/*! For license information please see 509.f368fd51c1b00cd60323.js.LICENSE.txt */
(globalThis.webpackChunk_rio_rio_ui=globalThis.webpackChunk_rio_rio_ui||[]).push([[509],{32055(e,t,i){"use strict";i.d(t,{j:()=>mn});var r=i(15567),n=i(51718),s=i(410),o=i(78953),a=new r.C("ClientDevice_Browser");var l,c,u,h,d,p,g,f,m,v,C,y,w,S,b,E,A,T,M,R,_,P,x,D,I,L,N,O,F,k,G,V,H,B,z,U,W,j,K,$,q,Y,Q,X,Z,J,ee,te,ie,re,ne,se,oe,ae,le,ce,ue,he,de,pe,ge,fe,me,ve,Ce,ye,we,Se,be,Ee,Ae,Te,Me,Re,_e,Pe,xe,De,Ie,Le,Ne,Oe,Fe,ke,Ge,Ve,He,Be,ze,Ue,We,je,Ke,$e,qe,Ye,Qe,Xe,Ze,Je,et,tt,it,rt,nt,st,ot,at,lt,ct,ut,ht,dt,pt,gt,ft,mt,vt,Ct,yt,wt,St,bt,Et,At,Tt,Mt,Rt,_t,Pt,xt,Dt=function(){function e(){}return e.clientInfo=function(){return"undefined"==typeof window?{}:function(){if("undefined"==typeof window)return a.warn("No window object available to get browser client info"),{};var e=window.navigator;if(!e)return a.warn("No navigator object available to get browser client info"),{};var t,i=e.platform,r=e.product,n=e.vendor,s=e.userAgent,o=e.language,l=function(e){var t=/.+(Opera[\s[A-Z]*|OPR[\sA-Z]*)\/([0-9\.]+).*/i.exec(e);if(t)return{type:t[1],version:t[2]};var i=/.+(Trident|Edge)\/([0-9\.]+).*/i.exec(e);if(i)return{type:i[1],version:i[2]};var r=/.+(Chrome|Firefox|FxiOS)\/([0-9\.]+).*/i.exec(e);if(r)return{type:r[1],version:r[2]};var n=/.+(Safari)\/([0-9\.]+).*/i.exec(e);if(n)return{type:n[1],version:n[2]};var s=/.+(AppleWebKit)\/([0-9\.]+).*/i.exec(e);if(s)return{type:s[1],version:s[2]};var o=/.*([A-Z]+)\/([0-9\.]+).*/i.exec(e);return o?{type:o[1],version:o[2]}:{type:"",version:""}}(s),c=(t=/\(([A-Za-z\s].*)\)/.exec((new Date).toString()))&&t[1]||"";return{platform:i,make:r||n,model:l.type,version:l.version,appVersion:[l.type,l.version].join("/"),language:o,timezone:c}}()},e.dimension=function(){return"undefined"==typeof window?(a.warn("No window object available to get browser client info"),{width:320,height:320}):{width:window.innerWidth,height:window.innerHeight}},e}(),It=i(56059),Lt=i(81504),Nt=i(71481),Ot={clockOffset:0,getDateWithClockOffset:function(){return Ot.clockOffset?new Date((new Date).getTime()+Ot.clockOffset):new Date},getClockOffset:function(){return Ot.clockOffset},getHeaderStringFromDate:function(e){return void 0===e&&(e=Ot.getDateWithClockOffset()),e.toISOString().replace(/[:\-]|\.\d{3}/g,"")},getDateFromHeaderString:function(e){var t=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o}(e.match(/^(\d{4})(\d{2})(\d{2})T(\d{2})(\d{2})(\d{2}).+/),7),i=t[1],r=t[2],n=t[3],s=t[4],o=t[5],a=t[6];return new Date(Date.UTC(Number(i),Number(r)-1,Number(n),Number(s),Number(o),Number(a)))},isClockSkewed:function(e){return Math.abs(e.getTime()-Ot.getDateWithClockOffset().getTime())>=3e5},isClockSkewError:function(e){if(!e.response||!e.response.headers)return!1;var t=e.response.headers;return Boolean(["BadRequestException","InvalidSignatureException"].includes(t["x-amzn-errortype"])&&(t.date||t.Date))},setClockOffset:function(e){Ot.clockOffset=e}},Ft=function(){return Ft=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Ft.apply(this,arguments)},kt=new r.C("Signer"),Gt="AWS4-HMAC-SHA256",Vt=function(e,t){var i=new It.Sha256(e);return i.update(t),i.digestSync()},Ht=function(e){var t=e||"",i=new It.Sha256;return i.update(t),(0,Lt.n)(i.digestSync())},Bt=function(e){return Object.keys(e).map(function(e){return e.toLowerCase()}).sort().join(";")},zt=function(e){var t,i,r=(0,Nt.parse)(e.url);return[e.method||"/",encodeURIComponent(r.pathname).replace(/%2F/gi,"/"),(i=r.query,i&&0!==i.length?i.split("&").map(function(e){var t=e.split("=");if(1===t.length)return e;var i=t[1].replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()});return t[0]+"="+i}).sort(function(e,t){var i=e.split("=")[0],r=t.split("=")[0];return i===r?e<t?-1:1:i<r?-1:1}).join("&"):""),(t=e.headers,t&&0!==Object.keys(t).length?Object.keys(t).map(function(e){return{key:e.toLowerCase(),value:t[e]?t[e].trim().replace(/\s+/g," "):""}}).sort(function(e,t){return e.key<t.key?-1:1}).map(function(e){return e.key+":"+e.value}).join("\n")+"\n":""),Bt(e.headers),Ht(e.data)].join("\n")},Ut=function(e){var t=((0,Nt.parse)(e.url).host.match(/([^\.]+)\.(?:([^\.]*)\.)?amazonaws\.com$/)||[]).slice(1,3);return"es"===t[1]&&(t=t.reverse()),{service:e.service||t[0],region:e.region||t[1]}},Wt=function(e,t,i){return[e,t,i,"aws4_request"].join("/")},jt=function(e,t,i,r){return[e,i,r,Ht(t)].join("\n")},Kt=function(e,t,i){kt.debug(i);var r=Vt("AWS4"+e,t),n=Vt(r,i.region),s=Vt(n,i.service);return Vt(s,"aws4_request")},$t=function(e,t){return(0,Lt.n)(Vt(e,t))},qt=function(){function e(){}return e.sign=function(e,t,i){if(void 0===i&&(i=null),e.headers=e.headers||{},e.body&&!e.data)throw new Error('The attribute "body" was found on the request object. Please use the attribute "data" instead.');var r=Ot.getDateWithClockOffset().toISOString().replace(/[:\-]|\.\d{3}/g,""),n=r.substr(0,8),s=(0,Nt.parse)(e.url);e.headers.host=s.host,e.headers["x-amz-date"]=r,t.session_token&&(e.headers["X-Amz-Security-Token"]=t.session_token);var o=zt(e);kt.debug(o);var a=i||Ut(e),l=Wt(n,a.region,a.service),c=jt(Gt,o,r,l),u=Kt(t.secret_key,n,a),h=$t(u,c),d=function(e,t,i,r,n){return[e+" Credential="+t+"/"+i,"SignedHeaders="+r,"Signature="+n].join(", ")}(Gt,t.access_key,l,Bt(e.headers),h);return e.headers.Authorization=d,e},e.signUrl=function(e,t,i,r){var n="object"==typeof e?e.url:e,s="object"==typeof e?e.method:"GET",o="object"==typeof e?e.body:void 0,a=Ot.getDateWithClockOffset().toISOString().replace(/[:\-]|\.\d{3}/g,""),l=a.substr(0,8),c=(0,Nt.parse)(n,!0,!0),u=(c.search,function(e,t){var i={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(e);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(e,r[n])&&(i[r[n]]=e[r[n]])}return i}(c,["search"])),h={host:u.host},d=i||Ut({url:(0,Nt.format)(u)}),p=d.region,g=d.service,f=Wt(l,p,g),m=t.session_token&&"iotdevicegateway"!==g,v=Ft(Ft(Ft({"X-Amz-Algorithm":Gt,"X-Amz-Credential":[t.access_key,f].join("/"),"X-Amz-Date":a.substr(0,16)},m?{"X-Amz-Security-Token":""+t.session_token}:{}),r?{"X-Amz-Expires":""+r}:{}),{"X-Amz-SignedHeaders":Object.keys(h).join(",")}),C=zt({method:s,url:(0,Nt.format)(Ft(Ft({},u),{query:Ft(Ft({},u.query),v)})),headers:h,data:o}),y=jt(Gt,C,a,f),w=Kt(t.secret_key,l,{region:p,service:g}),S=$t(w,y),b=Ft({"X-Amz-Signature":S},t.session_token&&{"X-Amz-Security-Token":t.session_token});return(0,Nt.format)({protocol:u.protocol,slashes:!0,hostname:u.hostname,port:u.port,pathname:u.pathname,query:Ft(Ft(Ft({},u.query),v),b)})},e}(),Yt=i(51678),Qt=i(41547),Xt=i(11351),Zt=i(65959);!function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(l||(l={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(c||(c={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(u||(u={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(h||(h={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(d||(d={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(p||(p={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(g||(g={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(f||(f={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(m||(m={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(v||(v={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(C||(C={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(y||(y={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(w||(w={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(S||(S={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(b||(b={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(E||(E={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(A||(A={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(T||(T={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(M||(M={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(R||(R={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(_||(_={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(P||(P={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(x||(x={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(D||(D={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(I||(I={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(L||(L={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(N||(N={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(O||(O={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(F||(F={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(k||(k={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(G||(G={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(V||(V={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(H||(H={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(B||(B={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(z||(z={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(U||(U={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(W||(W={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(j||(j={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(K||(K={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}($||($={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(q||(q={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Y||(Y={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Q||(Q={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(X||(X={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Z||(Z={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(J||(J={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ee||(ee={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(te||(te={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ie||(ie={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(re||(re={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ne||(ne={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(se||(se={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(oe||(oe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ae||(ae={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(le||(le={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ce||(ce={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ue||(ue={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(he||(he={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(de||(de={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(pe||(pe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ge||(ge={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(fe||(fe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(me||(me={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ve||(ve={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ce||(Ce={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ye||(ye={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(we||(we={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Se||(Se={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(be||(be={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ee||(Ee={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ae||(Ae={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Te||(Te={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Me||(Me={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Re||(Re={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(_e||(_e={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Pe||(Pe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(xe||(xe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(De||(De={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ie||(Ie={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Le||(Le={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ne||(Ne={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Oe||(Oe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Fe||(Fe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ke||(ke={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ge||(Ge={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ve||(Ve={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(He||(He={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Be||(Be={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ze||(ze={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ue||(Ue={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(We||(We={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(je||(je={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ke||(Ke={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}($e||($e={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(qe||(qe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ye||(Ye={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Qe||(Qe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Xe||(Xe={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ze||(Ze={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Je||(Je={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(et||(et={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(tt||(tt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(it||(it={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(rt||(rt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(nt||(nt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(st||(st={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ot||(ot={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(at||(at={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(lt||(lt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ct||(ct={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ut||(ut={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ht||(ht={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(dt||(dt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(pt||(pt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(gt||(gt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(ft||(ft={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(mt||(mt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(vt||(vt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Ct||(Ct={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(yt||(yt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(wt||(wt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(St||(St={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(bt||(bt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Et||(Et={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(At||(At={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Tt||(Tt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Mt||(Mt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Rt||(Rt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(_t||(_t={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(Pt||(Pt={})),function(e){e.filterSensitiveLog=function(e){return(0,Zt.__assign)({},e)}}(xt||(xt={}));var Jt=i(59027),ei=i(11538),ti=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u,h,d,p,g,f;return(0,Zt.__generator)(this,function(m){switch(m.label){case 0:return r=[(0,Zt.__assign)({},e)],f={},[4,Ai(e.body,t)];case 1:switch(i=Zt.__assign.apply(void 0,r.concat([(f.body=m.sent(),f)])),s="UnknownError",s=Ti(e,i.body)){case"BadRequestException":case"com.amazonaws.pinpoint#BadRequestException":return[3,2];case"ForbiddenException":case"com.amazonaws.pinpoint#ForbiddenException":return[3,4];case"InternalServerErrorException":case"com.amazonaws.pinpoint#InternalServerErrorException":return[3,6];case"MethodNotAllowedException":case"com.amazonaws.pinpoint#MethodNotAllowedException":return[3,8];case"NotFoundException":case"com.amazonaws.pinpoint#NotFoundException":return[3,10];case"PayloadTooLargeException":case"com.amazonaws.pinpoint#PayloadTooLargeException":return[3,12];case"TooManyRequestsException":case"com.amazonaws.pinpoint#TooManyRequestsException":return[3,14]}return[3,16];case 2:return o=[{}],[4,ri(i,t)];case 3:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,o.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 4:return a=[{}],[4,ni(i,t)];case 5:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,a.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 6:return l=[{}],[4,si(i,t)];case 7:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,l.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 8:return c=[{}],[4,oi(i,t)];case 9:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,c.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 10:return u=[{}],[4,ai(i,t)];case 11:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,u.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 12:return h=[{}],[4,li(i,t)];case 13:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,h.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 14:return d=[{}],[4,ci(i,t)];case 15:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,d.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 16:p=i.body,s=p.code||p.Code||s,n=(0,Zt.__assign)((0,Zt.__assign)({},p),{name:""+s,message:p.message||p.Message||s,$fault:"client",$metadata:Ei(e)}),m.label=17;case 17:return g=n.message||n.Message||s,n.message=g,delete n.Message,[2,Promise.reject(Object.assign(new Error(g),n))]}})})},ii=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u,h,d,p,g,f;return(0,Zt.__generator)(this,function(m){switch(m.label){case 0:return r=[(0,Zt.__assign)({},e)],f={},[4,Ai(e.body,t)];case 1:switch(i=Zt.__assign.apply(void 0,r.concat([(f.body=m.sent(),f)])),s="UnknownError",s=Ti(e,i.body)){case"BadRequestException":case"com.amazonaws.pinpoint#BadRequestException":return[3,2];case"ForbiddenException":case"com.amazonaws.pinpoint#ForbiddenException":return[3,4];case"InternalServerErrorException":case"com.amazonaws.pinpoint#InternalServerErrorException":return[3,6];case"MethodNotAllowedException":case"com.amazonaws.pinpoint#MethodNotAllowedException":return[3,8];case"NotFoundException":case"com.amazonaws.pinpoint#NotFoundException":return[3,10];case"PayloadTooLargeException":case"com.amazonaws.pinpoint#PayloadTooLargeException":return[3,12];case"TooManyRequestsException":case"com.amazonaws.pinpoint#TooManyRequestsException":return[3,14]}return[3,16];case 2:return o=[{}],[4,ri(i,t)];case 3:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,o.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 4:return a=[{}],[4,ni(i,t)];case 5:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,a.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 6:return l=[{}],[4,si(i,t)];case 7:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,l.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 8:return c=[{}],[4,oi(i,t)];case 9:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,c.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 10:return u=[{}],[4,ai(i,t)];case 11:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,u.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 12:return h=[{}],[4,li(i,t)];case 13:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,h.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 14:return d=[{}],[4,ci(i,t)];case 15:return n=Zt.__assign.apply(void 0,[Zt.__assign.apply(void 0,d.concat([m.sent()])),{name:s,$metadata:Ei(e)}]),[3,17];case 16:p=i.body,s=p.code||p.Code||s,n=(0,Zt.__assign)((0,Zt.__assign)({},p),{name:""+s,message:p.message||p.Message||s,$fault:"client",$metadata:Ei(e)}),m.label=17;case 17:return g=n.message||n.Message||s,n.message=g,delete n.Message,[2,Promise.reject(Object.assign(new Error(g),n))]}})})},ri=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"BadRequestException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},ni=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"ForbiddenException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},si=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"InternalServerErrorException",$fault:"server",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},oi=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"MethodNotAllowedException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},ai=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"NotFoundException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},li=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"PayloadTooLargeException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},ci=function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var t,i;return(0,Zt.__generator)(this,function(r){return t={name:"TooManyRequestsException",$fault:"client",$metadata:Ei(e),Message:void 0,RequestID:void 0},void 0!==(i=e.body).Message&&null!==i.Message&&(t.Message=i.Message),void 0!==i.RequestID&&null!==i.RequestID&&(t.RequestID=i.RequestID),[2,t]})})},ui=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.AppVersion&&null!==e.AppVersion&&{AppVersion:e.AppVersion}),void 0!==e.Locale&&null!==e.Locale&&{Locale:e.Locale}),void 0!==e.Make&&null!==e.Make&&{Make:e.Make}),void 0!==e.Model&&null!==e.Model&&{Model:e.Model}),void 0!==e.ModelVersion&&null!==e.ModelVersion&&{ModelVersion:e.ModelVersion}),void 0!==e.Platform&&null!==e.Platform&&{Platform:e.Platform}),void 0!==e.PlatformVersion&&null!==e.PlatformVersion&&{PlatformVersion:e.PlatformVersion}),void 0!==e.Timezone&&null!==e.Timezone&&{Timezone:e.Timezone})},hi=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.City&&null!==e.City&&{City:e.City}),void 0!==e.Country&&null!==e.Country&&{Country:e.Country}),void 0!==e.Latitude&&null!==e.Latitude&&{Latitude:e.Latitude}),void 0!==e.Longitude&&null!==e.Longitude&&{Longitude:e.Longitude}),void 0!==e.PostalCode&&null!==e.PostalCode&&{PostalCode:e.PostalCode}),void 0!==e.Region&&null!==e.Region&&{Region:e.Region})},di=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.UserAttributes&&null!==e.UserAttributes&&{UserAttributes:vi(e.UserAttributes,t)}),void 0!==e.UserId&&null!==e.UserId&&{UserId:e.UserId})},pi=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,Zt.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((i={})[n]=s,i))},{})},gi=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,Zt.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((i={})[n]=s,i))},{})},fi=function(e,t){return Object.entries(e).reduce(function(e,i){var r,n=(0,Zt.__read)(i,2),s=n[0],o=n[1];return null===o?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((r={})[s]=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.AppPackageName&&null!==e.AppPackageName&&{AppPackageName:e.AppPackageName}),void 0!==e.AppTitle&&null!==e.AppTitle&&{AppTitle:e.AppTitle}),void 0!==e.AppVersionCode&&null!==e.AppVersionCode&&{AppVersionCode:e.AppVersionCode}),void 0!==e.Attributes&&null!==e.Attributes&&{Attributes:gi(e.Attributes)}),void 0!==e.ClientSdkVersion&&null!==e.ClientSdkVersion&&{ClientSdkVersion:e.ClientSdkVersion}),void 0!==e.EventType&&null!==e.EventType&&{EventType:e.EventType}),void 0!==e.Metrics&&null!==e.Metrics&&{Metrics:pi(e.Metrics,t)}),void 0!==e.SdkName&&null!==e.SdkName&&{SdkName:e.SdkName}),void 0!==e.Session&&null!==e.Session&&{Session:yi(e.Session,t)}),void 0!==e.Timestamp&&null!==e.Timestamp&&{Timestamp:e.Timestamp})}(o,t),r))},{})},mi=function(e,t){return Object.entries(e).reduce(function(e,i){var r,n=(0,Zt.__read)(i,2),s=n[0],o=n[1];return null===o?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((r={})[s]=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.Endpoint&&null!==e.Endpoint&&{Endpoint:Ci(e.Endpoint,t)}),void 0!==e.Events&&null!==e.Events&&{Events:fi(e.Events,t)})}(o,t),r))},{})},vi=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,Zt.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((i={})[n]=function(e){return e.filter(function(e){return null!=e}).map(function(e){return null===e?null:e})}(s),i))},{})},Ci=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.Address&&null!==e.Address&&{Address:e.Address}),void 0!==e.Attributes&&null!==e.Attributes&&{Attributes:vi(e.Attributes,t)}),void 0!==e.ChannelType&&null!==e.ChannelType&&{ChannelType:e.ChannelType}),void 0!==e.Demographic&&null!==e.Demographic&&{Demographic:ui(e.Demographic)}),void 0!==e.EffectiveDate&&null!==e.EffectiveDate&&{EffectiveDate:e.EffectiveDate}),void 0!==e.EndpointStatus&&null!==e.EndpointStatus&&{EndpointStatus:e.EndpointStatus}),void 0!==e.Location&&null!==e.Location&&{Location:hi(e.Location)}),void 0!==e.Metrics&&null!==e.Metrics&&{Metrics:pi(e.Metrics,t)}),void 0!==e.OptOut&&null!==e.OptOut&&{OptOut:e.OptOut}),void 0!==e.RequestId&&null!==e.RequestId&&{RequestId:e.RequestId}),void 0!==e.User&&null!==e.User&&{User:di(e.User,t)})},yi=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.Duration&&null!==e.Duration&&{Duration:e.Duration}),void 0!==e.Id&&null!==e.Id&&{Id:e.Id}),void 0!==e.StartTimestamp&&null!==e.StartTimestamp&&{StartTimestamp:e.StartTimestamp}),void 0!==e.StopTimestamp&&null!==e.StopTimestamp&&{StopTimestamp:e.StopTimestamp})},wi=function(e,t){return{Message:void 0!==e.Message&&null!==e.Message?e.Message:void 0,StatusCode:void 0!==e.StatusCode&&null!==e.StatusCode?e.StatusCode:void 0}},Si=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,Zt.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((i={})[n]=function(e){return{Message:void 0!==e.Message&&null!==e.Message?e.Message:void 0,StatusCode:void 0!==e.StatusCode&&null!==e.StatusCode?e.StatusCode:void 0}}(s),i))},{})},bi=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,Zt.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,Zt.__assign)((0,Zt.__assign)({},e),((i={})[n]=function(e){return{EndpointItemResponse:void 0!==e.EndpointItemResponse&&null!==e.EndpointItemResponse?wi(e.EndpointItemResponse):void 0,EventsItemResponse:void 0!==e.EventsItemResponse&&null!==e.EventsItemResponse?Si(e.EventsItemResponse):void 0}}(s),i))},{})},Ei=function(e){var t;return{httpStatusCode:e.statusCode,requestId:null!==(t=e.headers["x-amzn-requestid"])&&void 0!==t?t:e.headers["x-amzn-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}},Ai=function(e,t){return function(e,t){return function(e,t){return void 0===e&&(e=new Uint8Array),e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array)}(e,t).then(function(e){return t.utf8Encoder(e)})}(e,t).then(function(e){return e.length?JSON.parse(e):{}})},Ti=function(e,t){var i,r=function(e){var t=e;return t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},n=(i=e.headers,Object.keys(i).find(function(e){return e.toLowerCase()==="x-amzn-errortype".toLowerCase()}));return void 0!==n?r(e.headers[n]):void 0!==t.code?r(t.code):void 0!==t.__type?r(t.__type):""},Mi=i(74052),Ri=function(e){function t(t){var i=e.call(this)||this;return i.input=t,i}return(0,Zt.__extends)(t,e),t.prototype.resolveMiddleware=function(e,t,i){this.middlewareStack.use((0,Mi.TM)(t,this.serialize,this.deserialize));var r=e.concat(this.middlewareStack),n={logger:t.logger,clientName:"PinpointClient",commandName:"PutEventsCommand",inputFilterSensitiveLog:Ce.filterSensitiveLog,outputFilterSensitiveLog:ye.filterSensitiveLog},s=t.requestHandler;return r.resolve(function(e){return s.handle(e.request,i||{})},n)},t.prototype.serialize=function(e,t){return function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u;return(0,Zt.__generator)(this,function(h){switch(h.label){case 0:if(i={"content-type":"application/json"},r="/v1/apps/{ApplicationId}/events",void 0===e.ApplicationId)throw new Error("No value provided for input HTTP label: ApplicationId.");if((n=e.ApplicationId).length<=0)throw new Error("Empty value provided for input HTTP label: ApplicationId.");return r=r.replace("{ApplicationId}",(0,ei.$6)(n)),void 0!==e.EventsRequest&&(s=function(e,t){return(0,Zt.__assign)({},void 0!==e.BatchItem&&null!==e.BatchItem&&{BatchItem:mi(e.BatchItem,t)})}(e.EventsRequest,t)),void 0===s&&(s={}),s=JSON.stringify(s),[4,t.endpoint()];case 1:return o=h.sent(),a=o.hostname,l=o.protocol,c=void 0===l?"https":l,u=o.port,[2,new Jt.Kd({protocol:c,hostname:a,port:u,method:"POST",headers:i,path:r,body:s})]}})})}(e,t)},t.prototype.deserialize=function(e,t){return function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,Zt.__generator)(this,function(n){switch(n.label){case 0:return 202!==e.statusCode&&e.statusCode>=300?[2,ti(e,t)]:(i={$metadata:Ei(e),EventsResponse:void 0},[4,Ai(e.body,t)]);case 1:return r=n.sent(),i.EventsResponse=function(e,t){return{Results:void 0!==e.Results&&null!==e.Results?bi(e.Results,t):void 0}}(r,t),[2,Promise.resolve(i)]}})})}(e,t)},t}(ei.uB),_i=function(e){function t(t){var i=e.call(this)||this;return i.input=t,i}return(0,Zt.__extends)(t,e),t.prototype.resolveMiddleware=function(e,t,i){this.middlewareStack.use((0,Mi.TM)(t,this.serialize,this.deserialize));var r=e.concat(this.middlewareStack),n={logger:t.logger,clientName:"PinpointClient",commandName:"UpdateEndpointCommand",inputFilterSensitiveLog:tt.filterSensitiveLog,outputFilterSensitiveLog:it.filterSensitiveLog},s=t.requestHandler;return r.resolve(function(e){return s.handle(e.request,i||{})},n)},t.prototype.serialize=function(e,t){return function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u;return(0,Zt.__generator)(this,function(h){switch(h.label){case 0:if(i={"content-type":"application/json"},r="/v1/apps/{ApplicationId}/endpoints/{EndpointId}",void 0===e.ApplicationId)throw new Error("No value provided for input HTTP label: ApplicationId.");if((n=e.ApplicationId).length<=0)throw new Error("Empty value provided for input HTTP label: ApplicationId.");if(r=r.replace("{ApplicationId}",(0,ei.$6)(n)),void 0===e.EndpointId)throw new Error("No value provided for input HTTP label: EndpointId.");if((n=e.EndpointId).length<=0)throw new Error("Empty value provided for input HTTP label: EndpointId.");return r=r.replace("{EndpointId}",(0,ei.$6)(n)),void 0!==e.EndpointRequest&&(s=function(e,t){return(0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)((0,Zt.__assign)({},void 0!==e.Address&&null!==e.Address&&{Address:e.Address}),void 0!==e.Attributes&&null!==e.Attributes&&{Attributes:vi(e.Attributes,t)}),void 0!==e.ChannelType&&null!==e.ChannelType&&{ChannelType:e.ChannelType}),void 0!==e.Demographic&&null!==e.Demographic&&{Demographic:ui(e.Demographic)}),void 0!==e.EffectiveDate&&null!==e.EffectiveDate&&{EffectiveDate:e.EffectiveDate}),void 0!==e.EndpointStatus&&null!==e.EndpointStatus&&{EndpointStatus:e.EndpointStatus}),void 0!==e.Location&&null!==e.Location&&{Location:hi(e.Location)}),void 0!==e.Metrics&&null!==e.Metrics&&{Metrics:pi(e.Metrics,t)}),void 0!==e.OptOut&&null!==e.OptOut&&{OptOut:e.OptOut}),void 0!==e.RequestId&&null!==e.RequestId&&{RequestId:e.RequestId}),void 0!==e.User&&null!==e.User&&{User:di(e.User,t)})}(e.EndpointRequest,t)),void 0===s&&(s={}),s=JSON.stringify(s),[4,t.endpoint()];case 1:return o=h.sent(),a=o.hostname,l=o.protocol,c=void 0===l?"https":l,u=o.port,[2,new Jt.Kd({protocol:c,hostname:a,port:u,method:"PUT",headers:i,path:r,body:s})]}})})}(e,t)},t.prototype.deserialize=function(e,t){return function(e,t){return(0,Zt.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,Zt.__generator)(this,function(n){switch(n.label){case 0:return 202!==e.statusCode&&e.statusCode>=300?[2,ii(e,t)]:(i={$metadata:Ei(e),MessageBody:void 0},[4,Ai(e.body,t)]);case 1:return r=n.sent(),i.MessageBody=function(e){return{Message:void 0!==e.Message&&null!==e.Message?e.Message:void 0,RequestID:void 0!==e.RequestID&&null!==e.RequestID?e.RequestID:void 0}}(r),[2,Promise.resolve(i)]}})})}(e,t)},t}(ei.uB),Pi=i(54218),xi=i(22292),Di=i(10078),Ii=i(16307),Li=i(68380),Ni=i(93972),Oi=i(39448),Fi=i(31643),ki="pinpoint.{region}.amazonaws.com",Gi=new Set(["af-south-1","ap-east-1","ap-northeast-1","ap-northeast-2","ap-south-1","ap-southeast-1","ap-southeast-2","ca-central-1","eu-central-1","eu-north-1","eu-south-1","eu-west-1","eu-west-2","eu-west-3","me-south-1","sa-east-1","us-east-1","us-east-2","us-west-1","us-west-2"]),Vi=new Set(["cn-north-1","cn-northwest-1"]),Hi=new Set(["us-iso-east-1"]),Bi=new Set(["us-isob-east-1"]),zi=new Set(["us-gov-east-1","us-gov-west-1"]),Ui={apiVersion:"2016-12-01",disableHostPrefix:!1,logger:{},regionInfoProvider:function(e,t){var i=void 0;switch(e){case"ap-northeast-1":i={hostname:"pinpoint.ap-northeast-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"ap-northeast-2":i={hostname:"pinpoint.ap-northeast-2.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"ap-south-1":i={hostname:"pinpoint.ap-south-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"ap-southeast-1":i={hostname:"pinpoint.ap-southeast-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"ap-southeast-2":i={hostname:"pinpoint.ap-southeast-2.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"ca-central-1":i={hostname:"pinpoint.ca-central-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"eu-central-1":i={hostname:"pinpoint.eu-central-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"eu-west-1":i={hostname:"pinpoint.eu-west-1.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"eu-west-2":i={hostname:"pinpoint.eu-west-2.amazonaws.com",partition:"aws",signingService:"mobiletargeting"};break;case"fips-us-east-1":i={hostname:"pinpoint-fips.us-east-1.amazonaws.com",partition:"aws",signingRegion:"us-east-1"};break;case"fips-us-gov-west-1":i={hostname:"pinpoint-fips.us-gov-west-1.amazonaws.com",partition:"aws-us-gov",signingRegion:"us-gov-west-1"};break;case"fips-us-west-2":i={hostname:"pinpoint-fips.us-west-2.amazonaws.com",partition:"aws",signingRegion:"us-west-2"};break;case"us-east-1":i={hostname:"pinpoint.us-east-1.amazonaws.com",partition:"aws",signingRegion:"us-east-1"};break;case"us-gov-west-1":i={hostname:"pinpoint.us-gov-west-1.amazonaws.com",partition:"aws-us-gov",signingRegion:"us-gov-west-1"};break;case"us-west-2":i={hostname:"pinpoint.us-west-2.amazonaws.com",partition:"aws",signingRegion:"us-west-2"};break;default:Gi.has(e)&&(i={hostname:ki.replace("{region}",e),partition:"aws",signingService:"mobiletargeting"}),Vi.has(e)&&(i={hostname:"pinpoint.{region}.amazonaws.com.cn".replace("{region}",e),partition:"aws-cn"}),Hi.has(e)&&(i={hostname:"pinpoint.{region}.c2s.ic.gov".replace("{region}",e),partition:"aws-iso"}),Bi.has(e)&&(i={hostname:"pinpoint.{region}.sc2s.sgov.gov".replace("{region}",e),partition:"aws-iso-b"}),zi.has(e)&&(i={hostname:"pinpoint.{region}.amazonaws.com".replace("{region}",e),partition:"aws-us-gov",signingService:"mobiletargeting"}),void 0===i&&(i={hostname:ki.replace("{region}",e),partition:"aws",signingService:"mobiletargeting"})}return Promise.resolve((0,Zt.__assign)({signingService:"mobiletargeting"},i))},serviceId:"Pinpoint",urlParser:i(2049).D},Wi=(0,Zt.__assign)((0,Zt.__assign)({},Ui),{runtime:"browser",base64Decoder:Li.E,base64Encoder:Li.n,bodyLengthChecker:Ni.n,credentialDefaultProvider:function(e){return function(){return Promise.reject(new Error("Credential is missing"))}},defaultUserAgentProvider:(0,Oi.m)({serviceId:Ui.serviceId,clientVersion:"3.6.1"}),maxAttempts:Ii.Gz,region:(0,Di.B)("Region is missing"),requestHandler:new xi.N,sha256:Pi.Sha256,streamCollector:xi.k,utf8Decoder:Fi.fromUtf8,utf8Encoder:Fi.toUtf8}),ji=i(85775),Ki=i(23788),$i=i(14188),qi=i(64996),Yi=i(88428),Qi=i(44625),Xi=function(e){function t(t){var i=this,r=(0,Zt.__assign)((0,Zt.__assign)({},Wi),t),n=(0,ji.TD)(r),s=(0,ji.vJ)(n),o=(0,Yi.k9)(s),a=(0,Ii.$z)(o),l=(0,$i.OV)(a),c=(0,Qi.Dc)(l);return(i=e.call(this,c)||this).config=c,i.middlewareStack.use((0,Yi.DF)(i.config)),i.middlewareStack.use((0,Ii.ey)(i.config)),i.middlewareStack.use((0,Ki.vK)(i.config)),i.middlewareStack.use((0,$i.TC)(i.config)),i.middlewareStack.use((0,qi.Y7)(i.config)),i.middlewareStack.use((0,Qi.sM)(i.config)),i}return(0,Zt.__extends)(t,e),t.prototype.destroy=function(){e.prototype.destroy.call(this)},t}(ei.Kj),Zi={keyPrefix:"aws-amplify-cache",capacityInBytes:1048576,itemMaxSize:21e4,defaultTTL:2592e5,defaultPriority:5,warningThreshold:.8,storage:(new(i(75315).i1)).getStorage()};function Ji(e){var t=0;t=e.length;for(var i=e.length;i>=0;i-=1){var r=e.charCodeAt(i);r>127&&r<=2047?t+=1:r>2047&&r<=65535&&(t+=2),r>=56320&&r<=57343&&(i-=1)}return t}function er(){return(new Date).getTime()}function tr(e){return Number.isInteger?Number.isInteger(e):function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e}(e)}var ir,rr={},nr=(function(){function e(){}e.clear=function(){rr={}},e.getItem=function(e){return rr[e]||null},e.setItem=function(e,t){rr[e]=t},e.removeItem=function(e){delete rr[e]}}(),new r.C("StorageCache")),sr=function(){function e(e){this.config=Object.assign({},e),this.cacheCurSizeKey=this.config.keyPrefix+"CurSize",this.checkConfig()}return e.prototype.getModuleName=function(){return"Cache"},e.prototype.checkConfig=function(){tr(this.config.capacityInBytes)||(nr.error("Invalid parameter: capacityInBytes. It should be an Integer. Setting back to default."),this.config.capacityInBytes=Zi.capacityInBytes),tr(this.config.itemMaxSize)||(nr.error("Invalid parameter: itemMaxSize. It should be an Integer. Setting back to default."),this.config.itemMaxSize=Zi.itemMaxSize),tr(this.config.defaultTTL)||(nr.error("Invalid parameter: defaultTTL. It should be an Integer. Setting back to default."),this.config.defaultTTL=Zi.defaultTTL),tr(this.config.defaultPriority)||(nr.error("Invalid parameter: defaultPriority. It should be an Integer. Setting back to default."),this.config.defaultPriority=Zi.defaultPriority),this.config.itemMaxSize>this.config.capacityInBytes&&(nr.error("Invalid parameter: itemMaxSize. It should be smaller than capacityInBytes. Setting back to default."),this.config.itemMaxSize=Zi.itemMaxSize),(this.config.defaultPriority>5||this.config.defaultPriority<1)&&(nr.error("Invalid parameter: defaultPriority. It should be between 1 and 5. Setting back to default."),this.config.defaultPriority=Zi.defaultPriority),(Number(this.config.warningThreshold)>1||Number(this.config.warningThreshold)<0)&&(nr.error("Invalid parameter: warningThreshold. It should be between 0 and 1. Setting back to default."),this.config.warningThreshold=Zi.warningThreshold),this.config.capacityInBytes>5242880&&(nr.error("Cache Capacity should be less than 5MB. Setting back to default. Setting back to default."),this.config.capacityInBytes=Zi.capacityInBytes)},e.prototype.fillCacheItem=function(e,t,i){var r={key:e,data:t,timestamp:er(),visitedTime:er(),priority:i.priority,expires:i.expires,type:typeof t,byteSize:0};return r.byteSize=Ji(JSON.stringify(r)),r.byteSize=Ji(JSON.stringify(r)),r},e.prototype.configure=function(e){return e?(e.keyPrefix&&nr.warn("Don't try to configure keyPrefix!"),this.config=Object.assign({},this.config,e,e.Cache),this.checkConfig(),this.config):this.config},e}(),or=(ir=function(e,t){return ir=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},ir(e,t)},function(e,t){function i(){this.constructor=e}ir(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),ar=new r.C("Cache"),lr=new(function(e){function t(t){var i=this,r=t?Object.assign({},Zi,t):Zi;return(i=e.call(this,r)||this).config.storage=r.storage,i.getItem=i.getItem.bind(i),i.setItem=i.setItem.bind(i),i.removeItem=i.removeItem.bind(i),i}return or(t,e),t.prototype._decreaseCurSizeInBytes=function(e){var t=this.getCacheCurSize();this.config.storage.setItem(this.cacheCurSizeKey,(t-e).toString())},t.prototype._increaseCurSizeInBytes=function(e){var t=this.getCacheCurSize();this.config.storage.setItem(this.cacheCurSizeKey,(t+e).toString())},t.prototype._refreshItem=function(e,t){return e.visitedTime=er(),this.config.storage.setItem(t,JSON.stringify(e)),e},t.prototype._isExpired=function(e){var t=this.config.storage.getItem(e),i=JSON.parse(t);return er()>=i.expires},t.prototype._removeItem=function(e,t){var i=t||JSON.parse(this.config.storage.getItem(e)).byteSize;this._decreaseCurSizeInBytes(i),this.config.storage.removeItem(e)},t.prototype._setItem=function(e,t){this._increaseCurSizeInBytes(t.byteSize);try{this.config.storage.setItem(e,JSON.stringify(t))}catch(e){this._decreaseCurSizeInBytes(t.byteSize),ar.error("Failed to set item "+e)}},t.prototype._sizeToPop=function(e){var t=this.getCacheCurSize()+e-this.config.capacityInBytes,i=(1-this.config.warningThreshold)*this.config.capacityInBytes;return t>i?t:i},t.prototype._isCacheFull=function(e){return e+this.getCacheCurSize()>this.config.capacityInBytes},t.prototype._findValidKeys=function(){for(var e=[],t=[],i=0;i<this.config.storage.length;i+=1)t.push(this.config.storage.key(i));for(i=0;i<t.length;i+=1){var r=t[i];0===r.indexOf(this.config.keyPrefix)&&r!==this.cacheCurSizeKey&&(this._isExpired(r)?this._removeItem(r):e.push(r))}return e},t.prototype._popOutItems=function(e,t){for(var i=[],r=t,n=0;n<e.length;n+=1){var s=this.config.storage.getItem(e[n]);if(null!=s){var o=JSON.parse(s);i.push(o)}}for(i.sort(function(e,t){return e.priority>t.priority?-1:e.priority<t.priority?1:e.visitedTime<t.visitedTime?-1:1}),n=0;n<i.length;n+=1)if(this._removeItem(i[n].key,i[n].byteSize),(r-=i[n].byteSize)<=0)return},t.prototype.setItem=function(e,t,i){ar.log("Set item: key is "+e+", value is "+t+" with options: "+i);var r=this.config.keyPrefix+e;if(r!==this.config.keyPrefix&&r!==this.cacheCurSizeKey)if(void 0!==t){var n={priority:i&&void 0!==i.priority?i.priority:this.config.defaultPriority,expires:i&&void 0!==i.expires?i.expires:this.config.defaultTTL+er()};if(n.priority<1||n.priority>5)ar.warn("Invalid parameter: priority due to out or range. It should be within 1 and 5.");else{var s=this.fillCacheItem(r,t,n);if(s.byteSize>this.config.itemMaxSize)ar.warn("Item with key: "+e+" you are trying to put into is too big!");else try{var o=this.config.storage.getItem(r);if(o&&this._removeItem(r,JSON.parse(o).byteSize),this._isCacheFull(s.byteSize)){var a=this._findValidKeys();if(this._isCacheFull(s.byteSize)){var l=this._sizeToPop(s.byteSize);this._popOutItems(a,l)}}this._setItem(r,s)}catch(e){ar.warn("setItem failed! "+e)}}}else ar.warn("The value of item should not be undefined!");else ar.warn("Invalid key: should not be empty or 'CurSize'")},t.prototype.getItem=function(e,t){ar.log("Get item: key is "+e+" with options "+t);var i=null,r=this.config.keyPrefix+e;if(r===this.config.keyPrefix||r===this.cacheCurSizeKey)return ar.warn("Invalid key: should not be empty or 'CurSize'"),null;try{if(null!=(i=this.config.storage.getItem(r))){if(!this._isExpired(r)){var n=JSON.parse(i);return(n=this._refreshItem(n,r)).data}this._removeItem(r,JSON.parse(i).byteSize),i=null}if(t&&void 0!==t.callback){var s=t.callback();return null!==s&&this.setItem(e,s,t),s}return null}catch(e){return ar.warn("getItem failed! "+e),null}},t.prototype.removeItem=function(e){ar.log("Remove item: key is "+e);var t=this.config.keyPrefix+e;if(t!==this.config.keyPrefix&&t!==this.cacheCurSizeKey)try{var i=this.config.storage.getItem(t);i&&this._removeItem(t,JSON.parse(i).byteSize)}catch(e){ar.warn("removeItem failed! "+e)}},t.prototype.clear=function(){ar.log("Clear Cache");for(var e=[],t=0;t<this.config.storage.length;t+=1){var i=this.config.storage.key(t);0===i.indexOf(this.config.keyPrefix)&&e.push(i)}try{for(t=0;t<e.length;t+=1)this.config.storage.removeItem(e[t])}catch(e){ar.warn("clear failed! "+e)}},t.prototype.getAllKeys=function(){for(var e=[],t=0;t<this.config.storage.length;t+=1){var i=this.config.storage.key(t);0===i.indexOf(this.config.keyPrefix)&&i!==this.cacheCurSizeKey&&e.push(i.substring(this.config.keyPrefix.length))}return e},t.prototype.getCacheCurSize=function(){var e=this.config.storage.getItem(this.cacheCurSizeKey);return e||(this.config.storage.setItem(this.cacheCurSizeKey,"0"),e="0"),Number(e)},t.prototype.createInstance=function(e){return e.keyPrefix&&e.keyPrefix!==Zi.keyPrefix||(ar.error("invalid keyPrefix, setting keyPrefix with timeStamp"),e.keyPrefix=er.toString()),new t(e)},t}(sr));const cr=lr;o.HA.register(lr);var ur=i(16699),hr=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},dr=new r.C("EventsBuffer"),pr=[429,500],gr=[202];const fr=function(){function e(e,t){this._pause=!1,this._flush=!1,dr.debug("Instantiating buffer with config:",t),this._buffer=[],this._client=e,this._config=t,this._sendBatch=this._sendBatch.bind(this),this._startLoop()}return e.prototype.push=function(e){var t;if(this._buffer.length>=this._config.bufferSize)return dr.debug("Exceeded analytics events buffer size"),e.handlers.reject(new Error("Exceeded the size of analytics events buffer"));var i=((t={})[e.params.event.eventId]=e,t);this._buffer.push(i)},e.prototype.pause=function(){this._pause=!0},e.prototype.resume=function(){this._pause=!1},e.prototype.updateClient=function(e){this._client=e},e.prototype.flush=function(){this._flush=!0},e.prototype._startLoop=function(){this._interval&&clearInterval(this._interval);var e=this._config.flushInterval;this._interval=setInterval(this._sendBatch,e)},e.prototype._sendBatch=function(){var e=this._buffer.length;if(this._flush&&!e&&clearInterval(this._interval),!this._pause&&e){var t=this._config.flushSize,i=Math.min(t,e),r=this._buffer.splice(0,i);this._putEvents(r)}},e.prototype._putEvents=function(e){return t=this,i=void 0,n=function(){var t,i,r,n,s;return function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}(this,function(o){switch(o.label){case 0:t=this._bufferToMap(e),i=this._generateBatchEventParams(t),o.label=1;case 1:return o.trys.push([1,3,,4]),r=new Ri(i),[4,this._client.send(r)];case 2:return n=o.sent(),this._processPutEventsSuccessResponse(n,t),[3,4];case 3:return s=o.sent(),[2,this._handlePutEventsFailure(s,t)];case 4:return[2]}})},new((r=void 0)||(r=Promise))(function(e,s){function o(e){try{l(n.next(e))}catch(e){s(e)}}function a(e){try{l(n.throw(e))}catch(e){s(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof r?i:new r(function(e){e(i)})).then(o,a)}l((n=n.apply(t,i||[])).next())});var t,i,r,n},e.prototype._generateBatchEventParams=function(e){var t={ApplicationId:"",EventsRequest:{BatchItem:{}}};return Object.values(e).forEach(function(e){var i=e.params,r=i.event,n=i.timestamp,s=i.config,o=r.name,a=r.attributes,l=r.metrics,c=r.eventId,u=r.session,h=s.appId,d=s.endpointId,p=t.EventsRequest.BatchItem;t.ApplicationId=t.ApplicationId||h,p[d]||(p[d]={Endpoint:{},Events:{}}),p[d].Events[c]={EventType:o,Timestamp:new Date(n).toISOString(),Attributes:a,Metrics:l,Session:u}}),t},e.prototype._handlePutEventsFailure=function(e,t){dr.debug("_putEvents Failed: ",e);var i=e.$metadata&&e.$metadata.httpStatusCode;if(pr.includes(i)){var r=Object.values(t);this._retry(r)}},e.prototype._processPutEventsSuccessResponse=function(e,t){var i=e.EventsResponse.Results,r=[];Object.entries(i).forEach(function(e){var i=hr(e,2),n=i[0],s=i[1].EventsItemResponse;Object.entries(s).forEach(function(e){var i,s,o=hr(e,2),a=o[0],l=o[1],c=l.StatusCode,u=l.Message,h=t[a],d={EventsResponse:{Results:(i={},i[n]={EventsItemResponse:(s={},s[a]={StatusCode:c,Message:u},s)},i)}};if(gr.includes(c))h.handlers.resolve(d);else{if(!pr.includes(c)){var p=h.params.event.name;return dr.error("event "+a+" : "+p+" failed with error: "+u),h.handlers.reject(d)}r.push(h)}})}),r.length&&this._retry(r)},e.prototype._retry=function(e){var t,i=[];e.forEach(function(e){var t,r=e.params,n=r.event,s=n.eventId,o=n.name;if(r.resendLimit-- >0)return dr.debug("resending event "+s+" : "+o+" with "+r.resendLimit+" retry attempts remaining"),void i.push((t={},t[s]=e,t));dr.debug("no retry attempts remaining for event "+s+" : "+o)}),(t=this._buffer).unshift.apply(t,function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(hr(arguments[t]));return e}(i))},e.prototype._bufferToMap=function(e){return e.reduce(function(e,t){var i=hr(Object.entries(t),1),r=hr(i[0],2),n=r[0],s=r[1];return e[n]=s,e},{})},e}();var mr=function(){return mr=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},mr.apply(this,arguments)},vr=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},Cr=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},yr=function(e,t){var i={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(e);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(e,r[n])&&(i[r[n]]=e[r[n]])}return i},wr="undefined"!=typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("amplify_default"):"@@amplify_default",Sr=function(e,t){n.YZ.dispatch("analytics",{event:e,data:t},"Analytics",wr)},br=new r.C("AWSPinpointProvider"),Er=[429,500],Ar=[202],Tr="_update_endpoint",Mr="_session.stop",Rr="undefined"!=typeof navigator&&navigator&&"function"==typeof navigator.sendBeacon,_r=function(){function e(e){this._endpointGenerating=!0,this._endpointUpdateInProgress=!1,this._buffer=null,this._endpointBuffer=[],this._config=e||{},this._config.bufferSize=this._config.bufferSize||1e3,this._config.flushSize=this._config.flushSize||100,this._config.flushInterval=this._config.flushInterval||5e3,this._config.resendLimit=this._config.resendLimit||5,this._clientInfo=Dt.clientInfo()}return e.prototype.getCategory=function(){return e.category},e.prototype.getProviderName=function(){return e.providerName},e.prototype.configure=function(e){var t=this;br.debug("configure Analytics",e);var i=e||{};if(this._config=Object.assign({},this._config,i),this._endpointGenerating=!!e.autoSessionRecord,this._config.appId&&!this._config.disabled)if(this._config.endpointId)Sr("pinpointProvider_configured",null);else{var r=this.getProviderName()+"_"+this._config.appId;this._getEndpointId(r).then(function(e){br.debug("setting endpoint id from the cache",e),t._config.endpointId=e,Sr("pinpointProvider_configured",null)}).catch(function(e){br.debug("Failed to generate endpointId",e)})}else this._flushBuffer();return this._config},e.prototype.record=function(e,t){return vr(this,void 0,void 0,function(){var i,r;return Cr(this,function(n){switch(n.label){case 0:return br.debug("_public record",e),[4,this._getCredentials()];case 1:return(i=n.sent())&&this._config.appId&&this._config.region?(this._initClients(i),r=(new Date).getTime(),this._generateSession(e),e.event.eventId=(0,ur.v1)(),Object.assign(e,{timestamp:r,config:this._config}),e.event.immediate?[2,this._send(e,t)]:(this._putToBuffer(e,t),[2])):(br.debug("cannot send events without credentials, applicationId or region"),[2,t.reject(new Error("No credentials, applicationId or region"))])}})})},e.prototype._sendEndpointUpdate=function(e){return vr(this,void 0,void 0,function(){var t;return Cr(this,function(i){switch(i.label){case 0:return this._endpointUpdateInProgress?(this._endpointBuffer.push(e),[2]):(this._endpointUpdateInProgress=!0,[4,this._updateEndpoint(e)]);case 1:return i.sent(),t=this._endpointBuffer.shift(),this._endpointUpdateInProgress=!1,t&&this._sendEndpointUpdate(t),[2]}})})},e.prototype._putToBuffer=function(e,t){e.event.name!==Tr?this._buffer&&this._buffer.push({params:e,handlers:t}):this._sendEndpointUpdate({params:e,handlers:t})},e.prototype._generateSession=function(e){this._sessionId=this._sessionId||(0,ur.v1)();var t=e.event;switch(t.name){case"_session.start":this._sessionStartTimestamp=(new Date).getTime(),this._sessionId=(0,ur.v1)(),t.session={Id:this._sessionId,StartTimestamp:new Date(this._sessionStartTimestamp).toISOString()};break;case Mr:var i=(new Date).getTime();this._sessionStartTimestamp=this._sessionStartTimestamp||(new Date).getTime(),this._sessionId=this._sessionId||(0,ur.v1)(),t.session={Id:this._sessionId,Duration:i-this._sessionStartTimestamp,StartTimestamp:new Date(this._sessionStartTimestamp).toISOString(),StopTimestamp:new Date(i).toISOString()},this._sessionId=void 0,this._sessionStartTimestamp=void 0;break;default:this._sessionStartTimestamp=this._sessionStartTimestamp||(new Date).getTime(),this._sessionId=this._sessionId||(0,ur.v1)(),t.session={Id:this._sessionId,StartTimestamp:new Date(this._sessionStartTimestamp).toISOString()}}},e.prototype._send=function(e,t){return vr(this,void 0,void 0,function(){return Cr(this,function(i){switch(e.event.name){case Tr:return[2,this._updateEndpoint({params:e,handlers:t})];case Mr:return[2,this._pinpointSendStopSession(e,t)];default:return[2,this._pinpointPutEvents(e,t)]}return[2]})})},e.prototype._generateBatchItemContext=function(e){var t,i=e.event,r=e.timestamp,n=e.config,s=i.name,o=i.attributes,a=i.metrics,l=i.eventId,c=i.session,u=n.appId,h=n.endpointId,d={ApplicationId:u,EventsRequest:{BatchItem:{}}},p={Endpoint:{}};return p.Events=((t={})[l]={EventType:s,Timestamp:new Date(r).toISOString(),Attributes:o,Metrics:a,Session:c},t),d.EventsRequest.BatchItem[h]=p,d},e.prototype._pinpointPutEvents=function(e,t){return vr(this,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u,h,d;return Cr(this,function(p){switch(p.label){case 0:i=e.event.eventId,r=e.config.endpointId,n=this._generateBatchItemContext(e),s=new Ri(n),p.label=1;case 1:return p.trys.push([1,3,,4]),[4,this.pinpointClient.send(s)];case 2:return o=p.sent(),a=r,l=i,c=o.EventsResponse.Results[a].EventsItemResponse[l],u=c.StatusCode,h=c.Message,Ar.includes(u)?(br.debug("record event success. ",o),[2,t.resolve(o)]):Er.includes(u)?(this._retry(e,t),[3,4]):(br.error("Event "+i+" is not accepted, the error is "+h),[2,t.reject(o)]);case 3:return d=p.sent(),this._eventError(d),[2,t.reject(d)];case 4:return[2]}})})},e.prototype._pinpointSendStopSession=function(e,t){if(Rr){var i=this._generateBatchItemContext(e),r=this._config.region,n=i.ApplicationId,s=i.EventsRequest,o={secret_key:this._config.credentials.secretAccessKey,access_key:this._config.credentials.accessKeyId,session_token:this._config.credentials.sessionToken},a="https://pinpoint."+r+".amazonaws.com/v1/apps/"+n+"/events/legacy",l=JSON.stringify(s),c={url:a,body:l,method:"POST"},u={region:r,service:"mobiletargeting"},h=qt.signUrl(c,o,u,null);return navigator.sendBeacon(h,l)?t.resolve("sendBeacon success"):t.reject("sendBeacon failure")}this._pinpointPutEvents(e,t)},e.prototype._retry=function(e,t){var i=e.config.resendLimit;e.resendLimit="number"==typeof e.resendLimit?e.resendLimit:i,e.resendLimit-- >0?(br.debug("resending event "+e.eventName+" with "+e.resendLimit+" retry times left"),this._pinpointPutEvents(e,t)):br.debug("retry times used up for event "+e.eventName)},e.prototype._updateEndpoint=function(e){return vr(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,c,u,h,d;return Cr(this,function(p){switch(p.label){case 0:t=e.params,i=e.handlers,r=t.config,n=t.event,s=r.appId,o=r.endpointId,a=this._endpointRequest(r,Yt.JS.transferKeyToLowerCase(n,[],["attributes","userAttributes","Attributes","UserAttributes"])),l={ApplicationId:s,EndpointId:o,EndpointRequest:a},p.label=1;case 1:return p.trys.push([1,3,,4]),c=new _i(l),[4,this.pinpointClient.send(c)];case 2:return u=p.sent(),br.debug("updateEndpoint success",u),this._endpointGenerating=!1,this._resumeBuffer(),i.resolve(u),[2];case 3:return h=p.sent(),d={err:h,update_params:l,endpointObject:e},[2,this._handleEndpointUpdateFailure(d)];case 4:return[2]}})})},e.prototype._handleEndpointUpdateFailure=function(e){return vr(this,void 0,void 0,function(){var t,i,r;return Cr(this,function(n){return t=e.err,i=e.endpointObject,r=t.$metadata&&t.$metadata.httpStatusCode,br.debug("updateEndpoint error",t),403===r?[2,this._handleEndpointUpdateForbidden(e)]:Er.includes(r)?[2,this._retryEndpointUpdate(i,!0)]:(br.error("updateEndpoint failed",t),i.handlers.reject(t),[2])})})},e.prototype._handleEndpointUpdateForbidden=function(e){var t=e.err,i=e.endpointObject,r=t.code,n=t.retryable;if("ExpiredTokenException"!==r&&!n)return i.handlers.reject(t);this._retryEndpointUpdate(i)},e.prototype._retryEndpointUpdate=function(e,t){void 0===t&&(t=!1),br.debug("_retryEndpointUpdate",e);var i=e.params,r=i.config.resendLimit;if(i.resendLimit="number"==typeof i.resendLimit?i.resendLimit:r,i.resendLimit-- >0)return br.debug("resending endpoint update "+i.event.eventId+" with "+i.resendLimit+" retry attempts remaining"),void(this._endpointBuffer.length?this._endpointBuffer.unshift(e):this._updateEndpoint(e));br.warn("resending endpoint update "+i.event.eventId+" failed after "+i.config.resendLimit+" attempts"),this._endpointGenerating&&br.error("Initial endpoint update failed. ")},e.prototype._initClients=function(e){return vr(this,void 0,void 0,function(){var t,i;return Cr(this,function(r){return br.debug("init clients"),this.pinpointClient&&this._config.credentials&&this._config.credentials.sessionToken===e.sessionToken&&this._config.credentials.identityId===e.identityId?(br.debug("no change for aws credentials, directly return from init"),[2]):(t=this._config.credentials?this._config.credentials.identityId:null,this._config.credentials=e,i=this._config.region,br.debug("init clients with credentials",e),this.pinpointClient=new Xi({region:i,credentials:e,customUserAgent:(0,Qt.fE)()}),this.pinpointClient.middlewareStack.addRelativeTo(function(e){return function(t){return delete t.request.headers["amz-sdk-invocation-id"],delete t.request.headers["amz-sdk-request"],e(t)}},{step:"finalizeRequest",relation:"after",toMiddleware:"retryMiddleware"}),this._bufferExists()&&t===e.identityId?this._updateBufferClient():this._initBuffer(),this._customizePinpointClientReq(),[2])})})},e.prototype._bufferExists=function(){return this._buffer&&this._buffer instanceof fr},e.prototype._initBuffer=function(){this._bufferExists()&&this._flushBuffer(),this._buffer=new fr(this.pinpointClient,this._config),this._endpointGenerating&&this._buffer.pause()},e.prototype._updateBufferClient=function(){this._bufferExists()&&this._buffer.updateClient(this.pinpointClient)},e.prototype._flushBuffer=function(){this._bufferExists()&&(this._buffer.flush(),this._buffer=null)},e.prototype._resumeBuffer=function(){this._bufferExists()&&this._buffer.resume()},e.prototype._customizePinpointClientReq=function(){},e.prototype._getEndpointId=function(e){return vr(this,void 0,void 0,function(){var t,i;return Cr(this,function(r){switch(r.label){case 0:return[4,cr.getItem(e)];case 1:return t=r.sent(),br.debug("endpointId from cache",t,"type",typeof t),t||(t=(0,ur.v1)(),i=(new Date).getTime()+31536e8,cr.setItem(e,t,{expires:i,priority:1})),[2,t]}})})},e.prototype._endpointRequest=function(e,t){var i=e.credentials,r=this._clientInfo||{},n=e.clientContext||{},s=e.endpoint||{},o={appVersion:r.appVersion,make:r.make,model:r.model,modelVersion:r.version,platform:r.platform},a=(n.clientId,n.appTitle,n.appVersionName,n.appVersionCode,n.appPackageName,yr(n,["clientId","appTitle","appVersionName","appVersionCode","appPackageName"])),l=t.address?"android"===r.platform?"GCM":"APNS":void 0,c=mr(mr(mr({channelType:l,requestId:(0,ur.v1)(),effectiveDate:(new Date).toISOString()},s),t),{attributes:mr(mr({},s.attributes),t.attributes),demographic:mr(mr(mr(mr({},o),a),s.demographic),t.demographic),location:mr(mr({},s.location),t.location),metrics:mr(mr({},s.metrics),t.metrics),user:{userId:t.userId||s.userId||i.identityId,userAttributes:mr(mr({},s.userAttributes),t.userAttributes)}}),u=(c.userId,c.userAttributes,c.name,c.session,c.eventId,c.immediate,yr(c,["userId","userAttributes","name","session","eventId","immediate"]));return Yt.JS.transferKeyToUpperCase(u,[],["metrics","userAttributes","attributes"])},e.prototype._eventError=function(e){br.error("record event failed.",e),br.warn('Please ensure you have updated your Pinpoint IAM Policy with the Action: "mobiletargeting:PutEvents" in order to record events')},e.prototype._getCredentials=function(){return vr(this,void 0,void 0,function(){var e,t;return Cr(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,Xt.Ji.get()];case 1:return(e=i.sent())?(br.debug("set credentials for analytics",e),[2,Xt.Ji.shear(e)]):[2,null];case 2:return t=i.sent(),br.debug("ensure credentials error",t),[2,null];case 3:return[2]}})})},e.category="Analytics",e.providerName="AWSPinpoint",e}(),Pr=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},xr=[],Dr=function(){function e(e,t){this.context=e,this.methodName=t,this._originalMethod=e[t].bind(e)}return e.add=function(e,t,i){Ir(e,t).set(i)},e.remove=function(e,t){Ir(e,t).remove()},e.prototype.set=function(e){var t=this;this.context[this.methodName]=function(){for(var i=[],r=0;r<arguments.length;r++)i[r]=arguments[r];return e(t._originalMethod.apply(t,function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(Pr(arguments[t]));return e}(i)))}},e.prototype.remove=function(){this.context[this.methodName]=this._originalMethod},e}();function Ir(e,t){var i=xr.filter(function(i){return i.context===e&&i.methodName===t})[0];return i||(i=new Dr(e,t),xr.push(i)),i}var Lr=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},Nr=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},Or=new r.C("PageViewTracker"),Fr="aws-amplify-analytics-prevUrl",kr={enable:!1,provider:"AWSPinpoint",getUrl:function(){return Yt.JS.browserOrNode().isBrowser?window.location.origin+window.location.pathname:""}},Gr=function(){function e(e,t){Or.debug("initialize pageview tracker with opts",t),this._config=Object.assign({},kr,t),this._tracker=e,this._hasEnabled=!1,this._trackFunc=this._trackFunc.bind(this),"SPA"===this._config.type?this._pageViewTrackSPA():this._pageViewTrackDefault()}return e.prototype.configure=function(e){return Object.assign(this._config,e),"SPA"===this._config.type&&this._pageViewTrackSPA(),this._config},e.prototype._isSameUrl=function(){return sessionStorage.getItem(Fr)===this._config.getUrl()&&(Or.debug("the url is same"),!0)},e.prototype._pageViewTrackDefault=function(){return Lr(this,void 0,void 0,function(){var e,t,i,r;return Nr(this,function(n){switch(n.label){case 0:return Yt.JS.browserOrNode().isBrowser&&window.addEventListener&&window.sessionStorage?(e=this._config.getUrl(),"function"!=typeof this._config.attributes?[3,2]:[4,this._config.attributes()]):(Or.debug("not in the supported web enviroment"),[2]);case 1:return i=n.sent(),[3,3];case 2:i=this._config.attributes,n.label=3;case 3:return t=i,r=Object.assign({url:e},t),this._config.enable&&!this._isSameUrl()&&(this._tracker({name:this._config.eventName||"pageView",attributes:r},this._config.provider).catch(function(e){Or.debug("Failed to record the page view event",e)}),sessionStorage.setItem(Fr,e)),[2]}})})},e.prototype._trackFunc=function(){return Lr(this,void 0,void 0,function(){var e,t,i,r;return Nr(this,function(n){switch(n.label){case 0:return Yt.JS.browserOrNode().isBrowser&&window.addEventListener&&history.pushState&&window.sessionStorage?(e=this._config.getUrl(),"function"!=typeof this._config.attributes?[3,2]:[4,this._config.attributes()]):(Or.debug("not in the supported web enviroment"),[2]);case 1:return i=n.sent(),[3,3];case 2:i=this._config.attributes,n.label=3;case 3:return t=i,r=Object.assign({url:e},t),this._isSameUrl()||(this._tracker({name:this._config.eventName||"pageView",attributes:r},this._config.provider).catch(function(e){Or.debug("Failed to record the page view event",e)}),sessionStorage.setItem(Fr,e)),[2]}})})},e.prototype._pageViewTrackSPA=function(){Yt.JS.browserOrNode().isBrowser&&window.addEventListener&&history.pushState?this._config.enable&&!this._hasEnabled?(Dr.add(history,"pushState",this._trackFunc),Dr.add(history,"replaceState",this._trackFunc),window.addEventListener("popstate",this._trackFunc),this._trackFunc(),this._hasEnabled=!0):(Dr.remove(history,"pushState"),Dr.remove(history,"replaceState"),window.removeEventListener("popstate",this._trackFunc),this._hasEnabled=!1):Or.debug("not in the supported web enviroment")},e}();const Vr=Gr;var Hr=Yt.JS.browserOrNode().isBrowser&&window.Element?window.Element.prototype:null,Br=Hr?Hr.matches||Hr.matchesSelector||Hr.webkitMatchesSelector||Hr.mozMatchesSelector||Hr.msMatchesSelector||Hr.oMatchesSelector:null;function zr(e,t){if(e&&1===e.nodeType&&t){if("string"==typeof t||1===t.nodeType)return e===t||Ur(e,t);if("length"in t)for(var i=0,r=void 0;r=t[i];i++)if(e===r||Ur(e,r))return!0}return!1}function Ur(e,t){if("string"!=typeof t)return!1;if(Br)return Br.call(e,t);for(var i=e.parentNode.querySelectorAll(t),r=0,n=void 0;n=i[r];r++)if(n===e)return!0;return!1}var Wr=new r.C("EventTracker"),jr={enable:!1,events:["click"],selectorPrefix:"data-amplify-analytics-",provider:"AWSPinpoint"};const Kr=function(){function e(e,t){Yt.JS.browserOrNode().isBrowser&&window.addEventListener?(this._config=Object.assign({},jr,t),this._tracker=e,this._delegates={},this._trackFunc=this._trackFunc.bind(this),Wr.debug("initialize pageview tracker with opts",this._config),this.configure(this._config)):Wr.debug("not in the supported web environment")}return e.prototype.configure=function(e){var t=this;if(Object.assign(this._config,e),this._config.enable){if(this._config.enable&&0===Object.keys(this._delegates).length){var i="["+this._config.selectorPrefix+"on]";this._config.events.forEach(function(e){t._delegates[e]=function(e,t,i,r,n){void 0===n&&(n={});var s=function(e){var t;if(n.composed&&"function"==typeof e.composedPath)for(var s=e.composedPath(),o=0,a=void 0;a=s[o];o++)1===a.nodeType&&zr(a,i)&&(t=a);else t=function(e,t,i){if(void 0===i&&(i=!1),e&&1===e.nodeType&&t)for(var r,n=(i?[e]:[]).concat(function(e){for(var t=[],i=e;i&&i.parentNode&&1===i.parentNode.nodeType;)i=i.parentNode,t.push(i);return t}(e)),s=0;r=n[s];s++)if(zr(r,t))return r}(e.target,i,!0);t&&r.call(t,e,t)};return e.addEventListener(t,s,n.useCapture),{destroy:function(){e.removeEventListener(t,s,n.useCapture)}}}(document,e,i,t._trackFunc,{composed:!0,useCapture:!0})})}}else Object.keys(this._delegates).forEach(function(e){"function"==typeof t._delegates[e].destroy&&t._delegates[e].destroy()}),this._delegates={};return this._config},e.prototype._trackFunc=function(e,t){return i=this,r=void 0,s=function(){var i,r,n,s,o,a,l;return function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}(this,function(c){switch(c.label){case 0:return i={},r=t.getAttribute(this._config.selectorPrefix+"on").split(/\s*,\s*/),n=t.getAttribute(this._config.selectorPrefix+"name"),(s=t.getAttribute(this._config.selectorPrefix+"attrs"))&&s.split(/\s*,\s*/).forEach(function(e){var t=e.trim().split(/\s*:\s*/);i[t[0]]=t[1]}),"function"!=typeof this._config.attributes?[3,2]:[4,this._config.attributes()];case 1:return a=c.sent(),[3,3];case 2:a=this._config.attributes,c.label=3;case 3:return o=a,l=Object.assign({type:e.type,target:e.target.localName+" with id "+e.target.id},o,i),Wr.debug("events needed to be recorded",r),Wr.debug("attributes needed to be attached",i),r.indexOf(e.type)<0?(Wr.debug("event "+e.type+" is not selected to be recorded"),[2]):(this._tracker({name:n||"event",attributes:l},this._config.provider).catch(function(t){Wr.debug("Failed to record the "+e.type+" event', "+t)}),[2])}})},new((n=void 0)||(n=Promise))(function(e,t){function o(e){try{l(s.next(e))}catch(e){t(e)}}function a(e){try{l(s.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof n?i:new n(function(e){e(i)})).then(o,a)}l((s=s.apply(i,r||[])).next())});var i,r,n,s},e}();var $r=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},qr=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},Yr=new r.C("SessionTracker"),Qr={enable:!1,provider:"AWSPinpoint"},Xr=!1;const Zr=function(){function e(e,t){this._config=Object.assign({},Qr,t),this._tracker=e,this._hasEnabled=!1,this._trackFunc=this._trackFunc.bind(this),this._trackBeforeUnload=this._trackBeforeUnload.bind(this),this.configure(this._config)}return e.prototype._envCheck=function(){if(!Yt.JS.browserOrNode().isBrowser)return!1;if(!document||!document.addEventListener)return Yr.debug("not in the supported web environment"),!1;if(void 0!==document.hidden)this._hidden="hidden",this._visibilityChange="visibilitychange";else if(void 0!==document.msHidden)this._hidden="msHidden",this._visibilityChange="msvisibilitychange";else{if(void 0===document.webkitHidden)return Yr.debug("not in the supported web environment"),!1;this._hidden="webkitHidden",this._visibilityChange="webkitvisibilitychange"}return!0},e.prototype._trackFunc=function(){return $r(this,void 0,void 0,function(){var e,t,i;return qr(this,function(r){switch(r.label){case 0:return"function"!=typeof this._config.attributes?[3,2]:[4,this._config.attributes()];case 1:return t=r.sent(),[3,3];case 2:t=this._config.attributes,r.label=3;case 3:return e=t,i=Object.assign({},e),document.visibilityState===this._hidden?this._tracker({name:"_session.stop",attributes:i},this._config.provider).catch(function(e){Yr.debug("record session stop event failed.",e)}):this._tracker({name:"_session.start",attributes:i},this._config.provider).catch(function(e){Yr.debug("record session start event failed.",e)}),[2]}})})},e.prototype._trackBeforeUnload=function(e){var t=this;("function"==typeof this._config.attributes?Promise.resolve(this._config.attributes()):Promise.resolve(this._config.attributes)).then(function(e){var i=Object.assign({},e);t._tracker({name:"_session.stop",attributes:i,immediate:!0},t._config.provider).catch(function(e){Yr.debug("record session stop event failed.",e)})})},e.prototype._sendInitialEvent=function(){return $r(this,void 0,void 0,function(){var e,t,i;return qr(this,function(r){switch(r.label){case 0:return Xr?(Yr.debug("the start session has been sent when the page is loaded"),[2]):(Xr=!0,"function"!=typeof this._config.attributes?[3,2]:[4,this._config.attributes()]);case 1:return t=r.sent(),[3,3];case 2:t=this._config.attributes,r.label=3;case 3:return e=t,i=Object.assign({},e),this._tracker({name:"_session.start",attributes:i},this._config.provider).catch(function(e){Yr.debug("record session start event failed.",e)}),[2]}})})},e.prototype.configure=function(e){return this._envCheck()?(Object.assign(this._config,e),this._config.enable&&!this._hasEnabled?(this._sendInitialEvent(),document.addEventListener(this._visibilityChange,this._trackFunc,!1),window.addEventListener("beforeunload",this._trackBeforeUnload,!1),this._hasEnabled=!0):!this._config.enable&&this._hasEnabled&&(document.removeEventListener(this._visibilityChange,this._trackFunc,!1),window.removeEventListener("beforeunload",this._trackBeforeUnload,!1),this._hasEnabled=!1),this._config):this._config},e}();var Jr=function(){return Jr=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Jr.apply(this,arguments)},en=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},tn=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},rn=new r.C("AnalyticsClass"),nn="undefined"!=typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("amplify_default"):"@@amplify_default",sn={pageView:Vr,event:Kr,session:Zr},on=null,an=function(){function e(){this._config={},this._pluggables=[],this._disabled=!1,this._trackers={},on=this,this.record=this.record.bind(this),n.YZ.listen("auth",hn),n.YZ.listen("storage",hn),n.YZ.listen("analytics",hn)}return e.prototype.getModuleName=function(){return"Analytics"},e.prototype.configure=function(e){var t=this;if(!e)return this._config;rn.debug("configure Analytics",e);var i=s.iX.parseMobilehubConfig(e);return this._config=Object.assign({},this._config,i.Analytics,e),this._config.disabled&&(this._disabled=!0),void 0===this._config.autoSessionRecord&&(this._config.autoSessionRecord=!0),this._pluggables.forEach(function(e){var i="AWSPinpoint"!==e.getProviderName()||t._config.AWSPinpoint?t._config[e.getProviderName()]:t._config;e.configure(Jr({disabled:t._config.disabled,autoSessionRecord:t._config.autoSessionRecord},i))}),0===this._pluggables.length&&this.addPluggable(new _r),n.YZ.dispatch("analytics",{event:"configured",data:null,message:"The Analytics category has been configured successfully"},"Analytics",nn),rn.debug("current configuration",this._config),this._config},e.prototype.addPluggable=function(e){if(e&&"Analytics"===e.getCategory()){this._pluggables.push(e);var t="AWSPinpoint"!==e.getProviderName()||this._config.AWSPinpoint?this._config[e.getProviderName()]:this._config,i=Jr({disabled:this._config.disabled},t);return e.configure(i),i}},e.prototype.getPluggable=function(e){for(var t=0;t<this._pluggables.length;t+=1){var i=this._pluggables[t];if(i.getProviderName()===e)return i}return rn.debug("No plugin found with providerName",e),null},e.prototype.removePluggable=function(e){for(var t=0;t<this._pluggables.length&&this._pluggables[t].getProviderName()!==e;)t+=1;return t===this._pluggables.length?void rn.debug("No plugin found with providerName",e):void this._pluggables.splice(t,t+1)},e.prototype.disable=function(){this._disabled=!0},e.prototype.enable=function(){this._disabled=!1},e.prototype.startSession=function(e){return en(this,void 0,void 0,function(){var t;return tn(this,function(i){return t={event:{name:"_session.start"},provider:e},[2,this._sendEvent(t)]})})},e.prototype.stopSession=function(e){return en(this,void 0,void 0,function(){var t;return tn(this,function(i){return t={event:{name:"_session.stop"},provider:e},[2,this._sendEvent(t)]})})},e.prototype.record=function(e,t,i){return en(this,void 0,void 0,function(){var r;return tn(this,function(n){return null,r="string"==typeof e?{event:{name:e,attributes:t,metrics:i},provider:"AWSPinpoint"}:{event:e,provider:t},[2,this._sendEvent(r)]})})},e.prototype.updateEndpoint=function(e,t){return en(this,void 0,void 0,function(){var i;return tn(this,function(r){return i=Jr(Jr({},e),{name:"_update_endpoint"}),[2,this.record(i,t)]})})},e.prototype._sendEvent=function(e){var t=this;if(this._disabled)return rn.debug("Analytics has been disabled"),Promise.resolve();var i=e.provider?e.provider:"AWSPinpoint";return new Promise(function(r,n){t._pluggables.forEach(function(t){t.getProviderName()===i&&t.record(e,{resolve:r,reject:n})})})},e.prototype.autoTrack=function(e,t){if(sn[e]){"session"===e&&(this._config.autoSessionRecord=t.enable);var i=this._trackers[e];i?i.configure(t):this._trackers[e]=new sn[e](this.record,t)}else rn.debug("invalid tracker type")},e}(),ln=!1,cn=!1,un=!1,hn=function(e){var t=e.channel,i=e.payload;switch(rn.debug("on hub capsule "+t,i),t){case"auth":pn(i);break;case"storage":dn(i);break;case"analytics":gn(i)}},dn=function(e){var t=e.data,i=t.attrs,r=t.metrics;i&&un&&on.record({name:"Storage",attributes:i,metrics:r}).catch(function(e){rn.debug("Failed to send the storage event automatically",e)})},pn=function(e){var t=e.event;if(t){var i=function(e){return en(void 0,void 0,void 0,function(){var t;return tn(this,function(i){switch(i.label){case 0:if(!cn||!un)return[3,4];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,on.record({name:"_userauth."+e})];case 2:return[2,i.sent()];case 3:return t=i.sent(),rn.debug("Failed to send the "+e+" event automatically",t),[3,4];case 4:return[2]}})})};switch(t){case"signIn":return i("sign_in");case"signUp":return i("sign_up");case"signOut":return i("sign_out");case"signIn_failure":return i("auth_fail");case"configured":(cn=!0)&&un&&fn()}}},gn=function(e){var t=e.event;t&&"pinpointProvider_configured"===t&&(un=!0,cn&&un&&fn())},fn=function(){var e=on.configure();!ln&&e.autoSessionRecord&&(on.updateEndpoint({immediate:!0}).catch(function(e){rn.debug("Failed to update the endpoint",e)}),ln=!0),on.autoTrack("session",{enable:e.autoSessionRecord})},mn=new an;o.HA.register(mn)},27021(e,t,i){"use strict";var r,n,s;function o(e){return e&&!!["provider"].find(function(t){return e.hasOwnProperty(t)})}function a(e){return void 0!==e.redirectSignIn}i.d(t,{N:()=>Qe}),function(e){e.Cognito="COGNITO",e.Google="Google",e.Facebook="Facebook",e.Amazon="LoginWithAmazon",e.Apple="SignInWithApple"}(r||(r={})),function(e){e.NoConfig="noConfig",e.MissingAuthConfig="missingAuthConfig",e.EmptyUsername="emptyUsername",e.InvalidUsername="invalidUsername",e.EmptyPassword="emptyPassword",e.EmptyCode="emptyCode",e.SignUpError="signUpError",e.NoMFA="noMFA",e.InvalidMFA="invalidMFA",e.EmptyChallengeResponse="emptyChallengeResponse",e.NoUserSession="noUserSession",e.Default="default",e.DeviceConfig="deviceConfig",e.NetworkError="networkError",e.AutoSignInError="autoSignInError"}(n||(n={})),function(e){e.API_KEY="API_KEY",e.AWS_IAM="AWS_IAM",e.OPENID_CONNECT="OPENID_CONNECT",e.AMAZON_COGNITO_USER_POOLS="AMAZON_COGNITO_USER_POOLS",e.AWS_LAMBDA="AWS_LAMBDA"}(s||(s={}));var l,c=i(15567),u=i(51718),h=i(11351),d=i(410),p=i(12599),g=i(51678),f=(0,g.gy)().isBrowser,m=function(){function e(e){void 0===e&&(e={}),this.cookies=new p.A,this.store=f?window.localStorage:Object.create(null),this.cookies=e.req?new p.A(e.req.headers.cookie):new p.A,Object.assign(this.store,this.cookies.getAll())}return Object.defineProperty(e.prototype,"length",{get:function(){return Object.entries(this.store).length},enumerable:!0,configurable:!0}),e.prototype.clear=function(){var e=this;Array.from(new Array(this.length)).map(function(t,i){return e.key(i)}).forEach(function(t){return e.removeItem(t)})},e.prototype.getItem=function(e){return this.getLocalItem(e)},e.prototype.getLocalItem=function(e){return Object.prototype.hasOwnProperty.call(this.store,e)?this.store[e]:null},e.prototype.getUniversalItem=function(e){return this.cookies.get(e)},e.prototype.key=function(e){return Object.keys(this.store)[e]},e.prototype.removeItem=function(e){this.removeLocalItem(e),this.removeUniversalItem(e)},e.prototype.removeLocalItem=function(e){delete this.store[e]},e.prototype.removeUniversalItem=function(e){this.cookies.remove(e,{path:"/"})},e.prototype.setItem=function(e,t){switch(this.setLocalItem(e,t),e.split(".").pop()){case"LastAuthUser":case"accessToken":case"refreshToken":case"idToken":f?this.setUniversalItem(e,t):this.setLocalItem(e,t)}},e.prototype.setLocalItem=function(e,t){this.store[e]=t},e.prototype.setUniversalItem=function(e,t){this.cookies.set(e,t,{path:"/",sameSite:!0,secure:"localhost"!==window.location.hostname})},e}(),v=i(75315),C=i(78953),y=function(){function e(e){var t=e||{},i=t.ValidationData,r=t.Username,n=t.Password,s=t.AuthParameters,o=t.ClientMetadata;this.validationData=i||{},this.authParameters=s||{},this.clientMetadata=o||{},this.username=r,this.password=n}var t=e.prototype;return t.getUsername=function(){return this.username},t.getPassword=function(){return this.password},t.getValidationData=function(){return this.validationData},t.getAuthParameters=function(){return this.authParameters},t.getClientMetadata=function(){return this.clientMetadata},e}(),w=i(51999),S=i(60095),b=i.n(S),E=(i(74842),i(9331)),A=i.n(E),T=i(31939),M=i.n(T);if("undefined"!=typeof window&&window.crypto&&(l=window.crypto),!l&&"undefined"!=typeof window&&window.msCrypto&&(l=window.msCrypto),!l&&"undefined"!=typeof globalThis&&globalThis.crypto&&(l=globalThis.crypto),!l)try{l=i(55595)}catch(e){}function R(){if(l){if("function"==typeof l.getRandomValues)try{return l.getRandomValues(new Uint32Array(1))[0]}catch(e){}if("function"==typeof l.randomBytes)try{return l.randomBytes(4).readInt32LE()}catch(e){}}throw new Error("Native crypto module could not be used to get secure random number.")}var _=function(){function e(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length}var t=e.prototype;return t.random=function(t){for(var i=[],r=0;r<t;r+=4)i.push(R());return new e(i,t)},t.toString=function(){return function(e){for(var t=e.words,i=e.sigBytes,r=[],n=0;n<i;n++){var s=t[n>>>2]>>>24-n%4*8&255;r.push((s>>>4).toString(16)),r.push((15&s).toString(16))}return r.join("")}(this)},e}();const P=x;function x(e,t){null!=e&&this.fromString(e,t)}function D(){return new x(null)}var I,L="undefined"!=typeof navigator;L&&"Microsoft Internet Explorer"==navigator.appName?(x.prototype.am=function(e,t,i,r,n,s){for(var o=32767&t,a=t>>15;--s>=0;){var l=32767&this[e],c=this[e++]>>15,u=a*l+c*o;n=((l=o*l+((32767&u)<<15)+i[r]+(1073741823&n))>>>30)+(u>>>15)+a*c+(n>>>30),i[r++]=1073741823&l}return n},I=30):L&&"Netscape"!=navigator.appName?(x.prototype.am=function(e,t,i,r,n,s){for(;--s>=0;){var o=t*this[e++]+i[r]+n;n=Math.floor(o/67108864),i[r++]=67108863&o}return n},I=26):(x.prototype.am=function(e,t,i,r,n,s){for(var o=16383&t,a=t>>14;--s>=0;){var l=16383&this[e],c=this[e++]>>14,u=a*l+c*o;n=((l=o*l+((16383&u)<<14)+i[r]+n)>>28)+(u>>14)+a*c,i[r++]=268435455&l}return n},I=28),x.prototype.DB=I,x.prototype.DM=(1<<I)-1,x.prototype.DV=1<<I,x.prototype.FV=Math.pow(2,52),x.prototype.F1=52-I,x.prototype.F2=2*I-52;var N,O,F=new Array;for(N="0".charCodeAt(0),O=0;O<=9;++O)F[N++]=O;for(N="a".charCodeAt(0),O=10;O<36;++O)F[N++]=O;for(N="A".charCodeAt(0),O=10;O<36;++O)F[N++]=O;function k(e){return"0123456789abcdefghijklmnopqrstuvwxyz".charAt(e)}function G(e,t){var i=F[e.charCodeAt(t)];return null==i?-1:i}function V(e){var t=D();return t.fromInt(e),t}function H(e){var t,i=1;return 0!=(t=e>>>16)&&(e=t,i+=16),0!=(t=e>>8)&&(e=t,i+=8),0!=(t=e>>4)&&(e=t,i+=4),0!=(t=e>>2)&&(e=t,i+=2),0!=(t=e>>1)&&(e=t,i+=1),i}function B(e){this.m=e,this.mp=e.invDigit(),this.mpl=32767&this.mp,this.mph=this.mp>>15,this.um=(1<<e.DB-15)-1,this.mt2=2*e.t}function z(e){return w.hp.from((new _).random(e).toString(),"hex")}B.prototype.convert=function(e){var t=D();return e.abs().dlShiftTo(this.m.t,t),t.divRemTo(this.m,null,t),e.s<0&&t.compareTo(x.ZERO)>0&&this.m.subTo(t,t),t},B.prototype.revert=function(e){var t=D();return e.copyTo(t),this.reduce(t),t},B.prototype.reduce=function(e){for(;e.t<=this.mt2;)e[e.t++]=0;for(var t=0;t<this.m.t;++t){var i=32767&e[t],r=i*this.mpl+((i*this.mph+(e[t]>>15)*this.mpl&this.um)<<15)&e.DM;for(e[i=t+this.m.t]+=this.m.am(0,r,e,t,0,this.m.t);e[i]>=e.DV;)e[i]-=e.DV,e[++i]++}e.clamp(),e.drShiftTo(this.m.t,e),e.compareTo(this.m)>=0&&e.subTo(this.m,e)},B.prototype.mulTo=function(e,t,i){e.multiplyTo(t,i),this.reduce(i)},B.prototype.sqrTo=function(e,t){e.squareTo(t),this.reduce(t)},x.prototype.copyTo=function(e){for(var t=this.t-1;t>=0;--t)e[t]=this[t];e.t=this.t,e.s=this.s},x.prototype.fromInt=function(e){this.t=1,this.s=e<0?-1:0,e>0?this[0]=e:e<-1?this[0]=e+this.DV:this.t=0},x.prototype.fromString=function(e,t){var i;if(16==t)i=4;else if(8==t)i=3;else if(2==t)i=1;else if(32==t)i=5;else{if(4!=t)throw new Error("Only radix 2, 4, 8, 16, 32 are supported");i=2}this.t=0,this.s=0;for(var r=e.length,n=!1,s=0;--r>=0;){var o=G(e,r);o<0?"-"==e.charAt(r)&&(n=!0):(n=!1,0==s?this[this.t++]=o:s+i>this.DB?(this[this.t-1]|=(o&(1<<this.DB-s)-1)<<s,this[this.t++]=o>>this.DB-s):this[this.t-1]|=o<<s,(s+=i)>=this.DB&&(s-=this.DB))}this.clamp(),n&&x.ZERO.subTo(this,this)},x.prototype.clamp=function(){for(var e=this.s&this.DM;this.t>0&&this[this.t-1]==e;)--this.t},x.prototype.dlShiftTo=function(e,t){var i;for(i=this.t-1;i>=0;--i)t[i+e]=this[i];for(i=e-1;i>=0;--i)t[i]=0;t.t=this.t+e,t.s=this.s},x.prototype.drShiftTo=function(e,t){for(var i=e;i<this.t;++i)t[i-e]=this[i];t.t=Math.max(this.t-e,0),t.s=this.s},x.prototype.lShiftTo=function(e,t){var i,r=e%this.DB,n=this.DB-r,s=(1<<n)-1,o=Math.floor(e/this.DB),a=this.s<<r&this.DM;for(i=this.t-1;i>=0;--i)t[i+o+1]=this[i]>>n|a,a=(this[i]&s)<<r;for(i=o-1;i>=0;--i)t[i]=0;t[o]=a,t.t=this.t+o+1,t.s=this.s,t.clamp()},x.prototype.rShiftTo=function(e,t){t.s=this.s;var i=Math.floor(e/this.DB);if(i>=this.t)t.t=0;else{var r=e%this.DB,n=this.DB-r,s=(1<<r)-1;t[0]=this[i]>>r;for(var o=i+1;o<this.t;++o)t[o-i-1]|=(this[o]&s)<<n,t[o-i]=this[o]>>r;r>0&&(t[this.t-i-1]|=(this.s&s)<<n),t.t=this.t-i,t.clamp()}},x.prototype.subTo=function(e,t){for(var i=0,r=0,n=Math.min(e.t,this.t);i<n;)r+=this[i]-e[i],t[i++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r-=e.s;i<this.t;)r+=this[i],t[i++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;i<e.t;)r-=e[i],t[i++]=r&this.DM,r>>=this.DB;r-=e.s}t.s=r<0?-1:0,r<-1?t[i++]=this.DV+r:r>0&&(t[i++]=r),t.t=i,t.clamp()},x.prototype.multiplyTo=function(e,t){var i=this.abs(),r=e.abs(),n=i.t;for(t.t=n+r.t;--n>=0;)t[n]=0;for(n=0;n<r.t;++n)t[n+i.t]=i.am(0,r[n],t,n,0,i.t);t.s=0,t.clamp(),this.s!=e.s&&x.ZERO.subTo(t,t)},x.prototype.squareTo=function(e){for(var t=this.abs(),i=e.t=2*t.t;--i>=0;)e[i]=0;for(i=0;i<t.t-1;++i){var r=t.am(i,t[i],e,2*i,0,1);(e[i+t.t]+=t.am(i+1,2*t[i],e,2*i+1,r,t.t-i-1))>=t.DV&&(e[i+t.t]-=t.DV,e[i+t.t+1]=1)}e.t>0&&(e[e.t-1]+=t.am(i,t[i],e,2*i,0,1)),e.s=0,e.clamp()},x.prototype.divRemTo=function(e,t,i){var r=e.abs();if(!(r.t<=0)){var n=this.abs();if(n.t<r.t)return null!=t&&t.fromInt(0),void(null!=i&&this.copyTo(i));null==i&&(i=D());var s=D(),o=this.s,a=e.s,l=this.DB-H(r[r.t-1]);l>0?(r.lShiftTo(l,s),n.lShiftTo(l,i)):(r.copyTo(s),n.copyTo(i));var c=s.t,u=s[c-1];if(0!=u){var h=u*(1<<this.F1)+(c>1?s[c-2]>>this.F2:0),d=this.FV/h,p=(1<<this.F1)/h,g=1<<this.F2,f=i.t,m=f-c,v=null==t?D():t;for(s.dlShiftTo(m,v),i.compareTo(v)>=0&&(i[i.t++]=1,i.subTo(v,i)),x.ONE.dlShiftTo(c,v),v.subTo(s,s);s.t<c;)s[s.t++]=0;for(;--m>=0;){var C=i[--f]==u?this.DM:Math.floor(i[f]*d+(i[f-1]+g)*p);if((i[f]+=s.am(0,C,i,m,0,c))<C)for(s.dlShiftTo(m,v),i.subTo(v,i);i[f]<--C;)i.subTo(v,i)}null!=t&&(i.drShiftTo(c,t),o!=a&&x.ZERO.subTo(t,t)),i.t=c,i.clamp(),l>0&&i.rShiftTo(l,i),o<0&&x.ZERO.subTo(i,i)}}},x.prototype.invDigit=function(){if(this.t<1)return 0;var e=this[0];if(!(1&e))return 0;var t=3&e;return(t=(t=(t=(t=t*(2-(15&e)*t)&15)*(2-(255&e)*t)&255)*(2-((65535&e)*t&65535))&65535)*(2-e*t%this.DV)%this.DV)>0?this.DV-t:-t},x.prototype.addTo=function(e,t){for(var i=0,r=0,n=Math.min(e.t,this.t);i<n;)r+=this[i]+e[i],t[i++]=r&this.DM,r>>=this.DB;if(e.t<this.t){for(r+=e.s;i<this.t;)r+=this[i],t[i++]=r&this.DM,r>>=this.DB;r+=this.s}else{for(r+=this.s;i<e.t;)r+=e[i],t[i++]=r&this.DM,r>>=this.DB;r+=e.s}t.s=r<0?-1:0,r>0?t[i++]=r:r<-1&&(t[i++]=this.DV+r),t.t=i,t.clamp()},x.prototype.toString=function(e){if(this.s<0)return"-"+this.negate().toString(e);var t;if(16==e)t=4;else if(8==e)t=3;else if(2==e)t=1;else if(32==e)t=5;else{if(4!=e)throw new Error("Only radix 2, 4, 8, 16, 32 are supported");t=2}var i,r=(1<<t)-1,n=!1,s="",o=this.t,a=this.DB-o*this.DB%t;if(o-- >0)for(a<this.DB&&(i=this[o]>>a)>0&&(n=!0,s=k(i));o>=0;)a<t?(i=(this[o]&(1<<a)-1)<<t-a,i|=this[--o]>>(a+=this.DB-t)):(i=this[o]>>(a-=t)&r,a<=0&&(a+=this.DB,--o)),i>0&&(n=!0),n&&(s+=k(i));return n?s:"0"},x.prototype.negate=function(){var e=D();return x.ZERO.subTo(this,e),e},x.prototype.abs=function(){return this.s<0?this.negate():this},x.prototype.compareTo=function(e){var t=this.s-e.s;if(0!=t)return t;var i=this.t;if(0!=(t=i-e.t))return this.s<0?-t:t;for(;--i>=0;)if(0!=(t=this[i]-e[i]))return t;return 0},x.prototype.bitLength=function(){return this.t<=0?0:this.DB*(this.t-1)+H(this[this.t-1]^this.s&this.DM)},x.prototype.mod=function(e){var t=D();return this.abs().divRemTo(e,null,t),this.s<0&&t.compareTo(x.ZERO)>0&&e.subTo(t,t),t},x.prototype.equals=function(e){return 0==this.compareTo(e)},x.prototype.add=function(e){var t=D();return this.addTo(e,t),t},x.prototype.subtract=function(e){var t=D();return this.subTo(e,t),t},x.prototype.multiply=function(e){var t=D();return this.multiplyTo(e,t),t},x.prototype.divide=function(e){var t=D();return this.divRemTo(e,t,null),t},x.prototype.modPow=function(e,t,i){var r,n=e.bitLength(),s=V(1),o=new B(t);if(n<=0)return s;r=n<18?1:n<48?3:n<144?4:n<768?5:6;var a=new Array,l=3,c=r-1,u=(1<<r)-1;if(a[1]=o.convert(this),r>1){var h=D();for(o.sqrTo(a[1],h);l<=u;)a[l]=D(),o.mulTo(h,a[l-2],a[l]),l+=2}var d,p,g=e.t-1,f=!0,m=D();for(n=H(e[g])-1;g>=0;){for(n>=c?d=e[g]>>n-c&u:(d=(e[g]&(1<<n+1)-1)<<c-n,g>0&&(d|=e[g-1]>>this.DB+n-c)),l=r;!(1&d);)d>>=1,--l;if((n-=l)<0&&(n+=this.DB,--g),f)a[d].copyTo(s),f=!1;else{for(;l>1;)o.sqrTo(s,m),o.sqrTo(m,s),l-=2;l>0?o.sqrTo(s,m):(p=s,s=m,m=p),o.mulTo(m,a[d],s)}for(;g>=0&&!(e[g]&1<<n);)o.sqrTo(s,m),p=s,s=m,m=p,--n<0&&(n=this.DB-1,--g)}var v=o.revert(s);return i(null,v),v},x.ZERO=V(0),x.ONE=V(1);var U=/^[89a-f]/i,W=function(){function e(e){this.N=new P("FFFFFFFFFFFFFFFFC90FDAA22168C234C4C6628B80DC1CD129024E088A67CC74020BBEA63B139B22514A08798E3404DDEF9519B3CD3A431B302B0A6DF25F14374FE1356D6D51C245E485B576625E7EC6F44C42E9A637ED6B0BFF5CB6F406B7EDEE386BFB5A899FA5AE9F24117C4B1FE649286651ECE45B3DC2007CB8A163BF0598DA48361C55D39A69163FA8FD24CF5F83655D23DCA3AD961C62F356208552BB9ED529077096966D670C354E4ABC9804F1746C08CA18217C32905E462E36CE3BE39E772C180E86039B2783A2EC07A28FB5C55DF06F4C52C9DE2BCBF6955817183995497CEA956AE515D2261898FA051015728E5A8AAAC42DAD33170D04507A33A85521ABDF1CBA64ECFB850458DBEF0A8AEA71575D060C7DB3970F85A6E1E4C7ABF5AE8CDB0933D71E8C94E04A25619DCEE3D2261AD2EE6BF12FFA06D98A0864D87602733EC86A64521F2B18177B200CBBE117577A615D6C770988C0BAD946E208E24FA074E5AB3143DB5BFCE0FD108E4B82D120A93AD2CAFFFFFFFFFFFFFFFF",16),this.g=new P("2",16),this.k=new P(this.hexHash(""+this.padHex(this.N)+this.padHex(this.g)),16),this.smallAValue=this.generateRandomSmallA(),this.getLargeAValue(function(){}),this.infoBits=w.hp.from("Caldera Derived Key","utf8"),this.poolName=e}var t=e.prototype;return t.getSmallAValue=function(){return this.smallAValue},t.getLargeAValue=function(e){var t=this;this.largeAValue?e(null,this.largeAValue):this.calculateA(this.smallAValue,function(i,r){i&&e(i,null),t.largeAValue=r,e(null,t.largeAValue)})},t.generateRandomSmallA=function(){var e=z(128).toString("hex");return new P(e,16)},t.generateRandomString=function(){return z(40).toString("base64")},t.getRandomPassword=function(){return this.randomPassword},t.getSaltDevices=function(){return this.SaltToHashDevices},t.getVerifierDevices=function(){return this.verifierDevices},t.generateHashDevice=function(e,t,i){var r=this;this.randomPassword=this.generateRandomString();var n=""+e+t+":"+this.randomPassword,s=this.hash(n),o=z(16).toString("hex");this.SaltToHashDevices=this.padHex(new P(o,16)),this.g.modPow(new P(this.hexHash(this.SaltToHashDevices+s),16),this.N,function(e,t){e&&i(e,null),r.verifierDevices=r.padHex(t),i(null,null)})},t.calculateA=function(e,t){var i=this;this.g.modPow(e,this.N,function(e,r){e&&t(e,null),r.mod(i.N).equals(P.ZERO)&&t(new Error("Illegal paramater. A mod N cannot be 0."),null),t(null,r)})},t.calculateU=function(e,t){return this.UHexHash=this.hexHash(this.padHex(e)+this.padHex(t)),new P(this.UHexHash,16)},t.hash=function(e){var t=e instanceof w.hp?b().lib.WordArray.create(e):e,i=A()(t).toString();return new Array(64-i.length).join("0")+i},t.hexHash=function(e){return this.hash(w.hp.from(e,"hex"))},t.computehkdf=function(e,t){var i=b().lib.WordArray.create(w.hp.concat([this.infoBits,w.hp.from(String.fromCharCode(1),"utf8")])),r=e instanceof w.hp?b().lib.WordArray.create(e):e,n=t instanceof w.hp?b().lib.WordArray.create(t):t,s=M()(r,n),o=M()(i,s);return w.hp.from(o.toString(),"hex").slice(0,16)},t.getPasswordAuthenticationKey=function(e,t,i,r,n){var s=this;if(i.mod(this.N).equals(P.ZERO))throw new Error("B cannot be zero.");if(this.UValue=this.calculateU(this.largeAValue,i),this.UValue.equals(P.ZERO))throw new Error("U cannot be zero.");var o=""+this.poolName+e+":"+t,a=this.hash(o),l=new P(this.hexHash(this.padHex(r)+a),16);this.calculateS(l,i,function(e,t){e&&n(e,null);var i=s.computehkdf(w.hp.from(s.padHex(t),"hex"),w.hp.from(s.padHex(s.UValue),"hex"));n(null,i)})},t.calculateS=function(e,t,i){var r=this;this.g.modPow(e,this.N,function(n,s){n&&i(n,null),t.subtract(r.k.multiply(s)).modPow(r.smallAValue.add(r.UValue.multiply(e)),r.N,function(e,t){e&&i(e,null),i(null,t.mod(r.N))})})},t.getNewPasswordRequiredChallengeUserAttributePrefix=function(){return"userAttributes."},t.padHex=function(e){if(!(e instanceof P))throw new Error("Not a BigInteger");var t=e.compareTo(P.ZERO)<0,i=e.abs().toString(16);if(i=i.length%2!=0?"0"+i:i,i=U.test(i)?"00"+i:i,t){var r=i.split("").map(function(e){var t=15&~parseInt(e,16);return"0123456789ABCDEF".charAt(t)}).join("");(i=new P(r,16).add(P.ONE).toString(16)).toUpperCase().startsWith("FF8")&&(i=i.substring(2))}return i},e}(),j=function(){function e(e){this.jwtToken=e||"",this.payload=this.decodePayload()}var t=e.prototype;return t.getJwtToken=function(){return this.jwtToken},t.getExpiration=function(){return this.payload.exp},t.getIssuedAt=function(){return this.payload.iat},t.decodePayload=function(){var e=this.jwtToken.split(".")[1];try{return JSON.parse(w.hp.from(e,"base64").toString("utf8"))}catch(e){return{}}},e}();function K(e,t){return K=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},K(e,t)}var $=function(e){var t,i;function r(t){var i=(void 0===t?{}:t).AccessToken;return e.call(this,i||"")||this}return i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,K(t,i),r}(j);function q(e,t){return q=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},q(e,t)}var Y=function(e){var t,i;function r(t){var i=(void 0===t?{}:t).IdToken;return e.call(this,i||"")||this}return i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,q(t,i),r}(j),Q=function(){function e(e){var t=(void 0===e?{}:e).RefreshToken;this.token=t||""}return e.prototype.getToken=function(){return this.token},e}(),X=i(81716),Z=i.n(X),J=function(){function e(e){var t=void 0===e?{}:e,i=t.IdToken,r=t.RefreshToken,n=t.AccessToken,s=t.ClockDrift;if(null==n||null==i)throw new Error("Id token and Access Token must be present.");this.idToken=i,this.refreshToken=r,this.accessToken=n,this.clockDrift=void 0===s?this.calculateClockDrift():s}var t=e.prototype;return t.getIdToken=function(){return this.idToken},t.getRefreshToken=function(){return this.refreshToken},t.getAccessToken=function(){return this.accessToken},t.getClockDrift=function(){return this.clockDrift},t.calculateClockDrift=function(){return Math.floor(new Date/1e3)-Math.min(this.accessToken.getIssuedAt(),this.idToken.getIssuedAt())},t.isValid=function(){var e=Math.floor(new Date/1e3)-this.clockDrift;return e<this.accessToken.getExpiration()&&e<this.idToken.getExpiration()},e}(),ee=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],te=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],ie=function(){function e(){}return e.prototype.getNowString=function(){var e=new Date,t=te[e.getUTCDay()],i=ee[e.getUTCMonth()],r=e.getUTCDate(),n=e.getUTCHours();n<10&&(n="0"+n);var s=e.getUTCMinutes();s<10&&(s="0"+s);var o=e.getUTCSeconds();return o<10&&(o="0"+o),t+" "+i+" "+r+" "+n+":"+s+":"+o+" UTC "+e.getUTCFullYear()},e}(),re=function(){function e(e){var t=void 0===e?{}:e,i=t.Name,r=t.Value;this.Name=i||"",this.Value=r||""}var t=e.prototype;return t.getValue=function(){return this.Value},t.setValue=function(e){return this.Value=e,this},t.getName=function(){return this.Name},t.setName=function(e){return this.Name=e,this},t.toString=function(){return JSON.stringify(this)},t.toJSON=function(){return{Name:this.Name,Value:this.Value}},e}(),ne={},se=function(){function e(){}return e.setItem=function(e,t){return ne[e]=t,ne[e]},e.getItem=function(e){return Object.prototype.hasOwnProperty.call(ne,e)?ne[e]:void 0},e.removeItem=function(e){return delete ne[e]},e.clear=function(){return ne={}},e}(),oe=function(){function e(){try{this.storageWindow=window.localStorage,this.storageWindow.setItem("aws.cognito.test-ls",1),this.storageWindow.removeItem("aws.cognito.test-ls")}catch(e){this.storageWindow=se}}return e.prototype.getStorage=function(){return this.storageWindow},e}(),ae="undefined"!=typeof navigator?navigator.userAgent:"nodejs",le=function(){function e(e){if(null==e||null==e.Username||null==e.Pool)throw new Error("Username and Pool information are required.");this.username=e.Username||"",this.pool=e.Pool,this.Session=null,this.client=e.Pool.client,this.signInUserSession=null,this.authenticationFlowType="USER_SRP_AUTH",this.storage=e.Storage||(new oe).getStorage(),this.keyPrefix="CognitoIdentityServiceProvider."+this.pool.getClientId(),this.userDataKey=this.keyPrefix+"."+this.username+".userData"}var t=e.prototype;return t.setSignInUserSession=function(e){this.clearCachedUserData(),this.signInUserSession=e,this.cacheTokens()},t.getSignInUserSession=function(){return this.signInUserSession},t.getUsername=function(){return this.username},t.getAuthenticationFlowType=function(){return this.authenticationFlowType},t.setAuthenticationFlowType=function(e){this.authenticationFlowType=e},t.initiateAuth=function(e,t){var i=this,r=e.getAuthParameters();r.USERNAME=this.username;var n=0!==Object.keys(e.getValidationData()).length?e.getValidationData():e.getClientMetadata(),s={AuthFlow:"CUSTOM_AUTH",ClientId:this.pool.getClientId(),AuthParameters:r,ClientMetadata:n};this.getUserContextData()&&(s.UserContextData=this.getUserContextData()),this.client.request("InitiateAuth",s,function(e,r){if(e)return t.onFailure(e);var n=r.ChallengeName,s=r.ChallengeParameters;return"CUSTOM_CHALLENGE"===n?(i.Session=r.Session,t.customChallenge(s)):(i.signInUserSession=i.getCognitoUserSession(r.AuthenticationResult),i.cacheTokens(),t.onSuccess(i.signInUserSession))})},t.authenticateUser=function(e,t){return"USER_PASSWORD_AUTH"===this.authenticationFlowType?this.authenticateUserPlainUsernamePassword(e,t):"USER_SRP_AUTH"===this.authenticationFlowType||"CUSTOM_AUTH"===this.authenticationFlowType?this.authenticateUserDefaultAuth(e,t):t.onFailure(new Error("Authentication flow type is invalid."))},t.authenticateUserDefaultAuth=function(e,t){var i,r,n=this,s=new W(this.pool.getUserPoolName()),o=new ie,a={};null!=this.deviceKey&&(a.DEVICE_KEY=this.deviceKey),a.USERNAME=this.username,s.getLargeAValue(function(l,c){l&&t.onFailure(l),a.SRP_A=c.toString(16),"CUSTOM_AUTH"===n.authenticationFlowType&&(a.CHALLENGE_NAME="SRP_A");var u=0!==Object.keys(e.getValidationData()).length?e.getValidationData():e.getClientMetadata(),h={AuthFlow:n.authenticationFlowType,ClientId:n.pool.getClientId(),AuthParameters:a,ClientMetadata:u};n.getUserContextData(n.username)&&(h.UserContextData=n.getUserContextData(n.username)),n.client.request("InitiateAuth",h,function(a,l){if(a)return t.onFailure(a);var c=l.ChallengeParameters;n.username=c.USER_ID_FOR_SRP,n.userDataKey=n.keyPrefix+"."+n.username+".userData",i=new P(c.SRP_B,16),r=new P(c.SALT,16),n.getCachedDeviceKeyAndPassword(),s.getPasswordAuthenticationKey(n.username,e.getPassword(),i,r,function(e,i){e&&t.onFailure(e);var r=o.getNowString(),a=b().lib.WordArray.create(w.hp.concat([w.hp.from(n.pool.getUserPoolName(),"utf8"),w.hp.from(n.username,"utf8"),w.hp.from(c.SECRET_BLOCK,"base64"),w.hp.from(r,"utf8")])),h=b().lib.WordArray.create(i),d=Z().stringify(M()(a,h)),p={};p.USERNAME=n.username,p.PASSWORD_CLAIM_SECRET_BLOCK=c.SECRET_BLOCK,p.TIMESTAMP=r,p.PASSWORD_CLAIM_SIGNATURE=d,null!=n.deviceKey&&(p.DEVICE_KEY=n.deviceKey);var g={ChallengeName:"PASSWORD_VERIFIER",ClientId:n.pool.getClientId(),ChallengeResponses:p,Session:l.Session,ClientMetadata:u};n.getUserContextData()&&(g.UserContextData=n.getUserContextData()),function e(t,i){return n.client.request("RespondToAuthChallenge",t,function(r,s){return r&&"ResourceNotFoundException"===r.code&&-1!==r.message.toLowerCase().indexOf("device")?(p.DEVICE_KEY=null,n.deviceKey=null,n.randomPassword=null,n.deviceGroupKey=null,n.clearCachedDeviceKeyAndPassword(),e(t,i)):i(r,s)})}(g,function(e,i){return e?t.onFailure(e):n.authenticateUserInternal(i,s,t)})})})})},t.authenticateUserPlainUsernamePassword=function(e,t){var i=this,r={};if(r.USERNAME=this.username,r.PASSWORD=e.getPassword(),r.PASSWORD){var n=new W(this.pool.getUserPoolName());this.getCachedDeviceKeyAndPassword(),null!=this.deviceKey&&(r.DEVICE_KEY=this.deviceKey);var s=0!==Object.keys(e.getValidationData()).length?e.getValidationData():e.getClientMetadata(),o={AuthFlow:"USER_PASSWORD_AUTH",ClientId:this.pool.getClientId(),AuthParameters:r,ClientMetadata:s};this.getUserContextData(this.username)&&(o.UserContextData=this.getUserContextData(this.username)),this.client.request("InitiateAuth",o,function(e,r){return e?t.onFailure(e):i.authenticateUserInternal(r,n,t)})}else t.onFailure(new Error("PASSWORD parameter is required"))},t.authenticateUserInternal=function(e,t,i){var r=this,n=e.ChallengeName,s=e.ChallengeParameters;if("SMS_MFA"===n)return this.Session=e.Session,i.mfaRequired(n,s);if("SELECT_MFA_TYPE"===n)return this.Session=e.Session,i.selectMFAType(n,s);if("MFA_SETUP"===n)return this.Session=e.Session,i.mfaSetup(n,s);if("SOFTWARE_TOKEN_MFA"===n)return this.Session=e.Session,i.totpRequired(n,s);if("CUSTOM_CHALLENGE"===n)return this.Session=e.Session,i.customChallenge(s);if("NEW_PASSWORD_REQUIRED"===n){this.Session=e.Session;var o=null,a=null,l=[],c=t.getNewPasswordRequiredChallengeUserAttributePrefix();if(s&&(o=JSON.parse(e.ChallengeParameters.userAttributes),a=JSON.parse(e.ChallengeParameters.requiredAttributes)),a)for(var u=0;u<a.length;u++)l[u]=a[u].substr(c.length);return i.newPasswordRequired(o,l)}if("DEVICE_SRP_AUTH"===n)return this.Session=e.Session,void this.getDeviceResponse(i);this.signInUserSession=this.getCognitoUserSession(e.AuthenticationResult),this.challengeName=n,this.cacheTokens();var h=e.AuthenticationResult.NewDeviceMetadata;if(null==h)return i.onSuccess(this.signInUserSession);t.generateHashDevice(e.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey,e.AuthenticationResult.NewDeviceMetadata.DeviceKey,function(n){if(n)return i.onFailure(n);var s={Salt:w.hp.from(t.getSaltDevices(),"hex").toString("base64"),PasswordVerifier:w.hp.from(t.getVerifierDevices(),"hex").toString("base64")};r.verifierDevices=s.PasswordVerifier,r.deviceGroupKey=h.DeviceGroupKey,r.randomPassword=t.getRandomPassword(),r.client.request("ConfirmDevice",{DeviceKey:h.DeviceKey,AccessToken:r.signInUserSession.getAccessToken().getJwtToken(),DeviceSecretVerifierConfig:s,DeviceName:ae},function(t,n){return t?i.onFailure(t):(r.deviceKey=e.AuthenticationResult.NewDeviceMetadata.DeviceKey,r.cacheDeviceKeyAndPassword(),!0===n.UserConfirmationNecessary?i.onSuccess(r.signInUserSession,n.UserConfirmationNecessary):i.onSuccess(r.signInUserSession))})})},t.completeNewPasswordChallenge=function(e,t,i,r){var n=this;if(!e)return i.onFailure(new Error("New password is required."));var s=new W(this.pool.getUserPoolName()),o=s.getNewPasswordRequiredChallengeUserAttributePrefix(),a={};t&&Object.keys(t).forEach(function(e){a[o+e]=t[e]}),a.NEW_PASSWORD=e,a.USERNAME=this.username;var l={ChallengeName:"NEW_PASSWORD_REQUIRED",ClientId:this.pool.getClientId(),ChallengeResponses:a,Session:this.Session,ClientMetadata:r};this.getUserContextData()&&(l.UserContextData=this.getUserContextData()),this.client.request("RespondToAuthChallenge",l,function(e,t){return e?i.onFailure(e):n.authenticateUserInternal(t,s,i)})},t.getDeviceResponse=function(e,t){var i=this,r=new W(this.deviceGroupKey),n=new ie,s={};s.USERNAME=this.username,s.DEVICE_KEY=this.deviceKey,r.getLargeAValue(function(o,a){o&&e.onFailure(o),s.SRP_A=a.toString(16);var l={ChallengeName:"DEVICE_SRP_AUTH",ClientId:i.pool.getClientId(),ChallengeResponses:s,ClientMetadata:t,Session:i.Session};i.getUserContextData()&&(l.UserContextData=i.getUserContextData()),i.client.request("RespondToAuthChallenge",l,function(t,s){if(t)return e.onFailure(t);var o=s.ChallengeParameters,a=new P(o.SRP_B,16),l=new P(o.SALT,16);r.getPasswordAuthenticationKey(i.deviceKey,i.randomPassword,a,l,function(t,r){if(t)return e.onFailure(t);var a=n.getNowString(),l=b().lib.WordArray.create(w.hp.concat([w.hp.from(i.deviceGroupKey,"utf8"),w.hp.from(i.deviceKey,"utf8"),w.hp.from(o.SECRET_BLOCK,"base64"),w.hp.from(a,"utf8")])),c=b().lib.WordArray.create(r),u=Z().stringify(M()(l,c)),h={};h.USERNAME=i.username,h.PASSWORD_CLAIM_SECRET_BLOCK=o.SECRET_BLOCK,h.TIMESTAMP=a,h.PASSWORD_CLAIM_SIGNATURE=u,h.DEVICE_KEY=i.deviceKey;var d={ChallengeName:"DEVICE_PASSWORD_VERIFIER",ClientId:i.pool.getClientId(),ChallengeResponses:h,Session:s.Session};i.getUserContextData()&&(d.UserContextData=i.getUserContextData()),i.client.request("RespondToAuthChallenge",d,function(t,r){return t?e.onFailure(t):(i.signInUserSession=i.getCognitoUserSession(r.AuthenticationResult),i.cacheTokens(),e.onSuccess(i.signInUserSession))})})})})},t.confirmRegistration=function(e,t,i,r){var n={ClientId:this.pool.getClientId(),ConfirmationCode:e,Username:this.username,ForceAliasCreation:t,ClientMetadata:r};this.getUserContextData()&&(n.UserContextData=this.getUserContextData()),this.client.request("ConfirmSignUp",n,function(e){return e?i(e,null):i(null,"SUCCESS")})},t.sendCustomChallengeAnswer=function(e,t,i){var r=this,n={};n.USERNAME=this.username,n.ANSWER=e;var s=new W(this.pool.getUserPoolName());this.getCachedDeviceKeyAndPassword(),null!=this.deviceKey&&(n.DEVICE_KEY=this.deviceKey);var o={ChallengeName:"CUSTOM_CHALLENGE",ChallengeResponses:n,ClientId:this.pool.getClientId(),Session:this.Session,ClientMetadata:i};this.getUserContextData()&&(o.UserContextData=this.getUserContextData()),this.client.request("RespondToAuthChallenge",o,function(e,i){return e?t.onFailure(e):r.authenticateUserInternal(i,s,t)})},t.sendMFACode=function(e,t,i,r){var n=this,s={};s.USERNAME=this.username,s.SMS_MFA_CODE=e;var o=i||"SMS_MFA";"SOFTWARE_TOKEN_MFA"===o&&(s.SOFTWARE_TOKEN_MFA_CODE=e),null!=this.deviceKey&&(s.DEVICE_KEY=this.deviceKey);var a={ChallengeName:o,ChallengeResponses:s,ClientId:this.pool.getClientId(),Session:this.Session,ClientMetadata:r};this.getUserContextData()&&(a.UserContextData=this.getUserContextData()),this.client.request("RespondToAuthChallenge",a,function(e,i){if(e)return t.onFailure(e);if("DEVICE_SRP_AUTH"!==i.ChallengeName){if(n.signInUserSession=n.getCognitoUserSession(i.AuthenticationResult),n.cacheTokens(),null==i.AuthenticationResult.NewDeviceMetadata)return t.onSuccess(n.signInUserSession);var r=new W(n.pool.getUserPoolName());r.generateHashDevice(i.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey,i.AuthenticationResult.NewDeviceMetadata.DeviceKey,function(e){if(e)return t.onFailure(e);var s={Salt:w.hp.from(r.getSaltDevices(),"hex").toString("base64"),PasswordVerifier:w.hp.from(r.getVerifierDevices(),"hex").toString("base64")};n.verifierDevices=s.PasswordVerifier,n.deviceGroupKey=i.AuthenticationResult.NewDeviceMetadata.DeviceGroupKey,n.randomPassword=r.getRandomPassword(),n.client.request("ConfirmDevice",{DeviceKey:i.AuthenticationResult.NewDeviceMetadata.DeviceKey,AccessToken:n.signInUserSession.getAccessToken().getJwtToken(),DeviceSecretVerifierConfig:s,DeviceName:ae},function(e,r){return e?t.onFailure(e):(n.deviceKey=i.AuthenticationResult.NewDeviceMetadata.DeviceKey,n.cacheDeviceKeyAndPassword(),!0===r.UserConfirmationNecessary?t.onSuccess(n.signInUserSession,r.UserConfirmationNecessary):t.onSuccess(n.signInUserSession))})})}else n.getDeviceResponse(t)})},t.changePassword=function(e,t,i,r){if(null==this.signInUserSession||!this.signInUserSession.isValid())return i(new Error("User is not authenticated"),null);this.client.request("ChangePassword",{PreviousPassword:e,ProposedPassword:t,AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),ClientMetadata:r},function(e){return e?i(e,null):i(null,"SUCCESS")})},t.enableMFA=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e(new Error("User is not authenticated"),null);var t=[];t.push({DeliveryMedium:"SMS",AttributeName:"phone_number"}),this.client.request("SetUserSettings",{MFAOptions:t,AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(t){return t?e(t,null):e(null,"SUCCESS")})},t.setUserMfaPreference=function(e,t,i){if(null==this.signInUserSession||!this.signInUserSession.isValid())return i(new Error("User is not authenticated"),null);this.client.request("SetUserMFAPreference",{SMSMfaSettings:e,SoftwareTokenMfaSettings:t,AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(e){return e?i(e,null):i(null,"SUCCESS")})},t.disableMFA=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e(new Error("User is not authenticated"),null);this.client.request("SetUserSettings",{MFAOptions:[],AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(t){return t?e(t,null):e(null,"SUCCESS")})},t.deleteUser=function(e,t){var i=this;if(null==this.signInUserSession||!this.signInUserSession.isValid())return e(new Error("User is not authenticated"),null);this.client.request("DeleteUser",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),ClientMetadata:t},function(t){return t?e(t,null):(i.clearCachedUser(),e(null,"SUCCESS"))})},t.updateAttributes=function(e,t,i){var r=this;if(null==this.signInUserSession||!this.signInUserSession.isValid())return t(new Error("User is not authenticated"),null);this.client.request("UpdateUserAttributes",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),UserAttributes:e,ClientMetadata:i},function(e){return e?t(e,null):r.getUserData(function(){return t(null,"SUCCESS")},{bypassCache:!0})})},t.getUserAttributes=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e(new Error("User is not authenticated"),null);this.client.request("GetUser",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(t,i){if(t)return e(t,null);for(var r=[],n=0;n<i.UserAttributes.length;n++){var s={Name:i.UserAttributes[n].Name,Value:i.UserAttributes[n].Value},o=new re(s);r.push(o)}return e(null,r)})},t.getMFAOptions=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e(new Error("User is not authenticated"),null);this.client.request("GetUser",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(t,i){return t?e(t,null):e(null,i.MFAOptions)})},t.createGetUserRequest=function(){return this.client.promisifyRequest("GetUser",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken()})},t.refreshSessionIfPossible=function(e){var t=this;return void 0===e&&(e={}),new Promise(function(i){var r=t.signInUserSession.getRefreshToken();r&&r.getToken()?t.refreshSession(r,i,e.clientMetadata):i()})},t.getUserData=function(e,t){var i=this;if(null==this.signInUserSession||!this.signInUserSession.isValid())return this.clearCachedUserData(),e(new Error("User is not authenticated"),null);var r=this.getUserDataFromCache();if(r)if(this.isFetchUserDataAndTokenRequired(t))this.fetchUserData().then(function(e){return i.refreshSessionIfPossible(t).then(function(){return e})}).then(function(t){return e(null,t)}).catch(e);else try{return void e(null,JSON.parse(r))}catch(t){return this.clearCachedUserData(),void e(t,null)}else this.fetchUserData().then(function(t){e(null,t)}).catch(e)},t.getUserDataFromCache=function(){return this.storage.getItem(this.userDataKey)},t.isFetchUserDataAndTokenRequired=function(e){var t=(e||{}).bypassCache;return void 0!==t&&t},t.fetchUserData=function(){var e=this;return this.createGetUserRequest().then(function(t){return e.cacheUserData(t),t})},t.deleteAttributes=function(e,t){var i=this;if(null==this.signInUserSession||!this.signInUserSession.isValid())return t(new Error("User is not authenticated"),null);this.client.request("DeleteUserAttributes",{UserAttributeNames:e,AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(e){return e?t(e,null):i.getUserData(function(){return t(null,"SUCCESS")},{bypassCache:!0})})},t.resendConfirmationCode=function(e,t){var i={ClientId:this.pool.getClientId(),Username:this.username,ClientMetadata:t};this.client.request("ResendConfirmationCode",i,function(t,i){return t?e(t,null):e(null,i)})},t.getSession=function(e,t){if(void 0===t&&(t={}),null==this.username)return e(new Error("Username is null. Cannot retrieve a new session"),null);if(null!=this.signInUserSession&&this.signInUserSession.isValid())return e(null,this.signInUserSession);var i="CognitoIdentityServiceProvider."+this.pool.getClientId()+"."+this.username,r=i+".idToken",n=i+".accessToken",s=i+".refreshToken",o=i+".clockDrift";if(this.storage.getItem(r)){var a=new Y({IdToken:this.storage.getItem(r)}),l=new $({AccessToken:this.storage.getItem(n)}),c=new Q({RefreshToken:this.storage.getItem(s)}),u=parseInt(this.storage.getItem(o),0)||0,h=new J({IdToken:a,AccessToken:l,RefreshToken:c,ClockDrift:u});if(h.isValid())return this.signInUserSession=h,e(null,this.signInUserSession);if(!c.getToken())return e(new Error("Cannot retrieve a new session. Please authenticate."),null);this.refreshSession(c,e,t.clientMetadata)}else e(new Error("Local storage is missing an ID Token, Please authenticate"),null)},t.refreshSession=function(e,t,i){var r=this,n=this.pool.wrapRefreshSessionCallback?this.pool.wrapRefreshSessionCallback(t):t,s={};s.REFRESH_TOKEN=e.getToken();var o="CognitoIdentityServiceProvider."+this.pool.getClientId(),a=o+".LastAuthUser";if(this.storage.getItem(a)){this.username=this.storage.getItem(a);var l=o+"."+this.username+".deviceKey";this.deviceKey=this.storage.getItem(l),s.DEVICE_KEY=this.deviceKey}var c={ClientId:this.pool.getClientId(),AuthFlow:"REFRESH_TOKEN_AUTH",AuthParameters:s,ClientMetadata:i};this.getUserContextData()&&(c.UserContextData=this.getUserContextData()),this.client.request("InitiateAuth",c,function(t,i){if(t)return"NotAuthorizedException"===t.code&&r.clearCachedUser(),n(t,null);if(i){var s=i.AuthenticationResult;return Object.prototype.hasOwnProperty.call(s,"RefreshToken")||(s.RefreshToken=e.getToken()),r.signInUserSession=r.getCognitoUserSession(s),r.cacheTokens(),n(null,r.signInUserSession)}})},t.cacheTokens=function(){var e="CognitoIdentityServiceProvider."+this.pool.getClientId(),t=e+"."+this.username+".idToken",i=e+"."+this.username+".accessToken",r=e+"."+this.username+".refreshToken",n=e+"."+this.username+".clockDrift",s=e+".LastAuthUser";this.storage.setItem(t,this.signInUserSession.getIdToken().getJwtToken()),this.storage.setItem(i,this.signInUserSession.getAccessToken().getJwtToken()),this.storage.setItem(r,this.signInUserSession.getRefreshToken().getToken()),this.storage.setItem(n,""+this.signInUserSession.getClockDrift()),this.storage.setItem(s,this.username)},t.cacheUserData=function(e){this.storage.setItem(this.userDataKey,JSON.stringify(e))},t.clearCachedUserData=function(){this.storage.removeItem(this.userDataKey)},t.clearCachedUser=function(){this.clearCachedTokens(),this.clearCachedUserData()},t.cacheDeviceKeyAndPassword=function(){var e="CognitoIdentityServiceProvider."+this.pool.getClientId()+"."+this.username,t=e+".deviceKey",i=e+".randomPasswordKey",r=e+".deviceGroupKey";this.storage.setItem(t,this.deviceKey),this.storage.setItem(i,this.randomPassword),this.storage.setItem(r,this.deviceGroupKey)},t.getCachedDeviceKeyAndPassword=function(){var e="CognitoIdentityServiceProvider."+this.pool.getClientId()+"."+this.username,t=e+".deviceKey",i=e+".randomPasswordKey",r=e+".deviceGroupKey";this.storage.getItem(t)&&(this.deviceKey=this.storage.getItem(t),this.randomPassword=this.storage.getItem(i),this.deviceGroupKey=this.storage.getItem(r))},t.clearCachedDeviceKeyAndPassword=function(){var e="CognitoIdentityServiceProvider."+this.pool.getClientId()+"."+this.username,t=e+".deviceKey",i=e+".randomPasswordKey",r=e+".deviceGroupKey";this.storage.removeItem(t),this.storage.removeItem(i),this.storage.removeItem(r)},t.clearCachedTokens=function(){var e="CognitoIdentityServiceProvider."+this.pool.getClientId(),t=e+"."+this.username+".idToken",i=e+"."+this.username+".accessToken",r=e+"."+this.username+".refreshToken",n=e+".LastAuthUser",s=e+"."+this.username+".clockDrift";this.storage.removeItem(t),this.storage.removeItem(i),this.storage.removeItem(r),this.storage.removeItem(n),this.storage.removeItem(s)},t.getCognitoUserSession=function(e){var t=new Y(e),i=new $(e),r=new Q(e);return new J({IdToken:t,AccessToken:i,RefreshToken:r})},t.forgotPassword=function(e,t){var i={ClientId:this.pool.getClientId(),Username:this.username,ClientMetadata:t};this.getUserContextData()&&(i.UserContextData=this.getUserContextData()),this.client.request("ForgotPassword",i,function(t,i){return t?e.onFailure(t):"function"==typeof e.inputVerificationCode?e.inputVerificationCode(i):e.onSuccess(i)})},t.confirmPassword=function(e,t,i,r){var n={ClientId:this.pool.getClientId(),Username:this.username,ConfirmationCode:e,Password:t,ClientMetadata:r};this.getUserContextData()&&(n.UserContextData=this.getUserContextData()),this.client.request("ConfirmForgotPassword",n,function(e){return e?i.onFailure(e):i.onSuccess("SUCCESS")})},t.getAttributeVerificationCode=function(e,t,i){if(null==this.signInUserSession||!this.signInUserSession.isValid())return t.onFailure(new Error("User is not authenticated"));this.client.request("GetUserAttributeVerificationCode",{AttributeName:e,AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),ClientMetadata:i},function(e,i){return e?t.onFailure(e):"function"==typeof t.inputVerificationCode?t.inputVerificationCode(i):t.onSuccess("SUCCESS")})},t.verifyAttribute=function(e,t,i){if(null==this.signInUserSession||!this.signInUserSession.isValid())return i.onFailure(new Error("User is not authenticated"));this.client.request("VerifyUserAttribute",{AttributeName:e,Code:t,AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(e){return e?i.onFailure(e):i.onSuccess("SUCCESS")})},t.getDevice=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e.onFailure(new Error("User is not authenticated"));this.client.request("GetDevice",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),DeviceKey:this.deviceKey},function(t,i){return t?e.onFailure(t):e.onSuccess(i)})},t.forgetSpecificDevice=function(e,t){if(null==this.signInUserSession||!this.signInUserSession.isValid())return t.onFailure(new Error("User is not authenticated"));this.client.request("ForgetDevice",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),DeviceKey:e},function(e){return e?t.onFailure(e):t.onSuccess("SUCCESS")})},t.forgetDevice=function(e){var t=this;this.forgetSpecificDevice(this.deviceKey,{onFailure:e.onFailure,onSuccess:function(i){return t.deviceKey=null,t.deviceGroupKey=null,t.randomPassword=null,t.clearCachedDeviceKeyAndPassword(),e.onSuccess(i)}})},t.setDeviceStatusRemembered=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e.onFailure(new Error("User is not authenticated"));this.client.request("UpdateDeviceStatus",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),DeviceKey:this.deviceKey,DeviceRememberedStatus:"remembered"},function(t){return t?e.onFailure(t):e.onSuccess("SUCCESS")})},t.setDeviceStatusNotRemembered=function(e){if(null==this.signInUserSession||!this.signInUserSession.isValid())return e.onFailure(new Error("User is not authenticated"));this.client.request("UpdateDeviceStatus",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),DeviceKey:this.deviceKey,DeviceRememberedStatus:"not_remembered"},function(t){return t?e.onFailure(t):e.onSuccess("SUCCESS")})},t.listDevices=function(e,t,i){if(null==this.signInUserSession||!this.signInUserSession.isValid())return i.onFailure(new Error("User is not authenticated"));var r={AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),Limit:e};t&&(r.PaginationToken=t),this.client.request("ListDevices",r,function(e,t){return e?i.onFailure(e):i.onSuccess(t)})},t.globalSignOut=function(e){var t=this;if(null==this.signInUserSession||!this.signInUserSession.isValid())return e.onFailure(new Error("User is not authenticated"));this.client.request("GlobalSignOut",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(i){return i?e.onFailure(i):(t.clearCachedUser(),e.onSuccess("SUCCESS"))})},t.signOut=function(e){var t=this;e&&"function"==typeof e?this.getSession(function(i,r){if(i)return e(i);t.revokeTokens(function(i){t.cleanClientData(),e(i)})}):this.cleanClientData()},t.revokeTokens=function(e){if(void 0===e&&(e=function(){}),"function"!=typeof e)throw new Error("Invalid revokeTokenCallback. It should be a function.");if(!this.signInUserSession)return e(new Error("User is not authenticated"));if(!this.signInUserSession.getAccessToken())return e(new Error("No Access token available"));var t=this.signInUserSession.getRefreshToken().getToken(),i=this.signInUserSession.getAccessToken();if(this.isSessionRevocable(i)&&t)return this.revokeToken({token:t,callback:e});e()},t.isSessionRevocable=function(e){if(e&&"function"==typeof e.decodePayload)try{return!!e.decodePayload().origin_jti}catch(e){}return!1},t.cleanClientData=function(){this.signInUserSession=null,this.clearCachedUser()},t.revokeToken=function(e){var t=e.token,i=e.callback;this.client.requestWithRetry("RevokeToken",{Token:t,ClientId:this.pool.getClientId()},function(e){if(e)return i(e);i()})},t.sendMFASelectionAnswer=function(e,t){var i=this,r={};r.USERNAME=this.username,r.ANSWER=e;var n={ChallengeName:"SELECT_MFA_TYPE",ChallengeResponses:r,ClientId:this.pool.getClientId(),Session:this.Session};this.getUserContextData()&&(n.UserContextData=this.getUserContextData()),this.client.request("RespondToAuthChallenge",n,function(r,n){return r?t.onFailure(r):(i.Session=n.Session,"SMS_MFA"===e?t.mfaRequired(n.ChallengeName,n.ChallengeParameters):"SOFTWARE_TOKEN_MFA"===e?t.totpRequired(n.ChallengeName,n.ChallengeParameters):void 0)})},t.getUserContextData=function(){return this.pool.getUserContextData(this.username)},t.associateSoftwareToken=function(e){var t=this;null!=this.signInUserSession&&this.signInUserSession.isValid()?this.client.request("AssociateSoftwareToken",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken()},function(t,i){return t?e.onFailure(t):e.associateSecretCode(i.SecretCode)}):this.client.request("AssociateSoftwareToken",{Session:this.Session},function(i,r){return i?e.onFailure(i):(t.Session=r.Session,e.associateSecretCode(r.SecretCode))})},t.verifySoftwareToken=function(e,t,i){var r=this;null!=this.signInUserSession&&this.signInUserSession.isValid()?this.client.request("VerifySoftwareToken",{AccessToken:this.signInUserSession.getAccessToken().getJwtToken(),UserCode:e,FriendlyDeviceName:t},function(e,t){return e?i.onFailure(e):i.onSuccess(t)}):this.client.request("VerifySoftwareToken",{Session:this.Session,UserCode:e,FriendlyDeviceName:t},function(e,t){if(e)return i.onFailure(e);r.Session=t.Session;var n={};n.USERNAME=r.username;var s={ChallengeName:"MFA_SETUP",ClientId:r.pool.getClientId(),ChallengeResponses:n,Session:r.Session};r.getUserContextData()&&(s.UserContextData=r.getUserContextData()),r.client.request("RespondToAuthChallenge",s,function(e,t){return e?i.onFailure(e):(r.signInUserSession=r.getCognitoUserSession(t.AuthenticationResult),r.cacheTokens(),i.onSuccess(r.signInUserSession))})})},e}(),ce=(i(40061),"aws-amplify/5.0.4"),ue={userAgent:ce+" js",product:"",navigator:null,isReactNative:!1};function he(){}"undefined"!=typeof navigator&&navigator.product&&(ue.product=navigator.product||"",ue.navigator=navigator||null,"ReactNative"===navigator.product?(ue.userAgent=ce+" react-native",ue.isReactNative=!0):(ue.userAgent=ce+" js",ue.isReactNative=!1)),he.prototype.userAgent=ue.userAgent;const de=he;function pe(e){var t="function"==typeof Map?new Map:void 0;return pe=function(e){if(null===e||(i=e,-1===Function.toString.call(i).indexOf("[native code]")))return e;var i;if("function"!=typeof e)throw new TypeError("Super expression must either be null or a function");if(void 0!==t){if(t.has(e))return t.get(e);t.set(e,r)}function r(){return ge(e,arguments,me(this).constructor)}return r.prototype=Object.create(e.prototype,{constructor:{value:r,enumerable:!1,writable:!0,configurable:!0}}),fe(r,e)},pe(e)}function ge(e,t,i){return ge=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(e){return!1}}()?Reflect.construct.bind():function(e,t,i){var r=[null];r.push.apply(r,t);var n=new(Function.bind.apply(e,r));return i&&fe(n,i.prototype),n},ge.apply(null,arguments)}function fe(e,t){return fe=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},fe(e,t)}function me(e){return me=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},me(e)}var ve=function(e){function t(t,i,r,n){var s;return(s=e.call(this,t)||this).code=i,s.name=r,s.statusCode=n,s}return r=e,(i=t).prototype=Object.create(r.prototype),i.prototype.constructor=i,fe(i,r),t;var i,r}(pe(Error)),Ce=function(){function e(e,t,i){this.endpoint=t||"https://cognito-idp."+e+".amazonaws.com/";var r=(i||{}).credentials;this.fetchOptions=r?{credentials:r}:{}}var t=e.prototype;return t.promisifyRequest=function(e,t){var i=this;return new Promise(function(r,n){i.request(e,t,function(e,t){e?n(new ve(e.message,e.code,e.name,e.statusCode)):r(t)})})},t.requestWithRetry=function(e,t,i){var r,n,s=this;(r=[t],n=5e3,void 0===n&&(n=3e5),ye(function(t){return new Promise(function(i,r){s.request(e,t,function(e,t){e?r(e):i(t)})})},r,function(e){return function(t){var i=100*Math.pow(2,t)+100*Math.random();return!(i>e)&&i}}(n))).then(function(e){return i(null,e)}).catch(function(e){return i(e)})},t.request=function(e,t,i){var r,n={"Content-Type":"application/x-amz-json-1.1","X-Amz-Target":"AWSCognitoIdentityProviderService."+e,"X-Amz-User-Agent":de.prototype.userAgent,"Cache-Control":"no-store"},s=Object.assign({},this.fetchOptions,{headers:n,method:"POST",mode:"cors",body:JSON.stringify(t)});fetch(this.endpoint,s).then(function(e){return r=e,e},function(e){if(e instanceof TypeError)throw new Error("Network error");throw e}).then(function(e){return e.json().catch(function(){return{}})}).then(function(e){if(r.ok)return i(null,e);var t=(e.__type||e.code).split("#").pop(),n=new Error(e.message||e.Message||null);return n.name=t,n.code=t,i(n)}).catch(function(e){if(r&&r.headers&&r.headers.get("x-amzn-errortype"))try{var t=r.headers.get("x-amzn-errortype").split(":")[0],n=new Error(r.status?r.status.toString():null);return n.code=t,n.name=t,n.statusCode=r.status,i(n)}catch(t){return i(e)}else e instanceof Error&&"Network error"===e.message&&(e.code="NetworkError");return i(e)})},e}();function ye(e,t,i,r){if(void 0===r&&(r=1),"function"!=typeof e)throw Error("functionToRetry must be a function");return e.name,JSON.stringify(t),e.apply(void 0,t).catch(function(n){if(e.name,(s=n)&&s.nonRetryable)throw e.name,n;var s,o=i(r,t,n);if(e.name,!1!==o)return new Promise(function(e){return setTimeout(e,o)}).then(function(){return ye(e,t,i,r+1)});throw n})}var we=function(){function e(e,t){var i=e||{},r=i.UserPoolId,n=i.ClientId,s=i.endpoint,o=i.fetchOptions,a=i.AdvancedSecurityDataCollectionFlag;if(!r||!n)throw new Error("Both UserPoolId and ClientId are required.");if(r.length>55||!/^[\w-]+_[0-9a-zA-Z]+$/.test(r))throw new Error("Invalid UserPoolId format.");var l=r.split("_")[0];this.userPoolId=r,this.clientId=n,this.client=new Ce(l,s,o),this.advancedSecurityDataCollectionFlag=!1!==a,this.storage=e.Storage||(new oe).getStorage(),t&&(this.wrapRefreshSessionCallback=t)}var t=e.prototype;return t.getUserPoolId=function(){return this.userPoolId},t.getUserPoolName=function(){return this.getUserPoolId().split("_")[1]},t.getClientId=function(){return this.clientId},t.signUp=function(e,t,i,r,n,s){var o=this,a={ClientId:this.clientId,Username:e,Password:t,UserAttributes:i,ValidationData:r,ClientMetadata:s};this.getUserContextData(e)&&(a.UserContextData=this.getUserContextData(e)),this.client.request("SignUp",a,function(t,i){if(t)return n(t,null);var r={Username:e,Pool:o,Storage:o.storage},s={user:new le(r),userConfirmed:i.UserConfirmed,userSub:i.UserSub,codeDeliveryDetails:i.CodeDeliveryDetails};return n(null,s)})},t.getCurrentUser=function(){var e="CognitoIdentityServiceProvider."+this.clientId+".LastAuthUser",t=this.storage.getItem(e);if(t){var i={Username:t,Pool:this,Storage:this.storage};return new le(i)}return null},t.getUserContextData=function(e){if("undefined"!=typeof AmazonCognitoAdvancedSecurityData){var t=AmazonCognitoAdvancedSecurityData;if(this.advancedSecurityDataCollectionFlag){var i=t.getData(e,this.userPoolId,this.clientId);if(i)return{EncodedData:i}}return{}}},e}(),Se=i(97351),be=function(){function e(e){if(!e.domain)throw new Error("The domain of cookieStorage can not be undefined.");if(this.domain=e.domain,e.path?this.path=e.path:this.path="/",Object.prototype.hasOwnProperty.call(e,"expires")?this.expires=e.expires:this.expires=365,Object.prototype.hasOwnProperty.call(e,"secure")?this.secure=e.secure:this.secure=!0,Object.prototype.hasOwnProperty.call(e,"sameSite")){if(!["strict","lax","none"].includes(e.sameSite))throw new Error('The sameSite value of cookieStorage must be "lax", "strict" or "none".');if("none"===e.sameSite&&!this.secure)throw new Error("sameSite = None requires the Secure attribute in latest browser versions.");this.sameSite=e.sameSite}else this.sameSite=null}var t=e.prototype;return t.setItem=function(e,t){var i={path:this.path,expires:this.expires,domain:this.domain,secure:this.secure};return this.sameSite&&(i.sameSite=this.sameSite),Se.set(e,t,i),Se.get(e)},t.getItem=function(e){return Se.get(e)},t.removeItem=function(e){var t={path:this.path,expires:this.expires,domain:this.domain,secure:this.secure};return this.sameSite&&(t.sameSite=this.sameSite),Se.remove(e,t)},t.clear=function(){for(var e=Se.get(),t=Object.keys(e).length,i=0;i<t;++i)this.removeItem(Object.keys(e)[i]);return{}},e}(),Ee=i(71481),Ae=function(e){var t=window.open(e,"_self");return t?Promise.resolve(t):Promise.reject()},Te=function(){return Te=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Te.apply(this,arguments)},Me=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},Re=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},_e=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},Pe="undefined"!=typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("amplify_default"):"@@amplify_default",xe=function(e,t,i){u.YZ.dispatch("auth",{event:e,data:t,message:i},"Auth",Pe)},De=new c.C("OAuth"),Ie=function(){function e(e){var t=e.config,i=e.cognitoClientId,r=e.scopes,n=void 0===r?[]:r;if(this._urlOpener=t.urlOpener||Ae,this._config=t,this._cognitoClientId=i,!this.isValidScopes(n))throw Error("scopes must be a String Array");this._scopes=n}return e.prototype.isValidScopes=function(e){return Array.isArray(e)&&e.every(function(e){return"string"==typeof e})},e.prototype.oauthSignIn=function(e,t,i,n,s,o){void 0===e&&(e="code"),void 0===s&&(s=r.Cognito);var a=this._generateState(32),l=o?a+"-"+o.split("").map(function(e){return e.charCodeAt(0).toString(16).padStart(2,"0")}).join(""):a;!function(e){window.sessionStorage.setItem("oauth_state",e)}(l);var c,u=this._generateRandom(128);c=u,window.sessionStorage.setItem("ouath_pkce_key",c);var h=this._generateChallenge(u),d=this._scopes.join(" "),p="https://"+t+"/oauth2/authorize?"+Object.entries(Te(Te({redirect_uri:i,response_type:e,client_id:n,identity_provider:s,scope:d,state:l},"code"===e?{code_challenge:h}:{}),"code"===e?{code_challenge_method:"S256"}:{})).map(function(e){var t=_e(e,2),i=t[0],r=t[1];return encodeURIComponent(i)+"="+encodeURIComponent(r)}).join("&");De.debug("Redirecting to "+p),this._urlOpener(p,i)},e.prototype._handleCodeFlow=function(e){return Me(this,void 0,void 0,function(){var t,i,r,n,s,o,l,c,u,h,d,p,g,f;return Re(this,function(m){switch(m.label){case 0:return t=((0,Ee.parse)(e).query||"").split("&").map(function(e){return e.split("=")}).reduce(function(e,t){var i,r=_e(t,2),n=r[0],s=r[1];return Te(Te({},e),((i={})[n]=s,i))},{code:void 0}).code,i=(0,Ee.parse)(e).pathname||"/",r=(0,Ee.parse)(this._config.redirectSignIn).pathname||"/",t&&i===r?(n="https://"+this._config.domain+"/oauth2/token",xe("codeFlow",{},"Retrieving tokens from "+n),s=a(this._config)?this._cognitoClientId:this._config.clientID,o=a(this._config)?this._config.redirectSignIn:this._config.redirectUri,v=window.sessionStorage.getItem("ouath_pkce_key"),window.sessionStorage.removeItem("ouath_pkce_key"),c=Te({grant_type:"authorization_code",code:t,client_id:s,redirect_uri:o},(l=v)?{code_verifier:l}:{}),De.debug("Calling token endpoint: "+n+" with",c),u=Object.entries(c).map(function(e){var t=_e(e,2),i=t[0],r=t[1];return encodeURIComponent(i)+"="+encodeURIComponent(r)}).join("&"),[4,fetch(n,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:u})]):[2];case 1:return[4,m.sent().json()];case 2:if(h=m.sent(),d=h.access_token,p=h.refresh_token,g=h.id_token,f=h.error)throw new Error(f);return[2,{accessToken:d,refreshToken:p,idToken:g}]}var v})})},e.prototype._handleImplicitFlow=function(e){return Me(this,void 0,void 0,function(){var t,i,r;return Re(this,function(n){return t=((0,Ee.parse)(e).hash||"#").substr(1).split("&").map(function(e){return e.split("=")}).reduce(function(e,t){var i,r=_e(t,2),n=r[0],s=r[1];return Te(Te({},e),((i={})[n]=s,i))},{id_token:void 0,access_token:void 0}),i=t.id_token,r=t.access_token,xe("implicitFlow",{},"Got tokens from "+e),De.debug("Retrieving implicit tokens from "+e+" with"),[2,{accessToken:r,idToken:i,refreshToken:null}]})})},e.prototype.handleAuthResponse=function(e){return Me(this,void 0,void 0,function(){var t,i,r,n,s,o,a;return Re(this,function(l){switch(l.label){case 0:if(l.trys.push([0,5,,6]),t=e?Te(Te({},((0,Ee.parse)(e).hash||"#").substr(1).split("&").map(function(e){return e.split("=")}).reduce(function(e,t){var i=_e(t,2),r=i[0],n=i[1];return e[r]=n,e},{})),((0,Ee.parse)(e).query||"").split("&").map(function(e){return e.split("=")}).reduce(function(e,t){var i=_e(t,2),r=i[0],n=i[1];return e[r]=n,e},{})):{},i=t.error,r=t.error_description,i)throw new Error(r);return n=this._validateState(t),De.debug("Starting "+this._config.responseType+" flow with "+e),"code"!==this._config.responseType?[3,2]:(s=[{}],[4,this._handleCodeFlow(e)]);case 1:return[2,Te.apply(void 0,[Te.apply(void 0,s.concat([l.sent()])),{state:n}])];case 2:return o=[{}],[4,this._handleImplicitFlow(e)];case 3:return[2,Te.apply(void 0,[Te.apply(void 0,o.concat([l.sent()])),{state:n}])];case 4:return[3,6];case 5:throw a=l.sent(),De.error("Error handling auth response.",a),a;case 6:return[2]}})})},e.prototype._validateState=function(e){if(e){var t,i=(t=window.sessionStorage.getItem("oauth_state"),window.sessionStorage.removeItem("oauth_state"),t),r=e.state;if(i&&i!==r)throw new Error("Invalid state in OAuth flow");return r}},e.prototype.signOut=function(){return Me(this,void 0,void 0,function(){var e,t,i;return Re(this,function(r){return e="https://"+this._config.domain+"/logout?",t=a(this._config)?this._cognitoClientId:this._config.oauth.clientID,i=a(this._config)?this._config.redirectSignOut:this._config.returnTo,e+=Object.entries({client_id:t,logout_uri:encodeURIComponent(i)}).map(function(e){var t=_e(e,2);return t[0]+"="+t[1]}).join("&"),xe("oAuthSignOut",{oAuth:"signOut"},"Signing out from "+e),De.debug("Signing out from "+e),[2,this._urlOpener(e,i)]})})},e.prototype._generateState=function(e){for(var t="",i=e;i>0;--i)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.round(61*Math.random())];return t},e.prototype._generateChallenge=function(e){return this._base64URL(A()(e))},e.prototype._base64URL=function(e){return e.toString(Z()).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")},e.prototype._generateRandom=function(e){var t=new Uint8Array(e);if("undefined"!=typeof window&&window.crypto)window.crypto.getRandomValues(t);else for(var i=0;i<e;i+=1)t[i]=66*Math.random()|0;return this._bufferToString(t)},e.prototype._bufferToString=function(e){for(var t=[],i=0;i<e.byteLength;i+=1){var r=e[i]%62;t.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"[r])}return t.join("")},e}();const Le=Ie;var Ne;!function(e){e.DEFAULT_MSG="Authentication Error",e.EMPTY_EMAIL="Email cannot be empty",e.EMPTY_PHONE="Phone number cannot be empty",e.EMPTY_USERNAME="Username cannot be empty",e.INVALID_USERNAME="The username should either be a string or one of the sign in types",e.EMPTY_PASSWORD="Password cannot be empty",e.EMPTY_CODE="Confirmation code cannot be empty",e.SIGN_UP_ERROR="Error creating account",e.NO_MFA="No valid MFA method provided",e.INVALID_MFA="Invalid MFA type",e.EMPTY_CHALLENGE="Challenge response cannot be empty",e.NO_USER_SESSION="Failed to get the session because the user is empty",e.NETWORK_ERROR="Network Error",e.DEVICE_CONFIG="Device tracking has not been configured in this User Pool",e.AUTOSIGNIN_ERROR="Please use your credentials to sign in"}(Ne||(Ne={}));var Oe,Fe=(Oe=function(e,t){return Oe=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},Oe(e,t)},function(e,t){function i(){this.constructor=e}Oe(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),ke=new c.C("AuthError"),Ge=function(e){function t(i){var r=this,n=He[i],s=n.message,o=n.log;return(r=e.call(this,s)||this).constructor=t,Object.setPrototypeOf(r,t.prototype),r.name="AuthError",r.log=o||s,ke.error(r.log),r}return Fe(t,e),t}(Error),Ve=function(e){function t(i){var r=e.call(this,i)||this;return r.constructor=t,Object.setPrototypeOf(r,t.prototype),r.name="NoUserPoolError",r}return Fe(t,e),t}(Ge),He={noConfig:{message:Ne.DEFAULT_MSG,log:"\n            Error: Amplify has not been configured correctly.\n            This error is typically caused by one of the following scenarios:\n\n            1. Make sure you're passing the awsconfig object to Amplify.configure() in your app's entry point\n                See https://aws-amplify.github.io/docs/js/authentication#configure-your-app for more information\n            \n            2. There might be multiple conflicting versions of amplify packages in your node_modules.\n\t\t\t\tRefer to our docs site for help upgrading Amplify packages (https://docs.amplify.aws/lib/troubleshooting/upgrading/q/platform/js)\n        "},missingAuthConfig:{message:Ne.DEFAULT_MSG,log:"\n            Error: Amplify has not been configured correctly. \n            The configuration object is missing required auth properties.\n            This error is typically caused by one of the following scenarios:\n\n            1. Did you run `amplify push` after adding auth via `amplify add auth`?\n                See https://aws-amplify.github.io/docs/js/authentication#amplify-project-setup for more information\n\n            2. This could also be caused by multiple conflicting versions of amplify packages, see (https://docs.amplify.aws/lib/troubleshooting/upgrading/q/platform/js) for help upgrading Amplify packages.\n        "},emptyUsername:{message:Ne.EMPTY_USERNAME},invalidUsername:{message:Ne.INVALID_USERNAME},emptyPassword:{message:Ne.EMPTY_PASSWORD},emptyCode:{message:Ne.EMPTY_CODE},signUpError:{message:Ne.SIGN_UP_ERROR,log:"The first parameter should either be non-null string or object"},noMFA:{message:Ne.NO_MFA},invalidMFA:{message:Ne.INVALID_MFA},emptyChallengeResponse:{message:Ne.EMPTY_CHALLENGE},noUserSession:{message:Ne.NO_USER_SESSION},deviceConfig:{message:Ne.DEVICE_CONFIG},networkError:{message:Ne.NETWORK_ERROR},autoSignInError:{message:Ne.AUTOSIGNIN_ERROR},default:{message:Ne.DEFAULT_MSG}},Be=function(){return Be=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Be.apply(this,arguments)},ze=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},Ue=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},We=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},je=new c.C("AuthClass"),Ke="aws.cognito.signin.user.admin",$e="undefined"!=typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("amplify_default"):"@@amplify_default",qe=function(e,t,i){u.YZ.dispatch("auth",{event:e,data:t,message:i},"Auth",$e)},Ye=function(){function e(e){var t=this;this.userPool=null,this.user=null,this.oAuthFlowInProgress=!1,this.autoSignInInitiated=!1,this.Credentials=h.Ji,this.wrapRefreshSessionCallback=function(e){return function(t,i){return i?qe("tokenRefresh",void 0,"New token retrieved"):qe("tokenRefresh_failure",t,"Failed to retrieve new token"),e(t,i)}},this.configure(e),this.currentCredentials=this.currentCredentials.bind(this),this.currentUserCredentials=this.currentUserCredentials.bind(this),u.YZ.listen("auth",function(e){switch(e.payload.event){case"signIn":t._storage.setItem("amplify-signin-with-hostedUI","false");break;case"signOut":t._storage.removeItem("amplify-signin-with-hostedUI");break;case"cognitoHostedUI":t._storage.setItem("amplify-signin-with-hostedUI","true")}})}return e.prototype.getModuleName=function(){return"Auth"},e.prototype.configure=function(e){var t=this;if(!e)return this._config||{};je.debug("configure Auth");var i=Object.assign({},this._config,d.iX.parseMobilehubConfig(e).Auth,e);this._config=i;var r=this._config,s=r.userPoolId,o=r.userPoolWebClientId,l=r.cookieStorage,c=r.oauth,u=r.region,h=r.identityPoolId,p=r.mandatorySignIn,f=r.refreshHandlers,C=r.identityPoolRegion,y=r.clientMetadata,w=r.endpoint;if(this._config.storage){if(!this._isValidAuthStorage(this._config.storage))throw je.error("The storage in the Auth config is not valid!"),new Error("Empty storage object");this._storage=this._config.storage}else this._storage=l?new be(l):e.ssr?new m:(new v.i1).getStorage();if(this._storageSync=Promise.resolve(),"function"==typeof this._storage.sync&&(this._storageSync=this._storage.sync()),s){var S={UserPoolId:s,ClientId:o,endpoint:w};S.Storage=this._storage,this.userPool=new we(S,this.wrapRefreshSessionCallback)}this.Credentials.configure({mandatorySignIn:p,region:C||u,userPoolId:s,identityPoolId:h,refreshHandlers:f,storage:this._storage});var b=c?a(this._config.oauth)?c:c.awsCognito:void 0;if(b){var E=Object.assign({cognitoClientId:o,UserPoolId:s,domain:b.domain,scopes:b.scope,redirectSignIn:b.redirectSignIn,redirectSignOut:b.redirectSignOut,responseType:b.responseType,Storage:this._storage,urlOpener:b.urlOpener,clientMetadata:y},b.options);this._oAuthHandler=new Le({scopes:E.scopes,config:E,cognitoClientId:E.cognitoClientId});var A={};!function(){if((0,g.gy)().isBrowser&&window.location)!function(e){var i=e.url;A[i]||(A[i]=!0,t._handleAuthResponse(i))}({url:window.location.href});else if(!(0,g.gy)().isNode)throw new Error("Not supported")}()}return qe("configured",null,"The Auth category has been configured successfully"),this.autoSignInInitiated||"function"!=typeof this._storage.getItem||(this.isTrueStorageValue("amplify-polling-started")&&(qe("autoSignIn_failure",null,n.AutoSignInError),this._storage.removeItem("amplify-auto-sign-in")),this._storage.removeItem("amplify-polling-started")),this._config},e.prototype.signUp=function(e){for(var t,i,r,s=this,o=[],a=1;a<arguments.length;a++)o[a-1]=arguments[a];if(!this.userPool)return this.rejectNoUserPool();var l,c=null,u=null,h=[],d=null,p={enabled:!1},g={},f={};if(e&&"string"==typeof e){c=e,u=o?o[0]:null;var m=o?o[1]:null,v=o?o[2]:null;m&&h.push(new re({Name:"email",Value:m})),v&&h.push(new re({Name:"phone_number",Value:v}))}else{if(!e||"object"!=typeof e)return this.rejectAuthError(n.SignUpError);c=e.username,u=e.password,e&&e.clientMetadata?l=e.clientMetadata:this._config.clientMetadata&&(l=this._config.clientMetadata);var C=e.attributes;C&&Object.keys(C).map(function(e){h.push(new re({Name:e,Value:C[e]}))});var y=e.validationData;y&&(d=[],Object.keys(y).map(function(e){d.push(new re({Name:e,Value:y[e]}))})),(p=null!==(t=e.autoSignIn)&&void 0!==t?t:{enabled:!1}).enabled&&(this._storage.setItem("amplify-auto-sign-in","true"),g=null!==(i=p.validationData)&&void 0!==i?i:{},f=null!==(r=p.clientMetaData)&&void 0!==r?r:{})}return c?u?(je.debug("signUp attrs:",h),je.debug("signUp validation data:",d),new Promise(function(e,t){s.userPool.signUp(c,u,h,d,function(i,r){i?(qe("signUp_failure",i,c+" failed to signup"),t(i)):(qe("signUp",r,c+" has signed up successfully"),p.enabled&&s.handleAutoSignIn(c,u,g,f,r),e(r))},l)})):this.rejectAuthError(n.EmptyPassword):this.rejectAuthError(n.EmptyUsername)},e.prototype.handleAutoSignIn=function(e,t,i,r,n){this.autoSignInInitiated=!0;var s=new y({Username:e,Password:t,ValidationData:i,ClientMetadata:r});n.userConfirmed?this.signInAfterUserConfirmed(s):"link"===this._config.signUpVerificationMethod?this.handleLinkAutoSignIn(s):this.handleCodeAutoSignIn(s)},e.prototype.handleCodeAutoSignIn=function(e){var t=this,i=function(r){"confirmSignUp"===r.payload.event&&t.signInAfterUserConfirmed(e,i)};u.YZ.listen("auth",i)},e.prototype.handleLinkAutoSignIn=function(e){var t=this;this._storage.setItem("amplify-polling-started","true");var i=Date.now(),r=setInterval(function(){Date.now()-i>18e4?(clearInterval(r),qe("autoSignIn_failure",null,"Please confirm your account and use your credentials to sign in."),t._storage.removeItem("amplify-auto-sign-in")):t.signInAfterUserConfirmed(e,null,r)},5e3)},e.prototype.signInAfterUserConfirmed=function(e,t,i){return ze(this,void 0,void 0,function(){var r,n,s=this;return Ue(this,function(o){switch(o.label){case 0:r=this.createCognitoUser(e.getUsername()),o.label=1;case 1:return o.trys.push([1,3,,4]),[4,r.authenticateUser(e,this.authCallbacks(r,function(r){qe("autoSignIn",r,e.getUsername()+" has signed in successfully"),t&&u.YZ.remove("auth",t),i&&(clearInterval(i),s._storage.removeItem("amplify-polling-started")),s._storage.removeItem("amplify-auto-sign-in")},function(e){je.error(e),s._storage.removeItem("amplify-auto-sign-in")}))];case 2:return o.sent(),[3,4];case 3:return n=o.sent(),je.error(n),[3,4];case 4:return[2]}})})},e.prototype.confirmSignUp=function(e,t,i){var r=this;if(!this.userPool)return this.rejectNoUserPool();if(!e)return this.rejectAuthError(n.EmptyUsername);if(!t)return this.rejectAuthError(n.EmptyCode);var s,o=this.createCognitoUser(e),a=!i||"boolean"!=typeof i.forceAliasCreation||i.forceAliasCreation;return i&&i.clientMetadata?s=i.clientMetadata:this._config.clientMetadata&&(s=this._config.clientMetadata),new Promise(function(i,l){o.confirmRegistration(t,a,function(t,s){t?l(t):(qe("confirmSignUp",s,e+" has been confirmed successfully"),r.isTrueStorageValue("amplify-auto-sign-in")&&!r.autoSignInInitiated&&(qe("autoSignIn_failure",null,n.AutoSignInError),r._storage.removeItem("amplify-auto-sign-in")),i(s))},s)})},e.prototype.isTrueStorageValue=function(e){var t=this._storage.getItem(e);return!!t&&"true"===t},e.prototype.resendSignUp=function(e,t){if(void 0===t&&(t=this._config.clientMetadata),!this.userPool)return this.rejectNoUserPool();if(!e)return this.rejectAuthError(n.EmptyUsername);var i=this.createCognitoUser(e);return new Promise(function(e,r){i.resendConfirmationCode(function(t,i){t?r(t):e(i)},t)})},e.prototype.signIn=function(e,t,i){if(void 0===i&&(i=this._config.clientMetadata),!this.userPool)return this.rejectNoUserPool();var r=null,s=null,o={};if("string"==typeof e)r=e,s=t;else{if(!e.username)return this.rejectAuthError(n.InvalidUsername);void 0!==t&&je.warn("The password should be defined under the first parameter object!"),r=e.username,s=e.password,o=e.validationData}if(!r)return this.rejectAuthError(n.EmptyUsername);var a=new y({Username:r,Password:s,ValidationData:o,ClientMetadata:i});return s?this.signInWithPassword(a):this.signInWithoutPassword(a)},e.prototype.authCallbacks=function(e,t,i){var r=this,n=this;return{onSuccess:function(s){return ze(r,void 0,void 0,function(){var r,o,a,l;return Ue(this,function(c){switch(c.label){case 0:je.debug(s),delete e.challengeName,delete e.challengeParam,c.label=1;case 1:return c.trys.push([1,4,5,9]),[4,this.Credentials.clear()];case 2:return c.sent(),[4,this.Credentials.set(s,"session")];case 3:return r=c.sent(),je.debug("succeed to get cognito credentials",r),[3,9];case 4:return o=c.sent(),je.debug("cannot get cognito credentials",o),[3,9];case 5:return c.trys.push([5,7,,8]),[4,this.currentUserPoolUser()];case 6:return a=c.sent(),n.user=a,qe("signIn",a,"A user "+e.getUsername()+" has been signed in"),t(a),[3,8];case 7:return l=c.sent(),je.error("Failed to get the signed in user",l),i(l),[3,8];case 8:return[7];case 9:return[2]}})})},onFailure:function(t){je.debug("signIn failure",t),qe("signIn_failure",t,e.getUsername()+" failed to signin"),i(t)},customChallenge:function(i){je.debug("signIn custom challenge answer required"),e.challengeName="CUSTOM_CHALLENGE",e.challengeParam=i,t(e)},mfaRequired:function(i,r){je.debug("signIn MFA required"),e.challengeName=i,e.challengeParam=r,t(e)},mfaSetup:function(i,r){je.debug("signIn mfa setup",i),e.challengeName=i,e.challengeParam=r,t(e)},newPasswordRequired:function(i,r){je.debug("signIn new password"),e.challengeName="NEW_PASSWORD_REQUIRED",e.challengeParam={userAttributes:i,requiredAttributes:r},t(e)},totpRequired:function(i,r){je.debug("signIn totpRequired"),e.challengeName=i,e.challengeParam=r,t(e)},selectMFAType:function(i,r){je.debug("signIn selectMFAType",i),e.challengeName=i,e.challengeParam=r,t(e)}}},e.prototype.signInWithPassword=function(e){var t=this;if(this.pendingSignIn)throw new Error("Pending sign-in attempt already in progress");var i=this.createCognitoUser(e.getUsername());return this.pendingSignIn=new Promise(function(r,n){i.authenticateUser(e,t.authCallbacks(i,function(e){t.pendingSignIn=null,r(e)},function(e){t.pendingSignIn=null,n(e)}))}),this.pendingSignIn},e.prototype.signInWithoutPassword=function(e){var t=this,i=this.createCognitoUser(e.getUsername());return i.setAuthenticationFlowType("CUSTOM_AUTH"),new Promise(function(r,n){i.initiateAuth(e,t.authCallbacks(i,r,n))})},e.prototype.getMFAOptions=function(e){return new Promise(function(t,i){e.getMFAOptions(function(e,r){if(e)return je.debug("get MFA Options failed",e),void i(e);je.debug("get MFA options success",r),t(r)})})},e.prototype.getPreferredMFA=function(e,t){var i=this,r=this;return new Promise(function(n,s){var o=i._config.clientMetadata,a=!!t&&t.bypassCache;e.getUserData(function(t,o){return ze(i,void 0,void 0,function(){var i,a;return Ue(this,function(l){switch(l.label){case 0:if(!t)return[3,5];if(je.debug("getting preferred mfa failed",t),!this.isSessionInvalid(t))return[3,4];l.label=1;case 1:return l.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(e)];case 2:return l.sent(),[3,4];case 3:return i=l.sent(),s(new Error("Session is invalid due to: "+t.message+" and failed to clean up invalid session: "+i.message)),[2];case 4:return s(t),[2];case 5:return(a=r._getMfaTypeFromUserData(o))?(n(a),[2]):(s("invalid MFA Type"),[2])}})})},{bypassCache:a,clientMetadata:o})})},e.prototype._getMfaTypeFromUserData=function(e){var t=null,i=e.PreferredMfaSetting;if(i)t=i;else{var r=e.UserMFASettingList;r?0===r.length?t="NOMFA":je.debug("invalid case for getPreferredMFA",e):t=e.MFAOptions?"SMS_MFA":"NOMFA"}return t},e.prototype._getUserData=function(e,t){var i=this;return new Promise(function(r,n){e.getUserData(function(t,s){return ze(i,void 0,void 0,function(){var i;return Ue(this,function(o){switch(o.label){case 0:if(!t)return[3,5];if(je.debug("getting user data failed",t),!this.isSessionInvalid(t))return[3,4];o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(e)];case 2:return o.sent(),[3,4];case 3:return i=o.sent(),n(new Error("Session is invalid due to: "+t.message+" and failed to clean up invalid session: "+i.message)),[2];case 4:return n(t),[2];case 5:r(s),o.label=6;case 6:return[2]}})})},t)})},e.prototype.setPreferredMFA=function(e,t){return ze(this,void 0,void 0,function(){var i,r,s,o,a,l,c=this;return Ue(this,function(u){switch(u.label){case 0:return i=this._config.clientMetadata,[4,this._getUserData(e,{bypassCache:!0,clientMetadata:i})];case 1:switch(r=u.sent(),s=null,o=null,t){case"TOTP":case"SOFTWARE_TOKEN_MFA":return[3,2];case"SMS":case"SMS_MFA":return[3,3];case"NOMFA":return[3,4]}return[3,6];case 2:return o={PreferredMfa:!0,Enabled:!0},[3,7];case 3:return s={PreferredMfa:!0,Enabled:!0},[3,7];case 4:return a=r.UserMFASettingList,[4,this._getMfaTypeFromUserData(r)];case 5:if("NOMFA"===(l=u.sent()))return[2,Promise.resolve("No change for mfa type")];if("SMS_MFA"===l)s={PreferredMfa:!1,Enabled:!1};else{if("SOFTWARE_TOKEN_MFA"!==l)return[2,this.rejectAuthError(n.InvalidMFA)];o={PreferredMfa:!1,Enabled:!1}}return a&&0!==a.length&&a.forEach(function(e){"SMS_MFA"===e?s={PreferredMfa:!1,Enabled:!1}:"SOFTWARE_TOKEN_MFA"===e&&(o={PreferredMfa:!1,Enabled:!1})}),[3,7];case 6:return je.debug("no validmfa method provided"),[2,this.rejectAuthError(n.NoMFA)];case 7:return[2,new Promise(function(t,r){e.setUserMfaPreference(s,o,function(n,s){if(n)return je.debug("Set user mfa preference error",n),r(n);je.debug("Set user mfa success",s),je.debug("Caching the latest user data into local"),e.getUserData(function(i,n){return ze(c,void 0,void 0,function(){var n;return Ue(this,function(o){switch(o.label){case 0:if(!i)return[3,5];if(je.debug("getting user data failed",i),!this.isSessionInvalid(i))return[3,4];o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(e)];case 2:return o.sent(),[3,4];case 3:return n=o.sent(),r(new Error("Session is invalid due to: "+i.message+" and failed to clean up invalid session: "+n.message)),[2];case 4:return[2,r(i)];case 5:return[2,t(s)]}})})},{bypassCache:!0,clientMetadata:i})})})]}})})},e.prototype.disableSMS=function(e){return new Promise(function(t,i){e.disableMFA(function(e,r){if(e)return je.debug("disable mfa failed",e),void i(e);je.debug("disable mfa succeed",r),t(r)})})},e.prototype.enableSMS=function(e){return new Promise(function(t,i){e.enableMFA(function(e,r){if(e)return je.debug("enable mfa failed",e),void i(e);je.debug("enable mfa succeed",r),t(r)})})},e.prototype.setupTOTP=function(e){return new Promise(function(t,i){e.associateSoftwareToken({onFailure:function(e){je.debug("associateSoftwareToken failed",e),i(e)},associateSecretCode:function(e){je.debug("associateSoftwareToken sucess",e),t(e)}})})},e.prototype.verifyTotpToken=function(e,t){return je.debug("verification totp token",e,t),new Promise(function(i,r){e.verifySoftwareToken(t,"My TOTP device",{onFailure:function(e){je.debug("verifyTotpToken failed",e),r(e)},onSuccess:function(t){qe("signIn",e,"A user "+e.getUsername()+" has been signed in"),je.debug("verifyTotpToken success",t),i(t)}})})},e.prototype.confirmSignIn=function(e,t,i,r){var s=this;if(void 0===r&&(r=this._config.clientMetadata),!t)return this.rejectAuthError(n.EmptyCode);var o=this;return new Promise(function(n,a){e.sendMFACode(t,{onSuccess:function(t){return ze(s,void 0,void 0,function(){var i,r;return Ue(this,function(s){switch(s.label){case 0:je.debug(t),s.label=1;case 1:return s.trys.push([1,4,5,6]),[4,this.Credentials.clear()];case 2:return s.sent(),[4,this.Credentials.set(t,"session")];case 3:return i=s.sent(),je.debug("succeed to get cognito credentials",i),[3,6];case 4:return r=s.sent(),je.debug("cannot get cognito credentials",r),[3,6];case 5:return o.user=e,qe("signIn",e,"A user "+e.getUsername()+" has been signed in"),n(e),[7];case 6:return[2]}})})},onFailure:function(e){je.debug("confirm signIn failure",e),a(e)}},i,r)})},e.prototype.completeNewPassword=function(e,t,i,r){var s=this;if(void 0===i&&(i={}),void 0===r&&(r=this._config.clientMetadata),!t)return this.rejectAuthError(n.EmptyPassword);var o=this;return new Promise(function(n,a){e.completeNewPasswordChallenge(t,i,{onSuccess:function(t){return ze(s,void 0,void 0,function(){var i,r;return Ue(this,function(s){switch(s.label){case 0:je.debug(t),s.label=1;case 1:return s.trys.push([1,4,5,6]),[4,this.Credentials.clear()];case 2:return s.sent(),[4,this.Credentials.set(t,"session")];case 3:return i=s.sent(),je.debug("succeed to get cognito credentials",i),[3,6];case 4:return r=s.sent(),je.debug("cannot get cognito credentials",r),[3,6];case 5:return o.user=e,qe("signIn",e,"A user "+e.getUsername()+" has been signed in"),n(e),[7];case 6:return[2]}})})},onFailure:function(e){je.debug("completeNewPassword failure",e),qe("completeNewPassword_failure",e,s.user+" failed to complete the new password flow"),a(e)},mfaRequired:function(t,i){je.debug("signIn MFA required"),e.challengeName=t,e.challengeParam=i,n(e)},mfaSetup:function(t,i){je.debug("signIn mfa setup",t),e.challengeName=t,e.challengeParam=i,n(e)},totpRequired:function(t,i){je.debug("signIn mfa setup",t),e.challengeName=t,e.challengeParam=i,n(e)}},r)})},e.prototype.sendCustomChallengeAnswer=function(e,t,i){var r=this;return void 0===i&&(i=this._config.clientMetadata),this.userPool?t?new Promise(function(n,s){e.sendCustomChallengeAnswer(t,r.authCallbacks(e,n,s),i)}):this.rejectAuthError(n.EmptyChallengeResponse):this.rejectNoUserPool()},e.prototype.deleteUserAttributes=function(e,t){var i=this;return new Promise(function(r,n){i.userSession(e).then(function(i){e.deleteAttributes(t,function(e,t){return e?n(e):r(t)})})})},e.prototype.deleteUser=function(){return ze(this,void 0,void 0,function(){var e,t,i=this;return Ue(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,3]),[4,this._storageSync];case 1:return r.sent(),[3,3];case 2:throw e=r.sent(),je.debug("Failed to sync cache info into memory",e),new Error(e);case 3:return t=this._oAuthHandler&&"true"===this._storage.getItem("amplify-signin-with-hostedUI"),[2,new Promise(function(e,r){return ze(i,void 0,void 0,function(){var i,n=this;return Ue(this,function(s){if(this.userPool){if(!(i=this.userPool.getCurrentUser()))return je.debug("Failed to get user from user pool"),[2,r(new Error("No current user."))];i.getSession(function(s,o){return ze(n,void 0,void 0,function(){var n,o=this;return Ue(this,function(a){switch(a.label){case 0:if(!s)return[3,5];if(je.debug("Failed to get the user session",s),!this.isSessionInvalid(s))return[3,4];a.label=1;case 1:return a.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(i)];case 2:return a.sent(),[3,4];case 3:return n=a.sent(),r(new Error("Session is invalid due to: "+s.message+" and failed to clean up invalid session: "+n.message)),[2];case 4:return[2,r(s)];case 5:i.deleteUser(function(n,s){if(n)r(n);else{qe("userDeleted",s,"The authenticated user has been deleted."),i.signOut(),o.user=null;try{o.cleanCachedItems()}catch(e){je.debug("failed to clear cached items")}t?o.oAuthSignOutRedirect(e,r):(qe("signOut",o.user,"A user has been signed out"),e(s))}}),a.label=6;case 6:return[2]}})})})}else je.debug("no Congito User pool"),r(new Error("Cognito User pool does not exist"));return[2]})})})]}})})},e.prototype.updateUserAttributes=function(e,t,i){void 0===i&&(i=this._config.clientMetadata);var r=[],n=this;return new Promise(function(s,o){n.userSession(e).then(function(n){for(var a in t)if("sub"!==a&&a.indexOf("_verified")<0){var l={Name:a,Value:t[a]};r.push(l)}e.updateAttributes(r,function(e,t){return e?o(e):s(t)},i)})})},e.prototype.userAttributes=function(e){var t=this;return new Promise(function(i,r){t.userSession(e).then(function(t){e.getUserAttributes(function(e,t){e?r(e):i(t)})})})},e.prototype.verifiedContact=function(e){var t=this;return this.userAttributes(e).then(function(e){var i=t.attributesToObject(e),r={},n={};return i.email&&(i.email_verified?n.email=i.email:r.email=i.email),i.phone_number&&(i.phone_number_verified?n.phone_number=i.phone_number:r.phone_number=i.phone_number),{verified:n,unverified:r}})},e.prototype.isErrorWithMessage=function(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"message")},e.prototype.isTokenRevokedError=function(e){return this.isErrorWithMessage(e)&&"Access Token has been revoked"===e.message},e.prototype.isRefreshTokenRevokedError=function(e){return this.isErrorWithMessage(e)&&"Refresh Token has been revoked"===e.message},e.prototype.isUserDisabledError=function(e){return this.isErrorWithMessage(e)&&"User is disabled."===e.message},e.prototype.isUserDoesNotExistError=function(e){return this.isErrorWithMessage(e)&&"User does not exist."===e.message},e.prototype.isRefreshTokenExpiredError=function(e){return this.isErrorWithMessage(e)&&"Refresh Token has expired"===e.message},e.prototype.isSignedInHostedUI=function(){return this._oAuthHandler&&"true"===this._storage.getItem("amplify-signin-with-hostedUI")},e.prototype.isSessionInvalid=function(e){return this.isUserDisabledError(e)||this.isUserDoesNotExistError(e)||this.isTokenRevokedError(e)||this.isRefreshTokenRevokedError(e)||this.isRefreshTokenExpiredError(e)},e.prototype.cleanUpInvalidSession=function(e){return ze(this,void 0,void 0,function(){var t=this;return Ue(this,function(i){switch(i.label){case 0:e.signOut(),this.user=null,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this.cleanCachedItems()];case 2:return i.sent(),[3,4];case 3:return i.sent(),je.debug("failed to clear cached items"),[3,4];case 4:return this.isSignedInHostedUI()?[2,new Promise(function(e,i){t.oAuthSignOutRedirect(e,i)})]:(qe("signOut",this.user,"A user has been signed out"),[2])}})})},e.prototype.currentUserPoolUser=function(e){var t=this;return this.userPool?new Promise(function(i,r){t._storageSync.then(function(){return ze(t,void 0,void 0,function(){var t,n,s=this;return Ue(this,function(o){switch(o.label){case 0:return this.isOAuthInProgress()?(je.debug("OAuth signIn in progress, waiting for resolution..."),[4,new Promise(function(e){var t=setTimeout(function(){je.debug("OAuth signIn in progress timeout"),u.YZ.remove("auth",i),e()},1e4);function i(r){var n=r.payload.event;"cognitoHostedUI"!==n&&"cognitoHostedUI_failure"!==n||(je.debug("OAuth signIn resolved: "+n),clearTimeout(t),u.YZ.remove("auth",i),e())}u.YZ.listen("auth",i)})]):[3,2];case 1:o.sent(),o.label=2;case 2:return(t=this.userPool.getCurrentUser())?(n=this._config.clientMetadata,t.getSession(function(n,o){return ze(s,void 0,void 0,function(){var s,a,l,c,u=this;return Ue(this,function(h){switch(h.label){case 0:if(!n)return[3,5];if(je.debug("Failed to get the user session",n),!this.isSessionInvalid(n))return[3,4];h.label=1;case 1:return h.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(t)];case 2:return h.sent(),[3,4];case 3:return s=h.sent(),r(new Error("Session is invalid due to: "+n.message+" and failed to clean up invalid session: "+s.message)),[2];case 4:return r(n),[2];case 5:return(a=!!e&&e.bypassCache)?[4,this.Credentials.clear()]:[3,7];case 6:h.sent(),h.label=7;case 7:return l=this._config.clientMetadata,(void 0===(c=o.getAccessToken().decodePayload().scope)?"":c).split(" ").includes(Ke)?(t.getUserData(function(e,n){return ze(u,void 0,void 0,function(){var s,o,a,l,c,u,h;return Ue(this,function(d){switch(d.label){case 0:if(!e)return[3,7];if(je.debug("getting user data failed",e),!this.isSessionInvalid(e))return[3,5];d.label=1;case 1:return d.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(t)];case 2:return d.sent(),[3,4];case 3:return s=d.sent(),r(new Error("Session is invalid due to: "+e.message+" and failed to clean up invalid session: "+s.message)),[2];case 4:return r(e),[3,6];case 5:i(t),d.label=6;case 6:return[2];case 7:for(o=n.PreferredMfaSetting||"NOMFA",a=[],l=0;l<n.UserAttributes.length;l++)c={Name:n.UserAttributes[l].Name,Value:n.UserAttributes[l].Value},u=new re(c),a.push(u);return h=this.attributesToObject(a),Object.assign(t,{attributes:h,preferredMFA:o}),[2,i(t)]}})})},{bypassCache:a,clientMetadata:l}),[2]):(je.debug("Unable to get the user data because the "+Ke+" is not in the scopes of the access token"),[2,i(t)])}})})},{clientMetadata:n}),[2]):(je.debug("Failed to get user from user pool"),r("No current user"),[2])}})})}).catch(function(e){return je.debug("Failed to sync cache info into memory",e),r(e)})}):this.rejectNoUserPool()},e.prototype.isOAuthInProgress=function(){return this.oAuthFlowInProgress},e.prototype.currentAuthenticatedUser=function(e){return ze(this,void 0,void 0,function(){var t,i,r,n,s;return Ue(this,function(o){switch(o.label){case 0:je.debug("getting current authenticated user"),t=null,o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this._storageSync];case 2:return o.sent(),[3,4];case 3:throw i=o.sent(),je.debug("Failed to sync cache info into memory",i),i;case 4:try{(r=JSON.parse(this._storage.getItem("aws-amplify-federatedInfo")))&&(t=Be(Be({},r.user),{token:r.token}))}catch(e){je.debug("cannot load federated user from auth storage")}return t?(this.user=t,je.debug("get current authenticated federated user",this.user),[2,this.user]):[3,5];case 5:je.debug("get current authenticated userpool user"),n=null,o.label=6;case 6:return o.trys.push([6,8,,9]),[4,this.currentUserPoolUser(e)];case 7:return n=o.sent(),[3,9];case 8:return"No userPool"===(s=o.sent())&&je.error("Cannot get the current user because the user pool is missing. Please make sure the Auth module is configured with a valid Cognito User Pool ID"),je.debug("The user is not authenticated by the error",s),[2,Promise.reject("The user is not authenticated")];case 9:return this.user=n,[2,this.user]}})})},e.prototype.currentSession=function(){var e=this;return je.debug("Getting current session"),this.userPool?new Promise(function(t,i){e.currentUserPoolUser().then(function(r){e.userSession(r).then(function(e){t(e)}).catch(function(e){je.debug("Failed to get the current session",e),i(e)})}).catch(function(e){je.debug("Failed to get the current user",e),i(e)})}):Promise.reject(new Error("No User Pool in the configuration."))},e.prototype.userSession=function(e){var t=this;if(!e)return je.debug("the user is null"),this.rejectAuthError(n.NoUserSession);var i=this._config.clientMetadata;return new Promise(function(r,n){je.debug("Getting the session from this user:",e),e.getSession(function(i,s){return ze(t,void 0,void 0,function(){var t;return Ue(this,function(o){switch(o.label){case 0:if(!i)return[3,5];if(je.debug("Failed to get the session from user",e),!this.isSessionInvalid(i))return[3,4];o.label=1;case 1:return o.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(e)];case 2:return o.sent(),[3,4];case 3:return t=o.sent(),n(new Error("Session is invalid due to: "+i.message+" and failed to clean up invalid session: "+t.message)),[2];case 4:return n(i),[2];case 5:return je.debug("Succeed to get the user session",s),r(s),[2]}})})},{clientMetadata:i})})},e.prototype.currentUserCredentials=function(){return ze(this,void 0,void 0,function(){var e,t,i=this;return Ue(this,function(r){switch(r.label){case 0:je.debug("Getting current user credentials"),r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this._storageSync];case 2:return r.sent(),[3,4];case 3:throw e=r.sent(),je.debug("Failed to sync cache info into memory",e),e;case 4:t=null;try{t=JSON.parse(this._storage.getItem("aws-amplify-federatedInfo"))}catch(e){je.debug("failed to get or parse item aws-amplify-federatedInfo",e)}return t?[2,this.Credentials.refreshFederatedToken(t)]:[2,this.currentSession().then(function(e){return je.debug("getting session success",e),i.Credentials.set(e,"session")}).catch(function(){return je.debug("getting guest credentials"),i.Credentials.set(null,"guest")})]}})})},e.prototype.currentCredentials=function(){return je.debug("getting current credentials"),this.Credentials.get()},e.prototype.verifyUserAttribute=function(e,t,i){return void 0===i&&(i=this._config.clientMetadata),new Promise(function(r,n){e.getAttributeVerificationCode(t,{onSuccess:function(e){return r(e)},onFailure:function(e){return n(e)}},i)})},e.prototype.verifyUserAttributeSubmit=function(e,t,i){return i?new Promise(function(r,n){e.verifyAttribute(t,i,{onSuccess:function(e){r(e)},onFailure:function(e){n(e)}})}):this.rejectAuthError(n.EmptyCode)},e.prototype.verifyCurrentUserAttribute=function(e){var t=this;return t.currentUserPoolUser().then(function(i){return t.verifyUserAttribute(i,e)})},e.prototype.verifyCurrentUserAttributeSubmit=function(e,t){var i=this;return i.currentUserPoolUser().then(function(r){return i.verifyUserAttributeSubmit(r,e,t)})},e.prototype.cognitoIdentitySignOut=function(e,t){return ze(this,void 0,void 0,function(){var i,r,n=this;return Ue(this,function(s){switch(s.label){case 0:return s.trys.push([0,2,,3]),[4,this._storageSync];case 1:return s.sent(),[3,3];case 2:throw i=s.sent(),je.debug("Failed to sync cache info into memory",i),i;case 3:return r=this._oAuthHandler&&"true"===this._storage.getItem("amplify-signin-with-hostedUI"),[2,new Promise(function(i,s){if(e&&e.global){je.debug("user global sign out",t);var o=n._config.clientMetadata;t.getSession(function(e,o){return ze(n,void 0,void 0,function(){var n,o=this;return Ue(this,function(a){switch(a.label){case 0:if(!e)return[3,5];if(je.debug("failed to get the user session",e),!this.isSessionInvalid(e))return[3,4];a.label=1;case 1:return a.trys.push([1,3,,4]),[4,this.cleanUpInvalidSession(t)];case 2:return a.sent(),[3,4];case 3:return n=a.sent(),s(new Error("Session is invalid due to: "+e.message+" and failed to clean up invalid session: "+n.message)),[2];case 4:return[2,s(e)];case 5:return t.globalSignOut({onSuccess:function(e){if(je.debug("global sign out success"),!r)return i();o.oAuthSignOutRedirect(i,s)},onFailure:function(e){return je.debug("global sign out failed",e),s(e)}}),[2]}})})},{clientMetadata:o})}else je.debug("user sign out",t),t.signOut(function(){if(!r)return i();n.oAuthSignOutRedirect(i,s)})})]}})})},e.prototype.oAuthSignOutRedirect=function(e,t){(0,g.gy)().isBrowser?this.oAuthSignOutRedirectOrReject(t):this.oAuthSignOutAndResolve(e)},e.prototype.oAuthSignOutAndResolve=function(e){this._oAuthHandler.signOut(),e()},e.prototype.oAuthSignOutRedirectOrReject=function(e){this._oAuthHandler.signOut(),setTimeout(function(){return e(Error("Signout timeout fail"))},3e3)},e.prototype.signOut=function(e){return ze(this,void 0,void 0,function(){var t;return Ue(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.cleanCachedItems()];case 1:return i.sent(),[3,3];case 2:return i.sent(),je.debug("failed to clear cached items"),[3,3];case 3:return this.userPool?(t=this.userPool.getCurrentUser())?[4,this.cognitoIdentitySignOut(e,t)]:[3,5]:[3,7];case 4:return i.sent(),[3,6];case 5:je.debug("no current Cognito user"),i.label=6;case 6:return[3,8];case 7:je.debug("no Cognito User pool"),i.label=8;case 8:return qe("signOut",this.user,"A user has been signed out"),this.user=null,[2]}})})},e.prototype.cleanCachedItems=function(){return ze(this,void 0,void 0,function(){return Ue(this,function(e){switch(e.label){case 0:return[4,this.Credentials.clear()];case 1:return e.sent(),[2]}})})},e.prototype.changePassword=function(e,t,i,r){var n=this;return void 0===r&&(r=this._config.clientMetadata),new Promise(function(s,o){n.userSession(e).then(function(n){e.changePassword(t,i,function(e,t){return e?(je.debug("change password failure",e),o(e)):s(t)},r)})})},e.prototype.forgotPassword=function(e,t){if(void 0===t&&(t=this._config.clientMetadata),!this.userPool)return this.rejectNoUserPool();if(!e)return this.rejectAuthError(n.EmptyUsername);var i=this.createCognitoUser(e);return new Promise(function(r,n){i.forgotPassword({onSuccess:function(){r()},onFailure:function(t){je.debug("forgot password failure",t),qe("forgotPassword_failure",t,e+" forgotPassword failed"),n(t)},inputVerificationCode:function(t){qe("forgotPassword",i,e+" has initiated forgot password flow"),r(t)}},t)})},e.prototype.forgotPasswordSubmit=function(e,t,i,r){if(void 0===r&&(r=this._config.clientMetadata),!this.userPool)return this.rejectNoUserPool();if(!e)return this.rejectAuthError(n.EmptyUsername);if(!t)return this.rejectAuthError(n.EmptyCode);if(!i)return this.rejectAuthError(n.EmptyPassword);var s=this.createCognitoUser(e);return new Promise(function(n,o){s.confirmPassword(t,i,{onSuccess:function(t){qe("forgotPasswordSubmit",s,e+" forgotPasswordSubmit successful"),n(t)},onFailure:function(t){qe("forgotPasswordSubmit_failure",t,e+" forgotPasswordSubmit failed"),o(t)}},r)})},e.prototype.currentUserInfo=function(){return ze(this,void 0,void 0,function(){var e,t,i,r,n,s,o;return Ue(this,function(a){switch(a.label){case 0:return(e=this.Credentials.getCredSource())&&"aws"!==e&&"userPool"!==e?[3,9]:[4,this.currentUserPoolUser().catch(function(e){return je.error(e)})];case 1:if(!(o=a.sent()))return[2,null];a.label=2;case 2:return a.trys.push([2,8,,9]),[4,this.userAttributes(o)];case 3:t=a.sent(),i=this.attributesToObject(t),r=null,a.label=4;case 4:return a.trys.push([4,6,,7]),[4,this.currentCredentials()];case 5:return r=a.sent(),[3,7];case 6:return n=a.sent(),je.debug("Failed to retrieve credentials while getting current user info",n),[3,7];case 7:return[2,{id:r?r.identityId:void 0,username:o.getUsername(),attributes:i}];case 8:return s=a.sent(),je.error("currentUserInfo error",s),[2,{}];case 9:return"federated"===e?[2,(o=this.user)||{}]:[2]}})})},e.prototype.federatedSignIn=function(e,t,i){return ze(this,void 0,void 0,function(){var n,s,l,c,u,h,d,p,g,f,m;return Ue(this,function(v){switch(v.label){case 0:if(!this._config.identityPoolId&&!this._config.userPoolId)throw new Error("Federation requires either a User Pool or Identity Pool in config");if(void 0===e&&this._config.identityPoolId&&!this._config.userPoolId)throw new Error("Federation with Identity Pools requires tokens passed as arguments");return o(e)||(C=e)&&["customProvider"].find(function(e){return C.hasOwnProperty(e)})||function(e){return e&&!!["customState"].find(function(t){return e.hasOwnProperty(t)})}(e)||void 0===e?(n=e||{provider:r.Cognito},u=o(n)?n.provider:n.customProvider,o(n),s=n.customState,this._config.userPoolId&&(l=a(this._config.oauth)?this._config.userPoolWebClientId:this._config.oauth.clientID,c=a(this._config.oauth)?this._config.oauth.redirectSignIn:this._config.oauth.redirectUri,this._oAuthHandler.oauthSignIn(this._config.oauth.responseType,this._config.oauth.domain,c,l,u,s)),[3,4]):[3,1];case 1:u=e;try{(h=JSON.stringify(JSON.parse(this._storage.getItem("aws-amplify-federatedInfo")).user))&&je.warn("There is already a signed in user: "+h+" in your app.\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tYou should not call Auth.federatedSignIn method again as it may cause unexpected behavior.")}catch(e){}return d=t.token,p=t.identity_id,g=t.expires_at,[4,this.Credentials.set({provider:u,token:d,identity_id:p,user:i,expires_at:g},"federation")];case 2:return f=v.sent(),[4,this.currentAuthenticatedUser()];case 3:return m=v.sent(),qe("signIn",m,"A user "+m.username+" has been signed in"),je.debug("federated sign in credentials",f),[2,f];case 4:return[2]}var C})})},e.prototype._handleAuthResponse=function(e){return ze(this,void 0,void 0,function(){var t,i,r,n,s,o,a,l,c,u,h,d,p,f;return Ue(this,function(m){switch(m.label){case 0:if(this.oAuthFlowInProgress)return je.debug("Skipping URL "+e+" current flow in progress"),[2];m.label=1;case 1:if(m.trys.push([1,,8,9]),this.oAuthFlowInProgress=!0,!this._config.userPoolId)throw new Error("OAuth responses require a User Pool defined in config");if(qe("parsingCallbackUrl",{url:e},"The callback url is being parsed"),t=e||((0,g.gy)().isBrowser?window.location.href:""),i=!!((0,Ee.parse)(t).query||"").split("&").map(function(e){return e.split("=")}).find(function(e){var t=We(e,1)[0];return"code"===t||"error"===t}),r=!!((0,Ee.parse)(t).hash||"#").substr(1).split("&").map(function(e){return e.split("=")}).find(function(e){var t=We(e,1)[0];return"access_token"===t||"error"===t}),!i&&!r)return[3,7];this._storage.setItem("amplify-redirected-from-hosted-ui","true"),m.label=2;case 2:return m.trys.push([2,6,,7]),[4,this._oAuthHandler.handleAuthResponse(t)];case 3:return n=m.sent(),s=n.accessToken,o=n.idToken,a=n.refreshToken,l=n.state,c=new J({IdToken:new Y({IdToken:o}),RefreshToken:new Q({RefreshToken:a}),AccessToken:new $({AccessToken:s})}),u=void 0,this._config.identityPoolId?[4,this.Credentials.set(c,"session")]:[3,5];case 4:u=m.sent(),je.debug("AWS credentials",u),m.label=5;case 5:return h=/-/.test(l),(d=this.createCognitoUser(c.getIdToken().decodePayload()["cognito:username"])).setSignInUserSession(c),window&&void 0!==window.history&&window.history.replaceState({},null,this._config.oauth.redirectSignIn),qe("signIn",d,"A user "+d.getUsername()+" has been signed in"),qe("cognitoHostedUI",d,"A user "+d.getUsername()+" has been signed in via Cognito Hosted UI"),h&&(p=l.split("-").splice(1).join("-"),qe("customOAuthState",p.match(/.{2}/g).map(function(e){return String.fromCharCode(parseInt(e,16))}).join(""),"State for user "+d.getUsername())),[2,u];case 6:return f=m.sent(),je.debug("Error in cognito hosted auth response",f),window&&void 0!==window.history&&window.history.replaceState({},null,this._config.oauth.redirectSignIn),qe("signIn_failure",f,"The OAuth response flow failed"),qe("cognitoHostedUI_failure",f,"A failure occurred when returning to the Cognito Hosted UI"),qe("customState_failure",f,"A failure occurred when returning state"),[3,7];case 7:return[3,9];case 8:return this.oAuthFlowInProgress=!1,[7];case 9:return[2]}})})},e.prototype.essentialCredentials=function(e){return{accessKeyId:e.accessKeyId,sessionToken:e.sessionToken,secretAccessKey:e.secretAccessKey,identityId:e.identityId,authenticated:e.authenticated}},e.prototype.attributesToObject=function(e){var t=this,i={};return e&&e.map(function(e){"email_verified"===e.Name||"phone_number_verified"===e.Name?i[e.Name]=t.isTruthyString(e.Value)||!0===e.Value:i[e.Name]=e.Value}),i},e.prototype.isTruthyString=function(e){return"function"==typeof e.toLowerCase&&"true"===e.toLowerCase()},e.prototype.createCognitoUser=function(e){var t={Username:e,Pool:this.userPool};t.Storage=this._storage;var i=this._config.authenticationFlowType,r=new le(t);return i&&r.setAuthenticationFlowType(i),r},e.prototype._isValidAuthStorage=function(e){return!!e&&"function"==typeof e.getItem&&"function"==typeof e.setItem&&"function"==typeof e.removeItem&&"function"==typeof e.clear},e.prototype.noUserPoolErrorHandler=function(e){return!e||e.userPoolId&&e.identityPoolId?n.NoConfig:n.MissingAuthConfig},e.prototype.rejectAuthError=function(e){return Promise.reject(new Ge(e))},e.prototype.rejectNoUserPool=function(){var e=this.noUserPoolErrorHandler(this._config);return Promise.reject(new Ve(e))},e.prototype.rememberDevice=function(){return ze(this,void 0,void 0,function(){var e,t;return Ue(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.currentUserPoolUser()];case 1:return e=i.sent(),[3,3];case 2:return t=i.sent(),je.debug("The user is not authenticated by the error",t),[2,Promise.reject("The user is not authenticated")];case 3:return e.getCachedDeviceKeyAndPassword(),[2,new Promise(function(t,i){e.setDeviceStatusRemembered({onSuccess:function(e){t(e)},onFailure:function(e){"InvalidParameterException"===e.code?i(new Ge(n.DeviceConfig)):"NetworkError"===e.code?i(new Ge(n.NetworkError)):i(e)}})})]}})})},e.prototype.forgetDevice=function(){return ze(this,void 0,void 0,function(){var e,t;return Ue(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.currentUserPoolUser()];case 1:return e=i.sent(),[3,3];case 2:return t=i.sent(),je.debug("The user is not authenticated by the error",t),[2,Promise.reject("The user is not authenticated")];case 3:return e.getCachedDeviceKeyAndPassword(),[2,new Promise(function(t,i){e.forgetDevice({onSuccess:function(e){t(e)},onFailure:function(e){"InvalidParameterException"===e.code?i(new Ge(n.DeviceConfig)):"NetworkError"===e.code?i(new Ge(n.NetworkError)):i(e)}})})]}})})},e.prototype.fetchDevices=function(){return ze(this,void 0,void 0,function(){var e,t;return Ue(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,this.currentUserPoolUser()];case 1:return e=i.sent(),[3,3];case 2:throw t=i.sent(),je.debug("The user is not authenticated by the error",t),new Error("The user is not authenticated");case 3:return e.getCachedDeviceKeyAndPassword(),[2,new Promise(function(t,i){var r={onSuccess:function(e){var i=e.Devices.map(function(e){var t=e.DeviceAttributes.find(function(e){return"device_name"===e.Name})||{};return{id:e.DeviceKey,name:t.Value}});t(i)},onFailure:function(e){"InvalidParameterException"===e.code?i(new Ge(n.DeviceConfig)):"NetworkError"===e.code?i(new Ge(n.NetworkError)):i(e)}};e.listDevices(60,null,r)})]}})})},e}(),Qe=new Ye(null);C.HA.register(Qe)},78953(e,t,i){"use strict";i.d(t,{HA:()=>s});var r=i(15567),n=new r.C("Amplify"),s=new(function(){function e(){this._components=[],this._config={},this._modules={},this.Auth=null,this.Analytics=null,this.API=null,this.Credentials=null,this.Storage=null,this.I18n=null,this.Cache=null,this.PubSub=null,this.Interactions=null,this.Pushnotification=null,this.UI=null,this.XR=null,this.Predictions=null,this.DataStore=null,this.Geo=null,this.Logger=r.C,this.ServiceWorker=null}return e.prototype.register=function(e){n.debug("component registered in amplify",e),this._components.push(e),"function"==typeof e.getModuleName?(this._modules[e.getModuleName()]=e,this[e.getModuleName()]=e):n.debug("no getModuleName method for component",e),e.configure(this._config)},e.prototype.configure=function(e){var t=this;return e?(this._config=Object.assign(this._config,e),n.debug("amplify config",this._config),Object.entries(this._modules).forEach(function(e){var i=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o}(e,2),r=(i[0],i[1]);Object.keys(r).forEach(function(e){t._modules[e]&&(r[e]=t._modules[e])})}),this._components.map(function(e){e.configure(t._config)}),this._config):this._config},e.prototype.addPluggable=function(e){e&&e.getCategory&&"function"==typeof e.getCategory&&this._components.map(function(t){t.addPluggable&&"function"==typeof t.addPluggable&&t.addPluggable(e)})},e}())},11351(e,t,i){"use strict";i.d(t,{Ji:()=>zt});var r,n,s,o,a,l,c,u,h,d,p,g,f,m,v,C,y,w,S,b,E,A,T,M,R,_,P,x,D,I,L,N,O,F,k,G,V,H,B,z,U,W,j,K,$,q,Y,Q,X,Z,J,ee,te,ie,re,ne,se,oe,ae=i(15567),le=i(75315),ce=i(51678),ue=(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),he=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},de=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},pe=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},ge=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(pe(arguments[t]));return e},fe=new ae.C("Util"),me=function(e){function t(t){var i=e.call(this,t)||this;return i.nonRetryable=!0,i}return ue(t,e),t}(Error),ve=3e5,Ce=new ae.C("CognitoCredentials"),ye=new Promise(function(e,t){return(0,ce.gy)().isBrowser?window.gapi&&window.gapi.auth2&&window.gapi.auth2?(Ce.debug("google api already loaded"),e()):void setTimeout(function(){return e()},2e3):(Ce.debug("not in the browser, directly resolved"),e())}),we=function(){function e(){this.initialized=!1,this.refreshGoogleToken=this.refreshGoogleToken.bind(this),this._refreshGoogleTokenImpl=this._refreshGoogleTokenImpl.bind(this)}return e.prototype.refreshGoogleToken=function(){return e=this,t=void 0,r=function(){return function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}(this,function(e){switch(e.label){case 0:return this.initialized?[3,2]:(Ce.debug("need to wait for the Google SDK loaded"),[4,ye]);case 1:e.sent(),this.initialized=!0,Ce.debug("finish waiting"),e.label=2;case 2:return[2,this._refreshGoogleTokenImpl()]}})},new((i=void 0)||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())});var e,t,i,r},e.prototype._refreshGoogleTokenImpl=function(){var e=null;return(0,ce.gy)().isBrowser&&(e=window.gapi&&window.gapi.auth2?window.gapi.auth2:null),e?new Promise(function(t,i){e.getAuthInstance().then(function(e){e||(Ce.debug("google Auth undefined"),i(new me("google Auth undefined")));var r=e.currentUser.get();r.isSignedIn()?(Ce.debug("refreshing the google access token"),r.reloadAuthResponse().then(function(e){var i=e.id_token,r=e.expires_at;t({token:i,expires_at:r})}).catch(function(e){e&&"network_error"===e.error?i("Network error reloading google auth response"):i(new me("Failed to reload google auth response"))})):i(new me("User is not signed in with Google"))}).catch(function(e){Ce.debug("Failed to refresh google token",e),i(new me("Failed to refresh google token"))})}):(Ce.debug("no gapi auth2 available"),Promise.reject("no gapi auth2 available"))},e}(),Se=new ae.C("CognitoCredentials"),be=new Promise(function(e,t){return(0,ce.gy)().isBrowser?window.FB?(Se.debug("FB SDK already loaded"),e()):void setTimeout(function(){return e()},2e3):(Se.debug("not in the browser, directly resolved"),e())}),Ee=function(){function e(){this.initialized=!1,this.refreshFacebookToken=this.refreshFacebookToken.bind(this),this._refreshFacebookTokenImpl=this._refreshFacebookTokenImpl.bind(this)}return e.prototype.refreshFacebookToken=function(){return e=this,t=void 0,r=function(){return function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}(this,function(e){switch(e.label){case 0:return this.initialized?[3,2]:(Se.debug("need to wait for the Facebook SDK loaded"),[4,be]);case 1:e.sent(),this.initialized=!0,Se.debug("finish waiting"),e.label=2;case 2:return[2,this._refreshFacebookTokenImpl()]}})},new((i=void 0)||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())});var e,t,i,r},e.prototype._refreshFacebookTokenImpl=function(){var e=null;if((0,ce.gy)().isBrowser&&(e=window.FB),!e){var t="no fb sdk available";return Se.debug(t),Promise.reject(new me(t))}return new Promise(function(t,i){e.getLoginStatus(function(e){if(e&&e.authResponse){var r=e.authResponse,n=r.accessToken,s=1e3*r.expiresIn+(new Date).getTime();n||(o="the jwtToken is undefined",Se.debug(o),i(new me(o))),t({token:n,expires_at:s})}else{var o="no response from facebook when refreshing the jwt token";Se.debug(o),i(new me(o))}},{scope:"public_profile,email"})})},e}(),Ae=new we,Te=new Ee,Me=i(78953),Re=i(65927),_e=i(65959);!function(e){e.AUTHENTICATED_ROLE="AuthenticatedRole",e.DENY="Deny"}(n||(n={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(s||(s={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(o||(o={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(a||(a={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(l||(l={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(c||(c={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(u||(u={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(h||(h={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(d||(d={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(p||(p={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(g||(g={})),function(e){e.ACCESS_DENIED="AccessDenied",e.INTERNAL_SERVER_ERROR="InternalServerError"}(f||(f={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(m||(m={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(v||(v={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(C||(C={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(y||(y={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(w||(w={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(S||(S={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(b||(b={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(E||(E={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(A||(A={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(T||(T={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(M||(M={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(R||(R={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(_||(_={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(P||(P={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(x||(x={})),function(e){e.CONTAINS="Contains",e.EQUALS="Equals",e.NOT_EQUAL="NotEqual",e.STARTS_WITH="StartsWith"}(D||(D={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(I||(I={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(L||(L={})),function(e){e.RULES="Rules",e.TOKEN="Token"}(N||(N={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(O||(O={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(F||(F={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(k||(k={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(G||(G={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(V||(V={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(H||(H={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(B||(B={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(z||(z={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(U||(U={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(W||(W={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(j||(j={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(K||(K={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}($||($={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(q||(q={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(Y||(Y={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(Q||(Q={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(X||(X={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(Z||(Z={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(J||(J={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(ee||(ee={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(te||(te={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(ie||(ie={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(re||(re={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(ne||(ne={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(se||(se={})),function(e){e.filterSensitiveLog=function(e){return(0,_e.__assign)({},e)}}(oe||(oe={}));var Pe=i(59027),xe=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u,h,d,p,g,f,m;return(0,_e.__generator)(this,function(v){switch(v.label){case 0:return r=[(0,_e.__assign)({},e)],m={},[4,et(e.body,t)];case 1:switch(i=_e.__assign.apply(void 0,r.concat([(m.body=v.sent(),m)])),s="UnknownError",s=tt(e,i.body)){case"ExternalServiceException":case"com.amazonaws.cognitoidentity#ExternalServiceException":return[3,2];case"InternalErrorException":case"com.amazonaws.cognitoidentity#InternalErrorException":return[3,4];case"InvalidIdentityPoolConfigurationException":case"com.amazonaws.cognitoidentity#InvalidIdentityPoolConfigurationException":return[3,6];case"InvalidParameterException":case"com.amazonaws.cognitoidentity#InvalidParameterException":return[3,8];case"NotAuthorizedException":case"com.amazonaws.cognitoidentity#NotAuthorizedException":return[3,10];case"ResourceConflictException":case"com.amazonaws.cognitoidentity#ResourceConflictException":return[3,12];case"ResourceNotFoundException":case"com.amazonaws.cognitoidentity#ResourceNotFoundException":return[3,14];case"TooManyRequestsException":case"com.amazonaws.cognitoidentity#TooManyRequestsException":return[3,16]}return[3,18];case 2:return o=[{}],[4,Ie(i,t)];case 3:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,o.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 4:return a=[{}],[4,Le(i,t)];case 5:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,a.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 6:return l=[{}],[4,Ne(i,t)];case 7:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,l.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 8:return c=[{}],[4,Oe(i,t)];case 9:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,c.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 10:return u=[{}],[4,ke(i,t)];case 11:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,u.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 12:return h=[{}],[4,Ge(i,t)];case 13:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,h.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 14:return d=[{}],[4,Ve(i,t)];case 15:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,d.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 16:return p=[{}],[4,He(i,t)];case 17:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,p.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 18:g=i.body,s=g.code||g.Code||s,n=(0,_e.__assign)((0,_e.__assign)({},g),{name:""+s,message:g.message||g.Message||s,$fault:"client",$metadata:Ze(e)}),v.label=19;case 19:return f=n.message||n.Message||s,n.message=f,delete n.Message,[2,Promise.reject(Object.assign(new Error(f),n))]}})})},De=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r,n,s,o,a,l,c,u,h,d,p,g,f,m;return(0,_e.__generator)(this,function(v){switch(v.label){case 0:return r=[(0,_e.__assign)({},e)],m={},[4,et(e.body,t)];case 1:switch(i=_e.__assign.apply(void 0,r.concat([(m.body=v.sent(),m)])),s="UnknownError",s=tt(e,i.body)){case"ExternalServiceException":case"com.amazonaws.cognitoidentity#ExternalServiceException":return[3,2];case"InternalErrorException":case"com.amazonaws.cognitoidentity#InternalErrorException":return[3,4];case"InvalidParameterException":case"com.amazonaws.cognitoidentity#InvalidParameterException":return[3,6];case"LimitExceededException":case"com.amazonaws.cognitoidentity#LimitExceededException":return[3,8];case"NotAuthorizedException":case"com.amazonaws.cognitoidentity#NotAuthorizedException":return[3,10];case"ResourceConflictException":case"com.amazonaws.cognitoidentity#ResourceConflictException":return[3,12];case"ResourceNotFoundException":case"com.amazonaws.cognitoidentity#ResourceNotFoundException":return[3,14];case"TooManyRequestsException":case"com.amazonaws.cognitoidentity#TooManyRequestsException":return[3,16]}return[3,18];case 2:return o=[{}],[4,Ie(i,t)];case 3:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,o.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 4:return a=[{}],[4,Le(i,t)];case 5:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,a.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 6:return l=[{}],[4,Oe(i,t)];case 7:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,l.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 8:return c=[{}],[4,Fe(i,t)];case 9:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,c.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 10:return u=[{}],[4,ke(i,t)];case 11:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,u.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 12:return h=[{}],[4,Ge(i,t)];case 13:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,h.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 14:return d=[{}],[4,Ve(i,t)];case 15:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,d.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 16:return p=[{}],[4,He(i,t)];case 17:return n=_e.__assign.apply(void 0,[_e.__assign.apply(void 0,p.concat([v.sent()])),{name:s,$metadata:Ze(e)}]),[3,19];case 18:g=i.body,s=g.code||g.Code||s,n=(0,_e.__assign)((0,_e.__assign)({},g),{name:""+s,message:g.message||g.Message||s,$fault:"client",$metadata:Ze(e)}),v.label=19;case 19:return f=n.message||n.Message||s,n.message=f,delete n.Message,[2,Promise.reject(Object.assign(new Error(f),n))]}})})},Ie=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=Ue(i,t),[2,(0,_e.__assign)({name:"ExternalServiceException",$fault:"client",$metadata:Ze(e)},r)]})})},Le=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=We(i,t),[2,(0,_e.__assign)({name:"InternalErrorException",$fault:"server",$metadata:Ze(e)},r)]})})},Ne=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=je(i,t),[2,(0,_e.__assign)({name:"InvalidIdentityPoolConfigurationException",$fault:"client",$metadata:Ze(e)},r)]})})},Oe=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=Ke(i,t),[2,(0,_e.__assign)({name:"InvalidParameterException",$fault:"client",$metadata:Ze(e)},r)]})})},Fe=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=$e(i,t),[2,(0,_e.__assign)({name:"LimitExceededException",$fault:"client",$metadata:Ze(e)},r)]})})},ke=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=qe(i,t),[2,(0,_e.__assign)({name:"NotAuthorizedException",$fault:"client",$metadata:Ze(e)},r)]})})},Ge=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=Ye(i,t),[2,(0,_e.__assign)({name:"ResourceConflictException",$fault:"client",$metadata:Ze(e)},r)]})})},Ve=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=Qe(i,t),[2,(0,_e.__assign)({name:"ResourceNotFoundException",$fault:"client",$metadata:Ze(e)},r)]})})},He=function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i=e.body,r=Xe(i,t),[2,(0,_e.__assign)({name:"TooManyRequestsException",$fault:"client",$metadata:Ze(e)},r)]})})},Be=function(e,t){return Object.entries(e).reduce(function(e,t){var i,r=(0,_e.__read)(t,2),n=r[0],s=r[1];return null===s?e:(0,_e.__assign)((0,_e.__assign)({},e),((i={})[n]=s,i))},{})},ze=function(e,t){return{AccessKeyId:void 0!==e.AccessKeyId&&null!==e.AccessKeyId?e.AccessKeyId:void 0,Expiration:void 0!==e.Expiration&&null!==e.Expiration?new Date(Math.round(1e3*e.Expiration)):void 0,SecretKey:void 0!==e.SecretKey&&null!==e.SecretKey?e.SecretKey:void 0,SessionToken:void 0!==e.SessionToken&&null!==e.SessionToken?e.SessionToken:void 0}},Ue=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},We=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},je=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},Ke=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},$e=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},qe=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},Ye=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},Qe=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},Xe=function(e,t){return{message:void 0!==e.message&&null!==e.message?e.message:void 0}},Ze=function(e){var t;return{httpStatusCode:e.statusCode,requestId:null!==(t=e.headers["x-amzn-requestid"])&&void 0!==t?t:e.headers["x-amzn-request-id"],extendedRequestId:e.headers["x-amz-id-2"],cfId:e.headers["x-amz-cf-id"]}},Je=function(e,t,i,r,n){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var s,o,a,l,c,u;return(0,_e.__generator)(this,function(h){switch(h.label){case 0:return[4,e.endpoint()];case 1:return s=h.sent(),o=s.hostname,a=s.protocol,l=void 0===a?"https":a,c=s.port,u={protocol:l,hostname:o,port:c,method:"POST",path:i,headers:t},void 0!==r&&(u.hostname=r),void 0!==n&&(u.body=n),[2,new Pe.Kd(u)]}})})},et=function(e,t){return function(e,t){return function(e,t){return void 0===e&&(e=new Uint8Array),e instanceof Uint8Array?Promise.resolve(e):t.streamCollector(e)||Promise.resolve(new Uint8Array)}(e,t).then(function(e){return t.utf8Encoder(e)})}(e,t).then(function(e){return e.length?JSON.parse(e):{}})},tt=function(e,t){var i,r=function(e){var t=e;return t.indexOf(":")>=0&&(t=t.split(":")[0]),t.indexOf("#")>=0&&(t=t.split("#")[1]),t},n=(i=e.headers,Object.keys(i).find(function(e){return e.toLowerCase()==="x-amzn-errortype".toLowerCase()}));return void 0!==n?r(e.headers[n]):void 0!==t.code?r(t.code):void 0!==t.__type?r(t.__type):""},it=i(74052),rt=i(11538),nt=function(e){function t(t){var i=e.call(this)||this;return i.input=t,i}return(0,_e.__extends)(t,e),t.prototype.resolveMiddleware=function(e,t,i){this.middlewareStack.use((0,it.TM)(t,this.serialize,this.deserialize));var r=e.concat(this.middlewareStack),n={logger:t.logger,clientName:"CognitoIdentityClient",commandName:"GetCredentialsForIdentityCommand",inputFilterSensitiveLog:A.filterSensitiveLog,outputFilterSensitiveLog:M.filterSensitiveLog},s=t.requestHandler;return r.resolve(function(e){return s.handle(e.request,i||{})},n)},t.prototype.serialize=function(e,t){return function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i={"content-type":"application/x-amz-json-1.1","x-amz-target":"AWSCognitoIdentityService.GetCredentialsForIdentity"},r=JSON.stringify(function(e,t){return(0,_e.__assign)((0,_e.__assign)((0,_e.__assign)({},void 0!==e.CustomRoleArn&&null!==e.CustomRoleArn&&{CustomRoleArn:e.CustomRoleArn}),void 0!==e.IdentityId&&null!==e.IdentityId&&{IdentityId:e.IdentityId}),void 0!==e.Logins&&null!==e.Logins&&{Logins:Be(e.Logins,t)})}(e,t)),[2,Je(t,i,"/",void 0,r)]})})}(e,t)},t.prototype.deserialize=function(e,t){return function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r,n;return(0,_e.__generator)(this,function(s){switch(s.label){case 0:return e.statusCode>=300?[2,xe(e,t)]:[4,et(e.body,t)];case 1:return i=s.sent(),r=function(e){return{Credentials:void 0!==e.Credentials&&null!==e.Credentials?ze(e.Credentials):void 0,IdentityId:void 0!==e.IdentityId&&null!==e.IdentityId?e.IdentityId:void 0}}(i),n=(0,_e.__assign)({$metadata:Ze(e)},r),[2,Promise.resolve(n)]}})})}(e,t)},t}(rt.uB),st=function(e){function t(t,i){void 0===i&&(i=!0);var r=e.call(this,t)||this;return r.tryNextLink=i,r}return(0,Re.__extends)(t,e),t}(Error);function ot(e){return Promise.all(Object.keys(e).reduce(function(t,i){var r=e[i];return"string"==typeof r?t.push([i,r]):t.push(r().then(function(e){return[i,e]})),t},[])).then(function(e){return e.reduce(function(e,t){var i=(0,Re.__read)(t,2),r=i[0],n=i[1];return e[r]=n,e},{})})}function at(e){var t=this;return function(){return(0,Re.__awaiter)(t,void 0,void 0,function(){var t,i,r,n,s,o,a,l,c,u,h,d,p;return(0,Re.__generator)(this,function(g){switch(g.label){case 0:return u=(c=e.client).send,h=nt.bind,p={CustomRoleArn:e.customRoleArn,IdentityId:e.identityId},e.logins?[4,ot(e.logins)]:[3,2];case 1:return d=g.sent(),[3,3];case 2:d=void 0,g.label=3;case 3:return[4,u.apply(c,[new(h.apply(nt,[void 0,(p.Logins=d,p)]))])];case 4:return t=g.sent().Credentials,i=void 0===t?function(){throw new st("Response from Amazon Cognito contained no credentials")}():t,r=i.AccessKeyId,n=void 0===r?function(){throw new st("Response from Amazon Cognito contained no access key ID")}():r,s=i.Expiration,o=i.SecretKey,a=void 0===o?function(){throw new st("Response from Amazon Cognito contained no secret key")}():o,l=i.SessionToken,[2,{identityId:e.identityId,accessKeyId:n,secretAccessKey:a,sessionToken:l,expiration:s}]}})})}}var lt=function(e){function t(t){var i=e.call(this)||this;return i.input=t,i}return(0,_e.__extends)(t,e),t.prototype.resolveMiddleware=function(e,t,i){this.middlewareStack.use((0,it.TM)(t,this.serialize,this.deserialize));var r=e.concat(this.middlewareStack),n={logger:t.logger,clientName:"CognitoIdentityClient",commandName:"GetIdCommand",inputFilterSensitiveLog:_.filterSensitiveLog,outputFilterSensitiveLog:P.filterSensitiveLog},s=t.requestHandler;return r.resolve(function(e){return s.handle(e.request,i||{})},n)},t.prototype.serialize=function(e,t){return function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r;return(0,_e.__generator)(this,function(n){return i={"content-type":"application/x-amz-json-1.1","x-amz-target":"AWSCognitoIdentityService.GetId"},r=JSON.stringify(function(e,t){return(0,_e.__assign)((0,_e.__assign)((0,_e.__assign)({},void 0!==e.AccountId&&null!==e.AccountId&&{AccountId:e.AccountId}),void 0!==e.IdentityPoolId&&null!==e.IdentityPoolId&&{IdentityPoolId:e.IdentityPoolId}),void 0!==e.Logins&&null!==e.Logins&&{Logins:Be(e.Logins,t)})}(e,t)),[2,Je(t,i,"/",void 0,r)]})})}(e,t)},t.prototype.deserialize=function(e,t){return function(e,t){return(0,_e.__awaiter)(void 0,void 0,void 0,function(){var i,r,n;return(0,_e.__generator)(this,function(s){switch(s.label){case 0:return e.statusCode>=300?[2,De(e,t)]:[4,et(e.body,t)];case 1:return i=s.sent(),r=function(e){return{IdentityId:void 0!==e.IdentityId&&null!==e.IdentityId?e.IdentityId:void 0}}(i),n=(0,_e.__assign)({$metadata:Ze(e)},r),[2,Promise.resolve(n)]}})})}(e,t)},t}(rt.uB),ct="IdentityIds",ut=function(){function e(e){void 0===e&&(e="aws:cognito-identity-ids"),this.dbName=e}return e.prototype.getItem=function(e){return this.withObjectStore("readonly",function(t){var i=t.get(e);return new Promise(function(e){i.onerror=function(){return e(null)},i.onsuccess=function(){return e(i.result?i.result.value:null)}})}).catch(function(){return null})},e.prototype.removeItem=function(e){return this.withObjectStore("readwrite",function(t){var i=t.delete(e);return new Promise(function(e,t){i.onerror=function(){return t(i.error)},i.onsuccess=function(){return e()}})})},e.prototype.setItem=function(e,t){return this.withObjectStore("readwrite",function(i){var r=i.put({id:e,value:t});return new Promise(function(e,t){r.onerror=function(){return t(r.error)},r.onsuccess=function(){return e()}})})},e.prototype.getDb=function(){var e=self.indexedDB.open(this.dbName,1);return new Promise(function(t,i){e.onsuccess=function(){t(e.result)},e.onerror=function(){i(e.error)},e.onblocked=function(){i(new Error("Unable to access DB"))},e.onupgradeneeded=function(){var t=e.result;t.onerror=function(){i(new Error("Failed to create object store"))},t.createObjectStore(ct,{keyPath:"id"})}})},e.prototype.withObjectStore=function(e,t){return this.getDb().then(function(i){var r=i.transaction(ct,e);return r.oncomplete=function(){return i.close()},new Promise(function(e,i){r.onerror=function(){return i(r.error)},e(t(r.objectStore(ct)))}).catch(function(e){throw i.close(),e})})},e}(),ht=new(function(){function e(e){void 0===e&&(e={}),this.store=e}return e.prototype.getItem=function(e){return e in this.store?this.store[e]:null},e.prototype.removeItem=function(e){delete this.store[e]},e.prototype.setItem=function(e,t){this.store[e]=t},e}());var dt=i(54218),pt=i(22292),gt=i(10078),ft=i(16307),mt=i(68380),vt=i(93972),Ct=i(39448),yt=i(31643),wt="cognito-identity.{region}.amazonaws.com",St=new Set(["af-south-1","ap-east-1","ap-northeast-1","ap-northeast-2","ap-south-1","ap-southeast-1","ap-southeast-2","ca-central-1","eu-central-1","eu-north-1","eu-south-1","eu-west-1","eu-west-2","eu-west-3","me-south-1","sa-east-1","us-east-1","us-east-2","us-west-1","us-west-2"]),bt=new Set(["cn-north-1","cn-northwest-1"]),Et=new Set(["us-iso-east-1"]),At=new Set(["us-isob-east-1"]),Tt=new Set(["us-gov-east-1","us-gov-west-1"]),Mt={apiVersion:"2014-06-30",disableHostPrefix:!1,logger:{},regionInfoProvider:function(e,t){var i=void 0;switch(e){case"ap-northeast-1":i={hostname:"cognito-identity.ap-northeast-1.amazonaws.com",partition:"aws"};break;case"ap-northeast-2":i={hostname:"cognito-identity.ap-northeast-2.amazonaws.com",partition:"aws"};break;case"ap-south-1":i={hostname:"cognito-identity.ap-south-1.amazonaws.com",partition:"aws"};break;case"ap-southeast-1":i={hostname:"cognito-identity.ap-southeast-1.amazonaws.com",partition:"aws"};break;case"ap-southeast-2":i={hostname:"cognito-identity.ap-southeast-2.amazonaws.com",partition:"aws"};break;case"ca-central-1":i={hostname:"cognito-identity.ca-central-1.amazonaws.com",partition:"aws"};break;case"cn-north-1":i={hostname:"cognito-identity.cn-north-1.amazonaws.com.cn",partition:"aws-cn"};break;case"eu-central-1":i={hostname:"cognito-identity.eu-central-1.amazonaws.com",partition:"aws"};break;case"eu-north-1":i={hostname:"cognito-identity.eu-north-1.amazonaws.com",partition:"aws"};break;case"eu-west-1":i={hostname:"cognito-identity.eu-west-1.amazonaws.com",partition:"aws"};break;case"eu-west-2":i={hostname:"cognito-identity.eu-west-2.amazonaws.com",partition:"aws"};break;case"eu-west-3":i={hostname:"cognito-identity.eu-west-3.amazonaws.com",partition:"aws"};break;case"fips-us-east-1":i={hostname:"cognito-identity-fips.us-east-1.amazonaws.com",partition:"aws",signingRegion:"us-east-1"};break;case"fips-us-east-2":i={hostname:"cognito-identity-fips.us-east-2.amazonaws.com",partition:"aws",signingRegion:"us-east-2"};break;case"fips-us-gov-west-1":i={hostname:"cognito-identity-fips.us-gov-west-1.amazonaws.com",partition:"aws-us-gov",signingRegion:"us-gov-west-1"};break;case"fips-us-west-2":i={hostname:"cognito-identity-fips.us-west-2.amazonaws.com",partition:"aws",signingRegion:"us-west-2"};break;case"sa-east-1":i={hostname:"cognito-identity.sa-east-1.amazonaws.com",partition:"aws"};break;case"us-east-1":i={hostname:"cognito-identity.us-east-1.amazonaws.com",partition:"aws"};break;case"us-east-2":i={hostname:"cognito-identity.us-east-2.amazonaws.com",partition:"aws"};break;case"us-gov-west-1":i={hostname:"cognito-identity.us-gov-west-1.amazonaws.com",partition:"aws-us-gov"};break;case"us-west-1":i={hostname:"cognito-identity.us-west-1.amazonaws.com",partition:"aws"};break;case"us-west-2":i={hostname:"cognito-identity.us-west-2.amazonaws.com",partition:"aws"};break;default:St.has(e)&&(i={hostname:wt.replace("{region}",e),partition:"aws"}),bt.has(e)&&(i={hostname:"cognito-identity.{region}.amazonaws.com.cn".replace("{region}",e),partition:"aws-cn"}),Et.has(e)&&(i={hostname:"cognito-identity.{region}.c2s.ic.gov".replace("{region}",e),partition:"aws-iso"}),At.has(e)&&(i={hostname:"cognito-identity.{region}.sc2s.sgov.gov".replace("{region}",e),partition:"aws-iso-b"}),Tt.has(e)&&(i={hostname:"cognito-identity.{region}.amazonaws.com".replace("{region}",e),partition:"aws-us-gov"}),void 0===i&&(i={hostname:wt.replace("{region}",e),partition:"aws"})}return Promise.resolve((0,_e.__assign)({signingService:"cognito-identity"},i))},serviceId:"Cognito Identity",urlParser:i(2049).D},Rt=(0,_e.__assign)((0,_e.__assign)({},Mt),{runtime:"browser",base64Decoder:mt.E,base64Encoder:mt.n,bodyLengthChecker:vt.n,credentialDefaultProvider:function(e){return function(){return Promise.reject(new Error("Credential is missing"))}},defaultUserAgentProvider:(0,Ct.m)({serviceId:Mt.serviceId,clientVersion:"3.6.1"}),maxAttempts:ft.Gz,region:(0,gt.B)("Region is missing"),requestHandler:new pt.N,sha256:dt.Sha256,streamCollector:pt.k,utf8Decoder:yt.fromUtf8,utf8Encoder:yt.toUtf8}),_t=i(85775),Pt=i(23788),xt=i(14188),Dt=i(64996),It=i(88428),Lt=i(44625),Nt=function(e){function t(t){var i=this,r=(0,_e.__assign)((0,_e.__assign)({},Rt),t),n=(0,_t.TD)(r),s=(0,_t.vJ)(n),o=(0,It.k9)(s),a=(0,ft.$z)(o),l=(0,xt.OV)(a),c=(0,Lt.Dc)(l);return(i=e.call(this,c)||this).config=c,i.middlewareStack.use((0,ft.ey)(i.config)),i.middlewareStack.use((0,Pt.vK)(i.config)),i.middlewareStack.use((0,xt.TC)(i.config)),i.middlewareStack.use((0,Dt.Y7)(i.config)),i.middlewareStack.use((0,Lt.sM)(i.config)),i}return(0,_e.__extends)(t,e),t.prototype.destroy=function(){e.prototype.destroy.call(this)},t}(rt.Kj),Ot=i(41547),Ft=function(){return Ft=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Ft.apply(this,arguments)};function kt(e){var t=new Nt({region:e.region,customUserAgent:(0,Ot.fE)()});return t.middlewareStack.add(function(e,t){return function(t){return e(function(e){return Ft(Ft({},e),{request:Ft(Ft({},e.request),{headers:Ft(Ft({},e.request.headers),{"cache-control":"no-store"})})})}(t))}},{step:"build",name:"cacheControlMiddleWare"}),t}var Gt=function(){return Gt=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},Gt.apply(this,arguments)},Vt=function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},Ht=function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},Bt=new ae.C("Credentials"),zt=new(function(){function e(e){this._gettingCredPromise=null,this._refreshHandlers={},this.Auth=void 0,this.configure(e),this._refreshHandlers.google=Ae.refreshGoogleToken,this._refreshHandlers.facebook=Te.refreshFacebookToken}return e.prototype.getModuleName=function(){return"Credentials"},e.prototype.getCredSource=function(){return this._credentials_source},e.prototype.configure=function(e){if(!e)return this._config||{};this._config=Object.assign({},this._config,e);var t=this._config.refreshHandlers;return t&&(this._refreshHandlers=Gt(Gt({},this._refreshHandlers),t)),this._storage=this._config.storage,this._storage||(this._storage=(new le.i1).getStorage()),this._storageSync=Promise.resolve(),"function"==typeof this._storage.sync&&(this._storageSync=this._storage.sync()),this._config},e.prototype.get=function(){return Bt.debug("getting credentials"),this._pickupCredentials()},e.prototype._getCognitoIdentityIdStorageKey=function(e){return"CognitoIdentityId-"+e},e.prototype._pickupCredentials=function(){return Bt.debug("picking up credentials"),this._gettingCredPromise&&this._gettingCredPromise.isPending()?Bt.debug("getting old cred promise"):(Bt.debug("getting new cred promise"),this._gettingCredPromise=(0,ce.VN)(this._keepAlive())),this._gettingCredPromise},e.prototype._keepAlive=function(){return Vt(this,void 0,void 0,function(){var e,t,i,r,n,s,o;return Ht(this,function(a){switch(a.label){case 0:if(Bt.debug("checking if credentials exists and not expired"),(e=this._credentials)&&!this._isExpired(e)&&!this._isPastTTL())return Bt.debug("credentials not changed and not expired, directly return"),[2,Promise.resolve(e)];if(Bt.debug("need to get a new credential or refresh the existing one"),t=this.Auth,!(i=void 0===t?Me.HA.Auth:t)||"function"!=typeof i.currentUserCredentials)return[2,Promise.reject("No Auth module registered in Amplify")];if(this._isExpired(e)||!this._isPastTTL())return[3,6];Bt.debug("ttl has passed but token is not yet expired"),a.label=1;case 1:return a.trys.push([1,5,,6]),[4,i.currentUserPoolUser()];case 2:return r=a.sent(),[4,i.currentSession()];case 3:return n=a.sent(),s=n.refreshToken,[4,new Promise(function(e,t){r.refreshSession(s,function(i,r){return i?t(i):e(r)})})];case 4:return a.sent(),[3,6];case 5:return o=a.sent(),Bt.debug("Error attempting to refreshing the session",o),[3,6];case 6:return[2,i.currentUserCredentials()]}})})},e.prototype.refreshFederatedToken=function(e){Bt.debug("Getting federated credentials");var t=e.provider,i=e.user,r=e.token,n=e.identity_id,s=e.expires_at;s=1970===new Date(s).getFullYear()?1e3*s:s;var o=this;return Bt.debug("checking if federated jwt token expired"),s>(new Date).getTime()?(Bt.debug("token not expired"),this._setCredentialsFromFederation({provider:t,token:r,user:i,identity_id:n,expires_at:s})):o._refreshHandlers[t]&&"function"==typeof o._refreshHandlers[t]?(Bt.debug("getting refreshed jwt token from federation provider"),this._providerRefreshWithRetry({refreshHandler:o._refreshHandlers[t],provider:t,user:i})):(Bt.debug("no refresh handler for provider:",t),this.clear(),Promise.reject("no refresh handler for provider"))},e.prototype._providerRefreshWithRetry=function(e){var t,i,r,n,s=this,o=e.refreshHandler,a=e.provider,l=e.user;return(t=o,i=[],r=1e4,void 0===r&&(r=ve),function(e,t,i,r){return he(this,void 0,void 0,function(){var n=this;return de(this,function(s){if("function"!=typeof e)throw Error("functionToRetry must be a function");return[2,new Promise(function(s,o){return he(n,void 0,void 0,function(){var n,a,l,c,u,h,d;return de(this,function(p){switch(p.label){case 0:n=0,a=!1,c=function(){},r&&r.then(function(){a=!0,clearTimeout(l),c()}),h=function(){var r,h,d,p;return de(this,function(g){switch(g.label){case 0:n++,fe.debug(e.name+" attempt #"+n+" with this vars: "+JSON.stringify(t)),g.label=1;case 1:return g.trys.push([1,3,,7]),r={},h=s,[4,e.apply(void 0,ge(t))];case 2:return[2,(r.value=h.apply(void 0,[g.sent()]),r)];case 3:return d=g.sent(),u=d,fe.debug("error on "+e.name,d),(f=d)&&f.nonRetryable?(fe.debug(e.name+" non retryable error",d),[2,{value:o(d)}]):(p=i(n,t,d),fe.debug(e.name+" retrying in "+p+" ms"),!1===p||a?[2,{value:o(d)}]:[3,4]);case 4:return[4,new Promise(function(e){c=e,l=setTimeout(c,p)})];case 5:g.sent(),g.label=6;case 6:return[3,7];case 7:return[2]}var f})},p.label=1;case 1:return a?[3,3]:[5,h()];case 2:return"object"==typeof(d=p.sent())?[2,d.value]:[3,1];case 3:return o(u),[2]}})})})]})})}(t,i,function(e){return void 0===e&&(e=ve),function(t){var i=100*Math.pow(2,t)+100*Math.random();return!(i>e)&&i}}(r),n)).then(function(e){return Bt.debug("refresh federated token sucessfully",e),s._setCredentialsFromFederation({provider:a,token:e.token,user:l,identity_id:e.identity_id,expires_at:e.expires_at})}).catch(function(e){return"string"==typeof e&&0===e.toLowerCase().lastIndexOf("network error",e.length)||s.clear(),Bt.debug("refresh federated token failed",e),Promise.reject("refreshing federation token failed: "+e)})},e.prototype._isExpired=function(e){if(!e)return Bt.debug("no credentials for expiration check"),!0;Bt.debug("are these credentials expired?",e);var t=Date.now();return e.expiration.getTime()<=t},e.prototype._isPastTTL=function(){return this._nextCredentialsRefresh<=Date.now()},e.prototype._setCredentialsForGuest=function(){return Vt(this,void 0,void 0,function(){var e,t,i,r,n,s,o,a,l=this;return Ht(this,function(c){switch(c.label){case 0:return Bt.debug("setting credentials for guest"),e=this._config,t=e.identityPoolId,i=e.region,e.mandatorySignIn?[2,Promise.reject("cannot get guest credentials when mandatory signin enabled")]:t?i?(n=this,[4,this._getGuestIdentityId()]):(Bt.debug("region is not configured for getting the credentials"),[2,Promise.reject("region is not configured for getting the credentials")]):(Bt.debug("No Cognito Identity pool provided for unauthenticated access"),[2,Promise.reject("No Cognito Identity pool provided for unauthenticated access")]);case 1:return r=n._identityId=c.sent(),s=kt({region:i}),o=void 0,r?o=at({identityId:r,client:s})():(a=function(){return Vt(l,void 0,void 0,function(){var e;return Ht(this,function(i){switch(i.label){case 0:return[4,s.send(new lt({IdentityPoolId:t}))];case 1:return e=i.sent().IdentityId,this._identityId=e,[2,at({client:s,identityId:e})()]}})})},o=a().catch(function(e){return Vt(l,void 0,void 0,function(){return Ht(this,function(t){throw e})})})),[2,this._loadCredentials(o,"guest",!1,null).then(function(e){return e}).catch(function(e){return Vt(l,void 0,void 0,function(){var i,n=this;return Ht(this,function(a){switch(a.label){case 0:return"ResourceNotFoundException"!==e.name||e.message!=="Identity '"+r+"' not found."?[3,2]:(Bt.debug("Failed to load guest credentials"),[4,this._removeGuestIdentityId()]);case 1:return a.sent(),i=function(){return Vt(n,void 0,void 0,function(){var e;return Ht(this,function(i){switch(i.label){case 0:return[4,s.send(new lt({IdentityPoolId:t}))];case 1:return e=i.sent().IdentityId,this._identityId=e,[2,at({client:s,identityId:e})()]}})})},o=i().catch(function(e){return Vt(n,void 0,void 0,function(){return Ht(this,function(t){throw e})})}),[2,this._loadCredentials(o,"guest",!1,null)];case 2:return[2,e]}})})})]}})})},e.prototype._setCredentialsFromFederation=function(e){var t=e.provider,i=e.token,r=e.identity_id,n={google:"accounts.google.com",facebook:"graph.facebook.com",amazon:"www.amazon.com",developer:"cognito-identity.amazonaws.com"}[t]||t;if(!n)return Promise.reject("You must specify a federated provider");var s={};s[n]=i;var o=this._config,a=o.identityPoolId,l=o.region;if(!a)return Bt.debug("No Cognito Federated Identity pool provided"),Promise.reject("No Cognito Federated Identity pool provided");if(!l)return Bt.debug("region is not configured for getting the credentials"),Promise.reject("region is not configured for getting the credentials");var c=kt({region:l}),u=void 0;return u=r?at({identityId:r,logins:s,client:c})():function(e){var t=this,i=e.accountId,r=e.cache,n=void 0===r?"object"==typeof self&&self.indexedDB?new ut:"object"==typeof window&&window.localStorage?window.localStorage:ht:r,s=e.client,o=e.customRoleArn,a=e.identityPoolId,l=e.logins,c=e.userIdentifier,u=void 0===c?l&&0!==Object.keys(l).length?void 0:"ANONYMOUS":c,h=u?"aws:cognito-identity-credentials:"+a+":"+u:void 0,d=function(){return(0,Re.__awaiter)(t,void 0,void 0,function(){var e,t,r,c,u,p,g,f,m;return(0,Re.__generator)(this,function(v){switch(v.label){case 0:return(t=h)?[4,n.getItem(h)]:[3,2];case 1:t=v.sent(),v.label=2;case 2:return(e=t)?[3,7]:(p=(u=s).send,g=lt.bind,m={AccountId:i,IdentityPoolId:a},l?[4,ot(l)]:[3,4]);case 3:return f=v.sent(),[3,5];case 4:f=void 0,v.label=5;case 5:return[4,p.apply(u,[new(g.apply(lt,[void 0,(m.Logins=f,m)]))])];case 6:r=v.sent().IdentityId,c=void 0===r?function(){throw new st("Response from Amazon Cognito contained no identity ID")}():r,e=c,h&&Promise.resolve(n.setItem(h,e)).catch(function(){}),v.label=7;case 7:return[2,(d=at({client:s,customRoleArn:o,logins:l,identityId:e}))()]}})})};return function(){return d().catch(function(e){return(0,Re.__awaiter)(t,void 0,void 0,function(){return(0,Re.__generator)(this,function(t){throw h&&Promise.resolve(n.removeItem(h)).catch(function(){}),e})})})}}({logins:s,identityPoolId:a,client:c})(),this._loadCredentials(u,"federated",!0,e)},e.prototype._setCredentialsFromSession=function(e){var t=this;Bt.debug("set credentials from session");var i=e.getIdToken().getJwtToken(),r=this._config,n=r.region,s=r.userPoolId,o=r.identityPoolId;if(!o)return Bt.debug("No Cognito Federated Identity pool provided"),Promise.reject("No Cognito Federated Identity pool provided");if(!n)return Bt.debug("region is not configured for getting the credentials"),Promise.reject("region is not configured for getting the credentials");var a={};a["cognito-idp."+n+".amazonaws.com/"+s]=i;var l=kt({region:n}),c=Vt(t,void 0,void 0,function(){var e,t,i,r,n,s,c,u,h,d;return Ht(this,function(p){switch(p.label){case 0:return[4,this._getGuestIdentityId()];case 1:return(e=p.sent())?[3,3]:[4,l.send(new lt({IdentityPoolId:o,Logins:a}))];case 2:i=p.sent().IdentityId,t=i,p.label=3;case 3:return[4,l.send(new nt({IdentityId:e||t,Logins:a}))];case 4:return r=p.sent(),n=r.Credentials,s=n.AccessKeyId,c=n.Expiration,u=n.SecretKey,h=n.SessionToken,d=r.IdentityId,this._identityId=d,e?(Bt.debug("The guest identity "+e+" has been successfully linked to the logins"),e===d&&Bt.debug("The guest identity "+e+" has become the primary identity"),[4,this._removeGuestIdentityId()]):[3,6];case 5:p.sent(),p.label=6;case 6:return[2,{accessKeyId:s,secretAccessKey:u,sessionToken:h,expiration:c,identityId:d}]}})}).catch(function(e){return Vt(t,void 0,void 0,function(){return Ht(this,function(t){throw e})})});return this._loadCredentials(c,"userPool",!0,null)},e.prototype._loadCredentials=function(e,t,i,r){var n=this,s=this;return new Promise(function(o,a){e.then(function(e){return Vt(n,void 0,void 0,function(){var n,a,l,c,u;return Ht(this,function(h){switch(h.label){case 0:if(Bt.debug("Load credentials successfully",e),this._identityId&&!e.identityId&&(e.identityId=this._identityId),s._credentials=e,s._credentials.authenticated=i,s._credentials_source=t,s._nextCredentialsRefresh=(new Date).getTime()+3e6,"federated"===t){n=Object.assign({id:this._credentials.identityId},r.user),a=r.provider,l=r.token,c=r.expires_at,u=r.identity_id;try{this._storage.setItem("aws-amplify-federatedInfo",JSON.stringify({provider:a,token:l,user:n,expires_at:c,identity_id:u}))}catch(e){Bt.debug("Failed to put federated info into auth storage",e)}}return"guest"!==t?[3,2]:[4,this._setGuestIdentityId(e.identityId)];case 1:h.sent(),h.label=2;case 2:return o(s._credentials),[2]}})})}).catch(function(t){if(t)return Bt.debug("Failed to load credentials",e),Bt.debug("Error loading credentials",t),void a(t)})})},e.prototype.set=function(e,t){return"session"===t?this._setCredentialsFromSession(e):"federation"===t?this._setCredentialsFromFederation(e):"guest"===t?this._setCredentialsForGuest():(Bt.debug("no source specified for setting credentials"),Promise.reject("invalid source"))},e.prototype.clear=function(){return Vt(this,void 0,void 0,function(){return Ht(this,function(e){return this._credentials=null,this._credentials_source=null,Bt.debug("removing aws-amplify-federatedInfo from storage"),this._storage.removeItem("aws-amplify-federatedInfo"),[2]})})},e.prototype._getGuestIdentityId=function(){return Vt(this,void 0,void 0,function(){var e,t;return Ht(this,function(i){switch(i.label){case 0:e=this._config.identityPoolId,i.label=1;case 1:return i.trys.push([1,3,,4]),[4,this._storageSync];case 2:return i.sent(),[2,this._storage.getItem(this._getCognitoIdentityIdStorageKey(e))];case 3:return t=i.sent(),Bt.debug("Failed to get the cached guest identityId",t),[3,4];case 4:return[2]}})})},e.prototype._setGuestIdentityId=function(e){return Vt(this,void 0,void 0,function(){var t,i;return Ht(this,function(r){switch(r.label){case 0:t=this._config.identityPoolId,r.label=1;case 1:return r.trys.push([1,3,,4]),[4,this._storageSync];case 2:return r.sent(),this._storage.setItem(this._getCognitoIdentityIdStorageKey(t),e),[3,4];case 3:return i=r.sent(),Bt.debug("Failed to cache guest identityId",i),[3,4];case 4:return[2]}})})},e.prototype._removeGuestIdentityId=function(){return Vt(this,void 0,void 0,function(){var e;return Ht(this,function(t){return e=this._config.identityPoolId,Bt.debug("removing "+this._getCognitoIdentityIdStorageKey(e)+" from storage"),this._storage.removeItem(this._getCognitoIdentityIdStorageKey(e)),[2]})})},e.prototype.shear=function(e){return{accessKeyId:e.accessKeyId,sessionToken:e.sessionToken,secretAccessKey:e.secretAccessKey,identityId:e.identityId,authenticated:e.authenticated}},e}())(null);Me.HA.register(zt)},51718(e,t,i){"use strict";i.d(t,{YZ:()=>c});var r=i(15567),n=function(){return n=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},n.apply(this,arguments)},s=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},o=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(s(arguments[t]));return e},a=new r.C("Hub"),l="undefined"!=typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("amplify_default"):"@@amplify_default",c=new(function(){function e(e){this.listeners=[],this.patterns=[],this.protectedChannels=["core","auth","api","analytics","interactions","pubsub","storage","ui","xr"],this.name=e}return e.prototype.remove=function(e,t){if(e instanceof RegExp){var i=this.patterns.find(function(t){return t.pattern.source===e.source});if(!i)return void a.warn("No listeners for "+e);this.patterns=o(this.patterns.filter(function(e){return e!==i}))}else{var r=this.listeners[e];if(!r)return void a.warn("No listeners for "+e);this.listeners[e]=o(r.filter(function(e){return e.callback!==t}))}},e.prototype.dispatch=function(e,t,i,r){void 0===i&&(i=""),this.protectedChannels.indexOf(e)>-1&&(r===l||a.warn("WARNING: "+e+" is protected and dispatching on it can have unintended consequences"));var s={channel:e,payload:n({},t),source:i,patternInfo:[]};try{this._toListeners(s)}catch(e){a.error(e)}},e.prototype.listen=function(e,t,i){var r,n=this;if(void 0===i&&(i="noname"),function(e){return void 0!==e.onHubCapsule}(t))a.warn("WARNING onHubCapsule is Deprecated. Please pass in a callback."),r=t.onHubCapsule.bind(t);else{if("function"!=typeof t)throw new Error("No callback supplied to Hub");r=t}if(e instanceof RegExp)this.patterns.push({pattern:e,callback:r});else{var s=this.listeners[e];s||(s=[],this.listeners[e]=s),s.push({name:i,callback:r})}return function(){n.remove(e,r)}},e.prototype._toListeners=function(e){var t=e.channel,i=e.payload,r=this.listeners[t];if(r&&r.forEach(function(r){a.debug("Dispatching to "+t+" with ",i);try{r.callback(e)}catch(e){a.error(e)}}),this.patterns.length>0){if(!i.message)return void a.warn("Cannot perform pattern matching without a message key");var o=i.message;this.patterns.forEach(function(t){var i=o.match(t.pattern);if(i){var r=s(i).slice(1),l=n(n({},e),{patternInfo:r});try{t.callback(l)}catch(e){a.error(e)}}})}},e}())("__default__")},51678(e,t,i){"use strict";i.d(t,{JS:()=>v,VN:()=>h,gy:()=>p});var r=i(85409),n=[{type:"text/plain",ext:"txt"},{type:"text/html",ext:"html"},{type:"text/javascript",ext:"js"},{type:"text/css",ext:"css"},{type:"text/csv",ext:"csv"},{type:"text/yaml",ext:"yml"},{type:"text/yaml",ext:"yaml"},{type:"text/calendar",ext:"ics"},{type:"text/calendar",ext:"ical"},{type:"image/apng",ext:"apng"},{type:"image/bmp",ext:"bmp"},{type:"image/gif",ext:"gif"},{type:"image/x-icon",ext:"ico"},{type:"image/x-icon",ext:"cur"},{type:"image/jpeg",ext:"jpg"},{type:"image/jpeg",ext:"jpeg"},{type:"image/jpeg",ext:"jfif"},{type:"image/jpeg",ext:"pjp"},{type:"image/jpeg",ext:"pjpeg"},{type:"image/png",ext:"png"},{type:"image/svg+xml",ext:"svg"},{type:"image/tiff",ext:"tif"},{type:"image/tiff",ext:"tiff"},{type:"image/webp",ext:"webp"},{type:"application/json",ext:"json"},{type:"application/xml",ext:"xml"},{type:"application/x-sh",ext:"sh"},{type:"application/zip",ext:"zip"},{type:"application/x-rar-compressed",ext:"rar"},{type:"application/x-tar",ext:"tar"},{type:"application/x-bzip",ext:"bz"},{type:"application/x-bzip2",ext:"bz2"},{type:"application/pdf",ext:"pdf"},{type:"application/java-archive",ext:"jar"},{type:"application/msword",ext:"doc"},{type:"application/vnd.ms-excel",ext:"xls"},{type:"application/vnd.ms-excel",ext:"xlsx"},{type:"message/rfc822",ext:"eml"}],s=function(e){return void 0===e&&(e={}),0===Object.keys(e).length},o=function(e,t,i){if(!e||!e.sort)return!1;var r=i&&"desc"===i?-1:1;return e.sort(function(e,i){var n=e[t],s=i[t];return void 0===s?void 0===n?0:1*r:void 0===n||n<s?-1*r:n>s?1*r:0}),!0},a=function(e,t){var i=Object.assign({},e);return t&&("string"==typeof t?delete i[t]:t.forEach(function(e){delete i[e]})),i},l=function(e,t){void 0===t&&(t="application/octet-stream");var i=e.toLowerCase(),r=n.filter(function(e){return i.endsWith("."+e.ext)});return r.length>0?r[0].type:t},c=function(e){var t=e.toLowerCase();return!!t.startsWith("text/")||"application/json"===t||"application/xml"===t||"application/sh"===t},u=function(){for(var e="",t=32;t>0;t-=1)e+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return e},h=function(e){if(e.isResolved)return e;var t=!0,i=!1,r=!1,n=e.then(function(e){return r=!0,t=!1,e},function(e){throw i=!0,t=!1,e});return n.isFullfilled=function(){return r},n.isPending=function(){return t},n.isRejected=function(){return i},n},d=function(){if("undefined"==typeof self)return!1;var e=self;return void 0!==e.WorkerGlobalScope&&self instanceof e.WorkerGlobalScope},p=function(){return{isBrowser:"undefined"!=typeof window&&void 0!==window.document,isNode:void 0!==r&&null!=r.versions&&null!=r.versions.node}},g=function(e,t,i){if(void 0===t&&(t=[]),void 0===i&&(i=[]),!m(e))return e;var r={};for(var n in e)e.hasOwnProperty(n)&&(r[t.includes(n)?n:n[0].toLowerCase()+n.slice(1)]=i.includes(n)?e[n]:g(e[n],t,i));return r},f=function(e,t,i){if(void 0===t&&(t=[]),void 0===i&&(i=[]),!m(e))return e;var r={};for(var n in e)e.hasOwnProperty(n)&&(r[t.includes(n)?n:n[0].toUpperCase()+n.slice(1)]=i.includes(n)?e[n]:f(e[n],t,i));return r},m=function(e){return!(!(e instanceof Object)||e instanceof Array||e instanceof Function||e instanceof Number||e instanceof String||e instanceof Boolean)},v=function(){function e(){}return e.isEmpty=s,e.sortByField=o,e.objectLessAttributes=a,e.filenameToContentType=l,e.isTextFile=c,e.generateRandomString=u,e.makeQuerablePromise=h,e.isWebWorker=d,e.browserOrNode=p,e.transferKeyToLowerCase=g,e.transferKeyToUpperCase=f,e.isStrictObject=m,e}()},15567(e,t,i){"use strict";i.d(t,{C:()=>a});var r,n=function(e,t){var i="function"==typeof Symbol&&e[Symbol.iterator];if(!i)return e;var r,n,s=i.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(r=s.next()).done;)o.push(r.value)}catch(e){n={error:e}}finally{try{r&&!r.done&&(i=s.return)&&i.call(s)}finally{if(n)throw n.error}}return o},s=function(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(n(arguments[t]));return e},o={VERBOSE:1,DEBUG:2,INFO:3,WARN:4,ERROR:5};!function(e){e.DEBUG="DEBUG",e.ERROR="ERROR",e.INFO="INFO",e.WARN="WARN",e.VERBOSE="VERBOSE"}(r||(r={}));var a=function(){function e(e,t){void 0===t&&(t=r.WARN),this.name=e,this.level=t,this._pluggables=[]}return e.prototype._padding=function(e){return e<10?"0"+e:""+e},e.prototype._ts=function(){var e=new Date;return[this._padding(e.getMinutes()),this._padding(e.getSeconds())].join(":")+"."+e.getMilliseconds()},e.prototype.configure=function(e){return e?(this._config=e,this._config):this._config},e.prototype._log=function(t){for(var i,n,s=[],a=1;a<arguments.length;a++)s[a-1]=arguments[a];var l=this.level;if(e.LOG_LEVEL&&(l=e.LOG_LEVEL),"undefined"!=typeof window&&window.LOG_LEVEL&&(l=window.LOG_LEVEL),o[t]>=o[l]){var c=console.log.bind(console);t===r.ERROR&&console.error&&(c=console.error.bind(console)),t===r.WARN&&console.warn&&(c=console.warn.bind(console));var u="["+t+"] "+this._ts()+" "+this.name,h="";if(1===s.length&&"string"==typeof s[0])c(h=u+" - "+s[0]);else if(1===s.length)h=u+" "+s[0],c(u,s[0]);else if("string"==typeof s[0]){var d=s.slice(1);1===d.length&&(d=d[0]),h=u+" - "+s[0]+" "+d,c(u+" - "+s[0],d)}else h=u+" "+s,c(u,s);try{for(var p=function(e){var t="function"==typeof Symbol&&Symbol.iterator,i=t&&e[t],r=0;if(i)return i.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}(this._pluggables),g=p.next();!g.done;g=p.next()){var f=g.value,m={message:h,timestamp:Date.now()};f.pushLogs([m])}}catch(e){i={error:e}}finally{try{g&&!g.done&&(n=p.return)&&n.call(p)}finally{if(i)throw i.error}}}},e.prototype.log=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.INFO],e))},e.prototype.info=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.INFO],e))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.WARN],e))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.ERROR],e))},e.prototype.debug=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.DEBUG],e))},e.prototype.verbose=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._log.apply(this,s([r.VERBOSE],e))},e.prototype.addPluggable=function(e){e&&"Logging"===e.getCategoryName()&&(this._pluggables.push(e),e.configure(this._config))},e.prototype.listPluggables=function(){return this._pluggables},e.LOG_LEVEL=null,e}()},410(e,t,i){"use strict";i.d(t,{iX:()=>a});var r=i(15567),n=function(){return n=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},n.apply(this,arguments)},s=new r.C("Parser"),o=function(e){var t,i={};if(e.aws_mobile_analytics_app_id){var r={AWSPinpoint:{appId:e.aws_mobile_analytics_app_id,region:e.aws_mobile_analytics_app_region}};i.Analytics=r}return(e.aws_cognito_identity_pool_id||e.aws_user_pools_id)&&(i.Auth={userPoolId:e.aws_user_pools_id,userPoolWebClientId:e.aws_user_pools_web_client_id,region:e.aws_cognito_region,identityPoolId:e.aws_cognito_identity_pool_id,identityPoolRegion:e.aws_cognito_region,mandatorySignIn:"enable"===e.aws_mandatory_sign_in,signUpVerificationMethod:e.aws_cognito_sign_up_verification_method||"code"}),t=e.aws_user_files_s3_bucket?{AWSS3:{bucket:e.aws_user_files_s3_bucket,region:e.aws_user_files_s3_bucket_region,dangerouslyConnectToHttpEndpointForTesting:e.aws_user_files_s3_dangerously_connect_to_http_endpoint_for_testing}}:e?e.Storage||e:{},e.Logging&&(i.Logging=n(n({},e.Logging),{region:e.aws_project_region})),e.geo&&(i.Geo=Object.assign({},e.geo),e.geo.amazon_location_service&&(i.Geo={AmazonLocationService:e.geo.amazon_location_service})),i.Analytics=Object.assign({},i.Analytics,e.Analytics),i.Auth=Object.assign({},i.Auth,e.Auth),i.Storage=Object.assign({},t),i.Logging=Object.assign({},i.Logging,e.Logging),s.debug("parse config",e,"to amplifyconfig",i),i},a=function(){function e(){}return e.parseMobilehubConfig=o,e}()},41547(e,t,i){"use strict";i.d(t,{fE:()=>s});var r="aws-amplify/4.7.14",n={userAgent:r+" js",product:"",navigator:null,isReactNative:!1};"undefined"!=typeof navigator&&navigator.product&&(n.product=navigator.product||"",n.navigator=navigator||null,"ReactNative"===navigator.product?(n.userAgent=r+" react-native",n.isReactNative=!0):(n.userAgent=r+" js",n.isReactNative=!1));var s=function(e){return""+n.userAgent+(e||"")}},75315(e,t,i){"use strict";i.d(t,{i1:()=>s});var r={},n=function(){function e(){}return e.setItem=function(e,t){return r[e]=t,r[e]},e.getItem=function(e){return Object.prototype.hasOwnProperty.call(r,e)?r[e]:void 0},e.removeItem=function(e){return delete r[e]},e.clear=function(){return r={}},e}(),s=function(){function e(){try{this.storageWindow=window.localStorage,this.storageWindow.setItem("aws.amplify.test-ls",1),this.storageWindow.removeItem("aws.amplify.test-ls")}catch(e){this.storageWindow=n}}return e.prototype.getStorage=function(){return this.storageWindow},e}()},56692(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},36637(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},21516(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},19840(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},15784(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isMsWindow=void 0;var i=["decrypt","digest","encrypt","exportKey","generateKey","importKey","sign","verify"];t.isMsWindow=function(e){if(function(e){return"MSInputMethodContext"in e&&"msCrypto"in e}(e)&&void 0!==e.msCrypto.subtle){var t=e.msCrypto,r=t.getRandomValues,n=t.subtle;return i.map(function(e){return n[e]}).concat(r).every(function(e){return"function"==typeof e})}return!1}},10098(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(65927);r.__exportStar(i(56692),t),r.__exportStar(i(36637),t),r.__exportStar(i(21516),t),r.__exportStar(i(19840),t),r.__exportStar(i(15784),t)},90843(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.EMPTY_DATA_SHA_256=t.SHA_256_HMAC_ALGO=t.SHA_256_HASH=void 0,t.SHA_256_HASH={name:"SHA-256"},t.SHA_256_HMAC_ALGO={name:"HMAC",hash:t.SHA_256_HASH},t.EMPTY_DATA_SHA_256=new Uint8Array([227,176,196,66,152,252,28,20,154,251,244,200,153,111,185,36,39,174,65,228,100,155,147,76,164,149,153,27,120,82,184,85])},87098(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sha256=void 0;var r=i(25515),n=i(22038),s=i(18558),o=i(91014),a=i(10098),l=i(1632),c=function(){function e(e){(0,o.supportsWebCrypto)((0,l.locateWindow)())?this.hash=new n.Sha256(e):(0,a.isMsWindow)((0,l.locateWindow)())?this.hash=new r.Sha256(e):this.hash=new s.Sha256(e)}return e.prototype.update=function(e,t){this.hash.update(e,t)},e.prototype.digest=function(){return this.hash.digest()},e}();t.Sha256=c},25515(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sha256=void 0;var r=i(27755),n=i(90843),s=i(31643),o=i(1632),a=function(){function e(e){e?(this.operation=function(e){return new Promise(function(t,i){var r=(0,o.locateWindow)().msCrypto.subtle.importKey("raw",l(e),n.SHA_256_HMAC_ALGO,!1,["sign"]);r.oncomplete=function(){r.result&&t(r.result),i(new Error("ImportKey completed without importing key."))},r.onerror=function(){i(new Error("ImportKey failed to import key."))}})}(e).then(function(e){return(0,o.locateWindow)().msCrypto.subtle.sign(n.SHA_256_HMAC_ALGO,e)}),this.operation.catch(function(){})):this.operation=Promise.resolve((0,o.locateWindow)().msCrypto.subtle.digest("SHA-256"))}return e.prototype.update=function(e){var t=this;(0,r.isEmptyData)(e)||(this.operation=this.operation.then(function(i){return i.onerror=function(){t.operation=Promise.reject(new Error("Error encountered updating hash"))},i.process(l(e)),i}),this.operation.catch(function(){}))},e.prototype.digest=function(){return this.operation.then(function(e){return new Promise(function(t,i){e.onerror=function(){i(new Error("Error encountered finalizing hash"))},e.oncomplete=function(){e.result&&t(new Uint8Array(e.result)),i(new Error("Error encountered finalizing hash"))},e.finish()})})},e}();function l(e){return"string"==typeof e?(0,s.fromUtf8)(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}t.Sha256=a},54218(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WebCryptoSha256=t.Ie11Sha256=void 0,(0,i(65927).__exportStar)(i(87098),t);var r=i(25515);Object.defineProperty(t,"Ie11Sha256",{enumerable:!0,get:function(){return r.Sha256}});var n=i(22038);Object.defineProperty(t,"WebCryptoSha256",{enumerable:!0,get:function(){return n.Sha256}})},27755(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isEmptyData=void 0,t.isEmptyData=function(e){return"string"==typeof e?0===e.length:0===e.byteLength}},22038(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sha256=void 0;var r=i(47062),n=i(90843),s=i(1632),o=function(){function e(e){this.toHash=new Uint8Array(0),void 0!==e&&(this.key=new Promise(function(t,i){(0,s.locateWindow)().crypto.subtle.importKey("raw",(0,r.convertToBuffer)(e),n.SHA_256_HMAC_ALGO,!1,["sign"]).then(t,i)}),this.key.catch(function(){}))}return e.prototype.update=function(e){if(!(0,r.isEmptyData)(e)){var t=(0,r.convertToBuffer)(e),i=new Uint8Array(this.toHash.byteLength+t.byteLength);i.set(this.toHash,0),i.set(t,this.toHash.byteLength),this.toHash=i}},e.prototype.digest=function(){var e=this;return this.key?this.key.then(function(t){return(0,s.locateWindow)().crypto.subtle.sign(n.SHA_256_HMAC_ALGO,t,e.toHash).then(function(e){return new Uint8Array(e)})}):(0,r.isEmptyData)(this.toHash)?Promise.resolve(n.EMPTY_DATA_SHA_256):Promise.resolve().then(function(){return(0,s.locateWindow)().crypto.subtle.digest(n.SHA_256_HASH,e.toHash)}).then(function(e){return Promise.resolve(new Uint8Array(e))})},e}();t.Sha256=o},50930(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(17214),n=function(){function e(){this.state=Int32Array.from(r.INIT),this.temp=new Int32Array(64),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}return e.prototype.update=function(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");var t=0,i=e.byteLength;if(this.bytesHashed+=i,8*this.bytesHashed>r.MAX_HASHABLE_LENGTH)throw new Error("Cannot hash more than 2^53 - 1 bits");for(;i>0;)this.buffer[this.bufferLength++]=e[t++],i--,this.bufferLength===r.BLOCK_SIZE&&(this.hashBuffer(),this.bufferLength=0)},e.prototype.digest=function(){if(!this.finished){var e=8*this.bytesHashed,t=new DataView(this.buffer.buffer,this.buffer.byteOffset,this.buffer.byteLength),i=this.bufferLength;if(t.setUint8(this.bufferLength++,128),i%r.BLOCK_SIZE>=r.BLOCK_SIZE-8){for(var n=this.bufferLength;n<r.BLOCK_SIZE;n++)t.setUint8(n,0);this.hashBuffer(),this.bufferLength=0}for(n=this.bufferLength;n<r.BLOCK_SIZE-8;n++)t.setUint8(n,0);t.setUint32(r.BLOCK_SIZE-8,Math.floor(e/4294967296),!0),t.setUint32(r.BLOCK_SIZE-4,e),this.hashBuffer(),this.finished=!0}var s=new Uint8Array(r.DIGEST_LENGTH);for(n=0;n<8;n++)s[4*n]=this.state[n]>>>24&255,s[4*n+1]=this.state[n]>>>16&255,s[4*n+2]=this.state[n]>>>8&255,s[4*n+3]=this.state[n]>>>0&255;return s},e.prototype.hashBuffer=function(){for(var e=this.buffer,t=this.state,i=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],c=t[6],u=t[7],h=0;h<r.BLOCK_SIZE;h++){if(h<16)this.temp[h]=(255&e[4*h])<<24|(255&e[4*h+1])<<16|(255&e[4*h+2])<<8|255&e[4*h+3];else{var d=this.temp[h-2],p=(d>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,g=((d=this.temp[h-15])>>>7|d<<25)^(d>>>18|d<<14)^d>>>3;this.temp[h]=(p+this.temp[h-7]|0)+(g+this.temp[h-16]|0)}var f=(((a>>>6|a<<26)^(a>>>11|a<<21)^(a>>>25|a<<7))+(a&l^~a&c)|0)+(u+(r.KEY[h]+this.temp[h]|0)|0)|0,m=((i>>>2|i<<30)^(i>>>13|i<<19)^(i>>>22|i<<10))+(i&n^i&s^n&s)|0;u=c,c=l,l=a,a=o+f|0,o=s,s=n,n=i,i=f+m|0}t[0]+=i,t[1]+=n,t[2]+=s,t[3]+=o,t[4]+=a,t[5]+=l,t[6]+=c,t[7]+=u},e}();t.RawSha256=n},17214(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BLOCK_SIZE=64,t.DIGEST_LENGTH=32,t.KEY=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),t.INIT=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],t.MAX_HASHABLE_LENGTH=Math.pow(2,53)-1},56059(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),i(65927).__exportStar(i(15119),t)},15119(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(65927),n=i(17214),s=i(50930),o=i(94518),a=function(){function e(e){if(this.hash=new s.RawSha256,e){this.outer=new s.RawSha256;var t=function(e){var t=l(e);if(t.byteLength>n.BLOCK_SIZE){var i=new s.RawSha256;i.update(t),t=i.digest()}var r=new Uint8Array(n.BLOCK_SIZE);return r.set(t),r}(e),i=new Uint8Array(n.BLOCK_SIZE);i.set(t);for(var r=0;r<n.BLOCK_SIZE;r++)t[r]^=54,i[r]^=92;for(this.hash.update(t),this.outer.update(i),r=0;r<t.byteLength;r++)t[r]=0}}return e.prototype.update=function(e){if(!(t=e,("string"==typeof t?0===t.length:0===t.byteLength)||this.error))try{this.hash.update(l(e))}catch(e){this.error=e}var t},e.prototype.digestSync=function(){if(this.error)throw this.error;return this.outer?(this.outer.finished||this.outer.update(this.hash.digest()),this.outer.digest()):this.hash.digest()},e.prototype.digest=function(){return r.__awaiter(this,void 0,void 0,function(){return r.__generator(this,function(e){return[2,this.digestSync()]})})},e}();function l(e){return"string"==typeof e?o.fromUtf8(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}t.Sha256=a},615(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RawSha256=void 0;var r=i(44335),n=function(){function e(){this.state=Int32Array.from(r.INIT),this.temp=new Int32Array(64),this.buffer=new Uint8Array(64),this.bufferLength=0,this.bytesHashed=0,this.finished=!1}return e.prototype.update=function(e){if(this.finished)throw new Error("Attempted to update an already finished hash.");var t=0,i=e.byteLength;if(this.bytesHashed+=i,8*this.bytesHashed>r.MAX_HASHABLE_LENGTH)throw new Error("Cannot hash more than 2^53 - 1 bits");for(;i>0;)this.buffer[this.bufferLength++]=e[t++],i--,this.bufferLength===r.BLOCK_SIZE&&(this.hashBuffer(),this.bufferLength=0)},e.prototype.digest=function(){if(!this.finished){var e=8*this.bytesHashed,t=new DataView(this.buffer.buffer,this.buffer.byteOffset,this.buffer.byteLength),i=this.bufferLength;if(t.setUint8(this.bufferLength++,128),i%r.BLOCK_SIZE>=r.BLOCK_SIZE-8){for(var n=this.bufferLength;n<r.BLOCK_SIZE;n++)t.setUint8(n,0);this.hashBuffer(),this.bufferLength=0}for(n=this.bufferLength;n<r.BLOCK_SIZE-8;n++)t.setUint8(n,0);t.setUint32(r.BLOCK_SIZE-8,Math.floor(e/4294967296),!0),t.setUint32(r.BLOCK_SIZE-4,e),this.hashBuffer(),this.finished=!0}var s=new Uint8Array(r.DIGEST_LENGTH);for(n=0;n<8;n++)s[4*n]=this.state[n]>>>24&255,s[4*n+1]=this.state[n]>>>16&255,s[4*n+2]=this.state[n]>>>8&255,s[4*n+3]=this.state[n]>>>0&255;return s},e.prototype.hashBuffer=function(){for(var e=this.buffer,t=this.state,i=t[0],n=t[1],s=t[2],o=t[3],a=t[4],l=t[5],c=t[6],u=t[7],h=0;h<r.BLOCK_SIZE;h++){if(h<16)this.temp[h]=(255&e[4*h])<<24|(255&e[4*h+1])<<16|(255&e[4*h+2])<<8|255&e[4*h+3];else{var d=this.temp[h-2],p=(d>>>17|d<<15)^(d>>>19|d<<13)^d>>>10,g=((d=this.temp[h-15])>>>7|d<<25)^(d>>>18|d<<14)^d>>>3;this.temp[h]=(p+this.temp[h-7]|0)+(g+this.temp[h-16]|0)}var f=(((a>>>6|a<<26)^(a>>>11|a<<21)^(a>>>25|a<<7))+(a&l^~a&c)|0)+(u+(r.KEY[h]+this.temp[h]|0)|0)|0,m=((i>>>2|i<<30)^(i>>>13|i<<19)^(i>>>22|i<<10))+(i&n^i&s^n&s)|0;u=c,c=l,l=a,a=o+f|0,o=s,s=n,n=i,i=f+m|0}t[0]+=i,t[1]+=n,t[2]+=s,t[3]+=o,t[4]+=a,t[5]+=l,t[6]+=c,t[7]+=u},e}();t.RawSha256=n},44335(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MAX_HASHABLE_LENGTH=t.INIT=t.KEY=t.DIGEST_LENGTH=t.BLOCK_SIZE=void 0,t.BLOCK_SIZE=64,t.DIGEST_LENGTH=32,t.KEY=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),t.INIT=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],t.MAX_HASHABLE_LENGTH=Math.pow(2,53)-1},18558(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),(0,i(65927).__exportStar)(i(21048),t)},21048(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Sha256=void 0;var r=i(65927),n=i(44335),s=i(615),o=i(47062),a=function(){function e(e){if(this.hash=new s.RawSha256,e){this.outer=new s.RawSha256;var t=function(e){var t=(0,o.convertToBuffer)(e);if(t.byteLength>n.BLOCK_SIZE){var i=new s.RawSha256;i.update(t),t=i.digest()}var r=new Uint8Array(n.BLOCK_SIZE);return r.set(t),r}(e),i=new Uint8Array(n.BLOCK_SIZE);i.set(t);for(var r=0;r<n.BLOCK_SIZE;r++)t[r]^=54,i[r]^=92;for(this.hash.update(t),this.outer.update(i),r=0;r<t.byteLength;r++)t[r]=0}}return e.prototype.update=function(e){if(!(0,o.isEmptyData)(e)&&!this.error)try{this.hash.update((0,o.convertToBuffer)(e))}catch(e){this.error=e}},e.prototype.digestSync=function(){if(this.error)throw this.error;return this.outer?(this.outer.finished||this.outer.update(this.hash.digest()),this.outer.digest()):this.hash.digest()},e.prototype.digest=function(){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(e){return[2,this.digestSync()]})})},e}();t.Sha256=a},91014(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),i(65927).__exportStar(i(9301),t)},9301(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.supportsZeroByteGCM=t.supportsSubtleCrypto=t.supportsSecureRandom=t.supportsWebCrypto=void 0;var r=i(65927),n=["decrypt","digest","encrypt","exportKey","generateKey","importKey","sign","verify"];function s(e){return"object"==typeof e&&"object"==typeof e.crypto&&"function"==typeof e.crypto.getRandomValues}function o(e){return e&&n.every(function(t){return"function"==typeof e[t]})}t.supportsWebCrypto=function(e){return!(!s(e)||"object"!=typeof e.crypto.subtle)&&o(e.crypto.subtle)},t.supportsSecureRandom=s,t.supportsSubtleCrypto=o,t.supportsZeroByteGCM=function(e){return r.__awaiter(this,void 0,void 0,function(){var t;return r.__generator(this,function(i){switch(i.label){case 0:if(!o(e))return[2,!1];i.label=1;case 1:return i.trys.push([1,4,,5]),[4,e.generateKey({name:"AES-GCM",length:128},!1,["encrypt"])];case 2:return t=i.sent(),[4,e.encrypt({name:"AES-GCM",iv:new Uint8Array(Array(12)),additionalData:new Uint8Array(Array(16)),tagLength:128},t,new Uint8Array(0))];case 3:return[2,16===i.sent().byteLength];case 4:return i.sent(),[2,!1];case 5:return[2]}})})}},29046(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.convertToBuffer=void 0;var r=i(91486),n="undefined"!=typeof Buffer&&Buffer.from?function(e){return Buffer.from(e,"utf8")}:r.fromUtf8;t.convertToBuffer=function(e){return e instanceof Uint8Array?e:"string"==typeof e?n(e):ArrayBuffer.isView(e)?new Uint8Array(e.buffer,e.byteOffset,e.byteLength/Uint8Array.BYTES_PER_ELEMENT):new Uint8Array(e)}},47062(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.uint32ArrayFrom=t.numToUint8=t.isEmptyData=t.convertToBuffer=void 0;var r=i(29046);Object.defineProperty(t,"convertToBuffer",{enumerable:!0,get:function(){return r.convertToBuffer}});var n=i(69783);Object.defineProperty(t,"isEmptyData",{enumerable:!0,get:function(){return n.isEmptyData}});var s=i(41739);Object.defineProperty(t,"numToUint8",{enumerable:!0,get:function(){return s.numToUint8}});var o=i(77780);Object.defineProperty(t,"uint32ArrayFrom",{enumerable:!0,get:function(){return o.uint32ArrayFrom}})},69783(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isEmptyData=void 0,t.isEmptyData=function(e){return"string"==typeof e?0===e.length:0===e.byteLength}},41739(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.numToUint8=void 0,t.numToUint8=function(e){return new Uint8Array([(4278190080&e)>>24,(16711680&e)>>16,(65280&e)>>8,255&e])}},77780(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.uint32ArrayFrom=void 0,t.uint32ArrayFrom=function(e){if(!Array.from){for(var t=new Uint32Array(e.length);0<e.length;)t[0]=e[0];return t}return Uint32Array.from(e)}},85775(e,t,i){"use strict";i.d(t,{vJ:()=>n,TD:()=>a});var r=i(65927),n=function(e){var t;return(0,r.__assign)((0,r.__assign)({},e),{tls:null===(t=e.tls)||void 0===t||t,endpoint:e.endpoint?s(e):function(){return o(e)},isCustomEndpoint:!!e.endpoint})},s=function(e){var t=e.endpoint,i=e.urlParser;if("string"==typeof t){var r=Promise.resolve(i(t));return function(){return r}}if("object"==typeof t){var n=Promise.resolve(t);return function(){return n}}return t},o=function(e){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var t,i,n,s,o;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return t=e.tls,i=void 0===t||t,[4,e.region()];case 1:if(n=r.sent(),!new RegExp(/^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]{0,61}[a-zA-Z0-9])$/).test(n))throw new Error("Invalid region in client config");return[4,e.regionInfoProvider(n)];case 2:if(!(s=(null!==(o=r.sent())&&void 0!==o?o:{}).hostname))throw new Error("Cannot resolve hostname from client config");return[2,e.urlParser((i?"https:":"http:")+"//"+s)]}})})},a=function(e){if(!e.region)throw new Error("Region is missing");return(0,r.__assign)((0,r.__assign)({},e),{region:l(e.region)})},l=function(e){if("string"==typeof e){var t=Promise.resolve(e);return function(){return t}}return e}},22292(e,t,i){"use strict";i.d(t,{N:()=>o,k:()=>l});var r=i(65927),n=i(59027),s=i(2726),o=function(){function e(e){var t=(void 0===e?{}:e).requestTimeout;this.requestTimeout=t}return e.prototype.destroy=function(){},e.prototype.handle=function(e,t){var i=(void 0===t?{}:t).abortSignal,o=this.requestTimeout;if(null==i?void 0:i.aborted){var a=new Error("Request aborted");return a.name="AbortError",Promise.reject(a)}var l=e.path;if(e.query){var c=function(e){var t,i,n=[];try{for(var o=(0,r.__values)(Object.keys(e).sort()),a=o.next();!a.done;a=o.next()){var l=a.value,c=e[l];if(l=(0,s.o)(l),Array.isArray(c))for(var u=0,h=c.length;u<h;u++)n.push(l+"="+(0,s.o)(c[u]));else{var d=l;(c||"string"==typeof c)&&(d+="="+(0,s.o)(c)),n.push(d)}}}catch(e){t={error:e}}finally{try{a&&!a.done&&(i=o.return)&&i.call(o)}finally{if(t)throw t.error}}return n.join("&")}(e.query);c&&(l+="?"+c)}var u=e.port,h=e.method,d=e.protocol+"//"+e.hostname+(u?":"+u:"")+l,p={body:"GET"===h||"HEAD"===h?void 0:e.body,headers:new Headers(e.headers),method:h};"undefined"!=typeof AbortController&&(p.signal=i);var g,f=new Request(d,p),m=[fetch(f).then(function(e){var t,i,s=e.headers,o={};try{for(var a=(0,r.__values)(s.entries()),l=a.next();!l.done;l=a.next()){var c=l.value;o[c[0]]=c[1]}}catch(e){t={error:e}}finally{try{l&&!l.done&&(i=a.return)&&i.call(a)}finally{if(t)throw t.error}}return void 0!==e.body?{response:new n.cS({headers:o,statusCode:e.status,body:e.body})}:e.blob().then(function(t){return{response:new n.cS({headers:o,statusCode:e.status,body:t})}})}),(g=o,void 0===g&&(g=0),new Promise(function(e,t){g&&setTimeout(function(){var e=new Error("Request did not complete within "+g+" ms");e.name="TimeoutError",t(e)},g)}))];return i&&m.push(new Promise(function(e,t){i.onabort=function(){var e=new Error("Request aborted");e.name="AbortError",t(e)}})),Promise.race(m)},e}(),a=i(68380),l=function(e){return"function"==typeof Blob&&e instanceof Blob?function(e){return(0,r.__awaiter)(this,void 0,void 0,function(){var t,i;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return[4,c(e)];case 1:return t=r.sent(),i=(0,a.E)(t),[2,new Uint8Array(i)]}})})}(e):function(e){return(0,r.__awaiter)(this,void 0,void 0,function(){var t,i,n,s,o,a,l;return(0,r.__generator)(this,function(r){switch(r.label){case 0:t=new Uint8Array(0),i=e.getReader(),n=!1,r.label=1;case 1:return n?[3,3]:[4,i.read()];case 2:return s=r.sent(),o=s.done,(a=s.value)&&(l=t,(t=new Uint8Array(l.length+a.length)).set(l),t.set(a,l.length)),n=o,[3,1];case 3:return[2,t]}})})}(e)};function c(e){return new Promise(function(t,i){var r=new FileReader;r.onloadend=function(){var e;if(2!==r.readyState)return i(new Error("Reader aborted too early"));var n=null!==(e=r.result)&&void 0!==e?e:"",s=n.indexOf(","),o=s>-1?s+1:n.length;t(n.substring(o))},r.onabort=function(){return i(new Error("Read aborted"))},r.onerror=function(){return i(r.error)},r.readAsDataURL(e)})}},10078(e,t,i){"use strict";i.d(t,{B:()=>r});var r=function(e){return function(){return Promise.reject(e)}}},23788(e,t,i){"use strict";i.d(t,{vK:()=>a});var r=i(65927),n=i(59027),s="content-length",o={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},a=function(e){return{applyToStack:function(t){t.add(function(e){var t=this;return function(i){return function(o){return(0,r.__awaiter)(t,void 0,void 0,function(){var t,a,l,c,u;return(0,r.__generator)(this,function(h){return t=o.request,n.Kd.isInstance(t)&&(a=t.body,l=t.headers,a&&-1===Object.keys(l).map(function(e){return e.toLowerCase()}).indexOf(s)&&void 0!==(c=e(a))&&(t.headers=(0,r.__assign)((0,r.__assign)({},t.headers),((u={})[s]=String(c),u)))),[2,i((0,r.__assign)((0,r.__assign)({},o),{request:t}))]})})}}}(e.bodyLengthChecker),o)}}}},14188(e,t,i){"use strict";i.d(t,{OV:()=>s,TC:()=>a});var r=i(65927),n=i(59027);function s(e){return e}var o={name:"hostHeaderMiddleware",step:"build",priority:"low",tags:["HOST"],override:!0},a=function(e){return{applyToStack:function(t){t.add(function(e){return function(t){return function(i){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var s,o;return(0,r.__generator)(this,function(r){return n.Kd.isInstance(i.request)?(s=i.request,(void 0===(o=(e.requestHandler.metadata||{}).handlerProtocol)?"":o).indexOf("h2")>=0&&!s.headers[":authority"]?(delete s.headers.host,s.headers[":authority"]=""):s.headers.host||(s.headers.host=s.hostname),[2,t(i)]):[2,t(i)]})})}}}(e),o)}}}},64996(e,t,i){"use strict";i.d(t,{Y7:()=>s});var r=i(65927),n={name:"loggerMiddleware",tags:["LOGGER"],step:"initialize",override:!0},s=function(e){return{applyToStack:function(e){e.add(function(e,t){return function(i){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var n,s,o,a,l,c,u,h,d;return(0,r.__generator)(this,function(p){switch(p.label){case 0:return n=t.clientName,s=t.commandName,o=t.inputFilterSensitiveLog,a=t.logger,l=t.outputFilterSensitiveLog,[4,e(i)];case 1:return c=p.sent(),a?("function"==typeof a.info&&(u=c.output,h=u.$metadata,d=(0,r.__rest)(u,["$metadata"]),a.info({clientName:n,commandName:s,input:o(i.input),output:l(d),metadata:h})),[2,c]):[2,c]}})})}},n)}}}},16307(e,t,i){"use strict";i.d(t,{Gz:()=>f,ey:()=>s,$z:()=>v});var r=i(65927),n={name:"retryMiddleware",tags:["RETRY"],step:"finalizeRequest",priority:"high",override:!0},s=function(e){return{applyToStack:function(t){t.add(function(e){return function(t,i){return function(n){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var s;return(0,r.__generator)(this,function(o){return(null===(s=null==e?void 0:e.retryStrategy)||void 0===s?void 0:s.mode)&&(i.userAgent=(0,r.__spread)(i.userAgent||[],[["cfg/retry-mode",e.retryStrategy.mode]])),[2,e.retryStrategy.retry(t,n)]})})}}}(e),n)}}},o=i(59027),a=["AuthFailure","InvalidSignatureException","RequestExpired","RequestInTheFuture","RequestTimeTooSkewed","SignatureDoesNotMatch"],l=["BandwidthLimitExceeded","EC2ThrottledException","LimitExceededException","PriorRequestNotComplete","ProvisionedThroughputExceededException","RequestLimitExceeded","RequestThrottled","RequestThrottledException","SlowDown","ThrottledException","Throttling","ThrottlingException","TooManyRequestsException","TransactionInProgressException"],c=["AbortError","TimeoutError","RequestTimeout","RequestTimeoutException"],u=[500,502,503,504],h=function(e){var t,i;return 429===(null===(t=e.$metadata)||void 0===t?void 0:t.httpStatusCode)||l.includes(e.name)||1==(null===(i=e.$retryable)||void 0===i?void 0:i.throttling)},d=i(16699),p=function(e,t){return Math.floor(Math.min(2e4,Math.random()*Math.pow(2,t)*e))},g=function(e){return!!e&&(function(e){return void 0!==e.$retryable}(e)||function(e){return a.includes(e.name)}(e)||h(e)||function(e){var t;return c.includes(e.name)||u.includes((null===(t=e.$metadata)||void 0===t?void 0:t.httpStatusCode)||0)}(e))},f=3,m=function(){function e(e,t){var i,r,n,s,o,a,l;this.maxAttemptsProvider=e,this.mode="standard",this.retryDecider=null!==(i=null==t?void 0:t.retryDecider)&&void 0!==i?i:g,this.delayDecider=null!==(r=null==t?void 0:t.delayDecider)&&void 0!==r?r:p,this.retryQuota=null!==(n=null==t?void 0:t.retryQuota)&&void 0!==n?n:(s=500,o=500,a=function(e){return"TimeoutError"===e.name?10:5},l=function(e){return a(e)<=o},Object.freeze({hasRetryTokens:l,retrieveRetryTokens:function(e){if(!l(e))throw new Error("No retry token available");var t=a(e);return o-=t,t},releaseRetryTokens:function(e){o+=null!=e?e:1,o=Math.min(o,s)}}))}return e.prototype.shouldRetry=function(e,t,i){return t<i&&this.retryDecider(e)&&this.retryQuota.hasRetryTokens(e)},e.prototype.getMaxAttempts=function(){return(0,r.__awaiter)(this,void 0,void 0,function(){var e;return(0,r.__generator)(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,this.maxAttemptsProvider()];case 1:return e=t.sent(),[3,3];case 2:return t.sent(),e=f,[3,3];case 3:return[2,e]}})})},e.prototype.retry=function(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){var i,n,s,a,l,c,u,p;return(0,r.__generator)(this,function(g){switch(g.label){case 0:return n=0,s=0,[4,this.getMaxAttempts()];case 1:a=g.sent(),l=t.request,o.Kd.isInstance(l)&&(l.headers["amz-sdk-invocation-id"]=(0,d.v4)()),c=function(){var c,d,p,g,f;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return r.trys.push([0,2,,5]),o.Kd.isInstance(l)&&(l.headers["amz-sdk-request"]="attempt="+(n+1)+"; max="+a),[4,e(t)];case 1:return c=r.sent(),d=c.response,p=c.output,u.retryQuota.releaseRetryTokens(i),p.$metadata.attempts=n+1,p.$metadata.totalRetryDelay=s,[2,{value:{response:d,output:p}}];case 2:return g=r.sent(),n++,u.shouldRetry(g,n,a)?(i=u.retryQuota.retrieveRetryTokens(g),f=u.delayDecider(h(g)?500:100,n),s+=f,[4,new Promise(function(e){return setTimeout(e,f)})]):[3,4];case 3:return r.sent(),[2,"continue"];case 4:throw g.$metadata||(g.$metadata={}),g.$metadata.attempts=n,g.$metadata.totalRetryDelay=s,g;case 5:return[2]}})},u=this,g.label=2;case 2:return[5,c()];case 3:return"object"==typeof(p=g.sent())?[2,p.value]:[3,2];case 4:return[2]}})})},e}(),v=function(e){var t=C(e.maxAttempts);return(0,r.__assign)((0,r.__assign)({},e),{maxAttempts:t,retryStrategy:e.retryStrategy||new m(t)})},C=function(e){if(void 0===e&&(e=f),"number"==typeof e){var t=Promise.resolve(e);return function(){return t}}return e}},74052(e,t,i){"use strict";i.d(t,{TM:()=>o});var r=i(65927),n={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},s={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function o(e,t,i){return{applyToStack:function(o){o.add(function(e,t){return function(i,n){return function(n){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var s,o;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return[4,i(n)];case 1:return s=r.sent().response,[4,t(s,e)];case 2:return o=r.sent(),[2,{response:s,output:o}]}})})}}}(e,i),n),o.add(function(e,t){return function(i,n){return function(n){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var s;return(0,r.__generator)(this,function(o){switch(o.label){case 0:return[4,t(n.input,e)];case 1:return s=o.sent(),[2,i((0,r.__assign)((0,r.__assign)({},n),{request:s}))]}})})}}}(e,t),s)}}}},88428(e,t,i){"use strict";i.d(t,{DF:()=>H,k9:()=>O});var r=i(65927),n=i(81504),s="X-Amz-Date",o="X-Amz-Signature",a="X-Amz-Security-Token",l="authorization",c=s.toLowerCase(),u=[l,c,"date"],h=o.toLowerCase(),d="x-amz-content-sha256",p=a.toLowerCase(),g={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},f=/^proxy-/,m=/^sec-/,v="AWS4-HMAC-SHA256",C="AWS4-HMAC-SHA256-PAYLOAD",y="aws4_request",w={},S=[];function b(e,t,i){return e+"/"+t+"/"+i+"/"+y}function E(e,t,i){var r=new e(t);return r.update(i),r.digest()}function A(e,t,i){var n,s,o=e.headers,a={};try{for(var l=(0,r.__values)(Object.keys(o).sort()),c=l.next();!c.done;c=l.next()){var u=c.value,h=u.toLowerCase();(h in g||(null==t?void 0:t.has(h))||f.test(h)||m.test(h))&&(!i||i&&!i.has(h))||(a[h]=o[u].trim().replace(/\s+/g," "))}}catch(e){n={error:e}}finally{try{c&&!c.done&&(s=l.return)&&s.call(l)}finally{if(n)throw n.error}}return a}var T=i(2726);function M(e,t){var i=e.headers,s=e.body;return(0,r.__awaiter)(this,void 0,void 0,function(){var e,o,a,l,c,u,h;return(0,r.__generator)(this,function(p){switch(p.label){case 0:try{for(e=(0,r.__values)(Object.keys(i)),o=e.next();!o.done;o=e.next())if((a=o.value).toLowerCase()===d)return[2,i[a]]}catch(e){u={error:e}}finally{try{o&&!o.done&&(h=e.return)&&h.call(e)}finally{if(u)throw u.error}}return null!=s?[3,1]:[2,"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"];case 1:return"string"==typeof s||ArrayBuffer.isView(s)||(g=s,"function"==typeof ArrayBuffer&&g instanceof ArrayBuffer||"[object ArrayBuffer]"===Object.prototype.toString.call(g))?((l=new t).update(s),c=n.n,[4,l.digest()]):[3,3];case 2:return[2,c.apply(void 0,[p.sent()])];case 3:return[2,"UNSIGNED-PAYLOAD"]}var g})})}function R(e){var t=e.headers,i=e.query,n=(0,r.__rest)(e,["headers","query"]);return(0,r.__assign)((0,r.__assign)({},n),{headers:(0,r.__assign)({},t),query:i?_(i):void 0})}function _(e){return Object.keys(e).reduce(function(t,i){var n,s=e[i];return(0,r.__assign)((0,r.__assign)({},t),((n={})[i]=Array.isArray(s)?(0,r.__spread)(s):s,n))},{})}function P(e){var t,i;e="function"==typeof e.clone?e.clone():R(e);try{for(var n=(0,r.__values)(Object.keys(e.headers)),s=n.next();!s.done;s=n.next()){var o=s.value;u.indexOf(o.toLowerCase())>-1&&delete e.headers[o]}}catch(e){t={error:e}}finally{try{s&&!s.done&&(i=n.return)&&i.call(n)}finally{if(t)throw t.error}}return e}var x=function(){function e(e){var t=e.applyChecksum,i=e.credentials,r=e.region,n=e.service,s=e.sha256,o=e.uriEscapePath,a=void 0===o||o;this.service=n,this.sha256=s,this.uriEscapePath=a,this.applyChecksum="boolean"!=typeof t||t,this.regionProvider=L(r),this.credentialProvider=N(i)}return e.prototype.presign=function(e,t){return void 0===t&&(t={}),(0,r.__awaiter)(this,void 0,void 0,function(){var i,n,l,c,u,h,d,p,g,f,m,C,y,w,S,E,T,_,x,L,N,O,F,k;return(0,r.__generator)(this,function(G){switch(G.label){case 0:return i=t.signingDate,n=void 0===i?new Date:i,l=t.expiresIn,c=void 0===l?3600:l,u=t.unsignableHeaders,h=t.unhoistableHeaders,d=t.signableHeaders,p=t.signingRegion,g=t.signingService,[4,this.credentialProvider()];case 1:return f=G.sent(),null==p?[3,2]:(C=p,[3,4]);case 2:return[4,this.regionProvider()];case 3:C=G.sent(),G.label=4;case 4:return m=C,y=D(n),w=y.longDate,S=y.shortDate,c>604800?[2,Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future")]:(E=b(S,m,null!=g?g:this.service),T=function(e,t){var i,n,s;void 0===t&&(t={});var o="function"==typeof e.clone?e.clone():R(e),a=o.headers,l=o.query,c=void 0===l?{}:l;try{for(var u=(0,r.__values)(Object.keys(a)),h=u.next();!h.done;h=u.next()){var d=h.value,p=d.toLowerCase();"x-amz-"!==p.substr(0,6)||(null===(s=t.unhoistableHeaders)||void 0===s?void 0:s.has(p))||(c[d]=a[d],delete a[d])}}catch(e){i={error:e}}finally{try{h&&!h.done&&(n=u.return)&&n.call(u)}finally{if(i)throw i.error}}return(0,r.__assign)((0,r.__assign)({},e),{headers:a,query:c})}(P(e),{unhoistableHeaders:h}),f.sessionToken&&(T.query[a]=f.sessionToken),T.query["X-Amz-Algorithm"]=v,T.query["X-Amz-Credential"]=f.accessKeyId+"/"+E,T.query[s]=w,T.query["X-Amz-Expires"]=c.toString(10),_=A(T,u,d),T.query["X-Amz-SignedHeaders"]=I(_),x=T.query,L=o,N=this.getSignature,O=[w,E,this.getSigningKey(f,m,S,g)],F=this.createCanonicalRequest,k=[T,_],[4,M(e,this.sha256)]);case 5:return[4,N.apply(this,O.concat([F.apply(this,k.concat([G.sent()]))]))];case 6:return x[L]=G.sent(),[2,T]}})})},e.prototype.sign=function(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(i){return"string"==typeof e?[2,this.signString(e,t)]:e.headers&&e.payload?[2,this.signEvent(e,t)]:[2,this.signRequest(e,t)]})})},e.prototype.signEvent=function(e,t){var i=e.headers,s=e.payload,o=t.signingDate,a=void 0===o?new Date:o,l=t.priorSignature,c=t.signingRegion,u=t.signingService;return(0,r.__awaiter)(this,void 0,void 0,function(){var e,t,o,h,d,p,g,f,m,v,y;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return null==c?[3,1]:(t=c,[3,3]);case 1:return[4,this.regionProvider()];case 2:t=r.sent(),r.label=3;case 3:return e=t,o=D(a),h=o.shortDate,d=o.longDate,p=b(h,e,null!=u?u:this.service),[4,M({headers:{},body:s},this.sha256)];case 4:return g=r.sent(),(f=new this.sha256).update(i),v=n.n,[4,f.digest()];case 5:return m=v.apply(void 0,[r.sent()]),y=[C,d,p,l,m,g].join("\n"),[2,this.signString(y,{signingDate:a,signingRegion:e,signingService:u})]}})})},e.prototype.signString=function(e,t){var i=void 0===t?{}:t,s=i.signingDate,o=void 0===s?new Date:s,a=i.signingRegion,l=i.signingService;return(0,r.__awaiter)(this,void 0,void 0,function(){var t,i,s,c,u,h,d,p;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return[4,this.credentialProvider()];case 1:return t=r.sent(),null==a?[3,2]:(s=a,[3,4]);case 2:return[4,this.regionProvider()];case 3:s=r.sent(),r.label=4;case 4:return i=s,c=D(o).shortDate,d=(h=this.sha256).bind,[4,this.getSigningKey(t,i,c,l)];case 5:return(u=new(d.apply(h,[void 0,r.sent()]))).update(e),p=n.n,[4,u.digest()];case 6:return[2,p.apply(void 0,[r.sent()])]}})})},e.prototype.signRequest=function(e,t){var i=void 0===t?{}:t,n=i.signingDate,s=void 0===n?new Date:n,o=i.signableHeaders,a=i.unsignableHeaders,u=i.signingRegion,h=i.signingService;return(0,r.__awaiter)(this,void 0,void 0,function(){var t,i,n,g,f,m,C,y,w,S,E;return(0,r.__generator)(this,function(T){switch(T.label){case 0:return[4,this.credentialProvider()];case 1:return t=T.sent(),null==u?[3,2]:(n=u,[3,4]);case 2:return[4,this.regionProvider()];case 3:n=T.sent(),T.label=4;case 4:return i=n,g=P(e),f=D(s),m=f.longDate,C=f.shortDate,y=b(C,i,null!=h?h:this.service),g.headers[c]=m,t.sessionToken&&(g.headers[p]=t.sessionToken),[4,M(g,this.sha256)];case 5:return w=T.sent(),!function(e,t){var i,n;e=e.toLowerCase();try{for(var s=(0,r.__values)(Object.keys(t)),o=s.next();!o.done;o=s.next())if(e===o.value.toLowerCase())return!0}catch(e){i={error:e}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}finally{if(i)throw i.error}}return!1}(d,g.headers)&&this.applyChecksum&&(g.headers[d]=w),S=A(g,a,o),[4,this.getSignature(m,y,this.getSigningKey(t,i,C,h),this.createCanonicalRequest(g,S,w))];case 6:return E=T.sent(),g.headers[l]=v+" Credential="+t.accessKeyId+"/"+y+", SignedHeaders="+I(S)+", Signature="+E,[2,g]}})})},e.prototype.createCanonicalRequest=function(e,t,i){var n=Object.keys(t).sort();return e.method+"\n"+this.getCanonicalPath(e)+"\n"+function(e){var t,i,n=e.query,s=void 0===n?{}:n,o=[],a={},l=function(e){if(e.toLowerCase()===h)return"continue";o.push(e);var t=s[e];"string"==typeof t?a[e]=(0,T.o)(e)+"="+(0,T.o)(t):Array.isArray(t)&&(a[e]=t.slice(0).sort().reduce(function(t,i){return t.concat([(0,T.o)(e)+"="+(0,T.o)(i)])},[]).join("&"))};try{for(var c=(0,r.__values)(Object.keys(s).sort()),u=c.next();!u.done;u=c.next())l(u.value)}catch(e){t={error:e}}finally{try{u&&!u.done&&(i=c.return)&&i.call(c)}finally{if(t)throw t.error}}return o.map(function(e){return a[e]}).filter(function(e){return e}).join("&")}(e)+"\n"+n.map(function(e){return e+":"+t[e]}).join("\n")+"\n\n"+n.join(";")+"\n"+i},e.prototype.createStringToSign=function(e,t,i){return(0,r.__awaiter)(this,void 0,void 0,function(){var s,o;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return(s=new this.sha256).update(i),[4,s.digest()];case 1:return o=r.sent(),[2,v+"\n"+e+"\n"+t+"\n"+(0,n.n)(o)]}})})},e.prototype.getCanonicalPath=function(e){var t=e.path;return this.uriEscapePath?"/"+encodeURIComponent(t.replace(/^\//,"")).replace(/%2F/g,"/"):t},e.prototype.getSignature=function(e,t,i,s){return(0,r.__awaiter)(this,void 0,void 0,function(){var o,a,l,c,u;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return[4,this.createStringToSign(e,t,s)];case 1:return o=r.sent(),c=(l=this.sha256).bind,[4,i];case 2:return(a=new(c.apply(l,[void 0,r.sent()]))).update(o),u=n.n,[4,a.digest()];case 3:return[2,u.apply(void 0,[r.sent()])]}})})},e.prototype.getSigningKey=function(e,t,i,s){return function(e,t,i,s,o){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var a,l,c,u,h,d,p,g,f;return(0,r.__generator)(this,function(m){switch(m.label){case 0:return[4,E(e,t.secretAccessKey,t.accessKeyId)];case 1:if(a=m.sent(),(l=i+":"+s+":"+o+":"+(0,n.n)(a)+":"+t.sessionToken)in w)return[2,w[l]];for(S.push(l);S.length>50;)delete w[S.shift()];c="AWS4"+t.secretAccessKey,m.label=2;case 2:m.trys.push([2,7,8,9]),u=(0,r.__values)([i,s,o,y]),h=u.next(),m.label=3;case 3:return h.done?[3,6]:(d=h.value,[4,E(e,c,d)]);case 4:c=m.sent(),m.label=5;case 5:return h=u.next(),[3,3];case 6:return[3,9];case 7:return p=m.sent(),g={error:p},[3,9];case 8:try{h&&!h.done&&(f=u.return)&&f.call(u)}finally{if(g)throw g.error}return[7];case 9:return[2,w[l]=c]}})})}(this.sha256,e,i,t,s||this.service)},e}(),D=function(e){var t,i=(t=e,function(e){return"number"==typeof e?new Date(1e3*e):"string"==typeof e?Number(e)?new Date(1e3*Number(e)):new Date(e):e}(t).toISOString().replace(/\.\d{3}Z$/,"Z")).replace(/[\-:]/g,"");return{longDate:i,shortDate:i.substr(0,8)}},I=function(e){return Object.keys(e).sort().join(";")},L=function(e){if("string"==typeof e){var t=Promise.resolve(e);return function(){return t}}return e},N=function(e){if("object"==typeof e){var t=Promise.resolve(e);return function(){return t}}return e};function O(e){var t,i=this,n=F(e.credentials||e.credentialDefaultProvider(e)),s=e.signingEscapePath,o=void 0===s||s,a=e.systemClockOffset,l=void 0===a?e.systemClockOffset||0:a,c=e.sha256;return t=e.signer?F(e.signer):function(){return F(e.region)().then(function(t){return(0,r.__awaiter)(i,void 0,void 0,function(){return(0,r.__generator)(this,function(i){switch(i.label){case 0:return[4,e.regionInfoProvider(t)];case 1:return[2,[i.sent()||{},t]]}})})}).then(function(t){var i=(0,r.__read)(t,2),s=i[0],a=i[1],l=s.signingRegion,u=s.signingService;return e.signingRegion=e.signingRegion||l||a,e.signingName=e.signingName||u||e.serviceId,new x({credentials:n,region:e.signingRegion,service:e.signingName,sha256:c,uriEscapePath:o})})},(0,r.__assign)((0,r.__assign)({},e),{systemClockOffset:l,signingEscapePath:o,credentials:n,signer:t})}function F(e){if("object"==typeof e){var t=Promise.resolve(e);return function(){return t}}return e}var k=i(59027);function G(e){return function(t,i){return function(n){return(0,r.__awaiter)(this,void 0,void 0,function(){var s,o,a,l,c,u,h,d,p;return(0,r.__generator)(this,function(g){switch(g.label){case 0:return k.Kd.isInstance(n.request)?"function"!=typeof e.signer?[3,2]:[4,e.signer()]:[2,t(n)];case 1:return o=g.sent(),[3,3];case 2:o=e.signer,g.label=3;case 3:return s=o,l=t,c=[(0,r.__assign)({},n)],p={},[4,s.sign(n.request,{signingDate:new Date(Date.now()+e.systemClockOffset),signingRegion:i.signing_region,signingService:i.signing_service})];case 4:return[4,l.apply(void 0,[r.__assign.apply(void 0,c.concat([(p.request=g.sent(),p)]))])];case 5:return a=g.sent(),u=a.response.headers,(h=u&&(u.date||u.Date))&&(f=d=Date.parse(h),m=e.systemClockOffset,Math.abs(function(e){return new Date(Date.now()+e)}(m).getTime()-f)>=3e5&&(e.systemClockOffset=d-Date.now())),[2,a]}var f,m})})}}}var V={name:"awsAuthMiddleware",tags:["SIGNATURE","AWSAUTH"],relation:"after",toMiddleware:"retryMiddleware",override:!0},H=function(e){return{applyToStack:function(t){t.addRelativeTo(G(e),V)}}}},44625(e,t,i){"use strict";i.d(t,{sM:()=>u,Dc:()=>n});var r=i(65927);function n(e){return(0,r.__assign)((0,r.__assign)({},e),{customUserAgent:"string"==typeof e.customUserAgent?[[e.customUserAgent]]:e.customUserAgent})}var s=i(59027),o="user-agent",a=/[^\!\#\$\%\&\'\*\+\-\.\^\_\`\|\~\d\w]/g,l=function(e){var t=(0,r.__read)(e,2),i=t[0],n=t[1],s=i.indexOf("/"),o=i.substring(0,s),l=i.substring(s+1);return"api"===o&&(l=l.toLowerCase()),[o,l,n].filter(function(e){return e&&e.length>0}).map(function(e){return null==e?void 0:e.replace(a,"_")}).join("/")},c={name:"getUserAgentMiddleware",step:"build",priority:"low",tags:["SET_USER_AGENT","USER_AGENT"],override:!0},u=function(e){return{applyToStack:function(t){var i;t.add((i=e,function(e,t){return function(n){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var a,c,u,h,d,p,g,f;return(0,r.__generator)(this,function(m){switch(m.label){case 0:return a=n.request,s.Kd.isInstance(a)?(c=a.headers,u=(null===(g=null==t?void 0:t.userAgent)||void 0===g?void 0:g.map(l))||[],[4,i.defaultUserAgentProvider()]):[2,e(n)];case 1:return h=m.sent().map(l),d=(null===(f=null==i?void 0:i.customUserAgent)||void 0===f?void 0:f.map(l))||[],c["x-amz-user-agent"]=(0,r.__spread)(h,u,d).join(" "),p=(0,r.__spread)(h.filter(function(e){return e.startsWith("aws-sdk-")}),d).join(" "),"browser"!==i.runtime&&p&&(c[o]=c[o]?c[o]+" "+p:p),[2,e((0,r.__assign)((0,r.__assign)({},n),{request:a}))]}})})}}),c)}}}},59027(e,t,i){"use strict";i.d(t,{Kd:()=>s,cS:()=>r});var r=function(){function e(e){this.statusCode=e.statusCode,this.headers=e.headers||{},this.body=e.body}return e.isInstance=function(e){if(!e)return!1;var t=e;return"number"==typeof t.statusCode&&"object"==typeof t.headers},e}(),n=i(65927),s=function(){function e(e){this.method=e.method||"GET",this.hostname=e.hostname||"localhost",this.port=e.port,this.query=e.query||{},this.headers=e.headers||{},this.body=e.body,this.protocol=e.protocol?":"!==e.protocol.substr(-1)?e.protocol+":":e.protocol:"https:",this.path=e.path?"/"!==e.path.charAt(0)?"/"+e.path:e.path:"/"}return e.isInstance=function(e){if(!e)return!1;var t=e;return"method"in t&&"protocol"in t&&"hostname"in t&&"path"in t&&"object"==typeof t.query&&"object"==typeof t.headers},e.prototype.clone=function(){var t,i=new e((0,n.__assign)((0,n.__assign)({},this),{headers:(0,n.__assign)({},this.headers)}));return i.query&&(i.query=(t=i.query,Object.keys(t).reduce(function(e,i){var r,s=t[i];return(0,n.__assign)((0,n.__assign)({},e),((r={})[i]=Array.isArray(s)?(0,n.__spread)(s):s,r))},{}))),i},e}()},11538(e,t,i){"use strict";i.d(t,{Kj:()=>a,uB:()=>l,$6:()=>c});var r=i(65927),n=function(){var e=[],t=[],i=new Set,a=function(i){return e.forEach(function(e){i.add(e.middleware,(0,r.__assign)({},e))}),t.forEach(function(e){i.addRelativeTo(e.middleware,(0,r.__assign)({},e))}),i},l=function(e){var t=[];return e.before.forEach(function(e){0===e.before.length&&0===e.after.length?t.push(e):t.push.apply(t,(0,r.__spread)(l(e)))}),t.push(e),e.after.reverse().forEach(function(e){0===e.before.length&&0===e.after.length?t.push(e):t.push.apply(t,(0,r.__spread)(l(e)))}),t},c={add:function(t,n){void 0===n&&(n={});var s=n.name,o=n.override,a=(0,r.__assign)({step:"initialize",priority:"normal",middleware:t},n);if(s){if(i.has(s)){if(!o)throw new Error("Duplicate middleware name '"+s+"'");var l=e.findIndex(function(e){return e.name===s}),c=e[l];if(c.step!==a.step||c.priority!==a.priority)throw new Error('"'+s+'" middleware with '+c.priority+" priority in "+c.step+" step cannot be overridden by same-name middleware with "+a.priority+" priority in "+a.step+" step.");e.splice(l,1)}i.add(s)}e.push(a)},addRelativeTo:function(e,n){var s=n.name,o=n.override,a=(0,r.__assign)({middleware:e},n);if(s){if(i.has(s)){if(!o)throw new Error("Duplicate middleware name '"+s+"'");var l=t.findIndex(function(e){return e.name===s}),c=t[l];if(c.toMiddleware!==a.toMiddleware||c.relation!==a.relation)throw new Error('"'+s+'" middleware '+c.relation+' "'+c.toMiddleware+'" middleware cannot be overridden by same-name middleware '+a.relation+' "'+a.toMiddleware+'" middleware.');t.splice(l,1)}i.add(s)}t.push(a)},clone:function(){return a(n())},use:function(e){e.applyToStack(c)},remove:function(r){return"string"==typeof r?function(r){var n=!1,s=function(e){return!e.name||e.name!==r||(n=!0,i.delete(r),!1)};return e=e.filter(s),t=t.filter(s),n}(r):function(r){var n=!1,s=function(e){return e.middleware!==r||(n=!0,e.name&&i.delete(e.name),!1)};return e=e.filter(s),t=t.filter(s),n}(r)},removeByTag:function(r){var n=!1,s=function(e){var t=e.tags,s=e.name;return!t||!t.includes(r)||(s&&i.delete(s),n=!0,!1)};return e=e.filter(s),t=t.filter(s),n},concat:function(e){var t=a(n());return t.use(e),t},applyToStack:a,resolve:function(i,n){var a,c;try{for(var u=(0,r.__values)(function(){var i,n=[],a=[],c={};return e.forEach(function(e){var t=(0,r.__assign)((0,r.__assign)({},e),{before:[],after:[]});t.name&&(c[t.name]=t),n.push(t)}),t.forEach(function(e){var t=(0,r.__assign)((0,r.__assign)({},e),{before:[],after:[]});t.name&&(c[t.name]=t),a.push(t)}),a.forEach(function(e){if(e.toMiddleware){var t=c[e.toMiddleware];if(void 0===t)throw new Error(e.toMiddleware+" is not found when adding "+(e.name||"anonymous")+" middleware "+e.relation+" "+e.toMiddleware);"after"===e.relation&&t.after.push(e),"before"===e.relation&&t.before.push(e)}}),(i=n,i.sort(function(e,t){return s[t.step]-s[e.step]||o[t.priority||"normal"]-o[e.priority||"normal"]})).map(l).reduce(function(e,t){return e.push.apply(e,(0,r.__spread)(t)),e},[]).map(function(e){return e.middleware})}().reverse()),h=u.next();!h.done;h=u.next())i=(0,h.value)(i,n)}catch(e){a={error:e}}finally{try{h&&!h.done&&(c=u.return)&&c.call(u)}finally{if(a)throw a.error}}return i}};return c},s={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},o={high:3,normal:2,low:1},a=function(){function e(e){this.middlewareStack=n(),this.config=e}return e.prototype.send=function(e,t,i){var r="function"!=typeof t?t:void 0,n="function"==typeof t?t:i,s=e.resolveMiddleware(this.middlewareStack,this.config,r);if(!n)return s(e).then(function(e){return e.output});s(e).then(function(e){return n(null,e.output)},function(e){return n(e)}).catch(function(){})},e.prototype.destroy=function(){this.config.requestHandler.destroy&&this.config.requestHandler.destroy()},e}(),l=function(){this.middlewareStack=n()};function c(e){return encodeURIComponent(e).replace(/[!'()*]/g,function(e){return"%"+e.charCodeAt(0).toString(16)})}var u=function(){var e=Object.getPrototypeOf(this).constructor,t=new(Function.bind.apply(String,(0,r.__spread)([null],arguments)));return Object.setPrototypeOf(t,e.prototype),t};u.prototype=Object.create(String.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),Object.setPrototypeOf(u,String),function(e){function t(){return null!==e&&e.apply(this,arguments)||this}(0,r.__extends)(t,e),t.prototype.deserializeJSON=function(){return JSON.parse(e.prototype.toString.call(this))},t.prototype.toJSON=function(){return e.prototype.toString.call(this)},t.fromObject=function(e){return e instanceof t?e:new t(e instanceof String||"string"==typeof e?e:JSON.stringify(e))}}(u)},2049(e,t,i){"use strict";i.d(t,{D:()=>n});var r=i(65927),n=function(e){var t,i=new URL(e),n=i.hostname,s=i.pathname,o=i.port,a=i.protocol,l=i.search;return l&&(t=function(e){var t,i,n={};if(e=e.replace(/^\?/,""))try{for(var s=(0,r.__values)(e.split("&")),o=s.next();!o.done;o=s.next()){var a=o.value,l=(0,r.__read)(a.split("="),2),c=l[0],u=l[1],h=void 0===u?null:u;c=decodeURIComponent(c),h&&(h=decodeURIComponent(h)),c in n?Array.isArray(n[c])?n[c].push(h):n[c]=[n[c],h]:n[c]=h}}catch(e){t={error:e}}finally{try{o&&!o.done&&(i=s.return)&&i.call(s)}finally{if(t)throw t.error}}return n}(l)),{hostname:n,port:o?parseInt(o):void 0,protocol:a,path:s,query:t}}},68380(e,t,i){"use strict";i.d(t,{E:()=>u,n:()=>h});for(var r={},n=new Array(64),s=0,o="A".charCodeAt(0),a="Z".charCodeAt(0);s+o<=a;s++){var l=String.fromCharCode(s+o);r[l]=s,n[s]=l}for(s=0,o="a".charCodeAt(0),a="z".charCodeAt(0);s+o<=a;s++){l=String.fromCharCode(s+o);var c=s+26;r[l]=c,n[c]=l}for(s=0;s<10;s++)r[s.toString(10)]=s+52,l=s.toString(10),c=s+52,r[l]=c,n[c]=l;function u(e){var t=e.length/4*3;"=="===e.substr(-2)?t-=2:"="===e.substr(-1)&&t--;for(var i=new ArrayBuffer(t),n=new DataView(i),s=0;s<e.length;s+=4){for(var o=0,a=0,l=s,c=s+3;l<=c;l++)"="!==e[l]?(o|=r[e[l]]<<6*(c-l),a+=6):o>>=6;var u=s/4*3;o>>=a%8;for(var h=Math.floor(a/8),d=0;d<h;d++){var p=8*(h-d-1);n.setUint8(u+d,(o&255<<p)>>p)}}return new Uint8Array(i)}function h(e){for(var t="",i=0;i<e.length;i+=3){for(var r=0,s=0,o=i,a=Math.min(i+3,e.length);o<a;o++)r|=e[o]<<8*(a-o-1),s+=8;var l=Math.ceil(s/6);r<<=6*l-s;for(var c=1;c<=l;c++){var u=6*(l-c);t+=n[(r&63<<u)>>u]}t+="==".slice(0,4-l)}return t}r["+"]=62,n[62]="+",r["/"]=63,n[63]="/"},93972(e,t,i){"use strict";function r(e){if("string"==typeof e){for(var t=e.length,i=t-1;i>=0;i--){var r=e.charCodeAt(i);r>127&&r<=2047?t++:r>2047&&r<=65535&&(t+=2)}return t}return"number"==typeof e.byteLength?e.byteLength:"number"==typeof e.size?e.size:void 0}i.d(t,{n:()=>r})},93065(e,t,i){"use strict";i.d(t,{n:()=>r.n});var r=i(67520)},81504(e,t,i){"use strict";i.d(t,{n:()=>a});for(var r={},n={},s=0;s<256;s++){var o=s.toString(16).toLowerCase();1===o.length&&(o="0"+o),r[s]=o,n[o]=s}function a(e){for(var t="",i=0;i<e.byteLength;i++)t+=r[e[i]];return t}},1632(e,t,i){"use strict";i.r(t),i.d(t,{locateWindow:()=>n});const r={};function n(){return"undefined"!=typeof window?window:"undefined"!=typeof self?self:r}},2726(e,t,i){"use strict";i.d(t,{o:()=>r});var r=function(e){return encodeURIComponent(e).replace(/[!'()*]/g,n)},n=function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}},39448(e,t,i){"use strict";i.d(t,{m:()=>o});var r=i(65927),n=i(36621),s=i.n(n),o=function(e){var t=e.serviceId,i=e.clientVersion;return function(){return(0,r.__awaiter)(void 0,void 0,void 0,function(){var e,n,o,a,l,c,u,h,d;return(0,r.__generator)(this,function(r){return e=(null===(o=null===window||void 0===window?void 0:window.navigator)||void 0===o?void 0:o.userAgent)?s().parse(window.navigator.userAgent):void 0,n=[["aws-sdk-js",i],["os/"+((null===(a=null==e?void 0:e.os)||void 0===a?void 0:a.name)||"other"),null===(l=null==e?void 0:e.os)||void 0===l?void 0:l.version],["lang/js"],["md/browser",(null!==(u=null===(c=null==e?void 0:e.browser)||void 0===c?void 0:c.name)&&void 0!==u?u:"unknown")+"_"+(null!==(d=null===(h=null==e?void 0:e.browser)||void 0===h?void 0:h.version)&&void 0!==d?d:"unknown")]],t&&n.push(["api/"+t,i]),[2,n]})})}}},94518(e,t,i){"use strict";i.r(t),i.d(t,{fromUtf8:()=>r,toUtf8:()=>n});var r=function(e){return"function"==typeof TextEncoder?function(e){return(new TextEncoder).encode(e)}(e):function(e){for(var t=[],i=0,r=e.length;i<r;i++){var n=e.charCodeAt(i);if(n<128)t.push(n);else if(n<2048)t.push(n>>6|192,63&n|128);else if(i+1<e.length&&55296==(64512&n)&&56320==(64512&e.charCodeAt(i+1))){var s=65536+((1023&n)<<10)+(1023&e.charCodeAt(++i));t.push(s>>18|240,s>>12&63|128,s>>6&63|128,63&s|128)}else t.push(n>>12|224,n>>6&63|128,63&n|128)}return Uint8Array.from(t)}(e)},n=function(e){return"function"==typeof TextDecoder?function(e){return new TextDecoder("utf-8").decode(e)}(e):function(e){for(var t="",i=0,r=e.length;i<r;i++){var n=e[i];if(n<128)t+=String.fromCharCode(n);else if(192<=n&&n<224){var s=e[++i];t+=String.fromCharCode((31&n)<<6|63&s)}else if(240<=n&&n<365){var o="%"+[n,e[++i],e[++i],e[++i]].map(function(e){return e.toString(16)}).join("%");t+=decodeURIComponent(o)}else t+=String.fromCharCode((15&n)<<12|(63&e[++i])<<6|63&e[++i])}return t}(e)}},91486(e,t,i){"use strict";i.r(t),i.d(t,{fromUtf8:()=>r,toUtf8:()=>n});const r=e=>"function"==typeof TextEncoder?function(e){return(new TextEncoder).encode(e)}(e):(e=>{const t=[];for(let i=0,r=e.length;i<r;i++){const r=e.charCodeAt(i);if(r<128)t.push(r);else if(r<2048)t.push(r>>6|192,63&r|128);else if(i+1<e.length&&55296==(64512&r)&&56320==(64512&e.charCodeAt(i+1))){const n=65536+((1023&r)<<10)+(1023&e.charCodeAt(++i));t.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}else t.push(r>>12|224,r>>6&63|128,63&r|128)}return Uint8Array.from(t)})(e),n=e=>"function"==typeof TextDecoder?function(e){return new TextDecoder("utf-8").decode(e)}(e):(e=>{let t="";for(let i=0,r=e.length;i<r;i++){const r=e[i];if(r<128)t+=String.fromCharCode(r);else if(192<=r&&r<224){const n=e[++i];t+=String.fromCharCode((31&r)<<6|63&n)}else if(240<=r&&r<365){const n="%"+[r,e[++i],e[++i],e[++i]].map(e=>e.toString(16)).join("%");t+=decodeURIComponent(n)}else t+=String.fromCharCode((15&r)<<12|(63&e[++i])<<6|63&e[++i])}return t})(e)},31643(e,t,i){"use strict";i.r(t),i.d(t,{fromUtf8:()=>r,toUtf8:()=>n});var r=function(e){return"function"==typeof TextEncoder?function(e){return(new TextEncoder).encode(e)}(e):function(e){for(var t=[],i=0,r=e.length;i<r;i++){var n=e.charCodeAt(i);if(n<128)t.push(n);else if(n<2048)t.push(n>>6|192,63&n|128);else if(i+1<e.length&&55296==(64512&n)&&56320==(64512&e.charCodeAt(i+1))){var s=65536+((1023&n)<<10)+(1023&e.charCodeAt(++i));t.push(s>>18|240,s>>12&63|128,s>>6&63|128,63&s|128)}else t.push(n>>12|224,n>>6&63|128,63&n|128)}return Uint8Array.from(t)}(e)},n=function(e){return"function"==typeof TextDecoder?function(e){return new TextDecoder("utf-8").decode(e)}(e):function(e){for(var t="",i=0,r=e.length;i<r;i++){var n=e[i];if(n<128)t+=String.fromCharCode(n);else if(192<=n&&n<224){var s=e[++i];t+=String.fromCharCode((31&n)<<6|63&s)}else if(240<=n&&n<365){var o="%"+[n,e[++i],e[++i],e[++i]].map(function(e){return e.toString(16)}).join("%");t+=decodeURIComponent(o)}else t+=String.fromCharCode((15&n)<<12|(63&e[++i])<<6|63&e[++i])}return t}(e)}},70381(e,t,i){e.exports={graphlib:i(55166),layout:i(79623),debug:i(10698),util:{time:i(82469).time,notime:i(82469).notime},version:i(69741)}},85933(e,t,i){"use strict";let r=i(72046),n=i(82469).uniqueId;e.exports={run:function(e){("greedy"===e.graph().acyclicer?r(e,function(e){return t=>e.edge(t).weight}(e)):function(e){let t=[],i={},r={};return e.nodes().forEach(function n(s){Object.hasOwn(r,s)||(r[s]=!0,i[s]=!0,e.outEdges(s).forEach(e=>{Object.hasOwn(i,e.w)?t.push(e):n(e.w)}),delete i[s])}),t}(e)).forEach(t=>{let i=e.edge(t);e.removeEdge(t),i.forwardName=t.name,i.reversed=!0,e.setEdge(t.w,t.v,i,n("rev"))})},undo:function(e){e.edges().forEach(t=>{let i=e.edge(t);if(i.reversed){e.removeEdge(t);let r=i.forwardName;delete i.reversed,delete i.forwardName,e.setEdge(t.w,t.v,i,r)}})}}},8328(e,t,i){let r=i(82469);function n(e,t,i,n,s,o){let a={width:0,height:0,rank:o,borderType:t},l=s[t][o-1],c=r.addDummyNode(e,"border",a,i);s[t][o]=c,e.setParent(c,n),l&&e.setEdge(l,c,{weight:1})}e.exports=function(e){e.children().forEach(function t(i){let r=e.children(i),s=e.node(i);if(r.length&&r.forEach(t),Object.hasOwn(s,"minRank")){s.borderLeft=[],s.borderRight=[];for(let t=s.minRank,r=s.maxRank+1;t<r;++t)n(e,"borderLeft","_bl",i,s,t),n(e,"borderRight","_br",i,s,t)}})}},29481(e){"use strict";function t(e){e.nodes().forEach(t=>i(e.node(t))),e.edges().forEach(t=>i(e.edge(t)))}function i(e){let t=e.width;e.width=e.height,e.height=t}function r(e){e.y=-e.y}function n(e){let t=e.x;e.x=e.y,e.y=t}e.exports={adjust:function(e){let i=e.graph().rankdir.toLowerCase();"lr"!==i&&"rl"!==i||t(e)},undo:function(e){let i=e.graph().rankdir.toLowerCase();"bt"!==i&&"rl"!==i||function(e){e.nodes().forEach(t=>r(e.node(t))),e.edges().forEach(t=>{let i=e.edge(t);i.points.forEach(r),Object.hasOwn(i,"y")&&r(i)})}(e),"lr"!==i&&"rl"!==i||(function(e){e.nodes().forEach(t=>n(e.node(t))),e.edges().forEach(t=>{let i=e.edge(t);i.points.forEach(n),Object.hasOwn(i,"x")&&n(i)})}(e),t(e))}}},78976(e){function t(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function i(e,t){if("_next"!==e&&"_prev"!==e)return t}e.exports=class{constructor(){let e={};e._next=e._prev=e,this._sentinel=e}dequeue(){let e=this._sentinel,i=e._prev;if(i!==e)return t(i),i}enqueue(e){let i=this._sentinel;e._prev&&e._next&&t(e),e._next=i._next,i._next._prev=e,i._next=e,e._prev=i}toString(){let e=[],t=this._sentinel,r=t._prev;for(;r!==t;)e.push(JSON.stringify(r,i)),r=r._prev;return"["+e.join(", ")+"]"}}},10698(e,t,i){let r=i(82469),n=i(55166).Graph;e.exports={debugOrdering:function(e){let t=r.buildLayerMatrix(e),i=new n({compound:!0,multigraph:!0}).setGraph({});return e.nodes().forEach(t=>{i.setNode(t,{label:t}),i.setParent(t,"layer"+e.node(t).rank)}),e.edges().forEach(e=>i.setEdge(e.v,e.w,{},e.name)),t.forEach((e,t)=>{let r="layer"+t;i.setNode(r,{rank:"same"}),e.reduce((e,t)=>(i.setEdge(e,t,{style:"invis"}),t))}),i}}},72046(e,t,i){let r=i(55166).Graph,n=i(78976);e.exports=function(e,t){if(e.nodeCount()<=1)return[];let i=function(e,t){let i=new r,s=0,o=0;e.nodes().forEach(e=>{i.setNode(e,{v:e,in:0,out:0})}),e.edges().forEach(e=>{let r=i.edge(e.v,e.w)||0,n=t(e),a=r+n;i.setEdge(e.v,e.w,a),o=Math.max(o,i.node(e.v).out+=n),s=Math.max(s,i.node(e.w).in+=n)});let l=function(e){const t=[];for(let i=0;i<e;i++)t.push(i);return t}(o+s+3).map(()=>new n),c=s+1;return i.nodes().forEach(e=>{a(l,c,i.node(e))}),{graph:i,buckets:l,zeroIdx:c}}(e,t||s);return function(e,t,i){let r,n=[],s=t[t.length-1],a=t[0];for(;e.nodeCount();){for(;r=a.dequeue();)o(e,t,i,r);for(;r=s.dequeue();)o(e,t,i,r);if(e.nodeCount())for(let s=t.length-2;s>0;--s)if(r=t[s].dequeue(),r){n=n.concat(o(e,t,i,r,!0));break}}return n}(i.graph,i.buckets,i.zeroIdx).flatMap(t=>e.outEdges(t.v,t.w))};let s=()=>1;function o(e,t,i,r,n){let s=n?[]:void 0;return e.inEdges(r.v).forEach(r=>{let o=e.edge(r),l=e.node(r.v);n&&s.push({v:r.v,w:r.w}),l.out-=o,a(t,i,l)}),e.outEdges(r.v).forEach(r=>{let n=e.edge(r),s=r.w,o=e.node(s);o.in-=n,a(t,i,o)}),e.removeNode(r.v),s}function a(e,t,i){i.out?i.in?e[i.out-i.in+t].enqueue(i):e[e.length-1].enqueue(i):e[0].enqueue(i)}},79623(e,t,i){"use strict";let r=i(85933),n=i(77798),s=i(83816),o=i(82469).normalizeRanks,a=i(77999),l=i(82469).removeEmptyRanks,c=i(32254),u=i(8328),h=i(29481),d=i(5354),p=i(7489),g=i(82469),f=i(55166).Graph;e.exports=function(e,t){let i=t&&t.debugTiming?g.time:g.notime;i("layout",()=>{let M=i("  buildLayoutGraph",()=>function(e){let t=new f({multigraph:!0,compound:!0}),i=T(e.graph());return t.setGraph(Object.assign({},v,A(i,m),g.pick(i,C))),e.nodes().forEach(i=>{const r=A(T(e.node(i)),y);Object.keys(w).forEach(e=>{void 0===r[e]&&(r[e]=w[e])}),t.setNode(i,r),t.setParent(i,e.parent(i))}),e.edges().forEach(i=>{let r=T(e.edge(i));t.setEdge(i,Object.assign({},b,A(r,S),g.pick(r,E)))}),t}(e));i("  runLayout",()=>function(e,t,i){t("    makeSpaceForEdgeLabels",()=>function(e){let t=e.graph();t.ranksep/=2,e.edges().forEach(i=>{let r=e.edge(i);r.minlen*=2,"c"!==r.labelpos.toLowerCase()&&("TB"===t.rankdir||"BT"===t.rankdir?r.width+=r.labeloffset:r.height+=r.labeloffset)})}(e)),t("    removeSelfEdges",()=>function(e){e.edges().forEach(t=>{if(t.v===t.w){var i=e.node(t.v);i.selfEdges||(i.selfEdges=[]),i.selfEdges.push({e:t,label:e.edge(t)}),e.removeEdge(t)}})}(e)),t("    acyclic",()=>r.run(e)),t("    nestingGraph.run",()=>c.run(e)),t("    rank",()=>s(g.asNonCompoundGraph(e))),t("    injectEdgeLabelProxies",()=>function(e){e.edges().forEach(t=>{let i=e.edge(t);if(i.width&&i.height){let i=e.node(t.v),r={rank:(e.node(t.w).rank-i.rank)/2+i.rank,e:t};g.addDummyNode(e,"edge-proxy",r,"_ep")}})}(e)),t("    removeEmptyRanks",()=>l(e)),t("    nestingGraph.cleanup",()=>c.cleanup(e)),t("    normalizeRanks",()=>o(e)),t("    assignRankMinMax",()=>function(e){let t=0;e.nodes().forEach(i=>{let r=e.node(i);r.borderTop&&(r.minRank=e.node(r.borderTop).rank,r.maxRank=e.node(r.borderBottom).rank,t=Math.max(t,r.maxRank))}),e.graph().maxRank=t}(e)),t("    removeEdgeLabelProxies",()=>function(e){e.nodes().forEach(t=>{let i=e.node(t);"edge-proxy"===i.dummy&&(e.edge(i.e).labelRank=i.rank,e.removeNode(t))})}(e)),t("    normalize.run",()=>n.run(e)),t("    parentDummyChains",()=>a(e)),t("    addBorderSegments",()=>u(e)),t("    order",()=>d(e,i)),t("    insertSelfEdges",()=>function(e){g.buildLayerMatrix(e).forEach(t=>{var i=0;t.forEach((t,r)=>{var n=e.node(t);n.order=r+i,(n.selfEdges||[]).forEach(t=>{g.addDummyNode(e,"selfedge",{width:t.label.width,height:t.label.height,rank:n.rank,order:r+ ++i,e:t.e,label:t.label},"_se")}),delete n.selfEdges})})}(e)),t("    adjustCoordinateSystem",()=>h.adjust(e)),t("    position",()=>p(e)),t("    positionSelfEdges",()=>function(e){e.nodes().forEach(t=>{var i=e.node(t);if("selfedge"===i.dummy){var r=e.node(i.e.v),n=r.x+r.width/2,s=r.y,o=i.x-n,a=r.height/2;e.setEdge(i.e,i.label),e.removeNode(t),i.label.points=[{x:n+2*o/3,y:s-a},{x:n+5*o/6,y:s-a},{x:n+o,y:s},{x:n+5*o/6,y:s+a},{x:n+2*o/3,y:s+a}],i.label.x=i.x,i.label.y=i.y}})}(e)),t("    removeBorderNodes",()=>function(e){e.nodes().forEach(t=>{if(e.children(t).length){let i=e.node(t),r=e.node(i.borderTop),n=e.node(i.borderBottom),s=e.node(i.borderLeft[i.borderLeft.length-1]),o=e.node(i.borderRight[i.borderRight.length-1]);i.width=Math.abs(o.x-s.x),i.height=Math.abs(n.y-r.y),i.x=s.x+i.width/2,i.y=r.y+i.height/2}}),e.nodes().forEach(t=>{"border"===e.node(t).dummy&&e.removeNode(t)})}(e)),t("    normalize.undo",()=>n.undo(e)),t("    fixupEdgeLabelCoords",()=>function(e){e.edges().forEach(t=>{let i=e.edge(t);if(Object.hasOwn(i,"x"))switch("l"!==i.labelpos&&"r"!==i.labelpos||(i.width-=i.labeloffset),i.labelpos){case"l":i.x-=i.width/2+i.labeloffset;break;case"r":i.x+=i.width/2+i.labeloffset}})}(e)),t("    undoCoordinateSystem",()=>h.undo(e)),t("    translateGraph",()=>function(e){let t=Number.POSITIVE_INFINITY,i=0,r=Number.POSITIVE_INFINITY,n=0,s=e.graph(),o=s.marginx||0,a=s.marginy||0;function l(e){let s=e.x,o=e.y,a=e.width,l=e.height;t=Math.min(t,s-a/2),i=Math.max(i,s+a/2),r=Math.min(r,o-l/2),n=Math.max(n,o+l/2)}e.nodes().forEach(t=>l(e.node(t))),e.edges().forEach(t=>{let i=e.edge(t);Object.hasOwn(i,"x")&&l(i)}),t-=o,r-=a,e.nodes().forEach(i=>{let n=e.node(i);n.x-=t,n.y-=r}),e.edges().forEach(i=>{let n=e.edge(i);n.points.forEach(e=>{e.x-=t,e.y-=r}),Object.hasOwn(n,"x")&&(n.x-=t),Object.hasOwn(n,"y")&&(n.y-=r)}),s.width=i-t+o,s.height=n-r+a}(e)),t("    assignNodeIntersects",()=>function(e){e.edges().forEach(t=>{let i,r,n=e.edge(t),s=e.node(t.v),o=e.node(t.w);n.points?(i=n.points[0],r=n.points[n.points.length-1]):(n.points=[],i=o,r=s),n.points.unshift(g.intersectRect(s,i)),n.points.push(g.intersectRect(o,r))})}(e)),t("    reversePoints",()=>function(e){e.edges().forEach(t=>{let i=e.edge(t);i.reversed&&i.points.reverse()})}(e)),t("    acyclic.undo",()=>r.undo(e))}(M,i,t)),i("  updateInputGraph",()=>function(e,t){e.nodes().forEach(i=>{let r=e.node(i),n=t.node(i);r&&(r.x=n.x,r.y=n.y,r.rank=n.rank,t.children(i).length&&(r.width=n.width,r.height=n.height))}),e.edges().forEach(i=>{let r=e.edge(i),n=t.edge(i);r.points=n.points,Object.hasOwn(n,"x")&&(r.x=n.x,r.y=n.y)}),e.graph().width=t.graph().width,e.graph().height=t.graph().height}(e,M))})};let m=["nodesep","edgesep","ranksep","marginx","marginy"],v={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},C=["acyclicer","ranker","rankdir","align"],y=["width","height","rank"],w={width:0,height:0},S=["minlen","weight","width","height","labeloffset"],b={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},E=["labelpos"];function A(e,t){return g.mapValues(g.pick(e,t),Number)}function T(e){var t={};return e&&Object.entries(e).forEach(([e,i])=>{"string"==typeof e&&(e=e.toLowerCase()),t[e]=i}),t}},32254(e,t,i){let r=i(82469);function n(e,t,i,s,o,a,l){let c=e.children(l);if(!c.length)return void(l!==t&&e.setEdge(t,l,{weight:0,minlen:i}));let u=r.addBorderNode(e,"_bt"),h=r.addBorderNode(e,"_bb"),d=e.node(l);e.setParent(u,l),d.borderTop=u,e.setParent(h,l),d.borderBottom=h,c.forEach(r=>{n(e,t,i,s,o,a,r);let c=e.node(r),d=c.borderTop?c.borderTop:r,p=c.borderBottom?c.borderBottom:r,g=c.borderTop?s:2*s,f=d!==p?1:o-a[l]+1;e.setEdge(u,d,{weight:g,minlen:f,nestingEdge:!0}),e.setEdge(p,h,{weight:g,minlen:f,nestingEdge:!0})}),e.parent(l)||e.setEdge(t,u,{weight:0,minlen:o+a[l]})}e.exports={run:function(e){let t=r.addDummyNode(e,"root",{},"_root"),i=function(e){var t={};function i(r,n){var s=e.children(r);s&&s.length&&s.forEach(e=>i(e,n+1)),t[r]=n}return e.children().forEach(e=>i(e,1)),t}(e),s=Object.values(i),o=r.applyWithChunking(Math.max,s)-1,a=2*o+1;e.graph().nestingRoot=t,e.edges().forEach(t=>e.edge(t).minlen*=a);let l=function(e){return e.edges().reduce((t,i)=>t+e.edge(i).weight,0)}(e)+1;e.children().forEach(r=>n(e,t,a,l,o,i,r)),e.graph().nodeRankFactor=a},cleanup:function(e){var t=e.graph();e.removeNode(t.nestingRoot),delete t.nestingRoot,e.edges().forEach(t=>{e.edge(t).nestingEdge&&e.removeEdge(t)})}}},77798(e,t,i){"use strict";let r=i(82469);e.exports={run:function(e){e.graph().dummyChains=[],e.edges().forEach(t=>function(e,t){let i,n,s,o=t.v,a=e.node(o).rank,l=t.w,c=e.node(l).rank,u=t.name,h=e.edge(t),d=h.labelRank;if(c!==a+1){for(e.removeEdge(t),s=0,++a;a<c;++s,++a)h.points=[],n={width:0,height:0,edgeLabel:h,edgeObj:t,rank:a},i=r.addDummyNode(e,"edge",n,"_d"),a===d&&(n.width=h.width,n.height=h.height,n.dummy="edge-label",n.labelpos=h.labelpos),e.setEdge(o,i,{weight:h.weight},u),0===s&&e.graph().dummyChains.push(i),o=i;e.setEdge(o,l,{weight:h.weight},u)}}(e,t))},undo:function(e){e.graph().dummyChains.forEach(t=>{let i,r=e.node(t),n=r.edgeLabel;for(e.setEdge(r.edgeObj,n);r.dummy;)i=e.successors(t)[0],e.removeNode(t),n.points.push({x:r.x,y:r.y}),"edge-label"===r.dummy&&(n.x=r.x,n.y=r.y,n.width=r.width,n.height=r.height),t=i,r=e.node(t)})}}},6281(e){e.exports=function(e,t,i){let r,n={};i.forEach(i=>{let s,o,a=e.parent(i);for(;a;){if(s=e.parent(a),s?(o=n[s],n[s]=a):(o=r,r=a),o&&o!==a)return void t.setEdge(o,a);a=s}})}},21213(e){e.exports=function(e,t=[]){return t.map(t=>{let i=e.inEdges(t);if(i.length){let r=i.reduce((t,i)=>{let r=e.edge(i),n=e.node(i.v);return{sum:t.sum+r.weight*n.order,weight:t.weight+r.weight}},{sum:0,weight:0});return{v:t,barycenter:r.sum/r.weight,weight:r.weight}}return{v:t}})}},96703(e,t,i){let r=i(55166).Graph,n=i(82469);e.exports=function(e,t,i){let s=function(e){for(var t;e.hasNode(t=n.uniqueId("_root")););return t}(e),o=new r({compound:!0}).setGraph({root:s}).setDefaultNodeLabel(t=>e.node(t));return e.nodes().forEach(r=>{let n=e.node(r),a=e.parent(r);(n.rank===t||n.minRank<=t&&t<=n.maxRank)&&(o.setNode(r),o.setParent(r,a||s),e[i](r).forEach(t=>{let i=t.v===r?t.w:t.v,n=o.edge(i,r),s=void 0!==n?n.weight:0;o.setEdge(i,r,{weight:e.edge(t).weight+s})}),Object.hasOwn(n,"minRank")&&o.setNode(r,{borderLeft:n.borderLeft[t],borderRight:n.borderRight[t]}))}),o}},28304(e,t,i){"use strict";let r=i(82469).zipObject;function n(e,t,i){let n=r(i,i.map((e,t)=>t)),s=t.flatMap(t=>e.outEdges(t).map(t=>({pos:n[t.w],weight:e.edge(t).weight})).sort((e,t)=>e.pos-t.pos)),o=1;for(;o<i.length;)o<<=1;let a=2*o-1;o-=1;let l=new Array(a).fill(0),c=0;return s.forEach(e=>{let t=e.pos+o;l[t]+=e.weight;let i=0;for(;t>0;)t%2&&(i+=l[t+1]),t=t-1>>1,l[t]+=e.weight;c+=e.weight*i}),c}e.exports=function(e,t){let i=0;for(let r=1;r<t.length;++r)i+=n(e,t[r-1],t[r]);return i}},5354(e,t,i){"use strict";let r=i(15612),n=i(28304),s=i(93315),o=i(96703),a=i(6281),l=i(55166).Graph,c=i(82469);function u(e,t,i){return t.map(function(t){return o(e,t,i)})}function h(e,t){let i=new l;e.forEach(function(e){let r=e.graph().root,n=s(e,r,i,t);n.vs.forEach((t,i)=>e.node(t).order=i),a(e,i,n.vs)})}function d(e,t){Object.values(t).forEach(t=>t.forEach((t,i)=>e.node(t).order=i))}e.exports=function e(t,i){if(i&&"function"==typeof i.customOrder)return void i.customOrder(t,e);let s=c.maxRank(t),o=u(t,c.range(1,s+1),"inEdges"),a=u(t,c.range(s-1,-1,-1),"outEdges"),l=r(t);if(d(t,l),i&&i.disableOptimalOrderHeuristic)return;let p,g=Number.POSITIVE_INFINITY;for(let e=0,i=0;i<4;++e,++i){h(e%2?o:a,e%4>=2),l=c.buildLayerMatrix(t);let r=n(t,l);r<g&&(i=0,p=Object.assign({},l),g=r)}d(t,p)}},15612(e,t,i){"use strict";let r=i(82469);e.exports=function(e){let t={},i=e.nodes().filter(t=>!e.children(t).length),n=i.map(t=>e.node(t).rank),s=r.applyWithChunking(Math.max,n),o=r.range(s+1).map(()=>[]);return i.sort((t,i)=>e.node(t).rank-e.node(i).rank).forEach(function i(r){if(t[r])return;t[r]=!0;let n=e.node(r);o[n.rank].push(r),e.successors(r).forEach(i)}),o}},7216(e,t,i){"use strict";let r=i(82469);e.exports=function(e,t){let i={};return e.forEach((e,t)=>{let r=i[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:t};void 0!==e.barycenter&&(r.barycenter=e.barycenter,r.weight=e.weight)}),t.edges().forEach(e=>{let t=i[e.v],r=i[e.w];void 0!==t&&void 0!==r&&(r.indegree++,t.out.push(i[e.w]))}),function(e){let t=[];function i(e){return t=>{t.merged||(void 0===t.barycenter||void 0===e.barycenter||t.barycenter>=e.barycenter)&&function(e,t){let i=0,r=0;e.weight&&(i+=e.barycenter*e.weight,r+=e.weight),t.weight&&(i+=t.barycenter*t.weight,r+=t.weight),e.vs=t.vs.concat(e.vs),e.barycenter=i/r,e.weight=r,e.i=Math.min(t.i,e.i),t.merged=!0}(e,t)}}function n(t){return i=>{i.in.push(t),0===--i.indegree&&e.push(i)}}for(;e.length;){let r=e.pop();t.push(r),r.in.reverse().forEach(i(r)),r.out.forEach(n(r))}return t.filter(e=>!e.merged).map(e=>r.pick(e,["vs","i","barycenter","weight"]))}(Object.values(i).filter(e=>!e.indegree))}},93315(e,t,i){let r=i(21213),n=i(7216),s=i(31112);e.exports=function e(t,i,o,a){let l=t.children(i),c=t.node(i),u=c?c.borderLeft:void 0,h=c?c.borderRight:void 0,d={};u&&(l=l.filter(e=>e!==u&&e!==h));let p=r(t,l);p.forEach(i=>{if(t.children(i.v).length){let s=e(t,i.v,o,a);d[i.v]=s,Object.hasOwn(s,"barycenter")&&(n=s,void 0!==(r=i).barycenter?(r.barycenter=(r.barycenter*r.weight+n.barycenter*n.weight)/(r.weight+n.weight),r.weight+=n.weight):(r.barycenter=n.barycenter,r.weight=n.weight))}var r,n});let g=n(p,o);!function(e,t){e.forEach(e=>{e.vs=e.vs.flatMap(e=>t[e]?t[e].vs:e)})}(g,d);let f=s(g,a);if(u&&(f.vs=[u,f.vs,h].flat(!0),t.predecessors(u).length)){let e=t.node(t.predecessors(u)[0]),i=t.node(t.predecessors(h)[0]);Object.hasOwn(f,"barycenter")||(f.barycenter=0,f.weight=0),f.barycenter=(f.barycenter*f.weight+e.order+i.order)/(f.weight+2),f.weight+=2}return f}},31112(e,t,i){let r=i(82469);function n(e,t,i){let r;for(;t.length&&(r=t[t.length-1]).i<=i;)t.pop(),e.push(r.vs),i++;return i}e.exports=function(e,t){let i=r.partition(e,e=>Object.hasOwn(e,"barycenter")),s=i.lhs,o=i.rhs.sort((e,t)=>t.i-e.i),a=[],l=0,c=0,u=0;var h;s.sort((h=!!t,(e,t)=>e.barycenter<t.barycenter?-1:e.barycenter>t.barycenter?1:h?t.i-e.i:e.i-t.i)),u=n(a,o,u),s.forEach(e=>{u+=e.vs.length,a.push(e.vs),l+=e.barycenter*e.weight,c+=e.weight,u=n(a,o,u)});let d={vs:a.flat(!0)};return c&&(d.barycenter=l/c,d.weight=c),d}},77999(e){e.exports=function(e){let t=function(e){let t={},i=0;return e.children().forEach(function r(n){let s=i;e.children(n).forEach(r),t[n]={low:s,lim:i++}}),t}(e);e.graph().dummyChains.forEach(i=>{let r=e.node(i),n=r.edgeObj,s=function(e,t,i,r){let n,s,o=[],a=[],l=Math.min(t[i].low,t[r].low),c=Math.max(t[i].lim,t[r].lim);n=i;do{n=e.parent(n),o.push(n)}while(n&&(t[n].low>l||c>t[n].lim));for(s=n,n=r;(n=e.parent(n))!==s;)a.push(n);return{path:o.concat(a.reverse()),lca:s}}(e,t,n.v,n.w),o=s.path,a=s.lca,l=0,c=o[l],u=!0;for(;i!==n.w;){if(r=e.node(i),u){for(;(c=o[l])!==a&&e.node(c).maxRank<r.rank;)l++;c===a&&(u=!1)}if(!u){for(;l<o.length-1&&e.node(c=o[l+1]).minRank<=r.rank;)l++;c=o[l]}e.setParent(i,c),i=e.successors(i)[0]}})}},95101(e,t,i){"use strict";let r=i(55166).Graph,n=i(82469);function s(e,t){let i={};return t.length&&t.reduce(function(t,r){let n=0,s=0,o=t.length,l=r[r.length-1];return r.forEach((t,c)=>{let u=function(e,t){if(e.node(t).dummy)return e.predecessors(t).find(t=>e.node(t).dummy)}(e,t),h=u?e.node(u).order:o;(u||t===l)&&(r.slice(s,c+1).forEach(t=>{e.predecessors(t).forEach(r=>{let s=e.node(r),o=s.order;!(o<n||h<o)||s.dummy&&e.node(t).dummy||a(i,r,t)})}),s=c+1,n=h)}),r}),i}function o(e,t){let i={};function r(t,r,s,o,l){let c;n.range(r,s).forEach(r=>{c=t[r],e.node(c).dummy&&e.predecessors(c).forEach(t=>{let r=e.node(t);r.dummy&&(r.order<o||r.order>l)&&a(i,t,c)})})}return t.length&&t.reduce(function(t,i){let n,s=-1,o=0;return i.forEach((a,l)=>{if("border"===e.node(a).dummy){let t=e.predecessors(a);t.length&&(n=e.node(t[0]).order,r(i,o,l,s,n),o=l,s=n)}r(i,o,i.length,n,t.length)}),i}),i}function a(e,t,i){if(t>i){let e=t;t=i,i=e}let r=e[t];r||(e[t]=r={}),r[i]=!0}function l(e,t,i){if(t>i){let e=t;t=i,i=e}return!!e[t]&&Object.hasOwn(e[t],i)}function c(e,t,i,r){let n={},s={},o={};return t.forEach(e=>{e.forEach((e,t)=>{n[e]=e,s[e]=e,o[e]=t})}),t.forEach(e=>{let t=-1;e.forEach(e=>{let a=r(e);if(a.length){a=a.sort((e,t)=>o[e]-o[t]);let r=(a.length-1)/2;for(let c=Math.floor(r),u=Math.ceil(r);c<=u;++c){let r=a[c];s[e]===e&&t<o[r]&&!l(i,e,r)&&(s[r]=e,s[e]=n[e]=n[r],t=o[r])}}})}),{root:n,align:s}}function u(e,t,i,n,s){let o={},a=function(e,t,i,n){let s=new r,o=e.graph(),a=function(e,t,i){return(r,n,s)=>{let o,a=r.node(n),l=r.node(s),c=0;if(c+=a.width/2,Object.hasOwn(a,"labelpos"))switch(a.labelpos.toLowerCase()){case"l":o=-a.width/2;break;case"r":o=a.width/2}if(o&&(c+=i?o:-o),o=0,c+=(a.dummy?t:e)/2,c+=(l.dummy?t:e)/2,c+=l.width/2,Object.hasOwn(l,"labelpos"))switch(l.labelpos.toLowerCase()){case"l":o=l.width/2;break;case"r":o=-l.width/2}return o&&(c+=i?o:-o),o=0,c}}(o.nodesep,o.edgesep,n);return t.forEach(t=>{let r;t.forEach(t=>{let n=i[t];if(s.setNode(n),r){var o=i[r],l=s.edge(o,n);s.setEdge(o,n,Math.max(a(e,t,r),l||0))}r=t})}),s}(e,t,i,s),l=s?"borderLeft":"borderRight";function c(e,t){let i=a.nodes(),r=i.pop(),n={};for(;r;)n[r]?e(r):(n[r]=!0,i.push(r),i=i.concat(t(r))),r=i.pop()}return c(function(e){o[e]=a.inEdges(e).reduce((e,t)=>Math.max(e,o[t.v]+a.edge(t)),0)},a.predecessors.bind(a)),c(function(t){let i=a.outEdges(t).reduce((e,t)=>Math.min(e,o[t.w]-a.edge(t)),Number.POSITIVE_INFINITY),r=e.node(t);i!==Number.POSITIVE_INFINITY&&r.borderType!==l&&(o[t]=Math.max(o[t],i))},a.successors.bind(a)),Object.keys(n).forEach(e=>o[e]=o[i[e]]),o}function h(e,t){return Object.values(t).reduce((t,i)=>{let r=Number.NEGATIVE_INFINITY,n=Number.POSITIVE_INFINITY;Object.entries(i).forEach(([t,i])=>{let s=function(e,t){return e.node(t).width}(e,t)/2;r=Math.max(i+s,r),n=Math.min(i-s,n)});const s=r-n;return s<t[0]&&(t=[s,i]),t},[Number.POSITIVE_INFINITY,null])[1]}function d(e,t){let i=Object.values(t),r=n.applyWithChunking(Math.min,i),s=n.applyWithChunking(Math.max,i);["u","d"].forEach(i=>{["l","r"].forEach(o=>{let a=i+o,l=e[a];if(l===t)return;let c=Object.values(l),u=r-n.applyWithChunking(Math.min,c);"l"!==o&&(u=s-n.applyWithChunking(Math.max,c)),u&&(e[a]=n.mapValues(l,e=>e+u))})})}function p(e,t){return n.mapValues(e.ul,(i,r)=>{if(t)return e[t.toLowerCase()][r];{let t=Object.values(e).map(e=>e[r]).sort((e,t)=>e-t);return(t[1]+t[2])/2}})}e.exports={positionX:function(e){let t,i=n.buildLayerMatrix(e),r=Object.assign(s(e,i),o(e,i)),a={};["u","d"].forEach(s=>{t="u"===s?i:Object.values(i).reverse(),["l","r"].forEach(i=>{"r"===i&&(t=t.map(e=>Object.values(e).reverse()));let o=("u"===s?e.predecessors:e.successors).bind(e),l=c(0,t,r,o),h=u(e,t,l.root,l.align,"r"===i);"r"===i&&(h=n.mapValues(h,e=>-e)),a[s+i]=h})});let l=h(e,a);return d(a,l),p(a,e.graph().align)},findType1Conflicts:s,findType2Conflicts:o,addConflict:a,hasConflict:l,verticalAlignment:c,horizontalCompaction:u,alignCoordinates:d,findSmallestWidthAlignment:h,balance:p}},7489(e,t,i){"use strict";let r=i(82469),n=i(95101).positionX;e.exports=function(e){(function(e){let t=r.buildLayerMatrix(e),i=e.graph().ranksep,n=0;t.forEach(t=>{const r=t.reduce((t,i)=>{const r=e.node(i).height;return t>r?t:r},0);t.forEach(t=>e.node(t).y=n+r/2),n+=r+i})})(e=r.asNonCompoundGraph(e)),Object.entries(n(e)).forEach(([t,i])=>e.node(t).x=i)}},66884(e,t,i){"use strict";var r=i(55166).Graph,n=i(74354).slack;function s(e,t){return e.nodes().forEach(function i(r){t.nodeEdges(r).forEach(s=>{var o=s.v,a=r===o?s.w:o;e.hasNode(a)||n(t,s)||(e.setNode(a,{}),e.setEdge(r,a,{}),i(a))})}),e.nodeCount()}function o(e,t){return t.edges().reduce((i,r)=>{let s=Number.POSITIVE_INFINITY;return e.hasNode(r.v)!==e.hasNode(r.w)&&(s=n(t,r)),s<i[0]?[s,r]:i},[Number.POSITIVE_INFINITY,null])[1]}function a(e,t,i){e.nodes().forEach(e=>t.node(e).rank+=i)}e.exports=function(e){var t,i,l=new r({directed:!1}),c=e.nodes()[0],u=e.nodeCount();for(l.setNode(c,{});s(l,e)<u;)t=o(l,e),i=l.hasNode(t.v)?n(e,t):-n(e,t),a(l,e,i);return l}},83816(e,t,i){"use strict";var r=i(74354).longestPath,n=i(66884),s=i(48641);e.exports=function(e){var t=e.graph().ranker;if(t instanceof Function)return t(e);switch(e.graph().ranker){case"network-simplex":default:!function(e){s(e)}(e);break;case"tight-tree":!function(e){r(e),n(e)}(e);break;case"longest-path":o(e);case"none":}};var o=r},48641(e,t,i){"use strict";var r=i(66884),n=i(74354).slack,s=i(74354).longestPath,o=i(55166).alg.preorder,a=i(55166).alg.postorder,l=i(82469).simplify;function c(e){e=l(e),s(e);var t,i=r(e);for(d(i),u(i,e);t=g(i);)m(i,e,t,f(i,e,t))}function u(e,t){var i=a(e,e.nodes());(i=i.slice(0,i.length-1)).forEach(i=>function(e,t,i){var r=e.node(i).parent;e.edge(i,r).cutvalue=h(e,t,i)}(e,t,i))}function h(e,t,i){var r=e.node(i).parent,n=!0,s=t.edge(i,r),o=0;return s||(n=!1,s=t.edge(r,i)),o=s.weight,t.nodeEdges(i).forEach(s=>{var a,l,c=s.v===i,u=c?s.w:s.v;if(u!==r){var h=c===n,d=t.edge(s).weight;if(o+=h?d:-d,a=i,l=u,e.hasEdge(a,l)){var p=e.edge(i,u).cutvalue;o+=h?-p:p}}}),o}function d(e,t){arguments.length<2&&(t=e.nodes()[0]),p(e,{},1,t)}function p(e,t,i,r,n){var s=i,o=e.node(r);return t[r]=!0,e.neighbors(r).forEach(n=>{Object.hasOwn(t,n)||(i=p(e,t,i,n,r))}),o.low=s,o.lim=i++,n?o.parent=n:delete o.parent,i}function g(e){return e.edges().find(t=>e.edge(t).cutvalue<0)}function f(e,t,i){var r=i.v,s=i.w;t.hasEdge(r,s)||(r=i.w,s=i.v);var o=e.node(r),a=e.node(s),l=o,c=!1;o.lim>a.lim&&(l=a,c=!0);var u=t.edges().filter(t=>c===v(0,e.node(t.v),l)&&c!==v(0,e.node(t.w),l));return u.reduce((e,i)=>n(t,i)<n(t,e)?i:e)}function m(e,t,i,r){var n=i.v,s=i.w;e.removeEdge(n,s),e.setEdge(r.v,r.w,{}),d(e),u(e,t),function(e,t){var i=e.nodes().find(e=>!t.node(e).parent),r=o(e,i);(r=r.slice(1)).forEach(i=>{var r=e.node(i).parent,n=t.edge(i,r),s=!1;n||(n=t.edge(r,i),s=!0),t.node(i).rank=t.node(r).rank+(s?n.minlen:-n.minlen)})}(e,t)}function v(e,t,i){return i.low<=t.lim&&t.lim<=i.lim}e.exports=c,c.initLowLimValues=d,c.initCutValues=u,c.calcCutValue=h,c.leaveEdge=g,c.enterEdge=f,c.exchangeEdges=m},74354(e,t,i){"use strict";const{applyWithChunking:r}=i(82469);e.exports={longestPath:function(e){var t={};e.sources().forEach(function i(n){var s=e.node(n);if(Object.hasOwn(t,n))return s.rank;t[n]=!0;let o=e.outEdges(n).map(t=>null==t?Number.POSITIVE_INFINITY:i(t.w)-e.edge(t).minlen);var a=r(Math.min,o);return a===Number.POSITIVE_INFINITY&&(a=0),s.rank=a})},slack:function(e,t){return e.node(t.w).rank-e.node(t.v).rank-e.edge(t).minlen}}},82469(e,t,i){"use strict";let r=i(55166).Graph;function n(e,t,i,r){for(var n=r;e.hasNode(n);)n=l(r);return i.dummy=t,e.setNode(n,i),n}e.exports={addBorderNode:function(e,t,i,r){let s={width:0,height:0};return arguments.length>=4&&(s.rank=i,s.order=r),n(e,"border",s,t)},addDummyNode:n,applyWithChunking:s,asNonCompoundGraph:function(e){let t=new r({multigraph:e.isMultigraph()}).setGraph(e.graph());return e.nodes().forEach(i=>{e.children(i).length||t.setNode(i,e.node(i))}),e.edges().forEach(i=>{t.setEdge(i,e.edge(i))}),t},buildLayerMatrix:function(e){let t=c(o(e)+1).map(()=>[]);return e.nodes().forEach(i=>{let r=e.node(i),n=r.rank;void 0!==n&&(t[n][r.order]=i)}),t},intersectRect:function(e,t){let i,r,n=e.x,s=e.y,o=t.x-n,a=t.y-s,l=e.width/2,c=e.height/2;if(!o&&!a)throw new Error("Not possible to find intersection inside of the rectangle");return Math.abs(a)*l>Math.abs(o)*c?(a<0&&(c=-c),i=c*o/a,r=c):(o<0&&(l=-l),i=l,r=l*a/o),{x:n+i,y:s+r}},mapValues:function(e,t){let i=t;return"string"==typeof t&&(i=e=>e[t]),Object.entries(e).reduce((e,[t,r])=>(e[t]=i(r,t),e),{})},maxRank:o,normalizeRanks:function(e){let t=e.nodes().map(t=>{let i=e.node(t).rank;return void 0===i?Number.MAX_VALUE:i}),i=s(Math.min,t);e.nodes().forEach(t=>{let r=e.node(t);Object.hasOwn(r,"rank")&&(r.rank-=i)})},notime:function(e,t){return t()},partition:function(e,t){let i={lhs:[],rhs:[]};return e.forEach(e=>{t(e)?i.lhs.push(e):i.rhs.push(e)}),i},pick:function(e,t){const i={};for(const r of t)void 0!==e[r]&&(i[r]=e[r]);return i},predecessorWeights:function(e){let t=e.nodes().map(t=>{let i={};return e.inEdges(t).forEach(t=>{i[t.v]=(i[t.v]||0)+e.edge(t).weight}),i});return u(e.nodes(),t)},range:c,removeEmptyRanks:function(e){let t=e.nodes().map(t=>e.node(t).rank),i=s(Math.min,t),r=[];e.nodes().forEach(t=>{let n=e.node(t).rank-i;r[n]||(r[n]=[]),r[n].push(t)});let n=0,o=e.graph().nodeRankFactor;Array.from(r).forEach((t,i)=>{void 0===t&&i%o!==0?--n:void 0!==t&&n&&t.forEach(t=>e.node(t).rank+=n)})},simplify:function(e){let t=(new r).setGraph(e.graph());return e.nodes().forEach(i=>t.setNode(i,e.node(i))),e.edges().forEach(i=>{let r=t.edge(i.v,i.w)||{weight:0,minlen:1},n=e.edge(i);t.setEdge(i.v,i.w,{weight:r.weight+n.weight,minlen:Math.max(r.minlen,n.minlen)})}),t},successorWeights:function(e){let t=e.nodes().map(t=>{let i={};return e.outEdges(t).forEach(t=>{i[t.w]=(i[t.w]||0)+e.edge(t).weight}),i});return u(e.nodes(),t)},time:function(e,t){let i=Date.now();try{return t()}finally{console.log(e+" time: "+(Date.now()-i)+"ms")}},uniqueId:l,zipObject:u};function s(e,t){if(t.length>65535){const i=function(e,t=65535){const i=[];for(let r=0;r<e.length;r+=t){const n=e.slice(r,r+t);i.push(n)}return i}(t);return e.apply(null,i.map(t=>e.apply(null,t)))}return e.apply(null,t)}function o(e){const t=e.nodes().map(t=>{let i=e.node(t).rank;return void 0===i?Number.MIN_VALUE:i});return s(Math.max,t)}let a=0;function l(e){return e+""+ ++a}function c(e,t,i=1){null==t&&(t=e,e=0);let r=e=>e<t;i<0&&(r=e=>t<e);const n=[];for(let t=e;r(t);t+=i)n.push(t);return n}function u(e,t){return e.reduce((e,i,r)=>(e[i]=t[r],e),{})}},69741(e){e.exports="1.1.5"},55166(e,t,i){var r=i(72482);e.exports={Graph:r.Graph,json:i(73082),alg:i(42703),version:r.version}},55783(e){e.exports=function(e){var t,i={},r=[];function n(r){Object.hasOwn(i,r)||(i[r]=!0,t.push(r),e.successors(r).forEach(n),e.predecessors(r).forEach(n))}return e.nodes().forEach(function(e){t=[],n(e),t.length&&r.push(t)}),r}},10400(e){function t(e,t,i,n){for(var s=[[e,!1]];s.length>0;){var o=s.pop();o[1]?n.push(o[0]):Object.hasOwn(i,o[0])||(i[o[0]]=!0,s.push([o[0],!0]),r(t(o[0]),e=>s.push([e,!1])))}}function i(e,t,i,n){for(var s=[e];s.length>0;){var o=s.pop();Object.hasOwn(i,o)||(i[o]=!0,n.push(o),r(t(o),e=>s.push(e)))}}function r(e,t){for(var i=e.length;i--;)t(e[i],i,e);return e}e.exports=function(e,r,n){Array.isArray(r)||(r=[r]);var s=e.isDirected()?t=>e.successors(t):t=>e.neighbors(t),o="post"===n?t:i,a=[],l={};return r.forEach(t=>{if(!e.hasNode(t))throw new Error("Graph does not have node: "+t);o(t,s,l,a)}),a}},32843(e,t,i){var r=i(59349);e.exports=function(e,t,i){return e.nodes().reduce(function(n,s){return n[s]=r(e,s,t,i),n},{})}},59349(e,t,i){var r=i(52821);e.exports=function(e,t,i,s){return function(e,t,i,n){var s,o,a={},l=new r,c=function(e){var t=e.v!==s?e.v:e.w,r=a[t],n=i(e),c=o.distance+n;if(n<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+e+" Weight: "+n);c<r.distance&&(r.distance=c,r.predecessor=s,l.decrease(t,c))};for(e.nodes().forEach(function(e){var i=e===t?0:Number.POSITIVE_INFINITY;a[e]={distance:i},l.add(e,i)});l.size()>0&&(s=l.removeMin(),(o=a[s]).distance!==Number.POSITIVE_INFINITY);)n(s).forEach(c);return a}(e,String(t),i||n,s||function(t){return e.outEdges(t)})};var n=()=>1},57706(e,t,i){var r=i(52495);e.exports=function(e){return r(e).filter(function(t){return t.length>1||1===t.length&&e.hasEdge(t[0],t[0])})}},85298(e){e.exports=function(e,i,r){return function(e,t,i){var r={},n=e.nodes();return n.forEach(function(e){r[e]={},r[e][e]={distance:0},n.forEach(function(t){e!==t&&(r[e][t]={distance:Number.POSITIVE_INFINITY})}),i(e).forEach(function(i){var n=i.v===e?i.w:i.v,s=t(i);r[e][n]={distance:s,predecessor:e}})}),n.forEach(function(e){var t=r[e];n.forEach(function(i){var s=r[i];n.forEach(function(i){var r=s[e],n=t[i],o=s[i],a=r.distance+n.distance;a<o.distance&&(o.distance=a,o.predecessor=n.predecessor)})})}),r}(e,i||t,r||function(t){return e.outEdges(t)})};var t=()=>1},42703(e,t,i){e.exports={components:i(55783),dijkstra:i(59349),dijkstraAll:i(32843),findCycles:i(57706),floydWarshall:i(85298),isAcyclic:i(20574),postorder:i(26385),preorder:i(57484),prim:i(8523),tarjan:i(52495),topsort:i(81412)}},20574(e,t,i){var r=i(81412);e.exports=function(e){try{r(e)}catch(e){if(e instanceof r.CycleException)return!1;throw e}return!0}},26385(e,t,i){var r=i(10400);e.exports=function(e,t){return r(e,t,"post")}},57484(e,t,i){var r=i(10400);e.exports=function(e,t){return r(e,t,"pre")}},8523(e,t,i){var r=i(76234),n=i(52821);e.exports=function(e,t){var i,s=new r,o={},a=new n;function l(e){var r=e.v===i?e.w:e.v,n=a.priority(r);if(void 0!==n){var s=t(e);s<n&&(o[r]=i,a.decrease(r,s))}}if(0===e.nodeCount())return s;e.nodes().forEach(function(e){a.add(e,Number.POSITIVE_INFINITY),s.setNode(e)}),a.decrease(e.nodes()[0],0);for(var c=!1;a.size()>0;){if(i=a.removeMin(),Object.hasOwn(o,i))s.setEdge(i,o[i]);else{if(c)throw new Error("Input graph is not connected: "+e);c=!0}e.nodeEdges(i).forEach(l)}return s}},52495(e){e.exports=function(e){var t=0,i=[],r={},n=[];function s(o){var a=r[o]={onStack:!0,lowlink:t,index:t++};if(i.push(o),e.successors(o).forEach(function(e){Object.hasOwn(r,e)?r[e].onStack&&(a.lowlink=Math.min(a.lowlink,r[e].index)):(s(e),a.lowlink=Math.min(a.lowlink,r[e].lowlink))}),a.lowlink===a.index){var l,c=[];do{l=i.pop(),r[l].onStack=!1,c.push(l)}while(o!==l);n.push(c)}}return e.nodes().forEach(function(e){Object.hasOwn(r,e)||s(e)}),n}},81412(e){function t(e){var t={},r={},n=[];if(e.sinks().forEach(function s(o){if(Object.hasOwn(r,o))throw new i;Object.hasOwn(t,o)||(r[o]=!0,t[o]=!0,e.predecessors(o).forEach(s),delete r[o],n.push(o))}),Object.keys(t).length!==e.nodeCount())throw new i;return n}class i extends Error{constructor(){super(...arguments)}}e.exports=t,t.CycleException=i},52821(e){e.exports=class{_arr=[];_keyIndices={};size(){return this._arr.length}keys(){return this._arr.map(function(e){return e.key})}has(e){return Object.hasOwn(this._keyIndices,e)}priority(e){var t=this._keyIndices[e];if(void 0!==t)return this._arr[t].priority}min(){if(0===this.size())throw new Error("Queue underflow");return this._arr[0].key}add(e,t){var i=this._keyIndices;if(e=String(e),!Object.hasOwn(i,e)){var r=this._arr,n=r.length;return i[e]=n,r.push({key:e,priority:t}),this._decrease(n),!0}return!1}removeMin(){this._swap(0,this._arr.length-1);var e=this._arr.pop();return delete this._keyIndices[e.key],this._heapify(0),e.key}decrease(e,t){var i=this._keyIndices[e];if(t>this._arr[i].priority)throw new Error("New priority is greater than current priority. Key: "+e+" Old: "+this._arr[i].priority+" New: "+t);this._arr[i].priority=t,this._decrease(i)}_heapify(e){var t=this._arr,i=2*e,r=i+1,n=e;i<t.length&&(n=t[i].priority<t[n].priority?i:n,r<t.length&&(n=t[r].priority<t[n].priority?r:n),n!==e&&(this._swap(e,n),this._heapify(n)))}_decrease(e){for(var t,i=this._arr,r=i[e].priority;0!==e&&!(i[t=e>>1].priority<r);)this._swap(e,t),e=t}_swap(e,t){var i=this._arr,r=this._keyIndices,n=i[e],s=i[t];i[e]=s,i[t]=n,r[s.key]=e,r[n.key]=t}}},76234(e){"use strict";var t="\0";function i(e,t){e[t]?e[t]++:e[t]=1}function r(e,t){--e[t]||delete e[t]}function n(e,t,i,r){var n=""+t,s=""+i;if(!e&&n>s){var o=n;n=s,s=o}return n+""+s+""+(void 0===r?"\0":r)}function s(e,t){return n(e,t.v,t.w,t.name)}e.exports=class{_isDirected=!0;_isMultigraph=!1;_isCompound=!1;_label;_defaultNodeLabelFn=()=>{};_defaultEdgeLabelFn=()=>{};_nodes={};_in={};_preds={};_out={};_sucs={};_edgeObjs={};_edgeLabels={};_nodeCount=0;_edgeCount=0;_parent;_children;constructor(e){e&&(this._isDirected=!Object.hasOwn(e,"directed")||e.directed,this._isMultigraph=!!Object.hasOwn(e,"multigraph")&&e.multigraph,this._isCompound=!!Object.hasOwn(e,"compound")&&e.compound),this._isCompound&&(this._parent={},this._children={},this._children[t]={})}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return this._defaultNodeLabelFn=e,"function"!=typeof e&&(this._defaultNodeLabelFn=()=>e),this}nodeCount(){return this._nodeCount}nodes(){return Object.keys(this._nodes)}sources(){var e=this;return this.nodes().filter(t=>0===Object.keys(e._in[t]).length)}sinks(){var e=this;return this.nodes().filter(t=>0===Object.keys(e._out[t]).length)}setNodes(e,t){var i=arguments,r=this;return e.forEach(function(e){i.length>1?r.setNode(e,t):r.setNode(e)}),this}setNode(e,i){return Object.hasOwn(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=i),this):(this._nodes[e]=arguments.length>1?i:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=t,this._children[e]={},this._children[t][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.hasOwn(this._nodes,e)}removeNode(e){var t=this;if(Object.hasOwn(this._nodes,e)){var i=e=>t.removeEdge(t._edgeObjs[e]);delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],this.children(e).forEach(function(e){t.setParent(e)}),delete this._children[e]),Object.keys(this._in[e]).forEach(i),delete this._in[e],delete this._preds[e],Object.keys(this._out[e]).forEach(i),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,i){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(void 0===i)i=t;else{for(var r=i+="";void 0!==r;r=this.parent(r))if(r===e)throw new Error("Setting "+i+" as parent of "+e+" would create a cycle");this.setNode(i)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=i,this._children[i][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var i=this._parent[e];if(i!==t)return i}}children(e=t){if(this._isCompound){var i=this._children[e];if(i)return Object.keys(i)}else{if(e===t)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return Object.keys(t)}successors(e){var t=this._sucs[e];if(t)return Object.keys(t)}neighbors(e){var t=this.predecessors(e);if(t){const r=new Set(t);for(var i of this.successors(e))r.add(i);return Array.from(r.values())}}isLeaf(e){return 0===(this.isDirected()?this.successors(e):this.neighbors(e)).length}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var i=this;Object.entries(this._nodes).forEach(function([i,r]){e(i)&&t.setNode(i,r)}),Object.values(this._edgeObjs).forEach(function(e){t.hasNode(e.v)&&t.hasNode(e.w)&&t.setEdge(e,i.edge(e))});var r={};function n(e){var s=i.parent(e);return void 0===s||t.hasNode(s)?(r[e]=s,s):s in r?r[s]:n(s)}return this._isCompound&&t.nodes().forEach(e=>t.setParent(e,n(e))),t}setDefaultEdgeLabel(e){return this._defaultEdgeLabelFn=e,"function"!=typeof e&&(this._defaultEdgeLabelFn=()=>e),this}edgeCount(){return this._edgeCount}edges(){return Object.values(this._edgeObjs)}setPath(e,t){var i=this,r=arguments;return e.reduce(function(e,n){return r.length>1?i.setEdge(e,n,t):i.setEdge(e,n),n}),this}setEdge(){var e,t,r,s,o=!1,a=arguments[0];"object"==typeof a&&null!==a&&"v"in a?(e=a.v,t=a.w,r=a.name,2===arguments.length&&(s=arguments[1],o=!0)):(e=a,t=arguments[1],r=arguments[3],arguments.length>2&&(s=arguments[2],o=!0)),e=""+e,t=""+t,void 0!==r&&(r=""+r);var l=n(this._isDirected,e,t,r);if(Object.hasOwn(this._edgeLabels,l))return o&&(this._edgeLabels[l]=s),this;if(void 0!==r&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[l]=o?s:this._defaultEdgeLabelFn(e,t,r);var c=function(e,t,i,r){var n=""+t,s=""+i;if(!e&&n>s){var o=n;n=s,s=o}var a={v:n,w:s};return r&&(a.name=r),a}(this._isDirected,e,t,r);return e=c.v,t=c.w,Object.freeze(c),this._edgeObjs[l]=c,i(this._preds[t],e),i(this._sucs[e],t),this._in[t][l]=c,this._out[e][l]=c,this._edgeCount++,this}edge(e,t,i){var r=1===arguments.length?s(this._isDirected,arguments[0]):n(this._isDirected,e,t,i);return this._edgeLabels[r]}edgeAsObj(){const e=this.edge(...arguments);return"object"!=typeof e?{label:e}:e}hasEdge(e,t,i){var r=1===arguments.length?s(this._isDirected,arguments[0]):n(this._isDirected,e,t,i);return Object.hasOwn(this._edgeLabels,r)}removeEdge(e,t,i){var o=1===arguments.length?s(this._isDirected,arguments[0]):n(this._isDirected,e,t,i),a=this._edgeObjs[o];return a&&(e=a.v,t=a.w,delete this._edgeLabels[o],delete this._edgeObjs[o],r(this._preds[t],e),r(this._sucs[e],t),delete this._in[t][o],delete this._out[e][o],this._edgeCount--),this}inEdges(e,t){var i=this._in[e];if(i){var r=Object.values(i);return t?r.filter(e=>e.v===t):r}}outEdges(e,t){var i=this._out[e];if(i){var r=Object.values(i);return t?r.filter(e=>e.w===t):r}}nodeEdges(e,t){var i=this.inEdges(e,t);if(i)return i.concat(this.outEdges(e,t))}}},72482(e,t,i){e.exports={Graph:i(76234),version:i(51350)}},73082(e,t,i){var r=i(76234);function n(e){return e.nodes().map(function(t){var i=e.node(t),r=e.parent(t),n={v:t};return void 0!==i&&(n.value=i),void 0!==r&&(n.parent=r),n})}function s(e){return e.edges().map(function(t){var i=e.edge(t),r={v:t.v,w:t.w};return void 0!==t.name&&(r.name=t.name),void 0!==i&&(r.value=i),r})}e.exports={write:function(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:n(e),edges:s(e)};return void 0!==e.graph()&&(t.value=structuredClone(e.graph())),t},read:function(e){var t=new r(e.options).setGraph(e.value);return e.nodes.forEach(function(e){t.setNode(e.v,e.value),e.parent&&t.setParent(e.v,e.parent)}),e.edges.forEach(function(e){t.setEdge({v:e.v,w:e.w,name:e.name},e.value)}),t}}},51350(e){e.exports="2.2.4"},85997(e,t,i){"use strict";i.d(t,{A:()=>o});var r=i(5866),n=i.n(r);const s={normalDateWithWeekday:"ddd, MMM D",normalDate:"D MMMM",shortDate:"MMM D",monthAndDate:"MMMM D",dayOfMonth:"D",year:"YYYY",month:"MMMM",monthShort:"MMM",monthAndYear:"MMMM YYYY",weekday:"dddd",weekdayShort:"ddd",minutes:"mm",hours12h:"hh",hours24h:"HH",seconds:"ss",fullTime:"LT",fullTime12h:"hh:mm A",fullTime24h:"HH:mm",fullDate:"ll",fullDateWithWeekday:"dddd, LL",fullDateTime:"lll",fullDateTime12h:"ll hh:mm A",fullDateTime24h:"ll HH:mm",keyboardDate:"L",keyboardDateTime:"L LT",keyboardDateTime12h:"L hh:mm A",keyboardDateTime24h:"L HH:mm"};class o{constructor({locale:e,formats:t,instance:i}={}){this.lib="moment",this.is12HourCycleInCurrentLocale=()=>/A|a/.test(this.moment.localeData(this.getCurrentLocaleCode()).longDateFormat("LT")),this.getFormatHelperText=e=>{var t,i;return null!==(i=null===(t=e.match(/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})|./g))||void 0===t?void 0:t.map(e=>{const t=e[0];return"L"===t||";"===t?this.moment.localeData(this.getCurrentLocaleCode()).longDateFormat(e):e}).join("").replace(/a/gi,"(a|p)m").toLocaleLowerCase())&&void 0!==i?i:e},this.getCurrentLocaleCode=()=>this.locale||this.moment.locale(),this.parseISO=e=>this.moment(e,!0),this.toISO=e=>e.toISOString(),this.parse=(e,t)=>""===e?null:this.locale?this.moment(e,t,this.locale,!0):this.moment(e,t,!0),this.date=e=>{if(null===e)return null;const t=this.moment(e);return this.locale&&t.locale(this.locale),t},this.toJsDate=e=>e.toDate(),this.isValid=e=>this.moment(e).isValid(),this.isNull=e=>null===e,this.getDiff=(e,t,i)=>this.moment(t).isValid()?e.diff(t,i):0,this.isAfter=(e,t)=>e.isAfter(t),this.isBefore=(e,t)=>e.isBefore(t),this.isAfterDay=(e,t)=>e.isAfter(t,"day"),this.isBeforeDay=(e,t)=>e.isBefore(t,"day"),this.isBeforeMonth=(e,t)=>e.isBefore(t,"month"),this.isAfterMonth=(e,t)=>e.isAfter(t,"month"),this.isBeforeYear=(e,t)=>e.isBefore(t,"year"),this.isAfterYear=(e,t)=>e.isAfter(t,"year"),this.startOfDay=e=>e.clone().startOf("day"),this.endOfDay=e=>e.clone().endOf("day"),this.format=(e,t)=>this.formatByString(e,this.formats[t]),this.formatByString=(e,t)=>{const i=e.clone();return this.locale&&i.locale(this.locale),i.format(t)},this.formatNumber=e=>e,this.getHours=e=>e.get("hours"),this.addSeconds=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"seconds"):e.clone().add(t,"seconds"),this.addMinutes=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"minutes"):e.clone().add(t,"minutes"),this.addHours=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"hours"):e.clone().add(t,"hours"),this.addDays=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"days"):e.clone().add(t,"days"),this.addWeeks=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"weeks"):e.clone().add(t,"weeks"),this.addMonths=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"months"):e.clone().add(t,"months"),this.addYears=(e,t)=>t<0?e.clone().subtract(Math.abs(t),"years"):e.clone().add(t,"years"),this.setHours=(e,t)=>e.clone().hours(t),this.getMinutes=e=>e.get("minutes"),this.setMinutes=(e,t)=>e.clone().minutes(t),this.getSeconds=e=>e.get("seconds"),this.setSeconds=(e,t)=>e.clone().seconds(t),this.getMonth=e=>e.get("month"),this.getDaysInMonth=e=>e.daysInMonth(),this.isSameDay=(e,t)=>e.isSame(t,"day"),this.isSameMonth=(e,t)=>e.isSame(t,"month"),this.isSameYear=(e,t)=>e.isSame(t,"year"),this.isSameHour=(e,t)=>e.isSame(t,"hour"),this.setMonth=(e,t)=>e.clone().month(t),this.getMeridiemText=e=>this.is12HourCycleInCurrentLocale()?this.moment.localeData(this.getCurrentLocaleCode()).meridiem("am"===e?0:13,0,!1):"am"===e?"AM":"PM",this.startOfYear=e=>e.clone().startOf("year"),this.endOfYear=e=>e.clone().endOf("year"),this.startOfMonth=e=>e.clone().startOf("month"),this.endOfMonth=e=>e.clone().endOf("month"),this.startOfWeek=e=>e.clone().startOf("week"),this.endOfWeek=e=>e.clone().endOf("week"),this.getNextMonth=e=>e.clone().add(1,"month"),this.getPreviousMonth=e=>e.clone().subtract(1,"month"),this.getMonthArray=e=>{const t=[e.clone().startOf("year")];for(;t.length<12;){const e=t[t.length-1];t.push(this.getNextMonth(e))}return t},this.getYear=e=>e.get("year"),this.setYear=(e,t)=>e.clone().set("year",t),this.getDate=e=>e.get("date"),this.setDate=(e,t)=>e.clone().set("date",t),this.mergeDateAndTime=(e,t)=>e.hour(t.hour()).minute(t.minute()).second(t.second()),this.getWeekdays=()=>this.moment.weekdaysShort(!0),this.isEqual=(e,t)=>null===e&&null===t||this.moment(e).isSame(t),this.getWeekArray=e=>{const t=e.clone().startOf("month").startOf("week"),i=e.clone().endOf("month").endOf("week");let r=0,n=t;const s=[];for(;n.isBefore(i);){const e=Math.floor(r/7);s[e]=s[e]||[],s[e].push(n),n=n.clone().add(1,"day"),r+=1}return s},this.getYearRange=(e,t)=>{const i=this.moment(e).startOf("year"),r=this.moment(t).endOf("year"),n=[];let s=i;for(;s.isBefore(r);)n.push(s),s=s.clone().add(1,"year");return n},this.isWithinRange=(e,[t,i])=>e.isBetween(t,i,null,"[]"),this.moment=i||n(),this.locale=e,this.formats=Object.assign({},s,t)}}},41487(e,t,i){"use strict";i.r(t),i.d(t,{default:()=>m});var r=i(8900),n=i(46903),s=i(75612),o=i(16253),a=i(95093),l=i(3746),c=i(39574),u=function(e,t,i){for(var r=0,n=0;r=n,n=(0,a.se)(),38===r&&12===n&&(t[i]=1),!(0,a.Sh)(n);)(0,a.K2)();return(0,a.di)(e,a.G1)},h=new WeakMap,d=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,i=e.parent,r=e.column===i.column&&e.line===i.line;"rule"!==i.type;)if(!(i=i.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||h.get(i))&&!r){h.set(e,!0);for(var n=[],o=function(e,t){return(0,a.VF)(function(e,t){var i=-1,r=44;do{switch((0,a.Sh)(r)){case 0:38===r&&12===(0,a.se)()&&(t[i]=1),e[i]+=u(a.G1-1,t,i);break;case 2:e[i]+=(0,a.Tb)(r);break;case 4:if(44===r){e[++i]=58===(0,a.se)()?"&\f":"",t[i]=e[i].length;break}default:e[i]+=(0,s.HT)(r)}}while(r=(0,a.K2)());return e}((0,a.c4)(e),t))}(t,n),l=i.props,c=0,d=0;c<o.length;c++)for(var p=0;p<l.length;p++,d++)e.props[d]=n[c]?o[c].replace(/&\f/g,l[p]):l[p]+" "+o[c]}}},p=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function g(e,t){switch((0,s.tW)(e,t)){case 5103:return n.j+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return n.j+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return n.j+e+n.vd+e+n.MS+e+e;case 6828:case 4268:return n.j+e+n.MS+e+e;case 6165:return n.j+e+n.MS+"flex-"+e+e;case 5187:return n.j+e+(0,s.HC)(e,/(\w+).+(:[^]+)/,n.j+"box-$1$2"+n.MS+"flex-$1$2")+e;case 5443:return n.j+e+n.MS+"flex-item-"+(0,s.HC)(e,/flex-|-self/,"")+e;case 4675:return n.j+e+n.MS+"flex-line-pack"+(0,s.HC)(e,/align-content|flex-|-self/,"")+e;case 5548:return n.j+e+n.MS+(0,s.HC)(e,"shrink","negative")+e;case 5292:return n.j+e+n.MS+(0,s.HC)(e,"basis","preferred-size")+e;case 6060:return n.j+"box-"+(0,s.HC)(e,"-grow","")+n.j+e+n.MS+(0,s.HC)(e,"grow","positive")+e;case 4554:return n.j+(0,s.HC)(e,/([^-])(transform)/g,"$1"+n.j+"$2")+e;case 6187:return(0,s.HC)((0,s.HC)((0,s.HC)(e,/(zoom-|grab)/,n.j+"$1"),/(image-set)/,n.j+"$1"),e,"")+e;case 5495:case 3959:return(0,s.HC)(e,/(image-set\([^]*)/,n.j+"$1$`$1");case 4968:return(0,s.HC)((0,s.HC)(e,/(.+:)(flex-)?(.*)/,n.j+"box-pack:$3"+n.MS+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+n.j+e+e;case 4095:case 3583:case 4068:case 2532:return(0,s.HC)(e,/(.+)-inline(.+)/,n.j+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if((0,s.b2)(e)-1-t>6)switch((0,s.wN)(e,t+1)){case 109:if(45!==(0,s.wN)(e,t+4))break;case 102:return(0,s.HC)(e,/(.+:)(.+)-([^]+)/,"$1"+n.j+"$2-$3$1"+n.vd+(108==(0,s.wN)(e,t+3)?"$3":"$2-$3"))+e;case 115:return~(0,s.K5)(e,"stretch")?g((0,s.HC)(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==(0,s.wN)(e,t+1))break;case 6444:switch((0,s.wN)(e,(0,s.b2)(e)-3-(~(0,s.K5)(e,"!important")&&10))){case 107:return(0,s.HC)(e,":",":"+n.j)+e;case 101:return(0,s.HC)(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+n.j+(45===(0,s.wN)(e,14)?"inline-":"")+"box$3$1"+n.j+"$2$3$1"+n.MS+"$2box$3")+e}break;case 5936:switch((0,s.wN)(e,t+11)){case 114:return n.j+e+n.MS+(0,s.HC)(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return n.j+e+n.MS+(0,s.HC)(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return n.j+e+n.MS+(0,s.HC)(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return n.j+e+n.MS+e+e}return e}var f=[function(e,t,i,r){if(e.length>-1&&!e.return)switch(e.type){case n.LU:e.return=g(e.value,e.length);break;case n.Sv:return(0,l.l)([(0,a.C)(e,{value:(0,s.HC)(e.value,"@","@"+n.j)})],r);case n.XZ:if(e.length)return(0,s.kg)(e.props,function(t){switch((0,s.YW)(t,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return(0,l.l)([(0,a.C)(e,{props:[(0,s.HC)(t,/:(read-\w+)/,":"+n.vd+"$1")]})],r);case"::placeholder":return(0,l.l)([(0,a.C)(e,{props:[(0,s.HC)(t,/:(plac\w+)/,":"+n.j+"input-$1")]}),(0,a.C)(e,{props:[(0,s.HC)(t,/:(plac\w+)/,":"+n.vd+"$1")]}),(0,a.C)(e,{props:[(0,s.HC)(t,/:(plac\w+)/,n.MS+"input-$1")]})],r)}return""})}}],m=function(e){var t=e.key;if("css"===t){var i=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(i,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var n,s,a=e.stylisPlugins||f,u={},h=[];n=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),i=1;i<t.length;i++)u[t[i]]=!0;h.push(e)});var g,m=[d,p],v=[l.A,(0,c.MY)(function(e){g.insert(e)})],C=(0,c.r1)(m.concat(a,v));s=function(e,t,i,r){var n;g=i,n=e?e+"{"+t.styles+"}":t.styles,(0,l.l)((0,o.wE)(n),C),r&&(y.inserted[t.name]=!0)};var y={key:t,sheet:new r.StyleSheet({key:t,container:n,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:u,registered:{},insert:s};return y.sheet.hydrate(h),y}},22066(e,t,i){"use strict";i.r(t),i.d(t,{CacheProvider:()=>x,ClassNames:()=>U,Global:()=>G,ThemeContext:()=>P,createElement:()=>k,css:()=>F,jsx:()=>k,keyframes:()=>H,withEmotionCache:()=>D});var r=i(20415),n=i(22155),s=function(){function e(e){this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.before=null}var t=e.prototype;return t.insert=function(e){if(this.ctr%(this.isSpeedy?65e3:1)==0){var t,i=function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t}(this);t=0===this.tags.length?this.before:this.tags[this.tags.length-1].nextSibling,this.container.insertBefore(i,t),this.tags.push(i)}var r=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(r);try{var s=105===e.charCodeAt(1)&&64===e.charCodeAt(0);n.insertRule(e,s?0:n.cssRules.length)}catch(e){}}else r.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){return e.parentNode.removeChild(e)}),this.tags=[],this.ctr=0},e}(),o=i(27903),a="/*|*/",l=a+"}";function c(e){e&&u.current.insert(e+"}")}var u={current:null},h=function(e,t,i,r,n,s,o,h,d,p){switch(e){case 1:switch(t.charCodeAt(0)){case 64:return u.current.insert(t+";"),"";case 108:if(98===t.charCodeAt(2))return""}break;case 2:if(0===h)return t+a;break;case 3:switch(h){case 102:case 112:return u.current.insert(i[0]+t),"";default:return t+(0===p?a:"")}case-2:t.split(l).forEach(c)}};function d(e,t,i){var r="";return i.split(" ").forEach(function(i){void 0!==e[i]?t.push(e[i]):r+=i+" "}),r}var p=function(e,t,i){var r=e.key+"-"+t.name;if(!1===i&&void 0===e.registered[r]&&(e.registered[r]=t.styles),void 0===e.inserted[t.name]){var n=t;do{e.insert("."+r,n,e.sheet,!0),n=n.next}while(void 0!==n)}};const g=function(e){for(var t,i=0,r=0,n=e.length;n>=4;++r,n-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),i=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(n){case 3:i^=(255&e.charCodeAt(r+2))<<16;case 2:i^=(255&e.charCodeAt(r+1))<<8;case 1:i=1540483477*(65535&(i^=255&e.charCodeAt(r)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)};var f,m=i(55355),v=/[A-Z]|^ms/g,C=/_EMO_([^_]+?)_([^]*?)_EMO_/g,y=function(e){return 45===e.charCodeAt(1)},w=function(e){return null!=e&&"boolean"!=typeof e},S=(f={},function(e){return void 0===f[e]&&(f[e]=y(t=e)?t:t.replace(v,"-$&").toLowerCase()),f[e];var t}),b=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(C,function(e,t,i){return A={name:t,styles:i,next:A},t})}return 1===m.A[e]||y(e)||"number"!=typeof t||0===t?t:t+"px"};function E(e,t,i,r){if(null==i)return"";if(void 0!==i.__emotion_styles)return i;switch(typeof i){case"boolean":return"";case"object":if(1===i.anim)return A={name:i.name,styles:i.styles,next:A},i.name;if(void 0!==i.styles){var n=i.next;if(void 0!==n)for(;void 0!==n;)A={name:n.name,styles:n.styles,next:A},n=n.next;return i.styles+";"}return function(e,t,i){var r="";if(Array.isArray(i))for(var n=0;n<i.length;n++)r+=E(e,t,i[n],!1);else for(var s in i){var o=i[s];if("object"!=typeof o)null!=t&&void 0!==t[o]?r+=s+"{"+t[o]+"}":w(o)&&(r+=S(s)+":"+b(s,o)+";");else if(!Array.isArray(o)||"string"!=typeof o[0]||null!=t&&void 0!==t[o[0]]){var a=E(e,t,o,!1);switch(s){case"animation":case"animationName":r+=S(s)+":"+a+";";break;default:r+=s+"{"+a+"}"}}else for(var l=0;l<o.length;l++)w(o[l])&&(r+=S(s)+":"+b(s,o[l])+";")}return r}(e,t,i);case"function":if(void 0!==e){var s=A,o=i(e);return A=s,E(e,t,o,r)}}if(null==t)return i;var a=t[i];return void 0===a||r?i:a}var A,T=/label:\s*([^\s;\n{]+)\s*;/g,M=function(e,t,i){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,n="";A=void 0;var s=e[0];null==s||void 0===s.raw?(r=!1,n+=E(i,t,s,!1)):n+=s[0];for(var o=1;o<e.length;o++)n+=E(i,t,e[o],46===n.charCodeAt(n.length-1)),r&&(n+=s[o]);T.lastIndex=0;for(var a,l="";null!==(a=T.exec(n));)l+="-"+a[1];return{name:g(n)+l,styles:n,next:A}},R=Object.prototype.hasOwnProperty,_=(0,n.createContext)("undefined"!=typeof HTMLElement?function(e){void 0===e&&(e={});var t,i=e.key||"css";void 0!==e.prefix&&(t={prefix:e.prefix});var r,n=new o.A(t),a={};r=e.container||document.head;var l,c=document.querySelectorAll("style[data-emotion-"+i+"]");Array.prototype.forEach.call(c,function(e){e.getAttribute("data-emotion-"+i).split(" ").forEach(function(e){a[e]=!0}),e.parentNode!==r&&r.appendChild(e)}),n.use(e.stylisPlugins)(h),l=function(e,t,i,r){var s=t.name;u.current=i,n(e,t.styles),r&&(d.inserted[s]=!0)};var d={key:i,sheet:new s({key:i,container:r,nonce:e.nonce,speedy:e.speedy}),nonce:e.nonce,inserted:a,registered:{},insert:l};return d}():null),P=(0,n.createContext)({}),x=_.Provider,D=function(e){var t=function(t,i){return(0,n.createElement)(_.Consumer,null,function(r){return e(t,r,i)})};return(0,n.forwardRef)(t)},I="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",L=function(){return null},N=function(e,t,i,r){var s=null===i?t.css:t.css(i);"string"==typeof s&&void 0!==e.registered[s]&&(s=e.registered[s]);var o=t[I],a=[s],l="";"string"==typeof t.className?l=d(e.registered,a,t.className):null!=t.className&&(l=t.className+" ");var c=M(a);p(e,c,"string"==typeof o),l+=e.key+"-"+c.name;var u={};for(var h in t)R.call(t,h)&&"css"!==h&&h!==I&&(u[h]=t[h]);u.ref=r,u.className=l;var g=(0,n.createElement)(o,u),f=(0,n.createElement)(L,null);return(0,n.createElement)(n.Fragment,null,f,g)},O=D(function(e,t,i){return"function"==typeof e.css?(0,n.createElement)(P.Consumer,null,function(r){return N(t,e,r,i)}):N(t,e,null,i)});const F=function(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return M(t)};var k=function(e,t){var i=arguments;if(null==t||!R.call(t,"css"))return n.createElement.apply(void 0,i);var r=i.length,s=new Array(r);s[0]=O,s[1]=function(e,t){var i={};for(var r in t)R.call(t,r)&&(i[r]=t[r]);return i[I]=e,i}(e,t);for(var o=2;o<r;o++)s[o]=i[o];return n.createElement.apply(null,s)},G=D(function(e,t){var i=e.styles;if("function"==typeof i)return(0,n.createElement)(P.Consumer,null,function(e){var r=M([i(e)]);return(0,n.createElement)(V,{serialized:r,cache:t})});var r=M([i]);return(0,n.createElement)(V,{serialized:r,cache:t})}),V=function(e){function t(t,i,r){return e.call(this,t,i,r)||this}(0,r.A)(t,e);var i=t.prototype;return i.componentDidMount=function(){this.sheet=new s({key:this.props.cache.key+"-global",nonce:this.props.cache.sheet.nonce,container:this.props.cache.sheet.container});var e=document.querySelector("style[data-emotion-"+this.props.cache.key+'="'+this.props.serialized.name+'"]');null!==e&&this.sheet.tags.push(e),this.props.cache.sheet.tags.length&&(this.sheet.before=this.props.cache.sheet.tags[0]),this.insertStyles()},i.componentDidUpdate=function(e){e.serialized.name!==this.props.serialized.name&&this.insertStyles()},i.insertStyles=function(){if(void 0!==this.props.serialized.next&&p(this.props.cache,this.props.serialized.next,!0),this.sheet.tags.length){var e=this.sheet.tags[this.sheet.tags.length-1].nextElementSibling;this.sheet.before=e,this.sheet.flush()}this.props.cache.insert("",this.props.serialized,this.sheet,!1)},i.componentWillUnmount=function(){this.sheet.flush()},i.render=function(){return null},t}(n.Component),H=function(){var e=F.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}},B=function e(t){for(var i=t.length,r=0,n="";r<i;r++){var s=t[r];if(null!=s){var o=void 0;switch(typeof s){case"boolean":break;case"object":if(Array.isArray(s))o=e(s);else for(var a in o="",s)s[a]&&a&&(o&&(o+=" "),o+=a);break;default:o=s}o&&(n&&(n+=" "),n+=o)}}return n},z=function(){return null},U=D(function(e,t){return(0,n.createElement)(P.Consumer,null,function(i){var r=function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];var n=M(i,t.registered);return p(t,n,!1),t.key+"-"+n.name},s={css:r,cx:function(){for(var e=arguments.length,i=new Array(e),n=0;n<e;n++)i[n]=arguments[n];return function(e,t,i){var r=[],n=d(e,r,i);return r.length<2?i:n+t(r)}(t.registered,r,B(i))},theme:i},o=e.children(s),a=(0,n.createElement)(z,null);return(0,n.createElement)(n.Fragment,null,a,o)})})},99302(e,t,i){"use strict";i.d(t,{A:()=>s});var r=i(78371),n=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,s=(0,r.A)(function(e){return n.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})},78371(e,t,i){"use strict";function r(e){var t=Object.create(null);return function(i){return void 0===t[i]&&(t[i]=e(i)),t[i]}}i.d(t,{A:()=>r})},95803(e,t,i){"use strict";i.d(t,{C:()=>g,E:()=>M,T:()=>v,_:()=>f,a:()=>w,b:()=>S,c:()=>A,h:()=>b,i:()=>d,u:()=>C,w:()=>m});var r=i(22155),n=i(41487),s=i(69932),o=function(e){var t=new WeakMap;return function(i){if(t.has(i))return t.get(i);var r=e(i);return t.set(i,r),r}},a=i(4674),l=i.n(a),c=i(60966),u=i(22855),h=i(82504),d=!1,p=r.createContext("undefined"!=typeof HTMLElement?(0,n.default)({key:"css"}):null),g=p.Provider,f=function(){return(0,r.useContext)(p)},m=function(e){return(0,r.forwardRef)(function(t,i){var n=(0,r.useContext)(p);return e(t,n,i)})},v=r.createContext({}),C=function(){return r.useContext(v)},y=o(function(e){return o(function(t){return function(e,t){return"function"==typeof t?t(e):(0,s.A)({},e,t)}(e,t)})}),w=function(e){var t=r.useContext(v);return e.theme!==t&&(t=y(t)(e.theme)),r.createElement(v.Provider,{value:t},e.children)};function S(e){var t,i,n=e.displayName||e.name||"Component",o=r.forwardRef(function(t,i){var n=r.useContext(v);return r.createElement(e,(0,s.A)({theme:n,ref:i},t))});return o.displayName="WithTheme("+n+")",t=o,i=e,l()(t,i)}var b={}.hasOwnProperty,E="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",A=function(e,t){var i={};for(var r in t)b.call(t,r)&&(i[r]=t[r]);return i[E]=e,i},T=function(e){var t=e.cache,i=e.serialized,r=e.isStringTag;return(0,c.SF)(t,i,r),(0,h.s)(function(){return(0,c.sk)(t,i,r)}),null},M=m(function(e,t,i){var n=e.css;"string"==typeof n&&void 0!==t.registered[n]&&(n=t.registered[n]);var s=e[E],o=[n],a="";"string"==typeof e.className?a=(0,c.Rk)(t.registered,o,e.className):null!=e.className&&(a=e.className+" ");var l=(0,u.serializeStyles)(o,void 0,r.useContext(v));a+=t.key+"-"+l.name;var h={};for(var p in e)b.call(e,p)&&"css"!==p&&p!==E&&!d&&(h[p]=e[p]);return h.className=a,i&&(h.ref=i),r.createElement(r.Fragment,null,r.createElement(T,{cache:t,serialized:l,isStringTag:"string"==typeof s}),r.createElement(s,h))})},95349(e,t,i){"use strict";i.r(t),i.d(t,{CacheProvider:()=>s.C,ClassNames:()=>m,Global:()=>h,ThemeContext:()=>s.T,ThemeProvider:()=>s.a,__unsafe_useEmotionCache:()=>s._,createElement:()=>u,css:()=>d,jsx:()=>u,keyframes:()=>p,useTheme:()=>s.u,withEmotionCache:()=>s.w,withTheme:()=>s.b});var r,n,s=i(95803),o=i(22155),a=i(60966),l=i(82504),c=i(22855),u=(i(41487),i(4674),function(e,t){var i=arguments;if(null==t||!s.h.call(t,"css"))return o.createElement.apply(void 0,i);var r=i.length,n=new Array(r);n[0]=s.E,n[1]=(0,s.c)(e,t);for(var a=2;a<r;a++)n[a]=i[a];return o.createElement.apply(null,n)});r=u||(u={}),n||(n=r.JSX||(r.JSX={}));var h=(0,s.w)(function(e,t){var i=e.styles,r=(0,c.serializeStyles)([i],void 0,o.useContext(s.T)),n=o.useRef();return(0,l.i)(function(){var e=t.key+"-global",i=new t.sheet.constructor({key:e,nonce:t.sheet.nonce,container:t.sheet.container,speedy:t.sheet.isSpeedy}),s=!1,o=document.querySelector('style[data-emotion="'+e+" "+r.name+'"]');return t.sheet.tags.length&&(i.before=t.sheet.tags[0]),null!==o&&(s=!0,o.setAttribute("data-emotion",e),i.hydrate([o])),n.current=[i,s],function(){i.flush()}},[t]),(0,l.i)(function(){var e=n.current,i=e[0];if(e[1])e[1]=!1;else{if(void 0!==r.next&&(0,a.sk)(t,r.next,!0),i.tags.length){var s=i.tags[i.tags.length-1].nextElementSibling;i.before=s,i.flush()}t.insert("",r,i,!1)}},[t,r.name]),null});function d(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];return(0,c.serializeStyles)(t)}function p(){var e=d.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}var g=function e(t){for(var i=t.length,r=0,n="";r<i;r++){var s=t[r];if(null!=s){var o=void 0;switch(typeof s){case"boolean":break;case"object":if(Array.isArray(s))o=e(s);else for(var a in o="",s)s[a]&&a&&(o&&(o+=" "),o+=a);break;default:o=s}o&&(n&&(n+=" "),n+=o)}}return n},f=function(e){var t=e.cache,i=e.serializedArr;return(0,l.s)(function(){for(var e=0;e<i.length;e++)(0,a.sk)(t,i[e],!1)}),null},m=(0,s.w)(function(e,t){var i=!1,r=[],n=function(){if(i&&s.i)throw new Error("css can only be used during render");for(var e=arguments.length,n=new Array(e),o=0;o<e;o++)n[o]=arguments[o];var l=(0,c.serializeStyles)(n,t.registered);return r.push(l),(0,a.SF)(t,l,!1),t.key+"-"+l.name},l={css:n,cx:function(){if(i&&s.i)throw new Error("cx can only be used during render");for(var e=arguments.length,r=new Array(e),o=0;o<e;o++)r[o]=arguments[o];return function(e,t,i){var r=[],n=(0,a.Rk)(e,r,i);return r.length<2?i:n+t(r)}(t.registered,n,g(r))},theme:o.useContext(s.T)},u=e.children(l);return i=!0,o.createElement(o.Fragment,null,o.createElement(f,{cache:t,serializedArr:r}),u)})},22855(e,t,i){"use strict";i.r(t),i.d(t,{serializeStyles:()=>g});var r={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},n=i(78371),s=/[A-Z]|^ms/g,o=/_EMO_([^_]+?)_([^]*?)_EMO_/g,a=function(e){return 45===e.charCodeAt(1)},l=function(e){return null!=e&&"boolean"!=typeof e},c=(0,n.A)(function(e){return a(e)?e:e.replace(s,"-$&").toLowerCase()}),u=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(o,function(e,t,i){return d={name:t,styles:i,next:d},t})}return 1===r[e]||a(e)||"number"!=typeof t||0===t?t:t+"px"};function h(e,t,i){if(null==i)return"";var r=i;if(void 0!==r.__emotion_styles)return r;switch(typeof i){case"boolean":return"";case"object":var n=i;if(1===n.anim)return d={name:n.name,styles:n.styles,next:d},n.name;var s=i;if(void 0!==s.styles){var o=s.next;if(void 0!==o)for(;void 0!==o;)d={name:o.name,styles:o.styles,next:d},o=o.next;return s.styles+";"}return function(e,t,i){var r="";if(Array.isArray(i))for(var n=0;n<i.length;n++)r+=h(e,t,i[n])+";";else for(var s in i){var o=i[s];if("object"!=typeof o){var a=o;null!=t&&void 0!==t[a]?r+=s+"{"+t[a]+"}":l(a)&&(r+=c(s)+":"+u(s,a)+";")}else if(!Array.isArray(o)||"string"!=typeof o[0]||null!=t&&void 0!==t[o[0]]){var d=h(e,t,o);switch(s){case"animation":case"animationName":r+=c(s)+":"+d+";";break;default:r+=s+"{"+d+"}"}}else for(var p=0;p<o.length;p++)l(o[p])&&(r+=c(s)+":"+u(s,o[p])+";")}return r}(e,t,i);case"function":if(void 0!==e){var a=d,p=i(e);return d=a,h(e,t,p)}}var g=i;if(null==t)return g;var f=t[g];return void 0!==f?f:g}var d,p=/label:\s*([^\s;{]+)\s*(;|$)/g;function g(e,t,i){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,n="";d=void 0;var s=e[0];null==s||void 0===s.raw?(r=!1,n+=h(i,t,s)):n+=s[0];for(var o=1;o<e.length;o++)n+=h(i,t,e[o]),r&&(n+=s[o]);p.lastIndex=0;for(var a,l="";null!==(a=p.exec(n));)l+="-"+a[1];var c=function(e){for(var t,i=0,r=0,n=e.length;n>=4;++r,n-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),i=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&i)+(59797*(i>>>16)<<16);switch(n){case 3:i^=(255&e.charCodeAt(r+2))<<16;case 2:i^=(255&e.charCodeAt(r+1))<<8;case 1:i=1540483477*(65535&(i^=255&e.charCodeAt(r)))+(59797*(i>>>16)<<16)}return(((i=1540483477*(65535&(i^=i>>>13))+(59797*(i>>>16)<<16))^i>>>15)>>>0).toString(36)}(n)+l;return{name:c,styles:n,next:d}}},8900(e,t,i){"use strict";i.r(t),i.d(t,{StyleSheet:()=>r});var r=function(){function e(e){var t=this;this._insertTag=function(e){var i;i=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,i),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var i=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{i.insertRule(e,i.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach(function(e){var t;return null==(t=e.parentNode)?void 0:t.removeChild(e)}),this.tags=[],this.ctr=0},e}()},41786(e,t,i){"use strict";i.r(t),i.d(t,{default:()=>g});var r=i(69932),n=i(95803),s=i(22855),o=i(82504),a=i(60966),l=i(22155),c=i(99302).A,u=function(e){return"theme"!==e},h=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?c:u},d=function(e,t,i){var r;if(t){var n=t.shouldForwardProp;r=e.__emotion_forwardProp&&n?function(t){return e.__emotion_forwardProp(t)&&n(t)}:n}return"function"!=typeof r&&i&&(r=e.__emotion_forwardProp),r},p=function(e){var t=e.cache,i=e.serialized,r=e.isStringTag;return(0,a.SF)(t,i,r),(0,o.s)(function(){return(0,a.sk)(t,i,r)}),null},g=function e(t,i){var o,c,u=t.__emotion_real===t,g=u&&t.__emotion_base||t;void 0!==i&&(o=i.label,c=i.target);var f=d(t,i,u),m=f||h(g),v=!m("as");return function(){var C=arguments,y=u&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==o&&y.push("label:"+o+";"),null==C[0]||void 0===C[0].raw)y.push.apply(y,C);else{var w=C[0];y.push(w[0]);for(var S=C.length,b=1;b<S;b++)y.push(C[b],w[b])}var E=(0,n.w)(function(e,t,i){var r=v&&e.as||g,o="",u=[],d=e;if(null==e.theme){for(var C in d={},e)d[C]=e[C];d.theme=l.useContext(n.T)}"string"==typeof e.className?o=(0,a.Rk)(t.registered,u,e.className):null!=e.className&&(o=e.className+" ");var w=(0,s.serializeStyles)(y.concat(u),t.registered,d);o+=t.key+"-"+w.name,void 0!==c&&(o+=" "+c);var S=v&&void 0===f?h(r):m,b={};for(var E in e)v&&"as"===E||S(E)&&(b[E]=e[E]);return b.className=o,i&&(b.ref=i),l.createElement(l.Fragment,null,l.createElement(p,{cache:t,serialized:w,isStringTag:"string"==typeof r}),l.createElement(r,b))});return E.displayName=void 0!==o?o:"Styled("+("string"==typeof g?g:g.displayName||g.name||"Component")+")",E.defaultProps=t.defaultProps,E.__emotion_real=E,E.__emotion_base=g,E.__emotion_styles=y,E.__emotion_forwardProp=f,Object.defineProperty(E,"toString",{value:function(){return"."+c}}),E.withComponent=function(t,n){return e(t,(0,r.A)({},i,n,{shouldForwardProp:d(E,n,!0)})).apply(void 0,y)},E}}.bind(null);["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"].forEach(function(e){g[e]=g(e)})},27903(e,t,i){"use strict";i.d(t,{A:()=>r});const r=function(e){function t(e,r,l,c,d){for(var p,g,f,m,w,b=0,E=0,A=0,T=0,M=0,I=0,N=f=p=0,F=0,k=0,G=0,V=0,H=l.length,B=H-1,z="",U="",W="",j="";F<H;){if(g=l.charCodeAt(F),F===B&&0!==E+T+A+b&&(0!==E&&(g=47===E?10:47),T=A=b=0,H++,B++),0===E+T+A+b){if(F===B&&(0<k&&(z=z.replace(h,"")),0<z.trim().length)){switch(g){case 32:case 9:case 59:case 13:case 10:break;default:z+=l.charAt(F)}g=59}switch(g){case 123:for(p=(z=z.trim()).charCodeAt(0),f=1,V=++F;F<H;){switch(g=l.charCodeAt(F)){case 123:f++;break;case 125:f--;break;case 47:switch(g=l.charCodeAt(F+1)){case 42:case 47:e:{for(N=F+1;N<B;++N)switch(l.charCodeAt(N)){case 47:if(42===g&&42===l.charCodeAt(N-1)&&F+2!==N){F=N+1;break e}break;case 10:if(47===g){F=N+1;break e}}F=N}}break;case 91:g++;case 40:g++;case 34:case 39:for(;F++<B&&l.charCodeAt(F)!==g;);}if(0===f)break;F++}if(f=l.substring(V,F),0===p&&(p=(z=z.replace(u,"").trim()).charCodeAt(0)),64===p){switch(0<k&&(z=z.replace(h,"")),g=z.charCodeAt(1)){case 100:case 109:case 115:case 45:k=r;break;default:k=D}if(V=(f=t(r,k,f,g,d+1)).length,0<L&&(w=a(3,f,k=i(D,z,G),r,_,R,V,g,d,c),z=k.join(""),void 0!==w&&0===(V=(f=w.trim()).length)&&(g=0,f="")),0<V)switch(g){case 115:z=z.replace(S,o);case 100:case 109:case 45:f=z+"{"+f+"}";break;case 107:f=(z=z.replace(v,"$1 $2"))+"{"+f+"}",f=1===x||2===x&&s("@"+f,3)?"@-webkit-"+f+"@"+f:"@"+f;break;default:f=z+f,112===c&&(U+=f,f="")}else f=""}else f=t(r,i(r,z,G),f,c,d+1);W+=f,f=G=k=N=p=0,z="",g=l.charCodeAt(++F);break;case 125:case 59:if(1<(V=(z=(0<k?z.replace(h,""):z).trim()).length))switch(0===N&&(p=z.charCodeAt(0),45===p||96<p&&123>p)&&(V=(z=z.replace(" ",":")).length),0<L&&void 0!==(w=a(1,z,r,e,_,R,U.length,c,d,c))&&0===(V=(z=w.trim()).length)&&(z="\0\0"),p=z.charCodeAt(0),g=z.charCodeAt(1),p){case 0:break;case 64:if(105===g||99===g){j+=z+l.charAt(F);break}default:58!==z.charCodeAt(V-1)&&(U+=n(z,p,g,z.charCodeAt(2)))}G=k=N=p=0,z="",g=l.charCodeAt(++F)}}switch(g){case 13:case 10:47===E?E=0:0===1+p&&107!==c&&0<z.length&&(k=1,z+="\0"),0<L*O&&a(0,z,r,e,_,R,U.length,c,d,c),R=1,_++;break;case 59:case 125:if(0===E+T+A+b){R++;break}default:switch(R++,m=l.charAt(F),g){case 9:case 32:if(0===T+b+E)switch(M){case 44:case 58:case 9:case 32:m="";break;default:32!==g&&(m=" ")}break;case 0:m="\\0";break;case 12:m="\\f";break;case 11:m="\\v";break;case 38:0===T+E+b&&(k=G=1,m="\f"+m);break;case 108:if(0===T+E+b+P&&0<N)switch(F-N){case 2:112===M&&58===l.charCodeAt(F-3)&&(P=M);case 8:111===I&&(P=I)}break;case 58:0===T+E+b&&(N=F);break;case 44:0===E+A+T+b&&(k=1,m+="\r");break;case 34:case 39:0===E&&(T=T===g?0:0===T?g:T);break;case 91:0===T+E+A&&b++;break;case 93:0===T+E+A&&b--;break;case 41:0===T+E+b&&A--;break;case 40:0===T+E+b&&(0===p&&(2*M+3*I==533||(p=1)),A++);break;case 64:0===E+A+T+b+N+f&&(f=1);break;case 42:case 47:if(!(0<T+b+A))switch(E){case 0:switch(2*g+3*l.charCodeAt(F+1)){case 235:E=47;break;case 220:V=F,E=42}break;case 42:47===g&&42===M&&V+2!==F&&(33===l.charCodeAt(V+2)&&(U+=l.substring(V,F+1)),m="",E=0)}}0===E&&(z+=m)}I=M,M=g,F++}if(0<(V=U.length)){if(k=r,0<L&&void 0!==(w=a(2,U,k,e,_,R,V,c,d,c))&&0===(U=w).length)return j+U+W;if(U=k.join(",")+"{"+U+"}",0!==x*P){switch(2!==x||s(U,2)||(P=0),P){case 111:U=U.replace(y,":-moz-$1")+U;break;case 112:U=U.replace(C,"::-webkit-input-$1")+U.replace(C,"::-moz-$1")+U.replace(C,":-ms-input-$1")+U}P=0}}return j+U+W}function i(e,t,i){var n=t.trim().split(f);t=n;var s=n.length,o=e.length;switch(o){case 0:case 1:var a=0;for(e=0===o?"":e[0]+" ";a<s;++a)t[a]=r(e,t[a],i).trim();break;default:var l=a=0;for(t=[];a<s;++a)for(var c=0;c<o;++c)t[l++]=r(e[c]+" ",n[a],i).trim()}return t}function r(e,t,i){var r=t.charCodeAt(0);switch(33>r&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*i&&0<t.indexOf("\f"))return t.replace(m,(58===e.charCodeAt(0)?"":"$1")+e.trim())}return e+t}function n(e,t,i,r){var o=e+";",a=2*t+3*i+4*r;if(944===a){e=o.indexOf(":",9)+1;var l=o.substring(e,o.length-1).trim();return l=o.substring(0,e).trim()+l+";",1===x||2===x&&s(l,1)?"-webkit-"+l+l:l}if(0===x||2===x&&!s(o,1))return o;switch(a){case 1015:return 97===o.charCodeAt(10)?"-webkit-"+o+o:o;case 951:return 116===o.charCodeAt(3)?"-webkit-"+o+o:o;case 963:return 110===o.charCodeAt(5)?"-webkit-"+o+o:o;case 1009:if(100!==o.charCodeAt(4))break;case 969:case 942:return"-webkit-"+o+o;case 978:return"-webkit-"+o+"-moz-"+o+o;case 1019:case 983:return"-webkit-"+o+"-moz-"+o+"-ms-"+o+o;case 883:if(45===o.charCodeAt(8))return"-webkit-"+o+o;if(0<o.indexOf("image-set(",11))return o.replace(M,"$1-webkit-$2")+o;break;case 932:if(45===o.charCodeAt(4))switch(o.charCodeAt(5)){case 103:return"-webkit-box-"+o.replace("-grow","")+"-webkit-"+o+"-ms-"+o.replace("grow","positive")+o;case 115:return"-webkit-"+o+"-ms-"+o.replace("shrink","negative")+o;case 98:return"-webkit-"+o+"-ms-"+o.replace("basis","preferred-size")+o}return"-webkit-"+o+"-ms-"+o+o;case 964:return"-webkit-"+o+"-ms-flex-"+o+o;case 1023:if(99!==o.charCodeAt(8))break;return"-webkit-box-pack"+(l=o.substring(o.indexOf(":",15)).replace("flex-","").replace("space-between","justify"))+"-webkit-"+o+"-ms-flex-pack"+l+o;case 1005:return p.test(o)?o.replace(d,":-webkit-")+o.replace(d,":-moz-")+o:o;case 1e3:switch(t=(l=o.substring(13).trim()).indexOf("-")+1,l.charCodeAt(0)+l.charCodeAt(t)){case 226:l=o.replace(w,"tb");break;case 232:l=o.replace(w,"tb-rl");break;case 220:l=o.replace(w,"lr");break;default:return o}return"-webkit-"+o+"-ms-"+l+o;case 1017:if(-1===o.indexOf("sticky",9))break;case 975:switch(t=(o=e).length-10,a=(l=(33===o.charCodeAt(t)?o.substring(0,t):o).substring(e.indexOf(":",7)+1).trim()).charCodeAt(0)+(0|l.charCodeAt(7))){case 203:if(111>l.charCodeAt(8))break;case 115:o=o.replace(l,"-webkit-"+l)+";"+o;break;case 207:case 102:o=o.replace(l,"-webkit-"+(102<a?"inline-":"")+"box")+";"+o.replace(l,"-webkit-"+l)+";"+o.replace(l,"-ms-"+l+"box")+";"+o}return o+";";case 938:if(45===o.charCodeAt(5))switch(o.charCodeAt(6)){case 105:return l=o.replace("-items",""),"-webkit-"+o+"-webkit-box-"+l+"-ms-flex-"+l+o;case 115:return"-webkit-"+o+"-ms-flex-item-"+o.replace(E,"")+o;default:return"-webkit-"+o+"-ms-flex-line-pack"+o.replace("align-content","").replace(E,"")+o}break;case 973:case 989:if(45!==o.charCodeAt(3)||122===o.charCodeAt(4))break;case 931:case 953:if(!0===T.test(e))return 115===(l=e.substring(e.indexOf(":")+1)).charCodeAt(0)?n(e.replace("stretch","fill-available"),t,i,r).replace(":fill-available",":stretch"):o.replace(l,"-webkit-"+l)+o.replace(l,"-moz-"+l.replace("fill-",""))+o;break;case 962:if(o="-webkit-"+o+(102===o.charCodeAt(5)?"-ms-"+o:"")+o,211===i+r&&105===o.charCodeAt(13)&&0<o.indexOf("transform",10))return o.substring(0,o.indexOf(";",27)+1).replace(g,"$1-webkit-$2")+o}return o}function s(e,t){var i=e.indexOf(1===t?":":"{"),r=e.substring(0,3!==t?i:10);return i=e.substring(i+1,e.length-1),N(2!==t?r:r.replace(A,"$1"),i,t)}function o(e,t){var i=n(t,t.charCodeAt(0),t.charCodeAt(1),t.charCodeAt(2));return i!==t+";"?i.replace(b," or ($1)").substring(4):"("+t+")"}function a(e,t,i,r,n,s,o,a,l,u){for(var h,d=0,p=t;d<L;++d)switch(h=I[d].call(c,e,p,i,r,n,s,o,a,l,u)){case void 0:case!1:case!0:case null:break;default:p=h}if(p!==t)return p}function l(e){return void 0!==(e=e.prefix)&&(N=null,e?"function"!=typeof e?x=1:(x=2,N=e):x=0),l}function c(e,i){var r=e;if(33>r.charCodeAt(0)&&(r=r.trim()),r=[r],0<L){var n=a(-1,i,r,r,_,R,0,0,0,0);void 0!==n&&"string"==typeof n&&(i=n)}var s=t(D,r,i,0,0);return 0<L&&void 0!==(n=a(-2,s,r,r,_,R,s.length,0,0,0))&&(s=n),P=0,R=_=1,s}var u=/^\0+/g,h=/[\0\r\f]/g,d=/: */g,p=/zoo|gra/,g=/([,: ])(transform)/g,f=/,\r+?/g,m=/([\t\r\n ])*\f?&/g,v=/@(k\w+)\s*(\S*)\s*/,C=/::(place)/g,y=/:(read-only)/g,w=/[svh]\w+-[tblr]{2}/,S=/\(\s*(.*)\s*\)/g,b=/([\s\S]*?);/g,E=/-self|flex-/g,A=/[^]*?(:[rp][el]a[\w-]+)[^]*/,T=/stretch|:\s*\w+\-(?:conte|avail)/,M=/([^-])(image-set\()/,R=1,_=1,P=0,x=1,D=[],I=[],L=0,N=null,O=0;return c.use=function e(t){switch(t){case void 0:case null:L=I.length=0;break;default:if("function"==typeof t)I[L++]=t;else if("object"==typeof t)for(var i=0,r=t.length;i<r;++i)e(t[i]);else O=0|!!t}return e},c.set=l,void 0!==e&&l(e),c}},55355(e,t,i){"use strict";i.d(t,{A:()=>r});const r={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1}},82504(e,t,i){"use strict";var r;i.d(t,{i:()=>a,s:()=>o});var n=i(22155),s=!!(r||(r=i.t(n,2))).useInsertionEffect&&(r||(r=i.t(n,2))).useInsertionEffect,o=s||function(e){return e()},a=s||n.useLayoutEffect},60966(e,t,i){"use strict";function r(e,t,i){var r="";return i.split(" ").forEach(function(i){void 0!==e[i]?t.push(e[i]+";"):i&&(r+=i+" ")}),r}i.d(t,{Rk:()=>r,SF:()=>n,sk:()=>s});var n=function(e,t,i){var r=e.key+"-"+t.name;!1===i&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},s=function(e,t,i){n(e,t,i);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var s=t;do{e.insert(t===s?"."+r:"",s,e.sheet,!0),s=s.next}while(void 0!==s)}}},6358(e,t,i){"use strict";i.r(t),i.d(t,{Composite:()=>De,CompositeItem:()=>Ie,FloatingArrow:()=>Ge,FloatingDelayGroup:()=>it,FloatingFocusManager:()=>It,FloatingList:()=>ve,FloatingNode:()=>je,FloatingOverlay:()=>Ft,FloatingPortal:()=>At,FloatingTree:()=>Ke,NextFloatingDelayGroup:()=>st,arrow:()=>pe,autoPlacement:()=>ue,autoUpdate:()=>J.ll,computePosition:()=>J.rD,detectOverflow:()=>J.__,flip:()=>le,getOverflowAncestors:()=>s.v9,hide:()=>he,inline:()=>de,inner:()=>di,limitShift:()=>ae,offset:()=>se,platform:()=>J.iD,safePolygon:()=>mi,shift:()=>oe,size:()=>ce,useClick:()=>Vt,useClientPoint:()=>Bt,useDelayGroup:()=>rt,useDelayGroupContext:()=>tt,useDismiss:()=>jt,useFloating:()=>$t,useFloatingNodeId:()=>We,useFloatingParentNodeId:()=>ze,useFloatingPortalNode:()=>Et,useFloatingRootContext:()=>Kt,useFloatingTree:()=>Ue,useFocus:()=>Yt,useHover:()=>Ze,useId:()=>ke,useInnerOffset:()=>pi,useInteractions:()=>Xt,useListItem:()=>Ce,useListNavigation:()=>ri,useMergeRefs:()=>ge,useNextDelayGroup:()=>ot,useRole:()=>si,useTransitionStatus:()=>li,useTransitionStyles:()=>ci,useTypeahead:()=>ui});var r=i(22155),n=i.t(r,2),s=i(32125),o=i(51771),a=i(86668);function l(){const e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}function c(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(e=>{let{brand:t,version:i}=e;return t+"/"+i}).join(" "):navigator.userAgent}function u(){return/apple/i.test(navigator.vendor)}function h(){const e=/android/i;return e.test(l())||e.test(c())}function d(){return c().includes("jsdom/")}const p="data-floating-ui-focusable",g="ArrowLeft",f="ArrowRight";function m(e){let t=e.activeElement;for(;null!=(null==(i=t)||null==(i=i.shadowRoot)?void 0:i.activeElement);){var i;t=t.shadowRoot.activeElement}return t}function v(e,t){if(!e||!t)return!1;const i=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(i&&(0,s.Ng)(i)){let i=t;for(;i;){if(e===i)return!0;i=i.parentNode||i.host}}return!1}function C(e){return"composedPath"in e?e.composedPath()[0]:e.target}function y(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const i=e;return null!=i.target&&t.contains(i.target)}function w(e){return(null==e?void 0:e.ownerDocument)||document}function S(e){return(0,s.sb)(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}function b(e){return!!e&&"combobox"===e.getAttribute("role")&&S(e)}function E(e){return e?e.hasAttribute(p)?e:e.querySelector("["+p+"]")||e:null}function A(e,t,i){return void 0===i&&(i=!0),e.filter(e=>{var r;return e.parentId===t&&(!i||(null==(r=e.context)?void 0:r.open))}).flatMap(t=>[t,...A(e,t.id,i)])}function T(e,t){var i;let r=[],n=null==(i=e.find(e=>e.id===t))?void 0:i.parentId;for(;n;){const t=e.find(e=>e.id===n);n=null==t?void 0:t.parentId,t&&(r=r.concat(t))}return r}function M(e){e.preventDefault(),e.stopPropagation()}function R(e){return!(0!==e.mozInputSource||!e.isTrusted)||(h()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)}function _(e){return!d()&&(!h()&&0===e.width&&0===e.height||h()&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)}function P(e,t){const i=["mouse","pen"];return t||i.push("",void 0),i.includes(e)}var x="undefined"!=typeof document?r.useLayoutEffect:function(){};function D(e){const t=r.useRef(e);return x(()=>{t.current=e}),t}const I={...n}.useInsertionEffect||(e=>e());function L(e){const t=r.useRef(()=>{});return I(()=>{t.current=e}),r.useCallback(function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];return null==t.current?void 0:t.current(...i)},[])}function N(e,t,i){return Math.floor(e/t)!==i}function O(e,t){return t<0||t>=e.current.length}function F(e,t){return G(e,{disabledIndices:t})}function k(e,t){return G(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function G(e,t){let{startingIndex:i=-1,decrement:r=!1,disabledIndices:n,amount:s=1}=void 0===t?{}:t,o=i;do{o+=r?-s:s}while(o>=0&&o<=e.current.length-1&&U(e,o,n));return o}function V(e,t){let{event:i,orientation:r,loop:n,rtl:s,cols:a,disabledIndices:l,minIndex:c,maxIndex:u,prevIndex:h,stopEvent:d=!1}=t,p=h;if("ArrowUp"===i.key){if(d&&M(i),-1===h)p=u;else if(p=G(e,{startingIndex:p,amount:a,decrement:!0,disabledIndices:l}),n&&(h-a<c||p<0)){const e=h%a,t=u%a,i=u-(t-e);p=t===e?u:t>e?i:i-a}O(e,p)&&(p=h)}if("ArrowDown"===i.key&&(d&&M(i),-1===h?p=c:(p=G(e,{startingIndex:h,amount:a,disabledIndices:l}),n&&h+a>u&&(p=G(e,{startingIndex:h%a-a,amount:a,disabledIndices:l}))),O(e,p)&&(p=h)),"both"===r){const t=(0,o.RI)(h/a);i.key===(s?g:f)&&(d&&M(i),h%a!==a-1?(p=G(e,{startingIndex:h,disabledIndices:l}),n&&N(p,a,t)&&(p=G(e,{startingIndex:h-h%a-1,disabledIndices:l}))):n&&(p=G(e,{startingIndex:h-h%a-1,disabledIndices:l})),N(p,a,t)&&(p=h)),i.key===(s?f:g)&&(d&&M(i),h%a!==0?(p=G(e,{startingIndex:h,decrement:!0,disabledIndices:l}),n&&N(p,a,t)&&(p=G(e,{startingIndex:h+(a-h%a),decrement:!0,disabledIndices:l}))):n&&(p=G(e,{startingIndex:h+(a-h%a),decrement:!0,disabledIndices:l})),N(p,a,t)&&(p=h));const r=(0,o.RI)(u/a)===t;O(e,p)&&(p=n&&r?i.key===(s?f:g)?u:G(e,{startingIndex:h-h%a-1,disabledIndices:l}):h)}return p}function H(e,t,i){const r=[];let n=0;return e.forEach((e,s)=>{let{width:o,height:a}=e,l=!1;for(i&&(n=0);!l;){const e=[];for(let i=0;i<o;i++)for(let r=0;r<a;r++)e.push(n+i+r*t);n%t+o<=t&&e.every(e=>null==r[e])?(e.forEach(e=>{r[e]=s}),l=!0):n++}}),[...r]}function B(e,t,i,r,n){if(-1===e)return-1;const s=i.indexOf(e),o=t[e];switch(n){case"tl":return s;case"tr":return o?s+o.width-1:s;case"bl":return o?s+(o.height-1)*r:s;case"br":return i.lastIndexOf(e)}}function z(e,t){return t.flatMap((t,i)=>e.includes(t)?[i]:[])}function U(e,t,i){if("function"==typeof i)return i(t);if(i)return i.includes(t);const r=e.current[t];return null==r||r.hasAttribute("disabled")||"true"===r.getAttribute("aria-disabled")}const W=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function j(e,t){const i=(0,a.Kr)(e,W()),r=i.length;if(0===r)return;const n=m(w(e)),s=i.indexOf(n);return i[-1===s?1===t?0:r-1:s+t]}function K(e){return j(w(e).body,1)||e}function $(e){return j(w(e).body,-1)||e}function q(e,t){const i=t||e.currentTarget,r=e.relatedTarget;return!r||!v(i,r)}function Y(e){(0,a.Kr)(e,W()).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})}function Q(e){e.querySelectorAll("[data-tabindex]").forEach(e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})}var X=i(65723),Z=i(70316),J=i(4830),ee="undefined"!=typeof document?r.useLayoutEffect:function(){};function te(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if("function"==typeof e&&e.toString()===t.toString())return!0;let i,r,n;if(e&&t&&"object"==typeof e){if(Array.isArray(e)){if(i=e.length,i!==t.length)return!1;for(r=i;0!==r--;)if(!te(e[r],t[r]))return!1;return!0}if(n=Object.keys(e),i=n.length,i!==Object.keys(t).length)return!1;for(r=i;0!==r--;)if(!{}.hasOwnProperty.call(t,n[r]))return!1;for(r=i;0!==r--;){const i=n[r];if(!("_owner"===i&&e.$$typeof||te(e[i],t[i])))return!1}return!0}return e!=e&&t!=t}function ie(e){return"undefined"==typeof window?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function re(e,t){const i=ie(e);return Math.round(t*i)/i}function ne(e){const t=r.useRef(e);return ee(()=>{t.current=e}),t}const se=(e,t)=>{const i=(0,J.cY)(e);return{name:i.name,fn:i.fn,options:[e,t]}},oe=(e,t)=>{const i=(0,J.BN)(e);return{name:i.name,fn:i.fn,options:[e,t]}},ae=(e,t)=>({fn:(0,J.ER)(e).fn,options:[e,t]}),le=(e,t)=>{const i=(0,J.UU)(e);return{name:i.name,fn:i.fn,options:[e,t]}},ce=(e,t)=>{const i=(0,J.Ej)(e);return{name:i.name,fn:i.fn,options:[e,t]}},ue=(e,t)=>{const i=(0,J.RK)(e);return{name:i.name,fn:i.fn,options:[e,t]}},he=(e,t)=>{const i=(0,J.jD)(e);return{name:i.name,fn:i.fn,options:[e,t]}},de=(e,t)=>{const i=(0,J.mG)(e);return{name:i.name,fn:i.fn,options:[e,t]}},pe=(e,t)=>{const i=(e=>({name:"arrow",options:e,fn(t){const{element:i,padding:r}="function"==typeof e?e(t):e;return i&&(n=i,{}.hasOwnProperty.call(n,"current"))?null!=i.current?(0,J.UE)({element:i.current,padding:r}).fn(t):{}:i?(0,J.UE)({element:i,padding:r}).fn(t):{};var n}}))(e);return{name:i.name,fn:i.fn,options:[e,t]}};function ge(e){const t=r.useRef(void 0),i=r.useCallback(t=>{const i=e.map(e=>{if(null!=e){if("function"==typeof e){const i=e,r=i(t);return"function"==typeof r?r:()=>{i(null)}}return e.current=t,()=>{e.current=null}}});return()=>{i.forEach(e=>null==e?void 0:e())}},e);return r.useMemo(()=>e.every(e=>null==e)?null:e=>{t.current&&(t.current(),t.current=void 0),null!=e&&(t.current=i(e))},e)}function fe(e,t){const i=e.compareDocumentPosition(t);return i&Node.DOCUMENT_POSITION_FOLLOWING||i&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:i&Node.DOCUMENT_POSITION_PRECEDING||i&Node.DOCUMENT_POSITION_CONTAINS?1:0}const me=r.createContext({register:()=>{},unregister:()=>{},map:new Map,elementsRef:{current:[]}});function ve(e){const{children:t,elementsRef:i,labelsRef:n}=e,[s,o]=r.useState(()=>new Set),a=r.useCallback(e=>{o(t=>new Set(t).add(e))},[]),l=r.useCallback(e=>{o(t=>{const i=new Set(t);return i.delete(e),i})},[]),c=r.useMemo(()=>{const e=new Map;return Array.from(s.keys()).sort(fe).forEach((t,i)=>{e.set(t,i)}),e},[s]);return(0,X.jsx)(me.Provider,{value:r.useMemo(()=>({register:a,unregister:l,map:c,elementsRef:i,labelsRef:n}),[a,l,c,i,n]),children:t})}function Ce(e){void 0===e&&(e={});const{label:t}=e,{register:i,unregister:n,map:s,elementsRef:o,labelsRef:a}=r.useContext(me),[l,c]=r.useState(null),u=r.useRef(null),h=r.useCallback(e=>{if(u.current=e,null!==l&&(o.current[l]=e,a)){var i;const r=void 0!==t;a.current[l]=r?t:null!=(i=null==e?void 0:e.textContent)?i:null}},[l,o,a,t]);return x(()=>{const e=u.current;if(e)return i(e),()=>{n(e)}},[i,n]),x(()=>{const e=u.current?s.get(u.current):null;null!=e&&c(e)},[s]),r.useMemo(()=>({ref:h,index:null==l?-1:l}),[l,h])}const ye="data-floating-ui-focusable",we="active",Se="selected",be="ArrowLeft",Ee="ArrowRight",Ae="ArrowUp",Te="ArrowDown";function Me(e,t){return"function"==typeof e?e(t):e?r.cloneElement(e,t):(0,X.jsx)("div",{...t})}const Re=r.createContext({activeIndex:0,onNavigate:()=>{}}),_e=[be,Ee],Pe=[Ae,Te],xe=[..._e,...Pe],De=r.forwardRef(function(e,t){const{render:i,orientation:n="both",loop:s=!0,rtl:o=!1,cols:a=1,disabledIndices:l,activeIndex:c,onNavigate:u,itemSizes:h,dense:d=!1,...p}=e,[g,f]=r.useState(0),m=null!=c?c:g,v=L(null!=u?u:f),C=r.useRef([]),y=i&&"function"!=typeof i?i.props:{},w=r.useMemo(()=>({activeIndex:m,onNavigate:v}),[m,v]),S=a>1,b={...p,...y,ref:t,"aria-orientation":"both"===n?void 0:n,onKeyDown(e){null==p.onKeyDown||p.onKeyDown(e),null==y.onKeyDown||y.onKeyDown(e),function(e){if(!xe.includes(e.key))return;let t=m;const i=F(C,l),r=k(C,l),c=o?be:Ee,u=o?Ee:be;if(S){const u=h||Array.from({length:C.current.length},()=>({width:1,height:1})),p=H(u,a,d),g=p.findIndex(e=>null!=e&&!U(C,e,l)),f=p.reduce((e,t,i)=>null==t||U(C,t,l)?e:i,-1),v=p[V({current:p.map(e=>e?C.current[e]:null)},{event:e,orientation:n,loop:s,rtl:o,cols:a,disabledIndices:z([...("function"!=typeof l?l:null)||C.current.map((e,t)=>U(C,t,l)?t:void 0),void 0],p),minIndex:g,maxIndex:f,prevIndex:B(m>r?i:m,u,p,a,e.key===Te?"bl":e.key===c?"tr":"tl")})];null!=v&&(t=v)}const p={horizontal:[c],vertical:[Te],both:[c,Te]}[n],g={horizontal:[u],vertical:[Ae],both:[u,Ae]}[n],f=S?xe:{horizontal:_e,vertical:Pe,both:xe}[n];var y;t===m&&[...p,...g].includes(e.key)&&(t=s&&t===r&&p.includes(e.key)?i:s&&t===i&&g.includes(e.key)?r:G(C,{startingIndex:t,decrement:g.includes(e.key),disabledIndices:l})),t===m||O(C,t)||(e.stopPropagation(),f.includes(e.key)&&e.preventDefault(),v(t),null==(y=C.current[t])||y.focus())}(e)}};return(0,X.jsx)(Re.Provider,{value:w,children:(0,X.jsx)(ve,{elementsRef:C,children:Me(i,b)})})}),Ie=r.forwardRef(function(e,t){const{render:i,...n}=e,s=i&&"function"!=typeof i?i.props:{},{activeIndex:o,onNavigate:a}=r.useContext(Re),{ref:l,index:c}=Ce(),u=ge([l,t,s.ref]),h=o===c;return Me(i,{...n,...s,ref:u,tabIndex:h?0:-1,"data-active":h?"":void 0,onFocus(e){null==n.onFocus||n.onFocus(e),null==s.onFocus||s.onFocus(e),a(c)}})}),Le={...n};let Ne=!1,Oe=0;const Fe=()=>"floating-ui-"+Math.random().toString(36).slice(2,6)+Oe++,ke=Le.useId||function(){const[e,t]=r.useState(()=>Ne?Fe():void 0);return x(()=>{null==e&&t(Fe())},[]),r.useEffect(()=>{Ne=!0},[]),e},Ge=r.forwardRef(function(e,t){const{context:{placement:i,elements:{floating:n},middlewareData:{arrow:o,shift:a}},width:l=14,height:c=7,tipRadius:u=0,strokeWidth:h=0,staticOffset:d,stroke:p,d:g,style:{transform:f,...m}={},...v}=e,C=ke(),[y,w]=r.useState(!1);if(x(()=>{n&&"rtl"===(0,s.L9)(n).direction&&w(!0)},[n]),!n)return null;const[S,b]=i.split("-"),E="top"===S||"bottom"===S;let A=d;(E&&null!=a&&a.x||!E&&null!=a&&a.y)&&(A=null);const T=2*h,M=T/2,R=l/2*(u/-8+1),_=c/2*u/4,P=!!g,D=A&&"end"===b?"bottom":"top";let I=A&&"end"===b?"right":"left";A&&y&&(I="end"===b?"left":"right");const L=null!=(null==o?void 0:o.x)?A||o.x:"",N=null!=(null==o?void 0:o.y)?A||o.y:"",O=g||"M0,0 H"+l+" L"+(l-R)+","+(c-_)+" Q"+l/2+","+c+" "+R+","+(c-_)+" Z",F={top:P?"rotate(180deg)":"",left:P?"rotate(90deg)":"rotate(-90deg)",bottom:P?"":"rotate(180deg)",right:P?"rotate(-90deg)":"rotate(90deg)"}[S];return(0,X.jsxs)("svg",{...v,"aria-hidden":!0,ref:t,width:P?l:l+T,height:l,viewBox:"0 0 "+l+" "+(c>l?c:l),style:{position:"absolute",pointerEvents:"none",[I]:L,[D]:N,[S]:E||P?"100%":"calc(100% - "+T/2+"px)",transform:[F,f].filter(e=>!!e).join(" "),...m},children:[T>0&&(0,X.jsx)("path",{clipPath:"url(#"+C+")",fill:"none",stroke:p,strokeWidth:T+(g?0:1),d:O}),(0,X.jsx)("path",{stroke:T&&!g?v.fill:"none",d:O}),(0,X.jsx)("clipPath",{id:C,children:(0,X.jsx)("rect",{x:-M,y:M*(P?-1:1),width:l+T,height:l})})]})});function Ve(){const e=new Map;return{emit(t,i){var r;null==(r=e.get(t))||r.forEach(e=>e(i))},on(t,i){e.has(t)||e.set(t,new Set),e.get(t).add(i)},off(t,i){var r;null==(r=e.get(t))||r.delete(i)}}}const He=r.createContext(null),Be=r.createContext(null),ze=()=>{var e;return(null==(e=r.useContext(He))?void 0:e.id)||null},Ue=()=>r.useContext(Be);function We(e){const t=ke(),i=Ue(),r=ze(),n=e||r;return x(()=>{if(!t)return;const e={id:t,parentId:n};return null==i||i.addNode(e),()=>{null==i||i.removeNode(e)}},[i,t,n]),t}function je(e){const{children:t,id:i}=e,n=ze();return(0,X.jsx)(He.Provider,{value:r.useMemo(()=>({id:i,parentId:n}),[i,n]),children:t})}function Ke(e){const{children:t}=e,i=r.useRef([]),n=r.useCallback(e=>{i.current=[...i.current,e]},[]),s=r.useCallback(e=>{i.current=i.current.filter(t=>t!==e)},[]),[o]=r.useState(()=>Ve());return(0,X.jsx)(Be.Provider,{value:r.useMemo(()=>({nodesRef:i,addNode:n,removeNode:s,events:o}),[n,s,o]),children:t})}function $e(e){return"data-floating-ui-"+e}function qe(e){-1!==e.current&&(clearTimeout(e.current),e.current=-1)}const Ye=$e("safe-polygon");function Qe(e,t,i){if(i&&!P(i))return 0;if("number"==typeof e)return e;if("function"==typeof e){const i=e();return"number"==typeof i?i:null==i?void 0:i[t]}return null==e?void 0:e[t]}function Xe(e){return"function"==typeof e?e():e}function Ze(e,t){void 0===t&&(t={});const{open:i,onOpenChange:n,dataRef:o,events:a,elements:l}=e,{enabled:c=!0,delay:u=0,handleClose:h=null,mouseOnly:d=!1,restMs:p=0,move:g=!0}=t,f=Ue(),m=ze(),C=D(h),y=D(u),S=D(i),b=D(p),E=r.useRef(),A=r.useRef(-1),T=r.useRef(),M=r.useRef(-1),R=r.useRef(!0),_=r.useRef(!1),I=r.useRef(()=>{}),N=r.useRef(!1),O=L(()=>{var e;const t=null==(e=o.current.openEvent)?void 0:e.type;return(null==t?void 0:t.includes("mouse"))&&"mousedown"!==t});r.useEffect(()=>{if(c)return a.on("openchange",e),()=>{a.off("openchange",e)};function e(e){let{open:t}=e;t||(qe(A),qe(M),R.current=!0,N.current=!1)}},[c,a]),r.useEffect(()=>{if(!c)return;if(!C.current)return;if(!i)return;function e(e){O()&&n(!1,e,"hover")}const t=w(l.floating).documentElement;return t.addEventListener("mouseleave",e),()=>{t.removeEventListener("mouseleave",e)}},[l.floating,i,n,c,C,O]);const F=r.useCallback(function(e,t,i){void 0===t&&(t=!0),void 0===i&&(i="hover");const r=Qe(y.current,"close",E.current);r&&!T.current?(qe(A),A.current=window.setTimeout(()=>n(!1,e,i),r)):t&&(qe(A),n(!1,e,i))},[y,n]),k=L(()=>{I.current(),T.current=void 0}),G=L(()=>{if(_.current){const e=w(l.floating).body;e.style.pointerEvents="",e.removeAttribute(Ye),_.current=!1}}),V=L(()=>!!o.current.openEvent&&["click","mousedown"].includes(o.current.openEvent.type));r.useEffect(()=>{if(c&&(0,s.vq)(l.domReference)){const n=l.domReference,s=l.floating;return i&&n.addEventListener("mouseleave",r),g&&n.addEventListener("mousemove",e,{once:!0}),n.addEventListener("mouseenter",e),n.addEventListener("mouseleave",t),s&&(s.addEventListener("mouseleave",r),s.addEventListener("mouseenter",a),s.addEventListener("mouseleave",u)),()=>{i&&n.removeEventListener("mouseleave",r),g&&n.removeEventListener("mousemove",e),n.removeEventListener("mouseenter",e),n.removeEventListener("mouseleave",t),s&&(s.removeEventListener("mouseleave",r),s.removeEventListener("mouseenter",a),s.removeEventListener("mouseleave",u))}}function e(e){if(qe(A),R.current=!1,d&&!P(E.current)||Xe(b.current)>0&&!Qe(y.current,"open"))return;const t=Qe(y.current,"open",E.current);t?A.current=window.setTimeout(()=>{S.current||n(!0,e,"hover")},t):i||n(!0,e,"hover")}function t(e){if(V())return void G();I.current();const t=w(l.floating);if(qe(M),N.current=!1,C.current&&o.current.floatingContext){i||qe(A),T.current=C.current({...o.current.floatingContext,tree:f,x:e.clientX,y:e.clientY,onClose(){G(),k(),V()||F(e,!0,"safe-polygon")}});const r=T.current;return t.addEventListener("mousemove",r),void(I.current=()=>{t.removeEventListener("mousemove",r)})}("touch"!==E.current||!v(l.floating,e.relatedTarget))&&F(e)}function r(e){V()||o.current.floatingContext&&(null==C.current||C.current({...o.current.floatingContext,tree:f,x:e.clientX,y:e.clientY,onClose(){G(),k(),V()||F(e)}})(e))}function a(){qe(A)}function u(e){V()||F(e,!1)}},[l,c,e,d,g,F,k,G,n,i,S,f,y,C,o,V,b]),x(()=>{var e;if(c&&i&&null!=(e=C.current)&&null!=(e=e.__options)&&e.blockPointerEvents&&O()){_.current=!0;const e=l.floating;if((0,s.vq)(l.domReference)&&e){var t;const i=w(l.floating).body;i.setAttribute(Ye,"");const r=l.domReference,n=null==f||null==(t=f.nodesRef.current.find(e=>e.id===m))||null==(t=t.context)?void 0:t.elements.floating;return n&&(n.style.pointerEvents=""),i.style.pointerEvents="none",r.style.pointerEvents="auto",e.style.pointerEvents="auto",()=>{i.style.pointerEvents="",r.style.pointerEvents="",e.style.pointerEvents=""}}}},[c,i,m,l,f,C,O]),x(()=>{i||(E.current=void 0,N.current=!1,k(),G())},[i,k,G]),r.useEffect(()=>()=>{k(),qe(A),qe(M),G()},[c,l.domReference,k,G]);const H=r.useMemo(()=>{function e(e){E.current=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){const{nativeEvent:t}=e;function r(){R.current||S.current||n(!0,t,"hover")}d&&!P(E.current)||i||0===Xe(b.current)||N.current&&e.movementX**2+e.movementY**2<2||(qe(M),"touch"===E.current?r():(N.current=!0,M.current=window.setTimeout(r,Xe(b.current))))}}},[d,n,i,S,b]);return r.useMemo(()=>c?{reference:H}:{},[c,H])}const Je=()=>{},et=r.createContext({delay:0,initialDelay:0,timeoutMs:0,currentId:null,setCurrentId:Je,setState:Je,isInstantPhase:!1}),tt=()=>r.useContext(et);function it(e){const{children:t,delay:i,timeoutMs:n=0}=e,[s,o]=r.useReducer((e,t)=>({...e,...t}),{delay:i,timeoutMs:n,initialDelay:i,currentId:null,isInstantPhase:!1}),a=r.useRef(null),l=r.useCallback(e=>{o({currentId:e})},[]);return x(()=>{s.currentId?null===a.current?a.current=s.currentId:s.isInstantPhase||o({isInstantPhase:!0}):(s.isInstantPhase&&o({isInstantPhase:!1}),a.current=null)},[s.currentId,s.isInstantPhase]),(0,X.jsx)(et.Provider,{value:r.useMemo(()=>({...s,setState:o,setCurrentId:l}),[s,l]),children:t})}function rt(e,t){void 0===t&&(t={});const{open:i,onOpenChange:r,floatingId:n}=e,{id:s,enabled:o=!0}=t,a=null!=s?s:n,l=tt(),{currentId:c,setCurrentId:u,initialDelay:h,setState:d,timeoutMs:p}=l;return x(()=>{o&&c&&(d({delay:{open:1,close:Qe(h,"close")}}),c!==a&&r(!1))},[o,a,r,d,c,h]),x(()=>{function e(){r(!1),d({delay:h,currentId:null})}if(o&&c&&!i&&c===a){if(p){const t=window.setTimeout(e,p);return()=>{clearTimeout(t)}}e()}},[o,i,d,c,a,r,h,p]),x(()=>{o&&u!==Je&&i&&u(a)},[o,i,u,a]),l}const nt=r.createContext({hasProvider:!1,timeoutMs:0,delayRef:{current:0},initialDelayRef:{current:0},timeoutIdRef:{current:-1},currentIdRef:{current:null},currentContextRef:{current:null}});function st(e){const{children:t,delay:i,timeoutMs:n=0}=e,s=r.useRef(i),o=r.useRef(i),a=r.useRef(null),l=r.useRef(null),c=r.useRef(-1);return(0,X.jsx)(nt.Provider,{value:r.useMemo(()=>({hasProvider:!0,delayRef:s,initialDelayRef:o,currentIdRef:a,timeoutMs:n,currentContextRef:l,timeoutIdRef:c}),[n]),children:t})}function ot(e,t){void 0===t&&(t={});const{open:i,onOpenChange:n,floatingId:s}=e,{enabled:o=!0}=t,a=r.useContext(nt),{currentIdRef:l,delayRef:c,timeoutMs:u,initialDelayRef:h,currentContextRef:d,hasProvider:p,timeoutIdRef:g}=a,[f,m]=r.useState(!1);return x(()=>{function e(){var e;m(!1),null==(e=d.current)||e.setIsInstantPhase(!1),l.current=null,d.current=null,c.current=h.current}if(o&&l.current&&!i&&l.current===s){if(m(!1),u)return g.current=window.setTimeout(e,u),()=>{clearTimeout(g.current)};e()}},[o,i,s,l,c,u,h,d,g]),x(()=>{if(!o)return;if(!i)return;const e=d.current,t=l.current;d.current={onOpenChange:n,setIsInstantPhase:m},l.current=s,c.current={open:0,close:Qe(h.current,"close")},null!==t&&t!==s?(qe(g),m(!0),null==e||e.setIsInstantPhase(!0),null==e||e.onOpenChange(!1)):(m(!1),null==e||e.setIsInstantPhase(!1))},[o,i,s,n,l,c,u,h,d,g]),x(()=>()=>{d.current=null},[d]),r.useMemo(()=>({hasProvider:p,delayRef:c,isInstantPhase:f}),[p,c,f])}let at=0;function lt(e,t){void 0===t&&(t={});const{preventScroll:i=!1,cancelPrevious:r=!0,sync:n=!1}=t;r&&cancelAnimationFrame(at);const s=()=>null==e?void 0:e.focus({preventScroll:i});n?s():at=requestAnimationFrame(s)}function ct(e,t){if(!e||!t)return!1;const i=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(i&&(0,s.Ng)(i)){let i=t;for(;i;){if(e===i)return!0;i=i.parentNode||i.host}}return!1}const ut={inert:new WeakMap,"aria-hidden":new WeakMap,none:new WeakMap};function ht(e){return"inert"===e?ut.inert:"aria-hidden"===e?ut["aria-hidden"]:ut.none}let dt=new WeakSet,pt={},gt=0;function ft(e){return e?(0,s.Ng)(e)?e.host:ft(e.parentNode):null}const mt=(e,t)=>t.map(t=>{if(e.contains(t))return t;const i=ft(t);return e.contains(i)?i:null}).filter(e=>null!=e);function vt(e,t,i){void 0===t&&(t=!1),void 0===i&&(i=!1);const r=(n=e[0],(null==n?void 0:n.ownerDocument)||document).body;var n;return function(e,t,i,r){const n="data-floating-ui-inert",o=r?"inert":i?"aria-hidden":null,a=mt(t,e),l=new Set,c=new Set(a),u=[];pt[n]||(pt[n]=new WeakMap);const h=pt[n];return a.forEach(function e(t){t&&!l.has(t)&&(l.add(t),t.parentNode&&e(t.parentNode))}),function e(t){t&&!c.has(t)&&[].forEach.call(t.children,t=>{if("script"!==(0,s.mq)(t))if(l.has(t))e(t);else{const e=o?t.getAttribute(o):null,i=null!==e&&"false"!==e,r=ht(o),s=(r.get(t)||0)+1,a=(h.get(t)||0)+1;r.set(t,s),h.set(t,a),u.push(t),1===s&&i&&dt.add(t),1===a&&t.setAttribute(n,""),!i&&o&&t.setAttribute(o,"inert"===o?"":"true")}})}(t),l.clear(),gt++,()=>{u.forEach(e=>{const t=ht(o),i=(t.get(e)||0)-1,r=(h.get(e)||0)-1;t.set(e,i),h.set(e,r),i||(!dt.has(e)&&o&&e.removeAttribute(o),dt.delete(e)),r||e.removeAttribute(n)}),gt--,gt||(ut.inert=new WeakMap,ut["aria-hidden"]=new WeakMap,ut.none=new WeakMap,dt=new WeakSet,pt={})}}(e.concat(Array.from(r.querySelectorAll('[aria-live],[role="status"],output'))),r,t,i)}const Ct={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0},yt=r.forwardRef(function(e,t){const[i,n]=r.useState();x(()=>{u()&&n("button")},[]);const s={ref:t,tabIndex:0,role:i,"aria-hidden":!i||void 0,[$e("focus-guard")]:"",style:Ct};return(0,X.jsx)("span",{...e,...s})}),wt={clipPath:"inset(50%)",position:"fixed",top:0,left:0},St=r.createContext(null),bt=$e("portal");function Et(e){void 0===e&&(e={});const{id:t,root:i}=e,n=ke(),o=Tt(),[a,l]=r.useState(null),c=r.useRef(null);return x(()=>()=>{null==a||a.remove(),queueMicrotask(()=>{c.current=null})},[a]),x(()=>{if(!n)return;if(c.current)return;const e=t?document.getElementById(t):null;if(!e)return;const i=document.createElement("div");i.id=n,i.setAttribute(bt,""),e.appendChild(i),c.current=i,l(i)},[t,n]),x(()=>{if(null===i)return;if(!n)return;if(c.current)return;let e=i||(null==o?void 0:o.portalNode);e&&!(0,s.Ll)(e)&&(e=e.current),e=e||document.body;let r=null;t&&(r=document.createElement("div"),r.id=t,e.appendChild(r));const a=document.createElement("div");a.id=n,a.setAttribute(bt,""),e=r||e,e.appendChild(a),c.current=a,l(a)},[t,i,n,o]),a}function At(e){const{children:t,id:i,root:n,preserveTabOrder:s=!0}=e,o=Et({id:i,root:n}),[a,l]=r.useState(null),c=r.useRef(null),u=r.useRef(null),h=r.useRef(null),d=r.useRef(null),p=null==a?void 0:a.modal,g=null==a?void 0:a.open,f=!!a&&!a.modal&&a.open&&s&&!(!n&&!o);return r.useEffect(()=>{if(o&&s&&!p)return o.addEventListener("focusin",e,!0),o.addEventListener("focusout",e,!0),()=>{o.removeEventListener("focusin",e,!0),o.removeEventListener("focusout",e,!0)};function e(e){o&&q(e)&&("focusin"===e.type?Q:Y)(o)}},[o,s,p]),r.useEffect(()=>{o&&(g||Q(o))},[g,o]),(0,X.jsxs)(St.Provider,{value:r.useMemo(()=>({preserveTabOrder:s,beforeOutsideRef:c,afterOutsideRef:u,beforeInsideRef:h,afterInsideRef:d,portalNode:o,setFocusManagerState:l}),[s,o]),children:[f&&o&&(0,X.jsx)(yt,{"data-type":"outside",ref:c,onFocus:e=>{if(q(e,o)){var t;null==(t=h.current)||t.focus()}else{const e=$(a?a.domReference:null);null==e||e.focus()}}}),f&&o&&(0,X.jsx)("span",{"aria-owns":o.id,style:wt}),o&&Z.createPortal(t,o),f&&o&&(0,X.jsx)(yt,{"data-type":"outside",ref:u,onFocus:e=>{if(q(e,o)){var t;null==(t=d.current)||t.focus()}else{const t=K(a?a.domReference:null);null==t||t.focus(),(null==a?void 0:a.closeOnFocusOut)&&(null==a||a.onOpenChange(!1,e.nativeEvent,"focus-out"))}}})]})}const Tt=()=>r.useContext(St);function Mt(e){return r.useMemo(()=>t=>{e.forEach(e=>{e&&(e.current=t)})},e)}let Rt=[];function _t(){Rt=Rt.filter(e=>{var t;return null==(t=e.deref())?void 0:t.isConnected})}function Pt(){_t();const e=Rt[Rt.length-1];return null==e?void 0:e.deref()}function xt(e,t){var i;if(!(t.current.includes("floating")||null!=(i=e.getAttribute("role"))&&i.includes("dialog")))return;const r=W(),n=(0,a.nq)(e,r).filter(e=>{const t=e.getAttribute("data-tabindex")||"";return(0,a.AO)(e,r)||e.hasAttribute("data-tabindex")&&!t.startsWith("-")}),s=e.getAttribute("tabindex");t.current.includes("floating")||0===n.length?"0"!==s&&e.setAttribute("tabindex","0"):("-1"!==s||e.hasAttribute("data-tabindex")&&"-1"!==e.getAttribute("data-tabindex"))&&(e.setAttribute("tabindex","-1"),e.setAttribute("data-tabindex","-1"))}const Dt=r.forwardRef(function(e,t){return(0,X.jsx)("button",{...e,type:"button",ref:t,tabIndex:-1,style:Ct})});function It(e){const{context:t,children:i,disabled:n=!1,order:o=["content"],guards:l=!0,initialFocus:c=0,returnFocus:u=!0,restoreFocus:h=!1,modal:d=!0,visuallyHiddenDismiss:p=!1,closeOnFocusOut:g=!0,outsideElementsInert:f=!1,getInsideElements:y=()=>[]}=e,{open:S,onOpenChange:P,events:I,dataRef:N,elements:{domReference:O,floating:F}}=t,k=L(()=>{var e;return null==(e=N.current.floatingContext)?void 0:e.nodeId}),G=L(y),V="number"==typeof c&&c<0,H=b(O)&&V,B="undefined"!=typeof HTMLElement&&"inert"in HTMLElement.prototype,z=!B||l,U=!z||B&&f,j=D(o),Y=D(c),Q=D(u),Z=Ue(),J=Tt(),ee=r.useRef(null),te=r.useRef(null),ie=r.useRef(!1),re=r.useRef(!1),ne=r.useRef(-1),se=r.useRef(-1),oe=null!=J,ae=E(F),le=L(function(e){return void 0===e&&(e=ae),e?(0,a.Kr)(e,W()):[]}),ce=L(e=>{const t=le(e);return j.current.map(e=>O&&"reference"===e?O:ae&&"floating"===e?ae:t).filter(Boolean).flat()});r.useEffect(()=>{if(n)return;if(!d)return;function e(e){if("Tab"===e.key){v(ae,m(w(ae)))&&0===le().length&&!H&&M(e);const t=ce(),i=C(e);"reference"===j.current[0]&&i===O&&(M(e),e.shiftKey?lt(t[t.length-1]):lt(t[1])),"floating"===j.current[1]&&i===ae&&e.shiftKey&&(M(e),lt(t[0]))}}const t=w(ae);return t.addEventListener("keydown",e),()=>{t.removeEventListener("keydown",e)}},[n,O,ae,d,j,H,le,ce]),r.useEffect(()=>{if(!n&&F)return F.addEventListener("focusin",e),()=>{F.removeEventListener("focusin",e)};function e(e){const t=C(e),i=le().indexOf(t);-1!==i&&(ne.current=i)}},[n,F,le]),r.useEffect(()=>{if(n)return;if(!g)return;function e(){re.current=!0,setTimeout(()=>{re.current=!1})}function t(e){const t=e.relatedTarget,i=e.currentTarget,r=C(e);queueMicrotask(()=>{const n=k(),o=!(v(O,t)||v(F,t)||v(t,F)||v(null==J?void 0:J.portalNode,t)||null!=t&&t.hasAttribute($e("focus-guard"))||Z&&(A(Z.nodesRef.current,n).find(e=>{var i,r;return v(null==(i=e.context)?void 0:i.elements.floating,t)||v(null==(r=e.context)?void 0:r.elements.domReference,t)})||T(Z.nodesRef.current,n).find(e=>{var i,r,n;return[null==(i=e.context)?void 0:i.elements.floating,E(null==(r=e.context)?void 0:r.elements.floating)].includes(t)||(null==(n=e.context)?void 0:n.elements.domReference)===t})));if(i===O&&ae&&xt(ae,j),h&&i!==O&&(null==r||!r.isConnected)&&m(w(ae))===w(ae).body){(0,s.sb)(ae)&&ae.focus();const e=ne.current,t=le(),i=t[e]||t[t.length-1]||ae;(0,s.sb)(i)&&i.focus()}N.current.insideReactTree?N.current.insideReactTree=!1:!H&&d||!t||!o||re.current||t===Pt()||(ie.current=!0,P(!1,e,"focus-out"))})}const i=Boolean(!Z&&J);function r(){qe(se),N.current.insideReactTree=!0,se.current=window.setTimeout(()=>{N.current.insideReactTree=!1})}return F&&(0,s.sb)(O)?(O.addEventListener("focusout",t),O.addEventListener("pointerdown",e),F.addEventListener("focusout",t),i&&F.addEventListener("focusout",r,!0),()=>{O.removeEventListener("focusout",t),O.removeEventListener("pointerdown",e),F.removeEventListener("focusout",t),i&&F.removeEventListener("focusout",r,!0)}):void 0},[n,O,F,ae,d,Z,J,P,g,h,le,H,k,j,N]);const ue=r.useRef(null),he=r.useRef(null),de=Mt([ue,null==J?void 0:J.beforeInsideRef]),pe=Mt([he,null==J?void 0:J.afterInsideRef]);function ge(e){return!n&&p&&d?(0,X.jsx)(Dt,{ref:"start"===e?ee:te,onClick:e=>P(!1,e.nativeEvent),children:"string"==typeof p?p:"Dismiss"}):null}r.useEffect(()=>{var e,t;if(n)return;if(!F)return;const i=Array.from((null==J||null==(e=J.portalNode)?void 0:e.querySelectorAll("["+$e("portal")+"]"))||[]),r=null==(t=(Z?T(Z.nodesRef.current,k()):[]).find(e=>{var t;return b((null==(t=e.context)?void 0:t.elements.domReference)||null)}))||null==(t=t.context)?void 0:t.elements.domReference,s=[F,r,...i,...G(),ee.current,te.current,ue.current,he.current,null==J?void 0:J.beforeOutsideRef.current,null==J?void 0:J.afterOutsideRef.current,j.current.includes("reference")||H?O:null].filter(e=>null!=e),o=d||H?vt(s,!U,U):vt(s);return()=>{o()}},[n,O,F,d,j,J,H,z,U,Z,k,G]),x(()=>{if(n||!(0,s.sb)(ae))return;const e=m(w(ae));queueMicrotask(()=>{const t=ce(ae),i=Y.current,r=("number"==typeof i?t[i]:i.current)||ae,n=v(ae,e);V||n||!S||lt(r,{preventScroll:r===ae})})},[n,S,ae,V,ce,Y]),x(()=>{if(n||!ae)return;const e=w(ae);var t;function i(e){let{reason:t,event:i,nested:r}=e;if(["hover","safe-polygon"].includes(t)&&"mouseleave"===i.type&&(ie.current=!0),"outside-press"===t)if(r)ie.current=!1;else if(R(i)||_(i))ie.current=!1;else{let e=!1;document.createElement("div").focus({get preventScroll(){return e=!0,!1}}),ie.current=!e}}t=m(e),_t(),t&&"body"!==(0,s.mq)(t)&&(Rt.push(new WeakRef(t)),Rt.length>20&&(Rt=Rt.slice(-20))),I.on("openchange",i);const r=e.createElement("span");return r.setAttribute("tabindex","-1"),r.setAttribute("aria-hidden","true"),Object.assign(r.style,Ct),oe&&O&&O.insertAdjacentElement("afterend",r),()=>{I.off("openchange",i);const t=m(e),n=v(F,t)||Z&&A(Z.nodesRef.current,k(),!1).some(e=>{var i;return v(null==(i=e.context)?void 0:i.elements.floating,t)}),o=function(){if("boolean"==typeof Q.current){const e=O||Pt();return e&&e.isConnected?e:r}return Q.current.current||r}();queueMicrotask(()=>{const i=function(e){const t=W();return(0,a.AO)(e,t)?e:(0,a.Kr)(e,t)[0]||e}(o);Q.current&&!ie.current&&(0,s.sb)(i)&&(i===t||t===e.body||n)&&i.focus({preventScroll:!0}),r.remove()})}},[n,F,ae,Q,N,I,Z,oe,O,k]),r.useEffect(()=>(queueMicrotask(()=>{ie.current=!1}),()=>{queueMicrotask(_t)}),[n]),x(()=>{if(!n&&J)return J.setFocusManagerState({modal:d,closeOnFocusOut:g,open:S,onOpenChange:P,domReference:O}),()=>{J.setFocusManagerState(null)}},[n,J,d,S,P,g,O]),x(()=>{n||ae&&xt(ae,j)},[n,ae,j]);const fe=!n&&z&&(!d||!H)&&(oe||d);return(0,X.jsxs)(X.Fragment,{children:[fe&&(0,X.jsx)(yt,{"data-type":"inside",ref:de,onFocus:e=>{if(d){const e=ce();lt("reference"===o[0]?e[0]:e[e.length-1])}else if(null!=J&&J.preserveTabOrder&&J.portalNode)if(ie.current=!1,q(e,J.portalNode)){const e=K(O);null==e||e.focus()}else{var t;null==(t=J.beforeOutsideRef.current)||t.focus()}}}),!H&&ge("start"),i,ge("end"),fe&&(0,X.jsx)(yt,{"data-type":"inside",ref:pe,onFocus:e=>{if(d)lt(ce()[0]);else if(null!=J&&J.preserveTabOrder&&J.portalNode)if(g&&(ie.current=!0),q(e,J.portalNode)){const e=$(O);null==e||e.focus()}else{var t;null==(t=J.afterOutsideRef.current)||t.focus()}}})]})}let Lt=0;const Nt="--floating-ui-scrollbar-width";let Ot=()=>{};const Ft=r.forwardRef(function(e,t){const{lockScroll:i=!1,...r}=e;return x(()=>{if(i)return Lt++,1===Lt&&(Ot=function(){const e=l(),t=/iP(hone|ad|od)|iOS/.test(e)||"MacIntel"===e&&navigator.maxTouchPoints>1,i=document.body.style,r=Math.round(document.documentElement.getBoundingClientRect().left)+document.documentElement.scrollLeft?"paddingLeft":"paddingRight",n=window.innerWidth-document.documentElement.clientWidth,s=i.left?parseFloat(i.left):window.scrollX,o=i.top?parseFloat(i.top):window.scrollY;if(i.overflow="hidden",i.setProperty(Nt,n+"px"),n&&(i[r]=n+"px"),t){var a,c;const e=(null==(a=window.visualViewport)?void 0:a.offsetLeft)||0,t=(null==(c=window.visualViewport)?void 0:c.offsetTop)||0;Object.assign(i,{position:"fixed",top:-(o-Math.floor(t))+"px",left:-(s-Math.floor(e))+"px",right:"0"})}return()=>{Object.assign(i,{overflow:"",[r]:""}),i.removeProperty(Nt),t&&(Object.assign(i,{position:"",top:"",left:"",right:""}),window.scrollTo(s,o))}}()),()=>{Lt--,0===Lt&&Ot()}},[i]),(0,X.jsx)("div",{ref:t,...r,style:{position:"fixed",overflow:"auto",top:0,right:0,bottom:0,left:0,...r.style}})});function kt(e){return(0,s.sb)(e.target)&&"BUTTON"===e.target.tagName}function Gt(e){return S(e)}function Vt(e,t){void 0===t&&(t={});const{open:i,onOpenChange:n,dataRef:o,elements:{domReference:a}}=e,{enabled:l=!0,event:c="click",toggle:u=!0,ignoreMouse:h=!1,keyboardHandlers:d=!0,stickIfOpen:p=!0}=t,g=r.useRef(),f=r.useRef(!1),m=r.useMemo(()=>({onPointerDown(e){g.current=e.pointerType},onMouseDown(e){const t=g.current;0===e.button&&"click"!==c&&(P(t,!0)&&h||(!i||!u||o.current.openEvent&&p&&"mousedown"!==o.current.openEvent.type?(e.preventDefault(),n(!0,e.nativeEvent,"click")):n(!1,e.nativeEvent,"click")))},onClick(e){const t=g.current;"mousedown"===c&&g.current?g.current=void 0:P(t,!0)&&h||(!i||!u||o.current.openEvent&&p&&"click"!==o.current.openEvent.type?n(!0,e.nativeEvent,"click"):n(!1,e.nativeEvent,"click"))},onKeyDown(e){g.current=void 0,e.defaultPrevented||!d||kt(e)||(" "!==e.key||Gt(a)||(e.preventDefault(),f.current=!0),function(e){return(0,s.sb)(e.target)&&"A"===e.target.tagName}(e)||"Enter"===e.key&&n(!i||!u,e.nativeEvent,"click"))},onKeyUp(e){e.defaultPrevented||!d||kt(e)||Gt(a)||" "===e.key&&f.current&&(f.current=!1,n(!i||!u,e.nativeEvent,"click"))}}),[o,a,c,h,d,n,i,p,u]);return r.useMemo(()=>l?{reference:m}:{},[l,m])}function Ht(e){return null!=e&&null!=e.clientX}function Bt(e,t){void 0===t&&(t={});const{open:i,dataRef:n,elements:{floating:o,domReference:a},refs:l}=e,{enabled:c=!0,axis:u="both",x:h=null,y:d=null}=t,p=r.useRef(!1),g=r.useRef(null),[f,m]=r.useState(),[y,w]=r.useState([]),S=L((e,t)=>{p.current||n.current.openEvent&&!Ht(n.current.openEvent)||l.setPositionReference(function(e,t){let i=null,r=null,n=!1;return{contextElement:e||void 0,getBoundingClientRect(){var s;const o=(null==e?void 0:e.getBoundingClientRect())||{width:0,height:0,x:0,y:0},a="x"===t.axis||"both"===t.axis,l="y"===t.axis||"both"===t.axis,c=["mouseenter","mousemove"].includes((null==(s=t.dataRef.current.openEvent)?void 0:s.type)||"")&&"touch"!==t.pointerType;let u=o.width,h=o.height,d=o.x,p=o.y;return null==i&&t.x&&a&&(i=o.x-t.x),null==r&&t.y&&l&&(r=o.y-t.y),d-=i||0,p-=r||0,u=0,h=0,!n||c?(u="y"===t.axis?o.width:0,h="x"===t.axis?o.height:0,d=a&&null!=t.x?t.x:d,p=l&&null!=t.y?t.y:p):n&&!c&&(h="x"===t.axis?o.height:h,u="y"===t.axis?o.width:u),n=!0,{width:u,height:h,x:d,y:p,top:p,right:d+u,bottom:p+h,left:d}}}}(a,{x:e,y:t,axis:u,dataRef:n,pointerType:f}))}),b=L(e=>{null==h&&null==d&&(i?g.current||w([]):S(e.clientX,e.clientY))}),E=P(f)?o:i,A=r.useCallback(()=>{if(!E||!c||null!=h||null!=d)return;const e=(0,s.zk)(o);function t(i){const r=C(i);v(o,r)?(e.removeEventListener("mousemove",t),g.current=null):S(i.clientX,i.clientY)}if(!n.current.openEvent||Ht(n.current.openEvent)){e.addEventListener("mousemove",t);const i=()=>{e.removeEventListener("mousemove",t),g.current=null};return g.current=i,i}l.setPositionReference(a)},[E,c,h,d,o,n,l,a,S]);r.useEffect(()=>A(),[A,y]),r.useEffect(()=>{c&&!o&&(p.current=!1)},[c,o]),r.useEffect(()=>{!c&&i&&(p.current=!0)},[c,i]),x(()=>{!c||null==h&&null==d||(p.current=!1,S(h,d))},[c,h,d,S]);const T=r.useMemo(()=>{function e(e){let{pointerType:t}=e;m(t)}return{onPointerDown:e,onPointerEnter:e,onMouseMove:b,onMouseEnter:b}},[b]);return r.useMemo(()=>c?{reference:T}:{},[c,T])}const zt={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},Ut={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},Wt=e=>{var t,i;return{escapeKey:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePress:"boolean"==typeof e?e:null==(i=null==e?void 0:e.outsidePress)||i}};function jt(e,t){void 0===t&&(t={});const{open:i,onOpenChange:n,elements:o,dataRef:a}=e,{enabled:l=!0,escapeKey:c=!0,outsidePress:u=!0,outsidePressEvent:h="pointerdown",referencePress:d=!1,referencePressEvent:p="pointerdown",ancestorScroll:g=!1,bubbles:f,capture:m}=t,S=Ue(),b=L("function"==typeof u?u:()=>!1),E="function"==typeof u?b:u,T=r.useRef(!1),{escapeKey:M,outsidePress:R}=Wt(f),{escapeKey:_,outsidePress:P}=Wt(m),x=r.useRef(!1),D=L(e=>{var t;if(!i||!l||!c||"Escape"!==e.key)return;if(x.current)return;const r=null==(t=a.current.floatingContext)?void 0:t.nodeId,s=S?A(S.nodesRef.current,r):[];if(!M&&(e.stopPropagation(),s.length>0)){let e=!0;if(s.forEach(t=>{var i;null==(i=t.context)||!i.open||t.context.dataRef.current.__escapeKeyBubbles||(e=!1)}),!e)return}n(!1,function(e){return"nativeEvent"in e}(e)?e.nativeEvent:e,"escape-key")}),I=L(e=>{var t;const i=()=>{var t;D(e),null==(t=C(e))||t.removeEventListener("keydown",i)};null==(t=C(e))||t.addEventListener("keydown",i)}),N=L(e=>{var t;const i=a.current.insideReactTree;a.current.insideReactTree=!1;const r=T.current;if(T.current=!1,"click"===h&&r)return;if(i)return;if("function"==typeof E&&!E(e))return;const l=C(e),c="["+$e("inert")+"]",u=w(o.floating).querySelectorAll(c);let d=(0,s.vq)(l)?l:null;for(;d&&!(0,s.eu)(d);){const e=(0,s.$4)(d);if((0,s.eu)(e)||!(0,s.vq)(e))break;d=e}if(u.length&&(0,s.vq)(l)&&!l.matches("html,body")&&!v(l,o.floating)&&Array.from(u).every(e=>!v(d,e)))return;if((0,s.sb)(l)&&k){const t=(0,s.eu)(l),i=(0,s.L9)(l),r=/auto|scroll/,n=t||r.test(i.overflowX),o=t||r.test(i.overflowY),a=n&&l.clientWidth>0&&l.scrollWidth>l.clientWidth,c=o&&l.clientHeight>0&&l.scrollHeight>l.clientHeight,u="rtl"===i.direction,h=c&&(u?e.offsetX<=l.offsetWidth-l.clientWidth:e.offsetX>l.clientWidth),d=a&&e.offsetY>l.clientHeight;if(h||d)return}const p=null==(t=a.current.floatingContext)?void 0:t.nodeId,g=S&&A(S.nodesRef.current,p).some(t=>{var i;return y(e,null==(i=t.context)?void 0:i.elements.floating)});if(y(e,o.floating)||y(e,o.domReference)||g)return;const f=S?A(S.nodesRef.current,p):[];if(f.length>0){let e=!0;if(f.forEach(t=>{var i;null==(i=t.context)||!i.open||t.context.dataRef.current.__outsidePressBubbles||(e=!1)}),!e)return}n(!1,e,"outside-press")}),O=L(e=>{var t;const i=()=>{var t;N(e),null==(t=C(e))||t.removeEventListener(h,i)};null==(t=C(e))||t.addEventListener(h,i)});r.useEffect(()=>{if(!i||!l)return;a.current.__escapeKeyBubbles=M,a.current.__outsidePressBubbles=R;let e=-1;function t(e){n(!1,e,"ancestor-scroll")}function r(){window.clearTimeout(e),x.current=!0}function u(){e=window.setTimeout(()=>{x.current=!1},(0,s.Tc)()?5:0)}const d=w(o.floating);c&&(d.addEventListener("keydown",_?I:D,_),d.addEventListener("compositionstart",r),d.addEventListener("compositionend",u)),E&&d.addEventListener(h,P?O:N,P);let p=[];return g&&((0,s.vq)(o.domReference)&&(p=(0,s.v9)(o.domReference)),(0,s.vq)(o.floating)&&(p=p.concat((0,s.v9)(o.floating))),!(0,s.vq)(o.reference)&&o.reference&&o.reference.contextElement&&(p=p.concat((0,s.v9)(o.reference.contextElement)))),p=p.filter(e=>{var t;return e!==(null==(t=d.defaultView)?void 0:t.visualViewport)}),p.forEach(e=>{e.addEventListener("scroll",t,{passive:!0})}),()=>{c&&(d.removeEventListener("keydown",_?I:D,_),d.removeEventListener("compositionstart",r),d.removeEventListener("compositionend",u)),E&&d.removeEventListener(h,P?O:N,P),p.forEach(e=>{e.removeEventListener("scroll",t)}),window.clearTimeout(e)}},[a,o,c,E,h,i,n,g,l,M,R,D,_,I,N,P,O]),r.useEffect(()=>{a.current.insideReactTree=!1},[a,E,h]);const F=r.useMemo(()=>({onKeyDown:D,...d&&{[zt[p]]:e=>{n(!1,e.nativeEvent,"reference-press")},..."click"!==p&&{onClick(e){n(!1,e.nativeEvent,"reference-press")}}}}),[D,n,d,p]),k=r.useMemo(()=>{function e(e){0===e.button&&(T.current=!0)}return{onKeyDown:D,onMouseDown:e,onMouseUp:e,[Ut[h]]:()=>{a.current.insideReactTree=!0}}},[D,h,a]);return r.useMemo(()=>l?{reference:F,floating:k}:{},[l,F,k])}function Kt(e){const{open:t=!1,onOpenChange:i,elements:n}=e,s=ke(),o=r.useRef({}),[a]=r.useState(()=>Ve()),l=null!=ze(),[c,u]=r.useState(n.reference),h=L((e,t,r)=>{o.current.openEvent=e?t:void 0,a.emit("openchange",{open:e,event:t,reason:r,nested:l}),null==i||i(e,t,r)}),d=r.useMemo(()=>({setPositionReference:u}),[]),p=r.useMemo(()=>({reference:c||n.reference||null,floating:n.floating||null,domReference:n.reference}),[c,n.reference,n.floating]);return r.useMemo(()=>({dataRef:o,open:t,onOpenChange:h,elements:p,events:a,floatingId:s,refs:d}),[t,h,p,a,s,d])}function $t(e){void 0===e&&(e={});const{nodeId:t}=e,i=Kt({...e,elements:{reference:null,floating:null,...e.elements}}),n=e.rootContext||i,o=n.elements,[a,l]=r.useState(null),[c,u]=r.useState(null),h=(null==o?void 0:o.domReference)||a,d=r.useRef(null),p=Ue();x(()=>{h&&(d.current=h)},[h]);const g=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:i="absolute",middleware:n=[],platform:s,elements:{reference:o,floating:a}={},transform:l=!0,whileElementsMounted:c,open:u}=e,[h,d]=r.useState({x:0,y:0,strategy:i,placement:t,middlewareData:{},isPositioned:!1}),[p,g]=r.useState(n);te(p,n)||g(n);const[f,m]=r.useState(null),[v,C]=r.useState(null),y=r.useCallback(e=>{e!==E.current&&(E.current=e,m(e))},[]),w=r.useCallback(e=>{e!==A.current&&(A.current=e,C(e))},[]),S=o||f,b=a||v,E=r.useRef(null),A=r.useRef(null),T=r.useRef(h),M=null!=c,R=ne(c),_=ne(s),P=ne(u),x=r.useCallback(()=>{if(!E.current||!A.current)return;const e={placement:t,strategy:i,middleware:p};_.current&&(e.platform=_.current),(0,J.rD)(E.current,A.current,e).then(e=>{const t={...e,isPositioned:!1!==P.current};D.current&&!te(T.current,t)&&(T.current=t,Z.flushSync(()=>{d(t)}))})},[p,t,i,_,P]);ee(()=>{!1===u&&T.current.isPositioned&&(T.current.isPositioned=!1,d(e=>({...e,isPositioned:!1})))},[u]);const D=r.useRef(!1);ee(()=>(D.current=!0,()=>{D.current=!1}),[]),ee(()=>{if(S&&(E.current=S),b&&(A.current=b),S&&b){if(R.current)return R.current(S,b,x);x()}},[S,b,x,R,M]);const I=r.useMemo(()=>({reference:E,floating:A,setReference:y,setFloating:w}),[y,w]),L=r.useMemo(()=>({reference:S,floating:b}),[S,b]),N=r.useMemo(()=>{const e={position:i,left:0,top:0};if(!L.floating)return e;const t=re(L.floating,h.x),r=re(L.floating,h.y);return l?{...e,transform:"translate("+t+"px, "+r+"px)",...ie(L.floating)>=1.5&&{willChange:"transform"}}:{position:i,left:t,top:r}},[i,l,L.floating,h.x,h.y]);return r.useMemo(()=>({...h,update:x,refs:I,elements:L,floatingStyles:N}),[h,x,I,L,N])}({...e,elements:{...o,...c&&{reference:c}}}),f=r.useCallback(e=>{const t=(0,s.vq)(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),getClientRects:()=>e.getClientRects(),contextElement:e}:e;u(t),g.refs.setReference(t)},[g.refs]),m=r.useCallback(e=>{((0,s.vq)(e)||null===e)&&(d.current=e,l(e)),((0,s.vq)(g.refs.reference.current)||null===g.refs.reference.current||null!==e&&!(0,s.vq)(e))&&g.refs.setReference(e)},[g.refs]),v=r.useMemo(()=>({...g.refs,setReference:m,setPositionReference:f,domReference:d}),[g.refs,m,f]),C=r.useMemo(()=>({...g.elements,domReference:h}),[g.elements,h]),y=r.useMemo(()=>({...g,...n,refs:v,elements:C,nodeId:t}),[g,v,C,t,n]);return x(()=>{n.dataRef.current.floatingContext=y;const e=null==p?void 0:p.nodesRef.current.find(e=>e.id===t);e&&(e.context=y)}),r.useMemo(()=>({...g,context:y,refs:v,elements:C}),[g,v,C,y])}function qt(){return l().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints&&u()}function Yt(e,t){void 0===t&&(t={});const{open:i,onOpenChange:n,events:o,dataRef:a,elements:l}=e,{enabled:c=!0,visibleOnly:u=!0}=t,h=r.useRef(!1),p=r.useRef(-1),g=r.useRef(!0);r.useEffect(()=>{if(!c)return;const e=(0,s.zk)(l.domReference);function t(){!i&&(0,s.sb)(l.domReference)&&l.domReference===m(w(l.domReference))&&(h.current=!0)}function r(){g.current=!0}function n(){g.current=!1}return e.addEventListener("blur",t),qt()&&(e.addEventListener("keydown",r,!0),e.addEventListener("pointerdown",n,!0)),()=>{e.removeEventListener("blur",t),qt()&&(e.removeEventListener("keydown",r,!0),e.removeEventListener("pointerdown",n,!0))}},[l.domReference,i,c]),r.useEffect(()=>{if(c)return o.on("openchange",e),()=>{o.off("openchange",e)};function e(e){let{reason:t}=e;"reference-press"!==t&&"escape-key"!==t||(h.current=!0)}},[o,c]),r.useEffect(()=>()=>{qe(p)},[]);const f=r.useMemo(()=>({onMouseLeave(){h.current=!1},onFocus(e){if(h.current)return;const t=C(e.nativeEvent);if(u&&(0,s.vq)(t))if(qt()&&!e.relatedTarget){if(!g.current&&!S(t))return}else if(!function(e){if(!e||d())return!0;try{return e.matches(":focus-visible")}catch(e){return!0}}(t))return;n(!0,e.nativeEvent,"focus")},onBlur(e){h.current=!1;const t=e.relatedTarget,i=e.nativeEvent,r=(0,s.vq)(t)&&t.hasAttribute($e("focus-guard"))&&"outside"===t.getAttribute("data-type");p.current=window.setTimeout(()=>{var e;const s=m(l.domReference?l.domReference.ownerDocument:document);(t||s!==l.domReference)&&(v(null==(e=a.current.floatingContext)?void 0:e.refs.floating.current,s)||v(l.domReference,s)||r||n(!1,i,"focus"))})}}),[a,l.domReference,n,u]);return r.useMemo(()=>c?{reference:f}:{},[c,f])}function Qt(e,t,i){const r=new Map,n="item"===i;let s=e;if(n&&e){const{[we]:t,[Se]:i,...r}=e;s=r}return{..."floating"===i&&{tabIndex:-1,[ye]:""},...s,...t.map(t=>{const r=t?t[i]:null;return"function"==typeof r?e?r(e):null:r}).concat(e).reduce((e,t)=>t?(Object.entries(t).forEach(t=>{let[i,s]=t;var o;n&&[we,Se].includes(i)||(0===i.indexOf("on")?(r.has(i)||r.set(i,[]),"function"==typeof s&&(null==(o=r.get(i))||o.push(s),e[i]=function(){for(var e,t=arguments.length,n=new Array(t),s=0;s<t;s++)n[s]=arguments[s];return null==(e=r.get(i))?void 0:e.map(e=>e(...n)).find(e=>void 0!==e)})):e[i]=s)}),e):e,{})}}function Xt(e){void 0===e&&(e=[]);const t=e.map(e=>null==e?void 0:e.reference),i=e.map(e=>null==e?void 0:e.floating),n=e.map(e=>null==e?void 0:e.item),s=r.useCallback(t=>Qt(t,e,"reference"),t),o=r.useCallback(t=>Qt(t,e,"floating"),i),a=r.useCallback(t=>Qt(t,e,"item"),n);return r.useMemo(()=>({getReferenceProps:s,getFloatingProps:o,getItemProps:a}),[s,o,a])}function Zt(e,t,i){switch(e){case"vertical":return t;case"horizontal":return i;default:return t||i}}function Jt(e,t){return Zt(t,e===Ae||e===Te,e===be||e===Ee)}function ei(e,t,i){return Zt(t,e===Te,i?e===be:e===Ee)||"Enter"===e||" "===e||""===e}function ti(e,t,i){return Zt(t,i?e===be:e===Ee,e===Te)}function ii(e,t,i,r){return"both"===t||"horizontal"===t&&r&&r>1?"Escape"===e:Zt(t,i?e===Ee:e===be,e===Ae)}function ri(e,t){const{open:i,onOpenChange:n,elements:o,floatingId:a}=e,{listRef:l,activeIndex:c,onNavigate:u=()=>{},enabled:h=!0,selectedIndex:d=null,allowEscape:p=!1,loop:g=!1,nested:f=!1,rtl:C=!1,virtual:y=!1,focusItemOnOpen:S="auto",focusItemOnHover:T=!0,openOnArrowKeyDown:P=!0,disabledIndices:I,orientation:N="vertical",parentOrientation:W,cols:j=1,scrollItemIntoView:K=!0,virtualItemRef:$,itemSizes:q,dense:Y=!1}=t,Q=D(E(o.floating)),X=ze(),Z=Ue();x(()=>{e.dataRef.current.orientation=N},[e,N]);const J=L(()=>{u(-1===ie.current?null:ie.current)}),ee=b(o.domReference),te=r.useRef(S),ie=r.useRef(null!=d?d:-1),re=r.useRef(null),ne=r.useRef(!0),se=r.useRef(J),oe=r.useRef(!!o.floating),ae=r.useRef(i),le=r.useRef(!1),ce=r.useRef(!1),ue=D(I),he=D(i),de=D(K),pe=D(d),[ge,fe]=r.useState(),[me,ve]=r.useState(),Ce=L(()=>{function e(e){var t;y?(null!=(t=e.id)&&t.endsWith("-fui-option")&&(e.id=a+"-"+Math.random().toString(16).slice(2,10)),fe(e.id),null==Z||Z.events.emit("virtualfocus",e),$&&($.current=e)):lt(e,{sync:le.current,preventScroll:!0})}const t=l.current[ie.current],i=ce.current;t&&e(t),(le.current?e=>e():requestAnimationFrame)(()=>{const r=l.current[ie.current]||t;if(!r)return;t||e(r);const n=de.current;n&&we&&(i||!ne.current)&&(null==r.scrollIntoView||r.scrollIntoView("boolean"==typeof n?{block:"nearest",inline:"nearest"}:n))})});x(()=>{h&&(i&&o.floating?te.current&&null!=d&&(ce.current=!0,ie.current=d,J()):oe.current&&(ie.current=-1,se.current()))},[h,i,o.floating,d,J]),x(()=>{if(h&&i&&o.floating)if(null==c){if(le.current=!1,null!=pe.current)return;if(oe.current&&(ie.current=-1,Ce()),(!ae.current||!oe.current)&&te.current&&(null!=re.current||!0===te.current&&null==re.current)){let e=0;const t=()=>{null==l.current[0]?(e<2&&(e?requestAnimationFrame:queueMicrotask)(t),e++):(ie.current=null==re.current||ei(re.current,N,C)||f?F(l,ue.current):k(l,ue.current),re.current=null,J())};t()}}else O(l,c)||(ie.current=c,Ce(),ce.current=!1)},[h,i,o.floating,c,pe,f,l,N,C,J,Ce,ue]),x(()=>{var e;if(!h||o.floating||!Z||y||!oe.current)return;const t=Z.nodesRef.current,i=null==(e=t.find(e=>e.id===X))||null==(e=e.context)?void 0:e.elements.floating,r=m(w(o.floating)),n=t.some(e=>e.context&&v(e.context.elements.floating,r));i&&!n&&ne.current&&i.focus({preventScroll:!0})},[h,o.floating,Z,X,y]),x(()=>{if(h&&Z&&y&&!X)return Z.events.on("virtualfocus",e),()=>{Z.events.off("virtualfocus",e)};function e(e){ve(e.id),$&&($.current=e)}},[h,Z,y,X,$]),x(()=>{se.current=J,ae.current=i,oe.current=!!o.floating}),x(()=>{i||(re.current=null,te.current=S)},[i,S]);const ye=null!=c,we=r.useMemo(()=>{function e(e){if(!he.current)return;const t=l.current.indexOf(e);-1!==t&&ie.current!==t&&(ie.current=t,J())}return{onFocus(t){let{currentTarget:i}=t;le.current=!0,e(i)},onClick:e=>{let{currentTarget:t}=e;return t.focus({preventScroll:!0})},onMouseMove(t){let{currentTarget:i}=t;le.current=!0,ce.current=!1,T&&e(i)},onPointerLeave(e){let{pointerType:t}=e;var i;ne.current&&"touch"!==t&&(le.current=!0,T&&(ie.current=-1,J(),y||null==(i=Q.current)||i.focus({preventScroll:!0})))}}},[he,Q,T,l,J,y]),Se=r.useCallback(()=>{var e;return null!=W?W:null==Z||null==(e=Z.nodesRef.current.find(e=>e.id===X))||null==(e=e.context)||null==(e=e.dataRef)?void 0:e.current.orientation},[X,Z,W]),Ae=L(e=>{if(ne.current=!1,le.current=!0,229===e.which)return;if(!he.current&&e.currentTarget===Q.current)return;if(f&&ii(e.key,N,C,j))return Jt(e.key,Se())||M(e),n(!1,e.nativeEvent,"list-navigation"),void((0,s.sb)(o.domReference)&&(y?null==Z||Z.events.emit("virtualfocus",o.domReference):o.domReference.focus()));const t=ie.current,r=F(l,I),a=k(l,I);if(ee||("Home"===e.key&&(M(e),ie.current=r,J()),"End"===e.key&&(M(e),ie.current=a,J())),j>1){const t=q||Array.from({length:l.current.length},()=>({width:1,height:1})),i=H(t,j,Y),n=i.findIndex(e=>null!=e&&!U(l,e,I)),s=i.reduce((e,t,i)=>null==t||U(l,t,I)?e:i,-1),o=i[V({current:i.map(e=>null!=e?l.current[e]:null)},{event:e,orientation:N,loop:g,rtl:C,cols:j,disabledIndices:z([...("function"!=typeof I?I:null)||l.current.map((e,t)=>U(l,t,I)?t:void 0),void 0],i),minIndex:n,maxIndex:s,prevIndex:B(ie.current>a?r:ie.current,t,i,j,e.key===Te?"bl":e.key===(C?be:Ee)?"tr":"tl"),stopEvent:!0})];if(null!=o&&(ie.current=o,J()),"both"===N)return}if(Jt(e.key,N)){if(M(e),i&&!y&&m(e.currentTarget.ownerDocument)===e.currentTarget)return ie.current=ei(e.key,N,C)?r:a,void J();ei(e.key,N,C)?ie.current=g?t>=a?p&&t!==l.current.length?-1:r:G(l,{startingIndex:t,disabledIndices:I}):Math.min(a,G(l,{startingIndex:t,disabledIndices:I})):ie.current=g?t<=r?p&&-1!==t?l.current.length:a:G(l,{startingIndex:t,decrement:!0,disabledIndices:I}):Math.max(r,G(l,{startingIndex:t,decrement:!0,disabledIndices:I})),O(l,ie.current)&&(ie.current=-1),J()}}),Me=r.useMemo(()=>y&&i&&ye&&{"aria-activedescendant":me||ge},[y,i,ye,me,ge]),Re=r.useMemo(()=>({"aria-orientation":"both"===N?void 0:N,...ee?{}:Me,onKeyDown:Ae,onPointerMove(){ne.current=!0}}),[Me,Ae,N,ee]),_e=r.useMemo(()=>{function e(e){"auto"===S&&R(e.nativeEvent)&&(te.current=!0)}function t(e){te.current=S,"auto"===S&&_(e.nativeEvent)&&(te.current=!0)}return{...Me,onKeyDown(e){ne.current=!1;const t=e.key.startsWith("Arrow"),r=["Home","End"].includes(e.key),s=t||r,o=ti(e.key,N,C),a=ii(e.key,N,C,j),c=ti(e.key,Se(),C),u=Jt(e.key,N),h=(f?c:u)||"Enter"===e.key||""===e.key.trim();if(y&&i){const t=null==Z?void 0:Z.nodesRef.current.find(e=>null==e.parentId),i=Z&&t?function(e,t){let i,r=-1;return function t(n,s){s>r&&(i=n,r=s),A(e,n).forEach(e=>{t(e.id,s+1)})}(t,0),e.find(e=>e.id===i)}(Z.nodesRef.current,t.id):null;if(s&&i&&$){const t=new KeyboardEvent("keydown",{key:e.key,bubbles:!0});if(o||a){var p,g;const r=(null==(p=i.context)?void 0:p.elements.domReference)===e.currentTarget,n=a&&!r?null==(g=i.context)?void 0:g.elements.domReference:o?l.current.find(e=>(null==e?void 0:e.id)===ge):null;n&&(M(e),n.dispatchEvent(t),ve(void 0))}var m;if((u||r)&&i.context&&i.context.open&&i.parentId&&e.currentTarget!==i.context.elements.domReference)return M(e),void(null==(m=i.context.elements.domReference)||m.dispatchEvent(t))}return Ae(e)}if(i||P||!t){if(h){const t=Jt(e.key,Se());re.current=f&&t?null:e.key}f?c&&(M(e),i?(ie.current=F(l,ue.current),J()):n(!0,e.nativeEvent,"list-navigation")):u&&(null!=d&&(ie.current=d),M(e),!i&&P?n(!0,e.nativeEvent,"list-navigation"):Ae(e),i&&J())}},onFocus(){i&&!y&&(ie.current=-1,J())},onPointerDown:t,onPointerEnter:t,onMouseDown:e,onClick:e}},[ge,Me,j,Ae,ue,S,l,f,J,n,i,P,N,Se,C,d,Z,y,$]);return r.useMemo(()=>h?{reference:_e,floating:Re,item:we}:{},[h,_e,Re,we])}const ni=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function si(e,t){var i,n;void 0===t&&(t={});const{open:s,elements:o,floatingId:a}=e,{enabled:l=!0,role:c="dialog"}=t,u=ke(),h=(null==(i=o.domReference)?void 0:i.id)||u,d=r.useMemo(()=>{var e;return(null==(e=E(o.floating))?void 0:e.id)||a},[o.floating,a]),p=null!=(n=ni.get(c))?n:c,g=null!=ze(),f=r.useMemo(()=>"tooltip"===p||"label"===c?{["aria-"+("label"===c?"labelledby":"describedby")]:s?d:void 0}:{"aria-expanded":s?"true":"false","aria-haspopup":"alertdialog"===p?"dialog":p,"aria-controls":s?d:void 0,..."listbox"===p&&{role:"combobox"},..."menu"===p&&{id:h},..."menu"===p&&g&&{role:"menuitem"},..."select"===c&&{"aria-autocomplete":"none"},..."combobox"===c&&{"aria-autocomplete":"list"}},[p,d,g,s,h,c]),m=r.useMemo(()=>{const e={id:d,...p&&{role:p}};return"tooltip"===p||"label"===c?e:{...e,..."menu"===p&&{"aria-labelledby":h}}},[p,d,h,c]),v=r.useCallback(e=>{let{active:t,selected:i}=e;const r={role:"option",...t&&{id:d+"-fui-option"}};switch(c){case"select":case"combobox":return{...r,"aria-selected":i}}return{}},[d,c]);return r.useMemo(()=>l?{reference:f,floating:m,item:v}:{},[l,f,m,v])}const oi=e=>e.replace(/[A-Z]+(?![a-z])|[A-Z]/g,(e,t)=>(t?"-":"")+e.toLowerCase());function ai(e,t){return"function"==typeof e?e(t):e}function li(e,t){void 0===t&&(t={});const{open:i,elements:{floating:n}}=e,{duration:s=250}=t,o=("number"==typeof s?s:s.close)||0,[a,l]=r.useState("unmounted"),c=function(e,t){const[i,n]=r.useState(e);return e&&!i&&n(!0),r.useEffect(()=>{if(!e&&i){const e=setTimeout(()=>n(!1),t);return()=>clearTimeout(e)}},[e,i,t]),i}(i,o);return c||"close"!==a||l("unmounted"),x(()=>{if(n){if(i){l("initial");const e=requestAnimationFrame(()=>{Z.flushSync(()=>{l("open")})});return()=>{cancelAnimationFrame(e)}}l("close")}},[i,n]),{isMounted:c,status:a}}function ci(e,t){void 0===t&&(t={});const{initial:i={opacity:0},open:n,close:s,common:o,duration:a=250}=t,l=e.placement,c=l.split("-")[0],u=r.useMemo(()=>({side:c,placement:l}),[c,l]),h="number"==typeof a,d=(h?a:a.open)||0,p=(h?a:a.close)||0,[g,f]=r.useState(()=>({...ai(o,u),...ai(i,u)})),{isMounted:m,status:v}=li(e,{duration:a}),C=D(i),y=D(n),w=D(s),S=D(o);return x(()=>{const e=ai(C.current,u),t=ai(w.current,u),i=ai(S.current,u),r=ai(y.current,u)||Object.keys(e).reduce((e,t)=>(e[t]="",e),{});if("initial"===v&&f(t=>({transitionProperty:t.transitionProperty,...i,...e})),"open"===v&&f({transitionProperty:Object.keys(r).map(oi).join(","),transitionDuration:d+"ms",...i,...r}),"close"===v){const r=t||e;f({transitionProperty:Object.keys(r).map(oi).join(","),transitionDuration:p+"ms",...i,...r})}},[p,w,C,y,S,d,v,u]),{isMounted:m,styles:g}}function ui(e,t){var i;const{open:n,dataRef:s}=e,{listRef:o,activeIndex:a,onMatch:l,onTypingChange:c,enabled:u=!0,findMatch:h=null,resetMs:d=750,ignoreKeys:p=[],selectedIndex:g=null}=t,f=r.useRef(-1),m=r.useRef(""),v=r.useRef(null!=(i=null!=g?g:a)?i:-1),C=r.useRef(null),y=L(l),w=L(c),S=D(h),b=D(p);x(()=>{n&&(qe(f),C.current=null,m.current="")},[n]),x(()=>{var e;n&&""===m.current&&(v.current=null!=(e=null!=g?g:a)?e:-1)},[n,g,a]);const E=L(e=>{e?s.current.typing||(s.current.typing=e,w(e)):s.current.typing&&(s.current.typing=e,w(e))}),A=L(e=>{function t(e,t,i){const r=S.current?S.current(t,i):t.find(e=>0===(null==e?void 0:e.toLocaleLowerCase().indexOf(i.toLocaleLowerCase())));return r?e.indexOf(r):-1}const i=o.current;if(m.current.length>0&&" "!==m.current[0]&&(-1===t(i,i,m.current)?E(!1):" "===e.key&&M(e)),null==i||b.current.includes(e.key)||1!==e.key.length||e.ctrlKey||e.metaKey||e.altKey)return;n&&" "!==e.key&&(M(e),E(!0)),i.every(e=>{var t,i;return!e||(null==(t=e[0])?void 0:t.toLocaleLowerCase())!==(null==(i=e[1])?void 0:i.toLocaleLowerCase())})&&m.current===e.key&&(m.current="",v.current=C.current),m.current+=e.key,qe(f),f.current=window.setTimeout(()=>{m.current="",v.current=C.current,E(!1)},d);const r=v.current,s=t(i,[...i.slice((r||0)+1),...i.slice(0,(r||0)+1)],m.current);-1!==s?(y(s),C.current=s):" "!==e.key&&(m.current="",E(!1))}),T=r.useMemo(()=>({onKeyDown:A}),[A]),R=r.useMemo(()=>({onKeyDown:A,onKeyUp(e){" "===e.key&&E(!1)}}),[A,E]);return r.useMemo(()=>u?{reference:T,floating:R}:{},[u,T,R])}function hi(e,t){return{...e,rects:{...e.rects,floating:{...e.rects.floating,height:t}}}}const di=e=>({name:"inner",options:e,async fn(t){const{listRef:i,overflowRef:r,onFallbackChange:n,offset:s=0,index:a=0,minItemsVisible:l=4,referenceOverflowThreshold:c=0,scrollRef:u,...h}=(0,o._3)(e,t),{rects:d,platform:p,elements:{floating:g}}=t,f=i.current[a],m=(null==u?void 0:u.current)||g,v=g.clientTop||m.clientTop,C=0!==g.clientTop,y=0!==m.clientTop,w=g===m;if(!f)return{};const S={...t,...await se(-f.offsetTop-g.clientTop-d.reference.height/2-f.offsetHeight/2-s).fn(t)},b=await p.detectOverflow(hi(S,m.scrollHeight+v+g.clientTop),h),E=await p.detectOverflow(S,{...h,elementContext:"reference"}),A=(0,o.T9)(0,b.top),T=S.y+A,M=(m.scrollHeight>m.clientHeight?e=>e:o.LI)((0,o.T9)(0,m.scrollHeight+(C&&w||y?2*v:0)-A-(0,o.T9)(0,b.bottom)));if(m.style.maxHeight=M+"px",m.scrollTop=A,n){const e=m.offsetHeight<f.offsetHeight*(0,o.jk)(l,i.current.length)-1||E.top>=-c||E.bottom>=-c;Z.flushSync(()=>n(e))}return r&&(r.current=await p.detectOverflow(hi({...S,y:T},m.offsetHeight+v+g.clientTop),h)),{y:T}}});function pi(e,t){const{open:i,elements:n}=e,{enabled:s=!0,overflowRef:o,scrollRef:a,onChange:l}=t,u=L(l),h=r.useRef(!1),d=r.useRef(null),p=r.useRef(null);r.useEffect(()=>{if(!s)return;function e(e){if(e.ctrlKey||!t||null==o.current)return;const i=e.deltaY,r=o.current.top>=-.5,n=o.current.bottom>=-.5,s=t.scrollHeight-t.clientHeight,a=i<0?-1:1,l=i<0?"max":"min";t.scrollHeight<=t.clientHeight||(!r&&i>0||!n&&i<0?(e.preventDefault(),Z.flushSync(()=>{u(e=>e+Math[l](i,s*a))})):/firefox/i.test(c())&&(t.scrollTop+=i))}const t=(null==a?void 0:a.current)||n.floating;return i&&t?(t.addEventListener("wheel",e),requestAnimationFrame(()=>{d.current=t.scrollTop,null!=o.current&&(p.current={...o.current})}),()=>{d.current=null,p.current=null,t.removeEventListener("wheel",e)}):void 0},[s,i,n.floating,o,a,u]);const g=r.useMemo(()=>({onKeyDown(){h.current=!0},onWheel(){h.current=!1},onPointerMove(){h.current=!1},onScroll(){const e=(null==a?void 0:a.current)||n.floating;if(o.current&&e&&h.current){if(null!==d.current){const t=e.scrollTop-d.current;(o.current.bottom<-.5&&t<-1||o.current.top<-.5&&t>1)&&Z.flushSync(()=>u(e=>e+t))}requestAnimationFrame(()=>{d.current=e.scrollTop})}}}),[n.floating,u,o,a]);return r.useMemo(()=>s?{floating:g}:{},[s,g])}function gi(e,t,i){return void 0===i&&(i=!0),e.filter(e=>{var r;return e.parentId===t&&(!i||(null==(r=e.context)?void 0:r.open))}).flatMap(t=>[t,...gi(e,t.id,i)])}function fi(e,t){const[i,r]=e;let n=!1;const s=t.length;for(let e=0,o=s-1;e<s;o=e++){const[s,a]=t[e]||[0,0],[l,c]=t[o]||[0,0];a>=r!=c>=r&&i<=(l-s)*(r-a)/(c-a)+s&&(n=!n)}return n}function mi(e){void 0===e&&(e={});const{buffer:t=.5,blockPointerEvents:i=!1,requireIntent:r=!0}=e,n={current:-1};let o=!1,a=null,l=null,c="undefined"!=typeof performance?performance.now():0;const u=e=>{let{x:i,y:u,placement:h,elements:d,onClose:p,nodeId:g,tree:f}=e;return function(e){function m(){qe(n),p()}if(qe(n),!d.domReference||!d.floating||null==h||null==i||null==u)return;const{clientX:v,clientY:C}=e,y=[v,C],w=function(e){return"composedPath"in e?e.composedPath()[0]:e.target}(e),S="mouseleave"===e.type,b=ct(d.floating,w),E=ct(d.domReference,w),A=d.domReference.getBoundingClientRect(),T=d.floating.getBoundingClientRect(),M=h.split("-")[0],R=i>T.right-T.width/2,_=u>T.bottom-T.height/2,P=function(e,t){return e[0]>=t.x&&e[0]<=t.x+t.width&&e[1]>=t.y&&e[1]<=t.y+t.height}(y,A),x=T.width>A.width,D=T.height>A.height,I=(x?A:T).left,L=(x?A:T).right,N=(D?A:T).top,O=(D?A:T).bottom;if(b&&(o=!0,!S))return;if(E&&(o=!1),E&&!S)return void(o=!0);if(S&&(0,s.vq)(e.relatedTarget)&&ct(d.floating,e.relatedTarget))return;if(f&&gi(f.nodesRef.current,g).length)return;if("top"===M&&u>=A.bottom-1||"bottom"===M&&u<=A.top+1||"left"===M&&i>=A.right-1||"right"===M&&i<=A.left+1)return m();let F=[];switch(M){case"top":F=[[I,A.top+1],[I,T.bottom-1],[L,T.bottom-1],[L,A.top+1]];break;case"bottom":F=[[I,T.top+1],[I,A.bottom-1],[L,A.bottom-1],[L,T.top+1]];break;case"left":F=[[T.right-1,O],[T.right-1,N],[A.left+1,N],[A.left+1,O]];break;case"right":F=[[A.right-1,O],[A.right-1,N],[T.left+1,N],[T.left+1,O]]}if(!fi([v,C],F)){if(o&&!P)return m();if(!S&&r){const t=function(e,t){const i=performance.now(),r=i-c;if(null===a||null===l||0===r)return a=e,l=t,c=i,null;const n=e-a,s=t-l,o=Math.sqrt(n*n+s*s);return a=e,l=t,c=i,o/r}(e.clientX,e.clientY);if(null!==t&&t<.1)return m()}fi([v,C],function(e){let[i,r]=e;switch(M){case"top":return[[x?i+t/2:R?i+4*t:i-4*t,r+t+1],[x?i-t/2:R?i+4*t:i-4*t,r+t+1],[T.left,R||x?T.bottom-t:T.top],[T.right,R?x?T.bottom-t:T.top:T.bottom-t]];case"bottom":return[[x?i+t/2:R?i+4*t:i-4*t,r-t],[x?i-t/2:R?i+4*t:i-4*t,r-t],[T.left,R||x?T.top+t:T.bottom],[T.right,R?x?T.top+t:T.bottom:T.top+t]];case"left":{const e=[i+t+1,D?r+t/2:_?r+4*t:r-4*t],n=[i+t+1,D?r-t/2:_?r+4*t:r-4*t];return[[_||D?T.right-t:T.left,T.top],[_?D?T.right-t:T.left:T.right-t,T.bottom],e,n]}case"right":return[[i-t,D?r+t/2:_?r+4*t:r-4*t],[i-t,D?r-t/2:_?r+4*t:r-4*t],[_||D?T.left+t:T.right,T.top],[_?D?T.left+t:T.right:T.left+t,T.bottom]]}}([i,u]))?!o&&r&&(n.current=window.setTimeout(m,40)):m()}}};return u.__options={blockPointerEvents:i},u}},57735(e,t,i){"use strict";var r;i.r(t),i.d(t,{activeElement:()=>v,contains:()=>C,createGridCellMap:()=>j,disableFocusInside:()=>ee,enableFocusInside:()=>te,findNonDisabledListIndex:()=>U,getDeepestNode:()=>_,getDocument:()=>b,getFloatingFocusElement:()=>M,getGridCellIndexOfCorner:()=>K,getGridCellIndices:()=>$,getGridNavigatedIndex:()=>W,getMaxListIndex:()=>z,getMinListIndex:()=>B,getNextTabbable:()=>X,getNodeAncestors:()=>P,getNodeChildren:()=>R,getPlatform:()=>l,getPreviousTabbable:()=>Z,getTabbableOptions:()=>Y,getTarget:()=>y,getUserAgent:()=>c,isAndroid:()=>h,isDifferentGridRow:()=>V,isEventTargetWithin:()=>w,isIndexOutOfListBounds:()=>H,isJSDOM:()=>p,isListIndexDisabled:()=>q,isMac:()=>d,isMouseLikePointerType:()=>N,isOutsideEvent:()=>J,isReactEvent:()=>D,isRootElement:()=>S,isSafari:()=>u,isTypeableCombobox:()=>A,isTypeableElement:()=>E,isVirtualClick:()=>I,isVirtualPointerEvent:()=>L,matchesFocusVisible:()=>T,stopEvent:()=>x,useEffectEvent:()=>G,useLatestRef:()=>F,useModernLayoutEffect:()=>O});var n=i(32125),s=i(22155),o=i(51771),a=i(86668);function l(){const e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}function c(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map(e=>{let{brand:t,version:i}=e;return t+"/"+i}).join(" "):navigator.userAgent}function u(){return/apple/i.test(navigator.vendor)}function h(){const e=/android/i;return e.test(l())||e.test(c())}function d(){return l().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints}function p(){return c().includes("jsdom/")}const g="data-floating-ui-focusable",f="ArrowLeft",m="ArrowRight";function v(e){let t=e.activeElement;for(;null!=(null==(i=t)||null==(i=i.shadowRoot)?void 0:i.activeElement);){var i;t=t.shadowRoot.activeElement}return t}function C(e,t){if(!e||!t)return!1;const i=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(i&&(0,n.Ng)(i)){let i=t;for(;i;){if(e===i)return!0;i=i.parentNode||i.host}}return!1}function y(e){return"composedPath"in e?e.composedPath()[0]:e.target}function w(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const i=e;return null!=i.target&&t.contains(i.target)}function S(e){return e.matches("html,body")}function b(e){return(null==e?void 0:e.ownerDocument)||document}function E(e){return(0,n.sb)(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}function A(e){return!!e&&"combobox"===e.getAttribute("role")&&E(e)}function T(e){if(!e||p())return!0;try{return e.matches(":focus-visible")}catch(e){return!0}}function M(e){return e?e.hasAttribute(g)?e:e.querySelector("["+g+"]")||e:null}function R(e,t,i){return void 0===i&&(i=!0),e.filter(e=>{var r;return e.parentId===t&&(!i||(null==(r=e.context)?void 0:r.open))}).flatMap(t=>[t,...R(e,t.id,i)])}function _(e,t){let i,r=-1;return function t(n,s){s>r&&(i=n,r=s),R(e,n).forEach(e=>{t(e.id,s+1)})}(t,0),e.find(e=>e.id===i)}function P(e,t){var i;let r=[],n=null==(i=e.find(e=>e.id===t))?void 0:i.parentId;for(;n;){const t=e.find(e=>e.id===n);n=null==t?void 0:t.parentId,t&&(r=r.concat(t))}return r}function x(e){e.preventDefault(),e.stopPropagation()}function D(e){return"nativeEvent"in e}function I(e){return!(0!==e.mozInputSource||!e.isTrusted)||(h()&&e.pointerType?"click"===e.type&&1===e.buttons:0===e.detail&&!e.pointerType)}function L(e){return!p()&&(!h()&&0===e.width&&0===e.height||h()&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)}function N(e,t){const i=["mouse","pen"];return t||i.push("",void 0),i.includes(e)}var O="undefined"!=typeof document?s.useLayoutEffect:function(){};function F(e){const t=s.useRef(e);return O(()=>{t.current=e}),t}const k={...r||(r=i.t(s,2))}.useInsertionEffect||(e=>e());function G(e){const t=s.useRef(()=>{});return k(()=>{t.current=e}),s.useCallback(function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];return null==t.current?void 0:t.current(...i)},[])}function V(e,t,i){return Math.floor(e/t)!==i}function H(e,t){return t<0||t>=e.current.length}function B(e,t){return U(e,{disabledIndices:t})}function z(e,t){return U(e,{decrement:!0,startingIndex:e.current.length,disabledIndices:t})}function U(e,t){let{startingIndex:i=-1,decrement:r=!1,disabledIndices:n,amount:s=1}=void 0===t?{}:t,o=i;do{o+=r?-s:s}while(o>=0&&o<=e.current.length-1&&q(e,o,n));return o}function W(e,t){let{event:i,orientation:r,loop:n,rtl:s,cols:a,disabledIndices:l,minIndex:c,maxIndex:u,prevIndex:h,stopEvent:d=!1}=t,p=h;if("ArrowUp"===i.key){if(d&&x(i),-1===h)p=u;else if(p=U(e,{startingIndex:p,amount:a,decrement:!0,disabledIndices:l}),n&&(h-a<c||p<0)){const e=h%a,t=u%a,i=u-(t-e);p=t===e?u:t>e?i:i-a}H(e,p)&&(p=h)}if("ArrowDown"===i.key&&(d&&x(i),-1===h?p=c:(p=U(e,{startingIndex:h,amount:a,disabledIndices:l}),n&&h+a>u&&(p=U(e,{startingIndex:h%a-a,amount:a,disabledIndices:l}))),H(e,p)&&(p=h)),"both"===r){const t=(0,o.RI)(h/a);i.key===(s?f:m)&&(d&&x(i),h%a!==a-1?(p=U(e,{startingIndex:h,disabledIndices:l}),n&&V(p,a,t)&&(p=U(e,{startingIndex:h-h%a-1,disabledIndices:l}))):n&&(p=U(e,{startingIndex:h-h%a-1,disabledIndices:l})),V(p,a,t)&&(p=h)),i.key===(s?m:f)&&(d&&x(i),h%a!==0?(p=U(e,{startingIndex:h,decrement:!0,disabledIndices:l}),n&&V(p,a,t)&&(p=U(e,{startingIndex:h+(a-h%a),decrement:!0,disabledIndices:l}))):n&&(p=U(e,{startingIndex:h+(a-h%a),decrement:!0,disabledIndices:l})),V(p,a,t)&&(p=h));const r=(0,o.RI)(u/a)===t;H(e,p)&&(p=n&&r?i.key===(s?m:f)?u:U(e,{startingIndex:h-h%a-1,disabledIndices:l}):h)}return p}function j(e,t,i){const r=[];let n=0;return e.forEach((e,s)=>{let{width:o,height:a}=e,l=!1;for(i&&(n=0);!l;){const e=[];for(let i=0;i<o;i++)for(let r=0;r<a;r++)e.push(n+i+r*t);n%t+o<=t&&e.every(e=>null==r[e])?(e.forEach(e=>{r[e]=s}),l=!0):n++}}),[...r]}function K(e,t,i,r,n){if(-1===e)return-1;const s=i.indexOf(e),o=t[e];switch(n){case"tl":return s;case"tr":return o?s+o.width-1:s;case"bl":return o?s+(o.height-1)*r:s;case"br":return i.lastIndexOf(e)}}function $(e,t){return t.flatMap((t,i)=>e.includes(t)?[i]:[])}function q(e,t,i){if("function"==typeof i)return i(t);if(i)return i.includes(t);const r=e.current[t];return null==r||r.hasAttribute("disabled")||"true"===r.getAttribute("aria-disabled")}const Y=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function Q(e,t){const i=(0,a.Kr)(e,Y()),r=i.length;if(0===r)return;const n=v(b(e)),s=i.indexOf(n);return i[-1===s?1===t?0:r-1:s+t]}function X(e){return Q(b(e).body,1)||e}function Z(e){return Q(b(e).body,-1)||e}function J(e,t){const i=t||e.currentTarget,r=e.relatedTarget;return!r||!C(i,r)}function ee(e){(0,a.Kr)(e,Y()).forEach(e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")})}function te(e){e.querySelectorAll("[data-tabindex]").forEach(e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")})}},31924(e,t,i){"use strict";i.r(t),i.d(t,{alignments:()=>n,clamp:()=>d,createCoords:()=>u,evaluate:()=>p,expandPaddingObject:()=>P,floor:()=>c,getAlignment:()=>f,getAlignmentAxis:()=>y,getAlignmentSides:()=>w,getAxisLength:()=>v,getExpandedPlacements:()=>S,getOppositeAlignmentPlacement:()=>b,getOppositeAxis:()=>m,getOppositeAxisPlacements:()=>R,getOppositePlacement:()=>_,getPaddingObject:()=>x,getSide:()=>g,getSideAxis:()=>C,max:()=>a,min:()=>o,placements:()=>s,rectToClientRect:()=>D,round:()=>l,sides:()=>r});const r=["top","right","bottom","left"],n=["start","end"],s=r.reduce((e,t)=>e.concat(t,t+"-"+n[0],t+"-"+n[1]),[]),o=Math.min,a=Math.max,l=Math.round,c=Math.floor,u=e=>({x:e,y:e}),h={left:"right",right:"left",bottom:"top",top:"bottom"};function d(e,t,i){return a(e,o(t,i))}function p(e,t){return"function"==typeof e?e(t):e}function g(e){return e.split("-")[0]}function f(e){return e.split("-")[1]}function m(e){return"x"===e?"y":"x"}function v(e){return"y"===e?"height":"width"}function C(e){const t=e[0];return"t"===t||"b"===t?"y":"x"}function y(e){return m(C(e))}function w(e,t,i){void 0===i&&(i=!1);const r=f(e),n=y(e),s=v(n);let o="x"===n?r===(i?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[s]>t.floating[s]&&(o=_(o)),[o,_(o)]}function S(e){const t=_(e);return[b(e),t,b(t)]}function b(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const E=["left","right"],A=["right","left"],T=["top","bottom"],M=["bottom","top"];function R(e,t,i,r){const n=f(e);let s=function(e,t,i){switch(e){case"top":case"bottom":return i?t?A:E:t?E:A;case"left":case"right":return t?T:M;default:return[]}}(g(e),"start"===i,r);return n&&(s=s.map(e=>e+"-"+n),t&&(s=s.concat(s.map(b)))),s}function _(e){const t=g(e);return h[t]+e.slice(t.length)}function P(e){return{top:0,right:0,bottom:0,left:0,...e}}function x(e){return"number"!=typeof e?P(e):{top:e,right:e,bottom:e,left:e}}function D(e){const{x:t,y:i,width:r,height:n}=e;return{width:r,height:n,top:i,left:t,right:t+r,bottom:i+n,x:t,y:i}}},3704(e,t,i){"use strict";function r(e,t,i){if(void 0===i&&(i=Error),!e)throw new i(t)}i.d(t,{V1:()=>r})},59556(e,t,i){"use strict";function r(e,t){var i=t&&t.cache?t.cache:u,r=t&&t.serializer?t.serializer:l;return(t&&t.strategy?t.strategy:a)(e,{cache:i,serializer:r})}function n(e,t,i,r){var n,s=null==(n=r)||"number"==typeof n||"boolean"==typeof n?r:i(r),o=t.get(s);return void 0===o&&(o=e.call(this,r),t.set(s,o)),o}function s(e,t,i){var r=Array.prototype.slice.call(arguments,3),n=i(r),s=t.get(n);return void 0===s&&(s=e.apply(this,r),t.set(n,s)),s}function o(e,t,i,r,n){return i.bind(t,e,r,n)}function a(e,t){return o(e,this,1===e.length?n:s,t.cache.create(),t.serializer)}i.d(t,{A:()=>r,W:()=>h});var l=function(){return JSON.stringify(arguments)};function c(){this.cache=Object.create(null)}c.prototype.get=function(e){return this.cache[e]},c.prototype.set=function(e,t){this.cache[e]=t};var u={create:function(){return new c}},h={variadic:function(e,t){return o(e,this,s,t.cache.create(),t.serializer)},monadic:function(e,t){return o(e,this,n,t.cache.create(),t.serializer)}}},9991(e,t,i){"use strict";function r(e,t){var i=t&&t.cache?t.cache:u,r=t&&t.serializer?t.serializer:l;return(t&&t.strategy?t.strategy:a)(e,{cache:i,serializer:r})}function n(e,t,i,r){var n,s=null==(n=r)||"number"==typeof n||"boolean"==typeof n?r:i(r),o=t.get(s);return void 0===o&&(o=e.call(this,r),t.set(s,o)),o}function s(e,t,i){var r=Array.prototype.slice.call(arguments,3),n=i(r),s=t.get(n);return void 0===s&&(s=e.apply(this,r),t.set(n,s)),s}function o(e,t,i,r,n){return i.bind(t,e,r,n)}function a(e,t){return o(e,this,1===e.length?n:s,t.cache.create(),t.serializer)}i.d(t,{B:()=>r,W:()=>h});var l=function(){return JSON.stringify(arguments)},c=function(){function e(){this.cache=Object.create(null)}return e.prototype.get=function(e){return this.cache[e]},e.prototype.set=function(e,t){this.cache[e]=t},e}(),u={create:function(){return new c}},h={variadic:function(e,t){return o(e,this,s,t.cache.create(),t.serializer)},monadic:function(e,t){return o(e,this,n,t.cache.create(),t.serializer)}}},26140(e,t,i){"use strict";i.d(t,{ZE:()=>n,Im:()=>l,tv:()=>u,Tu:()=>v,eW:()=>a,oF:()=>c,N1:()=>m,N6:()=>p,jA:()=>g,Jp:()=>d,xm:()=>f,Qh:()=>h,qg:()=>ae});var r,n,s,o=i(65959);function a(e){return e.type===n.literal}function l(e){return e.type===n.argument}function c(e){return e.type===n.number}function u(e){return e.type===n.date}function h(e){return e.type===n.time}function d(e){return e.type===n.select}function p(e){return e.type===n.plural}function g(e){return e.type===n.pound}function f(e){return e.type===n.tag}function m(e){return!(!e||"object"!=typeof e||e.type!==s.number)}function v(e){return!(!e||"object"!=typeof e||e.type!==s.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(r||(r={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(n||(n={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(s||(s={}));var C=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,y=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function w(e){var t={};return e.replace(y,function(e){var i=e.length;switch(e[0]){case"G":t.era=4===i?"long":5===i?"narrow":"short";break;case"y":t.year=2===i?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][i-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][i-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===i?"short":5===i?"narrow":"short";break;case"e":if(i<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][i-4];break;case"c":if(i<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][i-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][i-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][i-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][i-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][i-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][i-1];break;case"s":t.second=["numeric","2-digit"][i-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=i<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var S=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function b(e){return e.replace(/^(.*?)-/,"")}var E=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,A=/^(@+)?(\+|#+)?[rs]?$/g,T=/(\*)(0+)|(#+)(0+)|(0+)/g,M=/^(0+)$/;function R(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(A,function(e,i,r){return"string"!=typeof r?(t.minimumSignificantDigits=i.length,t.maximumSignificantDigits=i.length):"+"===r?t.minimumSignificantDigits=i.length:"#"===i[0]?t.maximumSignificantDigits=i.length:(t.minimumSignificantDigits=i.length,t.maximumSignificantDigits=i.length+("string"==typeof r?r.length:0)),""}),t}function _(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function P(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var i=e.slice(0,2);if("+!"===i?(t.signDisplay="always",e=e.slice(2)):"+?"===i&&(t.signDisplay="exceptZero",e=e.slice(2)),!M.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function x(e){return _(e)||{}}function D(e){for(var t={},i=0,r=e;i<r.length;i++){var n=r[i];switch(n.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=n.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=b(n.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=(0,o.__assign)((0,o.__assign)((0,o.__assign)({},t),{notation:"scientific"}),n.options.reduce(function(e,t){return(0,o.__assign)((0,o.__assign)({},e),x(t))},{}));continue;case"engineering":t=(0,o.__assign)((0,o.__assign)((0,o.__assign)({},t),{notation:"engineering"}),n.options.reduce(function(e,t){return(0,o.__assign)((0,o.__assign)({},e),x(t))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(n.options[0]);continue;case"integer-width":if(n.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");n.options[0].replace(T,function(e,i,r,n,s,o){if(i)t.minimumIntegerDigits=r.length;else{if(n&&s)throw new Error("We currently do not support maximum integer digits");if(o)throw new Error("We currently do not support exact integer digits")}return""});continue}if(M.test(n.stem))t.minimumIntegerDigits=n.stem.length;else if(E.test(n.stem)){if(n.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");n.stem.replace(E,function(e,i,r,n,s,o){return"*"===r?t.minimumFractionDigits=i.length:n&&"#"===n[0]?t.maximumFractionDigits=n.length:s&&o?(t.minimumFractionDigits=s.length,t.maximumFractionDigits=s.length+o.length):(t.minimumFractionDigits=i.length,t.maximumFractionDigits=i.length),""});var s=n.options[0];"w"===s?t=(0,o.__assign)((0,o.__assign)({},t),{trailingZeroDisplay:"stripIfInteger"}):s&&(t=(0,o.__assign)((0,o.__assign)({},t),R(s)))}else if(A.test(n.stem))t=(0,o.__assign)((0,o.__assign)({},t),R(n.stem));else{var a=_(n.stem);a&&(t=(0,o.__assign)((0,o.__assign)({},t),a));var l=P(n.stem);l&&(t=(0,o.__assign)((0,o.__assign)({},t),l))}}return t}var I,L={AX:["H"],BQ:["H"],CP:["H"],CZ:["H"],DK:["H"],FI:["H"],ID:["H"],IS:["H"],ML:["H"],NE:["H"],RU:["H"],SE:["H"],SJ:["H"],SK:["H"],AS:["h","H"],BT:["h","H"],DJ:["h","H"],ER:["h","H"],GH:["h","H"],IN:["h","H"],LS:["h","H"],PG:["h","H"],PW:["h","H"],SO:["h","H"],TO:["h","H"],VU:["h","H"],WS:["h","H"],"001":["H","h"],AL:["h","H","hB"],TD:["h","H","hB"],"ca-ES":["H","h","hB"],CF:["H","h","hB"],CM:["H","h","hB"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],LU:["H","h","hB"],NP:["H","h","hB"],PF:["H","h","hB"],SC:["H","h","hB"],SM:["H","h","hB"],SN:["H","h","hB"],TF:["H","h","hB"],VA:["H","h","hB"],CY:["h","H","hb","hB"],GR:["h","H","hb","hB"],CO:["h","H","hB","hb"],DO:["h","H","hB","hb"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],NA:["h","H","hB","hb"],PA:["h","H","hB","hb"],PR:["h","H","hB","hb"],VE:["h","H","hB","hb"],AC:["H","h","hb","hB"],AI:["H","h","hb","hB"],BW:["H","h","hb","hB"],BZ:["H","h","hb","hB"],CC:["H","h","hb","hB"],CK:["H","h","hb","hB"],CX:["H","h","hb","hB"],DG:["H","h","hb","hB"],FK:["H","h","hb","hB"],GB:["H","h","hb","hB"],GG:["H","h","hb","hB"],GI:["H","h","hb","hB"],IE:["H","h","hb","hB"],IM:["H","h","hb","hB"],IO:["H","h","hb","hB"],JE:["H","h","hb","hB"],LT:["H","h","hb","hB"],MK:["H","h","hb","hB"],MN:["H","h","hb","hB"],MS:["H","h","hb","hB"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],PN:["H","h","hb","hB"],SH:["H","h","hb","hB"],SX:["H","h","hb","hB"],TA:["H","h","hb","hB"],ZA:["H","h","hb","hB"],"af-ZA":["H","h","hB","hb"],AR:["H","h","hB","hb"],CL:["H","h","hB","hb"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],EA:["H","h","hB","hb"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],GT:["H","h","hB","hb"],HN:["H","h","hB","hb"],IC:["H","h","hB","hb"],KG:["H","h","hB","hb"],KM:["H","h","hB","hb"],LK:["H","h","hB","hb"],MA:["H","h","hB","hb"],MX:["H","h","hB","hb"],NI:["H","h","hB","hb"],PY:["H","h","hB","hb"],SV:["H","h","hB","hb"],UY:["H","h","hB","hb"],JP:["H","h","K"],AD:["H","hB"],AM:["H","hB"],AO:["H","hB"],AT:["H","hB"],AW:["H","hB"],BE:["H","hB"],BF:["H","hB"],BJ:["H","hB"],BL:["H","hB"],BR:["H","hB"],CG:["H","hB"],CI:["H","hB"],CV:["H","hB"],DE:["H","hB"],EE:["H","hB"],FR:["H","hB"],GA:["H","hB"],GF:["H","hB"],GN:["H","hB"],GP:["H","hB"],GW:["H","hB"],HR:["H","hB"],IL:["H","hB"],IT:["H","hB"],KZ:["H","hB"],MC:["H","hB"],MD:["H","hB"],MF:["H","hB"],MQ:["H","hB"],MZ:["H","hB"],NC:["H","hB"],NL:["H","hB"],PM:["H","hB"],PT:["H","hB"],RE:["H","hB"],RO:["H","hB"],SI:["H","hB"],SR:["H","hB"],ST:["H","hB"],TG:["H","hB"],TR:["H","hB"],WF:["H","hB"],YT:["H","hB"],BD:["h","hB","H"],PK:["h","hB","H"],AZ:["H","hB","h"],BA:["H","hB","h"],BG:["H","hB","h"],CH:["H","hB","h"],GE:["H","hB","h"],LI:["H","hB","h"],ME:["H","hB","h"],RS:["H","hB","h"],UA:["H","hB","h"],UZ:["H","hB","h"],XK:["H","hB","h"],AG:["h","hb","H","hB"],AU:["h","hb","H","hB"],BB:["h","hb","H","hB"],BM:["h","hb","H","hB"],BS:["h","hb","H","hB"],CA:["h","hb","H","hB"],DM:["h","hb","H","hB"],"en-001":["h","hb","H","hB"],FJ:["h","hb","H","hB"],FM:["h","hb","H","hB"],GD:["h","hb","H","hB"],GM:["h","hb","H","hB"],GU:["h","hb","H","hB"],GY:["h","hb","H","hB"],JM:["h","hb","H","hB"],KI:["h","hb","H","hB"],KN:["h","hb","H","hB"],KY:["h","hb","H","hB"],LC:["h","hb","H","hB"],LR:["h","hb","H","hB"],MH:["h","hb","H","hB"],MP:["h","hb","H","hB"],MW:["h","hb","H","hB"],NZ:["h","hb","H","hB"],SB:["h","hb","H","hB"],SG:["h","hb","H","hB"],SL:["h","hb","H","hB"],SS:["h","hb","H","hB"],SZ:["h","hb","H","hB"],TC:["h","hb","H","hB"],TT:["h","hb","H","hB"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],VC:["h","hb","H","hB"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],ZM:["h","hb","H","hB"],BO:["H","hB","h","hb"],EC:["H","hB","h","hb"],ES:["H","hB","h","hb"],GQ:["H","hB","h","hb"],PE:["H","hB","h","hb"],AE:["h","hB","hb","H"],"ar-001":["h","hB","hb","H"],BH:["h","hB","hb","H"],DZ:["h","hB","hb","H"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],HK:["h","hB","hb","H"],IQ:["h","hB","hb","H"],JO:["h","hB","hb","H"],KW:["h","hB","hb","H"],LB:["h","hB","hb","H"],LY:["h","hB","hb","H"],MO:["h","hB","hb","H"],MR:["h","hB","hb","H"],OM:["h","hB","hb","H"],PH:["h","hB","hb","H"],PS:["h","hB","hb","H"],QA:["h","hB","hb","H"],SA:["h","hB","hb","H"],SD:["h","hB","hb","H"],SY:["h","hB","hb","H"],TN:["h","hB","hb","H"],YE:["h","hB","hb","H"],AF:["H","hb","hB","h"],LA:["H","hb","hB","h"],CN:["H","hB","hb","h"],LV:["H","hB","hb","h"],TL:["H","hB","hb","h"],"zu-ZA":["H","hB","hb","h"],CD:["hB","H"],IR:["hB","H"],"hi-IN":["hB","h","H"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"te-IN":["hB","h","H"],KH:["hB","h","H","hb"],"ta-IN":["hB","h","hb","H"],BN:["hb","hB","h","H"],MY:["hb","hB","h","H"],ET:["hB","hb","h","H"],"gu-IN":["hB","hb","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],TW:["hB","hb","h","H"],KE:["hB","hb","H","h"],MM:["hB","hb","H","h"],TZ:["hB","hb","H","h"],UG:["hB","hb","H","h"]};function N(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var i,r=e.language;return"root"!==r&&(i=e.maximize().region),(L[i||""]||L[r||""]||L["".concat(r,"-001")]||L["001"])[0]}var O=new RegExp("^".concat(C.source,"*")),F=new RegExp("".concat(C.source,"*$"));function k(e,t){return{start:e,end:t}}var G=!!String.prototype.startsWith,V=!!String.fromCodePoint,H=!!Object.fromEntries,B=!!String.prototype.codePointAt,z=!!String.prototype.trimStart,U=!!String.prototype.trimEnd,W=Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},j=!0;try{j="a"===(null===(I=J("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===I?void 0:I[0])}catch(e){j=!1}var K,$=G?function(e,t,i){return e.startsWith(t,i)}:function(e,t,i){return e.slice(i,i+t.length)===t},q=V?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var i,r="",n=e.length,s=0;n>s;){if((i=e[s++])>1114111)throw RangeError(i+" is not a valid code point");r+=i<65536?String.fromCharCode(i):String.fromCharCode(55296+((i-=65536)>>10),i%1024+56320)}return r},Y=H?Object.fromEntries:function(e){for(var t={},i=0,r=e;i<r.length;i++){var n=r[i],s=n[0],o=n[1];t[s]=o}return t},Q=B?function(e,t){return e.codePointAt(t)}:function(e,t){var i=e.length;if(!(t<0||t>=i)){var r,n=e.charCodeAt(t);return n<55296||n>56319||t+1===i||(r=e.charCodeAt(t+1))<56320||r>57343?n:r-56320+(n-55296<<10)+65536}},X=z?function(e){return e.trimStart()}:function(e){return e.replace(O,"")},Z=U?function(e){return e.trimEnd()}:function(e){return e.replace(F,"")};function J(e,t){return new RegExp(e,t)}if(j){var ee=J("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");K=function(e,t){var i;return ee.lastIndex=t,null!==(i=ee.exec(e)[1])&&void 0!==i?i:""}}else K=function(e,t){for(var i=[];;){var r=Q(e,t);if(void 0===r||ne(r)||se(r))break;i.push(r),t+=r>=65536?2:1}return q.apply(void 0,i)};var te=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,i){for(var s=[];!this.isEOF();){var o=this.char();if(123===o){if((a=this.parseArgument(e,i)).err)return a;s.push(a.val)}else{if(125===o&&e>0)break;if(35!==o||"plural"!==t&&"selectordinal"!==t){if(60===o&&!this.ignoreTag&&47===this.peek()){if(i)break;return this.error(r.UNMATCHED_CLOSING_TAG,k(this.clonePosition(),this.clonePosition()))}if(60===o&&!this.ignoreTag&&ie(this.peek()||0)){if((a=this.parseTag(e,t)).err)return a;s.push(a.val)}else{var a;if((a=this.parseLiteral(e,t)).err)return a;s.push(a.val)}}else{var l=this.clonePosition();this.bump(),s.push({type:n.pound,location:k(l,this.clonePosition())})}}}return{val:s,err:null}},e.prototype.parseTag=function(e,t){var i=this.clonePosition();this.bump();var s=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:n.literal,value:"<".concat(s,"/>"),location:k(i,this.clonePosition())},err:null};if(this.bumpIf(">")){var o=this.parseMessage(e+1,t,!0);if(o.err)return o;var a=o.val,l=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!ie(this.char()))return this.error(r.INVALID_TAG,k(l,this.clonePosition()));var c=this.clonePosition();return s!==this.parseTagName()?this.error(r.UNMATCHED_CLOSING_TAG,k(c,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:n.tag,value:s,children:a,location:k(i,this.clonePosition())},err:null}:this.error(r.INVALID_TAG,k(l,this.clonePosition())))}return this.error(r.UNCLOSED_TAG,k(i,this.clonePosition()))}return this.error(r.INVALID_TAG,k(i,this.clonePosition()))},e.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&re(this.char());)this.bump();return this.message.slice(e,this.offset())},e.prototype.parseLiteral=function(e,t){for(var i=this.clonePosition(),r="";;){var s=this.tryParseQuote(t);if(s)r+=s;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var a=this.tryParseLeftAngleBracket();if(!a)break;r+=a}}}var l=k(i,this.clonePosition());return{val:{type:n.literal,value:r,location:l},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(ie(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var i=this.char();if(39===i){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(i);this.bump()}return q.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var i=this.char();return 60===i||123===i||35===i&&("plural"===t||"selectordinal"===t)||125===i&&e>0?null:(this.bump(),q(i))},e.prototype.parseArgument=function(e,t){var i=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition()));if(125===this.char())return this.bump(),this.error(r.EMPTY_ARGUMENT,k(i,this.clonePosition()));var s=this.parseIdentifierIfPossible().value;if(!s)return this.error(r.MALFORMED_ARGUMENT,k(i,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:n.argument,value:s,location:k(i,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition())):this.parseArgumentOptions(e,t,s,i);default:return this.error(r.MALFORMED_ARGUMENT,k(i,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),i=K(this.message,t),r=t+i.length;return this.bumpTo(r),{value:i,location:k(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,i,a){var l,c=this.clonePosition(),u=this.parseIdentifierIfPossible().value,h=this.clonePosition();switch(u){case"":return this.error(r.EXPECT_ARGUMENT_TYPE,k(c,h));case"number":case"date":case"time":this.bumpSpace();var d=null;if(this.bumpIf(",")){this.bumpSpace();var p=this.clonePosition();if((b=this.parseSimpleArgStyleIfPossible()).err)return b;if(0===(v=Z(b.val)).length)return this.error(r.EXPECT_ARGUMENT_STYLE,k(this.clonePosition(),this.clonePosition()));d={style:v,styleLocation:k(p,this.clonePosition())}}if((E=this.tryParseArgumentClose(a)).err)return E;var g=k(a,this.clonePosition());if(d&&$(null==d?void 0:d.style,"::",0)){var f=X(d.style.slice(2));if("number"===u)return(b=this.parseNumberSkeletonFromString(f,d.styleLocation)).err?b:{val:{type:n.number,value:i,location:g,style:b.val},err:null};if(0===f.length)return this.error(r.EXPECT_DATE_TIME_SKELETON,g);var m=f;this.locale&&(m=function(e,t){for(var i="",r=0;r<e.length;r++){var n=e.charAt(r);if("j"===n){for(var s=0;r+1<e.length&&e.charAt(r+1)===n;)s++,r++;var o=1+(1&s),a=s<2?1:3+(s>>1),l=N(t);for("H"!=l&&"k"!=l||(a=0);a-- >0;)i+="a";for(;o-- >0;)i=l+i}else i+="J"===n?"H":n}return i}(f,this.locale));var v={type:s.dateTime,pattern:m,location:d.styleLocation,parsedOptions:this.shouldParseSkeletons?w(m):{}};return{val:{type:"date"===u?n.date:n.time,value:i,location:g,style:v},err:null}}return{val:{type:"number"===u?n.number:"date"===u?n.date:n.time,value:i,location:g,style:null!==(l=null==d?void 0:d.style)&&void 0!==l?l:null},err:null};case"plural":case"selectordinal":case"select":var C=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(r.EXPECT_SELECT_ARGUMENT_OPTIONS,k(C,(0,o.__assign)({},C)));this.bumpSpace();var y=this.parseIdentifierIfPossible(),S=0;if("select"!==u&&"offset"===y.value){if(!this.bumpIf(":"))return this.error(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,k(this.clonePosition(),this.clonePosition()));var b;if(this.bumpSpace(),(b=this.tryParseDecimalInteger(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return b;this.bumpSpace(),y=this.parseIdentifierIfPossible(),S=b.val}var E,A=this.tryParsePluralOrSelectOptions(e,u,t,y);if(A.err)return A;if((E=this.tryParseArgumentClose(a)).err)return E;var T=k(a,this.clonePosition());return"select"===u?{val:{type:n.select,value:i,options:Y(A.val),location:T},err:null}:{val:{type:n.plural,value:i,options:Y(A.val),offset:S,pluralType:"plural"===u?"cardinal":"ordinal",location:T},err:null};default:return this.error(r.INVALID_ARGUMENT_TYPE,k(c,h))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();)switch(this.char()){case 39:this.bump();var i=this.clonePosition();if(!this.bumpUntil("'"))return this.error(r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,k(i,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var i=[];try{i=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],i=0,r=e.split(S).filter(function(e){return e.length>0});i<r.length;i++){var n=r[i].split("/");if(0===n.length)throw new Error("Invalid number skeleton");for(var s=n[0],o=n.slice(1),a=0,l=o;a<l.length;a++)if(0===l[a].length)throw new Error("Invalid number skeleton");t.push({stem:s,options:o})}return t}(e)}catch(e){return this.error(r.INVALID_NUMBER_SKELETON,t)}return{val:{type:s.number,tokens:i,location:t,parsedOptions:this.shouldParseSkeletons?D(i):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,i,n){for(var s,o=!1,a=[],l=new Set,c=n.value,u=n.location;;){if(0===c.length){var h=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var d=this.tryParseDecimalInteger(r.EXPECT_PLURAL_ARGUMENT_SELECTOR,r.INVALID_PLURAL_ARGUMENT_SELECTOR);if(d.err)return d;u=k(h,this.clonePosition()),c=this.message.slice(h.offset,this.offset())}if(l.has(c))return this.error("select"===t?r.DUPLICATE_SELECT_ARGUMENT_SELECTOR:r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,u);"other"===c&&(o=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,k(this.clonePosition(),this.clonePosition()));var g=this.parseMessage(e+1,t,i);if(g.err)return g;var f=this.tryParseArgumentClose(p);if(f.err)return f;a.push([c,{value:g.val,location:k(p,this.clonePosition())}]),l.add(c),this.bumpSpace(),c=(s=this.parseIdentifierIfPossible()).value,u=s.location}return 0===a.length?this.error("select"===t?r.EXPECT_SELECT_ARGUMENT_SELECTOR:r.EXPECT_PLURAL_ARGUMENT_SELECTOR,k(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(r.MISSING_OTHER_CLAUSE,k(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var i=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(i=-1);for(var n=!1,s=0;!this.isEOF();){var o=this.char();if(!(o>=48&&o<=57))break;n=!0,s=10*s+(o-48),this.bump()}var a=k(r,this.clonePosition());return n?W(s*=i)?{val:s,err:null}:this.error(t,a):this.error(e,a)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=Q(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if($(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),i=this.message.indexOf(e,t);return i>=0?(this.bumpTo(i),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&ne(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),i=this.message.charCodeAt(t+(e>=65536?2:1));return null!=i?i:null},e}();function ie(e){return e>=97&&e<=122||e>=65&&e<=90}function re(e){return 45===e||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function ne(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function se(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function oe(e){e.forEach(function(e){if(delete e.location,d(e)||p(e))for(var t in e.options)delete e.options[t].location,oe(e.options[t].value);else c(e)&&m(e.style)||(u(e)||h(e))&&v(e.style)?delete e.style.location:f(e)&&oe(e.children)})}function ae(e,t){void 0===t&&(t={}),t=(0,o.__assign)({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var i=new te(e,t).parse();if(i.err){var n=SyntaxError(r[i.err.kind]);throw n.location=i.err.location,n.originalMessage=i.err.message,n}return(null==t?void 0:t.captureLocation)||oe(i.val),i.val}},78582(e,t,i){"use strict";i.d(t,{Im:()=>l,tv:()=>u,Tu:()=>v,eW:()=>a,oF:()=>c,N1:()=>m,N6:()=>p,jA:()=>g,Jp:()=>d,xm:()=>f,Qh:()=>h,qg:()=>ae});var r,n,s,o=i(65959);function a(e){return e.type===n.literal}function l(e){return e.type===n.argument}function c(e){return e.type===n.number}function u(e){return e.type===n.date}function h(e){return e.type===n.time}function d(e){return e.type===n.select}function p(e){return e.type===n.plural}function g(e){return e.type===n.pound}function f(e){return e.type===n.tag}function m(e){return!(!e||"object"!=typeof e||e.type!==s.number)}function v(e){return!(!e||"object"!=typeof e||e.type!==s.dateTime)}!function(e){e[e.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",e[e.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",e[e.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",e[e.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",e[e.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",e[e.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",e[e.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",e[e.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",e[e.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",e[e.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",e[e.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",e[e.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",e[e.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",e[e.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",e[e.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",e[e.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",e[e.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",e[e.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",e[e.INVALID_TAG=23]="INVALID_TAG",e[e.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",e[e.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",e[e.UNCLOSED_TAG=27]="UNCLOSED_TAG"}(r||(r={})),function(e){e[e.literal=0]="literal",e[e.argument=1]="argument",e[e.number=2]="number",e[e.date=3]="date",e[e.time=4]="time",e[e.select=5]="select",e[e.plural=6]="plural",e[e.pound=7]="pound",e[e.tag=8]="tag"}(n||(n={})),function(e){e[e.number=0]="number",e[e.dateTime=1]="dateTime"}(s||(s={}));var C=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,y=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g;function w(e){var t={};return e.replace(y,function(e){var i=e.length;switch(e[0]){case"G":t.era=4===i?"long":5===i?"narrow":"short";break;case"y":t.year=2===i?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw new RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw new RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":t.month=["numeric","2-digit","short","long","narrow"][i-1];break;case"w":case"W":throw new RangeError("`w/W` (week) patterns are not supported");case"d":t.day=["numeric","2-digit"][i-1];break;case"D":case"F":case"g":throw new RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":t.weekday=4===i?"long":5===i?"narrow":"short";break;case"e":if(i<4)throw new RangeError("`e..eee` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][i-4];break;case"c":if(i<4)throw new RangeError("`c..ccc` (weekday) patterns are not supported");t.weekday=["short","long","narrow","short"][i-4];break;case"a":t.hour12=!0;break;case"b":case"B":throw new RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":t.hourCycle="h12",t.hour=["numeric","2-digit"][i-1];break;case"H":t.hourCycle="h23",t.hour=["numeric","2-digit"][i-1];break;case"K":t.hourCycle="h11",t.hour=["numeric","2-digit"][i-1];break;case"k":t.hourCycle="h24",t.hour=["numeric","2-digit"][i-1];break;case"j":case"J":case"C":throw new RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":t.minute=["numeric","2-digit"][i-1];break;case"s":t.second=["numeric","2-digit"][i-1];break;case"S":case"A":throw new RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":t.timeZoneName=i<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw new RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),t}var S=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i;function b(e){return e.replace(/^(.*?)-/,"")}var E=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,A=/^(@+)?(\+|#+)?[rs]?$/g,T=/(\*)(0+)|(#+)(0+)|(0+)/g,M=/^(0+)$/;function R(e){var t={};return"r"===e[e.length-1]?t.roundingPriority="morePrecision":"s"===e[e.length-1]&&(t.roundingPriority="lessPrecision"),e.replace(A,function(e,i,r){return"string"!=typeof r?(t.minimumSignificantDigits=i.length,t.maximumSignificantDigits=i.length):"+"===r?t.minimumSignificantDigits=i.length:"#"===i[0]?t.maximumSignificantDigits=i.length:(t.minimumSignificantDigits=i.length,t.maximumSignificantDigits=i.length+("string"==typeof r?r.length:0)),""}),t}function _(e){switch(e){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function P(e){var t;if("E"===e[0]&&"E"===e[1]?(t={notation:"engineering"},e=e.slice(2)):"E"===e[0]&&(t={notation:"scientific"},e=e.slice(1)),t){var i=e.slice(0,2);if("+!"===i?(t.signDisplay="always",e=e.slice(2)):"+?"===i&&(t.signDisplay="exceptZero",e=e.slice(2)),!M.test(e))throw new Error("Malformed concise eng/scientific notation");t.minimumIntegerDigits=e.length}return t}function x(e){return _(e)||{}}function D(e){for(var t={},i=0,r=e;i<r.length;i++){var n=r[i];switch(n.stem){case"percent":case"%":t.style="percent";continue;case"%x100":t.style="percent",t.scale=100;continue;case"currency":t.style="currency",t.currency=n.options[0];continue;case"group-off":case",_":t.useGrouping=!1;continue;case"precision-integer":case".":t.maximumFractionDigits=0;continue;case"measure-unit":case"unit":t.style="unit",t.unit=b(n.options[0]);continue;case"compact-short":case"K":t.notation="compact",t.compactDisplay="short";continue;case"compact-long":case"KK":t.notation="compact",t.compactDisplay="long";continue;case"scientific":t=(0,o.__assign)((0,o.__assign)((0,o.__assign)({},t),{notation:"scientific"}),n.options.reduce(function(e,t){return(0,o.__assign)((0,o.__assign)({},e),x(t))},{}));continue;case"engineering":t=(0,o.__assign)((0,o.__assign)((0,o.__assign)({},t),{notation:"engineering"}),n.options.reduce(function(e,t){return(0,o.__assign)((0,o.__assign)({},e),x(t))},{}));continue;case"notation-simple":t.notation="standard";continue;case"unit-width-narrow":t.currencyDisplay="narrowSymbol",t.unitDisplay="narrow";continue;case"unit-width-short":t.currencyDisplay="code",t.unitDisplay="short";continue;case"unit-width-full-name":t.currencyDisplay="name",t.unitDisplay="long";continue;case"unit-width-iso-code":t.currencyDisplay="symbol";continue;case"scale":t.scale=parseFloat(n.options[0]);continue;case"rounding-mode-floor":t.roundingMode="floor";continue;case"rounding-mode-ceiling":t.roundingMode="ceil";continue;case"rounding-mode-down":t.roundingMode="trunc";continue;case"rounding-mode-up":t.roundingMode="expand";continue;case"rounding-mode-half-even":t.roundingMode="halfEven";continue;case"rounding-mode-half-down":t.roundingMode="halfTrunc";continue;case"rounding-mode-half-up":t.roundingMode="halfExpand";continue;case"integer-width":if(n.options.length>1)throw new RangeError("integer-width stems only accept a single optional option");n.options[0].replace(T,function(e,i,r,n,s,o){if(i)t.minimumIntegerDigits=r.length;else{if(n&&s)throw new Error("We currently do not support maximum integer digits");if(o)throw new Error("We currently do not support exact integer digits")}return""});continue}if(M.test(n.stem))t.minimumIntegerDigits=n.stem.length;else if(E.test(n.stem)){if(n.options.length>1)throw new RangeError("Fraction-precision stems only accept a single optional option");n.stem.replace(E,function(e,i,r,n,s,o){return"*"===r?t.minimumFractionDigits=i.length:n&&"#"===n[0]?t.maximumFractionDigits=n.length:s&&o?(t.minimumFractionDigits=s.length,t.maximumFractionDigits=s.length+o.length):(t.minimumFractionDigits=i.length,t.maximumFractionDigits=i.length),""});var s=n.options[0];"w"===s?t=(0,o.__assign)((0,o.__assign)({},t),{trailingZeroDisplay:"stripIfInteger"}):s&&(t=(0,o.__assign)((0,o.__assign)({},t),R(s)))}else if(A.test(n.stem))t=(0,o.__assign)((0,o.__assign)({},t),R(n.stem));else{var a=_(n.stem);a&&(t=(0,o.__assign)((0,o.__assign)({},t),a));var l=P(n.stem);l&&(t=(0,o.__assign)((0,o.__assign)({},t),l))}}return t}var I,L={"001":["H","h"],419:["h","H","hB","hb"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["h","H","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["h","H","hB","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["h","H","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["h","H","hB","hb"],CU:["h","H","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["h","H","hB","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["h","H","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["h","H","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["h","H","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["h","H","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["h","H","hB","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["h","H","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["h","H","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["h","H","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"en-HK":["h","hb","H","hB"],"en-IL":["H","h","hb","hB"],"en-MY":["h","hb","H","hB"],"es-BR":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]};function N(e){var t=e.hourCycle;if(void 0===t&&e.hourCycles&&e.hourCycles.length&&(t=e.hourCycles[0]),t)switch(t){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw new Error("Invalid hourCycle")}var i,r=e.language;return"root"!==r&&(i=e.maximize().region),(L[i||""]||L[r||""]||L["".concat(r,"-001")]||L["001"])[0]}var O=new RegExp("^".concat(C.source,"*")),F=new RegExp("".concat(C.source,"*$"));function k(e,t){return{start:e,end:t}}var G=!!String.prototype.startsWith&&"_a".startsWith("a",1),V=!!String.fromCodePoint,H=!!Object.fromEntries,B=!!String.prototype.codePointAt,z=!!String.prototype.trimStart,U=!!String.prototype.trimEnd,W=Number.isSafeInteger?Number.isSafeInteger:function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e&&Math.abs(e)<=9007199254740991},j=!0;try{j="a"===(null===(I=J("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu").exec("a"))||void 0===I?void 0:I[0])}catch(e){j=!1}var K,$=G?function(e,t,i){return e.startsWith(t,i)}:function(e,t,i){return e.slice(i,i+t.length)===t},q=V?String.fromCodePoint:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];for(var i,r="",n=e.length,s=0;n>s;){if((i=e[s++])>1114111)throw RangeError(i+" is not a valid code point");r+=i<65536?String.fromCharCode(i):String.fromCharCode(55296+((i-=65536)>>10),i%1024+56320)}return r},Y=H?Object.fromEntries:function(e){for(var t={},i=0,r=e;i<r.length;i++){var n=r[i],s=n[0],o=n[1];t[s]=o}return t},Q=B?function(e,t){return e.codePointAt(t)}:function(e,t){var i=e.length;if(!(t<0||t>=i)){var r,n=e.charCodeAt(t);return n<55296||n>56319||t+1===i||(r=e.charCodeAt(t+1))<56320||r>57343?n:r-56320+(n-55296<<10)+65536}},X=z?function(e){return e.trimStart()}:function(e){return e.replace(O,"")},Z=U?function(e){return e.trimEnd()}:function(e){return e.replace(F,"")};function J(e,t){return new RegExp(e,t)}if(j){var ee=J("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");K=function(e,t){var i;return ee.lastIndex=t,null!==(i=ee.exec(e)[1])&&void 0!==i?i:""}}else K=function(e,t){for(var i=[];;){var r=Q(e,t);if(void 0===r||ne(r)||se(r))break;i.push(r),t+=r>=65536?2:1}return q.apply(void 0,i)};var te=function(){function e(e,t){void 0===t&&(t={}),this.message=e,this.position={offset:0,line:1,column:1},this.ignoreTag=!!t.ignoreTag,this.locale=t.locale,this.requiresOtherClause=!!t.requiresOtherClause,this.shouldParseSkeletons=!!t.shouldParseSkeletons}return e.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},e.prototype.parseMessage=function(e,t,i){for(var s=[];!this.isEOF();){var o=this.char();if(123===o){if((a=this.parseArgument(e,i)).err)return a;s.push(a.val)}else{if(125===o&&e>0)break;if(35!==o||"plural"!==t&&"selectordinal"!==t){if(60===o&&!this.ignoreTag&&47===this.peek()){if(i)break;return this.error(r.UNMATCHED_CLOSING_TAG,k(this.clonePosition(),this.clonePosition()))}if(60===o&&!this.ignoreTag&&ie(this.peek()||0)){if((a=this.parseTag(e,t)).err)return a;s.push(a.val)}else{var a;if((a=this.parseLiteral(e,t)).err)return a;s.push(a.val)}}else{var l=this.clonePosition();this.bump(),s.push({type:n.pound,location:k(l,this.clonePosition())})}}}return{val:s,err:null}},e.prototype.parseTag=function(e,t){var i=this.clonePosition();this.bump();var s=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:n.literal,value:"<".concat(s,"/>"),location:k(i,this.clonePosition())},err:null};if(this.bumpIf(">")){var o=this.parseMessage(e+1,t,!0);if(o.err)return o;var a=o.val,l=this.clonePosition();if(this.bumpIf("</")){if(this.isEOF()||!ie(this.char()))return this.error(r.INVALID_TAG,k(l,this.clonePosition()));var c=this.clonePosition();return s!==this.parseTagName()?this.error(r.UNMATCHED_CLOSING_TAG,k(c,this.clonePosition())):(this.bumpSpace(),this.bumpIf(">")?{val:{type:n.tag,value:s,children:a,location:k(i,this.clonePosition())},err:null}:this.error(r.INVALID_TAG,k(l,this.clonePosition())))}return this.error(r.UNCLOSED_TAG,k(i,this.clonePosition()))}return this.error(r.INVALID_TAG,k(i,this.clonePosition()))},e.prototype.parseTagName=function(){var e=this.offset();for(this.bump();!this.isEOF()&&re(this.char());)this.bump();return this.message.slice(e,this.offset())},e.prototype.parseLiteral=function(e,t){for(var i=this.clonePosition(),r="";;){var s=this.tryParseQuote(t);if(s)r+=s;else{var o=this.tryParseUnquoted(e,t);if(o)r+=o;else{var a=this.tryParseLeftAngleBracket();if(!a)break;r+=a}}}var l=k(i,this.clonePosition());return{val:{type:n.literal,value:r,location:l},err:null}},e.prototype.tryParseLeftAngleBracket=function(){return this.isEOF()||60!==this.char()||!this.ignoreTag&&(ie(e=this.peek()||0)||47===e)?null:(this.bump(),"<");var e},e.prototype.tryParseQuote=function(e){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===e||"selectordinal"===e)break;return null;default:return null}this.bump();var t=[this.char()];for(this.bump();!this.isEOF();){var i=this.char();if(39===i){if(39!==this.peek()){this.bump();break}t.push(39),this.bump()}else t.push(i);this.bump()}return q.apply(void 0,t)},e.prototype.tryParseUnquoted=function(e,t){if(this.isEOF())return null;var i=this.char();return 60===i||123===i||35===i&&("plural"===t||"selectordinal"===t)||125===i&&e>0?null:(this.bump(),q(i))},e.prototype.parseArgument=function(e,t){var i=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition()));if(125===this.char())return this.bump(),this.error(r.EMPTY_ARGUMENT,k(i,this.clonePosition()));var s=this.parseIdentifierIfPossible().value;if(!s)return this.error(r.MALFORMED_ARGUMENT,k(i,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:n.argument,value:s,location:k(i,this.clonePosition())},err:null};case 44:return this.bump(),this.bumpSpace(),this.isEOF()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(i,this.clonePosition())):this.parseArgumentOptions(e,t,s,i);default:return this.error(r.MALFORMED_ARGUMENT,k(i,this.clonePosition()))}},e.prototype.parseIdentifierIfPossible=function(){var e=this.clonePosition(),t=this.offset(),i=K(this.message,t),r=t+i.length;return this.bumpTo(r),{value:i,location:k(e,this.clonePosition())}},e.prototype.parseArgumentOptions=function(e,t,i,a){var l,c=this.clonePosition(),u=this.parseIdentifierIfPossible().value,h=this.clonePosition();switch(u){case"":return this.error(r.EXPECT_ARGUMENT_TYPE,k(c,h));case"number":case"date":case"time":this.bumpSpace();var d=null;if(this.bumpIf(",")){this.bumpSpace();var p=this.clonePosition();if((b=this.parseSimpleArgStyleIfPossible()).err)return b;if(0===(v=Z(b.val)).length)return this.error(r.EXPECT_ARGUMENT_STYLE,k(this.clonePosition(),this.clonePosition()));d={style:v,styleLocation:k(p,this.clonePosition())}}if((E=this.tryParseArgumentClose(a)).err)return E;var g=k(a,this.clonePosition());if(d&&$(null==d?void 0:d.style,"::",0)){var f=X(d.style.slice(2));if("number"===u)return(b=this.parseNumberSkeletonFromString(f,d.styleLocation)).err?b:{val:{type:n.number,value:i,location:g,style:b.val},err:null};if(0===f.length)return this.error(r.EXPECT_DATE_TIME_SKELETON,g);var m=f;this.locale&&(m=function(e,t){for(var i="",r=0;r<e.length;r++){var n=e.charAt(r);if("j"===n){for(var s=0;r+1<e.length&&e.charAt(r+1)===n;)s++,r++;var o=1+(1&s),a=s<2?1:3+(s>>1),l=N(t);for("H"!=l&&"k"!=l||(a=0);a-- >0;)i+="a";for(;o-- >0;)i=l+i}else i+="J"===n?"H":n}return i}(f,this.locale));var v={type:s.dateTime,pattern:m,location:d.styleLocation,parsedOptions:this.shouldParseSkeletons?w(m):{}};return{val:{type:"date"===u?n.date:n.time,value:i,location:g,style:v},err:null}}return{val:{type:"number"===u?n.number:"date"===u?n.date:n.time,value:i,location:g,style:null!==(l=null==d?void 0:d.style)&&void 0!==l?l:null},err:null};case"plural":case"selectordinal":case"select":var C=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(r.EXPECT_SELECT_ARGUMENT_OPTIONS,k(C,(0,o.__assign)({},C)));this.bumpSpace();var y=this.parseIdentifierIfPossible(),S=0;if("select"!==u&&"offset"===y.value){if(!this.bumpIf(":"))return this.error(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,k(this.clonePosition(),this.clonePosition()));var b;if(this.bumpSpace(),(b=this.tryParseDecimalInteger(r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE)).err)return b;this.bumpSpace(),y=this.parseIdentifierIfPossible(),S=b.val}var E,A=this.tryParsePluralOrSelectOptions(e,u,t,y);if(A.err)return A;if((E=this.tryParseArgumentClose(a)).err)return E;var T=k(a,this.clonePosition());return"select"===u?{val:{type:n.select,value:i,options:Y(A.val),location:T},err:null}:{val:{type:n.plural,value:i,options:Y(A.val),offset:S,pluralType:"plural"===u?"cardinal":"ordinal",location:T},err:null};default:return this.error(r.INVALID_ARGUMENT_TYPE,k(c,h))}},e.prototype.tryParseArgumentClose=function(e){return this.isEOF()||125!==this.char()?this.error(r.EXPECT_ARGUMENT_CLOSING_BRACE,k(e,this.clonePosition())):(this.bump(),{val:!0,err:null})},e.prototype.parseSimpleArgStyleIfPossible=function(){for(var e=0,t=this.clonePosition();!this.isEOF();)switch(this.char()){case 39:this.bump();var i=this.clonePosition();if(!this.bumpUntil("'"))return this.error(r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,k(i,this.clonePosition()));this.bump();break;case 123:e+=1,this.bump();break;case 125:if(!(e>0))return{val:this.message.slice(t.offset,this.offset()),err:null};e-=1;break;default:this.bump()}return{val:this.message.slice(t.offset,this.offset()),err:null}},e.prototype.parseNumberSkeletonFromString=function(e,t){var i=[];try{i=function(e){if(0===e.length)throw new Error("Number skeleton cannot be empty");for(var t=[],i=0,r=e.split(S).filter(function(e){return e.length>0});i<r.length;i++){var n=r[i].split("/");if(0===n.length)throw new Error("Invalid number skeleton");for(var s=n[0],o=n.slice(1),a=0,l=o;a<l.length;a++)if(0===l[a].length)throw new Error("Invalid number skeleton");t.push({stem:s,options:o})}return t}(e)}catch(e){return this.error(r.INVALID_NUMBER_SKELETON,t)}return{val:{type:s.number,tokens:i,location:t,parsedOptions:this.shouldParseSkeletons?D(i):{}},err:null}},e.prototype.tryParsePluralOrSelectOptions=function(e,t,i,n){for(var s,o=!1,a=[],l=new Set,c=n.value,u=n.location;;){if(0===c.length){var h=this.clonePosition();if("select"===t||!this.bumpIf("="))break;var d=this.tryParseDecimalInteger(r.EXPECT_PLURAL_ARGUMENT_SELECTOR,r.INVALID_PLURAL_ARGUMENT_SELECTOR);if(d.err)return d;u=k(h,this.clonePosition()),c=this.message.slice(h.offset,this.offset())}if(l.has(c))return this.error("select"===t?r.DUPLICATE_SELECT_ARGUMENT_SELECTOR:r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,u);"other"===c&&(o=!0),this.bumpSpace();var p=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===t?r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,k(this.clonePosition(),this.clonePosition()));var g=this.parseMessage(e+1,t,i);if(g.err)return g;var f=this.tryParseArgumentClose(p);if(f.err)return f;a.push([c,{value:g.val,location:k(p,this.clonePosition())}]),l.add(c),this.bumpSpace(),c=(s=this.parseIdentifierIfPossible()).value,u=s.location}return 0===a.length?this.error("select"===t?r.EXPECT_SELECT_ARGUMENT_SELECTOR:r.EXPECT_PLURAL_ARGUMENT_SELECTOR,k(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(r.MISSING_OTHER_CLAUSE,k(this.clonePosition(),this.clonePosition())):{val:a,err:null}},e.prototype.tryParseDecimalInteger=function(e,t){var i=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(i=-1);for(var n=!1,s=0;!this.isEOF();){var o=this.char();if(!(o>=48&&o<=57))break;n=!0,s=10*s+(o-48),this.bump()}var a=k(r,this.clonePosition());return n?W(s*=i)?{val:s,err:null}:this.error(t,a):this.error(e,a)},e.prototype.offset=function(){return this.position.offset},e.prototype.isEOF=function(){return this.offset()===this.message.length},e.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},e.prototype.char=function(){var e=this.position.offset;if(e>=this.message.length)throw Error("out of bound");var t=Q(this.message,e);if(void 0===t)throw Error("Offset ".concat(e," is at invalid UTF-16 code unit boundary"));return t},e.prototype.error=function(e,t){return{val:null,err:{kind:e,message:this.message,location:t}}},e.prototype.bump=function(){if(!this.isEOF()){var e=this.char();10===e?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=e<65536?1:2)}},e.prototype.bumpIf=function(e){if($(this.message,e,this.offset())){for(var t=0;t<e.length;t++)this.bump();return!0}return!1},e.prototype.bumpUntil=function(e){var t=this.offset(),i=this.message.indexOf(e,t);return i>=0?(this.bumpTo(i),!0):(this.bumpTo(this.message.length),!1)},e.prototype.bumpTo=function(e){if(this.offset()>e)throw Error("targetOffset ".concat(e," must be greater than or equal to the current offset ").concat(this.offset()));for(e=Math.min(e,this.message.length);;){var t=this.offset();if(t===e)break;if(t>e)throw Error("targetOffset ".concat(e," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},e.prototype.bumpSpace=function(){for(;!this.isEOF()&&ne(this.char());)this.bump()},e.prototype.peek=function(){if(this.isEOF())return null;var e=this.char(),t=this.offset(),i=this.message.charCodeAt(t+(e>=65536?2:1));return null!=i?i:null},e}();function ie(e){return e>=97&&e<=122||e>=65&&e<=90}function re(e){return 45===e||46===e||e>=48&&e<=57||95===e||e>=97&&e<=122||e>=65&&e<=90||183==e||e>=192&&e<=214||e>=216&&e<=246||e>=248&&e<=893||e>=895&&e<=8191||e>=8204&&e<=8205||e>=8255&&e<=8256||e>=8304&&e<=8591||e>=11264&&e<=12271||e>=12289&&e<=55295||e>=63744&&e<=64975||e>=65008&&e<=65533||e>=65536&&e<=983039}function ne(e){return e>=9&&e<=13||32===e||133===e||e>=8206&&e<=8207||8232===e||8233===e}function se(e){return e>=33&&e<=35||36===e||e>=37&&e<=39||40===e||41===e||42===e||43===e||44===e||45===e||e>=46&&e<=47||e>=58&&e<=59||e>=60&&e<=62||e>=63&&e<=64||91===e||92===e||93===e||94===e||96===e||123===e||124===e||125===e||126===e||161===e||e>=162&&e<=165||166===e||167===e||169===e||171===e||172===e||174===e||176===e||177===e||182===e||187===e||191===e||215===e||247===e||e>=8208&&e<=8213||e>=8214&&e<=8215||8216===e||8217===e||8218===e||e>=8219&&e<=8220||8221===e||8222===e||8223===e||e>=8224&&e<=8231||e>=8240&&e<=8248||8249===e||8250===e||e>=8251&&e<=8254||e>=8257&&e<=8259||8260===e||8261===e||8262===e||e>=8263&&e<=8273||8274===e||8275===e||e>=8277&&e<=8286||e>=8592&&e<=8596||e>=8597&&e<=8601||e>=8602&&e<=8603||e>=8604&&e<=8607||8608===e||e>=8609&&e<=8610||8611===e||e>=8612&&e<=8613||8614===e||e>=8615&&e<=8621||8622===e||e>=8623&&e<=8653||e>=8654&&e<=8655||e>=8656&&e<=8657||8658===e||8659===e||8660===e||e>=8661&&e<=8691||e>=8692&&e<=8959||e>=8960&&e<=8967||8968===e||8969===e||8970===e||8971===e||e>=8972&&e<=8991||e>=8992&&e<=8993||e>=8994&&e<=9e3||9001===e||9002===e||e>=9003&&e<=9083||9084===e||e>=9085&&e<=9114||e>=9115&&e<=9139||e>=9140&&e<=9179||e>=9180&&e<=9185||e>=9186&&e<=9254||e>=9255&&e<=9279||e>=9280&&e<=9290||e>=9291&&e<=9311||e>=9472&&e<=9654||9655===e||e>=9656&&e<=9664||9665===e||e>=9666&&e<=9719||e>=9720&&e<=9727||e>=9728&&e<=9838||9839===e||e>=9840&&e<=10087||10088===e||10089===e||10090===e||10091===e||10092===e||10093===e||10094===e||10095===e||10096===e||10097===e||10098===e||10099===e||10100===e||10101===e||e>=10132&&e<=10175||e>=10176&&e<=10180||10181===e||10182===e||e>=10183&&e<=10213||10214===e||10215===e||10216===e||10217===e||10218===e||10219===e||10220===e||10221===e||10222===e||10223===e||e>=10224&&e<=10239||e>=10240&&e<=10495||e>=10496&&e<=10626||10627===e||10628===e||10629===e||10630===e||10631===e||10632===e||10633===e||10634===e||10635===e||10636===e||10637===e||10638===e||10639===e||10640===e||10641===e||10642===e||10643===e||10644===e||10645===e||10646===e||10647===e||10648===e||e>=10649&&e<=10711||10712===e||10713===e||10714===e||10715===e||e>=10716&&e<=10747||10748===e||10749===e||e>=10750&&e<=11007||e>=11008&&e<=11055||e>=11056&&e<=11076||e>=11077&&e<=11078||e>=11079&&e<=11084||e>=11085&&e<=11123||e>=11124&&e<=11125||e>=11126&&e<=11157||11158===e||e>=11159&&e<=11263||e>=11776&&e<=11777||11778===e||11779===e||11780===e||11781===e||e>=11782&&e<=11784||11785===e||11786===e||11787===e||11788===e||11789===e||e>=11790&&e<=11798||11799===e||e>=11800&&e<=11801||11802===e||11803===e||11804===e||11805===e||e>=11806&&e<=11807||11808===e||11809===e||11810===e||11811===e||11812===e||11813===e||11814===e||11815===e||11816===e||11817===e||e>=11818&&e<=11822||11823===e||e>=11824&&e<=11833||e>=11834&&e<=11835||e>=11836&&e<=11839||11840===e||11841===e||11842===e||e>=11843&&e<=11855||e>=11856&&e<=11857||11858===e||e>=11859&&e<=11903||e>=12289&&e<=12291||12296===e||12297===e||12298===e||12299===e||12300===e||12301===e||12302===e||12303===e||12304===e||12305===e||e>=12306&&e<=12307||12308===e||12309===e||12310===e||12311===e||12312===e||12313===e||12314===e||12315===e||12316===e||12317===e||e>=12318&&e<=12319||12320===e||12336===e||64830===e||64831===e||e>=65093&&e<=65094}function oe(e){e.forEach(function(e){if(delete e.location,d(e)||p(e))for(var t in e.options)delete e.options[t].location,oe(e.options[t].value);else c(e)&&m(e.style)||(u(e)||h(e))&&v(e.style)?delete e.style.location:f(e)&&oe(e.children)})}function ae(e,t){void 0===t&&(t={}),t=(0,o.__assign)({shouldParseSkeletons:!0,requiresOtherClause:!0},t);var i=new te(e,t).parse();if(i.err){var n=SyntaxError(r[i.err.kind]);throw n.location=i.err.location,n.originalMessage=i.err.message,n}return(null==t?void 0:t.captureLocation)||oe(i.val),i.val}},82607(e,t,i){"use strict";i.d(t,{E:()=>P});var r=i(65959),n=i(14716),s=i(71984),o=["localeMatcher","style","currency","currencyDisplay","unit","unitDisplay","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","currencyDisplay","currencySign","notation","signDisplay","unit","unitDisplay","numberingSystem"];function a(e,t,i){var r=e.locale,s=e.formats,a=e.onError;void 0===i&&(i={});var l=i.format,c=l&&(0,n.F3)(s,"number",l,a)||{};return t(r,(0,n.J9)(i,o,c))}function l(e,t,i,r){void 0===r&&(r={});try{return a(e,t,r).format(i)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting number.",t))}return String(i)}function c(e,t,i,r){void 0===r&&(r={});try{return a(e,t,r).formatToParts(i)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting number.",t))}return[]}var u=i(660),h=["numeric","style"];function d(e,t,i,r,o){void 0===o&&(o={}),r||(r="second"),Intl.RelativeTimeFormat||e.onError(new u.IF('Intl.RelativeTimeFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-relativetimeformat"\n',u.O4.MISSING_INTL_API));try{return function(e,t,i){var r=e.locale,s=e.formats,o=e.onError;void 0===i&&(i={});var a=i.format,l=!!a&&(0,n.F3)(s,"relative",a,o)||{};return t(r,(0,n.J9)(i,h,l))}(e,t,o).format(i,r)}catch(t){e.onError(new s.pg("Error formatting relative time.",e.locale,t))}return String(i)}var p=["localeMatcher","formatMatcher","timeZone","hour12","weekday","era","year","month","day","hour","minute","second","timeZoneName","hourCycle","dateStyle","timeStyle","calendar","numberingSystem"];function g(e,t,i,s){var o=e.locale,a=e.formats,l=e.onError,c=e.timeZone;void 0===s&&(s={});var u=s.format,h=(0,r.__assign)((0,r.__assign)({},c&&{timeZone:c}),u&&(0,n.F3)(a,t,u,l)),d=(0,n.J9)(s,p,h);return"time"!==t||d.hour||d.minute||d.second||d.timeStyle||d.dateStyle||(d=(0,r.__assign)((0,r.__assign)({},d),{hour:"numeric",minute:"numeric"})),i(o,d)}function f(e,t){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];var n=i[0],o=i[1],a=void 0===o?{}:o,l="string"==typeof n?new Date(n||0):n;try{return g(e,"date",t,a).format(l)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting date.",t))}return String(l)}function m(e,t){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];var n=i[0],o=i[1],a=void 0===o?{}:o,l="string"==typeof n?new Date(n||0):n;try{return g(e,"time",t,a).format(l)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting time.",t))}return String(l)}function v(e,t){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];var o=i[0],a=i[1],l=i[2],c=void 0===l?{}:l,u=e.timeZone,h=e.locale,d=e.onError,g=(0,n.J9)(c,p,u?{timeZone:u}:{});try{return t(h,g).formatRange(o,a)}catch(e){d(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting date time range.",e))}return String(o)}function C(e,t){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];var n=i[0],o=i[1],a=void 0===o?{}:o,l="string"==typeof n?new Date(n||0):n;try{return g(e,"date",t,a).formatToParts(l)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting date.",t))}return[]}function y(e,t){for(var i=[],r=2;r<arguments.length;r++)i[r-2]=arguments[r];var n=i[0],o=i[1],a=void 0===o?{}:o,l="string"==typeof n?new Date(n||0):n;try{return g(e,"time",t,a).formatToParts(l)}catch(t){e.onError(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting time.",t))}return[]}var w=["localeMatcher","type"];function S(e,t,i,r){var o=e.locale,a=e.onError;void 0===r&&(r={}),Intl.PluralRules||a(new u.IF('Intl.PluralRules is not available in this environment.\nTry polyfilling it using "@formatjs/intl-pluralrules"\n',u.O4.MISSING_INTL_API));var l=(0,n.J9)(r,w);try{return t(o,l).select(i)}catch(e){a(new s.pg("Error formatting plural.",o,e))}return"other"}var b=i(62954),E=["localeMatcher","type","style"],A=Date.now();function T(e,t,i,r){void 0===r&&(r={});var n=M(e,t,i,r).reduce(function(e,t){var i=t.value;return"string"!=typeof i?e.push(i):"string"==typeof e[e.length-1]?e[e.length-1]+=i:e.push(i),e},[]);return 1===n.length?n[0]:n}function M(e,t,i,o){var a=e.locale,l=e.onError;void 0===o&&(o={}),Intl.ListFormat||l(new u.IF('Intl.ListFormat is not available in this environment.\nTry polyfilling it using "@formatjs/intl-listformat"\n',u.O4.MISSING_INTL_API));var c=(0,n.J9)(o,E);try{var h={},d=i.map(function(e,t){if("object"==typeof e){var i=function(e){return"".concat(A,"_").concat(e,"_").concat(A)}(t);return h[i]=e,i}return String(e)});return t(a,c).formatToParts(d).map(function(e){return"literal"===e.type?e:(0,r.__assign)((0,r.__assign)({},e),{value:h[e.value]||e.value})})}catch(e){l(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting list.",e))}return i}var R=["localeMatcher","style","type","fallback"];function _(e,t,i,r){var o=e.locale,a=e.onError;Intl.DisplayNames||a(new u.IF('Intl.DisplayNames is not available in this environment.\nTry polyfilling it using "@formatjs/intl-displaynames"\n',u.O4.MISSING_INTL_API));var l=(0,n.J9)(r,R);try{return t(o,l).of(i)}catch(e){a(new s.Ar(s.lo.FORMAT_ERROR,"Error formatting display name.",e))}}function P(e,t){var i=(0,n.GT)(t),o=(0,r.__assign)((0,r.__assign)({},n.JF),e),a=o.locale,u=o.defaultLocale,h=o.onError;return a?!Intl.NumberFormat.supportedLocalesOf(a).length&&h?h(new s.hr('Missing locale data for locale: "'.concat(a,'" in Intl.NumberFormat. Using default locale: "').concat(u,'" as fallback. See https://formatjs.io/docs/react-intl#runtime-requirements for more details'))):!Intl.DateTimeFormat.supportedLocalesOf(a).length&&h&&h(new s.hr('Missing locale data for locale: "'.concat(a,'" in Intl.DateTimeFormat. Using default locale: "').concat(u,'" as fallback. See https://formatjs.io/docs/react-intl#runtime-requirements for more details'))):(h&&h(new s.uo('"locale" was not configured, using "'.concat(u,'" as fallback. See https://formatjs.io/docs/react-intl/api#intlshape for more details'))),o.locale=o.defaultLocale||"en"),function(e){var t;e.onWarn&&e.defaultRichTextElements&&"string"==typeof((t=e.messages||{})?t[Object.keys(t)[0]]:void 0)&&e.onWarn('[@formatjs/intl] "defaultRichTextElements" was specified but "message" was not pre-compiled. \nPlease consider using "@formatjs/cli" to pre-compile your messages for performance.\nFor more details see https://formatjs.io/docs/getting-started/message-distribution')}(o),(0,r.__assign)((0,r.__assign)({},o),{formatters:i,formatNumber:l.bind(null,o,i.getNumberFormat),formatNumberToParts:c.bind(null,o,i.getNumberFormat),formatRelativeTime:d.bind(null,o,i.getRelativeTimeFormat),formatDate:f.bind(null,o,i.getDateTimeFormat),formatDateToParts:C.bind(null,o,i.getDateTimeFormat),formatTime:m.bind(null,o,i.getDateTimeFormat),formatDateTimeRange:v.bind(null,o,i.getDateTimeFormat),formatTimeToParts:y.bind(null,o,i.getDateTimeFormat),formatPlural:S.bind(null,o,i.getPluralRules),formatMessage:b.h.bind(null,o,i),$t:b.h.bind(null,o,i),formatList:T.bind(null,o,i.getListFormat),formatListToParts:M.bind(null,o,i.getListFormat),formatDisplayName:_.bind(null,o,i.getDisplayNames)})}},71984(e,t,i){"use strict";i.d(t,{Ar:()=>s,Ho:()=>u,OC:()=>o,hr:()=>l,lo:()=>r,pg:()=>c,sb:()=>h,uo:()=>a});var r,n=i(65959);!function(e){e.FORMAT_ERROR="FORMAT_ERROR",e.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",e.INVALID_CONFIG="INVALID_CONFIG",e.MISSING_DATA="MISSING_DATA",e.MISSING_TRANSLATION="MISSING_TRANSLATION"}(r||(r={}));var s=function(e){function t(i,r,n){var s=this,o=n?n instanceof Error?n:new Error(String(n)):void 0;return(s=e.call(this,"[@formatjs/intl Error ".concat(i,"] ").concat(r," \n").concat(o?"\n".concat(o.message,"\n").concat(o.stack):""))||this).code=i,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(s,t),s}return(0,n.__extends)(t,e),t}(Error),o=function(e){function t(t,i){return e.call(this,r.UNSUPPORTED_FORMATTER,t,i)||this}return(0,n.__extends)(t,e),t}(s),a=function(e){function t(t,i){return e.call(this,r.INVALID_CONFIG,t,i)||this}return(0,n.__extends)(t,e),t}(s),l=function(e){function t(t,i){return e.call(this,r.MISSING_DATA,t,i)||this}return(0,n.__extends)(t,e),t}(s),c=function(e){function t(t,i,n){return e.call(this,r.FORMAT_ERROR,"".concat(t," \nLocale: ").concat(i,"\n"),n)||this}return(0,n.__extends)(t,e),t}(s),u=function(e){function t(t,i,r,n){var s=e.call(this,"".concat(t," \nMessageID: ").concat(null==r?void 0:r.id,"\nDefault Message: ").concat(null==r?void 0:r.defaultMessage,"\nDescription: ").concat(null==r?void 0:r.description," \n"),i,n)||this;return s.descriptor=r,s}return(0,n.__extends)(t,e),t}(c),h=function(e){function t(t,i){var n=e.call(this,r.MISSING_TRANSLATION,'Missing message: "'.concat(t.id,'" for locale "').concat(i,'", using ').concat(t.defaultMessage?"default message":"id"," as fallback."))||this;return n.descriptor=t,n}return(0,n.__extends)(t,e),t}(s)},62954(e,t,i){"use strict";i.d(t,{h:()=>h});var r=i(65959),n=i(3704),s=i(92859),o=i(71984),a=i(26140);function l(e,t){return Object.keys(e).reduce(function(i,n){return i[n]=(0,r.__assign)({timeZone:t},e[n]),i},{})}function c(e,t){return Object.keys((0,r.__assign)((0,r.__assign)({},e),t)).reduce(function(i,n){return i[n]=(0,r.__assign)((0,r.__assign)({},e[n]||{}),t[n]||{}),i},{})}function u(e,t){if(!t)return e;var i=s.S.formats;return(0,r.__assign)((0,r.__assign)((0,r.__assign)({},i),e),{date:c(l(i.date,t),l(e.date||{},t)),time:c(l(i.time,t),l(e.time||{},t))})}function h(e,t,i,s,l){var c=e.locale,h=e.formats,d=e.messages,p=e.defaultLocale,g=e.defaultFormats,f=e.fallbackOnEmptyString,m=e.onError,v=e.timeZone,C=e.defaultRichTextElements;void 0===i&&(i={id:""});var y=i.id,w=i.defaultMessage;(0,n.V1)(!!y,"[@formatjs/intl] An `id` must be provided to format a message. You can either:\n1. Configure your build toolchain with [babel-plugin-formatjs](https://formatjs.io/docs/tooling/babel-plugin)\nor [@formatjs/ts-transformer](https://formatjs.io/docs/tooling/ts-transformer) OR\n2. Configure your `eslint` config to include [eslint-plugin-formatjs](https://formatjs.io/docs/tooling/linter#enforce-id)\nto autofix this issue");var S=String(y),b=d&&Object.prototype.hasOwnProperty.call(d,S)&&d[S];if(Array.isArray(b)&&1===b.length&&b[0].type===a.ZE.literal)return b[0].value;if(!s&&b&&"string"==typeof b&&!C)return b.replace(/'\{(.*?)\}'/gi,"{$1}");if(s=(0,r.__assign)((0,r.__assign)({},C),s||{}),h=u(h,v),g=u(g,v),!b){if(!1===f&&""===b)return b;if((!w||c&&c.toLowerCase()!==p.toLowerCase())&&m(new o.sb(i,c)),w)try{return t.getMessageFormat(w,p,g,l).format(s)}catch(e){return m(new o.Ho('Error formatting default message for: "'.concat(S,'", rendering default message verbatim'),c,i,e)),"string"==typeof w?w:S}return S}try{return t.getMessageFormat(b,c,h,(0,r.__assign)({formatters:t},l||{})).format(s)}catch(e){m(new o.Ho('Error formatting message: "'.concat(S,'", using ').concat(w?"default message":"id"," as fallback."),c,i,e))}if(w)try{return t.getMessageFormat(w,p,g,l).format(s)}catch(e){m(new o.Ho('Error formatting the default message for: "'.concat(S,'", rendering message verbatim'),c,i,e))}return"string"==typeof b?b:"string"==typeof w?w:S}},14716(e,t,i){"use strict";i.d(t,{F3:()=>d,GT:()=>h,J9:()=>a,JF:()=>l,MT:()=>c});var r=i(65959),n=i(92859),s=i(59556),o=i(71984);function a(e,t,i){return void 0===i&&(i={}),t.reduce(function(t,r){return r in e?t[r]=e[r]:r in i&&(t[r]=i[r]),t},{})}var l={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:function(e){},onWarn:function(e){}};function c(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function u(e){return{create:function(){return{get:function(t){return e[t]},set:function(t,i){e[t]=i}}}}}function h(e){void 0===e&&(e={dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}});var t=Intl.RelativeTimeFormat,i=Intl.ListFormat,o=Intl.DisplayNames,a=(0,s.A)(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.DateTimeFormat).bind.apply(e,(0,r.__spreadArray)([void 0],t,!1)))},{cache:u(e.dateTime),strategy:s.W.variadic}),l=(0,s.A)(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.NumberFormat).bind.apply(e,(0,r.__spreadArray)([void 0],t,!1)))},{cache:u(e.number),strategy:s.W.variadic}),c=(0,s.A)(function(){for(var e,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return new((e=Intl.PluralRules).bind.apply(e,(0,r.__spreadArray)([void 0],t,!1)))},{cache:u(e.pluralRules),strategy:s.W.variadic});return{getDateTimeFormat:a,getNumberFormat:l,getMessageFormat:(0,s.A)(function(e,t,i,s){return new n.S(e,t,i,(0,r.__assign)({formatters:{getNumberFormat:l,getDateTimeFormat:a,getPluralRules:c}},s||{}))},{cache:u(e.message),strategy:s.W.variadic}),getRelativeTimeFormat:(0,s.A)(function(){for(var e=[],i=0;i<arguments.length;i++)e[i]=arguments[i];return new(t.bind.apply(t,(0,r.__spreadArray)([void 0],e,!1)))},{cache:u(e.relativeTime),strategy:s.W.variadic}),getPluralRules:c,getListFormat:(0,s.A)(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(i.bind.apply(i,(0,r.__spreadArray)([void 0],e,!1)))},{cache:u(e.list),strategy:s.W.variadic}),getDisplayNames:(0,s.A)(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return new(o.bind.apply(o,(0,r.__spreadArray)([void 0],e,!1)))},{cache:u(e.displayNames),strategy:s.W.variadic})}}function d(e,t,i,r){var n,s=e&&e[t];if(s&&(n=s[i]),n)return n;r(new o.OC("No ".concat(t," format named: ").concat(i)))}},5188(e,t,i){"use strict";function r(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,r)}return i}function n(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?r(Object(i),!0).forEach(function(t){a(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):r(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function s(e){return s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},s(e)}function o(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function a(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var r,n,s=[],o=!0,a=!1;try{for(i=i.call(e);!(o=(r=i.next()).done)&&(s.push(r.value),!t||s.length!==t);o=!0);}catch(e){a=!0,n=e}finally{try{o||null==i.return||i.return()}finally{if(a)throw n}}return s}}(e,t)||u(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function c(e){return function(e){if(Array.isArray(e))return h(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||u(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){if(e){if("string"==typeof e)return h(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?h(e,t):void 0}}function h(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,r=new Array(t);i<t;i++)r[i]=e[i];return r}i.r(t),i.d(t,{api:()=>Qe,config:()=>$t,counter:()=>ii,dom:()=>Yt,findIconDefinition:()=>Xt,icon:()=>Jt,layer:()=>ei,library:()=>qt,noAuto:()=>Kt,parse:()=>Qt,text:()=>ti,toHtml:()=>Zt});var d=function(){},p={},g={},f=null,m={mark:d,measure:d};try{"undefined"!=typeof window&&(p=window),"undefined"!=typeof document&&(g=document),"undefined"!=typeof MutationObserver&&(f=MutationObserver),"undefined"!=typeof performance&&(m=performance)}catch(e){}var v=(p.navigator||{}).userAgent,C=void 0===v?"":v,y=p,w=g,S=f,b=m,E=(y.document,!!w.documentElement&&!!w.head&&"function"==typeof w.addEventListener&&"function"==typeof w.createElement),A=~C.indexOf("MSIE")||~C.indexOf("Trident/"),T="___FONT_AWESOME___",M="svg-inline--fa",R="data-fa-i2svg",_="data-fa-pseudo-element",P="data-prefix",x="data-icon",D="fontawesome-i2svg",I=["HTML","HEAD","STYLE","SCRIPT"],L=function(){try{return!0}catch(e){return!1}}(),N={fas:"solid","fa-solid":"solid",far:"regular","fa-regular":"regular",fal:"light","fa-light":"light",fat:"thin","fa-thin":"thin",fad:"duotone","fa-duotone":"duotone",fab:"brands","fa-brands":"brands",fak:"kit","fa-kit":"kit",fa:"solid"},O={solid:"fas",regular:"far",light:"fal",thin:"fat",duotone:"fad",brands:"fab",kit:"fak"},F={fab:"fa-brands",fad:"fa-duotone",fak:"fa-kit",fal:"fa-light",far:"fa-regular",fas:"fa-solid",fat:"fa-thin"},k={"fa-brands":"fab","fa-duotone":"fad","fa-kit":"fak","fa-light":"fal","fa-regular":"far","fa-solid":"fas","fa-thin":"fat"},G=/fa[srltdbk\-\ ]/,V="fa-layers-text",H=/Font ?Awesome ?([56 ]*)(Solid|Regular|Light|Thin|Duotone|Brands|Free|Pro|Kit)?.*/i,B={900:"fas",400:"far",normal:"far",300:"fal",100:"fat"},z=[1,2,3,4,5,6,7,8,9,10],U=z.concat([11,12,13,14,15,16,17,18,19,20]),W=["class","data-prefix","data-icon","data-fa-transform","data-fa-mask"],j="duotone-group",K="primary",$="secondary",q=[].concat(c(Object.keys(O)),["2xs","xs","sm","lg","xl","2xl","beat","border","fade","beat-fade","bounce","flip-both","flip-horizontal","flip-vertical","flip","fw","inverse","layers-counter","layers-text","layers","li","pull-left","pull-right","pulse","rotate-180","rotate-270","rotate-90","rotate-by","shake","spin-pulse","spin-reverse","spin","stack-1x","stack-2x","stack","ul",j,"swap-opacity",K,$]).concat(z.map(function(e){return"".concat(e,"x")})).concat(U.map(function(e){return"w-".concat(e)})),Y=y.FontAwesomeConfig||{};w&&"function"==typeof w.querySelector&&[["data-family-prefix","familyPrefix"],["data-style-default","styleDefault"],["data-replacement-class","replacementClass"],["data-auto-replace-svg","autoReplaceSvg"],["data-auto-add-css","autoAddCss"],["data-auto-a11y","autoA11y"],["data-search-pseudo-elements","searchPseudoElements"],["data-observe-mutations","observeMutations"],["data-mutate-approach","mutateApproach"],["data-keep-original-source","keepOriginalSource"],["data-measure-performance","measurePerformance"],["data-show-missing-icons","showMissingIcons"]].forEach(function(e){var t=l(e,2),i=t[0],r=t[1],n=function(e){return""===e||"false"!==e&&("true"===e||e)}(function(e){var t=w.querySelector("script["+e+"]");if(t)return t.getAttribute(e)}(i));null!=n&&(Y[r]=n)});var Q=n(n({},{familyPrefix:"fa",styleDefault:"solid",replacementClass:M,autoReplaceSvg:!0,autoAddCss:!0,autoA11y:!0,searchPseudoElements:!1,observeMutations:!0,mutateApproach:"async",keepOriginalSource:!0,measurePerformance:!1,showMissingIcons:!0}),Y);Q.autoReplaceSvg||(Q.observeMutations=!1);var X={};Object.keys(Q).forEach(function(e){Object.defineProperty(X,e,{enumerable:!0,set:function(t){Q[e]=t,Z.forEach(function(e){return e(X)})},get:function(){return Q[e]}})}),y.FontAwesomeConfig=X;var Z=[],J=16,ee={size:16,x:0,y:0,rotate:0,flipX:!1,flipY:!1};function te(){for(var e=12,t="";e-- >0;)t+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[62*Math.random()|0];return t}function ie(e){for(var t=[],i=(e||[]).length>>>0;i--;)t[i]=e[i];return t}function re(e){return e.classList?ie(e.classList):(e.getAttribute("class")||"").split(" ").filter(function(e){return e})}function ne(e){return"".concat(e).replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#39;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function se(e){return Object.keys(e||{}).reduce(function(t,i){return t+"".concat(i,": ").concat(e[i].trim(),";")},"")}function oe(e){return e.size!==ee.size||e.x!==ee.x||e.y!==ee.y||e.rotate!==ee.rotate||e.flipX||e.flipY}function ae(){var e="fa",t=M,i=X.familyPrefix,r=X.replacementClass,n=':root, :host {\n  --fa-font-solid: normal 900 1em/1 "Font Awesome 6 Solid";\n  --fa-font-regular: normal 400 1em/1 "Font Awesome 6 Regular";\n  --fa-font-light: normal 300 1em/1 "Font Awesome 6 Light";\n  --fa-font-thin: normal 100 1em/1 "Font Awesome 6 Thin";\n  --fa-font-duotone: normal 900 1em/1 "Font Awesome 6 Duotone";\n  --fa-font-brands: normal 400 1em/1 "Font Awesome 6 Brands";\n}\n\nsvg:not(:root).svg-inline--fa, svg:not(:host).svg-inline--fa {\n  overflow: visible;\n  box-sizing: content-box;\n}\n\n.svg-inline--fa {\n  display: var(--fa-display, inline-block);\n  height: 1em;\n  overflow: visible;\n  vertical-align: -0.125em;\n}\n.svg-inline--fa.fa-2xs {\n  vertical-align: 0.1em;\n}\n.svg-inline--fa.fa-xs {\n  vertical-align: 0em;\n}\n.svg-inline--fa.fa-sm {\n  vertical-align: -0.0714285705em;\n}\n.svg-inline--fa.fa-lg {\n  vertical-align: -0.2em;\n}\n.svg-inline--fa.fa-xl {\n  vertical-align: -0.25em;\n}\n.svg-inline--fa.fa-2xl {\n  vertical-align: -0.3125em;\n}\n.svg-inline--fa.fa-pull-left {\n  margin-right: var(--fa-pull-margin, 0.3em);\n  width: auto;\n}\n.svg-inline--fa.fa-pull-right {\n  margin-left: var(--fa-pull-margin, 0.3em);\n  width: auto;\n}\n.svg-inline--fa.fa-li {\n  width: var(--fa-li-width, 2em);\n  top: 0.25em;\n}\n.svg-inline--fa.fa-fw {\n  width: var(--fa-fw-width, 1.25em);\n}\n\n.fa-layers svg.svg-inline--fa {\n  bottom: 0;\n  left: 0;\n  margin: auto;\n  position: absolute;\n  right: 0;\n  top: 0;\n}\n\n.fa-layers-counter, .fa-layers-text {\n  display: inline-block;\n  position: absolute;\n  text-align: center;\n}\n\n.fa-layers {\n  display: inline-block;\n  height: 1em;\n  position: relative;\n  text-align: center;\n  vertical-align: -0.125em;\n  width: 1em;\n}\n.fa-layers svg.svg-inline--fa {\n  -webkit-transform-origin: center center;\n          transform-origin: center center;\n}\n\n.fa-layers-text {\n  left: 50%;\n  top: 50%;\n  -webkit-transform: translate(-50%, -50%);\n          transform: translate(-50%, -50%);\n  -webkit-transform-origin: center center;\n          transform-origin: center center;\n}\n\n.fa-layers-counter {\n  background-color: var(--fa-counter-background-color, #ff253a);\n  border-radius: var(--fa-counter-border-radius, 1em);\n  box-sizing: border-box;\n  color: var(--fa-inverse, #fff);\n  line-height: var(--fa-counter-line-height, 1);\n  max-width: var(--fa-counter-max-width, 5em);\n  min-width: var(--fa-counter-min-width, 1.5em);\n  overflow: hidden;\n  padding: var(--fa-counter-padding, 0.25em 0.5em);\n  right: var(--fa-right, 0);\n  text-overflow: ellipsis;\n  top: var(--fa-top, 0);\n  -webkit-transform: scale(var(--fa-counter-scale, 0.25));\n          transform: scale(var(--fa-counter-scale, 0.25));\n  -webkit-transform-origin: top right;\n          transform-origin: top right;\n}\n\n.fa-layers-bottom-right {\n  bottom: var(--fa-bottom, 0);\n  right: var(--fa-right, 0);\n  top: auto;\n  -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n          transform: scale(var(--fa-layers-scale, 0.25));\n  -webkit-transform-origin: bottom right;\n          transform-origin: bottom right;\n}\n\n.fa-layers-bottom-left {\n  bottom: var(--fa-bottom, 0);\n  left: var(--fa-left, 0);\n  right: auto;\n  top: auto;\n  -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n          transform: scale(var(--fa-layers-scale, 0.25));\n  -webkit-transform-origin: bottom left;\n          transform-origin: bottom left;\n}\n\n.fa-layers-top-right {\n  top: var(--fa-top, 0);\n  right: var(--fa-right, 0);\n  -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n          transform: scale(var(--fa-layers-scale, 0.25));\n  -webkit-transform-origin: top right;\n          transform-origin: top right;\n}\n\n.fa-layers-top-left {\n  left: var(--fa-left, 0);\n  right: auto;\n  top: var(--fa-top, 0);\n  -webkit-transform: scale(var(--fa-layers-scale, 0.25));\n          transform: scale(var(--fa-layers-scale, 0.25));\n  -webkit-transform-origin: top left;\n          transform-origin: top left;\n}\n\n.fa-1x {\n  font-size: 1em;\n}\n\n.fa-2x {\n  font-size: 2em;\n}\n\n.fa-3x {\n  font-size: 3em;\n}\n\n.fa-4x {\n  font-size: 4em;\n}\n\n.fa-5x {\n  font-size: 5em;\n}\n\n.fa-6x {\n  font-size: 6em;\n}\n\n.fa-7x {\n  font-size: 7em;\n}\n\n.fa-8x {\n  font-size: 8em;\n}\n\n.fa-9x {\n  font-size: 9em;\n}\n\n.fa-10x {\n  font-size: 10em;\n}\n\n.fa-2xs {\n  font-size: 0.625em;\n  line-height: 0.1em;\n  vertical-align: 0.225em;\n}\n\n.fa-xs {\n  font-size: 0.75em;\n  line-height: 0.0833333337em;\n  vertical-align: 0.125em;\n}\n\n.fa-sm {\n  font-size: 0.875em;\n  line-height: 0.0714285718em;\n  vertical-align: 0.0535714295em;\n}\n\n.fa-lg {\n  font-size: 1.25em;\n  line-height: 0.05em;\n  vertical-align: -0.075em;\n}\n\n.fa-xl {\n  font-size: 1.5em;\n  line-height: 0.0416666682em;\n  vertical-align: -0.125em;\n}\n\n.fa-2xl {\n  font-size: 2em;\n  line-height: 0.03125em;\n  vertical-align: -0.1875em;\n}\n\n.fa-fw {\n  text-align: center;\n  width: 1.25em;\n}\n\n.fa-ul {\n  list-style-type: none;\n  margin-left: var(--fa-li-margin, 2.5em);\n  padding-left: 0;\n}\n.fa-ul > li {\n  position: relative;\n}\n\n.fa-li {\n  left: calc(var(--fa-li-width, 2em) * -1);\n  position: absolute;\n  text-align: center;\n  width: var(--fa-li-width, 2em);\n  line-height: inherit;\n}\n\n.fa-border {\n  border-color: var(--fa-border-color, #eee);\n  border-radius: var(--fa-border-radius, 0.1em);\n  border-style: var(--fa-border-style, solid);\n  border-width: var(--fa-border-width, 0.08em);\n  padding: var(--fa-border-padding, 0.2em 0.25em 0.15em);\n}\n\n.fa-pull-left {\n  float: left;\n  margin-right: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-pull-right {\n  float: right;\n  margin-left: var(--fa-pull-margin, 0.3em);\n}\n\n.fa-beat {\n  -webkit-animation-name: fa-beat;\n          animation-name: fa-beat;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out);\n          animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-bounce {\n  -webkit-animation-name: fa-bounce;\n          animation-name: fa-bounce;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n          animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.28, 0.84, 0.42, 1));\n}\n\n.fa-fade {\n  -webkit-animation-name: fa-fade;\n          animation-name: fa-fade;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n          animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-beat-fade {\n  -webkit-animation-name: fa-beat-fade;\n          animation-name: fa-beat-fade;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n          animation-timing-function: var(--fa-animation-timing, cubic-bezier(0.4, 0, 0.6, 1));\n}\n\n.fa-flip {\n  -webkit-animation-name: fa-flip;\n          animation-name: fa-flip;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, ease-in-out);\n          animation-timing-function: var(--fa-animation-timing, ease-in-out);\n}\n\n.fa-shake {\n  -webkit-animation-name: fa-shake;\n          animation-name: fa-shake;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, linear);\n          animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin {\n  -webkit-animation-name: fa-spin;\n          animation-name: fa-spin;\n  -webkit-animation-delay: var(--fa-animation-delay, 0);\n          animation-delay: var(--fa-animation-delay, 0);\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 2s);\n          animation-duration: var(--fa-animation-duration, 2s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, linear);\n          animation-timing-function: var(--fa-animation-timing, linear);\n}\n\n.fa-spin-reverse {\n  --fa-animation-direction: reverse;\n}\n\n.fa-pulse,\n.fa-spin-pulse {\n  -webkit-animation-name: fa-spin;\n          animation-name: fa-spin;\n  -webkit-animation-direction: var(--fa-animation-direction, normal);\n          animation-direction: var(--fa-animation-direction, normal);\n  -webkit-animation-duration: var(--fa-animation-duration, 1s);\n          animation-duration: var(--fa-animation-duration, 1s);\n  -webkit-animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n          animation-iteration-count: var(--fa-animation-iteration-count, infinite);\n  -webkit-animation-timing-function: var(--fa-animation-timing, steps(8));\n          animation-timing-function: var(--fa-animation-timing, steps(8));\n}\n\n@media (prefers-reduced-motion: reduce) {\n  .fa-beat,\n.fa-bounce,\n.fa-fade,\n.fa-beat-fade,\n.fa-flip,\n.fa-pulse,\n.fa-shake,\n.fa-spin,\n.fa-spin-pulse {\n    -webkit-animation-delay: -1ms;\n            animation-delay: -1ms;\n    -webkit-animation-duration: 1ms;\n            animation-duration: 1ms;\n    -webkit-animation-iteration-count: 1;\n            animation-iteration-count: 1;\n    transition-delay: 0s;\n    transition-duration: 0s;\n  }\n}\n@-webkit-keyframes fa-beat {\n  0%, 90% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n  45% {\n    -webkit-transform: scale(var(--fa-beat-scale, 1.25));\n            transform: scale(var(--fa-beat-scale, 1.25));\n  }\n}\n@keyframes fa-beat {\n  0%, 90% {\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n  45% {\n    -webkit-transform: scale(var(--fa-beat-scale, 1.25));\n            transform: scale(var(--fa-beat-scale, 1.25));\n  }\n}\n@-webkit-keyframes fa-bounce {\n  0% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n  10% {\n    -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n            transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n  }\n  30% {\n    -webkit-transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n            transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n  }\n  50% {\n    -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n            transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n  }\n  57% {\n    -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n            transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n  }\n  64% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n  100% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n}\n@keyframes fa-bounce {\n  0% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n  10% {\n    -webkit-transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n            transform: scale(var(--fa-bounce-start-scale-x, 1.1), var(--fa-bounce-start-scale-y, 0.9)) translateY(0);\n  }\n  30% {\n    -webkit-transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n            transform: scale(var(--fa-bounce-jump-scale-x, 0.9), var(--fa-bounce-jump-scale-y, 1.1)) translateY(var(--fa-bounce-height, -0.5em));\n  }\n  50% {\n    -webkit-transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n            transform: scale(var(--fa-bounce-land-scale-x, 1.05), var(--fa-bounce-land-scale-y, 0.95)) translateY(0);\n  }\n  57% {\n    -webkit-transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n            transform: scale(1, 1) translateY(var(--fa-bounce-rebound, -0.125em));\n  }\n  64% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n  100% {\n    -webkit-transform: scale(1, 1) translateY(0);\n            transform: scale(1, 1) translateY(0);\n  }\n}\n@-webkit-keyframes fa-fade {\n  50% {\n    opacity: var(--fa-fade-opacity, 0.4);\n  }\n}\n@keyframes fa-fade {\n  50% {\n    opacity: var(--fa-fade-opacity, 0.4);\n  }\n}\n@-webkit-keyframes fa-beat-fade {\n  0%, 100% {\n    opacity: var(--fa-beat-fade-opacity, 0.4);\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n  50% {\n    opacity: 1;\n    -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125));\n            transform: scale(var(--fa-beat-fade-scale, 1.125));\n  }\n}\n@keyframes fa-beat-fade {\n  0%, 100% {\n    opacity: var(--fa-beat-fade-opacity, 0.4);\n    -webkit-transform: scale(1);\n            transform: scale(1);\n  }\n  50% {\n    opacity: 1;\n    -webkit-transform: scale(var(--fa-beat-fade-scale, 1.125));\n            transform: scale(var(--fa-beat-fade-scale, 1.125));\n  }\n}\n@-webkit-keyframes fa-flip {\n  50% {\n    -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n            transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n  }\n}\n@keyframes fa-flip {\n  50% {\n    -webkit-transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n            transform: rotate3d(var(--fa-flip-x, 0), var(--fa-flip-y, 1), var(--fa-flip-z, 0), var(--fa-flip-angle, -180deg));\n  }\n}\n@-webkit-keyframes fa-shake {\n  0% {\n    -webkit-transform: rotate(-15deg);\n            transform: rotate(-15deg);\n  }\n  4% {\n    -webkit-transform: rotate(15deg);\n            transform: rotate(15deg);\n  }\n  8%, 24% {\n    -webkit-transform: rotate(-18deg);\n            transform: rotate(-18deg);\n  }\n  12%, 28% {\n    -webkit-transform: rotate(18deg);\n            transform: rotate(18deg);\n  }\n  16% {\n    -webkit-transform: rotate(-22deg);\n            transform: rotate(-22deg);\n  }\n  20% {\n    -webkit-transform: rotate(22deg);\n            transform: rotate(22deg);\n  }\n  32% {\n    -webkit-transform: rotate(-12deg);\n            transform: rotate(-12deg);\n  }\n  36% {\n    -webkit-transform: rotate(12deg);\n            transform: rotate(12deg);\n  }\n  40%, 100% {\n    -webkit-transform: rotate(0deg);\n            transform: rotate(0deg);\n  }\n}\n@keyframes fa-shake {\n  0% {\n    -webkit-transform: rotate(-15deg);\n            transform: rotate(-15deg);\n  }\n  4% {\n    -webkit-transform: rotate(15deg);\n            transform: rotate(15deg);\n  }\n  8%, 24% {\n    -webkit-transform: rotate(-18deg);\n            transform: rotate(-18deg);\n  }\n  12%, 28% {\n    -webkit-transform: rotate(18deg);\n            transform: rotate(18deg);\n  }\n  16% {\n    -webkit-transform: rotate(-22deg);\n            transform: rotate(-22deg);\n  }\n  20% {\n    -webkit-transform: rotate(22deg);\n            transform: rotate(22deg);\n  }\n  32% {\n    -webkit-transform: rotate(-12deg);\n            transform: rotate(-12deg);\n  }\n  36% {\n    -webkit-transform: rotate(12deg);\n            transform: rotate(12deg);\n  }\n  40%, 100% {\n    -webkit-transform: rotate(0deg);\n            transform: rotate(0deg);\n  }\n}\n@-webkit-keyframes fa-spin {\n  0% {\n    -webkit-transform: rotate(0deg);\n            transform: rotate(0deg);\n  }\n  100% {\n    -webkit-transform: rotate(360deg);\n            transform: rotate(360deg);\n  }\n}\n@keyframes fa-spin {\n  0% {\n    -webkit-transform: rotate(0deg);\n            transform: rotate(0deg);\n  }\n  100% {\n    -webkit-transform: rotate(360deg);\n            transform: rotate(360deg);\n  }\n}\n.fa-rotate-90 {\n  -webkit-transform: rotate(90deg);\n          transform: rotate(90deg);\n}\n\n.fa-rotate-180 {\n  -webkit-transform: rotate(180deg);\n          transform: rotate(180deg);\n}\n\n.fa-rotate-270 {\n  -webkit-transform: rotate(270deg);\n          transform: rotate(270deg);\n}\n\n.fa-flip-horizontal {\n  -webkit-transform: scale(-1, 1);\n          transform: scale(-1, 1);\n}\n\n.fa-flip-vertical {\n  -webkit-transform: scale(1, -1);\n          transform: scale(1, -1);\n}\n\n.fa-flip-both,\n.fa-flip-horizontal.fa-flip-vertical {\n  -webkit-transform: scale(-1, -1);\n          transform: scale(-1, -1);\n}\n\n.fa-rotate-by {\n  -webkit-transform: rotate(var(--fa-rotate-angle, none));\n          transform: rotate(var(--fa-rotate-angle, none));\n}\n\n.fa-stack {\n  display: inline-block;\n  vertical-align: middle;\n  height: 2em;\n  position: relative;\n  width: 2.5em;\n}\n\n.fa-stack-1x,\n.fa-stack-2x {\n  bottom: 0;\n  left: 0;\n  margin: auto;\n  position: absolute;\n  right: 0;\n  top: 0;\n  z-index: var(--fa-stack-z-index, auto);\n}\n\n.svg-inline--fa.fa-stack-1x {\n  height: 1em;\n  width: 1.25em;\n}\n.svg-inline--fa.fa-stack-2x {\n  height: 2em;\n  width: 2.5em;\n}\n\n.fa-inverse {\n  color: var(--fa-inverse, #fff);\n}\n\n.sr-only,\n.fa-sr-only {\n  position: absolute;\n  width: 1px;\n  height: 1px;\n  padding: 0;\n  margin: -1px;\n  overflow: hidden;\n  clip: rect(0, 0, 0, 0);\n  white-space: nowrap;\n  border-width: 0;\n}\n\n.sr-only-focusable:not(:focus),\n.fa-sr-only-focusable:not(:focus) {\n  position: absolute;\n  width: 1px;\n  height: 1px;\n  padding: 0;\n  margin: -1px;\n  overflow: hidden;\n  clip: rect(0, 0, 0, 0);\n  white-space: nowrap;\n  border-width: 0;\n}\n\n.svg-inline--fa .fa-primary {\n  fill: var(--fa-primary-color, currentColor);\n  opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa .fa-secondary {\n  fill: var(--fa-secondary-color, currentColor);\n  opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-primary {\n  opacity: var(--fa-secondary-opacity, 0.4);\n}\n\n.svg-inline--fa.fa-swap-opacity .fa-secondary {\n  opacity: var(--fa-primary-opacity, 1);\n}\n\n.svg-inline--fa mask .fa-primary,\n.svg-inline--fa mask .fa-secondary {\n  fill: black;\n}\n\n.fad.fa-inverse,\n.fa-duotone.fa-inverse {\n  color: var(--fa-inverse, #fff);\n}';if(i!==e||r!==t){var s=new RegExp("\\.".concat(e,"\\-"),"g"),o=new RegExp("\\--".concat(e,"\\-"),"g"),a=new RegExp("\\.".concat(t),"g");n=n.replace(s,".".concat(i,"-")).replace(o,"--".concat(i,"-")).replace(a,".".concat(r))}return n}var le=!1;function ce(){X.autoAddCss&&!le&&(function(e){if(e&&E){var t=w.createElement("style");t.setAttribute("type","text/css"),t.innerHTML=e;for(var i=w.head.childNodes,r=null,n=i.length-1;n>-1;n--){var s=i[n],o=(s.tagName||"").toUpperCase();["STYLE","LINK"].indexOf(o)>-1&&(r=s)}w.head.insertBefore(t,r)}}(ae()),le=!0)}var ue={mixout:function(){return{dom:{css:ae,insertCss:ce}}},hooks:function(){return{beforeDOMElementCreation:function(){ce()},beforeI2svg:function(){ce()}}}},he=y||{};he[T]||(he[T]={}),he[T].styles||(he[T].styles={}),he[T].hooks||(he[T].hooks={}),he[T].shims||(he[T].shims=[]);var de=he[T],pe=[],ge=!1;function fe(e){var t=e.tag,i=e.attributes,r=void 0===i?{}:i,n=e.children,s=void 0===n?[]:n;return"string"==typeof e?ne(e):"<".concat(t," ").concat(function(e){return Object.keys(e||{}).reduce(function(t,i){return t+"".concat(i,'="').concat(ne(e[i]),'" ')},"").trim()}(r),">").concat(s.map(fe).join(""),"</").concat(t,">")}function me(e,t,i){if(e&&e[t]&&e[t][i])return{prefix:t,iconName:i,icon:e[t][i]}}E&&((ge=(w.documentElement.doScroll?/^loaded|^c/:/^loaded|^i|^c/).test(w.readyState))||w.addEventListener("DOMContentLoaded",function e(){w.removeEventListener("DOMContentLoaded",e),ge=1,pe.map(function(e){return e()})}));var ve=function(e,t,i,r){var n,s,o,a=Object.keys(e),l=a.length,c=void 0!==r?function(e,t){return function(i,r,n,s){return e.call(t,i,r,n,s)}}(t,r):t;for(void 0===i?(n=1,o=e[a[0]]):(n=0,o=i);n<l;n++)o=c(o,e[s=a[n]],s,e);return o};function Ce(e){var t=function(e){for(var t=[],i=0,r=e.length;i<r;){var n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){var s=e.charCodeAt(i++);56320==(64512&s)?t.push(((1023&n)<<10)+(1023&s)+65536):(t.push(n),i--)}else t.push(n)}return t}(e);return 1===t.length?t[0].toString(16):null}function ye(e){return Object.keys(e).reduce(function(t,i){var r=e[i];return r.icon?t[r.iconName]=r.icon:t[i]=r,t},{})}function we(e,t){var i=(arguments.length>2&&void 0!==arguments[2]?arguments[2]:{}).skipHooks,r=void 0!==i&&i,s=ye(t);"function"!=typeof de.hooks.addPack||r?de.styles[e]=n(n({},de.styles[e]||{}),s):de.hooks.addPack(e,ye(t)),"fas"===e&&we("fa",t)}var Se=de.styles,be=de.shims,Ee=Object.values(F),Ae=null,Te={},Me={},Re={},_e={},Pe={},xe=Object.keys(N);var De,Ie=function(){var e=function(e){return ve(Se,function(t,i,r){return t[r]=ve(i,e,{}),t},{})};Te=e(function(e,t,i){return t[3]&&(e[t[3]]=i),t[2]&&t[2].filter(function(e){return"number"==typeof e}).forEach(function(t){e[t.toString(16)]=i}),e}),Me=e(function(e,t,i){return e[i]=i,t[2]&&t[2].filter(function(e){return"string"==typeof e}).forEach(function(t){e[t]=i}),e}),Pe=e(function(e,t,i){var r=t[2];return e[i]=i,r.forEach(function(t){e[t]=i}),e});var t="far"in Se||X.autoFetchSvg,i=ve(be,function(e,i){var r=i[0],n=i[1],s=i[2];return"far"!==n||t||(n="fas"),"string"==typeof r&&(e.names[r]={prefix:n,iconName:s}),"number"==typeof r&&(e.unicodes[r.toString(16)]={prefix:n,iconName:s}),e},{names:{},unicodes:{}});Re=i.names,_e=i.unicodes,Ae=ke(X.styleDefault)};function Le(e,t){return(Te[e]||{})[t]}function Ne(e,t){return(Pe[e]||{})[t]}function Oe(e){return Re[e]||{prefix:null,iconName:null}}function Fe(){return Ae}function ke(e){var t=O[e]||O[N[e]],i=e in de.styles?e:null;return t||i||null}function Ge(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).skipLookups,i=void 0!==t&&t,r=null,n=e.reduce(function(e,t){var n=function(e,t){var i,r=t.split("-"),n=r[0],s=r.slice(1).join("-");return n!==e||""===s||(i=s,~q.indexOf(i))?null:s}(X.familyPrefix,t);if(Se[t]?(t=Ee.includes(t)?k[t]:t,r=t,e.prefix=t):xe.indexOf(t)>-1?(r=t,e.prefix=ke(t)):n?e.iconName=n:t!==X.replacementClass&&e.rest.push(t),!i&&e.prefix&&e.iconName){var s="fa"===r?Oe(e.iconName):{},o=Ne(e.prefix,e.iconName);s.prefix&&(r=null),e.iconName=s.iconName||o||e.iconName,e.prefix=s.prefix||e.prefix,"far"!==e.prefix||Se.far||!Se.fas||X.autoFetchSvg||(e.prefix="fas")}return e},{prefix:null,iconName:null,rest:[]});return"fa"!==n.prefix&&"fa"!==r||(n.prefix=Fe()||"fas"),n}De=function(e){Ae=ke(e.styleDefault)},Z.push(De),Ie();var Ve=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.definitions={}}var t,i;return t=e,i=[{key:"add",value:function(){for(var e=this,t=arguments.length,i=new Array(t),r=0;r<t;r++)i[r]=arguments[r];var s=i.reduce(this._pullDefinitions,{});Object.keys(s).forEach(function(t){e.definitions[t]=n(n({},e.definitions[t]||{}),s[t]),we(t,s[t]);var i=F[t];i&&we(i,s[t]),Ie()})}},{key:"reset",value:function(){this.definitions={}}},{key:"_pullDefinitions",value:function(e,t){var i=t.prefix&&t.iconName&&t.icon?{0:t}:t;return Object.keys(i).map(function(t){var r=i[t],n=r.prefix,s=r.iconName,o=r.icon,a=o[2];e[n]||(e[n]={}),a.length>0&&a.forEach(function(t){"string"==typeof t&&(e[n][t]=o)}),e[n][s]=o}),e}}],i&&o(t.prototype,i),Object.defineProperty(t,"prototype",{writable:!1}),e}(),He=[],Be={},ze={},Ue=Object.keys(ze);function We(e,t){for(var i=arguments.length,r=new Array(i>2?i-2:0),n=2;n<i;n++)r[n-2]=arguments[n];return(Be[e]||[]).forEach(function(e){t=e.apply(null,[t].concat(r))}),t}function je(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),r=1;r<t;r++)i[r-1]=arguments[r];(Be[e]||[]).forEach(function(e){e.apply(null,i)})}function Ke(){var e=arguments[0],t=Array.prototype.slice.call(arguments,1);return ze[e]?ze[e].apply(null,t):void 0}function $e(e){"fa"===e.prefix&&(e.prefix="fas");var t=e.iconName,i=e.prefix||Fe();if(t)return t=Ne(i,t)||t,me(qe.definitions,i,t)||me(de.styles,i,t)}var qe=new Ve,Ye={i2svg:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return E?(je("beforeI2svg",e),Ke("pseudoElements2svg",e),Ke("i2svg",e)):Promise.reject("Operation requires a DOM of some kind.")},watch:function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.autoReplaceSvgRoot;!1===X.autoReplaceSvg&&(X.autoReplaceSvg=!0),X.observeMutations=!0,e=function(){Xe({autoReplaceSvgRoot:i}),je("watch",t)},E&&(ge?setTimeout(e,0):pe.push(e))}},Qe={noAuto:function(){X.autoReplaceSvg=!1,X.observeMutations=!1,je("noAuto")},config:X,dom:Ye,parse:{icon:function(e){if(null===e)return null;if("object"===s(e)&&e.prefix&&e.iconName)return{prefix:e.prefix,iconName:Ne(e.prefix,e.iconName)||e.iconName};if(Array.isArray(e)&&2===e.length){var t=0===e[1].indexOf("fa-")?e[1].slice(3):e[1],i=ke(e[0]);return{prefix:i,iconName:Ne(i,t)||t}}if("string"==typeof e&&(e.indexOf("".concat(X.familyPrefix,"-"))>-1||e.match(G))){var r=Ge(e.split(" "),{skipLookups:!0});return{prefix:r.prefix||Fe(),iconName:Ne(r.prefix,r.iconName)||r.iconName}}if("string"==typeof e){var n=Fe();return{prefix:n,iconName:Ne(n,e)||e}}}},library:qe,findIconDefinition:$e,toHtml:fe},Xe=function(){var e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}).autoReplaceSvgRoot,t=void 0===e?w:e;(Object.keys(de.styles).length>0||X.autoFetchSvg)&&E&&X.autoReplaceSvg&&Qe.dom.i2svg({node:t})};function Ze(e,t){return Object.defineProperty(e,"abstract",{get:t}),Object.defineProperty(e,"html",{get:function(){return e.abstract.map(function(e){return fe(e)})}}),Object.defineProperty(e,"node",{get:function(){if(E){var t=w.createElement("div");return t.innerHTML=e.html,t.children}}}),e}function Je(e){var t=e.icons,i=t.main,r=t.mask,s=e.prefix,o=e.iconName,a=e.transform,l=e.symbol,c=e.title,u=e.maskId,h=e.titleId,d=e.extra,p=e.watchable,g=void 0!==p&&p,f=r.found?r:i,m=f.width,v=f.height,C="fak"===s,y=[X.replacementClass,o?"".concat(X.familyPrefix,"-").concat(o):""].filter(function(e){return-1===d.classes.indexOf(e)}).filter(function(e){return""!==e||!!e}).concat(d.classes).join(" "),w={children:[],attributes:n(n({},d.attributes),{},{"data-prefix":s,"data-icon":o,class:y,role:d.attributes.role||"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 ".concat(m," ").concat(v)})},S=C&&!~d.classes.indexOf("fa-fw")?{width:"".concat(m/v*16*.0625,"em")}:{};g&&(w.attributes[R]=""),c&&(w.children.push({tag:"title",attributes:{id:w.attributes["aria-labelledby"]||"title-".concat(h||te())},children:[c]}),delete w.attributes.title);var b=n(n({},w),{},{prefix:s,iconName:o,main:i,mask:r,maskId:u,transform:a,symbol:l,styles:n(n({},S),d.styles)}),E=r.found&&i.found?Ke("generateAbstractMask",b)||{children:[],attributes:{}}:Ke("generateAbstractIcon",b)||{children:[],attributes:{}},A=E.children,T=E.attributes;return b.children=A,b.attributes=T,l?function(e){var t=e.prefix,i=e.iconName,r=e.children,s=e.attributes,o=e.symbol,a=!0===o?"".concat(t,"-").concat(X.familyPrefix,"-").concat(i):o;return[{tag:"svg",attributes:{style:"display: none;"},children:[{tag:"symbol",attributes:n(n({},s),{},{id:a}),children:r}]}]}(b):function(e){var t=e.children,i=e.main,r=e.mask,s=e.attributes,o=e.styles,a=e.transform;if(oe(a)&&i.found&&!r.found){var l={x:i.width/i.height/2,y:.5};s.style=se(n(n({},o),{},{"transform-origin":"".concat(l.x+a.x/16,"em ").concat(l.y+a.y/16,"em")}))}return[{tag:"svg",attributes:s,children:t}]}(b)}function et(e){var t=e.content,i=e.width,r=e.height,s=e.transform,o=e.title,a=e.extra,l=e.watchable,c=void 0!==l&&l,u=n(n(n({},a.attributes),o?{title:o}:{}),{},{class:a.classes.join(" ")});c&&(u[R]="");var h=n({},a.styles);oe(s)&&(h.transform=function(e){var t=e.transform,i=e.width,r=void 0===i?16:i,n=e.height,s=void 0===n?16:n,o=e.startCentered,a=void 0!==o&&o,l="";return l+=a&&A?"translate(".concat(t.x/J-r/2,"em, ").concat(t.y/J-s/2,"em) "):a?"translate(calc(-50% + ".concat(t.x/J,"em), calc(-50% + ").concat(t.y/J,"em)) "):"translate(".concat(t.x/J,"em, ").concat(t.y/J,"em) "),(l+="scale(".concat(t.size/J*(t.flipX?-1:1),", ").concat(t.size/J*(t.flipY?-1:1),") "))+"rotate(".concat(t.rotate,"deg) ")}({transform:s,startCentered:!0,width:i,height:r}),h["-webkit-transform"]=h.transform);var d=se(h);d.length>0&&(u.style=d);var p=[];return p.push({tag:"span",attributes:u,children:[t]}),o&&p.push({tag:"span",attributes:{class:"sr-only"},children:[o]}),p}var tt=de.styles;function it(e){var t=e[0],i=e[1],r=l(e.slice(4),1)[0];return{found:!0,width:t,height:i,icon:Array.isArray(r)?{tag:"g",attributes:{class:"".concat(X.familyPrefix,"-").concat(j)},children:[{tag:"path",attributes:{class:"".concat(X.familyPrefix,"-").concat($),fill:"currentColor",d:r[0]}},{tag:"path",attributes:{class:"".concat(X.familyPrefix,"-").concat(K),fill:"currentColor",d:r[1]}}]}:{tag:"path",attributes:{fill:"currentColor",d:r}}}}var rt={found:!1,width:512,height:512};function nt(e,t){var i=t;return"fa"===t&&null!==X.styleDefault&&(t=Fe()),new Promise(function(r,s){if(Ke("missingIconAbstract"),"fa"===i){var o=Oe(e)||{};e=o.iconName||e,t=o.prefix||t}if(e&&t&&tt[t]&&tt[t][e])return r(it(tt[t][e]));!function(e,t){L||X.showMissingIcons||!e||console.error('Icon with name "'.concat(e,'" and prefix "').concat(t,'" is missing.'))}(e,t),r(n(n({},rt),{},{icon:X.showMissingIcons&&e&&Ke("missingIconAbstract")||{}}))})}var st=function(){},ot=X.measurePerformance&&b&&b.mark&&b.measure?b:{mark:st,measure:st},at='FA "6.0.0"',lt=function(e){return ot.mark("".concat(at," ").concat(e," begins")),function(){return function(e){ot.mark("".concat(at," ").concat(e," ends")),ot.measure("".concat(at," ").concat(e),"".concat(at," ").concat(e," begins"),"".concat(at," ").concat(e," ends"))}(e)}},ct=function(){};function ut(e){return"string"==typeof(e.getAttribute?e.getAttribute(R):null)}function ht(e){return w.createElementNS("http://www.w3.org/2000/svg",e)}function dt(e){return w.createElement(e)}function pt(e){var t=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).ceFn,i=void 0===t?"svg"===e.tag?ht:dt:t;if("string"==typeof e)return w.createTextNode(e);var r=i(e.tag);return Object.keys(e.attributes||[]).forEach(function(t){r.setAttribute(t,e.attributes[t])}),(e.children||[]).forEach(function(e){r.appendChild(pt(e,{ceFn:i}))}),r}var gt={replace:function(e){var t=e[0];if(t.parentNode)if(e[1].forEach(function(e){t.parentNode.insertBefore(pt(e),t)}),null===t.getAttribute(R)&&X.keepOriginalSource){var i=w.createComment(function(e){var t=" ".concat(e.outerHTML," ");return"".concat(t,"Font Awesome fontawesome.com ")}(t));t.parentNode.replaceChild(i,t)}else t.remove()},nest:function(e){var t=e[0],i=e[1];if(~re(t).indexOf(X.replacementClass))return gt.replace(e);var r=new RegExp("".concat(X.familyPrefix,"-.*"));if(delete i[0].attributes.id,i[0].attributes.class){var n=i[0].attributes.class.split(" ").reduce(function(e,t){return t===X.replacementClass||t.match(r)?e.toSvg.push(t):e.toNode.push(t),e},{toNode:[],toSvg:[]});i[0].attributes.class=n.toSvg.join(" "),0===n.toNode.length?t.removeAttribute("class"):t.setAttribute("class",n.toNode.join(" "))}var s=i.map(function(e){return fe(e)}).join("\n");t.setAttribute(R,""),t.innerHTML=s}};function ft(e){e()}function mt(e,t){var i="function"==typeof t?t:ct;if(0===e.length)i();else{var r=ft;"async"===X.mutateApproach&&(r=y.requestAnimationFrame||ft),r(function(){var t=!0===X.autoReplaceSvg?gt.replace:gt[X.autoReplaceSvg]||gt.replace,r=lt("mutate");e.map(t),r(),i()})}}var vt=!1;function Ct(){vt=!0}function yt(){vt=!1}var wt=null;function St(e){if(S&&X.observeMutations){var t=e.treeCallback,i=void 0===t?ct:t,r=e.nodeCallback,n=void 0===r?ct:r,s=e.pseudoElementsCallback,o=void 0===s?ct:s,a=e.observeMutationsRoot,l=void 0===a?w:a;wt=new S(function(e){if(!vt){var t=Fe();ie(e).forEach(function(e){if("childList"===e.type&&e.addedNodes.length>0&&!ut(e.addedNodes[0])&&(X.searchPseudoElements&&o(e.target),i(e.target)),"attributes"===e.type&&e.target.parentNode&&X.searchPseudoElements&&o(e.target.parentNode),"attributes"===e.type&&ut(e.target)&&~W.indexOf(e.attributeName))if("class"===e.attributeName&&function(e){var t=e.getAttribute?e.getAttribute(P):null,i=e.getAttribute?e.getAttribute(x):null;return t&&i}(e.target)){var r=Ge(re(e.target)),s=r.prefix,a=r.iconName;e.target.setAttribute(P,s||t),a&&e.target.setAttribute(x,a)}else(l=e.target)&&l.classList&&l.classList.contains&&l.classList.contains(X.replacementClass)&&n(e.target);var l})}}),E&&wt.observe(l,{childList:!0,attributes:!0,characterData:!0,subtree:!0})}}function bt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{styleParser:!0},i=function(e){var t,i,r=e.getAttribute("data-prefix"),n=e.getAttribute("data-icon"),s=void 0!==e.innerText?e.innerText.trim():"",o=Ge(re(e));return o.prefix||(o.prefix=Fe()),r&&n&&(o.prefix=r,o.iconName=n),o.iconName&&o.prefix||o.prefix&&s.length>0&&(o.iconName=(t=o.prefix,i=e.innerText,(Me[t]||{})[i]||Le(o.prefix,Ce(e.innerText)))),o}(e),r=i.iconName,s=i.prefix,o=i.rest,a=function(e){var t=ie(e.attributes).reduce(function(e,t){return"class"!==e.name&&"style"!==e.name&&(e[t.name]=t.value),e},{}),i=e.getAttribute("title"),r=e.getAttribute("data-fa-title-id");return X.autoA11y&&(i?t["aria-labelledby"]="".concat(X.replacementClass,"-title-").concat(r||te()):(t["aria-hidden"]="true",t.focusable="false")),t}(e),l=We("parseNodeAttributes",{},e),c=t.styleParser?function(e){var t=e.getAttribute("style"),i=[];return t&&(i=t.split(";").reduce(function(e,t){var i=t.split(":"),r=i[0],n=i.slice(1);return r&&n.length>0&&(e[r]=n.join(":").trim()),e},{})),i}(e):[];return n({iconName:r,title:e.getAttribute("title"),titleId:e.getAttribute("data-fa-title-id"),prefix:s,transform:ee,mask:{iconName:null,prefix:null,rest:[]},maskId:null,symbol:!1,extra:{classes:o,styles:c,attributes:a}},l)}var Et=de.styles;function At(e){var t="nest"===X.autoReplaceSvg?bt(e,{styleParser:!1}):bt(e);return~t.extra.classes.indexOf(V)?Ke("generateLayersText",e,t):Ke("generateSvgReplacementMutation",e,t)}function Tt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if(!E)return Promise.resolve();var i=w.documentElement.classList,r=function(e){return i.add("".concat(D,"-").concat(e))},n=function(e){return i.remove("".concat(D,"-").concat(e))},s=X.autoFetchSvg?Object.keys(N):Object.keys(Et),o=[".".concat(V,":not([").concat(R,"])")].concat(s.map(function(e){return".".concat(e,":not([").concat(R,"])")})).join(", ");if(0===o.length)return Promise.resolve();var a=[];try{a=ie(e.querySelectorAll(o))}catch(e){}if(!(a.length>0))return Promise.resolve();r("pending"),n("complete");var l=lt("onTree"),c=a.reduce(function(e,t){try{var i=At(t);i&&e.push(i)}catch(e){L||"MissingIcon"===e.name&&console.error(e)}return e},[]);return new Promise(function(e,i){Promise.all(c).then(function(i){mt(i,function(){r("active"),r("complete"),n("pending"),"function"==typeof t&&t(),l(),e()})}).catch(function(e){l(),i(e)})})}function Mt(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;At(e).then(function(e){e&&mt([e],t)})}var Rt=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.transform,r=void 0===i?ee:i,s=t.symbol,o=void 0!==s&&s,a=t.mask,l=void 0===a?null:a,c=t.maskId,u=void 0===c?null:c,h=t.title,d=void 0===h?null:h,p=t.titleId,g=void 0===p?null:p,f=t.classes,m=void 0===f?[]:f,v=t.attributes,C=void 0===v?{}:v,y=t.styles,w=void 0===y?{}:y;if(e){var S=e.prefix,b=e.iconName,E=e.icon;return Ze(n({type:"icon"},e),function(){return je("beforeDOMElementCreation",{iconDefinition:e,params:t}),X.autoA11y&&(d?C["aria-labelledby"]="".concat(X.replacementClass,"-title-").concat(g||te()):(C["aria-hidden"]="true",C.focusable="false")),Je({icons:{main:it(E),mask:l?it(l.icon):{found:!1,width:null,height:null,icon:{}}},prefix:S,iconName:b,transform:n(n({},ee),r),symbol:o,title:d,maskId:u,titleId:g,extra:{attributes:C,styles:w,classes:m}})})}},_t={mixout:function(){return{icon:(e=Rt,function(t){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=(t||{}).icon?t:$e(t||{}),s=i.mask;return s&&(s=(s||{}).icon?s:$e(s||{})),e(r,n(n({},i),{},{mask:s}))})};var e},hooks:function(){return{mutationObserverCallbacks:function(e){return e.treeCallback=Tt,e.nodeCallback=Mt,e}}},provides:function(e){e.i2svg=function(e){var t=e.node,i=void 0===t?w:t,r=e.callback;return Tt(i,void 0===r?function(){}:r)},e.generateSvgReplacementMutation=function(e,t){var i=t.iconName,r=t.title,n=t.titleId,s=t.prefix,o=t.transform,a=t.symbol,c=t.mask,u=t.maskId,h=t.extra;return new Promise(function(t,d){Promise.all([nt(i,s),c.iconName?nt(c.iconName,c.prefix):Promise.resolve({found:!1,width:512,height:512,icon:{}})]).then(function(c){var d=l(c,2),p=d[0],g=d[1];t([e,Je({icons:{main:p,mask:g},prefix:s,iconName:i,transform:o,symbol:a,maskId:u,title:r,titleId:n,extra:h,watchable:!0})])}).catch(d)})},e.generateAbstractIcon=function(e){var t,i=e.children,r=e.attributes,n=e.main,s=e.transform,o=se(e.styles);return o.length>0&&(r.style=o),oe(s)&&(t=Ke("generateAbstractTransformGrouping",{main:n,transform:s,containerWidth:n.width,iconWidth:n.width})),i.push(t||n.icon),{children:i,attributes:r}}}},Pt={mixout:function(){return{layer:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.classes,r=void 0===i?[]:i;return Ze({type:"layer"},function(){je("beforeDOMElementCreation",{assembler:e,params:t});var i=[];return e(function(e){Array.isArray(e)?e.map(function(e){i=i.concat(e.abstract)}):i=i.concat(e.abstract)}),[{tag:"span",attributes:{class:["".concat(X.familyPrefix,"-layers")].concat(c(r)).join(" ")},children:i}]})}}}},xt={mixout:function(){return{counter:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.title,r=void 0===i?null:i,s=t.classes,o=void 0===s?[]:s,a=t.attributes,l=void 0===a?{}:a,u=t.styles,h=void 0===u?{}:u;return Ze({type:"counter",content:e},function(){return je("beforeDOMElementCreation",{content:e,params:t}),function(e){var t=e.content,i=e.title,r=e.extra,s=n(n(n({},r.attributes),i?{title:i}:{}),{},{class:r.classes.join(" ")}),o=se(r.styles);o.length>0&&(s.style=o);var a=[];return a.push({tag:"span",attributes:s,children:[t]}),i&&a.push({tag:"span",attributes:{class:"sr-only"},children:[i]}),a}({content:e.toString(),title:r,extra:{attributes:l,styles:h,classes:["".concat(X.familyPrefix,"-layers-counter")].concat(c(o))}})})}}}},Dt={mixout:function(){return{text:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.transform,r=void 0===i?ee:i,s=t.title,o=void 0===s?null:s,a=t.classes,l=void 0===a?[]:a,u=t.attributes,h=void 0===u?{}:u,d=t.styles,p=void 0===d?{}:d;return Ze({type:"text",content:e},function(){return je("beforeDOMElementCreation",{content:e,params:t}),et({content:e,transform:n(n({},ee),r),title:o,extra:{attributes:h,styles:p,classes:["".concat(X.familyPrefix,"-layers-text")].concat(c(l))}})})}}},provides:function(e){e.generateLayersText=function(e,t){var i=t.title,r=t.transform,n=t.extra,s=null,o=null;if(A){var a=parseInt(getComputedStyle(e).fontSize,10),l=e.getBoundingClientRect();s=l.width/a,o=l.height/a}return X.autoA11y&&!i&&(n.attributes["aria-hidden"]="true"),Promise.resolve([e,et({content:e.innerHTML,width:s,height:o,transform:r,title:i,extra:n,watchable:!0})])}}},It=new RegExp('"',"ug"),Lt=[1105920,1112319];function Nt(e,t){var i="".concat("data-fa-pseudo-element-pending").concat(t.replace(":","-"));return new Promise(function(r,s){if(null!==e.getAttribute(i))return r();var o,a,l,c=ie(e.children).filter(function(e){return e.getAttribute(_)===t})[0],u=y.getComputedStyle(e,t),h=u.getPropertyValue("font-family").match(H),d=u.getPropertyValue("font-weight"),p=u.getPropertyValue("content");if(c&&!h)return e.removeChild(c),r();if(h&&"none"!==p&&""!==p){var g=u.getPropertyValue("content"),f=~["Solid","Regular","Light","Thin","Duotone","Brands","Kit"].indexOf(h[2])?O[h[2].toLowerCase()]:B[d],m=function(e){var t,i,r,n,s=e.replace(It,""),o=(r=(t=s).length,(n=t.charCodeAt(0))>=55296&&n<=56319&&r>1&&(i=t.charCodeAt(1))>=56320&&i<=57343?1024*(n-55296)+i-56320+65536:n),a=o>=Lt[0]&&o<=Lt[1],l=2===s.length&&s[0]===s[1];return{value:Ce(l?s[0]:s),isSecondary:a||l}}(g),v=m.value,C=m.isSecondary,S=h[0].startsWith("FontAwesome"),b=Le(f,v),E=b;if(S){var A=(a=_e[o=v],l=Le("fas",o),a||(l?{prefix:"fas",iconName:l}:null)||{prefix:null,iconName:null});A.iconName&&A.prefix&&(b=A.iconName,f=A.prefix)}if(!b||C||c&&c.getAttribute(P)===f&&c.getAttribute(x)===E)r();else{e.setAttribute(i,E),c&&e.removeChild(c);var T={iconName:null,title:null,titleId:null,prefix:null,transform:ee,symbol:!1,mask:{iconName:null,prefix:null,rest:[]},maskId:null,extra:{classes:[],styles:{},attributes:{}}},M=T.extra;M.attributes[_]=t,nt(b,f).then(function(s){var o=Je(n(n({},T),{},{icons:{main:s,mask:{prefix:null,iconName:null,rest:[]}},prefix:f,iconName:E,extra:M,watchable:!0})),a=w.createElement("svg");"::before"===t?e.insertBefore(a,e.firstChild):e.appendChild(a),a.outerHTML=o.map(function(e){return fe(e)}).join("\n"),e.removeAttribute(i),r()}).catch(s)}}else r()})}function Ot(e){return Promise.all([Nt(e,"::before"),Nt(e,"::after")])}function Ft(e){return!(e.parentNode===document.head||~I.indexOf(e.tagName.toUpperCase())||e.getAttribute(_)||e.parentNode&&"svg"===e.parentNode.tagName)}function kt(e){if(E)return new Promise(function(t,i){var r=ie(e.querySelectorAll("*")).filter(Ft).map(Ot),n=lt("searchPseudoElements");Ct(),Promise.all(r).then(function(){n(),yt(),t()}).catch(function(){n(),yt(),i()})})}var Gt=!1,Vt=function(e){return e.toLowerCase().split(" ").reduce(function(e,t){var i=t.toLowerCase().split("-"),r=i[0],n=i.slice(1).join("-");if(r&&"h"===n)return e.flipX=!0,e;if(r&&"v"===n)return e.flipY=!0,e;if(n=parseFloat(n),isNaN(n))return e;switch(r){case"grow":e.size=e.size+n;break;case"shrink":e.size=e.size-n;break;case"left":e.x=e.x-n;break;case"right":e.x=e.x+n;break;case"up":e.y=e.y-n;break;case"down":e.y=e.y+n;break;case"rotate":e.rotate=e.rotate+n}return e},{size:16,x:0,y:0,flipX:!1,flipY:!1,rotate:0})},Ht={mixout:function(){return{parse:{transform:function(e){return Vt(e)}}}},hooks:function(){return{parseNodeAttributes:function(e,t){var i=t.getAttribute("data-fa-transform");return i&&(e.transform=Vt(i)),e}}},provides:function(e){e.generateAbstractTransformGrouping=function(e){var t=e.main,i=e.transform,r=e.containerWidth,s=e.iconWidth,o={transform:"translate(".concat(r/2," 256)")},a="translate(".concat(32*i.x,", ").concat(32*i.y,") "),l="scale(".concat(i.size/16*(i.flipX?-1:1),", ").concat(i.size/16*(i.flipY?-1:1),") "),c="rotate(".concat(i.rotate," 0 0)"),u={outer:o,inner:{transform:"".concat(a," ").concat(l," ").concat(c)},path:{transform:"translate(".concat(s/2*-1," -256)")}};return{tag:"g",attributes:n({},u.outer),children:[{tag:"g",attributes:n({},u.inner),children:[{tag:t.icon.tag,children:t.icon.children,attributes:n(n({},t.icon.attributes),u.path)}]}]}}}},Bt={x:0,y:0,width:"100%",height:"100%"};function zt(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return e.attributes&&(e.attributes.fill||t)&&(e.attributes.fill="black"),e}var Ut,Wt={hooks:function(){return{parseNodeAttributes:function(e,t){var i=t.getAttribute("data-fa-mask"),r=i?Ge(i.split(" ").map(function(e){return e.trim()})):{prefix:null,iconName:null,rest:[]};return r.prefix||(r.prefix=Fe()),e.mask=r,e.maskId=t.getAttribute("data-fa-mask-id"),e}}},provides:function(e){e.generateAbstractMask=function(e){var t,i=e.children,r=e.attributes,s=e.main,o=e.mask,a=e.maskId,l=e.transform,c=s.width,u=s.icon,h=o.width,d=o.icon,p=function(e){var t=e.transform,i=e.iconWidth,r={transform:"translate(".concat(e.containerWidth/2," 256)")},n="translate(".concat(32*t.x,", ").concat(32*t.y,") "),s="scale(".concat(t.size/16*(t.flipX?-1:1),", ").concat(t.size/16*(t.flipY?-1:1),") "),o="rotate(".concat(t.rotate," 0 0)");return{outer:r,inner:{transform:"".concat(n," ").concat(s," ").concat(o)},path:{transform:"translate(".concat(i/2*-1," -256)")}}}({transform:l,containerWidth:h,iconWidth:c}),g={tag:"rect",attributes:n(n({},Bt),{},{fill:"white"})},f=u.children?{children:u.children.map(zt)}:{},m={tag:"g",attributes:n({},p.inner),children:[zt(n({tag:u.tag,attributes:n(n({},u.attributes),p.path)},f))]},v={tag:"g",attributes:n({},p.outer),children:[m]},C="mask-".concat(a||te()),y="clip-".concat(a||te()),w={tag:"mask",attributes:n(n({},Bt),{},{id:C,maskUnits:"userSpaceOnUse",maskContentUnits:"userSpaceOnUse"}),children:[g,v]},S={tag:"defs",children:[{tag:"clipPath",attributes:{id:y},children:(t=d,"g"===t.tag?t.children:[t])},w]};return i.push(S,{tag:"rect",attributes:n({fill:"currentColor","clip-path":"url(#".concat(y,")"),mask:"url(#".concat(C,")")},Bt)}),{children:i,attributes:r}}}},jt={provides:function(e){var t=!1;y.matchMedia&&(t=y.matchMedia("(prefers-reduced-motion: reduce)").matches),e.missingIconAbstract=function(){var e=[],i={fill:"currentColor"},r={attributeType:"XML",repeatCount:"indefinite",dur:"2s"};e.push({tag:"path",attributes:n(n({},i),{},{d:"M156.5,447.7l-12.6,29.5c-18.7-9.5-35.9-21.2-51.5-34.9l22.7-22.7C127.6,430.5,141.5,440,156.5,447.7z M40.6,272H8.5 c1.4,21.2,5.4,41.7,11.7,61.1L50,321.2C45.1,305.5,41.8,289,40.6,272z M40.6,240c1.4-18.8,5.2-37,11.1-54.1l-29.5-12.6 C14.7,194.3,10,216.7,8.5,240H40.6z M64.3,156.5c7.8-14.9,17.2-28.8,28.1-41.5L69.7,92.3c-13.7,15.6-25.5,32.8-34.9,51.5 L64.3,156.5z M397,419.6c-13.9,12-29.4,22.3-46.1,30.4l11.9,29.8c20.7-9.9,39.8-22.6,56.9-37.6L397,419.6z M115,92.4 c13.9-12,29.4-22.3,46.1-30.4l-11.9-29.8c-20.7,9.9-39.8,22.6-56.8,37.6L115,92.4z M447.7,355.5c-7.8,14.9-17.2,28.8-28.1,41.5 l22.7,22.7c13.7-15.6,25.5-32.9,34.9-51.5L447.7,355.5z M471.4,272c-1.4,18.8-5.2,37-11.1,54.1l29.5,12.6 c7.5-21.1,12.2-43.5,13.6-66.8H471.4z M321.2,462c-15.7,5-32.2,8.2-49.2,9.4v32.1c21.2-1.4,41.7-5.4,61.1-11.7L321.2,462z M240,471.4c-18.8-1.4-37-5.2-54.1-11.1l-12.6,29.5c21.1,7.5,43.5,12.2,66.8,13.6V471.4z M462,190.8c5,15.7,8.2,32.2,9.4,49.2h32.1 c-1.4-21.2-5.4-41.7-11.7-61.1L462,190.8z M92.4,397c-12-13.9-22.3-29.4-30.4-46.1l-29.8,11.9c9.9,20.7,22.6,39.8,37.6,56.9 L92.4,397z M272,40.6c18.8,1.4,36.9,5.2,54.1,11.1l12.6-29.5C317.7,14.7,295.3,10,272,8.5V40.6z M190.8,50 c15.7-5,32.2-8.2,49.2-9.4V8.5c-21.2,1.4-41.7,5.4-61.1,11.7L190.8,50z M442.3,92.3L419.6,115c12,13.9,22.3,29.4,30.5,46.1 l29.8-11.9C470,128.5,457.3,109.4,442.3,92.3z M397,92.4l22.7-22.7c-15.6-13.7-32.8-25.5-51.5-34.9l-12.6,29.5 C370.4,72.1,384.4,81.5,397,92.4z"})});var s=n(n({},r),{},{attributeName:"opacity"}),o={tag:"circle",attributes:n(n({},i),{},{cx:"256",cy:"364",r:"28"}),children:[]};return t||o.children.push({tag:"animate",attributes:n(n({},r),{},{attributeName:"r",values:"28;14;28;28;14;28;"})},{tag:"animate",attributes:n(n({},s),{},{values:"1;0;1;1;0;1;"})}),e.push(o),e.push({tag:"path",attributes:n(n({},i),{},{opacity:"1",d:"M263.7,312h-16c-6.6,0-12-5.4-12-12c0-71,77.4-63.9,77.4-107.8c0-20-17.8-40.2-57.4-40.2c-29.1,0-44.3,9.6-59.2,28.7 c-3.9,5-11.1,6-16.2,2.4l-13.1-9.2c-5.6-3.9-6.9-11.8-2.6-17.2c21.2-27.2,46.4-44.7,91.2-44.7c52.3,0,97.4,29.8,97.4,80.2 c0,67.6-77.4,63.5-77.4,107.8C275.7,306.6,270.3,312,263.7,312z"}),children:t?[]:[{tag:"animate",attributes:n(n({},s),{},{values:"1;0;0;0;0;1;"})}]}),t||e.push({tag:"path",attributes:n(n({},i),{},{opacity:"0",d:"M232.5,134.5l7,168c0.3,6.4,5.6,11.5,12,11.5h9c6.4,0,11.7-5.1,12-11.5l7-168c0.3-6.8-5.2-12.5-12-12.5h-23 C237.7,122,232.2,127.7,232.5,134.5z"}),children:[{tag:"animate",attributes:n(n({},s),{},{values:"0;0;1;1;0;0;"})}]}),{tag:"g",attributes:{class:"missing"},children:e}}}};Ut={mixoutsTo:Qe}.mixoutsTo,He=[ue,_t,Pt,xt,Dt,{hooks:function(){return{mutationObserverCallbacks:function(e){return e.pseudoElementsCallback=kt,e}}},provides:function(e){e.pseudoElements2svg=function(e){var t=e.node,i=void 0===t?w:t;X.searchPseudoElements&&kt(i)}}},{mixout:function(){return{dom:{unwatch:function(){Ct(),Gt=!0}}}},hooks:function(){return{bootstrap:function(){St(We("mutationObserverCallbacks",{}))},noAuto:function(){wt&&wt.disconnect()},watch:function(e){var t=e.observeMutationsRoot;Gt?yt():St(We("mutationObserverCallbacks",{observeMutationsRoot:t}))}}}},Ht,Wt,jt,{hooks:function(){return{parseNodeAttributes:function(e,t){var i=t.getAttribute("data-fa-symbol"),r=null!==i&&(""===i||i);return e.symbol=r,e}}}}],Be={},Object.keys(ze).forEach(function(e){-1===Ue.indexOf(e)&&delete ze[e]}),He.forEach(function(e){var t=e.mixout?e.mixout():{};if(Object.keys(t).forEach(function(e){"function"==typeof t[e]&&(Ut[e]=t[e]),"object"===s(t[e])&&Object.keys(t[e]).forEach(function(i){Ut[e]||(Ut[e]={}),Ut[e][i]=t[e][i]})}),e.hooks){var i=e.hooks();Object.keys(i).forEach(function(e){Be[e]||(Be[e]=[]),Be[e].push(i[e])})}e.provides&&e.provides(ze)});var Kt=Qe.noAuto,$t=Qe.config,qt=Qe.library,Yt=Qe.dom,Qt=Qe.parse,Xt=Qe.findIconDefinition,Zt=Qe.toHtml,Jt=Qe.icon,ei=Qe.layer,ti=Qe.text,ii=Qe.counter},55897(e,t,i){"use strict";i.r(t),i.d(t,{faAd:()=>n,faAddressBook:()=>s,faAddressCard:()=>o,faAdjust:()=>a,faAirFreshener:()=>l,faAlignCenter:()=>c,faAlignJustify:()=>u,faAlignLeft:()=>h,faAlignRight:()=>d,faAllergies:()=>p,faAmbulance:()=>g,faAmericanSignLanguageInterpreting:()=>f,faAnchor:()=>m,faAngleDoubleDown:()=>v,faAngleDoubleLeft:()=>C,faAngleDoubleRight:()=>y,faAngleDoubleUp:()=>w,faAngleDown:()=>S,faAngleLeft:()=>b,faAngleRight:()=>E,faAngleUp:()=>A,faAngry:()=>T,faAnkh:()=>M,faAppleAlt:()=>R,faArchive:()=>_,faArchway:()=>P,faArrowAltCircleDown:()=>x,faArrowAltCircleLeft:()=>D,faArrowAltCircleRight:()=>I,faArrowAltCircleUp:()=>L,faArrowCircleDown:()=>N,faArrowCircleLeft:()=>O,faArrowCircleRight:()=>F,faArrowCircleUp:()=>k,faArrowDown:()=>G,faArrowLeft:()=>V,faArrowRight:()=>H,faArrowUp:()=>B,faArrowsAlt:()=>z,faArrowsAltH:()=>U,faArrowsAltV:()=>W,faAssistiveListeningSystems:()=>j,faAsterisk:()=>K,faAt:()=>$,faAtlas:()=>q,faAtom:()=>Y,faAudioDescription:()=>Q,faAward:()=>X,faBaby:()=>Z,faBabyCarriage:()=>J,faBackspace:()=>ee,faBackward:()=>te,faBacon:()=>ie,faBacteria:()=>re,faBacterium:()=>ne,faBahai:()=>se,faBalanceScale:()=>oe,faBalanceScaleLeft:()=>ae,faBalanceScaleRight:()=>le,faBan:()=>ce,faBandAid:()=>ue,faBarcode:()=>he,faBars:()=>de,faBaseballBall:()=>pe,faBasketballBall:()=>ge,faBath:()=>fe,faBatteryEmpty:()=>me,faBatteryFull:()=>ve,faBatteryHalf:()=>Ce,faBatteryQuarter:()=>ye,faBatteryThreeQuarters:()=>we,faBed:()=>Se,faBeer:()=>be,faBell:()=>Ee,faBellSlash:()=>Ae,faBezierCurve:()=>Te,faBible:()=>Me,faBicycle:()=>Re,faBiking:()=>_e,faBinoculars:()=>Pe,faBiohazard:()=>xe,faBirthdayCake:()=>De,faBlender:()=>Ie,faBlenderPhone:()=>Le,faBlind:()=>Ne,faBlog:()=>Oe,faBold:()=>Fe,faBolt:()=>ke,faBomb:()=>Ge,faBone:()=>Ve,faBong:()=>He,faBook:()=>Be,faBookDead:()=>ze,faBookMedical:()=>Ue,faBookOpen:()=>We,faBookReader:()=>je,faBookmark:()=>Ke,faBorderAll:()=>$e,faBorderNone:()=>qe,faBorderStyle:()=>Ye,faBowlingBall:()=>Qe,faBox:()=>Xe,faBoxOpen:()=>Ze,faBoxTissue:()=>Je,faBoxes:()=>et,faBraille:()=>tt,faBrain:()=>it,faBreadSlice:()=>rt,faBriefcase:()=>nt,faBriefcaseMedical:()=>st,faBroadcastTower:()=>ot,faBroom:()=>at,faBrush:()=>lt,faBug:()=>ct,faBuilding:()=>ut,faBullhorn:()=>ht,faBullseye:()=>dt,faBurn:()=>pt,faBus:()=>gt,faBusAlt:()=>ft,faBusinessTime:()=>mt,faCalculator:()=>vt,faCalendar:()=>Ct,faCalendarAlt:()=>yt,faCalendarCheck:()=>wt,faCalendarDay:()=>St,faCalendarMinus:()=>bt,faCalendarPlus:()=>Et,faCalendarTimes:()=>At,faCalendarWeek:()=>Tt,faCamera:()=>Mt,faCameraRetro:()=>Rt,faCampground:()=>_t,faCandyCane:()=>Pt,faCannabis:()=>xt,faCapsules:()=>Dt,faCar:()=>It,faCarAlt:()=>Lt,faCarBattery:()=>Nt,faCarCrash:()=>Ot,faCarSide:()=>Ft,faCaravan:()=>kt,faCaretDown:()=>Gt,faCaretLeft:()=>Vt,faCaretRight:()=>Ht,faCaretSquareDown:()=>Bt,faCaretSquareLeft:()=>zt,faCaretSquareRight:()=>Ut,faCaretSquareUp:()=>Wt,faCaretUp:()=>jt,faCarrot:()=>Kt,faCartArrowDown:()=>$t,faCartPlus:()=>qt,faCashRegister:()=>Yt,faCat:()=>Qt,faCertificate:()=>Xt,faChair:()=>Zt,faChalkboard:()=>Jt,faChalkboardTeacher:()=>ei,faChargingStation:()=>ti,faChartArea:()=>ii,faChartBar:()=>ri,faChartLine:()=>ni,faChartPie:()=>si,faCheck:()=>oi,faCheckCircle:()=>ai,faCheckDouble:()=>li,faCheckSquare:()=>ci,faCheese:()=>ui,faChess:()=>hi,faChessBishop:()=>di,faChessBoard:()=>pi,faChessKing:()=>gi,faChessKnight:()=>fi,faChessPawn:()=>mi,faChessQueen:()=>vi,faChessRook:()=>Ci,faChevronCircleDown:()=>yi,faChevronCircleLeft:()=>wi,faChevronCircleRight:()=>Si,faChevronCircleUp:()=>bi,faChevronDown:()=>Ei,faChevronLeft:()=>Ai,faChevronRight:()=>Ti,faChevronUp:()=>Mi,faChild:()=>Ri,faChurch:()=>_i,faCircle:()=>Pi,faCircleNotch:()=>xi,faCity:()=>Di,faClinicMedical:()=>Ii,faClipboard:()=>Li,faClipboardCheck:()=>Ni,faClipboardList:()=>Oi,faClock:()=>Fi,faClone:()=>ki,faClosedCaptioning:()=>Gi,faCloud:()=>Vi,faCloudDownloadAlt:()=>Hi,faCloudMeatball:()=>Bi,faCloudMoon:()=>zi,faCloudMoonRain:()=>Ui,faCloudRain:()=>Wi,faCloudShowersHeavy:()=>ji,faCloudSun:()=>Ki,faCloudSunRain:()=>$i,faCloudUploadAlt:()=>qi,faCocktail:()=>Yi,faCode:()=>Qi,faCodeBranch:()=>Xi,faCoffee:()=>Zi,faCog:()=>Ji,faCogs:()=>er,faCoins:()=>tr,faColumns:()=>ir,faComment:()=>rr,faCommentAlt:()=>nr,faCommentDollar:()=>sr,faCommentDots:()=>or,faCommentMedical:()=>ar,faCommentSlash:()=>lr,faComments:()=>cr,faCommentsDollar:()=>ur,faCompactDisc:()=>hr,faCompass:()=>dr,faCompress:()=>pr,faCompressAlt:()=>gr,faCompressArrowsAlt:()=>fr,faConciergeBell:()=>mr,faCookie:()=>vr,faCookieBite:()=>Cr,faCopy:()=>yr,faCopyright:()=>wr,faCouch:()=>Sr,faCreditCard:()=>br,faCrop:()=>Er,faCropAlt:()=>Ar,faCross:()=>Tr,faCrosshairs:()=>Mr,faCrow:()=>Rr,faCrown:()=>_r,faCrutch:()=>Pr,faCube:()=>xr,faCubes:()=>Dr,faCut:()=>Ir,faDatabase:()=>Lr,faDeaf:()=>Nr,faDemocrat:()=>Or,faDesktop:()=>Fr,faDharmachakra:()=>kr,faDiagnoses:()=>Gr,faDice:()=>Vr,faDiceD20:()=>Hr,faDiceD6:()=>Br,faDiceFive:()=>zr,faDiceFour:()=>Ur,faDiceOne:()=>Wr,faDiceSix:()=>jr,faDiceThree:()=>Kr,faDiceTwo:()=>$r,faDigitalTachograph:()=>qr,faDirections:()=>Yr,faDisease:()=>Qr,faDivide:()=>Xr,faDizzy:()=>Zr,faDna:()=>Jr,faDog:()=>en,faDollarSign:()=>tn,faDolly:()=>rn,faDollyFlatbed:()=>nn,faDonate:()=>sn,faDoorClosed:()=>on,faDoorOpen:()=>an,faDotCircle:()=>ln,faDove:()=>cn,faDownload:()=>un,faDraftingCompass:()=>hn,faDragon:()=>dn,faDrawPolygon:()=>pn,faDrum:()=>gn,faDrumSteelpan:()=>fn,faDrumstickBite:()=>mn,faDumbbell:()=>vn,faDumpster:()=>Cn,faDumpsterFire:()=>yn,faDungeon:()=>wn,faEdit:()=>Sn,faEgg:()=>bn,faEject:()=>En,faEllipsisH:()=>An,faEllipsisV:()=>Tn,faEnvelope:()=>Mn,faEnvelopeOpen:()=>Rn,faEnvelopeOpenText:()=>_n,faEnvelopeSquare:()=>Pn,faEquals:()=>xn,faEraser:()=>Dn,faEthernet:()=>In,faEuroSign:()=>Ln,faExchangeAlt:()=>Nn,faExclamation:()=>On,faExclamationCircle:()=>Fn,faExclamationTriangle:()=>kn,faExpand:()=>Gn,faExpandAlt:()=>Vn,faExpandArrowsAlt:()=>Hn,faExternalLinkAlt:()=>Bn,faExternalLinkSquareAlt:()=>zn,faEye:()=>Un,faEyeDropper:()=>Wn,faEyeSlash:()=>jn,faFan:()=>Kn,faFastBackward:()=>$n,faFastForward:()=>qn,faFaucet:()=>Yn,faFax:()=>Qn,faFeather:()=>Xn,faFeatherAlt:()=>Zn,faFemale:()=>Jn,faFighterJet:()=>es,faFile:()=>ts,faFileAlt:()=>is,faFileArchive:()=>rs,faFileAudio:()=>ns,faFileCode:()=>ss,faFileContract:()=>os,faFileCsv:()=>as,faFileDownload:()=>ls,faFileExcel:()=>cs,faFileExport:()=>us,faFileImage:()=>hs,faFileImport:()=>ds,faFileInvoice:()=>ps,faFileInvoiceDollar:()=>gs,faFileMedical:()=>fs,faFileMedicalAlt:()=>ms,faFilePdf:()=>vs,faFilePowerpoint:()=>Cs,faFilePrescription:()=>ys,faFileSignature:()=>ws,faFileUpload:()=>Ss,faFileVideo:()=>bs,faFileWord:()=>Es,faFill:()=>As,faFillDrip:()=>Ts,faFilm:()=>Ms,faFilter:()=>Rs,faFingerprint:()=>_s,faFire:()=>Ps,faFireAlt:()=>xs,faFireExtinguisher:()=>Ds,faFirstAid:()=>Is,faFish:()=>Ls,faFistRaised:()=>Ns,faFlag:()=>Os,faFlagCheckered:()=>Fs,faFlagUsa:()=>ks,faFlask:()=>Gs,faFlushed:()=>Vs,faFolder:()=>Hs,faFolderMinus:()=>Bs,faFolderOpen:()=>zs,faFolderPlus:()=>Us,faFont:()=>Ws,faFontAwesomeLogoFull:()=>js,faFootballBall:()=>Ks,faForward:()=>$s,faFrog:()=>qs,faFrown:()=>Ys,faFrownOpen:()=>Qs,faFunnelDollar:()=>Xs,faFutbol:()=>Zs,faGamepad:()=>Js,faGasPump:()=>eo,faGavel:()=>to,faGem:()=>io,faGenderless:()=>ro,faGhost:()=>no,faGift:()=>so,faGifts:()=>oo,faGlassCheers:()=>ao,faGlassMartini:()=>lo,faGlassMartiniAlt:()=>co,faGlassWhiskey:()=>uo,faGlasses:()=>ho,faGlobe:()=>po,faGlobeAfrica:()=>go,faGlobeAmericas:()=>fo,faGlobeAsia:()=>mo,faGlobeEurope:()=>vo,faGolfBall:()=>Co,faGopuram:()=>yo,faGraduationCap:()=>wo,faGreaterThan:()=>So,faGreaterThanEqual:()=>bo,faGrimace:()=>Eo,faGrin:()=>Ao,faGrinAlt:()=>To,faGrinBeam:()=>Mo,faGrinBeamSweat:()=>Ro,faGrinHearts:()=>_o,faGrinSquint:()=>Po,faGrinSquintTears:()=>xo,faGrinStars:()=>Do,faGrinTears:()=>Io,faGrinTongue:()=>Lo,faGrinTongueSquint:()=>No,faGrinTongueWink:()=>Oo,faGrinWink:()=>Fo,faGripHorizontal:()=>ko,faGripLines:()=>Go,faGripLinesVertical:()=>Vo,faGripVertical:()=>Ho,faGuitar:()=>Bo,faHSquare:()=>zo,faHamburger:()=>Uo,faHammer:()=>Wo,faHamsa:()=>jo,faHandHolding:()=>Ko,faHandHoldingHeart:()=>$o,faHandHoldingMedical:()=>qo,faHandHoldingUsd:()=>Yo,faHandHoldingWater:()=>Qo,faHandLizard:()=>Xo,faHandMiddleFinger:()=>Zo,faHandPaper:()=>Jo,faHandPeace:()=>ea,faHandPointDown:()=>ta,faHandPointLeft:()=>ia,faHandPointRight:()=>ra,faHandPointUp:()=>na,faHandPointer:()=>sa,faHandRock:()=>oa,faHandScissors:()=>aa,faHandSparkles:()=>la,faHandSpock:()=>ca,faHands:()=>ua,faHandsHelping:()=>ha,faHandsWash:()=>da,faHandshake:()=>pa,faHandshakeAltSlash:()=>ga,faHandshakeSlash:()=>fa,faHanukiah:()=>ma,faHardHat:()=>va,faHashtag:()=>Ca,faHatCowboy:()=>ya,faHatCowboySide:()=>wa,faHatWizard:()=>Sa,faHdd:()=>ba,faHeadSideCough:()=>Ea,faHeadSideCoughSlash:()=>Aa,faHeadSideMask:()=>Ta,faHeadSideVirus:()=>Ma,faHeading:()=>Ra,faHeadphones:()=>_a,faHeadphonesAlt:()=>Pa,faHeadset:()=>xa,faHeart:()=>Da,faHeartBroken:()=>Ia,faHeartbeat:()=>La,faHelicopter:()=>Na,faHighlighter:()=>Oa,faHiking:()=>Fa,faHippo:()=>ka,faHistory:()=>Ga,faHockeyPuck:()=>Va,faHollyBerry:()=>Ha,faHome:()=>Ba,faHorse:()=>za,faHorseHead:()=>Ua,faHospital:()=>Wa,faHospitalAlt:()=>ja,faHospitalSymbol:()=>Ka,faHospitalUser:()=>$a,faHotTub:()=>qa,faHotdog:()=>Ya,faHotel:()=>Qa,faHourglass:()=>Xa,faHourglassEnd:()=>Za,faHourglassHalf:()=>Ja,faHourglassStart:()=>el,faHouseDamage:()=>tl,faHouseUser:()=>il,faHryvnia:()=>rl,faICursor:()=>nl,faIceCream:()=>sl,faIcicles:()=>ol,faIcons:()=>al,faIdBadge:()=>ll,faIdCard:()=>cl,faIdCardAlt:()=>ul,faIgloo:()=>hl,faImage:()=>dl,faImages:()=>pl,faInbox:()=>gl,faIndent:()=>fl,faIndustry:()=>ml,faInfinity:()=>vl,faInfo:()=>Cl,faInfoCircle:()=>yl,faItalic:()=>wl,faJedi:()=>Sl,faJoint:()=>bl,faJournalWhills:()=>El,faKaaba:()=>Al,faKey:()=>Tl,faKeyboard:()=>Ml,faKhanda:()=>Rl,faKiss:()=>_l,faKissBeam:()=>Pl,faKissWinkHeart:()=>xl,faKiwiBird:()=>Dl,faLandmark:()=>Il,faLanguage:()=>Ll,faLaptop:()=>Nl,faLaptopCode:()=>Ol,faLaptopHouse:()=>Fl,faLaptopMedical:()=>kl,faLaugh:()=>Gl,faLaughBeam:()=>Vl,faLaughSquint:()=>Hl,faLaughWink:()=>Bl,faLayerGroup:()=>zl,faLeaf:()=>Ul,faLemon:()=>Wl,faLessThan:()=>jl,faLessThanEqual:()=>Kl,faLevelDownAlt:()=>$l,faLevelUpAlt:()=>ql,faLifeRing:()=>Yl,faLightbulb:()=>Ql,faLink:()=>Xl,faLiraSign:()=>Zl,faList:()=>Jl,faListAlt:()=>ec,faListOl:()=>tc,faListUl:()=>ic,faLocationArrow:()=>rc,faLock:()=>nc,faLockOpen:()=>sc,faLongArrowAltDown:()=>oc,faLongArrowAltLeft:()=>ac,faLongArrowAltRight:()=>lc,faLongArrowAltUp:()=>cc,faLowVision:()=>uc,faLuggageCart:()=>hc,faLungs:()=>dc,faLungsVirus:()=>pc,faMagic:()=>gc,faMagnet:()=>fc,faMailBulk:()=>mc,faMale:()=>vc,faMap:()=>Cc,faMapMarked:()=>yc,faMapMarkedAlt:()=>wc,faMapMarker:()=>Sc,faMapMarkerAlt:()=>bc,faMapPin:()=>Ec,faMapSigns:()=>Ac,faMarker:()=>Tc,faMars:()=>Mc,faMarsDouble:()=>Rc,faMarsStroke:()=>_c,faMarsStrokeH:()=>Pc,faMarsStrokeV:()=>xc,faMask:()=>Dc,faMedal:()=>Ic,faMedkit:()=>Lc,faMeh:()=>Nc,faMehBlank:()=>Oc,faMehRollingEyes:()=>Fc,faMemory:()=>kc,faMenorah:()=>Gc,faMercury:()=>Vc,faMeteor:()=>Hc,faMicrochip:()=>Bc,faMicrophone:()=>zc,faMicrophoneAlt:()=>Uc,faMicrophoneAltSlash:()=>Wc,faMicrophoneSlash:()=>jc,faMicroscope:()=>Kc,faMinus:()=>$c,faMinusCircle:()=>qc,faMinusSquare:()=>Yc,faMitten:()=>Qc,faMobile:()=>Xc,faMobileAlt:()=>Zc,faMoneyBill:()=>Jc,faMoneyBillAlt:()=>eu,faMoneyBillWave:()=>tu,faMoneyBillWaveAlt:()=>iu,faMoneyCheck:()=>ru,faMoneyCheckAlt:()=>nu,faMonument:()=>su,faMoon:()=>ou,faMortarPestle:()=>au,faMosque:()=>lu,faMotorcycle:()=>cu,faMountain:()=>uu,faMouse:()=>hu,faMousePointer:()=>du,faMugHot:()=>pu,faMusic:()=>gu,faNetworkWired:()=>fu,faNeuter:()=>mu,faNewspaper:()=>vu,faNotEqual:()=>Cu,faNotesMedical:()=>yu,faObjectGroup:()=>wu,faObjectUngroup:()=>Su,faOilCan:()=>bu,faOm:()=>Eu,faOtter:()=>Au,faOutdent:()=>Tu,faPager:()=>Mu,faPaintBrush:()=>Ru,faPaintRoller:()=>_u,faPalette:()=>Pu,faPallet:()=>xu,faPaperPlane:()=>Du,faPaperclip:()=>Iu,faParachuteBox:()=>Lu,faParagraph:()=>Nu,faParking:()=>Ou,faPassport:()=>Fu,faPastafarianism:()=>ku,faPaste:()=>Gu,faPause:()=>Vu,faPauseCircle:()=>Hu,faPaw:()=>Bu,faPeace:()=>zu,faPen:()=>Uu,faPenAlt:()=>Wu,faPenFancy:()=>ju,faPenNib:()=>Ku,faPenSquare:()=>$u,faPencilAlt:()=>qu,faPencilRuler:()=>Yu,faPeopleArrows:()=>Qu,faPeopleCarry:()=>Xu,faPepperHot:()=>Zu,faPercent:()=>Ju,faPercentage:()=>eh,faPersonBooth:()=>th,faPhone:()=>ih,faPhoneAlt:()=>rh,faPhoneSlash:()=>nh,faPhoneSquare:()=>sh,faPhoneSquareAlt:()=>oh,faPhoneVolume:()=>ah,faPhotoVideo:()=>lh,faPiggyBank:()=>ch,faPills:()=>uh,faPizzaSlice:()=>hh,faPlaceOfWorship:()=>dh,faPlane:()=>ph,faPlaneArrival:()=>gh,faPlaneDeparture:()=>fh,faPlaneSlash:()=>mh,faPlay:()=>vh,faPlayCircle:()=>Ch,faPlug:()=>yh,faPlus:()=>wh,faPlusCircle:()=>Sh,faPlusSquare:()=>bh,faPodcast:()=>Eh,faPoll:()=>Ah,faPollH:()=>Th,faPoo:()=>Mh,faPooStorm:()=>Rh,faPoop:()=>_h,faPortrait:()=>Ph,faPoundSign:()=>xh,faPowerOff:()=>Dh,faPray:()=>Ih,faPrayingHands:()=>Lh,faPrescription:()=>Nh,faPrescriptionBottle:()=>Oh,faPrescriptionBottleAlt:()=>Fh,faPrint:()=>kh,faProcedures:()=>Gh,faProjectDiagram:()=>Vh,faPumpMedical:()=>Hh,faPumpSoap:()=>Bh,faPuzzlePiece:()=>zh,faQrcode:()=>Uh,faQuestion:()=>Wh,faQuestionCircle:()=>jh,faQuidditch:()=>Kh,faQuoteLeft:()=>$h,faQuoteRight:()=>qh,faQuran:()=>Yh,faRadiation:()=>Qh,faRadiationAlt:()=>Xh,faRainbow:()=>Zh,faRandom:()=>Jh,faReceipt:()=>ed,faRecordVinyl:()=>td,faRecycle:()=>id,faRedo:()=>rd,faRedoAlt:()=>nd,faRegistered:()=>sd,faRemoveFormat:()=>od,faReply:()=>ad,faReplyAll:()=>ld,faRepublican:()=>cd,faRestroom:()=>ud,faRetweet:()=>hd,faRibbon:()=>dd,faRing:()=>pd,faRoad:()=>gd,faRobot:()=>fd,faRocket:()=>md,faRoute:()=>vd,faRss:()=>Cd,faRssSquare:()=>yd,faRubleSign:()=>wd,faRuler:()=>Sd,faRulerCombined:()=>bd,faRulerHorizontal:()=>Ed,faRulerVertical:()=>Ad,faRunning:()=>Td,faRupeeSign:()=>Md,faSadCry:()=>Rd,faSadTear:()=>_d,faSatellite:()=>Pd,faSatelliteDish:()=>xd,faSave:()=>Dd,faSchool:()=>Id,faScrewdriver:()=>Ld,faScroll:()=>Nd,faSdCard:()=>Od,faSearch:()=>Fd,faSearchDollar:()=>kd,faSearchLocation:()=>Gd,faSearchMinus:()=>Vd,faSearchPlus:()=>Hd,faSeedling:()=>Bd,faServer:()=>zd,faShapes:()=>Ud,faShare:()=>Wd,faShareAlt:()=>jd,faShareAltSquare:()=>Kd,faShareSquare:()=>$d,faShekelSign:()=>qd,faShieldAlt:()=>Yd,faShieldVirus:()=>Qd,faShip:()=>Xd,faShippingFast:()=>Zd,faShoePrints:()=>Jd,faShoppingBag:()=>ep,faShoppingBasket:()=>tp,faShoppingCart:()=>ip,faShower:()=>rp,faShuttleVan:()=>np,faSign:()=>sp,faSignInAlt:()=>op,faSignLanguage:()=>ap,faSignOutAlt:()=>lp,faSignal:()=>cp,faSignature:()=>up,faSimCard:()=>hp,faSink:()=>dp,faSitemap:()=>pp,faSkating:()=>gp,faSkiing:()=>fp,faSkiingNordic:()=>mp,faSkull:()=>vp,faSkullCrossbones:()=>Cp,faSlash:()=>yp,faSleigh:()=>wp,faSlidersH:()=>Sp,faSmile:()=>bp,faSmileBeam:()=>Ep,faSmileWink:()=>Ap,faSmog:()=>Tp,faSmoking:()=>Mp,faSmokingBan:()=>Rp,faSms:()=>_p,faSnowboarding:()=>Pp,faSnowflake:()=>xp,faSnowman:()=>Dp,faSnowplow:()=>Ip,faSoap:()=>Lp,faSocks:()=>Np,faSolarPanel:()=>Op,faSort:()=>Fp,faSortAlphaDown:()=>kp,faSortAlphaDownAlt:()=>Gp,faSortAlphaUp:()=>Vp,faSortAlphaUpAlt:()=>Hp,faSortAmountDown:()=>Bp,faSortAmountDownAlt:()=>zp,faSortAmountUp:()=>Up,faSortAmountUpAlt:()=>Wp,faSortDown:()=>jp,faSortNumericDown:()=>Kp,faSortNumericDownAlt:()=>$p,faSortNumericUp:()=>qp,faSortNumericUpAlt:()=>Yp,faSortUp:()=>Qp,faSpa:()=>Xp,faSpaceShuttle:()=>Zp,faSpellCheck:()=>Jp,faSpider:()=>eg,faSpinner:()=>tg,faSplotch:()=>ig,faSprayCan:()=>rg,faSquare:()=>ng,faSquareFull:()=>sg,faSquareRootAlt:()=>og,faStamp:()=>ag,faStar:()=>lg,faStarAndCrescent:()=>cg,faStarHalf:()=>ug,faStarHalfAlt:()=>hg,faStarOfDavid:()=>dg,faStarOfLife:()=>pg,faStepBackward:()=>gg,faStepForward:()=>fg,faStethoscope:()=>mg,faStickyNote:()=>vg,faStop:()=>Cg,faStopCircle:()=>yg,faStopwatch:()=>wg,faStopwatch20:()=>Sg,faStore:()=>bg,faStoreAlt:()=>Eg,faStoreAltSlash:()=>Ag,faStoreSlash:()=>Tg,faStream:()=>Mg,faStreetView:()=>Rg,faStrikethrough:()=>_g,faStroopwafel:()=>Pg,faSubscript:()=>xg,faSubway:()=>Dg,faSuitcase:()=>Ig,faSuitcaseRolling:()=>Lg,faSun:()=>Ng,faSuperscript:()=>Og,faSurprise:()=>Fg,faSwatchbook:()=>kg,faSwimmer:()=>Gg,faSwimmingPool:()=>Vg,faSynagogue:()=>Hg,faSync:()=>Bg,faSyncAlt:()=>zg,faSyringe:()=>Ug,faTable:()=>Wg,faTableTennis:()=>jg,faTablet:()=>Kg,faTabletAlt:()=>$g,faTablets:()=>qg,faTachometerAlt:()=>Yg,faTag:()=>Qg,faTags:()=>Xg,faTape:()=>Zg,faTasks:()=>Jg,faTaxi:()=>ef,faTeeth:()=>tf,faTeethOpen:()=>rf,faTemperatureHigh:()=>nf,faTemperatureLow:()=>sf,faTenge:()=>of,faTerminal:()=>af,faTextHeight:()=>lf,faTextWidth:()=>cf,faTh:()=>uf,faThLarge:()=>hf,faThList:()=>df,faTheaterMasks:()=>pf,faThermometer:()=>gf,faThermometerEmpty:()=>ff,faThermometerFull:()=>mf,faThermometerHalf:()=>vf,faThermometerQuarter:()=>Cf,faThermometerThreeQuarters:()=>yf,faThumbsDown:()=>wf,faThumbsUp:()=>Sf,faThumbtack:()=>bf,faTicketAlt:()=>Ef,faTimes:()=>Af,faTimesCircle:()=>Tf,faTint:()=>Mf,faTintSlash:()=>Rf,faTired:()=>_f,faToggleOff:()=>Pf,faToggleOn:()=>xf,faToilet:()=>Df,faToiletPaper:()=>If,faToiletPaperSlash:()=>Lf,faToolbox:()=>Nf,faTools:()=>Of,faTooth:()=>Ff,faTorah:()=>kf,faToriiGate:()=>Gf,faTractor:()=>Vf,faTrademark:()=>Hf,faTrafficLight:()=>Bf,faTrailer:()=>zf,faTrain:()=>Uf,faTram:()=>Wf,faTransgender:()=>jf,faTransgenderAlt:()=>Kf,faTrash:()=>$f,faTrashAlt:()=>qf,faTrashRestore:()=>Yf,faTrashRestoreAlt:()=>Qf,faTree:()=>Xf,faTrophy:()=>Zf,faTruck:()=>Jf,faTruckLoading:()=>em,faTruckMonster:()=>tm,faTruckMoving:()=>im,faTruckPickup:()=>rm,faTshirt:()=>nm,faTty:()=>sm,faTv:()=>om,faUmbrella:()=>am,faUmbrellaBeach:()=>lm,faUnderline:()=>cm,faUndo:()=>um,faUndoAlt:()=>hm,faUniversalAccess:()=>dm,faUniversity:()=>pm,faUnlink:()=>gm,faUnlock:()=>fm,faUnlockAlt:()=>mm,faUpload:()=>vm,faUser:()=>Cm,faUserAlt:()=>ym,faUserAltSlash:()=>wm,faUserAstronaut:()=>Sm,faUserCheck:()=>bm,faUserCircle:()=>Em,faUserClock:()=>Am,faUserCog:()=>Tm,faUserEdit:()=>Mm,faUserFriends:()=>Rm,faUserGraduate:()=>_m,faUserInjured:()=>Pm,faUserLock:()=>xm,faUserMd:()=>Dm,faUserMinus:()=>Im,faUserNinja:()=>Lm,faUserNurse:()=>Nm,faUserPlus:()=>Om,faUserSecret:()=>Fm,faUserShield:()=>km,faUserSlash:()=>Gm,faUserTag:()=>Vm,faUserTie:()=>Hm,faUserTimes:()=>Bm,faUsers:()=>zm,faUsersCog:()=>Um,faUsersSlash:()=>Wm,faUtensilSpoon:()=>jm,faUtensils:()=>Km,faVectorSquare:()=>$m,faVenus:()=>qm,faVenusDouble:()=>Ym,faVenusMars:()=>Qm,faVest:()=>Xm,faVestPatches:()=>Zm,faVial:()=>Jm,faVials:()=>ev,faVideo:()=>tv,faVideoSlash:()=>iv,faVihara:()=>rv,faVirus:()=>nv,faVirusSlash:()=>sv,faViruses:()=>ov,faVoicemail:()=>av,faVolleyballBall:()=>lv,faVolumeDown:()=>cv,faVolumeMute:()=>uv,faVolumeOff:()=>hv,faVolumeUp:()=>dv,faVoteYea:()=>pv,faVrCardboard:()=>gv,faWalking:()=>fv,faWallet:()=>mv,faWarehouse:()=>vv,faWater:()=>Cv,faWaveSquare:()=>yv,faWeight:()=>wv,faWeightHanging:()=>Sv,faWheelchair:()=>bv,faWifi:()=>Ev,faWind:()=>Av,faWindowClose:()=>Tv,faWindowMaximize:()=>Mv,faWindowMinimize:()=>Rv,faWindowRestore:()=>_v,faWineBottle:()=>Pv,faWineGlass:()=>xv,faWineGlassAlt:()=>Dv,faWonSign:()=>Iv,faWrench:()=>Lv,faXRay:()=>Nv,faYenSign:()=>Ov,faYinYang:()=>Fv,fas:()=>kv,prefix:()=>r});var r="fas",n={prefix:"fas",iconName:"ad",icon:[512,512,[],"f641","M157.52 272h36.96L176 218.78 157.52 272zM352 256c-13.23 0-24 10.77-24 24s10.77 24 24 24 24-10.77 24-24-10.77-24-24-24zM464 64H48C21.5 64 0 85.5 0 112v288c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM250.58 352h-16.94c-6.81 0-12.88-4.32-15.12-10.75L211.15 320h-70.29l-7.38 21.25A16 16 0 0 1 118.36 352h-16.94c-11.01 0-18.73-10.85-15.12-21.25L140 176.12A23.995 23.995 0 0 1 162.67 160h26.66A23.99 23.99 0 0 1 212 176.13l53.69 154.62c3.61 10.4-4.11 21.25-15.11 21.25zM424 336c0 8.84-7.16 16-16 16h-16c-4.85 0-9.04-2.27-11.98-5.68-8.62 3.66-18.09 5.68-28.02 5.68-39.7 0-72-32.3-72-72s32.3-72 72-72c8.46 0 16.46 1.73 24 4.42V176c0-8.84 7.16-16 16-16h16c8.84 0 16 7.16 16 16v160z"]},s={prefix:"fas",iconName:"address-book",icon:[448,512,[],"f2b9","M436 160c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h320c26.5 0 48-21.5 48-48v-48h20c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20v-64h20c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20v-64h20zm-228-32c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm112 236.8c0 10.6-10 19.2-22.4 19.2H118.4C106 384 96 375.4 96 364.8v-19.2c0-31.8 30.1-57.6 67.2-57.6h5c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h5c37.1 0 67.2 25.8 67.2 57.6v19.2z"]},o={prefix:"fas",iconName:"address-card",icon:[576,512,[],"f2bb","M528 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h480c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zm-352 96c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm112 236.8c0 10.6-10 19.2-22.4 19.2H86.4C74 384 64 375.4 64 364.8v-19.2c0-31.8 30.1-57.6 67.2-57.6h5c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h5c37.1 0 67.2 25.8 67.2 57.6v19.2zM512 312c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16zm0-64c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16zm0-64c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16z"]},a={prefix:"fas",iconName:"adjust",icon:[512,512,[],"f042","M8 256c0 136.966 111.033 248 248 248s248-111.034 248-248S392.966 8 256 8 8 119.033 8 256zm248 184V72c101.705 0 184 82.311 184 184 0 101.705-82.311 184-184 184z"]},l={prefix:"fas",iconName:"air-freshener",icon:[512,512,[],"f5d0","M224 160H96C43 160 0 203 0 256V480C0 497.625 14.375 512 32 512H288C305.625 512 320 497.625 320 480V256C320 203 277 160 224 160ZM160 416C115.875 416 80 380.125 80 336S115.875 256 160 256S240 291.875 240 336S204.125 416 160 416ZM224 32C224 14.375 209.625 0 192 0H128C110.375 0 96 14.375 96 32V128H224V32ZM381.781 51.578C383 50.969 384 49.359 384 48C384 46.625 383 45.031 381.781 44.422L352 32L339.562 2.219C338.969 1 337.375 0 336 0S333.031 1 332.406 2.219L320 32L290.219 44.422C289 45.031 288 46.625 288 48C288 49.359 289 50.969 290.219 51.578L320 64L332.406 93.781C333.031 95 334.625 96 336 96S338.969 95 339.562 93.781L352 64L381.781 51.578ZM448 64L460.406 93.781C461.031 95 462.625 96 464 96S466.969 95 467.562 93.781L480 64L509.781 51.578C511 50.969 512 49.359 512 48C512 46.625 511 45.031 509.781 44.422L480 32L467.562 2.219C466.969 1 465.375 0 464 0S461.031 1 460.406 2.219L448 32L418.219 44.422C417 45.031 416 46.625 416 48C416 49.359 417 50.969 418.219 51.578L448 64ZM480 224L467.562 194.219C466.969 193 465.375 192 464 192S461.031 193 460.406 194.219L448 224L418.219 236.422C417 237.031 416 238.625 416 240C416 241.359 417 242.969 418.219 243.578L448 256L460.406 285.781C461.031 287 462.625 288 464 288S466.969 287 467.562 285.781L480 256L509.781 243.578C511 242.969 512 241.359 512 240C512 238.625 511 237.031 509.781 236.422L480 224ZM445.781 147.578C447 146.969 448 145.359 448 144C448 142.625 447 141.031 445.781 140.422L416 128L403.562 98.219C402.969 97 401.375 96 400 96S397.031 97 396.406 98.219L384 128L354.219 140.422C353 141.031 352 142.625 352 144C352 145.359 353 146.969 354.219 147.578L384 160L396.406 189.781C397.031 191 398.625 192 400 192S402.969 191 403.562 189.781L416 160L445.781 147.578Z"]},c={prefix:"fas",iconName:"align-center",icon:[448,512,[],"f037","M432 160H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0 256H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM108.1 96h231.81A12.09 12.09 0 0 0 352 83.9V44.09A12.09 12.09 0 0 0 339.91 32H108.1A12.09 12.09 0 0 0 96 44.09V83.9A12.1 12.1 0 0 0 108.1 96zm231.81 256A12.09 12.09 0 0 0 352 339.9v-39.81A12.09 12.09 0 0 0 339.91 288H108.1A12.09 12.09 0 0 0 96 300.09v39.81a12.1 12.1 0 0 0 12.1 12.1z"]},u={prefix:"fas",iconName:"align-justify",icon:[448,512,[],"f039","M432 416H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-128H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-128H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-128H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},h={prefix:"fas",iconName:"align-left",icon:[448,512,[],"f036","M12.83 352h262.34A12.82 12.82 0 0 0 288 339.17v-38.34A12.82 12.82 0 0 0 275.17 288H12.83A12.82 12.82 0 0 0 0 300.83v38.34A12.82 12.82 0 0 0 12.83 352zm0-256h262.34A12.82 12.82 0 0 0 288 83.17V44.83A12.82 12.82 0 0 0 275.17 32H12.83A12.82 12.82 0 0 0 0 44.83v38.34A12.82 12.82 0 0 0 12.83 96zM432 160H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0 256H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},d={prefix:"fas",iconName:"align-right",icon:[448,512,[],"f038","M16 224h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm416 192H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm3.17-384H172.83A12.82 12.82 0 0 0 160 44.83v38.34A12.82 12.82 0 0 0 172.83 96h262.34A12.82 12.82 0 0 0 448 83.17V44.83A12.82 12.82 0 0 0 435.17 32zm0 256H172.83A12.82 12.82 0 0 0 160 300.83v38.34A12.82 12.82 0 0 0 172.83 352h262.34A12.82 12.82 0 0 0 448 339.17v-38.34A12.82 12.82 0 0 0 435.17 288z"]},p={prefix:"fas",iconName:"allergies",icon:[448,512,[],"f461","M416 112c-17.6 0-32 14.4-32 32v72c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8V64c0-17.6-14.4-32-32-32s-32 14.4-32 32v152c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8V32c0-17.6-14.4-32-32-32s-32 14.4-32 32v184c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8V64c0-17.6-14.4-32-32-32S96 46.4 96 64v241l-23.6-32.5c-13-17.9-38-21.8-55.9-8.8s-21.8 38-8.8 55.9l125.6 172.7c9 12.4 23.5 19.8 38.8 19.8h197.6c22.3 0 41.6-15.3 46.7-37l26.5-112.7c3.2-13.7 4.9-28.3 5.1-42.3V144c0-17.6-14.4-32-32-32zM176 416c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm0-96c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm64 128c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm0-96c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm64 32c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm32 64c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm32-128c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16z"]},g={prefix:"fas",iconName:"ambulance",icon:[640,512,[],"f0f9","M624 352h-16V243.9c0-12.7-5.1-24.9-14.1-33.9L494 110.1c-9-9-21.2-14.1-33.9-14.1H416V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h16c0 53 43 96 96 96s96-43 96-96h128c0 53 43 96 96 96s96-43 96-96h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM160 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm144-248c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8v48zm176 248c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm80-208H416V144h44.1l99.9 99.9V256z"]},f={prefix:"fas",iconName:"american-sign-language-interpreting",icon:[640,512,[],"f2a3","M290.547 189.039c-20.295-10.149-44.147-11.199-64.739-3.89 42.606 0 71.208 20.475 85.578 50.576 8.576 17.899-5.148 38.071-23.617 38.071 18.429 0 32.211 20.136 23.617 38.071-14.725 30.846-46.123 50.854-80.298 50.854-.557 0-94.471-8.615-94.471-8.615l-66.406 33.347c-9.384 4.693-19.815.379-23.895-7.781L1.86 290.747c-4.167-8.615-1.111-18.897 6.946-23.621l58.072-33.069L108 159.861c6.39-57.245 34.731-109.767 79.743-146.726 11.391-9.448 28.341-7.781 37.51 3.613 9.446 11.394 7.78 28.067-3.612 37.516-12.503 10.559-23.618 22.509-32.509 35.57 21.672-14.729 46.679-24.732 74.186-28.067 14.725-1.945 28.063 8.336 29.73 23.065 1.945 14.728-8.336 28.067-23.062 29.734-16.116 1.945-31.12 7.503-44.178 15.284 26.114-5.713 58.712-3.138 88.079 11.115 13.336 6.669 18.893 22.509 12.224 35.848-6.389 13.06-22.504 18.617-35.564 12.226zm-27.229 69.472c-6.112-12.505-18.338-20.286-32.231-20.286a35.46 35.46 0 0 0-35.565 35.57c0 21.428 17.808 35.57 35.565 35.57 13.893 0 26.119-7.781 32.231-20.286 4.446-9.449 13.614-15.006 23.339-15.284-9.725-.277-18.893-5.835-23.339-15.284zm374.821-37.237c4.168 8.615 1.111 18.897-6.946 23.621l-58.071 33.069L532 352.16c-6.39 57.245-34.731 109.767-79.743 146.726-10.932 9.112-27.799 8.144-37.51-3.613-9.446-11.394-7.78-28.067 3.613-37.516 12.503-10.559 23.617-22.509 32.508-35.57-21.672 14.729-46.679 24.732-74.186 28.067-10.021 2.506-27.552-5.643-29.73-23.065-1.945-14.728 8.336-28.067 23.062-29.734 16.116-1.946 31.12-7.503 44.178-15.284-26.114 5.713-58.712 3.138-88.079-11.115-13.336-6.669-18.893-22.509-12.224-35.848 6.389-13.061 22.505-18.619 35.565-12.227 20.295 10.149 44.147 11.199 64.739 3.89-42.606 0-71.208-20.475-85.578-50.576-8.576-17.899 5.148-38.071 23.617-38.071-18.429 0-32.211-20.136-23.617-38.071 14.033-29.396 44.039-50.887 81.966-50.854l92.803 8.615 66.406-33.347c9.408-4.704 19.828-.354 23.894 7.781l44.455 88.926zm-229.227-18.618c-13.893 0-26.119 7.781-32.231 20.286-4.446 9.449-13.614 15.006-23.339 15.284 9.725.278 18.893 5.836 23.339 15.284 6.112 12.505 18.338 20.286 32.231 20.286a35.46 35.46 0 0 0 35.565-35.57c0-21.429-17.808-35.57-35.565-35.57z"]},m={prefix:"fas",iconName:"anchor",icon:[576,512,[],"f13d","M12.971 352h32.394C67.172 454.735 181.944 512 288 512c106.229 0 220.853-57.38 242.635-160h32.394c10.691 0 16.045-12.926 8.485-20.485l-67.029-67.029c-4.686-4.686-12.284-4.686-16.971 0l-67.029 67.029c-7.56 7.56-2.206 20.485 8.485 20.485h35.146c-20.29 54.317-84.963 86.588-144.117 94.015V256h52c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-52v-5.47c37.281-13.178 63.995-48.725 64-90.518C384.005 43.772 341.605.738 289.37.01 235.723-.739 192 42.525 192 96c0 41.798 26.716 77.35 64 90.53V192h-52c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h52v190.015c-58.936-7.399-123.82-39.679-144.117-94.015h35.146c10.691 0 16.045-12.926 8.485-20.485l-67.029-67.029c-4.686-4.686-12.284-4.686-16.971 0L4.485 331.515C-3.074 339.074 2.28 352 12.971 352zM288 64c17.645 0 32 14.355 32 32s-14.355 32-32 32-32-14.355-32-32 14.355-32 32-32z"]},v={prefix:"fas",iconName:"angle-double-down",icon:[320,512,[],"f103","M143 256.3L7 120.3c-9.4-9.4-9.4-24.6 0-33.9l22.6-22.6c9.4-9.4 24.6-9.4 33.9 0l96.4 96.4 96.4-96.4c9.4-9.4 24.6-9.4 33.9 0L313 86.3c9.4 9.4 9.4 24.6 0 33.9l-136 136c-9.4 9.5-24.6 9.5-34 .1zm34 192l136-136c9.4-9.4 9.4-24.6 0-33.9l-22.6-22.6c-9.4-9.4-24.6-9.4-33.9 0L160 352.1l-96.4-96.4c-9.4-9.4-24.6-9.4-33.9 0L7 278.3c-9.4 9.4-9.4 24.6 0 33.9l136 136c9.4 9.5 24.6 9.5 34 .1z"]},C={prefix:"fas",iconName:"angle-double-left",icon:[448,512,[],"f100","M223.7 239l136-136c9.4-9.4 24.6-9.4 33.9 0l22.6 22.6c9.4 9.4 9.4 24.6 0 33.9L319.9 256l96.4 96.4c9.4 9.4 9.4 24.6 0 33.9L393.7 409c-9.4 9.4-24.6 9.4-33.9 0l-136-136c-9.5-9.4-9.5-24.6-.1-34zm-192 34l136 136c9.4 9.4 24.6 9.4 33.9 0l22.6-22.6c9.4-9.4 9.4-24.6 0-33.9L127.9 256l96.4-96.4c9.4-9.4 9.4-24.6 0-33.9L201.7 103c-9.4-9.4-24.6-9.4-33.9 0l-136 136c-9.5 9.4-9.5 24.6-.1 34z"]},y={prefix:"fas",iconName:"angle-double-right",icon:[448,512,[],"f101","M224.3 273l-136 136c-9.4 9.4-24.6 9.4-33.9 0l-22.6-22.6c-9.4-9.4-9.4-24.6 0-33.9l96.4-96.4-96.4-96.4c-9.4-9.4-9.4-24.6 0-33.9L54.3 103c9.4-9.4 24.6-9.4 33.9 0l136 136c9.5 9.4 9.5 24.6.1 34zm192-34l-136-136c-9.4-9.4-24.6-9.4-33.9 0l-22.6 22.6c-9.4 9.4-9.4 24.6 0 33.9l96.4 96.4-96.4 96.4c-9.4 9.4-9.4 24.6 0 33.9l22.6 22.6c9.4 9.4 24.6 9.4 33.9 0l136-136c9.4-9.2 9.4-24.4 0-33.8z"]},w={prefix:"fas",iconName:"angle-double-up",icon:[320,512,[],"f102","M177 255.7l136 136c9.4 9.4 9.4 24.6 0 33.9l-22.6 22.6c-9.4 9.4-24.6 9.4-33.9 0L160 351.9l-96.4 96.4c-9.4 9.4-24.6 9.4-33.9 0L7 425.7c-9.4-9.4-9.4-24.6 0-33.9l136-136c9.4-9.5 24.6-9.5 34-.1zm-34-192L7 199.7c-9.4 9.4-9.4 24.6 0 33.9l22.6 22.6c9.4 9.4 24.6 9.4 33.9 0l96.4-96.4 96.4 96.4c9.4 9.4 24.6 9.4 33.9 0l22.6-22.6c9.4-9.4 9.4-24.6 0-33.9l-136-136c-9.2-9.4-24.4-9.4-33.8 0z"]},S={prefix:"fas",iconName:"angle-down",icon:[320,512,[],"f107","M143 352.3L7 216.3c-9.4-9.4-9.4-24.6 0-33.9l22.6-22.6c9.4-9.4 24.6-9.4 33.9 0l96.4 96.4 96.4-96.4c9.4-9.4 24.6-9.4 33.9 0l22.6 22.6c9.4 9.4 9.4 24.6 0 33.9l-136 136c-9.2 9.4-24.4 9.4-33.8 0z"]},b={prefix:"fas",iconName:"angle-left",icon:[256,512,[],"f104","M31.7 239l136-136c9.4-9.4 24.6-9.4 33.9 0l22.6 22.6c9.4 9.4 9.4 24.6 0 33.9L127.9 256l96.4 96.4c9.4 9.4 9.4 24.6 0 33.9L201.7 409c-9.4 9.4-24.6 9.4-33.9 0l-136-136c-9.5-9.4-9.5-24.6-.1-34z"]},E={prefix:"fas",iconName:"angle-right",icon:[256,512,[],"f105","M224.3 273l-136 136c-9.4 9.4-24.6 9.4-33.9 0l-22.6-22.6c-9.4-9.4-9.4-24.6 0-33.9l96.4-96.4-96.4-96.4c-9.4-9.4-9.4-24.6 0-33.9L54.3 103c9.4-9.4 24.6-9.4 33.9 0l136 136c9.5 9.4 9.5 24.6.1 34z"]},A={prefix:"fas",iconName:"angle-up",icon:[320,512,[],"f106","M177 159.7l136 136c9.4 9.4 9.4 24.6 0 33.9l-22.6 22.6c-9.4 9.4-24.6 9.4-33.9 0L160 255.9l-96.4 96.4c-9.4 9.4-24.6 9.4-33.9 0L7 329.7c-9.4-9.4-9.4-24.6 0-33.9l136-136c9.4-9.5 24.6-9.5 34-.1z"]},T={prefix:"fas",iconName:"angry",icon:[496,512,[],"f556","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM136 240c0-9.3 4.1-17.5 10.5-23.4l-31-9.3c-8.5-2.5-13.3-11.5-10.7-19.9 2.5-8.5 11.4-13.2 19.9-10.7l80 24c8.5 2.5 13.3 11.5 10.7 19.9-2.1 6.9-8.4 11.4-15.3 11.4-.5 0-1.1-.2-1.7-.2.7 2.7 1.7 5.3 1.7 8.2 0 17.7-14.3 32-32 32S136 257.7 136 240zm168 154.2c-27.8-33.4-84.2-33.4-112.1 0-13.5 16.3-38.2-4.2-24.6-20.5 20-24 49.4-37.8 80.6-37.8s60.6 13.8 80.6 37.8c13.8 16.5-11.1 36.6-24.5 20.5zm76.6-186.9l-31 9.3c6.3 5.8 10.5 14.1 10.5 23.4 0 17.7-14.3 32-32 32s-32-14.3-32-32c0-2.9.9-5.6 1.7-8.2-.6.1-1.1.2-1.7.2-6.9 0-13.2-4.5-15.3-11.4-2.5-8.5 2.3-17.4 10.7-19.9l80-24c8.4-2.5 17.4 2.3 19.9 10.7 2.5 8.5-2.3 17.4-10.8 19.9z"]},M={prefix:"fas",iconName:"ankh",icon:[320,512,[],"f644","M296 256h-44.62C272.46 222.01 288 181.65 288 144 288 55.63 230.69 0 160 0S32 55.63 32 144c0 37.65 15.54 78.01 36.62 112H24c-13.25 0-24 10.74-24 24v32c0 13.25 10.75 24 24 24h96v152c0 13.25 10.75 24 24 24h32c13.25 0 24-10.75 24-24V336h96c13.25 0 24-10.75 24-24v-32c0-13.26-10.75-24-24-24zM160 80c29.61 0 48 24.52 48 64 0 34.66-27.14 78.14-48 100.87-20.86-22.72-48-66.21-48-100.87 0-39.48 18.39-64 48-64z"]},R={prefix:"fas",iconName:"apple-alt",icon:[448,512,[],"f5d1","M350.85 129c25.97 4.67 47.27 18.67 63.92 42 14.65 20.67 24.64 46.67 29.96 78 4.67 28.67 4.32 57.33-1 86-7.99 47.33-23.97 87-47.94 119-28.64 38.67-64.59 58-107.87 58-10.66 0-22.3-3.33-34.96-10-8.66-5.33-18.31-8-28.97-8s-20.3 2.67-28.97 8c-12.66 6.67-24.3 10-34.96 10-43.28 0-79.23-19.33-107.87-58-23.97-32-39.95-71.67-47.94-119-5.32-28.67-5.67-57.33-1-86 5.32-31.33 15.31-57.33 29.96-78 16.65-23.33 37.95-37.33 63.92-42 15.98-2.67 37.95-.33 65.92 7 23.97 6.67 44.28 14.67 60.93 24 16.65-9.33 36.96-17.33 60.93-24 27.98-7.33 49.96-9.67 65.94-7zm-54.94-41c-9.32 8.67-21.65 15-36.96 19-10.66 3.33-22.3 5-34.96 5l-14.98-1c-1.33-9.33-1.33-20 0-32 2.67-24 10.32-42.33 22.97-55 9.32-8.67 21.65-15 36.96-19 10.66-3.33 22.3-5 34.96-5l14.98 1 1 15c0 12.67-1.67 24.33-4.99 35-3.99 15.33-10.31 27.67-18.98 37z"]},_={prefix:"fas",iconName:"archive",icon:[512,512,[],"f187","M32 448c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V160H32v288zm160-212c0-6.6 5.4-12 12-12h104c6.6 0 12 5.4 12 12v8c0 6.6-5.4 12-12 12H204c-6.6 0-12-5.4-12-12v-8zM480 32H32C14.3 32 0 46.3 0 64v48c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16V64c0-17.7-14.3-32-32-32z"]},P={prefix:"fas",iconName:"archway",icon:[576,512,[],"f557","M560 448h-16V96H32v352H16.02c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16H176c8.84 0 16-7.16 16-16V320c0-53.02 42.98-96 96-96s96 42.98 96 96l.02 160v16c0 8.84 7.16 16 16 16H560c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm0-448H16C7.16 0 0 7.16 0 16v32c0 8.84 7.16 16 16 16h544c8.84 0 16-7.16 16-16V16c0-8.84-7.16-16-16-16z"]},x={prefix:"fas",iconName:"arrow-alt-circle-down",icon:[512,512,[],"f358","M504 256c0 137-111 248-248 248S8 393 8 256 119 8 256 8s248 111 248 248zM212 140v116h-70.9c-10.7 0-16.1 13-8.5 20.5l114.9 114.3c4.7 4.7 12.2 4.7 16.9 0l114.9-114.3c7.6-7.6 2.2-20.5-8.5-20.5H300V140c0-6.6-5.4-12-12-12h-64c-6.6 0-12 5.4-12 12z"]},D={prefix:"fas",iconName:"arrow-alt-circle-left",icon:[512,512,[],"f359","M256 504C119 504 8 393 8 256S119 8 256 8s248 111 248 248-111 248-248 248zm116-292H256v-70.9c0-10.7-13-16.1-20.5-8.5L121.2 247.5c-4.7 4.7-4.7 12.2 0 16.9l114.3 114.9c7.6 7.6 20.5 2.2 20.5-8.5V300h116c6.6 0 12-5.4 12-12v-64c0-6.6-5.4-12-12-12z"]},I={prefix:"fas",iconName:"arrow-alt-circle-right",icon:[512,512,[],"f35a","M256 8c137 0 248 111 248 248S393 504 256 504 8 393 8 256 119 8 256 8zM140 300h116v70.9c0 10.7 13 16.1 20.5 8.5l114.3-114.9c4.7-4.7 4.7-12.2 0-16.9l-114.3-115c-7.6-7.6-20.5-2.2-20.5 8.5V212H140c-6.6 0-12 5.4-12 12v64c0 6.6 5.4 12 12 12z"]},L={prefix:"fas",iconName:"arrow-alt-circle-up",icon:[512,512,[],"f35b","M8 256C8 119 119 8 256 8s248 111 248 248-111 248-248 248S8 393 8 256zm292 116V256h70.9c10.7 0 16.1-13 8.5-20.5L264.5 121.2c-4.7-4.7-12.2-4.7-16.9 0l-115 114.3c-7.6 7.6-2.2 20.5 8.5 20.5H212v116c0 6.6 5.4 12 12 12h64c6.6 0 12-5.4 12-12z"]},N={prefix:"fas",iconName:"arrow-circle-down",icon:[512,512,[],"f0ab","M504 256c0 137-111 248-248 248S8 393 8 256 119 8 256 8s248 111 248 248zm-143.6-28.9L288 302.6V120c0-13.3-10.7-24-24-24h-16c-13.3 0-24 10.7-24 24v182.6l-72.4-75.5c-9.3-9.7-24.8-9.9-34.3-.4l-10.9 11c-9.4 9.4-9.4 24.6 0 33.9L239 404.3c9.4 9.4 24.6 9.4 33.9 0l132.7-132.7c9.4-9.4 9.4-24.6 0-33.9l-10.9-11c-9.5-9.5-25-9.3-34.3.4z"]},O={prefix:"fas",iconName:"arrow-circle-left",icon:[512,512,[],"f0a8","M256 504C119 504 8 393 8 256S119 8 256 8s248 111 248 248-111 248-248 248zm28.9-143.6L209.4 288H392c13.3 0 24-10.7 24-24v-16c0-13.3-10.7-24-24-24H209.4l75.5-72.4c9.7-9.3 9.9-24.8.4-34.3l-11-10.9c-9.4-9.4-24.6-9.4-33.9 0L107.7 239c-9.4 9.4-9.4 24.6 0 33.9l132.7 132.7c9.4 9.4 24.6 9.4 33.9 0l11-10.9c9.5-9.5 9.3-25-.4-34.3z"]},F={prefix:"fas",iconName:"arrow-circle-right",icon:[512,512,[],"f0a9","M256 8c137 0 248 111 248 248S393 504 256 504 8 393 8 256 119 8 256 8zm-28.9 143.6l75.5 72.4H120c-13.3 0-24 10.7-24 24v16c0 13.3 10.7 24 24 24h182.6l-75.5 72.4c-9.7 9.3-9.9 24.8-.4 34.3l11 10.9c9.4 9.4 24.6 9.4 33.9 0L404.3 273c9.4-9.4 9.4-24.6 0-33.9L271.6 106.3c-9.4-9.4-24.6-9.4-33.9 0l-11 10.9c-9.5 9.6-9.3 25.1.4 34.4z"]},k={prefix:"fas",iconName:"arrow-circle-up",icon:[512,512,[],"f0aa","M8 256C8 119 119 8 256 8s248 111 248 248-111 248-248 248S8 393 8 256zm143.6 28.9l72.4-75.5V392c0 13.3 10.7 24 24 24h16c13.3 0 24-10.7 24-24V209.4l72.4 75.5c9.3 9.7 24.8 9.9 34.3.4l10.9-11c9.4-9.4 9.4-24.6 0-33.9L273 107.7c-9.4-9.4-24.6-9.4-33.9 0L106.3 240.4c-9.4 9.4-9.4 24.6 0 33.9l10.9 11c9.6 9.5 25.1 9.3 34.4-.4z"]},G={prefix:"fas",iconName:"arrow-down",icon:[448,512,[],"f063","M413.1 222.5l22.2 22.2c9.4 9.4 9.4 24.6 0 33.9L241 473c-9.4 9.4-24.6 9.4-33.9 0L12.7 278.6c-9.4-9.4-9.4-24.6 0-33.9l22.2-22.2c9.5-9.5 25-9.3 34.3.4L184 343.4V56c0-13.3 10.7-24 24-24h32c13.3 0 24 10.7 24 24v287.4l114.8-120.5c9.3-9.8 24.8-10 34.3-.4z"]},V={prefix:"fas",iconName:"arrow-left",icon:[448,512,[],"f060","M257.5 445.1l-22.2 22.2c-9.4 9.4-24.6 9.4-33.9 0L7 273c-9.4-9.4-9.4-24.6 0-33.9L201.4 44.7c9.4-9.4 24.6-9.4 33.9 0l22.2 22.2c9.5 9.5 9.3 25-.4 34.3L136.6 216H424c13.3 0 24 10.7 24 24v32c0 13.3-10.7 24-24 24H136.6l120.5 114.8c9.8 9.3 10 24.8.4 34.3z"]},H={prefix:"fas",iconName:"arrow-right",icon:[448,512,[],"f061","M190.5 66.9l22.2-22.2c9.4-9.4 24.6-9.4 33.9 0L441 239c9.4 9.4 9.4 24.6 0 33.9L246.6 467.3c-9.4 9.4-24.6 9.4-33.9 0l-22.2-22.2c-9.5-9.5-9.3-25 .4-34.3L311.4 296H24c-13.3 0-24-10.7-24-24v-32c0-13.3 10.7-24 24-24h287.4L190.9 101.2c-9.8-9.3-10-24.8-.4-34.3z"]},B={prefix:"fas",iconName:"arrow-up",icon:[448,512,[],"f062","M34.9 289.5l-22.2-22.2c-9.4-9.4-9.4-24.6 0-33.9L207 39c9.4-9.4 24.6-9.4 33.9 0l194.3 194.3c9.4 9.4 9.4 24.6 0 33.9L413 289.4c-9.5 9.5-25 9.3-34.3-.4L264 168.6V456c0 13.3-10.7 24-24 24h-32c-13.3 0-24-10.7-24-24V168.6L69.2 289.1c-9.3 9.8-24.8 10-34.3.4z"]},z={prefix:"fas",iconName:"arrows-alt",icon:[512,512,[],"f0b2","M352.201 425.775l-79.196 79.196c-9.373 9.373-24.568 9.373-33.941 0l-79.196-79.196c-15.119-15.119-4.411-40.971 16.971-40.97h51.162L228 284H127.196v51.162c0 21.382-25.851 32.09-40.971 16.971L7.029 272.937c-9.373-9.373-9.373-24.569 0-33.941L86.225 159.8c15.119-15.119 40.971-4.411 40.971 16.971V228H228V127.196h-51.23c-21.382 0-32.09-25.851-16.971-40.971l79.196-79.196c9.373-9.373 24.568-9.373 33.941 0l79.196 79.196c15.119 15.119 4.411 40.971-16.971 40.971h-51.162V228h100.804v-51.162c0-21.382 25.851-32.09 40.97-16.971l79.196 79.196c9.373 9.373 9.373 24.569 0 33.941L425.773 352.2c-15.119 15.119-40.971 4.411-40.97-16.971V284H284v100.804h51.23c21.382 0 32.09 25.851 16.971 40.971z"]},U={prefix:"fas",iconName:"arrows-alt-h",icon:[512,512,[],"f337","M377.941 169.941V216H134.059v-46.059c0-21.382-25.851-32.09-40.971-16.971L7.029 239.029c-9.373 9.373-9.373 24.568 0 33.941l86.059 86.059c15.119 15.119 40.971 4.411 40.971-16.971V296h243.882v46.059c0 21.382 25.851 32.09 40.971 16.971l86.059-86.059c9.373-9.373 9.373-24.568 0-33.941l-86.059-86.059c-15.119-15.12-40.971-4.412-40.971 16.97z"]},W={prefix:"fas",iconName:"arrows-alt-v",icon:[256,512,[],"f338","M214.059 377.941H168V134.059h46.059c21.382 0 32.09-25.851 16.971-40.971L144.971 7.029c-9.373-9.373-24.568-9.373-33.941 0L24.971 93.088c-15.119 15.119-4.411 40.971 16.971 40.971H88v243.882H41.941c-21.382 0-32.09 25.851-16.971 40.971l86.059 86.059c9.373 9.373 24.568 9.373 33.941 0l86.059-86.059c15.12-15.119 4.412-40.971-16.97-40.971z"]},j={prefix:"fas",iconName:"assistive-listening-systems",icon:[512,512,[],"f2a2","M216 260c0 15.464-12.536 28-28 28s-28-12.536-28-28c0-44.112 35.888-80 80-80s80 35.888 80 80c0 15.464-12.536 28-28 28s-28-12.536-28-28c0-13.234-10.767-24-24-24s-24 10.766-24 24zm24-176c-97.047 0-176 78.953-176 176 0 15.464 12.536 28 28 28s28-12.536 28-28c0-66.168 53.832-120 120-120s120 53.832 120 120c0 75.164-71.009 70.311-71.997 143.622L288 404c0 28.673-23.327 52-52 52-15.464 0-28 12.536-28 28s12.536 28 28 28c59.475 0 107.876-48.328 108-107.774.595-34.428 72-48.24 72-144.226 0-97.047-78.953-176-176-176zm-80 236c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zM32 448c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm480-187.993c0-1.518-.012-3.025-.045-4.531C510.076 140.525 436.157 38.47 327.994 1.511c-14.633-4.998-30.549 2.809-35.55 17.442-5 14.633 2.81 30.549 17.442 35.55 85.906 29.354 144.61 110.513 146.077 201.953l.003.188c.026 1.118.033 2.236.033 3.363 0 15.464 12.536 28 28 28s28.001-12.536 28.001-28zM152.971 439.029l-80-80L39.03 392.97l80 80 33.941-33.941z"]},K={prefix:"fas",iconName:"asterisk",icon:[512,512,[],"f069","M478.21 334.093L336 256l142.21-78.093c11.795-6.477 15.961-21.384 9.232-33.037l-19.48-33.741c-6.728-11.653-21.72-15.499-33.227-8.523L296 186.718l3.475-162.204C299.763 11.061 288.937 0 275.48 0h-38.96c-13.456 0-24.283 11.061-23.994 24.514L216 186.718 77.265 102.607c-11.506-6.976-26.499-3.13-33.227 8.523l-19.48 33.741c-6.728 11.653-2.562 26.56 9.233 33.037L176 256 33.79 334.093c-11.795 6.477-15.961 21.384-9.232 33.037l19.48 33.741c6.728 11.653 21.721 15.499 33.227 8.523L216 325.282l-3.475 162.204C212.237 500.939 223.064 512 236.52 512h38.961c13.456 0 24.283-11.061 23.995-24.514L296 325.282l138.735 84.111c11.506 6.976 26.499 3.13 33.227-8.523l19.48-33.741c6.728-11.653 2.563-26.559-9.232-33.036z"]},$={prefix:"fas",iconName:"at",icon:[512,512,[],"f1fa","M256 8C118.941 8 8 118.919 8 256c0 137.059 110.919 248 248 248 48.154 0 95.342-14.14 135.408-40.223 12.005-7.815 14.625-24.288 5.552-35.372l-10.177-12.433c-7.671-9.371-21.179-11.667-31.373-5.129C325.92 429.757 291.314 440 256 440c-101.458 0-184-82.542-184-184S154.542 72 256 72c100.139 0 184 57.619 184 160 0 38.786-21.093 79.742-58.17 83.693-17.349-.454-16.91-12.857-13.476-30.024l23.433-121.11C394.653 149.75 383.308 136 368.225 136h-44.981a13.518 13.518 0 0 0-13.432 11.993l-.01.092c-14.697-17.901-40.448-21.775-59.971-21.775-74.58 0-137.831 62.234-137.831 151.46 0 65.303 36.785 105.87 96 105.87 26.984 0 57.369-15.637 74.991-38.333 9.522 34.104 40.613 34.103 70.71 34.103C462.609 379.41 504 307.798 504 232 504 95.653 394.023 8 256 8zm-21.68 304.43c-22.249 0-36.07-15.623-36.07-40.771 0-44.993 30.779-72.729 58.63-72.729 22.292 0 35.601 15.241 35.601 40.77 0 45.061-33.875 72.73-58.161 72.73z"]},q={prefix:"fas",iconName:"atlas",icon:[448,512,[],"f558","M318.38 208h-39.09c-1.49 27.03-6.54 51.35-14.21 70.41 27.71-13.24 48.02-39.19 53.3-70.41zm0-32c-5.29-31.22-25.59-57.17-53.3-70.41 7.68 19.06 12.72 43.38 14.21 70.41h39.09zM224 97.31c-7.69 7.45-20.77 34.42-23.43 78.69h46.87c-2.67-44.26-15.75-71.24-23.44-78.69zm-41.08 8.28c-27.71 13.24-48.02 39.19-53.3 70.41h39.09c1.49-27.03 6.53-51.35 14.21-70.41zm0 172.82c-7.68-19.06-12.72-43.38-14.21-70.41h-39.09c5.28 31.22 25.59 57.17 53.3 70.41zM247.43 208h-46.87c2.66 44.26 15.74 71.24 23.43 78.69 7.7-7.45 20.78-34.43 23.44-78.69zM448 358.4V25.6c0-16-9.6-25.6-25.6-25.6H96C41.6 0 0 41.6 0 96v320c0 54.4 41.6 96 96 96h326.4c12.8 0 25.6-9.6 25.6-25.6v-16c0-6.4-3.2-12.8-9.6-19.2-3.2-16-3.2-60.8 0-73.6 6.4-3.2 9.6-9.6 9.6-19.2zM224 64c70.69 0 128 57.31 128 128s-57.31 128-128 128S96 262.69 96 192 153.31 64 224 64zm160 384H96c-19.2 0-32-12.8-32-32s16-32 32-32h288v64z"]},Y={prefix:"fas",iconName:"atom",icon:[448,512,[],"f5d2","M223.99908,224a32,32,0,1,0,32.00782,32A32.06431,32.06431,0,0,0,223.99908,224Zm214.172-96c-10.877-19.5-40.50979-50.75-116.27544-41.875C300.39168,34.875,267.63386,0,223.99908,0s-76.39066,34.875-97.89653,86.125C50.3369,77.375,20.706,108.5,9.82907,128-6.54984,157.375-5.17484,201.125,34.958,256-5.17484,310.875-6.54984,354.625,9.82907,384c29.13087,52.375,101.64652,43.625,116.27348,41.875C147.60842,477.125,180.36429,512,223.99908,512s76.3926-34.875,97.89652-86.125c14.62891,1.75,87.14456,10.5,116.27544-41.875C454.55,354.625,453.175,310.875,413.04017,256,453.175,201.125,454.55,157.375,438.171,128ZM63.33886,352c-4-7.25-.125-24.75,15.00391-48.25,6.87695,6.5,14.12891,12.875,21.88087,19.125,1.625,13.75,4,27.125,6.75,40.125C82.34472,363.875,67.09081,358.625,63.33886,352Zm36.88478-162.875c-7.752,6.25-15.00392,12.625-21.88087,19.125-15.12891-23.5-19.00392-41-15.00391-48.25,3.377-6.125,16.37891-11.5,37.88478-11.5,1.75,0,3.875.375,5.75.375C104.09864,162.25,101.84864,175.625,100.22364,189.125ZM223.99908,64c9.50195,0,22.25586,13.5,33.88282,37.25-11.252,3.75-22.50391,8-33.88282,12.875-11.377-4.875-22.62892-9.125-33.88283-12.875C201.74516,77.5,214.49712,64,223.99908,64Zm0,384c-9.502,0-22.25392-13.5-33.88283-37.25,11.25391-3.75,22.50587-8,33.88283-12.875C235.378,402.75,246.62994,407,257.8819,410.75,246.25494,434.5,233.501,448,223.99908,448Zm0-112a80,80,0,1,1,80-80A80.00023,80.00023,0,0,1,223.99908,336ZM384.6593,352c-3.625,6.625-19.00392,11.875-43.63479,11,2.752-13,5.127-26.375,6.752-40.125,7.75195-6.25,15.00391-12.625,21.87891-19.125C384.7843,327.25,388.6593,344.75,384.6593,352ZM369.65538,208.25c-6.875-6.5-14.127-12.875-21.87891-19.125-1.625-13.5-3.875-26.875-6.752-40.25,1.875,0,4.002-.375,5.752-.375,21.50391,0,34.50782,5.375,37.88283,11.5C388.6593,167.25,384.7843,184.75,369.65538,208.25Z"]},Q={prefix:"fas",iconName:"audio-description",icon:[512,512,[],"f29e","M162.925 238.709l8.822 30.655h-25.606l9.041-30.652c1.277-4.421 2.651-9.994 3.872-15.245 1.22 5.251 2.594 10.823 3.871 15.242zm166.474-32.099h-14.523v98.781h14.523c29.776 0 46.175-17.678 46.175-49.776 0-32.239-17.49-49.005-46.175-49.005zM512 112v288c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V112c0-26.51 21.49-48 48-48h416c26.51 0 48 21.49 48 48zM245.459 336.139l-57.097-168A12.001 12.001 0 0 0 177 160h-35.894a12.001 12.001 0 0 0-11.362 8.139l-57.097 168C70.003 343.922 75.789 352 84.009 352h29.133a12 12 0 0 0 11.535-8.693l8.574-29.906h51.367l8.793 29.977A12 12 0 0 0 204.926 352h29.172c8.22 0 14.006-8.078 11.361-15.861zm184.701-80.525c0-58.977-37.919-95.614-98.96-95.614h-57.366c-6.627 0-12 5.373-12 12v168c0 6.627 5.373 12 12 12H331.2c61.041 0 98.96-36.933 98.96-96.386z"]},X={prefix:"fas",iconName:"award",icon:[384,512,[],"f559","M97.12 362.63c-8.69-8.69-4.16-6.24-25.12-11.85-9.51-2.55-17.87-7.45-25.43-13.32L1.2 448.7c-4.39 10.77 3.81 22.47 15.43 22.03l52.69-2.01L105.56 507c8 8.44 22.04 5.81 26.43-4.96l52.05-127.62c-10.84 6.04-22.87 9.58-35.31 9.58-19.5 0-37.82-7.59-51.61-21.37zM382.8 448.7l-45.37-111.24c-7.56 5.88-15.92 10.77-25.43 13.32-21.07 5.64-16.45 3.18-25.12 11.85-13.79 13.78-32.12 21.37-51.62 21.37-12.44 0-24.47-3.55-35.31-9.58L252 502.04c4.39 10.77 18.44 13.4 26.43 4.96l36.25-38.28 52.69 2.01c11.62.44 19.82-11.27 15.43-22.03zM263 340c15.28-15.55 17.03-14.21 38.79-20.14 13.89-3.79 24.75-14.84 28.47-28.98 7.48-28.4 5.54-24.97 25.95-45.75 10.17-10.35 14.14-25.44 10.42-39.58-7.47-28.38-7.48-24.42 0-52.83 3.72-14.14-.25-29.23-10.42-39.58-20.41-20.78-18.47-17.36-25.95-45.75-3.72-14.14-14.58-25.19-28.47-28.98-27.88-7.61-24.52-5.62-44.95-26.41-10.17-10.35-25-14.4-38.89-10.61-27.87 7.6-23.98 7.61-51.9 0-13.89-3.79-28.72.25-38.89 10.61-20.41 20.78-17.05 18.8-44.94 26.41-13.89 3.79-24.75 14.84-28.47 28.98-7.47 28.39-5.54 24.97-25.95 45.75-10.17 10.35-14.15 25.44-10.42 39.58 7.47 28.36 7.48 24.4 0 52.82-3.72 14.14.25 29.23 10.42 39.59 20.41 20.78 18.47 17.35 25.95 45.75 3.72 14.14 14.58 25.19 28.47 28.98C104.6 325.96 106.27 325 121 340c13.23 13.47 33.84 15.88 49.74 5.82a39.676 39.676 0 0 1 42.53 0c15.89 10.06 36.5 7.65 49.73-5.82zM97.66 175.96c0-53.03 42.24-96.02 94.34-96.02s94.34 42.99 94.34 96.02-42.24 96.02-94.34 96.02-94.34-42.99-94.34-96.02z"]},Z={prefix:"fas",iconName:"baby",icon:[384,512,[],"f77c","M192 160c44.2 0 80-35.8 80-80S236.2 0 192 0s-80 35.8-80 80 35.8 80 80 80zm-53.4 248.8l25.6-32-61.5-51.2L56.8 383c-11.4 14.2-11.7 34.4-.8 49l48 64c7.9 10.5 19.9 16 32 16 8.3 0 16.8-2.6 24-8 17.7-13.2 21.2-38.3 8-56l-29.4-39.2zm142.7-83.2l-61.5 51.2 25.6 32L216 448c-13.2 17.7-9.7 42.8 8 56 7.2 5.4 15.6 8 24 8 12.2 0 24.2-5.5 32-16l48-64c10.9-14.6 10.6-34.8-.8-49l-45.9-57.4zM376.7 145c-12.7-18.1-37.6-22.4-55.7-9.8l-40.6 28.5c-52.7 37-124.2 37-176.8 0L63 135.3C44.9 122.6 20 127 7.3 145-5.4 163.1-1 188 17 200.7l40.6 28.5c17 11.9 35.4 20.9 54.4 27.9V288h160v-30.8c19-7 37.4-16 54.4-27.9l40.6-28.5c18.1-12.8 22.4-37.7 9.7-55.8z"]},J={prefix:"fas",iconName:"baby-carriage",icon:[512,512,[],"f77d","M144.8 17c-11.3-17.8-37.2-22.8-54-9.4C35.3 51.9 0 118 0 192h256L144.8 17zM496 96h-48c-35.3 0-64 28.7-64 64v64H0c0 50.6 23 96.4 60.3 130.7C25.7 363.6 0 394.7 0 432c0 44.2 35.8 80 80 80s80-35.8 80-80c0-8.9-1.8-17.2-4.4-25.2 21.6 5.9 44.6 9.2 68.4 9.2s46.9-3.3 68.4-9.2c-2.7 8-4.4 16.3-4.4 25.2 0 44.2 35.8 80 80 80s80-35.8 80-80c0-37.3-25.7-68.4-60.3-77.3C425 320.4 448 274.6 448 224v-64h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM80 464c-17.6 0-32-14.4-32-32s14.4-32 32-32 32 14.4 32 32-14.4 32-32 32zm320-32c0 17.6-14.4 32-32 32s-32-14.4-32-32 14.4-32 32-32 32 14.4 32 32z"]},ee={prefix:"fas",iconName:"backspace",icon:[640,512,[],"f55a","M576 64H205.26A63.97 63.97 0 0 0 160 82.75L9.37 233.37c-12.5 12.5-12.5 32.76 0 45.25L160 429.25c12 12 28.28 18.75 45.25 18.75H576c35.35 0 64-28.65 64-64V128c0-35.35-28.65-64-64-64zm-84.69 254.06c6.25 6.25 6.25 16.38 0 22.63l-22.62 22.62c-6.25 6.25-16.38 6.25-22.63 0L384 301.25l-62.06 62.06c-6.25 6.25-16.38 6.25-22.63 0l-22.62-22.62c-6.25-6.25-6.25-16.38 0-22.63L338.75 256l-62.06-62.06c-6.25-6.25-6.25-16.38 0-22.63l22.62-22.62c6.25-6.25 16.38-6.25 22.63 0L384 210.75l62.06-62.06c6.25-6.25 16.38-6.25 22.63 0l22.62 22.62c6.25 6.25 6.25 16.38 0 22.63L429.25 256l62.06 62.06z"]},te={prefix:"fas",iconName:"backward",icon:[512,512,[],"f04a","M11.5 280.6l192 160c20.6 17.2 52.5 2.8 52.5-24.6V96c0-27.4-31.9-41.8-52.5-24.6l-192 160c-15.3 12.8-15.3 36.4 0 49.2zm256 0l192 160c20.6 17.2 52.5 2.8 52.5-24.6V96c0-27.4-31.9-41.8-52.5-24.6l-192 160c-15.3 12.8-15.3 36.4 0 49.2z"]},ie={prefix:"fas",iconName:"bacon",icon:[576,512,[],"f7e5","M218.92 336.39c34.89-34.89 44.2-59.7 54.05-86 10.61-28.29 21.59-57.54 61.37-97.34s69.05-50.77 97.35-61.38c23.88-9 46.64-17.68 76.79-45.37L470.81 8.91a31 31 0 0 0-40.18-2.83c-13.64 10.1-25.15 14.39-41 20.3C247 79.52 209.26 191.29 200.65 214.1c-29.75 78.83-89.55 94.68-98.72 98.09-24.86 9.26-54.73 20.38-91.07 50.36C-3 374-3.63 395 9.07 407.61l35.76 35.51C80 410.52 107 400.15 133 390.39c26.27-9.84 51.06-19.12 85.92-54zm348-232l-35.75-35.51c-35.19 32.63-62.18 43-88.25 52.79-26.26 9.85-51.06 19.16-85.95 54s-44.19 59.69-54 86C292.33 290 281.34 319.22 241.55 359s-69 50.73-97.3 61.32c-23.86 9-46.61 17.66-76.72 45.33l37.68 37.43a31 31 0 0 0 40.18 2.82c13.6-10.06 25.09-14.34 40.94-20.24 142.2-53 180-164.1 188.94-187.69C405 219.18 464.8 203.3 474 199.86c24.87-9.27 54.74-20.4 91.11-50.41 13.89-11.4 14.52-32.45 1.82-45.05z"]},re={prefix:"fas",iconName:"bacteria",icon:[640,512,[],"e059","M272.35,226.4A17.71,17.71,0,0,0,281.46,203l-4-9.08a121.29,121.29,0,0,1,12.36-3.08A83.34,83.34,0,0,0,323.57,177l10,9a17.76,17.76,0,1,0,23.92-26.27l-9.72-8.76a83.12,83.12,0,0,0,11.65-48.18l11.85-3.51a17.73,17.73,0,1,0-10.15-34l-11.34,3.36a84,84,0,0,0-36.38-35.57l2.84-10.85a17.8,17.8,0,0,0-34.47-8.93l-2.82,10.78a83.25,83.25,0,0,0-16.74,1.1C250.83,27,240,30.22,229.1,33.39l-3.38-9.46a17.8,17.8,0,0,0-33.56,11.89l3.49,9.8a286.74,286.74,0,0,0-43.94,23.57l-6.32-8.43a17.9,17.9,0,0,0-24.94-3.6A17.69,17.69,0,0,0,116.84,82l6.45,8.61a286.59,286.59,0,0,0-34.95,35.33l-8.82-6.42a17.84,17.84,0,0,0-24.89,3.86,17.66,17.66,0,0,0,3.88,24.77l8.88,6.47a286.6,286.6,0,0,0-23,43.91l-10.48-3.59a17.73,17.73,0,1,0-11.59,33.52L32.67,232c-2.79,10-5.79,19.84-7.52,30.22a83.16,83.16,0,0,0-.82,19l-11.58,3.43a17.73,17.73,0,1,0,10.13,34l11.27-3.33a83.51,83.51,0,0,0,36.39,35.43l-2.88,11.06a17.81,17.81,0,0,0,34.48,8.92l2.87-11c1,0,2.07.26,3.1.26a83.39,83.39,0,0,0,45.65-13.88l8.59,8.8a17.77,17.77,0,0,0,25.56-24.7l-9.14-9.37a83.41,83.41,0,0,0,12.08-31.05,119.08,119.08,0,0,1,3.87-15.53l9,4.22a17.74,17.74,0,1,0,15.15-32.09l-8.8-4.11c.67-1,1.2-2.08,1.9-3.05a119.89,119.89,0,0,1,7.87-9.41,121.73,121.73,0,0,1,11.65-11.4,119.49,119.49,0,0,1,9.94-7.82c1.12-.77,2.32-1.42,3.47-2.15l3.92,8.85a17.86,17.86,0,0,0,16.32,10.58A18.14,18.14,0,0,0,272.35,226.4ZM128,256a32,32,0,1,1,32-32A32,32,0,0,1,128,256Zm80-96a16,16,0,1,1,16-16A16,16,0,0,1,208,160Zm431.26,45.3a17.79,17.79,0,0,0-17.06-12.69,17.55,17.55,0,0,0-5.08.74l-11.27,3.33a83.61,83.61,0,0,0-36.39-35.43l2.88-11.06a17.81,17.81,0,0,0-34.48-8.91l-2.87,11c-1,0-2.07-.26-3.1-.26a83.32,83.32,0,0,0-45.65,13.89l-8.59-8.81a17.77,17.77,0,0,0-25.56,24.7l9.14,9.37a83.28,83.28,0,0,0-12.08,31.06,119.34,119.34,0,0,1-3.87,15.52l-9-4.22a17.74,17.74,0,1,0-15.15,32.09l8.8,4.11c-.67,1-1.2,2.08-1.89,3.05a117.71,117.71,0,0,1-7.94,9.47,119,119,0,0,1-11.57,11.33,121.59,121.59,0,0,1-10,7.83c-1.12.77-2.32,1.42-3.47,2.15l-3.92-8.85a17.86,17.86,0,0,0-16.32-10.58,18.14,18.14,0,0,0-7.18,1.5A17.71,17.71,0,0,0,358.54,309l4,9.08a118.71,118.71,0,0,1-12.36,3.08,83.34,83.34,0,0,0-33.77,13.9l-10-9a17.77,17.77,0,1,0-23.92,26.28l9.72,8.75a83.12,83.12,0,0,0-11.65,48.18l-11.86,3.51a17.73,17.73,0,1,0,10.16,34l11.34-3.36A84,84,0,0,0,326.61,479l-2.84,10.85a17.8,17.8,0,0,0,34.47,8.93L361.06,488a83.3,83.3,0,0,0,16.74-1.1c11.37-1.89,22.24-5.07,33.1-8.24l3.38,9.46a17.8,17.8,0,0,0,33.56-11.89l-3.49-9.79a287.66,287.66,0,0,0,43.94-23.58l6.32,8.43a17.88,17.88,0,0,0,24.93,3.6A17.67,17.67,0,0,0,523.16,430l-6.45-8.61a287.37,287.37,0,0,0,34.95-35.34l8.82,6.42a17.76,17.76,0,1,0,21-28.63l-8.88-6.46a287.17,287.17,0,0,0,23-43.92l10.48,3.59a17.73,17.73,0,1,0,11.59-33.52L607.33,280c2.79-10,5.79-19.84,7.52-30.21a83.27,83.27,0,0,0,.82-19.05l11.58-3.43A17.7,17.7,0,0,0,639.26,205.3ZM416,416a32,32,0,1,1,32-32A32,32,0,0,1,416,416Z"]},ne={prefix:"fas",iconName:"bacterium",icon:[512,512,[],"e05a","M511,102.93A23.76,23.76,0,0,0,481.47,87l-15.12,4.48a111.85,111.85,0,0,0-48.5-47.42l3.79-14.47a23.74,23.74,0,0,0-46-11.91l-3.76,14.37a111.94,111.94,0,0,0-22.33,1.47,386.74,386.74,0,0,0-44.33,10.41l-4.3-12a23.74,23.74,0,0,0-44.75,15.85l4.3,12.05a383.4,383.4,0,0,0-58.69,31.83l-8-10.63a23.85,23.85,0,0,0-33.24-4.8,23.57,23.57,0,0,0-4.83,33.09l8,10.63a386.14,386.14,0,0,0-46.7,47.44l-11-8a23.68,23.68,0,1,0-28,38.17l11.09,8.06a383.45,383.45,0,0,0-30.92,58.75l-12.93-4.43a23.65,23.65,0,1,0-15.47,44.69l13,4.48a385.81,385.81,0,0,0-9.3,40.53A111.58,111.58,0,0,0,32.44,375L17,379.56a23.64,23.64,0,0,0,13.51,45.31l15-4.44a111.49,111.49,0,0,0,48.53,47.24l-3.85,14.75a23.66,23.66,0,0,0,17,28.83,24.7,24.7,0,0,0,6,.75,23.73,23.73,0,0,0,23-17.7L140,479.67c1.37.05,2.77.35,4.13.35A111.22,111.22,0,0,0,205,461.5l11.45,11.74a23.7,23.7,0,0,0,34.08-32.93l-12.19-12.5a111,111,0,0,0,16.11-41.4,158.69,158.69,0,0,1,5.16-20.71l12,5.64a23.66,23.66,0,1,0,20.19-42.79l-11.72-5.49c.89-1.32,1.59-2.77,2.52-4.06a157.86,157.86,0,0,1,10.46-12.49,159.5,159.5,0,0,1,15.59-15.28,162.18,162.18,0,0,1,13.23-10.4c1.5-1,3.1-1.89,4.63-2.87l5.23,11.8a23.74,23.74,0,0,0,43.48-19.08l-5.36-12.11a158.87,158.87,0,0,1,16.49-4.1,111,111,0,0,0,45-18.54l13.33,12a23.69,23.69,0,1,0,31.88-35l-12.94-11.67A110.83,110.83,0,0,0,479.21,137L495,132.32A23.61,23.61,0,0,0,511,102.93ZM160,368a48,48,0,1,1,48-48A48,48,0,0,1,160,368Zm80-136a24,24,0,1,1,24-24A24,24,0,0,1,240,232Z"]},se={prefix:"fas",iconName:"bahai",icon:[512,512,[],"f666","M496.25 202.52l-110-15.44 41.82-104.34c6.67-16.64-11.6-32.18-26.59-22.63L307.44 120 273.35 12.82C270.64 4.27 263.32 0 256 0c-7.32 0-14.64 4.27-17.35 12.82l-34.09 107.19-94.04-59.89c-14.99-9.55-33.25 5.99-26.59 22.63l41.82 104.34-110 15.43c-17.54 2.46-21.68 26.27-6.03 34.67l98.16 52.66-74.48 83.54c-10.92 12.25-1.72 30.93 13.29 30.93 1.31 0 2.67-.14 4.07-.45l108.57-23.65-4.11 112.55c-.43 11.65 8.87 19.22 18.41 19.22 5.15 0 10.39-2.21 14.2-7.18l68.18-88.9 68.18 88.9c3.81 4.97 9.04 7.18 14.2 7.18 9.54 0 18.84-7.57 18.41-19.22l-4.11-112.55 108.57 23.65c17.36 3.76 29.21-17.2 17.35-30.49l-74.48-83.54 98.16-52.66c15.64-8.39 11.5-32.2-6.04-34.66zM338.51 311.68l-51.89-11.3 1.97 53.79L256 311.68l-32.59 42.49 1.96-53.79-51.89 11.3 35.6-39.93-46.92-25.17 52.57-7.38-19.99-49.87 44.95 28.62L256 166.72l16.29 51.23 44.95-28.62-19.99 49.87 52.57 7.38-46.92 25.17 35.61 39.93z"]},oe={prefix:"fas",iconName:"balance-scale",icon:[640,512,[],"f24e","M256 336h-.02c0-16.18 1.34-8.73-85.05-181.51-17.65-35.29-68.19-35.36-85.87 0C-2.06 328.75.02 320.33.02 336H0c0 44.18 57.31 80 128 80s128-35.82 128-80zM128 176l72 144H56l72-144zm511.98 160c0-16.18 1.34-8.73-85.05-181.51-17.65-35.29-68.19-35.36-85.87 0-87.12 174.26-85.04 165.84-85.04 181.51H384c0 44.18 57.31 80 128 80s128-35.82 128-80h-.02zM440 320l72-144 72 144H440zm88 128H352V153.25c23.51-10.29 41.16-31.48 46.39-57.25H528c8.84 0 16-7.16 16-16V48c0-8.84-7.16-16-16-16H383.64C369.04 12.68 346.09 0 320 0s-49.04 12.68-63.64 32H112c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h129.61c5.23 25.76 22.87 46.96 46.39 57.25V448H112c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h416c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},ae={prefix:"fas",iconName:"balance-scale-left",icon:[640,512,[],"f515","M528 448H352V153.25c20.42-8.94 36.1-26.22 43.38-47.47l132-44.26c8.38-2.81 12.89-11.88 10.08-20.26l-10.17-30.34C524.48 2.54 515.41-1.97 507.03.84L389.11 40.37C375.3 16.36 349.69 0 320 0c-44.18 0-80 35.82-80 80 0 3.43.59 6.71 1.01 10.03l-128.39 43.05c-8.38 2.81-12.89 11.88-10.08 20.26l10.17 30.34c2.81 8.38 11.88 12.89 20.26 10.08l142.05-47.63c4.07 2.77 8.43 5.12 12.99 7.12V496c0 8.84 7.16 16 16 16h224c8.84 0 16-7.16 16-16v-32c-.01-8.84-7.17-16-16.01-16zm111.98-144c0-16.18 1.34-8.73-85.05-181.51-17.65-35.29-68.19-35.36-85.87 0-87.12 174.26-85.04 165.84-85.04 181.51H384c0 44.18 57.31 80 128 80s128-35.82 128-80h-.02zM440 288l72-144 72 144H440zm-269.07-37.51c-17.65-35.29-68.19-35.36-85.87 0C-2.06 424.75.02 416.33.02 432H0c0 44.18 57.31 80 128 80s128-35.82 128-80h-.02c0-16.18 1.34-8.73-85.05-181.51zM56 416l72-144 72 144H56z"]},le={prefix:"fas",iconName:"balance-scale-right",icon:[640,512,[],"f516","M96 464v32c0 8.84 7.16 16 16 16h224c8.84 0 16-7.16 16-16V153.25c4.56-2 8.92-4.35 12.99-7.12l142.05 47.63c8.38 2.81 17.45-1.71 20.26-10.08l10.17-30.34c2.81-8.38-1.71-17.45-10.08-20.26l-128.4-43.05c.42-3.32 1.01-6.6 1.01-10.03 0-44.18-35.82-80-80-80-29.69 0-55.3 16.36-69.11 40.37L132.96.83c-8.38-2.81-17.45 1.71-20.26 10.08l-10.17 30.34c-2.81 8.38 1.71 17.45 10.08 20.26l132 44.26c7.28 21.25 22.96 38.54 43.38 47.47V448H112c-8.84 0-16 7.16-16 16zM0 304c0 44.18 57.31 80 128 80s128-35.82 128-80h-.02c0-15.67 2.08-7.25-85.05-181.51-17.68-35.36-68.22-35.29-85.87 0C-1.32 295.27.02 287.82.02 304H0zm56-16l72-144 72 144H56zm328.02 144H384c0 44.18 57.31 80 128 80s128-35.82 128-80h-.02c0-15.67 2.08-7.25-85.05-181.51-17.68-35.36-68.22-35.29-85.87 0-86.38 172.78-85.04 165.33-85.04 181.51zM440 416l72-144 72 144H440z"]},ce={prefix:"fas",iconName:"ban",icon:[512,512,[],"f05e","M256 8C119.034 8 8 119.033 8 256s111.034 248 248 248 248-111.034 248-248S392.967 8 256 8zm130.108 117.892c65.448 65.448 70 165.481 20.677 235.637L150.47 105.216c70.204-49.356 170.226-44.735 235.638 20.676zM125.892 386.108c-65.448-65.448-70-165.481-20.677-235.637L361.53 406.784c-70.203 49.356-170.226 44.736-235.638-20.676z"]},ue={prefix:"fas",iconName:"band-aid",icon:[640,512,[],"f462","M0 160v192c0 35.3 28.7 64 64 64h96V96H64c-35.3 0-64 28.7-64 64zm576-64h-96v320h96c35.3 0 64-28.7 64-64V160c0-35.3-28.7-64-64-64zM192 416h256V96H192v320zm176-232c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm0 96c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm-96-96c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm0 96c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24z"]},he={prefix:"fas",iconName:"barcode",icon:[512,512,[],"f02a","M0 448V64h18v384H0zm26.857-.273V64H36v383.727h-9.143zm27.143 0V64h8.857v383.727H54zm44.857 0V64h8.857v383.727h-8.857zm36 0V64h17.714v383.727h-17.714zm44.857 0V64h8.857v383.727h-8.857zm18 0V64h8.857v383.727h-8.857zm18 0V64h8.857v383.727h-8.857zm35.715 0V64h18v383.727h-18zm44.857 0V64h18v383.727h-18zm35.999 0V64h18.001v383.727h-18.001zm36.001 0V64h18.001v383.727h-18.001zm26.857 0V64h18v383.727h-18zm45.143 0V64h26.857v383.727h-26.857zm35.714 0V64h9.143v383.727H476zm18 .273V64h18v384h-18z"]},de={prefix:"fas",iconName:"bars",icon:[448,512,[],"f0c9","M16 132h416c8.837 0 16-7.163 16-16V76c0-8.837-7.163-16-16-16H16C7.163 60 0 67.163 0 76v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16zm0 160h416c8.837 0 16-7.163 16-16v-40c0-8.837-7.163-16-16-16H16c-8.837 0-16 7.163-16 16v40c0 8.837 7.163 16 16 16z"]},pe={prefix:"fas",iconName:"baseball-ball",icon:[496,512,[],"f433","M368.5 363.9l28.8-13.9c11.1 22.9 26 43.2 44.1 60.9 34-42.5 54.5-96.3 54.5-154.9 0-58.5-20.4-112.2-54.2-154.6-17.8 17.3-32.6 37.1-43.6 59.5l-28.7-14.1c12.8-26 30-49 50.8-69C375.6 34.7 315 8 248 8 181.1 8 120.5 34.6 75.9 77.7c20.7 19.9 37.9 42.9 50.7 68.8l-28.7 14.1c-11-22.3-25.7-42.1-43.5-59.4C20.4 143.7 0 197.4 0 256c0 58.6 20.4 112.3 54.4 154.7 18.2-17.7 33.2-38 44.3-61l28.8 13.9c-12.9 26.7-30.3 50.3-51.5 70.7 44.5 43.1 105.1 69.7 172 69.7 66.8 0 127.3-26.5 171.9-69.5-21.1-20.4-38.5-43.9-51.4-70.6zm-228.3-32l-30.5-9.8c14.9-46.4 12.7-93.8-.6-134l30.4-10c15 45.6 18 99.9.7 153.8zm216.3-153.4l30.4 10c-13.2 40.1-15.5 87.5-.6 134l-30.5 9.8c-17.3-54-14.3-108.3.7-153.8z"]},ge={prefix:"fas",iconName:"basketball-ball",icon:[496,512,[],"f434","M212.3 10.3c-43.8 6.3-86.2 24.1-122.2 53.8l77.4 77.4c27.8-35.8 43.3-81.2 44.8-131.2zM248 222L405.9 64.1c-42.4-35-93.6-53.5-145.5-56.1-1.2 63.9-21.5 122.3-58.7 167.7L248 222zM56.1 98.1c-29.7 36-47.5 78.4-53.8 122.2 50-1.5 95.5-17 131.2-44.8L56.1 98.1zm272.2 204.2c45.3-37.1 103.7-57.4 167.7-58.7-2.6-51.9-21.1-103.1-56.1-145.5L282 256l46.3 46.3zM248 290L90.1 447.9c42.4 34.9 93.6 53.5 145.5 56.1 1.3-64 21.6-122.4 58.7-167.7L248 290zm191.9 123.9c29.7-36 47.5-78.4 53.8-122.2-50.1 1.6-95.5 17.1-131.2 44.8l77.4 77.4zM167.7 209.7C122.3 246.9 63.9 267.3 0 268.4c2.6 51.9 21.1 103.1 56.1 145.5L214 256l-46.3-46.3zm116 292c43.8-6.3 86.2-24.1 122.2-53.8l-77.4-77.4c-27.7 35.7-43.2 81.2-44.8 131.2z"]},fe={prefix:"fas",iconName:"bath",icon:[512,512,[],"f2cd","M32,384a95.4,95.4,0,0,0,32,71.09V496a16,16,0,0,0,16,16h32a16,16,0,0,0,16-16V480H384v16a16,16,0,0,0,16,16h32a16,16,0,0,0,16-16V455.09A95.4,95.4,0,0,0,480,384V336H32ZM496,256H80V69.25a21.26,21.26,0,0,1,36.28-15l19.27,19.26c-13.13,29.88-7.61,59.11,8.62,79.73l-.17.17A16,16,0,0,0,144,176l11.31,11.31a16,16,0,0,0,22.63,0L283.31,81.94a16,16,0,0,0,0-22.63L272,48a16,16,0,0,0-22.62,0l-.17.17c-20.62-16.23-49.83-21.75-79.73-8.62L150.22,20.28A69.25,69.25,0,0,0,32,69.25V256H16A16,16,0,0,0,0,272v16a16,16,0,0,0,16,16H496a16,16,0,0,0,16-16V272A16,16,0,0,0,496,256Z"]},me={prefix:"fas",iconName:"battery-empty",icon:[640,512,[],"f244","M544 160v64h32v64h-32v64H64V160h480m16-64H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h512c26.51 0 48-21.49 48-48v-16h8c13.255 0 24-10.745 24-24V184c0-13.255-10.745-24-24-24h-8v-16c0-26.51-21.49-48-48-48z"]},ve={prefix:"fas",iconName:"battery-full",icon:[640,512,[],"f240","M544 160v64h32v64h-32v64H64V160h480m16-64H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h512c26.51 0 48-21.49 48-48v-16h8c13.255 0 24-10.745 24-24V184c0-13.255-10.745-24-24-24h-8v-16c0-26.51-21.49-48-48-48zm-48 96H96v128h416V192z"]},Ce={prefix:"fas",iconName:"battery-half",icon:[640,512,[],"f242","M544 160v64h32v64h-32v64H64V160h480m16-64H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h512c26.51 0 48-21.49 48-48v-16h8c13.255 0 24-10.745 24-24V184c0-13.255-10.745-24-24-24h-8v-16c0-26.51-21.49-48-48-48zm-240 96H96v128h224V192z"]},ye={prefix:"fas",iconName:"battery-quarter",icon:[640,512,[],"f243","M544 160v64h32v64h-32v64H64V160h480m16-64H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h512c26.51 0 48-21.49 48-48v-16h8c13.255 0 24-10.745 24-24V184c0-13.255-10.745-24-24-24h-8v-16c0-26.51-21.49-48-48-48zm-336 96H96v128h128V192z"]},we={prefix:"fas",iconName:"battery-three-quarters",icon:[640,512,[],"f241","M544 160v64h32v64h-32v64H64V160h480m16-64H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h512c26.51 0 48-21.49 48-48v-16h8c13.255 0 24-10.745 24-24V184c0-13.255-10.745-24-24-24h-8v-16c0-26.51-21.49-48-48-48zm-144 96H96v128h320V192z"]},Se={prefix:"fas",iconName:"bed",icon:[640,512,[],"f236","M176 256c44.11 0 80-35.89 80-80s-35.89-80-80-80-80 35.89-80 80 35.89 80 80 80zm352-128H304c-8.84 0-16 7.16-16 16v144H64V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v352c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-48h512v48c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16V240c0-61.86-50.14-112-112-112z"]},be={prefix:"fas",iconName:"beer",icon:[448,512,[],"f0fc","M368 96h-48V56c0-13.255-10.745-24-24-24H24C10.745 32 0 42.745 0 56v400c0 13.255 10.745 24 24 24h272c13.255 0 24-10.745 24-24v-42.11l80.606-35.977C429.396 365.063 448 336.388 448 304.86V176c0-44.112-35.888-80-80-80zm16 208.86a16.018 16.018 0 0 1-9.479 14.611L320 343.805V160h48c8.822 0 16 7.178 16 16v128.86zM208 384c-8.836 0-16-7.164-16-16V144c0-8.836 7.164-16 16-16s16 7.164 16 16v224c0 8.836-7.164 16-16 16zm-96 0c-8.836 0-16-7.164-16-16V144c0-8.836 7.164-16 16-16s16 7.164 16 16v224c0 8.836-7.164 16-16 16z"]},Ee={prefix:"fas",iconName:"bell",icon:[448,512,[],"f0f3","M224 512c35.32 0 63.97-28.65 63.97-64H160.03c0 35.35 28.65 64 63.97 64zm215.39-149.71c-19.32-20.76-55.47-51.99-55.47-154.29 0-77.7-54.48-139.9-127.94-155.16V32c0-17.67-14.32-32-31.98-32s-31.98 14.33-31.98 32v20.84C118.56 68.1 64.08 130.3 64.08 208c0 102.3-36.15 133.53-55.47 154.29-6 6.45-8.66 14.16-8.61 21.71.11 16.4 12.98 32 32.1 32h383.8c19.12 0 32-15.6 32.1-32 .05-7.55-2.61-15.27-8.61-21.71z"]},Ae={prefix:"fas",iconName:"bell-slash",icon:[640,512,[],"f1f6","M633.82 458.1l-90.62-70.05c.19-1.38.8-2.66.8-4.06.05-7.55-2.61-15.27-8.61-21.71-19.32-20.76-55.47-51.99-55.47-154.29 0-77.7-54.48-139.9-127.94-155.16V32c0-17.67-14.32-32-31.98-32s-31.98 14.33-31.98 32v20.84c-40.33 8.38-74.66 31.07-97.59 62.57L45.47 3.37C38.49-2.05 28.43-.8 23.01 6.18L3.37 31.45C-2.05 38.42-.8 48.47 6.18 53.9l588.35 454.73c6.98 5.43 17.03 4.17 22.46-2.81l19.64-25.27c5.42-6.97 4.17-17.02-2.81-22.45zM157.23 251.54c-8.61 67.96-36.41 93.33-52.62 110.75-6 6.45-8.66 14.16-8.61 21.71.11 16.4 12.98 32 32.1 32h241.92L157.23 251.54zM320 512c35.32 0 63.97-28.65 63.97-64H256.03c0 35.35 28.65 64 63.97 64z"]},Te={prefix:"fas",iconName:"bezier-curve",icon:[640,512,[],"f55b","M368 32h-96c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32zM208 88h-84.75C113.75 64.56 90.84 48 64 48 28.66 48 0 76.65 0 112s28.66 64 64 64c26.84 0 49.75-16.56 59.25-40h79.73c-55.37 32.52-95.86 87.32-109.54 152h49.4c11.3-41.61 36.77-77.21 71.04-101.56-3.7-8.08-5.88-16.99-5.88-26.44V88zm-48 232H64c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32zM576 48c-26.84 0-49.75 16.56-59.25 40H432v72c0 9.45-2.19 18.36-5.88 26.44 34.27 24.35 59.74 59.95 71.04 101.56h49.4c-13.68-64.68-54.17-119.48-109.54-152h79.73c9.5 23.44 32.41 40 59.25 40 35.34 0 64-28.65 64-64s-28.66-64-64-64zm0 272h-96c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32z"]},Me={prefix:"fas",iconName:"bible",icon:[448,512,[],"f647","M448 358.4V25.6c0-16-9.6-25.6-25.6-25.6H96C41.6 0 0 41.6 0 96v320c0 54.4 41.6 96 96 96h326.4c12.8 0 25.6-9.6 25.6-25.6v-16c0-6.4-3.2-12.8-9.6-19.2-3.2-16-3.2-60.8 0-73.6 6.4-3.2 9.6-9.6 9.6-19.2zM144 144c0-8.84 7.16-16 16-16h48V80c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v48h48c8.84 0 16 7.16 16 16v32c0 8.84-7.16 16-16 16h-48v112c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16V192h-48c-8.84 0-16-7.16-16-16v-32zm236.8 304H96c-19.2 0-32-12.8-32-32s16-32 32-32h284.8v64z"]},Re={prefix:"fas",iconName:"bicycle",icon:[640,512,[],"f206","M512.509 192.001c-16.373-.064-32.03 2.955-46.436 8.495l-77.68-125.153A24 24 0 0 0 368.001 64h-64c-8.837 0-16 7.163-16 16v16c0 8.837 7.163 16 16 16h50.649l14.896 24H256.002v-16c0-8.837-7.163-16-16-16h-87.459c-13.441 0-24.777 10.999-24.536 24.437.232 13.044 10.876 23.563 23.995 23.563h48.726l-29.417 47.52c-13.433-4.83-27.904-7.483-42.992-7.52C58.094 191.83.412 249.012.002 319.236-.413 390.279 57.055 448 128.002 448c59.642 0 109.758-40.793 123.967-96h52.033a24 24 0 0 0 20.406-11.367L410.37 201.77l14.938 24.067c-25.455 23.448-41.385 57.081-41.307 94.437.145 68.833 57.899 127.051 126.729 127.719 70.606.685 128.181-55.803 129.255-125.996 1.086-70.941-56.526-129.72-127.476-129.996zM186.75 265.772c9.727 10.529 16.673 23.661 19.642 38.228h-43.306l23.664-38.228zM128.002 400c-44.112 0-80-35.888-80-80s35.888-80 80-80c5.869 0 11.586.653 17.099 1.859l-45.505 73.509C89.715 331.327 101.213 352 120.002 352h81.3c-12.37 28.225-40.562 48-73.3 48zm162.63-96h-35.624c-3.96-31.756-19.556-59.894-42.383-80.026L237.371 184h127.547l-74.286 120zm217.057 95.886c-41.036-2.165-74.049-35.692-75.627-76.755-.812-21.121 6.633-40.518 19.335-55.263l44.433 71.586c4.66 7.508 14.524 9.816 22.032 5.156l13.594-8.437c7.508-4.66 9.817-14.524 5.156-22.032l-44.468-71.643a79.901 79.901 0 0 1 19.858-2.497c44.112 0 80 35.888 80 80-.001 45.54-38.252 82.316-84.313 79.885z"]},_e={prefix:"fas",iconName:"biking",icon:[640,512,[],"f84a","M400 96a48 48 0 1 0-48-48 48 48 0 0 0 48 48zm-4 121a31.9 31.9 0 0 0 20 7h64a32 32 0 0 0 0-64h-52.78L356 103a31.94 31.94 0 0 0-40.81.68l-112 96a32 32 0 0 0 3.08 50.92L288 305.12V416a32 32 0 0 0 64 0V288a32 32 0 0 0-14.25-26.62l-41.36-27.57 58.25-49.92zm116 39a128 128 0 1 0 128 128 128 128 0 0 0-128-128zm0 192a64 64 0 1 1 64-64 64 64 0 0 1-64 64zM128 256a128 128 0 1 0 128 128 128 128 0 0 0-128-128zm0 192a64 64 0 1 1 64-64 64 64 0 0 1-64 64z"]},Pe={prefix:"fas",iconName:"binoculars",icon:[512,512,[],"f1e5","M416 48c0-8.84-7.16-16-16-16h-64c-8.84 0-16 7.16-16 16v48h96V48zM63.91 159.99C61.4 253.84 3.46 274.22 0 404v44c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32V288h32V128H95.84c-17.63 0-31.45 14.37-31.93 31.99zm384.18 0c-.48-17.62-14.3-31.99-31.93-31.99H320v160h32v160c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-44c-3.46-129.78-61.4-150.16-63.91-244.01zM176 32h-64c-8.84 0-16 7.16-16 16v48h96V48c0-8.84-7.16-16-16-16zm48 256h64V128h-64v160z"]},xe={prefix:"fas",iconName:"biohazard",icon:[576,512,[],"f780","M287.9 112c18.6 0 36.2 3.8 52.8 9.6 13.3-10.3 23.6-24.3 29.5-40.7-25.2-10.9-53-17-82.2-17-29.1 0-56.9 6-82.1 16.9 5.9 16.4 16.2 30.4 29.5 40.7 16.5-5.7 34-9.5 52.5-9.5zM163.6 438.7c12-11.8 20.4-26.4 24.5-42.4-32.9-26.4-54.8-65.3-58.9-109.6-8.5-2.8-17.2-4.6-26.4-4.6-7.6 0-15.2 1-22.5 3.1 4.1 62.8 35.8 118 83.3 153.5zm224.2-42.6c4.1 16 12.5 30.7 24.5 42.5 47.4-35.5 79.1-90.7 83-153.5-7.2-2-14.7-3-22.2-3-9.2 0-18 1.9-26.6 4.7-4.1 44.2-26 82.9-58.7 109.3zm113.5-205c-17.6-10.4-36.3-16.6-55.3-19.9 6-17.7 10-36.4 10-56.2 0-41-14.5-80.8-41-112.2-2.5-3-6.6-3.7-10-1.8-3.3 1.9-4.8 6-3.6 9.7 4.5 13.8 6.6 26.3 6.6 38.5 0 67.8-53.8 122.9-120 122.9S168 117 168 49.2c0-12.1 2.2-24.7 6.6-38.5 1.2-3.7-.3-7.8-3.6-9.7-3.4-1.9-7.5-1.2-10 1.8C134.6 34.2 120 74 120 115c0 19.8 3.9 38.5 10 56.2-18.9 3.3-37.7 9.5-55.3 19.9-34.6 20.5-61 53.3-74.3 92.4-1.3 3.7.2 7.7 3.5 9.8 3.3 2 7.5 1.3 10-1.6 9.4-10.8 19-19.1 29.2-25.1 57.3-33.9 130.8-13.7 163.9 45 33.1 58.7 13.4 134-43.9 167.9-10.2 6.1-22 10.4-35.8 13.4-3.7.8-6.4 4.2-6.4 8.1.1 4 2.7 7.3 6.5 8 39.7 7.8 80.6.8 115.2-19.7 18-10.6 32.9-24.5 45.3-40.1 12.4 15.6 27.3 29.5 45.3 40.1 34.6 20.5 75.5 27.5 115.2 19.7 3.8-.7 6.4-4 6.5-8 0-3.9-2.6-7.3-6.4-8.1-13.9-2.9-25.6-7.3-35.8-13.4-57.3-33.9-77-109.2-43.9-167.9s106.6-78.9 163.9-45c10.2 6.1 19.8 14.3 29.2 25.1 2.5 2.9 6.7 3.6 10 1.6s4.8-6.1 3.5-9.8c-13.1-39.1-39.5-72-74.1-92.4zm-213.4 129c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48z"]},De={prefix:"fas",iconName:"birthday-cake",icon:[448,512,[],"f1fd","M448 384c-28.02 0-31.26-32-74.5-32-43.43 0-46.825 32-74.75 32-27.695 0-31.454-32-74.75-32-42.842 0-47.218 32-74.5 32-28.148 0-31.202-32-74.75-32-43.547 0-46.653 32-74.75 32v-80c0-26.5 21.5-48 48-48h16V112h64v144h64V112h64v144h64V112h64v144h16c26.5 0 48 21.5 48 48v80zm0 128H0v-96c43.356 0 46.767-32 74.75-32 27.951 0 31.253 32 74.75 32 42.843 0 47.217-32 74.5-32 28.148 0 31.201 32 74.75 32 43.357 0 46.767-32 74.75-32 27.488 0 31.252 32 74.5 32v96zM96 96c-17.75 0-32-14.25-32-32 0-31 32-23 32-64 12 0 32 29.5 32 56s-14.25 40-32 40zm128 0c-17.75 0-32-14.25-32-32 0-31 32-23 32-64 12 0 32 29.5 32 56s-14.25 40-32 40zm128 0c-17.75 0-32-14.25-32-32 0-31 32-23 32-64 12 0 32 29.5 32 56s-14.25 40-32 40z"]},Ie={prefix:"fas",iconName:"blender",icon:[512,512,[],"f517","M416 384H160c-35.35 0-64 28.65-64 64v32c0 17.67 14.33 32 32 32h320c17.67 0 32-14.33 32-32v-32c0-35.35-28.65-64-64-64zm-128 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm40-416h166.54L512 0H48C21.49 0 0 21.49 0 48v160c0 26.51 21.49 48 48 48h103.27l8.73 96h256l17.46-64H328c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h114.18l17.46-64H328c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h140.36l17.46-64H328c-4.42 0-8-3.58-8-8V72c0-4.42 3.58-8 8-8zM64 192V64h69.82l11.64 128H64z"]},Le={prefix:"fas",iconName:"blender-phone",icon:[576,512,[],"f6b6","M392 64h166.54L576 0H192v352h288l17.46-64H392c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h114.18l17.46-64H392c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h140.36l17.46-64H392c-4.42 0-8-3.58-8-8V72c0-4.42 3.58-8 8-8zM158.8 335.01l-25.78-63.26c-2.78-6.81-9.8-10.99-17.24-10.26l-45.03 4.42c-17.28-46.94-17.65-99.78 0-147.72l45.03 4.42c7.43.73 14.46-3.46 17.24-10.26l25.78-63.26c3.02-7.39.2-15.85-6.68-20.07l-39.28-24.1C98.51-3.87 80.09-.5 68.95 11.97c-92.57 103.6-92 259.55 2.1 362.49 9.87 10.8 29.12 12.48 41.65 4.8l39.41-24.18c6.89-4.22 9.7-12.67 6.69-20.07zM480 384H192c-35.35 0-64 28.65-64 64v32c0 17.67 14.33 32 32 32h352c17.67 0 32-14.33 32-32v-32c0-35.35-28.65-64-64-64zm-144 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Ne={prefix:"fas",iconName:"blind",icon:[384,512,[],"f29d","M380.15 510.837a8 8 0 0 1-10.989-2.687l-125.33-206.427a31.923 31.923 0 0 0 12.958-9.485l126.048 207.608a8 8 0 0 1-2.687 10.991zM142.803 314.338l-32.54 89.485 36.12 88.285c6.693 16.36 25.377 24.192 41.733 17.501 16.357-6.692 24.193-25.376 17.501-41.734l-62.814-153.537zM96 88c24.301 0 44-19.699 44-44S120.301 0 96 0 52 19.699 52 44s19.699 44 44 44zm154.837 169.128l-120-152c-4.733-5.995-11.75-9.108-18.837-9.112V96H80v.026c-7.146.003-14.217 3.161-18.944 9.24L0 183.766v95.694c0 13.455 11.011 24.791 24.464 24.536C37.505 303.748 48 293.1 48 280v-79.766l16-20.571v140.698L9.927 469.055c-6.04 16.609 2.528 34.969 19.138 41.009 16.602 6.039 34.968-2.524 41.009-19.138L136 309.638V202.441l-31.406-39.816a4 4 0 1 1 6.269-4.971l102.3 129.217c9.145 11.584 24.368 11.339 33.708 3.965 10.41-8.216 12.159-23.334 3.966-33.708z"]},Oe={prefix:"fas",iconName:"blog",icon:[512,512,[],"f781","M172.2 226.8c-14.6-2.9-28.2 8.9-28.2 23.8V301c0 10.2 7.1 18.4 16.7 22 18.2 6.8 31.3 24.4 31.3 45 0 26.5-21.5 48-48 48s-48-21.5-48-48V120c0-13.3-10.7-24-24-24H24c-13.3 0-24 10.7-24 24v248c0 89.5 82.1 160.2 175 140.7 54.4-11.4 98.3-55.4 109.7-109.7 17.4-82.9-37-157.2-112.5-172.2zM209 0c-9.2-.5-17 6.8-17 16v31.6c0 8.5 6.6 15.5 15 15.9 129.4 7 233.4 112 240.9 241.5.5 8.4 7.5 15 15.9 15h32.1c9.2 0 16.5-7.8 16-17C503.4 139.8 372.2 8.6 209 0zm.3 96c-9.3-.7-17.3 6.7-17.3 16.1v32.1c0 8.4 6.5 15.3 14.8 15.9 76.8 6.3 138 68.2 144.9 145.2.8 8.3 7.6 14.7 15.9 14.7h32.2c9.3 0 16.8-8 16.1-17.3-8.4-110.1-96.5-198.2-206.6-206.7z"]},Fe={prefix:"fas",iconName:"bold",icon:[384,512,[],"f032","M333.49 238a122 122 0 0 0 27-65.21C367.87 96.49 308 32 233.42 32H34a16 16 0 0 0-16 16v48a16 16 0 0 0 16 16h31.87v288H34a16 16 0 0 0-16 16v48a16 16 0 0 0 16 16h209.32c70.8 0 134.14-51.75 141-122.4 4.74-48.45-16.39-92.06-50.83-119.6zM145.66 112h87.76a48 48 0 0 1 0 96h-87.76zm87.76 288h-87.76V288h87.76a56 56 0 0 1 0 112z"]},ke={prefix:"fas",iconName:"bolt",icon:[320,512,[],"f0e7","M296 160H180.6l42.6-129.8C227.2 15 215.7 0 200 0H56C44 0 33.8 8.9 32.2 20.8l-32 240C-1.7 275.2 9.5 288 24 288h118.7L96.6 482.5c-3.6 15.2 8 29.5 23.3 29.5 8.4 0 16.4-4.4 20.8-12l176-304c9.3-15.9-2.2-36-20.7-36z"]},Ge={prefix:"fas",iconName:"bomb",icon:[512,512,[],"f1e2","M440.5 88.5l-52 52L415 167c9.4 9.4 9.4 24.6 0 33.9l-17.4 17.4c11.8 26.1 18.4 55.1 18.4 85.6 0 114.9-93.1 208-208 208S0 418.9 0 304 93.1 96 208 96c30.5 0 59.5 6.6 85.6 18.4L311 97c9.4-9.4 24.6-9.4 33.9 0l26.5 26.5 52-52 17.1 17zM500 60h-24c-6.6 0-12 5.4-12 12s5.4 12 12 12h24c6.6 0 12-5.4 12-12s-5.4-12-12-12zM440 0c-6.6 0-12 5.4-12 12v24c0 6.6 5.4 12 12 12s12-5.4 12-12V12c0-6.6-5.4-12-12-12zm33.9 55l17-17c4.7-4.7 4.7-12.3 0-17-4.7-4.7-12.3-4.7-17 0l-17 17c-4.7 4.7-4.7 12.3 0 17 4.8 4.7 12.4 4.7 17 0zm-67.8 0c4.7 4.7 12.3 4.7 17 0 4.7-4.7 4.7-12.3 0-17l-17-17c-4.7-4.7-12.3-4.7-17 0-4.7 4.7-4.7 12.3 0 17l17 17zm67.8 34c-4.7-4.7-12.3-4.7-17 0-4.7 4.7-4.7 12.3 0 17l17 17c4.7 4.7 12.3 4.7 17 0 4.7-4.7 4.7-12.3 0-17l-17-17zM112 272c0-35.3 28.7-64 64-64 8.8 0 16-7.2 16-16s-7.2-16-16-16c-52.9 0-96 43.1-96 96 0 8.8 7.2 16 16 16s16-7.2 16-16z"]},Ve={prefix:"fas",iconName:"bone",icon:[640,512,[],"f5d7","M598.88 244.56c25.2-12.6 41.12-38.36 41.12-66.53v-7.64C640 129.3 606.7 96 565.61 96c-32.02 0-60.44 20.49-70.57 50.86-7.68 23.03-11.6 45.14-38.11 45.14H183.06c-27.38 0-31.58-25.54-38.11-45.14C134.83 116.49 106.4 96 74.39 96 33.3 96 0 129.3 0 170.39v7.64c0 28.17 15.92 53.93 41.12 66.53 9.43 4.71 9.43 18.17 0 22.88C15.92 280.04 0 305.8 0 333.97v7.64C0 382.7 33.3 416 74.38 416c32.02 0 60.44-20.49 70.57-50.86 7.68-23.03 11.6-45.14 38.11-45.14h273.87c27.38 0 31.58 25.54 38.11 45.14C505.17 395.51 533.6 416 565.61 416c41.08 0 74.38-33.3 74.38-74.39v-7.64c0-28.18-15.92-53.93-41.12-66.53-9.42-4.71-9.42-18.17.01-22.88z"]},He={prefix:"fas",iconName:"bong",icon:[448,512,[],"f55c","M302.5 512c23.18 0 44.43-12.58 56-32.66C374.69 451.26 384 418.75 384 384c0-36.12-10.08-69.81-27.44-98.62L400 241.94l9.38 9.38c6.25 6.25 16.38 6.25 22.63 0l11.3-11.32c6.25-6.25 6.25-16.38 0-22.63l-52.69-52.69c-6.25-6.25-16.38-6.25-22.63 0l-11.31 11.31c-6.25 6.25-6.25 16.38 0 22.63l9.38 9.38-39.41 39.41c-11.56-11.37-24.53-21.33-38.65-29.51V63.74l15.97-.02c8.82-.01 15.97-7.16 15.98-15.98l.04-31.72C320 7.17 312.82-.01 303.97 0L80.03.26c-8.82.01-15.97 7.16-15.98 15.98l-.04 31.73c-.01 8.85 7.17 16.02 16.02 16.01L96 63.96v153.93C38.67 251.1 0 312.97 0 384c0 34.75 9.31 67.27 25.5 95.34C37.08 499.42 58.33 512 81.5 512h221zM120.06 259.43L144 245.56V63.91l96-.11v181.76l23.94 13.87c24.81 14.37 44.12 35.73 56.56 60.57h-257c12.45-24.84 31.75-46.2 56.56-60.57z"]},Be={prefix:"fas",iconName:"book",icon:[448,512,[],"f02d","M448 360V24c0-13.3-10.7-24-24-24H96C43 0 0 43 0 96v320c0 53 43 96 96 96h328c13.3 0 24-10.7 24-24v-16c0-7.5-3.5-14.3-8.9-18.7-4.2-15.4-4.2-59.3 0-74.7 5.4-4.3 8.9-11.1 8.9-18.6zM128 134c0-3.3 2.7-6 6-6h212c3.3 0 6 2.7 6 6v20c0 3.3-2.7 6-6 6H134c-3.3 0-6-2.7-6-6v-20zm0 64c0-3.3 2.7-6 6-6h212c3.3 0 6 2.7 6 6v20c0 3.3-2.7 6-6 6H134c-3.3 0-6-2.7-6-6v-20zm253.4 250H96c-17.7 0-32-14.3-32-32 0-17.6 14.4-32 32-32h285.4c-1.9 17.1-1.9 46.9 0 64z"]},ze={prefix:"fas",iconName:"book-dead",icon:[448,512,[],"f6b7","M272 136c8.8 0 16-7.2 16-16s-7.2-16-16-16-16 7.2-16 16 7.2 16 16 16zm176 222.4V25.6c0-16-9.6-25.6-25.6-25.6H96C41.6 0 0 41.6 0 96v320c0 54.4 41.6 96 96 96h326.4c12.8 0 25.6-9.6 25.6-25.6v-16c0-6.4-3.2-12.8-9.6-19.2-3.2-16-3.2-60.8 0-73.6 6.4-3.2 9.6-9.6 9.6-19.2zM240 56c44.2 0 80 28.7 80 64 0 20.9-12.7 39.2-32 50.9V184c0 8.8-7.2 16-16 16h-64c-8.8 0-16-7.2-16-16v-13.1c-19.3-11.7-32-30-32-50.9 0-35.3 35.8-64 80-64zM124.8 223.3l6.3-14.7c1.7-4.1 6.4-5.9 10.5-4.2l98.3 42.1 98.4-42.1c4.1-1.7 8.8.1 10.5 4.2l6.3 14.7c1.7 4.1-.1 8.8-4.2 10.5L280.6 264l70.3 30.1c4.1 1.7 5.9 6.4 4.2 10.5l-6.3 14.7c-1.7 4.1-6.4 5.9-10.5 4.2L240 281.4l-98.3 42.2c-4.1 1.7-8.8-.1-10.5-4.2l-6.3-14.7c-1.7-4.1.1-8.8 4.2-10.5l70.4-30.1-70.5-30.3c-4.1-1.7-5.9-6.4-4.2-10.5zm256 224.7H96c-19.2 0-32-12.8-32-32s16-32 32-32h284.8zM208 136c8.8 0 16-7.2 16-16s-7.2-16-16-16-16 7.2-16 16 7.2 16 16 16z"]},Ue={prefix:"fas",iconName:"book-medical",icon:[448,512,[],"f7e6","M448 358.4V25.6c0-16-9.6-25.6-25.6-25.6H96C41.6 0 0 41.6 0 96v320c0 54.4 41.6 96 96 96h326.4c12.8 0 25.6-9.6 25.6-25.6v-16q0-9.6-9.6-19.2c-3.2-16-3.2-60.8 0-73.6q9.6-4.8 9.6-19.2zM144 168a8 8 0 0 1 8-8h56v-56a8 8 0 0 1 8-8h48a8 8 0 0 1 8 8v56h56a8 8 0 0 1 8 8v48a8 8 0 0 1-8 8h-56v56a8 8 0 0 1-8 8h-48a8 8 0 0 1-8-8v-56h-56a8 8 0 0 1-8-8zm236.8 280H96c-19.2 0-32-12.8-32-32s16-32 32-32h284.8z"]},We={prefix:"fas",iconName:"book-open",icon:[576,512,[],"f518","M542.22 32.05c-54.8 3.11-163.72 14.43-230.96 55.59-4.64 2.84-7.27 7.89-7.27 13.17v363.87c0 11.55 12.63 18.85 23.28 13.49 69.18-34.82 169.23-44.32 218.7-46.92 16.89-.89 30.02-14.43 30.02-30.66V62.75c.01-17.71-15.35-31.74-33.77-30.7zM264.73 87.64C197.5 46.48 88.58 35.17 33.78 32.05 15.36 31.01 0 45.04 0 62.75V400.6c0 16.24 13.13 29.78 30.02 30.66 49.49 2.6 149.59 12.11 218.77 46.95 10.62 5.35 23.21-1.94 23.21-13.46V100.63c0-5.29-2.62-10.14-7.27-12.99z"]},je={prefix:"fas",iconName:"book-reader",icon:[512,512,[],"f5da","M352 96c0-53.02-42.98-96-96-96s-96 42.98-96 96 42.98 96 96 96 96-42.98 96-96zM233.59 241.1c-59.33-36.32-155.43-46.3-203.79-49.05C13.55 191.13 0 203.51 0 219.14v222.8c0 14.33 11.59 26.28 26.49 27.05 43.66 2.29 131.99 10.68 193.04 41.43 9.37 4.72 20.48-1.71 20.48-11.87V252.56c-.01-4.67-2.32-8.95-6.42-11.46zm248.61-49.05c-48.35 2.74-144.46 12.73-203.78 49.05-4.1 2.51-6.41 6.96-6.41 11.63v245.79c0 10.19 11.14 16.63 20.54 11.9 61.04-30.72 149.32-39.11 192.97-41.4 14.9-.78 26.49-12.73 26.49-27.06V219.14c-.01-15.63-13.56-28.01-29.81-27.09z"]},Ke={prefix:"fas",iconName:"bookmark",icon:[384,512,[],"f02e","M0 512V48C0 21.49 21.49 0 48 0h288c26.51 0 48 21.49 48 48v464L192 400 0 512z"]},$e={prefix:"fas",iconName:"border-all",icon:[448,512,[],"f84c","M416 32H32A32 32 0 0 0 0 64v384a32 32 0 0 0 32 32h384a32 32 0 0 0 32-32V64a32 32 0 0 0-32-32zm-32 64v128H256V96zm-192 0v128H64V96zM64 416V288h128v128zm192 0V288h128v128z"]},qe={prefix:"fas",iconName:"border-none",icon:[448,512,[],"f850","M240 224h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-288 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96 192h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-96h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-192h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM240 320h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-192h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-96 288h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96-384h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zM48 224H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0 192H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-96H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-192H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-96H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zm96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Ye={prefix:"fas",iconName:"border-style",icon:[448,512,[],"f853","M240 416h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-96 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm192 0h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm96-192h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0 96h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0 96h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-288h-32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-96H32A32 32 0 0 0 0 64v400a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V96h368a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Qe={prefix:"fas",iconName:"bowling-ball",icon:[496,512,[],"f436","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM120 192c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm64-96c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32zm48 144c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Xe={prefix:"fas",iconName:"box",icon:[512,512,[],"f466","M509.5 184.6L458.9 32.8C452.4 13.2 434.1 0 413.4 0H272v192h238.7c-.4-2.5-.4-5-1.2-7.4zM240 0H98.6c-20.7 0-39 13.2-45.5 32.8L2.5 184.6c-.8 2.4-.8 4.9-1.2 7.4H240V0zM0 224v240c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V224H0z"]},Ze={prefix:"fas",iconName:"box-open",icon:[640,512,[],"f49e","M425.7 256c-16.9 0-32.8-9-41.4-23.4L320 126l-64.2 106.6c-8.7 14.5-24.6 23.5-41.5 23.5-4.5 0-9-.6-13.3-1.9L64 215v178c0 14.7 10 27.5 24.2 31l216.2 54.1c10.2 2.5 20.9 2.5 31 0L551.8 424c14.2-3.6 24.2-16.4 24.2-31V215l-137 39.1c-4.3 1.3-8.8 1.9-13.3 1.9zm212.6-112.2L586.8 41c-3.1-6.2-9.8-9.8-16.7-8.9L320 64l91.7 152.1c3.8 6.3 11.4 9.3 18.5 7.3l197.9-56.5c9.9-2.9 14.7-13.9 10.2-23.1zM53.2 41L1.7 143.8c-4.6 9.2.3 20.2 10.1 23l197.9 56.5c7.1 2 14.7-1 18.5-7.3L320 64 69.8 32.1c-6.9-.8-13.5 2.7-16.6 8.9z"]},Je={prefix:"fas",iconName:"box-tissue",icon:[512,512,[],"e05b","M383.88,287.82l64-192H338.47a70.2,70.2,0,0,1-66.59-48,70.21,70.21,0,0,0-66.6-48H63.88l64,288Zm-384,192a32,32,0,0,0,32,32h448a32,32,0,0,0,32-32v-64H-.12Zm480-256H438.94l-21.33,64h14.27a16,16,0,0,1,0,32h-352a16,16,0,1,1,0-32H95.09l-14.22-64h-49a32,32,0,0,0-32,32v128h512v-128A32,32,0,0,0,479.88,223.82Z"]},et={prefix:"fas",iconName:"boxes",icon:[576,512,[],"f468","M560 288h-80v96l-32-21.3-32 21.3v-96h-80c-8.8 0-16 7.2-16 16v192c0 8.8 7.2 16 16 16h224c8.8 0 16-7.2 16-16V304c0-8.8-7.2-16-16-16zm-384-64h224c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16h-80v96l-32-21.3L256 96V0h-80c-8.8 0-16 7.2-16 16v192c0 8.8 7.2 16 16 16zm64 64h-80v96l-32-21.3L96 384v-96H16c-8.8 0-16 7.2-16 16v192c0 8.8 7.2 16 16 16h224c8.8 0 16-7.2 16-16V304c0-8.8-7.2-16-16-16z"]},tt={prefix:"fas",iconName:"braille",icon:[640,512,[],"f2a1","M128 256c0 35.346-28.654 64-64 64S0 291.346 0 256s28.654-64 64-64 64 28.654 64 64zM64 384c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0-352C28.654 32 0 60.654 0 96s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64zm160 192c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0 160c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0-352c-35.346 0-64 28.654-64 64s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64zm224 192c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0 160c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0-352c-35.346 0-64 28.654-64 64s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64zm160 192c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0 160c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm0-320c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32z"]},it={prefix:"fas",iconName:"brain",icon:[576,512,[],"f5dc","M208 0c-29.9 0-54.7 20.5-61.8 48.2-.8 0-1.4-.2-2.2-.2-35.3 0-64 28.7-64 64 0 4.8.6 9.5 1.7 14C52.5 138 32 166.6 32 200c0 12.6 3.2 24.3 8.3 34.9C16.3 248.7 0 274.3 0 304c0 33.3 20.4 61.9 49.4 73.9-.9 4.6-1.4 9.3-1.4 14.1 0 39.8 32.2 72 72 72 4.1 0 8.1-.5 12-1.2 9.6 28.5 36.2 49.2 68 49.2 39.8 0 72-32.2 72-72V64c0-35.3-28.7-64-64-64zm368 304c0-29.7-16.3-55.3-40.3-69.1 5.2-10.6 8.3-22.3 8.3-34.9 0-33.4-20.5-62-49.7-74 1-4.5 1.7-9.2 1.7-14 0-35.3-28.7-64-64-64-.8 0-1.5.2-2.2.2C422.7 20.5 397.9 0 368 0c-35.3 0-64 28.6-64 64v376c0 39.8 32.2 72 72 72 31.8 0 58.4-20.7 68-49.2 3.9.7 7.9 1.2 12 1.2 39.8 0 72-32.2 72-72 0-4.8-.5-9.5-1.4-14.1 29-12 49.4-40.6 49.4-73.9z"]},rt={prefix:"fas",iconName:"bread-slice",icon:[576,512,[],"f7ec","M288 0C108 0 0 93.4 0 169.14 0 199.44 24.24 224 64 224v256c0 17.67 16.12 32 36 32h376c19.88 0 36-14.33 36-32V224c39.76 0 64-24.56 64-54.86C576 93.4 468 0 288 0z"]},nt={prefix:"fas",iconName:"briefcase",icon:[512,512,[],"f0b1","M320 336c0 8.84-7.16 16-16 16h-96c-8.84 0-16-7.16-16-16v-48H0v144c0 25.6 22.4 48 48 48h416c25.6 0 48-22.4 48-48V288H320v48zm144-208h-80V80c0-25.6-22.4-48-48-48H176c-25.6 0-48 22.4-48 48v48H48c-25.6 0-48 22.4-48 48v80h512v-80c0-25.6-22.4-48-48-48zm-144 0H192V96h128v32z"]},st={prefix:"fas",iconName:"briefcase-medical",icon:[512,512,[],"f469","M464 128h-80V80c0-26.5-21.5-48-48-48H176c-26.5 0-48 21.5-48 48v48H48c-26.5 0-48 21.5-48 48v288c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V176c0-26.5-21.5-48-48-48zM192 96h128v32H192V96zm160 248c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8v48z"]},ot={prefix:"fas",iconName:"broadcast-tower",icon:[640,512,[],"f519","M150.94 192h33.73c11.01 0 18.61-10.83 14.86-21.18-4.93-13.58-7.55-27.98-7.55-42.82s2.62-29.24 7.55-42.82C203.29 74.83 195.68 64 184.67 64h-33.73c-7.01 0-13.46 4.49-15.41 11.23C130.64 92.21 128 109.88 128 128c0 18.12 2.64 35.79 7.54 52.76 1.94 6.74 8.39 11.24 15.4 11.24zM89.92 23.34C95.56 12.72 87.97 0 75.96 0H40.63c-6.27 0-12.14 3.59-14.74 9.31C9.4 45.54 0 85.65 0 128c0 24.75 3.12 68.33 26.69 118.86 2.62 5.63 8.42 9.14 14.61 9.14h34.84c12.02 0 19.61-12.74 13.95-23.37-49.78-93.32-16.71-178.15-.17-209.29zM614.06 9.29C611.46 3.58 605.6 0 599.33 0h-35.42c-11.98 0-19.66 12.66-14.02 23.25 18.27 34.29 48.42 119.42.28 209.23-5.72 10.68 1.8 23.52 13.91 23.52h35.23c6.27 0 12.13-3.58 14.73-9.29C630.57 210.48 640 170.36 640 128s-9.42-82.48-25.94-118.71zM489.06 64h-33.73c-11.01 0-18.61 10.83-14.86 21.18 4.93 13.58 7.55 27.98 7.55 42.82s-2.62 29.24-7.55 42.82c-3.76 10.35 3.85 21.18 14.86 21.18h33.73c7.02 0 13.46-4.49 15.41-11.24 4.9-16.97 7.53-34.64 7.53-52.76 0-18.12-2.64-35.79-7.54-52.76-1.94-6.75-8.39-11.24-15.4-11.24zm-116.3 100.12c7.05-10.29 11.2-22.71 11.2-36.12 0-35.35-28.63-64-63.96-64-35.32 0-63.96 28.65-63.96 64 0 13.41 4.15 25.83 11.2 36.12l-130.5 313.41c-3.4 8.15.46 17.52 8.61 20.92l29.51 12.31c8.15 3.4 17.52-.46 20.91-8.61L244.96 384h150.07l49.2 118.15c3.4 8.16 12.76 12.01 20.91 8.61l29.51-12.31c8.15-3.4 12-12.77 8.61-20.92l-130.5-313.41zM271.62 320L320 203.81 368.38 320h-96.76z"]},at={prefix:"fas",iconName:"broom",icon:[640,512,[],"f51a","M256.47 216.77l86.73 109.18s-16.6 102.36-76.57 150.12C206.66 523.85 0 510.19 0 510.19s3.8-23.14 11-55.43l94.62-112.17c3.97-4.7-.87-11.62-6.65-9.5l-60.4 22.09c14.44-41.66 32.72-80.04 54.6-97.47 59.97-47.76 163.3-40.94 163.3-40.94zM636.53 31.03l-19.86-25c-5.49-6.9-15.52-8.05-22.41-2.56l-232.48 177.8-34.14-42.97c-5.09-6.41-15.14-5.21-18.59 2.21l-25.33 54.55 86.73 109.18 58.8-12.45c8-1.69 11.42-11.2 6.34-17.6l-34.09-42.92 232.48-177.8c6.89-5.48 8.04-15.53 2.55-22.44z"]},lt={prefix:"fas",iconName:"brush",icon:[384,512,[],"f55d","M352 0H32C14.33 0 0 14.33 0 32v224h384V32c0-17.67-14.33-32-32-32zM0 320c0 35.35 28.66 64 64 64h64v64c0 35.35 28.66 64 64 64s64-28.65 64-64v-64h64c35.34 0 64-28.65 64-64v-32H0v32zm192 104c13.25 0 24 10.74 24 24 0 13.25-10.75 24-24 24s-24-10.75-24-24c0-13.26 10.75-24 24-24z"]},ct={prefix:"fas",iconName:"bug",icon:[512,512,[],"f188","M511.988 288.9c-.478 17.43-15.217 31.1-32.653 31.1H424v16c0 21.864-4.882 42.584-13.6 61.145l60.228 60.228c12.496 12.497 12.496 32.758 0 45.255-12.498 12.497-32.759 12.496-45.256 0l-54.736-54.736C345.886 467.965 314.351 480 280 480V236c0-6.627-5.373-12-12-12h-24c-6.627 0-12 5.373-12 12v244c-34.351 0-65.886-12.035-90.636-32.108l-54.736 54.736c-12.498 12.497-32.759 12.496-45.256 0-12.496-12.497-12.496-32.758 0-45.255l60.228-60.228C92.882 378.584 88 357.864 88 336v-16H32.666C15.23 320 .491 306.33.013 288.9-.484 270.816 14.028 256 32 256h56v-58.745l-46.628-46.628c-12.496-12.497-12.496-32.758 0-45.255 12.498-12.497 32.758-12.497 45.256 0L141.255 160h229.489l54.627-54.627c12.498-12.497 32.758-12.497 45.256 0 12.496 12.497 12.496 32.758 0 45.255L424 197.255V256h56c17.972 0 32.484 14.816 31.988 32.9zM257 0c-61.856 0-112 50.144-112 112h224C369 50.144 318.856 0 257 0z"]},ut={prefix:"fas",iconName:"building",icon:[448,512,[],"f1ad","M436 480h-20V24c0-13.255-10.745-24-24-24H56C42.745 0 32 10.745 32 24v456H12c-6.627 0-12 5.373-12 12v20h448v-20c0-6.627-5.373-12-12-12zM128 76c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40c0 6.627-5.373 12-12 12h-40c-6.627 0-12-5.373-12-12V76zm0 96c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40c0 6.627-5.373 12-12 12h-40c-6.627 0-12-5.373-12-12v-40zm52 148h-40c-6.627 0-12-5.373-12-12v-40c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40c0 6.627-5.373 12-12 12zm76 160h-64v-84c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v84zm64-172c0 6.627-5.373 12-12 12h-40c-6.627 0-12-5.373-12-12v-40c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40zm0-96c0 6.627-5.373 12-12 12h-40c-6.627 0-12-5.373-12-12v-40c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40zm0-96c0 6.627-5.373 12-12 12h-40c-6.627 0-12-5.373-12-12V76c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v40z"]},ht={prefix:"fas",iconName:"bullhorn",icon:[576,512,[],"f0a1","M576 240c0-23.63-12.95-44.04-32-55.12V32.01C544 23.26 537.02 0 512 0c-7.12 0-14.19 2.38-19.98 7.02l-85.03 68.03C364.28 109.19 310.66 128 256 128H64c-35.35 0-64 28.65-64 64v96c0 35.35 28.65 64 64 64h33.7c-1.39 10.48-2.18 21.14-2.18 32 0 39.77 9.26 77.35 25.56 110.94 5.19 10.69 16.52 17.06 28.4 17.06h74.28c26.05 0 41.69-29.84 25.9-50.56-16.4-21.52-26.15-48.36-26.15-77.44 0-11.11 1.62-21.79 4.41-32H256c54.66 0 108.28 18.81 150.98 52.95l85.03 68.03a32.023 32.023 0 0 0 19.98 7.02c24.92 0 32-22.78 32-32V295.13C563.05 284.04 576 263.63 576 240zm-96 141.42l-33.05-26.44C392.95 311.78 325.12 288 256 288v-96c69.12 0 136.95-23.78 190.95-66.98L480 98.58v282.84z"]},dt={prefix:"fas",iconName:"bullseye",icon:[496,512,[],"f140","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm0 432c-101.69 0-184-82.29-184-184 0-101.69 82.29-184 184-184 101.69 0 184 82.29 184 184 0 101.69-82.29 184-184 184zm0-312c-70.69 0-128 57.31-128 128s57.31 128 128 128 128-57.31 128-128-57.31-128-128-128zm0 192c-35.29 0-64-28.71-64-64s28.71-64 64-64 64 28.71 64 64-28.71 64-64 64z"]},pt={prefix:"fas",iconName:"burn",icon:[384,512,[],"f46a","M192 0C79.7 101.3 0 220.9 0 300.5 0 425 79 512 192 512s192-87 192-211.5c0-79.9-80.2-199.6-192-300.5zm0 448c-56.5 0-96-39-96-94.8 0-13.5 4.6-61.5 96-161.2 91.4 99.7 96 147.7 96 161.2 0 55.8-39.5 94.8-96 94.8z"]},gt={prefix:"fas",iconName:"bus",icon:[512,512,[],"f207","M488 128h-8V80c0-44.8-99.2-80-224-80S32 35.2 32 80v48h-8c-13.25 0-24 10.74-24 24v80c0 13.25 10.75 24 24 24h8v160c0 17.67 14.33 32 32 32v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h192v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h6.4c16 0 25.6-12.8 25.6-25.6V256h8c13.25 0 24-10.75 24-24v-80c0-13.26-10.75-24-24-24zM112 400c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm16-112c-17.67 0-32-14.33-32-32V128c0-17.67 14.33-32 32-32h256c17.67 0 32 14.33 32 32v128c0 17.67-14.33 32-32 32H128zm272 112c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},ft={prefix:"fas",iconName:"bus-alt",icon:[512,512,[],"f55e","M488 128h-8V80c0-44.8-99.2-80-224-80S32 35.2 32 80v48h-8c-13.25 0-24 10.74-24 24v80c0 13.25 10.75 24 24 24h8v160c0 17.67 14.33 32 32 32v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h192v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h6.4c16 0 25.6-12.8 25.6-25.6V256h8c13.25 0 24-10.75 24-24v-80c0-13.26-10.75-24-24-24zM160 72c0-4.42 3.58-8 8-8h176c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H168c-4.42 0-8-3.58-8-8V72zm-48 328c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm128-112H128c-17.67 0-32-14.33-32-32v-96c0-17.67 14.33-32 32-32h112v160zm32 0V128h112c17.67 0 32 14.33 32 32v96c0 17.67-14.33 32-32 32H272zm128 112c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},mt={prefix:"fas",iconName:"business-time",icon:[640,512,[],"f64a","M496 224c-79.59 0-144 64.41-144 144s64.41 144 144 144 144-64.41 144-144-64.41-144-144-144zm64 150.29c0 5.34-4.37 9.71-9.71 9.71h-60.57c-5.34 0-9.71-4.37-9.71-9.71v-76.57c0-5.34 4.37-9.71 9.71-9.71h12.57c5.34 0 9.71 4.37 9.71 9.71V352h38.29c5.34 0 9.71 4.37 9.71 9.71v12.58zM496 192c5.4 0 10.72.33 16 .81V144c0-25.6-22.4-48-48-48h-80V48c0-25.6-22.4-48-48-48H176c-25.6 0-48 22.4-48 48v48H48c-25.6 0-48 22.4-48 48v80h395.12c28.6-20.09 63.35-32 100.88-32zM320 96H192V64h128v32zm6.82 224H208c-8.84 0-16-7.16-16-16v-48H0v144c0 25.6 22.4 48 48 48h291.43C327.1 423.96 320 396.82 320 368c0-16.66 2.48-32.72 6.82-48z"]},vt={prefix:"fas",iconName:"calculator",icon:[448,512,[],"f1ec","M400 0H48C22.4 0 0 22.4 0 48v416c0 25.6 22.4 48 48 48h352c25.6 0 48-22.4 48-48V48c0-25.6-22.4-48-48-48zM128 435.2c0 6.4-6.4 12.8-12.8 12.8H76.8c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4zm0-128c0 6.4-6.4 12.8-12.8 12.8H76.8c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4zm128 128c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4zm0-128c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4zm128 128c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8V268.8c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v166.4zm0-256c0 6.4-6.4 12.8-12.8 12.8H76.8c-6.4 0-12.8-6.4-12.8-12.8V76.8C64 70.4 70.4 64 76.8 64h294.4c6.4 0 12.8 6.4 12.8 12.8v102.4z"]},Ct={prefix:"fas",iconName:"calendar",icon:[448,512,[],"f133","M12 192h424c6.6 0 12 5.4 12 12v260c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V204c0-6.6 5.4-12 12-12zm436-44v-36c0-26.5-21.5-48-48-48h-48V12c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12v52H160V12c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12v52H48C21.5 64 0 85.5 0 112v36c0 6.6 5.4 12 12 12h424c6.6 0 12-5.4 12-12z"]},yt={prefix:"fas",iconName:"calendar-alt",icon:[448,512,[],"f073","M0 464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V192H0v272zm320-196c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40zm0 128c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40zM192 268c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40zm0 128c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40zM64 268c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H76c-6.6 0-12-5.4-12-12v-40zm0 128c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H76c-6.6 0-12-5.4-12-12v-40zM400 64h-48V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H160V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H48C21.5 64 0 85.5 0 112v48h448v-48c0-26.5-21.5-48-48-48z"]},wt={prefix:"fas",iconName:"calendar-check",icon:[448,512,[],"f274","M436 160H12c-6.627 0-12-5.373-12-12v-36c0-26.51 21.49-48 48-48h48V12c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v52h128V12c0-6.627 5.373-12 12-12h40c6.627 0 12 5.373 12 12v52h48c26.51 0 48 21.49 48 48v36c0 6.627-5.373 12-12 12zM12 192h424c6.627 0 12 5.373 12 12v260c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V204c0-6.627 5.373-12 12-12zm333.296 95.947l-28.169-28.398c-4.667-4.705-12.265-4.736-16.97-.068L194.12 364.665l-45.98-46.352c-4.667-4.705-12.266-4.736-16.971-.068l-28.397 28.17c-4.705 4.667-4.736 12.265-.068 16.97l82.601 83.269c4.667 4.705 12.265 4.736 16.97.068l142.953-141.805c4.705-4.667 4.736-12.265.068-16.97z"]},St={prefix:"fas",iconName:"calendar-day",icon:[448,512,[],"f783","M0 464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V192H0v272zm64-192c0-8.8 7.2-16 16-16h96c8.8 0 16 7.2 16 16v96c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16v-96zM400 64h-48V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H160V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H48C21.5 64 0 85.5 0 112v48h448v-48c0-26.5-21.5-48-48-48z"]},bt={prefix:"fas",iconName:"calendar-minus",icon:[448,512,[],"f272","M436 160H12c-6.6 0-12-5.4-12-12v-36c0-26.5 21.5-48 48-48h48V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h128V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h48c26.5 0 48 21.5 48 48v36c0 6.6-5.4 12-12 12zM12 192h424c6.6 0 12 5.4 12 12v260c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V204c0-6.6 5.4-12 12-12zm304 192c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12H132c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h184z"]},Et={prefix:"fas",iconName:"calendar-plus",icon:[448,512,[],"f271","M436 160H12c-6.6 0-12-5.4-12-12v-36c0-26.5 21.5-48 48-48h48V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h128V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h48c26.5 0 48 21.5 48 48v36c0 6.6-5.4 12-12 12zM12 192h424c6.6 0 12 5.4 12 12v260c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V204c0-6.6 5.4-12 12-12zm316 140c0-6.6-5.4-12-12-12h-60v-60c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12v60h-60c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h60v60c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-60h60c6.6 0 12-5.4 12-12v-40z"]},At={prefix:"fas",iconName:"calendar-times",icon:[448,512,[],"f273","M436 160H12c-6.6 0-12-5.4-12-12v-36c0-26.5 21.5-48 48-48h48V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h128V12c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v52h48c26.5 0 48 21.5 48 48v36c0 6.6-5.4 12-12 12zM12 192h424c6.6 0 12 5.4 12 12v260c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V204c0-6.6 5.4-12 12-12zm257.3 160l48.1-48.1c4.7-4.7 4.7-12.3 0-17l-28.3-28.3c-4.7-4.7-12.3-4.7-17 0L224 306.7l-48.1-48.1c-4.7-4.7-12.3-4.7-17 0l-28.3 28.3c-4.7 4.7-4.7 12.3 0 17l48.1 48.1-48.1 48.1c-4.7 4.7-4.7 12.3 0 17l28.3 28.3c4.7 4.7 12.3 4.7 17 0l48.1-48.1 48.1 48.1c4.7 4.7 12.3 4.7 17 0l28.3-28.3c4.7-4.7 4.7-12.3 0-17L269.3 352z"]},Tt={prefix:"fas",iconName:"calendar-week",icon:[448,512,[],"f784","M0 464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V192H0v272zm64-192c0-8.8 7.2-16 16-16h288c8.8 0 16 7.2 16 16v64c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16v-64zM400 64h-48V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H160V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48H48C21.5 64 0 85.5 0 112v48h448v-48c0-26.5-21.5-48-48-48z"]},Mt={prefix:"fas",iconName:"camera",icon:[512,512,[],"f030","M512 144v288c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V144c0-26.5 21.5-48 48-48h88l12.3-32.9c7-18.7 24.9-31.1 44.9-31.1h125.5c20 0 37.9 12.4 44.9 31.1L376 96h88c26.5 0 48 21.5 48 48zM376 288c0-66.2-53.8-120-120-120s-120 53.8-120 120 53.8 120 120 120 120-53.8 120-120zm-32 0c0 48.5-39.5 88-88 88s-88-39.5-88-88 39.5-88 88-88 88 39.5 88 88z"]},Rt={prefix:"fas",iconName:"camera-retro",icon:[512,512,[],"f083","M48 32C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48H48zm0 32h106c3.3 0 6 2.7 6 6v20c0 3.3-2.7 6-6 6H38c-3.3 0-6-2.7-6-6V80c0-8.8 7.2-16 16-16zm426 96H38c-3.3 0-6-2.7-6-6v-36c0-3.3 2.7-6 6-6h138l30.2-45.3c1.1-1.7 3-2.7 5-2.7H464c8.8 0 16 7.2 16 16v74c0 3.3-2.7 6-6 6zM256 424c-66.2 0-120-53.8-120-120s53.8-120 120-120 120 53.8 120 120-53.8 120-120 120zm0-208c-48.5 0-88 39.5-88 88s39.5 88 88 88 88-39.5 88-88-39.5-88-88-88zm-48 104c-8.8 0-16-7.2-16-16 0-35.3 28.7-64 64-64 8.8 0 16 7.2 16 16s-7.2 16-16 16c-17.6 0-32 14.4-32 32 0 8.8-7.2 16-16 16z"]},_t={prefix:"fas",iconName:"campground",icon:[640,512,[],"f6bb","M624 448h-24.68L359.54 117.75l53.41-73.55c5.19-7.15 3.61-17.16-3.54-22.35l-25.9-18.79c-7.15-5.19-17.15-3.61-22.35 3.55L320 63.3 278.83 6.6c-5.19-7.15-15.2-8.74-22.35-3.55l-25.88 18.8c-7.15 5.19-8.74 15.2-3.54 22.35l53.41 73.55L40.68 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h608c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM320 288l116.36 160H203.64L320 288z"]},Pt={prefix:"fas",iconName:"candy-cane",icon:[512,512,[],"f786","M497.5 92C469.6 33.1 411.8 0 352.4 0c-27.9 0-56.2 7.3-81.8 22.6L243.1 39c-15.2 9.1-20.1 28.7-11 43.9l32.8 54.9c6 10 16.6 15.6 27.5 15.6 5.6 0 11.2-1.5 16.4-4.5l27.5-16.4c5.1-3.1 10.8-4.5 16.4-4.5 10.9 0 21.5 5.6 27.5 15.6 9.1 15.1 4.1 34.8-11 43.9L15.6 397.6c-15.2 9.1-20.1 28.7-11 43.9l32.8 54.9c6 10 16.6 15.6 27.5 15.6 5.6 0 11.2-1.5 16.4-4.5L428.6 301c71.7-42.9 104.6-133.5 68.9-209zm-177.7 13l-2.5 1.5L296.8 45c9.7-4.7 19.8-8.1 30.3-10.2l20.6 61.8c-9.8.8-19.4 3.3-27.9 8.4zM145.9 431.8l-60.5-38.5 30.8-18.3 60.5 38.5-30.8 18.3zm107.5-63.9l-60.5-38.5 30.8-18.3 60.5 38.5-30.8 18.3zM364.3 302l-60.5-38.5 30.8-18.3 60.5 38.5-30.8 18.3zm20.4-197.3l46-46c8.4 6.5 16 14.1 22.6 22.6L407.6 127c-5.7-9.3-13.7-16.9-22.9-22.3zm82.1 107.8l-59.5-19.8c3.2-5.3 5.8-10.9 7.4-17.1 1.1-4.5 1.7-9.1 1.8-13.6l60.4 20.1c-2.1 10.4-5.5 20.6-10.1 30.4z"]},xt={prefix:"fas",iconName:"cannabis",icon:[512,512,[],"f55f","M503.47 360.25c-1.56-.82-32.39-16.89-76.78-25.81 64.25-75.12 84.05-161.67 84.93-165.64 1.18-5.33-.44-10.9-4.3-14.77-3.03-3.04-7.12-4.7-11.32-4.7-1.14 0-2.29.12-3.44.38-3.88.85-86.54 19.59-160.58 79.76.01-1.46.01-2.93.01-4.4 0-118.79-59.98-213.72-62.53-217.7A15.973 15.973 0 0 0 256 0c-5.45 0-10.53 2.78-13.47 7.37-2.55 3.98-62.53 98.91-62.53 217.7 0 1.47.01 2.94.01 4.4-74.03-60.16-156.69-78.9-160.58-79.76-1.14-.25-2.29-.38-3.44-.38-4.2 0-8.29 1.66-11.32 4.7A15.986 15.986 0 0 0 .38 168.8c.88 3.97 20.68 90.52 84.93 165.64-44.39 8.92-75.21 24.99-76.78 25.81a16.003 16.003 0 0 0-.02 28.29c2.45 1.29 60.76 31.72 133.49 31.72 6.14 0 11.96-.1 17.5-.31-11.37 22.23-16.52 38.31-16.81 39.22-1.8 5.68-.29 11.89 3.91 16.11a16.019 16.019 0 0 0 16.1 3.99c1.83-.57 37.72-11.99 77.3-39.29V504c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8v-64.01c39.58 27.3 75.47 38.71 77.3 39.29a16.019 16.019 0 0 0 16.1-3.99c4.2-4.22 5.71-10.43 3.91-16.11-.29-.91-5.45-16.99-16.81-39.22 5.54.21 11.37.31 17.5.31 72.72 0 131.04-30.43 133.49-31.72 5.24-2.78 8.52-8.22 8.51-14.15-.01-5.94-3.29-11.39-8.53-14.15z"]},Dt={prefix:"fas",iconName:"capsules",icon:[576,512,[],"f46b","M555.3 300.1L424.2 112.8C401.9 81 366.4 64 330.4 64c-22.6 0-45.5 6.7-65.5 20.7-19.7 13.8-33.7 32.8-41.5 53.8C220.5 79.2 172 32 112 32 50.1 32 0 82.1 0 144v224c0 61.9 50.1 112 112 112s112-50.1 112-112V218.9c3.3 8.6 7.3 17.1 12.8 25L368 431.2c22.2 31.8 57.7 48.8 93.8 48.8 22.7 0 45.5-6.7 65.5-20.7 51.7-36.2 64.2-107.5 28-159.2zM160 256H64V144c0-26.5 21.5-48 48-48s48 21.5 48 48v112zm194.8 44.9l-65.6-93.7c-7.7-11-10.7-24.4-8.3-37.6 2.3-13.2 9.7-24.8 20.7-32.5 8.5-6 18.5-9.1 28.8-9.1 16.5 0 31.9 8 41.3 21.5l65.6 93.7-82.5 57.7z"]},It={prefix:"fas",iconName:"car",icon:[512,512,[],"f1b9","M499.99 176h-59.87l-16.64-41.6C406.38 91.63 365.57 64 319.5 64h-127c-46.06 0-86.88 27.63-103.99 70.4L71.87 176H12.01C4.2 176-1.53 183.34.37 190.91l6 24C7.7 220.25 12.5 224 18.01 224h20.07C24.65 235.73 16 252.78 16 272v48c0 16.12 6.16 30.67 16 41.93V416c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h256v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-54.07c9.84-11.25 16-25.8 16-41.93v-48c0-19.22-8.65-36.27-22.07-48H494c5.51 0 10.31-3.75 11.64-9.09l6-24c1.89-7.57-3.84-14.91-11.65-14.91zm-352.06-17.83c7.29-18.22 24.94-30.17 44.57-30.17h127c19.63 0 37.28 11.95 44.57 30.17L384 208H128l19.93-49.83zM96 319.8c-19.2 0-32-12.76-32-31.9S76.8 256 96 256s48 28.71 48 47.85-28.8 15.95-48 15.95zm320 0c-19.2 0-48 3.19-48-15.95S396.8 256 416 256s32 12.76 32 31.9-12.8 31.9-32 31.9z"]},Lt={prefix:"fas",iconName:"car-alt",icon:[480,512,[],"f5de","M438.66 212.33l-11.24-28.1-19.93-49.83C390.38 91.63 349.57 64 303.5 64h-127c-46.06 0-86.88 27.63-103.99 70.4l-19.93 49.83-11.24 28.1C17.22 221.5 0 244.66 0 272v48c0 16.12 6.16 30.67 16 41.93V416c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h256v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-54.07c9.84-11.25 16-25.8 16-41.93v-48c0-27.34-17.22-50.5-41.34-59.67zm-306.73-54.16c7.29-18.22 24.94-30.17 44.57-30.17h127c19.63 0 37.28 11.95 44.57 30.17L368 208H112l19.93-49.83zM80 319.8c-19.2 0-32-12.76-32-31.9S60.8 256 80 256s48 28.71 48 47.85-28.8 15.95-48 15.95zm320 0c-19.2 0-48 3.19-48-15.95S380.8 256 400 256s32 12.76 32 31.9-12.8 31.9-32 31.9z"]},Nt={prefix:"fas",iconName:"car-battery",icon:[512,512,[],"f5df","M480 128h-32V80c0-8.84-7.16-16-16-16h-96c-8.84 0-16 7.16-16 16v48H192V80c0-8.84-7.16-16-16-16H80c-8.84 0-16 7.16-16 16v48H32c-17.67 0-32 14.33-32 32v256c0 17.67 14.33 32 32 32h448c17.67 0 32-14.33 32-32V160c0-17.67-14.33-32-32-32zM192 264c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h112c4.42 0 8 3.58 8 8v16zm256 0c0 4.42-3.58 8-8 8h-40v40c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-40h-40c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h40v-40c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v40h40c4.42 0 8 3.58 8 8v16z"]},Ot={prefix:"fas",iconName:"car-crash",icon:[640,512,[],"f5e1","M143.25 220.81l-12.42 46.37c-3.01 11.25-3.63 22.89-2.41 34.39l-35.2 28.98c-6.57 5.41-16.31-.43-14.62-8.77l15.44-76.68c1.06-5.26-2.66-10.28-8-10.79l-77.86-7.55c-8.47-.82-11.23-11.83-4.14-16.54l65.15-43.3c4.46-2.97 5.38-9.15 1.98-13.29L21.46 93.22c-5.41-6.57.43-16.3 8.78-14.62l76.68 15.44c5.26 1.06 10.28-2.66 10.8-8l7.55-77.86c.82-8.48 11.83-11.23 16.55-4.14l43.3 65.14c2.97 4.46 9.15 5.38 13.29 1.98l60.4-49.71c6.57-5.41 16.3.43 14.62 8.77L262.1 86.38c-2.71 3.05-5.43 6.09-7.91 9.4l-32.15 42.97-10.71 14.32c-32.73 8.76-59.18 34.53-68.08 67.74zm494.57 132.51l-12.42 46.36c-3.13 11.68-9.38 21.61-17.55 29.36a66.876 66.876 0 0 1-8.76 7l-13.99 52.23c-1.14 4.27-3.1 8.1-5.65 11.38-7.67 9.84-20.74 14.68-33.54 11.25L515 502.62c-17.07-4.57-27.2-22.12-22.63-39.19l8.28-30.91-247.28-66.26-8.28 30.91c-4.57 17.07-22.12 27.2-39.19 22.63l-30.91-8.28c-12.8-3.43-21.7-14.16-23.42-26.51-.57-4.12-.35-8.42.79-12.68l13.99-52.23a66.62 66.62 0 0 1-4.09-10.45c-3.2-10.79-3.65-22.52-.52-34.2l12.42-46.37c5.31-19.8 19.36-34.83 36.89-42.21a64.336 64.336 0 0 1 18.49-4.72l18.13-24.23 32.15-42.97c3.45-4.61 7.19-8.9 11.2-12.84 8-7.89 17.03-14.44 26.74-19.51 4.86-2.54 9.89-4.71 15.05-6.49 10.33-3.58 21.19-5.63 32.24-6.04 11.05-.41 22.31.82 33.43 3.8l122.68 32.87c11.12 2.98 21.48 7.54 30.85 13.43a111.11 111.11 0 0 1 34.69 34.5c8.82 13.88 14.64 29.84 16.68 46.99l6.36 53.29 3.59 30.05a64.49 64.49 0 0 1 22.74 29.93c4.39 11.88 5.29 25.19 1.75 38.39zM255.58 234.34c-18.55-4.97-34.21 4.04-39.17 22.53-4.96 18.49 4.11 34.12 22.65 39.09 18.55 4.97 45.54 15.51 50.49-2.98 4.96-18.49-15.43-53.67-33.97-58.64zm290.61 28.17l-6.36-53.29c-.58-4.87-1.89-9.53-3.82-13.86-5.8-12.99-17.2-23.01-31.42-26.82l-122.68-32.87a48.008 48.008 0 0 0-50.86 17.61l-32.15 42.97 172 46.08 75.29 20.18zm18.49 54.65c-18.55-4.97-53.8 15.31-58.75 33.79-4.95 18.49 23.69 22.86 42.24 27.83 18.55 4.97 34.21-4.04 39.17-22.53 4.95-18.48-4.11-34.12-22.66-39.09z"]},Ft={prefix:"fas",iconName:"car-side",icon:[640,512,[],"f5e4","M544 192h-16L419.22 56.02A64.025 64.025 0 0 0 369.24 32H155.33c-26.17 0-49.7 15.93-59.42 40.23L48 194.26C20.44 201.4 0 226.21 0 256v112c0 8.84 7.16 16 16 16h48c0 53.02 42.98 96 96 96s96-42.98 96-96h128c0 53.02 42.98 96 96 96s96-42.98 96-96h48c8.84 0 16-7.16 16-16v-80c0-53.02-42.98-96-96-96zM160 432c-26.47 0-48-21.53-48-48s21.53-48 48-48 48 21.53 48 48-21.53 48-48 48zm72-240H116.93l38.4-96H232v96zm48 0V96h89.24l76.8 96H280zm200 240c-26.47 0-48-21.53-48-48s21.53-48 48-48 48 21.53 48 48-21.53 48-48 48z"]},kt={prefix:"fas",iconName:"caravan",icon:[640,512,[],"f8ff","M416,208a16,16,0,1,0,16,16A16,16,0,0,0,416,208ZM624,320H576V160A160,160,0,0,0,416,0H64A64,64,0,0,0,0,64V320a64,64,0,0,0,64,64H96a96,96,0,0,0,192,0H624a16,16,0,0,0,16-16V336A16,16,0,0,0,624,320ZM192,432a48,48,0,1,1,48-48A48.05,48.05,0,0,1,192,432Zm64-240a32,32,0,0,1-32,32H96a32,32,0,0,1-32-32V128A32,32,0,0,1,96,96H224a32,32,0,0,1,32,32ZM448,320H320V128a32,32,0,0,1,32-32h64a32,32,0,0,1,32,32Z"]},Gt={prefix:"fas",iconName:"caret-down",icon:[320,512,[],"f0d7","M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z"]},Vt={prefix:"fas",iconName:"caret-left",icon:[192,512,[],"f0d9","M192 127.338v257.324c0 17.818-21.543 26.741-34.142 14.142L29.196 270.142c-7.81-7.81-7.81-20.474 0-28.284l128.662-128.662c12.599-12.6 34.142-3.676 34.142 14.142z"]},Ht={prefix:"fas",iconName:"caret-right",icon:[192,512,[],"f0da","M0 384.662V127.338c0-17.818 21.543-26.741 34.142-14.142l128.662 128.662c7.81 7.81 7.81 20.474 0 28.284L34.142 398.804C21.543 411.404 0 402.48 0 384.662z"]},Bt={prefix:"fas",iconName:"caret-square-down",icon:[448,512,[],"f150","M448 80v352c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V80c0-26.5 21.5-48 48-48h352c26.5 0 48 21.5 48 48zM92.5 220.5l123 123c4.7 4.7 12.3 4.7 17 0l123-123c7.6-7.6 2.2-20.5-8.5-20.5H101c-10.7 0-16.1 12.9-8.5 20.5z"]},zt={prefix:"fas",iconName:"caret-square-left",icon:[448,512,[],"f191","M400 480H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48v352c0 26.51-21.49 48-48 48zM259.515 124.485l-123.03 123.03c-4.686 4.686-4.686 12.284 0 16.971l123.029 123.029c7.56 7.56 20.485 2.206 20.485-8.485V132.971c.001-10.691-12.925-16.045-20.484-8.486z"]},Ut={prefix:"fas",iconName:"caret-square-right",icon:[448,512,[],"f152","M48 32h352c26.51 0 48 21.49 48 48v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48zm140.485 355.515l123.029-123.029c4.686-4.686 4.686-12.284 0-16.971l-123.029-123.03c-7.56-7.56-20.485-2.206-20.485 8.485v246.059c0 10.691 12.926 16.045 20.485 8.486z"]},Wt={prefix:"fas",iconName:"caret-square-up",icon:[448,512,[],"f151","M0 432V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48zm355.515-140.485l-123.03-123.03c-4.686-4.686-12.284-4.686-16.971 0L92.485 291.515c-7.56 7.56-2.206 20.485 8.485 20.485h246.059c10.691 0 16.045-12.926 8.486-20.485z"]},jt={prefix:"fas",iconName:"caret-up",icon:[320,512,[],"f0d8","M288.662 352H31.338c-17.818 0-26.741-21.543-14.142-34.142l128.662-128.662c7.81-7.81 20.474-7.81 28.284 0l128.662 128.662c12.6 12.599 3.676 34.142-14.142 34.142z"]},Kt={prefix:"fas",iconName:"carrot",icon:[512,512,[],"f787","M298.2 156.6c-52.7-25.7-114.5-10.5-150.2 32.8l55.2 55.2c6.3 6.3 6.3 16.4 0 22.6-3.1 3.1-7.2 4.7-11.3 4.7s-8.2-1.6-11.3-4.7L130.4 217 2.3 479.7c-2.9 6-3.1 13.3 0 19.7 5.4 11.1 18.9 15.7 30 10.3l133.6-65.2-49.2-49.2c-6.3-6.2-6.3-16.4 0-22.6 6.3-6.2 16.4-6.2 22.6 0l57 57 102-49.8c24-11.7 44.5-31.3 57.1-57.1 30.1-61.7 4.5-136.1-57.2-166.2zm92.1-34.9C409.8 81 399.7 32.9 360 0c-50.3 41.7-52.5 107.5-7.9 151.9l8 8c44.4 44.6 110.3 42.4 151.9-7.9-32.9-39.7-81-49.8-121.7-30.3z"]},$t={prefix:"fas",iconName:"cart-arrow-down",icon:[576,512,[],"f218","M504.717 320H211.572l6.545 32h268.418c15.401 0 26.816 14.301 23.403 29.319l-5.517 24.276C523.112 414.668 536 433.828 536 456c0 31.202-25.519 56.444-56.824 55.994-29.823-.429-54.35-24.631-55.155-54.447-.44-16.287 6.085-31.049 16.803-41.548H231.176C241.553 426.165 248 440.326 248 456c0 31.813-26.528 57.431-58.67 55.938-28.54-1.325-51.751-24.385-53.251-52.917-1.158-22.034 10.436-41.455 28.051-51.586L93.883 64H24C10.745 64 0 53.255 0 40V24C0 10.745 10.745 0 24 0h102.529c11.401 0 21.228 8.021 23.513 19.19L159.208 64H551.99c15.401 0 26.816 14.301 23.403 29.319l-47.273 208C525.637 312.246 515.923 320 504.717 320zM403.029 192H360v-60c0-6.627-5.373-12-12-12h-24c-6.627 0-12 5.373-12 12v60h-43.029c-10.691 0-16.045 12.926-8.485 20.485l67.029 67.029c4.686 4.686 12.284 4.686 16.971 0l67.029-67.029c7.559-7.559 2.205-20.485-8.486-20.485z"]},qt={prefix:"fas",iconName:"cart-plus",icon:[576,512,[],"f217","M504.717 320H211.572l6.545 32h268.418c15.401 0 26.816 14.301 23.403 29.319l-5.517 24.276C523.112 414.668 536 433.828 536 456c0 31.202-25.519 56.444-56.824 55.994-29.823-.429-54.35-24.631-55.155-54.447-.44-16.287 6.085-31.049 16.803-41.548H231.176C241.553 426.165 248 440.326 248 456c0 31.813-26.528 57.431-58.67 55.938-28.54-1.325-51.751-24.385-53.251-52.917-1.158-22.034 10.436-41.455 28.051-51.586L93.883 64H24C10.745 64 0 53.255 0 40V24C0 10.745 10.745 0 24 0h102.529c11.401 0 21.228 8.021 23.513 19.19L159.208 64H551.99c15.401 0 26.816 14.301 23.403 29.319l-47.273 208C525.637 312.246 515.923 320 504.717 320zM408 168h-48v-40c0-8.837-7.163-16-16-16h-16c-8.837 0-16 7.163-16 16v40h-48c-8.837 0-16 7.163-16 16v16c0 8.837 7.163 16 16 16h48v40c0 8.837 7.163 16 16 16h16c8.837 0 16-7.163 16-16v-40h48c8.837 0 16-7.163 16-16v-16c0-8.837-7.163-16-16-16z"]},Yt={prefix:"fas",iconName:"cash-register",icon:[512,512,[],"f788","M511.1 378.8l-26.7-160c-2.6-15.4-15.9-26.7-31.6-26.7H208v-64h96c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16H48c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16h96v64H59.1c-15.6 0-29 11.3-31.6 26.7L.8 378.7c-.6 3.5-.9 7-.9 10.5V480c0 17.7 14.3 32 32 32h448c17.7 0 32-14.3 32-32v-90.7c.1-3.5-.2-7-.8-10.5zM280 248c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v16c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16v-16zm-32 64h16c8.8 0 16 7.2 16 16v16c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16v-16c0-8.8 7.2-16 16-16zm-32-80c8.8 0 16 7.2 16 16v16c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16v-16c0-8.8 7.2-16 16-16h16zM80 80V48h192v32H80zm40 200h-16c-8.8 0-16-7.2-16-16v-16c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v16c0 8.8-7.2 16-16 16zm16 64v-16c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v16c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16zm216 112c0 4.4-3.6 8-8 8H168c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h176c4.4 0 8 3.6 8 8v16zm24-112c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16v-16c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v16zm48-80c0 8.8-7.2 16-16 16h-16c-8.8 0-16-7.2-16-16v-16c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v16z"]},Qt={prefix:"fas",iconName:"cat",icon:[512,512,[],"f6be","M290.59 192c-20.18 0-106.82 1.98-162.59 85.95V192c0-52.94-43.06-96-96-96-17.67 0-32 14.33-32 32s14.33 32 32 32c17.64 0 32 14.36 32 32v256c0 35.3 28.7 64 64 64h176c8.84 0 16-7.16 16-16v-16c0-17.67-14.33-32-32-32h-32l128-96v144c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16V289.86c-10.29 2.67-20.89 4.54-32 4.54-61.81 0-113.52-44.05-125.41-102.4zM448 96h-64l-64-64v134.4c0 53.02 42.98 96 96 96s96-42.98 96-96V32l-64 64zm-72 80c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16zm80 0c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16z"]},Xt={prefix:"fas",iconName:"certificate",icon:[512,512,[],"f0a3","M458.622 255.92l45.985-45.005c13.708-12.977 7.316-36.039-10.664-40.339l-62.65-15.99 17.661-62.015c4.991-17.838-11.829-34.663-29.661-29.671l-61.994 17.667-15.984-62.671C337.085.197 313.765-6.276 300.99 7.228L256 53.57 211.011 7.229c-12.63-13.351-36.047-7.234-40.325 10.668l-15.984 62.671-61.995-17.667C74.87 57.907 58.056 74.738 63.046 92.572l17.661 62.015-62.65 15.99C.069 174.878-6.31 197.944 7.392 210.915l45.985 45.005-45.985 45.004c-13.708 12.977-7.316 36.039 10.664 40.339l62.65 15.99-17.661 62.015c-4.991 17.838 11.829 34.663 29.661 29.671l61.994-17.667 15.984 62.671c4.439 18.575 27.696 24.018 40.325 10.668L256 458.61l44.989 46.001c12.5 13.488 35.987 7.486 40.325-10.668l15.984-62.671 61.994 17.667c17.836 4.994 34.651-11.837 29.661-29.671l-17.661-62.015 62.65-15.99c17.987-4.302 24.366-27.367 10.664-40.339l-45.984-45.004z"]},Zt={prefix:"fas",iconName:"chair",icon:[448,512,[],"f6c0","M112 128c0-29.5 16.2-55 40-68.9V256h48V48h48v208h48V59.1c23.8 13.9 40 39.4 40 68.9v128h48V128C384 57.3 326.7 0 256 0h-64C121.3 0 64 57.3 64 128v128h48zm334.3 213.9l-10.7-32c-4.4-13.1-16.6-21.9-30.4-21.9H42.7c-13.8 0-26 8.8-30.4 21.9l-10.7 32C-5.2 362.6 10.2 384 32 384v112c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V384h256v112c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V384c21.8 0 37.2-21.4 30.3-42.1z"]},Jt={prefix:"fas",iconName:"chalkboard",icon:[640,512,[],"f51b","M96 64h448v352h64V40c0-22.06-17.94-40-40-40H72C49.94 0 32 17.94 32 40v376h64V64zm528 384H480v-64H288v64H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h608c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},ei={prefix:"fas",iconName:"chalkboard-teacher",icon:[640,512,[],"f51c","M208 352c-2.39 0-4.78.35-7.06 1.09C187.98 357.3 174.35 360 160 360c-14.35 0-27.98-2.7-40.95-6.91-2.28-.74-4.66-1.09-7.05-1.09C49.94 352-.33 402.48 0 464.62.14 490.88 21.73 512 48 512h224c26.27 0 47.86-21.12 48-47.38.33-62.14-49.94-112.62-112-112.62zm-48-32c53.02 0 96-42.98 96-96s-42.98-96-96-96-96 42.98-96 96 42.98 96 96 96zM592 0H208c-26.47 0-48 22.25-48 49.59V96c23.42 0 45.1 6.78 64 17.8V64h352v288h-64v-64H384v64h-76.24c19.1 16.69 33.12 38.73 39.69 64H592c26.47 0 48-22.25 48-49.59V49.59C640 22.25 618.47 0 592 0z"]},ti={prefix:"fas",iconName:"charging-station",icon:[576,512,[],"f5e7","M336 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h320c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm208-320V80c0-8.84-7.16-16-16-16s-16 7.16-16 16v48h-32V80c0-8.84-7.16-16-16-16s-16 7.16-16 16v48h-16c-8.84 0-16 7.16-16 16v32c0 35.76 23.62 65.69 56 75.93v118.49c0 13.95-9.5 26.92-23.26 29.19C431.22 402.5 416 388.99 416 372v-28c0-48.6-39.4-88-88-88h-8V64c0-35.35-28.65-64-64-64H96C60.65 0 32 28.65 32 64v352h288V304h8c22.09 0 40 17.91 40 40v24.61c0 39.67 28.92 75.16 68.41 79.01C481.71 452.05 520 416.41 520 372V251.93c32.38-10.24 56-40.17 56-75.93v-32c0-8.84-7.16-16-16-16h-16zm-283.91 47.76l-93.7 139c-2.2 3.33-6.21 5.24-10.39 5.24-7.67 0-13.47-6.28-11.67-12.92L167.35 224H108c-7.25 0-12.85-5.59-11.89-11.89l16-107C112.9 99.9 117.98 96 124 96h68c7.88 0 13.62 6.54 11.6 13.21L192 160h57.7c9.24 0 15.01 8.78 10.39 15.76z"]},ii={prefix:"fas",iconName:"chart-area",icon:[512,512,[],"f1fe","M500 384c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H12c-6.6 0-12-5.4-12-12V76c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v308h436zM372.7 159.5L288 216l-85.3-113.7c-5.1-6.8-15.5-6.3-19.9 1L96 248v104h384l-89.9-187.8c-3.2-6.5-11.4-8.7-17.4-4.7z"]},ri={prefix:"fas",iconName:"chart-bar",icon:[512,512,[],"f080","M332.8 320h38.4c6.4 0 12.8-6.4 12.8-12.8V172.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h38.4c6.4 0 12.8-6.4 12.8-12.8V76.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-288 0h38.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h38.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-38.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zM496 384H64V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},ni={prefix:"fas",iconName:"chart-line",icon:[512,512,[],"f201","M496 384H64V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM464 96H345.94c-21.38 0-32.09 25.85-16.97 40.97l32.4 32.4L288 242.75l-73.37-73.37c-12.5-12.5-32.76-12.5-45.25 0l-68.69 68.69c-6.25 6.25-6.25 16.38 0 22.63l22.62 22.62c6.25 6.25 16.38 6.25 22.63 0L192 237.25l73.37 73.37c12.5 12.5 32.76 12.5 45.25 0l96-96 32.4 32.4c15.12 15.12 40.97 4.41 40.97-16.97V112c.01-8.84-7.15-16-15.99-16z"]},si={prefix:"fas",iconName:"chart-pie",icon:[544,512,[],"f200","M527.79 288H290.5l158.03 158.03c6.04 6.04 15.98 6.53 22.19.68 38.7-36.46 65.32-85.61 73.13-140.86 1.34-9.46-6.51-17.85-16.06-17.85zm-15.83-64.8C503.72 103.74 408.26 8.28 288.8.04 279.68-.59 272 7.1 272 16.24V240h223.77c9.14 0 16.82-7.68 16.19-16.8zM224 288V50.71c0-9.55-8.39-17.4-17.84-16.06C86.99 51.49-4.1 155.6.14 280.37 4.5 408.51 114.83 513.59 243.03 511.98c50.4-.63 96.97-16.87 135.26-44.03 7.9-5.6 8.42-17.23 1.57-24.08L224 288z"]},oi={prefix:"fas",iconName:"check",icon:[512,512,[],"f00c","M173.898 439.404l-166.4-166.4c-9.997-9.997-9.997-26.206 0-36.204l36.203-36.204c9.997-9.998 26.207-9.998 36.204 0L192 312.69 432.095 72.596c9.997-9.997 26.207-9.997 36.204 0l36.203 36.204c9.997 9.997 9.997 26.206 0 36.204l-294.4 294.401c-9.998 9.997-26.207 9.997-36.204-.001z"]},ai={prefix:"fas",iconName:"check-circle",icon:[512,512,[],"f058","M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM227.314 387.314l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.249-16.379-6.249-22.628 0L216 308.118l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.249 16.379 6.249 22.628.001z"]},li={prefix:"fas",iconName:"check-double",icon:[512,512,[],"f560","M505 174.8l-39.6-39.6c-9.4-9.4-24.6-9.4-33.9 0L192 374.7 80.6 263.2c-9.4-9.4-24.6-9.4-33.9 0L7 302.9c-9.4 9.4-9.4 24.6 0 34L175 505c9.4 9.4 24.6 9.4 33.9 0l296-296.2c9.4-9.5 9.4-24.7.1-34zm-324.3 106c6.2 6.3 16.4 6.3 22.6 0l208-208.2c6.2-6.3 6.2-16.4 0-22.6L366.1 4.7c-6.2-6.3-16.4-6.3-22.6 0L192 156.2l-55.4-55.5c-6.2-6.3-16.4-6.3-22.6 0L68.7 146c-6.2 6.3-6.2 16.4 0 22.6l112 112.2z"]},ci={prefix:"fas",iconName:"check-square",icon:[448,512,[],"f14a","M400 480H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48v352c0 26.51-21.49 48-48 48zm-204.686-98.059l184-184c6.248-6.248 6.248-16.379 0-22.627l-22.627-22.627c-6.248-6.248-16.379-6.249-22.628 0L184 302.745l-70.059-70.059c-6.248-6.248-16.379-6.248-22.628 0l-22.627 22.627c-6.248 6.248-6.248 16.379 0 22.627l104 104c6.249 6.25 16.379 6.25 22.628.001z"]},ui={prefix:"fas",iconName:"cheese",icon:[512,512,[],"f7ef","M0 288v160a32 32 0 0 0 32 32h448a32 32 0 0 0 32-32V288zM299.83 32a32 32 0 0 0-21.13 7L0 256h512c0-119.89-94-217.8-212.17-224z"]},hi={prefix:"fas",iconName:"chess",icon:[512,512,[],"f439","M74 208H64a16 16 0 0 0-16 16v16a16 16 0 0 0 16 16h15.94A535.78 535.78 0 0 1 64 384h128a535.78 535.78 0 0 1-15.94-128H192a16 16 0 0 0 16-16v-16a16 16 0 0 0-16-16h-10l33.89-90.38a16 16 0 0 0-15-21.62H144V64h24a8 8 0 0 0 8-8V40a8 8 0 0 0-8-8h-24V8a8 8 0 0 0-8-8h-16a8 8 0 0 0-8 8v24H88a8 8 0 0 0-8 8v16a8 8 0 0 0 8 8h24v32H55.09a16 16 0 0 0-15 21.62zm173.16 251.58L224 448v-16a16 16 0 0 0-16-16H48a16 16 0 0 0-16 16v16L8.85 459.58A16 16 0 0 0 0 473.89V496a16 16 0 0 0 16 16h224a16 16 0 0 0 16-16v-22.11a16 16 0 0 0-8.84-14.31zm92.77-157.78l-3.29 82.2h126.72l-3.29-82.21 24.6-20.79A32 32 0 0 0 496 256.54V198a6 6 0 0 0-6-6h-26.38a6 6 0 0 0-6 6v26h-24.71v-26a6 6 0 0 0-6-6H373.1a6 6 0 0 0-6 6v26h-24.71v-26a6 6 0 0 0-6-6H310a6 6 0 0 0-6 6v58.6a32 32 0 0 0 11.36 24.4zM384 304a16 16 0 0 1 32 0v32h-32zm119.16 155.58L480 448v-16a16 16 0 0 0-16-16H336a16 16 0 0 0-16 16v16l-23.15 11.58a16 16 0 0 0-8.85 14.31V496a16 16 0 0 0 16 16h192a16 16 0 0 0 16-16v-22.11a16 16 0 0 0-8.84-14.31z"]},di={prefix:"fas",iconName:"chess-bishop",icon:[320,512,[],"f43a","M8 287.88c0 51.64 22.14 73.83 56 84.6V416h192v-43.52c33.86-10.77 56-33 56-84.6 0-30.61-10.73-67.1-26.69-102.56L185 285.65a8 8 0 0 1-11.31 0l-11.31-11.31a8 8 0 0 1 0-11.31L270.27 155.1c-20.8-37.91-46.47-72.1-70.87-92.59C213.4 59.09 224 47.05 224 32a32 32 0 0 0-32-32h-64a32 32 0 0 0-32 32c0 15 10.6 27.09 24.6 30.51C67.81 106.8 8 214.5 8 287.88zM304 448H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h288a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},pi={prefix:"fas",iconName:"chess-board",icon:[512,512,[],"f43c","M255.9.2h-64v64h64zM0 64.17v64h64v-64zM128 .2H64v64h64zm64 255.9v64h64v-64zM0 192.12v64h64v-64zM383.85.2h-64v64h64zm128 0h-64v64h64zM128 256.1H64v64h64zM511.8 448v-64h-64v64zm0-128v-64h-64v64zM383.85 512h64v-64h-64zm128-319.88v-64h-64v64zM128 512h64v-64h-64zM0 512h64v-64H0zm255.9 0h64v-64h-64zM0 320.07v64h64v-64zm319.88-191.92v-64h-64v64zm-64 128h64v-64h-64zm-64 128v64h64v-64zm128-64h64v-64h-64zm0-127.95h64v-64h-64zm0 191.93v64h64v-64zM64 384.05v64h64v-64zm128-255.9v-64h-64v64zm191.92 255.9h64v-64h-64zm-128-191.93v-64h-64v64zm128-127.95v64h64v-64zm-128 255.9v64h64v-64zm-64-127.95H128v64h64zm191.92 64h64v-64h-64zM128 128.15H64v64h64zm0 191.92v64h64v-64z"]},gi={prefix:"fas",iconName:"chess-king",icon:[448,512,[],"f43f","M400 448H48a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h352a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm16-288H256v-48h40a8 8 0 0 0 8-8V56a8 8 0 0 0-8-8h-40V8a8 8 0 0 0-8-8h-48a8 8 0 0 0-8 8v40h-40a8 8 0 0 0-8 8v48a8 8 0 0 0 8 8h40v48H32a32 32 0 0 0-30.52 41.54L74.56 416h298.88l73.08-214.46A32 32 0 0 0 416 160z"]},fi={prefix:"fas",iconName:"chess-knight",icon:[384,512,[],"f441","M19 272.47l40.63 18.06a32 32 0 0 0 24.88.47l12.78-5.12a32 32 0 0 0 18.76-20.5l9.22-30.65a24 24 0 0 1 12.55-15.65L159.94 208v50.33a48 48 0 0 1-26.53 42.94l-57.22 28.65A80 80 0 0 0 32 401.48V416h319.86V224c0-106-85.92-192-191.92-192H12A12 12 0 0 0 0 44a16.9 16.9 0 0 0 1.79 7.58L16 80l-9 9a24 24 0 0 0-7 17v137.21a32 32 0 0 0 19 29.26zM52 128a20 20 0 1 1-20 20 20 20 0 0 1 20-20zm316 320H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h352a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},mi={prefix:"fas",iconName:"chess-pawn",icon:[320,512,[],"f443","M105.1 224H80a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h16v5.49c0 44-4.14 86.6-24 122.51h176c-19.89-35.91-24-78.51-24-122.51V288h16a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-25.1c29.39-18.38 49.1-50.78 49.1-88a104 104 0 0 0-208 0c0 37.22 19.71 69.62 49.1 88zM304 448H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h288a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},vi={prefix:"fas",iconName:"chess-queen",icon:[512,512,[],"f445","M256 112a56 56 0 1 0-56-56 56 56 0 0 0 56 56zm176 336H80a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h352a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm72.87-263.84l-28.51-15.92c-7.44-5-16.91-2.46-22.29 4.68a47.59 47.59 0 0 1-47.23 18.23C383.7 186.86 368 164.93 368 141.4a13.4 13.4 0 0 0-13.4-13.4h-38.77c-6 0-11.61 4-12.86 9.91a48 48 0 0 1-93.94 0c-1.25-5.92-6.82-9.91-12.86-9.91H157.4a13.4 13.4 0 0 0-13.4 13.4c0 25.69-19 48.75-44.67 50.49a47.5 47.5 0 0 1-41.54-19.15c-5.28-7.09-14.73-9.45-22.09-4.54l-28.57 16a16 16 0 0 0-5.44 20.47L104.24 416h303.52l102.55-211.37a16 16 0 0 0-5.44-20.47z"]},Ci={prefix:"fas",iconName:"chess-rook",icon:[384,512,[],"f447","M368 32h-56a16 16 0 0 0-16 16v48h-48V48a16 16 0 0 0-16-16h-80a16 16 0 0 0-16 16v48H88.1V48a16 16 0 0 0-16-16H16A16 16 0 0 0 0 48v176l64 32c0 48.33-1.54 95-13.21 160h282.42C321.54 351 320 303.72 320 256l64-32V48a16 16 0 0 0-16-16zM224 320h-64v-64a32 32 0 0 1 64 0zm144 128H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h352a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},yi={prefix:"fas",iconName:"chevron-circle-down",icon:[512,512,[],"f13a","M504 256c0 137-111 248-248 248S8 393 8 256 119 8 256 8s248 111 248 248zM273 369.9l135.5-135.5c9.4-9.4 9.4-24.6 0-33.9l-17-17c-9.4-9.4-24.6-9.4-33.9 0L256 285.1 154.4 183.5c-9.4-9.4-24.6-9.4-33.9 0l-17 17c-9.4 9.4-9.4 24.6 0 33.9L239 369.9c9.4 9.4 24.6 9.4 34 0z"]},wi={prefix:"fas",iconName:"chevron-circle-left",icon:[512,512,[],"f137","M256 504C119 504 8 393 8 256S119 8 256 8s248 111 248 248-111 248-248 248zM142.1 273l135.5 135.5c9.4 9.4 24.6 9.4 33.9 0l17-17c9.4-9.4 9.4-24.6 0-33.9L226.9 256l101.6-101.6c9.4-9.4 9.4-24.6 0-33.9l-17-17c-9.4-9.4-24.6-9.4-33.9 0L142.1 239c-9.4 9.4-9.4 24.6 0 34z"]},Si={prefix:"fas",iconName:"chevron-circle-right",icon:[512,512,[],"f138","M256 8c137 0 248 111 248 248S393 504 256 504 8 393 8 256 119 8 256 8zm113.9 231L234.4 103.5c-9.4-9.4-24.6-9.4-33.9 0l-17 17c-9.4 9.4-9.4 24.6 0 33.9L285.1 256 183.5 357.6c-9.4 9.4-9.4 24.6 0 33.9l17 17c9.4 9.4 24.6 9.4 33.9 0L369.9 273c9.4-9.4 9.4-24.6 0-34z"]},bi={prefix:"fas",iconName:"chevron-circle-up",icon:[512,512,[],"f139","M8 256C8 119 119 8 256 8s248 111 248 248-111 248-248 248S8 393 8 256zm231-113.9L103.5 277.6c-9.4 9.4-9.4 24.6 0 33.9l17 17c9.4 9.4 24.6 9.4 33.9 0L256 226.9l101.6 101.6c9.4 9.4 24.6 9.4 33.9 0l17-17c9.4-9.4 9.4-24.6 0-33.9L273 142.1c-9.4-9.4-24.6-9.4-34 0z"]},Ei={prefix:"fas",iconName:"chevron-down",icon:[448,512,[],"f078","M207.029 381.476L12.686 187.132c-9.373-9.373-9.373-24.569 0-33.941l22.667-22.667c9.357-9.357 24.522-9.375 33.901-.04L224 284.505l154.745-154.021c9.379-9.335 24.544-9.317 33.901.04l22.667 22.667c9.373 9.373 9.373 24.569 0 33.941L240.971 381.476c-9.373 9.372-24.569 9.372-33.942 0z"]},Ai={prefix:"fas",iconName:"chevron-left",icon:[320,512,[],"f053","M34.52 239.03L228.87 44.69c9.37-9.37 24.57-9.37 33.94 0l22.67 22.67c9.36 9.36 9.37 24.52.04 33.9L131.49 256l154.02 154.75c9.34 9.38 9.32 24.54-.04 33.9l-22.67 22.67c-9.37 9.37-24.57 9.37-33.94 0L34.52 272.97c-9.37-9.37-9.37-24.57 0-33.94z"]},Ti={prefix:"fas",iconName:"chevron-right",icon:[320,512,[],"f054","M285.476 272.971L91.132 467.314c-9.373 9.373-24.569 9.373-33.941 0l-22.667-22.667c-9.357-9.357-9.375-24.522-.04-33.901L188.505 256 34.484 101.255c-9.335-9.379-9.317-24.544.04-33.901l22.667-22.667c9.373-9.373 24.569-9.373 33.941 0L285.475 239.03c9.373 9.372 9.373 24.568.001 33.941z"]},Mi={prefix:"fas",iconName:"chevron-up",icon:[448,512,[],"f077","M240.971 130.524l194.343 194.343c9.373 9.373 9.373 24.569 0 33.941l-22.667 22.667c-9.357 9.357-24.522 9.375-33.901.04L224 227.495 69.255 381.516c-9.379 9.335-24.544 9.317-33.901-.04l-22.667-22.667c-9.373-9.373-9.373-24.569 0-33.941L207.03 130.525c9.372-9.373 24.568-9.373 33.941-.001z"]},Ri={prefix:"fas",iconName:"child",icon:[384,512,[],"f1ae","M120 72c0-39.765 32.235-72 72-72s72 32.235 72 72c0 39.764-32.235 72-72 72s-72-32.236-72-72zm254.627 1.373c-12.496-12.497-32.758-12.497-45.254 0L242.745 160H141.254L54.627 73.373c-12.496-12.497-32.758-12.497-45.254 0-12.497 12.497-12.497 32.758 0 45.255L104 213.254V480c0 17.673 14.327 32 32 32h16c17.673 0 32-14.327 32-32V368h16v112c0 17.673 14.327 32 32 32h16c17.673 0 32-14.327 32-32V213.254l94.627-94.627c12.497-12.497 12.497-32.757 0-45.254z"]},_i={prefix:"fas",iconName:"church",icon:[640,512,[],"f51d","M464.46 246.68L352 179.2V128h48c8.84 0 16-7.16 16-16V80c0-8.84-7.16-16-16-16h-48V16c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v48h-48c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h48v51.2l-112.46 67.48A31.997 31.997 0 0 0 160 274.12V512h96v-96c0-35.35 28.65-64 64-64s64 28.65 64 64v96h96V274.12c0-11.24-5.9-21.66-15.54-27.44zM0 395.96V496c0 8.84 7.16 16 16 16h112V320L19.39 366.54A32.024 32.024 0 0 0 0 395.96zm620.61-29.42L512 320v192h112c8.84 0 16-7.16 16-16V395.96c0-12.8-7.63-24.37-19.39-29.42z"]},Pi={prefix:"fas",iconName:"circle",icon:[512,512,[],"f111","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8z"]},xi={prefix:"fas",iconName:"circle-notch",icon:[512,512,[],"f1ce","M288 39.056v16.659c0 10.804 7.281 20.159 17.686 23.066C383.204 100.434 440 171.518 440 256c0 101.689-82.295 184-184 184-101.689 0-184-82.295-184-184 0-84.47 56.786-155.564 134.312-177.219C216.719 75.874 224 66.517 224 55.712V39.064c0-15.709-14.834-27.153-30.046-23.234C86.603 43.482 7.394 141.206 8.003 257.332c.72 137.052 111.477 246.956 248.531 246.667C393.255 503.711 504 392.788 504 256c0-115.633-79.14-212.779-186.211-240.236C302.678 11.889 288 23.456 288 39.056z"]},Di={prefix:"fas",iconName:"city",icon:[640,512,[],"f64f","M616 192H480V24c0-13.26-10.74-24-24-24H312c-13.26 0-24 10.74-24 24v72h-64V16c0-8.84-7.16-16-16-16h-16c-8.84 0-16 7.16-16 16v80h-64V16c0-8.84-7.16-16-16-16H80c-8.84 0-16 7.16-16 16v80H24c-13.26 0-24 10.74-24 24v360c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V216c0-13.26-10.75-24-24-24zM128 404c0 6.63-5.37 12-12 12H76c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12H76c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12H76c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm128 192c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm160 96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12V76c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm160 288c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40zm0-96c0 6.63-5.37 12-12 12h-40c-6.63 0-12-5.37-12-12v-40c0-6.63 5.37-12 12-12h40c6.63 0 12 5.37 12 12v40z"]},Ii={prefix:"fas",iconName:"clinic-medical",icon:[576,512,[],"f7f2","M288 115L69.47 307.71c-1.62 1.46-3.69 2.14-5.47 3.35V496a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V311.1c-1.7-1.16-3.72-1.82-5.26-3.2zm96 261a8 8 0 0 1-8 8h-56v56a8 8 0 0 1-8 8h-48a8 8 0 0 1-8-8v-56h-56a8 8 0 0 1-8-8v-48a8 8 0 0 1 8-8h56v-56a8 8 0 0 1 8-8h48a8 8 0 0 1 8 8v56h56a8 8 0 0 1 8 8zm186.69-139.72l-255.94-226a39.85 39.85 0 0 0-53.45 0l-256 226a16 16 0 0 0-1.21 22.6L25.5 282.7a16 16 0 0 0 22.6 1.21L277.42 81.63a16 16 0 0 1 21.17 0L527.91 283.9a16 16 0 0 0 22.6-1.21l21.4-23.82a16 16 0 0 0-1.22-22.59z"]},Li={prefix:"fas",iconName:"clipboard",icon:[384,512,[],"f328","M384 112v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V112c0-26.51 21.49-48 48-48h80c0-35.29 28.71-64 64-64s64 28.71 64 64h80c26.51 0 48 21.49 48 48zM192 40c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24m96 114v-20a6 6 0 0 0-6-6H102a6 6 0 0 0-6 6v20a6 6 0 0 0 6 6h180a6 6 0 0 0 6-6z"]},Ni={prefix:"fas",iconName:"clipboard-check",icon:[384,512,[],"f46c","M336 64h-80c0-35.3-28.7-64-64-64s-64 28.7-64 64H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM192 40c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm121.2 231.8l-143 141.8c-4.7 4.7-12.3 4.6-17-.1l-82.6-83.3c-4.7-4.7-4.6-12.3.1-17L99.1 285c4.7-4.7 12.3-4.6 17 .1l46 46.4 106-105.2c4.7-4.7 12.3-4.6 17 .1l28.2 28.4c4.7 4.8 4.6 12.3-.1 17z"]},Oi={prefix:"fas",iconName:"clipboard-list",icon:[384,512,[],"f46d","M336 64h-80c0-35.3-28.7-64-64-64s-64 28.7-64 64H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM96 424c-13.3 0-24-10.7-24-24s10.7-24 24-24 24 10.7 24 24-10.7 24-24 24zm0-96c-13.3 0-24-10.7-24-24s10.7-24 24-24 24 10.7 24 24-10.7 24-24 24zm0-96c-13.3 0-24-10.7-24-24s10.7-24 24-24 24 10.7 24 24-10.7 24-24 24zm96-192c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm128 368c0 4.4-3.6 8-8 8H168c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16zm0-96c0 4.4-3.6 8-8 8H168c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16zm0-96c0 4.4-3.6 8-8 8H168c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16z"]},Fi={prefix:"fas",iconName:"clock",icon:[512,512,[],"f017","M256,8C119,8,8,119,8,256S119,504,256,504,504,393,504,256,393,8,256,8Zm92.49,313h0l-20,25a16,16,0,0,1-22.49,2.5h0l-67-49.72a40,40,0,0,1-15-31.23V112a16,16,0,0,1,16-16h32a16,16,0,0,1,16,16V256l58,42.5A16,16,0,0,1,348.49,321Z"]},ki={prefix:"fas",iconName:"clone",icon:[512,512,[],"f24d","M464 0c26.51 0 48 21.49 48 48v288c0 26.51-21.49 48-48 48H176c-26.51 0-48-21.49-48-48V48c0-26.51 21.49-48 48-48h288M176 416c-44.112 0-80-35.888-80-80V128H48c-26.51 0-48 21.49-48 48v288c0 26.51 21.49 48 48 48h288c26.51 0 48-21.49 48-48v-48H176z"]},Gi={prefix:"fas",iconName:"closed-captioning",icon:[512,512,[],"f20a","M464 64H48C21.5 64 0 85.5 0 112v288c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM218.1 287.7c2.8-2.5 7.1-2.1 9.2.9l19.5 27.7c1.7 2.4 1.5 5.6-.5 7.7-53.6 56.8-172.8 32.1-172.8-67.9 0-97.3 121.7-119.5 172.5-70.1 2.1 2 2.5 3.2 1 5.7l-17.5 30.5c-1.9 3.1-6.2 4-9.1 1.7-40.8-32-94.6-14.9-94.6 31.2.1 48 51.1 70.5 92.3 32.6zm190.4 0c2.8-2.5 7.1-2.1 9.2.9l19.5 27.7c1.7 2.4 1.5 5.6-.5 7.7-53.5 56.9-172.7 32.1-172.7-67.9 0-97.3 121.7-119.5 172.5-70.1 2.1 2 2.5 3.2 1 5.7L420 222.2c-1.9 3.1-6.2 4-9.1 1.7-40.8-32-94.6-14.9-94.6 31.2 0 48 51 70.5 92.2 32.6z"]},Vi={prefix:"fas",iconName:"cloud",icon:[640,512,[],"f0c2","M537.6 226.6c4.1-10.7 6.4-22.4 6.4-34.6 0-53-43-96-96-96-19.7 0-38.1 6-53.3 16.2C367 64.2 315.3 32 256 32c-88.4 0-160 71.6-160 160 0 2.7.1 5.4.2 8.1C40.2 219.8 0 273.2 0 336c0 79.5 64.5 144 144 144h368c70.7 0 128-57.3 128-128 0-61.9-44-113.6-102.4-125.4z"]},Hi={prefix:"fas",iconName:"cloud-download-alt",icon:[640,512,[],"f381","M537.6 226.6c4.1-10.7 6.4-22.4 6.4-34.6 0-53-43-96-96-96-19.7 0-38.1 6-53.3 16.2C367 64.2 315.3 32 256 32c-88.4 0-160 71.6-160 160 0 2.7.1 5.4.2 8.1C40.2 219.8 0 273.2 0 336c0 79.5 64.5 144 144 144h368c70.7 0 128-57.3 128-128 0-61.9-44-113.6-102.4-125.4zm-132.9 88.7L299.3 420.7c-6.2 6.2-16.4 6.2-22.6 0L171.3 315.3c-10.1-10.1-2.9-27.3 11.3-27.3H248V176c0-8.8 7.2-16 16-16h48c8.8 0 16 7.2 16 16v112h65.4c14.2 0 21.4 17.2 11.3 27.3z"]},Bi={prefix:"fas",iconName:"cloud-meatball",icon:[512,512,[],"f73b","M48 352c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48zm416 0c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48zm-119 11.1c4.6-14.5 1.6-30.8-9.8-42.3-11.5-11.5-27.8-14.4-42.3-9.9-7-13.5-20.7-23-36.9-23s-29.9 9.5-36.9 23c-14.5-4.6-30.8-1.6-42.3 9.9-11.5 11.5-14.4 27.8-9.9 42.3-13.5 7-23 20.7-23 36.9s9.5 29.9 23 36.9c-4.6 14.5-1.6 30.8 9.9 42.3 8.2 8.2 18.9 12.3 29.7 12.3 4.3 0 8.5-1.1 12.6-2.5 7 13.5 20.7 23 36.9 23s29.9-9.5 36.9-23c4.1 1.3 8.3 2.5 12.6 2.5 10.8 0 21.5-4.1 29.7-12.3 11.5-11.5 14.4-27.8 9.8-42.3 13.5-7 23-20.7 23-36.9s-9.5-29.9-23-36.9zM512 224c0-53-43-96-96-96-.6 0-1.1.2-1.6.2 1.1-5.2 1.6-10.6 1.6-16.2 0-44.2-35.8-80-80-80-24.6 0-46.3 11.3-61 28.8C256.4 24.8 219.3 0 176 0 114.1 0 64 50.1 64 112c0 7.3.8 14.3 2.1 21.2C27.8 145.8 0 181.5 0 224c0 53 43 96 96 96h43.4c3.6-8 8.4-15.4 14.8-21.8 13.5-13.5 31.5-21.1 50.8-21.3 13.5-13.2 31.7-20.9 51-20.9s37.5 7.7 51 20.9c19.3.2 37.3 7.8 50.8 21.3 6.4 6.4 11.3 13.8 14.8 21.8H416c53 0 96-43 96-96z"]},zi={prefix:"fas",iconName:"cloud-moon",icon:[576,512,[],"f6c3","M342.8 352.7c5.7-9.6 9.2-20.7 9.2-32.7 0-35.3-28.7-64-64-64-17.2 0-32.8 6.9-44.3 17.9-16.3-29.6-47.5-49.9-83.7-49.9-53 0-96 43-96 96 0 2 .5 3.8.6 5.7C27.1 338.8 0 374.1 0 416c0 53 43 96 96 96h240c44.2 0 80-35.8 80-80 0-41.9-32.3-75.8-73.2-79.3zm222.5-54.3c-93.1 17.7-178.5-53.7-178.5-147.7 0-54.2 29-104 76.1-130.8 7.3-4.1 5.4-15.1-2.8-16.7C448.4 1.1 436.7 0 425 0 319.1 0 233.1 85.9 233.1 192c0 8.5.7 16.8 1.8 25 5.9 4.3 11.6 8.9 16.7 14.2 11.4-4.7 23.7-7.2 36.4-7.2 52.9 0 96 43.1 96 96 0 3.6-.2 7.2-.6 10.7 23.6 10.8 42.4 29.5 53.5 52.6 54.4-3.4 103.7-29.3 137.1-70.4 5.3-6.5-.5-16.1-8.7-14.5z"]},Ui={prefix:"fas",iconName:"cloud-moon-rain",icon:[576,512,[],"f73c","M350.5 225.5c-6.9-37.2-39.3-65.5-78.5-65.5-12.3 0-23.9 3-34.3 8-17.4-24.1-45.6-40-77.7-40-53 0-96 43-96 96 0 .5.2 1.1.2 1.6C27.6 232.9 0 265.2 0 304c0 44.2 35.8 80 80 80h256c44.2 0 80-35.8 80-80 0-39.2-28.2-71.7-65.5-78.5zm217.4-1.7c-70.4 13.3-135-40.3-135-110.8 0-40.6 21.9-78 57.5-98.1 5.5-3.1 4.1-11.4-2.1-12.5C479.6.8 470.7 0 461.8 0c-77.9 0-141.1 61.2-144.4 137.9 26.7 11.9 48.2 33.8 58.9 61.7 37.1 14.3 64 47.4 70.2 86.8 5.1.5 10 1.5 15.2 1.5 44.7 0 85.6-20.2 112.6-53.3 4.2-4.8-.2-12-6.4-10.8zM364.5 418.1c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8z"]},Wi={prefix:"fas",iconName:"cloud-rain",icon:[512,512,[],"f73d","M416 128c-.6 0-1.1.2-1.6.2 1.1-5.2 1.6-10.6 1.6-16.2 0-44.2-35.8-80-80-80-24.6 0-46.3 11.3-61 28.8C256.4 24.8 219.3 0 176 0 114.1 0 64 50.1 64 112c0 7.3.8 14.3 2.1 21.2C27.8 145.8 0 181.5 0 224c0 53 43 96 96 96h320c53 0 96-43 96-96s-43-96-96-96zM88 374.2c-12.8 44.4-40 56.4-40 87.7 0 27.7 21.5 50.1 48 50.1s48-22.4 48-50.1c0-31.4-27.2-43.1-40-87.7-2.2-8.1-13.5-8.5-16 0zm160 0c-12.8 44.4-40 56.4-40 87.7 0 27.7 21.5 50.1 48 50.1s48-22.4 48-50.1c0-31.4-27.2-43.1-40-87.7-2.2-8.1-13.5-8.5-16 0zm160 0c-12.8 44.4-40 56.4-40 87.7 0 27.7 21.5 50.1 48 50.1s48-22.4 48-50.1c0-31.4-27.2-43.1-40-87.7-2.2-8.1-13.5-8.5-16 0z"]},ji={prefix:"fas",iconName:"cloud-showers-heavy",icon:[512,512,[],"f740","M183.9 370.1c-7.6-4.4-17.4-1.8-21.8 6l-64 112c-4.4 7.7-1.7 17.5 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l64-112c4.4-7.6 1.7-17.4-6-21.8zm96 0c-7.6-4.4-17.4-1.8-21.8 6l-64 112c-4.4 7.7-1.7 17.5 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l64-112c4.4-7.6 1.7-17.4-6-21.8zm-192 0c-7.6-4.4-17.4-1.8-21.8 6l-64 112c-4.4 7.7-1.7 17.5 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l64-112c4.4-7.6 1.7-17.4-6-21.8zm384 0c-7.6-4.4-17.4-1.8-21.8 6l-64 112c-4.4 7.7-1.7 17.5 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l64-112c4.4-7.6 1.7-17.4-6-21.8zm-96 0c-7.6-4.4-17.4-1.8-21.8 6l-64 112c-4.4 7.7-1.7 17.5 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l64-112c4.4-7.6 1.7-17.4-6-21.8zM416 128c-.6 0-1.1.2-1.6.2 1.1-5.2 1.6-10.6 1.6-16.2 0-44.2-35.8-80-80-80-24.6 0-46.3 11.3-61 28.8C256.4 24.8 219.3 0 176 0 114.2 0 64 50.1 64 112c0 7.3.8 14.3 2.1 21.2C27.8 145.8 0 181.5 0 224c0 53 43 96 96 96h320c53 0 96-43 96-96s-43-96-96-96z"]},Ki={prefix:"fas",iconName:"cloud-sun",icon:[640,512,[],"f6c4","M575.2 325.7c.2-1.9.8-3.7.8-5.6 0-35.3-28.7-64-64-64-12.6 0-24.2 3.8-34.1 10-17.6-38.8-56.5-66-101.9-66-61.8 0-112 50.1-112 112 0 3 .7 5.8.9 8.7-49.6 3.7-88.9 44.7-88.9 95.3 0 53 43 96 96 96h272c53 0 96-43 96-96 0-42.1-27.2-77.4-64.8-90.4zm-430.4-22.6c-43.7-43.7-43.7-114.7 0-158.3 43.7-43.7 114.7-43.7 158.4 0 9.7 9.7 16.9 20.9 22.3 32.7 9.8-3.7 20.1-6 30.7-7.5L386 81.1c4-11.9-7.3-23.1-19.2-19.2L279 91.2 237.5 8.4C232-2.8 216-2.8 210.4 8.4L169 91.2 81.1 61.9C69.3 58 58 69.3 61.9 81.1l29.3 87.8-82.8 41.5c-11.2 5.6-11.2 21.5 0 27.1l82.8 41.4-29.3 87.8c-4 11.9 7.3 23.1 19.2 19.2l76.1-25.3c6.1-12.4 14-23.7 23.6-33.5-13.1-5.4-25.4-13.4-36-24zm-4.8-79.2c0 40.8 29.3 74.8 67.9 82.3 8-4.7 16.3-8.8 25.2-11.7 5.4-44.3 31-82.5 67.4-105C287.3 160.4 258 140 224 140c-46.3 0-84 37.6-84 83.9z"]},$i={prefix:"fas",iconName:"cloud-sun-rain",icon:[576,512,[],"f743","M510.5 225.5c-6.9-37.2-39.3-65.5-78.5-65.5-12.3 0-23.9 3-34.3 8-17.4-24.1-45.6-40-77.7-40-53 0-96 43-96 96 0 .5.2 1.1.2 1.6C187.6 233 160 265.2 160 304c0 44.2 35.8 80 80 80h256c44.2 0 80-35.8 80-80 0-39.2-28.2-71.7-65.5-78.5zm-386.4 34.4c-37.4-37.4-37.4-98.3 0-135.8 34.6-34.6 89.1-36.8 126.7-7.4 20-12.9 43.6-20.7 69.2-20.7.7 0 1.3.2 2 .2l8.9-26.7c3.4-10.2-6.3-19.8-16.5-16.4l-75.3 25.1-35.5-71c-4.8-9.6-18.5-9.6-23.3 0l-35.5 71-75.3-25.1c-10.2-3.4-19.8 6.3-16.4 16.5l25.1 75.3-71 35.5c-9.6 4.8-9.6 18.5 0 23.3l71 35.5-25.1 75.3c-3.4 10.2 6.3 19.8 16.5 16.5l59.2-19.7c-.2-2.4-.7-4.7-.7-7.2 0-12.5 2.3-24.5 6.2-35.9-3.6-2.7-7.1-5.2-10.2-8.3zm69.8-58c4.3-24.5 15.8-46.4 31.9-64-9.8-6.2-21.4-9.9-33.8-9.9-35.3 0-64 28.7-64 64 0 18.7 8.2 35.4 21.1 47.1 11.3-15.9 26.6-28.9 44.8-37.2zm330.6 216.2c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8zm-96 0c-7.6-4.3-17.4-1.8-21.8 6l-36.6 64c-4.4 7.7-1.7 17.4 6 21.8 2.5 1.4 5.2 2.1 7.9 2.1 5.5 0 10.9-2.9 13.9-8.1l36.6-64c4.3-7.7 1.7-17.4-6-21.8z"]},qi={prefix:"fas",iconName:"cloud-upload-alt",icon:[640,512,[],"f382","M537.6 226.6c4.1-10.7 6.4-22.4 6.4-34.6 0-53-43-96-96-96-19.7 0-38.1 6-53.3 16.2C367 64.2 315.3 32 256 32c-88.4 0-160 71.6-160 160 0 2.7.1 5.4.2 8.1C40.2 219.8 0 273.2 0 336c0 79.5 64.5 144 144 144h368c70.7 0 128-57.3 128-128 0-61.9-44-113.6-102.4-125.4zM393.4 288H328v112c0 8.8-7.2 16-16 16h-48c-8.8 0-16-7.2-16-16V288h-65.4c-14.3 0-21.4-17.2-11.3-27.3l105.4-105.4c6.2-6.2 16.4-6.2 22.6 0l105.4 105.4c10.1 10.1 2.9 27.3-11.3 27.3z"]},Yi={prefix:"fas",iconName:"cocktail",icon:[576,512,[],"f561","M296 464h-56V338.78l168.74-168.73c15.52-15.52 4.53-42.05-17.42-42.05H24.68c-21.95 0-32.94 26.53-17.42 42.05L176 338.78V464h-56c-22.09 0-40 17.91-40 40 0 4.42 3.58 8 8 8h240c4.42 0 8-3.58 8-8 0-22.09-17.91-40-40-40zM432 0c-62.61 0-115.35 40.2-135.18 96h52.54c16.65-28.55 47.27-48 82.64-48 52.93 0 96 43.06 96 96s-43.07 96-96 96c-14.04 0-27.29-3.2-39.32-8.64l-35.26 35.26C379.23 279.92 404.59 288 432 288c79.53 0 144-64.47 144-144S511.53 0 432 0z"]},Qi={prefix:"fas",iconName:"code",icon:[640,512,[],"f121","M278.9 511.5l-61-17.7c-6.4-1.8-10-8.5-8.2-14.9L346.2 8.7c1.8-6.4 8.5-10 14.9-8.2l61 17.7c6.4 1.8 10 8.5 8.2 14.9L293.8 503.3c-1.9 6.4-8.5 10.1-14.9 8.2zm-114-112.2l43.5-46.4c4.6-4.9 4.3-12.7-.8-17.2L117 256l90.6-79.7c5.1-4.5 5.5-12.3.8-17.2l-43.5-46.4c-4.5-4.8-12.1-5.1-17-.5L3.8 247.2c-5.1 4.7-5.1 12.8 0 17.5l144.1 135.1c4.9 4.6 12.5 4.4 17-.5zm327.2.6l144.1-135.1c5.1-4.7 5.1-12.8 0-17.5L492.1 112.1c-4.8-4.5-12.4-4.3-17 .5L431.6 159c-4.6 4.9-4.3 12.7.8 17.2L523 256l-90.6 79.7c-5.1 4.5-5.5 12.3-.8 17.2l43.5 46.4c4.5 4.9 12.1 5.1 17 .6z"]},Xi={prefix:"fas",iconName:"code-branch",icon:[384,512,[],"f126","M384 144c0-44.2-35.8-80-80-80s-80 35.8-80 80c0 36.4 24.3 67.1 57.5 76.8-.6 16.1-4.2 28.5-11 36.9-15.4 19.2-49.3 22.4-85.2 25.7-28.2 2.6-57.4 5.4-81.3 16.9v-144c32.5-10.2 56-40.5 56-76.3 0-44.2-35.8-80-80-80S0 35.8 0 80c0 35.8 23.5 66.1 56 76.3v199.3C23.5 365.9 0 396.2 0 432c0 44.2 35.8 80 80 80s80-35.8 80-80c0-34-21.2-63.1-51.2-74.6 3.1-5.2 7.8-9.8 14.9-13.4 16.2-8.2 40.4-10.4 66.1-12.8 42.2-3.9 90-8.4 118.2-43.4 14-17.4 21.1-39.8 21.6-67.9 31.6-10.8 54.4-40.7 54.4-75.9zM80 64c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16zm0 384c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm224-320c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16 7.2-16 16-16z"]},Zi={prefix:"fas",iconName:"coffee",icon:[640,512,[],"f0f4","M192 384h192c53 0 96-43 96-96h32c70.6 0 128-57.4 128-128S582.6 32 512 32H120c-13.3 0-24 10.7-24 24v232c0 53 43 96 96 96zM512 96c35.3 0 64 28.7 64 64s-28.7 64-64 64h-32V96h32zm47.7 384H48.3c-47.6 0-61-64-36-64h583.3c25 0 11.8 64-35.9 64z"]},Ji={prefix:"fas",iconName:"cog",icon:[512,512,[],"f013","M487.4 315.7l-42.6-24.6c4.3-23.2 4.3-47 0-70.2l42.6-24.6c4.9-2.8 7.1-8.6 5.5-14-11.1-35.6-30-67.8-54.7-94.6-3.8-4.1-10-5.1-14.8-2.3L380.8 110c-17.9-15.4-38.5-27.3-60.8-35.1V25.8c0-5.6-3.9-10.5-9.4-11.7-36.7-8.2-74.3-7.8-109.2 0-5.5 1.2-9.4 6.1-9.4 11.7V75c-22.2 7.9-42.8 19.8-60.8 35.1L88.7 85.5c-4.9-2.8-11-1.9-14.8 2.3-24.7 26.7-43.6 58.9-54.7 94.6-1.7 5.4.6 11.2 5.5 14L67.3 221c-4.3 23.2-4.3 47 0 70.2l-42.6 24.6c-4.9 2.8-7.1 8.6-5.5 14 11.1 35.6 30 67.8 54.7 94.6 3.8 4.1 10 5.1 14.8 2.3l42.6-24.6c17.9 15.4 38.5 27.3 60.8 35.1v49.2c0 5.6 3.9 10.5 9.4 11.7 36.7 8.2 74.3 7.8 109.2 0 5.5-1.2 9.4-6.1 9.4-11.7v-49.2c22.2-7.9 42.8-19.8 60.8-35.1l42.6 24.6c4.9 2.8 11 1.9 14.8-2.3 24.7-26.7 43.6-58.9 54.7-94.6 1.5-5.5-.7-11.3-5.6-14.1zM256 336c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},er={prefix:"fas",iconName:"cogs",icon:[640,512,[],"f085","M512.1 191l-8.2 14.3c-3 5.3-9.4 7.5-15.1 5.4-11.8-4.4-22.6-10.7-32.1-18.6-4.6-3.8-5.8-10.5-2.8-15.7l8.2-14.3c-6.9-8-12.3-17.3-15.9-27.4h-16.5c-6 0-11.2-4.3-12.2-10.3-2-12-2.1-24.6 0-37.1 1-6 6.2-10.4 12.2-10.4h16.5c3.6-10.1 9-19.4 15.9-27.4l-8.2-14.3c-3-5.2-1.9-11.9 2.8-15.7 9.5-7.9 20.4-14.2 32.1-18.6 5.7-2.1 12.1.1 15.1 5.4l8.2 14.3c10.5-1.9 21.2-1.9 31.7 0L552 6.3c3-5.3 9.4-7.5 15.1-5.4 11.8 4.4 22.6 10.7 32.1 18.6 4.6 3.8 5.8 10.5 2.8 15.7l-8.2 14.3c6.9 8 12.3 17.3 15.9 27.4h16.5c6 0 11.2 4.3 12.2 10.3 2 12 2.1 24.6 0 37.1-1 6-6.2 10.4-12.2 10.4h-16.5c-3.6 10.1-9 19.4-15.9 27.4l8.2 14.3c3 5.2 1.9 11.9-2.8 15.7-9.5 7.9-20.4 14.2-32.1 18.6-5.7 2.1-12.1-.1-15.1-5.4l-8.2-14.3c-10.4 1.9-21.2 1.9-31.7 0zm-10.5-58.8c38.5 29.6 82.4-14.3 52.8-52.8-38.5-29.7-82.4 14.3-52.8 52.8zM386.3 286.1l33.7 16.8c10.1 5.8 14.5 18.1 10.5 29.1-8.9 24.2-26.4 46.4-42.6 65.8-7.4 8.9-20.2 11.1-30.3 5.3l-29.1-16.8c-16 13.7-34.6 24.6-54.9 31.7v33.6c0 11.6-8.3 21.6-19.7 23.6-24.6 4.2-50.4 4.4-75.9 0-11.5-2-20-11.9-20-23.6V418c-20.3-7.2-38.9-18-54.9-31.7L74 403c-10 5.8-22.9 3.6-30.3-5.3-16.2-19.4-33.3-41.6-42.2-65.7-4-10.9.4-23.2 10.5-29.1l33.3-16.8c-3.9-20.9-3.9-42.4 0-63.4L12 205.8c-10.1-5.8-14.6-18.1-10.5-29 8.9-24.2 26-46.4 42.2-65.8 7.4-8.9 20.2-11.1 30.3-5.3l29.1 16.8c16-13.7 34.6-24.6 54.9-31.7V57.1c0-11.5 8.2-21.5 19.6-23.5 24.6-4.2 50.5-4.4 76-.1 11.5 2 20 11.9 20 23.6v33.6c20.3 7.2 38.9 18 54.9 31.7l29.1-16.8c10-5.8 22.9-3.6 30.3 5.3 16.2 19.4 33.2 41.6 42.1 65.8 4 10.9.1 23.2-10 29.1l-33.7 16.8c3.9 21 3.9 42.5 0 63.5zm-117.6 21.1c59.2-77-28.7-164.9-105.7-105.7-59.2 77 28.7 164.9 105.7 105.7zm243.4 182.7l-8.2 14.3c-3 5.3-9.4 7.5-15.1 5.4-11.8-4.4-22.6-10.7-32.1-18.6-4.6-3.8-5.8-10.5-2.8-15.7l8.2-14.3c-6.9-8-12.3-17.3-15.9-27.4h-16.5c-6 0-11.2-4.3-12.2-10.3-2-12-2.1-24.6 0-37.1 1-6 6.2-10.4 12.2-10.4h16.5c3.6-10.1 9-19.4 15.9-27.4l-8.2-14.3c-3-5.2-1.9-11.9 2.8-15.7 9.5-7.9 20.4-14.2 32.1-18.6 5.7-2.1 12.1.1 15.1 5.4l8.2 14.3c10.5-1.9 21.2-1.9 31.7 0l8.2-14.3c3-5.3 9.4-7.5 15.1-5.4 11.8 4.4 22.6 10.7 32.1 18.6 4.6 3.8 5.8 10.5 2.8 15.7l-8.2 14.3c6.9 8 12.3 17.3 15.9 27.4h16.5c6 0 11.2 4.3 12.2 10.3 2 12 2.1 24.6 0 37.1-1 6-6.2 10.4-12.2 10.4h-16.5c-3.6 10.1-9 19.4-15.9 27.4l8.2 14.3c3 5.2 1.9 11.9-2.8 15.7-9.5 7.9-20.4 14.2-32.1 18.6-5.7 2.1-12.1-.1-15.1-5.4l-8.2-14.3c-10.4 1.9-21.2 1.9-31.7 0zM501.6 431c38.5 29.6 82.4-14.3 52.8-52.8-38.5-29.6-82.4 14.3-52.8 52.8z"]},tr={prefix:"fas",iconName:"coins",icon:[512,512,[],"f51e","M0 405.3V448c0 35.3 86 64 192 64s192-28.7 192-64v-42.7C342.7 434.4 267.2 448 192 448S41.3 434.4 0 405.3zM320 128c106 0 192-28.7 192-64S426 0 320 0 128 28.7 128 64s86 64 192 64zM0 300.4V352c0 35.3 86 64 192 64s192-28.7 192-64v-51.6c-41.3 34-116.9 51.6-192 51.6S41.3 334.4 0 300.4zm416 11c57.3-11.1 96-31.7 96-55.4v-42.7c-23.2 16.4-57.3 27.6-96 34.5v63.6zM192 160C86 160 0 195.8 0 240s86 80 192 80 192-35.8 192-80-86-80-192-80zm219.3 56.3c60-10.8 100.7-32 100.7-56.3v-42.7c-35.5 25.1-96.5 38.6-160.7 41.8 29.5 14.3 51.2 33.5 60 57.2z"]},ir={prefix:"fas",iconName:"columns",icon:[512,512,[],"f0db","M464 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V80c0-26.51-21.49-48-48-48zM224 416H64V160h160v256zm224 0H288V160h160v256z"]},rr={prefix:"fas",iconName:"comment",icon:[512,512,[],"f075","M256 32C114.6 32 0 125.1 0 240c0 49.6 21.4 95 57 130.7C44.5 421.1 2.7 466 2.2 466.5c-2.2 2.3-2.8 5.7-1.5 8.7S4.8 480 8 480c66.3 0 116-31.8 140.6-51.4 32.7 12.3 69 19.4 107.4 19.4 141.4 0 256-93.1 256-208S397.4 32 256 32z"]},nr={prefix:"fas",iconName:"comment-alt",icon:[512,512,[],"f27a","M448 0H64C28.7 0 0 28.7 0 64v288c0 35.3 28.7 64 64 64h96v84c0 9.8 11.2 15.5 19.1 9.7L304 416h144c35.3 0 64-28.7 64-64V64c0-35.3-28.7-64-64-64z"]},sr={prefix:"fas",iconName:"comment-dollar",icon:[512,512,[],"f651","M256 32C114.62 32 0 125.12 0 240c0 49.56 21.41 95.01 57.02 130.74C44.46 421.05 2.7 465.97 2.2 466.5A7.995 7.995 0 0 0 8 480c66.26 0 115.99-31.75 140.6-51.38C181.29 440.93 217.59 448 256 448c141.38 0 256-93.12 256-208S397.38 32 256 32zm24 302.44V352c0 8.84-7.16 16-16 16h-16c-8.84 0-16-7.16-16-16v-17.73c-11.42-1.35-22.28-5.19-31.78-11.46-6.22-4.11-6.82-13.11-1.55-18.38l17.52-17.52c3.74-3.74 9.31-4.24 14.11-2.03 3.18 1.46 6.66 2.22 10.26 2.22h32.78c4.66 0 8.44-3.78 8.44-8.42 0-3.75-2.52-7.08-6.12-8.11l-50.07-14.3c-22.25-6.35-40.01-24.71-42.91-47.67-4.05-32.07 19.03-59.43 49.32-63.05V128c0-8.84 7.16-16 16-16h16c8.84 0 16 7.16 16 16v17.73c11.42 1.35 22.28 5.19 31.78 11.46 6.22 4.11 6.82 13.11 1.55 18.38l-17.52 17.52c-3.74 3.74-9.31 4.24-14.11 2.03a24.516 24.516 0 0 0-10.26-2.22h-32.78c-4.66 0-8.44 3.78-8.44 8.42 0 3.75 2.52 7.08 6.12 8.11l50.07 14.3c22.25 6.36 40.01 24.71 42.91 47.67 4.05 32.06-19.03 59.42-49.32 63.04z"]},or={prefix:"fas",iconName:"comment-dots",icon:[512,512,[],"f4ad","M256 32C114.6 32 0 125.1 0 240c0 49.6 21.4 95 57 130.7C44.5 421.1 2.7 466 2.2 466.5c-2.2 2.3-2.8 5.7-1.5 8.7S4.8 480 8 480c66.3 0 116-31.8 140.6-51.4 32.7 12.3 69 19.4 107.4 19.4 141.4 0 256-93.1 256-208S397.4 32 256 32zM128 272c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128 0c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128 0c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},ar={prefix:"fas",iconName:"comment-medical",icon:[512,512,[],"f7f5","M256 32C114.62 32 0 125.12 0 240c0 49.56 21.41 95 57 130.74C44.46 421.05 2.7 466 2.2 466.5A8 8 0 0 0 8 480c66.26 0 116-31.75 140.6-51.38A304.66 304.66 0 0 0 256 448c141.39 0 256-93.12 256-208S397.39 32 256 32zm96 232a8 8 0 0 1-8 8h-56v56a8 8 0 0 1-8 8h-48a8 8 0 0 1-8-8v-56h-56a8 8 0 0 1-8-8v-48a8 8 0 0 1 8-8h56v-56a8 8 0 0 1 8-8h48a8 8 0 0 1 8 8v56h56a8 8 0 0 1 8 8z"]},lr={prefix:"fas",iconName:"comment-slash",icon:[640,512,[],"f4b3","M64 240c0 49.6 21.4 95 57 130.7-12.6 50.3-54.3 95.2-54.8 95.8-2.2 2.3-2.8 5.7-1.5 8.7 1.3 2.9 4.1 4.8 7.3 4.8 66.3 0 116-31.8 140.6-51.4 32.7 12.3 69 19.4 107.4 19.4 27.4 0 53.7-3.6 78.4-10L72.9 186.4c-5.6 17.1-8.9 35-8.9 53.6zm569.8 218.1l-114.4-88.4C554.6 334.1 576 289.2 576 240c0-114.9-114.6-208-256-208-65.1 0-124.2 20.1-169.4 52.7L45.5 3.4C38.5-2 28.5-.8 23 6.2L3.4 31.4c-5.4 7-4.2 17 2.8 22.4l588.4 454.7c7 5.4 17 4.2 22.5-2.8l19.6-25.3c5.4-6.8 4.1-16.9-2.9-22.3z"]},cr={prefix:"fas",iconName:"comments",icon:[576,512,[],"f086","M416 192c0-88.4-93.1-160-208-160S0 103.6 0 192c0 34.3 14.1 65.9 38 92-13.4 30.2-35.5 54.2-35.8 54.5-2.2 2.3-2.8 5.7-1.5 8.7S4.8 352 8 352c36.6 0 66.9-12.3 88.7-25 32.2 15.7 70.3 25 111.3 25 114.9 0 208-71.6 208-160zm122 220c23.9-26 38-57.7 38-92 0-66.9-53.5-124.2-129.3-148.1.9 6.6 1.3 13.3 1.3 20.1 0 105.9-107.7 192-240 192-10.8 0-21.3-.8-31.7-1.9C207.8 439.6 281.8 480 368 480c41 0 79.1-9.2 111.3-25 21.8 12.7 52.1 25 88.7 25 3.2 0 6.1-1.9 7.3-4.8 1.3-2.9.7-6.3-1.5-8.7-.3-.3-22.4-24.2-35.8-54.5z"]},ur={prefix:"fas",iconName:"comments-dollar",icon:[576,512,[],"f653","M416 192c0-88.37-93.12-160-208-160S0 103.63 0 192c0 34.27 14.13 65.95 37.97 91.98C24.61 314.22 2.52 338.16 2.2 338.5A7.995 7.995 0 0 0 8 352c36.58 0 66.93-12.25 88.73-24.98C128.93 342.76 167.02 352 208 352c114.88 0 208-71.63 208-160zm-224 96v-16.29c-11.29-.58-22.27-4.52-31.37-11.35-3.9-2.93-4.1-8.77-.57-12.14l11.75-11.21c2.77-2.64 6.89-2.76 10.13-.73 3.87 2.42 8.26 3.72 12.82 3.72h28.11c6.5 0 11.8-5.92 11.8-13.19 0-5.95-3.61-11.19-8.77-12.73l-45-13.5c-18.59-5.58-31.58-23.42-31.58-43.39 0-24.52 19.05-44.44 42.67-45.07V96c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16.29c11.29.58 22.27 4.51 31.37 11.35 3.9 2.93 4.1 8.77.57 12.14l-11.75 11.21c-2.77 2.64-6.89 2.76-10.13.73-3.87-2.43-8.26-3.72-12.82-3.72h-28.11c-6.5 0-11.8 5.92-11.8 13.19 0 5.95 3.61 11.19 8.77 12.73l45 13.5c18.59 5.58 31.58 23.42 31.58 43.39 0 24.53-19.05 44.44-42.67 45.07V288c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8zm346.01 123.99C561.87 385.96 576 354.27 576 320c0-66.94-53.49-124.2-129.33-148.07.86 6.6 1.33 13.29 1.33 20.07 0 105.87-107.66 192-240 192-10.78 0-21.32-.77-31.73-1.88C207.8 439.63 281.77 480 368 480c40.98 0 79.07-9.24 111.27-24.98C501.07 467.75 531.42 480 568 480c3.2 0 6.09-1.91 7.34-4.84 1.27-2.94.66-6.34-1.55-8.67-.31-.33-22.42-24.24-35.78-54.5z"]},hr={prefix:"fas",iconName:"compact-disc",icon:[496,512,[],"f51f","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM88 256H56c0-105.9 86.1-192 192-192v32c-88.2 0-160 71.8-160 160zm160 96c-53 0-96-43-96-96s43-96 96-96 96 43 96 96-43 96-96 96zm0-128c-17.7 0-32 14.3-32 32s14.3 32 32 32 32-14.3 32-32-14.3-32-32-32z"]},dr={prefix:"fas",iconName:"compass",icon:[496,512,[],"f14e","M225.38 233.37c-12.5 12.5-12.5 32.76 0 45.25 12.49 12.5 32.76 12.5 45.25 0 12.5-12.5 12.5-32.76 0-45.25-12.5-12.49-32.76-12.49-45.25 0zM248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm126.14 148.05L308.17 300.4a31.938 31.938 0 0 1-15.77 15.77l-144.34 65.97c-16.65 7.61-33.81-9.55-26.2-26.2l65.98-144.35a31.938 31.938 0 0 1 15.77-15.77l144.34-65.97c16.65-7.6 33.8 9.55 26.19 26.2z"]},pr={prefix:"fas",iconName:"compress",icon:[448,512,[],"f066","M436 192H312c-13.3 0-24-10.7-24-24V44c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v84h84c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12zm-276-24V44c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12v84H12c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h124c13.3 0 24-10.7 24-24zm0 300V344c0-13.3-10.7-24-24-24H12c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h84v84c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12zm192 0v-84h84c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12H312c-13.3 0-24 10.7-24 24v124c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12z"]},gr={prefix:"fas",iconName:"compress-alt",icon:[448,512,[],"f422","M4.686 427.314L104 328l-32.922-31.029C55.958 281.851 66.666 256 88.048 256h112C213.303 256 224 266.745 224 280v112c0 21.382-25.803 32.09-40.922 16.971L152 376l-99.314 99.314c-6.248 6.248-16.379 6.248-22.627 0L4.686 449.941c-6.248-6.248-6.248-16.379 0-22.627zM443.314 84.686L344 184l32.922 31.029c15.12 15.12 4.412 40.971-16.97 40.971h-112C234.697 256 224 245.255 224 232V120c0-21.382 25.803-32.09 40.922-16.971L296 136l99.314-99.314c6.248-6.248 16.379-6.248 22.627 0l25.373 25.373c6.248 6.248 6.248 16.379 0 22.627z"]},fr={prefix:"fas",iconName:"compress-arrows-alt",icon:[512,512,[],"f78c","M200 288H88c-21.4 0-32.1 25.8-17 41l32.9 31-99.2 99.3c-6.2 6.2-6.2 16.4 0 22.6l25.4 25.4c6.2 6.2 16.4 6.2 22.6 0L152 408l31.1 33c15.1 15.1 40.9 4.4 40.9-17V312c0-13.3-10.7-24-24-24zm112-64h112c21.4 0 32.1-25.9 17-41l-33-31 99.3-99.3c6.2-6.2 6.2-16.4 0-22.6L481.9 4.7c-6.2-6.2-16.4-6.2-22.6 0L360 104l-31.1-33C313.8 55.9 288 66.6 288 88v112c0 13.3 10.7 24 24 24zm96 136l33-31.1c15.1-15.1 4.4-40.9-17-40.9H312c-13.3 0-24 10.7-24 24v112c0 21.4 25.9 32.1 41 17l31-32.9 99.3 99.3c6.2 6.2 16.4 6.2 22.6 0l25.4-25.4c6.2-6.2 6.2-16.4 0-22.6L408 360zM183 71.1L152 104 52.7 4.7c-6.2-6.2-16.4-6.2-22.6 0L4.7 30.1c-6.2 6.2-6.2 16.4 0 22.6L104 152l-33 31.1C55.9 198.2 66.6 224 88 224h112c13.3 0 24-10.7 24-24V88c0-21.3-25.9-32-41-16.9z"]},mr={prefix:"fas",iconName:"concierge-bell",icon:[512,512,[],"f562","M288 130.54V112h16c8.84 0 16-7.16 16-16V80c0-8.84-7.16-16-16-16h-96c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h16v18.54C115.49 146.11 32 239.18 32 352h448c0-112.82-83.49-205.89-192-221.46zM496 384H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h480c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},vr={prefix:"fas",iconName:"cookie",icon:[512,512,[],"f563","M510.37 254.79l-12.08-76.26a132.493 132.493 0 0 0-37.16-72.95l-54.76-54.75c-19.73-19.72-45.18-32.7-72.71-37.05l-76.7-12.15c-27.51-4.36-55.69.11-80.52 12.76L107.32 49.6a132.25 132.25 0 0 0-57.79 57.8l-35.1 68.88a132.602 132.602 0 0 0-12.82 80.94l12.08 76.27a132.493 132.493 0 0 0 37.16 72.95l54.76 54.75a132.087 132.087 0 0 0 72.71 37.05l76.7 12.14c27.51 4.36 55.69-.11 80.52-12.75l69.12-35.21a132.302 132.302 0 0 0 57.79-57.8l35.1-68.87c12.71-24.96 17.2-53.3 12.82-80.96zM176 368c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm32-160c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm160 128c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Cr={prefix:"fas",iconName:"cookie-bite",icon:[512,512,[],"f564","M510.52 255.82c-69.97-.85-126.47-57.69-126.47-127.86-70.17 0-127-56.49-127.86-126.45-27.26-4.14-55.13.3-79.72 12.82l-69.13 35.22a132.221 132.221 0 0 0-57.79 57.81l-35.1 68.88a132.645 132.645 0 0 0-12.82 80.95l12.08 76.27a132.521 132.521 0 0 0 37.16 72.96l54.77 54.76a132.036 132.036 0 0 0 72.71 37.06l76.71 12.15c27.51 4.36 55.7-.11 80.53-12.76l69.13-35.21a132.273 132.273 0 0 0 57.79-57.81l35.1-68.88c12.56-24.64 17.01-52.58 12.91-79.91zM176 368c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm32-160c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm160 128c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},yr={prefix:"fas",iconName:"copy",icon:[448,512,[],"f0c5","M320 448v40c0 13.255-10.745 24-24 24H24c-13.255 0-24-10.745-24-24V120c0-13.255 10.745-24 24-24h72v296c0 30.879 25.121 56 56 56h168zm0-344V0H152c-13.255 0-24 10.745-24 24v368c0 13.255 10.745 24 24 24h272c13.255 0 24-10.745 24-24V128H344c-13.2 0-24-10.8-24-24zm120.971-31.029L375.029 7.029A24 24 0 0 0 358.059 0H352v96h96v-6.059a24 24 0 0 0-7.029-16.97z"]},wr={prefix:"fas",iconName:"copyright",icon:[512,512,[],"f1f9","M256 8C119.033 8 8 119.033 8 256s111.033 248 248 248 248-111.033 248-248S392.967 8 256 8zm117.134 346.753c-1.592 1.867-39.776 45.731-109.851 45.731-84.692 0-144.484-63.26-144.484-145.567 0-81.303 62.004-143.401 143.762-143.401 66.957 0 101.965 37.315 103.422 38.904a12 12 0 0 1 1.238 14.623l-22.38 34.655c-4.049 6.267-12.774 7.351-18.234 2.295-.233-.214-26.529-23.88-61.88-23.88-46.116 0-73.916 33.575-73.916 76.082 0 39.602 25.514 79.692 74.277 79.692 38.697 0 65.28-28.338 65.544-28.625 5.132-5.565 14.059-5.033 18.508 1.053l24.547 33.572a12.001 12.001 0 0 1-.553 14.866z"]},Sr={prefix:"fas",iconName:"couch",icon:[640,512,[],"f4b8","M160 224v64h320v-64c0-35.3 28.7-64 64-64h32c0-53-43-96-96-96H160c-53 0-96 43-96 96h32c35.3 0 64 28.7 64 64zm416-32h-32c-17.7 0-32 14.3-32 32v96H128v-96c0-17.7-14.3-32-32-32H64c-35.3 0-64 28.7-64 64 0 23.6 13 44 32 55.1V432c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16v-16h384v16c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16V311.1c19-11.1 32-31.5 32-55.1 0-35.3-28.7-64-64-64z"]},br={prefix:"fas",iconName:"credit-card",icon:[576,512,[],"f09d","M0 432c0 26.5 21.5 48 48 48h480c26.5 0 48-21.5 48-48V256H0v176zm192-68c0-6.6 5.4-12 12-12h136c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H204c-6.6 0-12-5.4-12-12v-40zm-128 0c0-6.6 5.4-12 12-12h72c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H76c-6.6 0-12-5.4-12-12v-40zM576 80v48H0V80c0-26.5 21.5-48 48-48h480c26.5 0 48 21.5 48 48z"]},Er={prefix:"fas",iconName:"crop",icon:[512,512,[],"f125","M488 352h-40V109.25l59.31-59.31c6.25-6.25 6.25-16.38 0-22.63L484.69 4.69c-6.25-6.25-16.38-6.25-22.63 0L402.75 64H192v96h114.75L160 306.75V24c0-13.26-10.75-24-24-24H88C74.75 0 64 10.74 64 24v40H24C10.75 64 0 74.74 0 88v48c0 13.25 10.75 24 24 24h40v264c0 13.25 10.75 24 24 24h232v-96H205.25L352 205.25V488c0 13.25 10.75 24 24 24h48c13.25 0 24-10.75 24-24v-40h40c13.25 0 24-10.75 24-24v-48c0-13.26-10.75-24-24-24z"]},Ar={prefix:"fas",iconName:"crop-alt",icon:[512,512,[],"f565","M488 352h-40V96c0-17.67-14.33-32-32-32H192v96h160v328c0 13.25 10.75 24 24 24h48c13.25 0 24-10.75 24-24v-40h40c13.25 0 24-10.75 24-24v-48c0-13.26-10.75-24-24-24zM160 24c0-13.26-10.75-24-24-24H88C74.75 0 64 10.74 64 24v40H24C10.75 64 0 74.74 0 88v48c0 13.25 10.75 24 24 24h40v256c0 17.67 14.33 32 32 32h224v-96H160V24z"]},Tr={prefix:"fas",iconName:"cross",icon:[384,512,[],"f654","M352 128h-96V32c0-17.67-14.33-32-32-32h-64c-17.67 0-32 14.33-32 32v96H32c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h96v224c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32V256h96c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32z"]},Mr={prefix:"fas",iconName:"crosshairs",icon:[512,512,[],"f05b","M500 224h-30.364C455.724 130.325 381.675 56.276 288 42.364V12c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v30.364C130.325 56.276 56.276 130.325 42.364 224H12c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h30.364C56.276 381.675 130.325 455.724 224 469.636V500c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-30.364C381.675 455.724 455.724 381.675 469.636 288H500c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12zM288 404.634V364c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40.634C165.826 392.232 119.783 346.243 107.366 288H148c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-40.634C119.768 165.826 165.757 119.783 224 107.366V148c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-40.634C346.174 119.768 392.217 165.757 404.634 224H364c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40.634C392.232 346.174 346.243 392.217 288 404.634zM288 256c0 17.673-14.327 32-32 32s-32-14.327-32-32c0-17.673 14.327-32 32-32s32 14.327 32 32z"]},Rr={prefix:"fas",iconName:"crow",icon:[640,512,[],"f520","M544 32h-16.36C513.04 12.68 490.09 0 464 0c-44.18 0-80 35.82-80 80v20.98L12.09 393.57A30.216 30.216 0 0 0 0 417.74c0 22.46 23.64 37.07 43.73 27.03L165.27 384h96.49l44.41 120.1c2.27 6.23 9.15 9.44 15.38 7.17l22.55-8.21c6.23-2.27 9.44-9.15 7.17-15.38L312.94 384H352c1.91 0 3.76-.23 5.66-.29l44.51 120.38c2.27 6.23 9.15 9.44 15.38 7.17l22.55-8.21c6.23-2.27 9.44-9.15 7.17-15.38l-41.24-111.53C485.74 352.8 544 279.26 544 192v-80l96-16c0-35.35-42.98-64-96-64zm-80 72c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24z"]},_r={prefix:"fas",iconName:"crown",icon:[640,512,[],"f521","M528 448H112c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h416c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm64-320c-26.5 0-48 21.5-48 48 0 7.1 1.6 13.7 4.4 19.8L476 239.2c-15.4 9.2-35.3 4-44.2-11.6L350.3 85C361 76.2 368 63 368 48c0-26.5-21.5-48-48-48s-48 21.5-48 48c0 15 7 28.2 17.7 37l-81.5 142.6c-8.9 15.6-28.9 20.8-44.2 11.6l-72.3-43.4c2.7-6 4.4-12.7 4.4-19.8 0-26.5-21.5-48-48-48S0 149.5 0 176s21.5 48 48 48c2.6 0 5.2-.4 7.7-.8L128 416h384l72.3-192.8c2.5.4 5.1.8 7.7.8 26.5 0 48-21.5 48-48s-21.5-48-48-48z"]},Pr={prefix:"fas",iconName:"crutch",icon:[512,512,[],"f7f7","M507.31 185.71l-181-181a16 16 0 0 0-22.62 0L281 27.31a16 16 0 0 0 0 22.63l181 181a16 16 0 0 0 22.63 0l22.62-22.63a16 16 0 0 0 .06-22.6zm-179.54 66.41l-67.89-67.89 55.1-55.1-45.25-45.25-109.67 109.67a96.08 96.08 0 0 0-25.67 46.29L106.65 360.1l-102 102a16 16 0 0 0 0 22.63l22.62 22.62a16 16 0 0 0 22.63 0l102-102 120.25-27.75a95.88 95.88 0 0 0 46.29-25.65l109.68-109.68L382.87 197zm-54.57 54.57a32 32 0 0 1-15.45 8.54l-79.3 18.32 18.3-79.3a32.22 32.22 0 0 1 8.56-15.45l9.31-9.31 67.89 67.89z"]},xr={prefix:"fas",iconName:"cube",icon:[512,512,[],"f1b2","M239.1 6.3l-208 78c-18.7 7-31.1 25-31.1 45v225.1c0 18.2 10.3 34.8 26.5 42.9l208 104c13.5 6.8 29.4 6.8 42.9 0l208-104c16.3-8.1 26.5-24.8 26.5-42.9V129.3c0-20-12.4-37.9-31.1-44.9l-208-78C262 2.2 250 2.2 239.1 6.3zM256 68.4l192 72v1.1l-192 78-192-78v-1.1l192-72zm32 356V275.5l160-65v133.9l-160 80z"]},Dr={prefix:"fas",iconName:"cubes",icon:[512,512,[],"f1b3","M488.6 250.2L392 214V105.5c0-15-9.3-28.4-23.4-33.7l-100-37.5c-8.1-3.1-17.1-3.1-25.3 0l-100 37.5c-14.1 5.3-23.4 18.7-23.4 33.7V214l-96.6 36.2C9.3 255.5 0 268.9 0 283.9V394c0 13.6 7.7 26.1 19.9 32.2l100 50c10.1 5.1 22.1 5.1 32.2 0l103.9-52 103.9 52c10.1 5.1 22.1 5.1 32.2 0l100-50c12.2-6.1 19.9-18.6 19.9-32.2V283.9c0-15-9.3-28.4-23.4-33.7zM358 214.8l-85 31.9v-68.2l85-37v73.3zM154 104.1l102-38.2 102 38.2v.6l-102 41.4-102-41.4v-.6zm84 291.1l-85 42.5v-79.1l85-38.8v75.4zm0-112l-102 41.4-102-41.4v-.6l102-38.2 102 38.2v.6zm240 112l-85 42.5v-79.1l85-38.8v75.4zm0-112l-102 41.4-102-41.4v-.6l102-38.2 102 38.2v.6z"]},Ir={prefix:"fas",iconName:"cut",icon:[448,512,[],"f0c4","M278.06 256L444.48 89.57c4.69-4.69 4.69-12.29 0-16.97-32.8-32.8-85.99-32.8-118.79 0L210.18 188.12l-24.86-24.86c4.31-10.92 6.68-22.81 6.68-35.26 0-53.02-42.98-96-96-96S0 74.98 0 128s42.98 96 96 96c4.54 0 8.99-.32 13.36-.93L142.29 256l-32.93 32.93c-4.37-.61-8.83-.93-13.36-.93-53.02 0-96 42.98-96 96s42.98 96 96 96 96-42.98 96-96c0-12.45-2.37-24.34-6.68-35.26l24.86-24.86L325.69 439.4c32.8 32.8 85.99 32.8 118.79 0 4.69-4.68 4.69-12.28 0-16.97L278.06 256zM96 160c-17.64 0-32-14.36-32-32s14.36-32 32-32 32 14.36 32 32-14.36 32-32 32zm0 256c-17.64 0-32-14.36-32-32s14.36-32 32-32 32 14.36 32 32-14.36 32-32 32z"]},Lr={prefix:"fas",iconName:"database",icon:[448,512,[],"f1c0","M448 73.143v45.714C448 159.143 347.667 192 224 192S0 159.143 0 118.857V73.143C0 32.857 100.333 0 224 0s224 32.857 224 73.143zM448 176v102.857C448 319.143 347.667 352 224 352S0 319.143 0 278.857V176c48.125 33.143 136.208 48.572 224 48.572S399.874 209.143 448 176zm0 160v102.857C448 479.143 347.667 512 224 512S0 479.143 0 438.857V336c48.125 33.143 136.208 48.572 224 48.572S399.874 369.143 448 336z"]},Nr={prefix:"fas",iconName:"deaf",icon:[512,512,[],"f2a4","M216 260c0 15.464-12.536 28-28 28s-28-12.536-28-28c0-44.112 35.888-80 80-80s80 35.888 80 80c0 15.464-12.536 28-28 28s-28-12.536-28-28c0-13.234-10.767-24-24-24s-24 10.766-24 24zm24-176c-97.047 0-176 78.953-176 176 0 15.464 12.536 28 28 28s28-12.536 28-28c0-66.168 53.832-120 120-120s120 53.832 120 120c0 75.164-71.009 70.311-71.997 143.622L288 404c0 28.673-23.327 52-52 52-15.464 0-28 12.536-28 28s12.536 28 28 28c59.475 0 107.876-48.328 108-107.774.595-34.428 72-48.24 72-144.226 0-97.047-78.953-176-176-176zm268.485-52.201L480.2 3.515c-4.687-4.686-12.284-4.686-16.971 0L376.2 90.544c-4.686 4.686-4.686 12.284 0 16.971l28.285 28.285c4.686 4.686 12.284 4.686 16.97 0l87.03-87.029c4.687-4.688 4.687-12.286 0-16.972zM168.97 314.745c-4.686-4.686-12.284-4.686-16.97 0L3.515 463.23c-4.686 4.686-4.686 12.284 0 16.971L31.8 508.485c4.687 4.686 12.284 4.686 16.971 0L197.256 360c4.686-4.686 4.686-12.284 0-16.971l-28.286-28.284z"]},Or={prefix:"fas",iconName:"democrat",icon:[640,512,[],"f747","M637.3 256.9l-19.6-29.4c-28.2-42.3-75.3-67.5-126.1-67.5H256l-81.2-81.2c20.1-20.1 22.6-51.1 7.5-73.9-3.4-5.2-10.8-5.9-15.2-1.5l-41.8 41.8L82.4 2.4c-3.6-3.6-9.6-3-12.4 1.2-12.3 18.6-10.3 44 6.1 60.4 3.3 3.3 7.3 5.3 11.3 7.5-2.2 1.7-4.7 3.1-6.4 5.4L6.4 176.2c-7.3 9.7-8.4 22.7-3 33.5l14.3 28.6c5.4 10.8 16.5 17.7 28.6 17.7h31c8.5 0 16.6-3.4 22.6-9.4L138 212l54 108h352v-77.8c16.2 12.2 18.3 17.6 40.1 50.3 4.9 7.4 14.8 9.3 22.2 4.4l26.6-17.7c7.3-5 9.3-14.9 4.4-22.3zm-341.1-13.6l-16.5 16.1 3.9 22.7c.7 4.1-3.6 7.2-7.2 5.3L256 276.7l-20.4 10.7c-3.6 1.9-7.9-1.2-7.2-5.3l3.9-22.7-16.5-16.1c-3-2.9-1.3-7.9 2.8-8.5l22.8-3.3 10.2-20.7c1.8-3.7 7.1-3.7 9 0l10.2 20.7 22.8 3.3c4 .6 5.6 5.6 2.6 8.5zm112 0l-16.5 16.1 3.9 22.7c.7 4.1-3.6 7.2-7.2 5.3L368 276.7l-20.4 10.7c-3.6 1.9-7.9-1.2-7.2-5.3l3.9-22.7-16.5-16.1c-3-2.9-1.3-7.9 2.8-8.5l22.8-3.3 10.2-20.7c1.8-3.7 7.1-3.7 9 0l10.2 20.7 22.8 3.3c4 .6 5.6 5.6 2.6 8.5zm112 0l-16.5 16.1 3.9 22.7c.7 4.1-3.6 7.2-7.2 5.3L480 276.7l-20.4 10.7c-3.6 1.9-7.9-1.2-7.2-5.3l3.9-22.7-16.5-16.1c-3-2.9-1.3-7.9 2.8-8.5l22.8-3.3 10.2-20.7c1.8-3.7 7.1-3.7 9 0l10.2 20.7 22.8 3.3c4 .6 5.6 5.6 2.6 8.5zM192 496c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16v-80h160v80c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16V352H192v144z"]},Fr={prefix:"fas",iconName:"desktop",icon:[576,512,[],"f108","M528 0H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h192l-16 48h-72c-13.3 0-24 10.7-24 24s10.7 24 24 24h272c13.3 0 24-10.7 24-24s-10.7-24-24-24h-72l-16-48h192c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zm-16 352H64V64h448v288z"]},kr={prefix:"fas",iconName:"dharmachakra",icon:[512,512,[],"f655","M495 225.06l-17.22 1.08c-5.27-39.49-20.79-75.64-43.86-105.84l12.95-11.43c6.92-6.11 7.25-16.79.73-23.31L426.44 64.4c-6.53-6.53-17.21-6.19-23.31.73L391.7 78.07c-30.2-23.06-66.35-38.58-105.83-43.86L286.94 17c.58-9.21-6.74-17-15.97-17h-29.94c-9.23 0-16.54 7.79-15.97 17l1.08 17.22c-39.49 5.27-75.64 20.79-105.83 43.86l-11.43-12.95c-6.11-6.92-16.79-7.25-23.31-.73L64.4 85.56c-6.53 6.53-6.19 17.21.73 23.31l12.95 11.43c-23.06 30.2-38.58 66.35-43.86 105.84L17 225.06c-9.21-.58-17 6.74-17 15.97v29.94c0 9.23 7.79 16.54 17 15.97l17.22-1.08c5.27 39.49 20.79 75.64 43.86 105.83l-12.95 11.43c-6.92 6.11-7.25 16.79-.73 23.31l21.17 21.17c6.53 6.53 17.21 6.19 23.31-.73l11.43-12.95c30.2 23.06 66.35 38.58 105.84 43.86L225.06 495c-.58 9.21 6.74 17 15.97 17h29.94c9.23 0 16.54-7.79 15.97-17l-1.08-17.22c39.49-5.27 75.64-20.79 105.84-43.86l11.43 12.95c6.11 6.92 16.79 7.25 23.31.73l21.17-21.17c6.53-6.53 6.19-17.21-.73-23.31l-12.95-11.43c23.06-30.2 38.58-66.35 43.86-105.83l17.22 1.08c9.21.58 17-6.74 17-15.97v-29.94c-.01-9.23-7.8-16.54-17.01-15.97zM281.84 98.61c24.81 4.07 47.63 13.66 67.23 27.78l-42.62 48.29c-8.73-5.44-18.32-9.54-28.62-11.95l4.01-64.12zm-51.68 0l4.01 64.12c-10.29 2.41-19.89 6.52-28.62 11.95l-42.62-48.29c19.6-14.12 42.42-23.71 67.23-27.78zm-103.77 64.33l48.3 42.61c-5.44 8.73-9.54 18.33-11.96 28.62l-64.12-4.01c4.07-24.81 13.66-47.62 27.78-67.22zm-27.78 118.9l64.12-4.01c2.41 10.29 6.52 19.89 11.95 28.62l-48.29 42.62c-14.12-19.6-23.71-42.42-27.78-67.23zm131.55 131.55c-24.81-4.07-47.63-13.66-67.23-27.78l42.61-48.3c8.73 5.44 18.33 9.54 28.62 11.96l-4 64.12zM256 288c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm25.84 125.39l-4.01-64.12c10.29-2.41 19.89-6.52 28.62-11.96l42.61 48.3c-19.6 14.12-42.41 23.71-67.22 27.78zm103.77-64.33l-48.29-42.62c5.44-8.73 9.54-18.32 11.95-28.62l64.12 4.01c-4.07 24.82-13.66 47.64-27.78 67.23zm-36.34-114.89c-2.41-10.29-6.52-19.89-11.96-28.62l48.3-42.61c14.12 19.6 23.71 42.42 27.78 67.23l-64.12 4z"]},Gr={prefix:"fas",iconName:"diagnoses",icon:[640,512,[],"f470","M496 256c8.8 0 16-7.2 16-16s-7.2-16-16-16-16 7.2-16 16 7.2 16 16 16zm-176-80c48.5 0 88-39.5 88-88S368.5 0 320 0s-88 39.5-88 88 39.5 88 88 88zM59.8 364c10.2 15.3 29.3 17.8 42.9 9.8 16.2-9.6 56.2-31.7 105.3-48.6V416h224v-90.7c49.1 16.8 89.1 39 105.3 48.6 13.6 8 32.7 5.3 42.9-9.8l17.8-26.7c8.8-13.2 7.6-34.6-10-45.1-11.9-7.1-29.7-17-51.1-27.4-28.1 46.1-99.4 17.8-87.7-35.1C409.3 217.2 365.1 208 320 208c-57 0-112.9 14.5-160 32.2-.2 40.2-47.6 63.3-79.2 36-11.2 6-21.3 11.6-28.7 16-17.6 10.5-18.8 31.8-10 45.1L59.8 364zM368 344c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm-96-96c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm-160 8c8.8 0 16-7.2 16-16s-7.2-16-16-16-16 7.2-16 16 7.2 16 16 16zm512 192H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h608c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16z"]},Vr={prefix:"fas",iconName:"dice",icon:[640,512,[],"f522","M592 192H473.26c12.69 29.59 7.12 65.2-17 89.32L320 417.58V464c0 26.51 21.49 48 48 48h224c26.51 0 48-21.49 48-48V240c0-26.51-21.49-48-48-48zM480 376c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm-46.37-186.7L258.7 14.37c-19.16-19.16-50.23-19.16-69.39 0L14.37 189.3c-19.16 19.16-19.16 50.23 0 69.39L189.3 433.63c19.16 19.16 50.23 19.16 69.39 0L433.63 258.7c19.16-19.17 19.16-50.24 0-69.4zM96 248c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm128 128c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm0-128c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm0-128c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm128 128c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24z"]},Hr={prefix:"fas",iconName:"dice-d20",icon:[480,512,[],"f6cf","M106.75 215.06L1.2 370.95c-3.08 5 .1 11.5 5.93 12.14l208.26 22.07-108.64-190.1zM7.41 315.43L82.7 193.08 6.06 147.1c-2.67-1.6-6.06.32-6.06 3.43v162.81c0 4.03 5.29 5.53 7.41 2.09zM18.25 423.6l194.4 87.66c5.3 2.45 11.35-1.43 11.35-7.26v-65.67l-203.55-22.3c-4.45-.5-6.23 5.59-2.2 7.57zm81.22-257.78L179.4 22.88c4.34-7.06-3.59-15.25-10.78-11.14L17.81 110.35c-2.47 1.62-2.39 5.26.13 6.78l81.53 48.69zM240 176h109.21L253.63 7.62C250.5 2.54 245.25 0 240 0s-10.5 2.54-13.63 7.62L130.79 176H240zm233.94-28.9l-76.64 45.99 75.29 122.35c2.11 3.44 7.41 1.94 7.41-2.1V150.53c0-3.11-3.39-5.03-6.06-3.43zm-93.41 18.72l81.53-48.7c2.53-1.52 2.6-5.16.13-6.78l-150.81-98.6c-7.19-4.11-15.12 4.08-10.78 11.14l79.93 142.94zm79.02 250.21L256 438.32v65.67c0 5.84 6.05 9.71 11.35 7.26l194.4-87.66c4.03-1.97 2.25-8.06-2.2-7.56zm-86.3-200.97l-108.63 190.1 208.26-22.07c5.83-.65 9.01-7.14 5.93-12.14L373.25 215.06zM240 208H139.57L240 383.75 340.43 208H240z"]},Br={prefix:"fas",iconName:"dice-d6",icon:[448,512,[],"f6d1","M422.19 109.95L256.21 9.07c-19.91-12.1-44.52-12.1-64.43 0L25.81 109.95c-5.32 3.23-5.29 11.27.06 14.46L224 242.55l198.14-118.14c5.35-3.19 5.38-11.22.05-14.46zm13.84 44.63L240 271.46v223.82c0 12.88 13.39 20.91 24.05 14.43l152.16-92.48c19.68-11.96 31.79-33.94 31.79-57.7v-197.7c0-6.41-6.64-10.43-11.97-7.25zM0 161.83v197.7c0 23.77 12.11 45.74 31.79 57.7l152.16 92.47c10.67 6.48 24.05-1.54 24.05-14.43V271.46L11.97 154.58C6.64 151.4 0 155.42 0 161.83z"]},zr={prefix:"fas",iconName:"dice-five",icon:[448,512,[],"f523","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM128 384c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm96 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm96 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Ur={prefix:"fas",iconName:"dice-four",icon:[448,512,[],"f524","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM128 384c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm192 192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Wr={prefix:"fas",iconName:"dice-one",icon:[448,512,[],"f525","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM224 288c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},jr={prefix:"fas",iconName:"dice-six",icon:[448,512,[],"f526","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM128 384c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm192 192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Kr={prefix:"fas",iconName:"dice-three",icon:[448,512,[],"f527","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM128 192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm96 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm96 96c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},$r={prefix:"fas",iconName:"dice-two",icon:[448,512,[],"f528","M384 32H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h320c35.35 0 64-28.65 64-64V96c0-35.35-28.65-64-64-64zM128 192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm192 192c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},qr={prefix:"fas",iconName:"digital-tachograph",icon:[640,512,[],"f566","M608 96H32c-17.67 0-32 14.33-32 32v256c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V128c0-17.67-14.33-32-32-32zM304 352c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-8c0-4.42 3.58-8 8-8h224c4.42 0 8 3.58 8 8v8zM72 288v-16c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H80c-4.42 0-8-3.58-8-8zm64 0v-16c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8zm64 0v-16c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8zm64 0v-16c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8zm40-64c0 8.84-7.16 16-16 16H80c-8.84 0-16-7.16-16-16v-48c0-8.84 7.16-16 16-16h208c8.84 0 16 7.16 16 16v48zm272 128c0 4.42-3.58 8-8 8H344c-4.42 0-8-3.58-8-8v-8c0-4.42 3.58-8 8-8h224c4.42 0 8 3.58 8 8v8z"]},Yr={prefix:"fas",iconName:"directions",icon:[512,512,[],"f5eb","M502.61 233.32L278.68 9.39c-12.52-12.52-32.83-12.52-45.36 0L9.39 233.32c-12.52 12.53-12.52 32.83 0 45.36l223.93 223.93c12.52 12.53 32.83 12.53 45.36 0l223.93-223.93c12.52-12.53 12.52-32.83 0-45.36zm-100.98 12.56l-84.21 77.73c-5.12 4.73-13.43 1.1-13.43-5.88V264h-96v64c0 4.42-3.58 8-8 8h-32c-4.42 0-8-3.58-8-8v-80c0-17.67 14.33-32 32-32h112v-53.73c0-6.97 8.3-10.61 13.43-5.88l84.21 77.73c3.43 3.17 3.43 8.59 0 11.76z"]},Qr={prefix:"fas",iconName:"disease",icon:[512,512,[],"f7fa","M472.29 195.9l-67.06-23c-19.28-6.6-33.54-20.92-38.14-38.31l-16-60.45c-11.58-43.77-76.57-57.13-110-22.62L195 99.24c-13.26 13.71-33.54 20.93-54.2 19.31l-71.9-5.62c-52-4.07-86.93 44.89-59 82.84l38.54 52.42c11.08 15.07 12.82 33.86 4.64 50.24l-28.43 57C4 396.67 47.46 440.29 98.11 429.23l70-15.28c20.11-4.39 41.45 0 57.07 11.73l54.32 40.83c39.32 29.56 101 7.57 104.45-37.22l4.7-61.86c1.35-17.8 12.8-33.87 30.63-43l62-31.74c44.84-22.96 39.55-80.17-8.99-96.79zM160 256a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm128 96a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm16-128a16 16 0 1 1 16-16 16 16 0 0 1-16 16z"]},Xr={prefix:"fas",iconName:"divide",icon:[448,512,[],"f529","M224 352c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64zm0-192c35.35 0 64-28.65 64-64s-28.65-64-64-64-64 28.65-64 64 28.65 64 64 64zm192 48H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"]},Zr={prefix:"fas",iconName:"dizzy",icon:[496,512,[],"f567","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm-96 206.6l-28.7 28.7c-14.8 14.8-37.8-7.5-22.6-22.6l28.7-28.7-28.7-28.7c-15-15 7.7-37.6 22.6-22.6l28.7 28.7 28.7-28.7c15-15 37.6 7.7 22.6 22.6L174.6 192l28.7 28.7c15.2 15.2-7.9 37.4-22.6 22.6L152 214.6zM248 416c-35.3 0-64-28.7-64-64s28.7-64 64-64 64 28.7 64 64-28.7 64-64 64zm147.3-195.3c15.2 15.2-7.9 37.4-22.6 22.6L344 214.6l-28.7 28.7c-14.8 14.8-37.8-7.5-22.6-22.6l28.7-28.7-28.7-28.7c-15-15 7.7-37.6 22.6-22.6l28.7 28.7 28.7-28.7c15-15 37.6 7.7 22.6 22.6L366.6 192l28.7 28.7z"]},Jr={prefix:"fas",iconName:"dna",icon:[448,512,[],"f471","M.1 494.1c-1.1 9.5 6.3 17.8 15.9 17.8l32.3.1c8.1 0 14.9-5.9 16-13.9.7-4.9 1.8-11.1 3.4-18.1H380c1.6 6.9 2.9 13.2 3.5 18.1 1.1 8 7.9 14 16 13.9l32.3-.1c9.6 0 17.1-8.3 15.9-17.8-4.6-37.9-25.6-129-118.9-207.7-17.6 12.4-37.1 24.2-58.5 35.4 6.2 4.6 11.4 9.4 17 14.2H159.7c21.3-18.1 47-35.6 78.7-51.4C410.5 199.1 442.1 65.8 447.9 17.9 449 8.4 441.6.1 432 .1L399.6 0c-8.1 0-14.9 5.9-16 13.9-.7 4.9-1.8 11.1-3.4 18.1H67.8c-1.6-7-2.7-13.1-3.4-18.1-1.1-8-7.9-14-16-13.9L16.1.1C6.5.1-1 8.4.1 17.9 5.3 60.8 31.4 171.8 160 256 31.5 340.2 5.3 451.2.1 494.1zM224 219.6c-25.1-13.7-46.4-28.4-64.3-43.6h128.5c-17.8 15.2-39.1 30-64.2 43.6zM355.1 96c-5.8 10.4-12.8 21.1-21 32H114c-8.3-10.9-15.3-21.6-21-32h262.1zM92.9 416c5.8-10.4 12.8-21.1 21-32h219.4c8.3 10.9 15.4 21.6 21.2 32H92.9z"]},en={prefix:"fas",iconName:"dog",icon:[576,512,[],"f6d3","M298.06,224,448,277.55V496a16,16,0,0,1-16,16H368a16,16,0,0,1-16-16V384H192V496a16,16,0,0,1-16,16H112a16,16,0,0,1-16-16V282.09C58.84,268.84,32,233.66,32,192a32,32,0,0,1,64,0,32.06,32.06,0,0,0,32,32ZM544,112v32a64,64,0,0,1-64,64H448v35.58L320,197.87V48c0-14.25,17.22-21.39,27.31-11.31L374.59,64h53.63c10.91,0,23.75,7.92,28.62,17.69L464,96h64A16,16,0,0,1,544,112Zm-112,0a16,16,0,1,0-16,16A16,16,0,0,0,432,112Z"]},tn={prefix:"fas",iconName:"dollar-sign",icon:[288,512,[],"f155","M209.2 233.4l-108-31.6C88.7 198.2 80 186.5 80 173.5c0-16.3 13.2-29.5 29.5-29.5h66.3c12.2 0 24.2 3.7 34.2 10.5 6.1 4.1 14.3 3.1 19.5-2l34.8-34c7.1-6.9 6.1-18.4-1.8-24.5C238 74.8 207.4 64.1 176 64V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v48h-2.5C45.8 64-5.4 118.7.5 183.6c4.2 46.1 39.4 83.6 83.8 96.6l102.5 30c12.5 3.7 21.2 15.3 21.2 28.3 0 16.3-13.2 29.5-29.5 29.5h-66.3C100 368 88 364.3 78 357.5c-6.1-4.1-14.3-3.1-19.5 2l-34.8 34c-7.1 6.9-6.1 18.4 1.8 24.5 24.5 19.2 55.1 29.9 86.5 30v48c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-48.2c46.6-.9 90.3-28.6 105.7-72.7 21.5-61.6-14.6-124.8-72.5-141.7z"]},rn={prefix:"fas",iconName:"dolly",icon:[576,512,[],"f472","M294.2 277.7c18 5 34.7 13.4 49.5 24.7l161.5-53.8c8.4-2.8 12.9-11.9 10.1-20.2L454.9 47.2c-2.8-8.4-11.9-12.9-20.2-10.1l-61.1 20.4 33.1 99.4L346 177l-33.1-99.4-61.6 20.5c-8.4 2.8-12.9 11.9-10.1 20.2l53 159.4zm281 48.7L565 296c-2.8-8.4-11.9-12.9-20.2-10.1l-213.5 71.2c-17.2-22-43.6-36.4-73.5-37L158.4 21.9C154 8.8 141.8 0 128 0H16C7.2 0 0 7.2 0 16v32c0 8.8 7.2 16 16 16h88.9l92.2 276.7c-26.1 20.4-41.7 53.6-36 90.5 6.1 39.4 37.9 72.3 77.3 79.2 60.2 10.7 112.3-34.8 113.4-92.6l213.3-71.2c8.3-2.8 12.9-11.8 10.1-20.2zM256 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48z"]},nn={prefix:"fas",iconName:"dolly-flatbed",icon:[640,512,[],"f474","M208 320h384c8.8 0 16-7.2 16-16V48c0-8.8-7.2-16-16-16H448v128l-48-32-48 32V32H208c-8.8 0-16 7.2-16 16v256c0 8.8 7.2 16 16 16zm416 64H128V16c0-8.8-7.2-16-16-16H16C7.2 0 0 7.2 0 16v32c0 8.8 7.2 16 16 16h48v368c0 8.8 7.2 16 16 16h82.9c-1.8 5-2.9 10.4-2.9 16 0 26.5 21.5 48 48 48s48-21.5 48-48c0-5.6-1.2-11-2.9-16H451c-1.8 5-2.9 10.4-2.9 16 0 26.5 21.5 48 48 48s48-21.5 48-48c0-5.6-1.2-11-2.9-16H624c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16z"]},sn={prefix:"fas",iconName:"donate",icon:[512,512,[],"f4b9","M256 416c114.9 0 208-93.1 208-208S370.9 0 256 0 48 93.1 48 208s93.1 208 208 208zM233.8 97.4V80.6c0-9.2 7.4-16.6 16.6-16.6h11.1c9.2 0 16.6 7.4 16.6 16.6v17c15.5.8 30.5 6.1 43 15.4 5.6 4.1 6.2 12.3 1.2 17.1L306 145.6c-3.8 3.7-9.5 3.8-14 1-5.4-3.4-11.4-5.1-17.8-5.1h-38.9c-9 0-16.3 8.2-16.3 18.3 0 8.2 5 15.5 12.1 17.6l62.3 18.7c25.7 7.7 43.7 32.4 43.7 60.1 0 34-26.4 61.5-59.1 62.4v16.8c0 9.2-7.4 16.6-16.6 16.6h-11.1c-9.2 0-16.6-7.4-16.6-16.6v-17c-15.5-.8-30.5-6.1-43-15.4-5.6-4.1-6.2-12.3-1.2-17.1l16.3-15.5c3.8-3.7 9.5-3.8 14-1 5.4 3.4 11.4 5.1 17.8 5.1h38.9c9 0 16.3-8.2 16.3-18.3 0-8.2-5-15.5-12.1-17.6l-62.3-18.7c-25.7-7.7-43.7-32.4-43.7-60.1.1-34 26.4-61.5 59.1-62.4zM480 352h-32.5c-19.6 26-44.6 47.7-73 64h63.8c5.3 0 9.6 3.6 9.6 8v16c0 4.4-4.3 8-9.6 8H73.6c-5.3 0-9.6-3.6-9.6-8v-16c0-4.4 4.3-8 9.6-8h63.8c-28.4-16.3-53.3-38-73-64H32c-17.7 0-32 14.3-32 32v96c0 17.7 14.3 32 32 32h448c17.7 0 32-14.3 32-32v-96c0-17.7-14.3-32-32-32z"]},on={prefix:"fas",iconName:"door-closed",icon:[640,512,[],"f52a","M624 448H512V50.8C512 22.78 490.47 0 464 0H175.99c-26.47 0-48 22.78-48 50.8V448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h608c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM415.99 288c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32c.01 17.67-14.32 32-32 32z"]},an={prefix:"fas",iconName:"door-open",icon:[640,512,[],"f52b","M624 448h-80V113.45C544 86.19 522.47 64 496 64H384v64h96v384h144c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM312.24 1.01l-192 49.74C105.99 54.44 96 67.7 96 82.92V448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h336V33.18c0-21.58-19.56-37.41-39.76-32.17zM264 288c-13.25 0-24-14.33-24-32s10.75-32 24-32 24 14.33 24 32-10.75 32-24 32z"]},ln={prefix:"fas",iconName:"dot-circle",icon:[512,512,[],"f192","M256 8C119.033 8 8 119.033 8 256s111.033 248 248 248 248-111.033 248-248S392.967 8 256 8zm80 248c0 44.112-35.888 80-80 80s-80-35.888-80-80 35.888-80 80-80 80 35.888 80 80z"]},cn={prefix:"fas",iconName:"dove",icon:[512,512,[],"f4ba","M288 167.2v-28.1c-28.2-36.3-47.1-79.3-54.1-125.2-2.1-13.5-19-18.8-27.8-8.3-21.1 24.9-37.7 54.1-48.9 86.5 34.2 38.3 80 64.6 130.8 75.1zM400 64c-44.2 0-80 35.9-80 80.1v59.4C215.6 197.3 127 133 87 41.8c-5.5-12.5-23.2-13.2-29-.9C41.4 76 32 115.2 32 156.6c0 70.8 34.1 136.9 85.1 185.9 13.2 12.7 26.1 23.2 38.9 32.8l-143.9 36C1.4 414-3.4 426.4 2.6 435.7 20 462.6 63 508.2 155.8 512c8 .3 16-2.6 22.1-7.9l65.2-56.1H320c88.4 0 160-71.5 160-159.9V128l32-64H400zm0 96.1c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16z"]},un={prefix:"fas",iconName:"download",icon:[512,512,[],"f019","M216 0h80c13.3 0 24 10.7 24 24v168h87.7c17.8 0 26.7 21.5 14.1 34.1L269.7 378.3c-7.5 7.5-19.8 7.5-27.3 0L90.1 226.1c-12.6-12.6-3.7-34.1 14.1-34.1H192V24c0-13.3 10.7-24 24-24zm296 376v112c0 13.3-10.7 24-24 24H24c-13.3 0-24-10.7-24-24V376c0-13.3 10.7-24 24-24h146.7l49 49c20.1 20.1 52.5 20.1 72.6 0l49-49H488c13.3 0 24 10.7 24 24zm-124 88c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20zm64 0c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20z"]},hn={prefix:"fas",iconName:"drafting-compass",icon:[512,512,[],"f568","M457.01 344.42c-25.05 20.33-52.63 37.18-82.54 49.05l54.38 94.19 53.95 23.04c9.81 4.19 20.89-2.21 22.17-12.8l7.02-58.25-54.98-95.23zm42.49-94.56c4.86-7.67 1.89-17.99-6.05-22.39l-28.07-15.57c-7.48-4.15-16.61-1.46-21.26 5.72C403.01 281.15 332.25 320 256 320c-23.93 0-47.23-4.25-69.41-11.53l67.36-116.68c.7.02 1.34.21 2.04.21s1.35-.19 2.04-.21l51.09 88.5c31.23-8.96 59.56-25.75 82.61-48.92l-51.79-89.71C347.39 128.03 352 112.63 352 96c0-53.02-42.98-96-96-96s-96 42.98-96 96c0 16.63 4.61 32.03 12.05 45.66l-68.3 118.31c-12.55-11.61-23.96-24.59-33.68-39-4.79-7.1-13.97-9.62-21.38-5.33l-27.75 16.07c-7.85 4.54-10.63 14.9-5.64 22.47 15.57 23.64 34.69 44.21 55.98 62.02L0 439.66l7.02 58.25c1.28 10.59 12.36 16.99 22.17 12.8l53.95-23.04 70.8-122.63C186.13 377.28 220.62 384 256 384c99.05 0 190.88-51.01 243.5-134.14zM256 64c17.67 0 32 14.33 32 32s-14.33 32-32 32-32-14.33-32-32 14.33-32 32-32z"]},dn={prefix:"fas",iconName:"dragon",icon:[640,512,[],"f6d5","M18.32 255.78L192 223.96l-91.28 68.69c-10.08 10.08-2.94 27.31 11.31 27.31h222.7c-9.44-26.4-14.73-54.47-14.73-83.38v-42.27l-119.73-87.6c-23.82-15.88-55.29-14.01-77.06 4.59L5.81 227.64c-12.38 10.33-3.45 30.42 12.51 28.14zm556.87 34.1l-100.66-50.31A47.992 47.992 0 0 1 448 196.65v-36.69h64l28.09 22.63c6 6 14.14 9.37 22.63 9.37h30.97a32 32 0 0 0 28.62-17.69l14.31-28.62a32.005 32.005 0 0 0-3.02-33.51l-74.53-99.38C553.02 4.7 543.54 0 533.47 0H296.02c-7.13 0-10.7 8.57-5.66 13.61L352 63.96 292.42 88.8c-5.9 2.95-5.9 11.36 0 14.31L352 127.96v108.62c0 72.08 36.03 139.39 96 179.38-195.59 6.81-344.56 41.01-434.1 60.91C5.78 478.67 0 485.88 0 494.2 0 504 7.95 512 17.76 512h499.08c63.29.01 119.61-47.56 122.99-110.76 2.52-47.28-22.73-90.4-64.64-111.36zM489.18 66.25l45.65 11.41c-2.75 10.91-12.47 18.89-24.13 18.26-12.96-.71-25.85-12.53-21.52-29.67z"]},pn={prefix:"fas",iconName:"draw-polygon",icon:[448,512,[],"f5ee","M384 352c-.35 0-.67.1-1.02.1l-39.2-65.32c5.07-9.17 8.22-19.56 8.22-30.78s-3.14-21.61-8.22-30.78l39.2-65.32c.35.01.67.1 1.02.1 35.35 0 64-28.65 64-64s-28.65-64-64-64c-23.63 0-44.04 12.95-55.12 32H119.12C108.04 44.95 87.63 32 64 32 28.65 32 0 60.65 0 96c0 23.63 12.95 44.04 32 55.12v209.75C12.95 371.96 0 392.37 0 416c0 35.35 28.65 64 64 64 23.63 0 44.04-12.95 55.12-32h209.75c11.09 19.05 31.49 32 55.12 32 35.35 0 64-28.65 64-64 .01-35.35-28.64-64-63.99-64zm-288 8.88V151.12A63.825 63.825 0 0 0 119.12 128h208.36l-38.46 64.1c-.35-.01-.67-.1-1.02-.1-35.35 0-64 28.65-64 64s28.65 64 64 64c.35 0 .67-.1 1.02-.1l38.46 64.1H119.12A63.748 63.748 0 0 0 96 360.88zM272 256c0-8.82 7.18-16 16-16s16 7.18 16 16-7.18 16-16 16-16-7.18-16-16zM400 96c0 8.82-7.18 16-16 16s-16-7.18-16-16 7.18-16 16-16 16 7.18 16 16zM64 80c8.82 0 16 7.18 16 16s-7.18 16-16 16-16-7.18-16-16 7.18-16 16-16zM48 416c0-8.82 7.18-16 16-16s16 7.18 16 16-7.18 16-16 16-16-7.18-16-16zm336 16c-8.82 0-16-7.18-16-16s7.18-16 16-16 16 7.18 16 16-7.18 16-16 16z"]},gn={prefix:"fas",iconName:"drum",icon:[512,512,[],"f569","M431.34 122.05l73.53-47.42a16 16 0 0 0 4.44-22.19l-8.87-13.31a16 16 0 0 0-22.19-4.44l-110.06 71C318.43 96.91 271.22 96 256 96 219.55 96 0 100.55 0 208.15v160.23c0 30.27 27.5 57.68 72 77.86v-101.9a24 24 0 1 1 48 0v118.93c33.05 9.11 71.07 15.06 112 16.73V376.39a24 24 0 1 1 48 0V480c40.93-1.67 78.95-7.62 112-16.73V344.34a24 24 0 1 1 48 0v101.9c44.5-20.18 72-47.59 72-77.86V208.15c0-43.32-35.76-69.76-80.66-86.1zM256 272.24c-114.88 0-208-28.69-208-64.09s93.12-64.08 208-64.08c17.15 0 33.73.71 49.68 1.91l-72.81 47a16 16 0 0 0-4.43 22.19l8.87 13.31a16 16 0 0 0 22.19 4.44l118.64-76.52C430.09 168 464 186.84 464 208.15c0 35.4-93.13 64.09-208 64.09z"]},fn={prefix:"fas",iconName:"drum-steelpan",icon:[576,512,[],"f56a","M288 32C128.94 32 0 89.31 0 160v192c0 70.69 128.94 128 288 128s288-57.31 288-128V160c0-70.69-128.94-128-288-128zm-82.99 158.36c-4.45 16.61-14.54 30.57-28.31 40.48C100.23 217.46 48 190.78 48 160c0-30.16 50.11-56.39 124.04-70.03l25.6 44.34c9.86 17.09 12.48 36.99 7.37 56.05zM288 240c-21.08 0-41.41-1-60.89-2.7 8.06-26.13 32.15-45.3 60.89-45.3s52.83 19.17 60.89 45.3C329.41 239 309.08 240 288 240zm64-144c0 35.29-28.71 64-64 64s-64-28.71-64-64V82.96c20.4-1.88 41.8-2.96 64-2.96s43.6 1.08 64 2.96V96zm46.93 134.9c-13.81-9.91-23.94-23.9-28.4-40.54-5.11-19.06-2.49-38.96 7.38-56.04l25.65-44.42C477.72 103.5 528 129.79 528 160c0 30.83-52.4 57.54-129.07 70.9z"]},mn={prefix:"fas",iconName:"drumstick-bite",icon:[512,512,[],"f6d7","M462.8 49.57a169.44 169.44 0 0 0-239.5 0C187.82 85 160.13 128 160.13 192v85.83l-40.62 40.59c-9.7 9.69-24 11.07-36.78 6a60.33 60.33 0 0 0-65 98.72C33 438.39 54.24 442.7 73.85 438.21c-4.5 19.6-.18 40.83 15.1 56.1a60.35 60.35 0 0 0 98.8-65c-5.09-12.73-3.72-27 6-36.75L234.36 352h85.89a187.87 187.87 0 0 0 61.89-10c-39.64-43.89-39.83-110.23 1.05-151.07 34.38-34.36 86.76-39.46 128.74-16.8 1.3-44.96-14.81-90.28-49.13-124.56z"]},vn={prefix:"fas",iconName:"dumbbell",icon:[640,512,[],"f44b","M104 96H56c-13.3 0-24 10.7-24 24v104H8c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8h24v104c0 13.3 10.7 24 24 24h48c13.3 0 24-10.7 24-24V120c0-13.3-10.7-24-24-24zm528 128h-24V120c0-13.3-10.7-24-24-24h-48c-13.3 0-24 10.7-24 24v272c0 13.3 10.7 24 24 24h48c13.3 0 24-10.7 24-24V288h24c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zM456 32h-48c-13.3 0-24 10.7-24 24v168H256V56c0-13.3-10.7-24-24-24h-48c-13.3 0-24 10.7-24 24v400c0 13.3 10.7 24 24 24h48c13.3 0 24-10.7 24-24V288h128v168c0 13.3 10.7 24 24 24h48c13.3 0 24-10.7 24-24V56c0-13.3-10.7-24-24-24z"]},Cn={prefix:"fas",iconName:"dumpster",icon:[576,512,[],"f793","M560 160c10.4 0 18-9.8 15.5-19.9l-24-96C549.7 37 543.3 32 536 32h-98.9l25.6 128H560zM272 32H171.5l-25.6 128H272V32zm132.5 0H304v128h126.1L404.5 32zM16 160h97.3l25.6-128H40c-7.3 0-13.7 5-15.5 12.1l-24 96C-2 150.2 5.6 160 16 160zm544 64h-20l4-32H32l4 32H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h28l20 160v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16h320v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16l20-160h28c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16z"]},yn={prefix:"fas",iconName:"dumpster-fire",icon:[640,512,[],"f794","M418.7 104.1l.2-.2-14.4-72H304v128h60.8c16.2-19.3 34.2-38.2 53.9-55.8zM272 32H171.5l-25.6 128H272V32zm189.3 72.1c18.2 16.3 35.5 33.7 51.1 51.5 5.7-5.6 11.4-11.1 17.3-16.3l21.3-19 21.3 19c1.1.9 2.1 2.1 3.1 3.1-.1-.8.2-1.5 0-2.3l-24-96C549.7 37 543.3 32 536 32h-98.9l12.3 61.5 11.9 10.6zM16 160h97.3l25.6-128H40c-7.3 0-13.7 5-15.5 12.1l-24 96C-2 150.2 5.6 160 16 160zm324.6 32H32l4 32H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h28l20 160v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16h208.8c-30.2-33.7-48.8-77.9-48.8-126.4 0-35.9 19.9-82.9 52.6-129.6zm210.5-28.8c-14.9 13.3-28.3 27.2-40.2 41.2-19.5-25.8-43.6-52-71-76.4-70.2 62.7-120 144.3-120 193.6 0 87.5 71.6 158.4 160 158.4s160-70.9 160-158.4c.1-36.6-37-112.2-88.8-158.4zm-18.6 229.4c-14.7 10.7-32.9 17-52.5 17-49 0-88.9-33.5-88.9-88 0-27.1 16.5-51 49.4-91.9 4.7 5.6 67.1 88.1 67.1 88.1l39.8-47c2.8 4.8 5.4 9.5 7.7 14 18.6 36.7 10.8 83.6-22.6 107.8z"]},wn={prefix:"fas",iconName:"dungeon",icon:[512,512,[],"f6d9","M128.73 195.32l-82.81-51.76c-8.04-5.02-18.99-2.17-22.93 6.45A254.19 254.19 0 0 0 .54 239.28C-.05 248.37 7.59 256 16.69 256h97.13c7.96 0 14.08-6.25 15.01-14.16 1.09-9.33 3.24-18.33 6.24-26.94 2.56-7.34.25-15.46-6.34-19.58zM319.03 8C298.86 2.82 277.77 0 256 0s-42.86 2.82-63.03 8c-9.17 2.35-13.91 12.6-10.39 21.39l37.47 104.03A16.003 16.003 0 0 0 235.1 144h41.8c6.75 0 12.77-4.23 15.05-10.58l37.47-104.03c3.52-8.79-1.22-19.03-10.39-21.39zM112 288H16c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h96c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16zm0 128H16c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h96c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16zm77.31-283.67l-36.32-90.8c-3.53-8.83-14.13-12.99-22.42-8.31a257.308 257.308 0 0 0-71.61 59.89c-6.06 7.32-3.85 18.48 4.22 23.52l82.93 51.83c6.51 4.07 14.66 2.62 20.11-2.79 5.18-5.15 10.79-9.85 16.79-14.05 6.28-4.41 9.15-12.17 6.3-19.29zM398.18 256h97.13c9.1 0 16.74-7.63 16.15-16.72a254.135 254.135 0 0 0-22.45-89.27c-3.94-8.62-14.89-11.47-22.93-6.45l-82.81 51.76c-6.59 4.12-8.9 12.24-6.34 19.58 3.01 8.61 5.15 17.62 6.24 26.94.93 7.91 7.05 14.16 15.01 14.16zm54.85-162.89a257.308 257.308 0 0 0-71.61-59.89c-8.28-4.68-18.88-.52-22.42 8.31l-36.32 90.8c-2.85 7.12.02 14.88 6.3 19.28 6 4.2 11.61 8.9 16.79 14.05 5.44 5.41 13.6 6.86 20.11 2.79l82.93-51.83c8.07-5.03 10.29-16.19 4.22-23.51zM496 288h-96c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h96c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16zm0 128h-96c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h96c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16zM240 177.62V472c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8V177.62c-5.23-.89-10.52-1.62-16-1.62s-10.77.73-16 1.62zm-64 41.51V472c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8V189.36c-12.78 7.45-23.84 17.47-32 29.77zm128-29.77V472c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8V219.13c-8.16-12.3-19.22-22.32-32-29.77z"]},Sn={prefix:"fas",iconName:"edit",icon:[576,512,[],"f044","M402.6 83.2l90.2 90.2c3.8 3.8 3.8 10 0 13.8L274.4 405.6l-92.8 10.3c-12.4 1.4-22.9-9.1-21.5-21.5l10.3-92.8L388.8 83.2c3.8-3.8 10-3.8 13.8 0zm162-22.9l-48.8-48.8c-15.2-15.2-39.9-15.2-55.2 0l-35.4 35.4c-3.8 3.8-3.8 10 0 13.8l90.2 90.2c3.8 3.8 10 3.8 13.8 0l35.4-35.4c15.2-15.3 15.2-40 0-55.2zM384 346.2V448H64V128h229.8c3.2 0 6.2-1.3 8.5-3.5l40-40c7.6-7.6 2.2-20.5-8.5-20.5H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V306.2c0-10.7-12.9-16-20.5-8.5l-40 40c-2.2 2.3-3.5 5.3-3.5 8.5z"]},bn={prefix:"fas",iconName:"egg",icon:[384,512,[],"f7fb","M192 0C86 0 0 214 0 320s86 192 192 192 192-86 192-192S298 0 192 0z"]},En={prefix:"fas",iconName:"eject",icon:[448,512,[],"f052","M448 384v64c0 17.673-14.327 32-32 32H32c-17.673 0-32-14.327-32-32v-64c0-17.673 14.327-32 32-32h384c17.673 0 32 14.327 32 32zM48.053 320h351.886c41.651 0 63.581-49.674 35.383-80.435L259.383 47.558c-19.014-20.743-51.751-20.744-70.767 0L12.67 239.565C-15.475 270.268 6.324 320 48.053 320z"]},An={prefix:"fas",iconName:"ellipsis-h",icon:[512,512,[],"f141","M328 256c0 39.8-32.2 72-72 72s-72-32.2-72-72 32.2-72 72-72 72 32.2 72 72zm104-72c-39.8 0-72 32.2-72 72s32.2 72 72 72 72-32.2 72-72-32.2-72-72-72zm-352 0c-39.8 0-72 32.2-72 72s32.2 72 72 72 72-32.2 72-72-32.2-72-72-72z"]},Tn={prefix:"fas",iconName:"ellipsis-v",icon:[192,512,[],"f142","M96 184c39.8 0 72 32.2 72 72s-32.2 72-72 72-72-32.2-72-72 32.2-72 72-72zM24 80c0 39.8 32.2 72 72 72s72-32.2 72-72S135.8 8 96 8 24 40.2 24 80zm0 352c0 39.8 32.2 72 72 72s72-32.2 72-72-32.2-72-72-72-72 32.2-72 72z"]},Mn={prefix:"fas",iconName:"envelope",icon:[512,512,[],"f0e0","M502.3 190.8c3.9-3.1 9.7-.2 9.7 4.7V400c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V195.6c0-5 5.7-7.8 9.7-4.7 22.4 17.4 52.1 39.5 154.1 113.6 21.1 15.4 56.7 47.8 92.2 47.6 35.7.3 72-32.8 92.3-47.6 102-74.1 131.6-96.3 154-113.7zM256 320c23.2.4 56.6-29.2 73.4-41.4 132.7-96.3 142.8-104.7 173.4-128.7 5.8-4.5 9.2-11.5 9.2-18.9v-19c0-26.5-21.5-48-48-48H48C21.5 64 0 85.5 0 112v19c0 7.4 3.4 14.3 9.2 18.9 30.6 23.9 40.7 32.4 173.4 128.7 16.8 12.2 50.2 41.8 73.4 41.4z"]},Rn={prefix:"fas",iconName:"envelope-open",icon:[512,512,[],"f2b6","M512 464c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V200.724a48 48 0 0 1 18.387-37.776c24.913-19.529 45.501-35.365 164.2-121.511C199.412 29.17 232.797-.347 256 .003c23.198-.354 56.596 29.172 73.413 41.433 118.687 86.137 139.303 101.995 164.2 121.512A48 48 0 0 1 512 200.724V464zm-65.666-196.605c-2.563-3.728-7.7-4.595-11.339-1.907-22.845 16.873-55.462 40.705-105.582 77.079-16.825 12.266-50.21 41.781-73.413 41.43-23.211.344-56.559-29.143-73.413-41.43-50.114-36.37-82.734-60.204-105.582-77.079-3.639-2.688-8.776-1.821-11.339 1.907l-9.072 13.196a7.998 7.998 0 0 0 1.839 10.967c22.887 16.899 55.454 40.69 105.303 76.868 20.274 14.781 56.524 47.813 92.264 47.573 35.724.242 71.961-32.771 92.263-47.573 49.85-36.179 82.418-59.97 105.303-76.868a7.998 7.998 0 0 0 1.839-10.967l-9.071-13.196z"]},_n={prefix:"fas",iconName:"envelope-open-text",icon:[512,512,[],"f658","M176 216h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16H176c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16zm-16 80c0 8.84 7.16 16 16 16h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16H176c-8.84 0-16 7.16-16 16v16zm96 121.13c-16.42 0-32.84-5.06-46.86-15.19L0 250.86V464c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V250.86L302.86 401.94c-14.02 10.12-30.44 15.19-46.86 15.19zm237.61-254.18c-8.85-6.94-17.24-13.47-29.61-22.81V96c0-26.51-21.49-48-48-48h-77.55c-3.04-2.2-5.87-4.26-9.04-6.56C312.6 29.17 279.2-.35 256 0c-23.2-.35-56.59 29.17-73.41 41.44-3.17 2.3-6 4.36-9.04 6.56H96c-26.51 0-48 21.49-48 48v44.14c-12.37 9.33-20.76 15.87-29.61 22.81A47.995 47.995 0 0 0 0 200.72v10.65l96 69.35V96h320v184.72l96-69.35v-10.65c0-14.74-6.78-28.67-18.39-37.77z"]},Pn={prefix:"fas",iconName:"envelope-square",icon:[448,512,[],"f199","M400 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48V80c0-26.51-21.49-48-48-48zM178.117 262.104C87.429 196.287 88.353 196.121 64 177.167V152c0-13.255 10.745-24 24-24h272c13.255 0 24 10.745 24 24v25.167c-24.371 18.969-23.434 19.124-114.117 84.938-10.5 7.655-31.392 26.12-45.883 25.894-14.503.218-35.367-18.227-45.883-25.895zM384 217.775V360c0 13.255-10.745 24-24 24H88c-13.255 0-24-10.745-24-24V217.775c13.958 10.794 33.329 25.236 95.303 70.214 14.162 10.341 37.975 32.145 64.694 32.01 26.887.134 51.037-22.041 64.72-32.025 61.958-44.965 81.325-59.406 95.283-70.199z"]},xn={prefix:"fas",iconName:"equals",icon:[448,512,[],"f52c","M416 304H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32zm0-192H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"]},Dn={prefix:"fas",iconName:"eraser",icon:[512,512,[],"f12d","M497.941 273.941c18.745-18.745 18.745-49.137 0-67.882l-160-160c-18.745-18.745-49.136-18.746-67.883 0l-256 256c-18.745 18.745-18.745 49.137 0 67.882l96 96A48.004 48.004 0 0 0 144 480h356c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12H355.883l142.058-142.059zm-302.627-62.627l137.373 137.373L265.373 416H150.628l-80-80 124.686-124.686z"]},In={prefix:"fas",iconName:"ethernet",icon:[512,512,[],"f796","M496 192h-48v-48c0-8.8-7.2-16-16-16h-48V80c0-8.8-7.2-16-16-16H144c-8.8 0-16 7.2-16 16v48H80c-8.8 0-16 7.2-16 16v48H16c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16h80V320h32v128h64V320h32v128h64V320h32v128h64V320h32v128h80c8.8 0 16-7.2 16-16V208c0-8.8-7.2-16-16-16z"]},Ln={prefix:"fas",iconName:"euro-sign",icon:[320,512,[],"f153","M310.706 413.765c-1.314-6.63-7.835-10.872-14.424-9.369-10.692 2.439-27.422 5.413-45.426 5.413-56.763 0-101.929-34.79-121.461-85.449h113.689a12 12 0 0 0 11.708-9.369l6.373-28.36c1.686-7.502-4.019-14.631-11.708-14.631H115.22c-1.21-14.328-1.414-28.287.137-42.245H261.95a12 12 0 0 0 11.723-9.434l6.512-29.755c1.638-7.484-4.061-14.566-11.723-14.566H130.184c20.633-44.991 62.69-75.03 117.619-75.03 14.486 0 28.564 2.25 37.851 4.145 6.216 1.268 12.347-2.498 14.002-8.623l11.991-44.368c1.822-6.741-2.465-13.616-9.326-14.917C290.217 34.912 270.71 32 249.635 32 152.451 32 74.03 92.252 45.075 176H12c-6.627 0-12 5.373-12 12v29.755c0 6.627 5.373 12 12 12h21.569c-1.009 13.607-1.181 29.287-.181 42.245H12c-6.627 0-12 5.373-12 12v28.36c0 6.627 5.373 12 12 12h30.114C67.139 414.692 145.264 480 249.635 480c26.301 0 48.562-4.544 61.101-7.788 6.167-1.595 10.027-7.708 8.788-13.957l-8.818-44.49z"]},Nn={prefix:"fas",iconName:"exchange-alt",icon:[512,512,[],"f362","M0 168v-16c0-13.255 10.745-24 24-24h360V80c0-21.367 25.899-32.042 40.971-16.971l80 80c9.372 9.373 9.372 24.569 0 33.941l-80 80C409.956 271.982 384 261.456 384 240v-48H24c-13.255 0-24-10.745-24-24zm488 152H128v-48c0-21.314-25.862-32.08-40.971-16.971l-80 80c-9.372 9.373-9.372 24.569 0 33.941l80 80C102.057 463.997 128 453.437 128 432v-48h360c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24z"]},On={prefix:"fas",iconName:"exclamation",icon:[192,512,[],"f12a","M176 432c0 44.112-35.888 80-80 80s-80-35.888-80-80 35.888-80 80-80 80 35.888 80 80zM25.26 25.199l13.6 272C39.499 309.972 50.041 320 62.83 320h66.34c12.789 0 23.331-10.028 23.97-22.801l13.6-272C167.425 11.49 156.496 0 142.77 0H49.23C35.504 0 24.575 11.49 25.26 25.199z"]},Fn={prefix:"fas",iconName:"exclamation-circle",icon:[512,512,[],"f06a","M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zm-248 50c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"]},kn={prefix:"fas",iconName:"exclamation-triangle",icon:[576,512,[],"f071","M569.517 440.013C587.975 472.007 564.806 512 527.94 512H48.054c-36.937 0-59.999-40.055-41.577-71.987L246.423 23.985c18.467-32.009 64.72-31.951 83.154 0l239.94 416.028zM288 354c-25.405 0-46 20.595-46 46s20.595 46 46 46 46-20.595 46-46-20.595-46-46-46zm-43.673-165.346l7.418 136c.347 6.364 5.609 11.346 11.982 11.346h48.546c6.373 0 11.635-4.982 11.982-11.346l7.418-136c.375-6.874-5.098-12.654-11.982-12.654h-63.383c-6.884 0-12.356 5.78-11.981 12.654z"]},Gn={prefix:"fas",iconName:"expand",icon:[448,512,[],"f065","M0 180V56c0-13.3 10.7-24 24-24h124c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12H64v84c0 6.6-5.4 12-12 12H12c-6.6 0-12-5.4-12-12zM288 44v40c0 6.6 5.4 12 12 12h84v84c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12V56c0-13.3-10.7-24-24-24H300c-6.6 0-12 5.4-12 12zm148 276h-40c-6.6 0-12 5.4-12 12v84h-84c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h124c13.3 0 24-10.7 24-24V332c0-6.6-5.4-12-12-12zM160 468v-40c0-6.6-5.4-12-12-12H64v-84c0-6.6-5.4-12-12-12H12c-6.6 0-12 5.4-12 12v124c0 13.3 10.7 24 24 24h124c6.6 0 12-5.4 12-12z"]},Vn={prefix:"fas",iconName:"expand-alt",icon:[448,512,[],"f424","M212.686 315.314L120 408l32.922 31.029c15.12 15.12 4.412 40.971-16.97 40.971h-112C10.697 480 0 469.255 0 456V344c0-21.382 25.803-32.09 40.922-16.971L72 360l92.686-92.686c6.248-6.248 16.379-6.248 22.627 0l25.373 25.373c6.249 6.248 6.249 16.378 0 22.627zm22.628-118.628L328 104l-32.922-31.029C279.958 57.851 290.666 32 312.048 32h112C437.303 32 448 42.745 448 56v112c0 21.382-25.803 32.09-40.922 16.971L376 152l-92.686 92.686c-6.248 6.248-16.379 6.248-22.627 0l-25.373-25.373c-6.249-6.248-6.249-16.378 0-22.627z"]},Hn={prefix:"fas",iconName:"expand-arrows-alt",icon:[448,512,[],"f31e","M448 344v112a23.94 23.94 0 0 1-24 24H312c-21.39 0-32.09-25.9-17-41l36.2-36.2L224 295.6 116.77 402.9 153 439c15.09 15.1 4.39 41-17 41H24a23.94 23.94 0 0 1-24-24V344c0-21.4 25.89-32.1 41-17l36.19 36.2L184.46 256 77.18 148.7 41 185c-15.1 15.1-41 4.4-41-17V56a23.94 23.94 0 0 1 24-24h112c21.39 0 32.09 25.9 17 41l-36.2 36.2L224 216.4l107.23-107.3L295 73c-15.09-15.1-4.39-41 17-41h112a23.94 23.94 0 0 1 24 24v112c0 21.4-25.89 32.1-41 17l-36.19-36.2L263.54 256l107.28 107.3L407 327.1c15.1-15.2 41-4.5 41 16.9z"]},Bn={prefix:"fas",iconName:"external-link-alt",icon:[512,512,[],"f35d","M432,320H400a16,16,0,0,0-16,16V448H64V128H208a16,16,0,0,0,16-16V80a16,16,0,0,0-16-16H48A48,48,0,0,0,0,112V464a48,48,0,0,0,48,48H400a48,48,0,0,0,48-48V336A16,16,0,0,0,432,320ZM488,0h-128c-21.37,0-32.05,25.91-17,41l35.73,35.73L135,320.37a24,24,0,0,0,0,34L157.67,377a24,24,0,0,0,34,0L435.28,133.32,471,169c15,15,41,4.5,41-17V24A24,24,0,0,0,488,0Z"]},zn={prefix:"fas",iconName:"external-link-square-alt",icon:[448,512,[],"f360","M448 80v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48zm-88 16H248.029c-21.313 0-32.08 25.861-16.971 40.971l31.984 31.987L67.515 364.485c-4.686 4.686-4.686 12.284 0 16.971l31.029 31.029c4.687 4.686 12.285 4.686 16.971 0l195.526-195.526 31.988 31.991C358.058 263.977 384 253.425 384 231.979V120c0-13.255-10.745-24-24-24z"]},Un={prefix:"fas",iconName:"eye",icon:[576,512,[],"f06e","M572.52 241.4C518.29 135.59 410.93 64 288 64S57.68 135.64 3.48 241.41a32.35 32.35 0 0 0 0 29.19C57.71 376.41 165.07 448 288 448s230.32-71.64 284.52-177.41a32.35 32.35 0 0 0 0-29.19zM288 400a144 144 0 1 1 144-144 143.93 143.93 0 0 1-144 144zm0-240a95.31 95.31 0 0 0-25.31 3.79 47.85 47.85 0 0 1-66.9 66.9A95.78 95.78 0 1 0 288 160z"]},Wn={prefix:"fas",iconName:"eye-dropper",icon:[512,512,[],"f1fb","M50.75 333.25c-12 12-18.75 28.28-18.75 45.26V424L0 480l32 32 56-32h45.49c16.97 0 33.25-6.74 45.25-18.74l126.64-126.62-128-128L50.75 333.25zM483.88 28.12c-37.47-37.5-98.28-37.5-135.75 0l-77.09 77.09-13.1-13.1c-9.44-9.44-24.65-9.31-33.94 0l-40.97 40.97c-9.37 9.37-9.37 24.57 0 33.94l161.94 161.94c9.44 9.44 24.65 9.31 33.94 0L419.88 288c9.37-9.37 9.37-24.57 0-33.94l-13.1-13.1 77.09-77.09c37.51-37.48 37.51-98.26.01-135.75z"]},jn={prefix:"fas",iconName:"eye-slash",icon:[640,512,[],"f070","M320 400c-75.85 0-137.25-58.71-142.9-133.11L72.2 185.82c-13.79 17.3-26.48 35.59-36.72 55.59a32.35 32.35 0 0 0 0 29.19C89.71 376.41 197.07 448 320 448c26.91 0 52.87-4 77.89-10.46L346 397.39a144.13 144.13 0 0 1-26 2.61zm313.82 58.1l-110.55-85.44a331.25 331.25 0 0 0 81.25-102.07 32.35 32.35 0 0 0 0-29.19C550.29 135.59 442.93 64 320 64a308.15 308.15 0 0 0-147.32 37.7L45.46 3.37A16 16 0 0 0 23 6.18L3.37 31.45A16 16 0 0 0 6.18 53.9l588.36 454.73a16 16 0 0 0 22.46-2.81l19.64-25.27a16 16 0 0 0-2.82-22.45zm-183.72-142l-39.3-30.38A94.75 94.75 0 0 0 416 256a94.76 94.76 0 0 0-121.31-92.21A47.65 47.65 0 0 1 304 192a46.64 46.64 0 0 1-1.54 10l-73.61-56.89A142.31 142.31 0 0 1 320 112a143.92 143.92 0 0 1 144 144c0 21.63-5.29 41.79-13.9 60.11z"]},Kn={prefix:"fas",iconName:"fan",icon:[512,512,[],"f863","M352.57 128c-28.09 0-54.09 4.52-77.06 12.86l12.41-123.11C289 7.31 279.81-1.18 269.33.13 189.63 10.13 128 77.64 128 159.43c0 28.09 4.52 54.09 12.86 77.06L17.75 224.08C7.31 223-1.18 232.19.13 242.67c10 79.7 77.51 141.33 159.3 141.33 28.09 0 54.09-4.52 77.06-12.86l-12.41 123.11c-1.05 10.43 8.11 18.93 18.59 17.62 79.7-10 141.33-77.51 141.33-159.3 0-28.09-4.52-54.09-12.86-77.06l123.11 12.41c10.44 1.05 18.93-8.11 17.62-18.59-10-79.7-77.51-141.33-159.3-141.33zM256 288a32 32 0 1 1 32-32 32 32 0 0 1-32 32z"]},$n={prefix:"fas",iconName:"fast-backward",icon:[512,512,[],"f049","M0 436V76c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v151.9L235.5 71.4C256.1 54.3 288 68.6 288 96v131.9L459.5 71.4C480.1 54.3 512 68.6 512 96v320c0 27.4-31.9 41.7-52.5 24.6L288 285.3V416c0 27.4-31.9 41.7-52.5 24.6L64 285.3V436c0 6.6-5.4 12-12 12H12c-6.6 0-12-5.4-12-12z"]},qn={prefix:"fas",iconName:"fast-forward",icon:[512,512,[],"f050","M512 76v360c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12V284.1L276.5 440.6c-20.6 17.2-52.5 2.8-52.5-24.6V284.1L52.5 440.6C31.9 457.8 0 443.4 0 416V96c0-27.4 31.9-41.7 52.5-24.6L224 226.8V96c0-27.4 31.9-41.7 52.5-24.6L448 226.8V76c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12z"]},Yn={prefix:"fas",iconName:"faucet",icon:[512,512,[],"e005","M352,256H313.39c-15.71-13.44-35.46-23.07-57.39-28V180.44l-32-3.38-32,3.38V228c-21.93,5-41.68,14.6-57.39,28H16A16,16,0,0,0,0,272v96a16,16,0,0,0,16,16h92.79C129.38,421.73,173,448,224,448s94.62-26.27,115.21-64H352a32,32,0,0,1,32,32,32,32,0,0,0,32,32h64a32,32,0,0,0,32-32A160,160,0,0,0,352,256ZM81.59,159.91l142.41-15,142.41,15c9.42,1,17.59-6.81,17.59-16.8V112.89c0-10-8.17-17.8-17.59-16.81L256,107.74V80a16,16,0,0,0-16-16H208a16,16,0,0,0-16,16v27.74L81.59,96.08C72.17,95.09,64,102.9,64,112.89v30.22C64,153.1,72.17,160.91,81.59,159.91Z"]},Qn={prefix:"fas",iconName:"fax",icon:[512,512,[],"f1ac","M480 160V77.25a32 32 0 0 0-9.38-22.63L425.37 9.37A32 32 0 0 0 402.75 0H160a32 32 0 0 0-32 32v448a32 32 0 0 0 32 32h320a32 32 0 0 0 32-32V192a32 32 0 0 0-32-32zM288 432a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32a16 16 0 0 1 16 16zm0-128a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32a16 16 0 0 1 16 16zm128 128a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32a16 16 0 0 1 16 16zm0-128a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32a16 16 0 0 1 16 16zm0-112H192V64h160v48a16 16 0 0 0 16 16h48zM64 128H32a32 32 0 0 0-32 32v320a32 32 0 0 0 32 32h32a32 32 0 0 0 32-32V160a32 32 0 0 0-32-32z"]},Xn={prefix:"fas",iconName:"feather",icon:[512,512,[],"f52d","M467.14 44.84c-62.55-62.48-161.67-64.78-252.28 25.73-78.61 78.52-60.98 60.92-85.75 85.66-60.46 60.39-70.39 150.83-63.64 211.17l178.44-178.25c6.26-6.25 16.4-6.25 22.65 0s6.25 16.38 0 22.63L7.04 471.03c-9.38 9.37-9.38 24.57 0 33.94 9.38 9.37 24.6 9.37 33.98 0l66.1-66.03C159.42 454.65 279 457.11 353.95 384h-98.19l147.57-49.14c49.99-49.93 36.38-36.18 46.31-46.86h-97.78l131.54-43.8c45.44-74.46 34.31-148.84-16.26-199.36z"]},Zn={prefix:"fas",iconName:"feather-alt",icon:[512,512,[],"f56b","M512 0C460.22 3.56 96.44 38.2 71.01 287.61c-3.09 26.66-4.84 53.44-5.99 80.24l178.87-178.69c6.25-6.25 16.4-6.25 22.65 0s6.25 16.38 0 22.63L7.04 471.03c-9.38 9.37-9.38 24.57 0 33.94 9.38 9.37 24.59 9.37 33.98 0l57.13-57.07c42.09-.14 84.15-2.53 125.96-7.36 53.48-5.44 97.02-26.47 132.58-56.54H255.74l146.79-48.88c11.25-14.89 21.37-30.71 30.45-47.12h-81.14l106.54-53.21C500.29 132.86 510.19 26.26 512 0z"]},Jn={prefix:"fas",iconName:"female",icon:[256,512,[],"f182","M128 0c35.346 0 64 28.654 64 64s-28.654 64-64 64c-35.346 0-64-28.654-64-64S92.654 0 128 0m119.283 354.179l-48-192A24 24 0 0 0 176 144h-11.36c-22.711 10.443-49.59 10.894-73.28 0H80a24 24 0 0 0-23.283 18.179l-48 192C4.935 369.305 16.383 384 32 384h56v104c0 13.255 10.745 24 24 24h32c13.255 0 24-10.745 24-24V384h56c15.591 0 27.071-14.671 23.283-29.821z"]},es={prefix:"fas",iconName:"fighter-jet",icon:[640,512,[],"f0fb","M544 224l-128-16-48-16h-24L227.158 44h39.509C278.333 44 288 41.375 288 38s-9.667-6-21.333-6H152v12h16v164h-48l-66.667-80H18.667L8 138.667V208h8v16h48v2.666l-64 8v42.667l64 8V288H16v16H8v69.333L18.667 384h34.667L120 304h48v164h-16v12h114.667c11.667 0 21.333-2.625 21.333-6s-9.667-6-21.333-6h-39.509L344 320h24l48-16 128-16c96-21.333 96-26.583 96-32 0-5.417 0-10.667-96-32z"]},ts={prefix:"fas",iconName:"file",icon:[384,512,[],"f15b","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm160-14.1v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},is={prefix:"fas",iconName:"file-alt",icon:[384,512,[],"f15c","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm64 236c0 6.6-5.4 12-12 12H108c-6.6 0-12-5.4-12-12v-8c0-6.6 5.4-12 12-12h168c6.6 0 12 5.4 12 12v8zm0-64c0 6.6-5.4 12-12 12H108c-6.6 0-12-5.4-12-12v-8c0-6.6 5.4-12 12-12h168c6.6 0 12 5.4 12 12v8zm0-72v8c0 6.6-5.4 12-12 12H108c-6.6 0-12-5.4-12-12v-8c0-6.6 5.4-12 12-12h168c6.6 0 12 5.4 12 12zm96-114.1v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},rs={prefix:"fas",iconName:"file-archive",icon:[384,512,[],"f1c6","M377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zM128.4 336c-17.9 0-32.4 12.1-32.4 27 0 15 14.6 27 32.5 27s32.4-12.1 32.4-27-14.6-27-32.5-27zM224 136V0h-63.6v32h-32V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zM95.9 32h32v32h-32zm32.3 384c-33.2 0-58-30.4-51.4-62.9L96.4 256v-32h32v-32h-32v-32h32v-32h-32V96h32V64h32v32h-32v32h32v32h-32v32h32v32h-32v32h22.1c5.7 0 10.7 4.1 11.8 9.7l17.3 87.7c6.4 32.4-18.4 62.6-51.4 62.6z"]},ns={prefix:"fas",iconName:"file-audio",icon:[384,512,[],"f1c7","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm-64 268c0 10.7-12.9 16-20.5 8.5L104 376H76c-6.6 0-12-5.4-12-12v-56c0-6.6 5.4-12 12-12h28l35.5-36.5c7.6-7.6 20.5-2.2 20.5 8.5v136zm33.2-47.6c9.1-9.3 9.1-24.1 0-33.4-22.1-22.8 12.2-56.2 34.4-33.5 27.2 27.9 27.2 72.4 0 100.4-21.8 22.3-56.9-10.4-34.4-33.5zm86-117.1c54.4 55.9 54.4 144.8 0 200.8-21.8 22.4-57-10.3-34.4-33.5 36.2-37.2 36.3-96.5 0-133.8-22.1-22.8 12.3-56.3 34.4-33.5zM384 121.9v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},ss={prefix:"fas",iconName:"file-code",icon:[384,512,[],"f1c9","M384 121.941V128H256V0h6.059c6.365 0 12.47 2.529 16.971 7.029l97.941 97.941A24.005 24.005 0 0 1 384 121.941zM248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160H248zM123.206 400.505a5.4 5.4 0 0 1-7.633.246l-64.866-60.812a5.4 5.4 0 0 1 0-7.879l64.866-60.812a5.4 5.4 0 0 1 7.633.246l19.579 20.885a5.4 5.4 0 0 1-.372 7.747L101.65 336l40.763 35.874a5.4 5.4 0 0 1 .372 7.747l-19.579 20.884zm51.295 50.479l-27.453-7.97a5.402 5.402 0 0 1-3.681-6.692l61.44-211.626a5.402 5.402 0 0 1 6.692-3.681l27.452 7.97a5.4 5.4 0 0 1 3.68 6.692l-61.44 211.626a5.397 5.397 0 0 1-6.69 3.681zm160.792-111.045l-64.866 60.812a5.4 5.4 0 0 1-7.633-.246l-19.58-20.885a5.4 5.4 0 0 1 .372-7.747L284.35 336l-40.763-35.874a5.4 5.4 0 0 1-.372-7.747l19.58-20.885a5.4 5.4 0 0 1 7.633-.246l64.866 60.812a5.4 5.4 0 0 1-.001 7.879z"]},os={prefix:"fas",iconName:"file-contract",icon:[384,512,[],"f56c","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zM64 72c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8V72zm0 64c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16zm192.81 248H304c8.84 0 16 7.16 16 16s-7.16 16-16 16h-47.19c-16.45 0-31.27-9.14-38.64-23.86-2.95-5.92-8.09-6.52-10.17-6.52s-7.22.59-10.02 6.19l-7.67 15.34a15.986 15.986 0 0 1-14.31 8.84c-.38 0-.75-.02-1.14-.05-6.45-.45-12-4.75-14.03-10.89L144 354.59l-10.61 31.88c-5.89 17.66-22.38 29.53-41 29.53H80c-8.84 0-16-7.16-16-16s7.16-16 16-16h12.39c4.83 0 9.11-3.08 10.64-7.66l18.19-54.64c3.3-9.81 12.44-16.41 22.78-16.41s19.48 6.59 22.77 16.41l13.88 41.64c19.77-16.19 54.05-9.7 66 14.16 2.02 4.06 5.96 6.5 10.16 6.5zM377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9z"]},as={prefix:"fas",iconName:"file-csv",icon:[384,512,[],"f6dd","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm-96 144c0 4.42-3.58 8-8 8h-8c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h8c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8h-8c-26.51 0-48-21.49-48-48v-32c0-26.51 21.49-48 48-48h8c4.42 0 8 3.58 8 8v16zm44.27 104H160c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h12.27c5.95 0 10.41-3.5 10.41-6.62 0-1.3-.75-2.66-2.12-3.84l-21.89-18.77c-8.47-7.22-13.33-17.48-13.33-28.14 0-21.3 19.02-38.62 42.41-38.62H200c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8h-12.27c-5.95 0-10.41 3.5-10.41 6.62 0 1.3.75 2.66 2.12 3.84l21.89 18.77c8.47 7.22 13.33 17.48 13.33 28.14.01 21.29-19 38.62-42.39 38.62zM256 264v20.8c0 20.27 5.7 40.17 16 56.88 10.3-16.7 16-36.61 16-56.88V264c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v20.8c0 35.48-12.88 68.89-36.28 94.09-3.02 3.25-7.27 5.11-11.72 5.11s-8.7-1.86-11.72-5.11c-23.4-25.2-36.28-58.61-36.28-94.09V264c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8zm121-159L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9z"]},ls={prefix:"fas",iconName:"file-download",icon:[384,512,[],"f56d","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm76.45 211.36l-96.42 95.7c-6.65 6.61-17.39 6.61-24.04 0l-96.42-95.7C73.42 337.29 80.54 320 94.82 320H160v-80c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v80h65.18c14.28 0 21.4 17.29 11.27 27.36zM377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9z"]},cs={prefix:"fas",iconName:"file-excel",icon:[384,512,[],"f1c3","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm60.1 106.5L224 336l60.1 93.5c5.1 8-.6 18.5-10.1 18.5h-34.9c-4.4 0-8.5-2.4-10.6-6.3C208.9 405.5 192 373 192 373c-6.4 14.8-10 20-36.6 68.8-2.1 3.9-6.1 6.3-10.5 6.3H110c-9.5 0-15.2-10.5-10.1-18.5l60.3-93.5-60.3-93.5c-5.2-8 .6-18.5 10.1-18.5h34.8c4.4 0 8.5 2.4 10.6 6.3 26.1 48.8 20 33.6 36.6 68.5 0 0 6.1-11.7 36.6-68.5 2.1-3.9 6.2-6.3 10.6-6.3H274c9.5-.1 15.2 10.4 10.1 18.4zM384 121.9v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},us={prefix:"fas",iconName:"file-export",icon:[576,512,[],"f56e","M384 121.9c0-6.3-2.5-12.4-7-16.9L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128zM571 308l-95.7-96.4c-10.1-10.1-27.4-3-27.4 11.3V288h-64v64h64v65.2c0 14.3 17.3 21.4 27.4 11.3L571 332c6.6-6.6 6.6-17.4 0-24zm-379 28v-32c0-8.8 7.2-16 16-16h176V160H248c-13.2 0-24-10.8-24-24V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V352H208c-8.8 0-16-7.2-16-16z"]},hs={prefix:"fas",iconName:"file-image",icon:[384,512,[],"f1c5","M384 121.941V128H256V0h6.059a24 24 0 0 1 16.97 7.029l97.941 97.941a24.002 24.002 0 0 1 7.03 16.971zM248 160c-13.2 0-24-10.8-24-24V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160H248zm-135.455 16c26.51 0 48 21.49 48 48s-21.49 48-48 48-48-21.49-48-48 21.491-48 48-48zm208 240h-256l.485-48.485L104.545 328c4.686-4.686 11.799-4.201 16.485.485L160.545 368 264.06 264.485c4.686-4.686 12.284-4.686 16.971 0L320.545 304v112z"]},ds={prefix:"fas",iconName:"file-import",icon:[512,512,[],"f56f","M16 288c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h112v-64zm489-183L407.1 7c-4.5-4.5-10.6-7-17-7H384v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-153 31V0H152c-13.3 0-24 10.7-24 24v264h128v-65.2c0-14.3 17.3-21.4 27.4-11.3L379 308c6.6 6.7 6.6 17.4 0 24l-95.7 96.4c-10.1 10.1-27.4 3-27.4-11.3V352H128v136c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H376c-13.2 0-24-10.8-24-24z"]},ps={prefix:"fas",iconName:"file-invoice",icon:[384,512,[],"f570","M288 256H96v64h192v-64zm89-151L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-153 31V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zM64 72c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8V72zm0 64c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16zm256 304c0 4.42-3.58 8-8 8h-80c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16zm0-200v96c0 8.84-7.16 16-16 16H80c-8.84 0-16-7.16-16-16v-96c0-8.84 7.16-16 16-16h224c8.84 0 16 7.16 16 16z"]},gs={prefix:"fas",iconName:"file-invoice-dollar",icon:[384,512,[],"f571","M377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-153 31V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zM64 72c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8V72zm0 80v-16c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8zm144 263.88V440c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-24.29c-11.29-.58-22.27-4.52-31.37-11.35-3.9-2.93-4.1-8.77-.57-12.14l11.75-11.21c2.77-2.64 6.89-2.76 10.13-.73 3.87 2.42 8.26 3.72 12.82 3.72h28.11c6.5 0 11.8-5.92 11.8-13.19 0-5.95-3.61-11.19-8.77-12.73l-45-13.5c-18.59-5.58-31.58-23.42-31.58-43.39 0-24.52 19.05-44.44 42.67-45.07V232c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v24.29c11.29.58 22.27 4.51 31.37 11.35 3.9 2.93 4.1 8.77.57 12.14l-11.75 11.21c-2.77 2.64-6.89 2.76-10.13.73-3.87-2.43-8.26-3.72-12.82-3.72h-28.11c-6.5 0-11.8 5.92-11.8 13.19 0 5.95 3.61 11.19 8.77 12.73l45 13.5c18.59 5.58 31.58 23.42 31.58 43.39 0 24.53-19.05 44.44-42.67 45.07z"]},fs={prefix:"fas",iconName:"file-medical",icon:[384,512,[],"f477","M377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-153 31V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm64 160v48c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8z"]},ms={prefix:"fas",iconName:"file-medical-alt",icon:[448,512,[],"f478","M288 136V0H88C74.7 0 64 10.7 64 24v232H8c-4.4 0-8 3.6-8 8v16c0 4.4 3.6 8 8 8h140.9c3 0 5.8 1.7 7.2 4.4l19.9 39.8 56.8-113.7c2.9-5.9 11.4-5.9 14.3 0l34.7 69.5H352c8.8 0 16 7.2 16 16s-7.2 16-16 16h-89.9L240 275.8l-56.8 113.7c-2.9 5.9-11.4 5.9-14.3 0L134.1 320H64v168c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H312c-13.2 0-24-10.8-24-24zm153-31L343.1 7c-4.5-4.5-10.6-7-17-7H320v128h128v-6.1c0-6.3-2.5-12.4-7-16.9z"]},vs={prefix:"fas",iconName:"file-pdf",icon:[384,512,[],"f1c1","M181.9 256.1c-5-16-4.9-46.9-2-46.9 8.4 0 7.6 36.9 2 46.9zm-1.7 47.2c-7.7 20.2-17.3 43.3-28.4 62.7 18.3-7 39-17.2 62.9-21.9-12.7-9.6-24.9-23.4-34.5-40.8zM86.1 428.1c0 .8 13.2-5.4 34.9-40.2-6.7 6.3-29.1 24.5-34.9 40.2zM248 160h136v328c0 13.3-10.7 24-24 24H24c-13.3 0-24-10.7-24-24V24C0 10.7 10.7 0 24 0h200v136c0 13.2 10.8 24 24 24zm-8 171.8c-20-12.2-33.3-29-42.7-53.8 4.5-18.5 11.6-46.6 6.2-64.2-4.7-29.4-42.4-26.5-47.8-6.8-5 18.3-.4 44.1 8.1 77-11.6 27.6-28.7 64.6-40.8 85.8-.1 0-.1.1-.2.1-27.1 13.9-73.6 44.5-54.5 68 5.6 6.9 16 10 21.5 10 17.9 0 35.7-18 61.1-61.8 25.8-8.5 54.1-19.1 79-23.2 21.7 11.8 47.1 19.5 64 19.5 29.2 0 31.2-32 19.7-43.4-13.9-13.6-54.3-9.7-73.6-7.2zM377 105L279 7c-4.5-4.5-10.6-7-17-7h-6v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-74.1 255.3c4.1-2.7-2.5-11.9-42.8-9 37.1 15.8 42.8 9 42.8 9z"]},Cs={prefix:"fas",iconName:"file-powerpoint",icon:[384,512,[],"f1c4","M193.7 271.2c8.8 0 15.5 2.7 20.3 8.1 9.6 10.9 9.8 32.7-.2 44.1-4.9 5.6-11.9 8.5-21.1 8.5h-26.9v-60.7h27.9zM377 105L279 7c-4.5-4.5-10.6-7-17-7h-6v128h128v-6.1c0-6.3-2.5-12.4-7-16.9zm-153 31V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm53 165.2c0 90.3-88.8 77.6-111.1 77.6V436c0 6.6-5.4 12-12 12h-30.8c-6.6 0-12-5.4-12-12V236.2c0-6.6 5.4-12 12-12h81c44.5 0 72.9 32.8 72.9 77z"]},ys={prefix:"fas",iconName:"file-prescription",icon:[384,512,[],"f572","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm68.53 179.48l11.31 11.31c6.25 6.25 6.25 16.38 0 22.63l-29.9 29.9L304 409.38c6.25 6.25 6.25 16.38 0 22.63l-11.31 11.31c-6.25 6.25-16.38 6.25-22.63 0L240 413.25l-30.06 30.06c-6.25 6.25-16.38 6.25-22.63 0L176 432c-6.25-6.25-6.25-16.38 0-22.63l30.06-30.06L146.74 320H128v48c0 8.84-7.16 16-16 16H96c-8.84 0-16-7.16-16-16V208c0-8.84 7.16-16 16-16h80c35.35 0 64 28.65 64 64 0 24.22-13.62 45.05-33.46 55.92L240 345.38l29.9-29.9c6.25-6.25 16.38-6.25 22.63 0zM176 272h-48v-32h48c8.82 0 16 7.18 16 16s-7.18 16-16 16zm208-150.1v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},ws={prefix:"fas",iconName:"file-signature",icon:[576,512,[],"f573","M218.17 424.14c-2.95-5.92-8.09-6.52-10.17-6.52s-7.22.59-10.02 6.19l-7.67 15.34c-6.37 12.78-25.03 11.37-29.48-2.09L144 386.59l-10.61 31.88c-5.89 17.66-22.38 29.53-41 29.53H80c-8.84 0-16-7.16-16-16s7.16-16 16-16h12.39c4.83 0 9.11-3.08 10.64-7.66l18.19-54.64c3.3-9.81 12.44-16.41 22.78-16.41s19.48 6.59 22.77 16.41l13.88 41.64c19.75-16.19 54.06-9.7 66 14.16 1.89 3.78 5.49 5.95 9.36 6.26v-82.12l128-127.09V160H248c-13.2 0-24-10.8-24-24V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24v-40l-128-.11c-16.12-.31-30.58-9.28-37.83-23.75zM384 121.9c0-6.3-2.5-12.4-7-16.9L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1zm-96 225.06V416h68.99l161.68-162.78-67.88-67.88L288 346.96zm280.54-179.63l-31.87-31.87c-9.94-9.94-26.07-9.94-36.01 0l-27.25 27.25 67.88 67.88 27.25-27.25c9.95-9.94 9.95-26.07 0-36.01z"]},Ss={prefix:"fas",iconName:"file-upload",icon:[384,512,[],"f574","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm65.18 216.01H224v80c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16v-80H94.82c-14.28 0-21.41-17.29-11.27-27.36l96.42-95.7c6.65-6.61 17.39-6.61 24.04 0l96.42 95.7c10.15 10.07 3.03 27.36-11.25 27.36zM377 105L279.1 7c-4.5-4.5-10.6-7-17-7H256v128h128v-6.1c0-6.3-2.5-12.4-7-16.9z"]},bs={prefix:"fas",iconName:"file-video",icon:[384,512,[],"f1c8","M384 121.941V128H256V0h6.059c6.365 0 12.47 2.529 16.971 7.029l97.941 97.941A24.005 24.005 0 0 1 384 121.941zM224 136V0H24C10.745 0 0 10.745 0 24v464c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V160H248c-13.2 0-24-10.8-24-24zm96 144.016v111.963c0 21.445-25.943 31.998-40.971 16.971L224 353.941V392c0 13.255-10.745 24-24 24H88c-13.255 0-24-10.745-24-24V280c0-13.255 10.745-24 24-24h112c13.255 0 24 10.745 24 24v38.059l55.029-55.013c15.011-15.01 40.971-4.491 40.971 16.97z"]},Es={prefix:"fas",iconName:"file-word",icon:[384,512,[],"f1c2","M224 136V0H24C10.7 0 0 10.7 0 24v464c0 13.3 10.7 24 24 24h336c13.3 0 24-10.7 24-24V160H248c-13.2 0-24-10.8-24-24zm57.1 120H305c7.7 0 13.4 7.1 11.7 14.7l-38 168c-1.2 5.5-6.1 9.3-11.7 9.3h-38c-5.5 0-10.3-3.8-11.6-9.1-25.8-103.5-20.8-81.2-25.6-110.5h-.5c-1.1 14.3-2.4 17.4-25.6 110.5-1.3 5.3-6.1 9.1-11.6 9.1H117c-5.6 0-10.5-3.9-11.7-9.4l-37.8-168c-1.7-7.5 4-14.6 11.7-14.6h24.5c5.7 0 10.7 4 11.8 9.7 15.6 78 20.1 109.5 21 122.2 1.6-10.2 7.3-32.7 29.4-122.7 1.3-5.4 6.1-9.1 11.7-9.1h29.1c5.6 0 10.4 3.8 11.7 9.2 24 100.4 28.8 124 29.6 129.4-.2-11.2-2.6-17.8 21.6-129.2 1-5.6 5.9-9.5 11.5-9.5zM384 121.9v6.1H256V0h6.1c6.4 0 12.5 2.5 17 7l97.9 98c4.5 4.5 7 10.6 7 16.9z"]},As={prefix:"fas",iconName:"fill",icon:[512,512,[],"f575","M502.63 217.06L294.94 9.37C288.69 3.12 280.5 0 272.31 0s-16.38 3.12-22.62 9.37l-81.58 81.58L81.93 4.77c-6.24-6.25-16.38-6.25-22.62 0L36.69 27.38c-6.24 6.25-6.24 16.38 0 22.63l86.19 86.18-94.76 94.76c-37.49 37.49-37.49 98.26 0 135.75l117.19 117.19c18.75 18.74 43.31 28.12 67.87 28.12 24.57 0 49.13-9.37 67.88-28.12l221.57-221.57c12.49-12.5 12.49-32.76 0-45.26zm-116.22 70.97H65.93c1.36-3.84 3.57-7.98 7.43-11.83l13.15-13.15 81.61-81.61 58.61 58.6c12.49 12.49 32.75 12.49 45.24 0 12.49-12.49 12.49-32.75 0-45.24l-58.61-58.6 58.95-58.95 162.45 162.44-48.35 48.34z"]},Ts={prefix:"fas",iconName:"fill-drip",icon:[576,512,[],"f576","M512 320s-64 92.65-64 128c0 35.35 28.66 64 64 64s64-28.65 64-64-64-128-64-128zm-9.37-102.94L294.94 9.37C288.69 3.12 280.5 0 272.31 0s-16.38 3.12-22.62 9.37l-81.58 81.58L81.93 4.76c-6.25-6.25-16.38-6.25-22.62 0L36.69 27.38c-6.24 6.25-6.24 16.38 0 22.62l86.19 86.18-94.76 94.76c-37.49 37.48-37.49 98.26 0 135.75l117.19 117.19c18.74 18.74 43.31 28.12 67.87 28.12 24.57 0 49.13-9.37 67.87-28.12l221.57-221.57c12.5-12.5 12.5-32.75.01-45.25zm-116.22 70.97H65.93c1.36-3.84 3.57-7.98 7.43-11.83l13.15-13.15 81.61-81.61 58.6 58.6c12.49 12.49 32.75 12.49 45.24 0s12.49-32.75 0-45.24l-58.6-58.6 58.95-58.95 162.44 162.44-48.34 48.34z"]},Ms={prefix:"fas",iconName:"film",icon:[512,512,[],"f008","M488 64h-8v20c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12V64H96v20c0 6.6-5.4 12-12 12H44c-6.6 0-12-5.4-12-12V64h-8C10.7 64 0 74.7 0 88v336c0 13.3 10.7 24 24 24h8v-20c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v20h320v-20c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v20h8c13.3 0 24-10.7 24-24V88c0-13.3-10.7-24-24-24zM96 372c0 6.6-5.4 12-12 12H44c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-96c0 6.6-5.4 12-12 12H44c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-96c0 6.6-5.4 12-12 12H44c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm272 208c0 6.6-5.4 12-12 12H156c-6.6 0-12-5.4-12-12v-96c0-6.6 5.4-12 12-12h200c6.6 0 12 5.4 12 12v96zm0-168c0 6.6-5.4 12-12 12H156c-6.6 0-12-5.4-12-12v-96c0-6.6 5.4-12 12-12h200c6.6 0 12 5.4 12 12v96zm112 152c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-96c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-96c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40z"]},Rs={prefix:"fas",iconName:"filter",icon:[512,512,[],"f0b0","M487.976 0H24.028C2.71 0-8.047 25.866 7.058 40.971L192 225.941V432c0 7.831 3.821 15.17 10.237 19.662l80 55.98C298.02 518.69 320 507.493 320 487.98V225.941l184.947-184.97C520.021 25.896 509.338 0 487.976 0z"]},_s={prefix:"fas",iconName:"fingerprint",icon:[512,512,[],"f577","M256.12 245.96c-13.25 0-24 10.74-24 24 1.14 72.25-8.14 141.9-27.7 211.55-2.73 9.72 2.15 30.49 23.12 30.49 10.48 0 20.11-6.92 23.09-17.52 13.53-47.91 31.04-125.41 29.48-224.52.01-13.25-10.73-24-23.99-24zm-.86-81.73C194 164.16 151.25 211.3 152.1 265.32c.75 47.94-3.75 95.91-13.37 142.55-2.69 12.98 5.67 25.69 18.64 28.36 13.05 2.67 25.67-5.66 28.36-18.64 10.34-50.09 15.17-101.58 14.37-153.02-.41-25.95 19.92-52.49 54.45-52.34 31.31.47 57.15 25.34 57.62 55.47.77 48.05-2.81 96.33-10.61 143.55-2.17 13.06 6.69 25.42 19.76 27.58 19.97 3.33 26.81-15.1 27.58-19.77 8.28-50.03 12.06-101.21 11.27-152.11-.88-55.8-47.94-101.88-104.91-102.72zm-110.69-19.78c-10.3-8.34-25.37-6.8-33.76 3.48-25.62 31.5-39.39 71.28-38.75 112 .59 37.58-2.47 75.27-9.11 112.05-2.34 13.05 6.31 25.53 19.36 27.89 20.11 3.5 27.07-14.81 27.89-19.36 7.19-39.84 10.5-80.66 9.86-121.33-.47-29.88 9.2-57.88 28-80.97 8.35-10.28 6.79-25.39-3.49-33.76zm109.47-62.33c-15.41-.41-30.87 1.44-45.78 4.97-12.89 3.06-20.87 15.98-17.83 28.89 3.06 12.89 16 20.83 28.89 17.83 11.05-2.61 22.47-3.77 34-3.69 75.43 1.13 137.73 61.5 138.88 134.58.59 37.88-1.28 76.11-5.58 113.63-1.5 13.17 7.95 25.08 21.11 26.58 16.72 1.95 25.51-11.88 26.58-21.11a929.06 929.06 0 0 0 5.89-119.85c-1.56-98.75-85.07-180.33-186.16-181.83zm252.07 121.45c-2.86-12.92-15.51-21.2-28.61-18.27-12.94 2.86-21.12 15.66-18.26 28.61 4.71 21.41 4.91 37.41 4.7 61.6-.11 13.27 10.55 24.09 23.8 24.2h.2c13.17 0 23.89-10.61 24-23.8.18-22.18.4-44.11-5.83-72.34zm-40.12-90.72C417.29 43.46 337.6 1.29 252.81.02 183.02-.82 118.47 24.91 70.46 72.94 24.09 119.37-.9 181.04.14 246.65l-.12 21.47c-.39 13.25 10.03 24.31 23.28 24.69.23.02.48.02.72.02 12.92 0 23.59-10.3 23.97-23.3l.16-23.64c-.83-52.5 19.16-101.86 56.28-139 38.76-38.8 91.34-59.67 147.68-58.86 69.45 1.03 134.73 35.56 174.62 92.39 7.61 10.86 22.56 13.45 33.42 5.86 10.84-7.62 13.46-22.59 5.84-33.43z"]},Ps={prefix:"fas",iconName:"fire",icon:[384,512,[],"f06d","M216 23.86c0-23.8-30.65-32.77-44.15-13.04C48 191.85 224 200 224 288c0 35.63-29.11 64.46-64.85 63.99-35.17-.45-63.15-29.77-63.15-64.94v-85.51c0-21.7-26.47-32.23-41.43-16.5C27.8 213.16 0 261.33 0 320c0 105.87 86.13 192 192 192s192-86.13 192-192c0-170.29-168-193-168-296.14z"]},xs={prefix:"fas",iconName:"fire-alt",icon:[448,512,[],"f7e4","M323.56 51.2c-20.8 19.3-39.58 39.59-56.22 59.97C240.08 73.62 206.28 35.53 168 0 69.74 91.17 0 209.96 0 281.6 0 408.85 100.29 512 224 512s224-103.15 224-230.4c0-53.27-51.98-163.14-124.44-230.4zm-19.47 340.65C282.43 407.01 255.72 416 226.86 416 154.71 416 96 368.26 96 290.75c0-38.61 24.31-72.63 72.79-130.75 6.93 7.98 98.83 125.34 98.83 125.34l58.63-66.88c4.14 6.85 7.91 13.55 11.27 19.97 27.35 52.19 15.81 118.97-33.43 153.42z"]},Ds={prefix:"fas",iconName:"fire-extinguisher",icon:[448,512,[],"f134","M434.027 26.329l-168 28C254.693 56.218 256 67.8 256 72h-58.332C208.353 36.108 181.446 0 144 0c-39.435 0-66.368 39.676-52.228 76.203-52.039 13.051-75.381 54.213-90.049 90.884-4.923 12.307 1.063 26.274 13.37 31.197 12.317 4.926 26.279-1.075 31.196-13.37C75.058 112.99 106.964 120 168 120v27.076c-41.543 10.862-72 49.235-72 94.129V488c0 13.255 10.745 24 24 24h144c13.255 0 24-10.745 24-24V240c0-44.731-30.596-82.312-72-92.97V120h40c0 2.974-1.703 15.716 10.027 17.671l168 28C441.342 166.89 448 161.25 448 153.834V38.166c0-7.416-6.658-13.056-13.973-11.837zM144 72c-8.822 0-16-7.178-16-16s7.178-16 16-16 16 7.178 16 16-7.178 16-16 16z"]},Is={prefix:"fas",iconName:"first-aid",icon:[576,512,[],"f479","M0 80v352c0 26.5 21.5 48 48 48h48V32H48C21.5 32 0 53.5 0 80zm128 400h320V32H128v448zm64-248c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8v48c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48zM528 32h-48v448h48c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48z"]},Ls={prefix:"fas",iconName:"fish",icon:[576,512,[],"f578","M327.1 96c-89.97 0-168.54 54.77-212.27 101.63L27.5 131.58c-12.13-9.18-30.24.6-27.14 14.66L24.54 256 .35 365.77c-3.1 14.06 15.01 23.83 27.14 14.66l87.33-66.05C158.55 361.23 237.13 416 327.1 416 464.56 416 576 288 576 256S464.56 96 327.1 96zm87.43 184c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24 13.26 0 24 10.74 24 24 0 13.25-10.75 24-24 24z"]},Ns={prefix:"fas",iconName:"fist-raised",icon:[384,512,[],"f6de","M255.98 160V16c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v146.93c5.02-1.78 10.34-2.93 15.97-2.93h48.03zm128 95.99c-.01-35.34-28.66-63.99-63.99-63.99H207.85c-8.78 0-15.9 7.07-15.9 15.85v.56c0 26.27 21.3 47.59 47.57 47.59h35.26c9.68 0 13.2 3.58 13.2 8v16.2c0 4.29-3.59 7.78-7.88 8-44.52 2.28-64.16 24.71-96.05 72.55l-6.31 9.47a7.994 7.994 0 0 1-11.09 2.22l-13.31-8.88a7.994 7.994 0 0 1-2.22-11.09l6.31-9.47c15.73-23.6 30.2-43.26 47.31-58.08-17.27-5.51-31.4-18.12-38.87-34.45-6.59 3.41-13.96 5.52-21.87 5.52h-32c-12.34 0-23.49-4.81-32-12.48C71.48 251.19 60.33 256 48 256H16c-5.64 0-10.97-1.15-16-2.95v77.93c0 33.95 13.48 66.5 37.49 90.51L63.99 448v64h255.98v-63.96l35.91-35.92A96.035 96.035 0 0 0 384 344.21l-.02-88.22zm-32.01-90.09V48c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v112h32c11.28 0 21.94 2.31 32 5.9zM16 224h32c8.84 0 16-7.16 16-16V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v128c0 8.84 7.16 16 16 16zm95.99 0h32c8.84 0 16-7.16 16-16V48c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v160c0 8.84 7.16 16 16 16z"]},Os={prefix:"fas",iconName:"flag",icon:[512,512,[],"f024","M349.565 98.783C295.978 98.783 251.721 64 184.348 64c-24.955 0-47.309 4.384-68.045 12.013a55.947 55.947 0 0 0 3.586-23.562C118.117 24.015 94.806 1.206 66.338.048 34.345-1.254 8 24.296 8 56c0 19.026 9.497 35.825 24 45.945V488c0 13.255 10.745 24 24 24h16c13.255 0 24-10.745 24-24v-94.4c28.311-12.064 63.582-22.122 114.435-22.122 53.588 0 97.844 34.783 165.217 34.783 48.169 0 86.667-16.294 122.505-40.858C506.84 359.452 512 349.571 512 339.045v-243.1c0-23.393-24.269-38.87-45.485-29.016-34.338 15.948-76.454 31.854-116.95 31.854z"]},Fs={prefix:"fas",iconName:"flag-checkered",icon:[512,512,[],"f11e","M243.2 189.9V258c26.1 5.9 49.3 15.6 73.6 22.3v-68.2c-26-5.8-49.4-15.5-73.6-22.2zm223.3-123c-34.3 15.9-76.5 31.9-117 31.9C296 98.8 251.7 64 184.3 64c-25 0-47.3 4.4-68 12 2.8-7.3 4.1-15.2 3.6-23.6C118.1 24 94.8 1.2 66.3 0 34.3-1.3 8 24.3 8 56c0 19 9.5 35.8 24 45.9V488c0 13.3 10.7 24 24 24h16c13.3 0 24-10.7 24-24v-94.4c28.3-12.1 63.6-22.1 114.4-22.1 53.6 0 97.8 34.8 165.2 34.8 48.2 0 86.7-16.3 122.5-40.9 8.7-6 13.8-15.8 13.8-26.4V95.9c.1-23.3-24.2-38.8-45.4-29zM169.6 325.5c-25.8 2.7-50 8.2-73.6 16.6v-70.5c26.2-9.3 47.5-15 73.6-17.4zM464 191c-23.6 9.8-46.3 19.5-73.6 23.9V286c24.8-3.4 51.4-11.8 73.6-26v70.5c-25.1 16.1-48.5 24.7-73.6 27.1V286c-27 3.7-47.9 1.5-73.6-5.6v67.4c-23.9-7.4-47.3-16.7-73.6-21.3V258c-19.7-4.4-40.8-6.8-73.6-3.8v-70c-22.4 3.1-44.6 10.2-73.6 20.9v-70.5c33.2-12.2 50.1-19.8 73.6-22v71.6c27-3.7 48.4-1.3 73.6 5.7v-67.4c23.7 7.4 47.2 16.7 73.6 21.3v68.4c23.7 5.3 47.6 6.9 73.6 2.7V143c27-4.8 52.3-13.6 73.6-22.5z"]},ks={prefix:"fas",iconName:"flag-usa",icon:[512,512,[],"f74d","M32 0C14.3 0 0 14.3 0 32v464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V32C64 14.3 49.7 0 32 0zm267.9 303.6c-57.2-15.1-111.7-28.8-203.9 11.1V384c185.7-92.2 221.7 53.3 397.5-23.1 11.4-5 18.5-16.5 18.5-28.8v-36c-43.6 17.3-80.2 24.1-112.1 24.1-37.4-.1-68.9-8.4-100-16.6zm0-96c-57.2-15.1-111.7-28.8-203.9 11.1v61.5c94.8-37.6 154.6-22.7 212.1-7.6 57.2 15.1 111.7 28.8 203.9-11.1V200c-43.6 17.3-80.2 24.1-112.1 24.1-37.4 0-68.9-8.3-100-16.5zm9.5-125.9c51.8 15.6 97.4 29 202.6-20.1V30.8c0-25.1-26.8-38.1-49.4-26.6C291.3 91.5 305.4-62.2 96 32.4v151.9c94.8-37.5 154.6-22.7 212.1-7.6 57.2 15 111.7 28.7 203.9-11.1V96.7c-53.6 23.5-93.3 31.4-126.1 31.4s-59-7.8-85.7-15.9c-4-1.2-8.1-2.4-12.1-3.5V75.5c7.2 2 14.3 4.1 21.3 6.2zM160 128.1c-8.8 0-16-7.1-16-16 0-8.8 7.2-16 16-16s16 7.1 16 16-7.2 16-16 16zm0-55.8c-8.8 0-16-7.1-16-16 0-8.8 7.2-16 16-16s16 7.1 16 16c0 8.8-7.2 16-16 16zm64 47.9c-8.8 0-16-7.1-16-16 0-8.8 7.2-16 16-16s16 7.1 16 16c0 8.8-7.2 16-16 16zm0-55.9c-8.8 0-16-7.1-16-16 0-8.8 7.2-16 16-16s16 7.1 16 16c0 8.8-7.2 16-16 16z"]},Gs={prefix:"fas",iconName:"flask",icon:[448,512,[],"f0c3","M437.2 403.5L320 215V64h8c13.3 0 24-10.7 24-24V24c0-13.3-10.7-24-24-24H120c-13.3 0-24 10.7-24 24v16c0 13.3 10.7 24 24 24h8v151L10.8 403.5C-18.5 450.6 15.3 512 70.9 512h306.2c55.7 0 89.4-61.5 60.1-108.5zM137.9 320l48.2-77.6c3.7-5.2 5.8-11.6 5.8-18.4V64h64v160c0 6.9 2.2 13.2 5.8 18.4l48.2 77.6h-172z"]},Vs={prefix:"fas",iconName:"flushed",icon:[496,512,[],"f579","M344 200c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zm-192 0c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zM248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM80 224c0-39.8 32.2-72 72-72s72 32.2 72 72-32.2 72-72 72-72-32.2-72-72zm232 176H184c-21.2 0-21.2-32 0-32h128c21.2 0 21.2 32 0 32zm32-104c-39.8 0-72-32.2-72-72s32.2-72 72-72 72 32.2 72 72-32.2 72-72 72z"]},Hs={prefix:"fas",iconName:"folder",icon:[512,512,[],"f07b","M464 128H272l-64-64H48C21.49 64 0 85.49 0 112v288c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V176c0-26.51-21.49-48-48-48z"]},Bs={prefix:"fas",iconName:"folder-minus",icon:[512,512,[],"f65d","M464 128H272l-64-64H48C21.49 64 0 85.49 0 112v288c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V176c0-26.51-21.49-48-48-48zm-96 168c0 8.84-7.16 16-16 16H160c-8.84 0-16-7.16-16-16v-16c0-8.84 7.16-16 16-16h192c8.84 0 16 7.16 16 16v16z"]},zs={prefix:"fas",iconName:"folder-open",icon:[576,512,[],"f07c","M572.694 292.093L500.27 416.248A63.997 63.997 0 0 1 444.989 448H45.025c-18.523 0-30.064-20.093-20.731-36.093l72.424-124.155A64 64 0 0 1 152 256h399.964c18.523 0 30.064 20.093 20.73 36.093zM152 224h328v-48c0-26.51-21.49-48-48-48H272l-64-64H48C21.49 64 0 85.49 0 112v278.046l69.077-118.418C86.214 242.25 117.989 224 152 224z"]},Us={prefix:"fas",iconName:"folder-plus",icon:[512,512,[],"f65e","M464,128H272L208,64H48A48,48,0,0,0,0,112V400a48,48,0,0,0,48,48H464a48,48,0,0,0,48-48V176A48,48,0,0,0,464,128ZM359.5,296a16,16,0,0,1-16,16h-64v64a16,16,0,0,1-16,16h-16a16,16,0,0,1-16-16V312h-64a16,16,0,0,1-16-16V280a16,16,0,0,1,16-16h64V200a16,16,0,0,1,16-16h16a16,16,0,0,1,16,16v64h64a16,16,0,0,1,16,16Z"]},Ws={prefix:"fas",iconName:"font",icon:[448,512,[],"f031","M432 416h-23.41L277.88 53.69A32 32 0 0 0 247.58 32h-47.16a32 32 0 0 0-30.3 21.69L39.41 416H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-19.58l23.3-64h152.56l23.3 64H304a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM176.85 272L224 142.51 271.15 272z"]},js={prefix:"fas",iconName:"font-awesome-logo-full",icon:[3992,512,["Font Awesome"],"f4e6","M454.6 0H57.4C25.9 0 0 25.9 0 57.4v397.3C0 486.1 25.9 512 57.4 512h397.3c31.4 0 57.4-25.9 57.4-57.4V57.4C512 25.9 486.1 0 454.6 0zm-58.9 324.9c0 4.8-4.1 6.9-8.9 8.9-19.2 8.1-39.7 15.7-61.5 15.7-40.5 0-68.7-44.8-163.2 2.5v51.8c0 30.3-45.7 30.2-45.7 0v-250c-9-7-15-17.9-15-30.3 0-21 17.1-38.2 38.2-38.2 21 0 38.2 17.1 38.2 38.2 0 12.2-5.8 23.2-14.9 30.2v21c37.1-12 65.5-34.4 146.1-3.4 26.6 11.4 68.7-15.7 76.5-15.7 5.5 0 10.3 4.1 10.3 8.9v160.4zm432.9-174.2h-137v70.1H825c39.8 0 40.4 62.2 0 62.2H691.6v105.6c0 45.5-70.7 46.4-70.7 0V128.3c0-22 18-39.8 39.8-39.8h167.8c39.6 0 40.5 62.2.1 62.2zm191.1 23.4c-169.3 0-169.1 252.4 0 252.4 169.9 0 169.9-252.4 0-252.4zm0 196.1c-81.6 0-82.1-139.8 0-139.8 82.5 0 82.4 139.8 0 139.8zm372.4 53.4c-17.5 0-31.4-13.9-31.4-31.4v-117c0-62.4-72.6-52.5-99.1-16.4v133.4c0 41.5-63.3 41.8-63.3 0V208c0-40 63.1-41.6 63.1 0v3.4c43.3-51.6 162.4-60.4 162.4 39.3v141.5c.3 30.4-31.5 31.4-31.7 31.4zm179.7 2.9c-44.3 0-68.3-22.9-68.3-65.8V235.2H1488c-35.6 0-36.7-55.3 0-55.3h15.5v-37.3c0-41.3 63.8-42.1 63.8 0v37.5h24.9c35.4 0 35.7 55.3 0 55.3h-24.9v108.5c0 29.6 26.1 26.3 27.4 26.3 31.4 0 52.6 56.3-22.9 56.3zM1992 123c-19.5-50.2-95.5-50-114.5 0-107.3 275.7-99.5 252.7-99.5 262.8 0 42.8 58.3 51.2 72.1 14.4l13.5-35.9H2006l13 35.9c14.2 37.7 72.1 27.2 72.1-14.4 0-10.1 5.3 6.8-99.1-262.8zm-108.9 179.1l51.7-142.9 51.8 142.9h-103.5zm591.3-85.6l-53.7 176.3c-12.4 41.2-72 41-84 0l-42.3-135.9-42.3 135.9c-12.4 40.9-72 41.2-84.5 0l-54.2-176.3c-12.5-39.4 49.8-56.1 60.2-16.9L2213 342l45.3-139.5c10.9-32.7 59.6-34.7 71.2 0l45.3 139.5 39.3-142.4c10.3-38.3 72.6-23.8 60.3 16.9zm275.4 75.1c0-42.4-33.9-117.5-119.5-117.5-73.2 0-124.4 56.3-124.4 126 0 77.2 55.3 126.4 128.5 126.4 31.7 0 93-11.5 93-39.8 0-18.3-21.1-31.5-39.3-22.4-49.4 26.2-109 8.4-115.9-43.8h148.3c16.3 0 29.3-13.4 29.3-28.9zM2571 277.7c9.5-73.4 113.9-68.6 118.6 0H2571zm316.7 148.8c-31.4 0-81.6-10.5-96.6-31.9-12.4-17 2.5-39.8 21.8-39.8 16.3 0 36.8 22.9 77.7 22.9 27.4 0 40.4-11 40.4-25.8 0-39.8-142.9-7.4-142.9-102 0-40.4 35.3-75.7 98.6-75.7 31.4 0 74.1 9.9 87.6 29.4 10.8 14.8-1.4 36.2-20.9 36.2-15.1 0-26.7-17.3-66.2-17.3-22.9 0-37.8 10.5-37.8 23.8 0 35.9 142.4 6 142.4 103.1-.1 43.7-37.4 77.1-104.1 77.1zm266.8-252.4c-169.3 0-169.1 252.4 0 252.4 170.1 0 169.6-252.4 0-252.4zm0 196.1c-81.8 0-82-139.8 0-139.8 82.5 0 82.4 139.8 0 139.8zm476.9 22V268.7c0-53.8-61.4-45.8-85.7-10.5v134c0 41.3-63.8 42.1-63.8 0V268.7c0-52.1-59.5-47.4-85.7-10.1v133.6c0 41.5-63.3 41.8-63.3 0V208c0-40 63.1-41.6 63.1 0v3.4c9.9-14.4 41.8-37.3 78.6-37.3 35.3 0 57.7 16.4 66.7 43.8 13.9-21.8 45.8-43.8 82.6-43.8 44.3 0 70.7 23.4 70.7 72.7v145.3c.5 17.3-13.5 31.4-31.9 31.4 3.5.1-31.3 1.1-31.3-31.3zM3992 291.6c0-42.4-32.4-117.5-117.9-117.5-73.2 0-127.5 56.3-127.5 126 0 77.2 58.3 126.4 131.6 126.4 31.7 0 91.5-11.5 91.5-39.8 0-18.3-21.1-31.5-39.3-22.4-49.4 26.2-110.5 8.4-117.5-43.8h149.8c16.3 0 29.1-13.4 29.3-28.9zm-180.5-13.9c9.7-74.4 115.9-68.3 120.1 0h-120.1z"]},Ks={prefix:"fas",iconName:"football-ball",icon:[496,512,[],"f44e","M481.5 60.3c-4.8-18.2-19.1-32.5-37.3-37.4C420.3 16.5 383 8.9 339.4 8L496 164.8c-.8-43.5-8.2-80.6-14.5-104.5zm-467 391.4c4.8 18.2 19.1 32.5 37.3 37.4 23.9 6.4 61.2 14 104.8 14.9L0 347.2c.8 43.5 8.2 80.6 14.5 104.5zM4.2 283.4L220.4 500c132.5-19.4 248.8-118.7 271.5-271.4L275.6 12C143.1 31.4 26.8 130.7 4.2 283.4zm317.3-123.6c3.1-3.1 8.2-3.1 11.3 0l11.3 11.3c3.1 3.1 3.1 8.2 0 11.3l-28.3 28.3 28.3 28.3c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0l-28.3-28.3-22.6 22.7 28.3 28.3c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0L248 278.6l-22.6 22.6 28.3 28.3c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0l-28.3-28.3-28.3 28.3c-3.1 3.1-8.2 3.1-11.3 0l-11.3-11.3c-3.1-3.1-3.1-8.2 0-11.3l28.3-28.3-28.3-28.2c-3.1-3.1-3.1-8.2 0-11.3l11.3-11.3c3.1-3.1 8.2-3.1 11.3 0l28.3 28.3 22.6-22.6-28.3-28.3c-3.1-3.1-3.1-8.2 0-11.3l11.3-11.3c3.1-3.1 8.2-3.1 11.3 0l28.3 28.3 22.6-22.6-28.3-28.3c-3.1-3.1-3.1-8.2 0-11.3l11.3-11.3c3.1-3.1 8.2-3.1 11.3 0l28.3 28.3 28.3-28.5z"]},$s={prefix:"fas",iconName:"forward",icon:[512,512,[],"f04e","M500.5 231.4l-192-160C287.9 54.3 256 68.6 256 96v320c0 27.4 31.9 41.8 52.5 24.6l192-160c15.3-12.8 15.3-36.4 0-49.2zm-256 0l-192-160C31.9 54.3 0 68.6 0 96v320c0 27.4 31.9 41.8 52.5 24.6l192-160c15.3-12.8 15.3-36.4 0-49.2z"]},qs={prefix:"fas",iconName:"frog",icon:[576,512,[],"f52e","M446.53 97.43C439.67 60.23 407.19 32 368 32c-39.23 0-71.72 28.29-78.54 65.54C126.75 112.96-.5 250.12 0 416.98.11 451.9 29.08 480 64 480h304c8.84 0 16-7.16 16-16 0-17.67-14.33-32-32-32h-79.49l35.8-48.33c24.14-36.23 10.35-88.28-33.71-106.6-23.89-9.93-51.55-4.65-72.24 10.88l-32.76 24.59c-7.06 5.31-17.09 3.91-22.41-3.19-5.3-7.08-3.88-17.11 3.19-22.41l34.78-26.09c36.84-27.66 88.28-27.62 125.13 0 10.87 8.15 45.87 39.06 40.8 93.21L469.62 480H560c8.84 0 16-7.16 16-16 0-17.67-14.33-32-32-32h-53.63l-98.52-104.68 154.44-86.65A58.16 58.16 0 0 0 576 189.94c0-21.4-11.72-40.95-30.48-51.23-40.56-22.22-98.99-41.28-98.99-41.28zM368 136c-13.26 0-24-10.75-24-24 0-13.26 10.74-24 24-24 13.25 0 24 10.74 24 24 0 13.25-10.75 24-24 24z"]},Ys={prefix:"fas",iconName:"frown",icon:[496,512,[],"f119","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm-160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm170.2 218.2C315.8 367.4 282.9 352 248 352s-67.8 15.4-90.2 42.2c-13.5 16.3-38.1-4.2-24.6-20.5C161.7 339.6 203.6 320 248 320s86.3 19.6 114.7 53.8c13.6 16.2-11 36.7-24.5 20.4z"]},Qs={prefix:"fas",iconName:"frown-open",icon:[496,512,[],"f57a","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM136 208c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32zm187.3 183.3c-31.2-9.6-59.4-15.3-75.3-15.3s-44.1 5.7-75.3 15.3c-11.5 3.5-22.5-6.3-20.5-18.1 7-40 60.1-61.2 95.8-61.2s88.8 21.3 95.8 61.2c2 11.9-9.1 21.6-20.5 18.1zM328 240c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Xs={prefix:"fas",iconName:"funnel-dollar",icon:[640,512,[],"f662","M433.46 165.94l101.2-111.87C554.61 34.12 540.48 0 512.26 0H31.74C3.52 0-10.61 34.12 9.34 54.07L192 256v155.92c0 12.59 5.93 24.44 16 32l79.99 60c20.86 15.64 48.47 6.97 59.22-13.57C310.8 455.38 288 406.35 288 352c0-89.79 62.05-165.17 145.46-186.06zM480 192c-88.37 0-160 71.63-160 160s71.63 160 160 160 160-71.63 160-160-71.63-160-160-160zm16 239.88V448c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-16.29c-11.29-.58-22.27-4.52-31.37-11.35-3.9-2.93-4.1-8.77-.57-12.14l11.75-11.21c2.77-2.64 6.89-2.76 10.13-.73 3.87 2.42 8.26 3.72 12.82 3.72h28.11c6.5 0 11.8-5.92 11.8-13.19 0-5.95-3.61-11.19-8.77-12.73l-45-13.5c-18.59-5.58-31.58-23.42-31.58-43.39 0-24.52 19.05-44.44 42.67-45.07V256c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16.29c11.29.58 22.27 4.51 31.37 11.35 3.9 2.93 4.1 8.77.57 12.14l-11.75 11.21c-2.77 2.64-6.89 2.76-10.13.73-3.87-2.43-8.26-3.72-12.82-3.72h-28.11c-6.5 0-11.8 5.92-11.8 13.19 0 5.95 3.61 11.19 8.77 12.73l45 13.5c18.59 5.58 31.58 23.42 31.58 43.39 0 24.53-19.04 44.44-42.67 45.07z"]},Zs={prefix:"fas",iconName:"futbol",icon:[512,512,[],"f1e3","M504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zm-48 0l-.003-.282-26.064 22.741-62.679-58.5 16.454-84.355 34.303 3.072c-24.889-34.216-60.004-60.089-100.709-73.141l13.651 31.939L256 139l-74.953-41.525 13.651-31.939c-40.631 13.028-75.78 38.87-100.709 73.141l34.565-3.073 16.192 84.355-62.678 58.5-26.064-22.741-.003.282c0 43.015 13.497 83.952 38.472 117.991l7.704-33.897 85.138 10.447 36.301 77.826-29.902 17.786c40.202 13.122 84.29 13.148 124.572 0l-29.902-17.786 36.301-77.826 85.138-10.447 7.704 33.897C442.503 339.952 456 299.015 456 256zm-248.102 69.571l-29.894-91.312L256 177.732l77.996 56.527-29.622 91.312h-96.476z"]},Js={prefix:"fas",iconName:"gamepad",icon:[640,512,[],"f11b","M480.07 96H160a160 160 0 1 0 114.24 272h91.52A160 160 0 1 0 480.07 96zM248 268a12 12 0 0 1-12 12h-52v52a12 12 0 0 1-12 12h-24a12 12 0 0 1-12-12v-52H84a12 12 0 0 1-12-12v-24a12 12 0 0 1 12-12h52v-52a12 12 0 0 1 12-12h24a12 12 0 0 1 12 12v52h52a12 12 0 0 1 12 12zm216 76a40 40 0 1 1 40-40 40 40 0 0 1-40 40zm64-96a40 40 0 1 1 40-40 40 40 0 0 1-40 40z"]},eo={prefix:"fas",iconName:"gas-pump",icon:[512,512,[],"f52f","M336 448H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h320c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm157.2-340.7l-81-81c-6.2-6.2-16.4-6.2-22.6 0l-11.3 11.3c-6.2 6.2-6.2 16.4 0 22.6L416 97.9V160c0 28.1 20.9 51.3 48 55.2V376c0 13.2-10.8 24-24 24s-24-10.8-24-24v-32c0-48.6-39.4-88-88-88h-8V64c0-35.3-28.7-64-64-64H96C60.7 0 32 28.7 32 64v352h288V304h8c22.1 0 40 17.9 40 40v27.8c0 37.7 27 72 64.5 75.9 43 4.3 79.5-29.5 79.5-71.7V152.6c0-17-6.8-33.3-18.8-45.3zM256 192H96V64h160v128z"]},to={prefix:"fas",iconName:"gavel",icon:[512,512,[],"f0e3","M504.971 199.362l-22.627-22.627c-9.373-9.373-24.569-9.373-33.941 0l-5.657 5.657L329.608 69.255l5.657-5.657c9.373-9.373 9.373-24.569 0-33.941L312.638 7.029c-9.373-9.373-24.569-9.373-33.941 0L154.246 131.48c-9.373 9.373-9.373 24.569 0 33.941l22.627 22.627c9.373 9.373 24.569 9.373 33.941 0l5.657-5.657 39.598 39.598-81.04 81.04-5.657-5.657c-12.497-12.497-32.758-12.497-45.255 0L9.373 412.118c-12.497 12.497-12.497 32.758 0 45.255l45.255 45.255c12.497 12.497 32.758 12.497 45.255 0l114.745-114.745c12.497-12.497 12.497-32.758 0-45.255l-5.657-5.657 81.04-81.04 39.598 39.598-5.657 5.657c-9.373 9.373-9.373 24.569 0 33.941l22.627 22.627c9.373 9.373 24.569 9.373 33.941 0l124.451-124.451c9.372-9.372 9.372-24.568 0-33.941z"]},io={prefix:"fas",iconName:"gem",icon:[576,512,[],"f3a5","M485.5 0L576 160H474.9L405.7 0h79.8zm-128 0l69.2 160H149.3L218.5 0h139zm-267 0h79.8l-69.2 160H0L90.5 0zM0 192h100.7l123 251.7c1.5 3.1-2.7 5.9-5 3.3L0 192zm148.2 0h279.6l-137 318.2c-1 2.4-4.5 2.4-5.5 0L148.2 192zm204.1 251.7l123-251.7H576L357.3 446.9c-2.3 2.7-6.5-.1-5-3.2z"]},ro={prefix:"fas",iconName:"genderless",icon:[288,512,[],"f22d","M144 176c44.1 0 80 35.9 80 80s-35.9 80-80 80-80-35.9-80-80 35.9-80 80-80m0-64C64.5 112 0 176.5 0 256s64.5 144 144 144 144-64.5 144-144-64.5-144-144-144z"]},no={prefix:"fas",iconName:"ghost",icon:[384,512,[],"f6e2","M186.1.09C81.01 3.24 0 94.92 0 200.05v263.92c0 14.26 17.23 21.39 27.31 11.31l24.92-18.53c6.66-4.95 16-3.99 21.51 2.21l42.95 48.35c6.25 6.25 16.38 6.25 22.63 0l40.72-45.85c6.37-7.17 17.56-7.17 23.92 0l40.72 45.85c6.25 6.25 16.38 6.25 22.63 0l42.95-48.35c5.51-6.2 14.85-7.17 21.51-2.21l24.92 18.53c10.08 10.08 27.31 2.94 27.31-11.31V192C384 84 294.83-3.17 186.1.09zM128 224c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm128 0c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},so={prefix:"fas",iconName:"gift",icon:[512,512,[],"f06b","M32 448c0 17.7 14.3 32 32 32h160V320H32v128zm256 32h160c17.7 0 32-14.3 32-32V320H288v160zm192-320h-42.1c6.2-12.1 10.1-25.5 10.1-40 0-48.5-39.5-88-88-88-41.6 0-68.5 21.3-103 68.3-34.5-47-61.4-68.3-103-68.3-48.5 0-88 39.5-88 88 0 14.5 3.8 27.9 10.1 40H32c-17.7 0-32 14.3-32 32v80c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16v-80c0-17.7-14.3-32-32-32zm-326.1 0c-22.1 0-40-17.9-40-40s17.9-40 40-40c19.9 0 34.6 3.3 86.1 80h-86.1zm206.1 0h-86.1c51.4-76.5 65.7-80 86.1-80 22.1 0 40 17.9 40 40s-17.9 40-40 40z"]},oo={prefix:"fas",iconName:"gifts",icon:[640,512,[],"f79c","M240.6 194.1c1.9-30.8 17.3-61.2 44-79.8C279.4 103.5 268.7 96 256 96h-29.4l30.7-22c7.2-5.1 8.9-15.1 3.7-22.3l-9.3-13c-5.1-7.2-15.1-8.9-22.3-3.7l-32 22.9 11.5-30.6c3.1-8.3-1.1-17.5-9.4-20.6l-15-5.6c-8.3-3.1-17.5 1.1-20.6 9.4l-19.9 53-19.9-53.1C121 2.1 111.8-2.1 103.5 1l-15 5.6C80.2 9.7 76 19 79.2 27.2l11.5 30.6L58.6 35c-7.2-5.1-17.2-3.5-22.3 3.7l-9.3 13c-5.1 7.2-3.5 17.2 3.7 22.3l30.7 22H32c-17.7 0-32 14.3-32 32v352c0 17.7 14.3 32 32 32h168.9c-5.5-9.5-8.9-20.3-8.9-32V256c0-29.9 20.8-55 48.6-61.9zM224 480c0 17.7 14.3 32 32 32h160V384H224v96zm224 32h160c17.7 0 32-14.3 32-32v-96H448v128zm160-288h-20.4c2.6-7.6 4.4-15.5 4.4-23.8 0-35.5-27-72.2-72.1-72.2-48.1 0-75.9 47.7-87.9 75.3-12.1-27.6-39.9-75.3-87.9-75.3-45.1 0-72.1 36.7-72.1 72.2 0 8.3 1.7 16.2 4.4 23.8H256c-17.7 0-32 14.3-32 32v96h192V224h15.3l.7-.2.7.2H448v128h192v-96c0-17.7-14.3-32-32-32zm-272 0c-2.7-1.4-5.1-3-7.2-4.8-7.3-6.4-8.8-13.8-8.8-19 0-9.7 6.4-24.2 24.1-24.2 18.7 0 35.6 27.4 44.5 48H336zm199.2-4.8c-2.1 1.8-4.5 3.4-7.2 4.8h-52.6c8.8-20.3 25.8-48 44.5-48 17.7 0 24.1 14.5 24.1 24.2 0 5.2-1.5 12.6-8.8 19z"]},ao={prefix:"fas",iconName:"glass-cheers",icon:[640,512,[],"f79f","M639.4 433.6c-8.4-20.4-31.8-30.1-52.2-21.6l-22.1 9.2-38.7-101.9c47.9-35 64.8-100.3 34.5-152.8L474.3 16c-8-13.9-25.1-19.7-40-13.6L320 49.8 205.7 2.4c-14.9-6.2-32-.3-40 13.6L79.1 166.5C48.9 219 65.7 284.3 113.6 319.2L74.9 421.1l-22.1-9.2c-20.4-8.5-43.7 1.2-52.2 21.6-1.7 4.1.2 8.8 4.3 10.5l162.3 67.4c4.1 1.7 8.7-.2 10.4-4.3 8.4-20.4-1.2-43.8-21.6-52.3l-22.1-9.2L173.3 342c4.4.5 8.8 1.3 13.1 1.3 51.7 0 99.4-33.1 113.4-85.3l20.2-75.4 20.2 75.4c14 52.2 61.7 85.3 113.4 85.3 4.3 0 8.7-.8 13.1-1.3L506 445.6l-22.1 9.2c-20.4 8.5-30.1 31.9-21.6 52.3 1.7 4.1 6.4 6 10.4 4.3L635.1 444c4-1.7 6-6.3 4.3-10.4zM275.9 162.1l-112.1-46.5 36.5-63.4 94.5 39.2-18.9 70.7zm88.2 0l-18.9-70.7 94.5-39.2 36.5 63.4-112.1 46.5z"]},lo={prefix:"fas",iconName:"glass-martini",icon:[512,512,[],"f000","M502.05 57.6C523.3 36.34 508.25 0 478.2 0H33.8C3.75 0-11.3 36.34 9.95 57.6L224 271.64V464h-56c-22.09 0-40 17.91-40 40 0 4.42 3.58 8 8 8h240c4.42 0 8-3.58 8-8 0-22.09-17.91-40-40-40h-56V271.64L502.05 57.6z"]},co={prefix:"fas",iconName:"glass-martini-alt",icon:[512,512,[],"f57b","M502.05 57.6C523.3 36.34 508.25 0 478.2 0H33.8C3.75 0-11.3 36.34 9.95 57.6L224 271.64V464h-56c-22.09 0-40 17.91-40 40 0 4.42 3.58 8 8 8h240c4.42 0 8-3.58 8-8 0-22.09-17.91-40-40-40h-56V271.64L502.05 57.6zM443.77 48l-48 48H116.24l-48-48h375.53z"]},uo={prefix:"fas",iconName:"glass-whiskey",icon:[512,512,[],"f7a0","M480 32H32C12.5 32-2.4 49.2.3 68.5l56 356.5c4.5 31.5 31.5 54.9 63.4 54.9h273c31.8 0 58.9-23.4 63.4-54.9l55.6-356.5C514.4 49.2 499.5 32 480 32zm-37.4 64l-30 192h-313L69.4 96h373.2z"]},ho={prefix:"fas",iconName:"glasses",icon:[576,512,[],"f530","M574.1 280.37L528.75 98.66c-5.91-23.7-21.59-44.05-43-55.81-21.44-11.73-46.97-14.11-70.19-6.33l-15.25 5.08c-8.39 2.79-12.92 11.86-10.12 20.24l5.06 15.18c2.79 8.38 11.85 12.91 20.23 10.12l13.18-4.39c10.87-3.62 23-3.57 33.16 1.73 10.29 5.37 17.57 14.56 20.37 25.82l38.46 153.82c-22.19-6.81-49.79-12.46-81.2-12.46-34.77 0-73.98 7.02-114.85 26.74h-73.18c-40.87-19.74-80.08-26.75-114.86-26.75-31.42 0-59.02 5.65-81.21 12.46l38.46-153.83c2.79-11.25 10.09-20.45 20.38-25.81 10.16-5.3 22.28-5.35 33.15-1.73l13.17 4.39c8.38 2.79 17.44-1.74 20.23-10.12l5.06-15.18c2.8-8.38-1.73-17.45-10.12-20.24l-15.25-5.08c-23.22-7.78-48.75-5.41-70.19 6.33-21.41 11.77-37.09 32.11-43 55.8L1.9 280.37A64.218 64.218 0 0 0 0 295.86v70.25C0 429.01 51.58 480 115.2 480h37.12c60.28 0 110.37-45.94 114.88-105.37l2.93-38.63h35.75l2.93 38.63C313.31 434.06 363.4 480 423.68 480h37.12c63.62 0 115.2-50.99 115.2-113.88v-70.25c0-5.23-.64-10.43-1.9-15.5zm-370.72 89.42c-1.97 25.91-24.4 46.21-51.06 46.21H115.2C86.97 416 64 393.62 64 366.11v-37.54c18.12-6.49 43.42-12.92 72.58-12.92 23.86 0 47.26 4.33 69.93 12.92l-3.13 41.22zM512 366.12c0 27.51-22.97 49.88-51.2 49.88h-37.12c-26.67 0-49.1-20.3-51.06-46.21l-3.13-41.22c22.67-8.59 46.08-12.92 69.95-12.92 29.12 0 54.43 6.44 72.55 12.93v37.54z"]},po={prefix:"fas",iconName:"globe",icon:[496,512,[],"f0ac","M336.5 160C322 70.7 287.8 8 248 8s-74 62.7-88.5 152h177zM152 256c0 22.2 1.2 43.5 3.3 64h185.3c2.1-20.5 3.3-41.8 3.3-64s-1.2-43.5-3.3-64H155.3c-2.1 20.5-3.3 41.8-3.3 64zm324.7-96c-28.6-67.9-86.5-120.4-158-141.6 24.4 33.8 41.2 84.7 50 141.6h108zM177.2 18.4C105.8 39.6 47.8 92.1 19.3 160h108c8.7-56.9 25.5-107.8 49.9-141.6zM487.4 192H372.7c2.1 21 3.3 42.5 3.3 64s-1.2 43-3.3 64h114.6c5.5-20.5 8.6-41.8 8.6-64s-3.1-43.5-8.5-64zM120 256c0-21.5 1.2-43 3.3-64H8.6C3.2 212.5 0 233.8 0 256s3.2 43.5 8.6 64h114.6c-2-21-3.2-42.5-3.2-64zm39.5 96c14.5 89.3 48.7 152 88.5 152s74-62.7 88.5-152h-177zm159.3 141.6c71.4-21.2 129.4-73.7 158-141.6h-108c-8.8 56.9-25.6 107.8-50 141.6zM19.3 352c28.6 67.9 86.5 120.4 158 141.6-24.4-33.8-41.2-84.7-50-141.6h-108z"]},go={prefix:"fas",iconName:"globe-africa",icon:[496,512,[],"f57c","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm160 215.5v6.93c0 5.87-3.32 11.24-8.57 13.86l-15.39 7.7a15.485 15.485 0 0 1-15.53-.97l-18.21-12.14a15.52 15.52 0 0 0-13.5-1.81l-2.65.88c-9.7 3.23-13.66 14.79-7.99 23.3l13.24 19.86c2.87 4.31 7.71 6.9 12.89 6.9h8.21c8.56 0 15.5 6.94 15.5 15.5v11.34c0 3.35-1.09 6.62-3.1 9.3l-18.74 24.98c-1.42 1.9-2.39 4.1-2.83 6.43l-4.3 22.83c-.62 3.29-2.29 6.29-4.76 8.56a159.608 159.608 0 0 0-25 29.16l-13.03 19.55a27.756 27.756 0 0 1-23.09 12.36c-10.51 0-20.12-5.94-24.82-15.34a78.902 78.902 0 0 1-8.33-35.29V367.5c0-8.56-6.94-15.5-15.5-15.5h-25.88c-14.49 0-28.38-5.76-38.63-16a54.659 54.659 0 0 1-16-38.63v-14.06c0-17.19 8.1-33.38 21.85-43.7l27.58-20.69a54.663 54.663 0 0 1 32.78-10.93h.89c8.48 0 16.85 1.97 24.43 5.77l14.72 7.36c3.68 1.84 7.93 2.14 11.83.84l47.31-15.77c6.33-2.11 10.6-8.03 10.6-14.7 0-8.56-6.94-15.5-15.5-15.5h-10.09c-4.11 0-8.05-1.63-10.96-4.54l-6.92-6.92a15.493 15.493 0 0 0-10.96-4.54H199.5c-8.56 0-15.5-6.94-15.5-15.5v-4.4c0-7.11 4.84-13.31 11.74-15.04l14.45-3.61c3.74-.94 7-3.23 9.14-6.44l8.08-12.11c2.87-4.31 7.71-6.9 12.89-6.9h24.21c8.56 0 15.5-6.94 15.5-15.5v-21.7C359.23 71.63 422.86 131.02 441.93 208H423.5c-8.56 0-15.5 6.94-15.5 15.5z"]},fo={prefix:"fas",iconName:"globe-americas",icon:[496,512,[],"f57d","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm82.29 357.6c-3.9 3.88-7.99 7.95-11.31 11.28-2.99 3-5.1 6.7-6.17 10.71-1.51 5.66-2.73 11.38-4.77 16.87l-17.39 46.85c-13.76 3-28 4.69-42.65 4.69v-27.38c1.69-12.62-7.64-36.26-22.63-51.25-6-6-9.37-14.14-9.37-22.63v-32.01c0-11.64-6.27-22.34-16.46-27.97-14.37-7.95-34.81-19.06-48.81-26.11-11.48-5.78-22.1-13.14-31.65-21.75l-.8-.72a114.792 114.792 0 0 1-18.06-20.74c-9.38-13.77-24.66-36.42-34.59-51.14 20.47-45.5 57.36-82.04 103.2-101.89l24.01 12.01C203.48 89.74 216 82.01 216 70.11v-11.3c7.99-1.29 16.12-2.11 24.39-2.42l28.3 28.3c6.25 6.25 6.25 16.38 0 22.63L264 112l-10.34 10.34c-3.12 3.12-3.12 8.19 0 11.31l4.69 4.69c3.12 3.12 3.12 8.19 0 11.31l-8 8a8.008 8.008 0 0 1-5.66 2.34h-8.99c-2.08 0-4.08.81-5.58 2.27l-9.92 9.65a8.008 8.008 0 0 0-1.58 9.31l15.59 31.19c2.66 5.32-1.21 11.58-7.15 11.58h-5.64c-1.93 0-3.79-.7-5.24-1.96l-9.28-8.06a16.017 16.017 0 0 0-15.55-3.1l-31.17 10.39a11.95 11.95 0 0 0-8.17 11.34c0 4.53 2.56 8.66 6.61 10.69l11.08 5.54c9.41 4.71 19.79 7.16 30.31 7.16s22.59 27.29 32 32h66.75c8.49 0 16.62 3.37 22.63 9.37l13.69 13.69a30.503 30.503 0 0 1 8.93 21.57 46.536 46.536 0 0 1-13.72 32.98zM417 274.25c-5.79-1.45-10.84-5-14.15-9.97l-17.98-26.97a23.97 23.97 0 0 1 0-26.62l19.59-29.38c2.32-3.47 5.5-6.29 9.24-8.15l12.98-6.49C440.2 193.59 448 223.87 448 256c0 8.67-.74 17.16-1.82 25.54L417 274.25z"]},mo={prefix:"fas",iconName:"globe-asia",icon:[496,512,[],"f57e","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm-11.34 240.23c-2.89 4.82-8.1 7.77-13.72 7.77h-.31c-4.24 0-8.31 1.69-11.31 4.69l-5.66 5.66c-3.12 3.12-3.12 8.19 0 11.31l5.66 5.66c3 3 4.69 7.07 4.69 11.31V304c0 8.84-7.16 16-16 16h-6.11c-6.06 0-11.6-3.42-14.31-8.85l-22.62-45.23c-2.44-4.88-8.95-5.94-12.81-2.08l-19.47 19.46c-3 3-7.07 4.69-11.31 4.69H50.81C49.12 277.55 48 266.92 48 256c0-110.28 89.72-200 200-200 21.51 0 42.2 3.51 61.63 9.82l-50.16 38.53c-5.11 3.41-4.63 11.06.86 13.81l10.83 5.41c5.42 2.71 8.84 8.25 8.84 14.31V216c0 4.42-3.58 8-8 8h-3.06c-3.03 0-5.8-1.71-7.15-4.42-1.56-3.12-5.96-3.29-7.76-.3l-17.37 28.95zM408 358.43c0 4.24-1.69 8.31-4.69 11.31l-9.57 9.57c-3 3-7.07 4.69-11.31 4.69h-15.16c-4.24 0-8.31-1.69-11.31-4.69l-13.01-13.01a26.767 26.767 0 0 0-25.42-7.04l-21.27 5.32c-1.27.32-2.57.48-3.88.48h-10.34c-4.24 0-8.31-1.69-11.31-4.69l-11.91-11.91a8.008 8.008 0 0 1-2.34-5.66v-10.2c0-3.27 1.99-6.21 5.03-7.43l39.34-15.74c1.98-.79 3.86-1.82 5.59-3.05l23.71-16.89a7.978 7.978 0 0 1 4.64-1.48h12.09c3.23 0 6.15 1.94 7.39 4.93l5.35 12.85a4 4 0 0 0 3.69 2.46h3.8c1.78 0 3.35-1.18 3.84-2.88l4.2-14.47c.5-1.71 2.06-2.88 3.84-2.88h6.06c2.21 0 4 1.79 4 4v12.93c0 2.12.84 4.16 2.34 5.66l11.91 11.91c3 3 4.69 7.07 4.69 11.31v24.6z"]},vo={prefix:"fas",iconName:"globe-europe",icon:[496,512,[],"f7a2","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm200 248c0 22.5-3.9 44.2-10.8 64.4h-20.3c-4.3 0-8.4-1.7-11.4-4.8l-32-32.6c-4.5-4.6-4.5-12.1.1-16.7l12.5-12.5v-8.7c0-3-1.2-5.9-3.3-8l-9.4-9.4c-2.1-2.1-5-3.3-8-3.3h-16c-6.2 0-11.3-5.1-11.3-11.3 0-3 1.2-5.9 3.3-8l9.4-9.4c2.1-2.1 5-3.3 8-3.3h32c6.2 0 11.3-5.1 11.3-11.3v-9.4c0-6.2-5.1-11.3-11.3-11.3h-36.7c-8.8 0-16 7.2-16 16v4.5c0 6.9-4.4 13-10.9 15.2l-31.6 10.5c-3.3 1.1-5.5 4.1-5.5 7.6v2.2c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8s-3.6-8-8-8H247c-3 0-5.8 1.7-7.2 4.4l-9.4 18.7c-2.7 5.4-8.2 8.8-14.3 8.8H194c-8.8 0-16-7.2-16-16V199c0-4.2 1.7-8.3 4.7-11.3l20.1-20.1c4.6-4.6 7.2-10.9 7.2-17.5 0-3.4 2.2-6.5 5.5-7.6l40-13.3c1.7-.6 3.2-1.5 4.4-2.7l26.8-26.8c2.1-2.1 3.3-5 3.3-8 0-6.2-5.1-11.3-11.3-11.3H258l-16 16v8c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8v-20c0-2.5 1.2-4.9 3.2-6.4l28.9-21.7c1.9-.1 3.8-.3 5.7-.3C358.3 56 448 145.7 448 256zM130.1 149.1c0-3 1.2-5.9 3.3-8l25.4-25.4c2.1-2.1 5-3.3 8-3.3 6.2 0 11.3 5.1 11.3 11.3v16c0 3-1.2 5.9-3.3 8l-9.4 9.4c-2.1 2.1-5 3.3-8 3.3h-16c-6.2 0-11.3-5.1-11.3-11.3zm128 306.4v-7.1c0-8.8-7.2-16-16-16h-20.2c-10.8 0-26.7-5.3-35.4-11.8l-22.2-16.7c-11.5-8.6-18.2-22.1-18.2-36.4v-23.9c0-16 8.4-30.8 22.1-39l42.9-25.7c7.1-4.2 15.2-6.5 23.4-6.5h31.2c10.9 0 21.4 3.9 29.6 10.9l43.2 37.1h18.3c8.5 0 16.6 3.4 22.6 9.4l17.3 17.3c3.4 3.4 8.1 5.3 12.9 5.3H423c-32.4 58.9-93.8 99.5-164.9 103.1z"]},Co={prefix:"fas",iconName:"golf-ball",icon:[416,512,[],"f450","M96 416h224c0 17.7-14.3 32-32 32h-16c-17.7 0-32 14.3-32 32v20c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-20c0-17.7-14.3-32-32-32h-16c-17.7 0-32-14.3-32-32zm320-208c0 74.2-39 139.2-97.5 176h-221C39 347.2 0 282.2 0 208 0 93.1 93.1 0 208 0s208 93.1 208 208zm-180.1 43.9c18.3 0 33.1-14.8 33.1-33.1 0-14.4-9.3-26.3-22.1-30.9 9.6 26.8-15.6 51.3-41.9 41.9 4.6 12.8 16.5 22.1 30.9 22.1zm49.1 46.9c0-14.4-9.3-26.3-22.1-30.9 9.6 26.8-15.6 51.3-41.9 41.9 4.6 12.8 16.5 22.1 30.9 22.1 18.3 0 33.1-14.9 33.1-33.1zm64-64c0-14.4-9.3-26.3-22.1-30.9 9.6 26.8-15.6 51.3-41.9 41.9 4.6 12.8 16.5 22.1 30.9 22.1 18.3 0 33.1-14.9 33.1-33.1z"]},yo={prefix:"fas",iconName:"gopuram",icon:[512,512,[],"f664","M496 352h-16V240c0-8.8-7.2-16-16-16h-16v-80c0-8.8-7.2-16-16-16h-16V16c0-8.8-7.2-16-16-16s-16 7.2-16 16v16h-64V16c0-8.8-7.2-16-16-16s-16 7.2-16 16v16h-64V16c0-8.8-7.2-16-16-16s-16 7.2-16 16v16h-64V16c0-8.8-7.2-16-16-16S96 7.2 96 16v112H80c-8.8 0-16 7.2-16 16v80H48c-8.8 0-16 7.2-16 16v112H16c-8.8 0-16 7.2-16 16v128c0 8.8 7.2 16 16 16h80V352h32V224h32v-96h32v96h-32v128h-32v160h80v-80c0-8.8 7.2-16 16-16h64c8.8 0 16 7.2 16 16v80h80V352h-32V224h-32v-96h32v96h32v128h32v160h80c8.8 0 16-7.2 16-16V368c0-8.8-7.2-16-16-16zM232 176c0-8.8 7.2-16 16-16h16c8.8 0 16 7.2 16 16v48h-48zm56 176h-64v-64c0-8.8 7.2-16 16-16h32c8.8 0 16 7.2 16 16z"]},wo={prefix:"fas",iconName:"graduation-cap",icon:[640,512,[],"f19d","M622.34 153.2L343.4 67.5c-15.2-4.67-31.6-4.67-46.79 0L17.66 153.2c-23.54 7.23-23.54 38.36 0 45.59l48.63 14.94c-10.67 13.19-17.23 29.28-17.88 46.9C38.78 266.15 32 276.11 32 288c0 10.78 5.68 19.85 13.86 25.65L20.33 428.53C18.11 438.52 25.71 448 35.94 448h56.11c10.24 0 17.84-9.48 15.62-19.47L82.14 313.65C90.32 307.85 96 298.78 96 288c0-11.57-6.47-21.25-15.66-26.87.76-15.02 8.44-28.3 20.69-36.72L296.6 284.5c9.06 2.78 26.44 6.25 46.79 0l278.95-85.7c23.55-7.24 23.55-38.36 0-45.6zM352.79 315.09c-28.53 8.76-52.84 3.92-65.59 0l-145.02-44.55L128 384c0 35.35 85.96 64 192 64s192-28.65 192-64l-14.18-113.47-145.03 44.56z"]},So={prefix:"fas",iconName:"greater-than",icon:[384,512,[],"f531","M365.52 209.85L59.22 67.01c-16.06-7.49-35.15-.54-42.64 15.52L3.01 111.61c-7.49 16.06-.54 35.15 15.52 42.64L236.96 256.1 18.49 357.99C2.47 365.46-4.46 384.5 3.01 400.52l13.52 29C24 445.54 43.04 452.47 59.06 445l306.47-142.91a32.003 32.003 0 0 0 18.48-29v-34.23c-.01-12.45-7.21-23.76-18.49-29.01z"]},bo={prefix:"fas",iconName:"greater-than-equal",icon:[448,512,[],"f532","M55.22 107.69l175.56 68.09-175.44 68.05c-18.39 6.03-27.88 24.39-21.2 41l12.09 30.08c6.68 16.61 26.99 25.19 45.38 19.15L393.02 214.2c13.77-4.52 22.98-16.61 22.98-30.17v-15.96c0-13.56-9.21-25.65-22.98-30.17L91.3 17.92c-18.29-6-38.51 2.53-45.15 19.06L34.12 66.9c-6.64 16.53 2.81 34.79 21.1 40.79zM424 400H24c-13.25 0-24 10.74-24 24v48c0 13.25 10.75 24 24 24h400c13.25 0 24-10.75 24-24v-48c0-13.26-10.75-24-24-24z"]},Eo={prefix:"fas",iconName:"grimace",icon:[496,512,[],"f57f","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM144 400h-8c-17.7 0-32-14.3-32-32v-8h40v40zm0-56h-40v-8c0-17.7 14.3-32 32-32h8v40zm-8-136c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32zm72 192h-48v-40h48v40zm0-56h-48v-40h48v40zm64 56h-48v-40h48v40zm0-56h-48v-40h48v40zm64 56h-48v-40h48v40zm0-56h-48v-40h48v40zm-8-104c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm64 128c0 17.7-14.3 32-32 32h-8v-40h40v8zm0-24h-40v-40h8c17.7 0 32 14.3 32 32v8z"]},Ao={prefix:"fas",iconName:"grin",icon:[496,512,[],"f580","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm-160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm80 256c-60.6 0-134.5-38.3-143.8-93.3-2-11.8 9.3-21.6 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.3-3.7 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},To={prefix:"fas",iconName:"grin-alt",icon:[496,512,[],"f581","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm63.7 128.7c7.6-11.4 24.7-11.7 32.7 0 12.4 18.4 15.1 36.9 15.7 55.3-.5 18.4-3.3 36.9-15.7 55.3-7.6 11.4-24.7 11.7-32.7 0-12.4-18.4-15.1-36.9-15.7-55.3.5-18.4 3.3-36.9 15.7-55.3zm-160 0c7.6-11.4 24.7-11.7 32.7 0 12.4 18.4 15.1 36.9 15.7 55.3-.5 18.4-3.3 36.9-15.7 55.3-7.6 11.4-24.7 11.7-32.7 0-12.4-18.4-15.1-36.9-15.7-55.3.5-18.4 3.3-36.9 15.7-55.3zM248 432c-60.6 0-134.5-38.3-143.8-93.3-2-11.8 9.3-21.6 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.4-3.7 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},Mo={prefix:"fas",iconName:"grin-beam",icon:[496,512,[],"f582","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 144c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 11.9-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.1 7.3-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm-160 0c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 11.9-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm80 280c-60.6 0-134.5-38.3-143.8-93.3-2-11.9 9.4-21.6 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.4-3.7 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},Ro={prefix:"fas",iconName:"grin-beam-sweat",icon:[504,512,[],"f583","M456 128c26.5 0 48-21 48-47 0-20-28.5-60.4-41.6-77.8-3.2-4.3-9.6-4.3-12.8 0C436.5 20.6 408 61 408 81c0 26 21.5 47 48 47zm0 32c-44.1 0-80-35.4-80-79 0-4.4.3-14.2 8.1-32.2C345 23.1 298.3 8 248 8 111 8 0 119 0 256s111 248 248 248 248-111 248-248c0-35.1-7.4-68.4-20.5-98.6-6.3 1.5-12.7 2.6-19.5 2.6zm-128-8c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 12-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.1 7.4-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm-160 0c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 12-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm80 280c-60.6 0-134.5-38.3-143.8-93.3-2-11.8 9.3-21.6 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.5-3.7 22.6 6.2 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},_o={prefix:"fas",iconName:"grin-hearts",icon:[496,512,[],"f584","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM90.4 183.6c6.7-17.6 26.7-26.7 44.9-21.9l7.1 1.9 2-7.1c5-18.1 22.8-30.9 41.5-27.9 21.4 3.4 34.4 24.2 28.8 44.5L195.3 243c-1.2 4.5-5.9 7.2-10.5 6l-70.2-18.2c-20.4-5.4-31.9-27-24.2-47.2zM248 432c-60.6 0-134.5-38.3-143.8-93.3-2-11.8 9.2-21.5 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.4-3.6 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3zm133.4-201.3l-70.2 18.2c-4.5 1.2-9.2-1.5-10.5-6L281.3 173c-5.6-20.3 7.4-41.1 28.8-44.5 18.6-3 36.4 9.8 41.5 27.9l2 7.1 7.1-1.9c18.2-4.7 38.2 4.3 44.9 21.9 7.7 20.3-3.8 41.9-24.2 47.2z"]},Po={prefix:"fas",iconName:"grin-squint",icon:[496,512,[],"f585","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm33.8 189.7l80-48c11.6-6.9 24 7.7 15.4 18L343.6 208l33.6 40.3c8.7 10.4-3.9 24.8-15.4 18l-80-48c-7.7-4.7-7.7-15.9 0-20.6zm-163-30c-8.6-10.3 3.8-24.9 15.4-18l80 48c7.8 4.7 7.8 15.9 0 20.6l-80 48c-11.5 6.8-24-7.6-15.4-18l33.6-40.3-33.6-40.3zM248 432c-60.6 0-134.5-38.3-143.8-93.3-2-11.9 9.4-21.6 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.5-3.7 22.6 6.2 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},xo={prefix:"fas",iconName:"grin-squint-tears",icon:[512,512,[],"f586","M409.6 111.9c22.6-3.2 73.5-12 88.3-26.8 19.2-19.2 18.9-50.6-.7-70.2S446-5 426.9 14.2c-14.8 14.8-23.5 65.7-26.8 88.3-.8 5.5 3.9 10.2 9.5 9.4zM102.4 400.1c-22.6 3.2-73.5 12-88.3 26.8-19.1 19.1-18.8 50.6.8 70.2s51 19.9 70.2.7c14.8-14.8 23.5-65.7 26.8-88.3.8-5.5-3.9-10.2-9.5-9.4zm311.7-256.5c-33 3.9-48.6-25.1-45.7-45.7 3.4-24 7.4-42.1 11.5-56.5C285.1-13.4 161.8-.5 80.6 80.6-.5 161.7-13.4 285 41.4 379.9c14.4-4.1 32.4-8 56.5-11.5 33.2-3.9 48.6 25.2 45.7 45.7-3.4 24-7.4 42.1-11.5 56.5 94.8 54.8 218.1 41.9 299.3-39.2s94-204.4 39.2-299.3c-14.4 4.1-32.5 8-56.5 11.5zM255.7 106c3.3-13.2 22.4-11.5 23.6 1.8l4.8 52.3 52.3 4.8c13.4 1.2 14.9 20.3 1.8 23.6l-90.5 22.6c-8.9 2.2-16.7-5.9-14.5-14.5l22.5-90.6zm-90.9 230.3L160 284l-52.3-4.8c-13.4-1.2-14.9-20.3-1.8-23.6l90.5-22.6c8.8-2.2 16.7 5.8 14.5 14.5L188.3 338c-3.1 13.2-22.2 11.7-23.5-1.7zm215.7 44.2c-29.3 29.3-75.7 50.4-116.7 50.4-18.9 0-36.6-4.5-51-14.7-9.8-6.9-8.7-21.8 2-27.2 28.3-14.6 63.9-42.4 97.8-76.3s61.7-69.6 76.3-97.8c5.4-10.5 20.2-11.9 27.3-2 32.3 45.3 7.1 124.7-35.7 167.6z"]},Do={prefix:"fas",iconName:"grin-stars",icon:[496,512,[],"f587","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM94.6 168.9l34.9-5 15.5-31.6c2.9-5.8 11-5.8 13.9 0l15.5 31.6 34.9 5c6.2 1 8.9 8.6 4.3 13.2l-25.4 24.6 6 34.9c1 6.2-5.3 11-11 7.9L152 233.3l-31.3 16.3c-5.7 3.1-12-1.7-11-7.9l6-34.9-25.4-24.6c-4.6-4.7-1.9-12.3 4.3-13.3zM248 432c-60.6 0-134.5-38.3-143.8-93.3-2-11.8 9.3-21.5 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.5-3.7 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3zm157.7-249.9l-25.4 24.6 6 34.9c1 6.2-5.3 11-11 7.9L344 233.3l-31.3 16.3c-5.7 3.1-12-1.7-11-7.9l6-34.9-25.4-24.6c-4.5-4.6-1.9-12.2 4.3-13.2l34.9-5 15.5-31.6c2.9-5.8 11-5.8 13.9 0l15.5 31.6 34.9 5c6.3.9 9 8.5 4.4 13.1z"]},Io={prefix:"fas",iconName:"grin-tears",icon:[640,512,[],"f588","M102.4 256.1c-22.6 3.2-73.5 12-88.3 26.8-19.1 19.1-18.8 50.6.8 70.2s51 19.9 70.2.7c14.8-14.8 23.5-65.7 26.8-88.3.8-5.5-3.9-10.2-9.5-9.4zm523.4 26.8c-14.8-14.8-65.7-23.5-88.3-26.8-5.5-.8-10.3 3.9-9.5 9.5 3.2 22.6 12 73.5 26.8 88.3 19.2 19.2 50.6 18.9 70.2-.7s20-51.2.8-70.3zm-129.4-12.8c-3.8-26.6 19.1-49.5 45.7-45.7 8.9 1.3 16.8 2.7 24.3 4.1C552.7 104.5 447.7 8 320 8S87.3 104.5 73.6 228.5c7.5-1.4 15.4-2.8 24.3-4.1 33.2-3.9 48.6 25.3 45.7 45.7-11.8 82.3-29.9 100.4-35.8 106.4-.9.9-2 1.6-3 2.5 42.7 74.6 123 125 215.2 125s172.5-50.4 215.2-125.1c-1-.9-2.1-1.5-3-2.5-5.9-5.9-24-24-35.8-106.3zM400 152c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 12-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm-160 0c23.8 0 52.7 29.3 56 71.4.7 8.6-10.8 12-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.6 4-14.9-4.5 3.1-42.1 32-71.4 55.8-71.4zm80 280c-60.6 0-134.5-38.3-143.8-93.3-2-11.7 9.2-21.6 20.7-17.9C227.1 330.5 272 336 320 336s92.9-5.5 123.1-15.2c11.4-3.7 22.6 6.1 20.7 17.9-9.3 55-83.2 93.3-143.8 93.3z"]},Lo={prefix:"fas",iconName:"grin-tongue",icon:[496,512,[],"f589","M248 8C111 8 0 119 0 256c0 106.3 67 196.7 161 232-5.6-12.2-9-25.7-9-40v-45.5c-24.7-16.2-43.5-38.1-47.8-63.8-2-11.8 9.3-21.5 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.4-3.6 22.6 6.1 20.7 17.9-4.3 25.7-23.1 47.6-47.8 63.8V448c0 14.3-3.4 27.8-9 40 94-35.3 161-125.7 161-232C496 119 385 8 248 8zm-80 232c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm160 0c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm-34.9 134.6c-14.4-6.5-31.1 2.2-34.6 17.6l-1.8 7.8c-2.1 9.2-15.2 9.2-17.3 0l-1.8-7.8c-3.5-15.4-20.2-24.1-34.6-17.6-.9.4.3-.2-18.9 9.4v63c0 35.2 28 64.5 63.1 64.9 35.7.5 64.9-28.4 64.9-64v-64c-19.5-9.6-18.2-8.9-19-9.3z"]},No={prefix:"fas",iconName:"grin-tongue-squint",icon:[496,512,[],"f58a","M293.1 374.6c-14.4-6.5-31.1 2.2-34.6 17.6l-1.8 7.8c-2.1 9.2-15.2 9.2-17.3 0l-1.8-7.8c-3.5-15.4-20.2-24.1-34.6-17.6-.9.4.3-.2-18.9 9.4v63c0 35.2 28 64.5 63.1 64.9 35.7.5 64.9-28.4 64.9-64v-64c-19.5-9.6-18.2-8.9-19-9.3zM248 8C111 8 0 119 0 256c0 106.3 67 196.7 161 232-5.6-12.2-9-25.7-9-40v-45.5c-24.7-16.2-43.5-38.1-47.8-63.8-2-11.8 9.2-21.5 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.4-3.7 22.6 6.1 20.7 17.9-4.3 25.7-23.1 47.6-47.8 63.8V448c0 14.3-3.4 27.8-9 40 94-35.3 161-125.7 161-232C496 119 385 8 248 8zm-33.8 210.3l-80 48c-11.5 6.8-24-7.6-15.4-18l33.6-40.3-33.6-40.3c-8.6-10.3 3.8-24.9 15.4-18l80 48c7.7 4.7 7.7 15.9 0 20.6zm163 30c8.7 10.4-3.9 24.8-15.4 18l-80-48c-7.8-4.7-7.8-15.9 0-20.6l80-48c11.7-6.9 23.9 7.7 15.4 18L343.6 208l33.6 40.3z"]},Oo={prefix:"fas",iconName:"grin-tongue-wink",icon:[496,512,[],"f58b","M344 184c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zM248 8C111 8 0 119 0 256c0 106.3 67 196.7 161 232-5.6-12.2-9-25.7-9-40v-45.5c-24.7-16.2-43.5-38.1-47.8-63.8-2-11.8 9.3-21.5 20.7-17.9C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.5-3.7 22.6 6.1 20.7 17.9-4.3 25.7-23.1 47.6-47.8 63.8V448c0 14.3-3.4 27.8-9 40 94-35.3 161-125.7 161-232C496 119 385 8 248 8zm-56 225l-9.5-8.5c-14.8-13.2-46.2-13.2-61 0L112 233c-8.5 7.4-21.6.3-19.8-10.8 4-25.2 34.2-42.1 59.9-42.1S208 197 212 222.2c1.6 11.1-11.6 18.2-20 10.8zm152 39c-35.3 0-64-28.7-64-64s28.7-64 64-64 64 28.7 64 64-28.7 64-64 64zm-50.9 102.6c-14.4-6.5-31.1 2.2-34.6 17.6l-1.8 7.8c-2.1 9.2-15.2 9.2-17.3 0l-1.8-7.8c-3.5-15.4-20.2-24.1-34.6-17.6-.9.4.3-.2-18.9 9.4v63c0 35.2 28 64.5 63.1 64.9 35.7.5 64.9-28.4 64.9-64v-64c-19.5-9.6-18.2-8.9-19-9.3z"]},Fo={prefix:"fas",iconName:"grin-wink",icon:[496,512,[],"f58c","M0 256c0 137 111 248 248 248s248-111 248-248S385 8 248 8 0 119 0 256zm200-48c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32zm168 25l-9.5-8.5c-14.8-13.2-46.2-13.2-61 0L288 233c-8.3 7.4-21.6.4-19.8-10.8 4-25.2 34.2-42.1 59.9-42.1S384 197 388 222.2c1.6 11-11.5 18.2-20 10.8zm-243.1 87.8C155.1 330.5 200 336 248 336s92.9-5.5 123.1-15.2c11.3-3.7 22.6 6 20.7 17.9-9.2 55-83.2 93.3-143.8 93.3s-134.5-38.3-143.8-93.3c-2-11.9 9.3-21.6 20.7-17.9z"]},ko={prefix:"fas",iconName:"grip-horizontal",icon:[448,512,[],"f58d","M96 288H32c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm160 0h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm160 0h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zM96 96H32c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm160 0h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm160 0h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32z"]},Go={prefix:"fas",iconName:"grip-lines",icon:[512,512,[],"f7a4","M496 288H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm0-128H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h480c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16z"]},Vo={prefix:"fas",iconName:"grip-lines-vertical",icon:[256,512,[],"f7a5","M96 496V16c0-8.8-7.2-16-16-16H48c-8.8 0-16 7.2-16 16v480c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16zm128 0V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v480c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16z"]},Ho={prefix:"fas",iconName:"grip-vertical",icon:[320,512,[],"f58e","M96 32H32C14.33 32 0 46.33 0 64v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32zm0 160H32c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm0 160H32c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zM288 32h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32zm0 160h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32zm0 160h-64c-17.67 0-32 14.33-32 32v64c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-64c0-17.67-14.33-32-32-32z"]},Bo={prefix:"fas",iconName:"guitar",icon:[512,512,[],"f7a6","M502.63 39L473 9.37a32 32 0 0 0-45.26 0L381.46 55.7a35.14 35.14 0 0 0-8.53 13.79L360.77 106l-76.26 76.26c-12.16-8.76-25.5-15.74-40.1-19.14-33.45-7.78-67-.88-89.88 22a82.45 82.45 0 0 0-20.24 33.47c-6 18.56-23.21 32.69-42.15 34.46-23.7 2.27-45.73 11.45-62.61 28.44C-16.11 327-7.9 409 47.58 464.45S185 528 230.56 482.52c17-16.88 26.16-38.9 28.45-62.71 1.76-18.85 15.89-36.13 34.43-42.14a82.6 82.6 0 0 0 33.48-20.25c22.87-22.88 29.74-56.36 22-89.75-3.39-14.64-10.37-28-19.16-40.2L406 151.23l36.48-12.16a35.14 35.14 0 0 0 13.79-8.53l46.33-46.32a32 32 0 0 0 .03-45.22zM208 352a48 48 0 1 1 48-48 48 48 0 0 1-48 48z"]},zo={prefix:"fas",iconName:"h-square",icon:[448,512,[],"f0fd","M448 80v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48zm-112 48h-32c-8.837 0-16 7.163-16 16v80H160v-80c0-8.837-7.163-16-16-16h-32c-8.837 0-16 7.163-16 16v224c0 8.837 7.163 16 16 16h32c8.837 0 16-7.163 16-16v-80h128v80c0 8.837 7.163 16 16 16h32c8.837 0 16-7.163 16-16V144c0-8.837-7.163-16-16-16z"]},Uo={prefix:"fas",iconName:"hamburger",icon:[512,512,[],"f805","M464 256H48a48 48 0 0 0 0 96h416a48 48 0 0 0 0-96zm16 128H32a16 16 0 0 0-16 16v16a64 64 0 0 0 64 64h352a64 64 0 0 0 64-64v-16a16 16 0 0 0-16-16zM58.64 224h394.72c34.57 0 54.62-43.9 34.82-75.88C448 83.2 359.55 32.1 256 32c-103.54.1-192 51.2-232.18 116.11C4 180.09 24.07 224 58.64 224zM384 112a16 16 0 1 1-16 16 16 16 0 0 1 16-16zM256 80a16 16 0 1 1-16 16 16 16 0 0 1 16-16zm-128 32a16 16 0 1 1-16 16 16 16 0 0 1 16-16z"]},Wo={prefix:"fas",iconName:"hammer",icon:[576,512,[],"f6e3","M571.31 193.94l-22.63-22.63c-6.25-6.25-16.38-6.25-22.63 0l-11.31 11.31-28.9-28.9c5.63-21.31.36-44.9-16.35-61.61l-45.25-45.25c-62.48-62.48-163.79-62.48-226.28 0l90.51 45.25v18.75c0 16.97 6.74 33.25 18.75 45.25l49.14 49.14c16.71 16.71 40.3 21.98 61.61 16.35l28.9 28.9-11.31 11.31c-6.25 6.25-6.25 16.38 0 22.63l22.63 22.63c6.25 6.25 16.38 6.25 22.63 0l90.51-90.51c6.23-6.24 6.23-16.37-.02-22.62zm-286.72-15.2c-3.7-3.7-6.84-7.79-9.85-11.95L19.64 404.96c-25.57 23.88-26.26 64.19-1.53 88.93s65.05 24.05 88.93-1.53l238.13-255.07c-3.96-2.91-7.9-5.87-11.44-9.41l-49.14-49.14z"]},jo={prefix:"fas",iconName:"hamsa",icon:[512,512,[],"f665","M509.34 307.25C504.28 295.56 492.75 288 480 288h-64V80c0-22-18-40-40-40s-40 18-40 40v134c0 5.52-4.48 10-10 10h-20c-5.52 0-10-4.48-10-10V40c0-22-18-40-40-40s-40 18-40 40v174c0 5.52-4.48 10-10 10h-20c-5.52 0-10-4.48-10-10V80c0-22-18-40-40-40S96 58 96 80v208H32c-12.75 0-24.28 7.56-29.34 19.25a31.966 31.966 0 0 0 5.94 34.58l102.69 110.03C146.97 490.08 199.69 512 256 512s109.03-21.92 144.72-60.14L503.4 341.83a31.966 31.966 0 0 0 5.94-34.58zM256 416c-53.02 0-96-64-96-64s42.98-64 96-64 96 64 96 64-42.98 64-96 64zm0-96c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32z"]},Ko={prefix:"fas",iconName:"hand-holding",icon:[576,512,[],"f4bd","M565.3 328.1c-11.8-10.7-30.2-10-42.6 0L430.3 402c-11.3 9.1-25.4 14-40 14H272c-8.8 0-16-7.2-16-16s7.2-16 16-16h78.3c15.9 0 30.7-10.9 33.3-26.6 3.3-20-12.1-37.4-31.6-37.4H192c-27 0-53.1 9.3-74.1 26.3L71.4 384H16c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16h356.8c14.5 0 28.6-4.9 40-14L564 377c15.2-12.1 16.4-35.3 1.3-48.9z"]},$o={prefix:"fas",iconName:"hand-holding-heart",icon:[576,512,[],"f4be","M275.3 250.5c7 7.4 18.4 7.4 25.5 0l108.9-114.2c31.6-33.2 29.8-88.2-5.6-118.8-30.8-26.7-76.7-21.9-104.9 7.7L288 36.9l-11.1-11.6C248.7-4.4 202.8-9.2 172 17.5c-35.3 30.6-37.2 85.6-5.6 118.8l108.9 114.2zm290 77.6c-11.8-10.7-30.2-10-42.6 0L430.3 402c-11.3 9.1-25.4 14-40 14H272c-8.8 0-16-7.2-16-16s7.2-16 16-16h78.3c15.9 0 30.7-10.9 33.3-26.6 3.3-20-12.1-37.4-31.6-37.4H192c-27 0-53.1 9.3-74.1 26.3L71.4 384H16c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16h356.8c14.5 0 28.6-4.9 40-14L564 377c15.2-12.1 16.4-35.3 1.3-48.9z"]},qo={prefix:"fas",iconName:"hand-holding-medical",icon:[576,512,[],"e05c","M159.88,175.82h64v64a16,16,0,0,0,16,16h64a16,16,0,0,0,16-16v-64h64a16,16,0,0,0,16-16v-64a16,16,0,0,0-16-16h-64v-64a16,16,0,0,0-16-16h-64a16,16,0,0,0-16,16v64h-64a16,16,0,0,0-16,16v64A16,16,0,0,0,159.88,175.82ZM568.07,336.13a39.91,39.91,0,0,0-55.93-8.47L392.47,415.84H271.86a16,16,0,0,1,0-32H350.1c16,0,30.75-10.87,33.37-26.61a32.06,32.06,0,0,0-31.62-37.38h-160a117.7,117.7,0,0,0-74.12,26.25l-46.5,37.74H15.87a16.11,16.11,0,0,0-16,16v96a16.11,16.11,0,0,0,16,16h347a104.8,104.8,0,0,0,61.7-20.27L559.6,392A40,40,0,0,0,568.07,336.13Z"]},Yo={prefix:"fas",iconName:"hand-holding-usd",icon:[576,512,[],"f4c0","M271.06,144.3l54.27,14.3a8.59,8.59,0,0,1,6.63,8.1c0,4.6-4.09,8.4-9.12,8.4h-35.6a30,30,0,0,1-11.19-2.2c-5.24-2.2-11.28-1.7-15.3,2l-19,17.5a11.68,11.68,0,0,0-2.25,2.66,11.42,11.42,0,0,0,3.88,15.74,83.77,83.77,0,0,0,34.51,11.5V240c0,8.8,7.83,16,17.37,16h17.37c9.55,0,17.38-7.2,17.38-16V222.4c32.93-3.6,57.84-31,53.5-63-3.15-23-22.46-41.3-46.56-47.7L282.68,97.4a8.59,8.59,0,0,1-6.63-8.1c0-4.6,4.09-8.4,9.12-8.4h35.6A30,30,0,0,1,332,83.1c5.23,2.2,11.28,1.7,15.3-2l19-17.5A11.31,11.31,0,0,0,368.47,61a11.43,11.43,0,0,0-3.84-15.78,83.82,83.82,0,0,0-34.52-11.5V16c0-8.8-7.82-16-17.37-16H295.37C285.82,0,278,7.2,278,16V33.6c-32.89,3.6-57.85,31-53.51,63C227.63,119.6,247,137.9,271.06,144.3ZM565.27,328.1c-11.8-10.7-30.2-10-42.6,0L430.27,402a63.64,63.64,0,0,1-40,14H272a16,16,0,0,1,0-32h78.29c15.9,0,30.71-10.9,33.25-26.6a31.2,31.2,0,0,0,.46-5.46A32,32,0,0,0,352,320H192a117.66,117.66,0,0,0-74.1,26.29L71.4,384H16A16,16,0,0,0,0,400v96a16,16,0,0,0,16,16H372.77a64,64,0,0,0,40-14L564,377a32,32,0,0,0,1.28-48.9Z"]},Qo={prefix:"fas",iconName:"hand-holding-water",icon:[576,512,[],"f4c1","M288 256c53 0 96-42.1 96-94 0-40-57.1-120.7-83.2-155.6-6.4-8.5-19.2-8.5-25.6 0C249.1 41.3 192 122 192 162c0 51.9 43 94 96 94zm277.3 72.1c-11.8-10.7-30.2-10-42.6 0L430.3 402c-11.3 9.1-25.4 14-40 14H272c-8.8 0-16-7.2-16-16s7.2-16 16-16h78.3c15.9 0 30.7-10.9 33.3-26.6 3.3-20-12.1-37.4-31.6-37.4H192c-27 0-53.1 9.3-74.1 26.3L71.4 384H16c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16h356.8c14.5 0 28.6-4.9 40-14L564 377c15.2-12.1 16.4-35.3 1.3-48.9z"]},Xo={prefix:"fas",iconName:"hand-lizard",icon:[576,512,[],"f258","M384 480h192V363.778a95.998 95.998 0 0 0-14.833-51.263L398.127 54.368A48 48 0 0 0 357.544 32H24C10.745 32 0 42.745 0 56v16c0 30.928 25.072 56 56 56h229.981c12.844 0 21.556 13.067 16.615 24.923l-21.41 51.385A32 32 0 0 1 251.648 224H128c-35.346 0-64 28.654-64 64v8c0 13.255 10.745 24 24 24h147.406a47.995 47.995 0 0 1 25.692 7.455l111.748 70.811A24.001 24.001 0 0 1 384 418.539V480z"]},Zo={prefix:"fas",iconName:"hand-middle-finger",icon:[512,512,[],"f806","M479.93 317.12a37.33 37.33 0 0 0-28.28-36.19L416 272v-49.59c0-11.44-9.69-21.29-23.15-23.54l-38.4-6.4C336.63 189.5 320 200.86 320 216v32a8 8 0 0 1-16 0V50c0-26.28-20.25-49.2-46.52-50A48 48 0 0 0 208 48v200a8 8 0 0 1-16 0v-32c0-15.15-16.63-26.51-34.45-23.54l-30.68 5.12c-18 3-30.87 16.12-30.87 31.38V376a8 8 0 0 1-16 0v-76l-27.36 15A37.34 37.34 0 0 0 32 348.4v73.47a37.31 37.31 0 0 0 10.93 26.39l30.93 30.93A112 112 0 0 0 153.05 512h215A112 112 0 0 0 480 400z"]},Jo={prefix:"fas",iconName:"hand-paper",icon:[448,512,[],"f256","M408.781 128.007C386.356 127.578 368 146.36 368 168.79V256h-8V79.79c0-22.43-18.356-41.212-40.781-40.783C297.488 39.423 280 57.169 280 79v177h-8V40.79C272 18.36 253.644-.422 231.219.007 209.488.423 192 18.169 192 40v216h-8V80.79c0-22.43-18.356-41.212-40.781-40.783C121.488 40.423 104 58.169 104 80v235.992l-31.648-43.519c-12.993-17.866-38.009-21.817-55.877-8.823-17.865 12.994-21.815 38.01-8.822 55.877l125.601 172.705A48 48 0 0 0 172.073 512h197.59c22.274 0 41.622-15.324 46.724-37.006l26.508-112.66a192.011 192.011 0 0 0 5.104-43.975V168c.001-21.831-17.487-39.577-39.218-39.993z"]},ea={prefix:"fas",iconName:"hand-peace",icon:[448,512,[],"f25b","M408 216c-22.092 0-40 17.909-40 40h-8v-32c0-22.091-17.908-40-40-40s-40 17.909-40 40v32h-8V48c0-26.51-21.49-48-48-48s-48 21.49-48 48v208h-13.572L92.688 78.449C82.994 53.774 55.134 41.63 30.461 51.324 5.787 61.017-6.356 88.877 3.337 113.551l74.765 190.342-31.09 24.872c-15.381 12.306-19.515 33.978-9.741 51.081l64 112A39.998 39.998 0 0 0 136 512h240c18.562 0 34.686-12.77 38.937-30.838l32-136A39.97 39.97 0 0 0 448 336v-80c0-22.091-17.908-40-40-40z"]},ta={prefix:"fas",iconName:"hand-point-down",icon:[384,512,[],"f0a7","M91.826 467.2V317.966c-8.248 5.841-16.558 10.57-24.918 14.153C35.098 345.752-.014 322.222 0 288c.008-18.616 10.897-32.203 29.092-40 28.286-12.122 64.329-78.648 77.323-107.534 7.956-17.857 25.479-28.453 43.845-28.464l.001-.002h171.526c11.812 0 21.897 8.596 23.703 20.269 7.25 46.837 38.483 61.76 38.315 123.731-.007 2.724.195 13.254.195 16 0 50.654-22.122 81.574-71.263 72.6-9.297 18.597-39.486 30.738-62.315 16.45-21.177 24.645-53.896 22.639-70.944 6.299V467.2c0 24.15-20.201 44.8-43.826 44.8-23.283 0-43.826-21.35-43.826-44.8zM112 72V24c0-13.255 10.745-24 24-24h192c13.255 0 24 10.745 24 24v48c0 13.255-10.745 24-24 24H136c-13.255 0-24-10.745-24-24zm212-24c0-11.046-8.954-20-20-20s-20 8.954-20 20 8.954 20 20 20 20-8.954 20-20z"]},ia={prefix:"fas",iconName:"hand-point-left",icon:[512,512,[],"f0a5","M44.8 155.826h149.234c-5.841-8.248-10.57-16.558-14.153-24.918C166.248 99.098 189.778 63.986 224 64c18.616.008 32.203 10.897 40 29.092 12.122 28.286 78.648 64.329 107.534 77.323 17.857 7.956 28.453 25.479 28.464 43.845l.002.001v171.526c0 11.812-8.596 21.897-20.269 23.703-46.837 7.25-61.76 38.483-123.731 38.315-2.724-.007-13.254.195-16 .195-50.654 0-81.574-22.122-72.6-71.263-18.597-9.297-30.738-39.486-16.45-62.315-24.645-21.177-22.639-53.896-6.299-70.944H44.8c-24.15 0-44.8-20.201-44.8-43.826 0-23.283 21.35-43.826 44.8-43.826zM440 176h48c13.255 0 24 10.745 24 24v192c0 13.255-10.745 24-24 24h-48c-13.255 0-24-10.745-24-24V200c0-13.255 10.745-24 24-24zm24 212c11.046 0 20-8.954 20-20s-8.954-20-20-20-20 8.954-20 20 8.954 20 20 20z"]},ra={prefix:"fas",iconName:"hand-point-right",icon:[512,512,[],"f0a4","M512 199.652c0 23.625-20.65 43.826-44.8 43.826h-99.851c16.34 17.048 18.346 49.766-6.299 70.944 14.288 22.829 2.147 53.017-16.45 62.315C353.574 425.878 322.654 448 272 448c-2.746 0-13.276-.203-16-.195-61.971.168-76.894-31.065-123.731-38.315C120.596 407.683 112 397.599 112 385.786V214.261l.002-.001c.011-18.366 10.607-35.889 28.464-43.845 28.886-12.994 95.413-49.038 107.534-77.323 7.797-18.194 21.384-29.084 40-29.092 34.222-.014 57.752 35.098 44.119 66.908-3.583 8.359-8.312 16.67-14.153 24.918H467.2c23.45 0 44.8 20.543 44.8 43.826zM96 200v192c0 13.255-10.745 24-24 24H24c-13.255 0-24-10.745-24-24V200c0-13.255 10.745-24 24-24h48c13.255 0 24 10.745 24 24zM68 368c0-11.046-8.954-20-20-20s-20 8.954-20 20 8.954 20 20 20 20-8.954 20-20z"]},na={prefix:"fas",iconName:"hand-point-up",icon:[384,512,[],"f0a6","M135.652 0c23.625 0 43.826 20.65 43.826 44.8v99.851c17.048-16.34 49.766-18.346 70.944 6.299 22.829-14.288 53.017-2.147 62.315 16.45C361.878 158.426 384 189.346 384 240c0 2.746-.203 13.276-.195 16 .168 61.971-31.065 76.894-38.315 123.731C343.683 391.404 333.599 400 321.786 400H150.261l-.001-.002c-18.366-.011-35.889-10.607-43.845-28.464C93.421 342.648 57.377 276.122 29.092 264 10.897 256.203.008 242.616 0 224c-.014-34.222 35.098-57.752 66.908-44.119 8.359 3.583 16.67 8.312 24.918 14.153V44.8c0-23.45 20.543-44.8 43.826-44.8zM136 416h192c13.255 0 24 10.745 24 24v48c0 13.255-10.745 24-24 24H136c-13.255 0-24-10.745-24-24v-48c0-13.255 10.745-24 24-24zm168 28c-11.046 0-20 8.954-20 20s8.954 20 20 20 20-8.954 20-20-8.954-20-20-20z"]},sa={prefix:"fas",iconName:"hand-pointer",icon:[448,512,[],"f25a","M448 240v96c0 3.084-.356 6.159-1.063 9.162l-32 136C410.686 499.23 394.562 512 376 512H168a40.004 40.004 0 0 1-32.35-16.473l-127.997-176c-12.993-17.866-9.043-42.883 8.822-55.876 17.867-12.994 42.884-9.043 55.877 8.823L104 315.992V40c0-22.091 17.908-40 40-40s40 17.909 40 40v200h8v-40c0-22.091 17.908-40 40-40s40 17.909 40 40v40h8v-24c0-22.091 17.908-40 40-40s40 17.909 40 40v24h8c0-22.091 17.908-40 40-40s40 17.909 40 40zm-256 80h-8v96h8v-96zm88 0h-8v96h8v-96zm88 0h-8v96h8v-96z"]},oa={prefix:"fas",iconName:"hand-rock",icon:[512,512,[],"f255","M464.8 80c-26.9-.4-48.8 21.2-48.8 48h-8V96.8c0-26.3-20.9-48.3-47.2-48.8-26.9-.4-48.8 21.2-48.8 48v32h-8V80.8c0-26.3-20.9-48.3-47.2-48.8-26.9-.4-48.8 21.2-48.8 48v48h-8V96.8c0-26.3-20.9-48.3-47.2-48.8-26.9-.4-48.8 21.2-48.8 48v136l-8-7.1v-48.1c0-26.3-20.9-48.3-47.2-48.8C21.9 127.6 0 149.2 0 176v66.4c0 27.4 11.7 53.5 32.2 71.8l111.7 99.3c10.2 9.1 16.1 22.2 16.1 35.9v6.7c0 13.3 10.7 24 24 24h240c13.3 0 24-10.7 24-24v-2.9c0-12.8 2.6-25.5 7.5-37.3l49-116.3c5-11.8 7.5-24.5 7.5-37.3V128.8c0-26.3-20.9-48.4-47.2-48.8z"]},aa={prefix:"fas",iconName:"hand-scissors",icon:[512,512,[],"f257","M216 440c0-22.092 17.909-40 40-40v-8h-32c-22.091 0-40-17.908-40-40s17.909-40 40-40h32v-8H48c-26.51 0-48-21.49-48-48s21.49-48 48-48h208v-13.572l-177.551-69.74c-24.674-9.694-36.818-37.555-27.125-62.228 9.693-24.674 37.554-36.817 62.228-27.124l190.342 74.765 24.872-31.09c12.306-15.381 33.978-19.515 51.081-9.741l112 64A40.002 40.002 0 0 1 512 168v240c0 18.562-12.77 34.686-30.838 38.937l-136 32A39.982 39.982 0 0 1 336 480h-80c-22.091 0-40-17.908-40-40z"]},la={prefix:"fas",iconName:"hand-sparkles",icon:[640,512,[],"e05d","M106.66,170.64l.09,0,49.55-20.65a7.32,7.32,0,0,0,3.68-6h0a7.29,7.29,0,0,0-3.68-6l-49.57-20.67-.07,0L86,67.68a6.66,6.66,0,0,0-11.92,0l-20.7,49.63-.05,0L3.7,138A7.29,7.29,0,0,0,0,144H0a7.32,7.32,0,0,0,3.68,6L53.27,170.6l.07,0L74,220.26a6.65,6.65,0,0,0,11.92,0l20.69-49.62ZM471.38,467.41l-1-.42-1-.5a38.67,38.67,0,0,1,0-69.14l1-.49,1-.43,37.49-15.63,15.63-37.48.41-1,.47-.95c3.85-7.74,10.58-13.63,18.35-17.34,0-1.33.25-2.69.27-4V144a32,32,0,0,0-64,0v72a8,8,0,0,1-8,8H456a8,8,0,0,1-8-8V64a32,32,0,0,0-64,0V216a8,8,0,0,1-8,8H360a8,8,0,0,1-8-8V32a32,32,0,0,0-64,0V216a8,8,0,0,1-8,8H264a8,8,0,0,1-8-8V64a32,32,0,0,0-64,0v241l-23.59-32.49a40,40,0,0,0-64.71,47.09L229.3,492.21A48.07,48.07,0,0,0,268.09,512H465.7c19.24,0,35.65-11.73,43.24-28.79l-.07-.17ZM349.79,339.52,320,351.93l-12.42,29.78a4,4,0,0,1-7.15,0L288,351.93l-29.79-12.41a4,4,0,0,1,0-7.16L288,319.94l12.42-29.78a4,4,0,0,1,7.15,0L320,319.94l29.79,12.42a4,4,0,0,1,0,7.16ZM640,431.91a7.28,7.28,0,0,0-3.68-6l-49.57-20.67-.07,0L566,355.63a6.66,6.66,0,0,0-11.92,0l-20.7,49.63-.05,0L483.7,426a7.28,7.28,0,0,0-3.68,6h0a7.29,7.29,0,0,0,3.68,5.95l49.57,20.67.07,0L554,508.21a6.65,6.65,0,0,0,11.92,0l20.69-49.62h0l.09,0,49.55-20.66a7.29,7.29,0,0,0,3.68-5.95h0Z"]},ca={prefix:"fas",iconName:"hand-spock",icon:[512,512,[],"f259","M510.9005,145.27027,442.604,432.09391A103.99507,103.99507,0,0,1,341.43745,512H214.074a135.96968,135.96968,0,0,1-93.18489-36.95291L12.59072,373.12723a39.992,39.992,0,0,1,54.8122-58.24988l60.59342,57.02528v0a283.24849,283.24849,0,0,0-11.6703-80.46734L73.63726,147.36011a40.00575,40.00575,0,1,1,76.71833-22.7187l37.15458,125.39477a8.33113,8.33113,0,0,0,16.05656-4.4414L153.26183,49.95406A39.99638,39.99638,0,1,1,230.73015,30.0166l56.09491,218.15825a10.42047,10.42047,0,0,0,20.30018-.501L344.80766,63.96966a40.052,40.052,0,0,1,51.30245-30.0893c19.86073,6.2998,30.86262,27.67378,26.67564,48.08487l-33.83869,164.966a7.55172,7.55172,0,0,0,14.74406,3.2666l29.3973-123.45874a39.99414,39.99414,0,1,1,77.81208,18.53121Z"]},ua={prefix:"fas",iconName:"hands",icon:[640,512,[],"f4c2","M204.8 230.4c-10.6-14.1-30.7-17-44.8-6.4-14.1 10.6-17 30.7-6.4 44.8l38.1 50.8c4.8 6.4 4.1 15.3-1.5 20.9l-12.8 12.8c-6.7 6.7-17.6 6.2-23.6-1.1L64 244.4V96c0-17.7-14.3-32-32-32S0 78.3 0 96v218.4c0 10.9 3.7 21.5 10.5 30l104.1 134.3c5 6.5 8.4 13.9 10.4 21.7 1.8 6.9 8.1 11.6 15.3 11.6H272c8.8 0 16-7.2 16-16V384c0-27.7-9-54.6-25.6-76.8l-57.6-76.8zM608 64c-17.7 0-32 14.3-32 32v148.4l-89.8 107.8c-6 7.2-17 7.7-23.6 1.1l-12.8-12.8c-5.6-5.6-6.3-14.5-1.5-20.9l38.1-50.8c10.6-14.1 7.7-34.2-6.4-44.8-14.1-10.6-34.2-7.7-44.8 6.4l-57.6 76.8C361 329.4 352 356.3 352 384v112c0 8.8 7.2 16 16 16h131.7c7.1 0 13.5-4.7 15.3-11.6 2-7.8 5.4-15.2 10.4-21.7l104.1-134.3c6.8-8.5 10.5-19.1 10.5-30V96c0-17.7-14.3-32-32-32z"]},ha={prefix:"fas",iconName:"hands-helping",icon:[640,512,[],"f4c4","M488 192H336v56c0 39.7-32.3 72-72 72s-72-32.3-72-72V126.4l-64.9 39C107.8 176.9 96 197.8 96 220.2v47.3l-80 46.2C.7 322.5-4.6 342.1 4.3 357.4l80 138.6c8.8 15.3 28.4 20.5 43.7 11.7L231.4 448H368c35.3 0 64-28.7 64-64h16c17.7 0 32-14.3 32-32v-64h8c13.3 0 24-10.7 24-24v-48c0-13.3-10.7-24-24-24zm147.7-37.4L555.7 16C546.9.7 527.3-4.5 512 4.3L408.6 64H306.4c-12 0-23.7 3.4-33.9 9.7L239 94.6c-9.4 5.8-15 16.1-15 27.1V248c0 22.1 17.9 40 40 40s40-17.9 40-40v-88h184c30.9 0 56 25.1 56 56v28.5l80-46.2c15.3-8.9 20.5-28.4 11.7-43.7z"]},da={prefix:"fas",iconName:"hands-wash",icon:[576,512,[],"e05e","M496,224a48,48,0,1,0-48-48A48,48,0,0,0,496,224ZM311.47,178.45A56.77,56.77,0,0,1,328,176a56,56,0,0,1,19,3.49l15.35-48.61A24,24,0,0,0,342,99.74c-11.53-1.35-22.21,6.44-25.71,17.51l-20.9,66.17ZM93.65,386.33c.8-.19,1.54-.54,2.35-.71V359.93a156,156,0,0,1,107.06-148l73.7-22.76L310.92,81.05a24,24,0,0,0-20.33-31.11c-11.53-1.34-22.22,6.45-25.72,17.52L231.42,173.88a8,8,0,0,1-15.26-4.83L259.53,31.26A24,24,0,0,0,239.2.15C227.67-1.19,217,6.6,213.49,17.66L165.56,169.37a8,8,0,1,1-15.26-4.82l38.56-122a24,24,0,0,0-20.33-31.11C157,10,146.32,17.83,142.82,28.9l-60,189.85L80.76,168.7A24,24,0,0,0,56.9,144.55c-13.23-.05-24.72,10.54-24.9,23.86V281.14A123.69,123.69,0,0,0,93.65,386.33ZM519.1,336H360a8,8,0,0,1,0-16H488a24,24,0,0,0,23.54-28.76C509.35,279.84,498.71,272,487.1,272H288l47.09-17.06a24,24,0,0,0-14.18-45.88L213.19,242.31A123.88,123.88,0,0,0,128,360v25.65a79.78,79.78,0,0,1,58,108.63A118.9,118.9,0,0,0,248,512H456a24,24,0,0,0,23.54-28.76C477.35,471.84,466.71,464,455.1,464H360a8,8,0,0,1,0-16H488a24,24,0,0,0,23.54-28.76C509.35,407.84,498.71,400,487.1,400H360a8,8,0,0,1,0-16H520a24,24,0,0,0,23.54-28.76C541.35,343.84,530.71,336,519.1,336ZM416,64a32,32,0,1,0-32-32A32,32,0,0,0,416,64ZM112,416a48,48,0,1,0,48,48A48,48,0,0,0,112,416Z"]},pa={prefix:"fas",iconName:"handshake",icon:[640,512,[],"f2b5","M434.7 64h-85.9c-8 0-15.7 3-21.6 8.4l-98.3 90c-.1.1-.2.3-.3.4-16.6 15.6-16.3 40.5-2.1 56 12.7 13.9 39.4 17.6 56.1 2.7.1-.1.3-.1.4-.2l79.9-73.2c6.5-5.9 16.7-5.5 22.6 1 6 6.5 5.5 16.6-1 22.6l-26.1 23.9L504 313.8c2.9 2.4 5.5 5 7.9 7.7V128l-54.6-54.6c-5.9-6-14.1-9.4-22.6-9.4zM544 128.2v223.9c0 17.7 14.3 32 32 32h64V128.2h-96zm48 223.9c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zM0 384h64c17.7 0 32-14.3 32-32V128.2H0V384zm48-63.9c8.8 0 16 7.2 16 16s-7.2 16-16 16-16-7.2-16-16c0-8.9 7.2-16 16-16zm435.9 18.6L334.6 217.5l-30 27.5c-29.7 27.1-75.2 24.5-101.7-4.4-26.9-29.4-24.8-74.9 4.4-101.7L289.1 64h-83.8c-8.5 0-16.6 3.4-22.6 9.4L128 128v223.9h18.3l90.5 81.9c27.4 22.3 67.7 18.1 90-9.3l.2-.2 17.9 15.5c15.9 13 39.4 10.5 52.3-5.4l31.4-38.6 5.4 4.4c13.7 11.1 33.9 9.1 45-4.7l9.5-11.7c11.2-13.8 9.1-33.9-4.6-45.1z"]},ga={prefix:"fas",iconName:"handshake-alt-slash",icon:[640,512,[],"e05f","M358.59,195.6,504.2,313.8a63.4,63.4,0,0,1,22.21,37.91H624a16.05,16.05,0,0,0,16-16V143.91A16,16,0,0,0,624,128H512L457.41,73.41A32,32,0,0,0,434.8,64H348.91a32,32,0,0,0-21.61,8.41l-88.12,80.68-25.69-19.85L289.09,64H205.3a32,32,0,0,0-22.6,9.41l-20.34,20.3L45.47,3.38A16,16,0,0,0,23,6.19L3.38,31.46A16,16,0,0,0,6.19,53.91L594.54,508.63A16,16,0,0,0,617,505.82l19.64-25.27a16,16,0,0,0-2.81-22.45L303.4,202.72l32.69-29.92,27-24.7a16,16,0,0,1,21.61,23.61ZM16,128A16.05,16.05,0,0,0,0,144V335.91a16,16,0,0,0,16,16H146.3l90.5,81.89a64,64,0,0,0,90-9.3l.2-.2,17.91,15.5a37.16,37.16,0,0,0,52.29-5.39l8.8-10.82L23.56,128Z"]},fa={prefix:"fas",iconName:"handshake-slash",icon:[640,512,[],"e060","M0,128.21V384H64a32,32,0,0,0,32-32V184L23.83,128.21ZM48,320.1a16,16,0,1,1-16,16A16,16,0,0,1,48,320.1Zm80,31.81h18.3l90.5,81.89a64,64,0,0,0,90-9.3l.2-.2,17.91,15.5a37.16,37.16,0,0,0,52.29-5.39l8.8-10.82L128,208.72Zm416-223.7V352.1a32,32,0,0,0,32,32h64V128.21ZM592,352.1a16,16,0,1,1,16-16A16,16,0,0,1,592,352.1ZM303.33,202.67l59.58-54.57a16,16,0,0,1,21.59,23.61L358.41,195.6,504,313.8a73.08,73.08,0,0,1,7.91,7.7V128L457.3,73.41A31.76,31.76,0,0,0,434.7,64H348.8a31.93,31.93,0,0,0-21.6,8.41l-88.07,80.64-25.64-19.81L289.09,64H205.3a32,32,0,0,0-22.6,9.41L162.36,93.72,45.47,3.38A16,16,0,0,0,23,6.19L3.38,31.46A16,16,0,0,0,6.19,53.91L594.53,508.63A16,16,0,0,0,617,505.82l19.65-25.27a16,16,0,0,0-2.82-22.45Z"]},ma={prefix:"fas",iconName:"hanukiah",icon:[640,512,[],"f6e6","M232 160c-4.42 0-8 3.58-8 8v120h32V168c0-4.42-3.58-8-8-8h-16zm-64 0c-4.42 0-8 3.58-8 8v120h32V168c0-4.42-3.58-8-8-8h-16zm224 0c-4.42 0-8 3.58-8 8v120h32V168c0-4.42-3.58-8-8-8h-16zm64 0c-4.42 0-8 3.58-8 8v120h32V168c0-4.42-3.58-8-8-8h-16zm88 8c0-4.42-3.58-8-8-8h-16c-4.42 0-8 3.58-8 8v120h32V168zm-440-8c-4.42 0-8 3.58-8 8v120h32V168c0-4.42-3.58-8-8-8h-16zm520 0h-32c-8.84 0-16 7.16-16 16v112c0 17.67-14.33 32-32 32H352V128c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v192H96c-17.67 0-32-14.33-32-32V176c0-8.84-7.16-16-16-16H16c-8.84 0-16 7.16-16 16v112c0 53.02 42.98 96 96 96h192v64H112c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h416c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16H352v-64h192c53.02 0 96-42.98 96-96V176c0-8.84-7.16-16-16-16zm-16-32c13.25 0 24-11.94 24-26.67S608 48 608 48s-24 38.61-24 53.33S594.75 128 608 128zm-576 0c13.25 0 24-11.94 24-26.67S32 48 32 48 8 86.61 8 101.33 18.75 128 32 128zm288-48c13.25 0 24-11.94 24-26.67S320 0 320 0s-24 38.61-24 53.33S306.75 80 320 80zm-208 48c13.25 0 24-11.94 24-26.67S112 48 112 48s-24 38.61-24 53.33S98.75 128 112 128zm64 0c13.25 0 24-11.94 24-26.67S176 48 176 48s-24 38.61-24 53.33S162.75 128 176 128zm64 0c13.25 0 24-11.94 24-26.67S240 48 240 48s-24 38.61-24 53.33S226.75 128 240 128zm160 0c13.25 0 24-11.94 24-26.67S400 48 400 48s-24 38.61-24 53.33S386.75 128 400 128zm64 0c13.25 0 24-11.94 24-26.67S464 48 464 48s-24 38.61-24 53.33S450.75 128 464 128zm64 0c13.25 0 24-11.94 24-26.67S528 48 528 48s-24 38.61-24 53.33S514.75 128 528 128z"]},va={prefix:"fas",iconName:"hard-hat",icon:[512,512,[],"f807","M480 288c0-80.25-49.28-148.92-119.19-177.62L320 192V80a16 16 0 0 0-16-16h-96a16 16 0 0 0-16 16v112l-40.81-81.62C81.28 139.08 32 207.75 32 288v64h448zm16 96H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h480a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},Ca={prefix:"fas",iconName:"hashtag",icon:[448,512,[],"f292","M440.667 182.109l7.143-40c1.313-7.355-4.342-14.109-11.813-14.109h-74.81l14.623-81.891C377.123 38.754 371.468 32 363.997 32h-40.632a12 12 0 0 0-11.813 9.891L296.175 128H197.54l14.623-81.891C213.477 38.754 207.822 32 200.35 32h-40.632a12 12 0 0 0-11.813 9.891L132.528 128H53.432a12 12 0 0 0-11.813 9.891l-7.143 40C33.163 185.246 38.818 192 46.289 192h74.81L98.242 320H19.146a12 12 0 0 0-11.813 9.891l-7.143 40C-1.123 377.246 4.532 384 12.003 384h74.81L72.19 465.891C70.877 473.246 76.532 480 84.003 480h40.632a12 12 0 0 0 11.813-9.891L151.826 384h98.634l-14.623 81.891C234.523 473.246 240.178 480 247.65 480h40.632a12 12 0 0 0 11.813-9.891L315.472 384h79.096a12 12 0 0 0 11.813-9.891l7.143-40c1.313-7.355-4.342-14.109-11.813-14.109h-74.81l22.857-128h79.096a12 12 0 0 0 11.813-9.891zM261.889 320h-98.634l22.857-128h98.634l-22.857 128z"]},ya={prefix:"fas",iconName:"hat-cowboy",icon:[640,512,[],"f8c0","M490 296.9C480.51 239.51 450.51 64 392.3 64c-14 0-26.49 5.93-37 14a58.21 58.21 0 0 1-70.58 0c-10.51-8-23-14-37-14-58.2 0-88.2 175.47-97.71 232.88C188.81 309.47 243.73 320 320 320s131.23-10.51 170-23.1zm142.9-37.18a16 16 0 0 0-19.75 1.5c-1 .9-101.27 90.78-293.16 90.78-190.82 0-292.22-89.94-293.24-90.84A16 16 0 0 0 1 278.53C1.73 280.55 78.32 480 320 480s318.27-199.45 319-201.47a16 16 0 0 0-6.09-18.81z"]},wa={prefix:"fas",iconName:"hat-cowboy-side",icon:[640,512,[],"f8c1","M260.8 291.06c-28.63-22.94-62-35.06-96.4-35.06C87 256 21.47 318.72 1.43 412.06c-3.55 16.6-.43 33.83 8.57 47.3C18.75 472.47 31.83 480 45.88 480H592c-103.21 0-155-37.07-233.19-104.46zm234.65-18.29L468.4 116.2A64 64 0 0 0 392 64.41L200.85 105a64 64 0 0 0-50.35 55.79L143.61 226c6.9-.83 13.7-2 20.79-2 41.79 0 82 14.55 117.29 42.82l98 84.48C450.76 412.54 494.9 448 592 448a48 48 0 0 0 48-48c0-25.39-29.6-119.33-144.55-127.23z"]},Sa={prefix:"fas",iconName:"hat-wizard",icon:[512,512,[],"f6e8","M496 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h480c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm-304-64l-64-32 64-32 32-64 32 64 64 32-64 32-16 32h208l-86.41-201.63a63.955 63.955 0 0 1-1.89-45.45L416 0 228.42 107.19a127.989 127.989 0 0 0-53.46 59.15L64 416h144l-16-32zm64-224l16-32 16 32 32 16-32 16-16 32-16-32-32-16 32-16z"]},ba={prefix:"fas",iconName:"hdd",icon:[576,512,[],"f0a0","M576 304v96c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48v-96c0-26.51 21.49-48 48-48h480c26.51 0 48 21.49 48 48zm-48-80a79.557 79.557 0 0 1 30.777 6.165L462.25 85.374A48.003 48.003 0 0 0 422.311 64H153.689a48 48 0 0 0-39.938 21.374L17.223 230.165A79.557 79.557 0 0 1 48 224h480zm-48 96c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32zm-96 0c-17.673 0-32 14.327-32 32s14.327 32 32 32 32-14.327 32-32-14.327-32-32-32z"]},Ea={prefix:"fas",iconName:"head-side-cough",icon:[640,512,[],"e061","M616,304a24,24,0,1,0-24-24A24,24,0,0,0,616,304ZM552,416a24,24,0,1,0,24,24A24,24,0,0,0,552,416Zm-64-56a24,24,0,1,0,24,24A24,24,0,0,0,488,360ZM616,464a24,24,0,1,0,24,24A24,24,0,0,0,616,464Zm0-104a24,24,0,1,0,24,24A24,24,0,0,0,616,360Zm-64-40a24,24,0,1,0,24,24A24,24,0,0,0,552,320Zm-74.78-45c-21-47.12-48.5-151.75-73.12-186.75A208.13,208.13,0,0,0,234.1,0H192C86,0,0,86,0,192c0,56.75,24.75,107.62,64,142.88V512H288V480h64a64,64,0,0,0,64-64H320a32,32,0,0,1,0-64h96V320h32A32,32,0,0,0,477.22,275ZM288,224a32,32,0,1,1,32-32A32.07,32.07,0,0,1,288,224Z"]},Aa={prefix:"fas",iconName:"head-side-cough-slash",icon:[640,512,[],"e062","M454.11,319.21c19.56-3.81,31.62-25,23.11-44.21-21-47.12-48.5-151.75-73.12-186.75A208.13,208.13,0,0,0,234.1,0H192A190.64,190.64,0,0,0,84.18,33.3L45.46,3.38A16,16,0,0,0,23,6.19L3.37,31.46A16,16,0,0,0,6.18,53.91L594.53,508.63A16,16,0,0,0,617,505.82l19.64-25.27a16,16,0,0,0-2.81-22.45ZM313.39,210.45,263.61,172c5.88-7.14,14.43-12,24.36-12a32.06,32.06,0,0,1,32,32C320,199,317.24,205.17,313.39,210.45ZM616,304a24,24,0,1,0-24-24A24,24,0,0,0,616,304Zm-64,64a24,24,0,1,0-24-24A24,24,0,0,0,552,368ZM288,384a32,32,0,0,1,32-32h19.54L20.73,105.59A190.86,190.86,0,0,0,0,192c0,56.75,24.75,107.62,64,142.88V512H288V480h64a64,64,0,0,0,64-64H320A32,32,0,0,1,288,384Zm328-24a24,24,0,1,0,24,24A24,24,0,0,0,616,360Z"]},Ta={prefix:"fas",iconName:"head-side-mask",icon:[512,512,[],"e063","M.15,184.42C-2.17,244.21,23,298.06,64,334.88V512H224V316.51L3.67,156.25A182.28,182.28,0,0,0,.15,184.42ZM509.22,275c-21-47.12-48.5-151.75-73.12-186.75A208.11,208.11,0,0,0,266.11,0H200C117,0,42.48,50.57,13.25,123.65L239.21,288H511.76A31.35,31.35,0,0,0,509.22,275ZM320,224a32,32,0,1,1,32-32A32.07,32.07,0,0,1,320,224Zm16,144H496l16-48H256V512H401.88a64,64,0,0,0,60.71-43.76L464,464H336a16,16,0,0,1,0-32H474.67l10.67-32H336a16,16,0,0,1,0-32Z"]},Ma={prefix:"fas",iconName:"head-side-virus",icon:[512,512,[],"e064","M272,240a16,16,0,1,0,16,16A16,16,0,0,0,272,240Zm-64-64a16,16,0,1,0,16,16A16,16,0,0,0,208,176Zm301.2,99c-20.93-47.12-48.43-151.73-73.07-186.75A207.9,207.9,0,0,0,266.09,0H192C86,0,0,86,0,192A191.23,191.23,0,0,0,64,334.81V512H320V448h64a64,64,0,0,0,64-64V320H480A32,32,0,0,0,509.2,275ZM368,240H355.88c-28.51,0-42.79,34.47-22.63,54.63l8.58,8.57a16,16,0,1,1-22.63,22.63l-8.57-8.58C290.47,297.09,256,311.37,256,339.88V352a16,16,0,0,1-32,0V339.88c0-28.51-34.47-42.79-54.63-22.63l-8.57,8.58a16,16,0,0,1-22.63-22.63l8.58-8.57c20.16-20.16,5.88-54.63-22.63-54.63H112a16,16,0,0,1,0-32h12.12c28.51,0,42.79-34.47,22.63-54.63l-8.58-8.57a16,16,0,0,1,22.63-22.63l8.57,8.58c20.16,20.16,54.63,5.88,54.63-22.63V96a16,16,0,0,1,32,0v12.12c0,28.51,34.47,42.79,54.63,22.63l8.57-8.58a16,16,0,0,1,22.63,22.63l-8.58,8.57C313.09,173.53,327.37,208,355.88,208H368a16,16,0,0,1,0,32Z"]},Ra={prefix:"fas",iconName:"heading",icon:[512,512,[],"f1dc","M448 96v320h32a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16H320a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32V288H160v128h32a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16H32a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h32V96H32a16 16 0 0 1-16-16V48a16 16 0 0 1 16-16h160a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16h-32v128h192V96h-32a16 16 0 0 1-16-16V48a16 16 0 0 1 16-16h160a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16z"]},_a={prefix:"fas",iconName:"headphones",icon:[512,512,[],"f025","M256 32C114.52 32 0 146.496 0 288v48a32 32 0 0 0 17.689 28.622l14.383 7.191C34.083 431.903 83.421 480 144 480h24c13.255 0 24-10.745 24-24V280c0-13.255-10.745-24-24-24h-24c-31.342 0-59.671 12.879-80 33.627V288c0-105.869 86.131-192 192-192s192 86.131 192 192v1.627C427.671 268.879 399.342 256 368 256h-24c-13.255 0-24 10.745-24 24v176c0 13.255 10.745 24 24 24h24c60.579 0 109.917-48.098 111.928-108.187l14.382-7.191A32 32 0 0 0 512 336v-48c0-141.479-114.496-256-256-256z"]},Pa={prefix:"fas",iconName:"headphones-alt",icon:[512,512,[],"f58f","M160 288h-16c-35.35 0-64 28.7-64 64.12v63.76c0 35.41 28.65 64.12 64 64.12h16c17.67 0 32-14.36 32-32.06V320.06c0-17.71-14.33-32.06-32-32.06zm208 0h-16c-17.67 0-32 14.35-32 32.06v127.88c0 17.7 14.33 32.06 32 32.06h16c35.35 0 64-28.71 64-64.12v-63.76c0-35.41-28.65-64.12-64-64.12zM256 32C112.91 32 4.57 151.13 0 288v112c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16V288c0-114.67 93.33-207.8 208-207.82 114.67.02 208 93.15 208 207.82v112c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16V288C507.43 151.13 399.09 32 256 32z"]},xa={prefix:"fas",iconName:"headset",icon:[512,512,[],"f590","M192 208c0-17.67-14.33-32-32-32h-16c-35.35 0-64 28.65-64 64v48c0 35.35 28.65 64 64 64h16c17.67 0 32-14.33 32-32V208zm176 144c35.35 0 64-28.65 64-64v-48c0-35.35-28.65-64-64-64h-16c-17.67 0-32 14.33-32 32v112c0 17.67 14.33 32 32 32h16zM256 0C113.18 0 4.58 118.83 0 256v16c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-16c0-114.69 93.31-208 208-208s208 93.31 208 208h-.12c.08 2.43.12 165.72.12 165.72 0 23.35-18.93 42.28-42.28 42.28H320c0-26.51-21.49-48-48-48h-32c-26.51 0-48 21.49-48 48s21.49 48 48 48h181.72c49.86 0 90.28-40.42 90.28-90.28V256C507.42 118.83 398.82 0 256 0z"]},Da={prefix:"fas",iconName:"heart",icon:[512,512,[],"f004","M462.3 62.6C407.5 15.9 326 24.3 275.7 76.2L256 96.5l-19.7-20.3C186.1 24.3 104.5 15.9 49.7 62.6c-62.8 53.6-66.1 149.8-9.9 207.9l193.5 199.8c12.5 12.9 32.8 12.9 45.3 0l193.5-199.8c56.3-58.1 53-154.3-9.8-207.9z"]},Ia={prefix:"fas",iconName:"heart-broken",icon:[512,512,[],"f7a9","M473.7 73.8l-2.4-2.5c-46-47-118-51.7-169.6-14.8L336 159.9l-96 64 48 128-144-144 96-64-28.6-86.5C159.7 19.6 87 24 40.7 71.4l-2.4 2.4C-10.4 123.6-12.5 202.9 31 256l212.1 218.6c7.1 7.3 18.6 7.3 25.7 0L481 255.9c43.5-53 41.4-132.3-7.3-182.1z"]},La={prefix:"fas",iconName:"heartbeat",icon:[512,512,[],"f21e","M320.2 243.8l-49.7 99.4c-6 12.1-23.4 11.7-28.9-.6l-56.9-126.3-30 71.7H60.6l182.5 186.5c7.1 7.3 18.6 7.3 25.7 0L451.4 288H342.3l-22.1-44.2zM473.7 73.9l-2.4-2.5c-51.5-52.6-135.8-52.6-187.4 0L256 100l-27.9-28.5c-51.5-52.7-135.9-52.7-187.4 0l-2.4 2.4C-10.4 123.7-12.5 203 31 256h102.4l35.9-86.2c5.4-12.9 23.6-13.2 29.4-.4l58.2 129.3 49-97.9c5.9-11.8 22.7-11.8 28.6 0l27.6 55.2H481c43.5-53 41.4-132.3-7.3-182.1z"]},Na={prefix:"fas",iconName:"helicopter",icon:[640,512,[],"f533","M304 384h272c17.67 0 32-14.33 32-32 0-123.71-100.29-224-224-224V64h176c8.84 0 16-7.16 16-16V16c0-8.84-7.16-16-16-16H144c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h176v64H112L68.8 70.4C65.78 66.37 61.03 64 56 64H16.01C5.6 64-2.04 73.78.49 83.88L32 192l160 64 86.4 115.2A31.992 31.992 0 0 0 304 384zm112-188.49C478.55 208.3 528.03 257.44 540.79 320H416V195.51zm219.37 263.3l-22.15-22.2c-6.25-6.26-16.24-6.1-22.64.01-7.09 6.77-13.84 11.25-24.64 11.25H240c-8.84 0-16 7.18-16 16.03v32.06c0 8.85 7.16 16.03 16 16.03h325.94c14.88 0 35.3-.47 68.45-29.52 7.02-6.14 7.57-17.05.98-23.66z"]},Oa={prefix:"fas",iconName:"highlighter",icon:[544,512,[],"f591","M0 479.98L99.92 512l35.45-35.45-67.04-67.04L0 479.98zm124.61-240.01a36.592 36.592 0 0 0-10.79 38.1l13.05 42.83-50.93 50.94 96.23 96.23 50.86-50.86 42.74 13.08c13.73 4.2 28.65-.01 38.15-10.78l35.55-41.64-173.34-173.34-41.52 35.44zm403.31-160.7l-63.2-63.2c-20.49-20.49-53.38-21.52-75.12-2.35L190.55 183.68l169.77 169.78L530.27 154.4c19.18-21.74 18.15-54.63-2.35-75.13z"]},Fa={prefix:"fas",iconName:"hiking",icon:[384,512,[],"f6ec","M80.95 472.23c-4.28 17.16 6.14 34.53 23.28 38.81 2.61.66 5.22.95 7.8.95 14.33 0 27.37-9.7 31.02-24.23l25.24-100.97-52.78-52.78-34.56 138.22zm14.89-196.12L137 117c2.19-8.42-3.14-16.95-11.92-19.06-43.88-10.52-88.35 15.07-99.32 57.17L.49 253.24c-2.19 8.42 3.14 16.95 11.92 19.06l63.56 15.25c8.79 2.1 17.68-3.02 19.87-11.44zM368 160h-16c-8.84 0-16 7.16-16 16v16h-34.75l-46.78-46.78C243.38 134.11 228.61 128 212.91 128c-27.02 0-50.47 18.3-57.03 44.52l-26.92 107.72a32.012 32.012 0 0 0 8.42 30.39L224 397.25V480c0 17.67 14.33 32 32 32s32-14.33 32-32v-82.75c0-17.09-6.66-33.16-18.75-45.25l-46.82-46.82c.15-.5.49-.89.62-1.41l19.89-79.57 22.43 22.43c6 6 14.14 9.38 22.62 9.38h48v240c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16V176c.01-8.84-7.15-16-15.99-16zM240 96c26.51 0 48-21.49 48-48S266.51 0 240 0s-48 21.49-48 48 21.49 48 48 48z"]},ka={prefix:"fas",iconName:"hippo",icon:[640,512,[],"f6ed","M581.12 96.2c-27.67-.15-52.5 17.58-76.6 26.62C489.98 88.27 455.83 64 416 64c-11.28 0-21.95 2.3-32 5.88V56c0-13.26-10.75-24-24-24h-16c-13.25 0-24 10.74-24 24v48.98C286.01 79.58 241.24 64 192 64 85.96 64 0 135.64 0 224v240c0 8.84 7.16 16 16 16h64c8.84 0 16-7.16 16-16v-70.79C128.35 407.57 166.72 416 208 416s79.65-8.43 112-22.79V464c0 8.84 7.16 16 16 16h64c8.84 0 16-7.16 16-16V288h128v32c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-32c17.67 0 32-14.33 32-32v-92.02c0-34.09-24.79-67.59-58.88-67.78zM448 176c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16z"]},Ga={prefix:"fas",iconName:"history",icon:[512,512,[],"f1da","M504 255.531c.253 136.64-111.18 248.372-247.82 248.468-59.015.042-113.223-20.53-155.822-54.911-11.077-8.94-11.905-25.541-1.839-35.607l11.267-11.267c8.609-8.609 22.353-9.551 31.891-1.984C173.062 425.135 212.781 440 256 440c101.705 0 184-82.311 184-184 0-101.705-82.311-184-184-184-48.814 0-93.149 18.969-126.068 49.932l50.754 50.754c10.08 10.08 2.941 27.314-11.313 27.314H24c-8.837 0-16-7.163-16-16V38.627c0-14.254 17.234-21.393 27.314-11.314l49.372 49.372C129.209 34.136 189.552 8 256 8c136.81 0 247.747 110.78 248 247.531zm-180.912 78.784l9.823-12.63c8.138-10.463 6.253-25.542-4.21-33.679L288 256.349V152c0-13.255-10.745-24-24-24h-16c-13.255 0-24 10.745-24 24v135.651l65.409 50.874c10.463 8.137 25.541 6.253 33.679-4.21z"]},Va={prefix:"fas",iconName:"hockey-puck",icon:[512,512,[],"f453","M0 160c0-53 114.6-96 256-96s256 43 256 96-114.6 96-256 96S0 213 0 160zm0 82.2V352c0 53 114.6 96 256 96s256-43 256-96V242.2c-113.4 82.3-398.5 82.4-512 0z"]},Ha={prefix:"fas",iconName:"holly-berry",icon:[448,512,[],"f7aa","M144 192c26.5 0 48-21.5 48-48s-21.5-48-48-48-48 21.5-48 48 21.5 48 48 48zm112-48c0 26.5 21.5 48 48 48s48-21.5 48-48-21.5-48-48-48-48 21.5-48 48zm-32-48c26.5 0 48-21.5 48-48S250.5 0 224 0s-48 21.5-48 48 21.5 48 48 48zm-16.2 139.1c.1-12.4-13.1-20.1-23.8-13.7-34.3 20.3-71.4 32.7-108.7 36.2-9.7.9-15.6 11.3-11.6 20.2 6.2 13.9 11.1 28.6 14.7 43.8 3.6 15.2-5.3 30.6-20.2 35.1-14.9 4.5-30.1 7.6-45.3 9.1-9.7 1-15.7 11.3-11.7 20.2 15 32.8 22.9 69.5 23 107.7.1 14.4 15.2 23.1 27.6 16 33.2-19 68.9-30.5 104.8-33.9 9.7-.9 15.6-11.3 11.6-20.2-6.2-13.9-11.1-28.6-14.7-43.8-3.6-15.2 5.3-30.6 20.2-35.1 14.9-4.5 30.1-7.6 45.3-9.1 9.7-1 15.7-11.3 11.7-20.2-15.5-34.2-23.3-72.5-22.9-112.3zM435 365.6c-15.2-1.6-30.3-4.7-45.3-9.1-14.9-4.5-23.8-19.9-20.2-35.1 3.6-15.2 8.5-29.8 14.7-43.8 4-8.9-1.9-19.3-11.6-20.2-37.3-3.5-74.4-15.9-108.7-36.2-10.7-6.3-23.9 1.4-23.8 13.7 0 1.6-.2 3.2-.2 4.9.2 33.3 7 65.7 19.9 94 5.7 12.4 5.2 26.6-.6 38.9 4.9 1.2 9.9 2.2 14.8 3.7 14.9 4.5 23.8 19.9 20.2 35.1-3.6 15.2-8.5 29.8-14.7 43.8-4 8.9 1.9 19.3 11.6 20.2 35.9 3.4 71.6 14.9 104.8 33.9 12.5 7.1 27.6-1.6 27.6-16 .2-38.2 8-75 23-107.7 4.3-8.7-1.8-19.1-11.5-20.1z"]},Ba={prefix:"fas",iconName:"home",icon:[576,512,[],"f015","M280.37 148.26L96 300.11V464a16 16 0 0 0 16 16l112.06-.29a16 16 0 0 0 15.92-16V368a16 16 0 0 1 16-16h64a16 16 0 0 1 16 16v95.64a16 16 0 0 0 16 16.05L464 480a16 16 0 0 0 16-16V300L295.67 148.26a12.19 12.19 0 0 0-15.3 0zM571.6 251.47L488 182.56V44.05a12 12 0 0 0-12-12h-56a12 12 0 0 0-12 12v72.61L318.47 43a48 48 0 0 0-61 0L4.34 251.47a12 12 0 0 0-1.6 16.9l25.5 31A12 12 0 0 0 45.15 301l235.22-193.74a12.19 12.19 0 0 1 15.3 0L530.9 301a12 12 0 0 0 16.9-1.6l25.5-31a12 12 0 0 0-1.7-16.93z"]},za={prefix:"fas",iconName:"horse",icon:[576,512,[],"f6f0","M575.92 76.6c-.01-8.13-3.02-15.87-8.58-21.8-3.78-4.03-8.58-9.12-13.69-14.5 11.06-6.84 19.5-17.49 22.18-30.66C576.85 4.68 572.96 0 567.9 0H447.92c-70.69 0-128 57.31-128 128H160c-28.84 0-54.4 12.98-72 33.11V160c-48.53 0-88 39.47-88 88v56c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-56c0-13.22 6.87-24.39 16.78-31.68-.21 2.58-.78 5.05-.78 7.68 0 27.64 11.84 52.36 30.54 69.88l-25.72 68.6a63.945 63.945 0 0 0-2.16 37.99l24.85 99.41A15.982 15.982 0 0 0 107.02 512h65.96c10.41 0 18.05-9.78 15.52-19.88l-26.31-105.26 23.84-63.59L320 345.6V496c0 8.84 7.16 16 16 16h64c8.84 0 16-7.16 16-16V318.22c19.74-20.19 32-47.75 32-78.22 0-.22-.07-.42-.08-.64V136.89l16 7.11 18.9 37.7c7.45 14.87 25.05 21.55 40.49 15.37l32.55-13.02a31.997 31.997 0 0 0 20.12-29.74l-.06-77.71zm-64 19.4c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16z"]},Ua={prefix:"fas",iconName:"horse-head",icon:[512,512,[],"f7ab","M509.8 332.5l-69.9-164.3c-14.9-41.2-50.4-71-93-79.2 18-10.6 46.3-35.9 34.2-82.3-1.3-5-7.1-7.9-12-6.1L166.9 76.3C35.9 123.4 0 238.9 0 398.8V480c0 17.7 14.3 32 32 32h236.2c23.8 0 39.3-25 28.6-46.3L256 384v-.7c-45.6-3.5-84.6-30.7-104.3-69.6-1.6-3.1-.9-6.9 1.6-9.3l12.1-12.1c3.9-3.9 10.6-2.7 12.9 2.4 14.8 33.7 48.2 57.4 87.4 57.4 17.2 0 33-5.1 46.8-13.2l46 63.9c6 8.4 15.7 13.3 26 13.3h50.3c8.5 0 16.6-3.4 22.6-9.4l45.3-39.8c8.9-9.1 11.7-22.6 7.1-34.4zM328 224c-13.3 0-24-10.7-24-24s10.7-24 24-24 24 10.7 24 24-10.7 24-24 24z"]},Wa={prefix:"fas",iconName:"hospital",icon:[448,512,[],"f0f8","M448 492v20H0v-20c0-6.627 5.373-12 12-12h20V120c0-13.255 10.745-24 24-24h88V24c0-13.255 10.745-24 24-24h112c13.255 0 24 10.745 24 24v72h88c13.255 0 24 10.745 24 24v360h20c6.627 0 12 5.373 12 12zM308 192h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12zm-168 64h40c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12zm104 128h-40c-6.627 0-12 5.373-12 12v84h64v-84c0-6.627-5.373-12-12-12zm64-96h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12zm-116 12c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-40zM182 96h26v26a6 6 0 0 0 6 6h20a6 6 0 0 0 6-6V96h26a6 6 0 0 0 6-6V70a6 6 0 0 0-6-6h-26V38a6 6 0 0 0-6-6h-20a6 6 0 0 0-6 6v26h-26a6 6 0 0 0-6 6v20a6 6 0 0 0 6 6z"]},ja={prefix:"fas",iconName:"hospital-alt",icon:[576,512,[],"f47d","M544 96H416V32c0-17.7-14.3-32-32-32H192c-17.7 0-32 14.3-32 32v64H32c-17.7 0-32 14.3-32 32v368c0 8.8 7.2 16 16 16h544c8.8 0 16-7.2 16-16V128c0-17.7-14.3-32-32-32zM160 436c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-128c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm160 128c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-128c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm16-170c0 3.3-2.7 6-6 6h-26v26c0 3.3-2.7 6-6 6h-20c-3.3 0-6-2.7-6-6v-26h-26c-3.3 0-6-2.7-6-6v-20c0-3.3 2.7-6 6-6h26V86c0-3.3 2.7-6 6-6h20c3.3 0 6 2.7 6 6v26h26c3.3 0 6 2.7 6 6v20zm144 298c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40zm0-128c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h40c6.6 0 12 5.4 12 12v40z"]},Ka={prefix:"fas",iconName:"hospital-symbol",icon:[512,512,[],"f47e","M256 0C114.6 0 0 114.6 0 256s114.6 256 256 256 256-114.6 256-256S397.4 0 256 0zm112 376c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-88h-96v88c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8V136c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v88h96v-88c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v240z"]},$a={prefix:"fas",iconName:"hospital-user",icon:[640,512,[],"f80d","M480 320a96 96 0 1 0-96-96 96 96 0 0 0 96 96zm48 32a22.88 22.88 0 0 0-7.06 1.09 124.76 124.76 0 0 1-81.89 0A22.82 22.82 0 0 0 432 352a112 112 0 0 0-112 112.62c.14 26.26 21.73 47.38 48 47.38h224c26.27 0 47.86-21.12 48-47.38A112 112 0 0 0 528 352zm-198.09 10.45A145.19 145.19 0 0 1 352 344.62V128a32 32 0 0 0-32-32h-32V32a32 32 0 0 0-32-32H96a32 32 0 0 0-32 32v64H32a32 32 0 0 0-32 32v368a16 16 0 0 0 16 16h288.31A78.62 78.62 0 0 1 288 464.79a143.06 143.06 0 0 1 41.91-102.34zM144 404a12 12 0 0 1-12 12H92a12 12 0 0 1-12-12v-40a12 12 0 0 1 12-12h40a12 12 0 0 1 12 12zm0-128a12 12 0 0 1-12 12H92a12 12 0 0 1-12-12v-40a12 12 0 0 1 12-12h40a12 12 0 0 1 12 12zm48-122a6 6 0 0 1-6 6h-20a6 6 0 0 1-6-6v-26h-26a6 6 0 0 1-6-6v-20a6 6 0 0 1 6-6h26V70a6 6 0 0 1 6-6h20a6 6 0 0 1 6 6v26h26a6 6 0 0 1 6 6v20a6 6 0 0 1-6 6h-26zm80 250a12 12 0 0 1-12 12h-40a12 12 0 0 1-12-12v-40a12 12 0 0 1 12-12h40a12 12 0 0 1 12 12zm0-128a12 12 0 0 1-12 12h-40a12 12 0 0 1-12-12v-40a12 12 0 0 1 12-12h40a12 12 0 0 1 12 12z"]},qa={prefix:"fas",iconName:"hot-tub",icon:[512,512,[],"f593","M414.21 177.65c1.02 8.21 7.75 14.35 15.75 14.35h16.12c9.51 0 17.08-8.57 16-18.35-4.34-39.11-22.4-74.53-50.13-97.16-17.37-14.17-28.82-36.75-31.98-62.15C378.96 6.14 372.22 0 364.23 0h-16.12c-9.51 0-17.09 8.57-16 18.35 4.34 39.11 22.4 74.53 50.13 97.16 17.36 14.17 28.82 36.75 31.97 62.14zm-108 0c1.02 8.21 7.75 14.35 15.75 14.35h16.12c9.51 0 17.08-8.57 16-18.35-4.34-39.11-22.4-74.53-50.13-97.16-17.37-14.17-28.82-36.75-31.98-62.15C270.96 6.14 264.22 0 256.23 0h-16.12c-9.51 0-17.09 8.57-16 18.35 4.34 39.11 22.4 74.53 50.13 97.16 17.36 14.17 28.82 36.75 31.97 62.14zM480 256H256l-110.93-83.2a63.99 63.99 0 0 0-38.4-12.8H64c-35.35 0-64 28.65-64 64v224c0 35.35 28.65 64 64 64h384c35.35 0 64-28.65 64-64V288c0-17.67-14.33-32-32-32zM128 440c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8V328c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v112zm96 0c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8V328c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v112zm96 0c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8V328c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v112zm96 0c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8V328c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v112zM64 128c35.35 0 64-28.65 64-64S99.35 0 64 0 0 28.65 0 64s28.65 64 64 64z"]},Ya={prefix:"fas",iconName:"hotdog",icon:[512,512,[],"f80f","M488.56 23.44a80 80 0 0 0-113.12 0l-352 352a80 80 0 1 0 113.12 113.12l352-352a80 80 0 0 0 0-113.12zm-49.93 95.19c-19.6 19.59-37.52 22.67-51.93 25.14C373.76 146 364.4 147.6 352 160s-14 21.76-16.23 34.71c-2.48 14.4-5.55 32.33-25.15 51.92s-37.52 22.67-51.92 25.15C245.75 274 236.4 275.6 224 288s-14 21.75-16.23 34.7c-2.47 14.4-5.54 32.33-25.14 51.92s-37.53 22.68-51.93 25.15C117.76 402 108.4 403.6 96 416a16 16 0 0 1-22.63-22.63c19.6-19.59 37.52-22.67 51.92-25.14 13-2.22 22.3-3.82 34.71-16.23s14-21.75 16.22-34.7c2.48-14.4 5.55-32.33 25.15-51.92s37.52-22.67 51.92-25.14c13-2.22 22.3-3.83 34.7-16.23s14-21.76 16.24-34.71c2.47-14.4 5.54-32.33 25.14-51.92s37.52-22.68 51.92-25.15C394.24 110 403.59 108.41 416 96a16 16 0 0 1 22.63 22.63zM31.44 322.18L322.18 31.44l-11.54-11.55c-25-25-63.85-26.66-86.79-3.72L16.17 223.85c-22.94 22.94-21.27 61.79 3.72 86.78zm449.12-132.36L189.82 480.56l11.54 11.55c25 25 63.85 26.66 86.79 3.72l207.68-207.68c22.94-22.94 21.27-61.79-3.72-86.79z"]},Qa={prefix:"fas",iconName:"hotel",icon:[576,512,[],"f594","M560 64c8.84 0 16-7.16 16-16V16c0-8.84-7.16-16-16-16H16C7.16 0 0 7.16 0 16v32c0 8.84 7.16 16 16 16h15.98v384H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h240v-80c0-8.8 7.2-16 16-16h32c8.8 0 16 7.2 16 16v80h240c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16h-16V64h16zm-304 44.8c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4zm0 96c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4zm-128-96c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4zM179.2 256h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4c0 6.4-6.4 12.8-12.8 12.8zM192 384c0-53.02 42.98-96 96-96s96 42.98 96 96H192zm256-140.8c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4zm0-96c0 6.4-6.4 12.8-12.8 12.8h-38.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h38.4c6.4 0 12.8 6.4 12.8 12.8v38.4z"]},Xa={prefix:"fas",iconName:"hourglass",icon:[384,512,[],"f254","M360 64c13.255 0 24-10.745 24-24V24c0-13.255-10.745-24-24-24H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24 0 90.965 51.016 167.734 120.842 192C75.016 280.266 24 357.035 24 448c-13.255 0-24 10.745-24 24v16c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24 0-90.965-51.016-167.734-120.842-192C308.984 231.734 360 154.965 360 64z"]},Za={prefix:"fas",iconName:"hourglass-end",icon:[384,512,[],"f253","M360 64c13.255 0 24-10.745 24-24V24c0-13.255-10.745-24-24-24H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24 0 90.965 51.016 167.734 120.842 192C75.016 280.266 24 357.035 24 448c-13.255 0-24 10.745-24 24v16c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24 0-90.965-51.016-167.734-120.842-192C308.984 231.734 360 154.965 360 64zM192 208c-57.787 0-104-66.518-104-144h208c0 77.945-46.51 144-104 144z"]},Ja={prefix:"fas",iconName:"hourglass-half",icon:[384,512,[],"f252","M360 0H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24 0 90.965 51.016 167.734 120.842 192C75.016 280.266 24 357.035 24 448c-13.255 0-24 10.745-24 24v16c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24 0-90.965-51.016-167.734-120.842-192C308.984 231.734 360 154.965 360 64c13.255 0 24-10.745 24-24V24c0-13.255-10.745-24-24-24zm-75.078 384H99.08c17.059-46.797 52.096-80 92.92-80 40.821 0 75.862 33.196 92.922 80zm.019-256H99.078C91.988 108.548 88 86.748 88 64h208c0 22.805-3.987 44.587-11.059 64z"]},el={prefix:"fas",iconName:"hourglass-start",icon:[384,512,[],"f251","M360 0H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24 0 90.965 51.016 167.734 120.842 192C75.016 280.266 24 357.035 24 448c-13.255 0-24 10.745-24 24v16c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24 0-90.965-51.016-167.734-120.842-192C308.984 231.734 360 154.965 360 64c13.255 0 24-10.745 24-24V24c0-13.255-10.745-24-24-24zm-64 448H88c0-77.458 46.204-144 104-144 57.786 0 104 66.517 104 144z"]},tl={prefix:"fas",iconName:"house-damage",icon:[576,512,[],"f6f1","M288 114.96L69.47 307.71c-1.62 1.46-3.69 2.14-5.47 3.35V496c0 8.84 7.16 16 16 16h149.23L192 439.19l104.11-64-60.16-119.22L384 392.75l-104.11 64L319.81 512H496c8.84 0 16-7.16 16-16V311.1c-1.7-1.16-3.72-1.82-5.26-3.2L288 114.96zm282.69 121.32L512 184.45V48c0-8.84-7.16-16-16-16h-64c-8.84 0-16 7.16-16 16v51.69L314.75 10.31C307.12 3.45 297.56.01 288 0s-19.1 3.41-26.7 10.27L5.31 236.28c-6.57 5.91-7.12 16.02-1.21 22.6l21.4 23.82c5.9 6.57 16.02 7.12 22.6 1.21L277.42 81.63c6.05-5.33 15.12-5.33 21.17 0L527.91 283.9c6.57 5.9 16.69 5.36 22.6-1.21l21.4-23.82c5.9-6.57 5.36-16.69-1.22-22.59z"]},il={prefix:"fas",iconName:"house-user",icon:[576,512,[],"e065","M570.69,236.27,512,184.44V48a16,16,0,0,0-16-16H432a16,16,0,0,0-16,16V99.67L314.78,10.3C308.5,4.61,296.53,0,288,0s-20.46,4.61-26.74,10.3l-256,226A18.27,18.27,0,0,0,0,248.2a18.64,18.64,0,0,0,4.09,10.71L25.5,282.7a21.14,21.14,0,0,0,12,5.3,21.67,21.67,0,0,0,10.69-4.11l15.9-14V480a32,32,0,0,0,32,32H480a32,32,0,0,0,32-32V269.88l15.91,14A21.94,21.94,0,0,0,538.63,288a20.89,20.89,0,0,0,11.87-5.31l21.41-23.81A21.64,21.64,0,0,0,576,248.19,21,21,0,0,0,570.69,236.27ZM288,176a64,64,0,1,1-64,64A64,64,0,0,1,288,176ZM400,448H176a16,16,0,0,1-16-16,96,96,0,0,1,96-96h64a96,96,0,0,1,96,96A16,16,0,0,1,400,448Z"]},rl={prefix:"fas",iconName:"hryvnia",icon:[384,512,[],"f6f2","M368 240c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16h-41.86c13.41-28.63 13.74-63.33-4.13-94.05C303.34 49.84 267.1 32 229.96 32h-78.82c-24.32 0-47.86 8.53-66.54 24.09L72.83 65.9c-10.18 8.49-11.56 23.62-3.07 33.8l20.49 24.59c8.49 10.19 23.62 11.56 33.81 3.07l11.73-9.78c4.32-3.6 9.77-5.57 15.39-5.57h83.62c11.69 0 21.2 9.52 21.2 21.2 0 5.91-2.48 11.58-6.81 15.58L219.7 176H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h134.37l-34.67 32H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h41.86c-13.41 28.63-13.74 63.33 4.13 94.05C80.66 462.15 116.9 480 154.04 480h78.82c24.32 0 47.86-8.53 66.54-24.09l11.77-9.81c10.18-8.49 11.56-23.62 3.07-33.8l-20.49-24.59c-8.49-10.19-23.62-11.56-33.81-3.07l-11.75 9.8a23.992 23.992 0 0 1-15.36 5.56H149.2c-11.69 0-21.2-9.52-21.2-21.2 0-5.91 2.48-11.58 6.81-15.58L164.3 336H368c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16H233.63l34.67-32H368z"]},nl={prefix:"fas",iconName:"i-cursor",icon:[256,512,[],"f246","M256 52.048V12.065C256 5.496 250.726.148 244.158.066 211.621-.344 166.469.011 128 37.959 90.266.736 46.979-.114 11.913.114 5.318.157 0 5.519 0 12.114v39.645c0 6.687 5.458 12.078 12.145 11.998C38.111 63.447 96 67.243 96 112.182V224H60c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h36v112c0 44.932-56.075 48.031-83.95 47.959C5.404 447.942 0 453.306 0 459.952v39.983c0 6.569 5.274 11.917 11.842 11.999 32.537.409 77.689.054 116.158-37.894 37.734 37.223 81.021 38.073 116.087 37.845 6.595-.043 11.913-5.405 11.913-12V460.24c0-6.687-5.458-12.078-12.145-11.998C217.889 448.553 160 444.939 160 400V288h36c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-36V112.182c0-44.932 56.075-48.213 83.95-48.142 6.646.018 12.05-5.346 12.05-11.992z"]},sl={prefix:"fas",iconName:"ice-cream",icon:[448,512,[],"f810","M368 160h-.94a144 144 0 1 0-286.12 0H80a48 48 0 0 0 0 96h288a48 48 0 0 0 0-96zM195.38 493.69a31.52 31.52 0 0 0 57.24 0L352 288H96z"]},ol={prefix:"fas",iconName:"icicles",icon:[512,512,[],"f7ad","M511.4 37.9C515.1 18.2 500 0 480 0H32C10.6 0-4.8 20.7 1.4 41.2l87.1 273.4c2.5 7.2 12.7 7.2 15.1 0L140 190.5l44.2 187.3c1.9 8.3 13.7 8.3 15.6 0l46.5-196.9 34.1 133.4c2.3 7.6 13 7.6 15.3 0l45.8-172.5 66.7 363.8c1.7 8.6 14 8.6 15.7 0l87.5-467.7z"]},al={prefix:"fas",iconName:"icons",icon:[512,512,[],"f86d","M116.65 219.35a15.68 15.68 0 0 0 22.65 0l96.75-99.83c28.15-29 26.5-77.1-4.91-103.88C203.75-7.7 163-3.5 137.86 22.44L128 32.58l-9.85-10.14C93.05-3.5 52.25-7.7 24.86 15.64c-31.41 26.78-33 74.85-5 103.88zm143.92 100.49h-48l-7.08-14.24a27.39 27.39 0 0 0-25.66-17.78h-71.71a27.39 27.39 0 0 0-25.66 17.78l-7 14.24h-48A27.45 27.45 0 0 0 0 347.3v137.25A27.44 27.44 0 0 0 27.43 512h233.14A27.45 27.45 0 0 0 288 484.55V347.3a27.45 27.45 0 0 0-27.43-27.46zM144 468a52 52 0 1 1 52-52 52 52 0 0 1-52 52zm355.4-115.9h-60.58l22.36-50.75c2.1-6.65-3.93-13.21-12.18-13.21h-75.59c-6.3 0-11.66 3.9-12.5 9.1l-16.8 106.93c-1 6.3 4.88 11.89 12.5 11.89h62.31l-24.2 83c-1.89 6.65 4.2 12.9 12.23 12.9a13.26 13.26 0 0 0 10.92-5.25l92.4-138.91c4.88-6.91-1.16-15.7-10.87-15.7zM478.08.33L329.51 23.17C314.87 25.42 304 38.92 304 54.83V161.6a83.25 83.25 0 0 0-16-1.7c-35.35 0-64 21.48-64 48s28.65 48 64 48c35.2 0 63.73-21.32 64-47.66V99.66l112-17.22v47.18a83.25 83.25 0 0 0-16-1.7c-35.35 0-64 21.48-64 48s28.65 48 64 48c35.2 0 63.73-21.32 64-47.66V32c0-19.48-16-34.42-33.92-31.67z"]},ll={prefix:"fas",iconName:"id-badge",icon:[384,512,[],"f2c1","M336 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM144 32h96c8.8 0 16 7.2 16 16s-7.2 16-16 16h-96c-8.8 0-16-7.2-16-16s7.2-16 16-16zm48 128c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm112 236.8c0 10.6-10 19.2-22.4 19.2H102.4C90 416 80 407.4 80 396.8v-19.2c0-31.8 30.1-57.6 67.2-57.6h5c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h5c37.1 0 67.2 25.8 67.2 57.6v19.2z"]},cl={prefix:"fas",iconName:"id-card",icon:[576,512,[],"f2c2","M528 32H48C21.5 32 0 53.5 0 80v16h576V80c0-26.5-21.5-48-48-48zM0 432c0 26.5 21.5 48 48 48h480c26.5 0 48-21.5 48-48V128H0v304zm352-232c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16zm0 64c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16zm0 64c0-4.4 3.6-8 8-8h144c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H360c-4.4 0-8-3.6-8-8v-16zM176 192c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zM67.1 396.2C75.5 370.5 99.6 352 128 352h8.2c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h8.2c28.4 0 52.5 18.5 60.9 44.2 3.2 9.9-5.2 19.8-15.6 19.8H82.7c-10.4 0-18.8-10-15.6-19.8z"]},ul={prefix:"fas",iconName:"id-card-alt",icon:[576,512,[],"f47f","M528 64H384v96H192V64H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h480c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM288 224c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm93.3 224H194.7c-10.4 0-18.8-10-15.6-19.8 8.3-25.6 32.4-44.2 60.9-44.2h8.2c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h8.2c28.4 0 52.5 18.5 60.9 44.2 3.2 9.8-5.2 19.8-15.6 19.8zM352 32c0-17.7-14.3-32-32-32h-64c-17.7 0-32 14.3-32 32v96h128V32z"]},hl={prefix:"fas",iconName:"igloo",icon:[576,512,[],"f7ae","M320 33.9c-10.5-1.2-21.2-1.9-32-1.9-99.8 0-187.8 50.8-239.4 128H320V33.9zM96 192H30.3C11.1 230.6 0 274 0 320h96V192zM352 39.4V160h175.4C487.2 99.9 424.8 55.9 352 39.4zM480 320h96c0-46-11.1-89.4-30.3-128H480v128zm-64 64v96h128c17.7 0 32-14.3 32-32v-96H411.5c2.6 10.3 4.5 20.9 4.5 32zm32-192H128v128h49.8c22.2-38.1 63-64 110.2-64s88 25.9 110.2 64H448V192zM0 448c0 17.7 14.3 32 32 32h128v-96c0-11.1 1.9-21.7 4.5-32H0v96zm288-160c-53 0-96 43-96 96v96h192v-96c0-53-43-96-96-96z"]},dl={prefix:"fas",iconName:"image",icon:[512,512,[],"f03e","M464 448H48c-26.51 0-48-21.49-48-48V112c0-26.51 21.49-48 48-48h416c26.51 0 48 21.49 48 48v288c0 26.51-21.49 48-48 48zM112 120c-30.928 0-56 25.072-56 56s25.072 56 56 56 56-25.072 56-56-25.072-56-56-56zM64 384h384V272l-87.515-87.515c-4.686-4.686-12.284-4.686-16.971 0L208 320l-55.515-55.515c-4.686-4.686-12.284-4.686-16.971 0L64 336v48z"]},pl={prefix:"fas",iconName:"images",icon:[576,512,[],"f302","M480 416v16c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V176c0-26.51 21.49-48 48-48h16v208c0 44.112 35.888 80 80 80h336zm96-80V80c0-26.51-21.49-48-48-48H144c-26.51 0-48 21.49-48 48v256c0 26.51 21.49 48 48 48h384c26.51 0 48-21.49 48-48zM256 128c0 26.51-21.49 48-48 48s-48-21.49-48-48 21.49-48 48-48 48 21.49 48 48zm-96 144l55.515-55.515c4.686-4.686 12.284-4.686 16.971 0L272 256l135.515-135.515c4.686-4.686 12.284-4.686 16.971 0L512 208v112H160v-48z"]},gl={prefix:"fas",iconName:"inbox",icon:[576,512,[],"f01c","M567.938 243.908L462.25 85.374A48.003 48.003 0 0 0 422.311 64H153.689a48 48 0 0 0-39.938 21.374L8.062 243.908A47.994 47.994 0 0 0 0 270.533V400c0 26.51 21.49 48 48 48h480c26.51 0 48-21.49 48-48V270.533a47.994 47.994 0 0 0-8.062-26.625zM162.252 128h251.497l85.333 128H376l-32 64H232l-32-64H76.918l85.334-128z"]},fl={prefix:"fas",iconName:"indent",icon:[448,512,[],"f03c","M27.31 363.3l96-96a16 16 0 0 0 0-22.62l-96-96C17.27 138.66 0 145.78 0 160v192c0 14.31 17.33 21.3 27.31 11.3zM432 416H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm3.17-128H204.83A12.82 12.82 0 0 0 192 300.83v38.34A12.82 12.82 0 0 0 204.83 352h230.34A12.82 12.82 0 0 0 448 339.17v-38.34A12.82 12.82 0 0 0 435.17 288zm0-128H204.83A12.82 12.82 0 0 0 192 172.83v38.34A12.82 12.82 0 0 0 204.83 224h230.34A12.82 12.82 0 0 0 448 211.17v-38.34A12.82 12.82 0 0 0 435.17 160zM432 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},ml={prefix:"fas",iconName:"industry",icon:[512,512,[],"f275","M475.115 163.781L336 252.309v-68.28c0-18.916-20.931-30.399-36.885-20.248L160 252.309V56c0-13.255-10.745-24-24-24H24C10.745 32 0 42.745 0 56v400c0 13.255 10.745 24 24 24h464c13.255 0 24-10.745 24-24V184.029c0-18.917-20.931-30.399-36.885-20.248z"]},vl={prefix:"fas",iconName:"infinity",icon:[640,512,[],"f534","M471.1 96C405 96 353.3 137.3 320 174.6 286.7 137.3 235 96 168.9 96 75.8 96 0 167.8 0 256s75.8 160 168.9 160c66.1 0 117.8-41.3 151.1-78.6 33.3 37.3 85 78.6 151.1 78.6 93.1 0 168.9-71.8 168.9-160S564.2 96 471.1 96zM168.9 320c-40.2 0-72.9-28.7-72.9-64s32.7-64 72.9-64c38.2 0 73.4 36.1 94 64-20.4 27.6-55.9 64-94 64zm302.2 0c-38.2 0-73.4-36.1-94-64 20.4-27.6 55.9-64 94-64 40.2 0 72.9 28.7 72.9 64s-32.7 64-72.9 64z"]},Cl={prefix:"fas",iconName:"info",icon:[192,512,[],"f129","M20 424.229h20V279.771H20c-11.046 0-20-8.954-20-20V212c0-11.046 8.954-20 20-20h112c11.046 0 20 8.954 20 20v212.229h20c11.046 0 20 8.954 20 20V492c0 11.046-8.954 20-20 20H20c-11.046 0-20-8.954-20-20v-47.771c0-11.046 8.954-20 20-20zM96 0C56.235 0 24 32.235 24 72s32.235 72 72 72 72-32.235 72-72S135.764 0 96 0z"]},yl={prefix:"fas",iconName:"info-circle",icon:[512,512,[],"f05a","M256 8C119.043 8 8 119.083 8 256c0 136.997 111.043 248 248 248s248-111.003 248-248C504 119.083 392.957 8 256 8zm0 110c23.196 0 42 18.804 42 42s-18.804 42-42 42-42-18.804-42-42 18.804-42 42-42zm56 254c0 6.627-5.373 12-12 12h-88c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h12v-64h-12c-6.627 0-12-5.373-12-12v-24c0-6.627 5.373-12 12-12h64c6.627 0 12 5.373 12 12v100h12c6.627 0 12 5.373 12 12v24z"]},wl={prefix:"fas",iconName:"italic",icon:[320,512,[],"f033","M320 48v32a16 16 0 0 1-16 16h-62.76l-80 320H208a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16H16a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h62.76l80-320H112a16 16 0 0 1-16-16V48a16 16 0 0 1 16-16h192a16 16 0 0 1 16 16z"]},Sl={prefix:"fas",iconName:"jedi",icon:[576,512,[],"f669","M535.95308,352c-42.64069,94.17188-137.64086,160-247.9848,160q-6.39844,0-12.84377-.29688C171.15558,506.9375,81.26481,442.23438,40.01474,352H79.93668L21.3272,293.40625a264.82522,264.82522,0,0,1-5.10938-39.42187,273.6653,273.6653,0,0,1,.5-29.98438H63.93665L22.546,182.625A269.79782,269.79782,0,0,1,130.51489,20.54688a16.06393,16.06393,0,0,1,9.28127-3,16.36332,16.36332,0,0,1,13.5,7.25,16.02739,16.02739,0,0,1,1.625,15.09374,138.387,138.387,0,0,0-9.84376,51.26563c0,45.10937,21.04691,86.57813,57.71884,113.73437a16.29989,16.29989,0,0,1,1.20313,25.39063c-26.54692,23.98437-41.17194,56.5-41.17194,91.57813,0,60.03124,42.95319,110.28124,99.89079,121.92187l2.5-65.26563L238.062,397a8.33911,8.33911,0,0,1-10-.75,8.025,8.025,0,0,1-1.39063-9.9375l20.125-33.76562-42.06257-8.73438a7.9898,7.9898,0,0,1,0-15.65625l42.06257-8.71875-20.10941-33.73438a7.99122,7.99122,0,0,1,11.35939-10.71874L268.437,295.64062,279.95265,7.67188a7.97138,7.97138,0,0,1,8-7.67188h.04687a8.02064,8.02064,0,0,1,7.95314,7.70312L307.48394,295.625l30.39068-20.67188a8.08327,8.08327,0,0,1,10,.8125,7.99866,7.99866,0,0,1,1.39062,9.90626L329.12461,319.4375l42.07819,8.73438a7.99373,7.99373,0,0,1,0,15.65624l-42.07819,8.71876,20.1094,33.73437a7.97791,7.97791,0,0,1-1.32812,9.92187A8.25739,8.25739,0,0,1,337.87462,397L310.7027,378.53125l2.5,65.34375c48.48446-9.40625,87.57828-48.15625,97.31267-96.5A123.52652,123.52652,0,0,0,371.9528,230.29688a16.30634,16.30634,0,0,1,1.20313-25.42188c36.65631-27.17188,57.6876-68.60938,57.6876-113.73438a138.01689,138.01689,0,0,0-9.85939-51.3125,15.98132,15.98132,0,0,1,1.60937-15.09374,16.36914,16.36914,0,0,1,13.5-7.23438,16.02453,16.02453,0,0,1,9.25,2.98438A271.26947,271.26947,0,0,1,553.25,182.76562L511.99992,224h46.9532C559.3125,229.76562,560,235.45312,560,241.26562a270.092,270.092,0,0,1-5.125,51.85938L495.98427,352Z"]},bl={prefix:"fas",iconName:"joint",icon:[640,512,[],"f595","M444.34 181.1c22.38 15.68 35.66 41.16 35.66 68.59V280c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-30.31c0-43.24-21.01-83.41-56.34-108.06C463.85 125.02 448 99.34 448 70.31V8c0-4.42-3.58-8-8-8h-48c-4.42 0-8 3.58-8 8v66.4c0 43.69 24.56 81.63 60.34 106.7zM194.97 358.98C126.03 370.07 59.69 394.69 0 432c83.65 52.28 180.3 80 278.94 80h88.57L254.79 380.49c-14.74-17.2-37.45-25.11-59.82-21.51zM553.28 87.09c-5.67-3.8-9.28-9.96-9.28-16.78V8c0-4.42-3.58-8-8-8h-48c-4.42 0-8 3.58-8 8v62.31c0 22.02 10.17 43.41 28.64 55.39C550.79 153.04 576 199.54 576 249.69V280c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-30.31c0-65.44-32.41-126.19-86.72-162.6zM360.89 352.05c-34.4.06-86.81.15-88.21.17l117.8 137.43A63.987 63.987 0 0 0 439.07 512h88.45L409.57 374.4a63.955 63.955 0 0 0-48.68-22.35zM616 352H432l117.99 137.65A63.987 63.987 0 0 0 598.58 512H616c13.25 0 24-10.75 24-24V376c0-13.26-10.75-24-24-24z"]},El={prefix:"fas",iconName:"journal-whills",icon:[448,512,[],"f66a","M438.40625,377.59375c-3.20313,12.8125-3.20313,57.60937,0,73.60937Q447.9922,460.78907,448,470.40625v16c0,16-12.79688,25.59375-25.59375,25.59375H96c-54.40625,0-96-41.59375-96-96V96C0,41.59375,41.59375,0,96,0H422.40625C438.40625,0,448,9.59375,448,25.59375v332.8125Q448,372.79688,438.40625,377.59375ZM380.79688,384H96c-16,0-32,12.79688-32,32s12.79688,32,32,32H380.79688ZM128.01562,176.01562c0,.51563.14063.98438.14063,1.5l37.10937,32.46876A7.99954,7.99954,0,0,1,160,224h-.01562a9.17678,9.17678,0,0,1-5.25-1.98438L131.14062,201.375C142.6875,250.95312,186.90625,288,240,288s97.3125-37.04688,108.875-86.625l-23.59375,20.64062a8.02516,8.02516,0,0,1-5.26563,1.96876H320a9.14641,9.14641,0,0,1-6.01562-2.71876A9.26508,9.26508,0,0,1,312,216a9.097,9.097,0,0,1,2.73438-6.01562l37.10937-32.46876c.01563-.53124.15625-1,.15625-1.51562,0-11.04688-2.09375-21.51562-5.06251-31.59375l-21.26562,21.25a8.00467,8.00467,0,0,1-11.32812-11.3125l26.42187-26.40625a111.81517,111.81517,0,0,0-46.35937-49.26562,63.02336,63.02336,0,0,1-14.0625,82.64062A55.83846,55.83846,0,0,1,251.625,254.73438l-1.42188-34.28126,12.67188,8.625a3.967,3.967,0,0,0,2.25.6875,3.98059,3.98059,0,0,0,3.43749-6.03124l-8.53124-14.3125,17.90625-3.71876a4.00647,4.00647,0,0,0,0-7.84374l-17.90625-3.71876,8.53124-14.3125a3.98059,3.98059,0,0,0-3.43749-6.03124,4.726,4.726,0,0,0-2.25.67187L248.6875,184.125,244,71.82812a4.00386,4.00386,0,0,0-8,0l-4.625,110.8125-12-8.15624a4.003,4.003,0,0,0-5.68751,5.35937l8.53126,14.3125L204.3125,197.875a3.99686,3.99686,0,0,0,0,7.82812l17.90625,3.73438-8.53126,14.29688a4.72469,4.72469,0,0,0-.56249,2.04687,4.59547,4.59547,0,0,0,1.25,2.90625,4.01059,4.01059,0,0,0,2.75,1.09375,4.09016,4.09016,0,0,0,2.25-.6875l10.35937-7.04687L228.375,254.76562a55.86414,55.86414,0,0,1-28.71875-93.45312,63.01119,63.01119,0,0,1-14.04688-82.65625,111.93158,111.93158,0,0,0-46.375,49.26563l26.42187,26.42187a7.99917,7.99917,0,0,1-11.3125,11.3125l-21.26563-21.26563C130.09375,154.48438,128,164.95312,128.01562,176.01562Z"]},Al={prefix:"fas",iconName:"kaaba",icon:[576,512,[],"f66b","M554.12 83.51L318.36 4.93a95.962 95.962 0 0 0-60.71 0L21.88 83.51A32.006 32.006 0 0 0 0 113.87v49.01l265.02-79.51c15.03-4.5 30.92-4.5 45.98 0l265 79.51v-49.01c0-13.77-8.81-26-21.88-30.36zm-279.9 30.52L0 196.3v228.38c0 15 10.42 27.98 25.06 31.24l242.12 53.8a95.937 95.937 0 0 0 41.65 0l242.12-53.8c14.64-3.25 25.06-16.24 25.06-31.24V196.29l-274.2-82.26c-9.04-2.72-18.59-2.72-27.59 0zM128 230.11c0 3.61-2.41 6.77-5.89 7.72l-80 21.82C37.02 261.03 32 257.2 32 251.93v-16.58c0-3.61 2.41-6.77 5.89-7.72l80-21.82c5.09-1.39 10.11 2.44 10.11 7.72v16.58zm144-39.28c0 3.61-2.41 6.77-5.89 7.72l-96 26.18c-5.09 1.39-10.11-2.44-10.11-7.72v-16.58c0-3.61 2.41-6.77 5.89-7.72l96-26.18c5.09-1.39 10.11 2.44 10.11 7.72v16.58zm176 22.7c0-5.28 5.02-9.11 10.11-7.72l80 21.82c3.48.95 5.89 4.11 5.89 7.72v16.58c0 5.28-5.02 9.11-10.11 7.72l-80-21.82a7.997 7.997 0 0 1-5.89-7.72v-16.58zm-144-39.27c0-5.28 5.02-9.11 10.11-7.72l96 26.18c3.48.95 5.89 4.11 5.89 7.72v16.58c0 5.28-5.02 9.11-10.11 7.72l-96-26.18a7.997 7.997 0 0 1-5.89-7.72v-16.58z"]},Tl={prefix:"fas",iconName:"key",icon:[512,512,[],"f084","M512 176.001C512 273.203 433.202 352 336 352c-11.22 0-22.19-1.062-32.827-3.069l-24.012 27.014A23.999 23.999 0 0 1 261.223 384H224v40c0 13.255-10.745 24-24 24h-40v40c0 13.255-10.745 24-24 24H24c-13.255 0-24-10.745-24-24v-78.059c0-6.365 2.529-12.47 7.029-16.971l161.802-161.802C163.108 213.814 160 195.271 160 176 160 78.798 238.797.001 335.999 0 433.488-.001 512 78.511 512 176.001zM336 128c0 26.51 21.49 48 48 48s48-21.49 48-48-21.49-48-48-48-48 21.49-48 48z"]},Ml={prefix:"fas",iconName:"keyboard",icon:[576,512,[],"f11c","M528 448H48c-26.51 0-48-21.49-48-48V112c0-26.51 21.49-48 48-48h480c26.51 0 48 21.49 48 48v288c0 26.51-21.49 48-48 48zM128 180v-40c0-6.627-5.373-12-12-12H76c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm-336 96v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm-336 96v-40c0-6.627-5.373-12-12-12H76c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm288 0v-40c0-6.627-5.373-12-12-12H172c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h232c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12z"]},Rl={prefix:"fas",iconName:"khanda",icon:[512,512,[],"f66d","M415.81 66c-6.37-3.5-14.37-2.33-19.36 3.02a15.974 15.974 0 0 0-1.91 19.52c16.49 26.16 25.2 56.39 25.2 87.41-.19 53.25-26.77 102.69-71.27 132.41l-76.63 53.35v-20.1l44.05-36.09c3.92-4.2 5-10.09 2.81-15.28L310.85 273c33.84-19.26 56.94-55.25 56.94-96.99 0-40.79-22.02-76.13-54.59-95.71l5.22-11.44c2.34-5.53.93-11.83-3.57-16.04L255.86 0l-58.99 52.81c-4.5 4.21-5.9 10.51-3.57 16.04l5.22 11.44c-32.57 19.58-54.59 54.93-54.59 95.72 0 41.75 23.09 77.73 56.94 96.99l-7.85 17.24c-2.19 5.18-1.1 11.07 2.81 15.28l44.05 36.09v19.9l-76.59-53.33C119.02 278.62 92.44 229.19 92.26 176c0-31.08 8.71-61.31 25.2-87.47 3.87-6.16 2.4-13.77-2.59-19.08-5-5.34-13.68-6.2-20.02-2.7C16.32 109.6-22.3 205.3 13.36 295.99c7.07 17.99 17.89 34.38 30.46 49.06l55.97 65.36c4.87 5.69 13.04 7.24 19.65 3.72l79.35-42.23L228 392.23l-47.08 32.78c-1.67-.37-3.23-1.01-5.01-1.01-13.25 0-23.99 10.74-23.99 24 0 13.25 10.74 24 23.99 24 12.1 0 21.69-9.11 23.33-20.76l40.63-28.28v29.95c-9.39 5.57-15.99 15.38-15.99 27.1 0 17.67 14.32 32 31.98 32s31.98-14.33 31.98-32c0-11.71-6.61-21.52-15.99-27.1v-30.15l40.91 28.48C314.41 462.89 324 472 336.09 472c13.25 0 23.99-10.75 23.99-24 0-13.26-10.74-24-23.99-24-1.78 0-3.34.64-5.01 1.01L284 392.23l29.21-20.34 79.35 42.23c6.61 3.52 14.78 1.97 19.65-3.71l52.51-61.31c18.87-22.02 34-47.5 41.25-75.59 21.62-83.66-16.45-167.27-90.16-207.51zm-95.99 110c0 22.3-11.49 41.92-28.83 53.38l-5.65-12.41c-8.75-24.52-8.75-51.04 0-75.56l7.83-17.18c16.07 11.65 26.65 30.45 26.65 51.77zm-127.93 0c0-21.32 10.58-40.12 26.66-51.76l7.83 17.18c8.75 24.52 8.75 51.03 0 75.56l-5.65 12.41c-17.34-11.46-28.84-31.09-28.84-53.39z"]},_l={prefix:"fas",iconName:"kiss",icon:[496,512,[],"f596","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm-80 232c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm136 156c0 19.2-28.7 41.5-71.5 44-8.5.8-12.1-11.8-3.6-15.4l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-6-2.5-6.1-12.2 0-14.8l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-8.6-3.6-4.8-16.5 3.6-15.4 42.8 2.5 71.5 24.8 71.5 44 0 13-13.4 27.3-35.2 36C290.6 368.7 304 383 304 396zm24-156c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Pl={prefix:"fas",iconName:"kiss-beam",icon:[496,512,[],"f597","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm-39 219.9l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.6 4-14.9-4.5 3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.5 8.5-10.9 12-15.1 4.5zM304 396c0 19.2-28.7 41.5-71.5 44-8.5.8-12.1-11.8-3.6-15.4l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-6-2.5-6.1-12.2 0-14.8l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-8.6-3.6-4.8-16.5 3.6-15.4 42.8 2.5 71.5 24.8 71.5 44 0 13-13.4 27.3-35.2 36C290.6 368.7 304 383 304 396zm65-168.1l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.1 7.3-15.6 4-14.9-4.5 3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.5 8.5-10.9 12-15.1 4.5z"]},xl={prefix:"fas",iconName:"kiss-wink-heart",icon:[504,512,[],"f598","M501.1 402.5c-8-20.8-31.5-31.5-53.1-25.9l-8.4 2.2-2.3-8.4c-5.9-21.4-27-36.5-49-33-25.2 4-40.6 28.6-34 52.6l22.9 82.6c1.5 5.3 7 8.5 12.4 7.1l83-21.5c24.1-6.3 37.7-31.8 28.5-55.7zm-177.6-4c-5.6-20.3-2.3-42 9-59.7 29.7-46.3 98.7-45.5 127.8 4.3 6.4.1 12.6 1.4 18.6 2.9 10.9-27.9 17.1-58.2 17.1-90C496 119 385 8 248 8S0 119 0 256s111 248 248 248c35.4 0 68.9-7.5 99.4-20.9-.3-.7-23.9-84.6-23.9-84.6zM168 240c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm120 156c0 19.2-28.7 41.5-71.5 44-8.5.8-12.1-11.8-3.6-15.4l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-6-2.5-5.7-12.3 0-14.8l17-7.2c13-5.5 20.8-13.5 20.8-21.5s-7.8-16-20.8-21.5l-17-7.2c-8.8-3.7-4.6-16.6 3.6-15.4 42.8 2.5 71.5 24.8 71.5 44 0 13-13.4 27.3-35.2 36C274.6 368.7 288 383 288 396zm16-179c-8.3 7.4-21.6.4-19.8-10.8 4-25.2 34.2-42.1 59.9-42.1S400 181 404 206.2c1.7 11.1-11.3 18.3-19.8 10.8l-9.5-8.5c-14.8-13.2-46.2-13.2-61 0L304 217z"]},Dl={prefix:"fas",iconName:"kiwi-bird",icon:[576,512,[],"f535","M575.81 217.98C572.64 157.41 518.28 112 457.63 112h-9.37c-52.82 0-104.25-16.25-147.74-46.24-41.99-28.96-96.04-41.62-153.21-28.7C129.3 41.12-.08 78.24 0 224c.04 70.95 38.68 132.8 95.99 166.01V464c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-54.26c15.36 3.96 31.4 6.26 48 6.26 5.44 0 10.68-.73 16-1.18V464c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-59.43c14.24-5.06 27.88-11.39 40.34-19.51C342.07 355.25 393.86 336 448.46 336c25.48 0 16.01-.31 23.05-.78l74.41 136.44c2.86 5.23 8.3 8.34 14.05 8.34 1.31 0 2.64-.16 3.95-.5 7.09-1.8 12.05-8.19 12.05-15.5 0 0 .14-240.24-.16-246.02zM463.97 248c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24zm80 153.25l-39.86-73.08c15.12-5.83 28.73-14.6 39.86-25.98v99.06z"]},Il={prefix:"fas",iconName:"landmark",icon:[512,512,[],"f66f","M501.62 92.11L267.24 2.04a31.958 31.958 0 0 0-22.47 0L10.38 92.11A16.001 16.001 0 0 0 0 107.09V144c0 8.84 7.16 16 16 16h480c8.84 0 16-7.16 16-16v-36.91c0-6.67-4.14-12.64-10.38-14.98zM64 192v160H48c-8.84 0-16 7.16-16 16v48h448v-48c0-8.84-7.16-16-16-16h-16V192h-64v160h-96V192h-64v160h-96V192H64zm432 256H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h480c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},Ll={prefix:"fas",iconName:"language",icon:[640,512,[],"f1ab","M152.1 236.2c-3.5-12.1-7.8-33.2-7.8-33.2h-.5s-4.3 21.1-7.8 33.2l-11.1 37.5H163zM616 96H336v320h280c13.3 0 24-10.7 24-24V120c0-13.3-10.7-24-24-24zm-24 120c0 6.6-5.4 12-12 12h-11.4c-6.9 23.6-21.7 47.4-42.7 69.9 8.4 6.4 17.1 12.5 26.1 18 5.5 3.4 7.3 10.5 4.1 16.2l-7.9 13.9c-3.4 5.9-10.9 7.8-16.7 4.3-12.6-7.8-24.5-16.1-35.4-24.9-10.9 8.7-22.7 17.1-35.4 24.9-5.8 3.5-13.3 1.6-16.7-4.3l-7.9-13.9c-3.2-5.6-1.4-12.8 4.2-16.2 9.3-5.7 18-11.7 26.1-18-7.9-8.4-14.9-17-21-25.7-4-5.7-2.2-13.6 3.7-17.1l6.5-3.9 7.3-4.3c5.4-3.2 12.4-1.7 16 3.4 5 7 10.8 14 17.4 20.9 13.5-14.2 23.8-28.9 30-43.2H412c-6.6 0-12-5.4-12-12v-16c0-6.6 5.4-12 12-12h64v-16c0-6.6 5.4-12 12-12h16c6.6 0 12 5.4 12 12v16h64c6.6 0 12 5.4 12 12zM0 120v272c0 13.3 10.7 24 24 24h280V96H24c-13.3 0-24 10.7-24 24zm58.9 216.1L116.4 167c1.7-4.9 6.2-8.1 11.4-8.1h32.5c5.1 0 9.7 3.3 11.4 8.1l57.5 169.1c2.6 7.8-3.1 15.9-11.4 15.9h-22.9a12 12 0 0 1-11.5-8.6l-9.4-31.9h-60.2l-9.1 31.8c-1.5 5.1-6.2 8.7-11.5 8.7H70.3c-8.2 0-14-8.1-11.4-15.9z"]},Nl={prefix:"fas",iconName:"laptop",icon:[640,512,[],"f109","M624 416H381.54c-.74 19.81-14.71 32-32.74 32H288c-18.69 0-33.02-17.47-32.77-32H16c-8.8 0-16 7.2-16 16v16c0 35.2 28.8 64 64 64h512c35.2 0 64-28.8 64-64v-16c0-8.8-7.2-16-16-16zM576 48c0-26.4-21.6-48-48-48H112C85.6 0 64 21.6 64 48v336h512V48zm-64 272H128V64h384v256z"]},Ol={prefix:"fas",iconName:"laptop-code",icon:[640,512,[],"f5fc","M255.03 261.65c6.25 6.25 16.38 6.25 22.63 0l11.31-11.31c6.25-6.25 6.25-16.38 0-22.63L253.25 192l35.71-35.72c6.25-6.25 6.25-16.38 0-22.63l-11.31-11.31c-6.25-6.25-16.38-6.25-22.63 0l-58.34 58.34c-6.25 6.25-6.25 16.38 0 22.63l58.35 58.34zm96.01-11.3l11.31 11.31c6.25 6.25 16.38 6.25 22.63 0l58.34-58.34c6.25-6.25 6.25-16.38 0-22.63l-58.34-58.34c-6.25-6.25-16.38-6.25-22.63 0l-11.31 11.31c-6.25 6.25-6.25 16.38 0 22.63L386.75 192l-35.71 35.72c-6.25 6.25-6.25 16.38 0 22.63zM624 416H381.54c-.74 19.81-14.71 32-32.74 32H288c-18.69 0-33.02-17.47-32.77-32H16c-8.8 0-16 7.2-16 16v16c0 35.2 28.8 64 64 64h512c35.2 0 64-28.8 64-64v-16c0-8.8-7.2-16-16-16zM576 48c0-26.4-21.6-48-48-48H112C85.6 0 64 21.6 64 48v336h512V48zm-64 272H128V64h384v256z"]},Fl={prefix:"fas",iconName:"laptop-house",icon:[640,512,[],"e066","M272,288H208a16,16,0,0,1-16-16V208a16,16,0,0,1,16-16h64a16,16,0,0,1,16,16v37.12C299.11,232.24,315,224,332.8,224H469.74l6.65-7.53A16.51,16.51,0,0,0,480,207a16.31,16.31,0,0,0-4.75-10.61L416,144V48a16,16,0,0,0-16-16H368a16,16,0,0,0-16,16V87.3L263.5,8.92C258,4,247.45,0,240.05,0s-17.93,4-23.47,8.92L4.78,196.42A16.15,16.15,0,0,0,0,207a16.4,16.4,0,0,0,3.55,9.39L22.34,237.7A16.22,16.22,0,0,0,33,242.48,16.51,16.51,0,0,0,42.34,239L64,219.88V384a32,32,0,0,0,32,32H272ZM629.33,448H592V288c0-17.67-12.89-32-28.8-32H332.8c-15.91,0-28.8,14.33-28.8,32V448H266.67A10.67,10.67,0,0,0,256,458.67v10.66A42.82,42.82,0,0,0,298.6,512H597.4A42.82,42.82,0,0,0,640,469.33V458.67A10.67,10.67,0,0,0,629.33,448ZM544,448H352V304H544Z"]},kl={prefix:"fas",iconName:"laptop-medical",icon:[640,512,[],"f812","M232 224h56v56a8 8 0 0 0 8 8h48a8 8 0 0 0 8-8v-56h56a8 8 0 0 0 8-8v-48a8 8 0 0 0-8-8h-56v-56a8 8 0 0 0-8-8h-48a8 8 0 0 0-8 8v56h-56a8 8 0 0 0-8 8v48a8 8 0 0 0 8 8zM576 48a48.14 48.14 0 0 0-48-48H112a48.14 48.14 0 0 0-48 48v336h512zm-64 272H128V64h384zm112 96H381.54c-.74 19.81-14.71 32-32.74 32H288c-18.69 0-33-17.47-32.77-32H16a16 16 0 0 0-16 16v16a64.19 64.19 0 0 0 64 64h512a64.19 64.19 0 0 0 64-64v-16a16 16 0 0 0-16-16z"]},Gl={prefix:"fas",iconName:"laugh",icon:[496,512,[],"f599","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 152c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm-160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm88 272h-16c-73.4 0-134-55-142.9-126-1.2-9.5 6.3-18 15.9-18h270c9.6 0 17.1 8.4 15.9 18-8.9 71-69.5 126-142.9 126z"]},Vl={prefix:"fas",iconName:"laugh-beam",icon:[496,512,[],"f59a","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm24 199.4c3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.7 8.6-10.8 11.9-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.2 7.4-15.8 4.1-15.1-4.5zm-160 0c3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.7 8.6-10.8 11.9-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.3 7.4-15.8 4-15.1-4.5zM398.9 306C390 377 329.4 432 256 432h-16c-73.4 0-134-55-142.9-126-1.2-9.5 6.3-18 15.9-18h270c9.6 0 17.1 8.4 15.9 18z"]},Hl={prefix:"fas",iconName:"laugh-squint",icon:[496,512,[],"f59b","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm33.8 161.7l80-48c11.6-6.9 24 7.7 15.4 18L343.6 180l33.6 40.3c8.7 10.4-3.9 24.8-15.4 18l-80-48c-7.7-4.7-7.7-15.9 0-20.6zm-163-30c-8.6-10.3 3.8-24.9 15.4-18l80 48c7.8 4.7 7.8 15.9 0 20.6l-80 48c-11.5 6.8-24-7.6-15.4-18l33.6-40.3-33.6-40.3zM398.9 306C390 377 329.4 432 256 432h-16c-73.4 0-134-55-142.9-126-1.2-9.5 6.3-18 15.9-18h270c9.6 0 17.1 8.4 15.9 18z"]},Bl={prefix:"fas",iconName:"laugh-wink",icon:[496,512,[],"f59c","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm20.1 198.1c4-25.2 34.2-42.1 59.9-42.1s55.9 16.9 59.9 42.1c1.7 11.1-11.4 18.3-19.8 10.8l-9.5-8.5c-14.8-13.2-46.2-13.2-61 0L288 217c-8.4 7.4-21.6.3-19.9-10.9zM168 160c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm230.9 146C390 377 329.4 432 256 432h-16c-73.4 0-134-55-142.9-126-1.2-9.5 6.3-18 15.9-18h270c9.6 0 17.1 8.4 15.9 18z"]},zl={prefix:"fas",iconName:"layer-group",icon:[512,512,[],"f5fd","M12.41 148.02l232.94 105.67c6.8 3.09 14.49 3.09 21.29 0l232.94-105.67c16.55-7.51 16.55-32.52 0-40.03L266.65 2.31a25.607 25.607 0 0 0-21.29 0L12.41 107.98c-16.55 7.51-16.55 32.53 0 40.04zm487.18 88.28l-58.09-26.33-161.64 73.27c-7.56 3.43-15.59 5.17-23.86 5.17s-16.29-1.74-23.86-5.17L70.51 209.97l-58.1 26.33c-16.55 7.5-16.55 32.5 0 40l232.94 105.59c6.8 3.08 14.49 3.08 21.29 0L499.59 276.3c16.55-7.5 16.55-32.5 0-40zm0 127.8l-57.87-26.23-161.86 73.37c-7.56 3.43-15.59 5.17-23.86 5.17s-16.29-1.74-23.86-5.17L70.29 337.87 12.41 364.1c-16.55 7.5-16.55 32.5 0 40l232.94 105.59c6.8 3.08 14.49 3.08 21.29 0L499.59 404.1c16.55-7.5 16.55-32.5 0-40z"]},Ul={prefix:"fas",iconName:"leaf",icon:[576,512,[],"f06c","M546.2 9.7c-5.6-12.5-21.6-13-28.3-1.2C486.9 62.4 431.4 96 368 96h-80C182 96 96 182 96 288c0 7 .8 13.7 1.5 20.5C161.3 262.8 253.4 224 384 224c8.8 0 16 7.2 16 16s-7.2 16-16 16C132.6 256 26 410.1 2.4 468c-6.6 16.3 1.2 34.9 17.5 41.6 16.4 6.8 35-1.1 41.8-17.3 1.5-3.6 20.9-47.9 71.9-90.6 32.4 43.9 94 85.8 174.9 77.2C465.5 467.5 576 326.7 576 154.3c0-50.2-10.8-102.2-29.8-144.6z"]},Wl={prefix:"fas",iconName:"lemon",icon:[512,512,[],"f094","M489.038 22.963C465.944-.13 434.648-5.93 413.947 6.129c-58.906 34.312-181.25-53.077-321.073 86.746S40.441 355.041 6.129 413.945c-12.059 20.702-6.26 51.999 16.833 75.093 23.095 23.095 54.392 28.891 75.095 16.832 58.901-34.31 181.246 53.079 321.068-86.743S471.56 156.96 505.871 98.056c12.059-20.702 6.261-51.999-16.833-75.093zM243.881 95.522c-58.189 14.547-133.808 90.155-148.358 148.358-1.817 7.27-8.342 12.124-15.511 12.124-1.284 0-2.59-.156-3.893-.481-8.572-2.144-13.784-10.83-11.642-19.403C81.901 166.427 166.316 81.93 236.119 64.478c8.575-2.143 17.261 3.069 19.403 11.642s-3.069 17.259-11.641 19.402z"]},jl={prefix:"fas",iconName:"less-than",icon:[384,512,[],"f536","M365.46 357.74L147.04 255.89l218.47-101.88c16.02-7.47 22.95-26.51 15.48-42.53l-13.52-29C360 66.46 340.96 59.53 324.94 67L18.48 209.91a32.014 32.014 0 0 0-18.48 29v34.24c0 12.44 7.21 23.75 18.48 29l306.31 142.83c16.06 7.49 35.15.54 42.64-15.52l13.56-29.08c7.49-16.06.54-35.15-15.53-42.64z"]},Kl={prefix:"fas",iconName:"less-than-equal",icon:[448,512,[],"f537","M54.98 214.2l301.41 119.87c18.39 6.03 38.71-2.54 45.38-19.15l12.09-30.08c6.68-16.61-2.82-34.97-21.21-41l-175.44-68.05 175.56-68.09c18.29-6 27.74-24.27 21.1-40.79l-12.03-29.92c-6.64-16.53-26.86-25.06-45.15-19.06L54.98 137.89C41.21 142.41 32 154.5 32 168.07v15.96c0 13.56 9.21 25.65 22.98 30.17zM424 400H24c-13.25 0-24 10.74-24 24v48c0 13.25 10.75 24 24 24h400c13.25 0 24-10.75 24-24v-48c0-13.26-10.75-24-24-24z"]},$l={prefix:"fas",iconName:"level-down-alt",icon:[320,512,[],"f3be","M313.553 392.331L209.587 504.334c-9.485 10.214-25.676 10.229-35.174 0L70.438 392.331C56.232 377.031 67.062 352 88.025 352H152V80H68.024a11.996 11.996 0 0 1-8.485-3.515l-56-56C-4.021 12.926 1.333 0 12.024 0H208c13.255 0 24 10.745 24 24v328h63.966c20.878 0 31.851 24.969 17.587 40.331z"]},ql={prefix:"fas",iconName:"level-up-alt",icon:[320,512,[],"f3bf","M313.553 119.669L209.587 7.666c-9.485-10.214-25.676-10.229-35.174 0L70.438 119.669C56.232 134.969 67.062 160 88.025 160H152v272H68.024a11.996 11.996 0 0 0-8.485 3.515l-56 56C-4.021 499.074 1.333 512 12.024 512H208c13.255 0 24-10.745 24-24V160h63.966c20.878 0 31.851-24.969 17.587-40.331z"]},Yl={prefix:"fas",iconName:"life-ring",icon:[512,512,[],"f1cd","M256 8C119.033 8 8 119.033 8 256s111.033 248 248 248 248-111.033 248-248S392.967 8 256 8zm173.696 119.559l-63.399 63.399c-10.987-18.559-26.67-34.252-45.255-45.255l63.399-63.399a218.396 218.396 0 0 1 45.255 45.255zM256 352c-53.019 0-96-42.981-96-96s42.981-96 96-96 96 42.981 96 96-42.981 96-96 96zM127.559 82.304l63.399 63.399c-18.559 10.987-34.252 26.67-45.255 45.255l-63.399-63.399a218.372 218.372 0 0 1 45.255-45.255zM82.304 384.441l63.399-63.399c10.987 18.559 26.67 34.252 45.255 45.255l-63.399 63.399a218.396 218.396 0 0 1-45.255-45.255zm302.137 45.255l-63.399-63.399c18.559-10.987 34.252-26.67 45.255-45.255l63.399 63.399a218.403 218.403 0 0 1-45.255 45.255z"]},Ql={prefix:"fas",iconName:"lightbulb",icon:[352,512,[],"f0eb","M96.06 454.35c.01 6.29 1.87 12.45 5.36 17.69l17.09 25.69a31.99 31.99 0 0 0 26.64 14.28h61.71a31.99 31.99 0 0 0 26.64-14.28l17.09-25.69a31.989 31.989 0 0 0 5.36-17.69l.04-38.35H96.01l.05 38.35zM0 176c0 44.37 16.45 84.85 43.56 115.78 16.52 18.85 42.36 58.23 52.21 91.45.04.26.07.52.11.78h160.24c.04-.26.07-.51.11-.78 9.85-33.22 35.69-72.6 52.21-91.45C335.55 260.85 352 220.37 352 176 352 78.61 272.91-.3 175.45 0 73.44.31 0 82.97 0 176zm176-80c-44.11 0-80 35.89-80 80 0 8.84-7.16 16-16 16s-16-7.16-16-16c0-61.76 50.24-112 112-112 8.84 0 16 7.16 16 16s-7.16 16-16 16z"]},Xl={prefix:"fas",iconName:"link",icon:[512,512,[],"f0c1","M326.612 185.391c59.747 59.809 58.927 155.698.36 214.59-.11.12-.24.25-.36.37l-67.2 67.2c-59.27 59.27-155.699 59.262-214.96 0-59.27-59.26-59.27-155.7 0-214.96l37.106-37.106c9.84-9.84 26.786-3.3 27.294 10.606.648 17.722 3.826 35.527 9.69 52.721 1.986 5.822.567 12.262-3.783 16.612l-13.087 13.087c-28.026 28.026-28.905 73.66-1.155 101.96 28.024 28.579 74.086 28.749 102.325.51l67.2-67.19c28.191-28.191 28.073-73.757 0-101.83-3.701-3.694-7.429-6.564-10.341-8.569a16.037 16.037 0 0 1-6.947-12.606c-.396-10.567 3.348-21.456 11.698-29.806l21.054-21.055c5.521-5.521 14.182-6.199 20.584-1.731a152.482 152.482 0 0 1 20.522 17.197zM467.547 44.449c-59.261-59.262-155.69-59.27-214.96 0l-67.2 67.2c-.12.12-.25.25-.36.37-58.566 58.892-59.387 154.781.36 214.59a152.454 152.454 0 0 0 20.521 17.196c6.402 4.468 15.064 3.789 20.584-1.731l21.054-21.055c8.35-8.35 12.094-19.239 11.698-29.806a16.037 16.037 0 0 0-6.947-12.606c-2.912-2.005-6.64-4.875-10.341-8.569-28.073-28.073-28.191-73.639 0-101.83l67.2-67.19c28.239-28.239 74.3-28.069 102.325.51 27.75 28.3 26.872 73.934-1.155 101.96l-13.087 13.087c-4.35 4.35-5.769 10.79-3.783 16.612 5.864 17.194 9.042 34.999 9.69 52.721.509 13.906 17.454 20.446 27.294 10.606l37.106-37.106c59.271-59.259 59.271-155.699.001-214.959z"]},Zl={prefix:"fas",iconName:"lira-sign",icon:[384,512,[],"f195","M371.994 256h-48.019C317.64 256 312 260.912 312 267.246 312 368 230.179 416 144 416V256.781l134.603-29.912A12 12 0 0 0 288 215.155v-40.976c0-7.677-7.109-13.38-14.603-11.714L144 191.219V160.78l134.603-29.912A12 12 0 0 0 288 119.154V78.179c0-7.677-7.109-13.38-14.603-11.714L144 95.219V44c0-6.627-5.373-12-12-12H76c-6.627 0-12 5.373-12 12v68.997L9.397 125.131A12 12 0 0 0 0 136.845v40.976c0 7.677 7.109 13.38 14.603 11.714L64 178.558v30.439L9.397 221.131A12 12 0 0 0 0 232.845v40.976c0 7.677 7.109 13.38 14.603 11.714L64 274.558V468c0 6.627 5.373 12 12 12h79.583c134.091 0 223.255-77.834 228.408-211.592.261-6.782-5.211-12.408-11.997-12.408z"]},Jl={prefix:"fas",iconName:"list",icon:[512,512,[],"f03a","M80 368H16a16 16 0 0 0-16 16v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-64a16 16 0 0 0-16-16zm0-320H16A16 16 0 0 0 0 64v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16V64a16 16 0 0 0-16-16zm0 160H16a16 16 0 0 0-16 16v64a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-64a16 16 0 0 0-16-16zm416 176H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-320H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16zm0 160H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},ec={prefix:"fas",iconName:"list-alt",icon:[512,512,[],"f022","M464 480H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h416c26.51 0 48 21.49 48 48v352c0 26.51-21.49 48-48 48zM128 120c-22.091 0-40 17.909-40 40s17.909 40 40 40 40-17.909 40-40-17.909-40-40-40zm0 96c-22.091 0-40 17.909-40 40s17.909 40 40 40 40-17.909 40-40-17.909-40-40-40zm0 96c-22.091 0-40 17.909-40 40s17.909 40 40 40 40-17.909 40-40-17.909-40-40-40zm288-136v-32c0-6.627-5.373-12-12-12H204c-6.627 0-12 5.373-12 12v32c0 6.627 5.373 12 12 12h200c6.627 0 12-5.373 12-12zm0 96v-32c0-6.627-5.373-12-12-12H204c-6.627 0-12 5.373-12 12v32c0 6.627 5.373 12 12 12h200c6.627 0 12-5.373 12-12zm0 96v-32c0-6.627-5.373-12-12-12H204c-6.627 0-12 5.373-12 12v32c0 6.627 5.373 12 12 12h200c6.627 0 12-5.373 12-12z"]},tc={prefix:"fas",iconName:"list-ol",icon:[512,512,[],"f0cb","M61.77 401l17.5-20.15a19.92 19.92 0 0 0 5.07-14.19v-3.31C84.34 356 80.5 352 73 352H16a8 8 0 0 0-8 8v16a8 8 0 0 0 8 8h22.83a157.41 157.41 0 0 0-11 12.31l-5.61 7c-4 5.07-5.25 10.13-2.8 14.88l1.05 1.93c3 5.76 6.29 7.88 12.25 7.88h4.73c10.33 0 15.94 2.44 15.94 9.09 0 4.72-4.2 8.22-14.36 8.22a41.54 41.54 0 0 1-15.47-3.12c-6.49-3.88-11.74-3.5-15.6 3.12l-5.59 9.31c-3.72 6.13-3.19 11.72 2.63 15.94 7.71 4.69 20.38 9.44 37 9.44 34.16 0 48.5-22.75 48.5-44.12-.03-14.38-9.12-29.76-28.73-34.88zM496 224H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-160H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16zm0 320H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM16 160h64a8 8 0 0 0 8-8v-16a8 8 0 0 0-8-8H64V40a8 8 0 0 0-8-8H32a8 8 0 0 0-7.14 4.42l-8 16A8 8 0 0 0 24 64h8v64H16a8 8 0 0 0-8 8v16a8 8 0 0 0 8 8zm-3.91 160H80a8 8 0 0 0 8-8v-16a8 8 0 0 0-8-8H41.32c3.29-10.29 48.34-18.68 48.34-56.44 0-29.06-25-39.56-44.47-39.56-21.36 0-33.8 10-40.46 18.75-4.37 5.59-3 10.84 2.8 15.37l8.58 6.88c5.61 4.56 11 2.47 16.12-2.44a13.44 13.44 0 0 1 9.46-3.84c3.33 0 9.28 1.56 9.28 8.75C51 248.19 0 257.31 0 304.59v4C0 316 5.08 320 12.09 320z"]},ic={prefix:"fas",iconName:"list-ul",icon:[512,512,[],"f0ca","M48 48a48 48 0 1 0 48 48 48 48 0 0 0-48-48zm0 160a48 48 0 1 0 48 48 48 48 0 0 0-48-48zm0 160a48 48 0 1 0 48 48 48 48 0 0 0-48-48zm448 16H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-320H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16zm0 160H176a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h320a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},rc={prefix:"fas",iconName:"location-arrow",icon:[512,512,[],"f124","M444.52 3.52L28.74 195.42c-47.97 22.39-31.98 92.75 19.19 92.75h175.91v175.91c0 51.17 70.36 67.17 92.75 19.19l191.9-415.78c15.99-38.39-25.59-79.97-63.97-63.97z"]},nc={prefix:"fas",iconName:"lock",icon:[448,512,[],"f023","M400 224h-24v-72C376 68.2 307.8 0 224 0S72 68.2 72 152v72H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48zm-104 0H152v-72c0-39.7 32.3-72 72-72s72 32.3 72 72v72z"]},sc={prefix:"fas",iconName:"lock-open",icon:[576,512,[],"f3c1","M423.5 0C339.5.3 272 69.5 272 153.5V224H48c-26.5 0-48 21.5-48 48v192c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V272c0-26.5-21.5-48-48-48h-48v-71.1c0-39.6 31.7-72.5 71.3-72.9 40-.4 72.7 32.1 72.7 72v80c0 13.3 10.7 24 24 24h32c13.3 0 24-10.7 24-24v-80C576 68 507.5-.3 423.5 0z"]},oc={prefix:"fas",iconName:"long-arrow-alt-down",icon:[256,512,[],"f309","M168 345.941V44c0-6.627-5.373-12-12-12h-56c-6.627 0-12 5.373-12 12v301.941H41.941c-21.382 0-32.09 25.851-16.971 40.971l86.059 86.059c9.373 9.373 24.569 9.373 33.941 0l86.059-86.059c15.119-15.119 4.411-40.971-16.971-40.971H168z"]},ac={prefix:"fas",iconName:"long-arrow-alt-left",icon:[448,512,[],"f30a","M134.059 296H436c6.627 0 12-5.373 12-12v-56c0-6.627-5.373-12-12-12H134.059v-46.059c0-21.382-25.851-32.09-40.971-16.971L7.029 239.029c-9.373 9.373-9.373 24.569 0 33.941l86.059 86.059c15.119 15.119 40.971 4.411 40.971-16.971V296z"]},lc={prefix:"fas",iconName:"long-arrow-alt-right",icon:[448,512,[],"f30b","M313.941 216H12c-6.627 0-12 5.373-12 12v56c0 6.627 5.373 12 12 12h301.941v46.059c0 21.382 25.851 32.09 40.971 16.971l86.059-86.059c9.373-9.373 9.373-24.569 0-33.941l-86.059-86.059c-15.119-15.119-40.971-4.411-40.971 16.971V216z"]},cc={prefix:"fas",iconName:"long-arrow-alt-up",icon:[256,512,[],"f30c","M88 166.059V468c0 6.627 5.373 12 12 12h56c6.627 0 12-5.373 12-12V166.059h46.059c21.382 0 32.09-25.851 16.971-40.971l-86.059-86.059c-9.373-9.373-24.569-9.373-33.941 0l-86.059 86.059c-15.119 15.119-4.411 40.971 16.971 40.971H88z"]},uc={prefix:"fas",iconName:"low-vision",icon:[576,512,[],"f2a8","M569.344 231.631C512.96 135.949 407.81 72 288 72c-28.468 0-56.102 3.619-82.451 10.409L152.778 10.24c-7.601-10.858-22.564-13.5-33.423-5.9l-13.114 9.178c-10.86 7.601-13.502 22.566-5.9 33.426l43.131 58.395C89.449 131.73 40.228 174.683 6.682 231.581c-.01.017-.023.033-.034.05-8.765 14.875-8.964 33.528 0 48.739 38.5 65.332 99.742 115.862 172.859 141.349L55.316 244.302A272.194 272.194 0 0 1 83.61 208.39l119.4 170.58h.01l40.63 58.04a330.055 330.055 0 0 0 78.94 1.17l-189.98-271.4a277.628 277.628 0 0 1 38.777-21.563l251.836 356.544c7.601 10.858 22.564 13.499 33.423 5.9l13.114-9.178c10.86-7.601 13.502-22.567 5.9-33.426l-43.12-58.377-.007-.009c57.161-27.978 104.835-72.04 136.81-126.301a47.938 47.938 0 0 0 .001-48.739zM390.026 345.94l-19.066-27.23c24.682-32.567 27.711-76.353 8.8-111.68v.03c0 23.65-19.17 42.82-42.82 42.82-23.828 0-42.82-19.349-42.82-42.82 0-23.65 19.17-42.82 42.82-42.82h.03c-24.75-13.249-53.522-15.643-79.51-7.68l-19.068-27.237C253.758 123.306 270.488 120 288 120c75.162 0 136 60.826 136 136 0 34.504-12.833 65.975-33.974 89.94z"]},hc={prefix:"fas",iconName:"luggage-cart",icon:[640,512,[],"f59d","M224 320h32V96h-32c-17.67 0-32 14.33-32 32v160c0 17.67 14.33 32 32 32zm352-32V128c0-17.67-14.33-32-32-32h-32v224h32c17.67 0 32-14.33 32-32zm48 96H128V16c0-8.84-7.16-16-16-16H16C7.16 0 0 7.16 0 16v32c0 8.84 7.16 16 16 16h48v368c0 8.84 7.16 16 16 16h82.94c-1.79 5.03-2.94 10.36-2.94 16 0 26.51 21.49 48 48 48s48-21.49 48-48c0-5.64-1.15-10.97-2.94-16h197.88c-1.79 5.03-2.94 10.36-2.94 16 0 26.51 21.49 48 48 48s48-21.49 48-48c0-5.64-1.15-10.97-2.94-16H624c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM480 96V48c0-26.51-21.49-48-48-48h-96c-26.51 0-48 21.49-48 48v272h192V96zm-48 0h-96V48h96v48z"]},dc={prefix:"fas",iconName:"lungs",icon:[640,512,[],"f604","M636.11 390.15C614.44 308.85 580.07 231 534.1 159.13 511.98 124.56 498.03 96 454.05 96 415.36 96 384 125.42 384 161.71v60.11l-32.88-21.92a15.996 15.996 0 0 1-7.12-13.31V16c0-8.84-7.16-16-16-16h-16c-8.84 0-16 7.16-16 16v170.59c0 5.35-2.67 10.34-7.12 13.31L256 221.82v-60.11C256 125.42 224.64 96 185.95 96c-43.98 0-57.93 28.56-80.05 63.13C59.93 231 25.56 308.85 3.89 390.15 1.3 399.84 0 409.79 0 419.78c0 61.23 62.48 105.44 125.24 88.62l59.5-15.95c42.18-11.3 71.26-47.47 71.26-88.62v-87.49l-85.84 57.23a7.992 7.992 0 0 1-11.09-2.22l-8.88-13.31a7.992 7.992 0 0 1 2.22-11.09L320 235.23l167.59 111.72a7.994 7.994 0 0 1 2.22 11.09l-8.88 13.31a7.994 7.994 0 0 1-11.09 2.22L384 316.34v87.49c0 41.15 29.08 77.31 71.26 88.62l59.5 15.95C577.52 525.22 640 481.01 640 419.78c0-9.99-1.3-19.94-3.89-29.63z"]},pc={prefix:"fas",iconName:"lungs-virus",icon:[640,512,[],"e067","M344,150.68V16A16,16,0,0,0,328,0H312a16,16,0,0,0-16,16V150.68a46.45,46.45,0,0,1,48,0ZM195.54,444.46a48.06,48.06,0,0,1,0-67.88l8.58-8.58H192a48,48,0,0,1,0-96h12.12l-8.58-8.57a48,48,0,0,1,60.46-74V161.75C256,125.38,224.62,96,186,96c-44,0-58,28.5-80.12,63.13a819.52,819.52,0,0,0-102,231A113.16,113.16,0,0,0,0,419.75C0,481,62.5,525.26,125.25,508.38l59.5-15.87a98.51,98.51,0,0,0,52.5-34.75,46.49,46.49,0,0,1-41.71-13.3Zm226.29-22.63a16,16,0,0,0,0-22.62l-8.58-8.58C393.09,370.47,407.37,336,435.88,336H448a16,16,0,0,0,0-32H435.88c-28.51,0-42.79-34.47-22.63-54.62l8.58-8.58a16,16,0,0,0-22.63-22.63l-8.57,8.58C370.47,246.91,336,232.63,336,204.12V192a16,16,0,0,0-32,0v12.12c0,28.51-34.47,42.79-54.63,22.63l-8.57-8.58a16,16,0,0,0-22.63,22.63l8.58,8.58c20.16,20.15,5.88,54.62-22.63,54.62H192a16,16,0,0,0,0,32h12.12c28.51,0,42.79,34.47,22.63,54.63l-8.58,8.58a16,16,0,1,0,22.63,22.62l8.57-8.57C269.53,393.1,304,407.38,304,435.88V448a16,16,0,0,0,32,0V435.88c0-28.5,34.47-42.78,54.63-22.62l8.57,8.57a16,16,0,0,0,22.63,0ZM288,304a16,16,0,1,1,16-16A16,16,0,0,1,288,304Zm64,64a16,16,0,1,1,16-16A16,16,0,0,1,352,368Zm284.12,22.13a819.52,819.52,0,0,0-102-231C512,124.5,498,96,454,96c-38.62,0-70,29.38-70,65.75v27.72a48,48,0,0,1,60.46,74L435.88,272H448a48,48,0,0,1,0,96H435.88l8.58,8.58a47.7,47.7,0,0,1-41.71,81.18,98.51,98.51,0,0,0,52.5,34.75l59.5,15.87C577.5,525.26,640,481,640,419.75A113.16,113.16,0,0,0,636.12,390.13Z"]},gc={prefix:"fas",iconName:"magic",icon:[512,512,[],"f0d0","M224 96l16-32 32-16-32-16-16-32-16 32-32 16 32 16 16 32zM80 160l26.66-53.33L160 80l-53.34-26.67L80 0 53.34 53.33 0 80l53.34 26.67L80 160zm352 128l-26.66 53.33L352 368l53.34 26.67L432 448l26.66-53.33L512 368l-53.34-26.67L432 288zm70.62-193.77L417.77 9.38C411.53 3.12 403.34 0 395.15 0c-8.19 0-16.38 3.12-22.63 9.38L9.38 372.52c-12.5 12.5-12.5 32.76 0 45.25l84.85 84.85c6.25 6.25 14.44 9.37 22.62 9.37 8.19 0 16.38-3.12 22.63-9.37l363.14-363.15c12.5-12.48 12.5-32.75 0-45.24zM359.45 203.46l-50.91-50.91 86.6-86.6 50.91 50.91-86.6 86.6z"]},fc={prefix:"fas",iconName:"magnet",icon:[512,512,[],"f076","M164.07 148.1H12a12 12 0 0 1-12-12v-80a36 36 0 0 1 36-36h104a36 36 0 0 1 36 36v80a11.89 11.89 0 0 1-11.93 12zm347.93-12V56a36 36 0 0 0-36-36H372a36 36 0 0 0-36 36v80a12 12 0 0 0 12 12h152a11.89 11.89 0 0 0 12-11.9zm-164 44a12 12 0 0 0-12 12v52c0 128.1-160 127.9-160 0v-52a12 12 0 0 0-12-12H12.1a12 12 0 0 0-12 12.1c.1 21.4.6 40.3 0 53.3 0 150.6 136.17 246.6 256.75 246.6s255-96 255-246.7c-.6-12.8-.2-33 0-53.2a12 12 0 0 0-12-12.1z"]},mc={prefix:"fas",iconName:"mail-bulk",icon:[576,512,[],"f674","M160 448c-25.6 0-51.2-22.4-64-32-64-44.8-83.2-60.8-96-70.4V480c0 17.67 14.33 32 32 32h256c17.67 0 32-14.33 32-32V345.6c-12.8 9.6-32 25.6-96 70.4-12.8 9.6-38.4 32-64 32zm128-192H32c-17.67 0-32 14.33-32 32v16c25.6 19.2 22.4 19.2 115.2 86.4 9.6 6.4 28.8 25.6 44.8 25.6s35.2-19.2 44.8-22.4c92.8-67.2 89.6-67.2 115.2-86.4V288c0-17.67-14.33-32-32-32zm256-96H224c-17.67 0-32 14.33-32 32v32h96c33.21 0 60.59 25.42 63.71 57.82l.29-.22V416h192c17.67 0 32-14.33 32-32V192c0-17.67-14.33-32-32-32zm-32 128h-64v-64h64v64zm-352-96c0-35.29 28.71-64 64-64h224V32c0-17.67-14.33-32-32-32H96C78.33 0 64 14.33 64 32v192h96v-32z"]},vc={prefix:"fas",iconName:"male",icon:[192,512,[],"f183","M96 0c35.346 0 64 28.654 64 64s-28.654 64-64 64-64-28.654-64-64S60.654 0 96 0m48 144h-11.36c-22.711 10.443-49.59 10.894-73.28 0H48c-26.51 0-48 21.49-48 48v136c0 13.255 10.745 24 24 24h16v136c0 13.255 10.745 24 24 24h64c13.255 0 24-10.745 24-24V352h16c13.255 0 24-10.745 24-24V192c0-26.51-21.49-48-48-48z"]},Cc={prefix:"fas",iconName:"map",icon:[576,512,[],"f279","M0 117.66v346.32c0 11.32 11.43 19.06 21.94 14.86L160 416V32L20.12 87.95A32.006 32.006 0 0 0 0 117.66zM192 416l192 64V96L192 32v384zM554.06 33.16L416 96v384l139.88-55.95A31.996 31.996 0 0 0 576 394.34V48.02c0-11.32-11.43-19.06-21.94-14.86z"]},yc={prefix:"fas",iconName:"map-marked",icon:[576,512,[],"f59f","M288 0c-69.59 0-126 56.41-126 126 0 56.26 82.35 158.8 113.9 196.02 6.39 7.54 17.82 7.54 24.2 0C331.65 284.8 414 182.26 414 126 414 56.41 357.59 0 288 0zM20.12 215.95A32.006 32.006 0 0 0 0 245.66v250.32c0 11.32 11.43 19.06 21.94 14.86L160 448V214.92c-8.84-15.98-16.07-31.54-21.25-46.42L20.12 215.95zM288 359.67c-14.07 0-27.38-6.18-36.51-16.96-19.66-23.2-40.57-49.62-59.49-76.72v182l192 64V266c-18.92 27.09-39.82 53.52-59.49 76.72-9.13 10.77-22.44 16.95-36.51 16.95zm266.06-198.51L416 224v288l139.88-55.95A31.996 31.996 0 0 0 576 426.34V176.02c0-11.32-11.43-19.06-21.94-14.86z"]},wc={prefix:"fas",iconName:"map-marked-alt",icon:[576,512,[],"f5a0","M288 0c-69.59 0-126 56.41-126 126 0 56.26 82.35 158.8 113.9 196.02 6.39 7.54 17.82 7.54 24.2 0C331.65 284.8 414 182.26 414 126 414 56.41 357.59 0 288 0zm0 168c-23.2 0-42-18.8-42-42s18.8-42 42-42 42 18.8 42 42-18.8 42-42 42zM20.12 215.95A32.006 32.006 0 0 0 0 245.66v250.32c0 11.32 11.43 19.06 21.94 14.86L160 448V214.92c-8.84-15.98-16.07-31.54-21.25-46.42L20.12 215.95zM288 359.67c-14.07 0-27.38-6.18-36.51-16.96-19.66-23.2-40.57-49.62-59.49-76.72v182l192 64V266c-18.92 27.09-39.82 53.52-59.49 76.72-9.13 10.77-22.44 16.95-36.51 16.95zm266.06-198.51L416 224v288l139.88-55.95A31.996 31.996 0 0 0 576 426.34V176.02c0-11.32-11.43-19.06-21.94-14.86z"]},Sc={prefix:"fas",iconName:"map-marker",icon:[384,512,[],"f041","M172.268 501.67C26.97 291.031 0 269.413 0 192 0 85.961 85.961 0 192 0s192 85.961 192 192c0 77.413-26.97 99.031-172.268 309.67-9.535 13.774-29.93 13.773-39.464 0z"]},bc={prefix:"fas",iconName:"map-marker-alt",icon:[384,512,[],"f3c5","M172.268 501.67C26.97 291.031 0 269.413 0 192 0 85.961 85.961 0 192 0s192 85.961 192 192c0 77.413-26.97 99.031-172.268 309.67-9.535 13.774-29.93 13.773-39.464 0zM192 272c44.183 0 80-35.817 80-80s-35.817-80-80-80-80 35.817-80 80 35.817 80 80 80z"]},Ec={prefix:"fas",iconName:"map-pin",icon:[288,512,[],"f276","M112 316.94v156.69l22.02 33.02c4.75 7.12 15.22 7.12 19.97 0L176 473.63V316.94c-10.39 1.92-21.06 3.06-32 3.06s-21.61-1.14-32-3.06zM144 0C64.47 0 0 64.47 0 144s64.47 144 144 144 144-64.47 144-144S223.53 0 144 0zm0 76c-37.5 0-68 30.5-68 68 0 6.62-5.38 12-12 12s-12-5.38-12-12c0-50.73 41.28-92 92-92 6.62 0 12 5.38 12 12s-5.38 12-12 12z"]},Ac={prefix:"fas",iconName:"map-signs",icon:[512,512,[],"f277","M507.31 84.69L464 41.37c-6-6-14.14-9.37-22.63-9.37H288V16c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v16H56c-13.25 0-24 10.75-24 24v80c0 13.25 10.75 24 24 24h385.37c8.49 0 16.62-3.37 22.63-9.37l43.31-43.31c6.25-6.26 6.25-16.38 0-22.63zM224 496c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16V384h-64v112zm232-272H288v-32h-64v32H70.63c-8.49 0-16.62 3.37-22.63 9.37L4.69 276.69c-6.25 6.25-6.25 16.38 0 22.63L48 342.63c6 6 14.14 9.37 22.63 9.37H456c13.25 0 24-10.75 24-24v-80c0-13.25-10.75-24-24-24z"]},Tc={prefix:"fas",iconName:"marker",icon:[512,512,[],"f5a1","M93.95 290.03A327.038 327.038 0 0 0 .17 485.11l-.03.23c-1.7 15.28 11.21 28.2 26.49 26.51a327.02 327.02 0 0 0 195.34-93.8l75.4-75.4-128.02-128.02-75.4 75.4zM485.49 26.51c-35.35-35.35-92.67-35.35-128.02 0l-21.76 21.76-36.56-36.55c-15.62-15.62-40.95-15.62-56.56 0L138.47 115.84c-6.25 6.25-6.25 16.38 0 22.63l22.62 22.62c6.25 6.25 16.38 6.25 22.63 0l87.15-87.15 19.59 19.59L191.98 192 320 320.02l165.49-165.49c35.35-35.35 35.35-92.66 0-128.02z"]},Mc={prefix:"fas",iconName:"mars",icon:[384,512,[],"f222","M372 64h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-80.7 80.7c-22.2-14-48.5-22.1-76.7-22.1C64.5 160 0 224.5 0 304s64.5 144 144 144 144-64.5 144-144c0-28.2-8.1-54.5-22.1-76.7l80.7-80.7 16.9 16.9c7.6 7.6 20.5 2.2 20.5-8.5V76c0-6.6-5.4-12-12-12zM144 384c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},Rc={prefix:"fas",iconName:"mars-double",icon:[512,512,[],"f227","M340 0h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-48.7 48.7C198.5 72.1 172.2 64 144 64 64.5 64 0 128.5 0 208s64.5 144 144 144 144-64.5 144-144c0-28.2-8.1-54.5-22.1-76.7l48.7-48.7 16.9 16.9c2.4 2.4 5.5 3.5 8.4 3.5 6.2 0 12.1-4.8 12.1-12V12c0-6.6-5.4-12-12-12zM144 288c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80zm356-128.1h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-48.7 48.7c-18.2-11.4-39-18.9-61.5-21.3-2.1 21.8-8.2 43.3-18.4 63.3 1.1 0 2.2-.1 3.2-.1 44.1 0 80 35.9 80 80s-35.9 80-80 80-80-35.9-80-80c0-1.1 0-2.2.1-3.2-20 10.2-41.5 16.4-63.3 18.4C168.4 455.6 229.6 512 304 512c79.5 0 144-64.5 144-144 0-28.2-8.1-54.5-22.1-76.7l48.7-48.7 16.9 16.9c2.4 2.4 5.4 3.5 8.4 3.5 6.2 0 12.1-4.8 12.1-12v-79c0-6.7-5.4-12.1-12-12.1z"]},_c={prefix:"fas",iconName:"mars-stroke",icon:[384,512,[],"f229","M372 64h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-17.5 17.5-14.1-14.1c-4.7-4.7-12.3-4.7-17 0L224.5 133c-4.7 4.7-4.7 12.3 0 17l14.1 14.1-18 18c-22.2-14-48.5-22.1-76.7-22.1C64.5 160 0 224.5 0 304s64.5 144 144 144 144-64.5 144-144c0-28.2-8.1-54.5-22.1-76.7l18-18 14.1 14.1c4.7 4.7 12.3 4.7 17 0l28.3-28.3c4.7-4.7 4.7-12.3 0-17L329.2 164l17.5-17.5 16.9 16.9c7.6 7.6 20.5 2.2 20.5-8.5V76c-.1-6.6-5.5-12-12.1-12zM144 384c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},Pc={prefix:"fas",iconName:"mars-stroke-h",icon:[480,512,[],"f22b","M476.2 247.5l-55.9-55.9c-7.6-7.6-20.5-2.2-20.5 8.5V224H376v-20c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12v20h-27.6c-5.8-25.6-18.7-49.9-38.6-69.8C189.6 98 98.4 98 42.2 154.2c-56.2 56.2-56.2 147.4 0 203.6 56.2 56.2 147.4 56.2 203.6 0 19.9-19.9 32.8-44.2 38.6-69.8H312v20c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-20h23.9v23.9c0 10.7 12.9 16 20.5 8.5l55.9-55.9c4.6-4.7 4.6-12.3-.1-17zm-275.6 65.1c-31.2 31.2-81.9 31.2-113.1 0-31.2-31.2-31.2-81.9 0-113.1 31.2-31.2 81.9-31.2 113.1 0 31.2 31.1 31.2 81.9 0 113.1z"]},xc={prefix:"fas",iconName:"mars-stroke-v",icon:[288,512,[],"f22a","M245.8 234.2c-19.9-19.9-44.2-32.8-69.8-38.6v-25.4h20c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-20V81.4h23.9c10.7 0 16-12.9 8.5-20.5L152.5 5.1c-4.7-4.7-12.3-4.7-17 0L79.6 61c-7.6 7.6-2.2 20.5 8.5 20.5H112v24.7H92c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h20v25.4c-25.6 5.8-49.9 18.7-69.8 38.6-56.2 56.2-56.2 147.4 0 203.6 56.2 56.2 147.4 56.2 203.6 0 56.3-56.2 56.3-147.4 0-203.6zm-45.2 158.4c-31.2 31.2-81.9 31.2-113.1 0-31.2-31.2-31.2-81.9 0-113.1 31.2-31.2 81.9-31.2 113.1 0 31.2 31.1 31.2 81.9 0 113.1z"]},Dc={prefix:"fas",iconName:"mask",icon:[640,512,[],"f6fa","M320.67 64c-442.6 0-357.57 384-158.46 384 39.9 0 77.47-20.69 101.42-55.86l25.73-37.79c15.66-22.99 46.97-22.99 62.63 0l25.73 37.79C401.66 427.31 439.23 448 479.13 448c189.86 0 290.63-384-158.46-384zM184 308.36c-41.06 0-67.76-25.66-80.08-41.05-5.23-6.53-5.23-16.09 0-22.63 12.32-15.4 39.01-41.05 80.08-41.05s67.76 25.66 80.08 41.05c5.23 6.53 5.23 16.09 0 22.63-12.32 15.4-39.02 41.05-80.08 41.05zm272 0c-41.06 0-67.76-25.66-80.08-41.05-5.23-6.53-5.23-16.09 0-22.63 12.32-15.4 39.01-41.05 80.08-41.05s67.76 25.66 80.08 41.05c5.23 6.53 5.23 16.09 0 22.63-12.32 15.4-39.02 41.05-80.08 41.05z"]},Ic={prefix:"fas",iconName:"medal",icon:[512,512,[],"f5a2","M223.75 130.75L154.62 15.54A31.997 31.997 0 0 0 127.18 0H16.03C3.08 0-4.5 14.57 2.92 25.18l111.27 158.96c29.72-27.77 67.52-46.83 109.56-53.39zM495.97 0H384.82c-11.24 0-21.66 5.9-27.44 15.54l-69.13 115.21c42.04 6.56 79.84 25.62 109.56 53.38L509.08 25.18C516.5 14.57 508.92 0 495.97 0zM256 160c-97.2 0-176 78.8-176 176s78.8 176 176 176 176-78.8 176-176-78.8-176-176-176zm92.52 157.26l-37.93 36.96 8.97 52.22c1.6 9.36-8.26 16.51-16.65 12.09L256 393.88l-46.9 24.65c-8.4 4.45-18.25-2.74-16.65-12.09l8.97-52.22-37.93-36.96c-6.82-6.64-3.05-18.23 6.35-19.59l52.43-7.64 23.43-47.52c2.11-4.28 6.19-6.39 10.28-6.39 4.11 0 8.22 2.14 10.33 6.39l23.43 47.52 52.43 7.64c9.4 1.36 13.17 12.95 6.35 19.59z"]},Lc={prefix:"fas",iconName:"medkit",icon:[512,512,[],"f0fa","M96 480h320V128h-32V80c0-26.51-21.49-48-48-48H176c-26.51 0-48 21.49-48 48v48H96v352zm96-384h128v32H192V96zm320 80v256c0 26.51-21.49 48-48 48h-16V128h16c26.51 0 48 21.49 48 48zM64 480H48c-26.51 0-48-21.49-48-48V176c0-26.51 21.49-48 48-48h16v352zm288-208v32c0 8.837-7.163 16-16 16h-48v48c0 8.837-7.163 16-16 16h-32c-8.837 0-16-7.163-16-16v-48h-48c-8.837 0-16-7.163-16-16v-32c0-8.837 7.163-16 16-16h48v-48c0-8.837 7.163-16 16-16h32c8.837 0 16 7.163 16 16v48h48c8.837 0 16 7.163 16 16z"]},Nc={prefix:"fas",iconName:"meh",icon:[496,512,[],"f11a","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm-80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm176 192H152c-21.2 0-21.2-32 0-32h192c21.2 0 21.2 32 0 32zm-16-128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Oc={prefix:"fas",iconName:"meh-blank",icon:[496,512,[],"f5a4","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm-80 232c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm160 0c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Fc={prefix:"fas",iconName:"meh-rolling-eyes",icon:[496,512,[],"f5a5","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM88 224c0-24.3 13.7-45.2 33.6-56-.7 2.6-1.6 5.2-1.6 8 0 17.7 14.3 32 32 32s32-14.3 32-32c0-2.8-.9-5.4-1.6-8 19.9 10.8 33.6 31.7 33.6 56 0 35.3-28.7 64-64 64s-64-28.7-64-64zm224 176H184c-21.2 0-21.2-32 0-32h128c21.2 0 21.2 32 0 32zm32-112c-35.3 0-64-28.7-64-64 0-24.3 13.7-45.2 33.6-56-.7 2.6-1.6 5.2-1.6 8 0 17.7 14.3 32 32 32s32-14.3 32-32c0-2.8-.9-5.4-1.6-8 19.9 10.8 33.6 31.7 33.6 56 0 35.3-28.7 64-64 64z"]},kc={prefix:"fas",iconName:"memory",icon:[640,512,[],"f538","M640 130.94V96c0-17.67-14.33-32-32-32H32C14.33 64 0 78.33 0 96v34.94c18.6 6.61 32 24.19 32 45.06s-13.4 38.45-32 45.06V320h640v-98.94c-18.6-6.61-32-24.19-32-45.06s13.4-38.45 32-45.06zM224 256h-64V128h64v128zm128 0h-64V128h64v128zm128 0h-64V128h64v128zM0 448h64v-26.67c0-8.84 7.16-16 16-16s16 7.16 16 16V448h128v-26.67c0-8.84 7.16-16 16-16s16 7.16 16 16V448h128v-26.67c0-8.84 7.16-16 16-16s16 7.16 16 16V448h128v-26.67c0-8.84 7.16-16 16-16s16 7.16 16 16V448h64v-96H0v96z"]},Gc={prefix:"fas",iconName:"menorah",icon:[640,512,[],"f676","M144 128h-32c-8.84 0-16 7.16-16 16v144h64V144c0-8.84-7.16-16-16-16zm96 0h-32c-8.84 0-16 7.16-16 16v144h64V144c0-8.84-7.16-16-16-16zm192 0h-32c-8.84 0-16 7.16-16 16v144h64V144c0-8.84-7.16-16-16-16zm96 0h-32c-8.84 0-16 7.16-16 16v144h64V144c0-8.84-7.16-16-16-16zm80-32c17.67 0 32-14.33 32-32S608 0 608 0s-32 46.33-32 64 14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S512 0 512 0s-32 46.33-32 64 14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S416 0 416 0s-32 46.33-32 64 14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S320 0 320 0s-32 46.33-32 64 14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S224 0 224 0s-32 46.33-32 64 14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S128 0 128 0 96 46.33 96 64s14.33 32 32 32zm-96 0c17.67 0 32-14.33 32-32S32 0 32 0 0 46.33 0 64s14.33 32 32 32zm544 192c0 17.67-14.33 32-32 32H352V144c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v176H96c-17.67 0-32-14.33-32-32V144c0-8.84-7.16-16-16-16H16c-8.84 0-16 7.16-16 16v144c0 53.02 42.98 96 96 96h192v64H112c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h416c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16H352v-64h192c53.02 0 96-42.98 96-96V144c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v144z"]},Vc={prefix:"fas",iconName:"mercury",icon:[288,512,[],"f223","M288 208c0-44.2-19.9-83.7-51.2-110.1 2.5-1.8 4.9-3.8 7.2-5.8 24.7-21.2 39.8-48.8 43.2-78.8.9-7.1-4.7-13.3-11.9-13.3h-40.5C229 0 224.1 4.1 223 9.8c-2.4 12.5-9.6 24.3-20.7 33.8C187 56.8 166.3 64 144 64s-43-7.2-58.4-20.4C74.5 34.1 67.4 22.3 64.9 9.8 63.8 4.1 58.9 0 53.2 0H12.7C5.5 0-.1 6.2.8 13.3 4.2 43.4 19.2 71 44 92.2c2.3 2 4.7 3.9 7.2 5.8C19.9 124.3 0 163.8 0 208c0 68.5 47.9 125.9 112 140.4V400H76c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v36c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-36h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-51.6c64.1-14.5 112-71.9 112-140.4zm-224 0c0-44.1 35.9-80 80-80s80 35.9 80 80-35.9 80-80 80-80-35.9-80-80z"]},Hc={prefix:"fas",iconName:"meteor",icon:[512,512,[],"f753","M511.328,20.8027c-11.60759,38.70264-34.30724,111.70173-61.30311,187.70077,6.99893,2.09372,13.4042,4,18.60653,5.59368a16.06158,16.06158,0,0,1,9.49854,22.906c-22.106,42.29635-82.69047,152.795-142.47819,214.40356-.99984,1.09373-1.99969,2.5-2.99954,3.49995A194.83046,194.83046,0,1,1,57.085,179.41009c.99985-1,2.40588-2,3.49947-3,61.59994-59.90549,171.97367-120.40473,214.37343-142.4982a16.058,16.058,0,0,1,22.90274,9.49988c1.59351,5.09368,3.49947,11.5936,5.5929,18.59351C379.34818,35.00565,452.43074,12.30281,491.12794.70921A16.18325,16.18325,0,0,1,511.328,20.8027ZM319.951,320.00207A127.98041,127.98041,0,1,0,191.97061,448.00046,127.97573,127.97573,0,0,0,319.951,320.00207Zm-127.98041-31.9996a31.9951,31.9951,0,1,1-31.9951-31.9996A31.959,31.959,0,0,1,191.97061,288.00247Zm31.9951,79.999a15.99755,15.99755,0,1,1-15.99755-15.9998A16.04975,16.04975,0,0,1,223.96571,368.00147Z"]},Bc={prefix:"fas",iconName:"microchip",icon:[512,512,[],"f2db","M416 48v416c0 26.51-21.49 48-48 48H144c-26.51 0-48-21.49-48-48V48c0-26.51 21.49-48 48-48h224c26.51 0 48 21.49 48 48zm96 58v12a6 6 0 0 1-6 6h-18v6a6 6 0 0 1-6 6h-42V88h42a6 6 0 0 1 6 6v6h18a6 6 0 0 1 6 6zm0 96v12a6 6 0 0 1-6 6h-18v6a6 6 0 0 1-6 6h-42v-48h42a6 6 0 0 1 6 6v6h18a6 6 0 0 1 6 6zm0 96v12a6 6 0 0 1-6 6h-18v6a6 6 0 0 1-6 6h-42v-48h42a6 6 0 0 1 6 6v6h18a6 6 0 0 1 6 6zm0 96v12a6 6 0 0 1-6 6h-18v6a6 6 0 0 1-6 6h-42v-48h42a6 6 0 0 1 6 6v6h18a6 6 0 0 1 6 6zM30 376h42v48H30a6 6 0 0 1-6-6v-6H6a6 6 0 0 1-6-6v-12a6 6 0 0 1 6-6h18v-6a6 6 0 0 1 6-6zm0-96h42v48H30a6 6 0 0 1-6-6v-6H6a6 6 0 0 1-6-6v-12a6 6 0 0 1 6-6h18v-6a6 6 0 0 1 6-6zm0-96h42v48H30a6 6 0 0 1-6-6v-6H6a6 6 0 0 1-6-6v-12a6 6 0 0 1 6-6h18v-6a6 6 0 0 1 6-6zm0-96h42v48H30a6 6 0 0 1-6-6v-6H6a6 6 0 0 1-6-6v-12a6 6 0 0 1 6-6h18v-6a6 6 0 0 1 6-6z"]},zc={prefix:"fas",iconName:"microphone",icon:[352,512,[],"f130","M176 352c53.02 0 96-42.98 96-96V96c0-53.02-42.98-96-96-96S80 42.98 80 96v160c0 53.02 42.98 96 96 96zm160-160h-16c-8.84 0-16 7.16-16 16v48c0 74.8-64.49 134.82-140.79 127.38C96.71 376.89 48 317.11 48 250.3V208c0-8.84-7.16-16-16-16H16c-8.84 0-16 7.16-16 16v40.16c0 89.64 63.97 169.55 152 181.69V464H96c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16h-56v-33.77C285.71 418.47 352 344.9 352 256v-48c0-8.84-7.16-16-16-16z"]},Uc={prefix:"fas",iconName:"microphone-alt",icon:[352,512,[],"f3c9","M336 192h-16c-8.84 0-16 7.16-16 16v48c0 74.8-64.49 134.82-140.79 127.38C96.71 376.89 48 317.11 48 250.3V208c0-8.84-7.16-16-16-16H16c-8.84 0-16 7.16-16 16v40.16c0 89.64 63.97 169.55 152 181.69V464H96c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16h-56v-33.77C285.71 418.47 352 344.9 352 256v-48c0-8.84-7.16-16-16-16zM176 352c53.02 0 96-42.98 96-96h-85.33c-5.89 0-10.67-3.58-10.67-8v-16c0-4.42 4.78-8 10.67-8H272v-32h-85.33c-5.89 0-10.67-3.58-10.67-8v-16c0-4.42 4.78-8 10.67-8H272v-32h-85.33c-5.89 0-10.67-3.58-10.67-8v-16c0-4.42 4.78-8 10.67-8H272c0-53.02-42.98-96-96-96S80 42.98 80 96v160c0 53.02 42.98 96 96 96z"]},Wc={prefix:"fas",iconName:"microphone-alt-slash",icon:[640,512,[],"f539","M633.82 458.1L476.26 336.33C488.74 312.21 496 284.98 496 256v-48c0-8.84-7.16-16-16-16h-16c-8.84 0-16 7.16-16 16v48c0 17.92-3.96 34.8-10.72 50.2l-26.55-20.52c3.1-9.4 5.28-19.22 5.28-29.67h-43.67l-41.4-32H416v-32h-85.33c-5.89 0-10.67-3.58-10.67-8v-16c0-4.42 4.78-8 10.67-8H416v-32h-85.33c-5.89 0-10.67-3.58-10.67-8v-16c0-4.42 4.78-8 10.67-8H416c0-53.02-42.98-96-96-96s-96 42.98-96 96v45.36L45.47 3.37C38.49-2.05 28.43-.8 23.01 6.18L3.37 31.45C-2.05 38.42-.8 48.47 6.18 53.9l588.36 454.73c6.98 5.43 17.03 4.17 22.46-2.81l19.64-25.27c5.41-6.97 4.16-17.02-2.82-22.45zM400 464h-56v-33.78c11.71-1.62 23.1-4.28 33.96-8.08l-50.4-38.96c-6.71.4-13.41.87-20.35.2-55.85-5.45-98.74-48.63-111.18-101.85L144 241.31v6.85c0 89.64 63.97 169.55 152 181.69V464h-56c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16z"]},jc={prefix:"fas",iconName:"microphone-slash",icon:[640,512,[],"f131","M633.82 458.1l-157.8-121.96C488.61 312.13 496 285.01 496 256v-48c0-8.84-7.16-16-16-16h-16c-8.84 0-16 7.16-16 16v48c0 17.92-3.96 34.8-10.72 50.2l-26.55-20.52c3.1-9.4 5.28-19.22 5.28-29.67V96c0-53.02-42.98-96-96-96s-96 42.98-96 96v45.36L45.47 3.37C38.49-2.05 28.43-.8 23.01 6.18L3.37 31.45C-2.05 38.42-.8 48.47 6.18 53.9l588.36 454.73c6.98 5.43 17.03 4.17 22.46-2.81l19.64-25.27c5.41-6.97 4.16-17.02-2.82-22.45zM400 464h-56v-33.77c11.66-1.6 22.85-4.54 33.67-8.31l-50.11-38.73c-6.71.4-13.41.87-20.35.2-55.85-5.45-98.74-48.63-111.18-101.85L144 241.31v6.85c0 89.64 63.97 169.55 152 181.69V464h-56c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h160c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16z"]},Kc={prefix:"fas",iconName:"microscope",icon:[512,512,[],"f610","M160 320h12v16c0 8.84 7.16 16 16 16h40c8.84 0 16-7.16 16-16v-16h12c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32V16c0-8.84-7.16-16-16-16h-64c-8.84 0-16 7.16-16 16v16c-17.67 0-32 14.33-32 32v224c0 17.67 14.33 32 32 32zm304 128h-1.29C493.24 413.99 512 369.2 512 320c0-105.88-86.12-192-192-192v64c70.58 0 128 57.42 128 128s-57.42 128-128 128H48c-26.51 0-48 21.49-48 48 0 8.84 7.16 16 16 16h480c8.84 0 16-7.16 16-16 0-26.51-21.49-48-48-48zm-360-32h208c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8H104c-4.42 0-8 3.58-8 8v16c0 4.42 3.58 8 8 8z"]},$c={prefix:"fas",iconName:"minus",icon:[448,512,[],"f068","M416 208H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h384c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"]},qc={prefix:"fas",iconName:"minus-circle",icon:[512,512,[],"f056","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zM124 296c-6.6 0-12-5.4-12-12v-56c0-6.6 5.4-12 12-12h264c6.6 0 12 5.4 12 12v56c0 6.6-5.4 12-12 12H124z"]},Yc={prefix:"fas",iconName:"minus-square",icon:[448,512,[],"f146","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zM92 296c-6.6 0-12-5.4-12-12v-56c0-6.6 5.4-12 12-12h264c6.6 0 12 5.4 12 12v56c0 6.6-5.4 12-12 12H92z"]},Qc={prefix:"fas",iconName:"mitten",icon:[448,512,[],"f7b5","M368 416H48c-8.8 0-16 7.2-16 16v64c0 8.8 7.2 16 16 16h320c8.8 0 16-7.2 16-16v-64c0-8.8-7.2-16-16-16zm57-209.1c-27.2-22.6-67.5-19-90.1 8.2l-20.9 25-29.6-128.4c-18-77.5-95.4-125.9-172.8-108C34.2 21.6-14.2 98.9 3.7 176.4L51.6 384h309l72.5-87c22.7-27.2 19-67.5-8.1-90.1z"]},Xc={prefix:"fas",iconName:"mobile",icon:[320,512,[],"f10b","M272 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h224c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM160 480c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Zc={prefix:"fas",iconName:"mobile-alt",icon:[320,512,[],"f3cd","M272 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h224c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM160 480c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm112-108c0 6.6-5.4 12-12 12H60c-6.6 0-12-5.4-12-12V60c0-6.6 5.4-12 12-12h200c6.6 0 12 5.4 12 12v312z"]},Jc={prefix:"fas",iconName:"money-bill",icon:[640,512,[],"f0d6","M608 64H32C14.33 64 0 78.33 0 96v320c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V96c0-17.67-14.33-32-32-32zM48 400v-64c35.35 0 64 28.65 64 64H48zm0-224v-64h64c0 35.35-28.65 64-64 64zm272 176c-44.19 0-80-42.99-80-96 0-53.02 35.82-96 80-96s80 42.98 80 96c0 53.03-35.83 96-80 96zm272 48h-64c0-35.35 28.65-64 64-64v64zm0-224c-35.35 0-64-28.65-64-64h64v64z"]},eu={prefix:"fas",iconName:"money-bill-alt",icon:[640,512,[],"f3d1","M352 288h-16v-88c0-4.42-3.58-8-8-8h-13.58c-4.74 0-9.37 1.4-13.31 4.03l-15.33 10.22a7.994 7.994 0 0 0-2.22 11.09l8.88 13.31a7.994 7.994 0 0 0 11.09 2.22l.47-.31V288h-16c-4.42 0-8 3.58-8 8v16c0 4.42 3.58 8 8 8h64c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8zM608 64H32C14.33 64 0 78.33 0 96v320c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V96c0-17.67-14.33-32-32-32zM48 400v-64c35.35 0 64 28.65 64 64H48zm0-224v-64h64c0 35.35-28.65 64-64 64zm272 192c-53.02 0-96-50.15-96-112 0-61.86 42.98-112 96-112s96 50.14 96 112c0 61.87-43 112-96 112zm272 32h-64c0-35.35 28.65-64 64-64v64zm0-224c-35.35 0-64-28.65-64-64h64v64z"]},tu={prefix:"fas",iconName:"money-bill-wave",icon:[640,512,[],"f53a","M621.16 54.46C582.37 38.19 543.55 32 504.75 32c-123.17-.01-246.33 62.34-369.5 62.34-30.89 0-61.76-3.92-92.65-13.72-3.47-1.1-6.95-1.62-10.35-1.62C15.04 79 0 92.32 0 110.81v317.26c0 12.63 7.23 24.6 18.84 29.46C57.63 473.81 96.45 480 135.25 480c123.17 0 246.34-62.35 369.51-62.35 30.89 0 61.76 3.92 92.65 13.72 3.47 1.1 6.95 1.62 10.35 1.62 17.21 0 32.25-13.32 32.25-31.81V83.93c-.01-12.64-7.24-24.6-18.85-29.47zM48 132.22c20.12 5.04 41.12 7.57 62.72 8.93C104.84 170.54 79 192.69 48 192.69v-60.47zm0 285v-47.78c34.37 0 62.18 27.27 63.71 61.4-22.53-1.81-43.59-6.31-63.71-13.62zM320 352c-44.19 0-80-42.99-80-96 0-53.02 35.82-96 80-96s80 42.98 80 96c0 53.03-35.83 96-80 96zm272 27.78c-17.52-4.39-35.71-6.85-54.32-8.44 5.87-26.08 27.5-45.88 54.32-49.28v57.72zm0-236.11c-30.89-3.91-54.86-29.7-55.81-61.55 19.54 2.17 38.09 6.23 55.81 12.66v48.89z"]},iu={prefix:"fas",iconName:"money-bill-wave-alt",icon:[640,512,[],"f53b","M621.16 54.46C582.37 38.19 543.55 32 504.75 32c-123.17-.01-246.33 62.34-369.5 62.34-30.89 0-61.76-3.92-92.65-13.72-3.47-1.1-6.95-1.62-10.35-1.62C15.04 79 0 92.32 0 110.81v317.26c0 12.63 7.23 24.6 18.84 29.46C57.63 473.81 96.45 480 135.25 480c123.17 0 246.34-62.35 369.51-62.35 30.89 0 61.76 3.92 92.65 13.72 3.47 1.1 6.95 1.62 10.35 1.62 17.21 0 32.25-13.32 32.25-31.81V83.93c-.01-12.64-7.24-24.6-18.85-29.47zM320 352c-44.19 0-80-42.99-80-96 0-53.02 35.82-96 80-96s80 42.98 80 96c0 53.03-35.83 96-80 96z"]},ru={prefix:"fas",iconName:"money-check",icon:[640,512,[],"f53c","M0 448c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V128H0v320zm448-208c0-8.84 7.16-16 16-16h96c8.84 0 16 7.16 16 16v32c0 8.84-7.16 16-16 16h-96c-8.84 0-16-7.16-16-16v-32zm0 120c0-4.42 3.58-8 8-8h112c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H456c-4.42 0-8-3.58-8-8v-16zM64 264c0-4.42 3.58-8 8-8h304c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16zm0 96c0-4.42 3.58-8 8-8h176c4.42 0 8 3.58 8 8v16c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16zM624 32H16C7.16 32 0 39.16 0 48v48h640V48c0-8.84-7.16-16-16-16z"]},nu={prefix:"fas",iconName:"money-check-alt",icon:[640,512,[],"f53d","M608 32H32C14.33 32 0 46.33 0 64v384c0 17.67 14.33 32 32 32h576c17.67 0 32-14.33 32-32V64c0-17.67-14.33-32-32-32zM176 327.88V344c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-16.29c-11.29-.58-22.27-4.52-31.37-11.35-3.9-2.93-4.1-8.77-.57-12.14l11.75-11.21c2.77-2.64 6.89-2.76 10.13-.73 3.87 2.42 8.26 3.72 12.82 3.72h28.11c6.5 0 11.8-5.92 11.8-13.19 0-5.95-3.61-11.19-8.77-12.73l-45-13.5c-18.59-5.58-31.58-23.42-31.58-43.39 0-24.52 19.05-44.44 42.67-45.07V152c0-4.42 3.58-8 8-8h16c4.42 0 8 3.58 8 8v16.29c11.29.58 22.27 4.51 31.37 11.35 3.9 2.93 4.1 8.77.57 12.14l-11.75 11.21c-2.77 2.64-6.89 2.76-10.13.73-3.87-2.43-8.26-3.72-12.82-3.72h-28.11c-6.5 0-11.8 5.92-11.8 13.19 0 5.95 3.61 11.19 8.77 12.73l45 13.5c18.59 5.58 31.58 23.42 31.58 43.39 0 24.53-19.05 44.44-42.67 45.07zM416 312c0 4.42-3.58 8-8 8H296c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h112c4.42 0 8 3.58 8 8v16zm160 0c0 4.42-3.58 8-8 8h-80c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h80c4.42 0 8 3.58 8 8v16zm0-96c0 4.42-3.58 8-8 8H296c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h272c4.42 0 8 3.58 8 8v16z"]},su={prefix:"fas",iconName:"monument",icon:[384,512,[],"f5a6","M368 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h352c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm-78.86-347.26a31.97 31.97 0 0 0-9.21-19.44L203.31 4.69c-6.25-6.25-16.38-6.25-22.63 0l-76.6 76.61a31.97 31.97 0 0 0-9.21 19.44L64 416h256l-30.86-315.26zM240 307.2c0 6.4-6.4 12.8-12.8 12.8h-70.4c-6.4 0-12.8-6.4-12.8-12.8v-38.4c0-6.4 6.4-12.8 12.8-12.8h70.4c6.4 0 12.8 6.4 12.8 12.8v38.4z"]},ou={prefix:"fas",iconName:"moon",icon:[512,512,[],"f186","M283.211 512c78.962 0 151.079-35.925 198.857-94.792 7.068-8.708-.639-21.43-11.562-19.35-124.203 23.654-238.262-71.576-238.262-196.954 0-72.222 38.662-138.635 101.498-174.394 9.686-5.512 7.25-20.197-3.756-22.23A258.156 258.156 0 0 0 283.211 0c-141.309 0-256 114.511-256 256 0 141.309 114.511 256 256 256z"]},au={prefix:"fas",iconName:"mortar-pestle",icon:[512,512,[],"f5a7","M501.54 60.91c17.22-17.22 12.51-46.25-9.27-57.14a35.696 35.696 0 0 0-37.37 3.37L251.09 160h151.37l99.08-99.09zM496 192H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h16c0 80.98 50.2 150.11 121.13 178.32-12.76 16.87-21.72 36.8-24.95 58.69-1.46 9.92 6.04 18.98 16.07 18.98h223.5c10.03 0 17.53-9.06 16.07-18.98-3.22-21.89-12.18-41.82-24.95-58.69C429.8 406.11 480 336.98 480 256h16c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16z"]},lu={prefix:"fas",iconName:"mosque",icon:[640,512,[],"f678","M0 480c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32V160H0v320zm579.16-192c17.86-17.39 28.84-37.34 28.84-58.91 0-52.86-41.79-93.79-87.92-122.9-41.94-26.47-80.63-57.77-111.96-96.22L400 0l-8.12 9.97c-31.33 38.45-70.01 69.76-111.96 96.22C233.79 135.3 192 176.23 192 229.09c0 21.57 10.98 41.52 28.84 58.91h358.32zM608 320H192c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h32v-64c0-17.67 14.33-32 32-32s32 14.33 32 32v64h64v-72c0-48 48-72 48-72s48 24 48 72v72h64v-64c0-17.67 14.33-32 32-32s32 14.33 32 32v64h32c17.67 0 32-14.33 32-32V352c0-17.67-14.33-32-32-32zM64 0S0 32 0 96v32h128V96c0-64-64-96-64-96z"]},cu={prefix:"fas",iconName:"motorcycle",icon:[640,512,[],"f21c","M512.9 192c-14.9-.1-29.1 2.3-42.4 6.9L437.6 144H520c13.3 0 24-10.7 24-24V88c0-13.3-10.7-24-24-24h-45.3c-6.8 0-13.3 2.9-17.8 7.9l-37.5 41.7-22.8-38C392.2 68.4 384.4 64 376 64h-80c-8.8 0-16 7.2-16 16v16c0 8.8 7.2 16 16 16h66.4l19.2 32H227.9c-17.7-23.1-44.9-40-99.9-40H72.5C59 104 47.7 115 48 128.5c.2 13 10.9 23.5 24 23.5h56c24.5 0 38.7 10.9 47.8 24.8l-11.3 20.5c-13-3.9-26.9-5.7-41.3-5.2C55.9 194.5 1.6 249.6 0 317c-1.6 72.1 56.3 131 128 131 59.6 0 109.7-40.8 124-96h84.2c13.7 0 24.6-11.4 24-25.1-2.1-47.1 17.5-93.7 56.2-125l12.5 20.8c-27.6 23.7-45.1 58.9-44.8 98.2.5 69.6 57.2 126.5 126.8 127.1 71.6.7 129.8-57.5 129.2-129.1-.7-69.6-57.6-126.4-127.2-126.9zM128 400c-44.1 0-80-35.9-80-80s35.9-80 80-80c4.2 0 8.4.3 12.5 1L99 316.4c-8.8 16 2.8 35.6 21 35.6h81.3c-12.4 28.2-40.6 48-73.3 48zm463.9-75.6c-2.2 40.6-35 73.4-75.5 75.5-46.1 2.5-84.4-34.3-84.4-79.9 0-21.4 8.4-40.8 22.1-55.1l49.4 82.4c4.5 7.6 14.4 10 22 5.5l13.7-8.2c7.6-4.5 10-14.4 5.5-22l-48.6-80.9c5.2-1.1 10.5-1.6 15.9-1.6 45.6-.1 82.3 38.2 79.9 84.3z"]},uu={prefix:"fas",iconName:"mountain",icon:[640,512,[],"f6fc","M634.92 462.7l-288-448C341.03 5.54 330.89 0 320 0s-21.03 5.54-26.92 14.7l-288 448a32.001 32.001 0 0 0-1.17 32.64A32.004 32.004 0 0 0 32 512h576c11.71 0 22.48-6.39 28.09-16.67a31.983 31.983 0 0 0-1.17-32.63zM320 91.18L405.39 224H320l-64 64-38.06-38.06L320 91.18z"]},hu={prefix:"fas",iconName:"mouse",icon:[384,512,[],"f8cc","M0 352a160 160 0 0 0 160 160h64a160 160 0 0 0 160-160V224H0zM176 0h-16A160 160 0 0 0 0 160v32h176zm48 0h-16v192h176v-32A160 160 0 0 0 224 0z"]},du={prefix:"fas",iconName:"mouse-pointer",icon:[320,512,[],"f245","M302.189 329.126H196.105l55.831 135.993c3.889 9.428-.555 19.999-9.444 23.999l-49.165 21.427c-9.165 4-19.443-.571-23.332-9.714l-53.053-129.136-86.664 89.138C18.729 472.71 0 463.554 0 447.977V18.299C0 1.899 19.921-6.096 30.277 5.443l284.412 292.542c11.472 11.179 3.007 31.141-12.5 31.141z"]},pu={prefix:"fas",iconName:"mug-hot",icon:[512,512,[],"f7b6","M127.1 146.5c1.3 7.7 8 13.5 16 13.5h16.5c9.8 0 17.6-8.5 16.3-18-3.8-28.2-16.4-54.2-36.6-74.7-14.4-14.7-23.6-33.3-26.4-53.5C111.8 5.9 105 0 96.8 0H80.4C70.6 0 63 8.5 64.1 18c3.9 31.9 18 61.3 40.6 84.4 12 12.2 19.7 27.5 22.4 44.1zm112 0c1.3 7.7 8 13.5 16 13.5h16.5c9.8 0 17.6-8.5 16.3-18-3.8-28.2-16.4-54.2-36.6-74.7-14.4-14.7-23.6-33.3-26.4-53.5C223.8 5.9 217 0 208.8 0h-16.4c-9.8 0-17.5 8.5-16.3 18 3.9 31.9 18 61.3 40.6 84.4 12 12.2 19.7 27.5 22.4 44.1zM400 192H32c-17.7 0-32 14.3-32 32v192c0 53 43 96 96 96h192c53 0 96-43 96-96h16c61.8 0 112-50.2 112-112s-50.2-112-112-112zm0 160h-16v-96h16c26.5 0 48 21.5 48 48s-21.5 48-48 48z"]},gu={prefix:"fas",iconName:"music",icon:[512,512,[],"f001","M470.38 1.51L150.41 96A32 32 0 0 0 128 126.51v261.41A139 139 0 0 0 96 384c-53 0-96 28.66-96 64s43 64 96 64 96-28.66 96-64V214.32l256-75v184.61a138.4 138.4 0 0 0-32-3.93c-53 0-96 28.66-96 64s43 64 96 64 96-28.65 96-64V32a32 32 0 0 0-41.62-30.49z"]},fu={prefix:"fas",iconName:"network-wired",icon:[640,512,[],"f6ff","M640 264v-16c0-8.84-7.16-16-16-16H344v-40h72c17.67 0 32-14.33 32-32V32c0-17.67-14.33-32-32-32H224c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h72v40H16c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h104v40H64c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h160c17.67 0 32-14.33 32-32V352c0-17.67-14.33-32-32-32h-56v-40h304v40h-56c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h160c17.67 0 32-14.33 32-32V352c0-17.67-14.33-32-32-32h-56v-40h104c8.84 0 16-7.16 16-16zM256 128V64h128v64H256zm-64 320H96v-64h96v64zm352 0h-96v-64h96v64z"]},mu={prefix:"fas",iconName:"neuter",icon:[288,512,[],"f22c","M288 176c0-79.5-64.5-144-144-144S0 96.5 0 176c0 68.5 47.9 125.9 112 140.4V468c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12V316.4c64.1-14.5 112-71.9 112-140.4zm-144 80c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},vu={prefix:"fas",iconName:"newspaper",icon:[576,512,[],"f1ea","M552 64H88c-13.255 0-24 10.745-24 24v8H24c-13.255 0-24 10.745-24 24v272c0 30.928 25.072 56 56 56h472c26.51 0 48-21.49 48-48V88c0-13.255-10.745-24-24-24zM56 400a8 8 0 0 1-8-8V144h16v248a8 8 0 0 1-8 8zm236-16H140c-6.627 0-12-5.373-12-12v-8c0-6.627 5.373-12 12-12h152c6.627 0 12 5.373 12 12v8c0 6.627-5.373 12-12 12zm208 0H348c-6.627 0-12-5.373-12-12v-8c0-6.627 5.373-12 12-12h152c6.627 0 12 5.373 12 12v8c0 6.627-5.373 12-12 12zm-208-96H140c-6.627 0-12-5.373-12-12v-8c0-6.627 5.373-12 12-12h152c6.627 0 12 5.373 12 12v8c0 6.627-5.373 12-12 12zm208 0H348c-6.627 0-12-5.373-12-12v-8c0-6.627 5.373-12 12-12h152c6.627 0 12 5.373 12 12v8c0 6.627-5.373 12-12 12zm0-96H140c-6.627 0-12-5.373-12-12v-40c0-6.627 5.373-12 12-12h360c6.627 0 12 5.373 12 12v40c0 6.627-5.373 12-12 12z"]},Cu={prefix:"fas",iconName:"not-equal",icon:[448,512,[],"f53e","M416 208c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32h-23.88l51.87-66.81c5.37-7.02 4.04-17.06-2.97-22.43L415.61 3.3c-7.02-5.38-17.06-4.04-22.44 2.97L311.09 112H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h204.56l-74.53 96H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h55.49l-51.87 66.81c-5.37 7.01-4.04 17.05 2.97 22.43L64 508.7c7.02 5.38 17.06 4.04 22.43-2.97L168.52 400H416c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32H243.05l74.53-96H416z"]},yu={prefix:"fas",iconName:"notes-medical",icon:[384,512,[],"f481","M336 64h-80c0-35.3-28.7-64-64-64s-64 28.7-64 64H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM192 40c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm96 304c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8v48zm0-192c0 4.4-3.6 8-8 8H104c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h176c4.4 0 8 3.6 8 8v16z"]},wu={prefix:"fas",iconName:"object-group",icon:[512,512,[],"f247","M480 128V96h20c6.627 0 12-5.373 12-12V44c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v20H64V44c0-6.627-5.373-12-12-12H12C5.373 32 0 37.373 0 44v40c0 6.627 5.373 12 12 12h20v320H12c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-20h384v20c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-20V128zM96 276V140c0-6.627 5.373-12 12-12h168c6.627 0 12 5.373 12 12v136c0 6.627-5.373 12-12 12H108c-6.627 0-12-5.373-12-12zm320 96c0 6.627-5.373 12-12 12H236c-6.627 0-12-5.373-12-12v-52h72c13.255 0 24-10.745 24-24v-72h84c6.627 0 12 5.373 12 12v136z"]},Su={prefix:"fas",iconName:"object-ungroup",icon:[576,512,[],"f248","M64 320v26a6 6 0 0 1-6 6H6a6 6 0 0 1-6-6v-52a6 6 0 0 1 6-6h26V96H6a6 6 0 0 1-6-6V38a6 6 0 0 1 6-6h52a6 6 0 0 1 6 6v26h288V38a6 6 0 0 1 6-6h52a6 6 0 0 1 6 6v52a6 6 0 0 1-6 6h-26v192h26a6 6 0 0 1 6 6v52a6 6 0 0 1-6 6h-52a6 6 0 0 1-6-6v-26H64zm480-64v-32h26a6 6 0 0 0 6-6v-52a6 6 0 0 0-6-6h-52a6 6 0 0 0-6 6v26H408v72h8c13.255 0 24 10.745 24 24v64c0 13.255-10.745 24-24 24h-64c-13.255 0-24-10.745-24-24v-8H192v72h-26a6 6 0 0 0-6 6v52a6 6 0 0 0 6 6h52a6 6 0 0 0 6-6v-26h288v26a6 6 0 0 0 6 6h52a6 6 0 0 0 6-6v-52a6 6 0 0 0-6-6h-26V256z"]},bu={prefix:"fas",iconName:"oil-can",icon:[640,512,[],"f613","M629.8 160.31L416 224l-50.49-25.24a64.07 64.07 0 0 0-28.62-6.76H280v-48h56c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16H176c-8.84 0-16 7.16-16 16v16c0 8.84 7.16 16 16 16h56v48h-56L37.72 166.86a31.9 31.9 0 0 0-5.79-.53C14.67 166.33 0 180.36 0 198.34v94.95c0 15.46 11.06 28.72 26.28 31.48L96 337.46V384c0 17.67 14.33 32 32 32h274.63c8.55 0 16.75-3.42 22.76-9.51l212.26-214.75c1.5-1.5 2.34-3.54 2.34-5.66V168c.01-5.31-5.08-9.15-10.19-7.69zM96 288.67l-48-8.73v-62.43l48 8.73v62.43zm453.33 84.66c0 23.56 19.1 42.67 42.67 42.67s42.67-19.1 42.67-42.67S592 288 592 288s-42.67 61.77-42.67 85.33z"]},Eu={prefix:"fas",iconName:"om",icon:[512,512,[],"f679","M360.6 60.94a10.43 10.43 0 0 0 14.76 0l21.57-21.56a10.43 10.43 0 0 0 0-14.76L375.35 3.06c-4.08-4.07-10.68-4.07-14.76 0l-21.57 21.56a10.43 10.43 0 0 0 0 14.76l21.58 21.56zM412.11 192c-26.69 0-51.77 10.39-70.64 29.25l-24.25 24.25c-6.78 6.77-15.78 10.5-25.38 10.5H245c10.54-22.1 14.17-48.11 7.73-75.23-10.1-42.55-46.36-76.11-89.52-83.19-36.15-5.93-70.9 5.04-96.01 28.78-7.36 6.96-6.97 18.85 1.12 24.93l26.15 19.63c5.72 4.3 13.66 4.32 19.2-.21 8.45-6.9 19.02-10.71 30.27-10.71 26.47 0 48.01 21.53 48.01 48s-21.54 48-48.01 48h-31.9c-11.96 0-19.74 12.58-14.39 23.28l16.09 32.17c2.53 5.06 7.6 8.1 13.17 8.55h33.03c35.3 0 64.01 28.7 64.01 64s-28.71 64-64.01 64c-96.02 0-122.35-54.02-145.15-92.03-4.53-7.55-14.77-3.58-14.79 5.22C-.09 416 41.13 512 159.94 512c70.59 0 128.02-57.42 128.02-128 0-23.42-6.78-45.1-17.81-64h21.69c26.69 0 51.77-10.39 70.64-29.25l24.25-24.25c6.78-6.77 15.78-10.5 25.38-10.5 19.78 0 35.88 16.09 35.88 35.88V392c0 13.23-18.77 24-32.01 24-39.4 0-66.67-24.24-81.82-42.89-4.77-5.87-14.2-2.54-14.2 5.02V416s0 64 96.02 64c48.54 0 96.02-39.47 96.02-88V291.88c0-55.08-44.8-99.88-99.89-99.88zm42.18-124.73c-85.55 65.12-169.05 2.75-172.58.05-6.02-4.62-14.44-4.38-20.14.55-5.74 4.92-7.27 13.17-3.66 19.8 1.61 2.95 40.37 72.34 118.8 72.34 79.92 0 98.78-31.36 101.75-37.66 1.02-2.12 1.53-4.47 1.53-6.83V80c0-13.22-15.14-20.69-25.7-12.73z"]},Au={prefix:"fas",iconName:"otter",icon:[640,512,[],"f700","M608 32h-32l-13.25-13.25A63.97 63.97 0 0 0 517.49 0H497c-11.14 0-22.08 2.91-31.75 8.43L312 96h-56C149.96 96 64 181.96 64 288v1.61c0 32.75-16 62.14-39.56 84.89-18.19 17.58-28.1 43.68-23.19 71.8 6.76 38.8 42.9 65.7 82.28 65.7H192c17.67 0 32-14.33 32-32s-14.33-32-32-32H80c-8.83 0-16-7.17-16-16s7.17-16 16-16h224c8.84 0 16-7.16 16-16v-16c0-17.67-14.33-32-32-32h-64l149.49-80.5L448 416h80c8.84 0 16-7.16 16-16v-16c0-17.67-14.33-32-32-32h-28.22l-55.11-110.21L521.14 192H544c53.02 0 96-42.98 96-96V64c0-17.67-14.33-32-32-32zm-96 16c8.84 0 16 7.16 16 16s-7.16 16-16 16-16-7.16-16-16 7.16-16 16-16zm32 96h-34.96L407.2 198.84l-13.77-27.55L512 112h77.05c-6.62 18.58-24.22 32-45.05 32z"]},Tu={prefix:"fas",iconName:"outdent",icon:[448,512,[],"f03b","M100.69 363.29c10 10 27.31 2.93 27.31-11.31V160c0-14.32-17.33-21.31-27.31-11.31l-96 96a16 16 0 0 0 0 22.62zM432 416H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm3.17-128H204.83A12.82 12.82 0 0 0 192 300.83v38.34A12.82 12.82 0 0 0 204.83 352h230.34A12.82 12.82 0 0 0 448 339.17v-38.34A12.82 12.82 0 0 0 435.17 288zm0-128H204.83A12.82 12.82 0 0 0 192 172.83v38.34A12.82 12.82 0 0 0 204.83 224h230.34A12.82 12.82 0 0 0 448 211.17v-38.34A12.82 12.82 0 0 0 435.17 160zM432 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Mu={prefix:"fas",iconName:"pager",icon:[512,512,[],"f815","M448 64H64a64 64 0 0 0-64 64v256a64 64 0 0 0 64 64h384a64 64 0 0 0 64-64V128a64 64 0 0 0-64-64zM160 368H80a16 16 0 0 1-16-16v-16a16 16 0 0 1 16-16h80zm128-16a16 16 0 0 1-16 16h-80v-48h80a16 16 0 0 1 16 16zm160-128a32 32 0 0 1-32 32H96a32 32 0 0 1-32-32v-64a32 32 0 0 1 32-32h320a32 32 0 0 1 32 32z"]},Ru={prefix:"fas",iconName:"paint-brush",icon:[512,512,[],"f1fc","M167.02 309.34c-40.12 2.58-76.53 17.86-97.19 72.3-2.35 6.21-8 9.98-14.59 9.98-11.11 0-45.46-27.67-55.25-34.35C0 439.62 37.93 512 128 512c75.86 0 128-43.77 128-120.19 0-3.11-.65-6.08-.97-9.13l-88.01-73.34zM457.89 0c-15.16 0-29.37 6.71-40.21 16.45C213.27 199.05 192 203.34 192 257.09c0 13.7 3.25 26.76 8.73 38.7l63.82 53.18c7.21 1.8 14.64 3.03 22.39 3.03 62.11 0 98.11-45.47 211.16-256.46 7.38-14.35 13.9-29.85 13.9-45.99C512 20.64 486 0 457.89 0z"]},_u={prefix:"fas",iconName:"paint-roller",icon:[512,512,[],"f5aa","M416 128V32c0-17.67-14.33-32-32-32H32C14.33 0 0 14.33 0 32v96c0 17.67 14.33 32 32 32h352c17.67 0 32-14.33 32-32zm32-64v128c0 17.67-14.33 32-32 32H256c-35.35 0-64 28.65-64 64v32c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32V352c0-17.67-14.33-32-32-32v-32h160c53.02 0 96-42.98 96-96v-64c0-35.35-28.65-64-64-64z"]},Pu={prefix:"fas",iconName:"palette",icon:[512,512,[],"f53f","M204.3 5C104.9 24.4 24.8 104.3 5.2 203.4c-37 187 131.7 326.4 258.8 306.7 41.2-6.4 61.4-54.6 42.5-91.7-23.1-45.4 9.9-98.4 60.9-98.4h79.7c35.8 0 64.8-29.6 64.9-65.3C511.5 97.1 368.1-26.9 204.3 5zM96 320c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm32-128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128-64c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm128 64c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},xu={prefix:"fas",iconName:"pallet",icon:[640,512,[],"f482","M144 256h352c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16H384v128l-64-32-64 32V0H144c-8.8 0-16 7.2-16 16v224c0 8.8 7.2 16 16 16zm480 128c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h48v64H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h608c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16h-48v-64h48zm-336 64H128v-64h160v64zm224 0H352v-64h160v64z"]},Du={prefix:"fas",iconName:"paper-plane",icon:[512,512,[],"f1d8","M476 3.2L12.5 270.6c-18.1 10.4-15.8 35.6 2.2 43.2L121 358.4l287.3-253.2c5.5-4.9 13.3 2.6 8.6 8.3L176 407v80.5c0 23.6 28.5 32.9 42.5 15.8L282 426l124.6 52.2c14.2 6 30.4-2.9 33-18.2l72-432C515 7.8 493.3-6.8 476 3.2z"]},Iu={prefix:"fas",iconName:"paperclip",icon:[448,512,[],"f0c6","M43.246 466.142c-58.43-60.289-57.341-157.511 1.386-217.581L254.392 34c44.316-45.332 116.351-45.336 160.671 0 43.89 44.894 43.943 117.329 0 162.276L232.214 383.128c-29.855 30.537-78.633 30.111-107.982-.998-28.275-29.97-27.368-77.473 1.452-106.953l143.743-146.835c6.182-6.314 16.312-6.422 22.626-.241l22.861 22.379c6.315 6.182 6.422 16.312.241 22.626L171.427 319.927c-4.932 5.045-5.236 13.428-.648 18.292 4.372 4.634 11.245 4.711 15.688.165l182.849-186.851c19.613-20.062 19.613-52.725-.011-72.798-19.189-19.627-49.957-19.637-69.154 0L90.39 293.295c-34.763 35.56-35.299 93.12-1.191 128.313 34.01 35.093 88.985 35.137 123.058.286l172.06-175.999c6.177-6.319 16.307-6.433 22.626-.256l22.877 22.364c6.319 6.177 6.434 16.307.256 22.626l-172.06 175.998c-59.576 60.938-155.943 60.216-214.77-.485z"]},Lu={prefix:"fas",iconName:"parachute-box",icon:[512,512,[],"f4cd","M511.9 175c-9.1-75.6-78.4-132.4-158.3-158.7C390 55.7 416 116.9 416 192h28.1L327.5 321.5c-2.5-.6-4.8-1.5-7.5-1.5h-48V192h112C384 76.8 315.1 0 256 0S128 76.8 128 192h112v128h-48c-2.7 0-5 .9-7.5 1.5L67.9 192H96c0-75.1 26-136.3 62.4-175.7C78.5 42.7 9.2 99.5.1 175c-1.1 9.1 6.8 17 16 17h8.7l136.7 151.9c-.7 2.6-1.6 5.2-1.6 8.1v128c0 17.7 14.3 32 32 32h128c17.7 0 32-14.3 32-32V352c0-2.9-.9-5.4-1.6-8.1L487.1 192h8.7c9.3 0 17.2-7.8 16.1-17z"]},Nu={prefix:"fas",iconName:"paragraph",icon:[448,512,[],"f1dd","M448 48v32a16 16 0 0 1-16 16h-48v368a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16V96h-32v368a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16V352h-32a160 160 0 0 1 0-320h240a16 16 0 0 1 16 16z"]},Ou={prefix:"fas",iconName:"parking",icon:[448,512,[],"f540","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zM240 320h-48v48c0 8.8-7.2 16-16 16h-32c-8.8 0-16-7.2-16-16V144c0-8.8 7.2-16 16-16h96c52.9 0 96 43.1 96 96s-43.1 96-96 96zm0-128h-48v64h48c17.6 0 32-14.4 32-32s-14.4-32-32-32z"]},Fu={prefix:"fas",iconName:"passport",icon:[448,512,[],"f5ab","M129.62 176h39.09c1.49-27.03 6.54-51.35 14.21-70.41-27.71 13.24-48.02 39.19-53.3 70.41zm0 32c5.29 31.22 25.59 57.17 53.3 70.41-7.68-19.06-12.72-43.38-14.21-70.41h-39.09zM224 286.69c7.69-7.45 20.77-34.42 23.43-78.69h-46.87c2.67 44.26 15.75 71.24 23.44 78.69zM200.57 176h46.87c-2.66-44.26-15.74-71.24-23.43-78.69-7.7 7.45-20.78 34.43-23.44 78.69zm64.51 102.41c27.71-13.24 48.02-39.19 53.3-70.41h-39.09c-1.49 27.03-6.53 51.35-14.21 70.41zM416 0H64C28.65 0 0 28.65 0 64v384c0 35.35 28.65 64 64 64h352c17.67 0 32-14.33 32-32V32c0-17.67-14.33-32-32-32zm-80 416H112c-8.8 0-16-7.2-16-16s7.2-16 16-16h224c8.8 0 16 7.2 16 16s-7.2 16-16 16zm-112-96c-70.69 0-128-57.31-128-128S153.31 64 224 64s128 57.31 128 128-57.31 128-128 128zm41.08-214.41c7.68 19.06 12.72 43.38 14.21 70.41h39.09c-5.28-31.22-25.59-57.17-53.3-70.41z"]},ku={prefix:"fas",iconName:"pastafarianism",icon:[640,512,[],"f67b","M624.54 347.67c-32.7-12.52-57.36 4.25-75.37 16.45-17.06 11.53-23.25 14.42-31.41 11.36-8.12-3.09-10.83-9.38-15.89-29.38-3.33-13.15-7.44-29.32-17.95-42.65 2.24-2.91 4.43-5.79 6.38-8.57C500.47 304.45 513.71 312 532 312c33.95 0 50.87-25.78 62.06-42.83 10.59-16.14 15-21.17 21.94-21.17 13.25 0 24-10.75 24-24s-10.75-24-24-24c-33.95 0-50.87 25.78-62.06 42.83-10.6 16.14-15 21.17-21.94 21.17-17.31 0-37.48-61.43-97.26-101.91l17.25-34.5C485.43 125.5 512 97.98 512 64c0-35.35-28.65-64-64-64s-64 28.65-64 64c0 13.02 3.94 25.1 10.62 35.21l-18.15 36.3c-16.98-4.6-35.6-7.51-56.46-7.51s-39.49 2.91-56.46 7.51l-18.15-36.3C252.06 89.1 256 77.02 256 64c0-35.35-28.65-64-64-64s-64 28.65-64 64c0 33.98 26.56 61.5 60.02 63.6l17.25 34.5C145.68 202.44 125.15 264 108 264c-6.94 0-11.34-5.03-21.94-21.17C74.88 225.78 57.96 200 24 200c-13.25 0-24 10.75-24 24s10.75 24 24 24c6.94 0 11.34 5.03 21.94 21.17C57.13 286.22 74.05 312 108 312c18.29 0 31.53-7.55 41.7-17.11 1.95 2.79 4.14 5.66 6.38 8.57-10.51 13.33-14.62 29.5-17.95 42.65-5.06 20-7.77 26.28-15.89 29.38-8.11 3.06-14.33.17-31.41-11.36-18.03-12.2-42.72-28.92-75.37-16.45-12.39 4.72-18.59 18.58-13.87 30.97 4.72 12.41 18.61 18.61 30.97 13.88 8.16-3.09 14.34-.19 31.39 11.36 13.55 9.16 30.83 20.86 52.42 20.84 7.17 0 14.83-1.28 22.97-4.39 32.66-12.44 39.98-41.33 45.33-62.44 2.21-8.72 3.99-14.49 5.95-18.87 16.62 13.61 36.95 25.88 61.64 34.17-9.96 37-32.18 90.8-60.26 90.8-13.25 0-24 10.75-24 24s10.75 24 24 24c66.74 0 97.05-88.63 107.42-129.14 6.69.6 13.42 1.14 20.58 1.14s13.89-.54 20.58-1.14C350.95 423.37 381.26 512 448 512c13.25 0 24-10.75 24-24s-10.75-24-24-24c-27.94 0-50.21-53.81-60.22-90.81 24.69-8.29 45-20.56 61.62-34.16 1.96 4.38 3.74 10.15 5.95 18.87 5.34 21.11 12.67 50 45.33 62.44 8.14 3.11 15.8 4.39 22.97 4.39 21.59 0 38.87-11.69 52.42-20.84 17.05-11.55 23.28-14.45 31.39-11.36 12.39 4.75 26.27-1.47 30.97-13.88 4.71-12.4-1.49-26.26-13.89-30.98zM448 48c8.82 0 16 7.18 16 16s-7.18 16-16 16-16-7.18-16-16 7.18-16 16-16zm-256 0c8.82 0 16 7.18 16 16s-7.18 16-16 16-16-7.18-16-16 7.18-16 16-16z"]},Gu={prefix:"fas",iconName:"paste",icon:[448,512,[],"f0ea","M128 184c0-30.879 25.122-56 56-56h136V56c0-13.255-10.745-24-24-24h-80.61C204.306 12.89 183.637 0 160 0s-44.306 12.89-55.39 32H24C10.745 32 0 42.745 0 56v336c0 13.255 10.745 24 24 24h104V184zm32-144c13.255 0 24 10.745 24 24s-10.745 24-24 24-24-10.745-24-24 10.745-24 24-24zm184 248h104v200c0 13.255-10.745 24-24 24H184c-13.255 0-24-10.745-24-24V184c0-13.255 10.745-24 24-24h136v104c0 13.2 10.8 24 24 24zm104-38.059V256h-96v-96h6.059a24 24 0 0 1 16.97 7.029l65.941 65.941a24.002 24.002 0 0 1 7.03 16.971z"]},Vu={prefix:"fas",iconName:"pause",icon:[448,512,[],"f04c","M144 479H48c-26.5 0-48-21.5-48-48V79c0-26.5 21.5-48 48-48h96c26.5 0 48 21.5 48 48v352c0 26.5-21.5 48-48 48zm304-48V79c0-26.5-21.5-48-48-48h-96c-26.5 0-48 21.5-48 48v352c0 26.5 21.5 48 48 48h96c26.5 0 48-21.5 48-48z"]},Hu={prefix:"fas",iconName:"pause-circle",icon:[512,512,[],"f28b","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm-16 328c0 8.8-7.2 16-16 16h-48c-8.8 0-16-7.2-16-16V176c0-8.8 7.2-16 16-16h48c8.8 0 16 7.2 16 16v160zm112 0c0 8.8-7.2 16-16 16h-48c-8.8 0-16-7.2-16-16V176c0-8.8 7.2-16 16-16h48c8.8 0 16 7.2 16 16v160z"]},Bu={prefix:"fas",iconName:"paw",icon:[512,512,[],"f1b0","M256 224c-79.41 0-192 122.76-192 200.25 0 34.9 26.81 55.75 71.74 55.75 48.84 0 81.09-25.08 120.26-25.08 39.51 0 71.85 25.08 120.26 25.08 44.93 0 71.74-20.85 71.74-55.75C448 346.76 335.41 224 256 224zm-147.28-12.61c-10.4-34.65-42.44-57.09-71.56-50.13-29.12 6.96-44.29 40.69-33.89 75.34 10.4 34.65 42.44 57.09 71.56 50.13 29.12-6.96 44.29-40.69 33.89-75.34zm84.72-20.78c30.94-8.14 46.42-49.94 34.58-93.36s-46.52-72.01-77.46-63.87-46.42 49.94-34.58 93.36c11.84 43.42 46.53 72.02 77.46 63.87zm281.39-29.34c-29.12-6.96-61.15 15.48-71.56 50.13-10.4 34.65 4.77 68.38 33.89 75.34 29.12 6.96 61.15-15.48 71.56-50.13 10.4-34.65-4.77-68.38-33.89-75.34zm-156.27 29.34c30.94 8.14 65.62-20.45 77.46-63.87 11.84-43.42-3.64-85.21-34.58-93.36s-65.62 20.45-77.46 63.87c-11.84 43.42 3.64 85.22 34.58 93.36z"]},zu={prefix:"fas",iconName:"peace",icon:[496,512,[],"f67c","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm184 248c0 31.93-8.2 61.97-22.57 88.17L280 240.63V74.97c86.23 15.21 152 90.5 152 181.03zM216 437.03c-33.86-5.97-64.49-21.2-89.29-43.02L216 322.57v114.46zm64-114.46L369.29 394c-24.8 21.82-55.43 37.05-89.29 43.02V322.57zm-64-247.6v165.66L86.57 344.17C72.2 317.97 64 287.93 64 256c0-90.53 65.77-165.82 152-181.03z"]},Uu={prefix:"fas",iconName:"pen",icon:[512,512,[],"f304","M290.74 93.24l128.02 128.02-277.99 277.99-114.14 12.6C11.35 513.54-1.56 500.62.14 485.34l12.7-114.22 277.9-277.88zm207.2-19.06l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.76 18.75-49.16 0-67.91z"]},Wu={prefix:"fas",iconName:"pen-alt",icon:[512,512,[],"f305","M497.94 74.17l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.75 18.75-49.15 0-67.91zm-246.8-20.53c-15.62-15.62-40.94-15.62-56.56 0L75.8 172.43c-6.25 6.25-6.25 16.38 0 22.62l22.63 22.63c6.25 6.25 16.38 6.25 22.63 0l101.82-101.82 22.63 22.62L93.95 290.03A327.038 327.038 0 0 0 .17 485.11l-.03.23c-1.7 15.28 11.21 28.2 26.49 26.51a327.02 327.02 0 0 0 195.34-93.8l196.79-196.79-82.77-82.77-84.85-84.85z"]},ju={prefix:"fas",iconName:"pen-fancy",icon:[512,512,[],"f5ac","M79.18 282.94a32.005 32.005 0 0 0-20.24 20.24L0 480l4.69 4.69 92.89-92.89c-.66-2.56-1.57-5.03-1.57-7.8 0-17.67 14.33-32 32-32s32 14.33 32 32-14.33 32-32 32c-2.77 0-5.24-.91-7.8-1.57l-92.89 92.89L32 512l176.82-58.94a31.983 31.983 0 0 0 20.24-20.24l33.07-84.07-98.88-98.88-84.07 33.07zM369.25 28.32L186.14 227.81l97.85 97.85 199.49-183.11C568.4 67.48 443.73-55.94 369.25 28.32z"]},Ku={prefix:"fas",iconName:"pen-nib",icon:[512,512,[],"f5ad","M136.6 138.79a64.003 64.003 0 0 0-43.31 41.35L0 460l14.69 14.69L164.8 324.58c-2.99-6.26-4.8-13.18-4.8-20.58 0-26.51 21.49-48 48-48s48 21.49 48 48-21.49 48-48 48c-7.4 0-14.32-1.81-20.58-4.8L37.31 497.31 52 512l279.86-93.29a64.003 64.003 0 0 0 41.35-43.31L416 224 288 96l-151.4 42.79zm361.34-64.62l-60.11-60.11c-18.75-18.75-49.16-18.75-67.91 0l-56.55 56.55 128.02 128.02 56.55-56.55c18.75-18.75 18.75-49.15 0-67.91z"]},$u={prefix:"fas",iconName:"pen-square",icon:[448,512,[],"f14b","M400 480H48c-26.5 0-48-21.5-48-48V80c0-26.5 21.5-48 48-48h352c26.5 0 48 21.5 48 48v352c0 26.5-21.5 48-48 48zM238.1 177.9L102.4 313.6l-6.3 57.1c-.8 7.6 5.6 14.1 13.3 13.3l57.1-6.3L302.2 242c2.3-2.3 2.3-6.1 0-8.5L246.7 178c-2.5-2.4-6.3-2.4-8.6-.1zM345 165.1L314.9 135c-9.4-9.4-24.6-9.4-33.9 0l-23.1 23.1c-2.3 2.3-2.3 6.1 0 8.5l55.5 55.5c2.3 2.3 6.1 2.3 8.5 0L345 199c9.3-9.3 9.3-24.5 0-33.9z"]},qu={prefix:"fas",iconName:"pencil-alt",icon:[512,512,[],"f303","M497.9 142.1l-46.1 46.1c-4.7 4.7-12.3 4.7-17 0l-111-111c-4.7-4.7-4.7-12.3 0-17l46.1-46.1c18.7-18.7 49.1-18.7 67.9 0l60.1 60.1c18.8 18.7 18.8 49.1 0 67.9zM284.2 99.8L21.6 362.4.4 483.9c-2.9 16.4 11.4 30.6 27.8 27.8l121.5-21.3 262.6-262.6c4.7-4.7 4.7-12.3 0-17l-111-111c-4.8-4.7-12.4-4.7-17.1 0zM124.1 339.9c-5.5-5.5-5.5-14.3 0-19.8l154-154c5.5-5.5 14.3-5.5 19.8 0s5.5 14.3 0 19.8l-154 154c-5.5 5.5-14.3 5.5-19.8 0zM88 424h48v36.3l-64.5 11.3-31.1-31.1L51.7 376H88v48z"]},Yu={prefix:"fas",iconName:"pencil-ruler",icon:[512,512,[],"f5ae","M109.46 244.04l134.58-134.56-44.12-44.12-61.68 61.68a7.919 7.919 0 0 1-11.21 0l-11.21-11.21c-3.1-3.1-3.1-8.12 0-11.21l61.68-61.68-33.64-33.65C131.47-3.1 111.39-3.1 99 9.29L9.29 99c-12.38 12.39-12.39 32.47 0 44.86l100.17 100.18zm388.47-116.8c18.76-18.76 18.75-49.17 0-67.93l-45.25-45.25c-18.76-18.76-49.18-18.76-67.95 0l-46.02 46.01 113.2 113.2 46.02-46.03zM316.08 82.71l-297 296.96L.32 487.11c-2.53 14.49 10.09 27.11 24.59 24.56l107.45-18.84L429.28 195.9 316.08 82.71zm186.63 285.43l-33.64-33.64-61.68 61.68c-3.1 3.1-8.12 3.1-11.21 0l-11.21-11.21c-3.09-3.1-3.09-8.12 0-11.21l61.68-61.68-44.14-44.14L267.93 402.5l100.21 100.2c12.39 12.39 32.47 12.39 44.86 0l89.71-89.7c12.39-12.39 12.39-32.47 0-44.86z"]},Qu={prefix:"fas",iconName:"people-arrows",icon:[576,512,[],"e068","M96,128A64,64,0,1,0,32,64,64,64,0,0,0,96,128Zm0,176.08a44.11,44.11,0,0,1,13.64-32L181.77,204c1.65-1.55,3.77-2.31,5.61-3.57A63.91,63.91,0,0,0,128,160H64A64,64,0,0,0,0,224v96a32,32,0,0,0,32,32V480a32,32,0,0,0,32,32h64a32,32,0,0,0,32-32V383.61l-50.36-47.53A44.08,44.08,0,0,1,96,304.08ZM480,128a64,64,0,1,0-64-64A64,64,0,0,0,480,128Zm32,32H448a63.91,63.91,0,0,0-59.38,40.42c1.84,1.27,4,2,5.62,3.59l72.12,68.06a44.37,44.37,0,0,1,0,64L416,383.62V480a32,32,0,0,0,32,32h64a32,32,0,0,0,32-32V352a32,32,0,0,0,32-32V224A64,64,0,0,0,512,160ZM444.4,295.34l-72.12-68.06A12,12,0,0,0,352,236v36H224V236a12,12,0,0,0-20.28-8.73L131.6,295.34a12.4,12.4,0,0,0,0,17.47l72.12,68.07A12,12,0,0,0,224,372.14V336H352v36.14a12,12,0,0,0,20.28,8.74l72.12-68.07A12.4,12.4,0,0,0,444.4,295.34Z"]},Xu={prefix:"fas",iconName:"people-carry",icon:[640,512,[],"f4ce","M128 96c26.5 0 48-21.5 48-48S154.5 0 128 0 80 21.5 80 48s21.5 48 48 48zm384 0c26.5 0 48-21.5 48-48S538.5 0 512 0s-48 21.5-48 48 21.5 48 48 48zm125.7 372.1l-44-110-41.1 46.4-2 18.2 27.7 69.2c5 12.5 17 20.1 29.7 20.1 4 0 8-.7 11.9-2.3 16.4-6.6 24.4-25.2 17.8-41.6zm-34.2-209.8L585 178.1c-4.6-20-18.6-36.8-37.5-44.9-18.5-8-39-6.7-56.1 3.3-22.7 13.4-39.7 34.5-48.1 59.4L432 229.8 416 240v-96c0-8.8-7.2-16-16-16H240c-8.8 0-16 7.2-16 16v96l-16.1-10.2-11.3-33.9c-8.3-25-25.4-46-48.1-59.4-17.2-10-37.6-11.3-56.1-3.3-18.9 8.1-32.9 24.9-37.5 44.9l-18.4 80.2c-4.6 20 .7 41.2 14.4 56.7l67.2 75.9 10.1 92.6C130 499.8 143.8 512 160 512c1.2 0 2.3-.1 3.5-.2 17.6-1.9 30.2-17.7 28.3-35.3l-10.1-92.8c-1.5-13-6.9-25.1-15.6-35l-43.3-49 17.6-70.3 6.8 20.4c4.1 12.5 11.9 23.4 24.5 32.6l51.1 32.5c4.6 2.9 12.1 4.6 17.2 5h160c5.1-.4 12.6-2.1 17.2-5l51.1-32.5c12.6-9.2 20.4-20 24.5-32.6l6.8-20.4 17.6 70.3-43.3 49c-8.7 9.9-14.1 22-15.6 35l-10.1 92.8c-1.9 17.6 10.8 33.4 28.3 35.3 1.2.1 2.3.2 3.5.2 16.1 0 30-12.1 31.8-28.5l10.1-92.6 67.2-75.9c13.6-15.5 19-36.7 14.4-56.7zM46.3 358.1l-44 110c-6.6 16.4 1.4 35 17.8 41.6 16.8 6.6 35.1-1.7 41.6-17.8l27.7-69.2-2-18.2-41.1-46.4z"]},Zu={prefix:"fas",iconName:"pepper-hot",icon:[512,512,[],"f816","M330.67 263.12V173.4l-52.75-24.22C219.44 218.76 197.58 400 56 400a56 56 0 0 0 0 112c212.64 0 370.65-122.87 419.18-210.34l-37.05-38.54zm131.09-128.37C493.92 74.91 477.18 26.48 458.62 3a8 8 0 0 0-11.93-.59l-22.9 23a8.06 8.06 0 0 0-.89 10.23c6.86 10.36 17.05 35.1-1.4 72.32A142.85 142.85 0 0 0 364.34 96c-28 0-54 8.54-76.34 22.59l74.67 34.29v78.24h89.09L506.44 288c3.26-12.62 5.56-25.63 5.56-39.31a154 154 0 0 0-50.24-113.94z"]},Ju={prefix:"fas",iconName:"percent",icon:[448,512,[],"f295","M112 224c61.9 0 112-50.1 112-112S173.9 0 112 0 0 50.1 0 112s50.1 112 112 112zm0-160c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48 21.5-48 48-48zm224 224c-61.9 0-112 50.1-112 112s50.1 112 112 112 112-50.1 112-112-50.1-112-112-112zm0 160c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zM392.3.2l31.6-.1c19.4-.1 30.9 21.8 19.7 37.8L77.4 501.6a23.95 23.95 0 0 1-19.6 10.2l-33.4.1c-19.5 0-30.9-21.9-19.7-37.8l368-463.7C377.2 4 384.5.2 392.3.2z"]},eh={prefix:"fas",iconName:"percentage",icon:[384,512,[],"f541","M109.25 173.25c24.99-24.99 24.99-65.52 0-90.51-24.99-24.99-65.52-24.99-90.51 0-24.99 24.99-24.99 65.52 0 90.51 25 25 65.52 25 90.51 0zm256 165.49c-24.99-24.99-65.52-24.99-90.51 0-24.99 24.99-24.99 65.52 0 90.51 24.99 24.99 65.52 24.99 90.51 0 25-24.99 25-65.51 0-90.51zm-1.94-231.43l-22.62-22.62c-12.5-12.5-32.76-12.5-45.25 0L20.69 359.44c-12.5 12.5-12.5 32.76 0 45.25l22.62 22.62c12.5 12.5 32.76 12.5 45.25 0l274.75-274.75c12.5-12.49 12.5-32.75 0-45.25z"]},th={prefix:"fas",iconName:"person-booth",icon:[576,512,[],"f756","M192 496c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320h-64v176zm32-272h-50.9l-45.2-45.3C115.8 166.6 99.7 160 82.7 160H64c-17.1 0-33.2 6.7-45.3 18.8C6.7 190.9 0 207 0 224.1L.2 320 0 480c0 17.7 14.3 32 31.9 32 17.6 0 32-14.3 32-32l.1-100.7c.9.5 1.6 1.3 2.5 1.7l29.1 43v56c0 17.7 14.3 32 32 32s32-14.3 32-32v-56.5c0-9.9-2.3-19.8-6.7-28.6l-41.2-61.3V253l20.9 20.9c9.1 9.1 21.1 14.1 33.9 14.1H224c17.7 0 32-14.3 32-32s-14.3-32-32-32zM64 128c26.5 0 48-21.5 48-48S90.5 32 64 32 16 53.5 16 80s21.5 48 48 48zm224-96l31.5 223.1-30.9 154.6c-4.3 21.6 13 38.3 31.4 38.3 15.2 0 28-9.1 32.3-30.4.9 16.9 14.6 30.4 31.7 30.4 17.7 0 32-14.3 32-32 0 17.7 14.3 32 32 32s32-14.3 32-32V0H288v32zm-96 0v160h64V0h-32c-17.7 0-32 14.3-32 32zM544 0h-32v496c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V32c0-17.7-14.3-32-32-32z"]},ih={prefix:"fas",iconName:"phone",icon:[512,512,[],"f095","M493.4 24.6l-104-24c-11.3-2.6-22.9 3.3-27.5 13.9l-48 112c-4.2 9.8-1.4 21.3 6.9 28l60.6 49.6c-36 76.7-98.9 140.5-177.2 177.2l-49.6-60.6c-6.8-8.3-18.2-11.1-28-6.9l-112 48C3.9 366.5-2 378.1.6 389.4l24 104C27.1 504.2 36.7 512 48 512c256.1 0 464-207.5 464-464 0-11.2-7.7-20.9-18.6-23.4z"]},rh={prefix:"fas",iconName:"phone-alt",icon:[512,512,[],"f879","M497.39 361.8l-112-48a24 24 0 0 0-28 6.9l-49.6 60.6A370.66 370.66 0 0 1 130.6 204.11l60.6-49.6a23.94 23.94 0 0 0 6.9-28l-48-112A24.16 24.16 0 0 0 122.6.61l-104 24A24 24 0 0 0 0 48c0 256.5 207.9 464 464 464a24 24 0 0 0 23.4-18.6l24-104a24.29 24.29 0 0 0-14.01-27.6z"]},nh={prefix:"fas",iconName:"phone-slash",icon:[640,512,[],"f3dd","M268.2 381.4l-49.6-60.6c-6.8-8.3-18.2-11.1-28-6.9l-112 48c-10.7 4.6-16.5 16.1-13.9 27.5l24 104c2.5 10.8 12.1 18.6 23.4 18.6 100.7 0 193.7-32.4 269.7-86.9l-80-61.8c-10.9 6.5-22.1 12.7-33.6 18.1zm365.6 76.7L475.1 335.5C537.9 256.4 576 156.9 576 48c0-11.2-7.7-20.9-18.6-23.4l-104-24c-11.3-2.6-22.9 3.3-27.5 13.9l-48 112c-4.2 9.8-1.4 21.3 6.9 28l60.6 49.6c-12.2 26.1-27.9 50.3-46 72.8L45.5 3.4C38.5-2 28.5-.8 23 6.2L3.4 31.4c-5.4 7-4.2 17 2.8 22.4l588.4 454.7c7 5.4 17 4.2 22.5-2.8l19.6-25.3c5.4-6.8 4.1-16.9-2.9-22.3z"]},sh={prefix:"fas",iconName:"phone-square",icon:[448,512,[],"f098","M400 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48V80c0-26.51-21.49-48-48-48zM94 416c-7.033 0-13.057-4.873-14.616-11.627l-14.998-65a15 15 0 0 1 8.707-17.16l69.998-29.999a15 15 0 0 1 17.518 4.289l30.997 37.885c48.944-22.963 88.297-62.858 110.781-110.78l-37.886-30.997a15.001 15.001 0 0 1-4.289-17.518l30-69.998a15 15 0 0 1 17.16-8.707l65 14.998A14.997 14.997 0 0 1 384 126c0 160.292-129.945 290-290 290z"]},oh={prefix:"fas",iconName:"phone-square-alt",icon:[448,512,[],"f87b","M400 32H48A48 48 0 0 0 0 80v352a48 48 0 0 0 48 48h352a48 48 0 0 0 48-48V80a48 48 0 0 0-48-48zm-16.39 307.37l-15 65A15 15 0 0 1 354 416C194 416 64 286.29 64 126a15.7 15.7 0 0 1 11.63-14.61l65-15A18.23 18.23 0 0 1 144 96a16.27 16.27 0 0 1 13.79 9.09l30 70A17.9 17.9 0 0 1 189 181a17 17 0 0 1-5.5 11.61l-37.89 31a231.91 231.91 0 0 0 110.78 110.78l31-37.89A17 17 0 0 1 299 291a17.85 17.85 0 0 1 5.91 1.21l70 30A16.25 16.25 0 0 1 384 336a17.41 17.41 0 0 1-.39 3.37z"]},ah={prefix:"fas",iconName:"phone-volume",icon:[384,512,[],"f2a0","M97.333 506.966c-129.874-129.874-129.681-340.252 0-469.933 5.698-5.698 14.527-6.632 21.263-2.422l64.817 40.513a17.187 17.187 0 0 1 6.849 20.958l-32.408 81.021a17.188 17.188 0 0 1-17.669 10.719l-55.81-5.58c-21.051 58.261-20.612 122.471 0 179.515l55.811-5.581a17.188 17.188 0 0 1 17.669 10.719l32.408 81.022a17.188 17.188 0 0 1-6.849 20.958l-64.817 40.513a17.19 17.19 0 0 1-21.264-2.422zM247.126 95.473c11.832 20.047 11.832 45.008 0 65.055-3.95 6.693-13.108 7.959-18.718 2.581l-5.975-5.726c-3.911-3.748-4.793-9.622-2.261-14.41a32.063 32.063 0 0 0 0-29.945c-2.533-4.788-1.65-10.662 2.261-14.41l5.975-5.726c5.61-5.378 14.768-4.112 18.718 2.581zm91.787-91.187c60.14 71.604 60.092 175.882 0 247.428-4.474 5.327-12.53 5.746-17.552.933l-5.798-5.557c-4.56-4.371-4.977-11.529-.93-16.379 49.687-59.538 49.646-145.933 0-205.422-4.047-4.85-3.631-12.008.93-16.379l5.798-5.557c5.022-4.813 13.078-4.394 17.552.933zm-45.972 44.941c36.05 46.322 36.108 111.149 0 157.546-4.39 5.641-12.697 6.251-17.856 1.304l-5.818-5.579c-4.4-4.219-4.998-11.095-1.285-15.931 26.536-34.564 26.534-82.572 0-117.134-3.713-4.836-3.115-11.711 1.285-15.931l5.818-5.579c5.159-4.947 13.466-4.337 17.856 1.304z"]},lh={prefix:"fas",iconName:"photo-video",icon:[640,512,[],"f87c","M608 0H160a32 32 0 0 0-32 32v96h160V64h192v320h128a32 32 0 0 0 32-32V32a32 32 0 0 0-32-32zM232 103a9 9 0 0 1-9 9h-30a9 9 0 0 1-9-9V73a9 9 0 0 1 9-9h30a9 9 0 0 1 9 9zm352 208a9 9 0 0 1-9 9h-30a9 9 0 0 1-9-9v-30a9 9 0 0 1 9-9h30a9 9 0 0 1 9 9zm0-104a9 9 0 0 1-9 9h-30a9 9 0 0 1-9-9v-30a9 9 0 0 1 9-9h30a9 9 0 0 1 9 9zm0-104a9 9 0 0 1-9 9h-30a9 9 0 0 1-9-9V73a9 9 0 0 1 9-9h30a9 9 0 0 1 9 9zm-168 57H32a32 32 0 0 0-32 32v288a32 32 0 0 0 32 32h384a32 32 0 0 0 32-32V192a32 32 0 0 0-32-32zM96 224a32 32 0 1 1-32 32 32 32 0 0 1 32-32zm288 224H64v-32l64-64 32 32 128-128 96 96z"]},ch={prefix:"fas",iconName:"piggy-bank",icon:[576,512,[],"f4d3","M560 224h-29.5c-8.8-20-21.6-37.7-37.4-52.5L512 96h-32c-29.4 0-55.4 13.5-73 34.3-7.6-1.1-15.1-2.3-23-2.3H256c-77.4 0-141.9 55-156.8 128H56c-14.8 0-26.5-13.5-23.5-28.8C34.7 215.8 45.4 208 57 208h1c3.3 0 6-2.7 6-6v-20c0-3.3-2.7-6-6-6-28.5 0-53.9 20.4-57.5 48.6C-3.9 258.8 22.7 288 56 288h40c0 52.2 25.4 98.1 64 127.3V496c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16v-48h128v48c0 8.8 7.2 16 16 16h64c8.8 0 16-7.2 16-16v-80.7c11.8-8.9 22.3-19.4 31.3-31.3H560c8.8 0 16-7.2 16-16V240c0-8.8-7.2-16-16-16zm-128 64c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zM256 96h128c5.4 0 10.7.4 15.9.8 0-.3.1-.5.1-.8 0-53-43-96-96-96s-96 43-96 96c0 2.1.5 4.1.6 6.2 15.2-3.9 31-6.2 47.4-6.2z"]},uh={prefix:"fas",iconName:"pills",icon:[576,512,[],"f484","M112 32C50.1 32 0 82.1 0 144v224c0 61.9 50.1 112 112 112s112-50.1 112-112V144c0-61.9-50.1-112-112-112zm48 224H64V144c0-26.5 21.5-48 48-48s48 21.5 48 48v112zm139.7-29.7c-3.5-3.5-9.4-3.1-12.3.8-45.3 62.5-40.4 150.1 15.9 206.4 56.3 56.3 143.9 61.2 206.4 15.9 4-2.9 4.3-8.8.8-12.3L299.7 226.3zm229.8-19c-56.3-56.3-143.9-61.2-206.4-15.9-4 2.9-4.3 8.8-.8 12.3l210.8 210.8c3.5 3.5 9.4 3.1 12.3-.8 45.3-62.6 40.5-150.1-15.9-206.4z"]},hh={prefix:"fas",iconName:"pizza-slice",icon:[512,512,[],"f818","M158.87.15c-16.16-1.52-31.2 8.42-35.33 24.12l-14.81 56.27c187.62 5.49 314.54 130.61 322.48 317l56.94-15.78c15.72-4.36 25.49-19.68 23.62-35.9C490.89 165.08 340.78 17.32 158.87.15zm-58.47 112L.55 491.64a16.21 16.21 0 0 0 20 19.75l379-105.1c-4.27-174.89-123.08-292.14-299.15-294.1zM128 416a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm48-152a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm104 104a32 32 0 1 1 32-32 32 32 0 0 1-32 32z"]},dh={prefix:"fas",iconName:"place-of-worship",icon:[640,512,[],"f67f","M620.61 366.55L512 320v192h112c8.84 0 16-7.16 16-16V395.96a32 32 0 0 0-19.39-29.41zM0 395.96V496c0 8.84 7.16 16 16 16h112V320L19.39 366.55A32 32 0 0 0 0 395.96zm464.46-149.28L416 217.6V102.63c0-8.49-3.37-16.62-9.38-22.63L331.31 4.69c-6.25-6.25-16.38-6.25-22.62 0L233.38 80c-6 6-9.38 14.14-9.38 22.63V217.6l-48.46 29.08A31.997 31.997 0 0 0 160 274.12V512h96v-96c0-35.35 28.66-64 64-64s64 28.65 64 64v96h96V274.12c0-11.24-5.9-21.66-15.54-27.44z"]},ph={prefix:"fas",iconName:"plane",icon:[576,512,[],"f072","M480 192H365.71L260.61 8.06A16.014 16.014 0 0 0 246.71 0h-65.5c-10.63 0-18.3 10.17-15.38 20.39L214.86 192H112l-43.2-57.6c-3.02-4.03-7.77-6.4-12.8-6.4H16.01C5.6 128-2.04 137.78.49 147.88L32 256 .49 364.12C-2.04 374.22 5.6 384 16.01 384H56c5.04 0 9.78-2.37 12.8-6.4L112 320h102.86l-49.03 171.6c-2.92 10.22 4.75 20.4 15.38 20.4h65.5c5.74 0 11.04-3.08 13.89-8.06L365.71 320H480c35.35 0 96-28.65 96-64s-60.65-64-96-64z"]},gh={prefix:"fas",iconName:"plane-arrival",icon:[640,512,[],"f5af","M624 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h608c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM44.81 205.66l88.74 80a62.607 62.607 0 0 0 25.47 13.93l287.6 78.35c26.48 7.21 54.56 8.72 81 1.36 29.67-8.27 43.44-21.21 47.25-35.71 3.83-14.5-1.73-32.71-23.37-54.96-19.28-19.82-44.35-32.79-70.83-40l-97.51-26.56L282.8 30.22c-1.51-5.81-5.95-10.35-11.66-11.91L206.05.58c-10.56-2.88-20.9 5.32-20.71 16.44l47.92 164.21-102.2-27.84-27.59-67.88c-1.93-4.89-6.01-8.57-11.02-9.93L52.72 64.75c-10.34-2.82-20.53 5-20.72 15.88l.23 101.78c.19 8.91 6.03 17.34 12.58 23.25z"]},fh={prefix:"fas",iconName:"plane-departure",icon:[640,512,[],"f5b0","M624 448H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h608c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM80.55 341.27c6.28 6.84 15.1 10.72 24.33 10.71l130.54-.18a65.62 65.62 0 0 0 29.64-7.12l290.96-147.65c26.74-13.57 50.71-32.94 67.02-58.31 18.31-28.48 20.3-49.09 13.07-63.65-7.21-14.57-24.74-25.27-58.25-27.45-29.85-1.94-59.54 5.92-86.28 19.48l-98.51 49.99-218.7-82.06a17.799 17.799 0 0 0-18-1.11L90.62 67.29c-10.67 5.41-13.25 19.65-5.17 28.53l156.22 98.1-103.21 52.38-72.35-36.47a17.804 17.804 0 0 0-16.07.02L9.91 230.22c-10.44 5.3-13.19 19.12-5.57 28.08l76.21 82.97z"]},mh={prefix:"fas",iconName:"plane-slash",icon:[640,512,[],"e069","M32.48,147.88,64,256,32.48,364.13A16,16,0,0,0,48,384H88a16,16,0,0,0,12.8-6.41L144,320H246.85l-49,171.59A16,16,0,0,0,213.2,512h65.5a16,16,0,0,0,13.89-8.06l66.6-116.54L34.35,136.34A15.47,15.47,0,0,0,32.48,147.88ZM633.82,458.09,455.14,320H512c35.34,0,96-28.66,96-64s-60.66-64-96-64H397.7L292.61,8.06C290.06,3.61,283.84,0,278.71,0H213.2a16,16,0,0,0-15.38,20.39l36.94,129.29L45.46,3.38A16,16,0,0,0,23,6.19L3.37,31.45A16,16,0,0,0,6.18,53.91L594.54,508.63A16,16,0,0,0,617,505.81l19.64-25.26A16,16,0,0,0,633.82,458.09Z"]},vh={prefix:"fas",iconName:"play",icon:[448,512,[],"f04b","M424.4 214.7L72.4 6.6C43.8-10.3 0 6.1 0 47.9V464c0 37.5 40.7 60.1 72.4 41.3l352-208c31.4-18.5 31.5-64.1 0-82.6z"]},Ch={prefix:"fas",iconName:"play-circle",icon:[512,512,[],"f144","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm115.7 272l-176 101c-15.8 8.8-35.7-2.5-35.7-21V152c0-18.4 19.8-29.8 35.7-21l176 107c16.4 9.2 16.4 32.9 0 42z"]},yh={prefix:"fas",iconName:"plug",icon:[384,512,[],"f1e6","M320,32a32,32,0,0,0-64,0v96h64Zm48,128H16A16,16,0,0,0,0,176v32a16,16,0,0,0,16,16H32v32A160.07,160.07,0,0,0,160,412.8V512h64V412.8A160.07,160.07,0,0,0,352,256V224h16a16,16,0,0,0,16-16V176A16,16,0,0,0,368,160ZM128,32a32,32,0,0,0-64,0v96h64Z"]},wh={prefix:"fas",iconName:"plus",icon:[448,512,[],"f067","M416 208H272V64c0-17.67-14.33-32-32-32h-32c-17.67 0-32 14.33-32 32v144H32c-17.67 0-32 14.33-32 32v32c0 17.67 14.33 32 32 32h144v144c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32V304h144c17.67 0 32-14.33 32-32v-32c0-17.67-14.33-32-32-32z"]},Sh={prefix:"fas",iconName:"plus-circle",icon:[512,512,[],"f055","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm144 276c0 6.6-5.4 12-12 12h-92v92c0 6.6-5.4 12-12 12h-56c-6.6 0-12-5.4-12-12v-92h-92c-6.6 0-12-5.4-12-12v-56c0-6.6 5.4-12 12-12h92v-92c0-6.6 5.4-12 12-12h56c6.6 0 12 5.4 12 12v92h92c6.6 0 12 5.4 12 12v56z"]},bh={prefix:"fas",iconName:"plus-square",icon:[448,512,[],"f0fe","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zm-32 252c0 6.6-5.4 12-12 12h-92v92c0 6.6-5.4 12-12 12h-56c-6.6 0-12-5.4-12-12v-92H92c-6.6 0-12-5.4-12-12v-56c0-6.6 5.4-12 12-12h92v-92c0-6.6 5.4-12 12-12h56c6.6 0 12 5.4 12 12v92h92c6.6 0 12 5.4 12 12v56z"]},Eh={prefix:"fas",iconName:"podcast",icon:[448,512,[],"f2ce","M267.429 488.563C262.286 507.573 242.858 512 224 512c-18.857 0-38.286-4.427-43.428-23.437C172.927 460.134 160 388.898 160 355.75c0-35.156 31.142-43.75 64-43.75s64 8.594 64 43.75c0 32.949-12.871 104.179-20.571 132.813zM156.867 288.554c-18.693-18.308-29.958-44.173-28.784-72.599 2.054-49.724 42.395-89.956 92.124-91.881C274.862 121.958 320 165.807 320 220c0 26.827-11.064 51.116-28.866 68.552-2.675 2.62-2.401 6.986.628 9.187 9.312 6.765 16.46 15.343 21.234 25.363 1.741 3.654 6.497 4.66 9.449 1.891 28.826-27.043 46.553-65.783 45.511-108.565-1.855-76.206-63.595-138.208-139.793-140.369C146.869 73.753 80 139.215 80 220c0 41.361 17.532 78.7 45.55 104.989 2.953 2.771 7.711 1.77 9.453-1.887 4.774-10.021 11.923-18.598 21.235-25.363 3.029-2.2 3.304-6.566.629-9.185zM224 0C100.204 0 0 100.185 0 224c0 89.992 52.602 165.647 125.739 201.408 4.333 2.118 9.267-1.544 8.535-6.31-2.382-15.512-4.342-30.946-5.406-44.339-.146-1.836-1.149-3.486-2.678-4.512-47.4-31.806-78.564-86.016-78.187-147.347.592-96.237 79.29-174.648 175.529-174.899C320.793 47.747 400 126.797 400 224c0 61.932-32.158 116.49-80.65 147.867-.999 14.037-3.069 30.588-5.624 47.23-.732 4.767 4.203 8.429 8.535 6.31C395.227 389.727 448 314.187 448 224 448 100.205 347.815 0 224 0zm0 160c-35.346 0-64 28.654-64 64s28.654 64 64 64 64-28.654 64-64-28.654-64-64-64z"]},Ah={prefix:"fas",iconName:"poll",icon:[448,512,[],"f681","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zM160 368c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16V240c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v128zm96 0c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16V144c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v224zm96 0c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16v-64c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v64z"]},Th={prefix:"fas",iconName:"poll-h",icon:[448,512,[],"f682","M448 432V80c0-26.5-21.5-48-48-48H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48zM112 192c-8.84 0-16-7.16-16-16v-32c0-8.84 7.16-16 16-16h128c8.84 0 16 7.16 16 16v32c0 8.84-7.16 16-16 16H112zm0 96c-8.84 0-16-7.16-16-16v-32c0-8.84 7.16-16 16-16h224c8.84 0 16 7.16 16 16v32c0 8.84-7.16 16-16 16H112zm0 96c-8.84 0-16-7.16-16-16v-32c0-8.84 7.16-16 16-16h64c8.84 0 16 7.16 16 16v32c0 8.84-7.16 16-16 16h-64z"]},Mh={prefix:"fas",iconName:"poo",icon:[512,512,[],"f2fe","M451.4 369.1C468.7 356 480 335.4 480 312c0-39.8-32.2-72-72-72h-14.1c13.4-11.7 22.1-28.8 22.1-48 0-35.3-28.7-64-64-64h-5.9c3.6-10.1 5.9-20.7 5.9-32 0-53-43-96-96-96-5.2 0-10.2.7-15.1 1.5C250.3 14.6 256 30.6 256 48c0 44.2-35.8 80-80 80h-16c-35.3 0-64 28.7-64 64 0 19.2 8.7 36.3 22.1 48H104c-39.8 0-72 32.2-72 72 0 23.4 11.3 44 28.6 57.1C26.3 374.6 0 404.1 0 440c0 39.8 32.2 72 72 72h368c39.8 0 72-32.2 72-72 0-35.9-26.3-65.4-60.6-70.9zM192 256c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm159.5 139C341 422.9 293 448 256 448s-85-25.1-95.5-53c-2-5.3 2-11 7.8-11h175.4c5.8 0 9.8 5.7 7.8 11zM320 320c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Rh={prefix:"fas",iconName:"poo-storm",icon:[448,512,[],"f75a","M308 336h-57.7l17.3-64.9c2-7.6-3.7-15.1-11.6-15.1h-68c-6 0-11.1 4.5-11.9 10.4l-16 120c-1 7.2 4.6 13.6 11.9 13.6h59.3l-23 97.2c-1.8 7.6 4 14.8 11.7 14.8 4.2 0 8.2-2.2 10.4-6l88-152c4.6-8-1.2-18-10.4-18zm66.4-111.3c5.9-9.6 9.6-20.6 9.6-32.7 0-35.3-28.7-64-64-64h-5.9c3.6-10.1 5.9-20.7 5.9-32 0-53-43-96-96-96-5.2 0-10.2.7-15.1 1.5C218.3 14.6 224 30.6 224 48c0 44.2-35.8 80-80 80h-16c-35.3 0-64 28.7-64 64 0 12.1 3.7 23.1 9.6 32.7C32.6 228 0 262.2 0 304c0 44 36 80 80 80h48.3c.1-.6 0-1.2 0-1.8l16-120c3-21.8 21.7-38.2 43.7-38.2h68c13.8 0 26.5 6.3 34.9 17.2s11.2 24.8 7.6 38.1l-6.6 24.7h16c15.7 0 30.3 8.4 38.1 22 7.8 13.6 7.8 30.5 0 44l-8.1 14h30c44 0 80-36 80-80 .1-41.8-32.5-76-73.5-79.3z"]},_h={prefix:"fas",iconName:"poop",icon:[512,512,[],"f619","M451.36 369.14C468.66 355.99 480 335.41 480 312c0-39.77-32.24-72-72-72h-14.07c13.42-11.73 22.07-28.78 22.07-48 0-35.35-28.65-64-64-64h-5.88c3.57-10.05 5.88-20.72 5.88-32 0-53.02-42.98-96-96-96-5.17 0-10.15.74-15.11 1.52C250.31 14.64 256 30.62 256 48c0 44.18-35.82 80-80 80h-16c-35.35 0-64 28.65-64 64 0 19.22 8.65 36.27 22.07 48H104c-39.76 0-72 32.23-72 72 0 23.41 11.34 43.99 28.64 57.14C26.31 374.62 0 404.12 0 440c0 39.76 32.24 72 72 72h368c39.76 0 72-32.24 72-72 0-35.88-26.31-65.38-60.64-70.86z"]},Ph={prefix:"fas",iconName:"portrait",icon:[384,512,[],"f3e0","M336 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM192 128c35.3 0 64 28.7 64 64s-28.7 64-64 64-64-28.7-64-64 28.7-64 64-64zm112 236.8c0 10.6-10 19.2-22.4 19.2H102.4C90 384 80 375.4 80 364.8v-19.2c0-31.8 30.1-57.6 67.2-57.6h5c12.3 5.1 25.7 8 39.8 8s27.6-2.9 39.8-8h5c37.1 0 67.2 25.8 67.2 57.6v19.2z"]},xh={prefix:"fas",iconName:"pound-sign",icon:[320,512,[],"f154","M308 352h-45.495c-6.627 0-12 5.373-12 12v50.848H128V288h84c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-84v-63.556c0-32.266 24.562-57.086 61.792-57.086 23.658 0 45.878 11.505 57.652 18.849 5.151 3.213 11.888 2.051 15.688-2.685l28.493-35.513c4.233-5.276 3.279-13.005-2.119-17.081C273.124 54.56 236.576 32 187.931 32 106.026 32 48 84.742 48 157.961V224H20c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h28v128H12c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h296c6.627 0 12-5.373 12-12V364c0-6.627-5.373-12-12-12z"]},Dh={prefix:"fas",iconName:"power-off",icon:[512,512,[],"f011","M400 54.1c63 45 104 118.6 104 201.9 0 136.8-110.8 247.7-247.5 248C120 504.3 8.2 393 8 256.4 7.9 173.1 48.9 99.3 111.8 54.2c11.7-8.3 28-4.8 35 7.7L162.6 90c5.9 10.5 3.1 23.8-6.6 31-41.5 30.8-68 79.6-68 134.9-.1 92.3 74.5 168.1 168 168.1 91.6 0 168.6-74.2 168-169.1-.3-51.8-24.7-101.8-68.1-134-9.7-7.2-12.4-20.5-6.5-30.9l15.8-28.1c7-12.4 23.2-16.1 34.8-7.8zM296 264V24c0-13.3-10.7-24-24-24h-32c-13.3 0-24 10.7-24 24v240c0 13.3 10.7 24 24 24h32c13.3 0 24-10.7 24-24z"]},Ih={prefix:"fas",iconName:"pray",icon:[384,512,[],"f683","M256 128c35.35 0 64-28.65 64-64S291.35 0 256 0s-64 28.65-64 64 28.65 64 64 64zm-30.63 169.75c14.06 16.72 39 19.09 55.97 5.22l88-72.02c17.09-13.98 19.59-39.19 5.62-56.28-13.97-17.11-39.19-19.59-56.31-5.62l-57.44 47-38.91-46.31c-15.44-18.39-39.22-27.92-64-25.33-24.19 2.48-45.25 16.27-56.37 36.92l-49.37 92.03c-23.4 43.64-8.69 96.37 34.19 123.75L131.56 432H40c-22.09 0-40 17.91-40 40s17.91 40 40 40h208c34.08 0 53.77-42.79 28.28-68.28L166.42 333.86l34.8-64.87 24.15 28.76z"]},Lh={prefix:"fas",iconName:"praying-hands",icon:[640,512,[],"f684","M272 191.91c-17.6 0-32 14.4-32 32v80c0 8.84-7.16 16-16 16s-16-7.16-16-16v-76.55c0-17.39 4.72-34.47 13.69-49.39l77.75-129.59c9.09-15.16 4.19-34.81-10.97-43.91-14.45-8.67-32.72-4.3-42.3 9.21-.2.23-.62.21-.79.48l-117.26 175.9C117.56 205.9 112 224.31 112 243.29v80.23l-90.12 30.04A31.974 31.974 0 0 0 0 383.91v96c0 10.82 8.52 32 32 32 2.69 0 5.41-.34 8.06-1.03l179.19-46.62C269.16 449.99 304 403.8 304 351.91v-128c0-17.6-14.4-32-32-32zm346.12 161.73L528 323.6v-80.23c0-18.98-5.56-37.39-16.12-53.23L394.62 14.25c-.18-.27-.59-.24-.79-.48-9.58-13.51-27.85-17.88-42.3-9.21-15.16 9.09-20.06 28.75-10.97 43.91l77.75 129.59c8.97 14.92 13.69 32 13.69 49.39V304c0 8.84-7.16 16-16 16s-16-7.16-16-16v-80c0-17.6-14.4-32-32-32s-32 14.4-32 32v128c0 51.89 34.84 98.08 84.75 112.34l179.19 46.62c2.66.69 5.38 1.03 8.06 1.03 23.48 0 32-21.18 32-32v-96c0-13.77-8.81-25.99-21.88-30.35z"]},Nh={prefix:"fas",iconName:"prescription",icon:[384,512,[],"f5b1","M301.26 352l78.06-78.06c6.25-6.25 6.25-16.38 0-22.63l-22.63-22.63c-6.25-6.25-16.38-6.25-22.63 0L256 306.74l-83.96-83.96C219.31 216.8 256 176.89 256 128c0-53.02-42.98-96-96-96H16C7.16 32 0 39.16 0 48v256c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-80h18.75l128 128-78.06 78.06c-6.25 6.25-6.25 16.38 0 22.63l22.63 22.63c6.25 6.25 16.38 6.25 22.63 0L256 397.25l78.06 78.06c6.25 6.25 16.38 6.25 22.63 0l22.63-22.63c6.25-6.25 6.25-16.38 0-22.63L301.26 352zM64 96h96c17.64 0 32 14.36 32 32s-14.36 32-32 32H64V96z"]},Oh={prefix:"fas",iconName:"prescription-bottle",icon:[384,512,[],"f485","M32 192h120c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H32v64h120c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H32v64h120c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H32v64c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32V128H32v64zM360 0H24C10.8 0 0 10.8 0 24v48c0 13.2 10.8 24 24 24h336c13.2 0 24-10.8 24-24V24c0-13.2-10.8-24-24-24z"]},Fh={prefix:"fas",iconName:"prescription-bottle-alt",icon:[384,512,[],"f486","M360 0H24C10.8 0 0 10.8 0 24v48c0 13.2 10.8 24 24 24h336c13.2 0 24-10.8 24-24V24c0-13.2-10.8-24-24-24zM32 480c0 17.6 14.4 32 32 32h256c17.6 0 32-14.4 32-32V128H32v352zm64-184c0-4.4 3.6-8 8-8h56v-56c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v56h56c4.4 0 8 3.6 8 8v48c0 4.4-3.6 8-8 8h-56v56c0 4.4-3.6 8-8 8h-48c-4.4 0-8-3.6-8-8v-56h-56c-4.4 0-8-3.6-8-8v-48z"]},kh={prefix:"fas",iconName:"print",icon:[512,512,[],"f02f","M448 192V77.25c0-8.49-3.37-16.62-9.37-22.63L393.37 9.37c-6-6-14.14-9.37-22.63-9.37H96C78.33 0 64 14.33 64 32v160c-35.35 0-64 28.65-64 64v112c0 8.84 7.16 16 16 16h48v96c0 17.67 14.33 32 32 32h320c17.67 0 32-14.33 32-32v-96h48c8.84 0 16-7.16 16-16V256c0-35.35-28.65-64-64-64zm-64 256H128v-96h256v96zm0-224H128V64h192v48c0 8.84 7.16 16 16 16h48v96zm48 72c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24z"]},Gh={prefix:"fas",iconName:"procedures",icon:[640,512,[],"f487","M528 224H272c-8.8 0-16 7.2-16 16v144H64V144c0-8.8-7.2-16-16-16H16c-8.8 0-16 7.2-16 16v352c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-48h512v48c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V336c0-61.9-50.1-112-112-112zM136 96h126.1l27.6 55.2c5.9 11.8 22.7 11.8 28.6 0L368 51.8 390.1 96H512c8.8 0 16-7.2 16-16s-7.2-16-16-16H409.9L382.3 8.8C376.4-3 359.6-3 353.7 8.8L304 108.2l-19.9-39.8c-1.4-2.7-4.1-4.4-7.2-4.4H136c-4.4 0-8 3.6-8 8v16c0 4.4 3.6 8 8 8zm24 256c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64z"]},Vh={prefix:"fas",iconName:"project-diagram",icon:[640,512,[],"f542","M384 320H256c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h128c17.67 0 32-14.33 32-32V352c0-17.67-14.33-32-32-32zM192 32c0-17.67-14.33-32-32-32H32C14.33 0 0 14.33 0 32v128c0 17.67 14.33 32 32 32h95.72l73.16 128.04C211.98 300.98 232.4 288 256 288h.28L192 175.51V128h224V64H192V32zM608 0H480c-17.67 0-32 14.33-32 32v128c0 17.67 14.33 32 32 32h128c17.67 0 32-14.33 32-32V32c0-17.67-14.33-32-32-32z"]},Hh={prefix:"fas",iconName:"pump-medical",icon:[384,512,[],"e06a","M235.51,159.82H84.24A64,64,0,0,0,20.51,218L.14,442a64,64,0,0,0,63.74,69.8h192A64,64,0,0,0,319.61,442L299.24,218A64,64,0,0,0,235.51,159.82Zm4.37,173.33a13.35,13.35,0,0,1-13.34,13.34h-40v40a13.33,13.33,0,0,1-13.33,13.33H146.54a13.33,13.33,0,0,1-13.33-13.33v-40h-40a13.34,13.34,0,0,1-13.33-13.34V306.49a13.33,13.33,0,0,1,13.33-13.34h40v-40a13.33,13.33,0,0,1,13.33-13.33h26.67a13.33,13.33,0,0,1,13.33,13.33v40h40a13.34,13.34,0,0,1,13.34,13.34ZM379.19,93.88,335.87,50.56a64,64,0,0,0-45.24-18.74H223.88a32,32,0,0,0-32-32h-64a32,32,0,0,0-32,32v96h128v-32h66.75l43.31,43.31a16,16,0,0,0,22.63,0l22.62-22.62A16,16,0,0,0,379.19,93.88Z"]},Bh={prefix:"fas",iconName:"pump-soap",icon:[384,512,[],"e06b","M235.63,160H84.37a64,64,0,0,0-63.74,58.21L.27,442.21A64,64,0,0,0,64,512H256a64,64,0,0,0,63.74-69.79l-20.36-224A64,64,0,0,0,235.63,160ZM160,416c-33.12,0-60-26.33-60-58.75,0-25,35.7-75.47,52-97.27A10,10,0,0,1,168,260c16.33,21.8,52,72.27,52,97.27C220,389.67,193.12,416,160,416ZM379.31,94.06,336,50.74A64,64,0,0,0,290.75,32H224A32,32,0,0,0,192,0H128A32,32,0,0,0,96,32v96H224V96h66.75l43.31,43.31a16,16,0,0,0,22.63,0l22.62-22.62A16,16,0,0,0,379.31,94.06Z"]},zh={prefix:"fas",iconName:"puzzle-piece",icon:[576,512,[],"f12e","M519.442 288.651c-41.519 0-59.5 31.593-82.058 31.593C377.409 320.244 432 144 432 144s-196.288 80-196.288-3.297c0-35.827 36.288-46.25 36.288-85.985C272 19.216 243.885 0 210.539 0c-34.654 0-66.366 18.891-66.366 56.346 0 41.364 31.711 59.277 31.711 81.75C175.885 207.719 0 166.758 0 166.758v333.237s178.635 41.047 178.635-28.662c0-22.473-40-40.107-40-81.471 0-37.456 29.25-56.346 63.577-56.346 33.673 0 61.788 19.216 61.788 54.717 0 39.735-36.288 50.158-36.288 85.985 0 60.803 129.675 25.73 181.23 25.73 0 0-34.725-120.101 25.827-120.101 35.962 0 46.423 36.152 86.308 36.152C556.712 416 576 387.99 576 354.443c0-34.199-18.962-65.792-56.558-65.792z"]},Uh={prefix:"fas",iconName:"qrcode",icon:[448,512,[],"f029","M0 224h192V32H0v192zM64 96h64v64H64V96zm192-64v192h192V32H256zm128 128h-64V96h64v64zM0 480h192V288H0v192zm64-128h64v64H64v-64zm352-64h32v128h-96v-32h-32v96h-64V288h96v32h64v-32zm0 160h32v32h-32v-32zm-64 0h32v32h-32v-32z"]},Wh={prefix:"fas",iconName:"question",icon:[384,512,[],"f128","M202.021 0C122.202 0 70.503 32.703 29.914 91.026c-7.363 10.58-5.093 25.086 5.178 32.874l43.138 32.709c10.373 7.865 25.132 6.026 33.253-4.148 25.049-31.381 43.63-49.449 82.757-49.449 30.764 0 68.816 19.799 68.816 49.631 0 22.552-18.617 34.134-48.993 51.164-35.423 19.86-82.299 44.576-82.299 106.405V320c0 13.255 10.745 24 24 24h72.471c13.255 0 24-10.745 24-24v-5.773c0-42.86 125.268-44.645 125.268-160.627C377.504 66.256 286.902 0 202.021 0zM192 373.459c-38.196 0-69.271 31.075-69.271 69.271 0 38.195 31.075 69.27 69.271 69.27s69.271-31.075 69.271-69.271-31.075-69.27-69.271-69.27z"]},jh={prefix:"fas",iconName:"question-circle",icon:[512,512,[],"f059","M504 256c0 136.997-111.043 248-248 248S8 392.997 8 256C8 119.083 119.043 8 256 8s248 111.083 248 248zM262.655 90c-54.497 0-89.255 22.957-116.549 63.758-3.536 5.286-2.353 12.415 2.715 16.258l34.699 26.31c5.205 3.947 12.621 3.008 16.665-2.122 17.864-22.658 30.113-35.797 57.303-35.797 20.429 0 45.698 13.148 45.698 32.958 0 14.976-12.363 22.667-32.534 33.976C247.128 238.528 216 254.941 216 296v4c0 6.627 5.373 12 12 12h56c6.627 0 12-5.373 12-12v-1.333c0-28.462 83.186-29.647 83.186-106.667 0-58.002-60.165-102-116.531-102zM256 338c-25.365 0-46 20.635-46 46 0 25.364 20.635 46 46 46s46-20.636 46-46c0-25.365-20.635-46-46-46z"]},Kh={prefix:"fas",iconName:"quidditch",icon:[640,512,[],"f458","M256.5 216.8L343.2 326s-16.6 102.4-76.6 150.1C206.7 523.8 0 510.2 0 510.2s3.8-23.1 11-55.4l94.6-112.2c4-4.7-.9-11.6-6.6-9.5l-60.4 22.1c14.4-41.7 32.7-80 54.6-97.5 59.9-47.8 163.3-40.9 163.3-40.9zm238 135c-44 0-79.8 35.8-79.8 79.9 0 44.1 35.7 79.9 79.8 79.9 44.1 0 79.8-35.8 79.8-79.9 0-44.2-35.8-79.9-79.8-79.9zM636.5 31L616.7 6c-5.5-6.9-15.5-8-22.4-2.6L361.8 181.3l-34.1-43c-5.1-6.4-15.1-5.2-18.6 2.2l-25.3 54.6 86.7 109.2 58.8-12.4c8-1.7 11.4-11.2 6.3-17.6l-34.1-42.9L634 53.5c6.9-5.5 8-15.6 2.5-22.5z"]},$h={prefix:"fas",iconName:"quote-left",icon:[512,512,[],"f10d","M464 256h-80v-64c0-35.3 28.7-64 64-64h8c13.3 0 24-10.7 24-24V56c0-13.3-10.7-24-24-24h-8c-88.4 0-160 71.6-160 160v240c0 26.5 21.5 48 48 48h128c26.5 0 48-21.5 48-48V304c0-26.5-21.5-48-48-48zm-288 0H96v-64c0-35.3 28.7-64 64-64h8c13.3 0 24-10.7 24-24V56c0-13.3-10.7-24-24-24h-8C71.6 32 0 103.6 0 192v240c0 26.5 21.5 48 48 48h128c26.5 0 48-21.5 48-48V304c0-26.5-21.5-48-48-48z"]},qh={prefix:"fas",iconName:"quote-right",icon:[512,512,[],"f10e","M464 32H336c-26.5 0-48 21.5-48 48v128c0 26.5 21.5 48 48 48h80v64c0 35.3-28.7 64-64 64h-8c-13.3 0-24 10.7-24 24v48c0 13.3 10.7 24 24 24h8c88.4 0 160-71.6 160-160V80c0-26.5-21.5-48-48-48zm-288 0H48C21.5 32 0 53.5 0 80v128c0 26.5 21.5 48 48 48h80v64c0 35.3-28.7 64-64 64h-8c-13.3 0-24 10.7-24 24v48c0 13.3 10.7 24 24 24h8c88.4 0 160-71.6 160-160V80c0-26.5-21.5-48-48-48z"]},Yh={prefix:"fas",iconName:"quran",icon:[448,512,[],"f687","M448 358.4V25.6c0-16-9.6-25.6-25.6-25.6H96C41.6 0 0 41.6 0 96v320c0 54.4 41.6 96 96 96h326.4c12.8 0 25.6-9.6 25.6-25.6v-16c0-6.4-3.2-12.8-9.6-19.2-3.2-16-3.2-60.8 0-73.6 6.4-3.2 9.6-9.6 9.6-19.2zM301.08 145.82c.6-1.21 1.76-1.82 2.92-1.82s2.32.61 2.92 1.82l11.18 22.65 25 3.63c2.67.39 3.74 3.67 1.81 5.56l-18.09 17.63 4.27 24.89c.36 2.11-1.31 3.82-3.21 3.82-.5 0-1.02-.12-1.52-.38L304 211.87l-22.36 11.75c-.5.26-1.02.38-1.52.38-1.9 0-3.57-1.71-3.21-3.82l4.27-24.89-18.09-17.63c-1.94-1.89-.87-5.17 1.81-5.56l24.99-3.63 11.19-22.65zm-57.89-69.01c13.67 0 27.26 2.49 40.38 7.41a6.775 6.775 0 1 1-2.38 13.12c-.67 0-3.09-.21-4.13-.21-52.31 0-94.86 42.55-94.86 94.86 0 52.3 42.55 94.86 94.86 94.86 1.03 0 3.48-.21 4.13-.21 3.93 0 6.8 3.14 6.8 6.78 0 2.98-1.94 5.51-4.62 6.42-13.07 4.87-26.59 7.34-40.19 7.34C179.67 307.19 128 255.51 128 192c0-63.52 51.67-115.19 115.19-115.19zM380.8 448H96c-19.2 0-32-12.8-32-32s16-32 32-32h284.8v64z"]},Qh={prefix:"fas",iconName:"radiation",icon:[496,512,[],"f7b9","M328.2 255.8h151.6c9.1 0 16.8-7.7 16.2-16.8-5.1-75.8-44.4-142.2-102.5-184.2-7.4-5.3-17.9-2.9-22.7 4.8L290.4 188c22.6 14.3 37.8 39.2 37.8 67.8zm-37.8 67.7c-12.3 7.7-26.8 12.4-42.4 12.4-15.6 0-30-4.7-42.4-12.4L125.2 452c-4.8 7.7-2.4 18.1 5.6 22.4C165.7 493.2 205.6 504 248 504s82.3-10.8 117.2-29.6c8-4.3 10.4-14.8 5.6-22.4l-80.4-128.5zM248 303.8c26.5 0 48-21.5 48-48s-21.5-48-48-48-48 21.5-48 48 21.5 48 48 48zm-231.8-48h151.6c0-28.6 15.2-53.5 37.8-67.7L125.2 59.7c-4.8-7.7-15.3-10.2-22.7-4.8C44.4 96.9 5.1 163.3 0 239.1c-.6 9 7.1 16.7 16.2 16.7z"]},Xh={prefix:"fas",iconName:"radiation-alt",icon:[496,512,[],"f7ba","M312 256h79.1c9.2 0 16.9-7.7 16-16.8-4.6-43.6-27-81.8-59.5-107.8-7.6-6.1-18.8-4.5-24 3.8L281.9 202c18 11.2 30.1 31.2 30.1 54zm-97.8 54.1L172.4 377c-4.9 7.8-2.4 18.4 5.8 22.5 21.1 10.4 44.7 16.5 69.8 16.5s48.7-6.1 69.9-16.5c8.2-4.1 10.6-14.7 5.8-22.5l-41.8-66.9c-9.8 6.2-21.4 9.9-33.8 9.9s-24.1-3.7-33.9-9.9zM104.9 256H184c0-22.8 12.1-42.8 30.2-54.1l-41.7-66.8c-5.2-8.3-16.4-9.9-24-3.8-32.6 26-54.9 64.2-59.5 107.8-1.1 9.2 6.7 16.9 15.9 16.9zM248 504c137 0 248-111 248-248S385 8 248 8 0 119 0 256s111 248 248 248zm0-432c101.5 0 184 82.5 184 184s-82.5 184-184 184S64 357.5 64 256 146.5 72 248 72zm0 216c17.7 0 32-14.3 32-32s-14.3-32-32-32-32 14.3-32 32 14.3 32 32 32z"]},Zh={prefix:"fas",iconName:"rainbow",icon:[576,512,[],"f75b","M268.3 32.7C115.4 42.9 0 176.9 0 330.2V464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320C64 186.8 180.9 80.3 317.5 97.9 430.4 112.4 512 214 512 327.8V464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320c0-165.3-140-298.6-307.7-287.3zm-5.6 96.9C166 142 96 229.1 96 326.7V464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320c0-74.8 64.5-134.8 140.8-127.4 66.5 6.5 115.2 66.2 115.2 133.1V464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320c0-114.2-100.2-205.4-217.3-190.4zm6.2 96.3c-45.6 8.9-76.9 51.5-76.9 97.9V464c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320c0-17.6 14.3-32 32-32s32 14.4 32 32v144c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320c0-59.2-53.8-106-115.1-94.1z"]},Jh={prefix:"fas",iconName:"random",icon:[512,512,[],"f074","M504.971 359.029c9.373 9.373 9.373 24.569 0 33.941l-80 79.984c-15.01 15.01-40.971 4.49-40.971-16.971V416h-58.785a12.004 12.004 0 0 1-8.773-3.812l-70.556-75.596 53.333-57.143L352 336h32v-39.981c0-21.438 25.943-31.998 40.971-16.971l80 79.981zM12 176h84l52.781 56.551 53.333-57.143-70.556-75.596A11.999 11.999 0 0 0 122.785 96H12c-6.627 0-12 5.373-12 12v56c0 6.627 5.373 12 12 12zm372 0v39.984c0 21.46 25.961 31.98 40.971 16.971l80-79.984c9.373-9.373 9.373-24.569 0-33.941l-80-79.981C409.943 24.021 384 34.582 384 56.019V96h-58.785a12.004 12.004 0 0 0-8.773 3.812L96 336H12c-6.627 0-12 5.373-12 12v56c0 6.627 5.373 12 12 12h110.785c3.326 0 6.503-1.381 8.773-3.812L352 176h32z"]},ed={prefix:"fas",iconName:"receipt",icon:[384,512,[],"f543","M358.4 3.2L320 48 265.6 3.2a15.9 15.9 0 0 0-19.2 0L192 48 137.6 3.2a15.9 15.9 0 0 0-19.2 0L64 48 25.6 3.2C15-4.7 0 2.8 0 16v480c0 13.2 15 20.7 25.6 12.8L64 464l54.4 44.8a15.9 15.9 0 0 0 19.2 0L192 464l54.4 44.8a15.9 15.9 0 0 0 19.2 0L320 464l38.4 44.8c10.5 7.9 25.6.4 25.6-12.8V16c0-13.2-15-20.7-25.6-12.8zM320 360c0 4.4-3.6 8-8 8H72c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h240c4.4 0 8 3.6 8 8v16zm0-96c0 4.4-3.6 8-8 8H72c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h240c4.4 0 8 3.6 8 8v16zm0-96c0 4.4-3.6 8-8 8H72c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h240c4.4 0 8 3.6 8 8v16z"]},td={prefix:"fas",iconName:"record-vinyl",icon:[512,512,[],"f8d9","M256 152a104 104 0 1 0 104 104 104 104 0 0 0-104-104zm0 128a24 24 0 1 1 24-24 24 24 0 0 1-24 24zm0-272C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm0 376a128 128 0 1 1 128-128 128 128 0 0 1-128 128z"]},id={prefix:"fas",iconName:"recycle",icon:[512,512,[],"f1b8","M184.561 261.903c3.232 13.997-12.123 24.635-24.068 17.168l-40.736-25.455-50.867 81.402C55.606 356.273 70.96 384 96.012 384H148c6.627 0 12 5.373 12 12v40c0 6.627-5.373 12-12 12H96.115c-75.334 0-121.302-83.048-81.408-146.88l50.822-81.388-40.725-25.448c-12.081-7.547-8.966-25.961 4.879-29.158l110.237-25.45c8.611-1.988 17.201 3.381 19.189 11.99l25.452 110.237zm98.561-182.915l41.289 66.076-40.74 25.457c-12.051 7.528-9 25.953 4.879 29.158l110.237 25.45c8.672 1.999 17.215-3.438 19.189-11.99l25.45-110.237c3.197-13.844-11.99-24.719-24.068-17.168l-40.687 25.424-41.263-66.082c-37.521-60.033-125.209-60.171-162.816 0l-17.963 28.766c-3.51 5.62-1.8 13.021 3.82 16.533l33.919 21.195c5.62 3.512 13.024 1.803 16.536-3.817l17.961-28.743c12.712-20.341 41.973-19.676 54.257-.022zM497.288 301.12l-27.515-44.065c-3.511-5.623-10.916-7.334-16.538-3.821l-33.861 21.159c-5.62 3.512-7.33 10.915-3.818 16.536l27.564 44.112c13.257 21.211-2.057 48.96-27.136 48.96H320V336.02c0-14.213-17.242-21.383-27.313-11.313l-80 79.981c-6.249 6.248-6.249 16.379 0 22.627l80 79.989C302.689 517.308 320 510.3 320 495.989V448h95.88c75.274 0 121.335-82.997 81.408-146.88z"]},rd={prefix:"fas",iconName:"redo",icon:[512,512,[],"f01e","M500.33 0h-47.41a12 12 0 0 0-12 12.57l4 82.76A247.42 247.42 0 0 0 256 8C119.34 8 7.9 119.53 8 256.19 8.1 393.07 119.1 504 256 504a247.1 247.1 0 0 0 166.18-63.91 12 12 0 0 0 .48-17.43l-34-34a12 12 0 0 0-16.38-.55A176 176 0 1 1 402.1 157.8l-101.53-4.87a12 12 0 0 0-12.57 12v47.41a12 12 0 0 0 12 12h200.33a12 12 0 0 0 12-12V12a12 12 0 0 0-12-12z"]},nd={prefix:"fas",iconName:"redo-alt",icon:[512,512,[],"f2f9","M256.455 8c66.269.119 126.437 26.233 170.859 68.685l35.715-35.715C478.149 25.851 504 36.559 504 57.941V192c0 13.255-10.745 24-24 24H345.941c-21.382 0-32.09-25.851-16.971-40.971l41.75-41.75c-30.864-28.899-70.801-44.907-113.23-45.273-92.398-.798-170.283 73.977-169.484 169.442C88.764 348.009 162.184 424 256 424c41.127 0 79.997-14.678 110.629-41.556 4.743-4.161 11.906-3.908 16.368.553l39.662 39.662c4.872 4.872 4.631 12.815-.482 17.433C378.202 479.813 319.926 504 256 504 119.034 504 8.001 392.967 8 256.002 7.999 119.193 119.646 7.755 256.455 8z"]},sd={prefix:"fas",iconName:"registered",icon:[512,512,[],"f25d","M285.363 207.475c0 18.6-9.831 28.431-28.431 28.431h-29.876v-56.14h23.378c28.668 0 34.929 8.773 34.929 27.709zM504 256c0 136.967-111.033 248-248 248S8 392.967 8 256 119.033 8 256 8s248 111.033 248 248zM363.411 360.414c-46.729-84.825-43.299-78.636-44.702-80.98 23.432-15.172 37.945-42.979 37.945-74.486 0-54.244-31.5-89.252-105.498-89.252h-70.667c-13.255 0-24 10.745-24 24V372c0 13.255 10.745 24 24 24h22.567c13.255 0 24-10.745 24-24v-71.663h25.556l44.129 82.937a24.001 24.001 0 0 0 21.188 12.727h24.464c18.261-.001 29.829-19.591 21.018-35.587z"]},od={prefix:"fas",iconName:"remove-format",icon:[640,512,[],"f87d","M336 416h-11.17l9.26-27.77L267 336.4 240.49 416H208a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm297.82 42.1L377 259.59 426.17 112H544v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16H176a16 16 0 0 0-16 16v43.9L45.46 3.38A16 16 0 0 0 23 6.19L3.37 31.46a16 16 0 0 0 2.81 22.45l588.36 454.72a16 16 0 0 0 22.46-2.81l19.64-25.27a16 16 0 0 0-2.82-22.45zM309.91 207.76L224 141.36V112h117.83z"]},ad={prefix:"fas",iconName:"reply",icon:[512,512,[],"f3e5","M8.309 189.836L184.313 37.851C199.719 24.546 224 35.347 224 56.015v80.053c160.629 1.839 288 34.032 288 186.258 0 61.441-39.581 122.309-83.333 154.132-13.653 9.931-33.111-2.533-28.077-18.631 45.344-145.012-21.507-183.51-176.59-185.742V360c0 20.7-24.3 31.453-39.687 18.164l-176.004-152c-11.071-9.562-11.086-26.753 0-36.328z"]},ld={prefix:"fas",iconName:"reply-all",icon:[576,512,[],"f122","M136.309 189.836L312.313 37.851C327.72 24.546 352 35.348 352 56.015v82.763c129.182 10.231 224 52.212 224 183.548 0 61.441-39.582 122.309-83.333 154.132-13.653 9.931-33.111-2.533-28.077-18.631 38.512-123.162-3.922-169.482-112.59-182.015v84.175c0 20.701-24.3 31.453-39.687 18.164L136.309 226.164c-11.071-9.561-11.086-26.753 0-36.328zm-128 36.328L184.313 378.15C199.7 391.439 224 380.687 224 359.986v-15.818l-108.606-93.785A55.96 55.96 0 0 1 96 207.998a55.953 55.953 0 0 1 19.393-42.38L224 71.832V56.015c0-20.667-24.28-31.469-39.687-18.164L8.309 189.836c-11.086 9.575-11.071 26.767 0 36.328z"]},cd={prefix:"fas",iconName:"republican",icon:[640,512,[],"f75e","M544 192c0-88.4-71.6-160-160-160H160C71.6 32 0 103.6 0 192v64h544v-64zm-367.7-21.6l-19.8 19.3 4.7 27.3c.8 4.9-4.3 8.6-8.7 6.3L128 210.4l-24.5 12.9c-4.3 2.3-9.5-1.4-8.7-6.3l4.7-27.3-19.8-19.3c-3.6-3.5-1.6-9.5 3.3-10.2l27.4-4 12.2-24.8c2.2-4.5 8.6-4.4 10.7 0l12.2 24.8 27.4 4c5 .7 6.9 6.7 3.4 10.2zm144 0l-19.8 19.3 4.7 27.3c.8 4.9-4.3 8.6-8.7 6.3L272 210.4l-24.5 12.9c-4.3 2.3-9.5-1.4-8.7-6.3l4.7-27.3-19.8-19.3c-3.6-3.5-1.6-9.5 3.3-10.2l27.4-4 12.2-24.8c2.2-4.5 8.6-4.4 10.7 0l12.2 24.8 27.4 4c5 .7 6.9 6.7 3.4 10.2zm144 0l-19.8 19.3 4.7 27.3c.8 4.9-4.3 8.6-8.7 6.3L416 210.4l-24.5 12.9c-4.3 2.3-9.5-1.4-8.7-6.3l4.7-27.3-19.8-19.3c-3.6-3.5-1.6-9.5 3.3-10.2l27.4-4 12.2-24.8c2.2-4.5 8.6-4.4 10.7 0l12.2 24.8 27.4 4c5 .7 6.9 6.7 3.4 10.2zM624 320h-32c-8.8 0-16 7.2-16 16v64c0 8.8-7.2 16-16 16s-16-7.2-16-16V288H0v176c0 8.8 7.2 16 16 16h96c8.8 0 16-7.2 16-16v-80h192v80c0 8.8 7.2 16 16 16h96c8.8 0 16-7.2 16-16V352h32v43.3c0 41.8 30 80.1 71.6 84.3 47.8 4.9 88.4-32.7 88.4-79.6v-64c0-8.8-7.2-16-16-16z"]},ud={prefix:"fas",iconName:"restroom",icon:[640,512,[],"f7bd","M128 128c35.3 0 64-28.7 64-64S163.3 0 128 0 64 28.7 64 64s28.7 64 64 64zm384 0c35.3 0 64-28.7 64-64S547.3 0 512 0s-64 28.7-64 64 28.7 64 64 64zm127.3 226.5l-45.6-185.8c-3.3-13.5-15.5-23-29.8-24.2-15 9.7-32.8 15.5-52 15.5-19.2 0-37-5.8-52-15.5-14.3 1.2-26.5 10.7-29.8 24.2l-45.6 185.8C381 369.6 393 384 409.2 384H464v104c0 13.3 10.7 24 24 24h48c13.3 0 24-10.7 24-24V384h54.8c16.2 0 28.2-14.4 24.5-29.5zM336 0h-32c-8.8 0-16 7.2-16 16v480c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16zM180.1 144.4c-15 9.8-32.9 15.6-52.1 15.6-19.2 0-37.1-5.8-52.1-15.6C51.3 146.5 32 166.9 32 192v136c0 13.3 10.7 24 24 24h8v136c0 13.3 10.7 24 24 24h80c13.3 0 24-10.7 24-24V352h8c13.3 0 24-10.7 24-24V192c0-25.1-19.3-45.5-43.9-47.6z"]},hd={prefix:"fas",iconName:"retweet",icon:[640,512,[],"f079","M629.657 343.598L528.971 444.284c-9.373 9.372-24.568 9.372-33.941 0L394.343 343.598c-9.373-9.373-9.373-24.569 0-33.941l10.823-10.823c9.562-9.562 25.133-9.34 34.419.492L480 342.118V160H292.451a24.005 24.005 0 0 1-16.971-7.029l-16-16C244.361 121.851 255.069 96 276.451 96H520c13.255 0 24 10.745 24 24v222.118l40.416-42.792c9.285-9.831 24.856-10.054 34.419-.492l10.823 10.823c9.372 9.372 9.372 24.569-.001 33.941zm-265.138 15.431A23.999 23.999 0 0 0 347.548 352H160V169.881l40.416 42.792c9.286 9.831 24.856 10.054 34.419.491l10.822-10.822c9.373-9.373 9.373-24.569 0-33.941L144.971 67.716c-9.373-9.373-24.569-9.373-33.941 0L10.343 168.402c-9.373 9.373-9.373 24.569 0 33.941l10.822 10.822c9.562 9.562 25.133 9.34 34.419-.491L96 169.881V392c0 13.255 10.745 24 24 24h243.549c21.382 0 32.09-25.851 16.971-40.971l-16.001-16z"]},dd={prefix:"fas",iconName:"ribbon",icon:[448,512,[],"f4d6","M6.1 444.3c-9.6 10.8-7.5 27.6 4.5 35.7l68.8 27.9c9.9 6.7 23.3 5 31.3-3.8l91.8-101.9-79.2-87.9-117.2 130zm435.8 0s-292-324.6-295.4-330.1c15.4-8.4 40.2-17.9 77.5-17.9s62.1 9.5 77.5 17.9c-3.3 5.6-56 64.6-56 64.6l79.1 87.7 34.2-38c28.7-31.9 33.3-78.6 11.4-115.5l-43.7-73.5c-4.3-7.2-9.9-13.3-16.8-18-40.7-27.6-127.4-29.7-171.4 0-6.9 4.7-12.5 10.8-16.8 18l-43.6 73.2c-1.5 2.5-37.1 62.2 11.5 116L337.5 504c8 8.9 21.4 10.5 31.3 3.8l68.8-27.9c11.9-8 14-24.8 4.3-35.6z"]},pd={prefix:"fas",iconName:"ring",icon:[512,512,[],"f70b","M256 64C110.06 64 0 125.91 0 208v98.13C0 384.48 114.62 448 256 448s256-63.52 256-141.87V208c0-82.09-110.06-144-256-144zm0 64c106.04 0 192 35.82 192 80 0 9.26-3.97 18.12-10.91 26.39C392.15 208.21 328.23 192 256 192s-136.15 16.21-181.09 42.39C67.97 226.12 64 217.26 64 208c0-44.18 85.96-80 192-80zM120.43 264.64C155.04 249.93 201.64 240 256 240s100.96 9.93 135.57 24.64C356.84 279.07 308.93 288 256 288s-100.84-8.93-135.57-23.36z"]},gd={prefix:"fas",iconName:"road",icon:[576,512,[],"f018","M573.19 402.67l-139.79-320C428.43 71.29 417.6 64 405.68 64h-97.59l2.45 23.16c.5 4.72-3.21 8.84-7.96 8.84h-29.16c-4.75 0-8.46-4.12-7.96-8.84L267.91 64h-97.59c-11.93 0-22.76 7.29-27.73 18.67L2.8 402.67C-6.45 423.86 8.31 448 30.54 448h196.84l10.31-97.68c.86-8.14 7.72-14.32 15.91-14.32h68.8c8.19 0 15.05 6.18 15.91 14.32L348.62 448h196.84c22.23 0 36.99-24.14 27.73-45.33zM260.4 135.16a8 8 0 0 1 7.96-7.16h39.29c4.09 0 7.53 3.09 7.96 7.16l4.6 43.58c.75 7.09-4.81 13.26-11.93 13.26h-40.54c-7.13 0-12.68-6.17-11.93-13.26l4.59-43.58zM315.64 304h-55.29c-9.5 0-16.91-8.23-15.91-17.68l5.07-48c.86-8.14 7.72-14.32 15.91-14.32h45.15c8.19 0 15.05 6.18 15.91 14.32l5.07 48c1 9.45-6.41 17.68-15.91 17.68z"]},fd={prefix:"fas",iconName:"robot",icon:[640,512,[],"f544","M32,224H64V416H32A31.96166,31.96166,0,0,1,0,384V256A31.96166,31.96166,0,0,1,32,224Zm512-48V448a64.06328,64.06328,0,0,1-64,64H160a64.06328,64.06328,0,0,1-64-64V176a79.974,79.974,0,0,1,80-80H288V32a32,32,0,0,1,64,0V96H464A79.974,79.974,0,0,1,544,176ZM264,256a40,40,0,1,0-40,40A39.997,39.997,0,0,0,264,256Zm-8,128H192v32h64Zm96,0H288v32h64ZM456,256a40,40,0,1,0-40,40A39.997,39.997,0,0,0,456,256Zm-8,128H384v32h64ZM640,256V384a31.96166,31.96166,0,0,1-32,32H576V224h32A31.96166,31.96166,0,0,1,640,256Z"]},md={prefix:"fas",iconName:"rocket",icon:[512,512,[],"f135","M505.12019,19.09375c-1.18945-5.53125-6.65819-11-12.207-12.1875C460.716,0,435.507,0,410.40747,0,307.17523,0,245.26909,55.20312,199.05238,128H94.83772c-16.34763.01562-35.55658,11.875-42.88664,26.48438L2.51562,253.29688A28.4,28.4,0,0,0,0,264a24.00867,24.00867,0,0,0,24.00582,24H127.81618l-22.47457,22.46875c-11.36521,11.36133-12.99607,32.25781,0,45.25L156.24582,406.625c11.15623,11.1875,32.15619,13.15625,45.27726,0l22.47457-22.46875V488a24.00867,24.00867,0,0,0,24.00581,24,28.55934,28.55934,0,0,0,10.707-2.51562l98.72834-49.39063c14.62888-7.29687,26.50776-26.5,26.50776-42.85937V312.79688c72.59753-46.3125,128.03493-108.40626,128.03493-211.09376C512.07526,76.5,512.07526,51.29688,505.12019,19.09375ZM384.04033,168A40,40,0,1,1,424.05,128,40.02322,40.02322,0,0,1,384.04033,168Z"]},vd={prefix:"fas",iconName:"route",icon:[512,512,[],"f4d7","M416 320h-96c-17.6 0-32-14.4-32-32s14.4-32 32-32h96s96-107 96-160-43-96-96-96-96 43-96 96c0 25.5 22.2 63.4 45.3 96H320c-52.9 0-96 43.1-96 96s43.1 96 96 96h96c17.6 0 32 14.4 32 32s-14.4 32-32 32H185.5c-16 24.8-33.8 47.7-47.3 64H416c52.9 0 96-43.1 96-96s-43.1-96-96-96zm0-256c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zM96 256c-53 0-96 43-96 96s96 160 96 160 96-107 96-160-43-96-96-96zm0 128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},Cd={prefix:"fas",iconName:"rss",icon:[448,512,[],"f09e","M128.081 415.959c0 35.369-28.672 64.041-64.041 64.041S0 451.328 0 415.959s28.672-64.041 64.041-64.041 64.04 28.673 64.04 64.041zm175.66 47.25c-8.354-154.6-132.185-278.587-286.95-286.95C7.656 175.765 0 183.105 0 192.253v48.069c0 8.415 6.49 15.472 14.887 16.018 111.832 7.284 201.473 96.702 208.772 208.772.547 8.397 7.604 14.887 16.018 14.887h48.069c9.149.001 16.489-7.655 15.995-16.79zm144.249.288C439.596 229.677 251.465 40.445 16.503 32.01 7.473 31.686 0 38.981 0 48.016v48.068c0 8.625 6.835 15.645 15.453 15.999 191.179 7.839 344.627 161.316 352.465 352.465.353 8.618 7.373 15.453 15.999 15.453h48.068c9.034-.001 16.329-7.474 16.005-16.504z"]},yd={prefix:"fas",iconName:"rss-square",icon:[448,512,[],"f143","M400 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48V80c0-26.51-21.49-48-48-48zM112 416c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm157.533 0h-34.335c-6.011 0-11.051-4.636-11.442-10.634-5.214-80.05-69.243-143.92-149.123-149.123-5.997-.39-10.633-5.431-10.633-11.441v-34.335c0-6.535 5.468-11.777 11.994-11.425 110.546 5.974 198.997 94.536 204.964 204.964.352 6.526-4.89 11.994-11.425 11.994zm103.027 0h-34.334c-6.161 0-11.175-4.882-11.427-11.038-5.598-136.535-115.204-246.161-251.76-251.76C68.882 152.949 64 147.935 64 141.774V107.44c0-6.454 5.338-11.664 11.787-11.432 167.83 6.025 302.21 141.191 308.205 308.205.232 6.449-4.978 11.787-11.432 11.787z"]},wd={prefix:"fas",iconName:"ruble-sign",icon:[384,512,[],"f158","M239.36 320C324.48 320 384 260.542 384 175.071S324.48 32 239.36 32H76c-6.627 0-12 5.373-12 12v206.632H12c-6.627 0-12 5.373-12 12V308c0 6.627 5.373 12 12 12h52v32H12c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h52v52c0 6.627 5.373 12 12 12h58.56c6.627 0 12-5.373 12-12v-52H308c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12H146.56v-32h92.8zm-92.8-219.252h78.72c46.72 0 74.88 29.11 74.88 74.323 0 45.832-28.16 75.561-76.16 75.561h-77.44V100.748z"]},Sd={prefix:"fas",iconName:"ruler",icon:[640,512,[],"f545","M635.7 167.2L556.1 31.7c-8.8-15-28.3-20.1-43.5-11.5l-69 39.1L503.3 161c2.2 3.8.9 8.5-2.9 10.7l-13.8 7.8c-3.8 2.2-8.7.9-10.9-2.9L416 75l-55.2 31.3 27.9 47.4c2.2 3.8.9 8.5-2.9 10.7l-13.8 7.8c-3.8 2.2-8.7.9-10.9-2.9L333.2 122 278 153.3 337.8 255c2.2 3.7.9 8.5-2.9 10.7l-13.8 7.8c-3.8 2.2-8.7.9-10.9-2.9l-59.7-101.7-55.2 31.3 27.9 47.4c2.2 3.8.9 8.5-2.9 10.7l-13.8 7.8c-3.8 2.2-8.7.9-10.9-2.9l-27.9-47.5-55.2 31.3 59.7 101.7c2.2 3.7.9 8.5-2.9 10.7l-13.8 7.8c-3.8 2.2-8.7.9-10.9-2.9L84.9 262.9l-69 39.1C.7 310.7-4.6 329.8 4.2 344.8l79.6 135.6c8.8 15 28.3 20.1 43.5 11.5L624.1 210c15.2-8.6 20.4-27.8 11.6-42.8z"]},bd={prefix:"fas",iconName:"ruler-combined",icon:[512,512,[],"f546","M160 288h-56c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h56v-64h-56c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h56V96h-56c-4.42 0-8-3.58-8-8V72c0-4.42 3.58-8 8-8h56V32c0-17.67-14.33-32-32-32H32C14.33 0 0 14.33 0 32v448c0 2.77.91 5.24 1.57 7.8L160 329.38V288zm320 64h-32v56c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-56h-64v56c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-56h-64v56c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-56h-41.37L24.2 510.43c2.56.66 5.04 1.57 7.8 1.57h448c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32z"]},Ed={prefix:"fas",iconName:"ruler-horizontal",icon:[576,512,[],"f547","M544 128h-48v88c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-88h-64v88c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-88h-64v88c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-88h-64v88c0 4.42-3.58 8-8 8h-16c-4.42 0-8-3.58-8-8v-88h-64v88c0 4.42-3.58 8-8 8H88c-4.42 0-8-3.58-8-8v-88H32c-17.67 0-32 14.33-32 32v192c0 17.67 14.33 32 32 32h512c17.67 0 32-14.33 32-32V160c0-17.67-14.33-32-32-32z"]},Ad={prefix:"fas",iconName:"ruler-vertical",icon:[256,512,[],"f548","M168 416c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h88v-64h-88c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h88v-64h-88c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h88v-64h-88c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h88V32c0-17.67-14.33-32-32-32H32C14.33 0 0 14.33 0 32v448c0 17.67 14.33 32 32 32h192c17.67 0 32-14.33 32-32v-64h-88z"]},Td={prefix:"fas",iconName:"running",icon:[416,512,[],"f70c","M272 96c26.51 0 48-21.49 48-48S298.51 0 272 0s-48 21.49-48 48 21.49 48 48 48zM113.69 317.47l-14.8 34.52H32c-17.67 0-32 14.33-32 32s14.33 32 32 32h77.45c19.25 0 36.58-11.44 44.11-29.09l8.79-20.52-10.67-6.3c-17.32-10.23-30.06-25.37-37.99-42.61zM384 223.99h-44.03l-26.06-53.25c-12.5-25.55-35.45-44.23-61.78-50.94l-71.08-21.14c-28.3-6.8-57.77-.55-80.84 17.14l-39.67 30.41c-14.03 10.75-16.69 30.83-5.92 44.86s30.84 16.66 44.86 5.92l39.69-30.41c7.67-5.89 17.44-8 25.27-6.14l14.7 4.37-37.46 87.39c-12.62 29.48-1.31 64.01 26.3 80.31l84.98 50.17-27.47 87.73c-5.28 16.86 4.11 34.81 20.97 40.09 3.19 1 6.41 1.48 9.58 1.48 13.61 0 26.23-8.77 30.52-22.45l31.64-101.06c5.91-20.77-2.89-43.08-21.64-54.39l-61.24-36.14 31.31-78.28 20.27 41.43c8 16.34 24.92 26.89 43.11 26.89H384c17.67 0 32-14.33 32-32s-14.33-31.99-32-31.99z"]},Md={prefix:"fas",iconName:"rupee-sign",icon:[320,512,[],"f156","M308 96c6.627 0 12-5.373 12-12V44c0-6.627-5.373-12-12-12H12C5.373 32 0 37.373 0 44v44.748c0 6.627 5.373 12 12 12h85.28c27.308 0 48.261 9.958 60.97 27.252H12c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h158.757c-6.217 36.086-32.961 58.632-74.757 58.632H12c-6.627 0-12 5.373-12 12v53.012c0 3.349 1.4 6.546 3.861 8.818l165.052 152.356a12.001 12.001 0 0 0 8.139 3.182h82.562c10.924 0 16.166-13.408 8.139-20.818L116.871 319.906c76.499-2.34 131.144-53.395 138.318-127.906H308c6.627 0 12-5.373 12-12v-40c0-6.627-5.373-12-12-12h-58.69c-3.486-11.541-8.28-22.246-14.252-32H308z"]},Rd={prefix:"fas",iconName:"sad-cry",icon:[496,512,[],"f5b3","M248 8C111 8 0 119 0 256c0 90.1 48.2 168.7 120 212.1V288c0-8.8 7.2-16 16-16s16 7.2 16 16v196.7c29.5 12.4 62 19.3 96 19.3s66.5-6.9 96-19.3V288c0-8.8 7.2-16 16-16s16 7.2 16 16v180.1C447.8 424.7 496 346 496 256 496 119 385 8 248 8zm-65.5 216.5c-14.8-13.2-46.2-13.2-61 0L112 233c-3.8 3.3-9.3 4-13.7 1.6-4.4-2.4-6.9-7.4-6.1-12.4 4-25.2 34.2-42.1 59.9-42.1S208 197 212 222.2c.8 5-1.7 10-6.1 12.4-5.8 3.1-11.2.7-13.7-1.6l-9.7-8.5zM248 416c-26.5 0-48-28.7-48-64s21.5-64 48-64 48 28.7 48 64-21.5 64-48 64zm149.8-181.5c-5.8 3.1-11.2.7-13.7-1.6l-9.5-8.5c-14.8-13.2-46.2-13.2-61 0L304 233c-3.8 3.3-9.3 4-13.7 1.6-4.4-2.4-6.9-7.4-6.1-12.4 4-25.2 34.2-42.1 59.9-42.1S400 197 404 222.2c.6 4.9-1.8 9.9-6.2 12.3z"]},_d={prefix:"fas",iconName:"sad-tear",icon:[496,512,[],"f5b4","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zM152 416c-26.5 0-48-21-48-47 0-20 28.5-60.4 41.6-77.8 3.2-4.3 9.6-4.3 12.8 0C171.5 308.6 200 349 200 369c0 26-21.5 47-48 47zm16-176c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm170.2 154.2C315.8 367.4 282.9 352 248 352c-21.2 0-21.2-32 0-32 44.4 0 86.3 19.6 114.7 53.8 13.8 16.4-11.2 36.5-24.5 20.4z"]},Pd={prefix:"fas",iconName:"satellite",icon:[512,512,[],"f7bf","M502.60969,310.04206l-96.70393,96.71625a31.88151,31.88151,0,0,1-45.00765,0L280.572,326.34115l-9.89231,9.90759a190.56343,190.56343,0,0,1-5.40716,168.52287c-4.50077,8.50115-16.39342,9.59505-23.20707,2.79725L134.54715,400.05428l-17.7999,17.79929c.70324,2.60972,1.60965,5.00067,1.60965,7.79793a32.00544,32.00544,0,1,1-32.00544-32.00434c2.79735,0,5.18838.90637,7.7982,1.60959l17.7999-17.79929L4.43129,269.94287c-6.798-6.81342-5.70409-18.6119,2.79735-23.20627a190.58161,190.58161,0,0,1,168.52864-5.407l9.79854-9.79821-80.31053-80.41716a32.002,32.002,0,0,1,0-45.09987L201.96474,9.29814A31.62639,31.62639,0,0,1,224.46868,0a31.99951,31.99951,0,0,1,22.59759,9.29814l80.32615,80.30777,47.805-47.89713a33.6075,33.6075,0,0,1,47.50808,0l47.50807,47.50645a33.63308,33.63308,0,0,1,0,47.50644l-47.805,47.89713L502.71908,265.036A31.78938,31.78938,0,0,1,502.60969,310.04206ZM219.56159,197.433l73.82505-73.82252-68.918-68.9-73.80942,73.80689Zm237.74352,90.106-68.90233-68.9156-73.825,73.82252,68.918,68.9Z"]},xd={prefix:"fas",iconName:"satellite-dish",icon:[512,512,[],"f7c0","M305.44954,462.59c7.39157,7.29792,6.18829,20.09661-3.00038,25.00356-77.713,41.80281-176.72559,29.9105-242.34331-35.7082C-5.49624,386.28227-17.404,287.362,24.41381,209.554c4.89125-9.095,17.68975-10.29834,25.00318-3.00043L166.22872,323.36708l27.39411-27.39452c-.68759-2.60974-1.594-5.00071-1.594-7.81361a32.00407,32.00407,0,1,1,32.00407,32.00455c-2.79723,0-5.20378-.89075-7.79786-1.594l-27.40974,27.41015ZM511.9758,303.06732a16.10336,16.10336,0,0,1-16.002,17.00242H463.86031a15.96956,15.96956,0,0,1-15.89265-15.00213C440.46671,175.5492,336.45348,70.53427,207.03078,63.53328a15.84486,15.84486,0,0,1-15.00191-15.90852V16.02652A16.09389,16.09389,0,0,1,209.031.02425C372.25491,8.61922,503.47472,139.841,511.9758,303.06732Zm-96.01221-.29692a16.21093,16.21093,0,0,1-16.11142,17.29934H367.645a16.06862,16.06862,0,0,1-15.89265-14.70522c-6.90712-77.01094-68.118-138.91037-144.92467-145.22376a15.94,15.94,0,0,1-14.79876-15.89289V112.13393a16.134,16.134,0,0,1,17.29908-16.096C319.45132,104.5391,407.55627,192.64538,415.96359,302.7704Z"]},Dd={prefix:"fas",iconName:"save",icon:[448,512,[],"f0c7","M433.941 129.941l-83.882-83.882A48 48 0 0 0 316.118 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48V163.882a48 48 0 0 0-14.059-33.941zM224 416c-35.346 0-64-28.654-64-64 0-35.346 28.654-64 64-64s64 28.654 64 64c0 35.346-28.654 64-64 64zm96-304.52V212c0 6.627-5.373 12-12 12H76c-6.627 0-12-5.373-12-12V108c0-6.627 5.373-12 12-12h228.52c3.183 0 6.235 1.264 8.485 3.515l3.48 3.48A11.996 11.996 0 0 1 320 111.48z"]},Id={prefix:"fas",iconName:"school",icon:[640,512,[],"f549","M0 224v272c0 8.84 7.16 16 16 16h80V192H32c-17.67 0-32 14.33-32 32zm360-48h-24v-40c0-4.42-3.58-8-8-8h-16c-4.42 0-8 3.58-8 8v64c0 4.42 3.58 8 8 8h48c4.42 0 8-3.58 8-8v-16c0-4.42-3.58-8-8-8zm137.75-63.96l-160-106.67a32.02 32.02 0 0 0-35.5 0l-160 106.67A32.002 32.002 0 0 0 128 138.66V512h128V368c0-8.84 7.16-16 16-16h96c8.84 0 16 7.16 16 16v144h128V138.67c0-10.7-5.35-20.7-14.25-26.63zM320 256c-44.18 0-80-35.82-80-80s35.82-80 80-80 80 35.82 80 80-35.82 80-80 80zm288-64h-64v320h80c8.84 0 16-7.16 16-16V224c0-17.67-14.33-32-32-32z"]},Ld={prefix:"fas",iconName:"screwdriver",icon:[512,512,[],"f54a","M448 0L320 96v62.06l-83.03 83.03c6.79 4.25 13.27 9.06 19.07 14.87 5.8 5.8 10.62 12.28 14.87 19.07L353.94 192H416l96-128-64-64zM128 278.59L10.92 395.67c-14.55 14.55-14.55 38.15 0 52.71l52.7 52.7c14.56 14.56 38.15 14.56 52.71 0L233.41 384c29.11-29.11 29.11-76.3 0-105.41s-76.3-29.11-105.41 0z"]},Nd={prefix:"fas",iconName:"scroll",icon:[640,512,[],"f70e","M48 0C21.53 0 0 21.53 0 48v64c0 8.84 7.16 16 16 16h80V48C96 21.53 74.47 0 48 0zm208 412.57V352h288V96c0-52.94-43.06-96-96-96H111.59C121.74 13.41 128 29.92 128 48v368c0 38.87 34.65 69.65 74.75 63.12C234.22 474 256 444.46 256 412.57zM288 384v32c0 52.93-43.06 96-96 96h336c61.86 0 112-50.14 112-112 0-8.84-7.16-16-16-16H288z"]},Od={prefix:"fas",iconName:"sd-card",icon:[384,512,[],"f7c2","M320 0H128L0 128v320c0 35.3 28.7 64 64 64h256c35.3 0 64-28.7 64-64V64c0-35.3-28.7-64-64-64zM160 160h-48V64h48v96zm80 0h-48V64h48v96zm80 0h-48V64h48v96z"]},Fd={prefix:"fas",iconName:"search",icon:[512,512,[],"f002","M505 442.7L405.3 343c-4.5-4.5-10.6-7-17-7H372c27.6-35.3 44-79.7 44-128C416 93.1 322.9 0 208 0S0 93.1 0 208s93.1 208 208 208c48.3 0 92.7-16.4 128-44v16.3c0 6.4 2.5 12.5 7 17l99.7 99.7c9.4 9.4 24.6 9.4 33.9 0l28.3-28.3c9.4-9.4 9.4-24.6.1-34zM208 336c-70.7 0-128-57.2-128-128 0-70.7 57.2-128 128-128 70.7 0 128 57.2 128 128 0 70.7-57.2 128-128 128z"]},kd={prefix:"fas",iconName:"search-dollar",icon:[512,512,[],"f688","M505.04 442.66l-99.71-99.69c-4.5-4.5-10.6-7-17-7h-16.3c27.6-35.3 44-79.69 44-127.99C416.03 93.09 322.92 0 208.02 0S0 93.09 0 207.98s93.11 207.98 208.02 207.98c48.3 0 92.71-16.4 128.01-44v16.3c0 6.4 2.5 12.5 7 17l99.71 99.69c9.4 9.4 24.6 9.4 33.9 0l28.3-28.3c9.4-9.4 9.4-24.59.1-33.99zm-297.02-90.7c-79.54 0-144-64.34-144-143.98 0-79.53 64.35-143.98 144-143.98 79.54 0 144 64.34 144 143.98 0 79.53-64.35 143.98-144 143.98zm27.11-152.54l-45.01-13.5c-5.16-1.55-8.77-6.78-8.77-12.73 0-7.27 5.3-13.19 11.8-13.19h28.11c4.56 0 8.96 1.29 12.82 3.72 3.24 2.03 7.36 1.91 10.13-.73l11.75-11.21c3.53-3.37 3.33-9.21-.57-12.14-9.1-6.83-20.08-10.77-31.37-11.35V112c0-4.42-3.58-8-8-8h-16c-4.42 0-8 3.58-8 8v16.12c-23.63.63-42.68 20.55-42.68 45.07 0 19.97 12.99 37.81 31.58 43.39l45.01 13.5c5.16 1.55 8.77 6.78 8.77 12.73 0 7.27-5.3 13.19-11.8 13.19h-28.1c-4.56 0-8.96-1.29-12.82-3.72-3.24-2.03-7.36-1.91-10.13.73l-11.75 11.21c-3.53 3.37-3.33 9.21.57 12.14 9.1 6.83 20.08 10.77 31.37 11.35V304c0 4.42 3.58 8 8 8h16c4.42 0 8-3.58 8-8v-16.12c23.63-.63 42.68-20.54 42.68-45.07 0-19.97-12.99-37.81-31.59-43.39z"]},Gd={prefix:"fas",iconName:"search-location",icon:[512,512,[],"f689","M505.04 442.66l-99.71-99.69c-4.5-4.5-10.6-7-17-7h-16.3c27.6-35.3 44-79.69 44-127.99C416.03 93.09 322.92 0 208.02 0S0 93.09 0 207.98s93.11 207.98 208.02 207.98c48.3 0 92.71-16.4 128.01-44v16.3c0 6.4 2.5 12.5 7 17l99.71 99.69c9.4 9.4 24.6 9.4 33.9 0l28.3-28.3c9.4-9.4 9.4-24.59.1-33.99zm-297.02-90.7c-79.54 0-144-64.34-144-143.98 0-79.53 64.35-143.98 144-143.98 79.54 0 144 64.34 144 143.98 0 79.53-64.35 143.98-144 143.98zm.02-239.96c-40.78 0-73.84 33.05-73.84 73.83 0 32.96 48.26 93.05 66.75 114.86a9.24 9.24 0 0 0 14.18 0c18.49-21.81 66.75-81.89 66.75-114.86 0-40.78-33.06-73.83-73.84-73.83zm0 96c-13.26 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24z"]},Vd={prefix:"fas",iconName:"search-minus",icon:[512,512,[],"f010","M304 192v32c0 6.6-5.4 12-12 12H124c-6.6 0-12-5.4-12-12v-32c0-6.6 5.4-12 12-12h168c6.6 0 12 5.4 12 12zm201 284.7L476.7 505c-9.4 9.4-24.6 9.4-33.9 0L343 405.3c-4.5-4.5-7-10.6-7-17V372c-35.3 27.6-79.7 44-128 44C93.1 416 0 322.9 0 208S93.1 0 208 0s208 93.1 208 208c0 48.3-16.4 92.7-44 128h16.3c6.4 0 12.5 2.5 17 7l99.7 99.7c9.3 9.4 9.3 24.6 0 34zM344 208c0-75.2-60.8-136-136-136S72 132.8 72 208s60.8 136 136 136 136-60.8 136-136z"]},Hd={prefix:"fas",iconName:"search-plus",icon:[512,512,[],"f00e","M304 192v32c0 6.6-5.4 12-12 12h-56v56c0 6.6-5.4 12-12 12h-32c-6.6 0-12-5.4-12-12v-56h-56c-6.6 0-12-5.4-12-12v-32c0-6.6 5.4-12 12-12h56v-56c0-6.6 5.4-12 12-12h32c6.6 0 12 5.4 12 12v56h56c6.6 0 12 5.4 12 12zm201 284.7L476.7 505c-9.4 9.4-24.6 9.4-33.9 0L343 405.3c-4.5-4.5-7-10.6-7-17V372c-35.3 27.6-79.7 44-128 44C93.1 416 0 322.9 0 208S93.1 0 208 0s208 93.1 208 208c0 48.3-16.4 92.7-44 128h16.3c6.4 0 12.5 2.5 17 7l99.7 99.7c9.3 9.4 9.3 24.6 0 34zM344 208c0-75.2-60.8-136-136-136S72 132.8 72 208s60.8 136 136 136 136-60.8 136-136z"]},Bd={prefix:"fas",iconName:"seedling",icon:[512,512,[],"f4d8","M64 96H0c0 123.7 100.3 224 224 224v144c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V320C288 196.3 187.7 96 64 96zm384-64c-84.2 0-157.4 46.5-195.7 115.2 27.7 30.2 48.2 66.9 59 107.6C424 243.1 512 147.9 512 32h-64z"]},zd={prefix:"fas",iconName:"server",icon:[512,512,[],"f233","M480 160H32c-17.673 0-32-14.327-32-32V64c0-17.673 14.327-32 32-32h448c17.673 0 32 14.327 32 32v64c0 17.673-14.327 32-32 32zm-48-88c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm-64 0c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm112 248H32c-17.673 0-32-14.327-32-32v-64c0-17.673 14.327-32 32-32h448c17.673 0 32 14.327 32 32v64c0 17.673-14.327 32-32 32zm-48-88c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm-64 0c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm112 248H32c-17.673 0-32-14.327-32-32v-64c0-17.673 14.327-32 32-32h448c17.673 0 32 14.327 32 32v64c0 17.673-14.327 32-32 32zm-48-88c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24zm-64 0c-13.255 0-24 10.745-24 24s10.745 24 24 24 24-10.745 24-24-10.745-24-24-24z"]},Ud={prefix:"fas",iconName:"shapes",icon:[512,512,[],"f61f","M128,256A128,128,0,1,0,256,384,128,128,0,0,0,128,256Zm379-54.86L400.07,18.29a37.26,37.26,0,0,0-64.14,0L229,201.14C214.76,225.52,232.58,256,261.09,256H474.91C503.42,256,521.24,225.52,507,201.14ZM480,288H320a32,32,0,0,0-32,32V480a32,32,0,0,0,32,32H480a32,32,0,0,0,32-32V320A32,32,0,0,0,480,288Z"]},Wd={prefix:"fas",iconName:"share",icon:[512,512,[],"f064","M503.691 189.836L327.687 37.851C312.281 24.546 288 35.347 288 56.015v80.053C127.371 137.907 0 170.1 0 322.326c0 61.441 39.581 122.309 83.333 154.132 13.653 9.931 33.111-2.533 28.077-18.631C66.066 312.814 132.917 274.316 288 272.085V360c0 20.7 24.3 31.453 39.687 18.164l176.004-152c11.071-9.562 11.086-26.753 0-36.328z"]},jd={prefix:"fas",iconName:"share-alt",icon:[448,512,[],"f1e0","M352 320c-22.608 0-43.387 7.819-59.79 20.895l-102.486-64.054a96.551 96.551 0 0 0 0-41.683l102.486-64.054C308.613 184.181 329.392 192 352 192c53.019 0 96-42.981 96-96S405.019 0 352 0s-96 42.981-96 96c0 7.158.79 14.13 2.276 20.841L155.79 180.895C139.387 167.819 118.608 160 96 160c-53.019 0-96 42.981-96 96s42.981 96 96 96c22.608 0 43.387-7.819 59.79-20.895l102.486 64.054A96.301 96.301 0 0 0 256 416c0 53.019 42.981 96 96 96s96-42.981 96-96-42.981-96-96-96z"]},Kd={prefix:"fas",iconName:"share-alt-square",icon:[448,512,[],"f1e1","M448 80v352c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48V80c0-26.51 21.49-48 48-48h352c26.51 0 48 21.49 48 48zM304 296c-14.562 0-27.823 5.561-37.783 14.671l-67.958-40.775a56.339 56.339 0 0 0 0-27.793l67.958-40.775C276.177 210.439 289.438 216 304 216c30.928 0 56-25.072 56-56s-25.072-56-56-56-56 25.072-56 56c0 4.797.605 9.453 1.74 13.897l-67.958 40.775C171.823 205.561 158.562 200 144 200c-30.928 0-56 25.072-56 56s25.072 56 56 56c14.562 0 27.823-5.561 37.783-14.671l67.958 40.775a56.088 56.088 0 0 0-1.74 13.897c0 30.928 25.072 56 56 56s56-25.072 56-56C360 321.072 334.928 296 304 296z"]},$d={prefix:"fas",iconName:"share-square",icon:[576,512,[],"f14d","M568.482 177.448L424.479 313.433C409.3 327.768 384 317.14 384 295.985v-71.963c-144.575.97-205.566 35.113-164.775 171.353 4.483 14.973-12.846 26.567-25.006 17.33C155.252 383.105 120 326.488 120 269.339c0-143.937 117.599-172.5 264-173.312V24.012c0-21.174 25.317-31.768 40.479-17.448l144.003 135.988c10.02 9.463 10.028 25.425 0 34.896zM384 379.128V448H64V128h50.916a11.99 11.99 0 0 0 8.648-3.693c14.953-15.568 32.237-27.89 51.014-37.676C185.708 80.83 181.584 64 169.033 64H48C21.49 64 0 85.49 0 112v352c0 26.51 21.49 48 48 48h352c26.51 0 48-21.49 48-48v-88.806c0-8.288-8.197-14.066-16.011-11.302a71.83 71.83 0 0 1-34.189 3.377c-7.27-1.046-13.8 4.514-13.8 11.859z"]},qd={prefix:"fas",iconName:"shekel-sign",icon:[448,512,[],"f20b","M248 168v168c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V168c0-75.11-60.89-136-136-136H24C10.75 32 0 42.74 0 56v408c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V112h112c30.93 0 56 25.07 56 56zM432 32h-48c-8.84 0-16 7.16-16 16v296c0 30.93-25.07 56-56 56H200V176c0-8.84-7.16-16-16-16h-48c-8.84 0-16 7.16-16 16v280c0 13.25 10.75 24 24 24h168c75.11 0 136-60.89 136-136V48c0-8.84-7.16-16-16-16z"]},Yd={prefix:"fas",iconName:"shield-alt",icon:[512,512,[],"f3ed","M466.5 83.7l-192-80a48.15 48.15 0 0 0-36.9 0l-192 80C27.7 91.1 16 108.6 16 128c0 198.5 114.5 335.7 221.5 380.3 11.8 4.9 25.1 4.9 36.9 0C360.1 472.6 496 349.3 496 128c0-19.4-11.7-36.9-29.5-44.3zM256.1 446.3l-.1-381 175.9 73.3c-3.3 151.4-82.1 261.1-175.8 307.7z"]},Qd={prefix:"fas",iconName:"shield-virus",icon:[512,512,[],"e06c","M224,192a16,16,0,1,0,16,16A16,16,0,0,0,224,192ZM466.5,83.68l-192-80A57.4,57.4,0,0,0,256.05,0a57.4,57.4,0,0,0-18.46,3.67l-192,80A47.93,47.93,0,0,0,16,128C16,326.5,130.5,463.72,237.5,508.32a48.09,48.09,0,0,0,36.91,0C360.09,472.61,496,349.3,496,128A48,48,0,0,0,466.5,83.68ZM384,256H371.88c-28.51,0-42.79,34.47-22.63,54.63l8.58,8.57a16,16,0,1,1-22.63,22.63l-8.57-8.58C306.47,313.09,272,327.37,272,355.88V368a16,16,0,0,1-32,0V355.88c0-28.51-34.47-42.79-54.63-22.63l-8.57,8.58a16,16,0,0,1-22.63-22.63l8.58-8.57c20.16-20.16,5.88-54.63-22.63-54.63H128a16,16,0,0,1,0-32h12.12c28.51,0,42.79-34.47,22.63-54.63l-8.58-8.57a16,16,0,0,1,22.63-22.63l8.57,8.58c20.16,20.16,54.63,5.88,54.63-22.63V112a16,16,0,0,1,32,0v12.12c0,28.51,34.47,42.79,54.63,22.63l8.57-8.58a16,16,0,0,1,22.63,22.63l-8.58,8.57C329.09,189.53,343.37,224,371.88,224H384a16,16,0,0,1,0,32Zm-96,0a16,16,0,1,0,16,16A16,16,0,0,0,288,256Z"]},Xd={prefix:"fas",iconName:"ship",icon:[640,512,[],"f21a","M496.616 372.639l70.012-70.012c16.899-16.9 9.942-45.771-12.836-53.092L512 236.102V96c0-17.673-14.327-32-32-32h-64V24c0-13.255-10.745-24-24-24H248c-13.255 0-24 10.745-24 24v40h-64c-17.673 0-32 14.327-32 32v140.102l-41.792 13.433c-22.753 7.313-29.754 36.173-12.836 53.092l70.012 70.012C125.828 416.287 85.587 448 24 448c-13.255 0-24 10.745-24 24v16c0 13.255 10.745 24 24 24 61.023 0 107.499-20.61 143.258-59.396C181.677 487.432 216.021 512 256 512h128c39.979 0 74.323-24.568 88.742-59.396C508.495 491.384 554.968 512 616 512c13.255 0 24-10.745 24-24v-16c0-13.255-10.745-24-24-24-60.817 0-101.542-31.001-119.384-75.361zM192 128h256v87.531l-118.208-37.995a31.995 31.995 0 0 0-19.584 0L192 215.531V128z"]},Zd={prefix:"fas",iconName:"shipping-fast",icon:[640,512,[],"f48b","M624 352h-16V243.9c0-12.7-5.1-24.9-14.1-33.9L494 110.1c-9-9-21.2-14.1-33.9-14.1H416V48c0-26.5-21.5-48-48-48H112C85.5 0 64 21.5 64 48v48H8c-4.4 0-8 3.6-8 8v16c0 4.4 3.6 8 8 8h272c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H40c-4.4 0-8 3.6-8 8v16c0 4.4 3.6 8 8 8h208c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H8c-4.4 0-8 3.6-8 8v16c0 4.4 3.6 8 8 8h208c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H64v128c0 53 43 96 96 96s96-43 96-96h128c0 53 43 96 96 96s96-43 96-96h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM160 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm320 0c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm80-208H416V144h44.1l99.9 99.9V256z"]},Jd={prefix:"fas",iconName:"shoe-prints",icon:[640,512,[],"f54b","M192 160h32V32h-32c-35.35 0-64 28.65-64 64s28.65 64 64 64zM0 416c0 35.35 28.65 64 64 64h32V352H64c-35.35 0-64 28.65-64 64zm337.46-128c-34.91 0-76.16 13.12-104.73 32-24.79 16.38-44.52 32-104.73 32v128l57.53 15.97c26.21 7.28 53.01 13.12 80.31 15.05 32.69 2.31 65.6.67 97.58-6.2C472.9 481.3 512 429.22 512 384c0-64-84.18-96-174.54-96zM491.42 7.19C459.44.32 426.53-1.33 393.84.99c-27.3 1.93-54.1 7.77-80.31 15.04L256 32v128c60.2 0 79.94 15.62 104.73 32 28.57 18.88 69.82 32 104.73 32C555.82 224 640 192 640 128c0-45.22-39.1-97.3-148.58-120.81z"]},ep={prefix:"fas",iconName:"shopping-bag",icon:[448,512,[],"f290","M352 160v-32C352 57.42 294.579 0 224 0 153.42 0 96 57.42 96 128v32H0v272c0 44.183 35.817 80 80 80h288c44.183 0 80-35.817 80-80V160h-96zm-192-32c0-35.29 28.71-64 64-64s64 28.71 64 64v32H160v-32zm160 120c-13.255 0-24-10.745-24-24s10.745-24 24-24 24 10.745 24 24-10.745 24-24 24zm-192 0c-13.255 0-24-10.745-24-24s10.745-24 24-24 24 10.745 24 24-10.745 24-24 24z"]},tp={prefix:"fas",iconName:"shopping-basket",icon:[576,512,[],"f291","M576 216v16c0 13.255-10.745 24-24 24h-8l-26.113 182.788C514.509 462.435 494.257 480 470.37 480H105.63c-23.887 0-44.139-17.565-47.518-41.212L32 256h-8c-13.255 0-24-10.745-24-24v-16c0-13.255 10.745-24 24-24h67.341l106.78-146.821c10.395-14.292 30.407-17.453 44.701-7.058 14.293 10.395 17.453 30.408 7.058 44.701L170.477 192h235.046L326.12 82.821c-10.395-14.292-7.234-34.306 7.059-44.701 14.291-10.395 34.306-7.235 44.701 7.058L484.659 192H552c13.255 0 24 10.745 24 24zM312 392V280c0-13.255-10.745-24-24-24s-24 10.745-24 24v112c0 13.255 10.745 24 24 24s24-10.745 24-24zm112 0V280c0-13.255-10.745-24-24-24s-24 10.745-24 24v112c0 13.255 10.745 24 24 24s24-10.745 24-24zm-224 0V280c0-13.255-10.745-24-24-24s-24 10.745-24 24v112c0 13.255 10.745 24 24 24s24-10.745 24-24z"]},ip={prefix:"fas",iconName:"shopping-cart",icon:[576,512,[],"f07a","M528.12 301.319l47.273-208C578.806 78.301 567.391 64 551.99 64H159.208l-9.166-44.81C147.758 8.021 137.93 0 126.529 0H24C10.745 0 0 10.745 0 24v16c0 13.255 10.745 24 24 24h69.883l70.248 343.435C147.325 417.1 136 435.222 136 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-15.674-6.447-29.835-16.824-40h209.647C430.447 426.165 424 440.326 424 456c0 30.928 25.072 56 56 56s56-25.072 56-56c0-22.172-12.888-41.332-31.579-50.405l5.517-24.276c3.413-15.018-8.002-29.319-23.403-29.319H218.117l-6.545-32h293.145c11.206 0 20.92-7.754 23.403-18.681z"]},rp={prefix:"fas",iconName:"shower",icon:[512,512,[],"f2cc","M304,320a16,16,0,1,0,16,16A16,16,0,0,0,304,320Zm32-96a16,16,0,1,0,16,16A16,16,0,0,0,336,224Zm32,64a16,16,0,1,0-16-16A16,16,0,0,0,368,288Zm-32,32a16,16,0,1,0-16-16A16,16,0,0,0,336,320Zm-32-64a16,16,0,1,0,16,16A16,16,0,0,0,304,256Zm128-32a16,16,0,1,0-16-16A16,16,0,0,0,432,224Zm-48,16a16,16,0,1,0,16-16A16,16,0,0,0,384,240Zm-16-48a16,16,0,1,0,16,16A16,16,0,0,0,368,192Zm96,32a16,16,0,1,0,16,16A16,16,0,0,0,464,224Zm32-32a16,16,0,1,0,16,16A16,16,0,0,0,496,192Zm-64,64a16,16,0,1,0,16,16A16,16,0,0,0,432,256Zm-32,32a16,16,0,1,0,16,16A16,16,0,0,0,400,288Zm-64,64a16,16,0,1,0,16,16A16,16,0,0,0,336,352Zm-32,32a16,16,0,1,0,16,16A16,16,0,0,0,304,384Zm64-64a16,16,0,1,0,16,16A16,16,0,0,0,368,320Zm21.65-218.35-11.3-11.31a16,16,0,0,0-22.63,0L350.05,96A111.19,111.19,0,0,0,272,64c-19.24,0-37.08,5.3-52.9,13.85l-10-10A121.72,121.72,0,0,0,123.44,32C55.49,31.5,0,92.91,0,160.85V464a16,16,0,0,0,16,16H48a16,16,0,0,0,16-16V158.4c0-30.15,21-58.2,51-61.93a58.38,58.38,0,0,1,48.93,16.67l10,10C165.3,138.92,160,156.76,160,176a111.23,111.23,0,0,0,32,78.05l-5.66,5.67a16,16,0,0,0,0,22.62l11.3,11.31a16,16,0,0,0,22.63,0L389.65,124.28A16,16,0,0,0,389.65,101.65Z"]},np={prefix:"fas",iconName:"shuttle-van",icon:[640,512,[],"f5b6","M628.88 210.65L494.39 49.27A48.01 48.01 0 0 0 457.52 32H32C14.33 32 0 46.33 0 64v288c0 17.67 14.33 32 32 32h32c0 53.02 42.98 96 96 96s96-42.98 96-96h128c0 53.02 42.98 96 96 96s96-42.98 96-96h32c17.67 0 32-14.33 32-32V241.38c0-11.23-3.94-22.1-11.12-30.73zM64 192V96h96v96H64zm96 240c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm160-240h-96V96h96v96zm160 240c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm-96-240V96h66.02l80 96H384z"]},sp={prefix:"fas",iconName:"sign",icon:[512,512,[],"f4d9","M496 64H128V16c0-8.8-7.2-16-16-16H80c-8.8 0-16 7.2-16 16v48H16C7.2 64 0 71.2 0 80v32c0 8.8 7.2 16 16 16h48v368c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V128h368c8.8 0 16-7.2 16-16V80c0-8.8-7.2-16-16-16zM160 384h320V160H160v224z"]},op={prefix:"fas",iconName:"sign-in-alt",icon:[512,512,[],"f2f6","M416 448h-84c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h84c17.7 0 32-14.3 32-32V160c0-17.7-14.3-32-32-32h-84c-6.6 0-12-5.4-12-12V76c0-6.6 5.4-12 12-12h84c53 0 96 43 96 96v192c0 53-43 96-96 96zm-47-201L201 79c-15-15-41-4.5-41 17v96H24c-13.3 0-24 10.7-24 24v96c0 13.3 10.7 24 24 24h136v96c0 21.5 26 32 41 17l168-168c9.3-9.4 9.3-24.6 0-34z"]},ap={prefix:"fas",iconName:"sign-language",icon:[448,512,[],"f2a7","M91.434 483.987c-.307-16.018 13.109-29.129 29.13-29.129h62.293v-5.714H56.993c-16.021 0-29.437-13.111-29.13-29.129C28.16 404.491 40.835 392 56.428 392h126.429v-5.714H29.136c-16.021 0-29.437-13.111-29.13-29.129.297-15.522 12.973-28.013 28.566-28.013h154.286v-5.714H57.707c-16.021 0-29.437-13.111-29.13-29.129.297-15.522 12.973-28.013 28.566-28.013h168.566l-31.085-22.606c-12.762-9.281-15.583-27.149-6.302-39.912 9.281-12.761 27.15-15.582 39.912-6.302l123.361 89.715a34.287 34.287 0 0 1 14.12 27.728v141.136c0 15.91-10.946 29.73-26.433 33.374l-80.471 18.934a137.16 137.16 0 0 1-31.411 3.646H120c-15.593-.001-28.269-12.492-28.566-28.014zm73.249-225.701h36.423l-11.187-8.136c-18.579-13.511-20.313-40.887-3.17-56.536l-13.004-16.7c-9.843-12.641-28.43-15.171-40.88-5.088-12.065 9.771-14.133 27.447-4.553 39.75l36.371 46.71zm283.298-2.103l-5.003-152.452c-.518-15.771-13.722-28.136-29.493-27.619-15.773.518-28.137 13.722-27.619 29.493l1.262 38.415L283.565 11.019c-9.58-12.303-27.223-14.63-39.653-5.328-12.827 9.599-14.929 28.24-5.086 40.881l76.889 98.745-4.509 3.511-94.79-121.734c-9.58-12.303-27.223-14.63-39.653-5.328-12.827 9.599-14.929 28.24-5.086 40.881l94.443 121.288-4.509 3.511-77.675-99.754c-9.58-12.303-27.223-14.63-39.653-5.328-12.827 9.599-14.929 28.24-5.086 40.881l52.053 66.849c12.497-8.257 29.055-8.285 41.69.904l123.36 89.714c10.904 7.93 17.415 20.715 17.415 34.198v16.999l61.064-47.549a34.285 34.285 0 0 0 13.202-28.177z"]},lp={prefix:"fas",iconName:"sign-out-alt",icon:[512,512,[],"f2f5","M497 273L329 441c-15 15-41 4.5-41-17v-96H152c-13.3 0-24-10.7-24-24v-96c0-13.3 10.7-24 24-24h136V88c0-21.4 25.9-32 41-17l168 168c9.3 9.4 9.3 24.6 0 34zM192 436v-40c0-6.6-5.4-12-12-12H96c-17.7 0-32-14.3-32-32V160c0-17.7 14.3-32 32-32h84c6.6 0 12-5.4 12-12V76c0-6.6-5.4-12-12-12H96c-53 0-96 43-96 96v192c0 53 43 96 96 96h84c6.6 0 12-5.4 12-12z"]},cp={prefix:"fas",iconName:"signal",icon:[640,512,[],"f012","M216 288h-48c-8.84 0-16 7.16-16 16v192c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V304c0-8.84-7.16-16-16-16zM88 384H40c-8.84 0-16 7.16-16 16v96c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16v-96c0-8.84-7.16-16-16-16zm256-192h-48c-8.84 0-16 7.16-16 16v288c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V208c0-8.84-7.16-16-16-16zm128-96h-48c-8.84 0-16 7.16-16 16v384c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V112c0-8.84-7.16-16-16-16zM600 0h-48c-8.84 0-16 7.16-16 16v480c0 8.84 7.16 16 16 16h48c8.84 0 16-7.16 16-16V16c0-8.84-7.16-16-16-16z"]},up={prefix:"fas",iconName:"signature",icon:[640,512,[],"f5b7","M623.2 192c-51.8 3.5-125.7 54.7-163.1 71.5-29.1 13.1-54.2 24.4-76.1 24.4-22.6 0-26-16.2-21.3-51.9 1.1-8 11.7-79.2-42.7-76.1-25.1 1.5-64.3 24.8-169.5 126L192 182.2c30.4-75.9-53.2-151.5-129.7-102.8L7.4 116.3C0 121-2.2 130.9 2.5 138.4l17.2 27c4.7 7.5 14.6 9.7 22.1 4.9l58-38.9c18.4-11.7 40.7 7.2 32.7 27.1L34.3 404.1C27.5 421 37 448 64 448c8.3 0 16.5-3.2 22.6-9.4 42.2-42.2 154.7-150.7 211.2-195.8-2.2 28.5-2.1 58.9 20.6 83.8 15.3 16.8 37.3 25.3 65.5 25.3 35.6 0 68-14.6 102.3-30 33-14.8 99-62.6 138.4-65.8 8.5-.7 15.2-7.3 15.2-15.8v-32.1c.2-9.1-7.5-16.8-16.6-16.2z"]},hp={prefix:"fas",iconName:"sim-card",icon:[384,512,[],"f7c4","M0 64v384c0 35.3 28.7 64 64 64h256c35.3 0 64-28.7 64-64V128L256 0H64C28.7 0 0 28.7 0 64zm224 192h-64v-64h64v64zm96 0h-64v-64h32c17.7 0 32 14.3 32 32v32zm-64 128h64v32c0 17.7-14.3 32-32 32h-32v-64zm-96 0h64v64h-64v-64zm-96 0h64v64H96c-17.7 0-32-14.3-32-32v-32zm0-96h256v64H64v-64zm0-64c0-17.7 14.3-32 32-32h32v64H64v-32z"]},dp={prefix:"fas",iconName:"sink",icon:[512,512,[],"e06d","M32,416a96,96,0,0,0,96,96H384a96,96,0,0,0,96-96V384H32ZM496,288H400V256h64a16,16,0,0,0,16-16V224a16,16,0,0,0-16-16H384a32,32,0,0,0-32,32v48H288V96a32,32,0,0,1,64,0v16a16,16,0,0,0,16,16h32a16,16,0,0,0,16-16V96A96.16,96.16,0,0,0,300.87,1.86C255.29,10.71,224,53.36,224,99.79V288H160V240a32,32,0,0,0-32-32H48a16,16,0,0,0-16,16v16a16,16,0,0,0,16,16h64v32H16A16,16,0,0,0,0,304v32a16,16,0,0,0,16,16H496a16,16,0,0,0,16-16V304A16,16,0,0,0,496,288Z"]},pp={prefix:"fas",iconName:"sitemap",icon:[640,512,[],"f0e8","M128 352H32c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32zm-24-80h192v48h48v-48h192v48h48v-57.59c0-21.17-17.23-38.41-38.41-38.41H344v-64h40c17.67 0 32-14.33 32-32V32c0-17.67-14.33-32-32-32H256c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h40v64H94.41C73.23 224 56 241.23 56 262.41V320h48v-48zm264 80h-96c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32zm240 0h-96c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32z"]},gp={prefix:"fas",iconName:"skating",icon:[448,512,[],"f7c5","M400 0c-26.5 0-48 21.5-48 48s21.5 48 48 48 48-21.5 48-48-21.5-48-48-48zm0 448c-8.8 0-16 7.2-16 16s-7.2 16-16 16h-96c-8.8 0-16 7.2-16 16s7.2 16 16 16h96c26.5 0 48-21.5 48-48 0-8.8-7.2-16-16-16zm-282.2 8.6c-6.2 6.2-16.4 6.3-22.6 0l-67.9-67.9c-6.2-6.2-16.4-6.2-22.6 0s-6.2 16.4 0 22.6l67.9 67.9c9.4 9.4 21.7 14 34 14s24.6-4.7 33.9-14c6.2-6.2 6.2-16.4 0-22.6s-16.4-6.3-22.7 0zm56.1-179.8l-93.7 93.7c-12.5 12.5-12.5 32.8 0 45.2 6.2 6.2 14.4 9.4 22.6 9.4s16.4-3.1 22.6-9.4l91.9-91.9-30.2-30.2c-5-5-9.4-10.7-13.2-16.8zM128 160h105.5l-20.1 17.2c-13.5 11.5-21.6 28.4-22.3 46.1-.7 17.8 6.1 35.2 18.7 47.7l78.2 78.2V432c0 17.7 14.3 32 32 32s32-14.3 32-32v-89.4c0-12.6-5.1-25-14.1-33.9l-61-61c.5-.4 1.2-.6 1.7-1.1l82.3-82.3c11.5-11.5 14.9-28.6 8.7-43.6-6.2-15-20.7-24.7-37-24.7H128c-17.7 0-32 14.3-32 32s14.3 32 32 32z"]},fp={prefix:"fas",iconName:"skiing",icon:[512,512,[],"f7c9","M432 96c26.5 0 48-21.5 48-48S458.5 0 432 0s-48 21.5-48 48 21.5 48 48 48zm73 356.1c-9.4-9.4-24.6-9.4-33.9 0-12.1 12.1-30.5 15.4-45.1 8.7l-135.8-70.2 49.2-73.8c12.7-19 10.2-44.5-6-60.6L293 215.7l-107-53.1c-2.9 19.9 3.4 40 17.7 54.4l75.1 75.2-45.9 68.8L35 258.7c-11.7-6-26.2-1.5-32.3 10.3-6.1 11.8-1.5 26.3 10.3 32.3l391.9 202.5c11.9 5.5 24.5 8.1 37.1 8.1 23.2 0 46-9 63-26 9.3-9.3 9.3-24.5 0-33.8zM120 91.6l-11.5 22.5c14.4 7.3 31.2 4.9 42.8-4.8l47.2 23.4c-.1.1-.1.2-.2.3l114.5 56.8 32.4-13 6.4 19.1c4 12.1 12.6 22 24 27.7l58.1 29c15.9 7.9 35 1.5 42.9-14.3 7.9-15.8 1.5-35-14.3-42.9l-52.1-26.1-17.1-51.2c-8.1-24.2-40.9-56.6-84.5-39.2l-81.2 32.5-62.5-31c.3-14.5-7.2-28.6-20.9-35.6l-11.1 21.7h-.2l-34.4-7c-1.8-.4-3.7.2-5 1.7-1.9 2.2-1.7 5.5.5 7.4l26.2 23z"]},mp={prefix:"fas",iconName:"skiing-nordic",icon:[576,512,[],"f7ca","M336 96c26.5 0 48-21.5 48-48S362.5 0 336 0s-48 21.5-48 48 21.5 48 48 48zm216 320c-13.2 0-24 10.7-24 24 0 13.2-10.8 24-24 24h-69.5L460 285.6c11.7-4.7 20.1-16.2 20.1-29.6 0-17.7-14.3-32-32-32h-44L378 170.8c-12.5-25.5-35.5-44.2-61.8-50.9L245 98.7c-28.3-6.8-57.8-.5-80.8 17.1l-39.7 30.4c-14 10.7-16.7 30.8-5.9 44.9.7.9 1.7 1.3 2.4 2.1L66.9 464H24c-13.2 0-24 10.7-24 24s10.8 24 24 24h480c39.7 0 72-32.3 72-72 0-13.2-10.8-24-24-24zm-260.5 48h-96.9l43.1-91-22-13c-12.1-7.2-21.9-16.9-29.5-27.8L123.7 464H99.5l52.3-261.4c4.1-1 8.1-2.9 11.7-5.6l39.7-30.4c7.7-5.9 17.4-8 25.3-6.1l14.7 4.4-37.5 87.4c-12.6 29.5-1.3 64 26.3 80.3l85 50.2-25.5 81.2zm110.6 0h-43.6l23.6-75.5c5.9-20.8-2.9-43.1-21.6-54.4L299.3 298l31.3-78.3 20.3 41.4c8 16.3 24.9 26.9 43.1 26.9h33.3l-25.2 176z"]},vp={prefix:"fas",iconName:"skull",icon:[512,512,[],"f54c","M256 0C114.6 0 0 100.3 0 224c0 70.1 36.9 132.6 94.5 173.7 9.6 6.9 15.2 18.1 13.5 29.9l-9.4 66.2c-1.4 9.6 6 18.2 15.7 18.2H192v-56c0-4.4 3.6-8 8-8h16c4.4 0 8 3.6 8 8v56h64v-56c0-4.4 3.6-8 8-8h16c4.4 0 8 3.6 8 8v56h77.7c9.7 0 17.1-8.6 15.7-18.2l-9.4-66.2c-1.7-11.7 3.8-23 13.5-29.9C475.1 356.6 512 294.1 512 224 512 100.3 397.4 0 256 0zm-96 320c-35.3 0-64-28.7-64-64s28.7-64 64-64 64 28.7 64 64-28.7 64-64 64zm192 0c-35.3 0-64-28.7-64-64s28.7-64 64-64 64 28.7 64 64-28.7 64-64 64z"]},Cp={prefix:"fas",iconName:"skull-crossbones",icon:[448,512,[],"f714","M439.15 453.06L297.17 384l141.99-69.06c7.9-3.95 11.11-13.56 7.15-21.46L432 264.85c-3.95-7.9-13.56-11.11-21.47-7.16L224 348.41 37.47 257.69c-7.9-3.95-17.51-.75-21.47 7.16L1.69 293.48c-3.95 7.9-.75 17.51 7.15 21.46L150.83 384 8.85 453.06c-7.9 3.95-11.11 13.56-7.15 21.47l14.31 28.63c3.95 7.9 13.56 11.11 21.47 7.15L224 419.59l186.53 90.72c7.9 3.95 17.51.75 21.47-7.15l14.31-28.63c3.95-7.91.74-17.52-7.16-21.47zM150 237.28l-5.48 25.87c-2.67 12.62 5.42 24.85 16.45 24.85h126.08c11.03 0 19.12-12.23 16.45-24.85l-5.5-25.87c41.78-22.41 70-62.75 70-109.28C368 57.31 303.53 0 224 0S80 57.31 80 128c0 46.53 28.22 86.87 70 109.28zM280 112c17.65 0 32 14.35 32 32s-14.35 32-32 32-32-14.35-32-32 14.35-32 32-32zm-112 0c17.65 0 32 14.35 32 32s-14.35 32-32 32-32-14.35-32-32 14.35-32 32-32z"]},yp={prefix:"fas",iconName:"slash",icon:[640,512,[],"f715","M594.53 508.63L6.18 53.9c-6.97-5.42-8.23-15.47-2.81-22.45L23.01 6.18C28.43-.8 38.49-2.06 45.47 3.37L633.82 458.1c6.97 5.42 8.23 15.47 2.81 22.45l-19.64 25.27c-5.42 6.98-15.48 8.23-22.46 2.81z"]},wp={prefix:"fas",iconName:"sleigh",icon:[640,512,[],"f7cc","M612.7 350.7l-9.3-7.4c-6.9-5.5-17-4.4-22.5 2.5l-10 12.5c-5.5 6.9-4.4 17 2.5 22.5l9.3 7.4c5.9 4.7 9.2 11.7 9.2 19.2 0 13.6-11 24.6-24.6 24.6H48c-8.8 0-16 7.2-16 16v16c0 8.8 7.2 16 16 16h516c39 0 73.7-29.3 75.9-68.3 1.4-23.8-8.7-46.3-27.2-61zM32 224c0 59.6 40.9 109.2 96 123.5V400h64v-48h192v48h64v-48c53 0 96-43 96-96v-96c17.7 0 32-14.3 32-32s-14.3-32-32-32h-96v64c0 35.3-28.7 64-64 64h-20.7c-65.8 0-125.9-37.2-155.3-96-29.4-58.8-89.6-96-155.3-96H32C14.3 32 0 46.3 0 64s14.3 32 32 32v128z"]},Sp={prefix:"fas",iconName:"sliders-h",icon:[512,512,[],"f1de","M496 384H160v-16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v16H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h80v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16h336c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm0-160h-80v-16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v16H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h336v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16h80c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm0-160H288V48c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v16H16C7.2 64 0 71.2 0 80v32c0 8.8 7.2 16 16 16h208v16c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-16h208c8.8 0 16-7.2 16-16V80c0-8.8-7.2-16-16-16z"]},bp={prefix:"fas",iconName:"smile",icon:[496,512,[],"f118","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm80 168c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm-160 0c17.7 0 32 14.3 32 32s-14.3 32-32 32-32-14.3-32-32 14.3-32 32-32zm194.8 170.2C334.3 380.4 292.5 400 248 400s-86.3-19.6-114.8-53.8c-13.6-16.3 11-36.7 24.6-20.5 22.4 26.9 55.2 42.2 90.2 42.2s67.8-15.4 90.2-42.2c13.4-16.2 38.1 4.2 24.6 20.5z"]},Ep={prefix:"fas",iconName:"smile-beam",icon:[496,512,[],"f5b8","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM112 223.4c3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.7 8.6-10.8 11.9-14.9 4.5l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.3 7.4-15.8 4-15.1-4.5zm250.8 122.8C334.3 380.4 292.5 400 248 400s-86.3-19.6-114.8-53.8c-13.5-16.3 11-36.7 24.6-20.5 22.4 26.9 55.2 42.2 90.2 42.2s67.8-15.4 90.2-42.2c13.6-16.2 38.1 4.3 24.6 20.5zm6.2-118.3l-9.5-17c-7.7-13.7-19.2-21.6-31.5-21.6s-23.8 7.9-31.5 21.6l-9.5 17c-4.1 7.3-15.6 4-14.9-4.5 3.3-42.1 32.2-71.4 56-71.4s52.7 29.3 56 71.4c.6 8.6-11 11.9-15.1 4.5z"]},Ap={prefix:"fas",iconName:"smile-wink",icon:[496,512,[],"f4da","M0 256c0 137 111 248 248 248s248-111 248-248S385 8 248 8 0 119 0 256zm200-48c0 17.7-14.3 32-32 32s-32-14.3-32-32 14.3-32 32-32 32 14.3 32 32zm158.5 16.5c-14.8-13.2-46.2-13.2-61 0L288 233c-8.3 7.4-21.6.4-19.8-10.8 4-25.2 34.2-42.1 59.9-42.1S384 197 388 222.2c1.7 11.1-11.4 18.3-19.8 10.8l-9.7-8.5zM157.8 325.8C180.2 352.7 213 368 248 368s67.8-15.4 90.2-42.2c13.6-16.2 38.1 4.2 24.6 20.5C334.3 380.4 292.5 400 248 400s-86.3-19.6-114.8-53.8c-13.5-16.3 11.2-36.7 24.6-20.4z"]},Tp={prefix:"fas",iconName:"smog",icon:[640,512,[],"f75f","M624 368H80c-8.8 0-16 7.2-16 16v16c0 8.8 7.2 16 16 16h544c8.8 0 16-7.2 16-16v-16c0-8.8-7.2-16-16-16zm-480 96H16c-8.8 0-16 7.2-16 16v16c0 8.8 7.2 16 16 16h128c8.8 0 16-7.2 16-16v-16c0-8.8-7.2-16-16-16zm416 0H224c-8.8 0-16 7.2-16 16v16c0 8.8 7.2 16 16 16h336c8.8 0 16-7.2 16-16v-16c0-8.8-7.2-16-16-16zM144 288h156.1c22.5 19.7 51.6 32 83.9 32s61.3-12.3 83.9-32H528c61.9 0 112-50.1 112-112S589.9 64 528 64c-18 0-34.7 4.6-49.7 12.1C454 31 406.8 0 352 0c-41 0-77.8 17.3-104 44.8C221.8 17.3 185 0 144 0 64.5 0 0 64.5 0 144s64.5 144 144 144z"]},Mp={prefix:"fas",iconName:"smoking",icon:[640,512,[],"f48d","M632 352h-48c-4.4 0-8 3.6-8 8v144c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8zM553.3 87.1c-5.7-3.8-9.3-10-9.3-16.8V8c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v62.3c0 22 10.2 43.4 28.6 55.4 42.2 27.3 67.4 73.8 67.4 124V280c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-30.3c0-65.5-32.4-126.2-86.7-162.6zM432 352H48c-26.5 0-48 21.5-48 48v64c0 26.5 21.5 48 48 48h384c8.8 0 16-7.2 16-16V368c0-8.8-7.2-16-16-16zm-32 112H224v-64h176v64zm87.7-322.4C463.8 125 448 99.3 448 70.3V8c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v66.4c0 43.7 24.6 81.6 60.3 106.7 22.4 15.7 35.7 41.2 35.7 68.6V280c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-30.3c0-43.3-21-83.4-56.3-108.1zM536 352h-48c-4.4 0-8 3.6-8 8v144c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V360c0-4.4-3.6-8-8-8z"]},Rp={prefix:"fas",iconName:"smoking-ban",icon:[512,512,[],"f54d","M96 304c0 8.8 7.2 16 16 16h117.5l-96-96H112c-8.8 0-16 7.2-16 16v64zM256 0C114.6 0 0 114.6 0 256s114.6 256 256 256 256-114.6 256-256S397.4 0 256 0zm0 448c-105.9 0-192-86.1-192-192 0-41.4 13.3-79.7 35.7-111.1l267.4 267.4C335.7 434.7 297.4 448 256 448zm45.2-192H384v32h-50.8l-32-32zm111.1 111.1L365.2 320H400c8.8 0 16-7.2 16-16v-64c0-8.8-7.2-16-16-16H269.2L144.9 99.7C176.3 77.3 214.6 64 256 64c105.9 0 192 86.1 192 192 0 41.4-13.3 79.7-35.7 111.1zM320.6 128c-15.6 0-28.6-11.2-31.4-25.9-.7-3.6-4-6.1-7.7-6.1h-16.2c-5 0-8.7 4.5-8 9.4 4.6 30.9 31.2 54.6 63.3 54.6 15.6 0 28.6 11.2 31.4 25.9.7 3.6 4 6.1 7.7 6.1h16.2c5 0 8.7-4.5 8-9.4-4.6-30.9-31.2-54.6-63.3-54.6z"]},_p={prefix:"fas",iconName:"sms",icon:[512,512,[],"f7cd","M256 32C114.6 32 0 125.1 0 240c0 49.6 21.4 95 57 130.7C44.5 421.1 2.7 466 2.2 466.5c-2.2 2.3-2.8 5.7-1.5 8.7 1.3 3 4.1 4.8 7.3 4.8 66.3 0 116-31.8 140.6-51.4 32.7 12.3 69 19.4 107.4 19.4 141.4 0 256-93.1 256-208S397.4 32 256 32zM128.2 304H116c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h12.3c6 0 10.4-3.5 10.4-6.6 0-1.3-.8-2.7-2.1-3.8l-21.9-18.8c-8.5-7.2-13.3-17.5-13.3-28.1 0-21.3 19-38.6 42.4-38.6H156c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8h-12.3c-6 0-10.4 3.5-10.4 6.6 0 1.3.8 2.7 2.1 3.8l21.9 18.8c8.5 7.2 13.3 17.5 13.3 28.1.1 21.3-19 38.6-42.4 38.6zm191.8-8c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8v-68.2l-24.8 55.8c-2.9 5.9-11.4 5.9-14.3 0L224 227.8V296c0 4.4-3.6 8-8 8h-16c-4.4 0-8-3.6-8-8V192c0-8.8 7.2-16 16-16h16c6.1 0 11.6 3.4 14.3 8.8l17.7 35.4 17.7-35.4c2.7-5.4 8.3-8.8 14.3-8.8h16c8.8 0 16 7.2 16 16v104zm48.3 8H356c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h12.3c6 0 10.4-3.5 10.4-6.6 0-1.3-.8-2.7-2.1-3.8l-21.9-18.8c-8.5-7.2-13.3-17.5-13.3-28.1 0-21.3 19-38.6 42.4-38.6H396c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8h-12.3c-6 0-10.4 3.5-10.4 6.6 0 1.3.8 2.7 2.1 3.8l21.9 18.8c8.5 7.2 13.3 17.5 13.3 28.1.1 21.3-18.9 38.6-42.3 38.6z"]},Pp={prefix:"fas",iconName:"snowboarding",icon:[512,512,[],"f7ce","M432 96c26.5 0 48-21.5 48-48S458.5 0 432 0s-48 21.5-48 48 21.5 48 48 48zm28.8 153.6c5.8 4.3 12.5 6.4 19.2 6.4 9.7 0 19.3-4.4 25.6-12.8 10.6-14.1 7.8-34.2-6.4-44.8l-111.4-83.5c-13.8-10.3-29.1-18.4-45.4-23.8l-63.7-21.2-26.1-52.1C244.7 2 225.5-4.4 209.7 3.5c-15.8 7.9-22.2 27.1-14.3 42.9l29.1 58.1c5.7 11.4 15.6 19.9 27.7 24l16.4 5.5-41.2 20.6c-21.8 10.9-35.4 32.8-35.4 57.2v53.1l-74.1 24.7c-16.8 5.6-25.8 23.7-20.2 40.5 1.7 5.2 4.9 9.4 8.7 12.9l-38.7-14.1c-9.7-3.5-17.4-10.6-21.8-20-5.6-12-19.9-17.2-31.9-11.6s-17.2 19.9-11.6 31.9c9.8 21 27.1 36.9 48.9 44.8l364.8 132.7c9.7 3.5 19.7 5.3 29.7 5.3 12.5 0 24.9-2.7 36.5-8.2 12-5.6 17.2-19.9 11.6-31.9S474 454.7 462 460.3c-9.3 4.4-19.8 4.8-29.5 1.3l-90.8-33.1c8.7-4.1 15.6-11.8 17.8-21.9l21.9-102c3.9-18.2-3.2-37.2-18.1-48.4l-52-39 66-30.5 83.5 62.9zm-144.4 51.7l-19.7 92c-1.5 7.1-.1 13.9 2.8 20l-169.4-61.6c2.7-.2 5.4-.4 8-1.3l85-28.4c19.6-6.5 32.8-24.8 32.8-45.5V256l60.5 45.3z"]},xp={prefix:"fas",iconName:"snowflake",icon:[448,512,[],"f2dc","M440.3 345.2l-33.8-19.5 26-7c8.2-2.2 13.1-10.7 10.9-18.9l-4-14.9c-2.2-8.2-10.7-13.1-18.9-10.9l-70.8 19-63.9-37 63.8-36.9 70.8 19c8.2 2.2 16.7-2.7 18.9-10.9l4-14.9c2.2-8.2-2.7-16.7-10.9-18.9l-26-7 33.8-19.5c7.4-4.3 9.9-13.7 5.7-21.1L430.4 119c-4.3-7.4-13.7-9.9-21.1-5.7l-33.8 19.5 7-26c2.2-8.2-2.7-16.7-10.9-18.9l-14.9-4c-8.2-2.2-16.7 2.7-18.9 10.9l-19 70.8-62.8 36.2v-77.5l53.7-53.7c6.2-6.2 6.2-16.4 0-22.6l-11.3-11.3c-6.2-6.2-16.4-6.2-22.6 0L256 56.4V16c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v40.4l-19.7-19.7c-6.2-6.2-16.4-6.2-22.6 0L138.3 48c-6.3 6.2-6.3 16.4 0 22.6l53.7 53.7v77.5l-62.8-36.2-19-70.8c-2.2-8.2-10.7-13.1-18.9-10.9l-14.9 4c-8.2 2.2-13.1 10.7-10.9 18.9l7 26-33.8-19.5c-7.4-4.3-16.8-1.7-21.1 5.7L2.1 145.7c-4.3 7.4-1.7 16.8 5.7 21.1l33.8 19.5-26 7c-8.3 2.2-13.2 10.7-11 19l4 14.9c2.2 8.2 10.7 13.1 18.9 10.9l70.8-19 63.8 36.9-63.8 36.9-70.8-19c-8.2-2.2-16.7 2.7-18.9 10.9l-4 14.9c-2.2 8.2 2.7 16.7 10.9 18.9l26 7-33.8 19.6c-7.4 4.3-9.9 13.7-5.7 21.1l15.5 26.8c4.3 7.4 13.7 9.9 21.1 5.7l33.8-19.5-7 26c-2.2 8.2 2.7 16.7 10.9 18.9l14.9 4c8.2 2.2 16.7-2.7 18.9-10.9l19-70.8 62.8-36.2v77.5l-53.7 53.7c-6.3 6.2-6.3 16.4 0 22.6l11.3 11.3c6.2 6.2 16.4 6.2 22.6 0l19.7-19.7V496c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-40.4l19.7 19.7c6.2 6.2 16.4 6.2 22.6 0l11.3-11.3c6.2-6.2 6.2-16.4 0-22.6L256 387.7v-77.5l62.8 36.2 19 70.8c2.2 8.2 10.7 13.1 18.9 10.9l14.9-4c8.2-2.2 13.1-10.7 10.9-18.9l-7-26 33.8 19.5c7.4 4.3 16.8 1.7 21.1-5.7l15.5-26.8c4.3-7.3 1.8-16.8-5.6-21z"]},Dp={prefix:"fas",iconName:"snowman",icon:[512,512,[],"f7d0","M510.9 152.3l-5.9-14.5c-3.3-8-12.6-11.9-20.8-8.7L456 140.6v-29c0-8.6-7.2-15.6-16-15.6h-16c-8.8 0-16 7-16 15.6v46.9c0 .5.3 1 .3 1.5l-56.4 23c-5.9-10-13.3-18.9-22-26.6 13.6-16.6 22-37.4 22-60.5 0-53-43-96-96-96s-96 43-96 96c0 23.1 8.5 43.9 22 60.5-8.7 7.7-16 16.6-22 26.6l-56.4-23c.1-.5.3-1 .3-1.5v-46.9C104 103 96.8 96 88 96H72c-8.8 0-16 7-16 15.6v29l-28.1-11.5c-8.2-3.2-17.5.7-20.8 8.7l-5.9 14.5c-3.3 8 .7 17.1 8.9 20.3l135.2 55.2c-.4 4-1.2 8-1.2 12.2 0 10.1 1.7 19.6 4.2 28.9C120.9 296.4 104 334.2 104 376c0 54 28.4 100.9 70.8 127.8 9.3 5.9 20.3 8.2 31.3 8.2h99.2c13.3 0 26.3-4.1 37.2-11.7 46.5-32.3 74.4-89.4 62.9-152.6-5.5-30.2-20.5-57.6-41.6-79 2.5-9.2 4.2-18.7 4.2-28.7 0-4.2-.8-8.1-1.2-12.2L502 172.6c8.1-3.1 12.1-12.2 8.9-20.3zM224 96c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm32 272c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm0-64c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm0-64c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16zm0-88s-16-23.2-16-32 7.2-16 16-16 16 7.2 16 16-16 32-16 32zm32-56c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16z"]},Ip={prefix:"fas",iconName:"snowplow",icon:[640,512,[],"f7d2","M120 376c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zm80 0c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zm80 0c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zm80 0c-13.3 0-24 10.7-24 24s10.7 24 24 24 24-10.7 24-24-10.7-24-24-24zm238.6 49.4c-14.5-14.5-22.6-34.1-22.6-54.6V269.2c0-20.5 8.1-40.1 22.6-54.6l36.7-36.7c6.2-6.2 6.2-16.4 0-22.6l-22.6-22.6c-6.2-6.2-16.4-6.2-22.6 0l-36.7 36.7c-26.5 26.5-41.4 62.4-41.4 99.9V288h-64v-50.9c0-8.7-1.8-17.2-5.2-25.2L364.5 29.1C356.9 11.4 339.6 0 320.3 0H176c-26.5 0-48 21.5-48 48v112h-16c-26.5 0-48 21.5-48 48v91.2C26.3 317.2 0 355.4 0 400c0 61.9 50.1 112 112 112h256c61.9 0 112-50.1 112-112 0-17.3-4.2-33.4-11.2-48H512v18.7c0 37.5 14.9 73.4 41.4 99.9l36.7 36.7c6.2 6.2 16.4 6.2 22.6 0l22.6-22.6c6.2-6.2 6.2-16.4 0-22.6l-36.7-36.7zM192 64h117.8l68.6 160H256l-64-64V64zm176 384H112c-26.5 0-48-21.5-48-48s21.5-48 48-48h256c26.5 0 48 21.5 48 48s-21.5 48-48 48z"]},Lp={prefix:"fas",iconName:"soap",icon:[512,512,[],"e06e","M416,192a95.42,95.42,0,0,1-30.94,70.21A95.8,95.8,0,0,1,352,448H160a96,96,0,0,1,0-192h88.91A95.3,95.3,0,0,1,224,192H96A96,96,0,0,0,0,288V416a96,96,0,0,0,96,96H416a96,96,0,0,0,96-96V288A96,96,0,0,0,416,192Zm-96,64a64,64,0,1,0-64-64A64,64,0,0,0,320,256ZM208,96a48,48,0,1,0-48-48A48,48,0,0,0,208,96ZM384,64a32,32,0,1,0-32-32A32,32,0,0,0,384,64ZM160,288a64,64,0,0,0,0,128H352a64,64,0,0,0,0-128Z"]},Np={prefix:"fas",iconName:"socks",icon:[512,512,[],"f696","M214.66 311.01L288 256V96H128v176l-86.65 64.61c-39.4 29.56-53.86 84.42-29.21 127.06C30.39 495.25 63.27 512 96.08 512c20.03 0 40.25-6.25 57.52-19.2l21.86-16.39c-29.85-55.38-13.54-125.84 39.2-165.4zM288 32c0-11.05 3.07-21.3 8.02-30.38C293.4.92 290.85 0 288 0H160c-17.67 0-32 14.33-32 32v32h160V32zM480 0H352c-17.67 0-32 14.33-32 32v32h192V32c0-17.67-14.33-32-32-32zM320 272l-86.13 64.61c-39.4 29.56-53.86 84.42-29.21 127.06 18.25 31.58 50.61 48.33 83.42 48.33 20.03 0 40.25-6.25 57.52-19.2l115.2-86.4A127.997 127.997 0 0 0 512 304V96H320v176z"]},Op={prefix:"fas",iconName:"solar-panel",icon:[640,512,[],"f5ba","M431.98 448.01l-47.97.05V416h-128v32.21l-47.98.05c-8.82.01-15.97 7.16-15.98 15.99l-.05 31.73c-.01 8.85 7.17 16.03 16.02 16.02l223.96-.26c8.82-.01 15.97-7.16 15.98-15.98l.04-31.73c.01-8.85-7.17-16.03-16.02-16.02zM585.2 26.74C582.58 11.31 568.99 0 553.06 0H86.93C71 0 57.41 11.31 54.79 26.74-3.32 369.16.04 348.08.03 352c-.03 17.32 14.29 32 32.6 32h574.74c18.23 0 32.51-14.56 32.59-31.79.02-4.08 3.35 16.95-54.76-325.47zM259.83 64h120.33l9.77 96H250.06l9.77-96zm-75.17 256H71.09L90.1 208h105.97l-11.41 112zm16.29-160H98.24l16.29-96h96.19l-9.77 96zm32.82 160l11.4-112h149.65l11.4 112H233.77zm195.5-256h96.19l16.29 96H439.04l-9.77-96zm26.06 256l-11.4-112H549.9l19.01 112H455.33z"]},Fp={prefix:"fas",iconName:"sort",icon:[320,512,[],"f0dc","M41 288h238c21.4 0 32.1 25.9 17 41L177 448c-9.4 9.4-24.6 9.4-33.9 0L24 329c-15.1-15.1-4.4-41 17-41zm255-105L177 64c-9.4-9.4-24.6-9.4-33.9 0L24 183c-15.1 15.1-4.4 41 17 41h238c21.4 0 32.1-25.9 17-41z"]},kp={prefix:"fas",iconName:"sort-alpha-down",icon:[448,512,[],"f15d","M176 352h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.36 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352zm240-64H288a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h56l-61.26 70.45A32 32 0 0 0 272 446.37V464a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-56l61.26-70.45A32 32 0 0 0 432 321.63V304a16 16 0 0 0-16-16zm31.06-85.38l-59.27-160A16 16 0 0 0 372.72 32h-41.44a16 16 0 0 0-15.07 10.62l-59.27 160A16 16 0 0 0 272 224h24.83a16 16 0 0 0 15.23-11.08l4.42-12.92h71l4.41 12.92A16 16 0 0 0 407.16 224H432a16 16 0 0 0 15.06-21.38zM335.61 144L352 96l16.39 48z"]},Gp={prefix:"fas",iconName:"sort-alpha-down-alt",icon:[448,512,[],"f881","M176 352h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.36 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352zm112-128h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-56l61.26-70.45A32 32 0 0 0 432 65.63V48a16 16 0 0 0-16-16H288a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h56l-61.26 70.45A32 32 0 0 0 272 190.37V208a16 16 0 0 0 16 16zm159.06 234.62l-59.27-160A16 16 0 0 0 372.72 288h-41.44a16 16 0 0 0-15.07 10.62l-59.27 160A16 16 0 0 0 272 480h24.83a16 16 0 0 0 15.23-11.08l4.42-12.92h71l4.41 12.92A16 16 0 0 0 407.16 480H432a16 16 0 0 0 15.06-21.38zM335.61 400L352 352l16.39 48z"]},Vp={prefix:"fas",iconName:"sort-alpha-up",icon:[448,512,[],"f15e","M16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.38-17.24 11.31-27.31l-80-96a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.78 160 16 160zm400 128H288a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h56l-61.26 70.45A32 32 0 0 0 272 446.37V464a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-56l61.26-70.45A32 32 0 0 0 432 321.63V304a16 16 0 0 0-16-16zm31.06-85.38l-59.27-160A16 16 0 0 0 372.72 32h-41.44a16 16 0 0 0-15.07 10.62l-59.27 160A16 16 0 0 0 272 224h24.83a16 16 0 0 0 15.23-11.08l4.42-12.92h71l4.41 12.92A16 16 0 0 0 407.16 224H432a16 16 0 0 0 15.06-21.38zM335.61 144L352 96l16.39 48z"]},Hp={prefix:"fas",iconName:"sort-alpha-up-alt",icon:[448,512,[],"f882","M16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.38-17.24 11.31-27.31l-80-96a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.78 160 16 160zm272 64h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-56l61.26-70.45A32 32 0 0 0 432 65.63V48a16 16 0 0 0-16-16H288a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h56l-61.26 70.45A32 32 0 0 0 272 190.37V208a16 16 0 0 0 16 16zm159.06 234.62l-59.27-160A16 16 0 0 0 372.72 288h-41.44a16 16 0 0 0-15.07 10.62l-59.27 160A16 16 0 0 0 272 480h24.83a16 16 0 0 0 15.23-11.08l4.42-12.92h71l4.41 12.92A16 16 0 0 0 407.16 480H432a16 16 0 0 0 15.06-21.38zM335.61 400L352 352l16.39 48z"]},Bp={prefix:"fas",iconName:"sort-amount-down",icon:[512,512,[],"f160","M304 416h-64a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-128-64h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.37 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352zm256-192H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h192a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-64 128H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM496 32H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h256a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},zp={prefix:"fas",iconName:"sort-amount-down-alt",icon:[512,512,[],"f884","M240 96h64a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16h-64a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm0 128h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm256 192H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h256a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-256-64h192a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm-64 0h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.37 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352z"]},Up={prefix:"fas",iconName:"sort-amount-up",icon:[512,512,[],"f161","M304 416h-64a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h64a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.38-17.24 11.31-27.31l-80-96a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.77 160 16 160zm416 0H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h192a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-64 128H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM496 32H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h256a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Wp={prefix:"fas",iconName:"sort-amount-up-alt",icon:[512,512,[],"f885","M240 96h64a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16h-64a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm0 128h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm256 192H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h256a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-256-64h192a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H240a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zM16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.39-17.24 11.31-27.31l-80-96a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.78 160 16 160z"]},jp={prefix:"fas",iconName:"sort-down",icon:[320,512,[],"f0dd","M41 288h238c21.4 0 32.1 25.9 17 41L177 448c-9.4 9.4-24.6 9.4-33.9 0L24 329c-15.1-15.1-4.4-41 17-41z"]},Kp={prefix:"fas",iconName:"sort-numeric-down",icon:[448,512,[],"f162","M304 96h16v64h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-16V48a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 304 96zm26.15 162.91a79 79 0 0 0-55 54.17c-14.25 51.05 21.21 97.77 68.85 102.53a84.07 84.07 0 0 1-20.85 12.91c-7.57 3.4-10.8 12.47-8.18 20.34l9.9 20c2.87 8.63 12.53 13.49 20.9 9.91 58-24.76 86.25-61.61 86.25-132V336c-.02-51.21-48.4-91.34-101.85-77.09zM352 356a20 20 0 1 1 20-20 20 20 0 0 1-20 20zm-176-4h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.36 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352z"]},$p={prefix:"fas",iconName:"sort-numeric-down-alt",icon:[448,512,[],"f886","M176 352h-48V48a16 16 0 0 0-16-16H80a16 16 0 0 0-16 16v304H16c-14.19 0-21.36 17.24-11.29 27.31l80 96a16 16 0 0 0 22.62 0l80-96C197.35 369.26 190.22 352 176 352zm224 64h-16V304a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 304 352h16v64h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM330.17 34.91a79 79 0 0 0-55 54.17c-14.27 51.05 21.19 97.77 68.83 102.53a84.07 84.07 0 0 1-20.85 12.91c-7.57 3.4-10.8 12.47-8.18 20.34l9.9 20c2.87 8.63 12.53 13.49 20.9 9.91 58-24.77 86.25-61.61 86.25-132V112c-.02-51.21-48.4-91.34-101.85-77.09zM352 132a20 20 0 1 1 20-20 20 20 0 0 1-20 20z"]},qp={prefix:"fas",iconName:"sort-numeric-up",icon:[448,512,[],"f163","M330.17 258.91a79 79 0 0 0-55 54.17c-14.27 51.05 21.19 97.77 68.83 102.53a84.07 84.07 0 0 1-20.85 12.91c-7.57 3.4-10.8 12.47-8.18 20.34l9.9 20c2.87 8.63 12.53 13.49 20.9 9.91 58-24.76 86.25-61.61 86.25-132V336c-.02-51.21-48.4-91.34-101.85-77.09zM352 356a20 20 0 1 1 20-20 20 20 0 0 1-20 20zM304 96h16v64h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-16V48a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 304 96zM107.31 36.69a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.78 160 16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.38-17.24 11.31-27.31z"]},Yp={prefix:"fas",iconName:"sort-numeric-up-alt",icon:[448,512,[],"f887","M107.31 36.69a16 16 0 0 0-22.62 0l-80 96C-5.35 142.74 1.78 160 16 160h48v304a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V160h48c14.21 0 21.38-17.24 11.31-27.31zM400 416h-16V304a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 304 352h16v64h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM330.17 34.91a79 79 0 0 0-55 54.17c-14.27 51.05 21.19 97.77 68.83 102.53a84.07 84.07 0 0 1-20.85 12.91c-7.57 3.4-10.8 12.47-8.18 20.34l9.9 20c2.87 8.63 12.53 13.49 20.9 9.91 58-24.77 86.25-61.61 86.25-132V112c-.02-51.21-48.4-91.34-101.85-77.09zM352 132a20 20 0 1 1 20-20 20 20 0 0 1-20 20z"]},Qp={prefix:"fas",iconName:"sort-up",icon:[320,512,[],"f0de","M279 224H41c-21.4 0-32.1-25.9-17-41L143 64c9.4-9.4 24.6-9.4 33.9 0l119 119c15.2 15.1 4.5 41-16.9 41z"]},Xp={prefix:"fas",iconName:"spa",icon:[576,512,[],"f5bb","M568.25 192c-29.04.13-135.01 6.16-213.84 83-33.12 29.63-53.36 63.3-66.41 94.86-13.05-31.56-33.29-65.23-66.41-94.86-78.83-76.84-184.8-82.87-213.84-83-4.41-.02-7.79 3.4-7.75 7.82.23 27.92 7.14 126.14 88.77 199.3C172.79 480.94 256 480 288 480s115.19.95 199.23-80.88c81.64-73.17 88.54-171.38 88.77-199.3.04-4.42-3.34-7.84-7.75-7.82zM287.98 302.6c12.82-18.85 27.6-35.78 44.09-50.52 19.09-18.61 39.58-33.3 60.26-45.18-16.44-70.5-51.72-133.05-96.73-172.22-4.11-3.58-11.02-3.58-15.14 0-44.99 39.14-80.27 101.63-96.74 172.07 20.37 11.7 40.5 26.14 59.22 44.39a282.768 282.768 0 0 1 45.04 51.46z"]},Zp={prefix:"fas",iconName:"space-shuttle",icon:[640,512,[],"f197","M592.604 208.244C559.735 192.836 515.777 184 472 184H186.327c-4.952-6.555-10.585-11.978-16.72-16H376C229.157 137.747 219.403 32 96.003 32H96v128H80V32c-26.51 0-48 28.654-48 64v64c-23.197 0-32 10.032-32 24v40c0 13.983 8.819 24 32 24v16c-23.197 0-32 10.032-32 24v40c0 13.983 8.819 24 32 24v64c0 35.346 21.49 64 48 64V352h16v128h.003c123.4 0 133.154-105.747 279.997-136H169.606c6.135-4.022 11.768-9.445 16.72-16H472c43.777 0 87.735-8.836 120.604-24.244C622.282 289.845 640 271.992 640 256s-17.718-33.845-47.396-47.756zM488 296a8 8 0 0 1-8-8v-64a8 8 0 0 1 8-8c31.909 0 31.942 80 0 80z"]},Jp={prefix:"fas",iconName:"spell-check",icon:[576,512,[],"f891","M272 256h91.36c43.2 0 82-32.2 84.51-75.34a79.82 79.82 0 0 0-25.26-63.07 79.81 79.81 0 0 0 9.06-44.91C427.9 30.57 389.3 0 347 0h-75a16 16 0 0 0-16 16v224a16 16 0 0 0 16 16zm40-200h40a24 24 0 0 1 0 48h-40zm0 96h56a24 24 0 0 1 0 48h-56zM155.12 22.25A32 32 0 0 0 124.64 0H99.36a32 32 0 0 0-30.48 22.25L.59 235.73A16 16 0 0 0 16 256h24.93a16 16 0 0 0 15.42-11.73L68.29 208h87.42l11.94 36.27A16 16 0 0 0 183.07 256H208a16 16 0 0 0 15.42-20.27zM89.37 144L112 75.3l22.63 68.7zm482 132.48l-45.21-45.3a15.88 15.88 0 0 0-22.59 0l-151.5 151.5-55.41-55.5a15.88 15.88 0 0 0-22.59 0l-45.3 45.3a16 16 0 0 0 0 22.59l112 112.21a15.89 15.89 0 0 0 22.6 0l208-208.21a16 16 0 0 0-.02-22.59z"]},eg={prefix:"fas",iconName:"spider",icon:[576,512,[],"f717","M151.17 167.35L177.1 176h4.67l5.22-26.12c.72-3.58 1.8-7.58 3.21-11.79l-20.29-40.58 23.8-71.39c2.79-8.38-1.73-17.44-10.12-20.24L168.42.82c-8.38-2.8-17.45 1.73-20.24 10.12l-25.89 77.68a32.04 32.04 0 0 0 1.73 24.43l27.15 54.3zm422.14 182.03l-52.75-79.12a32.002 32.002 0 0 0-26.62-14.25H416l68.99-24.36a32.03 32.03 0 0 0 16.51-12.61l53.6-80.41c4.9-7.35 2.91-17.29-4.44-22.19l-13.31-8.88c-7.35-4.9-17.29-2.91-22.19 4.44l-50.56 75.83L404.1 208H368l-10.37-51.85C355.44 145.18 340.26 96 288 96c-52.26 0-67.44 49.18-69.63 60.15L208 208h-36.1l-60.49-20.17L60.84 112c-4.9-7.35-14.83-9.34-22.19-4.44l-13.31 8.88c-7.35 4.9-9.34 14.83-4.44 22.19l53.6 80.41a32.03 32.03 0 0 0 16.51 12.61L160 256H82.06a32.02 32.02 0 0 0-26.63 14.25L2.69 349.38c-4.9 7.35-2.92 17.29 4.44 22.19l13.31 8.88c7.35 4.9 17.29 2.91 22.19-4.44l48-72h47.06l-60.83 97.33A31.988 31.988 0 0 0 72 418.3V496c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-73.11l74.08-118.53c-1.01 14.05-2.08 28.11-2.08 42.21C192 399.64 232.76 448 288 448s96-48.36 96-101.43c0-14.1-1.08-28.16-2.08-42.21L456 422.89V496c0 8.84 7.16 16 16 16h16c8.84 0 16-7.16 16-16v-77.71c0-6-1.69-11.88-4.86-16.96L438.31 304h47.06l48 72c4.9 7.35 14.84 9.34 22.19 4.44l13.31-8.88c7.36-4.9 9.34-14.83 4.44-22.18zM406.09 97.51l-20.29 40.58c1.41 4.21 2.49 8.21 3.21 11.79l5.22 26.12h4.67l25.93-8.65 27.15-54.3a31.995 31.995 0 0 0 1.73-24.43l-25.89-77.68C425.03 2.56 415.96-1.98 407.58.82l-15.17 5.06c-8.38 2.8-12.91 11.86-10.12 20.24l23.8 71.39z"]},tg={prefix:"fas",iconName:"spinner",icon:[512,512,[],"f110","M304 48c0 26.51-21.49 48-48 48s-48-21.49-48-48 21.49-48 48-48 48 21.49 48 48zm-48 368c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48zm208-208c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48zM96 256c0-26.51-21.49-48-48-48S0 229.49 0 256s21.49 48 48 48 48-21.49 48-48zm12.922 99.078c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48c0-26.509-21.491-48-48-48zm294.156 0c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48c0-26.509-21.49-48-48-48zM108.922 60.922c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.491-48-48-48z"]},ig={prefix:"fas",iconName:"splotch",icon:[512,512,[],"f5bc","M472.29 195.89l-67.06-22.95c-19.28-6.6-33.54-20.92-38.14-38.3L351.1 74.19c-11.58-43.77-76.57-57.13-109.98-22.62l-46.14 47.67c-13.26 13.71-33.54 20.93-54.2 19.31l-71.88-5.62c-52.05-4.07-86.93 44.88-59.03 82.83l38.54 52.42c11.08 15.07 12.82 33.86 4.64 50.24L24.62 355.4c-20.59 41.25 22.84 84.87 73.49 73.81l69.96-15.28c20.11-4.39 41.45 0 57.07 11.73l54.32 40.83c39.32 29.56 101.04 7.57 104.45-37.22l4.7-61.86c1.35-17.79 12.8-33.86 30.63-42.99l62-31.74c44.88-22.96 39.59-80.17-8.95-96.79z"]},rg={prefix:"fas",iconName:"spray-can",icon:[512,512,[],"f5bd","M224 32c0-17.67-14.33-32-32-32h-64c-17.67 0-32 14.33-32 32v96h128V32zm256 96c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32zm-256 32H96c-53.02 0-96 42.98-96 96v224c0 17.67 14.33 32 32 32h256c17.67 0 32-14.33 32-32V256c0-53.02-42.98-96-96-96zm-64 256c-44.18 0-80-35.82-80-80s35.82-80 80-80 80 35.82 80 80-35.82 80-80 80zM480 96c17.67 0 32-14.33 32-32s-14.33-32-32-32-32 14.33-32 32 14.33 32 32 32zm-96 32c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32zm-96-96c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32zm96 0c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32zm96 192c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32z"]},ng={prefix:"fas",iconName:"square",icon:[448,512,[],"f0c8","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48z"]},sg={prefix:"fas",iconName:"square-full",icon:[512,512,[],"f45c","M512 512H0V0h512v512z"]},og={prefix:"fas",iconName:"square-root-alt",icon:[576,512,[],"f698","M571.31 251.31l-22.62-22.62c-6.25-6.25-16.38-6.25-22.63 0L480 274.75l-46.06-46.06c-6.25-6.25-16.38-6.25-22.63 0l-22.62 22.62c-6.25 6.25-6.25 16.38 0 22.63L434.75 320l-46.06 46.06c-6.25 6.25-6.25 16.38 0 22.63l22.62 22.62c6.25 6.25 16.38 6.25 22.63 0L480 365.25l46.06 46.06c6.25 6.25 16.38 6.25 22.63 0l22.62-22.62c6.25-6.25 6.25-16.38 0-22.63L525.25 320l46.06-46.06c6.25-6.25 6.25-16.38 0-22.63zM552 0H307.65c-14.54 0-27.26 9.8-30.95 23.87l-84.79 322.8-58.41-106.1A32.008 32.008 0 0 0 105.47 224H24c-13.25 0-24 10.74-24 24v48c0 13.25 10.75 24 24 24h43.62l88.88 163.73C168.99 503.5 186.3 512 204.94 512c17.27 0 44.44-9 54.28-41.48L357.03 96H552c13.25 0 24-10.75 24-24V24c0-13.26-10.75-24-24-24z"]},ag={prefix:"fas",iconName:"stamp",icon:[512,512,[],"f5bf","M32 512h448v-64H32v64zm384-256h-66.56c-16.26 0-29.44-13.18-29.44-29.44v-9.46c0-27.37 8.88-53.41 21.46-77.72 9.11-17.61 12.9-38.39 9.05-60.42-6.77-38.78-38.47-70.7-77.26-77.45C212.62-9.04 160 37.33 160 96c0 14.16 3.12 27.54 8.69 39.58C182.02 164.43 192 194.7 192 226.49v.07c0 16.26-13.18 29.44-29.44 29.44H96c-53.02 0-96 42.98-96 96v32c0 17.67 14.33 32 32 32h448c17.67 0 32-14.33 32-32v-32c0-53.02-42.98-96-96-96z"]},lg={prefix:"fas",iconName:"star",icon:[576,512,[],"f005","M259.3 17.8L194 150.2 47.9 171.5c-26.2 3.8-36.7 36.1-17.7 54.6l105.7 103-25 145.5c-4.5 26.3 23.2 46 46.4 33.7L288 439.6l130.7 68.7c23.2 12.2 50.9-7.4 46.4-33.7l-25-145.5 105.7-103c19-18.5 8.5-50.8-17.7-54.6L382 150.2 316.7 17.8c-11.7-23.6-45.6-23.9-57.4 0z"]},cg={prefix:"fas",iconName:"star-and-crescent",icon:[512,512,[],"f699","M340.47 466.36c-1.45 0-6.89.46-9.18.46-116.25 0-210.82-94.57-210.82-210.82S215.04 45.18 331.29 45.18c2.32 0 7.7.46 9.18.46 7.13 0 13.33-5.03 14.75-12.07 1.46-7.25-2.55-14.49-9.47-17.09C316.58 5.54 286.39 0 256 0 114.84 0 0 114.84 0 256s114.84 256 256 256c30.23 0 60.28-5.49 89.32-16.32 5.96-2.02 10.28-7.64 10.28-14.26 0-8.09-6.39-15.06-15.13-15.06zm162.99-252.5l-76.38-11.1-34.16-69.21c-1.83-3.7-5.38-5.55-8.93-5.55s-7.1 1.85-8.93 5.55l-34.16 69.21-76.38 11.1c-8.17 1.18-11.43 11.22-5.52 16.99l55.27 53.87-13.05 76.07c-1.11 6.44 4.01 11.66 9.81 11.66 1.53 0 3.11-.36 4.64-1.17L384 335.37l68.31 35.91c1.53.8 3.11 1.17 4.64 1.17 5.8 0 10.92-5.23 9.81-11.66l-13.05-76.07 55.27-53.87c5.91-5.77 2.65-15.81-5.52-16.99z"]},ug={prefix:"fas",iconName:"star-half",icon:[576,512,[],"f089","M288 0c-11.4 0-22.8 5.9-28.7 17.8L194 150.2 47.9 171.4c-26.2 3.8-36.7 36.1-17.7 54.6l105.7 103-25 145.5c-4.5 26.1 23 46 46.4 33.7L288 439.6V0z"]},hg={prefix:"fas",iconName:"star-half-alt",icon:[536,512,[],"f5c0","M508.55 171.51L362.18 150.2 296.77 17.81C290.89 5.98 279.42 0 267.95 0c-11.4 0-22.79 5.9-28.69 17.81l-65.43 132.38-146.38 21.29c-26.25 3.8-36.77 36.09-17.74 54.59l105.89 103-25.06 145.48C86.98 495.33 103.57 512 122.15 512c4.93 0 10-1.17 14.87-3.75l130.95-68.68 130.94 68.7c4.86 2.55 9.92 3.71 14.83 3.71 18.6 0 35.22-16.61 31.66-37.4l-25.03-145.49 105.91-102.98c19.04-18.5 8.52-50.8-17.73-54.6zm-121.74 123.2l-18.12 17.62 4.28 24.88 19.52 113.45-102.13-53.59-22.38-11.74.03-317.19 51.03 103.29 11.18 22.63 25.01 3.64 114.23 16.63-82.65 80.38z"]},dg={prefix:"fas",iconName:"star-of-david",icon:[464,512,[],"f69a","M405.68 256l53.21-89.39C473.3 142.4 455.48 112 426.88 112H319.96l-55.95-93.98C256.86 6.01 244.43 0 232 0s-24.86 6.01-32.01 18.02L144.04 112H37.11c-28.6 0-46.42 30.4-32.01 54.61L58.32 256 5.1 345.39C-9.31 369.6 8.51 400 37.11 400h106.93l55.95 93.98C207.14 505.99 219.57 512 232 512s24.86-6.01 32.01-18.02L319.96 400h106.93c28.6 0 46.42-30.4 32.01-54.61L405.68 256zm-12.78-88l-19.8 33.26L353.3 168h39.6zm-52.39 88l-52.39 88H175.88l-52.39-88 52.38-88h112.25l52.39 88zM232 73.72L254.79 112h-45.57L232 73.72zM71.1 168h39.6l-19.8 33.26L71.1 168zm0 176l19.8-33.26L110.7 344H71.1zM232 438.28L209.21 400h45.57L232 438.28zM353.29 344l19.8-33.26L392.9 344h-39.61z"]},pg={prefix:"fas",iconName:"star-of-life",icon:[480,512,[],"f621","M471.99 334.43L336.06 256l135.93-78.43c7.66-4.42 10.28-14.2 5.86-21.86l-32.02-55.43c-4.42-7.65-14.21-10.28-21.87-5.86l-135.93 78.43V16c0-8.84-7.17-16-16.01-16h-64.04c-8.84 0-16.01 7.16-16.01 16v156.86L56.04 94.43c-7.66-4.42-17.45-1.79-21.87 5.86L2.15 155.71c-4.42 7.65-1.8 17.44 5.86 21.86L143.94 256 8.01 334.43c-7.66 4.42-10.28 14.21-5.86 21.86l32.02 55.43c4.42 7.65 14.21 10.27 21.87 5.86l135.93-78.43V496c0 8.84 7.17 16 16.01 16h64.04c8.84 0 16.01-7.16 16.01-16V339.14l135.93 78.43c7.66 4.42 17.45 1.8 21.87-5.86l32.02-55.43c4.42-7.65 1.8-17.43-5.86-21.85z"]},gg={prefix:"fas",iconName:"step-backward",icon:[448,512,[],"f048","M64 468V44c0-6.6 5.4-12 12-12h48c6.6 0 12 5.4 12 12v176.4l195.5-181C352.1 22.3 384 36.6 384 64v384c0 27.4-31.9 41.7-52.5 24.6L136 292.7V468c0 6.6-5.4 12-12 12H76c-6.6 0-12-5.4-12-12z"]},fg={prefix:"fas",iconName:"step-forward",icon:[448,512,[],"f051","M384 44v424c0 6.6-5.4 12-12 12h-48c-6.6 0-12-5.4-12-12V291.6l-195.5 181C95.9 489.7 64 475.4 64 448V64c0-27.4 31.9-41.7 52.5-24.6L312 219.3V44c0-6.6 5.4-12 12-12h48c6.6 0 12 5.4 12 12z"]},mg={prefix:"fas",iconName:"stethoscope",icon:[512,512,[],"f0f1","M447.1 112c-34.2.5-62.3 28.4-63 62.6-.5 24.3 12.5 45.6 32 56.8V344c0 57.3-50.2 104-112 104-60 0-109.2-44.1-111.9-99.2C265 333.8 320 269.2 320 192V36.6c0-11.4-8.1-21.3-19.3-23.5L237.8.5c-13-2.6-25.6 5.8-28.2 18.8L206.4 35c-2.6 13 5.8 25.6 18.8 28.2l30.7 6.1v121.4c0 52.9-42.2 96.7-95.1 97.2-53.4.5-96.9-42.7-96.9-96V69.4l30.7-6.1c13-2.6 21.4-15.2 18.8-28.2l-3.1-15.7C107.7 6.4 95.1-2 82.1.6L19.3 13C8.1 15.3 0 25.1 0 36.6V192c0 77.3 55.1 142 128.1 156.8C130.7 439.2 208.6 512 304 512c97 0 176-75.4 176-168V231.4c19.1-11.1 32-31.7 32-55.4 0-35.7-29.2-64.5-64.9-64zm.9 80c-8.8 0-16-7.2-16-16s7.2-16 16-16 16 7.2 16 16-7.2 16-16 16z"]},vg={prefix:"fas",iconName:"sticky-note",icon:[448,512,[],"f249","M312 320h136V56c0-13.3-10.7-24-24-24H24C10.7 32 0 42.7 0 56v400c0 13.3 10.7 24 24 24h264V344c0-13.2 10.8-24 24-24zm129 55l-98 98c-4.5 4.5-10.6 7-17 7h-6V352h128v6.1c0 6.3-2.5 12.4-7 16.9z"]},Cg={prefix:"fas",iconName:"stop",icon:[448,512,[],"f04d","M400 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48z"]},yg={prefix:"fas",iconName:"stop-circle",icon:[512,512,[],"f28d","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm96 328c0 8.8-7.2 16-16 16H176c-8.8 0-16-7.2-16-16V176c0-8.8 7.2-16 16-16h160c8.8 0 16 7.2 16 16v160z"]},wg={prefix:"fas",iconName:"stopwatch",icon:[448,512,[],"f2f2","M432 304c0 114.9-93.1 208-208 208S16 418.9 16 304c0-104 76.3-190.2 176-205.5V64h-28c-6.6 0-12-5.4-12-12V12c0-6.6 5.4-12 12-12h120c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-28v34.5c37.5 5.8 71.7 21.6 99.7 44.6l27.5-27.5c4.7-4.7 12.3-4.7 17 0l28.3 28.3c4.7 4.7 4.7 12.3 0 17l-29.4 29.4-.6.6C419.7 223.3 432 262.2 432 304zm-176 36V188.5c0-6.6-5.4-12-12-12h-40c-6.6 0-12 5.4-12 12V340c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12z"]},Sg={prefix:"fas",iconName:"stopwatch-20",icon:[448,512,[],"e06f","M398.5,190.91l.59-.61,26.59-26.58a16,16,0,0,0,0-22.63L403,118.41a16,16,0,0,0-22.63,0l-24.68,24.68A206.68,206.68,0,0,0,256,98.5V64h32a16,16,0,0,0,16-16V16A16,16,0,0,0,288,0H160a16.05,16.05,0,0,0-16,16V48a16.05,16.05,0,0,0,16,16h32V98.5A207.92,207.92,0,0,0,16.09,297.57C12.64,411.5,106.76,510.22,220.72,512,337.13,513.77,432,420,432,304A206,206,0,0,0,398.5,190.91ZM204.37,377.55a8.2,8.2,0,0,1,8.32,8.07v22.31a8.2,8.2,0,0,1-8.32,8.07H121.52a16.46,16.46,0,0,1-16.61-17.62c2.78-35.22,14.67-57.41,38.45-91.37,20.42-29.19,27.1-37.32,27.1-62.34,0-16.92-1.79-24.27-12.21-24.27-9.39,0-12.69,7.4-12.69,22.68v5.23a8.2,8.2,0,0,1-8.33,8.07h-24.9a8.2,8.2,0,0,1-8.33-8.07v-4.07c0-27.3,8.48-60.24,56.43-60.24,43,0,55.57,25.85,55.57,61,0,35.58-12.44,51.21-34.35,81.31-11.56,15-24.61,35.57-26.41,51.2ZM344,352.32c0,35.16-12.3,63.68-57.23,63.68C243.19,416,232,386.48,232,352.55V247.22c0-40.73,19.58-63.22,56.2-63.22C325,184,344,206.64,344,245.3ZM287.87,221.73c-9.41,0-13.23,7.5-13.23,20V357.68c0,13.11,3.59,20.59,13.23,20.59s13-8,13-21.27V241.06C300.89,229.79,297.88,221.73,287.87,221.73Z"]},bg={prefix:"fas",iconName:"store",icon:[616,512,[],"f54e","M602 118.6L537.1 15C531.3 5.7 521 0 510 0H106C95 0 84.7 5.7 78.9 15L14 118.6c-33.5 53.5-3.8 127.9 58.8 136.4 4.5.6 9.1.9 13.7.9 29.6 0 55.8-13 73.8-33.1 18 20.1 44.3 33.1 73.8 33.1 29.6 0 55.8-13 73.8-33.1 18 20.1 44.3 33.1 73.8 33.1 29.6 0 55.8-13 73.8-33.1 18.1 20.1 44.3 33.1 73.8 33.1 4.7 0 9.2-.3 13.7-.9 62.8-8.4 92.6-82.8 59-136.4zM529.5 288c-10 0-19.9-1.5-29.5-3.8V384H116v-99.8c-9.6 2.2-19.5 3.8-29.5 3.8-6 0-12.1-.4-18-1.2-5.6-.8-11.1-2.1-16.4-3.6V480c0 17.7 14.3 32 32 32h448c17.7 0 32-14.3 32-32V283.2c-5.4 1.6-10.8 2.9-16.4 3.6-6.1.8-12.1 1.2-18.2 1.2z"]},Eg={prefix:"fas",iconName:"store-alt",icon:[640,512,[],"f54f","M320 384H128V224H64v256c0 17.7 14.3 32 32 32h256c17.7 0 32-14.3 32-32V224h-64v160zm314.6-241.8l-85.3-128c-6-8.9-16-14.2-26.7-14.2H117.4c-10.7 0-20.7 5.3-26.6 14.2l-85.3 128c-14.2 21.3 1 49.8 26.6 49.8H608c25.5 0 40.7-28.5 26.6-49.8zM512 496c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16V224h-64v272z"]},Ag={prefix:"fas",iconName:"store-alt-slash",icon:[640,512,[],"e070","M17.89,123.62,5.51,142.2c-14.2,21.3,1,49.8,26.59,49.8h74.26ZM576,413.42V224H512V364L384,265V224H330.92l-41.4-32H608c25.5,0,40.7-28.5,26.59-49.8l-85.29-128A32.18,32.18,0,0,0,522.6,0H117.42A31.87,31.87,0,0,0,90.81,14.2l-10.66,16L45.46,3.38A16,16,0,0,0,23,6.19L3.37,31.46A16,16,0,0,0,6.18,53.91L594.53,508.63A16,16,0,0,0,617,505.81l19.64-25.26a16,16,0,0,0-2.81-22.45ZM320,384H128V224H64V480a32,32,0,0,0,32,32H352a32,32,0,0,0,32-32V406.59l-64-49.47Z"]},Tg={prefix:"fas",iconName:"store-slash",icon:[640,512,[],"e071","M121.51,384V284.2a119.43,119.43,0,0,1-28,3.8,123.46,123.46,0,0,1-17.1-1.2,114.88,114.88,0,0,1-15.58-3.6V480c0,17.7,13.59,32,30.4,32H505.75L348.42,384Zm-28-128.09c25.1,0,47.29-10.72,64-27.24L24,120.05c-30.52,53.39-2.45,126.53,56.49,135A95.68,95.68,0,0,0,93.48,255.91ZM602.13,458.09,547.2,413.41V283.2a93.5,93.5,0,0,1-15.57,3.6,127.31,127.31,0,0,1-17.29,1.2,114.89,114.89,0,0,1-28-3.8v79.68L348.52,251.77a88.06,88.06,0,0,0,25.41,4.14c28.11,0,53-13,70.11-33.11,17.19,20.11,42.08,33.11,70.11,33.11a94.31,94.31,0,0,0,13-.91c59.66-8.41,88-82.8,56.06-136.4L521.55,15A30.1,30.1,0,0,0,495.81,0H112A30.11,30.11,0,0,0,86.27,15L76.88,30.78,43.19,3.38A14.68,14.68,0,0,0,21.86,6.19L3.2,31.45A16.58,16.58,0,0,0,5.87,53.91L564.81,508.63a14.69,14.69,0,0,0,21.33-2.82l18.66-25.26A16.58,16.58,0,0,0,602.13,458.09Z"]},Mg={prefix:"fas",iconName:"stream",icon:[512,512,[],"f550","M16 128h416c8.84 0 16-7.16 16-16V48c0-8.84-7.16-16-16-16H16C7.16 32 0 39.16 0 48v64c0 8.84 7.16 16 16 16zm480 80H80c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h416c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16zm-64 176H16c-8.84 0-16 7.16-16 16v64c0 8.84 7.16 16 16 16h416c8.84 0 16-7.16 16-16v-64c0-8.84-7.16-16-16-16z"]},Rg={prefix:"fas",iconName:"street-view",icon:[512,512,[],"f21d","M367.9 329.76c-4.62 5.3-9.78 10.1-15.9 13.65v22.94c66.52 9.34 112 28.05 112 49.65 0 30.93-93.12 56-208 56S48 446.93 48 416c0-21.6 45.48-40.3 112-49.65v-22.94c-6.12-3.55-11.28-8.35-15.9-13.65C58.87 345.34 0 378.05 0 416c0 53.02 114.62 96 256 96s256-42.98 256-96c0-37.95-58.87-70.66-144.1-86.24zM256 128c35.35 0 64-28.65 64-64S291.35 0 256 0s-64 28.65-64 64 28.65 64 64 64zm-64 192v96c0 17.67 14.33 32 32 32h64c17.67 0 32-14.33 32-32v-96c17.67 0 32-14.33 32-32v-96c0-26.51-21.49-48-48-48h-11.8c-11.07 5.03-23.26 8-36.2 8s-25.13-2.97-36.2-8H208c-26.51 0-48 21.49-48 48v96c0 17.67 14.33 32 32 32z"]},_g={prefix:"fas",iconName:"strikethrough",icon:[512,512,[],"f0cc","M496 224H293.9l-87.17-26.83A43.55 43.55 0 0 1 219.55 112h66.79A49.89 49.89 0 0 1 331 139.58a16 16 0 0 0 21.46 7.15l42.94-21.47a16 16 0 0 0 7.16-21.46l-.53-1A128 128 0 0 0 287.51 32h-68a123.68 123.68 0 0 0-123 135.64c2 20.89 10.1 39.83 21.78 56.36H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h480a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm-180.24 96A43 43 0 0 1 336 356.45 43.59 43.59 0 0 1 292.45 400h-66.79A49.89 49.89 0 0 1 181 372.42a16 16 0 0 0-21.46-7.15l-42.94 21.47a16 16 0 0 0-7.16 21.46l.53 1A128 128 0 0 0 224.49 480h68a123.68 123.68 0 0 0 123-135.64 114.25 114.25 0 0 0-5.34-24.36z"]},Pg={prefix:"fas",iconName:"stroopwafel",icon:[512,512,[],"f551","M188.12 210.74L142.86 256l45.25 45.25L233.37 256l-45.25-45.26zm113.13-22.62L256 142.86l-45.25 45.25L256 233.37l45.25-45.25zm-90.5 135.76L256 369.14l45.26-45.26L256 278.63l-45.25 45.25zM256 0C114.62 0 0 114.62 0 256s114.62 256 256 256 256-114.62 256-256S397.38 0 256 0zm186.68 295.6l-11.31 11.31c-3.12 3.12-8.19 3.12-11.31 0l-28.29-28.29-45.25 45.25 33.94 33.94 16.97-16.97c3.12-3.12 8.19-3.12 11.31 0l11.31 11.31c3.12 3.12 3.12 8.19 0 11.31l-16.97 16.97 16.97 16.97c3.12 3.12 3.12 8.19 0 11.31l-11.31 11.31c-3.12 3.12-8.19 3.12-11.31 0l-16.97-16.97-16.97 16.97c-3.12 3.12-8.19 3.12-11.31 0l-11.31-11.31c-3.12-3.12-3.12-8.19 0-11.31l16.97-16.97-33.94-33.94-45.26 45.26 28.29 28.29c3.12 3.12 3.12 8.19 0 11.31l-11.31 11.31c-3.12 3.12-8.19 3.12-11.31 0L256 414.39l-28.29 28.29c-3.12 3.12-8.19 3.12-11.31 0l-11.31-11.31c-3.12-3.12-3.12-8.19 0-11.31l28.29-28.29-45.25-45.26-33.94 33.94 16.97 16.97c3.12 3.12 3.12 8.19 0 11.31l-11.31 11.31c-3.12 3.12-8.19 3.12-11.31 0l-16.97-16.97-16.97 16.97c-3.12 3.12-8.19 3.12-11.31 0l-11.31-11.31c-3.12-3.12-3.12-8.19 0-11.31l16.97-16.97-16.97-16.97c-3.12-3.12-3.12-8.19 0-11.31l11.31-11.31c3.12-3.12 8.19-3.12 11.31 0l16.97 16.97 33.94-33.94-45.25-45.25-28.29 28.29c-3.12 3.12-8.19 3.12-11.31 0L69.32 295.6c-3.12-3.12-3.12-8.19 0-11.31L97.61 256l-28.29-28.29c-3.12-3.12-3.12-8.19 0-11.31l11.31-11.31c3.12-3.12 8.19-3.12 11.31 0l28.29 28.29 45.25-45.26-33.94-33.94-16.97 16.97c-3.12 3.12-8.19 3.12-11.31 0l-11.31-11.31c-3.12-3.12-3.12-8.19 0-11.31l16.97-16.97-16.97-16.97c-3.12-3.12-3.12-8.19 0-11.31l11.31-11.31c3.12-3.12 8.19-3.12 11.31 0l16.97 16.97 16.97-16.97c3.12-3.12 8.19-3.12 11.31 0l11.31 11.31c3.12 3.12 3.12 8.19 0 11.31l-16.97 16.97 33.94 33.94 45.26-45.25-28.29-28.29c-3.12-3.12-3.12-8.19 0-11.31l11.31-11.31c3.12-3.12 8.19-3.12 11.31 0L256 97.61l28.29-28.29c3.12-3.12 8.19-3.12 11.31 0l11.31 11.31c3.12 3.12 3.12 8.19 0 11.31l-28.29 28.29 45.26 45.25 33.94-33.94-16.97-16.97c-3.12-3.12-3.12-8.19 0-11.31l11.31-11.31c3.12-3.12 8.19-3.12 11.31 0l16.97 16.97 16.97-16.97c3.12-3.12 8.19-3.12 11.31 0l11.31 11.31c3.12 3.12 3.12 8.19 0 11.31l-16.97 16.97 16.97 16.97c3.12 3.12 3.12 8.19 0 11.31l-11.31 11.31c-3.12 3.12-8.19 3.12-11.31 0l-16.97-16.97-33.94 33.94 45.25 45.26 28.29-28.29c3.12-3.12 8.19-3.12 11.31 0l11.31 11.31c3.12 3.12 3.12 8.19 0 11.31L414.39 256l28.29 28.28a8.015 8.015 0 0 1 0 11.32zM278.63 256l45.26 45.25L369.14 256l-45.25-45.26L278.63 256z"]},xg={prefix:"fas",iconName:"subscript",icon:[512,512,[],"f12c","M496 448h-16V304a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 400 352h16v96h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM336 64h-67a16 16 0 0 0-13.14 6.87l-79.9 115-79.9-115A16 16 0 0 0 83 64H16A16 16 0 0 0 0 80v48a16 16 0 0 0 16 16h33.48l77.81 112-77.81 112H16a16 16 0 0 0-16 16v48a16 16 0 0 0 16 16h67a16 16 0 0 0 13.14-6.87l79.9-115 79.9 115A16 16 0 0 0 269 448h67a16 16 0 0 0 16-16v-48a16 16 0 0 0-16-16h-33.48l-77.81-112 77.81-112H336a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16z"]},Dg={prefix:"fas",iconName:"subway",icon:[448,512,[],"f239","M448 96v256c0 51.815-61.624 96-130.022 96l62.98 49.721C386.905 502.417 383.562 512 376 512H72c-7.578 0-10.892-9.594-4.957-14.279L130.022 448C61.82 448 0 403.954 0 352V96C0 42.981 64 0 128 0h192c65 0 128 42.981 128 96zM200 232V120c0-13.255-10.745-24-24-24H72c-13.255 0-24 10.745-24 24v112c0 13.255 10.745 24 24 24h104c13.255 0 24-10.745 24-24zm200 0V120c0-13.255-10.745-24-24-24H272c-13.255 0-24 10.745-24 24v112c0 13.255 10.745 24 24 24h104c13.255 0 24-10.745 24-24zm-48 56c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48zm-256 0c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48z"]},Ig={prefix:"fas",iconName:"suitcase",icon:[512,512,[],"f0f2","M128 480h256V80c0-26.5-21.5-48-48-48H176c-26.5 0-48 21.5-48 48v400zm64-384h128v32H192V96zm320 80v256c0 26.5-21.5 48-48 48h-48V128h48c26.5 0 48 21.5 48 48zM96 480H48c-26.5 0-48-21.5-48-48V176c0-26.5 21.5-48 48-48h48v352z"]},Lg={prefix:"fas",iconName:"suitcase-rolling",icon:[384,512,[],"f5c1","M336 160H48c-26.51 0-48 21.49-48 48v224c0 26.51 21.49 48 48 48h16v16c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-16h128v16c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-16h16c26.51 0 48-21.49 48-48V208c0-26.51-21.49-48-48-48zm-16 216c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h240c4.42 0 8 3.58 8 8v16zm0-96c0 4.42-3.58 8-8 8H72c-4.42 0-8-3.58-8-8v-16c0-4.42 3.58-8 8-8h240c4.42 0 8 3.58 8 8v16zM144 48h96v80h48V48c0-26.51-21.49-48-48-48h-96c-26.51 0-48 21.49-48 48v80h48V48z"]},Ng={prefix:"fas",iconName:"sun",icon:[512,512,[],"f185","M256 160c-52.9 0-96 43.1-96 96s43.1 96 96 96 96-43.1 96-96-43.1-96-96-96zm246.4 80.5l-94.7-47.3 33.5-100.4c4.5-13.6-8.4-26.5-21.9-21.9l-100.4 33.5-47.4-94.8c-6.4-12.8-24.6-12.8-31 0l-47.3 94.7L92.7 70.8c-13.6-4.5-26.5 8.4-21.9 21.9l33.5 100.4-94.7 47.4c-12.8 6.4-12.8 24.6 0 31l94.7 47.3-33.5 100.5c-4.5 13.6 8.4 26.5 21.9 21.9l100.4-33.5 47.3 94.7c6.4 12.8 24.6 12.8 31 0l47.3-94.7 100.4 33.5c13.6 4.5 26.5-8.4 21.9-21.9l-33.5-100.4 94.7-47.3c13-6.5 13-24.7.2-31.1zm-155.9 106c-49.9 49.9-131.1 49.9-181 0-49.9-49.9-49.9-131.1 0-181 49.9-49.9 131.1-49.9 181 0 49.9 49.9 49.9 131.1 0 181z"]},Og={prefix:"fas",iconName:"superscript",icon:[512,512,[],"f12b","M496 160h-16V16a16 16 0 0 0-16-16h-48a16 16 0 0 0-14.29 8.83l-16 32A16 16 0 0 0 400 64h16v96h-16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h96a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zM336 64h-67a16 16 0 0 0-13.14 6.87l-79.9 115-79.9-115A16 16 0 0 0 83 64H16A16 16 0 0 0 0 80v48a16 16 0 0 0 16 16h33.48l77.81 112-77.81 112H16a16 16 0 0 0-16 16v48a16 16 0 0 0 16 16h67a16 16 0 0 0 13.14-6.87l79.9-115 79.9 115A16 16 0 0 0 269 448h67a16 16 0 0 0 16-16v-48a16 16 0 0 0-16-16h-33.48l-77.81-112 77.81-112H336a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16z"]},Fg={prefix:"fas",iconName:"surprise",icon:[496,512,[],"f5c2","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zM136 208c0-17.7 14.3-32 32-32s32 14.3 32 32-14.3 32-32 32-32-14.3-32-32zm112 208c-35.3 0-64-28.7-64-64s28.7-64 64-64 64 28.7 64 64-28.7 64-64 64zm80-176c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},kg={prefix:"fas",iconName:"swatchbook",icon:[512,512,[],"f5c3","M434.66,167.71h0L344.5,77.36a31.83,31.83,0,0,0-45-.07h0l-.07.07L224,152.88V424L434.66,212.9A32,32,0,0,0,434.66,167.71ZM480,320H373.09L186.68,506.51c-2.06,2.07-4.5,3.58-6.68,5.49H480a32,32,0,0,0,32-32V352A32,32,0,0,0,480,320ZM192,32A32,32,0,0,0,160,0H32A32,32,0,0,0,0,32V416a96,96,0,0,0,192,0ZM96,440a24,24,0,1,1,24-24A24,24,0,0,1,96,440Zm32-184H64V192h64Zm0-128H64V64h64Z"]},Gg={prefix:"fas",iconName:"swimmer",icon:[640,512,[],"f5c4","M189.61 310.58c3.54 3.26 15.27 9.42 34.39 9.42s30.86-6.16 34.39-9.42c16.02-14.77 34.5-22.58 53.46-22.58h16.3c18.96 0 37.45 7.81 53.46 22.58 3.54 3.26 15.27 9.42 34.39 9.42s30.86-6.16 34.39-9.42c14.86-13.71 31.88-21.12 49.39-22.16l-112.84-80.6 18-12.86c3.64-2.58 8.28-3.52 12.62-2.61l100.35 21.53c25.91 5.53 51.44-10.97 57-36.88 5.55-25.92-10.95-51.44-36.88-57L437.68 98.47c-30.73-6.58-63.02.12-88.56 18.38l-80.02 57.17c-10.38 7.39-19.36 16.44-26.72 26.94L173.75 299c5.47 3.23 10.82 6.93 15.86 11.58zM624 352h-16c-26.04 0-45.8-8.42-56.09-17.9-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C461.8 343.58 442.04 352 416 352s-45.8-8.42-56.09-17.9c-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C269.8 343.58 250.04 352 224 352s-45.8-8.42-56.09-17.9c-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C77.8 343.58 58.04 352 32 352H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h16c38.62 0 72.72-12.19 96-31.84 23.28 19.66 57.38 31.84 96 31.84s72.72-12.19 96-31.84c23.28 19.66 57.38 31.84 96 31.84s72.72-12.19 96-31.84c23.28 19.66 57.38 31.84 96 31.84h16c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm-512-96c44.18 0 80-35.82 80-80s-35.82-80-80-80-80 35.82-80 80 35.82 80 80 80z"]},Vg={prefix:"fas",iconName:"swimming-pool",icon:[640,512,[],"f5c5","M624 416h-16c-26.04 0-45.8-8.42-56.09-17.9-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C461.8 407.58 442.04 416 416 416s-45.8-8.42-56.09-17.9c-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C269.8 407.58 250.04 416 224 416s-45.8-8.42-56.09-17.9c-8.9-8.21-19.66-14.1-31.77-14.1h-16.3c-12.11 0-22.87 5.89-31.77 14.1C77.8 407.58 58.04 416 32 416H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h16c38.62 0 72.72-12.19 96-31.84 23.28 19.66 57.38 31.84 96 31.84s72.72-12.19 96-31.84c23.28 19.66 57.38 31.84 96 31.84s72.72-12.19 96-31.84c23.28 19.66 57.38 31.84 96 31.84h16c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm-400-32v-96h192v96c19.12 0 30.86-6.16 34.39-9.42 9.17-8.46 19.2-14.34 29.61-18.07V128c0-17.64 14.36-32 32-32s32 14.36 32 32v16c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-16c0-52.94-43.06-96-96-96s-96 43.06-96 96v96H224v-96c0-17.64 14.36-32 32-32s32 14.36 32 32v16c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-16c0-52.94-43.06-96-96-96s-96 43.06-96 96v228.5c10.41 3.73 20.44 9.62 29.61 18.07 3.53 3.27 15.27 9.43 34.39 9.43z"]},Hg={prefix:"fas",iconName:"synagogue",icon:[640,512,[],"f69b","M70 196.51L6.67 268.29A26.643 26.643 0 0 0 0 285.93V512h128V239.58l-38-43.07c-5.31-6.01-14.69-6.01-20 0zm563.33 71.78L570 196.51c-5.31-6.02-14.69-6.02-20 0l-38 43.07V512h128V285.93c0-6.5-2.37-12.77-6.67-17.64zM339.99 7.01c-11.69-9.35-28.29-9.35-39.98 0l-128 102.4A32.005 32.005 0 0 0 160 134.4V512h96v-92.57c0-31.88 21.78-61.43 53.25-66.55C349.34 346.35 384 377.13 384 416v96h96V134.4c0-9.72-4.42-18.92-12.01-24.99l-128-102.4zm52.07 215.55c1.98 3.15-.29 7.24-4 7.24h-38.94L324 269.79c-1.85 2.95-6.15 2.95-8 0l-25.12-39.98h-38.94c-3.72 0-5.98-4.09-4-7.24l19.2-30.56-19.2-30.56c-1.98-3.15.29-7.24 4-7.24h38.94l25.12-40c1.85-2.95 6.15-2.95 8 0l25.12 39.98h38.95c3.71 0 5.98 4.09 4 7.24L372.87 192l19.19 30.56z"]},Bg={prefix:"fas",iconName:"sync",icon:[512,512,[],"f021","M440.65 12.57l4 82.77A247.16 247.16 0 0 0 255.83 8C134.73 8 33.91 94.92 12.29 209.82A12 12 0 0 0 24.09 224h49.05a12 12 0 0 0 11.67-9.26 175.91 175.91 0 0 1 317-56.94l-101.46-4.86a12 12 0 0 0-12.57 12v47.41a12 12 0 0 0 12 12H500a12 12 0 0 0 12-12V12a12 12 0 0 0-12-12h-47.37a12 12 0 0 0-11.98 12.57zM255.83 432a175.61 175.61 0 0 1-146-77.8l101.8 4.87a12 12 0 0 0 12.57-12v-47.4a12 12 0 0 0-12-12H12a12 12 0 0 0-12 12V500a12 12 0 0 0 12 12h47.35a12 12 0 0 0 12-12.6l-4.15-82.57A247.17 247.17 0 0 0 255.83 504c121.11 0 221.93-86.92 243.55-201.82a12 12 0 0 0-11.8-14.18h-49.05a12 12 0 0 0-11.67 9.26A175.86 175.86 0 0 1 255.83 432z"]},zg={prefix:"fas",iconName:"sync-alt",icon:[512,512,[],"f2f1","M370.72 133.28C339.458 104.008 298.888 87.962 255.848 88c-77.458.068-144.328 53.178-162.791 126.85-1.344 5.363-6.122 9.15-11.651 9.15H24.103c-7.498 0-13.194-6.807-11.807-14.176C33.933 94.924 134.813 8 256 8c66.448 0 126.791 26.136 171.315 68.685L463.03 40.97C478.149 25.851 504 36.559 504 57.941V192c0 13.255-10.745 24-24 24H345.941c-21.382 0-32.09-25.851-16.971-40.971l41.75-41.749zM32 296h134.059c21.382 0 32.09 25.851 16.971 40.971l-41.75 41.75c31.262 29.273 71.835 45.319 114.876 45.28 77.418-.07 144.315-53.144 162.787-126.849 1.344-5.363 6.122-9.15 11.651-9.15h57.304c7.498 0 13.194 6.807 11.807 14.176C478.067 417.076 377.187 504 256 504c-66.448 0-126.791-26.136-171.315-68.685L48.97 471.03C33.851 486.149 8 475.441 8 454.059V320c0-13.255 10.745-24 24-24z"]},Ug={prefix:"fas",iconName:"syringe",icon:[512,512,[],"f48e","M201.5 174.8l55.7 55.8c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0l-55.7-55.8-45.3 45.3 55.8 55.8c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0L111 265.2l-26.4 26.4c-17.3 17.3-25.6 41.1-23 65.4l7.1 63.6L2.3 487c-3.1 3.1-3.1 8.2 0 11.3l11.3 11.3c3.1 3.1 8.2 3.1 11.3 0l66.3-66.3 63.6 7.1c23.9 2.6 47.9-5.4 65.4-23l181.9-181.9-135.7-135.7-64.9 65zm308.2-93.3L430.5 2.3c-3.1-3.1-8.2-3.1-11.3 0l-11.3 11.3c-3.1 3.1-3.1 8.2 0 11.3l28.3 28.3-45.3 45.3-56.6-56.6-17-17c-3.1-3.1-8.2-3.1-11.3 0l-33.9 33.9c-3.1 3.1-3.1 8.2 0 11.3l17 17L424.8 223l17 17c3.1 3.1 8.2 3.1 11.3 0l33.9-34c3.1-3.1 3.1-8.2 0-11.3l-73.5-73.5 45.3-45.3 28.3 28.3c3.1 3.1 8.2 3.1 11.3 0l11.3-11.3c3.1-3.2 3.1-8.2 0-11.4z"]},Wg={prefix:"fas",iconName:"table",icon:[512,512,[],"f0ce","M464 32H48C21.49 32 0 53.49 0 80v352c0 26.51 21.49 48 48 48h416c26.51 0 48-21.49 48-48V80c0-26.51-21.49-48-48-48zM224 416H64v-96h160v96zm0-160H64v-96h160v96zm224 160H288v-96h160v96zm0-160H288v-96h160v96z"]},jg={prefix:"fas",iconName:"table-tennis",icon:[512,512,[],"f45d","M496.2 296.5C527.7 218.7 512 126.2 449 63.1 365.1-21 229-21 145.1 63.1l-56 56.1 211.5 211.5c46.1-62.1 131.5-77.4 195.6-34.2zm-217.9 79.7L57.9 155.9c-27.3 45.3-21.7 105 17.3 144.1l34.5 34.6L6.7 424c-8.6 7.5-9.1 20.7-1 28.8l53.4 53.5c8 8.1 21.2 7.6 28.7-1L177.1 402l35.7 35.7c19.7 19.7 44.6 30.5 70.3 33.3-7.1-17-11-35.6-11-55.1-.1-13.8 2.5-27 6.2-39.7zM416 320c-53 0-96 43-96 96s43 96 96 96 96-43 96-96-43-96-96-96z"]},Kg={prefix:"fas",iconName:"tablet",icon:[448,512,[],"f10a","M400 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM224 480c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32z"]},$g={prefix:"fas",iconName:"tablet-alt",icon:[448,512,[],"f3fa","M400 0H48C21.5 0 0 21.5 0 48v416c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V48c0-26.5-21.5-48-48-48zM224 480c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm176-108c0 6.6-5.4 12-12 12H60c-6.6 0-12-5.4-12-12V60c0-6.6 5.4-12 12-12h328c6.6 0 12 5.4 12 12v312z"]},qg={prefix:"fas",iconName:"tablets",icon:[640,512,[],"f490","M160 192C78.9 192 12.5 250.5.1 326.7c-.8 4.8 3.3 9.3 8.3 9.3h303.3c5 0 9.1-4.5 8.3-9.3C307.5 250.5 241.1 192 160 192zm151.6 176H8.4c-5 0-9.1 4.5-8.3 9.3C12.5 453.5 78.9 512 160 512s147.5-58.5 159.9-134.7c.8-4.8-3.3-9.3-8.3-9.3zM593.4 46.6c-56.5-56.5-144.2-61.4-206.9-16-4 2.9-4.3 8.9-.8 12.3L597 254.3c3.5 3.5 9.5 3.2 12.3-.8 45.5-62.7 40.6-150.4-15.9-206.9zM363 65.7c-3.5-3.5-9.5-3.2-12.3.8-45.4 62.7-40.5 150.4 15.9 206.9 56.5 56.5 144.2 61.4 206.9 15.9 4-2.9 4.3-8.9.8-12.3L363 65.7z"]},Yg={prefix:"fas",iconName:"tachometer-alt",icon:[576,512,[],"f3fd","M288 32C128.94 32 0 160.94 0 320c0 52.8 14.25 102.26 39.06 144.8 5.61 9.62 16.3 15.2 27.44 15.2h443c11.14 0 21.83-5.58 27.44-15.2C561.75 422.26 576 372.8 576 320c0-159.06-128.94-288-288-288zm0 64c14.71 0 26.58 10.13 30.32 23.65-1.11 2.26-2.64 4.23-3.45 6.67l-9.22 27.67c-5.13 3.49-10.97 6.01-17.64 6.01-17.67 0-32-14.33-32-32S270.33 96 288 96zM96 384c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm48-160c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm246.77-72.41l-61.33 184C343.13 347.33 352 364.54 352 384c0 11.72-3.38 22.55-8.88 32H232.88c-5.5-9.45-8.88-20.28-8.88-32 0-33.94 26.5-61.43 59.9-63.59l61.34-184.01c4.17-12.56 17.73-19.45 30.36-15.17 12.57 4.19 19.35 17.79 15.17 30.36zm14.66 57.2l15.52-46.55c3.47-1.29 7.13-2.23 11.05-2.23 17.67 0 32 14.33 32 32s-14.33 32-32 32c-11.38-.01-20.89-6.28-26.57-15.22zM480 384c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},Qg={prefix:"fas",iconName:"tag",icon:[512,512,[],"f02b","M0 252.118V48C0 21.49 21.49 0 48 0h204.118a48 48 0 0 1 33.941 14.059l211.882 211.882c18.745 18.745 18.745 49.137 0 67.882L293.823 497.941c-18.745 18.745-49.137 18.745-67.882 0L14.059 286.059A48 48 0 0 1 0 252.118zM112 64c-26.51 0-48 21.49-48 48s21.49 48 48 48 48-21.49 48-48-21.49-48-48-48z"]},Xg={prefix:"fas",iconName:"tags",icon:[640,512,[],"f02c","M497.941 225.941L286.059 14.059A48 48 0 0 0 252.118 0H48C21.49 0 0 21.49 0 48v204.118a48 48 0 0 0 14.059 33.941l211.882 211.882c18.744 18.745 49.136 18.746 67.882 0l204.118-204.118c18.745-18.745 18.745-49.137 0-67.882zM112 160c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm513.941 133.823L421.823 497.941c-18.745 18.745-49.137 18.745-67.882 0l-.36-.36L527.64 323.522c16.999-16.999 26.36-39.6 26.36-63.64s-9.362-46.641-26.36-63.64L331.397 0h48.721a48 48 0 0 1 33.941 14.059l211.882 211.882c18.745 18.745 18.745 49.137 0 67.882z"]},Zg={prefix:"fas",iconName:"tape",icon:[640,512,[],"f4db","M224 192c-35.3 0-64 28.7-64 64s28.7 64 64 64 64-28.7 64-64-28.7-64-64-64zm400 224H380.6c41.5-40.7 67.4-97.3 67.4-160 0-123.7-100.3-224-224-224S0 132.3 0 256s100.3 224 224 224h400c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm-400-64c-53 0-96-43-96-96s43-96 96-96 96 43 96 96-43 96-96 96z"]},Jg={prefix:"fas",iconName:"tasks",icon:[512,512,[],"f0ae","M139.61 35.5a12 12 0 0 0-17 0L58.93 98.81l-22.7-22.12a12 12 0 0 0-17 0L3.53 92.41a12 12 0 0 0 0 17l47.59 47.4a12.78 12.78 0 0 0 17.61 0l15.59-15.62L156.52 69a12.09 12.09 0 0 0 .09-17zm0 159.19a12 12 0 0 0-17 0l-63.68 63.72-22.7-22.1a12 12 0 0 0-17 0L3.53 252a12 12 0 0 0 0 17L51 316.5a12.77 12.77 0 0 0 17.6 0l15.7-15.69 72.2-72.22a12 12 0 0 0 .09-16.9zM64 368c-26.49 0-48.59 21.5-48.59 48S37.53 464 64 464a48 48 0 0 0 0-96zm432 16H208a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h288a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16zm0-320H208a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h288a16 16 0 0 0 16-16V80a16 16 0 0 0-16-16zm0 160H208a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h288a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},ef={prefix:"fas",iconName:"taxi",icon:[512,512,[],"f1ba","M462 241.64l-22-84.84c-9.6-35.2-41.6-60.8-76.8-60.8H352V64c0-17.67-14.33-32-32-32H192c-17.67 0-32 14.33-32 32v32h-11.2c-35.2 0-67.2 25.6-76.8 60.8l-22 84.84C21.41 248.04 0 273.47 0 304v48c0 23.63 12.95 44.04 32 55.12V448c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-32h256v32c0 17.67 14.33 32 32 32h32c17.67 0 32-14.33 32-32v-40.88c19.05-11.09 32-31.5 32-55.12v-48c0-30.53-21.41-55.96-50-62.36zM96 352c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm20.55-112l17.2-66.36c2.23-8.16 9.59-13.64 15.06-13.64h214.4c5.47 0 12.83 5.48 14.85 12.86L395.45 240h-278.9zM416 352c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},tf={prefix:"fas",iconName:"teeth",icon:[640,512,[],"f62e","M544 0H96C42.98 0 0 42.98 0 96v320c0 53.02 42.98 96 96 96h448c53.02 0 96-42.98 96-96V96c0-53.02-42.98-96-96-96zM160 368c0 26.51-21.49 48-48 48s-48-21.49-48-48v-64c0-8.84 7.16-16 16-16h64c8.84 0 16 7.16 16 16v64zm0-128c0 8.84-7.16 16-16 16H80c-8.84 0-16-7.16-16-16v-64c0-26.51 21.49-48 48-48s48 21.49 48 48v64zm144 120c0 30.93-25.07 56-56 56s-56-25.07-56-56v-56c0-8.84 7.16-16 16-16h80c8.84 0 16 7.16 16 16v56zm0-120c0 8.84-7.16 16-16 16h-80c-8.84 0-16-7.16-16-16v-88c0-30.93 25.07-56 56-56s56 25.07 56 56v88zm144 120c0 30.93-25.07 56-56 56s-56-25.07-56-56v-56c0-8.84 7.16-16 16-16h80c8.84 0 16 7.16 16 16v56zm0-120c0 8.84-7.16 16-16 16h-80c-8.84 0-16-7.16-16-16v-88c0-30.93 25.07-56 56-56s56 25.07 56 56v88zm128 128c0 26.51-21.49 48-48 48s-48-21.49-48-48v-64c0-8.84 7.16-16 16-16h64c8.84 0 16 7.16 16 16v64zm0-128c0 8.84-7.16 16-16 16h-64c-8.84 0-16-7.16-16-16v-64c0-26.51 21.49-48 48-48s48 21.49 48 48v64z"]},rf={prefix:"fas",iconName:"teeth-open",icon:[640,512,[],"f62f","M544 0H96C42.98 0 0 42.98 0 96v64c0 35.35 28.66 64 64 64h512c35.34 0 64-28.65 64-64V96c0-53.02-42.98-96-96-96zM160 176c0 8.84-7.16 16-16 16H80c-8.84 0-16-7.16-16-16v-32c0-26.51 21.49-48 48-48s48 21.49 48 48v32zm144 0c0 8.84-7.16 16-16 16h-80c-8.84 0-16-7.16-16-16v-56c0-30.93 25.07-56 56-56s56 25.07 56 56v56zm144 0c0 8.84-7.16 16-16 16h-80c-8.84 0-16-7.16-16-16v-56c0-30.93 25.07-56 56-56s56 25.07 56 56v56zm128 0c0 8.84-7.16 16-16 16h-64c-8.84 0-16-7.16-16-16v-32c0-26.51 21.49-48 48-48s48 21.49 48 48v32zm0 144H64c-35.34 0-64 28.65-64 64v32c0 53.02 42.98 96 96 96h448c53.02 0 96-42.98 96-96v-32c0-35.35-28.66-64-64-64zm-416 80c0 26.51-21.49 48-48 48s-48-21.49-48-48v-32c0-8.84 7.16-16 16-16h64c8.84 0 16 7.16 16 16v32zm144-8c0 30.93-25.07 56-56 56s-56-25.07-56-56v-24c0-8.84 7.16-16 16-16h80c8.84 0 16 7.16 16 16v24zm144 0c0 30.93-25.07 56-56 56s-56-25.07-56-56v-24c0-8.84 7.16-16 16-16h80c8.84 0 16 7.16 16 16v24zm128 8c0 26.51-21.49 48-48 48s-48-21.49-48-48v-32c0-8.84 7.16-16 16-16h64c8.84 0 16 7.16 16 16v32z"]},nf={prefix:"fas",iconName:"temperature-high",icon:[512,512,[],"f769","M416 0c-52.9 0-96 43.1-96 96s43.1 96 96 96 96-43.1 96-96-43.1-96-96-96zm0 128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm-160-16C256 50.1 205.9 0 144 0S32 50.1 32 112v166.5C12.3 303.2 0 334 0 368c0 79.5 64.5 144 144 144s144-64.5 144-144c0-34-12.3-64.9-32-89.5V112zM144 448c-44.1 0-80-35.9-80-80 0-25.5 12.2-48.9 32-63.8V112c0-26.5 21.5-48 48-48s48 21.5 48 48v192.2c19.8 14.8 32 38.3 32 63.8 0 44.1-35.9 80-80 80zm16-125.1V112c0-8.8-7.2-16-16-16s-16 7.2-16 16v210.9c-18.6 6.6-32 24.2-32 45.1 0 26.5 21.5 48 48 48s48-21.5 48-48c0-20.9-13.4-38.5-32-45.1z"]},sf={prefix:"fas",iconName:"temperature-low",icon:[512,512,[],"f76b","M416 0c-52.9 0-96 43.1-96 96s43.1 96 96 96 96-43.1 96-96-43.1-96-96-96zm0 128c-17.7 0-32-14.3-32-32s14.3-32 32-32 32 14.3 32 32-14.3 32-32 32zm-160-16C256 50.1 205.9 0 144 0S32 50.1 32 112v166.5C12.3 303.2 0 334 0 368c0 79.5 64.5 144 144 144s144-64.5 144-144c0-34-12.3-64.9-32-89.5V112zM144 448c-44.1 0-80-35.9-80-80 0-25.5 12.2-48.9 32-63.8V112c0-26.5 21.5-48 48-48s48 21.5 48 48v192.2c19.8 14.8 32 38.3 32 63.8 0 44.1-35.9 80-80 80zm16-125.1V304c0-8.8-7.2-16-16-16s-16 7.2-16 16v18.9c-18.6 6.6-32 24.2-32 45.1 0 26.5 21.5 48 48 48s48-21.5 48-48c0-20.9-13.4-38.5-32-45.1z"]},of={prefix:"fas",iconName:"tenge",icon:[384,512,[],"f7d7","M372 160H12c-6.6 0-12 5.4-12 12v56c0 6.6 5.4 12 12 12h140v228c0 6.6 5.4 12 12 12h56c6.6 0 12-5.4 12-12V240h140c6.6 0 12-5.4 12-12v-56c0-6.6-5.4-12-12-12zm0-128H12C5.4 32 0 37.4 0 44v56c0 6.6 5.4 12 12 12h360c6.6 0 12-5.4 12-12V44c0-6.6-5.4-12-12-12z"]},af={prefix:"fas",iconName:"terminal",icon:[640,512,[],"f120","M257.981 272.971L63.638 467.314c-9.373 9.373-24.569 9.373-33.941 0L7.029 444.647c-9.357-9.357-9.375-24.522-.04-33.901L161.011 256 6.99 101.255c-9.335-9.379-9.317-24.544.04-33.901l22.667-22.667c9.373-9.373 24.569-9.373 33.941 0L257.981 239.03c9.373 9.372 9.373 24.568 0 33.941zM640 456v-32c0-13.255-10.745-24-24-24H312c-13.255 0-24 10.745-24 24v32c0 13.255 10.745 24 24 24h304c13.255 0 24-10.745 24-24z"]},lf={prefix:"fas",iconName:"text-height",icon:[576,512,[],"f034","M304 32H16A16 16 0 0 0 0 48v96a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-32h56v304H80a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h160a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-40V112h56v32a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zm256 336h-48V144h48c14.31 0 21.33-17.31 11.31-27.31l-80-80a16 16 0 0 0-22.62 0l-80 80C379.36 126 384.36 144 400 144h48v224h-48c-14.31 0-21.32 17.31-11.31 27.31l80 80a16 16 0 0 0 22.62 0l80-80C580.64 386 575.64 368 560 368z"]},cf={prefix:"fas",iconName:"text-width",icon:[448,512,[],"f035","M432 32H16A16 16 0 0 0 0 48v80a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16v-16h120v112h-24a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h128a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16h-24V112h120v16a16 16 0 0 0 16 16h32a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zm-68.69 260.69C354 283.36 336 288.36 336 304v48H112v-48c0-14.31-17.31-21.32-27.31-11.31l-80 80a16 16 0 0 0 0 22.62l80 80C94 484.64 112 479.64 112 464v-48h224v48c0 14.31 17.31 21.33 27.31 11.31l80-80a16 16 0 0 0 0-22.62z"]},uf={prefix:"fas",iconName:"th",icon:[512,512,[],"f00a","M149.333 56v80c0 13.255-10.745 24-24 24H24c-13.255 0-24-10.745-24-24V56c0-13.255 10.745-24 24-24h101.333c13.255 0 24 10.745 24 24zm181.334 240v-80c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24h101.333c13.256 0 24.001-10.745 24.001-24zm32-240v80c0 13.255 10.745 24 24 24H488c13.255 0 24-10.745 24-24V56c0-13.255-10.745-24-24-24H386.667c-13.255 0-24 10.745-24 24zm-32 80V56c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24h101.333c13.256 0 24.001-10.745 24.001-24zm-205.334 56H24c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24h101.333c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24zM0 376v80c0 13.255 10.745 24 24 24h101.333c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H24c-13.255 0-24 10.745-24 24zm386.667-56H488c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H386.667c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24zm0 160H488c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H386.667c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24zM181.333 376v80c0 13.255 10.745 24 24 24h101.333c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24z"]},hf={prefix:"fas",iconName:"th-large",icon:[512,512,[],"f009","M296 32h192c13.255 0 24 10.745 24 24v160c0 13.255-10.745 24-24 24H296c-13.255 0-24-10.745-24-24V56c0-13.255 10.745-24 24-24zm-80 0H24C10.745 32 0 42.745 0 56v160c0 13.255 10.745 24 24 24h192c13.255 0 24-10.745 24-24V56c0-13.255-10.745-24-24-24zM0 296v160c0 13.255 10.745 24 24 24h192c13.255 0 24-10.745 24-24V296c0-13.255-10.745-24-24-24H24c-13.255 0-24 10.745-24 24zm296 184h192c13.255 0 24-10.745 24-24V296c0-13.255-10.745-24-24-24H296c-13.255 0-24 10.745-24 24v160c0 13.255 10.745 24 24 24z"]},df={prefix:"fas",iconName:"th-list",icon:[512,512,[],"f00b","M149.333 216v80c0 13.255-10.745 24-24 24H24c-13.255 0-24-10.745-24-24v-80c0-13.255 10.745-24 24-24h101.333c13.255 0 24 10.745 24 24zM0 376v80c0 13.255 10.745 24 24 24h101.333c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H24c-13.255 0-24 10.745-24 24zM125.333 32H24C10.745 32 0 42.745 0 56v80c0 13.255 10.745 24 24 24h101.333c13.255 0 24-10.745 24-24V56c0-13.255-10.745-24-24-24zm80 448H488c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24zm-24-424v80c0 13.255 10.745 24 24 24H488c13.255 0 24-10.745 24-24V56c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24zm24 264H488c13.255 0 24-10.745 24-24v-80c0-13.255-10.745-24-24-24H205.333c-13.255 0-24 10.745-24 24v80c0 13.255 10.745 24 24 24z"]},pf={prefix:"fas",iconName:"theater-masks",icon:[640,512,[],"f630","M206.86 245.15c-35.88 10.45-59.95 41.2-57.53 74.1 11.4-12.72 28.81-23.7 49.9-30.92l7.63-43.18zM95.81 295L64.08 115.49c-.29-1.62.28-2.62.24-2.65 57.76-32.06 123.12-49.01 189.01-49.01 1.61 0 3.23.17 4.85.19 13.95-13.47 31.73-22.83 51.59-26 18.89-3.02 38.05-4.55 57.18-5.32-9.99-13.95-24.48-24.23-41.77-27C301.27 1.89 277.24 0 253.32 0 176.66 0 101.02 19.42 33.2 57.06 9.03 70.48-3.92 98.48 1.05 126.58l31.73 179.51c14.23 80.52 136.33 142.08 204.45 142.08 3.59 0 6.75-.46 10.01-.8-13.52-17.08-28.94-40.48-39.5-67.58-47.61-12.98-106.06-51.62-111.93-84.79zm97.55-137.46c-.73-4.12-2.23-7.87-4.07-11.4-8.25 8.91-20.67 15.75-35.32 18.32-14.65 2.58-28.67.4-39.48-5.17-.52 3.94-.64 7.98.09 12.1 3.84 21.7 24.58 36.19 46.34 32.37 21.75-3.82 36.28-24.52 32.44-46.22zM606.8 120.9c-88.98-49.38-191.43-67.41-291.98-51.35-27.31 4.36-49.08 26.26-54.04 54.36l-31.73 179.51c-15.39 87.05 95.28 196.27 158.31 207.35 63.03 11.09 204.47-53.79 219.86-140.84l31.73-179.51c4.97-28.11-7.98-56.11-32.15-69.52zm-273.24 96.8c3.84-21.7 24.58-36.19 46.34-32.36 21.76 3.83 36.28 24.52 32.45 46.22-.73 4.12-2.23 7.87-4.07 11.4-8.25-8.91-20.67-15.75-35.32-18.32-14.65-2.58-28.67-.4-39.48 5.17-.53-3.95-.65-7.99.08-12.11zm70.47 198.76c-55.68-9.79-93.52-59.27-89.04-112.9 20.6 25.54 56.21 46.17 99.49 53.78 43.28 7.61 83.82.37 111.93-16.6-14.18 51.94-66.71 85.51-122.38 75.72zm130.3-151.34c-8.25-8.91-20.68-15.75-35.33-18.32-14.65-2.58-28.67-.4-39.48 5.17-.52-3.94-.64-7.98.09-12.1 3.84-21.7 24.58-36.19 46.34-32.37 21.75 3.83 36.28 24.52 32.45 46.22-.73 4.13-2.23 7.88-4.07 11.4z"]},gf={prefix:"fas",iconName:"thermometer",icon:[512,512,[],"f491","M476.8 20.4c-37.5-30.7-95.5-26.3-131.9 10.2l-45.7 46 50.5 50.5c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0l-50.4-50.5-45.1 45.4 50.3 50.4c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0L209 167.4l-45.1 45.4L214 263c3.1 3.1 3.1 8.2 0 11.3l-11.3 11.3c-3.1 3.1-8.2 3.1-11.3 0l-50.1-50.2L96 281.1V382L7 471c-9.4 9.4-9.4 24.6 0 33.9 9.4 9.4 24.6 9.4 33.9 0l89-89h99.9L484 162.6c34.9-34.9 42.2-101.5-7.2-142.2z"]},ff={prefix:"fas",iconName:"thermometer-empty",icon:[256,512,[],"f2cb","M192 384c0 35.346-28.654 64-64 64s-64-28.654-64-64c0-35.346 28.654-64 64-64s64 28.654 64 64zm32-84.653c19.912 22.563 32 52.194 32 84.653 0 70.696-57.303 128-128 128-.299 0-.609-.001-.909-.003C56.789 511.509-.357 453.636.002 383.333.166 351.135 12.225 321.755 32 299.347V96c0-53.019 42.981-96 96-96s96 42.981 96 96v203.347zM208 384c0-34.339-19.37-52.19-32-66.502V96c0-26.467-21.533-48-48-48S80 69.533 80 96v221.498c-12.732 14.428-31.825 32.1-31.999 66.08-.224 43.876 35.563 80.116 79.423 80.42L128 464c44.112 0 80-35.888 80-80z"]},mf={prefix:"fas",iconName:"thermometer-full",icon:[256,512,[],"f2c7","M224 96c0-53.019-42.981-96-96-96S32 42.981 32 96v203.347C12.225 321.756.166 351.136.002 383.333c-.359 70.303 56.787 128.176 127.089 128.664.299.002.61.003.909.003 70.698 0 128-57.304 128-128 0-32.459-12.088-62.09-32-84.653V96zm-96 368l-.576-.002c-43.86-.304-79.647-36.544-79.423-80.42.173-33.98 19.266-51.652 31.999-66.08V96c0-26.467 21.533-48 48-48s48 21.533 48 48v221.498c12.63 14.312 32 32.164 32 66.502 0 44.112-35.888 80-80 80zm64-80c0 35.346-28.654 64-64 64s-64-28.654-64-64c0-23.685 12.876-44.349 32-55.417V96c0-17.673 14.327-32 32-32s32 14.327 32 32v232.583c19.124 11.068 32 31.732 32 55.417z"]},vf={prefix:"fas",iconName:"thermometer-half",icon:[256,512,[],"f2c9","M192 384c0 35.346-28.654 64-64 64s-64-28.654-64-64c0-23.685 12.876-44.349 32-55.417V224c0-17.673 14.327-32 32-32s32 14.327 32 32v104.583c19.124 11.068 32 31.732 32 55.417zm32-84.653c19.912 22.563 32 52.194 32 84.653 0 70.696-57.303 128-128 128-.299 0-.609-.001-.909-.003C56.789 511.509-.357 453.636.002 383.333.166 351.135 12.225 321.755 32 299.347V96c0-53.019 42.981-96 96-96s96 42.981 96 96v203.347zM208 384c0-34.339-19.37-52.19-32-66.502V96c0-26.467-21.533-48-48-48S80 69.533 80 96v221.498c-12.732 14.428-31.825 32.1-31.999 66.08-.224 43.876 35.563 80.116 79.423 80.42L128 464c44.112 0 80-35.888 80-80z"]},Cf={prefix:"fas",iconName:"thermometer-quarter",icon:[256,512,[],"f2ca","M192 384c0 35.346-28.654 64-64 64s-64-28.654-64-64c0-23.685 12.876-44.349 32-55.417V288c0-17.673 14.327-32 32-32s32 14.327 32 32v40.583c19.124 11.068 32 31.732 32 55.417zm32-84.653c19.912 22.563 32 52.194 32 84.653 0 70.696-57.303 128-128 128-.299 0-.609-.001-.909-.003C56.789 511.509-.357 453.636.002 383.333.166 351.135 12.225 321.755 32 299.347V96c0-53.019 42.981-96 96-96s96 42.981 96 96v203.347zM208 384c0-34.339-19.37-52.19-32-66.502V96c0-26.467-21.533-48-48-48S80 69.533 80 96v221.498c-12.732 14.428-31.825 32.1-31.999 66.08-.224 43.876 35.563 80.116 79.423 80.42L128 464c44.112 0 80-35.888 80-80z"]},yf={prefix:"fas",iconName:"thermometer-three-quarters",icon:[256,512,[],"f2c8","M192 384c0 35.346-28.654 64-64 64-35.346 0-64-28.654-64-64 0-23.685 12.876-44.349 32-55.417V160c0-17.673 14.327-32 32-32s32 14.327 32 32v168.583c19.124 11.068 32 31.732 32 55.417zm32-84.653c19.912 22.563 32 52.194 32 84.653 0 70.696-57.303 128-128 128-.299 0-.609-.001-.909-.003C56.789 511.509-.357 453.636.002 383.333.166 351.135 12.225 321.755 32 299.347V96c0-53.019 42.981-96 96-96s96 42.981 96 96v203.347zM208 384c0-34.339-19.37-52.19-32-66.502V96c0-26.467-21.533-48-48-48S80 69.533 80 96v221.498c-12.732 14.428-31.825 32.1-31.999 66.08-.224 43.876 35.563 80.116 79.423 80.42L128 464c44.112 0 80-35.888 80-80z"]},wf={prefix:"fas",iconName:"thumbs-down",icon:[512,512,[],"f165","M0 56v240c0 13.255 10.745 24 24 24h80c13.255 0 24-10.745 24-24V56c0-13.255-10.745-24-24-24H24C10.745 32 0 42.745 0 56zm40 200c0-13.255 10.745-24 24-24s24 10.745 24 24-10.745 24-24 24-24-10.745-24-24zm272 256c-20.183 0-29.485-39.293-33.931-57.795-5.206-21.666-10.589-44.07-25.393-58.902-32.469-32.524-49.503-73.967-89.117-113.111a11.98 11.98 0 0 1-3.558-8.521V59.901c0-6.541 5.243-11.878 11.783-11.998 15.831-.29 36.694-9.079 52.651-16.178C256.189 17.598 295.709.017 343.995 0h2.844c42.777 0 93.363.413 113.774 29.737 8.392 12.057 10.446 27.034 6.148 44.632 16.312 17.053 25.063 48.863 16.382 74.757 17.544 23.432 19.143 56.132 9.308 79.469l.11.11c11.893 11.949 19.523 31.259 19.439 49.197-.156 30.352-26.157 58.098-59.553 58.098H350.723C358.03 364.34 384 388.132 384 430.548 384 504 336 512 312 512z"]},Sf={prefix:"fas",iconName:"thumbs-up",icon:[512,512,[],"f164","M104 224H24c-13.255 0-24 10.745-24 24v240c0 13.255 10.745 24 24 24h80c13.255 0 24-10.745 24-24V248c0-13.255-10.745-24-24-24zM64 472c-13.255 0-24-10.745-24-24s10.745-24 24-24 24 10.745 24 24-10.745 24-24 24zM384 81.452c0 42.416-25.97 66.208-33.277 94.548h101.723c33.397 0 59.397 27.746 59.553 58.098.084 17.938-7.546 37.249-19.439 49.197l-.11.11c9.836 23.337 8.237 56.037-9.308 79.469 8.681 25.895-.069 57.704-16.382 74.757 4.298 17.598 2.244 32.575-6.148 44.632C440.202 511.587 389.616 512 346.839 512l-2.845-.001c-48.287-.017-87.806-17.598-119.56-31.725-15.957-7.099-36.821-15.887-52.651-16.178-6.54-.12-11.783-5.457-11.783-11.998v-213.77c0-3.2 1.282-6.271 3.558-8.521 39.614-39.144 56.648-80.587 89.117-113.111 14.804-14.832 20.188-37.236 25.393-58.902C282.515 39.293 291.817 0 312 0c24 0 72 8 72 81.452z"]},bf={prefix:"fas",iconName:"thumbtack",icon:[384,512,[],"f08d","M298.028 214.267L285.793 96H328c13.255 0 24-10.745 24-24V24c0-13.255-10.745-24-24-24H56C42.745 0 32 10.745 32 24v48c0 13.255 10.745 24 24 24h42.207L85.972 214.267C37.465 236.82 0 277.261 0 328c0 13.255 10.745 24 24 24h136v104.007c0 1.242.289 2.467.845 3.578l24 48c2.941 5.882 11.364 5.893 14.311 0l24-48a8.008 8.008 0 0 0 .845-3.578V352h136c13.255 0 24-10.745 24-24-.001-51.183-37.983-91.42-85.973-113.733z"]},Ef={prefix:"fas",iconName:"ticket-alt",icon:[576,512,[],"f3ff","M128 160h320v192H128V160zm400 96c0 26.51 21.49 48 48 48v96c0 26.51-21.49 48-48 48H48c-26.51 0-48-21.49-48-48v-96c26.51 0 48-21.49 48-48s-21.49-48-48-48v-96c0-26.51 21.49-48 48-48h480c26.51 0 48 21.49 48 48v96c-26.51 0-48 21.49-48 48zm-48-104c0-13.255-10.745-24-24-24H120c-13.255 0-24 10.745-24 24v208c0 13.255 10.745 24 24 24h336c13.255 0 24-10.745 24-24V152z"]},Af={prefix:"fas",iconName:"times",icon:[352,512,[],"f00d","M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"]},Tf={prefix:"fas",iconName:"times-circle",icon:[512,512,[],"f057","M256 8C119 8 8 119 8 256s111 248 248 248 248-111 248-248S393 8 256 8zm121.6 313.1c4.7 4.7 4.7 12.3 0 17L338 377.6c-4.7 4.7-12.3 4.7-17 0L256 312l-65.1 65.6c-4.7 4.7-12.3 4.7-17 0L134.4 338c-4.7-4.7-4.7-12.3 0-17l65.6-65-65.6-65.1c-4.7-4.7-4.7-12.3 0-17l39.6-39.6c4.7-4.7 12.3-4.7 17 0l65 65.7 65.1-65.6c4.7-4.7 12.3-4.7 17 0l39.6 39.6c4.7 4.7 4.7 12.3 0 17L312 256l65.6 65.1z"]},Mf={prefix:"fas",iconName:"tint",icon:[352,512,[],"f043","M205.22 22.09c-7.94-28.78-49.44-30.12-58.44 0C100.01 179.85 0 222.72 0 333.91 0 432.35 78.72 512 176 512s176-79.65 176-178.09c0-111.75-99.79-153.34-146.78-311.82zM176 448c-61.75 0-112-50.25-112-112 0-8.84 7.16-16 16-16s16 7.16 16 16c0 44.11 35.89 80 80 80 8.84 0 16 7.16 16 16s-7.16 16-16 16z"]},Rf={prefix:"fas",iconName:"tint-slash",icon:[640,512,[],"f5c7","M633.82 458.1L494.97 350.78c.52-5.57 1.03-11.16 1.03-16.87 0-111.76-99.79-153.34-146.78-311.82-7.94-28.78-49.44-30.12-58.44 0-15.52 52.34-36.87 91.96-58.49 125.68L45.47 3.37C38.49-2.05 28.43-.8 23.01 6.18L3.37 31.45C-2.05 38.42-.8 48.47 6.18 53.9l588.36 454.73c6.98 5.43 17.03 4.17 22.46-2.81l19.64-25.27c5.41-6.97 4.16-17.02-2.82-22.45zM144 333.91C144 432.35 222.72 512 320 512c44.71 0 85.37-16.96 116.4-44.7L162.72 255.78c-11.41 23.5-18.72 48.35-18.72 78.13z"]},_f={prefix:"fas",iconName:"tired",icon:[496,512,[],"f5c8","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm33.8 189.7l80-48c11.6-6.9 24 7.7 15.4 18L343.6 208l33.6 40.3c8.7 10.4-3.9 24.8-15.4 18l-80-48c-7.7-4.7-7.7-15.9 0-20.6zm-163-30c-8.6-10.3 3.8-24.9 15.4-18l80 48c7.8 4.7 7.8 15.9 0 20.6l-80 48c-11.5 6.8-24-7.6-15.4-18l33.6-40.3-33.6-40.3zM248 288c51.9 0 115.3 43.8 123.2 106.7 1.7 13.6-8 24.6-17.7 20.4-25.9-11.1-64.4-17.4-105.5-17.4s-79.6 6.3-105.5 17.4c-9.8 4.2-19.4-7-17.7-20.4C132.7 331.8 196.1 288 248 288z"]},Pf={prefix:"fas",iconName:"toggle-off",icon:[576,512,[],"f204","M384 64H192C85.961 64 0 149.961 0 256s85.961 192 192 192h192c106.039 0 192-85.961 192-192S490.039 64 384 64zM64 256c0-70.741 57.249-128 128-128 70.741 0 128 57.249 128 128 0 70.741-57.249 128-128 128-70.741 0-128-57.249-128-128zm320 128h-48.905c65.217-72.858 65.236-183.12 0-256H384c70.741 0 128 57.249 128 128 0 70.74-57.249 128-128 128z"]},xf={prefix:"fas",iconName:"toggle-on",icon:[576,512,[],"f205","M384 64H192C86 64 0 150 0 256s86 192 192 192h192c106 0 192-86 192-192S490 64 384 64zm0 320c-70.8 0-128-57.3-128-128 0-70.8 57.3-128 128-128 70.8 0 128 57.3 128 128 0 70.8-57.3 128-128 128z"]},Df={prefix:"fas",iconName:"toilet",icon:[384,512,[],"f7d8","M368 48c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16H16C7.2 0 0 7.2 0 16v16c0 8.8 7.2 16 16 16h16v156.7C11.8 214.8 0 226.9 0 240c0 67.2 34.6 126.2 86.8 160.5l-21.4 70.2C59.1 491.2 74.5 512 96 512h192c21.5 0 36.9-20.8 30.6-41.3l-21.4-70.2C349.4 366.2 384 307.2 384 240c0-13.1-11.8-25.2-32-35.3V48h16zM80 72c0-4.4 3.6-8 8-8h48c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H88c-4.4 0-8-3.6-8-8V72zm112 200c-77.1 0-139.6-14.3-139.6-32s62.5-32 139.6-32 139.6 14.3 139.6 32-62.5 32-139.6 32z"]},If={prefix:"fas",iconName:"toilet-paper",icon:[576,512,[],"f71e","M128 0C74.98 0 32 85.96 32 192v172.07c0 41.12-9.8 62.77-31.17 126.87C-2.62 501.3 5.09 512 16.01 512h280.92c13.77 0 26-8.81 30.36-21.88 12.83-38.48 24.71-72.4 24.71-126.05V192c0-83.6 23.67-153.52 60.44-192H128zM96 224c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16zm64 0c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16zm64 0c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16zm64 0c-8.84 0-16-7.16-16-16s7.16-16 16-16 16 7.16 16 16-7.16 16-16 16zM480 0c-53.02 0-96 85.96-96 192s42.98 192 96 192 96-85.96 96-192S533.02 0 480 0zm0 256c-17.67 0-32-28.65-32-64s14.33-64 32-64 32 28.65 32 64-14.33 64-32 64z"]},Lf={prefix:"fas",iconName:"toilet-paper-slash",icon:[640,512,[],"e072","M64,192V364.13c0,41.12-9.75,62.75-31.12,126.87A16,16,0,0,0,48,512H328.86a31.87,31.87,0,0,0,30.38-21.87c9.31-27.83,18-53.35,22.18-85.55l-316-244.25C64.53,170.66,64,181.19,64,192ZM633.82,458.09l-102-78.81C575.28,360.91,608,284.32,608,192,608,86,565,0,512,0s-96,86-96,192c0,42,7,80.4,18.43,112L384,265V192c0-83.62,23.63-153.5,60.5-192H160c-23.33,0-44.63,16.83-61.26,44.53L45.46,3.38A16,16,0,0,0,23,6.19L3.37,31.45A16,16,0,0,0,6.18,53.91L594.54,508.63A16,16,0,0,0,617,505.81l19.64-25.26A16,16,0,0,0,633.82,458.09ZM512,256c-17.63,0-32-28.62-32-64s14.37-64,32-64,32,28.63,32,64S529.62,256,512,256Z"]},Nf={prefix:"fas",iconName:"toolbox",icon:[512,512,[],"f552","M502.63 214.63l-45.25-45.25c-6-6-14.14-9.37-22.63-9.37H384V80c0-26.51-21.49-48-48-48H176c-26.51 0-48 21.49-48 48v80H77.25c-8.49 0-16.62 3.37-22.63 9.37L9.37 214.63c-6 6-9.37 14.14-9.37 22.63V320h128v-16c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v16h128v-16c0-8.84 7.16-16 16-16h32c8.84 0 16 7.16 16 16v16h128v-82.75c0-8.48-3.37-16.62-9.37-22.62zM320 160H192V96h128v64zm64 208c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16v-16H192v16c0 8.84-7.16 16-16 16h-32c-8.84 0-16-7.16-16-16v-16H0v96c0 17.67 14.33 32 32 32h448c17.67 0 32-14.33 32-32v-96H384v16z"]},Of={prefix:"fas",iconName:"tools",icon:[512,512,[],"f7d9","M501.1 395.7L384 278.6c-23.1-23.1-57.6-27.6-85.4-13.9L192 158.1V96L64 0 0 64l96 128h62.1l106.6 106.6c-13.6 27.8-9.2 62.3 13.9 85.4l117.1 117.1c14.6 14.6 38.2 14.6 52.7 0l52.7-52.7c14.5-14.6 14.5-38.2 0-52.7zM331.7 225c28.3 0 54.9 11 74.9 31l19.4 19.4c15.8-6.9 30.8-16.5 43.8-29.5 37.1-37.1 49.7-89.3 37.9-136.7-2.2-9-13.5-12.1-20.1-5.5l-74.4 74.4-67.9-11.3L334 98.9l74.4-74.4c6.6-6.6 3.4-17.9-5.7-20.2-47.4-11.7-99.6.9-136.6 37.9-28.5 28.5-41.9 66.1-41.2 103.6l82.1 82.1c8.1-1.9 16.5-2.9 24.7-2.9zm-103.9 82l-56.7-56.7L18.7 402.8c-25 25-25 65.5 0 90.5s65.5 25 90.5 0l123.6-123.6c-7.6-19.9-9.9-41.6-5-62.7zM64 472c-13.2 0-24-10.8-24-24 0-13.3 10.7-24 24-24s24 10.7 24 24c0 13.2-10.7 24-24 24z"]},Ff={prefix:"fas",iconName:"tooth",icon:[448,512,[],"f5c9","M443.98 96.25c-11.01-45.22-47.11-82.06-92.01-93.72-32.19-8.36-63 5.1-89.14 24.33-3.25 2.39-6.96 3.73-10.5 5.48l28.32 18.21c7.42 4.77 9.58 14.67 4.8 22.11-4.46 6.95-14.27 9.86-22.11 4.8L162.83 12.84c-20.7-10.85-43.38-16.4-66.81-10.31-44.9 11.67-81 48.5-92.01 93.72-10.13 41.62-.42 80.81 21.5 110.43 23.36 31.57 32.68 68.66 36.29 107.35 4.4 47.16 10.33 94.16 20.94 140.32l7.8 33.95c3.19 13.87 15.49 23.7 29.67 23.7 13.97 0 26.15-9.55 29.54-23.16l34.47-138.42c4.56-18.32 20.96-31.16 39.76-31.16s35.2 12.85 39.76 31.16l34.47 138.42c3.39 13.61 15.57 23.16 29.54 23.16 14.18 0 26.48-9.83 29.67-23.7l7.8-33.95c10.61-46.15 16.53-93.16 20.94-140.32 3.61-38.7 12.93-75.78 36.29-107.35 21.95-29.61 31.66-68.8 21.53-110.43z"]},kf={prefix:"fas",iconName:"torah",icon:[640,512,[],"f6a0","M320.05 366.48l17.72-29.64h-35.46zm99.21-166H382.4l18.46 30.82zM48 0C21.49 0 0 14.33 0 32v448c0 17.67 21.49 32 48 32s48-14.33 48-32V32C96 14.33 74.51 0 48 0zm172.74 311.5h36.85l-18.46-30.82zm161.71 0h36.86l-18.45-30.8zM128 464h384V48H128zm66.77-278.13a21.22 21.22 0 0 1 18.48-10.71h59.45l29.13-48.71a21.13 21.13 0 0 1 18.22-10.37A20.76 20.76 0 0 1 338 126.29l29.25 48.86h59.52a21.12 21.12 0 0 1 18.1 32L415.63 256 445 305a20.69 20.69 0 0 1 .24 21.12 21.25 21.25 0 0 1-18.48 10.72h-59.47l-29.13 48.7a21.13 21.13 0 0 1-18.16 10.4 20.79 20.79 0 0 1-18-10.22l-29.25-48.88h-59.5a21.11 21.11 0 0 1-18.1-32L224.36 256 195 207a20.7 20.7 0 0 1-.23-21.13zM592 0c-26.51 0-48 14.33-48 32v448c0 17.67 21.49 32 48 32s48-14.33 48-32V32c0-17.67-21.49-32-48-32zM320 145.53l-17.78 29.62h35.46zm-62.45 55h-36.81l18.44 30.8zm29.58 111h65.79L386.09 256l-33.23-55.52h-65.79L253.9 256z"]},Gf={prefix:"fas",iconName:"torii-gate",icon:[512,512,[],"f6a1","M376.45 32h-240.9A303.17 303.17 0 0 1 0 0v96c0 17.67 14.33 32 32 32h32v64H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h48v240c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16V256h256v240c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16V256h48c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16h-48v-64h32c17.67 0 32-14.33 32-32V0a303.17 303.17 0 0 1-135.55 32zM128 128h96v64h-96v-64zm256 64h-96v-64h96v64z"]},Vf={prefix:"fas",iconName:"tractor",icon:[640,512,[],"f722","M528 336c-48.6 0-88 39.4-88 88s39.4 88 88 88 88-39.4 88-88-39.4-88-88-88zm0 112c-13.23 0-24-10.77-24-24s10.77-24 24-24 24 10.77 24 24-10.77 24-24 24zm80-288h-64v-40.2c0-14.12 4.7-27.76 13.15-38.84 4.42-5.8 3.55-14.06-1.32-19.49L534.2 37.3c-6.66-7.45-18.32-6.92-24.7.78C490.58 60.9 480 89.81 480 119.8V160H377.67L321.58 29.14A47.914 47.914 0 0 0 277.45 0H144c-26.47 0-48 21.53-48 48v146.52c-8.63-6.73-20.96-6.46-28.89 1.47L36 227.1c-8.59 8.59-8.59 22.52 0 31.11l5.06 5.06c-4.99 9.26-8.96 18.82-11.91 28.72H22c-12.15 0-22 9.85-22 22v44c0 12.15 9.85 22 22 22h7.14c2.96 9.91 6.92 19.46 11.91 28.73l-5.06 5.06c-8.59 8.59-8.59 22.52 0 31.11L67.1 476c8.59 8.59 22.52 8.59 31.11 0l5.06-5.06c9.26 4.99 18.82 8.96 28.72 11.91V490c0 12.15 9.85 22 22 22h44c12.15 0 22-9.85 22-22v-7.14c9.9-2.95 19.46-6.92 28.72-11.91l5.06 5.06c8.59 8.59 22.52 8.59 31.11 0l31.11-31.11c8.59-8.59 8.59-22.52 0-31.11l-5.06-5.06c4.99-9.26 8.96-18.82 11.91-28.72H330c12.15 0 22-9.85 22-22v-6h80.54c21.91-28.99 56.32-48 95.46-48 18.64 0 36.07 4.61 51.8 12.2l50.82-50.82c6-6 9.37-14.14 9.37-22.63V192c.01-17.67-14.32-32-31.99-32zM176 416c-44.18 0-80-35.82-80-80s35.82-80 80-80 80 35.82 80 80-35.82 80-80 80zm22-256h-38V64h106.89l41.15 96H198z"]},Hf={prefix:"fas",iconName:"trademark",icon:[640,512,[],"f25c","M260.6 96H12c-6.6 0-12 5.4-12 12v43.1c0 6.6 5.4 12 12 12h85.1V404c0 6.6 5.4 12 12 12h54.3c6.6 0 12-5.4 12-12V163.1h85.1c6.6 0 12-5.4 12-12V108c.1-6.6-5.3-12-11.9-12zM640 403l-24-296c-.5-6.2-5.7-11-12-11h-65.4c-5.1 0-9.7 3.3-11.3 8.1l-43.8 127.1c-7.2 20.6-16.1 52.8-16.1 52.8h-.9s-8.9-32.2-16.1-52.8l-43.8-127.1c-1.7-4.8-6.2-8.1-11.3-8.1h-65.4c-6.2 0-11.4 4.8-12 11l-24.4 296c-.6 7 4.9 13 12 13H360c6.3 0 11.5-4.9 12-11.2l9.1-132.9c1.8-24.2 0-53.7 0-53.7h.9s10.7 33.6 17.9 53.7l30.7 84.7c1.7 4.7 6.2 7.9 11.3 7.9h50.3c5.1 0 9.6-3.2 11.3-7.9l30.7-84.7c7.2-20.1 17.9-53.7 17.9-53.7h.9s-1.8 29.5 0 53.7l9.1 132.9c.4 6.3 5.7 11.2 12 11.2H628c7 0 12.5-6 12-13z"]},Bf={prefix:"fas",iconName:"traffic-light",icon:[384,512,[],"f637","M384 192h-64v-37.88c37.2-13.22 64-48.38 64-90.12h-64V32c0-17.67-14.33-32-32-32H96C78.33 0 64 14.33 64 32v32H0c0 41.74 26.8 76.9 64 90.12V192H0c0 41.74 26.8 76.9 64 90.12V320H0c0 42.84 28.25 78.69 66.99 91.05C79.42 468.72 130.6 512 192 512s112.58-43.28 125.01-100.95C355.75 398.69 384 362.84 384 320h-64v-37.88c37.2-13.22 64-48.38 64-90.12zM192 416c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm0-128c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm0-128c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48z"]},zf={prefix:"fas",iconName:"trailer",icon:[640,512,[],"e041","M624,320H544V80a16,16,0,0,0-16-16H16A16,16,0,0,0,0,80V368a16,16,0,0,0,16,16H65.61c7.83-54.21,54-96,110.39-96s102.56,41.79,110.39,96H624a16,16,0,0,0,16-16V336A16,16,0,0,0,624,320ZM96,243.68a176.29,176.29,0,0,0-32,20.71V136a8,8,0,0,1,8-8H88a8,8,0,0,1,8,8Zm96-18.54c-5.31-.49-10.57-1.14-16-1.14s-10.69.65-16,1.14V136a8,8,0,0,1,8-8h16a8,8,0,0,1,8,8Zm96,39.25a176.29,176.29,0,0,0-32-20.71V136a8,8,0,0,1,8-8h16a8,8,0,0,1,8,8ZM384,320H352V136a8,8,0,0,1,8-8h16a8,8,0,0,1,8,8Zm96,0H448V136a8,8,0,0,1,8-8h16a8,8,0,0,1,8,8Zm-304,0a80,80,0,1,0,80,80A80,80,0,0,0,176,320Zm0,112a32,32,0,1,1,32-32A32,32,0,0,1,176,432Z"]},Uf={prefix:"fas",iconName:"train",icon:[448,512,[],"f238","M448 96v256c0 51.815-61.624 96-130.022 96l62.98 49.721C386.905 502.417 383.562 512 376 512H72c-7.578 0-10.892-9.594-4.957-14.279L130.022 448C61.82 448 0 403.954 0 352V96C0 42.981 64 0 128 0h192c65 0 128 42.981 128 96zm-48 136V120c0-13.255-10.745-24-24-24H72c-13.255 0-24 10.745-24 24v112c0 13.255 10.745 24 24 24h304c13.255 0 24-10.745 24-24zm-176 64c-30.928 0-56 25.072-56 56s25.072 56 56 56 56-25.072 56-56-25.072-56-56-56z"]},Wf={prefix:"fas",iconName:"tram",icon:[512,512,[],"f7da","M288 64c17.7 0 32-14.3 32-32S305.7 0 288 0s-32 14.3-32 32 14.3 32 32 32zm223.5-12.1c-2.3-8.6-11-13.6-19.6-11.3l-480 128c-8.5 2.3-13.6 11-11.3 19.6C2.5 195.3 8.9 200 16 200c1.4 0 2.8-.2 4.1-.5L240 140.8V224H64c-17.7 0-32 14.3-32 32v224c0 17.7 14.3 32 32 32h384c17.7 0 32-14.3 32-32V256c0-17.7-14.3-32-32-32H272v-91.7l228.1-60.8c8.6-2.3 13.6-11.1 11.4-19.6zM176 384H80v-96h96v96zm160-96h96v96h-96v-96zm-32 0v96h-96v-96h96zM192 96c17.7 0 32-14.3 32-32s-14.3-32-32-32-32 14.3-32 32 14.3 32 32 32z"]},jf={prefix:"fas",iconName:"transgender",icon:[384,512,[],"f224","M372 0h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-80.7 80.7C198.5 104.1 172.2 96 144 96 64.5 96 0 160.5 0 240c0 68.5 47.9 125.9 112 140.4V408H76c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v28c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-28h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-27.6c64.1-14.6 112-71.9 112-140.4 0-28.2-8.1-54.5-22.1-76.7l80.7-80.7 16.9 16.9c7.6 7.6 20.5 2.2 20.5-8.5V12c0-6.6-5.4-12-12-12zM144 320c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},Kf={prefix:"fas",iconName:"transgender-alt",icon:[480,512,[],"f225","M468 0h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-80.7 80.7C294.5 104.1 268.2 96 240 96c-28.2 0-54.5 8.1-76.7 22.1l-16.5-16.5 19.8-19.8c4.7-4.7 4.7-12.3 0-17l-28.3-28.3c-4.7-4.7-12.3-4.7-17 0l-19.8 19.8-19-19 16.9-16.9C107.1 12.9 101.7 0 91 0H12C5.4 0 0 5.4 0 12v79c0 10.7 12.9 16 20.5 8.5l16.9-16.9 19 19-19.8 19.8c-4.7 4.7-4.7 12.3 0 17l28.3 28.3c4.7 4.7 12.3 4.7 17 0l19.8-19.8 16.5 16.5C104.1 185.5 96 211.8 96 240c0 68.5 47.9 125.9 112 140.4V408h-36c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v28c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-28h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-27.6c64.1-14.6 112-71.9 112-140.4 0-28.2-8.1-54.5-22.1-76.7l80.7-80.7 16.9 16.9c7.6 7.6 20.5 2.2 20.5-8.5V12c0-6.6-5.4-12-12-12zM240 320c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},$f={prefix:"fas",iconName:"trash",icon:[448,512,[],"f1f8","M432 32H312l-9.4-18.7A24 24 0 0 0 281.1 0H166.8a23.72 23.72 0 0 0-21.4 13.3L136 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16zM53.2 467a48 48 0 0 0 47.9 45h245.8a48 48 0 0 0 47.9-45L416 128H32z"]},qf={prefix:"fas",iconName:"trash-alt",icon:[448,512,[],"f2ed","M32 464a48 48 0 0 0 48 48h288a48 48 0 0 0 48-48V128H32zm272-256a16 16 0 0 1 32 0v224a16 16 0 0 1-32 0zm-96 0a16 16 0 0 1 32 0v224a16 16 0 0 1-32 0zm-96 0a16 16 0 0 1 32 0v224a16 16 0 0 1-32 0zM432 32H312l-9.4-18.7A24 24 0 0 0 281.1 0H166.8a23.72 23.72 0 0 0-21.4 13.3L136 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Yf={prefix:"fas",iconName:"trash-restore",icon:[448,512,[],"f829","M53.2 467a48 48 0 0 0 47.9 45h245.8a48 48 0 0 0 47.9-45L416 128H32zm70.11-175.8l89.38-94.26a15.41 15.41 0 0 1 22.62 0l89.38 94.26c10.08 10.62 2.94 28.8-11.32 28.8H256v112a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16V320h-57.37c-14.26 0-21.4-18.18-11.32-28.8zM432 32H312l-9.4-18.7A24 24 0 0 0 281.1 0H166.8a23.72 23.72 0 0 0-21.4 13.3L136 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Qf={prefix:"fas",iconName:"trash-restore-alt",icon:[448,512,[],"f82a","M32 464a48 48 0 0 0 48 48h288a48 48 0 0 0 48-48V128H32zm91.31-172.8l89.38-94.26a15.41 15.41 0 0 1 22.62 0l89.38 94.26c10.08 10.62 2.94 28.8-11.32 28.8H256v112a16 16 0 0 1-16 16h-32a16 16 0 0 1-16-16V320h-57.37c-14.26 0-21.4-18.18-11.32-28.8zM432 32H312l-9.4-18.7A24 24 0 0 0 281.1 0H166.8a23.72 23.72 0 0 0-21.4 13.3L136 32H16A16 16 0 0 0 0 48v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16V48a16 16 0 0 0-16-16z"]},Xf={prefix:"fas",iconName:"tree",icon:[384,512,[],"f1bb","M378.31 378.49L298.42 288h30.63c9.01 0 16.98-5 20.78-13.06 3.8-8.04 2.55-17.26-3.28-24.05L268.42 160h28.89c9.1 0 17.3-5.35 20.86-13.61 3.52-8.13 1.86-17.59-4.24-24.08L203.66 4.83c-6.03-6.45-17.28-6.45-23.32 0L70.06 122.31c-6.1 6.49-7.75 15.95-4.24 24.08C69.38 154.65 77.59 160 86.69 160h28.89l-78.14 90.91c-5.81 6.78-7.06 15.99-3.27 24.04C37.97 283 45.93 288 54.95 288h30.63L5.69 378.49c-6 6.79-7.36 16.09-3.56 24.26 3.75 8.05 12 13.25 21.01 13.25H160v24.45l-30.29 48.4c-5.32 10.64 2.42 23.16 14.31 23.16h95.96c11.89 0 19.63-12.52 14.31-23.16L224 440.45V416h136.86c9.01 0 17.26-5.2 21.01-13.25 3.8-8.17 2.44-17.47-3.56-24.26z"]},Zf={prefix:"fas",iconName:"trophy",icon:[576,512,[],"f091","M552 64H448V24c0-13.3-10.7-24-24-24H152c-13.3 0-24 10.7-24 24v40H24C10.7 64 0 74.7 0 88v56c0 35.7 22.5 72.4 61.9 100.7 31.5 22.7 69.8 37.1 110 41.7C203.3 338.5 240 360 240 360v72h-48c-35.3 0-64 20.7-64 56v12c0 6.6 5.4 12 12 12h296c6.6 0 12-5.4 12-12v-12c0-35.3-28.7-56-64-56h-48v-72s36.7-21.5 68.1-73.6c40.3-4.6 78.6-19 110-41.7 39.3-28.3 61.9-65 61.9-100.7V88c0-13.3-10.7-24-24-24zM99.3 192.8C74.9 175.2 64 155.6 64 144v-16h64.2c1 32.6 5.8 61.2 12.8 86.2-15.1-5.2-29.2-12.4-41.7-21.4zM512 144c0 16.1-17.7 36.1-35.3 48.8-12.5 9-26.7 16.2-41.8 21.4 7-25 11.8-53.6 12.8-86.2H512v16z"]},Jf={prefix:"fas",iconName:"truck",icon:[640,512,[],"f0d1","M624 352h-16V243.9c0-12.7-5.1-24.9-14.1-33.9L494 110.1c-9-9-21.2-14.1-33.9-14.1H416V48c0-26.5-21.5-48-48-48H48C21.5 0 0 21.5 0 48v320c0 26.5 21.5 48 48 48h16c0 53 43 96 96 96s96-43 96-96h128c0 53 43 96 96 96s96-43 96-96h48c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM160 464c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm320 0c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48zm80-208H416V144h44.1l99.9 99.9V256z"]},em={prefix:"fas",iconName:"truck-loading",icon:[640,512,[],"f4de","M50.2 375.6c2.3 8.5 11.1 13.6 19.6 11.3l216.4-58c8.5-2.3 13.6-11.1 11.3-19.6l-49.7-185.5c-2.3-8.5-11.1-13.6-19.6-11.3L151 133.3l24.8 92.7-61.8 16.5-24.8-92.7-77.3 20.7C3.4 172.8-1.7 181.6.6 190.1l49.6 185.5zM384 0c-17.7 0-32 14.3-32 32v323.6L5.9 450c-4.3 1.2-6.8 5.6-5.6 9.8l12.6 46.3c1.2 4.3 5.6 6.8 9.8 5.6l393.7-107.4C418.8 464.1 467.6 512 528 512c61.9 0 112-50.1 112-112V0H384zm144 448c-26.5 0-48-21.5-48-48s21.5-48 48-48 48 21.5 48 48-21.5 48-48 48z"]},tm={prefix:"fas",iconName:"truck-monster",icon:[640,512,[],"f63b","M624 224h-16v-64c0-17.67-14.33-32-32-32h-73.6L419.22 24.02A64.025 64.025 0 0 0 369.24 0H256c-17.67 0-32 14.33-32 32v96H48c-8.84 0-16 7.16-16 16v80H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h16.72c29.21-38.65 75.1-64 127.28-64s98.07 25.35 127.28 64h65.45c29.21-38.65 75.1-64 127.28-64s98.07 25.35 127.28 64H624c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zm-336-96V64h81.24l51.2 64H288zm304 224h-5.2c-2.2-7.33-5.07-14.28-8.65-20.89l3.67-3.67c6.25-6.25 6.25-16.38 0-22.63l-22.63-22.63c-6.25-6.25-16.38-6.25-22.63 0l-3.67 3.67A110.85 110.85 0 0 0 512 277.2V272c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v5.2c-7.33 2.2-14.28 5.07-20.89 8.65l-3.67-3.67c-6.25-6.25-16.38-6.25-22.63 0l-22.63 22.63c-6.25 6.25-6.25 16.38 0 22.63l3.67 3.67A110.85 110.85 0 0 0 373.2 352H368c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h5.2c2.2 7.33 5.07 14.28 8.65 20.89l-3.67 3.67c-6.25 6.25-6.25 16.38 0 22.63l22.63 22.63c6.25 6.25 16.38 6.25 22.63 0l3.67-3.67c6.61 3.57 13.57 6.45 20.9 8.65v5.2c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-5.2c7.33-2.2 14.28-5.07 20.9-8.65l3.67 3.67c6.25 6.25 16.38 6.25 22.63 0l22.63-22.63c6.25-6.25 6.25-16.38 0-22.63l-3.67-3.67a110.85 110.85 0 0 0 8.65-20.89h5.2c8.84 0 16-7.16 16-16v-32c-.02-8.84-7.18-16-16.02-16zm-112 80c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48zm-208-80h-5.2c-2.2-7.33-5.07-14.28-8.65-20.89l3.67-3.67c6.25-6.25 6.25-16.38 0-22.63l-22.63-22.63c-6.25-6.25-16.38-6.25-22.63 0l-3.67 3.67A110.85 110.85 0 0 0 192 277.2V272c0-8.84-7.16-16-16-16h-32c-8.84 0-16 7.16-16 16v5.2c-7.33 2.2-14.28 5.07-20.89 8.65l-3.67-3.67c-6.25-6.25-16.38-6.25-22.63 0L58.18 304.8c-6.25 6.25-6.25 16.38 0 22.63l3.67 3.67a110.85 110.85 0 0 0-8.65 20.89H48c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h5.2c2.2 7.33 5.07 14.28 8.65 20.89l-3.67 3.67c-6.25 6.25-6.25 16.38 0 22.63l22.63 22.63c6.25 6.25 16.38 6.25 22.63 0l3.67-3.67c6.61 3.57 13.57 6.45 20.9 8.65v5.2c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-5.2c7.33-2.2 14.28-5.07 20.9-8.65l3.67 3.67c6.25 6.25 16.38 6.25 22.63 0l22.63-22.63c6.25-6.25 6.25-16.38 0-22.63l-3.67-3.67a110.85 110.85 0 0 0 8.65-20.89h5.2c8.84 0 16-7.16 16-16v-32C288 359.16 280.84 352 272 352zm-112 80c-26.51 0-48-21.49-48-48s21.49-48 48-48 48 21.49 48 48-21.49 48-48 48z"]},im={prefix:"fas",iconName:"truck-moving",icon:[640,512,[],"f4df","M621.3 237.3l-58.5-58.5c-12-12-28.3-18.7-45.3-18.7H480V64c0-17.7-14.3-32-32-32H32C14.3 32 0 46.3 0 64v336c0 44.2 35.8 80 80 80 26.3 0 49.4-12.9 64-32.4 14.6 19.6 37.7 32.4 64 32.4 44.2 0 80-35.8 80-80 0-5.5-.6-10.8-1.6-16h163.2c-1.1 5.2-1.6 10.5-1.6 16 0 44.2 35.8 80 80 80s80-35.8 80-80c0-5.5-.6-10.8-1.6-16H624c8.8 0 16-7.2 16-16v-85.5c0-17-6.7-33.2-18.7-45.2zM80 432c-17.6 0-32-14.4-32-32s14.4-32 32-32 32 14.4 32 32-14.4 32-32 32zm128 0c-17.6 0-32-14.4-32-32s14.4-32 32-32 32 14.4 32 32-14.4 32-32 32zm272-224h37.5c4.3 0 8.3 1.7 11.3 4.7l43.3 43.3H480v-48zm48 224c-17.6 0-32-14.4-32-32s14.4-32 32-32 32 14.4 32 32-14.4 32-32 32z"]},rm={prefix:"fas",iconName:"truck-pickup",icon:[640,512,[],"f63c","M624 288h-16v-64c0-17.67-14.33-32-32-32h-48L419.22 56.02A64.025 64.025 0 0 0 369.24 32H256c-17.67 0-32 14.33-32 32v128H64c-17.67 0-32 14.33-32 32v64H16c-8.84 0-16 7.16-16 16v32c0 8.84 7.16 16 16 16h49.61c-.76 5.27-1.61 10.52-1.61 16 0 61.86 50.14 112 112 112s112-50.14 112-112c0-5.48-.85-10.73-1.61-16h67.23c-.76 5.27-1.61 10.52-1.61 16 0 61.86 50.14 112 112 112s112-50.14 112-112c0-5.48-.85-10.73-1.61-16H624c8.84 0 16-7.16 16-16v-32c0-8.84-7.16-16-16-16zM288 96h81.24l76.8 96H288V96zM176 416c-26.47 0-48-21.53-48-48s21.53-48 48-48 48 21.53 48 48-21.53 48-48 48zm288 0c-26.47 0-48-21.53-48-48s21.53-48 48-48 48 21.53 48 48-21.53 48-48 48z"]},nm={prefix:"fas",iconName:"tshirt",icon:[640,512,[],"f553","M631.2 96.5L436.5 0C416.4 27.8 371.9 47.2 320 47.2S223.6 27.8 203.5 0L8.8 96.5c-7.9 4-11.1 13.6-7.2 21.5l57.2 114.5c4 7.9 13.6 11.1 21.5 7.2l56.6-27.7c10.6-5.2 23 2.5 23 14.4V480c0 17.7 14.3 32 32 32h256c17.7 0 32-14.3 32-32V226.3c0-11.8 12.4-19.6 23-14.4l56.6 27.7c7.9 4 17.5.8 21.5-7.2L638.3 118c4-7.9.8-17.6-7.1-21.5z"]},sm={prefix:"fas",iconName:"tty",icon:[512,512,[],"f1e4","M5.37 103.822c138.532-138.532 362.936-138.326 501.262 0 6.078 6.078 7.074 15.496 2.583 22.681l-43.214 69.138a18.332 18.332 0 0 1-22.356 7.305l-86.422-34.569a18.335 18.335 0 0 1-11.434-18.846L351.741 90c-62.145-22.454-130.636-21.986-191.483 0l5.953 59.532a18.331 18.331 0 0 1-11.434 18.846l-86.423 34.568a18.334 18.334 0 0 1-22.356-7.305L2.787 126.502a18.333 18.333 0 0 1 2.583-22.68zM96 308v-40c0-6.627-5.373-12-12-12H44c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm-336 96v-40c0-6.627-5.373-12-12-12H92c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zM96 500v-40c0-6.627-5.373-12-12-12H44c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12zm288 0v-40c0-6.627-5.373-12-12-12H140c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h232c6.627 0 12-5.373 12-12zm96 0v-40c0-6.627-5.373-12-12-12h-40c-6.627 0-12 5.373-12 12v40c0 6.627 5.373 12 12 12h40c6.627 0 12-5.373 12-12z"]},om={prefix:"fas",iconName:"tv",icon:[640,512,[],"f26c","M592 0H48A48 48 0 0 0 0 48v320a48 48 0 0 0 48 48h240v32H112a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16H352v-32h240a48 48 0 0 0 48-48V48a48 48 0 0 0-48-48zm-16 352H64V64h512z"]},am={prefix:"fas",iconName:"umbrella",icon:[576,512,[],"f0e9","M575.7 280.8C547.1 144.5 437.3 62.6 320 49.9V32c0-17.7-14.3-32-32-32s-32 14.3-32 32v17.9C138.3 62.6 29.5 144.5.3 280.8c-2.2 10.1 8.5 21.3 18.7 11.4 52-55 107.7-52.4 158.6 37 5.3 9.5 14.9 8.6 19.7 0 20.2-35.4 44.9-73.2 90.7-73.2 58.5 0 88.2 68.8 90.7 73.2 4.8 8.6 14.4 9.5 19.7 0 51-89.5 107.1-91.4 158.6-37 10.3 10 20.9-1.3 18.7-11.4zM256 301.7V432c0 8.8-7.2 16-16 16-7.8 0-13.2-5.3-15.1-10.7-5.9-16.7-24.1-25.4-40.8-19.5-16.7 5.9-25.4 24.2-19.5 40.8 11.2 31.9 41.6 53.3 75.4 53.3 44.1 0 80-35.9 80-80V301.6c-9.1-7.9-19.8-13.6-32-13.6-12.3.1-22.4 4.8-32 13.7z"]},lm={prefix:"fas",iconName:"umbrella-beach",icon:[640,512,[],"f5ca","M115.38 136.9l102.11 37.18c35.19-81.54 86.21-144.29 139-173.7-95.88-4.89-188.78 36.96-248.53 111.8-6.69 8.4-2.66 21.05 7.42 24.72zm132.25 48.16l238.48 86.83c35.76-121.38 18.7-231.66-42.63-253.98-7.4-2.7-15.13-4-23.09-4-58.02.01-128.27 69.17-172.76 171.15zM521.48 60.5c6.22 16.3 10.83 34.6 13.2 55.19 5.74 49.89-1.42 108.23-18.95 166.98l102.62 37.36c10.09 3.67 21.31-3.43 21.57-14.17 2.32-95.69-41.91-187.44-118.44-245.36zM560 447.98H321.06L386 269.5l-60.14-21.9-72.9 200.37H16c-8.84 0-16 7.16-16 16.01v32.01C0 504.83 7.16 512 16 512h544c8.84 0 16-7.17 16-16.01v-32.01c0-8.84-7.16-16-16-16z"]},cm={prefix:"fas",iconName:"underline",icon:[448,512,[],"f0cd","M32 64h32v160c0 88.22 71.78 160 160 160s160-71.78 160-160V64h32a16 16 0 0 0 16-16V16a16 16 0 0 0-16-16H272a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h32v160a80 80 0 0 1-160 0V64h32a16 16 0 0 0 16-16V16a16 16 0 0 0-16-16H32a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16zm400 384H16a16 16 0 0 0-16 16v32a16 16 0 0 0 16 16h416a16 16 0 0 0 16-16v-32a16 16 0 0 0-16-16z"]},um={prefix:"fas",iconName:"undo",icon:[512,512,[],"f0e2","M212.333 224.333H12c-6.627 0-12-5.373-12-12V12C0 5.373 5.373 0 12 0h48c6.627 0 12 5.373 12 12v78.112C117.773 39.279 184.26 7.47 258.175 8.007c136.906.994 246.448 111.623 246.157 248.532C504.041 393.258 393.12 504 256.333 504c-64.089 0-122.496-24.313-166.51-64.215-5.099-4.622-5.334-12.554-.467-17.42l33.967-33.967c4.474-4.474 11.662-4.717 16.401-.525C170.76 415.336 211.58 432 256.333 432c97.268 0 176-78.716 176-176 0-97.267-78.716-176-176-176-58.496 0-110.28 28.476-142.274 72.333h98.274c6.627 0 12 5.373 12 12v48c0 6.627-5.373 12-12 12z"]},hm={prefix:"fas",iconName:"undo-alt",icon:[512,512,[],"f2ea","M255.545 8c-66.269.119-126.438 26.233-170.86 68.685L48.971 40.971C33.851 25.851 8 36.559 8 57.941V192c0 13.255 10.745 24 24 24h134.059c21.382 0 32.09-25.851 16.971-40.971l-41.75-41.75c30.864-28.899 70.801-44.907 113.23-45.273 92.398-.798 170.283 73.977 169.484 169.442C423.236 348.009 349.816 424 256 424c-41.127 0-79.997-14.678-110.63-41.556-4.743-4.161-11.906-3.908-16.368.553L89.34 422.659c-4.872 4.872-4.631 12.815.482 17.433C133.798 479.813 192.074 504 256 504c136.966 0 247.999-111.033 248-247.998C504.001 119.193 392.354 7.755 255.545 8z"]},dm={prefix:"fas",iconName:"universal-access",icon:[512,512,[],"f29a","M256 48c114.953 0 208 93.029 208 208 0 114.953-93.029 208-208 208-114.953 0-208-93.029-208-208 0-114.953 93.029-208 208-208m0-40C119.033 8 8 119.033 8 256s111.033 248 248 248 248-111.033 248-248S392.967 8 256 8zm0 56C149.961 64 64 149.961 64 256s85.961 192 192 192 192-85.961 192-192S362.039 64 256 64zm0 44c19.882 0 36 16.118 36 36s-16.118 36-36 36-36-16.118-36-36 16.118-36 36-36zm117.741 98.023c-28.712 6.779-55.511 12.748-82.14 15.807.851 101.023 12.306 123.052 25.037 155.621 3.617 9.26-.957 19.698-10.217 23.315-9.261 3.617-19.699-.957-23.316-10.217-8.705-22.308-17.086-40.636-22.261-78.549h-9.686c-5.167 37.851-13.534 56.208-22.262 78.549-3.615 9.255-14.05 13.836-23.315 10.217-9.26-3.617-13.834-14.056-10.217-23.315 12.713-32.541 24.185-54.541 25.037-155.621-26.629-3.058-53.428-9.027-82.141-15.807-8.6-2.031-13.926-10.648-11.895-19.249s10.647-13.926 19.249-11.895c96.686 22.829 124.283 22.783 220.775 0 8.599-2.03 17.218 3.294 19.249 11.895 2.029 8.601-3.297 17.219-11.897 19.249z"]},pm={prefix:"fas",iconName:"university",icon:[512,512,[],"f19c","M496 128v16a8 8 0 0 1-8 8h-24v12c0 6.627-5.373 12-12 12H60c-6.627 0-12-5.373-12-12v-12H24a8 8 0 0 1-8-8v-16a8 8 0 0 1 4.941-7.392l232-88a7.996 7.996 0 0 1 6.118 0l232 88A8 8 0 0 1 496 128zm-24 304H40c-13.255 0-24 10.745-24 24v16a8 8 0 0 0 8 8h464a8 8 0 0 0 8-8v-16c0-13.255-10.745-24-24-24zM96 192v192H60c-6.627 0-12 5.373-12 12v20h416v-20c0-6.627-5.373-12-12-12h-36V192h-64v192h-64V192h-64v192h-64V192H96z"]},gm={prefix:"fas",iconName:"unlink",icon:[512,512,[],"f127","M304.083 405.907c4.686 4.686 4.686 12.284 0 16.971l-44.674 44.674c-59.263 59.262-155.693 59.266-214.961 0-59.264-59.265-59.264-155.696 0-214.96l44.675-44.675c4.686-4.686 12.284-4.686 16.971 0l39.598 39.598c4.686 4.686 4.686 12.284 0 16.971l-44.675 44.674c-28.072 28.073-28.072 73.75 0 101.823 28.072 28.072 73.75 28.073 101.824 0l44.674-44.674c4.686-4.686 12.284-4.686 16.971 0l39.597 39.598zm-56.568-260.216c4.686 4.686 12.284 4.686 16.971 0l44.674-44.674c28.072-28.075 73.75-28.073 101.824 0 28.072 28.073 28.072 73.75 0 101.823l-44.675 44.674c-4.686 4.686-4.686 12.284 0 16.971l39.598 39.598c4.686 4.686 12.284 4.686 16.971 0l44.675-44.675c59.265-59.265 59.265-155.695 0-214.96-59.266-59.264-155.695-59.264-214.961 0l-44.674 44.674c-4.686 4.686-4.686 12.284 0 16.971l39.597 39.598zm234.828 359.28l22.627-22.627c9.373-9.373 9.373-24.569 0-33.941L63.598 7.029c-9.373-9.373-24.569-9.373-33.941 0L7.029 29.657c-9.373 9.373-9.373 24.569 0 33.941l441.373 441.373c9.373 9.372 24.569 9.372 33.941 0z"]},fm={prefix:"fas",iconName:"unlock",icon:[448,512,[],"f09c","M400 256H152V152.9c0-39.6 31.7-72.5 71.3-72.9 40-.4 72.7 32.1 72.7 72v16c0 13.3 10.7 24 24 24h32c13.3 0 24-10.7 24-24v-16C376 68 307.5-.3 223.5 0 139.5.3 72 69.5 72 153.5V256H48c-26.5 0-48 21.5-48 48v160c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V304c0-26.5-21.5-48-48-48z"]},mm={prefix:"fas",iconName:"unlock-alt",icon:[448,512,[],"f13e","M400 256H152V152.9c0-39.6 31.7-72.5 71.3-72.9 40-.4 72.7 32.1 72.7 72v16c0 13.3 10.7 24 24 24h32c13.3 0 24-10.7 24-24v-16C376 68 307.5-.3 223.5 0 139.5.3 72 69.5 72 153.5V256H48c-26.5 0-48 21.5-48 48v160c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48V304c0-26.5-21.5-48-48-48zM264 408c0 22.1-17.9 40-40 40s-40-17.9-40-40v-48c0-22.1 17.9-40 40-40s40 17.9 40 40v48z"]},vm={prefix:"fas",iconName:"upload",icon:[512,512,[],"f093","M296 384h-80c-13.3 0-24-10.7-24-24V192h-87.7c-17.8 0-26.7-21.5-14.1-34.1L242.3 5.7c7.5-7.5 19.8-7.5 27.3 0l152.2 152.2c12.6 12.6 3.7 34.1-14.1 34.1H320v168c0 13.3-10.7 24-24 24zm216-8v112c0 13.3-10.7 24-24 24H24c-13.3 0-24-10.7-24-24V376c0-13.3 10.7-24 24-24h136v8c0 30.9 25.1 56 56 56h80c30.9 0 56-25.1 56-56v-8h136c13.3 0 24 10.7 24 24zm-124 88c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20zm64 0c0-11-9-20-20-20s-20 9-20 20 9 20 20 20 20-9 20-20z"]},Cm={prefix:"fas",iconName:"user",icon:[448,512,[],"f007","M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"]},ym={prefix:"fas",iconName:"user-alt",icon:[512,512,[],"f406","M256 288c79.5 0 144-64.5 144-144S335.5 0 256 0 112 64.5 112 144s64.5 144 144 144zm128 32h-55.1c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16H128C57.3 320 0 377.3 0 448v16c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48v-16c0-70.7-57.3-128-128-128z"]},wm={prefix:"fas",iconName:"user-alt-slash",icon:[640,512,[],"f4fa","M633.8 458.1L389.6 269.3C433.8 244.7 464 198.1 464 144 464 64.5 399.5 0 320 0c-67.1 0-123 46.1-139 108.2L45.5 3.4C38.5-2 28.5-.8 23 6.2L3.4 31.4c-5.4 7-4.2 17 2.8 22.4l588.4 454.7c7 5.4 17 4.2 22.5-2.8l19.6-25.3c5.4-6.8 4.1-16.9-2.9-22.3zM198.4 320C124.2 320 64 380.2 64 454.4v9.6c0 26.5 21.5 48 48 48h382.2L245.8 320h-47.4z"]},Sm={prefix:"fas",iconName:"user-astronaut",icon:[448,512,[],"f4fb","M64 224h13.5c24.7 56.5 80.9 96 146.5 96s121.8-39.5 146.5-96H384c8.8 0 16-7.2 16-16v-96c0-8.8-7.2-16-16-16h-13.5C345.8 39.5 289.6 0 224 0S102.2 39.5 77.5 96H64c-8.8 0-16 7.2-16 16v96c0 8.8 7.2 16 16 16zm40-88c0-22.1 21.5-40 48-40h144c26.5 0 48 17.9 48 40v24c0 53-43 96-96 96h-48c-53 0-96-43-96-96v-24zm72 72l12-36 36-12-36-12-12-36-12 36-36 12 36 12 12 36zm151.6 113.4C297.7 340.7 262.2 352 224 352s-73.7-11.3-103.6-30.6C52.9 328.5 0 385 0 454.4v9.6c0 26.5 21.5 48 48 48h80v-64c0-17.7 14.3-32 32-32h128c17.7 0 32 14.3 32 32v64h80c26.5 0 48-21.5 48-48v-9.6c0-69.4-52.9-125.9-120.4-133zM272 448c-8.8 0-16 7.2-16 16s7.2 16 16 16 16-7.2 16-16-7.2-16-16-16zm-96 0c-8.8 0-16 7.2-16 16v48h32v-48c0-8.8-7.2-16-16-16z"]},bm={prefix:"fas",iconName:"user-check",icon:[640,512,[],"f4fc","M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4zm323-128.4l-27.8-28.1c-4.6-4.7-12.1-4.7-16.8-.1l-104.8 104-45.5-45.8c-4.6-4.7-12.1-4.7-16.8-.1l-28.1 27.9c-4.7 4.6-4.7 12.1-.1 16.8l81.7 82.3c4.6 4.7 12.1 4.7 16.8.1l141.3-140.2c4.6-4.7 4.7-12.2.1-16.8z"]},Em={prefix:"fas",iconName:"user-circle",icon:[496,512,[],"f2bd","M248 8C111 8 0 119 0 256s111 248 248 248 248-111 248-248S385 8 248 8zm0 96c48.6 0 88 39.4 88 88s-39.4 88-88 88-88-39.4-88-88 39.4-88 88-88zm0 344c-58.7 0-111.3-26.6-146.5-68.2 18.8-35.4 55.6-59.8 98.5-59.8 2.4 0 4.8.4 7.1 1.1 13 4.2 26.6 6.9 40.9 6.9 14.3 0 28-2.7 40.9-6.9 2.3-.7 4.7-1.1 7.1-1.1 42.9 0 79.7 24.4 98.5 59.8C359.3 421.4 306.7 448 248 448z"]},Am={prefix:"fas",iconName:"user-clock",icon:[640,512,[],"f4fd","M496 224c-79.6 0-144 64.4-144 144s64.4 144 144 144 144-64.4 144-144-64.4-144-144-144zm64 150.3c0 5.3-4.4 9.7-9.7 9.7h-60.6c-5.3 0-9.7-4.4-9.7-9.7v-76.6c0-5.3 4.4-9.7 9.7-9.7h12.6c5.3 0 9.7 4.4 9.7 9.7V352h38.3c5.3 0 9.7 4.4 9.7 9.7v12.6zM320 368c0-27.8 6.7-54.1 18.2-77.5-8-1.5-16.2-2.5-24.6-2.5h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h347.1c-45.3-31.9-75.1-84.5-75.1-144zm-96-112c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128z"]},Tm={prefix:"fas",iconName:"user-cog",icon:[640,512,[],"f4fe","M610.5 373.3c2.6-14.1 2.6-28.5 0-42.6l25.8-14.9c3-1.7 4.3-5.2 3.3-8.5-6.7-21.6-18.2-41.2-33.2-57.4-2.3-2.5-6-3.1-9-1.4l-25.8 14.9c-10.9-9.3-23.4-16.5-36.9-21.3v-29.8c0-3.4-2.4-6.4-5.7-7.1-22.3-5-45-4.8-66.2 0-3.3.7-5.7 3.7-5.7 7.1v29.8c-13.5 4.8-26 12-36.9 21.3l-25.8-14.9c-2.9-1.7-6.7-1.1-9 1.4-15 16.2-26.5 35.8-33.2 57.4-1 3.3.4 6.8 3.3 8.5l25.8 14.9c-2.6 14.1-2.6 28.5 0 42.6l-25.8 14.9c-3 1.7-4.3 5.2-3.3 8.5 6.7 21.6 18.2 41.1 33.2 57.4 2.3 2.5 6 3.1 9 1.4l25.8-14.9c10.9 9.3 23.4 16.5 36.9 21.3v29.8c0 3.4 2.4 6.4 5.7 7.1 22.3 5 45 4.8 66.2 0 3.3-.7 5.7-3.7 5.7-7.1v-29.8c13.5-4.8 26-12 36.9-21.3l25.8 14.9c2.9 1.7 6.7 1.1 9-1.4 15-16.2 26.5-35.8 33.2-57.4 1-3.3-.4-6.8-3.3-8.5l-25.8-14.9zM496 400.5c-26.8 0-48.5-21.8-48.5-48.5s21.8-48.5 48.5-48.5 48.5 21.8 48.5 48.5-21.7 48.5-48.5 48.5zM224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm201.2 226.5c-2.3-1.2-4.6-2.6-6.8-3.9l-7.9 4.6c-6 3.4-12.8 5.3-19.6 5.3-10.9 0-21.4-4.6-28.9-12.6-18.3-19.8-32.3-43.9-40.2-69.6-5.5-17.7 1.9-36.4 17.9-45.7l7.9-4.6c-.1-2.6-.1-5.2 0-7.8l-7.9-4.6c-16-9.2-23.4-28-17.9-45.7.9-2.9 2.2-5.8 3.2-8.7-3.8-.3-7.5-1.2-11.4-1.2h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c10.1 0 19.5-3.2 27.2-8.5-1.2-3.8-2-7.7-2-11.8v-9.2z"]},Mm={prefix:"fas",iconName:"user-edit",icon:[640,512,[],"f4ff","M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h274.9c-2.4-6.8-3.4-14-2.6-21.3l6.8-60.9 1.2-11.1 7.9-7.9 77.3-77.3c-24.5-27.7-60-45.5-99.9-45.5zm45.3 145.3l-6.8 61c-1.1 10.2 7.5 18.8 17.6 17.6l60.9-6.8 137.9-137.9-71.7-71.7-137.9 137.8zM633 268.9L595.1 231c-9.3-9.3-24.5-9.3-33.8 0l-37.8 37.8-4.1 4.1 71.8 71.7 41.8-41.8c9.3-9.4 9.3-24.5 0-33.9z"]},Rm={prefix:"fas",iconName:"user-friends",icon:[640,512,[],"f500","M192 256c61.9 0 112-50.1 112-112S253.9 32 192 32 80 82.1 80 144s50.1 112 112 112zm76.8 32h-8.3c-20.8 10-43.9 16-68.5 16s-47.6-6-68.5-16h-8.3C51.6 288 0 339.6 0 403.2V432c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48v-28.8c0-63.6-51.6-115.2-115.2-115.2zM480 256c53 0 96-43 96-96s-43-96-96-96-96 43-96 96 43 96 96 96zm48 32h-3.8c-13.9 4.8-28.6 8-44.2 8s-30.3-3.2-44.2-8H432c-20.4 0-39.2 5.9-55.7 15.4 24.4 26.3 39.7 61.2 39.7 99.8v38.4c0 2.2-.5 4.3-.6 6.4H592c26.5 0 48-21.5 48-48 0-61.9-50.1-112-112-112z"]},_m={prefix:"fas",iconName:"user-graduate",icon:[448,512,[],"f501","M319.4 320.6L224 416l-95.4-95.4C57.1 323.7 0 382.2 0 454.4v9.6c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-9.6c0-72.2-57.1-130.7-128.6-133.8zM13.6 79.8l6.4 1.5v58.4c-7 4.2-12 11.5-12 20.3 0 8.4 4.6 15.4 11.1 19.7L3.5 242c-1.7 6.9 2.1 14 7.6 14h41.8c5.5 0 9.3-7.1 7.6-14l-15.6-62.3C51.4 175.4 56 168.4 56 160c0-8.8-5-16.1-12-20.3V87.1l66 15.9c-8.6 17.2-14 36.4-14 57 0 70.7 57.3 128 128 128s128-57.3 128-128c0-20.6-5.3-39.8-14-57l96.3-23.2c18.2-4.4 18.2-27.1 0-31.5l-190.4-46c-13-3.1-26.7-3.1-39.7 0L13.6 48.2c-18.1 4.4-18.1 27.2 0 31.6z"]},Pm={prefix:"fas",iconName:"user-injured",icon:[448,512,[],"f728","M277.37 11.98C261.08 4.47 243.11 0 224 0c-53.69 0-99.5 33.13-118.51 80h81.19l90.69-68.02zM342.51 80c-7.9-19.47-20.67-36.2-36.49-49.52L239.99 80h102.52zM224 256c70.69 0 128-57.31 128-128 0-5.48-.95-10.7-1.61-16H97.61c-.67 5.3-1.61 10.52-1.61 16 0 70.69 57.31 128 128 128zM80 299.7V512h128.26l-98.45-221.52A132.835 132.835 0 0 0 80 299.7zM0 464c0 26.51 21.49 48 48 48V320.24C18.88 344.89 0 381.26 0 422.4V464zm256-48h-55.38l42.67 96H256c26.47 0 48-21.53 48-48s-21.53-48-48-48zm57.6-128h-16.71c-22.24 10.18-46.88 16-72.89 16s-50.65-5.82-72.89-16h-7.37l42.67 96H256c44.11 0 80 35.89 80 80 0 18.08-6.26 34.59-16.41 48H400c26.51 0 48-21.49 48-48v-41.6c0-74.23-60.17-134.4-134.4-134.4z"]},xm={prefix:"fas",iconName:"user-lock",icon:[640,512,[],"f502","M224 256A128 128 0 1 0 96 128a128 128 0 0 0 128 128zm96 64a63.08 63.08 0 0 1 8.1-30.5c-4.8-.5-9.5-1.5-14.5-1.5h-16.7a174.08 174.08 0 0 1-145.8 0h-16.7A134.43 134.43 0 0 0 0 422.4V464a48 48 0 0 0 48 48h280.9a63.54 63.54 0 0 1-8.9-32zm288-32h-32v-80a80 80 0 0 0-160 0v80h-32a32 32 0 0 0-32 32v160a32 32 0 0 0 32 32h224a32 32 0 0 0 32-32V320a32 32 0 0 0-32-32zM496 432a32 32 0 1 1 32-32 32 32 0 0 1-32 32zm32-144h-64v-80a32 32 0 0 1 64 0z"]},Dm={prefix:"fas",iconName:"user-md",icon:[448,512,[],"f0f0","M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zM104 424c0 13.3 10.7 24 24 24s24-10.7 24-24-10.7-24-24-24-24 10.7-24 24zm216-135.4v49c36.5 7.4 64 39.8 64 78.4v41.7c0 7.6-5.4 14.2-12.9 15.7l-32.2 6.4c-4.3.9-8.5-1.9-9.4-6.3l-3.1-15.7c-.9-4.3 1.9-8.6 6.3-9.4l19.3-3.9V416c0-62.8-96-65.1-96 1.9v26.7l19.3 3.9c4.3.9 7.1 5.1 6.3 9.4l-3.1 15.7c-.9 4.3-5.1 7.1-9.4 6.3l-31.2-4.2c-7.9-1.1-13.8-7.8-13.8-15.9V416c0-38.6 27.5-70.9 64-78.4v-45.2c-2.2.7-4.4 1.1-6.6 1.9-18 6.3-37.3 9.8-57.4 9.8s-39.4-3.5-57.4-9.8c-7.4-2.6-14.9-4.2-22.6-5.2v81.6c23.1 6.9 40 28.1 40 53.4 0 30.9-25.1 56-56 56s-56-25.1-56-56c0-25.3 16.9-46.5 40-53.4v-80.4C48.5 301 0 355.8 0 422.4v44.8C0 491.9 20.1 512 44.8 512h358.4c24.7 0 44.8-20.1 44.8-44.8v-44.8c0-72-56.8-130.3-128-133.8z"]},Im={prefix:"fas",iconName:"user-minus",icon:[640,512,[],"f503","M624 208H432c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h192c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm-400 48c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"]},Lm={prefix:"fas",iconName:"user-ninja",icon:[448,512,[],"f504","M325.4 289.2L224 390.6 122.6 289.2C54 295.3 0 352.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-70.2-54-127.1-122.6-133.2zM32 192c27.3 0 51.8-11.5 69.2-29.7 15.1 53.9 64 93.7 122.8 93.7 70.7 0 128-57.3 128-128S294.7 0 224 0c-50.4 0-93.6 29.4-114.5 71.8C92.1 47.8 64 32 32 32c0 33.4 17.1 62.8 43.1 80-26 17.2-43.1 46.6-43.1 80zm144-96h96c17.7 0 32 14.3 32 32H144c0-17.7 14.3-32 32-32z"]},Nm={prefix:"fas",iconName:"user-nurse",icon:[448,512,[],"f82f","M319.41,320,224,415.39,128.59,320C57.1,323.1,0,381.6,0,453.79A58.21,58.21,0,0,0,58.21,512H389.79A58.21,58.21,0,0,0,448,453.79C448,381.6,390.9,323.1,319.41,320ZM224,304A128,128,0,0,0,352,176V65.82a32,32,0,0,0-20.76-30L246.47,4.07a64,64,0,0,0-44.94,0L116.76,35.86A32,32,0,0,0,96,65.82V176A128,128,0,0,0,224,304ZM184,71.67a5,5,0,0,1,5-5h21.67V45a5,5,0,0,1,5-5h16.66a5,5,0,0,1,5,5V66.67H259a5,5,0,0,1,5,5V88.33a5,5,0,0,1-5,5H237.33V115a5,5,0,0,1-5,5H215.67a5,5,0,0,1-5-5V93.33H189a5,5,0,0,1-5-5ZM144,160H304v16a80,80,0,0,1-160,0Z"]},Om={prefix:"fas",iconName:"user-plus",icon:[640,512,[],"f234","M624 208h-64v-64c0-8.8-7.2-16-16-16h-32c-8.8 0-16 7.2-16 16v64h-64c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h64v64c0 8.8 7.2 16 16 16h32c8.8 0 16-7.2 16-16v-64h64c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zm-400 48c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"]},Fm={prefix:"fas",iconName:"user-secret",icon:[448,512,[],"f21b","M383.9 308.3l23.9-62.6c4-10.5-3.7-21.7-15-21.7h-58.5c11-18.9 17.8-40.6 17.8-64v-.3c39.2-7.8 64-19.1 64-31.7 0-13.3-27.3-25.1-70.1-33-9.2-32.8-27-65.8-40.6-82.8-9.5-11.9-25.9-15.6-39.5-8.8l-27.6 13.8c-9 4.5-19.6 4.5-28.6 0L182.1 3.4c-13.6-6.8-30-3.1-39.5 8.8-13.5 17-31.4 50-40.6 82.8-42.7 7.9-70 19.7-70 33 0 12.6 24.8 23.9 64 31.7v.3c0 23.4 6.8 45.1 17.8 64H56.3c-11.5 0-19.2 11.7-14.7 22.3l25.8 60.2C27.3 329.8 0 372.7 0 422.4v44.8C0 491.9 20.1 512 44.8 512h358.4c24.7 0 44.8-20.1 44.8-44.8v-44.8c0-48.4-25.8-90.4-64.1-114.1zM176 480l-41.6-192 49.6 32 24 40-32 120zm96 0l-32-120 24-40 49.6-32L272 480zm41.7-298.5c-3.9 11.9-7 24.6-16.5 33.4-10.1 9.3-48 22.4-64-25-2.8-8.4-15.4-8.4-18.3 0-17 50.2-56 32.4-64 25-9.5-8.8-12.7-21.5-16.5-33.4-.8-2.5-6.3-5.7-6.3-5.8v-10.8c28.3 3.6 61 5.8 96 5.8s67.7-2.1 96-5.8v10.8c-.1.1-5.6 3.2-6.4 5.8z"]},km={prefix:"fas",iconName:"user-shield",icon:[640,512,[],"f505","M622.3 271.1l-115.2-45c-4.1-1.6-12.6-3.7-22.2 0l-115.2 45c-10.7 4.2-17.7 14-17.7 24.9 0 111.6 68.7 188.8 132.9 213.9 9.6 3.7 18 1.6 22.2 0C558.4 489.9 640 420.5 640 296c0-10.9-7-20.7-17.7-24.9zM496 462.4V273.3l95.5 37.3c-5.6 87.1-60.9 135.4-95.5 151.8zM224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm96 40c0-2.5.8-4.8 1.1-7.2-2.5-.1-4.9-.8-7.5-.8h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c6.8 0 13.3-1.5 19.2-4-54-42.9-99.2-116.7-99.2-212z"]},Gm={prefix:"fas",iconName:"user-slash",icon:[640,512,[],"f506","M633.8 458.1L362.3 248.3C412.1 230.7 448 183.8 448 128 448 57.3 390.7 0 320 0c-67.1 0-121.5 51.8-126.9 117.4L45.5 3.4C38.5-2 28.5-.8 23 6.2L3.4 31.4c-5.4 7-4.2 17 2.8 22.4l588.4 454.7c7 5.4 17 4.2 22.5-2.8l19.6-25.3c5.4-6.8 4.1-16.9-2.9-22.3zM96 422.4V464c0 26.5 21.5 48 48 48h350.2L207.4 290.3C144.2 301.3 96 356 96 422.4z"]},Vm={prefix:"fas",iconName:"user-tag",icon:[640,512,[],"f507","M630.6 364.9l-90.3-90.2c-12-12-28.3-18.7-45.3-18.7h-79.3c-17.7 0-32 14.3-32 32v79.2c0 17 6.7 33.2 18.7 45.2l90.3 90.2c12.5 12.5 32.8 12.5 45.3 0l92.5-92.5c12.6-12.5 12.6-32.7.1-45.2zm-182.8-21c-13.3 0-24-10.7-24-24s10.7-24 24-24 24 10.7 24 24c0 13.2-10.7 24-24 24zm-223.8-88c70.7 0 128-57.3 128-128C352 57.3 294.7 0 224 0S96 57.3 96 128c0 70.6 57.3 127.9 128 127.9zm127.8 111.2V294c-12.2-3.6-24.9-6.2-38.2-6.2h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 287.9 0 348.1 0 422.3v41.6c0 26.5 21.5 48 48 48h352c15.5 0 29.1-7.5 37.9-18.9l-58-58c-18.1-18.1-28.1-42.2-28.1-67.9z"]},Hm={prefix:"fas",iconName:"user-tie",icon:[448,512,[],"f508","M224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm95.8 32.6L272 480l-32-136 32-56h-96l32 56-32 136-47.8-191.4C56.9 292 0 350.3 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-72.1-56.9-130.4-128.2-133.8z"]},Bm={prefix:"fas",iconName:"user-times",icon:[640,512,[],"f235","M589.6 240l45.6-45.6c6.3-6.3 6.3-16.5 0-22.8l-22.8-22.8c-6.3-6.3-16.5-6.3-22.8 0L544 194.4l-45.6-45.6c-6.3-6.3-16.5-6.3-22.8 0l-22.8 22.8c-6.3 6.3-6.3 16.5 0 22.8l45.6 45.6-45.6 45.6c-6.3 6.3-6.3 16.5 0 22.8l22.8 22.8c6.3 6.3 16.5 6.3 22.8 0l45.6-45.6 45.6 45.6c6.3 6.3 16.5 6.3 22.8 0l22.8-22.8c6.3-6.3 6.3-16.5 0-22.8L589.6 240zM224 256c70.7 0 128-57.3 128-128S294.7 0 224 0 96 57.3 96 128s57.3 128 128 128zm89.6 32h-16.7c-22.2 10.2-46.9 16-72.9 16s-50.6-5.8-72.9-16h-16.7C60.2 288 0 348.2 0 422.4V464c0 26.5 21.5 48 48 48h352c26.5 0 48-21.5 48-48v-41.6c0-74.2-60.2-134.4-134.4-134.4z"]},zm={prefix:"fas",iconName:"users",icon:[640,512,[],"f0c0","M96 224c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64zm448 0c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64zm32 32h-64c-17.6 0-33.5 7.1-45.1 18.6 40.3 22.1 68.9 62 75.1 109.4h66c17.7 0 32-14.3 32-32v-32c0-35.3-28.7-64-64-64zm-256 0c61.9 0 112-50.1 112-112S381.9 32 320 32 208 82.1 208 144s50.1 112 112 112zm76.8 32h-8.3c-20.8 10-43.9 16-68.5 16s-47.6-6-68.5-16h-8.3C179.6 288 128 339.6 128 403.2V432c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48v-28.8c0-63.6-51.6-115.2-115.2-115.2zm-223.7-13.4C161.5 263.1 145.6 256 128 256H64c-35.3 0-64 28.7-64 64v32c0 17.7 14.3 32 32 32h65.9c6.3-47.4 34.9-87.3 75.2-109.4z"]},Um={prefix:"fas",iconName:"users-cog",icon:[640,512,[],"f509","M610.5 341.3c2.6-14.1 2.6-28.5 0-42.6l25.8-14.9c3-1.7 4.3-5.2 3.3-8.5-6.7-21.6-18.2-41.2-33.2-57.4-2.3-2.5-6-3.1-9-1.4l-25.8 14.9c-10.9-9.3-23.4-16.5-36.9-21.3v-29.8c0-3.4-2.4-6.4-5.7-7.1-22.3-5-45-4.8-66.2 0-3.3.7-5.7 3.7-5.7 7.1v29.8c-13.5 4.8-26 12-36.9 21.3l-25.8-14.9c-2.9-1.7-6.7-1.1-9 1.4-15 16.2-26.5 35.8-33.2 57.4-1 3.3.4 6.8 3.3 8.5l25.8 14.9c-2.6 14.1-2.6 28.5 0 42.6l-25.8 14.9c-3 1.7-4.3 5.2-3.3 8.5 6.7 21.6 18.2 41.1 33.2 57.4 2.3 2.5 6 3.1 9 1.4l25.8-14.9c10.9 9.3 23.4 16.5 36.9 21.3v29.8c0 3.4 2.4 6.4 5.7 7.1 22.3 5 45 4.8 66.2 0 3.3-.7 5.7-3.7 5.7-7.1v-29.8c13.5-4.8 26-12 36.9-21.3l25.8 14.9c2.9 1.7 6.7 1.1 9-1.4 15-16.2 26.5-35.8 33.2-57.4 1-3.3-.4-6.8-3.3-8.5l-25.8-14.9zM496 368.5c-26.8 0-48.5-21.8-48.5-48.5s21.8-48.5 48.5-48.5 48.5 21.8 48.5 48.5-21.7 48.5-48.5 48.5zM96 224c35.3 0 64-28.7 64-64s-28.7-64-64-64-64 28.7-64 64 28.7 64 64 64zm224 32c1.9 0 3.7-.5 5.6-.6 8.3-21.7 20.5-42.1 36.3-59.2 7.4-8 17.9-12.6 28.9-12.6 6.9 0 13.7 1.8 19.6 5.3l7.9 4.6c.8-.5 1.6-.9 2.4-1.4 7-14.6 11.2-30.8 11.2-48 0-61.9-50.1-112-112-112S208 82.1 208 144c0 61.9 50.1 112 112 112zm105.2 194.5c-2.3-1.2-4.6-2.6-6.8-3.9-8.2 4.8-15.3 9.8-27.5 9.8-10.9 0-21.4-4.6-28.9-12.6-18.3-19.8-32.3-43.9-40.2-69.6-10.7-34.5 24.9-49.7 25.8-50.3-.1-2.6-.1-5.2 0-7.8l-7.9-4.6c-3.8-2.2-7-5-9.8-8.1-3.3.2-6.5.6-9.8.6-24.6 0-47.6-6-68.5-16h-8.3C179.6 288 128 339.6 128 403.2V432c0 26.5 21.5 48 48 48h255.4c-3.7-6-6.2-12.8-6.2-20.3v-9.2zM173.1 274.6C161.5 263.1 145.6 256 128 256H64c-35.3 0-64 28.7-64 64v32c0 17.7 14.3 32 32 32h65.9c6.3-47.4 34.9-87.3 75.2-109.4z"]},Wm={prefix:"fas",iconName:"users-slash",icon:[640,512,[],"e073","M132.65,212.32,36.21,137.78A63.4,63.4,0,0,0,32,160a63.84,63.84,0,0,0,100.65,52.32Zm40.44,62.28A63.79,63.79,0,0,0,128,256H64A64.06,64.06,0,0,0,0,320v32a32,32,0,0,0,32,32H97.91A146.62,146.62,0,0,1,173.09,274.6ZM544,224a64,64,0,1,0-64-64A64.06,64.06,0,0,0,544,224ZM500.56,355.11a114.24,114.24,0,0,0-84.47-65.28L361,247.23c41.46-16.3,71-55.92,71-103.23A111.93,111.93,0,0,0,320,32c-57.14,0-103.69,42.83-110.6,98.08L45.46,3.38A16,16,0,0,0,23,6.19L3.37,31.46A16,16,0,0,0,6.18,53.91L594.53,508.63A16,16,0,0,0,617,505.82l19.64-25.27a16,16,0,0,0-2.81-22.45ZM128,403.21V432a48,48,0,0,0,48,48H464a47.45,47.45,0,0,0,12.57-1.87L232,289.13C173.74,294.83,128,343.42,128,403.21ZM576,256H512a63.79,63.79,0,0,0-45.09,18.6A146.29,146.29,0,0,1,542,384h66a32,32,0,0,0,32-32V320A64.06,64.06,0,0,0,576,256Z"]},jm={prefix:"fas",iconName:"utensil-spoon",icon:[512,512,[],"f2e5","M480.1 31.9c-55-55.1-164.9-34.5-227.8 28.5-49.3 49.3-55.1 110-28.8 160.4L9 413.2c-11.6 10.5-12.1 28.5-1 39.5L59.3 504c11 11 29.1 10.5 39.5-1.1l192.4-214.4c50.4 26.3 111.1 20.5 160.4-28.8 63-62.9 83.6-172.8 28.5-227.8z"]},Km={prefix:"fas",iconName:"utensils",icon:[416,512,[],"f2e7","M207.9 15.2c.8 4.7 16.1 94.5 16.1 128.8 0 52.3-27.8 89.6-68.9 104.6L168 486.7c.7 13.7-10.2 25.3-24 25.3H80c-13.7 0-24.7-11.5-24-25.3l12.9-238.1C27.7 233.6 0 196.2 0 144 0 109.6 15.3 19.9 16.1 15.2 19.3-5.1 61.4-5.4 64 16.3v141.2c1.3 3.4 15.1 3.2 16 0 1.4-25.3 7.9-139.2 8-141.8 3.3-20.8 44.7-20.8 47.9 0 .2 2.7 6.6 116.5 8 141.8.9 3.2 14.8 3.4 16 0V16.3c2.6-21.6 44.8-21.4 48-1.1zm119.2 285.7l-15 185.1c-1.2 14 9.9 26 23.9 26h56c13.3 0 24-10.7 24-24V24c0-13.2-10.7-24-24-24-82.5 0-221.4 178.5-64.9 300.9z"]},$m={prefix:"fas",iconName:"vector-square",icon:[512,512,[],"f5cb","M512 128V32c0-17.67-14.33-32-32-32h-96c-17.67 0-32 14.33-32 32H160c0-17.67-14.33-32-32-32H32C14.33 0 0 14.33 0 32v96c0 17.67 14.33 32 32 32v192c-17.67 0-32 14.33-32 32v96c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32h192c0 17.67 14.33 32 32 32h96c17.67 0 32-14.33 32-32v-96c0-17.67-14.33-32-32-32V160c17.67 0 32-14.33 32-32zm-96-64h32v32h-32V64zM64 64h32v32H64V64zm32 384H64v-32h32v32zm352 0h-32v-32h32v32zm-32-96h-32c-17.67 0-32 14.33-32 32v32H160v-32c0-17.67-14.33-32-32-32H96V160h32c17.67 0 32-14.33 32-32V96h192v32c0 17.67 14.33 32 32 32h32v192z"]},qm={prefix:"fas",iconName:"venus",icon:[288,512,[],"f221","M288 176c0-79.5-64.5-144-144-144S0 96.5 0 176c0 68.5 47.9 125.9 112 140.4V368H76c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v36c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-36h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-51.6c64.1-14.5 112-71.9 112-140.4zm-224 0c0-44.1 35.9-80 80-80s80 35.9 80 80-35.9 80-80 80-80-35.9-80-80z"]},Ym={prefix:"fas",iconName:"venus-double",icon:[512,512,[],"f226","M288 176c0-79.5-64.5-144-144-144S0 96.5 0 176c0 68.5 47.9 125.9 112 140.4V368H76c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v36c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-36h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-51.6c64.1-14.5 112-71.9 112-140.4zm-224 0c0-44.1 35.9-80 80-80s80 35.9 80 80-35.9 80-80 80-80-35.9-80-80zm336 140.4V368h36c6.6 0 12 5.4 12 12v40c0 6.6-5.4 12-12 12h-36v36c0 6.6-5.4 12-12 12h-40c-6.6 0-12-5.4-12-12v-36h-36c-6.6 0-12-5.4-12-12v-40c0-6.6 5.4-12 12-12h36v-51.6c-21.2-4.8-40.6-14.3-57.2-27.3 14-16.7 25-36 32.1-57.1 14.5 14.8 34.7 24 57.1 24 44.1 0 80-35.9 80-80s-35.9-80-80-80c-22.3 0-42.6 9.2-57.1 24-7.1-21.1-18-40.4-32.1-57.1C303.4 43.6 334.3 32 368 32c79.5 0 144 64.5 144 144 0 68.5-47.9 125.9-112 140.4z"]},Qm={prefix:"fas",iconName:"venus-mars",icon:[576,512,[],"f228","M564 0h-79c-10.7 0-16 12.9-8.5 20.5l16.9 16.9-48.7 48.7C422.5 72.1 396.2 64 368 64c-33.7 0-64.6 11.6-89.2 30.9 14 16.7 25 36 32.1 57.1 14.5-14.8 34.7-24 57.1-24 44.1 0 80 35.9 80 80s-35.9 80-80 80c-22.3 0-42.6-9.2-57.1-24-7.1 21.1-18 40.4-32.1 57.1 24.5 19.4 55.5 30.9 89.2 30.9 79.5 0 144-64.5 144-144 0-28.2-8.1-54.5-22.1-76.7l48.7-48.7 16.9 16.9c2.4 2.4 5.4 3.5 8.4 3.5 6.2 0 12.1-4.8 12.1-12V12c0-6.6-5.4-12-12-12zM144 64C64.5 64 0 128.5 0 208c0 68.5 47.9 125.9 112 140.4V400H76c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h36v36c0 6.6 5.4 12 12 12h40c6.6 0 12-5.4 12-12v-36h36c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-36v-51.6c64.1-14.6 112-71.9 112-140.4 0-79.5-64.5-144-144-144zm0 224c-44.1 0-80-35.9-80-80s35.9-80 80-80 80 35.9 80 80-35.9 80-80 80z"]},Xm={prefix:"fas",iconName:"vest",icon:[448,512,[],"e085","M437.252,239.877,384,160V32A32,32,0,0,0,352,0H320a24.021,24.021,0,0,0-13.312,4.031l-25,16.672a103.794,103.794,0,0,1-115.376,0l-25-16.672A24.021,24.021,0,0,0,128,0H96A32,32,0,0,0,64,32V160L10.748,239.877A64,64,0,0,0,0,275.377V480a32,32,0,0,0,32,32H192V288a31.987,31.987,0,0,1,1.643-10.119L207.135,237.4,150.188,66.564A151.518,151.518,0,0,0,224,86.234a151.55,151.55,0,0,0,73.812-19.672L224,288V512H416a32,32,0,0,0,32-32V275.377A64,64,0,0,0,437.252,239.877ZM131.312,371.312l-48,48a16,16,0,0,1-22.624-22.624l48-48a16,16,0,0,1,22.624,22.624Zm256,48a15.992,15.992,0,0,1-22.624,0l-48-48a16,16,0,0,1,22.624-22.624l48,48A15.993,15.993,0,0,1,387.312,419.312Z"]},Zm={prefix:"fas",iconName:"vest-patches",icon:[448,512,[],"e086","M437.252,239.877,384,160V32A32,32,0,0,0,352,0H320a23.982,23.982,0,0,0-13.312,4.031l-25,16.672a103.794,103.794,0,0,1-115.376,0l-25-16.672A23.982,23.982,0,0,0,128,0H96A32,32,0,0,0,64,32V160L10.748,239.877A64,64,0,0,0,0,275.377V480a32,32,0,0,0,32,32H192V288a31.987,31.987,0,0,1,1.643-10.119L207.135,237.4,150.188,66.561A151.579,151.579,0,0,0,224,86.234a151.565,151.565,0,0,0,73.811-19.668L224,288V512H416a32,32,0,0,0,32-32V275.377A64,64,0,0,0,437.252,239.877ZM63.5,272.484a12.01,12.01,0,0,1,17-16.968l15.5,15.5,15.5-15.5a12.01,12.01,0,0,1,17,16.968L112.984,288,128.5,303.516a12.01,12.01,0,0,1-17,16.968L96,304.984l-15.5,15.5a12.01,12.01,0,0,1-17-16.968L79.016,288ZM96,456a40,40,0,1,1,40-40A40,40,0,0,1,96,456ZM359.227,335.785,310.7,336a6.671,6.671,0,0,1-6.7-6.7l.215-48.574A24.987,24.987,0,0,1,331.43,256.1c12.789,1.162,22.129,12.619,22.056,25.419l-.037,5.057,5.051-.037c12.826-.035,24.236,9.275,25.4,22.076A24.948,24.948,0,0,1,359.227,335.785Z"]},Jm={prefix:"fas",iconName:"vial",icon:[480,512,[],"f492","M477.7 186.1L309.5 18.3c-3.1-3.1-8.2-3.1-11.3 0l-34 33.9c-3.1 3.1-3.1 8.2 0 11.3l11.2 11.1L33 316.5c-38.8 38.7-45.1 102-9.4 143.5 20.6 24 49.5 36 78.4 35.9 26.4 0 52.8-10 72.9-30.1l246.3-245.7 11.2 11.1c3.1 3.1 8.2 3.1 11.3 0l34-33.9c3.1-3 3.1-8.1 0-11.2zM318 256H161l148-147.7 78.5 78.3L318 256z"]},ev={prefix:"fas",iconName:"vials",icon:[640,512,[],"f493","M72 64h24v240c0 44.1 35.9 80 80 80s80-35.9 80-80V64h24c4.4 0 8-3.6 8-8V8c0-4.4-3.6-8-8-8H72c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm72 0h64v96h-64V64zm480 384H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h608c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM360 64h24v240c0 44.1 35.9 80 80 80s80-35.9 80-80V64h24c4.4 0 8-3.6 8-8V8c0-4.4-3.6-8-8-8H360c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm72 0h64v96h-64V64z"]},tv={prefix:"fas",iconName:"video",icon:[576,512,[],"f03d","M336.2 64H47.8C21.4 64 0 85.4 0 111.8v288.4C0 426.6 21.4 448 47.8 448h288.4c26.4 0 47.8-21.4 47.8-47.8V111.8c0-26.4-21.4-47.8-47.8-47.8zm189.4 37.7L416 177.3v157.4l109.6 75.5c21.2 14.6 50.4-.3 50.4-25.8V127.5c0-25.4-29.1-40.4-50.4-25.8z"]},iv={prefix:"fas",iconName:"video-slash",icon:[640,512,[],"f4e2","M633.8 458.1l-55-42.5c15.4-1.4 29.2-13.7 29.2-31.1v-257c0-25.5-29.1-40.4-50.4-25.8L448 177.3v137.2l-32-24.7v-178c0-26.4-21.4-47.8-47.8-47.8H123.9L45.5 3.4C38.5-2 28.5-.8 23 6.2L3.4 31.4c-5.4 7-4.2 17 2.8 22.4L42.7 82 416 370.6l178.5 138c7 5.4 17 4.2 22.5-2.8l19.6-25.3c5.5-6.9 4.2-17-2.8-22.4zM32 400.2c0 26.4 21.4 47.8 47.8 47.8h288.4c11.2 0 21.4-4 29.6-10.5L32 154.7v245.5z"]},rv={prefix:"fas",iconName:"vihara",icon:[640,512,[],"f6a7","M632.88 400.71L544 352v-64l55.16-17.69c11.79-5.9 11.79-22.72 0-28.62L480 192v-64l27.31-16.3c7.72-7.72 5.61-20.74-4.16-25.62L320 0 136.85 86.07c-9.77 4.88-11.88 17.9-4.16 25.62L160 128v64L40.84 241.69c-11.79 5.9-11.79 22.72 0 28.62L96 288v64L7.12 400.71c-5.42 3.62-7.7 9.63-7 15.29.62 5.01 3.57 9.75 8.72 12.33L64 448v48c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-48h160v48c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-48h160v48c0 8.84 7.16 16 16 16h32c8.84 0 16-7.16 16-16v-48l55.15-19.67c5.16-2.58 8.1-7.32 8.72-12.33.71-5.67-1.57-11.68-6.99-15.29zM224 128h192v64H224v-64zm-64 224v-64h320v64H160z"]},nv={prefix:"fas",iconName:"virus",icon:[512,512,[],"e074","M483.55,227.55H462c-50.68,0-76.07-61.27-40.23-97.11L437,115.19A28.44,28.44,0,0,0,396.8,75L381.56,90.22c-35.84,35.83-97.11,10.45-97.11-40.23V28.44a28.45,28.45,0,0,0-56.9,0V50c0,50.68-61.27,76.06-97.11,40.23L115.2,75A28.44,28.44,0,0,0,75,115.19l15.25,15.25c35.84,35.84,10.45,97.11-40.23,97.11H28.45a28.45,28.45,0,1,0,0,56.89H50c50.68,0,76.07,61.28,40.23,97.12L75,396.8A28.45,28.45,0,0,0,115.2,437l15.24-15.25c35.84-35.84,97.11-10.45,97.11,40.23v21.54a28.45,28.45,0,0,0,56.9,0V462c0-50.68,61.27-76.07,97.11-40.23L396.8,437A28.45,28.45,0,0,0,437,396.8l-15.25-15.24c-35.84-35.84-10.45-97.12,40.23-97.12h21.54a28.45,28.45,0,1,0,0-56.89ZM224,272a48,48,0,1,1,48-48A48,48,0,0,1,224,272Zm80,56a24,24,0,1,1,24-24A24,24,0,0,1,304,328Z"]},sv={prefix:"fas",iconName:"virus-slash",icon:[640,512,[],"e075","M114,227.6H92.4C76.7,227.6,64,240.3,64,256s12.7,28.4,28.4,28.4H114c50.7,0,76.1,61.3,40.2,97.1L139,396.8 c-11.5,10.7-12.2,28.7-1.6,40.2s28.7,12.2,40.2,1.6c0.5-0.5,1.1-1,1.6-1.6l15.2-15.2c35.8-35.8,97.1-10.5,97.1,40.2v21.5 c0,15.7,12.8,28.4,28.5,28.4c15.7,0,28.4-12.7,28.4-28.4V462c0-26.6,17-45.9,38.2-53.4l-244.5-189 C133.7,224.7,123.9,227.5,114,227.6z M617,505.8l19.6-25.3c5.4-7,4.2-17-2.8-22.5L470.6,332c4.2-25.4,24.9-47.5,55.4-47.5h21.5 c15.7,0,28.4-12.7,28.4-28.4s-12.7-28.4-28.4-28.4H526c-50.7,0-76.1-61.3-40.2-97.1l15.2-15.3c10.7-11.5,10-29.5-1.6-40.2 c-10.9-10.1-27.7-10.1-38.6,0l-15.2,15.2c-35.8,35.8-97.1,10.5-97.1-40.2V28.5C348.4,12.7,335.7,0,320,0 c-15.7,0-28.4,12.7-28.4,28.4V50c0,50.7-61.3,76.1-97.1,40.2L179.2,75c-11.1-11.1-29.4-10.6-40.5,0.5L45.5,3.4 c-7-5.4-17-4.2-22.5,2.8L3.4,31.5c-5.4,7-4.2,17,2.8,22.5l588.4,454.7C601.5,514.1,611.6,512.8,617,505.8z M335.4,227.5l-62.9-48.6 c4.9-1.8,10.2-2.8,15.4-2.9c26.5,0,48,21.5,48,48C336,225.2,335.5,226.3,335.4,227.5z"]},ov={prefix:"fas",iconName:"viruses",icon:[640,512,[],"e076","M624,352H611.88c-28.51,0-42.79-34.47-22.63-54.63l8.58-8.57a16,16,0,1,0-22.63-22.63l-8.57,8.58C546.47,294.91,512,280.63,512,252.12V240a16,16,0,0,0-32,0v12.12c0,28.51-34.47,42.79-54.63,22.63l-8.57-8.58a16,16,0,0,0-22.63,22.63l8.58,8.57c20.16,20.16,5.88,54.63-22.63,54.63H368a16,16,0,0,0,0,32h12.12c28.51,0,42.79,34.47,22.63,54.63l-8.58,8.57a16,16,0,1,0,22.63,22.63l8.57-8.58c20.16-20.16,54.63-5.88,54.63,22.63V496a16,16,0,0,0,32,0V483.88c0-28.51,34.47-42.79,54.63-22.63l8.57,8.58a16,16,0,1,0,22.63-22.63l-8.58-8.57C569.09,418.47,583.37,384,611.88,384H624a16,16,0,0,0,0-32ZM480,384a32,32,0,1,1,32-32A32,32,0,0,1,480,384ZM346.51,213.33h16.16a21.33,21.33,0,0,0,0-42.66H346.51c-38,0-57.05-46-30.17-72.84l11.43-11.44A21.33,21.33,0,0,0,297.6,56.23L286.17,67.66c-26.88,26.88-72.84,7.85-72.84-30.17V21.33a21.33,21.33,0,0,0-42.66,0V37.49c0,38-46,57.05-72.84,30.17L86.4,56.23A21.33,21.33,0,0,0,56.23,86.39L67.66,97.83c26.88,26.88,7.85,72.84-30.17,72.84H21.33a21.33,21.33,0,0,0,0,42.66H37.49c38,0,57.05,46,30.17,72.84L56.23,297.6A21.33,21.33,0,1,0,86.4,327.77l11.43-11.43c26.88-26.88,72.84-7.85,72.84,30.17v16.16a21.33,21.33,0,0,0,42.66,0V346.51c0-38,46-57.05,72.84-30.17l11.43,11.43a21.33,21.33,0,0,0,30.17-30.17l-11.43-11.43C289.46,259.29,308.49,213.33,346.51,213.33ZM160,192a32,32,0,1,1,32-32A32,32,0,0,1,160,192Zm80,32a16,16,0,1,1,16-16A16,16,0,0,1,240,224Z"]},av={prefix:"fas",iconName:"voicemail",icon:[640,512,[],"f897","M496 128a144 144 0 0 0-119.74 224H263.74A144 144 0 1 0 144 416h352a144 144 0 0 0 0-288zM64 272a80 80 0 1 1 80 80 80 80 0 0 1-80-80zm432 80a80 80 0 1 1 80-80 80 80 0 0 1-80 80z"]},lv={prefix:"fas",iconName:"volleyball-ball",icon:[512,512,[],"f45f","M231.39 243.48a285.56 285.56 0 0 0-22.7-105.7c-90.8 42.4-157.5 122.4-180.3 216.8a249 249 0 0 0 56.9 81.1 333.87 333.87 0 0 1 146.1-192.2zm-36.9-134.4a284.23 284.23 0 0 0-57.4-70.7c-91 49.8-144.8 152.9-125 262.2 33.4-83.1 98.4-152 182.4-191.5zm187.6 165.1c8.6-99.8-27.3-197.5-97.5-264.4-14.7-1.7-51.6-5.5-98.9 8.5A333.87 333.87 0 0 1 279.19 241a285 285 0 0 0 102.9 33.18zm-124.7 9.5a286.33 286.33 0 0 0-80.2 72.6c82 57.3 184.5 75.1 277.5 47.8a247.15 247.15 0 0 0 42.2-89.9 336.1 336.1 0 0 1-80.9 10.4c-54.6-.1-108.9-14.1-158.6-40.9zm-98.3 99.7c-15.2 26-25.7 54.4-32.1 84.2a247.07 247.07 0 0 0 289-22.1c-112.9 16.1-203.3-24.8-256.9-62.1zm180.3-360.6c55.3 70.4 82.5 161.2 74.6 253.6a286.59 286.59 0 0 0 89.7-14.2c0-2 .3-4 .3-6 0-107.8-68.7-199.1-164.6-233.4z"]},cv={prefix:"fas",iconName:"volume-down",icon:[384,512,[],"f027","M215.03 72.04L126.06 161H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V89.02c0-21.47-25.96-31.98-40.97-16.98zm123.2 108.08c-11.58-6.33-26.19-2.16-32.61 9.45-6.39 11.61-2.16 26.2 9.45 32.61C327.98 229.28 336 242.62 336 257c0 14.38-8.02 27.72-20.92 34.81-11.61 6.41-15.84 21-9.45 32.61 6.43 11.66 21.05 15.8 32.61 9.45 28.23-15.55 45.77-45 45.77-76.88s-17.54-61.32-45.78-76.87z"]},uv={prefix:"fas",iconName:"volume-mute",icon:[512,512,[],"f6a9","M215.03 71.05L126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97zM461.64 256l45.64-45.64c6.3-6.3 6.3-16.52 0-22.82l-22.82-22.82c-6.3-6.3-16.52-6.3-22.82 0L416 210.36l-45.64-45.64c-6.3-6.3-16.52-6.3-22.82 0l-22.82 22.82c-6.3 6.3-6.3 16.52 0 22.82L370.36 256l-45.63 45.63c-6.3 6.3-6.3 16.52 0 22.82l22.82 22.82c6.3 6.3 16.52 6.3 22.82 0L416 301.64l45.64 45.64c6.3 6.3 16.52 6.3 22.82 0l22.82-22.82c6.3-6.3 6.3-16.52 0-22.82L461.64 256z"]},hv={prefix:"fas",iconName:"volume-off",icon:[256,512,[],"f026","M215 71l-89 89H24a24 24 0 0 0-24 24v144a24 24 0 0 0 24 24h102.06L215 441c15 15 41 4.47 41-17V88c0-21.47-26-32-41-17z"]},dv={prefix:"fas",iconName:"volume-up",icon:[576,512,[],"f028","M215.03 71.05L126.06 160H24c-13.26 0-24 10.74-24 24v144c0 13.25 10.74 24 24 24h102.06l88.97 88.95c15.03 15.03 40.97 4.47 40.97-16.97V88.02c0-21.46-25.96-31.98-40.97-16.97zm233.32-51.08c-11.17-7.33-26.18-4.24-33.51 6.95-7.34 11.17-4.22 26.18 6.95 33.51 66.27 43.49 105.82 116.6 105.82 195.58 0 78.98-39.55 152.09-105.82 195.58-11.17 7.32-14.29 22.34-6.95 33.5 7.04 10.71 21.93 14.56 33.51 6.95C528.27 439.58 576 351.33 576 256S528.27 72.43 448.35 19.97zM480 256c0-63.53-32.06-121.94-85.77-156.24-11.19-7.14-26.03-3.82-33.12 7.46s-3.78 26.21 7.41 33.36C408.27 165.97 432 209.11 432 256s-23.73 90.03-63.48 115.42c-11.19 7.14-14.5 22.07-7.41 33.36 6.51 10.36 21.12 15.14 33.12 7.46C447.94 377.94 480 319.54 480 256zm-141.77-76.87c-11.58-6.33-26.19-2.16-32.61 9.45-6.39 11.61-2.16 26.2 9.45 32.61C327.98 228.28 336 241.63 336 256c0 14.38-8.02 27.72-20.92 34.81-11.61 6.41-15.84 21-9.45 32.61 6.43 11.66 21.05 15.8 32.61 9.45 28.23-15.55 45.77-45 45.77-76.88s-17.54-61.32-45.78-76.86z"]},pv={prefix:"fas",iconName:"vote-yea",icon:[640,512,[],"f772","M608 320h-64v64h22.4c5.3 0 9.6 3.6 9.6 8v16c0 4.4-4.3 8-9.6 8H73.6c-5.3 0-9.6-3.6-9.6-8v-16c0-4.4 4.3-8 9.6-8H96v-64H32c-17.7 0-32 14.3-32 32v96c0 17.7 14.3 32 32 32h576c17.7 0 32-14.3 32-32v-96c0-17.7-14.3-32-32-32zm-96 64V64.3c0-17.9-14.5-32.3-32.3-32.3H160.4C142.5 32 128 46.5 128 64.3V384h384zM211.2 202l25.5-25.3c4.2-4.2 11-4.2 15.2.1l41.3 41.6 95.2-94.4c4.2-4.2 11-4.2 15.2.1l25.3 25.5c4.2 4.2 4.2 11-.1 15.2L300.5 292c-4.2 4.2-11 4.2-15.2-.1l-74.1-74.7c-4.3-4.2-4.2-11 0-15.2z"]},gv={prefix:"fas",iconName:"vr-cardboard",icon:[640,512,[],"f729","M608 64H32C14.33 64 0 78.33 0 96v320c0 17.67 14.33 32 32 32h160.22c25.19 0 48.03-14.77 58.36-37.74l27.74-61.64C286.21 331.08 302.35 320 320 320s33.79 11.08 41.68 28.62l27.74 61.64C399.75 433.23 422.6 448 447.78 448H608c17.67 0 32-14.33 32-32V96c0-17.67-14.33-32-32-32zM160 304c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64zm320 0c-35.35 0-64-28.65-64-64s28.65-64 64-64 64 28.65 64 64-28.65 64-64 64z"]},fv={prefix:"fas",iconName:"walking",icon:[320,512,[],"f554","M208 96c26.5 0 48-21.5 48-48S234.5 0 208 0s-48 21.5-48 48 21.5 48 48 48zm94.5 149.1l-23.3-11.8-9.7-29.4c-14.7-44.6-55.7-75.8-102.2-75.9-36-.1-55.9 10.1-93.3 25.2-21.6 8.7-39.3 25.2-49.7 46.2L17.6 213c-7.8 15.8-1.5 35 14.2 42.9 15.6 7.9 34.6 1.5 42.5-14.3L81 228c3.5-7 9.3-12.5 16.5-15.4l26.8-10.8-15.2 60.7c-5.2 20.8.4 42.9 14.9 58.8l59.9 65.4c7.2 7.9 12.3 17.4 14.9 27.7l18.3 73.3c4.3 17.1 21.7 27.6 38.8 23.3 17.1-4.3 27.6-21.7 23.3-38.8l-22.2-89c-2.6-10.3-7.7-19.9-14.9-27.7l-45.5-49.7 17.2-68.7 5.5 16.5c5.3 16.1 16.7 29.4 31.7 37l23.3 11.8c15.6 7.9 34.6 1.5 42.5-14.3 7.7-15.7 1.4-35.1-14.3-43zM73.6 385.8c-3.2 8.1-8 15.4-14.2 21.5l-50 50.1c-12.5 12.5-12.5 32.8 0 45.3s32.7 12.5 45.2 0l59.4-59.4c6.1-6.1 10.9-13.4 14.2-21.5l13.5-33.8c-55.3-60.3-38.7-41.8-47.4-53.7l-20.7 51.5z"]},mv={prefix:"fas",iconName:"wallet",icon:[512,512,[],"f555","M461.2 128H80c-8.84 0-16-7.16-16-16s7.16-16 16-16h384c8.84 0 16-7.16 16-16 0-26.51-21.49-48-48-48H64C28.65 32 0 60.65 0 96v320c0 35.35 28.65 64 64 64h397.2c28.02 0 50.8-21.53 50.8-48V176c0-26.47-22.78-48-50.8-48zM416 336c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32z"]},vv={prefix:"fas",iconName:"warehouse",icon:[640,512,[],"f494","M504 352H136.4c-4.4 0-8 3.6-8 8l-.1 48c0 4.4 3.6 8 8 8H504c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zm0 96H136.1c-4.4 0-8 3.6-8 8l-.1 48c0 4.4 3.6 8 8 8h368c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zm0-192H136.6c-4.4 0-8 3.6-8 8l-.1 48c0 4.4 3.6 8 8 8H504c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8zm106.5-139L338.4 3.7a48.15 48.15 0 0 0-36.9 0L29.5 117C11.7 124.5 0 141.9 0 161.3V504c0 4.4 3.6 8 8 8h80c4.4 0 8-3.6 8-8V256c0-17.6 14.6-32 32.6-32h382.8c18 0 32.6 14.4 32.6 32v248c0 4.4 3.6 8 8 8h80c4.4 0 8-3.6 8-8V161.3c0-19.4-11.7-36.8-29.5-44.3z"]},Cv={prefix:"fas",iconName:"water",icon:[576,512,[],"f773","M562.1 383.9c-21.5-2.4-42.1-10.5-57.9-22.9-14.1-11.1-34.2-11.3-48.2 0-37.9 30.4-107.2 30.4-145.7-1.5-13.5-11.2-33-9.1-46.7 1.8-38 30.1-106.9 30-145.2-1.7-13.5-11.2-33.3-8.9-47.1 2-15.5 12.2-36 20.1-57.7 22.4-7.9.8-13.6 7.8-13.6 15.7v32.2c0 9.1 7.6 16.8 16.7 16 28.8-2.5 56.1-11.4 79.4-25.9 56.5 34.6 137 34.1 192 0 56.5 34.6 137 34.1 192 0 23.3 14.2 50.9 23.3 79.1 25.8 9.1.8 16.7-6.9 16.7-16v-31.6c.1-8-5.7-15.4-13.8-16.3zm0-144c-21.5-2.4-42.1-10.5-57.9-22.9-14.1-11.1-34.2-11.3-48.2 0-37.9 30.4-107.2 30.4-145.7-1.5-13.5-11.2-33-9.1-46.7 1.8-38 30.1-106.9 30-145.2-1.7-13.5-11.2-33.3-8.9-47.1 2-15.5 12.2-36 20.1-57.7 22.4-7.9.8-13.6 7.8-13.6 15.7v32.2c0 9.1 7.6 16.8 16.7 16 28.8-2.5 56.1-11.4 79.4-25.9 56.5 34.6 137 34.1 192 0 56.5 34.6 137 34.1 192 0 23.3 14.2 50.9 23.3 79.1 25.8 9.1.8 16.7-6.9 16.7-16v-31.6c.1-8-5.7-15.4-13.8-16.3zm0-144C540.6 93.4 520 85.4 504.2 73 490.1 61.9 470 61.7 456 73c-37.9 30.4-107.2 30.4-145.7-1.5-13.5-11.2-33-9.1-46.7 1.8-38 30.1-106.9 30-145.2-1.7-13.5-11.2-33.3-8.9-47.1 2-15.5 12.2-36 20.1-57.7 22.4-7.9.8-13.6 7.8-13.6 15.7v32.2c0 9.1 7.6 16.8 16.7 16 28.8-2.5 56.1-11.4 79.4-25.9 56.5 34.6 137 34.1 192 0 56.5 34.6 137 34.1 192 0 23.3 14.2 50.9 23.3 79.1 25.8 9.1.8 16.7-6.9 16.7-16v-31.6c.1-8-5.7-15.4-13.8-16.3z"]},yv={prefix:"fas",iconName:"wave-square",icon:[640,512,[],"f83e","M476 480H324a36 36 0 0 1-36-36V96h-96v156a36 36 0 0 1-36 36H16a16 16 0 0 1-16-16v-32a16 16 0 0 1 16-16h112V68a36 36 0 0 1 36-36h152a36 36 0 0 1 36 36v348h96V260a36 36 0 0 1 36-36h140a16 16 0 0 1 16 16v32a16 16 0 0 1-16 16H512v156a36 36 0 0 1-36 36z"]},wv={prefix:"fas",iconName:"weight",icon:[512,512,[],"f496","M448 64h-25.98C438.44 92.28 448 125.01 448 160c0 105.87-86.13 192-192 192S64 265.87 64 160c0-34.99 9.56-67.72 25.98-96H64C28.71 64 0 92.71 0 128v320c0 35.29 28.71 64 64 64h384c35.29 0 64-28.71 64-64V128c0-35.29-28.71-64-64-64zM256 320c88.37 0 160-71.63 160-160S344.37 0 256 0 96 71.63 96 160s71.63 160 160 160zm-.3-151.94l33.58-78.36c3.5-8.17 12.94-11.92 21.03-8.41 8.12 3.48 11.88 12.89 8.41 21l-33.67 78.55C291.73 188 296 197.45 296 208c0 22.09-17.91 40-40 40s-40-17.91-40-40c0-21.98 17.76-39.77 39.7-39.94z"]},Sv={prefix:"fas",iconName:"weight-hanging",icon:[512,512,[],"f5cd","M510.28 445.86l-73.03-292.13c-3.8-15.19-16.44-25.72-30.87-25.72h-60.25c3.57-10.05 5.88-20.72 5.88-32 0-53.02-42.98-96-96-96s-96 42.98-96 96c0 11.28 2.3 21.95 5.88 32h-60.25c-14.43 0-27.08 10.54-30.87 25.72L1.72 445.86C-6.61 479.17 16.38 512 48.03 512h415.95c31.64 0 54.63-32.83 46.3-66.14zM256 128c-17.64 0-32-14.36-32-32s14.36-32 32-32 32 14.36 32 32-14.36 32-32 32z"]},bv={prefix:"fas",iconName:"wheelchair",icon:[512,512,[],"f193","M496.101 385.669l14.227 28.663c3.929 7.915.697 17.516-7.218 21.445l-65.465 32.886c-16.049 7.967-35.556 1.194-43.189-15.055L331.679 320H192c-15.925 0-29.426-11.71-31.679-27.475C126.433 55.308 128.38 70.044 128 64c0-36.358 30.318-65.635 67.052-63.929 33.271 1.545 60.048 28.905 60.925 62.201.868 32.933-23.152 60.423-54.608 65.039l4.67 32.69H336c8.837 0 16 7.163 16 16v32c0 8.837-7.163 16-16 16H215.182l4.572 32H352a32 32 0 0 1 28.962 18.392L438.477 396.8l36.178-18.349c7.915-3.929 17.517-.697 21.446 7.218zM311.358 352h-24.506c-7.788 54.204-54.528 96-110.852 96-61.757 0-112-50.243-112-112 0-41.505 22.694-77.809 56.324-97.156-3.712-25.965-6.844-47.86-9.488-66.333C45.956 198.464 0 261.963 0 336c0 97.047 78.953 176 176 176 71.87 0 133.806-43.308 161.11-105.192L311.358 352z"]},Ev={prefix:"fas",iconName:"wifi",icon:[640,512,[],"f1eb","M634.91 154.88C457.74-8.99 182.19-8.93 5.09 154.88c-6.66 6.16-6.79 16.59-.35 22.98l34.24 33.97c6.14 6.1 16.02 6.23 22.4.38 145.92-133.68 371.3-133.71 517.25 0 6.38 5.85 16.26 5.71 22.4-.38l34.24-33.97c6.43-6.39 6.3-16.82-.36-22.98zM320 352c-35.35 0-64 28.65-64 64s28.65 64 64 64 64-28.65 64-64-28.65-64-64-64zm202.67-83.59c-115.26-101.93-290.21-101.82-405.34 0-6.9 6.1-7.12 16.69-.57 23.15l34.44 33.99c6 5.92 15.66 6.32 22.05.8 83.95-72.57 209.74-72.41 293.49 0 6.39 5.52 16.05 5.13 22.05-.8l34.44-33.99c6.56-6.46 6.33-17.06-.56-23.15z"]},Av={prefix:"fas",iconName:"wind",icon:[512,512,[],"f72e","M156.7 256H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h142.2c15.9 0 30.8 10.9 33.4 26.6 3.3 20-12.1 37.4-31.6 37.4-14.1 0-26.1-9.2-30.4-21.9-2.1-6.3-8.6-10.1-15.2-10.1H81.6c-9.8 0-17.7 8.8-15.9 18.4 8.6 44.1 47.6 77.6 94.2 77.6 57.1 0 102.7-50.1 95.2-108.6C249 291 205.4 256 156.7 256zM16 224h336c59.7 0 106.8-54.8 93.8-116.7-7.6-36.2-36.9-65.5-73.1-73.1-55.4-11.6-105.1 24.9-114.9 75.5-1.9 9.6 6.1 18.3 15.8 18.3h32.8c6.7 0 13.1-3.8 15.2-10.1C325.9 105.2 337.9 96 352 96c19.4 0 34.9 17.4 31.6 37.4-2.6 15.7-17.4 26.6-33.4 26.6H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16zm384 32H243.7c19.3 16.6 33.2 38.8 39.8 64H400c26.5 0 48 21.5 48 48s-21.5 48-48 48c-17.9 0-33.3-9.9-41.6-24.4-2.9-5-8.7-7.6-14.5-7.6h-33.8c-10.9 0-19 10.8-15.3 21.1 17.8 50.6 70.5 84.8 129.4 72.3 41.2-8.7 75.1-41.6 84.7-82.7C526 321.5 470.5 256 400 256z"]},Tv={prefix:"fas",iconName:"window-close",icon:[512,512,[],"f410","M464 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zm-83.6 290.5c4.8 4.8 4.8 12.6 0 17.4l-40.5 40.5c-4.8 4.8-12.6 4.8-17.4 0L256 313.3l-66.5 67.1c-4.8 4.8-12.6 4.8-17.4 0l-40.5-40.5c-4.8-4.8-4.8-12.6 0-17.4l67.1-66.5-67.1-66.5c-4.8-4.8-4.8-12.6 0-17.4l40.5-40.5c4.8-4.8 12.6-4.8 17.4 0l66.5 67.1 66.5-67.1c4.8-4.8 12.6-4.8 17.4 0l40.5 40.5c4.8 4.8 4.8 12.6 0 17.4L313.3 256l67.1 66.5z"]},Mv={prefix:"fas",iconName:"window-maximize",icon:[512,512,[],"f2d0","M464 32H48C21.5 32 0 53.5 0 80v352c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48V80c0-26.5-21.5-48-48-48zm-16 160H64v-84c0-6.6 5.4-12 12-12h360c6.6 0 12 5.4 12 12v84z"]},Rv={prefix:"fas",iconName:"window-minimize",icon:[512,512,[],"f2d1","M464 352H48c-26.5 0-48 21.5-48 48v32c0 26.5 21.5 48 48 48h416c26.5 0 48-21.5 48-48v-32c0-26.5-21.5-48-48-48z"]},_v={prefix:"fas",iconName:"window-restore",icon:[512,512,[],"f2d2","M512 48v288c0 26.5-21.5 48-48 48h-48V176c0-44.1-35.9-80-80-80H128V48c0-26.5 21.5-48 48-48h288c26.5 0 48 21.5 48 48zM384 176v288c0 26.5-21.5 48-48 48H48c-26.5 0-48-21.5-48-48V176c0-26.5 21.5-48 48-48h288c26.5 0 48 21.5 48 48zm-68 28c0-6.6-5.4-12-12-12H76c-6.6 0-12 5.4-12 12v52h252v-52z"]},Pv={prefix:"fas",iconName:"wine-bottle",icon:[512,512,[],"f72f","M507.31 72.57L439.43 4.69c-6.25-6.25-16.38-6.25-22.63 0l-22.63 22.63c-6.25 6.25-6.25 16.38 0 22.63l-76.67 76.67c-46.58-19.7-102.4-10.73-140.37 27.23L18.75 312.23c-24.99 24.99-24.99 65.52 0 90.51l90.51 90.51c24.99 24.99 65.52 24.99 90.51 0l158.39-158.39c37.96-37.96 46.93-93.79 27.23-140.37l76.67-76.67c6.25 6.25 16.38 6.25 22.63 0l22.63-22.63c6.24-6.24 6.24-16.37-.01-22.62zM179.22 423.29l-90.51-90.51 122.04-122.04 90.51 90.51-122.04 122.04z"]},xv={prefix:"fas",iconName:"wine-glass",icon:[288,512,[],"f4e3","M216 464h-40V346.81c68.47-15.89 118.05-79.91 111.4-154.16l-15.95-178.1C270.71 6.31 263.9 0 255.74 0H32.26c-8.15 0-14.97 6.31-15.7 14.55L.6 192.66C-6.05 266.91 43.53 330.93 112 346.82V464H72c-22.09 0-40 17.91-40 40 0 4.42 3.58 8 8 8h208c4.42 0 8-3.58 8-8 0-22.09-17.91-40-40-40z"]},Dv={prefix:"fas",iconName:"wine-glass-alt",icon:[288,512,[],"f5ce","M216 464h-40V346.81c68.47-15.89 118.05-79.91 111.4-154.16l-15.95-178.1C270.71 6.31 263.9 0 255.74 0H32.26c-8.15 0-14.97 6.31-15.7 14.55L.6 192.66C-6.05 266.91 43.53 330.93 112 346.82V464H72c-22.09 0-40 17.91-40 40 0 4.42 3.58 8 8 8h208c4.42 0 8-3.58 8-8 0-22.09-17.91-40-40-40zM61.75 48h164.5l7.17 80H54.58l7.17-80z"]},Iv={prefix:"fas",iconName:"won-sign",icon:[576,512,[],"f159","M564 192c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-48l18.6-80.6c1.7-7.5-4-14.7-11.7-14.7h-46.1c-5.7 0-10.6 4-11.7 9.5L450.7 128H340.8l-19.7-86c-1.3-5.5-6.1-9.3-11.7-9.3h-44c-5.6 0-10.4 3.8-11.7 9.3l-20 86H125l-17.5-85.7c-1.1-5.6-6.1-9.6-11.8-9.6H53.6c-7.7 0-13.4 7.1-11.7 14.6L60 128H12c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h62.3l7.2 32H12c-6.6 0-12 5.4-12 12v40c0 6.6 5.4 12 12 12h83.9l40.9 182.6c1.2 5.5 6.1 9.4 11.7 9.4h56.8c5.6 0 10.4-3.9 11.7-9.3L259.3 288h55.1l42.4 182.7c1.3 5.4 6.1 9.3 11.7 9.3h56.8c5.6 0 10.4-3.9 11.7-9.3L479.1 288H564c6.6 0 12-5.4 12-12v-40c0-6.6-5.4-12-12-12h-70.1l7.4-32zM183.8 342c-6.2 25.8-6.8 47.2-7.3 47.2h-1.1s-1.7-22-6.8-47.2l-11-54h38.8zm27.5-118h-66.8l-6.5-32h80.8zm62.9 0l2-8.6c1.9-8 3.5-16 4.8-23.4h11.8c1.3 7.4 2.9 15.4 4.8 23.4l2 8.6zm130.9 118c-5.1 25.2-6.8 47.2-6.8 47.2h-1.1c-.6 0-1.1-21.4-7.3-47.2l-12.4-54h39.1zm25.2-118h-67.4l-7.3-32h81.6z"]},Lv={prefix:"fas",iconName:"wrench",icon:[512,512,[],"f0ad","M507.73 109.1c-2.24-9.03-13.54-12.09-20.12-5.51l-74.36 74.36-67.88-11.31-11.31-67.88 74.36-74.36c6.62-6.62 3.43-17.9-5.66-20.16-47.38-11.74-99.55.91-136.58 37.93-39.64 39.64-50.55 97.1-34.05 147.2L18.74 402.76c-24.99 24.99-24.99 65.51 0 90.5 24.99 24.99 65.51 24.99 90.5 0l213.21-213.21c50.12 16.71 107.47 5.68 147.37-34.22 37.07-37.07 49.7-89.32 37.91-136.73zM64 472c-13.25 0-24-10.75-24-24 0-13.26 10.75-24 24-24s24 10.74 24 24c0 13.25-10.75 24-24 24z"]},Nv={prefix:"fas",iconName:"x-ray",icon:[640,512,[],"f497","M240 384c-8.8 0-16 7.2-16 16s7.2 16 16 16 16-7.2 16-16-7.2-16-16-16zm160 32c8.8 0 16-7.2 16-16s-7.2-16-16-16-16 7.2-16 16 7.2 16 16 16zM624 0H16C7.2 0 0 7.2 0 16v32c0 8.8 7.2 16 16 16h608c8.8 0 16-7.2 16-16V16c0-8.8-7.2-16-16-16zm0 448h-48V96H64v352H16c-8.8 0-16 7.2-16 16v32c0 8.8 7.2 16 16 16h608c8.8 0 16-7.2 16-16v-32c0-8.8-7.2-16-16-16zM480 248c0 4.4-3.6 8-8 8H336v32h104c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H336v32h64c26.5 0 48 21.5 48 48s-21.5 48-48 48-48-21.5-48-48v-16h-64v16c0 26.5-21.5 48-48 48s-48-21.5-48-48 21.5-48 48-48h64v-32H200c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h104v-32H168c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h136v-32H200c-4.4 0-8-3.6-8-8v-16c0-4.4 3.6-8 8-8h104v-24c0-4.4 3.6-8 8-8h16c4.4 0 8 3.6 8 8v24h104c4.4 0 8 3.6 8 8v16c0 4.4-3.6 8-8 8H336v32h136c4.4 0 8 3.6 8 8v16z"]},Ov={prefix:"fas",iconName:"yen-sign",icon:[384,512,[],"f157","M351.2 32h-65.3c-4.6 0-8.8 2.6-10.8 6.7l-55.4 113.2c-14.5 34.7-27.1 71.9-27.1 71.9h-1.3s-12.6-37.2-27.1-71.9L108.8 38.7c-2-4.1-6.2-6.7-10.8-6.7H32.8c-9.1 0-14.8 9.7-10.6 17.6L102.3 200H44c-6.6 0-12 5.4-12 12v32c0 6.6 5.4 12 12 12h88.2l19.8 37.2V320H44c-6.6 0-12 5.4-12 12v32c0 6.6 5.4 12 12 12h108v92c0 6.6 5.4 12 12 12h56c6.6 0 12-5.4 12-12v-92h108c6.6 0 12-5.4 12-12v-32c0-6.6-5.4-12-12-12H232v-26.8l19.8-37.2H340c6.6 0 12-5.4 12-12v-32c0-6.6-5.4-12-12-12h-58.3l80.1-150.4c4.3-7.9-1.5-17.6-10.6-17.6z"]},Fv={prefix:"fas",iconName:"yin-yang",icon:[496,512,[],"f6ad","M248 8C111.03 8 0 119.03 0 256s111.03 248 248 248 248-111.03 248-248S384.97 8 248 8zm0 376c-17.67 0-32-14.33-32-32s14.33-32 32-32 32 14.33 32 32-14.33 32-32 32zm0-128c-53.02 0-96 42.98-96 96s42.98 96 96 96c-106.04 0-192-85.96-192-192S141.96 64 248 64c53.02 0 96 42.98 96 96s-42.98 96-96 96zm0-128c-17.67 0-32 14.33-32 32s14.33 32 32 32 32-14.33 32-32-14.33-32-32-32z"]},kv={faAd:n,faAddressBook:s,faAddressCard:o,faAdjust:a,faAirFreshener:l,faAlignCenter:c,faAlignJustify:u,faAlignLeft:h,faAlignRight:d,faAllergies:p,faAmbulance:g,faAmericanSignLanguageInterpreting:f,faAnchor:m,faAngleDoubleDown:v,faAngleDoubleLeft:C,faAngleDoubleRight:y,faAngleDoubleUp:w,faAngleDown:S,faAngleLeft:b,faAngleRight:E,faAngleUp:A,faAngry:T,faAnkh:M,faAppleAlt:R,faArchive:_,faArchway:P,faArrowAltCircleDown:x,faArrowAltCircleLeft:D,faArrowAltCircleRight:I,faArrowAltCircleUp:L,faArrowCircleDown:N,faArrowCircleLeft:O,faArrowCircleRight:F,faArrowCircleUp:k,faArrowDown:G,faArrowLeft:V,faArrowRight:H,faArrowUp:B,faArrowsAlt:z,faArrowsAltH:U,faArrowsAltV:W,faAssistiveListeningSystems:j,faAsterisk:K,faAt:$,faAtlas:q,faAtom:Y,faAudioDescription:Q,faAward:X,faBaby:Z,faBabyCarriage:J,faBackspace:ee,faBackward:te,faBacon:ie,faBacteria:re,faBacterium:ne,faBahai:se,faBalanceScale:oe,faBalanceScaleLeft:ae,faBalanceScaleRight:le,faBan:ce,faBandAid:ue,faBarcode:he,faBars:de,faBaseballBall:pe,faBasketballBall:ge,faBath:fe,faBatteryEmpty:me,faBatteryFull:ve,faBatteryHalf:Ce,faBatteryQuarter:ye,faBatteryThreeQuarters:we,faBed:Se,faBeer:be,faBell:Ee,faBellSlash:Ae,faBezierCurve:Te,faBible:Me,faBicycle:Re,faBiking:_e,faBinoculars:Pe,faBiohazard:xe,faBirthdayCake:De,faBlender:Ie,faBlenderPhone:Le,faBlind:Ne,faBlog:Oe,faBold:Fe,faBolt:ke,faBomb:Ge,faBone:Ve,faBong:He,faBook:Be,faBookDead:ze,faBookMedical:Ue,faBookOpen:We,faBookReader:je,faBookmark:Ke,faBorderAll:$e,faBorderNone:qe,faBorderStyle:Ye,faBowlingBall:Qe,faBox:Xe,faBoxOpen:Ze,faBoxTissue:Je,faBoxes:et,faBraille:tt,faBrain:it,faBreadSlice:rt,faBriefcase:nt,faBriefcaseMedical:st,faBroadcastTower:ot,faBroom:at,faBrush:lt,faBug:ct,faBuilding:ut,faBullhorn:ht,faBullseye:dt,faBurn:pt,faBus:gt,faBusAlt:ft,faBusinessTime:mt,faCalculator:vt,faCalendar:Ct,faCalendarAlt:yt,faCalendarCheck:wt,faCalendarDay:St,faCalendarMinus:bt,faCalendarPlus:Et,faCalendarTimes:At,faCalendarWeek:Tt,faCamera:Mt,faCameraRetro:Rt,faCampground:_t,faCandyCane:Pt,faCannabis:xt,faCapsules:Dt,faCar:It,faCarAlt:Lt,faCarBattery:Nt,faCarCrash:Ot,faCarSide:Ft,faCaravan:kt,faCaretDown:Gt,faCaretLeft:Vt,faCaretRight:Ht,faCaretSquareDown:Bt,faCaretSquareLeft:zt,faCaretSquareRight:Ut,faCaretSquareUp:Wt,faCaretUp:jt,faCarrot:Kt,faCartArrowDown:$t,faCartPlus:qt,faCashRegister:Yt,faCat:Qt,faCertificate:Xt,faChair:Zt,faChalkboard:Jt,faChalkboardTeacher:ei,faChargingStation:ti,faChartArea:ii,faChartBar:ri,faChartLine:ni,faChartPie:si,faCheck:oi,faCheckCircle:ai,faCheckDouble:li,faCheckSquare:ci,faCheese:ui,faChess:hi,faChessBishop:di,faChessBoard:pi,faChessKing:gi,faChessKnight:fi,faChessPawn:mi,faChessQueen:vi,faChessRook:Ci,faChevronCircleDown:yi,faChevronCircleLeft:wi,faChevronCircleRight:Si,faChevronCircleUp:bi,faChevronDown:Ei,faChevronLeft:Ai,faChevronRight:Ti,faChevronUp:Mi,faChild:Ri,faChurch:_i,faCircle:Pi,faCircleNotch:xi,faCity:Di,faClinicMedical:Ii,faClipboard:Li,faClipboardCheck:Ni,faClipboardList:Oi,faClock:Fi,faClone:ki,faClosedCaptioning:Gi,faCloud:Vi,faCloudDownloadAlt:Hi,faCloudMeatball:Bi,faCloudMoon:zi,faCloudMoonRain:Ui,faCloudRain:Wi,faCloudShowersHeavy:ji,faCloudSun:Ki,faCloudSunRain:$i,faCloudUploadAlt:qi,faCocktail:Yi,faCode:Qi,faCodeBranch:Xi,faCoffee:Zi,faCog:Ji,faCogs:er,faCoins:tr,faColumns:ir,faComment:rr,faCommentAlt:nr,faCommentDollar:sr,faCommentDots:or,faCommentMedical:ar,faCommentSlash:lr,faComments:cr,faCommentsDollar:ur,faCompactDisc:hr,faCompass:dr,faCompress:pr,faCompressAlt:gr,faCompressArrowsAlt:fr,faConciergeBell:mr,faCookie:vr,faCookieBite:Cr,faCopy:yr,faCopyright:wr,faCouch:Sr,faCreditCard:br,faCrop:Er,faCropAlt:Ar,faCross:Tr,faCrosshairs:Mr,faCrow:Rr,faCrown:_r,faCrutch:Pr,faCube:xr,faCubes:Dr,faCut:Ir,faDatabase:Lr,faDeaf:Nr,faDemocrat:Or,faDesktop:Fr,faDharmachakra:kr,faDiagnoses:Gr,faDice:Vr,faDiceD20:Hr,faDiceD6:Br,faDiceFive:zr,faDiceFour:Ur,faDiceOne:Wr,faDiceSix:jr,faDiceThree:Kr,faDiceTwo:$r,faDigitalTachograph:qr,faDirections:Yr,faDisease:Qr,faDivide:Xr,faDizzy:Zr,faDna:Jr,faDog:en,faDollarSign:tn,faDolly:rn,faDollyFlatbed:nn,faDonate:sn,faDoorClosed:on,faDoorOpen:an,faDotCircle:ln,faDove:cn,faDownload:un,faDraftingCompass:hn,faDragon:dn,faDrawPolygon:pn,faDrum:gn,faDrumSteelpan:fn,faDrumstickBite:mn,faDumbbell:vn,faDumpster:Cn,faDumpsterFire:yn,faDungeon:wn,faEdit:Sn,faEgg:bn,faEject:En,faEllipsisH:An,faEllipsisV:Tn,faEnvelope:Mn,faEnvelopeOpen:Rn,faEnvelopeOpenText:_n,faEnvelopeSquare:Pn,faEquals:xn,faEraser:Dn,faEthernet:In,faEuroSign:Ln,faExchangeAlt:Nn,faExclamation:On,faExclamationCircle:Fn,faExclamationTriangle:kn,faExpand:Gn,faExpandAlt:Vn,faExpandArrowsAlt:Hn,faExternalLinkAlt:Bn,faExternalLinkSquareAlt:zn,faEye:Un,faEyeDropper:Wn,faEyeSlash:jn,faFan:Kn,faFastBackward:$n,faFastForward:qn,faFaucet:Yn,faFax:Qn,faFeather:Xn,faFeatherAlt:Zn,faFemale:Jn,faFighterJet:es,faFile:ts,faFileAlt:is,faFileArchive:rs,faFileAudio:ns,faFileCode:ss,faFileContract:os,faFileCsv:as,faFileDownload:ls,faFileExcel:cs,faFileExport:us,faFileImage:hs,faFileImport:ds,faFileInvoice:ps,faFileInvoiceDollar:gs,faFileMedical:fs,faFileMedicalAlt:ms,faFilePdf:vs,faFilePowerpoint:Cs,faFilePrescription:ys,faFileSignature:ws,faFileUpload:Ss,faFileVideo:bs,faFileWord:Es,faFill:As,faFillDrip:Ts,faFilm:Ms,faFilter:Rs,faFingerprint:_s,faFire:Ps,faFireAlt:xs,faFireExtinguisher:Ds,faFirstAid:Is,faFish:Ls,faFistRaised:Ns,faFlag:Os,faFlagCheckered:Fs,faFlagUsa:ks,faFlask:Gs,faFlushed:Vs,faFolder:Hs,faFolderMinus:Bs,faFolderOpen:zs,faFolderPlus:Us,faFont:Ws,faFontAwesomeLogoFull:js,faFootballBall:Ks,faForward:$s,faFrog:qs,faFrown:Ys,faFrownOpen:Qs,faFunnelDollar:Xs,faFutbol:Zs,faGamepad:Js,faGasPump:eo,faGavel:to,faGem:io,faGenderless:ro,faGhost:no,faGift:so,faGifts:oo,faGlassCheers:ao,faGlassMartini:lo,faGlassMartiniAlt:co,faGlassWhiskey:uo,faGlasses:ho,faGlobe:po,faGlobeAfrica:go,faGlobeAmericas:fo,faGlobeAsia:mo,faGlobeEurope:vo,faGolfBall:Co,faGopuram:yo,faGraduationCap:wo,faGreaterThan:So,faGreaterThanEqual:bo,faGrimace:Eo,faGrin:Ao,faGrinAlt:To,faGrinBeam:Mo,faGrinBeamSweat:Ro,faGrinHearts:_o,faGrinSquint:Po,faGrinSquintTears:xo,faGrinStars:Do,faGrinTears:Io,faGrinTongue:Lo,faGrinTongueSquint:No,faGrinTongueWink:Oo,faGrinWink:Fo,faGripHorizontal:ko,faGripLines:Go,faGripLinesVertical:Vo,faGripVertical:Ho,faGuitar:Bo,faHSquare:zo,faHamburger:Uo,faHammer:Wo,faHamsa:jo,faHandHolding:Ko,faHandHoldingHeart:$o,faHandHoldingMedical:qo,faHandHoldingUsd:Yo,faHandHoldingWater:Qo,faHandLizard:Xo,faHandMiddleFinger:Zo,faHandPaper:Jo,faHandPeace:ea,faHandPointDown:ta,faHandPointLeft:ia,faHandPointRight:ra,faHandPointUp:na,faHandPointer:sa,faHandRock:oa,faHandScissors:aa,faHandSparkles:la,faHandSpock:ca,faHands:ua,faHandsHelping:ha,faHandsWash:da,faHandshake:pa,faHandshakeAltSlash:ga,faHandshakeSlash:fa,faHanukiah:ma,faHardHat:va,faHashtag:Ca,faHatCowboy:ya,faHatCowboySide:wa,faHatWizard:Sa,faHdd:ba,faHeadSideCough:Ea,faHeadSideCoughSlash:Aa,faHeadSideMask:Ta,faHeadSideVirus:Ma,faHeading:Ra,faHeadphones:_a,faHeadphonesAlt:Pa,faHeadset:xa,faHeart:Da,faHeartBroken:Ia,faHeartbeat:La,faHelicopter:Na,faHighlighter:Oa,faHiking:Fa,faHippo:ka,faHistory:Ga,faHockeyPuck:Va,faHollyBerry:Ha,faHome:Ba,faHorse:za,faHorseHead:Ua,faHospital:Wa,faHospitalAlt:ja,faHospitalSymbol:Ka,faHospitalUser:$a,faHotTub:qa,faHotdog:Ya,faHotel:Qa,faHourglass:Xa,faHourglassEnd:Za,faHourglassHalf:Ja,faHourglassStart:el,faHouseDamage:tl,faHouseUser:il,faHryvnia:rl,faICursor:nl,faIceCream:sl,faIcicles:ol,faIcons:al,faIdBadge:ll,faIdCard:cl,faIdCardAlt:ul,faIgloo:hl,faImage:dl,faImages:pl,faInbox:gl,faIndent:fl,faIndustry:ml,faInfinity:vl,faInfo:Cl,faInfoCircle:yl,faItalic:wl,faJedi:Sl,faJoint:bl,faJournalWhills:El,faKaaba:Al,faKey:Tl,faKeyboard:Ml,faKhanda:Rl,faKiss:_l,faKissBeam:Pl,faKissWinkHeart:xl,faKiwiBird:Dl,faLandmark:Il,faLanguage:Ll,faLaptop:Nl,faLaptopCode:Ol,faLaptopHouse:Fl,faLaptopMedical:kl,faLaugh:Gl,faLaughBeam:Vl,faLaughSquint:Hl,faLaughWink:Bl,faLayerGroup:zl,faLeaf:Ul,faLemon:Wl,faLessThan:jl,faLessThanEqual:Kl,faLevelDownAlt:$l,faLevelUpAlt:ql,faLifeRing:Yl,faLightbulb:Ql,faLink:Xl,faLiraSign:Zl,faList:Jl,faListAlt:ec,faListOl:tc,faListUl:ic,faLocationArrow:rc,faLock:nc,faLockOpen:sc,faLongArrowAltDown:oc,faLongArrowAltLeft:ac,faLongArrowAltRight:lc,faLongArrowAltUp:cc,faLowVision:uc,faLuggageCart:hc,faLungs:dc,faLungsVirus:pc,faMagic:gc,faMagnet:fc,faMailBulk:mc,faMale:vc,faMap:Cc,faMapMarked:yc,faMapMarkedAlt:wc,faMapMarker:Sc,faMapMarkerAlt:bc,faMapPin:Ec,faMapSigns:Ac,faMarker:Tc,faMars:Mc,faMarsDouble:Rc,faMarsStroke:_c,faMarsStrokeH:Pc,faMarsStrokeV:xc,faMask:Dc,faMedal:Ic,faMedkit:Lc,faMeh:Nc,faMehBlank:Oc,faMehRollingEyes:Fc,faMemory:kc,faMenorah:Gc,faMercury:Vc,faMeteor:Hc,faMicrochip:Bc,faMicrophone:zc,faMicrophoneAlt:Uc,faMicrophoneAltSlash:Wc,faMicrophoneSlash:jc,faMicroscope:Kc,faMinus:$c,faMinusCircle:qc,faMinusSquare:Yc,faMitten:Qc,faMobile:Xc,faMobileAlt:Zc,faMoneyBill:Jc,faMoneyBillAlt:eu,faMoneyBillWave:tu,faMoneyBillWaveAlt:iu,faMoneyCheck:ru,faMoneyCheckAlt:nu,faMonument:su,faMoon:ou,faMortarPestle:au,faMosque:lu,faMotorcycle:cu,faMountain:uu,faMouse:hu,faMousePointer:du,faMugHot:pu,faMusic:gu,faNetworkWired:fu,faNeuter:mu,faNewspaper:vu,faNotEqual:Cu,faNotesMedical:yu,faObjectGroup:wu,faObjectUngroup:Su,faOilCan:bu,faOm:Eu,faOtter:Au,faOutdent:Tu,faPager:Mu,faPaintBrush:Ru,faPaintRoller:_u,faPalette:Pu,faPallet:xu,faPaperPlane:Du,faPaperclip:Iu,faParachuteBox:Lu,faParagraph:Nu,faParking:Ou,faPassport:Fu,faPastafarianism:ku,faPaste:Gu,faPause:Vu,faPauseCircle:Hu,faPaw:Bu,faPeace:zu,faPen:Uu,faPenAlt:Wu,faPenFancy:ju,faPenNib:Ku,faPenSquare:$u,faPencilAlt:qu,faPencilRuler:Yu,faPeopleArrows:Qu,faPeopleCarry:Xu,faPepperHot:Zu,faPercent:Ju,faPercentage:eh,faPersonBooth:th,faPhone:ih,faPhoneAlt:rh,faPhoneSlash:nh,faPhoneSquare:sh,faPhoneSquareAlt:oh,faPhoneVolume:ah,faPhotoVideo:lh,faPiggyBank:ch,faPills:uh,faPizzaSlice:hh,faPlaceOfWorship:dh,faPlane:ph,faPlaneArrival:gh,faPlaneDeparture:fh,faPlaneSlash:mh,faPlay:vh,faPlayCircle:Ch,faPlug:yh,faPlus:wh,faPlusCircle:Sh,faPlusSquare:bh,faPodcast:Eh,faPoll:Ah,faPollH:Th,faPoo:Mh,faPooStorm:Rh,faPoop:_h,faPortrait:Ph,faPoundSign:xh,faPowerOff:Dh,faPray:Ih,faPrayingHands:Lh,faPrescription:Nh,faPrescriptionBottle:Oh,faPrescriptionBottleAlt:Fh,faPrint:kh,faProcedures:Gh,faProjectDiagram:Vh,faPumpMedical:Hh,faPumpSoap:Bh,faPuzzlePiece:zh,faQrcode:Uh,faQuestion:Wh,faQuestionCircle:jh,faQuidditch:Kh,faQuoteLeft:$h,faQuoteRight:qh,faQuran:Yh,faRadiation:Qh,faRadiationAlt:Xh,faRainbow:Zh,faRandom:Jh,faReceipt:ed,faRecordVinyl:td,faRecycle:id,faRedo:rd,faRedoAlt:nd,faRegistered:sd,faRemoveFormat:od,faReply:ad,faReplyAll:ld,faRepublican:cd,faRestroom:ud,faRetweet:hd,faRibbon:dd,faRing:pd,faRoad:gd,faRobot:fd,faRocket:md,faRoute:vd,faRss:Cd,faRssSquare:yd,faRubleSign:wd,faRuler:Sd,faRulerCombined:bd,faRulerHorizontal:Ed,faRulerVertical:Ad,faRunning:Td,faRupeeSign:Md,faSadCry:Rd,faSadTear:_d,faSatellite:Pd,faSatelliteDish:xd,faSave:Dd,faSchool:Id,faScrewdriver:Ld,faScroll:Nd,faSdCard:Od,faSearch:Fd,faSearchDollar:kd,faSearchLocation:Gd,faSearchMinus:Vd,faSearchPlus:Hd,faSeedling:Bd,faServer:zd,faShapes:Ud,faShare:Wd,faShareAlt:jd,faShareAltSquare:Kd,faShareSquare:$d,faShekelSign:qd,faShieldAlt:Yd,faShieldVirus:Qd,faShip:Xd,faShippingFast:Zd,faShoePrints:Jd,faShoppingBag:ep,faShoppingBasket:tp,faShoppingCart:ip,faShower:rp,faShuttleVan:np,faSign:sp,faSignInAlt:op,faSignLanguage:ap,faSignOutAlt:lp,faSignal:cp,faSignature:up,faSimCard:hp,faSink:dp,faSitemap:pp,faSkating:gp,faSkiing:fp,faSkiingNordic:mp,faSkull:vp,faSkullCrossbones:Cp,faSlash:yp,faSleigh:wp,faSlidersH:Sp,faSmile:bp,faSmileBeam:Ep,faSmileWink:Ap,faSmog:Tp,faSmoking:Mp,faSmokingBan:Rp,faSms:_p,faSnowboarding:Pp,faSnowflake:xp,faSnowman:Dp,faSnowplow:Ip,faSoap:Lp,faSocks:Np,faSolarPanel:Op,faSort:Fp,faSortAlphaDown:kp,faSortAlphaDownAlt:Gp,faSortAlphaUp:Vp,faSortAlphaUpAlt:Hp,faSortAmountDown:Bp,faSortAmountDownAlt:zp,faSortAmountUp:Up,faSortAmountUpAlt:Wp,faSortDown:jp,faSortNumericDown:Kp,faSortNumericDownAlt:$p,faSortNumericUp:qp,faSortNumericUpAlt:Yp,faSortUp:Qp,faSpa:Xp,faSpaceShuttle:Zp,faSpellCheck:Jp,faSpider:eg,faSpinner:tg,faSplotch:ig,faSprayCan:rg,faSquare:ng,faSquareFull:sg,faSquareRootAlt:og,faStamp:ag,faStar:lg,faStarAndCrescent:cg,faStarHalf:ug,faStarHalfAlt:hg,faStarOfDavid:dg,faStarOfLife:pg,faStepBackward:gg,faStepForward:fg,faStethoscope:mg,faStickyNote:vg,faStop:Cg,faStopCircle:yg,faStopwatch:wg,faStopwatch20:Sg,faStore:bg,faStoreAlt:Eg,faStoreAltSlash:Ag,faStoreSlash:Tg,faStream:Mg,faStreetView:Rg,faStrikethrough:_g,faStroopwafel:Pg,faSubscript:xg,faSubway:Dg,faSuitcase:Ig,faSuitcaseRolling:Lg,faSun:Ng,faSuperscript:Og,faSurprise:Fg,faSwatchbook:kg,faSwimmer:Gg,faSwimmingPool:Vg,faSynagogue:Hg,faSync:Bg,faSyncAlt:zg,faSyringe:Ug,faTable:Wg,faTableTennis:jg,faTablet:Kg,faTabletAlt:$g,faTablets:qg,faTachometerAlt:Yg,faTag:Qg,faTags:Xg,faTape:Zg,faTasks:Jg,faTaxi:ef,faTeeth:tf,faTeethOpen:rf,faTemperatureHigh:nf,faTemperatureLow:sf,faTenge:of,faTerminal:af,faTextHeight:lf,faTextWidth:cf,faTh:uf,faThLarge:hf,faThList:df,faTheaterMasks:pf,faThermometer:gf,faThermometerEmpty:ff,faThermometerFull:mf,faThermometerHalf:vf,faThermometerQuarter:Cf,faThermometerThreeQuarters:yf,faThumbsDown:wf,faThumbsUp:Sf,faThumbtack:bf,faTicketAlt:Ef,faTimes:Af,faTimesCircle:Tf,faTint:Mf,faTintSlash:Rf,faTired:_f,faToggleOff:Pf,faToggleOn:xf,faToilet:Df,faToiletPaper:If,faToiletPaperSlash:Lf,faToolbox:Nf,faTools:Of,faTooth:Ff,faTorah:kf,faToriiGate:Gf,faTractor:Vf,faTrademark:Hf,faTrafficLight:Bf,faTrailer:zf,faTrain:Uf,faTram:Wf,faTransgender:jf,faTransgenderAlt:Kf,faTrash:$f,faTrashAlt:qf,faTrashRestore:Yf,faTrashRestoreAlt:Qf,faTree:Xf,faTrophy:Zf,faTruck:Jf,faTruckLoading:em,faTruckMonster:tm,faTruckMoving:im,faTruckPickup:rm,faTshirt:nm,faTty:sm,faTv:om,faUmbrella:am,faUmbrellaBeach:lm,faUnderline:cm,faUndo:um,faUndoAlt:hm,faUniversalAccess:dm,faUniversity:pm,faUnlink:gm,faUnlock:fm,faUnlockAlt:mm,faUpload:vm,faUser:Cm,faUserAlt:ym,faUserAltSlash:wm,faUserAstronaut:Sm,faUserCheck:bm,faUserCircle:Em,faUserClock:Am,faUserCog:Tm,faUserEdit:Mm,faUserFriends:Rm,faUserGraduate:_m,faUserInjured:Pm,faUserLock:xm,faUserMd:Dm,faUserMinus:Im,faUserNinja:Lm,faUserNurse:Nm,faUserPlus:Om,faUserSecret:Fm,faUserShield:km,faUserSlash:Gm,faUserTag:Vm,faUserTie:Hm,faUserTimes:Bm,faUsers:zm,faUsersCog:Um,faUsersSlash:Wm,faUtensilSpoon:jm,faUtensils:Km,faVectorSquare:$m,faVenus:qm,faVenusDouble:Ym,faVenusMars:Qm,faVest:Xm,faVestPatches:Zm,faVial:Jm,faVials:ev,faVideo:tv,faVideoSlash:iv,faVihara:rv,faVirus:nv,faVirusSlash:sv,faViruses:ov,faVoicemail:av,faVolleyballBall:lv,faVolumeDown:cv,faVolumeMute:uv,faVolumeOff:hv,faVolumeUp:dv,faVoteYea:pv,faVrCardboard:gv,faWalking:fv,faWallet:mv,faWarehouse:vv,faWater:Cv,faWaveSquare:yv,faWeight:wv,faWeightHanging:Sv,faWheelchair:bv,faWifi:Ev,faWind:Av,faWindowClose:Tv,faWindowMaximize:Mv,faWindowMinimize:Rv,faWindowRestore:_v,faWineBottle:Pv,faWineGlass:xv,faWineGlassAlt:Dv,faWonSign:Iv,faWrench:Lv,faXRay:Nv,faYenSign:Ov,faYinYang:Fv}},92845(e,t,i){"use strict";i.r(t),i.d(t,{FontAwesomeIcon:()=>w});var r=i(5188),n=i(5821),s=i.n(n),o=i(22155);function a(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,r)}return i}function l(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?a(Object(i),!0).forEach(function(t){u(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):a(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function c(e){return c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},c(e)}function u(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function h(e,t){if(null==e)return{};var i,r,n=function(e,t){if(null==e)return{};var i,r,n={},s=Object.keys(e);for(r=0;r<s.length;r++)i=s[r],t.indexOf(i)>=0||(n[i]=e[i]);return n}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)i=s[r],t.indexOf(i)>=0||Object.prototype.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}function d(e){return function(e){if(Array.isArray(e))return p(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var i=Object.prototype.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?p(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,r=new Array(t);i<t;i++)r[i]=e[i];return r}function g(e){return t=e,(t-=0)==t?e:(e=e.replace(/[\-_\s]+(.)?/g,function(e,t){return t?t.toUpperCase():""})).substr(0,1).toLowerCase()+e.substr(1);var t}var f=["style"],m=!1;try{m=!0}catch(e){}function v(e){return e&&"object"===c(e)&&e.prefix&&e.iconName&&e.icon?e:r.parse.icon?r.parse.icon(e):null===e?null:e&&"object"===c(e)&&e.prefix&&e.iconName?e:Array.isArray(e)&&2===e.length?{prefix:e[0],iconName:e[1]}:"string"==typeof e?{prefix:"fas",iconName:e}:void 0}function C(e,t){return Array.isArray(t)&&t.length>0||!Array.isArray(t)&&t?u({},e,t):{}}var y=["forwardedRef"];function w(e){var t=e.forwardedRef,i=h(e,y),n=i.icon,s=i.mask,o=i.symbol,a=i.className,c=i.title,p=i.titleId,g=i.maskId,f=v(n),b=C("classes",[].concat(d(function(e){var t,i=e.beat,r=e.fade,n=e.beatFade,s=e.bounce,o=e.shake,a=e.flash,l=e.spin,c=e.spinPulse,h=e.spinReverse,d=e.pulse,p=e.fixedWidth,g=e.inverse,f=e.border,m=e.listItem,v=e.flip,C=e.size,y=e.rotation,w=e.pull,S=(u(t={"fa-beat":i,"fa-fade":r,"fa-beat-fade":n,"fa-bounce":s,"fa-shake":o,"fa-flash":a,"fa-spin":l,"fa-spin-reverse":h,"fa-spin-pulse":c,"fa-pulse":d,"fa-fw":p,"fa-inverse":g,"fa-border":f,"fa-li":m,"fa-flip":!0===v,"fa-flip-horizontal":"horizontal"===v||"both"===v,"fa-flip-vertical":"vertical"===v||"both"===v},"fa-".concat(C),null!=C),u(t,"fa-rotate-".concat(y),null!=y&&0!==y),u(t,"fa-pull-".concat(w),null!=w),u(t,"fa-swap-opacity",e.swapOpacity),t);return Object.keys(S).map(function(e){return S[e]?e:null}).filter(function(e){return e})}(i)),d(a.split(" ")))),E=C("transform","string"==typeof i.transform?r.parse.transform(i.transform):i.transform),A=C("mask",v(s)),T=(0,r.icon)(f,l(l(l(l({},b),E),A),{},{symbol:o,title:c,titleId:p,maskId:g}));if(!T)return function(){var e;!m&&console&&"function"==typeof console.error&&(e=console).error.apply(e,arguments)}("Could not find icon",f),null;var M=T.abstract,R={ref:t};return Object.keys(i).forEach(function(e){w.defaultProps.hasOwnProperty(e)||(R[e]=i[e])}),S(M[0],R)}w.displayName="FontAwesomeIcon",w.propTypes={beat:s().bool,border:s().bool,beatFade:s().bool,bounce:s().bool,className:s().string,fade:s().bool,flash:s().bool,mask:s().oneOfType([s().object,s().array,s().string]),maskId:s().string,fixedWidth:s().bool,inverse:s().bool,flip:s().oneOf([!0,!1,"horizontal","vertical","both"]),icon:s().oneOfType([s().object,s().array,s().string]),listItem:s().bool,pull:s().oneOf(["right","left"]),pulse:s().bool,rotation:s().oneOf([0,90,180,270]),shake:s().bool,size:s().oneOf(["2xs","xs","sm","lg","xl","2xl","1x","2x","3x","4x","5x","6x","7x","8x","9x","10x"]),spin:s().bool,spinPulse:s().bool,spinReverse:s().bool,symbol:s().oneOfType([s().bool,s().string]),title:s().string,titleId:s().string,transform:s().oneOfType([s().string,s().object]),swapOpacity:s().bool},w.defaultProps={border:!1,className:"",mask:null,maskId:null,fixedWidth:!1,inverse:!1,flip:!1,icon:null,listItem:!1,pull:null,pulse:!1,rotation:null,size:null,spin:!1,spinPulse:!1,spinReverse:!1,beat:!1,fade:!1,beatFade:!1,bounce:!1,shake:!1,symbol:!1,title:"",titleId:null,transform:null,swapOpacity:!1};var S=function e(t,i){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if("string"==typeof i)return i;var n=(i.children||[]).map(function(i){return e(t,i)}),s=Object.keys(i.attributes||{}).reduce(function(e,t){var r=i.attributes[t];switch(t){case"class":e.attrs.className=r,delete i.attributes.class;break;case"style":e.attrs.style=r.split(";").map(function(e){return e.trim()}).filter(function(e){return e}).reduce(function(e,t){var i,r=t.indexOf(":"),n=g(t.slice(0,r)),s=t.slice(r+1).trim();return n.startsWith("webkit")?e[(i=n,i.charAt(0).toUpperCase()+i.slice(1))]=s:e[n]=s,e},{});break;default:0===t.indexOf("aria-")||0===t.indexOf("data-")?e.attrs[t.toLowerCase()]=r:e.attrs[g(t)]=r}return e},{attrs:{}}),o=r.style,a=void 0===o?{}:o,c=h(r,f);return s.attrs.style=l(l({},s.attrs.style),a),t.apply(void 0,[i.tag,l(l({},s.attrs),c)].concat(d(n)))}.bind(null,o.createElement)},98092(e){var t,i=Object.defineProperty,r=Object.defineProperties,n=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyDescriptors,o=Object.getOwnPropertyNames,a=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,u=(e,t,r)=>t in e?i(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,h=(e,t)=>{for(var i in t||(t={}))l.call(t,i)&&u(e,i,t[i]);if(a)for(var i of a(t))c.call(t,i)&&u(e,i,t[i]);return e},d=(e,t)=>r(e,s(t)),p=(e,t)=>{for(var r in t)i(e,r,{get:t[r],enumerable:!0})},g=(e,t,r,s)=>{for(var o,a=s>1?void 0:s?n(t,r):t,l=e.length-1;l>=0;l--)(o=e[l])&&(a=(s?o(t,r,a):o(a))||a);return s&&a&&i(t,r,a),a},f=(e,t)=>(i,r)=>t(i,r,e),m={};p(m,{ALWAYS_SYNC_GLOBAL_EVENTS:()=>ut,AbstractHeaderCellCtrl:()=>el,AgAbstractField:()=>Fn,AgAbstractLabel:()=>On,AgAutocomplete:()=>Cc,AgCheckbox:()=>Un,AgDialog:()=>hc,AgGroupComponent:()=>tc,AgInputDateField:()=>Kl,AgInputNumberField:()=>rs,AgInputRange:()=>$l,AgInputTextArea:()=>jl,AgInputTextField:()=>is,AgMenuItemComponent:()=>lc,AgMenuItemRenderer:()=>ho,AgMenuList:()=>sc,AgMenuPanel:()=>oc,AgPanel:()=>uc,AgPickerField:()=>kn,AgPromise:()=>dn,AgPromiseStatus:()=>hn,AgRadioButton:()=>Wn,AgRichSelect:()=>Xl,AgSelect:()=>Bn,AgSlider:()=>Jl,AgStackComponentsRegistry:()=>Ot,AgToggleButton:()=>Wl,AlignedGridsService:()=>Mc,AnimateShowChangeCellRenderer:()=>Ds,AnimateSlideCellRenderer:()=>Is,AnimationFrameService:()=>_l,AutoScrollService:()=>ko,AutoWidthCalculator:()=>Il,Autowired:()=>he,BarColumnLabelPlacement:()=>Wu,BaseComponentWrapper:()=>zu,BaseCreator:()=>Eh,BaseGridSerializingSession:()=>Ah,Bean:()=>ue,BeanStub:()=>nt,Beans:()=>la,BodyDropPivotTarget:()=>za,BodyDropTarget:()=>ja,CellComp:()=>Va,CellCtrl:()=>fa,CellNavigationService:()=>Tc,CellPositionUtils:()=>Jc,CellRangeType:()=>ra,ChangedPath:()=>Gl,ChartMappings:()=>Uu,CheckboxCellEditor:()=>uo,CheckboxCellRenderer:()=>co,CheckboxSelectionComponent:()=>Os,ClientSideRowModelModule:()=>th,ClientSideRowModelSteps:()=>Pl,Column:()=>be,ColumnApi:()=>_c,ColumnFactory:()=>st,ColumnGroup:()=>lt,ColumnKeyCreator:()=>P,ColumnModel:()=>Mt,Component:()=>wn,ComponentUtil:()=>Nt,Context:()=>oe,CssClassApplier:()=>da,CssClassManager:()=>gn,CsvCreator:()=>Rh,CsvExportModule:()=>xh,CtrlsService:()=>cu,DataTypeService:()=>_u,DateCellEditor:()=>so,DateFilter:()=>Zn,DateStringCellEditor:()=>ao,DisplayedGroupCreator:()=>Pt,Downloader:()=>Th,DragAndDropService:()=>Vs,DragService:()=>Vo,DragSourceType:()=>Gs,Environment:()=>Kc,EventService:()=>me,Events:()=>ct,ExcelFactoryMode:()=>Oo,ExpansionService:()=>xl,ExpressionService:()=>xc,FilterManager:()=>jo,FilterWrapperComp:()=>Ko,FloatingFilterMapper:()=>Lo,FocusService:()=>Fc,GROUP_AUTO_COLUMN_ID:()=>dt,Grid:()=>Vu,GridApi:()=>Uo,GridBodyComp:()=>La,GridBodyCtrl:()=>ta,GridComp:()=>Nc,GridCoreCreator:()=>Bu,GridCtrl:()=>Lc,GridHeaderComp:()=>yl,GridHeaderCtrl:()=>vl,GridOptionsService:()=>bu,GridSerializer:()=>Ph,GroupCellRenderer:()=>Ks,GroupCellRendererCtrl:()=>Ws,GroupInstanceIdCreator:()=>ht,HeaderCellCtrl:()=>ol,HeaderFilterCellComp:()=>Yo,HeaderFilterCellCtrl:()=>rl,HeaderGroupCellCtrl:()=>cl,HeaderNavigationDirection:()=>fl,HeaderNavigationService:()=>ml,HeaderPositionUtils:()=>su,HeaderRowComp:()=>Xa,HeaderRowContainerComp:()=>gl,HeaderRowContainerCtrl:()=>dl,HeaderRowCtrl:()=>hl,HeaderRowType:()=>Qa,HorizontalDirection:()=>ks,HorizontalResizeService:()=>wl,InfiniteRowModelModule:()=>uh,KeyCode:()=>Qr,LargeTextCellEditor:()=>Ms,LayoutCssClasses:()=>Qo,LocaleService:()=>Eu,Logger:()=>Ic,LoggerFactory:()=>Dc,ManagedFocusFeature:()=>Pn,MenuService:()=>Dl,ModuleNames:()=>re,ModuleRegistry:()=>se,MouseEventService:()=>Oa,MoveColumnFeature:()=>Wa,NavigationService:()=>Fa,NumberCellEditor:()=>ro,NumberFilter:()=>as,NumberSequence:()=>un,Optional:()=>de,PaginationProxy:()=>zl,PillDragComp:()=>wc,PillDropZonePanel:()=>bc,PinnedRowModel:()=>Fl,PopupComponent:()=>As,PopupEditorWrapper:()=>Ga,PopupService:()=>pc,PositionableFeature:()=>In,PostConstruct:()=>le,PreConstruct:()=>ae,PreDestroy:()=>ce,PropertyKeys:()=>It,ProvidedColumnGroup:()=>Ae,ProvidedFilter:()=>Nn,Qualifier:()=>ge,QuerySelector:()=>Sn,RefSelector:()=>bn,ResizeObserverService:()=>Rl,RowAnimationCssClasses:()=>Jo,RowContainerComp:()=>Ba,RowContainerCtrl:()=>Ia,RowContainerName:()=>Ma,RowContainerType:()=>Ra,RowCtrl:()=>Ca,RowHighlightPosition:()=>Fo,RowNode:()=>Ns,RowNodeBlock:()=>Hl,RowNodeBlockLoader:()=>Bl,RowNodeSorter:()=>lu,RowPositionUtils:()=>Zc,RowRenderer:()=>Nl,RowType:()=>_h,ScalarFilter:()=>qn,ScrollVisibleService:()=>Na,SelectCellEditor:()=>Rs,SelectableService:()=>qc,SelectionHandleType:()=>ia,ServerSideTransactionResultStatus:()=>kl,SetLeftFeature:()=>tl,SimpleFilter:()=>$n,SortController:()=>Oc,SortIndicatorComp:()=>ys,StandardMenuFactory:()=>Sl,StylingService:()=>Ul,TabGuardClassNames:()=>bl,TabGuardComp:()=>Al,TabGuardCtrl:()=>El,TabbedLayout:()=>Ml,TextCellEditor:()=>xs,TextFilter:()=>us,TextFloatingFilter:()=>fs,Timer:()=>pn,TooltipFeature:()=>vn,TooltipStateManager:()=>mn,TouchListener:()=>vs,UserComponentFactory:()=>No,UserComponentRegistry:()=>po,ValueCache:()=>Hc,ValueService:()=>Pc,VanillaFrameworkOverrides:()=>Ac,VerticalDirection:()=>Fs,VirtualList:()=>Ql,VirtualListDragFeature:()=>Bo,XmlFactory:()=>Ih,ZipContainer:()=>Bh,_:()=>cn,createGrid:()=>Gu,getRowContainerTypeForName:()=>_a,provideGlobalGridOptions:()=>ku}),e.exports=(t=m,((e,t,r,s)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let r of o(t))l.call(e,r)||void 0===r||i(e,r,{get:()=>t[r],enumerable:!(s=n(t,r))||s.enumerable});return e})(i({},"__esModule",{value:!0}),t));var v={};function C(e){return null==e||""===e?null:e}function y(e,t=!1){return null!=e&&(""!==e||t)}function w(e){return!y(e)}function S(e){return null==e||0===e.length}function b(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function E(e){if(void 0===e)return;if(null===e||""===e)return null;if("number"==typeof e)return isNaN(e)?void 0:e;const t=parseInt(e,10);return isNaN(t)?void 0:t}function A(e){if(void 0!==e)return null!==e&&""!==e&&("boolean"==typeof e?e:/true/i.test(e))}function T(e){if(null!=e&&""!==e)return e}function M(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}function R(e,t,i=!1){const r=null==e,n=null==t;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),r&&n)return 0;if(r)return-1;if(n)return 1;function s(e,t){return e>t?1:e<t?-1:0}if("string"!=typeof e)return s(e,t);if(!i)return s(e,t);try{return e.localeCompare(t)}catch(i){return s(e,t)}}function _(e){if(e instanceof Set||e instanceof Map){const t=[];return e.forEach(e=>t.push(e)),t}return Object.values(e)}p(v,{attrToBoolean:()=>A,attrToNumber:()=>E,attrToString:()=>T,defaultComparator:()=>R,exists:()=>y,jsonEquals:()=>M,makeNull:()=>C,missing:()=>w,missingOrEmpty:()=>S,toStringOrNull:()=>b,values:()=>_});var P=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=b(e);let i=0;for(;;){let r;if(e?(r=e,0!==i&&(r+="_"+i)):t?(r=t,0!==i&&(r+="_"+i)):r=i,!this.existingKeys[r])return this.existingKeys[r]=!0,String(r);i++}}},x={};p(x,{SKIP_JS_BUILTINS:()=>D,cloneObject:()=>L,deepCloneDefinition:()=>N,getAllValuesInObject:()=>O,getValueUsingField:()=>k,isNonNullObject:()=>V,iterateObject:()=>I,mergeDeep:()=>F,removeAllReferences:()=>G});var D=new Set(["__proto__","constructor","prototype"]);function I(e,t){if(null!=e)if(Array.isArray(e))for(let i=0;i<e.length;i++)t(i.toString(),e[i]);else for(const[i,r]of Object.entries(e))t(i,r)}function L(e){const t={},i=Object.keys(e);for(let r=0;r<i.length;r++){if(D.has(i[r]))continue;const n=i[r],s=e[n];t[n]=s}return t}function N(e,t){if(!e)return;const i=e,r={};return Object.keys(i).forEach(e=>{if(t&&t.indexOf(e)>=0||D.has(e))return;const n=i[e],s=V(n)&&n.constructor===Object;r[e]=s?N(n):n}),r}function O(e){if(!e)return[];const t=Object;if("function"==typeof t.values)return t.values(e);const i=[];for(const t in e)e.hasOwnProperty(t)&&e.propertyIsEnumerable(t)&&i.push(e[t]);return i}function F(e,t,i=!0,r=!1){y(t)&&I(t,(t,n)=>{if(D.has(t))return;let s=e[t];s!==n&&(r&&null==s&&null!=n&&"object"==typeof n&&n.constructor===Object&&(s={},e[t]=s),V(n)&&V(s)&&!Array.isArray(s)?F(s,n,i,r):(i||void 0!==n)&&(e[t]=n))})}function k(e,t,i){if(!t||!e)return;if(!i)return e[t];const r=t.split(".");let n=e;for(let e=0;e<r.length;e++){if(null==n)return;n=n[r[e]]}return n}function G(e,t=[],i){Object.keys(e).forEach(i=>{"object"!=typeof e[i]||t.includes(i)||(e[i]=void 0)});const r=Object.getPrototypeOf(e),n={};Object.getOwnPropertyNames(r).forEach(e=>{if("function"==typeof r[e]&&!t.includes(e)){const t=()=>{console.warn((e=>`AG Grid: Grid API function ${e}() cannot be called as the grid has been destroyed.\n    It is recommended to remove local references to the grid api. Alternatively, check gridApi.isDestroyed() to avoid calling methods against a destroyed grid.\n    To run logic when the grid is about to be destroyed use the gridPreDestroy event. See: ${i}`)(e))};n[e]={value:t,writable:!0}}}),Object.defineProperties(e,n)}function V(e){return"object"==typeof e&&null!==e}var H={};p(H,{compose:()=>te,debounce:()=>Z,doOnce:()=>z,errorOnce:()=>W,executeAfter:()=>X,executeInAWhile:()=>$,executeNextVMTurn:()=>Q,getFunctionName:()=>j,isFunction:()=>K,noop:()=>ie,throttle:()=>J,waitUntil:()=>ee,warnOnce:()=>U});var B={};function z(e,t){B[t]||(e(),B[t]=!0)}function U(e){z(()=>console.warn("AG Grid: "+e),e)}function W(e){z(()=>console.error("AG Grid: "+e),e)}function j(e){if(e.name)return e.name;const t=/function\s+([^\(]+)/.exec(e.toString());return t&&2===t.length?t[1].trim():null}function K(e){return!!(e&&e.constructor&&e.call&&e.apply)}function $(e){X(e,400)}var q=[],Y=!1;function Q(e){q.push(e),Y||(Y=!0,window.setTimeout(()=>{const e=q.slice();q.length=0,Y=!1,e.forEach(e=>e())},0))}function X(e,t=0){e.length>0&&window.setTimeout(()=>e.forEach(e=>e()),t)}function Z(e,t){let i;return function(...r){const n=this;window.clearTimeout(i),i=window.setTimeout(function(){e.apply(n,r)},t)}}function J(e,t){let i=0;return function(...r){const n=(new Date).getTime();n-i<t||(i=n,e.apply(this,r))}}function ee(e,t,i=100,r){const n=(new Date).getTime();let s=null,o=!1;const a=()=>{const a=(new Date).getTime()-n>i;(e()||a)&&(t(),o=!0,null!=s&&(window.clearInterval(s),s=null),a&&r&&console.warn(r))};a(),o||(s=window.setInterval(a,10))}function te(...e){return t=>e.reduce((e,t)=>t(e),t)}var ie=()=>{},re=(e=>(e.CommunityCoreModule="@ag-grid-community/core",e.InfiniteRowModelModule="@ag-grid-community/infinite-row-model",e.ClientSideRowModelModule="@ag-grid-community/client-side-row-model",e.CsvExportModule="@ag-grid-community/csv-export",e.EnterpriseCoreModule="@ag-grid-enterprise/core",e.RowGroupingModule="@ag-grid-enterprise/row-grouping",e.ColumnsToolPanelModule="@ag-grid-enterprise/column-tool-panel",e.FiltersToolPanelModule="@ag-grid-enterprise/filter-tool-panel",e.MenuModule="@ag-grid-enterprise/menu",e.SetFilterModule="@ag-grid-enterprise/set-filter",e.MultiFilterModule="@ag-grid-enterprise/multi-filter",e.StatusBarModule="@ag-grid-enterprise/status-bar",e.SideBarModule="@ag-grid-enterprise/side-bar",e.RangeSelectionModule="@ag-grid-enterprise/range-selection",e.MasterDetailModule="@ag-grid-enterprise/master-detail",e.RichSelectModule="@ag-grid-enterprise/rich-select",e.GridChartsModule="@ag-grid-enterprise/charts",e.ViewportRowModelModule="@ag-grid-enterprise/viewport-row-model",e.ServerSideRowModelModule="@ag-grid-enterprise/server-side-row-model",e.ExcelExportModule="@ag-grid-enterprise/excel-export",e.ClipboardModule="@ag-grid-enterprise/clipboard",e.SparklinesModule="@ag-grid-enterprise/sparklines",e.AdvancedFilterModule="@ag-grid-enterprise/advanced-filter",e.AngularModule="@ag-grid-community/angular",e.ReactModule="@ag-grid-community/react",e.VueModule="@ag-grid-community/vue",e))(re||{}),ne=class e{static register(t){e.__register(t,!0,void 0)}static registerModules(t){e.__registerModules(t,!0,void 0)}static __register(t,i,r){e.runVersionChecks(t),void 0!==r?(e.areGridScopedModules=!0,void 0===e.gridModulesMap[r]&&(e.gridModulesMap[r]={}),e.gridModulesMap[r][t.moduleName]=t):e.globalModulesMap[t.moduleName]=t,e.setModuleBased(i)}static __unRegisterGridModules(t){delete e.gridModulesMap[t]}static __registerModules(t,i,r){e.setModuleBased(i),t&&t.forEach(t=>e.__register(t,i,r))}static isValidModuleVersion(t){const[i,r]=t.version.split(".")||[],[n,s]=e.currentModuleVersion.split(".")||[];return i===n&&r===s}static runVersionChecks(t){if(e.currentModuleVersion||(e.currentModuleVersion=t.version),t.version?e.isValidModuleVersion(t)||console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is version ${t.version} but the other modules are version ${this.currentModuleVersion}. Please update all modules to the same version.`):console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is incompatible. Please update all modules to the same version.`),t.validate){const e=t.validate();if(!e.isValid){const t=e;console.error(`AG Grid: ${t.message}`)}}}static setModuleBased(t){void 0===e.moduleBased?e.moduleBased=t:e.moduleBased!==t&&z(()=>{console.warn("AG Grid: You are mixing modules (i.e. @ag-grid-community/core) and packages (ag-grid-community) - you can only use one or the other of these mechanisms."),console.warn("Please see https://www.ag-grid.com/javascript-grid/modules/ for more information.")},"ModulePackageCheck")}static __setIsBundled(){e.isBundled=!0}static __assertRegistered(t,i,r){var n;if(this.__isRegistered(t,r))return!0;const s=i+t;let o;if(e.isBundled)o=`AG Grid: unable to use ${i} as 'ag-grid-enterprise' has not been loaded. Check you are using the Enterprise bundle:\n        \n        <script src="https://cdn.jsdelivr.net/npm/ag-grid-enterprise@AG_GRID_VERSION/dist/ag-grid-enterprise.min.js"><\/script>\n        \nFor more info see: https://ag-grid.com/javascript-data-grid/getting-started/#getting-started-with-ag-grid-enterprise`;else if(e.moduleBased||void 0===e.moduleBased){let s=null==(n=Object.entries(re).find(([e,i])=>i===t))?void 0:n[0];o=`AG Grid: unable to use ${i} as the ${s} is not registered${e.areGridScopedModules?` for gridId: ${r}`:""}. Check if you have registered the module:\n           \n    import { ModuleRegistry } from '@ag-grid-community/core';\n    import { ${s} } from '${t}';\n    \n    ModuleRegistry.registerModules([ ${s} ]);\n\nFor more info see: https://www.ag-grid.com/javascript-grid/modules/`}else o=`AG Grid: unable to use ${i} as package 'ag-grid-enterprise' has not been imported. Check that you have imported the package:\n            \n    import 'ag-grid-enterprise';`;return z(()=>{console.warn(o)},s),!1}static __isRegistered(t,i){var r;return!!e.globalModulesMap[t]||!!(null==(r=e.gridModulesMap[i])?void 0:r[t])}static __getRegisteredModules(t){return[..._(e.globalModulesMap),..._(e.gridModulesMap[t]||{})]}static __getGridRegisteredModules(t){var i;return _(null!=(i=e.gridModulesMap[t])?i:{})||[]}static __isPackageBased(){return!e.moduleBased}};ne.globalModulesMap={},ne.gridModulesMap={},ne.areGridScopedModules=!1;var se=ne,oe=class{constructor(e,t){if(this.beanWrappers={},this.destroyed=!1,!e||!e.beanClasses)return;this.contextParams=e,this.logger=t,this.logger.log(">> creating ag-Application Context"),this.createBeans();const i=this.getBeanInstances();this.wireBeans(i),this.logger.log(">> ag-Application Context ready - component is alive")}getBeanInstances(){return _(this.beanWrappers).map(e=>e.beanInstance)}createBean(e,t){if(!e)throw Error("Can't wire to bean since it is null");return this.wireBeans([e],t),e}wireBeans(e,t){this.autoWireBeans(e),this.methodWireBeans(e),this.callLifeCycleMethods(e,"preConstructMethods"),y(t)&&e.forEach(t),this.callLifeCycleMethods(e,"postConstructMethods")}createBeans(){this.contextParams.beanClasses.forEach(this.createBeanWrapper.bind(this)),I(this.beanWrappers,(e,t)=>{let i;t.bean.__agBeanMetaData&&t.bean.__agBeanMetaData.autowireMethods&&t.bean.__agBeanMetaData.autowireMethods.agConstructor&&(i=t.bean.__agBeanMetaData.autowireMethods.agConstructor);const r=this.getBeansForParameters(i,t.bean.name),n=new(t.bean.bind.apply(t.bean,[null,...r]));t.beanInstance=n});const e=Object.keys(this.beanWrappers).join(", ");this.logger.log(`created beans: ${e}`)}createBeanWrapper(e){const t=e.__agBeanMetaData;if(!t){let t;return t=e.prototype.constructor?j(e.prototype.constructor):""+e,void console.error(`Context item ${t} is not a bean`)}const i={bean:e,beanInstance:null,beanName:t.beanName};this.beanWrappers[t.beanName]=i}autoWireBeans(e){e.forEach(e=>{this.forEachMetaDataInHierarchy(e,(t,i)=>{const r=t.agClassAttributes;r&&r.forEach(t=>{const r=this.lookupBeanInstance(i,t.beanName,t.optional);e[t.attributeName]=r})})})}methodWireBeans(e){e.forEach(e=>{this.forEachMetaDataInHierarchy(e,(t,i)=>{I(t.autowireMethods,(t,r)=>{if("agConstructor"===t)return;const n=this.getBeansForParameters(r,i);e[t].apply(e,n)})})})}forEachMetaDataInHierarchy(e,t){let i=Object.getPrototypeOf(e);for(;null!=i;){const e=i.constructor;e.hasOwnProperty("__agBeanMetaData")&&t(e.__agBeanMetaData,this.getBeanName(e)),i=Object.getPrototypeOf(i)}}getBeanName(e){if(e.__agBeanMetaData&&e.__agBeanMetaData.beanName)return e.__agBeanMetaData.beanName;const t=e.toString();return t.substring(9,t.indexOf("("))}getBeansForParameters(e,t){const i=[];return e&&I(e,(e,r)=>{const n=this.lookupBeanInstance(t,r);i[Number(e)]=n}),i}lookupBeanInstance(e,t,i=!1){if(this.destroyed)return this.logger.log(`AG Grid: bean reference ${t} is used after the grid is destroyed!`),null;if("context"===t)return this;if(this.contextParams.providedBeanInstances&&this.contextParams.providedBeanInstances.hasOwnProperty(t))return this.contextParams.providedBeanInstances[t];const r=this.beanWrappers[t];return r?r.beanInstance:(i||console.error(`AG Grid: unable to find bean reference ${t} while initialising ${e}`),null)}callLifeCycleMethods(e,t){e.forEach(e=>this.callLifeCycleMethodsOnBean(e,t))}callLifeCycleMethodsOnBean(e,t,i){const r={};this.forEachMetaDataInHierarchy(e,e=>{const n=e[t];n&&n.forEach(e=>{e!=i&&(r[e]=!0)})}),Object.keys(r).forEach(t=>e[t]())}getBean(e){return this.lookupBeanInstance("getBean",e,!0)}destroy(){if(this.destroyed)return;this.destroyed=!0,this.logger.log(">> Shutting down ag-Application Context");const e=this.getBeanInstances();this.destroyBeans(e),this.contextParams.providedBeanInstances=null,se.__unRegisterGridModules(this.contextParams.gridId),this.logger.log(">> ag-Application Context shut down - component is dead")}destroyBean(e){e&&this.destroyBeans([e])}destroyBeans(e){return e?(e.forEach(e=>{this.callLifeCycleMethodsOnBean(e,"preDestroyMethods","destroy");const t=e;"function"==typeof t.destroy&&t.destroy()}),[]):[]}isDestroyed(){return this.destroyed}getGridId(){return this.contextParams.gridId}};function ae(e,t,i){const r=fe(e.constructor);r.preConstructMethods||(r.preConstructMethods=[]),r.preConstructMethods.push(t)}function le(e,t,i){const r=fe(e.constructor);r.postConstructMethods||(r.postConstructMethods=[]),r.postConstructMethods.push(t)}function ce(e,t,i){const r=fe(e.constructor);r.preDestroyMethods||(r.preDestroyMethods=[]),r.preDestroyMethods.push(t)}function ue(e){return t=>{fe(t).beanName=e}}function he(e){return(t,i,r)=>{pe(t,e,!1,0,i,null)}}function de(e){return(t,i,r)=>{pe(t,e,!0,0,i,null)}}function pe(e,t,i,r,n,s){if(null===t)return void console.error("AG Grid: Autowired name should not be null");if("number"==typeof s)return void console.error("AG Grid: Autowired should be on an attribute");const o=fe(e.constructor);o.agClassAttributes||(o.agClassAttributes=[]),o.agClassAttributes.push({attributeName:n,beanName:t,optional:i})}function ge(e){return(t,i,r)=>{const n="function"==typeof t?t:t.constructor;let s;if("number"==typeof r){let t;i?(s=fe(n),t=i):(s=fe(n),t="agConstructor"),s.autowireMethods||(s.autowireMethods={}),s.autowireMethods[t]||(s.autowireMethods[t]={}),s.autowireMethods[t][r]=e}}}function fe(e){return e.hasOwnProperty("__agBeanMetaData")||(e.__agBeanMetaData={}),e.__agBeanMetaData}var me=class{constructor(){this.allSyncListeners=new Map,this.allAsyncListeners=new Map,this.globalSyncListeners=new Set,this.globalAsyncListeners=new Set,this.asyncFunctionsQueue=[],this.scheduled=!1,this.firedEvents={}}setBeans(e,t,i=null,r=null){if(this.frameworkOverrides=t,this.gos=e,i){const t=e.useAsyncEvents();this.addGlobalListener(i,t)}r&&this.addGlobalListener(r,!1)}setFrameworkOverrides(e){this.frameworkOverrides=e}getListeners(e,t,i){const r=t?this.allAsyncListeners:this.allSyncListeners;let n=r.get(e);return!n&&i&&(n=new Set,r.set(e,n)),n}noRegisteredListenersExist(){return 0===this.allSyncListeners.size&&0===this.allAsyncListeners.size&&0===this.globalSyncListeners.size&&0===this.globalAsyncListeners.size}addEventListener(e,t,i=!1){this.getListeners(e,i,!0).add(t)}removeEventListener(e,t,i=!1){const r=this.getListeners(e,i,!1);r&&(r.delete(t),0===r.size)&&(i?this.allAsyncListeners:this.allSyncListeners).delete(e)}addGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).add(e)}removeGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).delete(e)}dispatchEvent(e){let t=e;this.gos&&this.gos.addGridCommonParams(t),this.dispatchToListeners(t,!0),this.dispatchToListeners(t,!1),this.firedEvents[t.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){var i;const r=e.type;if(t&&"event"in e){const t=e.event;t instanceof Event&&(e.eventPath=t.composedPath())}const n=null!=(i=this.getListeners(r,t,!1))?i:new Set,s=new Set(n);s.size>0&&((i,r)=>{i.forEach(i=>{if(!r.has(i))return;const n=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>i(e)):()=>i(e);t?this.dispatchAsync(n):n()})})(s,n),new Set(t?this.globalAsyncListeners:this.globalSyncListeners).forEach(i=>{const n=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>i(r,e)):()=>i(r,e);t?this.dispatchAsync(n):n()})}dispatchAsync(e){this.asyncFunctionsQueue.push(e),this.scheduled||(this.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)}),this.scheduled=!0)}flushAsyncQueue(){this.scheduled=!1;const e=this.asyncFunctionsQueue.slice();this.asyncFunctionsQueue=[],e.forEach(e=>e())}};g([f(0,ge("gridOptionsService")),f(1,ge("frameworkOverrides")),f(2,ge("globalEventListener")),f(3,ge("globalSyncEventListener"))],me.prototype,"setBeans",1),me=g([ue("eventService")],me);var ve=class{constructor(e){this.frameworkOverrides=e,this.wrappedListeners=new Map,this.wrappedGlobalListeners=new Map}wrap(e){let t=e;return this.frameworkOverrides.shouldWrapOutgoing&&(t=t=>{this.frameworkOverrides.wrapOutgoing(()=>e(t))},this.wrappedListeners.set(e,t)),t}wrapGlobal(e){let t=e;return this.frameworkOverrides.shouldWrapOutgoing&&(t=(t,i)=>{this.frameworkOverrides.wrapOutgoing(()=>e(t,i))},this.wrappedGlobalListeners.set(e,t)),t}unwrap(e){var t;return null!=(t=this.wrappedListeners.get(e))?t:e}unwrapGlobal(e){var t;return null!=(t=this.wrappedGlobalListeners.get(e))?t:e}},Ce={resizable:!0,sortable:!0},ye=0;function we(){return ye++}var Se=class e{constructor(e,t,i,r){this.instanceId=we(),this.autoHeaderHeight=null,this.moving=!1,this.menuVisible=!1,this.lastLeftPinned=!1,this.firstRightPinned=!1,this.filterActive=!1,this.eventService=new me,this.tooltipEnabled=!1,this.rowGroupActive=!1,this.pivotActive=!1,this.aggregationActive=!1,this.colDef=e,this.userProvidedColDef=t,this.colId=i,this.primary=r,this.setState(e)}getInstanceId(){return this.instanceId}setState(e){void 0!==e.sort?"asc"!==e.sort&&"desc"!==e.sort||(this.sort=e.sort):"asc"!==e.initialSort&&"desc"!==e.initialSort||(this.sort=e.initialSort);const t=e.sortIndex,i=e.initialSortIndex;void 0!==t?null!==t&&(this.sortIndex=t):null!==i&&(this.sortIndex=i);const r=e.hide,n=e.initialHide;this.visible=void 0!==r?!r:!n,void 0!==e.pinned?this.setPinned(e.pinned):this.setPinned(e.initialPinned);const s=e.flex,o=e.initialFlex;void 0!==s?this.flex=s:void 0!==o&&(this.flex=o)}setColDef(e,t,i){this.colDef=e,this.userProvidedColDef=t,this.initMinAndMaxWidths(),this.initDotNotation(),this.initTooltip(),this.eventService.dispatchEvent(this.createColumnEvent("colDefChanged",i))}getUserProvidedColDef(){return this.userProvidedColDef}setParent(e){this.parent=e}getParent(){return this.parent}setOriginalParent(e){this.originalParent=e}getOriginalParent(){return this.originalParent}initialise(){this.initMinAndMaxWidths(),this.resetActualWidth("gridInitializing"),this.initDotNotation(),this.initTooltip()}initDotNotation(){const e=this.gos.get("suppressFieldDotNotation");this.fieldContainsDots=y(this.colDef.field)&&this.colDef.field.indexOf(".")>=0&&!e,this.tooltipFieldContainsDots=y(this.colDef.tooltipField)&&this.colDef.tooltipField.indexOf(".")>=0&&!e}initMinAndMaxWidths(){var e,t;const i=this.colDef;this.minWidth=null!=(e=i.minWidth)?e:this.environment.getMinColWidth(),this.maxWidth=null!=(t=i.maxWidth)?t:Number.MAX_SAFE_INTEGER}initTooltip(){this.tooltipEnabled=y(this.colDef.tooltipField)||y(this.colDef.tooltipValueGetter)||y(this.colDef.tooltipComponent)}resetActualWidth(e){const t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){var t,i;const r=null!=(t=e.minWidth)?t:this.environment.getMinColWidth(),n=null!=(i=e.maxWidth)?i:Number.MAX_SAFE_INTEGER;let s;const o=E(e.width),a=E(e.initialWidth);return s=null!=o?o:null!=a?a:200,Math.max(Math.min(s,n),r)}isEmptyGroup(){return!1}isRowGroupDisplayed(e){if(w(this.colDef)||w(this.colDef.showRowGroup))return!1;const t=!0===this.colDef.showRowGroup,i=this.colDef.showRowGroup===e;return t||i}isPrimary(){return this.primary}isFilterAllowed(){return!!this.colDef.filter}isFieldContainsDots(){return this.fieldContainsDots}isTooltipEnabled(){return this.tooltipEnabled}isTooltipFieldContainsDots(){return this.tooltipFieldContainsDots}addEventListener(e,t){var i,r;this.frameworkOverrides.shouldWrapOutgoing&&!this.frameworkEventListenerService&&(this.eventService.setFrameworkOverrides(this.frameworkOverrides),this.frameworkEventListenerService=new ve(this.frameworkOverrides));const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.wrap(t))?r:t;this.eventService.addEventListener(e,n)}removeEventListener(e,t){var i,r;const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.unwrap(t))?r:t;this.eventService.removeEventListener(e,n)}createColumnFunctionCallbackParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,column:this,colDef:this.colDef})}isSuppressNavigable(e){if("boolean"==typeof this.colDef.suppressNavigable)return this.colDef.suppressNavigable;if("function"==typeof this.colDef.suppressNavigable){const t=this.createColumnFunctionCallbackParams(e);return(0,this.colDef.suppressNavigable)(t)}return!1}isCellEditable(e){return!(e.group&&!this.gos.get("enableGroupEdit"))&&this.isColumnFunc(e,this.colDef.editable)}isSuppressFillHandle(){return!!this.colDef.suppressFillHandle}isAutoHeight(){return!!this.colDef.autoHeight}isAutoHeaderHeight(){return!!this.colDef.autoHeaderHeight}isRowDrag(e){return this.isColumnFunc(e,this.colDef.rowDrag)}isDndSource(e){return this.isColumnFunc(e,this.colDef.dndSource)}isCellCheckboxSelection(e){return this.isColumnFunc(e,this.colDef.checkboxSelection)}isSuppressPaste(e){return this.isColumnFunc(e,this.colDef?this.colDef.suppressPaste:null)}isResizable(){return!!this.getColDefValue("resizable")}getColDefValue(e){var t;return null!=(t=this.colDef[e])?t:Ce[e]}isColumnFunc(e,t){return"boolean"==typeof t?t:"function"==typeof t&&t(this.createColumnFunctionCallbackParams(e))}setMoving(e,t){this.moving=e,this.eventService.dispatchEvent(this.createColumnEvent("movingChanged",t))}createColumnEvent(e,t){return this.gos.addGridCommonParams({type:e,column:this,columns:[this],source:t})}isMoving(){return this.moving}getSort(){return this.sort}setSort(e,t){this.sort!==e&&(this.sort=e,this.eventService.dispatchEvent(this.createColumnEvent("sortChanged",t))),this.dispatchStateUpdatedEvent("sort")}setMenuVisible(e,t){this.menuVisible!==e&&(this.menuVisible=e,this.eventService.dispatchEvent(this.createColumnEvent("menuVisibleChanged",t)))}isMenuVisible(){return this.menuVisible}isSortable(){return!!this.getColDefValue("sortable")}isSortAscending(){return"asc"===this.sort}isSortDescending(){return"desc"===this.sort}isSortNone(){return w(this.sort)}isSorting(){return y(this.sort)}getSortIndex(){return this.sortIndex}setSortIndex(e){this.sortIndex=e,this.dispatchStateUpdatedEvent("sortIndex")}setAggFunc(e){this.aggFunc=e,this.dispatchStateUpdatedEvent("aggFunc")}getAggFunc(){return this.aggFunc}getLeft(){return this.left}getOldLeft(){return this.oldLeft}getRight(){return this.left+this.actualWidth}setLeft(e,t){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.eventService.dispatchEvent(this.createColumnEvent("leftChanged",t)))}isFilterActive(){return this.filterActive}setFilterActive(e,t,i){this.filterActive!==e&&(this.filterActive=e,this.eventService.dispatchEvent(this.createColumnEvent("filterActiveChanged",t)));const r=this.createColumnEvent("filterChanged",t);i&&F(r,i),this.eventService.dispatchEvent(r)}isHovered(){return this.columnHoverService.isHovered(this)}setPinned(e){this.pinned=!0===e||"left"===e?"left":"right"===e?"right":null,this.dispatchStateUpdatedEvent("pinned")}setFirstRightPinned(e,t){this.firstRightPinned!==e&&(this.firstRightPinned=e,this.eventService.dispatchEvent(this.createColumnEvent("firstRightPinnedChanged",t)))}setLastLeftPinned(e,t){this.lastLeftPinned!==e&&(this.lastLeftPinned=e,this.eventService.dispatchEvent(this.createColumnEvent("lastLeftPinnedChanged",t)))}isFirstRightPinned(){return this.firstRightPinned}isLastLeftPinned(){return this.lastLeftPinned}isPinned(){return"left"===this.pinned||"right"===this.pinned}isPinnedLeft(){return"left"===this.pinned}isPinnedRight(){return"right"===this.pinned}getPinned(){return this.pinned}setVisible(e,t){const i=!0===e;this.visible!==i&&(this.visible=i,this.eventService.dispatchEvent(this.createColumnEvent("visibleChanged",t))),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}isSpanHeaderHeight(){const e=this.getColDef();return!e.suppressSpanHeaderHeight&&!e.autoHeaderHeight}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e||!e.isPadding())return{numberOfParents:0,isSpanningTotal:!1};const t=e.getPaddingLevel()+1;let i=!0;for(;e;){if(!e.isPadding()){i=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:i}}getColDef(){return this.colDef}getColumnGroupShow(){return this.colDef.columnGroupShow}getColId(){return this.colId}getId(){return this.colId}getUniqueId(){return this.colId}getDefinition(){return this.colDef}getActualWidth(){return this.actualWidth}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(w(this.colDef.colSpan))return 1;const t=this.createBaseColDefParams(e),i=this.colDef.colSpan(t);return Math.max(i,1)}getRowSpan(e){if(w(this.colDef.rowSpan))return 1;const t=this.createBaseColDefParams(e),i=this.colDef.rowSpan(t);return Math.max(i,1)}setActualWidth(e,t,i=!1){null!=this.minWidth&&(e=Math.max(e,this.minWidth)),null!=this.maxWidth&&(e=Math.min(e,this.maxWidth)),this.actualWidth!==e&&(this.actualWidth=e,this.flex&&"flex"!==t&&"gridInitializing"!==t&&(this.flex=null),i||this.fireColumnWidthChangedEvent(t)),this.dispatchStateUpdatedEvent("width")}fireColumnWidthChangedEvent(e){this.eventService.dispatchEvent(this.createColumnEvent("widthChanged",e))}isGreaterThanMax(e){return null!=this.maxWidth&&e>this.maxWidth}getMinWidth(){return this.minWidth}getMaxWidth(){return this.maxWidth}getFlex(){return this.flex||0}setFlex(e){this.flex!==e&&(this.flex=e),this.dispatchStateUpdatedEvent("flex")}setMinimum(e){y(this.minWidth)&&this.setActualWidth(this.minWidth,e)}setRowGroupActive(e,t){this.rowGroupActive!==e&&(this.rowGroupActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnRowGroupChanged",t))),this.dispatchStateUpdatedEvent("rowGroup")}isRowGroupActive(){return this.rowGroupActive}setPivotActive(e,t){this.pivotActive!==e&&(this.pivotActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnPivotChanged",t))),this.dispatchStateUpdatedEvent("pivot")}isPivotActive(){return this.pivotActive}isAnyFunctionActive(){return this.isPivotActive()||this.isRowGroupActive()||this.isValueActive()}isAnyFunctionAllowed(){return this.isAllowPivot()||this.isAllowRowGroup()||this.isAllowValue()}setValueActive(e,t){this.aggregationActive!==e&&(this.aggregationActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnValueChanged",t)))}isValueActive(){return this.aggregationActive}isAllowPivot(){return!0===this.colDef.enablePivot}isAllowValue(){return!0===this.colDef.enableValue}isAllowRowGroup(){return!0===this.colDef.enableRowGroup}getMenuTabs(e){U("As of v31.1, 'getMenuTabs' is deprecated. Use 'getColDef().menuTabs ?? defaultValues' instead.");let t=this.getColDef().menuTabs;return null==t&&(t=e),t}dispatchStateUpdatedEvent(t){this.eventService.dispatchEvent({type:e.EVENT_STATE_UPDATED,key:t})}};Se.EVENT_MOVING_CHANGED="movingChanged",Se.EVENT_LEFT_CHANGED="leftChanged",Se.EVENT_WIDTH_CHANGED="widthChanged",Se.EVENT_LAST_LEFT_PINNED_CHANGED="lastLeftPinnedChanged",Se.EVENT_FIRST_RIGHT_PINNED_CHANGED="firstRightPinnedChanged",Se.EVENT_VISIBLE_CHANGED="visibleChanged",Se.EVENT_FILTER_CHANGED="filterChanged",Se.EVENT_FILTER_ACTIVE_CHANGED="filterActiveChanged",Se.EVENT_SORT_CHANGED="sortChanged",Se.EVENT_COL_DEF_CHANGED="colDefChanged",Se.EVENT_MENU_VISIBLE_CHANGED="menuVisibleChanged",Se.EVENT_ROW_GROUP_CHANGED="columnRowGroupChanged",Se.EVENT_PIVOT_CHANGED="columnPivotChanged",Se.EVENT_VALUE_CHANGED="columnValueChanged",Se.EVENT_STATE_UPDATED="columnStateUpdated",g([he("gridOptionsService")],Se.prototype,"gos",2),g([he("environment")],Se.prototype,"environment",2),g([he("columnHoverService")],Se.prototype,"columnHoverService",2),g([he("frameworkOverrides")],Se.prototype,"frameworkOverrides",2),g([le],Se.prototype,"initialise",1);var be=Se,Ee=class e{constructor(e,t,i,r){this.localEventService=new me,this.expandable=!1,this.instanceId=we(),this.expandableListenerRemoveCallback=null,this.colGroupDef=e,this.groupId=t,this.expanded=!!e&&!!e.openByDefault,this.padding=i,this.level=r}destroy(){this.expandableListenerRemoveCallback&&this.reset(null,void 0)}reset(e,t){this.colGroupDef=e,this.level=t,this.originalParent=null,this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback(),this.children=void 0,this.expandable=void 0}getInstanceId(){return this.instanceId}setOriginalParent(e){this.originalParent=e}getOriginalParent(){return this.originalParent}getLevel(){return this.level}isVisible(){return!!this.children&&this.children.some(e=>e.isVisible())}isPadding(){return this.padding}setExpanded(t){this.expanded=void 0!==t&&t;const i={type:e.EVENT_EXPANDED_CHANGED};this.localEventService.dispatchEvent(i)}isExpandable(){return this.expandable}isExpanded(){return this.expanded}getGroupId(){return this.groupId}getId(){return this.getGroupId()}setChildren(e){this.children=e}getChildren(){return this.children}getColGroupDef(){return this.colGroupDef}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}addLeafColumns(t){this.children&&this.children.forEach(i=>{i instanceof be?t.push(i):i instanceof e&&i.addLeafColumns(t)})}getColumnGroupShow(){const e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();const e=this.onColumnVisibilityChanged.bind(this);this.getLeafColumns().forEach(t=>t.addEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=()=>{this.getLeafColumns().forEach(t=>t.removeEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let t=!1,i=!1,r=!1;const n=this.findChildrenRemovingPadding();for(let e=0,s=n.length;e<s;e++){const s=n[e];if(!s.isVisible())continue;const o=s.getColumnGroupShow();"open"===o?(t=!0,r=!0):"closed"===o?(i=!0,r=!0):(t=!0,i=!0)}const s=t&&i&&r;if(this.expandable!==s){this.expandable=s;const t={type:e.EVENT_EXPANDABLE_CHANGED};this.localEventService.dispatchEvent(t)}}findChildrenRemovingPadding(){const t=[],i=r=>{r.forEach(r=>{r instanceof e&&r.isPadding()?i(r.children):t.push(r)})};return i(this.children),t}onColumnVisibilityChanged(){this.setExpandable()}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}};Ee.EVENT_EXPANDED_CHANGED="expandedChanged",Ee.EVENT_EXPANDABLE_CHANGED="expandableChanged",g([ce],Ee.prototype,"destroy",1);var Ae=Ee,Te={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}},Me={};p(Me,{addSafePassiveEventListener:()=>it,createEventPath:()=>et,getCtrlForEventTarget:()=>Ze,getEventPath:()=>tt,isElementInEventPath:()=>Je,isEventSupported:()=>Xe,isStopPropagationForAgGrid:()=>Qe,stopPropagationForAgGrid:()=>Ye});var Re={};function _e(e){return null!=e&&e.length>0}function Pe(e){if(e&&e.length)return e[e.length-1]}function xe(e,t,i){return null==e&&null==t||null!=e&&null!=t&&e.length===t.length&&e.every((e,r)=>i?i(e,t[r]):t[r]===e)}function De(e,t){return xe(e,t)}function Ie(e){return e.sort((e,t)=>e-t)}function Le(e,t){if(e)for(let i=e.length-2;i>=0;i--){const r=e[i]===t,n=e[i+1]===t;r&&n&&e.splice(i+1,1)}}function Ne(e,t){const i=e.indexOf(t);i>=0&&(e[i]=e[e.length-1],e.pop())}function Oe(e,t){const i=e.indexOf(t);i>=0&&e.splice(i,1)}function Fe(e,t){for(let i=0;i<t.length;i++)Ne(e,t[i])}function ke(e,t){for(let i=0;i<t.length;i++)Oe(e,t[i])}function Ge(e,t,i){e.splice(i,0,t)}function Ve(e,t,i){if(null!=e&&null!=t)for(let r=t.length-1;r>=0;r--)Ge(e,t[r],i)}function He(e,t,i){ke(e,t),t.slice().reverse().forEach(t=>Ge(e,t,i))}function Be(e,t){return e.indexOf(t)>-1}function ze(e){return[].concat.apply([],e)}function Ue(e,t){null!=t&&null!=e&&t.forEach(t=>e.push(t))}function We(e){return e.map(b)}function je(e,t){if(null!=e)for(let i=e.length-1;i>=0;i--)t(e[i],i)}p(Re,{areEqual:()=>xe,existsAndNotEmpty:()=>_e,flatten:()=>ze,forEachReverse:()=>je,includes:()=>Be,insertArrayIntoArray:()=>Ve,insertIntoArray:()=>Ge,last:()=>Pe,moveInArray:()=>He,pushAll:()=>Ue,removeAllFromArray:()=>ke,removeAllFromUnorderedArray:()=>Fe,removeFromArray:()=>Oe,removeFromUnorderedArray:()=>Ne,removeRepeatsFromArray:()=>Le,shallowCompare:()=>De,sortNumerically:()=>Ie,toStrings:()=>We});var Ke="__ag_Grid_Stop_Propagation",$e=["touchstart","touchend","touchmove","touchcancel","scroll"],qe={};function Ye(e){e[Ke]=!0}function Qe(e){return!0===e[Ke]}var Xe=(()=>{const e={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return t=>{if("boolean"==typeof qe[t])return qe[t];const i=document.createElement(e[t]||"div");return qe[t="on"+t]=t in i}})();function Ze(e,t,i){let r=t;for(;r;){const t=e.getDomData(r,i);if(t)return t;r=r.parentElement}return null}function Je(e,t){return!(!t||!e)&&tt(t).indexOf(e)>=0}function et(e){const t=[];let i=e.target;for(;i;)t.push(i),i=i.parentElement;return t}function tt(e){const t=e;return t.path?t.path:t.composedPath?t.composedPath():et(t)}function it(e,t,i,r){const n=Be($e,i)?{passive:!0}:void 0;e&&e.addEventListener&&e.addEventListener(t,i,r,n)}var rt=class e{constructor(){this.destroyFunctions=[],this.destroyed=!1,this.__v_skip=!0,this.lastChangeSetIdLookup={},this.propertyListenerId=0,this.isAlive=()=>!this.destroyed}getFrameworkOverrides(){return this.frameworkOverrides}getContext(){return this.context}destroy(){for(let e=0;e<this.destroyFunctions.length;e++)this.destroyFunctions[e]();this.destroyFunctions.length=0,this.destroyed=!0,this.dispatchEvent({type:e.EVENT_DESTROYED})}addEventListener(e,t){this.localEventService||(this.localEventService=new me),this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService&&this.localEventService.removeEventListener(e,t)}dispatchEvent(e){this.localEventService&&this.localEventService.dispatchEvent(e)}addManagedListener(e,t,i){if(this.destroyed)return;e instanceof HTMLElement?it(this.getFrameworkOverrides(),e,t,i):e.addEventListener(t,i);const r=()=>(e.removeEventListener(t,i),null);return this.destroyFunctions.push(r),()=>(r(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==r),null)}setupGridOptionListener(e,t){this.gos.addEventListener(e,t);const i=()=>(this.gos.removeEventListener(e,t),null);return this.destroyFunctions.push(i),()=>(i(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==i),null)}addManagedPropertyListener(e,t){return this.destroyed?()=>null:this.setupGridOptionListener(e,t)}addManagedPropertyListeners(e,t){if(this.destroyed)return;const i=e.join("-")+this.propertyListenerId++,r=e=>{if(e.changeSet){if(e.changeSet&&e.changeSet.id===this.lastChangeSetIdLookup[i])return;this.lastChangeSetIdLookup[i]=e.changeSet.id}const r={type:"gridPropertyChanged",changeSet:e.changeSet,source:e.source};t(r)};e.forEach(e=>this.setupGridOptionListener(e,r))}addDestroyFunc(e){this.isAlive()?this.destroyFunctions.push(e):e()}createManagedBean(e,t){const i=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),i}createBean(e,t,i){return(t||this.getContext()).createBean(e,i)}destroyBean(e,t){return(t||this.getContext()).destroyBean(e)}destroyBeans(e,t){if(e)for(let i=0;i<e.length;i++)this.destroyBean(e[i],t);return[]}};rt.EVENT_DESTROYED="destroyed",g([he("frameworkOverrides")],rt.prototype,"frameworkOverrides",2),g([he("context")],rt.prototype,"context",2),g([he("eventService")],rt.prototype,"eventService",2),g([he("gridOptionsService")],rt.prototype,"gos",2),g([he("localeService")],rt.prototype,"localeService",2),g([he("environment")],rt.prototype,"environment",2),g([ce],rt.prototype,"destroy",1);var nt=rt,st=class extends nt{setBeans(e){this.logger=e.create("ColumnFactory")}createColumnTree(e,t,i,r){const n=new P,{existingCols:s,existingGroups:o,existingColKeys:a}=this.extractExistingTreeData(i);n.addExistingKeys(a);const l=this.recursivelyCreateColumns(e,0,t,s,n,o,r),c=this.findMaxDept(l,0);this.logger.log("Number of levels for grouped columns is "+c);const u=this.balanceColumnTree(l,0,c,n);return ot(null,u,(e,t)=>{e instanceof Ae&&e.setupExpandable(),e.setOriginalParent(t)}),{columnTree:u,treeDept:c}}extractExistingTreeData(e){const t=[],i=[],r=[];return e&&ot(null,e,e=>{if(e instanceof Ae){const t=e;i.push(t)}else{const i=e;r.push(i.getId()),t.push(i)}}),{existingCols:t,existingGroups:i,existingColKeys:r}}createForAutoGroups(e,t){return e.map(e=>this.createAutoGroupTreeItem(t,e))}createAutoGroupTreeItem(e,t){const i=this.findDepth(e);let r=t;for(let e=i-1;e>=0;e--){const i=new Ae(null,`FAKE_PATH_${t.getId()}}_${e}`,!0,e);this.createBean(i),i.setChildren([r]),r.setOriginalParent(i),r=i}return 0===i&&t.setOriginalParent(null),r}findDepth(e){let t=0,i=e;for(;i&&i[0]&&i[0]instanceof Ae;)t++,i=i[0].getChildren();return t}balanceColumnTree(e,t,i,r){const n=[];for(let s=0;s<e.length;s++){const o=e[s];if(o instanceof Ae){const e=o,s=this.balanceColumnTree(e.getChildren(),t+1,i,r);e.setChildren(s),n.push(e)}else{let s,a;for(let e=i-1;e>=t;e--){const e=r.getUniqueKey(null,null),i=this.createMergedColGroupDef(null),n=new Ae(i,e,!0,t);this.createBean(n),a&&a.setChildren([n]),a=n,s||(s=a)}if(s&&a){if(n.push(s),e.some(e=>e instanceof Ae)){a.setChildren([o]);continue}a.setChildren(e);break}n.push(o)}}return n}findMaxDept(e,t){let i=t;for(let r=0;r<e.length;r++){const n=e[r];if(n instanceof Ae){const e=n,r=this.findMaxDept(e.getChildren(),t+1);i<r&&(i=r)}}return i}recursivelyCreateColumns(e,t,i,r,n,s,o){if(!e)return[];const a=new Array(e.length);for(let l=0;l<a.length;l++){const c=e[l];this.isColumnGroup(c)?a[l]=this.createColumnGroup(i,c,t,r,n,s,o):a[l]=this.createColumn(i,c,r,n,o)}return a}createColumnGroup(e,t,i,r,n,s,o){const a=this.createMergedColGroupDef(t),l=n.getUniqueKey(a.groupId||null,null),c=new Ae(a,l,!1,i);this.createBean(c);const u=this.findExistingGroup(t,s);u&&s.splice(u.idx,1);let h=null==u?void 0:u.group;h&&c.setExpanded(h.isExpanded());const d=this.recursivelyCreateColumns(a.children,i+1,e,r,n,s,o);return c.setChildren(d),c}createMergedColGroupDef(e){const t={};return Object.assign(t,this.gos.get("defaultColGroupDef")),Object.assign(t,e),t}createColumn(e,t,i,r,n){const s=this.findExistingColumn(t,i);s&&(null==i||i.splice(s.idx,1));let o=null==s?void 0:s.column;if(o){const e=this.addColumnDefaultAndTypes(t,o.getColId());o.setColDef(e,t,n),this.applyColumnState(o,e,n)}else{const i=r.getUniqueKey(t.colId,t.field),n=this.addColumnDefaultAndTypes(t,i);o=new be(n,t,i,e),this.context.createBean(o)}return this.dataTypeService.addColumnListeners(o),o}applyColumnState(e,t,i){const r=E(t.flex);if(void 0!==r&&e.setFlex(r),e.getFlex()<=0){const r=E(t.width);if(null!=r)e.setActualWidth(r,i);else{const t=e.getActualWidth();e.setActualWidth(t,i)}}void 0!==t.sort&&("asc"==t.sort||"desc"==t.sort?e.setSort(t.sort,i):e.setSort(void 0,i));const n=E(t.sortIndex);void 0!==n&&e.setSortIndex(n);const s=A(t.hide);void 0!==s&&e.setVisible(!s,i),void 0!==t.pinned&&e.setPinned(t.pinned)}findExistingColumn(e,t){if(t)for(let i=0;i<t.length;i++){const r=t[i].getUserProvidedColDef();if(r)if(null==e.colId){if(null!=e.field){if(r.field===e.field)return{idx:i,column:t[i]}}else if(r===e)return{idx:i,column:t[i]}}else if(t[i].getId()===e.colId)return{idx:i,column:t[i]}}}findExistingGroup(e,t){if(null!=e.groupId)for(let i=0;i<t.length;i++){const r=t[i];if(r.getColGroupDef()&&r.getId()===e.groupId)return{idx:i,group:r}}}addColumnDefaultAndTypes(e,t){const i={};F(i,this.gos.get("defaultColDef"),!1,!0);const r=this.dataTypeService.updateColDefAndGetColumnType(i,e,t);r&&this.assignColumnTypes(r,i),F(i,e,!1,!0);const n=this.gos.get("autoGroupColumnDef"),s=this.gos.isColumnsSortingCoupledToGroup();return e.rowGroup&&n&&s&&F(i,{sort:n.sort,initialSort:n.initialSort},!1,!0),this.dataTypeService.validateColDef(i),i}assignColumnTypes(e,t){if(!e.length)return;const i=Object.assign({},Te);I(this.gos.get("columnTypes")||{},(e,t)=>{e in i?console.warn(`AG Grid: the column type '${e}' is a default column type and cannot be overridden.`):(t.type&&U("Column type definitions 'columnTypes' with a 'type' attribute are not supported because a column type cannot refer to another column type. Only column definitions 'columnDefs' can use the 'type' attribute to refer to a column type."),i[e]=t)}),e.forEach(e=>{const r=i[e.trim()];r?F(t,r,!1,!0):console.warn("AG Grid: colDef.type '"+e+"' does not correspond to defined gridOptions.columnTypes")})}isColumnGroup(e){return void 0!==e.children}};function ot(e,t,i){if(t)for(let r=0;r<t.length;r++){const n=t[r];n instanceof Ae&&ot(n,n.getChildren(),i),i(n,e)}}g([he("dataTypeService")],st.prototype,"dataTypeService",2),g([f(0,ge("loggerFactory"))],st.prototype,"setBeans",1),st=g([ue("columnFactory")],st);var at=class e{constructor(e,t,i,r){this.displayedChildren=[],this.localEventService=new me,this.groupId=t,this.partId=i,this.providedColumnGroup=e,this.pinned=r}static createUniqueId(e,t){return e+"_"+t}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}setParent(e){this.parent=e}getUniqueId(){return e.createUniqueId(this.groupId,this.partId)}isEmptyGroup(){return 0===this.displayedChildren.length}isMoving(){const e=this.getProvidedColumnGroup().getLeafColumns();return!(!e||0===e.length)&&e.every(e=>e.isMoving())}checkLeft(){if(this.displayedChildren.forEach(t=>{t instanceof e&&t.checkLeft()}),this.displayedChildren.length>0)if(this.gos.get("enableRtl")){const e=Pe(this.displayedChildren).getLeft();this.setLeft(e)}else{const e=this.displayedChildren[0].getLeft();this.setLeft(e)}else this.setLeft(null)}getLeft(){return this.left}getOldLeft(){return this.oldLeft}setLeft(t){this.oldLeft=this.left,this.left!==t&&(this.left=t,this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_LEFT_CHANGED)))}getPinned(){return this.pinned}createAgEvent(e){return{type:e}}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}getGroupId(){return this.groupId}getPartId(){return this.partId}isChildInThisGroupDeepSearch(t){let i=!1;return this.children.forEach(r=>{t===r&&(i=!0),r instanceof e&&r.isChildInThisGroupDeepSearch(t)&&(i=!0)}),i}getActualWidth(){let e=0;return this.displayedChildren&&this.displayedChildren.forEach(t=>{e+=t.getActualWidth()}),e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;return this.displayedChildren.forEach(t=>{t.isResizable()&&(e=!0)}),e}getMinWidth(){let e=0;return this.displayedChildren.forEach(t=>{e+=t.getMinWidth()||0}),e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){const e=[];return this.addDisplayedLeafColumns(e),e}getDefinition(){return this.providedColumnGroup.getColGroupDef()}getColGroupDef(){return this.providedColumnGroup.getColGroupDef()}isPadding(){return this.providedColumnGroup.isPadding()}isExpandable(){return this.providedColumnGroup.isExpandable()}isExpanded(){return this.providedColumnGroup.isExpanded()}setExpanded(e){this.providedColumnGroup.setExpanded(e)}addDisplayedLeafColumns(t){this.displayedChildren.forEach(i=>{i instanceof be?t.push(i):i instanceof e&&i.addDisplayedLeafColumns(t)})}addLeafColumns(t){this.children.forEach(i=>{i instanceof be?t.push(i):i instanceof e&&i.addLeafColumns(t)})}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){const e=this.getParent();return this.isPadding()&&e&&e.isPadding()?1+e.getPaddingLevel():0}calculateDisplayedColumns(){this.displayedChildren=[];let t=this;for(;null!=t&&t.isPadding();)t=t.getParent();if(!t||!t.providedColumnGroup.isExpandable())return this.displayedChildren=this.children,void this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_DISPLAYED_CHILDREN_CHANGED));this.children.forEach(i=>{if(!(i instanceof e)||i.displayedChildren&&i.displayedChildren.length)switch(i.getColumnGroupShow()){case"open":t.providedColumnGroup.isExpanded()&&this.displayedChildren.push(i);break;case"closed":t.providedColumnGroup.isExpanded()||this.displayedChildren.push(i);break;default:this.displayedChildren.push(i)}}),this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_DISPLAYED_CHILDREN_CHANGED))}};at.EVENT_LEFT_CHANGED="leftChanged",at.EVENT_DISPLAYED_CHILDREN_CHANGED="displayedChildrenChanged",g([he("gridOptionsService")],at.prototype,"gos",2);var lt=at,ct=class{};ct.EVENT_COLUMN_EVERYTHING_CHANGED="columnEverythingChanged",ct.EVENT_NEW_COLUMNS_LOADED="newColumnsLoaded",ct.EVENT_COLUMN_PIVOT_MODE_CHANGED="columnPivotModeChanged",ct.EVENT_PIVOT_MAX_COLUMNS_EXCEEDED="pivotMaxColumnsExceeded",ct.EVENT_COLUMN_ROW_GROUP_CHANGED="columnRowGroupChanged",ct.EVENT_EXPAND_COLLAPSE_ALL="expandOrCollapseAll",ct.EVENT_COLUMN_PIVOT_CHANGED="columnPivotChanged",ct.EVENT_GRID_COLUMNS_CHANGED="gridColumnsChanged",ct.EVENT_COLUMN_VALUE_CHANGED="columnValueChanged",ct.EVENT_COLUMN_MOVED="columnMoved",ct.EVENT_COLUMN_VISIBLE="columnVisible",ct.EVENT_COLUMN_PINNED="columnPinned",ct.EVENT_COLUMN_GROUP_OPENED="columnGroupOpened",ct.EVENT_COLUMN_RESIZED="columnResized",ct.EVENT_DISPLAYED_COLUMNS_CHANGED="displayedColumnsChanged",ct.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED="suppressMovableColumns",ct.EVENT_SUPPRESS_MENU_HIDE_CHANGED="suppressMenuHide",ct.EVENT_SUPPRESS_FIELD_DOT_NOTATION="suppressFieldDotNotation",ct.EVENT_VIRTUAL_COLUMNS_CHANGED="virtualColumnsChanged",ct.EVENT_COLUMN_HEADER_MOUSE_OVER="columnHeaderMouseOver",ct.EVENT_COLUMN_HEADER_MOUSE_LEAVE="columnHeaderMouseLeave",ct.EVENT_COLUMN_HEADER_CLICKED="columnHeaderClicked",ct.EVENT_COLUMN_HEADER_CONTEXT_MENU="columnHeaderContextMenu",ct.EVENT_ASYNC_TRANSACTIONS_FLUSHED="asyncTransactionsFlushed",ct.EVENT_ROW_GROUP_OPENED="rowGroupOpened",ct.EVENT_ROW_DATA_UPDATED="rowDataUpdated",ct.EVENT_PINNED_ROW_DATA_CHANGED="pinnedRowDataChanged",ct.EVENT_RANGE_SELECTION_CHANGED="rangeSelectionChanged",ct.EVENT_CHART_CREATED="chartCreated",ct.EVENT_CHART_RANGE_SELECTION_CHANGED="chartRangeSelectionChanged",ct.EVENT_CHART_OPTIONS_CHANGED="chartOptionsChanged",ct.EVENT_CHART_DESTROYED="chartDestroyed",ct.EVENT_TOOL_PANEL_VISIBLE_CHANGED="toolPanelVisibleChanged",ct.EVENT_TOOL_PANEL_SIZE_CHANGED="toolPanelSizeChanged",ct.EVENT_COLUMN_PANEL_ITEM_DRAG_START="columnPanelItemDragStart",ct.EVENT_COLUMN_PANEL_ITEM_DRAG_END="columnPanelItemDragEnd",ct.EVENT_MODEL_UPDATED="modelUpdated",ct.EVENT_CUT_START="cutStart",ct.EVENT_CUT_END="cutEnd",ct.EVENT_PASTE_START="pasteStart",ct.EVENT_PASTE_END="pasteEnd",ct.EVENT_FILL_START="fillStart",ct.EVENT_FILL_END="fillEnd",ct.EVENT_RANGE_DELETE_START="rangeDeleteStart",ct.EVENT_RANGE_DELETE_END="rangeDeleteEnd",ct.EVENT_UNDO_STARTED="undoStarted",ct.EVENT_UNDO_ENDED="undoEnded",ct.EVENT_REDO_STARTED="redoStarted",ct.EVENT_REDO_ENDED="redoEnded",ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_START="keyShortcutChangedCellStart",ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_END="keyShortcutChangedCellEnd",ct.EVENT_CELL_CLICKED="cellClicked",ct.EVENT_CELL_DOUBLE_CLICKED="cellDoubleClicked",ct.EVENT_CELL_MOUSE_DOWN="cellMouseDown",ct.EVENT_CELL_CONTEXT_MENU="cellContextMenu",ct.EVENT_CELL_VALUE_CHANGED="cellValueChanged",ct.EVENT_CELL_EDIT_REQUEST="cellEditRequest",ct.EVENT_ROW_VALUE_CHANGED="rowValueChanged",ct.EVENT_CELL_FOCUSED="cellFocused",ct.EVENT_CELL_FOCUS_CLEARED="cellFocusCleared",ct.EVENT_FULL_WIDTH_ROW_FOCUSED="fullWidthRowFocused",ct.EVENT_ROW_SELECTED="rowSelected",ct.EVENT_SELECTION_CHANGED="selectionChanged",ct.EVENT_TOOLTIP_SHOW="tooltipShow",ct.EVENT_TOOLTIP_HIDE="tooltipHide",ct.EVENT_CELL_KEY_DOWN="cellKeyDown",ct.EVENT_CELL_MOUSE_OVER="cellMouseOver",ct.EVENT_CELL_MOUSE_OUT="cellMouseOut",ct.EVENT_FILTER_CHANGED="filterChanged",ct.EVENT_FILTER_MODIFIED="filterModified",ct.EVENT_FILTER_OPENED="filterOpened",ct.EVENT_ADVANCED_FILTER_BUILDER_VISIBLE_CHANGED="advancedFilterBuilderVisibleChanged",ct.EVENT_SORT_CHANGED="sortChanged",ct.EVENT_VIRTUAL_ROW_REMOVED="virtualRowRemoved",ct.EVENT_ROW_CLICKED="rowClicked",ct.EVENT_ROW_DOUBLE_CLICKED="rowDoubleClicked",ct.EVENT_GRID_READY="gridReady",ct.EVENT_GRID_PRE_DESTROYED="gridPreDestroyed",ct.EVENT_GRID_SIZE_CHANGED="gridSizeChanged",ct.EVENT_VIEWPORT_CHANGED="viewportChanged",ct.EVENT_SCROLLBAR_WIDTH_CHANGED="scrollbarWidthChanged",ct.EVENT_FIRST_DATA_RENDERED="firstDataRendered",ct.EVENT_DRAG_STARTED="dragStarted",ct.EVENT_DRAG_STOPPED="dragStopped",ct.EVENT_CHECKBOX_CHANGED="checkboxChanged",ct.EVENT_ROW_EDITING_STARTED="rowEditingStarted",ct.EVENT_ROW_EDITING_STOPPED="rowEditingStopped",ct.EVENT_CELL_EDITING_STARTED="cellEditingStarted",ct.EVENT_CELL_EDITING_STOPPED="cellEditingStopped",ct.EVENT_BODY_SCROLL="bodyScroll",ct.EVENT_BODY_SCROLL_END="bodyScrollEnd",ct.EVENT_HEIGHT_SCALE_CHANGED="heightScaleChanged",ct.EVENT_PAGINATION_CHANGED="paginationChanged",ct.EVENT_COMPONENT_STATE_CHANGED="componentStateChanged",ct.EVENT_STORE_REFRESHED="storeRefreshed",ct.EVENT_STATE_UPDATED="stateUpdated",ct.EVENT_COLUMN_MENU_VISIBLE_CHANGED="columnMenuVisibleChanged",ct.EVENT_CONTEXT_MENU_VISIBLE_CHANGED="contextMenuVisibleChanged",ct.EVENT_BODY_HEIGHT_CHANGED="bodyHeightChanged",ct.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED="columnContainerWidthChanged",ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED="displayedColumnsWidthChanged",ct.EVENT_SCROLL_VISIBILITY_CHANGED="scrollVisibilityChanged",ct.EVENT_COLUMN_HOVER_CHANGED="columnHoverChanged",ct.EVENT_FLASH_CELLS="flashCells",ct.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED="paginationPixelOffsetChanged",ct.EVENT_DISPLAYED_ROWS_CHANGED="displayedRowsChanged",ct.EVENT_LEFT_PINNED_WIDTH_CHANGED="leftPinnedWidthChanged",ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED="rightPinnedWidthChanged",ct.EVENT_ROW_CONTAINER_HEIGHT_CHANGED="rowContainerHeightChanged",ct.EVENT_HEADER_HEIGHT_CHANGED="headerHeightChanged",ct.EVENT_COLUMN_HEADER_HEIGHT_CHANGED="columnHeaderHeightChanged",ct.EVENT_ROW_DRAG_ENTER="rowDragEnter",ct.EVENT_ROW_DRAG_MOVE="rowDragMove",ct.EVENT_ROW_DRAG_LEAVE="rowDragLeave",ct.EVENT_ROW_DRAG_END="rowDragEnd",ct.EVENT_GRID_STYLES_CHANGED="gridStylesChanged",ct.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST="columnRowGroupChangeRequest",ct.EVENT_COLUMN_PIVOT_CHANGE_REQUEST="columnPivotChangeRequest",ct.EVENT_COLUMN_VALUE_CHANGE_REQUEST="columnValueChangeRequest",ct.EVENT_COLUMN_AGG_FUNC_CHANGE_REQUEST="columnAggFuncChangeRequest",ct.EVENT_STORE_UPDATED="storeUpdated",ct.EVENT_FILTER_DESTROYED="filterDestroyed",ct.EVENT_ROW_DATA_UPDATE_STARTED="rowDataUpdateStarted",ct.EVENT_ROW_COUNT_READY="rowCountReady",ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED="advancedFilterEnabledChanged",ct.EVENT_DATA_TYPES_INFERRED="dataTypesInferred",ct.EVENT_FIELD_VALUE_CHANGED="fieldValueChanged",ct.EVENT_FIELD_PICKER_VALUE_SELECTED="fieldPickerValueSelected",ct.EVENT_SIDE_BAR_UPDATED="sideBarUpdated";var ut=new Set([ct.EVENT_GRID_PRE_DESTROYED,ct.EVENT_FILL_START]),ht=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){const t=this.existingIds[e];let i;return i="number"!=typeof t?0:t+1,this.existingIds[e]=i,i}},dt="ag-Grid-AutoColumn",pt=class extends nt{createAutoGroupColumns(e){const t=[],i=this.gos.get("treeData");let r=this.gos.isGroupMultiAutoColumn();return i&&r&&(console.warn('AG Grid: you cannot mix groupDisplayType = "multipleColumns" with treeData, only one column can be used to display groups when doing tree data'),r=!1),r?e.forEach((e,i)=>{t.push(this.createOneAutoGroupColumn(e,i))}):t.push(this.createOneAutoGroupColumn()),t}updateAutoGroupColumns(e,t){e.forEach((e,i)=>this.updateOneAutoGroupColumn(e,i,t))}createOneAutoGroupColumn(e,t){let i;i=e?`${dt}-${e.getId()}`:dt;const r=this.createAutoGroupColDef(i,e,t);r.colId=i;const n=new be(r,null,i,!0);return this.context.createBean(n),n}updateOneAutoGroupColumn(e,t,i){const r=e.getColDef(),n="string"==typeof r.showRowGroup?r.showRowGroup:void 0,s=null!=n?this.columnModel.getPrimaryColumn(n):void 0,o=this.createAutoGroupColDef(e.getId(),null!=s?s:void 0,t);e.setColDef(o,null,i),this.columnFactory.applyColumnState(e,o,i)}createAutoGroupColDef(e,t,i){let r=this.createBaseColDef(t);F(r,this.gos.get("autoGroupColumnDef")),r=this.columnFactory.addColumnDefaultAndTypes(r,e),this.gos.get("treeData")||w(r.field)&&w(r.valueGetter)&&w(r.filterValueGetter)&&"agGroupColumnFilter"!==r.filter&&(r.filter=!1),i&&i>0&&(r.headerCheckboxSelection=!1);const n=this.gos.isColumnsSortingCoupledToGroup(),s=r.valueGetter||null!=r.field;return n&&!s&&(r.sortIndex=void 0,r.initialSort=void 0),r}createBaseColDef(e){const t=this.gos.get("autoGroupColumnDef"),i={headerName:this.localeService.getLocaleTextFunc()("group","Group")};if(t&&(t.cellRenderer||t.cellRendererSelector)||(i.cellRenderer="agGroupCellRenderer"),e){const t=e.getColDef();Object.assign(i,{headerName:this.columnModel.getDisplayNameForColumn(e,"header"),headerValueGetter:t.headerValueGetter}),t.cellRenderer&&Object.assign(i,{cellRendererParams:{innerRenderer:t.cellRenderer,innerRendererParams:t.cellRendererParams}}),i.showRowGroup=e.getColId()}else i.showRowGroup=!0;return i}};g([he("columnModel")],pt.prototype,"columnModel",2),g([he("columnFactory")],pt.prototype,"columnFactory",2),pt=g([ue("autoGroupColService")],pt);var gt={};p(gt,{camelCaseToHumanText:()=>wt,camelCaseToHyphenated:()=>St,capitalise:()=>Ct,escapeString:()=>yt,utf8_encode:()=>vt});var ft=/[&<>"']/g,mt={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function vt(e){const t=String.fromCharCode;function i(e,i){return t(e>>i&63|128)}function r(e){if(e>=0&&e<=31&&10!==e)return`_x${e.toString(16).toUpperCase().padStart(4,"0")}_`;if(!(4294967168&e))return t(e);let r="";return 4294965248&e?4294901760&e?4292870144&e||(r=t(e>>18&7|240),r+=i(e,12),r+=i(e,6)):(function(e){if(e>=55296&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}(e),r=t(e>>12&15|224),r+=i(e,6)):r=t(e>>6&31|192),r+=t(63&e|128),r}const n=function(e){const t=[];if(!e)return[];const i=e.length;let r,n,s=0;for(;s<i;)r=e.charCodeAt(s++),r>=55296&&r<=56319&&s<i?(n=e.charCodeAt(s++),56320==(64512&n)?t.push(((1023&r)<<10)+(1023&n)+65536):(t.push(r),s--)):t.push(r);return t}(e),s=n.length;let o,a=-1,l="";for(;++a<s;)o=n[a],l+=r(o);return l}function Ct(e){return e[0].toUpperCase()+e.substring(1).toLowerCase()}function yt(e,t){if(null==e)return null;const i=e.toString().toString();return t?i:i.replace(ft,e=>mt[e])}function wt(e){return e&&null!=e?e.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z])([a-z])/g,"$1 $2$3").replace(/\./g," ").split(" ").map(e=>e.substring(0,1).toUpperCase()+(e.length>1?e.substring(1,e.length):"")).join(" "):null}function St(e){return e.replace(/[A-Z]/g,e=>`-${e.toLocaleLowerCase()}`)}var bt={};function Et(e){const t=new Map;return e.forEach(e=>t.set(e[0],e[1])),t}function At(e,t){const i=new Map;return e.forEach(e=>i.set(t(e),e)),i}function Tt(e){const t=[];return e.forEach((e,i)=>t.push(i)),t}p(bt,{convertToMap:()=>Et,keys:()=>Tt,mapById:()=>At});var Mt=class extends nt{constructor(){super(...arguments),this.primaryHeaderRowCount=0,this.secondaryHeaderRowCount=0,this.gridHeaderRowCount=0,this.displayedColumnsLeft=[],this.displayedColumnsRight=[],this.displayedColumnsCenter=[],this.displayedColumns=[],this.displayedColumnsAndGroupsMap={},this.viewportColumns=[],this.viewportColumnsHash="",this.headerViewportColumns=[],this.viewportColumnsCenter=[],this.headerViewportColumnsCenter=[],this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={},this.autoHeightActiveAtLeastOnce=!1,this.rowGroupColumns=[],this.valueColumns=[],this.pivotColumns=[],this.ready=!1,this.changeEventsDispatching=!1,this.autoGroupsNeedBuilding=!1,this.forceRecreateAutoGroups=!1,this.pivotMode=!1,this.bodyWidth=0,this.leftWidth=0,this.rightWidth=0,this.bodyWidthDirty=!0,this.shouldQueueResizeOperations=!1,this.resizeOperationQueue=[]}init(){this.suppressColumnVirtualisation=this.gos.get("suppressColumnVirtualisation");const e=this.gos.get("pivotMode");this.isPivotSettingAllowed(e)&&(this.pivotMode=e),this.addManagedPropertyListeners(["groupDisplayType","treeData","treeDataDisplayType","groupHideOpenParents"],e=>this.buildAutoGroupColumns(Rt(e.source))),this.addManagedPropertyListener("autoGroupColumnDef",e=>this.onAutoGroupColumnDefChanged(Rt(e.source))),this.addManagedPropertyListeners(["defaultColDef","columnTypes","suppressFieldDotNotation"],e=>this.onSharedColDefChanged(Rt(e.source))),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),Rt(e.source))),this.addManagedListener(this.eventService,ct.EVENT_FIRST_DATA_RENDERED,()=>this.onFirstDataRendered())}buildAutoGroupColumns(e){this.columnDefs&&(this.autoGroupsNeedBuilding=!0,this.forceRecreateAutoGroups=!0,this.updateGridColumns(),this.updateDisplayedColumns(e))}onAutoGroupColumnDefChanged(e){this.groupAutoColumns&&this.autoGroupColService.updateAutoGroupColumns(this.groupAutoColumns,e)}onSharedColDefChanged(e){this.gridColumns&&(this.groupAutoColumns&&this.autoGroupColService.updateAutoGroupColumns(this.groupAutoColumns,e),this.createColumnsFromColumnDefs(!0,e))}setColumnDefs(e,t){const i=!!this.columnDefs;this.columnDefs=e,this.createColumnsFromColumnDefs(i,t)}recreateColumnDefs(e){this.onSharedColDefChanged(e)}destroyOldColumns(e,t){const i={};if(!e)return;ot(null,e,e=>{i[e.getInstanceId()]=e}),t&&ot(null,t,e=>{i[e.getInstanceId()]=null});const r=Object.values(i).filter(e=>null!=e);this.destroyBeans(r)}destroyColumns(){this.destroyOldColumns(this.primaryColumnTree),this.destroyOldColumns(this.secondaryBalancedTree),this.destroyOldColumns(this.groupAutoColsBalancedTree)}createColumnsFromColumnDefs(e,t){const i=e?this.compareColumnStatesAndDispatchEvents(t):void 0;this.valueCache.expire(),this.autoGroupsNeedBuilding=!0;const r=this.primaryColumns,n=this.primaryColumnTree,s=this.columnFactory.createColumnTree(this.columnDefs,!0,n,t);this.destroyOldColumns(this.primaryColumnTree,s.columnTree),this.primaryColumnTree=s.columnTree,this.primaryHeaderRowCount=s.treeDept+1,this.primaryColumns=this.getColumnsFromTree(this.primaryColumnTree),this.primaryColumnsMap={},this.primaryColumns.forEach(e=>this.primaryColumnsMap[e.getId()]=e),this.extractRowGroupColumns(t,r),this.extractPivotColumns(t,r),this.extractValueColumns(t,r),this.ready=!0;const o=void 0===this.gridColsArePrimary;(this.gridColsArePrimary||o||this.autoGroupsNeedBuilding)&&(this.updateGridColumns(),e&&this.gridColsArePrimary&&!this.gos.get("maintainColumnOrder")&&this.orderGridColumnsLikePrimary(),this.updateDisplayedColumns(t),this.checkViewportColumns()),this.dispatchEverythingChanged(t),this.changeEventsDispatching=!0,i&&i(),this.changeEventsDispatching=!1,this.dispatchNewColumnsLoaded(t)}shouldRowModelIgnoreRefresh(){return this.changeEventsDispatching}dispatchNewColumnsLoaded(e){const t={type:ct.EVENT_NEW_COLUMNS_LOADED,source:e};this.eventService.dispatchEvent(t),"gridInitializing"===e&&this.onColumnsReady()}dispatchEverythingChanged(e){const t={type:ct.EVENT_COLUMN_EVERYTHING_CHANGED,source:e};this.eventService.dispatchEvent(t)}orderGridColumnsLikePrimary(){const e=this.primaryColumns;if(!e)return;const t=e.filter(e=>this.gridColumns.indexOf(e)>=0),i=this.gridColumns.filter(e=>t.indexOf(e)<0);this.gridColumns=[...i,...t],this.gridColumns=this.placeLockedColumns(this.gridColumns)}getAllDisplayedAutoHeightCols(){return this.displayedAutoHeightCols}setViewport(){this.gos.get("enableRtl")?(this.viewportLeft=this.bodyWidth-this.scrollPosition-this.scrollWidth,this.viewportRight=this.bodyWidth-this.scrollPosition):(this.viewportLeft=this.scrollPosition,this.viewportRight=this.scrollWidth+this.scrollPosition)}checkViewportColumns(e=!1){if(null==this.displayedColumnsCenter)return;if(!this.extractViewport())return;const t={type:ct.EVENT_VIRTUAL_COLUMNS_CHANGED,afterScroll:e};this.eventService.dispatchEvent(t)}setViewportPosition(e,t,i=!1){(e!==this.scrollWidth||t!==this.scrollPosition||this.bodyWidthDirty)&&(this.scrollWidth=e,this.scrollPosition=t,this.bodyWidthDirty=!0,this.setViewport(),this.ready&&this.checkViewportColumns(i))}isPivotMode(){return this.pivotMode}isPivotSettingAllowed(e){return!e||!this.gos.get("treeData")||(U("Pivot mode not available with treeData."),!1)}setPivotMode(e,t){if(e===this.pivotMode||!this.isPivotSettingAllowed(this.pivotMode))return;if(this.pivotMode=e,!this.gridColumns)return;this.autoGroupsNeedBuilding=!0,this.updateGridColumns(),this.updateDisplayedColumns(t);const i={type:ct.EVENT_COLUMN_PIVOT_MODE_CHANGED};this.eventService.dispatchEvent(i)}getSecondaryPivotColumn(e,t){if(w(this.secondaryColumns))return null;const i=this.getPrimaryColumn(t);let r=null;return this.secondaryColumns.forEach(t=>{const n=t.getColDef().pivotKeys,s=t.getColDef().pivotValueColumn;xe(n,e)&&s===i&&(r=t)}),r}setBeans(e){this.logger=e.create("columnModel")}setFirstRightAndLastLeftPinned(e){let t,i;this.gos.get("enableRtl")?(t=this.displayedColumnsLeft?this.displayedColumnsLeft[0]:null,i=this.displayedColumnsRight?Pe(this.displayedColumnsRight):null):(t=this.displayedColumnsLeft?Pe(this.displayedColumnsLeft):null,i=this.displayedColumnsRight?this.displayedColumnsRight[0]:null),this.gridColumns.forEach(r=>{r.setLastLeftPinned(r===t,e),r.setFirstRightPinned(r===i,e)})}autoSizeColumns(e){if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.autoSizeColumns(e));const{columns:t,skipHeader:i,skipHeaderGroups:r,stopAtGroup:n,source:s="api"}=e;this.animationFrameService.flushAllFrames();const o=[];let a=-1;const l=null!=i?i:this.gos.get("skipHeaderOnAutoSize"),c=null!=r?r:l;for(;0!==a;)a=0,this.actionOnGridColumns(t,e=>{if(o.indexOf(e)>=0)return!1;const t=this.autoWidthCalculator.getPreferredWidthForColumn(e,l);if(t>0){const i=this.normaliseColumnWidth(e,t);e.setActualWidth(i,s),o.push(e),a++}return!0},s);c||this.autoSizeColumnGroupsByColumns(t,s,n),this.dispatchColumnResizedEvent(o,!0,"autosizeColumns")}dispatchColumnResizedEvent(e,t,i,r=null){if(e&&e.length){const n={type:ct.EVENT_COLUMN_RESIZED,columns:e,column:1===e.length?e[0]:null,flexColumns:r,finished:t,source:i};this.eventService.dispatchEvent(n)}}dispatchColumnChangedEvent(e,t,i){const r={type:e,columns:t,column:t&&1==t.length?t[0]:null,source:i};this.eventService.dispatchEvent(r)}dispatchColumnMovedEvent(e){const{movedColumns:t,source:i,toIndex:r,finished:n}=e,s={type:ct.EVENT_COLUMN_MOVED,columns:t,column:t&&1===t.length?t[0]:null,toIndex:r,finished:n,source:i};this.eventService.dispatchEvent(s)}dispatchColumnPinnedEvent(e,t){if(!e.length)return;const i=1===e.length?e[0]:null,r=this.getCommonValue(e,e=>e.getPinned()),n={type:ct.EVENT_COLUMN_PINNED,pinned:null!=r?r:null,columns:e,column:i,source:t};this.eventService.dispatchEvent(n)}dispatchColumnVisibleEvent(e,t){if(!e.length)return;const i=1===e.length?e[0]:null,r=this.getCommonValue(e,e=>e.isVisible()),n={type:ct.EVENT_COLUMN_VISIBLE,visible:r,columns:e,column:i,source:t};this.eventService.dispatchEvent(n)}autoSizeColumn(e,t,i){e&&this.autoSizeColumns({columns:[e],skipHeader:i,skipHeaderGroups:!0,source:t})}autoSizeColumnGroupsByColumns(e,t,i){const r=new Set;let n;this.getGridColumns(e).forEach(e=>{let t=e.getParent();for(;t&&t!=i;)t.isPadding()||r.add(t),t=t.getParent()});for(const e of r){for(const t of this.ctrlsService.getHeaderRowContainerCtrls())if(n=t.getHeaderCtrlForColumn(e),n)break;n&&n.resizeLeafColumnsToFit(t)}return[]}autoSizeAllColumns(e,t){if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.autoSizeAllColumns(e,t));const i=this.getAllDisplayedColumns();this.autoSizeColumns({columns:i,skipHeader:t,source:e})}getColumnsFromTree(e){const t=[],i=e=>{for(let r=0;r<e.length;r++){const n=e[r];n instanceof be?t.push(n):n instanceof Ae&&i(n.getChildren())}};return i(e),t}getAllDisplayedTrees(){return this.displayedTreeLeft&&this.displayedTreeRight&&this.displayedTreeCentre?this.displayedTreeLeft.concat(this.displayedTreeCentre).concat(this.displayedTreeRight):null}getPrimaryColumnTree(){return this.primaryColumnTree}getHeaderRowCount(){return this.gridHeaderRowCount}getDisplayedTreeLeft(){return this.displayedTreeLeft}getDisplayedTreeRight(){return this.displayedTreeRight}getDisplayedTreeCentre(){return this.displayedTreeCentre}isColumnDisplayed(e){return this.getAllDisplayedColumns().indexOf(e)>=0}getAllDisplayedColumns(){return this.displayedColumns}getViewportColumns(){return this.viewportColumns}getDisplayedLeftColumnsForRow(e){return this.colSpanActive?this.getDisplayedColumnsForRow(e,this.displayedColumnsLeft):this.displayedColumnsLeft}getDisplayedRightColumnsForRow(e){return this.colSpanActive?this.getDisplayedColumnsForRow(e,this.displayedColumnsRight):this.displayedColumnsRight}isColSpanActive(){return this.colSpanActive}getDisplayedColumnsForRow(e,t,i,r){const n=[];let s=null;for(let o=0;o<t.length;o++){const a=t[o],l=t.length-o,c=Math.min(a.getColSpan(e),l),u=[a];if(c>1){const e=c-1;for(let i=1;i<=e;i++)u.push(t[o+i]);o+=e}let h;i?(h=!1,u.forEach(e=>{i(e)&&(h=!0)})):h=!0,h&&(0===n.length&&s&&r&&r(a)&&n.push(s),n.push(a)),s=a}return n}getViewportCenterColumnsForRow(e){if(!this.colSpanActive)return this.viewportColumnsCenter;const t=this.isColumnVirtualisationSuppressed()?null:this.isColumnInRowViewport.bind(this);return this.getDisplayedColumnsForRow(e,this.displayedColumnsCenter,t,e=>{const t=e.getLeft();return y(t)&&t>this.viewportLeft})}isColumnAtEdge(e,t){const i=this.getAllDisplayedColumns();if(!i.length)return!1;const r="first"===t;let n;if(e instanceof lt){const t=e.getDisplayedLeafColumns();if(!t.length)return!1;n=r?t[0]:Pe(t)}else n=e;return(r?i[0]:Pe(i))===n}getAriaColumnIndex(e){let t;return t=e instanceof lt?e.getLeafColumns()[0]:e,this.ariaOrderColumns.indexOf(t)+1}isColumnInHeaderViewport(e){return!!e.isAutoHeaderHeight()||this.isColumnInRowViewport(e)}isColumnInRowViewport(e){if(e.isAutoHeight())return!0;const t=e.getLeft()||0,i=t+e.getActualWidth(),r=this.viewportLeft-200,n=this.viewportRight+200;return!(t<r&&i<r||t>n&&i>n)}getDisplayedColumnsLeftWidth(){return this.getWidthOfColsInList(this.displayedColumnsLeft)}getDisplayedColumnsRightWidth(){return this.getWidthOfColsInList(this.displayedColumnsRight)}updatePrimaryColumnList(e,t,i,r,n,s){if(!e||S(e))return;let o=!1;if(e.forEach(e=>{if(!e)return;const n=this.getPrimaryColumn(e);if(n){if(i){if(t.indexOf(n)>=0)return;t.push(n)}else{if(t.indexOf(n)<0)return;Oe(t,n)}r(n),o=!0}}),!o)return;this.autoGroupsNeedBuilding&&this.updateGridColumns(),this.updateDisplayedColumns(s);const a={type:n,columns:t,column:1===t.length?t[0]:null,source:s};this.eventService.dispatchEvent(a)}setRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.setPrimaryColumnList(e,this.rowGroupColumns,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,!0,this.setRowGroupActive.bind(this),t)}setRowGroupActive(e,t,i){e!==t.isRowGroupActive()&&(t.setRowGroupActive(e,i),e&&!this.gos.get("suppressRowGroupHidesColumns")&&this.setColumnsVisible([t],!1,i),e||this.gos.get("suppressMakeColumnVisibleAfterUnGroup")||this.setColumnsVisible([t],!0,i))}addRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.updatePrimaryColumnList(e,this.rowGroupColumns,!0,this.setRowGroupActive.bind(this,!0),ct.EVENT_COLUMN_ROW_GROUP_CHANGED,t)}removeRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.updatePrimaryColumnList(e,this.rowGroupColumns,!1,this.setRowGroupActive.bind(this,!1),ct.EVENT_COLUMN_ROW_GROUP_CHANGED,t)}addPivotColumns(e,t){this.updatePrimaryColumnList(e,this.pivotColumns,!0,e=>e.setPivotActive(!0,t),ct.EVENT_COLUMN_PIVOT_CHANGED,t)}setPivotColumns(e,t){this.setPrimaryColumnList(e,this.pivotColumns,ct.EVENT_COLUMN_PIVOT_CHANGED,!0,(e,i)=>{i.setPivotActive(e,t)},t)}removePivotColumns(e,t){this.updatePrimaryColumnList(e,this.pivotColumns,!1,e=>e.setPivotActive(!1,t),ct.EVENT_COLUMN_PIVOT_CHANGED,t)}setPrimaryColumnList(e,t,i,r,n,s){if(!this.gridColumns)return;const o=new Map;t.forEach((e,t)=>o.set(e,t)),t.length=0,y(e)&&e.forEach(e=>{const i=this.getPrimaryColumn(e);i&&t.push(i)}),t.forEach((e,t)=>{const i=o.get(e);void 0!==i?r&&i!==t||o.delete(e):o.set(e,0)}),(this.primaryColumns||[]).forEach(e=>{const i=t.indexOf(e)>=0;n(i,e)}),this.autoGroupsNeedBuilding&&this.updateGridColumns(),this.updateDisplayedColumns(s),this.dispatchColumnChangedEvent(i,[...o.keys()],s)}setValueColumns(e,t){this.setPrimaryColumnList(e,this.valueColumns,ct.EVENT_COLUMN_VALUE_CHANGED,!1,this.setValueActive.bind(this),t)}setValueActive(e,t,i){if(e!==t.isValueActive()&&(t.setValueActive(e,i),e&&!t.getAggFunc()&&this.aggFuncService)){const e=this.aggFuncService.getDefaultAggFunc(t);t.setAggFunc(e)}}addValueColumns(e,t){this.updatePrimaryColumnList(e,this.valueColumns,!0,this.setValueActive.bind(this,!0),ct.EVENT_COLUMN_VALUE_CHANGED,t)}removeValueColumns(e,t){this.updatePrimaryColumnList(e,this.valueColumns,!1,this.setValueActive.bind(this,!1),ct.EVENT_COLUMN_VALUE_CHANGED,t)}normaliseColumnWidth(e,t){const i=e.getMinWidth();y(i)&&t<i&&(t=i);const r=e.getMaxWidth();return y(r)&&e.isGreaterThanMax(t)&&(t=r),t}getPrimaryOrGridColumn(e){return this.getPrimaryColumn(e)||this.getGridColumn(e)}setColumnWidths(e,t,i,r){const n=[];e.forEach(e=>{const i=this.getPrimaryOrGridColumn(e.key);if(i&&(n.push({width:e.newWidth,ratios:[1],columns:[i]}),"shift"===this.gos.get("colResizeDefault")&&(t=!t),t)){const t=this.getDisplayedColAfter(i);if(!t)return;const r=i.getActualWidth()-e.newWidth,s=t.getActualWidth()+r;n.push({width:s,ratios:[1],columns:[t]})}}),0!==n.length&&this.resizeColumnSets({resizeSets:n,finished:i,source:r})}checkMinAndMaxWidthsForSet(e){const{columns:t,width:i}=e;let r=0,n=0,s=!0;return t.forEach(e=>{const t=e.getMinWidth();r+=t||0;const i=e.getMaxWidth();y(i)&&i>0?n+=i:s=!1}),i>=r&&(!s||i<=n)}resizeColumnSets(e){const{resizeSets:t,finished:i,source:r}=e;if(t&&!t.every(e=>this.checkMinAndMaxWidthsForSet(e))){if(i){const e=t&&t.length>0?t[0].columns:null;this.dispatchColumnResizedEvent(e,i,r)}return}const n=[],s=[];t.forEach(e=>{const{width:t,columns:i,ratios:o}=e,a={},l={};i.forEach(e=>s.push(e));let c=!0,u=0;for(;c;){if(u++,u>1e3){console.error("AG Grid: infinite loop in resizeColumnSets");break}c=!1;const e=[];let r=0,n=t;i.forEach((t,i)=>{if(l[t.getId()])n-=a[t.getId()];else{e.push(t);const n=o[i];r+=n}});const s=1/r;e.forEach((i,r)=>{let u;r===e.length-1?u=n:(u=Math.round(o[r]*t*s),n-=u);const h=i.getMinWidth(),d=i.getMaxWidth();y(h)&&u<h?(u=h,l[i.getId()]=!0,c=!0):y(d)&&d>0&&u>d&&(u=d,l[i.getId()]=!0,c=!0),a[i.getId()]=u})}i.forEach(e=>{const t=a[e.getId()];e.getActualWidth()!==t&&(e.setActualWidth(t,r),n.push(e))})});const o=n.length>0;let a=[];o&&(a=this.refreshFlexedColumns({resizingCols:s,skipSetLeft:!0}),this.setLeftValues(r),this.updateBodyWidths(),this.checkViewportColumns());const l=s.concat(a);(o||i)&&this.dispatchColumnResizedEvent(l,i,r,a)}setColumnAggFunc(e,t,i){if(!e)return;const r=this.getPrimaryColumn(e);r&&(r.setAggFunc(t),this.dispatchColumnChangedEvent(ct.EVENT_COLUMN_VALUE_CHANGED,[r],i))}moveRowGroupColumn(e,t,i){if(this.isRowGroupEmpty())return;const r=this.rowGroupColumns[e],n=this.rowGroupColumns.slice(e,t);this.rowGroupColumns.splice(e,1),this.rowGroupColumns.splice(t,0,r);const s={type:ct.EVENT_COLUMN_ROW_GROUP_CHANGED,columns:n,column:1===n.length?n[0]:null,source:i};this.eventService.dispatchEvent(s)}moveColumns(e,t,i,r=!0){if(!this.gridColumns)return;if(this.columnAnimationService.start(),t>this.gridColumns.length-e.length)return console.warn("AG Grid: tried to insert columns in invalid location, toIndex = "+t),void console.warn("AG Grid: remember that you should not count the moving columns when calculating the new index");const n=this.getGridColumns(e);!this.doesMovePassRules(n,t)||(He(this.gridColumns,n,t),this.updateDisplayedColumns(i),this.dispatchColumnMovedEvent({movedColumns:n,source:i,toIndex:t,finished:r}),this.columnAnimationService.finish())}doesMovePassRules(e,t){const i=this.getProposedColumnOrder(e,t);return this.doesOrderPassRules(i)}doesOrderPassRules(e){return!!this.doesMovePassMarryChildren(e)&&!!this.doesMovePassLockedPositions(e)}getProposedColumnOrder(e,t){const i=this.gridColumns.slice();return He(i,e,t),i}sortColumnsLikeGridColumns(e){!e||e.length<=1||e.filter(e=>this.gridColumns.indexOf(e)<0).length>0||e.sort((e,t)=>this.gridColumns.indexOf(e)-this.gridColumns.indexOf(t))}doesMovePassLockedPositions(e){let t=0,i=!0;return e.forEach(e=>{const r=(n=e.getColDef().lockPosition)?!0===n||"left"===n?0:2:1;var n;r<t&&(i=!1),t=r}),i}doesMovePassMarryChildren(e){let t=!0;return ot(null,this.gridBalancedTree,i=>{if(!(i instanceof Ae))return;const r=i,n=r.getColGroupDef();if(!n||!n.marryChildren)return;const s=[];r.getLeafColumns().forEach(t=>{const i=e.indexOf(t);s.push(i)}),Math.max.apply(Math,s)-Math.min.apply(Math,s)>r.getLeafColumns().length-1&&(t=!1)}),t}moveColumnByIndex(e,t,i){if(!this.gridColumns)return;const r=this.gridColumns[e];this.moveColumns([r],t,i)}getColumnDefs(){if(!this.primaryColumns)return;const e=this.primaryColumns.slice();return this.gridColsArePrimary?e.sort((e,t)=>this.gridColumns.indexOf(e)-this.gridColumns.indexOf(t)):this.lastPrimaryOrder&&e.sort((e,t)=>this.lastPrimaryOrder.indexOf(e)-this.lastPrimaryOrder.indexOf(t)),this.columnDefFactory.buildColumnDefs(e,this.rowGroupColumns,this.pivotColumns)}getBodyContainerWidth(){return this.bodyWidth}getContainerWidth(e){switch(e){case"left":return this.leftWidth;case"right":return this.rightWidth;default:return this.bodyWidth}}updateBodyWidths(){const e=this.getWidthOfColsInList(this.displayedColumnsCenter),t=this.getWidthOfColsInList(this.displayedColumnsLeft),i=this.getWidthOfColsInList(this.displayedColumnsRight);if(this.bodyWidthDirty=this.bodyWidth!==e,this.bodyWidth!==e||this.leftWidth!==t||this.rightWidth!==i){this.bodyWidth=e,this.leftWidth=t,this.rightWidth=i;const r={type:ct.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED};this.eventService.dispatchEvent(r);const n={type:ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED};this.eventService.dispatchEvent(n)}}getValueColumns(){return this.valueColumns?this.valueColumns:[]}getPivotColumns(){return this.pivotColumns?this.pivotColumns:[]}isPivotActive(){return this.pivotColumns&&this.pivotColumns.length>0&&this.pivotMode}getRowGroupColumns(){return this.rowGroupColumns?this.rowGroupColumns:[]}getDisplayedCenterColumns(){return this.displayedColumnsCenter}getDisplayedLeftColumns(){return this.displayedColumnsLeft}getDisplayedRightColumns(){return this.displayedColumnsRight}getAllPrimaryColumns(){return this.primaryColumns?this.primaryColumns:null}getSecondaryColumns(){return this.secondaryColumns?this.secondaryColumns:null}getAllColumnsForQuickFilter(){return this.columnsForQuickFilter}getAllGridColumns(){var e;return null!=(e=this.gridColumns)?e:[]}isRowGroupEmpty(){return S(this.rowGroupColumns)}setColumnsVisible(e,t=!1,i){this.applyColumnState({state:e.map(e=>({colId:"string"==typeof e?e:e.getColId(),hide:!t}))},i)}setColumnsPinned(e,t,i){if(!this.gridColumns)return;if(this.gos.isDomLayout("print"))return void console.warn("AG Grid: Changing the column pinning status is not allowed with domLayout='print'");let r;this.columnAnimationService.start(),r=!0===t||"left"===t?"left":"right"===t?"right":null,this.actionOnGridColumns(e,e=>e.getPinned()!==r&&(e.setPinned(r),!0),i,()=>({type:ct.EVENT_COLUMN_PINNED,pinned:r,column:null,columns:null,source:i})),this.columnAnimationService.finish()}actionOnGridColumns(e,t,i,r){if(S(e))return;const n=[];if(e.forEach(e=>{if(!e)return;const i=this.getGridColumn(e);i&&!1!==t(i)&&n.push(i)}),n.length&&(this.updateDisplayedColumns(i),y(r)&&r)){const e=r();e.columns=n,e.column=1===n.length?n[0]:null,this.eventService.dispatchEvent(e)}}getDisplayedColBefore(e){const t=this.getAllDisplayedColumns(),i=t.indexOf(e);return i>0?t[i-1]:null}getDisplayedColAfter(e){const t=this.getAllDisplayedColumns(),i=t.indexOf(e);return i<t.length-1?t[i+1]:null}getDisplayedGroupAtDirection(e,t){const i=e.getProvidedColumnGroup().getLevel()+e.getPaddingLevel(),r=e.getDisplayedLeafColumns(),n="After"===t?Pe(r):r[0],s=`getDisplayedCol${t}`;for(;;){const t=this[s](n);if(!t)return null;const r=this.getColumnGroupAtLevel(t,i);if(r!==e)return r}}getColumnGroupAtLevel(e,t){let i,r,n=e.getParent();for(;i=n.getProvidedColumnGroup().getLevel(),r=n.getPaddingLevel(),!(i+r<=t);)n=n.getParent();return n}isPinningLeft(){return this.displayedColumnsLeft.length>0}isPinningRight(){return this.displayedColumnsRight.length>0}getPrimaryAndSecondaryAndAutoColumns(){return[].concat(this.primaryColumns||[],this.groupAutoColumns||[],this.secondaryColumns||[])}createStateItemFromColumn(e){const t=e.isRowGroupActive()?this.rowGroupColumns.indexOf(e):null,i=e.isPivotActive()?this.pivotColumns.indexOf(e):null,r=e.isValueActive()?e.getAggFunc():null,n=null!=e.getSort()?e.getSort():null,s=null!=e.getSortIndex()?e.getSortIndex():null,o=null!=e.getFlex()&&e.getFlex()>0?e.getFlex():null;return{colId:e.getColId(),width:e.getActualWidth(),hide:!e.isVisible(),pinned:e.getPinned(),sort:n,sortIndex:s,aggFunc:r,rowGroup:e.isRowGroupActive(),rowGroupIndex:t,pivot:e.isPivotActive(),pivotIndex:i,flex:o}}getColumnState(){if(w(this.primaryColumns)||!this.isAlive())return[];const e=this.getPrimaryAndSecondaryAndAutoColumns().map(this.createStateItemFromColumn.bind(this));return this.orderColumnStateList(e),e}orderColumnStateList(e){const t=Et(this.gridColumns.map((e,t)=>[e.getColId(),t]));e.sort((e,i)=>(t.has(e.colId)?t.get(e.colId):-1)-(t.has(i.colId)?t.get(i.colId):-1))}resetColumnState(e){if(S(this.primaryColumns))return;const t=this.getColumnsFromTree(this.primaryColumnTree),i=[];let r=1e3,n=1e3,s=[];this.groupAutoColumns&&(s=s.concat(this.groupAutoColumns)),t&&(s=s.concat(t)),s.forEach(e=>{const t=this.getColumnStateFromColDef(e);w(t.rowGroupIndex)&&t.rowGroup&&(t.rowGroupIndex=r++),w(t.pivotIndex)&&t.pivot&&(t.pivotIndex=n++),i.push(t)}),this.applyColumnState({state:i,applyOrder:!0},e)}getColumnStateFromColDef(e){const t=(e,t)=>null!=e?e:null!=t?t:null,i=e.getColDef(),r=t(i.sort,i.initialSort),n=t(i.sortIndex,i.initialSortIndex),s=t(i.hide,i.initialHide),o=t(i.pinned,i.initialPinned),a=t(i.width,i.initialWidth),l=t(i.flex,i.initialFlex);let c=t(i.rowGroupIndex,i.initialRowGroupIndex),u=t(i.rowGroup,i.initialRowGroup);null!=c||null!=u&&0!=u||(c=null,u=null);let h=t(i.pivotIndex,i.initialPivotIndex),d=t(i.pivot,i.initialPivot);null!=h||null!=d&&0!=d||(h=null,d=null);const p=t(i.aggFunc,i.initialAggFunc);return{colId:e.getColId(),sort:r,sortIndex:n,hide:s,pinned:o,width:a,flex:l,rowGroup:u,rowGroupIndex:c,pivot:d,pivotIndex:h,aggFunc:p}}applyColumnState(e,t){if(S(this.primaryColumns))return!1;if(e&&e.state&&!e.state.forEach)return console.warn("AG Grid: applyColumnState() - the state attribute should be an array, however an array was not found. Please provide an array of items (one for each col you want to change) for state."),!1;const i=(i,r,n)=>{const s=this.compareColumnStatesAndDispatchEvents(t);this.autoGroupsNeedBuilding=!0;const o=r.slice(),a={},l={},c=[],u=[];let h=0;const d=this.rowGroupColumns.slice(),p=this.pivotColumns.slice();i.forEach(i=>{const r=i.colId||"";if(r.startsWith(dt))return c.push(i),void u.push(i);const s=n(r);s?(this.syncColumnWithStateItem(s,i,e.defaultState,a,l,!1,t),Oe(o,s)):(u.push(i),h+=1)});const g=i=>this.syncColumnWithStateItem(i,null,e.defaultState,a,l,!1,t);o.forEach(g);const f=(e,t,i,r)=>{const n=e[i.getId()],s=e[r.getId()],o=null!=n,a=null!=s;if(o&&a)return n-s;if(o)return-1;if(a)return 1;const l=t.indexOf(i),c=t.indexOf(r),u=l>=0;return u&&c>=0?l-c:u?-1:1};this.rowGroupColumns.sort(f.bind(this,a,d)),this.pivotColumns.sort(f.bind(this,l,p)),this.updateGridColumns();const m=this.groupAutoColumns?this.groupAutoColumns.slice():[];return c.forEach(i=>{const r=this.getAutoColumn(i.colId);Oe(m,r),this.syncColumnWithStateItem(r,i,e.defaultState,null,null,!0,t)}),m.forEach(g),this.applyOrderAfterApplyState(e),this.updateDisplayedColumns(t),this.dispatchEverythingChanged(t),s(),{unmatchedAndAutoStates:u,unmatchedCount:h}};this.columnAnimationService.start();let{unmatchedAndAutoStates:r,unmatchedCount:n}=i(e.state||[],this.primaryColumns||[],e=>this.getPrimaryColumn(e));return(r.length>0||y(e.defaultState))&&(n=i(r,this.secondaryColumns||[],e=>this.getSecondaryColumn(e)).unmatchedCount),this.columnAnimationService.finish(),0===n}applyOrderAfterApplyState(e){if(!e.applyOrder||!e.state)return;let t=[];const i={};e.state.forEach(e=>{if(!e.colId||i[e.colId])return;const r=this.gridColumnsMap[e.colId];r&&(t.push(r),i[e.colId]=!0)});let r=0;this.gridColumns.forEach(e=>{const n=e.getColId();null==i[n]&&(n.startsWith(dt)?Ge(t,e,r++):t.push(e))}),t=this.placeLockedColumns(t),this.doesMovePassMarryChildren(t)?this.gridColumns=t:console.warn("AG Grid: Applying column order broke a group where columns should be married together. Applying new order has been discarded.")}compareColumnStatesAndDispatchEvents(e){const t={rowGroupColumns:this.rowGroupColumns.slice(),pivotColumns:this.pivotColumns.slice(),valueColumns:this.valueColumns.slice()},i=this.getColumnState(),r={};return i.forEach(e=>{r[e.colId]=e}),()=>{const n=this.getPrimaryAndSecondaryAndAutoColumns(),s=(t,i,r,n)=>{if(xe(i.map(n),r.map(n)))return;const s=new Set(i);r.forEach(e=>{s.delete(e)||s.add(e)});const o=[...s],a={type:t,columns:o,column:1===o.length?o[0]:null,source:e};this.eventService.dispatchEvent(a)},o=e=>{const t=[];return n.forEach(i=>{const n=r[i.getColId()];n&&e(n,i)&&t.push(i)}),t},a=e=>e.getColId();s(ct.EVENT_COLUMN_ROW_GROUP_CHANGED,t.rowGroupColumns,this.rowGroupColumns,a),s(ct.EVENT_COLUMN_PIVOT_CHANGED,t.pivotColumns,this.pivotColumns,a);const l=o((e,t)=>{const i=null!=e.aggFunc,r=i!=t.isValueActive(),n=i&&e.aggFunc!=t.getAggFunc();return r||n});l.length>0&&this.dispatchColumnChangedEvent(ct.EVENT_COLUMN_VALUE_CHANGED,l,e),this.dispatchColumnResizedEvent(o((e,t)=>e.width!=t.getActualWidth()),!0,e),this.dispatchColumnPinnedEvent(o((e,t)=>e.pinned!=t.getPinned()),e),this.dispatchColumnVisibleEvent(o((e,t)=>e.hide==t.isVisible()),e);const c=o((e,t)=>e.sort!=t.getSort()||e.sortIndex!=t.getSortIndex());c.length>0&&this.sortController.dispatchSortChangedEvents(e,c),this.normaliseColumnMovedEventForColumnState(i,e)}}getCommonValue(e,t){if(!e||0==e.length)return;const i=t(e[0]);for(let r=1;r<e.length;r++)if(i!==t(e[r]))return;return i}normaliseColumnMovedEventForColumnState(e,t){const i=this.getColumnState(),r={};i.forEach(e=>r[e.colId]=e);const n={};e.forEach(e=>{r[e.colId]&&(n[e.colId]=!0)});const s=e.filter(e=>n[e.colId]),o=i.filter(e=>n[e.colId]),a=[];o.forEach((e,t)=>{const i=s&&s[t];if(i&&i.colId!==e.colId){const e=this.getGridColumn(i.colId);e&&a.push(e)}}),a.length&&this.dispatchColumnMovedEvent({movedColumns:a,source:t,finished:!0})}syncColumnWithStateItem(e,t,i,r,n,s,o){var a;if(!e)return;const l=(e,r)=>{const n={value1:void 0,value2:void 0};let s=!1;return t&&(void 0!==t[e]&&(n.value1=t[e],s=!0),y(r)&&void 0!==t[r]&&(n.value2=t[r],s=!0)),!s&&i&&(void 0!==i[e]&&(n.value1=i[e]),y(r)&&void 0!==i[r]&&(n.value2=i[r])),n},c=l("hide").value1;void 0!==c&&e.setVisible(!c,o);const u=l("pinned").value1;void 0!==u&&e.setPinned(u);const h=null!=(a=e.getColDef().minWidth)?a:this.environment.getMinColWidth(),d=l("flex").value1;if(void 0!==d&&e.setFlex(d),null==d){const t=l("width").value1;null!=t&&null!=h&&t>=h&&e.setActualWidth(t,o)}const p=l("sort").value1;void 0!==p&&("desc"===p||"asc"===p?e.setSort(p,o):e.setSort(void 0,o));const g=l("sortIndex").value1;if(void 0!==g&&e.setSortIndex(g),s||!e.isPrimary())return;const f=l("aggFunc").value1;void 0!==f&&("string"==typeof f?(e.setAggFunc(f),e.isValueActive()||(e.setValueActive(!0,o),this.valueColumns.push(e))):(y(f)&&console.warn("AG Grid: stateItem.aggFunc must be a string. if using your own aggregation functions, register the functions first before using them in get/set state. This is because it is intended for the column state to be stored and retrieved as simple JSON."),e.isValueActive()&&(e.setValueActive(!1,o),Oe(this.valueColumns,e))));const{value1:m,value2:v}=l("rowGroup","rowGroupIndex");void 0===m&&void 0===v||("number"==typeof v||m?(e.isRowGroupActive()||(e.setRowGroupActive(!0,o),this.rowGroupColumns.push(e)),r&&"number"==typeof v&&(r[e.getId()]=v)):e.isRowGroupActive()&&(e.setRowGroupActive(!1,o),Oe(this.rowGroupColumns,e)));const{value1:C,value2:w}=l("pivot","pivotIndex");void 0===C&&void 0===w||("number"==typeof w||C?(e.isPivotActive()||(e.setPivotActive(!0,o),this.pivotColumns.push(e)),n&&"number"==typeof w&&(n[e.getId()]=w)):e.isPivotActive()&&(e.setPivotActive(!1,o),Oe(this.pivotColumns,e)))}getGridColumns(e){return this.getColumns(e,this.getGridColumn.bind(this))}getColumns(e,t){const i=[];return e&&e.forEach(e=>{const r=t(e);r&&i.push(r)}),i}getColumnWithValidation(e){if(null==e)return null;const t=this.getGridColumn(e);return t||console.warn("AG Grid: could not find column "+e),t}getPrimaryColumn(e){return this.primaryColumns?this.getColumn(e,this.primaryColumns,this.primaryColumnsMap):null}getGridColumn(e){return this.getColumn(e,this.gridColumns,this.gridColumnsMap)}lookupGridColumn(e){return this.gridColumnsMap[e]}getSecondaryColumn(e){return this.secondaryColumns?this.getColumn(e,this.secondaryColumns,this.secondaryColumnsMap):null}getColumn(e,t,i){if(!e||!i)return null;if("string"==typeof e&&i[e])return i[e];for(let i=0;i<t.length;i++)if(this.columnsMatch(t[i],e))return t[i];return this.getAutoColumn(e)}getSourceColumnsForGroupColumn(e){const t=e.getColDef().showRowGroup;if(!t)return null;if(!0===t)return this.rowGroupColumns.slice(0);const i=this.getPrimaryColumn(t);return i?[i]:null}getAutoColumn(e){return this.groupAutoColumns&&y(this.groupAutoColumns)&&!w(this.groupAutoColumns)&&this.groupAutoColumns.find(t=>this.columnsMatch(t,e))||null}columnsMatch(e,t){const i=e===t,r=e.getColDef()===t,n=e.getColId()==t;return i||r||n}getDisplayNameForColumn(e,t,i=!1){if(!e)return null;const r=this.getHeaderName(e.getColDef(),e,null,null,t);return i?this.wrapHeaderNameWithAggFunc(e,r):r}getDisplayNameForProvidedColumnGroup(e,t,i){const r=t?t.getColGroupDef():null;return r?this.getHeaderName(r,null,e,t,i):null}getDisplayNameForColumnGroup(e,t){return this.getDisplayNameForProvidedColumnGroup(e,e.getProvidedColumnGroup(),t)}getHeaderName(e,t,i,r,n){const s=e.headerValueGetter;if(s){const o=this.gos.addGridCommonParams({colDef:e,column:t,columnGroup:i,providedColumnGroup:r,location:n});return"function"==typeof s?s(o):"string"==typeof s?this.expressionService.evaluate(s,o):(console.warn("AG Grid: headerValueGetter must be a function or a string"),"")}return null!=e.headerName?e.headerName:e.field?wt(e.field):""}wrapHeaderNameWithAggFunc(e,t){if(this.gos.get("suppressAggFuncInHeader"))return t;const i=e.getColDef().pivotValueColumn;let r,n=null;if(y(i)){const s=this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&1===this.valueColumns.length,o=void 0!==e.getColDef().pivotTotalColumnIds;if(s&&!o)return t;n=i?i.getAggFunc():null,r=!0}else{const t=e.isValueActive(),i=this.pivotMode||!this.isRowGroupEmpty();t&&i?(n=e.getAggFunc(),r=!0):r=!1}if(r){const e="string"==typeof n?n:"func";return`${this.localeService.getLocaleTextFunc()(e,e)}(${t})`}return t}getColumnGroup(e,t){if(!e)return null;if(e instanceof lt)return e;const i=this.getAllDisplayedTrees(),r="number"==typeof t;let n=null;return _t(i,!1,i=>{if(i instanceof lt){const s=i;let o;o=r?e===s.getGroupId()&&t===s.getPartId():e===s.getGroupId(),o&&(n=s)}}),n}isReady(){return this.ready}extractValueColumns(e,t){this.valueColumns=this.extractColumns(t,this.valueColumns,(t,i)=>t.setValueActive(i,e),()=>{},()=>{},e=>{const t=e.aggFunc;return null===t||""===t?null:void 0!==t?!!t:void 0},e=>null!=e.initialAggFunc&&""!=e.initialAggFunc),this.valueColumns.forEach(e=>{const t=e.getColDef();null!=t.aggFunc&&""!=t.aggFunc?e.setAggFunc(t.aggFunc):e.getAggFunc()||e.setAggFunc(t.initialAggFunc)})}extractRowGroupColumns(e,t){this.rowGroupColumns=this.extractColumns(t,this.rowGroupColumns,(t,i)=>t.setRowGroupActive(i,e),e=>e.rowGroupIndex,e=>e.initialRowGroupIndex,e=>e.rowGroup,e=>e.initialRowGroup)}extractColumns(e=[],t=[],i,r,n,s,o){const a=[],l=[];(this.primaryColumns||[]).forEach(i=>{const c=e.indexOf(i)<0,u=i.getColDef(),h=A(s(u)),d=A(o(u)),p=E(r(u)),g=E(n(u));let f;f=void 0!==h?h:void 0!==p?null!==p&&p>=0:c?void 0!==d?d:!(void 0===g)&&null!=g&&g>=0:t.indexOf(i)>=0,f&&((c?null!=p||null!=g:null!=p)?a.push(i):l.push(i))});const c=e=>{const t=r(e.getColDef()),i=n(e.getColDef());return null!=t?t:i};a.sort((e,t)=>{const i=c(e),r=c(t);return i===r?0:i<r?-1:1});const u=[].concat(a);return t.forEach(e=>{l.indexOf(e)>=0&&u.push(e)}),l.forEach(e=>{u.indexOf(e)<0&&u.push(e)}),t.forEach(e=>{u.indexOf(e)<0&&i(e,!1)}),u.forEach(e=>{t.indexOf(e)<0&&i(e,!0)}),u}extractPivotColumns(e,t){this.pivotColumns=this.extractColumns(t,this.pivotColumns,(t,i)=>t.setPivotActive(i,e),e=>e.pivotIndex,e=>e.initialPivotIndex,e=>e.pivot,e=>e.initialPivot)}resetColumnGroupState(e){if(!this.primaryColumnTree)return;const t=[];ot(null,this.primaryColumnTree,e=>{if(e instanceof Ae){const i=e.getColGroupDef(),r={groupId:e.getGroupId(),open:i?i.openByDefault:void 0};t.push(r)}}),this.setColumnGroupState(t,e)}getColumnGroupState(){const e=[];return ot(null,this.gridBalancedTree,t=>{t instanceof Ae&&e.push({groupId:t.getGroupId(),open:t.isExpanded()})}),e}setColumnGroupState(e,t){if(!this.gridBalancedTree)return;this.columnAnimationService.start();const i=[];if(e.forEach(e=>{const t=e.groupId,r=e.open,n=this.getProvidedColumnGroup(t);n&&n.isExpanded()!==r&&(this.logger.log("columnGroupOpened("+n.getGroupId()+","+r+")"),n.setExpanded(r),i.push(n))}),this.updateGroupsAndDisplayedColumns(t),this.setFirstRightAndLastLeftPinned(t),i.length){const e={type:ct.EVENT_COLUMN_GROUP_OPENED,columnGroup:1===Ae.length?i[0]:void 0,columnGroups:i};this.eventService.dispatchEvent(e)}this.columnAnimationService.finish()}setColumnGroupOpened(e,t,i){let r;r=e instanceof Ae?e.getId():e||"",this.setColumnGroupState([{groupId:r,open:t}],i)}getProvidedColumnGroup(e){"string"!=typeof e&&console.error("AG Grid: group key must be a string");let t=null;return ot(null,this.gridBalancedTree,i=>{i instanceof Ae&&i.getId()===e&&(t=i)}),t}calculateColumnsForDisplay(){let e;return e=this.pivotMode&&w(this.secondaryColumns)?this.gridColumns.filter(e=>{const t=this.groupAutoColumns&&Be(this.groupAutoColumns,e),i=this.valueColumns&&Be(this.valueColumns,e);return t||i}):this.gridColumns.filter(e=>this.groupAutoColumns&&Be(this.groupAutoColumns,e)||e.isVisible()),e}checkColSpanActiveInCols(e){let t=!1;return e.forEach(e=>{y(e.getColDef().colSpan)&&(t=!0)}),t}calculateColumnsForGroupDisplay(){this.groupDisplayColumns=[],this.groupDisplayColumnsMap={},this.gridColumns.forEach(e=>{const t=e.getColDef(),i=t.showRowGroup;t&&y(i)&&(this.groupDisplayColumns.push(e),"string"==typeof i?this.groupDisplayColumnsMap[i]=e:!0===i&&this.getRowGroupColumns().forEach(t=>{this.groupDisplayColumnsMap[t.getId()]=e}))})}getGroupDisplayColumns(){return this.groupDisplayColumns}getGroupDisplayColumnForGroup(e){return this.groupDisplayColumnsMap[e]}updateDisplayedColumns(e){const t=this.calculateColumnsForDisplay();this.buildDisplayedTrees(t),this.updateGroupsAndDisplayedColumns(e),this.setFirstRightAndLastLeftPinned(e)}isSecondaryColumnsPresent(){return y(this.secondaryColumns)}setSecondaryColumns(e,t){if(!this.gridColumns)return;const i=e;if(i||!w(this.secondaryColumns)){if(i){this.processSecondaryColumnDefinitions(e);const i=this.columnFactory.createColumnTree(e,!1,this.secondaryBalancedTree||this.previousSecondaryColumns||void 0,t);this.destroyOldColumns(this.secondaryBalancedTree,i.columnTree),this.secondaryBalancedTree=i.columnTree,this.secondaryHeaderRowCount=i.treeDept+1,this.secondaryColumns=this.getColumnsFromTree(this.secondaryBalancedTree),this.secondaryColumnsMap={},this.secondaryColumns.forEach(e=>this.secondaryColumnsMap[e.getId()]=e),this.previousSecondaryColumns=null}else this.previousSecondaryColumns=this.secondaryBalancedTree,this.secondaryBalancedTree=null,this.secondaryHeaderRowCount=-1,this.secondaryColumns=null,this.secondaryColumnsMap={};this.updateGridColumns(),this.updateDisplayedColumns(t)}}processSecondaryColumnDefinitions(e){const t=this.gos.get("processPivotResultColDef"),i=this.gos.get("processPivotResultColGroupDef");if(!t&&!i)return;const r=e=>{e.forEach(e=>{if(y(e.children)){const t=e;i&&i(t),r(t.children)}else t&&t(e)})};e&&r(e)}updateGridColumns(){const e=this.gridBalancedTree;if(this.gridColsArePrimary?this.lastPrimaryOrder=this.gridColumns:this.lastSecondaryOrder=this.gridColumns,this.createGroupAutoColumnsIfNeeded()){const e=Et(this.groupAutoColumns.map(e=>[e,!0]));this.lastPrimaryOrder&&(this.lastPrimaryOrder=this.lastPrimaryOrder.filter(t=>!e.has(t)),this.lastPrimaryOrder=[...this.groupAutoColumns,...this.lastPrimaryOrder]),this.lastSecondaryOrder&&(this.lastSecondaryOrder=this.lastSecondaryOrder.filter(t=>!e.has(t)),this.lastSecondaryOrder=[...this.groupAutoColumns,...this.lastSecondaryOrder])}let t;if(this.secondaryColumns&&this.secondaryBalancedTree){const e=this.secondaryColumns.some(e=>void 0!==this.gridColumnsMap[e.getColId()]);this.gridBalancedTree=this.secondaryBalancedTree.slice(),this.gridHeaderRowCount=this.secondaryHeaderRowCount,this.gridColumns=this.secondaryColumns.slice(),this.gridColsArePrimary=!1,e&&(t=this.lastSecondaryOrder)}else this.primaryColumns&&(this.gridBalancedTree=this.primaryColumnTree.slice(),this.gridHeaderRowCount=this.primaryHeaderRowCount,this.gridColumns=this.primaryColumns.slice(),this.gridColsArePrimary=!0,t=this.lastPrimaryOrder);if(this.addAutoGroupToGridColumns(),this.orderGridColsLike(t),this.gridColumns=this.placeLockedColumns(this.gridColumns),this.calculateColumnsForGroupDisplay(),this.refreshQuickFilterColumns(),this.clearDisplayedAndViewportColumns(),this.colSpanActive=this.checkColSpanActiveInCols(this.gridColumns),this.gridColumnsMap={},this.gridColumns.forEach(e=>this.gridColumnsMap[e.getId()]=e),this.setAutoHeightActive(),!xe(e,this.gridBalancedTree)){const e={type:ct.EVENT_GRID_COLUMNS_CHANGED};this.eventService.dispatchEvent(e)}}setAutoHeightActive(){this.autoHeightActive=this.gridColumns.filter(e=>e.isAutoHeight()).length>0,this.autoHeightActive&&(this.autoHeightActiveAtLeastOnce=!0,this.gos.isRowModelType("clientSide")||this.gos.isRowModelType("serverSide")||U("autoHeight columns only work with Client Side Row Model and Server Side Row Model."))}orderGridColsLike(e){if(w(e))return;const t=Et(e.map((e,t)=>[e,t]));let i=!0;if(this.gridColumns.forEach(e=>{t.has(e)&&(i=!1)}),i)return;const r=Et(this.gridColumns.map(e=>[e,!0])),n=e.filter(e=>r.has(e)),s=Et(n.map(e=>[e,!0])),o=this.gridColumns.filter(e=>!s.has(e)),a=n.slice();o.forEach(e=>{let t=e.getOriginalParent();if(!t)return void a.push(e);const i=[];for(;!i.length&&t;)t.getLeafColumns().forEach(e=>{const t=a.indexOf(e)>=0,r=i.indexOf(e)<0;t&&r&&i.push(e)}),t=t.getOriginalParent();if(!i.length)return void a.push(e);const r=i.map(e=>a.indexOf(e)),n=Math.max(...r);Ge(a,e,n+1)}),this.gridColumns=a}isPrimaryColumnGroupsPresent(){return this.primaryHeaderRowCount>1}refreshQuickFilterColumns(){var e;let t=null!=(e=this.isPivotMode()&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")?this.secondaryColumns:this.primaryColumns)?e:[];this.groupAutoColumns&&(t=t.concat(this.groupAutoColumns)),this.columnsForQuickFilter=this.gos.get("includeHiddenColumnsInQuickFilter")?t:t.filter(e=>e.isVisible()||e.isRowGroupActive())}placeLockedColumns(e){const t=[],i=[],r=[];return e.forEach(e=>{const n=e.getColDef().lockPosition;"right"===n?r.push(e):"left"===n||!0===n?t.push(e):i.push(e)}),[...t,...i,...r]}addAutoGroupToGridColumns(){if(w(this.groupAutoColumns))return this.destroyOldColumns(this.groupAutoColsBalancedTree),void(this.groupAutoColsBalancedTree=null);this.gridColumns=this.groupAutoColumns?this.groupAutoColumns.concat(this.gridColumns):this.gridColumns;const e=this.columnFactory.createForAutoGroups(this.groupAutoColumns,this.gridBalancedTree);this.destroyOldColumns(this.groupAutoColsBalancedTree,e),this.groupAutoColsBalancedTree=e,this.gridBalancedTree=e.concat(this.gridBalancedTree)}clearDisplayedAndViewportColumns(){this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={},this.displayedColumnsLeft=[],this.displayedColumnsRight=[],this.displayedColumnsCenter=[],this.displayedColumns=[],this.ariaOrderColumns=[],this.viewportColumns=[],this.headerViewportColumns=[],this.viewportColumnsHash=""}updateGroupsAndDisplayedColumns(e){this.updateOpenClosedVisibilityInColumnGroups(),this.deriveDisplayedColumns(e),this.refreshFlexedColumns(),this.extractViewport(),this.updateBodyWidths();const t={type:ct.EVENT_DISPLAYED_COLUMNS_CHANGED};this.eventService.dispatchEvent(t)}deriveDisplayedColumns(e){this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeLeft,this.displayedColumnsLeft),this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeCentre,this.displayedColumnsCenter),this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeRight,this.displayedColumnsRight),this.joinColumnsAriaOrder(),this.joinDisplayedColumns(),this.setLeftValues(e),this.displayedAutoHeightCols=this.displayedColumns.filter(e=>e.isAutoHeight())}isAutoRowHeightActive(){return this.autoHeightActive}wasAutoRowHeightEverActive(){return this.autoHeightActiveAtLeastOnce}joinColumnsAriaOrder(){const e=this.getAllGridColumns(),t=[],i=[],r=[];for(const n of e){const e=n.getPinned();e?!0===e||"left"===e?t.push(n):r.push(n):i.push(n)}this.ariaOrderColumns=t.concat(i).concat(r)}joinDisplayedColumns(){this.gos.get("enableRtl")?this.displayedColumns=this.displayedColumnsRight.concat(this.displayedColumnsCenter).concat(this.displayedColumnsLeft):this.displayedColumns=this.displayedColumnsLeft.concat(this.displayedColumnsCenter).concat(this.displayedColumnsRight)}setLeftValues(e){this.setLeftValuesOfColumns(e),this.setLeftValuesOfGroups()}setLeftValuesOfColumns(e){if(!this.primaryColumns)return;const t=this.getPrimaryAndSecondaryAndAutoColumns().slice(0),i=this.gos.get("enableRtl");[this.displayedColumnsLeft,this.displayedColumnsRight,this.displayedColumnsCenter].forEach(r=>{if(i){let t=this.getWidthOfColsInList(r);r.forEach(i=>{t-=i.getActualWidth(),i.setLeft(t,e)})}else{let t=0;r.forEach(i=>{i.setLeft(t,e),t+=i.getActualWidth()})}Fe(t,r)}),t.forEach(t=>{t.setLeft(null,e)})}setLeftValuesOfGroups(){[this.displayedTreeLeft,this.displayedTreeRight,this.displayedTreeCentre].forEach(e=>{e.forEach(e=>{e instanceof lt&&e.checkLeft()})})}derivedDisplayedColumnsFromDisplayedTree(e,t){t.length=0,_t(e,!0,e=>{e instanceof be&&t.push(e)})}isColumnVirtualisationSuppressed(){return this.suppressColumnVirtualisation||0===this.viewportRight}extractViewportColumns(){this.isColumnVirtualisationSuppressed()?(this.viewportColumnsCenter=this.displayedColumnsCenter,this.headerViewportColumnsCenter=this.displayedColumnsCenter):(this.viewportColumnsCenter=this.displayedColumnsCenter.filter(this.isColumnInRowViewport.bind(this)),this.headerViewportColumnsCenter=this.displayedColumnsCenter.filter(this.isColumnInHeaderViewport.bind(this))),this.viewportColumns=this.viewportColumnsCenter.concat(this.displayedColumnsLeft).concat(this.displayedColumnsRight),this.headerViewportColumns=this.headerViewportColumnsCenter.concat(this.displayedColumnsLeft).concat(this.displayedColumnsRight)}getVirtualHeaderGroupRow(e,t){let i;switch(e){case"left":i=this.viewportRowLeft[t];break;case"right":i=this.viewportRowRight[t];break;default:i=this.viewportRowCenter[t]}return w(i)&&(i=[]),i}calculateHeaderRows(){this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={};const e={};this.headerViewportColumns.forEach(t=>e[t.getId()]=!0);const t=(i,r,n)=>{let s=!1;for(let o=0;o<i.length;o++){const a=i[o];let l=!1;if(a instanceof be)l=!0===e[a.getId()];else{const e=a.getDisplayedChildren();e&&(l=t(e,r,n+1))}l&&(s=!0,r[n]||(r[n]=[]),r[n].push(a))}return s};t(this.displayedTreeLeft,this.viewportRowLeft,0),t(this.displayedTreeRight,this.viewportRowRight,0),t(this.displayedTreeCentre,this.viewportRowCenter,0)}extractViewport(){this.extractViewportColumns();const e=this.viewportColumns.map(e=>`${e.getId()}-${e.getPinned()||"normal"}`).join("#"),t=this.viewportColumnsHash!==e;return t&&(this.viewportColumnsHash=e,this.calculateHeaderRows()),t}refreshFlexedColumns(e={}){var t;const i=e.source?e.source:"flex";if(null!=e.viewportWidth&&(this.flexViewportWidth=e.viewportWidth),!this.flexViewportWidth)return[];let r=-1;if(e.resizingCols){const t=new Set(e.resizingCols);let i=this.displayedColumnsCenter;for(let e=i.length-1;e>=0;e--)if(t.has(i[e])){r=e;break}}let n=0,s=[],o=0,a=0;for(let e=0;e<this.displayedColumnsCenter.length;e++)this.displayedColumnsCenter[e].getFlex()&&e>r?(s.push(this.displayedColumnsCenter[e]),a+=this.displayedColumnsCenter[e].getFlex(),o+=null!=(t=this.displayedColumnsCenter[e].getMinWidth())?t:0):n+=this.displayedColumnsCenter[e].getActualWidth();if(!s.length)return[];let l=[];n+o>this.flexViewportWidth&&(s.forEach(e=>{var t;return e.setActualWidth(null!=(t=e.getMinWidth())?t:0,i)}),l=s,s=[]);const c=[];let u;e:for(;;){u=this.flexViewportWidth-n;const e=u/a;for(let t=0;t<s.length;t++){const r=s[t],o=e*r.getFlex();let u=0;const h=r.getMinWidth(),d=r.getMaxWidth();if(y(h)&&o<h?u=h:y(d)&&o>d&&(u=d),u){r.setActualWidth(u,i),Ne(s,r),a-=r.getFlex(),l.push(r),n+=r.getActualWidth();continue e}c[t]=Math.round(o)}break}let h=u;return s.forEach((e,t)=>{e.setActualWidth(Math.min(c[t],h),i),l.push(e),h-=c[t]}),e.skipSetLeft||this.setLeftValues(i),e.updateBodyWidths&&this.updateBodyWidths(),e.fireResizedEvent&&this.dispatchColumnResizedEvent(l,!0,i,s),s}sizeColumnsToFit(e,t="sizeColumnsToFit",i,r){var n,s,o,u,h;if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.sizeColumnsToFit(e,t,i,r));const d={};r&&(null==(n=null==r?void 0:r.columnLimits)||n.forEach(e=>{var t=e,{key:i}=t,r=((e,t)=>{var i={};for(var r in e)l.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&a)for(var r of a(e))t.indexOf(r)<0&&c.call(e,r)&&(i[r]=e[r]);return i})(t,["key"]);d["string"==typeof i?i:i.getColId()]=r}));const p=this.getAllDisplayedColumns(),g=e===this.getWidthOfColsInList(p);if(e<=0||!p.length||g)return;const f=[],m=[];p.forEach(e=>{!0===e.getColDef().suppressSizeToFit?m.push(e):f.push(e)});const v=f.slice(0);let C=!1;const w=e=>{Oe(f,e),m.push(e)};for(f.forEach(e=>{var i,n;e.resetActualWidth(t);const s=null==d?void 0:d[e.getId()],o=null!=(i=null==s?void 0:s.minWidth)?i:null==r?void 0:r.defaultMinWidth,a=null!=(n=null==s?void 0:s.maxWidth)?n:null==r?void 0:r.defaultMaxWidth,l=e.getActualWidth();"number"==typeof o&&l<o?e.setActualWidth(o,t,!0):"number"==typeof a&&l>a&&e.setActualWidth(a,t,!0)});!C;){C=!0;const i=e-this.getWidthOfColsInList(m);if(i<=0)f.forEach(e=>{var i,n;const s=null!=(n=null==(i=null==d?void 0:d[e.getId()])?void 0:i.minWidth)?n:null==r?void 0:r.defaultMinWidth;"number"!=typeof s?e.setMinimum(t):e.setActualWidth(s,t,!0)});else{const e=i/this.getWidthOfColsInList(f);let n=i;for(let i=f.length-1;i>=0;i--){const a=f[i],l=null==d?void 0:d[a.getId()],c=null!=(s=null==l?void 0:l.minWidth)?s:null==r?void 0:r.defaultMinWidth,p=null!=(o=null==l?void 0:l.maxWidth)?o:null==r?void 0:r.defaultMaxWidth,g=null!=(u=a.getMinWidth())?u:0,m=null!=(h=a.getMaxWidth())?h:Number.MAX_VALUE,v="number"==typeof c&&c>g?c:a.getMinWidth(),S="number"==typeof p&&p<m?p:a.getMaxWidth();let b=Math.round(a.getActualWidth()*e);y(v)&&b<v?(b=v,w(a),C=!1):y(S)&&b>S?(b=S,w(a),C=!1):0===i&&(b=n),a.setActualWidth(b,t,!0),n-=b}}}v.forEach(e=>{e.fireColumnWidthChangedEvent(t)}),this.setLeftValues(t),this.updateBodyWidths(),i||this.dispatchColumnResizedEvent(v,!0,t)}buildDisplayedTrees(e){const t=[],i=[],r=[];e.forEach(e=>{switch(e.getPinned()){case"left":t.push(e);break;case"right":i.push(e);break;default:r.push(e)}});const n=new ht;this.displayedTreeLeft=this.displayedGroupCreator.createDisplayedGroups(t,n,"left",this.displayedTreeLeft),this.displayedTreeRight=this.displayedGroupCreator.createDisplayedGroups(i,n,"right",this.displayedTreeRight),this.displayedTreeCentre=this.displayedGroupCreator.createDisplayedGroups(r,n,null,this.displayedTreeCentre),this.updateDisplayedMap()}updateDisplayedMap(){this.displayedColumnsAndGroupsMap={};const e=e=>{this.displayedColumnsAndGroupsMap[e.getUniqueId()]=e};_t(this.displayedTreeCentre,!1,e),_t(this.displayedTreeLeft,!1,e),_t(this.displayedTreeRight,!1,e)}isDisplayed(e){return this.displayedColumnsAndGroupsMap[e.getUniqueId()]===e}updateOpenClosedVisibilityInColumnGroups(){_t(this.getAllDisplayedTrees(),!1,e=>{e instanceof lt&&e.calculateDisplayedColumns()})}getGroupAutoColumns(){return this.groupAutoColumns}createGroupAutoColumnsIfNeeded(){const e=this.forceRecreateAutoGroups;if(this.forceRecreateAutoGroups=!1,!this.autoGroupsNeedBuilding)return!1;this.autoGroupsNeedBuilding=!1;const t=this.gos.isGroupUseEntireRow(this.pivotMode),i=this.pivotMode?this.gos.get("pivotSuppressAutoColumn"):this.isGroupSuppressAutoColumn();if(!(this.rowGroupColumns.length>0||this.gos.get("treeData"))||i||t)this.groupAutoColumns=null;else{const t=this.autoGroupColService.createAutoGroupColumns(this.rowGroupColumns);if(!this.autoColsEqual(t,this.groupAutoColumns)||e)return this.groupAutoColumns=t,!0}return!1}isGroupSuppressAutoColumn(){return"custom"===this.gos.get("groupDisplayType")||"custom"===this.gos.get("treeDataDisplayType")}autoColsEqual(e,t){return xe(e,t,(e,t)=>e.getColId()===t.getColId())}getWidthOfColsInList(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}getFirstDisplayedColumn(){const e=this.gos.get("enableRtl"),t=["getDisplayedLeftColumns","getDisplayedCenterColumns","getDisplayedRightColumns"];e&&t.reverse();for(let i=0;i<t.length;i++){const r=this[t[i]]();if(r.length)return e?Pe(r):r[0]}return null}setColumnHeaderHeight(e,t){if(e.setAutoHeaderHeight(t)){const t={type:ct.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,column:e,columns:[e],source:"autosizeColumnHeaderHeight"};this.eventService.dispatchEvent(t)}}getColumnGroupHeaderRowHeight(){return this.isPivotMode()?this.getPivotGroupHeaderHeight():this.getGroupHeaderHeight()}getColumnHeaderRowHeight(){const e=this.isPivotMode()?this.getPivotHeaderHeight():this.getHeaderHeight(),t=this.getAllDisplayedColumns().filter(e=>e.isAutoHeaderHeight()).map(e=>e.getAutoHeaderHeight()||0);return Math.max(e,...t)}getHeaderHeight(){var e;return null!=(e=this.gos.get("headerHeight"))?e:this.environment.getFromTheme(25,"headerHeight")}getFloatingFiltersHeight(){var e;return null!=(e=this.gos.get("floatingFiltersHeight"))?e:this.getHeaderHeight()}getGroupHeaderHeight(){var e;return null!=(e=this.gos.get("groupHeaderHeight"))?e:this.getHeaderHeight()}getPivotHeaderHeight(){var e;return null!=(e=this.gos.get("pivotHeaderHeight"))?e:this.getHeaderHeight()}getPivotGroupHeaderHeight(){var e;return null!=(e=this.gos.get("pivotGroupHeaderHeight"))?e:this.getGroupHeaderHeight()}queueResizeOperations(){this.shouldQueueResizeOperations=!0}processResizeOperations(){this.shouldQueueResizeOperations=!1,this.resizeOperationQueue.forEach(e=>e()),this.resizeOperationQueue=[]}resetColumnDefIntoColumn(e,t){const i=e.getUserProvidedColDef();if(!i)return!1;const r=this.columnFactory.addColumnDefaultAndTypes(i,e.getColId());return e.setColDef(r,i,t),!0}isColumnGroupingLocked(e){const t=this.gos.get("groupLockGroupColumns");return!(!e.isRowGroupActive()||0===t)&&(-1===t||t>this.rowGroupColumns.findIndex(t=>t.getColId()===e.getColId()))}generateColumnStateForRowGroupAndPivotIndexes(e,t){let i={};const r=(e,t,r,n,s,o)=>{if(!t.length||!this.primaryColumns)return[];const a=Object.keys(e),l=new Set(a),c=new Set(a),u=new Set(t.map(e=>{const t=e.getColId();return c.delete(t),t}).concat(a)),h=[],d={};let p=0;for(let e=0;e<this.primaryColumns.length;e++){const t=this.primaryColumns[e].getColId();u.has(t)&&(h.push(t),d[t]=p++)}let g=1e3,f=!1,m=0;const v=t=>{const i=d[t];for(let t=m;t<i;t++){const i=h[t];c.has(i)&&(e[i][s]=g++,c.delete(i))}m=i};t.forEach(t=>{const a=t.getColId();if(l.has(a))v(a),e[a][s]=g++;else{const l=t.getColDef();(null===l[s]||void 0===l[s]&&null==l[o])&&(f||(l[r]||void 0===l[r]&&l[n]?v(a):(c.forEach(t=>{e[t][s]=g+d[t]}),g+=h.length,f=!0)),i[a]||(i[a]={colId:a}),i[a][s]=g++)}})};return r(e,this.rowGroupColumns,"rowGroup","initialRowGroup","rowGroupIndex","initialRowGroupIndex"),r(t,this.pivotColumns,"pivot","initialPivot","pivotIndex","initialPivotIndex"),Object.values(i)}onColumnsReady(){const e=this.gos.get("autoSizeStrategy");if(!e)return;const{type:t}=e;setTimeout(()=>{if("fitGridWidth"===t){const{columnLimits:t,defaultMinWidth:i,defaultMaxWidth:r}=e,n=null==t?void 0:t.map(({colId:e,minWidth:t,maxWidth:i})=>({key:e,minWidth:t,maxWidth:i}));this.ctrlsService.getGridBodyCtrl().sizeColumnsToFit({defaultMinWidth:i,defaultMaxWidth:r,columnLimits:n})}else"fitProvidedWidth"===t&&this.sizeColumnsToFit(e.width,"sizeColumnsToFit")})}onFirstDataRendered(){const e=this.gos.get("autoSizeStrategy");if("fitCellContents"!==(null==e?void 0:e.type))return;const{colIds:t,skipHeader:i}=e;setTimeout(()=>{t?this.autoSizeColumns({columns:t,skipHeader:i,source:"autosizeColumns"}):this.autoSizeAllColumns("autosizeColumns",i)})}};function Rt(e){return"gridOptionsUpdated"===e?"gridOptionsChanged":e}function _t(e,t,i){if(e)for(let r=0;r<e.length;r++){const n=e[r];n instanceof lt&&_t(t?n.getDisplayedChildren():n.getChildren(),t,i),i(n)}}g([he("expressionService")],Mt.prototype,"expressionService",2),g([he("columnFactory")],Mt.prototype,"columnFactory",2),g([he("displayedGroupCreator")],Mt.prototype,"displayedGroupCreator",2),g([he("ctrlsService")],Mt.prototype,"ctrlsService",2),g([he("autoWidthCalculator")],Mt.prototype,"autoWidthCalculator",2),g([he("columnAnimationService")],Mt.prototype,"columnAnimationService",2),g([he("autoGroupColService")],Mt.prototype,"autoGroupColService",2),g([he("valueCache")],Mt.prototype,"valueCache",2),g([he("animationFrameService")],Mt.prototype,"animationFrameService",2),g([he("sortController")],Mt.prototype,"sortController",2),g([he("columnDefFactory")],Mt.prototype,"columnDefFactory",2),g([de("aggFuncService")],Mt.prototype,"aggFuncService",2),g([le],Mt.prototype,"init",1),g([ce],Mt.prototype,"destroyColumns",1),g([f(0,ge("loggerFactory"))],Mt.prototype,"setBeans",1),Mt=g([ue("columnModel")],Mt);var Pt=class extends nt{createDisplayedGroups(e,t,i,r){const n=this.mapOldGroupsById(r),s=[];let o=e;for(;o.length;){const e=o;o=[];let r=0;const a=a=>{const l=r;r=a;const c=e[l],u=(c instanceof lt?c.getProvidedColumnGroup():c).getOriginalParent();if(null==u){for(let t=l;t<a;t++)s.push(e[t]);return}const h=this.createColumnGroup(u,t,n,i);for(let t=l;t<a;t++)h.addChild(e[t]);o.push(h)};for(let t=1;t<e.length;t++){const i=e[t],n=(i instanceof lt?i.getProvidedColumnGroup():i).getOriginalParent(),s=e[r];n!==(s instanceof lt?s.getProvidedColumnGroup():s).getOriginalParent()&&a(t)}r<e.length&&a(e.length)}return this.setupParentsIntoColumns(s,null),s}createColumnGroup(e,t,i,r){const n=e.getGroupId(),s=t.getInstanceIdForKey(n);let o=i[lt.createUniqueId(n,s)];return o&&o.getProvidedColumnGroup()!==e&&(o=null),y(o)?o.reset():(o=new lt(e,n,s,r),this.context.createBean(o)),o}mapOldGroupsById(e){const t={},i=e=>{e.forEach(e=>{if(e instanceof lt){const r=e;t[e.getUniqueId()]=r,i(r.getChildren())}})};return e&&i(e),t}setupParentsIntoColumns(e,t){e.forEach(e=>{if(e.setParent(t),e instanceof lt){const t=e;this.setupParentsIntoColumns(t.getChildren(),t)}})}};Pt=g([ue("displayedGroupCreator")],Pt);var xt={enableBrowserTooltips:!0,tooltipTrigger:!0,tooltipMouseTrack:!0,tooltipShowMode:!0,tooltipInteraction:!0,defaultColGroupDef:!0,suppressAutoSize:!0,skipHeaderOnAutoSize:!0,autoSizeStrategy:!0,components:!0,stopEditingWhenCellsLoseFocus:!0,undoRedoCellEditing:!0,undoRedoCellEditingLimit:!0,excelStyles:!0,cacheQuickFilter:!0,excludeHiddenColumnsFromQuickFilter:!0,advancedFilterModel:!0,customChartThemes:!0,chartThemeOverrides:!0,enableChartToolPanelsButton:!0,suppressChartToolPanelsButton:!0,chartToolPanelsDef:!0,loadingCellRendererSelector:!0,localeText:!0,keepDetailRows:!0,keepDetailRowsCount:!0,detailRowHeight:!0,detailRowAutoHeight:!0,tabIndex:!0,valueCache:!0,valueCacheNeverExpires:!0,enableCellExpressions:!0,suppressParentsInRowNodes:!0,suppressTouch:!0,suppressAsyncEvents:!0,suppressBrowserResizeObserver:!0,suppressPropertyNamesCheck:!0,debug:!0,loadingOverlayComponent:!0,suppressLoadingOverlay:!0,noRowsOverlayComponent:!0,paginationPageSizeSelector:!0,paginateChildRows:!0,pivotPanelShow:!0,pivotSuppressAutoColumn:!0,suppressExpandablePivotGroups:!0,aggFuncs:!0,suppressAggFuncInHeader:!0,suppressAggAtRootLevel:!0,removePivotHeaderRowWhenSingleValueColumn:!0,allowShowChangeAfterFilter:!0,ensureDomOrder:!0,enableRtl:!0,suppressColumnVirtualisation:!0,suppressMaxRenderedRowRestriction:!0,suppressRowVirtualisation:!0,rowDragText:!0,suppressGroupMaintainValueType:!0,groupLockGroupColumns:!0,rowGroupPanelSuppressSort:!0,suppressGroupRowsSticky:!0,rowModelType:!0,cacheOverflowSize:!0,infiniteInitialRowCount:!0,serverSideInitialRowCount:!0,suppressServerSideInfiniteScroll:!0,maxBlocksInCache:!0,maxConcurrentDatasourceRequests:!0,blockLoadDebounceMillis:!0,serverSideOnlyRefreshFilteredGroups:!0,serverSidePivotResultFieldSeparator:!0,viewportRowModelPageSize:!0,viewportRowModelBufferSize:!0,debounceVerticalScrollbar:!0,suppressAnimationFrame:!0,suppressPreventDefaultOnMouseWheel:!0,scrollbarWidth:!0,icons:!0,suppressRowTransform:!0,gridId:!0,functionsPassive:!0,enableGroupEdit:!0,initialState:!0,processUnpinnedColumns:!0,createChartContainer:!0,getLocaleText:!0,getRowId:!0,reactiveCustomComponents:!0,columnMenu:!0},Dt=class{};Dt.STRING_PROPERTIES=["rowSelection","overlayLoadingTemplate","overlayNoRowsTemplate","gridId","quickFilterText","rowModelType","editType","domLayout","clipboardDelimiter","rowGroupPanelShow","multiSortKey","pivotColumnGroupTotals","pivotRowTotals","pivotPanelShow","fillHandleDirection","groupDisplayType","treeDataDisplayType","colResizeDefault","tooltipTrigger","serverSidePivotResultFieldSeparator","columnMenu","tooltipShowMode","grandTotalRow"],Dt.OBJECT_PROPERTIES=["components","rowStyle","context","autoGroupColumnDef","localeText","icons","datasource","serverSideDatasource","viewportDatasource","groupRowRendererParams","aggFuncs","fullWidthCellRendererParams","defaultColGroupDef","defaultColDef","defaultCsvExportParams","defaultExcelExportParams","columnTypes","rowClassRules","detailCellRendererParams","loadingCellRendererParams","loadingOverlayComponentParams","noRowsOverlayComponentParams","popupParent","statusBar","sideBar","chartThemeOverrides","customChartThemes","chartToolPanelsDef","dataTypeDefinitions","advancedFilterModel","advancedFilterParent","advancedFilterBuilderParams","initialState","autoSizeStrategy"],Dt.ARRAY_PROPERTIES=["sortingOrder","alignedGrids","rowData","columnDefs","excelStyles","pinnedTopRowData","pinnedBottomRowData","chartThemes","rowClass","paginationPageSizeSelector"],Dt.NUMBER_PROPERTIES=["rowHeight","detailRowHeight","rowBuffer","headerHeight","groupHeaderHeight","groupLockGroupColumns","floatingFiltersHeight","pivotHeaderHeight","pivotGroupHeaderHeight","groupDefaultExpanded","pivotDefaultExpanded","viewportRowModelPageSize","viewportRowModelBufferSize","autoSizePadding","maxBlocksInCache","maxConcurrentDatasourceRequests","tooltipShowDelay","tooltipHideDelay","cacheOverflowSize","paginationPageSize","cacheBlockSize","infiniteInitialRowCount","serverSideInitialRowCount","scrollbarWidth","asyncTransactionWaitMillis","blockLoadDebounceMillis","keepDetailRowsCount","undoRedoCellEditingLimit","cellFlashDelay","cellFadeDelay","cellFlashDuration","cellFadeDuration","tabIndex","pivotMaxGeneratedColumns"],Dt.BOOLEAN_PROPERTIES=["suppressMakeColumnVisibleAfterUnGroup","suppressRowClickSelection","suppressCellFocus","suppressHeaderFocus","suppressHorizontalScroll","groupSelectsChildren","alwaysShowHorizontalScroll","alwaysShowVerticalScroll","debug","enableBrowserTooltips","enableCellExpressions","groupIncludeTotalFooter","groupSuppressBlankHeader","suppressMenuHide","suppressRowDeselection","unSortIcon","suppressMultiSort","alwaysMultiSort","singleClickEdit","suppressLoadingOverlay","suppressNoRowsOverlay","suppressAutoSize","skipHeaderOnAutoSize","suppressParentsInRowNodes","suppressColumnMoveAnimation","suppressMovableColumns","suppressFieldDotNotation","enableRangeSelection","enableRangeHandle","enableFillHandle","suppressClearOnFillReduction","deltaSort","suppressTouch","suppressAsyncEvents","allowContextMenuWithControlKey","suppressContextMenu","enableCellChangeFlash","suppressDragLeaveHidesColumns","suppressRowGroupHidesColumns","suppressMiddleClickScrolls","suppressPreventDefaultOnMouseWheel","suppressCopyRowsToClipboard","copyHeadersToClipboard","copyGroupHeadersToClipboard","pivotMode","suppressAggFuncInHeader","suppressColumnVirtualisation","alwaysAggregateAtRootLevel","suppressAggAtRootLevel","suppressFocusAfterRefresh","functionsPassive","functionsReadOnly","animateRows","groupSelectsFiltered","groupRemoveSingleChildren","groupRemoveLowestSingleChildren","enableRtl","suppressClickEdit","rowDragEntireRow","rowDragManaged","suppressRowDrag","suppressMoveWhenRowDragging","rowDragMultiRow","enableGroupEdit","embedFullWidthRows","suppressPaginationPanel","groupHideOpenParents","groupAllowUnbalanced","pagination","paginationAutoPageSize","suppressScrollOnNewData","suppressScrollWhenPopupsAreOpen","purgeClosedRowNodes","cacheQuickFilter","includeHiddenColumnsInQuickFilter","excludeHiddenColumnsFromQuickFilter","ensureDomOrder","accentedSort","suppressChangeDetection","valueCache","valueCacheNeverExpires","aggregateOnlyChangedColumns","suppressAnimationFrame","suppressExcelExport","suppressCsvExport","includeHiddenColumnsInAdvancedFilter","suppressMultiRangeSelection","enterMovesDown","enterMovesDownAfterEdit","enterNavigatesVerticallyAfterEdit","enterNavigatesVertically","suppressPropertyNamesCheck","rowMultiSelectWithClick","suppressRowHoverHighlight","suppressRowTransform","suppressClipboardPaste","suppressLastEmptyLineOnPaste","enableCharts","enableChartToolPanelsButton","suppressChartToolPanelsButton","suppressMaintainUnsortedOrder","enableCellTextSelection","suppressBrowserResizeObserver","suppressMaxRenderedRowRestriction","excludeChildrenWhenTreeDataFiltering","tooltipMouseTrack","tooltipInteraction","keepDetailRows","paginateChildRows","preventDefaultOnContextMenu","undoRedoCellEditing","allowDragFromColumnsToolPanel","pivotSuppressAutoColumn","suppressExpandablePivotGroups","debounceVerticalScrollbar","detailRowAutoHeight","serverSideFilterAllLevels","serverSideSortAllLevels","serverSideEnableClientSideSort","serverSideOnlyRefreshFilteredGroups","serverSideSortOnServer","serverSideFilterOnServer","suppressAggFilteredOnly","showOpenedGroup","suppressClipboardApi","suppressModelUpdateAfterUpdateTransaction","stopEditingWhenCellsLoseFocus","maintainColumnOrder","groupMaintainOrder","columnHoverHighlight","readOnlyEdit","suppressRowVirtualisation","enableCellEditingOnBackspace","resetRowDataOnUpdate","removePivotHeaderRowWhenSingleValueColumn","suppressCopySingleCellRanges","suppressGroupRowsSticky","suppressCutToClipboard","suppressServerSideInfiniteScroll","rowGroupPanelSuppressSort","allowShowChangeAfterFilter","enableAdvancedFilter","masterDetail","treeData","suppressGroupMaintainValueType","reactiveCustomComponents","applyQuickFilterBeforePivotOrAgg","suppressServerSideFullWidthLoadingRow","suppressAdvancedFilterEval"],Dt.OTHER_PROPERTIES=["suppressStickyTotalRow"],Dt.FUNCTIONAL_PROPERTIES=["doesExternalFilterPass","processPivotResultColDef","processPivotResultColGroupDef","getBusinessKeyForNode","isRowSelectable","rowDragText","groupRowRenderer","fullWidthCellRenderer","loadingCellRenderer","loadingOverlayComponent","noRowsOverlayComponent","detailCellRenderer","quickFilterParser","quickFilterMatcher"],Dt.CALLBACK_PROPERTIES=["getLocaleText","isExternalFilterPresent","getRowHeight","getRowClass","getRowStyle","getContextMenuItems","getMainMenuItems","processRowPostCreate","processCellForClipboard","getGroupRowAgg","isFullWidthRow","sendToClipboard","navigateToNextHeader","tabToNextHeader","navigateToNextCell","tabToNextCell","processCellFromClipboard","getDocument","postProcessPopup","getChildCount","getDataPath","isRowMaster","postSortRows","processHeaderForClipboard","processUnpinnedColumns","processGroupHeaderForClipboard","paginationNumberFormatter","processDataFromClipboard","getServerSideGroupKey","isServerSideGroup","createChartContainer","getChartToolbarItems","fillOperation","isApplyServerSideTransaction","getServerSideGroupLevelParams","isServerSideGroupOpenByDefault","isGroupOpenByDefault","initialGroupOrderComparator","groupIncludeFooter","loadingCellRendererSelector","getRowId","groupAggFiltering","chartMenuItems","groupTotalRow"],Dt.FUNCTION_PROPERTIES=[...Dt.FUNCTIONAL_PROPERTIES,...Dt.CALLBACK_PROPERTIES],Dt.ALL_PROPERTIES=[...Dt.ARRAY_PROPERTIES,...Dt.OBJECT_PROPERTIES,...Dt.STRING_PROPERTIES,...Dt.NUMBER_PROPERTIES,...Dt.FUNCTION_PROPERTIES,...Dt.BOOLEAN_PROPERTIES,...Dt.OTHER_PROPERTIES];var It=Dt,Lt=class e{static getCallbackForEvent(e){return!e||e.length<2?e:"on"+e[0].toUpperCase()+e.substring(1)}static getGridOptionKeys(){return this.ALL_PROPERTIES_AND_CALLBACKS}static combineAttributesAndGridOptions(t,i){"object"!=typeof t&&(t={});const r=h({},t);return e.getGridOptionKeys().forEach(t=>{const n=i[t];void 0!==n&&n!==e.VUE_OMITTED_PROPERTY&&(r[t]=n)}),r}static processOnChange(t,i,r){if(!t)return;const n={};let s=!1;if(Object.keys(t).filter(t=>e.ALL_PROPERTIES_AND_CALLBACKS_SET.has(t)).forEach(e=>{n[e]=t[e],s=!0}),!s)return;i.__internalUpdateGridOptions(n,!0);const o={type:ct.EVENT_COMPONENT_STATE_CHANGED};I(n,(e,t)=>{o[e]=t}),i.dispatchEvent(o)}};Lt.EVENTS=_(ct),Lt.VUE_OMITTED_PROPERTY="AG-VUE-OMITTED-PROPERTY",Lt.EXCLUDED_INTERNAL_EVENTS=[ct.EVENT_SCROLLBAR_WIDTH_CHANGED,ct.EVENT_CHECKBOX_CHANGED,ct.EVENT_HEIGHT_SCALE_CHANGED,ct.EVENT_BODY_HEIGHT_CHANGED,ct.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,ct.EVENT_SCROLL_VISIBILITY_CHANGED,ct.EVENT_COLUMN_HOVER_CHANGED,ct.EVENT_FLASH_CELLS,ct.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED,ct.EVENT_DISPLAYED_ROWS_CHANGED,ct.EVENT_LEFT_PINNED_WIDTH_CHANGED,ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED,ct.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,ct.EVENT_STORE_UPDATED,ct.EVENT_COLUMN_PANEL_ITEM_DRAG_START,ct.EVENT_COLUMN_PANEL_ITEM_DRAG_END,ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_START,ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_END,ct.EVENT_FULL_WIDTH_ROW_FOCUSED,ct.EVENT_HEADER_HEIGHT_CHANGED,ct.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,ct.EVENT_CELL_FOCUS_CLEARED,ct.EVENT_GRID_STYLES_CHANGED,ct.EVENT_FILTER_DESTROYED,ct.EVENT_ROW_DATA_UPDATE_STARTED,ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,ct.EVENT_DATA_TYPES_INFERRED,ct.EVENT_FIELD_VALUE_CHANGED,ct.EVENT_FIELD_PICKER_VALUE_SELECTED,ct.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED,ct.EVENT_SUPPRESS_MENU_HIDE_CHANGED,ct.EVENT_SUPPRESS_FIELD_DOT_NOTATION,ct.EVENT_ROW_COUNT_READY,ct.EVENT_SIDE_BAR_UPDATED],Lt.PUBLIC_EVENTS=Lt.EVENTS.filter(e=>!Be(Lt.EXCLUDED_INTERNAL_EVENTS,e)),Lt.EVENT_CALLBACKS=Lt.EVENTS.map(e=>Lt.getCallbackForEvent(e)),Lt.BOOLEAN_PROPERTIES=It.BOOLEAN_PROPERTIES,Lt.ALL_PROPERTIES=It.ALL_PROPERTIES,Lt.ALL_PROPERTIES_AND_CALLBACKS=[...Lt.ALL_PROPERTIES,...Lt.EVENT_CALLBACKS],Lt.ALL_PROPERTIES_AND_CALLBACKS_SET=new Set(Lt.ALL_PROPERTIES_AND_CALLBACKS);var Nt=Lt,Ot=class extends nt{constructor(){super(...arguments),this.componentsMappedByName={}}setupComponents(e){e&&e.forEach(e=>this.addComponent(e))}addComponent(e){const t=e.componentName.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase().toUpperCase();this.componentsMappedByName[t]=e.componentClass}getComponentClass(e){return this.componentsMappedByName[e]}};Ot=g([ue("agStackComponentsRegistry")],Ot);var Ft={};function kt(e,t,i){null==i||"string"==typeof i&&""==i?Vt(e,t):Gt(e,t,i)}function Gt(e,t,i){e.setAttribute(Ht(t),i.toString())}function Vt(e,t){e.removeAttribute(Ht(t))}function Ht(e){return`aria-${e}`}function Bt(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function zt(e){let t;return t="asc"===e?"ascending":"desc"===e?"descending":"mixed"===e?"other":"none",t}function Ut(e){return parseInt(e.getAttribute("aria-level"),10)}function Wt(e){return parseInt(e.getAttribute("aria-posinset"),10)}function jt(e){return e.getAttribute("aria-label")}function Kt(e,t){kt(e,"label",t)}function $t(e,t){kt(e,"labelledby",t)}function qt(e,t){kt(e,"describedby",t)}function Yt(e,t){kt(e,"live",t)}function Qt(e,t){kt(e,"atomic",t)}function Xt(e,t){kt(e,"relevant",t)}function Zt(e,t){kt(e,"level",t)}function Jt(e,t){kt(e,"disabled",t)}function ei(e,t){kt(e,"hidden",t)}function ti(e,t){kt(e,"activedescendant",t)}function ii(e,t){Gt(e,"expanded",t)}function ri(e){Vt(e,"expanded")}function ni(e,t){Gt(e,"setsize",t)}function si(e,t){Gt(e,"posinset",t)}function oi(e,t){Gt(e,"multiselectable",t)}function ai(e,t){Gt(e,"rowcount",t)}function li(e,t){Gt(e,"rowindex",t)}function ci(e,t){Gt(e,"colcount",t)}function ui(e,t){Gt(e,"colindex",t)}function hi(e,t){Gt(e,"colspan",t)}function di(e,t){Gt(e,"sort",t)}function pi(e){Vt(e,"sort")}function gi(e,t){kt(e,"selected",t)}function fi(e,t){Gt(e,"checked",void 0===t?"mixed":t)}function mi(e,t){kt(e,"controls",t.id),$t(t,e.id)}function vi(e,t){return void 0===t?e("ariaIndeterminate","indeterminate"):!0===t?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}p(Ft,{getAriaCheckboxStateName:()=>vi,getAriaLabel:()=>jt,getAriaLevel:()=>Ut,getAriaPosInSet:()=>Wt,getAriaSortState:()=>zt,removeAriaExpanded:()=>ri,removeAriaSort:()=>pi,setAriaActiveDescendant:()=>ti,setAriaAtomic:()=>Qt,setAriaChecked:()=>fi,setAriaColCount:()=>ci,setAriaColIndex:()=>ui,setAriaColSpan:()=>hi,setAriaControls:()=>mi,setAriaDescribedBy:()=>qt,setAriaDisabled:()=>Jt,setAriaExpanded:()=>ii,setAriaHidden:()=>ei,setAriaLabel:()=>Kt,setAriaLabelledBy:()=>$t,setAriaLevel:()=>Zt,setAriaLive:()=>Yt,setAriaMultiSelectable:()=>oi,setAriaPosInSet:()=>si,setAriaRelevant:()=>Xt,setAriaRole:()=>Bt,setAriaRowCount:()=>ai,setAriaRowIndex:()=>li,setAriaSelected:()=>gi,setAriaSetSize:()=>ni,setAriaSort:()=>di});var Ci,yi,wi,Si,bi,Ei,Ai,Ti,Mi={};function Ri(){return void 0===Ci&&(Ci=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),Ci}function _i(){if(void 0===yi)if(Ri()){const e=navigator.userAgent.match(/version\/(\d+)/i);e&&(yi=null!=e[1]?parseFloat(e[1]):0)}else yi=0;return yi}function Pi(){if(void 0===wi){const e=window;wi=!!e.chrome&&(!!e.chrome.webstore||!!e.chrome.runtime)||/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor)}return wi}function xi(){return void 0===Si&&(Si=/(firefox)/i.test(navigator.userAgent)),Si}function Di(){return void 0===bi&&(bi=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),bi}function Ii(){return void 0===Ei&&(Ei=/iPad|iPhone|iPod/.test(navigator.platform)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1),Ei}function Li(){return!Ri()||_i()>=15}function Ni(e){if(!e)return null;const t=e.tabIndex,i=e.getAttribute("tabIndex");return-1!==t||null!==i&&(""!==i||xi())?t.toString():null}function Oi(){if(!document.body)return-1;let e=1e6;const t=navigator.userAgent.toLowerCase().match(/firefox/)?6e6:1e9,i=document.createElement("div");for(document.body.appendChild(i);;){const r=2*e;if(i.style.height=r+"px",r>t||i.clientHeight!==r)break;e=r}return document.body.removeChild(i),e}function Fi(){var e,t,i;return null!=(i=null==(e=document.body)?void 0:e.clientWidth)?i:window.innerHeight||(null==(t=document.documentElement)?void 0:t.clientWidth)||-1}function ki(){var e,t,i;return null!=(i=null==(e=document.body)?void 0:e.clientHeight)?i:window.innerHeight||(null==(t=document.documentElement)?void 0:t.clientHeight)||-1}function Gi(){return null==Ti&&Vi(),Ti}function Vi(){const e=document.body,t=document.createElement("div");t.style.width=t.style.height="100px",t.style.opacity="0",t.style.overflow="scroll",t.style.msOverflowStyle="scrollbar",t.style.position="absolute",e.appendChild(t);let i=t.offsetWidth-t.clientWidth;0===i&&0===t.clientWidth&&(i=null),t.parentNode&&t.parentNode.removeChild(t),null!=i&&(Ti=i,Ai=0===i)}function Hi(){return null==Ai&&Vi(),Ai}p(Mi,{browserSupportsPreventScroll:()=>Li,getBodyHeight:()=>ki,getBodyWidth:()=>Fi,getMaxDivHeight:()=>Oi,getSafariVersion:()=>_i,getScrollbarWidth:()=>Gi,getTabIndex:()=>Ni,isBrowserChrome:()=>Pi,isBrowserFirefox:()=>xi,isBrowserSafari:()=>Ri,isIOSUserAgent:()=>Ii,isInvisibleScrollbar:()=>Hi,isMacOsUserAgent:()=>Di});var Bi={};p(Bi,{dateToFormattedString:()=>Zi,parseDateTimeFromString:()=>Ji,serialiseDate:()=>Qi});var zi={};function Ui(e,t){return e.toString().padStart(t,"0")}function Wi(e,t){const i=[];for(let r=e;r<=t;r++)i.push(r);return i}function ji(e){return"string"==typeof e&&(e=parseInt(e,10)),"number"==typeof e?Math.floor(e):null}function Ki(e,t){let i="";for(let r=0;r<t;r++)i+=String.fromCharCode(255&e),e>>>=8;return i}function $i(e,t,i){return"number"!=typeof e?"":qi(Math.round(100*e)/100,t,i)}function qi(e,t,i){return"number"!=typeof e?"":e.toString().replace(".",i).replace(/(\d)(?=(\d{3})+(?!\d))/g,`$1${t}`)}function Yi(e){return null==e?null:e.reduce((e,t)=>e+t,0)}function Qi(e,t=!0,i="-"){if(!e)return null;let r=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(e=>Ui(e,2)).join(i);return t&&(r+=" "+[e.getHours(),e.getMinutes(),e.getSeconds()].map(e=>Ui(e,2)).join(":")),r}p(zi,{cleanNumber:()=>ji,createArrayOfNumbers:()=>Wi,decToHex:()=>Ki,formatNumberCommas:()=>qi,formatNumberTwoDecimalPlacesAndCommas:()=>$i,padStartWidthZeros:()=>Ui,sum:()=>Yi});var Xi=e=>{if(e>3&&e<21)return"th";switch(e%10){case 1:return"st";case 2:return"nd";case 3:return"rd"}return"th"};function Zi(e,t="YYYY-MM-DD"){const i=Ui(e.getFullYear(),4),r=["January","February","March","April","May","June","July","August","September","October","November","December"],n=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],s={YYYY:()=>i.slice(i.length-4,i.length),YY:()=>i.slice(i.length-2,i.length),Y:()=>`${e.getFullYear()}`,MMMM:()=>r[e.getMonth()],MMM:()=>r[e.getMonth()].slice(0,3),MM:()=>Ui(e.getMonth()+1,2),Mo:()=>`${e.getMonth()+1}${Xi(e.getMonth()+1)}`,M:()=>`${e.getMonth()+1}`,Do:()=>`${e.getDate()}${Xi(e.getDate())}`,DD:()=>Ui(e.getDate(),2),D:()=>`${e.getDate()}`,dddd:()=>n[e.getDay()],ddd:()=>n[e.getDay()].slice(0,3),dd:()=>n[e.getDay()].slice(0,2),do:()=>`${e.getDay()}${Xi(e.getDay())}`,d:()=>`${e.getDay()}`},o=new RegExp(Object.keys(s).join("|"),"g");return t.replace(o,e=>e in s?s[e]():e)}function Ji(e){if(!e)return null;const[t,i]=e.split(" ");if(!t)return null;const r=t.split("-").map(e=>parseInt(e,10));if(3!==r.filter(e=>!isNaN(e)).length)return null;const[n,s,o]=r,a=new Date(n,s-1,o);if(a.getFullYear()!==n||a.getMonth()!==s-1||a.getDate()!==o)return null;if(!i||"00:00:00"===i)return a;const[l,c,u]=i.split(":").map(e=>parseInt(e,10));return l>=0&&l<24&&a.setHours(l),c>=0&&c<60&&a.setMinutes(c),u>=0&&u<60&&a.setSeconds(u),a}var er,tr={};function ir(e,t,i){const r=e.parentElement;let n=r&&r.firstChild;for(;n;)t&&n.classList.toggle(t,n===e),i&&n.classList.toggle(i,n!==e),n=n.nextSibling}p(tr,{FOCUSABLE_EXCLUDE:()=>nr,FOCUSABLE_SELECTOR:()=>rr,addOrRemoveAttribute:()=>Gr,addStylesToElement:()=>Rr,bindCellRendererToHtmlElement:()=>Hr,clearElement:()=>yr,copyNodeList:()=>Fr,ensureDomOrder:()=>Ar,formatSize:()=>Nr,getAbsoluteHeight:()=>pr,getAbsoluteWidth:()=>gr,getElementRectWithOffset:()=>fr,getElementSize:()=>ur,getInnerHeight:()=>hr,getInnerWidth:()=>dr,getScrollLeft:()=>vr,insertWithDomOrder:()=>Mr,isElementChildOfClass:()=>cr,isFocusableFormField:()=>sr,isHorizontalScrollShowing:()=>_r,isInDOM:()=>Sr,isNodeOrElement:()=>Or,isRtlNegativeScroll:()=>mr,isVerticalScrollShowing:()=>Pr,isVisible:()=>br,iterateNamedNodeMap:()=>kr,loadTemplate:()=>Er,nodeListForEach:()=>Vr,radioCssClass:()=>ir,removeFromParent:()=>wr,setDisabled:()=>lr,setDisplayed:()=>or,setDomChildOrder:()=>Tr,setElementHeight:()=>Ir,setElementWidth:()=>xr,setFixedHeight:()=>Lr,setFixedWidth:()=>Dr,setScrollLeft:()=>Cr,setVisible:()=>ar});var rr="[tabindex], input, select, button, textarea, [href]",nr="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function sr(e){const t=Element.prototype.matches||Element.prototype.msMatchesSelector,i=t.call(e,"input, select, button, textarea"),r=t.call(e,nr),n=br(e);return i&&!r&&n}function or(e,t,i={}){const{skipAriaHidden:r}=i;e.classList.toggle("ag-hidden",!t),r||ei(e,!t)}function ar(e,t,i={}){const{skipAriaHidden:r}=i;e.classList.toggle("ag-invisible",!t),r||ei(e,!t)}function lr(e,t){const i="disabled",r=t?e=>e.setAttribute(i,""):e=>e.removeAttribute(i);r(e),Vr(e.querySelectorAll("input"),e=>r(e))}function cr(e,t,i){let r=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,"number"==typeof i){if(++r>i)break}else if(e===i)break}return!1}function ur(e){const{height:t,width:i,borderTopWidth:r,borderRightWidth:n,borderBottomWidth:s,borderLeftWidth:o,paddingTop:a,paddingRight:l,paddingBottom:c,paddingLeft:u,marginTop:h,marginRight:d,marginBottom:p,marginLeft:g,boxSizing:f}=window.getComputedStyle(e);return{height:parseFloat(t||"0"),width:parseFloat(i||"0"),borderTopWidth:parseFloat(r||"0"),borderRightWidth:parseFloat(n||"0"),borderBottomWidth:parseFloat(s||"0"),borderLeftWidth:parseFloat(o||"0"),paddingTop:parseFloat(a||"0"),paddingRight:parseFloat(l||"0"),paddingBottom:parseFloat(c||"0"),paddingLeft:parseFloat(u||"0"),marginTop:parseFloat(h||"0"),marginRight:parseFloat(d||"0"),marginBottom:parseFloat(p||"0"),marginLeft:parseFloat(g||"0"),boxSizing:f}}function hr(e){const t=ur(e);return"border-box"===t.boxSizing?t.height-t.paddingTop-t.paddingBottom:t.height}function dr(e){const t=ur(e);return"border-box"===t.boxSizing?t.width-t.paddingLeft-t.paddingRight:t.width}function pr(e){const t=ur(e),i=t.marginBottom+t.marginTop;return Math.ceil(e.offsetHeight+i)}function gr(e){const t=ur(e),i=t.marginLeft+t.marginRight;return Math.ceil(e.offsetWidth+i)}function fr(e){const t=e.getBoundingClientRect(),{borderTopWidth:i,borderLeftWidth:r,borderRightWidth:n,borderBottomWidth:s}=ur(e);return{top:t.top+(i||0),left:t.left+(r||0),right:t.right+(n||0),bottom:t.bottom+(s||0)}}function mr(){if("boolean"==typeof er)return er;const e=document.createElement("div");return e.style.direction="rtl",e.style.width="1px",e.style.height="1px",e.style.position="fixed",e.style.top="0px",e.style.overflow="hidden",e.dir="rtl",e.innerHTML='<div style="width: 2px">\n            <span style="display: inline-block; width: 1px"></span>\n            <span style="display: inline-block; width: 1px"></span>\n        </div>',document.body.appendChild(e),e.scrollLeft=1,er=0===Math.floor(e.scrollLeft),document.body.removeChild(e),er}function vr(e,t){let i=e.scrollLeft;return t&&(i=Math.abs(i),Pi()&&!mr()&&(i=e.scrollWidth-e.clientWidth-i)),i}function Cr(e,t,i){i&&(mr()?t*=-1:(Ri()||Pi())&&(t=e.scrollWidth-e.clientWidth-t)),e.scrollLeft=t}function yr(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}function wr(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function Sr(e){return!!e.offsetParent}function br(e){const t=e;return t.checkVisibility?t.checkVisibility({checkVisibilityCSS:!0}):!(!Sr(e)||"visible"!==window.getComputedStyle(e).visibility)}function Er(e){const t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function Ar(e,t,i){i&&i.nextSibling===t||(i?i.nextSibling?e.insertBefore(t,i.nextSibling):e.appendChild(t):e.firstChild&&e.firstChild!==t&&e.insertAdjacentElement("afterbegin",t))}function Tr(e,t){for(let i=0;i<t.length;i++){const r=t[i],n=e.children[i];n!==r&&e.insertBefore(r,n)}}function Mr(e,t,i){i?i.insertAdjacentElement("afterend",t):e.firstChild?e.insertAdjacentElement("afterbegin",t):e.appendChild(t)}function Rr(e,t){if(t)for(const[i,r]of Object.entries(t)){if(!i||!i.length||null==r)continue;const t=St(i),n=r.toString(),s=n.replace(/\s*!important/g,""),o=s.length!=n.length?"important":void 0;e.style.setProperty(t,s,o)}}function _r(e){return e.clientWidth<e.scrollWidth}function Pr(e){return e.clientHeight<e.scrollHeight}function xr(e,t){"flex"===t?(e.style.removeProperty("width"),e.style.removeProperty("minWidth"),e.style.removeProperty("maxWidth"),e.style.flex="1 1 auto"):Dr(e,t)}function Dr(e,t){t=Nr(t),e.style.width=t.toString(),e.style.maxWidth=t.toString(),e.style.minWidth=t.toString()}function Ir(e,t){"flex"===t?(e.style.removeProperty("height"),e.style.removeProperty("minHeight"),e.style.removeProperty("maxHeight"),e.style.flex="1 1 auto"):Lr(e,t)}function Lr(e,t){t=Nr(t),e.style.height=t.toString(),e.style.maxHeight=t.toString(),e.style.minHeight=t.toString()}function Nr(e){return"number"==typeof e?`${e}px`:e}function Or(e){return e instanceof Node||e instanceof HTMLElement}function Fr(e){if(null==e)return[];const t=[];return Vr(e,e=>t.push(e)),t}function kr(e,t){if(e)for(let i=0;i<e.length;i++){const r=e[i];t(r.name,r.value)}}function Gr(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i.toString())}function Vr(e,t){if(null!=e)for(let i=0;i<e.length;i++)t(e[i])}function Hr(e,t){e.then(e=>{const i=e.getGui();null!=i&&("object"==typeof i?t.appendChild(i):t.innerHTML=i)})}var Br={};function zr(e,t,i){const r={},n=e.filter(e=>!t.some(t=>t===e));return n.length>0&&n.forEach(e=>r[e]=Ur(e,i).values),r}function Ur(e,t,i,r){let n=t.map((t,i)=>({value:t,relevance:Wr(e.toLowerCase(),t.toLocaleLowerCase()),idx:i}));if(n.sort((e,t)=>t.relevance-e.relevance),i&&(n=n.filter(e=>0!==e.relevance)),n.length>0&&r&&r>0){const e=n[0].relevance*r;n=n.filter(t=>e-t.relevance<0)}const s=[],o=[];for(const e of n)s.push(e.value),o.push(e.idx);return{values:s,indices:o}}function Wr(e,t){const i=e.replace(/\s/g,""),r=t.replace(/\s/g,"");let n=0,s=-1;for(let e=0;e<i.length;e++){const t=r.indexOf(i[e],s+1);-1!==t&&(s=t,n+=100-100*s/1e4*100)}return n}p(Br,{fuzzyCheckStrings:()=>zr,fuzzySuggestions:()=>Ur});var jr={};p(jr,{createIcon:()=>$r,createIconNoSpan:()=>qr,iconNameClassMap:()=>Kr});var Kr={columnGroupOpened:"expanded",columnGroupClosed:"contracted",columnSelectClosed:"tree-closed",columnSelectOpen:"tree-open",columnSelectIndeterminate:"tree-indeterminate",columnMovePin:"pin",columnMoveHide:"eye-slash",columnMoveMove:"arrows",columnMoveLeft:"left",columnMoveRight:"right",columnMoveGroup:"group",columnMoveValue:"aggregation",columnMovePivot:"pivot",dropNotAllowed:"not-allowed",groupContracted:"tree-closed",groupExpanded:"tree-open",setFilterGroupClosed:"tree-closed",setFilterGroupOpen:"tree-open",setFilterGroupIndeterminate:"tree-indeterminate",chart:"chart",close:"cross",cancel:"cancel",check:"tick",first:"first",previous:"previous",next:"next",last:"last",linked:"linked",unlinked:"unlinked",colorPicker:"color-picker",groupLoading:"loading",menu:"menu",menuAlt:"menu-alt",filter:"filter",columns:"columns",maximize:"maximize",minimize:"minimize",menuPin:"pin",menuValue:"aggregation",menuAddRowGroup:"group",menuRemoveRowGroup:"group",clipboardCopy:"copy",clipboardCut:"cut",clipboardPaste:"paste",pivotPanel:"pivot",rowGroupPanel:"group",valuePanel:"aggregation",columnDrag:"grip",rowDrag:"grip",save:"save",csvExport:"csv",excelExport:"excel",smallDown:"small-down",smallLeft:"small-left",smallRight:"small-right",smallUp:"small-up",sortAscending:"asc",sortDescending:"desc",sortUnSort:"none",advancedFilterBuilder:"group",advancedFilterBuilderDrag:"grip",advancedFilterBuilderInvalid:"not-allowed",advancedFilterBuilderMoveUp:"up",advancedFilterBuilderMoveDown:"down",advancedFilterBuilderAdd:"plus",advancedFilterBuilderRemove:"minus",chartsMenuEdit:"chart",chartsMenuAdvancedSettings:"settings",chartsMenuAdd:"plus"};function $r(e,t,i){const r=qr(e,t,i);if(r){const{className:e}=r;if("string"==typeof e&&e.indexOf("ag-icon")>-1||"object"==typeof e&&e["ag-icon"])return r}const n=document.createElement("span");return n.appendChild(r),n}function qr(e,t,i,r){let n=null;const s=i&&i.getColDef().icons;if(s&&(n=s[e]),t&&!n){const i=t.get("icons");i&&(n=i[e])}if(!n){const t=document.createElement("span");let i=Kr[e];return i||(r?i=e:(console.warn(`AG Grid: Did not find icon ${e}`),i="")),t.setAttribute("class",`ag-icon ag-icon-${i}`),t.setAttribute("unselectable","on"),Bt(t,"presentation"),t}{let e;if("function"==typeof n)e=n();else{if("string"!=typeof n)throw new Error("icon from grid options needs to be a string or a function");e=n}if("string"==typeof e)return Er(e);if(Or(e))return e;console.warn("AG Grid: iconRenderer should return back a string or a dom object")}}var Yr={};p(Yr,{isDeleteKey:()=>tn,isEventFromPrintableCharacter:()=>Xr,isUserSuppressingHeaderKeyboardEvent:()=>Jr,isUserSuppressingKeyboardEvent:()=>Zr,normaliseQwertyAzerty:()=>en});var Qr=class{};function Xr(e){return!(e.altKey||e.ctrlKey||e.metaKey)&&1===e.key.length}function Zr(e,t,i,r,n){const s=r?r.getColDef().suppressKeyboardEvent:void 0;if(!s)return!1;const o=e.addGridCommonParams({event:t,editing:n,column:r,node:i,data:i.data,colDef:r.getColDef()});return!(!s||!s(o))}function Jr(e,t,i,r){const n=r.getDefinition(),s=n&&n.suppressHeaderKeyboardEvent;return!!y(s)&&!!s(e.addGridCommonParams({colDef:n,column:r,headerRowIndex:i,event:t}))}function en(e){const{keyCode:t}=e;let i;switch(t){case 65:i=Qr.A;break;case 67:i=Qr.C;break;case 86:i=Qr.V;break;case 68:i=Qr.D;break;case 90:i=Qr.Z;break;case 89:i=Qr.Y;break;default:i=e.code}return i}function tn(e,t=!1){return e===Qr.DELETE||!t&&e===Qr.BACKSPACE&&Di()}Qr.BACKSPACE="Backspace",Qr.TAB="Tab",Qr.ENTER="Enter",Qr.ESCAPE="Escape",Qr.SPACE=" ",Qr.LEFT="ArrowLeft",Qr.UP="ArrowUp",Qr.RIGHT="ArrowRight",Qr.DOWN="ArrowDown",Qr.DELETE="Delete",Qr.F2="F2",Qr.PAGE_UP="PageUp",Qr.PAGE_DOWN="PageDown",Qr.PAGE_HOME="Home",Qr.PAGE_END="End",Qr.A="KeyA",Qr.C="KeyC",Qr.D="KeyD",Qr.V="KeyV",Qr.X="KeyX",Qr.Y="KeyY",Qr.Z="KeyZ";var rn={};function nn(e,t,i){if(0===i)return!1;const r=Math.abs(e.clientX-t.clientX),n=Math.abs(e.clientY-t.clientY);return Math.max(r,n)<=i}p(rn,{areEventsNear:()=>nn});var sn={};function on(e,t){if(!e)return!1;const i=(e,i)=>{const r=t[e.id],n=t[i.id],s=void 0!==r,o=void 0!==n;return s&&o?r-n:s||o?s?1:-1:e.__objectId-i.__objectId};let r,n,s=!1;for(let t=0;t<e.length-1;t++)if(r=e[t],n=e[t+1],i(r,n)>0){s=!0;break}return!!s&&(e.sort(i),!0)}p(sn,{sortRowNodesByOrder:()=>on});var an={};function ln(e){const t=new Set;return e.forEach(e=>t.add(e)),t}p(an,{convertToSet:()=>ln});var cn=h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h({},Ft),Re),Mi),Bi),tr),Me),H),Br),v),jr),Yr),bt),rn),zi),x),sn),an),gt),un=class{constructor(e=0,t=1){this.nextValue=e,this.step=t}next(){const e=this.nextValue;return this.nextValue+=this.step,e}peek(){return this.nextValue}skip(e){this.nextValue+=e}},hn=(e=>(e[e.IN_PROGRESS=0]="IN_PROGRESS",e[e.RESOLVED=1]="RESOLVED",e))(hn||{}),dn=class e{constructor(e){this.status=0,this.resolution=null,this.waiters=[],e(e=>this.onDone(e),e=>this.onReject(e))}static all(t){return new e(e=>{let i=t.length;const r=new Array(i);t.forEach((t,n)=>{t.then(t=>{r[n]=t,i--,0===i&&e(r)})})})}static resolve(t=null){return new e(e=>e(t))}then(t){return new e(e=>{1===this.status?e(t(this.resolution)):this.waiters.push(i=>e(t(i)))})}resolveNow(e,t){return 1===this.status?t(this.resolution):e}onDone(e){this.status=1,this.resolution=e,this.waiters.forEach(t=>t(e))}onReject(e){console.warn("TBI")}},pn=class{constructor(){this.timestamp=(new Date).getTime()}print(e){const t=(new Date).getTime()-this.timestamp;console.info(`${e} = ${t}`),this.timestamp=(new Date).getTime()}},gn=class{constructor(e){this.cssClassStates={},this.getGui=e}addCssClass(e){const t=(e||"").split(" ");if(t.length>1)t.forEach(e=>this.addCssClass(e));else if(!0!==this.cssClassStates[e]&&e.length){const t=this.getGui();t&&t.classList.add(e),this.cssClassStates[e]=!0}}removeCssClass(e){const t=(e||"").split(" ");if(t.length>1)t.forEach(e=>this.removeCssClass(e));else if(!1!==this.cssClassStates[e]&&e.length){const t=this.getGui();t&&t.classList.remove(e),this.cssClassStates[e]=!1}}containsCssClass(e){const t=this.getGui();return!!t&&t.classList.contains(e)}addOrRemoveCssClass(e,t){if(e){if(e.indexOf(" ")>=0){const i=(e||"").split(" ");if(i.length>1)return void i.forEach(e=>this.addOrRemoveCssClass(e,t))}if(this.cssClassStates[e]!==t&&e.length){const i=this.getGui();i&&i.classList.toggle(e,t),this.cssClassStates[e]=t}}}},fn=class e extends nt{constructor(e,t,i,r){super(),this.parentComp=e,this.tooltipShowDelayOverride=t,this.tooltipHideDelayOverride=i,this.shouldDisplayTooltip=r,this.SHOW_QUICK_TOOLTIP_DIFF=1e3,this.FADE_OUT_TOOLTIP_TIMEOUT=1e3,this.INTERACTIVE_HIDE_DELAY=100,this.interactionEnabled=!1,this.isInteractingWithTooltip=!1,this.state=0,this.tooltipInstanceCount=0,this.tooltipMouseTrack=!1}postConstruct(){this.gos.get("tooltipInteraction")&&(this.interactionEnabled=!0),this.tooltipTrigger=this.getTooltipTrigger(),this.tooltipMouseTrack=this.gos.get("tooltipMouseTrack");const e=this.parentComp.getGui();0===this.tooltipTrigger&&(this.addManagedListener(e,"mouseenter",this.onMouseEnter.bind(this)),this.addManagedListener(e,"mouseleave",this.onMouseLeave.bind(this))),1===this.tooltipTrigger&&(this.addManagedListener(e,"focusin",this.onFocusIn.bind(this)),this.addManagedListener(e,"focusout",this.onFocusOut.bind(this))),this.addManagedListener(e,"mousemove",this.onMouseMove.bind(this)),this.interactionEnabled||(this.addManagedListener(e,"mousedown",this.onMouseDown.bind(this)),this.addManagedListener(e,"keydown",this.onKeyDown.bind(this)))}getGridOptionsTooltipDelay(e){const t=this.gos.get(e);return t<0&&U(`${e} should not be lower than 0`),Math.max(200,t)}getTooltipDelay(e){var t,i;return"show"===e?null!=(t=this.tooltipShowDelayOverride)?t:this.getGridOptionsTooltipDelay("tooltipShowDelay"):null!=(i=this.tooltipHideDelayOverride)?i:this.getGridOptionsTooltipDelay("tooltipHideDelay")}destroy(){this.setToDoNothing(),super.destroy()}getTooltipTrigger(){const e=this.gos.get("tooltipTrigger");return e&&"hover"!==e?1:0}onMouseEnter(t){this.interactionEnabled&&this.interactiveTooltipTimeoutId&&(this.unlockService(),this.startHideTimeout()),Ii()||(e.isLocked?this.showTooltipTimeoutId=window.setTimeout(()=>{this.prepareToShowTooltip(t)},this.INTERACTIVE_HIDE_DELAY):this.prepareToShowTooltip(t))}onMouseMove(e){this.lastMouseEvent&&(this.lastMouseEvent=e),this.tooltipMouseTrack&&2===this.state&&this.tooltipComp&&this.positionTooltip()}onMouseDown(){this.setToDoNothing()}onMouseLeave(){this.interactionEnabled?this.lockService():this.setToDoNothing()}onFocusIn(){this.prepareToShowTooltip()}onFocusOut(e){var t;const i=e.relatedTarget,r=this.parentComp.getGui(),n=null==(t=this.tooltipComp)?void 0:t.getGui();this.isInteractingWithTooltip||r.contains(i)||this.interactionEnabled&&(null==n?void 0:n.contains(i))||this.setToDoNothing()}onKeyDown(){this.setToDoNothing()}prepareToShowTooltip(t){if(0!=this.state||e.isLocked)return;let i=0;t&&(i=this.isLastTooltipHiddenRecently()?200:this.getTooltipDelay("show")),this.lastMouseEvent=t||null,this.showTooltipTimeoutId=window.setTimeout(this.showTooltip.bind(this),i),this.state=1}isLastTooltipHiddenRecently(){return(new Date).getTime()-e.lastTooltipHideTime<this.SHOW_QUICK_TOOLTIP_DIFF}setToDoNothing(){2===this.state&&this.hideTooltip(),this.onBodyScrollEventCallback&&(this.onBodyScrollEventCallback(),this.onBodyScrollEventCallback=void 0),this.onColumnMovedEventCallback&&(this.onColumnMovedEventCallback(),this.onColumnMovedEventCallback=void 0),this.clearTimeouts(),this.state=0,this.lastMouseEvent=null}showTooltip(){const e=h({},this.parentComp.getTooltipParams());if(!y(e.value)||this.shouldDisplayTooltip&&!this.shouldDisplayTooltip())return void this.setToDoNothing();this.state=2,this.tooltipInstanceCount++;const t=this.newTooltipComponentCallback.bind(this,this.tooltipInstanceCount);this.userComponentFactory.getTooltipCompDetails(e).newAgStackInstance().then(t)}hideTooltip(t){if(!t&&this.isInteractingWithTooltip)return;this.tooltipComp&&(this.destroyTooltipComp(),e.lastTooltipHideTime=(new Date).getTime());const i={type:ct.EVENT_TOOLTIP_HIDE,parentGui:this.parentComp.getGui()};this.eventService.dispatchEvent(i),this.state=0}newTooltipComponentCallback(e,t){if(2!==this.state||this.tooltipInstanceCount!==e)return void this.getContext().destroyBean(t);const i=t.getGui();this.tooltipComp=t,i.classList.contains("ag-tooltip")||i.classList.add("ag-tooltip-custom"),0===this.tooltipTrigger&&i.classList.add("ag-tooltip-animate"),this.interactionEnabled&&i.classList.add("ag-tooltip-interactive");const r=this.localeService.getLocaleTextFunc(),n=this.popupService.addPopup({eChild:i,ariaLabel:r("ariaLabelTooltip","Tooltip")});n&&(this.tooltipPopupDestroyFunc=n.hideFunc),this.positionTooltip(),1===this.tooltipTrigger&&(this.onBodyScrollEventCallback=this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL,this.setToDoNothing.bind(this)),this.onColumnMovedEventCallback=this.addManagedListener(this.eventService,ct.EVENT_COLUMN_MOVED,this.setToDoNothing.bind(this))),this.interactionEnabled&&(0===this.tooltipTrigger?(this.tooltipMouseEnterListener=this.addManagedListener(i,"mouseenter",this.onTooltipMouseEnter.bind(this))||null,this.tooltipMouseLeaveListener=this.addManagedListener(i,"mouseleave",this.onTooltipMouseLeave.bind(this))||null):(this.tooltipFocusInListener=this.addManagedListener(i,"focusin",this.onTooltipFocusIn.bind(this))||null,this.tooltipFocusOutListener=this.addManagedListener(i,"focusout",this.onTooltipFocusOut.bind(this))||null));const s={type:ct.EVENT_TOOLTIP_SHOW,tooltipGui:i,parentGui:this.parentComp.getGui()};this.eventService.dispatchEvent(s),this.startHideTimeout()}onTooltipMouseEnter(){this.isInteractingWithTooltip=!0,this.unlockService()}onTooltipMouseLeave(){this.isInteractingWithTooltip=!1,this.lockService()}onTooltipFocusIn(){this.isInteractingWithTooltip=!0}onTooltipFocusOut(e){var t;const i=this.parentComp.getGui(),r=null==(t=this.tooltipComp)?void 0:t.getGui(),n=e.relatedTarget;(null==r?void 0:r.contains(n))||(this.isInteractingWithTooltip=!1,i.contains(n)?this.startHideTimeout():this.hideTooltip())}positionTooltip(){const e={type:"tooltip",ePopup:this.tooltipComp.getGui(),nudgeY:18,skipObserver:this.tooltipMouseTrack};this.lastMouseEvent?this.popupService.positionPopupUnderMouseEvent(d(h({},e),{mouseEvent:this.lastMouseEvent})):this.popupService.positionPopupByComponent(d(h({},e),{eventSource:this.parentComp.getGui(),position:"under",keepWithinBounds:!0,nudgeY:5}))}destroyTooltipComp(){this.tooltipComp.getGui().classList.add("ag-tooltip-hiding");const e=this.tooltipPopupDestroyFunc,t=this.tooltipComp,i=0===this.tooltipTrigger?this.FADE_OUT_TOOLTIP_TIMEOUT:0;window.setTimeout(()=>{e(),this.getContext().destroyBean(t)},i),this.clearTooltipListeners(),this.tooltipPopupDestroyFunc=void 0,this.tooltipComp=void 0}clearTooltipListeners(){[this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener,this.tooltipFocusInListener,this.tooltipFocusOutListener].forEach(e=>{e&&e()}),this.tooltipMouseEnterListener=this.tooltipMouseLeaveListener=this.tooltipFocusInListener=this.tooltipFocusOutListener=null}lockService(){e.isLocked=!0,this.interactiveTooltipTimeoutId=window.setTimeout(()=>{this.unlockService(),this.setToDoNothing()},this.INTERACTIVE_HIDE_DELAY)}unlockService(){e.isLocked=!1,this.clearInteractiveTimeout()}startHideTimeout(){this.clearHideTimeout(),this.hideTooltipTimeoutId=window.setTimeout(this.hideTooltip.bind(this),this.getTooltipDelay("hide"))}clearShowTimeout(){this.showTooltipTimeoutId&&(window.clearTimeout(this.showTooltipTimeoutId),this.showTooltipTimeoutId=void 0)}clearHideTimeout(){this.hideTooltipTimeoutId&&(window.clearTimeout(this.hideTooltipTimeoutId),this.hideTooltipTimeoutId=void 0)}clearInteractiveTimeout(){this.interactiveTooltipTimeoutId&&(window.clearTimeout(this.interactiveTooltipTimeoutId),this.interactiveTooltipTimeoutId=void 0)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout(),this.clearInteractiveTimeout()}};fn.isLocked=!1,g([he("popupService")],fn.prototype,"popupService",2),g([he("userComponentFactory")],fn.prototype,"userComponentFactory",2),g([le],fn.prototype,"postConstruct",1);var mn=fn,vn=class extends nt{constructor(e,t){super(),this.ctrl=e,t&&(this.beans=t)}postConstruct(){this.refreshToolTip()}setBrowserTooltip(e){const t="title",i=this.ctrl.getGui();i&&(null!=e&&""!=e?i.setAttribute(t,e):i.removeAttribute(t))}updateTooltipText(){this.tooltip=this.ctrl.getTooltipValue()}createTooltipFeatureIfNeeded(){var e,t,i,r;if(null!=this.tooltipManager)return;const n={getTooltipParams:()=>this.getTooltipParams(),getGui:()=>this.ctrl.getGui()};this.tooltipManager=this.createBean(new mn(n,null==(t=(e=this.ctrl).getTooltipShowDelayOverride)?void 0:t.call(e),null==(r=(i=this.ctrl).getTooltipHideDelayOverride)?void 0:r.call(i),this.ctrl.shouldDisplayTooltip),this.beans.context)}refreshToolTip(){this.browserTooltips=this.beans.gos.get("enableBrowserTooltips"),this.updateTooltipText(),this.browserTooltips?(this.setBrowserTooltip(this.tooltip),this.tooltipManager&&(this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context))):(this.setBrowserTooltip(null),this.createTooltipFeatureIfNeeded())}getTooltipParams(){const e=this.ctrl,t=e.getColumn?e.getColumn():void 0,i=e.getColDef?e.getColDef():void 0,r=e.getRowNode?e.getRowNode():void 0;return{location:e.getLocation(),colDef:i,column:t,rowIndex:e.getRowIndex?e.getRowIndex():void 0,node:r,data:r?r.data:void 0,value:this.getTooltipText(),valueFormatted:e.getValueFormatted?e.getValueFormatted():void 0,hideTooltipCallback:()=>{var e;return null==(e=this.tooltipManager)?void 0:e.hideTooltip(!0)}}}getTooltipText(){return this.tooltip}destroy(){this.tooltipManager&&(this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context)),super.destroy()}};g([he("beans")],vn.prototype,"beans",2),g([le],vn.prototype,"postConstruct",1);var Cn=new un,yn=class e extends nt{constructor(e){super(),this.displayed=!0,this.visible=!0,this.compId=Cn.next(),this.cssClassManager=new gn(()=>this.eGui),e&&this.setTemplate(e)}preConstructOnComponent(){this.usingBrowserTooltips=this.gos.get("enableBrowserTooltips")}getCompId(){return this.compId}getTooltipParams(){return{value:this.tooltipText,location:"UNKNOWN"}}setTooltip(e){const{newTooltipText:t,showDelayOverride:i,hideDelayOverride:r,location:n,shouldDisplayTooltip:s}=e||{};this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),this.tooltipText!==t&&(this.tooltipText=t);null!=t&&(this.tooltipFeature=this.createBean(new vn({getTooltipValue:()=>this.tooltipText,getGui:()=>this.getGui(),getLocation:()=>null!=n?n:"UNKNOWN",getColDef:null==e?void 0:e.getColDef,getColumn:null==e?void 0:e.getColumn,getTooltipShowDelayOverride:null!=i?()=>i:void 0,getTooltipHideDelayOverride:null!=r?()=>r:void 0,shouldDisplayTooltip:s})))}createChildComponentsFromTags(e,t){Fr(e.childNodes).forEach(i=>{if(!(i instanceof HTMLElement))return;const r=this.createComponentFromElement(i,e=>{e.getGui()&&this.copyAttributesFromNode(i,e.getGui())},t);if(r){if(r.addItems&&i.children.length){this.createChildComponentsFromTags(i,t);const e=Array.prototype.slice.call(i.children);r.addItems(e)}this.swapComponentForNode(r,e,i)}else i.childNodes&&this.createChildComponentsFromTags(i,t)})}createComponentFromElement(t,i,r){const n=t.nodeName,s=r?r[t.getAttribute("ref")]:void 0,o=this.agStackComponentsRegistry.getComponentClass(n);if(o){e.elementGettingCreated=t;const r=new o(s);return r.setParentComponent(this),this.createBean(r,null,i),r}return null}copyAttributesFromNode(e,t){kr(e.attributes,(e,i)=>t.setAttribute(e,i))}swapComponentForNode(e,t,i){const r=e.getGui();t.replaceChild(r,i),t.insertBefore(document.createComment(i.nodeName),r),this.addDestroyFunc(this.destroyBean.bind(this,e)),this.swapInComponentForQuerySelectors(e,i)}swapInComponentForQuerySelectors(e,t){const i=this;this.iterateOverQuerySelectors(r=>{i[r.attributeName]===t&&(i[r.attributeName]=e)})}iterateOverQuerySelectors(e){let t=Object.getPrototypeOf(this);for(;null!=t;){const i=t.__agComponentMetaData,r=j(t.constructor);i&&i[r]&&i[r].querySelectors&&i[r].querySelectors.forEach(t=>e(t)),t=Object.getPrototypeOf(t)}}activateTabIndex(e){const t=this.gos.get("tabIndex");e||(e=[]),e.length||e.push(this.getGui()),e.forEach(e=>e.setAttribute("tabindex",t.toString()))}setTemplate(e,t){const i=Er(e);this.setTemplateFromElement(i,t)}setTemplateFromElement(e,t){this.eGui=e,this.eGui.__agComponent=this,this.wireQuerySelectors(),this.getContext()&&this.createChildComponentsFromTags(this.getGui(),t)}createChildComponentsPreConstruct(){this.getGui()&&this.createChildComponentsFromTags(this.getGui())}wireQuerySelectors(){if(!this.eGui)return;const e=this;this.iterateOverQuerySelectors(t=>{const i=i=>e[t.attributeName]=i;if(t.refSelector&&this.getAttribute("ref")===t.refSelector)i(this.eGui);else{const e=this.eGui.querySelector(t.querySelector);e&&i(e.__agComponent||e)}})}getGui(){return this.eGui}getFocusableElement(){return this.eGui}getAriaElement(){return this.getFocusableElement()}setParentComponent(e){this.parentComponent=e}getParentComponent(){return this.parentComponent}setGui(e){this.eGui=e}queryForHtmlElement(e){return this.eGui.querySelector(e)}queryForHtmlInputElement(e){return this.eGui.querySelector(e)}appendChild(e,t){if(null!=e)if(t||(t=this.eGui),Or(e))t.appendChild(e);else{const i=e;t.appendChild(i.getGui())}}isDisplayed(){return this.displayed}setVisible(e,t={}){if(e!==this.visible){this.visible=e;const{skipAriaHidden:i}=t;ar(this.eGui,e,{skipAriaHidden:i})}}setDisplayed(t,i={}){if(t!==this.displayed){this.displayed=t;const{skipAriaHidden:r}=i;or(this.eGui,t,{skipAriaHidden:r});const n={type:e.EVENT_DISPLAYED_CHANGED,visible:this.displayed};this.dispatchEvent(n)}}destroy(){this.parentComponent&&(this.parentComponent=void 0),this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const e=this.eGui;e&&e.__agComponent&&(e.__agComponent=void 0),super.destroy()}addGuiEventListener(e,t,i){this.eGui.addEventListener(e,t,i),this.addDestroyFunc(()=>this.eGui.removeEventListener(e,t))}addCssClass(e){this.cssClassManager.addCssClass(e)}removeCssClass(e){this.cssClassManager.removeCssClass(e)}containsCssClass(e){return this.cssClassManager.containsCssClass(e)}addOrRemoveCssClass(e,t){this.cssClassManager.addOrRemoveCssClass(e,t)}getAttribute(e){const{eGui:t}=this;return t?t.getAttribute(e):null}getRefElement(e){return this.queryForHtmlElement(`[ref="${e}"]`)}};yn.EVENT_DISPLAYED_CHANGED="displayedChanged",g([he("agStackComponentsRegistry")],yn.prototype,"agStackComponentsRegistry",2),g([ae],yn.prototype,"preConstructOnComponent",1),g([ae],yn.prototype,"createChildComponentsPreConstruct",1);var wn=yn;function Sn(e){return En.bind(this,e,void 0)}function bn(e){return En.bind(this,`[ref=${e}]`,e)}function En(e,t,i,r,n){null!==e?"number"!=typeof n?function(e,t,i){const r=function(e,t){return e.__agComponentMetaData||(e.__agComponentMetaData={}),e.__agComponentMetaData[t]||(e.__agComponentMetaData[t]={}),e.__agComponentMetaData[t]}(e,j(e.constructor));r[t]||(r[t]=[]),r[t].push(i)}(i,"querySelectors",{attributeName:r,querySelector:e,refSelector:t}):console.error("AG Grid: QuerySelector should be on an attribute"):console.error("AG Grid: QuerySelector selector should not be null")}var An=class extends wn{constructor(){super('\n            <div class="ag-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eFloatingFilterText"></ag-input-text-field>\n            </div>')}destroy(){super.destroy()}init(e){this.params=e;const t=this.columnModel.getDisplayNameForColumn(e.column,"header",!0),i=this.localeService.getLocaleTextFunc();this.eFloatingFilterText.setDisabled(!0).setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}onParentModelChanged(e){null!=e?this.params.parentFilterInstance(t=>{if(t.getModelAsString){const i=t.getModelAsString(e);this.eFloatingFilterText.setValue(i)}}):this.eFloatingFilterText.setValue("")}onParamsUpdated(e){this.refresh(e)}refresh(e){this.init(e)}};g([bn("eFloatingFilterText")],An.prototype,"eFloatingFilterText",2),g([he("columnModel")],An.prototype,"columnModel",2);var Tn=class{constructor(e,t,i,r,n){this.alive=!0,this.context=e,this.eParent=r,t.getDateCompDetails(i).newAgStackInstance().then(t=>{this.alive?(this.dateComp=t,t&&(r.appendChild(t.getGui()),t.afterGuiAttached&&t.afterGuiAttached(),this.tempValue&&t.setDate(this.tempValue),null!=this.disabled&&this.setDateCompDisabled(this.disabled),null==n||n(this))):e.destroyBean(t)})}destroy(){this.alive=!1,this.dateComp=this.context.destroyBean(this.dateComp)}getDate(){return this.dateComp?this.dateComp.getDate():this.tempValue}setDate(e){this.dateComp?this.dateComp.setDate(e):this.tempValue=e}setDisabled(e){this.dateComp?this.setDateCompDisabled(e):this.disabled=e}setDisplayed(e){or(this.eParent,e)}setInputPlaceholder(e){this.dateComp&&this.dateComp.setInputPlaceholder&&this.dateComp.setInputPlaceholder(e)}setInputAriaLabel(e){this.dateComp&&this.dateComp.setInputAriaLabel&&this.dateComp.setInputAriaLabel(e)}afterGuiAttached(e){this.dateComp&&"function"==typeof this.dateComp.afterGuiAttached&&this.dateComp.afterGuiAttached(e)}updateParams(e){var t,i;let r=!1;(null==(t=this.dateComp)?void 0:t.refresh)&&"function"==typeof this.dateComp.refresh&&null!==this.dateComp.refresh(e)&&(r=!0),!r&&(null==(i=this.dateComp)?void 0:i.onParamsUpdated)&&"function"==typeof this.dateComp.onParamsUpdated&&null!==this.dateComp.onParamsUpdated(e)&&U("Custom date component method 'onParamsUpdated' is deprecated. Use 'refresh' instead.")}setDateCompDisabled(e){null!=this.dateComp&&null!=this.dateComp.setDisabled&&this.dateComp.setDisabled(e)}},Mn=class{constructor(){this.customFilterOptions={}}init(e,t){this.filterOptions=e.filterOptions||t,this.mapCustomOptions(),this.selectDefaultItem(e)}getFilterOptions(){return this.filterOptions}mapCustomOptions(){this.filterOptions&&this.filterOptions.forEach(e=>{"string"!=typeof e&&([["displayKey"],["displayName"],["predicate","test"]].every(t=>!!t.some(t=>null!=e[t])||(console.warn(`AG Grid: ignoring FilterOptionDef as it doesn't contain one of '${t}'`),!1))?this.customFilterOptions[e.displayKey]=e:this.filterOptions=this.filterOptions.filter(t=>t===e)||[])})}selectDefaultItem(e){if(e.defaultOption)this.defaultOption=e.defaultOption;else if(this.filterOptions.length>=1){const e=this.filterOptions[0];"string"==typeof e?this.defaultOption=e:e.displayKey?this.defaultOption=e.displayKey:console.warn("AG Grid: invalid FilterOptionDef supplied as it doesn't contain a 'displayKey'")}else console.warn("AG Grid: no filter options for filter")}getDefaultOption(){return this.defaultOption}getCustomOption(e){return this.customFilterOptions[e]}},Rn={applyFilter:"Apply",clearFilter:"Clear",resetFilter:"Reset",cancelFilter:"Cancel",textFilter:"Text Filter",numberFilter:"Number Filter",dateFilter:"Date Filter",setFilter:"Set Filter",filterOoo:"Filter...",empty:"Choose one",equals:"Equals",notEqual:"Does not equal",lessThan:"Less than",greaterThan:"Greater than",inRange:"Between",inRangeStart:"From",inRangeEnd:"To",lessThanOrEqual:"Less than or equal to",greaterThanOrEqual:"Greater than or equal to",contains:"Contains",notContains:"Does not contain",startsWith:"Begins with",endsWith:"Ends with",blank:"Blank",notBlank:"Not blank",before:"Before",after:"After",andCondition:"AND",orCondition:"OR",dateFormatOoo:"yyyy-mm-dd"},_n=class e extends nt{constructor(e,t={}){super(),this.eFocusableElement=e,this.callbacks=t,this.callbacks=h({shouldStopEventPropagation:()=>!1,onTabKeyDown:e=>{if(e.defaultPrevented)return;const t=this.focusService.findNextFocusableElement(this.eFocusableElement,!1,e.shiftKey);t&&(t.focus(),e.preventDefault())}},t)}postConstruct(){this.eFocusableElement.classList.add(e.FOCUS_MANAGED_CLASS),this.addKeyDownListeners(this.eFocusableElement),this.callbacks.onFocusIn&&this.addManagedListener(this.eFocusableElement,"focusin",this.callbacks.onFocusIn),this.callbacks.onFocusOut&&this.addManagedListener(this.eFocusableElement,"focusout",this.callbacks.onFocusOut)}addKeyDownListeners(e){this.addManagedListener(e,"keydown",e=>{e.defaultPrevented||Qe(e)||(this.callbacks.shouldStopEventPropagation(e)?Ye(e):e.key===Qr.TAB?this.callbacks.onTabKeyDown(e):this.callbacks.handleKeyDown&&this.callbacks.handleKeyDown(e))})}};_n.FOCUS_MANAGED_CLASS="ag-focus-managed",g([he("focusService")],_n.prototype,"focusService",2),g([le],_n.prototype,"postConstruct",1);var Pn=_n,xn="ag-resizer-wrapper",Dn=`<div class="${xn}">\n        <div ref="eTopLeftResizer" class="ag-resizer ag-resizer-topLeft"></div>\n        <div ref="eTopResizer" class="ag-resizer ag-resizer-top"></div>\n        <div ref="eTopRightResizer" class="ag-resizer ag-resizer-topRight"></div>\n        <div ref="eRightResizer" class="ag-resizer ag-resizer-right"></div>\n        <div ref="eBottomRightResizer" class="ag-resizer ag-resizer-bottomRight"></div>\n        <div ref="eBottomResizer" class="ag-resizer ag-resizer-bottom"></div>\n        <div ref="eBottomLeftResizer" class="ag-resizer ag-resizer-bottomLeft"></div>\n        <div ref="eLeftResizer" class="ag-resizer ag-resizer-left"></div>\n    </div>`,In=class extends nt{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0},this.lastSize={width:-1,height:-1},this.positioned=!1,this.resizersAdded=!1,this.resizeListeners=[],this.boundaryEl=null,this.isResizing=!1,this.isMoving=!1,this.resizable={},this.movable=!1,this.currentResizer=null,this.config=Object.assign({},{popup:!1},t)}center(){const{clientHeight:e,clientWidth:t}=this.offsetParent,i=t/2-this.getWidth()/2,r=e/2-this.getHeight()/2;this.offsetElement(i,r)}initialisePosition(){if(this.positioned)return;const{centered:e,forcePopupParentAsOffsetParent:t,minWidth:i,width:r,minHeight:n,height:s,x:o,y:a}=this.config;this.offsetParent||this.setOffsetParent();let l=0,c=0;const u=br(this.element);if(u){const e=this.findBoundaryElement(),t=window.getComputedStyle(e);if(null!=t.minWidth){const i=e.offsetWidth-this.element.offsetWidth;c=parseInt(t.minWidth,10)-i}if(null!=t.minHeight){const i=e.offsetHeight-this.element.offsetHeight;l=parseInt(t.minHeight,10)-i}}if(this.minHeight=n||l,this.minWidth=i||c,r&&this.setWidth(r),s&&this.setHeight(s),r&&s||this.refreshSize(),e)this.center();else if(o||a)this.offsetElement(o,a);else if(u&&t){let e=this.boundaryEl,t=!0;if(e||(e=this.findBoundaryElement(),t=!1),e){const i=parseFloat(e.style.top),r=parseFloat(e.style.left);t?this.offsetElement(isNaN(r)?0:r,isNaN(i)?0:i):this.setPosition(r,i)}}this.positioned=!!this.offsetParent}isPositioned(){return this.positioned}getPosition(){return this.position}setMovable(e,t){if(!this.config.popup||e===this.movable)return;this.movable=e;const i=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?(this.dragService.addDragSource(i),this.moveElementDragListener=i):(this.dragService.removeDragSource(i),this.moveElementDragListener=void 0)}setResizable(e){if(this.clearResizeListeners(),e?this.addResizers():this.removeResizers(),"boolean"==typeof e){if(!1===e)return;e={topLeft:e,top:e,topRight:e,right:e,bottomRight:e,bottom:e,bottomLeft:e,left:e}}Object.keys(e).forEach(t=>{const i=!!e[t],r=this.getResizerElement(t),n={dragStartPixels:0,eElement:r,onDragStart:e=>this.onResizeStart(e,t),onDragging:this.onResize.bind(this),onDragStop:e=>this.onResizeEnd(e,t)};(i||!this.isAlive()&&!i)&&(i?(this.dragService.addDragSource(n),this.resizeListeners.push(n),r.style.pointerEvents="all"):r.style.pointerEvents="none",this.resizable[t]=i)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";const{height:e,width:t}=this.lastSize;-1!==t&&(this.element.style.width=`${t}px`),-1!==e&&(this.element.style.height=`${e}px`)}getHeight(){return this.element.offsetHeight}setHeight(e){const{popup:t}=this.config,i=this.element;let r=!1;if("string"==typeof e&&-1!==e.indexOf("%"))Lr(i,e),e=pr(i),r=!0;else if(e=Math.max(this.minHeight,e),this.positioned){const t=this.getAvailableHeight();t&&e>t&&(e=t)}this.getHeight()!==e&&(r?(i.style.maxHeight="unset",i.style.minHeight="unset"):t?Lr(i,e):(i.style.height=`${e}px`,i.style.flex="0 0 auto",this.lastSize.height="number"==typeof e?e:parseFloat(e)))}getAvailableHeight(){const{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();const{clientHeight:i}=this.offsetParent;if(!i)return null;const r=this.element.getBoundingClientRect(),n=this.offsetParent.getBoundingClientRect(),s=e?this.position.y:r.top,o=e?0:n.top;let a=0;if(t){const e=this.element.parentElement;if(e){const{bottom:t}=e.getBoundingClientRect();a=t-r.bottom}}return i+o-s-a}getWidth(){return this.element.offsetWidth}setWidth(e){const t=this.element,{popup:i}=this.config;let r=!1;if("string"==typeof e&&-1!==e.indexOf("%"))Dr(t,e),e=gr(t),r=!0;else if(this.positioned){e=Math.max(this.minWidth,e);const{clientWidth:t}=this.offsetParent,r=i?this.position.x:this.element.getBoundingClientRect().left;t&&e+r>t&&(e=t-r)}this.getWidth()!==e&&(r?(t.style.maxWidth="unset",t.style.minWidth="unset"):this.config.popup?Dr(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width="number"==typeof e?e:parseFloat(e)))}offsetElement(e=0,t=0){const{forcePopupParentAsOffsetParent:i}=this.config,r=i?this.boundaryEl:this.element;r&&(this.popupService.positionPopup({ePopup:r,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t})}),this.setPosition(parseFloat(r.style.left),parseFloat(r.style.top)))}constrainSizeToAvailableHeight(e){if(!this.config.forcePopupParentAsOffsetParent)return;e?this.resizeObserverSubscriber=this.resizeObserverService.observeResize(this.popupService.getPopupParent(),()=>{const e=this.getAvailableHeight();this.element.style.setProperty("max-height",`${e}px`)}):(this.element.style.removeProperty("max-height"),this.resizeObserverSubscriber&&(this.resizeObserverSubscriber(),this.resizeObserverSubscriber=void 0))}setPosition(e,t){this.position.x=e,this.position.y=t}updateDragStartPosition(e,t){this.dragStartPosition={x:e,y:t}}calculateMouseMovement(e){const{e:t,isLeft:i,isTop:r,anywhereWithin:n,topBuffer:s}=e,o=t.clientX-this.dragStartPosition.x,a=t.clientY-this.dragStartPosition.y;return{movementX:this.shouldSkipX(t,!!i,!!n,o)?0:o,movementY:this.shouldSkipY(t,!!r,s,a)?0:a}}shouldSkipX(e,t,i,r){const n=this.element.getBoundingClientRect(),s=this.offsetParent.getBoundingClientRect(),o=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.x:n.left;let l=a<=0&&s.left>=e.clientX||s.right<=e.clientX&&s.right<=o.right;return!!l||(l=t?r<0&&e.clientX>a+s.left||r>0&&e.clientX<a+s.left:i?r<0&&e.clientX>o.right||r>0&&e.clientX<a+s.left:r<0&&e.clientX>o.right||r>0&&e.clientX<o.right,l)}shouldSkipY(e,t,i=0,r){const n=this.element.getBoundingClientRect(),s=this.offsetParent.getBoundingClientRect(),o=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.y:n.top;let l=a<=0&&s.top>=e.clientY||s.bottom<=e.clientY&&s.bottom<=o.bottom;return!!l||(l=t?r<0&&e.clientY>a+s.top+i||r>0&&e.clientY<a+s.top:r<0&&e.clientY>o.bottom||r>0&&e.clientY<o.bottom,l)}createResizeMap(){const e=this.element;this.resizerMap={topLeft:{element:e.querySelector("[ref=eTopLeftResizer]")},top:{element:e.querySelector("[ref=eTopResizer]")},topRight:{element:e.querySelector("[ref=eTopRightResizer]")},right:{element:e.querySelector("[ref=eRightResizer]")},bottomRight:{element:e.querySelector("[ref=eBottomRightResizer]")},bottom:{element:e.querySelector("[ref=eBottomResizer]")},bottomLeft:{element:e.querySelector("[ref=eBottomLeftResizer]")},left:{element:e.querySelector("[ref=eLeftResizer]")}}}addResizers(){if(this.resizersAdded)return;const e=this.element;if(!e)return;const t=(new DOMParser).parseFromString(Dn,"text/html").body;e.appendChild(t.firstChild),this.createResizeMap(),this.resizersAdded=!0}removeResizers(){this.resizerMap=void 0;const e=this.element.querySelector(`.${xn}`);e&&this.element.removeChild(e),this.resizersAdded=!1}getResizerElement(e){return this.resizerMap[e].element}onResizeStart(e,t){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.currentResizer={isTop:!!t.match(/top/i),isRight:!!t.match(/right/i),isBottom:!!t.match(/bottom/i),isLeft:!!t.match(/left/i)},this.element.classList.add("ag-resizing"),this.resizerMap[t].element.classList.add("ag-active");const{popup:i,forcePopupParentAsOffsetParent:r}=this.config;i||r||this.applySizeToSiblings(this.currentResizer.isBottom||this.currentResizer.isTop),this.isResizing=!0,this.updateDragStartPosition(e.clientX,e.clientY)}getSiblings(){const e=this.element.parentElement;return e?Array.prototype.slice.call(e.children).filter(e=>!e.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){const e=this.getSiblings()||[];let t=0,i=0;for(let r=0;r<e.length;r++){const n=e[r],s=!!n.style.flex&&"0 0 auto"!==n.style.flex;if(n===this.element)continue;let o=this.minHeight||0,a=this.minWidth||0;if(s){const e=window.getComputedStyle(n);e.minHeight&&(o=parseInt(e.minHeight,10)),e.minWidth&&(a=parseInt(e.minWidth,10))}else o=n.offsetHeight,a=n.offsetWidth;t+=o,i+=a}return{height:t,width:i}}applySizeToSiblings(e){let t=null;const i=this.getSiblings();if(i){for(let r=0;r<i.length;r++){const n=i[r];n!==t&&(e?n.style.height=`${n.offsetHeight}px`:n.style.width=`${n.offsetWidth}px`,n.style.flex="0 0 auto",n===this.element&&(t=i[r+1]))}t&&(t.style.removeProperty("height"),t.style.removeProperty("min-height"),t.style.removeProperty("max-height"),t.style.flex="1 1 auto")}}isResizable(){return Object.values(this.resizable).some(e=>e)}onResize(e){if(!this.isResizing||!this.currentResizer)return;const{popup:t,forcePopupParentAsOffsetParent:i}=this.config,{isTop:r,isRight:n,isBottom:s,isLeft:o}=this.currentResizer,a=n||o,l=s||r,{movementX:c,movementY:u}=this.calculateMouseMovement({e,isLeft:o,isTop:r}),h=this.position.x,d=this.position.y;let p=0,g=0;if(a&&c){const e=o?-1:1,t=this.getWidth(),i=t+c*e;let r=!1;o&&(p=t-i,(h+p<=0||i<=this.minWidth)&&(r=!0,p=0)),r||this.setWidth(i)}if(l&&u){const e=r?-1:1,t=this.getHeight(),i=t+u*e;let n=!1;r?(g=t-i,(d+g<=0||i<=this.minHeight)&&(n=!0,g=0)):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&t<i&&this.getMinSizeOfSiblings().height+i>this.element.parentElement.offsetHeight&&(n=!0),n||this.setHeight(i)}this.updateDragStartPosition(e.clientX,e.clientY),((t||i)&&p||g)&&this.offsetElement(h+p,d+g)}onResizeEnd(e,t){this.isResizing=!1,this.currentResizer=null,this.boundaryEl=null,this.element.classList.remove("ag-resizing"),this.resizerMap[t].element.classList.remove("ag-active"),this.dispatchEvent({type:"resize"})}refreshSize(){const e=this.element;this.config.popup&&(this.config.width||this.setWidth(e.offsetWidth),this.config.height||this.setHeight(e.offsetHeight))}onMoveStart(e){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.isMoving=!0,this.element.classList.add("ag-moving"),this.updateDragStartPosition(e.clientX,e.clientY)}onMove(e){if(!this.isMoving)return;const{x:t,y:i}=this.position;let r;this.config.calculateTopBuffer&&(r=this.config.calculateTopBuffer());const{movementX:n,movementY:s}=this.calculateMouseMovement({e,isTop:!0,anywhereWithin:!0,topBuffer:r});this.offsetElement(t+n,i+s),this.updateDragStartPosition(e.clientX,e.clientY)}onMoveEnd(){this.isMoving=!1,this.boundaryEl=null,this.element.classList.remove("ag-moving")}setOffsetParent(){this.config.forcePopupParentAsOffsetParent?this.offsetParent=this.popupService.getPopupParent():this.offsetParent=this.element.offsetParent}findBoundaryElement(){let e=this.element;for(;e;){if("static"!==window.getComputedStyle(e).position)return e;e=e.parentElement}return this.element}clearResizeListeners(){for(;this.resizeListeners.length;){const e=this.resizeListeners.pop();this.dragService.removeDragSource(e)}}destroy(){super.destroy(),this.moveElementDragListener&&this.dragService.removeDragSource(this.moveElementDragListener),this.constrainSizeToAvailableHeight(!1),this.clearResizeListeners(),this.removeResizers()}};g([he("popupService")],In.prototype,"popupService",2),g([he("resizeObserverService")],In.prototype,"resizeObserverService",2),g([he("dragService")],In.prototype,"dragService",2);var Ln=class e extends wn{constructor(e){super(),this.filterNameKey=e,this.applyActive=!1,this.hidePopup=null,this.debouncePending=!1,this.appliedModel=null,this.buttonListeners=[]}postConstruct(){this.resetTemplate(),this.createManagedBean(new Pn(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=new In(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}),this.createBean(this.positionableFeature)}handleKeyDown(e){}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return!!this.appliedModel}resetTemplate(e){let t=this.getGui();t&&t.removeEventListener("submit",this.onFormSubmit);const i=`\n            <form class="ag-filter-wrapper">\n                <div class="ag-filter-body-wrapper ag-${this.getCssIdentifier()}-body-wrapper" ref="eFilterBody">\n                    ${this.createBodyTemplate()}\n                </div>\n            </form>`;this.setTemplate(i,e),t=this.getGui(),t&&t.addEventListener("submit",this.onFormSubmit)}isReadOnly(){return!!this.providedFilterParams.readOnly}init(e){this.setParams(e),this.resetUiToDefaults(!0).then(()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}setParams(t){this.providedFilterParams=t,this.applyActive=e.isUseApplyButton(t),this.resetButtonsPanel()}updateParams(t){this.providedFilterParams=t,this.applyActive=e.isUseApplyButton(t),this.resetUiToActiveModel(this.getModel(),()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}resetButtonsPanel(){const{buttons:e}=this.providedFilterParams,t=e&&e.length>0&&!this.isReadOnly();if(this.eButtonsPanel?(yr(this.eButtonsPanel),this.buttonListeners.forEach(e=>null==e?void 0:e()),this.buttonListeners=[]):t&&(this.eButtonsPanel=document.createElement("div"),this.eButtonsPanel.classList.add("ag-filter-apply-panel")),!t)return void(this.eButtonsPanel&&wr(this.eButtonsPanel));const i=document.createDocumentFragment(),r=e=>{let t,r;switch(e){case"apply":t=this.translate("applyFilter"),r=e=>this.onBtApply(!1,!1,e);break;case"clear":t=this.translate("clearFilter"),r=()=>this.onBtClear();break;case"reset":t=this.translate("resetFilter"),r=()=>this.onBtReset();break;case"cancel":t=this.translate("cancelFilter"),r=e=>{this.onBtCancel(e)};break;default:return void console.warn("AG Grid: Unknown button type specified")}const n=Er(`<button\n                    type="${"apply"===e?"submit":"button"}"\n                    ref="${e}FilterButton"\n                    class="ag-button ag-standard-button ag-filter-apply-panel-button"\n                >${t}\n                </button>`);this.buttonListeners.push(this.addManagedListener(n,"click",r)),i.append(n)};ln(e).forEach(e=>r(e)),this.eButtonsPanel.append(i),this.getGui().appendChild(this.eButtonsPanel)}getDefaultDebounceMs(){return 0}setupOnBtApplyDebounce(){const t=e.getDebounceMs(this.providedFilterParams,this.getDefaultDebounceMs()),i=Z(this.checkApplyDebounce.bind(this),t);this.onBtApplyDebounce=()=>{this.debouncePending=!0,i()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.onBtApply())}getModel(){return this.appliedModel?this.appliedModel:null}setModel(e){return(null!=e?this.setModelIntoUi(e):this.resetUiToDefaults()).then(()=>{this.updateUiVisibility(),this.applyModel("api")})}onBtCancel(e){this.resetUiToActiveModel(this.getModel(),()=>{this.handleCancelEnd(e)})}handleCancelEnd(e){this.providedFilterParams.closeOnApply&&this.close(e)}resetUiToActiveModel(e,t){const i=()=>{this.onUiChanged(!1,"prevent"),null==t||t()};null!=e?this.setModelIntoUi(e).then(i):this.resetUiToDefaults().then(i)}onBtClear(){this.resetUiToDefaults().then(()=>this.onUiChanged())}onBtReset(){this.onBtClear(),this.onBtApply()}applyModel(e="api"){const t=this.getModelFromUi();if(!this.isModelValid(t))return!1;const i=this.appliedModel;return this.appliedModel=t,!this.areModelsEqual(i,t)}isModelValid(e){return!0}onFormSubmit(e){e.preventDefault()}onBtApply(e=!1,t=!1,i){if(i&&i.preventDefault(),this.applyModel(t?"rowDataUpdated":"ui")){const i="columnFilter";this.providedFilterParams.filterChangedCallback({afterFloatingFilter:e,afterDataChange:t,source:i})}const{closeOnApply:r}=this.providedFilterParams;r&&this.applyActive&&!e&&!t&&this.close(i)}onNewRowsLoaded(){}close(e){if(!this.hidePopup)return;const t=e,i=t&&t.key;let r;"Enter"!==i&&"Space"!==i||(r={keyboardEvent:t}),this.hidePopup(r),this.hidePopup=null}onUiChanged(e=!1,t){if(this.updateUiVisibility(),this.providedFilterParams.filterModifiedCallback(),this.applyActive&&!this.isReadOnly()){const e=this.isModelValid(this.getModelFromUi()),t=this.getRefElement("applyFilterButton");t&&lr(t,!e)}e&&!t||"immediately"===t?this.onBtApply(e):(this.applyActive||t)&&"debounce"!==t||this.onBtApplyDebounce()}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup),this.refreshFilterResizer(null==e?void 0:e.container)}refreshFilterResizer(e){if(!this.positionableFeature||"toolPanel"===e)return;const t="floatingFilter"===e||"columnFilter"===e,{positionableFeature:i,gos:r}=this;t?(i.restoreLastSize(),i.setResizable(r.get("enableRtl")?{bottom:!0,bottomLeft:!0,left:!0}:{bottom:!0,bottomRight:!0,right:!0})):(this.positionableFeature.removeSizeFromEl(),this.positionableFeature.setResizable(!1)),this.positionableFeature.constrainSizeToAvailableHeight(!0)}afterGuiDetached(){this.checkApplyDebounce(),this.positionableFeature&&this.positionableFeature.constrainSizeToAvailableHeight(!1)}static getDebounceMs(t,i){return e.isUseApplyButton(t)?(null!=t.debounceMs&&console.warn("AG Grid: debounceMs is ignored when apply button is present"),0):null!=t.debounceMs?t.debounceMs:i}static isUseApplyButton(e){return!!e.buttons&&e.buttons.indexOf("apply")>=0}refresh(e){return this.providedFilterParams=e,!0}destroy(){const e=this.getGui();e&&e.removeEventListener("submit",this.onFormSubmit),this.hidePopup=null,this.positionableFeature&&(this.positionableFeature=this.destroyBean(this.positionableFeature)),this.appliedModel=null,super.destroy()}translate(e){return this.localeService.getLocaleTextFunc()(e,Rn[e])}getCellValue(e){return this.providedFilterParams.getValue(e)}getPositionableElement(){return this.eFilterBody}};g([he("rowModel")],Ln.prototype,"rowModel",2),g([bn("eFilterBody")],Ln.prototype,"eFilterBody",2),g([le],Ln.prototype,"postConstruct",1);var Nn=Ln,On=class extends wn{constructor(e,t){super(t),this.labelSeparator="",this.labelAlignment="left",this.disabled=!1,this.label="",this.config=e||{}}postConstruct(){this.addCssClass("ag-labeled"),this.eLabel.classList.add("ag-label");const{labelSeparator:e,label:t,labelWidth:i,labelAlignment:r,disabled:n}=this.config;null!=n&&this.setDisabled(n),null!=e&&this.setLabelSeparator(e),null!=t&&this.setLabel(t),null!=i&&this.setLabelWidth(i),this.setLabelAlignment(r||this.labelAlignment),this.refreshLabel()}refreshLabel(){yr(this.eLabel),"string"==typeof this.label?this.eLabel.innerText=this.label+this.labelSeparator:this.label&&this.eLabel.appendChild(this.label),""===this.label?(or(this.eLabel,!1),Bt(this.eLabel,"presentation")):(or(this.eLabel,!0),Bt(this.eLabel,null))}setLabelSeparator(e){return this.labelSeparator===e||(this.labelSeparator=e,null!=this.label&&this.refreshLabel()),this}getLabelId(){return this.eLabel.id=this.eLabel.id||`ag-${this.getCompId()}-label`,this.eLabel.id}getLabel(){return this.label}setLabel(e){return this.label===e||(this.label=e,this.refreshLabel()),this}setLabelAlignment(e){const t=this.getGui().classList;return t.toggle("ag-label-align-left","left"===e),t.toggle("ag-label-align-right","right"===e),t.toggle("ag-label-align-top","top"===e),this}setLabelEllipsis(e){return this.eLabel.classList.toggle("ag-label-ellipsis",e),this}setLabelWidth(e){return null==this.label||xr(this.eLabel,e),this}setDisabled(e){e=!!e;const t=this.getGui();return lr(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}};g([le],On.prototype,"postConstruct",1);var Fn=class extends On{constructor(e,t,i){super(e,t),this.className=i}postConstruct(){super.postConstruct();const{width:e,value:t,onValueChange:i}=this.config;null!=e&&this.setWidth(e),null!=t&&this.setValue(t),null!=i&&this.onValueChange(i),this.className&&this.addCssClass(this.className),this.refreshAriaLabelledBy()}refreshAriaLabelledBy(){const e=this.getAriaElement(),t=this.getLabelId();null!==jt(e)?$t(e,""):$t(e,null!=t?t:"")}setAriaLabel(e){return Kt(this.getAriaElement(),e),this.refreshAriaLabelledBy(),this}onValueChange(e){return this.addManagedListener(this,ct.EVENT_FIELD_VALUE_CHANGED,()=>e(this.getValue())),this}getWidth(){return this.getGui().clientWidth}setWidth(e){return Dr(this.getGui(),e),this}getPreviousValue(){return this.previousValue}getValue(){return this.value}setValue(e,t){return this.value===e||(this.previousValue=this.value,this.value=e,t||this.dispatchEvent({type:ct.EVENT_FIELD_VALUE_CHANGED})),this}},kn=class extends Fn{constructor(e){if(super(e,(null==e?void 0:e.template)||'\n    <div class="ag-picker-field" role="presentation">\n        <div ref="eLabel"></div>\n            <div ref="eWrapper" class="ag-wrapper ag-picker-field-wrapper ag-picker-collapsed">\n            <div ref="eDisplayField" class="ag-picker-field-display"></div>\n            <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n        </div>\n    </div>',null==e?void 0:e.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.ariaRole=null==e?void 0:e.ariaRole,this.onPickerFocusIn=this.onPickerFocusIn.bind(this),this.onPickerFocusOut=this.onPickerFocusOut.bind(this),!e)return;const{pickerGap:t,maxPickerHeight:i,variableWidth:r,minPickerWidth:n,maxPickerWidth:s}=e;null!=t&&(this.pickerGap=t),this.variableWidth=!!r,null!=i&&this.setPickerMaxHeight(i),null!=n&&this.setPickerMinWidth(n),null!=s&&this.setPickerMaxWidth(s)}postConstruct(){super.postConstruct(),this.setupAria();const e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);const t=this.getAriaElement();this.addManagedListener(t,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(this.eLabel,"mousedown",this.onLabelOrWrapperMouseDown.bind(this)),this.addManagedListener(this.eWrapper,"mousedown",this.onLabelOrWrapperMouseDown.bind(this));const{pickerIcon:i,inputWidth:r}=this.config;if(i){const e=qr(i,this.gos);e&&this.eIcon.appendChild(e)}null!=r&&this.setInputWidth(r)}setupAria(){const e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),ii(e,!1),this.ariaRole&&Bt(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){const t=this.getFocusableElement();if(t!==this.eWrapper&&(null==e?void 0:e.target)===t)return;e.preventDefault(),this.getFocusableElement().focus()}this.skipClick?this.skipClick=!1:this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case Qr.UP:case Qr.DOWN:case Qr.ENTER:case Qr.SPACE:e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case Qr.ESCAPE:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker())}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());const e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){const e=this.gos.getDocument(),t=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||(this.destroyMouseWheelFunc=this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL,()=>{this.hidePicker()}));const i=this.localeService.getLocaleTextFunc(),{pickerAriaLabelKey:r,pickerAriaLabelValue:n,modalPicker:s=!0}=this.config,o={modal:s,eChild:t,closeOnEsc:!0,closedCallback:()=>{const t=this.gos.getActiveDomElement(),i=!t||t===e.body;this.beforeHidePicker(),i&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:i(r,n)},a=this.popupService.addPopup(o),{maxPickerHeight:l,minPickerWidth:c,maxPickerWidth:u,variableWidth:h}=this;h?(c&&(t.style.minWidth=c),t.style.width=Nr(gr(this.eWrapper)),u&&(t.style.maxWidth=u)):xr(t,null!=u?u:gr(this.eWrapper));const d=null!=l?l:`${hr(this.popupService.getPopupParent())}px`;return t.style.setProperty("max-height",d),t.style.position="absolute",this.alignPickerToComponent(),a.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;const{pickerType:e}=this.config,{pickerGap:t}=this,i=this.gos.get("enableRtl")?"right":"left";this.popupService.positionPopupByComponent({type:e,eventSource:this.eWrapper,ePopup:this.pickerComponent.getGui(),position:"under",alignSide:i,keepWithinBounds:!0,nudgeY:t})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);const e=this.pickerComponent.getGui();e.removeEventListener("focusin",this.onPickerFocusIn),e.removeEventListener("focusout",this.onPickerFocusOut),this.isPickerDisplayed=!1,this.pickerComponent=void 0,this.hideCurrentPicker=null}toggleExpandedStyles(e){this.isAlive()&&(ii(this.getAriaElement(),e),this.eWrapper.classList.toggle("ag-picker-expanded",e),this.eWrapper.classList.toggle("ag-picker-collapsed",!e))}onPickerFocusIn(){this.togglePickerHasFocus(!0)}onPickerFocusOut(e){var t;(null==(t=this.pickerComponent)?void 0:t.getGui().contains(e.relatedTarget))||this.togglePickerHasFocus(!1)}togglePickerHasFocus(e){this.pickerComponent&&this.eWrapper.classList.toggle("ag-picker-has-focus",e)}hidePicker(){this.hideCurrentPicker&&this.hideCurrentPicker()}setInputWidth(e){return xr(this.eWrapper,e),this}getFocusableElement(){return this.eWrapper}setPickerGap(e){return this.pickerGap=e,this}setPickerMinWidth(e){return"number"==typeof e&&(e=`${e}px`),this.minPickerWidth=null==e?void 0:e,this}setPickerMaxWidth(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerWidth=null==e?void 0:e,this}setPickerMaxHeight(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerHeight=null==e?void 0:e,this}destroy(){this.hidePicker(),super.destroy()}};g([he("popupService")],kn.prototype,"popupService",2),g([bn("eLabel")],kn.prototype,"eLabel",2),g([bn("eWrapper")],kn.prototype,"eWrapper",2),g([bn("eDisplayField")],kn.prototype,"eDisplayField",2),g([bn("eIcon")],kn.prototype,"eIcon",2);var Gn=class e extends wn{constructor(e="default",t=!1){super(`<div class="ag-list ag-${e}-list" role="listbox"></div>`),this.cssIdentifier=e,this.unFocusable=t,this.options=[],this.itemEls=[]}init(){const e=this.getGui();this.addManagedListener(e,"mouseleave",()=>this.clearHighlighted()),this.unFocusable||this.addManagedListener(e,"keydown",this.handleKeyDown.bind(this))}handleKeyDown(e){const t=e.key;switch(t){case Qr.ENTER:if(this.highlightedEl){const e=this.itemEls.indexOf(this.highlightedEl);this.setValueByIndex(e)}else this.setValue(this.getValue());break;case Qr.DOWN:case Qr.UP:e.preventDefault(),this.navigate(t);break;case Qr.PAGE_DOWN:case Qr.PAGE_UP:case Qr.PAGE_HOME:case Qr.PAGE_END:e.preventDefault(),this.navigateToPage(t)}}navigate(e){const t=e===Qr.DOWN;let i;if(this.highlightedEl){let e=this.itemEls.indexOf(this.highlightedEl)+(t?1:-1);e=Math.min(Math.max(e,0),this.itemEls.length-1),i=this.itemEls[e]}else i=this.itemEls[t?0:this.itemEls.length-1];this.highlightItem(i)}navigateToPage(e){if(!this.highlightedEl||0===this.itemEls.length)return;const t=this.itemEls.indexOf(this.highlightedEl),i=this.options.length-1,r=this.itemEls[0].clientHeight,n=Math.floor(this.getGui().clientHeight/r);let s=-1;e===Qr.PAGE_HOME?s=0:e===Qr.PAGE_END?s=i:e===Qr.PAGE_DOWN?s=Math.min(t+n,i):e===Qr.PAGE_UP&&(s=Math.max(t-n,0)),-1!==s&&this.highlightItem(this.itemEls[s])}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){const{value:t,text:i}=e,r=i||t;return this.options.push({value:t,text:r}),this.renderOption(t,r),this.updateIndices(),this}clearOptions(){this.options=[],this.reset(!0),this.itemEls.forEach(e=>{wr(e)}),this.itemEls=[]}updateIndices(){const e=this.getGui().querySelectorAll(".ag-list-item");e.forEach((t,i)=>{si(t,i+1),ni(t,e.length)})}renderOption(e,t){const i=this.gos.getDocument(),r=i.createElement("div");Bt(r,"option"),r.classList.add("ag-list-item",`ag-${this.cssIdentifier}-list-item`);const n=i.createElement("span");r.appendChild(n),n.textContent=t,this.unFocusable||(r.tabIndex=-1),this.itemEls.push(r),this.addManagedListener(r,"mousemove",()=>this.highlightItem(r)),this.addManagedListener(r,"mousedown",t=>{t.preventDefault(),this.setValue(e)}),this.createManagedBean(new vn({getTooltipValue:()=>t,getGui:()=>r,getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>n.scrollWidth>n.clientWidth})),this.getGui().appendChild(r)}setValue(e,t){if(this.value===e)return this.fireItemSelected(),this;if(null==e)return this.reset(t),this;const i=this.options.findIndex(t=>t.value===e);if(-1!==i){const e=this.options[i];this.value=e.value,this.displayValue=e.text,this.highlightItem(this.itemEls[i]),t||this.fireChangeEvent()}return this}setValueByIndex(e){return this.setValue(this.options[e].value)}getValue(){return this.value}getDisplayValue(){return this.displayValue}refreshHighlighted(){this.clearHighlighted();const e=this.options.findIndex(e=>e.value===this.value);-1!==e&&this.highlightItem(this.itemEls[e])}reset(e){this.value=null,this.displayValue=null,this.clearHighlighted(),e||this.fireChangeEvent()}highlightItem(t){if(!br(t))return;this.clearHighlighted(),this.highlightedEl=t,this.highlightedEl.classList.add(e.ACTIVE_CLASS),gi(this.highlightedEl,!0);const i=this.getGui(),{scrollTop:r,clientHeight:n}=i,{offsetTop:s,offsetHeight:o}=t;(s+o>r+n||s<r)&&this.highlightedEl.scrollIntoView({block:"nearest"}),this.unFocusable||this.highlightedEl.focus()}clearHighlighted(){this.highlightedEl&&br(this.highlightedEl)&&(this.highlightedEl.classList.remove(e.ACTIVE_CLASS),gi(this.highlightedEl,!1),this.highlightedEl=null)}fireChangeEvent(){this.dispatchEvent({type:ct.EVENT_FIELD_VALUE_CHANGED}),this.fireItemSelected()}fireItemSelected(){this.dispatchEvent({type:e.EVENT_ITEM_SELECTED})}};Gn.EVENT_ITEM_SELECTED="selectedItem",Gn.ACTIVE_CLASS="ag-active-item",g([le],Gn.prototype,"init",1);var Vn=Gn,Hn=class e extends kn{constructor(e){super(h({pickerAriaLabelKey:"ariaLabelSelectField",pickerAriaLabelValue:"Select Field",pickerType:"ag-list",className:"ag-select",pickerIcon:"smallDown",ariaRole:"combobox"},e))}postConstruct(){super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{options:e,value:t,placeholder:i}=this.config;null!=e&&this.addOptions(e),null!=t&&this.setValue(t,!0),i&&null==t&&(this.eDisplayField.textContent=i),this.addManagedListener(this.eWrapper,"focusout",this.onWrapperFocusOut.bind(this))}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){this.listComponent=this.createBean(new Vn("select",!0)),this.listComponent.setParentComponent(this);const t=this.listComponent.getAriaElement(),i=`ag-select-list-${this.listComponent.getCompId()}`;t.setAttribute("id",i),mi(this.getAriaElement(),t),this.listComponent.addManagedListener(this.listComponent,Vn.EVENT_ITEM_SELECTED,()=>{this.hidePicker(),this.dispatchEvent({type:e.EVENT_ITEM_SELECTED})}),this.listComponent.addManagedListener(this.listComponent,ct.EVENT_FIELD_VALUE_CHANGED,()=>{this.listComponent&&(this.setValue(this.listComponent.getValue(),!1,!0),this.hidePicker())})}createPickerComponent(){return this.listComponent}onKeyDown(e){var t;const{key:i}=e;switch(i===Qr.TAB&&this.hidePicker(),i){case Qr.ENTER:case Qr.UP:case Qr.DOWN:case Qr.PAGE_UP:case Qr.PAGE_DOWN:case Qr.PAGE_HOME:case Qr.PAGE_END:e.preventDefault(),this.isPickerDisplayed?null==(t=this.listComponent)||t.handleKeyDown(e):super.onKeyDown(e);break;case Qr.ESCAPE:super.onKeyDown(e)}}showPicker(){this.listComponent&&(super.showPicker(),this.listComponent.refreshHighlighted())}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){var e;return null==(e=this.listComponent)||e.clearOptions(),this}setValue(e,t,i){if(this.value===e||!this.listComponent)return this;if(i||this.listComponent.setValue(e,!0),this.listComponent.getValue()===this.getValue())return this;let r=this.listComponent.getDisplayValue();return null==r&&this.config.placeholder&&(r=this.config.placeholder),this.eDisplayField.textContent=r,this.setTooltip({newTooltipText:null!=r?r:null,shouldDisplayTooltip:()=>this.eDisplayField.scrollWidth>this.eDisplayField.clientWidth}),super.setValue(e,t)}destroy(){this.listComponent&&(this.destroyBean(this.listComponent),this.listComponent=void 0),super.destroy()}};Hn.EVENT_ITEM_SELECTED="selectedItem";var Bn=Hn,zn=class extends Fn{constructor(e,t,i="text",r="input"){super(e,`\n            <div role="presentation">\n                <div ref="eLabel" class="ag-input-field-label"></div>\n                <div ref="eWrapper" class="ag-wrapper ag-input-wrapper" role="presentation">\n                    <${r} ref="eInput" class="ag-input-field-input"></${r}>\n                </div>\n            </div>`,t),this.inputType=i,this.displayFieldTag=r}postConstruct(){super.postConstruct(),this.setInputType(),this.eLabel.classList.add(`${this.className}-label`),this.eWrapper.classList.add(`${this.className}-input-wrapper`),this.eInput.classList.add(`${this.className}-input`),this.addCssClass("ag-input-field"),this.eInput.id=this.eInput.id||`ag-${this.getCompId()}-input`;const{inputName:e,inputWidth:t}=this.config;null!=e&&this.setInputName(e),null!=t&&this.setInputWidth(t),this.addInputListeners(),this.activateTabIndex([this.eInput])}addInputListeners(){this.addManagedListener(this.eInput,"input",e=>this.setValue(e.target.value))}setInputType(){"input"===this.displayFieldTag&&this.eInput.setAttribute("type",this.inputType)}getInputElement(){return this.eInput}setInputWidth(e){return xr(this.eWrapper,e),this}setInputName(e){return this.getInputElement().setAttribute("name",e),this}getFocusableElement(){return this.eInput}setMaxLength(e){return this.eInput.maxLength=e,this}setInputPlaceholder(e){return Gr(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return Kt(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return lr(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){if(!0===e)Gr(this.eInput,"autocomplete",null);else{const t="string"==typeof e?e:"off";Gr(this.eInput,"autocomplete",t)}return this}};g([bn("eLabel")],zn.prototype,"eLabel",2),g([bn("eWrapper")],zn.prototype,"eWrapper",2),g([bn("eInput")],zn.prototype,"eInput",2);var Un=class extends zn{constructor(e,t="ag-checkbox",i="checkbox"){super(e,t,i),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();const{readOnly:e,passive:t}=this.config;"boolean"==typeof e&&this.setReadOnly(e),"boolean"==typeof t&&this.setPassive(t)}addInputListeners(){this.addManagedListener(this.eInput,"click",this.onCheckboxClick.bind(this)),this.addManagedListener(this.eLabel,"click",this.toggle.bind(this))}getNextValue(){return void 0===this.selected||!this.selected}setPassive(e){this.passive=e}isReadOnly(){return this.readOnly}setReadOnly(e){this.eWrapper.classList.toggle("ag-disabled",e),this.eInput.disabled=e,this.readOnly=e}setDisabled(e){return this.eWrapper.classList.toggle("ag-disabled",e),super.setDisabled(e)}toggle(){if(this.eInput.disabled)return;const e=this.isSelected(),t=this.getNextValue();this.passive?this.dispatchChange(t,e):this.setValue(t)}getValue(){return this.isSelected()}setValue(e,t){return this.refreshSelectedClass(e),this.setSelected(e,t),this}setName(e){return this.getInputElement().name=e,this}isSelected(){return this.selected}setSelected(e,t){this.isSelected()!==e&&(this.previousValue=this.isSelected(),e=this.selected="boolean"==typeof e?e:void 0,this.eInput.checked=e,this.eInput.indeterminate=void 0===e,t||this.dispatchChange(this.selected,this.previousValue))}dispatchChange(e,t,i){this.dispatchEvent({type:ct.EVENT_FIELD_VALUE_CHANGED,selected:e,previousValue:t,event:i});const r=this.getInputElement(),n={type:ct.EVENT_CHECKBOX_CHANGED,id:r.id,name:r.name,selected:e,previousValue:t};this.eventService.dispatchEvent(n)}onCheckboxClick(e){if(this.passive||this.eInput.disabled)return;const t=this.isSelected(),i=this.selected=e.target.checked;this.refreshSelectedClass(i),this.dispatchChange(i,t,e)}refreshSelectedClass(e){this.eWrapper.classList.toggle("ag-checked",!0===e),this.eWrapper.classList.toggle("ag-indeterminate",null==e)}},Wn=class extends Un{constructor(e){super(e,"ag-radio-button","radio")}isSelected(){return this.eInput.checked}toggle(){this.eInput.disabled||this.isSelected()||this.setValue(!0)}addInputListeners(){super.addInputListeners(),this.addManagedListener(this.eventService,ct.EVENT_CHECKBOX_CHANGED,this.onChange.bind(this))}onChange(e){e.selected&&e.name&&this.eInput.name&&this.eInput.name===e.name&&e.id&&this.eInput.id!==e.id&&this.setValue(!1,!0)}},jn=class{constructor(e,t,i){this.localeService=e,this.optionsFactory=t,this.valueFormatter=i}getModelAsString(e){if(!e)return null;const t=null!=e.operator,i=this.localeService.getLocaleTextFunc();if(t){const t=e;let{conditions:r}=t;if(!r){const{condition1:e,condition2:i}=t;r=[e,i]}const n=r.map(e=>this.getModelAsString(e)),s="AND"===t.operator?"andCondition":"orCondition";return n.join(` ${i(s,Rn[s])} `)}if(e.type===$n.BLANK||e.type===$n.NOT_BLANK)return i(e.type,e.type);{const t=e,r=this.optionsFactory.getCustomOption(t.type),{displayKey:n,displayName:s,numberOfInputs:o}=r||{};return n&&s&&0===o?(i(n,s),s):this.conditionToString(t,r)}}updateParams(e){this.optionsFactory=e.optionsFactory}formatValue(e){var t;return this.valueFormatter?null!=(t=this.valueFormatter(null!=e?e:null))?t:"":String(e)}},Kn=class e extends Nn{constructor(){super(...arguments),this.eTypes=[],this.eJoinOperatorPanels=[],this.eJoinOperatorsAnd=[],this.eJoinOperatorsOr=[],this.eConditionBodies=[],this.listener=()=>this.onUiChanged(),this.lastUiCompletePosition=null,this.joinOperatorId=0}getNumberOfInputs(t){const i=this.optionsFactory.getCustomOption(t);if(i){const{numberOfInputs:e}=i;return null!=e?e:1}const r=[e.EMPTY,e.NOT_BLANK,e.BLANK];return t&&r.indexOf(t)>=0?0:t===e.IN_RANGE?2:1}onFloatingFilterChanged(e,t){this.setTypeFromFloatingFilter(e),this.setValueFromFloatingFilter(t),this.onUiChanged(!0)}setTypeFromFloatingFilter(e){this.eTypes.forEach((t,i)=>{0===i?t.setValue(e,!0):t.setValue(this.optionsFactory.getDefaultOption(),!0)})}getModelFromUi(){const e=this.getUiCompleteConditions();return 0===e.length?null:this.maxNumConditions>1&&e.length>1?{filterType:this.getFilterType(),operator:this.getJoinOperator(),condition1:e[0],condition2:e[1],conditions:e}:e[0]}getConditionTypes(){return this.eTypes.map(e=>e.getValue())}getConditionType(e){return this.eTypes[e].getValue()}getJoinOperator(){return 0===this.eJoinOperatorsOr.length?this.defaultJoinOperator:!0===this.eJoinOperatorsOr[0].getValue()?"OR":"AND"}areModelsEqual(e,t){if(!e&&!t)return!0;if(!e&&t||e&&!t)return!1;const i=!e.operator,r=!t.operator;if(!i&&r||i&&!r)return!1;let n;if(i){const i=e,r=t;n=this.areSimpleModelsEqual(i,r)}else{const i=e,r=t;n=i.operator===r.operator&&xe(i.conditions,r.conditions,(e,t)=>this.areSimpleModelsEqual(e,t))}return n}shouldRefresh(e){var t,i,r;const n=this.getModel(),s=n?null!=(t=n.conditions)?t:[n]:null,o=null!=(r=null==(i=e.filterOptions)?void 0:i.map(e=>"string"==typeof e?e:e.displayKey))?r:this.getDefaultFilterOptions();return!(s&&!s.every(e=>void 0!==o.find(t=>t===e.type))||"number"==typeof e.maxNumConditions&&s&&s.length>e.maxNumConditions)}refresh(e){return!!this.shouldRefresh(e)&&(!!super.refresh(e)&&(this.setParams(e),this.removeConditionsAndOperators(0),this.createOption(),this.setModel(this.getModel()),!0))}setModelIntoUi(e){if(e.operator){let t=e;t.conditions||(t.conditions=[t.condition1,t.condition2]);const i=this.validateAndUpdateConditions(t.conditions),r=this.getNumConditions();if(i<r)this.removeConditionsAndOperators(i);else if(i>r)for(let e=r;e<i;e++)this.createJoinOperatorPanel(),this.createOption();const n="OR"===t.operator;this.eJoinOperatorsAnd.forEach(e=>e.setValue(!n,!0)),this.eJoinOperatorsOr.forEach(e=>e.setValue(n,!0)),t.conditions.forEach((e,t)=>{this.eTypes[t].setValue(e.type,!0),this.setConditionIntoUi(e,t)})}else{const t=e;this.getNumConditions()>1&&this.removeConditionsAndOperators(1),this.eTypes[0].setValue(t.type,!0),this.setConditionIntoUi(t,0)}return this.lastUiCompletePosition=this.getNumConditions()-1,this.createMissingConditionsAndOperators(),this.onUiChanged(),dn.resolve()}validateAndUpdateConditions(e){let t=e.length;return t>this.maxNumConditions&&(e.splice(this.maxNumConditions),U('Filter Model contains more conditions than "filterParams.maxNumConditions". Additional conditions have been ignored.'),t=this.maxNumConditions),t}doesFilterPass(e){var t;const i=this.getModel();if(null==i)return!0;const{operator:r}=i,n=[];if(r){const e=i;n.push(...null!=(t=e.conditions)?t:[])}else n.push(i);return n[r&&"OR"===r?"some":"every"](t=>this.individualConditionPasses(e,t))}setParams(e){super.setParams(e),this.setNumConditions(e),this.defaultJoinOperator=this.getDefaultJoinOperator(e.defaultJoinOperator),this.filterPlaceholder=e.filterPlaceholder,this.optionsFactory=new Mn,this.optionsFactory.init(e,this.getDefaultFilterOptions()),this.createFilterListOptions(),this.createOption(),this.createMissingConditionsAndOperators(),this.isReadOnly()&&this.eFilterBody.setAttribute("tabindex","-1")}setNumConditions(e){var t,i;null!=e.suppressAndOrCondition&&U('Since v29.2 "filterParams.suppressAndOrCondition" is deprecated. Use "filterParams.maxNumConditions = 1" instead.'),null!=e.alwaysShowBothConditions&&U('Since v29.2 "filterParams.alwaysShowBothConditions" is deprecated. Use "filterParams.numAlwaysVisibleConditions = 2" instead.'),this.maxNumConditions=null!=(t=e.maxNumConditions)?t:e.suppressAndOrCondition?1:2,this.maxNumConditions<1&&(U('"filterParams.maxNumConditions" must be greater than or equal to zero.'),this.maxNumConditions=1),this.numAlwaysVisibleConditions=null!=(i=e.numAlwaysVisibleConditions)?i:e.alwaysShowBothConditions?2:1,this.numAlwaysVisibleConditions<1&&(U('"filterParams.numAlwaysVisibleConditions" must be greater than or equal to zero.'),this.numAlwaysVisibleConditions=1),this.numAlwaysVisibleConditions>this.maxNumConditions&&(U('"filterParams.numAlwaysVisibleConditions" cannot be greater than "filterParams.maxNumConditions".'),this.numAlwaysVisibleConditions=this.maxNumConditions)}createOption(){const e=this.createManagedBean(new Bn);this.eTypes.push(e),e.addCssClass("ag-filter-select"),this.eFilterBody.appendChild(e.getGui());const t=this.createValueElement();this.eConditionBodies.push(t),this.eFilterBody.appendChild(t),this.putOptionsIntoDropdown(e),this.resetType(e);const i=this.getNumConditions()-1;this.forEachPositionInput(i,e=>this.resetInput(e)),this.addChangedListeners(e,i)}createJoinOperatorPanel(){const e=document.createElement("div");this.eJoinOperatorPanels.push(e),e.classList.add("ag-filter-condition");const t=this.createJoinOperator(this.eJoinOperatorsAnd,e,"and"),i=this.createJoinOperator(this.eJoinOperatorsOr,e,"or");this.eFilterBody.appendChild(e);const r=this.eJoinOperatorPanels.length-1,n=this.joinOperatorId++;this.resetJoinOperatorAnd(t,r,n),this.resetJoinOperatorOr(i,r,n),this.isReadOnly()||(t.onValueChange(this.listener),i.onValueChange(this.listener))}createJoinOperator(e,t,i){const r=this.createManagedBean(new Wn);return e.push(r),r.addCssClass("ag-filter-condition-operator"),r.addCssClass(`ag-filter-condition-operator-${i}`),t.appendChild(r.getGui()),r}getDefaultJoinOperator(e){return"AND"===e||"OR"===e?e:"AND"}createFilterListOptions(){const e=this.optionsFactory.getFilterOptions();this.filterListOptions=e.map(e=>"string"==typeof e?this.createBoilerplateListOption(e):this.createCustomListOption(e))}putOptionsIntoDropdown(e){this.filterListOptions.forEach(t=>{e.addOption(t)}),e.setDisabled(this.filterListOptions.length<=1)}createBoilerplateListOption(e){return{value:e,text:this.translate(e)}}createCustomListOption(e){const{displayKey:t}=e,i=this.optionsFactory.getCustomOption(e.displayKey);return{value:t,text:i?this.localeService.getLocaleTextFunc()(i.displayKey,i.displayName):this.translate(t)}}isAllowTwoConditions(){return this.maxNumConditions>=2}createBodyTemplate(){return""}getCssIdentifier(){return"simple-filter"}updateUiVisibility(){const e=this.getJoinOperator();this.updateNumConditions(),this.updateConditionStatusesAndValues(this.lastUiCompletePosition,e)}updateNumConditions(){var e;let t=-1,i=!0;for(let e=0;e<this.getNumConditions();e++)this.isConditionUiComplete(e)?t=e:i=!1;if(this.shouldAddNewConditionAtEnd(i))this.createJoinOperatorPanel(),this.createOption();else{const i=null!=(e=this.lastUiCompletePosition)?e:this.getNumConditions()-2;if(t<i){this.removeConditionsAndOperators(i+1);const e=t+1,r=i-e;r>0&&this.removeConditionsAndOperators(e,r),this.createMissingConditionsAndOperators()}}this.lastUiCompletePosition=t}updateConditionStatusesAndValues(e,t){this.eTypes.forEach((t,i)=>{const r=this.isConditionDisabled(i,e);t.setDisabled(r||this.filterListOptions.length<=1),1===i&&(lr(this.eJoinOperatorPanels[0],r),this.eJoinOperatorsAnd[0].setDisabled(r),this.eJoinOperatorsOr[0].setDisabled(r))}),this.eConditionBodies.forEach((e,t)=>{or(e,this.isConditionBodyVisible(t))});const i="OR"===(null!=t?t:this.getJoinOperator());this.eJoinOperatorsAnd.forEach((e,t)=>{e.setValue(!i,!0)}),this.eJoinOperatorsOr.forEach((e,t)=>{e.setValue(i,!0)}),this.forEachInput((t,i,r,n)=>{this.setElementDisplayed(t,i<n),this.setElementDisabled(t,this.isConditionDisabled(r,e))}),this.resetPlaceholder()}shouldAddNewConditionAtEnd(e){return e&&this.getNumConditions()<this.maxNumConditions&&!this.isReadOnly()}removeConditionsAndOperators(e,t){if(e>=this.getNumConditions())return;this.removeComponents(this.eTypes,e,t),this.removeElements(this.eConditionBodies,e,t),this.removeValueElements(e,t);const i=Math.max(e-1,0);this.removeElements(this.eJoinOperatorPanels,i,t),this.removeComponents(this.eJoinOperatorsAnd,i,t),this.removeComponents(this.eJoinOperatorsOr,i,t)}removeElements(e,t,i){this.removeItems(e,t,i).forEach(e=>wr(e))}removeComponents(e,t,i){this.removeItems(e,t,i).forEach(e=>{wr(e.getGui()),this.destroyBean(e)})}removeItems(e,t,i){return null==i?e.splice(t):e.splice(t,i)}afterGuiAttached(e){if(super.afterGuiAttached(e),this.resetPlaceholder(),!(null==e?void 0:e.suppressFocus))if(this.isReadOnly())this.eFilterBody.focus();else{const e=this.getInputs(0)[0];if(!e)return;e instanceof zn&&e.getInputElement().focus()}}afterGuiDetached(){super.afterGuiDetached();const e=this.getModel();this.resetUiToActiveModel(e);let t=-1,i=-1,r=!1;const n=this.getJoinOperator();for(let e=this.getNumConditions()-1;e>=0;e--)if(this.isConditionUiComplete(e))-1===t&&(t=e,i=e);else{const n=e<t;(e>=this.numAlwaysVisibleConditions&&!this.isConditionUiComplete(e-1)||n)&&(this.removeConditionsAndOperators(e,1),r=!0,n&&i--)}let s=!1;this.getNumConditions()<this.numAlwaysVisibleConditions&&(this.createMissingConditionsAndOperators(),s=!0),this.shouldAddNewConditionAtEnd(i===this.getNumConditions()-1)&&(this.createJoinOperatorPanel(),this.createOption(),s=!0),s&&this.updateConditionStatusesAndValues(i,n),r&&this.updateJoinOperatorsDisabled(),this.lastUiCompletePosition=i}getPlaceholderText(e,t){let i=this.translate(e);if(K(this.filterPlaceholder)){const e=this.filterPlaceholder,r=this.eTypes[t].getValue();i=e({filterOptionKey:r,filterOption:this.translate(r),placeholder:i})}else"string"==typeof this.filterPlaceholder&&(i=this.filterPlaceholder);return i}resetPlaceholder(){const e=this.localeService.getLocaleTextFunc();this.forEachInput((t,i,r,n)=>{if(!(t instanceof zn))return;const s=0===i&&n>1?"inRangeStart":0===i?"filterOoo":"inRangeEnd",o=0===i&&n>1?e("ariaFilterFromValue","Filter from value"):0===i?e("ariaFilterValue","Filter Value"):e("ariaFilterToValue","Filter to Value");t.setInputPlaceholder(this.getPlaceholderText(s,r)),t.setInputAriaLabel(o)})}setElementValue(e,t,i){e instanceof zn&&e.setValue(null!=t?String(t):null,!0)}setElementDisplayed(e,t){e instanceof wn&&or(e.getGui(),t)}setElementDisabled(e,t){e instanceof wn&&lr(e.getGui(),t)}attachElementOnChange(e,t){e instanceof zn&&e.onValueChange(t)}forEachInput(e){this.getConditionTypes().forEach((t,i)=>{this.forEachPositionTypeInput(i,t,e)})}forEachPositionInput(e,t){const i=this.getConditionType(e);this.forEachPositionTypeInput(e,i,t)}forEachPositionTypeInput(e,t,i){const r=this.getNumberOfInputs(t),n=this.getInputs(e);for(let t=0;t<n.length;t++){const s=n[t];null!=s&&i(s,t,e,r)}}isConditionDisabled(e,t){return!!this.isReadOnly()||0!==e&&e>t+1}isConditionBodyVisible(e){const t=this.getConditionType(e);return this.getNumberOfInputs(t)>0}isConditionUiComplete(t){return!(t>=this.getNumConditions())&&(this.getConditionType(t)!==e.EMPTY&&!this.getValues(t).some(e=>null==e))}getNumConditions(){return this.eTypes.length}getUiCompleteConditions(){const e=[];for(let t=0;t<this.getNumConditions();t++)this.isConditionUiComplete(t)&&e.push(this.createCondition(t));return e}createMissingConditionsAndOperators(){if(!this.isReadOnly())for(let e=this.getNumConditions();e<this.numAlwaysVisibleConditions;e++)this.createJoinOperatorPanel(),this.createOption()}resetUiToDefaults(e){return this.removeConditionsAndOperators(this.isReadOnly()?1:this.numAlwaysVisibleConditions),this.eTypes.forEach(e=>this.resetType(e)),this.eJoinOperatorsAnd.forEach((e,t)=>this.resetJoinOperatorAnd(e,t,this.joinOperatorId+t)),this.eJoinOperatorsOr.forEach((e,t)=>this.resetJoinOperatorOr(e,t,this.joinOperatorId+t)),this.joinOperatorId++,this.forEachInput(e=>this.resetInput(e)),this.resetPlaceholder(),this.createMissingConditionsAndOperators(),this.lastUiCompletePosition=null,e||this.onUiChanged(),dn.resolve()}resetType(e){const t=this.localeService.getLocaleTextFunc()("ariaFilteringOperator","Filtering operator");e.setValue(this.optionsFactory.getDefaultOption(),!0).setAriaLabel(t).setDisabled(this.isReadOnly()||this.filterListOptions.length<=1)}resetJoinOperatorAnd(e,t,i){this.resetJoinOperator(e,t,this.isDefaultOperator("AND"),this.translate("andCondition"),i)}resetJoinOperatorOr(e,t,i){this.resetJoinOperator(e,t,this.isDefaultOperator("OR"),this.translate("orCondition"),i)}resetJoinOperator(e,t,i,r,n){this.updateJoinOperatorDisabled(e.setValue(i,!0).setName(`ag-simple-filter-and-or-${this.getCompId()}-${n}`).setLabel(r),t)}updateJoinOperatorsDisabled(){this.eJoinOperatorsAnd.forEach((e,t)=>this.updateJoinOperatorDisabled(e,t)),this.eJoinOperatorsOr.forEach((e,t)=>this.updateJoinOperatorDisabled(e,t))}updateJoinOperatorDisabled(e,t){e.setDisabled(this.isReadOnly()||t>0)}resetInput(e){this.setElementValue(e,null),this.setElementDisabled(e,this.isReadOnly())}setConditionIntoUi(e,t){const i=this.mapValuesFromModel(e);this.forEachInput((e,r,n,s)=>{n===t&&this.setElementValue(e,null!=i[r]?i[r]:null)})}setValueFromFloatingFilter(e){this.forEachInput((t,i,r,n)=>{this.setElementValue(t,0===i&&0===r?e:null,!0)})}isDefaultOperator(e){return e===this.defaultJoinOperator}addChangedListeners(e,t){this.isReadOnly()||(e.onValueChange(this.listener),this.forEachPositionInput(t,e=>{this.attachElementOnChange(e,this.listener)}))}individualConditionPasses(e,t){const i=this.getCellValue(e.node),r=this.mapValuesFromModel(t),n=this.optionsFactory.getCustomOption(t.type),s=this.evaluateCustomFilter(n,r,i);return null!=s?s:null==i?this.evaluateNullValue(t.type):this.evaluateNonNullValue(r,i,t,e)}evaluateCustomFilter(e,t,i){if(null==e)return;const{predicate:r}=e;return null==r||t.some(e=>null==e)?void 0:r(t,i)}isBlank(e){return null==e||"string"==typeof e&&0===e.trim().length}hasInvalidInputs(){return!1}};Kn.EMPTY="empty",Kn.BLANK="blank",Kn.NOT_BLANK="notBlank",Kn.EQUALS="equals",Kn.NOT_EQUAL="notEqual",Kn.LESS_THAN="lessThan",Kn.LESS_THAN_OR_EQUAL="lessThanOrEqual",Kn.GREATER_THAN="greaterThan",Kn.GREATER_THAN_OR_EQUAL="greaterThanOrEqual",Kn.IN_RANGE="inRange",Kn.CONTAINS="contains",Kn.NOT_CONTAINS="notContains",Kn.STARTS_WITH="startsWith",Kn.ENDS_WITH="endsWith";var $n=Kn,qn=class e extends $n{setParams(e){super.setParams(e),this.scalarFilterParams=e}evaluateNullValue(t){switch(t){case e.EQUALS:case e.NOT_EQUAL:if(this.scalarFilterParams.includeBlanksInEquals)return!0;break;case e.GREATER_THAN:case e.GREATER_THAN_OR_EQUAL:if(this.scalarFilterParams.includeBlanksInGreaterThan)return!0;break;case e.LESS_THAN:case e.LESS_THAN_OR_EQUAL:if(this.scalarFilterParams.includeBlanksInLessThan)return!0;break;case e.IN_RANGE:if(this.scalarFilterParams.includeBlanksInRange)return!0;break;case e.BLANK:return!0;case e.NOT_BLANK:return!1}return!1}evaluateNonNullValue(t,i,r){const n=this.comparator(),s=null!=t[0]?n(t[0],i):0;switch(r.type){case e.EQUALS:return 0===s;case e.NOT_EQUAL:return 0!==s;case e.GREATER_THAN:return s>0;case e.GREATER_THAN_OR_EQUAL:return s>=0;case e.LESS_THAN:return s<0;case e.LESS_THAN_OR_EQUAL:return s<=0;case e.IN_RANGE:{const e=n(t[1],i);return this.scalarFilterParams.inRangeInclusive?s>=0&&e<=0:s>0&&e<0}case e.BLANK:return this.isBlank(i);case e.NOT_BLANK:return!this.isBlank(i);default:return console.warn('AG Grid: Unexpected type of filter "'+r.type+'", it looks like the filter was configured with incorrect Filter Options'),!0}}},Yn=1/0,Qn=class extends jn{constructor(e,t,i){super(t,i),this.dateFilterParams=e}conditionToString(e,t){const{type:i}=e,{numberOfInputs:r}=t||{},n=i==$n.IN_RANGE||2===r,s=Ji(e.dateFrom),o=Ji(e.dateTo),a=this.dateFilterParams.inRangeFloatingFilterDateFormat;return n?`${null!==s?Zi(s,a):"null"}-${null!==o?Zi(o,a):"null"}`:null!=s?Zi(s,a):`${i}`}updateParams(e){super.updateParams(e),this.dateFilterParams=e.dateFilterParams}},Xn=class e extends qn{constructor(){super("dateFilter"),this.eConditionPanelsFrom=[],this.eConditionPanelsTo=[],this.dateConditionFromComps=[],this.dateConditionToComps=[],this.minValidYear=1e3,this.maxValidYear=Yn,this.minValidDate=null,this.maxValidDate=null}afterGuiAttached(e){super.afterGuiAttached(e),this.dateConditionFromComps[0].afterGuiAttached(e)}mapValuesFromModel(e){const{dateFrom:t,dateTo:i,type:r}=e||{};return[t&&Ji(t)||null,i&&Ji(i)||null].slice(0,this.getNumberOfInputs(r))}comparator(){return this.dateFilterParams.comparator?this.dateFilterParams.comparator:this.defaultComparator.bind(this)}defaultComparator(e,t){return null==t||t<e?-1:t>e?1:0}setParams(e){this.dateFilterParams=e,super.setParams(e);const t=(t,i)=>{if(null!=e[t]){if(!isNaN(e[t]))return null==e[t]?i:Number(e[t]);console.warn(`AG Grid: DateFilter ${t} is not a number`)}return i};this.minValidYear=t("minValidYear",1e3),this.maxValidYear=t("maxValidYear",Yn),this.minValidYear>this.maxValidYear&&console.warn("AG Grid: DateFilter minValidYear should be <= maxValidYear"),e.minValidDate?this.minValidDate=e.minValidDate instanceof Date?e.minValidDate:Ji(e.minValidDate):this.minValidDate=null,e.maxValidDate?this.maxValidDate=e.maxValidDate instanceof Date?e.maxValidDate:Ji(e.maxValidDate):this.maxValidDate=null,this.minValidDate&&this.maxValidDate&&this.minValidDate>this.maxValidDate&&console.warn("AG Grid: DateFilter minValidDate should be <= maxValidDate"),this.filterModelFormatter=new Qn(this.dateFilterParams,this.localeService,this.optionsFactory)}createDateCompWrapper(e){const t=new Tn(this.getContext(),this.userComponentFactory,{onDateChanged:()=>this.onUiChanged(),filterParams:this.dateFilterParams},e);return this.addDestroyFunc(()=>t.destroy()),t}setElementValue(e,t){e.setDate(t)}setElementDisplayed(e,t){e.setDisplayed(t)}setElementDisabled(e,t){e.setDisabled(t)}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}createValueElement(){const e=this.gos.getDocument().createElement("div");return e.classList.add("ag-filter-body"),this.createFromToElement(e,this.eConditionPanelsFrom,this.dateConditionFromComps,"from"),this.createFromToElement(e,this.eConditionPanelsTo,this.dateConditionToComps,"to"),e}createFromToElement(e,t,i,r){const n=this.gos.getDocument().createElement("div");n.classList.add(`ag-filter-${r}`),n.classList.add(`ag-filter-date-${r}`),t.push(n),e.appendChild(n),i.push(this.createDateCompWrapper(n))}removeValueElements(e,t){this.removeDateComps(this.dateConditionFromComps,e,t),this.removeDateComps(this.dateConditionToComps,e,t),this.removeItems(this.eConditionPanelsFrom,e,t),this.removeItems(this.eConditionPanelsTo,e,t)}removeDateComps(e,t,i){this.removeItems(e,t,i).forEach(e=>e.destroy())}isValidDateValue(e){if(null===e)return!1;if(this.minValidDate){if(e<this.minValidDate)return!1}else if(e.getUTCFullYear()<this.minValidYear)return!1;if(this.maxValidDate){if(e>this.maxValidDate)return!1}else if(e.getUTCFullYear()>this.maxValidYear)return!1;return!0}isConditionUiComplete(e){if(!super.isConditionUiComplete(e))return!1;let t=!0;return this.forEachInput((i,r,n,s)=>{n!==e||!t||r>=s||(t=t&&this.isValidDateValue(i.getDate()))}),t}areSimpleModelsEqual(e,t){return e.dateFrom===t.dateFrom&&e.dateTo===t.dateTo&&e.type===t.type}getFilterType(){return"date"}createCondition(e){const t=this.getConditionType(e),i={},r=this.getValues(e);return r.length>0&&(i.dateFrom=Qi(r[0])),r.length>1&&(i.dateTo=Qi(r[1])),h({dateFrom:null,dateTo:null,filterType:this.getFilterType(),type:t},i)}resetPlaceholder(){const e=this.localeService.getLocaleTextFunc(),t=this.translate("dateFormatOoo"),i=e("ariaFilterValue","Filter Value");this.forEachInput(e=>{e.setInputPlaceholder(t),e.setInputAriaLabel(i)})}getInputs(e){return e>=this.dateConditionFromComps.length?[null,null]:[this.dateConditionFromComps[e],this.dateConditionToComps[e]]}getValues(e){const t=[];return this.forEachPositionInput(e,(e,i,r,n)=>{i<n&&t.push(e.getDate())}),t}translate(e){return e===qn.LESS_THAN?super.translate("before"):e===qn.GREATER_THAN?super.translate("after"):super.translate(e)}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}};Xn.DEFAULT_FILTER_OPTIONS=[qn.EQUALS,qn.NOT_EQUAL,qn.LESS_THAN,qn.GREATER_THAN,qn.IN_RANGE,qn.BLANK,qn.NOT_BLANK],g([he("userComponentFactory")],Xn.prototype,"userComponentFactory",2);var Zn=Xn,Jn=class extends wn{getDefaultDebounceMs(){return 0}destroy(){super.destroy()}isEventFromFloatingFilter(e){return e&&e.afterFloatingFilter}isEventFromDataChange(e){return null==e?void 0:e.afterDataChange}getLastType(){return this.lastType}isReadOnly(){return this.readOnly}setLastTypeFromModel(e){if(!e)return void(this.lastType=this.optionsFactory.getDefaultOption());let t;t=e.operator?e.conditions[0]:e,this.lastType=t.type}canWeEditAfterModelFromParentFilter(e){if(!e)return this.isTypeEditable(this.lastType);if(e.operator)return!1;const t=e;return this.isTypeEditable(t.type)}init(e){this.setSimpleParams(e,!1)}setSimpleParams(e,t=!0){this.optionsFactory=new Mn,this.optionsFactory.init(e.filterParams,this.getDefaultFilterOptions()),t||(this.lastType=this.optionsFactory.getDefaultOption()),this.readOnly=!!e.filterParams.readOnly;const i=this.isTypeEditable(this.optionsFactory.getDefaultOption());this.setEditable(i)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.setSimpleParams(e)}doesFilterHaveSingleInput(e){const t=this.optionsFactory.getCustomOption(e),{numberOfInputs:i}=t||{};return null==i||1==i}isTypeEditable(e){const t=[$n.IN_RANGE,$n.EMPTY,$n.BLANK,$n.NOT_BLANK];return!!e&&!this.isReadOnly()&&this.doesFilterHaveSingleInput(e)&&t.indexOf(e)<0}getAriaLabel(e){return`${this.columnModel.getDisplayNameForColumn(e.column,"header",!0)} ${this.localeService.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`}};g([he("columnModel")],Jn.prototype,"columnModel",2);var es=class extends Jn{constructor(){super('\n            <div class="ag-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eReadOnlyText"></ag-input-text-field>\n                <div ref="eDateWrapper" style="display: flex;"></div>\n            </div>')}getDefaultFilterOptions(){return Zn.DEFAULT_FILTER_OPTIONS}init(e){super.init(e),this.params=e,this.filterParams=e.filterParams,this.createDateComponent(),this.filterModelFormatter=new Qn(this.filterParams,this.localeService,this.optionsFactory);const t=this.localeService.getLocaleTextFunc();this.eReadOnlyText.setDisabled(!0).setInputAriaLabel(t("ariaDateFilterInput","Date Filter Input"))}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.params=e,this.filterParams=e.filterParams,this.updateDateComponent(),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory,dateFilterParams:this.filterParams}),this.updateCompOnModelChange(e.currentParentModel())}updateCompOnModelChange(e){const t=!this.isReadOnly()&&this.canWeEditAfterModelFromParentFilter(e);if(this.setEditable(t),t){if(e){const t=e;this.dateComp.setDate(Ji(t.dateFrom))}else this.dateComp.setDate(null);this.eReadOnlyText.setValue("")}else this.eReadOnlyText.setValue(this.filterModelFormatter.getModelAsString(e)),this.dateComp.setDate(null)}setEditable(e){or(this.eDateWrapper,e),or(this.eReadOnlyText.getGui(),!e)}onParentModelChanged(e,t){this.isEventFromFloatingFilter(t)||this.isEventFromDataChange(t)||(super.setLastTypeFromModel(e),this.updateCompOnModelChange(e))}onDateChanged(){const e=Qi(this.dateComp.getDate());this.params.parentFilterInstance(t=>{if(t){const i=Ji(e);t.onFloatingFilterChanged(this.getLastType()||null,i)}})}getDateComponentParams(){const e=Nn.getDebounceMs(this.params.filterParams,this.getDefaultDebounceMs());return{onDateChanged:Z(this.onDateChanged.bind(this),e),filterParams:this.params.column.getColDef().filterParams}}createDateComponent(){this.dateComp=new Tn(this.getContext(),this.userComponentFactory,this.getDateComponentParams(),this.eDateWrapper,e=>{e.setInputAriaLabel(this.getAriaLabel(this.params))}),this.addDestroyFunc(()=>this.dateComp.destroy())}updateDateComponent(){const e=this.gos.addGridCommonParams(this.getDateComponentParams());this.dateComp.updateParams(e)}getFilterModelFormatter(){return this.filterModelFormatter}};g([he("userComponentFactory")],es.prototype,"userComponentFactory",2),g([bn("eReadOnlyText")],es.prototype,"eReadOnlyText",2),g([bn("eDateWrapper")],es.prototype,"eDateWrapper",2);var ts=class extends wn{constructor(){super('\n            <div class="ag-filter-filter">\n                <ag-input-text-field class="ag-date-filter" ref="eDateInput"></ag-input-text-field>\n            </div>')}destroy(){super.destroy()}init(e){this.params=e,this.setParams(e);const t=this.eDateInput.getInputElement();this.addManagedListener(t,"mousedown",()=>{this.eDateInput.isDisabled()||this.usingSafariDatePicker||t.focus()}),this.addManagedListener(t,"input",e=>{e.target===this.gos.getActiveDomElement()&&(this.eDateInput.isDisabled()||this.params.onDateChanged())})}setParams(e){const t=this.eDateInput.getInputElement(),i=this.shouldUseBrowserDatePicker(e);this.usingSafariDatePicker=i&&Ri(),t.type=i?"date":"text";const{minValidYear:r,maxValidYear:n,minValidDate:s,maxValidDate:o}=e.filterParams||{};if(s&&r&&U("DateFilter should not have both minValidDate and minValidYear parameters set at the same time! minValidYear will be ignored."),o&&n&&U("DateFilter should not have both maxValidDate and maxValidYear parameters set at the same time! maxValidYear will be ignored."),s&&o){const[e,t]=[s,o].map(e=>e instanceof Date?e:Ji(e));e&&t&&e.getTime()>t.getTime()&&U("DateFilter parameter minValidDate should always be lower than or equal to parameter maxValidDate.")}s?s instanceof Date?t.min=Zi(s):t.min=s:r&&(t.min=`${r}-01-01`),o?o instanceof Date?t.max=Zi(o):t.max=o:n&&(t.max=`${n}-12-31`)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams(e)}getDate(){return Ji(this.eDateInput.getValue())}setDate(e){this.eDateInput.setValue(Qi(e,!1))}setInputPlaceholder(e){this.eDateInput.setInputPlaceholder(e)}setInputAriaLabel(e){this.eDateInput.setAriaLabel(e)}setDisabled(e){this.eDateInput.setDisabled(e)}afterGuiAttached(e){e&&e.suppressFocus||this.eDateInput.getInputElement().focus()}shouldUseBrowserDatePicker(e){return e.filterParams&&null!=e.filterParams.browserDatePicker?e.filterParams.browserDatePicker:Pi()||xi()||Ri()&&_i()>=14.1}};g([bn("eDateInput")],ts.prototype,"eDateInput",2);var is=class extends zn{constructor(e,t="ag-text-field",i="text"){super(e,t,i)}postConstruct(){super.postConstruct(),this.config.allowedCharPattern&&this.preventDisallowedCharacters()}setValue(e,t){return this.eInput.value!==e&&(this.eInput.value=y(e)?e:""),super.setValue(e,t)}setStartValue(e){this.setValue(e,!0)}preventDisallowedCharacters(){const e=new RegExp(`[${this.config.allowedCharPattern}]`);this.addManagedListener(this.eInput,"keydown",t=>{Xr(t)&&t.key&&!e.test(t.key)&&t.preventDefault()}),this.addManagedListener(this.eInput,"paste",t=>{var i;const r=null==(i=t.clipboardData)?void 0:i.getData("text");r&&r.split("").some(t=>!e.test(t))&&t.preventDefault()})}},rs=class extends is{constructor(e){super(e,"ag-number-field","number")}postConstruct(){super.postConstruct(),this.addManagedListener(this.eInput,"blur",()=>{const e=parseFloat(this.eInput.value),t=isNaN(e)?"":this.normalizeValue(e.toString());this.value!==t&&this.setValue(t)}),this.addManagedListener(this.eInput,"wheel",this.onWheel.bind(this)),this.eInput.step="any";const{precision:e,min:t,max:i,step:r}=this.config;"number"==typeof e&&this.setPrecision(e),"number"==typeof t&&this.setMin(t),"number"==typeof i&&this.setMax(i),"number"==typeof r&&this.setStep(r)}onWheel(e){this.gos.getActiveDomElement()===this.eInput&&e.preventDefault()}normalizeValue(e){if(""===e)return"";null!=this.precision&&(e=this.adjustPrecision(e));const t=parseFloat(e);return null!=this.min&&t<this.min?e=this.min.toString():null!=this.max&&t>this.max&&(e=this.max.toString()),e}adjustPrecision(e,t){if(null==this.precision)return e;if(t){const t=parseFloat(e).toFixed(this.precision);return parseFloat(t).toString()}const i=String(e).split(".");if(i.length>1){if(i[1].length<=this.precision)return e;if(this.precision>0)return`${i[0]}.${i[1].slice(0,this.precision)}`}return i[0]}setMin(e){return this.min===e||(this.min=e,Gr(this.eInput,"min",e)),this}setMax(e){return this.max===e||(this.max=e,Gr(this.eInput,"max",e)),this}setPrecision(e){return this.precision=e,this}setStep(e){return this.step===e||(this.step=e,Gr(this.eInput,"step",e)),this}setValue(e,t){return this.setValueOrInputValue(e=>super.setValue(e,t),()=>this,e)}setStartValue(e){return this.setValueOrInputValue(e=>super.setValue(e,!0),e=>{this.eInput.value=e},e)}setValueOrInputValue(e,t,i){if(y(i)){let r=this.isScientificNotation(i);if(r&&this.eInput.validity.valid)return e(i);if(r||(r=(i=this.adjustPrecision(i))!=this.normalizeValue(i)),r)return t(i)}return e(i)}getValue(){if(!this.eInput.validity.valid)return;const e=this.eInput.value;return this.isScientificNotation(e)?this.adjustPrecision(e,!0):super.getValue()}isScientificNotation(e){return"string"==typeof e&&e.includes("e")}},ns=class extends jn{conditionToString(e,t){const{numberOfInputs:i}=t||{};return e.type==$n.IN_RANGE||2===i?`${this.formatValue(e.filter)}-${this.formatValue(e.filterTo)}`:null!=e.filter?this.formatValue(e.filter):`${e.type}`}};function ss(e){const{allowedCharPattern:t}=null!=e?e:{};return null!=t?t:null}var os=class e extends qn{constructor(){super("numberFilter"),this.eValuesFrom=[],this.eValuesTo=[]}refresh(e){return this.numberFilterParams.allowedCharPattern===e.allowedCharPattern&&super.refresh(e)}mapValuesFromModel(e){const{filter:t,filterTo:i,type:r}=e||{};return[this.processValue(t),this.processValue(i)].slice(0,this.getNumberOfInputs(r))}getDefaultDebounceMs(){return 500}comparator(){return(e,t)=>e===t?0:e<t?1:-1}setParams(e){this.numberFilterParams=e,super.setParams(e),this.filterModelFormatter=new ns(this.localeService,this.optionsFactory,this.numberFilterParams.numberFormatter)}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}setElementValue(e,t,i){const r=!i&&this.numberFilterParams.numberFormatter?this.numberFilterParams.numberFormatter(null!=t?t:null):t;super.setElementValue(e,r)}createValueElement(){const e=ss(this.numberFilterParams),t=document.createElement("div");return t.classList.add("ag-filter-body"),Bt(t,"presentation"),this.createFromToElement(t,this.eValuesFrom,"from",e),this.createFromToElement(t,this.eValuesTo,"to",e),t}createFromToElement(e,t,i,r){const n=this.createManagedBean(r?new is({allowedCharPattern:r}):new rs);n.addCssClass(`ag-filter-${i}`),n.addCssClass("ag-filter-filter"),t.push(n),e.appendChild(n.getGui())}removeValueElements(e,t){this.removeComponents(this.eValuesFrom,e,t),this.removeComponents(this.eValuesTo,e,t)}getValues(e){const t=[];return this.forEachPositionInput(e,(e,i,r,n)=>{i<n&&t.push(this.processValue(this.stringToFloat(e.getValue())))}),t}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getFilterType(){return"number"}processValue(e){return null==e||isNaN(e)?null:e}stringToFloat(e){if("number"==typeof e)return e;let t=C(e);return null!=t&&""===t.trim()&&(t=null),this.numberFilterParams.numberParser?this.numberFilterParams.numberParser(t):null==t||"-"===t.trim()?null:parseFloat(t)}createCondition(e){const t=this.getConditionType(e),i={filterType:this.getFilterType(),type:t},r=this.getValues(e);return r.length>0&&(i.filter=r[0]),r.length>1&&(i.filterTo=r[1]),i}getInputs(e){return e>=this.eValuesFrom.length?[null,null]:[this.eValuesFrom[e],this.eValuesTo[e]]}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}hasInvalidInputs(){let e=!1;return this.forEachInput(t=>{t.getInputElement().validity.valid||(e=!0)}),e}};os.DEFAULT_FILTER_OPTIONS=[qn.EQUALS,qn.NOT_EQUAL,qn.GREATER_THAN,qn.GREATER_THAN_OR_EQUAL,qn.LESS_THAN,qn.LESS_THAN_OR_EQUAL,qn.IN_RANGE,qn.BLANK,qn.NOT_BLANK];var as=os,ls=class extends jn{conditionToString(e,t){const{numberOfInputs:i}=t||{};return e.type==$n.IN_RANGE||2===i?`${e.filter}-${e.filterTo}`:null!=e.filter?`${e.filter}`:`${e.type}`}},cs=class e extends $n{constructor(){super("textFilter"),this.eValuesFrom=[],this.eValuesTo=[]}static trimInput(e){const t=e&&e.trim();return""===t?e:t}getDefaultDebounceMs(){return 500}setParams(t){this.textFilterParams=t,super.setParams(t),this.matcher=this.getTextMatcher(),this.formatter=this.textFilterParams.textFormatter||(this.textFilterParams.caseSensitive?e.DEFAULT_FORMATTER:e.DEFAULT_LOWERCASE_FORMATTER),this.filterModelFormatter=new ls(this.localeService,this.optionsFactory)}getTextMatcher(){const t=this.textFilterParams.textCustomComparator;return t?(cn.warnOnce("textCustomComparator is deprecated, use textMatcher instead."),({filterOption:e,value:i,filterText:r})=>t(e,i,r)):this.textFilterParams.textMatcher||e.DEFAULT_MATCHER}createCondition(e){const t=this.getConditionType(e),i={filterType:this.getFilterType(),type:t},r=this.getValuesWithSideEffects(e,!0);return r.length>0&&(i.filter=r[0]),r.length>1&&(i.filterTo=r[1]),i}getFilterType(){return"text"}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getInputs(e){return e>=this.eValuesFrom.length?[null,null]:[this.eValuesFrom[e],this.eValuesTo[e]]}getValues(e){return this.getValuesWithSideEffects(e,!1)}getValuesWithSideEffects(t,i){const r=[];return this.forEachPositionInput(t,(t,n,s,o)=>{var a;if(n<o){let n=C(t.getValue());i&&this.textFilterParams.trimInput&&(n=null!=(a=e.trimInput(n))?a:null,t.setValue(n,!0)),r.push(n)}}),r}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}createValueElement(){const e=document.createElement("div");return e.classList.add("ag-filter-body"),Bt(e,"presentation"),this.createFromToElement(e,this.eValuesFrom,"from"),this.createFromToElement(e,this.eValuesTo,"to"),e}createFromToElement(e,t,i){const r=this.createManagedBean(new is);r.addCssClass(`ag-filter-${i}`),r.addCssClass("ag-filter-filter"),t.push(r),e.appendChild(r.getGui())}removeValueElements(e,t){this.removeComponents(this.eValuesFrom,e,t),this.removeComponents(this.eValuesTo,e,t)}mapValuesFromModel(e){const{filter:t,filterTo:i,type:r}=e||{};return[t||null,i||null].slice(0,this.getNumberOfInputs(r))}evaluateNullValue(e){const t=[$n.NOT_EQUAL,$n.NOT_CONTAINS,$n.BLANK];return!!e&&t.indexOf(e)>=0}evaluateNonNullValue(e,t,i,r){const n=e.map(e=>this.formatter(e))||[],s=this.formatter(t),{api:o,colDef:a,column:l,columnApi:c,context:u,textFormatter:p}=this.textFilterParams;if(i.type===$n.BLANK)return this.isBlank(t);if(i.type===$n.NOT_BLANK)return!this.isBlank(t);const g={api:o,colDef:a,column:l,columnApi:c,context:u,node:r.node,data:r.data,filterOption:i.type,value:s,textFormatter:p};return n.some(e=>this.matcher(d(h({},g),{filterText:e})))}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}};cs.DEFAULT_FILTER_OPTIONS=[$n.CONTAINS,$n.NOT_CONTAINS,$n.EQUALS,$n.NOT_EQUAL,$n.STARTS_WITH,$n.ENDS_WITH,$n.BLANK,$n.NOT_BLANK],cs.DEFAULT_FORMATTER=e=>e,cs.DEFAULT_LOWERCASE_FORMATTER=e=>null==e?null:e.toString().toLowerCase(),cs.DEFAULT_MATCHER=({filterOption:e,value:t,filterText:i})=>{if(null==i)return!1;switch(e){case cs.CONTAINS:return t.indexOf(i)>=0;case cs.NOT_CONTAINS:return t.indexOf(i)<0;case cs.EQUALS:return t===i;case cs.NOT_EQUAL:return t!=i;case cs.STARTS_WITH:return 0===t.indexOf(i);case cs.ENDS_WITH:const e=t.lastIndexOf(i);return e>=0&&e===t.length-i.length;default:return!1}};var us=cs,hs=class extends nt{constructor(e){super(),this.params=e,this.valueChangedListener=()=>{}}setupGui(e){var t;this.eFloatingFilterTextInput=this.createManagedBean(new is(null==(t=this.params)?void 0:t.config));const i=this.eFloatingFilterTextInput.getGui();e.appendChild(i),this.addManagedListener(i,"input",e=>this.valueChangedListener(e)),this.addManagedListener(i,"keydown",e=>this.valueChangedListener(e))}setEditable(e){this.eFloatingFilterTextInput.setDisabled(!e)}setAutoComplete(e){this.eFloatingFilterTextInput.setAutoComplete(e)}getValue(){return this.eFloatingFilterTextInput.getValue()}setValue(e,t){this.eFloatingFilterTextInput.setValue(e,t)}setValueChangedListener(e){this.valueChangedListener=e}setParams(e){this.setAriaLabel(e.ariaLabel),void 0!==e.autoComplete&&this.setAutoComplete(e.autoComplete)}setAriaLabel(e){this.eFloatingFilterTextInput.setInputAriaLabel(e)}},ds=class extends Jn{postConstruct(){this.setTemplate('\n            <div class="ag-floating-filter-input" role="presentation" ref="eFloatingFilterInputContainer"></div>\n        ')}getDefaultDebounceMs(){return 500}onParentModelChanged(e,t){this.isEventFromFloatingFilter(t)||this.isEventFromDataChange(t)||(this.setLastTypeFromModel(e),this.setEditable(this.canWeEditAfterModelFromParentFilter(e)),this.floatingFilterInputService.setValue(this.getFilterModelFormatter().getModelAsString(e)))}init(e){this.setupFloatingFilterInputService(e),super.init(e),this.setTextInputParams(e)}setupFloatingFilterInputService(e){this.floatingFilterInputService=this.createFloatingFilterInputService(e),this.floatingFilterInputService.setupGui(this.eFloatingFilterInputContainer)}setTextInputParams(e){var t;this.params=e;const i=null!=(t=e.browserAutoComplete)&&t;if(this.floatingFilterInputService.setParams({ariaLabel:this.getAriaLabel(e),autoComplete:i}),this.applyActive=Nn.isUseApplyButton(this.params.filterParams),!this.isReadOnly()){const e=Nn.getDebounceMs(this.params.filterParams,this.getDefaultDebounceMs()),t=Z(this.syncUpWithParentFilter.bind(this),e);this.floatingFilterInputService.setValueChangedListener(t)}}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.setTextInputParams(e)}recreateFloatingFilterInputService(e){const t=this.floatingFilterInputService.getValue();yr(this.eFloatingFilterInputContainer),this.destroyBean(this.floatingFilterInputService),this.setupFloatingFilterInputService(e),this.floatingFilterInputService.setValue(t,!0)}syncUpWithParentFilter(e){const t=e.key===Qr.ENTER;if(this.applyActive&&!t)return;let i=this.floatingFilterInputService.getValue();this.params.filterParams.trimInput&&(i=us.trimInput(i),this.floatingFilterInputService.setValue(i,!0)),this.params.parentFilterInstance(e=>{e&&e.onFloatingFilterChanged(this.getLastType()||null,i||null)})}setEditable(e){this.floatingFilterInputService.setEditable(e)}};g([bn("eFloatingFilterInputContainer")],ds.prototype,"eFloatingFilterInputContainer",2),g([le],ds.prototype,"postConstruct",1);var ps=class extends nt{constructor(){super(...arguments),this.valueChangedListener=()=>{},this.numberInputActive=!0}setupGui(e){this.eFloatingFilterNumberInput=this.createManagedBean(new rs),this.eFloatingFilterTextInput=this.createManagedBean(new is),this.eFloatingFilterTextInput.setDisabled(!0);const t=this.eFloatingFilterNumberInput.getGui(),i=this.eFloatingFilterTextInput.getGui();e.appendChild(t),e.appendChild(i),this.setupListeners(t,e=>this.valueChangedListener(e)),this.setupListeners(i,e=>this.valueChangedListener(e))}setEditable(e){this.numberInputActive=e,this.eFloatingFilterNumberInput.setDisplayed(this.numberInputActive),this.eFloatingFilterTextInput.setDisplayed(!this.numberInputActive)}setAutoComplete(e){this.eFloatingFilterNumberInput.setAutoComplete(e),this.eFloatingFilterTextInput.setAutoComplete(e)}getValue(){return this.getActiveInputElement().getValue()}setValue(e,t){this.getActiveInputElement().setValue(e,t)}getActiveInputElement(){return this.numberInputActive?this.eFloatingFilterNumberInput:this.eFloatingFilterTextInput}setValueChangedListener(e){this.valueChangedListener=e}setupListeners(e,t){this.addManagedListener(e,"input",t),this.addManagedListener(e,"keydown",t)}setParams(e){this.setAriaLabel(e.ariaLabel),void 0!==e.autoComplete&&this.setAutoComplete(e.autoComplete)}setAriaLabel(e){this.eFloatingFilterNumberInput.setInputAriaLabel(e),this.eFloatingFilterTextInput.setInputAriaLabel(e)}},gs=class extends ds{init(e){var t;super.init(e),this.filterModelFormatter=new ns(this.localeService,this.optionsFactory,null==(t=e.filterParams)?void 0:t.numberFormatter)}onParamsUpdated(e){this.refresh(e)}refresh(e){ss(e.filterParams)!==this.allowedCharPattern&&this.recreateFloatingFilterInputService(e),super.refresh(e),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory})}getDefaultFilterOptions(){return as.DEFAULT_FILTER_OPTIONS}getFilterModelFormatter(){return this.filterModelFormatter}createFloatingFilterInputService(e){return this.allowedCharPattern=ss(e.filterParams),this.allowedCharPattern?this.createManagedBean(new hs({config:{allowedCharPattern:this.allowedCharPattern}})):this.createManagedBean(new ps)}},fs=class extends ds{init(e){super.init(e),this.filterModelFormatter=new ls(this.localeService,this.optionsFactory)}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory})}getDefaultFilterOptions(){return us.DEFAULT_FILTER_OPTIONS}getFilterModelFormatter(){return this.filterModelFormatter}createFloatingFilterInputService(){return this.createManagedBean(new hs)}},ms=class e{constructor(e,t=!1){this.destroyFuncs=[],this.touching=!1,this.eventService=new me,this.eElement=e,this.preventMouseClick=t;const i=this.onTouchStart.bind(this),r=this.onTouchMove.bind(this),n=this.onTouchEnd.bind(this);this.eElement.addEventListener("touchstart",i,{passive:!0}),this.eElement.addEventListener("touchmove",r,{passive:!0}),this.eElement.addEventListener("touchend",n,{passive:!1}),this.destroyFuncs.push(()=>{this.eElement.removeEventListener("touchstart",i,{passive:!0}),this.eElement.removeEventListener("touchmove",r,{passive:!0}),this.eElement.removeEventListener("touchend",n,{passive:!1})})}getActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}addEventListener(e,t){this.eventService.addEventListener(e,t)}removeEventListener(e,t){this.eventService.removeEventListener(e,t)}onTouchStart(t){if(this.touching)return;this.touchStart=t.touches[0],this.touching=!0,this.moved=!1;const i=this.touchStart;window.setTimeout(()=>{const r=this.touchStart===i;if(this.touching&&r&&!this.moved){this.moved=!0;const i={type:e.EVENT_LONG_TAP,touchStart:this.touchStart,touchEvent:t};this.eventService.dispatchEvent(i)}},500)}onTouchMove(e){if(!this.touching)return;const t=this.getActiveTouch(e.touches);t&&!nn(t,this.touchStart,4)&&(this.moved=!0)}onTouchEnd(t){if(this.touching){if(!this.moved){const t={type:e.EVENT_TAP,touchStart:this.touchStart};this.eventService.dispatchEvent(t),this.checkForDoubleTap()}this.preventMouseClick&&t.cancelable&&t.preventDefault(),this.touching=!1}}checkForDoubleTap(){const t=(new Date).getTime();if(this.lastTapTime&&this.lastTapTime>0)if(t-this.lastTapTime>e.DOUBLE_TAP_MILLIS){const t={type:e.EVENT_DOUBLE_TAP,touchStart:this.touchStart};this.eventService.dispatchEvent(t),this.lastTapTime=null}else this.lastTapTime=t;else this.lastTapTime=t}destroy(){this.destroyFuncs.forEach(e=>e())}};ms.EVENT_TAP="tap",ms.EVENT_DOUBLE_TAP="doubleTap",ms.EVENT_LONG_TAP="longTap",ms.DOUBLE_TAP_MILLIS=500;var vs=ms,Cs=class e extends wn{constructor(t){super(),t||this.setTemplate(e.TEMPLATE)}attachCustomElements(e,t,i,r,n){this.eSortOrder=e,this.eSortAsc=t,this.eSortDesc=i,this.eSortMixed=r,this.eSortNone=n}setupSort(e,t=!1){this.column=e,this.suppressOrder=t,this.setupMultiSortIndicator(),(this.column.isSortable()||this.column.getColDef().showRowGroup)&&(this.addInIcon("sortAscending",this.eSortAsc,e),this.addInIcon("sortDescending",this.eSortDesc,e),this.addInIcon("sortUnSort",this.eSortNone,e),this.addManagedPropertyListener("unSortIcon",()=>this.updateIcons()),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.updateIcons()),this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,()=>this.onSortChanged()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onSortChanged()),this.onSortChanged())}addInIcon(e,t,i){if(null==t)return;const r=qr(e,this.gos,i);r&&t.appendChild(r)}onSortChanged(){this.updateIcons(),this.suppressOrder||this.updateSortOrder()}updateIcons(){const e=this.sortController.getDisplaySortForColumn(this.column);if(this.eSortAsc){const t="asc"===e;or(this.eSortAsc,t,{skipAriaHidden:!0})}if(this.eSortDesc){const t="desc"===e;or(this.eSortDesc,t,{skipAriaHidden:!0})}if(this.eSortNone){const t=!this.column.getColDef().unSortIcon&&!this.gos.get("unSortIcon"),i=null==e;or(this.eSortNone,!t&&i,{skipAriaHidden:!0})}}setupMultiSortIndicator(){this.addInIcon("sortUnSort",this.eSortMixed,this.column);const e=this.column.getColDef().showRowGroup;this.gos.isColumnsSortingCoupledToGroup()&&e&&(this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,()=>this.updateMultiSortIndicator()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.updateMultiSortIndicator()),this.updateMultiSortIndicator())}updateMultiSortIndicator(){if(this.eSortMixed){const e="mixed"===this.sortController.getDisplaySortForColumn(this.column);or(this.eSortMixed,e,{skipAriaHidden:!0})}}updateSortOrder(){var e;if(!this.eSortOrder)return;const t=this.sortController.getColumnsWithSortingOrdered(),i=null!=(e=this.sortController.getDisplaySortIndexForColumn(this.column))?e:-1,r=t.some(e=>{var t;return null!=(t=this.sortController.getDisplaySortIndexForColumn(e))&&t}),n=i>=0&&r;or(this.eSortOrder,n,{skipAriaHidden:!0}),i>=0?this.eSortOrder.textContent=(i+1).toString():yr(this.eSortOrder)}};Cs.TEMPLATE='<span class="ag-sort-indicator-container">\n            <span ref="eSortOrder" class="ag-sort-indicator-icon ag-sort-order ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortAsc" class="ag-sort-indicator-icon ag-sort-ascending-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortDesc" class="ag-sort-indicator-icon ag-sort-descending-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortMixed" class="ag-sort-indicator-icon ag-sort-mixed-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortNone" class="ag-sort-indicator-icon ag-sort-none-icon ag-hidden" aria-hidden="true"></span>\n        </span>',g([bn("eSortOrder")],Cs.prototype,"eSortOrder",2),g([bn("eSortAsc")],Cs.prototype,"eSortAsc",2),g([bn("eSortDesc")],Cs.prototype,"eSortDesc",2),g([bn("eSortMixed")],Cs.prototype,"eSortMixed",2),g([bn("eSortNone")],Cs.prototype,"eSortNone",2),g([he("columnModel")],Cs.prototype,"columnModel",2),g([he("sortController")],Cs.prototype,"sortController",2);var ys=Cs,ws=class e extends wn{constructor(){super(...arguments),this.lastMovingChanged=0}destroy(){super.destroy()}refresh(e){const t=this.params;return this.params=e,this.workOutTemplate()==this.currentTemplate&&this.workOutShowMenu()==this.currentShowMenu&&this.workOutSort()==this.currentSort&&this.shouldSuppressMenuHide()==this.currentSuppressMenuHide&&t.enableFilterButton==e.enableFilterButton&&t.enableFilterIcon==e.enableFilterIcon&&(this.setDisplayName(e),!0)}workOutTemplate(){var t;let i=null!=(t=this.params.template)?t:e.TEMPLATE;return i=i&&i.trim?i.trim():i,i}init(e){this.params=e,this.currentTemplate=this.workOutTemplate(),this.setTemplate(this.currentTemplate),this.setupTap(),this.setMenu(),this.setupSort(),this.setupFilterIcon(),this.setupFilterButton(),this.setDisplayName(e)}setDisplayName(e){if(this.currentDisplayName!=e.displayName){this.currentDisplayName=e.displayName;const t=yt(this.currentDisplayName,!0);this.eText&&(this.eText.textContent=t)}}addInIcon(e,t,i){if(null==t)return;const r=qr(e,this.gos,i);r&&t.appendChild(r)}setupTap(){const{gos:e}=this;if(e.get("suppressTouch"))return;const t=new vs(this.getGui(),!0),i=this.shouldSuppressMenuHide(),r=i&&y(this.eMenu),n=r?new vs(this.eMenu,!0):t;if(this.params.enableMenu){const e=r?"EVENT_TAP":"EVENT_LONG_TAP",t=e=>this.params.showColumnMenuAfterMouseClick(e.touchStart);this.addManagedListener(n,vs[e],t)}if(this.params.enableSorting){const e=e=>{var t,r;const n=e.touchStart.target;i&&((null==(t=this.eMenu)?void 0:t.contains(n))||(null==(r=this.eFilterButton)?void 0:r.contains(n)))||this.sortController.progressSort(this.params.column,!1,"uiColumnSorted")};this.addManagedListener(t,vs.EVENT_TAP,e)}if(this.params.enableFilterButton){const e=new vs(this.eFilterButton,!0);this.addManagedListener(e,"tap",()=>this.params.showFilter(this.eFilterButton)),this.addDestroyFunc(()=>e.destroy())}this.addDestroyFunc(()=>t.destroy()),r&&this.addDestroyFunc(()=>n.destroy())}workOutShowMenu(){return this.params.enableMenu&&this.menuService.isHeaderMenuButtonEnabled()}shouldSuppressMenuHide(){return this.menuService.isHeaderMenuButtonAlwaysShowEnabled()}setMenu(){if(!this.eMenu)return;if(this.currentShowMenu=this.workOutShowMenu(),!this.currentShowMenu)return wr(this.eMenu),void(this.eMenu=void 0);const e=this.menuService.isLegacyMenuEnabled();this.addInIcon(e?"menu":"menuAlt",this.eMenu,this.params.column),this.eMenu.classList.toggle("ag-header-menu-icon",!e),this.currentSuppressMenuHide=this.shouldSuppressMenuHide(),this.addManagedListener(this.eMenu,"click",()=>this.params.showColumnMenu(this.eMenu)),this.eMenu.classList.toggle("ag-header-menu-always-show",this.currentSuppressMenuHide)}onMenuKeyboardShortcut(e){var t,i,r,n;const{column:s}=this.params,o=this.menuService.isLegacyMenuEnabled();if(e&&!o){if(this.menuService.isFilterMenuInHeaderEnabled(s))return this.params.showFilter(null!=(i=null!=(t=this.eFilterButton)?t:this.eMenu)?i:this.getGui()),!0}else if(this.params.enableMenu)return this.params.showColumnMenu(null!=(n=null!=(r=this.eMenu)?r:this.eFilterButton)?n:this.getGui()),!0;return!1}workOutSort(){return this.params.enableSorting}setupSort(){if(this.currentSort=this.params.enableSorting,this.eSortIndicator||(this.eSortIndicator=this.context.createBean(new ys(!0)),this.eSortIndicator.attachCustomElements(this.eSortOrder,this.eSortAsc,this.eSortDesc,this.eSortMixed,this.eSortNone)),this.eSortIndicator.setupSort(this.params.column),!this.currentSort)return;this.addManagedListener(this.params.column,be.EVENT_MOVING_CHANGED,()=>{this.lastMovingChanged=(new Date).getTime()}),this.eLabel&&this.addManagedListener(this.eLabel,"click",e=>{const t=this.params.column.isMoving(),i=(new Date).getTime()-this.lastMovingChanged<50;if(!t&&!i){const t="ctrl"===this.gos.get("multiSortKey")?e.ctrlKey||e.metaKey:e.shiftKey;this.params.progressSort(t)}});const e=()=>{if(this.addOrRemoveCssClass("ag-header-cell-sorted-asc",this.params.column.isSortAscending()),this.addOrRemoveCssClass("ag-header-cell-sorted-desc",this.params.column.isSortDescending()),this.addOrRemoveCssClass("ag-header-cell-sorted-none",this.params.column.isSortNone()),this.params.column.getColDef().showRowGroup){const e=this.columnModel.getSourceColumnsForGroupColumn(this.params.column),t=!(null==e?void 0:e.every(e=>this.params.column.getSort()==e.getSort()));this.addOrRemoveCssClass("ag-header-cell-sorted-mixed",t)}};this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,e)}setupFilterIcon(){this.eFilter&&this.configureFilter(this.params.enableFilterIcon,this.eFilter,this.onFilterChangedIcon.bind(this))}setupFilterButton(){this.eFilterButton&&(this.configureFilter(this.params.enableFilterButton,this.eFilterButton,this.onFilterChangedButton.bind(this))?this.addManagedListener(this.eFilterButton,"click",()=>this.params.showFilter(this.eFilterButton)):this.eFilterButton=void 0)}configureFilter(e,t,i){if(!e)return wr(t),!1;const{column:r}=this.params;return this.addInIcon("filter",t,r),this.addManagedListener(r,be.EVENT_FILTER_CHANGED,i),i(),!0}onFilterChangedIcon(){const e=this.params.column.isFilterActive();or(this.eFilter,e,{skipAriaHidden:!0})}onFilterChangedButton(){const e=this.params.column.isFilterActive();this.eFilterButton.classList.toggle("ag-filter-active",e)}getAnchorElementForMenu(e){var t,i,r,n;return e?null!=(i=null!=(t=this.eFilterButton)?t:this.eMenu)?i:this.getGui():null!=(n=null!=(r=this.eMenu)?r:this.eFilterButton)?n:this.getGui()}};ws.TEMPLATE='<div class="ag-cell-label-container" role="presentation">\n            <span ref="eMenu" class="ag-header-icon ag-header-cell-menu-button" aria-hidden="true"></span>\n            <span ref="eFilterButton" class="ag-header-icon ag-header-cell-filter-button" aria-hidden="true"></span>\n            <div ref="eLabel" class="ag-header-cell-label" role="presentation">\n                <span ref="eText" class="ag-header-cell-text"></span>\n                <span ref="eFilter" class="ag-header-icon ag-header-label-icon ag-filter-icon" aria-hidden="true"></span>\n                <ag-sort-indicator ref="eSortIndicator"></ag-sort-indicator>\n            </div>\n        </div>',g([he("sortController")],ws.prototype,"sortController",2),g([he("menuService")],ws.prototype,"menuService",2),g([he("columnModel")],ws.prototype,"columnModel",2),g([bn("eFilter")],ws.prototype,"eFilter",2),g([bn("eFilterButton")],ws.prototype,"eFilterButton",2),g([bn("eSortIndicator")],ws.prototype,"eSortIndicator",2),g([bn("eMenu")],ws.prototype,"eMenu",2),g([bn("eLabel")],ws.prototype,"eLabel",2),g([bn("eText")],ws.prototype,"eText",2),g([bn("eSortOrder")],ws.prototype,"eSortOrder",2),g([bn("eSortAsc")],ws.prototype,"eSortAsc",2),g([bn("eSortDesc")],ws.prototype,"eSortDesc",2),g([bn("eSortMixed")],ws.prototype,"eSortMixed",2),g([bn("eSortNone")],ws.prototype,"eSortNone",2);var Ss=ws,bs=class e extends wn{constructor(){super(e.TEMPLATE)}destroy(){super.destroy()}init(e){this.params=e,this.checkWarnings(),this.setupLabel(),this.addGroupExpandIcon(),this.setupExpandIcons()}checkWarnings(){this.params.template&&U("A template was provided for Header Group Comp - templates are only supported for Header Comps (not groups)")}setupExpandIcons(){this.addInIcon("columnGroupOpened","agOpened"),this.addInIcon("columnGroupClosed","agClosed");const e=e=>{if(Qe(e))return;const t=!this.params.columnGroup.isExpanded();this.columnModel.setColumnGroupOpened(this.params.columnGroup.getProvidedColumnGroup(),t,"uiColumnExpanded")};this.addTouchAndClickListeners(this.eCloseIcon,e),this.addTouchAndClickListeners(this.eOpenIcon,e);const t=e=>{Ye(e)};this.addManagedListener(this.eCloseIcon,"dblclick",t),this.addManagedListener(this.eOpenIcon,"dblclick",t),this.addManagedListener(this.getGui(),"dblclick",e),this.updateIconVisibility();const i=this.params.columnGroup.getProvidedColumnGroup();this.addManagedListener(i,Ae.EVENT_EXPANDED_CHANGED,this.updateIconVisibility.bind(this)),this.addManagedListener(i,Ae.EVENT_EXPANDABLE_CHANGED,this.updateIconVisibility.bind(this))}addTouchAndClickListeners(e,t){const i=new vs(e,!0);this.addManagedListener(i,vs.EVENT_TAP,t),this.addDestroyFunc(()=>i.destroy()),this.addManagedListener(e,"click",t)}updateIconVisibility(){if(this.params.columnGroup.isExpandable()){const e=this.params.columnGroup.isExpanded();or(this.eOpenIcon,e),or(this.eCloseIcon,!e)}else or(this.eOpenIcon,!1),or(this.eCloseIcon,!1)}addInIcon(e,t){const i=qr(e,this.gos,null);i&&this.getRefElement(t).appendChild(i)}addGroupExpandIcon(){if(!this.params.columnGroup.isExpandable())return or(this.eOpenIcon,!1),void or(this.eCloseIcon,!1)}setupLabel(){var e;const{displayName:t,columnGroup:i}=this.params;if(y(t)){const e=yt(t,!0);this.getRefElement("agLabel").textContent=e}this.addOrRemoveCssClass("ag-sticky-label",!(null==(e=i.getColGroupDef())?void 0:e.suppressStickyLabel))}};bs.TEMPLATE='<div class="ag-header-group-cell-label" ref="agContainer" role="presentation">\n            <span ref="agLabel" class="ag-header-group-text" role="presentation"></span>\n            <span ref="agOpened" class="ag-header-icon ag-header-expand-icon ag-header-expand-icon-expanded"></span>\n            <span ref="agClosed" class="ag-header-icon ag-header-expand-icon ag-header-expand-icon-collapsed"></span>\n        </div>',g([he("columnModel")],bs.prototype,"columnModel",2),g([bn("agOpened")],bs.prototype,"eOpenIcon",2),g([bn("agClosed")],bs.prototype,"eCloseIcon",2);var Es=bs,As=class extends wn{isPopup(){return!0}setParentComponent(e){e.addCssClass("ag-has-popup"),super.setParentComponent(e)}destroy(){const e=this.parentComponent;e&&e.isAlive()&&e.getGui().classList.remove("ag-has-popup"),super.destroy()}},Ts=class e extends As{constructor(){super(e.TEMPLATE)}init(e){this.params=e,this.focusAfterAttached=e.cellStartedEdit,this.eTextArea.setMaxLength(e.maxLength||200).setCols(e.cols||60).setRows(e.rows||10),y(e.value,!0)&&this.eTextArea.setValue(e.value.toString(),!0),this.addGuiEventListener("keydown",this.onKeyDown.bind(this)),this.activateTabIndex()}onKeyDown(e){const t=e.key;(t===Qr.LEFT||t===Qr.UP||t===Qr.RIGHT||t===Qr.DOWN||e.shiftKey&&t===Qr.ENTER)&&e.stopPropagation()}afterGuiAttached(){const e=this.localeService.getLocaleTextFunc();this.eTextArea.setInputAriaLabel(e("ariaInputEditor","Input Editor")),this.focusAfterAttached&&this.eTextArea.getFocusableElement().focus()}getValue(){const e=this.eTextArea.getValue();return y(e)||y(this.params.value)?this.params.parseValue(e):this.params.value}};Ts.TEMPLATE='<div class="ag-large-text">\n            <ag-input-text-area ref="eTextArea" class="ag-large-text-input"></ag-input-text-area>\n        </div>',g([bn("eTextArea")],Ts.prototype,"eTextArea",2);var Ms=Ts,Rs=class extends As{constructor(){super('<div class="ag-cell-edit-wrapper">\n                <ag-select class="ag-cell-editor" ref="eSelect"></ag-select>\n            </div>'),this.startedByEnter=!1}init(e){this.focusAfterAttached=e.cellStartedEdit;const{eSelect:t,valueService:i,gos:r}=this,{values:n,value:s,eventKey:o}=e;if(w(n))return void console.warn("AG Grid: no values found for select cellEditor");this.startedByEnter=null!=o&&o===Qr.ENTER;let a=!1;n.forEach(r=>{const n={value:r},o=i.formatValue(e.column,null,r),l=null!=o;n.text=l?o:r,t.addOption(n),a=a||s===r}),a?t.setValue(e.value,!0):e.values.length&&t.setValue(e.values[0],!0);const{valueListGap:l,valueListMaxWidth:c,valueListMaxHeight:u}=e;null!=l&&t.setPickerGap(l),null!=u&&t.setPickerMaxHeight(u),null!=c&&t.setPickerMaxWidth(c),"fullRow"!==r.get("editType")&&this.addManagedListener(this.eSelect,Bn.EVENT_ITEM_SELECTED,()=>e.stopEditing())}afterGuiAttached(){this.focusAfterAttached&&this.eSelect.getFocusableElement().focus(),this.startedByEnter&&setTimeout(()=>{this.isAlive()&&this.eSelect.showPicker()})}focusIn(){this.eSelect.getFocusableElement().focus()}getValue(){return this.eSelect.getValue()}isPopup(){return!1}};g([he("valueService")],Rs.prototype,"valueService",2),g([bn("eSelect")],Rs.prototype,"eSelect",2);var _s=class extends As{constructor(e){super(`\n            <div class="ag-cell-edit-wrapper">\n                ${e.getTemplate()}\n            </div>`),this.cellEditorInput=e}init(e){this.params=e;const t=this.eInput;let i;if(this.cellEditorInput.init(t,e),e.cellStartedEdit){this.focusAfterAttached=!0;const t=e.eventKey;t===Qr.BACKSPACE||e.eventKey===Qr.DELETE?i="":t&&1===t.length?i=t:(i=this.cellEditorInput.getStartValue(),t!==Qr.F2&&(this.highlightAllOnFocus=!0))}else this.focusAfterAttached=!1,i=this.cellEditorInput.getStartValue();null!=i&&t.setStartValue(i),this.addManagedListener(t.getGui(),"keydown",e=>{const{key:t}=e;t!==Qr.PAGE_UP&&t!==Qr.PAGE_DOWN||e.preventDefault()})}afterGuiAttached(){var e,t;const i=this.localeService.getLocaleTextFunc(),r=this.eInput;if(r.setInputAriaLabel(i("ariaInputEditor","Input Editor")),!this.focusAfterAttached)return;Ri()||r.getFocusableElement().focus();const n=r.getInputElement();this.highlightAllOnFocus?n.select():null==(t=(e=this.cellEditorInput).setCaret)||t.call(e)}focusIn(){const e=this.eInput,t=e.getFocusableElement(),i=e.getInputElement();t.focus(),i.select()}getValue(){return this.cellEditorInput.getValue()}isPopup(){return!1}};g([bn("eInput")],_s.prototype,"eInput",2);var Ps=class{getTemplate(){return'<ag-input-text-field class="ag-cell-editor" ref="eInput"></ag-input-text-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.maxLength&&e.setMaxLength(t.maxLength)}getValue(){const e=this.eInput.getValue();return y(e)||y(this.params.value)?this.params.parseValue(e):this.params.value}getStartValue(){return this.params.useFormatter||this.params.column.getColDef().refData?this.params.formatValue(this.params.value):this.params.value}setCaret(){const e=this.eInput.getValue(),t=y(e)&&e.length||0;t&&this.eInput.getInputElement().setSelectionRange(t,t)}},xs=class extends _s{constructor(){super(new Ps)}},Ds=class extends wn{constructor(){super(),this.refreshCount=0;const e=document.createElement("span"),t=document.createElement("span");t.setAttribute("class","ag-value-change-delta");const i=document.createElement("span");i.setAttribute("class","ag-value-change-value"),e.appendChild(t),e.appendChild(i),this.setTemplateFromElement(e)}init(e){this.eValue=this.queryForHtmlElement(".ag-value-change-value"),this.eDelta=this.queryForHtmlElement(".ag-value-change-delta"),this.refresh(e,!0)}showDelta(e,t){const i=Math.abs(t),r=e.formatValue(i),n=y(r)?r:i,s=t>=0;this.eDelta.textContent=s?"↑"+n:"↓"+n,this.eDelta.classList.toggle("ag-value-change-delta-up",s),this.eDelta.classList.toggle("ag-value-change-delta-down",!s)}setTimerToRemoveDelta(){this.refreshCount++;const e=this.refreshCount;this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.hideDeltaValue()},2e3)})}hideDeltaValue(){this.eValue.classList.remove("ag-value-change-value-highlight"),yr(this.eDelta)}refresh(e,t=!1){const i=e.value;if(i===this.lastValue)return!1;if(y(e.valueFormatted)?this.eValue.textContent=e.valueFormatted:y(e.value)?this.eValue.textContent=i:yr(this.eValue),this.filterManager.isSuppressFlashingCellsBecauseFiltering())return!1;if("number"==typeof i&&"number"==typeof this.lastValue){const t=i-this.lastValue;this.showDelta(e,t)}return this.lastValue&&this.eValue.classList.add("ag-value-change-value-highlight"),t||this.setTimerToRemoveDelta(),this.lastValue=i,!0}};g([he("filterManager")],Ds.prototype,"filterManager",2);var Is=class extends wn{constructor(){super(),this.refreshCount=0;const e=document.createElement("span"),t=document.createElement("span");t.setAttribute("class","ag-value-slide-current"),e.appendChild(t),this.setTemplateFromElement(e),this.eCurrent=this.queryForHtmlElement(".ag-value-slide-current")}init(e){this.refresh(e,!0)}addSlideAnimation(){this.refreshCount++;const e=this.refreshCount;this.ePrevious&&this.getGui().removeChild(this.ePrevious);const t=document.createElement("span");t.setAttribute("class","ag-value-slide-previous ag-value-slide-out"),this.ePrevious=t,this.ePrevious.textContent=this.eCurrent.textContent,this.getGui().insertBefore(this.ePrevious,this.eCurrent),this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.ePrevious.classList.add("ag-value-slide-out-end")},50),window.setTimeout(()=>{e===this.refreshCount&&(this.getGui().removeChild(this.ePrevious),this.ePrevious=null)},3e3)})}refresh(e,t=!1){let i=e.value;return w(i)&&(i=""),i!==this.lastValue&&!this.filterManager.isSuppressFlashingCellsBecauseFiltering()&&(t||this.addSlideAnimation(),this.lastValue=i,y(e.valueFormatted)?this.eCurrent.textContent=e.valueFormatted:y(e.value)?this.eCurrent.textContent=i:yr(this.eCurrent),!0)}};g([he("filterManager")],Is.prototype,"filterManager",2);var Ls=class e{constructor(t){this.rowIndex=null,this.key=null,this.childrenMapped={},this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=e.OBJECT_ID_SEQUENCE++,this.__autoHeights={},this.alreadyRendered=!1,this.highlighted=null,this.hovered=!1,this.selected=!1,this.beans=t}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){const i=this.data;this.data=e,this.beans.valueCache.onDataChanged(),this.updateDataOnDetailNode(),this.checkRowSelectable(),this.resetQuickFilterAggregateText();const r=this.createDataChangedEvent(e,i,t);this.dispatchLocalEvent(r)}updateDataOnDetailNode(){this.detailNode&&(this.detailNode.data=this.data)}createDataChangedEvent(t,i,r){return{type:e.EVENT_DATA_CHANGED,node:this,oldData:i,newData:t,update:r}}createLocalRowEvent(e){return{type:e,node:this}}getRowIndexString(){return"top"===this.rowPinned?"t-"+this.rowIndex:"bottom"===this.rowPinned?"b-"+this.rowIndex:this.rowIndex.toString()}createDaemonNode(){const t=new e(this.beans);return t.id=this.id,t.data=this.data,t.__daemon=!0,t.selected=this.selected,t.level=this.level,t}setDataAndId(e,t){const i=y(this.id)?this.createDaemonNode():null,r=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),this.checkRowSelectable(),this.beans.selectionService.syncInRowNode(this,i);const n=this.createDataChangedEvent(e,r,!1);this.dispatchLocalEvent(n)}checkRowSelectable(){const e=this.beans.gos.get("isRowSelectable");this.setRowSelectable(!e||e(this))}setRowSelectable(t,i){if(this.selectable!==t){if(this.selectable=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_SELECTABLE_CHANGED)),i)return;if(this.beans.gos.get("groupSelectsChildren")){const e=this.calculateSelectedFromChildren();return void this.setSelectedParams({newValue:null!=e&&e,source:"selectableChanged"})}this.isSelected()&&!this.selectable&&this.setSelectedParams({newValue:!1,source:"selectableChanged"})}}setId(t){const i=this.beans.gos.getCallback("getRowId");if(i)if(this.data){const t=this.getGroupKeys(!0);this.id=i({data:this.data,parentKeys:t.length>0?t:void 0,level:this.level}),null!==this.id&&"string"==typeof this.id&&this.id.startsWith(e.ID_PREFIX_ROW_GROUP)&&console.error(`AG Grid: Row IDs cannot start with ${e.ID_PREFIX_ROW_GROUP}, this is a reserved prefix for AG Grid's row grouping feature.`),null!==this.id&&"string"!=typeof this.id&&(this.id=""+this.id)}else this.id=void 0;else this.id=t}getGroupKeys(e=!1){const t=[];let i=this;for(e&&(i=i.parent);i&&i.level>=0;)t.push(i.key),i=i.parent;return t.reverse(),t}isPixelInRange(e){return!(!y(this.rowTop)||!y(this.rowHeight))&&e>=this.rowTop&&e<this.rowTop+this.rowHeight}setFirstChild(t){this.firstChild!==t&&(this.firstChild=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_FIRST_CHILD_CHANGED)))}setLastChild(t){this.lastChild!==t&&(this.lastChild=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_LAST_CHILD_CHANGED)))}setChildIndex(t){this.childIndex!==t&&(this.childIndex=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_CHILD_INDEX_CHANGED)))}setRowTop(t){this.oldRowTop=this.rowTop,this.rowTop!==t&&(this.rowTop=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_TOP_CHANGED)),this.setDisplayed(null!==t))}clearRowTopAndRowIndex(){this.oldRowTop=null,this.setRowTop(null),this.setRowIndex(null)}setDisplayed(t){this.displayed!==t&&(this.displayed=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_DISPLAYED_CHANGED)))}setDragging(t){this.dragging!==t&&(this.dragging=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_DRAGGING_CHANGED)))}setHighlighted(t){t!==this.highlighted&&(this.highlighted=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HIGHLIGHT_CHANGED)))}setHovered(e){this.hovered!==e&&(this.hovered=e)}isHovered(){return this.hovered}setAllChildrenCount(t){this.allChildrenCount!==t&&(this.allChildrenCount=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_ALL_CHILDREN_COUNT_CHANGED)))}setMaster(t){this.master!==t&&(this.master&&!t&&(this.expanded=!1),this.master=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_MASTER_CHANGED)))}setGroup(t){this.group!==t&&(this.group&&!t&&(this.expanded=!1),this.group=t,this.updateHasChildren(),this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_GROUP_CHANGED)))}setRowHeight(t,i=!1){this.rowHeight=t,this.rowHeightEstimated=i,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HEIGHT_CHANGED))}setRowAutoHeight(e,t){this.__autoHeights||(this.__autoHeights={}),this.__autoHeights[t.getId()]=e,null!=e&&(null==this.checkAutoHeightsDebounced&&(this.checkAutoHeightsDebounced=Z(this.checkAutoHeights.bind(this),1)),this.checkAutoHeightsDebounced())}checkAutoHeights(){let e=!1,t=!0,i=0;const r=this.__autoHeights;if(null==r)return;if(this.beans.columnModel.getAllDisplayedAutoHeightCols().forEach(n=>{let s=r[n.getId()];if(null==s){if(!this.beans.columnModel.isColSpanActive())return void(e=!0);{let t=[];switch(n.getPinned()){case"left":t=this.beans.columnModel.getDisplayedLeftColumnsForRow(this);break;case"right":t=this.beans.columnModel.getDisplayedRightColumnsForRow(this);break;case null:t=this.beans.columnModel.getViewportCenterColumnsForRow(this)}if(t.includes(n))return void(e=!0);s=-1}}else t=!1;s>i&&(i=s)}),e)return;if((t||i<10)&&(i=this.beans.gos.getRowHeightForNode(this).height),i==this.rowHeight)return;this.setRowHeight(i);const n=this.beans.rowModel;n.onRowHeightChangedDebounced&&n.onRowHeightChangedDebounced()}setRowIndex(t){this.rowIndex!==t&&(this.rowIndex=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_ROW_INDEX_CHANGED)))}setUiLevel(t){this.uiLevel!==t&&(this.uiLevel=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_UI_LEVEL_CHANGED)))}setExpanded(t,i,r){if(this.expanded===t)return;this.expanded=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_EXPANDED_CHANGED));const n=Object.assign({},this.createGlobalRowEvent(ct.EVENT_ROW_GROUP_OPENED),{expanded:t,event:i||null});this.beans.rowNodeEventThrottle.dispatchExpanded(n,r),this.beans.rowRenderer.refreshCells({rowNodes:[this]})}createGlobalRowEvent(e){return this.beans.gos.addGridCommonParams({type:e,node:this,data:this.data,rowIndex:this.rowIndex,rowPinned:this.rowPinned})}dispatchLocalEvent(e){this.eventService&&this.eventService.dispatchEvent(e)}setDataValue(e,t,i){const r=(()=>{var t;return"string"!=typeof e?e:null!=(t=this.beans.columnModel.getGridColumn(e))?t:this.beans.columnModel.getPrimaryColumn(e)})(),n=this.getValueFromValueService(r);if(this.beans.gos.get("readOnlyEdit"))return this.dispatchEventForSaveValueReadOnly(r,n,t,i),!1;const s=this.beans.valueService.setValue(this,r,t,i);return this.dispatchCellChangedEvent(r,t,n),this.checkRowSelectable(),s}getValueFromValueService(e){var t,i;const r=this.leafGroup&&this.beans.columnModel.isPivotMode(),n=this.group&&this.expanded&&!this.footer&&!r;let s=!1;const o=null!=(t=this.beans.gos.get("groupTotalRow"))?t:this.beans.gos.get("groupIncludeFooter");s="function"!=typeof o?!!o:!!(null!=(i=this.beans.gos.getCallback("groupTotalRow"))?i:this.beans.gos.getCallback("groupIncludeFooter"))({node:this});const a=this.beans.gos.get("groupSuppressBlankHeader"),l=n&&s&&!a;return this.beans.valueService.getValue(e,this,!1,l)}dispatchEventForSaveValueReadOnly(e,t,i,r){const n=this.beans.gos.addGridCommonParams({type:ct.EVENT_CELL_EDIT_REQUEST,event:null,rowIndex:this.rowIndex,rowPinned:this.rowPinned,column:e,colDef:e.getColDef(),data:this.data,node:this,oldValue:t,newValue:i,value:i,source:r});this.beans.eventService.dispatchEvent(n)}setGroupValue(e,t){const i=this.beans.columnModel.getGridColumn(e);w(this.groupData)&&(this.groupData={});const r=i.getColId(),n=this.groupData[r];n!==t&&(this.groupData[r]=t,this.dispatchCellChangedEvent(i,t,n))}setAggData(e){const t=this.aggData;if(this.aggData=e,this.eventService){const i=e=>{const i=this.aggData?this.aggData[e]:void 0,r=t?t[e]:void 0;if(i===r)return;const n=this.beans.columnModel.lookupGridColumn(e);n&&this.dispatchCellChangedEvent(n,i,r)};for(const e in this.aggData)i(e);for(const t in e)t in this.aggData||i(t)}}updateHasChildren(){let t=this.group&&!this.footer||this.childrenAfterGroup&&this.childrenAfterGroup.length>0;if(this.beans.gos.isRowModelType("serverSide")){const e=this.beans.gos.get("treeData"),i=this.beans.gos.get("isServerSideGroup");t=!this.stub&&!this.footer&&(e?!!i&&i(this.data):!!this.group)}t!==this.__hasChildren&&(this.__hasChildren=!!t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HAS_CHILDREN_CHANGED)))}hasChildren(){return null==this.__hasChildren&&this.updateHasChildren(),this.__hasChildren}isEmptyRowGroupNode(){return this.group&&S(this.childrenAfterGroup)}dispatchCellChangedEvent(t,i,r){const n={type:e.EVENT_CELL_CHANGED,node:this,column:t,newValue:i,oldValue:r};this.dispatchLocalEvent(n)}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){return!this.footer&&(this.beans.columnModel.isPivotMode()?this.hasChildren()&&!this.leafGroup:this.hasChildren()||!!this.master)}isSelected(){return this.footer?this.sibling.isSelected():this.selected}depthFirstSearch(e){this.childrenAfterGroup&&this.childrenAfterGroup.forEach(t=>t.depthFirstSearch(e)),e(this)}calculateSelectedFromChildren(){var e;let t=!1,i=!1,r=!1;if(!(null==(e=this.childrenAfterGroup)?void 0:e.length))return this.selectable?this.selected:null;for(let e=0;e<this.childrenAfterGroup.length;e++){const n=this.childrenAfterGroup[e];let s=n.isSelected();if(!n.selectable){const e=n.calculateSelectedFromChildren();if(null===e)continue;s=e}switch(s){case!0:t=!0;break;case!1:i=!0;break;default:r=!0}}return r||t&&i?void 0:!!t||!i&&(this.selectable?this.selected:null)}setSelectedInitialValue(e){this.selected=e}selectThisNode(t,i,r="api"){const n=!this.selectable&&t,s=this.selected===t;if(n||s)return!1;this.selected=t,this.eventService&&this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_ROW_SELECTED));const o=this.sibling;o&&o.footer&&o.eventService&&o.dispatchLocalEvent(o.createLocalRowEvent(e.EVENT_ROW_SELECTED));const a=d(h({},this.createGlobalRowEvent(ct.EVENT_ROW_SELECTED)),{event:i||null,source:r});return this.beans.eventService.dispatchEvent(a),!0}setSelected(e,t=!1,i="api"){"boolean"!=typeof i?this.setSelectedParams({newValue:e,clearSelection:t,rangeSelect:!1,source:i}):console.warn("AG Grid: since version v30, rowNode.setSelected() property `suppressFinishActions` has been removed, please use `gridApi.setNodesSelected()` for bulk actions, and the event `source` property for ignoring events instead.")}setSelectedParams(e){return this.rowPinned?(console.warn("AG Grid: cannot select pinned rows"),0):void 0===this.id?(console.warn("AG Grid: cannot select node until id for node is known"),0):this.beans.selectionService.setNodesSelected(d(h({},e),{nodes:[this.footer?this.sibling:this]}))}isRowPinned(){return"top"===this.rowPinned||"bottom"===this.rowPinned}isParentOfNode(e){let t=this.parent;for(;t;){if(t===e)return!0;t=t.parent}return!1}addEventListener(e,t){var i,r;this.eventService||(this.eventService=new me),this.beans.frameworkOverrides.shouldWrapOutgoing&&!this.frameworkEventListenerService&&(this.eventService.setFrameworkOverrides(this.beans.frameworkOverrides),this.frameworkEventListenerService=new ve(this.beans.frameworkOverrides));const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.wrap(t))?r:t;this.eventService.addEventListener(e,n)}removeEventListener(e,t){var i,r;if(!this.eventService)return;const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.unwrap(t))?r:t;this.eventService.removeEventListener(e,n),this.eventService.noRegisteredListenersExist()&&(this.eventService=null)}onMouseEnter(){this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_MOUSE_ENTER))}onMouseLeave(){this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_MOUSE_LEAVE))}getFirstChildOfFirstChild(e){let t=this,i=!0,r=!1,n=null;for(;i&&!r;){const s=t.parent;y(s)&&t.firstChild?s.rowGroupColumn===e&&(r=!0,n=s):i=!1,t=s}return r?n:null}isFullWidthCell(){if(this.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this})}getRoute(){if(null==this.key)return;const e=[];let t=this;for(;null!=t.key;)e.push(t.key),t=t.parent;return e.reverse()}createFooter(){if(this.sibling)return;const t=new Set(["eventService","__objectId","sticky"]),i=new e(this.beans);Object.keys(this).forEach(e=>{t.has(e)||(i[e]=this[e])}),i.footer=!0,i.setRowTop(null),i.setRowIndex(null),i.oldRowTop=null,i.id="rowGroupFooter_"+this.id,i.sibling=this,this.sibling=i}destroyFooter(){this.sibling&&(this.sibling.setRowTop(null),this.sibling.setRowIndex(null),this.sibling=void 0)}};Ls.ID_PREFIX_ROW_GROUP="row-group-",Ls.ID_PREFIX_TOP_PINNED="t-",Ls.ID_PREFIX_BOTTOM_PINNED="b-",Ls.OBJECT_ID_SEQUENCE=0,Ls.EVENT_ROW_SELECTED="rowSelected",Ls.EVENT_DATA_CHANGED="dataChanged",Ls.EVENT_CELL_CHANGED="cellChanged",Ls.EVENT_ALL_CHILDREN_COUNT_CHANGED="allChildrenCountChanged",Ls.EVENT_MASTER_CHANGED="masterChanged",Ls.EVENT_GROUP_CHANGED="groupChanged",Ls.EVENT_MOUSE_ENTER="mouseEnter",Ls.EVENT_MOUSE_LEAVE="mouseLeave",Ls.EVENT_HEIGHT_CHANGED="heightChanged",Ls.EVENT_TOP_CHANGED="topChanged",Ls.EVENT_DISPLAYED_CHANGED="displayedChanged",Ls.EVENT_FIRST_CHILD_CHANGED="firstChildChanged",Ls.EVENT_LAST_CHILD_CHANGED="lastChildChanged",Ls.EVENT_CHILD_INDEX_CHANGED="childIndexChanged",Ls.EVENT_ROW_INDEX_CHANGED="rowIndexChanged",Ls.EVENT_EXPANDED_CHANGED="expandedChanged",Ls.EVENT_HAS_CHILDREN_CHANGED="hasChildrenChanged",Ls.EVENT_SELECTABLE_CHANGED="selectableChanged",Ls.EVENT_UI_LEVEL_CHANGED="uiLevelChanged",Ls.EVENT_HIGHLIGHT_CHANGED="rowHighlightChanged",Ls.EVENT_DRAGGING_CHANGED="draggingChanged";var Ns=Ls,Os=class extends wn{constructor(){super('\n            <div class="ag-selection-checkbox" role="presentation">\n                <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n            </div>')}postConstruct(){this.eCheckbox.setPassive(!0)}getCheckboxId(){return this.eCheckbox.getInputElement().id}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){const e=this.localeService.getLocaleTextFunc(),t=this.rowNode.isSelected(),i=vi(e,t),[r,n]=this.rowNode.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],s=e(r,n);this.eCheckbox.setValue(t,!0),this.eCheckbox.setInputAriaLabel(`${s} (${i})`)}onClicked(e,t,i){return this.rowNode.setSelectedParams({newValue:e,rangeSelect:i.shiftKey,groupSelectsFiltered:t,event:i,source:"checkboxSelected"})}init(e){if(this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListener(this.eCheckbox.getInputElement(),"dblclick",e=>{Ye(e)}),this.addManagedListener(this.eCheckbox.getInputElement(),"click",e=>{Ye(e);const t=this.gos.get("groupSelectsFiltered"),i=this.eCheckbox.getValue();this.shouldHandleIndeterminateState(i,t)?0===this.onClicked(!0,t,e||{})&&this.onClicked(!1,t,e):i?this.onClicked(!1,t,e):this.onClicked(!0,t,e||{})}),this.addManagedListener(this.rowNode,Ns.EVENT_ROW_SELECTED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_DATA_CHANGED,this.onDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_SELECTABLE_CHANGED,this.onSelectableChanged.bind(this)),this.gos.get("isRowSelectable")||"function"==typeof this.getIsVisible()){const e=this.showOrHideSelect.bind(this);this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.rowNode,Ns.EVENT_DATA_CHANGED,e),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,e),this.showOrHideSelect()}this.eCheckbox.getInputElement().setAttribute("tabindex","-1")}shouldHandleIndeterminateState(e,t){return t&&(void 0===this.eCheckbox.getPreviousValue()||void 0===e)&&this.gos.isRowModelType("clientSide")}showOrHideSelect(){var e,t,i;let r=this.rowNode.selectable;const n=this.getIsVisible();if(r)if("function"==typeof n){const t=null==(e=this.overrides)?void 0:e.callbackParams;if(this.column){const e=this.column.createColumnFunctionCallbackParams(this.rowNode);r=n(h(h({},t),e))}else r=n(d(h({},t),{node:this.rowNode,data:this.rowNode.data}))}else r=null!=n&&n;if(null==(t=this.column)?void 0:t.getColDef().showDisabledCheckboxes)return this.eCheckbox.setDisabled(!r),this.setVisible(!0),void this.setDisplayed(!0);(null==(i=this.overrides)?void 0:i.removeHidden)?this.setDisplayed(r):this.setVisible(r)}getIsVisible(){var e,t;return this.overrides?this.overrides.isVisible:null==(t=null==(e=this.column)?void 0:e.getColDef())?void 0:t.checkboxSelection}};g([bn("eCheckbox")],Os.prototype,"eCheckbox",2),g([le],Os.prototype,"postConstruct",1);var Fs=(e=>(e[e.Up=0]="Up",e[e.Down=1]="Down",e))(Fs||{}),ks=(e=>(e[e.Left=0]="Left",e[e.Right=1]="Right",e))(ks||{}),Gs=(e=>(e[e.ToolPanel=0]="ToolPanel",e[e.HeaderCell=1]="HeaderCell",e[e.RowDrag=2]="RowDrag",e[e.ChartPanel=3]="ChartPanel",e[e.AdvancedFilterBuilder=4]="AdvancedFilterBuilder",e))(Gs||{}),Vs=class extends nt{constructor(){super(...arguments),this.dragSourceAndParamsList=[],this.dropTargets=[]}init(){this.ePinnedIcon=$r("columnMovePin",this.gos,null),this.eHideIcon=$r("columnMoveHide",this.gos,null),this.eMoveIcon=$r("columnMoveMove",this.gos,null),this.eLeftIcon=$r("columnMoveLeft",this.gos,null),this.eRightIcon=$r("columnMoveRight",this.gos,null),this.eGroupIcon=$r("columnMoveGroup",this.gos,null),this.eAggregateIcon=$r("columnMoveValue",this.gos,null),this.ePivotIcon=$r("columnMovePivot",this.gos,null),this.eDropNotAllowedIcon=$r("dropNotAllowed",this.gos,null)}addDragSource(e,t=!1){const i={eElement:e.eElement,dragStartPixels:e.dragStartPixels,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this),onDragging:this.onDragging.bind(this),includeTouch:t};this.dragSourceAndParamsList.push({params:i,dragSource:e}),this.dragService.addDragSource(i)}removeDragSource(e){const t=this.dragSourceAndParamsList.find(t=>t.dragSource===e);t&&(this.dragService.removeDragSource(t.params),Oe(this.dragSourceAndParamsList,t))}clearDragSourceParamsList(){this.dragSourceAndParamsList.forEach(e=>this.dragService.removeDragSource(e.params)),this.dragSourceAndParamsList.length=0,this.dropTargets.length=0}nudge(){this.dragging&&this.onDragging(this.eventLastTime,!0)}onDragStart(e,t){this.dragging=!0,this.dragSource=e,this.eventLastTime=t,this.dragItem=this.dragSource.getDragItem(),this.lastDropTarget=void 0,this.dragSource.onDragStarted&&this.dragSource.onDragStarted(),this.createGhost()}onDragStop(e){if(this.eventLastTime=null,this.dragging=!1,this.dragSource.onDragStopped&&this.dragSource.onDragStopped(),this.lastDropTarget&&this.lastDropTarget.onDragStop){const t=this.createDropTargetEvent(this.lastDropTarget,e,null,null,!1);this.lastDropTarget.onDragStop(t)}this.lastDropTarget=null,this.dragItem=null,this.removeGhost()}onDragging(e,t){var i,r,n,s;const o=this.getHorizontalDirection(e),a=this.getVerticalDirection(e);this.eventLastTime=e,this.positionGhost(e);const l=this.dropTargets.filter(t=>this.isMouseOnDropTarget(e,t)),c=this.findCurrentDropTarget(e,l);if(c!==this.lastDropTarget)this.leaveLastTargetIfExists(e,o,a,t),null!==this.lastDropTarget&&null===c&&(null==(r=(i=this.dragSource).onGridExit)||r.call(i,this.dragItem)),null===this.lastDropTarget&&null!==c&&(null==(s=(n=this.dragSource).onGridEnter)||s.call(n,this.dragItem)),this.enterDragTargetIfExists(c,e,o,a,t),this.lastDropTarget=c;else if(c&&c.onDragging){const i=this.createDropTargetEvent(c,e,o,a,t);c.onDragging(i)}}getAllContainersFromDropTarget(e){const t=e.getSecondaryContainers?e.getSecondaryContainers():null,i=[[e.getContainer()]];return t?i.concat(t):i}allContainersIntersect(e,t){for(const i of t){const t=i.getBoundingClientRect();if(0===t.width||0===t.height)return!1;const r=e.clientX>=t.left&&e.clientX<t.right,n=e.clientY>=t.top&&e.clientY<t.bottom;if(!r||!n)return!1}return!0}isMouseOnDropTarget(e,t){const i=this.getAllContainersFromDropTarget(t);let r=!1;for(const t of i)if(this.allContainersIntersect(e,t)){r=!0;break}return!(t.targetContainsSource&&!t.getContainer().contains(this.dragSource.eElement))&&r&&t.isInterestedIn(this.dragSource.type,this.dragSource.eElement)}findCurrentDropTarget(e,t){const i=t.length;if(0===i)return null;if(1===i)return t[0];const r=this.gos.getRootNode().elementsFromPoint(e.clientX,e.clientY);for(const e of r)for(const i of t)if(-1!==ze(this.getAllContainersFromDropTarget(i)).indexOf(e))return i;return null}enterDragTargetIfExists(e,t,i,r,n){if(e){if(e.onDragEnter){const s=this.createDropTargetEvent(e,t,i,r,n);e.onDragEnter(s)}this.setGhostIcon(e.getIconName?e.getIconName():null)}}leaveLastTargetIfExists(e,t,i,r){if(this.lastDropTarget){if(this.lastDropTarget.onDragLeave){const n=this.createDropTargetEvent(this.lastDropTarget,e,t,i,r);this.lastDropTarget.onDragLeave(n)}this.setGhostIcon(null)}}addDropTarget(e){this.dropTargets.push(e)}removeDropTarget(e){this.dropTargets=this.dropTargets.filter(t=>t.getContainer()!==e.getContainer())}hasExternalDropZones(){return this.dropTargets.some(e=>e.external)}findExternalZone(e){return this.dropTargets.filter(e=>e.external).find(t=>t.getContainer()===e.getContainer())||null}getHorizontalDirection(e){const t=this.eventLastTime&&this.eventLastTime.clientX,i=e.clientX;return t===i?null:t>i?0:1}getVerticalDirection(e){const t=this.eventLastTime&&this.eventLastTime.clientY,i=e.clientY;return t===i?null:t>i?0:1}createDropTargetEvent(e,t,i,r,n){const s=e.getContainer(),o=s.getBoundingClientRect(),{gridApi:a,columnApi:l,dragItem:c,dragSource:u}=this;return{event:t,x:t.clientX-o.left,y:t.clientY-o.top,vDirection:r,hDirection:i,dragSource:u,fromNudge:n,dragItem:c,api:a,columnApi:l,dropZoneTarget:s}}positionGhost(e){const t=this.eGhost;if(!t)return;const i=t.getBoundingClientRect().height,r=Fi()-2,n=ki()-2,s=fr(t.offsetParent),{clientY:o,clientX:a}=e;let l=o-s.top-i/2,c=a-s.left-10;const u=this.gos.getDocument(),h=u.defaultView||window,d=h.pageYOffset||u.documentElement.scrollTop,p=h.pageXOffset||u.documentElement.scrollLeft;r>0&&c+t.clientWidth>r+p&&(c=r+p-t.clientWidth),c<0&&(c=0),n>0&&l+t.clientHeight>n+d&&(l=n+d-t.clientHeight),l<0&&(l=0),t.style.left=`${c}px`,t.style.top=`${l}px`}removeGhost(){this.eGhost&&this.eGhostParent&&this.eGhostParent.removeChild(this.eGhost),this.eGhost=null}createGhost(){this.eGhost=Er(Vs.GHOST_TEMPLATE),this.mouseEventService.stampTopLevelGridCompWithGridInstance(this.eGhost);const{theme:e}=this.environment.getTheme();e&&this.eGhost.classList.add(e),this.eGhostIcon=this.eGhost.querySelector(".ag-dnd-ghost-icon"),this.setGhostIcon(null);const t=this.eGhost.querySelector(".ag-dnd-ghost-label");let i=this.dragSource.dragItemName;K(i)&&(i=i()),t.innerHTML=yt(i)||"",this.eGhost.style.height="25px",this.eGhost.style.top="20px",this.eGhost.style.left="20px";const r=this.gos.getDocument();let n=null,s=null;try{n=r.fullscreenElement}catch(e){}finally{n||(n=this.gos.getRootNode());s=n.querySelector("body")||(n instanceof ShadowRoot?n:n instanceof Document?null==n?void 0:n.documentElement:n)}this.eGhostParent=s,this.eGhostParent?this.eGhostParent.appendChild(this.eGhost):console.warn("AG Grid: could not find document body, it is needed for dragging columns")}setGhostIcon(e,t=!1){yr(this.eGhostIcon);let i=null;switch(e||(e=this.dragSource.getDefaultIconName?this.dragSource.getDefaultIconName():Vs.ICON_NOT_ALLOWED),e){case Vs.ICON_PINNED:i=this.ePinnedIcon;break;case Vs.ICON_MOVE:i=this.eMoveIcon;break;case Vs.ICON_LEFT:i=this.eLeftIcon;break;case Vs.ICON_RIGHT:i=this.eRightIcon;break;case Vs.ICON_GROUP:i=this.eGroupIcon;break;case Vs.ICON_AGGREGATE:i=this.eAggregateIcon;break;case Vs.ICON_PIVOT:i=this.ePivotIcon;break;case Vs.ICON_NOT_ALLOWED:i=this.eDropNotAllowedIcon;break;case Vs.ICON_HIDE:i=this.eHideIcon}this.eGhostIcon.classList.toggle("ag-shake-left-to-right",t),i===this.eHideIcon&&this.gos.get("suppressDragLeaveHidesColumns")||i&&this.eGhostIcon.appendChild(i)}};Vs.ICON_PINNED="pinned",Vs.ICON_MOVE="move",Vs.ICON_LEFT="left",Vs.ICON_RIGHT="right",Vs.ICON_GROUP="group",Vs.ICON_AGGREGATE="aggregate",Vs.ICON_PIVOT="pivot",Vs.ICON_NOT_ALLOWED="notAllowed",Vs.ICON_HIDE="hide",Vs.GHOST_TEMPLATE='<div class="ag-dnd-ghost ag-unselectable">\n            <span class="ag-dnd-ghost-icon ag-shake-left-to-right"></span>\n            <div class="ag-dnd-ghost-label"></div>\n        </div>',g([he("dragService")],Vs.prototype,"dragService",2),g([he("mouseEventService")],Vs.prototype,"mouseEventService",2),g([he("columnApi")],Vs.prototype,"columnApi",2),g([he("gridApi")],Vs.prototype,"gridApi",2),g([le],Vs.prototype,"init",1),g([ce],Vs.prototype,"clearDragSourceParamsList",1),Vs=g([ue("dragAndDropService")],Vs);var Hs=class extends wn{constructor(e,t,i,r,n,s){super(),this.cellValueFn=e,this.rowNode=t,this.column=i,this.customGui=r,this.dragStartPixels=n,this.suppressVisibilityChange=s,this.dragSource=null}isCustomGui(){return null!=this.customGui}postConstruct(){if(this.customGui?this.setDragElement(this.customGui,this.dragStartPixels):(this.setTemplate('<div class="ag-drag-handle ag-row-drag" aria-hidden="true"></div>'),this.getGui().appendChild(qr("rowDrag",this.gos,null)),this.addDragSource()),this.checkCompatibility(),!this.suppressVisibilityChange){const e=this.gos.get("rowDragManaged")?new Us(this,this.beans,this.rowNode,this.column):new zs(this,this.beans,this.rowNode,this.column);this.createManagedBean(e,this.beans.context)}}setDragElement(e,t){this.setTemplateFromElement(e),this.addDragSource(t)}getSelectedNodes(){if(!this.gos.get("rowDragMultiRow"))return[this.rowNode];const e=this.beans.selectionService.getSelectedNodes();return-1!==e.indexOf(this.rowNode)?e:[this.rowNode]}checkCompatibility(){const e=this.gos.get("rowDragManaged");this.gos.get("treeData")&&e&&U("If using row drag with tree data, you cannot have rowDragManaged=true")}getDragItem(){return{rowNode:this.rowNode,rowNodes:this.getSelectedNodes(),columns:this.column?[this.column]:void 0,defaultTextValue:this.cellValueFn()}}getRowDragText(e){if(e){const t=e.getColDef();if(t.rowDragText)return t.rowDragText}return this.gos.get("rowDragText")}addDragSource(e=4){this.dragSource&&this.removeDragSource();const t=this.localeService.getLocaleTextFunc();this.dragSource={type:2,eElement:this.getGui(),dragItemName:()=>{var e;const i=this.getDragItem(),r=(null==(e=i.rowNodes)?void 0:e.length)||1,n=this.getRowDragText(this.column);return n?n(i,r):1===r?this.cellValueFn():`${r} ${t("rowDragRows","rows")}`},getDragItem:()=>this.getDragItem(),dragStartPixels:e,dragSourceDomDataKey:this.gos.getDomDataKey()},this.beans.dragAndDropService.addDragSource(this.dragSource,!0)}removeDragSource(){this.dragSource&&this.beans.dragAndDropService.removeDragSource(this.dragSource),this.dragSource=null}};g([he("beans")],Hs.prototype,"beans",2),g([le],Hs.prototype,"postConstruct",1),g([ce],Hs.prototype,"removeDragSource",1);var Bs=class extends nt{constructor(e,t,i){super(),this.parent=e,this.rowNode=t,this.column=i}setDisplayedOrVisible(e){const t={skipAriaHidden:!0};if(e)this.parent.setDisplayed(!1,t);else{let e=!0,i=!1;this.column&&(e=this.column.isRowDrag(this.rowNode)||this.parent.isCustomGui(),i=K(this.column.getColDef().rowDrag)),i?(this.parent.setDisplayed(!0,t),this.parent.setVisible(e,t)):(this.parent.setDisplayed(e,t),this.parent.setVisible(!0,t))}}},zs=class extends Bs{constructor(e,t,i,r){super(e,i,r),this.beans=t}postConstruct(){this.addManagedPropertyListener("suppressRowDrag",this.onSuppressRowDrag.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_DATA_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.workOutVisibility.bind(this)),this.workOutVisibility()}onSuppressRowDrag(){this.workOutVisibility()}workOutVisibility(){const e=this.gos.get("suppressRowDrag");this.setDisplayedOrVisible(e)}};g([le],zs.prototype,"postConstruct",1);var Us=class extends Bs{constructor(e,t,i,r){super(e,i,r),this.beans=t}postConstruct(){this.addManagedListener(this.beans.eventService,ct.EVENT_SORT_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,ct.EVENT_FILTER_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_DATA_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedPropertyListener("suppressRowDrag",this.onSuppressRowDrag.bind(this)),this.workOutVisibility()}onSuppressRowDrag(){this.workOutVisibility()}workOutVisibility(){const e=this.beans.ctrlsService.getGridBodyCtrl().getRowDragFeature(),t=e&&e.shouldPreventRowMove(),i=this.gos.get("suppressRowDrag"),r=this.beans.dragAndDropService.hasExternalDropZones(),n=t&&!r||i;this.setDisplayedOrVisible(n)}};g([le],Us.prototype,"postConstruct",1);var Ws=class extends nt{init(e,t,i,r,n,s,o){var a,l,c,u;this.params=o,this.eGui=t,this.eCheckbox=i,this.eExpanded=r,this.eContracted=n,this.comp=e,this.compClass=s;const{node:h,value:d,colDef:p}=o,g=this.isTopLevelFooter();if(!g){if(this.isEmbeddedRowMismatch())return;if(h.footer&&this.gos.get("groupHideOpenParents")&&(p&&p.showRowGroup)!==(h.rowGroupColumn&&h.rowGroupColumn.getColId()))return}if(this.setupShowingValueForOpenedParent(),this.findDisplayedGroupNode(),!g){const e=o.node.footer&&o.node.rowGroupIndex===this.columnModel.getRowGroupColumns().findIndex(e=>{var t;return e.getColId()===(null==(t=o.colDef)?void 0:t.showRowGroup)}),t="multipleColumns"!=this.gos.get("groupDisplayType")||this.gos.get("treeData")||this.gos.get("showOpenedGroup")&&!o.node.footer&&(!o.node.group||null!=o.node.rowGroupIndex&&o.node.rowGroupIndex>this.columnModel.getRowGroupColumns().findIndex(e=>{var t;return e.getColId()===(null==(t=o.colDef)?void 0:t.showRowGroup)})),i=!h.group&&((null==(a=this.params.colDef)?void 0:a.field)||(null==(l=this.params.colDef)?void 0:l.valueGetter)),r=this.isExpandable(),n=this.columnModel.isPivotMode()&&h.leafGroup&&(null==(c=h.rowGroupColumn)?void 0:c.getColId())===(null==(u=o.column)?void 0:u.getColDef().showRowGroup);if(!(this.showingValueForOpenedParent||r||i||t||e||n))return}this.addExpandAndContract(),this.addFullWidthRowDraggerIfNeeded(),this.addCheckboxIfNeeded(),this.addValueElement(),this.setupIndent(),this.refreshAriaExpanded()}getCellAriaRole(){var e,t;const i=null==(e=this.params.colDef)?void 0:e.cellAriaRole,r=null==(t=this.params.column)?void 0:t.getColDef().cellAriaRole;return i||r||"gridcell"}destroy(){super.destroy(),this.expandListener=null}refreshAriaExpanded(){const{node:e,eGridCell:t}=this.params;if(this.expandListener&&(this.expandListener=this.expandListener()),!this.isExpandable())return void ri(t);const i=()=>{ii(t,!!e.expanded)};this.expandListener=this.addManagedListener(e,Ns.EVENT_EXPANDED_CHANGED,i)||null,i()}isTopLevelFooter(){if(!this.gos.getGrandTotalRow())return!1;if(null!=this.params.value||-1!=this.params.node.level)return!1;const e=this.params.colDef;if(null==e)return!0;if(!0===e.showRowGroup)return!0;const t=this.columnModel.getRowGroupColumns();return!t||0===t.length||t[0].getId()===e.showRowGroup}isEmbeddedRowMismatch(){if(!this.params.fullWidth||!this.gos.get("embedFullWidthRows"))return!1;const e="left"===this.params.pinned,t="right"===this.params.pinned,i=!e&&!t;return this.gos.get("enableRtl")?this.columnModel.isPinningLeft()?!t:!i:this.columnModel.isPinningLeft()?!e:!i}findDisplayedGroupNode(){const e=this.params.column,t=this.params.node;if(this.showingValueForOpenedParent){let i=t.parent;for(;null!=i;){if(i.rowGroupColumn&&e.isRowGroupDisplayed(i.rowGroupColumn.getId())){this.displayedGroupNode=i;break}i=i.parent}}w(this.displayedGroupNode)&&(this.displayedGroupNode=t)}setupShowingValueForOpenedParent(){const e=this.params.node,t=this.params.column;if(!this.gos.get("groupHideOpenParents"))return void(this.showingValueForOpenedParent=!1);if(!e.groupData)return void(this.showingValueForOpenedParent=!1);if(null!=e.rowGroupColumn){const i=e.rowGroupColumn.getId();if(t.isRowGroupDisplayed(i))return void(this.showingValueForOpenedParent=!1)}const i=null!=e.groupData[t.getId()];this.showingValueForOpenedParent=i}addValueElement(){this.displayedGroupNode.footer?this.addFooterValue():(this.addGroupValue(),this.addChildCount())}addGroupValue(){var e;const t=this.adjustParamsWithDetailsFromRelatedColumn(),i=this.getInnerCompDetails(t),{valueFormatted:r,value:n}=t;let s=r;if(null==s){const t=this.displayedGroupNode.rowGroupColumn&&(null==(e=this.params.column)?void 0:e.isRowGroupDisplayed(this.displayedGroupNode.rowGroupColumn.getId()));s=""===this.displayedGroupNode.key&&this.displayedGroupNode.group&&t?this.localeService.getLocaleTextFunc()("blanks","(Blanks)"):null!=n?n:null}this.comp.setInnerRenderer(i,s)}adjustParamsWithDetailsFromRelatedColumn(){const e=this.displayedGroupNode.rowGroupColumn,t=this.params.column;if(!e)return this.params;if(null!=t&&!t.isRowGroupDisplayed(e.getId()))return this.params;const i=this.params,{value:r,node:n}=this.params,s=this.valueService.formatValue(e,n,r);return d(h({},i),{valueFormatted:s})}addFooterValue(){let e=this.params.totalValueGetter;if(!e){const t=this.params.footerValueGetter;t&&(e=t,U("As of v31.3, footerValueGetter is deprecated. Use `totalValueGetter` instead."))}let t="";if(e){const i=L(this.params);i.value=this.params.value,"function"==typeof e?t=e(i):"string"==typeof e?t=this.expressionService.evaluate(e,i):console.warn("AG Grid: footerValueGetter should be either a function or a string (expression)")}else t=this.localeService.getLocaleTextFunc()("footerTotal","Total")+" "+(null!=this.params.value?this.params.value:"");const i=this.getInnerCompDetails(this.params);this.comp.setInnerRenderer(i,t)}getInnerCompDetails(e){if(e.fullWidth)return this.userComponentFactory.getFullWidthGroupRowInnerCellRenderer(this.gos.get("groupRowRendererParams"),e);const t=this.userComponentFactory.getInnerRendererDetails(e,e),i=e=>e&&e.componentClass==this.compClass;if(t&&!i(t))return t;const r=this.displayedGroupNode.rowGroupColumn,n=r?r.getColDef():void 0;if(!n)return;const s=this.userComponentFactory.getCellRendererDetails(n,e);return s&&!i(s)?s:i(s)&&n.cellRendererParams&&n.cellRendererParams.innerRenderer?this.userComponentFactory.getInnerRendererDetails(n.cellRendererParams,e):void 0}addChildCount(){this.params.suppressCount||(this.addManagedListener(this.displayedGroupNode,Ns.EVENT_ALL_CHILDREN_COUNT_CHANGED,this.updateChildCount.bind(this)),this.updateChildCount())}updateChildCount(){const e=this.displayedGroupNode.allChildrenCount,t=this.isShowRowGroupForThisRow()&&null!=e&&e>=0?`(${e})`:"";this.comp.setChildCount(t)}isShowRowGroupForThisRow(){if(this.gos.get("treeData"))return!0;const e=this.displayedGroupNode.rowGroupColumn;if(!e)return!1;const t=this.params.column;return null==t||t.isRowGroupDisplayed(e.getId())}addExpandAndContract(){var e;const t=this.params,i=qr("groupExpanded",this.gos,null),r=qr("groupContracted",this.gos,null);i&&this.eExpanded.appendChild(i),r&&this.eContracted.appendChild(r);const n=t.eGridCell;(null==(e=this.params.column)?void 0:e.isCellEditable(t.node))&&this.gos.get("enableGroupEdit")||!this.isExpandable()||t.suppressDoubleClickExpand||this.addManagedListener(n,"dblclick",this.onCellDblClicked.bind(this)),this.addManagedListener(this.eExpanded,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eContracted,"click",this.onExpandClicked.bind(this)),this.addManagedListener(n,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(t.node,Ns.EVENT_EXPANDED_CHANGED,this.showExpandAndContractIcons.bind(this)),this.showExpandAndContractIcons();const s=this.onRowNodeIsExpandableChanged.bind(this);this.addManagedListener(this.displayedGroupNode,Ns.EVENT_ALL_CHILDREN_COUNT_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ns.EVENT_MASTER_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ns.EVENT_GROUP_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ns.EVENT_HAS_CHILDREN_CHANGED,s)}onExpandClicked(e){Qe(e)||(Ye(e),this.onExpandOrContract(e))}onExpandOrContract(e){const t=this.displayedGroupNode,i=!t.expanded;!i&&t.sticky&&this.scrollToStickyNode(t),t.setExpanded(i,e)}scrollToStickyNode(e){this.ctrlsService.getGridBodyCtrl().getScrollFeature().setVerticalScrollPosition(e.rowTop-e.stickyRowTop)}isExpandable(){if(this.showingValueForOpenedParent)return!0;const e=this.displayedGroupNode,t=this.columnModel.isPivotMode()&&e.leafGroup;if(!e.isExpandable()||e.footer||t)return!1;const i=this.params.column;return null==i||"string"!=typeof i.getColDef().showRowGroup||this.isShowRowGroupForThisRow()}showExpandAndContractIcons(){const{params:e,displayedGroupNode:t,columnModel:i}=this,{node:r}=e,n=this.isExpandable();if(n){const e=!!this.showingValueForOpenedParent||r.expanded;this.comp.setExpandedDisplayed(e),this.comp.setContractedDisplayed(!e)}else this.comp.setExpandedDisplayed(!1),this.comp.setContractedDisplayed(!1);const s=i.isPivotMode(),o=s&&t.leafGroup,a=n&&!o,l=r.footer&&-1===r.level;this.comp.addOrRemoveCssClass("ag-cell-expandable",a),this.comp.addOrRemoveCssClass("ag-row-group",a),s?this.comp.addOrRemoveCssClass("ag-pivot-leaf-group",o):l||this.comp.addOrRemoveCssClass("ag-row-group-leaf-indent",!a)}onRowNodeIsExpandableChanged(){this.showExpandAndContractIcons(),this.setIndent(),this.refreshAriaExpanded()}setupIndent(){const e=this.params.node;this.params.suppressPadding||(this.addManagedListener(e,Ns.EVENT_UI_LEVEL_CHANGED,this.setIndent.bind(this)),this.setIndent())}setIndent(){if(this.gos.get("groupHideOpenParents"))return;const e=this.params,t=e.node,i=!!e.colDef,r=this.gos.get("treeData"),n=!i||r||!0===e.colDef.showRowGroup?t.uiLevel:0;this.indentClass&&this.comp.addOrRemoveCssClass(this.indentClass,!1),this.indentClass="ag-row-group-indent-"+n,this.comp.addOrRemoveCssClass(this.indentClass,!0)}addFullWidthRowDraggerIfNeeded(){if(!this.params.fullWidth||!this.params.rowDrag)return;const e=new Hs(()=>this.params.value,this.params.node);this.createManagedBean(e,this.context),this.eGui.insertAdjacentElement("afterbegin",e.getGui())}isUserWantsSelected(){const e=this.params.checkbox;return"function"==typeof e||!0===e}addCheckboxIfNeeded(){const e=this.displayedGroupNode,t=this.isUserWantsSelected()&&!e.footer&&!e.rowPinned&&!e.detail;if(t){const e=new Os;this.getContext().createBean(e),e.init({rowNode:this.params.node,column:this.params.column,overrides:{isVisible:this.params.checkbox,callbackParams:this.params,removeHidden:!0}}),this.eCheckbox.appendChild(e.getGui()),this.addDestroyFunc(()=>this.getContext().destroyBean(e))}this.comp.setCheckboxVisible(t)}onKeyDown(e){e.key!==Qr.ENTER||this.params.suppressEnterExpand||this.params.column&&this.params.column.isCellEditable(this.params.node)||this.onExpandOrContract(e)}onCellDblClicked(e){Qe(e)||Je(this.eExpanded,e)||Je(this.eContracted,e)||this.onExpandOrContract(e)}};g([he("expressionService")],Ws.prototype,"expressionService",2),g([he("valueService")],Ws.prototype,"valueService",2),g([he("columnModel")],Ws.prototype,"columnModel",2),g([he("userComponentFactory")],Ws.prototype,"userComponentFactory",2),g([he("ctrlsService")],Ws.prototype,"ctrlsService",2);var js=class e extends wn{constructor(){super(e.TEMPLATE)}init(e){const t={setInnerRenderer:(e,t)=>this.setRenderDetails(e,t),setChildCount:e=>this.eChildCount.textContent=e,addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setContractedDisplayed:e=>or(this.eContracted,e),setExpandedDisplayed:e=>or(this.eExpanded,e),setCheckboxVisible:e=>this.eCheckbox.classList.toggle("ag-invisible",!e)},i=this.createManagedBean(new Ws),r=!e.colDef,n=this.getGui();i.init(t,n,this.eCheckbox,this.eExpanded,this.eContracted,this.constructor,e),r&&Bt(n,i.getCellAriaRole())}setRenderDetails(e,t){if(e){const t=e.newAgStackInstance();if(!t)return;t.then(e=>{if(!e)return;const t=()=>this.context.destroyBean(e);this.isAlive()?(this.eValue.appendChild(e.getGui()),this.addDestroyFunc(t)):t()})}else this.eValue.innerText=t}destroy(){this.getContext().destroyBean(this.innerCellRenderer),super.destroy()}refresh(){return!1}};js.TEMPLATE='<span class="ag-cell-wrapper">\n            <span class="ag-group-expanded" ref="eExpanded"></span>\n            <span class="ag-group-contracted" ref="eContracted"></span>\n            <span class="ag-group-checkbox ag-invisible" ref="eCheckbox"></span>\n            <span class="ag-group-value" ref="eValue"></span>\n            <span class="ag-group-child-count" ref="eChildCount"></span>\n        </span>',g([bn("eExpanded")],js.prototype,"eExpanded",2),g([bn("eContracted")],js.prototype,"eContracted",2),g([bn("eCheckbox")],js.prototype,"eCheckbox",2),g([bn("eValue")],js.prototype,"eValue",2),g([bn("eChildCount")],js.prototype,"eChildCount",2);var Ks=js,$s=class e extends wn{constructor(){super(e.TEMPLATE)}init(e){e.node.failedLoad?this.setupFailed():this.setupLoading()}setupFailed(){const e=this.localeService.getLocaleTextFunc();this.eLoadingText.innerText=e("loadingError","ERR")}setupLoading(){const e=qr("groupLoading",this.gos,null);e&&this.eLoadingIcon.appendChild(e);const t=this.localeService.getLocaleTextFunc();this.eLoadingText.innerText=t("loadingOoo","Loading")}refresh(e){return!1}destroy(){super.destroy()}};$s.TEMPLATE='<div class="ag-loading">\n            <span class="ag-loading-icon" ref="eLoadingIcon"></span>\n            <span class="ag-loading-text" ref="eLoadingText"></span>\n        </div>',g([bn("eLoadingIcon")],$s.prototype,"eLoadingIcon",2),g([bn("eLoadingText")],$s.prototype,"eLoadingText",2);var qs=$s,Ys=class e extends wn{constructor(){super(e.TEMPLATE)}init(e){const t=`ag-cell-skeleton-renderer-${this.getCompId()}`;this.getGui().setAttribute("id",t),this.addDestroyFunc(()=>$t(e.eParentOfValue)),$t(e.eParentOfValue,t),e.node.failedLoad?this.setupFailed():this.setupLoading()}setupFailed(){const e=this.localeService.getLocaleTextFunc();this.getGui().innerText=e("loadingError","ERR");const t=e("ariaSkeletonCellLoadingFailed","Row failed to load");Kt(this.getGui(),t)}setupLoading(){const e=this.gos.getDocument().createElement("div");e.classList.add("ag-skeleton-effect"),this.getGui().appendChild(e);const t=this.localeService.getLocaleTextFunc()("ariaSkeletonCellLoading","Row data is loading");Kt(this.getGui(),t)}refresh(e){return!1}destroy(){super.destroy()}};Ys.TEMPLATE='<div class="ag-skeleton-container"></div>';var Qs=Ys,Xs=class e extends wn{constructor(){super()}destroy(){super.destroy()}init(t){const i=this.gos.get("overlayLoadingTemplate");if(this.setTemplate(null!=i?i:e.DEFAULT_LOADING_OVERLAY_TEMPLATE),!i){const e=this.localeService.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=e("loadingOoo","Loading...")})}}};Xs.DEFAULT_LOADING_OVERLAY_TEMPLATE='<span aria-live="polite" aria-atomic="true" class="ag-overlay-loading-center"></span>';var Zs=Xs,Js=class e extends wn{constructor(){super()}destroy(){super.destroy()}init(t){const i=this.gos.get("overlayNoRowsTemplate");if(this.setTemplate(null!=i?i:e.DEFAULT_NO_ROWS_TEMPLATE),!i){const e=this.localeService.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=e("noRowsToShow","No Rows To Show")})}}};Js.DEFAULT_NO_ROWS_TEMPLATE='<span class="ag-overlay-no-rows-center"></span>';var eo=Js,to=class extends As{constructor(){super('<div class="ag-tooltip"></div>')}init(e){const{value:t}=e;this.getGui().textContent=yt(t,!0)}},io=class{getTemplate(){return'<ag-input-number-field class="ag-cell-editor" ref="eInput"></ag-input-number-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.max&&e.setMax(t.max),null!=t.min&&e.setMin(t.min),null!=t.precision&&e.setPrecision(t.precision),null!=t.step&&e.setStep(t.step);const i=e.getInputElement();t.preventStepping?e.addManagedListener(i,"keydown",this.preventStepping):t.showStepperButtons&&i.classList.add("ag-number-field-input-stepper")}preventStepping(e){e.key!==Qr.UP&&e.key!==Qr.DOWN||e.preventDefault()}getValue(){const e=this.eInput.getValue();if(!y(e)&&!y(this.params.value))return this.params.value;let t=this.params.parseValue(e);if(null==t)return t;if("string"==typeof t){if(""===t)return null;t=Number(t)}return isNaN(t)?null:t}getStartValue(){return this.params.value}},ro=class extends _s{constructor(){super(new io)}},no=class{getTemplate(){return'<ag-input-date-field class="ag-cell-editor" ref="eInput"></ag-input-date-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.min&&e.setMin(t.min),null!=t.max&&e.setMax(t.max),null!=t.step&&e.setStep(t.step)}getValue(){const e=this.eInput.getDate();return y(e)||y(this.params.value)?null!=e?e:null:this.params.value}getStartValue(){const{value:e}=this.params;if(e instanceof Date)return Qi(e,!1)}},so=class extends _s{constructor(){super(new no)}},oo=class{constructor(e){this.getDataTypeService=e}getTemplate(){return'<ag-input-date-field class="ag-cell-editor" ref="eInput"></ag-input-date-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.min&&e.setMin(t.min),null!=t.max&&e.setMax(t.max),null!=t.step&&e.setStep(t.step)}getValue(){const e=this.formatDate(this.eInput.getDate());return y(e)||y(this.params.value)?this.params.parseValue(null!=e?e:""):this.params.value}getStartValue(){var e,t;return Qi(null!=(t=this.parseDate(null!=(e=this.params.value)?e:void 0))?t:null,!1)}parseDate(e){return this.getDataTypeService().getDateParserFunction(this.params.column)(e)}formatDate(e){return this.getDataTypeService().getDateFormatterFunction(this.params.column)(e)}},ao=class extends _s{constructor(){super(new oo(()=>this.dataTypeService))}};g([he("dataTypeService")],ao.prototype,"dataTypeService",2);var lo=class e extends wn{constructor(){super(e.TEMPLATE)}init(e){this.params=e,this.updateCheckbox(e);const t=this.eCheckbox.getInputElement();t.setAttribute("tabindex","-1"),Yt(t,"polite"),this.addManagedListener(t,"click",e=>{if(Ye(e),this.eCheckbox.isDisabled())return;const t=this.eCheckbox.getValue();this.onCheckboxChanged(t)}),this.addManagedListener(t,"dblclick",e=>{Ye(e)}),this.addManagedListener(this.params.eGridCell,"keydown",e=>{if(e.key===Qr.SPACE&&!this.eCheckbox.isDisabled()){this.params.eGridCell===this.gos.getActiveDomElement()&&this.eCheckbox.toggle();const t=this.eCheckbox.getValue();this.onCheckboxChanged(t),e.preventDefault()}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){var t,i,r;let n,s=!0;if(e.node.group&&e.column){const i=e.column.getColId();i.startsWith(dt)?n=null==e.value||""===e.value?void 0:"true"===e.value:e.node.aggData&&void 0!==e.node.aggData[i]?n=null!=(t=e.value)?t:void 0:s=!1}else n=null!=(i=e.value)?i:void 0;if(!s)return void this.eCheckbox.setDisplayed(!1);this.eCheckbox.setValue(n);const o=null!=e.disabled?e.disabled:!(null==(r=e.column)?void 0:r.isCellEditable(e.node));this.eCheckbox.setDisabled(o);const a=this.localeService.getLocaleTextFunc(),l=vi(a,n),c=o?l:`${a("ariaToggleCellValue","Press SPACE to toggle cell value")} (${l})`;this.eCheckbox.setInputAriaLabel(c)}onCheckboxChanged(e){const{column:t,node:i,rowIndex:r,value:n}=this.params,s={type:ct.EVENT_CELL_EDITING_STARTED,column:t,colDef:null==t?void 0:t.getColDef(),data:i.data,node:i,rowIndex:r,rowPinned:i.rowPinned,value:n};this.eventService.dispatchEvent(s);const o=this.params.node.setDataValue(this.params.column,e,"edit"),a={type:ct.EVENT_CELL_EDITING_STOPPED,column:t,colDef:null==t?void 0:t.getColDef(),data:i.data,node:i,rowIndex:r,rowPinned:i.rowPinned,value:n,oldValue:n,newValue:e,valueChanged:o};this.eventService.dispatchEvent(a)}};lo.TEMPLATE='\n        <div class="ag-cell-wrapper ag-checkbox-cell" role="presentation">\n            <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n        </div>',g([bn("eCheckbox")],lo.prototype,"eCheckbox",2);var co=lo,uo=class extends As{constructor(){super('\n            <div class="ag-cell-wrapper ag-cell-edit-wrapper ag-checkbox-edit">\n                <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n            </div>')}init(e){var t;this.params=e;const i=null!=(t=e.value)?t:void 0;this.eCheckbox.setValue(i),this.eCheckbox.getInputElement().setAttribute("tabindex","-1"),this.setAriaLabel(i),this.addManagedListener(this.eCheckbox,ct.EVENT_FIELD_VALUE_CHANGED,e=>this.setAriaLabel(e.selected))}getValue(){return this.eCheckbox.getValue()}focusIn(){this.eCheckbox.getFocusableElement().focus()}afterGuiAttached(){this.params.cellStartedEdit&&this.focusIn()}isPopup(){return!1}setAriaLabel(e){const t=this.localeService.getLocaleTextFunc(),i=vi(t,e),r=t("ariaToggleCellValue","Press SPACE to toggle cell value");this.eCheckbox.setInputAriaLabel(`${r} (${i})`)}};g([bn("eCheckbox")],uo.prototype,"eCheckbox",2);var ho=class extends wn{constructor(){super(),this.setTemplate("<div></div>")}init(e){var t;this.params=e,this.cssClassPrefix=null!=(t=this.params.cssClassPrefix)?t:"ag-menu-option",this.addIcon(),this.addName(),this.addShortcut(),this.addSubMenu()}configureDefaults(){return!0}addIcon(){if(this.params.isCompact)return;const e=Er(`<span ref="eIcon" class="${this.getClassName("part")} ${this.getClassName("icon")}" role="presentation"></span>`);this.params.checked?e.appendChild(qr("check",this.gos)):this.params.icon&&(Or(this.params.icon)?e.appendChild(this.params.icon):"string"==typeof this.params.icon?e.innerHTML=this.params.icon:console.warn("AG Grid: menu item icon must be DOM node or string")),this.getGui().appendChild(e)}addName(){const e=Er(`<span ref="eName" class="${this.getClassName("part")} ${this.getClassName("text")}">${this.params.name||""}</span>`);this.getGui().appendChild(e)}addShortcut(){if(this.params.isCompact)return;const e=Er(`<span ref="eShortcut" class="${this.getClassName("part")} ${this.getClassName("shortcut")}">${this.params.shortcut||""}</span>`);this.getGui().appendChild(e)}addSubMenu(){const e=Er(`<span ref="ePopupPointer" class="${this.getClassName("part")} ${this.getClassName("popup-pointer")}"></span>`),t=this.getGui();if(this.params.subMenu){const i=this.gos.get("enableRtl")?"smallLeft":"smallRight";ii(t,!1),e.appendChild(qr(i,this.gos))}t.appendChild(e)}getClassName(e){return`${this.cssClassPrefix}-${e}`}destroy(){super.destroy()}},po=class extends nt{constructor(){super(...arguments),this.agGridDefaults={agDateInput:ts,agColumnHeader:Ss,agColumnGroupHeader:Es,agSortIndicator:ys,agTextColumnFloatingFilter:fs,agNumberColumnFloatingFilter:gs,agDateColumnFloatingFilter:es,agReadOnlyFloatingFilter:An,agAnimateShowChangeCellRenderer:Ds,agAnimateSlideCellRenderer:Is,agGroupCellRenderer:Ks,agGroupRowRenderer:Ks,agLoadingCellRenderer:qs,agSkeletonCellRenderer:Qs,agCheckboxCellRenderer:co,agCellEditor:xs,agTextCellEditor:xs,agNumberCellEditor:ro,agDateCellEditor:so,agDateStringCellEditor:ao,agSelectCellEditor:Rs,agLargeTextCellEditor:Ms,agCheckboxCellEditor:uo,agTextColumnFilter:us,agNumberColumnFilter:as,agDateColumnFilter:Zn,agLoadingOverlay:Zs,agNoRowsOverlay:eo,agTooltipComponent:to,agMenuItem:ho},this.enterpriseAgDefaultCompsModule={agSetColumnFilter:"@ag-grid-enterprise/set-filter",agSetColumnFloatingFilter:"@ag-grid-enterprise/set-filter",agMultiColumnFilter:"@ag-grid-enterprise/multi-filter",agMultiColumnFloatingFilter:"@ag-grid-enterprise/multi-filter",agGroupColumnFilter:"@ag-grid-enterprise/row-grouping",agGroupColumnFloatingFilter:"@ag-grid-enterprise/row-grouping",agRichSelect:"@ag-grid-enterprise/rich-select",agRichSelectCellEditor:"@ag-grid-enterprise/rich-select",agDetailCellRenderer:"@ag-grid-enterprise/master-detail",agSparklineCellRenderer:"@ag-grid-enterprise/sparklines"},this.jsComps={}}init(){const e=this.gos.get("components");null!=e&&I(e,(e,t)=>this.registerJsComponent(e,t))}registerDefaultComponent(e,t){this.agGridDefaults[e]?console.error("Trying to overwrite a default component. You should call registerComponent"):this.agGridDefaults[e]=t}registerJsComponent(e,t){this.jsComps[e]=t}retrieve(e,t){const i=(e,t)=>({componentFromFramework:t,component:e}),r=this.getFrameworkOverrides().frameworkComponent(t,this.gos.get("components"));if(null!=r)return i(r,!0);const n=this.jsComps[t];if(n)return i(n,this.getFrameworkOverrides().isFrameworkComponent(n));const s=this.agGridDefaults[t];if(s)return i(s,!1);const o=this.enterpriseAgDefaultCompsModule[t];return o?se.__assertRegistered(o,`AG Grid '${e}' component: ${t}`,this.context.getGridId()):z(()=>{this.warnAboutMissingComponent(e,t)},"MissingComp"+t),null}warnAboutMissingComponent(e,t){const i=Ur(t,[...Object.keys(this.agGridDefaults).filter(e=>!["agCellEditor","agGroupRowRenderer","agSortIndicator"].includes(e)),...Object.keys(this.jsComps)],!0,.8).values;console.warn(`AG Grid: Could not find '${t}' component. It was configured as "${e}: '${t}'" but it wasn't found in the list of registered components.`),i.length>0&&console.warn(`         Did you mean: [${i.slice(0,3)}]?`),console.warn(`If using a custom component check it has been registered as described in: ${this.getFrameworkOverrides().getDocLink("components/")}`)}};g([le],po.prototype,"init",1),po=g([ue("userComponentRegistry")],po);var go={propertyName:"dateComponent",cellRenderer:!1},fo={propertyName:"headerComponent",cellRenderer:!1},mo={propertyName:"headerGroupComponent",cellRenderer:!1},vo={propertyName:"cellRenderer",cellRenderer:!0},Co={propertyName:"loadingCellRenderer",cellRenderer:!0},yo={propertyName:"cellEditor",cellRenderer:!1},wo={propertyName:"innerRenderer",cellRenderer:!0},So={propertyName:"loadingOverlayComponent",cellRenderer:!1},bo={propertyName:"noRowsOverlayComponent",cellRenderer:!1},Eo={propertyName:"tooltipComponent",cellRenderer:!1},Ao={propertyName:"filter",cellRenderer:!1},To={propertyName:"floatingFilterComponent",cellRenderer:!1},Mo={propertyName:"toolPanel",cellRenderer:!1},Ro={propertyName:"statusPanel",cellRenderer:!1},_o={propertyName:"fullWidthCellRenderer",cellRenderer:!0},Po={propertyName:"loadingCellRenderer",cellRenderer:!0},xo={propertyName:"groupRowRenderer",cellRenderer:!0},Do={propertyName:"detailCellRenderer",cellRenderer:!0},Io={propertyName:"menuItem",cellRenderer:!1},Lo=class{static getFloatingFilterType(e){return this.filterToFloatingFilterMapping[e]}};Lo.filterToFloatingFilterMapping={set:"agSetColumnFloatingFilter",agSetColumnFilter:"agSetColumnFloatingFilter",multi:"agMultiColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",group:"agGroupColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",number:"agNumberColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",date:"agDateColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",text:"agTextColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"};var No=class extends nt{getHeaderCompDetails(e,t){return this.getCompDetails(e,fo,"agColumnHeader",t)}getHeaderGroupCompDetails(e){const t=e.columnGroup.getColGroupDef();return this.getCompDetails(t,mo,"agColumnGroupHeader",e)}getFullWidthCellRendererDetails(e){return this.getCompDetails(this.gridOptions,_o,null,e,!0)}getFullWidthLoadingCellRendererDetails(e){return this.getCompDetails(this.gridOptions,Po,"agLoadingCellRenderer",e,!0)}getFullWidthGroupCellRendererDetails(e){return this.getCompDetails(this.gridOptions,xo,"agGroupRowRenderer",e,!0)}getFullWidthDetailCellRendererDetails(e){return this.getCompDetails(this.gridOptions,Do,"agDetailCellRenderer",e,!0)}getInnerRendererDetails(e,t){return this.getCompDetails(e,wo,null,t)}getFullWidthGroupRowInnerCellRenderer(e,t){return this.getCompDetails(e,wo,null,t)}getCellRendererDetails(e,t){return this.getCompDetails(e,vo,null,t)}getLoadingCellRendererDetails(e,t){return this.getCompDetails(e,Co,"agSkeletonCellRenderer",t,!0)}getCellEditorDetails(e,t){return this.getCompDetails(e,yo,"agCellEditor",t,!0)}getFilterDetails(e,t,i){return this.getCompDetails(e,Ao,i,t,!0)}getDateCompDetails(e){return this.getCompDetails(this.gridOptions,go,"agDateInput",e,!0)}getLoadingOverlayCompDetails(e){return this.getCompDetails(this.gridOptions,So,"agLoadingOverlay",e,!0)}getNoRowsOverlayCompDetails(e){return this.getCompDetails(this.gridOptions,bo,"agNoRowsOverlay",e,!0)}getTooltipCompDetails(e){return this.getCompDetails(e.colDef,Eo,"agTooltipComponent",e,!0)}getSetFilterCellRendererDetails(e,t){return this.getCompDetails(e,vo,null,t)}getFloatingFilterCompDetails(e,t,i){return this.getCompDetails(e,To,i,t)}getToolPanelCompDetails(e,t){return this.getCompDetails(e,Mo,null,t,!0)}getStatusPanelCompDetails(e,t){return this.getCompDetails(e,Ro,null,t,!0)}getMenuItemCompDetails(e,t){return this.getCompDetails(e,Io,"agMenuItem",t,!0)}getCompDetails(e,t,i,r,n=!1){const{propertyName:s,cellRenderer:o}=t;let{compName:a,jsComp:l,fwComp:c,paramsFromSelector:u,popupFromSelector:h,popupPositionFromSelector:d}=this.getCompKeys(e,t,r);const p=e=>{const t=this.userComponentRegistry.retrieve(s,e);t&&(l=t.componentFromFramework?void 0:t.component,c=t.componentFromFramework?t.component:void 0)};if(null!=a&&p(a),null==l&&null==c&&null!=i&&p(i),l&&o&&!this.agComponentUtils.doesImplementIComponent(l)&&(l=this.agComponentUtils.adaptFunction(s,l)),!l&&!c)return void(n&&console.error(`AG Grid: Could not find component ${a}, did you forget to configure this component?`));const g=this.mergeParamsWithApplicationProvidedParams(e,t,r,u),f=null==l,m=l||c;return{componentFromFramework:f,componentClass:m,params:g,type:t,popupFromSelector:h,popupPositionFromSelector:d,newAgStackInstance:()=>this.newAgStackInstance(m,f,g,t)}}getCompKeys(e,t,i){const{propertyName:r}=t;let n,s,o,a,l,c;if(e){const t=e,u=t[r+"Selector"],h=u?u(i):null,d=e=>{"string"==typeof e?n=e:null!=e&&!0!==e&&(this.getFrameworkOverrides().isFrameworkComponent(e)?o=e:s=e)};h?(d(h.component),a=h.params,l=h.popup,c=h.popupPosition):d(t[r])}return{compName:n,jsComp:s,fwComp:o,paramsFromSelector:a,popupFromSelector:l,popupPositionFromSelector:c}}newAgStackInstance(e,t,i,r){const n=r.propertyName;let s;if(t){const t=this.componentMetadataProvider.retrieve(n);s=this.frameworkComponentWrapper.wrap(e,t.mandatoryMethodList,t.optionalMethodList,r)}else s=new e;const o=this.initComponent(s,i);return null==o?dn.resolve(s):o.then(()=>s)}mergeParamsWithApplicationProvidedParams(e,t,i,r=null){const n=this.gos.getGridCommonParams();F(n,i);const s=e&&e[t.propertyName+"Params"];return"function"==typeof s?F(n,s(i)):"object"==typeof s&&F(n,s),F(n,r),n}initComponent(e,t){if(this.context.createBean(e),null!=e.init)return e.init(t)}getDefaultFloatingFilterType(e,t){if(null==e)return null;let i=null,{compName:r,jsComp:n,fwComp:s}=this.getCompKeys(e,Ao);return r?i=Lo.getFloatingFilterType(r):null==n&&null==s&&!0===e.filter&&(i=t()),i}};g([he("gridOptions")],No.prototype,"gridOptions",2),g([he("agComponentUtils")],No.prototype,"agComponentUtils",2),g([he("componentMetadataProvider")],No.prototype,"componentMetadataProvider",2),g([he("userComponentRegistry")],No.prototype,"userComponentRegistry",2),g([de("frameworkComponentWrapper")],No.prototype,"frameworkComponentWrapper",2),No=g([ue("userComponentFactory")],No);var Oo=(e=>(e[e.SINGLE_SHEET=0]="SINGLE_SHEET",e[e.MULTI_SHEET=1]="MULTI_SHEET",e))(Oo||{}),Fo=(e=>(e[e.Above=0]="Above",e[e.Below=1]="Below",e))(Fo||{}),ko=class{constructor(e){this.tickingInterval=null,this.onScrollCallback=null,this.scrollContainer=e.scrollContainer,this.scrollHorizontally=-1!==e.scrollAxis.indexOf("x"),this.scrollVertically=-1!==e.scrollAxis.indexOf("y"),this.scrollByTick=null!=e.scrollByTick?e.scrollByTick:20,e.onScrollCallback&&(this.onScrollCallback=e.onScrollCallback),this.scrollVertically&&(this.getVerticalPosition=e.getVerticalPosition,this.setVerticalPosition=e.setVerticalPosition),this.scrollHorizontally&&(this.getHorizontalPosition=e.getHorizontalPosition,this.setHorizontalPosition=e.setHorizontalPosition),this.shouldSkipVerticalScroll=e.shouldSkipVerticalScroll||(()=>!1),this.shouldSkipHorizontalScroll=e.shouldSkipHorizontalScroll||(()=>!1)}check(e,t=!1){const i=t||this.shouldSkipVerticalScroll();if(i&&this.shouldSkipHorizontalScroll())return;const r=this.scrollContainer.getBoundingClientRect(),n=this.scrollByTick;this.tickLeft=e.clientX<r.left+n,this.tickRight=e.clientX>r.right-n,this.tickUp=e.clientY<r.top+n&&!i,this.tickDown=e.clientY>r.bottom-n&&!i,this.tickLeft||this.tickRight||this.tickUp||this.tickDown?this.ensureTickingStarted():this.ensureCleared()}ensureTickingStarted(){null===this.tickingInterval&&(this.tickingInterval=window.setInterval(this.doTick.bind(this),100),this.tickCount=0)}doTick(){let e;if(this.tickCount++,e=this.tickCount>20?200:this.tickCount>10?80:40,this.scrollVertically){const t=this.getVerticalPosition();this.tickUp&&this.setVerticalPosition(t-e),this.tickDown&&this.setVerticalPosition(t+e)}if(this.scrollHorizontally){const t=this.getHorizontalPosition();this.tickLeft&&this.setHorizontalPosition(t-e),this.tickRight&&this.setHorizontalPosition(t+e)}this.onScrollCallback&&this.onScrollCallback()}ensureCleared(){this.tickingInterval&&(window.clearInterval(this.tickingInterval),this.tickingInterval=null)}},Go=class extends nt{constructor(e){super(),this.eContainer=e}postConstruct(){this.gos.isRowModelType("clientSide")&&(this.clientSideRowModel=this.rowModel),this.ctrlsService.whenReady(e=>{const t=e.gridBodyCtrl;this.autoScrollService=new ko({scrollContainer:t.getBodyViewportElement(),scrollAxis:"y",getVerticalPosition:()=>t.getScrollFeature().getVScrollPosition().top,setVerticalPosition:e=>t.getScrollFeature().setVerticalScrollPosition(e),onScrollCallback:()=>{this.onDragging(this.lastDraggingEvent)}})})}getContainer(){return this.eContainer}isInterestedIn(e){return 2===e}getIconName(){return this.gos.get("rowDragManaged")&&this.shouldPreventRowMove()?Vs.ICON_NOT_ALLOWED:Vs.ICON_MOVE}shouldPreventRowMove(){return!!this.columnModel.getRowGroupColumns().length||(!!this.filterManager.isAnyFilterPresent()||!!this.sortController.isSortActive())}getRowNodes(e){if(!this.isFromThisGrid(e))return e.dragItem.rowNodes||[];const t=e.dragItem.rowNode;if(this.gos.get("rowDragMultiRow")){const e=[...this.selectionService.getSelectedNodes()].sort((e,t)=>null==e.rowIndex||null==t.rowIndex?0:this.getRowIndexNumber(e)-this.getRowIndexNumber(t));if(-1!==e.indexOf(t))return e}return[t]}onDragEnter(e){e.dragItem.rowNodes=this.getRowNodes(e),this.dispatchGridEvent(ct.EVENT_ROW_DRAG_ENTER,e),this.getRowNodes(e).forEach(e=>{e.setDragging(!0)}),this.onEnterOrDragging(e)}onDragging(e){this.onEnterOrDragging(e)}isFromThisGrid(e){const{dragSourceDomDataKey:t}=e.dragSource;return t===this.gos.getDomDataKey()}isDropZoneWithinThisGrid(e){const t=this.ctrlsService.getGridBodyCtrl().getGui(),{dropZoneTarget:i}=e;return!t.contains(i)}onEnterOrDragging(e){this.dispatchGridEvent(ct.EVENT_ROW_DRAG_MOVE,e),this.lastDraggingEvent=e;const t=this.mouseEventService.getNormalisedPosition(e).y;this.gos.get("rowDragManaged")&&this.doManagedDrag(e,t),this.autoScrollService.check(e.event)}doManagedDrag(e,t){const i=this.isFromThisGrid(e),r=this.gos.get("rowDragManaged"),n=e.dragItem.rowNodes;r&&this.shouldPreventRowMove()||(this.gos.get("suppressMoveWhenRowDragging")||!i?this.isDropZoneWithinThisGrid(e)||this.clientSideRowModel.highlightRowAtPixel(n[0],t):this.moveRows(n,t))}getRowIndexNumber(e){return parseInt(Pe(e.getRowIndexString().split("-")),10)}moveRowAndClearHighlight(e){const t=this.clientSideRowModel.getLastHighlightedRowNode(),i=t&&1===t.highlighted,r=this.mouseEventService.getNormalisedPosition(e).y,n=e.dragItem.rowNodes;let s=i?1:0;if(this.isFromThisGrid(e))n.forEach(e=>{e.rowTop<r&&(s-=1)}),this.moveRows(n,r,s);else{const e=this.gos.getCallback("getRowId");let t=this.clientSideRowModel.getRowIndexAtPixel(r)+1;0===this.clientSideRowModel.getHighlightPosition(r)&&t--,this.clientSideRowModel.updateRowData({add:n.map(e=>e.data).filter(t=>!this.clientSideRowModel.getRowNode(e?e({data:t,level:0}):t.id)),addIndex:t})}this.clearRowHighlight()}clearRowHighlight(){this.clientSideRowModel.highlightRowAtPixel(null)}moveRows(e,t,i=0){var r;this.clientSideRowModel.ensureRowsAtPixel(e,t,i)&&(this.focusService.clearFocusedCell(),null==(r=this.rangeService)||r.removeAllCellRanges())}addRowDropZone(e){if(!e.getContainer())return void U("addRowDropZone - A container target needs to be provided");if(this.dragAndDropService.findExternalZone(e))return void console.warn("AG Grid: addRowDropZone - target already exists in the list of DropZones. Use `removeRowDropZone` before adding it again.");let t={getContainer:e.getContainer};e.fromGrid?t=e:(e.onDragEnter&&(t.onDragEnter=t=>{e.onDragEnter(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_ENTER,t))}),e.onDragLeave&&(t.onDragLeave=t=>{e.onDragLeave(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_LEAVE,t))}),e.onDragging&&(t.onDragging=t=>{e.onDragging(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_MOVE,t))}),e.onDragStop&&(t.onDragStop=t=>{e.onDragStop(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_END,t))})),this.dragAndDropService.addDropTarget(h({isInterestedIn:e=>2===e,getIconName:()=>Vs.ICON_MOVE,external:!0},t))}getRowDropZone(e){const t=this.getContainer.bind(this),i=this.onDragEnter.bind(this),r=this.onDragLeave.bind(this),n=this.onDragging.bind(this),s=this.onDragStop.bind(this);return e?{getContainer:t,onDragEnter:e.onDragEnter?t=>{i(t),e.onDragEnter(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_ENTER,t))}:i,onDragLeave:e.onDragLeave?t=>{r(t),e.onDragLeave(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_LEAVE,t))}:r,onDragging:e.onDragging?t=>{n(t),e.onDragging(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_MOVE,t))}:n,onDragStop:e.onDragStop?t=>{s(t),e.onDragStop(this.draggingToRowDragEvent(ct.EVENT_ROW_DRAG_END,t))}:s,fromGrid:!0}:{getContainer:t,onDragEnter:i,onDragLeave:r,onDragging:n,onDragStop:s,fromGrid:!0}}draggingToRowDragEvent(e,t){const i=this.mouseEventService.getNormalisedPosition(t).y;let r,n,s=-1;switch(i>this.paginationProxy.getCurrentPageHeight()||(s=this.rowModel.getRowIndexAtPixel(i),r=this.rowModel.getRow(s)),t.vDirection){case 1:n="down";break;case 0:n="up";break;default:n=null}return this.gos.addGridCommonParams({type:e,event:t.event,node:t.dragItem.rowNode,nodes:t.dragItem.rowNodes,overIndex:s,overNode:r,y:i,vDirection:n})}dispatchGridEvent(e,t){const i=this.draggingToRowDragEvent(e,t);this.eventService.dispatchEvent(i)}onDragLeave(e){this.dispatchGridEvent(ct.EVENT_ROW_DRAG_LEAVE,e),this.stopDragging(e),this.gos.get("rowDragManaged")&&this.clearRowHighlight()}onDragStop(e){this.dispatchGridEvent(ct.EVENT_ROW_DRAG_END,e),this.stopDragging(e),!this.gos.get("rowDragManaged")||!this.gos.get("suppressMoveWhenRowDragging")&&this.isFromThisGrid(e)||this.isDropZoneWithinThisGrid(e)||this.moveRowAndClearHighlight(e)}stopDragging(e){this.autoScrollService.ensureCleared(),this.getRowNodes(e).forEach(e=>{e.setDragging(!1)})}};g([he("dragAndDropService")],Go.prototype,"dragAndDropService",2),g([he("rowModel")],Go.prototype,"rowModel",2),g([he("paginationProxy")],Go.prototype,"paginationProxy",2),g([he("columnModel")],Go.prototype,"columnModel",2),g([he("focusService")],Go.prototype,"focusService",2),g([he("sortController")],Go.prototype,"sortController",2),g([he("filterManager")],Go.prototype,"filterManager",2),g([he("selectionService")],Go.prototype,"selectionService",2),g([he("mouseEventService")],Go.prototype,"mouseEventService",2),g([he("ctrlsService")],Go.prototype,"ctrlsService",2),g([de("rangeService")],Go.prototype,"rangeService",2),g([le],Go.prototype,"postConstruct",1);var Vo=class extends nt{constructor(){super(...arguments),this.dragEndFunctions=[],this.dragSources=[]}removeAllListeners(){this.dragSources.forEach(this.removeListener.bind(this)),this.dragSources.length=0}removeListener(e){const t=e.dragSource.eElement,i=e.mouseDownListener;if(t.removeEventListener("mousedown",i),e.touchEnabled){const i=e.touchStartListener;t.removeEventListener("touchstart",i,{passive:!0})}}removeDragSource(e){const t=this.dragSources.find(t=>t.dragSource===e);t&&(this.removeListener(t),Oe(this.dragSources,t))}isDragging(){return this.dragging}addDragSource(e){const t=this.onMouseDown.bind(this,e),{eElement:i,includeTouch:r,stopPropagationForTouch:n}=e;i.addEventListener("mousedown",t);let s=null;const o=this.gos.get("suppressTouch");r&&!o&&(s=t=>{sr(t.target)||(t.cancelable&&(t.preventDefault(),n&&t.stopPropagation()),this.onTouchStart(e,t))},i.addEventListener("touchstart",s,{passive:!1})),this.dragSources.push({dragSource:e,mouseDownListener:t,touchStartListener:s,touchEnabled:!!r})}getStartTarget(){return this.startTarget}onTouchStart(e,t){this.currentDragParams=e,this.dragging=!1;const i=t.touches[0];this.touchLastTime=i,this.touchStart=i;const r=t=>this.onTouchUp(t,e.eElement),n=t.target,s=[{target:this.gos.getRootNode(),type:"touchmove",listener:e=>{e.cancelable&&e.preventDefault()},options:{passive:!1}},{target:n,type:"touchmove",listener:t=>this.onTouchMove(t,e.eElement),options:{passive:!0}},{target:n,type:"touchend",listener:r,options:{passive:!0}},{target:n,type:"touchcancel",listener:r,options:{passive:!0}}];this.addTemporaryEvents(s),0===e.dragStartPixels&&this.onCommonMove(i,this.touchStart,e.eElement)}onMouseDown(e,t){const i=t;if(e.skipMouseEvent&&e.skipMouseEvent(t))return;if(i._alreadyProcessedByDragService)return;if(i._alreadyProcessedByDragService=!0,0!==t.button)return;this.shouldPreventMouseEvent(t)&&t.preventDefault(),this.currentDragParams=e,this.dragging=!1,this.mouseStartEvent=t,this.startTarget=t.target;const r=this.gos.getRootNode(),n=[{target:r,type:"mousemove",listener:t=>this.onMouseMove(t,e.eElement)},{target:r,type:"mouseup",listener:t=>this.onMouseUp(t,e.eElement)},{target:r,type:"contextmenu",listener:e=>e.preventDefault()}];this.addTemporaryEvents(n),0===e.dragStartPixels&&this.onMouseMove(t,e.eElement)}addTemporaryEvents(e){e.forEach(e=>{const{target:t,type:i,listener:r,options:n}=e;t.addEventListener(i,r,n)}),this.dragEndFunctions.push(()=>{e.forEach(e=>{const{target:t,type:i,listener:r,options:n}=e;t.removeEventListener(i,r,n)})})}isEventNearStartEvent(e,t){const{dragStartPixels:i}=this.currentDragParams;return nn(e,t,y(i)?i:4)}getFirstActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}onCommonMove(e,t,i){if(!this.dragging){if(!this.dragging&&this.isEventNearStartEvent(e,t))return;this.dragging=!0;const r={type:ct.EVENT_DRAG_STARTED,target:i};this.eventService.dispatchEvent(r),this.currentDragParams.onDragStart(t),this.currentDragParams.onDragging(t)}this.currentDragParams.onDragging(e)}onTouchMove(e,t){const i=this.getFirstActiveTouch(e.touches);i&&this.onCommonMove(i,this.touchStart,t)}onMouseMove(e,t){var i;Ri()&&(null==(i=this.gos.getDocument().getSelection())||i.removeAllRanges()),this.shouldPreventMouseEvent(e)&&e.preventDefault(),this.onCommonMove(e,this.mouseStartEvent,t)}shouldPreventMouseEvent(e){const t=this.gos.get("enableCellTextSelection"),i="mousemove"===e.type;return t&&i&&e.cancelable&&this.mouseEventService.isEventFromThisGrid(e)&&!this.isOverFormFieldElement(e)}isOverFormFieldElement(e){const t=e.target,i=null==t?void 0:t.tagName.toLocaleLowerCase();return!!(null==i?void 0:i.match("^a$|textarea|input|select|button"))}onTouchUp(e,t){let i=this.getFirstActiveTouch(e.changedTouches);i||(i=this.touchLastTime),this.onUpCommon(i,t)}onMouseUp(e,t){this.onUpCommon(e,t)}onUpCommon(e,t){if(this.dragging){this.dragging=!1,this.currentDragParams.onDragStop(e);const i={type:ct.EVENT_DRAG_STOPPED,target:t};this.eventService.dispatchEvent(i)}this.mouseStartEvent=null,this.startTarget=null,this.touchStart=null,this.touchLastTime=null,this.currentDragParams=null,this.dragEndFunctions.forEach(e=>e()),this.dragEndFunctions.length=0}};g([he("mouseEventService")],Vo.prototype,"mouseEventService",2),g([ce],Vo.prototype,"removeAllListeners",1),Vo=g([ue("dragService")],Vo);var Ho="ag-list-item-hovered",Bo=class extends nt{constructor(e,t,i){super(),this.comp=e,this.virtualList=t,this.params=i,this.currentDragValue=null,this.lastHoveredListItem=null}postConstruct(){this.addManagedListener(this.params.eventSource,this.params.listItemDragStartEvent,this.listItemDragStart.bind(this)),this.addManagedListener(this.params.eventSource,this.params.listItemDragEndEvent,this.listItemDragEnd.bind(this)),this.createDropTarget(),this.createAutoScrollService()}listItemDragStart(e){this.currentDragValue=this.params.getCurrentDragValue(e),this.moveBlocked=this.params.isMoveBlocked(this.currentDragValue)}listItemDragEnd(){window.setTimeout(()=>{this.currentDragValue=null,this.moveBlocked=!1},10)}createDropTarget(){const e={isInterestedIn:e=>e===this.params.dragSourceType,getIconName:()=>this.moveBlocked?Vs.ICON_PINNED:Vs.ICON_MOVE,getContainer:()=>this.comp.getGui(),onDragging:e=>this.onDragging(e),onDragStop:()=>this.onDragStop(),onDragLeave:()=>this.onDragLeave()};this.dragAndDropService.addDropTarget(e)}createAutoScrollService(){const e=this.virtualList.getGui();this.autoScrollService=new ko({scrollContainer:e,scrollAxis:"y",getVerticalPosition:()=>e.scrollTop,setVerticalPosition:t=>e.scrollTop=t})}onDragging(e){if(!this.currentDragValue||this.moveBlocked)return;const t=this.getListDragItem(e),i=this.virtualList.getComponentAt(t.rowIndex);if(!i)return;const r=i.getGui().parentElement;this.lastHoveredListItem&&this.lastHoveredListItem.rowIndex===t.rowIndex&&this.lastHoveredListItem.position===t.position||(this.autoScrollService.check(e.event),this.clearHoveredItems(),this.lastHoveredListItem=t,ir(r,Ho),ir(r,`ag-item-highlight-${t.position}`))}getListDragItem(e){const t=this.virtualList.getGui(),i=parseFloat(window.getComputedStyle(t).paddingTop),r=this.virtualList.getRowHeight(),n=this.virtualList.getScrollTop(),s=Math.max(0,(e.y-i+n)/r),o=this.params.getNumRows(this.comp)-1,a=0|Math.min(o,s);return{rowIndex:a,position:Math.round(s)>s||s>o?"bottom":"top",component:this.virtualList.getComponentAt(a)}}onDragStop(){this.moveBlocked||(this.params.moveItem(this.currentDragValue,this.lastHoveredListItem),this.clearHoveredItems(),this.autoScrollService.ensureCleared())}onDragLeave(){this.clearHoveredItems(),this.autoScrollService.ensureCleared()}clearHoveredItems(){this.virtualList.getGui().querySelectorAll(`.${Ho}`).forEach(e=>{[Ho,"ag-item-highlight-top","ag-item-highlight-bottom"].forEach(t=>{e.classList.remove(t)})}),this.lastHoveredListItem=null}};function zo(e){const t=e;return null!=t&&null!=t.getFrameworkComponentInstance?t.getFrameworkComponentInstance():e}g([he("dragAndDropService")],Bo.prototype,"dragAndDropService",2),g([le],Bo.prototype,"postConstruct",1);var Uo=class{constructor(){this.detailGridInfoMap={},this.destroyCalled=!1}init(){switch(this.rowModel.getType()){case"clientSide":this.clientSideRowModel=this.rowModel;break;case"infinite":this.infiniteRowModel=this.rowModel;break;case"serverSide":this.serverSideRowModel=this.rowModel}this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl})}__getAlignedGridService(){return this.alignedGridsService}getGridId(){return this.context.getGridId()}addDetailGridInfo(e,t){this.detailGridInfoMap[e]=t}removeDetailGridInfo(e){delete this.detailGridInfoMap[e]}getDetailGridInfo(e){return this.detailGridInfoMap[e]}forEachDetailGridInfo(e){let t=0;I(this.detailGridInfoMap,(i,r)=>{y(r)&&(e(r,t),t++)})}getDataAsCsv(e){if(se.__assertRegistered("@ag-grid-community/csv-export","api.getDataAsCsv",this.context.getGridId()))return this.csvCreator.getDataAsCsv(e)}exportDataAsCsv(e){se.__assertRegistered("@ag-grid-community/csv-export","api.exportDataAsCsv",this.context.getGridId())&&this.csvCreator.exportDataAsCsv(e)}assertNotExcelMultiSheet(e,t){return!(!se.__assertRegistered("@ag-grid-enterprise/excel-export","api."+e,this.context.getGridId())||1===this.excelCreator.getFactoryMode()&&(console.warn("AG Grid: The Excel Exporter is currently on Multi Sheet mode. End that operation by calling 'api.getMultipleSheetAsExcel()' or 'api.exportMultipleSheetsAsExcel()'"),1))}getDataAsExcel(e){if(this.assertNotExcelMultiSheet("getDataAsExcel",e))return this.excelCreator.getDataAsExcel(e)}exportDataAsExcel(e){this.assertNotExcelMultiSheet("exportDataAsExcel",e)&&this.excelCreator.exportDataAsExcel(e)}getSheetDataForExcel(e){if(se.__assertRegistered("@ag-grid-enterprise/excel-export","api.getSheetDataForExcel",this.context.getGridId()))return this.excelCreator.setFactoryMode(1),this.excelCreator.getSheetDataForExcel(e)}getMultipleSheetsAsExcel(e){if(se.__assertRegistered("@ag-grid-enterprise/excel-export","api.getMultipleSheetsAsExcel",this.context.getGridId()))return this.excelCreator.getMultipleSheetsAsExcel(e)}exportMultipleSheetsAsExcel(e){se.__assertRegistered("@ag-grid-enterprise/excel-export","api.exportMultipleSheetsAsExcel",this.context.getGridId())&&this.excelCreator.exportMultipleSheetsAsExcel(e)}setGridAriaProperty(e,t){if(!e)return;const i=this.ctrlsService.getGridBodyCtrl().getGui(),r=`aria-${e}`;null===t?i.removeAttribute(r):i.setAttribute(r,t)}logMissingRowModel(e,...t){console.error(`AG Grid: api.${e} can only be called when gridOptions.rowModelType is ${t.join(" or ")}`)}logDeprecation(e,t,i,r){U(`Since ${e} api.${t} is deprecated. Please use ${i} instead. ${null!=r?r:""}`)}getPinnedTopRowCount(){return this.pinnedRowModel.getPinnedTopRowCount()}getPinnedBottomRowCount(){return this.pinnedRowModel.getPinnedBottomRowCount()}getPinnedTopRow(e){return this.pinnedRowModel.getPinnedTopRow(e)}getPinnedBottomRow(e){return this.pinnedRowModel.getPinnedBottomRow(e)}expireValueCache(){this.valueCache.expire()}getVerticalPixelRange(){return this.gridBodyCtrl.getScrollFeature().getVScrollPosition()}getHorizontalPixelRange(){return this.gridBodyCtrl.getScrollFeature().getHScrollPosition()}refreshCells(e={}){this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.refreshCells(e))}flashCells(e={}){const t=e=>U(`Since v31.1 api.flashCells parameter '${e}Delay' is deprecated. Please use '${e}Duration' instead.`);y(e.fadeDelay)&&t("fade"),y(e.flashDelay)&&t("flash"),this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.flashCells(e))}redrawRows(e={}){const t=e?e.rowNodes:void 0;this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.redrawRows(t))}refreshHeader(){this.frameworkOverrides.wrapIncoming(()=>this.ctrlsService.getHeaderRowContainerCtrls().forEach(e=>e.refresh()))}isAnyFilterPresent(){return this.filterManager.isAnyFilterPresent()}isColumnFilterPresent(){return this.filterManager.isColumnFilterPresent()||this.filterManager.isAggregateFilterPresent()}isQuickFilterPresent(){return this.filterManager.isQuickFilterPresent()}getModel(){return U("Since v31.1 getModel() is deprecated. Please use the appropriate grid API methods instead."),this.rowModel}setRowNodeExpanded(e,t,i,r){this.expansionService.setRowNodeExpanded(e,t,i,r)}onGroupExpandedOrCollapsed(){w(this.clientSideRowModel)?this.logMissingRowModel("onGroupExpandedOrCollapsed","clientSide"):this.expansionService.onGroupExpandedOrCollapsed()}refreshClientSideRowModel(e){w(this.clientSideRowModel)?this.logMissingRowModel("refreshClientSideRowModel","clientSide"):this.clientSideRowModel.refreshModel(e)}isAnimationFrameQueueEmpty(){return this.animationFrameService.isQueueEmpty()}flushAllAnimationFrames(){this.animationFrameService.flushAllFrames()}getRowNode(e){return this.rowModel.getRowNode(e)}getSizesForCurrentTheme(){return{rowHeight:this.gos.getRowHeightAsNumber(),headerHeight:this.columnModel.getHeaderHeight()}}expandAll(){this.clientSideRowModel||this.serverSideRowModel?this.expansionService.expandAll(!0):this.logMissingRowModel("expandAll","clientSide","serverSide")}collapseAll(){this.clientSideRowModel||this.serverSideRowModel?this.expansionService.expandAll(!1):this.logMissingRowModel("collapseAll","clientSide","serverSide")}addRenderedRowListener(e,t,i){this.rowRenderer.addRenderedRowListener(e,t,i)}getQuickFilter(){return this.gos.get("quickFilterText")}getAdvancedFilterModel(){return se.__assertRegistered("@ag-grid-enterprise/advanced-filter","api.getAdvancedFilterModel",this.context.getGridId())?this.filterManager.getAdvancedFilterModel():null}setAdvancedFilterModel(e){this.filterManager.setAdvancedFilterModel(e)}showAdvancedFilterBuilder(){se.__assertRegistered("@ag-grid-enterprise/advanced-filter","api.setAdvancedFilterModel",this.context.getGridId())&&this.filterManager.showAdvancedFilterBuilder("api")}setNodesSelected(e){if(!e.nodes.every(e=>e.rowPinned?(console.warn("AG Grid: cannot select pinned rows"),!1):void 0!==e.id||(console.warn("AG Grid: cannot select node until id for node is known"),!1)))return;const{nodes:t,source:i,newValue:r}=e,n=t;this.selectionService.setNodesSelected({nodes:n,source:null!=i?i:"api",newValue:r})}selectAll(e="apiSelectAll"){this.selectionService.selectAllRowNodes({source:e})}deselectAll(e="apiSelectAll"){this.selectionService.deselectAllRowNodes({source:e})}selectAllFiltered(e="apiSelectAllFiltered"){this.selectionService.selectAllRowNodes({source:e,justFiltered:!0})}deselectAllFiltered(e="apiSelectAllFiltered"){this.selectionService.deselectAllRowNodes({source:e,justFiltered:!0})}getServerSideSelectionState(){return w(this.serverSideRowModel)?(this.logMissingRowModel("getServerSideSelectionState","serverSide"),null):this.selectionService.getSelectionState()}setServerSideSelectionState(e){w(this.serverSideRowModel)?this.logMissingRowModel("setServerSideSelectionState","serverSide"):this.selectionService.setSelectionState(e,"api")}selectAllOnCurrentPage(e="apiSelectAllCurrentPage"){this.selectionService.selectAllRowNodes({source:e,justCurrentPage:!0})}deselectAllOnCurrentPage(e="apiSelectAllCurrentPage"){this.selectionService.deselectAllRowNodes({source:e,justCurrentPage:!0})}showLoadingOverlay(){this.overlayService.showLoadingOverlay()}showNoRowsOverlay(){this.overlayService.showNoRowsOverlay()}hideOverlay(){this.overlayService.hideOverlay()}getSelectedNodes(){return this.selectionService.getSelectedNodes()}getSelectedRows(){return this.selectionService.getSelectedRows()}getBestCostNodeSelection(){if(!w(this.clientSideRowModel))return this.selectionService.getBestCostNodeSelection();this.logMissingRowModel("getBestCostNodeSelection","clientSide")}getRenderedNodes(){return this.rowRenderer.getRenderedNodes()}ensureColumnVisible(e,t="auto"){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureColumnVisible(e,t),"ensureVisible")}ensureIndexVisible(e,t){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureIndexVisible(e,t),"ensureVisible")}ensureNodeVisible(e,t=null){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureNodeVisible(e,t),"ensureVisible")}forEachLeafNode(e){w(this.clientSideRowModel)?this.logMissingRowModel("forEachLeafNode","clientSide"):this.clientSideRowModel.forEachLeafNode(e)}forEachNode(e,t){this.rowModel.forEachNode(e,t)}forEachNodeAfterFilter(e){w(this.clientSideRowModel)?this.logMissingRowModel("forEachNodeAfterFilter","clientSide"):this.clientSideRowModel.forEachNodeAfterFilter(e)}forEachNodeAfterFilterAndSort(e){w(this.clientSideRowModel)?this.logMissingRowModel("forEachNodeAfterFilterAndSort","clientSide"):this.clientSideRowModel.forEachNodeAfterFilterAndSort(e)}getFilterInstance(e,t){return U("'getFilterInstance' is deprecated. To get/set individual filter models, use 'getColumnFilterModel' or 'setColumnFilterModel' instead. To get hold of the filter instance, use 'getColumnFilterInstance' which returns the instance asynchronously."),this.filterManager.getFilterInstance(e,t)}getColumnFilterInstance(e){return this.filterManager.getColumnFilterInstance(e)}destroyFilter(e){const t=this.columnModel.getPrimaryColumn(e);if(t)return this.filterManager.destroyFilter(t,"api")}getStatusPanel(e){if(se.__assertRegistered("@ag-grid-enterprise/status-bar","api.getStatusPanel",this.context.getGridId()))return zo(this.statusBarService.getStatusPanel(e))}getColumnDef(e){const t=this.columnModel.getPrimaryColumn(e);return t?t.getColDef():null}getColumnDefs(){return this.columnModel.getColumnDefs()}onFilterChanged(e="api"){this.filterManager.onFilterChanged({source:e})}onSortChanged(){this.sortController.onSortChanged("api")}setFilterModel(e){this.frameworkOverrides.wrapIncoming(()=>this.filterManager.setFilterModel(e))}getFilterModel(){return this.filterManager.getFilterModel()}getColumnFilterModel(e){return this.filterManager.getColumnFilterModel(e)}setColumnFilterModel(e,t){return this.filterManager.setColumnFilterModel(e,t)}getFocusedCell(){return this.focusService.getFocusedCell()}clearFocusedCell(){return this.focusService.clearFocusedCell()}setFocusedCell(e,t,i){this.focusService.setFocusedCell({rowIndex:e,column:t,rowPinned:i,forceBrowserFocus:!0})}addRowDropZone(e){this.gridBodyCtrl.getRowDragFeature().addRowDropZone(e)}removeRowDropZone(e){const t=this.dragAndDropService.findExternalZone(e);t&&this.dragAndDropService.removeDropTarget(t)}getRowDropZoneParams(e){return this.gridBodyCtrl.getRowDragFeature().getRowDropZone(e)}assertSideBarLoaded(e){return se.__assertRegistered("@ag-grid-enterprise/side-bar","api."+e,this.context.getGridId())}isSideBarVisible(){return this.assertSideBarLoaded("isSideBarVisible")&&this.sideBarService.getSideBarComp().isDisplayed()}setSideBarVisible(e){this.assertSideBarLoaded("setSideBarVisible")&&this.sideBarService.getSideBarComp().setDisplayed(e)}setSideBarPosition(e){this.assertSideBarLoaded("setSideBarPosition")&&this.sideBarService.getSideBarComp().setSideBarPosition(e)}openToolPanel(e){this.assertSideBarLoaded("openToolPanel")&&this.sideBarService.getSideBarComp().openToolPanel(e,"api")}closeToolPanel(){this.assertSideBarLoaded("closeToolPanel")&&this.sideBarService.getSideBarComp().close("api")}getOpenedToolPanel(){return this.assertSideBarLoaded("getOpenedToolPanel")?this.sideBarService.getSideBarComp().openedItem():null}refreshToolPanel(){this.assertSideBarLoaded("refreshToolPanel")&&this.sideBarService.getSideBarComp().refresh()}isToolPanelShowing(){return this.assertSideBarLoaded("isToolPanelShowing")&&this.sideBarService.getSideBarComp().isToolPanelShowing()}getToolPanelInstance(e){if(this.assertSideBarLoaded("getToolPanelInstance"))return zo(this.sideBarService.getSideBarComp().getToolPanelInstance(e))}getSideBar(){if(this.assertSideBarLoaded("getSideBar"))return this.sideBarService.getSideBarComp().getDef()}resetRowHeights(){if(y(this.clientSideRowModel)){if(this.columnModel.isAutoRowHeightActive())return void console.warn("AG Grid: calling gridApi.resetRowHeights() makes no sense when using Auto Row Height.");this.clientSideRowModel.resetRowHeights()}}setRowCount(e,t){if(this.serverSideRowModel)return this.columnModel.isRowGroupEmpty()?void this.serverSideRowModel.setRowCount(e,t):void console.error("AG Grid: setRowCount cannot be used while using row grouping.");this.infiniteRowModel?this.infiniteRowModel.setRowCount(e,t):this.logMissingRowModel("setRowCount","infinite","serverSide")}onRowHeightChanged(){this.clientSideRowModel?this.clientSideRowModel.onRowHeightChanged():this.serverSideRowModel&&this.serverSideRowModel.onRowHeightChanged()}getValue(e,t){return this.logDeprecation("31.3","getValue","getCellValue"),this.getCellValue({colKey:e,rowNode:t})}getCellValue(e){var t;const{colKey:i,rowNode:r,useFormatter:n}=e;let s=null!=(t=this.columnModel.getPrimaryColumn(i))?t:this.columnModel.getGridColumn(i);if(w(s))return null;const o=this.valueService.getValue(s,r);if(n){const e=this.valueService.formatValue(s,r,o);return null!=e?e:yt(o,!0)}return o}addEventListener(e,t){this.apiEventService.addEventListener(e,t)}addGlobalListener(e){this.apiEventService.addGlobalListener(e)}removeEventListener(e,t){this.apiEventService.removeEventListener(e,t)}removeGlobalListener(e){this.apiEventService.removeGlobalListener(e)}dispatchEvent(e){this.eventService.dispatchEvent(e)}destroy(){var e;const t=`See ${this.frameworkOverrides.getDocLink("grid-lifecycle/#grid-pre-destroyed")}`;if(this.destroyCalled)return;const i={type:ct.EVENT_GRID_PRE_DESTROYED,state:this.getState()};this.dispatchEvent(i),this.destroyCalled=!0,null==(e=this.ctrlsService.get("gridCtrl"))||e.destroyGridUi(),this.context.destroy(),this.detailGridInfoMap={},G(this,["isDestroyed"],t)}isDestroyed(){return this.destroyCalled}resetQuickFilter(){this.filterManager.resetQuickFilterCache()}getCellRanges(){return this.rangeService?this.rangeService.getCellRanges():(se.__assertRegistered("@ag-grid-enterprise/range-selection","api.getCellRanges",this.context.getGridId()),null)}addCellRange(e){this.rangeService?this.rangeService.addCellRange(e):se.__assertRegistered("@ag-grid-enterprise/range-selection","api.addCellRange",this.context.getGridId())}clearRangeSelection(){this.rangeService&&this.rangeService.removeAllCellRanges(),se.__assertRegistered("@ag-grid-enterprise/range-selection","gridApi.clearRangeSelection",this.context.getGridId())}undoCellEditing(){this.undoRedoService.undo("api")}redoCellEditing(){this.undoRedoService.redo("api")}getCurrentUndoSize(){return this.undoRedoService.getCurrentUndoStackSize()}getCurrentRedoSize(){return this.undoRedoService.getCurrentRedoStackSize()}assertChart(e,t){if(se.__assertRegistered("@ag-grid-enterprise/charts","api."+e,this.context.getGridId()))return this.frameworkOverrides.wrapIncoming(()=>t())}getChartModels(){return this.assertChart("getChartModels",()=>this.chartService.getChartModels())}getChartRef(e){return this.assertChart("getChartRef",()=>this.chartService.getChartRef(e))}getChartImageDataURL(e){return this.assertChart("getChartImageDataURL",()=>this.chartService.getChartImageDataURL(e))}downloadChart(e){return this.assertChart("downloadChart",()=>this.chartService.downloadChart(e))}openChartToolPanel(e){return this.assertChart("openChartToolPanel",()=>this.chartService.openChartToolPanel(e))}closeChartToolPanel(e){return this.assertChart("closeChartToolPanel",()=>this.chartService.closeChartToolPanel(e.chartId))}createRangeChart(e){return this.assertChart("createRangeChart",()=>this.chartService.createRangeChart(e))}createPivotChart(e){return this.assertChart("createPivotChart",()=>this.chartService.createPivotChart(e))}createCrossFilterChart(e){return this.assertChart("createCrossFilterChart",()=>this.chartService.createCrossFilterChart(e))}updateChart(e){return this.assertChart("updateChart",()=>this.chartService.updateChart(e))}restoreChart(e,t){return this.assertChart("restoreChart",()=>this.chartService.restoreChart(e,t))}assertClipboard(e,t){se.__assertRegistered("@ag-grid-enterprise/clipboard","api"+e,this.context.getGridId())&&t()}copyToClipboard(e){this.assertClipboard("copyToClipboard",()=>this.clipboardService.copyToClipboard(e))}cutToClipboard(e){this.assertClipboard("cutToClipboard",()=>this.clipboardService.cutToClipboard(e))}copySelectedRowsToClipboard(e){this.assertClipboard("copySelectedRowsToClipboard",()=>this.clipboardService.copySelectedRowsToClipboard(e))}copySelectedRangeToClipboard(e){this.assertClipboard("copySelectedRangeToClipboard",()=>this.clipboardService.copySelectedRangeToClipboard(e))}copySelectedRangeDown(){this.assertClipboard("copySelectedRangeDown",()=>this.clipboardService.copyRangeDown())}pasteFromClipboard(){this.assertClipboard("pasteFromClipboard",()=>this.clipboardService.pasteFromClipboard())}showColumnMenuAfterButtonClick(e,t){U("'showColumnMenuAfterButtonClick' is deprecated. Use 'IHeaderParams.showColumnMenu' within a header component, or 'api.showColumnMenu' elsewhere.");const i=this.columnModel.getGridColumn(e);this.menuService.showColumnMenu({column:i,buttonElement:t,positionBy:"button"})}showColumnMenuAfterMouseClick(e,t){U("'showColumnMenuAfterMouseClick' is deprecated. Use 'IHeaderParams.showColumnMenuAfterMouseClick' within a header component, or 'api.showColumnMenu' elsewhere.");let i=this.columnModel.getGridColumn(e);i||(i=this.columnModel.getPrimaryColumn(e)),i?this.menuService.showColumnMenu({column:i,mouseEvent:t,positionBy:"mouse"}):console.error(`AG Grid: column '${e}' not found`)}showContextMenu(e){const{rowNode:t,column:i,value:r,x:n,y:s}=e||{};let{x:o,y:a}=this.menuService.getContextMenuPosition(t,i);null!=n&&(o=n),null!=s&&(a=s),this.menuService.showContextMenu({mouseEvent:new MouseEvent("mousedown",{clientX:o,clientY:a}),rowNode:t,column:i,value:r})}showColumnChooser(e){this.menuService.showColumnChooser({chooserParams:e})}showColumnFilter(e){const t=this.columnModel.getGridColumn(e);t?this.menuService.showFilterMenu({column:t,containerType:"columnFilter",positionBy:"auto"}):console.error(`AG Grid: column '${e}' not found`)}showColumnMenu(e){const t=this.columnModel.getGridColumn(e);t?this.menuService.showColumnMenu({column:t,positionBy:"auto"}):console.error(`AG Grid: column '${e}' not found`)}hidePopupMenu(){this.menuService.hidePopupMenu()}hideColumnChooser(){this.menuService.hideColumnChooser()}tabToNextCell(e){return this.navigationService.tabToNextCell(!1,e)}tabToPreviousCell(e){return this.navigationService.tabToNextCell(!0,e)}getCellRendererInstances(e={}){return this.rowRenderer.getCellRendererInstances(e).map(zo)}getCellEditorInstances(e={}){return this.rowRenderer.getCellEditorInstances(e).map(zo)}getEditingCells(){return this.rowRenderer.getEditingCells()}stopEditing(e=!1){this.rowRenderer.stopEditing(e)}startEditingCell(e){const t=this.columnModel.getGridColumn(e.colKey);if(!t)return void console.warn(`AG Grid: no column found for ${e.colKey}`);const i={rowIndex:e.rowIndex,rowPinned:e.rowPinned||null,column:t};null==e.rowPinned&&this.ensureIndexVisible(e.rowIndex),this.ensureColumnVisible(e.colKey);const r=this.navigationService.getCellByPosition(i);r&&(this.focusService.isCellFocused(i)||this.focusService.setFocusedCell(i),r.startRowOrCellEdit(e.key))}addAggFunc(e,t){this.logDeprecation("v31.1","addAggFunc(key, func)","addAggFuncs({ key: func })"),this.aggFuncService&&this.aggFuncService.addAggFuncs({key:t})}addAggFuncs(e){this.aggFuncService&&this.aggFuncService.addAggFuncs(e)}clearAggFuncs(){this.aggFuncService&&this.aggFuncService.clear()}applyServerSideTransaction(e){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.applyTransaction(e);this.logMissingRowModel("applyServerSideTransaction","serverSide")}applyServerSideTransactionAsync(e,t){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.applyTransactionAsync(e,t);this.logMissingRowModel("applyServerSideTransactionAsync","serverSide")}applyServerSideRowData(e){var t,i;const r=null!=(t=e.startRow)?t:0,n=null!=(i=e.route)?i:[];r<0?console.warn(`AG Grid: invalid value ${e.startRow} for startRow, the value should be >= 0`):this.serverSideRowModel?this.serverSideRowModel.applyRowData(e.successParams,r,n):this.logMissingRowModel("setServerSideDatasource","serverSide")}retryServerSideLoads(){this.serverSideRowModel?this.serverSideRowModel.retryLoads():this.logMissingRowModel("retryServerSideLoads","serverSide")}flushServerSideAsyncTransactions(){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.flushAsyncTransactions();this.logMissingRowModel("flushServerSideAsyncTransactions","serverSide")}applyTransaction(e){if(this.clientSideRowModel)return this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.updateRowData(e));this.logMissingRowModel("applyTransaction","clientSide")}applyTransactionAsync(e,t){this.clientSideRowModel?this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.batchUpdateRowData(e,t)):this.logMissingRowModel("applyTransactionAsync","clientSide")}flushAsyncTransactions(){this.clientSideRowModel?this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.flushAsyncTransactions()):this.logMissingRowModel("flushAsyncTransactions","clientSide")}refreshInfiniteCache(){this.infiniteRowModel?this.infiniteRowModel.refreshCache():this.logMissingRowModel("refreshInfiniteCache","infinite")}purgeInfiniteCache(){this.infiniteRowModel?this.infiniteRowModel.purgeCache():this.logMissingRowModel("purgeInfiniteCache","infinite")}refreshServerSide(e){this.serverSideRowModel?this.serverSideRowModel.refreshStore(e):this.logMissingRowModel("refreshServerSide","serverSide")}getServerSideGroupLevelState(){return this.serverSideRowModel?this.serverSideRowModel.getStoreState():(this.logMissingRowModel("getServerSideGroupLevelState","serverSide"),[])}getInfiniteRowCount(){if(this.infiniteRowModel)return this.infiniteRowModel.getRowCount();this.logMissingRowModel("getInfiniteRowCount","infinite")}isLastRowIndexKnown(){if(this.infiniteRowModel)return this.infiniteRowModel.isLastRowIndexKnown();this.logMissingRowModel("isLastRowIndexKnown","infinite")}getCacheBlockState(){return this.rowNodeBlockLoader.getBlockState()}getFirstDisplayedRow(){return this.logDeprecation("v31.1","getFirstDisplayedRow","getFirstDisplayedRowIndex"),this.getFirstDisplayedRowIndex()}getFirstDisplayedRowIndex(){return this.rowRenderer.getFirstVirtualRenderedRow()}getLastDisplayedRow(){return this.logDeprecation("v31.1","getLastDisplayedRow","getLastDisplayedRowIndex"),this.getLastDisplayedRowIndex()}getLastDisplayedRowIndex(){return this.rowRenderer.getLastVirtualRenderedRow()}getDisplayedRowAtIndex(e){return this.rowModel.getRow(e)}getDisplayedRowCount(){return this.rowModel.getRowCount()}paginationIsLastPageFound(){return this.paginationProxy.isLastPageFound()}paginationGetPageSize(){return this.paginationProxy.getPageSize()}paginationGetCurrentPage(){return this.paginationProxy.getCurrentPage()}paginationGetTotalPages(){return this.paginationProxy.getTotalPages()}paginationGetRowCount(){return this.paginationProxy.getMasterRowCount()}paginationGoToNextPage(){this.paginationProxy.goToNextPage()}paginationGoToPreviousPage(){this.paginationProxy.goToPreviousPage()}paginationGoToFirstPage(){this.paginationProxy.goToFirstPage()}paginationGoToLastPage(){this.paginationProxy.goToLastPage()}paginationGoToPage(e){this.paginationProxy.goToPage(e)}sizeColumnsToFit(e){"number"==typeof e?this.columnModel.sizeColumnsToFit(e,"api"):this.gridBodyCtrl.sizeColumnsToFit(e)}setColumnGroupOpened(e,t){this.columnModel.setColumnGroupOpened(e,t,"api")}getColumnGroup(e,t){return this.columnModel.getColumnGroup(e,t)}getProvidedColumnGroup(e){return this.columnModel.getProvidedColumnGroup(e)}getDisplayNameForColumn(e,t){return this.columnModel.getDisplayNameForColumn(e,t)||""}getDisplayNameForColumnGroup(e,t){return this.columnModel.getDisplayNameForColumnGroup(e,t)||""}getColumn(e){return this.columnModel.getPrimaryColumn(e)}getColumns(){return this.columnModel.getAllPrimaryColumns()}applyColumnState(e){return this.columnModel.applyColumnState(e,"api")}getColumnState(){return this.columnModel.getColumnState()}resetColumnState(){this.columnModel.resetColumnState("api")}getColumnGroupState(){return this.columnModel.getColumnGroupState()}setColumnGroupState(e){this.columnModel.setColumnGroupState(e,"api")}resetColumnGroupState(){this.columnModel.resetColumnGroupState("api")}isPinning(){return this.columnModel.isPinningLeft()||this.columnModel.isPinningRight()}isPinningLeft(){return this.columnModel.isPinningLeft()}isPinningRight(){return this.columnModel.isPinningRight()}getDisplayedColAfter(e){return this.columnModel.getDisplayedColAfter(e)}getDisplayedColBefore(e){return this.columnModel.getDisplayedColBefore(e)}setColumnVisible(e,t){this.logDeprecation("v31.1","setColumnVisible(key,visible)","setColumnsVisible([key],visible)"),this.columnModel.setColumnsVisible([e],t,"api")}setColumnsVisible(e,t){this.columnModel.setColumnsVisible(e,t,"api")}setColumnPinned(e,t){this.logDeprecation("v31.1","setColumnPinned(key,pinned)","setColumnsPinned([key],pinned)"),this.columnModel.setColumnsPinned([e],t,"api")}setColumnsPinned(e,t){this.columnModel.setColumnsPinned(e,t,"api")}getAllGridColumns(){return this.columnModel.getAllGridColumns()}getDisplayedLeftColumns(){return this.columnModel.getDisplayedLeftColumns()}getDisplayedCenterColumns(){return this.columnModel.getDisplayedCenterColumns()}getDisplayedRightColumns(){return this.columnModel.getDisplayedRightColumns()}getAllDisplayedColumns(){return this.columnModel.getAllDisplayedColumns()}getAllDisplayedVirtualColumns(){return this.columnModel.getViewportColumns()}moveColumn(e,t){this.logDeprecation("v31.1","moveColumn(key, toIndex)","moveColumns([key], toIndex)"),this.columnModel.moveColumns([e],t,"api")}moveColumnByIndex(e,t){this.columnModel.moveColumnByIndex(e,t,"api")}moveColumns(e,t){this.columnModel.moveColumns(e,t,"api")}moveRowGroupColumn(e,t){this.columnModel.moveRowGroupColumn(e,t,"api")}setColumnAggFunc(e,t){this.columnModel.setColumnAggFunc(e,t,"api")}setColumnWidth(e,t,i=!0,r="api"){this.logDeprecation("v31.1","setColumnWidth(col, width)","setColumnWidths([{key: col, newWidth: width}])"),this.columnModel.setColumnWidths([{key:e,newWidth:t}],!1,i,r)}setColumnWidths(e,t=!0,i="api"){this.columnModel.setColumnWidths(e,!1,t,i)}isPivotMode(){return this.columnModel.isPivotMode()}getPivotResultColumn(e,t){return this.columnModel.getSecondaryPivotColumn(e,t)}setValueColumns(e){this.columnModel.setValueColumns(e,"api")}getValueColumns(){return this.columnModel.getValueColumns()}removeValueColumn(e){this.logDeprecation("v31.1","removeValueColumn(colKey)","removeValueColumns([colKey])"),this.columnModel.removeValueColumns([e],"api")}removeValueColumns(e){this.columnModel.removeValueColumns(e,"api")}addValueColumn(e){this.logDeprecation("v31.1","addValueColumn(colKey)","addValueColumns([colKey])"),this.columnModel.addValueColumns([e],"api")}addValueColumns(e){this.columnModel.addValueColumns(e,"api")}setRowGroupColumns(e){this.columnModel.setRowGroupColumns(e,"api")}removeRowGroupColumn(e){this.logDeprecation("v31.1","removeRowGroupColumn(colKey)","removeRowGroupColumns([colKey])"),this.columnModel.removeRowGroupColumns([e],"api")}removeRowGroupColumns(e){this.columnModel.removeRowGroupColumns(e,"api")}addRowGroupColumn(e){this.logDeprecation("v31.1","addRowGroupColumn(colKey)","addRowGroupColumns([colKey])"),this.columnModel.addRowGroupColumns([e],"api")}addRowGroupColumns(e){this.columnModel.addRowGroupColumns(e,"api")}getRowGroupColumns(){return this.columnModel.getRowGroupColumns()}setPivotColumns(e){this.columnModel.setPivotColumns(e,"api")}removePivotColumn(e){this.logDeprecation("v31.1","removePivotColumn(colKey)","removePivotColumns([colKey])"),this.columnModel.removePivotColumns([e],"api")}removePivotColumns(e){this.columnModel.removePivotColumns(e,"api")}addPivotColumn(e){this.logDeprecation("v31.1","addPivotColumn(colKey)","addPivotColumns([colKey])"),this.columnModel.addPivotColumns([e],"api")}addPivotColumns(e){this.columnModel.addPivotColumns(e,"api")}getPivotColumns(){return this.columnModel.getPivotColumns()}getLeftDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeLeft()}getCenterDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeCentre()}getRightDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeRight()}getAllDisplayedColumnGroups(){return this.columnModel.getAllDisplayedTrees()}autoSizeColumn(e,t){return this.logDeprecation("v31.1","autoSizeColumn(key, skipHeader)","autoSizeColumns([key], skipHeader)"),this.columnModel.autoSizeColumns({columns:[e],skipHeader:t,source:"api"})}autoSizeColumns(e,t){this.columnModel.autoSizeColumns({columns:e,skipHeader:t,source:"api"})}autoSizeAllColumns(e){this.columnModel.autoSizeAllColumns("api",e)}setPivotResultColumns(e){this.columnModel.setSecondaryColumns(e,"api")}getPivotResultColumns(){return this.columnModel.getSecondaryColumns()}getState(){return this.stateService.getState()}getGridOption(e){return this.gos.get(e)}setGridOption(e,t){this.updateGridOptions({[e]:t})}updateGridOptions(e){this.gos.updateGridOptions({options:e})}__internalUpdateGridOptions(e,t){this.gos.updateGridOptions({options:e,force:t,source:"gridOptionsUpdated"})}deprecatedUpdateGridOption(e,t){U(`set${e.charAt(0).toUpperCase()}${e.slice(1,e.length)} is deprecated. Please use 'api.setGridOption('${e}', newValue)' or 'api.updateGridOptions({ ${e}: newValue })' instead.`),this.setGridOption(e,t)}setPivotMode(e){this.deprecatedUpdateGridOption("pivotMode",e)}setPinnedTopRowData(e){this.deprecatedUpdateGridOption("pinnedTopRowData",e)}setPinnedBottomRowData(e){this.deprecatedUpdateGridOption("pinnedBottomRowData",e)}setPopupParent(e){this.deprecatedUpdateGridOption("popupParent",e)}setSuppressModelUpdateAfterUpdateTransaction(e){this.deprecatedUpdateGridOption("suppressModelUpdateAfterUpdateTransaction",e)}setDataTypeDefinitions(e){this.deprecatedUpdateGridOption("dataTypeDefinitions",e)}setPagination(e){this.deprecatedUpdateGridOption("pagination",e)}paginationSetPageSize(e){this.deprecatedUpdateGridOption("paginationPageSize",e)}setSideBar(e){this.deprecatedUpdateGridOption("sideBar",e)}setSuppressClipboardPaste(e){this.deprecatedUpdateGridOption("suppressClipboardPaste",e)}setGroupRemoveSingleChildren(e){this.deprecatedUpdateGridOption("groupRemoveSingleChildren",e)}setGroupRemoveLowestSingleChildren(e){this.deprecatedUpdateGridOption("groupRemoveLowestSingleChildren",e)}setGroupDisplayType(e){this.deprecatedUpdateGridOption("groupDisplayType",e)}setGroupIncludeFooter(e){this.deprecatedUpdateGridOption("groupIncludeFooter",e)}setGroupIncludeTotalFooter(e){this.deprecatedUpdateGridOption("groupIncludeTotalFooter",e)}setRowClass(e){this.deprecatedUpdateGridOption("rowClass",e)}setDeltaSort(e){this.deprecatedUpdateGridOption("deltaSort",e)}setSuppressRowDrag(e){this.deprecatedUpdateGridOption("suppressRowDrag",e)}setSuppressMoveWhenRowDragging(e){this.deprecatedUpdateGridOption("suppressMoveWhenRowDragging",e)}setSuppressRowClickSelection(e){this.deprecatedUpdateGridOption("suppressRowClickSelection",e)}setEnableAdvancedFilter(e){this.deprecatedUpdateGridOption("enableAdvancedFilter",e)}setIncludeHiddenColumnsInAdvancedFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInAdvancedFilter",e)}setAdvancedFilterParent(e){this.deprecatedUpdateGridOption("advancedFilterParent",e)}setAdvancedFilterBuilderParams(e){this.deprecatedUpdateGridOption("advancedFilterBuilderParams",e)}setQuickFilter(e){U("setQuickFilter is deprecated. Please use 'api.setGridOption('quickFilterText', newValue)' or 'api.updateGridOptions({ quickFilterText: newValue })' instead."),this.gos.updateGridOptions({options:{quickFilterText:e}})}setExcludeHiddenColumnsFromQuickFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInQuickFilter",!e)}setIncludeHiddenColumnsInQuickFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInQuickFilter",e)}setQuickFilterParser(e){this.deprecatedUpdateGridOption("quickFilterParser",e)}setQuickFilterMatcher(e){this.deprecatedUpdateGridOption("quickFilterMatcher",e)}setAlwaysShowHorizontalScroll(e){this.deprecatedUpdateGridOption("alwaysShowHorizontalScroll",e)}setAlwaysShowVerticalScroll(e){this.deprecatedUpdateGridOption("alwaysShowVerticalScroll",e)}setFunctionsReadOnly(e){this.deprecatedUpdateGridOption("functionsReadOnly",e)}setColumnDefs(e,t="api"){U("setColumnDefs is deprecated. Please use 'api.setGridOption('columnDefs', newValue)' or 'api.updateGridOptions({ columnDefs: newValue })' instead."),this.gos.updateGridOptions({options:{columnDefs:e},source:t})}setAutoGroupColumnDef(e,t="api"){U("setAutoGroupColumnDef is deprecated. Please use 'api.setGridOption('autoGroupColumnDef', newValue)' or 'api.updateGridOptions({ autoGroupColumnDef: newValue })' instead."),this.gos.updateGridOptions({options:{autoGroupColumnDef:e},source:t})}setDefaultColDef(e,t="api"){U("setDefaultColDef is deprecated. Please use 'api.setGridOption('defaultColDef', newValue)' or 'api.updateGridOptions({ defaultColDef: newValue })' instead."),this.gos.updateGridOptions({options:{defaultColDef:e},source:t})}setColumnTypes(e,t="api"){U("setColumnTypes is deprecated. Please use 'api.setGridOption('columnTypes', newValue)' or 'api.updateGridOptions({ columnTypes: newValue })' instead."),this.gos.updateGridOptions({options:{columnTypes:e},source:t})}setTreeData(e){this.deprecatedUpdateGridOption("treeData",e)}setServerSideDatasource(e){this.deprecatedUpdateGridOption("serverSideDatasource",e)}setCacheBlockSize(e){this.deprecatedUpdateGridOption("cacheBlockSize",e)}setDatasource(e){this.deprecatedUpdateGridOption("datasource",e)}setViewportDatasource(e){this.deprecatedUpdateGridOption("viewportDatasource",e)}setRowData(e){this.deprecatedUpdateGridOption("rowData",e)}setEnableCellTextSelection(e){this.deprecatedUpdateGridOption("enableCellTextSelection",e)}setHeaderHeight(e){this.deprecatedUpdateGridOption("headerHeight",e)}setDomLayout(e){this.deprecatedUpdateGridOption("domLayout",e)}setFillHandleDirection(e){this.deprecatedUpdateGridOption("fillHandleDirection",e)}setGroupHeaderHeight(e){this.deprecatedUpdateGridOption("groupHeaderHeight",e)}setFloatingFiltersHeight(e){this.deprecatedUpdateGridOption("floatingFiltersHeight",e)}setPivotHeaderHeight(e){this.deprecatedUpdateGridOption("pivotHeaderHeight",e)}setPivotGroupHeaderHeight(e){this.deprecatedUpdateGridOption("pivotGroupHeaderHeight",e)}setAnimateRows(e){this.deprecatedUpdateGridOption("animateRows",e)}setIsExternalFilterPresent(e){this.deprecatedUpdateGridOption("isExternalFilterPresent",e)}setDoesExternalFilterPass(e){this.deprecatedUpdateGridOption("doesExternalFilterPass",e)}setNavigateToNextCell(e){this.deprecatedUpdateGridOption("navigateToNextCell",e)}setTabToNextCell(e){this.deprecatedUpdateGridOption("tabToNextCell",e)}setTabToNextHeader(e){this.deprecatedUpdateGridOption("tabToNextHeader",e)}setNavigateToNextHeader(e){this.deprecatedUpdateGridOption("navigateToNextHeader",e)}setRowGroupPanelShow(e){this.deprecatedUpdateGridOption("rowGroupPanelShow",e)}setGetGroupRowAgg(e){this.deprecatedUpdateGridOption("getGroupRowAgg",e)}setGetBusinessKeyForNode(e){this.deprecatedUpdateGridOption("getBusinessKeyForNode",e)}setGetChildCount(e){this.deprecatedUpdateGridOption("getChildCount",e)}setProcessRowPostCreate(e){this.deprecatedUpdateGridOption("processRowPostCreate",e)}setGetRowId(e){U("getRowId is a static property and can no longer be updated.")}setGetRowClass(e){this.deprecatedUpdateGridOption("getRowClass",e)}setIsFullWidthRow(e){this.deprecatedUpdateGridOption("isFullWidthRow",e)}setIsRowSelectable(e){this.deprecatedUpdateGridOption("isRowSelectable",e)}setIsRowMaster(e){this.deprecatedUpdateGridOption("isRowMaster",e)}setPostSortRows(e){this.deprecatedUpdateGridOption("postSortRows",e)}setGetDocument(e){this.deprecatedUpdateGridOption("getDocument",e)}setGetContextMenuItems(e){this.deprecatedUpdateGridOption("getContextMenuItems",e)}setGetMainMenuItems(e){this.deprecatedUpdateGridOption("getMainMenuItems",e)}setProcessCellForClipboard(e){this.deprecatedUpdateGridOption("processCellForClipboard",e)}setSendToClipboard(e){this.deprecatedUpdateGridOption("sendToClipboard",e)}setProcessCellFromClipboard(e){this.deprecatedUpdateGridOption("processCellFromClipboard",e)}setProcessPivotResultColDef(e){this.deprecatedUpdateGridOption("processPivotResultColDef",e)}setProcessPivotResultColGroupDef(e){this.deprecatedUpdateGridOption("processPivotResultColGroupDef",e)}setPostProcessPopup(e){this.deprecatedUpdateGridOption("postProcessPopup",e)}setInitialGroupOrderComparator(e){this.deprecatedUpdateGridOption("initialGroupOrderComparator",e)}setGetChartToolbarItems(e){this.deprecatedUpdateGridOption("getChartToolbarItems",e)}setPaginationNumberFormatter(e){this.deprecatedUpdateGridOption("paginationNumberFormatter",e)}setGetServerSideGroupLevelParams(e){this.deprecatedUpdateGridOption("getServerSideGroupLevelParams",e)}setIsServerSideGroupOpenByDefault(e){this.deprecatedUpdateGridOption("isServerSideGroupOpenByDefault",e)}setIsApplyServerSideTransaction(e){this.deprecatedUpdateGridOption("isApplyServerSideTransaction",e)}setIsServerSideGroup(e){this.deprecatedUpdateGridOption("isServerSideGroup",e)}setGetServerSideGroupKey(e){this.deprecatedUpdateGridOption("getServerSideGroupKey",e)}setGetRowStyle(e){this.deprecatedUpdateGridOption("getRowStyle",e)}setGetRowHeight(e){this.deprecatedUpdateGridOption("getRowHeight",e)}};g([he("rowRenderer")],Uo.prototype,"rowRenderer",2),g([he("navigationService")],Uo.prototype,"navigationService",2),g([he("filterManager")],Uo.prototype,"filterManager",2),g([he("columnModel")],Uo.prototype,"columnModel",2),g([he("selectionService")],Uo.prototype,"selectionService",2),g([he("gridOptionsService")],Uo.prototype,"gos",2),g([he("valueService")],Uo.prototype,"valueService",2),g([he("alignedGridsService")],Uo.prototype,"alignedGridsService",2),g([he("eventService")],Uo.prototype,"eventService",2),g([he("pinnedRowModel")],Uo.prototype,"pinnedRowModel",2),g([he("context")],Uo.prototype,"context",2),g([he("rowModel")],Uo.prototype,"rowModel",2),g([he("sortController")],Uo.prototype,"sortController",2),g([he("paginationProxy")],Uo.prototype,"paginationProxy",2),g([he("focusService")],Uo.prototype,"focusService",2),g([he("dragAndDropService")],Uo.prototype,"dragAndDropService",2),g([he("menuService")],Uo.prototype,"menuService",2),g([he("valueCache")],Uo.prototype,"valueCache",2),g([he("animationFrameService")],Uo.prototype,"animationFrameService",2),g([he("ctrlsService")],Uo.prototype,"ctrlsService",2),g([he("overlayService")],Uo.prototype,"overlayService",2),g([he("stateService")],Uo.prototype,"stateService",2),g([he("expansionService")],Uo.prototype,"expansionService",2),g([he("apiEventService")],Uo.prototype,"apiEventService",2),g([he("frameworkOverrides")],Uo.prototype,"frameworkOverrides",2),g([he("undoRedoService")],Uo.prototype,"undoRedoService",2),g([he("rowNodeBlockLoader")],Uo.prototype,"rowNodeBlockLoader",2),g([de("csvCreator")],Uo.prototype,"csvCreator",2),g([de("excelCreator")],Uo.prototype,"excelCreator",2),g([de("rangeService")],Uo.prototype,"rangeService",2),g([de("clipboardService")],Uo.prototype,"clipboardService",2),g([de("aggFuncService")],Uo.prototype,"aggFuncService",2),g([de("statusBarService")],Uo.prototype,"statusBarService",2),g([de("chartService")],Uo.prototype,"chartService",2),g([de("ssrmTransactionManager")],Uo.prototype,"serverSideTransactionManager",2),g([de("sideBarService")],Uo.prototype,"sideBarService",2),g([le],Uo.prototype,"init",1),Uo=g([ue("gridApi")],Uo);var Wo=class extends nt{constructor(){super(...arguments),this.quickFilter=null,this.quickFilterParts=null}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VISIBLE,()=>{this.gos.get("includeHiddenColumnsInQuickFilter")||this.resetQuickFilterCache()}),this.addManagedPropertyListener("quickFilterText",e=>this.setQuickFilter(e.currentValue)),this.addManagedPropertyListeners(["includeHiddenColumnsInQuickFilter","applyQuickFilterBeforePivotOrAgg"],()=>this.onQuickFilterColumnConfigChanged()),this.quickFilter=this.parseQuickFilter(this.gos.get("quickFilterText")),this.parser=this.gos.get("quickFilterParser"),this.matcher=this.gos.get("quickFilterMatcher"),this.setQuickFilterParts(),this.addManagedPropertyListeners(["quickFilterMatcher","quickFilterParser"],()=>this.setQuickFilterParserAndMatcher())}isQuickFilterPresent(){return null!==this.quickFilter}doesRowPassQuickFilter(e){const t=this.gos.get("cacheQuickFilter");return this.matcher?this.doesRowPassQuickFilterMatcher(t,e):this.quickFilterParts.every(i=>t?this.doesRowPassQuickFilterCache(e,i):this.doesRowPassQuickFilterNoCache(e,i))}resetQuickFilterCache(){this.rowModel.forEachNode(e=>e.quickFilterAggregateText=null)}setQuickFilterParts(){const{quickFilter:e,parser:t}=this;this.quickFilterParts=e?t?t(e):e.split(" "):null}parseQuickFilter(e){return y(e)?this.gos.isRowModelType("clientSide")?e.toUpperCase():(console.warn("AG Grid - Quick filtering only works with the Client-Side Row Model"),null):null}setQuickFilter(e){if(null!=e&&"string"!=typeof e)return void console.warn("AG Grid - Grid option quickFilterText only supports string inputs, received: "+typeof e);const t=this.parseQuickFilter(e);this.quickFilter!==t&&(this.quickFilter=t,this.setQuickFilterParts(),this.dispatchEvent({type:Wo.EVENT_QUICK_FILTER_CHANGED}))}setQuickFilterParserAndMatcher(){const e=this.gos.get("quickFilterParser"),t=this.gos.get("quickFilterMatcher"),i=e!==this.parser||t!==this.matcher;this.parser=e,this.matcher=t,i&&(this.setQuickFilterParts(),this.dispatchEvent({type:Wo.EVENT_QUICK_FILTER_CHANGED}))}onQuickFilterColumnConfigChanged(){this.columnModel.refreshQuickFilterColumns(),this.resetQuickFilterCache(),this.isQuickFilterPresent()&&this.dispatchEvent({type:Wo.EVENT_QUICK_FILTER_CHANGED})}doesRowPassQuickFilterNoCache(e,t){return this.columnModel.getAllColumnsForQuickFilter().some(i=>{const r=this.getQuickFilterTextForColumn(i,e);return y(r)&&r.indexOf(t)>=0})}doesRowPassQuickFilterCache(e,t){return this.checkGenerateQuickFilterAggregateText(e),e.quickFilterAggregateText.indexOf(t)>=0}doesRowPassQuickFilterMatcher(e,t){let i;e?(this.checkGenerateQuickFilterAggregateText(t),i=t.quickFilterAggregateText):i=this.getQuickFilterAggregateText(t);const{quickFilterParts:r,matcher:n}=this;return n(r,i)}checkGenerateQuickFilterAggregateText(e){e.quickFilterAggregateText||(e.quickFilterAggregateText=this.getQuickFilterAggregateText(e))}getQuickFilterTextForColumn(e,t){let i=this.valueService.getValue(e,t,!0);const r=e.getColDef();if(r.getQuickFilterText){const n=this.gos.addGridCommonParams({value:i,node:t,data:t.data,column:e,colDef:r});i=r.getQuickFilterText(n)}return y(i)?i.toString().toUpperCase():null}getQuickFilterAggregateText(e){const t=[];return this.columnModel.getAllColumnsForQuickFilter().forEach(i=>{const r=this.getQuickFilterTextForColumn(i,e);y(r)&&t.push(r)}),t.join(Wo.QUICK_FILTER_SEPARATOR)}};Wo.EVENT_QUICK_FILTER_CHANGED="quickFilterChanged",Wo.QUICK_FILTER_SEPARATOR="\n",g([he("valueService")],Wo.prototype,"valueService",2),g([he("columnModel")],Wo.prototype,"columnModel",2),g([he("rowModel")],Wo.prototype,"rowModel",2),g([le],Wo.prototype,"postConstruct",1),Wo=g([ue("quickFilterService")],Wo);var jo=class extends nt{constructor(){super(...arguments),this.allColumnFilters=new Map,this.allColumnListeners=new Map,this.activeAggregateFilters=[],this.activeColumnFilters=[],this.processingFilterChange=!1,this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue=[],this.advancedFilterModelUpdateQueue=[]}init(){var e,t,i;this.addManagedListener(this.eventService,ct.EVENT_GRID_COLUMNS_CHANGED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VALUE_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.updateAdvancedFilterColumns()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VISIBLE,()=>this.updateAdvancedFilterColumns()),this.addManagedListener(this.eventService,ct.EVENT_ROW_DATA_UPDATED,()=>this.onNewRowsLoaded("rowDataUpdated")),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.addManagedPropertyListeners(["isExternalFilterPresent","doesExternalFilterPass"],()=>{this.onFilterChanged({source:"api"})}),this.updateAggFiltering(),this.addManagedPropertyListener("groupAggFiltering",()=>{this.updateAggFiltering(),this.onFilterChanged()}),this.addManagedPropertyListener("advancedFilterModel",e=>this.setAdvancedFilterModel(e.currentValue)),this.addManagedListener(this.eventService,ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,({enabled:e})=>this.onAdvancedFilterEnabledChanged(e)),this.addManagedListener(this.eventService,ct.EVENT_DATA_TYPES_INFERRED,()=>this.processFilterModelUpdateQueue()),this.addManagedListener(this.quickFilterService,Wo.EVENT_QUICK_FILTER_CHANGED,()=>this.onFilterChanged({source:"quickFilter"})),this.initialFilterModel=h({},null!=(i=null==(t=null==(e=this.gos.get("initialState"))?void 0:e.filter)?void 0:t.filterModel)?i:{})}isExternalFilterPresentCallback(){const e=this.gos.getCallback("isExternalFilterPresent");return"function"==typeof e&&e({})}doesExternalFilterPass(e){const t=this.gos.get("doesExternalFilterPass");return"function"==typeof t&&t(e)}setFilterModel(e,t="api"){if(this.isAdvancedFilterEnabled())return void this.warnAdvancedFilters();if(this.dataTypeService.isPendingInference())return void this.filterModelUpdateQueue.push({model:e,source:t});const i=[],r=this.getFilterModel();if(e){const t=ln(Object.keys(e));this.allColumnFilters.forEach((r,n)=>{const s=e[n];i.push(this.setModelOnFilterWrapper(r.filterPromise,s)),t.delete(n)}),t.forEach(t=>{const r=this.columnModel.getPrimaryColumn(t)||this.columnModel.getGridColumn(t);if(!r)return void console.warn("AG Grid: setFilterModel() - no column found for colId: "+t);if(!r.isFilterAllowed())return void console.warn("AG Grid: setFilterModel() - unable to fully apply model, filtering disabled for colId: "+t);const n=this.getOrCreateFilterWrapper(r,"NO_UI");n?i.push(this.setModelOnFilterWrapper(n.filterPromise,e[t])):console.warn("AG-Grid: setFilterModel() - unable to fully apply model, unable to create filter for colId: "+t)})}else this.allColumnFilters.forEach(e=>{i.push(this.setModelOnFilterWrapper(e.filterPromise,null))});dn.all(i).then(()=>{const e=this.getFilterModel(),i=[];this.allColumnFilters.forEach((t,n)=>{const s=r?r[n]:null,o=e?e[n]:null;cn.jsonEquals(s,o)||i.push(t.column)}),i.length>0&&this.onFilterChanged({columns:i,source:t})})}setModelOnFilterWrapper(e,t){return new dn(i=>{e.then(e=>{"function"!=typeof e.setModel&&(console.warn("AG Grid: filter missing setModel method, which is needed for setFilterModel"),i()),(e.setModel(t)||dn.resolve()).then(()=>i())})})}getFilterModel(){const e={};return this.allColumnFilters.forEach((t,i)=>{const r=this.getModelFromFilterWrapper(t);y(r)&&(e[i]=r)}),e}getModelFromFilterWrapper(e){var t;const i=e.filterPromise.resolveNow(null,e=>e);return null==i?null!=(t=this.initialFilterModel[e.column.getColId()])?t:null:"function"!=typeof i.getModel?(console.warn("AG Grid: filter API missing getModel method, which is needed for getFilterModel"),null):i.getModel()}isColumnFilterPresent(){return this.activeColumnFilters.length>0}isAggregateFilterPresent(){return!!this.activeAggregateFilters.length}isExternalFilterPresent(){return this.externalFilterPresent}isChildFilterPresent(){return this.isColumnFilterPresent()||this.isQuickFilterPresent()||this.isExternalFilterPresent()||this.isAdvancedFilterPresent()}isAdvancedFilterPresent(){return this.isAdvancedFilterEnabled()&&this.advancedFilterService.isFilterPresent()}onAdvancedFilterEnabledChanged(e){var t;e?this.allColumnFilters.size&&(this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"advancedFilterEnabled")),this.onFilterChanged({source:"advancedFilter"})):(null==(t=this.advancedFilterService)?void 0:t.isFilterPresent())&&(this.advancedFilterService.setModel(null),this.onFilterChanged({source:"advancedFilter"}))}isAdvancedFilterEnabled(){var e;return!!(null==(e=this.advancedFilterService)?void 0:e.isEnabled())}isAdvancedFilterHeaderActive(){return this.isAdvancedFilterEnabled()&&this.advancedFilterService.isHeaderActive()}doAggregateFiltersPass(e,t){return this.doColumnFiltersPass(e,t,!0)}updateActiveFilters(){this.activeColumnFilters.length=0,this.activeAggregateFilters.length=0;const e=e=>!!e&&(e.isFilterActive?e.isFilterActive():(console.warn("AG Grid: Filter is missing isFilterActive() method"),!1)),t=!!this.gos.getGroupAggFiltering(),i=e=>{if(!e.isPrimary())return!0;const i=!this.columnModel.isPivotActive();return!(!e.isValueActive()||!i)&&(!!this.columnModel.isPivotMode()||t)};this.allColumnFilters.forEach(t=>{if(t.filterPromise.resolveNow(!1,e)){const e=t.filterPromise.resolveNow(null,e=>e);i(t.column)?this.activeAggregateFilters.push(e):this.activeColumnFilters.push(e)}})}updateFilterFlagInColumns(e,t){this.allColumnFilters.forEach(i=>{const r=i.filterPromise.resolveNow(!1,e=>e.isFilterActive());i.column.setFilterActive(r,e,t)})}isAnyFilterPresent(){return this.isQuickFilterPresent()||this.isColumnFilterPresent()||this.isAggregateFilterPresent()||this.isExternalFilterPresent()||this.isAdvancedFilterPresent()}doColumnFiltersPass(e,t,i){const{data:r,aggData:n}=e,s=i?this.activeAggregateFilters:this.activeColumnFilters,o=i?n:r;for(let i=0;i<s.length;i++){const r=s[i];if(null!=r&&r!==t){if("function"!=typeof r.doesFilterPass)throw new Error("Filter is missing method doesFilterPass");if(!r.doesFilterPass({node:e,data:o}))return!1}}return!0}resetQuickFilterCache(){this.quickFilterService.resetQuickFilterCache()}refreshFiltersForAggregations(){this.gos.getGroupAggFiltering()&&this.onFilterChanged()}callOnFilterChangedOutsideRenderCycle(e){const t=()=>this.onFilterChanged(e);this.rowRenderer.isRefreshInProgress()?setTimeout(t,0):t()}onFilterChanged(e={}){const{source:t,filterInstance:i,additionalEventAttributes:r,columns:n}=e;this.updateDependantFilters(),this.updateActiveFilters(),this.updateFilterFlagInColumns("filterChanged",r),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.allColumnFilters.forEach(e=>{e.filterPromise&&e.filterPromise.then(e=>{e&&e!==i&&e.onAnyFilterChanged&&e.onAnyFilterChanged()})});const s={source:t,type:ct.EVENT_FILTER_CHANGED,columns:n||[]};r&&F(s,r),this.processingFilterChange=!0,this.eventService.dispatchEvent(s),this.processingFilterChange=!1}isSuppressFlashingCellsBecauseFiltering(){var e;return!(null!=(e=this.gos.get("allowShowChangeAfterFilter"))&&e)&&this.processingFilterChange}isQuickFilterPresent(){return this.quickFilterService.isQuickFilterPresent()}updateAggFiltering(){this.aggFiltering=!!this.gos.getGroupAggFiltering()}isAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&this.shouldApplyQuickFilterAfterAgg()}isNonAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&!this.shouldApplyQuickFilterAfterAgg()}shouldApplyQuickFilterAfterAgg(){return(this.aggFiltering||this.columnModel.isPivotMode())&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")}doesRowPassOtherFilters(e,t){return this.doesRowPassFilter({rowNode:t,filterInstanceToSkip:e})}doesRowPassAggregateFilters(e){return!(this.isAggregateQuickFilterPresent()&&!this.quickFilterService.doesRowPassQuickFilter(e.rowNode)||this.isAggregateFilterPresent()&&!this.doAggregateFiltersPass(e.rowNode,e.filterInstanceToSkip))}doesRowPassFilter(e){return!(this.isNonAggregateQuickFilterPresent()&&!this.quickFilterService.doesRowPassQuickFilter(e.rowNode)||this.isExternalFilterPresent()&&!this.doesExternalFilterPass(e.rowNode)||this.isColumnFilterPresent()&&!this.doColumnFiltersPass(e.rowNode,e.filterInstanceToSkip)||this.isAdvancedFilterPresent()&&!this.advancedFilterService.doesFilterPass(e.rowNode))}onNewRowsLoaded(e){this.allColumnFilters.forEach(e=>{e.filterPromise.then(e=>{e.onNewRowsLoaded&&e.onNewRowsLoaded()})}),this.updateFilterFlagInColumns(e,{afterDataChange:!0}),this.updateActiveFilters()}createValueGetter(e){return({node:t})=>this.valueService.getValue(e,t,!0)}createGetValue(e){return(t,i)=>{const r=i?this.columnModel.getGridColumn(i):e;return r?this.valueService.getValue(r,t,!0):void 0}}getFilterComponent(e,t,i=!0){var r;if(i)return(null==(r=this.getOrCreateFilterWrapper(e,t))?void 0:r.filterPromise)||null;const n=this.cachedFilter(e);return n?n.filterPromise:null}isFilterActive(e){const t=this.cachedFilter(e);return!!t&&t.filterPromise.resolveNow(!1,e=>e.isFilterActive())}getOrCreateFilterWrapper(e,t){if(!e.isFilterAllowed())return null;let i=this.cachedFilter(e);return i||(i=this.createFilterWrapper(e,t),this.setColumnFilterWrapper(e,i)),i}cachedFilter(e){return this.allColumnFilters.get(e.getColId())}getDefaultFilter(e){let t;if(se.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()))t="agSetColumnFilter";else{const i=this.dataTypeService.getBaseDataType(e);t="number"===i?"agNumberColumnFilter":"date"===i||"dateString"===i?"agDateColumnFilter":"agTextColumnFilter"}return t}getDefaultFloatingFilter(e){let t;if(se.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()))t="agSetColumnFloatingFilter";else{const i=this.dataTypeService.getBaseDataType(e);t="number"===i?"agNumberColumnFloatingFilter":"date"===i||"dateString"===i?"agDateColumnFloatingFilter":"agTextColumnFloatingFilter"}return t}createFilterInstance(e){const t=this.getDefaultFilter(e),i=e.getColDef();let r;const n=d(h({},this.createFilterParams(e,i)),{filterModifiedCallback:()=>this.filterModifiedCallbackFactory(r,e)(),filterChangedCallback:t=>this.filterChangedCallbackFactory(r,e)(t),doesRowPassOtherFilter:e=>this.doesRowPassOtherFilters(r,e)}),s=this.userComponentFactory.getFilterDetails(i,n,t);return s?{filterPromise:()=>{const e=s.newAgStackInstance();return e&&e.then(e=>r=e),e},compDetails:s}:{filterPromise:null,compDetails:null}}createFilterParams(e,t){return this.gos.addGridCommonParams({column:e,colDef:L(t),rowModel:this.rowModel,filterChangedCallback:()=>{},filterModifiedCallback:()=>{},valueGetter:this.createValueGetter(e),getValue:this.createGetValue(e),doesRowPassOtherFilter:()=>!0})}createFilterWrapper(e,t){var i;const r={column:e,filterPromise:null,compiledElement:null,compDetails:null},{filterPromise:n,compDetails:s}=this.createFilterInstance(e);return r.filterPromise=null!=(i=null==n?void 0:n())?i:null,r.compDetails=s,r}onColumnsChanged(){const e=[];this.allColumnFilters.forEach((t,i)=>{let r;r=t.column.isPrimary()?this.columnModel.getPrimaryColumn(i):this.columnModel.getGridColumn(i),r&&r===t.column||(e.push(t.column),this.disposeFilterWrapper(t,"columnChanged"),this.disposeColumnListener(i))}),e.length>0?this.onFilterChanged({columns:e,source:"api"}):this.updateDependantFilters()}updateDependantFilters(){const e=this.columnModel.getGroupAutoColumns();null==e||e.forEach(e=>{"agGroupColumnFilter"===e.getColDef().filter&&this.getOrCreateFilterWrapper(e,"NO_UI")})}isFilterAllowed(e){var t,i;if(this.isAdvancedFilterEnabled())return!1;if(!e.isFilterAllowed())return!1;const r=this.allColumnFilters.get(e.getColId());return null==(i=null==(t=null==r?void 0:r.filterPromise)?void 0:t.resolveNow(!0,e=>"function"!=typeof(null==e?void 0:e.isFilterAllowed)||(null==e?void 0:e.isFilterAllowed())))||i}getFloatingFilterCompDetails(e,t){const i=t=>{const i=this.getFilterComponent(e,"NO_UI");null!=i&&i.then(e=>{t(zo(e))})},r=e.getColDef(),n=d(h({},this.createFilterParams(e,r)),{filterChangedCallback:()=>i(t=>this.filterChangedCallbackFactory(t,e)())}),s=this.userComponentFactory.mergeParamsWithApplicationProvidedParams(r,Ao,n);let o=this.userComponentFactory.getDefaultFloatingFilterType(r,()=>this.getDefaultFloatingFilter(e));null==o&&(o="agReadOnlyFloatingFilter");const a={column:e,filterParams:s,currentParentModel:()=>this.getCurrentFloatingFilterParentModel(e),parentFilterInstance:i,showParentFilter:t,suppressFilterButton:!1};return this.userComponentFactory.getFloatingFilterCompDetails(r,a,o)}getCurrentFloatingFilterParentModel(e){const t=this.getFilterComponent(e,"NO_UI",!1);return t?t.resolveNow(null,e=>e&&e.getModel()):null}destroyFilter(e,t="api"){const i=e.getColId(),r=this.allColumnFilters.get(i);this.disposeColumnListener(i),delete this.initialFilterModel[i],r&&(this.disposeFilterWrapper(r,t),this.onFilterChanged({columns:[e],source:"api"}))}disposeColumnListener(e){const t=this.allColumnListeners.get(e);t&&(this.allColumnListeners.delete(e),t())}disposeFilterWrapper(e,t){e.filterPromise.then(i=>{this.getContext().destroyBean(i),e.column.setFilterActive(!1,"filterDestroyed"),this.allColumnFilters.delete(e.column.getColId());const r={type:ct.EVENT_FILTER_DESTROYED,source:t,column:e.column};this.eventService.dispatchEvent(r)})}filterModifiedCallbackFactory(e,t){return()=>{const i={type:ct.EVENT_FILTER_MODIFIED,column:t,filterInstance:e};this.eventService.dispatchEvent(i)}}filterChangedCallbackFactory(e,t){return i=>{var r;const n=null!=(r=null==i?void 0:i.source)?r:"api",s={filter:e,additionalEventAttributes:i,columns:[t],source:n};this.callOnFilterChangedOutsideRenderCycle(s)}}checkDestroyFilter(e){const t=this.allColumnFilters.get(e);if(!t)return;const i=t.column,{compDetails:r}=i.isFilterAllowed()?this.createFilterInstance(i):{compDetails:null};if(this.areFilterCompsDifferent(t.compDetails,r))return void this.destroyFilter(i,"paramsUpdated");const n=i.getColDef().filterParams;t.filterPromise?t.filterPromise.then(e=>{!1===(!(null==e?void 0:e.refresh)||e.refresh(h(d(h({},this.createFilterParams(i,i.getColDef())),{filterModifiedCallback:this.filterModifiedCallbackFactory(e,i),filterChangedCallback:this.filterChangedCallbackFactory(e,i),doesRowPassOtherFilter:t=>this.doesRowPassOtherFilters(e,t)}),n)))&&this.destroyFilter(i,"paramsUpdated")}):this.destroyFilter(i,"paramsUpdated")}setColumnFilterWrapper(e,t){const i=e.getColId();this.allColumnFilters.set(i,t),this.allColumnListeners.set(i,this.addManagedListener(e,be.EVENT_COL_DEF_CHANGED,()=>this.checkDestroyFilter(i)))}areFilterCompsDifferent(e,t){if(!t||!e)return!0;const{componentClass:i}=e,{componentClass:r}=t;return!(i===r||(null==i?void 0:i.render)&&(null==r?void 0:r.render)&&i.render===r.render)}getAdvancedFilterModel(){return this.isAdvancedFilterEnabled()?this.advancedFilterService.getModel():null}setAdvancedFilterModel(e){this.isAdvancedFilterEnabled()&&(this.dataTypeService.isPendingInference()?this.advancedFilterModelUpdateQueue.push(e):(this.advancedFilterService.setModel(null!=e?e:null),this.onFilterChanged({source:"advancedFilter"})))}showAdvancedFilterBuilder(e){this.isAdvancedFilterEnabled()&&this.advancedFilterService.getCtrl().toggleFilterBuilder(e,!0)}updateAdvancedFilterColumns(){this.isAdvancedFilterEnabled()&&this.advancedFilterService.updateValidity()&&this.onFilterChanged({source:"advancedFilter"})}hasFloatingFilters(){return!this.isAdvancedFilterEnabled()&&this.columnModel.getAllGridColumns().some(e=>e.getColDef().floatingFilter)}getFilterInstance(e,t){if(this.isAdvancedFilterEnabled())return void this.warnAdvancedFilters();const i=this.getFilterInstanceImpl(e,e=>{if(!t)return;const i=zo(e);t(i)});return zo(i)}getColumnFilterInstance(e){return new Promise(t=>{this.getFilterInstance(e,e=>{t(e)})})}getFilterInstanceImpl(e,t){const i=this.columnModel.getPrimaryColumn(e);if(!i)return;const r=this.getFilterComponent(i,"NO_UI"),n=r&&r.resolveNow(null,e=>e);return n?setTimeout(t,0,n):r&&r.then(e=>{t(e)}),n}warnAdvancedFilters(){U("Column Filter API methods have been disabled as Advanced Filters are enabled.")}setupAdvancedFilterHeaderComp(e){var t;null==(t=this.advancedFilterService)||t.getCtrl().setupHeaderComp(e)}getHeaderRowCount(){return this.isAdvancedFilterHeaderActive()?1:0}getHeaderHeight(){return this.isAdvancedFilterHeaderActive()?this.advancedFilterService.getCtrl().getHeaderHeight():0}processFilterModelUpdateQueue(){this.filterModelUpdateQueue.forEach(({model:e,source:t})=>this.setFilterModel(e,t)),this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue.forEach(({key:e,model:t,resolve:i})=>{this.setColumnFilterModel(e,t).then(()=>i())}),this.columnFilterModelUpdateQueue=[],this.advancedFilterModelUpdateQueue.forEach(e=>this.setAdvancedFilterModel(e)),this.advancedFilterModelUpdateQueue=[]}getColumnFilterModel(e){const t=this.getFilterWrapper(e);return t?this.getModelFromFilterWrapper(t):null}setColumnFilterModel(e,t){if(this.isAdvancedFilterEnabled())return this.warnAdvancedFilters(),Promise.resolve();if(this.dataTypeService.isPendingInference()){let i=()=>{};const r=new Promise(e=>{i=e});return this.columnFilterModelUpdateQueue.push({key:e,model:t,resolve:i}),r}const i=this.columnModel.getPrimaryColumn(e),r=i?this.getOrCreateFilterWrapper(i,"NO_UI"):null;return r?(n=this.setModelOnFilterWrapper(r.filterPromise,t),new Promise(e=>{n.then(t=>e(t))})):Promise.resolve();var n}getFilterWrapper(e){var t;const i=this.columnModel.getPrimaryColumn(e);return i&&null!=(t=this.cachedFilter(i))?t:null}destroy(){super.destroy(),this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"gridDestroyed")),this.allColumnListeners.clear()}};g([he("valueService")],jo.prototype,"valueService",2),g([he("columnModel")],jo.prototype,"columnModel",2),g([he("rowModel")],jo.prototype,"rowModel",2),g([he("userComponentFactory")],jo.prototype,"userComponentFactory",2),g([he("rowRenderer")],jo.prototype,"rowRenderer",2),g([he("dataTypeService")],jo.prototype,"dataTypeService",2),g([he("quickFilterService")],jo.prototype,"quickFilterService",2),g([de("advancedFilterService")],jo.prototype,"advancedFilterService",2),g([le],jo.prototype,"init",1),jo=g([ue("filterManager")],jo);var Ko=class extends wn{constructor(e,t){super('<div class="ag-filter"></div>'),this.column=e,this.source=t,this.filterWrapper=null}postConstruct(){this.createFilter(!0),this.addManagedListener(this.eventService,ct.EVENT_FILTER_DESTROYED,this.onFilterDestroyed.bind(this))}hasFilter(){return!!this.filterWrapper}getFilter(){var e,t;return null!=(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)?t:null}afterInit(){var e,t,i;return null!=(i=null==(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)?void 0:t.then(()=>{}))?i:dn.resolve()}afterGuiAttached(e){var t,i;null==(i=null==(t=this.filterWrapper)?void 0:t.filterPromise)||i.then(t=>{var i;null==(i=null==t?void 0:t.afterGuiAttached)||i.call(t,e)})}afterGuiDetached(){var e,t;null==(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)||t.then(e=>{var t;null==(t=null==e?void 0:e.afterGuiDetached)||t.call(e)})}createFilter(e){var t;const{column:i,source:r}=this;this.filterWrapper=this.filterManager.getOrCreateFilterWrapper(i,r),(null==(t=this.filterWrapper)?void 0:t.filterPromise)&&this.filterWrapper.filterPromise.then(t=>{let n=t.getGui();if(y(n)||console.warn(`AG Grid: getGui method from filter returned ${n}, it should be a DOM element or an HTML template string.`),"string"==typeof n&&(n=Er(n)),this.appendChild(n),e){const e={type:ct.EVENT_FILTER_OPENED,column:i,source:r,eGui:this.getGui()};this.eventService.dispatchEvent(e)}})}onFilterDestroyed(e){"api"!==e.source&&"paramsUpdated"!==e.source||e.column.getId()!==this.column.getId()||!this.columnModel.getPrimaryColumn(this.column)||(yr(this.getGui()),this.createFilter())}destroy(){this.filterWrapper=null,super.destroy()}};g([he("filterManager")],Ko.prototype,"filterManager",2),g([he("columnModel")],Ko.prototype,"columnModel",2),g([le],Ko.prototype,"postConstruct",1);var $o=class extends wn{constructor(e,t){super(e),this.ctrl=t}getCtrl(){return this.ctrl}},qo=class e extends $o{constructor(t){super(e.TEMPLATE,t)}postConstruct(){const e=this.getGui(),t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),addOrRemoveBodyCssClass:(e,t)=>this.eFloatingFilterBody.classList.toggle(e,t),setButtonWrapperDisplayed:e=>or(this.eButtonWrapper,e),setCompDetails:e=>this.setCompDetails(e),getFloatingFilterComp:()=>this.compPromise,setWidth:t=>e.style.width=t,setMenuIcon:e=>this.eButtonShowMainFilter.appendChild(e)};this.ctrl.setComp(t,e,this.eButtonShowMainFilter,this.eFloatingFilterBody)}setCompDetails(e){if(!e)return this.destroyFloatingFilterComp(),void(this.compPromise=null);this.compPromise=e.newAgStackInstance(),this.compPromise.then(e=>this.afterCompCreated(e))}destroyFloatingFilterComp(){this.floatingFilterComp&&(this.eFloatingFilterBody.removeChild(this.floatingFilterComp.getGui()),this.floatingFilterComp=this.destroyBean(this.floatingFilterComp))}afterCompCreated(e){e&&(this.isAlive()?(this.destroyFloatingFilterComp(),this.floatingFilterComp=e,this.eFloatingFilterBody.appendChild(e.getGui()),e.afterGuiAttached&&e.afterGuiAttached()):this.destroyBean(e))}};qo.TEMPLATE='<div class="ag-header-cell ag-floating-filter" role="gridcell">\n            <div ref="eFloatingFilterBody" role="presentation"></div>\n            <div class="ag-floating-filter-button ag-hidden" ref="eButtonWrapper" role="presentation">\n                <button type="button" class="ag-button ag-floating-filter-button-button" ref="eButtonShowMainFilter" tabindex="-1"></button>\n            </div>\n        </div>',g([bn("eFloatingFilterBody")],qo.prototype,"eFloatingFilterBody",2),g([bn("eButtonWrapper")],qo.prototype,"eButtonWrapper",2),g([bn("eButtonShowMainFilter")],qo.prototype,"eButtonShowMainFilter",2),g([le],qo.prototype,"postConstruct",1),g([ce],qo.prototype,"destroyFloatingFilterComp",1);var Yo=qo,Qo=(e=>(e.AUTO_HEIGHT="ag-layout-auto-height",e.NORMAL="ag-layout-normal",e.PRINT="ag-layout-print",e))(Qo||{}),Xo=class extends nt{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){const e=this.getDomLayout(),t={autoHeight:"autoHeight"===e,normal:"normal"===e,print:"print"===e},i=t.autoHeight?"ag-layout-auto-height":t.print?"ag-layout-print":"ag-layout-normal";this.view.updateLayoutClasses(i,t)}getDomLayout(){var e;const t=null!=(e=this.gos.get("domLayout"))?e:"normal";return-1===["normal","print","autoHeight"].indexOf(t)?(U(`${t} is not valid for DOM Layout, valid values are 'normal', 'autoHeight', 'print'.`),"normal"):t}};g([le],Xo.prototype,"postConstruct",1);var Zo=class extends nt{constructor(e){super(),this.lastScrollSource=[null,null],this.scrollLeft=-1,this.nextScrollTop=-1,this.scrollTop=-1,this.lastOffsetHeight=-1,this.lastScrollTop=-1,this.eBodyViewport=e,this.resetLastHScrollDebounced=Z(()=>this.lastScrollSource[1]=null,500),this.resetLastVScrollDebounced=Z(()=>this.lastScrollSource[0]=null,500)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onDisplayedColumnsWidthChanged.bind(this)),this.ctrlsService.whenReady(e=>{this.centerRowsCtrl=e.center,this.onDisplayedColumnsWidthChanged(),this.addScrollListener()})}addScrollListener(){const{fakeHScrollComp:e,fakeVScrollComp:t}=this.ctrlsService.getParams();this.addManagedListener(this.centerRowsCtrl.getViewportElement(),"scroll",this.onHScroll.bind(this)),e.onScrollCallback(this.onFakeHScroll.bind(this));const i=this.gos.get("debounceVerticalScrollbar"),r=i?Z(this.onVScroll.bind(this),100):this.onVScroll.bind(this),n=i?Z(this.onFakeVScroll.bind(this),100):this.onFakeVScroll.bind(this);this.addManagedListener(this.eBodyViewport,"scroll",r),t.onScrollCallback(n)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloatingCenter()}horizontallyScrollHeaderCenterAndFloatingCenter(e){if(null==this.centerRowsCtrl)return;void 0===e&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft());const t=this.enableRtl?e:-e,{topCenter:i,stickyTopCenter:r,stickyBottomCenter:n,centerHeader:s,bottomCenter:o,fakeHScrollComp:a}=this.ctrlsService.getParams();s.setHorizontalScroll(-t),o.setContainerTranslateX(t),i.setContainerTranslateX(t),r.setContainerTranslateX(t),n.setContainerTranslateX(t);const l=this.centerRowsCtrl.getViewportElement(),c=0===this.lastScrollSource[1];e=Math.abs(e),c?a.setScrollPosition(e):Cr(l,e,this.enableRtl)}isControllingScroll(e,t){return null==this.lastScrollSource[t]?(this.lastScrollSource[t]=e,!0):this.lastScrollSource[t]===e}onFakeHScroll(){this.isControllingScroll(1,1)&&this.onHScrollCommon(1)}onHScroll(){this.isControllingScroll(0,1)&&this.onHScrollCommon(0)}onHScrollCommon(e){const t=this.centerRowsCtrl.getViewportElement(),{scrollLeft:i}=t;if(this.shouldBlockScrollUpdate(1,i,!0))return;let r;r=0===e?vr(t,this.enableRtl):this.ctrlsService.get("fakeHScrollComp").getScrollPosition(),this.doHorizontalScroll(Math.round(r)),this.resetLastHScrollDebounced()}onFakeVScroll(){this.isControllingScroll(1,0)&&this.onVScrollCommon(1)}onVScroll(){this.isControllingScroll(0,0)&&this.onVScrollCommon(0)}onVScrollCommon(e){let t;t=0===e?this.eBodyViewport.scrollTop:this.ctrlsService.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0)||(this.animationFrameService.setScrollTop(t),this.nextScrollTop=t,0===e?this.ctrlsService.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,this.gos.get("suppressAnimationFrame")?this.scrollGridIfNeeded():this.animationFrameService.schedule(),this.resetLastVScrollDebounced())}doHorizontalScroll(e){const t=this.ctrlsService.get("fakeHScrollComp").getScrollPosition();this.scrollLeft===e&&e===t||(this.scrollLeft=e,this.fireScrollEvent(1),this.horizontallyScrollHeaderCenterAndFloatingCenter(e),this.centerRowsCtrl.onHorizontalViewportChanged(!0))}fireScrollEvent(e){const t={type:ct.EVENT_BODY_SCROLL,direction:1===e?"horizontal":"vertical",left:this.scrollLeft,top:this.scrollTop};this.eventService.dispatchEvent(t),window.clearTimeout(this.scrollTimer),this.scrollTimer=void 0,this.scrollTimer=window.setTimeout(()=>{const e=d(h({},t),{type:ct.EVENT_BODY_SCROLL_END});this.eventService.dispatchEvent(e)},100)}shouldBlockScrollUpdate(e,t,i=!1){return!(i&&!Ii())&&(0===e?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t))}shouldBlockVerticalScroll(e){const t=hr(this.eBodyViewport),{scrollHeight:i}=this.eBodyViewport;return e<0||e+t>i}shouldBlockHorizontalScroll(e){const t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:i}=this.centerRowsCtrl.getViewportElement();if(this.enableRtl&&mr()){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>i}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){this.scrollLeft!==this.centerRowsCtrl.getCenterViewportScrollLeft()&&this.onHScrollCommon(0)}scrollGridIfNeeded(){const e=this.scrollTop!=this.nextScrollTop;return e&&(this.scrollTop=this.nextScrollTop,this.redrawRowsAfterScroll()),e}setHorizontalScrollPosition(e,t=!1){const i=this.centerRowsCtrl.getViewportElement().scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(e=this.enableRtl&&mr()?e>0?0:i:Math.min(Math.max(e,0),i)),Cr(this.centerRowsCtrl.getViewportElement(),Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.eBodyViewport.scrollTop=e}getVScrollPosition(){return this.lastScrollTop=this.eBodyViewport.scrollTop,this.lastOffsetHeight=this.eBodyViewport.offsetHeight,{top:this.lastScrollTop,bottom:this.lastScrollTop+this.lastOffsetHeight}}getApproximateVScollPosition(){return this.lastScrollTop>=0&&this.lastOffsetHeight>=0?{top:this.scrollTop,bottom:this.scrollTop+this.lastOffsetHeight}:this.getVScrollPosition()}getHScrollPosition(){return this.centerRowsCtrl.getHScrollPosition()}isHorizontalScrollShowing(){return this.centerRowsCtrl.isHorizontalScrollShowing()}scrollHorizontally(e){const t=this.centerRowsCtrl.getViewportElement().scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.getViewportElement().scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){const i=this.rowModel.getRowCount();let r=-1;for(let t=0;t<i;t++){const i=this.rowModel.getRow(t);if("function"==typeof e){if(i&&e(i)){r=t;break}}else if(e===i||e===i.data){r=t;break}}r>=0&&this.ensureIndexVisible(r,t)}ensureIndexVisible(e,t){if(this.gos.isDomLayout("print"))return;const i=this.paginationProxy.getRowCount();if("number"!=typeof e||e<0||e>=i)return void console.warn("AG Grid: Invalid row index for ensureIndexVisible: "+e);const r=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel");this.getFrameworkOverrides().wrapIncoming(()=>{r||this.paginationProxy.goToPageWithIndex(e);const i=this.ctrlsService.getGridBodyCtrl(),n=i.getStickyTopHeight(),s=i.getStickyBottomHeight(),o=this.paginationProxy.getRow(e);let a;do{const e=o.rowTop,i=o.rowHeight,r=this.paginationProxy.getPixelOffset(),l=o.rowTop-r,c=l+o.rowHeight,u=this.getVScrollPosition(),h=this.heightScaler.getDivStretchOffset(),d=u.top+h,p=u.bottom+h,g=p-d,f=this.heightScaler.getScrollPositionForPixel(l),m=this.heightScaler.getScrollPositionForPixel(c-g),v=Math.min((f+m)/2,l);let C=null;"top"===t?C=f:"bottom"===t?C=m:"middle"===t?C=v:d+n>l?C=f-n:p-s<c&&(C=m+s),null!==C&&(this.setVerticalScrollPosition(C),this.rowRenderer.redraw({afterScroll:!0})),a=e!==o.rowTop||i!==o.rowHeight}while(a);this.animationFrameService.flushAllFrames()})}ensureColumnVisible(e,t="auto"){const i=this.columnModel.getGridColumn(e);if(!i)return;if(i.isPinned())return;if(!this.columnModel.isColumnDisplayed(i))return;const r=this.getPositionedHorizontalScroll(i,t);this.getFrameworkOverrides().wrapIncoming(()=>{null!==r&&this.centerRowsCtrl.setCenterViewportScrollLeft(r),this.centerRowsCtrl.onHorizontalViewportChanged(),this.animationFrameService.flushAllFrames()})}setScrollPosition(e,t){this.getFrameworkOverrides().wrapIncoming(()=>{this.centerRowsCtrl.setCenterViewportScrollLeft(t),this.setVerticalScrollPosition(e),this.rowRenderer.redraw({afterScroll:!0}),this.animationFrameService.flushAllFrames()})}getPositionedHorizontalScroll(e,t){const{columnBeforeStart:i,columnAfterEnd:r}=this.isColumnOutsideViewport(e),n=this.centerRowsCtrl.getCenterWidth()<e.getActualWidth(),s=this.centerRowsCtrl.getCenterWidth(),o=this.enableRtl;let a=(o?i:r)||n,l=o?r:i;"auto"!==t&&(a="start"===t,l="end"===t);const c="middle"===t;if(a||l||c){const{colLeft:t,colMiddle:i,colRight:r}=this.getColumnBounds(e);return c?i-s/2:a?o?r:t:o?t-s:r-s}return null}isColumnOutsideViewport(e){const{start:t,end:i}=this.getViewportBounds(),{colLeft:r,colRight:n}=this.getColumnBounds(e),s=this.enableRtl;return{columnBeforeStart:s?t>n:i<n,columnAfterEnd:s?i<r:t>r}}getColumnBounds(e){const t=this.enableRtl,i=this.columnModel.getBodyContainerWidth(),r=e.getActualWidth(),n=e.getLeft(),s=t?-1:1,o=t?i-n:n;return{colLeft:o,colMiddle:o+r/2*s,colRight:o+r*s}}getViewportBounds(){const e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft();return{start:t,end:e+t,width:e}}};g([he("ctrlsService")],Zo.prototype,"ctrlsService",2),g([he("animationFrameService")],Zo.prototype,"animationFrameService",2),g([he("paginationProxy")],Zo.prototype,"paginationProxy",2),g([he("rowModel")],Zo.prototype,"rowModel",2),g([he("rowContainerHeightService")],Zo.prototype,"heightScaler",2),g([he("rowRenderer")],Zo.prototype,"rowRenderer",2),g([he("columnModel")],Zo.prototype,"columnModel",2),g([le],Zo.prototype,"postConstruct",1);var Jo=(e=>(e.ANIMATION_ON="ag-row-animation",e.ANIMATION_OFF="ag-row-no-animation",e))(Jo||{}),ea="ag-force-vertical-scroll",ta=class extends nt{constructor(){super(...arguments),this.stickyTopHeight=0,this.stickyBottomHeight=0}getScrollFeature(){return this.bodyScrollFeature}getBodyViewportElement(){return this.eBodyViewport}setComp(e,t,i,r,n,s,o){this.comp=e,this.eGridBody=t,this.eBodyViewport=i,this.eTop=r,this.eBottom=n,this.eStickyTop=s,this.eStickyBottom=o,this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",e=>this.setCellTextSelection(e.currentValue)),this.createManagedBean(new Xo(this.comp)),this.bodyScrollFeature=this.createManagedBean(new Zo(this.eBodyViewport)),this.addRowDragListener(),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([r,i,n,s,o]),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.filterManager.setupAdvancedFilterHeaderComp(r),this.ctrlsService.register("gridBodyCtrl",this)}getComp(){return this.comp}addEventListeners(){this.addManagedListener(this.eventService,ct.EVENT_GRID_COLUMNS_CHANGED,this.onGridColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_SCROLL_VISIBILITY_CHANGED,this.onScrollVisibilityChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_HEADER_HEIGHT_CHANGED,this.onHeaderHeightChanged.bind(this))}addFocusListeners(e){e.forEach(e=>{this.addManagedListener(e,"focusin",t=>{const{target:i}=t,r=cr(i,"ag-root",e);e.classList.toggle("ag-has-focus",!r)}),this.addManagedListener(e,"focusout",t=>{const{target:i,relatedTarget:r}=t,n=e.contains(r),s=cr(r,"ag-root",e);cr(i,"ag-root",e)||n&&!s||e.classList.remove("ag-has-focus")})})}setColumnMovingCss(e){this.comp.setColumnMovingCss("ag-column-moving",e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss("ag-selectable",e)}onScrollVisibilityChanged(){const e=this.scrollVisibleService.isVerticalScrollShowing();this.setVerticalScrollPaddingVisible(e),this.setStickyWidth(e),this.setStickyBottomOffsetBottom();const t=`calc(100% + ${(e&&this.gos.getScrollbarWidth()||0)+(Hi()?16:0)}px)`;this.animationFrameService.requestAnimationFrame(()=>this.comp.setBodyViewportWidth(t))}onGridColumnsChanged(){const e=this.columnModel.getAllGridColumns();this.comp.setColumnCount(e.length)}disableBrowserDragging(){this.addManagedListener(this.eGridBody,"dragstart",e=>{if(e.target instanceof HTMLImageElement)return e.preventDefault(),!1})}addStopEditingWhenGridLosesFocus(){if(!this.gos.get("stopEditingWhenCellsLoseFocus"))return;const e=e=>{const i=e.relatedTarget;if(null===Ni(i))return void this.rowRenderer.stopEditing();let r=t.some(e=>e.contains(i))&&this.mouseEventService.isElementInThisGrid(i);if(!r){const e=this.popupService;r=e.getActivePopups().some(e=>e.contains(i))||e.isElementWithinCustomPopup(i)}r||this.rowRenderer.stopEditing()},t=[this.eBodyViewport,this.eBottom,this.eTop,this.eStickyTop,this.eStickyBottom];t.forEach(t=>this.addManagedListener(t,"focusout",e))}updateRowCount(){const e=this.headerNavigationService.getHeaderRowCount()+this.filterManager.getHeaderRowCount(),t=this.rowModel.isLastRowIndexKnown()?this.rowModel.getRowCount():-1,i=-1===t?-1:e+t;this.comp.setRowCount(i)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){const t=e?"scroll":"hidden";this.comp.setPinnedTopBottomOverflowY(t)}isVerticalScrollShowing(){const e=this.gos.get("alwaysShowVerticalScroll"),t=e?ea:null,i=this.gos.isDomLayout("normal");return this.comp.setAlwaysVerticalScrollClass(t,e),e||i&&Pr(this.eBodyViewport)}setupRowAnimationCssClass(){const e=()=>{const e=this.gos.isAnimateRows()&&!this.rowContainerHeightService.isStretching(),t=e?"ag-row-animation":"ag-row-no-animation";this.comp.setRowAnimationCssOnBodyViewport(t,e)};e(),this.addManagedListener(this.eventService,ct.EVENT_HEIGHT_SCALE_CHANGED,e),this.addManagedPropertyListener("animateRows",e)}getGridBodyElement(){return this.eGridBody}addBodyViewportListener(){const e=this.onBodyViewportContextMenu.bind(this);this.addManagedListener(this.eBodyViewport,"contextmenu",e),this.mockContextMenuForIPad(e),this.addManagedListener(this.eBodyViewport,"wheel",this.onBodyViewportWheel.bind(this)),this.addManagedListener(this.eStickyTop,"wheel",this.onStickyWheel.bind(this)),this.addManagedListener(this.eStickyBottom,"wheel",this.onStickyWheel.bind(this)),this.addFullWidthContainerWheelListener()}addFullWidthContainerWheelListener(){const e=this.eBodyViewport.querySelector(".ag-full-width-container"),t=this.eBodyViewport.querySelector(".ag-center-cols-viewport");e&&t&&this.addManagedListener(e,"wheel",e=>this.onFullWidthContainerWheel(e,t))}onFullWidthContainerWheel(e,t){!e.deltaX||Math.abs(e.deltaY)>Math.abs(e.deltaX)||!this.mouseEventService.isEventFromThisGrid(e)||(e.preventDefault(),t.scrollBy({left:e.deltaX}))}onBodyViewportContextMenu(e,t,i){if(!e&&!i)return;this.gos.get("preventDefaultOnContextMenu")&&(e||i).preventDefault();const{target:r}=e||t;r!==this.eBodyViewport&&r!==this.ctrlsService.get("center").getViewportElement()||this.menuService.showContextMenu({mouseEvent:e,touchEvent:i,value:null,anchorToElement:this.eGridBody})}mockContextMenuForIPad(e){if(!Ii())return;const t=new vs(this.eBodyViewport);this.addManagedListener(t,vs.EVENT_LONG_TAP,t=>{e(void 0,t.touchStart,t.touchEvent)}),this.addDestroyFunc(()=>t.destroy())}onBodyViewportWheel(e){this.gos.get("suppressScrollWhenPopupsAreOpen")&&this.popupService.hasAnchoredPopup()&&e.preventDefault()}onStickyWheel(e){e.preventDefault(),e.offsetY&&this.scrollVertically(e.deltaY)}getGui(){return this.eGridBody}scrollVertically(e){const t=this.eBodyViewport.scrollTop;return this.bodyScrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}addRowDragListener(){this.rowDragFeature=this.createManagedBean(new Go(this.eBodyViewport)),this.dragAndDropService.addDropTarget(this.rowDragFeature)}getRowDragFeature(){return this.rowDragFeature}onPinnedRowDataChanged(){this.setFloatingHeights()}setFloatingHeights(){const{pinnedRowModel:e}=this;let t=e.getPinnedTopTotalHeight(),i=e.getPinnedBottomTotalHeight();this.comp.setTopHeight(t),this.comp.setBottomHeight(i),this.comp.setTopDisplay(t?"inherit":"none"),this.comp.setBottomDisplay(i?"inherit":"none"),this.setStickyTopOffsetTop(),this.setStickyBottomOffsetBottom()}setStickyTopHeight(e=0){this.comp.setStickyTopHeight(`${e}px`),this.stickyTopHeight=e}getStickyTopHeight(){return this.stickyTopHeight}setStickyBottomHeight(e=0){this.comp.setStickyBottomHeight(`${e}px`),this.stickyBottomHeight=e}getStickyBottomHeight(){return this.stickyBottomHeight}setStickyWidth(e){if(e){const e=this.gos.getScrollbarWidth();this.comp.setStickyTopWidth(`calc(100% - ${e}px)`),this.comp.setStickyBottomWidth(`calc(100% - ${e}px)`)}else this.comp.setStickyTopWidth("100%"),this.comp.setStickyBottomWidth("100%")}onHeaderHeightChanged(){this.setStickyTopOffsetTop()}setStickyTopOffsetTop(){const e=this.ctrlsService.get("gridHeaderCtrl").getHeaderHeight()+this.filterManager.getHeaderHeight(),t=this.pinnedRowModel.getPinnedTopTotalHeight();let i=0;e>0&&(i+=e),t>0&&(i+=t),i>0&&(i+=1),this.comp.setStickyTopTop(`${i}px`)}setStickyBottomOffsetBottom(){const e=this.pinnedRowModel.getPinnedBottomTotalHeight()+(this.scrollVisibleService.isHorizontalScrollShowing()&&this.gos.getScrollbarWidth()||0);this.comp.setStickyBottomBottom(`${e}px`)}sizeColumnsToFit(e,t){const i=this.isVerticalScrollShowing()?this.gos.getScrollbarWidth():0,r=dr(this.eGridBody)-i;r>0?this.columnModel.sizeColumnsToFit(r,"sizeColumnsToFit",!1,e):void 0===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,100)},0):100===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,500)},100):500===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,-1)},500):console.warn("AG Grid: tried to call sizeColumnsToFit() but the grid is coming back with zero width, maybe the grid is not visible yet on the screen?")}addScrollEventListener(e){this.eBodyViewport.addEventListener("scroll",e,{passive:!0})}removeScrollEventListener(e){this.eBodyViewport.removeEventListener("scroll",e)}};g([he("animationFrameService")],ta.prototype,"animationFrameService",2),g([he("rowContainerHeightService")],ta.prototype,"rowContainerHeightService",2),g([he("ctrlsService")],ta.prototype,"ctrlsService",2),g([he("columnModel")],ta.prototype,"columnModel",2),g([he("scrollVisibleService")],ta.prototype,"scrollVisibleService",2),g([he("menuService")],ta.prototype,"menuService",2),g([he("headerNavigationService")],ta.prototype,"headerNavigationService",2),g([he("dragAndDropService")],ta.prototype,"dragAndDropService",2),g([he("pinnedRowModel")],ta.prototype,"pinnedRowModel",2),g([he("rowRenderer")],ta.prototype,"rowRenderer",2),g([he("popupService")],ta.prototype,"popupService",2),g([he("mouseEventService")],ta.prototype,"mouseEventService",2),g([he("rowModel")],ta.prototype,"rowModel",2),g([he("filterManager")],ta.prototype,"filterManager",2);var ia=(e=>(e[e.FILL=0]="FILL",e[e.RANGE=1]="RANGE",e))(ia||{}),ra=(e=>(e[e.VALUE=0]="VALUE",e[e.DIMENSION=1]="DIMENSION",e))(ra||{}),na="ag-cell-range-selected",sa=class{constructor(e,t){this.beans=e,this.rangeService=e.rangeService,this.selectionHandleFactory=e.selectionHandleFactory,this.cellCtrl=t}setComp(e,t){this.cellComp=e,this.eGui=t,this.onRangeSelectionChanged()}onRangeSelectionChanged(){this.cellComp&&(this.rangeCount=this.rangeService.getCellRangeCount(this.cellCtrl.getCellPosition()),this.hasChartRange=this.getHasChartRange(),this.cellComp.addOrRemoveCssClass(na,0!==this.rangeCount),this.cellComp.addOrRemoveCssClass(`${na}-1`,1===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${na}-2`,2===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${na}-3`,3===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${na}-4`,this.rangeCount>=4),this.cellComp.addOrRemoveCssClass("ag-cell-range-chart",this.hasChartRange),gi(this.eGui,this.rangeCount>0||void 0),this.cellComp.addOrRemoveCssClass("ag-cell-range-single-cell",this.isSingleCell()),this.updateRangeBorders(),this.refreshHandle())}updateRangeBorders(){const e=this.getRangeBorders(),t=this.isSingleCell(),i=!t&&e.top,r=!t&&e.right,n=!t&&e.bottom,s=!t&&e.left;this.cellComp.addOrRemoveCssClass("ag-cell-range-top",i),this.cellComp.addOrRemoveCssClass("ag-cell-range-right",r),this.cellComp.addOrRemoveCssClass("ag-cell-range-bottom",n),this.cellComp.addOrRemoveCssClass("ag-cell-range-left",s)}isSingleCell(){const{rangeService:e}=this.beans;return 1===this.rangeCount&&!!e&&!e.isMoreThanOneCell()}getHasChartRange(){const{rangeService:e}=this.beans;if(!this.rangeCount||!e)return!1;const t=e.getCellRanges();return t.length>0&&t.every(e=>Be([1,0],e.type))}updateRangeBordersIfRangeCount(){this.rangeCount>0&&(this.updateRangeBorders(),this.refreshHandle())}getRangeBorders(){const e=this.beans.gos.get("enableRtl");let t=!1,i=!1,r=!1,n=!1;const s=this.cellCtrl.getCellPosition().column,o=this.beans.columnModel;let a,l;e?(a=o.getDisplayedColAfter(s),l=o.getDisplayedColBefore(s)):(a=o.getDisplayedColBefore(s),l=o.getDisplayedColAfter(s));const c=this.rangeService.getCellRanges().filter(e=>this.rangeService.isCellInSpecificRange(this.cellCtrl.getCellPosition(),e));a||(n=!0),l||(i=!0);for(let e=0;e<c.length&&!(t&&i&&r&&n);e++){const s=c[e],o=this.rangeService.getRangeStartRow(s),u=this.rangeService.getRangeEndRow(s);!t&&this.beans.rowPositionUtils.sameRow(o,this.cellCtrl.getCellPosition())&&(t=!0),!r&&this.beans.rowPositionUtils.sameRow(u,this.cellCtrl.getCellPosition())&&(r=!0),!n&&a&&s.columns.indexOf(a)<0&&(n=!0),!i&&l&&s.columns.indexOf(l)<0&&(i=!0)}return{top:t,right:i,bottom:r,left:n}}refreshHandle(){if(this.beans.context.isDestroyed())return;const e=this.shouldHaveSelectionHandle();this.selectionHandle&&!e&&(this.selectionHandle=this.beans.context.destroyBean(this.selectionHandle)),e&&this.addSelectionHandle(),this.cellComp.addOrRemoveCssClass("ag-cell-range-handle",!!this.selectionHandle)}shouldHaveSelectionHandle(){const e=this.beans.gos,t=this.rangeService.getCellRanges(),i=t.length;if(this.rangeCount<1||i<1)return!1;const r=Pe(t),n=this.cellCtrl.getCellPosition(),s=e.get("enableFillHandle")&&!this.cellCtrl.isSuppressFillHandle(),o=e.get("enableRangeHandle");let a=1===i&&!this.cellCtrl.isEditing()&&(s||o);if(this.hasChartRange){const e=1===t[0].type&&this.rangeService.isCellInSpecificRange(n,t[0]);this.cellComp.addOrRemoveCssClass("ag-cell-range-chart-category",e),a=0===r.type}return a&&null!=r.endRow&&this.rangeService.isContiguousRange(r)&&this.rangeService.isBottomRightCell(r,n)}addSelectionHandle(){const e=this.beans.gos,t=Pe(this.rangeService.getCellRanges()).type,i=e.get("enableFillHandle")&&w(t)?0:1;this.selectionHandle&&this.selectionHandle.getType()!==i&&(this.selectionHandle=this.beans.context.destroyBean(this.selectionHandle)),this.selectionHandle||(this.selectionHandle=this.selectionHandleFactory.createSelectionHandle(i)),this.selectionHandle.refresh(this.cellCtrl)}destroy(){this.beans.context.destroyBean(this.selectionHandle)}},oa=class extends nt{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.column=e.getColumn(),this.rowNode=e.getRowNode()}setupRowSpan(){this.rowSpan=this.column.getRowSpan(this.rowNode),this.addManagedListener(this.beans.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.onNewColumnsLoaded())}setComp(e){this.eGui=e,this.setupColSpan(),this.setupRowSpan(),this.onLeftChanged(),this.onWidthChanged(),this.applyRowSpan()}onNewColumnsLoaded(){const e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this.applyRowSpan(!0))}onDisplayColumnsChanged(){const e=this.getColSpanningList();xe(this.colsSpanning,e)||(this.colsSpanning=e,this.onWidthChanged(),this.onLeftChanged())}setupColSpan(){null!=this.column.getColDef().colSpan&&(this.colsSpanning=this.getColSpanningList(),this.addManagedListener(this.beans.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayColumnsChanged.bind(this)),this.addManagedListener(this.beans.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onWidthChanged.bind(this)))}onWidthChanged(){if(!this.eGui)return;const e=this.getCellWidth();this.eGui.style.width=`${e}px`}getCellWidth(){return this.colsSpanning?this.colsSpanning.reduce((e,t)=>e+t.getActualWidth(),0):this.column.getActualWidth()}getColSpanningList(){const e=this.column.getColSpan(this.rowNode),t=[];if(1===e)t.push(this.column);else{let i=this.column;const r=this.column.getPinned();for(let n=0;i&&n<e&&(t.push(i),i=this.beans.columnModel.getDisplayedColAfter(i),i&&!w(i))&&r===i.getPinned();n++);}return t}onLeftChanged(){if(!this.eGui)return;const e=this.modifyLeftForPrintLayout(this.getCellLeft());this.eGui.style.left=e+"px"}getCellLeft(){let e;return e=this.beans.gos.get("enableRtl")&&this.colsSpanning?Pe(this.colsSpanning):this.column,e.getLeft()}modifyLeftForPrintLayout(e){if(!this.cellCtrl.isPrintLayout()||"left"===this.column.getPinned())return e;const t=this.beans.columnModel.getDisplayedColumnsLeftWidth();return"right"===this.column.getPinned()?t+this.beans.columnModel.getBodyContainerWidth()+(e||0):t+(e||0)}applyRowSpan(e){if(1===this.rowSpan&&!e)return;const t=this.beans.gos.getRowHeightAsNumber()*this.rowSpan;this.eGui.style.height=`${t}px`,this.eGui.style.zIndex="1"}destroy(){super.destroy()}},aa=class extends nt{constructor(e,t){super(),this.staticClasses=[],this.cellCtrl=e,this.beans=t,this.column=e.getColumn(),this.rowNode=e.getRowNode()}setComp(e){this.cellComp=e,this.applyUserStyles(),this.applyCellClassRules(),this.applyClassesFromColDef()}applyCellClassRules(){const e=this.column.getColDef(),{cellClassRules:t}=e,i=this.beans.gos.addGridCommonParams({value:this.cellCtrl.getValue(),data:this.rowNode.data,node:this.rowNode,colDef:e,column:this.column,rowIndex:this.rowNode.rowIndex});this.beans.stylingService.processClassRules(t===this.cellClassRules?void 0:this.cellClassRules,t,i,e=>this.cellComp.addOrRemoveCssClass(e,!0),e=>this.cellComp.addOrRemoveCssClass(e,!1)),this.cellClassRules=t}applyUserStyles(){const e=this.column.getColDef();if(!e.cellStyle)return;let t;if("function"==typeof e.cellStyle){const i=this.beans.gos.addGridCommonParams({column:this.column,value:this.cellCtrl.getValue(),colDef:e,data:this.rowNode.data,node:this.rowNode,rowIndex:this.rowNode.rowIndex});t=(0,e.cellStyle)(i)}else t=e.cellStyle;t&&this.cellComp.setUserStyles(t)}applyClassesFromColDef(){const e=this.column.getColDef(),t=this.beans.gos.addGridCommonParams({value:this.cellCtrl.getValue(),data:this.rowNode.data,node:this.rowNode,column:this.column,colDef:e,rowIndex:this.rowNode.rowIndex});this.staticClasses.length&&this.staticClasses.forEach(e=>this.cellComp.addOrRemoveCssClass(e,!1)),this.staticClasses=this.beans.stylingService.getStaticCellClasses(e,t),this.staticClasses.length&&this.staticClasses.forEach(e=>this.cellComp.addOrRemoveCssClass(e,!0))}destroy(){super.destroy()}},la=class{postConstruct(){this.gos.isRowModelType("clientSide")&&(this.clientSideRowModel=this.rowModel),this.gos.isRowModelType("serverSide")&&(this.serverSideRowModel=this.rowModel)}};g([he("resizeObserverService")],la.prototype,"resizeObserverService",2),g([he("paginationProxy")],la.prototype,"paginationProxy",2),g([he("context")],la.prototype,"context",2),g([he("gridOptionsService")],la.prototype,"gos",2),g([he("environment")],la.prototype,"environment",2),g([he("rowRenderer")],la.prototype,"rowRenderer",2),g([he("valueService")],la.prototype,"valueService",2),g([he("eventService")],la.prototype,"eventService",2),g([he("columnModel")],la.prototype,"columnModel",2),g([he("headerNavigationService")],la.prototype,"headerNavigationService",2),g([he("navigationService")],la.prototype,"navigationService",2),g([he("columnAnimationService")],la.prototype,"columnAnimationService",2),g([he("focusService")],la.prototype,"focusService",2),g([he("popupService")],la.prototype,"popupService",2),g([he("stylingService")],la.prototype,"stylingService",2),g([he("columnHoverService")],la.prototype,"columnHoverService",2),g([he("userComponentFactory")],la.prototype,"userComponentFactory",2),g([he("userComponentRegistry")],la.prototype,"userComponentRegistry",2),g([he("animationFrameService")],la.prototype,"animationFrameService",2),g([he("dragService")],la.prototype,"dragService",2),g([he("dragAndDropService")],la.prototype,"dragAndDropService",2),g([he("sortController")],la.prototype,"sortController",2),g([he("filterManager")],la.prototype,"filterManager",2),g([he("rowContainerHeightService")],la.prototype,"rowContainerHeightService",2),g([he("frameworkOverrides")],la.prototype,"frameworkOverrides",2),g([he("cellPositionUtils")],la.prototype,"cellPositionUtils",2),g([he("rowPositionUtils")],la.prototype,"rowPositionUtils",2),g([he("selectionService")],la.prototype,"selectionService",2),g([he("rowCssClassCalculator")],la.prototype,"rowCssClassCalculator",2),g([he("rowModel")],la.prototype,"rowModel",2),g([he("ctrlsService")],la.prototype,"ctrlsService",2),g([he("ctrlsFactory")],la.prototype,"ctrlsFactory",2),g([he("agStackComponentsRegistry")],la.prototype,"agStackComponentsRegistry",2),g([he("valueCache")],la.prototype,"valueCache",2),g([he("rowNodeEventThrottle")],la.prototype,"rowNodeEventThrottle",2),g([he("localeService")],la.prototype,"localeService",2),g([he("syncService")],la.prototype,"syncService",2),g([he("ariaAnnouncementService")],la.prototype,"ariaAnnouncementService",2),g([de("rangeService")],la.prototype,"rangeService",2),g([de("selectionHandleFactory")],la.prototype,"selectionHandleFactory",2),g([le],la.prototype,"postConstruct",1),la=g([ue("beans")],la);var ca=class extends la{constructor(e,t,i){super(),this.cellCtrl=e,this.beans=t,this.column=i}onMouseEvent(e,t){if(!Qe(t))switch(e){case"click":this.onCellClicked(t);break;case"mousedown":case"touchstart":this.onMouseDown(t);break;case"dblclick":this.onCellDoubleClicked(t);break;case"mouseout":this.onMouseOut(t);break;case"mouseover":this.onMouseOver(t)}}onCellClicked(e){if(this.isDoubleClickOnIPad())return this.onCellDoubleClicked(e),void e.preventDefault();const{eventService:t,rangeService:i,gos:r}=this.beans,n=e.ctrlKey||e.metaKey;i&&n&&i.getCellRangeCount(this.cellCtrl.getCellPosition())>1&&i.intersectLastRange(!0);const s=this.cellCtrl.createEvent(e,ct.EVENT_CELL_CLICKED);t.dispatchEvent(s);const o=this.column.getColDef();o.onCellClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{o.onCellClicked(s)})},0),!r.get("singleClickEdit")&&!o.singleClickEdit||r.get("suppressClickEdit")||e.shiftKey&&0!=(null==i?void 0:i.getCellRanges().length)||this.cellCtrl.startRowOrCellEdit()}isDoubleClickOnIPad(){if(!Ii()||Xe("dblclick"))return!1;const e=(new Date).getTime(),t=e-this.lastIPadMouseClickEvent<200;return this.lastIPadMouseClickEvent=e,t}onCellDoubleClicked(e){const t=this.column.getColDef(),i=this.cellCtrl.createEvent(e,ct.EVENT_CELL_DOUBLE_CLICKED);this.beans.eventService.dispatchEvent(i),"function"==typeof t.onCellDoubleClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{t.onCellDoubleClicked(i)})},0),!this.beans.gos.get("singleClickEdit")&&!this.beans.gos.get("suppressClickEdit")&&this.cellCtrl.startRowOrCellEdit(null,e)}onMouseDown(e){const{ctrlKey:t,metaKey:i,shiftKey:r}=e,n=e.target,{cellCtrl:s,beans:o}=this,{eventService:a,rangeService:l,focusService:c}=o;if(this.isRightClickInExistingRange(e))return;const u=l&&0!=l.getCellRanges().length;if(!r||!u){const e=Ri()&&!s.isEditing()&&!sr(n);s.focusCell(e)}if(r&&u&&!c.isCellFocused(s.getCellPosition())){e.preventDefault();const t=c.getFocusedCell();if(t){const{column:e,rowIndex:i,rowPinned:r}=t,n=o.rowRenderer.getRowByPosition({rowIndex:i,rowPinned:r}),s=null==n?void 0:n.getCellCtrl(e);(null==s?void 0:s.isEditing())&&s.stopEditing(),c.setFocusedCell({column:e,rowIndex:i,rowPinned:r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}}if(!this.containsWidget(n)){if(l){const e=this.cellCtrl.getCellPosition();if(r)l.extendLatestRangeToCell(e);else{const r=t||i;l.setRangeToCell(e,r)}}a.dispatchEvent(this.cellCtrl.createEvent(e,ct.EVENT_CELL_MOUSE_DOWN))}}isRightClickInExistingRange(e){const{rangeService:t}=this.beans;if(t){const i=t.isCellInAnyRange(this.cellCtrl.getCellPosition()),r=2===e.button||e.ctrlKey&&this.beans.gos.get("allowContextMenuWithControlKey");if(i&&r)return!0}return!1}containsWidget(e){return cr(e,"ag-selection-checkbox",3)}onMouseOut(e){if(this.mouseStayingInsideCell(e))return;const t=this.cellCtrl.createEvent(e,ct.EVENT_CELL_MOUSE_OUT);this.beans.eventService.dispatchEvent(t),this.beans.columnHoverService.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;const t=this.cellCtrl.createEvent(e,ct.EVENT_CELL_MOUSE_OVER);this.beans.eventService.dispatchEvent(t),this.beans.columnHoverService.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;const t=this.cellCtrl.getGui(),i=t.contains(e.target),r=t.contains(e.relatedTarget);return i&&r}destroy(){}},ua=class extends nt{constructor(e,t,i,r,n){super(),this.cellCtrl=e,this.beans=t,this.rowNode=r,this.rowCtrl=n}setComp(e){this.eGui=e}onKeyDown(e){const t=e.key;switch(t){case Qr.ENTER:this.onEnterKeyDown(e);break;case Qr.F2:this.onF2KeyDown(e);break;case Qr.ESCAPE:this.onEscapeKeyDown(e);break;case Qr.TAB:this.onTabKeyDown(e);break;case Qr.BACKSPACE:case Qr.DELETE:this.onBackspaceOrDeleteKeyDown(t,e);break;case Qr.DOWN:case Qr.UP:case Qr.RIGHT:case Qr.LEFT:this.onNavigationKeyDown(e,t)}}onNavigationKeyDown(e,t){this.cellCtrl.isEditing()||(e.shiftKey&&this.cellCtrl.isRangeSelectionEnabled()?this.onShiftRangeSelect(e):this.beans.navigationService.navigateToNextCell(e,t,this.cellCtrl.getCellPosition(),!0),e.preventDefault())}onShiftRangeSelect(e){if(!this.beans.rangeService)return;const t=this.beans.rangeService.extendLatestRangeInDirection(e);t&&this.beans.navigationService.ensureCellVisible(t)}onTabKeyDown(e){this.beans.navigationService.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){var i;const{cellCtrl:r,beans:n,rowNode:s}=this,{gos:o,rangeService:a,eventService:l}=n;if(!r.isEditing()){if(l.dispatchEvent({type:ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_START}),tn(e,o.get("enableCellEditingOnBackspace"))){if(a&&o.get("enableRangeSelection"))a.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(r.isCellEditable()){const e=r.getColumn(),t=null!=(i=this.beans.valueService.parseValue(e,s,"",s.getValueFromValueService(e)))?i:null;s.setDataValue(e,t,"cellClear")}}else r.startRowOrCellEdit(e,t);l.dispatchEvent({type:ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_END})}}onEnterKeyDown(e){if(this.cellCtrl.isEditing()||this.rowCtrl.isEditing())this.cellCtrl.stopEditingAndFocus(!1,e.shiftKey);else if(this.beans.gos.get("enterNavigatesVertically")){const t=e.shiftKey?Qr.UP:Qr.DOWN;this.beans.navigationService.navigateToNextCell(null,t,this.cellCtrl.getCellPosition(),!1)}else this.cellCtrl.startRowOrCellEdit(Qr.ENTER,e),this.cellCtrl.isEditing()&&e.preventDefault()}onF2KeyDown(e){this.cellCtrl.isEditing()||this.cellCtrl.startRowOrCellEdit(Qr.F2,e)}onEscapeKeyDown(e){this.cellCtrl.isEditing()&&(this.cellCtrl.stopRowOrCellEdit(!0),this.cellCtrl.focusCell(!0))}processCharacter(e){if(e.target!==this.eGui||this.cellCtrl.isEditing())return;const t=e.key;" "===t?this.onSpaceKeyDown(e):(this.cellCtrl.startRowOrCellEdit(t,e),e.preventDefault())}onSpaceKeyDown(e){const{gos:t}=this.beans;if(!this.cellCtrl.isEditing()&&t.isRowSelection()){const i=this.rowNode.isSelected(),r=!i;if(r||!t.get("suppressRowDeselection")){const t=this.beans.gos.get("groupSelectsFiltered"),n=this.rowNode.setSelectedParams({newValue:r,rangeSelect:e.shiftKey,groupSelectsFiltered:t,event:e,source:"spaceKey"});void 0===i&&0===n&&this.rowNode.setSelectedParams({newValue:!1,rangeSelect:e.shiftKey,groupSelectsFiltered:t,event:e,source:"spaceKey"})}}e.preventDefault()}destroy(){super.destroy()}},ha=class extends wn{constructor(e,t,i){super('<div class="ag-drag-handle ag-row-drag" draggable="true"></div>'),this.rowNode=e,this.column=t,this.eCell=i}postConstruct(){this.getGui().appendChild(qr("rowDrag",this.gos,null)),this.addGuiEventListener("mousedown",e=>{e.stopPropagation()}),this.addDragSource(),this.checkVisibility()}addDragSource(){this.addGuiEventListener("dragstart",this.onDragStart.bind(this))}onDragStart(e){const t=this.column.getColDef().dndSourceOnRowDrag;e.dataTransfer.setDragImage(this.eCell,0,0);t?t(this.gos.addGridCommonParams({rowNode:this.rowNode,dragEvent:e})):(()=>{try{const t=JSON.stringify(this.rowNode.data);e.dataTransfer.setData("application/json",t),e.dataTransfer.setData("text/plain",t)}catch(e){}})()}checkVisibility(){const e=this.column.isDndSource(this.rowNode);this.setDisplayed(e)}};g([le],ha.prototype,"postConstruct",1);var da=class{static getHeaderClassesFromColDef(e,t,i,r){return w(e)?[]:this.getColumnClassesFromCollDef(e.headerClass,e,t,i,r)}static getToolPanelClassesFromColDef(e,t,i,r){return w(e)?[]:this.getColumnClassesFromCollDef(e.toolPanelClass,e,t,i,r)}static refreshFirstAndLastStyles(e,t,i){e.addOrRemoveCssClass("ag-column-first",i.isColumnAtEdge(t,"first")),e.addOrRemoveCssClass("ag-column-last",i.isColumnAtEdge(t,"last"))}static getClassParams(e,t,i,r){return t.addGridCommonParams({colDef:e,column:i,columnGroup:r})}static getColumnClassesFromCollDef(e,t,i,r,n){if(w(e))return[];let s;return s="function"==typeof e?e(this.getClassParams(t,i,r,n)):e,"string"==typeof s?[s]:Array.isArray(s)?[...s]:[]}},pa=0,ga=class e extends nt{constructor(e,t,i,r){super(),this.cellRangeFeature=null,this.cellPositionFeature=null,this.cellCustomStyleFeature=null,this.tooltipFeature=null,this.cellMouseListenerFeature=null,this.cellKeyboardListenerFeature=null,this.suppressRefreshCell=!1,this.onCellCompAttachedFuncs=[],this.column=e,this.rowNode=t,this.beans=i,this.rowCtrl=r,this.instanceId=e.getId()+"-"+pa++,this.colIdSanitised=yt(this.column.getId()),i.gos.get("suppressCellFocus")||(this.tabIndex=-1),this.createCellPosition(),this.addFeatures(),this.updateAndFormatValue(!1)}shouldRestoreFocus(){return this.beans.focusService.shouldRestoreFocus(this.cellPosition)}addFeatures(){this.cellPositionFeature=new oa(this,this.beans),this.addDestroyFunc(()=>{var e;null==(e=this.cellPositionFeature)||e.destroy(),this.cellPositionFeature=null}),this.cellCustomStyleFeature=new aa(this,this.beans),this.addDestroyFunc(()=>{var e;null==(e=this.cellCustomStyleFeature)||e.destroy(),this.cellCustomStyleFeature=null}),this.cellMouseListenerFeature=new ca(this,this.beans,this.column),this.addDestroyFunc(()=>{var e;null==(e=this.cellMouseListenerFeature)||e.destroy(),this.cellMouseListenerFeature=null}),this.cellKeyboardListenerFeature=new ua(this,this.beans,this.column,this.rowNode,this.rowCtrl),this.addDestroyFunc(()=>{var e;null==(e=this.cellKeyboardListenerFeature)||e.destroy(),this.cellKeyboardListenerFeature=null}),this.column.isTooltipEnabled()&&(this.enableTooltipFeature(),this.addDestroyFunc(()=>{this.disableTooltipFeature()})),this.beans.rangeService&&this.beans.gos.get("enableRangeSelection")&&(this.cellRangeFeature=new sa(this.beans,this),this.addDestroyFunc(()=>{var e;null==(e=this.cellRangeFeature)||e.destroy(),this.cellRangeFeature=null}))}enableTooltipFeature(e,t){const i="whenTruncated"===this.beans.gos.get("tooltipShowMode");t||!i||this.isCellRenderer()||(t=()=>{const e=this.getGui(),t=0===e.children.length?e:e.querySelector(".ag-cell-value");return!t||t.scrollWidth>t.clientWidth});const r={getColumn:()=>this.column,getColDef:()=>this.column.getColDef(),getRowIndex:()=>this.cellPosition.rowIndex,getRowNode:()=>this.rowNode,getGui:()=>this.getGui(),getLocation:()=>"cell",getTooltipValue:null!=e?()=>e:()=>{const e=this.column.getColDef(),t=this.rowNode.data;if(e.tooltipField&&y(t))return k(t,e.tooltipField,this.column.isTooltipFieldContainsDots());const i=e.tooltipValueGetter;return i?i(this.beans.gos.addGridCommonParams({location:"cell",colDef:this.column.getColDef(),column:this.column,rowIndex:this.cellPosition.rowIndex,node:this.rowNode,data:this.rowNode.data,value:this.value,valueFormatted:this.valueFormatted})):null},getValueFormatted:()=>this.valueFormatted,shouldDisplayTooltip:t};this.tooltipFeature=new vn(r,this.beans)}disableTooltipFeature(){this.tooltipFeature&&(this.tooltipFeature.destroy(),this.tooltipFeature=null)}setComp(e,t,i,r,n){var s,o,a,l;this.cellComp=e,this.eGui=t,this.printLayout=r,this.addDomData(),this.onCellFocused(this.focusEventToRestore),this.applyStaticCssClasses(),this.setWrapText(),this.onFirstRightPinnedChanged(),this.onLastLeftPinnedChanged(),this.onColumnHover(),this.setupControlComps(),this.setupAutoHeight(i),this.refreshFirstAndLastStyles(),this.refreshAriaColIndex(),null==(s=this.cellPositionFeature)||s.setComp(t),null==(o=this.cellCustomStyleFeature)||o.setComp(e),null==(a=this.tooltipFeature)||a.refreshToolTip(),null==(l=this.cellKeyboardListenerFeature)||l.setComp(this.eGui),this.cellRangeFeature&&this.cellRangeFeature.setComp(e,t),n&&this.isCellEditable()?this.startEditing():this.showValue(),this.onCellCompAttachedFuncs.length&&(this.onCellCompAttachedFuncs.forEach(e=>e()),this.onCellCompAttachedFuncs=[])}setupAutoHeight(e){if(this.isAutoHeight=this.column.isAutoHeight(),!this.isAutoHeight||!e)return;const t=e.parentElement,i=this.beans.gos.getRowHeightForNode(this.rowNode).height,r=n=>{if(this.editing)return;if(!this.isAlive())return;const{paddingTop:s,paddingBottom:o,borderBottomWidth:a,borderTopWidth:l}=ur(t),c=s+o+a+l,u=e.offsetHeight+c;if(n<5){const t=this.beans.gos.getDocument();if(!t||!t.contains(e)||0==u)return void window.setTimeout(()=>r(n+1),0)}const h=Math.max(u,i);this.rowNode.setRowAutoHeight(h,this.column)},n=()=>r(0);n();const s=this.beans.resizeObserverService.observeResize(e,n);this.addDestroyFunc(()=>{s(),this.rowNode.setRowAutoHeight(void 0,this.column)})}getCellAriaRole(){var e;return null!=(e=this.column.getColDef().cellAriaRole)?e:"gridcell"}getInstanceId(){return this.instanceId}getColumnIdSanitised(){return this.colIdSanitised}getTabIndex(){return this.tabIndex}isCellRenderer(){const e=this.column.getColDef();return null!=e.cellRenderer||null!=e.cellRendererSelector}getValueToDisplay(){var e;return null!=(e=this.valueFormatted)?e:this.value}showValue(e=!1){var t;const i=this.getValueToDisplay();let r;if(this.rowNode.stub){const e=this.createCellRendererParams();r=this.beans.userComponentFactory.getLoadingCellRendererDetails(this.column.getColDef(),e)}else if(this.isCellRenderer()){const e=this.createCellRendererParams();r=this.beans.userComponentFactory.getCellRendererDetails(this.column.getColDef(),e)}this.cellComp.setRenderDetails(r,i,e),null==(t=this.cellRangeFeature)||t.refreshHandle()}setupControlComps(){const e=this.column.getColDef();this.includeSelection=this.isIncludeControl(e.checkboxSelection),this.includeRowDrag=this.isIncludeControl(e.rowDrag),this.includeDndSource=this.isIncludeControl(e.dndSource),this.cellComp.setIncludeSelection(this.includeSelection),this.cellComp.setIncludeDndSource(this.includeDndSource),this.cellComp.setIncludeRowDrag(this.includeRowDrag)}isForceWrapper(){return this.beans.gos.get("enableCellTextSelection")||this.column.isAutoHeight()}isIncludeControl(e){return!(null!=this.rowNode.rowPinned||"function"!=typeof e&&!0!==e)}refreshShouldDestroy(){const e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(e.checkboxSelection),i=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),r=this.includeDndSource!=this.isIncludeControl(e.dndSource),n=this.isAutoHeight!=this.column.isAutoHeight();return t||i||r||n}startEditing(e=null,t=!1,i=null){if(!this.isCellEditable()||this.editing)return;if(!this.cellComp)return void this.onCellCompAttachedFuncs.push(()=>{this.startEditing(e,t,i)});const r=this.createCellEditorParams(e,t),n=this.column.getColDef(),s=this.beans.userComponentFactory.getCellEditorDetails(n,r);this.editCompDetails=s;const o=null!=(null==s?void 0:s.popupFromSelector)?s.popupFromSelector:!!n.cellEditorPopup,a=null!=(null==s?void 0:s.popupPositionFromSelector)?s.popupPositionFromSelector:n.cellEditorPopupPosition;this.setEditing(!0),this.cellComp.setEditDetails(s,o,a,this.beans.gos.get("reactiveCustomComponents"));const l=this.createEvent(i,ct.EVENT_CELL_EDITING_STARTED);this.beans.eventService.dispatchEvent(l)}setEditing(e){var t;this.editing!==e&&(this.editing=e,null==(t=this.cellRangeFeature)||t.refreshHandle())}stopRowOrCellEdit(e=!1){"fullRow"===this.beans.gos.get("editType")?this.rowCtrl.stopEditing(e):this.stopEditing(e)}onPopupEditorClosed(){this.isEditing()&&this.stopEditingAndFocus()}takeValueFromCellEditor(e){const t={newValueExists:!1};if(e)return t;const i=this.cellComp.getCellEditor();return i?i.isCancelAfterEnd&&i.isCancelAfterEnd()?t:{newValue:i.getValue(),newValueExists:!0}:t}saveNewValue(e,t){if(t===e)return!1;this.suppressRefreshCell=!0;const i=this.rowNode.setDataValue(this.column,t,"edit");return this.suppressRefreshCell=!1,i}stopEditing(e=!1){if(!this.editing)return!1;const{newValue:t,newValueExists:i}=this.takeValueFromCellEditor(e),r=this.rowNode.getValueFromValueService(this.column);let n=!1;return i&&(n=this.saveNewValue(r,t)),this.setEditing(!1),this.cellComp.setEditDetails(),this.editCompDetails=void 0,this.updateAndFormatValue(!1),this.refreshCell({forceRefresh:!0,suppressFlash:!0}),this.dispatchEditingStoppedEvent(r,t,!e&&!!n),n}dispatchEditingStoppedEvent(e,t,i){const r=d(h({},this.createEvent(null,ct.EVENT_CELL_EDITING_STOPPED)),{oldValue:e,newValue:t,valueChanged:i});this.beans.eventService.dispatchEvent(r)}createCellEditorParams(e,t){return this.beans.gos.addGridCommonParams({value:this.rowNode.getValueFromValueService(this.column),eventKey:e,column:this.column,colDef:this.column.getColDef(),rowIndex:this.getCellPosition().rowIndex,node:this.rowNode,data:this.rowNode.data,cellStartedEdit:t,onKeyDown:this.onKeyDown.bind(this),stopEditing:this.stopEditingAndFocus.bind(this),eGridCell:this.getGui(),parseValue:this.parseValue.bind(this),formatValue:this.formatValue.bind(this)})}createCellRendererParams(){return this.beans.gos.addGridCommonParams({value:this.value,valueFormatted:this.valueFormatted,getValue:()=>this.rowNode.getValueFromValueService(this.column),setValue:e=>this.beans.valueService.setValue(this.rowNode,this.column,e),formatValue:this.formatValue.bind(this),data:this.rowNode.data,node:this.rowNode,pinned:this.column.getPinned(),colDef:this.column.getColDef(),column:this.column,rowIndex:this.getCellPosition().rowIndex,refreshCell:this.refreshCell.bind(this),eGridCell:this.getGui(),eParentOfValue:this.cellComp.getParentOfValue(),registerRowDragger:(e,t,i,r)=>this.registerRowDragger(e,t,r),setTooltip:(e,t)=>{var i;this.tooltipFeature&&this.disableTooltipFeature(),this.enableTooltipFeature(e,t),null==(i=this.tooltipFeature)||i.refreshToolTip()}})}parseValue(e){return this.beans.valueService.parseValue(this.column,this.rowNode,e,this.getValue())}setFocusOutOnEditor(){if(!this.editing)return;const e=this.cellComp.getCellEditor();e&&e.focusOut&&e.focusOut()}setFocusInOnEditor(){if(!this.editing)return;const e=this.cellComp.getCellEditor();e&&e.focusIn?e.focusIn():this.focusCell(!0)}onCellChanged(e){e.column===this.column&&this.refreshCell({})}refreshOrDestroyCell(e){var t;this.refreshShouldDestroy()?null==(t=this.rowCtrl)||t.recreateCell(this):this.refreshCell(e)}refreshCell(e){var t,i,r,n;if(this.suppressRefreshCell||this.editing)return;const s=this.column.getColDef(),o=null!=e&&!!e.newData,a=null!=e&&!!e.suppressFlash||!!s.suppressCellFlash,l=null==s.field&&null==s.valueGetter&&null==s.showRowGroup,c=e&&e.forceRefresh||l||o,u=!!this.cellComp,h=this.updateAndFormatValue(u);if(u){if(c||h){this.showValue(o);const e=this.beans.filterManager.isSuppressFlashingCellsBecauseFiltering();!a&&!e&&(this.beans.gos.get("enableCellChangeFlash")||s.enableCellChangeFlash)&&this.flashCell(),null==(t=this.cellCustomStyleFeature)||t.applyUserStyles(),null==(i=this.cellCustomStyleFeature)||i.applyClassesFromColDef()}null==(r=this.tooltipFeature)||r.refreshToolTip(),null==(n=this.cellCustomStyleFeature)||n.applyCellClassRules()}}stopEditingAndFocus(e=!1,t=!1){this.stopRowOrCellEdit(),this.focusCell(!0),e||this.navigateAfterEdit(t)}navigateAfterEdit(e){if(this.beans.gos.get("enterNavigatesVerticallyAfterEdit")){const t=e?Qr.UP:Qr.DOWN;this.beans.navigationService.navigateToNextCell(null,t,this.getCellPosition(),!1)}}flashCell(e){var t,i;const r=null!=(t=null==e?void 0:e.flashDuration)?t:null==e?void 0:e.flashDelay,n=null!=(i=null==e?void 0:e.fadeDuration)?i:null==e?void 0:e.fadeDelay;this.animateCell("data-changed",r,n)}animateCell(e,t,i){if(!this.cellComp)return;const r=`ag-cell-${e}`,n=`ag-cell-${e}-animation`,{gos:s}=this.beans;t||(t=s.get("cellFlashDuration")),y(i)||(i=s.get("cellFadeDuration")),this.cellComp.addOrRemoveCssClass(r,!0),this.cellComp.addOrRemoveCssClass(n,!1),this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{this.isAlive()&&(this.cellComp.addOrRemoveCssClass(r,!1),this.cellComp.addOrRemoveCssClass(n,!0),this.eGui.style.transition=`background-color ${i}ms`,window.setTimeout(()=>{this.isAlive()&&(this.cellComp.addOrRemoveCssClass(n,!1),this.eGui.style.transition="")},i))},t)})}onFlashCells(e){if(!this.cellComp)return;const t=this.beans.cellPositionUtils.createId(this.getCellPosition());e.cells[t]&&this.animateCell("highlight")}isCellEditable(){return this.column.isCellEditable(this.rowNode)}isSuppressFillHandle(){return this.column.isSuppressFillHandle()}formatValue(e){var t;return null!=(t=this.callValueFormatter(e))?t:e}callValueFormatter(e){return this.beans.valueService.formatValue(this.column,this.rowNode,e)}updateAndFormatValue(e){const t=this.value,i=this.valueFormatted;return this.value=this.rowNode.getValueFromValueService(this.column),this.valueFormatted=this.callValueFormatter(this.value),!e||!this.valuesAreEqual(t,this.value)||this.valueFormatted!=i}valuesAreEqual(e,t){const i=this.column.getColDef();return i.equals?i.equals(e,t):e===t}getComp(){return this.cellComp}getValue(){return this.value}addDomData(){const t=this.getGui();this.beans.gos.setDomData(t,e.DOM_DATA_KEY_CELL_CTRL,this),this.addDestroyFunc(()=>this.beans.gos.setDomData(t,e.DOM_DATA_KEY_CELL_CTRL,null))}createEvent(e,t){return this.beans.gos.addGridCommonParams({type:t,node:this.rowNode,data:this.rowNode.data,value:this.value,column:this.column,colDef:this.column.getColDef(),rowPinned:this.rowNode.rowPinned,event:e,rowIndex:this.rowNode.rowIndex})}processCharacter(e){var t;null==(t=this.cellKeyboardListenerFeature)||t.processCharacter(e)}onKeyDown(e){var t;null==(t=this.cellKeyboardListenerFeature)||t.onKeyDown(e)}onMouseEvent(e,t){var i;null==(i=this.cellMouseListenerFeature)||i.onMouseEvent(e,t)}getGui(){return this.eGui}getColSpanningList(){return this.cellPositionFeature.getColSpanningList()}onLeftChanged(){var e;this.cellComp&&(null==(e=this.cellPositionFeature)||e.onLeftChanged())}onDisplayedColumnsChanged(){this.eGui&&(this.refreshAriaColIndex(),this.refreshFirstAndLastStyles())}refreshFirstAndLastStyles(){const{cellComp:e,column:t,beans:i}=this;da.refreshFirstAndLastStyles(e,t,i.columnModel)}refreshAriaColIndex(){const e=this.beans.columnModel.getAriaColumnIndex(this.column);ui(this.getGui(),e)}isSuppressNavigable(){return this.column.isSuppressNavigable(this.rowNode)}onWidthChanged(){var e;return null==(e=this.cellPositionFeature)?void 0:e.onWidthChanged()}getColumn(){return this.column}getRowNode(){return this.rowNode}isPrintLayout(){return this.printLayout}getCellPosition(){return this.cellPosition}isEditing(){return this.editing}startRowOrCellEdit(e,t=null){this.cellComp?"fullRow"===this.beans.gos.get("editType")?this.rowCtrl.startRowEditing(e,this):this.startEditing(e,!0,t):this.onCellCompAttachedFuncs.push(()=>{this.startRowOrCellEdit(e,t)})}getRowCtrl(){return this.rowCtrl}getRowPosition(){return{rowIndex:this.cellPosition.rowIndex,rowPinned:this.cellPosition.rowPinned}}updateRangeBordersIfRangeCount(){this.cellComp&&this.cellRangeFeature&&this.cellRangeFeature.updateRangeBordersIfRangeCount()}onRangeSelectionChanged(){this.cellComp&&this.cellRangeFeature&&this.cellRangeFeature.onRangeSelectionChanged()}isRangeSelectionEnabled(){return null!=this.cellRangeFeature}focusCell(e=!1){this.beans.focusService.setFocusedCell({rowIndex:this.getCellPosition().rowIndex,column:this.column,rowPinned:this.rowNode.rowPinned,forceBrowserFocus:e})}onRowIndexChanged(){this.createCellPosition(),this.onCellFocused(),this.cellRangeFeature&&this.cellRangeFeature.onRangeSelectionChanged()}onFirstRightPinnedChanged(){if(!this.cellComp)return;const e=this.column.isFirstRightPinned();this.cellComp.addOrRemoveCssClass("ag-cell-first-right-pinned",e)}onLastLeftPinnedChanged(){if(!this.cellComp)return;const e=this.column.isLastLeftPinned();this.cellComp.addOrRemoveCssClass("ag-cell-last-left-pinned",e)}onCellFocused(e){if(this.beans.gos.get("suppressCellFocus"))return;const t=this.beans.focusService.isCellFocused(this.cellPosition);if(!this.cellComp)return void(t&&(null==e?void 0:e.forceBrowserFocus)&&(this.focusEventToRestore=e));this.focusEventToRestore=void 0,this.cellComp.addOrRemoveCssClass("ag-cell-focus",t),t&&e&&e.forceBrowserFocus&&this.cellComp.getFocusableElement().focus({preventScroll:!!e.preventScrollOnBrowserFocus});const i="fullRow"===this.beans.gos.get("editType");t||i||!this.editing||this.stopRowOrCellEdit(),t&&this.rowCtrl.announceDescription()}createCellPosition(){this.cellPosition={rowIndex:this.rowNode.rowIndex,rowPinned:C(this.rowNode.rowPinned),column:this.column}}applyStaticCssClasses(){this.cellComp.addOrRemoveCssClass("ag-cell",!0),this.cellComp.addOrRemoveCssClass("ag-cell-not-inline-editing",!0);const e=1==this.column.isAutoHeight();this.cellComp.addOrRemoveCssClass("ag-cell-auto-height",e),this.cellComp.addOrRemoveCssClass("ag-cell-normal-height",!e)}onColumnHover(){if(!this.cellComp)return;if(!this.beans.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.cellComp.addOrRemoveCssClass("ag-column-hover",e)}onColDefChanged(){if(this.cellComp)if(this.column.isTooltipEnabled()?(this.disableTooltipFeature(),this.enableTooltipFeature()):this.disableTooltipFeature(),this.setWrapText(),this.editing){const e=this.getCellEditor();if(null==e?void 0:e.refresh){const{eventKey:t,cellStartedEdit:i}=this.editCompDetails.params,r=this.createCellEditorParams(t,i),n=this.column.getColDef(),s=this.beans.userComponentFactory.getCellEditorDetails(n,r);e.refresh(s.params)}}else this.refreshOrDestroyCell({forceRefresh:!0,suppressFlash:!0})}setWrapText(){const e=1==this.column.getColDef().wrapText;this.cellComp.addOrRemoveCssClass("ag-cell-wrap-text",e)}dispatchCellContextMenuEvent(e){const t=this.column.getColDef(),i=this.createEvent(e,ct.EVENT_CELL_CONTEXT_MENU);this.beans.eventService.dispatchEvent(i),t.onCellContextMenu&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(i)})},0)}getCellRenderer(){return this.cellComp?this.cellComp.getCellRenderer():null}getCellEditor(){return this.cellComp?this.cellComp.getCellEditor():null}destroy(){this.onCellCompAttachedFuncs=[],super.destroy()}createSelectionCheckbox(){const e=new Os;return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){const e=new ha(this.rowNode,this.column,this.eGui);return this.beans.context.createBean(e),e}registerRowDragger(e,t,i){if(this.customRowDragComp)return void this.customRowDragComp.setDragElement(e,t);const r=this.createRowDragComp(e,t,i);r&&(this.customRowDragComp=r,this.addDestroyFunc(()=>{this.beans.context.destroyBean(r),this.customRowDragComp=null}))}createRowDragComp(e,t,i){const r=this.beans.gos.get("pagination"),n=this.beans.gos.get("rowDragManaged"),s=this.beans.gos.isRowModelType("clientSide");if(n){if(!s)return void U("managed row dragging is only allowed in the Client Side Row Model");if(r)return void U("managed row dragging is not possible when doing pagination")}const o=new Hs(()=>this.value,this.rowNode,this.column,e,t,i);return this.beans.context.createBean(o),o}};ga.DOM_DATA_KEY_CELL_CTRL="cellCtrl";var fa=ga,ma=0,va=class e extends nt{constructor(e,t,i,r,n){super(),this.allRowGuis=[],this.active=!0,this.centerCellCtrls={list:[],map:{}},this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}},this.slideInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.fadeInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.rowDragComps=[],this.lastMouseDownOnDragger=!1,this.emptyStyle={},this.updateColumnListsPending=!1,this.rowId=null,this.businessKeySanitised=null,this.beans=t,this.gos=t.gos,this.rowNode=e,this.paginationPage=t.paginationProxy.getCurrentPage(),this.useAnimationFrameForCreate=r,this.printLayout=n,this.suppressRowTransform=this.gos.get("suppressRowTransform"),this.instanceId=e.id+"-"+ma++,this.rowId=yt(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusService.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=t.rowCssClassCalculator.calculateRowLevel(this.rowNode),this.setRowType(),this.setAnimateFlags(i),this.rowStyles=this.processStylesFromGridOptions(),this.isFullWidth()&&!this.gos.get("suppressCellFocus")&&(this.tabIndex=-1),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if("function"!=typeof this.businessKeyForNodeFunc)return;const e=this.businessKeyForNodeFunc(this.rowNode);this.businessKeySanitised=yt(e)}getRowId(){return this.rowId}getRowStyles(){return this.rowStyles}getTabIndex(){return this.tabIndex}isSticky(){return this.rowNode.sticky}getInstanceId(){return this.instanceId}setComp(e,t,i){const r={rowComp:e,element:t,containerType:i};this.allRowGuis.push(r),"left"===i?this.leftGui=r:"right"===i?this.rightGui=r:"fullWidth"===i?this.fullWidthGui=r:this.centerGui=r,this.initialiseRowComp(r),"FullWidthLoading"===this.rowType||this.rowNode.rowPinned||this.beans.rowRenderer.dispatchFirstDataRenderedEvent()}unsetComp(e){switch(this.allRowGuis=this.allRowGuis.filter(t=>t.containerType!==e),e){case"left":this.leftGui=void 0;break;case"right":this.rightGui=void 0;break;case"fullWidth":this.fullWidthGui=void 0;break;case"center":this.centerGui=void 0}}isCacheable(){return"FullWidthDetail"===this.rowType&&this.gos.get("keepDetailRows")}setCached(e){const t=e?"none":"";this.allRowGuis.forEach(e=>e.element.style.display=t)}initialiseRowComp(t){const i=this.gos;this.listenOnDomOrder(t),this.beans.columnModel.wasAutoRowHeightEverActive()&&this.rowNode.checkAutoHeights(),this.onRowHeightChanged(t),this.updateRowIndexes(t),this.setFocusedClasses(t),this.setStylesFromGridOptions(!1,t),i.isRowSelection()&&this.rowNode.selectable&&this.onRowSelected(t),this.updateColumnLists(!this.useAnimationFrameForCreate);const r=t.rowComp;this.getInitialRowClasses(t.containerType).forEach(e=>r.addOrRemoveCssClass(e,!0)),this.executeSlideAndFadeAnimations(t),this.rowNode.group&&ii(t.element,1==this.rowNode.expanded),this.setRowCompRowId(r),this.setRowCompRowBusinessKey(r),i.setDomData(t.element,e.DOM_DATA_KEY_ROW_CTRL,this),this.addDestroyFunc(()=>i.setDomData(t.element,e.DOM_DATA_KEY_ROW_CTRL,null)),this.useAnimationFrameForCreate?this.beans.animationFrameService.createTask(this.addHoverFunctionality.bind(this,t.element),this.rowNode.rowIndex,"createTasksP2"):this.addHoverFunctionality(t.element),this.isFullWidth()&&this.setupFullWidth(t),i.get("rowDragEntireRow")&&this.addRowDraggerToRow(t),this.useAnimationFrameForCreate&&this.beans.animationFrameService.addDestroyTask(()=>{this.isAlive()&&t.rowComp.addOrRemoveCssClass("ag-after-created",!0)}),this.executeProcessRowPostCreateFunc()}setRowCompRowBusinessKey(e){null!=this.businessKeySanitised&&e.setRowBusinessKey(this.businessKeySanitised)}getBusinessKey(){return this.businessKeySanitised}setRowCompRowId(e){this.rowId=yt(this.rowNode.id),null!=this.rowId&&e.setRowId(this.rowId)}executeSlideAndFadeAnimations(e){const{containerType:t}=e;this.slideInAnimation[t]&&(Q(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1),this.fadeInAnimation[t]&&(Q(()=>{e.rowComp.addOrRemoveCssClass("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){if(this.gos.get("enableRangeSelection"))return void U("Setting `rowDragEntireRow: true` in the gridOptions doesn't work with `enableRangeSelection: true`");const t=this.beans.localeService.getLocaleTextFunc(),i=new Hs(()=>`1 ${t("rowDragRow","row")}`,this.rowNode,void 0,e.element,void 0,!0),r=this.createBean(i,this.beans.context);this.rowDragComps.push(r)}setupFullWidth(e){const t=this.getPinnedForContainer(e.containerType);if("FullWidthDetail"==this.rowType&&!se.__assertRegistered("@ag-grid-enterprise/master-detail","cell renderer 'agDetailCellRenderer' (for master detail)",this.beans.context.getGridId()))return;const i=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(i)}isPrintLayout(){return this.printLayout}getFullWidthCellRenderers(){var e,t;return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(e=>{var t;return null==(t=null==e?void 0:e.rowComp)?void 0:t.getFullWidthCellRenderer()}):[null==(t=null==(e=this.fullWidthGui)?void 0:e.rowComp)?void 0:t.getFullWidthCellRenderer()]}getCellElement(e){const t=this.getCellCtrl(e);return t?t.getGui():null}executeProcessRowPostCreateFunc(){const e=this.gos.getCallback("processRowPostCreate");e&&this.areAllContainersReady()&&e({eRow:this.centerGui.element,ePinnedLeftRow:this.leftGui?this.leftGui.element:void 0,ePinnedRightRow:this.rightGui?this.rightGui.element:void 0,node:this.rowNode,rowIndex:this.rowNode.rowIndex,addRenderedRowListener:this.addEventListener.bind(this)})}areAllContainersReady(){const e=!!this.leftGui||!this.beans.columnModel.isPinningLeft(),t=!!this.centerGui,i=!!this.rightGui||!this.beans.columnModel.isPinningRight();return e&&t&&i}setRowType(){const e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow"),t=this.rowNode.isFullWidthCell(),i=this.gos.get("masterDetail")&&this.rowNode.detail,r=this.beans.columnModel.isPivotMode(),n=!!this.rowNode.group&&!this.rowNode.footer&&this.gos.isGroupUseEntireRow(r);this.rowType=e?"FullWidthLoading":i?"FullWidthDetail":t?"FullWidth":n?"FullWidthGroup":"Normal"}updateColumnLists(e=!1,t=!1){this.isFullWidth()||(e||this.gos.get("suppressAnimationFrame")||this.printLayout?this.updateColumnListsImpl(t):this.updateColumnListsPending||(this.beans.animationFrameService.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"createTasksP1"),this.updateColumnListsPending=!0))}createCellCtrls(e,t,i=null){const r={list:[],map:{}},n=(e,t)=>{r.list.push(t),r.map[e]=t};return t.forEach(t=>{const i=t.getInstanceId();let r=e.map[i];r||(r=new fa(t,this.rowNode,this.beans,this)),n(i,r)}),e.list.forEach(e=>{null==r.map[e.getColumn().getInstanceId()]&&(this.isCellEligibleToBeRemoved(e,i)?e.destroy():n(e.getColumn().getInstanceId(),e))}),r}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){this.allRowGuis.forEach(t=>{const i=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(i,e)})}getCellCtrlsForContainer(e){switch(e){case"left":return this.leftCellCtrls.list;case"right":return this.rightCellCtrls.list;case"fullWidth":return[];case"center":return this.centerCellCtrls.list;default:throw new Error(`Unhandled case: ${e}`)}}createAllCellCtrls(){const e=this.beans.columnModel;if(this.printLayout)this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,e.getAllDisplayedColumns()),this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}};else{const t=e.getViewportCenterColumnsForRow(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,t);const i=e.getDisplayedLeftColumnsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,i,"left");const r=e.getDisplayedRightColumnsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,r,"right")}}isCellEligibleToBeRemoved(e,t){const i=!0;if(e.getColumn().getPinned()!=t)return i;const r=e.isEditing(),n=this.beans.focusService.isCellFocused(e.getCellPosition());if(r||n){const t=e.getColumn();return!(this.beans.columnModel.getAllDisplayedColumns().indexOf(t)>=0)&&i}return i}getDomOrder(){return this.gos.get("ensureDomOrder")||this.gos.isDomLayout("print")}listenOnDomOrder(e){const t=()=>{e.rowComp.setDomOrder(this.getDomOrder())};this.addManagedPropertyListener("domLayout",t),this.addManagedPropertyListener("ensureDomOrder",t)}setAnimateFlags(e){if(this.isSticky()||!e)return;const t=y(this.rowNode.oldRowTop),i=this.beans.columnModel.isPinningLeft(),r=this.beans.columnModel.isPinningRight();if(t){if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(this.slideInAnimation.fullWidth=!0);this.slideInAnimation.center=!0,this.slideInAnimation.left=i,this.slideInAnimation.right=r}else{if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(this.fadeInAnimation.fullWidth=!0);this.fadeInAnimation.center=!0,this.fadeInAnimation.left=i,this.fadeInAnimation.right=r}}isEditing(){return this.editingRow}isFullWidth(){return"Normal"!==this.rowType}refreshFullWidth(){const e=(e,t)=>!e||e.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(e.element,t).params),t=e(this.fullWidthGui,null),i=e(this.centerGui,null),r=e(this.leftGui,"left"),n=e(this.rightGui,"right");return t&&i&&r&&n}addListeners(){this.addManagedListener(this.rowNode,Ns.EVENT_HEIGHT_CHANGED,()=>this.onRowHeightChanged()),this.addManagedListener(this.rowNode,Ns.EVENT_ROW_SELECTED,()=>this.onRowSelected()),this.addManagedListener(this.rowNode,Ns.EVENT_ROW_INDEX_CHANGED,this.onRowIndexChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_TOP_CHANGED,this.onTopChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_EXPANDED_CHANGED,this.updateExpandedCss.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_HAS_CHILDREN_CHANGED,this.updateExpandedCss.bind(this)),this.rowNode.detail&&this.addManagedListener(this.rowNode.parent,Ns.EVENT_DATA_CHANGED,this.onRowNodeDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_DATA_CHANGED,this.onRowNodeDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,this.postProcessCss.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_HIGHLIGHT_CHANGED,this.onRowNodeHighlightChanged.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_DRAGGING_CHANGED,this.postProcessRowDragging.bind(this)),this.addManagedListener(this.rowNode,Ns.EVENT_UI_LEVEL_CHANGED,this.onUiLevelChanged.bind(this));const e=this.beans.eventService;this.addManagedListener(e,ct.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED,this.onPaginationPixelOffsetChanged.bind(this)),this.addManagedListener(e,ct.EVENT_HEIGHT_SCALE_CHANGED,this.onTopChanged.bind(this)),this.addManagedListener(e,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(e,ct.EVENT_VIRTUAL_COLUMNS_CHANGED,this.onVirtualColumnsChanged.bind(this)),this.addManagedListener(e,ct.EVENT_CELL_FOCUSED,this.onCellFocusChanged.bind(this)),this.addManagedListener(e,ct.EVENT_CELL_FOCUS_CLEARED,this.onCellFocusChanged.bind(this)),this.addManagedListener(e,ct.EVENT_PAGINATION_CHANGED,this.onPaginationChanged.bind(this)),this.addManagedListener(e,ct.EVENT_MODEL_UPDATED,this.refreshFirstAndLastRowStyles.bind(this)),this.addManagedListener(e,ct.EVENT_COLUMN_MOVED,this.updateColumnLists.bind(this)),this.addDestroyFunc(()=>{this.destroyBeans(this.rowDragComps,this.beans.context),this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature,this.beans.context))}),this.addManagedPropertyListeners(["rowDragEntireRow"],()=>{this.gos.get("rowDragEntireRow")?this.allRowGuis.forEach(e=>{this.addRowDraggerToRow(e)}):(this.destroyBeans(this.rowDragComps,this.beans.context),this.rowDragComps=[])}),this.addListenersForCellComps()}addListenersForCellComps(){this.addManagedListener(this.rowNode,Ns.EVENT_ROW_INDEX_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onRowIndexChanged())}),this.addManagedListener(this.rowNode,Ns.EVENT_CELL_CHANGED,e=>{this.getAllCellCtrls().forEach(t=>t.onCellChanged(e))})}onRowNodeDataChanged(e){if(this.isFullWidth()!==!!this.rowNode.isFullWidthCell())this.beans.rowRenderer.redrawRow(this.rowNode);else{if(this.isFullWidth())return void(this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode));this.getAllCellCtrls().forEach(t=>t.refreshCell({suppressFlash:!e.update,newData:!e.update})),this.allRowGuis.forEach(e=>{this.setRowCompRowId(e.rowComp),this.updateRowBusinessKey(),this.setRowCompRowBusinessKey(e.rowComp)}),this.onRowSelected(),this.postProcessCss()}}postProcessCss(){this.setStylesFromGridOptions(!0),this.postProcessClassesFromGridOptions(),this.postProcessRowClassRules(),this.postProcessRowDragging()}onRowNodeHighlightChanged(){const e=this.rowNode.highlighted;this.allRowGuis.forEach(t=>{const i=0===e,r=1===e;t.rowComp.addOrRemoveCssClass("ag-row-highlight-above",i),t.rowComp.addOrRemoveCssClass("ag-row-highlight-below",r)})}postProcessRowDragging(){const e=this.rowNode.dragging;this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-dragging",e))}updateExpandedCss(){const e=this.rowNode.isExpandable(),t=1==this.rowNode.expanded;this.allRowGuis.forEach(i=>{i.rowComp.addOrRemoveCssClass("ag-row-group",e),i.rowComp.addOrRemoveCssClass("ag-row-group-expanded",e&&t),i.rowComp.addOrRemoveCssClass("ag-row-group-contracted",e&&!t),ii(i.element,e&&t)})}onDisplayedColumnsChanged(){this.updateColumnLists(!0),this.beans.columnModel.wasAutoRowHeightEverActive()&&this.rowNode.checkAutoHeights()}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:C(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}onKeyboardNavigate(e){const t=this.allRowGuis.find(t=>t.element.contains(e.target));if((t?t.element:null)!==e.target)return;const i=this.rowNode,r=this.beans.focusService.getFocusedCell(),n={rowIndex:i.rowIndex,rowPinned:i.rowPinned,column:r&&r.column};this.beans.navigationService.navigateToNextCell(e,e.key,n,!0),e.preventDefault()}onTabKeyDown(e){if(e.defaultPrevented||Qe(e))return;const t=this.allRowGuis.find(t=>t.element.contains(e.target)),i=t?t.element:null,r=i===e.target;let n=null;r||(n=this.beans.focusService.findNextFocusableElement(i,!1,e.shiftKey)),(this.isFullWidth()&&r||!n)&&this.beans.navigationService.onTabKeyDown(this,e)}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){var e;const t=null==(e=this.allRowGuis.find(e=>br(e.element)))?void 0:e.element;return t?t.getBoundingClientRect().top:0}onFullWidthRowFocused(e){var t;const i=this.rowNode,r=!!e&&this.isFullWidth()&&e.rowIndex===i.rowIndex&&e.rowPinned==i.rowPinned,n=this.fullWidthGui?this.fullWidthGui.element:null==(t=this.centerGui)?void 0:t.element;n&&(n.classList.toggle("ag-full-width-focus",r),r&&n.focus({preventScroll:!0}))}recreateCell(e){this.centerCellCtrls=this.removeCellCtrl(this.centerCellCtrls,e),this.leftCellCtrls=this.removeCellCtrl(this.leftCellCtrls,e),this.rightCellCtrls=this.removeCellCtrl(this.rightCellCtrls,e),e.destroy(),this.updateColumnLists()}removeCellCtrl(e,t){const i={list:[],map:{}};return e.list.forEach(e=>{e!==t&&(i.list.push(e),i.map[e.getColumn().getInstanceId()]=e)}),i}onMouseEvent(e,t){switch(e){case"dblclick":this.onRowDblClick(t);break;case"click":this.onRowClick(t);break;case"touchstart":case"mousedown":this.onRowMouseDown(t)}}createRowEvent(e,t){return this.gos.addGridCommonParams({type:e,node:this.rowNode,data:this.rowNode.data,rowIndex:this.rowNode.rowIndex,rowPinned:this.rowNode.rowPinned,event:t})}createRowEventWithSource(e,t){const i=this.createRowEvent(e,t);return i.source=this,i}onRowDblClick(e){if(Qe(e))return;const t=this.createRowEventWithSource(ct.EVENT_ROW_DOUBLE_CLICKED,e);this.beans.eventService.dispatchEvent(t)}onRowMouseDown(e){if(this.lastMouseDownOnDragger=cr(e.target,"ag-row-drag",3),!this.isFullWidth())return;const t=this.rowNode,i=this.beans.columnModel;this.beans.rangeService&&this.beans.rangeService.removeAllCellRanges(),this.beans.focusService.setFocusedCell({rowIndex:t.rowIndex,column:i.getAllDisplayedColumns()[0],rowPinned:t.rowPinned,forceBrowserFocus:!0})}onRowClick(e){if(Qe(e)||this.lastMouseDownOnDragger)return;const t=this.createRowEventWithSource(ct.EVENT_ROW_CLICKED,e);this.beans.eventService.dispatchEvent(t);const i=e.ctrlKey||e.metaKey,r=e.shiftKey;if(this.gos.get("groupSelectsChildren")&&this.rowNode.group||this.isRowSelectionBlocked()||this.gos.get("suppressRowClickSelection"))return;const n=this.gos.get("rowMultiSelectWithClick"),s=!this.gos.get("suppressRowDeselection"),o="rowClicked";if(this.rowNode.isSelected())n?this.rowNode.setSelectedParams({newValue:!1,event:e,source:o}):i?s&&this.rowNode.setSelectedParams({newValue:!1,event:e,source:o}):this.rowNode.setSelectedParams({newValue:!0,clearSelection:!r,rangeSelect:r,event:e,source:o});else{const t=!n&&!i;this.rowNode.setSelectedParams({newValue:!0,clearSelection:t,rangeSelect:r,event:e,source:o})}}isRowSelectionBlocked(){return!this.rowNode.selectable||!!this.rowNode.rowPinned||!this.gos.isRowSelection()}setupDetailRowAutoHeight(e){if("FullWidthDetail"!==this.rowType)return;if(!this.gos.get("detailRowAutoHeight"))return;const t=()=>{const t=e.clientHeight;if(null!=t&&t>0){const e=()=>{this.rowNode.setRowHeight(t),this.beans.clientSideRowModel?this.beans.clientSideRowModel.onRowHeightChanged():this.beans.serverSideRowModel&&this.beans.serverSideRowModel.onRowHeightChanged()};window.setTimeout(e,0)}},i=this.beans.resizeObserverService.observeResize(e,t);this.addDestroyFunc(i),t()}createFullWidthCompDetails(e,t){const i=this.gos.addGridCommonParams({fullWidth:!0,data:this.rowNode.data,node:this.rowNode,value:this.rowNode.key,valueFormatted:this.rowNode.key,rowIndex:this.rowNode.rowIndex,eGridCell:e,eParentOfValue:e,pinned:t,addRenderedRowListener:this.addEventListener.bind(this),registerRowDragger:(e,t,i,r)=>this.addFullWidthRowDragging(e,t,i,r),setTooltip:(e,t)=>this.refreshRowTooltip(e,t)});switch(this.rowType){case"FullWidthDetail":return this.beans.userComponentFactory.getFullWidthDetailCellRendererDetails(i);case"FullWidthGroup":return this.beans.userComponentFactory.getFullWidthGroupCellRendererDetails(i);case"FullWidthLoading":return this.beans.userComponentFactory.getFullWidthLoadingCellRendererDetails(i);default:return this.beans.userComponentFactory.getFullWidthCellRendererDetails(i)}}refreshRowTooltip(e,t){if(!this.fullWidthGui)return;const i={getGui:()=>this.fullWidthGui.element,getTooltipValue:()=>e,getLocation:()=>"fullWidthRow",shouldDisplayTooltip:t};this.tooltipFeature&&this.destroyBean(this.tooltipFeature,this.beans.context),this.tooltipFeature=this.createBean(new vn(i,this.beans))}addFullWidthRowDragging(e,t,i="",r){if(!this.isFullWidth())return;const n=new Hs(()=>i,this.rowNode,void 0,e,t,r);this.createBean(n,this.beans.context),this.addDestroyFunc(()=>{this.destroyBean(n,this.beans.context)})}onUiLevelChanged(){const e=this.beans.rowCssClassCalculator.calculateRowLevel(this.rowNode);if(this.rowLevel!=e){const t="ag-row-level-"+e,i="ag-row-level-"+this.rowLevel;this.allRowGuis.forEach(e=>{e.rowComp.addOrRemoveCssClass(t,!0),e.rowComp.addOrRemoveCssClass(i,!1)})}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.paginationProxy.getPageFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.paginationProxy.getPageLastRow()}refreshFirstAndLastRowStyles(){const e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();this.firstRowOnPage!==e&&(this.firstRowOnPage=e,this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-first",e))),this.lastRowOnPage!==t&&(this.lastRowOnPage=t,this.allRowGuis.forEach(e=>e.rowComp.addOrRemoveCssClass("ag-row-last",t)))}stopEditing(e=!1){if(this.stoppingRowEdit)return;const t=this.getAllCellCtrls(),i=this.editingRow;this.stoppingRowEdit=!0;let r=!1;for(const n of t){const t=n.stopEditing(e);i&&!e&&!r&&t&&(r=!0)}if(r){const e=this.createRowEvent(ct.EVENT_ROW_VALUE_CHANGED);this.beans.eventService.dispatchEvent(e)}i&&this.setEditingRow(!1),this.stoppingRowEdit=!1}setInlineEditingCss(e){this.allRowGuis.forEach(t=>{t.rowComp.addOrRemoveCssClass("ag-row-inline-editing",e),t.rowComp.addOrRemoveCssClass("ag-row-not-inline-editing",!e)})}setEditingRow(e){this.editingRow=e,this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-editing",e));const t=e?this.createRowEvent(ct.EVENT_ROW_EDITING_STARTED):this.createRowEvent(ct.EVENT_ROW_EDITING_STOPPED);this.beans.eventService.dispatchEvent(t)}startRowEditing(e=null,t=null,i=null){this.editingRow||this.getAllCellCtrls().reduce((r,n)=>{const s=n===t;return s?n.startEditing(e,s,i):n.startEditing(null,s,i),!!r||n.isEditing()},!1)&&this.setEditingRow(!0)}getAllCellCtrls(){return 0===this.leftCellCtrls.list.length&&0===this.rightCellCtrls.list.length?this.centerCellCtrls.list:[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){const e=this.beans.rowCssClassCalculator.processClassesFromGridOptions(this.rowNode);e&&e.length&&e.forEach(e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!0))})}postProcessRowClassRules(){this.beans.rowCssClassCalculator.processRowClassRules(this.rowNode,e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!0))},e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!1))})}setStylesFromGridOptions(e,t){e&&(this.rowStyles=this.processStylesFromGridOptions()),this.forEachGui(t,e=>e.rowComp.setUserStyles(this.rowStyles))}getPinnedForContainer(e){return"left"===e?"left":"right"===e?"right":null}getInitialRowClasses(e){const t=this.getPinnedForContainer(e),i={rowNode:this.rowNode,rowFocused:this.rowFocused,fadeRowIn:this.fadeInAnimation[e],rowIsEven:this.rowNode.rowIndex%2==0,rowLevel:this.rowLevel,fullWidthRow:this.isFullWidth(),firstRowOnPage:this.isFirstRowOnPage(),lastRowOnPage:this.isLastRowOnPage(),printLayout:this.printLayout,expandable:this.rowNode.isExpandable(),pinned:t};return this.beans.rowCssClassCalculator.getInitialRowClasses(i)}processStylesFromGridOptions(){const e=this.gos.get("rowStyle");if(e&&"function"==typeof e)return void console.warn("AG Grid: rowStyle should be an object of key/value styles, not be a function, use getRowStyle() instead");const t=this.gos.getCallback("getRowStyle");let i;return t&&(i=t({data:this.rowNode.data,node:this.rowNode,rowIndex:this.rowNode.rowIndex})),i||e?Object.assign({},e,i):this.emptyStyle}onRowSelected(e){const t=!!this.rowNode.isSelected();this.forEachGui(e,e=>{e.rowComp.addOrRemoveCssClass("ag-row-selected",t),gi(e.element,t),!e.element.contains(this.beans.gos.getActiveDomElement())||e!==this.centerGui&&e!==this.fullWidthGui||this.announceDescription()})}announceDescription(){if(this.isRowSelectionBlocked())return;const e=this.rowNode.isSelected();if(e&&this.beans.gos.get("suppressRowDeselection"))return;const t=this.beans.localeService.getLocaleTextFunc()(e?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${e?"deselect":"select"} this row.`);this.beans.ariaAnnouncementService.announceValue(t)}addHoverFunctionality(e){this.active&&(this.addManagedListener(e,"mouseenter",()=>this.rowNode.onMouseEnter()),this.addManagedListener(e,"mouseleave",()=>this.rowNode.onMouseLeave()),this.addManagedListener(this.rowNode,Ns.EVENT_MOUSE_ENTER,()=>{this.beans.dragService.isDragging()||this.gos.get("suppressRowHoverHighlight")||(e.classList.add("ag-row-hover"),this.rowNode.setHovered(!0))}),this.addManagedListener(this.rowNode,Ns.EVENT_MOUSE_LEAVE,()=>{e.classList.remove("ag-row-hover"),this.rowNode.setHovered(!1)}))}roundRowTopToBounds(e){const t=this.beans.ctrlsService.getGridBodyCtrl().getScrollFeature().getApproximateVScollPosition(),i=this.applyPaginationOffset(t.top,!0)-100,r=this.applyPaginationOffset(t.bottom,!0)+100;return Math.min(Math.max(i,e),r)}getFrameworkOverrides(){return this.beans.frameworkOverrides}forEachGui(e,t){e?t(e):this.allRowGuis.forEach(t)}onRowHeightChanged(e){if(null==this.rowNode.rowHeight)return;const t=this.rowNode.rowHeight,i=this.beans.environment.getDefaultRowHeight(),r=this.gos.isGetRowHeightFunction()?this.gos.getRowHeightForNode(this.rowNode).height:void 0,n=r?Math.min(i,r)-2+"px":void 0;this.forEachGui(e,e=>{e.element.style.height=`${t}px`,n&&e.element.style.setProperty("--ag-line-height",n)})}addEventListener(e,t){super.addEventListener(e,t)}removeEventListener(e,t){super.removeEventListener(e,t)}destroyFirstPass(e=!1){if(this.active=!1,!e&&this.gos.isAnimateRows()&&!this.isSticky())if(null!=this.rowNode.rowTop){const e=this.roundRowTopToBounds(this.rowNode.rowTop);this.setRowTop(e)}else this.allRowGuis.forEach(e=>e.rowComp.addOrRemoveCssClass("ag-opacity-zero",!0));this.rowNode.setHovered(!1);const t=this.createRowEvent(ct.EVENT_VIRTUAL_ROW_REMOVED);this.dispatchEvent(t),this.beans.eventService.dispatchEvent(t),super.destroy()}destroySecondPass(){this.allRowGuis.length=0,this.stopEditing();const e=e=>(e.list.forEach(e=>e.destroy()),{list:[],map:{}});this.centerCellCtrls=e(this.centerCellCtrls),this.leftCellCtrls=e(this.leftCellCtrls),this.rightCellCtrls=e(this.rightCellCtrls)}setFocusedClasses(e){this.forEachGui(e,e=>{e.rowComp.addOrRemoveCssClass("ag-row-focus",this.rowFocused),e.rowComp.addOrRemoveCssClass("ag-row-no-focus",!this.rowFocused)})}onCellFocusChanged(){const e=this.beans.focusService.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);e!==this.rowFocused&&(this.rowFocused=e,this.setFocusedClasses()),!e&&this.editingRow&&this.stopEditing(!1)}onPaginationChanged(){const e=this.beans.paginationProxy.getCurrentPage();this.paginationPage!==e&&(this.paginationPage=e,this.onTopChanged()),this.refreshFirstAndLastRowStyles()}onTopChanged(){this.setRowTop(this.rowNode.rowTop)}onPaginationPixelOffsetChanged(){this.onTopChanged()}applyPaginationOffset(e,t=!1){return this.rowNode.isRowPinned()||this.rowNode.sticky?e:e+this.beans.paginationProxy.getPixelOffset()*(t?1:-1)}setRowTop(e){if(!this.printLayout&&y(e)){const t=this.applyPaginationOffset(e),i=`${this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeightService.getRealPixelPosition(t)}px`;this.setRowTopStyle(i)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){if(this.printLayout)return"";let t;if(this.isSticky())t=this.rowNode.stickyRowTop;else{const i=this.slideInAnimation[e]?this.roundRowTopToBounds(this.rowNode.oldRowTop):this.rowNode.rowTop,r=this.applyPaginationOffset(i);t=this.rowNode.isRowPinned()?r:this.beans.rowContainerHeightService.getRealPixelPosition(r)}return t+"px"}setRowTopStyle(e){this.allRowGuis.forEach(t=>this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`))}getRowNode(){return this.rowNode}getCellCtrl(e){let t=null;return this.getAllCellCtrls().forEach(i=>{i.getColumn()==e&&(t=i)}),null!=t||this.getAllCellCtrls().forEach(i=>{i.getColSpanningList().indexOf(e)>=0&&(t=i)}),t}onRowIndexChanged(){null!=this.rowNode.rowIndex&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}getRowIndex(){return this.rowNode.getRowIndexString()}updateRowIndexes(e){const t=this.rowNode.getRowIndexString(),i=this.beans.headerNavigationService.getHeaderRowCount()+this.beans.filterManager.getHeaderRowCount(),r=this.rowNode.rowIndex%2==0,n=i+this.rowNode.rowIndex+1;this.forEachGui(e,e=>{e.rowComp.setRowIndex(t),e.rowComp.addOrRemoveCssClass("ag-row-even",r),e.rowComp.addOrRemoveCssClass("ag-row-odd",!r),li(e.element,n)})}};va.DOM_DATA_KEY_ROW_CTRL="renderedRow";var Ca=va,ya=class extends nt{constructor(e){super(),this.element=e}postConstruct(){this.addKeyboardListeners(),this.addMouseListeners(),this.mockContextMenuForIPad()}addKeyboardListeners(){const e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedListener(this.element,e,t)}addMouseListeners(){["dblclick","contextmenu","mouseover","mouseout","click",Xe("touchstart")?"touchstart":"mousedown"].forEach(e=>{const t=this.processMouseEvent.bind(this,e);this.addManagedListener(this.element,e,t)})}processMouseEvent(e,t){if(!this.mouseEventService.isEventFromThisGrid(t)||Qe(t))return;const i=this.getRowForEvent(t),r=this.mouseEventService.getRenderedCellForEvent(t);"contextmenu"===e?this.handleContextMenuMouseEvent(t,void 0,i,r):(r&&r.onMouseEvent(e,t),i&&i.onMouseEvent(e,t))}mockContextMenuForIPad(){if(!Ii())return;const e=new vs(this.element);this.addManagedListener(e,vs.EVENT_LONG_TAP,e=>{const t=this.getRowForEvent(e.touchEvent),i=this.mouseEventService.getRenderedCellForEvent(e.touchEvent);this.handleContextMenuMouseEvent(void 0,e.touchEvent,t,i)}),this.addDestroyFunc(()=>e.destroy())}getRowForEvent(e){let t=e.target;for(;t;){const e=this.gos.getDomData(t,Ca.DOM_DATA_KEY_ROW_CTRL);if(e)return e;t=t.parentElement}return null}handleContextMenuMouseEvent(e,t,i,r){const n=i?i.getRowNode():null,s=r?r.getColumn():null;let o=null;if(s){const i=e||t;r.dispatchCellContextMenuEvent(null!=i?i:null),o=this.valueService.getValue(s,n)}const a=this.ctrlsService.getGridBodyCtrl(),l=r?r.getGui():a.getGridBodyElement();this.menuService.showContextMenu({mouseEvent:e,touchEvent:t,rowNode:n,column:s,value:o,anchorToElement:l})}getControlsForEventTarget(e){return{cellCtrl:Ze(this.gos,e,fa.DOM_DATA_KEY_CELL_CTRL),rowCtrl:Ze(this.gos,e,Ca.DOM_DATA_KEY_ROW_CTRL)}}processKeyboardEvent(e,t){const{cellCtrl:i,rowCtrl:r}=this.getControlsForEventTarget(t.target);t.defaultPrevented||(i?this.processCellKeyboardEvent(i,e,t):r&&r.isFullWidth()&&this.processFullWidthRowKeyboardEvent(r,e,t))}processCellKeyboardEvent(e,t,i){const r=e.getRowNode(),n=e.getColumn(),s=e.isEditing();if(Zr(this.gos,i,r,n,s)||"keydown"!==t||(!s&&this.navigationService.handlePageScrollingKey(i)||e.onKeyDown(i),this.doGridOperations(i,e.isEditing()),Xr(i)&&e.processCharacter(i)),"keydown"===t){const t=e.createEvent(i,ct.EVENT_CELL_KEY_DOWN);this.eventService.dispatchEvent(t)}}processFullWidthRowKeyboardEvent(e,t,i){const r=e.getRowNode(),n=this.focusService.getFocusedCell(),s=n&&n.column;if(!Zr(this.gos,i,r,s,!1)){const r=i.key;if("keydown"===t)switch(r){case Qr.PAGE_HOME:case Qr.PAGE_END:case Qr.PAGE_UP:case Qr.PAGE_DOWN:this.navigationService.handlePageScrollingKey(i,!0);break;case Qr.UP:case Qr.DOWN:e.onKeyboardNavigate(i);break;case Qr.TAB:e.onTabKeyDown(i)}}if("keydown"===t){const t=e.createRowEvent(ct.EVENT_CELL_KEY_DOWN,i);this.eventService.dispatchEvent(t)}}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey)return;if(t)return;if(!this.mouseEventService.isEventFromThisGrid(e))return;const i=en(e);return i===Qr.A?this.onCtrlAndA(e):i===Qr.C?this.onCtrlAndC(e):i===Qr.D?this.onCtrlAndD(e):i===Qr.V?this.onCtrlAndV(e):i===Qr.X?this.onCtrlAndX(e):i===Qr.Y?this.onCtrlAndY():i===Qr.Z?this.onCtrlAndZ(e):void 0}onCtrlAndA(e){const{pinnedRowModel:t,paginationProxy:i,rangeService:r}=this;if(r&&i.isRowsToRender()){const[e,i]=[t.isEmpty("top"),t.isEmpty("bottom")],n=e?null:"top";let s,o;i?(s=null,o=this.paginationProxy.getRowCount()-1):(s="bottom",o=t.getPinnedBottomRowData().length-1);const a=this.columnModel.getAllDisplayedColumns();if(S(a))return;r.setCellRange({rowStartIndex:0,rowStartPinned:n,rowEndIndex:o,rowEndPinned:s,columnStart:a[0],columnEnd:Pe(a)})}e.preventDefault()}onCtrlAndC(e){if(!this.clipboardService||this.gos.get("enableCellTextSelection"))return;const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||(e.preventDefault(),this.clipboardService.copyToClipboard())}onCtrlAndX(e){if(!this.clipboardService||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||(e.preventDefault(),this.clipboardService.cutToClipboard(void 0,"ui"))}onCtrlAndV(e){const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||this.clipboardService&&!this.gos.get("suppressClipboardPaste")&&this.clipboardService.pasteFromClipboard()}onCtrlAndD(e){this.clipboardService&&!this.gos.get("suppressClipboardPaste")&&this.clipboardService.copyRangeDown(),e.preventDefault()}onCtrlAndZ(e){this.gos.get("undoRedoCellEditing")&&(e.preventDefault(),e.shiftKey?this.undoRedoService.redo("ui"):this.undoRedoService.undo("ui"))}onCtrlAndY(){this.undoRedoService.redo("ui")}};g([he("mouseEventService")],ya.prototype,"mouseEventService",2),g([he("valueService")],ya.prototype,"valueService",2),g([he("menuService")],ya.prototype,"menuService",2),g([he("ctrlsService")],ya.prototype,"ctrlsService",2),g([he("navigationService")],ya.prototype,"navigationService",2),g([he("focusService")],ya.prototype,"focusService",2),g([he("undoRedoService")],ya.prototype,"undoRedoService",2),g([he("columnModel")],ya.prototype,"columnModel",2),g([he("paginationProxy")],ya.prototype,"paginationProxy",2),g([he("pinnedRowModel")],ya.prototype,"pinnedRowModel",2),g([de("rangeService")],ya.prototype,"rangeService",2),g([de("clipboardService")],ya.prototype,"clipboardService",2),g([le],ya.prototype,"postConstruct",1);var wa=class extends nt{constructor(e){super(),this.centerContainerCtrl=e}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.listenForResize()}),this.addManagedListener(this.eventService,ct.EVENT_SCROLLBAR_WIDTH_CHANGED,this.onScrollbarWidthChanged.bind(this)),this.addManagedPropertyListeners(["alwaysShowHorizontalScroll","alwaysShowVerticalScroll"],()=>{this.checkViewportAndScrolls()})}listenForResize(){const e=()=>this.onCenterViewportResized();this.centerContainerCtrl.registerViewportResizeListener(e),this.gridBodyCtrl.registerBodyViewportResizeListener(e)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.centerContainerCtrl.isViewportInTheDOMTree()){this.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();const e=this.centerContainerCtrl.getCenterWidth();e!==this.centerWidth&&(this.centerWidth=e,this.columnModel.refreshFlexedColumns({viewportWidth:this.centerWidth,updateBodyWidths:!0,fireResizedEvent:!0}))}else this.bodyHeight=0}keepPinnedColumnsNarrowerThanViewport(){const e=dr(this.gridBodyCtrl.getBodyViewportElement());if(e<=50)return;let t=this.getPinnedColumnsOverflowingViewport(e-50);const i=this.gos.getCallback("processUnpinnedColumns");t.length&&(i&&(t=i({columns:t,viewportWidth:e})),this.columnModel.setColumnsPinned(t,null,"viewportSizeFeature"))}getPinnedColumnsOverflowingViewport(e){const t=this.pinnedWidthService.getPinnedRightWidth()+this.pinnedWidthService.getPinnedLeftWidth();if(t<e)return[];const i=[...this.columnModel.getDisplayedLeftColumns()],r=[...this.columnModel.getDisplayedRightColumns()];let n=0,s=0;const o=[];let a=t-0-e;for(;(s<i.length||n<r.length)&&a>0;){if(n<r.length){const e=r[n++];a-=e.getActualWidth(),o.push(e)}if(s<i.length&&a>0){const e=i[s++];a-=e.getActualWidth(),o.push(e)}}return o}checkViewportAndScrolls(){this.updateScrollVisibleService(),this.checkBodyHeight(),this.onHorizontalViewportChanged(),this.gridBodyCtrl.getScrollFeature().checkScrollLeft()}getBodyHeight(){return this.bodyHeight}checkBodyHeight(){const e=hr(this.gridBodyCtrl.getBodyViewportElement());if(this.bodyHeight!==e){this.bodyHeight=e;const t={type:ct.EVENT_BODY_HEIGHT_CHANGED};this.eventService.dispatchEvent(t)}}updateScrollVisibleService(){this.updateScrollVisibleServiceImpl(),setTimeout(this.updateScrollVisibleServiceImpl.bind(this),500)}updateScrollVisibleServiceImpl(){const e={horizontalScrollShowing:this.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleService.setScrollsVisible(e)}isHorizontalScrollShowing(){return this.centerContainerCtrl.isHorizontalScrollShowing()}onHorizontalViewportChanged(){const e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.columnModel.setViewportPosition(e,t)}};g([he("ctrlsService")],wa.prototype,"ctrlsService",2),g([he("pinnedWidthService")],wa.prototype,"pinnedWidthService",2),g([he("columnModel")],wa.prototype,"columnModel",2),g([he("scrollVisibleService")],wa.prototype,"scrollVisibleService",2),g([le],wa.prototype,"postConstruct",1);var Sa=class extends nt{constructor(e){super(),this.element=e}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_LEFT_PINNED_WIDTH_CHANGED,this.onPinnedLeftWidthChanged.bind(this))}onPinnedLeftWidthChanged(){const e=this.pinnedWidthService.getPinnedLeftWidth(),t=e>0;or(this.element,t),Dr(this.element,e)}getWidth(){return this.pinnedWidthService.getPinnedLeftWidth()}};g([he("pinnedWidthService")],Sa.prototype,"pinnedWidthService",2),g([le],Sa.prototype,"postConstruct",1);var ba=class extends nt{constructor(e){super(),this.element=e}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED,this.onPinnedRightWidthChanged.bind(this))}onPinnedRightWidthChanged(){const e=this.pinnedWidthService.getPinnedRightWidth(),t=e>0;or(this.element,t),Dr(this.element,e)}getWidth(){return this.pinnedWidthService.getPinnedRightWidth()}};g([he("pinnedWidthService")],ba.prototype,"pinnedWidthService",2),g([le],ba.prototype,"postConstruct",1);var Ea=class extends nt{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,this.onHeightChanged.bind(this))}onHeightChanged(){const e=this.maxDivHeightScaler.getUiContainerHeight(),t=null!=e?`${e}px`:"";this.eContainer.style.height=t,this.eViewport&&(this.eViewport.style.height=t)}};g([he("rowContainerHeightService")],Ea.prototype,"maxDivHeightScaler",2),g([le],Ea.prototype,"postConstruct",1);var Aa=class extends nt{constructor(e){super(),this.eContainer=e}postConstruct(){this.rangeService&&(this.params={eElement:this.eContainer,onDragStart:this.rangeService.onDragStart.bind(this.rangeService),onDragStop:this.rangeService.onDragStop.bind(this.rangeService),onDragging:this.rangeService.onDragging.bind(this.rangeService)},this.addManagedPropertyListener("enableRangeSelection",e=>{e.currentValue?this.enableFeature():this.disableFeature()}),this.addDestroyFunc(()=>this.disableFeature()),this.gos.get("enableRangeSelection")&&this.enableFeature())}enableFeature(){this.dragService.addDragSource(this.params)}disableFeature(){this.dragService.removeDragSource(this.params)}};g([he("dragService")],Aa.prototype,"dragService",2),g([de("rangeService")],Aa.prototype,"rangeService",2),g([le],Aa.prototype,"postConstruct",1);var Ta=class extends nt{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){const e=this.setWidth.bind(this);this.addManagedPropertyListener("domLayout",e),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_LEFT_PINNED_WIDTH_CHANGED,e),this.addSpacer&&(this.addManagedListener(this.eventService,ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_SCROLL_VISIBILITY_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_SCROLLBAR_WIDTH_CHANGED,e)),this.setWidth()}setWidth(){const{columnModel:e}=this,t=this.gos.isDomLayout("print"),i=e.getBodyContainerWidth(),r=e.getDisplayedColumnsLeftWidth(),n=e.getDisplayedColumnsRightWidth();let s;t?s=i+r+n:(s=i,this.addSpacer&&0===(this.gos.get("enableRtl")?r:n)&&this.scrollVisibleService.isVerticalScrollShowing()&&(s+=this.gos.getScrollbarWidth())),this.callback(s)}};g([he("columnModel")],Ta.prototype,"columnModel",2),g([he("scrollVisibleService")],Ta.prototype,"scrollVisibleService",2),g([le],Ta.prototype,"postConstruct",1);var Ma=(e=>(e.LEFT="left",e.RIGHT="right",e.CENTER="center",e.FULL_WIDTH="fullWidth",e.TOP_LEFT="topLeft",e.TOP_RIGHT="topRight",e.TOP_CENTER="topCenter",e.TOP_FULL_WIDTH="topFullWidth",e.STICKY_TOP_LEFT="stickyTopLeft",e.STICKY_TOP_RIGHT="stickyTopRight",e.STICKY_TOP_CENTER="stickyTopCenter",e.STICKY_TOP_FULL_WIDTH="stickyTopFullWidth",e.STICKY_BOTTOM_LEFT="stickyBottomLeft",e.STICKY_BOTTOM_RIGHT="stickyBottomRight",e.STICKY_BOTTOM_CENTER="stickyBottomCenter",e.STICKY_BOTTOM_FULL_WIDTH="stickyBottomFullWidth",e.BOTTOM_LEFT="bottomLeft",e.BOTTOM_RIGHT="bottomRight",e.BOTTOM_CENTER="bottomCenter",e.BOTTOM_FULL_WIDTH="bottomFullWidth",e))(Ma||{}),Ra=(e=>(e.LEFT="left",e.RIGHT="right",e.CENTER="center",e.FULL_WIDTH="fullWidth",e))(Ra||{});function _a(e){switch(e){case"center":case"topCenter":case"stickyTopCenter":case"bottomCenter":case"stickyBottomCenter":return"center";case"left":case"topLeft":case"stickyTopLeft":case"bottomLeft":case"stickyBottomLeft":return"left";case"right":case"topRight":case"stickyTopRight":case"bottomRight":case"stickyBottomRight":return"right";case"fullWidth":case"topFullWidth":case"stickyTopFullWidth":case"bottomFullWidth":case"stickyBottomFullWidth":return"fullWidth";default:throw Error("Invalid Row Container Type")}}var Pa=Et([["center","ag-center-cols-container"],["left","ag-pinned-left-cols-container"],["right","ag-pinned-right-cols-container"],["fullWidth","ag-full-width-container"],["topCenter","ag-floating-top-container"],["topLeft","ag-pinned-left-floating-top"],["topRight","ag-pinned-right-floating-top"],["topFullWidth","ag-floating-top-full-width-container"],["stickyTopCenter","ag-sticky-top-container"],["stickyTopLeft","ag-pinned-left-sticky-top"],["stickyTopRight","ag-pinned-right-sticky-top"],["stickyTopFullWidth","ag-sticky-top-full-width-container"],["stickyBottomCenter","ag-sticky-bottom-container"],["stickyBottomLeft","ag-pinned-left-sticky-bottom"],["stickyBottomRight","ag-pinned-right-sticky-bottom"],["stickyBottomFullWidth","ag-sticky-bottom-full-width-container"],["bottomCenter","ag-floating-bottom-container"],["bottomLeft","ag-pinned-left-floating-bottom"],["bottomRight","ag-pinned-right-floating-bottom"],["bottomFullWidth","ag-floating-bottom-full-width-container"]]),xa=Et([["center","ag-center-cols-viewport"],["topCenter","ag-floating-top-viewport"],["stickyTopCenter","ag-sticky-top-viewport"],["bottomCenter","ag-floating-bottom-viewport"],["stickyBottomCenter","ag-sticky-bottom-viewport"]]),Da=class e extends nt{constructor(e){super(),this.visible=!0,this.EMPTY_CTRLS=[],this.name=e,this.isFullWithContainer="topFullWidth"===this.name||"stickyTopFullWidth"===this.name||"stickyBottomFullWidth"===this.name||"bottomFullWidth"===this.name||"fullWidth"===this.name}static getRowContainerCssClasses(e){return{container:Pa.get(e),viewport:xa.get(e)}}static getPinned(e){switch(e){case"bottomLeft":case"topLeft":case"stickyTopLeft":case"stickyBottomLeft":case"left":return"left";case"bottomRight":case"topRight":case"stickyTopRight":case"stickyBottomRight":case"right":return"right";default:return null}}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>this.viewportSizeFeature=this.createManagedBean(new wa(this)))}registerWithCtrlsService(){switch(this.name){case"fullWidth":case"topFullWidth":case"stickyTopFullWidth":case"bottomFullWidth":case"stickyBottomFullWidth":return;default:this.ctrlsService.register(this.name,this)}}forContainers(e,t){e.indexOf(this.name)>=0&&t()}getContainerElement(){return this.eContainer}getViewportSizeFeature(){return this.viewportSizeFeature}setComp(e,t,i){this.comp=e,this.eContainer=t,this.eViewport=i,this.createManagedBean(new ya(this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder(),this.stopHScrollOnPinnedRows();this.forContainers(["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],()=>{this.pinnedWidthFeature=this.createManagedBean(new Sa(this.eContainer)),this.addManagedListener(this.eventService,ct.EVENT_LEFT_PINNED_WIDTH_CHANGED,()=>this.onPinnedWidthChanged())}),this.forContainers(["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],()=>{this.pinnedWidthFeature=this.createManagedBean(new ba(this.eContainer)),this.addManagedListener(this.eventService,ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED,()=>this.onPinnedWidthChanged())}),this.forContainers(["center","left","right","fullWidth"],()=>this.createManagedBean(new Ea(this.eContainer,"center"===this.name?i:void 0))),this.forContainers(["topCenter","topLeft","topRight","bottomCenter","bottomLeft","bottomRight","center","left","right","stickyTopCenter","stickyTopLeft","stickyTopRight","stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],()=>this.createManagedBean(new Aa(this.eContainer))),this.forContainers(["center","topCenter","stickyTopCenter","bottomCenter","stickyBottomCenter"],()=>this.createManagedBean(new Ta(e=>this.comp.setContainerWidth(`${e}px`)))),this.addListeners(),this.registerWithCtrlsService()}addListeners(){this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,()=>this.onDisplayedColumnsChanged()),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,()=>this.onDisplayedColumnsWidthChanged()),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_ROWS_CHANGED,e=>this.onDisplayedRowsChanged(e.afterScroll)),this.onDisplayedColumnsChanged(),this.onDisplayedColumnsWidthChanged(),this.onDisplayedRowsChanged()}listenOnDomOrder(){if(["stickyTopCenter","stickyTopLeft","stickyTopRight","stickyTopFullWidth","stickyBottomCenter","stickyBottomLeft","stickyBottomRight","stickyBottomFullWidth"].indexOf(this.name)>=0)return void this.comp.setDomOrder(!0);const e=()=>{const e=this.gos.get("ensureDomOrder"),t=this.gos.isDomLayout("print");this.comp.setDomOrder(e||t)};this.addManagedPropertyListener("domLayout",e),e()}stopHScrollOnPinnedRows(){this.forContainers(["topCenter","stickyTopCenter","bottomCenter","stickyBottomCenter"],()=>{this.addManagedListener(this.eViewport,"scroll",()=>this.eViewport.scrollLeft=0)})}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}onDisplayedColumnsWidthChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){const e=e=>{this.dragService.isDragging()&&e.cancelable&&e.preventDefault()};this.eContainer.addEventListener("touchmove",e,{passive:!1}),this.addDestroyFunc(()=>this.eContainer.removeEventListener("touchmove",e))}onHorizontalViewportChanged(e=!1){const t=this.getCenterWidth(),i=this.getCenterViewportScrollLeft();this.columnModel.setViewportPosition(t,i,e)}getCenterWidth(){return dr(this.eViewport)}getCenterViewportScrollLeft(){return vr(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){const t=this.resizeObserverService.observeResize(this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return Sr(this.eViewport)}getViewportScrollLeft(){return vr(this.eViewport,this.enableRtl)}isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||_r(this.eViewport)}getViewportElement(){return this.eViewport}setContainerTranslateX(e){this.eContainer.style.transform=`translateX(${e}px)`}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){Cr(this.eViewport,e,this.enableRtl)}isContainerVisible(){return!e.getPinned(this.name)||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){const e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){const t=this.getRowCtrls();if(!this.visible||0===t.length)return void this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});const i=this.gos.isDomLayout("print"),r=this.gos.get("embedFullWidthRows")||i,n=t.filter(e=>{const t=e.isFullWidth();return this.isFullWithContainer?!r&&t:r||!t});this.comp.setRowCtrls({rowCtrls:n,useFlushSync:e})}getRowCtrls(){switch(this.name){case"topCenter":case"topLeft":case"topRight":case"topFullWidth":return this.rowRenderer.getTopRowCtrls();case"stickyTopCenter":case"stickyTopLeft":case"stickyTopRight":case"stickyTopFullWidth":return this.rowRenderer.getStickyTopRowCtrls();case"stickyBottomCenter":case"stickyBottomLeft":case"stickyBottomRight":case"stickyBottomFullWidth":return this.rowRenderer.getStickyBottomRowCtrls();case"bottomCenter":case"bottomLeft":case"bottomRight":case"bottomFullWidth":return this.rowRenderer.getBottomRowCtrls();default:return this.rowRenderer.getCentreRowCtrls()}}};g([he("dragService")],Da.prototype,"dragService",2),g([he("ctrlsService")],Da.prototype,"ctrlsService",2),g([he("columnModel")],Da.prototype,"columnModel",2),g([he("resizeObserverService")],Da.prototype,"resizeObserverService",2),g([he("rowRenderer")],Da.prototype,"rowRenderer",2),g([le],Da.prototype,"postConstruct",1);var Ia=Da,La=class extends wn{constructor(){super('<div class="ag-root ag-unselectable" role="treegrid">\n        <ag-header-root ref="gridHeader"></ag-header-root>\n        <div class="ag-floating-top" ref="eTop" role="presentation">\n            <ag-row-container ref="topLeftContainer" name="topLeft"></ag-row-container>\n            <ag-row-container ref="topCenterContainer" name="topCenter"></ag-row-container>\n            <ag-row-container ref="topRightContainer" name="topRight"></ag-row-container>\n            <ag-row-container ref="topFullWidthContainer" name="topFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-body" ref="eBody" role="presentation">\n            <div class="ag-body-viewport" ref="eBodyViewport" role="presentation">\n                <ag-row-container ref="leftContainer" name="left"></ag-row-container>\n                <ag-row-container ref="centerContainer" name="center"></ag-row-container>\n                <ag-row-container ref="rightContainer" name="right"></ag-row-container>\n                <ag-row-container ref="fullWidthContainer" name="fullWidth"></ag-row-container>\n            </div>\n            <ag-fake-vertical-scroll></ag-fake-vertical-scroll>\n        </div>\n        <div class="ag-sticky-top" ref="eStickyTop" role="presentation">\n            <ag-row-container ref="stickyTopLeftContainer" name="stickyTopLeft"></ag-row-container>\n            <ag-row-container ref="stickyTopCenterContainer" name="stickyTopCenter"></ag-row-container>\n            <ag-row-container ref="stickyTopRightContainer" name="stickyTopRight"></ag-row-container>\n            <ag-row-container ref="stickyTopFullWidthContainer" name="stickyTopFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-sticky-bottom" ref="eStickyBottom" role="presentation">\n            <ag-row-container ref="stickyBottomLeftContainer" name="stickyBottomLeft"></ag-row-container>\n            <ag-row-container ref="stickyBottomCenterContainer" name="stickyBottomCenter"></ag-row-container>\n            <ag-row-container ref="stickyBottomRightContainer" name="stickyBottomRight"></ag-row-container>\n            <ag-row-container ref="stickyBottomFullWidthContainer" name="stickyBottomFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-floating-bottom" ref="eBottom" role="presentation">\n            <ag-row-container ref="bottomLeftContainer" name="bottomLeft"></ag-row-container>\n            <ag-row-container ref="bottomCenterContainer" name="bottomCenter"></ag-row-container>\n            <ag-row-container ref="bottomRightContainer" name="bottomRight"></ag-row-container>\n            <ag-row-container ref="bottomFullWidthContainer" name="bottomFullWidth"></ag-row-container>\n        </div>\n        <ag-fake-horizontal-scroll></ag-fake-horizontal-scroll>\n        <ag-overlay-wrapper></ag-overlay-wrapper>\n    </div>')}init(){const e=(e,t)=>{const i=`${e}px`;t.style.minHeight=i,t.style.height=i},t={setRowAnimationCssOnBodyViewport:(e,t)=>this.setRowAnimationCssOnBodyViewport(e,t),setColumnCount:e=>ci(this.getGui(),e),setRowCount:e=>ai(this.getGui(),e),setTopHeight:t=>e(t,this.eTop),setBottomHeight:t=>e(t,this.eBottom),setTopDisplay:e=>this.eTop.style.display=e,setBottomDisplay:e=>this.eBottom.style.display=e,setStickyTopHeight:e=>this.eStickyTop.style.height=e,setStickyTopTop:e=>this.eStickyTop.style.top=e,setStickyTopWidth:e=>this.eStickyTop.style.width=e,setStickyBottomHeight:e=>this.eStickyBottom.style.height=e,setStickyBottomBottom:e=>this.eStickyBottom.style.bottom=e,setStickyBottomWidth:e=>this.eStickyBottom.style.width=e,setColumnMovingCss:(e,t)=>this.addOrRemoveCssClass(e,t),updateLayoutClasses:(e,t)=>{[this.eBodyViewport.classList,this.eBody.classList].forEach(e=>{e.toggle("ag-layout-auto-height",t.autoHeight),e.toggle("ag-layout-normal",t.normal),e.toggle("ag-layout-print",t.print)}),this.addOrRemoveCssClass("ag-layout-auto-height",t.autoHeight),this.addOrRemoveCssClass("ag-layout-normal",t.normal),this.addOrRemoveCssClass("ag-layout-print",t.print)},setAlwaysVerticalScrollClass:(e,t)=>this.eBodyViewport.classList.toggle(ea,t),registerBodyViewportResizeListener:e=>{const t=this.resizeObserverService.observeResize(this.eBodyViewport,e);this.addDestroyFunc(()=>t())},setPinnedTopBottomOverflowY:e=>this.eTop.style.overflowY=this.eBottom.style.overflowY=e,setCellSelectableCss:(e,t)=>{[this.eTop,this.eBodyViewport,this.eBottom].forEach(i=>i.classList.toggle(e,t))},setBodyViewportWidth:e=>this.eBodyViewport.style.width=e};this.ctrl=this.createManagedBean(new ta),this.ctrl.setComp(t,this.getGui(),this.eBodyViewport,this.eTop,this.eBottom,this.eStickyTop,this.eStickyBottom),(this.rangeService&&this.gos.get("enableRangeSelection")||"multiple"===this.gos.get("rowSelection"))&&oi(this.getGui(),!0)}setRowAnimationCssOnBodyViewport(e,t){const i=this.eBodyViewport.classList;i.toggle("ag-row-animation",t),i.toggle("ag-row-no-animation",!t)}getFloatingTopBottom(){return[this.eTop,this.eBottom]}};g([he("resizeObserverService")],La.prototype,"resizeObserverService",2),g([de("rangeService")],La.prototype,"rangeService",2),g([bn("eBodyViewport")],La.prototype,"eBodyViewport",2),g([bn("eStickyTop")],La.prototype,"eStickyTop",2),g([bn("eStickyBottom")],La.prototype,"eStickyBottom",2),g([bn("eTop")],La.prototype,"eTop",2),g([bn("eBottom")],La.prototype,"eBottom",2),g([bn("gridHeader")],La.prototype,"headerRootComp",2),g([bn("eBody")],La.prototype,"eBody",2),g([le],La.prototype,"init",1);var Na=class extends nt{postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onDisplayedColumnsWidthChanged.bind(this))}onDisplayedColumnsChanged(){this.update()}onDisplayedColumnsWidthChanged(){this.update()}update(){this.columnAnimationService.isActive()?this.columnAnimationService.executeLaterVMTurn(()=>{this.columnAnimationService.executeLaterVMTurn(()=>this.updateImpl())}):this.updateImpl()}updateImpl(){const e=this.ctrlsService.get("center");if(!e||this.columnAnimationService.isActive())return;const t={horizontalScrollShowing:e.isHorizontalScrollShowing(),verticalScrollShowing:this.isVerticalScrollShowing()};this.setScrollsVisible(t)}setScrollsVisible(e){if(this.horizontalScrollShowing!==e.horizontalScrollShowing||this.verticalScrollShowing!==e.verticalScrollShowing){this.horizontalScrollShowing=e.horizontalScrollShowing,this.verticalScrollShowing=e.verticalScrollShowing;const t={type:ct.EVENT_SCROLL_VISIBILITY_CHANGED};this.eventService.dispatchEvent(t)}}isHorizontalScrollShowing(){return this.horizontalScrollShowing}isVerticalScrollShowing(){return this.verticalScrollShowing}};g([he("ctrlsService")],Na.prototype,"ctrlsService",2),g([he("columnAnimationService")],Na.prototype,"columnAnimationService",2),g([le],Na.prototype,"postConstruct",1),Na=g([ue("scrollVisibleService")],Na);var Oa=class extends nt{constructor(){super(...arguments),this.gridInstanceId=Oa.gridInstanceSequence.next()}stampTopLevelGridCompWithGridInstance(e){e[Oa.GRID_DOM_KEY]=this.gridInstanceId}getRenderedCellForEvent(e){return Ze(this.gos,e.target,fa.DOM_DATA_KEY_CELL_CTRL)}isEventFromThisGrid(e){return this.isElementInThisGrid(e.target)}isElementInThisGrid(e){let t=e;for(;t;){const e=t[Oa.GRID_DOM_KEY];if(y(e))return e===this.gridInstanceId;t=t.parentElement}return!1}getCellPositionForEvent(e){const t=this.getRenderedCellForEvent(e);return t?t.getCellPosition():null}getNormalisedPosition(e){const t=this.gos.isDomLayout("normal"),i=e;let r,n;if(null!=i.clientX||null!=i.clientY?(r=i.clientX,n=i.clientY):(r=i.x,n=i.y),t){const e=this.ctrlsService.getGridBodyCtrl(),t=e.getScrollFeature().getVScrollPosition();r+=e.getScrollFeature().getHScrollPosition().left,n+=t.top}return{x:r,y:n}}};Oa.gridInstanceSequence=new un,Oa.GRID_DOM_KEY="__ag_grid_instance",g([he("ctrlsService")],Oa.prototype,"ctrlsService",2),Oa=g([ue("mouseEventService")],Oa);var Fa=class extends nt{constructor(){super(),this.onPageDown=J(this.onPageDown,100),this.onPageUp=J(this.onPageUp,100)}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl})}handlePageScrollingKey(e,t=!1){const i=e.key,r=e.altKey,n=e.ctrlKey||e.metaKey,s=!!this.rangeService&&e.shiftKey,o=this.mouseEventService.getCellPositionForEvent(e);let a=!1;switch(i){case Qr.PAGE_HOME:case Qr.PAGE_END:n||r||(this.onHomeOrEndKey(i),a=!0);break;case Qr.LEFT:case Qr.RIGHT:case Qr.UP:case Qr.DOWN:if(!o)return!1;!n||r||s||(this.onCtrlUpDownLeftRight(i,o),a=!0);break;case Qr.PAGE_DOWN:case Qr.PAGE_UP:n||r||(a=this.handlePageUpDown(i,o,t))}return a&&e.preventDefault(),a}handlePageUpDown(e,t,i){return i&&(t=this.focusService.getFocusedCell()),!!t&&(e===Qr.PAGE_UP?this.onPageUp(t):this.onPageDown(t),!0)}navigateTo(e){var t;const{scrollIndex:i,scrollType:r,scrollColumn:n,focusIndex:s,focusColumn:o}=e;y(n)&&!n.isPinned()&&this.gridBodyCon.getScrollFeature().ensureColumnVisible(n),y(i)&&this.gridBodyCon.getScrollFeature().ensureIndexVisible(i,r),e.isAsync||this.gridBodyCon.getScrollFeature().ensureIndexVisible(s),this.focusService.setFocusedCell({rowIndex:s,column:o,rowPinned:null,forceBrowserFocus:!0}),null==(t=this.rangeService)||t.setRangeToCell({rowIndex:s,rowPinned:null,column:o})}onPageDown(e){const t=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition(),i=this.getViewportHeight(),r=this.paginationProxy.getPixelOffset(),n=t.top+i,s=this.paginationProxy.getRowIndexAtPixel(n+r);this.columnModel.isAutoRowHeightActive()?this.navigateToNextPageWithAutoHeight(e,s):this.navigateToNextPage(e,s)}onPageUp(e){const t=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition(),i=this.paginationProxy.getPixelOffset(),r=t.top,n=this.paginationProxy.getRowIndexAtPixel(r+i);this.columnModel.isAutoRowHeightActive()?this.navigateToNextPageWithAutoHeight(e,n,!0):this.navigateToNextPage(e,n,!0)}navigateToNextPage(e,t,i=!1){const r=this.getViewportHeight(),n=this.paginationProxy.getPageFirstRow(),s=this.paginationProxy.getPageLastRow(),o=this.paginationProxy.getPixelOffset(),a=this.paginationProxy.getRow(e.rowIndex),l=i?(null==a?void 0:a.rowHeight)-r-o:r-o,c=(null==a?void 0:a.rowTop)+l;let u,h=this.paginationProxy.getRowIndexAtPixel(c+o);if(h===e.rowIndex){const r=i?-1:1;t=h=e.rowIndex+r}i?(u="bottom",h<n&&(h=n),t<n&&(t=n)):(u="top",h>s&&(h=s),t>s&&(t=s)),this.isRowTallerThanView(h)&&(t=h,u="top"),this.navigateTo({scrollIndex:t,scrollType:u,scrollColumn:null,focusIndex:h,focusColumn:e.column})}navigateToNextPageWithAutoHeight(e,t,i=!1){this.navigateTo({scrollIndex:t,scrollType:i?"bottom":"top",scrollColumn:null,focusIndex:t,focusColumn:e.column}),setTimeout(()=>{const r=this.getNextFocusIndexForAutoHeight(e,i);this.navigateTo({scrollIndex:t,scrollType:i?"bottom":"top",scrollColumn:null,focusIndex:r,focusColumn:e.column,isAsync:!0})},50)}getNextFocusIndexForAutoHeight(e,t=!1){var i;const r=t?-1:1,n=this.getViewportHeight(),s=this.paginationProxy.getPageLastRow();let o=0,a=e.rowIndex;for(;a>=0&&a<=s;){const e=this.paginationProxy.getRow(a);if(e){const t=null!=(i=e.rowHeight)?i:0;if(o+t>n)break;o+=t}a+=r}return Math.max(0,Math.min(a,s))}getViewportHeight(){const{gridBodyCtrl:e,center:t}=this.ctrlsService.getParams(),i=e.getScrollFeature().getVScrollPosition(),r=this.gos.getScrollbarWidth();let n=i.bottom-i.top;return t.isHorizontalScrollShowing()&&(n-=r),n}isRowTallerThanView(e){const t=this.paginationProxy.getRow(e);if(!t)return!1;const i=t.rowHeight;return"number"==typeof i&&i>this.getViewportHeight()}onCtrlUpDownLeftRight(e,t){const i=this.cellNavigationService.getNextCellToFocus(e,t,!0),{rowIndex:r,column:n}=i;this.navigateTo({scrollIndex:r,scrollType:null,scrollColumn:n,focusIndex:r,focusColumn:n})}onHomeOrEndKey(e){const t=e===Qr.PAGE_HOME,i=this.columnModel.getAllDisplayedColumns(),r=t?i[0]:Pe(i),n=t?this.paginationProxy.getPageFirstRow():this.paginationProxy.getPageLastRow();this.navigateTo({scrollIndex:n,scrollType:null,scrollColumn:r,focusIndex:n,focusColumn:r})}onTabKeyDown(e,t){const i=t.shiftKey,r=this.tabToNextCellCommon(e,i,t);if(!1===r)if(i){const{rowIndex:i,rowPinned:r}=e.getRowPosition();(r?0===i:i===this.paginationProxy.getPageFirstRow())&&(0===this.gos.get("headerHeight")||this.gos.get("suppressHeaderFocus")?this.focusService.focusNextGridCoreContainer(!0,!0):(t.preventDefault(),this.focusService.focusPreviousFromFirstCell(t)))}else e instanceof fa&&e.focusCell(!0),this.focusService.focusNextGridCoreContainer(i)&&t.preventDefault();else r&&t.preventDefault()}tabToNextCell(e,t){const i=this.focusService.getFocusedCell();if(!i)return!1;let r=this.getCellByPosition(i);return!!(r||(r=this.rowRenderer.getRowByPosition(i),r&&r.isFullWidth()))&&!!this.tabToNextCellCommon(r,e,t)}tabToNextCellCommon(e,t,i){let r,n=e.isEditing();if(!n&&e instanceof fa){const t=e.getRowCtrl();t&&(n=t.isEditing())}return r=n?"fullRow"===this.gos.get("editType")?this.moveToNextEditingRow(e,t,i):this.moveToNextEditingCell(e,t,i):this.moveToNextCellNotEditing(e,t),null===r?r:r||!!this.focusService.getFocusedHeader()}moveToNextEditingCell(e,t,i=null){const r=e.getCellPosition();e.getGui().focus(),e.stopEditing();const n=this.findNextCellToFocusOn(r,t,!0);return!1===n?null:null!=n&&(n.startEditing(null,!0,i),n.focusCell(!1),!0)}moveToNextEditingRow(e,t,i=null){const r=e.getCellPosition(),n=this.findNextCellToFocusOn(r,t,!0);if(!1===n)return null;if(null==n)return!1;const s=n.getCellPosition(),o=this.isCellEditable(r),a=this.isCellEditable(s),l=s&&r.rowIndex===s.rowIndex&&r.rowPinned===s.rowPinned;return o&&e.setFocusOutOnEditor(),l||(e.getRowCtrl().stopEditing(),n.getRowCtrl().startRowEditing(void 0,void 0,i)),a?(n.setFocusInOnEditor(),n.focusCell()):n.focusCell(!0),!0}moveToNextCellNotEditing(e,t){const i=this.columnModel.getAllDisplayedColumns();let r;r=e instanceof Ca?d(h({},e.getRowPosition()),{column:t?i[0]:Pe(i)}):e.getCellPosition();const n=this.findNextCellToFocusOn(r,t,!1);if(!1===n)return null;if(n instanceof fa)n.focusCell(!0);else if(n)return this.tryToFocusFullWidthRow(n.getRowPosition(),t);return y(n)}findNextCellToFocusOn(e,t,i){var r;let n=e;for(;;){e!==n&&(e=n),t||(n=this.getLastCellOfColSpan(n)),n=this.cellNavigationService.getNextTabbedCell(n,t);const s=this.gos.getCallback("tabToNextCell");if(y(s)){const r=s({backwards:t,editing:i,previousCellPosition:e,nextCellPosition:n||null});if(!0===r||null===r)null===r&&U("Returning `null` from tabToNextCell is deprecated. Return `true` to stay on the current cell, or `false` to let the browser handle the tab behaviour."),n=e;else{if(!1===r)return!1;r.floating&&(U("tabToNextCellFunc return type should have attributes: rowIndex, rowPinned, column. However you had 'floating', maybe you meant 'rowPinned'?"),r.rowPinned=r.floating),n={rowIndex:r.rowIndex,column:r.column,rowPinned:r.rowPinned}}}if(!n)return null;if(n.rowIndex<0){const e=this.headerNavigationService.getHeaderRowCount();return this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:e+n.rowIndex,column:n.column},fromCell:!0}),null}const o="fullRow"===this.gos.get("editType");if(i&&!o&&!this.isCellEditable(n))continue;this.ensureCellVisible(n);const a=this.getCellByPosition(n);if(!a){const e=this.rowRenderer.getRowByPosition(n);if(!e||!e.isFullWidth()||i)continue;return e}if(!a.isSuppressNavigable())return null==(r=this.rangeService)||r.setRangeToCell(n),a}}isCellEditable(e){const t=this.lookupRowNodeForCell(e);return!!t&&e.column.isCellEditable(t)}getCellByPosition(e){const t=this.rowRenderer.getRowByPosition(e);return t?t.getCellCtrl(e.column):null}lookupRowNodeForCell(e){return"top"===e.rowPinned?this.pinnedRowModel.getPinnedTopRow(e.rowIndex):"bottom"===e.rowPinned?this.pinnedRowModel.getPinnedBottomRow(e.rowIndex):this.paginationProxy.getRow(e.rowIndex)}navigateToNextCell(e,t,i,r){let n=i,s=!1;for(;n&&(n===i||!this.isValidNavigateCell(n));)this.gos.get("enableRtl")?t===Qr.LEFT&&(n=this.getLastCellOfColSpan(n)):t===Qr.RIGHT&&(n=this.getLastCellOfColSpan(n)),n=this.cellNavigationService.getNextCellToFocus(t,n),s=w(n);if(s&&e&&e.key===Qr.UP&&(n={rowIndex:-1,rowPinned:null,column:i.column}),r){const r=this.gos.getCallback("navigateToNextCell");if(y(r)){const s=r({key:t,previousCellPosition:i,nextCellPosition:n||null,event:e});y(s)?(s.floating&&(U("tabToNextCellFunc return type should have attributes: rowIndex, rowPinned, column. However you had 'floating', maybe you meant 'rowPinned'?"),s.rowPinned=s.floating),n={rowPinned:s.rowPinned,rowIndex:s.rowIndex,column:s.column}):n=null}}if(!n)return;if(n.rowIndex<0){const t=this.headerNavigationService.getHeaderRowCount();return void this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:t+n.rowIndex,column:i.column},event:e||void 0,fromCell:!0})}const o=this.getNormalisedPosition(n);o?this.focusPosition(o):this.tryToFocusFullWidthRow(n)}getNormalisedPosition(e){this.ensureCellVisible(e);const t=this.getCellByPosition(e);return t?(e=t.getCellPosition(),this.ensureCellVisible(e),e):null}tryToFocusFullWidthRow(e,t=!1){const i=this.columnModel.getAllDisplayedColumns(),r=this.rowRenderer.getRowByPosition(e);if(!r||!r.isFullWidth())return!1;const n=this.focusService.getFocusedCell(),s={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column||(t?Pe(i):i[0])};this.focusPosition(s);const o=null!=n&&this.rowPositionUtils.before(s,n),a={type:ct.EVENT_FULL_WIDTH_ROW_FOCUSED,rowIndex:s.rowIndex,rowPinned:s.rowPinned,column:s.column,isFullWidthCell:!0,floating:s.rowPinned,fromBelow:o};return this.eventService.dispatchEvent(a),!0}focusPosition(e){var t;this.focusService.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0}),null==(t=this.rangeService)||t.setRangeToCell(e)}isValidNavigateCell(e){return!!this.rowPositionUtils.getRowNode(e)}getLastCellOfColSpan(e){const t=this.getCellByPosition(e);if(!t)return e;const i=t.getColSpanningList();return 1===i.length?e:{rowIndex:e.rowIndex,column:Pe(i),rowPinned:e.rowPinned}}ensureCellVisible(e){const t=this.gos.isGroupRowsSticky(),i=this.rowModel.getRow(e.rowIndex);!(t&&(null==i?void 0:i.sticky))&&w(e.rowPinned)&&this.gridBodyCon.getScrollFeature().ensureIndexVisible(e.rowIndex),e.column.isPinned()||this.gridBodyCon.getScrollFeature().ensureColumnVisible(e.column)}};g([he("mouseEventService")],Fa.prototype,"mouseEventService",2),g([he("paginationProxy")],Fa.prototype,"paginationProxy",2),g([he("focusService")],Fa.prototype,"focusService",2),g([he("columnModel")],Fa.prototype,"columnModel",2),g([he("rowModel")],Fa.prototype,"rowModel",2),g([he("ctrlsService")],Fa.prototype,"ctrlsService",2),g([he("rowRenderer")],Fa.prototype,"rowRenderer",2),g([he("headerNavigationService")],Fa.prototype,"headerNavigationService",2),g([he("rowPositionUtils")],Fa.prototype,"rowPositionUtils",2),g([he("cellNavigationService")],Fa.prototype,"cellNavigationService",2),g([he("pinnedRowModel")],Fa.prototype,"pinnedRowModel",2),g([de("rangeService")],Fa.prototype,"rangeService",2),g([le],Fa.prototype,"postConstruct",1),Fa=g([ue("navigationService")],Fa);var ka=class e extends As{constructor(e){super('<div class="ag-popup-editor" tabindex="-1"/>'),this.params=e}postConstruct(){this.gos.setDomData(this.getGui(),e.DOM_KEY_POPUP_EDITOR_WRAPPER,!0),this.addKeyDownListener()}addKeyDownListener(){const e=this.getGui(),t=this.params;this.addManagedListener(e,"keydown",e=>{Zr(this.gos,e,t.node,t.column,!0)||t.onKeyDown(e)})}};ka.DOM_KEY_POPUP_EDITOR_WRAPPER="popupEditorWrapper",g([le],ka.prototype,"postConstruct",1);var Ga=ka,Va=class extends wn{constructor(e,t,i,r,n){super(),this.rendererVersion=0,this.editorVersion=0,this.beans=e,this.column=t.getColumn(),this.rowNode=t.getRowNode(),this.rowCtrl=t.getRowCtrl(),this.eRow=r,this.cellCtrl=t;const s=document.createElement("div");s.setAttribute("comp-id",`${this.getCompId()}`),this.setTemplateFromElement(s);const o=this.getGui();this.forceWrapper=t.isForceWrapper(),this.refreshWrapper(!1);const a=(e,t)=>{null!=t&&""!=t?o.setAttribute(e,t):o.removeAttribute(e)};Bt(o,t.getCellAriaRole()),a("col-id",t.getColumnIdSanitised());const l=t.getTabIndex();void 0!==l&&a("tabindex",l.toString());const c={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setUserStyles:e=>Rr(o,e),getFocusableElement:()=>this.getFocusableElement(),setIncludeSelection:e=>this.includeSelection=e,setIncludeRowDrag:e=>this.includeRowDrag=e,setIncludeDndSource:e=>this.includeDndSource=e,setRenderDetails:(e,t,i)=>this.setRenderDetails(e,t,i),setEditDetails:(e,t,i)=>this.setEditDetails(e,t,i),getCellEditor:()=>this.cellEditor||null,getCellRenderer:()=>this.cellRenderer||null,getParentOfValue:()=>this.getParentOfValue()};t.setComp(c,this.getGui(),this.eCellWrapper,i,n)}getParentOfValue(){return this.eCellValue?this.eCellValue:this.eCellWrapper?this.eCellWrapper:this.getGui()}setRenderDetails(e,t,i){if(this.cellEditor&&!this.cellEditorPopupWrapper)return;this.firstRender=null==this.firstRender;const r=this.refreshWrapper(!1);this.refreshEditStyles(!1),e?!i&&!r&&this.refreshCellRenderer(e)||(this.destroyRenderer(),this.createCellRendererInstance(e)):(this.destroyRenderer(),this.insertValueWithoutCellRenderer(t))}setEditDetails(e,t,i){e?this.createCellEditorInstance(e,t,i):this.destroyEditor()}removeControls(){this.checkboxSelectionComp=this.beans.context.destroyBean(this.checkboxSelectionComp),this.dndSourceComp=this.beans.context.destroyBean(this.dndSourceComp),this.rowDraggingComp=this.beans.context.destroyBean(this.rowDraggingComp)}refreshWrapper(e){const t=this.includeRowDrag||this.includeDndSource||this.includeSelection,i=t||this.forceWrapper,r=i&&null==this.eCellWrapper;if(r){const e=document.createElement("div");e.setAttribute("role","presentation"),e.setAttribute("class","ag-cell-wrapper"),this.eCellWrapper=e,this.getGui().appendChild(this.eCellWrapper)}const n=!i&&null!=this.eCellWrapper;n&&(wr(this.eCellWrapper),this.eCellWrapper=void 0),this.addOrRemoveCssClass("ag-cell-value",!i);const s=!e&&i,o=s&&null==this.eCellValue;if(o){const e=document.createElement("span");e.setAttribute("role","presentation"),e.setAttribute("class","ag-cell-value"),this.eCellValue=e,this.eCellWrapper.appendChild(this.eCellValue)}const a=!s&&null!=this.eCellValue;a&&(wr(this.eCellValue),this.eCellValue=void 0);const l=r||n||o||a;return l&&this.removeControls(),e||t&&this.addControls(),l}addControls(){this.includeRowDrag&&null==this.rowDraggingComp&&(this.rowDraggingComp=this.cellCtrl.createRowDragComp(),this.rowDraggingComp&&this.eCellWrapper.insertBefore(this.rowDraggingComp.getGui(),this.eCellValue)),this.includeDndSource&&null==this.dndSourceComp&&(this.dndSourceComp=this.cellCtrl.createDndSource(),this.eCellWrapper.insertBefore(this.dndSourceComp.getGui(),this.eCellValue)),this.includeSelection&&null==this.checkboxSelectionComp&&(this.checkboxSelectionComp=this.cellCtrl.createSelectionCheckbox(),this.eCellWrapper.insertBefore(this.checkboxSelectionComp.getGui(),this.eCellValue))}createCellEditorInstance(e,t,i){const r=this.editorVersion,n=e.newAgStackInstance();if(!n)return;const{params:s}=e;n.then(e=>this.afterCellEditorCreated(r,e,s,t,i)),w(this.cellEditor)&&s.cellStartedEdit&&this.cellCtrl.focusCell(!0)}insertValueWithoutCellRenderer(e){const t=this.getParentOfValue();yr(t);const i=null!=e?yt(e,!0):null;null!=i&&(t.textContent=i)}destroyEditorAndRenderer(){this.destroyRenderer(),this.destroyEditor()}destroyRenderer(){const{context:e}=this.beans;this.cellRenderer=e.destroyBean(this.cellRenderer),wr(this.cellRendererGui),this.cellRendererGui=null,this.rendererVersion++}destroyEditor(){const{context:e}=this.beans;this.hideEditorPopup&&this.hideEditorPopup(),this.hideEditorPopup=void 0,this.cellEditor=e.destroyBean(this.cellEditor),this.cellEditorPopupWrapper=e.destroyBean(this.cellEditorPopupWrapper),wr(this.cellEditorGui),this.cellEditorGui=null,this.editorVersion++}refreshCellRenderer(e){if(null==this.cellRenderer||null==this.cellRenderer.refresh)return!1;if(this.cellRendererClass!==e.componentClass)return!1;const t=this.cellRenderer.refresh(e.params);return!0===t||void 0===t}createCellRendererInstance(e){const t=!this.beans.gos.get("suppressAnimationFrame"),i=this.rendererVersion,{componentClass:r}=e,n=()=>{if(this.rendererVersion!==i||!this.isAlive())return;const t=e.newAgStackInstance(),n=this.afterCellRendererCreated.bind(this,i,r);t&&t.then(n)};t&&this.firstRender?this.beans.animationFrameService.createTask(n,this.rowNode.rowIndex,"createTasksP2"):n()}getCtrl(){return this.cellCtrl}getRowCtrl(){return this.rowCtrl}getCellRenderer(){return this.cellRenderer}getCellEditor(){return this.cellEditor}afterCellRendererCreated(e,t,i){if(this.isAlive()&&e===this.rendererVersion){if(this.cellRenderer=i,this.cellRendererClass=t,this.cellRendererGui=this.cellRenderer.getGui(),null!=this.cellRendererGui){const e=this.getParentOfValue();yr(e),e.appendChild(this.cellRendererGui)}}else this.beans.context.destroyBean(i)}afterCellEditorCreated(e,t,i,r,n){if(e!==this.editorVersion)return void this.beans.context.destroyBean(t);if(t.isCancelBeforeStart&&t.isCancelBeforeStart())return this.beans.context.destroyBean(t),void this.cellCtrl.stopEditing(!0);if(!t.getGui)return console.warn(`AG Grid: cellEditor for column ${this.column.getId()} is missing getGui() method`),void this.beans.context.destroyBean(t);this.cellEditor=t,this.cellEditorGui=t.getGui();const s=r||void 0!==t.isPopup&&t.isPopup();s?this.addPopupCellEditor(i,n):this.addInCellEditor(),this.refreshEditStyles(!0,s),t.afterGuiAttached&&t.afterGuiAttached()}refreshEditStyles(e,t){var i;this.addOrRemoveCssClass("ag-cell-inline-editing",e&&!t),this.addOrRemoveCssClass("ag-cell-popup-editing",e&&!!t),this.addOrRemoveCssClass("ag-cell-not-inline-editing",!e||!!t),null==(i=this.rowCtrl)||i.setInlineEditingCss(e)}addInCellEditor(){const e=this.getGui();e.contains(this.beans.gos.getActiveDomElement())&&e.focus(),this.destroyRenderer(),this.refreshWrapper(!0),this.clearParentOfValue(),this.cellEditorGui&&this.getParentOfValue().appendChild(this.cellEditorGui)}addPopupCellEditor(e,t){"fullRow"===this.beans.gos.get("editType")&&console.warn("AG Grid: popup cellEditor does not work with fullRowEdit - you cannot use them both - either turn off fullRowEdit, or stop using popup editors.");const i=this.cellEditor;this.cellEditorPopupWrapper=this.beans.context.createBean(new Ga(e));const r=this.cellEditorPopupWrapper.getGui();this.cellEditorGui&&r.appendChild(this.cellEditorGui);const n=this.beans.popupService,s=this.beans.gos.get("stopEditingWhenCellsLoseFocus"),o=null!=t?t:i.getPopupPosition?i.getPopupPosition():"over",a=this.beans.gos.get("enableRtl"),l={ePopup:r,column:this.column,rowNode:this.rowNode,type:"popupCellEditor",eventSource:this.getGui(),position:o,alignSide:a?"right":"left",keepWithinBounds:!0},c=n.positionPopupByComponent.bind(n,l),u=this.beans.localeService.getLocaleTextFunc(),h=n.addPopup({modal:s,eChild:r,closeOnEsc:!0,closedCallback:()=>{this.cellCtrl.onPopupEditorClosed()},anchorToElement:this.getGui(),positionCallback:c,ariaLabel:u("ariaLabelCellEditor","Cell Editor")});h&&(this.hideEditorPopup=h.hideFunc)}detach(){this.eRow.removeChild(this.getGui())}destroy(){this.cellCtrl.stopEditing(),this.destroyEditorAndRenderer(),this.removeControls(),super.destroy()}clearParentOfValue(){const e=this.getGui();e.contains(this.beans.gos.getActiveDomElement())&&Li()&&e.focus({preventScroll:!0}),yr(this.getParentOfValue())}},Ha=class extends wn{constructor(e,t,i){super(),this.cellComps={},this.beans=t,this.rowCtrl=e;const r=document.createElement("div");r.setAttribute("comp-id",`${this.getCompId()}`),r.setAttribute("style",this.getInitialStyle(i)),this.setTemplateFromElement(r);const n=this.getGui(),s=n.style;this.domOrder=this.rowCtrl.getDomOrder(),Bt(n,"row");const o=this.rowCtrl.getTabIndex();null!=o&&n.setAttribute("tabindex",o.toString());const a={setDomOrder:e=>this.domOrder=e,setCellCtrls:e=>this.setCellCtrls(e),showFullWidth:e=>this.showFullWidth(e),getFullWidthCellRenderer:()=>this.getFullWidthCellRenderer(),addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setUserStyles:e=>Rr(n,e),setTop:e=>s.top=e,setTransform:e=>s.transform=e,setRowIndex:e=>n.setAttribute("row-index",e),setRowId:e=>n.setAttribute("row-id",e),setRowBusinessKey:e=>n.setAttribute("row-business-key",e),refreshFullWidth:e=>this.refreshFullWidth(e)};e.setComp(a,this.getGui(),i),this.addDestroyFunc(()=>{e.unsetComp(i)})}getInitialStyle(e){const t=this.rowCtrl.getInitialTransform(e);return t?`transform: ${t}`:`top: ${this.rowCtrl.getInitialRowTop(e)}`}showFullWidth(e){const t=e.newAgStackInstance();t&&t.then(e=>{if(this.isAlive()){const t=e.getGui();this.getGui().appendChild(t),this.rowCtrl.setupDetailRowAutoHeight(t),this.setFullWidthRowComp(e)}else this.beans.context.destroyBean(e)})}setCellCtrls(e){const t=Object.assign({},this.cellComps);e.forEach(e=>{const i=e.getInstanceId();null==this.cellComps[i]?this.newCellComp(e):t[i]=null});const i=O(t).filter(e=>null!=e);this.destroyCells(i),this.ensureDomOrder(e)}ensureDomOrder(e){if(!this.domOrder)return;const t=[];e.forEach(e=>{const i=this.cellComps[e.getInstanceId()];i&&t.push(i.getGui())}),Tr(this.getGui(),t)}newCellComp(e){const t=new Va(this.beans,e,this.rowCtrl.isPrintLayout(),this.getGui(),this.rowCtrl.isEditing());this.cellComps[e.getInstanceId()]=t,this.getGui().appendChild(t.getGui())}destroy(){super.destroy(),this.destroyAllCells()}destroyAllCells(){const e=O(this.cellComps).filter(e=>null!=e);this.destroyCells(e)}setFullWidthRowComp(e){this.fullWidthCellRenderer&&console.error("AG Grid - should not be setting fullWidthRowComponent twice"),this.fullWidthCellRenderer=e,this.addDestroyFunc(()=>{this.fullWidthCellRenderer=this.beans.context.destroyBean(this.fullWidthCellRenderer)})}getFullWidthCellRenderer(){return this.fullWidthCellRenderer}destroyCells(e){e.forEach(e=>{if(!e)return;const t=e.getCtrl().getInstanceId();this.cellComps[t]===e&&(e.detach(),e.destroy(),this.cellComps[t]=null)})}refreshFullWidth(e){const{fullWidthCellRenderer:t}=this;if(!t||!t.refresh)return!1;const i=e();return t.refresh(i)}},Ba=class extends wn{constructor(){super(function(){const e=wn.elementGettingCreated.getAttribute("name"),t=Ia.getRowContainerCssClasses(e);let i;return i="center"===e||"topCenter"===e||"stickyTopCenter"===e||"bottomCenter"===e||"stickyBottomCenter"===e?`<div class="${t.viewport}" ref="eViewport" role="presentation">\n                <div class="${t.container}" ref="eContainer"></div>\n            </div>`:`<div class="${t.container}" ref="eContainer"></div>`,i}()),this.rowComps={},this.name=wn.elementGettingCreated.getAttribute("name"),this.type=_a(this.name)}postConstruct(){const e={setViewportHeight:e=>this.eViewport.style.height=e,setRowCtrls:({rowCtrls:e})=>this.setRowCtrls(e),setDomOrder:e=>{this.domOrder=e},setContainerWidth:e=>this.eContainer.style.width=e};this.createManagedBean(new Ia(this.name)).setComp(e,this.eContainer,this.eViewport)}preDestroy(){this.setRowCtrls([])}setRowCtrls(e){const t=h({},this.rowComps);this.rowComps={},this.lastPlacedElement=null,e.forEach(e=>{const i=e.getInstanceId(),r=t[i];if(r)this.rowComps[i]=r,delete t[i],this.ensureDomOrder(r.getGui());else{if(!e.getRowNode().displayed)return;const t=new Ha(e,this.beans,this.type);this.rowComps[i]=t,this.appendRow(t.getGui())}}),O(t).forEach(e=>{this.eContainer.removeChild(e.getGui()),e.destroy()}),Bt(this.eContainer,"rowgroup")}appendRow(e){this.domOrder?Mr(this.eContainer,e,this.lastPlacedElement):this.eContainer.appendChild(e),this.lastPlacedElement=e}ensureDomOrder(e){this.domOrder&&(Ar(this.eContainer,e,this.lastPlacedElement),this.lastPlacedElement=e)}};g([he("beans")],Ba.prototype,"beans",2),g([bn("eViewport")],Ba.prototype,"eViewport",2),g([bn("eContainer")],Ba.prototype,"eContainer",2),g([le],Ba.prototype,"postConstruct",1),g([ce],Ba.prototype,"preDestroy",1);var za=class{constructor(e){this.columnsToAggregate=[],this.columnsToGroup=[],this.columnsToPivot=[],this.pinned=e}onDragEnter(e){if(this.clearColumnsList(),this.gos.get("functionsReadOnly"))return;const t=e.dragItem.columns;t&&t.forEach(e=>{e.isPrimary()&&(e.isAnyFunctionActive()||(e.isAllowValue()?this.columnsToAggregate.push(e):e.isAllowRowGroup()?this.columnsToGroup.push(e):e.isAllowPivot()&&this.columnsToPivot.push(e)))})}getIconName(){return this.columnsToAggregate.length+this.columnsToGroup.length+this.columnsToPivot.length>0?this.pinned?Vs.ICON_PINNED:Vs.ICON_MOVE:null}onDragLeave(e){this.clearColumnsList()}clearColumnsList(){this.columnsToAggregate.length=0,this.columnsToGroup.length=0,this.columnsToPivot.length=0}onDragging(e){}onDragStop(e){this.columnsToAggregate.length>0&&this.columnModel.addValueColumns(this.columnsToAggregate,"toolPanelDragAndDrop"),this.columnsToGroup.length>0&&this.columnModel.addRowGroupColumns(this.columnsToGroup,"toolPanelDragAndDrop"),this.columnsToPivot.length>0&&this.columnModel.addPivotColumns(this.columnsToPivot,"toolPanelDragAndDrop")}};g([he("columnModel")],za.prototype,"columnModel",2),g([he("gridOptionsService")],za.prototype,"gos",2);var Ua=class{static attemptMoveColumns(e){const{isFromHeader:t,hDirection:i,xPosition:r,fromEnter:n,fakeEvent:s,pinned:o,gos:a,columnModel:l}=e,c=0===i,u=1===i;let{allMovingColumns:h}=e;if(t){let e=[];h.forEach(t=>{var i;let r=null,n=t.getParent();for(;null!=n&&1===n.getDisplayedLeafColumns().length;)r=n,n=n.getParent();null!=r?((null==(i=r.getColGroupDef())?void 0:i.marryChildren)?r.getProvidedColumnGroup().getLeafColumns():r.getLeafColumns()).forEach(t=>{e.includes(t)||e.push(t)}):e.includes(t)||e.push(t)}),h=e}const d=h.slice();l.sortColumnsLikeGridColumns(d);const p=this.calculateValidMoves({movingCols:d,draggingRight:u,xPosition:r,pinned:o,gos:a,columnModel:l}),g=this.calculateOldIndex(d,l);if(0===p.length)return;const f=p[0];let m=null!==g&&!n;if(t&&(m=null!==g),m&&!s){if(c&&f>=g)return;if(u&&f<=g)return}const v=l.getAllDisplayedColumns();let C=[],y=null;for(let e=0;e<p.length;e++){const t=p[e],i=l.getProposedColumnOrder(d,t);if(!l.doesOrderPassRules(i))continue;const r=i.filter(e=>v.includes(e));if(null===y)y=r;else if(!xe(r,y))break;const n=this.groupFragCount(i);C.push({move:t,fragCount:n})}return 0!==C.length?(C.sort((e,t)=>e.fragCount-t.fragCount),this.moveColumns(h,C[0].move,"uiColumnMoved",!1,l)):void 0}static moveColumns(e,t,i,r,n){return n.moveColumns(e,t,i,r),r?null:{columns:e,toIndex:t}}static calculateOldIndex(e,t){const i=t.getAllGridColumns(),r=Ie(e.map(e=>i.indexOf(e))),n=r[0];return Pe(r)-n!==r.length-1?null:n}static groupFragCount(e){function t(e){let t=[],i=e.getOriginalParent();for(;null!=i;)t.push(i),i=i.getOriginalParent();return t}let i=0;for(let r=0;r<e.length-1;r++){let n=t(e[r]),s=t(e[r+1]);[n,s]=n.length>s.length?[n,s]:[s,n],n.forEach(e=>{-1===s.indexOf(e)&&i++})}return i}static getDisplayedColumns(e,t){switch(t){case"left":return e.getDisplayedLeftColumns();case"right":return e.getDisplayedRightColumns();default:return e.getDisplayedCenterColumns()}}static calculateValidMoves(e){const{movingCols:t,draggingRight:i,xPosition:r,pinned:n,gos:s,columnModel:o}=e;if(s.get("suppressMovableColumns")||t.some(e=>e.getColDef().suppressMovable))return[];const a=this.getDisplayedColumns(o,n),l=o.getAllGridColumns(),c=a.filter(e=>Be(t,e)),u=a.filter(e=>!Be(t,e)),h=l.filter(e=>!Be(t,e));let d,p=0,g=r;if(i){let e=0;c.forEach(t=>e+=t.getActualWidth()),g-=e}if(g>0){for(let e=0;e<u.length&&(g-=u[e].getActualWidth(),!(g<0));e++)p++;i&&p++}if(p>0){const e=u[p-1];d=h.indexOf(e)+1}else d=h.indexOf(u[0]),-1===d&&(d=0);const f=[d],m=(e,t)=>e-t;if(i){let e=d+1;const t=l.length-1;for(;e<=t;)f.push(e),e++;f.sort(m)}else{let e=d;const t=l.length-1;let i=l[e];for(;e<=t&&a.indexOf(i)<0;)e++,f.push(e),i=l[e];e=d-1;const r=0;for(;e>=r;)f.push(e),e--;f.sort(m).reverse()}return f}static normaliseX(e,t,i,r,n){const s=n.getHeaderRowContainerCtrl(t).getViewport();return i&&(e-=s.getBoundingClientRect().left),r.get("enableRtl")&&(e=s.clientWidth-e),null==t&&(e+=n.get("center").getCenterViewportScrollLeft()),e}},Wa=class{constructor(e){this.needToMoveLeft=!1,this.needToMoveRight=!1,this.lastMovedInfo=null,this.pinned=e,this.isCenterContainer=!y(e)}init(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl})}getIconName(){return this.pinned?Vs.ICON_PINNED:Vs.ICON_MOVE}onDragEnter(e){const t=e.dragItem.columns;if(0===e.dragSource.type)this.setColumnsVisible(t,!0,"uiColumnDragged");else{const i=e.dragItem.visibleState,r=(t||[]).filter(e=>i[e.getId()]);this.setColumnsVisible(r,!0,"uiColumnDragged")}this.setColumnsPinned(t,this.pinned,"uiColumnDragged"),this.onDragging(e,!0,!0)}onDragLeave(){this.ensureIntervalCleared(),this.lastMovedInfo=null}setColumnsVisible(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockVisible);this.columnModel.setColumnsVisible(r,t,i)}}setColumnsPinned(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockPinned);this.columnModel.setColumnsPinned(r,t,i)}}onDragStop(){this.onDragging(this.lastDraggingEvent,!1,!0,!0),this.ensureIntervalCleared(),this.lastMovedInfo=null}checkCenterForScrolling(e){if(this.isCenterContainer){const t=this.ctrlsService.get("center"),i=t.getCenterViewportScrollLeft(),r=i+t.getCenterWidth();this.gos.get("enableRtl")?(this.needToMoveRight=e<i+50,this.needToMoveLeft=e>r-50):(this.needToMoveLeft=e<i+50,this.needToMoveRight=e>r-50),this.needToMoveLeft||this.needToMoveRight?this.ensureIntervalStarted():this.ensureIntervalCleared()}}onDragging(e=this.lastDraggingEvent,t=!1,i=!1,r=!1){var n;if(r){if(this.lastMovedInfo){const{columns:e,toIndex:t}=this.lastMovedInfo;Ua.moveColumns(e,t,"uiColumnMoved",!0,this.columnModel)}return}if(this.lastDraggingEvent=e,w(e.hDirection))return;const s=Ua.normaliseX(e.x,this.pinned,!1,this.gos,this.ctrlsService);t||this.checkCenterForScrolling(s);const o=this.normaliseDirection(e.hDirection),a=e.dragSource.type,l=(null==(n=e.dragSource.getDragItem().columns)?void 0:n.filter(e=>!e.getColDef().lockPinned||e.getPinned()==this.pinned))||[],c=Ua.attemptMoveColumns({allMovingColumns:l,isFromHeader:1===a,hDirection:o,xPosition:s,pinned:this.pinned,fromEnter:t,fakeEvent:i,gos:this.gos,columnModel:this.columnModel});c&&(this.lastMovedInfo=c)}normaliseDirection(e){if(!this.gos.get("enableRtl"))return e;switch(e){case 0:return 1;case 1:return 0;default:console.error(`AG Grid: Unknown direction ${e}`)}}ensureIntervalStarted(){this.movingIntervalId||(this.intervalCount=0,this.failedMoveAttempts=0,this.movingIntervalId=window.setInterval(this.moveInterval.bind(this),100),this.needToMoveLeft?this.dragAndDropService.setGhostIcon(Vs.ICON_LEFT,!0):this.dragAndDropService.setGhostIcon(Vs.ICON_RIGHT,!0))}ensureIntervalCleared(){this.movingIntervalId&&(window.clearInterval(this.movingIntervalId),this.movingIntervalId=null,this.dragAndDropService.setGhostIcon(Vs.ICON_MOVE))}moveInterval(){let e;this.intervalCount++,e=10+5*this.intervalCount,e>100&&(e=100);let t=null;const i=this.gridBodyCon.getScrollFeature();if(this.needToMoveLeft?t=i.scrollHorizontally(-e):this.needToMoveRight&&(t=i.scrollHorizontally(e)),0!==t)this.onDragging(this.lastDraggingEvent),this.failedMoveAttempts=0;else{this.failedMoveAttempts++;const e=this.lastDraggingEvent.dragItem.columns.filter(e=>!e.getColDef().lockPinned);if(e.length>0&&(this.dragAndDropService.setGhostIcon(Vs.ICON_PINNED),this.failedMoveAttempts>7)){const t=this.needToMoveLeft?"left":"right";this.setColumnsPinned(e,t,"uiColumnDragged"),this.dragAndDropService.nudge()}}}};g([he("columnModel")],Wa.prototype,"columnModel",2),g([he("dragAndDropService")],Wa.prototype,"dragAndDropService",2),g([he("gridOptionsService")],Wa.prototype,"gos",2),g([he("ctrlsService")],Wa.prototype,"ctrlsService",2),g([le],Wa.prototype,"init",1);var ja=class extends nt{constructor(e,t){super(),this.pinned=e,this.eContainer=t}postConstruct(){this.ctrlsService.whenReady(e=>{switch(this.pinned){case"left":this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.left.getContainerElement()],[e.bottomLeft.getContainerElement()],[e.topLeft.getContainerElement()]];break;case"right":this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.right.getContainerElement()],[e.bottomRight.getContainerElement()],[e.topRight.getContainerElement()]];break;default:this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.center.getViewportElement()],[e.bottomCenter.getViewportElement()],[e.topCenter.getViewportElement()]]}})}isInterestedIn(e){return 1===e||0===e&&this.gos.get("allowDragFromColumnsToolPanel")}getSecondaryContainers(){return this.eSecondaryContainers}getContainer(){return this.eContainer}init(){this.moveColumnFeature=this.createManagedBean(new Wa(this.pinned)),this.bodyDropPivotTarget=this.createManagedBean(new za(this.pinned)),this.dragAndDropService.addDropTarget(this)}getIconName(){return this.currentDropListener.getIconName()}isDropColumnInPivotMode(e){return this.columnModel.isPivotMode()&&0===e.dragSource.type}onDragEnter(e){this.currentDropListener=this.isDropColumnInPivotMode(e)?this.bodyDropPivotTarget:this.moveColumnFeature,this.currentDropListener.onDragEnter(e)}onDragLeave(e){this.currentDropListener.onDragLeave(e)}onDragging(e){this.currentDropListener.onDragging(e)}onDragStop(e){this.currentDropListener.onDragStop(e)}};g([he("dragAndDropService")],ja.prototype,"dragAndDropService",2),g([he("columnModel")],ja.prototype,"columnModel",2),g([he("ctrlsService")],ja.prototype,"ctrlsService",2),g([le],ja.prototype,"postConstruct",1),g([le],ja.prototype,"init",1);var Ka=class e extends $o{constructor(t){super(e.TEMPLATE,t),this.headerCompVersion=0,this.column=t.getColumnGroupChild(),this.pinned=t.getPinned()}postConstruct(){const e=this.getGui();var t,i;t="col-id",null!=(i=this.column.getColId())&&""!=i?e.setAttribute(t,i):e.removeAttribute(t);const r={setWidth:t=>e.style.width=t,addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setAriaSort:t=>t?di(e,t):pi(e),setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerComp};this.ctrl.setComp(r,this.getGui(),this.eResize,this.eHeaderCompWrapper);const n=this.ctrl.getSelectAllGui();this.eResize.insertAdjacentElement("afterend",n)}destroyHeaderComp(){this.headerComp&&(this.eHeaderCompWrapper.removeChild(this.headerCompGui),this.headerComp=this.destroyBean(this.headerComp),this.headerCompGui=void 0)}setUserCompDetails(e){this.headerCompVersion++;const t=this.headerCompVersion;e.newAgStackInstance().then(e=>this.afterCompCreated(t,e))}afterCompCreated(e,t){e==this.headerCompVersion&&this.isAlive()?(this.destroyHeaderComp(),this.headerComp=t,this.headerCompGui=t.getGui(),this.eHeaderCompWrapper.appendChild(this.headerCompGui),this.ctrl.setDragSource(this.getGui())):this.destroyBean(t)}};Ka.TEMPLATE='<div class="ag-header-cell" role="columnheader">\n            <div ref="eResize" class="ag-header-cell-resize" role="presentation"></div>\n            <div ref="eHeaderCompWrapper" class="ag-header-cell-comp-wrapper" role="presentation"></div>\n        </div>',g([bn("eResize")],Ka.prototype,"eResize",2),g([bn("eHeaderCompWrapper")],Ka.prototype,"eHeaderCompWrapper",2),g([le],Ka.prototype,"postConstruct",1),g([ce],Ka.prototype,"destroyHeaderComp",1);var $a=Ka,qa=class e extends $o{constructor(t){super(e.TEMPLATE,t)}postConstruct(){const e=this.getGui();e.setAttribute("col-id",this.ctrl.getColId());const t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setResizableDisplayed:e=>or(this.eResize,e),setWidth:t=>e.style.width=t,setAriaExpanded:t=>{return i="aria-expanded",null!=(r=t)?e.setAttribute(i,r):e.removeAttribute(i);var i,r},setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerGroupComp};this.ctrl.setComp(t,e,this.eResize)}setUserCompDetails(e){e.newAgStackInstance().then(e=>this.afterHeaderCompCreated(e))}afterHeaderCompCreated(e){const t=()=>this.destroyBean(e);if(!this.isAlive())return void t();const i=this.getGui(),r=e.getGui();i.appendChild(r),this.addDestroyFunc(t),this.headerGroupComp=e,this.ctrl.setDragSource(i)}};qa.TEMPLATE='<div class="ag-header-group-cell" role="columnheader">\n            <div ref="eResize" class="ag-header-cell-resize" role="presentation"></div>\n        </div>',g([bn("eResize")],qa.prototype,"eResize",2),g([le],qa.prototype,"postConstruct",1);var Ya=qa,Qa=(e=>(e.COLUMN_GROUP="group",e.COLUMN="column",e.FLOATING_FILTER="filter",e))(Qa||{}),Xa=class extends wn{constructor(e){super(),this.headerComps={},this.ctrl=e,this.setTemplate(`<div class="${this.ctrl.getHeaderRowClass()}" role="row"></div>`)}init(){li(this.getGui(),this.ctrl.getAriaRowIndex());const e={setHeight:e=>this.getGui().style.height=e,setTop:e=>this.getGui().style.top=e,setHeaderCtrls:(e,t)=>this.setHeaderCtrls(e,t),setWidth:e=>this.getGui().style.width=e};this.ctrl.setComp(e)}destroyHeaderCtrls(){this.setHeaderCtrls([],!1)}setHeaderCtrls(e,t){if(!this.isAlive())return;const i=this.headerComps;if(this.headerComps={},e.forEach(e=>{const t=e.getInstanceId();let r=i[t];delete i[t],null==r&&(r=this.createHeaderComp(e),this.getGui().appendChild(r.getGui())),this.headerComps[t]=r}),I(i,(e,t)=>{this.getGui().removeChild(t.getGui()),this.destroyBean(t)}),t){const e=O(this.headerComps);e.sort((e,t)=>e.getCtrl().getColumnGroupChild().getLeft()-t.getCtrl().getColumnGroupChild().getLeft());const t=e.map(e=>e.getGui());Tr(this.getGui(),t)}}createHeaderComp(e){let t;switch(this.ctrl.getType()){case"group":t=new Ya(e);break;case"filter":t=new Yo(e);break;default:t=new $a(e)}return this.createBean(t),t.setParentComponent(this),t}};g([le],Xa.prototype,"init",1),g([ce],Xa.prototype,"destroyHeaderCtrls",1);var Za=0,Ja=class e extends nt{constructor(e,t,i){super(),this.resizeToggleTimeout=0,this.resizeMultiplier=1,this.resizeFeature=null,this.lastFocusEvent=null,this.dragSource=null,this.columnGroupChild=e,this.parentRowCtrl=i,this.beans=t,this.instanceId=e.getUniqueId()+"-"+Za++}postConstruct(){this.addManagedPropertyListeners(["suppressHeaderFocus"],()=>this.refreshTabIndex())}shouldStopEventPropagation(e){const{headerRowIndex:t,column:i}=this.focusService.getFocusedHeader();return Jr(this.gos,e,t,i)}getWrapperHasFocus(){return this.gos.getActiveDomElement()===this.eGui}setGui(e){this.eGui=e,this.addDomData(),this.addManagedListener(this.beans.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.onDisplayedColumnsChanged(),this.refreshTabIndex()}onDisplayedColumnsChanged(){this.comp&&this.column&&(this.refreshFirstAndLastStyles(),this.refreshAriaColIndex())}refreshFirstAndLastStyles(){const{comp:e,column:t,beans:i}=this;da.refreshFirstAndLastStyles(e,t,i.columnModel)}refreshAriaColIndex(){const{beans:e,column:t}=this,i=e.columnModel.getAriaColumnIndex(t);ui(this.eGui,i)}addResizeAndMoveKeyboardListeners(){this.resizeFeature&&(this.addManagedListener(this.eGui,"keydown",this.onGuiKeyDown.bind(this)),this.addManagedListener(this.eGui,"keyup",this.onGuiKeyUp.bind(this)))}refreshTabIndex(){this.gos.get("suppressHeaderFocus")?this.eGui.removeAttribute("tabindex"):this.eGui.setAttribute("tabindex","-1")}onGuiKeyDown(e){var t;const i=this.gos.getActiveDomElement(),r=e.key===Qr.LEFT||e.key===Qr.RIGHT;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),i!==this.eGui||!e.shiftKey&&!e.altKey)return;if((this.isResizing||r)&&(e.preventDefault(),e.stopImmediatePropagation()),!r)return;const n=e.key===Qr.LEFT!==this.gos.get("enableRtl"),s=ks[n?"Left":"Right"];if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;const i=this.getViewportAdjustedResizeDiff(e);this.resizeHeader(i,e.shiftKey),null==(t=this.resizeFeature)||t.toggleColumnResizing(!0)}else this.moveHeader(s)}getViewportAdjustedResizeDiff(e){let t=this.getResizeDiff(e);if(this.column.getPinned()){const e=this.pinnedWidthService.getPinnedLeftWidth(),i=this.pinnedWidthService.getPinnedRightWidth(),r=dr(this.ctrlsService.getGridBodyCtrl().getBodyViewportElement())-50;if(e+i+t>r){if(!(r>e+i))return 0;t=r-e-i}}return t}getResizeDiff(e){let t=e.key===Qr.LEFT!==this.gos.get("enableRtl");const i=this.column.getPinned(),r=this.gos.get("enableRtl");return i&&r!==("right"===i)&&(t=!t),(t?-1:1)*this.resizeMultiplier}onGuiKeyUp(){this.isResizing&&(this.resizeToggleTimeout&&(window.clearTimeout(this.resizeToggleTimeout),this.resizeToggleTimeout=0),this.isResizing=!1,this.resizeMultiplier=1,this.resizeToggleTimeout=setTimeout(()=>{var e;null==(e=this.resizeFeature)||e.toggleColumnResizing(!1)},150))}handleKeyDown(e){const t=this.getWrapperHasFocus();switch(e.key){case Qr.PAGE_DOWN:case Qr.PAGE_UP:case Qr.PAGE_HOME:case Qr.PAGE_END:t&&e.preventDefault()}}addDomData(){const t=e.DOM_DATA_KEY_HEADER_CTRL;this.gos.setDomData(this.eGui,t,this),this.addDestroyFunc(()=>this.gos.setDomData(this.eGui,t,null))}getGui(){return this.eGui}focus(e){return!!this.eGui&&(this.lastFocusEvent=e||null,this.eGui.focus(),!0)}getRowIndex(){return this.parentRowCtrl.getRowIndex()}getParentRowCtrl(){return this.parentRowCtrl}getPinned(){return this.parentRowCtrl.getPinned()}getInstanceId(){return this.instanceId}getColumnGroupChild(){return this.columnGroupChild}removeDragSource(){this.dragSource&&(this.dragAndDropService.removeDragSource(this.dragSource),this.dragSource=null)}handleContextMenuMouseEvent(e,t,i){const r=null!=e?e:t;this.gos.get("preventDefaultOnContextMenu")&&r.preventDefault();const n=i instanceof be?i:void 0;this.menuService.isHeaderContextMenuEnabled(n)&&this.menuService.showHeaderContextMenu(n,e,t),this.dispatchColumnMouseEvent(ct.EVENT_COLUMN_HEADER_CONTEXT_MENU,i)}dispatchColumnMouseEvent(e,t){const i={type:e,column:t};this.eventService.dispatchEvent(i)}destroy(){super.destroy(),this.removeDragSource(),this.comp=null,this.column=null,this.resizeFeature=null,this.lastFocusEvent=null,this.columnGroupChild=null,this.parentRowCtrl=null,this.eGui=null}};Ja.DOM_DATA_KEY_HEADER_CTRL="headerCtrl",g([he("pinnedWidthService")],Ja.prototype,"pinnedWidthService",2),g([he("focusService")],Ja.prototype,"focusService",2),g([he("userComponentFactory")],Ja.prototype,"userComponentFactory",2),g([he("ctrlsService")],Ja.prototype,"ctrlsService",2),g([he("dragAndDropService")],Ja.prototype,"dragAndDropService",2),g([he("menuService")],Ja.prototype,"menuService",2),g([le],Ja.prototype,"postConstruct",1);var el=Ja,tl=class extends nt{constructor(e,t,i,r){super(),this.columnOrGroup=e,this.eCell=t,this.ariaEl=this.eCell.querySelector("[role=columnheader]")||this.eCell,this.colsSpanning=r,this.beans=i}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){return this.beans.gos.get("enableRtl")&&this.colsSpanning?Pe(this.colsSpanning):this.columnOrGroup}postConstruct(){this.addManagedListener(this.columnOrGroup,be.EVENT_LEFT_CHANGED,this.onLeftChanged.bind(this)),this.setLeftFirstTime(),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onLeftChanged.bind(this)),this.addManagedPropertyListener("domLayout",this.onLeftChanged.bind(this))}setLeftFirstTime(){const e=this.beans.gos.get("suppressColumnMoveAnimation"),t=y(this.columnOrGroup.getOldLeft());this.beans.columnAnimationService.isActive()&&t&&!e?this.animateInLeft():this.onLeftChanged()}animateInLeft(){const e=this.getColumnOrGroup(),t=e.getLeft(),i=e.getOldLeft(),r=this.modifyLeftForPrintLayout(e,i),n=this.modifyLeftForPrintLayout(e,t);this.setLeft(r),this.actualLeft=n,this.beans.columnAnimationService.executeNextVMTurn(()=>{this.actualLeft===n&&this.setLeft(n)})}onLeftChanged(){const e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){if(!this.beans.gos.isDomLayout("print"))return t;if("left"===e.getPinned())return t;const i=this.beans.columnModel.getDisplayedColumnsLeftWidth();return"right"===e.getPinned()?i+this.beans.columnModel.getBodyContainerWidth()+t:i+t}setLeft(e){let t;if(y(e)&&(this.eCell.style.left=`${e}px`),this.columnOrGroup instanceof be)t=this.columnOrGroup;else{const e=this.columnOrGroup.getLeafColumns();if(!e.length)return;e.length>1&&hi(this.ariaEl,e.length),t=e[0]}}};g([le],tl.prototype,"postConstruct",1);var il=class extends nt{constructor(e,t){super(),this.columns=e,this.element=t}postConstruct(){this.gos.get("columnHoverHighlight")&&this.addMouseHoverListeners()}addMouseHoverListeners(){this.addManagedListener(this.element,"mouseout",this.onMouseOut.bind(this)),this.addManagedListener(this.element,"mouseover",this.onMouseOver.bind(this))}onMouseOut(){this.columnHoverService.clearMouseOver()}onMouseOver(){this.columnHoverService.setMouseOver(this.columns)}};g([he("columnHoverService")],il.prototype,"columnHoverService",2),g([le],il.prototype,"postConstruct",1);var rl=class extends el{constructor(e,t,i){super(e,t,i),this.iconCreated=!1,this.column=e}setComp(e,t,i,r){this.comp=e,this.eButtonShowMainFilter=i,this.eFloatingFilterBody=r,this.setGui(t),this.setupActive(),this.setupWidth(),this.setupLeft(),this.setupHover(),this.setupFocus(),this.setupAria(),this.setupFilterButton(),this.setupUserComp(),this.setupSyncWithFilter(),this.setupUi(),this.addManagedListener(this.eButtonShowMainFilter,"click",this.showParentFilter.bind(this)),this.setupFilterChangedListener(),this.addManagedListener(this.column,be.EVENT_COL_DEF_CHANGED,this.onColDefChanged.bind(this))}resizeHeader(){}moveHeader(){}setupActive(){const e=this.column.getColDef(),t=!!e.filter,i=!!e.floatingFilter;this.active=t&&i}setupUi(){if(this.comp.setButtonWrapperDisplayed(!this.suppressFilterButton&&this.active),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-full-body",this.suppressFilterButton),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-body",!this.suppressFilterButton),!this.active||this.iconCreated)return;const e=qr("filter",this.gos,this.column);e&&(this.iconCreated=!0,this.eButtonShowMainFilter.appendChild(e))}setupFocus(){this.createManagedBean(new Pn(this.eGui,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)}))}setupAria(){const e=this.localeService.getLocaleTextFunc();Kt(this.eButtonShowMainFilter,e("ariaFilterMenuOpen","Open Filter Menu"))}onTabKeyDown(e){if(this.gos.getActiveDomElement()===this.eGui)return;const t=this.focusService.findNextFocusableElement(this.eGui,null,e.shiftKey);if(t)return this.beans.headerNavigationService.scrollToColumn(this.column),e.preventDefault(),void t.focus();const i=this.findNextColumnWithFloatingFilter(e.shiftKey);i&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:this.getParentRowCtrl().getRowIndex(),column:i},event:e})&&e.preventDefault()}findNextColumnWithFloatingFilter(e){const t=this.beans.columnModel;let i=this.column;do{if(i=e?t.getDisplayedColBefore(i):t.getDisplayedColAfter(i),!i)break}while(!i.getColDef().filter||!i.getColDef().floatingFilter);return i}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();switch(e.key){case Qr.UP:case Qr.DOWN:t||e.preventDefault();case Qr.LEFT:case Qr.RIGHT:if(t)return;e.stopPropagation();case Qr.ENTER:t&&this.focusService.focusInto(this.eGui)&&e.preventDefault();break;case Qr.ESCAPE:t||this.eGui.focus()}}onFocusIn(e){if(this.eGui.contains(e.relatedTarget))return;const t=!!e.relatedTarget&&!e.relatedTarget.classList.contains("ag-floating-filter"),i=!!e.relatedTarget&&cr(e.relatedTarget,"ag-floating-filter");if(t&&i&&e.target===this.eGui){const e=this.lastFocusEvent,t=!(!e||e.key!==Qr.TAB);if(e&&t){const t=e.shiftKey;this.focusService.focusInto(this.eGui,t)}}const r=this.getRowIndex();this.beans.focusService.setFocusedHeader(r,this.column)}setupHover(){this.createManagedBean(new il([this.column],this.eGui));const e=()=>{if(!this.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.comp.addOrRemoveCssClass("ag-column-hover",e)};this.addManagedListener(this.eventService,ct.EVENT_COLUMN_HOVER_CHANGED,e),e()}setupLeft(){const e=new tl(this.column,this.eGui,this.beans);this.createManagedBean(e)}setupFilterButton(){this.suppressFilterButton=!this.menuService.isFloatingFilterButtonEnabled(this.column),this.highlightFilterButtonWhenActive=!this.menuService.isLegacyMenuEnabled()}setupUserComp(){if(!this.active)return;const e=this.beans.filterManager.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter());e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setCompDetails(e)}showParentFilter(){const e=this.suppressFilterButton?this.eFloatingFilterBody:this.eButtonShowMainFilter;this.menuService.showFilterMenu({column:this.column,buttonElement:e,containerType:"floatingFilter",positionBy:"button"})}setupSyncWithFilter(){if(!this.active)return;const{filterManager:e}=this.beans,t=t=>{if("filterDestroyed"===(null==t?void 0:t.source)&&this.context.isDestroyed())return;const i=this.comp.getFloatingFilterComp();i&&i.then(i=>{var r;if(i){const n=e.getCurrentFloatingFilterParentModel(this.column);i.onParentModelChanged(n,t?this.gos.addGridCommonParams({columns:null!=(r=t.columns)?r:[],type:ct.EVENT_FILTER_CHANGED,source:"api"===t.source?"api":"columnFilter"}):null)}})};this.destroySyncListener=this.addManagedListener(this.column,be.EVENT_FILTER_CHANGED,t),e.isFilterActive(this.column)&&t(null)}setupWidth(){const e=()=>{const e=`${this.column.getActualWidth()}px`;this.comp.setWidth(e)};this.addManagedListener(this.column,be.EVENT_WIDTH_CHANGED,e),e()}setupFilterChangedListener(){this.active&&(this.destroyFilterChangedListener=this.addManagedListener(this.column,be.EVENT_FILTER_CHANGED,this.updateFilterButton.bind(this)),this.updateFilterButton())}updateFilterButton(){if(!this.suppressFilterButton&&this.comp){const e=this.beans.filterManager.isFilterAllowed(this.column);this.comp.setButtonWrapperDisplayed(e),this.highlightFilterButtonWhenActive&&e&&this.eButtonShowMainFilter.classList.toggle("ag-filter-active",this.column.isFilterActive())}}onColDefChanged(){var e,t;const i=this.active;this.setupActive();const r=!i&&this.active;i&&!this.active&&(null==(e=this.destroySyncListener)||e.call(this),null==(t=this.destroyFilterChangedListener)||t.call(this));const n=this.active?this.beans.filterManager.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter()):null,s=this.comp.getFloatingFilterComp();s&&n?s.then(e=>{var t;!e||this.beans.filterManager.areFilterCompsDifferent(null!=(t=this.userCompDetails)?t:null,n)?this.updateCompDetails(n,r):this.updateFloatingFilterParams(n)}):this.updateCompDetails(n,r)}updateCompDetails(e,t){this.isAlive()&&(this.setCompDetails(e),this.setupFilterButton(),this.setupUi(),t&&(this.setupSyncWithFilter(),this.setupFilterChangedListener()))}updateFloatingFilterParams(e){var t;if(!e)return;const i=e.params;null==(t=this.comp.getFloatingFilterComp())||t.then(e=>{let t=!1;(null==e?void 0:e.refresh)&&"function"==typeof e.refresh&&null!==e.refresh(i)&&(t=!0),!t&&(null==e?void 0:e.onParamsUpdated)&&"function"==typeof e.onParamsUpdated&&null!==e.onParamsUpdated(i)&&U("Custom floating filter method 'onParamsUpdated' is deprecated. Use 'refresh' instead.")})}destroy(){super.destroy(),this.eButtonShowMainFilter=null,this.eFloatingFilterBody=null,this.userCompDetails=null,this.destroySyncListener=null,this.destroyFilterChangedListener=null}},nl=class extends nt{constructor(e,t,i,r,n){super(),this.pinned=e,this.column=t,this.eResize=i,this.comp=r,this.ctrl=n}postConstruct(){const e=[];let t,i;const r=()=>{if(or(this.eResize,t),!t)return;const r=this.horizontalResizeService.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});if(e.push(r),i){const t=this.gos.get("skipHeaderOnAutoSize"),i=()=>{this.columnModel.autoSizeColumn(this.column,"uiColumnResized",t)};this.eResize.addEventListener("dblclick",i);const r=new vs(this.eResize);r.addEventListener(vs.EVENT_DOUBLE_TAP,i),e.push(()=>{this.eResize.removeEventListener("dblclick",i),r.removeEventListener(vs.EVENT_DOUBLE_TAP,i),r.destroy()})}},n=()=>{e.forEach(e=>e()),e.length=0},s=()=>{const e=this.column.isResizable(),s=!this.gos.get("suppressAutoSize")&&!this.column.getColDef().suppressAutoSize;(e!==t||s!==i)&&(t=e,i=s,n(),r())};s(),this.addDestroyFunc(n),this.ctrl.addRefreshFunction(s)}onResizing(e,t){const{column:i,lastResizeAmount:r,resizeStartWidth:n}=this,s=this.normaliseResizeAmount(t),o=[{key:i,newWidth:n+s}];this.column.getPinned()&&this.pinnedWidthService.getPinnedLeftWidth()+this.pinnedWidthService.getPinnedRightWidth()+(s-r)>dr(this.ctrlsService.getGridBodyCtrl().getBodyViewportElement())-50||(this.lastResizeAmount=s,this.columnModel.setColumnWidths(o,this.resizeWithShiftKey,e,"uiColumnResized"),e&&this.toggleColumnResizing(!1))}onResizeStart(e){this.resizeStartWidth=this.column.getActualWidth(),this.lastResizeAmount=0,this.resizeWithShiftKey=e,this.toggleColumnResizing(!0)}toggleColumnResizing(e){this.comp.addOrRemoveCssClass("ag-column-resizing",e)}normaliseResizeAmount(e){let t=e;const i="left"!==this.pinned,r="right"===this.pinned;return this.gos.get("enableRtl")?i&&(t*=-1):r&&(t*=-1),t}};g([he("horizontalResizeService")],nl.prototype,"horizontalResizeService",2),g([he("pinnedWidthService")],nl.prototype,"pinnedWidthService",2),g([he("ctrlsService")],nl.prototype,"ctrlsService",2),g([he("columnModel")],nl.prototype,"columnModel",2),g([le],nl.prototype,"postConstruct",1);var sl=class extends nt{constructor(e){super(),this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1,this.column=e}onSpaceKeyDown(e){const t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(this.gos.getActiveDomElement())&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e,this.cbSelectAll=this.createManagedBean(new Un),this.cbSelectAll.addCssClass("ag-header-select-all"),Bt(this.cbSelectAll.getGui(),"presentation"),this.showOrHideSelectAll(),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.onNewColumnsLoaded.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_SELECTION_CHANGED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_PAGINATION_CHANGED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_MODEL_UPDATED,this.onModelChanged.bind(this)),this.addManagedListener(this.cbSelectAll,ct.EVENT_FIELD_VALUE_CHANGED,this.onCbSelectAll.bind(this)),ei(this.cbSelectAll.getGui(),!0),this.cbSelectAll.getInputElement().setAttribute("tabindex","-1"),this.refreshSelectAllLabel()}onNewColumnsLoaded(){this.showOrHideSelectAll()}onDisplayedColumnsChanged(){this.isAlive()&&this.showOrHideSelectAll()}showOrHideSelectAll(){this.cbSelectAllVisible=this.isCheckboxSelection(),this.cbSelectAll.setDisplayed(this.cbSelectAllVisible,{skipAriaHidden:!0}),this.cbSelectAllVisible&&(this.checkRightRowModelType("selectAllCheckbox"),this.checkSelectionType("selectAllCheckbox"),this.updateStateOfCheckbox()),this.refreshSelectAllLabel()}onModelChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}onSelectionChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}updateStateOfCheckbox(){if(this.processingEventFromCheckbox)return;this.processingEventFromCheckbox=!0;const e=this.selectionService.getSelectAllState(this.isFilteredOnly(),this.isCurrentPageOnly());this.cbSelectAll.setValue(e);const t=this.selectionService.hasNodesToSelect(this.isFilteredOnly(),this.isCurrentPageOnly());this.cbSelectAll.setDisabled(!t),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(){const e=this.localeService.getLocaleTextFunc(),t=this.cbSelectAll.getValue()?e("ariaChecked","checked"):e("ariaUnchecked","unchecked"),i=e("ariaRowSelectAll","Press Space to toggle all rows selection");this.cbSelectAllVisible?this.headerCellCtrl.setAriaDescriptionProperty("selectAll",`${i} (${t})`):this.headerCellCtrl.setAriaDescriptionProperty("selectAll",null),this.cbSelectAll.setInputAriaLabel(`${i} (${t})`),this.headerCellCtrl.announceAriaDescription()}checkSelectionType(e){return!("multiple"!==this.gos.get("rowSelection")&&(console.warn(`AG Grid: ${e} is only available if using 'multiple' rowSelection.`),1))}checkRightRowModelType(e){const t=this.rowModel.getType();return!("clientSide"!==t&&"serverSide"!==t&&(console.warn(`AG Grid: ${e} is only available if using 'clientSide' or 'serverSide' rowModelType, you are using ${t}.`),1))}onCbSelectAll(){if(this.processingEventFromCheckbox)return;if(!this.cbSelectAllVisible)return;const e=this.cbSelectAll.getValue(),t=this.isFilteredOnly(),i=this.isCurrentPageOnly();let r="uiSelectAll";i?r="uiSelectAllCurrentPage":t&&(r="uiSelectAllFiltered");const n={source:r,justFiltered:t,justCurrentPage:i};e?this.selectionService.selectAllRowNodes(n):this.selectionService.deselectAllRowNodes(n)}isCheckboxSelection(){let e=this.column.getColDef().headerCheckboxSelection;return"function"==typeof e&&(e=e(this.gos.addGridCommonParams({column:this.column,colDef:this.column.getColDef()}))),!!e&&this.checkRightRowModelType("headerCheckboxSelection")&&this.checkSelectionType("headerCheckboxSelection")}isFilteredOnly(){return!!this.column.getColDef().headerCheckboxSelectionFilteredOnly}isCurrentPageOnly(){return!!this.column.getColDef().headerCheckboxSelectionCurrentPageOnly}};g([he("rowModel")],sl.prototype,"rowModel",2),g([he("selectionService")],sl.prototype,"selectionService",2);var ol=class extends el{constructor(e,t,i){super(e,t,i),this.refreshFunctions=[],this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map,this.column=e}setComp(e,t,i,r){this.comp=e,this.setGui(t),this.updateState(),this.setupWidth(),this.setupMovingCss(),this.setupMenuClass(),this.setupSortableClass(),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight(r),this.addColumnHoverListener(),this.setupFilterClass(),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(),this.setupSelectAll(),this.setupUserComp(),this.refreshAria(),this.resizeFeature=this.createManagedBean(new nl(this.getPinned(),this.column,i,e,this)),this.createManagedBean(new il([this.column],t)),this.createManagedBean(new tl(this.column,t,this.beans)),this.createManagedBean(new Pn(t,{shouldStopEventPropagation:e=>this.shouldStopEventPropagation(e),onTabKeyDown:()=>null,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addResizeAndMoveKeyboardListeners(),this.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader"],this.refresh.bind(this)),this.addManagedListener(this.column,be.EVENT_COL_DEF_CHANGED,this.refresh.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VALUE_CHANGED,this.onColumnValueChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,this.onColumnRowGroupChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_CHANGED,this.onColumnPivotChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_HEADER_HEIGHT_CHANGED,this.onHeaderHeightChanged.bind(this))}resizeHeader(e,t){var i,r;if(!this.column.isResizable())return;const n=this.column.getActualWidth(),s=null!=(i=this.column.getMinWidth())?i:0,o=null!=(r=this.column.getMaxWidth())?r:Number.MAX_SAFE_INTEGER,a=Math.min(Math.max(n+e,s),o);this.beans.columnModel.setColumnWidths([{key:this.column,newWidth:a}],t,!0,"uiColumnResized")}moveHeader(e){const{eGui:t,column:i,gos:r,ctrlsService:n}=this,s=this.getPinned(),o=t.getBoundingClientRect().left,a=i.getActualWidth(),l=0===e!==r.get("enableRtl"),c=Ua.normaliseX(l?o-20:o+a+20,s,!0,r,n);Ua.attemptMoveColumns({allMovingColumns:[i],isFromHeader:!0,hDirection:e,xPosition:c,pinned:s,fromEnter:!1,fakeEvent:!1,gos:r,columnModel:this.beans.columnModel}),n.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(i,"auto")}setupUserComp(){const e=this.lookupUserCompDetails();this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){const e=this.createParams(),t=this.column.getColDef();return this.userComponentFactory.getHeaderCompDetails(t,e)}createParams(){return this.gos.addGridCommonParams({column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&this.menuService.isHeaderFilterButtonEnabled(this.column),enableFilterIcon:!this.openFilterEnabled||this.menuService.isLegacyMenuEnabled(),showColumnMenu:e=>{this.menuService.showColumnMenu({column:this.column,buttonElement:e,positionBy:"button"})},showColumnMenuAfterMouseClick:e=>{this.menuService.showColumnMenu({column:this.column,mouseEvent:e,positionBy:"mouse"})},showFilter:e=>{this.menuService.showFilterMenu({column:this.column,buttonElement:e,containerType:"columnFilter",positionBy:"button"})},progressSort:e=>{this.beans.sortController.progressSort(this.column,!!e,"uiColumnSorted")},setSort:(e,t)=>{this.beans.sortController.setSortForColumn(this.column,e,!!t,"uiColumnSorted")},eGridHeader:this.getGui(),setTooltip:(e,t)=>{this.setupTooltip(e,t)}})}setupSelectAll(){this.selectAllFeature=this.createManagedBean(new sl(this.column)),this.selectAllFeature.setComp(this)}getSelectAllGui(){return this.selectAllFeature.getCheckboxGui()}handleKeyDown(e){super.handleKeyDown(e),e.key===Qr.SPACE&&this.selectAllFeature.onSpaceKeyDown(e),e.key===Qr.ENTER&&this.onEnterKeyDown(e),e.key===Qr.DOWN&&e.altKey&&this.showMenuOnKeyPress(e,!1)}onEnterKeyDown(e){if(e.ctrlKey||e.metaKey)this.showMenuOnKeyPress(e,!0);else if(this.sortable){const t=e.shiftKey;this.beans.sortController.progressSort(this.column,t,"uiColumnSorted")}}showMenuOnKeyPress(e,t){const i=this.comp.getUserCompInstance();i&&i instanceof Ss&&i.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){if(!this.getGui().contains(e.relatedTarget)){const e=this.getRowIndex();this.focusService.setFocusedHeader(e,this.column),this.announceAriaDescription()}this.focusService.isKeyboardMode()&&this.setActiveHeader(!0)}onFocusOut(e){this.getGui().contains(e.relatedTarget)||this.setActiveHeader(!1)}setupTooltip(e,t){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const i="whenTruncated"===this.gos.get("tooltipShowMode"),r=this.eGui,n=this.column.getColDef();t||!i||n.headerComponent||(t=()=>{const e=r.querySelector(".ag-header-cell-text");return!e||e.scrollWidth>e.clientWidth});const s={getColumn:()=>this.column,getColDef:()=>this.column.getColDef(),getGui:()=>r,getLocation:()=>"header",getTooltipValue:()=>null!=e?e:this.column.getColDef().headerTooltip,shouldDisplayTooltip:t},o=this.createManagedBean(new vn(s));this.refreshFunctions.push(()=>o.refreshToolTip())}setupClassesFromColDef(){const e=()=>{const e=this.column.getColDef(),t=da.getHeaderClassesFromColDef(e,this.gos,this.column,null),i=this.userHeaderClasses;this.userHeaderClasses=new Set(t),t.forEach(e=>{i.has(e)?i.delete(e):this.comp.addOrRemoveCssClass(e,!0)}),i.forEach(e=>this.comp.addOrRemoveCssClass(e,!1))};this.refreshFunctions.push(e),e()}setDragSource(e){if(this.dragSourceElement=e,this.removeDragSource(),!e||!this.draggable)return;const{column:t,beans:i,displayName:r,dragAndDropService:n,gos:s}=this,{columnModel:o}=i;let a=!this.gos.get("suppressDragLeaveHidesColumns");const l=this.dragSource={type:1,eElement:e,getDefaultIconName:()=>a?Vs.ICON_HIDE:Vs.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(t),dragItemName:r,onDragStarted:()=>{a=!s.get("suppressDragLeaveHidesColumns"),t.setMoving(!0,"uiColumnMoved")},onDragStopped:()=>t.setMoving(!1,"uiColumnMoved"),onGridEnter:e=>{var t;if(a){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!0,"uiColumnMoved")}},onGridExit:e=>{var t;if(a){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!1,"uiColumnMoved")}}};n.addDragSource(l,!0)}createDragItem(e){const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t}}updateState(){this.menuEnabled=this.menuService.isColumnMenuInHeaderEnabled(this.column),this.openFilterEnabled=this.menuService.isFilterMenuInHeaderEnabled(this.column),this.sortable=this.column.isSortable(),this.displayName=this.calculateDisplayName(),this.draggable=this.workOutDraggable()}addRefreshFunction(e){this.refreshFunctions.push(e)}refresh(){this.updateState(),this.refreshHeaderComp(),this.refreshAria(),this.refreshFunctions.forEach(e=>e())}refreshHeaderComp(){const e=this.lookupUserCompDetails();null!=this.comp.getUserCompInstance()&&this.userCompDetails.componentClass==e.componentClass&&this.attemptHeaderCompRefresh(e.params)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e)}attemptHeaderCompRefresh(e){const t=this.comp.getUserCompInstance();return!!t&&(!!t.refresh&&t.refresh(e))}calculateDisplayName(){return this.beans.columnModel.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){const e=this.column.getColDef();return!(this.gos.get("suppressMovableColumns")||e.suppressMovable||e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}onColumnRowGroupChanged(){this.checkDisplayName()}onColumnPivotChanged(){this.checkDisplayName()}onColumnValueChanged(){this.checkDisplayName()}setupWidth(){const e=()=>{const e=this.column.getActualWidth();this.comp.setWidth(`${e}px`)};this.addManagedListener(this.column,be.EVENT_WIDTH_CHANGED,e),e()}setupMovingCss(){const e=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-moving",this.column.isMoving())};this.addManagedListener(this.column,be.EVENT_MOVING_CHANGED,e),e()}setupMenuClass(){const e=()=>{this.comp.addOrRemoveCssClass("ag-column-menu-visible",this.column.isMenuVisible())};this.addManagedListener(this.column,be.EVENT_MENU_VISIBLE_CHANGED,e),e()}setupSortableClass(){const e=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-sortable",!!this.sortable)};e(),this.addRefreshFunction(e),this.addManagedListener(this.eventService,be.EVENT_SORT_CHANGED,this.refreshAriaSort.bind(this))}setupFilterClass(){const e=()=>{const e=this.column.isFilterActive();this.comp.addOrRemoveCssClass("ag-header-cell-filtered",e),this.refreshAria()};this.addManagedListener(this.column,be.EVENT_FILTER_ACTIVE_CHANGED,e),e()}setupWrapTextClass(){const e=()=>{const e=!!this.column.getColDef().wrapHeaderText;this.comp.addOrRemoveCssClass("ag-header-cell-wrap-text",e)};e(),this.addRefreshFunction(e)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){const{eGui:e,column:t,comp:i,beans:r}=this;if(!t.isSpanHeaderHeight())return e.style.removeProperty("top"),e.style.removeProperty("height"),i.addOrRemoveCssClass("ag-header-span-height",!1),void i.addOrRemoveCssClass("ag-header-span-total",!1);const{numberOfParents:n,isSpanningTotal:s}=this.column.getColumnGroupPaddingInfo();i.addOrRemoveCssClass("ag-header-span-height",n>0);const{columnModel:o}=r,a=o.getColumnHeaderRowHeight();if(0===n)return i.addOrRemoveCssClass("ag-header-span-total",!1),e.style.setProperty("top","0px"),void e.style.setProperty("height",`${a}px`);i.addOrRemoveCssClass("ag-header-span-total",s);const l=n*(o.isPivotMode()?o.getPivotGroupHeaderHeight():o.getGroupHeaderHeight());e.style.setProperty("top",-l+"px"),e.style.setProperty("height",`${a+l}px`)}setupAutoHeight(e){const{columnModel:t,resizeObserverService:i}=this.beans,r=i=>{if(!this.isAlive())return;const{paddingTop:n,paddingBottom:s,borderBottomWidth:o,borderTopWidth:a}=ur(this.getGui()),l=n+s+o+a,c=e.offsetHeight+l;if(i<5){const t=this.beans.gos.getDocument();if(!t||!t.contains(e)||0==c)return void window.setTimeout(()=>r(i+1),0)}t.setColumnHeaderHeight(this.column,c)};let n,s=!1;const o=()=>{const e=this.column.isAutoHeaderHeight();e&&!s&&a(),!e&&s&&l()},a=()=>{s=!0,r(0),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!0),n=i.observeResize(e,()=>r(0))},l=()=>{s=!1,n&&n(),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!1),n=void 0};o(),this.addDestroyFunc(()=>l()),this.addManagedListener(this.column,be.EVENT_WIDTH_CHANGED,()=>s&&r(0)),this.addManagedListener(this.eventService,be.EVENT_SORT_CHANGED,()=>{s&&window.setTimeout(()=>r(0))}),this.addRefreshFunction(o)}refreshAriaSort(){if(this.sortable){const e=this.localeService.getLocaleTextFunc(),t=this.beans.sortController.getDisplaySortForColumn(this.column)||null;this.comp.setAriaSort(zt(t)),this.setAriaDescriptionProperty("sort",e("ariaSortableColumn","Press ENTER to sort"))}else this.comp.setAriaSort(),this.setAriaDescriptionProperty("sort",null)}refreshAriaMenu(){if(this.menuEnabled){const e=this.localeService.getLocaleTextFunc();this.setAriaDescriptionProperty("menu",e("ariaMenuColumn","Press ALT DOWN to open column menu"))}else this.setAriaDescriptionProperty("menu",null)}refreshAriaFilterButton(){if(this.openFilterEnabled&&!this.menuService.isLegacyMenuEnabled()){const e=this.localeService.getLocaleTextFunc();this.setAriaDescriptionProperty("filterButton",e("ariaFilterColumn","Press CTRL ENTER to open filter"))}else this.setAriaDescriptionProperty("filterButton",null)}refreshAriaFiltered(){const e=this.localeService.getLocaleTextFunc();this.column.isFilterActive()?this.setAriaDescriptionProperty("filter",e("ariaColumnFiltered","Column Filtered")):this.setAriaDescriptionProperty("filter",null)}setAriaDescriptionProperty(e,t){null!=t?this.ariaDescriptionProperties.set(e,t):this.ariaDescriptionProperties.delete(e)}announceAriaDescription(){if(!this.eGui.contains(this.beans.gos.getActiveDomElement()))return;const e=Array.from(this.ariaDescriptionProperties.keys()).sort((e,t)=>"filter"===e?-1:t.charCodeAt(0)-e.charCodeAt(0)).map(e=>this.ariaDescriptionProperties.get(e)).join(". ");this.beans.ariaAnnouncementService.announceValue(e)}refreshAria(){this.refreshAriaSort(),this.refreshAriaMenu(),this.refreshAriaFilterButton(),this.refreshAriaFiltered()}addColumnHoverListener(){const e=()=>{if(!this.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.comp.addOrRemoveCssClass("ag-column-hover",e)};this.addManagedListener(this.eventService,ct.EVENT_COLUMN_HOVER_CHANGED,e),e()}getColId(){return this.column.getColId()}addActiveHeaderMouseListeners(){const e=e=>this.handleMouseOverChange("mouseenter"===e.type);this.addManagedListener(this.getGui(),"mouseenter",e),this.addManagedListener(this.getGui(),"mouseleave",e),this.addManagedListener(this.getGui(),"click",()=>this.dispatchColumnMouseEvent(ct.EVENT_COLUMN_HEADER_CLICKED,this.column)),this.addManagedListener(this.getGui(),"contextmenu",e=>this.handleContextMenuMouseEvent(e,void 0,this.column))}handleMouseOverChange(e){this.setActiveHeader(e);const t={type:e?ct.EVENT_COLUMN_HEADER_MOUSE_OVER:ct.EVENT_COLUMN_HEADER_MOUSE_LEAVE,column:this.column};this.eventService.dispatchEvent(t)}setActiveHeader(e){this.comp.addOrRemoveCssClass("ag-header-active",e)}getAnchorElementForMenu(e){const t=this.comp.getUserCompInstance();return t instanceof Ss?t.getAnchorElementForMenu(e):this.getGui()}destroy(){super.destroy(),this.refreshFunctions=null,this.selectAllFeature=null,this.dragSourceElement=null,this.userCompDetails=null,this.userHeaderClasses=null,this.ariaDescriptionProperties=null}},al=class extends nt{constructor(e,t,i,r){super(),this.eResize=t,this.comp=e,this.pinned=i,this.columnGroup=r}postConstruct(){if(!this.columnGroup.isResizable())return void this.comp.setResizableDisplayed(!1);const e=this.horizontalResizeService.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});if(this.addDestroyFunc(e),!this.gos.get("suppressAutoSize")){const e=this.gos.get("skipHeaderOnAutoSize");this.eResize.addEventListener("dblclick",()=>{const t=[];this.columnGroup.getDisplayedLeafColumns().forEach(e=>{e.getColDef().suppressAutoSize||t.push(e.getColId())}),t.length>0&&this.columnModel.autoSizeColumns({columns:t,skipHeader:e,stopAtGroup:this.columnGroup,source:"uiColumnResized"}),this.resizeLeafColumnsToFit("uiColumnResized")})}}onResizeStart(e){const t=this.getInitialValues(e);this.storeLocalValues(t),this.toggleColumnResizing(!0)}onResizing(e,t,i="uiColumnResized"){const r=this.normaliseDragChange(t),n=this.resizeStartWidth+r;this.resizeColumnsFromLocalValues(n,i,e)}getInitialValues(e){const t=this.getColumnsToResize(),i=this.getInitialSizeOfColumns(t),r={columnsToResize:t,resizeStartWidth:i,resizeRatios:this.getSizeRatiosOfColumns(t,i)};let n=null;if(e&&(n=this.columnModel.getDisplayedGroupAtDirection(this.columnGroup,"After")),n){const e=n.getDisplayedLeafColumns(),t=r.groupAfterColumns=e.filter(e=>e.isResizable()),i=r.groupAfterStartWidth=this.getInitialSizeOfColumns(t);r.groupAfterRatios=this.getSizeRatiosOfColumns(t,i)}else r.groupAfterColumns=void 0,r.groupAfterStartWidth=void 0,r.groupAfterRatios=void 0;return r}storeLocalValues(e){const{columnsToResize:t,resizeStartWidth:i,resizeRatios:r,groupAfterColumns:n,groupAfterStartWidth:s,groupAfterRatios:o}=e;this.resizeCols=t,this.resizeStartWidth=i,this.resizeRatios=r,this.resizeTakeFromCols=n,this.resizeTakeFromStartWidth=s,this.resizeTakeFromRatios=o}clearLocalValues(){this.resizeCols=void 0,this.resizeRatios=void 0,this.resizeTakeFromCols=void 0,this.resizeTakeFromRatios=void 0}resizeLeafColumnsToFit(e){const t=this.autoWidthCalculator.getPreferredWidthForColumnGroup(this.columnGroup),i=this.getInitialValues();t>i.resizeStartWidth&&this.resizeColumns(i,t,e,!0)}resizeColumnsFromLocalValues(e,t,i=!0){var r,n,s;if(!this.resizeCols||!this.resizeRatios)return;const o={columnsToResize:this.resizeCols,resizeStartWidth:this.resizeStartWidth,resizeRatios:this.resizeRatios,groupAfterColumns:null!=(r=this.resizeTakeFromCols)?r:void 0,groupAfterStartWidth:null!=(n=this.resizeTakeFromStartWidth)?n:void 0,groupAfterRatios:null!=(s=this.resizeTakeFromRatios)?s:void 0};this.resizeColumns(o,e,t,i)}resizeColumns(e,t,i,r=!0){const{columnsToResize:n,resizeStartWidth:s,resizeRatios:o,groupAfterColumns:a,groupAfterStartWidth:l,groupAfterRatios:c}=e,u=[];if(u.push({columns:n,ratios:o,width:t}),a){const e=t-s;u.push({columns:a,ratios:c,width:l-e})}this.columnModel.resizeColumnSets({resizeSets:u,finished:r,source:i}),r&&this.toggleColumnResizing(!1)}toggleColumnResizing(e){this.comp.addOrRemoveCssClass("ag-column-resizing",e)}getColumnsToResize(){return this.columnGroup.getDisplayedLeafColumns().filter(e=>e.isResizable())}getInitialSizeOfColumns(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}getSizeRatiosOfColumns(e,t){return e.map(e=>e.getActualWidth()/t)}normaliseDragChange(e){let t=e;return this.gos.get("enableRtl")?"left"!==this.pinned&&(t*=-1):"right"===this.pinned&&(t*=-1),t}destroy(){super.destroy(),this.clearLocalValues()}};g([he("horizontalResizeService")],al.prototype,"horizontalResizeService",2),g([he("autoWidthCalculator")],al.prototype,"autoWidthCalculator",2),g([he("columnModel")],al.prototype,"columnModel",2),g([le],al.prototype,"postConstruct",1);var ll=class extends nt{constructor(e,t){super(),this.removeChildListenersFuncs=[],this.columnGroup=t,this.comp=e}postConstruct(){this.addListenersToChildrenColumns(),this.addManagedListener(this.columnGroup,lt.EVENT_DISPLAYED_CHILDREN_CHANGED,this.onDisplayedChildrenChanged.bind(this)),this.onWidthChanged(),this.addDestroyFunc(this.removeListenersOnChildrenColumns.bind(this))}addListenersToChildrenColumns(){this.removeListenersOnChildrenColumns();const e=this.onWidthChanged.bind(this);this.columnGroup.getLeafColumns().forEach(t=>{t.addEventListener("widthChanged",e),t.addEventListener("visibleChanged",e),this.removeChildListenersFuncs.push(()=>{t.removeEventListener("widthChanged",e),t.removeEventListener("visibleChanged",e)})})}removeListenersOnChildrenColumns(){this.removeChildListenersFuncs.forEach(e=>e()),this.removeChildListenersFuncs=[]}onDisplayedChildrenChanged(){this.addListenersToChildrenColumns(),this.onWidthChanged()}onWidthChanged(){const e=this.columnGroup.getActualWidth();this.comp.setWidth(`${e}px`),this.comp.addOrRemoveCssClass("ag-hidden",0===e)}};g([le],ll.prototype,"postConstruct",1);var cl=class extends el{constructor(e,t,i){super(e,t,i),this.onSuppressColMoveChange=()=>{if(!this.isAlive()||this.isSuppressMoving())this.removeDragSource();else if(!this.dragSource){const e=this.getGui();this.setDragSource(e)}},this.column=e}setComp(e,t,i){this.comp=e,this.setGui(t),this.displayName=this.beans.columnModel.getDisplayNameForColumnGroup(this.column,"header"),this.addClasses(),this.setupMovingCss(),this.setupExpandable(),this.setupTooltip(),this.addDestroyFunc(()=>{this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature))}),this.setupUserComp(),this.addHeaderMouseListeners();const r=this.getParentRowCtrl().getPinned(),n=this.column.getProvidedColumnGroup().getLeafColumns();this.createManagedBean(new il(n,t)),this.createManagedBean(new tl(this.column,t,this.beans)),this.createManagedBean(new ll(e,this.column)),this.resizeFeature=this.createManagedBean(new al(e,i,r,this.column)),this.createManagedBean(new Pn(t,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:()=>{},handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)})),this.addManagedPropertyListener(ct.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED,this.onSuppressColMoveChange),this.addResizeAndMoveKeyboardListeners()}resizeHeader(e,t){if(!this.resizeFeature)return;const i=this.resizeFeature.getInitialValues(t);this.resizeFeature.resizeColumns(i,i.resizeStartWidth+e,"uiColumnResized",!0)}moveHeader(e){const{beans:t,eGui:i,column:r,gos:n,ctrlsService:s}=this,o=n.get("enableRtl"),a=0===e,l=this.getPinned(),c=i.getBoundingClientRect(),u=c.left,h=c.width,d=Ua.normaliseX(a!==o?u-20:u+h+20,l,!0,n,s),p=r.getGroupId(),g=this.focusService.getFocusedHeader();Ua.attemptMoveColumns({allMovingColumns:this.column.getLeafColumns(),isFromHeader:!0,hDirection:e,xPosition:d,pinned:l,fromEnter:!1,fakeEvent:!1,gos:n,columnModel:t.columnModel});const f=r.getDisplayedLeafColumns(),m=a?f[0]:Pe(f);this.ctrlsService.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(m,"auto"),!this.isAlive()&&g&&this.restoreFocus(p,r,g)}restoreFocus(e,t,i){const r=t.getLeafColumns();if(!r.length)return;const n=r[0].getParent();if(!n)return;const s=this.findGroupWidthId(n,e);s&&this.focusService.focusHeaderPosition({headerPosition:d(h({},i),{column:s})})}findGroupWidthId(e,t){for(;e;){if(e.getGroupId()===t)return e;e=e.getParent()}return null}resizeLeafColumnsToFit(e){this.resizeFeature&&this.resizeFeature.resizeLeafColumnsToFit(e)}setupUserComp(){const e=this.gos.addGridCommonParams({displayName:this.displayName,columnGroup:this.column,setExpanded:e=>{this.beans.columnModel.setColumnGroupOpened(this.column.getProvidedColumnGroup(),e,"gridInitializing")},setTooltip:(e,t)=>{this.setupTooltip(e,t)}}),t=this.userComponentFactory.getHeaderGroupCompDetails(e);this.comp.setUserCompDetails(t)}addHeaderMouseListeners(){const e=e=>this.handleMouseOverChange("mouseenter"===e.type);this.addManagedListener(this.getGui(),"mouseenter",e),this.addManagedListener(this.getGui(),"mouseleave",e),this.addManagedListener(this.getGui(),"click",()=>this.dispatchColumnMouseEvent(ct.EVENT_COLUMN_HEADER_CLICKED,this.column.getProvidedColumnGroup())),this.addManagedListener(this.getGui(),"contextmenu",e=>this.handleContextMenuMouseEvent(e,void 0,this.column.getProvidedColumnGroup()))}handleMouseOverChange(e){const t={type:e?ct.EVENT_COLUMN_HEADER_MOUSE_OVER:ct.EVENT_COLUMN_HEADER_MOUSE_LEAVE,column:this.column.getProvidedColumnGroup()};this.eventService.dispatchEvent(t)}setupTooltip(e,t){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const i=this.column.getColGroupDef(),r="whenTruncated"===this.gos.get("tooltipShowMode"),n=this.eGui;t||!r||(null==i?void 0:i.headerGroupComponent)||(t=()=>{const e=n.querySelector(".ag-header-group-text");return!e||e.scrollWidth>e.clientWidth});const s={getColumn:()=>this.column,getGui:()=>n,getLocation:()=>"headerGroup",getTooltipValue:()=>null!=e?e:i&&i.headerTooltip,shouldDisplayTooltip:t};i&&(s.getColDef=()=>i),this.createBean(new vn(s))}setupExpandable(){const e=this.column.getProvidedColumnGroup();this.refreshExpanded(),this.addManagedListener(e,Ae.EVENT_EXPANDABLE_CHANGED,this.refreshExpanded.bind(this)),this.addManagedListener(e,Ae.EVENT_EXPANDED_CHANGED,this.refreshExpanded.bind(this))}refreshExpanded(){const e=this.column;this.expandable=e.isExpandable();const t=e.isExpanded();this.expandable?this.comp.setAriaExpanded(t?"true":"false"):this.comp.setAriaExpanded(void 0)}getColId(){return this.column.getUniqueId()}addClasses(){const e=this.column.getColGroupDef(),t=da.getHeaderClassesFromColDef(e,this.gos,null,this.column);this.column.isPadding()?(t.push("ag-header-group-cell-no-group"),this.column.getLeafColumns().every(e=>e.isSpanHeaderHeight())&&t.push("ag-header-span-height")):t.push("ag-header-group-cell-with-group"),t.forEach(e=>this.comp.addOrRemoveCssClass(e,!0))}setupMovingCss(){const e=this.column.getProvidedColumnGroup().getLeafColumns(),t=()=>this.comp.addOrRemoveCssClass("ag-header-cell-moving",this.column.isMoving());e.forEach(e=>{this.addManagedListener(e,be.EVENT_MOVING_CHANGED,t)}),t()}onFocusIn(e){if(!this.eGui.contains(e.relatedTarget)){const e=this.getRowIndex();this.beans.focusService.setFocusedHeader(e,this.column)}}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();if(this.expandable&&t&&e.key===Qr.ENTER){const e=this.column,t=!e.isExpanded();this.beans.columnModel.setColumnGroupOpened(e.getProvidedColumnGroup(),t,"uiColumnExpanded")}}setDragSource(e){if(!this.isAlive()||this.isSuppressMoving())return;if(this.removeDragSource(),!e)return;const{beans:t,column:i,displayName:r,gos:n,dragAndDropService:s}=this,{columnModel:o}=t,a=i.getProvidedColumnGroup().getLeafColumns();let l=!n.get("suppressDragLeaveHidesColumns");const c=this.dragSource={type:1,eElement:e,getDefaultIconName:()=>l?Vs.ICON_HIDE:Vs.ICON_NOT_ALLOWED,dragItemName:r,getDragItem:()=>this.getDragItemForGroup(i),onDragStarted:()=>{l=!n.get("suppressDragLeaveHidesColumns"),a.forEach(e=>e.setMoving(!0,"uiColumnDragged"))},onDragStopped:()=>a.forEach(e=>e.setMoving(!1,"uiColumnDragged")),onGridEnter:e=>{var t;if(l){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!0,"uiColumnMoved")}},onGridExit:e=>{var t;if(l){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!1,"uiColumnMoved")}}};s.addDragSource(c,!0)}getDragItemForGroup(e){const t=e.getProvidedColumnGroup().getLeafColumns(),i={};t.forEach(e=>i[e.getId()]=e.isVisible());const r=[];return this.beans.columnModel.getAllDisplayedColumns().forEach(e=>{t.indexOf(e)>=0&&(r.push(e),Oe(t,e))}),t.forEach(e=>r.push(e)),{columns:r,visibleState:i}}isSuppressMoving(){let e=!1;return this.column.getLeafColumns().forEach(t=>{(t.getColDef().suppressMovable||t.getColDef().lockPosition)&&(e=!0)}),e||this.gos.get("suppressMovableColumns")}},ul=0,hl=class extends nt{constructor(e,t,i){super(),this.instanceId=ul++,this.rowIndex=e,this.pinned=t,this.type=i;const r="group"==i?"ag-header-row-column-group":"filter"==i?"ag-header-row-column-filter":"ag-header-row-column";this.headerRowClass=`ag-header-row ${r}`}postConstruct(){this.isPrintLayout=this.gos.isDomLayout("print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}getInstanceId(){return this.instanceId}setComp(e,t=!0){this.comp=e,t&&(this.onRowHeightChanged(),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners()}getHeaderRowClass(){return this.headerRowClass}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(){this.addManagedListener(this.eventService,ct.EVENT_COLUMN_RESIZED,this.onColumnResized.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_VIRTUAL_COLUMNS_CHANGED,e=>this.onVirtualColumnsChanged(e.afterScroll)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_GRID_STYLES_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("domLayout",this.onDisplayedColumnsChanged.bind(this)),this.addManagedPropertyListener("ensureDomOrder",e=>this.isEnsureDomOrder=e.currentValue),this.addManagedPropertyListener("headerHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("pivotHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("groupHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("pivotGroupHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("floatingFiltersHeight",this.onRowHeightChanged.bind(this))}getHeaderCellCtrl(e){if(this.headerCellCtrls)return _(this.headerCellCtrls).find(t=>t.getColumnGroupChild()===e)}onDisplayedColumnsChanged(){this.isPrintLayout=this.gos.isDomLayout("print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}getType(){return this.type}onColumnResized(){this.setWidth()}setWidth(){const e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){const{columnModel:e}=this.beans;return this.isPrintLayout?null!=this.pinned?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null):e.getContainerWidth(this.pinned)}onRowHeightChanged(){var{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){const{columnModel:e,filterManager:t}=this.beans;let i=e.getHeaderRowCount();const r=[];let n=0;t.hasFloatingFilters()&&(i++,n=1);const s=e.getColumnGroupHeaderRowHeight(),o=e.getColumnHeaderRowHeight(),a=i-(1+n);for(let e=0;e<a;e++)r.push(s);r.push(o);for(let t=0;t<n;t++)r.push(e.getFloatingFiltersHeight());let l=0;for(let e=0;e<this.rowIndex;e++)l+=r[e];return{topOffset:l,rowHeight:r[this.rowIndex]}}getPinned(){return this.pinned}getRowIndex(){return this.rowIndex}onVirtualColumnsChanged(e=!1){const t=this.getHeaderCtrls(),i=this.isEnsureDomOrder||this.isPrintLayout;this.comp.setHeaderCtrls(t,i,e)}getHeaderCtrls(){const e=this.headerCellCtrls;this.headerCellCtrls=new Map;const t=this.getColumnsInViewport();for(const i of t)this.recycleAndCreateHeaderCtrls(i,e);const i=e=>{const{focusService:t,columnModel:i}=this.beans;return!!t.isHeaderWrapperFocused(e)&&i.isDisplayed(e.getColumnGroupChild())};if(e)for(const[t,r]of e)i(r)?this.headerCellCtrls.set(t,r):this.destroyBean(r);return Array.from(this.headerCellCtrls.values())}recycleAndCreateHeaderCtrls(e,t){if(!this.headerCellCtrls)return;if(e.isEmptyGroup())return;const i=e.getUniqueId();let r;if(t&&(r=t.get(i),t.delete(i)),r&&r.getColumnGroupChild()!=e&&(this.destroyBean(r),r=void 0),null==r)switch(this.type){case"filter":r=this.createBean(new rl(e,this.beans,this));break;case"group":r=this.createBean(new cl(e,this.beans,this));break;default:r=this.createBean(new ol(e,this.beans,this))}this.headerCellCtrls.set(i,r)}getColumnsInViewport(){return this.isPrintLayout?this.getColumnsInViewportPrintLayout():this.getColumnsInViewportNormalLayout()}getColumnsInViewportPrintLayout(){if(null!=this.pinned)return[];let e=[];const t=this.getActualDepth(),{columnModel:i}=this.beans;return["left",null,"right"].forEach(r=>{const n=i.getVirtualHeaderGroupRow(r,t);e=e.concat(n)}),e}getActualDepth(){return"filter"==this.type?this.rowIndex-1:this.rowIndex}getColumnsInViewportNormalLayout(){return this.beans.columnModel.getVirtualHeaderGroupRow(this.pinned,this.getActualDepth())}focusHeader(e,t){if(!this.headerCellCtrls)return!1;const i=Array.from(this.headerCellCtrls.values()).find(t=>t.getColumnGroupChild()==e);return!!i&&i.focus(t)}destroy(){this.headerCellCtrls&&this.headerCellCtrls.forEach(e=>{this.destroyBean(e)}),this.headerCellCtrls=void 0,super.destroy()}};g([he("beans")],hl.prototype,"beans",2),g([le],hl.prototype,"postConstruct",1);var dl=class extends nt{constructor(e){super(),this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[],this.pinned=e}setComp(e,t){this.comp=e,this.eViewport=t,this.setupCenterWidth(),this.setupPinnedWidth(),this.setupDragAndDrop(this.eViewport),this.addManagedListener(this.eventService,ct.EVENT_GRID_COLUMNS_CHANGED,this.onGridColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.ctrlsService.registerHeaderContainer(this,this.pinned),this.columnModel.isReady()&&this.refresh()}setupDragAndDrop(e){const t=new ja(this.pinned,e);this.createManagedBean(t)}refresh(e=!1){const t=new un,i=this.focusService.getFocusHeaderToUseAfterRefresh();(()=>{const e=this.columnModel.getHeaderRowCount()-1;this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls);for(let i=0;i<e;i++){const e=this.createBean(new hl(t.next(),this.pinned,"group"));this.groupsRowCtrls.push(e)}})(),(()=>{const i=t.next(),r=!(this.hidden||null!=this.columnsRowCtrl&&e&&this.columnsRowCtrl.getRowIndex()===i);(r||this.hidden)&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),r&&(this.columnsRowCtrl=this.createBean(new hl(i,this.pinned,"column")))})(),(()=>{this.includeFloatingFilter=this.filterManager.hasFloatingFilters()&&!this.hidden;const i=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter)return void i();const r=t.next();if(this.filtersRowCtrl){const t=this.filtersRowCtrl.getRowIndex()!==r;e&&!t||i()}this.filtersRowCtrl||(this.filtersRowCtrl=this.createBean(new hl(r,this.pinned,"filter")))})();const r=this.getAllCtrls();this.comp.setCtrls(r),this.restoreFocusOnHeader(i)}restoreFocusOnHeader(e){null!=e&&e.column.getPinned()==this.pinned&&this.focusService.focusHeaderPosition({headerPosition:e})}getAllCtrls(){const e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}onGridColumnsChanged(){this.refresh(!0)}onDisplayedColumnsChanged(){const e=this.filterManager.hasFloatingFilters()&&!this.hidden;this.includeFloatingFilter!==e&&this.refresh(!0)}setupCenterWidth(){null==this.pinned&&this.createManagedBean(new Ta(e=>this.comp.setCenterWidth(`${e}px`),!0))}setHorizontalScroll(e){this.comp.setViewportScrollLeft(e)}setupPinnedWidth(){if(null==this.pinned)return;const e="left"===this.pinned,t="right"===this.pinned;this.hidden=!0;const i=()=>{const i=e?this.pinnedWidthService.getPinnedLeftWidth():this.pinnedWidthService.getPinnedRightWidth();if(null==i)return;const r=0==i,n=this.hidden!==r,s=this.gos.get("enableRtl"),o=this.gos.getScrollbarWidth(),a=this.scrollVisibleService.isVerticalScrollShowing()&&(s&&e||!s&&t)?i+o:i;this.comp.setPinnedContainerWidth(`${a}px`),this.comp.setDisplayed(!r),n&&(this.hidden=r,this.refresh())};this.addManagedListener(this.eventService,ct.EVENT_LEFT_PINNED_WIDTH_CHANGED,i),this.addManagedListener(this.eventService,ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED,i),this.addManagedListener(this.eventService,ct.EVENT_SCROLL_VISIBILITY_CHANGED,i),this.addManagedListener(this.eventService,ct.EVENT_SCROLLBAR_WIDTH_CHANGED,i)}getHeaderCtrlForColumn(e){if(e instanceof be){if(!this.columnsRowCtrl)return;return this.columnsRowCtrl.getHeaderCellCtrl(e)}if(0!==this.groupsRowCtrls.length)for(let t=0;t<this.groupsRowCtrls.length;t++){const i=this.groupsRowCtrls[t].getHeaderCellCtrl(e);if(i)return i}}getHtmlElementForColumnHeader(e){const t=this.getHeaderCtrlForColumn(e);return t?t.getGui():null}getRowType(e){const t=this.getAllCtrls()[e];return t?t.getType():void 0}focusHeader(e,t,i){const r=this.getAllCtrls()[e];return!!r&&r.focusHeader(t,i)}getViewport(){return this.eViewport}getRowCount(){return this.groupsRowCtrls.length+(this.columnsRowCtrl?1:0)+(this.filtersRowCtrl?1:0)}destroy(){this.filtersRowCtrl&&(this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)),this.columnsRowCtrl&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),this.groupsRowCtrls&&this.groupsRowCtrls.length&&(this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls)),super.destroy()}};g([he("ctrlsService")],dl.prototype,"ctrlsService",2),g([he("scrollVisibleService")],dl.prototype,"scrollVisibleService",2),g([he("pinnedWidthService")],dl.prototype,"pinnedWidthService",2),g([he("columnModel")],dl.prototype,"columnModel",2),g([he("focusService")],dl.prototype,"focusService",2),g([he("filterManager")],dl.prototype,"filterManager",2);var pl=class e extends wn{constructor(e){super(),this.headerRowComps={},this.rowCompsList=[],this.pinned=e}init(){this.selectAndSetTemplate();const e={setDisplayed:e=>this.setDisplayed(e),setCtrls:e=>this.setCtrls(e),setCenterWidth:e=>this.eCenterContainer.style.width=e,setViewportScrollLeft:e=>this.getGui().scrollLeft=e,setPinnedContainerWidth:e=>{const t=this.getGui();t.style.width=e,t.style.maxWidth=e,t.style.minWidth=e}};this.createManagedBean(new dl(this.pinned)).setComp(e,this.getGui())}selectAndSetTemplate(){const t="left"==this.pinned,i="right"==this.pinned,r=t?e.PINNED_LEFT_TEMPLATE:i?e.PINNED_RIGHT_TEMPLATE:e.CENTER_TEMPLATE;this.setTemplate(r),this.eRowContainer=this.eCenterContainer?this.eCenterContainer:this.getGui()}destroyRowComps(){this.setCtrls([])}destroyRowComp(e){this.destroyBean(e),this.eRowContainer.removeChild(e.getGui())}setCtrls(e){const t=this.headerRowComps;let i;this.headerRowComps={},this.rowCompsList=[];const r=e=>{const t=e.getGui();t.parentElement!=this.eRowContainer&&this.eRowContainer.appendChild(t),i&&Ar(this.eRowContainer,t,i),i=t};e.forEach(e=>{const i=e.getInstanceId(),n=t[i];delete t[i];const s=n||this.createBean(new Xa(e));this.headerRowComps[i]=s,this.rowCompsList.push(s),r(s)}),O(t).forEach(e=>this.destroyRowComp(e))}};pl.PINNED_LEFT_TEMPLATE='<div class="ag-pinned-left-header" role="rowgroup"></div>',pl.PINNED_RIGHT_TEMPLATE='<div class="ag-pinned-right-header" role="rowgroup"></div>',pl.CENTER_TEMPLATE='<div class="ag-header-viewport" role="presentation">\n            <div class="ag-header-container" ref="eCenterContainer" role="rowgroup"></div>\n        </div>',g([bn("eCenterContainer")],pl.prototype,"eCenterContainer",2),g([le],pl.prototype,"init",1),g([ce],pl.prototype,"destroyRowComps",1);var gl=pl,fl=(e=>(e[e.UP=0]="UP",e[e.DOWN=1]="DOWN",e[e.LEFT=2]="LEFT",e[e.RIGHT=3]="RIGHT",e))(fl||{}),ml=class extends nt{constructor(){super(...arguments),this.currentHeaderRowWithoutSpan=-1}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl});const e=this.gos.getDocument();this.addManagedListener(e,"mousedown",()=>this.setCurrentHeaderRowWithoutSpan(-1))}getHeaderRowCount(){const e=this.ctrlsService.getHeaderRowContainerCtrl();return e?e.getRowCount():0}navigateVertically(e,t,i){if(t||(t=this.focusService.getFocusedHeader()),!t)return!1;const{headerRowIndex:r,column:n}=t,s=this.getHeaderRowCount(),o=0===e;let{headerRowIndex:a,column:l,headerRowIndexWithoutSpan:c}=o?this.headerPositionUtils.getColumnVisibleParent(n,r):this.headerPositionUtils.getColumnVisibleChild(n,r),u=!1;return a<0&&(a=0,l=n,u=!0),a>=s?(a=-1,this.setCurrentHeaderRowWithoutSpan(-1)):void 0!==c&&(this.currentHeaderRowWithoutSpan=c),!(!u&&!l)&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:a,column:l},allowUserOverride:!0,event:i})}setCurrentHeaderRowWithoutSpan(e){this.currentHeaderRowWithoutSpan=e}navigateHorizontally(e,t=!1,i){const r=this.focusService.getFocusedHeader(),n=2===e,s=this.gos.get("enableRtl");let o,a;if(-1!==this.currentHeaderRowWithoutSpan?r.headerRowIndex=this.currentHeaderRowWithoutSpan:this.currentHeaderRowWithoutSpan=r.headerRowIndex,n!==s?(a="Before",o=this.headerPositionUtils.findHeader(r,a)):(a="After",o=this.headerPositionUtils.findHeader(r,a)),o||!t)return this.focusService.focusHeaderPosition({headerPosition:o,direction:a,fromTab:t,allowUserOverride:!0,event:i});if(t){const e=this.gos.getCallback("tabToNextHeader");if(e)return this.focusService.focusHeaderPositionFromUserFunc({userFunc:e,headerPosition:o,direction:a})}return this.focusNextHeaderRow(r,a,i)}focusNextHeaderRow(e,t,i){const r=e.headerRowIndex;let n,s=null;if("Before"===t?r>0&&(n=r-1,this.currentHeaderRowWithoutSpan-=1,s=this.headerPositionUtils.findColAtEdgeForHeaderRow(n,"end")):(n=r+1,this.currentHeaderRowWithoutSpan<this.getHeaderRowCount()?this.currentHeaderRowWithoutSpan+=1:this.setCurrentHeaderRowWithoutSpan(-1),s=this.headerPositionUtils.findColAtEdgeForHeaderRow(n,"start")),!s)return!1;const{column:o,headerRowIndex:a}=this.headerPositionUtils.getHeaderIndexToFocus(s.column,null==s?void 0:s.headerRowIndex);return this.focusService.focusHeaderPosition({headerPosition:{column:o,headerRowIndex:a},direction:t,fromTab:!0,allowUserOverride:!0,event:i})}scrollToColumn(e,t="After"){if(e.getPinned())return;let i;if(e instanceof lt){const r=e.getDisplayedLeafColumns();i="Before"===t?Pe(r):r[0]}else i=e;this.gridBodyCon.getScrollFeature().ensureColumnVisible(i)}};g([he("focusService")],ml.prototype,"focusService",2),g([he("headerPositionUtils")],ml.prototype,"headerPositionUtils",2),g([he("ctrlsService")],ml.prototype,"ctrlsService",2),g([le],ml.prototype,"postConstruct",1),ml=g([ue("headerNavigationService")],ml);var vl=class extends nt{setComp(e,t,i){this.comp=e,this.eGui=t,this.createManagedBean(new Pn(i,{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onPivotModeChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.onPivotModeChanged(),this.setupHeaderHeight();const r=this.onHeaderContextMenu.bind(this);this.addManagedListener(this.eGui,"contextmenu",r),this.mockContextMenuForIPad(r),this.ctrlsService.register("gridHeaderCtrl",this)}setupHeaderHeight(){const e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListener("headerHeight",e),this.addManagedPropertyListener("pivotHeaderHeight",e),this.addManagedPropertyListener("groupHeaderHeight",e),this.addManagedPropertyListener("pivotGroupHeaderHeight",e),this.addManagedPropertyListener("floatingFiltersHeight",e),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_GRID_STYLES_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,e)}getHeaderHeight(){return this.headerHeight}setHeaderHeight(){const{columnModel:e}=this;let t,i=0,r=e.getHeaderRowCount();this.filterManager.hasFloatingFilters()&&(r++,i=1);const n=this.columnModel.getColumnGroupHeaderRowHeight(),s=this.columnModel.getColumnHeaderRowHeight(),o=r-(1+i);if(t=i*e.getFloatingFiltersHeight(),t+=o*n,t+=s,this.headerHeight===t)return;this.headerHeight=t;const a=`${t+1}px`;this.comp.setHeightAndMinHeight(a),this.eventService.dispatchEvent({type:ct.EVENT_HEADER_HEIGHT_CHANGED})}onPivotModeChanged(){const e=this.columnModel.isPivotMode();this.comp.addOrRemoveCssClass("ag-pivot-on",e),this.comp.addOrRemoveCssClass("ag-pivot-off",!e)}onDisplayedColumnsChanged(){const e=this.columnModel.getAllDisplayedColumns().some(e=>e.isSpanHeaderHeight());this.comp.addOrRemoveCssClass("ag-header-allow-overflow",e)}onTabKeyDown(e){const t=this.gos.get("enableRtl"),i=e.shiftKey!==t?2:3;(this.headerNavigationService.navigateHorizontally(i,!0,e)||this.focusService.focusNextGridCoreContainer(e.shiftKey))&&e.preventDefault()}handleKeyDown(e){let t=null;switch(e.key){case Qr.LEFT:t=2;case Qr.RIGHT:y(t)||(t=3),this.headerNavigationService.navigateHorizontally(t,!1,e);break;case Qr.UP:t=0;case Qr.DOWN:y(t)||(t=1),this.headerNavigationService.navigateVertically(t,null,e)&&e.preventDefault();break;default:return}}onFocusOut(e){const{relatedTarget:t}=e;!t&&this.eGui.contains(this.gos.getActiveDomElement())||this.eGui.contains(t)||this.focusService.clearFocusedHeader()}onHeaderContextMenu(e,t,i){if(!e&&!i||!this.menuService.isHeaderContextMenuEnabled())return;const{target:r}=null!=e?e:t;r!==this.eGui&&r!==this.ctrlsService.getHeaderRowContainerCtrl().getViewport()||this.menuService.showHeaderContextMenu(void 0,e,i)}mockContextMenuForIPad(e){if(!Ii())return;const t=new vs(this.eGui);this.addManagedListener(t,vs.EVENT_LONG_TAP,t=>{e(void 0,t.touchStart,t.touchEvent)}),this.addDestroyFunc(()=>t.destroy())}};g([he("headerNavigationService")],vl.prototype,"headerNavigationService",2),g([he("focusService")],vl.prototype,"focusService",2),g([he("columnModel")],vl.prototype,"columnModel",2),g([he("ctrlsService")],vl.prototype,"ctrlsService",2),g([he("filterManager")],vl.prototype,"filterManager",2),g([he("menuService")],vl.prototype,"menuService",2);var Cl=class e extends wn{constructor(){super(e.TEMPLATE)}postConstruct(){const e={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setHeightAndMinHeight:e=>{this.getGui().style.height=e,this.getGui().style.minHeight=e}};this.createManagedBean(new vl).setComp(e,this.getGui(),this.getFocusableElement());const t=e=>{this.createManagedBean(e),this.appendChild(e)};t(new gl("left")),t(new gl(null)),t(new gl("right"))}};Cl.TEMPLATE='<div class="ag-header" role="presentation"/>',g([le],Cl.prototype,"postConstruct",1);var yl=Cl,wl=class extends nt{addResizeBar(e){const t={dragStartPixels:e.dragStartPixels||0,eElement:e.eResizeBar,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this,e),onDragging:this.onDragging.bind(this,e),includeTouch:!0,stopPropagationForTouch:!0};return this.dragService.addDragSource(t),()=>this.dragService.removeDragSource(t)}onDragStart(e,t){this.dragStartX=t.clientX,this.setResizeIcons();const i=t instanceof MouseEvent&&!0===t.shiftKey;e.onResizeStart(i)}setResizeIcons(){const e=this.ctrlsService.get("gridCtrl");e.setResizeCursor(!0),e.disableUserSelect(!0)}onDragStop(e,t){e.onResizeEnd(this.resizeAmount),this.resetIcons()}resetIcons(){const e=this.ctrlsService.get("gridCtrl");e.setResizeCursor(!1),e.disableUserSelect(!1)}onDragging(e,t){this.resizeAmount=t.clientX-this.dragStartX,e.onResizing(this.resizeAmount)}};g([he("dragService")],wl.prototype,"dragService",2),g([he("ctrlsService")],wl.prototype,"ctrlsService",2),wl=g([ue("horizontalResizeService")],wl);var Sl=class extends nt{hideActiveMenu(){this.hidePopup&&this.hidePopup()}showMenuAfterMouseEvent(e,t,i){this.showPopup(e,r=>{this.popupService.positionPopupUnderMouseEvent({column:e,type:i,mouseEvent:t,ePopup:r})},i,t.target,this.menuService.isLegacyMenuEnabled())}showMenuAfterButtonClick(e,t,i){let r=-1,n="left";const s=this.menuService.isLegacyMenuEnabled();!s&&this.gos.get("enableRtl")&&(r=1,n="right");let o=s?void 0:4*r,a=s?void 0:4;this.showPopup(e,r=>{this.popupService.positionPopupByComponent({type:i,eventSource:t,ePopup:r,nudgeX:o,nudgeY:a,alignSide:n,keepWithinBounds:!0,position:"under",column:e})},i,t,s)}showPopup(e,t,i,r,n){const s=e?this.createBean(new Ko(e,"COLUMN_MENU")):void 0;if(this.activeMenu=s,!(null==s?void 0:s.hasFilter())||!e)throw new Error("AG Grid - unable to show popup filter, filter instantiation failed");const o=document.createElement("div");let a;Bt(o,"presentation"),o.classList.add("ag-menu"),n||o.classList.add("ag-filter-menu"),this.tabListener=this.addManagedListener(o,"keydown",e=>this.trapFocusWithin(e,o)),o.appendChild(null==s?void 0:s.getGui());const l=this.menuService.isColumnMenuAnchoringEnabled()?null!=r?r:this.ctrlsService.getGridBodyCtrl().getGui():void 0,c=this.localeService.getLocaleTextFunc(),u=n&&"columnFilter"!==i?c("ariaLabelColumnMenu","Column Menu"):c("ariaLabelColumnFilter","Column Filter"),h=this.popupService.addPopup({modal:!0,eChild:o,closeOnEsc:!0,closedCallback:t=>{e.setMenuVisible(!1,"contextMenu");const n=t instanceof KeyboardEvent;if(this.tabListener&&(this.tabListener=this.tabListener()),n&&r&&br(r)){const e=this.focusService.findTabbableParent(r);e&&e.focus()}null==s||s.afterGuiDetached(),this.destroyBean(this.activeMenu),this.dispatchVisibleChangedEvent(!1,i,e)},positionCallback:()=>t(o),anchorToElement:l,ariaLabel:u});h&&(this.hidePopup=a=h.hideFunc),s.afterInit().then(()=>{t(o),s.afterGuiAttached({container:i,hidePopup:a})}),e.setMenuVisible(!0,"contextMenu"),this.dispatchVisibleChangedEvent(!0,i,e)}trapFocusWithin(e,t){e.key!==Qr.TAB||e.defaultPrevented||this.focusService.findNextFocusableElement(t,!1,e.shiftKey)||(e.preventDefault(),this.focusService.focusInto(t,e.shiftKey))}dispatchVisibleChangedEvent(e,t,i){const r={type:ct.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:!1,key:t,column:null!=i?i:null};this.eventService.dispatchEvent(r)}isMenuEnabled(e){var t;return e.isFilterAllowed()&&(null!=(t=e.getColDef().menuTabs)?t:["filterMenuTab"]).includes("filterMenuTab")}showMenuAfterContextMenuEvent(){}destroy(){this.destroyBean(this.activeMenu),super.destroy()}};g([he("filterManager")],Sl.prototype,"filterManager",2),g([he("popupService")],Sl.prototype,"popupService",2),g([he("focusService")],Sl.prototype,"focusService",2),g([he("ctrlsService")],Sl.prototype,"ctrlsService",2),g([he("menuService")],Sl.prototype,"menuService",2),Sl=g([ue("filterMenuFactory")],Sl);var bl=(e=>(e.TAB_GUARD="ag-tab-guard",e.TAB_GUARD_TOP="ag-tab-guard-top",e.TAB_GUARD_BOTTOM="ag-tab-guard-bottom",e))(bl||{}),El=class extends nt{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1;const{comp:t,eTopGuard:i,eBottomGuard:r,focusTrapActive:n,forceFocusOutWhenTabGuardsAreEmpty:s,focusInnerElement:o,onFocusIn:a,onFocusOut:l,shouldStopEventPropagation:c,onTabKeyDown:u,handleKeyDown:h,eFocusableElement:d}=e;this.comp=t,this.eTopGuard=i,this.eBottomGuard=r,this.providedFocusInnerElement=o,this.eFocusableElement=d,this.focusTrapActive=!!n,this.forceFocusOutWhenTabGuardsAreEmpty=!!s,this.providedFocusIn=a,this.providedFocusOut=l,this.providedShouldStopEventPropagation=c,this.providedOnTabKeyDown=u,this.providedHandleKeyDown=h}postConstruct(){this.createManagedBean(new Pn(this.eFocusableElement,{shouldStopEventPropagation:()=>this.shouldStopEventPropagation(),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e)})),this.activateTabGuards(),[this.eTopGuard,this.eBottomGuard].forEach(e=>this.addManagedListener(e,"focus",this.onFocus.bind(this)))}handleKeyDown(e){this.providedHandleKeyDown&&this.providedHandleKeyDown(e)}tabGuardsAreActive(){return!!this.eTopGuard&&this.eTopGuard.hasAttribute("tabIndex")}shouldStopEventPropagation(){return!!this.providedShouldStopEventPropagation&&this.providedShouldStopEventPropagation()}activateTabGuards(){if(this.forcingFocusOut)return;const e=this.gos.get("tabIndex");this.comp.setTabIndex(e.toString())}deactivateTabGuards(){this.comp.setTabIndex()}onFocus(e){if(this.skipTabGuardFocus)return void(this.skipTabGuardFocus=!1);if(this.forceFocusOutWhenTabGuardsAreEmpty&&0===this.focusService.findFocusableElements(this.eFocusableElement,".ag-tab-guard").length)return void this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);const t=e.target===this.eBottomGuard;this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t)}findNextElementOutsideAndFocus(e){const t=this.gos.getDocument(),i=this.focusService.findFocusableElements(t.body,null,!0),r=i.indexOf(e?this.eTopGuard:this.eBottomGuard);if(-1===r)return;let n,s;e?(n=0,s=r):(n=r+1,s=i.length);const o=i.slice(n,s),a=this.gos.get("tabIndex");o.sort((e,t)=>{const i=parseInt(e.getAttribute("tabindex")||"0"),r=parseInt(t.getAttribute("tabindex")||"0");return r===a?1:i===a?-1:0===i?1:0===r?-1:i-r}),o[e?o.length-1:0].focus()}onFocusIn(e){this.focusTrapActive||(this.providedFocusIn&&this.providedFocusIn(e),this.deactivateTabGuards())}onFocusOut(e){this.focusTrapActive||(this.providedFocusOut&&this.providedFocusOut(e),this.eFocusableElement.contains(e.relatedTarget)||this.activateTabGuards())}onTabKeyDown(e){if(this.providedOnTabKeyDown)return void this.providedOnTabKeyDown(e);if(this.focusTrapActive)return;if(e.defaultPrevented)return;const t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();const i=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),i&&(i.focus(),e.preventDefault())}focusInnerElement(e=!1){const t=this.focusService.findFocusableElements(this.eFocusableElement);this.tabGuardsAreActive()&&(t.splice(0,1),t.splice(t.length-1,1)),t.length&&t[e?t.length-1:0].focus({preventScroll:!0})}getNextFocusableElement(e){return this.focusService.findNextFocusableElement(this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;const t=e?this.eTopGuard:this.eBottomGuard;this.activateTabGuards(),this.skipTabGuardFocus=!0,this.forcingFocusOut=!0,t.focus(),window.setTimeout(()=>{this.forcingFocusOut=!1,this.activateTabGuards()})}isTabGuard(e){return e===this.eTopGuard||e===this.eBottomGuard}};g([he("focusService")],El.prototype,"focusService",2),g([le],El.prototype,"postConstruct",1);var Al=class extends wn{initialiseTabGuard(e){this.eTopGuard=this.createTabGuard("top"),this.eBottomGuard=this.createTabGuard("bottom"),this.eFocusableElement=this.getFocusableElement();const t=[this.eTopGuard,this.eBottomGuard],i={setTabIndex:e=>{t.forEach(t=>null!=e?t.setAttribute("tabindex",e):t.removeAttribute("tabindex"))}};this.addTabGuards(this.eTopGuard,this.eBottomGuard),this.tabGuardCtrl=this.createManagedBean(new El({comp:i,focusTrapActive:!!e.focusTrapActive,eTopGuard:this.eTopGuard,eBottomGuard:this.eBottomGuard,eFocusableElement:this.eFocusableElement,onFocusIn:e.onFocusIn,onFocusOut:e.onFocusOut,focusInnerElement:e.focusInnerElement,handleKeyDown:e.handleKeyDown,onTabKeyDown:e.onTabKeyDown,shouldStopEventPropagation:e.shouldStopEventPropagation,forceFocusOutWhenTabGuardsAreEmpty:e.forceFocusOutWhenTabGuardsAreEmpty}))}createTabGuard(e){const t=document.createElement("div"),i="top"===e?"ag-tab-guard-top":"ag-tab-guard-bottom";return t.classList.add("ag-tab-guard",i),Bt(t,"presentation"),t}addTabGuards(e,t){this.eFocusableElement.insertAdjacentElement("afterbegin",e),this.eFocusableElement.insertAdjacentElement("beforeend",t)}removeAllChildrenExceptTabGuards(){const e=[this.eTopGuard,this.eBottomGuard];yr(this.getFocusableElement()),this.addTabGuards(...e)}forceFocusOutOfContainer(e=!1){this.tabGuardCtrl.forceFocusOutOfContainer(e)}appendChild(e,t){Or(e)||(e=e.getGui());const{eBottomGuard:i}=this;i?i.insertAdjacentElement("beforebegin",e):super.appendChild(e,t)}},Tl=class e extends Al{constructor(t){super(e.getTemplate(t.cssClass)),this.items=[],this.tabbedItemScrollMap=new Map,this.params=t}postConstruct(){this.setupHeader(),this.params.items&&this.params.items.forEach(e=>this.addItem(e)),this.initialiseTabGuard({onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),focusInnerElement:this.focusInnerElement.bind(this),focusTrapActive:!0}),this.addDestroyFunc(()=>{var e,t,i;return null==(i=null==(t=null==(e=this.activeItem)?void 0:e.tabbedItem)?void 0:t.afterDetachedCallback)?void 0:i.call(t)})}static getTemplate(e){return`<div class="ag-tabs ${e}">\n            <div ref="eHeader"></div>\n            <div ref="eBody" role="presentation" class="ag-tabs-body ${e?`${e}-body`:""}"></div>\n        </div>`}setupHeader(){const{enableCloseButton:e,cssClass:t}=this.params,i=(e,i)=>{e.classList.add(`ag-tabs-${i}`),t&&e.classList.add(`${t}-${i}`)};e?(this.setupCloseButton(i),this.eTabHeader=this.gos.getDocument().createElement("div"),i(this.eHeader,"header-wrapper"),Bt(this.eHeader,"presentation"),this.eHeader.appendChild(this.eTabHeader)):this.eTabHeader=this.eHeader,Bt(this.eTabHeader,"tablist"),i(this.eTabHeader,"header")}setupCloseButton(e){const t=this.gos.getDocument(),i=t.createElement("button");e(i,"close-button");const r=qr("close",this.gos,void 0,!0);Kt(i,this.params.closeButtonAriaLabel),i.appendChild(r),this.addManagedListener(i,"click",()=>{var e,t;return null==(t=(e=this.params).onCloseClicked)?void 0:t.call(e)});const n=t.createElement("div");e(n,"close-button-wrapper"),Bt(n,"presentation"),n.appendChild(i),this.eHeader.appendChild(n),this.eCloseButton=i}handleKeyDown(e){switch(e.key){case Qr.RIGHT:case Qr.LEFT:if(!this.eTabHeader.contains(this.gos.getActiveDomElement()))return;const t=e.key===Qr.RIGHT,i=this.gos.get("enableRtl"),r=this.items.indexOf(this.activeItem),n=t!==i?Math.min(r+1,this.items.length-1):Math.max(r-1,0);if(r===n)return;e.preventDefault();const s=this.items[n];this.showItemWrapper(s),s.eHeaderButton.focus();break;case Qr.UP:case Qr.DOWN:e.stopPropagation()}}onTabKeyDown(e){var t,i,r,n;if(e.defaultPrevented)return;const{focusService:s,eHeader:o,eBody:a,activeItem:l,params:c}=this,{suppressTrapFocus:u,enableCloseButton:h}=c,d=this.gos.getActiveDomElement(),p=e.target,g=e.shiftKey;if(o.contains(d))return e.preventDefault(),void(h&&g&&!(null==(t=this.eCloseButton)?void 0:t.contains(d))?null==(i=this.eCloseButton)||i.focus():u&&g?null==(r=this.focusService.findFocusableElementBeforeTabGuard(this.gos.getDocument().body,p))||r.focus():this.focusBody(e.shiftKey));let f=null;if(s.isTargetUnderManagedComponent(a,p)&&(g&&(f=this.focusService.findFocusableElementBeforeTabGuard(a,p)),f||u||(f=l.eHeaderButton)),!f&&a.contains(d)&&(f=s.findNextFocusableElement(a,!1,g),!f))return e.preventDefault(),void(u&&!g?this.forceFocusOutOfContainer(g):h&&!g?null==(n=this.eCloseButton)||n.focus():this.focusHeader());f&&(e.preventDefault(),f.focus())}focusInnerElement(e){e?this.focusHeader():this.focusBody(!0)}focusHeader(e){this.activeItem.eHeaderButton.focus({preventScroll:e})}focusBody(e){this.focusService.focusInto(this.eBody,e)}setAfterAttachedParams(e){this.afterAttachedParams=e}showFirstItem(){this.items.length>0&&this.showItemWrapper(this.items[0])}addItem(e){const t=document.createElement("span");Bt(t,"tab"),t.setAttribute("tabindex","-1"),t.appendChild(e.title),t.classList.add("ag-tab"),this.eTabHeader.appendChild(t),Kt(t,e.titleLabel);const i={tabbedItem:e,eHeaderButton:t};this.items.push(i),t.addEventListener("click",this.showItemWrapper.bind(this,i))}showItem(e){const t=this.items.find(t=>t.tabbedItem===e);t&&this.showItemWrapper(t)}showItemWrapper(e){var t,i,r,n,s,o;const{tabbedItem:a,eHeaderButton:l}=e;null==(i=(t=this.params).onItemClicked)||i.call(t,{item:a}),this.activeItem!==e?(this.lastScrollListener&&(this.lastScrollListener=this.lastScrollListener()),yr(this.eBody),a.bodyPromise.then(e=>{this.eBody.appendChild(e);const t=!this.focusService.isKeyboardMode();if(this.params.suppressFocusBodyOnOpen||this.focusService.focusInto(this.eBody,!1,t),a.afterAttachedCallback&&a.afterAttachedCallback(this.afterAttachedParams),this.params.keepScrollPosition){const t=a.getScrollableContainer&&a.getScrollableContainer()||e;this.lastScrollListener=this.addManagedListener(t,"scroll",()=>{this.tabbedItemScrollMap.set(a.name,t.scrollTop)});const i=this.tabbedItemScrollMap.get(a.name);void 0!==i&&setTimeout(()=>{t.scrollTop=i},0)}}),this.activeItem&&(this.activeItem.eHeaderButton.classList.remove("ag-tab-selected"),null==(o=(s=this.activeItem.tabbedItem).afterDetachedCallback)||o.call(s)),l.classList.add("ag-tab-selected"),this.activeItem=e):null==(n=(r=this.params).onActiveItemClicked)||n.call(r)}};g([he("focusService")],Tl.prototype,"focusService",2),g([bn("eHeader")],Tl.prototype,"eHeader",2),g([bn("eBody")],Tl.prototype,"eBody",2),g([le],Tl.prototype,"postConstruct",1);var Ml=Tl,Rl=class extends nt{constructor(){super(...arguments),this.polyfillFunctions=[]}observeResize(e,t){const i=this.gos.getWindow(),r=()=>{var i,r;let n=null!=(i=null==e?void 0:e.clientWidth)?i:0,s=null!=(r=null==e?void 0:e.clientHeight)?r:0,o=!0;const a=()=>{var i,r;if(o){const o=null!=(i=null==e?void 0:e.clientWidth)?i:0,l=null!=(r=null==e?void 0:e.clientHeight)?r:0;(o!==n||l!==s)&&(n=o,s=l,t()),this.doNextPolyfillTurn(a)}};return a(),()=>o=!1},n=this.gos.get("suppressBrowserResizeObserver");return i.ResizeObserver&&!n?(()=>{const r=new i.ResizeObserver(t);return r.observe(e),()=>r.disconnect()})():this.getFrameworkOverrides().wrapIncoming(()=>r(),"resize-observer")}doNextPolyfillTurn(e){this.polyfillFunctions.push(e),this.schedulePolyfill()}schedulePolyfill(){this.polyfillScheduled||(this.polyfillScheduled=!0,window.setTimeout(()=>{const e=this.polyfillFunctions;this.polyfillScheduled=!1,this.polyfillFunctions=[],e.forEach(e=>e())},50))}};Rl=g([ue("resizeObserverService")],Rl);var _l=class extends nt{constructor(){super(...arguments),this.createTasksP1={list:[],sorted:!1},this.createTasksP2={list:[],sorted:!1},this.destroyTasks=[],this.ticking=!1,this.scrollGoingDown=!0,this.lastPage=0,this.lastScrollTop=0,this.taskCount=0,this.cancelledTasks=new Set}setScrollTop(e){const t=this.gos.get("pagination");if(this.scrollGoingDown=e>=this.lastScrollTop,t&&0===e){const e=this.paginationProxy.getCurrentPage();e!==this.lastPage&&(this.lastPage=e,this.scrollGoingDown=!0)}this.lastScrollTop=e}init(){this.useAnimationFrame=!this.gos.get("suppressAnimationFrame")}isOn(){return this.useAnimationFrame}verifyAnimationFrameOn(e){!1===this.useAnimationFrame&&console.warn(`AG Grid: AnimationFrameService.${e} called but animation frames are off`)}createTask(e,t,i){this.verifyAnimationFrameOn(i);const r={task:e,index:t,createOrder:++this.taskCount};this.addTaskToList(this[i],r),this.schedule()}cancelTask(e){this.cancelledTasks.add(e)}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;const t=this.scrollGoingDown?1:-1;e.list.sort((e,i)=>e.index!==i.index?t*(i.index-e.index):i.createOrder-e.createOrder),e.sorted=!0}addDestroyTask(e){this.verifyAnimationFrameOn("createTasksP3"),this.destroyTasks.push(e),this.schedule()}executeFrame(e){this.verifyAnimationFrameOn("executeFrame");const t=this.createTasksP1,i=t.list,r=this.createTasksP2,n=r.list,s=this.destroyTasks,o=(new Date).getTime();let a=(new Date).getTime()-o;const l=e<=0,c=this.ctrlsService.getGridBodyCtrl();for(;l||a<e;){if(!c.getScrollFeature().scrollGridIfNeeded()){let e;if(i.length)this.sortTaskList(t),e=i.pop().task;else if(n.length)this.sortTaskList(r),e=n.pop().task;else{if(!s.length){this.cancelledTasks.clear();break}e=s.pop()}this.cancelledTasks.has(e)||e()}a=(new Date).getTime()-o}i.length||n.length||s.length?this.requestFrame():this.stopTicking()}stopTicking(){this.ticking=!1}flushAllFrames(){this.useAnimationFrame&&this.executeFrame(-1)}schedule(){this.useAnimationFrame&&(this.ticking||(this.ticking=!0,this.requestFrame()))}requestFrame(){const e=this.executeFrame.bind(this,60);this.requestAnimationFrame(e)}requestAnimationFrame(e){const t=this.gos.getWindow();t.requestAnimationFrame?t.requestAnimationFrame(e):t.webkitRequestAnimationFrame?t.webkitRequestAnimationFrame(e):t.setTimeout(e,0)}isQueueEmpty(){return!this.ticking}debounce(e){let t=!1;return()=>{this.isOn()?t||(t=!0,this.addDestroyTask(()=>{t=!1,e()})):window.setTimeout(e,0)}}};g([he("ctrlsService")],_l.prototype,"ctrlsService",2),g([he("paginationProxy")],_l.prototype,"paginationProxy",2),g([le],_l.prototype,"init",1),_l=g([ue("animationFrameService")],_l);var Pl=(e=>(e.EVERYTHING="group",e.FILTER="filter",e.SORT="sort",e.MAP="map",e.AGGREGATE="aggregate",e.FILTER_AGGREGATES="filter_aggregates",e.PIVOT="pivot",e.NOTHING="nothing",e))(Pl||{}),xl=class extends nt{postConstruct(){this.isClientSideRowModel="clientSide"===this.rowModel.getType()}expandRows(e){if(!this.isClientSideRowModel)return;const t=new Set(e);this.rowModel.forEachNode(e=>{e.id&&t.has(e.id)&&(e.expanded=!0)}),this.onGroupExpandedOrCollapsed()}getExpandedRows(){const e=[];return this.rowModel.forEachNode(({expanded:t,id:i})=>{t&&i&&e.push(i)}),e}expandAll(e){this.isClientSideRowModel&&this.rowModel.expandOrCollapseAll(e)}setRowNodeExpanded(e,t,i,r){e&&(i&&e.parent&&-1!==e.parent.level&&this.setRowNodeExpanded(e.parent,t,i,r),e.setExpanded(t,void 0,r))}onGroupExpandedOrCollapsed(){this.isClientSideRowModel&&this.rowModel.refreshModel({step:"map"})}};g([he("rowModel")],xl.prototype,"rowModel",2),g([le],xl.prototype,"postConstruct",1),xl=g([ue("expansionService")],xl);var Dl=class extends nt{postConstruct(){var e;this.activeMenuFactory=null!=(e=this.enterpriseMenuFactory)?e:this.filterMenuFactory}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){const t=this.enterpriseMenuFactory&&this.isLegacyMenuEnabled()?this.enterpriseMenuFactory:this.filterMenuFactory;this.showColumnMenuCommon(t,e,e.containerType,!0)}showHeaderContextMenu(e,t,i){this.activeMenuFactory.showMenuAfterContextMenuEvent(e,t,i)}getContextMenuPosition(e,t){const i=this.getRowCtrl(e),r=this.getCellGui(i,t);if(!r)return i?{x:0,y:i.getRowYPosition()}:{x:0,y:0};const n=r.getBoundingClientRect();return{x:n.x+n.width/2,y:n.y+n.height/2}}showContextMenu(e){var t,i,r;const{column:n,rowNode:s}=e;let{anchorToElement:o,value:a}=e;s&&n&&null==a&&(a=s.getValueFromValueService(n)),null==o&&(o=this.getContextMenuAnchorElement(s,n)),null==(r=this.contextMenuFactory)||r.onContextMenu(null!=(t=e.mouseEvent)?t:null,null!=(i=e.touchEvent)?i:null,null!=s?s:null,null!=n?n:null,a,o)}showColumnChooser(e){var t;null==(t=this.columnChooserFactory)||t.showColumnChooser(e)}hidePopupMenu(){var e;null==(e=this.contextMenuFactory)||e.hideActiveMenu(),this.activeMenuFactory.hideActiveMenu()}hideColumnChooser(){var e;null==(e=this.columnChooserFactory)||e.hideActiveColumnChooser()}isColumnMenuInHeaderEnabled(e){const{suppressMenu:t,suppressHeaderMenuButton:i}=e.getColDef();return!(null!=i?i:t)&&this.activeMenuFactory.isMenuEnabled(e)&&(this.isLegacyMenuEnabled()||!!this.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){return!e.getColDef().suppressHeaderFilterButton&&this.filterManager.isFilterAllowed(e)}isHeaderContextMenuEnabled(e){return!(null==e?void 0:e.getColDef().suppressHeaderContextMenu)&&"new"===this.getColumnMenuType()}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){const e=!this.isSuppressMenuHide();return!(Ii()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!this.isLegacyMenuEnabled()&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){return this.filterManager.isFilterAllowed(e)&&!this.isLegacyMenuEnabled()&&!this.isFilterMenuInHeaderEnabled(e)&&!this.isFloatingFilterButtonDisplayed(e)}isColumnMenuAnchoringEnabled(){return!this.isLegacyMenuEnabled()}areAdditionalColumnMenuItemsEnabled(){return"new"===this.getColumnMenuType()}isLegacyMenuEnabled(){return"legacy"===this.getColumnMenuType()}isFloatingFilterButtonEnabled(e){var t;const i=e.getColDef(),r=null==(t=i.floatingFilterComponentParams)?void 0:t.suppressFilterButton;return null!=r&&U("As of v31.1, 'colDef.floatingFilterComponentParams.suppressFilterButton' is deprecated. Use 'colDef.suppressFloatingFilterButton' instead."),null==i.suppressFloatingFilterButton?!r:!i.suppressFloatingFilterButton}getColumnMenuType(){var e;return null!=(e=this.gos.get("columnMenu"))?e:"legacy"}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){const e=this.gos.get("suppressMenuHide");return this.isLegacyMenuEnabled()?e:!this.gos.exists("suppressMenuHide")||e}showColumnMenuCommon(e,t,i,r){const{column:n,positionBy:s}=t;if("button"===s){const{buttonElement:s}=t;e.showMenuAfterButtonClick(n,s,i,r)}else if("mouse"===s){const{mouseEvent:s}=t;e.showMenuAfterMouseEvent(n,s,i,r)}else n&&(this.ctrlsService.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(n,"auto"),this.animationFrameService.requestAnimationFrame(()=>{const t=this.ctrlsService.getHeaderRowContainerCtrl(n.getPinned()).getHeaderCtrlForColumn(n);e.showMenuAfterButtonClick(n,t.getAnchorElementForMenu(r),i,!0)}))}getRowCtrl(e){const{rowIndex:t,rowPinned:i}=e||{};if(null!=t)return this.rowRenderer.getRowByPosition({rowIndex:t,rowPinned:i})||void 0}getCellGui(e,t){if(!e||!t)return;const i=e.getCellCtrl(t);return(null==i?void 0:i.getGui())||void 0}getContextMenuAnchorElement(e,t){const i=this.ctrlsService.getGridBodyCtrl().getGridBodyElement(),r=this.getRowCtrl(e);if(!r)return i;return this.getCellGui(r,t)||(r.isFullWidth()?r.getFullWidthElement():i)}};g([he("filterMenuFactory")],Dl.prototype,"filterMenuFactory",2),g([he("ctrlsService")],Dl.prototype,"ctrlsService",2),g([he("animationFrameService")],Dl.prototype,"animationFrameService",2),g([he("filterManager")],Dl.prototype,"filterManager",2),g([he("rowRenderer")],Dl.prototype,"rowRenderer",2),g([de("columnChooserFactory")],Dl.prototype,"columnChooserFactory",2),g([de("contextMenuFactory")],Dl.prototype,"contextMenuFactory",2),g([de("enterpriseMenuFactory")],Dl.prototype,"enterpriseMenuFactory",2),g([le],Dl.prototype,"postConstruct",1),Dl=g([ue("menuService")],Dl);var Il=class extends nt{postConstruct(){this.ctrlsService.whenReady(e=>{this.centerRowContainerCtrl=e.center})}getPreferredWidthForColumn(e,t){const i=this.getHeaderCellForColumn(e);if(!i)return-1;const r=this.rowRenderer.getAllCellsForColumn(e);return t||r.push(i),this.addElementsToContainerAndGetWidth(r)}getPreferredWidthForColumnGroup(e){const t=this.getHeaderCellForColumn(e);return t?this.addElementsToContainerAndGetWidth([t]):-1}addElementsToContainerAndGetWidth(e){const t=document.createElement("form");t.style.position="fixed";const i=this.centerRowContainerCtrl.getContainerElement();e.forEach(e=>this.cloneItemIntoDummy(e,t)),i.appendChild(t);const r=t.offsetWidth;return i.removeChild(t),r+this.getAutoSizePadding()}getAutoSizePadding(){return this.gos.get("autoSizePadding")}getHeaderCellForColumn(e){let t=null;return this.ctrlsService.getHeaderRowContainerCtrls().forEach(i=>{const r=i.getHtmlElementForColumnHeader(e);null!=r&&(t=r)}),t}cloneItemIntoDummy(e,t){const i=e.cloneNode(!0);i.style.width="",i.style.position="static",i.style.left="";const r=document.createElement("div"),n=r.classList;["ag-header-cell","ag-header-group-cell"].some(e=>i.classList.contains(e))?(n.add("ag-header","ag-header-row"),r.style.position="static"):n.add("ag-row");let s=e.parentElement;for(;s;){if(["ag-header-row","ag-row"].some(e=>s.classList.contains(e))){for(let e=0;e<s.classList.length;e++){const t=s.classList[e];"ag-row-position-absolute"!=t&&n.add(t)}break}s=s.parentElement}r.appendChild(i),t.appendChild(r)}};g([he("rowRenderer")],Il.prototype,"rowRenderer",2),g([he("ctrlsService")],Il.prototype,"ctrlsService",2),g([he("rowCssClassCalculator")],Il.prototype,"rowCssClassCalculator",2),g([le],Il.prototype,"postConstruct",1),Il=g([ue("autoWidthCalculator")],Il);var Ll=class extends nt{constructor(e,t){super(),this.createRowCon=e,this.destroyRowCtrls=t,this.stickyTopRowCtrls=[],this.stickyBottomRowCtrls=[],this.topContainerHeight=0,this.bottomContainerHeight=0}postConstruct(){this.isClientSide="clientSide"===this.rowModel.getType(),this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl})}getStickyTopRowCtrls(){return this.stickyTopRowCtrls}getStickyBottomRowCtrls(){return this.stickyBottomRowCtrls}getLastPixelOfGroup(e){return this.isClientSide?this.getClientSideLastPixelOfGroup(e):this.getServerSideLastPixelOfGroup(e)}getFirstPixelOfGroup(e){return e.footer?e.sibling.rowTop+e.sibling.rowHeight-1:e.hasChildren()?e.rowTop-1:0}getServerSideLastPixelOfGroup(e){var t,i,r,n;if(this.isClientSide)throw new Error("This func should only be called in server side row model.");if(e.isExpandable()||e.footer){if(e.master)return e.detailNode.rowTop+e.detailNode.rowHeight;if(!e.sibling||1===Math.abs(e.sibling.rowIndex-e.rowIndex)){let s=null==(t=e.childStore)?void 0:t.getStoreBounds();return e.footer&&(s=null==(i=e.sibling.childStore)?void 0:i.getStoreBounds()),(null!=(r=null==s?void 0:s.heightPx)?r:0)+(null!=(n=null==s?void 0:s.topPx)?n:0)}return e.footer?e.rowTop+e.rowHeight:e.sibling.rowTop+e.sibling.rowHeight}return Number.MAX_SAFE_INTEGER}getClientSideLastPixelOfGroup(e){if(!this.isClientSide)throw new Error("This func should only be called in client side row model.");if(e.isExpandable()||e.footer){const t=e.footer&&0===e.rowIndex,i=!e.sibling||1===Math.abs(e.sibling.rowIndex-e.rowIndex);if(t||i){let t=e.footer?e.sibling:e;for(;t.isExpandable()&&t.expanded;)if(t.master)t=t.detailNode;else if(t.childrenAfterSort){if(0===t.childrenAfterSort.length)break;t=Pe(t.childrenAfterSort)}return t.rowTop+t.rowHeight}return e.footer?e.rowTop+e.rowHeight:e.sibling.rowTop+e.sibling.rowHeight}return Number.MAX_SAFE_INTEGER}updateStickyRows(e){const t="top"===e;let i=0;if(!this.canRowsBeSticky())return this.refreshNodesAndContainerHeight(e,new Set,i);const r=t?this.rowRenderer.getFirstVisibleVerticalPixel():this.rowRenderer.getLastVisibleVerticalPixel(),n=new Set,s=e=>{if(n.add(e),t){const t=this.getLastPixelOfGroup(e),n=r+i+e.rowHeight;e.stickyRowTop=t<n?i+(t-n):i}else{const t=this.getFirstPixelOfGroup(e),n=r-(i+e.rowHeight);e.stickyRowTop=t>n?i-(t-n):i}i=0,n.forEach(e=>{const t=e.stickyRowTop+e.rowHeight;i<t&&(i=t)})},o=this.areFooterRowsStickySuppressed(),a=this.gos.get("suppressGroupRowsSticky"),l=e=>!!e.displayed&&(e.footer?!0!==o&&(("grand"!==o||-1!==e.level)&&(!("group"===o&&e.level>-1)&&!n.has(e))):!!e.isExpandable()&&(!0!==a&&(!n.has(e)&&e.expanded)));for(let e=0;e<100;e++){let e=r+i;t||(e=r-i);const n=this.rowModel.getRowIndexAtPixel(e),o=this.rowModel.getRow(n);if(null==o)break;const a=this.getStickyAncestors(o).find(e=>(t?e.rowIndex<n:e.rowIndex>n)&&l(e));if(a)s(a);else{if(!(t?o.rowTop<e:o.rowTop+o.rowHeight>e)||!l(o))break;s(o)}}return t||n.forEach(e=>{e.stickyRowTop=i-(e.stickyRowTop+e.rowHeight)}),this.refreshNodesAndContainerHeight(e,n,i)}areFooterRowsStickySuppressed(){const e=this.gos.get("suppressStickyTotalRow");if(!0===e)return!0;const t=!!this.gos.get("groupIncludeFooter")||"group"===e,i=!!this.gos.get("groupIncludeTotalFooter")||"grand"===e;return!(!t||!i)||(i?"grand":!!t&&"group")}canRowsBeSticky(){const e=this.gos.isGroupRowsSticky(),t=this.areFooterRowsStickySuppressed(),i=this.gos.get("suppressGroupRowsSticky");return e&&(!t||!i)}getStickyAncestors(e){const t=[];let i=e.footer?e.sibling:e.parent;for(;i;)i.sibling&&t.push(i.sibling),t.push(i),i=i.parent;return t.reverse()}checkStickyRows(){const e=this.updateStickyRows("top"),t=this.updateStickyRows("bottom");return e||t}destroyStickyCtrls(){this.refreshNodesAndContainerHeight("top",new Set,0),this.refreshNodesAndContainerHeight("bottom",new Set,0)}refreshStickyNode(e){const t=new Set;if(this.stickyTopRowCtrls.some(t=>t.getRowNode()===e)){for(let i=0;i<this.stickyTopRowCtrls.length;i++){const r=this.stickyTopRowCtrls[i].getRowNode();r!==e&&t.add(r)}this.refreshNodesAndContainerHeight("top",t,this.topContainerHeight)&&this.checkStickyRows()}else{for(let i=0;i<this.stickyBottomRowCtrls.length;i++){const r=this.stickyBottomRowCtrls[i].getRowNode();r!==e&&t.add(r)}this.refreshNodesAndContainerHeight("bottom",t,this.bottomContainerHeight)&&this.checkStickyRows()}}refreshNodesAndContainerHeight(e,t,i){const r="top"===e,n=r?this.stickyTopRowCtrls:this.stickyBottomRowCtrls,s={},o=[];for(let e=0;e<n.length;e++){const i=n[e].getRowNode();t.has(i)?o.push(n[e]):(s[i.id]=n[e],i.sticky=!1)}const a=new Set;for(let e=0;e<o.length;e++)a.add(o[e].getRowNode());const l=[];t.forEach(e=>{a.has(e)||(e.sticky=!0,l.push(this.createRowCon(e,!1,!1)))});let c=!!l.length||o.length!==n.length;r?this.topContainerHeight!==i&&(this.topContainerHeight=i,this.gridBodyCtrl.setStickyTopHeight(i),c=!0):this.bottomContainerHeight!==i&&(this.bottomContainerHeight=i,this.gridBodyCtrl.setStickyBottomHeight(i),c=!0),this.destroyRowCtrls(s,!1);const u=[...o,...l];return u.sort((e,t)=>t.getRowNode().rowIndex-e.getRowNode().rowIndex),r||u.reverse(),u.forEach(e=>e.setRowTop(e.getRowNode().stickyRowTop)),!!c&&(r?this.stickyTopRowCtrls=u:this.stickyBottomRowCtrls=u,!0)}};g([he("rowModel")],Ll.prototype,"rowModel",2),g([he("rowRenderer")],Ll.prototype,"rowRenderer",2),g([he("ctrlsService")],Ll.prototype,"ctrlsService",2),g([le],Ll.prototype,"postConstruct",1);var Nl=class extends nt{constructor(){super(...arguments),this.destroyFuncsForColumnListeners=[],this.rowCtrlsByRowIndex={},this.zombieRowCtrls={},this.allRowCtrls=[],this.topRowCtrls=[],this.bottomRowCtrls=[],this.refreshInProgress=!1,this.dataFirstRenderedFired=!1,this.setupRangeSelectionListeners=()=>{const e=()=>{this.getAllCellCtrls().forEach(e=>e.onRangeSelectionChanged())},t=()=>{this.getAllCellCtrls().forEach(e=>e.updateRangeBordersIfRangeCount())},i=()=>{this.eventService.addEventListener(ct.EVENT_RANGE_SELECTION_CHANGED,e),this.eventService.addEventListener(ct.EVENT_COLUMN_MOVED,t),this.eventService.addEventListener(ct.EVENT_COLUMN_PINNED,t),this.eventService.addEventListener(ct.EVENT_COLUMN_VISIBLE,t)},r=()=>{this.eventService.removeEventListener(ct.EVENT_RANGE_SELECTION_CHANGED,e),this.eventService.removeEventListener(ct.EVENT_COLUMN_MOVED,t),this.eventService.removeEventListener(ct.EVENT_COLUMN_PINNED,t),this.eventService.removeEventListener(ct.EVENT_COLUMN_VISIBLE,t)};this.addDestroyFunc(()=>r()),this.addManagedPropertyListener("enableRangeSelection",e=>{e.currentValue?i():r()}),this.gos.get("enableRangeSelection")&&i()}}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.initialise()})}initialise(){if(this.addManagedListener(this.eventService,ct.EVENT_PAGINATION_CHANGED,this.onPageLoaded.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL,this.onBodyScroll.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_BODY_HEIGHT_CHANGED,this.redraw.bind(this)),this.addManagedPropertyListeners(["domLayout","embedFullWidthRows"],()=>this.onDomLayoutChanged()),this.addManagedPropertyListeners(["suppressMaxRenderedRowRestriction","rowBuffer"],()=>this.redraw()),this.addManagedPropertyListeners(["suppressCellFocus","getBusinessKeyForNode","fullWidthCellRenderer","fullWidthCellRendererParams","rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules","suppressStickyTotalRow","groupRowRenderer","groupRowRendererParams","loadingCellRenderer","loadingCellRendererParams","detailCellRenderer","detailCellRendererParams","enableRangeSelection","enableCellTextSelection"],()=>this.redrawRows()),this.gos.isGroupRowsSticky()){const e=this.rowModel.getType();"clientSide"!==e&&"serverSide"!==e||(this.stickyRowFeature=this.createManagedBean(new Ll(this.createRowCon.bind(this),this.destroyRowCtrls.bind(this))))}this.registerCellEventListeners(),this.initialiseCache(),this.printLayout=this.gos.isDomLayout("print"),this.embedFullWidthRows=this.printLayout||this.gos.get("embedFullWidthRows"),this.redrawAfterModelUpdate()}initialiseCache(){if(this.gos.get("keepDetailRows")){const e=this.getKeepDetailRowsCount(),t=null!=e?e:3;this.cachedRowCtrls=new Ol(t)}}getKeepDetailRowsCount(){return this.gos.get("keepDetailRowsCount")}getStickyTopRowCtrls(){return this.stickyRowFeature?this.stickyRowFeature.getStickyTopRowCtrls():[]}getStickyBottomRowCtrls(){return this.stickyRowFeature?this.stickyRowFeature.getStickyBottomRowCtrls():[]}updateAllRowCtrls(){const e=O(this.rowCtrlsByRowIndex),t=O(this.zombieRowCtrls),i=this.cachedRowCtrls?this.cachedRowCtrls.getEntries():[];t.length>0||i.length>0?this.allRowCtrls=[...e,...t,...i]:this.allRowCtrls=e}onCellFocusChanged(e){this.getAllCellCtrls().forEach(t=>t.onCellFocused(e)),this.getFullWidthRowCtrls().forEach(t=>t.onFullWidthRowFocused(e))}registerCellEventListeners(){this.addManagedListener(this.eventService,ct.EVENT_CELL_FOCUSED,e=>{this.onCellFocusChanged(e)}),this.addManagedListener(this.eventService,ct.EVENT_CELL_FOCUS_CLEARED,()=>{this.onCellFocusChanged()}),this.addManagedListener(this.eventService,ct.EVENT_FLASH_CELLS,e=>{this.getAllCellCtrls().forEach(t=>t.onFlashCells(e))}),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_HOVER_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onColumnHover())}),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onDisplayedColumnsChanged())}),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,()=>{this.printLayout&&this.getAllCellCtrls().forEach(e=>e.onLeftChanged())}),this.setupRangeSelectionListeners(),this.refreshListenersToColumnsForCellComps(),this.addManagedListener(this.eventService,ct.EVENT_GRID_COLUMNS_CHANGED,this.refreshListenersToColumnsForCellComps.bind(this)),this.addDestroyFunc(this.removeGridColumnListeners.bind(this))}removeGridColumnListeners(){this.destroyFuncsForColumnListeners.forEach(e=>e()),this.destroyFuncsForColumnListeners.length=0}refreshListenersToColumnsForCellComps(){this.removeGridColumnListeners(),this.columnModel.getAllGridColumns().forEach(e=>{const t=t=>{this.getAllCellCtrls().forEach(i=>{i.getColumn()===e&&t(i)})},i=()=>{t(e=>e.onLeftChanged())},r=()=>{t(e=>e.onWidthChanged())},n=()=>{t(e=>e.onFirstRightPinnedChanged())},s=()=>{t(e=>e.onLastLeftPinnedChanged())},o=()=>{t(e=>e.onColDefChanged())};e.addEventListener("leftChanged",i),e.addEventListener("widthChanged",r),e.addEventListener("firstRightPinnedChanged",n),e.addEventListener("lastLeftPinnedChanged",s),e.addEventListener("colDefChanged",o),this.destroyFuncsForColumnListeners.push(()=>{e.removeEventListener("leftChanged",i),e.removeEventListener("widthChanged",r),e.removeEventListener("firstRightPinnedChanged",n),e.removeEventListener("lastLeftPinnedChanged",s),e.removeEventListener("colDefChanged",o)})})}onDomLayoutChanged(){const e=this.gos.isDomLayout("print"),t=e||this.gos.get("embedFullWidthRows"),i=t!==this.embedFullWidthRows||this.printLayout!==e;this.printLayout=e,this.embedFullWidthRows=t,i&&this.redrawAfterModelUpdate({domLayoutChanged:!0})}datasourceChanged(){this.firstRenderedRow=0,this.lastRenderedRow=-1;const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e)}onPageLoaded(e){const t={recycleRows:e.keepRenderedRows,animate:e.animate,newData:e.newData,newPage:e.newPage,onlyBody:!0};this.redrawAfterModelUpdate(t)}getAllCellsForColumn(e){const t=[];return this.getAllRowCtrls().forEach(i=>{const r=i.getCellElement(e);r&&t.push(r)}),t}refreshFloatingRowComps(){this.refreshFloatingRows(this.topRowCtrls,this.pinnedRowModel.getPinnedTopRowData()),this.refreshFloatingRows(this.bottomRowCtrls,this.pinnedRowModel.getPinnedBottomRowData())}getTopRowCtrls(){return this.topRowCtrls}getCentreRowCtrls(){return this.allRowCtrls}getBottomRowCtrls(){return this.bottomRowCtrls}refreshFloatingRows(e,t){e.forEach(e=>{e.destroyFirstPass(),e.destroySecondPass()}),e.length=0,t&&t.forEach(t=>{const i=new Ca(t,this.beans,!1,!1,this.printLayout);e.push(i)})}onPinnedRowDataChanged(){this.redrawAfterModelUpdate({recycleRows:!0})}redrawRow(e,t=!1){var i;if(e.sticky)this.stickyRowFeature.refreshStickyNode(e);else{if(null==(i=this.cachedRowCtrls)?void 0:i.has(e))return void this.cachedRowCtrls.removeRow(e);{const t=t=>{const i=t[e.rowIndex];i&&i.getRowNode()===e&&(i.destroyFirstPass(),i.destroySecondPass(),t[e.rowIndex]=this.createRowCon(e,!1,!1))};switch(e.rowPinned){case"top":t(this.topRowCtrls);break;case"bottom":t(this.bottomRowCtrls);break;default:t(this.rowCtrlsByRowIndex),this.updateAllRowCtrls()}}}t||this.dispatchDisplayedRowsChanged(!1)}redrawRows(e){if(null!=e)return null==e||e.forEach(e=>this.redrawRow(e,!0)),void this.dispatchDisplayedRowsChanged(!1);this.redrawAfterModelUpdate()}getCellToRestoreFocusToAfterRefresh(e){const t=(null==e?void 0:e.suppressKeepFocus)?null:this.focusService.getFocusCellToUseAfterRefresh();if(null==t)return null;const i=this.gos.getActiveDomElement(),r=this.gos.getDomData(i,fa.DOM_DATA_KEY_CELL_CTRL),n=this.gos.getDomData(i,Ca.DOM_DATA_KEY_ROW_CTRL);return r||n?t:null}redrawAfterModelUpdate(e={}){this.getLockOnRefresh();const t=this.getCellToRestoreFocusToAfterRefresh(e);this.updateContainerHeights(),this.scrollToTopIfNewData(e);const i=!e.domLayoutChanged&&!!e.recycleRows,r=e.animate&&this.gos.isAnimateRows(),n=i?this.getRowsToRecycle():null;i||this.removeAllRowComps(),this.workOutFirstAndLastRowsToRender(),this.stickyRowFeature&&this.stickyRowFeature.checkStickyRows(),this.recycleRows(n,r),this.gridBodyCtrl.updateRowCount(),e.onlyBody||this.refreshFloatingRowComps(),this.dispatchDisplayedRowsChanged(),null!=t&&this.restoreFocusedCell(t),this.releaseLockOnRefresh()}scrollToTopIfNewData(e){const t=e.newData||e.newPage,i=this.gos.get("suppressScrollOnNewData");t&&!i&&this.gridBodyCtrl.getScrollFeature().scrollToTop()}updateContainerHeights(){if(this.printLayout)return void this.rowContainerHeightService.setModelHeight(null);let e=this.paginationProxy.getCurrentPageHeight();0===e&&(e=1),this.rowContainerHeightService.setModelHeight(e)}getLockOnRefresh(){if(this.refreshInProgress)throw new Error("AG Grid: cannot get grid to draw rows when it is in the middle of drawing rows. Your code probably called a grid API method while the grid was in the render stage. To overcome this, put the API call into a timeout, e.g. instead of api.redrawRows(), call setTimeout(function() { api.redrawRows(); }, 0). To see what part of your code that caused the refresh check this stacktrace.");this.refreshInProgress=!0}releaseLockOnRefresh(){this.refreshInProgress=!1}isRefreshInProgress(){return this.refreshInProgress}restoreFocusedCell(e){e&&(this.focusService.setRestoreFocusedCell(e),this.onCellFocusChanged(this.beans.gos.addGridCommonParams({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,type:"mock"})))}stopEditing(e=!1){this.getAllRowCtrls().forEach(t=>{t.stopEditing(e)})}getAllCellCtrls(){const e=[],t=this.getAllRowCtrls(),i=t.length;for(let r=0;r<i;r++){const i=t[r].getAllCellCtrls(),n=i.length;for(let t=0;t<n;t++)e.push(i[t])}return e}getAllRowCtrls(){const e=this.stickyRowFeature&&this.stickyRowFeature.getStickyTopRowCtrls()||[],t=this.stickyRowFeature&&this.stickyRowFeature.getStickyBottomRowCtrls()||[],i=[...this.topRowCtrls,...this.bottomRowCtrls,...e,...t];for(const e in this.rowCtrlsByRowIndex)i.push(this.rowCtrlsByRowIndex[e]);return i}addRenderedRowListener(e,t,i){const r=this.rowCtrlsByRowIndex[t];r&&r.addEventListener(e,i)}flashCells(e={}){this.getCellCtrls(e.rowNodes,e.columns).forEach(t=>t.flashCell(e))}refreshCells(e={}){const t={forceRefresh:e.force,newData:!1,suppressFlash:e.suppressFlash};this.getCellCtrls(e.rowNodes,e.columns).forEach(e=>e.refreshOrDestroyCell(t)),e.rowNodes&&(this.getRowCtrls(e.rowNodes).forEach(e=>{e.isFullWidth()&&(e.refreshFullWidth()||this.redrawRow(e.getRowNode(),!0))}),this.dispatchDisplayedRowsChanged(!1))}getCellRendererInstances(e){var t;const i=this.getCellCtrls(e.rowNodes,e.columns).map(e=>e.getCellRenderer()).filter(e=>null!=e);if(null==(t=e.columns)?void 0:t.length)return i;const r=[],n=this.mapRowNodes(e.rowNodes);return this.getAllRowCtrls().forEach(e=>{if(n&&!this.isRowInMap(e.getRowNode(),n))return;if(!e.isFullWidth())return;const t=e.getFullWidthCellRenderers();for(let e=0;e<t.length;e++){const i=t[e];null!=i&&r.push(i)}}),[...r,...i]}getCellEditorInstances(e){const t=[];return this.getCellCtrls(e.rowNodes,e.columns).forEach(e=>{const i=e.getCellEditor();i&&t.push(i)}),t}getEditingCells(){const e=[];return this.getAllCellCtrls().forEach(t=>{if(t.isEditing()){const i=t.getCellPosition();e.push(i)}}),e}mapRowNodes(e){if(!e)return;const t={top:{},bottom:{},normal:{}};return e.forEach(e=>{const i=e.id;switch(e.rowPinned){case"top":t.top[i]=e;break;case"bottom":t.bottom[i]=e;break;default:t.normal[i]=e}}),t}isRowInMap(e,t){const i=e.id;switch(e.rowPinned){case"top":return null!=t.top[i];case"bottom":return null!=t.bottom[i];default:return null!=t.normal[i]}}getRowCtrls(e){const t=this.mapRowNodes(e),i=this.getAllRowCtrls();return e&&t?i.filter(e=>{const i=e.getRowNode();return this.isRowInMap(i,t)}):i}getCellCtrls(e,t){let i;y(t)&&(i={},t.forEach(e=>{const t=this.columnModel.getGridColumn(e);y(t)&&(i[t.getId()]=!0)}));const r=[];return this.getRowCtrls(e).forEach(e=>{e.getAllCellCtrls().forEach(e=>{const t=e.getColumn().getId();i&&!i[t]||r.push(e)})}),r}destroy(){this.removeAllRowComps(),super.destroy()}removeAllRowComps(){const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e),this.stickyRowFeature&&this.stickyRowFeature.destroyStickyCtrls()}getRowsToRecycle(){const e=[];I(this.rowCtrlsByRowIndex,(t,i)=>{null==i.getRowNode().id&&e.push(t)}),this.removeRowCtrls(e);const t={};return I(this.rowCtrlsByRowIndex,(e,i)=>{const r=i.getRowNode();t[r.id]=i}),this.rowCtrlsByRowIndex={},t}removeRowCtrls(e,t=!1){e.forEach(e=>{const i=this.rowCtrlsByRowIndex[e];i&&(i.destroyFirstPass(t),i.destroySecondPass()),delete this.rowCtrlsByRowIndex[e]})}onBodyScroll(e){"vertical"===e.direction&&this.redraw({afterScroll:!0})}redraw(e={}){const{afterScroll:t}=e;let i;this.stickyRowFeature&&Li()&&(i=this.getCellToRestoreFocusToAfterRefresh()||void 0);const r=this.firstRenderedRow,n=this.lastRenderedRow;this.workOutFirstAndLastRowsToRender();let s=!1;this.stickyRowFeature&&(s=this.stickyRowFeature.checkStickyRows());const o=this.firstRenderedRow!==r||this.lastRenderedRow!==n;if((!t||s||o)&&(this.getLockOnRefresh(),this.recycleRows(null,!1,t),this.releaseLockOnRefresh(),this.dispatchDisplayedRowsChanged(t&&!s),null!=i)){const e=this.getCellToRestoreFocusToAfterRefresh();null!=i&&null==e&&(this.animationFrameService.flushAllFrames(),this.restoreFocusedCell(i))}}removeRowCompsNotToDraw(e,t){const i={};e.forEach(e=>i[e]=!0);const r=Object.keys(this.rowCtrlsByRowIndex).filter(e=>!i[e]);this.removeRowCtrls(r,t)}calculateIndexesToDraw(e){let t=Wi(this.firstRenderedRow,this.lastRenderedRow);const i=(e,i)=>{const r=i.getRowNode().rowIndex;null!=r&&(r<this.firstRenderedRow||r>this.lastRenderedRow)&&this.doNotUnVirtualiseRow(i)&&t.push(r)};I(this.rowCtrlsByRowIndex,i),I(e,i),t.sort((e,t)=>e-t);const r=[];for(let e=0;e<t.length;e++){const i=t[e],n=this.paginationProxy.getRow(i);n&&!n.sticky&&r.push(i)}return r}recycleRows(e,t=!1,i=!1){const r=this.calculateIndexesToDraw(e);(this.printLayout||i)&&(t=!1),this.removeRowCompsNotToDraw(r,!t);const n=[];r.forEach(r=>{const s=this.createOrUpdateRowCtrl(r,e,t,i);y(s)&&n.push(s)}),e&&(!i||this.gos.get("suppressAnimationFrame")||this.printLayout?this.destroyRowCtrls(e,t):this.beans.animationFrameService.addDestroyTask(()=>{this.destroyRowCtrls(e,t),this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()})),this.updateAllRowCtrls()}dispatchDisplayedRowsChanged(e=!1){const t={type:ct.EVENT_DISPLAYED_ROWS_CHANGED,afterScroll:e};this.eventService.dispatchEvent(t)}onDisplayedColumnsChanged(){const e=this.columnModel.isPinningLeft(),t=this.columnModel.isPinningRight();(this.pinningLeft!==e||t!==this.pinningRight)&&(this.pinningLeft=e,this.pinningRight=t,this.embedFullWidthRows&&this.redrawFullWidthEmbeddedRows())}redrawFullWidthEmbeddedRows(){const e=[];this.getFullWidthRowCtrls().forEach(t=>{const i=t.getRowNode().rowIndex;e.push(i.toString())}),this.refreshFloatingRowComps(),this.removeRowCtrls(e),this.redraw({afterScroll:!0})}getFullWidthRowCtrls(e){const t=this.mapRowNodes(e);return this.getAllRowCtrls().filter(e=>{if(!e.isFullWidth())return!1;const i=e.getRowNode();return!(null!=t&&!this.isRowInMap(i,t))})}createOrUpdateRowCtrl(e,t,i,r){let n,s=this.rowCtrlsByRowIndex[e];if(s||(n=this.paginationProxy.getRow(e),y(n)&&y(t)&&t[n.id]&&n.alreadyRendered&&(s=t[n.id],t[n.id]=null)),!s){if(n||(n=this.paginationProxy.getRow(e)),!y(n))return;s=this.createRowCon(n,i,r)}return n&&(n.alreadyRendered=!0),this.rowCtrlsByRowIndex[e]=s,s}destroyRowCtrls(e,t){const i=[];I(e,(e,r)=>{r&&(this.cachedRowCtrls&&r.isCacheable()?this.cachedRowCtrls.addRow(r):(r.destroyFirstPass(!t),t?(this.zombieRowCtrls[r.getInstanceId()]=r,i.push(()=>{r.destroySecondPass(),delete this.zombieRowCtrls[r.getInstanceId()]})):r.destroySecondPass()))}),t&&(i.push(()=>{this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()}),$(i))}getRowBuffer(){return this.gos.get("rowBuffer")}getRowBufferInPixels(){return this.getRowBuffer()*this.gos.getRowHeightAsNumber()}workOutFirstAndLastRowsToRender(){let e,t;if(this.rowContainerHeightService.updateOffset(),this.paginationProxy.isRowsToRender())if(this.printLayout)this.environment.refreshRowHeightVariable(),e=this.paginationProxy.getPageFirstRow(),t=this.paginationProxy.getPageLastRow();else{const i=this.getRowBufferInPixels(),r=this.ctrlsService.getGridBodyCtrl(),n=this.gos.get("suppressRowVirtualisation");let s,o,a=!1;do{const e=this.paginationProxy.getPixelOffset(),{pageFirstPixel:t,pageLastPixel:l}=this.paginationProxy.getCurrentPagePixelRange(),c=this.rowContainerHeightService.getDivStretchOffset(),u=r.getScrollFeature().getVScrollPosition(),h=u.top,d=u.bottom;n?(s=t+c,o=l+c):(s=Math.max(h+e-i,t)+c,o=Math.min(d+e+i,l)+c),this.firstVisibleVPixel=Math.max(h+e,t)+c,this.lastVisibleVPixel=Math.min(d+e,l)+c,a=this.ensureAllRowsInRangeHaveHeightsCalculated(s,o)}while(a);let l=this.paginationProxy.getRowIndexAtPixel(s),c=this.paginationProxy.getRowIndexAtPixel(o);const u=this.paginationProxy.getPageFirstRow(),h=this.paginationProxy.getPageLastRow();l<u&&(l=u),c>h&&(c=h),e=l,t=c}else e=0,t=-1;const i=this.gos.isDomLayout("normal"),r=this.gos.get("suppressMaxRenderedRowRestriction"),n=Math.max(this.getRowBuffer(),500);i&&!r&&t-e>n&&(t=e+n);const s=e!==this.firstRenderedRow,o=t!==this.lastRenderedRow;if(s||o){this.firstRenderedRow=e,this.lastRenderedRow=t;const i={type:ct.EVENT_VIEWPORT_CHANGED,firstRow:e,lastRow:t};this.eventService.dispatchEvent(i)}}dispatchFirstDataRenderedEvent(){if(this.dataFirstRenderedFired)return;this.dataFirstRenderedFired=!0;const e={type:ct.EVENT_FIRST_DATA_RENDERED,firstRow:this.firstRenderedRow,lastRow:this.lastRenderedRow};window.requestAnimationFrame(()=>{this.beans.eventService.dispatchEvent(e)})}ensureAllRowsInRangeHaveHeightsCalculated(e,t){const i=this.paginationProxy.ensureRowHeightsValid(e,t,-1,-1);return i&&this.updateContainerHeights(),i}getFirstVisibleVerticalPixel(){return this.firstVisibleVPixel}getLastVisibleVerticalPixel(){return this.lastVisibleVPixel}getFirstVirtualRenderedRow(){return this.firstRenderedRow}getLastVirtualRenderedRow(){return this.lastRenderedRow}doNotUnVirtualiseRow(e){const t=!1,i=e.getRowNode(),r=this.focusService.isRowNodeFocused(i),n=e.isEditing(),s=i.detail;return(r||n||s)&&!!this.paginationProxy.isRowPresent(i)||t}createRowCon(e,t,i){const r=this.cachedRowCtrls?this.cachedRowCtrls.getRow(e):null;if(r)return r;const n=this.gos.get("suppressAnimationFrame"),s=i&&!n&&!this.printLayout;return new Ca(e,this.beans,t,s,this.printLayout)}getRenderedNodes(){const e=this.rowCtrlsByRowIndex;return Object.values(e).map(e=>e.getRowNode())}getRowByPosition(e){let t;const{rowIndex:i}=e;switch(e.rowPinned){case"top":t=this.topRowCtrls[i];break;case"bottom":t=this.bottomRowCtrls[i];break;default:t=this.rowCtrlsByRowIndex[i],t||(t=this.getStickyTopRowCtrls().find(e=>e.getRowNode().rowIndex===i)||null,t||(t=this.getStickyBottomRowCtrls().find(e=>e.getRowNode().rowIndex===i)||null))}return t}isRangeInRenderedViewport(e,t){if(null==e||null==t)return!1;const i=e>this.lastRenderedRow;return!(t<this.firstRenderedRow||i)}};g([he("animationFrameService")],Nl.prototype,"animationFrameService",2),g([he("paginationProxy")],Nl.prototype,"paginationProxy",2),g([he("columnModel")],Nl.prototype,"columnModel",2),g([he("pinnedRowModel")],Nl.prototype,"pinnedRowModel",2),g([he("rowModel")],Nl.prototype,"rowModel",2),g([he("focusService")],Nl.prototype,"focusService",2),g([he("beans")],Nl.prototype,"beans",2),g([he("rowContainerHeightService")],Nl.prototype,"rowContainerHeightService",2),g([he("ctrlsService")],Nl.prototype,"ctrlsService",2),g([le],Nl.prototype,"postConstruct",1),Nl=g([ue("rowRenderer")],Nl);var Ol=class{constructor(e){this.entriesMap={},this.entriesList=[],this.maxCount=e}addRow(e){if(this.entriesMap[e.getRowNode().id]=e,this.entriesList.push(e),e.setCached(!0),this.entriesList.length>this.maxCount){const e=this.entriesList[0];e.destroyFirstPass(),e.destroySecondPass(),this.removeFromCache(e)}}getRow(e){if(null==e||null==e.id)return null;const t=this.entriesMap[e.id];return t?(this.removeFromCache(t),t.setCached(!1),t.getRowNode()!=e?null:t):null}has(e){return null!=this.entriesMap[e.id]}removeRow(e){const t=e.id,i=this.entriesMap[t];delete this.entriesMap[t],Oe(this.entriesList,i)}removeFromCache(e){const t=e.getRowNode().id;delete this.entriesMap[t],Oe(this.entriesList,e)}getEntries(){return this.entriesList}},Fl=class extends nt{init(){this.setPinnedTopRowData(),this.setPinnedBottomRowData(),this.addManagedPropertyListener("pinnedTopRowData",()=>this.setPinnedTopRowData()),this.addManagedPropertyListener("pinnedBottomRowData",()=>this.setPinnedBottomRowData())}isEmpty(e){return S("top"===e?this.pinnedTopRows:this.pinnedBottomRows)}isRowsToRender(e){return!this.isEmpty(e)}getRowAtPixel(e,t){const i="top"===t?this.pinnedTopRows:this.pinnedBottomRows;if(S(i))return 0;for(let t=0;t<i.length;t++){const r=i[t];if(r.rowTop+r.rowHeight-1>=e)return t}return i.length-1}setPinnedTopRowData(){const e=this.gos.get("pinnedTopRowData");this.pinnedTopRows=this.createNodesFromData(e,!0);const t={type:ct.EVENT_PINNED_ROW_DATA_CHANGED};this.eventService.dispatchEvent(t)}setPinnedBottomRowData(){const e=this.gos.get("pinnedBottomRowData");this.pinnedBottomRows=this.createNodesFromData(e,!1);const t={type:ct.EVENT_PINNED_ROW_DATA_CHANGED};this.eventService.dispatchEvent(t)}createNodesFromData(e,t){const i=[];if(e){let r=0;e.forEach((e,n)=>{const s=new Ns(this.beans);s.data=e;const o=t?Ns.ID_PREFIX_TOP_PINNED:Ns.ID_PREFIX_BOTTOM_PINNED;s.id=o+n,s.rowPinned=t?"top":"bottom",s.setRowTop(r),s.setRowHeight(this.gos.getRowHeightForNode(s).height),s.setRowIndex(n),r+=s.rowHeight,i.push(s)})}return i}getPinnedTopRowData(){return this.pinnedTopRows}getPinnedBottomRowData(){return this.pinnedBottomRows}getPinnedTopTotalHeight(){return this.getTotalHeight(this.pinnedTopRows)}getPinnedTopRowCount(){return this.pinnedTopRows?this.pinnedTopRows.length:0}getPinnedBottomRowCount(){return this.pinnedBottomRows?this.pinnedBottomRows.length:0}getPinnedTopRow(e){return this.pinnedTopRows[e]}getPinnedBottomRow(e){return this.pinnedBottomRows[e]}forEachPinnedTopRow(e){S(this.pinnedTopRows)||this.pinnedTopRows.forEach(e)}forEachPinnedBottomRow(e){S(this.pinnedBottomRows)||this.pinnedBottomRows.forEach(e)}getPinnedBottomTotalHeight(){return this.getTotalHeight(this.pinnedBottomRows)}getTotalHeight(e){if(!e||0===e.length)return 0;const t=Pe(e);return t.rowTop+t.rowHeight}};g([he("beans")],Fl.prototype,"beans",2),g([le],Fl.prototype,"init",1),Fl=g([ue("pinnedRowModel")],Fl);var kl=(e=>(e.Applied="Applied",e.StoreNotFound="StoreNotFound",e.StoreLoading="StoreLoading",e.StoreWaitingToLoad="StoreWaitingToLoad",e.StoreLoadingFailed="StoreLoadingFailed",e.StoreWrongType="StoreWrongType",e.Cancelled="Cancelled",e.StoreNotStarted="StoreNotStarted",e))(kl||{}),Gl=class{constructor(e,t){this.active=!0,this.nodeIdsToColumns={},this.mapToItems={},this.keepingColumns=e,this.pathRoot={rowNode:t,children:null},this.mapToItems[t.id]=this.pathRoot}setInactive(){this.active=!1}isActive(){return this.active}depthFirstSearchChangedPath(e,t){if(e.children)for(let i=0;i<e.children.length;i++)this.depthFirstSearchChangedPath(e.children[i],t);t(e.rowNode)}depthFirstSearchEverything(e,t,i){if(e.childrenAfterGroup)for(let r=0;r<e.childrenAfterGroup.length;r++){const n=e.childrenAfterGroup[r];n.childrenAfterGroup?this.depthFirstSearchEverything(e.childrenAfterGroup[r],t,i):i&&t(n)}t(e)}forEachChangedNodeDepthFirst(e,t=!1,i=!1){this.active&&!i?this.depthFirstSearchChangedPath(this.pathRoot,e):this.depthFirstSearchEverything(this.pathRoot.rowNode,e,t)}executeFromRootNode(e){e(this.pathRoot.rowNode)}createPathItems(e){let t=e,i=0;for(;!this.mapToItems[t.id];){const e={rowNode:t,children:null};this.mapToItems[t.id]=e,i++,t=t.parent}return i}populateColumnsMap(e,t){if(!this.keepingColumns||!t)return;let i=e;for(;i;)this.nodeIdsToColumns[i.id]||(this.nodeIdsToColumns[i.id]={}),t.forEach(e=>this.nodeIdsToColumns[i.id][e.getId()]=!0),i=i.parent}linkPathItems(e,t){let i=e;for(let e=0;e<t;e++){const e=this.mapToItems[i.id],t=this.mapToItems[i.parent.id];t.children||(t.children=[]),t.children.push(e),i=i.parent}}addParentNode(e,t){if(!e||e.isRowPinned())return;const i=this.createPathItems(e);this.linkPathItems(e,i),this.populateColumnsMap(e,t)}canSkip(e){return this.active&&!this.mapToItems[e.id]}getValueColumnsForNode(e,t){if(!this.keepingColumns)return t;const i=this.nodeIdsToColumns[e.id];return t.filter(e=>i[e.getId()])}getNotValueColumnsForNode(e,t){if(!this.keepingColumns)return null;const i=this.nodeIdsToColumns[e.id];return t.filter(e=>!i[e.getId()])}},Vl=class e extends nt{constructor(t){super(),this.state=e.STATE_WAITING_TO_LOAD,this.version=0,this.id=t}getId(){return this.id}load(){this.state=e.STATE_LOADING,this.loadFromDatasource()}getVersion(){return this.version}setStateWaitingToLoad(){this.version++,this.state=e.STATE_WAITING_TO_LOAD}getState(){return this.state}pageLoadFailed(t){this.isRequestMostRecentAndLive(t)&&(this.state=e.STATE_FAILED,this.processServerFail()),this.dispatchLoadCompleted(!1)}success(e,t){this.successCommon(e,t)}pageLoaded(e,t,i){this.successCommon(e,{rowData:t,rowCount:i})}isRequestMostRecentAndLive(e){const t=e===this.version,i=this.isAlive();return t&&i}successCommon(t,i){this.dispatchLoadCompleted(),this.isRequestMostRecentAndLive(t)&&(this.state=e.STATE_LOADED,this.processServerResult(i))}dispatchLoadCompleted(t=!0){const i={type:e.EVENT_LOAD_COMPLETE,success:t,block:this};this.dispatchEvent(i)}};Vl.EVENT_LOAD_COMPLETE="loadComplete",Vl.STATE_WAITING_TO_LOAD="needsLoading",Vl.STATE_LOADING="loading",Vl.STATE_LOADED="loaded",Vl.STATE_FAILED="failed";var Hl=Vl,Bl=class extends nt{constructor(){super(...arguments),this.activeBlockLoadsCount=0,this.blocks=[],this.active=!0}postConstruct(){this.maxConcurrentRequests=this.getMaxConcurrentDatasourceRequests();const e=this.gos.get("blockLoadDebounceMillis");e&&e>0&&(this.checkBlockToLoadDebounce=cn.debounce(this.performCheckBlocksToLoad.bind(this),e))}setBeans(e){this.logger=e.create("RowNodeBlockLoader")}getMaxConcurrentDatasourceRequests(){const e=this.gos.get("maxConcurrentDatasourceRequests");return null==e?2:e<=0?void 0:e}addBlock(e){this.blocks.push(e),e.addEventListener(Hl.EVENT_LOAD_COMPLETE,this.loadComplete.bind(this)),this.checkBlockToLoad()}removeBlock(e){cn.removeFromArray(this.blocks,e)}destroy(){super.destroy(),this.active=!1}loadComplete(){this.activeBlockLoadsCount--,this.checkBlockToLoad(),this.dispatchEvent({type:Bl.BLOCK_LOADED_EVENT}),0==this.activeBlockLoadsCount&&this.dispatchEvent({type:Bl.BLOCK_LOADER_FINISHED_EVENT})}checkBlockToLoad(){this.checkBlockToLoadDebounce?this.checkBlockToLoadDebounce():this.performCheckBlocksToLoad()}performCheckBlocksToLoad(){if(!this.active)return;if(this.printCacheStatus(),null!=this.maxConcurrentRequests&&this.activeBlockLoadsCount>=this.maxConcurrentRequests)return void this.logger.log("checkBlockToLoad: max loads exceeded");const e=this.getAvailableLoadingCount(),t=this.blocks.filter(e=>e.getState()===Hl.STATE_WAITING_TO_LOAD).slice(0,e);this.registerLoads(t.length),t.forEach(e=>e.load()),this.printCacheStatus()}getBlockState(){if(this.gos.isRowModelType("serverSide"))return this.rowModel.getBlockStates();const e={};return this.blocks.forEach(t=>{const{id:i,state:r}=t.getBlockStateJson();e[i]=r}),e}printCacheStatus(){this.logger.isLogging()&&this.logger.log(`printCacheStatus: activePageLoadsCount = ${this.activeBlockLoadsCount}, blocks = ${JSON.stringify(this.getBlockState())}`)}isLoading(){return this.activeBlockLoadsCount>0}registerLoads(e){this.activeBlockLoadsCount+=e}getAvailableLoadingCount(){return void 0!==this.maxConcurrentRequests?this.maxConcurrentRequests-this.activeBlockLoadsCount:void 0}};Bl.BLOCK_LOADED_EVENT="blockLoaded",Bl.BLOCK_LOADER_FINISHED_EVENT="blockLoaderFinished",g([he("rowModel")],Bl.prototype,"rowModel",2),g([le],Bl.prototype,"postConstruct",1),g([f(0,ge("loggerFactory"))],Bl.prototype,"setBeans",1),Bl=g([ue("rowNodeBlockLoader")],Bl);var zl=class extends nt{constructor(){super(...arguments),this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=0,this.pixelOffset=0,this.masterRowCount=0}postConstruct(){this.active=this.gos.get("pagination"),this.pageSizeFromGridOptions=this.gos.get("paginationPageSize"),this.paginateChildRows=this.isPaginateChildRows(),this.addManagedListener(this.eventService,ct.EVENT_MODEL_UPDATED,this.onModelUpdated.bind(this)),this.addManagedPropertyListener("pagination",this.onPaginationGridOptionChanged.bind(this)),this.addManagedPropertyListener("paginationPageSize",this.onPageSizeGridOptionChanged.bind(this)),this.onModelUpdated()}ensureRowHeightsValid(e,t,i,r){const n=this.rowModel.ensureRowHeightsValid(e,t,this.getPageFirstRow(),this.getPageLastRow());return n&&this.calculatePages(),n}isPaginateChildRows(){return!(!this.gos.get("groupRemoveSingleChildren")&&!this.gos.get("groupRemoveLowestSingleChildren"))||this.gos.get("paginateChildRows")}onModelUpdated(e){this.calculatePages();const t={type:ct.EVENT_PAGINATION_CHANGED,animate:!!e&&e.animate,newData:!!e&&e.newData,newPage:!!e&&e.newPage,newPageSize:!!e&&e.newPageSize,keepRenderedRows:!!e&&e.keepRenderedRows};this.eventService.dispatchEvent(t)}onPaginationGridOptionChanged(){this.active=this.gos.get("pagination"),this.calculatePages();const e={type:ct.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!1,keepRenderedRows:!0};this.eventService.dispatchEvent(e)}onPageSizeGridOptionChanged(){this.setPageSize(this.gos.get("paginationPageSize"),"gridOptions")}goToPage(e){if(!this.active||this.currentPage===e||"number"!=typeof this.currentPage)return;this.currentPage=e,this.calculatePages();const t={type:ct.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!0,newPageSize:!1,keepRenderedRows:!1};this.eventService.dispatchEvent(t)}getPixelOffset(){return this.pixelOffset}getRow(e){return this.rowModel.getRow(e)}getRowNode(e){return this.rowModel.getRowNode(e)}getRowIndexAtPixel(e){return this.rowModel.getRowIndexAtPixel(e)}getCurrentPageHeight(){return w(this.topRowBounds)||w(this.bottomRowBounds)?0:Math.max(this.bottomRowBounds.rowTop+this.bottomRowBounds.rowHeight-this.topRowBounds.rowTop,0)}getCurrentPagePixelRange(){return{pageFirstPixel:this.topRowBounds?this.topRowBounds.rowTop:0,pageLastPixel:this.bottomRowBounds?this.bottomRowBounds.rowTop+this.bottomRowBounds.rowHeight:0}}isRowPresent(e){return!!this.rowModel.isRowPresent(e)&&(e.rowIndex>=this.topDisplayedRowIndex&&e.rowIndex<=this.bottomDisplayedRowIndex)}isEmpty(){return this.rowModel.isEmpty()}isRowsToRender(){return this.rowModel.isRowsToRender()}forEachNode(e){return this.rowModel.forEachNode(e)}forEachNodeOnPage(e){const t=this.getPageFirstRow(),i=this.getPageLastRow();for(let r=t;r<=i;r++){const t=this.getRow(r);t&&e(t)}}getType(){return this.rowModel.getType()}getRowBounds(e){const t=this.rowModel.getRowBounds(e);return t.rowIndex=e,t}getPageFirstRow(){return this.topRowBounds?this.topRowBounds.rowIndex:-1}getPageLastRow(){return this.bottomRowBounds?this.bottomRowBounds.rowIndex:-1}getRowCount(){return this.rowModel.getRowCount()}getPageForIndex(e){return Math.floor(e/this.pageSize)}goToPageWithIndex(e){if(!this.active)return;const t=this.getPageForIndex(e);this.goToPage(t)}isRowInPage(e){return!this.active||this.getPageForIndex(e.rowIndex)===this.currentPage}isLastPageFound(){return this.rowModel.isLastRowIndexKnown()}getCurrentPage(){return this.currentPage}goToNextPage(){this.goToPage(this.currentPage+1)}goToPreviousPage(){this.goToPage(this.currentPage-1)}goToFirstPage(){this.goToPage(0)}goToLastPage(){const e=this.rowModel.getRowCount(),t=Math.floor(e/this.pageSize);this.goToPage(t)}getPageSize(){return this.pageSize}getTotalPages(){return this.totalPages}setPage(e){this.currentPage=e}get pageSize(){return y(this.pageSizeAutoCalculated)?this.pageSizeAutoCalculated:y(this.pageSizeFromPageSizeSelector)?this.pageSizeFromPageSizeSelector:y(this.pageSizeFromInitialState)?this.pageSizeFromInitialState:y(this.pageSizeFromGridOptions)?this.pageSizeFromGridOptions:this.defaultPageSize}unsetAutoCalculatedPageSize(){if(void 0===this.pageSizeAutoCalculated)return;const e=this.pageSizeAutoCalculated;if(this.pageSizeAutoCalculated=void 0,this.pageSize===e)return;this.calculatePages();const t={type:ct.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!0,keepRenderedRows:!1};this.eventService.dispatchEvent(t)}setPageSize(e,t){const i=this.pageSize;switch(t){case"autoCalculated":this.pageSizeAutoCalculated=e;break;case"pageSizeSelector":this.pageSizeFromPageSizeSelector=e,0!==this.currentPage&&this.goToFirstPage();break;case"initialState":this.pageSizeFromInitialState=e;break;case"gridOptions":this.pageSizeFromGridOptions=e,this.pageSizeFromInitialState=void 0,this.pageSizeFromPageSizeSelector=void 0,0!==this.currentPage&&this.goToFirstPage()}if(i!==this.pageSize){this.calculatePages();const e={type:ct.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!0,keepRenderedRows:!0};this.eventService.dispatchEvent(e)}}calculatePages(){this.active?this.paginateChildRows?this.calculatePagesAllRows():this.calculatePagesMasterRowsOnly():this.calculatedPagesNotActive(),this.topRowBounds=this.rowModel.getRowBounds(this.topDisplayedRowIndex),this.topRowBounds&&(this.topRowBounds.rowIndex=this.topDisplayedRowIndex),this.bottomRowBounds=this.rowModel.getRowBounds(this.bottomDisplayedRowIndex),this.bottomRowBounds&&(this.bottomRowBounds.rowIndex=this.bottomDisplayedRowIndex),this.setPixelOffset(y(this.topRowBounds)?this.topRowBounds.rowTop:0)}setPixelOffset(e){this.pixelOffset!==e&&(this.pixelOffset=e,this.eventService.dispatchEvent({type:ct.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED}))}setZeroRows(){this.masterRowCount=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=-1,this.currentPage=0,this.totalPages=0}adjustCurrentPageIfInvalid(){this.currentPage>=this.totalPages&&(this.currentPage=this.totalPages-1),(!isFinite(this.currentPage)||isNaN(this.currentPage)||this.currentPage<0)&&(this.currentPage=0)}calculatePagesMasterRowsOnly(){if(this.masterRowCount=this.rowModel.getTopLevelRowCount(),this.masterRowCount<=0)return void this.setZeroRows();const e=this.masterRowCount-1;this.totalPages=Math.floor(e/this.pageSize)+1,this.adjustCurrentPageIfInvalid();const t=this.pageSize*this.currentPage;let i=this.pageSize*(this.currentPage+1)-1;if(i>e&&(i=e),this.topDisplayedRowIndex=this.rowModel.getTopLevelRowDisplayedIndex(t),i===e)this.bottomDisplayedRowIndex=this.rowModel.getRowCount()-1;else{const e=this.rowModel.getTopLevelRowDisplayedIndex(i+1);this.bottomDisplayedRowIndex=e-1}}getMasterRowCount(){return this.masterRowCount}calculatePagesAllRows(){if(this.masterRowCount=this.rowModel.getRowCount(),0===this.masterRowCount)return void this.setZeroRows();const e=this.masterRowCount-1;this.totalPages=Math.floor(e/this.pageSize)+1,this.adjustCurrentPageIfInvalid(),this.topDisplayedRowIndex=this.pageSize*this.currentPage,this.bottomDisplayedRowIndex=this.pageSize*(this.currentPage+1)-1,this.bottomDisplayedRowIndex>e&&(this.bottomDisplayedRowIndex=e)}calculatedPagesNotActive(){this.setPageSize(void 0,"autoCalculated"),this.totalPages=1,this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=this.rowModel.getRowCount()-1}};g([he("rowModel")],zl.prototype,"rowModel",2),g([le],zl.prototype,"postConstruct",1),zl=g([ue("paginationProxy")],zl);var Ul=class extends nt{processAllCellClasses(e,t,i,r){this.processClassRules(void 0,e.cellClassRules,t,i,r),this.processStaticCellClasses(e,t,i)}processClassRules(e,t,i,r,n){if(null==t&&null==e)return;const s={},o={},a=(e,t)=>{e.split(" ").forEach(e=>{""!=e.trim()&&t(e)})};if(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r],l=t[n];let c;"string"==typeof l?c=this.expressionService.evaluate(l,i):"function"==typeof l&&(c=l(i)),a(n,e=>{c?s[e]=!0:o[e]=!0})}}e&&n&&Object.keys(e).forEach(e=>a(e,e=>{s[e]||(o[e]=!0)})),n&&Object.keys(o).forEach(n),Object.keys(s).forEach(r)}getStaticCellClasses(e,t){const{cellClass:i}=e;if(!i)return[];let r;return r="function"==typeof i?i(t):i,"string"==typeof r&&(r=[r]),r||[]}processStaticCellClasses(e,t,i){this.getStaticCellClasses(e,t).forEach(e=>{i(e)})}};g([he("expressionService")],Ul.prototype,"expressionService",2),Ul=g([ue("stylingService")],Ul);var Wl=class extends Un{constructor(e){super(e,"ag-toggle-button")}setValue(e,t){return super.setValue(e,t),this.addOrRemoveCssClass("ag-selected",this.getValue()),this}},jl=class extends zn{constructor(e){super(e,"ag-text-area",null,"textarea")}setValue(e,t){const i=super.setValue(e,t);return this.eInput.value=e,i}setCols(e){return this.eInput.cols=e,this}setRows(e){return this.eInput.rows=e,this}},Kl=class extends is{constructor(e){super(e,"ag-date-field","date")}postConstruct(){super.postConstruct(),this.addManagedListener(this.eInput,"wheel",this.onWheel.bind(this));const e=Ri();this.addManagedListener(this.eInput,"mousedown",()=>{this.isDisabled()||e||this.eInput.focus()}),this.eInput.step="any"}onWheel(e){this.gos.getActiveDomElement()===this.eInput&&e.preventDefault()}setMin(e){var t;const i=e instanceof Date?null!=(t=Qi(null!=e?e:null,!1))?t:void 0:e;return this.min===i||(this.min=i,Gr(this.eInput,"min",i)),this}setMax(e){var t;const i=e instanceof Date?null!=(t=Qi(null!=e?e:null,!1))?t:void 0:e;return this.max===i||(this.max=i,Gr(this.eInput,"max",i)),this}setStep(e){return this.step===e||(this.step=e,Gr(this.eInput,"step",e)),this}getDate(){var e;if(this.eInput.validity.valid)return null!=(e=Ji(this.getValue()))?e:void 0}setDate(e,t){this.setValue(Qi(null!=e?e:null,!1),t)}},$l=class extends zn{constructor(e){super(e,"ag-range-field","range")}postConstruct(){super.postConstruct();const{min:e,max:t,step:i}=this.config;null!=e&&this.setMinValue(e),null!=t&&this.setMaxValue(t),this.setStep(i||1)}addInputListeners(){this.addManagedListener(this.eInput,"input",e=>{const t=e.target.value;this.setValue(t)})}setMinValue(e){return this.min=e,this.eInput.setAttribute("min",e.toString()),this}setMaxValue(e){return this.max=e,this.eInput.setAttribute("max",e.toString()),this}setStep(e){return this.eInput.setAttribute("step",e.toString()),this}setValue(e,t){null!=this.min&&(e=Math.max(parseFloat(e),this.min).toString()),null!=this.max&&(e=Math.min(parseFloat(e),this.max).toString());const i=super.setValue(e,t);return this.eInput.value=e,i}},ql=class extends wn{constructor(e,t){super('<div class="ag-rich-select-row" role="presentation"></div>'),this.params=e,this.wrapperEl=t}postConstruct(){this.addManagedListener(this.getGui(),"click",this.onClick.bind(this))}setState(e){let t="";this.params.valueFormatter&&(t=this.params.valueFormatter(e)),this.populateWithRenderer(e,t)||this.populateWithoutRenderer(e,t),this.value=e}highlightString(e){const{parsedValue:t}=this;if(this.params.cellRenderer||!y(t))return;let i=y(e);if(i){const r=null==t?void 0:t.toLocaleLowerCase().indexOf(e.toLocaleLowerCase());if(r>=0){const i=r+e.length,n=yt(t.slice(0,r),!0),s=yt(t.slice(r,i),!0),o=yt(t.slice(i));this.renderValueWithoutRenderer(`${n}<span class="ag-rich-select-row-text-highlight">${s}</span>${o}`)}else i=!1}i||this.renderValueWithoutRenderer(t)}updateHighlighted(e){var t;const i=this.getGui(),r=`ag-rich-select-row-${this.getCompId()}`;null==(t=i.parentElement)||t.setAttribute("id",r),e&&(ti(this.getParentComponent().getAriaElement(),r),this.wrapperEl.setAttribute("data-active-option",r)),gi(i.parentElement,e),this.addOrRemoveCssClass("ag-rich-select-row-selected",e)}populateWithoutRenderer(e,t){const i=this.gos.getDocument(),r=this.getGui(),n=i.createElement("span");n.style.overflow="hidden",n.style.textOverflow="ellipsis";const s=yt(y(t)?t:e,!0);this.parsedValue=y(s)?s:null,r.appendChild(n),this.renderValueWithoutRenderer(s),this.setTooltip({newTooltipText:this.parsedValue,shouldDisplayTooltip:()=>n.scrollWidth>n.clientWidth})}renderValueWithoutRenderer(e){const t=this.getGui().querySelector("span");t&&(t.innerHTML=y(e)?e:"&nbsp;")}populateWithRenderer(e,t){let i,r;return this.params.cellRenderer&&(r=this.userComponentFactory.getCellRendererDetails(this.params,{value:e,valueFormatted:t,setTooltip:(e,t)=>{this.setTooltip({newTooltipText:e,shouldDisplayTooltip:t})}})),r&&(i=r.newAgStackInstance()),i&&Hr(i,this.getGui()),!!i&&(i.then(e=>{this.addDestroyFunc(()=>{this.getContext().destroyBean(e)})}),!0)}onClick(){const e=this.getParentComponent(),t={type:ct.EVENT_FIELD_PICKER_VALUE_SELECTED,fromEnterKey:!1,value:this.value};null==e||e.dispatchEvent(t)}};g([he("userComponentFactory")],ql.prototype,"userComponentFactory",2),g([le],ql.prototype,"postConstruct",1);var Yl=class e extends Al{constructor(t){super(e.getTemplate((null==t?void 0:t.cssIdentifier)||"default")),this.renderedRows=new Map,this.rowHeight=20,this.pageSize=-1,this.isScrolling=!1,this.isHeightFromTheme=!0;const{cssIdentifier:i="default",ariaRole:r="listbox",listName:n}=t||{};this.cssIdentifier=i,this.ariaRole=r,this.listName=n}postConstruct(){this.addScrollListener(),this.rowHeight=this.getItemHeight(),this.addResizeObserver(),this.initialiseTabGuard({onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e),focusInnerElement:e=>this.focusInnerElement(e),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e)}),this.setAriaProperties(),this.addManagedListener(this.eventService,ct.EVENT_GRID_STYLES_CHANGED,this.onGridStylesChanged.bind(this))}onGridStylesChanged(){this.rowHeight=this.getItemHeight(),this.refresh()}setAriaProperties(){const e=this.localeService.getLocaleTextFunc()("ariaDefaultListName",this.listName||"List"),t=this.eContainer;Bt(t,this.ariaRole),Kt(t,e)}addResizeObserver(){const e=this.resizeObserverService.observeResize(this.getGui(),()=>this.animationFrameService.requestAnimationFrame(()=>this.drawVirtualRows()));this.addDestroyFunc(e)}focusInnerElement(e){this.focusRow(e?this.model.getRowCount()-1:0)}onFocusIn(e){const t=e.target;t.classList.contains("ag-virtual-list-item")&&(this.lastFocusedRowIndex=Wt(t)-1)}onFocusOut(e){this.getFocusableElement().contains(e.relatedTarget)||(this.lastFocusedRowIndex=null)}handleKeyDown(e){switch(e.key){case Qr.UP:case Qr.DOWN:this.navigate(e.key===Qr.UP)&&e.preventDefault();break;case Qr.PAGE_HOME:case Qr.PAGE_END:case Qr.PAGE_UP:case Qr.PAGE_DOWN:null!==this.navigateToPage(e.key)&&e.preventDefault()}}onTabKeyDown(e){this.navigate(e.shiftKey)?e.preventDefault():(Ye(e),this.forceFocusOutOfContainer(e.shiftKey))}navigate(e){if(null==this.lastFocusedRowIndex)return!1;const t=this.lastFocusedRowIndex+(e?-1:1);return!(t<0||t>=this.model.getRowCount()||(this.focusRow(t),0))}navigateToPage(e,t="focused"){let i=!1;"focused"===t&&(t=this.getLastFocusedRow(),i=!0);const r=this.model.getRowCount()-1;let n=-1;return e===Qr.PAGE_HOME?n=0:e===Qr.PAGE_END?n=r:e===Qr.PAGE_DOWN?n=Math.min(t+this.pageSize,r):e===Qr.PAGE_UP&&(n=Math.max(t-this.pageSize,0)),-1===n?null:(i?this.focusRow(n):this.ensureIndexVisible(n),n)}getLastFocusedRow(){return this.lastFocusedRowIndex}focusRow(e){this.isScrolling||(this.isScrolling=!0,this.ensureIndexVisible(e),this.animationFrameService.requestAnimationFrame(()=>{if(this.isScrolling=!1,!this.isAlive())return;const t=this.renderedRows.get(e);t&&t.eDiv.focus()}))}getComponentAt(e){const t=this.renderedRows.get(e);return t&&t.rowComponent}forEachRenderedRow(e){this.renderedRows.forEach((t,i)=>e(t.rowComponent,i))}static getTemplate(e){return`<div class="ag-virtual-list-viewport ag-${e}-virtual-list-viewport" role="presentation">\n                <div class="ag-virtual-list-container ag-${e}-virtual-list-container" ref="eContainer"></div>\n            </div>`}getItemHeight(){return this.isHeightFromTheme?this.environment.getListItemHeight():this.rowHeight}ensureIndexVisible(e,t=!0){const i=this.model.getRowCount();if("number"!=typeof e||e<0||e>=i)return console.warn("AG Grid: invalid row index for ensureIndexVisible: "+e),!1;const r=e*this.rowHeight,n=r+this.rowHeight,s=this.getGui(),o=s.scrollTop,a=s.offsetHeight,l=o+a,c=t?0:this.rowHeight,u=l<n-c;if(o>r+c)return s.scrollTop=r,!0;if(u){const e=n-a;return s.scrollTop=e,!0}return!1}setComponentCreator(e){this.componentCreator=e}setComponentUpdater(e){this.componentUpdater=e}getRowHeight(){return this.rowHeight}getScrollTop(){return this.getGui().scrollTop}setRowHeight(e){this.isHeightFromTheme=!1,this.rowHeight=e,this.refresh()}refresh(e){if(null==this.model||!this.isAlive())return;const t=this.model.getRowCount();this.eContainer.style.height=t*this.rowHeight+"px",ee(()=>this.eContainer.clientHeight>=t*this.rowHeight,()=>{this.isAlive()&&(this.canSoftRefresh(e)?this.drawVirtualRows(!0):(this.clearVirtualRows(),this.drawVirtualRows()))})}canSoftRefresh(e){return!!(e&&this.renderedRows.size&&"function"==typeof this.model.areRowsEqual&&this.componentUpdater)}clearVirtualRows(){this.renderedRows.forEach((e,t)=>this.removeRow(t))}drawVirtualRows(e){if(!this.isAlive()||!this.model)return;const t=this.getGui(),i=t.scrollTop,r=i+t.offsetHeight,n=Math.floor(i/this.rowHeight),s=Math.floor(r/this.rowHeight);this.pageSize=Math.floor((r-i)/this.rowHeight),this.ensureRowsRendered(n,s,e)}ensureRowsRendered(e,t,i){this.renderedRows.forEach((i,r)=>{(r<e||r>t)&&r!==this.lastFocusedRowIndex&&this.removeRow(r)}),i&&this.refreshRows();for(let i=e;i<=t;i++)this.renderedRows.has(i)||i<this.model.getRowCount()&&this.insertRow(i)}insertRow(e){const t=this.model.getRow(e),i=document.createElement("div");i.classList.add("ag-virtual-list-item",`ag-${this.cssIdentifier}-virtual-list-item`),Bt(i,"tree"===this.ariaRole?"treeitem":"option"),ni(i,this.model.getRowCount()),si(i,e+1),i.setAttribute("tabindex","-1"),i.style.height=`${this.rowHeight}px`,i.style.top=this.rowHeight*e+"px";const r=this.componentCreator(t,i);r.addGuiEventListener("focusin",()=>this.lastFocusedRowIndex=e),i.appendChild(r.getGui()),this.renderedRows.has(e-1)?this.renderedRows.get(e-1).eDiv.insertAdjacentElement("afterend",i):this.renderedRows.has(e+1)?this.renderedRows.get(e+1).eDiv.insertAdjacentElement("beforebegin",i):this.eContainer.appendChild(i),this.renderedRows.set(e,{rowComponent:r,eDiv:i,value:t})}removeRow(e){const t=this.renderedRows.get(e);this.eContainer.removeChild(t.eDiv),this.destroyBean(t.rowComponent),this.renderedRows.delete(e)}refreshRows(){const e=this.model.getRowCount();this.renderedRows.forEach((t,i)=>{var r,n;if(i>=e)this.removeRow(i);else{const e=this.model.getRow(i);(null==(n=(r=this.model).areRowsEqual)?void 0:n.call(r,t.value,e))?this.componentUpdater(e,t.rowComponent):this.removeRow(i)}})}addScrollListener(){this.addGuiEventListener("scroll",()=>this.drawVirtualRows(),{passive:!0})}setModel(e){this.model=e}getAriaElement(){return this.eContainer}destroy(){this.isAlive()&&(this.clearVirtualRows(),super.destroy())}};g([he("resizeObserverService")],Yl.prototype,"resizeObserverService",2),g([he("animationFrameService")],Yl.prototype,"animationFrameService",2),g([bn("eContainer")],Yl.prototype,"eContainer",2),g([le],Yl.prototype,"postConstruct",1);var Ql=Yl,Xl=class extends kn{constructor(e){var t,i;super(d(h({pickerAriaLabelKey:"ariaLabelRichSelectField",pickerAriaLabelValue:"Rich Select Field",pickerType:"ag-list",className:"ag-rich-select",pickerIcon:"smallDown",ariaRole:"combobox",template:null!=(t=null==e?void 0:e.template)?t:'\n    <div class="ag-picker-field" role="presentation">\n        <div ref="eLabel"></div>\n            <div ref="eWrapper" class="ag-wrapper ag-picker-field-wrapper ag-rich-select-value ag-picker-collapsed">\n            <div ref="eDisplayField" class="ag-picker-field-display"></div>\n            <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n            <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n        </div>\n    </div>',modalPicker:!1},e),{maxPickerHeight:null!=(i=null==e?void 0:e.maxPickerHeight)?i:"calc(var(--ag-row-height) * 6.5)"})),this.searchString="",this.highlightedItem=-1,this.lastRowHovered=-1,this.searchStringCreator=null;const{cellRowHeight:r,value:n,valueList:s,searchStringCreator:o}=e||{};null!=r&&(this.cellRowHeight=r),void 0!==n&&(this.value=n),null!=s&&(this.values=s),o&&(this.searchStringCreator=o)}postConstruct(){super.postConstruct(),this.createLoadingElement(),this.createListComponent();const{allowTyping:e,placeholder:t}=this.config;e?(this.eInput.setAutoComplete(!1).setInputPlaceholder(t),this.eDisplayField.classList.add("ag-hidden")):this.eInput.setDisplayed(!1),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{searchDebounceDelay:i=300}=this.config;this.clearSearchString=Z(this.clearSearchString,i),this.renderSelectedValue(),e&&(this.eInput.onValueChange(e=>this.searchTextFromString(e)),this.addManagedListener(this.eWrapper,"focus",this.onWrapperFocus.bind(this))),this.addManagedListener(this.eWrapper,"focusout",this.onWrapperFocusOut.bind(this))}createLoadingElement(){const e=this.gos.getDocument(),t=this.localeService.getLocaleTextFunc(),i=e.createElement("div");i.classList.add("ag-loading-text"),i.innerText=t("loadingOoo","Loading..."),this.eLoading=i}createListComponent(){this.listComponent=this.createBean(new Ql({cssIdentifier:"rich-select"})),this.listComponent.setComponentCreator(this.createRowComponent.bind(this)),this.listComponent.setComponentUpdater((e,t)=>{}),this.listComponent.setParentComponent(this),this.addManagedListener(this.listComponent,ct.EVENT_FIELD_PICKER_VALUE_SELECTED,e=>{this.onListValueSelected(e.value,e.fromEnterKey)});const{cellRowHeight:e}=this;e&&this.listComponent.setRowHeight(e);const t=this.listComponent.getGui(),i=this.listComponent.getAriaElement();this.addManagedListener(t,"mousemove",this.onPickerMouseMove.bind(this)),this.addManagedListener(t,"mousedown",e=>e.preventDefault()),t.classList.add("ag-rich-select-list");const r=`ag-rich-select-list-${this.listComponent.getCompId()}`;i.setAttribute("id",r),Kt(i,this.localeService.getLocaleTextFunc()(this.config.pickerAriaLabelKey,this.config.pickerAriaLabelValue)),mi(this.eWrapper,i)}renderSelectedValue(){const{value:e,eDisplayField:t,config:i}=this,{allowTyping:r,initialInputValue:n}=this.config,s=this.config.valueFormatter?this.config.valueFormatter(e):e;if(r)return void this.eInput.setValue(null!=n?n:s);let o,a;if(i.cellRenderer&&(o=this.userComponentFactory.getCellRendererDetails(this.config,{value:e,valueFormatted:s})),o&&(a=o.newAgStackInstance()),a)yr(t),Hr(a,t),a.then(e=>{this.addDestroyFunc(()=>this.getContext().destroyBean(e))});else{if(y(this.value))t.innerText=s,t.classList.remove("ag-display-as-placeholder");else{const{placeholder:e}=i;y(e)?(t.innerHTML=`${yt(e)}`,t.classList.add("ag-display-as-placeholder")):yr(t)}this.setTooltip({newTooltipText:null!=s?s:null,shouldDisplayTooltip:()=>this.eDisplayField.scrollWidth>this.eDisplayField.clientWidth})}}getCurrentValueIndex(){const{currentList:e,value:t}=this;if(null==t||!e)return-1;for(let i=0;i<e.length;i++)if(e[i]===t)return i;return-1}highlightFilterMatch(){var e;null==(e=this.listComponent)||e.forEachRenderedRow((e,t)=>{e.highlightString(this.searchString)})}highlightSelectedValue(e){var t;null==e&&(e=this.getCurrentValueIndex()),this.highlightedItem=e,null==(t=this.listComponent)||t.forEachRenderedRow((t,i)=>{const r=-1!==e&&this.highlightedItem===i;t.updateHighlighted(r)})}setRowHeight(e){e!==this.cellRowHeight&&(this.cellRowHeight=e),this.listComponent&&this.listComponent.setRowHeight(e)}createPickerComponent(){const{values:e}=this;return e&&this.setValueList({valueList:e}),this.listComponent}setSearchStringCreator(e){this.searchStringCreator=e}setValueList(e){const{valueList:t,refresh:i}=e;this.listComponent&&this.currentList!==t&&(this.currentList=t,this.listComponent.setModel({getRowCount:()=>t.length,getRow:e=>t[e],areRowsEqual:(e,t)=>e===t}),i&&(this.values?this.listComponent.refresh(!0):(this.values=t,this.isPickerDisplayed&&this.showCurrentValueInPicker())))}showPicker(){super.showPicker(),this.showCurrentValueInPicker(),this.displayOrHidePicker()}showCurrentValueInPicker(){var e,t;if(!this.listComponent)return;if(!this.currentList)return void(this.isPickerDisplayed&&this.eLoading&&this.listComponent.appendChild(this.eLoading));(null==(e=this.eLoading)?void 0:e.offsetParent)&&(null==(t=this.eLoading.parentElement)||t.removeChild(this.eLoading));const i=this.getCurrentValueIndex();-1!==i?(this.listComponent.refresh(),this.listComponent.ensureIndexVisible(i),this.listComponent.refresh(!0),this.highlightSelectedValue(i)):this.listComponent.refresh()}beforeHidePicker(){this.highlightedItem=-1,super.beforeHidePicker()}onWrapperFocus(){if(!this.eInput)return;const e=this.eInput.getFocusableElement();e.focus(),e.select()}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}buildSearchStringFromKeyboardEvent(e){let{key:t}=e;if(t===Qr.BACKSPACE)this.searchString=this.searchString.slice(0,-1),t="";else if(!Xr(e))return;e.preventDefault(),this.searchTextFromCharacter(t)}searchTextFromCharacter(e){this.searchString+=e,this.runSearch(),this.clearSearchString()}searchTextFromString(e){null==e&&(e=""),this.searchString=e,this.runSearch()}buildSearchStrings(e){const{valueFormatter:t=e=>e}=this.config;let i;return"number"==typeof e[0]||"string"==typeof e[0]?i=e.map(e=>t(e)):"object"==typeof e[0]&&this.searchStringCreator&&(i=this.searchStringCreator(e)),i}getSuggestionsAndFilteredValues(e,t){let i=[],r=[];if(!e.length)return{suggestions:i,filteredValues:r};const{searchType:n="fuzzy",filterList:s}=this.config;if("fuzzy"===n){const e=Ur(this.searchString,t,!0);i=e.values;const n=e.indices;if(s&&n.length)for(let e=0;e<n.length;e++)r.push(this.values[n[e]])}else i=t.filter((e,t)=>{const i=e.toLocaleLowerCase(),o=this.searchString.toLocaleLowerCase(),a="match"===n?i.startsWith(o):-1!==i.indexOf(o);return s&&a&&r.push(this.values[t]),a});return{suggestions:i,filteredValues:r}}filterListModel(e){const{filterList:t}=this.config;t&&(this.setValueList({valueList:e,refresh:!0}),this.alignPickerToComponent())}runSearch(){var e,t;const{values:i}=this,r=this.buildSearchStrings(i);if(!r)return void this.highlightSelectedValue(-1);const{suggestions:n,filteredValues:s}=this.getSuggestionsAndFilteredValues(this.searchString,r),{filterList:o,highlightMatch:a,searchType:l="fuzzy"}=this.config,c=s.length,u=!(!o||""===this.searchString);if(this.filterListModel(u?s:i),n.length){const e=u?0:r.indexOf(n[0]);this.selectListItem(e)}else if(this.highlightSelectedValue(-1),!u||c)null==(e=this.listComponent)||e.ensureIndexVisible(0);else if(u){this.getAriaElement().removeAttribute("data-active-option");const e=null==(t=this.listComponent)?void 0:t.getAriaElement();e&&ti(e,null)}a&&"fuzzy"!==l&&this.highlightFilterMatch(),this.displayOrHidePicker()}displayOrHidePicker(){var e;const t=null==(e=this.listComponent)?void 0:e.getGui(),i=!!this.currentList&&0===this.currentList.length;null==t||t.classList.toggle("ag-hidden",i)}clearSearchString(){this.searchString=""}selectListItem(e,t){!this.isPickerDisplayed||!this.currentList||!this.listComponent||e<0||e>=this.currentList.length||(this.listComponent.ensureIndexVisible(e,!t)&&!t&&this.listComponent.refresh(!0),this.highlightSelectedValue(e))}setValue(e,t,i){const r=this.currentList?this.currentList.indexOf(e):-1;return-1===r?this:(this.value=e,i||this.selectListItem(r),this.renderSelectedValue(),super.setValue(e,t))}createRowComponent(e){const t=new ql(this.config,this.eWrapper);t.setParentComponent(this.listComponent),this.getContext().createBean(t),t.setState(e);const{highlightMatch:i,searchType:r="fuzzy"}=this.config;return i&&"fuzzy"!==r&&t.highlightString(this.searchString),t}getRowForMouseEvent(e){const{listComponent:t}=this;if(!t)return-1;const i=(null==t?void 0:t.getGui()).getBoundingClientRect(),r=t.getScrollTop(),n=e.clientY-i.top+r;return Math.floor(n/t.getRowHeight())}onPickerMouseMove(e){if(!this.listComponent)return;const t=this.getRowForMouseEvent(e);-1!==t&&t!=this.lastRowHovered&&(this.lastRowHovered=t,this.selectListItem(t,!0))}onNavigationKeyDown(e,t){e.preventDefault();const i=t===Qr.DOWN;if(!this.isPickerDisplayed&&i)return void this.showPicker();const r=this.highlightedItem,n=-1===r?0:r+(i?1:-1);this.selectListItem(n)}onPageNavigation(e){var t;if(!this.isPickerDisplayed)return;const i=null==(t=this.listComponent)?void 0:t.navigateToPage(e,this.highlightedItem);null!=i&&this.animationFrameService.requestAnimationFrame(()=>{if(!this.isAlive())return null;this.highlightSelectedValue(i)})}onEnterKeyDown(e){this.isPickerDisplayed&&(e.preventDefault(),this.currentList&&this.onListValueSelected(this.currentList[this.highlightedItem],!0))}onTabKeyDown(){this.isPickerDisplayed&&this.currentList&&this.setValue(this.currentList[this.highlightedItem],!1,!0)}onListValueSelected(e,t){this.setValue(e,!1,!0),this.dispatchPickerEvent(e,t),this.hidePicker()}dispatchPickerEvent(e,t){const i={type:ct.EVENT_FIELD_PICKER_VALUE_SELECTED,fromEnterKey:t,value:e};this.dispatchEvent(i)}getFocusableElement(){const{allowTyping:e}=this.config;return e?this.eInput.getFocusableElement():super.getFocusableElement()}onKeyDown(e){const t=e.key,{allowTyping:i}=this.config;switch(t){case Qr.LEFT:case Qr.RIGHT:i||e.preventDefault();break;case Qr.PAGE_HOME:case Qr.PAGE_END:if(i){e.preventDefault();const i=this.eInput.getInputElement(),r=t===Qr.PAGE_HOME?0:i.value.length;i.setSelectionRange(r,r);break}case Qr.PAGE_UP:case Qr.PAGE_DOWN:e.preventDefault(),this.onPageNavigation(t);break;case Qr.DOWN:case Qr.UP:this.onNavigationKeyDown(e,t);break;case Qr.ESCAPE:this.isPickerDisplayed&&(br(this.listComponent.getGui())&&(e.preventDefault(),Ye(e)),this.hidePicker());break;case Qr.ENTER:this.onEnterKeyDown(e);break;case Qr.TAB:this.onTabKeyDown();break;default:i||this.buildSearchStringFromKeyboardEvent(e)}}destroy(){this.listComponent&&(this.destroyBean(this.listComponent),this.listComponent=void 0),this.eLoading=void 0,super.destroy()}};g([he("userComponentFactory")],Xl.prototype,"userComponentFactory",2),g([he("animationFrameService")],Xl.prototype,"animationFrameService",2),g([bn("eInput")],Xl.prototype,"eInput",2);var Zl=class e extends On{constructor(t){super(t,e.TEMPLATE),this.labelAlignment="top"}init(){this.eSlider.addCssClass("ag-slider-field");const{minValue:e,maxValue:t,textFieldWidth:i,step:r,value:n,onValueChange:s}=this.config;null!=e&&this.setMinValue(e),null!=t&&this.setMaxValue(t),null!=i&&this.setTextFieldWidth(i),null!=r&&this.setStep(r),null!=n&&this.setValue(n),null!=s&&this.onValueChange(s)}onValueChange(e){const t=ct.EVENT_FIELD_VALUE_CHANGED;return this.addManagedListener(this.eText,t,()=>{const t=parseFloat(this.eText.getValue());this.eSlider.setValue(t.toString(),!0),e(t||0)}),this.addManagedListener(this.eSlider,t,()=>{const t=this.eSlider.getValue();this.eText.setValue(t,!0),e(parseFloat(t))}),this}setSliderWidth(e){return this.eSlider.setWidth(e),this}setTextFieldWidth(e){return this.eText.setWidth(e),this}setMinValue(e){return this.eSlider.setMinValue(e),this.eText.setMin(e),this}setMaxValue(e){return this.eSlider.setMaxValue(e),this.eText.setMax(e),this}getValue(){return this.eText.getValue()}setValue(e,t){return this.getValue()===e||(this.eText.setValue(e,!0),this.eSlider.setValue(e,!0),t||this.dispatchEvent({type:ct.EVENT_FIELD_VALUE_CHANGED})),this}setStep(e){return this.eSlider.setStep(e),this.eText.setStep(e),this}};Zl.TEMPLATE='<div class="ag-slider">\n            <label ref="eLabel"></label>\n            <div class="ag-wrapper ag-slider-wrapper">\n                <ag-input-range ref="eSlider"></ag-input-range>\n                <ag-input-number-field ref="eText"></ag-input-number-field>\n            </div>\n        </div>',g([bn("eLabel")],Zl.prototype,"eLabel",2),g([bn("eSlider")],Zl.prototype,"eSlider",2),g([bn("eText")],Zl.prototype,"eText",2),g([le],Zl.prototype,"init",1);var Jl=Zl,ec=class e extends wn{constructor(t={}){super(e.getTemplate(t)),this.params=t,this.suppressEnabledCheckbox=!0,this.suppressToggleExpandOnEnableChange=!1;const{enabled:i,items:r,suppressEnabledCheckbox:n,expanded:s,suppressToggleExpandOnEnableChange:o,useToggle:a}=t;this.cssIdentifier=t.cssIdentifier||"default",this.enabled=null==i||i,this.items=r||[],this.useToggle=null!=a&&a,this.alignItems=t.alignItems||"center",this.expanded=null==s||s,null!=n&&(this.suppressEnabledCheckbox=n),null!=o&&(this.suppressToggleExpandOnEnableChange=o)}static getTemplate(e){const t=e.cssIdentifier||"default";return`\n            <div class="ag-group ag-${t}-group" role="presentation">\n                <div ref="eToolbar" class="ag-group-toolbar ag-${t}-group-toolbar">\n                    <ag-checkbox ref="cbGroupEnabled"></ag-checkbox>\n                </div>\n                <div ref="eContainer" class="ag-group-container ag-group-container-${e.direction||"vertical"} ag-${t}-group-container"></div>\n            </div>\n        `}postConstruct(){if(this.setupTitleBar(),this.items.length){const e=this.items;this.items=[],this.addItems(e)}const e=this.localeService.getLocaleTextFunc();this.cbGroupEnabled.setLabel(e("enabled","Enabled")),this.enabled&&this.setEnabled(this.enabled,void 0,!0),this.setAlignItems(this.alignItems);const{onEnableChange:t,suppressOpenCloseIcons:i}=this.params;this.hideEnabledCheckbox(this.suppressEnabledCheckbox),this.hideOpenCloseIcons(null!=i&&i),this.refreshChildDisplay(),or(this.eContainer,this.expanded),this.cbGroupEnabled.onValueChange(e=>{this.setEnabled(e,!0,this.suppressToggleExpandOnEnableChange),this.dispatchEnableChangeEvent(e)}),null!=t&&this.onEnableChange(t)}refreshChildDisplay(){var e;or(this.eToolbar,this.expanded&&!this.suppressEnabledCheckbox),null==(e=this.eTitleBar)||e.refreshOnExpand(this.expanded)}isExpanded(){return this.expanded}setAlignItems(e){this.alignItems!==e&&this.removeCssClass(`ag-group-item-alignment-${this.alignItems}`),this.alignItems=e;const t=`ag-group-item-alignment-${this.alignItems}`;return this.addCssClass(t),this}toggleGroupExpand(t){var i;let r=!1;if((null==(i=this.eTitleBar)?void 0:i.isSuppressCollapse())&&!this.useToggle)t=!0,r=!0;else if(t=null!=t?t:!this.expanded,this.expanded===t)return this;return this.expanded=t,this.refreshChildDisplay(),or(this.eContainer,t),r||this.dispatchEvent({type:t?e.EVENT_EXPANDED:e.EVENT_COLLAPSED}),this}addItems(e){e.forEach(e=>this.addItem(e))}prependItem(e){this.insertItem(e,!0)}addItem(e){this.insertItem(e,!1)}insertItem(e,t){const i=this.eContainer,r=e instanceof wn?e.getGui():e;r.classList.add("ag-group-item",`ag-${this.cssIdentifier}-group-item`),t?(i.insertAdjacentElement("afterbegin",r),this.items.unshift(r)):(i.appendChild(r),this.items.push(r))}hideItem(e,t){or(this.items[t],!e)}getItemIndex(e){const t=e instanceof wn?e.getGui():e;return this.items.indexOf(t)}setTitle(e){var t;return null==(t=this.eTitleBar)||t.setTitle(e),this}addTitleBarWidget(e){var t;return null==(t=this.eTitleBar)||t.addWidget(e),this}addCssClassToTitleBar(e){var t;null==(t=this.eTitleBar)||t.addCssClass(e)}dispatchEnableChangeEvent(t){const i={type:e.EVENT_ENABLE_CHANGE,enabled:t};this.dispatchEvent(i)}setEnabled(e,t,i){var r;return this.enabled=e,this.refreshDisabledStyles(),i||this.toggleGroupExpand(e),t||(this.cbGroupEnabled.setValue(e),null==(r=this.eToggle)||r.setValue(e)),this}isEnabled(){return this.enabled}onEnableChange(t){return this.addManagedListener(this,e.EVENT_ENABLE_CHANGE,e=>t(e.enabled)),this}hideEnabledCheckbox(e){return this.suppressEnabledCheckbox=e,this.refreshChildDisplay(),this.refreshDisabledStyles(),this}hideOpenCloseIcons(e){var t;return null==(t=this.eTitleBar)||t.hideOpenCloseIcons(e),this}refreshDisabledStyles(){var e;const t=!this.enabled;this.eContainer.classList.toggle("ag-disabled",t),null==(e=this.eTitleBar)||e.refreshDisabledStyles(this.suppressEnabledCheckbox&&t),this.eContainer.classList.toggle("ag-disabled-group-container",t)}setupTitleBar(){const e=this.useToggle?this.createToggleTitleBar():this.createDefaultTitleBar();this.eToolbar.insertAdjacentElement("beforebegin",e.getGui())}createDefaultTitleBar(){const e=this.createManagedBean(new nc(this.params));return this.eTitleBar=e,e.refreshOnExpand(this.expanded),this.addManagedListener(e,nc.EVENT_EXPAND_CHANGED,e=>this.toggleGroupExpand(e.expanded)),e}createToggleTitleBar(){var e;const t=this.createManagedBean(new Wl({value:this.enabled,label:this.params.title,labelAlignment:"left",labelWidth:"flex",onValueChange:e=>{this.setEnabled(e,!0),this.dispatchEnableChangeEvent(e)}}));return t.addCssClass("ag-group-title-bar"),t.addCssClass(`ag-${null!=(e=this.params.cssIdentifier)?e:"default"}-group-title-bar ag-unselectable`),this.eToggle=t,this.toggleGroupExpand(this.enabled),t}};ec.EVENT_EXPANDED="expanded",ec.EVENT_COLLAPSED="collapsed",ec.EVENT_ENABLE_CHANGE="enableChange",g([bn("eToolbar")],ec.prototype,"eToolbar",2),g([bn("cbGroupEnabled")],ec.prototype,"cbGroupEnabled",2),g([bn("eContainer")],ec.prototype,"eContainer",2),g([le],ec.prototype,"postConstruct",1);var tc=ec,ic="ag-disabled-group-title-bar",rc=class e extends wn{constructor(t={}){super(e.getTemplate(t)),this.suppressOpenCloseIcons=!1;const{title:i,suppressOpenCloseIcons:r}=t;i&&i.length>0&&(this.title=i),null!=r&&(this.suppressOpenCloseIcons=r)}static getTemplate(e){var t;const i=null!=(t=e.cssIdentifier)?t:"default";return`\n            <div class="ag-group-title-bar ag-${i}-group-title-bar ag-unselectable" role="button">\n                <span class="ag-group-title-bar-icon ag-${i}-group-title-bar-icon" ref="eGroupOpenedIcon" role="presentation"></span>\n                <span class="ag-group-title-bar-icon ag-${i}-group-title-bar-icon" ref="eGroupClosedIcon" role="presentation"></span>\n                <span ref="eTitle" class="ag-group-title ag-${i}-group-title"></span>\n            </div>\n        `}postConstruct(){this.setTitle(this.title),this.hideOpenCloseIcons(this.suppressOpenCloseIcons),this.setupExpandContract()}setupExpandContract(){this.eGroupClosedIcon.appendChild($r("columnSelectClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild($r("columnSelectOpen",this.gos,null)),this.addManagedListener(this.getGui(),"click",()=>this.dispatchExpandChanged()),this.addManagedListener(this.getGui(),"keydown",e=>{switch(e.key){case Qr.ENTER:case Qr.SPACE:e.preventDefault(),this.dispatchExpandChanged();break;case Qr.RIGHT:case Qr.LEFT:e.preventDefault(),this.dispatchExpandChanged(e.key===Qr.RIGHT)}})}refreshOnExpand(e){this.refreshAriaStatus(e),this.refreshOpenCloseIcons(e)}refreshAriaStatus(e){this.suppressOpenCloseIcons||ii(this.getGui(),e)}refreshOpenCloseIcons(e){const t=!this.suppressOpenCloseIcons;or(this.eGroupOpenedIcon,t&&e),or(this.eGroupClosedIcon,t&&!e)}isSuppressCollapse(){return this.suppressOpenCloseIcons}dispatchExpandChanged(t){const i={type:e.EVENT_EXPAND_CHANGED,expanded:t};this.dispatchEvent(i)}setTitle(e){const t=this.getGui(),i=!!e&&e.length>0;e=i?e:void 0,this.eTitle.textContent=null!=e?e:"",or(t,i),e!==this.title&&(this.title=e);const r=t.classList.contains(ic);return this.refreshDisabledStyles(r),this}addWidget(e){return this.getGui().appendChild(e),this}hideOpenCloseIcons(e){return this.suppressOpenCloseIcons=e,e&&this.dispatchExpandChanged(!0),this}refreshDisabledStyles(e){const t=this.getGui();e?(t.classList.add(ic),t.removeAttribute("tabindex")):(t.classList.remove(ic),"string"==typeof this.title?t.setAttribute("tabindex","0"):t.removeAttribute("tabindex"))}};rc.EVENT_EXPAND_CHANGED="expandedChanged",g([bn("eGroupOpenedIcon")],rc.prototype,"eGroupOpenedIcon",2),g([bn("eGroupClosedIcon")],rc.prototype,"eGroupClosedIcon",2),g([bn("eTitle")],rc.prototype,"eTitle",2),g([le],rc.prototype,"postConstruct",1);var nc=rc,sc=class extends Al{constructor(e=0,t){super('<div class="ag-menu-list" role="tree"></div>'),this.level=e,this.menuItems=[],this.params=null!=t?t:{column:null,node:null,value:null}}postConstruct(){this.initialiseTabGuard({onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.handleFocusIn(e),onFocusOut:e=>this.handleFocusOut(e)})}onTabKeyDown(e){const t=this.getParentComponent(),i=t&&t.getGui();i&&i.classList.contains("ag-focus-managed")||e.preventDefault(),e.shiftKey&&this.closeIfIsChild(e)}handleKeyDown(e){switch(e.key){case Qr.UP:case Qr.RIGHT:case Qr.DOWN:case Qr.LEFT:e.preventDefault(),this.handleNavKey(e.key);break;case Qr.ESCAPE:this.closeIfIsChild()&&Ye(e)}}handleFocusIn(e){var t,i;const r=e.relatedTarget;(this.tabGuardCtrl.isTabGuard(r)||!this.getGui().contains(r)&&!(null==(i=null==(t=this.activeMenuItem)?void 0:t.getSubMenuGui())?void 0:i.contains(r)))&&(this.activeMenuItem?this.activeMenuItem.activate():this.activateFirstItem())}handleFocusOut(e){var t;const i=e.relatedTarget;!this.activeMenuItem||this.getGui().contains(i)||(null==(t=this.activeMenuItem.getSubMenuGui())?void 0:t.contains(i))||this.activeMenuItem.isSubMenuOpening()||this.activeMenuItem.deactivate()}clearActiveItem(){this.activeMenuItem&&(this.activeMenuItem.deactivate(),this.activeMenuItem=null)}addMenuItems(e){null!=e&&dn.all(e.map(e=>"separator"===e?dn.resolve({eGui:this.createSeparator()}):"string"==typeof e?(console.warn(`AG Grid: unrecognised menu item ${e}`),dn.resolve({eGui:null})):this.addItem(e))).then(e=>{e.forEach(e=>{(null==e?void 0:e.eGui)&&(this.appendChild(e.eGui),e.comp&&this.menuItems.push(e.comp))})})}addItem(e){const t=this.createManagedBean(new lc);return t.init({menuItemDef:e,isAnotherSubMenuOpen:()=>this.menuItems.some(e=>e.isSubMenuOpen()),level:this.level,contextParams:this.params}).then(()=>(t.setParentComponent(this),this.addManagedListener(t,lc.EVENT_CLOSE_MENU,e=>{this.dispatchEvent(e)}),this.addManagedListener(t,lc.EVENT_MENU_ITEM_ACTIVATED,e=>{this.activeMenuItem&&this.activeMenuItem!==e.menuItem&&this.activeMenuItem.deactivate(),this.activeMenuItem=e.menuItem}),{comp:t,eGui:t.getGui()}))}activateFirstItem(){const e=this.menuItems.filter(e=>!e.isDisabled())[0];e&&e.activate()}createSeparator(){return Er('\n            <div class="ag-menu-separator" aria-hidden="true">\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n            </div>')}handleNavKey(e){switch(e){case Qr.UP:case Qr.DOWN:const t=this.findNextItem(e===Qr.UP);return void(t&&t!==this.activeMenuItem&&t.activate())}e===(this.gos.get("enableRtl")?Qr.RIGHT:Qr.LEFT)?this.closeIfIsChild():this.openChild()}closeIfIsChild(e){const t=this.getParentComponent();return!!(t&&t instanceof lc)&&(e&&e.preventDefault(),t.closeSubMenu(),t.getGui().focus(),!0)}openChild(){this.activeMenuItem&&this.activeMenuItem.openSubMenu(!0)}findNextItem(e){const t=this.menuItems.filter(e=>!e.isDisabled());if(!t.length)return;if(!this.activeMenuItem)return e?Pe(t):t[0];let i;e&&t.reverse();let r=!1;for(let e=0;e<t.length;e++){const n=t[e];if(r){i=n;break}n===this.activeMenuItem&&(r=!0)}return r&&!i?t[0]:i||this.activeMenuItem}destroy(){this.clearActiveItem(),super.destroy()}};g([he("focusService")],sc.prototype,"focusService",2),g([le],sc.prototype,"postConstruct",1);var oc=class extends Al{constructor(e){super(),this.wrappedComponent=e,this.setTemplateFromElement(e.getGui())}postConstruct(){this.initialiseTabGuard({onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e)})}handleKeyDown(e){e.key===Qr.ESCAPE&&this.closePanel()}onTabKeyDown(e){e.defaultPrevented||(this.closePanel(),e.preventDefault())}closePanel(){const e=this.parentComponent;e.closeSubMenu(),setTimeout(()=>e.getGui().focus(),0)}};g([le],oc.prototype,"postConstruct",1);var ac=class e extends nt{constructor(){super(...arguments),this.isActive=!1,this.subMenuIsOpen=!1,this.subMenuIsOpening=!1,this.suppressRootStyles=!0,this.suppressAria=!0,this.suppressFocus=!0}init(e){var t,i;const{menuItemDef:r,isAnotherSubMenuOpen:n,level:s,childComponent:o,contextParams:a}=e;return this.params=e.menuItemDef,this.level=s,this.isAnotherSubMenuOpen=n,this.childComponent=o,this.contextParams=a,this.cssClassPrefix=null!=(i=null==(t=this.params.menuItemParams)?void 0:t.cssClassPrefix)?i:"ag-menu-option",this.userComponentFactory.getMenuItemCompDetails(this.params,d(h({},r),{level:s,isAnotherSubMenuOpen:n,openSubMenu:e=>this.openSubMenu(e),closeSubMenu:()=>this.closeSubMenu(),closeMenu:e=>this.closeMenu(e),updateTooltip:(e,t)=>this.refreshTooltip(e,t),onItemActivated:()=>this.onItemActivated()})).newAgStackInstance().then(e=>{var t;this.menuItemComp=e;const i=null==(t=e.configureDefaults)?void 0:t.call(e);i&&this.configureDefaults(!0===i?void 0:i)})}addListeners(e,t){(null==t?void 0:t.suppressClick)||this.addManagedListener(e,"click",e=>this.onItemSelected(e)),(null==t?void 0:t.suppressKeyboardSelect)||this.addManagedListener(e,"keydown",e=>{e.key!==Qr.ENTER&&e.key!==Qr.SPACE||(e.preventDefault(),this.onItemSelected(e))}),(null==t?void 0:t.suppressMouseDown)||this.addManagedListener(e,"mousedown",e=>{e.stopPropagation(),e.preventDefault()}),(null==t?void 0:t.suppressMouseOver)||(this.addManagedListener(e,"mouseenter",()=>this.onMouseEnter()),this.addManagedListener(e,"mouseleave",()=>this.onMouseLeave()))}isDisabled(){return!!this.params.disabled}openSubMenu(t=!1){var i,r;if(this.closeSubMenu(),!this.params.subMenu)return;this.subMenuIsOpening=!0;const n=Er('<div class="ag-menu" role="presentation"></div>');let s;this.eSubMenuGui=n;let o=()=>{this.subMenuIsOpening=!1};if(this.childComponent){const e=this.createBean(new oc(this.childComponent));e.setParentComponent(this);const t=e.getGui(),i="mouseenter",r=()=>this.cancelDeactivate();t.addEventListener(i,r),s=()=>t.removeEventListener(i,r),n.appendChild(t),this.childComponent.afterGuiAttached&&(o=()=>{this.childComponent.afterGuiAttached(),this.subMenuIsOpening=!1})}else if(this.params.subMenu){const i=this.createBean(new sc(this.level+1,this.contextParams));i.setParentComponent(this),i.addMenuItems(this.params.subMenu),n.appendChild(i.getGui()),this.addManagedListener(i,e.EVENT_CLOSE_MENU,e=>this.dispatchEvent(e)),i.addGuiEventListener("mouseenter",()=>this.cancelDeactivate()),s=()=>this.destroyBean(i),t&&(o=()=>{i.activateFirstItem(),this.subMenuIsOpening=!1})}const a=this.popupService.positionPopupForMenu.bind(this.popupService,{eventSource:this.eGui,ePopup:n}),l=this.localeService.getLocaleTextFunc(),c=this.popupService.addPopup({modal:!0,eChild:n,positionCallback:a,anchorToElement:this.eGui,ariaLabel:l("ariaLabelSubMenu","SubMenu"),afterGuiAttached:o});this.subMenuIsOpen=!0,this.setAriaExpanded(!0),this.hideSubMenu=()=>{var e,t;c&&c.hideFunc(),this.subMenuIsOpen=!1,this.setAriaExpanded(!1),s(),null==(t=(e=this.menuItemComp).setExpanded)||t.call(e,!1),this.eSubMenuGui=void 0},null==(r=(i=this.menuItemComp).setExpanded)||r.call(i,!0)}setAriaExpanded(e){this.suppressAria||ii(this.eGui,e)}closeSubMenu(){this.hideSubMenu&&(this.hideSubMenu(),this.hideSubMenu=null,this.setAriaExpanded(!1))}isSubMenuOpen(){return this.subMenuIsOpen}isSubMenuOpening(){return this.subMenuIsOpening}activate(e){var t,i;this.cancelActivate(),this.params.disabled||(this.isActive=!0,this.suppressRootStyles||this.eGui.classList.add(`${this.cssClassPrefix}-active`),null==(i=(t=this.menuItemComp).setActive)||i.call(t,!0),this.suppressFocus||this.eGui.focus({preventScroll:!0}),e&&this.params.subMenu&&window.setTimeout(()=>{this.isAlive()&&this.isActive&&this.openSubMenu()},300),this.onItemActivated())}deactivate(){var e,t;this.cancelDeactivate(),this.suppressRootStyles||this.eGui.classList.remove(`${this.cssClassPrefix}-active`),null==(t=(e=this.menuItemComp).setActive)||t.call(e,!1),this.isActive=!1,this.subMenuIsOpen&&this.hideSubMenu()}getGui(){return this.menuItemComp.getGui()}getParentComponent(){return this.parentComponent}setParentComponent(e){this.parentComponent=e}getSubMenuGui(){return this.eSubMenuGui}onItemSelected(e){var t,i;null==(i=(t=this.menuItemComp).select)||i.call(t),this.params.action?this.getFrameworkOverrides().wrapOutgoing(()=>this.params.action(this.gos.addGridCommonParams(h({},this.contextParams)))):this.openSubMenu(e&&"keydown"===e.type),this.params.subMenu&&!this.params.action||this.params.suppressCloseOnSelect||this.closeMenu(e)}closeMenu(t){const i={type:e.EVENT_CLOSE_MENU};t&&(t instanceof MouseEvent?i.mouseEvent=t:i.keyboardEvent=t),this.dispatchEvent(i)}onItemActivated(){const t={type:e.EVENT_MENU_ITEM_ACTIVATED,menuItem:this};this.dispatchEvent(t)}cancelActivate(){this.activateTimeoutId&&(window.clearTimeout(this.activateTimeoutId),this.activateTimeoutId=0)}cancelDeactivate(){this.deactivateTimeoutId&&(window.clearTimeout(this.deactivateTimeoutId),this.deactivateTimeoutId=0)}onMouseEnter(){this.cancelDeactivate(),this.isAnotherSubMenuOpen()?this.activateTimeoutId=window.setTimeout(()=>this.activate(!0),e.ACTIVATION_DELAY):this.activate(!0)}onMouseLeave(){this.cancelActivate(),this.isSubMenuOpen()?this.deactivateTimeoutId=window.setTimeout(()=>this.deactivate(),e.ACTIVATION_DELAY):this.deactivate()}configureDefaults(e){var t,i,r;if(!this.menuItemComp)return void setTimeout(()=>this.configureDefaults(e));let n=this.menuItemComp.getGui();const s=null==(i=(t=this.menuItemComp).getRootElement)?void 0:i.call(t);s&&((null==e?void 0:e.suppressRootStyles)||n.classList.add("ag-menu-option-custom"),n=s),this.eGui=n,this.suppressRootStyles=!!(null==e?void 0:e.suppressRootStyles),this.suppressRootStyles||(n.classList.add(this.cssClassPrefix),null==(r=this.params.cssClasses)||r.forEach(e=>n.classList.add(e)),this.params.disabled&&n.classList.add(`${this.cssClassPrefix}-disabled`)),(null==e?void 0:e.suppressTooltip)||this.refreshTooltip(this.params.tooltip),this.suppressAria=!!(null==e?void 0:e.suppressAria),this.suppressAria||(Bt(n,"treeitem"),Zt(n,this.level+1),this.params.disabled&&Jt(n,!0)),(null==e?void 0:e.suppressTabIndex)||n.setAttribute("tabindex","-1"),this.params.disabled||this.addListeners(n,e),this.suppressFocus=!!(null==e?void 0:e.suppressFocus)}refreshTooltip(e,t){this.tooltip=e,this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),e&&this.menuItemComp&&(this.tooltipFeature=this.createBean(new vn({getGui:()=>this.getGui(),getTooltipValue:()=>this.tooltip,getLocation:()=>"menu",shouldDisplayTooltip:t})))}destroy(){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),super.destroy()}};ac.EVENT_CLOSE_MENU="closeMenu",ac.EVENT_MENU_ITEM_ACTIVATED="menuItemActivated",ac.ACTIVATION_DELAY=80,g([he("popupService")],ac.prototype,"popupService",2),g([he("userComponentFactory")],ac.prototype,"userComponentFactory",2);var lc=ac,cc=class e extends wn{constructor(t){super(e.getTemplate(t)),this.config=t,this.closable=!0}static getTemplate(e){const t=e.cssIdentifier||"default";return`<div class="ag-panel ag-${t}-panel" tabindex="-1">\n            <div ref="eTitleBar" class="ag-panel-title-bar ag-${t}-panel-title-bar ag-unselectable">\n                <span ref="eTitle" class="ag-panel-title-bar-title ag-${t}-panel-title-bar-title"></span>\n                <div ref="eTitleBarButtons" class="ag-panel-title-bar-buttons ag-${t}-panel-title-bar-buttons"></div>\n            </div>\n            <div ref="eContentWrapper" class="ag-panel-content-wrapper ag-${t}-panel-content-wrapper"></div>\n        </div>`}postConstruct(){const{component:e,closable:t,hideTitleBar:i,title:r,minWidth:n=250,width:s,minHeight:o=250,height:a,centered:l,popup:c,x:u,y:h}=this.config;this.positionableFeature=new In(this.getGui(),{minWidth:n,width:s,minHeight:o,height:a,centered:l,x:u,y:h,popup:c,calculateTopBuffer:()=>this.positionableFeature.getHeight()-this.getBodyHeight()}),this.createManagedBean(this.positionableFeature);const d=this.getGui();e&&this.setBodyComponent(e),i?or(this.eTitleBar,!1):(r&&this.setTitle(r),this.setClosable(null!=t?t:this.closable)),this.addManagedListener(this.eTitleBar,"mousedown",e=>{if(d.contains(e.relatedTarget)||d.contains(this.gos.getActiveDomElement())||this.eTitleBarButtons.contains(e.target))return void e.preventDefault();const t=this.eContentWrapper.querySelector("button, [href], input, select, textarea, [tabindex]");t&&t.focus()}),c&&this.positionableFeature.isPositioned()||(this.renderComponent&&this.renderComponent(),this.positionableFeature.initialisePosition(),this.eContentWrapper.style.height="0")}renderComponent(){const e=this.getGui();e.focus(),this.close=()=>{e.parentElement.removeChild(e),this.destroy()}}getHeight(){return this.positionableFeature.getHeight()}setHeight(e){this.positionableFeature.setHeight(e)}getWidth(){return this.positionableFeature.getWidth()}setWidth(e){this.positionableFeature.setWidth(e)}setClosable(t){if(t!==this.closable&&(this.closable=t),t){const t=this.closeButtonComp=new wn(e.CLOSE_BTN_TEMPLATE);this.getContext().createBean(t);const i=t.getGui(),r=qr("close",this.gos);r.classList.add("ag-panel-title-bar-button-icon"),i.appendChild(r),this.addTitleBarButton(t),t.addManagedListener(i,"click",this.onBtClose.bind(this))}else if(this.closeButtonComp){const e=this.closeButtonComp.getGui();e.parentElement.removeChild(e),this.closeButtonComp=this.destroyBean(this.closeButtonComp)}}setBodyComponent(e){e.setParentComponent(this),this.eContentWrapper.appendChild(e.getGui())}addTitleBarButton(e,t){const i=this.eTitleBarButtons,r=i.children,n=r.length;null==t&&(t=n),t=Math.max(0,Math.min(t,n)),e.addCssClass("ag-panel-title-bar-button");const s=e.getGui();0===t?i.insertAdjacentElement("afterbegin",s):t===n?i.insertAdjacentElement("beforeend",s):r[t-1].insertAdjacentElement("afterend",s),e.setParentComponent(this)}getBodyHeight(){return hr(this.eContentWrapper)}getBodyWidth(){return dr(this.eContentWrapper)}setTitle(e){this.eTitle.innerText=e}onBtClose(){this.close()}destroy(){this.closeButtonComp&&(this.closeButtonComp=this.destroyBean(this.closeButtonComp));const e=this.getGui();e&&br(e)&&this.close(),super.destroy()}};cc.CLOSE_BTN_TEMPLATE='<div class="ag-button"></div>',g([bn("eContentWrapper")],cc.prototype,"eContentWrapper",2),g([bn("eTitleBar")],cc.prototype,"eTitleBar",2),g([bn("eTitleBarButtons")],cc.prototype,"eTitleBarButtons",2),g([bn("eTitle")],cc.prototype,"eTitle",2),g([le],cc.prototype,"postConstruct",1);var uc=cc,hc=class extends uc{constructor(e){super(d(h({},e),{popup:!0})),this.isMaximizable=!1,this.isMaximized=!1,this.maximizeListeners=[],this.resizeListenerDestroy=null,this.lastPosition={x:0,y:0,width:0,height:0}}postConstruct(){const e=this.getGui(),{movable:t,resizable:i,maximizable:r}=this.config;this.addCssClass("ag-dialog"),super.postConstruct(),this.addManagedListener(e,"focusin",t=>{this.popupService.bringPopupToFront(e)}),t&&this.setMovable(t),r&&this.setMaximizable(r),i&&this.setResizable(i)}renderComponent(){const e=this.getGui(),{alwaysOnTop:t,modal:i,title:r,afterGuiAttached:n}=this.config,s=this.localeService.getLocaleTextFunc(),o=this.popupService.addPopup({modal:i,eChild:e,closeOnEsc:!0,closedCallback:this.onClosed.bind(this),alwaysOnTop:t,ariaLabel:r||s("ariaLabelDialog","Dialog"),afterGuiAttached:n});o&&(this.close=o.hideFunc)}onClosed(e){var t,i;this.destroy(),null==(i=(t=this.config).closedCallback)||i.call(t,e)}toggleMaximize(){const e=this.positionableFeature.getPosition();if(this.isMaximized){const{x:e,y:t,width:i,height:r}=this.lastPosition;this.setWidth(i),this.setHeight(r),this.positionableFeature.offsetElement(e,t)}else this.lastPosition.width=this.getWidth(),this.lastPosition.height=this.getHeight(),this.lastPosition.x=e.x,this.lastPosition.y=e.y,this.positionableFeature.offsetElement(0,0),this.setHeight("100%"),this.setWidth("100%");this.isMaximized=!this.isMaximized,this.refreshMaximizeIcon()}refreshMaximizeIcon(){or(this.maximizeIcon,!this.isMaximized),or(this.minimizeIcon,this.isMaximized)}clearMaximizebleListeners(){this.maximizeListeners.length&&(this.maximizeListeners.forEach(e=>e()),this.maximizeListeners.length=0),this.resizeListenerDestroy&&(this.resizeListenerDestroy(),this.resizeListenerDestroy=null)}destroy(){this.maximizeButtonComp=this.destroyBean(this.maximizeButtonComp),this.clearMaximizebleListeners(),super.destroy()}setResizable(e){this.positionableFeature.setResizable(e)}setMovable(e){this.positionableFeature.setMovable(e,this.eTitleBar)}setMaximizable(e){if(!e)return this.clearMaximizebleListeners(),void(this.maximizeButtonComp&&(this.destroyBean(this.maximizeButtonComp),this.maximizeButtonComp=this.maximizeIcon=this.minimizeIcon=void 0));const t=this.eTitleBar;if(!t||e===this.isMaximizable)return;const i=this.buildMaximizeAndMinimizeElements();this.refreshMaximizeIcon(),i.addManagedListener(i.getGui(),"click",this.toggleMaximize.bind(this)),this.addTitleBarButton(i,0),this.maximizeListeners.push(this.addManagedListener(t,"dblclick",this.toggleMaximize.bind(this))),this.resizeListenerDestroy=this.addManagedListener(this,"resize",()=>{this.isMaximized=!1,this.refreshMaximizeIcon()})}buildMaximizeAndMinimizeElements(){const e=this.maximizeButtonComp=this.createBean(new wn('<div class="ag-dialog-button"></span>')),t=e.getGui();return this.maximizeIcon=qr("maximize",this.gos),t.appendChild(this.maximizeIcon),this.maximizeIcon.classList.add("ag-panel-title-bar-button-icon"),this.minimizeIcon=qr("minimize",this.gos),t.appendChild(this.minimizeIcon),this.minimizeIcon.classList.add("ag-panel-title-bar-button-icon"),e}};g([he("popupService")],hc.prototype,"popupService",2);var dc=0,pc=class extends nt{constructor(){super(...arguments),this.popupList=[]}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl}),this.addManagedListener(this.eventService,ct.EVENT_GRID_STYLES_CHANGED,this.handleThemeChange.bind(this))}getPopupParent(){return this.gos.get("popupParent")||this.gridCtrl.getGui()}positionPopupForMenu(e){const{eventSource:t,ePopup:i}=e,r=this.getPopupIndex(i);-1!==r&&(this.popupList[r].alignedToElement=t);const n=t.getBoundingClientRect(),s=this.getParentRect(),o=this.keepXYWithinBounds(i,n.top-s.top,0),a=i.clientWidth>0?i.clientWidth:200;i.style.minWidth=`${a}px`;const l=s.right-s.left-a;let c;function u(){return n.right-s.left-2}function h(){return n.left-s.left-a}this.gos.get("enableRtl")?(c=h(),c<0&&(c=u(),this.setAlignedStyles(i,"left")),c>l&&(c=0,this.setAlignedStyles(i,"right"))):(c=u(),c>l&&(c=h(),this.setAlignedStyles(i,"right")),c<0&&(c=0,this.setAlignedStyles(i,"left"))),i.style.left=`${c}px`,i.style.top=`${o}px`}positionPopupUnderMouseEvent(e){const{ePopup:t,nudgeX:i,nudgeY:r,skipObserver:n}=e;this.positionPopup({ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:!0,skipObserver:n,updatePosition:()=>this.calculatePointerAlign(e.mouseEvent),postProcessCallback:()=>this.callPostProcessPopup(e.type,e.ePopup,null,e.mouseEvent,e.column,e.rowNode)})}calculatePointerAlign(e){const t=this.getParentRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}positionPopupByComponent(e){const{ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:n,eventSource:s,alignSide:o="left",position:a="over",column:l,rowNode:c,type:u}=e,h=s.getBoundingClientRect(),d=this.getParentRect(),p=this.getPopupIndex(t);-1!==p&&(this.popupList[p].alignedToElement=s),this.positionPopup({ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:n,updatePosition:()=>{let i,n=h.left-d.left;return"right"===o&&(n-=t.offsetWidth-h.width),"over"===a?(i=h.top-d.top,this.setAlignedStyles(t,"over")):(this.setAlignedStyles(t,"under"),i="under"===this.shouldRenderUnderOrAbove(t,h,d,e.nudgeY||0)?h.top-d.top+h.height:h.top-t.offsetHeight-2*(r||0)-d.top),{x:n,y:i}},postProcessCallback:()=>this.callPostProcessPopup(u,t,s,null,l,c)})}shouldRenderUnderOrAbove(e,t,i,r){const n=i.bottom-t.bottom,s=t.top-i.top,o=e.offsetHeight+r;return n>o?"under":s>o||s>n?"above":"under"}setAlignedStyles(e,t){const i=this.getPopupIndex(e);if(-1===i)return;const r=this.popupList[i],{alignedToElement:n}=r;n&&(["right","left","over","above","under"].forEach(t=>{n.classList.remove(`ag-has-popup-positioned-${t}`),e.classList.remove(`ag-popup-positioned-${t}`)}),t&&(n.classList.add(`ag-has-popup-positioned-${t}`),e.classList.add(`ag-popup-positioned-${t}`)))}callPostProcessPopup(e,t,i,r,n,s){const o=this.gos.getCallback("postProcessPopup");o&&o({column:n,rowNode:s,ePopup:t,type:e,eventSource:i,mouseEvent:r})}positionPopup(e){const{ePopup:t,keepWithinBounds:i,nudgeX:r,nudgeY:n,skipObserver:s,updatePosition:o}=e,a={width:0,height:0},l=(s=!1)=>{let{x:l,y:c}=o();s&&t.clientWidth===a.width&&t.clientHeight===a.height||(a.width=t.clientWidth,a.height=t.clientHeight,r&&(l+=r),n&&(c+=n),i&&(l=this.keepXYWithinBounds(t,l,1),c=this.keepXYWithinBounds(t,c,0)),t.style.left=`${l}px`,t.style.top=`${c}px`,e.postProcessCallback&&e.postProcessCallback())};if(l(),!s){const e=this.resizeObserverService.observeResize(t,()=>l(!0));setTimeout(()=>e(),pc.WAIT_FOR_POPUP_CONTENT_RESIZE)}}getActivePopups(){return this.popupList.map(e=>e.element)}getPopupList(){return this.popupList}getParentRect(){const e=this.gos.getDocument();let t=this.getPopupParent();return t===e.body?t=e.documentElement:"static"===getComputedStyle(t).position&&(t=t.offsetParent),fr(t)}keepXYWithinBounds(e,t,i){const r=0===i,n=r?"clientHeight":"clientWidth",s=r?"top":"left",o=r?"offsetHeight":"offsetWidth",a=r?"scrollTop":"scrollLeft",l=this.gos.getDocument(),c=l.documentElement,u=this.getPopupParent(),h=u.getBoundingClientRect(),d=l.documentElement.getBoundingClientRect(),p=u===l.body,g=e[o];let f=p?(r?pr:gr)(c)+c[a]:u[n];p&&(f-=Math.abs(d[s]-h[s]));const m=f-g;return Math.min(Math.max(t,0),Math.abs(m))}addPopup(e){const t=this.gos.getDocument(),{eChild:i,ariaLabel:r,alwaysOnTop:n,positionCallback:s,anchorToElement:o}=e;if(!t)return console.warn("AG Grid: could not find the document, document is empty"),{hideFunc:()=>{}};const a=this.getPopupIndex(i);if(-1!==a)return{hideFunc:this.popupList[a].hideFunc};this.initialisePopupPosition(i);const l=this.createPopupWrapper(i,r,!!n),c=this.addEventListenersToPopup(d(h({},e),{wrapperEl:l}));return s&&s(),this.addPopupToPopupList(i,l,c,o),{hideFunc:c}}initialisePopupPosition(e){const t=this.getPopupParent().getBoundingClientRect();y(e.style.top)||(e.style.top=-1*t.top+"px"),y(e.style.left)||(e.style.left=-1*t.left+"px")}createPopupWrapper(e,t,i){const r=this.getPopupParent(),n=document.createElement("div"),{allThemes:s}=this.environment.getTheme();return s.length&&n.classList.add(...s),n.classList.add("ag-popup"),e.classList.add(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr","ag-popup-child"),e.hasAttribute("role")||Bt(e,"dialog"),Kt(e,t),n.appendChild(e),r.appendChild(n),i?this.setAlwaysOnTop(e,!0):this.bringPopupToFront(e),n}handleThemeChange(){const{allThemes:e}=this.environment.getTheme();for(const t of this.popupList){for(const e of Array.from(t.wrapper.classList))e.startsWith("ag-theme-")&&t.wrapper.classList.remove(e);e.length&&t.wrapper.classList.add(...e)}}addEventListenersToPopup(e){const t=this.gos.getDocument(),i=this.getPopupParent(),{wrapperEl:r,eChild:n,closedCallback:s,afterGuiAttached:o,closeOnEsc:a,modal:l}=e;let c=!1;const u=e=>{r.contains(this.gos.getActiveDomElement())&&(e.key!==Qr.ESCAPE||Qe(e)||p({keyboardEvent:e}))},h=e=>p({mouseEvent:e}),d=e=>p({touchEvent:e}),p=(e={})=>{const{mouseEvent:o,touchEvent:a,keyboardEvent:l,forceHide:p}=e;(p||!this.isEventFromCurrentPopup({mouseEvent:o,touchEvent:a},n)&&!c)&&(c=!0,i.removeChild(r),t.removeEventListener("keydown",u),t.removeEventListener("mousedown",h),t.removeEventListener("touchstart",d),t.removeEventListener("contextmenu",h),this.eventService.removeEventListener(ct.EVENT_DRAG_STARTED,h),s&&s(o||a||l),this.removePopupFromPopupList(n))};return o&&o({hidePopup:p}),window.setTimeout(()=>{a&&t.addEventListener("keydown",u),l&&(t.addEventListener("mousedown",h),this.eventService.addEventListener(ct.EVENT_DRAG_STARTED,h),t.addEventListener("touchstart",d),t.addEventListener("contextmenu",h))},0),p}addPopupToPopupList(e,t,i,r){this.popupList.push({element:e,wrapper:t,hideFunc:i,instanceId:dc++,isAnchored:!!r}),r&&this.setPopupPositionRelatedToElement(e,r)}getPopupIndex(e){return this.popupList.findIndex(t=>t.element===e)}setPopupPositionRelatedToElement(e,t){const i=this.getPopupIndex(e);if(-1===i)return;const r=this.popupList[i];if(r.stopAnchoringPromise&&r.stopAnchoringPromise.then(e=>e&&e()),r.stopAnchoringPromise=void 0,r.isAnchored=!1,!t)return;const n=this.keepPopupPositionedRelativeTo({element:t,ePopup:e,hidePopup:r.hideFunc});return r.stopAnchoringPromise=n,r.isAnchored=!0,n}removePopupFromPopupList(e){this.setAlignedStyles(e,null),this.setPopupPositionRelatedToElement(e,null),this.popupList=this.popupList.filter(t=>t.element!==e)}keepPopupPositionedRelativeTo(e){const t=this.getPopupParent(),i=t.getBoundingClientRect(),{element:r,ePopup:n}=e,s=r.getBoundingClientRect(),o=i.top-s.top,a=i.left-s.left;let l=o,c=a;const u=n.style.top,h=parseInt(u.substring(0,u.length-1),10),d=n.style.left,p=parseInt(d.substring(0,d.length-1),10);return new dn(i=>{this.getFrameworkOverrides().setInterval(()=>{const i=t.getBoundingClientRect(),s=r.getBoundingClientRect();if(0==s.top&&0==s.left&&0==s.height&&0==s.width)return void e.hidePopup();const u=i.top-s.top;if(u!=l){const e=this.keepXYWithinBounds(n,h+o-u,0);n.style.top=`${e}px`}l=u;const d=i.left-s.left;if(d!=c){const e=this.keepXYWithinBounds(n,p+a-d,1);n.style.left=`${e}px`}c=d},200).then(e=>{i(()=>{null!=e&&window.clearInterval(e)})})})}hasAnchoredPopup(){return this.popupList.some(e=>e.isAnchored)}isEventFromCurrentPopup(e,t){const{mouseEvent:i,touchEvent:r}=e,n=i||r;if(!n)return!1;const s=this.getPopupIndex(t);if(-1===s)return!1;for(let e=s;e<this.popupList.length;e++)if(Je(this.popupList[e].element,n))return!0;return this.isElementWithinCustomPopup(n.target)}isElementWithinCustomPopup(e){const t=this.gos.getDocument();for(;e&&e!==t.body;){if(e.classList.contains("ag-custom-component-popup")||null===e.parentElement)return!0;e=e.parentElement}return!1}getWrapper(e){for(;!e.classList.contains("ag-popup")&&e.parentElement;)e=e.parentElement;return e.classList.contains("ag-popup")?e:null}setAlwaysOnTop(e,t){const i=this.getWrapper(e);i&&(i.classList.toggle("ag-always-on-top",!!t),t&&this.bringPopupToFront(i))}bringPopupToFront(e){const t=this.getPopupParent(),i=Array.prototype.slice.call(t.querySelectorAll(".ag-popup")),r=i.length,n=Array.prototype.slice.call(t.querySelectorAll(".ag-popup.ag-always-on-top")),s=n.length,o=this.getWrapper(e);if(!o||r<=1||!t.contains(e))return;const a=i.indexOf(o),l=o.querySelectorAll("div"),c=[];for(l.forEach(e=>{0!==e.scrollTop&&c.push([e,e.scrollTop])}),s?o.classList.contains("ag-always-on-top")?a!==r-1&&Pe(n).insertAdjacentElement("afterend",o):a!==r-s-1&&n[0].insertAdjacentElement("beforebegin",o):a!==r-1&&Pe(i).insertAdjacentElement("afterend",o);c.length;){const e=c.pop();e[0].scrollTop=e[1]}}};pc.WAIT_FOR_POPUP_CONTENT_RESIZE=200,g([he("focusService")],pc.prototype,"focusService",2),g([he("ctrlsService")],pc.prototype,"ctrlsService",2),g([he("resizeObserverService")],pc.prototype,"resizeObserverService",2),g([le],pc.prototype,"postConstruct",1),pc=g([ue("popupService")],pc);var gc=class extends wn{constructor(){super('\n        <div class="ag-autocomplete-row" role="presentation">\n            <div class="ag-autocomplete-row-label"></div>\n        </div>'),this.hasHighlighting=!1}setState(e,t){this.value=e,this.render(),this.updateSelected(t)}updateSelected(e){this.addOrRemoveCssClass("ag-autocomplete-row-selected",e)}setSearchString(e){var t;let i=!1;if(y(e)){const r=null==(t=this.value)?void 0:t.toLocaleLowerCase().indexOf(e.toLocaleLowerCase());if(r>=0){i=!0,this.hasHighlighting=!0;const t=r+e.length,n=yt(this.value.slice(0,r)),s=yt(this.value.slice(r,t)),o=yt(this.value.slice(t));this.getGui().lastElementChild.innerHTML=`${n}<b>${s}</b>${o}`}}!i&&this.hasHighlighting&&(this.hasHighlighting=!1,this.render())}render(){var e;this.getGui().lastElementChild.innerHTML=null!=(e=yt(this.value))?e:"&nbsp;"}},fc=class e extends As{constructor(t){super(e.TEMPLATE),this.params=t,this.searchString=""}destroy(){super.destroy()}init(){this.autocompleteEntries=this.params.autocompleteEntries,this.virtualList=this.createManagedBean(new Ql({cssIdentifier:"autocomplete"})),this.virtualList.setComponentCreator(this.createRowComponent.bind(this)),this.eList.appendChild(this.virtualList.getGui()),this.virtualList.setModel({getRowCount:()=>this.autocompleteEntries.length,getRow:e=>this.autocompleteEntries[e]});const e=this.virtualList.getGui();this.addManagedListener(e,"click",()=>this.params.onConfirmed()),this.addManagedListener(e,"mousemove",this.onMouseMove.bind(this)),this.addManagedListener(e,"mousedown",e=>e.preventDefault()),this.setSelectedValue(0)}onNavigationKeyDown(e,t){e.preventDefault();const i=this.autocompleteEntries.indexOf(this.selectedValue),r=t===Qr.UP?i-1:i+1;this.checkSetSelectedValue(r)}setSearch(e){this.searchString=e,y(e)?this.runSearch():(this.autocompleteEntries=this.params.autocompleteEntries,this.virtualList.refresh(),this.checkSetSelectedValue(0)),this.updateSearchInList()}runContainsSearch(e,t){let i,r=!1;const n=e.toLocaleLowerCase(),s=t.filter(e=>{const t=e.toLocaleLowerCase().indexOf(n),s=0===t,o=t>=0;return o&&(!i||!r&&s||r===s&&e.length<i.length)&&(i=e,r=s),o});return!i&&s.length&&(i=s[0]),{topMatch:i,allMatches:s}}runSearch(){var e,t;const{autocompleteEntries:i}=this.params,r=i.map(e=>{var t;return null!=(t=e.displayValue)?t:e.key});let n,s;if(this.params.useFuzzySearch)n=Ur(this.searchString,r,!0).values,s=n.length?n[0]:void 0;else{const e=this.runContainsSearch(this.searchString,r);n=e.allMatches,s=e.topMatch}let o=i.filter(({key:e,displayValue:t})=>n.includes(null!=t?t:e));if(!o.length&&this.selectedValue&&(null==(t=null==(e=this.params)?void 0:e.forceLastSelection)?void 0:t.call(e,this.selectedValue,this.searchString))&&(o=[this.selectedValue]),this.autocompleteEntries=o,this.virtualList.refresh(),!s)return;const a=n.indexOf(s);this.checkSetSelectedValue(a)}updateSearchInList(){this.virtualList.forEachRenderedRow(e=>e.setSearchString(this.searchString))}checkSetSelectedValue(e){e>=0&&e<this.autocompleteEntries.length&&this.setSelectedValue(e)}setSelectedValue(e){const t=this.autocompleteEntries[e];this.selectedValue!==t&&(this.selectedValue=t,this.virtualList.ensureIndexVisible(e),this.virtualList.forEachRenderedRow((t,i)=>{t.updateSelected(e===i)}))}createRowComponent(e){var t;const i=new gc;return this.getContext().createBean(i),i.setState(null!=(t=e.displayValue)?t:e.key,e===this.selectedValue),i}onMouseMove(e){const t=this.virtualList.getGui().getBoundingClientRect(),i=this.virtualList.getScrollTop(),r=e.clientY-t.top+i,n=Math.floor(r/this.virtualList.getRowHeight());this.checkSetSelectedValue(n)}afterGuiAttached(){this.virtualList.refresh()}getSelectedValue(){var e;return this.autocompleteEntries.length&&null!=(e=this.selectedValue)?e:null}};fc.TEMPLATE='<div class="ag-autocomplete-list-popup">\n            <div ref="eList" class="ag-autocomplete-list"></div>\n        <div>',g([bn("eList")],fc.prototype,"eList",2),g([le],fc.prototype,"init",1);var mc=fc,vc=class e extends wn{constructor(){super('\n            <div class="ag-autocomplete" role="presentation">\n                <ag-input-text-field ref="eAutocompleteInput"></ag-input-text-field>\n            </div>'),this.isListOpen=!1,this.lastPosition=0,this.valid=!0}postConstruct(){this.eAutocompleteInput.onValueChange(e=>this.onValueChanged(e)),this.eAutocompleteInput.getInputElement().setAttribute("autocomplete","off"),this.addGuiEventListener("keydown",this.onKeyDown.bind(this)),this.addGuiEventListener("click",this.updatePositionAndList.bind(this)),this.addDestroyFunc(()=>{this.destroyBean(this.autocompleteList)}),this.addGuiEventListener("focusout",()=>this.onFocusOut())}onValueChanged(e){const t=C(e);this.updateValue(t),this.updateAutocompleteList(t)}updateValue(t){this.updateLastPosition(),this.dispatchEvent({type:e.EVENT_VALUE_CHANGED,value:t}),this.validate(t)}updateAutocompleteList(e){var t,i,r,n;const s=null!=(i=null==(t=this.listGenerator)?void 0:t.call(this,e,this.lastPosition))?i:{enabled:!1};if(s.type&&s.type===(null==(r=this.autocompleteListParams)?void 0:r.type)||this.isListOpen&&this.closeList(),this.autocompleteListParams=s,null==(n=this.autocompleteListParams)?void 0:n.enabled){this.isListOpen||this.openList();const{searchString:e}=this.autocompleteListParams;this.autocompleteList.setSearch(null!=e?e:"")}else this.isListOpen&&this.closeList()}onKeyDown(e){const t=e.key;switch(this.updateLastPosition(),t){case Qr.ENTER:this.onEnterKeyDown(e);break;case Qr.TAB:this.onTabKeyDown(e);break;case Qr.DOWN:case Qr.UP:this.onUpDownKeyDown(e,t);break;case Qr.LEFT:case Qr.RIGHT:case Qr.PAGE_HOME:case Qr.PAGE_END:setTimeout(()=>{this.updatePositionAndList()});break;case Qr.ESCAPE:this.onEscapeKeyDown(e);break;case Qr.SPACE:e.ctrlKey&&!this.isListOpen&&(e.preventDefault(),this.forceOpenList())}}confirmSelection(){var t;const i=null==(t=this.autocompleteList)?void 0:t.getSelectedValue();i&&(this.closeList(),this.dispatchEvent({type:e.EVENT_OPTION_SELECTED,value:this.getValue(),position:this.lastPosition,updateEntry:i,autocompleteType:this.autocompleteListParams.type}))}onTabKeyDown(e){this.isListOpen&&(e.preventDefault(),e.stopPropagation(),this.confirmSelection())}onEnterKeyDown(e){e.preventDefault(),this.isListOpen?this.confirmSelection():this.onCompleted()}onUpDownKeyDown(e,t){var i;e.preventDefault(),this.isListOpen?null==(i=this.autocompleteList)||i.onNavigationKeyDown(e,t):this.forceOpenList()}onEscapeKeyDown(e){this.isListOpen&&(e.preventDefault(),e.stopPropagation(),this.closeList(),this.setCaret(this.lastPosition,!0))}onFocusOut(){this.isListOpen&&this.closeList()}updatePositionAndList(){var e;this.updateLastPosition(),this.updateAutocompleteList(null!=(e=this.eAutocompleteInput.getValue())?e:null)}setCaret(e,t){const i=this.gos.getDocument(),r=this.gos.getActiveDomElement();!t||r&&r!==i.body||this.eAutocompleteInput.getFocusableElement().focus();const n=this.eAutocompleteInput.getInputElement();n.setSelectionRange(e,e),e===n.value.length&&(n.scrollLeft=n.scrollWidth)}forceOpenList(){this.onValueChanged(this.eAutocompleteInput.getValue())}updateLastPosition(){var e;this.lastPosition=null!=(e=this.eAutocompleteInput.getInputElement().selectionStart)?e:0}validate(t){var i;this.validator&&(this.validationMessage=this.validator(t),this.eAutocompleteInput.getInputElement().setCustomValidity(null!=(i=this.validationMessage)?i:""),this.valid=!this.validationMessage,this.dispatchEvent({type:e.EVENT_VALID_CHANGED,isValid:this.valid,validationMessage:this.validationMessage}))}openList(){this.isListOpen=!0,this.autocompleteList=this.createBean(new mc({autocompleteEntries:this.autocompleteListParams.entries,onConfirmed:()=>this.confirmSelection(),forceLastSelection:this.forceLastSelection}));const e=this.autocompleteList.getGui(),t={ePopup:e,type:"autocomplete",eventSource:this.getGui(),position:"under",alignSide:this.gos.get("enableRtl")?"right":"left",keepWithinBounds:!0},i=this.popupService.addPopup({eChild:e,anchorToElement:this.getGui(),positionCallback:()=>this.popupService.positionPopupByComponent(t),ariaLabel:this.listAriaLabel});this.hidePopup=i.hideFunc,this.autocompleteList.afterGuiAttached()}closeList(){this.isListOpen=!1,this.hidePopup(),this.destroyBean(this.autocompleteList),this.autocompleteList=null}onCompleted(){this.isListOpen&&this.closeList(),this.dispatchEvent({type:e.EVENT_VALUE_CONFIRMED,value:this.getValue(),isValid:this.isValid()})}getValue(){return C(this.eAutocompleteInput.getValue())}setInputPlaceholder(e){return this.eAutocompleteInput.setInputPlaceholder(e),this}setInputAriaLabel(e){return this.eAutocompleteInput.setInputAriaLabel(e),this}setListAriaLabel(e){return this.listAriaLabel=e,this}setListGenerator(e){return this.listGenerator=e,this}setValidator(e){return this.validator=e,this}isValid(){return this.valid}setValue(e){const{value:t,position:i,silent:r,updateListOnlyIfOpen:n,restoreFocus:s}=e;this.eAutocompleteInput.setValue(t,!0),this.setCaret(null!=i?i:this.lastPosition,s),r||this.updateValue(t),n&&!this.isListOpen||this.updateAutocompleteList(t)}setForceLastSelection(e){return this.forceLastSelection=e,this}setInputDisabled(e){return this.eAutocompleteInput.setDisabled(e),this}};vc.EVENT_VALUE_CHANGED="eventValueChanged",vc.EVENT_VALUE_CONFIRMED="eventValueConfirmed",vc.EVENT_OPTION_SELECTED="eventOptionSelected",vc.EVENT_VALID_CHANGED="eventValidChanged",g([he("popupService")],vc.prototype,"popupService",2),g([bn("eAutocompleteInput")],vc.prototype,"eAutocompleteInput",2),g([le],vc.prototype,"postConstruct",1);var Cc=vc,yc=class e extends wn{constructor(e,t,i,r){super(),this.dragSourceDropTarget=e,this.ghost=t,this.horizontal=i,this.template=r}init(){var t;this.setTemplate(null!=(t=this.template)?t:e.TEMPLATE);const i=this.getGui();this.addElementClasses(i),this.addElementClasses(this.eDragHandle,"drag-handle"),this.addElementClasses(this.eText,"text"),this.addElementClasses(this.eButton,"button"),this.eDragHandle.appendChild(qr("columnDrag",this.gos)),this.eButton.appendChild(qr("cancel",this.gos)),this.setupComponents(),!this.ghost&&this.isDraggable()&&this.addDragSource(),this.setupAria(),this.setupTooltip(),this.activateTabIndex(),this.refreshDraggable()}isDraggable(){return!0}refreshDraggable(){this.eDragHandle.classList.toggle("ag-column-select-column-readonly",!this.isDraggable())}setupAria(){const e=this.localeService.getLocaleTextFunc(),t=[this.getAriaDisplayName()];this.addAdditionalAriaInstructions(t,e),Kt(this.getGui(),t.join(". "))}addAdditionalAriaInstructions(e,t){if(this.isRemovable()){const i=t("ariaDropZoneColumnComponentDescription","Press DELETE to remove");e.push(i)}}setupTooltip(){const e=()=>{const e=this.getTooltip();this.setTooltip({newTooltipText:e})};e(),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,e)}getDragSourceId(){}getDefaultIconName(){return Vs.ICON_NOT_ALLOWED}addDragSource(){const{dragAndDropService:e,eDragHandle:t}=this,i=this.createGetDragItem(),r=this.getDefaultIconName(),n={type:this.getDragSourceType(),sourceId:this.getDragSourceId(),eElement:t,getDefaultIconName:()=>r,getDragItem:i,dragItemName:this.getDisplayName()};e.addDragSource(n,!0),this.addDestroyFunc(()=>e.removeDragSource(n))}setupComponents(){this.setTextValue(),this.setupRemove(),this.ghost&&this.addCssClass("ag-column-drop-cell-ghost")}isRemovable(){return!0}refreshRemove(){or(this.eButton,this.isRemovable())}setupRemove(){this.refreshRemove();const t={type:e.EVENT_COLUMN_REMOVE};this.addGuiEventListener("keydown",e=>this.onKeyDown(e)),this.addManagedListener(this.eButton,"click",e=>{this.dispatchEvent(t),e.stopPropagation()});const i=new vs(this.eButton);this.addManagedListener(i,vs.EVENT_TAP,()=>{this.dispatchEvent(t)}),this.addDestroyFunc(i.destroy.bind(i))}onKeyDown(t){t.key===Qr.DELETE&&this.isRemovable()&&(t.preventDefault(),this.dispatchEvent({type:e.EVENT_COLUMN_REMOVE}))}getDisplayValue(){return this.getDisplayName()}setTextValue(){const e=yt(this.getDisplayValue());this.eText.innerHTML=e}addElementClasses(e,t){t=t?`-${t}`:"";const i=this.horizontal?"horizontal":"vertical";e.classList.add(`ag-column-drop-cell${t}`,`ag-column-drop-${i}-cell${t}`)}destroy(){super.destroy(),this.dragSourceDropTarget=null}};yc.EVENT_COLUMN_REMOVE="columnRemove",yc.TEMPLATE='<span role="option">\n          <span ref="eDragHandle" class="ag-drag-handle ag-column-drop-cell-drag-handle" role="presentation"></span>\n          <span ref="eText" class="ag-column-drop-cell-text" aria-hidden="true"></span>\n          <span ref="eButton" class="ag-column-drop-cell-button" role="presentation"></span>\n        </span>',g([he("dragAndDropService")],yc.prototype,"dragAndDropService",2),g([bn("eText")],yc.prototype,"eText",2),g([bn("eDragHandle")],yc.prototype,"eDragHandle",2),g([bn("eButton")],yc.prototype,"eButton",2),g([le],yc.prototype,"init",1);var wc=yc,Sc=class e extends wn{constructor(t){super('<div class="ag-unselectable" role="presentation"></div>'),this.horizontal=t,this.state=e.STATE_NOT_DRAGGING,this.guiDestroyFunctions=[],this.childPillComponents=[],this.resizeEnabled=!1,this.addElementClasses(this.getGui()),this.ePillDropList=document.createElement("div"),this.addElementClasses(this.ePillDropList,"list"),Bt(this.ePillDropList,"listbox")}isHorizontal(){return this.horizontal}toggleResizable(e){this.positionableFeature.setResizable(!!e&&{bottom:!0}),this.resizeEnabled=e}isSourceEventFromTarget(e){const{dropZoneTarget:t,dragSource:i}=e;return t.contains(i.eElement)}destroy(){this.destroyGui(),super.destroy()}destroyGui(){this.guiDestroyFunctions.forEach(e=>e()),this.guiDestroyFunctions.length=0,this.childPillComponents.length=0,yr(this.getGui()),yr(this.ePillDropList)}init(e){this.params=null!=e?e:{},this.createManagedBean(new Pn(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.setupDropTarget(),this.positionableFeature=new In(this.getGui(),{minHeight:100}),this.createManagedBean(this.positionableFeature),this.refreshGui(),Kt(this.ePillDropList,this.getAriaLabel())}handleKeyDown(e){const t=!this.horizontal;let i=e.key===Qr.DOWN,r=e.key===Qr.UP;if(!t){const t=this.gos.get("enableRtl");i=!t&&e.key===Qr.RIGHT||t&&e.key===Qr.LEFT,r=!t&&e.key===Qr.LEFT||t&&e.key===Qr.RIGHT}if(!i&&!r)return;const n=this.focusService.findNextFocusableElement(this.getFocusableElement(),!1,r);n&&(e.preventDefault(),n.focus())}addElementClasses(e,t){t=t?`-${t}`:"";const i=this.horizontal?"horizontal":"vertical";e.classList.add(`ag-column-drop${t}`,`ag-column-drop-${i}${t}`)}setupDropTarget(){this.dropTarget={getContainer:this.getGui.bind(this),getIconName:this.getIconName.bind(this),onDragging:this.onDragging.bind(this),onDragEnter:this.onDragEnter.bind(this),onDragLeave:this.onDragLeave.bind(this),onDragStop:this.onDragStop.bind(this),isInterestedIn:this.isInterestedIn.bind(this)},this.dragAndDropService.addDropTarget(this.dropTarget)}minimumAllowedNewInsertIndex(){return 0}checkInsertIndex(e){const t=this.getNewInsertIndex(e);if(t<0)return!1;const i=this.minimumAllowedNewInsertIndex(),r=Math.max(i,t),n=r!==this.insertIndex;return n&&(this.insertIndex=r),n}getNewInsertIndex(e){const t=e.event,i=this.horizontal?t.clientX:t.clientY,r=this.childPillComponents.map(e=>e.getGui().getBoundingClientRect()),n=r.findIndex(e=>this.horizontal?e.right>i&&e.left<i:e.top<i&&e.bottom>i);if(-1===n){const e=this.gos.get("enableRtl");return r.every(e=>i>(this.horizontal?e.right:e.bottom))?e&&this.horizontal?0:this.childPillComponents.length:r.every(e=>i<(this.horizontal?e.left:e.top))?e&&this.horizontal?this.childPillComponents.length:0:this.insertIndex}return this.insertIndex<=n?n+1:n}checkDragStartedBySelf(t){this.state===e.STATE_NOT_DRAGGING&&(this.state=e.STATE_REARRANGE_ITEMS,this.potentialDndItems=this.getItems(t.dragSource.getDragItem()),this.refreshGui(),this.checkInsertIndex(t),this.refreshGui())}onDragging(e){this.checkDragStartedBySelf(e),this.checkInsertIndex(e)&&this.refreshGui()}handleDragEnterEnd(e){}onDragEnter(t){const i=this.getItems(t.dragSource.getDragItem());this.state=e.STATE_NEW_ITEMS_IN;const r=i.filter(e=>this.isItemDroppable(e,t)),n=r.every(e=>-1!==this.childPillComponents.map(e=>e.getItem()).indexOf(e));0!==r.length&&(this.potentialDndItems=r,n?this.state=e.STATE_NOT_DRAGGING:(this.handleDragEnterEnd(t),this.checkInsertIndex(t),this.refreshGui()))}isPotentialDndItems(){return _e(this.potentialDndItems)}handleDragLeaveEnd(e){}onDragLeave(t){if(this.state===e.STATE_REARRANGE_ITEMS){const e=this.getItems(t.dragSource.getDragItem());this.removeItems(e)}this.isPotentialDndItems()&&(this.handleDragLeaveEnd(t),this.potentialDndItems=[],this.refreshGui()),this.state=e.STATE_NOT_DRAGGING}refreshOnDragStop(){return!0}onDragStop(){if(this.isPotentialDndItems()){let t=!1;this.state===e.STATE_NEW_ITEMS_IN?(this.addItems(this.potentialDndItems),t=!0):t=this.rearrangeItems(this.potentialDndItems),this.potentialDndItems=[],!this.refreshOnDragStop()&&t||this.refreshGui()}this.state=e.STATE_NOT_DRAGGING}removeItems(e){const t=this.getExistingItems().filter(t=>!Be(e,t));this.updateItems(t)}addItems(e){if(!e)return;const t=this.getExistingItems().slice(),i=e.filter(e=>t.indexOf(e)<0);Ve(t,i,this.insertIndex),this.updateItems(t)}addItem(e){this.insertIndex=this.getExistingItems().length,this.addItems([e]),this.refreshGui()}rearrangeItems(e){const t=this.getNonGhostItems().slice();return Ve(t,e,this.insertIndex),!xe(t,this.getExistingItems())&&(this.updateItems(t),!0)}refreshGui(){const e=this.ePillDropList.scrollTop,t=this.resizeEnabled,i=this.getFocusedItem();let r=this.focusService.findNextFocusableElement();r||(r=this.focusService.findNextFocusableElement(void 0,!1,!0)),this.toggleResizable(!1),this.destroyGui(),this.addIconAndTitleToGui(),this.addEmptyMessageToGui(),this.addItemsToGui(),this.isHorizontal()||(this.ePillDropList.scrollTop=e),t&&this.toggleResizable(t),this.focusService.isKeyboardMode()&&this.restoreFocus(i,r)}getFocusedItem(){const e=this.getGui(),t=this.gos.getActiveDomElement();return e.contains(t)?Array.from(e.querySelectorAll(".ag-column-drop-cell")).indexOf(t):-1}restoreFocus(e,t){const i=this.getGui(),r=Array.from(i.querySelectorAll(".ag-column-drop-cell"));if(-1===e)return;0===r.length&&t.focus();const n=r[Math.min(r.length-1,e)];n&&n.focus()}focusList(e){const t=e?this.childPillComponents.length-1:0;this.restoreFocus(t,this.getFocusableElement())}getNonGhostItems(){const e=this.getExistingItems();return this.isPotentialDndItems()?e.filter(e=>!Be(this.potentialDndItems,e)):e}addItemsToGui(){const e=this.getNonGhostItems().map(e=>this.createItemComponent(e,!1));if(this.isPotentialDndItems()){const t=this.potentialDndItems.map(e=>this.createItemComponent(e,!0));this.insertIndex>=e.length?e.push(...t):e.splice(this.insertIndex,0,...t)}this.appendChild(this.ePillDropList),e.forEach((e,t)=>{t>0&&this.addArrow(this.ePillDropList),this.ePillDropList.appendChild(e.getGui())}),this.addAriaLabelsToComponents()}addAriaLabelsToComponents(){this.childPillComponents.forEach((e,t)=>{const i=e.getGui();si(i,t+1),ni(i,this.childPillComponents.length)})}createItemComponent(e,t){const i=this.createPillComponent(e,this.dropTarget,t,this.horizontal);return i.addEventListener(wc.EVENT_COLUMN_REMOVE,this.removeItems.bind(this,[e])),this.context.createBean(i),this.guiDestroyFunctions.push(()=>this.destroyBean(i)),t||this.childPillComponents.push(i),i}addIconAndTitleToGui(){const{title:e,icon:t}=this.params;if(!e||!t)return;const i=document.createElement("div");if(ei(i,!0),this.addElementClasses(i,"title-bar"),this.addElementClasses(t,"icon"),this.addOrRemoveCssClass("ag-column-drop-empty",this.isExistingItemsEmpty()),i.appendChild(t),!this.horizontal){const t=document.createElement("span");this.addElementClasses(t,"title"),t.innerHTML=e,i.appendChild(t)}this.appendChild(i)}isExistingItemsEmpty(){return 0===this.getExistingItems().length}addEmptyMessageToGui(){const{emptyMessage:e}=this.params;if(!e||!this.isExistingItemsEmpty()||this.isPotentialDndItems())return;const t=document.createElement("span");t.innerHTML=e,this.addElementClasses(t,"empty-message"),this.ePillDropList.appendChild(t)}addArrow(e){if(this.horizontal){const t=qr(this.gos.get("enableRtl")?"smallLeft":"smallRight",this.gos);this.addElementClasses(t,"cell-separator"),e.appendChild(t)}}};Sc.STATE_NOT_DRAGGING="notDragging",Sc.STATE_NEW_ITEMS_IN="newItemsIn",Sc.STATE_REARRANGE_ITEMS="rearrangeItems",g([he("focusService")],Sc.prototype,"focusService",2),g([he("dragAndDropService")],Sc.prototype,"dragAndDropService",2);var bc=Sc,Ec=["touchstart","touchend","touchmove","touchcancel"],Ac=class{constructor(e="javascript"){this.frameworkName=e,this.renderingEngine="vanilla",this.wrapIncoming=e=>e(),this.wrapOutgoing=e=>e()}setInterval(e,t){return new dn(i=>{i(window.setInterval(e,t))})}addEventListener(e,t,i,r){const n=Be(Ec,t);e.addEventListener(t,i,{capture:!!r,passive:n})}get shouldWrapOutgoing(){return!1}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return`https://www.ag-grid.com/${"solid"===this.frameworkName?"react":this.frameworkName}-data-grid${e?`/${e}`:""}`}},Tc=class extends nt{getNextCellToFocus(e,t,i=!1){return i?this.getNextCellToFocusWithCtrlPressed(e,t):this.getNextCellToFocusWithoutCtrlPressed(e,t)}getNextCellToFocusWithCtrlPressed(e,t){const i=e===Qr.UP,r=e===Qr.DOWN,n=e===Qr.LEFT;let s,o;if(i||r)o=i?this.paginationProxy.getPageFirstRow():this.paginationProxy.getPageLastRow(),s=t.column;else{const e=this.columnModel.getAllDisplayedColumns(),i=this.gos.get("enableRtl");o=t.rowIndex,s=n!==i?e[0]:Pe(e)}return{rowIndex:o,rowPinned:null,column:s}}getNextCellToFocusWithoutCtrlPressed(e,t){let i=t,r=!1;for(;!r;){switch(e){case Qr.UP:i=this.getCellAbove(i);break;case Qr.DOWN:i=this.getCellBelow(i);break;case Qr.RIGHT:i=this.gos.get("enableRtl")?this.getCellToLeft(i):this.getCellToRight(i);break;case Qr.LEFT:i=this.gos.get("enableRtl")?this.getCellToRight(i):this.getCellToLeft(i);break;default:i=null,console.warn("AG Grid: unknown key for navigation "+e)}r=!i||this.isCellGoodToFocusOn(i)}return i}isCellGoodToFocusOn(e){const t=e.column;let i;switch(e.rowPinned){case"top":i=this.pinnedRowModel.getPinnedTopRow(e.rowIndex);break;case"bottom":i=this.pinnedRowModel.getPinnedBottomRow(e.rowIndex);break;default:i=this.rowModel.getRow(e.rowIndex)}return!!i&&!t.isSuppressNavigable(i)}getCellToLeft(e){if(!e)return null;const t=this.columnModel.getDisplayedColBefore(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellToRight(e){if(!e)return null;const t=this.columnModel.getDisplayedColAfter(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getRowBelow(e){const t=e.rowIndex,i=e.rowPinned;if(this.isLastRowInContainer(e))switch(i){case"bottom":return null;case"top":return this.rowModel.isRowsToRender()?{rowIndex:this.paginationProxy.getPageFirstRow(),rowPinned:null}:this.pinnedRowModel.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null;default:return this.pinnedRowModel.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null}const r=this.rowModel.getRow(e.rowIndex);return this.getNextStickyPosition(r)||{rowIndex:t+1,rowPinned:i}}getNextStickyPosition(e,t){if(!this.gos.isGroupRowsSticky()||!e||!e.sticky)return;let i=[];i=this.rowRenderer.getStickyTopRowCtrls().some(t=>t.getRowNode().rowIndex===e.rowIndex)?[...this.rowRenderer.getStickyTopRowCtrls()].sort((e,t)=>e.getRowNode().rowIndex-t.getRowNode().rowIndex):[...this.rowRenderer.getStickyBottomRowCtrls()].sort((e,t)=>t.getRowNode().rowIndex-e.getRowNode().rowIndex);const r=t?-1:1,n=i.findIndex(t=>t.getRowNode().rowIndex===e.rowIndex),s=i[n+r];return s?{rowIndex:s.getRowNode().rowIndex,rowPinned:null}:void 0}getCellBelow(e){if(!e)return null;const t=this.getRowBelow(e);return t?{rowIndex:t.rowIndex,column:e.column,rowPinned:t.rowPinned}:null}isLastRowInContainer(e){const t=e.rowPinned,i=e.rowIndex;return"top"===t?this.pinnedRowModel.getPinnedTopRowData().length-1<=i:"bottom"===t?this.pinnedRowModel.getPinnedBottomRowData().length-1<=i:this.paginationProxy.getPageLastRow()<=i}getRowAbove(e){const t=e.rowIndex,i=e.rowPinned;if(i?0===t:t===this.paginationProxy.getPageFirstRow())return"top"===i?null:i&&this.rowModel.isRowsToRender()?this.getLastBodyCell():this.pinnedRowModel.isRowsToRender("top")?this.getLastFloatingTopRow():null;const r=this.rowModel.getRow(e.rowIndex);return this.getNextStickyPosition(r,!0)||{rowIndex:t-1,rowPinned:i}}getCellAbove(e){if(!e)return null;const t=this.getRowAbove({rowIndex:e.rowIndex,rowPinned:e.rowPinned});return t?{rowIndex:t.rowIndex,column:e.column,rowPinned:t.rowPinned}:null}getLastBodyCell(){return{rowIndex:this.paginationProxy.getPageLastRow(),rowPinned:null}}getLastFloatingTopRow(){return{rowIndex:this.pinnedRowModel.getPinnedTopRowData().length-1,rowPinned:"top"}}getNextTabbedCell(e,t){return t?this.getNextTabbedCellBackwards(e):this.getNextTabbedCellForwards(e)}getNextTabbedCellForwards(e){const t=this.columnModel.getAllDisplayedColumns();let i=e.rowIndex,r=e.rowPinned,n=this.columnModel.getDisplayedColAfter(e.column);if(!n){n=t[0];const s=this.getRowBelow(e);if(w(s))return null;if(!s.rowPinned&&!this.paginationProxy.isRowInPage(s))return null;i=s?s.rowIndex:null,r=s?s.rowPinned:null}return{rowIndex:i,column:n,rowPinned:r}}getNextTabbedCellBackwards(e){const t=this.columnModel.getAllDisplayedColumns();let i=e.rowIndex,r=e.rowPinned,n=this.columnModel.getDisplayedColBefore(e.column);if(!n){n=Pe(t);const s=this.getRowAbove({rowIndex:e.rowIndex,rowPinned:e.rowPinned});if(w(s))return null;if(!s.rowPinned&&!this.paginationProxy.isRowInPage(s))return null;i=s?s.rowIndex:null,r=s?s.rowPinned:null}return{rowIndex:i,column:n,rowPinned:r}}};g([he("columnModel")],Tc.prototype,"columnModel",2),g([he("rowModel")],Tc.prototype,"rowModel",2),g([he("rowRenderer")],Tc.prototype,"rowRenderer",2),g([he("pinnedRowModel")],Tc.prototype,"pinnedRowModel",2),g([he("paginationProxy")],Tc.prototype,"paginationProxy",2),Tc=g([ue("cellNavigationService")],Tc);var Mc=class extends nt{constructor(){super(...arguments),this.consuming=!1}setBeans(e){this.logger=e.create("AlignedGridsService")}getAlignedGridApis(){var e;let t=null!=(e=this.gos.get("alignedGrids"))?e:[];const i="function"==typeof t;"function"==typeof t&&(t=t());const r=()=>`See ${this.getFrameworkOverrides().getDocLink("aligned-grids")}`;return t.map(e=>{var t;if(!e)return W("alignedGrids contains an undefined option."),i||W('You may want to configure via a callback to avoid setup race conditions:\n                     "alignedGrids: () => [linkedGrid]"'),void W(r());if(e instanceof Uo)return e;const n=e;return"current"in n?null==(t=n.current)?void 0:t.api:(n.api||W(`alignedGrids - No api found on the linked grid. If you are passing gridOptions to alignedGrids since v31 this is no longer valid. ${r()}`),n.api)}).filter(e=>!!e&&!e.isDestroyed())}init(){this.addManagedListener(this.eventService,ct.EVENT_COLUMN_MOVED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VISIBLE,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PINNED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_GROUP_OPENED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_RESIZED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL,this.fireScrollEvent.bind(this))}fireEvent(e){this.consuming||this.getAlignedGridApis().forEach(t=>{if(t.isDestroyed())return;const i=t.__getAlignedGridService();e(i)})}onEvent(e){this.consuming=!0,e(),this.consuming=!1}fireColumnEvent(e){this.fireEvent(t=>{t.onColumnEvent(e)})}fireScrollEvent(e){"horizontal"===e.direction&&this.fireEvent(t=>{t.onScrollEvent(e)})}onScrollEvent(e){this.onEvent(()=>{this.ctrlsService.getGridBodyCtrl().getScrollFeature().setHorizontalScrollPosition(e.left,!0)})}getMasterColumns(e){const t=[];return e.columns?e.columns.forEach(e=>{t.push(e)}):e.column&&t.push(e.column),t}getColumnIds(e){const t=[];return e.columns?e.columns.forEach(e=>{t.push(e.getColId())}):e.column&&t.push(e.column.getColId()),t}onColumnEvent(e){this.onEvent(()=>{switch(e.type){case ct.EVENT_COLUMN_MOVED:case ct.EVENT_COLUMN_VISIBLE:case ct.EVENT_COLUMN_PINNED:case ct.EVENT_COLUMN_RESIZED:const t=e;this.processColumnEvent(t);break;case ct.EVENT_COLUMN_GROUP_OPENED:const i=e;this.processGroupOpenedEvent(i);break;case ct.EVENT_COLUMN_PIVOT_CHANGED:console.warn("AG Grid: pivoting is not supported with aligned grids. You can only use one of these features at a time in a grid.")}})}processGroupOpenedEvent(e){e.columnGroups.forEach(t=>{let i=null;if(t){const e=t.getGroupId();i=this.columnModel.getProvidedColumnGroup(e)}t&&!i||(this.logger.log("onColumnEvent-> processing "+e+" expanded = "+t.isExpanded()),this.columnModel.setColumnGroupOpened(i,t.isExpanded(),"alignedGridChanged"))})}processColumnEvent(e){var t;const i=e.column;let r=null;if(i&&(r=this.columnModel.getPrimaryColumn(i.getColId())),i&&!r)return;const n=this.getMasterColumns(e);switch(e.type){case ct.EVENT_COLUMN_MOVED:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId}));this.columnModel.applyColumnState({state:i,applyOrder:!0},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} toIndex = ${t.toIndex}`)}break;case ct.EVENT_COLUMN_VISIBLE:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId,hide:e.hide}));this.columnModel.applyColumnState({state:i},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} visible = ${t.visible}`)}break;case ct.EVENT_COLUMN_PINNED:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId,pinned:e.pinned}));this.columnModel.applyColumnState({state:i},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} pinned = ${t.pinned}`)}break;case ct.EVENT_COLUMN_RESIZED:const i=e,r={};n.forEach(t=>{this.logger.log(`onColumnEvent-> processing ${e.type} actualWidth = ${t.getActualWidth()}`),r[t.getId()]={key:t.getColId(),newWidth:t.getActualWidth()}}),null==(t=i.flexColumns)||t.forEach(e=>{r[e.getId()]&&delete r[e.getId()]}),this.columnModel.setColumnWidths(Object.values(r),!1,i.finished,"alignedGridChanged")}const s=this.ctrlsService.getGridBodyCtrl().isVerticalScrollShowing();this.getAlignedGridApis().forEach(e=>{e.setGridOption("alwaysShowVerticalScroll",s)})}};g([he("columnModel")],Mc.prototype,"columnModel",2),g([he("ctrlsService")],Mc.prototype,"ctrlsService",2),g([f(0,ge("loggerFactory"))],Mc.prototype,"setBeans",1),g([le],Mc.prototype,"init",1),Mc=g([ue("alignedGridsService")],Mc);var Rc=class extends nt{constructor(){super(...arguments),this.selectedNodes=new Map,this.lastRowNode=null}init(){this.rowSelection=this.gos.get("rowSelection"),this.groupSelectsChildren=this.gos.get("groupSelectsChildren"),this.addManagedPropertyListeners(["groupSelectsChildren","rowSelection"],()=>{this.groupSelectsChildren=this.gos.get("groupSelectsChildren"),this.rowSelection=this.gos.get("rowSelection"),this.deselectAllRowNodes({source:"api"})}),this.addManagedListener(this.eventService,ct.EVENT_ROW_SELECTED,this.onRowSelected.bind(this))}destroy(){super.destroy(),this.resetNodes(),this.lastRowNode=null}isMultiselect(){return"multiple"===this.rowSelection}setNodesSelected(e){var t;const{newValue:i,clearSelection:r,suppressFinishActions:n,rangeSelect:s,nodes:o,event:a,source:l="api"}=e;if(0===o.length)return 0;if(o.length>1&&!this.isMultiselect())return console.warn("AG Grid: cannot multi select while rowSelection='single'"),0;const c=this.groupSelectsChildren&&!0===e.groupSelectsFiltered,u=o.map(e=>e.footer?e.sibling:e);if(s){if(o.length>1)return console.warn("AG Grid: cannot range select while selecting multiple rows"),0;let e=null;if("checkboxSelected"===l&&!1===i&&this.lastRowNode&&(this.lastRowNode.id?e=this.lastRowNode:this.lastRowNode=null),null==e&&(e=this.getLastSelectedNode()),e){const t=u[0];if(t!==e&&this.isMultiselect())return this.selectRange(t,e,i,l)}}this.lastRowNode=i?null:u[0];let h=0;for(let e=0;e<u.length;e++){const r=u[e];c&&r.group||r.selectThisNode(i,a,l)&&h++,this.groupSelectsChildren&&(null==(t=r.childrenAfterGroup)?void 0:t.length)&&(h+=this.selectChildren(r,i,c,l))}if(!n&&(i&&(r||!this.isMultiselect())&&(h+=this.clearOtherNodes(u[0],l)),h>0)){this.updateGroupsFromChildrenSelections(l);const e={type:ct.EVENT_SELECTION_CHANGED,source:l};this.eventService.dispatchEvent(e)}return h}selectRange(e,t,i=!0,r){const n=this.rowModel.getNodesInRangeForSelection(e,t);let s=0;n.forEach(e=>{e.group&&this.groupSelectsChildren||e.selectThisNode(i,void 0,r)&&s++}),this.updateGroupsFromChildrenSelections(r);const o={type:ct.EVENT_SELECTION_CHANGED,source:r};return this.eventService.dispatchEvent(o),s}selectChildren(e,t,i,r){const n=i?e.childrenAfterAggFilter:e.childrenAfterGroup;return w(n)?0:this.setNodesSelected({newValue:t,clearSelection:!1,suppressFinishActions:!0,groupSelectsFiltered:i,source:r,nodes:n})}getLastSelectedNode(){const e=Array.from(this.selectedNodes.keys());if(0==e.length)return null;return this.selectedNodes.get(Pe(e))||null}getSelectedNodes(){const e=[];return this.selectedNodes.forEach(t=>{t&&e.push(t)}),e}getSelectedRows(){const e=[];return this.selectedNodes.forEach(t=>{t&&t.data&&e.push(t.data)}),e}getSelectionCount(){return this.selectedNodes.size}filterFromSelection(e){const t=new Map;this.selectedNodes.forEach((i,r)=>{i&&e(i)&&t.set(r,i)}),this.selectedNodes=t}updateGroupsFromChildrenSelections(e,t){if(!this.groupSelectsChildren)return!1;if("clientSide"!==this.rowModel.getType())return!1;const i=this.rowModel.getRootNode();t||(t=new Gl(!0,i)).setInactive();let r=!1;return t.forEachChangedNodeDepthFirst(t=>{if(t!==i){const i=t.calculateSelectedFromChildren();r=t.selectThisNode(null!==i&&i,void 0,e)||r}}),r}clearOtherNodes(e,t){const i=new Map;let r=0;return this.selectedNodes.forEach(n=>{if(n&&n.id!==e.id){const e=this.selectedNodes.get(n.id);r+=e.setSelectedParams({newValue:!1,clearSelection:!1,suppressFinishActions:!0,source:t}),this.groupSelectsChildren&&n.parent&&i.set(n.parent.id,n.parent)}}),i.forEach(e=>{const i=e.calculateSelectedFromChildren();e.selectThisNode(null!==i&&i,void 0,t)}),r}onRowSelected(e){const t=e.node;this.groupSelectsChildren&&t.group||(t.isSelected()?this.selectedNodes.set(t.id,t):this.selectedNodes.delete(t.id))}syncInRowNode(e,t){this.syncInOldRowNode(e,t),this.syncInNewRowNode(e)}syncInOldRowNode(e,t){if(y(t)&&e.id!==t.id&&t){const i=t.id;this.selectedNodes.get(i)==e&&this.selectedNodes.set(t.id,t)}}syncInNewRowNode(e){this.selectedNodes.has(e.id)?(e.setSelectedInitialValue(!0),this.selectedNodes.set(e.id,e)):e.setSelectedInitialValue(!1)}reset(e){const t=this.getSelectionCount();if(this.resetNodes(),t){const t={type:ct.EVENT_SELECTION_CHANGED,source:e};this.eventService.dispatchEvent(t)}}resetNodes(){var e;null==(e=this.selectedNodes)||e.clear()}getBestCostNodeSelection(){if("clientSide"!==this.rowModel.getType())return;const e=this.rowModel.getTopLevelNodes();if(null===e)return;const t=[];return function e(i){for(let r=0,n=i.length;r<n;r++){const n=i[r];if(n.isSelected())t.push(n);else{const t=n;t.group&&t.children&&e(t.children)}}}(e),t}isEmpty(){let e=0;return this.selectedNodes.forEach(t=>{t&&e++}),0===e}deselectAllRowNodes(e){const t=e=>e.selectThisNode(!1,void 0,r),i="clientSide"===this.rowModel.getType(),{source:r,justFiltered:n,justCurrentPage:s}=e;if(s||n){if(!i)return void console.error("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'");this.getNodesToSelect(n,s).forEach(t)}else this.selectedNodes.forEach(e=>{e&&t(e)}),this.reset(r);i&&this.groupSelectsChildren&&this.updateGroupsFromChildrenSelections(r);const o={type:ct.EVENT_SELECTION_CHANGED,source:r};this.eventService.dispatchEvent(o)}getSelectedCounts(e,t){let i=0,r=0;return this.getNodesToSelect(e,t).forEach(e=>{this.groupSelectsChildren&&e.group||(e.isSelected()?i++:e.selectable&&r++)}),{selectedCount:i,notSelectedCount:r}}getSelectAllState(e,t){const{selectedCount:i,notSelectedCount:r}=this.getSelectedCounts(e,t);return(0!==i||0!==r)&&(i>0&&r>0?null:i>0)}hasNodesToSelect(e=!1,t=!1){return this.getNodesToSelect(e,t).filter(e=>e.selectable).length>0}getNodesToSelect(e=!1,t=!1){if("clientSide"!==this.rowModel.getType())throw new Error(`selectAll only available when rowModelType='clientSide', ie not ${this.rowModel.getType()}`);const i=[];if(t)return this.paginationProxy.forEachNodeOnPage(e=>{if(e.group){if(!e.expanded){const t=e=>{var r;i.push(e),(null==(r=e.childrenAfterFilter)?void 0:r.length)&&e.childrenAfterFilter.forEach(t)};return void t(e)}this.groupSelectsChildren||i.push(e)}else i.push(e)}),i;const r=this.rowModel;return e?(r.forEachNodeAfterFilter(e=>{i.push(e)}),i):(r.forEachNode(e=>{i.push(e)}),i)}selectAllRowNodes(e){if("clientSide"!==this.rowModel.getType())throw new Error(`selectAll only available when rowModelType='clientSide', ie not ${this.rowModel.getType()}`);const{source:t,justFiltered:i,justCurrentPage:r}=e;this.getNodesToSelect(i,r).forEach(e=>e.selectThisNode(!0,void 0,t)),"clientSide"===this.rowModel.getType()&&this.groupSelectsChildren&&this.updateGroupsFromChildrenSelections(t);const n={type:ct.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(n)}getSelectionState(){const e=[];return this.selectedNodes.forEach(t=>{(null==t?void 0:t.id)&&e.push(t.id)}),e.length?e:null}setSelectionState(e,t){if(!Array.isArray(e))return;const i=new Set(e),r=[];this.rowModel.forEachNode(e=>{i.has(e.id)&&r.push(e)}),this.setNodesSelected({newValue:!0,nodes:r,source:t})}};g([he("rowModel")],Rc.prototype,"rowModel",2),g([he("paginationProxy")],Rc.prototype,"paginationProxy",2),g([le],Rc.prototype,"init",1),Rc=g([ue("selectionService")],Rc);var _c=class{constructor(e){this.viaApi=(e,...t)=>(U(`Since v31, 'columnApi.${e}' is deprecated and moved to 'api.${e}'.`),this.api[e](...t)),this.api=e}sizeColumnsToFit(e){this.viaApi("sizeColumnsToFit",e)}setColumnGroupOpened(e,t){this.viaApi("setColumnGroupOpened",e,t)}getColumnGroup(e,t){return this.viaApi("getColumnGroup",e,t)}getProvidedColumnGroup(e){return this.viaApi("getProvidedColumnGroup",e)}getDisplayNameForColumn(e,t){return this.viaApi("getDisplayNameForColumn",e,t)}getDisplayNameForColumnGroup(e,t){return this.viaApi("getDisplayNameForColumnGroup",e,t)}getColumn(e){return this.viaApi("getColumn",e)}getColumns(){return this.viaApi("getColumns")}applyColumnState(e){return this.viaApi("applyColumnState",e)}getColumnState(){return this.viaApi("getColumnState")}resetColumnState(){this.viaApi("resetColumnState")}getColumnGroupState(){return this.viaApi("getColumnGroupState")}setColumnGroupState(e){this.viaApi("setColumnGroupState",e)}resetColumnGroupState(){this.viaApi("resetColumnGroupState")}isPinning(){return this.viaApi("isPinning")}isPinningLeft(){return this.viaApi("isPinningLeft")}isPinningRight(){return this.viaApi("isPinningRight")}getDisplayedColAfter(e){return this.viaApi("getDisplayedColAfter",e)}getDisplayedColBefore(e){return this.viaApi("getDisplayedColBefore",e)}setColumnVisible(e,t){this.viaApi("setColumnVisible",e,t)}setColumnsVisible(e,t){this.viaApi("setColumnsVisible",e,t)}setColumnPinned(e,t){this.viaApi("setColumnPinned",e,t)}setColumnsPinned(e,t){this.viaApi("setColumnsPinned",e,t)}getAllGridColumns(){return this.viaApi("getAllGridColumns")}getDisplayedLeftColumns(){return this.viaApi("getDisplayedLeftColumns")}getDisplayedCenterColumns(){return this.viaApi("getDisplayedCenterColumns")}getDisplayedRightColumns(){return this.viaApi("getDisplayedRightColumns")}getAllDisplayedColumns(){return this.viaApi("getAllDisplayedColumns")}getAllDisplayedVirtualColumns(){return this.viaApi("getAllDisplayedVirtualColumns")}moveColumn(e,t){this.viaApi("moveColumn",e,t)}moveColumnByIndex(e,t){this.viaApi("moveColumnByIndex",e,t)}moveColumns(e,t){this.viaApi("moveColumns",e,t)}moveRowGroupColumn(e,t){this.viaApi("moveRowGroupColumn",e,t)}setColumnAggFunc(e,t){this.viaApi("setColumnAggFunc",e,t)}setColumnWidth(e,t,i=!0,r){this.viaApi("setColumnWidth",e,t,i,r)}setColumnWidths(e,t=!0,i){this.viaApi("setColumnWidths",e,t,i)}setPivotMode(e){this.viaApi("setPivotMode",e)}isPivotMode(){return this.viaApi("isPivotMode")}getPivotResultColumn(e,t){return this.viaApi("getPivotResultColumn",e,t)}setValueColumns(e){this.viaApi("setValueColumns",e)}getValueColumns(){return this.viaApi("getValueColumns")}removeValueColumn(e){this.viaApi("removeValueColumn",e)}removeValueColumns(e){this.viaApi("removeValueColumns",e)}addValueColumn(e){this.viaApi("addValueColumn",e)}addValueColumns(e){this.viaApi("addValueColumns",e)}setRowGroupColumns(e){this.viaApi("setRowGroupColumns",e)}removeRowGroupColumn(e){this.viaApi("removeRowGroupColumn",e)}removeRowGroupColumns(e){this.viaApi("removeRowGroupColumns",e)}addRowGroupColumn(e){this.viaApi("addRowGroupColumn",e)}addRowGroupColumns(e){this.viaApi("addRowGroupColumns",e)}getRowGroupColumns(){return this.viaApi("getRowGroupColumns")}setPivotColumns(e){this.viaApi("setPivotColumns",e)}removePivotColumn(e){this.viaApi("removePivotColumn",e)}removePivotColumns(e){this.viaApi("removePivotColumns",e)}addPivotColumn(e){this.viaApi("addPivotColumn",e)}addPivotColumns(e){this.viaApi("addPivotColumns",e)}getPivotColumns(){return this.viaApi("getPivotColumns")}getLeftDisplayedColumnGroups(){return this.viaApi("getLeftDisplayedColumnGroups")}getCenterDisplayedColumnGroups(){return this.viaApi("getCenterDisplayedColumnGroups")}getRightDisplayedColumnGroups(){return this.viaApi("getRightDisplayedColumnGroups")}getAllDisplayedColumnGroups(){return this.viaApi("getAllDisplayedColumnGroups")}autoSizeColumn(e,t){return this.viaApi("autoSizeColumn",e,t)}autoSizeColumns(e,t){this.viaApi("autoSizeColumns",e,t)}autoSizeAllColumns(e){this.viaApi("autoSizeAllColumns",e)}setPivotResultColumns(e){this.viaApi("setPivotResultColumns",e)}getPivotResultColumns(){return this.viaApi("getPivotResultColumns")}};g([he("gridApi")],_c.prototype,"api",2),_c=g([ue("columnApi")],_c);var Pc=class extends nt{constructor(){super(...arguments),this.initialised=!1,this.isSsrm=!1}init(){this.isSsrm=this.gos.isRowModelType("serverSide"),this.cellExpressions=this.gos.get("enableCellExpressions"),this.isTreeData=this.gos.get("treeData"),this.initialised=!0;const e=e=>this.callColumnCellValueChangedHandler(e),t=this.gos.useAsyncEvents();this.eventService.addEventListener(ct.EVENT_CELL_VALUE_CHANGED,e,t),this.addDestroyFunc(()=>this.eventService.removeEventListener(ct.EVENT_CELL_VALUE_CHANGED,e,t)),this.addManagedPropertyListener("treeData",e=>this.isTreeData=e.currentValue)}getValue(e,t,i=!1,r=!1){if(this.initialised||this.init(),!t)return;const n=e.getColDef(),s=n.field,o=e.getColId(),a=t.data;let l;const c=t.groupData&&void 0!==t.groupData[o],u=!r&&t.aggData&&void 0!==t.aggData[o],h=this.isSsrm&&r&&!!e.getColDef().aggFunc,d=this.isSsrm&&t.footer&&t.field&&(!0===e.getColDef().showRowGroup||e.getColDef().showRowGroup===t.field);if(i&&n.filterValueGetter?l=this.executeFilterValueGetter(n.filterValueGetter,a,e,t):this.isTreeData&&u?l=t.aggData[o]:this.isTreeData&&n.valueGetter?l=this.executeValueGetter(n.valueGetter,a,e,t):this.isTreeData&&s&&a?l=k(a,s,e.isFieldContainsDots()):c?l=t.groupData[o]:u?l=t.aggData[o]:n.valueGetter?l=this.executeValueGetter(n.valueGetter,a,e,t):d?l=k(a,t.field,e.isFieldContainsDots()):s&&a&&!h&&(l=k(a,s,e.isFieldContainsDots())),this.cellExpressions&&"string"==typeof l&&0===l.indexOf("=")){const i=l.substring(1);l=this.executeValueGetter(i,a,e,t)}if(null==l){const i=this.getOpenedGroup(t,e);if(null!=i)return i}return l}parseValue(e,t,i,r){const n=e.getColDef(),s=this.gos.addGridCommonParams({node:t,data:null==t?void 0:t.data,oldValue:r,newValue:i,colDef:n,column:e}),o=n.valueParser;return y(o)?"function"==typeof o?o(s):this.expressionService.evaluate(o,s):i}formatValue(e,t,i,r,n=!0){let s,o=null;const a=e.getColDef();if(r?s=r:n&&(s=a.valueFormatter),s){const r=this.gos.addGridCommonParams({value:i,node:t,data:t?t.data:null,colDef:a,column:e});o="function"==typeof s?s(r):this.expressionService.evaluate(s,r)}else if(a.refData)return a.refData[i]||"";return null==o&&Array.isArray(i)&&(o=i.join(", ")),o}getOpenedGroup(e,t){if(!this.gos.get("showOpenedGroup"))return;if(!t.getColDef().showRowGroup)return;const i=t.getColDef().showRowGroup;let r=e.parent;for(;null!=r;){if(r.rowGroupColumn&&(!0===i||i===r.rowGroupColumn.getColId()))return r.key;r=r.parent}}setValue(e,t,i,r){const n=this.columnModel.getPrimaryColumn(t);if(!e||!n)return!1;w(e.data)&&(e.data={});const{field:s,valueSetter:o}=n.getColDef();if(w(s)&&w(o))return console.warn("AG Grid: you need either field or valueSetter set on colDef for editing to work"),!1;if(!this.dataTypeService.checkType(n,i))return console.warn("AG Grid: Data type of the new value does not match the cell data type of the column"),!1;const a=this.gos.addGridCommonParams({node:e,data:e.data,oldValue:this.getValue(n,e),newValue:i,colDef:n.getColDef(),column:n});let l;if(a.newValue=i,l=y(o)?"function"==typeof o?o(a):this.expressionService.evaluate(o,a):this.setValueUsingField(e.data,s,i,n.isFieldContainsDots()),void 0===l&&(l=!0),!l)return!1;e.resetQuickFilterAggregateText(),this.valueCache.onDataChanged(),a.newValue=this.getValue(n,e);const c={type:ct.EVENT_CELL_VALUE_CHANGED,event:null,rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:a.column,api:a.api,columnApi:a.columnApi,colDef:a.colDef,context:a.context,data:e.data,node:e,oldValue:a.oldValue,newValue:a.newValue,value:a.newValue,source:r};return this.eventService.dispatchEvent(c),!0}callColumnCellValueChangedHandler(e){const t=e.colDef.onCellValueChanged;"function"==typeof t&&this.getFrameworkOverrides().wrapOutgoing(()=>{t({node:e.node,data:e.data,oldValue:e.oldValue,newValue:e.newValue,colDef:e.colDef,column:e.column,api:e.api,columnApi:e.columnApi,context:e.context})})}setValueUsingField(e,t,i,r){if(!t)return!1;let n=!1;if(r){const r=t.split(".");let s=e;for(;r.length>0&&s;){const e=r.shift();0===r.length?(n=s[e]===i,n||(s[e]=i)):s=s[e]}}else n=e[t]===i,n||(e[t]=i);return!n}executeFilterValueGetter(e,t,i,r){const n=this.gos.addGridCommonParams({data:t,node:r,column:i,colDef:i.getColDef(),getValue:this.getValueCallback.bind(this,r)});return"function"==typeof e?e(n):this.expressionService.evaluate(e,n)}executeValueGetter(e,t,i,r){const n=i.getColId(),s=this.valueCache.getValue(r,n);if(void 0!==s)return s;const o=this.gos.addGridCommonParams({data:t,node:r,column:i,colDef:i.getColDef(),getValue:this.getValueCallback.bind(this,r)});let a;return a="function"==typeof e?e(o):this.expressionService.evaluate(e,o),this.valueCache.setValue(r,n,a),a}getValueCallback(e,t){const i=this.columnModel.getPrimaryColumn(t);return i?this.getValue(i,e):null}getKeyForNode(e,t){const i=this.getValue(e,t),r=e.getColDef().keyCreator;let n=i;return r&&(n=r(this.gos.addGridCommonParams({value:i,colDef:e.getColDef(),column:e,node:t,data:t.data}))),"string"==typeof n||null==n||(n=String(n),"[object Object]"===n&&U("a column you are grouping or pivoting by has objects as values. If you want to group by complex objects then either a) use a colDef.keyCreator (se AG Grid docs) or b) to toString() on the object to return a key")),n}};g([he("expressionService")],Pc.prototype,"expressionService",2),g([he("columnModel")],Pc.prototype,"columnModel",2),g([he("valueCache")],Pc.prototype,"valueCache",2),g([he("dataTypeService")],Pc.prototype,"dataTypeService",2),g([le],Pc.prototype,"init",1),Pc=g([ue("valueService")],Pc);var xc=class extends nt{constructor(){super(...arguments),this.expressionToFunctionCache={}}setBeans(e){this.logger=e.create("ExpressionService")}evaluate(e,t){if("string"==typeof e)return this.evaluateExpression(e,t);console.error("AG Grid: value should be either a string or a function",e)}evaluateExpression(e,t){try{return this.createExpressionFunction(e)(t.value,t.context,t.oldValue,t.newValue,t.value,t.node,t.data,t.colDef,t.rowIndex,t.api,t.columnApi,t.getValue,t.column,t.columnGroup)}catch(i){return console.log("Processing of the expression failed"),console.log("Expression = "+e),console.log("Params =",t),console.log("Exception = "+i),null}}createExpressionFunction(e){if(this.expressionToFunctionCache[e])return this.expressionToFunctionCache[e];const t=this.createFunctionBody(e),i=new Function("x, ctx, oldValue, newValue, value, node, data, colDef, rowIndex, api, columnApi, getValue, column, columnGroup",t);return this.expressionToFunctionCache[e]=i,i}createFunctionBody(e){return e.indexOf("return")>=0?e:"return "+e+";"}};g([f(0,ge("loggerFactory"))],xc.prototype,"setBeans",1),xc=g([ue("expressionService")],xc);var Dc=class extends nt{setBeans(e){this.logging=e.get("debug")}create(e){return new Ic(e,this.isLogging.bind(this))}isLogging(){return this.logging}};g([f(0,ge("gridOptionsService"))],Dc.prototype,"setBeans",1),Dc=g([ue("loggerFactory")],Dc);var Ic=class{constructor(e,t){this.name=e,this.isLoggingFunc=t}isLogging(){return this.isLoggingFunc()}log(e){this.isLoggingFunc()&&console.log("AG Grid."+this.name+": "+e)}},Lc=class extends nt{setComp(e,t,i){this.view=e,this.eGridHostDiv=t,this.eGui=i,this.eGui.setAttribute("grid-id",this.context.getGridId()),this.dragAndDropService.addDropTarget({getContainer:()=>this.eGui,isInterestedIn:e=>1===e||0===e,getIconName:()=>Vs.ICON_NOT_ALLOWED}),this.mouseEventService.stampTopLevelGridCompWithGridInstance(t),this.createManagedBean(new Xo(this.view)),this.addRtlSupport();const r=this.resizeObserverService.observeResize(this.eGridHostDiv,this.onGridSizeChanged.bind(this));this.addDestroyFunc(()=>r()),this.ctrlsService.register("gridCtrl",this)}isDetailGrid(){var e;const t=this.focusService.findTabbableParent(this.getGui());return(null==(e=null==t?void 0:t.getAttribute("row-id"))?void 0:e.startsWith("detail"))||!1}showDropZones(){return se.__isRegistered("@ag-grid-enterprise/row-grouping",this.context.getGridId())}showSideBar(){return se.__isRegistered("@ag-grid-enterprise/side-bar",this.context.getGridId())}showStatusBar(){return se.__isRegistered("@ag-grid-enterprise/status-bar",this.context.getGridId())}showWatermark(){return se.__isRegistered("@ag-grid-enterprise/core",this.context.getGridId())}onGridSizeChanged(){const e={type:ct.EVENT_GRID_SIZE_CHANGED,clientWidth:this.eGridHostDiv.clientWidth,clientHeight:this.eGridHostDiv.clientHeight};this.eventService.dispatchEvent(e)}addRtlSupport(){const e=this.gos.get("enableRtl")?"ag-rtl":"ag-ltr";this.view.setRtlClass(e)}destroyGridUi(){this.view.destroyGridUi()}getGui(){return this.eGui}setResizeCursor(e){this.view.setCursor(e?"ew-resize":null)}disableUserSelect(e){this.view.setUserSelect(e?"none":null)}focusNextInnerContainer(e){const t=this.view.getFocusableContainers(),i=this.gos.getActiveDomElement(),r=t.findIndex(e=>e.contains(i))+(e?-1:1);return!(r<=0||r>=t.length)&&this.focusService.focusInto(t[r])}focusInnerElement(e){const t=this.view.getFocusableContainers(),i=this.columnModel.getAllDisplayedColumns();if(e){if(t.length>1)return this.focusService.focusInto(Pe(t),!0);const e=Pe(i);if(this.focusService.focusGridView(e,!0))return!0}if(0===this.gos.get("headerHeight")||this.gos.get("suppressHeaderFocus")){if(this.focusService.focusGridView(i[0]))return!0;for(let e=1;e<t.length;e++)if(this.focusService.focusInto(t[e]))return!0;return!1}return this.focusService.focusFirstHeader()}forceFocusOutOfContainer(e=!1){this.view.forceFocusOutOfContainer(e)}};g([he("focusService")],Lc.prototype,"focusService",2),g([he("resizeObserverService")],Lc.prototype,"resizeObserverService",2),g([he("columnModel")],Lc.prototype,"columnModel",2),g([he("ctrlsService")],Lc.prototype,"ctrlsService",2),g([he("mouseEventService")],Lc.prototype,"mouseEventService",2),g([he("dragAndDropService")],Lc.prototype,"dragAndDropService",2);var Nc=class extends Al{constructor(e){super(),this.eGridDiv=e}postConstruct(){this.logger=this.loggerFactory.create("GridComp");const e={destroyGridUi:()=>this.destroyBean(this),setRtlClass:e=>this.addCssClass(e),forceFocusOutOfContainer:this.forceFocusOutOfContainer.bind(this),updateLayoutClasses:this.updateLayoutClasses.bind(this),getFocusableContainers:this.getFocusableContainers.bind(this),setUserSelect:e=>{this.getGui().style.userSelect=null!=e?e:"",this.getGui().style.webkitUserSelect=null!=e?e:""},setCursor:e=>{this.getGui().style.cursor=null!=e?e:""}};this.ctrl=this.createManagedBean(new Lc);const t=this.createTemplate();this.setTemplate(t),this.ctrl.setComp(e,this.eGridDiv,this.getGui()),this.insertGridIntoDom(),this.initialiseTabGuard({onTabKeyDown:()=>{},focusInnerElement:e=>this.ctrl.focusInnerElement(e),forceFocusOutWhenTabGuardsAreEmpty:!0})}insertGridIntoDom(){const e=this.getGui();this.eGridDiv.appendChild(e),this.addDestroyFunc(()=>{this.eGridDiv.removeChild(e),this.logger.log("Grid removed from DOM")})}updateLayoutClasses(e,t){const i=this.eRootWrapperBody.classList;i.toggle("ag-layout-auto-height",t.autoHeight),i.toggle("ag-layout-normal",t.normal),i.toggle("ag-layout-print",t.print),this.addOrRemoveCssClass("ag-layout-auto-height",t.autoHeight),this.addOrRemoveCssClass("ag-layout-normal",t.normal),this.addOrRemoveCssClass("ag-layout-print",t.print)}createTemplate(){return`<div class="ag-root-wrapper" role="presentation">\n                ${this.ctrl.showDropZones()?"<ag-grid-header-drop-zones></ag-grid-header-drop-zones>":""}\n                <div class="ag-root-wrapper-body" ref="rootWrapperBody" role="presentation">\n                    <ag-grid-body ref="gridBody"></ag-grid-body>\n                    ${this.ctrl.showSideBar()?'<ag-side-bar ref="sideBar"></ag-side-bar>':""}\n                </div>\n                ${this.ctrl.showStatusBar()?'<ag-status-bar ref="statusBar"></ag-status-bar>':""}\n                <ag-pagination></ag-pagination>\n                ${this.ctrl.showWatermark()?"<ag-watermark></ag-watermark>":""}\n            </div>`}getFocusableElement(){return this.eRootWrapperBody}getFocusableContainers(){const e=[this.gridBodyComp.getGui()];return this.sideBarComp&&e.push(this.sideBarComp.getGui()),e.filter(e=>br(e))}};g([he("loggerFactory")],Nc.prototype,"loggerFactory",2),g([bn("gridBody")],Nc.prototype,"gridBodyComp",2),g([bn("sideBar")],Nc.prototype,"sideBarComp",2),g([bn("rootWrapperBody")],Nc.prototype,"eRootWrapperBody",2),g([le],Nc.prototype,"postConstruct",1);var Oc=class extends nt{progressSort(e,t,i){const r=this.getNextSortDirection(e);this.setSortForColumn(e,r,t,i)}setSortForColumn(e,t,i,r){"asc"!==t&&"desc"!==t&&(t=null);let n=[e];if(this.gos.isColumnsSortingCoupledToGroup()&&e.getColDef().showRowGroup){const t=this.columnModel.getSourceColumnsForGroupColumn(e),i=null==t?void 0:t.filter(e=>e.isSortable());i&&(n=[e,...i])}n.forEach(e=>e.setSort(t,r));const s=[];if(!i&&!this.gos.get("alwaysMultiSort")||this.gos.get("suppressMultiSort")){const e=this.clearSortBarTheseColumns(n,r);s.push(...e)}this.updateSortIndex(e),s.push(...n),this.dispatchSortChangedEvents(r,s)}updateSortIndex(e){const t=this.gos.isColumnsSortingCoupledToGroup(),i=this.columnModel.getGroupDisplayColumnForGroup(e.getId()),r=t&&i||e,n=this.getColumnsWithSortingOrdered();this.columnModel.getPrimaryAndSecondaryAndAutoColumns().forEach(e=>e.setSortIndex(null));const s=n.filter(e=>!(t&&e.getColDef().showRowGroup||e===r));(r.getSort()?[...s,r]:s).forEach((e,t)=>{e.setSortIndex(t)})}onSortChanged(e,t){this.dispatchSortChangedEvents(e,t)}isSortActive(){const e=this.columnModel.getPrimaryAndSecondaryAndAutoColumns().filter(e=>!!e.getSort());return e&&e.length>0}dispatchSortChangedEvents(e,t){const i={type:ct.EVENT_SORT_CHANGED,source:e};t&&(i.columns=t),this.eventService.dispatchEvent(i)}clearSortBarTheseColumns(e,t){const i=[];return this.columnModel.getPrimaryAndSecondaryAndAutoColumns().forEach(r=>{e.includes(r)||(r.getSort()&&i.push(r),r.setSort(void 0,t))}),i}getNextSortDirection(e){let t;if(t=e.getColDef().sortingOrder?e.getColDef().sortingOrder:this.gos.get("sortingOrder")?this.gos.get("sortingOrder"):Oc.DEFAULT_SORTING_ORDER,!Array.isArray(t)||t.length<=0)return console.warn(`AG Grid: sortingOrder must be an array with at least one element, currently it's ${t}`),null;const i=t.indexOf(e.getSort()),r=i<0,n=i==t.length-1;let s;return s=r||n?t[0]:t[i+1],Oc.DEFAULT_SORTING_ORDER.indexOf(s)<0?(console.warn("AG Grid: invalid sort type "+s),null):s}getIndexedSortMap(){let e=this.columnModel.getPrimaryAndSecondaryAndAutoColumns().filter(e=>!!e.getSort());if(this.columnModel.isPivotMode()){const t=this.gos.isColumnsSortingCoupledToGroup();e=e.filter(e=>{const i=!!e.getAggFunc(),r=!e.isPrimary(),n=t?this.columnModel.getGroupDisplayColumnForGroup(e.getId()):e.getColDef().showRowGroup;return i||r||n})}const t=this.columnModel.getRowGroupColumns().filter(e=>!!e.getSort()),i={};e.forEach((e,t)=>i[e.getId()]=t),e.sort((e,t)=>{const r=e.getSortIndex(),n=t.getSortIndex();return null!=r&&null!=n?r-n:null==r&&null==n?i[e.getId()]>i[t.getId()]?1:-1:null==n?-1:1});const r=this.gos.isColumnsSortingCoupledToGroup()&&!!t.length;r&&(e=[...new Set(e.map(e=>{var t;return null!=(t=this.columnModel.getGroupDisplayColumnForGroup(e.getId()))?t:e}))]);const n=new Map;return e.forEach((e,t)=>n.set(e,t)),r&&t.forEach(e=>{const t=this.columnModel.getGroupDisplayColumnForGroup(e.getId());n.set(e,n.get(t))}),n}getColumnsWithSortingOrdered(){return[...this.getIndexedSortMap().entries()].sort(([e,t],[i,r])=>t-r).map(([e])=>e)}getSortModel(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),colId:e.getId()}))}getSortOptions(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),column:e}))}canColumnDisplayMixedSort(e){const t=this.gos.isColumnsSortingCoupledToGroup(),i=!!e.getColDef().showRowGroup;return t&&i}getDisplaySortForColumn(e){const t=this.columnModel.getSourceColumnsForGroupColumn(e);if(!this.canColumnDisplayMixedSort(e)||!(null==t?void 0:t.length))return e.getSort();const i=null!=e.getColDef().field||e.getColDef().valueGetter?[e,...t]:t,r=i[0].getSort();return i.every(e=>e.getSort()==r)?r:"mixed"}getDisplaySortIndexForColumn(e){return this.getIndexedSortMap().get(e)}};Oc.DEFAULT_SORTING_ORDER=["asc","desc",null],g([he("columnModel")],Oc.prototype,"columnModel",2),Oc=g([ue("sortController")],Oc);var Fc=class extends nt{static addKeyboardModeEvents(e){this.instanceCount>0||(e.addEventListener("keydown",Fc.toggleKeyboardMode),e.addEventListener("mousedown",Fc.toggleKeyboardMode))}static removeKeyboardModeEvents(e){this.instanceCount>0||(e.addEventListener("keydown",Fc.toggleKeyboardMode),e.addEventListener("mousedown",Fc.toggleKeyboardMode))}static toggleKeyboardMode(e){const t=Fc.keyboardModeActive,i="keydown"===e.type;i&&(e.ctrlKey||e.metaKey||e.altKey)||t!==i&&(Fc.keyboardModeActive=i)}static unregisterGridCompController(e){Fc.removeKeyboardModeEvents(e)}init(){const e=this.clearFocusedCell.bind(this);this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverythingChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_GROUP_OPENED,e),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.registerKeyboardFocusEvents(),this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl})}registerKeyboardFocusEvents(){const e=this.gos.getDocument();Fc.addKeyboardModeEvents(e),Fc.instanceCount++,this.addDestroyFunc(()=>{Fc.instanceCount--,Fc.unregisterGridCompController(e)})}onColumnEverythingChanged(){if(!this.focusedCellPosition)return;const e=this.focusedCellPosition.column,t=this.columnModel.getGridColumn(e.getId());e!==t&&this.clearFocusedCell()}isKeyboardMode(){return Fc.keyboardModeActive}getFocusCellToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedCellPosition||this.isDomDataMissingInHierarchy(this.gos.getActiveDomElement(),Ca.DOM_DATA_KEY_ROW_CTRL)?null:this.focusedCellPosition}getFocusHeaderToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedHeaderPosition||this.isDomDataMissingInHierarchy(this.gos.getActiveDomElement(),el.DOM_DATA_KEY_HEADER_CTRL)?null:this.focusedHeaderPosition}isDomDataMissingInHierarchy(e,t){let i=e;for(;i;){if(this.gos.getDomData(i,t))return!1;i=i.parentNode}return!0}getFocusedCell(){return this.focusedCellPosition}shouldRestoreFocus(e){return!!this.isCellRestoreFocused(e)&&(setTimeout(()=>{this.restoredFocusedCellPosition=null},0),!0)}isCellRestoreFocused(e){return null!=this.restoredFocusedCellPosition&&this.cellPositionUtils.equals(e,this.restoredFocusedCellPosition)}setRestoreFocusedCell(e){"react"===this.getFrameworkOverrides().renderingEngine&&(this.restoredFocusedCellPosition=e)}getFocusEventParams(){const{rowIndex:e,rowPinned:t,column:i}=this.focusedCellPosition,r={rowIndex:e,rowPinned:t,column:i,isFullWidthCell:!1},n=this.rowRenderer.getRowByPosition({rowIndex:e,rowPinned:t});return n&&(r.isFullWidthCell=n.isFullWidth()),r}clearFocusedCell(){if(this.restoredFocusedCellPosition=null,null==this.focusedCellPosition)return;const e=h({type:ct.EVENT_CELL_FOCUS_CLEARED},this.getFocusEventParams());this.focusedCellPosition=null,this.eventService.dispatchEvent(e)}setFocusedCell(e){const{column:t,rowIndex:i,rowPinned:r,forceBrowserFocus:n=!1,preventScrollOnBrowserFocus:s=!1}=e,o=this.columnModel.getGridColumn(t);if(!o)return void(this.focusedCellPosition=null);this.focusedCellPosition=o?{rowIndex:i,rowPinned:C(r),column:o}:null;const a=d(h({type:ct.EVENT_CELL_FOCUSED},this.getFocusEventParams()),{forceBrowserFocus:n,preventScrollOnBrowserFocus:s,floating:null});this.eventService.dispatchEvent(a)}isCellFocused(e){return null!=this.focusedCellPosition&&this.cellPositionUtils.equals(e,this.focusedCellPosition)}isRowNodeFocused(e){return this.isRowFocused(e.rowIndex,e.rowPinned)}isHeaderWrapperFocused(e){if(null==this.focusedHeaderPosition)return!1;const t=e.getColumnGroupChild(),i=e.getRowIndex(),r=e.getPinned(),{column:n,headerRowIndex:s}=this.focusedHeaderPosition;return t===n&&i===s&&r==n.getPinned()}clearFocusedHeader(){this.focusedHeaderPosition=null}getFocusedHeader(){return this.focusedHeaderPosition}setFocusedHeader(e,t){this.focusedHeaderPosition={headerRowIndex:e,column:t}}focusHeaderPosition(e){if(this.gos.get("suppressHeaderFocus"))return!1;const{direction:t,fromTab:i,allowUserOverride:r,event:n,fromCell:s,rowWithoutSpanValue:o}=e;let{headerPosition:a}=e;if(s&&this.filterManager.isAdvancedFilterHeaderActive())return this.focusAdvancedFilter(a);if(r){const e=this.getFocusedHeader(),r=this.headerNavigationService.getHeaderRowCount();if(i){const i=this.gos.getCallback("tabToNextHeader");i&&(a=this.getHeaderPositionFromUserFunc({userFunc:i,direction:t,currentPosition:e,headerPosition:a,headerRowCount:r}))}else{const t=this.gos.getCallback("navigateToNextHeader");t&&n&&(a=t({key:n.key,previousHeaderPosition:e,nextHeaderPosition:a,headerRowCount:r,event:n}))}}return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:t,event:n,fromCell:s,rowWithoutSpanValue:o})}focusHeaderPositionFromUserFunc(e){if(this.gos.get("suppressHeaderFocus"))return!1;const{userFunc:t,headerPosition:i,direction:r,event:n}=e,s=this.getFocusedHeader(),o=this.headerNavigationService.getHeaderRowCount(),a=this.getHeaderPositionFromUserFunc({userFunc:t,direction:r,currentPosition:s,headerPosition:i,headerRowCount:o});return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:r,event:n})}getHeaderPositionFromUserFunc(e){const{userFunc:t,direction:i,currentPosition:r,headerPosition:n,headerRowCount:s}=e,o=t({backwards:"Before"===i,previousHeaderPosition:r,nextHeaderPosition:n,headerRowCount:s});return!0===o||null===o?(null===o&&U("Returning `null` from tabToNextHeader is deprecated. Return `true` to stay on the current header, or `false` to let the browser handle the tab behaviour."),r):!1===o?null:o}focusProvidedHeaderPosition(e){const{headerPosition:t,direction:i,fromCell:r,rowWithoutSpanValue:n,event:s}=e;if(-1===t.headerRowIndex)return this.filterManager.isAdvancedFilterHeaderActive()?this.focusAdvancedFilter(t):this.focusGridView(t.column);this.headerNavigationService.scrollToColumn(t.column,i);const o=this.ctrlsService.getHeaderRowContainerCtrl(t.column.getPinned()).focusHeader(t.headerRowIndex,t.column,s);return o&&(null!=n||r)&&this.headerNavigationService.setCurrentHeaderRowWithoutSpan(null!=n?n:-1),o}focusFirstHeader(){let e=this.columnModel.getAllDisplayedColumns()[0];if(!e)return!1;e.getParent()&&(e=this.columnModel.getColumnGroupAtLevel(e,0));const t=this.headerPositionUtils.getHeaderIndexToFocus(e,0);return this.focusHeaderPosition({headerPosition:t,rowWithoutSpanValue:0})}focusLastHeader(e){const t=this.headerNavigationService.getHeaderRowCount()-1,i=Pe(this.columnModel.getAllDisplayedColumns());return this.focusHeaderPosition({headerPosition:{headerRowIndex:t,column:i},rowWithoutSpanValue:-1,event:e})}focusPreviousFromFirstCell(e){return this.filterManager.isAdvancedFilterHeaderActive()?this.focusAdvancedFilter(null):this.focusLastHeader(e)}isAnyCellFocused(){return!!this.focusedCellPosition}isRowFocused(e,t){return null!=this.focusedCellPosition&&this.focusedCellPosition.rowIndex===e&&this.focusedCellPosition.rowPinned===C(t)}findFocusableElements(e,t,i=!1){const r=rr;let n=nr;t&&(n+=", "+t),i&&(n+=', [tabindex="-1"]');const s=Array.prototype.slice.apply(e.querySelectorAll(r)).filter(e=>br(e)),o=Array.prototype.slice.apply(e.querySelectorAll(n));return o.length?(a=o,s.filter(e=>-1===a.indexOf(e))):s;var a}focusInto(e,t=!1,i=!1){const r=this.findFocusableElements(e,null,i),n=t?Pe(r):r[0];return!!n&&(n.focus({preventScroll:!0}),!0)}findFocusableElementBeforeTabGuard(e,t){if(!t)return null;const i=this.findFocusableElements(e),r=i.indexOf(t);if(-1===r)return null;let n=-1;for(let e=r-1;e>=0;e--)if(i[e].classList.contains("ag-tab-guard-top")){n=e;break}return n<=0?null:i[n-1]}findNextFocusableElement(e=this.eGridDiv,t,i){const r=this.findFocusableElements(e,t?':not([tabindex="-1"])':null),n=this.gos.getActiveDomElement();let s;s=t?r.findIndex(e=>e.contains(n)):r.indexOf(n);const o=s+(i?-1:1);return o<0||o>=r.length?null:r[o]}isTargetUnderManagedComponent(e,t){if(!t)return!1;const i=e.querySelectorAll(`.${Pn.FOCUS_MANAGED_CLASS}`);if(!i.length)return!1;for(let e=0;e<i.length;e++)if(i[e].contains(t))return!0;return!1}findTabbableParent(e,t=5){let i=0;for(;e&&null===Ni(e)&&++i<=t;)e=e.parentElement;return null===Ni(e)?null:e}focusGridView(e,t){var i;if(this.gos.get("suppressCellFocus"))return t?this.gos.get("suppressHeaderFocus")?this.focusNextGridCoreContainer(!0,!0):this.focusLastHeader():this.focusNextGridCoreContainer(!1);const r=t?this.rowPositionUtils.getLastRow():this.rowPositionUtils.getFirstRow();if(!r)return!1;const{rowIndex:n,rowPinned:s}=r,o=this.getFocusedHeader();return!e&&o&&(e=o.column),!(null==n||!e||(this.navigationService.ensureCellVisible({rowIndex:n,column:e,rowPinned:s}),this.setFocusedCell({rowIndex:n,column:e,rowPinned:C(s),forceBrowserFocus:!0}),null==(i=this.rangeService)||i.setRangeToCell({rowIndex:n,rowPinned:s,column:e}),0))}focusNextGridCoreContainer(e,t=!1){return!(t||!this.gridCtrl.focusNextInnerContainer(e))||((t||!e&&!this.gridCtrl.isDetailGrid())&&this.gridCtrl.forceFocusOutOfContainer(e),!1)}focusAdvancedFilter(e){var t,i;return this.advancedFilterFocusColumn=null==e?void 0:e.column,null!=(i=null==(t=this.advancedFilterService)?void 0:t.getCtrl().focusHeaderComp())&&i}focusNextFromAdvancedFilter(e,t){var i,r;const n=null!=(r=t?void 0:this.advancedFilterFocusColumn)?r:null==(i=this.columnModel.getAllDisplayedColumns())?void 0:i[0];return e?this.focusHeaderPosition({headerPosition:{column:n,headerRowIndex:this.headerNavigationService.getHeaderRowCount()-1}}):this.focusGridView(n)}clearAdvancedFilterColumn(){this.advancedFilterFocusColumn=void 0}};Fc.keyboardModeActive=!1,Fc.instanceCount=0,g([he("eGridDiv")],Fc.prototype,"eGridDiv",2),g([he("columnModel")],Fc.prototype,"columnModel",2),g([he("headerNavigationService")],Fc.prototype,"headerNavigationService",2),g([he("headerPositionUtils")],Fc.prototype,"headerPositionUtils",2),g([he("rowRenderer")],Fc.prototype,"rowRenderer",2),g([he("rowPositionUtils")],Fc.prototype,"rowPositionUtils",2),g([he("cellPositionUtils")],Fc.prototype,"cellPositionUtils",2),g([he("navigationService")],Fc.prototype,"navigationService",2),g([he("ctrlsService")],Fc.prototype,"ctrlsService",2),g([he("filterManager")],Fc.prototype,"filterManager",2),g([de("rangeService")],Fc.prototype,"rangeService",2),g([de("advancedFilterService")],Fc.prototype,"advancedFilterService",2),g([le],Fc.prototype,"init",1),Fc=g([ue("focusService")],Fc);var kc=class extends nt{setMouseOver(e){this.selectedColumns=e;const t={type:ct.EVENT_COLUMN_HOVER_CHANGED};this.eventService.dispatchEvent(t)}clearMouseOver(){this.selectedColumns=null;const e={type:ct.EVENT_COLUMN_HOVER_CHANGED};this.eventService.dispatchEvent(e)}isHovered(e){return!!this.selectedColumns&&this.selectedColumns.indexOf(e)>=0}};kc=g([ue("columnHoverService")],kc);var Gc=class extends nt{constructor(){super(...arguments),this.executeNextFuncs=[],this.executeLaterFuncs=[],this.active=!1,this.suppressAnimation=!1,this.animationThreadCount=0}postConstruct(){this.ctrlsService.whenReady(e=>this.gridBodyCtrl=e.gridBodyCtrl)}isActive(){return this.active&&!this.suppressAnimation}setSuppressAnimation(e){this.suppressAnimation=e}start(){this.active||this.gos.get("suppressColumnMoveAnimation")||this.gos.get("enableRtl")||(this.ensureAnimationCssClassPresent(),this.active=!0)}finish(){this.active&&this.flush(()=>{this.active=!1})}executeNextVMTurn(e){this.active?this.executeNextFuncs.push(e):e()}executeLaterVMTurn(e){this.active?this.executeLaterFuncs.push(e):e()}ensureAnimationCssClassPresent(){this.animationThreadCount++;const e=this.animationThreadCount;this.gridBodyCtrl.setColumnMovingCss(!0),this.executeLaterFuncs.push(()=>{this.animationThreadCount===e&&this.gridBodyCtrl.setColumnMovingCss(!1)})}flush(e){if(0===this.executeNextFuncs.length&&0===this.executeLaterFuncs.length)return void e();const t=e=>{for(;e.length;){const t=e.pop();t&&t()}};this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>t(this.executeNextFuncs),0),window.setTimeout(()=>{e(),t(this.executeLaterFuncs)},200)})}};g([he("ctrlsService")],Gc.prototype,"ctrlsService",2),g([le],Gc.prototype,"postConstruct",1),Gc=g([ue("columnAnimationService")],Gc);var Vc=class extends nt{postConstruct(){this.ctrlsService.whenReady(e=>{this.centerRowsCtrl=e.center,this.addManagedListener(this.eventService,ct.EVENT_BODY_HEIGHT_CHANGED,this.checkPageSize.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_SCROLL_VISIBILITY_CHANGED,this.checkPageSize.bind(this)),this.addManagedPropertyListener("paginationAutoPageSize",this.onPaginationAutoSizeChanged.bind(this)),this.checkPageSize()})}notActive(){return!this.gos.get("paginationAutoPageSize")||null==this.centerRowsCtrl}onPaginationAutoSizeChanged(){this.notActive()?this.paginationProxy.unsetAutoCalculatedPageSize():this.checkPageSize()}checkPageSize(){if(this.notActive())return;const e=this.centerRowsCtrl.getViewportSizeFeature().getBodyHeight();if(e>0){const t=()=>{const t=this.gos.getRowHeightAsNumber(),i=Math.floor(e/t);this.paginationProxy.setPageSize(i,"autoCalculated")};this.isBodyRendered?Z(()=>t(),50)():(t(),this.isBodyRendered=!0)}else this.isBodyRendered=!1}};g([he("ctrlsService")],Vc.prototype,"ctrlsService",2),g([he("paginationProxy")],Vc.prototype,"paginationProxy",2),g([le],Vc.prototype,"postConstruct",1),Vc=g([ue("paginationAutoPageSizeService")],Vc);var Hc=class extends nt{constructor(){super(...arguments),this.cacheVersion=0}init(){this.active=this.gos.get("valueCache"),this.neverExpires=this.gos.get("valueCacheNeverExpires")}onDataChanged(){this.neverExpires||this.expire()}expire(){this.cacheVersion++}setValue(e,t,i){this.active&&(e.__cacheVersion!==this.cacheVersion&&(e.__cacheVersion=this.cacheVersion,e.__cacheData={}),e.__cacheData[t]=i)}getValue(e,t){if(this.active&&e.__cacheVersion===this.cacheVersion)return e.__cacheData[t]}};g([le],Hc.prototype,"init",1),Hc=g([ue("valueCache")],Hc);var Bc=class extends nt{init(){"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel),this.addManagedListener(this.eventService,ct.EVENT_CELL_VALUE_CHANGED,this.onCellValueChanged.bind(this))}onCellValueChanged(e){"paste"!==e.source&&this.doChangeDetection(e.node,e.column)}doChangeDetection(e,t){if(this.gos.get("suppressChangeDetection"))return;const i=[e];if(this.clientSideRowModel&&!e.isRowPinned()){const r=this.gos.get("aggregateOnlyChangedColumns"),n=new Gl(r,this.clientSideRowModel.getRootNode());n.addParentNode(e.parent,[t]),this.clientSideRowModel.doAggregate(n),n.forEachChangedNodeDepthFirst(e=>{i.push(e)})}this.rowRenderer.refreshCells({rowNodes:i})}};g([he("rowModel")],Bc.prototype,"rowModel",2),g([he("rowRenderer")],Bc.prototype,"rowRenderer",2),g([le],Bc.prototype,"init",1),Bc=g([ue("changeDetectionService")],Bc);var zc=class extends nt{adaptFunction(e,t){const i=this.componentMetadataProvider.retrieve(e);return i&&i.functionAdapter?i.functionAdapter(t):null}adaptCellRendererFunction(e){return class{refresh(e){return!1}getGui(){return this.eGui}init(t){const i=e(t),r=typeof i;this.eGui="string"!==r&&"number"!==r&&"boolean"!==r?null!=i?i:Er("<span></span>"):Er("<span>"+i+"</span>")}}}doesImplementIComponent(e){return!!e&&e.prototype&&"getGui"in e.prototype}};g([he("componentMetadataProvider")],zc.prototype,"componentMetadataProvider",2),zc=g([ue("agComponentUtils")],zc);var Uc=class extends nt{postConstruct(){this.componentMetaData={dateComponent:{mandatoryMethodList:["getDate","setDate"],optionalMethodList:["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled","onParamsUpdated","refresh"]},detailCellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},headerComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},headerGroupComponent:{mandatoryMethodList:[],optionalMethodList:[]},loadingCellRenderer:{mandatoryMethodList:[],optionalMethodList:[],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},loadingOverlayComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},noRowsOverlayComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},floatingFilterComponent:{mandatoryMethodList:["onParentModelChanged"],optionalMethodList:["afterGuiAttached","onParamsUpdated","refresh"]},cellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh","afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},cellEditor:{mandatoryMethodList:["getValue"],optionalMethodList:["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached","refresh"]},innerRenderer:{mandatoryMethodList:[],optionalMethodList:["afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},fullWidthCellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh","afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},groupRowRenderer:{mandatoryMethodList:[],optionalMethodList:["afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},filter:{mandatoryMethodList:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethodList:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},statusPanel:{mandatoryMethodList:[],optionalMethodList:["refresh"]},toolPanel:{mandatoryMethodList:[],optionalMethodList:["refresh","getState"]},tooltipComponent:{mandatoryMethodList:[],optionalMethodList:[]},menuItem:{mandatoryMethodList:[],optionalMethodList:["setActive","select","setExpanded","configureDefaults"]}}}retrieve(e){return this.componentMetaData[e]}};g([he("agComponentUtils")],Uc.prototype,"agComponentUtils",2),g([le],Uc.prototype,"postConstruct",1),Uc=g([ue("componentMetadataProvider")],Uc);var Wc={"ag-theme-custom":{headerHeight:25,headerCellMinWidth:24,listItemHeight:20,rowHeight:25,chartMenuPanelWidth:220},"ag-theme-material":{headerHeight:56,headerCellMinWidth:48,listItemHeight:32,rowHeight:48,chartMenuPanelWidth:240},"ag-theme-balham":{headerHeight:32,headerCellMinWidth:24,listItemHeight:24,rowHeight:28,chartMenuPanelWidth:220},"ag-theme-alpine":{headerHeight:48,headerCellMinWidth:36,listItemHeight:24,rowHeight:42,chartMenuPanelWidth:240},"ag-theme-quartz":{headerHeight:48,headerCellMinWidth:36,listItemHeight:24,rowHeight:42,chartMenuPanelWidth:260}},jc={headerHeight:["ag-header-row"],headerCellMinWidth:["ag-header-cell"],listItemHeight:["ag-virtual-list-item"],rowHeight:["ag-row"],chartMenuPanelWidth:["ag-chart-docked-container"]},Kc=class extends nt{constructor(){super(...arguments),this.calculatedSizes={},this.calculatedTheme=null}postConstruct(){var e;const t=null!=(e=this.getTheme().el)?e:this.eGridDiv;this.addManagedPropertyListener("rowHeight",()=>this.refreshRowHeightVariable()),this.mutationObserver=new MutationObserver(()=>{this.calculatedSizes={},this.calculatedTheme=null,this.calculatedTheme=this.getTheme(),this.fireGridStylesChangedEvent()}),this.mutationObserver.observe(t||this.eGridDiv,{attributes:!0,attributeFilter:["class"]})}fireGridStylesChangedEvent(){const e={type:ct.EVENT_GRID_STYLES_CHANGED};this.eventService.dispatchEvent(e)}getSassVariable(e){const{themeFamily:t,el:i}=this.getTheme();if(!t||0!==t.indexOf("ag-theme"))return;this.calculatedSizes||(this.calculatedSizes={}),this.calculatedSizes[t]||(this.calculatedSizes[t]={});const r=this.calculatedSizes[t][e];return null!=r?r:(this.calculatedSizes[t][e]=this.calculateValueForSassProperty(e,t,i),this.calculatedSizes[t][e])}calculateValueForSassProperty(e,t,i){const r="ag-theme-"+(t.match("material")?"material":t.match("balham")?"balham":t.match("alpine")?"alpine":"custom"),n=Wc[r][e],s=this.gos.getDocument();if(i||(i=this.eGridDiv),!jc[e])return n;const o=jc[e],a=s.createElement("div"),l=Array.from(i.classList);a.classList.add(t,...l),a.style.position="absolute";const c=o.reduce((e,t)=>{const i=s.createElement("div");return i.style.position="static",i.classList.add(t),e.appendChild(i),i},a);let u=0;if(s.body){s.body.appendChild(a);const t=-1!==e.toLowerCase().indexOf("height")?"height":"width";u=parseInt(window.getComputedStyle(c)[t],10),s.body.removeChild(a)}return u||n}isThemeDark(){const{theme:e}=this.getTheme();return!!e&&e.indexOf("dark")>=0}chartMenuPanelWidth(){return this.getSassVariable("chartMenuPanelWidth")}getTheme(){if(this.calculatedTheme)return this.calculatedTheme;const e=/\bag-(material|(?:theme-([\w\-]*)))\b/g;let t=this.eGridDiv,i=null,r=[];for(;t;){if(i=e.exec(t.className),i){const i=t.className.match(e);i&&(r=i);break}t=t.parentElement||void 0}if(!i)return{allThemes:r};const n=i[0];return this.calculatedTheme={theme:n,el:t,themeFamily:n.replace(/-dark$/,""),allThemes:r},this.calculatedTheme}getFromTheme(e,t){var i;return null!=(i=this.getSassVariable(t))?i:e}getDefaultRowHeight(){return this.getFromTheme(25,"rowHeight")}getListItemHeight(){return this.getFromTheme(20,"listItemHeight")}refreshRowHeightVariable(){const e=this.eGridDiv.style.getPropertyValue("--ag-line-height").trim(),t=this.gos.get("rowHeight");if(null==t||isNaN(t)||!isFinite(t))return null!==e&&this.eGridDiv.style.setProperty("--ag-line-height",null),-1;const i=`${t}px`;return e!=i?(this.eGridDiv.style.setProperty("--ag-line-height",i),t):""!=e?parseFloat(e):-1}getMinColWidth(){const e=this.getFromTheme(null,"headerCellMinWidth");return y(e)?Math.max(e,10):10}destroy(){this.calculatedSizes=null,this.mutationObserver&&this.mutationObserver.disconnect(),super.destroy()}};g([he("eGridDiv")],Kc.prototype,"eGridDiv",2),g([le],Kc.prototype,"postConstruct",1),Kc=g([ue("environment")],Kc);var $c=class extends nt{constructor(){super(...arguments),this.scrollY=0,this.uiBodyHeight=0}agWire(e){this.logger=e.create("RowContainerHeightService")}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_BODY_HEIGHT_CHANGED,this.updateOffset.bind(this)),this.maxDivHeight=Oi(),this.logger.log("maxDivHeight = "+this.maxDivHeight)}isStretching(){return this.stretching}getDivStretchOffset(){return this.divStretchOffset}updateOffset(){if(!this.stretching)return;const e=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition().top,t=this.getUiBodyHeight();(e!==this.scrollY||t!==this.uiBodyHeight)&&(this.scrollY=e,this.uiBodyHeight=t,this.calculateOffset())}calculateOffset(){this.setUiContainerHeight(this.maxDivHeight),this.pixelsToShave=this.modelHeight-this.uiContainerHeight,this.maxScrollY=this.uiContainerHeight-this.uiBodyHeight;const e=this.scrollY/this.maxScrollY,t=e*this.pixelsToShave;this.logger.log(`Div Stretch Offset = ${t} (${this.pixelsToShave} * ${e})`),this.setDivStretchOffset(t)}setUiContainerHeight(e){e!==this.uiContainerHeight&&(this.uiContainerHeight=e,this.eventService.dispatchEvent({type:ct.EVENT_ROW_CONTAINER_HEIGHT_CHANGED}))}clearOffset(){this.setUiContainerHeight(this.modelHeight),this.pixelsToShave=0,this.setDivStretchOffset(0)}setDivStretchOffset(e){const t="number"==typeof e?Math.floor(e):null;this.divStretchOffset!==t&&(this.divStretchOffset=t,this.eventService.dispatchEvent({type:ct.EVENT_HEIGHT_SCALE_CHANGED}))}setModelHeight(e){this.modelHeight=e,this.stretching=null!=e&&this.maxDivHeight>0&&e>this.maxDivHeight,this.stretching?this.calculateOffset():this.clearOffset()}getUiContainerHeight(){return this.uiContainerHeight}getRealPixelPosition(e){return e-this.divStretchOffset}getUiBodyHeight(){const e=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition();return e.bottom-e.top}getScrollPositionForPixel(e){if(this.pixelsToShave<=0)return e;const t=e/(this.modelHeight-this.getUiBodyHeight());return this.maxScrollY*t}};g([he("ctrlsService")],$c.prototype,"ctrlsService",2),g([f(0,ge("loggerFactory"))],$c.prototype,"agWire",1),g([le],$c.prototype,"postConstruct",1),$c=g([ue("rowContainerHeightService")],$c);var qc=class extends nt{init(){this.addManagedPropertyListener("isRowSelectable",()=>this.updateSelectable())}updateSelectableAfterGrouping(){this.updateSelectable(!0)}updateSelectable(e=!1){const t=!!this.gos.get("rowSelection"),i=this.gos.get("isRowSelectable");if(!t||!i)return;const r=this.gos.get("groupSelectsChildren"),n="clientSide"===this.rowModel.getType()&&r,s=[],o=t=>{if(e&&!t.group)return;if(n&&t.group){const e=t.childrenAfterGroup.some(e=>!0===e.selectable);return void t.setRowSelectable(e,!0)}const r=!i||i(t);t.setRowSelectable(r,!0),!r&&t.isSelected()&&s.push(t)};if(n){const e=this.rowModel;new Gl(!1,e.getRootNode()).forEachChangedNodeDepthFirst(o,!0,!0)}else this.rowModel.forEachNode(o);s.length&&this.selectionService.setNodesSelected({nodes:s,newValue:!1,source:"selectableChanged"}),n&&this.selectionService instanceof Rc&&this.selectionService.updateGroupsFromChildrenSelections("selectableChanged")}};g([he("rowModel")],qc.prototype,"rowModel",2),g([he("selectionService")],qc.prototype,"selectionService",2),g([le],qc.prototype,"init",1),qc=g([ue("selectableService")],qc);var Yc=class extends wn{constructor(){super(),this.previousAndFirstButtonsDisabled=!1,this.nextButtonDisabled=!1,this.lastButtonDisabled=!1,this.areListenersSetup=!1}postConstruct(){const e=this.gos.get("enableRtl");this.setTemplate(this.getTemplate());const{btFirst:t,btPrevious:i,btNext:r,btLast:n,pageSizeComp:s}=this;this.activateTabIndex([t,i,r,n]),t.insertAdjacentElement("afterbegin",qr(e?"last":"first",this.gos)),i.insertAdjacentElement("afterbegin",qr(e?"next":"previous",this.gos)),r.insertAdjacentElement("afterbegin",qr(e?"previous":"next",this.gos)),n.insertAdjacentElement("afterbegin",qr(e?"first":"last",this.gos)),this.addManagedPropertyListener("pagination",this.onPaginationChanged.bind(this)),this.addManagedPropertyListener("suppressPaginationPanel",this.onPaginationChanged.bind(this)),this.addManagedPropertyListeners(["paginationPageSizeSelector","paginationAutoPageSize","suppressPaginationPanel"],()=>this.onPageSizeRelatedOptionsChange()),this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector()),this.onPaginationChanged()}onPaginationChanged(){const e=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel");this.setDisplayed(e),e&&(this.setupListeners(),this.enableOrDisableButtons(),this.updateRowLabels(),this.setCurrentPageLabel(),this.setTotalLabels(),this.onPageSizeRelatedOptionsChange())}onPageSizeRelatedOptionsChange(){this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector())}setupListeners(){this.areListenersSetup||(this.addManagedListener(this.eventService,ct.EVENT_PAGINATION_CHANGED,this.onPaginationChanged.bind(this)),[{el:this.btFirst,fn:this.onBtFirst.bind(this)},{el:this.btPrevious,fn:this.onBtPrevious.bind(this)},{el:this.btNext,fn:this.onBtNext.bind(this)},{el:this.btLast,fn:this.onBtLast.bind(this)}].forEach(e=>{const{el:t,fn:i}=e;this.addManagedListener(t,"click",i),this.addManagedListener(t,"keydown",e=>{e.key!==Qr.ENTER&&e.key!==Qr.SPACE||(e.preventDefault(),i())})}),this.areListenersSetup=!0)}onBtFirst(){this.previousAndFirstButtonsDisabled||this.paginationProxy.goToFirstPage()}setCurrentPageLabel(){const e=this.paginationProxy.getTotalPages()>0,t=this.paginationProxy.getCurrentPage(),i=e?t+1:0;this.lbCurrent.textContent=this.formatNumber(i)}formatNumber(e){const t=this.gos.getCallback("paginationNumberFormatter");if(t)return t({value:e});const i=this.localeService.getLocaleTextFunc();return qi(e,i("thousandSeparator",","),i("decimalSeparator","."))}getTemplate(){const e=this.localeService.getLocaleTextFunc(),t=e("page","Page"),i=e("to","to"),r=e("of","of"),n=e("firstPage","First Page"),s=e("previousPage","Previous Page"),o=e("nextPage","Next Page"),a=e("lastPage","Last Page"),l=this.getCompId();return`<div class="ag-paging-panel ag-unselectable" id="ag-${l}">\n                <ag-page-size-selector ref="pageSizeComp"></ag-page-size-selector>\n                <span class="ag-paging-row-summary-panel" role="status">\n                    <span id="ag-${l}-first-row" ref="lbFirstRowOnPage" class="ag-paging-row-summary-panel-number"></span>\n                    <span id="ag-${l}-to">${i}</span>\n                    <span id="ag-${l}-last-row" ref="lbLastRowOnPage" class="ag-paging-row-summary-panel-number"></span>\n                    <span id="ag-${l}-of">${r}</span>\n                    <span id="ag-${l}-row-count" ref="lbRecordCount" class="ag-paging-row-summary-panel-number"></span>\n                </span>\n                <span class="ag-paging-page-summary-panel" role="presentation">\n                    <div ref="btFirst" class="ag-button ag-paging-button" role="button" aria-label="${n}"></div>\n                    <div ref="btPrevious" class="ag-button ag-paging-button" role="button" aria-label="${s}"></div>\n                    <span class="ag-paging-description" role="status">\n                        <span id="ag-${l}-start-page">${t}</span>\n                        <span id="ag-${l}-start-page-number" ref="lbCurrent" class="ag-paging-number"></span>\n                        <span id="ag-${l}-of-page">${r}</span>\n                        <span id="ag-${l}-of-page-number" ref="lbTotal" class="ag-paging-number"></span>\n                    </span>\n                    <div ref="btNext" class="ag-button ag-paging-button" role="button" aria-label="${o}"></div>\n                    <div ref="btLast" class="ag-button ag-paging-button" role="button" aria-label="${a}"></div>\n                </span>\n            </div>`}onBtNext(){this.nextButtonDisabled||this.paginationProxy.goToNextPage()}onBtPrevious(){this.previousAndFirstButtonsDisabled||this.paginationProxy.goToPreviousPage()}onBtLast(){this.lastButtonDisabled||this.paginationProxy.goToLastPage()}enableOrDisableButtons(){const e=this.paginationProxy.getCurrentPage(),t=this.paginationProxy.isLastPageFound(),i=this.paginationProxy.getTotalPages();this.previousAndFirstButtonsDisabled=0===e,this.toggleButtonDisabled(this.btFirst,this.previousAndFirstButtonsDisabled),this.toggleButtonDisabled(this.btPrevious,this.previousAndFirstButtonsDisabled);const r=this.isZeroPagesToDisplay(),n=e===i-1;this.nextButtonDisabled=n||r,this.lastButtonDisabled=!t||r||e===i-1,this.toggleButtonDisabled(this.btNext,this.nextButtonDisabled),this.toggleButtonDisabled(this.btLast,this.lastButtonDisabled)}toggleButtonDisabled(e,t){Jt(e,t),e.classList.toggle("ag-disabled",t)}updateRowLabels(){const e=this.paginationProxy.getCurrentPage(),t=this.paginationProxy.getPageSize(),i=this.paginationProxy.isLastPageFound(),r=this.paginationProxy.isLastPageFound()?this.paginationProxy.getMasterRowCount():null;let n,s;if(this.isZeroPagesToDisplay()?n=s=0:(n=t*e+1,s=n+t-1,i&&s>r&&(s=r)),this.lbFirstRowOnPage.textContent=this.formatNumber(n),this.rowNodeBlockLoader.isLoading()){const e=this.localeService.getLocaleTextFunc();this.lbLastRowOnPage.innerHTML=e("pageLastRowUnknown","?")}else this.lbLastRowOnPage.textContent=this.formatNumber(s)}isZeroPagesToDisplay(){const e=this.paginationProxy.isLastPageFound(),t=this.paginationProxy.getTotalPages();return e&&0===t}setTotalLabels(){const e=this.paginationProxy.isLastPageFound(),t=this.paginationProxy.getTotalPages(),i=e?this.paginationProxy.getMasterRowCount():null;if(1===i){const e=this.paginationProxy.getRow(0);if(e&&e.group&&!e.groupData&&!e.aggData)return void this.setTotalLabelsToZero()}if(e)this.lbTotal.textContent=this.formatNumber(t),this.lbRecordCount.textContent=this.formatNumber(i);else{const e=this.localeService.getLocaleTextFunc()("more","more");this.lbTotal.innerHTML=e,this.lbRecordCount.innerHTML=e}}setTotalLabelsToZero(){this.lbFirstRowOnPage.textContent=this.formatNumber(0),this.lbCurrent.textContent=this.formatNumber(0),this.lbLastRowOnPage.textContent=this.formatNumber(0),this.lbTotal.textContent=this.formatNumber(0),this.lbRecordCount.textContent=this.formatNumber(0)}};g([he("paginationProxy")],Yc.prototype,"paginationProxy",2),g([he("rowNodeBlockLoader")],Yc.prototype,"rowNodeBlockLoader",2),g([bn("btFirst")],Yc.prototype,"btFirst",2),g([bn("btPrevious")],Yc.prototype,"btPrevious",2),g([bn("btNext")],Yc.prototype,"btNext",2),g([bn("btLast")],Yc.prototype,"btLast",2),g([bn("lbRecordCount")],Yc.prototype,"lbRecordCount",2),g([bn("lbFirstRowOnPage")],Yc.prototype,"lbFirstRowOnPage",2),g([bn("lbLastRowOnPage")],Yc.prototype,"lbLastRowOnPage",2),g([bn("lbCurrent")],Yc.prototype,"lbCurrent",2),g([bn("lbTotal")],Yc.prototype,"lbTotal",2),g([bn("pageSizeComp")],Yc.prototype,"pageSizeComp",2),g([le],Yc.prototype,"postConstruct",1);var Qc=class e extends wn{constructor(){super(e.TEMPLATE),this.inProgress=!1,this.destroyRequested=!1}updateLayoutClasses(e,t){const i=this.eOverlayWrapper.classList;i.toggle("ag-layout-auto-height",t.autoHeight),i.toggle("ag-layout-normal",t.normal),i.toggle("ag-layout-print",t.print)}postConstruct(){this.createManagedBean(new Xo(this)),this.setDisplayed(!1,{skipAriaHidden:!0}),this.overlayService.registerOverlayWrapperComp(this)}setWrapperTypeClass(e){const t=this.eOverlayWrapper.classList;this.activeOverlayWrapperCssClass&&t.toggle(this.activeOverlayWrapperCssClass,!1),this.activeOverlayWrapperCssClass=e,t.toggle(e,!0)}showOverlay(e,t,i){this.inProgress||(this.setWrapperTypeClass(t),this.destroyActiveOverlay(),this.inProgress=!0,e&&e.then(e=>{this.inProgress=!1,this.eOverlayWrapper.appendChild(e.getGui()),this.activeOverlay=e,this.updateListenerDestroyFunc=i,this.destroyRequested&&(this.destroyRequested=!1,this.destroyActiveOverlay())}),this.setDisplayed(!0,{skipAriaHidden:!0}))}destroyActiveOverlay(){var e;this.inProgress?this.destroyRequested=!0:this.activeOverlay&&(this.activeOverlay=this.getContext().destroyBean(this.activeOverlay),null==(e=this.updateListenerDestroyFunc)||e.call(this),yr(this.eOverlayWrapper))}hideOverlay(){this.destroyActiveOverlay(),this.setDisplayed(!1,{skipAriaHidden:!0})}destroy(){this.destroyActiveOverlay(),super.destroy()}};Qc.TEMPLATE='\n        <div class="ag-overlay" role="presentation">\n            <div class="ag-overlay-panel" role="presentation">\n                <div class="ag-overlay-wrapper" ref="eOverlayWrapper" role="presentation"></div>\n            </div>\n        </div>',g([he("overlayService")],Qc.prototype,"overlayService",2),g([bn("eOverlayWrapper")],Qc.prototype,"eOverlayWrapper",2),g([le],Qc.prototype,"postConstruct",1);var Xc=Qc,Zc=class extends nt{getFirstRow(){let e,t=0;return this.pinnedRowModel.getPinnedTopRowCount()?e="top":this.rowModel.getRowCount()?(e=null,t=this.paginationProxy.getPageFirstRow()):this.pinnedRowModel.getPinnedBottomRowCount()&&(e="bottom"),void 0===e?null:{rowIndex:t,rowPinned:e}}getLastRow(){let e,t=null;const i=this.pinnedRowModel.getPinnedBottomRowCount(),r=this.pinnedRowModel.getPinnedTopRowCount();return i?(t="bottom",e=i-1):this.rowModel.getRowCount()?(t=null,e=this.paginationProxy.getPageLastRow()):r&&(t="top",e=r-1),void 0===e?null:{rowIndex:e,rowPinned:t}}getRowNode(e){switch(e.rowPinned){case"top":return this.pinnedRowModel.getPinnedTopRowData()[e.rowIndex];case"bottom":return this.pinnedRowModel.getPinnedBottomRowData()[e.rowIndex];default:return this.rowModel.getRow(e.rowIndex)}}sameRow(e,t){return!e&&!t||!(e&&!t||!e&&t)&&e.rowIndex===t.rowIndex&&e.rowPinned==t.rowPinned}before(e,t){switch(e.rowPinned){case"top":if("top"!==t.rowPinned)return!0;break;case"bottom":if("bottom"!==t.rowPinned)return!1;break;default:if(y(t.rowPinned))return"top"!==t.rowPinned}return e.rowIndex<t.rowIndex}};g([he("rowModel")],Zc.prototype,"rowModel",2),g([he("pinnedRowModel")],Zc.prototype,"pinnedRowModel",2),g([he("paginationProxy")],Zc.prototype,"paginationProxy",2),Zc=g([ue("rowPositionUtils")],Zc);var Jc=class extends nt{createId(e){const{rowIndex:t,rowPinned:i,column:r}=e;return this.createIdFromValues({rowIndex:t,column:r,rowPinned:i})}createIdFromValues(e){const{rowIndex:t,rowPinned:i,column:r}=e;return`${t}.${null==i?"null":i}.${r.getId()}`}equals(e,t){const i=e.column===t.column,r=e.rowPinned===t.rowPinned,n=e.rowIndex===t.rowIndex;return i&&r&&n}};Jc=g([ue("cellPositionUtils")],Jc);var eu=class{constructor(e){this.cellValueChanges=e}},tu=class extends eu{constructor(e,t,i,r){super(e),this.initialRange=t,this.finalRange=i,this.ranges=r}},iu=class e{constructor(t){this.actionStack=[],this.maxStackSize=t||e.DEFAULT_STACK_SIZE,this.actionStack=new Array(this.maxStackSize)}pop(){return this.actionStack.pop()}push(e){e.cellValueChanges&&e.cellValueChanges.length>0&&(this.actionStack.length===this.maxStackSize&&this.actionStack.shift(),this.actionStack.push(e))}clear(){this.actionStack=[]}getCurrentStackSize(){return this.actionStack.length}};iu.DEFAULT_STACK_SIZE=10;var ru=iu,nu=class extends nt{constructor(){super(...arguments),this.cellValueChanges=[],this.activeCellEdit=null,this.activeRowEdit=null,this.isPasting=!1,this.isRangeInAction=!1,this.onCellValueChanged=e=>{const t={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned},i=null!==this.activeCellEdit&&this.cellPositionUtils.equals(this.activeCellEdit,t),r=null!==this.activeRowEdit&&this.rowPositionUtils.sameRow(this.activeRowEdit,t);if(!(i||r||this.isPasting||this.isRangeInAction))return;const{rowPinned:n,rowIndex:s,column:o,oldValue:a,value:l}=e,c={rowPinned:n,rowIndex:s,columnId:o.getColId(),newValue:l,oldValue:a};this.cellValueChanges.push(c)},this.clearStacks=()=>{this.undoStack.clear(),this.redoStack.clear()}}init(){if(!this.gos.get("undoRedoCellEditing"))return;const e=this.gos.get("undoRedoCellEditingLimit");e<=0||(this.undoStack=new ru(e),this.redoStack=new ru(e),this.addRowEditingListeners(),this.addCellEditingListeners(),this.addPasteListeners(),this.addFillListeners(),this.addCellKeyListeners(),this.addManagedListener(this.eventService,ct.EVENT_CELL_VALUE_CHANGED,this.onCellValueChanged),this.addManagedListener(this.eventService,ct.EVENT_MODEL_UPDATED,e=>{e.keepUndoRedoStack||this.clearStacks()}),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_GROUP_OPENED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_MOVED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PINNED,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VISIBLE,this.clearStacks),this.addManagedListener(this.eventService,ct.EVENT_ROW_DRAG_END,this.clearStacks),this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl}))}getCurrentUndoStackSize(){return this.undoStack?this.undoStack.getCurrentStackSize():0}getCurrentRedoStackSize(){return this.redoStack?this.redoStack.getCurrentStackSize():0}undo(e){const t={type:ct.EVENT_UNDO_STARTED,source:e};this.eventService.dispatchEvent(t);const i=this.undoRedo(this.undoStack,this.redoStack,"initialRange","oldValue","undo"),r={type:ct.EVENT_UNDO_ENDED,source:e,operationPerformed:i};this.eventService.dispatchEvent(r)}redo(e){const t={type:ct.EVENT_REDO_STARTED,source:e};this.eventService.dispatchEvent(t);const i=this.undoRedo(this.redoStack,this.undoStack,"finalRange","newValue","redo"),r={type:ct.EVENT_REDO_ENDED,source:e,operationPerformed:i};this.eventService.dispatchEvent(r)}undoRedo(e,t,i,r,n){if(!e)return!1;const s=e.pop();return!(!s||!s.cellValueChanges||(this.processAction(s,e=>e[r],n),s instanceof tu?this.processRange(this.rangeService,s.ranges||[s[i]]):this.processCell(s.cellValueChanges),t.push(s),0))}processAction(e,t,i){e.cellValueChanges.forEach(e=>{const{rowIndex:r,rowPinned:n,columnId:s}=e,o={rowIndex:r,rowPinned:n},a=this.rowPositionUtils.getRowNode(o);a.displayed&&a.setDataValue(s,t(e),i)})}processRange(e,t){let i;e.removeAllCellRanges(!0),t.forEach((r,n)=>{if(!r)return;const s=r.startRow,o=r.endRow;n===t.length-1&&(i={rowPinned:s.rowPinned,rowIndex:s.rowIndex,columnId:r.startColumn.getColId()},this.setLastFocusedCell(i));const a={rowStartIndex:s.rowIndex,rowStartPinned:s.rowPinned,rowEndIndex:o.rowIndex,rowEndPinned:o.rowPinned,columnStart:r.startColumn,columns:r.columns};e.addCellRange(a)})}processCell(e){const t=e[0],{rowIndex:i,rowPinned:r}=t,n={rowIndex:i,rowPinned:r},s=this.rowPositionUtils.getRowNode(n),o={rowPinned:t.rowPinned,rowIndex:s.rowIndex,columnId:t.columnId};this.setLastFocusedCell(o,this.rangeService)}setLastFocusedCell(e,t){const{rowIndex:i,columnId:r,rowPinned:n}=e,s=this.gridBodyCtrl.getScrollFeature(),o=this.columnModel.getGridColumn(r);if(!o)return;s.ensureIndexVisible(i),s.ensureColumnVisible(o);const a={rowIndex:i,column:o,rowPinned:n};this.focusService.setFocusedCell(d(h({},a),{forceBrowserFocus:!0})),null==t||t.setRangeToCell(a)}addRowEditingListeners(){this.addManagedListener(this.eventService,ct.EVENT_ROW_EDITING_STARTED,e=>{this.activeRowEdit={rowIndex:e.rowIndex,rowPinned:e.rowPinned}}),this.addManagedListener(this.eventService,ct.EVENT_ROW_EDITING_STOPPED,()=>{const e=new eu(this.cellValueChanges);this.pushActionsToUndoStack(e),this.activeRowEdit=null})}addCellEditingListeners(){this.addManagedListener(this.eventService,ct.EVENT_CELL_EDITING_STARTED,e=>{this.activeCellEdit={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned}}),this.addManagedListener(this.eventService,ct.EVENT_CELL_EDITING_STOPPED,e=>{if(this.activeCellEdit=null,e.valueChanged&&!this.activeRowEdit&&!this.isPasting&&!this.isRangeInAction){const e=new eu(this.cellValueChanges);this.pushActionsToUndoStack(e)}})}addPasteListeners(){this.addManagedListener(this.eventService,ct.EVENT_PASTE_START,()=>{this.isPasting=!0}),this.addManagedListener(this.eventService,ct.EVENT_PASTE_END,()=>{const e=new eu(this.cellValueChanges);this.pushActionsToUndoStack(e),this.isPasting=!1})}addFillListeners(){this.addManagedListener(this.eventService,ct.EVENT_FILL_START,()=>{this.isRangeInAction=!0}),this.addManagedListener(this.eventService,ct.EVENT_FILL_END,e=>{const t=new tu(this.cellValueChanges,e.initialRange,e.finalRange);this.pushActionsToUndoStack(t),this.isRangeInAction=!1})}addCellKeyListeners(){this.addManagedListener(this.eventService,ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_START,()=>{this.isRangeInAction=!0}),this.addManagedListener(this.eventService,ct.EVENT_KEY_SHORTCUT_CHANGED_CELL_END,()=>{let e;e=this.rangeService&&this.gos.get("enableRangeSelection")?new tu(this.cellValueChanges,void 0,void 0,[...this.rangeService.getCellRanges()]):new eu(this.cellValueChanges),this.pushActionsToUndoStack(e),this.isRangeInAction=!1})}pushActionsToUndoStack(e){this.undoStack.push(e),this.cellValueChanges=[],this.redoStack.clear()}};g([he("focusService")],nu.prototype,"focusService",2),g([he("ctrlsService")],nu.prototype,"ctrlsService",2),g([he("cellPositionUtils")],nu.prototype,"cellPositionUtils",2),g([he("rowPositionUtils")],nu.prototype,"rowPositionUtils",2),g([he("columnModel")],nu.prototype,"columnModel",2),g([de("rangeService")],nu.prototype,"rangeService",2),g([le],nu.prototype,"init",1),nu=g([ue("undoRedoService")],nu);var su=class extends nt{findHeader(e,t){let i,r;if(e.column instanceof lt?i=this.columnModel.getDisplayedGroupAtDirection(e.column,t):(r=`getDisplayedCol${t}`,i=this.columnModel[r](e.column)),!i)return;let{headerRowIndex:n}=e;if("filter"!==this.getHeaderRowType(n)){const e=[i];for(;i.getParent();)i=i.getParent(),e.push(i);i=e[e.length-1-n]}const{column:s,headerRowIndex:o}=this.getHeaderIndexToFocus(i,n);return{column:s,headerRowIndex:o}}getHeaderIndexToFocus(e,t){let i;if(e instanceof lt&&this.isAnyChildSpanningHeaderHeight(e)&&e.isPadding()){const r=e;i=r.getLeafColumns()[0];let n=i;for(;n!==r;)t++,n=n.getParent()}return{column:i||e,headerRowIndex:t}}isAnyChildSpanningHeaderHeight(e){return!!e&&e.getLeafColumns().some(e=>e.isSpanHeaderHeight())}getColumnVisibleParent(e,t){const i=this.getHeaderRowType(t),r="column"===i;let n="filter"===i?e:e.getParent(),s=t-1,o=s;if(r&&this.isAnyChildSpanningHeaderHeight(e.getParent())){for(;n&&n.isPadding();)n=n.getParent(),s--;o=s,s<0&&(n=e,s=t,o=void 0)}return{column:n,headerRowIndex:s,headerRowIndexWithoutSpan:o}}getColumnVisibleChild(e,t,i="After"){let r=e,n=t+1,s=n;if("group"===this.getHeaderRowType(t)){const t=e.getDisplayedLeafColumns(),s="After"===i?t[0]:Pe(t),o=[];let a=s;for(;a.getParent()!==e;)a=a.getParent(),o.push(a);if(r=s,s.isSpanHeaderHeight())for(let e=o.length-1;e>=0;e--){const t=o[e];if(!t.isPadding()){r=t;break}n++}else r=Pe(o),r||(r=s)}return{column:r,headerRowIndex:n,headerRowIndexWithoutSpan:s}}getHeaderRowType(e){const t=this.ctrlsService.getHeaderRowContainerCtrl();if(t)return t.getRowType(e)}findColAtEdgeForHeaderRow(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=i["start"===t?0:i.length-1];if(!r)return;const n=this.ctrlsService.getHeaderRowContainerCtrl(r.getPinned()).getRowType(e);return"group"==n?{headerRowIndex:e,column:this.columnModel.getColumnGroupAtLevel(r,e)}:{headerRowIndex:null==n?-1:e,column:r}}};g([he("columnModel")],su.prototype,"columnModel",2),g([he("ctrlsService")],su.prototype,"ctrlsService",2),su=g([ue("headerPositionUtils")],su);var ou=class{buildColumnDefs(e,t,i){const r=[],n={};return e.forEach(e=>{let s=!0,o=this.createDefFromColumn(e,t,i),a=e.getOriginalParent(),l=null;for(;a;){let e=null;if(a.isPadding()){a=a.getOriginalParent();continue}const t=n[a.getGroupId()];if(t){t.children.push(o),s=!1;break}if(e=this.createDefFromGroup(a),e&&(e.children=[o],n[e.groupId]=e,o=e,a=a.getOriginalParent()),null!=a&&l===a){s=!1;break}l=a}s&&r.push(o)}),r}createDefFromGroup(e){const t=N(e.getColGroupDef(),["children"]);return t&&(t.groupId=e.getGroupId()),t}createDefFromColumn(e,t,i){const r=N(e.getColDef());return r.colId=e.getColId(),r.width=e.getActualWidth(),r.rowGroup=e.isRowGroupActive(),r.rowGroupIndex=e.isRowGroupActive()?t.indexOf(e):null,r.pivot=e.isPivotActive(),r.pivotIndex=e.isPivotActive()?i.indexOf(e):null,r.aggFunc=e.isValueActive()?e.getAggFunc():null,r.hide=!e.isVisible()||void 0,r.pinned=e.isPinned()?e.getPinned():null,r.sort=e.getSort()?e.getSort():null,r.sortIndex=null!=e.getSortIndex()?e.getSortIndex():null,r}};ou=g([ue("columnDefFactory")],ou);var au=class{getInitialRowClasses(e){const t=[];return y(e.extraCssClass)&&t.push(e.extraCssClass),t.push("ag-row"),t.push(e.rowFocused?"ag-row-focus":"ag-row-no-focus"),e.fadeRowIn&&t.push("ag-opacity-zero"),t.push(e.rowIsEven?"ag-row-even":"ag-row-odd"),e.rowNode.isRowPinned()&&t.push("ag-row-pinned"),e.rowNode.isSelected()&&t.push("ag-row-selected"),e.rowNode.footer&&t.push("ag-row-footer"),t.push("ag-row-level-"+e.rowLevel),e.rowNode.stub&&t.push("ag-row-loading"),e.fullWidthRow&&t.push("ag-full-width-row"),e.expandable&&(t.push("ag-row-group"),t.push(e.rowNode.expanded?"ag-row-group-expanded":"ag-row-group-contracted")),e.rowNode.dragging&&t.push("ag-row-dragging"),Ue(t,this.processClassesFromGridOptions(e.rowNode)),Ue(t,this.preProcessRowClassRules(e.rowNode)),t.push(e.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),e.firstRowOnPage&&t.push("ag-row-first"),e.lastRowOnPage&&t.push("ag-row-last"),e.fullWidthRow&&("left"===e.pinned&&t.push("ag-cell-last-left-pinned"),"right"===e.pinned&&t.push("ag-cell-first-right-pinned")),t}processClassesFromGridOptions(e){const t=[],i=e=>{"string"==typeof e?t.push(e):Array.isArray(e)&&e.forEach(e=>t.push(e))},r=this.gos.get("rowClass");if(r){if("function"==typeof r)return console.warn("AG Grid: rowClass should not be a function, please use getRowClass instead"),[];i(r)}const n=this.gos.getCallback("getRowClass");return n&&i(n({data:e.data,node:e,rowIndex:e.rowIndex})),t}preProcessRowClassRules(e){const t=[];return this.processRowClassRules(e,e=>{t.push(e)},e=>{}),t}processRowClassRules(e,t,i){const r=this.gos.addGridCommonParams({data:e.data,node:e,rowIndex:e.rowIndex});this.stylingService.processClassRules(void 0,this.gos.get("rowClassRules"),r,t,i)}calculateRowLevel(e){return e.group?e.level:e.parent?e.parent.level+1:0}};g([he("stylingService")],au.prototype,"stylingService",2),g([he("gridOptionsService")],au.prototype,"gos",2),au=g([ue("rowCssClassCalculator")],au);var lu=class extends nt{init(){this.isAccentedSort=this.gos.get("accentedSort"),this.primaryColumnsSortGroups=this.gos.isColumnsSortingCoupledToGroup(),this.addManagedPropertyListener("accentedSort",e=>this.isAccentedSort=e.currentValue),this.addManagedPropertyListener("autoGroupColumnDef",()=>this.primaryColumnsSortGroups=this.gos.isColumnsSortingCoupledToGroup())}doFullSort(e,t){const i=e.map((e,t)=>({currentPos:t,rowNode:e}));return i.sort(this.compareRowNodes.bind(this,t)),i.map(e=>e.rowNode)}compareRowNodes(e,t,i){const r=t.rowNode,n=i.rowNode;for(let t=0,i=e.length;t<i;t++){const i=e[t],s="desc"===i.sort,o=this.getValue(r,i.column),a=this.getValue(n,i.column);let l;const c=this.getComparator(i,r);if(l=c?c(o,a,r,n,s):cn.defaultComparator(o,a,this.isAccentedSort),!isNaN(l)&&0!==l)return"asc"===i.sort?l:-1*l}return t.currentPos-i.currentPos}getComparator(e,t){const i=e.column,r=i.getColDef().comparator;if(null!=r)return r;if(!i.getColDef().showRowGroup)return;const n=!t.group&&i.getColDef().field;if(!n)return;const s=this.columnModel.getPrimaryColumn(n);return s?s.getColDef().comparator:void 0}getValue(e,t){var i,r;if(!this.primaryColumnsSortGroups)return this.valueService.getValue(t,e,!1,!1);if(e.rowGroupColumn===t){if(this.gos.isGroupUseEntireRow(this.columnModel.isPivotActive())){const r=null==(i=e.allLeafChildren)?void 0:i[0];return r?this.valueService.getValue(t,r,!1,!1):void 0}const n=this.columnModel.getGroupDisplayColumnForGroup(t.getId());if(!n)return;return null==(r=e.groupData)?void 0:r[n.getId()]}return e.group&&t.getColDef().showRowGroup?void 0:this.valueService.getValue(t,e,!1,!1)}};g([he("valueService")],lu.prototype,"valueService",2),g([he("columnModel")],lu.prototype,"columnModel",2),g([le],lu.prototype,"init",1),lu=g([ue("rowNodeSorter")],lu);var cu=class extends nt{constructor(){super(...arguments),this.params={},this.ready=!1,this.readyCallbacks=[]}checkReady(){const e=this.params;this.ready=null!=e.gridCtrl&&null!=e.gridBodyCtrl&&null!=e.center&&null!=e.left&&null!=e.right&&null!=e.bottomCenter&&null!=e.bottomLeft&&null!=e.bottomRight&&null!=e.topCenter&&null!=e.topLeft&&null!=e.topRight&&null!=e.stickyTopCenter&&null!=e.stickyTopLeft&&null!=e.stickyTopRight&&null!=e.stickyBottomCenter&&null!=e.stickyBottomLeft&&null!=e.stickyBottomRight&&null!=e.centerHeader&&null!=e.leftHeader&&null!=e.rightHeader&&null!=e.fakeHScrollComp&&null!=e.fakeVScrollComp&&null!=e.gridHeaderCtrl,this.ready&&(this.readyCallbacks.forEach(t=>t(e)),this.readyCallbacks.length=0)}whenReady(e){this.ready?e(this.params):this.readyCallbacks.push(e)}register(e,t){this.params[e]=t,this.checkReady()}registerHeaderContainer(e,t){switch(t){case"left":this.params.leftHeader=e;break;case"right":this.params.rightHeader=e;break;default:this.params.centerHeader=e}this.checkReady()}get(e){return this.params[e]}getParams(){return this.params}getGridBodyCtrl(){return this.params.gridBodyCtrl}getHeaderRowContainerCtrls(){return[this.params.leftHeader,this.params.rightHeader,this.params.centerHeader]}getHeaderRowContainerCtrl(e){switch(e){case"left":return this.params.leftHeader;case"right":return this.params.rightHeader;default:return this.params.centerHeader}}};cu.NAME="ctrlsService",cu=g([ue(cu.NAME)],cu);var uu=class extends nt{constructor(){super(...arguments),this.registry={}}register(e){this.registry[e.controllerName]=e.controllerClass}getInstance(e){const t=this.registry[e];if(null!=t)return new t}};uu=g([ue("ctrlsFactory")],uu);var hu=class extends wn{constructor(e,t){super(e),this.direction=t,this.hideTimeout=null}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_SCROLL_VISIBILITY_CHANGED,this.onScrollVisibilityChanged.bind(this)),this.onScrollVisibilityChanged(),this.addOrRemoveCssClass("ag-apple-scrollbar",Di()||Ii())}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.invisibleScrollbar=Hi(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles()))}addActiveListenerToggles(){const e=this.getGui();["mouseenter","mousedown","touchstart"].forEach(t=>this.addManagedListener(e,t,()=>this.addOrRemoveCssClass("ag-scrollbar-active",!0))),["mouseleave","touchend"].forEach(t=>this.addManagedListener(e,t,()=>this.addOrRemoveCssClass("ag-scrollbar-active",!1)))}onScrollVisibilityChanged(){void 0===this.invisibleScrollbar&&this.initialiseInvisibleScrollbar(),this.animationFrameService.requestAnimationFrame(()=>this.setScrollVisible())}hideAndShowInvisibleScrollAsNeeded(){this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL,e=>{e.direction===this.direction&&(null!==this.hideTimeout&&(window.clearTimeout(this.hideTimeout),this.hideTimeout=null),this.addOrRemoveCssClass("ag-scrollbar-scrolling",!0))}),this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL_END,()=>{this.hideTimeout=window.setTimeout(()=>{this.addOrRemoveCssClass("ag-scrollbar-scrolling",!1),this.hideTimeout=null},400)})}attemptSettingScrollPosition(e){const t=this.getViewport();ee(()=>br(t),()=>this.setScrollPosition(e),100)}getViewport(){return this.eViewport}getContainer(){return this.eContainer}onScrollCallback(e){this.addManagedListener(this.getViewport(),"scroll",e)}};g([bn("eViewport")],hu.prototype,"eViewport",2),g([bn("eContainer")],hu.prototype,"eContainer",2),g([he("scrollVisibleService")],hu.prototype,"scrollVisibleService",2),g([he("ctrlsService")],hu.prototype,"ctrlsService",2),g([he("animationFrameService")],hu.prototype,"animationFrameService",2);var du=class e extends hu{constructor(){super(e.TEMPLATE,"horizontal")}postConstruct(){super.postConstruct();const e=this.setFakeHScrollSpacerWidths.bind(this);this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedPropertyListener("domLayout",e),this.ctrlsService.register("fakeHScrollComp",this),this.createManagedBean(new Ta(e=>this.eContainer.style.width=`${e}px`)),this.addManagedPropertyListeners(["suppressHorizontalScroll"],this.onScrollVisibilityChanged.bind(this))}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.enableRtl=this.gos.get("enableRtl"),super.initialiseInvisibleScrollbar(),this.invisibleScrollbar&&this.refreshCompBottom())}onPinnedRowDataChanged(){this.refreshCompBottom()}refreshCompBottom(){if(!this.invisibleScrollbar)return;const e=this.pinnedRowModel.getPinnedBottomTotalHeight();this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){const e=this.scrollVisibleService.isVerticalScrollShowing();let t=this.columnModel.getDisplayedColumnsRightWidth();const i=!this.enableRtl&&e,r=this.gos.getScrollbarWidth();i&&(t+=r),Dr(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=r);let n=this.columnModel.getDisplayedColumnsLeftWidth();this.enableRtl&&e&&(n+=r),Dr(this.eLeftSpacer,n),this.eLeftSpacer.classList.toggle("ag-scroller-corner",n<=r)}setScrollVisible(){const e=this.scrollVisibleService.isHorizontalScrollShowing(),t=this.invisibleScrollbar,i=this.gos.get("suppressHorizontalScroll"),r=e&&this.gos.getScrollbarWidth()||0,n=i?0:0===r&&t?16:r;this.addOrRemoveCssClass("ag-scrollbar-invisible",t),Lr(this.getGui(),n),Lr(this.eViewport,n),Lr(this.eContainer,n),this.setDisplayed(e,{skipAriaHidden:!0})}getScrollPosition(){return vr(this.getViewport(),this.enableRtl)}setScrollPosition(e){br(this.getViewport())||this.attemptSettingScrollPosition(e),Cr(this.getViewport(),e,this.enableRtl)}};du.TEMPLATE='<div class="ag-body-horizontal-scroll" aria-hidden="true">\n            <div class="ag-horizontal-left-spacer" ref="eLeftSpacer"></div>\n            <div class="ag-body-horizontal-scroll-viewport" ref="eViewport">\n                <div class="ag-body-horizontal-scroll-container" ref="eContainer"></div>\n            </div>\n            <div class="ag-horizontal-right-spacer" ref="eRightSpacer"></div>\n        </div>',g([bn("eLeftSpacer")],du.prototype,"eLeftSpacer",2),g([bn("eRightSpacer")],du.prototype,"eRightSpacer",2),g([he("columnModel")],du.prototype,"columnModel",2),g([he("pinnedRowModel")],du.prototype,"pinnedRowModel",2),g([le],du.prototype,"postConstruct",1);var pu=du,gu=class extends nt{postConstruct(){const e=this.checkContainerWidths.bind(this);this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,e),this.addManagedPropertyListener("domLayout",e)}checkContainerWidths(){const e=this.gos.isDomLayout("print"),t=e?0:this.columnModel.getDisplayedColumnsLeftWidth(),i=e?0:this.columnModel.getDisplayedColumnsRightWidth();t!=this.leftWidth&&(this.leftWidth=t,this.eventService.dispatchEvent({type:ct.EVENT_LEFT_PINNED_WIDTH_CHANGED})),i!=this.rightWidth&&(this.rightWidth=i,this.eventService.dispatchEvent({type:ct.EVENT_RIGHT_PINNED_WIDTH_CHANGED}))}getPinnedRightWidth(){return this.rightWidth}getPinnedLeftWidth(){return this.leftWidth}};g([he("columnModel")],gu.prototype,"columnModel",2),g([le],gu.prototype,"postConstruct",1),gu=g([ue("pinnedWidthService")],gu);var fu=class extends nt{constructor(){super(...arguments),this.events=[]}postConstruct(){"clientSide"==this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel)}dispatchExpanded(e,t){if(null==this.clientSideRowModel)return void this.eventService.dispatchEvent(e);this.events.push(e);const i=()=>{this.clientSideRowModel&&this.clientSideRowModel.onRowGroupOpened(),this.events.forEach(e=>this.eventService.dispatchEvent(e)),this.events=[]};t?i():(null==this.dispatchExpandedDebounced&&(this.dispatchExpandedDebounced=this.animationFrameService.debounce(i)),this.dispatchExpandedDebounced())}};g([he("animationFrameService")],fu.prototype,"animationFrameService",2),g([he("rowModel")],fu.prototype,"rowModel",2),g([le],fu.prototype,"postConstruct",1),fu=g([ue("rowNodeEventThrottle")],fu);var mu=(e,t)=>{var i;return"clientSide"===(null!=(i=t.rowModelType)?i:"clientSide")?{module:"@ag-grid-enterprise/row-grouping"}:null},vu={enableRowGroup:mu,rowGroup:mu,rowGroupIndex:mu,enablePivot:mu,enableValue:mu,pivot:mu,pivotIndex:mu,aggFunc:mu,cellEditor:e=>"agRichSelect"===e.cellEditor||"agRichSelectCellEditor"===e.cellEditor?{module:"@ag-grid-enterprise/rich-select"}:null,menuTabs:e=>{var t;const i=["columnsMenuTab","generalMenuTab"];return(null==(t=e.menuTabs)?void 0:t.some(e=>i.includes(e)))?{module:"@ag-grid-enterprise/menu"}:null},columnsMenuParams:{module:["@ag-grid-enterprise/menu","@ag-grid-enterprise/column-tool-panel"]},columnChooserParams:{module:["@ag-grid-enterprise/menu","@ag-grid-enterprise/column-tool-panel"]},headerCheckboxSelection:{supportedRowModels:["clientSide","serverSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelection is only supported with rowSelection=multiple"},headerCheckboxSelectionFilteredOnly:{supportedRowModels:["clientSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionFilteredOnly is only supported with rowSelection=multiple"},headerCheckboxSelectionCurrentPageOnly:{supportedRowModels:["clientSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionCurrentPageOnly is only supported with rowSelection=multiple"},children:()=>Cu},Cu={objectName:"colDef",allProperties:Object.keys({headerName:void 0,columnGroupShow:void 0,headerClass:void 0,toolPanelClass:void 0,headerValueGetter:void 0,pivotKeys:void 0,groupId:void 0,colId:void 0,sort:void 0,initialSort:void 0,field:void 0,type:void 0,cellDataType:void 0,tooltipComponent:void 0,tooltipField:void 0,headerTooltip:void 0,cellClass:void 0,showRowGroup:void 0,filter:void 0,initialAggFunc:void 0,defaultAggFunc:void 0,aggFunc:void 0,pinned:void 0,initialPinned:void 0,chartDataType:void 0,cellAriaRole:void 0,cellEditorPopupPosition:void 0,headerGroupComponent:void 0,headerGroupComponentParams:void 0,cellStyle:void 0,cellRenderer:void 0,cellRendererParams:void 0,cellEditor:void 0,cellEditorParams:void 0,filterParams:void 0,pivotValueColumn:void 0,headerComponent:void 0,headerComponentParams:void 0,floatingFilterComponent:void 0,floatingFilterComponentParams:void 0,tooltipComponentParams:void 0,refData:void 0,columnsMenuParams:void 0,columnChooserParams:void 0,children:void 0,sortingOrder:void 0,allowedAggFuncs:void 0,menuTabs:void 0,pivotTotalColumnIds:void 0,cellClassRules:void 0,icons:void 0,sortIndex:void 0,initialSortIndex:void 0,flex:void 0,initialFlex:void 0,width:void 0,initialWidth:void 0,minWidth:void 0,maxWidth:void 0,rowGroupIndex:void 0,initialRowGroupIndex:void 0,pivotIndex:void 0,initialPivotIndex:void 0,suppressCellFlash:void 0,suppressColumnsToolPanel:void 0,suppressFiltersToolPanel:void 0,openByDefault:void 0,marryChildren:void 0,suppressStickyLabel:void 0,hide:void 0,initialHide:void 0,rowGroup:void 0,initialRowGroup:void 0,pivot:void 0,initialPivot:void 0,checkboxSelection:void 0,showDisabledCheckboxes:void 0,headerCheckboxSelection:void 0,headerCheckboxSelectionFilteredOnly:void 0,headerCheckboxSelectionCurrentPageOnly:void 0,suppressMenu:void 0,suppressHeaderMenuButton:void 0,suppressMovable:void 0,lockPosition:void 0,lockVisible:void 0,lockPinned:void 0,unSortIcon:void 0,suppressSizeToFit:void 0,suppressAutoSize:void 0,enableRowGroup:void 0,enablePivot:void 0,enableValue:void 0,editable:void 0,suppressPaste:void 0,suppressNavigable:void 0,enableCellChangeFlash:void 0,rowDrag:void 0,dndSource:void 0,autoHeight:void 0,wrapText:void 0,sortable:void 0,resizable:void 0,singleClickEdit:void 0,floatingFilter:void 0,cellEditorPopup:void 0,suppressFillHandle:void 0,wrapHeaderText:void 0,autoHeaderHeight:void 0,dndSourceOnRowDrag:void 0,valueGetter:void 0,valueSetter:void 0,filterValueGetter:void 0,keyCreator:void 0,valueFormatter:void 0,valueParser:void 0,comparator:void 0,equals:void 0,pivotComparator:void 0,suppressKeyboardEvent:void 0,suppressHeaderKeyboardEvent:void 0,colSpan:void 0,rowSpan:void 0,getQuickFilterText:void 0,onCellValueChanged:void 0,onCellClicked:void 0,onCellDoubleClicked:void 0,onCellContextMenu:void 0,rowDragText:void 0,tooltipValueGetter:void 0,cellRendererSelector:void 0,cellEditorSelector:void 0,suppressSpanHeaderHeight:void 0,useValueFormatterForExport:void 0,useValueParserForImport:void 0,mainMenuItems:void 0,contextMenuItems:void 0,suppressFloatingFilterButton:void 0,suppressHeaderFilterButton:void 0,suppressHeaderContextMenu:void 0,loadingCellRenderer:void 0,loadingCellRendererParams:void 0,loadingCellRendererSelector:void 0}),docsUrl:"column-properties/",deprecations:{columnsMenuParams:{version:"31.1",message:"Use `columnChooserParams` instead."},suppressMenu:{version:"31.1",message:"Use `suppressHeaderMenuButton` instead."},suppressCellFlash:{version:"31.2",message:"Use `enableCellChangeFlash={false}` in the ColDef"},dndSource:{version:"31.2",message:"This feature has been replaced by `Row Dragging to an External DropZone`."},dndSourceOnRowDrag:{version:"31.2",message:"This feature has been replaced by `Row Dragging to an External DropZone`."}},validations:vu},yu={suppressContextMenu:!1,preventDefaultOnContextMenu:!1,allowContextMenuWithControlKey:!1,suppressMenuHide:!1,enableBrowserTooltips:!1,tooltipTrigger:"hover",tooltipShowDelay:2e3,tooltipHideDelay:1e4,tooltipMouseTrack:!1,tooltipShowMode:"standard",tooltipInteraction:!1,copyHeadersToClipboard:!1,copyGroupHeadersToClipboard:!1,clipboardDelimiter:"\t",suppressCopyRowsToClipboard:!1,suppressCopySingleCellRanges:!1,suppressLastEmptyLineOnPaste:!1,suppressClipboardPaste:!1,suppressClipboardApi:!1,suppressCutToClipboard:!1,maintainColumnOrder:!1,suppressFieldDotNotation:!1,allowDragFromColumnsToolPanel:!1,suppressMovableColumns:!1,suppressColumnMoveAnimation:!1,suppressDragLeaveHidesColumns:!1,suppressRowGroupHidesColumns:!1,suppressAutoSize:!1,autoSizePadding:20,skipHeaderOnAutoSize:!1,singleClickEdit:!1,suppressClickEdit:!1,readOnlyEdit:!1,stopEditingWhenCellsLoseFocus:!1,enterNavigatesVertically:!1,enterNavigatesVerticallyAfterEdit:!1,enableCellEditingOnBackspace:!1,undoRedoCellEditing:!1,undoRedoCellEditingLimit:10,suppressCsvExport:!1,suppressExcelExport:!1,cacheQuickFilter:!1,includeHiddenColumnsInQuickFilter:!1,excludeChildrenWhenTreeDataFiltering:!1,enableAdvancedFilter:!1,includeHiddenColumnsInAdvancedFilter:!1,enableCharts:!1,suppressChartToolPanelsButton:!1,masterDetail:!1,keepDetailRows:!1,keepDetailRowsCount:10,detailRowAutoHeight:!1,tabIndex:0,rowBuffer:10,valueCache:!1,valueCacheNeverExpires:!1,enableCellExpressions:!1,suppressTouch:!1,suppressFocusAfterRefresh:!1,suppressAsyncEvents:!1,suppressBrowserResizeObserver:!1,suppressPropertyNamesCheck:!1,suppressChangeDetection:!1,debug:!1,suppressLoadingOverlay:!1,suppressNoRowsOverlay:!1,pagination:!1,paginationPageSize:100,paginationPageSizeSelector:!0,paginationAutoPageSize:!1,paginateChildRows:!1,suppressPaginationPanel:!1,pivotMode:!1,pivotPanelShow:"never",pivotDefaultExpanded:0,pivotSuppressAutoColumn:!1,suppressExpandablePivotGroups:!1,functionsReadOnly:!1,suppressAggFuncInHeader:!1,alwaysAggregateAtRootLevel:!1,aggregateOnlyChangedColumns:!1,suppressAggFilteredOnly:!1,removePivotHeaderRowWhenSingleValueColumn:!1,animateRows:!0,enableCellChangeFlash:!1,cellFlashDelay:500,cellFlashDuration:500,cellFadeDelay:1e3,cellFadeDuration:1e3,allowShowChangeAfterFilter:!1,domLayout:"normal",ensureDomOrder:!1,enableRtl:!1,suppressColumnVirtualisation:!1,suppressMaxRenderedRowRestriction:!1,suppressRowVirtualisation:!1,rowDragManaged:!1,suppressRowDrag:!1,suppressMoveWhenRowDragging:!1,rowDragEntireRow:!1,rowDragMultiRow:!1,embedFullWidthRows:!1,groupDisplayType:"singleColumn",groupDefaultExpanded:0,groupMaintainOrder:!1,groupSelectsChildren:!1,groupIncludeTotalFooter:!1,groupSuppressBlankHeader:!1,groupSelectsFiltered:!1,showOpenedGroup:!1,groupRemoveSingleChildren:!1,groupRemoveLowestSingleChildren:!1,groupHideOpenParents:!1,groupAllowUnbalanced:!1,rowGroupPanelShow:"never",suppressMakeColumnVisibleAfterUnGroup:!1,treeData:!1,rowGroupPanelSuppressSort:!1,suppressGroupRowsSticky:!1,rowModelType:"clientSide",asyncTransactionWaitMillis:50,suppressModelUpdateAfterUpdateTransaction:!1,cacheOverflowSize:1,infiniteInitialRowCount:1,serverSideInitialRowCount:1,suppressServerSideInfiniteScroll:!1,cacheBlockSize:100,maxBlocksInCache:-1,maxConcurrentDatasourceRequests:2,blockLoadDebounceMillis:0,purgeClosedRowNodes:!1,serverSideSortAllLevels:!1,serverSideOnlyRefreshFilteredGroups:!1,serverSideSortOnServer:!1,serverSideFilterOnServer:!1,serverSidePivotResultFieldSeparator:"_",viewportRowModelPageSize:5,viewportRowModelBufferSize:5,alwaysShowHorizontalScroll:!1,alwaysShowVerticalScroll:!1,debounceVerticalScrollbar:!1,suppressHorizontalScroll:!1,suppressScrollOnNewData:!1,suppressScrollWhenPopupsAreOpen:!1,suppressAnimationFrame:!1,suppressMiddleClickScrolls:!1,suppressPreventDefaultOnMouseWheel:!1,rowMultiSelectWithClick:!1,suppressRowDeselection:!1,suppressRowClickSelection:!1,suppressCellFocus:!1,suppressHeaderFocus:!1,suppressMultiRangeSelection:!1,enableCellTextSelection:!1,enableRangeSelection:!1,enableRangeHandle:!1,enableFillHandle:!1,fillHandleDirection:"xy",suppressClearOnFillReduction:!1,accentedSort:!1,unSortIcon:!1,suppressMultiSort:!1,alwaysMultiSort:!1,suppressMaintainUnsortedOrder:!1,suppressRowHoverHighlight:!1,suppressRowTransform:!1,columnHoverHighlight:!1,deltaSort:!1,enableGroupEdit:!1,suppressGroupMaintainValueType:!1,functionsPassive:!1,groupLockGroupColumns:0,serverSideEnableClientSideSort:!1,suppressServerSideFullWidthLoadingRow:!1,pivotMaxGeneratedColumns:-1},wu={sideBar:{module:"@ag-grid-enterprise/side-bar"},statusBar:{module:"@ag-grid-enterprise/status-bar"},enableCharts:{module:"@ag-grid-enterprise/charts"},getMainMenuItems:{module:"@ag-grid-enterprise/menu"},getContextMenuItems:{module:"@ag-grid-enterprise/menu"},allowContextMenuWithControlKey:{module:"@ag-grid-enterprise/menu"},enableAdvancedFilter:{module:"@ag-grid-enterprise/advanced-filter"},treeData:{supportedRowModels:["clientSide","serverSide"],module:"@ag-grid-enterprise/row-grouping",dependencies:e=>{var t;const i=null!=(t=e.rowModelType)?t:"clientSide";switch(i){case"clientSide":const t=`treeData requires 'getDataPath' in the ${i} row model.`;return e.getDataPath?null:t;case"serverSide":const r=`treeData requires 'isServerSideGroup' and 'getServerSideGroupKey' in the ${i} row model.`;return e.isServerSideGroup&&e.getServerSideGroupKey?null:r}return null}},masterDetail:{module:"@ag-grid-enterprise/master-detail"},enableRangeSelection:{module:"@ag-grid-enterprise/range-selection"},enableRangeHandle:{dependencies:{enableRangeSelection:[!0]}},enableFillHandle:{dependencies:{enableRangeSelection:[!0]}},groupDefaultExpanded:{supportedRowModels:["clientSide"]},groupIncludeFooter:{supportedRowModels:["clientSide","serverSide"],dependencies:e=>{var t;switch(null!=(t=e.rowModelType)?t:"clientSide"){case"clientSide":return null;case"serverSide":const t="groupIncludeFooter is not supported alongside suppressServerSideInfiniteScroll";return e.suppressServerSideInfiniteScroll?t:null}return null}},groupIncludeTotalFooter:{supportedRowModels:["clientSide"]},groupRemoveSingleChildren:{dependencies:{groupHideOpenParents:[void 0,!1],groupRemoveLowestSingleChildren:[void 0,!1]}},groupRemoveLowestSingleChildren:{dependencies:{groupHideOpenParents:[void 0,!1],groupRemoveSingleChildren:[void 0,!1]}},groupSelectsChildren:{dependencies:{rowSelection:["multiple"]}},suppressParentsInRowNodes:{dependencies:{groupSelectsChildren:[void 0,!1]}},viewportDatasource:{supportedRowModels:["viewport"],module:"@ag-grid-enterprise/viewport-row-model"},serverSideDatasource:{supportedRowModels:["serverSide"],module:"@ag-grid-enterprise/server-side-row-model"},cacheBlockSize:{supportedRowModels:["serverSide","infinite"]},datasource:{supportedRowModels:["infinite"],module:"@ag-grid-community/infinite-row-model"},rowData:{supportedRowModels:["clientSide"],module:"@ag-grid-community/client-side-row-model"},columnDefs:()=>Cu,defaultColDef:()=>Cu,defaultColGroupDef:()=>Cu,autoGroupColumnDef:()=>Cu},Su={objectName:"gridOptions",allProperties:[...It.ALL_PROPERTIES,...Nt.EVENT_CALLBACKS],propertyExceptions:["api","columnApi"],docsUrl:"grid-options/",deprecations:{enableChartToolPanelsButton:{version:"29"},functionsPassive:{version:"29.2"},onColumnRowGroupChangeRequest:{version:"29.2"},onColumnPivotChangeRequest:{version:"29.2"},onColumnValueChangeRequest:{version:"29.2"},onColumnAggFuncChangeRequest:{version:"29.2"},serverSideFilterAllLevels:{version:"30",message:"All server-side group levels are now filtered by default. This can be toggled using `serverSideOnlyRefreshFilteredGroups`."},suppressAggAtRootLevel:{version:"30",message:"The root level aggregation is now suppressed by default. This can be toggled using  `alwaysAggregateAtRootLevel`."},excludeHiddenColumnsFromQuickFilter:{version:"30",message:"Hidden columns are now excluded from the Quick Filter by default. This can be toggled using `includeHiddenColumnsInQuickFilter`."},enterMovesDown:{version:"30",renamed:"enterNavigatesVertically"},enterMovesDownAfterEdit:{version:"30",renamed:"enterNavigatesVerticallyAfterEdit"},suppressParentsInRowNodes:{version:"30.2",message:"Using suppressParentsInRowNodes is no longer recommended. To serialize nodes it is now recommended to instead remove the parent node reference before serialization."},advancedFilterModel:{version:"31",message:"Use `initialState.filter.advancedFilterModel` instead."},suppressAsyncEvents:{version:"31",message:"Events should be handled asynchronously."},cellFadeDelay:{version:"31.1",renamed:"cellFadeDuration"},cellFlashDelay:{version:"31.1",renamed:"cellFlashDuration"},suppressServerSideInfiniteScroll:{version:"31.1"},serverSideSortOnServer:{version:"31.1"},serverSideFilterOnServer:{version:"31.1"},enableCellChangeFlash:{version:"31.2",message:"Use `enableCellChangeFlash` in the `ColDef` or `defaultColDef` for all columns."},groupIncludeFooter:{version:"31.3",message:"Use `groupTotalRow` instead."},groupIncludeTotalFooter:{version:"31.3",message:"Use `grandTotalRow` instead."}},validations:wu},bu=class{constructor(){this.destroyed=!1,this.domDataKey="__AG_"+Math.random().toString(),this.propertyEventService=new me,this.globalEventHandlerFactory=e=>(t,i)=>{if(this.destroyed)return;const r=ut.has(t);if(r&&!e||!r&&e)return;const n=Nt.getCallbackForEvent(t),s=this.gridOptions[n];"function"==typeof s&&this.frameworkOverrides.wrapOutgoing(()=>{s(i)})}}get context(){return this.gridOptions.context}init(){this.columnApi=new _c(this.api);const e=!this.get("suppressAsyncEvents");this.eventService.addGlobalListener(this.globalEventHandlerFactory().bind(this),e),this.eventService.addGlobalListener(this.globalEventHandlerFactory(!0).bind(this),!1),this.propertyEventService.setFrameworkOverrides(this.frameworkOverrides),this.getScrollbarWidth()}destroy(){this.destroyed=!0,this.columnApi=void 0}get(e){var t;return null!=(t=this.gridOptions[e])?t:yu[e]}getCallback(e){return this.mergeGridCommonParams(this.gridOptions[e])}exists(e){return y(this.gridOptions[e])}mergeGridCommonParams(e){return e?t=>{const i=t;return i.api=this.api,i.columnApi=this.columnApi,i.context=this.context,e(i)}:e}static toBoolean(e){return"boolean"==typeof e?e:"string"==typeof e&&("TRUE"===e.toUpperCase()||""==e)}static toNumber(e){if("number"==typeof e)return e;if("string"==typeof e){const t=parseInt(e);if(isNaN(t))return;return t}}static toConstrainedNum(e,t){return i=>{const r=bu.toNumber(i);if(!(null==r||r<e||r>t))return r}}static getCoercedValue(e,t){const i=bu.PROPERTY_COERCIONS.get(e);return i?i(t):t}static getCoercedGridOptions(e){const t={};return Object.entries(e).forEach(([e,i])=>{const r=bu.getCoercedValue(e,i);t[e]=r}),t}updateGridOptions({options:e,force:t,source:i="api"}){const r={id:bu.changeSetId++,properties:[]},n=[];Object.entries(e).forEach(([e,s])=>{"api"===i&&xt[e]&&U(`${e} is an initial property and cannot be updated.`);const o=bu.getCoercedValue(e,s),a=t||"object"==typeof o&&"api"===i,l=this.gridOptions[e];if(a||l!==o){this.gridOptions[e]=o;const t={type:e,currentValue:o,previousValue:l,changeSet:r,source:i};n.push(t)}}),this.validationService.processGridOptions(this.gridOptions),r.properties=n.map(e=>e.type),n.forEach(e=>{this.gridOptions.debug&&console.log(`AG Grid: Updated property ${e.type} from `,e.previousValue," to  ",e.currentValue),this.propertyEventService.dispatchEvent(e)})}addEventListener(e,t){this.propertyEventService.addEventListener(e,t)}removeEventListener(e,t){this.propertyEventService.removeEventListener(e,t)}getScrollbarWidth(){if(null==this.scrollbarWidth){const e="number"==typeof this.gridOptions.scrollbarWidth&&this.gridOptions.scrollbarWidth>=0?this.gridOptions.scrollbarWidth:Gi();null!=e&&(this.scrollbarWidth=e,this.eventService.dispatchEvent({type:ct.EVENT_SCROLLBAR_WIDTH_CHANGED}))}return this.scrollbarWidth}isRowModelType(e){return this.gridOptions.rowModelType===e||"clientSide"===e&&w(this.gridOptions.rowModelType)}isDomLayout(e){var t;return(null!=(t=this.gridOptions.domLayout)?t:"normal")===e}isRowSelection(){return"single"===this.gridOptions.rowSelection||"multiple"===this.gridOptions.rowSelection}useAsyncEvents(){return!this.get("suppressAsyncEvents")}isGetRowHeightFunction(){return"function"==typeof this.gridOptions.getRowHeight}getRowHeightForNode(e,t=!1,i){if(null==i&&(i=this.environment.getDefaultRowHeight()),this.isGetRowHeightFunction()){if(t)return{height:i,estimated:!0};const r={node:e,data:e.data},n=this.getCallback("getRowHeight")(r);if(this.isNumeric(n))return 0===n&&U("The return of `getRowHeight` cannot be zero. If the intention is to hide rows, use a filter instead."),{height:Math.max(1,n),estimated:!1}}return e.detail&&this.get("masterDetail")?this.getMasterDetailRowHeight():{height:this.gridOptions.rowHeight&&this.isNumeric(this.gridOptions.rowHeight)?this.gridOptions.rowHeight:i,estimated:!1}}getMasterDetailRowHeight(){return this.get("detailRowAutoHeight")?{height:1,estimated:!1}:this.isNumeric(this.gridOptions.detailRowHeight)?{height:this.gridOptions.detailRowHeight,estimated:!1}:{height:300,estimated:!1}}getRowHeightAsNumber(){if(!this.gridOptions.rowHeight||w(this.gridOptions.rowHeight))return this.environment.getDefaultRowHeight();const e=this.environment.refreshRowHeightVariable();return-1!==e?e:(console.warn("AG Grid row height must be a number if not using standard row model"),this.environment.getDefaultRowHeight())}isNumeric(e){return!isNaN(e)&&"number"==typeof e&&isFinite(e)}getDomDataKey(){return this.domDataKey}getDomData(e,t){const i=e[this.getDomDataKey()];return i?i[t]:void 0}setDomData(e,t,i){const r=this.getDomDataKey();let n=e[r];w(n)&&(n={},e[r]=n),n[t]=i}getDocument(){let e=null;return this.gridOptions.getDocument&&y(this.gridOptions.getDocument)?e=this.gridOptions.getDocument():this.eGridDiv&&(e=this.eGridDiv.ownerDocument),e&&y(e)?e:document}getWindow(){return this.getDocument().defaultView||window}getRootNode(){return this.eGridDiv.getRootNode()}getActiveDomElement(){return this.getRootNode().activeElement}getAsyncTransactionWaitMillis(){return y(this.gridOptions.asyncTransactionWaitMillis)?this.gridOptions.asyncTransactionWaitMillis:50}isAnimateRows(){return!this.get("ensureDomOrder")&&this.get("animateRows")}isGroupRowsSticky(){return!(this.get("paginateChildRows")||this.get("groupHideOpenParents")||this.isDomLayout("print"))}isColumnsSortingCoupledToGroup(){const e=this.gridOptions.autoGroupColumnDef;return!(null==e?void 0:e.comparator)&&!this.get("treeData")}getGroupAggFiltering(){const e=this.gridOptions.groupAggFiltering;return"function"==typeof e?this.getCallback("groupAggFiltering"):!0===e?()=>!0:void 0}getGrandTotalRow(){const e=this.gridOptions.grandTotalRow;return e||(this.gridOptions.groupIncludeTotalFooter?"bottom":void 0)}getGroupTotalRowCallback(){const e=this.get("groupTotalRow");if("function"==typeof e)return this.getCallback("groupTotalRow");if(e)return()=>e;const t=this.get("groupIncludeFooter");if("function"==typeof t){const e=this.getCallback("groupIncludeFooter");return t=>e(t)?"bottom":void 0}return()=>t?"bottom":void 0}isGroupMultiAutoColumn(){return this.gridOptions.groupDisplayType?"multipleColumns"===this.gridOptions.groupDisplayType:this.get("groupHideOpenParents")}isGroupUseEntireRow(e){return!e&&"groupRows"===this.gridOptions.groupDisplayType}getGridCommonParams(){return{api:this.api,columnApi:this.columnApi,context:this.context}}addGridCommonParams(e){const t=e;return t.api=this.api,t.columnApi=this.columnApi,t.context=this.context,t}};bu.PROPERTY_COERCIONS=new Map([...It.BOOLEAN_PROPERTIES.map(e=>[e,bu.toBoolean]),...It.NUMBER_PROPERTIES.map(e=>[e,bu.toNumber]),["groupAggFiltering",e=>"function"==typeof e?e:bu.toBoolean(e)],["pageSize",bu.toConstrainedNum(1,Number.MAX_VALUE)],["autoSizePadding",bu.toConstrainedNum(0,Number.MAX_VALUE)],["keepDetailRowsCount",bu.toConstrainedNum(1,Number.MAX_VALUE)],["rowBuffer",bu.toConstrainedNum(0,Number.MAX_VALUE)],["infiniteInitialRowCount",bu.toConstrainedNum(1,Number.MAX_VALUE)],["cacheOverflowSize",bu.toConstrainedNum(1,Number.MAX_VALUE)],["cacheBlockSize",bu.toConstrainedNum(1,Number.MAX_VALUE)],["serverSideInitialRowCount",bu.toConstrainedNum(1,Number.MAX_VALUE)],["viewportRowModelPageSize",bu.toConstrainedNum(1,Number.MAX_VALUE)],["viewportRowModelBufferSize",bu.toConstrainedNum(0,Number.MAX_VALUE)]]),bu.changeSetId=0,g([he("gridOptions")],bu.prototype,"gridOptions",2),g([he("eventService")],bu.prototype,"eventService",2),g([he("environment")],bu.prototype,"environment",2),g([he("frameworkOverrides")],bu.prototype,"frameworkOverrides",2),g([he("eGridDiv")],bu.prototype,"eGridDiv",2),g([he("validationService")],bu.prototype,"validationService",2),g([he("gridApi")],bu.prototype,"api",2),g([le],bu.prototype,"init",1),g([ce],bu.prototype,"destroy",1),bu=g([ue("gridOptionsService")],bu);var Eu=class extends nt{getLocaleTextFunc(){const e=this.gos.getCallback("getLocaleText");if(e)return(t,i,r)=>e({key:t,defaultValue:i,variableValues:r});const t=this.gos.get("localeText");return(e,i,r)=>{let n=t&&t[e];if(n&&r&&r.length){let e=0;for(;!(e>=r.length)&&-1!==n.indexOf("${variable}");)n=n.replace("${variable}",r[e++])}return null!=n?n:i}}};Eu=g([ue("localeService")],Eu);var Au=class e extends hu{constructor(){super(e.TEMPLATE,"vertical")}postConstruct(){super.postConstruct(),this.createManagedBean(new Ea(this.eContainer)),this.ctrlsService.register("fakeVScrollComp",this),this.addManagedListener(this.eventService,ct.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,this.onRowContainerHeightChanged.bind(this))}setScrollVisible(){const e=this.scrollVisibleService.isVerticalScrollShowing(),t=this.invisibleScrollbar,i=e&&this.gos.getScrollbarWidth()||0,r=0===i&&t?16:i;this.addOrRemoveCssClass("ag-scrollbar-invisible",t),Dr(this.getGui(),r),Dr(this.eViewport,r),Dr(this.eContainer,r),this.setDisplayed(e,{skipAriaHidden:!0})}onRowContainerHeightChanged(){const{ctrlsService:e}=this,t=e.getGridBodyCtrl().getBodyViewportElement(),i=this.getScrollPosition(),r=t.scrollTop;i!=r&&this.setScrollPosition(r,!0)}getScrollPosition(){return this.getViewport().scrollTop}setScrollPosition(e,t){t||br(this.getViewport())||this.attemptSettingScrollPosition(e),this.getViewport().scrollTop=e}};Au.TEMPLATE='<div class="ag-body-vertical-scroll" aria-hidden="true">\n            <div class="ag-body-vertical-scroll-viewport" ref="eViewport">\n                <div class="ag-body-vertical-scroll-container" ref="eContainer"></div>\n            </div>\n        </div>',g([le],Au.prototype,"postConstruct",1);var Tu=Au,Mu={january:"January",february:"February",march:"March",april:"April",may:"May",june:"June",july:"July",august:"August",september:"September",october:"October",november:"November",december:"December"},Ru=["january","february","march","april","may","june","july","august","september","october","november","december"],_u=class extends nt{constructor(){super(...arguments),this.dataTypeDefinitions={},this.isWaitingForRowData=!1,this.isColumnTypeOverrideInDataTypeDefinitions=!1,this.columnStateUpdatesPendingInference={},this.columnStateUpdateListenerDestroyFuncs=[]}init(){this.groupHideOpenParents=this.gos.get("groupHideOpenParents"),this.addManagedPropertyListener("groupHideOpenParents",()=>{this.groupHideOpenParents=this.gos.get("groupHideOpenParents")}),this.processDataTypeDefinitions(),this.addManagedPropertyListener("dataTypeDefinitions",e=>{this.processDataTypeDefinitions(),this.columnModel.recreateColumnDefs(Rt(e.source))})}processDataTypeDefinitions(){var e;const t=this.getDefaultDataTypes();this.dataTypeDefinitions={},Object.entries(t).forEach(([e,t])=>{this.dataTypeDefinitions[e]=d(h({},t),{groupSafeValueFormatter:this.createGroupSafeValueFormatter(t)})});const i=null!=(e=this.gos.get("dataTypeDefinitions"))?e:{};this.dataTypeMatchers={},Object.entries(i).forEach(([e,r])=>{const n=this.processDataTypeDefinition(r,i,[e],t);n&&(this.dataTypeDefinitions[e]=n,r.dataTypeMatcher&&(this.dataTypeMatchers[e]=r.dataTypeMatcher))}),this.checkObjectValueHandlers(t),["dateString","text","number","boolean","date"].forEach(e=>{const i=this.dataTypeMatchers[e];i&&delete this.dataTypeMatchers[e],this.dataTypeMatchers[e]=null!=i?i:t[e].dataTypeMatcher})}mergeDataTypeDefinitions(e,t){const i=h(h({},e),t);return e.columnTypes&&t.columnTypes&&t.appendColumnTypes&&(i.columnTypes=[...this.convertColumnTypes(e.columnTypes),...this.convertColumnTypes(t.columnTypes)]),i}processDataTypeDefinition(e,t,i,r){let n;const s=e.extendsDataType;if(e.columnTypes&&(this.isColumnTypeOverrideInDataTypeDefinitions=!0),e.extendsDataType===e.baseDataType){let i=r[s];const o=t[s];if(i&&o&&(i=o),!this.validateDataTypeDefinition(e,i,s))return;n=this.mergeDataTypeDefinitions(i,e)}else{if(i.includes(s))return void U('Data type definition hierarchies (via the "extendsDataType" property) cannot contain circular references.');const o=t[s];if(!this.validateDataTypeDefinition(e,o,s))return;const a=this.processDataTypeDefinition(o,t,[...i,s],r);if(!a)return;n=this.mergeDataTypeDefinitions(a,e)}return d(h({},n),{groupSafeValueFormatter:this.createGroupSafeValueFormatter(n)})}validateDataTypeDefinition(e,t,i){return t?t.baseDataType===e.baseDataType||(U('The "baseDataType" property of a data type definition must match that of its parent.'),!1):(U(`The data type definition ${i} does not exist.`),!1)}createGroupSafeValueFormatter(e){if(e.valueFormatter)return t=>{var i,r;if(null==(i=t.node)?void 0:i.group){const i=t.column.getAggFunc();if(i){if("first"===i||"last"===i)return e.valueFormatter(t);if("number"===e.baseDataType&&"count"!==i){if("number"==typeof t.value)return e.valueFormatter(t);if("object"==typeof t.value){if(!t.value)return;if("toNumber"in t.value)return e.valueFormatter(d(h({},t),{value:t.value.toNumber()}));if("value"in t.value)return e.valueFormatter(d(h({},t),{value:t.value.value}))}}}if(!this.gos.get("suppressGroupMaintainValueType"))return}else if(this.groupHideOpenParents&&t.column.isRowGroupActive()){if("string"!=typeof t.value||(null==(r=e.dataTypeMatcher)?void 0:r.call(e,t.value)))return e.valueFormatter(t);if(!this.gos.get("suppressGroupMaintainValueType"))return}return e.valueFormatter(t)}}updateColDefAndGetDataTypeDefinitionColumnType(e,t,i){let{cellDataType:r}=t;const{field:n}=t;if(void 0===r&&(r=e.cellDataType),null!=r&&!0!==r||(r=!!this.canInferCellDataType(e,t)&&this.inferCellDataType(n,i)),!r)return void(e.cellDataType=!1);const s=this.dataTypeDefinitions[r];if(s)return e.cellDataType=r,s.groupSafeValueFormatter&&(e.valueFormatter=s.groupSafeValueFormatter),s.valueParser&&(e.valueParser=s.valueParser),s.suppressDefaultProperties||this.setColDefPropertiesForBaseDataType(e,s,i),s.columnTypes;U(`Missing data type definition - "${r}"`)}updateColDefAndGetColumnType(e,t,i){var r,n;const s=this.updateColDefAndGetDataTypeDefinitionColumnType(e,t,i),o=null!=(n=null!=(r=t.type)?r:s)?n:e.type;return e.type=o,o?this.convertColumnTypes(o):void 0}addColumnListeners(e){if(!this.isWaitingForRowData)return;const t=this.columnStateUpdatesPendingInference[e.getColId()];if(!t)return;const i=e=>{t.add(e.key)};e.addEventListener(be.EVENT_STATE_UPDATED,i),this.columnStateUpdateListenerDestroyFuncs.push(()=>e.removeEventListener(be.EVENT_STATE_UPDATED,i))}canInferCellDataType(e,t){var i;if("clientSide"!==this.rowModel.getType())return!1;const r={cellRenderer:!0,valueGetter:!0,valueParser:!0,refData:!0};if(this.doColDefPropsPreventInference(t,r))return!1;const n=null===t.type?e.type:t.type;if(n){const e=null!=(i=this.gos.get("columnTypes"))?i:{};if(this.convertColumnTypes(n).some(t=>{const i=e[t.trim()];return i&&this.doColDefPropsPreventInference(i,r)}))return!1}return!this.doColDefPropsPreventInference(e,r)}doColDefPropsPreventInference(e,t){return[["cellRenderer","agSparklineCellRenderer"],["valueGetter",void 0],["valueParser",void 0],["refData",void 0]].some(([i,r])=>this.doesColDefPropPreventInference(e,t,i,r))}doesColDefPropPreventInference(e,t,i,r){if(!t[i])return!1;const n=e[i];return null===n?(t[i]=!1,!1):void 0===r?!!n:n===r}inferCellDataType(e,t){var i;if(!e)return;let r;const n=this.getInitialData();if(n){const t=e.indexOf(".")>=0&&!this.gos.get("suppressFieldDotNotation");r=k(n,e,t)}else this.initWaitForRowData(t);if(null==r)return;const[s]=null!=(i=Object.entries(this.dataTypeMatchers).find(([e,t])=>t(r)))?i:["object"];return s}getInitialData(){const e=this.gos.get("rowData");if(null==e?void 0:e.length)return e[0];if(this.initialData)return this.initialData;{const e=this.rowModel.getRootNode().allLeafChildren;if(null==e?void 0:e.length)return e[0].data}return null}initWaitForRowData(e){if(this.columnStateUpdatesPendingInference[e]=new Set,this.isWaitingForRowData)return;this.isWaitingForRowData=!0;const t=this.isColumnTypeOverrideInDataTypeDefinitions;t&&this.columnModel.queueResizeOperations();const i=this.addManagedListener(this.eventService,ct.EVENT_ROW_DATA_UPDATE_STARTED,e=>{const{firstRowData:r}=e;if(!r)return;null==i||i(),this.isWaitingForRowData=!1,this.processColumnsPendingInference(r,t),this.columnStateUpdatesPendingInference={},t&&this.columnModel.processResizeOperations();const n={type:ct.EVENT_DATA_TYPES_INFERRED};this.eventService.dispatchEvent(n)})}isPendingInference(){return this.isWaitingForRowData}processColumnsPendingInference(e,t){this.initialData=e;const i=[];this.columnStateUpdateListenerDestroyFuncs.forEach(e=>e()),this.columnStateUpdateListenerDestroyFuncs=[];const r={},n={};Object.entries(this.columnStateUpdatesPendingInference).forEach(([e,s])=>{const o=this.columnModel.getGridColumn(e);if(!o)return;const a=o.getColDef();if(!this.columnModel.resetColumnDefIntoColumn(o,"cellDataTypeInferred"))return;const l=o.getColDef();if(t&&l.type&&l.type!==a.type){const t=this.getUpdatedColumnState(o,s);t.rowGroup&&null==t.rowGroupIndex&&(r[e]=t),t.pivot&&null==t.pivotIndex&&(n[e]=t),i.push(t)}}),t&&i.push(...this.columnModel.generateColumnStateForRowGroupAndPivotIndexes(r,n)),i.length&&this.columnModel.applyColumnState({state:i},"cellDataTypeInferred"),this.initialData=null}getUpdatedColumnState(e,t){const i=this.columnModel.getColumnStateFromColDef(e);return t.forEach(e=>{delete i[e],"rowGroup"===e?delete i.rowGroupIndex:"pivot"===e&&delete i.pivotIndex}),i}checkObjectValueHandlers(e){const t=this.dataTypeDefinitions.object,i=e.object;this.hasObjectValueParser=t.valueParser!==i.valueParser,this.hasObjectValueFormatter=t.valueFormatter!==i.valueFormatter}convertColumnTypes(e){let t=[];return e instanceof Array?e.some(e=>"string"!=typeof e)?console.warn("if colDef.type is supplied an array it should be of type 'string[]'"):t=e:"string"==typeof e?t=e.split(","):console.warn("colDef.type should be of type 'string' | 'string[]'"),t}getDateStringTypeDefinition(e){var t;return e&&null!=(t=this.getDataTypeDefinition(e))?t:this.dataTypeDefinitions.dateString}getDateParserFunction(e){return this.getDateStringTypeDefinition(e).dateParser}getDateFormatterFunction(e){return this.getDateStringTypeDefinition(e).dateFormatter}getDataTypeDefinition(e){const t=e.getColDef();if(t.cellDataType)return this.dataTypeDefinitions[t.cellDataType]}getBaseDataType(e){var t;return null==(t=this.getDataTypeDefinition(e))?void 0:t.baseDataType}checkType(e,t){var i;if(null==t)return!0;const r=null==(i=this.getDataTypeDefinition(e))?void 0:i.dataTypeMatcher;return!r||r(t)}validateColDef(e){"object"===e.cellDataType&&(e.valueFormatter!==this.dataTypeDefinitions.object.groupSafeValueFormatter||this.hasObjectValueFormatter||U('Cell data type is "object" but no value formatter has been provided. Please either provide an object data type definition with a value formatter, or set "colDef.valueFormatter"'),e.editable&&e.valueParser===this.dataTypeDefinitions.object.valueParser&&!this.hasObjectValueParser&&U('Cell data type is "object" but no value parser has been provided. Please either provide an object data type definition with a value parser, or set "colDef.valueParser"'))}setColDefPropertiesForBaseDataType(e,t,i){const r=(e,i,r)=>{let n=e.getColDef().valueFormatter;return n===t.groupSafeValueFormatter&&(n=t.valueFormatter),this.valueService.formatValue(e,i,r,n)},n=se.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()),s=this.localeService.getLocaleTextFunc(),o=t=>{const{filterParams:i}=e;e.filterParams="object"==typeof i?h(h({},i),t):t};switch(t.baseDataType){case"number":e.cellEditor="agNumberCellEditor",n&&o({comparator:(e,t)=>{const i=null==e?0:parseInt(e),r=null==t?0:parseInt(t);return i===r?0:i>r?1:-1}});break;case"boolean":e.cellEditor="agCheckboxCellEditor",e.cellRenderer="agCheckboxCellRenderer",e.suppressKeyboardEvent=e=>!!e.colDef.editable&&e.event.key===Qr.SPACE,o(n?{valueFormatter:e=>y(e.value)?s(String(e.value),e.value?"True":"False"):s("blanks","(Blanks)")}:{maxNumConditions:1,debounceMs:0,filterOptions:["empty",{displayKey:"true",displayName:"True",predicate:(e,t)=>t,numberOfInputs:0},{displayKey:"false",displayName:"False",predicate:(e,t)=>!1===t,numberOfInputs:0}]});break;case"date":e.cellEditor="agDateCellEditor",e.keyCreator=e=>r(e.column,e.node,e.value),n&&o({valueFormatter:e=>{const t=r(e.column,e.node,e.value);return y(t)?t:s("blanks","(Blanks)")},treeList:!0,treeListFormatter:(e,t)=>{if(1===t&&null!=e){const t=Ru[Number(e)-1];return s(t,Mu[t])}return null!=e?e:s("blanks","(Blanks)")}});break;case"dateString":{e.cellEditor="agDateStringCellEditor",e.keyCreator=e=>r(e.column,e.node,e.value);const i=t.dateParser;o(n?{valueFormatter:e=>{const t=r(e.column,e.node,e.value);return y(t)?t:s("blanks","(Blanks)")},treeList:!0,treeListPathGetter:e=>{const t=i(null!=e?e:void 0);return t?[String(t.getFullYear()),String(t.getMonth()+1),String(t.getDate())]:null},treeListFormatter:(e,t)=>{if(1===t&&null!=e){const t=Ru[Number(e)-1];return s(t,Mu[t])}return null!=e?e:s("blanks","(Blanks)")}}:{comparator:(e,t)=>{const r=i(t);return null==t||r<e?-1:r>e?1:0}});break}case"object":e.cellEditorParams={useFormatter:!0},e.comparator=(e,t)=>{const n=this.columnModel.getPrimaryColumn(i),s=null==n?void 0:n.getColDef();if(!n||!s)return 0;const o=null==e?"":r(n,null,e),a=null==t?"":r(n,null,t);return o===a?0:o>a?1:-1},e.keyCreator=e=>r(e.column,e.node,e.value),n?o({valueFormatter:e=>{const t=r(e.column,e.node,e.value);return y(t)?t:s("blanks","(Blanks)")}}):e.filterValueGetter=e=>r(e.column,e.node,this.valueService.getValue(e.column,e.node))}}getDefaultDataTypes(){const e=e=>!!e.match("^\\d{4}-\\d{2}-\\d{2}$"),t=this.localeService.getLocaleTextFunc();return{number:{baseDataType:"number",valueParser:e=>{var t,i;return""===(null==(i=null==(t=e.newValue)?void 0:t.trim)?void 0:i.call(t))?null:Number(e.newValue)},valueFormatter:e=>null==e.value?"":"number"!=typeof e.value||isNaN(e.value)?t("invalidNumber","Invalid Number"):String(e.value),dataTypeMatcher:e=>"number"==typeof e},text:{baseDataType:"text",valueParser:e=>""===e.newValue?null:b(e.newValue),dataTypeMatcher:e=>"string"==typeof e},boolean:{baseDataType:"boolean",valueParser:e=>{var t,i;return null==e.newValue?e.newValue:""===(null==(i=null==(t=e.newValue)?void 0:t.trim)?void 0:i.call(t))?null:"true"===String(e.newValue).toLowerCase()},valueFormatter:e=>null==e.value?"":String(e.value),dataTypeMatcher:e=>"boolean"==typeof e},date:{baseDataType:"date",valueParser:e=>Ji(null==e.newValue?null:String(e.newValue)),valueFormatter:e=>{var i;return null==e.value?"":e.value instanceof Date&&!isNaN(e.value.getTime())?null!=(i=Qi(e.value,!1))?i:"":t("invalidDate","Invalid Date")},dataTypeMatcher:e=>e instanceof Date},dateString:{baseDataType:"dateString",dateParser:e=>{var t;return null!=(t=Ji(e))?t:void 0},dateFormatter:e=>{var t;return null!=(t=Qi(null!=e?e:null,!1))?t:void 0},valueParser:t=>e(String(t.newValue))?t.newValue:null,valueFormatter:t=>e(String(t.value))?t.value:"",dataTypeMatcher:t=>"string"==typeof t&&e(t)},object:{baseDataType:"object",valueParser:()=>null,valueFormatter:e=>{var t;return null!=(t=b(e.value))?t:""}}}}};g([he("rowModel")],_u.prototype,"rowModel",2),g([he("columnModel")],_u.prototype,"columnModel",2),g([he("valueService")],_u.prototype,"valueService",2),g([le],_u.prototype,"init",1),_u=g([ue("dataTypeService")],_u);var Pu=class extends nt{constructor(){super(...arguments),this.waitingForColumns=!1}postConstruct(){this.addManagedPropertyListener("columnDefs",e=>this.setColumnDefs(e))}start(){this.ctrlsService.whenReady(()=>{const e=this.gos.get("columnDefs");e?this.setColumnsAndData(e):this.waitingForColumns=!0,this.gridReady()})}setColumnsAndData(e){this.columnModel.setColumnDefs(null!=e?e:[],"gridInitializing"),this.rowModel.start()}gridReady(){this.dispatchGridReadyEvent();const e=se.__isRegistered("@ag-grid-enterprise/core",this.context.getGridId());new Ic("AG Grid",()=>this.gos.get("debug")).log(`initialised successfully, enterprise = ${e}`)}dispatchGridReadyEvent(){const e={type:ct.EVENT_GRID_READY};this.eventService.dispatchEvent(e)}setColumnDefs(e){const t=this.gos.get("columnDefs");if(t)return this.waitingForColumns?(this.waitingForColumns=!1,void this.setColumnsAndData(t)):void this.columnModel.setColumnDefs(t,Rt(e.source))}};g([he("ctrlsService")],Pu.prototype,"ctrlsService",2),g([he("columnModel")],Pu.prototype,"columnModel",2),g([he("rowModel")],Pu.prototype,"rowModel",2),g([le],Pu.prototype,"postConstruct",1),Pu=g([ue("syncService")],Pu);var xu=class extends nt{constructor(){super(...arguments),this.manuallyDisplayed=!1}postConstruct(){this.addManagedListener(this.eventService,ct.EVENT_ROW_DATA_UPDATED,()=>this.onRowDataUpdated()),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.onNewColumnsLoaded())}registerOverlayWrapperComp(e){this.overlayWrapperComp=e,(!this.gos.get("columnDefs")||this.gos.isRowModelType("clientSide")&&!this.gos.get("rowData"))&&this.showLoadingOverlay()}showLoadingOverlay(){if(this.gos.get("suppressLoadingOverlay"))return;const e=this.userComponentFactory.getLoadingOverlayCompDetails({});this.showOverlay(e,"ag-overlay-loading-wrapper","loadingOverlayComponentParams")}showNoRowsOverlay(){if(this.gos.get("suppressNoRowsOverlay"))return;const e=this.userComponentFactory.getNoRowsOverlayCompDetails({});this.showOverlay(e,"ag-overlay-no-rows-wrapper","noRowsOverlayComponentParams")}showOverlay(e,t,i){const r=e.newAgStackInstance(),n=this.addManagedPropertyListener(i,({currentValue:e})=>{r.then(t=>{t.refresh&&t.refresh(this.gos.addGridCommonParams(h({},null!=e?e:{})))})});this.manuallyDisplayed=this.columnModel.isReady()&&!this.paginationProxy.isEmpty(),this.overlayWrapperComp.showOverlay(r,t,n)}hideOverlay(){this.manuallyDisplayed=!1,this.overlayWrapperComp.hideOverlay()}showOrHideOverlay(){const e=this.paginationProxy.isEmpty(),t=this.gos.get("suppressNoRowsOverlay");e&&!t?this.showNoRowsOverlay():this.hideOverlay()}onRowDataUpdated(){this.showOrHideOverlay()}onNewColumnsLoaded(){!this.columnModel.isReady()||this.paginationProxy.isEmpty()||this.manuallyDisplayed||this.hideOverlay()}};g([he("userComponentFactory")],xu.prototype,"userComponentFactory",2),g([he("paginationProxy")],xu.prototype,"paginationProxy",2),g([he("columnModel")],xu.prototype,"columnModel",2),g([le],xu.prototype,"postConstruct",1),xu=g([ue("overlayService")],xu);var Du=class extends nt{constructor(){super(...arguments),this.suppressEvents=!0,this.queuedUpdateSources=new Set,this.dispatchStateUpdateEventDebounced=Z(()=>this.dispatchQueuedStateUpdateEvents(),0),this.onRowGroupOpenedDebounced=Z(()=>this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState()),0),this.onRowSelectedDebounced=Z(()=>{this.staleStateKeys.delete("rowSelection"),this.updateCachedState("rowSelection",this.getRowSelectionState())},0),this.staleStateKeys=new Set}postConstruct(){var e;this.isClientSideRowModel="clientSide"===this.rowModel.getType(),this.cachedState=null!=(e=this.gos.get("initialState"))?e:{},this.ctrlsService.whenReady(()=>this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnGridReady()));const t=this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,({source:e})=>{"gridInitializing"===e&&(null==t||t(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnColumnsInitialised()))}),i=this.addManagedListener(this.eventService,ct.EVENT_ROW_COUNT_READY,()=>{null==i||i(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnRowCountReady())}),r=this.addManagedListener(this.eventService,ct.EVENT_FIRST_DATA_RENDERED,()=>{null==r||r(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnFirstDataRendered())})}getState(){return this.staleStateKeys.size&&this.refreshStaleState(),this.cachedState}setupStateOnGridReady(){this.updateCachedState("sideBar",this.getSideBarState()),this.addManagedListener(this.eventService,ct.EVENT_TOOL_PANEL_VISIBLE_CHANGED,()=>this.updateCachedState("sideBar",this.getSideBarState())),this.addManagedListener(this.eventService,ct.EVENT_SIDE_BAR_UPDATED,()=>this.updateCachedState("sideBar",this.getSideBarState()))}setupStateOnColumnsInitialised(){var e;const t=null!=(e=this.gos.get("initialState"))?e:{};this.setColumnState(t),this.setColumnGroupState(t),this.updateColumnState(["aggregation","columnOrder","columnPinning","columnSizing","columnVisibility","pivot","pivot","rowGroup","sort"]),this.updateCachedState("columnGroup",this.getColumnGroupState()),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VALUE_CHANGED,()=>this.updateColumnState(["aggregation"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_MOVED,()=>this.updateColumnState(["columnOrder"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PINNED,()=>this.updateColumnState(["columnPinning"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_RESIZED,()=>this.updateColumnState(["columnSizing"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VISIBLE,()=>this.updateColumnState(["columnVisibility"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_CHANGED,()=>this.updateColumnState(["pivot"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.updateColumnState(["pivot"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.updateColumnState(["rowGroup"])),this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,()=>this.updateColumnState(["sort"])),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,()=>this.updateColumnState(["aggregation","columnOrder","columnPinning","columnSizing","columnVisibility","pivot","pivot","rowGroup","sort"])),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_GROUP_OPENED,()=>this.updateCachedState("columnGroup",this.getColumnGroupState()))}setupStateOnRowCountReady(){var e;const{filter:t,rowGroupExpansion:i,rowSelection:r,pagination:n}=null!=(e=this.gos.get("initialState"))?e:{},s=this.gos.get("advancedFilterModel");(t||s)&&this.setFilterState(t,s),i&&this.setRowGroupExpansionState(i),r&&this.setRowSelectionState(r),n&&this.setPaginationState(n),this.updateCachedState("filter",this.getFilterState()),this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState()),this.updateCachedState("rowSelection",this.getRowSelectionState()),this.updateCachedState("pagination",this.getPaginationState()),this.addManagedListener(this.eventService,ct.EVENT_FILTER_CHANGED,()=>this.updateCachedState("filter",this.getFilterState())),this.addManagedListener(this.eventService,ct.EVENT_ROW_GROUP_OPENED,()=>this.onRowGroupOpenedDebounced()),this.addManagedListener(this.eventService,ct.EVENT_EXPAND_COLLAPSE_ALL,()=>this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState())),this.addManagedListener(this.eventService,ct.EVENT_SELECTION_CHANGED,()=>{this.staleStateKeys.add("rowSelection"),this.onRowSelectedDebounced()}),this.addManagedListener(this.eventService,ct.EVENT_PAGINATION_CHANGED,e=>{(e.newPage||e.newPageSize)&&this.updateCachedState("pagination",this.getPaginationState())})}setupStateOnFirstDataRendered(){var e;const{scroll:t,rangeSelection:i,focusedCell:r,columnOrder:n}=null!=(e=this.gos.get("initialState"))?e:{};r&&this.setFocusedCellState(r),i&&this.setRangeSelectionState(i),t&&this.setScrollState(t),this.setColumnPivotState(!!(null==n?void 0:n.orderedColIds)),this.updateCachedState("sideBar",this.getSideBarState()),this.updateCachedState("focusedCell",this.getFocusedCellState()),this.updateCachedState("rangeSelection",this.getRangeSelectionState()),this.updateCachedState("scroll",this.getScrollState()),this.addManagedListener(this.eventService,ct.EVENT_CELL_FOCUSED,()=>this.updateCachedState("focusedCell",this.getFocusedCellState())),this.addManagedListener(this.eventService,ct.EVENT_RANGE_SELECTION_CHANGED,e=>{e.finished&&this.updateCachedState("rangeSelection",this.getRangeSelectionState())}),this.addManagedListener(this.eventService,ct.EVENT_BODY_SCROLL_END,()=>this.updateCachedState("scroll",this.getScrollState()))}getColumnState(){const e=this.columnModel.isPivotMode(),t=[],i=[],r=[],n=[],s=[],o=[],a=[],l=[],c=[],u=this.columnModel.getColumnState();for(let e=0;e<u.length;e++){const{colId:h,sort:d,sortIndex:p,rowGroup:g,rowGroupIndex:f,aggFunc:m,pivot:v,pivotIndex:C,pinned:y,hide:w,width:S,flex:b}=u[e];c.push(h),d&&(t[null!=p?p:0]={colId:h,sort:d}),g&&(i[null!=f?f:0]=h),"string"==typeof m&&r.push({colId:h,aggFunc:m}),v&&(n[null!=C?C:0]=h),y&&("right"===y?o:s).push(h),w&&a.push(h),(b||S)&&l.push({colId:h,flex:null!=b?b:void 0,width:S})}return{sort:t.length?{sortModel:t}:void 0,rowGroup:i.length?{groupColIds:i}:void 0,aggregation:r.length?{aggregationModel:r}:void 0,pivot:n.length||e?{pivotMode:e,pivotColIds:n}:void 0,columnPinning:s.length||o.length?{leftColIds:s,rightColIds:o}:void 0,columnVisibility:a.length?{hiddenColIds:a}:void 0,columnSizing:l.length?{columnSizingModel:l}:void 0,columnOrder:c.length?{orderedColIds:c}:void 0}}setColumnState(e){const{sort:t,rowGroup:i,aggregation:r,pivot:n,columnPinning:s,columnVisibility:o,columnSizing:a,columnOrder:l}=e,c={},u=e=>{let t=c[e];return t||(t={colId:e},c[e]=t,t)};t&&t.sortModel.forEach(({colId:e,sort:t},i)=>{const r=u(e);r.sort=t,r.sortIndex=i}),i&&i.groupColIds.forEach((e,t)=>{const i=u(e);i.rowGroup=!0,i.rowGroupIndex=t}),r&&r.aggregationModel.forEach(({colId:e,aggFunc:t})=>{u(e).aggFunc=t}),n&&(n.pivotColIds.forEach((e,t)=>{const i=u(e);i.pivot=!0,i.pivotIndex=t}),this.gos.updateGridOptions({options:{pivotMode:n.pivotMode},source:"gridInitializing"})),s&&(s.leftColIds.forEach(e=>{u(e).pinned="left"}),s.rightColIds.forEach(e=>{u(e).pinned="right"})),o&&o.hiddenColIds.forEach(e=>{u(e).hide=!0}),a&&a.columnSizingModel.forEach(({colId:e,flex:t,width:i})=>{const r=u(e);r.flex=null!=t?t:null,r.width=i});const h=null==l?void 0:l.orderedColIds,d=!!(null==h?void 0:h.length),p=d?h.map(e=>u(e)):Object.values(c);if(p.length){this.columnStates=p;const e={sort:null,sortIndex:null,rowGroup:null,rowGroupIndex:null,aggFunc:null,pivot:null,pivotIndex:null,pinned:null,hide:null,flex:null};this.columnModel.applyColumnState({state:p,applyOrder:d,defaultState:e},"gridInitializing")}}setColumnPivotState(e){const t=this.columnStates;this.columnStates=void 0;const i=this.columnGroupStates;if(this.columnGroupStates=void 0,this.columnModel.isSecondaryColumnsPresent()){if(t){let i=[];for(const e of t)this.columnModel.getSecondaryColumn(e.colId)&&i.push(e);this.columnModel.applyColumnState({state:i,applyOrder:e},"gridInitializing")}i&&this.columnModel.setColumnGroupState(i,"gridInitializing")}}getColumnGroupState(){const e=this.columnModel.getColumnGroupState(),t=[];return e.forEach(({groupId:e,open:i})=>{i&&t.push(e)}),t.length?{openColumnGroupIds:t}:void 0}setColumnGroupState(e){var t;if(!e.hasOwnProperty("columnGroup"))return;const i=new Set(null==(t=e.columnGroup)?void 0:t.openColumnGroupIds),r=this.columnModel.getColumnGroupState().map(({groupId:e})=>{const t=i.has(e);return t&&i.delete(e),{groupId:e,open:t}});i.forEach(e=>{r.push({groupId:e,open:!0})}),r.length&&(this.columnGroupStates=r),this.columnModel.setColumnGroupState(r,"gridInitializing")}getFilterState(){var e;let t=this.filterManager.getFilterModel();t&&0===Object.keys(t).length&&(t=void 0);const i=null!=(e=this.filterManager.getAdvancedFilterModel())?e:void 0;return t||i?{filterModel:t,advancedFilterModel:i}:void 0}setFilterState(e,t){const{filterModel:i,advancedFilterModel:r}=null!=e?e:{advancedFilterModel:t};i&&this.filterManager.setFilterModel(i,"columnFilter"),r&&this.filterManager.setAdvancedFilterModel(r)}getRangeSelectionState(){var e;const t=null==(e=this.rangeService)?void 0:e.getCellRanges().map(e=>{const{id:t,type:i,startRow:r,endRow:n,columns:s,startColumn:o}=e;return{id:t,type:i,startRow:r,endRow:n,colIds:s.map(e=>e.getColId()),startColId:o.getColId()}});return(null==t?void 0:t.length)?{cellRanges:t}:void 0}setRangeSelectionState(e){if(!this.gos.get("enableRangeSelection")||!this.rangeService)return;const t=[];e.cellRanges.forEach(e=>{const i=[];if(e.colIds.forEach(e=>{const t=this.columnModel.getGridColumn(e);t&&i.push(t)}),!i.length)return;let r=this.columnModel.getGridColumn(e.startColId);if(!r){const e=this.columnModel.getAllDisplayedColumns(),t=new Set(i);r=e.find(e=>t.has(e))}t.push(d(h({},e),{columns:i,startColumn:r}))}),this.rangeService.setCellRanges(t)}getScrollState(){var e,t,i;if(!this.isClientSideRowModel)return;const r=null==(e=this.ctrlsService.getGridBodyCtrl())?void 0:e.getScrollFeature(),{left:n}=null!=(t=null==r?void 0:r.getHScrollPosition())?t:{left:0},{top:s}=null!=(i=null==r?void 0:r.getVScrollPosition())?i:{top:0};return s||n?{top:s,left:n}:void 0}setScrollState(e){var t;if(!this.isClientSideRowModel)return;const{top:i,left:r}=e;null==(t=this.ctrlsService.getGridBodyCtrl())||t.getScrollFeature().setScrollPosition(i,r)}getSideBarState(){var e,t;return null==(t=null==(e=this.sideBarService)?void 0:e.getSideBarComp())?void 0:t.getState()}getFocusedCellState(){if(!this.isClientSideRowModel)return;const e=this.focusService.getFocusedCell();if(e){const{column:t,rowIndex:i,rowPinned:r}=e;return{colId:t.getColId(),rowIndex:i,rowPinned:r}}}setFocusedCellState(e){if(!this.isClientSideRowModel)return;const{colId:t,rowIndex:i,rowPinned:r}=e;this.focusService.setFocusedCell({column:this.columnModel.getGridColumn(t),rowIndex:i,rowPinned:r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}getPaginationState(){const e=this.paginationProxy.getCurrentPage(),t=this.gos.get("paginationAutoPageSize")?void 0:this.paginationProxy.getPageSize();if(e||t)return{page:e,pageSize:t}}setPaginationState(e){e.pageSize&&!this.gos.get("paginationAutoPageSize")&&this.paginationProxy.setPageSize(e.pageSize,"initialState"),"number"==typeof e.page&&this.paginationProxy.setPage(e.page)}getRowSelectionState(){var e;const t=this.selectionService.getSelectionState();return t&&(Array.isArray(t)||!1!==t.selectAll&&!1!==t.selectAllChildren||(null==(e=null==t?void 0:t.toggledNodes)?void 0:e.length))?t:void 0}setRowSelectionState(e){this.selectionService.setSelectionState(e,"gridInitializing")}getRowGroupExpansionState(){const e=this.expansionService.getExpandedRows();return e.length?{expandedRowGroupIds:e}:void 0}setRowGroupExpansionState(e){this.expansionService.expandRows(e.expandedRowGroupIds)}updateColumnState(e){const t=this.getColumnState();let i=!1;Object.entries(t).forEach(([e,t])=>{M(t,this.cachedState[e])||(i=!0)}),this.cachedState=h(h({},this.cachedState),t),i&&this.dispatchStateUpdateEvent(e)}updateCachedState(e,t){const i=this.cachedState[e];this.setCachedStateValue(e,t),M(t,i)||this.dispatchStateUpdateEvent([e])}setCachedStateValue(e,t){this.cachedState=d(h({},this.cachedState),{[e]:t})}refreshStaleState(){this.staleStateKeys.forEach(e=>{"rowSelection"===e&&this.setCachedStateValue(e,this.getRowSelectionState())}),this.staleStateKeys.clear()}dispatchStateUpdateEvent(e){this.suppressEvents||(e.forEach(e=>this.queuedUpdateSources.add(e)),this.dispatchStateUpdateEventDebounced())}dispatchQueuedStateUpdateEvents(){const e=Array.from(this.queuedUpdateSources);this.queuedUpdateSources.clear();const t={type:ct.EVENT_STATE_UPDATED,sources:e,state:this.cachedState};this.eventService.dispatchEvent(t)}suppressEventsAndDispatchInitEvent(e){this.suppressEvents=!0,this.columnAnimationService.setSuppressAnimation(!0),e(),setTimeout(()=>{this.suppressEvents=!1,this.queuedUpdateSources.clear(),this.isAlive()&&(this.columnAnimationService.setSuppressAnimation(!1),this.dispatchStateUpdateEvent(["gridInitializing"]))})}};g([he("filterManager")],Du.prototype,"filterManager",2),g([he("ctrlsService")],Du.prototype,"ctrlsService",2),g([he("focusService")],Du.prototype,"focusService",2),g([he("columnModel")],Du.prototype,"columnModel",2),g([he("paginationProxy")],Du.prototype,"paginationProxy",2),g([he("rowModel")],Du.prototype,"rowModel",2),g([he("selectionService")],Du.prototype,"selectionService",2),g([he("expansionService")],Du.prototype,"expansionService",2),g([he("columnAnimationService")],Du.prototype,"columnAnimationService",2),g([de("sideBarService")],Du.prototype,"sideBarService",2),g([de("rangeService")],Du.prototype,"rangeService",2),g([le],Du.prototype,"postConstruct",1),Du=g([ue("stateService")],Du);var Iu=class extends nt{init(){this.processGridOptions(this.gridOptions)}processGridOptions(e){this.processOptions(e,Su)}processColumnDefs(e){this.processOptions(e,Cu)}processOptions(e,t){const{validations:i,deprecations:r,allProperties:n,propertyExceptions:s,objectName:o,docsUrl:a}=t;n&&!0!==this.gridOptions.suppressPropertyNamesCheck&&this.checkProperties(e,[...null!=s?s:[],...Object.keys(r)],n,o,a);const l=new Set;Object.keys(e).forEach(t=>{var n;const s=r[t];if(s)if("renamed"in s){const{renamed:i,version:r}=s;l.add(`As of v${r}, ${String(t)} is deprecated. Please use ${String(i)} instead.`),e[i]=e[t]}else{const{message:e,version:i}=s;l.add(`As of v${i}, ${String(t)} is deprecated. ${null!=e?e:""}`)}const o=e[t];if(null==o||!1===o)return;const a=i[t];let c;if(!a)return;if("function"==typeof a){const i=a(e,this.gridOptions);if(!i)return;if("objectName"in i){const r=e[t];return Array.isArray(r)?void r.forEach(e=>{this.processOptions(e,i)}):void this.processOptions(e[t],i)}c=i}else c=a;const{module:u,dependencies:h,supportedRowModels:d}=c;if(d){const e=null!=(n=this.gridOptions.rowModelType)?n:"clientSide";if(!d.includes(e))return void l.add(`${String(t)} is not supported with the '${e}' row model.`)}if(u){const e=Array.isArray(u)?u:[u];let i=!0;if(e.forEach(e=>{se.__assertRegistered(e,String(t),this.context.getGridId())||(i=!1,l.add(`${String(t)} is only available when ${e} is loaded.`))}),!i)return}if(h){const i=this.checkForWarning(t,h,e);if(i)return void l.add(i)}}),l.size>0&&l.forEach(e=>{U(e)})}checkForWarning(e,t,i){if("function"==typeof t)return t(i,this.gridOptions);const r=Object.entries(t).find(([e,t])=>{const r=i[e];return!t.includes(r)});if(!r)return null;const[n,s]=r;return s.length>1?`'${String(e)}' requires '${n}' to be one of [${s.join(", ")}].`:`'${String(e)}' requires '${n}' to be ${s[0]}.`}checkProperties(e,t,i,r,n){const s=zr(Object.getOwnPropertyNames(e),["__ob__","__v_skip","__metadata__",...t,...i],i);if(I(s,(e,t)=>{U(`invalid ${r} property '${e}' did you mean any of these: ${t.slice(0,8).join(", ")}`)}),Object.keys(s).length>0&&n){const e=this.getFrameworkOverrides().getDocLink(n);U(`to see all the valid ${r} properties please check: ${e}`)}}};g([he("gridOptions")],Iu.prototype,"gridOptions",2),g([le],Iu.prototype,"init",1),Iu=g([ue("validationService")],Iu);var Lu=class extends nt{constructor(){super(...arguments),this.syncEventListeners=new Map,this.asyncEventListeners=new Map,this.syncGlobalEventListeners=new Set,this.globalEventListenerPairs=new Map}postConstruct(){this.frameworkEventWrappingService=new ve(this.getFrameworkOverrides())}addEventListener(e,t){const i=this.frameworkEventWrappingService.wrap(t),r=this.gos.useAsyncEvents()&&!ut.has(e),n=r?this.asyncEventListeners:this.syncEventListeners;n.has(e)||n.set(e,new Set),n.get(e).add(i),this.eventService.addEventListener(e,i,r)}removeEventListener(e,t){var i;const r=this.frameworkEventWrappingService.unwrap(t),n=this.asyncEventListeners.get(e),s=!!(null==n?void 0:n.delete(r));s||null==(i=this.syncEventListeners.get(e))||i.delete(r),this.eventService.removeEventListener(e,r,s)}addGlobalListener(e){const t=this.frameworkEventWrappingService.wrapGlobal(e);if(this.gos.useAsyncEvents()){const i=(e,i)=>{ut.has(e)&&t(e,i)},r=(e,i)=>{ut.has(e)||t(e,i)};this.globalEventListenerPairs.set(e,{syncListener:i,asyncListener:r}),this.eventService.addGlobalListener(i,!1),this.eventService.addGlobalListener(r,!0)}else this.syncGlobalEventListeners.add(t),this.eventService.addGlobalListener(t,!1)}removeGlobalListener(e){const t=this.frameworkEventWrappingService.unwrapGlobal(e);if(this.globalEventListenerPairs.has(t)){const{syncListener:i,asyncListener:r}=this.globalEventListenerPairs.get(t);this.eventService.removeGlobalListener(i,!1),this.eventService.removeGlobalListener(r,!0),this.globalEventListenerPairs.delete(e)}else this.syncGlobalEventListeners.delete(t),this.eventService.removeGlobalListener(t,!1)}destroyEventListeners(e,t){e.forEach((e,i)=>{e.forEach(e=>this.eventService.removeEventListener(i,e,t)),e.clear()}),e.clear()}destroyGlobalListeners(e,t){e.forEach(e=>this.eventService.removeGlobalListener(e,t)),e.clear()}destroy(){super.destroy(),this.destroyEventListeners(this.syncEventListeners,!1),this.destroyEventListeners(this.asyncEventListeners,!0),this.destroyGlobalListeners(this.syncGlobalEventListeners,!1),this.globalEventListenerPairs.forEach(({syncListener:e,asyncListener:t})=>{this.eventService.removeGlobalListener(e,!1),this.eventService.removeGlobalListener(t,!0)}),this.globalEventListenerPairs.clear()}};g([le],Lu.prototype,"postConstruct",1),Lu=g([ue("apiEventService")],Lu);var Nu=class extends wn{constructor(){super('<span class="ag-paging-page-size"></span>'),this.hasEmptyOption=!1,this.handlePageSizeItemSelected=()=>{if(!this.selectPageSizeComp)return;const e=this.selectPageSizeComp.getValue();if(!e)return;const t=Number(e);isNaN(t)||t<1||t===this.paginationProxy.getPageSize()||(this.paginationProxy.setPageSize(t,"pageSizeSelector"),this.hasEmptyOption&&this.toggleSelectDisplay(!0),this.selectPageSizeComp.getFocusableElement().focus())}}init(){this.addManagedPropertyListener("paginationPageSizeSelector",()=>{this.onPageSizeSelectorValuesChange()}),this.addManagedListener(this.eventService,ct.EVENT_PAGINATION_CHANGED,e=>this.handlePaginationChanged(e))}handlePaginationChanged(e){if(!this.selectPageSizeComp||!(null==e?void 0:e.newPageSize))return;const t=this.paginationProxy.getPageSize();this.getPageSizeSelectorValues().includes(t)?this.selectPageSizeComp.setValue(t.toString()):this.hasEmptyOption?this.selectPageSizeComp.setValue(""):this.toggleSelectDisplay(!0)}toggleSelectDisplay(e){this.selectPageSizeComp&&this.reset(),e&&(this.reloadPageSizesSelector(),this.selectPageSizeComp&&this.appendChild(this.selectPageSizeComp))}reset(){yr(this.getGui()),this.selectPageSizeComp&&(this.destroyBean(this.selectPageSizeComp),this.selectPageSizeComp=void 0)}onPageSizeSelectorValuesChange(){this.selectPageSizeComp&&this.shouldShowPageSizeSelector()&&this.reloadPageSizesSelector()}shouldShowPageSizeSelector(){return this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel")&&!this.gos.get("paginationAutoPageSize")&&!1!==this.gos.get("paginationPageSizeSelector")}reloadPageSizesSelector(){const e=this.getPageSizeSelectorValues(),t=this.paginationProxy.getPageSize(),i=!t||!e.includes(t);i&&(e.unshift(""),U("The paginationPageSize grid option is set to a value that is not in the list of page size options.\n                Please make sure that the paginationPageSize grid option is set to one of the values in the \n                paginationPageSizeSelector array, or set the paginationPageSizeSelector to false to hide the page size selector.")),this.selectPageSizeComp&&(this.destroyBean(this.selectPageSizeComp),this.selectPageSizeComp=void 0);const r=this.localeService.getLocaleTextFunc(),n=r("pageSizeSelectorLabel","Page Size:"),s=e.map(e=>({value:String(e),text:String(e)})),o=r("ariaPageSizeSelectorLabel","Page Size");this.selectPageSizeComp=this.createManagedBean(new Bn).addOptions(s).setValue(String(i?"":t)).setAriaLabel(o).setLabel(n).onValueChange(()=>this.handlePageSizeItemSelected()),this.hasEmptyOption=i}getPageSizeSelectorValues(){const e=this.gos.get("paginationPageSizeSelector");return Array.isArray(e)&&this.validateValues(e)?[...e].sort((e,t)=>e-t):[20,50,100]}validateValues(e){if(!e.length)return U("The paginationPageSizeSelector grid option is an empty array. This is most likely a mistake.\n                If you want to hide the page size selector, please set the paginationPageSizeSelector to false."),!1;for(let t=0;t<e.length;t++){const i=e[t],r=i>0;if("number"!=typeof i)return U("The paginationPageSizeSelector grid option contains a non-numeric value.\n                    Please make sure that all values in the paginationPageSizeSelector array are numbers."),!1;if(!r)return U("The paginationPageSizeSelector grid option contains a negative number or zero.\n                    Please make sure that all values in the paginationPageSizeSelector array are positive."),!1}return!0}destroy(){this.toggleSelectDisplay(!1),super.destroy()}};g([he("paginationProxy")],Nu.prototype,"paginationProxy",2),g([le],Nu.prototype,"init",1);var Ou=class extends nt{constructor(){super(),this.descriptionContainer=null,this.announceValue=Z(this.announceValue.bind(this),200)}postConstruct(){const e=this.gos.getDocument(),t=this.descriptionContainer=e.createElement("div");t.classList.add("ag-aria-description-container"),Yt(t,"polite"),Xt(t,"additions text"),Qt(t,!0),this.eGridDiv.appendChild(t)}announceValue(e){this.descriptionContainer&&(this.descriptionContainer.textContent="",setTimeout(()=>{this.isAlive()&&this.descriptionContainer&&(this.descriptionContainer.textContent=e)},50))}destroy(){super.destroy();const{descriptionContainer:e}=this;e&&(yr(e),e.parentElement&&e.parentElement.removeChild(e)),this.descriptionContainer=null,this.eGridDiv=null}};g([he("eGridDiv")],Ou.prototype,"eGridDiv",2),g([le],Ou.prototype,"postConstruct",1),Ou=g([ue("ariaAnnouncementService")],Ou);var Fu=class{};function ku(e){Fu.gridOptions=e}function Gu(e,t,i){if(!t)return W("No gridOptions provided to createGrid"),{};const r=(new Bu).create(e,t,t=>{const i=new Nc(e);t.createBean(i)},void 0,i);if(!Object.isFrozen(t)&&!(null==i?void 0:i.frameworkOverrides)){const e="https://ag-grid.com/javascript-data-grid/grid-interface/#grid-api";Object.defineProperty(t,"api",{get:()=>{W(`gridOptions.api is no longer supported. See ${e}.`)},configurable:!0}),Object.defineProperty(t,"columnApi",{get:()=>{W(`gridOptions.columnApi is no longer supported and all methods moved to the grid api. See ${e}.`)},configurable:!0})}return r}Fu.gridOptions=void 0;var Vu=class{constructor(e,t,i){if(U("Since v31 new Grid(...) is deprecated. Use createGrid instead: `const gridApi = createGrid(...)`. The grid api is returned from createGrid and will not be available on gridOptions."),!t)return void W("No gridOptions provided to the grid");this.gridOptions=t;const r=(new Bu).create(e,t,t=>{const i=new Nc(e);t.createBean(i).addDestroyFunc(()=>{this.destroy()})},void 0,i);this.gridOptions.api=r,this.gridOptions.columnApi=new _c(r)}destroy(){var e;this.gridOptions&&(null==(e=this.gridOptions.api)||e.destroy(),delete this.gridOptions.api,delete this.gridOptions.columnApi)}},Hu=1,Bu=class{create(e,t,i,r,n){var s;let o={};Fu.gridOptions?(F(o,Fu.gridOptions,!0,!0),o=h(h({},o),t)):o=t;const a=bu.getCoercedGridOptions(o),l=!!a.debug,c=null!=(s=a.gridId)?s:String(Hu++),u=this.getRegisteredModules(n,c),d=this.createBeansList(a.rowModelType,u,c),p=this.createProvidedBeans(e,a,n);if(!d)return void W("Failed to create grid.");const g={providedBeanInstances:p,beanClasses:d,debug:l,gridId:c},f=new Ic("Context",()=>g.debug),m=new oe(g,f),v=m.getBean("beans");return this.registerModuleUserComponents(v,u),this.registerStackComponents(v,u),this.registerControllers(v,u),i(m),v.syncService.start(),r&&r(m),m.getBean("gridApi")}registerControllers(e,t){t.forEach(t=>{t.controllers&&t.controllers.forEach(t=>e.ctrlsFactory.register(t))})}registerStackComponents(e,t){const i=this.createAgStackComponentsList(t);e.agStackComponentsRegistry.setupComponents(i)}getRegisteredModules(e,t){const i=e?e.modules:null,r=se.__getRegisteredModules(t),n=[],s={},o=(e,t,i)=>{var r;s[(r=t).moduleName]||(s[r.moduleName]=!0,n.push(r),se.__register(r,e,i)),t.dependantModules&&t.dependantModules.forEach(t=>o(e,t,i))};return i&&i.forEach(e=>o(!0,e,t)),r&&r.forEach(e=>o(!se.__isPackageBased(),e,void 0)),n}registerModuleUserComponents(e,t){this.extractModuleEntity(t,e=>e.userComponents?e.userComponents:[]).forEach(t=>{e.userComponentRegistry.registerDefaultComponent(t.componentName,t.componentClass)})}createProvidedBeans(e,t,i){let r=i?i.frameworkOverrides:null;w(r)&&(r=new Ac);const n={gridOptions:t,eGridDiv:e,globalEventListener:i?i.globalEventListener:null,globalSyncEventListener:i?i.globalSyncEventListener:null,frameworkOverrides:r};return i&&i.providedBeanInstances&&Object.assign(n,i.providedBeanInstances),n}createAgStackComponentsList(e){let t=[{componentName:"AgCheckbox",componentClass:Un},{componentName:"AgRadioButton",componentClass:Wn},{componentName:"AgToggleButton",componentClass:Wl},{componentName:"AgInputTextField",componentClass:is},{componentName:"AgInputTextArea",componentClass:jl},{componentName:"AgInputNumberField",componentClass:rs},{componentName:"AgInputDateField",componentClass:Kl},{componentName:"AgInputRange",componentClass:$l},{componentName:"AgRichSelect",componentClass:Xl},{componentName:"AgSelect",componentClass:Bn},{componentName:"AgSlider",componentClass:Jl},{componentName:"AgGridBody",componentClass:La},{componentName:"AgHeaderRoot",componentClass:yl},{componentName:"AgSortIndicator",componentClass:ys},{componentName:"AgPagination",componentClass:Yc},{componentName:"AgPageSizeSelector",componentClass:Nu},{componentName:"AgOverlayWrapper",componentClass:Xc},{componentName:"AgGroupComponent",componentClass:tc},{componentName:"AgRowContainer",componentClass:Ba},{componentName:"AgFakeHorizontalScroll",componentClass:pu},{componentName:"AgFakeVerticalScroll",componentClass:Tu},{componentName:"AgAutocomplete",componentClass:Cc}];const i=this.extractModuleEntity(e,e=>e.agStackComponents?e.agStackComponents:[]);return t=t.concat(i),t}createBeansList(e="clientSide",t,i){const r=t.filter(t=>!t.rowModel||t.rowModel===e),n={clientSide:"@ag-grid-community/client-side-row-model",infinite:"@ag-grid-community/infinite-row-model",serverSide:"@ag-grid-enterprise/server-side-row-model",viewport:"@ag-grid-enterprise/viewport-row-model"};if(!n[e])return void W("Could not find row model for rowModelType = "+e);if(!se.__assertRegistered(n[e],`rowModelType = '${e}'`,i))return;const s=[la,Zc,Jc,su,Vc,Uo,po,zc,Uc,Rl,No,$c,wl,Eu,Iu,Fl,Vo,Pt,me,bu,pc,Rc,jo,Mt,ml,zl,Nl,xc,st,Mc,Fa,Hc,Pc,Dc,Il,Sl,Vs,_c,Fc,Oa,Kc,Tc,Ul,Na,Oc,kc,Gc,qc,pt,Bc,_l,nu,Ot,ou,au,Bl,lu,cu,gu,fu,uu,_u,Wo,Pu,xu,Du,xl,Lu,Ou,Dl],o=this.extractModuleEntity(r,e=>e.beans?e.beans:[]);s.push(...o);const a=[];return s.forEach(e=>{a.indexOf(e)<0&&a.push(e)}),a}extractModuleEntity(e,t){return[].concat(...e.map(t))}},zu=class{wrap(e,t,i=[],r){const n=this.createWrapper(e,r);return t.forEach(e=>{this.createMethod(n,e,!0)}),i.forEach(e=>{this.createMethod(n,e,!1)}),n}unwrap(e){return e}createMethod(e,t,i){e.addMethod(t,this.createMethodProxy(e,t,i))}createMethodProxy(e,t,i){return function(){return e.hasMethod(t)?e.callMethod(t,arguments):(i&&console.warn("AG Grid: Framework component is missing the method "+t+"()"),null)}}},Uu=class{};Uu.CHART_TYPE_TO_SERIES_TYPE={column:"bar",groupedColumn:"bar",stackedColumn:"bar",normalizedColumn:"bar",bar:"bar",groupedBar:"bar",stackedBar:"bar",normalizedBar:"bar",line:"line",scatter:"scatter",bubble:"bubble",pie:"pie",donut:"donut",doughnut:"donut",area:"area",stackedArea:"area",normalizedArea:"area",histogram:"histogram",radarLine:"radar-line",radarArea:"radar-area",nightingale:"nightingale",radialColumn:"radial-column",radialBar:"radial-bar",sunburst:"sunburst",rangeBar:"range-bar",rangeArea:"range-area",boxPlot:"box-plot",treemap:"treemap",heatmap:"heatmap",waterfall:"waterfall"},Uu.COMBO_CHART_TYPES=["columnLineCombo","areaColumnCombo","customCombo"],Uu.SERIES_GROUP_TYPES=["grouped","stacked","normalized"];var Wu=(e=>(e.InsideBase="insideBase",e.InsideEnd="insideEnd",e.Center="center",e.OutsideEnd="outsideEnd",e))(Wu||{}),ju="undefined"==typeof globalThis?{}:globalThis;ju.HTMLElement="undefined"==typeof HTMLElement?{}:HTMLElement,ju.HTMLButtonElement="undefined"==typeof HTMLButtonElement?{}:HTMLButtonElement,ju.HTMLSelectElement="undefined"==typeof HTMLSelectElement?{}:HTMLSelectElement,ju.HTMLInputElement="undefined"==typeof HTMLInputElement?{}:HTMLInputElement,ju.Node="undefined"==typeof Node?{}:Node,ju.MouseEvent="undefined"==typeof MouseEvent?{}:MouseEvent;var Ku=class e{constructor(t,i,r,n,s,o){this.nextId=0,this.rowCountReady=!1,this.allNodesMap={},this.rootNode=t,this.gos=i,this.eventService=r,this.columnModel=n,this.beans=o,this.selectionService=s,this.rootNode.group=!0,this.rootNode.level=-1,this.rootNode.id=e.ROOT_NODE_ID,this.rootNode.allLeafChildren=[],this.rootNode.childrenAfterGroup=[],this.rootNode.childrenAfterSort=[],this.rootNode.childrenAfterAggFilter=[],this.rootNode.childrenAfterFilter=[]}getCopyOfNodesMap(){return cn.cloneObject(this.allNodesMap)}getRowNode(e){return this.allNodesMap[e]}setRowData(t){if("string"==typeof t)return void console.warn("AG Grid: rowData must be an array.");this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(t);const i=this.rootNode,r=this.rootNode.sibling;i.childrenAfterFilter=null,i.childrenAfterGroup=null,i.childrenAfterAggFilter=null,i.childrenAfterSort=null,i.childrenMapped=null,i.updateHasChildren(),this.nextId=0,this.allNodesMap={},t?i.allLeafChildren=t.map(t=>this.createNode(t,this.rootNode,e.TOP_LEVEL)):(i.allLeafChildren=[],i.childrenAfterGroup=[]),r&&(r.childrenAfterFilter=i.childrenAfterFilter,r.childrenAfterGroup=i.childrenAfterGroup,r.childrenAfterAggFilter=i.childrenAfterAggFilter,r.childrenAfterSort=i.childrenAfterSort,r.childrenMapped=i.childrenMapped,r.allLeafChildren=i.allLeafChildren)}updateRowData(e,t){this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(e.add);const i={remove:[],update:[],add:[]},r=[];return this.executeRemove(e,i,r),this.executeUpdate(e,i,r),this.executeAdd(e,i),this.updateSelection(r,"rowDataChanged"),t&&cn.sortRowNodesByOrder(this.rootNode.allLeafChildren,t),i}isRowCountReady(){return this.rowCountReady}dispatchRowDataUpdateStartedEvent(e){const t={type:ct.EVENT_ROW_DATA_UPDATE_STARTED,firstRowData:(null==e?void 0:e.length)?e[0]:null};this.eventService.dispatchEvent(t)}updateSelection(e,t){const i=e.length>0;if(i&&this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),this.selectionService.updateGroupsFromChildrenSelections(t),i){const e={type:ct.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(e)}}executeAdd(t,i){var r;const{add:n,addIndex:s}=t;if(cn.missingOrEmpty(n))return;const o=n.map(t=>this.createNode(t,this.rootNode,e.TOP_LEVEL));if("number"==typeof s&&s>=0){const{allLeafChildren:e}=this.rootNode,t=e.length;let i=s;if(this.gos.get("treeData")&&s>0&&t>0)for(let n=0;n<t;n++)if((null==(r=e[n])?void 0:r.rowIndex)==s-1){i=n+1;break}const n=e.slice(0,i),a=e.slice(i,e.length);this.rootNode.allLeafChildren=[...n,...o,...a]}else this.rootNode.allLeafChildren=[...this.rootNode.allLeafChildren,...o];this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren),i.add=o}executeRemove(e,t,i){const{remove:r}=e;if(cn.missingOrEmpty(r))return;const n={};r.forEach(e=>{const r=this.lookupRowNode(e);r&&(r.isSelected()&&i.push(r),r.clearRowTopAndRowIndex(),n[r.id]=!0,delete this.allNodesMap[r.id],t.remove.push(r))}),this.rootNode.allLeafChildren=this.rootNode.allLeafChildren.filter(e=>!n[e.id]),this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren)}executeUpdate(t,i,r){const{update:n}=t;cn.missingOrEmpty(n)||n.forEach(t=>{const n=this.lookupRowNode(t);n&&(n.updateData(t),!n.selectable&&n.isSelected()&&r.push(n),this.setMasterForRow(n,t,e.TOP_LEVEL,!1),i.update.push(n))})}lookupRowNode(e){const t=this.gos.getCallback("getRowId");let i;if(t){const r=t({data:e,level:0});if(i=this.allNodesMap[r],!i)return console.error(`AG Grid: could not find row id=${r}, data item was not found for this id`),null}else if(i=this.rootNode.allLeafChildren.find(t=>t.data===e),!i)return console.error("AG Grid: could not find data item as object was not found",e),console.error("Consider using getRowId to help the Grid find matching row data"),null;return i||null}createNode(e,t,i){const r=new Ns(this.beans);r.group=!1,this.setMasterForRow(r,e,i,!0);const n=this.gos.get("suppressParentsInRowNodes");return t&&!n&&(r.parent=t),r.level=i,r.setDataAndId(e,this.nextId.toString()),this.allNodesMap[r.id]&&console.warn(`AG Grid: duplicate node id '${r.id}' detected from getRowId callback, this could cause issues in your grid.`),this.allNodesMap[r.id]=r,this.nextId++,r}setMasterForRow(e,t,i,r){if(this.gos.get("treeData"))e.setMaster(!1),r&&(e.expanded=!1);else{if(this.gos.get("masterDetail")){const i=this.gos.get("isRowMaster");i?e.setMaster(i(t)):e.setMaster(!0)}else e.setMaster(!1);if(r){const t=this.columnModel.getRowGroupColumns(),r=i+(t?t.length:0);e.expanded=!!e.master&&this.isExpanded(r)}}}isExpanded(e){const t=this.gos.get("groupDefaultExpanded");return-1===t||e<t}};Ku.TOP_LEVEL=0,Ku.ROOT_NODE_ID="ROOT_NODE_ID";var $u=Ku,qu=class extends nt{constructor(){super(...arguments),this.onRowHeightChanged_debounced=cn.debounce(this.onRowHeightChanged.bind(this),100),this.rowsToDisplay=[],this.hasStarted=!1,this.shouldSkipSettingDataOnStart=!1,this.isRefreshingModel=!1,this.rowCountReady=!1}init(){const e=this.refreshModel.bind(this,{step:"group"}),t=!this.gos.get("suppressAnimationFrame"),i=this.refreshModel.bind(this,{step:"group",afterColumnsChanged:!0,keepRenderedRows:!0,animate:t});this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,i),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_VALUE_CHANGED,this.onValueChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_CHANGED,this.refreshModel.bind(this,{step:"pivot"})),this.addManagedListener(this.eventService,ct.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,this.onSortChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedListener(this.eventService,ct.EVENT_GRID_STYLES_CHANGED,this.onGridStylesChanges.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_GRID_READY,()=>this.onGridReady()),this.addPropertyListeners(),this.rootNode=new Ns(this.beans),this.nodeManager=new $u(this.rootNode,this.gos,this.eventService,this.columnModel,this.selectionService,this.beans)}addPropertyListeners(){const e=new Set(["treeData","masterDetail"]),t=new Set(["suppressParentsInRowNodes","groupDefaultExpanded","groupAllowUnbalanced","initialGroupOrderComparator","groupHideOpenParents","groupDisplayType"]),i=new Set(["excludeChildrenWhenTreeDataFiltering"]),r=new Set(["removePivotHeaderRowWhenSingleValueColumn","pivotRowTotals","pivotColumnGroupTotals","suppressExpandablePivotGroups"]),n=new Set(["getGroupRowAgg","alwaysAggregateAtRootLevel","groupIncludeTotalFooter","suppressAggFilteredOnly","grandTotalRow"]),s=new Set(["postSortRows","groupDisplayType","accentedSort"]),o=new Set([]),a=new Set(["groupRemoveSingleChildren","groupRemoveLowestSingleChildren","groupIncludeFooter","groupTotalRow"]),l=[...e,...t,...i,...r,...r,...n,...s,...o,...a];this.addManagedPropertyListeners(l,l=>{var c;const u=null==(c=l.changeSet)?void 0:c.properties;if(!u)return;const h=e=>u.some(t=>e.has(t));h(e)?this.setRowData(this.rootNode.allLeafChildren.map(e=>e.data)):h(t)?this.refreshModel({step:"group"}):h(i)?this.refreshModel({step:"filter"}):h(r)?this.refreshModel({step:"pivot"}):h(n)?this.refreshModel({step:"aggregate"}):h(s)?this.refreshModel({step:"sort"}):h(o)?this.refreshModel({step:"filter_aggregates"}):h(a)&&this.refreshModel({step:"map"})}),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights())}start(){this.hasStarted=!0,this.shouldSkipSettingDataOnStart?this.dispatchUpdateEventsAndRefresh():this.setInitialData()}setInitialData(){const e=this.gos.get("rowData");e&&(this.shouldSkipSettingDataOnStart=!0,this.setRowData(e))}ensureRowHeightsValid(e,t,i,r){let n,s=!1;do{n=!1;const o=this.getRowIndexAtPixel(e),a=this.getRowIndexAtPixel(t),l=Math.max(o,i),c=Math.min(a,r);for(let e=l;e<=c;e++){const t=this.getRow(e);if(t.rowHeightEstimated){const e=this.gos.getRowHeightForNode(t);t.setRowHeight(e.height),n=!0,s=!0}}n&&this.setRowTopAndRowIndex()}while(n);return s}setRowTopAndRowIndex(){const e=this.environment.getDefaultRowHeight();let t=0;const i=new Set,r=this.gos.isDomLayout("normal");for(let n=0;n<this.rowsToDisplay.length;n++){const s=this.rowsToDisplay[n];if(null!=s.id&&i.add(s.id),null==s.rowHeight){const t=this.gos.getRowHeightForNode(s,r,e);s.setRowHeight(t.height,t.estimated)}s.setRowTop(t),s.setRowIndex(n),t+=s.rowHeight}return i}clearRowTopAndRowIndex(e,t){const i=e.isActive(),r=e=>{e&&null!=e.id&&!t.has(e.id)&&e.clearRowTopAndRowIndex()},n=e=>{if(r(e),r(e.detailNode),r(e.sibling),e.hasChildren()&&e.childrenAfterGroup){const t=-1==e.level;i&&!t&&!e.expanded||e.childrenAfterGroup.forEach(n)}};n(this.rootNode)}ensureRowsAtPixel(e,t,i=0){const r=this.getRowIndexAtPixel(t),n=this.getRow(r),s=!this.gos.get("suppressAnimationFrame");return n!==e[0]&&(e.forEach(e=>{cn.removeFromArray(this.rootNode.allLeafChildren,e)}),e.forEach((e,t)=>{cn.insertIntoArray(this.rootNode.allLeafChildren,e,Math.max(r+i,0)+t)}),this.refreshModel({step:"group",keepRenderedRows:!0,keepEditingRows:!0,animate:s}),!0)}highlightRowAtPixel(e,t){const i=null!=t?this.getRowIndexAtPixel(t):null,r=null!=i?this.getRow(i):null;if(!r||!e||r===e||null==t)return void(this.lastHighlightedRow&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null));const n=this.getHighlightPosition(t,r);this.lastHighlightedRow&&this.lastHighlightedRow!==r&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null),r.setHighlighted(n),this.lastHighlightedRow=r}getHighlightPosition(e,t){if(!t){const i=this.getRowIndexAtPixel(e);if(!(t=this.getRow(i||0)))return 1}const{rowTop:i,rowHeight:r}=t;return e-i<r/2?0:1}getLastHighlightedRowNode(){return this.lastHighlightedRow}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return 1;const e=this.rootNode.childrenAfterAggFilter;return e?e.length:0}getTopLevelRowDisplayedIndex(e){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return e;let t=this.rootNode.childrenAfterSort[e];if(this.gos.get("groupHideOpenParents"))for(;t.expanded&&t.childrenAfterSort&&t.childrenAfterSort.length>0;)t=t.childrenAfterSort[0];return t.rowIndex}getRowBounds(e){if(cn.missing(this.rowsToDisplay))return null;const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=this.gos.isAnimateRows();this.refreshModel({step:"map",keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=this.gos.isAnimateRows(),i=0===e.columns.length||e.columns.some(e=>e.isPrimary())?"filter":"filter_aggregates";this.refreshModel({step:i,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=this.gos.isAnimateRows();this.refreshModel({step:"sort",keepRenderedRows:!0,animate:e,keepEditingRows:!0})}getType(){return"clientSide"}onValueChanged(){this.columnModel.isPivotActive()?this.refreshModel({step:"pivot"}):this.refreshModel({step:"aggregate"})}createChangePath(e){const t=cn.missingOrEmpty(e),i=new Gl(!1,this.rootNode);return(t||this.gos.get("treeData"))&&i.setInactive(),i}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;if(null==e.rowNodeTransactions)return!1;const t=e.rowNodeTransactions.filter(e=>null!=e.add&&e.add.length>0||null!=e.remove&&e.remove.length>0);return null==t||0==t.length}buildRefreshModelParams(e){let t="group";const i={everything:"group",group:"group",filter:"filter",map:"map",aggregate:"aggregate",sort:"sort",pivot:"pivot"};if(cn.exists(e)&&(t=i[e]),!cn.missing(t))return{step:t,keepRenderedRows:!0,keepEditingRows:!0,animate:!this.gos.get("suppressAnimationFrame")};console.error(`AG Grid: invalid step ${e}, available steps are ${Object.keys(i).join(", ")}`)}refreshModel(e){if(!this.hasStarted||this.isRefreshingModel||this.columnModel.shouldRowModelIgnoreRefresh())return;let t="object"==typeof e&&"step"in e?e:this.buildRefreshModelParams(e);if(!t)return;if(this.isSuppressModelUpdateAfterUpdateTransaction(t))return;const i=this.createChangePath(t.rowNodeTransactions);switch(this.isRefreshingModel=!0,t.step){case"group":this.doRowGrouping(t.rowNodeTransactions,t.rowNodeOrder,i,!!t.afterColumnsChanged);case"filter":this.doFilter(i);case"pivot":this.doPivot(i);case"aggregate":this.doAggregate(i);case"filter_aggregates":this.doFilterAggregates(i);case"sort":this.doSort(t.rowNodeTransactions,i);case"map":this.doRowsToDisplay()}const r=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(i,r),this.isRefreshingModel=!1;const n={type:ct.EVENT_MODEL_UPDATED,animate:t.animate,keepRenderedRows:t.keepRenderedRows,newData:t.newData,newPage:!1,keepUndoRedoStack:t.keepUndoRedoStack};this.eventService.dispatchEvent(n)}isEmpty(){const e=cn.missing(this.rootNode.allLeafChildren)||0===this.rootNode.allLeafChildren.length;return cn.missing(this.rootNode)||e||!this.columnModel.isReady()}isRowsToRender(){return cn.exists(this.rowsToDisplay)&&this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let i=!t,r=!1;const n=[],s=this.gos.get("groupSelectsChildren");return this.forEachNodeAfterFilterAndSort(o=>{if(!r)if(i&&(o===t||o===e)&&(r=!0,o.group&&s))n.push(...o.allLeafChildren);else{if(!i){if(o!==t&&o!==e)return;i=!0}(!o.group||!s)&&n.push(o)}}),n}setDatasource(e){console.error("AG Grid: should never call setDatasource on clientSideRowController")}getTopLevelNodes(){return this.rootNode?this.rootNode.childrenAfterGroup:null}getRootNode(){return this.rootNode}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){if(this.isEmpty()||0===this.rowsToDisplay.length)return-1;let t=0,i=this.rowsToDisplay.length-1;if(e<=0)return 0;if(cn.last(this.rowsToDisplay).rowTop<=e)return this.rowsToDisplay.length-1;let r=-1,n=-1;for(;;){const s=Math.floor((t+i)/2),o=this.rowsToDisplay[s];if(this.isRowInPixel(o,e))return s;if(o.rowTop<e?t=s+1:o.rowTop>e&&(i=s-1),r===t&&n===i)return s;r=t,n=i}}isRowInPixel(e,t){const i=e.rowTop,r=e.rowTop+e.rowHeight;return i<=t&&r>t}forEachLeafNode(e){this.rootNode.allLeafChildren&&this.rootNode.allLeafChildren.forEach((t,i)=>e(t,i))}forEachNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterGroup||[]],callback:e,recursionType:0,index:0,includeFooterNodes:t})}forEachNodeAfterFilter(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterAggFilter||[]],callback:e,recursionType:1,index:0,includeFooterNodes:t})}forEachNodeAfterFilterAndSort(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterSort||[]],callback:e,recursionType:2,index:0,includeFooterNodes:t})}forEachPivotNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[this.rootNode],callback:e,recursionType:3,index:0,includeFooterNodes:t})}recursivelyWalkNodesAndCallback(e){const{nodes:t,callback:i,recursionType:r,includeFooterNodes:n}=e;let{index:s}=e;const o=e=>{var r;const o=null==(r=t[0])?void 0:r.parent;if(!o)return;const a=n&&this.gos.getGrandTotalRow(),l=this.gos.getGroupTotalRowCallback(),c=n&&l({node:o});o===this.rootNode?a===e&&(o.createFooter(),i(o.sibling,s++)):c===e&&(o.createFooter(),i(o.sibling,s++))};o("top");for(let e=0;e<t.length;e++){const o=t[e];if(i(o,s++),o.hasChildren()&&!o.footer){let e=null;switch(r){case 0:e=o.childrenAfterGroup;break;case 1:e=o.childrenAfterAggFilter;break;case 2:e=o.childrenAfterSort;break;case 3:e=o.leafGroup?null:o.childrenAfterSort}e&&(s=this.recursivelyWalkNodesAndCallback({nodes:[...e],callback:i,recursionType:r,index:s,includeFooterNodes:n}))}}return o("bottom"),s}doAggregate(e){var t;null==(t=this.aggregationStage)||t.execute({rowNode:this.rootNode,changedPath:e})}doFilterAggregates(e){this.filterAggregatesStage?this.filterAggregatesStage.execute({rowNode:this.rootNode,changedPath:e}):this.rootNode.childrenAfterAggFilter=this.rootNode.childrenAfterFilter}expandOrCollapseAll(e){const t=this.gos.get("treeData"),i=this.columnModel.isPivotActive(),r=n=>{n&&n.forEach(n=>{const s=()=>{n.expanded=e,r(n.childrenAfterGroup)};t?cn.exists(n.childrenAfterGroup)&&s():i?!n.leafGroup&&s():n.group&&s()})};this.rootNode&&r(this.rootNode.childrenAfterGroup),this.refreshModel({step:"map"});const n=e?"expandAll":"collapseAll",s={type:ct.EVENT_EXPAND_COLLAPSE_ALL,source:n};this.eventService.dispatchEvent(s)}doSort(e,t){this.sortStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,changedPath:t})}doRowGrouping(e,t,i,r){if(this.groupStage){if(e?this.groupStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,rowNodeOrder:t,changedPath:i}):this.groupStage.execute({rowNode:this.rootNode,changedPath:i,afterColumnsChanged:r}),this.gos.get("groupSelectsChildren")&&this.selectionService.updateGroupsFromChildrenSelections("rowGroupChanged",i)){const e={type:ct.EVENT_SELECTION_CHANGED,source:"rowGroupChanged"};this.eventService.dispatchEvent(e)}}else this.rootNode.childrenAfterGroup=this.rootNode.allLeafChildren,this.rootNode.sibling&&(this.rootNode.sibling.childrenAfterGroup=this.rootNode.childrenAfterGroup),this.rootNode.updateHasChildren();this.nodeManager.isRowCountReady()&&(this.rowCountReady=!0,this.eventService.dispatchEventOnce({type:ct.EVENT_ROW_COUNT_READY}))}doFilter(e){this.filterStage.execute({rowNode:this.rootNode,changedPath:e})}doPivot(e){var t;null==(t=this.pivotStage)||t.execute({rowNode:this.rootNode,changedPath:e})}getCopyOfNodesMap(){return this.nodeManager.getCopyOfNodesMap()}getRowNode(e){if("string"==typeof e&&0==e.indexOf(Ns.ID_PREFIX_ROW_GROUP)){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}return this.nodeManager.getRowNode(e)}setRowData(e){this.selectionService.reset("rowDataChanged"),this.nodeManager.setRowData(e),this.hasStarted&&this.dispatchUpdateEventsAndRefresh()}dispatchUpdateEventsAndRefresh(){const e={type:ct.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(e),this.refreshModel({step:"group",newData:!0})}batchUpdateRowData(e,t){if(null==this.applyAsyncTransactionsTimeout){this.rowDataTransactionBatch=[];const e=this.gos.getAsyncTransactionWaitMillis();this.applyAsyncTransactionsTimeout=window.setTimeout(()=>{this.executeBatchUpdateRowData()},e)}this.rowDataTransactionBatch.push({rowDataTransaction:e,callback:t})}flushAsyncTransactions(){null!=this.applyAsyncTransactionsTimeout&&(clearTimeout(this.applyAsyncTransactionsTimeout),this.executeBatchUpdateRowData())}executeBatchUpdateRowData(){this.valueCache.onDataChanged();const e=[],t=[];let i=!1;if(this.rowDataTransactionBatch&&this.rowDataTransactionBatch.forEach(r=>{const n=this.nodeManager.updateRowData(r.rowDataTransaction,void 0);t.push(n),r.callback&&e.push(r.callback.bind(null,n)),"number"==typeof r.rowDataTransaction.addIndex&&(i=!0)}),this.commonUpdateRowData(t,void 0,i),e.length>0&&window.setTimeout(()=>{e.forEach(e=>e())},0),t.length>0){const e={type:ct.EVENT_ASYNC_TRANSACTIONS_FLUSHED,results:t};this.eventService.dispatchEvent(e)}this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e,t){this.valueCache.onDataChanged();const i=this.nodeManager.updateRowData(e,t),r="number"==typeof e.addIndex;return this.commonUpdateRowData([i],t,r),i}createRowNodeOrder(){if(this.gos.get("suppressMaintainUnsortedOrder"))return;const e={};if(this.rootNode&&this.rootNode.allLeafChildren)for(let t=0;t<this.rootNode.allLeafChildren.length;t++)e[this.rootNode.allLeafChildren[t].id]=t;return e}commonUpdateRowData(e,t,i){if(!this.hasStarted)return;const r=!this.gos.get("suppressAnimationFrame");i&&(t=this.createRowNodeOrder());const n={type:ct.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(n),this.refreshModel({step:"group",rowNodeTransactions:e,rowNodeOrder:t,keepRenderedRows:!0,keepEditingRows:!0,animate:r})}doRowsToDisplay(){this.rowsToDisplay=this.flattenStage.execute({rowNode:this.rootNode})}onRowHeightChanged(){this.refreshModel({step:"map",keepRenderedRows:!0,keepEditingRows:!0,keepUndoRedoStack:!0})}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}resetRowHeights(){const e=this.resetRowHeightsForAllRowNodes();this.rootNode.setRowHeight(this.rootNode.rowHeight,!0),this.rootNode.sibling&&this.rootNode.sibling.setRowHeight(this.rootNode.sibling.rowHeight,!0),e&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{t.setRowHeight(t.rowHeight,!0);const i=t.detailNode;i&&i.setRowHeight(i.rowHeight,!0),t.sibling&&t.sibling.setRowHeight(t.sibling.rowHeight,!0),e=!0}),e}onGridStylesChanges(){this.columnModel.isAutoRowHeightActive()||this.resetRowHeights()}onGridReady(){this.hasStarted||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}};g([he("columnModel")],qu.prototype,"columnModel",2),g([he("selectionService")],qu.prototype,"selectionService",2),g([he("valueCache")],qu.prototype,"valueCache",2),g([he("beans")],qu.prototype,"beans",2),g([he("filterStage")],qu.prototype,"filterStage",2),g([he("sortStage")],qu.prototype,"sortStage",2),g([he("flattenStage")],qu.prototype,"flattenStage",2),g([de("groupStage")],qu.prototype,"groupStage",2),g([de("aggregationStage")],qu.prototype,"aggregationStage",2),g([de("pivotStage")],qu.prototype,"pivotStage",2),g([de("filterAggregatesStage")],qu.prototype,"filterAggregatesStage",2),g([le],qu.prototype,"init",1),qu=g([ue("rowModel")],qu);var Yu=class extends nt{execute(e){const{changedPath:t}=e;this.filterService.filter(t)}};g([he("filterService")],Yu.prototype,"filterService",2),Yu=g([ue("filterStage")],Yu);var Qu=class extends nt{execute(e){const t=this.sortController.getSortOptions(),i=cn.exists(t)&&t.length>0,r=i&&cn.exists(e.rowNodeTransactions)&&this.gos.get("deltaSort"),n=t.some(e=>this.gos.isColumnsSortingCoupledToGroup()?e.column.isPrimary()&&e.column.isRowGroupActive():!!e.column.getColDef().showRowGroup);this.sortService.sort(t,i,r,e.rowNodeTransactions,e.changedPath,n)}};g([he("sortService")],Qu.prototype,"sortService",2),g([he("sortController")],Qu.prototype,"sortController",2),Qu=g([ue("sortStage")],Qu);var Xu=class extends nt{execute(e){const t=e.rowNode,i=[],r=this.beans.columnModel.isPivotMode(),n=r&&t.leafGroup,s=n?[t]:t.childrenAfterSort,o=this.getFlattenDetails();if(this.recursivelyAddToRowsToDisplay(o,s,i,r,0),!n&&i.length>0&&o.grandTotalRow){t.createFooter();const e="top"===o.grandTotalRow;this.addRowNodeToRowsToDisplay(o,t.sibling,i,0,e)}return i}getFlattenDetails(){const e=this.gos.get("groupRemoveSingleChildren");return{groupRemoveLowestSingleChildren:!e&&this.gos.get("groupRemoveLowestSingleChildren"),groupRemoveSingleChildren:e,isGroupMultiAutoColumn:this.gos.isGroupMultiAutoColumn(),hideOpenParents:this.gos.get("groupHideOpenParents"),grandTotalRow:this.gos.getGrandTotalRow(),groupTotalRow:this.gos.getGroupTotalRowCallback()}}recursivelyAddToRowsToDisplay(e,t,i,r,n){if(!cn.missingOrEmpty(t))for(let s=0;s<t.length;s++){const o=t[s],a=o.hasChildren(),l=r&&!a,c=e.groupRemoveSingleChildren&&a&&1===o.childrenAfterGroup.length,u=e.groupRemoveLowestSingleChildren&&a&&o.leafGroup&&1===o.childrenAfterGroup.length,h=r&&o.leafGroup,d=e.hideOpenParents&&o.expanded&&!o.master&&!h;if(!(l||d||c||u)&&this.addRowNodeToRowsToDisplay(e,o,i,n),!r||!o.leafGroup)if(a){const t=c||u;if(o.expanded||t){const s=e.groupTotalRow({node:o});s||o.destroyFooter();const a=t?n:n+1;"top"===s&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,a)),this.recursivelyAddToRowsToDisplay(e,o.childrenAfterSort,i,r,a),"bottom"===s&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,a))}}else if(o.master&&o.expanded){const t=this.createDetailNode(o);this.addRowNodeToRowsToDisplay(e,t,i,n)}}}addRowNodeToRowsToDisplay(e,t,i,r,n){n?i.unshift(t):i.push(t),t.setUiLevel(e.isGroupMultiAutoColumn?0:r)}createDetailNode(e){if(cn.exists(e.detailNode))return e.detailNode;const t=new Ns(this.beans);return t.detail=!0,t.selectable=!1,t.parent=e,cn.exists(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1,e.detailNode=t,t}};g([he("beans")],Xu.prototype,"beans",2),Xu=g([ue("flattenStage")],Xu);var Zu=class extends nt{sort(e,t,i,r,n,s){const o=this.gos.get("groupMaintainOrder"),a=this.columnModel.getAllGridColumns().some(e=>e.isRowGroupActive());let l={};i&&r&&(l=this.calculateDirtyNodes(r));const c=this.columnModel.isPivotMode(),u=this.gos.getCallback("postSortRows");n&&n.forEachChangedNodeDepthFirst(r=>{var h;this.pullDownGroupDataForHideOpenParents(r.childrenAfterAggFilter,!0);const d=c&&r.leafGroup;if(o&&a&&!r.leafGroup&&!s){const e=null==(h=this.columnModel.getRowGroupColumns())?void 0:h[r.level+1],t=null===(null==e?void 0:e.getSort()),i=r.childrenAfterAggFilter.slice(0);if(r.childrenAfterSort&&!t){const e={};r.childrenAfterSort.forEach((t,i)=>{e[t.id]=i}),i.sort((t,i)=>{var r,n;return(null!=(r=e[t.id])?r:0)-(null!=(n=e[i.id])?n:0)})}r.childrenAfterSort=i}else r.childrenAfterSort=!t||d?r.childrenAfterAggFilter.slice(0):i?this.doDeltaSort(r,l,n,e):this.rowNodeSorter.doFullSort(r.childrenAfterAggFilter,e);if(r.sibling&&(r.sibling.childrenAfterSort=r.childrenAfterSort),this.updateChildIndexes(r),u){const e={nodes:r.childrenAfterSort};u(e)}}),this.updateGroupDataForHideOpenParents(n)}calculateDirtyNodes(e){const t={},i=e=>{e&&e.forEach(e=>t[e.id]=!0)};return e&&e.forEach(e=>{i(e.add),i(e.update),i(e.remove)}),t}doDeltaSort(e,t,i,r){const n=e.childrenAfterAggFilter,s=e.childrenAfterSort;if(!s)return this.rowNodeSorter.doFullSort(n,r);const o={},a=[];n.forEach(e=>{t[e.id]||!i.canSkip(e)?a.push(e):o[e.id]=!0});const l=s.filter(e=>o[e.id]),c=(e,t)=>({currentPos:t,rowNode:e}),u=a.map(c).sort((e,t)=>this.rowNodeSorter.compareRowNodes(r,e,t));return this.mergeSortedArrays(r,u,l.map(c)).map(({rowNode:e})=>e)}mergeSortedArrays(e,t,i){const r=[];let n=0,s=0;for(;n<t.length&&s<i.length;)this.rowNodeSorter.compareRowNodes(e,t[n],i[s])<0?r.push(t[n++]):r.push(i[s++]);for(;n<t.length;)r.push(t[n++]);for(;s<i.length;)r.push(i[s++]);return r}updateChildIndexes(e){if(cn.missing(e.childrenAfterSort))return;const t=e.childrenAfterSort;for(let i=0;i<t.length;i++){const r=t[i],n=0===i,s=i===e.childrenAfterSort.length-1;r.setFirstChild(n),r.setLastChild(s),r.setChildIndex(i)}}updateGroupDataForHideOpenParents(e){if(!this.gos.get("groupHideOpenParents"))return;if(this.gos.get("treeData"))return cn.warnOnce("The property hideOpenParents dose not work with Tree Data. This is because Tree Data has values at the group level, it doesn't make sense to hide them."),!1;const t=e=>{this.pullDownGroupDataForHideOpenParents(e.childrenAfterSort,!1),e.childrenAfterSort.forEach(e=>{e.hasChildren()&&t(e)})};e&&e.executeFromRootNode(e=>t(e))}pullDownGroupDataForHideOpenParents(e,t){this.gos.get("groupHideOpenParents")&&!cn.missing(e)&&e.forEach(e=>{this.columnModel.getGroupDisplayColumns().forEach(i=>{const r=i.getColDef().showRowGroup;if("string"!=typeof r)return void console.error("AG Grid: groupHideOpenParents only works when specifying specific columns for colDef.showRowGroup");const n=r,s=this.columnModel.getPrimaryColumn(n);if(s!==e.rowGroupColumn)if(t)e.setGroupValue(i.getId(),void 0);else{const t=e.getFirstChildOfFirstChild(s);t&&e.setGroupValue(i.getId(),t.key)}})})}};g([he("columnModel")],Zu.prototype,"columnModel",2),g([he("rowNodeSorter")],Zu.prototype,"rowNodeSorter",2),Zu=g([ue("sortService")],Zu);var Ju=class extends nt{filter(e){const t=this.filterManager.isChildFilterPresent();this.filterNodes(t,e)}filterNodes(e,t){const i=(t,i)=>{t.hasChildren()?t.childrenAfterFilter=e&&!i?t.childrenAfterGroup.filter(e=>{const t=e.childrenAfterFilter&&e.childrenAfterFilter.length>0,i=e.data&&this.filterManager.doesRowPassFilter({rowNode:e});return t||i}):t.childrenAfterGroup:t.childrenAfterFilter=t.childrenAfterGroup,t.sibling&&(t.sibling.childrenAfterFilter=t.childrenAfterFilter)};if(this.doingTreeDataFiltering()){const e=(t,r)=>{if(t.childrenAfterGroup)for(let n=0;n<t.childrenAfterGroup.length;n++){const s=t.childrenAfterGroup[n],o=r||this.filterManager.doesRowPassFilter({rowNode:s});s.childrenAfterGroup?e(t.childrenAfterGroup[n],o):i(s,o)}i(t,r)},r=t=>e(t,!1);t.executeFromRootNode(r)}else{const e=e=>i(e,!1);t.forEachChangedNodeDepthFirst(e,!0)}}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}};g([he("filterManager")],Ju.prototype,"filterManager",2),Ju=g([ue("filterService")],Ju);var eh=class extends nt{postConstruct(){"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel,this.addManagedPropertyListener("rowData",()=>this.onRowDataUpdated()))}isActive(){const e=this.gos.exists("getRowId");return!this.gos.get("resetRowDataOnUpdate")&&e}setRowData(e){const t=this.createTransactionForRowData(e);if(!t)return;const[i,r]=t;this.clientSideRowModel.updateRowData(i,r)}createTransactionForRowData(e){if(cn.missing(this.clientSideRowModel))return void console.error("AG Grid: ImmutableService only works with ClientSideRowModel");const t=this.gos.getCallback("getRowId");if(null==t)return void console.error("AG Grid: ImmutableService requires getRowId() callback to be implemented, your row data needs IDs!");const i={remove:[],update:[],add:[]},r=this.clientSideRowModel.getCopyOfNodesMap(),n=this.gos.get("suppressMaintainUnsortedOrder")?void 0:{};return cn.exists(e)&&e.forEach((e,s)=>{const o=t({data:e,level:0}),a=r[o];n&&(n[o]=s),a?(a.data!==e&&i.update.push(e),r[o]=void 0):i.add.push(e)}),cn.iterateObject(r,(e,t)=>{t&&i.remove.push(t.data)}),[i,n]}onRowDataUpdated(){const e=this.gos.get("rowData");e&&(this.isActive()?this.setRowData(e):(this.selectionService.reset("rowDataChanged"),this.clientSideRowModel.setRowData(e)))}};g([he("rowModel")],eh.prototype,"rowModel",2),g([he("rowRenderer")],eh.prototype,"rowRenderer",2),g([he("selectionService")],eh.prototype,"selectionService",2),g([le],eh.prototype,"postConstruct",1);var th={version:"31.3.4",moduleName:"@ag-grid-community/client-side-row-model",rowModel:"clientSide",beans:[qu,Yu,Qu,Xu,Zu,Ju,eh=g([ue("immutableService")],eh)]},ih=Object.defineProperty,rh=Object.getOwnPropertyDescriptor,nh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?rh(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&ih(t,i,s),s},sh=class extends Hl{constructor(e,t,i){super(e),this.parentCache=t,this.params=i,this.startRow=e*i.blockSize,this.endRow=this.startRow+i.blockSize}postConstruct(){this.createRowNodes()}getBlockStateJson(){return{id:""+this.getId(),state:{blockNumber:this.getId(),startRow:this.getStartRow(),endRow:this.getEndRow(),pageStatus:this.getState()}}}setDataAndId(e,t,i){cn.exists(t)?e.setDataAndId(t,i.toString()):e.setDataAndId(void 0,void 0)}loadFromDatasource(){const e=this.createLoadParams();cn.missing(this.params.datasource.getRows)?console.warn("AG Grid: datasource is missing getRows method"):window.setTimeout(()=>{this.params.datasource.getRows(e)},0)}processServerFail(){}createLoadParams(){return{startRow:this.getStartRow(),endRow:this.getEndRow(),successCallback:this.pageLoaded.bind(this,this.getVersion()),failCallback:this.pageLoadFailed.bind(this,this.getVersion()),sortModel:this.params.sortModel,filterModel:this.params.filterModel,context:this.gos.getGridCommonParams().context}}forEachNode(e,t,i){this.rowNodes.forEach((r,n)=>{this.startRow+n<i&&e(r,t.next())})}getLastAccessed(){return this.lastAccessed}getRow(e,t=!1){t||(this.lastAccessed=this.params.lastAccessedSequence.next());const i=e-this.startRow;return this.rowNodes[i]}getStartRow(){return this.startRow}getEndRow(){return this.endRow}createRowNodes(){this.rowNodes=[];for(let e=0;e<this.params.blockSize;e++){const t=this.startRow+e,i=new Ns(this.beans);i.setRowHeight(this.params.rowHeight),i.uiLevel=0,i.setRowIndex(t),i.setRowTop(this.params.rowHeight*t),this.rowNodes.push(i)}}processServerResult(e){this.rowNodes.forEach((t,i)=>{const r=e.rowData?e.rowData[i]:void 0;!t.id&&t.alreadyRendered&&r&&(this.rowNodes[i]=new Ns(this.beans),this.rowNodes[i].setRowIndex(t.rowIndex),this.rowNodes[i].setRowTop(t.rowTop),this.rowNodes[i].setRowHeight(t.rowHeight),t.clearRowTopAndRowIndex()),this.setDataAndId(this.rowNodes[i],r,this.startRow+i)});const t=null!=e.rowCount&&e.rowCount>=0?e.rowCount:void 0;this.parentCache.pageLoaded(this,t)}destroyRowNodes(){this.rowNodes.forEach(e=>{e.clearRowTopAndRowIndex()})}};nh([he("beans")],sh.prototype,"beans",2),nh([le],sh.prototype,"postConstruct",1),nh([ce],sh.prototype,"destroyRowNodes",1);var oh,ah=class e extends nt{constructor(e){super(),this.lastRowIndexKnown=!1,this.blocks={},this.blockCount=0,this.rowCount=e.initialRowCount,this.params=e}setBeans(e){this.logger=e.create("InfiniteCache")}getRow(e,t=!1){const i=Math.floor(e/this.params.blockSize);let r=this.blocks[i];if(!r){if(t)return;r=this.createBlock(i)}return r.getRow(e)}createBlock(e){const t=this.createBean(new sh(e,this,this.params));return this.blocks[t.getId()]=t,this.blockCount++,this.purgeBlocksIfNeeded(t),this.params.rowNodeBlockLoader.addBlock(t),t}refreshCache(){0==this.blockCount?this.purgeCache():(this.getBlocksInOrder().forEach(e=>e.setStateWaitingToLoad()),this.params.rowNodeBlockLoader.checkBlockToLoad())}destroyAllBlocks(){this.getBlocksInOrder().forEach(e=>this.destroyBlock(e))}getRowCount(){return this.rowCount}isLastRowIndexKnown(){return this.lastRowIndexKnown}pageLoaded(e,t){this.isAlive()&&(this.logger.log(`onPageLoaded: page = ${e.getId()}, lastRow = ${t}`),this.checkRowCount(e,t),this.onCacheUpdated())}purgeBlocksIfNeeded(t){const i=this.getBlocksInOrder().filter(e=>e!=t);i.sort((e,t)=>t.getLastAccessed()-e.getLastAccessed());const r=this.params.maxBlocksInCache>0,n=r?this.params.maxBlocksInCache-1:null,s=e.MAX_EMPTY_BLOCKS_TO_KEEP-1;i.forEach((e,t)=>{if(e.getState()===sh.STATE_WAITING_TO_LOAD&&t>=s||r&&t>=n){if(this.isBlockCurrentlyDisplayed(e))return;if(this.isBlockFocused(e))return;this.removeBlockFromCache(e)}})}isBlockFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();if(!t)return!1;if(null!=t.rowPinned)return!1;const i=e.getStartRow(),r=e.getEndRow();return t.rowIndex>=i&&t.rowIndex<r}isBlockCurrentlyDisplayed(e){const t=e.getStartRow(),i=e.getEndRow()-1;return this.rowRenderer.isRangeInRenderedViewport(t,i)}removeBlockFromCache(e){e&&this.destroyBlock(e)}checkRowCount(e,t){if("number"==typeof t&&t>=0)this.rowCount=t,this.lastRowIndexKnown=!0;else if(!this.lastRowIndexKnown){const t=(e.getId()+1)*this.params.blockSize+this.params.overflowSize;this.rowCount<t&&(this.rowCount=t)}}setRowCount(e,t){this.rowCount=e,cn.exists(t)&&(this.lastRowIndexKnown=t),this.lastRowIndexKnown||this.rowCount%this.params.blockSize===0&&this.rowCount++,this.onCacheUpdated()}forEachNodeDeep(e){const t=new un;this.getBlocksInOrder().forEach(i=>i.forEachNode(e,t,this.rowCount))}getBlocksInOrder(){return cn.getAllValuesInObject(this.blocks).sort((e,t)=>e.getId()-t.getId())}destroyBlock(e){delete this.blocks[e.getId()],this.destroyBean(e),this.blockCount--,this.params.rowNodeBlockLoader.removeBlock(e)}onCacheUpdated(){if(this.isAlive()){this.destroyAllBlocksPastVirtualRowCount();const e={type:ct.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}}destroyAllBlocksPastVirtualRowCount(){const e=[];this.getBlocksInOrder().forEach(t=>{t.getId()*this.params.blockSize>=this.rowCount&&e.push(t)}),e.length>0&&e.forEach(e=>this.destroyBlock(e))}purgeCache(){this.getBlocksInOrder().forEach(e=>this.removeBlockFromCache(e)),this.lastRowIndexKnown=!1,0===this.rowCount&&(this.rowCount=this.params.initialRowCount),this.onCacheUpdated()}getRowNodesInRange(e,t){const i=[];let r=-1,n=!1;const s=new un;cn.missing(e)&&(n=!0);let o=!1;return this.getBlocksInOrder().forEach(a=>{o||(n&&r+1!==a.getId()?o=!0:(r=a.getId(),a.forEachNode(r=>{const s=r===e||r===t;(n||s)&&i.push(r),s&&(n=!n)},s,this.rowCount)))}),o||n?[]:i}};ah.MAX_EMPTY_BLOCKS_TO_KEEP=2,nh([he("rowRenderer")],ah.prototype,"rowRenderer",2),nh([he("focusService")],ah.prototype,"focusService",2),nh([(oh=ge("loggerFactory"),(e,t)=>oh(e,t,0))],ah.prototype,"setBeans",1),nh([ce],ah.prototype,"destroyAllBlocks",1);var lh=ah,ch=class extends nt{getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}ensureRowHeightsValid(e,t,i,r){return!1}init(){this.gos.isRowModelType("infinite")&&(this.rowHeight=this.gos.getRowHeightAsNumber(),this.addEventListeners(),this.addDestroyFunc(()=>this.destroyCache()),this.verifyProps())}verifyProps(){this.gos.exists("initialGroupOrderComparator")&&cn.warnOnce("initialGroupOrderComparator cannot be used with Infinite Row Model as sorting is done on the server side")}start(){this.setDatasource(this.gos.get("datasource"))}destroyDatasource(){this.datasource&&(this.getContext().destroyBean(this.datasource),this.rowRenderer.datasourceChanged(),this.datasource=null)}addEventListeners(){this.addManagedListener(this.eventService,ct.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_SORT_CHANGED,this.onSortChanged.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverything.bind(this)),this.addManagedListener(this.eventService,ct.EVENT_STORE_UPDATED,this.onCacheUpdated.bind(this)),this.addManagedPropertyListener("datasource",()=>this.setDatasource(this.gos.get("datasource"))),this.addManagedPropertyListener("cacheBlockSize",()=>this.resetCache()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=this.gos.getRowHeightAsNumber(),this.cacheParams.rowHeight=this.rowHeight,this.updateRowHeights()})}onFilterChanged(){this.reset()}onSortChanged(){this.reset()}onColumnEverything(){let e;e=!this.cacheParams||this.isSortModelDifferent(),e&&this.reset()}isSortModelDifferent(){return!cn.jsonEquals(this.cacheParams.sortModel,this.sortController.getSortModel())}getType(){return"infinite"}setDatasource(e){this.destroyDatasource(),this.datasource=e,e&&this.reset()}isEmpty(){return!this.infiniteCache}isRowsToRender(){return!!this.infiniteCache}getNodesInRangeForSelection(e,t){return this.infiniteCache?this.infiniteCache.getRowNodesInRange(e,t):[]}reset(){this.datasource&&(null!=this.gos.getCallback("getRowId")||this.selectionService.reset("rowDataChanged"),this.resetCache())}createModelUpdatedEvent(){return{type:ct.EVENT_MODEL_UPDATED,newPage:!1,newPageSize:!1,newData:!1,keepRenderedRows:!0,animate:!1}}resetCache(){this.destroyCache(),this.cacheParams={datasource:this.datasource,filterModel:this.filterManager.getFilterModel(),sortModel:this.sortController.getSortModel(),rowNodeBlockLoader:this.rowNodeBlockLoader,initialRowCount:this.gos.get("infiniteInitialRowCount"),maxBlocksInCache:this.gos.get("maxBlocksInCache"),rowHeight:this.gos.getRowHeightAsNumber(),overflowSize:this.gos.get("cacheOverflowSize"),blockSize:this.gos.get("cacheBlockSize"),lastAccessedSequence:new un},this.infiniteCache=this.createBean(new lh(this.cacheParams)),this.eventService.dispatchEventOnce({type:ct.EVENT_ROW_COUNT_READY});const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)});const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}destroyCache(){this.infiniteCache&&(this.infiniteCache=this.destroyBean(this.infiniteCache))}onCacheUpdated(){const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}getRow(e){if(this.infiniteCache&&!(e>=this.infiniteCache.getRowCount()))return this.infiniteCache.getRow(e)}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}forEachNode(e){this.infiniteCache&&this.infiniteCache.forEachNodeDeep(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}getRowIndexAtPixel(e){if(0!==this.rowHeight){const t=Math.floor(e/this.rowHeight),i=this.getRowCount()-1;return t>i?i:t}return 0}getRowCount(){return this.infiniteCache?this.infiniteCache.getRowCount():0}isRowPresent(e){return!!this.getRowNode(e.id)}refreshCache(){this.infiniteCache&&this.infiniteCache.refreshCache()}purgeCache(){this.infiniteCache&&this.infiniteCache.purgeCache()}isLastRowIndexKnown(){return!!this.infiniteCache&&this.infiniteCache.isLastRowIndexKnown()}setRowCount(e,t){this.infiniteCache&&this.infiniteCache.setRowCount(e,t)}};nh([he("filterManager")],ch.prototype,"filterManager",2),nh([he("sortController")],ch.prototype,"sortController",2),nh([he("selectionService")],ch.prototype,"selectionService",2),nh([he("rowRenderer")],ch.prototype,"rowRenderer",2),nh([he("rowNodeBlockLoader")],ch.prototype,"rowNodeBlockLoader",2),nh([le],ch.prototype,"init",1),nh([ce],ch.prototype,"destroyDatasource",1);var uh={version:"31.3.4",moduleName:"@ag-grid-community/infinite-row-model",rowModel:"infinite",beans:[ch=nh([ue("rowModel")],ch)]},hh=Object.defineProperty,dh=Object.defineProperties,ph=Object.getOwnPropertyDescriptor,gh=Object.getOwnPropertyDescriptors,fh=Object.getOwnPropertySymbols,mh=Object.prototype.hasOwnProperty,vh=Object.prototype.propertyIsEnumerable,Ch=(e,t,i)=>t in e?hh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,yh=(e,t)=>{for(var i in t||(t={}))mh.call(t,i)&&Ch(e,i,t[i]);if(fh)for(var i of fh(t))vh.call(t,i)&&Ch(e,i,t[i]);return e},wh=(e,t)=>dh(e,gh(t)),Sh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?ph(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&hh(t,i,s),s},bh=(e,t,i)=>new Promise((r,n)=>{var s=e=>{try{a(i.next(e))}catch(e){n(e)}},o=e=>{try{a(i.throw(e))}catch(e){n(e)}},a=e=>e.done?r(e.value):Promise.resolve(e.value).then(s,o);a((i=i.apply(e,t)).next())}),Eh=class{setBeans(e){this.beans=e}getFileName(e){const t=this.getDefaultFileExtension();return null!=e&&e.length||(e=this.getDefaultFileName()),-1===e.indexOf(".")?`${e}.${t}`:e}getData(e){const t=this.createSerializingSession(e);return this.beans.gridSerializer.serialize(t,e)}getDefaultFileName(){return`export.${this.getDefaultFileExtension()}`}},Ah=class{constructor(e){this.groupColumns=[];const{columnModel:t,valueService:i,gos:r,processCellCallback:n,processHeaderCallback:s,processGroupHeaderCallback:o,processRowGroupCallback:a}=e;this.columnModel=t,this.valueService=i,this.gos=r,this.processCellCallback=n,this.processHeaderCallback=s,this.processGroupHeaderCallback=o,this.processRowGroupCallback=a}prepare(e){this.groupColumns=e.filter(e=>!!e.getColDef().showRowGroup)}extractHeaderValue(e){const t=this.getHeaderName(this.processHeaderCallback,e);return null!=t?t:""}extractRowCellValue(e,t,i,r,n){const s=this.gos.get("groupHideOpenParents")&&!n.footer||!this.shouldRenderGroupSummaryCell(n,e,t)?this.valueService.getValue(e,n):this.createValueForGroupNode(e,n);return this.processCell({accumulatedRowIndex:i,rowNode:n,column:e,value:s,processCellCallback:this.processCellCallback,type:r})}shouldRenderGroupSummaryCell(e,t,i){var r;if(!e||!e.group)return!1;if(-1!==this.groupColumns.indexOf(t)){if(null!=(null==(r=e.groupData)?void 0:r[t.getId()]))return!0;if(this.gos.isRowModelType("serverSide")&&e.group)return!0;if(e.footer&&-1===e.level){const e=t.getColDef();return null==e||!0===e.showRowGroup||e.showRowGroup===this.columnModel.getRowGroupColumns()[0].getId()}}const n=this.gos.isGroupUseEntireRow(this.columnModel.isPivotMode());return 0===i&&n}getHeaderName(e,t){return e?e(this.gos.addGridCommonParams({column:t})):this.columnModel.getDisplayNameForColumn(t,"csv",!0)}createValueForGroupNode(e,t){if(this.processRowGroupCallback)return this.processRowGroupCallback(this.gos.addGridCommonParams({column:e,node:t}));const i=this.gos.get("treeData"),r=this.gos.get("suppressGroupMaintainValueType"),n=t=>{var n,s;if(i||r)return t.key;const o=null==(n=t.groupData)?void 0:n[e.getId()];return o&&t.rowGroupColumn&&!1!==t.rowGroupColumn.getColDef().useValueFormatterForExport&&null!=(s=this.valueService.formatValue(t.rowGroupColumn,t,o))?s:o},s=t.footer,o=[n(t)];if(!this.gos.isGroupMultiAutoColumn())for(;t.parent;)t=t.parent,o.push(n(t));const a=o.reverse().join(" -> ");return s?`Total ${a}`:a}processCell(e){var t;const{accumulatedRowIndex:i,rowNode:r,column:n,value:s,processCellCallback:o,type:a}=e;return o?{value:null!=(t=o(this.gos.addGridCommonParams({accumulatedRowIndex:i,column:n,node:r,value:s,type:a,parseValue:e=>this.valueService.parseValue(n,r,e,this.valueService.getValue(n,r)),formatValue:e=>{var t;return null!=(t=this.valueService.formatValue(n,r,e))?t:e}})))?t:""}:!1!==n.getColDef().useValueFormatterForExport?{value:null!=s?s:"",valueFormatted:this.valueService.formatValue(n,r,s)}:{value:null!=s?s:""}}},Th=class{static download(e,t){const i=document.defaultView||window;if(!i)return void console.warn("AG Grid: There is no `window` associated with the current `document`");const r=document.createElement("a"),n=i.URL.createObjectURL(t);r.setAttribute("href",n),r.setAttribute("download",e),r.style.display="none",document.body.appendChild(r),r.dispatchEvent(new MouseEvent("click",{bubbles:!1,cancelable:!0,view:i})),document.body.removeChild(r),i.setTimeout(()=>{i.URL.revokeObjectURL(n)},0)}},Mh=class extends Ah{constructor(e){super(e),this.isFirstLine=!0,this.result="";const{suppressQuotes:t,columnSeparator:i}=e;this.suppressQuotes=t,this.columnSeparator=i}addCustomContent(e){e&&("string"==typeof e?(/^\s*\n/.test(e)||this.beginNewLine(),e=e.replace(/\r?\n/g,"\r\n"),this.result+=e):e.forEach(e=>{this.beginNewLine(),e.forEach((e,t)=>{0!==t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(e.data.value||""),e.mergeAcross&&this.appendEmptyCells(e.mergeAcross)})}))}onNewHeaderGroupingRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderGroupingRowColumn.bind(this)}}onNewHeaderGroupingRowColumn(e,t,i,r){0!=i&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(t),this.appendEmptyCells(r)}appendEmptyCells(e){for(let t=1;t<=e;t++)this.result+=this.columnSeparator+this.putInQuotes("")}onNewHeaderRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderRowColumn.bind(this)}}onNewHeaderRowColumn(e,t){0!=t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(this.extractHeaderValue(e))}onNewBodyRow(){return this.beginNewLine(),{onColumn:this.onNewBodyRowColumn.bind(this)}}onNewBodyRowColumn(e,t,i){var r;0!=t&&(this.result+=this.columnSeparator);const n=this.extractRowCellValue(e,t,t,"csv",i);this.result+=this.putInQuotes(null!=(r=n.valueFormatted)?r:n.value)}putInQuotes(e){if(this.suppressQuotes)return e;if(null==e)return'""';let t;return"string"==typeof e?t=e:"function"==typeof e.toString?t=e.toString():(console.warn("AG Grid: unknown value type during csv conversion"),t=""),'"'+t.replace(/"/g,'""')+'"'}parse(){return this.result}beginNewLine(){this.isFirstLine||(this.result+="\r\n"),this.isFirstLine=!1}},Rh=class extends Eh{postConstruct(){this.setBeans({gridSerializer:this.gridSerializer,gos:this.gos})}getMergedParams(e){const t=this.gos.get("defaultCsvExportParams");return Object.assign({},t,e)}export(e){if(this.isExportSuppressed())return void console.warn("AG Grid: Export cancelled. Export is not allowed as per your configuration.");const t=this.getMergedParams(e),i=this.getData(t),r=new Blob(["\ufeff",i],{type:"text/plain"}),n="function"==typeof t.fileName?t.fileName(this.gos.getGridCommonParams()):t.fileName;Th.download(this.getFileName(n),r)}exportDataAsCsv(e){this.export(e)}getDataAsCsv(e,t=!1){const i=t?Object.assign({},e):this.getMergedParams(e);return this.getData(i)}getDefaultFileExtension(){return"csv"}createSerializingSession(e){const{columnModel:t,valueService:i,gos:r}=this,{processCellCallback:n,processHeaderCallback:s,processGroupHeaderCallback:o,processRowGroupCallback:a,suppressQuotes:l,columnSeparator:c}=e;return new Mh({columnModel:t,valueService:i,gos:r,processCellCallback:n||void 0,processHeaderCallback:s||void 0,processGroupHeaderCallback:o||void 0,processRowGroupCallback:a||void 0,suppressQuotes:l||!1,columnSeparator:c||","})}isExportSuppressed(){return this.gos.get("suppressCsvExport")}};Sh([he("columnModel")],Rh.prototype,"columnModel",2),Sh([he("valueService")],Rh.prototype,"valueService",2),Sh([he("gridSerializer")],Rh.prototype,"gridSerializer",2),Sh([he("gridOptionsService")],Rh.prototype,"gos",2),Sh([le],Rh.prototype,"postConstruct",1),Rh=Sh([ue("csvCreator")],Rh);var _h=(e=>(e[e.HEADER_GROUPING=0]="HEADER_GROUPING",e[e.HEADER=1]="HEADER",e[e.BODY=2]="BODY",e))(_h||{}),Ph=class extends nt{serialize(e,t={}){const{allColumns:i,columnKeys:r,skipRowGroups:n}=t,s=this.getColumnsToExport(i,n,r);return cn.compose(this.prepareSession(s),this.prependContent(t),this.exportColumnGroups(t,s),this.exportHeaders(t,s),this.processPinnedTopRows(t,s),this.processRows(t,s),this.processPinnedBottomRows(t,s),this.appendContent(t))(e).parse()}processRow(e,t,i,r){const n=t.shouldRowBeSkipped||(()=>!1),s=this.gos.get("groupRemoveSingleChildren"),o=this.gos.get("groupRemoveLowestSingleChildren"),a=null!=t.rowPositions||!!t.onlySelected,l=this.gos.get("groupHideOpenParents")&&!a,c=this.columnModel.isPivotMode()?r.leafGroup:!r.group,u=!!r.footer,h=(t.skipRowGroups,o&&r.leafGroup),d=1===r.allChildrenCount&&(s||h);if(!c&&!u&&(t.skipRowGroups||d||l)||t.onlySelected&&!r.isSelected()||t.skipPinnedTop&&"top"===r.rowPinned||t.skipPinnedBottom&&"bottom"===r.rowPinned)return;if(-1===r.level&&!c&&!u)return;if(n(this.gos.addGridCommonParams({node:r})))return;const p=e.onNewBodyRow(r);if(i.forEach((e,t)=>{p.onColumn(e,t,r)}),t.getCustomContentBelowRow){const i=t.getCustomContentBelowRow(this.gos.addGridCommonParams({node:r}));i&&e.addCustomContent(i)}}appendContent(e){return t=>{const i=e.appendContent;return i&&t.addCustomContent(i),t}}prependContent(e){return t=>{const i=e.prependContent;return i&&t.addCustomContent(i),t}}prepareSession(e){return t=>(t.prepare(e),t)}exportColumnGroups(e,t){return i=>{if(!e.skipColumnGroupHeaders){const r=new ht,n=this.displayedGroupCreator.createDisplayedGroups(t,r,null);this.recursivelyAddHeaderGroups(n,i,e.processGroupHeaderCallback)}return i}}exportHeaders(e,t){return i=>{if(!e.skipColumnHeaders){const e=i.onNewHeaderRow();t.forEach((t,i)=>{e.onColumn(t,i,void 0)})}return i}}processPinnedTopRows(e,t){return i=>{const r=this.processRow.bind(this,i,e,t);return e.rowPositions?e.rowPositions.filter(e=>"top"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel.getPinnedTopRow(e.rowIndex)).forEach(r):this.pinnedRowModel.forEachPinnedTopRow(r),i}}processRows(e,t){return i=>{const r=this.rowModel,n=r.getType(),s="clientSide"===n,o="serverSide"===n,a=!s&&e.onlySelected,l=this.processRow.bind(this,i,e,t),{exportedRows:c="filteredAndSorted"}=e;if(e.rowPositions)e.rowPositions.filter(e=>null==e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>r.getRow(e.rowIndex)).forEach(l);else if(this.columnModel.isPivotMode())s?r.forEachPivotNode(l,!0):o?r.forEachNodeAfterFilterAndSort(l,!0):r.forEachNode(l);else if(e.onlySelectedAllPages||a){const e=this.selectionService.getSelectedNodes();this.replicateSortedOrder(e),e.forEach(l)}else"all"===c?r.forEachNode(l):s||o?r.forEachNodeAfterFilterAndSort(l,!0):r.forEachNode(l);return i}}replicateSortedOrder(e){const t=this.sortController.getSortOptions(),i=(e,r)=>{var n,s,o,a;return null!=e.rowIndex&&null!=r.rowIndex?e.rowIndex-r.rowIndex:e.level===r.level?(null==(n=e.parent)?void 0:n.id)===(null==(s=r.parent)?void 0:s.id)?this.rowNodeSorter.compareRowNodes(t,{rowNode:e,currentPos:null!=(o=e.rowIndex)?o:-1},{rowNode:r,currentPos:null!=(a=r.rowIndex)?a:-1}):i(e.parent,r.parent):e.level>r.level?i(e.parent,r):i(e,r.parent)};e.sort(i)}processPinnedBottomRows(e,t){return i=>{const r=this.processRow.bind(this,i,e,t);return e.rowPositions?e.rowPositions.filter(e=>"bottom"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel.getPinnedBottomRow(e.rowIndex)).forEach(r):this.pinnedRowModel.forEachPinnedBottomRow(r),i}}getColumnsToExport(e=!1,t=!1,i){const r=this.columnModel.isPivotMode();if(i&&i.length)return this.columnModel.getGridColumns(i);const n=this.gos.get("treeData");let s=[];return s=e&&!r?this.columnModel.getAllGridColumns():this.columnModel.getAllDisplayedColumns(),t&&!n&&(s=s.filter(e=>e.getColId()!==dt)),s}recursivelyAddHeaderGroups(e,t,i){const r=[];e.forEach(e=>{const t=e;t.getChildren&&t.getChildren().forEach(e=>r.push(e))}),e.length>0&&e[0]instanceof lt&&this.doAddHeaderHeader(t,e,i),r&&r.length>0&&this.recursivelyAddHeaderGroups(r,t,i)}doAddHeaderHeader(e,t,i){const r=e.onNewHeaderGroupingRow();let n=0;t.forEach(e=>{const t=e;let s;s=i?i(this.gos.addGridCommonParams({columnGroup:t})):this.columnModel.getDisplayNameForColumnGroup(t,"header");const o=t.getLeafColumns().reduce((e,t,i,r)=>{let n=cn.last(e);return"open"===t.getColumnGroupShow()?n&&null==n[1]||(n=[i],e.push(n)):n&&null==n[1]&&(n[1]=i-1),i===r.length-1&&n&&null==n[1]&&(n[1]=i),e},[]);r.onColumn(t,s||"",n++,t.getLeafColumns().length-1,o)})}};Sh([he("displayedGroupCreator")],Ph.prototype,"displayedGroupCreator",2),Sh([he("columnModel")],Ph.prototype,"columnModel",2),Sh([he("rowModel")],Ph.prototype,"rowModel",2),Sh([he("pinnedRowModel")],Ph.prototype,"pinnedRowModel",2),Sh([he("selectionService")],Ph.prototype,"selectionService",2),Sh([he("rowNodeSorter")],Ph.prototype,"rowNodeSorter",2),Sh([he("sortController")],Ph.prototype,"sortController",2),Ph=Sh([ue("gridSerializer")],Ph);var xh={version:"31.3.4",moduleName:"@ag-grid-community/csv-export",beans:[Rh,Ph]},Dh="\r\n",Ih=class{static createHeader(e={}){const t=["version"];return e.version||(e.version="1.0"),e.encoding&&t.push("encoding"),e.standalone&&t.push("standalone"),`<?xml ${t.map(t=>`${t}="${e[t]}"`).join(" ")} ?>`}static createXml(e,t){let i="";e.properties&&(e.properties.prefixedAttributes&&e.properties.prefixedAttributes.forEach(e=>{Object.keys(e.map).forEach(r=>{i+=this.returnAttributeIfPopulated(e.prefix+r,e.map[r],t)})}),e.properties.rawMap&&Object.keys(e.properties.rawMap).forEach(r=>{i+=this.returnAttributeIfPopulated(r,e.properties.rawMap[r],t)}));let r="<"+e.name+i;return e.children||null!=e.textNode?null!=e.textNode?r+">"+e.textNode+"</"+e.name+">"+Dh:(r+=">\r\n",e.children&&e.children.forEach(e=>{r+=this.createXml(e,t)}),r+"</"+e.name+">"+Dh):r+"/>"+Dh}static returnAttributeIfPopulated(e,t,i){if(!t&&""!==t&&0!==t)return"";let r=t;return"boolean"==typeof t&&i&&(r=i(t)),` ${e}="${r}"`}};function Lh(e,t){let i="";for(let r=0;r<t;r++)i+=String.fromCharCode(255&e),e>>>=8;return i}var Nh=e=>e.length?(e=>{if(!e.length)return 0;let t=-1,i=0,r=0,n=0;for(let s=0;s<e.length;s++)i=e[s],r=255&(t^i),n=Oh[r],t=t>>>8^n;return-1^t})("string"==typeof e?(new TextEncoder).encode(e):e):0,Oh=new Uint32Array([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]),{utf8_encode:Fh}=cn,kh=(e,t)=>bh(void 0,null,function*(){const{content:i}=e,{size:r,content:n}=i?Hh(i):{size:0,content:Uint8Array.from([])};let s,o,a=!1;if("file"===e.type&&n&&r>0){const e=yield(e=>bh(void 0,null,function*(){const t=new Blob([e]),{size:i,content:r}=yield(n=t,bh(void 0,null,function*(){let e=0;const t=[],i=new WritableStream({write:i=>{t.push(i),e+=i.length}}),r=new ReadableStream({start:e=>{const t=new FileReader;t.onload=t=>{var i;(null==(i=t.target)?void 0:i.result)&&e.enqueue(t.target.result),e.close()},t.readAsArrayBuffer(n)}}),s=new window.CompressionStream("deflate-raw");return yield r.pipeThrough(s).pipeTo(i),{size:e,content:new Blob(t)}}));var n;return{size:i,content:new Uint8Array(yield r.arrayBuffer())}}))(n);s=e.content,o=e.size,a=!0}const l=Vh(e,a,t,r,n,o);return wh(yh({},l),{content:s||n,isCompressed:a})}),Gh=(e,t)=>{const{content:i}=e,{content:r}=i?Hh(i):{content:Uint8Array.from([])},n=Vh(e,!1,t,r.length,r,void 0);return wh(yh({},n),{content:r,isCompressed:!1})},Vh=(e,t,i,r,n,s)=>{const{content:o,path:a,created:l}=e,c=(e=>{let t=e.getHours();return t<<=6,t|=e.getMinutes(),t<<=5,t|=e.getSeconds()/2,t})(l),u=(e=>{let t=e.getFullYear()-1980;return t<<=4,t|=e.getMonth()+1,t<<=5,t|=e.getDate(),t})(l),h=Nh(n),d=void 0!==s?s:r,p=Fh(a),g=p!==a;let f="";if(g){const e=Lh(1,1)+Lh(Nh(p),4)+p;f="up"+Lh(e.length,2)+e}const m="\0"+(g?"\0\b":"\0\0")+Lh(t?8:0,2)+Lh(c,2)+Lh(u,2)+Lh(d?h:0,4)+Lh(null!=s?s:r,4)+Lh(r,4)+Lh(p.length,2)+Lh(f.length,2),v="PK"+m+p+f,C="PK\0"+m+"\0\0\0\0\0\0"+(o?"\0\0\0\0":"\0\0\0")+Lh(i,4)+p+f;return{localFileHeader:Uint8Array.from(v,e=>e.charCodeAt(0)),centralDirectoryHeader:Uint8Array.from(C,e=>e.charCodeAt(0))}},Hh=e=>{let t;return t="string"==typeof e?(e=>{const t=new Uint8Array(e.length);for(let i=0;i<e.length;i++)t[i]=e.charCodeAt(i);return t})(atob(e.split(";base64,")[1])):e,{size:t.length,content:t}},Bh=class{static addFolders(e){e.forEach(this.addFolder.bind(this))}static addFolder(e){this.folders.push({path:e,created:new Date,isBase64:!1,type:"folder"})}static addFile(e,t,i=!1){this.files.push({path:e,created:new Date,content:i?t:(new TextEncoder).encode(t),isBase64:i,type:"file"})}static getZipFile(e="application/zip"){return bh(this,null,function*(){const t=yield this.buildCompressedFileStream();return this.clearStream(),new Blob([t],{type:e})})}static getUncompressedZipFile(e="application/zip"){const t=this.buildFileStream();return this.clearStream(),new Blob([t],{type:e})}static clearStream(){this.folders=[],this.files=[]}static packageFiles(e){let t=new Uint8Array(0),i=new Uint8Array(0),r=0,n=0;for(const s of e){const{localFileHeader:e,centralDirectoryHeader:o,content:a}=s,l=new Uint8Array(t.length+e.length);l.set(t),l.set(e,t.length),t=l;const c=new Uint8Array(t.length+a.length);c.set(t),c.set(a,t.length),t=c;const u=new Uint8Array(i.length+o.length);u.set(i),u.set(o,i.length),i=u,r+=e.length+a.length,n+=o.length}const s=((e,t,i)=>{const r="PK\0\0\0\0"+Lh(e,2)+Lh(e,2)+Lh(t,4)+Lh(i,4)+"\0\0";return Uint8Array.from(r,e=>e.charCodeAt(0))})(e.length,n,r),o=new Uint8Array(t.length+i.length+s.length);return o.set(t),o.set(i,t.length),o.set(s,t.length+i.length),o}static buildCompressedFileStream(){return bh(this,null,function*(){const e=[...this.folders,...this.files],t=[];let i=0;for(const r of e){const e=yield kh(r,i),{localFileHeader:n,content:s}=e;t.push(e),i+=n.length+s.length}return this.packageFiles(t)})}static buildFileStream(){const e=[...this.folders,...this.files],t=[];let i=0;for(const r of e){const e=Gh(r,i),{localFileHeader:n,content:s}=e;t.push(e),i+=n.length+s.length}return this.packageFiles(t)}};Bh.folders=[],Bh.files=[],se.__registerModules([th,uh,xh],!1,void 0)},67748(e,t,i){var r,n=Object.defineProperty,s=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,l=(e,t)=>{for(var i in t)n(e,i,{get:t[i],enumerable:!0})},c=(e,t,i,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let l of o(t))a.call(e,l)||l===i||n(e,l,{get:()=>t[l],enumerable:!(r=s(t,l))||r.enumerable});return e},u=(e,t,i)=>(c(e,t,"default"),i&&c(i,t,"default")),h=(e,t,i,r)=>{for(var o,a=r>1?void 0:r?s(t,i):t,l=e.length-1;l>=0;l--)(o=e[l])&&(a=(r?o(t,i,a):o(a))||a);return r&&a&&n(t,i,a),a},d={};l(d,{ALWAYS_SYNC_GLOBAL_EVENTS:()=>Yv.ALWAYS_SYNC_GLOBAL_EVENTS,AbstractHeaderCellCtrl:()=>Qv.AbstractHeaderCellCtrl,AdvancedFilterModule:()=>ke,AgAbstractField:()=>Xv.AgAbstractField,AgAbstractLabel:()=>Zv.AgAbstractLabel,AgAutocomplete:()=>Jv.AgAutocomplete,AgCheckbox:()=>eC.AgCheckbox,AgDialog:()=>tC.AgDialog,AgGroupComponent:()=>iC.AgGroupComponent,AgInputDateField:()=>rC.AgInputDateField,AgInputNumberField:()=>nC.AgInputNumberField,AgInputRange:()=>sC.AgInputRange,AgInputTextArea:()=>oC.AgInputTextArea,AgInputTextField:()=>aC.AgInputTextField,AgMenuItemComponent:()=>lC.AgMenuItemComponent,AgMenuItemRenderer:()=>cC.AgMenuItemRenderer,AgMenuList:()=>uC.AgMenuList,AgMenuPanel:()=>hC.AgMenuPanel,AgPanel:()=>dC.AgPanel,AgPickerField:()=>pC.AgPickerField,AgPromise:()=>gC.AgPromise,AgPromiseStatus:()=>fC.AgPromiseStatus,AgRadioButton:()=>mC.AgRadioButton,AgRichSelect:()=>vC.AgRichSelect,AgSelect:()=>CC.AgSelect,AgSlider:()=>yC.AgSlider,AgStackComponentsRegistry:()=>wC.AgStackComponentsRegistry,AgToggleButton:()=>SC.AgToggleButton,AlignedGridsService:()=>bC.AlignedGridsService,AnimateShowChangeCellRenderer:()=>EC.AnimateShowChangeCellRenderer,AnimateSlideCellRenderer:()=>AC.AnimateSlideCellRenderer,AnimationFrameService:()=>TC.AnimationFrameService,AutoScrollService:()=>MC.AutoScrollService,AutoWidthCalculator:()=>RC.AutoWidthCalculator,Autowired:()=>_C.Autowired,BarColumnLabelPlacement:()=>PC.BarColumnLabelPlacement,BaseComponentWrapper:()=>xC.BaseComponentWrapper,Bean:()=>DC.Bean,BeanStub:()=>IC.BeanStub,Beans:()=>LC.Beans,BodyDropPivotTarget:()=>NC.BodyDropPivotTarget,BodyDropTarget:()=>OC.BodyDropTarget,CellComp:()=>FC.CellComp,CellCtrl:()=>kC.CellCtrl,CellNavigationService:()=>GC.CellNavigationService,CellPositionUtils:()=>VC.CellPositionUtils,CellRangeType:()=>HC.CellRangeType,ChangedPath:()=>BC.ChangedPath,ChartMappings:()=>zC.ChartMappings,CheckboxCellEditor:()=>UC.CheckboxCellEditor,CheckboxCellRenderer:()=>WC.CheckboxCellRenderer,CheckboxSelectionComponent:()=>jC.CheckboxSelectionComponent,ClientSideRowModelSteps:()=>KC.ClientSideRowModelSteps,ClipboardModule:()=>pl,Column:()=>$C.Column,ColumnApi:()=>qC.ColumnApi,ColumnFactory:()=>YC.ColumnFactory,ColumnGroup:()=>QC.ColumnGroup,ColumnKeyCreator:()=>XC.ColumnKeyCreator,ColumnModel:()=>ZC.ColumnModel,ColumnsToolPanelModule:()=>Ou,Component:()=>JC.Component,ComponentUtil:()=>ey.ComponentUtil,Context:()=>ty.Context,CssClassApplier:()=>iy.CssClassApplier,CssClassManager:()=>ry.CssClassManager,CtrlsService:()=>ny.CtrlsService,DataTypeService:()=>sy.DataTypeService,DateCellEditor:()=>oy.DateCellEditor,DateFilter:()=>ay.DateFilter,DateStringCellEditor:()=>ly.DateStringCellEditor,DisplayedGroupCreator:()=>cy.DisplayedGroupCreator,DragAndDropService:()=>uy.DragAndDropService,DragService:()=>hy.DragService,DragSourceType:()=>dy.DragSourceType,EnterpriseCoreModule:()=>_,Environment:()=>py.Environment,EventService:()=>gy.EventService,Events:()=>fy.Events,ExcelExportModule:()=>jd,ExcelFactoryMode:()=>my.ExcelFactoryMode,ExpansionService:()=>vy.ExpansionService,ExpressionService:()=>Cy.ExpressionService,FilterManager:()=>yy.FilterManager,FilterWrapperComp:()=>wy.FilterWrapperComp,FiltersToolPanelModule:()=>fp,FloatingFilterMapper:()=>Sy.FloatingFilterMapper,FocusService:()=>by.FocusService,GROUP_AUTO_COLUMN_ID:()=>Ey.GROUP_AUTO_COLUMN_ID,Grid:()=>Ay.Grid,GridApi:()=>Ty.GridApi,GridBodyComp:()=>My.GridBodyComp,GridBodyCtrl:()=>Ry.GridBodyCtrl,GridChartsModule:()=>Ja,GridComp:()=>_y.GridComp,GridCoreCreator:()=>Py.GridCoreCreator,GridCtrl:()=>xy.GridCtrl,GridHeaderComp:()=>Dy.GridHeaderComp,GridHeaderCtrl:()=>Iy.GridHeaderCtrl,GridOptionsService:()=>Ly.GridOptionsService,GroupCellRenderer:()=>Ny.GroupCellRenderer,GroupCellRendererCtrl:()=>Oy.GroupCellRendererCtrl,GroupInstanceIdCreator:()=>Fy.GroupInstanceIdCreator,HeaderCellCtrl:()=>ky.HeaderCellCtrl,HeaderFilterCellComp:()=>Gy.HeaderFilterCellComp,HeaderFilterCellCtrl:()=>Vy.HeaderFilterCellCtrl,HeaderGroupCellCtrl:()=>Hy.HeaderGroupCellCtrl,HeaderNavigationDirection:()=>By.HeaderNavigationDirection,HeaderNavigationService:()=>zy.HeaderNavigationService,HeaderPositionUtils:()=>Uy.HeaderPositionUtils,HeaderRowComp:()=>Wy.HeaderRowComp,HeaderRowContainerComp:()=>jy.HeaderRowContainerComp,HeaderRowContainerCtrl:()=>Ky.HeaderRowContainerCtrl,HeaderRowCtrl:()=>$y.HeaderRowCtrl,HeaderRowType:()=>qy.HeaderRowType,HorizontalDirection:()=>Yy.HorizontalDirection,HorizontalResizeService:()=>Qy.HorizontalResizeService,KeyCode:()=>Xy.KeyCode,LargeTextCellEditor:()=>Zy.LargeTextCellEditor,LayoutCssClasses:()=>Jy.LayoutCssClasses,LicenseManager:()=>T,LocaleService:()=>ew.LocaleService,Logger:()=>tw.Logger,LoggerFactory:()=>iw.LoggerFactory,ManagedFocusFeature:()=>rw.ManagedFocusFeature,MasterDetailModule:()=>Pp,MenuModule:()=>cg,MenuService:()=>nw.MenuService,ModuleNames:()=>sw.ModuleNames,ModuleRegistry:()=>ow.ModuleRegistry,MouseEventService:()=>aw.MouseEventService,MoveColumnFeature:()=>lw.MoveColumnFeature,MultiFilter:()=>Tg,MultiFilterModule:()=>Rg,NavigationService:()=>cw.NavigationService,NumberCellEditor:()=>uw.NumberCellEditor,NumberFilter:()=>hw.NumberFilter,NumberSequence:()=>dw.NumberSequence,Optional:()=>pw.Optional,PaginationProxy:()=>gw.PaginationProxy,PillDragComp:()=>fw.PillDragComp,PillDropZonePanel:()=>mw.PillDropZonePanel,PinnedRowModel:()=>vw.PinnedRowModel,PivotDropZonePanel:()=>dc,PopupComponent:()=>Cw.PopupComponent,PopupEditorWrapper:()=>yw.PopupEditorWrapper,PopupService:()=>ww.PopupService,PositionableFeature:()=>Sw.PositionableFeature,PostConstruct:()=>bw.PostConstruct,PreConstruct:()=>Ew.PreConstruct,PreDestroy:()=>Aw.PreDestroy,PrimaryColsPanel:()=>bu,PropertyKeys:()=>Tw.PropertyKeys,ProvidedColumnGroup:()=>Mw.ProvidedColumnGroup,ProvidedFilter:()=>Rw.ProvidedFilter,Qualifier:()=>_w.Qualifier,QuerySelector:()=>Pw.QuerySelector,RangeSelectionModule:()=>ht,RefSelector:()=>xw.RefSelector,ResizeObserverService:()=>Dw.ResizeObserverService,RichSelectModule:()=>Dg,RowAnimationCssClasses:()=>Iw.RowAnimationCssClasses,RowContainerComp:()=>Lw.RowContainerComp,RowContainerCtrl:()=>Nw.RowContainerCtrl,RowContainerName:()=>Ow.RowContainerName,RowContainerType:()=>Fw.RowContainerType,RowCtrl:()=>kw.RowCtrl,RowGroupDropZonePanel:()=>hc,RowGroupingModule:()=>Cc,RowHighlightPosition:()=>Gw.RowHighlightPosition,RowNode:()=>Vw.RowNode,RowNodeBlock:()=>Hw.RowNodeBlock,RowNodeBlockLoader:()=>Bw.RowNodeBlockLoader,RowNodeSorter:()=>zw.RowNodeSorter,RowPositionUtils:()=>Uw.RowPositionUtils,RowRenderer:()=>Ww.RowRenderer,ScalarFilter:()=>jw.ScalarFilter,ScrollVisibleService:()=>Kw.ScrollVisibleService,SelectCellEditor:()=>$w.SelectCellEditor,SelectableService:()=>qw.SelectableService,SelectionHandleType:()=>Yw.SelectionHandleType,ServerSideRowModelModule:()=>_f,ServerSideTransactionResultStatus:()=>Qw.ServerSideTransactionResultStatus,SetFilter:()=>Xf,SetFilterModule:()=>im,SetLeftFeature:()=>Xw.SetLeftFeature,SideBarModule:()=>Xc,SimpleFilter:()=>Zw.SimpleFilter,SortController:()=>Jw.SortController,SortIndicatorComp:()=>eS.SortIndicatorComp,SparklinesModule:()=>wv,StandardMenuFactory:()=>tS.StandardMenuFactory,StatusBarModule:()=>Bv,StylingService:()=>iS.StylingService,TabGuardClassNames:()=>rS.TabGuardClassNames,TabGuardComp:()=>nS.TabGuardComp,TabGuardCtrl:()=>sS.TabGuardCtrl,TabbedLayout:()=>oS.TabbedLayout,TextCellEditor:()=>aS.TextCellEditor,TextFilter:()=>lS.TextFilter,TextFloatingFilter:()=>cS.TextFloatingFilter,Timer:()=>uS.Timer,ToolPanelColDefService:()=>Yc,TooltipFeature:()=>hS.TooltipFeature,TooltipStateManager:()=>dS.TooltipStateManager,TouchListener:()=>pS.TouchListener,UserComponentFactory:()=>gS.UserComponentFactory,UserComponentRegistry:()=>fS.UserComponentRegistry,ValueCache:()=>mS.ValueCache,ValueService:()=>vS.ValueService,ValuesDropZonePanel:()=>yc,VanillaFrameworkOverrides:()=>CS.VanillaFrameworkOverrides,VerticalDirection:()=>yS.VerticalDirection,ViewportRowModelModule:()=>qv,VirtualList:()=>wS.VirtualList,VirtualListDragFeature:()=>SS.VirtualListDragFeature,_:()=>bS._,__FORCE_MODULE_DETECTION_AG_GRID_CORE_EXT:()=>el,agCharts:()=>tl,createGrid:()=>ES.createGrid,exportMultipleSheetsAsExcel:()=>Ud,getMultipleSheetsAsExcel:()=>zd,getRowContainerTypeForName:()=>AS.getRowContainerTypeForName,provideGlobalGridOptions:()=>TS.provideGlobalGridOptions}),e.exports=(r=d,c(n({},"__esModule",{value:!0}),r));var p=i(98092),g=i(98092),f=i(98092),m=i(98092),v=i(98092),C=i(98092),y=i(98092),w=class{constructor(){this.ieCompatibility=!1}init(){this.ieCompatibility="5d41402abc4b2a76b9719d911017c592"!=this.md5("hello")}md5cycle(e,t){let i=e[0],r=e[1],n=e[2],s=e[3];i=this.ff(i,r,n,s,t[0],7,-680876936),s=this.ff(s,i,r,n,t[1],12,-389564586),n=this.ff(n,s,i,r,t[2],17,606105819),r=this.ff(r,n,s,i,t[3],22,-1044525330),i=this.ff(i,r,n,s,t[4],7,-176418897),s=this.ff(s,i,r,n,t[5],12,1200080426),n=this.ff(n,s,i,r,t[6],17,-1473231341),r=this.ff(r,n,s,i,t[7],22,-45705983),i=this.ff(i,r,n,s,t[8],7,1770035416),s=this.ff(s,i,r,n,t[9],12,-1958414417),n=this.ff(n,s,i,r,t[10],17,-42063),r=this.ff(r,n,s,i,t[11],22,-1990404162),i=this.ff(i,r,n,s,t[12],7,1804603682),s=this.ff(s,i,r,n,t[13],12,-40341101),n=this.ff(n,s,i,r,t[14],17,-1502002290),r=this.ff(r,n,s,i,t[15],22,1236535329),i=this.gg(i,r,n,s,t[1],5,-165796510),s=this.gg(s,i,r,n,t[6],9,-1069501632),n=this.gg(n,s,i,r,t[11],14,643717713),r=this.gg(r,n,s,i,t[0],20,-373897302),i=this.gg(i,r,n,s,t[5],5,-701558691),s=this.gg(s,i,r,n,t[10],9,38016083),n=this.gg(n,s,i,r,t[15],14,-660478335),r=this.gg(r,n,s,i,t[4],20,-405537848),i=this.gg(i,r,n,s,t[9],5,568446438),s=this.gg(s,i,r,n,t[14],9,-1019803690),n=this.gg(n,s,i,r,t[3],14,-187363961),r=this.gg(r,n,s,i,t[8],20,1163531501),i=this.gg(i,r,n,s,t[13],5,-1444681467),s=this.gg(s,i,r,n,t[2],9,-51403784),n=this.gg(n,s,i,r,t[7],14,1735328473),r=this.gg(r,n,s,i,t[12],20,-1926607734),i=this.hh(i,r,n,s,t[5],4,-378558),s=this.hh(s,i,r,n,t[8],11,-2022574463),n=this.hh(n,s,i,r,t[11],16,1839030562),r=this.hh(r,n,s,i,t[14],23,-35309556),i=this.hh(i,r,n,s,t[1],4,-1530992060),s=this.hh(s,i,r,n,t[4],11,1272893353),n=this.hh(n,s,i,r,t[7],16,-155497632),r=this.hh(r,n,s,i,t[10],23,-1094730640),i=this.hh(i,r,n,s,t[13],4,681279174),s=this.hh(s,i,r,n,t[0],11,-358537222),n=this.hh(n,s,i,r,t[3],16,-722521979),r=this.hh(r,n,s,i,t[6],23,76029189),i=this.hh(i,r,n,s,t[9],4,-640364487),s=this.hh(s,i,r,n,t[12],11,-421815835),n=this.hh(n,s,i,r,t[15],16,530742520),r=this.hh(r,n,s,i,t[2],23,-995338651),i=this.ii(i,r,n,s,t[0],6,-198630844),s=this.ii(s,i,r,n,t[7],10,1126891415),n=this.ii(n,s,i,r,t[14],15,-1416354905),r=this.ii(r,n,s,i,t[5],21,-57434055),i=this.ii(i,r,n,s,t[12],6,1700485571),s=this.ii(s,i,r,n,t[3],10,-1894986606),n=this.ii(n,s,i,r,t[10],15,-1051523),r=this.ii(r,n,s,i,t[1],21,-2054922799),i=this.ii(i,r,n,s,t[8],6,1873313359),s=this.ii(s,i,r,n,t[15],10,-30611744),n=this.ii(n,s,i,r,t[6],15,-1560198380),r=this.ii(r,n,s,i,t[13],21,1309151649),i=this.ii(i,r,n,s,t[4],6,-145523070),s=this.ii(s,i,r,n,t[11],10,-1120210379),n=this.ii(n,s,i,r,t[2],15,718787259),r=this.ii(r,n,s,i,t[9],21,-343485551),e[0]=this.add32(i,e[0]),e[1]=this.add32(r,e[1]),e[2]=this.add32(n,e[2]),e[3]=this.add32(s,e[3])}cmn(e,t,i,r,n,s){return t=this.add32(this.add32(t,e),this.add32(r,s)),this.add32(t<<n|t>>>32-n,i)}ff(e,t,i,r,n,s,o){return this.cmn(t&i|~t&r,e,t,n,s,o)}gg(e,t,i,r,n,s,o){return this.cmn(t&r|i&~r,e,t,n,s,o)}hh(e,t,i,r,n,s,o){return this.cmn(t^i^r,e,t,n,s,o)}ii(e,t,i,r,n,s,o){return this.cmn(i^(t|~r),e,t,n,s,o)}md51(e){const t=e.length,i=[1732584193,-271733879,-1732584194,271733878];let r;for(r=64;r<=e.length;r+=64)this.md5cycle(i,this.md5blk(e.substring(r-64,r)));e=e.substring(r-64);const n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;r<e.length;r++)n[r>>2]|=e.charCodeAt(r)<<(r%4<<3);if(n[r>>2]|=128<<(r%4<<3),r>55)for(this.md5cycle(i,n),r=0;r<16;r++)n[r]=0;return n[14]=8*t,this.md5cycle(i,n),i}md5blk(e){const t=[];for(let i=0;i<64;i+=4)t[i>>2]=e.charCodeAt(i)+(e.charCodeAt(i+1)<<8)+(e.charCodeAt(i+2)<<16)+(e.charCodeAt(i+3)<<24);return t}rhex(e){const t="0123456789abcdef".split("");let i="",r=0;for(;r<4;r++)i+=t[e>>8*r+4&15]+t[e>>8*r&15];return i}hex(e){for(let t=0;t<e.length;t++)e[t]=this.rhex(e[t]);return e.join("")}md5(e){return this.hex(this.md51(e))}add32(e,t){return this.ieCompatibility?this.add32Compat(e,t):this.add32Std(e,t)}add32Std(e,t){return e+t&4294967295}add32Compat(e,t){const i=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(i>>16)<<16|65535&i}};function S(e){return null==e||0===e.length}var b={"01":"GRID","02":"CHARTS","0102":"BOTH"},E=class e{constructor(e){this.watermarkMessage=void 0,this.totalMessageLength=124,this.document=e,this.md5=new w,this.md5.init()}validateLicense(){const t=this.getLicenseDetails(e.licenseKey),i=`AG Grid ${"BOTH"===t.currentLicenseType?"and AG Charts ":""}Enterprise`,r=void 0===t.suppliedLicenseType?"":`AG ${"BOTH"===t.suppliedLicenseType?"Grid and AG Charts":"GRID"===t.suppliedLicenseType?"Grid":"Charts"} Enterprise`;if(t.missing)this.isWebsiteUrl()&&!this.isForceWatermark()||this.outputMissingLicenseKey(i);else if(t.expired){const n=e.getGridReleaseDate(),s=e.formatDate(n);this.outputExpiredKey(t.expiry,s,i,r)}else t.valid?t.isTrial&&t.trialExpired&&this.outputExpiredTrialKey(t.expiry,i,r):this.outputInvalidLicenseKey(!!t.incorrectLicenseType,i,r)}static extractExpiry(t){const i=t.substring(t.lastIndexOf("_")+1,t.length);return new Date(parseInt(e.decode(i),10))}static extractLicenseComponents(t){let i=t.replace(/[\u200B-\u200D\uFEFF]/g,"");if(i=i.replace(/\r?\n|\r/g,""),t.length<=32)return{md5:null,license:t,version:null,isTrial:null};const r=i.length-32,n=i.substring(r),s=i.substring(0,r),[o,a,l]=e.extractBracketedInformation(i);return{md5:n,license:s,version:o,isTrial:a,type:l}}getLicenseDetails(t){const i=e.chartsLicenseManager?"BOTH":"GRID";if(S(t))return{licenseKey:t,valid:!1,missing:!0,currentLicenseType:i};const r=e.getGridReleaseDate(),{md5:n,license:s,version:o,isTrial:a,type:l}=e.extractLicenseComponents(t);let c,u,h,d=n===this.md5.md5(s)&&-1===t.indexOf("For_Trialing_ag-Grid_Only"),p=null,g=!1;function f(){c=p<new Date,u=void 0}if(d&&(p=e.extractExpiry(s),d=!isNaN(p.getTime()),d))switch(u=r>p,o){case"legacy":case"2":a&&f();break;case"3":S(l)?d=!1:(h=l,l!==b["01"]&&l!==b["0102"]||"BOTH"===i&&"BOTH"!==h?(d=!1,g=!0):a&&f())}return d?{licenseKey:t,valid:d,expiry:e.formatDate(p),expired:u,version:o,isTrial:a,trialExpired:c,incorrectLicenseType:g,currentLicenseType:i,suppliedLicenseType:h}:{licenseKey:t,valid:d,incorrectLicenseType:g,currentLicenseType:i,suppliedLicenseType:h}}isDisplayWatermark(){return this.isForceWatermark()||!this.isLocalhost()&&!this.isWebsiteUrl()&&!S(this.watermarkMessage)}getWatermarkMessage(){return this.watermarkMessage||""}getHostname(){const e=(this.document.defaultView||window).location,{hostname:t=""}=e;return t}isForceWatermark(){const e=(this.document.defaultView||window).location,{pathname:t}=e;return!!t&&-1!==t.indexOf("forceWatermark")}isWebsiteUrl(){return null!==this.getHostname().match(/^((?:[\w-]+\.)?ag-grid\.com)$/)}isLocalhost(){return null!==this.getHostname().match(/^(?:127\.0\.0\.1|localhost)$/)}static formatDate(e){const t=e.getDate(),i=e.getMonth(),r=e.getFullYear();return t+" "+["January","February","March","April","May","June","July","August","September","October","November","December"][i]+" "+r}static getGridReleaseDate(){return new Date(parseInt(e.decode(e.RELEASE_INFORMATION),10))}static decode(t){const i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let r,n,s,o,a,l,c,u="",h=0;const d=t.replace(/[^A-Za-z0-9+/=]/g,"");for(;h<d.length;)o=i.indexOf(d.charAt(h++)),a=i.indexOf(d.charAt(h++)),l=i.indexOf(d.charAt(h++)),c=i.indexOf(d.charAt(h++)),r=o<<2|a>>4,n=(15&a)<<4|l>>2,s=(3&l)<<6|c,u+=String.fromCharCode(r),64!=l&&(u+=String.fromCharCode(n)),64!=c&&(u+=String.fromCharCode(s));return u=e.utf8_decode(u),u}static utf8_decode(e){e=e.replace(/rn/g,"n");let t="";for(let i=0;i<e.length;i++){const r=e.charCodeAt(i);r<128?t+=String.fromCharCode(r):r>127&&r<2048?(t+=String.fromCharCode(r>>6|192),t+=String.fromCharCode(63&r|128)):(t+=String.fromCharCode(r>>12|224),t+=String.fromCharCode(r>>6&63|128),t+=String.fromCharCode(63&r|128))}return t}static setChartsLicenseManager(e){this.chartsLicenseManager=e}static setLicenseKey(e){this.licenseKey=e,this.chartsLicenseManager&&this.chartsLicenseManager.setLicenseKey(e,!0)}static extractBracketedInformation(e){if(!e.includes("["))return["legacy",!1,void 0];const t=e.match(/\[(.*?)\]/g).map(e=>e.replace("[","").replace("]",""));if(!t||0===t.length)return["legacy",!1,void 0];const i=1===t.filter(e=>"TRIAL"===e).length,r=t.filter(e=>0===e.indexOf("v"))[0];return[r?r.replace("v",""):"legacy",i,b[t.filter(e=>b[e])[0]]]}centerPadAndOutput(e){const t=this.totalMessageLength-e.length;console.error(e.padStart(t/2+e.length,"*").padEnd(this.totalMessageLength,"*"))}padAndOutput(e,t="*",i=""){console.error(e.padEnd(this.totalMessageLength-i.length,t)+i)}outputInvalidLicenseKey(e,t,i){e?(this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Incompatible License Key "),this.padAndOutput(`* Your license key is for ${i} only and does not cover you for ${t}.`," ","*"),this.padAndOutput("* Please contact info@ag-grid.com to obtain a combined license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput("")):(this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Invalid License Key "),this.padAndOutput("* Your license key is not valid - please contact info@ag-grid.com to obtain a valid license."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput("")),this.watermarkMessage="Invalid License"}outputExpiredTrialKey(e,t,i){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Trial Period Expired. "),this.padAndOutput(`* Your trial only license for ${i} expired on ${e}.`," ","*"),this.padAndOutput("* Please email info@ag-grid.com to purchase a license."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="Trial Period Expired"}outputMissingLicenseKey(e){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${e} License `),this.centerPadAndOutput(" License Key Not Found "),this.padAndOutput(`* All ${e} features are unlocked for trial.`," ","*"),this.padAndOutput("* If you want to hide the watermark please email info@ag-grid.com for a trial license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="For Trial Use Only"}outputExpiredKey(e,t,i,r){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${i} License `),this.centerPadAndOutput(" Incompatible Software Version "),this.padAndOutput(`* Your license key works with versions of ${r} released before ${e}.`," ","*"),this.padAndOutput(`* The version you are trying to use was released on ${t}.`," ","*"),this.padAndOutput("* Please contact info@ag-grid.com to renew your license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="License Expired"}};E.RELEASE_INFORMATION="MTcxNTc3NTcyODYxNg==";var A=E,T=class extends y.BeanStub{validateLicense(){this.licenseManager=new A(this.gos.getDocument()),this.licenseManager.validateLicense()}static getLicenseDetails(e){return new A(null).getLicenseDetails(e)}isDisplayWatermark(){return this.licenseManager.isDisplayWatermark()}getWatermarkMessage(){return this.licenseManager.getWatermarkMessage()}static setLicenseKey(e){A.setLicenseKey(e)}static setChartsLicenseManager(e){A.setChartsLicenseManager(e)}};h([y.PreConstruct],T.prototype,"validateLicense",1),T=h([(0,y.Bean)("licenseManager")],T);var M=i(98092),R=class extends M.Component{constructor(){super('<div class="ag-watermark">\n                <div ref="eLicenseTextRef" class="ag-watermark-text"></div>\n            </div>')}postConstruct(){const e=this.shouldDisplayWatermark();this.setDisplayed(e),e&&(this.eLicenseTextRef.innerText=this.licenseManager.getWatermarkMessage(),window.setTimeout(()=>this.addCssClass("ag-opacity-zero"),0),window.setTimeout(()=>this.setDisplayed(!1),5e3))}shouldDisplayWatermark(){return this.licenseManager.isDisplayWatermark()}};h([(0,M.Autowired)("licenseManager")],R.prototype,"licenseManager",2),h([(0,M.RefSelector)("eLicenseTextRef")],R.prototype,"eLicenseTextRef",2),h([M.PostConstruct],R.prototype,"postConstruct",1);var _={version:"31.3.4",moduleName:C.ModuleNames.EnterpriseCoreModule,beans:[T],agStackComponents:[{componentName:"AgWatermark",componentClass:R}]},P=i(98092),x=i(98092),D=i(98092),I=i(98092),L=i(98092),N=i(98092),O=i(98092),F=i(98092),k=i(98092),G=i(98092),V=i(98092),H=i(98092),B=i(98092),z=i(98092),U=i(98092),W=Object.defineProperty,j=Object.defineProperties,K=Object.getOwnPropertyDescriptor,$=Object.getOwnPropertyDescriptors,q=Object.getOwnPropertySymbols,Y=Object.prototype.hasOwnProperty,Q=Object.prototype.propertyIsEnumerable,X=(e,t,i)=>t in e?W(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Z=(e,t)=>{for(var i in t||(t={}))Y.call(t,i)&&X(e,i,t[i]);if(q)for(var i of q(t))Q.call(t,i)&&X(e,i,t[i]);return e},J=(e,t)=>j(e,$(t)),ee=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?K(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&W(t,i,s),s},te=class extends D.Component{constructor(e){super('\n            <div class="ag-advanced-filter-header" role="row">\n            </div>'),this.enabled=e}postConstruct(){this.setupAdvancedFilter(this.enabled),this.addDestroyFunc(()=>this.destroyBean(this.eAdvancedFilter)),this.addManagedListener(this.eventService,D.Events.EVENT_GRID_COLUMNS_CHANGED,()=>this.onGridColumnsChanged()),this.addGuiEventListener("keydown",e=>this.onKeyDown(e)),this.addGuiEventListener("focusout",e=>{this.getFocusableElement().contains(e.relatedTarget)||this.focusService.clearAdvancedFilterColumn()})}getFocusableElement(){var e,t;return null!=(t=null==(e=this.eAdvancedFilter)?void 0:e.getGui())?t:this.getGui()}setEnabled(e){e!==this.enabled&&this.setupAdvancedFilter(e)}refresh(){var e;null==(e=this.eAdvancedFilter)||e.refresh()}getHeight(){return this.height}setInputDisabled(e){var t;null==(t=this.eAdvancedFilter)||t.setInputDisabled(e)}setupAdvancedFilter(e){const t=this.getGui();if(e){this.eAdvancedFilter=this.createBean(new ve);const e=this.eAdvancedFilter.getGui();this.eAdvancedFilter.addCssClass("ag-advanced-filter-header-cell"),this.height=this.columnModel.getFloatingFiltersHeight();const i=`${this.height}px`;t.style.height=i,t.style.minHeight=i,this.setAriaRowIndex(),D._.setAriaRole(e,"gridcell"),D._.setAriaColIndex(e,1),this.setAriaColumnCount(e),t.appendChild(e)}else D._.clearElement(t),this.destroyBean(this.eAdvancedFilter),this.height=0;D._.setDisplayed(t,e),this.enabled=e}setAriaColumnCount(e){D._.setAriaColSpan(e,this.columnModel.getAllGridColumns().length)}setAriaRowIndex(){D._.setAriaRowIndex(this.getGui(),this.headerNavigationService.getHeaderRowCount())}onGridColumnsChanged(){this.eAdvancedFilter&&(this.setAriaColumnCount(this.eAdvancedFilter.getGui()),this.setAriaRowIndex())}onKeyDown(e){switch(e.key){case D.KeyCode.ENTER:this.hasFocus()&&this.focusService.focusInto(this.getFocusableElement())&&e.preventDefault();break;case D.KeyCode.ESCAPE:this.hasFocus()||this.getFocusableElement().focus();break;case D.KeyCode.UP:this.navigateUpDown(!0,e);break;case D.KeyCode.DOWN:this.navigateUpDown(!1,e);break;case D.KeyCode.TAB:if(this.hasFocus())this.navigateLeftRight(e);else{const t=this.focusService.findNextFocusableElement(this.getFocusableElement(),null,e.shiftKey);t?(e.preventDefault(),t.focus()):this.navigateLeftRight(e)}}}navigateUpDown(e,t){this.hasFocus()&&this.focusService.focusNextFromAdvancedFilter(e)&&t.preventDefault()}navigateLeftRight(e){(e.shiftKey?this.focusService.focusLastHeader():this.focusService.focusNextFromAdvancedFilter(!1,!0))&&e.preventDefault()}hasFocus(){return this.gos.getActiveDomElement()===this.getFocusableElement()}};ee([(0,D.Autowired)("columnModel")],te.prototype,"columnModel",2),ee([(0,D.Autowired)("focusService")],te.prototype,"focusService",2),ee([(0,D.Autowired)("headerNavigationService")],te.prototype,"headerNavigationService",2),ee([D.PostConstruct],te.prototype,"postConstruct",1);var ie=class extends N.AgRichSelect{constructor(e){super(J(Z({},e),{template:'\n                <div class="ag-picker-field" role="presentation">\n                    <div ref="eLabel"></div>\n                    <div ref="eWrapper" class="ag-wrapper ag-picker-collapsed">\n                        <div ref="eDisplayField" class="ag-picker-field-display"></div>\n                        <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n                        <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n                    </div>\n                </div>'})),this.params=e}showPicker(){setTimeout(()=>super.showPicker())}hidePicker(){setTimeout(()=>super.hidePicker())}postConstruct(){super.postConstruct();const{wrapperClassName:e,ariaLabel:t}=this.params;N._.setDisplayed(this.eDisplayField,!1),e&&this.eWrapper.classList.add(e),N._.setAriaLabelledBy(this.eWrapper,""),N._.setAriaLabel(this.eWrapper,t)}onEnterKeyDown(e){N._.stopPropagationForAgGrid(e),this.isPickerDisplayed?super.onEnterKeyDown(e):(e.preventDefault(),this.showPicker())}},re=class e extends O.BeanStub{constructor(e,t){super(),this.comp=e,this.virtualList=t}postConstruct(){this.createManagedBean(new O.VirtualListDragFeature(this.comp,this.virtualList,{dragSourceType:O.DragSourceType.AdvancedFilterBuilder,listItemDragStartEvent:e.EVENT_DRAG_STARTED,listItemDragEndEvent:e.EVENT_DRAG_ENDED,eventSource:this,getCurrentDragValue:e=>this.getCurrentDragValue(e),isMoveBlocked:()=>!1,getNumRows:e=>e.getNumItems(),moveItem:(e,t)=>this.moveItem(e,t)}))}getCurrentDragValue(e){return e.item}moveItem(e,t){this.comp.moveItem(e,t)}};re.EVENT_DRAG_STARTED="advancedFilterBuilderDragStarted",re.EVENT_DRAG_ENDED="advancedFilterBuilderDragEnded",ee([O.PostConstruct],re.prototype,"postConstruct",1);var ne=re,se=class extends F.BeanStub{constructor(e,t,i){super(),this.eGui=e,this.focusWrapper=t,this.eFocusableComp=i}postConstruct(){this.addManagedListener(this.eGui,"keydown",e=>{switch(e.key){case F.KeyCode.TAB:e.defaultPrevented||F._.stopPropagationForAgGrid(e);break;case F.KeyCode.UP:case F.KeyCode.DOWN:F._.stopPropagationForAgGrid(e);break;case F.KeyCode.ESCAPE:if(F._.isStopPropagationForAgGrid(e))return;this.eGui.contains(this.gos.getActiveDomElement())&&(e.preventDefault(),F._.stopPropagationForAgGrid(e),this.focusWrapper.focus())}}),this.addManagedListener(this.focusWrapper,"keydown",e=>{if(e.key===F.KeyCode.ENTER){if(F._.isStopPropagationForAgGrid(e))return;this.gos.getActiveDomElement()===this.focusWrapper&&(e.preventDefault(),F._.stopPropagationForAgGrid(e),this.eFocusableComp.getFocusableElement().focus())}}),this.addManagedListener(this.focusWrapper,"focusin",()=>{this.focusWrapper.classList.add("ag-advanced-filter-builder-virtual-list-item-highlight")}),this.addManagedListener(this.focusWrapper,"focusout",e=>{this.focusWrapper.contains(e.relatedTarget)||this.focusWrapper.classList.remove("ag-advanced-filter-builder-virtual-list-item-highlight")})}};function oe(e,t){return{pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderAddField",pickerAriaLabelValue:"Advanced Filter Builder Add Field",pickerType:"ag-list",valueList:[{key:"condition",displayValue:e("advancedFilterBuilderAddCondition")},{key:"join",displayValue:e("advancedFilterBuilderAddJoin")}],valueFormatter:e=>{var t;return null==e?null:null!=(t=e.displayValue)?t:e.key},pickerIcon:"advancedFilterBuilderAdd",maxPickerWidth:`${null!=t?t:120}px`,wrapperClassName:"ag-advanced-filter-builder-item-button",ariaLabel:e("advancedFilterBuilderAddButtonTooltip")}}ee([F.PostConstruct],se.prototype,"postConstruct",1);var ae=class{};ae.EVENT_ADDED="advancedFilterBuilderAdded",ae.EVENT_MOVED="advancedFilterBuilderMoved",ae.EVENT_REMOVED="advancedFilterBuilderRemoved",ae.EVENT_VALUE_CHANGED="advancedFilterBuilderValueChanged",ae.EVENT_VALID_CHANGED="advancedFilterBuilderValidChanged";var le=class extends k.Component{constructor(){super('\n            <div class="ag-advanced-filter-builder-item-condition" role="presentation"></div>\n        '),this.validationMessage=null}init(e){const{item:t,createPill:i}=e;this.item=t,this.createPill=i,this.filterModel=t.filterModel,this.setupColumnCondition(this.filterModel),this.validate(),this.addDestroyFunc(()=>this.destroyBeans([this.eColumnPill,this.eOperatorPill,this.eOperandPill]))}getDragName(){return this.filterModel.colId?this.advancedFilterExpressionService.parseColumnFilterModel(this.filterModel):this.getDefaultColumnDisplayValue()}getAriaLabel(){return`${this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderFilterItem")} ${this.getDragName()}`}getValidationMessage(){return this.validationMessage}getFocusableElement(){return this.eColumnPill.getFocusableElement()}setupColumnCondition(e){var t;const i=this.advancedFilterExpressionService.getColumnDetails(e.colId);this.baseCellDataType=i.baseCellDataType,this.column=i.column,this.numOperands=this.getNumOperands(this.getOperatorKey()),this.eColumnPill=this.createPill({key:this.getColumnKey(),displayValue:null!=(t=this.getColumnDisplayValue())?t:this.getDefaultColumnDisplayValue(),cssClass:"ag-advanced-filter-builder-column-pill",isSelect:!0,getEditorParams:()=>({values:this.advancedFilterExpressionService.getColumnAutocompleteEntries()}),update:e=>this.setColumnKey(e),pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderColumnSelectField",pickerAriaLabelValue:"Advanced Filter Builder Column Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderColumn")}),this.getGui().appendChild(this.eColumnPill.getGui()),k._.exists(this.getColumnKey())&&(this.createOperatorPill(),this.hasOperand()&&this.createOperandPill())}createOperatorPill(){var e;this.eOperatorPill=this.createPill({key:this.getOperatorKey(),displayValue:null!=(e=this.getOperatorDisplayValue())?e:this.getDefaultOptionSelectValue(),cssClass:"ag-advanced-filter-builder-option-pill",isSelect:!0,getEditorParams:()=>({values:this.getOperatorAutocompleteEntries()}),update:e=>this.setOperatorKey(e),pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderOptionSelectField",pickerAriaLabelValue:"Advanced Filter Builder Option Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderOption")}),this.eColumnPill.getGui().insertAdjacentElement("afterend",this.eOperatorPill.getGui())}createOperandPill(){var e;const t=null!=(e=this.getOperandDisplayValue())?e:"";this.eOperandPill=this.createPill({key:t,displayValue:t,baseCellDataType:this.baseCellDataType,cssClass:"ag-advanced-filter-builder-value-pill",isSelect:!1,update:e=>this.setOperand(e),ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderValue")}),this.getGui().appendChild(this.eOperandPill.getGui())}getColumnKey(){return this.filterModel.colId}getColumnDisplayValue(){return this.advancedFilterExpressionService.getColumnDisplayValue(this.filterModel)}getOperatorKey(){return this.filterModel.type}getOperatorDisplayValue(){return this.advancedFilterExpressionService.getOperatorDisplayValue(this.filterModel)}getOperandDisplayValue(){return this.advancedFilterExpressionService.getOperandDisplayValue(this.filterModel,!0)}hasOperand(){return this.numOperands>0}getOperatorAutocompleteEntries(){return this.column?this.advancedFilterExpressionService.getOperatorAutocompleteEntries(this.column,this.baseCellDataType):[]}setColumnKey(e){this.eOperatorPill||this.createOperatorPill();const t=this.advancedFilterExpressionService.getColumnDetails(e);this.column=t.column;const i=t.baseCellDataType;this.baseCellDataType!==i&&(this.baseCellDataType=i,this.setOperatorKey(void 0),this.eOperatorPill&&(k._.removeFromParent(this.eOperatorPill.getGui()),this.destroyBean(this.eOperatorPill),this.createOperatorPill()),this.validate()),this.filterModel.colId=e,this.filterModel.filterType=this.baseCellDataType}setOperatorKey(e){const t=this.getNumOperands(e);t!==this.numOperands&&(this.numOperands=t,0===t?this.destroyOperandPill():(this.createOperandPill(),"number"!==this.baseCellDataType&&this.setOperand(""))),this.filterModel.type=e,this.validate()}setOperand(e){var t;let i=e;this.column&&(i=null!=(t=this.advancedFilterExpressionService.getOperandModelValue(e,this.baseCellDataType,this.column))?t:""),this.filterModel.filter=i,this.validate()}getNumOperands(e){var t,i;return null!=(i=null==(t=this.advancedFilterExpressionService.getExpressionOperator(this.baseCellDataType,e))?void 0:t.numOperands)?i:0}destroyOperandPill(){delete this.filterModel.filter,this.getGui().removeChild(this.eOperandPill.getGui()),this.destroyBean(this.eOperandPill),this.eOperandPill=void 0}validate(){let e=null;k._.exists(this.getColumnKey())?k._.exists(this.getOperatorKey())?this.numOperands>0&&!k._.exists(this.getOperandDisplayValue())&&(e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationEnterValue")):e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationSelectOption"):e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationSelectColumn"),this.item.valid=!e,e!==this.validationMessage&&(this.validationMessage=e,this.dispatchEvent({type:ae.EVENT_VALID_CHANGED}))}getDefaultColumnDisplayValue(){return this.advancedFilterExpressionService.translate("advancedFilterBuilderSelectColumn")}getDefaultOptionSelectValue(){return this.advancedFilterExpressionService.translate("advancedFilterBuilderSelectOption")}};ee([(0,k.Autowired)("advancedFilterExpressionService")],le.prototype,"advancedFilterExpressionService",2),ee([(0,k.Autowired)("valueService")],le.prototype,"valueService",2);var ce=class extends G.Component{constructor(e){super('\n            <div class="ag-advanced-filter-builder-pill-wrapper" role="presentation">\n                <div ref="ePill" class="ag-advanced-filter-builder-pill" role="button">\n                    <span ref="eLabel" class="ag-advanced-filter-builder-pill-display"></span>\n                </div>\n            </div>\n        '),this.params=e,this.value=e.value}postConstruct(){const{cssClass:e,ariaLabel:t}=this.params;this.ePill.classList.add(e),this.activateTabIndex([this.ePill]),this.eLabel.id=`${this.getCompId()}`,G._.setAriaDescribedBy(this.ePill,this.eLabel.id),G._.setAriaLabel(this.ePill,t),this.renderValue(),this.addManagedListener(this.ePill,"click",e=>{e.preventDefault(),this.showEditor()}),this.addManagedListener(this.ePill,"keydown",e=>{e.key===G.KeyCode.ENTER&&(e.preventDefault(),G._.stopPropagationForAgGrid(e),this.showEditor())}),this.addDestroyFunc(()=>this.destroyBean(this.eEditor))}getFocusableElement(){return this.ePill}showEditor(){if(this.eEditor)return;G._.setDisplayed(this.ePill,!1),this.eEditor=this.createEditorComp(this.params.type),this.eEditor.setValue(this.value);const e=this.eEditor.getGui();this.eEditor.addManagedListener(e,"keydown",e=>{switch(e.key){case G.KeyCode.ENTER:e.preventDefault(),G._.stopPropagationForAgGrid(e),this.updateValue(!0);break;case G.KeyCode.ESCAPE:e.preventDefault(),G._.stopPropagationForAgGrid(e),this.hideEditor(!0)}}),this.eEditor.addManagedListener(e,"focusout",()=>{this.updateValue(!1)}),this.getGui().appendChild(e),this.eEditor.getFocusableElement().focus()}createEditorComp(e){let t;switch(e){case"text":t=new G.AgInputTextField;break;case"number":t=new G.AgInputNumberField;break;case"date":t=new G.AgInputDateField}return this.createBean(t)}hideEditor(e){const{eEditor:t}=this;t&&(this.eEditor=void 0,this.getGui().removeChild(t.getGui()),this.destroyBean(t),G._.setDisplayed(this.ePill,!0),e&&this.ePill.focus())}renderValue(){let e;this.eLabel.classList.remove("ag-advanced-filter-builder-value-empty","ag-advanced-filter-builder-value-number","ag-advanced-filter-builder-value-text"),G._.exists(this.value)?"number"===this.params.type?(e=this.value,this.eLabel.classList.add("ag-advanced-filter-builder-value-number")):(e=`"${this.value}"`,this.eLabel.classList.add("ag-advanced-filter-builder-value-text")):(e=this.advancedFilterExpressionService.translate("advancedFilterBuilderEnterValue"),this.eLabel.classList.add("ag-advanced-filter-builder-value-empty")),this.eLabel.innerText=e}updateValue(e){var t;if(!this.eEditor)return;const i=null!=(t=this.eEditor.getValue())?t:"";this.dispatchEvent({type:G.Events.EVENT_FIELD_VALUE_CHANGED,value:i}),this.value=i,this.renderValue(),this.hideEditor(e)}};ee([(0,G.RefSelector)("ePill")],ce.prototype,"ePill",2),ee([(0,G.RefSelector)("eLabel")],ce.prototype,"eLabel",2),ee([(0,G.Autowired)("advancedFilterExpressionService")],ce.prototype,"advancedFilterExpressionService",2),ee([G.PostConstruct],ce.prototype,"postConstruct",1);var ue=class extends V.Component{constructor(){super('\n            <div class="ag-advanced-filter-builder-item-condition" role="presentation"></div>\n        ')}init(e){const{item:t,createPill:i}=e,r=t.filterModel;this.filterModel=r,this.ePill=i({key:r.type,displayValue:this.advancedFilterExpressionService.parseJoinOperator(r),cssClass:"ag-advanced-filter-builder-join-pill",isSelect:!0,getEditorParams:()=>({values:this.advancedFilterExpressionService.getJoinOperatorAutocompleteEntries()}),update:e=>r.type=e,pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderJoinSelectField",pickerAriaLabelValue:"Advanced Filter Builder Join Operator Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderJoinOperator")}),this.getGui().appendChild(this.ePill.getGui()),this.addDestroyFunc(()=>this.destroyBean(this.ePill))}getDragName(){return this.advancedFilterExpressionService.parseJoinOperator(this.filterModel)}getAriaLabel(){return`${this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderGroupItem")} ${this.getDragName()}`}getValidationMessage(){return null}getFocusableElement(){return this.ePill.getFocusableElement()}};ee([(0,V.Autowired)("advancedFilterExpressionService")],ue.prototype,"advancedFilterExpressionService",2);var he=class extends H.AgRichSelect{constructor(e){super(J(Z({},e),{template:'\n                <div class="ag-picker-field ag-advanced-filter-builder-pill-wrapper" role="presentation">\n                    <div ref="eLabel"></div>\n                    <div ref="eWrapper" class="ag-wrapper ag-advanced-filter-builder-pill ag-picker-collapsed">\n                        <div ref="eDisplayField" class="ag-picker-field-display ag-advanced-filter-builder-pill-display"></div>\n                        <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n                        <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n                    </div>\n                </div>'})),this.params=e}getFocusableElement(){return this.eWrapper}showPicker(){setTimeout(()=>super.showPicker())}hidePicker(){setTimeout(()=>super.hidePicker())}postConstruct(){super.postConstruct();const{wrapperClassName:e,ariaLabel:t}=this.params;this.eWrapper.classList.add(e),H._.setAriaLabelledBy(this.eWrapper,""),H._.setAriaLabel(this.eWrapper,t)}createPickerComponent(){var e;if(!this.values){const{values:t}=this.params.getEditorParams();this.values=t;const i=this.value.key,r=null!=(e=t.find(e=>e.key===i))?e:{key:i,displayValue:this.value.displayValue};this.value=r}return super.createPickerComponent()}onEnterKeyDown(e){H._.stopPropagationForAgGrid(e),this.isPickerDisplayed?super.onEnterKeyDown(e):(e.preventDefault(),this.showPicker())}},de=class extends L.TabGuardComp{constructor(e,t,i){super('\n            <div class="ag-advanced-filter-builder-item-wrapper" role="presentation">\n                <div ref="eItem" class="ag-advanced-filter-builder-item" role="presentation">\n                    <div ref="eTreeLines" class="ag-advanced-filter-builder-item-tree-lines" aria-hidden="true"></div>\n                    <span ref="eDragHandle" class="ag-drag-handle" aria-hidden="true"></span>\n                    <span ref="eValidation" class="ag-advanced-filter-builder-item-button ag-advanced-filter-builder-invalid" aria-hidden="true"></span>\n                </div>\n                <div ref="eButtons" class="ag-advanced-filter-builder-item-buttons">\n                    <span ref="eMoveUpButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                    <span ref="eMoveDownButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                    <div ref="eAddButton" role="presentation"></div>\n                    <span ref="eRemoveButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                </div>\n            </div>\n        '),this.item=e,this.dragFeature=t,this.focusWrapper=i,this.moveUpDisabled=!1,this.moveDownDisabled=!1}postConstruct(){const{filterModel:e,level:t,showMove:i}=this.item,r="join"===e.filterType;if(this.ePillWrapper=this.createManagedBean(r?new ue:new le),this.ePillWrapper.init({item:this.item,createPill:e=>this.createPill(e)}),this.eDragHandle.insertAdjacentElement("afterend",this.ePillWrapper.getGui()),0===t){const e=document.createElement("div");e.classList.add("ag-advanced-filter-builder-item-tree-line-vertical-bottom"),e.classList.add("ag-advanced-filter-builder-item-tree-line-root"),this.eTreeLines.appendChild(e),L._.setDisplayed(this.eDragHandle,!1),L._.setDisplayed(this.eButtons,!1),L._.setAriaExpanded(this.focusWrapper,!0)}else this.setupTreeLines(t),this.eDragHandle.appendChild(L._.createIconNoSpan("advancedFilterBuilderDrag",this.gos)),this.setupValidation(),this.setupMoveButtons(i),this.setupAddButton(),this.setupRemoveButton(),this.setupDragging(),this.updateAriaExpanded();L._.setAriaLevel(this.focusWrapper,t+1),this.initialiseTabGuard({}),this.createManagedBean(new se(this.getGui(),this.focusWrapper,this.ePillWrapper)),this.updateAriaLabel(),this.addManagedListener(this.ePillWrapper,ae.EVENT_VALUE_CHANGED,()=>this.dispatchEvent({type:ae.EVENT_VALUE_CHANGED})),this.addManagedListener(this.ePillWrapper,ae.EVENT_VALID_CHANGED,()=>this.updateValidity())}setState(e){const{level:t}=this.item;if(0===t)return;const{showMove:i}=this.item,{disableMoveUp:r,disableMoveDown:n,treeLines:s,showStartTreeLine:o}=e;this.updateTreeLines(s,o),this.updateAriaExpanded(),i&&(this.moveUpDisabled=!!r,this.moveDownDisabled=!!n,this.eMoveUpButton.classList.toggle("ag-advanced-filter-builder-item-button-disabled",r),this.eMoveDownButton.classList.toggle("ag-advanced-filter-builder-item-button-disabled",n),L._.setAriaDisabled(this.eMoveUpButton,!!r),L._.setAriaDisabled(this.eMoveDownButton,!!n),this.moveUpTooltipFeature.refreshToolTip(),this.moveDownTooltipFeature.refreshToolTip())}focusMoveButton(e){(e?this.eMoveUpButton:this.eMoveDownButton).focus()}afterAdd(){this.ePillWrapper.getFocusableElement().focus()}setupTreeLines(e){for(let t=0;t<e;t++){const e=document.createElement("div");this.eTreeLines.appendChild(e)}}updateTreeLines(e,t){const i=e.length-1,{children:r}=this.eTreeLines;for(let t=0;t<i;t++){const i=r.item(t);i&&i.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical",!e[t])}const n=r.item(i);if(n){n.classList.add("ag-advanced-filter-builder-item-tree-line-horizontal");const t=e[i];n.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical-top",t),n.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical",!t)}this.eDragHandle.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical-bottom",t)}setupValidation(){this.eValidation.appendChild(L._.createIconNoSpan("advancedFilterBuilderInvalid",this.gos)),this.validationTooltipFeature=this.createManagedBean(new L.TooltipFeature({getGui:()=>this.eValidation,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.ePillWrapper.getValidationMessage(),getTooltipShowDelayOverride:()=>1e3})),this.updateValidity()}setupAddButton(){var e;const t=oe(e=>this.advancedFilterExpressionService.translate(e),null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.addSelectWidth),i=this.createManagedBean(new ie(t));this.addManagedListener(i,L.Events.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>this.dispatchEvent({type:ae.EVENT_ADDED,item:this.item,isJoin:"join"===e.key})),this.eAddButton.appendChild(i.getGui()),this.createManagedBean(new L.TooltipFeature({getGui:()=>this.eAddButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip")}))}setupRemoveButton(){this.eRemoveButton.appendChild(L._.createIconNoSpan("advancedFilterBuilderRemove",this.gos)),this.addManagedListener(this.eRemoveButton,"click",()=>this.removeItem()),this.addManagedListener(this.eRemoveButton,"keydown",e=>{e.key===L.KeyCode.ENTER&&(e.preventDefault(),L._.stopPropagationForAgGrid(e),this.removeItem())}),this.createManagedBean(new L.TooltipFeature({getGui:()=>this.eRemoveButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderRemoveButtonTooltip")})),L._.setAriaLabel(this.eRemoveButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderRemoveButtonTooltip")),this.activateTabIndex([this.eRemoveButton])}setupMoveButtons(e){e?(this.eMoveUpButton.appendChild(L._.createIconNoSpan("advancedFilterBuilderMoveUp",this.gos)),this.addManagedListener(this.eMoveUpButton,"click",()=>this.moveItem(!0)),this.addManagedListener(this.eMoveUpButton,"keydown",e=>{e.key===L.KeyCode.ENTER&&(e.preventDefault(),L._.stopPropagationForAgGrid(e),this.moveItem(!0))}),this.moveUpTooltipFeature=this.createManagedBean(new L.TooltipFeature({getGui:()=>this.eMoveUpButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.moveUpDisabled?null:this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveUpButtonTooltip")})),L._.setAriaLabel(this.eMoveUpButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveUpButtonTooltip")),this.eMoveDownButton.appendChild(L._.createIconNoSpan("advancedFilterBuilderMoveDown",this.gos)),this.addManagedListener(this.eMoveDownButton,"click",()=>this.moveItem(!1)),this.addManagedListener(this.eMoveDownButton,"keydown",e=>{e.key===L.KeyCode.ENTER&&(e.preventDefault(),L._.stopPropagationForAgGrid(e),this.moveItem(!1))}),this.moveDownTooltipFeature=this.createManagedBean(new L.TooltipFeature({getGui:()=>this.eMoveDownButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.moveDownDisabled?null:this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveDownButtonTooltip")})),L._.setAriaLabel(this.eMoveDownButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveDownButtonTooltip")),this.activateTabIndex([this.eMoveUpButton,this.eMoveDownButton])):(L._.setDisplayed(this.eMoveUpButton,!1),L._.setDisplayed(this.eMoveDownButton,!1))}updateValidity(){L._.setVisible(this.eValidation,!this.item.valid),this.validationTooltipFeature.refreshToolTip(),this.updateAriaLabel()}createPill(e){var t,i;const{key:r,displayValue:n,cssClass:s,update:o,ariaLabel:a}=e,l=e=>{null!=e&&(o(e),this.dispatchEvent({type:ae.EVENT_VALUE_CHANGED}))};if(e.isSelect){const{getEditorParams:o,pickerAriaLabelKey:c,pickerAriaLabelValue:u}=e,h=this.gos.get("advancedFilterBuilderParams"),d=`${null!=(t=null==h?void 0:h.pillSelectMinWidth)?t:140}px`,p=`${null!=(i=null==h?void 0:h.pillSelectMaxWidth)?i:200}px`,g=this.createBean(new he({pickerAriaLabelKey:c,pickerAriaLabelValue:u,pickerType:"ag-list",value:{key:r,displayValue:n},valueFormatter:e=>{var t;return null==e?null:null!=(t=e.displayValue)?t:e.key},variableWidth:!0,minPickerWidth:d,maxPickerWidth:p,getEditorParams:o,wrapperClassName:s,ariaLabel:a}));return this.addManagedListener(g,L.Events.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>l(null==e?void 0:e.key)),g}{const t=this.createBean(new ce({value:n,cssClass:s,type:this.getInputType(e.baseCellDataType),ariaLabel:a}));return this.addManagedListener(t,L.Events.EVENT_FIELD_VALUE_CHANGED,({value:e})=>l(e)),t}}getInputType(e){switch(e){case"text":case"object":case"boolean":return"text";case"number":return"number";case"date":case"dateString":return"date"}}setupDragging(){const e={type:L.DragSourceType.AdvancedFilterBuilder,eElement:this.eDragHandle,dragItemName:()=>this.ePillWrapper.getDragName(),getDefaultIconName:()=>L.DragAndDropService.ICON_NOT_ALLOWED,getDragItem:()=>({}),onDragStarted:()=>this.dragFeature.dispatchEvent({type:ne.EVENT_DRAG_STARTED,item:this.item}),onDragStopped:()=>this.dragFeature.dispatchEvent({type:ne.EVENT_DRAG_ENDED})};this.dragAndDropService.addDragSource(e,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(e))}updateAriaLabel(){const e=this.ePillWrapper.getAriaLabel(),t=`${this.item.level+1}`,i=this.ePillWrapper.getValidationMessage();let r;r=i?this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItemValidation",[e,t,i]):this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItem",[e,t]),L._.setAriaLabel(this.focusWrapper,r)}updateAriaExpanded(){L._.removeAriaExpanded(this.focusWrapper);const{filterModel:e}=this.item;"join"===(null==e?void 0:e.filterType)&&e.conditions.length&&L._.setAriaExpanded(this.focusWrapper,!0)}removeItem(){this.dispatchEvent({type:ae.EVENT_REMOVED,item:this.item})}moveItem(e){this.dispatchEvent({type:ae.EVENT_MOVED,item:this.item,backwards:e})}};ee([(0,L.RefSelector)("eTreeLines")],de.prototype,"eTreeLines",2),ee([(0,L.RefSelector)("eDragHandle")],de.prototype,"eDragHandle",2),ee([(0,L.RefSelector)("eItem")],de.prototype,"eItem",2),ee([(0,L.RefSelector)("eButtons")],de.prototype,"eButtons",2),ee([(0,L.RefSelector)("eValidation")],de.prototype,"eValidation",2),ee([(0,L.RefSelector)("eMoveUpButton")],de.prototype,"eMoveUpButton",2),ee([(0,L.RefSelector)("eMoveDownButton")],de.prototype,"eMoveDownButton",2),ee([(0,L.RefSelector)("eAddButton")],de.prototype,"eAddButton",2),ee([(0,L.RefSelector)("eRemoveButton")],de.prototype,"eRemoveButton",2),ee([(0,L.Autowired)("beans")],de.prototype,"beans",2),ee([(0,L.Autowired)("dragAndDropService")],de.prototype,"dragAndDropService",2),ee([(0,L.Autowired)("advancedFilterExpressionService")],de.prototype,"advancedFilterExpressionService",2),ee([L.PostConstruct],de.prototype,"postConstruct",1);var pe=class extends B.Component{constructor(e,t){super('\n            <div class="ag-advanced-filter-builder-item-wrapper" role="presentation">\n                <div ref="eItem" class="ag-advanced-filter-builder-item" role="presentation">\n                    <div class="ag-advanced-filter-builder-item-tree-lines" aria-hidden="true">\n                        <div class="ag-advanced-filter-builder-item-tree-line-vertical-top ag-advanced-filter-builder-item-tree-line-horizontal"></div>\n                    </div>\n                </div>\n            </div>\n        '),this.item=e,this.focusWrapper=t}postConstruct(){var e;B._.setAriaLevel(this.focusWrapper,2);const t=oe(e=>this.advancedFilterExpressionService.translate(e),null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.addSelectWidth),i=this.createManagedBean(new ie(t));this.addManagedListener(i,B.Events.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>{this.dispatchEvent({type:ae.EVENT_ADDED,item:this.item,isJoin:"join"===e.key})}),this.eItem.appendChild(i.getGui()),this.createManagedBean(new B.TooltipFeature({getGui:()=>i.getGui(),getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip")})),this.createManagedBean(new se(this.getGui(),this.focusWrapper,i)),B._.setAriaLabel(this.focusWrapper,this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItem",[this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip"),`${this.item.level+1}`]))}afterAdd(){}};ee([(0,B.Autowired)("beans")],pe.prototype,"beans",2),ee([(0,B.Autowired)("advancedFilterExpressionService")],pe.prototype,"advancedFilterExpressionService",2),ee([(0,B.RefSelector)("eItem")],pe.prototype,"eItem",2),ee([B.PostConstruct],pe.prototype,"postConstruct",1);var ge=class extends I.Component{constructor(){super('\n            <div role="presentation" class="ag-advanced-filter-builder" tabindex="-1">\n                <div role="presentation" class="ag-advanced-filter-builder-list" ref="eList"></div>\n                <div role="presentation" class="ag-advanced-filter-builder-button-panel">\n                    <button class="ag-button ag-standard-button ag-advanced-filter-builder-apply-button" ref="eApplyFilterButton"></button>\n                    <button class="ag-button ag-standard-button ag-advanced-filter-builder-cancel-button" ref="eCancelFilterButton"></button>\n                </div>\n            </div>'),this.validationMessage=null}postConstruct(){var e;const{showMoveButtons:t}=null!=(e=this.gos.get("advancedFilterBuilderParams"))?e:{};this.showMove=!!t,this.addManagedPropertyListener("advancedFilterBuilderParams",({currentValue:e})=>{this.showMove=!!(null==e?void 0:e.showMoveButtons),this.refreshList(!1)}),this.filterModel=this.setupFilterModel(),this.setupVirtualList(),this.dragFeature=this.createManagedBean(new ne(this,this.virtualList)),this.setupButtons()}refresh(){let e=this.virtualList.getLastFocusedRow();this.setupFilterModel(),this.validateItems(),this.refreshList(!1),null!=e&&(this.virtualList.getComponentAt(e)||(e=0),this.virtualList.focusRow(e))}getNumItems(){return this.items.length}moveItem(e,t){t&&e&&this.moveItemToIndex(e,t.rowIndex,t.position)}afterGuiAttached(){this.virtualList.focusRow(0)}setupVirtualList(){this.virtualList=this.createManagedBean(new I.VirtualList({cssIdentifier:"advanced-filter-builder",ariaRole:"tree",listName:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderList")})),this.virtualList.setComponentCreator(this.createItemComponent.bind(this)),this.virtualList.setComponentUpdater(this.updateItemComponent.bind(this)),this.virtualList.setRowHeight(40),this.eList.appendChild(this.virtualList.getGui()),this.virtualList.setModel({getRowCount:()=>this.items.length,getRow:e=>this.items[e],areRowsEqual:(e,t)=>e===t}),this.buildList(),this.virtualList.refresh()}setupButtons(){this.eApplyFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilderApply"),this.activateTabIndex([this.eApplyFilterButton]),this.addManagedListener(this.eApplyFilterButton,"click",()=>{this.advancedFilterService.setModel(this.filterModel),this.filterManager.onFilterChanged({source:"advancedFilter"}),this.close()}),this.validationTooltipFeature=this.createManagedBean(new I.TooltipFeature({getGui:()=>this.eApplyFilterButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.validationMessage,getTooltipShowDelayOverride:()=>1e3})),this.validate(),this.addManagedListener(this.eApplyFilterButton,"mouseenter",()=>this.addOrRemoveCssClass("ag-advanced-filter-builder-validation",!0)),this.addManagedListener(this.eApplyFilterButton,"mouseleave",()=>this.addOrRemoveCssClass("ag-advanced-filter-builder-validation",!1)),this.eCancelFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilderCancel"),this.activateTabIndex([this.eCancelFilterButton]),this.addManagedListener(this.eCancelFilterButton,"click",()=>this.close())}removeItemFromParent(e){const t=e.parent.conditions.indexOf(e.filterModel);return e.parent.conditions.splice(t,1),t}moveItemToIndex(e,t,i){var r;const n=this.items[t],s="join"===(null==(r=n.filterModel)?void 0:r.filterType)&&"bottom"===i,o=s?n.filterModel:n.parent;if(!o)return;if(this.isChildOrSelf(o,e.filterModel)||n===e)return;let a;this.removeItemFromParent(e),s?a=0:(a=o.conditions.indexOf(n.filterModel),-1===a?a=o.conditions.length:"bottom"===i&&(a+=1)),o.conditions.splice(a,0,e.filterModel),this.refreshList(!1)}isChildOrSelf(e,t){return e===t||"join"===t.filterType&&t.conditions.some(t=>this.isChildOrSelf(e,t))}setupFilterModel(){const e=this.formatFilterModel(this.advancedFilterService.getModel());return this.stringifiedModel=JSON.stringify(e),e}formatFilterModel(e){return"join"!==(e=null!=e?e:{filterType:"join",type:"AND",conditions:[]}).filterType&&(e={filterType:"join",type:"AND",conditions:[e]}),e}buildList(){const e=(t,i,r,n)=>{i.push({filterModel:t,level:r,parent:n,valid:!0,showMove:this.showMove}),"join"===t.filterType&&(t.conditions.forEach(n=>e(n,i,r+1,t)),0===r&&i.push({filterModel:null,level:r+1,parent:t,valid:!0}))};this.items=[],e(this.filterModel,this.items,0)}refreshList(e){if(!e){const e=[];this.items.forEach(t=>{t.valid||e.push(t.filterModel)}),this.buildList(),e.length&&this.items.forEach(t=>{t.filterModel&&e.includes(t.filterModel)&&(t.valid=!1)})}this.virtualList.refresh(e),this.validate()}updateItemComponent(e,t){const i=this.items.indexOf(e),r=(e,t)=>{const i=this.items.find(t=>t.filterModel===e),n=null==i?void 0:i.parent;if(n){const{conditions:i}=n;r(n,t),t.push(i[i.length-1]===e)}},n=[],{filterModel:s}=e;s&&(r(s,n),n[0]=!1);const o="join"===(null==s?void 0:s.filterType)&&!!s.conditions.length;t.setState({disableMoveUp:1===i,disableMoveDown:!this.canMoveDown(e,i),treeLines:n,showStartTreeLine:o})}createItemComponent(e,t){const i=this.createBean(e.filterModel?new de(e,this.dragFeature,t):new pe(e,t));return i.addManagedListener(i,ae.EVENT_REMOVED,({item:e})=>this.removeItem(e)),i.addManagedListener(i,ae.EVENT_VALUE_CHANGED,()=>this.validate()),i.addManagedListener(i,ae.EVENT_ADDED,({item:e,isJoin:t})=>this.addItem(e,t)),i.addManagedListener(i,ae.EVENT_MOVED,({item:e,backwards:t})=>this.moveItemUpDown(e,t)),i instanceof de&&this.updateItemComponent(e,i),i}addItem(e,t){var i;const{parent:r,level:n,filterModel:s}=e,o="join"===(null==s?void 0:s.filterType),a=t?{filterType:"join",type:"AND",conditions:[]}:{},l=o?s:r;let c=o?0:l.conditions.indexOf(s);c>=0?(o||(c+=1),l.conditions.splice(c,0,a)):l.conditions.push(a);let u=this.items.indexOf(e);const h=u>=0;if(h){e.filterModel&&u++;const i=[{filterModel:a,level:o?n+1:n,parent:l,valid:t,showMove:this.showMove}];this.items.splice(u,0,...i)}this.refreshList(h),h&&(null==(i=this.virtualList.getComponentAt(u))||i.afterAdd())}removeItem(e){var t;const i=e.parent,{filterModel:r}=e,n=i.conditions.indexOf(r);i.conditions.splice(n,1);const s="join"===(null==(t=e.filterModel)?void 0:t.filterType),o=this.items.indexOf(e),a=!s&&o>=0;a&&this.items.splice(o,1),this.refreshList(a),o>=0&&this.virtualList.focusRow(o)}moveItemUpDown(e,t){const i=this.items.indexOf(e),r=t?i-1:i+1;if(0===r||!t&&!this.canMoveDown(e,i))return;const n=this.items[r],s=this.removeItemFromParent(e),{level:o,filterModel:a,parent:l}=e,{level:c,filterModel:u,parent:h}=n;if(t)if(c===o&&"join"===u.filterType)u.conditions.push(a);else if(c<=o){const e=h.conditions.indexOf(u);h.conditions.splice(e,0,a)}else l.conditions[s-1].conditions.push(a);else if(c===o)if("join"===u.filterType)u.conditions.splice(0,0,a);else{const e=h.conditions.indexOf(u);h.conditions.splice(e+1,0,a)}else if(s<l.conditions.length)l.conditions.splice(s+1,0,a);else{const e=this.items.find(e=>e.filterModel===l),t=e.parent.conditions.indexOf(e.filterModel)+1;e.parent.conditions.splice(t,0,a)}this.refreshList(!1);const d=this.items.findIndex(({filterModel:e})=>e===a);if(d>=0){const e=this.virtualList.getComponentAt(d);e instanceof de&&e.focusMoveButton(t)}}canMoveDown(e,t){return!(1===e.level&&t===this.items.length-2||1===e.level&&e.parent.conditions[e.parent.conditions.length-1]===e.filterModel)}close(){this.advancedFilterService.getCtrl().toggleFilterBuilder("ui")}validate(){let e=!this.items.every(({valid:e})=>e);e?this.validationMessage=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationIncomplete"):(e=JSON.stringify(this.filterModel)===this.stringifiedModel,this.validationMessage=e?this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationAlreadyApplied"):null),I._.setDisabled(this.eApplyFilterButton,e),this.validationTooltipFeature.refreshToolTip()}validateItems(){const e=e=>{e.type=void 0},t=e=>{delete e.filter};this.items.forEach(i=>{if(!i.valid||!i.filterModel||"join"===i.filterModel.filterType)return;const{filterModel:r}=i,{colId:n}=r,s=this.advancedFilterExpressionService.getColumnAutocompleteEntries().find(({key:e})=>e===n),o=this.advancedFilterExpressionService.getColumnDetails(r.colId);if(!s||!o.column)return i.valid=!1,r.colId=void 0,e(r),void t(r);const a=this.advancedFilterExpressionService.getDataTypeExpressionOperator(o.baseCellDataType).operators[r.type];if(!a)return i.valid=!1,e(r),void t(r);a.numOperands>0&&!I._.exists(r.filter)&&(i.valid=!1)})}};ee([(0,I.RefSelector)("eList")],ge.prototype,"eList",2),ee([(0,I.RefSelector)("eApplyFilterButton")],ge.prototype,"eApplyFilterButton",2),ee([(0,I.RefSelector)("eCancelFilterButton")],ge.prototype,"eCancelFilterButton",2),ee([(0,I.Autowired)("filterManager")],ge.prototype,"filterManager",2),ee([(0,I.Autowired)("advancedFilterService")],ge.prototype,"advancedFilterService",2),ee([(0,I.Autowired)("advancedFilterExpressionService")],ge.prototype,"advancedFilterExpressionService",2),ee([(0,I.Autowired)("beans")],ge.prototype,"beans",2),ee([I.PostConstruct],ge.prototype,"postConstruct",1);var fe=class e extends x.BeanStub{constructor(e){super(),this.enabled=e}postConstruct(){this.hasAdvancedFilterParent=!!this.gos.get("advancedFilterParent"),this.ctrlsService.whenReady(()=>this.setAdvancedFilterComp()),this.addManagedListener(this.eventService,x.Events.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,({enabled:e})=>this.onEnabledChanged(e)),this.addManagedPropertyListener("advancedFilterParent",()=>this.updateComps()),this.addDestroyFunc(()=>{this.destroyAdvancedFilterComp(),this.destroyBean(this.eBuilderComp),this.eBuilderDialog&&this.eBuilderDialog.isAlive()&&this.destroyBean(this.eBuilderDialog)})}setupHeaderComp(e){this.eHeaderComp=this.createManagedBean(new te(this.enabled&&!this.hasAdvancedFilterParent)),e.insertAdjacentElement("beforebegin",this.eHeaderComp.getGui())}focusHeaderComp(){return!!this.eHeaderComp&&(this.eHeaderComp.getFocusableElement().focus(),!0)}refreshComp(){var e,t;null==(e=this.eFilterComp)||e.refresh(),null==(t=this.eHeaderComp)||t.refresh()}refreshBuilderComp(){var e;null==(e=this.eBuilderComp)||e.refresh()}getHeaderHeight(){var e,t;return null!=(t=null==(e=this.eHeaderComp)?void 0:e.getHeight())?t:0}setInputDisabled(e){var t,i;null==(t=this.eFilterComp)||t.setInputDisabled(e),null==(i=this.eHeaderComp)||i.setInputDisabled(e)}toggleFilterBuilder(t,i){if(i&&this.eBuilderDialog||!1===i&&!this.eBuilderDialog)return;if(this.eBuilderDialog)return this.builderDestroySource=t,void this.destroyBean(this.eBuilderDialog);this.setInputDisabled(!0);const{width:r,height:n,minWidth:s}=this.getBuilderDialogSize();this.eBuilderComp=this.createBean(new ge),this.eBuilderDialog=this.createBean(new x.AgDialog({title:this.advancedFilterExpressionService.translate("advancedFilterBuilderTitle"),component:this.eBuilderComp,width:r,height:n,resizable:!0,movable:!0,maximizable:!0,centered:!0,closable:!0,minWidth:s,afterGuiAttached:()=>{var e;return null==(e=this.eBuilderComp)?void 0:e.afterGuiAttached()}})),this.dispatchFilterBuilderVisibleChangedEvent(t,!0),this.eBuilderDialog.addEventListener(x.AgDialog.EVENT_DESTROYED,()=>{var t;this.destroyBean(this.eBuilderComp),this.eBuilderComp=void 0,this.eBuilderDialog=void 0,this.setInputDisabled(!1),this.dispatchEvent({type:e.EVENT_BUILDER_CLOSED}),this.dispatchFilterBuilderVisibleChangedEvent(null!=(t=this.builderDestroySource)?t:"ui",!1),this.builderDestroySource=void 0})}dispatchFilterBuilderVisibleChangedEvent(e,t){const i={type:x.Events.EVENT_ADVANCED_FILTER_BUILDER_VISIBLE_CHANGED,source:e,visible:t};this.eventService.dispatchEvent(i)}getBuilderDialogSize(){var e,t;const i=null!=(t=null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.minWidth)?t:500,r=this.popupService.getPopupParent(),n=Math.round(x._.getAbsoluteWidth(r))-2,s=Math.round(.75*x._.getAbsoluteHeight(r))-2;return{width:Math.min(Math.max(600,i),n),height:Math.min(600,s),minWidth:i}}onEnabledChanged(e){this.enabled=e,this.updateComps()}updateComps(){this.setAdvancedFilterComp(),this.setHeaderCompEnabled(),this.eventService.dispatchEvent({type:x.Events.EVENT_HEADER_HEIGHT_CHANGED})}setAdvancedFilterComp(){if(this.destroyAdvancedFilterComp(),!this.enabled)return;const e=this.gos.get("advancedFilterParent");if(this.hasAdvancedFilterParent=!!e,e){const t=this.createBean(new ve),i=t.getGui(),{allThemes:r}=this.environment.getTheme();r.length&&i.classList.add(...r),i.classList.add(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr"),e.appendChild(i),this.eFilterComp=t}}setHeaderCompEnabled(){var e;null==(e=this.eHeaderComp)||e.setEnabled(this.enabled&&!this.hasAdvancedFilterParent)}destroyAdvancedFilterComp(){this.eFilterComp&&(x._.removeFromParent(this.eFilterComp.getGui()),this.destroyBean(this.eFilterComp))}};fe.EVENT_BUILDER_CLOSED="advancedFilterBuilderClosed",ee([(0,x.Autowired)("focusService")],fe.prototype,"focusService",2),ee([(0,x.Autowired)("ctrlsService")],fe.prototype,"ctrlsService",2),ee([(0,x.Autowired)("popupService")],fe.prototype,"popupService",2),ee([(0,x.Autowired)("advancedFilterExpressionService")],fe.prototype,"advancedFilterExpressionService",2),ee([x.PostConstruct],fe.prototype,"postConstruct",1);var me=fe,ve=class extends P.Component{constructor(){super('\n            <div class="ag-advanced-filter" role="presentation" tabindex="-1">\n                <ag-autocomplete ref="eAutocomplete"></ag-autocomplete>\n                <button class="ag-button ag-standard-button ag-advanced-filter-apply-button" ref="eApplyFilterButton"></button>\n                <button class="ag-advanced-filter-builder-button" ref="eBuilderFilterButton">\n                    <span ref="eBuilderFilterButtonIcon" aria-hidden="true"></span>\n                    <span class="ag-advanced-filter-builder-button-label" ref="eBuilderFilterButtonLabel"></span>\n                </button>\n            </div>'),this.expressionParser=null,this.isApplyDisabled=!0,this.builderOpen=!1}postConstruct(){this.eAutocomplete.setListGenerator((e,t)=>this.generateAutocompleteListParams(t)).setValidator(()=>this.validateValue()).setForceLastSelection((e,t)=>this.forceLastSelection(e,t)).setInputAriaLabel(this.advancedFilterExpressionService.translate("ariaAdvancedFilterInput")).setListAriaLabel(this.advancedFilterExpressionService.translate("ariaLabelAdvancedFilterAutocomplete")),this.refresh(),this.addManagedListener(this.eAutocomplete,P.AgAutocomplete.EVENT_VALUE_CHANGED,({value:e})=>this.onValueChanged(e)),this.addManagedListener(this.eAutocomplete,P.AgAutocomplete.EVENT_VALUE_CONFIRMED,({isValid:e})=>this.onValueConfirmed(e)),this.addManagedListener(this.eAutocomplete,P.AgAutocomplete.EVENT_OPTION_SELECTED,({position:e,updateEntry:t,autocompleteType:i})=>this.onOptionSelected(e,t,i)),this.addManagedListener(this.eAutocomplete,P.AgAutocomplete.EVENT_VALID_CHANGED,({isValid:e,validationMessage:t})=>this.onValidChanged(e,t)),this.setupApplyButton(),this.setupBuilderButton()}refresh(){const e=this.advancedFilterService.getExpressionDisplayValue();this.eAutocomplete.setValue({value:null!=e?e:"",position:null==e?void 0:e.length,updateListOnlyIfOpen:!0})}setInputDisabled(e){this.eAutocomplete.setInputDisabled(e),P._.setDisabled(this.eApplyFilterButton,e||this.isApplyDisabled)}getTooltipParams(){const e=super.getTooltipParams();return e.location="advancedFilter",e}setupApplyButton(){this.eApplyFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterApply"),this.activateTabIndex([this.eApplyFilterButton]),this.addManagedListener(this.eApplyFilterButton,"click",()=>this.onValueConfirmed(this.eAutocomplete.isValid())),P._.setDisabled(this.eApplyFilterButton,this.isApplyDisabled)}setupBuilderButton(){this.eBuilderFilterButtonIcon.appendChild(P._.createIconNoSpan("advancedFilterBuilder",this.gos)),this.eBuilderFilterButtonLabel.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilder"),this.activateTabIndex([this.eBuilderFilterButton]),this.addManagedListener(this.eBuilderFilterButton,"click",()=>this.openBuilder()),this.addManagedListener(this.advancedFilterService.getCtrl(),me.EVENT_BUILDER_CLOSED,()=>this.closeBuilder())}onValueChanged(e){var t;e=P._.makeNull(e),this.advancedFilterService.setExpressionDisplayValue(e),this.expressionParser=this.advancedFilterService.createExpressionParser(e);const i=null==(t=this.expressionParser)?void 0:t.parseExpression();i&&i!==e&&this.eAutocomplete.setValue({value:i,silent:!0,restoreFocus:!0})}onValueConfirmed(e){e&&!this.isApplyDisabled&&(P._.setDisabled(this.eApplyFilterButton,!0),this.advancedFilterService.applyExpression(),this.filterManager.onFilterChanged({source:"advancedFilter"}))}onOptionSelected(e,t,i){const{updatedValue:r,updatedPosition:n,hideAutocomplete:s}=this.updateExpression(e,t,i);this.eAutocomplete.setValue({value:r,position:n,updateListOnlyIfOpen:s,restoreFocus:!0})}validateValue(){var e,t,i;return(null==(e=this.expressionParser)?void 0:e.isValid())?null:null!=(i=null==(t=this.expressionParser)?void 0:t.getValidationMessage())?i:null}onValidChanged(e,t){this.isApplyDisabled=!e||this.advancedFilterService.isCurrentExpressionApplied(),P._.setDisabled(this.eApplyFilterButton,this.isApplyDisabled),this.setTooltip({newTooltipText:t,showDelayOverride:1e3})}generateAutocompleteListParams(e){return this.expressionParser?this.expressionParser.getAutocompleteListParams(e):this.advancedFilterExpressionService.getDefaultAutocompleteListParams("")}updateExpression(e,t,i){var r,n;return this.advancedFilterExpressionService.updateAutocompleteCache(t,i),null!=(n=null==(r=this.expressionParser)?void 0:r.updateExpression(e,t,i))?n:this.advancedFilterService.getDefaultExpression(t)}forceLastSelection({key:e,displayValue:t},i){return!!i.toLocaleLowerCase().match(`^${(null!=t?t:e).toLocaleLowerCase()}\\s*$`)}openBuilder(){this.builderOpen||(this.builderOpen=!0,P._.setDisabled(this.eBuilderFilterButton,!0),this.advancedFilterService.getCtrl().toggleFilterBuilder("ui"))}closeBuilder(){this.builderOpen&&(this.builderOpen=!1,P._.setDisabled(this.eBuilderFilterButton,!1),this.eBuilderFilterButton.focus())}};ee([(0,P.RefSelector)("eAutocomplete")],ve.prototype,"eAutocomplete",2),ee([(0,P.RefSelector)("eApplyFilterButton")],ve.prototype,"eApplyFilterButton",2),ee([(0,P.RefSelector)("eBuilderFilterButton")],ve.prototype,"eBuilderFilterButton",2),ee([(0,P.RefSelector)("eBuilderFilterButtonIcon")],ve.prototype,"eBuilderFilterButtonIcon",2),ee([(0,P.RefSelector)("eBuilderFilterButtonLabel")],ve.prototype,"eBuilderFilterButtonLabel",2),ee([(0,P.Autowired)("advancedFilterService")],ve.prototype,"advancedFilterService",2),ee([(0,P.Autowired)("advancedFilterExpressionService")],ve.prototype,"advancedFilterExpressionService",2),ee([(0,P.Autowired)("filterManager")],ve.prototype,"filterManager",2),ee([P.PostConstruct],ve.prototype,"postConstruct",1);var Ce={ariaAdvancedFilterBuilderItem:e=>`${e[0]}. Level ${e[1]}. Press ENTER to edit.`,ariaAdvancedFilterBuilderItemValidation:e=>`${e[0]}. Level ${e[1]}. ${e[2]} Press ENTER to edit.`,ariaAdvancedFilterBuilderList:"Advanced Filter Builder List",ariaAdvancedFilterBuilderFilterItem:"Filter Condition",ariaAdvancedFilterBuilderGroupItem:"Filter Group",ariaAdvancedFilterBuilderColumn:"Column",ariaAdvancedFilterBuilderOption:"Option",ariaAdvancedFilterBuilderValue:"Value",ariaAdvancedFilterBuilderJoinOperator:"Join Operator",ariaAdvancedFilterInput:"Advanced Filter Input",ariaLabelAdvancedFilterAutocomplete:"Advanced Filter Autocomplete",advancedFilterContains:"contains",advancedFilterNotContains:"does not contain",advancedFilterTextEquals:"equals",advancedFilterTextNotEqual:"does not equal",advancedFilterStartsWith:"begins with",advancedFilterEndsWith:"ends with",advancedFilterBlank:"is blank",advancedFilterNotBlank:"is not blank",advancedFilterEquals:"=",advancedFilterNotEqual:"!=",advancedFilterGreaterThan:">",advancedFilterGreaterThanOrEqual:">=",advancedFilterLessThan:"<",advancedFilterLessThanOrEqual:"<=",advancedFilterTrue:"is true",advancedFilterFalse:"is false",advancedFilterAnd:"AND",advancedFilterOr:"OR",advancedFilterApply:"Apply",advancedFilterBuilder:"Builder",advancedFilterValidationMissingColumn:"Column is missing",advancedFilterValidationMissingOption:"Option is missing",advancedFilterValidationMissingValue:"Value is missing",advancedFilterValidationInvalidColumn:"Column not found",advancedFilterValidationInvalidOption:"Option not found",advancedFilterValidationMissingQuote:"Value is missing an end quote",advancedFilterValidationNotANumber:"Value is not a number",advancedFilterValidationInvalidDate:"Value is not a valid date",advancedFilterValidationMissingCondition:"Condition is missing",advancedFilterValidationJoinOperatorMismatch:"Join operators within a condition must be the same",advancedFilterValidationInvalidJoinOperator:"Join operator not found",advancedFilterValidationMissingEndBracket:"Missing end bracket",advancedFilterValidationExtraEndBracket:"Too many end brackets",advancedFilterValidationMessage:e=>`Expression has an error. ${e[0]} - ${e[1]}.`,advancedFilterValidationMessageAtEnd:e=>`Expression has an error. ${e[0]} at end of expression.`,advancedFilterBuilderTitle:"Advanced Filter",advancedFilterBuilderApply:"Apply",advancedFilterBuilderCancel:"Cancel",advancedFilterBuilderAddButtonTooltip:"Add Filter or Group",advancedFilterBuilderRemoveButtonTooltip:"Remove",advancedFilterBuilderMoveUpButtonTooltip:"Move Up",advancedFilterBuilderMoveDownButtonTooltip:"Move Down",advancedFilterBuilderAddJoin:"Add Group",advancedFilterBuilderAddCondition:"Add Filter",advancedFilterBuilderSelectColumn:"Select a column",advancedFilterBuilderSelectOption:"Select an option",advancedFilterBuilderEnterValue:"Enter a value...",advancedFilterBuilderValidationAlreadyApplied:"Current filter already applied.",advancedFilterBuilderValidationIncomplete:"Not all conditions are complete.",advancedFilterBuilderValidationSelectColumn:"Must select a column.",advancedFilterBuilderValidationSelectOption:"Must select an option.",advancedFilterBuilderValidationEnterValue:"Must enter a value."};function ye(e,t,i){if(!e)return"";const r=i-t;return r?e.slice(0,e.length-r):e}function we(e,t,i,r,n,s,o){const a=i+(!e.length||o?0:1);let l=0;return n&&(" "===e[a]?l=1:(r+=" ",s&&(r+='"'))),{updatedValue:e.slice(0,t)+r+e.slice(a),updatedPosition:t+r.length+l}}function Se(e,t,i,r){let n=t,s=!1;for(;n<e.length;){const t=e[n];if("("===t){r&&" "===e[n-1]?s=!0:n-=1;break}if(" "===t||i&&")"===t){n-=1;break}n++}return{endPosition:n,isEmpty:s}}function be(e,t,i,r){i!==t&&(e.expression=we(e.expression,r-t.length+1,r,i).updatedValue)}var Ee=class{constructor(e,t){this.params=e,this.startPosition=t,this.type="column",this.valid=!0,this.hasStartChar=!1,this.hasEndChar=!1,this.colName=""}parse(e,t){if(e!==Me.COL_START_CHAR||this.colName)if(e===Me.COL_END_CHAR&&this.hasStartChar){if(this.parseColumn(!1,t))return this.hasEndChar=!0,!1;this.colName+=e}else this.colName+=e;else this.hasStartChar=!0}getDisplayValue(){return(this.hasStartChar?Me.COL_START_CHAR:"")+this.colName+(this.hasEndChar?Me.COL_END_CHAR:"")}getColId(){return this.colId}complete(e){this.parseColumn(!0,e)}getValidationError(){var e;return this.valid?null:{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidColumn"),startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}}parseColumn(e,t){var i;this.endPosition=t;const r=this.params.advancedFilterExpressionService.getColId(this.colName);return r&&this.hasStartChar&&(this.colId=r.colId,be(this.params,this.colName,r.columnName,t-1),this.colName=r.columnName,this.column=this.params.columnModel.getPrimaryColumn(this.colId),this.column)?(this.baseCellDataType=null!=(i=this.params.dataTypeService.getBaseDataType(this.column))?i:"text",!0):(e&&(this.valid=!1),this.baseCellDataType="text",!1)}},Ae=class{constructor(e,t,i){this.params=e,this.startPosition=t,this.baseCellDataType=i,this.type="operator",this.valid=!0,this.expectedNumOperands=0,this.operator=""}parse(e,t){if(" "===e||")"===e){if(this.parseOperator(!1,t-1))return!0;this.operator+=e}else this.operator+=e}complete(e){this.parseOperator(!0,e)}getValidationError(){var e;return this.valid?null:{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidOption"),startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}}getDisplayValue(){return this.operator}getOperatorKey(){return this.parsedOperator}parseOperator(e,t){const i=this.params.advancedFilterExpressionService.getDataTypeExpressionOperator(this.baseCellDataType),r=i.findOperator(this.operator);if(this.endPosition=t,r){this.parsedOperator=r;const e=i.operators[r];this.expectedNumOperands=e.numOperands;const n=e.displayValue;return be(this.params,this.operator,n,t),this.operator=n,!0}return!e&&null===r||(this.valid=!1),!1}},Te=class{constructor(e,t,i,r){this.params=e,this.startPosition=t,this.baseCellDataType=i,this.column=r,this.type="operand",this.valid=!0,this.operand="",this.validationMessage=null}parse(e,t){if(" "===e){if(!this.quotes)return this.parseOperand(!1,t),!0;this.operand+=e}else if(")"===e){if("number"===this.baseCellDataType||!this.quotes)return this.parseOperand(!1,t-1),!0;this.operand+=e}else if(this.operand||this.quotes||"'"!==e&&'"'!==e){if(this.quotes&&e===this.quotes)return this.parseOperand(!1,t),!1;this.operand+=e}else this.quotes=e}complete(e){this.parseOperand(!0,e)}getValidationError(){var e;return this.validationMessage?{message:this.validationMessage,startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}:null}getRawValue(){return this.operand}getModelValue(){return this.modelValue}parseOperand(e,t){const{advancedFilterExpressionService:i}=this.params;if(this.endPosition=t,this.modelValue=this.operand,e&&this.quotes)this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationMissingQuote");else if(""===this.modelValue)this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationMissingValue");else{const e=i.getOperandModelValue(this.operand,this.baseCellDataType,this.column);switch(null!=e&&(this.modelValue=e),this.baseCellDataType){case"number":(this.quotes||isNaN(this.modelValue))&&(this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationNotANumber"));break;case"date":case"dateString":null==e&&(this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationInvalidDate"))}}}},Me=class{constructor(e,t){this.params=e,this.startPosition=t,this.isAwaiting=!0}parseExpression(){var e,t;let i=this.startPosition;const{expression:r}=this.params;for(;i<r.length;){const e=r[i];if(" "===e&&this.isAwaiting);else{if(this.isAwaiting=!1,!this.parser){let e;this.columnParser?this.operatorParser?(this.operandParser=new Te(this.params,i,this.columnParser.baseCellDataType,this.columnParser.column),e=this.operandParser):(this.operatorParser=new Ae(this.params,i,this.columnParser.baseCellDataType),e=this.operatorParser):(this.columnParser=new Ee(this.params,i),e=this.columnParser),this.parser=e}const t=this.parser.parse(e,i);if(null!=t){if(this.isComplete())return this.returnEndPosition(t?i-1:i,!0);this.parser=void 0,this.isAwaiting=!0}}i++}return null==(t=null==(e=this.parser)?void 0:e.complete)||t.call(e,i-1),this.returnEndPosition(i)}isValid(){return this.isComplete()&&this.columnParser.valid&&this.operatorParser.valid&&(!this.operandParser||this.operandParser.valid)}getValidationError(){var e,t,i,r,n;const s=null!=(n=null!=(i=null==(e=this.columnParser)?void 0:e.getValidationError())?i:null==(t=this.operatorParser)?void 0:t.getValidationError())?n:null==(r=this.operandParser)?void 0:r.getValidationError();if(s)return s;const o=this.params.expression.length;let a;return this.columnParser?this.operatorParser?this.operatorParser.expectedNumOperands&&!this.operandParser&&(a="advancedFilterValidationMissingValue"):a="advancedFilterValidationMissingOption":a="advancedFilterValidationMissingColumn",a?{message:this.params.advancedFilterExpressionService.translate(a),startPosition:o,endPosition:o}:null}getFunctionString(e){return this.getFunctionCommon(e,(e,t,i,r)=>`params.operators[${t}].evaluator(expressionProxy.getValue('${i.replace(/(['"])/,"\\$1")}', node), node, params.evaluatorParams[${r}]${null==e?"":`, params.operands[${e}]`})`)}getFunctionParsed(e){return this.getFunctionCommon(e,(e,t,i,r)=>(n,s,o)=>o.operators[t].evaluator(n.getValue(i,s),s,o.evaluatorParams[r],null==e?void 0:o.operands[e]))}getAutocompleteListParams(e){return this.isColumnPosition(e)?this.getColumnAutocompleteListParams(e):this.isOperatorPosition(e)?this.getOperatorAutocompleteListParams(e):this.isBeyondEndPosition(e)?void 0:{enabled:!1}}updateExpression(e,t,i){var r,n,s,o,a;const{expression:l}=this.params;if(this.isColumnPosition(e))return we(this.params.expression,this.startPosition,(null==(r=this.columnParser)?void 0:r.getColId())?this.columnParser.endPosition:Se(l,e).endPosition,this.params.advancedFilterExpressionService.getColumnValue(t),!0);if(this.isOperatorPosition(e)){const r=this.getBaseCellDataTypeFromOperatorAutocompleteType(i),c=this.hasOperand(r,t.key),u=c&&this.doesOperandNeedQuotes(r);let h;if(null!=(null==(n=this.operatorParser)?void 0:n.startPosition)&&e<this.operatorParser.startPosition)h=we(l,e,e,null!=(s=t.displayValue)?s:t.key,c,u);else{let i,r=!1;if(null==(o=this.operatorParser)?void 0:o.getOperatorKey())i=this.operatorParser.endPosition;else{const{endPosition:t,isEmpty:n}=Se(l,e,!0,!0);i=t,r=n}h=we(l,function(e,t,i){let r=t;for(;r<i&&" "===e[r];)r++;return r}(l,this.columnParser.endPosition+1,i),i,null!=(a=t.displayValue)?a:t.key,c,u,r)}return J(Z({},h),{hideAutocomplete:!c})}return null}getModel(){const e=this.columnParser.getColId(),t={filterType:this.columnParser.baseCellDataType,colId:e,type:this.operatorParser.getOperatorKey()};return this.operatorParser.expectedNumOperands&&(t.filter=this.operandParser.getModelValue()),t}getFunctionCommon(e,t){var i,r;const n=this.columnParser.getColId(),s=null==(i=this.operatorParser)?void 0:i.getOperatorKey(),{operators:o,evaluatorParams:a,operands:l}=e,c=this.params.advancedFilterExpressionService.getExpressionOperator(this.columnParser.baseCellDataType,s),u=this.addToListAndGetIndex(o,c),h=this.params.advancedFilterExpressionService.getExpressionEvaluatorParams(n),d=this.addToListAndGetIndex(a,h);return t(0===(null==(r=this.operatorParser)?void 0:r.expectedNumOperands)?void 0:this.addToListAndGetIndex(l,this.getOperandValue()),u,n,d)}getOperandValue(){let e=this.operandParser.getRawValue();const{baseCellDataType:t,column:i}=this.columnParser;switch(t){case"number":e=Number(e);break;case"date":case"dateString":e=this.params.valueService.parseValue(i,null,e,void 0)}return"dateString"===t?this.params.dataTypeService.getDateParserFunction(i)(e):e}isComplete(){return!(!this.operatorParser||!(!this.operatorParser.expectedNumOperands||this.operatorParser.expectedNumOperands&&this.operandParser))}isColumnPosition(e){return!this.columnParser||null==this.columnParser.endPosition||e<=this.columnParser.endPosition+1}isOperatorPosition(e){return!this.operatorParser||null==this.operatorParser.endPosition||e<=this.operatorParser.endPosition+1}isBeyondEndPosition(e){return this.isComplete()&&null!=this.endPosition&&e>this.endPosition+1&&this.endPosition+1<this.params.expression.length}returnEndPosition(e,t){return this.endPosition=t?e:e-1,e}getColumnAutocompleteListParams(e){return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getColumnAutocompleteEntries(),"column",this.getColumnSearchString(e))}getColumnSearchString(e){var t,i,r,n,s;const o=null!=(i=null==(t=this.columnParser)?void 0:t.getDisplayValue())?i:"",a=ye(o,e,null==(null==(r=this.columnParser)?void 0:r.endPosition)?this.params.expression.length:this.columnParser.endPosition+1),l=(null==(n=this.columnParser)?void 0:n.hasStartChar)&&a.length>0,c=(null==(s=this.columnParser)?void 0:s.hasEndChar)&&a.length===o.length+2;return l?a.slice(1,c?-1:void 0):a}getOperatorAutocompleteListParams(e){var t,i,r,n,s;const o=null==(t=this.columnParser)?void 0:t.column;if(!o)return{enabled:!1};const a=this.columnParser.baseCellDataType,l=null!=(null==(i=this.operatorParser)?void 0:i.startPosition)&&e<this.operatorParser.startPosition?"":ye(null!=(n=null==(r=this.operatorParser)?void 0:r.getDisplayValue())?n:"",e,null==(null==(s=this.operatorParser)?void 0:s.endPosition)?this.params.expression.length:this.operatorParser.endPosition+1);return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getOperatorAutocompleteEntries(o,a),`operator-${a}`,l)}getBaseCellDataTypeFromOperatorAutocompleteType(e){return null==e?void 0:e.replace("operator-","")}hasOperand(e,t){var i,r;return!e||!t||(null!=(r=null==(i=this.params.advancedFilterExpressionService.getExpressionOperator(e,t))?void 0:i.numOperands)?r:0)>0}doesOperandNeedQuotes(e){return"number"!==e}addToListAndGetIndex(e,t){const i=e.length;return e.push(t),i}};function Re(e,t,i){let r=!1;const n=e.toLocaleLowerCase(),s=n+" ",o=Object.entries(t).find(([e,t])=>{const o=i(t).toLocaleLowerCase();return o.startsWith(s)&&(r=!0),o===n});return o?o[0]:r?null:void 0}function _e(e,t){return(null!=t?t:Object.keys(e)).map(t=>({key:t,displayValue:e[t].displayValue}))}Me.COL_START_CHAR="[",Me.COL_END_CHAR="]";var Pe=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return _e(this.operators,e)}findOperator(e){return Re(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e}=this.params;this.operators={contains:{displayValue:e("advancedFilterContains"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.includes(t)),numOperands:1},notContains:{displayValue:e("advancedFilterNotContains"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!0,(e,t)=>!e.includes(t)),numOperands:1},equals:{displayValue:e("advancedFilterTextEquals"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e===t),numOperands:1},notEqual:{displayValue:e("advancedFilterTextNotEqual"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!0,(e,t)=>e!=t),numOperands:1},startsWith:{displayValue:e("advancedFilterStartsWith"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.startsWith(t)),numOperands:1},endsWith:{displayValue:e("advancedFilterEndsWith"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.endsWith(t)),numOperands:1},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e||"string"==typeof e&&0===e.trim().length,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e&&("string"!=typeof e||e.trim().length>0),numOperands:0}}}evaluateExpression(e,t,i,r,n,s){return null==e?n:i.caseSensitive?s(i.valueConverter(e,t),r):s(i.valueConverter(e,t).toLocaleLowerCase(),r.toLocaleLowerCase())}},xe=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return _e(this.operators,e)}findOperator(e){return Re(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e,equals:t}=this.params;this.operators={equals:{displayValue:e("advancedFilterEquals"),evaluator:(e,i,r,n)=>this.evaluateSingleOperandExpression(e,i,r,n,!!r.includeBlanksInEquals,t),numOperands:1},notEqual:{displayValue:e("advancedFilterNotEqual"),evaluator:(e,i,r,n)=>this.evaluateSingleOperandExpression(e,i,r,n,!!r.includeBlanksInEquals,(e,i)=>!t(e,i)),numOperands:1},greaterThan:{displayValue:e("advancedFilterGreaterThan"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInGreaterThan,(e,t)=>e>t),numOperands:1},greaterThanOrEqual:{displayValue:e("advancedFilterGreaterThanOrEqual"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInGreaterThan,(e,t)=>e>=t),numOperands:1},lessThan:{displayValue:e("advancedFilterLessThan"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInLessThan,(e,t)=>e<t),numOperands:1},lessThanOrEqual:{displayValue:e("advancedFilterLessThanOrEqual"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInLessThan,(e,t)=>e<=t),numOperands:1},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e,numOperands:0}}}evaluateSingleOperandExpression(e,t,i,r,n,s){return null==e?n:s(i.valueConverter(e,t),r)}},De=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return _e(this.operators,e)}findOperator(e){return Re(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e}=this.params;this.operators={true:{displayValue:e("advancedFilterTrue"),evaluator:e=>!!e,numOperands:0},false:{displayValue:e("advancedFilterFalse"),evaluator:e=>!1===e,numOperands:0},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e,numOperands:0}}}},Ie=class extends z.BeanStub{constructor(){super(...arguments),this.columnNameToIdMap={},this.columnAutocompleteEntries=null,this.expressionEvaluatorParams={}}postConstruct(){this.expressionJoinOperators=this.generateExpressionJoinOperators(),this.expressionOperators=this.generateExpressionOperators()}parseJoinOperator(e){var t;const{type:i}=e;return null!=(t=this.expressionJoinOperators[i])?t:i}getColumnDisplayValue(e){const{colId:t}=e,i=this.getColumnAutocompleteEntries().find(({key:e})=>e===t);let r;return i?(r=i.displayValue,this.columnNameToIdMap[r.toLocaleUpperCase()]={colId:t,columnName:r}):r=t,r}getOperatorDisplayValue(e){var t,i;return null!=(i=null==(t=this.getExpressionOperator(e.filterType,e.type))?void 0:t.displayValue)?i:e.type}getOperandModelValue(e,t,i){var r;switch(t){case"number":return z._.exists(e)?Number(e):null;case"date":return z._.serialiseDate(this.valueService.parseValue(i,null,e,void 0),!1);case"dateString":const t=this.valueService.parseValue(i,null,e,void 0);return z._.serialiseDate(null!=(r=this.dataTypeService.getDateParserFunction(i)(t))?r:null,!1)}return e}getOperandDisplayValue(e,t){var i,r;const{colId:n,filter:s}=e,o=this.columnModel.getPrimaryColumn(n);let a="";if(null!=s){let n;switch(e.filterType){case"number":n=null!=(i=z._.toStringOrNull(s))?i:"";break;case"date":const e=z._.parseDateTimeFromString(s);n=o?this.valueService.formatValue(o,null,e):null;break;case"dateString":const t=z._.parseDateTimeFromString(s),r=o?this.dataTypeService.getDateFormatterFunction(o)(null!=t?t:void 0):null;n=o?this.valueService.formatValue(o,null,r):null}"number"!==e.filterType&&(n=null!=(r=null!=n?n:z._.toStringOrNull(s))?r:"",t||(n=`"${n}"`)),a=t?n:` ${n}`}return a}parseColumnFilterModel(e){var t,i;return`[${null!=(t=this.getColumnDisplayValue(e))?t:""}] ${null!=(i=this.getOperatorDisplayValue(e))?i:""}${this.getOperandDisplayValue(e)}`}updateAutocompleteCache(e,t){if("column"===t){const{key:t,displayValue:i}=e;this.columnNameToIdMap[e.displayValue.toLocaleUpperCase()]={colId:t,columnName:i}}}translate(e,t){let i=Ce[e];return"function"==typeof i&&(i=i(t)),this.localeService.getLocaleTextFunc()(e,i,t)}generateAutocompleteListParams(e,t,i){return{enabled:!0,type:t,searchString:i,entries:e}}getColumnAutocompleteEntries(){var e;if(this.columnAutocompleteEntries)return this.columnAutocompleteEntries;const t=null!=(e=this.columnModel.getAllPrimaryColumns())?e:[],i=[],r=this.gos.get("includeHiddenColumnsInAdvancedFilter");return t.forEach(e=>{e.getColDef().filter&&(r||e.isVisible()||e.isRowGroupActive())&&i.push({key:e.getColId(),displayValue:this.columnModel.getDisplayNameForColumn(e,"advancedFilter")})}),i.sort((e,t)=>{var i,r;const n=null!=(i=e.displayValue)?i:"",s=null!=(r=t.displayValue)?r:"";return n<s?-1:s>n?1:0}),i}getOperatorAutocompleteEntries(e,t){const i=this.getActiveOperators(e);return this.getDataTypeExpressionOperator(t).getEntries(i)}getJoinOperatorAutocompleteEntries(){return Object.entries(this.expressionJoinOperators).map(([e,t])=>({key:e,displayValue:t}))}getDefaultAutocompleteListParams(e){return this.generateAutocompleteListParams(this.getColumnAutocompleteEntries(),"column",e)}getDataTypeExpressionOperator(e){return this.expressionOperators[e]}getExpressionOperator(e,t){var i,r;return null==(r=null==(i=this.getDataTypeExpressionOperator(e))?void 0:i.operators)?void 0:r[t]}getExpressionJoinOperators(){return this.expressionJoinOperators}getColId(e){const t=e.toLocaleUpperCase(),i=this.columnNameToIdMap[t];if(i)return i;const r=this.getColumnAutocompleteEntries().find(({displayValue:e})=>e.toLocaleUpperCase()===t);if(r){const{key:e,displayValue:i}=r,n={colId:e,columnName:i};return this.columnNameToIdMap[t]=n,n}return null}getExpressionEvaluatorParams(e){let t=this.expressionEvaluatorParams[e];if(t)return t;const i=this.columnModel.getPrimaryColumn(e);if(!i)return{valueConverter:e=>e};switch(this.dataTypeService.getBaseDataType(i)){case"dateString":t={valueConverter:this.dataTypeService.getDateParserFunction(i)};break;case"object":t=i.getColDef().filterValueGetter?{valueConverter:e=>e}:{valueConverter:(e,t)=>{var r;return null!=(r=this.valueService.formatValue(i,t,e))?r:"function"==typeof e.toString?e.toString():""}};break;case"text":case void 0:t={valueConverter:e=>z._.toStringOrNull(e)};break;default:t={valueConverter:e=>e}}const{filterParams:r}=i.getColDef();return r&&["caseSensitive","includeBlanksInEquals","includeBlanksInLessThan","includeBlanksInGreaterThan"].forEach(e=>{const i=r[e];i&&(t[e]=i)}),this.expressionEvaluatorParams[e]=t,t}getColumnDetails(e){var t,i;const r=null!=(t=this.columnModel.getPrimaryColumn(e))?t:void 0;return{column:r,baseCellDataType:null!=(i=r?this.dataTypeService.getBaseDataType(r):void 0)?i:"text"}}generateExpressionOperators(){const e=(e,t)=>this.translate(e,t);return{text:new Pe({translate:e}),boolean:new De({translate:e}),object:new Pe({translate:e}),number:new xe({translate:e,equals:(e,t)=>e===t}),date:new xe({translate:e,equals:(e,t)=>e.getTime()===t.getTime()}),dateString:new xe({translate:e,equals:(e,t)=>e.getTime()===t.getTime()})}}getColumnValue({displayValue:e}){return`${Me.COL_START_CHAR}${e}${Me.COL_END_CHAR}`}generateExpressionJoinOperators(){return{AND:this.translate("advancedFilterAnd"),OR:this.translate("advancedFilterOr")}}getActiveOperators(e){var t;const i=null==(t=e.getColDef().filterParams)?void 0:t.filterOptions;if(i)return i.every(e=>"string"==typeof e)?i:void 0}resetColumnCaches(){this.columnAutocompleteEntries=null,this.columnNameToIdMap={},this.expressionEvaluatorParams={}}};ee([(0,z.Autowired)("valueService")],Ie.prototype,"valueService",2),ee([(0,z.Autowired)("columnModel")],Ie.prototype,"columnModel",2),ee([(0,z.Autowired)("dataTypeService")],Ie.prototype,"dataTypeService",2),ee([z.PostConstruct],Ie.prototype,"postConstruct",1),Ie=ee([(0,z.Bean)("advancedFilterExpressionService")],Ie);var Le=class{constructor(e){this.params=e,this.operators=[],this.operatorStartPositions=[],this.operatorEndPositions=[],this.activeOperator=0,this.validationError=null}parseExpression(e){this.operators.push(""),this.operatorStartPositions.push(e),this.operatorEndPositions.push(void 0);const{expression:t}=this.params;for(;e<t.length;){const i=t[e];if(" "===i){if(this.parseOperator(e-1))return this.activeOperator++,e-1;this.operators[this.activeOperator]+=i}else this.operators[this.activeOperator]+=i;e++}return this.parseOperator(e-1),e}isValid(){return!(this.validationError||this.operators.length&&!this.parsedOperator)}getValidationError(){return this.validationError}getFunction(){return"OR"===this.parsedOperator?"||":"&&"}getModel(){return"OR"===this.parsedOperator?"OR":"AND"}getAutocompleteListParams(e,t){let i;if(null==t)i="";else{const r=this.operators[t],n=this.operatorEndPositions[t];i=ye(r,e,null==n?this.params.expression.length:n+1)}let r=this.params.advancedFilterExpressionService.getJoinOperatorAutocompleteEntries();return(t||null==t&&this.activeOperator)&&(r=r.filter(({key:e})=>e===this.parsedOperator)),this.params.advancedFilterExpressionService.generateAutocompleteListParams(r,"join",i)}updateExpression(e,t,i){var r,n;let{expression:s}=this.params;const o=null!=(r=t.displayValue)?r:t.key;if(0===i)for(let e=this.operatorEndPositions.length-1;e>0;e--){const t=this.operatorEndPositions[e];null!=t&&(s=we(s,this.operatorStartPositions[e],t,o).updatedValue)}return we(s,this.operatorStartPositions.length>i?this.operatorStartPositions[i]:e,null!=(n=this.operatorEndPositions.length>i?this.operatorEndPositions[i]:void 0)?n:Se(s,e,!0).endPosition,o,!0)}getNumOperators(){return this.operators.length}getLastOperatorEndPosition(){return this.operatorEndPositions[this.operatorEndPositions.length-1]}parseOperator(e){const t=this.operators.length>this.activeOperator?this.operators[this.activeOperator]:"",i=this.params.advancedFilterExpressionService.getExpressionJoinOperators(),r=Re(t,i,e=>e);if(r){this.operatorEndPositions[this.activeOperator]=e;const n=i[r];if(this.activeOperator){if(r!==this.parsedOperator)return this.validationError||(this.validationError={message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationJoinOperatorMismatch"),startPosition:e-t.length+1,endPosition:e}),!1}else this.parsedOperator=r;return t!==n&&(be(this.params,t,n,e),this.operators[this.activeOperator]=n),!0}return null!==r&&(this.validationError||(this.validationError={message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidJoinOperator"),startPosition:e-t.length+1,endPosition:e}),!0)}},Ne=class e{constructor(e,t){this.params=e,this.startPosition=t,this.expectingExpression=!0,this.expectingOperator=!1,this.expressionParsers=[],this.operatorParser=new Le(this.params),this.missingEndBracket=!1,this.extraEndBracket=!1}parseExpression(){let t=this.startPosition;const{expression:i}=this.params;for(;t<i.length;){const r=i[t];if("("!==r||this.expectingOperator){if(")"===r)return this.endPosition=t-1,0===this.startPosition&&(this.extraEndBracket=!0),t;if(" "===r);else if(this.expectingExpression){const e=new Me(this.params,t);t=e.parseExpression(),this.expressionParsers.push(e),this.expectingExpression=!1,this.expectingOperator=!0}else this.expectingOperator&&(t=this.operatorParser.parseExpression(t),this.expectingOperator=!1,this.expectingExpression=!0)}else{const i=new e(this.params,t+1);t=i.parseExpression(),this.expressionParsers.push(i),this.expectingExpression=!1,this.expectingOperator=!0}t++}return this.startPosition>0&&(this.missingEndBracket=!0),t}isValid(){return!this.missingEndBracket&&!this.extraEndBracket&&this.expressionParsers.length===this.operatorParser.getNumOperators()+1&&this.operatorParser.isValid()&&this.expressionParsers.every(e=>e.isValid())}getValidationError(){const e=this.operatorParser.getValidationError();for(let t=0;t<this.expressionParsers.length;t++){const i=this.expressionParsers[t].getValidationError();if(i)return e&&e.startPosition<i.startPosition?e:i}if(e)return e;if(this.extraEndBracket)return{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationExtraEndBracket"),startPosition:this.endPosition+1,endPosition:this.endPosition+1};let t;return this.expressionParsers.length===this.operatorParser.getNumOperators()?t="advancedFilterValidationMissingCondition":this.missingEndBracket&&(t="advancedFilterValidationMissingEndBracket"),t?{message:this.params.advancedFilterExpressionService.translate(t),startPosition:this.params.expression.length,endPosition:this.params.expression.length}:null}getFunctionString(e){const t=this.expressionParsers.length>1,i=this.expressionParsers.map(t=>t.getFunctionString(e)).join(` ${this.operatorParser.getFunction()} `);return t?`(${i})`:i}getFunctionParsed(e){const t=this.operatorParser.getFunction(),i=this.expressionParsers.map(t=>t.getFunctionParsed(e)),r="&&"===t?"every":"some";return(e,t,n)=>i[r](i=>i(e,t,n))}getAutocompleteListParams(e){if(null!=this.endPosition&&e>this.endPosition+1)return;if(!this.expressionParsers.length)return this.getColumnAutocompleteListParams();const t=this.getExpressionParserIndex(e);if(null==t)return"("===this.params.expression[e]?{enabled:!1}:this.getColumnAutocompleteListParams();const i=this.expressionParsers[t].getAutocompleteListParams(e);if(!i){if(t<this.expressionParsers.length-1)return this.operatorParser.getAutocompleteListParams(e,t);if(this.expressionParsers.length===this.operatorParser.getNumOperators()){const t=this.operatorParser.getLastOperatorEndPosition();return null==t||e<=t+1?this.operatorParser.getAutocompleteListParams(e,this.operatorParser.getNumOperators()-1):this.getColumnAutocompleteListParams()}return")"===this.params.expression[e-1]?{enabled:!1}:this.operatorParser.getAutocompleteListParams(e)}return i}updateExpression(e,t,i){var r;const n=this.params.expression,s=this.getExpressionParserIndex(e);if(null==s){const e="column"===i?this.params.advancedFilterExpressionService.getColumnValue(t):null!=(r=t.displayValue)?r:t.key;return we(n,this.startPosition,this.startPosition,e,!0)}const o=this.expressionParsers[s].updateExpression(e,t,i);return null==o?"column"===i?we(n,e,n.length-1,this.params.advancedFilterExpressionService.getColumnValue(t),!0):null!=this.endPosition&&e>this.endPosition+1?null:this.operatorParser.updateExpression(e,t,s):o}getModel(){return this.expressionParsers.length>1?{filterType:"join",type:this.operatorParser.getModel(),conditions:this.expressionParsers.map(e=>e.getModel())}:this.expressionParsers[0].getModel()}getColumnAutocompleteListParams(){return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getColumnAutocompleteEntries(),"column","")}getExpressionParserIndex(e){let t;for(let i=0;i<this.expressionParsers.length&&!(this.expressionParsers[i].startPosition>e);i++)t=i;return t}},Oe=class{constructor(e){this.params=e,this.valid=!1}parseExpression(){this.joinExpressionParser=new Ne(this.params,0);const e=this.joinExpressionParser.parseExpression();return this.valid=e>=this.params.expression.length-1&&this.joinExpressionParser.isValid(),this.params.expression}isValid(){return this.valid}getValidationMessage(){const e=this.joinExpressionParser.getValidationError();if(!e)return null;const{message:t,startPosition:i,endPosition:r}=e;return i<this.params.expression.length?this.params.advancedFilterExpressionService.translate("advancedFilterValidationMessage",[t,this.params.expression.slice(i,r+1).trim()]):this.params.advancedFilterExpressionService.translate("advancedFilterValidationMessageAtEnd",[t])}getFunctionString(){const e=this.createFunctionParams();return{functionString:`return ${this.joinExpressionParser.getFunctionString(e)};`,params:e}}getFunctionParsed(){const e=this.createFunctionParams();return{expressionFunction:this.joinExpressionParser.getFunctionParsed(e),params:e}}getAutocompleteListParams(e){var t;return null!=(t=this.joinExpressionParser.getAutocompleteListParams(e))?t:{enabled:!1}}updateExpression(e,t,i){return this.joinExpressionParser.updateExpression(e,t,i)}getModel(){return this.isValid()?this.joinExpressionParser.getModel():null}createFunctionParams(){return{operands:[],operators:[],evaluatorParams:[]}}},Fe=class extends U.BeanStub{constructor(){super(...arguments),this.appliedExpression=null,this.expression=null,this.isValid=!0}postConstruct(){this.setEnabled(this.gos.get("enableAdvancedFilter"),!0),this.ctrl=this.createManagedBean(new me(this.enabled)),this.expressionProxy={getValue:(e,t)=>{const i=this.columnModel.getPrimaryColumn(e);return i?this.valueService.getValue(i,t,!0):void 0}},this.addManagedPropertyListener("enableAdvancedFilter",e=>this.setEnabled(!!e.currentValue)),this.addManagedListener(this.eventService,U.Events.EVENT_NEW_COLUMNS_LOADED,e=>this.onNewColumnsLoaded(e)),this.addManagedPropertyListener("includeHiddenColumnsInAdvancedFilter",()=>this.updateValidity())}isEnabled(){return this.enabled}isFilterPresent(){return!!this.expressionFunction}doesFilterPass(e){return this.expressionFunction(this.expressionProxy,e,this.expressionParams)}getModel(){var e;const t=this.createExpressionParser(this.appliedExpression);return null==t||t.parseExpression(),null!=(e=null==t?void 0:t.getModel())?e:null}setModel(e){const t=(e,i)=>{if("join"===e.filterType){const r=this.advancedFilterExpressionService.parseJoinOperator(e),n=e.conditions.map(e=>t(e)).filter(e=>U._.exists(e)).join(` ${r} `);return i||e.conditions.length<=1?n:`(${n})`}return this.advancedFilterExpressionService.parseColumnFilterModel(e)},i=e?t(e,!0):null;this.setExpressionDisplayValue(i),this.applyExpression(),this.ctrl.refreshComp(),this.ctrl.refreshBuilderComp()}getExpressionDisplayValue(){return this.expression}setExpressionDisplayValue(e){this.expression=e}isCurrentExpressionApplied(){return this.appliedExpression===this.expression}createExpressionParser(e){return e?new Oe({expression:e,columnModel:this.columnModel,dataTypeService:this.dataTypeService,valueService:this.valueService,advancedFilterExpressionService:this.advancedFilterExpressionService}):null}getDefaultExpression(e){const t=this.advancedFilterExpressionService.getColumnValue(e)+" ";return{updatedValue:t,updatedPosition:t.length}}isHeaderActive(){return!this.gos.get("advancedFilterParent")}getCtrl(){return this.ctrl}setEnabled(e,t){const i=this.enabled,r=this.rowModel.getType(),n="clientSide"===r||"serverSide"===r;if(e&&!r&&U._.warnOnce("Advanced Filter is only supported with the Client-Side Row Model or Server-Side Row Model."),this.enabled=e&&n,!t&&this.enabled!==i){const e={type:U.Events.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,enabled:this.enabled};this.eventService.dispatchEvent(e)}}applyExpression(){const e=this.createExpressionParser(this.expression);null==e||e.parseExpression(),this.applyExpressionFromParser(e)}applyExpressionFromParser(e){if(this.isValid=!e||e.isValid(),!e||!this.isValid)return this.expressionFunction=null,this.expressionParams=null,void(this.appliedExpression=null);const{expressionFunction:t,params:i}=this.getFunction(e);this.expressionFunction=t,this.expressionParams=i,this.appliedExpression=this.expression}getFunction(e){if(this.gos.get("suppressAdvancedFilterEval"))return e.getFunctionParsed();{const{functionString:t,params:i}=e.getFunctionString();return{expressionFunction:new Function("expressionProxy","node","params",t),params:i}}}updateValidity(){this.advancedFilterExpressionService.resetColumnCaches();const e=this.createExpressionParser(this.expression);null==e||e.parseExpression();const t=(!e||e.isValid())!==this.isValid;return this.applyExpressionFromParser(e),this.ctrl.refreshComp(),this.ctrl.refreshBuilderComp(),t}onNewColumnsLoaded(e){if("gridInitializing"!==e.source||!this.dataTypeService.isPendingInference())return;this.ctrl.setInputDisabled(!0);const t=this.addManagedListener(this.eventService,U.Events.EVENT_DATA_TYPES_INFERRED,()=>{null==t||t(),this.ctrl.setInputDisabled(!1)})}};ee([(0,U.Autowired)("valueService")],Fe.prototype,"valueService",2),ee([(0,U.Autowired)("columnModel")],Fe.prototype,"columnModel",2),ee([(0,U.Autowired)("dataTypeService")],Fe.prototype,"dataTypeService",2),ee([(0,U.Autowired)("rowModel")],Fe.prototype,"rowModel",2),ee([(0,U.Autowired)("advancedFilterExpressionService")],Fe.prototype,"advancedFilterExpressionService",2),ee([U.PostConstruct],Fe.prototype,"postConstruct",1),Fe=ee([(0,U.Bean)("advancedFilterService")],Fe);var ke={version:"31.3.4",moduleName:v.ModuleNames.AdvancedFilterModule,beans:[Fe,Ie],agStackComponents:[{componentName:"agAdvancedFilter",componentClass:ve}],dependantModules:[_]},Ge={};l(Ge,{GridChartsModule:()=>Ja,__FORCE_MODULE_DETECTION_AG_GRID_CORE_EXT:()=>el,agCharts:()=>tl});var Ve=i(98092),He=i(98092),Be=i(98092),ze=i(98092),Ue=i(98092),We=i(98092),je=i(98092),Ke=Object.defineProperty,$e=Object.defineProperties,qe=Object.getOwnPropertyDescriptor,Ye=Object.getOwnPropertyDescriptors,Qe=Object.getOwnPropertySymbols,Xe=Object.prototype.hasOwnProperty,Ze=Object.prototype.propertyIsEnumerable,Je=(e,t,i)=>t in e?Ke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,et=(e,t)=>{for(var i in t||(t={}))Xe.call(t,i)&&Je(e,i,t[i]);if(Qe)for(var i of Qe(t))Ze.call(t,i)&&Je(e,i,t[i]);return e},tt=(e,t)=>$e(e,Ye(t)),it=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?qe(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Ke(t,i,s),s},rt=class extends Be.BeanStub{constructor(){super(...arguments),this.cellRanges=[],this.bodyScrollListener=this.onBodyScroll.bind(this),this.dragging=!1,this.intersectionRange=!1}init(){this.addManagedListener(this.eventService,Be.Events.EVENT_NEW_COLUMNS_LOADED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_VISIBLE,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_VALUE_CHANGED,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_PIVOT_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_GROUP_OPENED,this.refreshLastRangeStart.bind(this)),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_MOVED,this.refreshLastRangeStart.bind(this)),this.addManagedListener(this.eventService,Be.Events.EVENT_COLUMN_PINNED,this.refreshLastRangeStart.bind(this)),this.ctrlsService.whenReady(e=>{const t=e.gridBodyCtrl;this.autoScrollService=new Be.AutoScrollService({scrollContainer:t.getBodyViewportElement(),scrollAxis:"xy",getVerticalPosition:()=>t.getScrollFeature().getVScrollPosition().top,setVerticalPosition:e=>t.getScrollFeature().setVerticalScrollPosition(e),getHorizontalPosition:()=>t.getScrollFeature().getHScrollPosition().left,setHorizontalPosition:e=>t.getScrollFeature().setHorizontalScrollPosition(e),shouldSkipVerticalScroll:()=>!this.gos.isDomLayout("normal"),shouldSkipHorizontalScroll:()=>!t.getScrollFeature().isHorizontalScrollShowing()})})}onColumnsChanged(){this.refreshLastRangeStart();const e=this.columnModel.getAllDisplayedColumns();this.cellRanges.forEach(t=>{const i=t.columns;t.columns=t.columns.filter(t=>t.isVisible()&&-1!==e.indexOf(t)),!Be._.areEqual(i,t.columns)&&this.dispatchChangedEvent(!1,!0,t.id)});const t=this.cellRanges.length;this.cellRanges=this.cellRanges.filter(e=>e.columns.length>0),t>this.cellRanges.length&&this.dispatchChangedEvent(!1,!0)}refreshLastRangeStart(){const e=Be._.last(this.cellRanges);e&&this.refreshRangeStart(e)}isContiguousRange(e){const t=e.columns;if(!t.length)return!1;const i=this.columnModel.getAllDisplayedColumns(),r=t.map(e=>i.indexOf(e)).sort((e,t)=>e-t);return Be._.last(r)-r[0]+1===t.length}getRangeStartRow(e){return e.startRow&&e.endRow?this.rowPositionUtils.before(e.startRow,e.endRow)?e.startRow:e.endRow:{rowIndex:0,rowPinned:this.pinnedRowModel.getPinnedTopRowCount()>0?"top":null}}getRangeEndRow(e){if(e.startRow&&e.endRow)return this.rowPositionUtils.before(e.startRow,e.endRow)?e.endRow:e.startRow;const t=this.pinnedRowModel.getPinnedBottomRowCount();return t>0?{rowIndex:t-1,rowPinned:"bottom"}:{rowIndex:this.rowModel.getRowCount()-1,rowPinned:null}}setRangeToCell(e,t=!1){if(!this.gos.get("enableRangeSelection"))return;const i=this.calculateColumnsBetween(e.column,e.column);if(!i)return;(this.gos.get("suppressMultiRangeSelection")||!t||Be._.missing(this.cellRanges))&&this.removeAllCellRanges(!0);const r={rowIndex:e.rowIndex,rowPinned:e.rowPinned},n={startRow:r,endRow:r,columns:i,startColumn:e.column};this.cellRanges.push(n),this.setNewestRangeStartCell(e),this.onDragStop(),this.dispatchChangedEvent(!0,!0)}extendLatestRangeToCell(e){if(this.isEmpty()||!this.newestRangeStartCell)return;const t=Be._.last(this.cellRanges);this.updateRangeEnd(t,e)}updateRangeEnd(e,t,i=!1){const r=t.column,n=this.calculateColumnsBetween(e.startColumn,r);n&&!this.isLastCellOfRange(e,t)&&(e.columns=n,e.endRow={rowIndex:t.rowIndex,rowPinned:t.rowPinned},i||this.dispatchChangedEvent(!0,!0,e.id))}refreshRangeStart(e){const{startColumn:t,columns:i}=e,r=(t,i)=>{const r=e.columns.filter(e=>e!==t);t?(e.startColumn=t,e.columns=i?[t,...r]:[...r,t]):e.columns=r},{left:n,right:s}=this.getRangeEdgeColumns(e);t!==i[0]||t===n?t===Be._.last(i)&&t===s&&r(s,!1):r(n,!0)}getRangeEdgeColumns(e){const t=this.columnModel.getAllDisplayedColumns(),i=e.columns.map(e=>t.indexOf(e)).filter(e=>e>-1).sort((e,t)=>e-t);return{left:t[i[0]],right:t[Be._.last(i)]}}extendLatestRangeInDirection(e){if(this.isEmpty()||!this.newestRangeStartCell)return;const t=e.key,i=e.ctrlKey||e.metaKey,r=Be._.last(this.cellRanges),n=this.newestRangeStartCell,s=r.columns[0],o=Be._.last(r.columns),a=r.endRow.rowIndex,l=r.endRow.rowPinned,c={column:n.column===s?o:s,rowIndex:a,rowPinned:l},u=this.cellNavigationService.getNextCellToFocus(t,c,i);return u?(this.setCellRange({rowStartIndex:n.rowIndex,rowStartPinned:n.rowPinned,rowEndIndex:u.rowIndex,rowEndPinned:u.rowPinned,columnStart:n.column,columnEnd:u.column}),u):void 0}setCellRange(e){this.gos.get("enableRangeSelection")&&(this.removeAllCellRanges(!0),this.addCellRange(e))}setCellRanges(e){Be._.shallowCompare(this.cellRanges,e)||(this.removeAllCellRanges(!0),e.forEach(e=>{e.columns&&e.startRow&&this.setNewestRangeStartCell({rowIndex:e.startRow.rowIndex,rowPinned:e.startRow.rowPinned,column:e.columns[0]}),this.cellRanges.push(e)}),this.dispatchChangedEvent(!1,!0))}setNewestRangeStartCell(e){this.newestRangeStartCell=e}clearCellRangeCellValues(e){let{cellRanges:t}=e;const{cellEventSource:i="rangeService",dispatchWrapperEvents:r,wrapperEventSource:n="deleteKey"}=e;if(r){const e={type:Be.Events.EVENT_RANGE_DELETE_START,source:n};this.eventService.dispatchEvent(e)}if(t||(t=this.cellRanges),t.forEach(e=>{this.forEachRowInRange(e,t=>{var r;const n=this.rowPositionUtils.getRowNode(t);if(n)for(let t=0;t<e.columns.length;t++){const s=this.columnModel.getGridColumn(e.columns[t]);if(!s||!s.isCellEditable(n))continue;const o=null!=(r=this.valueService.parseValue(s,n,"",n.getValueFromValueService(s)))?r:null;n.setDataValue(s,o,i)}})}),r){const e={type:Be.Events.EVENT_RANGE_DELETE_END,source:n};this.eventService.dispatchEvent(e)}}createCellRangeFromCellRangeParams(e){return this.createPartialCellRangeFromRangeParams(e,!1)}createPartialCellRangeFromRangeParams(e,t){let i,r=!1;if(e.columns)i=e.columns.map(e=>this.columnModel.getColumnWithValidation(e)).filter(e=>e);else{const t=this.columnModel.getColumnWithValidation(e.columnStart),n=this.columnModel.getColumnWithValidation(e.columnEnd);if(!t||!n)return;i=this.calculateColumnsBetween(t,n),i&&i.length&&(r=i[0]!==t)}if(i&&(t||0!==i.length))return{startRow:null!=e.rowStartIndex?{rowIndex:e.rowStartIndex,rowPinned:e.rowStartPinned||null}:void 0,endRow:null!=e.rowEndIndex?{rowIndex:e.rowEndIndex,rowPinned:e.rowEndPinned||null}:void 0,columns:i,startColumn:r?Be._.last(i):i[0]}}addCellRange(e){if(!this.gos.get("enableRangeSelection"))return;const t=this.createCellRangeFromCellRangeParams(e);t&&(t.startRow&&this.setNewestRangeStartCell({rowIndex:t.startRow.rowIndex,rowPinned:t.startRow.rowPinned,column:t.startColumn}),this.cellRanges.push(t),this.dispatchChangedEvent(!1,!0,t.id))}getCellRanges(){return this.cellRanges}isEmpty(){return 0===this.cellRanges.length}isMoreThanOneCell(){const e=this.cellRanges.length;if(0===e)return!1;if(e>1)return!0;const t=this.cellRanges[0],i=this.getRangeStartRow(t),r=this.getRangeEndRow(t);return i.rowPinned!==r.rowPinned||i.rowIndex!==r.rowIndex||1!==t.columns.length}areAllRangesAbleToMerge(){const e=new Map;if(this.cellRanges.length<=1)return!0;let t;this.cellRanges.forEach(t=>{this.forEachRowInRange(t,i=>{const r=`${i.rowPinned||"normal"}_${i.rowIndex}`,n=e.get(r),s=t.columns.map(e=>e.getId());if(n){const e=s.filter(e=>-1===n.indexOf(e));n.push(...e)}else e.set(r,s)})});for(const i of e.values()){const e=i.sort().join();if(void 0!==t){if(t!==e)return!1}else t=e}return!0}forEachRowInRange(e,t){const i=this.getRangeStartRow(e),r=this.getRangeEndRow(e);let n=i;for(;n&&(t(n),!this.rowPositionUtils.sameRow(n,r));)n=this.cellNavigationService.getRowBelow(n)}removeAllCellRanges(e){this.isEmpty()||(this.onDragStop(),this.cellRanges.length=0,e||this.dispatchChangedEvent(!1,!0))}onBodyScroll(){this.dragging&&this.lastMouseEvent&&this.onDragging(this.lastMouseEvent)}isCellInAnyRange(e){return this.getCellRangeCount(e)>0}isCellInSpecificRange(e,t){const i=null!==t.columns&&Be._.includes(t.columns,e.column),r=this.isRowInRange(e.rowIndex,e.rowPinned,t);return i&&r}isLastCellOfRange(e,t){const{startRow:i,endRow:r}=e,n=this.rowPositionUtils.before(i,r)?r:i,s=t.rowIndex===n.rowIndex&&t.rowPinned===n.rowPinned,o=e.columns[0],a=Be._.last(e.columns),l=e.startColumn===o?a:o;return t.column===l&&s}isBottomRightCell(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=e.columns.map(e=>i.indexOf(e)).sort((e,t)=>e-t),{startRow:n,endRow:s}=e,o=this.rowPositionUtils.before(n,s)?s:n,a=i.indexOf(t.column)===Be._.last(r),l=t.rowIndex===o.rowIndex&&Be._.makeNull(t.rowPinned)===Be._.makeNull(o.rowPinned);return a&&l}getCellRangeCount(e){return this.isEmpty()?0:this.cellRanges.filter(t=>this.isCellInSpecificRange(e,t)).length}isRowInRange(e,t,i){const r=this.getRangeStartRow(i),n=this.getRangeEndRow(i),s={rowIndex:e,rowPinned:t||null},o=s.rowIndex===r.rowIndex&&s.rowPinned==r.rowPinned,a=s.rowIndex===n.rowIndex&&s.rowPinned==n.rowPinned;if(o||a)return!0;const l=!this.rowPositionUtils.before(s,r),c=this.rowPositionUtils.before(s,n);return l&&c}getDraggingRange(){return this.draggingRange}onDragStart(e){if(!this.gos.get("enableRangeSelection"))return;const{ctrlKey:t,metaKey:i,shiftKey:r}=e,n=t||i,s=!this.gos.get("suppressMultiRangeSelection")&&n,o=r&&Be._.existsAndNotEmpty(this.cellRanges);s||o&&!Be._.exists(Be._.last(this.cellRanges).type)||this.removeAllCellRanges(!0);const a=this.dragService.getStartTarget();if(a&&this.updateValuesOnMove(a),this.lastCellHovered){if(this.dragging=!0,this.lastMouseEvent=e,this.intersectionRange=s&&this.getCellRangeCount(this.lastCellHovered)>1,o||this.setNewestRangeStartCell(this.lastCellHovered),this.cellRanges.length>0)this.draggingRange=Be._.last(this.cellRanges);else{const e={rowIndex:this.lastCellHovered.rowIndex,rowPinned:this.lastCellHovered.rowPinned};this.draggingRange={startRow:e,endRow:e,columns:[this.lastCellHovered.column],startColumn:this.newestRangeStartCell.column},this.cellRanges.push(this.draggingRange)}this.ctrlsService.getGridBodyCtrl().addScrollEventListener(this.bodyScrollListener),this.dispatchChangedEvent(!0,!1,this.draggingRange.id)}}intersectLastRange(e){if(e&&this.dragging)return;if(this.gos.get("suppressMultiRangeSelection"))return;if(this.isEmpty())return;const t=this.rowPositionUtils,i=Be._.last(this.cellRanges),r=this.getRangeStartRow(i),n=this.getRangeEndRow(i),s=[];this.cellRanges.slice(0,-1).forEach(e=>{const o=this.getRangeStartRow(e),a=this.getRangeEndRow(e),l=e.columns,c=l.filter(e=>-1===i.columns.indexOf(e));if(c.length===l.length)return void s.push(e);if(t.before(n,o)||t.before(a,r))return void s.push(e);const u=s.length;if(t.before(o,r)){const e={columns:[...l],startColumn:i.startColumn,startRow:et({},o),endRow:this.cellNavigationService.getRowAbove(r)};s.push(e)}if(c.length>0){const e={columns:c,startColumn:Be._.includes(c,i.startColumn)?i.startColumn:c[0],startRow:this.rowMax([et({},r),et({},o)]),endRow:this.rowMin([et({},n),et({},a)])};s.push(e)}t.before(n,a)&&s.push({columns:[...l],startColumn:i.startColumn,startRow:this.cellNavigationService.getRowBelow(n),endRow:et({},a)}),s.length-u===1&&(s[s.length-1].id=e.id)}),this.cellRanges=s,e&&this.dispatchChangedEvent(!1,!0)}rowMax(e){let t;return e.forEach(e=>{(void 0===t||this.rowPositionUtils.before(t,e))&&(t=e)}),t}rowMin(e){let t;return e.forEach(e=>{(void 0===t||this.rowPositionUtils.before(e,t))&&(t=e)}),t}updateValuesOnMove(e){const t=Be._.getCtrlForEventTarget(this.gos,e,Be.CellCtrl.DOM_DATA_KEY_CELL_CTRL),i=null==t?void 0:t.getCellPosition();this.cellHasChanged=!1,!i||this.lastCellHovered&&this.cellPositionUtils.equals(i,this.lastCellHovered)||(this.lastCellHovered&&(this.cellHasChanged=!0),this.lastCellHovered=i)}onDragging(e){if(!this.dragging||!e)return;this.updateValuesOnMove(e.target),this.lastMouseEvent=e;const t=this.lastCellHovered,i=e=>t&&t.rowPinned===e&&this.newestRangeStartCell.rowPinned===e,r=i("top")||i("bottom");if(this.autoScrollService.check(e,r),!this.cellHasChanged)return;const n=this.calculateColumnsBetween(this.newestRangeStartCell.column,t.column);n&&(this.draggingRange.endRow={rowIndex:t.rowIndex,rowPinned:t.rowPinned},this.draggingRange.columns=n,this.dispatchChangedEvent(!1,!1,this.draggingRange.id))}onDragStop(){if(!this.dragging)return;const{id:e}=this.draggingRange;this.autoScrollService.ensureCleared(),this.ctrlsService.getGridBodyCtrl().removeScrollEventListener(this.bodyScrollListener),this.lastMouseEvent=null,this.dragging=!1,this.draggingRange=void 0,this.lastCellHovered=void 0,this.intersectionRange&&(this.intersectionRange=!1,this.intersectLastRange()),this.dispatchChangedEvent(!1,!0,e)}dispatchChangedEvent(e,t,i){const r={type:Be.Events.EVENT_RANGE_SELECTION_CHANGED,started:e,finished:t,id:i};this.eventService.dispatchEvent(r)}calculateColumnsBetween(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=e===t,n=i.indexOf(e);if(n<0)return void console.warn(`AG Grid: column ${e.getId()} is not visible`);const s=r?n:i.indexOf(t);if(s<0)return void console.warn(`AG Grid: column ${t.getId()} is not visible`);if(r)return[e];const o=Math.min(n,s),a=o===n?s:n,l=[];for(let e=o;e<=a;e++)l.push(i[e]);return l}};it([(0,Be.Autowired)("rowModel")],rt.prototype,"rowModel",2),it([(0,Be.Autowired)("dragService")],rt.prototype,"dragService",2),it([(0,Be.Autowired)("columnModel")],rt.prototype,"columnModel",2),it([(0,Be.Autowired)("cellNavigationService")],rt.prototype,"cellNavigationService",2),it([(0,Be.Autowired)("pinnedRowModel")],rt.prototype,"pinnedRowModel",2),it([(0,Be.Autowired)("rowPositionUtils")],rt.prototype,"rowPositionUtils",2),it([(0,Be.Autowired)("cellPositionUtils")],rt.prototype,"cellPositionUtils",2),it([(0,Be.Autowired)("ctrlsService")],rt.prototype,"ctrlsService",2),it([(0,Be.Autowired)("valueService")],rt.prototype,"valueService",2),it([Be.PostConstruct],rt.prototype,"init",1),rt=it([(0,Be.Bean)("rangeService")],rt);var nt=class extends Ue.Component{constructor(){super(...arguments),this.changedCalculatedValues=!1,this.dragging=!1,this.shouldDestroyOnEndDragging=!1}init(){this.dragService.addDragSource({dragStartPixels:0,eElement:this.getGui(),onDragStart:this.onDragStart.bind(this),onDragging:e=>{this.dragging=!0,this.rangeService.autoScrollService.check(e),this.changedCalculatedValues&&(this.onDrag(e),this.changedCalculatedValues=!1)},onDragStop:e=>{this.dragging=!1,this.onDragEnd(e),this.clearValues(),this.rangeService.autoScrollService.ensureCleared(),document.body.classList.remove(this.getDraggingCssClass()),this.shouldDestroyOnEndDragging&&this.destroy()}}),this.addManagedListener(this.getGui(),"mousedown",this.preventRangeExtension.bind(this))}isDragging(){return this.dragging}getCellCtrl(){return this.cellCtrl}setCellCtrl(e){this.cellCtrl=e}getCellRange(){return this.cellRange}setCellRange(e){this.cellRange=e}getRangeStartRow(){return this.rangeStartRow}setRangeStartRow(e){this.rangeStartRow=e}getRangeEndRow(){return this.rangeEndRow}setRangeEndRow(e){this.rangeEndRow=e}getLastCellHovered(){return this.lastCellHovered}preventRangeExtension(e){e.stopPropagation()}onDragStart(e){this.cellHoverListener=this.addManagedListener(this.ctrlsService.get("gridCtrl").getGui(),"mousemove",this.updateValuesOnMove.bind(this)),document.body.classList.add(this.getDraggingCssClass())}getDraggingCssClass(){return`ag-dragging-${this.type===Ue.SelectionHandleType.FILL?"fill":"range"}-handle`}updateValuesOnMove(e){const t=this.mouseEventService.getCellPositionForEvent(e);!t||this.lastCellHovered&&this.cellPositionUtils.equals(t,this.lastCellHovered)||(this.lastCellHovered=t,this.changedCalculatedValues=!0)}getType(){return this.type}refresh(e){const t=this.getCellCtrl(),i=this.getGui(),r=Ue._.last(this.rangeService.getCellRanges()),n=r.startRow,s=r.endRow;if(n&&s&&(this.rowPositionUtils.before(s,n)?(this.setRangeStartRow(s),this.setRangeEndRow(n)):(this.setRangeStartRow(n),this.setRangeEndRow(s))),t!==e||!Ue._.isVisible(i)){this.setCellCtrl(e);const t=e.getComp().getParentOfValue();t&&t.appendChild(i)}this.setCellRange(r)}clearValues(){this.lastCellHovered=void 0,this.removeListeners()}removeListeners(){this.cellHoverListener&&(this.cellHoverListener(),this.cellHoverListener=void 0)}destroy(){if(!this.shouldDestroyOnEndDragging&&this.isDragging())return Ue._.setDisplayed(this.getGui(),!1),void(this.shouldDestroyOnEndDragging=!0);this.shouldDestroyOnEndDragging=!1,super.destroy(),this.removeListeners();const e=this.getGui();e.parentElement&&e.parentElement.removeChild(e)}};function st(e){const t=e.length;let i=0;if(t<=1)return e;for(let t=0;t<e.length;t++){const r=e[t],n=r.toString().split("e-");n.length>1?i=Math.max(i,parseInt(n[1],10)):Math.floor(r)!==r&&(i=Math.max(i,r.toString().split(".")[1].length))}let r=0,n=0,s=0,o=0,a=0;for(let i=0;i<t;i++)a=e[i],r+=i,n+=a,o+=i*i,s+=i*a;const l=(t*s-r*n)/(t*o-r*r),c=n/t-l*r/t,u=[];for(let e=0;e<=t;e++)u.push(parseFloat((e*l+c).toFixed(i)));return u}it([(0,Ue.Autowired)("rowRenderer")],nt.prototype,"rowRenderer",2),it([(0,Ue.Autowired)("dragService")],nt.prototype,"dragService",2),it([(0,Ue.Autowired)("rangeService")],nt.prototype,"rangeService",2),it([(0,Ue.Autowired)("mouseEventService")],nt.prototype,"mouseEventService",2),it([(0,Ue.Autowired)("columnModel")],nt.prototype,"columnModel",2),it([(0,Ue.Autowired)("cellNavigationService")],nt.prototype,"cellNavigationService",2),it([(0,Ue.Autowired)("navigationService")],nt.prototype,"navigationService",2),it([(0,Ue.Autowired)("rowPositionUtils")],nt.prototype,"rowPositionUtils",2),it([(0,Ue.Autowired)("cellPositionUtils")],nt.prototype,"cellPositionUtils",2),it([(0,Ue.Autowired)("ctrlsService")],nt.prototype,"ctrlsService",2),it([Ue.PostConstruct],nt.prototype,"init",1);var ot=class e extends nt{constructor(){super(e.TEMPLATE),this.markedCells=[],this.cellValues=[],this.isUp=!1,this.isLeft=!1,this.isReduce=!1,this.type=ze.SelectionHandleType.FILL}updateValuesOnMove(e){super.updateValuesOnMove(e),this.initialXY||(this.initialXY=this.mouseEventService.getNormalisedPosition(e));const{x:t,y:i}=this.initialXY,{x:r,y:n}=this.mouseEventService.getNormalisedPosition(e),s=Math.abs(t-r),o=Math.abs(i-n),a=this.getFillHandleDirection();let l;l="xy"===a?s>o?"x":"y":a,l!==this.dragAxis&&(this.dragAxis=l,this.changedCalculatedValues=!0)}onDrag(e){if(!this.initialPosition){const e=this.getCellCtrl();if(!e)return;this.initialPosition=e.getCellPosition()}const t=this.getLastCellHovered();t&&this.markPathFrom(this.initialPosition,t)}onDragEnd(e){if(this.initialXY=null,!this.markedCells.length)return;const t="x"===this.dragAxis,i=this.getCellRange(),r=i.columns.length,n=this.getRangeStartRow(),s=this.getRangeEndRow();let o;if(this.isUp||this.isLeft){const e=t?n:this.lastCellMarked;o=this.rangeService.createCellRangeFromCellRangeParams({rowStartIndex:e.rowIndex,rowStartPinned:e.rowPinned,columnStart:t?this.lastCellMarked.column:i.columns[0],rowEndIndex:s.rowIndex,rowEndPinned:s.rowPinned,columnEnd:i.columns[r-1]})}else o=this.rangeService.createCellRangeFromCellRangeParams({rowStartIndex:n.rowIndex,rowStartPinned:n.rowPinned,columnStart:i.columns[0],rowEndIndex:t?s.rowIndex:this.lastCellMarked.rowIndex,rowEndPinned:t?s.rowPinned:this.lastCellMarked.rowPinned,columnEnd:t?this.lastCellMarked.column:i.columns[r-1]});o&&(this.raiseFillStartEvent(),this.handleValueChanged(i,o,e),this.rangeService.setCellRanges([o]),this.raiseFillEndEvent(i,o))}getFillHandleDirection(){const e=this.gos.get("fillHandleDirection");return e?"x"!==e&&"y"!==e&&"xy"!==e?(ze._.warnOnce("valid values for fillHandleDirection are 'x', 'y' and 'xy'. Default to 'xy'."),"xy"):e:"xy"}raiseFillStartEvent(){const e={type:ze.Events.EVENT_FILL_START};this.eventService.dispatchEvent(e)}raiseFillEndEvent(e,t){const i={type:ze.Events.EVENT_FILL_END,initialRange:e,finalRange:t};this.eventService.dispatchEvent(i)}handleValueChanged(e,t,i){const r=this.rangeService.getRangeEndRow(e),n=this.rangeService.getRangeStartRow(e),s=this.rangeService.getRangeEndRow(t),o=this.rangeService.getRangeStartRow(t),a="y"===this.dragAxis;if(this.isReduce&&!this.gos.get("suppressClearOnFillReduction")){const i=a?e.columns:e.columns.filter(e=>t.columns.indexOf(e)<0),n=a?this.cellNavigationService.getRowBelow(s):o;return void(n&&this.clearCellsInRange(n,r,i))}const l=[],c=[],u=[],h=[];let d=!0,p=0;const g=()=>{l.length=0,c.length=0,u.length=0,h.length=0,p=0},f=(t,i)=>{let c=this.isUp?r:n,u=!1;for(a&&(d=!0,g());!u&&c;){const h=this.rowPositionUtils.getRowNode(c);if(!h)break;a&&t?m(l,t,h,()=>!this.rowPositionUtils.sameRow(c,this.isUp?n:r)):i&&(d=!0,g(),i.forEach(t=>m(l,t,h,()=>t!==(this.isLeft?e.columns[0]:ze._.last(e.columns))))),u=this.rowPositionUtils.sameRow(c,this.isUp?o:s),c=this.isUp?this.cellNavigationService.getRowAbove(c):this.cellNavigationService.getRowBelow(c)}},m=(e,t,r,n)=>{var s,o;let a,l=!1;if(d)a=this.valueService.getValue(t,r),c.push(a),u.push(this.valueService.getValue(t,r,void 0,!0)),h.push(this.valueService.formatValue(t,r,a)),d=n();else{const{value:n,fromUserFunction:d,sourceCol:g,sourceRowNode:f}=this.processValues({event:i,values:e,initialValues:c,initialNonAggregatedValues:u,initialFormattedValues:h,col:t,rowNode:r,idx:p++});if(a=n,t.isCellEditable(r)){const e=this.valueService.getValue(t,r);d||(g&&!1!==(null==(s=g.getColDef())?void 0:s.useValueFormatterForExport)&&(a=null!=(o=this.valueService.formatValue(g,f,a))?o:a),!1!==t.getColDef().useValueParserForImport&&(a=this.valueService.parseValue(t,r,g?a:ze._.toStringOrNull(a),e))),d&&e===a?l=!0:r.setDataValue(t,a,"rangeService")}}l||e.push({value:a,column:t,rowNode:r})};if(a)e.columns.forEach(e=>{f(e)});else{const e=this.isLeft?[...t.columns].reverse():t.columns;f(void 0,e)}}clearCellsInRange(e,t,i){const r={startRow:e,endRow:t,columns:i,startColumn:i[0]};this.rangeService.clearCellRangeCellValues({cellRanges:[r]})}processValues(e){const{event:t,values:i,initialValues:r,initialNonAggregatedValues:n,initialFormattedValues:s,col:o,rowNode:a,idx:l}=e,c=this.gos.getCallback("fillOperation");let u;if(u="y"===this.dragAxis?this.isUp?"up":"down":this.isLeft?"left":"right",c){const e=c({event:t,values:i.map(({value:e})=>e),initialValues:r,initialNonAggregatedValues:n,initialFormattedValues:s,currentIndex:l,currentCellValue:this.valueService.getValue(o,a),direction:u,column:o,rowNode:a});if(!1!==e)return{value:e,fromUserFunction:!0}}const h=!i.some(({value:e})=>{const t=parseFloat(e);return isNaN(t)||t.toString()!==e.toString()});if(t.altKey||!h){if(h&&1===r.length){const e=this.isUp||this.isLeft?-1:1;return{value:parseFloat(ze._.last(i).value)+1*e,fromUserFunction:!1}}const{value:e,column:t,rowNode:n}=i[l%i.length];return{value:e,fromUserFunction:!1,sourceCol:t,sourceRowNode:n}}return{value:ze._.last(st(i.map(({value:e})=>Number(e)))),fromUserFunction:!1}}clearValues(){this.clearMarkedPath(),this.clearCellValues(),this.lastCellMarked=void 0,super.clearValues()}clearMarkedPath(){this.markedCells.forEach(e=>{if(!e.isAlive())return;const t=e.getComp();t.addOrRemoveCssClass("ag-selection-fill-top",!1),t.addOrRemoveCssClass("ag-selection-fill-right",!1),t.addOrRemoveCssClass("ag-selection-fill-bottom",!1),t.addOrRemoveCssClass("ag-selection-fill-left",!1)}),this.markedCells.length=0,this.isUp=!1,this.isLeft=!1,this.isReduce=!1}clearCellValues(){this.cellValues.length=0}markPathFrom(e,t){if(this.clearMarkedPath(),this.clearCellValues(),"y"===this.dragAxis){if(this.rowPositionUtils.sameRow(t,e))return;const i=this.rowPositionUtils.before(t,e),r=this.getRangeStartRow(),n=this.getRangeEndRow();i&&(t.rowPinned==r.rowPinned&&t.rowIndex>=r.rowIndex||r.rowPinned!=n.rowPinned&&t.rowPinned==n.rowPinned&&t.rowIndex<=n.rowIndex)?(this.reduceVertical(e,t),this.isReduce=!0):(this.extendVertical(e,t,i),this.isReduce=!1)}else{const i=e.column,r=t.column;if(i===r)return;const n=this.columnModel.getAllDisplayedColumns(),s=n.indexOf(i),o=n.indexOf(r);o<=s&&o>=n.indexOf(this.getCellRange().columns[0])?(this.reduceHorizontal(e,t),this.isReduce=!0):(this.extendHorizontal(e,t,o<s),this.isReduce=!1)}this.lastCellMarked=t}extendVertical(e,t,i){const{navigationService:r,rangeService:n}=this;let s=e;do{const o=this.getCellRange(),a=o.columns.length;for(let l=0;l<a;l++){const c=o.columns[l],u={rowIndex:s.rowIndex,rowPinned:s.rowPinned},h=tt(et({},u),{column:c}),d=n.isCellInSpecificRange(h,o),p=this.rowPositionUtils.sameRow(s,e);if(i&&(this.isUp=!0),!p){const e=r.getCellByPosition(h);if(e){this.markedCells.push(e);const r=e.getComp();d||(r.addOrRemoveCssClass("ag-selection-fill-left",0===l),r.addOrRemoveCssClass("ag-selection-fill-right",l===a-1)),r.addOrRemoveCssClass(i?"ag-selection-fill-top":"ag-selection-fill-bottom",this.rowPositionUtils.sameRow(s,t))}}}if(this.rowPositionUtils.sameRow(s,t))break}while(s=i?this.cellNavigationService.getRowAbove(s):this.cellNavigationService.getRowBelow(s))}reduceVertical(e,t){let i=e;do{const e=this.getCellRange(),r=e.columns.length,n=this.rowPositionUtils.sameRow(i,t);for(let n=0;n<r;n++){const r={rowIndex:i.rowIndex,rowPinned:i.rowPinned},s=tt(et({},r),{column:e.columns[n]}),o=this.navigationService.getCellByPosition(s);o&&(this.markedCells.push(o),o.getComp().addOrRemoveCssClass("ag-selection-fill-bottom",this.rowPositionUtils.sameRow(i,t)))}if(n)break}while(i=this.cellNavigationService.getRowAbove(i))}extendHorizontal(e,t,i){const r=this.columnModel.getAllDisplayedColumns(),n=r.indexOf(i?t.column:e.column),s=r.indexOf(i?this.getCellRange().columns[0]:t.column),o=i?0:1,a=r.slice(n+o,s+o),l=this.getRangeStartRow(),c=this.getRangeEndRow();a.forEach(e=>{let t=l,r=!1;do{r=this.rowPositionUtils.sameRow(t,c);const n=this.navigationService.getCellByPosition({rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:e});if(n){this.markedCells.push(n);const r=n.getComp();r.addOrRemoveCssClass("ag-selection-fill-top",this.rowPositionUtils.sameRow(t,l)),r.addOrRemoveCssClass("ag-selection-fill-bottom",this.rowPositionUtils.sameRow(t,c)),i?(this.isLeft=!0,r.addOrRemoveCssClass("ag-selection-fill-left",e===a[0])):r.addOrRemoveCssClass("ag-selection-fill-right",e===ze._.last(a))}t=this.cellNavigationService.getRowBelow(t)}while(!r)})}reduceHorizontal(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=i.indexOf(t.column),n=i.indexOf(e.column),s=i.slice(r,n),o=this.getRangeStartRow(),a=this.getRangeEndRow();s.forEach(e=>{let t=o,i=!1;do{i=this.rowPositionUtils.sameRow(t,a);const r=this.navigationService.getCellByPosition({rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:e});r&&(this.markedCells.push(r),r.getComp().addOrRemoveCssClass("ag-selection-fill-right",e===s[0])),t=this.cellNavigationService.getRowBelow(t)}while(!i)})}refresh(e){const t=this.rangeService.getCellRanges()[0];t.startRow&&t.endRow?super.refresh(e):this.destroy()}};ot.TEMPLATE='<div class="ag-fill-handle"></div>',it([(0,ze.Autowired)("valueService")],ot.prototype,"valueService",2);var at=ot,lt=class e extends nt{constructor(){super(e.TEMPLATE),this.type=We.SelectionHandleType.RANGE,this.rangeFixed=!1}onDrag(e){const t=this.getLastCellHovered();if(!t)return;const i=this.rangeService.getCellRanges(),r=We._.last(i);this.rangeFixed||(this.fixRangeStartEnd(r),this.rangeFixed=!0),this.endPosition={rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:t.column},2===i.length&&i[0].type===We.CellRangeType.DIMENSION&&r.type===We.CellRangeType.VALUE&&!this.rowPositionUtils.sameRow(this.endPosition,this.rangeService.getRangeEndRow(r))&&this.rangeService.updateRangeEnd(i[0],tt(et({},this.endPosition),{column:i[0].columns[0]}),!0),this.rangeService.extendLatestRangeToCell(this.endPosition)}onDragEnd(e){const t=We._.last(this.rangeService.getCellRanges());this.fixRangeStartEnd(t),this.rangeFixed=!1}fixRangeStartEnd(e){const t=this.rangeService.getRangeStartRow(e),i=this.rangeService.getRangeEndRow(e),r=e.columns[0];e.startRow=t,e.endRow=i,e.startColumn=r}};lt.TEMPLATE='<div class="ag-range-handle"></div>';var ct=lt,ut=class extends je.BeanStub{createSelectionHandle(e){return this.createBean(e===je.SelectionHandleType.RANGE?new ct:new at)}};ut=it([(0,je.Bean)("selectionHandleFactory")],ut);var ht={version:"31.3.4",moduleName:He.ModuleNames.RangeSelectionModule,beans:[rt,ut],agStackComponents:[{componentName:"AgFillHandle",componentClass:at},{componentName:"AgRangeHandle",componentClass:ct}],dependantModules:[_]},dt=i(98092),pt=i(21371),gt=i(98092),ft=i(98092),mt=i(98092),vt=i(98092),Ct=i(98092),yt=i(98092),wt=i(98092),St=i(98092),bt=i(98092),Et=i(98092),At=i(21371),Tt=i(98092),Mt=i(21371),Rt=i(98092),_t=i(21371),Pt=i(98092),xt=i(98092),Dt=i(98092),It=i(98092),Lt=i(98092),Nt=i(98092),Ot=i(98092),Ft=i(98092),kt=i(98092),Gt=i(98092),Vt=i(98092),Ht=i(98092),Bt=i(98092),zt=i(98092),Ut=i(98092),Wt=i(98092),jt=i(98092),Kt=i(98092),$t=i(98092),qt=i(98092),Yt=i(98092),Qt=i(98092),Xt=i(98092),Zt=i(21371),Jt=i(98092),ei=i(98092),ti=i(98092),ii=i(98092),ri=i(98092),ni=i(98092),si=i(98092),oi=i(98092),ai=i(98092),li=i(98092),ci=i(98092),ui=i(98092),hi=i(98092),di=i(98092),pi=i(21371),gi=i(21371),fi=i(21371),mi=i(21371),vi=i(21371),Ci=i(21371),yi=i(21371),wi=i(21371),Si=i(21371),bi=i(21371),Ei=i(21371),Ai=i(21371),Ti=i(98092),Mi=i(21371),Ri=i(21371),_i=i(21371),Pi=i(21371),xi=i(21371),Di=i(21371),Ii=i(21371),Li=i(21371),Ni=i(21371),Oi=i(21371),Fi=i(21371),ki=i(21371),Gi=i(98092),Vi=i(98092),Hi=i(98092),Bi=i(21371),zi=i(21371),Ui=i(98092),Wi=i(21371),ji=i(98092),Ki=i(98092),$i=i(98092),qi=i(98092),Yi=i(98092),Qi=i(98092),Xi=i(98092),Zi=i(98092),Ji=i(98092),er=i(98092),tr=i(98092),ir=i(21371);u(Ge,i(21371));var rr=Object.defineProperty,nr=Object.defineProperties,sr=Object.getOwnPropertyDescriptor,or=Object.getOwnPropertyDescriptors,ar=Object.getOwnPropertySymbols,lr=Object.prototype.hasOwnProperty,cr=Object.prototype.propertyIsEnumerable,ur=(e,t,i)=>t in e?rr(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,hr=(e,t)=>{for(var i in t||(t={}))lr.call(t,i)&&ur(e,i,t[i]);if(ar)for(var i of ar(t))cr.call(t,i)&&ur(e,i,t[i]);return e},dr=(e,t)=>nr(e,or(t)),pr=(e,t)=>{var i={};for(var r in e)lr.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&ar)for(var r of ar(e))t.indexOf(r)<0&&cr.call(e,r)&&(i[r]=e[r]);return i},gr=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?sr(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&rr(t,i,s),s},fr=class e extends wt.BeanStub{getData(e){if(e.crossFiltering){if(e.grouping)return console.warn("AG Grid: crossing filtering with row grouping is not supported."),{chartData:[],columnNames:{}};if(!this.gos.isRowModelType("clientSide"))return console.warn("AG Grid: crossing filtering is only supported in the client side row model."),{chartData:[],columnNames:{}}}this.gos.isRowModelType("serverSide")&&e.pivoting&&this.updatePivotKeysForSSRM();const t=this.extractRowsFromGridRowModel(e);return t.chartData=this.aggregateRowsByDimension(e,t.chartData),t}extractRowsFromGridRowModel(t){const{crossFiltering:i,startRow:r,endRow:n,valueCols:s,dimensionCols:o,grouping:a}=t;let l=[];const c={},u={},h={};let d,p={},g=[];if(i)p=this.getFilteredRowNodes(),g=this.getAllRowNodes(),d=g.length;else{const e=this.gridRowModel.getRowCount()-1;d=r===n&&0===r&&0===o.length&&0===s.length?0:(n>=0?Math.min(n,e):e)-r+1}d>0&&s.forEach(e=>{let t=[];const i=e.getColDef().pivotKeys;i&&(t=i.slice());const r=e.getColDef().headerName;r&&t.push(r),t.length>0&&(c[e.getId()]=t)});let f,m=0;for(let n=0;n<d;n++){const c=i?g[n]:this.gridRowModel.getRow(n+r);if(c.footer){m++;continue}const d={};o.forEach(t=>{const i=t.colId,r=this.columnModel.getGridColumn(i);if(r){const t=this.valueService.getValue(r,c);if(a){const r=t&&t.toString?String(t.toString()):"",s=e.getGroupLabels(c,r);d[i]={labels:s,toString:function(){return this.labels.filter(e=>!!e).reverse().join(" - ")}},c.group&&(u[s.toString()]=n-m);const o=s.slice(1,s.length).toString();o&&(h[o]=u[o])}else d[i]=t}else d[Or.DEFAULT_CATEGORY]=n+1}),s.forEach(e=>{const r=e.getColId();if(i){const i=r+"-filtered-out",n=this.valueService.getValue(e,c),s=null!=n&&"function"==typeof n.toNumber?n.toNumber():n;p[c.id]?(d[r]=s,d[i]=t.aggFunc||t.isScatter?void 0:0):(d[r]=t.aggFunc||t.isScatter?void 0:0,d[i]=s)}else{let t=this.valueService.getValue(e,c);t&&t.hasOwnProperty("toString")&&(t=parseFloat(t.toString())),d[r]=null!=t&&"function"==typeof t.toNumber?t.toNumber():t}}),l.push(d)}if(a){const e=wt._.values(h),t=l;l=[],f=[];for(let i=0;i<t.length;i++)(wt._.includes(e,i)?f:l).push(t[i])}return{chartData:l,columnNames:c,groupChartData:f}}aggregateRowsByDimension(e,t){const i=e.dimensionCols;if(!e.aggFunc||0===i.length)return t;const r=wt._.last(i),n=r&&r.colId,s={},o=[];if(t.forEach(e=>{let t=s;i.forEach(r=>{const s=r.colId,a=e[s];if(s===n){let r=t[a];r||(r={__children:[]},i.forEach(t=>{const i=t.colId;r[i]=e[i]}),t[a]=r,o.push(r)),r.__children.push(e)}else t[a]||(t[a]={}),t=t[a]})}),wt.ModuleRegistry.__assertRegistered(wt.ModuleNames.RowGroupingModule,"Charting Aggregation",this.context.getGridId())){const t=this.aggregationStage;o.forEach(i=>e.valueCols.forEach(r=>{if(e.crossFiltering)e.valueCols.forEach(r=>{const n=r.getColId(),s=i.__children.filter(e=>void 0!==e[n]).map(e=>e[n]);let o=t.aggregateValues(s,e.aggFunc);i[r.getId()]=o&&void 0!==o.value?o.value:o;const a=`${n}-filtered-out`,l=i.__children.filter(e=>void 0!==e[a]).map(e=>e[a]);let c=t.aggregateValues(l,e.aggFunc);i[a]=c&&void 0!==c.value?c.value:c});else{const n=i.__children.map(e=>e[r.getId()]);let s=t.aggregateValues(n,e.aggFunc);i[r.getId()]=s&&void 0!==s.value?s.value:s}}))}return o}updatePivotKeysForSSRM(){const e=this.columnModel.getSecondaryColumns();if(!e)return;const t=this.extractPivotKeySeparator(e);e.forEach(e=>{if(""===t)e.getColDef().pivotKeys=[];else{const i=e.getColId().split(t);e.getColDef().pivotKeys=i.slice(0,i.length-1)}})}extractPivotKeySeparator(e){if(0===e.length)return"";const t=(e,i)=>{const r=e.getGroupId();return e.getParent()?t(e.getParent(),r):i.split(r)[1][0]},i=e[0];return null==i.getParent()?"":t(i.getParent(),i.getColId())}static getGroupLabels(e,t){const i=[t];for(;e&&0!==e.level;)(e=e.parent)&&i.push(e.key);return i}getFilteredRowNodes(){const e={};return this.gridRowModel.forEachNodeAfterFilterAndSort(t=>{e[t.id]=t}),e}getAllRowNodes(){let e=[];return this.gridRowModel.forEachNode(t=>{e.push(t)}),this.sortRowNodes(e)}sortRowNodes(e){const t=this.sortController.getSortOptions();return t&&0!=t.length?this.rowNodeSorter.doFullSort(e,t):e}};gr([(0,wt.Autowired)("rowModel")],fr.prototype,"gridRowModel",2),gr([(0,wt.Autowired)("valueService")],fr.prototype,"valueService",2),gr([(0,wt.Autowired)("columnModel")],fr.prototype,"columnModel",2),gr([(0,wt.Autowired)("rowNodeSorter")],fr.prototype,"rowNodeSorter",2),gr([(0,wt.Autowired)("sortController")],fr.prototype,"sortController",2),gr([(0,wt.Optional)("aggregationStage")],fr.prototype,"aggregationStage",2);var mr=fr,vr=class extends St.BeanStub{constructor(){super(...arguments),this.valueColsWithoutSeriesType=new Set}postConstruct(){const e=()=>this.valueColsWithoutSeriesType.clear();this.addManagedListener(this.eventService,St.Events.EVENT_NEW_COLUMNS_LOADED,e),this.addManagedListener(this.eventService,St.Events.EVENT_ROW_DATA_UPDATED,e)}getColumn(e){return this.columnModel.getPrimaryColumn(e)}getAllDisplayedColumns(){return this.columnModel.getAllDisplayedColumns()}getColDisplayName(e){return this.columnModel.getDisplayNameForColumn(e,"chart")}getRowGroupColumns(){return this.columnModel.getRowGroupColumns()}getGroupDisplayColumns(){return this.columnModel.getGroupDisplayColumns()}isPivotMode(){return this.columnModel.isPivotMode()}isPivotActive(){return this.columnModel.isPivotActive()}getChartColumns(){const e=this.columnModel.getAllGridColumns(),t=new Set,i=new Set;return e.forEach(e=>{const r=e.getColDef(),n=r.chartDataType;if(n)switch(n){case"category":case"time":return void t.add(e);case"series":return void i.add(e);case"excluded":return;default:console.warn(`AG Grid: unexpected chartDataType value '${n}' supplied, instead use 'category', 'series' or 'excluded'`)}"ag-Grid-AutoColumn"!==r.colId?e.isPrimary()?(this.isInferredValueCol(e)?i:t).add(e):i.add(e):t.add(e)}),{dimensionCols:t,valueCols:i}}isInferredValueCol(e){const t=e.getColId();if("ag-Grid-AutoColumn"===t)return!1;const i=this.rowPositionUtils.getRowNode({rowIndex:0,rowPinned:null});if(!i)return this.valueColsWithoutSeriesType.has(t);let r=this.valueService.getValue(e,i);null==r&&(r=this.extractLeafData(i,e)),null!=r&&"function"==typeof r.toNumber&&(r=r.toNumber());const n="number"==typeof r;return n&&this.valueColsWithoutSeriesType.add(t),n}extractLeafData(e,t){if(!e.allLeafChildren)return null;for(let i=0;i<e.allLeafChildren.length;i++){const r=e.allLeafChildren[i],n=this.valueService.getValue(t,r);if(null!=n)return n}return null}destroy(){this.valueColsWithoutSeriesType.clear(),super.destroy()}};gr([(0,St.Autowired)("columnModel")],vr.prototype,"columnModel",2),gr([(0,St.Autowired)("valueService")],vr.prototype,"valueService",2),gr([(0,St.Autowired)("rowPositionUtils")],vr.prototype,"rowPositionUtils",2),gr([St.PostConstruct],vr.prototype,"postConstruct",1),vr=gr([(0,St.Bean)("chartColumnService")],vr);var Cr=class e extends bt.BeanStub{constructor(e){var t;super(),this.suppressComboChartWarnings=!1,this.chartDataModel=e,this.seriesChartTypes=null!=(t=e.params.seriesChartTypes)?t:[]}init(){this.initComboCharts()}update(e){this.seriesChartTypes=null!=e?e:this.seriesChartTypes,this.initComboCharts(),this.updateSeriesChartTypes()}initComboCharts(){const e=this.seriesChartTypes&&this.seriesChartTypes.length>0;("customCombo"===this.chartDataModel.chartType||e)&&(this.chartDataModel.chartType="customCombo",this.savedCustomSeriesChartTypes=this.seriesChartTypes||[])}updateSeriesChartTypes(){this.chartDataModel.isComboChart()&&(this.seriesChartTypes=this.seriesChartTypes.map(e=>{const t=["groupedColumn","stackedColumn","stackedArea"].includes(e.chartType);return e.secondaryAxis=!t&&e.secondaryAxis,e}),"customCombo"!==this.chartDataModel.chartType?this.updateChartSeriesTypesForBuiltInCombos():this.updateSeriesChartTypesForCustomCombo())}updateSeriesChartTypesForCustomCombo(){this.seriesChartTypes&&this.seriesChartTypes.length>0||this.suppressComboChartWarnings||console.warn("AG Grid: 'seriesChartTypes' are required when the 'customCombo' chart type is specified."),this.seriesChartTypes=this.seriesChartTypes.map(t=>(e.SUPPORTED_COMBO_CHART_TYPES.includes(t.chartType)||(console.warn(`AG Grid: invalid chartType '${t.chartType}' supplied in 'seriesChartTypes', converting to 'line' instead.`),t.chartType="line"),t));const t=this.chartDataModel.valueColState.map(e=>{this.savedCustomSeriesChartTypes&&0!==this.savedCustomSeriesChartTypes.length||(this.savedCustomSeriesChartTypes=this.seriesChartTypes);return this.savedCustomSeriesChartTypes.find(t=>t.colId===e.colId)||(e.selected&&!this.suppressComboChartWarnings&&console.warn(`AG Grid: no 'seriesChartType' found for colId = '${e.colId}', defaulting to 'line'.`),{colId:e.colId,chartType:"line",secondaryAxis:!1})});this.seriesChartTypes=t,this.savedCustomSeriesChartTypes=t,this.suppressComboChartWarnings=!0}updateChartSeriesTypesForBuiltInCombos(){const{chartType:e,valueColState:t}=this.chartDataModel;let i="columnLineCombo"===e?"groupedColumn":"stackedArea",r="columnLineCombo"===e?"line":"groupedColumn";const n=t.filter(e=>e.selected),s=Math.ceil(n.length/2);this.seriesChartTypes=n.map((e,t)=>{const n=t>=s?r:i;return{colId:e.colId,chartType:n,secondaryAxis:!1}})}};Cr.SUPPORTED_COMBO_CHART_TYPES=["line","groupedColumn","stackedColumn","area","stackedArea"],gr([bt.PostConstruct],Cr.prototype,"init",1);var yr=Cr,wr={area:{isCartesian:!0,canInvert:!0},bar:{isCartesian:!0,canInvert:!0},histogram:{isCartesian:!0},line:{isCartesian:!0,canInvert:!0},pie:{isPie:!0},donut:{isPie:!0,canInvert:!0},scatter:{isCartesian:!0},bubble:{isCartesian:!0},"radial-column":{isPolar:!0,isEnterprise:!0,isRadial:!0,canInvert:!0},"radial-bar":{isPolar:!0,isEnterprise:!0,isRadial:!0,canInvert:!0},"radar-line":{isPolar:!0,isEnterprise:!0,canInvert:!0},"radar-area":{isPolar:!0,isEnterprise:!0,canInvert:!0},nightingale:{isPolar:!0,isEnterprise:!0,canInvert:!0},"range-bar":{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0},"range-area":{isCartesian:!0,isEnterprise:!0},"box-plot":{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0},treemap:{isEnterprise:!0,isHierarchical:!0},sunburst:{isEnterprise:!0,isHierarchical:!0},heatmap:{isCartesian:!0,isEnterprise:!0},waterfall:{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0}};function Sr(e){return Et.ChartMappings.COMBO_CHART_TYPES.includes(e)}function br(e,t){var i;return!!(null==(i=wr[e])?void 0:i[t])}var Er=new Set(["stackedColumn","normalizedColumn","stackedBar","normalizedBar"]);function Ar(e){return br(e,"isCartesian")}function Tr(e){return br(e,"isPolar")}function Mr(e){return br(e,"isHierarchical")}function Rr(e){return"doughnut"===e?"donut":e}function _r(e){return Et.ChartMappings.CHART_TYPE_TO_SERIES_TYPE[e]}function Pr(e){var t;return null!=(t=_r(e))?t:"line"}function xr(e){return br(e,"isPie")}function Dr(e){return Mr(Pr(e))?void 0:1}function Ir(e){return Mr(Pr(e))?2:function(e){return"pie"===e||"waterfall"===e||"histogram"===e}(e)?1:void 0}function Lr(e){return br(Pr(e),"canInvert")}var Nr=class e extends yt.BeanStub{constructor(e){super(),this.unlinked=!1,this.chartData=[],this.valueColState=[],this.dimensionColState=[],this.columnNames={},this.crossFiltering=!1,this.grouping=!1,this.params=e,this.chartId=e.chartId,this.setParams(e)}setParams(e){const{chartType:t,pivotChart:i,chartThemeName:r,switchCategorySeries:n,aggFunc:s,cellRange:o,suppressChartRanges:a,unlinkChart:l,crossFiltering:c,seriesGroupType:u}=e;this.chartType=t,this.pivotChart=null!=i&&i,this.chartThemeName=r,this.switchCategorySeries=!!n,this.aggFunc=s,this.referenceCellRange=o,this.suppliedCellRange=o,this.suppressChartRanges=null!=a&&a,this.unlinked=!!l,this.crossFiltering=!!c,this.seriesGroupType=u}init(){this.datasource=this.createManagedBean(new mr),this.chartColumnService=this.createManagedBean(new vr),this.comboChartModel=this.createManagedBean(new yr(this)),this.updateCellRanges({setColsFromRange:!0}),this.updateData()}updateModel(e){const{cellRange:t,seriesChartTypes:i}=e;t!==this.suppliedCellRange&&(this.dimensionCellRange=void 0,this.valueCellRange=void 0),this.setParams(e),this.updateSelectedDimensions(null==t?void 0:t.columns),this.updateCellRanges({setColsFromRange:!0}),(this.isComboChart()||i)&&this.comboChartModel.update(i),this.unlinked||this.updateData()}updateCellRanges(e){const{updatedColState:t,resetOrder:i,maintainColState:r,setColsFromRange:n}=null!=e?e:{};this.valueCellRange&&(this.referenceCellRange=this.valueCellRange);const{dimensionCols:s,valueCols:o}=this.chartColumnService.getChartColumns(),a=this.getAllColumnsFromRanges();t&&this.updateColumnState(t,i),this.setDimensionCellRange(s,a,t),this.setValueCellRange(o,a,n),t||r||(this.resetColumnState(),this.syncDimensionCellRange()),this.comboChartModel.updateSeriesChartTypes()}updateData(){const{startRow:e,endRow:t}=this.getRowIndexes();this.pivotChart&&this.resetColumnState(),this.grouping=this.isGrouping();const i={aggFunc:this.aggFunc,dimensionCols:this.getSelectedDimensions(),grouping:this.grouping,pivoting:this.isPivotActive(),crossFiltering:this.crossFiltering,valueCols:this.getSelectedValueCols(),startRow:e,endRow:t,isScatter:yt._.includes(["scatter","bubble"],this.chartType)},{chartData:r,columnNames:n,groupChartData:s}=this.datasource.getData(i);this.chartData=r,this.groupChartData=s,this.columnNames=n,this.categoryAxisType=void 0}isGrouping(){const e=this.gos.get("treeData"),t=e?null:this.chartColumnService.getRowGroupColumns(),i=e||t&&t.length>0,r=this.getSelectedDimensions().map(({colId:e})=>e),n=this.chartColumnService.getGroupDisplayColumns().map(e=>e.getColId()).some(e=>r.includes(e));return!!i&&n}getSelectedValueCols(){return this.valueColState.filter(e=>e.selected).map(e=>e.column)}getSelectedDimensions(){return this.dimensionColState.filter(e=>e.selected)}getColDisplayName(e){return this.chartColumnService.getColDisplayName(e)}isPivotMode(){return this.chartColumnService.isPivotMode()}getChartDataType(e){const t=this.chartColumnService.getColumn(e);return t?t.getColDef().chartDataType:void 0}isPivotActive(){return this.chartColumnService.isPivotActive()}createCellRange(e,...t){return{id:this.chartId,startRow:this.referenceCellRange.startRow,endRow:this.referenceCellRange.endRow,columns:t,startColumn:e===yt.CellRangeType.DIMENSION||null==this.referenceCellRange.startColumn?t[0]:this.referenceCellRange.startColumn,type:e}}getAllColumnsFromRanges(){if(this.pivotChart)return yt._.convertToSet(this.chartColumnService.getAllDisplayedColumns());const e=this.dimensionCellRange||this.valueCellRange?[]:this.referenceCellRange.columns;return this.dimensionCellRange&&e.push(...this.dimensionCellRange.columns),this.valueCellRange&&e.push(...this.valueCellRange.columns),yt._.convertToSet(e)}getRowIndexes(){let e=0,t=0;const{rangeService:i,valueCellRange:r,dimensionCellRange:n}=this,s=r||n;if(i&&s){e=i.getRangeStartRow(s).rowIndex;const r=i.getRangeEndRow(s);t="bottom"===r.rowPinned?-1:r.rowIndex}return{startRow:e,endRow:t}}resetColumnState(){const{dimensionCols:t,valueCols:i}=this.chartColumnService.getChartColumns(),r=this.getAllColumnsFromRanges(),n=this.valueColState.length<1;this.dimensionColState=[],this.valueColState=[];const s=Mr(Pr(this.chartType));let o=!1,a=1;const l=this.suppliedCellRange.columns[0];t.forEach(e=>{const t="ag-Grid-AutoColumn"===e.getColId();let i=!1;this.crossFiltering&&this.aggFunc?l.getColId()===e.getColId()&&(i=!0):i=!!t||(!o||s)&&r.has(e),this.dimensionColState.push({column:e,colId:e.getColId(),displayName:this.getColDisplayName(e),selected:i,order:a++}),i&&(o=!0)});const c={colId:e.DEFAULT_CATEGORY,displayName:this.chartTranslationService.translate("defaultCategory"),selected:!o,order:0};this.dimensionColState.unshift(c);const u=this.referenceCellRange.columns.filter(e=>i.has(e));i.forEach(e=>{n&&yt._.includes(this.referenceCellRange.columns,e)&&(e=u.shift()),this.valueColState.push({column:e,colId:e.getColId(),displayName:this.getColDisplayName(e),selected:r.has(e),order:a++})})}updateColumnState(e,t){const i=t=>t.colId===e.colId,{dimensionColState:r,valueColState:n}=this,s=r.find(i),o=n.find(i);if(s)if(Mr(Pr(this.chartType)))s.selected=e.selected;else{const t=e.selected?s:r.filter(e=>e!==s).find(({selected:e})=>e);r.forEach(e=>e.selected=e===t)}else o&&(o.selected=e.selected);const a=[...r,...n],l=[];t||(a.forEach((t,i)=>{i===e.order&&l.push(e.colId),t.colId!==e.colId&&l.push(t.colId)}),a.forEach(e=>{const t=l.indexOf(e.colId);e.order=t>=0?l.indexOf(e.colId):a.length-1})),this.reorderColState()}reorderColState(){const e=(e,t)=>e.order-t.order;this.dimensionColState.sort(e),this.valueColState.sort(e)}setDimensionCellRange(t,i,r){this.dimensionCellRange=void 0;const n=Mr(Pr(this.chartType));if(!r&&!this.dimensionColState.length){const e=new Array;return t.forEach(t=>{e.length>0&&!n||!i.has(t)||e.push(t)}),void(e.length>0&&(this.dimensionCellRange=this.createCellRange(yt.CellRangeType.DIMENSION,...e)))}let s=r?[r]:[];if(this.crossFiltering&&this.aggFunc){const e=this.suppliedCellRange.columns[0];s=this.dimensionColState.filter(t=>t.colId===e.getColId())}else(n||0===s.length||s.some(({column:e})=>!e||!t.has(e)))&&(s=this.dimensionColState.filter(e=>e.selected));const o=1===s.length&&s[0].colId===e.DEFAULT_CATEGORY,a=s.map(({column:e})=>e).filter(e=>null!=e);a.length>0&&!o&&(this.dimensionCellRange=this.createCellRange(yt.CellRangeType.DIMENSION,...a))}setValueCellRange(e,t,i){this.valueCellRange=void 0;const r=[],n=Ir(this.chartType);let s=0;if(e.forEach(e=>{i?(null==n||s<n)&&t.has(e)&&(r.push(e),s++):this.valueColState.some(t=>t.selected&&t.colId===e.getColId())&&r.push(e)}),r.length>0){let e=[];this.valueColState.length>0?e=this.valueColState.map(e=>e.colId):t.forEach(t=>e.push(t.getColId())),r.sort((t,i)=>e.indexOf(t.getColId())-e.indexOf(i.getColId())),this.valueCellRange=this.createCellRange(yt.CellRangeType.VALUE,...r)}}resetCellRanges(e,t){if(!e&&!t)return;const{dimensionCols:i,valueCols:r}=this.chartColumnService.getChartColumns(),n=this.getAllColumnsFromRanges();e&&this.setDimensionCellRange(i,n),t&&this.setValueCellRange(r,n)}updateSelectedDimensions(e){const t=new Set(e.map(e=>e.getColId()));if(Mr(Pr(this.chartType))){const e=this.dimensionColState.filter(e=>t.has(e.colId)),i=new Set(e.map(e=>e.colId));this.dimensionColState=this.dimensionColState.map(e=>dr(hr({},e),{selected:i.has(e.colId)}))}else{const e=(this.dimensionColState.find(e=>t.has(e.colId))||this.dimensionColState[0]).colId;this.dimensionColState=this.dimensionColState.map(t=>dr(hr({},t),{selected:t.colId===e}))}}syncDimensionCellRange(){const e=this.getSelectedDimensions();if(0===e.length)return;const t=e.map(({column:e})=>e).filter(e=>null!=e);t.length>0&&(this.dimensionCellRange=this.createCellRange(yt.CellRangeType.DIMENSION,...t))}isComboChart(e){return Sr(null!=e?e:this.chartType)}};Nr.DEFAULT_CATEGORY="AG-GRID-DEFAULT-CATEGORY",gr([(0,yt.Autowired)("rangeService")],Nr.prototype,"rangeService",2),gr([(0,yt.Autowired)("chartTranslationService")],Nr.prototype,"chartTranslationService",2),gr([yt.PostConstruct],Nr.prototype,"init",1);var Or=Nr,Fr=["number","category","grouped-category","log","time"];function kr(e,t){return!1!==t.clone&&t.isMergeableObject(e)?zr(function(e){return Array.isArray(e)?[]:{}}(e),e,t):e}function Gr(e,t,i){return e.concat(t).map(function(e){return kr(e,i)})}function Vr(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return e.propertyIsEnumerable(t)}):[]}(e))}function Hr(e,t){try{return t in e}catch(e){return!1}}function Br(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){const t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t}(e)}function zr(e,t,i){(i=i||{}).arrayMerge=i.arrayMerge||Gr,i.isMergeableObject=i.isMergeableObject||Br,i.cloneUnlessOtherwiseSpecified=kr;const r=Array.isArray(t);return r===Array.isArray(e)?r?i.arrayMerge(e,t,i):function(e={},t={},i){const r={};return i.isMergeableObject(e)&&Vr(e).forEach(function(t){r[t]=kr(e[t],i)}),Vr(t).forEach(function(n){(function(e,t){return Hr(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,n)||(Hr(e,n)&&i.isMergeableObject(t[n])?r[n]=function(e,t){if(!t.customMerge)return zr;const i=t.customMerge(e);return"function"==typeof i?i:zr}(n,i)(e[n],t[n],i):r[n]=kr(t[n],i))}),r}(e,t,i):kr(t,i)}function Ur(e,t,i){if(null==e)return i;const r=t.split(".");let n=e;for(;r.length>1;)if(n=n[r.shift()],null==n)return i;const s=n[r[0]];return null!=s?s:i}function Wr(e){return Tt._.includes(Object.keys(Mt._Theme.themes),e)}var jr=Fr.reduce((e,t)=>dr(hr({},e),{[t]:{title:{_enabledFromTheme:!0}}}),{});function Kr(e,t,i){const r=e.getExtraPaddingDirections();return{common:dr(hr({},t?{animation:{duration:500}}:void 0),{axes:jr,padding:{top:!i&&r.includes("top")?40:20,right:r.includes("right")?30:20,bottom:r.includes("bottom")?40:20,left:r.includes("left")?30:20}}),pie:{series:{title:{_enabledFromTheme:!0},calloutLabel:{_enabledFromTheme:!0},sectorLabel:{enabled:!1,_enabledFromTheme:!0}}},donut:{series:{title:{_enabledFromTheme:!0},calloutLabel:{_enabledFromTheme:!0},sectorLabel:{enabled:!1,_enabledFromTheme:!0}}}}}function $r(e,t){const{customChartThemes:i}=e,r=i&&i[t];return r||console.warn(`AG Grid: no stock theme exists with the name '${t}' and no custom chart theme with that name was supplied to 'customChartThemes'`),r}var qr=e=>t=>null==t||e(t),Yr=e=>"string"==typeof e,Qr=e=>"boolean"==typeof e,Xr=e=>"object"==typeof e,Zr=(e,t)=>i=>`AG Grid - unable to update chart as invalid params supplied:  \`${e}: ${i}\`, expected ${t}.`,Jr=e=>`${e} is not supported in AG Charts Community (either 'ag-grid-charts-enterprise' or '@ag-grid-enterprise/charts-enterprise' hasn't been loaded). See https://www.ag-grid.com/javascript-data-grid/integrated-charts-installation/ for more details.`,en=class e{static isEnterprise(){return _t._ModuleSupport.enterpriseModule.isEnterprise}static isValidChartType(e){return!!_r(e)||Sr(e)}static isLegacyChartType(t){return e.legacyChartTypes.includes(t)}static validateUpdateParams(t){switch(t.type){case"rangeChartUpdate":return e.validateUpdateRangeChartParams(t);case"pivotChartUpdate":return e.validateUpdatePivotChartParams(t);case"crossFilterChartUpdate":return e.validateUpdateCrossFilterChartParams(t);default:return console.warn(`AG Grid - Invalid value supplied for 'type': ${t.type}. It must be either 'rangeChartUpdate', 'pivotChartUpdate', or 'crossFilterChartUpdate'.`),!1}}static validateCreateParams(t){return e.validateProperties(t,[e.enterpriseChartTypeValidation,e.switchCategorySeriesValidation])}static validateUpdateRangeChartParams(t){const i=[...e.commonUpdateValidations,e.enterpriseChartTypeValidation,...e.cellRangeValidations,{property:"seriesChartTypes",validationFn:e=>void 0===e||Array.isArray(e)&&e.every(Xr),warnMessage:Zr("seriesChartTypes","Array of SeriesChartType")}];return e.validateProperties(t,i,[...e.baseUpdateChartParams,"cellRange","suppressChartRanges","switchCategorySeries","aggFunc","seriesChartTypes","seriesGroupType"],"UpdateRangeChartParams")}static validateUpdatePivotChartParams(t){const i=[...e.commonUpdateValidations];return e.validateProperties(t,i,[...e.baseUpdateChartParams],"UpdatePivotChartParams")}static validateUpdateCrossFilterChartParams(t){const i=[...e.commonUpdateValidations,...e.cellRangeValidations];return e.validateProperties(t,i,[...e.baseUpdateChartParams,"cellRange","suppressChartRanges","aggFunc"],"UpdateCrossFilterChartParams")}static validateProperties(e,t,i,r){let n;for(const i of t){const{property:t,validationFn:r,warnMessage:s,warnIfFixed:o}=i;if(t in e){const i=e[t],a=r(i);if(!0===a)continue;if(!1===a)return console.warn(s(i)),!1;n=n||hr({},e),n[t]=a,o&&console.warn(s(i))}}if(i)for(const t in e)if(!i.includes(t))return console.warn(`AG Grid - Unexpected property supplied. ${r} does not contain: \`${t}\`.`),!1;return n||!0}};en.legacyChartTypes=["doughnut"],en.baseUpdateChartParams=["type","chartId","chartType","chartThemeName","chartThemeOverrides","unlinkChart"],en.validateChartType=qr(e=>{if(en.isValidChartType(e))return!0;if(en.isLegacyChartType(e)){const t=Rr(e);return Rt._.warnOnce(`The chart type '${e}' has been deprecated. Please use '${t}' instead.`),t}return!1}),en.validateAgChartThemeOverrides=qr(e=>"object"==typeof e),en.validateChartParamsCellRange=qr(e=>"object"==typeof e),en.validateAggFunc=qr(e=>"string"==typeof e||"function"==typeof e),en.enterpriseChartTypeValidation={property:"chartType",validationFn:qr(e=>en.isEnterprise()||!e||!function(e){return br(Pr(e),"isEnterprise")}(e)),warnMessage:e=>Jr(`The '${e}' chart type`)},en.switchCategorySeriesValidation={property:"switchCategorySeries",validationFn:qr(e=>{if(!e||en.isEnterprise())return!0}),warnMessage:()=>Jr("'switchCategorySeries' has been ignored as it"),warnIfFixed:!0},en.commonUpdateValidations=[{property:"chartId",validationFn:Yr,warnMessage:Zr("chartId","string")},{property:"chartType",validationFn:en.validateChartType,warnMessage:Zr("chartType","ChartType")},{property:"chartThemeName",validationFn:Yr,warnMessage:Zr("chartThemeName","string")},{property:"chartThemeOverrides",validationFn:en.validateAgChartThemeOverrides,warnMessage:Zr("chartThemeOverrides","AgChartThemeOverrides")},{property:"unlinkChart",validationFn:Qr,warnMessage:Zr("unlinkChart","boolean")}],en.cellRangeValidations=[{property:"cellRange",validationFn:en.validateChartParamsCellRange,warnMessage:Zr("cellRange","ChartParamsCellRange")},{property:"suppressChartRanges",validationFn:Qr,warnMessage:Zr("suppressChartRanges","boolean")},{property:"aggFunc",validationFn:en.validateAggFunc,warnMessage:Zr("aggFunc","string or IAggFunc")},en.switchCategorySeriesValidation];var tn=en,rn=["ag-default","ag-material","ag-sheets","ag-polychroma","ag-vivid"],nn=class e extends Ct.BeanStub{constructor(e){super(),this.model=e,this.isEnterprise=()=>At._ModuleSupport.enterpriseModule.isEnterprise}init(){this.setChartRange(),this.addManagedListener(this.eventService,Ct.Events.EVENT_RANGE_SELECTION_CHANGED,e=>{e.id&&e.id===this.model.chartId&&this.updateForRangeChange()}),this.model.unlinked&&this.rangeService&&this.rangeService.setCellRanges([]),this.addManagedListener(this.eventService,Ct.Events.EVENT_COLUMN_MOVED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,Ct.Events.EVENT_COLUMN_PINNED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,Ct.Events.EVENT_COLUMN_VISIBLE,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,Ct.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,Ct.Events.EVENT_MODEL_UPDATED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,Ct.Events.EVENT_CELL_VALUE_CHANGED,this.updateForDataChange.bind(this))}update(e){if(!this.validUpdateType(e))return!1;const t=tn.validateUpdateParams(e);if(!t)return!1;const i=!0===t?e:t;return this.applyValidatedChartParams(i),!0}applyValidatedChartParams(e){var t,i,r,n,s,o,a,l,c;const{chartId:u,chartType:h,chartThemeName:d,unlinkChart:p}=e,g={chartId:u,pivotChart:this.model.pivotChart,chartType:null!=h?h:this.model.chartType,chartThemeName:null!=d?d:this.model.chartThemeName,unlinkChart:null!=p?p:this.model.unlinked,cellRange:this.model.suppliedCellRange,switchCategorySeries:this.model.switchCategorySeries,aggFunc:this.model.aggFunc,seriesChartTypes:void 0,suppressChartRanges:!1,crossFiltering:!1};let f=hr({},g);switch(e.type){case"rangeChartUpdate":f.cellRange=null!=(t=this.createCellRange(e))?t:this.model.suppliedCellRange,f.switchCategorySeries=null!=(i=e.switchCategorySeries)?i:this.model.switchCategorySeries,f.aggFunc=null!=(r=e.aggFunc)?r:this.model.aggFunc,f.seriesChartTypes=e.seriesChartTypes,f.suppressChartRanges=null!=(n=e.suppressChartRanges)?n:this.model.suppressChartRanges,f.seriesGroupType=null!=(s=e.seriesGroupType)?s:this.model.seriesGroupType;break;case"crossFilterChartUpdate":f.cellRange=null!=(o=this.createCellRange(e))?o:this.model.suppliedCellRange,f.switchCategorySeries=!1,f.aggFunc=null!=(a=e.aggFunc)?a:this.model.aggFunc,f.crossFiltering=!0,f.suppressChartRanges=null!=(l=e.suppressChartRanges)?l:this.model.suppressChartRanges;break;case"pivotChartUpdate":f.switchCategorySeries=!1}this.model.updateModel(f),f.unlinkChart||f.suppressChartRanges?null==(c=this.rangeService)||c.setCellRanges([]):this.setChartRange()}updateForGridChange(e){if(this.model.unlinked)return;const{maintainColState:t,setColsFromRange:i}=null!=e?e:{};this.model.updateCellRanges({maintainColState:t,setColsFromRange:i}),this.model.updateData(),this.setChartRange()}updateForDataChange(){this.model.unlinked||(this.model.updateData(),this.raiseChartModelUpdateEvent())}updateForRangeChange(){this.updateForGridChange({setColsFromRange:!0}),this.raiseChartRangeSelectionChangedEvent()}updateForPanelChange(e){this.model.updateCellRanges(e),this.model.updateData(),e.skipAnimation&&this.getChartProxy().getChartRef().skipAnimations(),this.setChartRange(),this.raiseChartRangeSelectionChangedEvent()}updateThemeOverrides(e){this.chartProxy.updateThemeOverrides(e)}getChartUpdateParams(e){const t=this.getSelectedValueColState().map(e=>({colId:e.colId,displayName:e.displayName})),i=this.getChartData(),r=this.getSelectedDimensions(),n={data:i,groupData:this.model.groupChartData,grouping:this.isGrouping(),categories:r.map(e=>{var t;return{id:e.colId,name:e.displayName,chartDataType:null!=(t=this.model.categoryAxisType)?t:this.model.getChartDataType(e.colId)}}),fields:t,chartId:this.getChartId(),getCrossFilteringContext:()=>({lastSelectedChartId:"xxx"}),seriesChartTypes:this.getSeriesChartTypes(),updatedOverrides:e,seriesGroupType:this.model.seriesGroupType};return this.isCategorySeriesSwitched()?this.invertCategorySeriesParams(n):n}invertCategorySeriesParams(e){const[t]=e.categories,i=[{id:Or.DEFAULT_CATEGORY,name:""}],r=e.data.map((e,i)=>{const r=`${t.id}:${i}`,n=e[t.id];return{colId:r,displayName:null==n?"":String(n)}}),n=e.fields.map(i=>{const r={[Or.DEFAULT_CATEGORY]:i.displayName};for(const[n,s]of e.data.entries()){const e=`${t.id}:${n}`,o=s[i.colId];r[e]=o}return r});return dr(hr({},e),{categories:i,fields:r,data:n})}getChartModel(){const e=this.model.pivotChart?"pivot":"range",t=this.isComboChart()?this.model.comboChartModel.seriesChartTypes:void 0;return{modelType:e,chartId:this.model.chartId,chartType:this.model.chartType,chartThemeName:this.getChartThemeName(),chartOptions:this.chartProxy.getChartThemeOverrides(),chartPalette:this.chartProxy.getChartPalette(),cellRange:this.getCellRangeParams(),switchCategorySeries:this.model.switchCategorySeries,suppressChartRanges:this.model.suppressChartRanges,aggFunc:this.model.aggFunc,unlinkChart:this.model.unlinked,seriesChartTypes:t,seriesGroupType:this.model.seriesGroupType}}getChartId(){return this.model.chartId}getChartData(){return this.model.chartData}getChartType(){return this.model.chartType}setChartType(e){this.updateMultiSeriesAndCategory(this.model.chartType,e),this.model.chartType=e,this.model.comboChartModel.updateSeriesChartTypes(),this.model.switchCategorySeries=!1,this.model.categoryAxisType=void 0,this.model.seriesGroupType=void 0,this.raiseChartModelUpdateEvent(),this.raiseChartOptionsChangedEvent()}isCategorySeriesSwitched(){return this.model.switchCategorySeries&&!this.model.isGrouping()}switchCategorySeries(e){Lr(this.getChartType())&&(this.model.switchCategorySeries=e,this.raiseChartModelUpdateEvent())}getAggFunc(){return this.model.aggFunc}setAggFunc(e,t){this.model.aggFunc!==e&&(this.model.aggFunc=e,t||(this.model.updateData(),this.raiseChartModelUpdateEvent()))}updateMultiSeriesAndCategory(e,t){var i,r;const n=(e,t)=>{let i=0;for(const r of e)r.selected&&(i>=t?r.selected=!1:i++);0===i&&(e[0].selected=!0)},s=Dr(t),o=Ir(t),a=null!=s&&(null!=(i=Dr(e))?i:100)>(null!=s?s:100),l=null!=o&&(null!=(r=Ir(e))?r:100)>(null!=o?o:100);a&&n(this.model.dimensionColState,s),l&&n(this.model.valueColState,o),(a||l)&&(this.model.resetCellRanges(a,l),this.setChartRange(!0))}setChartThemeName(e,t){this.model.chartThemeName=e,t||(this.raiseChartModelUpdateEvent(),this.raiseChartOptionsChangedEvent())}getChartThemeName(){return this.model.chartThemeName}isPivotChart(){return this.model.pivotChart}isPivotMode(){return this.model.isPivotMode()}isGrouping(){return this.model.isGrouping()}isCrossFilterChart(){return this.model.crossFiltering}getThemeNames(){return this.gos.get("chartThemes")||rn}getThemes(){return this.getThemeNames().map(e=>{const t=Wr(e)?e:this.chartProxy.lookupCustomChartTheme(e);return At._Theme.getChartTheme(t)})}getPalettes(){return this.getThemes().map(e=>e.palette)}getThemeTemplateParameters(){return this.getThemes().map(e=>e.getTemplateParameters())}getValueColState(){return this.model.valueColState.map(this.displayNameMapper.bind(this))}getSelectedValueColState(){return this.getValueColState().filter(e=>e.selected)}getSelectedDimensions(){return this.model.getSelectedDimensions()}displayNameMapper(e){const t=this.model.columnNames[e.colId];return e.displayName=t?t.join(" - "):this.model.getColDisplayName(e.column),e}getColStateForMenu(){return{dimensionCols:this.model.dimensionColState,valueCols:this.getValueColState()}}setChartRange(e=!1){!this.rangeService||this.model.suppressChartRanges||this.model.unlinked||this.rangeService.setCellRanges(this.getCellRanges()),e||this.raiseChartModelUpdateEvent()}detachChartRange(){this.model.unlinked=!this.model.unlinked,this.model.unlinked?this.rangeService&&this.rangeService.setCellRanges([]):this.updateForGridChange(),this.dispatchEvent({type:e.EVENT_CHART_LINKED_CHANGED})}setChartProxy(e){this.chartProxy=e}getChartProxy(){return this.chartProxy}isActiveXYChart(){return Ct._.includes(["scatter","bubble"],this.getChartType())}isChartLinked(){return!this.model.unlinked}customComboExists(){const e=this.model.comboChartModel.savedCustomSeriesChartTypes;return e&&e.length>0}getSeriesChartTypes(){return this.model.comboChartModel.seriesChartTypes}isComboChart(e){return this.model.isComboChart(e)}updateSeriesChartType(t,i,r){const n=this.model.comboChartModel.seriesChartTypes.find(e=>e.colId===t);if(n){const t="customCombo"!==this.model.chartType;t&&(this.model.chartType="customCombo");const s=n.chartType;null!=i&&(n.chartType=i),null!=r&&(n.secondaryAxis=r),this.model.comboChartModel.savedCustomSeriesChartTypes=this.model.comboChartModel.seriesChartTypes,this.model.comboChartModel.updateSeriesChartTypes(),this.updateForDataChange(),t&&this.dispatchEvent({type:e.EVENT_CHART_TYPE_CHANGED}),s!==i&&this.dispatchEvent({type:e.EVENT_CHART_SERIES_CHART_TYPE_CHANGED}),this.raiseChartOptionsChangedEvent()}}getActiveSeriesChartTypes(){const e=this.getSelectedValueColState().map(e=>e.colId);return this.getSeriesChartTypes().filter(t=>e.includes(t.colId))}getChartSeriesTypes(e){const t=null!=e?e:this.getChartType();return this.isComboChart(t)?["line","bar","area"]:[Pr(t)]}getChartSeriesType(){const e=this.getSeriesChartTypes();if(0===e.length)return"bar";const t=e[0].chartType;return"columnLineCombo"===t?"bar":"areaColumnCombo"===t?"area":Pr(t)}getCellRanges(){return[this.model.dimensionCellRange,this.model.valueCellRange].filter(e=>e)}createCellRange(e){var t;return e.cellRange&&(null==(t=this.rangeService)?void 0:t.createPartialCellRangeFromRangeParams(e.cellRange,!0))}validUpdateType(e){var t;if(!e.type)return console.warn("AG Grid - Unable to update chart as the 'type' is missing. It must be either 'rangeChartUpdate', 'pivotChartUpdate', or 'crossFilterChartUpdate'."),!1;const i={"Range Chart":()=>!this.isPivotChart()&&!this.isCrossFilterChart(),"Pivot Chart":()=>this.isPivotChart(),"Cross Filter Chart":()=>this.isCrossFilterChart()},r=null!=(t=Object.keys(i).find(e=>i[e]()))?t:"Range Chart",n=e.type===`${r[0].toLowerCase()}${r.slice(1).replace(/ /g,"")}Update`;return n||console.warn(`AG Grid - Unable to update chart as a '${e.type}' update type is not permitted on a ${r}.`),n}getCellRangeParams(){const e=this.getCellRanges(),t=e[0],i=t&&t.startRow||null,r=t&&t.endRow||null;return{rowStartIndex:i&&i.rowIndex,rowStartPinned:i&&i.rowPinned,rowEndIndex:r&&r.rowIndex,rowEndPinned:r&&r.rowPinned,columns:e.reduce((e,t)=>e.concat(t.columns.map(e=>e.getId())),[])}}setCategoryAxisType(e){this.model.categoryAxisType=e,this.raiseChartModelUpdateEvent()}getSeriesGroupType(){var e;return null!=(e=this.model.seriesGroupType)?e:this.chartProxy.getSeriesGroupType()}setSeriesGroupType(e){this.model.seriesGroupType=e,this.raiseChartModelUpdateEvent()}raiseChartModelUpdateEvent(){const t={type:e.EVENT_CHART_MODEL_UPDATE};this.dispatchEvent(t)}raiseChartUpdatedEvent(){const t={type:e.EVENT_CHART_UPDATED};this.dispatchEvent(t)}raiseChartApiUpdateEvent(){const t={type:e.EVENT_CHART_API_UPDATE};this.dispatchEvent(t)}raiseChartOptionsChangedEvent(){const{chartId:e,chartType:t}=this.getChartModel(),i={type:Ct.Events.EVENT_CHART_OPTIONS_CHANGED,chartId:e,chartType:t,chartThemeName:this.getChartThemeName(),chartOptions:this.chartProxy.getChartThemeOverrides()};this.eventService.dispatchEvent(i)}raiseChartRangeSelectionChangedEvent(){const e={type:Ct.Events.EVENT_CHART_RANGE_SELECTION_CHANGED,id:this.model.chartId,chartId:this.model.chartId,cellRange:this.getCellRangeParams()};this.eventService.dispatchEvent(e)}destroy(){super.destroy(),this.rangeService&&this.rangeService.setCellRanges([])}};nn.EVENT_CHART_UPDATED="chartUpdated",nn.EVENT_CHART_API_UPDATE="chartApiUpdate",nn.EVENT_CHART_MODEL_UPDATE="chartModelUpdate",nn.EVENT_CHART_TYPE_CHANGED="chartTypeChanged",nn.EVENT_CHART_SERIES_CHART_TYPE_CHANGED="chartSeriesChartTypeChanged",nn.EVENT_CHART_LINKED_CHANGED="chartLinkedChanged",gr([(0,Ct.Autowired)("rangeService")],nn.prototype,"rangeService",2),gr([Ct.PostConstruct],nn.prototype,"init",1);var sn=nn,on=class e extends Dt.Component{constructor(t){super(e.TEMPLATE),this.config=null!=t?t:{};const{selectedValueList:i,valueFormatter:r,valueList:n}=this.config;this.selectedValues=null!=i?i:[],this.valueList=null!=n?n:[],this.valueFormatter=null!=r?r:e=>Dt._.escapeString(e)}init(){const{ariaLabel:e,onValuesChange:t,dragSourceId:i}=this.config;this.dropZonePanel=this.createManagedBean(new cn({getValues:()=>this.selectedValues,setValues:e=>this.updateValues(e),isDraggable:()=>this.selectedValues.length>1},e=>this.valueFormatter(e),e,i)),this.getGui().appendChild(this.dropZonePanel.getGui()),this.initSelect(),null!=t&&(this.onValuesChange=t)}setValues(e,t){const{added:i,removed:r,updated:n}=this.getChanges(this.valueList,e);let s=!1;return(i.length||r.length||n.length)&&(s=!0),this.valueList=e,this.updateValues(t,s,!0),this}setValueFormatter(e){return this.valueFormatter=e,this}initSelect(){const e=this.createSelectOptions();if(!e.length)return!1;const{selectPlaceholder:t}=this.config;return this.eSelect=this.createBean(new Dt.AgSelect({options:e,placeholder:t,onValueChange:e=>this.addValue(e),pickerIcon:"chartsMenuAdd"})),this.getGui().appendChild(this.eSelect.getGui()),!0}createSelectOptions(){let e=[];const{maxSelection:t}=this.config;return t&&this.selectedValues.length>=t||this.valueList.forEach(t=>{this.selectedValues.includes(t)||e.push({value:t,text:this.valueFormatter(t)})}),e}addValue(e){this.dropZonePanel.addItem(e)}updateValues(e,t,i){var r,n,s,o,a;const l=this.selectedValues;this.selectedValues=e;const c=this.getChanges(l,e),u=t||c.added.length||c.removed.length,h=this.gos.getActiveDomElement(),d=null==(r=this.eSelect)?void 0:r.getGui().contains(h),p=null==(n=this.dropZonePanel)?void 0:n.getGui().contains(h);i||null==(s=this.onValuesChange)||s.call(this,c);const g=!!u&&!this.refreshSelect();this.dropZonePanel.refreshGui(),u&&d&&(g?this.dropZonePanel.focusList(!0):null==(o=this.eSelect)||o.getFocusableElement().focus()),p&&!e.length&&(null==(a=this.eSelect)||a.getFocusableElement().focus())}getChanges(e,t){return{added:t.filter(t=>!e.includes(t)),removed:e.filter(e=>!t.includes(e)),updated:t.filter((t,i)=>e[i]!==t),selected:t}}refreshSelect(){if(!this.eSelect)return this.initSelect();const e=this.createSelectOptions();return e.length?(this.eSelect.clearOptions().addOptions(e).setValue(void 0,!0),!0):(Dt._.removeFromParent(this.eSelect.getGui()),this.eSelect=this.destroyBean(this.eSelect),!1)}destroy(){this.destroyBean(this.eSelect),super.destroy()}};on.TEMPLATE='<div class="ag-pill-select" role="presentation"></div>',gr([Dt.PostConstruct],on.prototype,"init",1);var an=on,ln=class extends Dt.PillDragComp{constructor(e,t,i,r,n,s){super(t,i,!1),this.value=e,this.valueFormatter=r,this.draggable=n,this.sourceId=s}getItem(){return this.value}getDisplayName(){return this.valueFormatter(this.value)}getAriaDisplayName(){return this.getDisplayName()}getTooltip(){}createGetDragItem(){return()=>({value:this.value})}getDragSourceType(){return Dt.DragSourceType.ChartPanel}getDragSourceId(){return this.sourceId}isDraggable(){return this.draggable}},cn=class extends Dt.PillDropZonePanel{constructor(e,t,i,r){super(!1),this.model=e,this.valueFormatter=t,this.ariaLabel=i,this.sourceId=r}postConstruct(){super.init()}isItemDroppable(e,t){return this.isSourceEventFromTarget(t)||null!=this.sourceId&&this.sourceId===t.dragSource.sourceId}updateItems(e){this.model.setValues(e)}getExistingItems(){return this.model.getValues()}getIconName(){return this.isPotentialDndItems()?Dt.DragAndDropService.ICON_MOVE:Dt.DragAndDropService.ICON_NOT_ALLOWED}getAriaLabel(){return this.ariaLabel}createPillComponent(e,t,i){return new ln(e,t,i,this.valueFormatter,this.model.isDraggable(),this.sourceId)}getItems(e){return[e.value]}isInterestedIn(e){return e===Dt.DragSourceType.ChartPanel}};gr([Dt.PostConstruct],cn.prototype,"postConstruct",1);var un=class extends xt.Component{constructor(e,t,i,r,n){super(n),this.chartController=e,this.autoScrollService=t,this.allowMultipleSelection=i,this.maxSelection=r,this.columnComps=new Map}refreshColumnComps(e){return!!xt._.areEqual(xt._.keys(this.columnComps),e.map(({colId:e})=>e))&&(e.forEach(e=>{this.columnComps.get(e.colId).setValue(e.selected,!0)}),!0)}createGroup(e,t,i,r,n){if(this.allowMultipleSelection){const n=e.filter(e=>e.selected);this.valuePillSelect=this.groupComp.createManagedBean(new an({valueList:e,selectedValueList:n,valueFormatter:t,selectPlaceholder:this.chartTranslationService.translate(i),dragSourceId:r,onValuesChange:e=>this.onValueChange(e),maxSelection:this.maxSelection})),this.groupComp.addItem(this.valuePillSelect)}else{const t=this.createValueSelectParams(e);t.onValueChange=t=>{e.forEach(e=>{e.selected=!1}),t.selected=!0,t.colId===Or.DEFAULT_CATEGORY&&this.chartController.setAggFunc(void 0,!0),this.chartController.updateForPanelChange({updatedColState:t,skipAnimation:null==n?void 0:n()})},this.valueSelect=this.groupComp.createManagedBean(new xt.AgSelect(t)),this.groupComp.addItem(this.valueSelect)}}refreshValueSelect(e){if(!this.valueSelect)return;const{options:t,value:i}=this.createValueSelectParams(e);this.valueSelect.clearOptions().addOptions(t).setValue(i,!0)}createValueSelectParams(e){let t;return{options:e.map(e=>{var i;const r=null!=(i=e.displayName)?i:"";return e.selected&&(t=e),{value:e,text:r}}),value:t}}onDragging(e){const t=this.checkHoveredItem(e);if(!t)return;this.lastDraggedColumn=e.dragItem.columns[0];const{comp:i,position:r}=t,{comp:n,position:s}=this.lastHoveredItem||{};i===n&&r===s||(this.autoScrollService.check(e.event),this.clearHoveredItems(),this.lastHoveredItem={comp:i,position:r},i.getGui().classList.add("ag-list-item-hovered",`ag-item-highlight-${r}`))}checkHoveredItem(e){if(xt._.missing(e.vDirection))return null;const t=e.event;for(const e of this.columnComps.values()){const i=e.getGui();if(!i.querySelector(".ag-chart-data-column-drag-handle"))continue;const r=i.getBoundingClientRect();if(t.clientY>=r.top&&t.clientY<=r.bottom){const n=i.clientHeight;return{comp:e,position:t.clientY>r.top+n/2?"bottom":"top"}}}return null}onDragLeave(){this.clearHoveredItems()}onDragStop(){if(this.lastHoveredItem){const{dimensionCols:e,valueCols:t}=this.chartController.getColStateForMenu(),i=[...e,...t].find(e=>e.column===this.lastDraggedColumn);if(i){let e=Array.from(this.columnComps.values()).indexOf(this.lastHoveredItem.comp);"bottom"===this.lastHoveredItem.position&&e++,i.order=e,this.chartController.updateForPanelChange({updatedColState:i})}}this.clearHoveredItems(),this.lastDraggedColumn=void 0,this.autoScrollService.ensureCleared()}clearHoveredItems(){this.columnComps.forEach(e=>{e.getGui().classList.remove("ag-list-item-hovered","ag-item-highlight-top","ag-item-highlight-bottom")}),this.lastHoveredItem=void 0}addDragHandle(e,t){const i=xt._.createIconNoSpan("columnDrag",this.gos);i.classList.add("ag-drag-handle","ag-chart-data-column-drag-handle"),e.getGui().insertAdjacentElement("beforeend",i);const r={type:xt.DragSourceType.ChartPanel,eElement:i,dragItemName:t.displayName,getDragItem:()=>({columns:[t.column]}),onDragStopped:()=>this.onDragStop()};this.dragAndDropService.addDragSource(r,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(r))}addChangeListener(e,t){this.addManagedListener(e,xt.Events.EVENT_FIELD_VALUE_CHANGED,()=>{t.selected=e.getValue(),this.chartController.updateForPanelChange({updatedColState:t})})}isInterestedIn(e){return e===xt.DragSourceType.ChartPanel}onValueChange({added:e,updated:t,removed:i,selected:r}){let n,s;const o=()=>{r.forEach((e,t)=>{e.order=t}),s=!0};e.length?(n=e[0],n.selected=!0,o()):i.length?(n=i[0],n.selected=!1):t.length&&(o(),n=t[0]),n&&this.chartController.updateForPanelChange({updatedColState:n,resetOrder:s})}destroy(){this.valuePillSelect=void 0,this.valueSelect=void 0,super.destroy()}};gr([(0,xt.Autowired)("dragAndDropService")],un.prototype,"dragAndDropService",2),gr([(0,xt.Autowired)("chartTranslationService")],un.prototype,"chartTranslationService",2);var hn=class e extends un{constructor(t,i,r,n,s,o){super(t,i,n,void 0,e.TEMPLATE),this.title=r,this.dimensionCols=s,this.isOpen=o}init(){this.groupComp=this.createBean(new Pt.AgGroupComponent({title:this.title,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen})),this.chartMenuService.isLegacyFormat()?(this.createLegacyCategoriesGroup(this.dimensionCols),this.clearAggFuncControls()):(this.createCategoriesGroup(this.dimensionCols),this.createAggFuncControls(this.dimensionCols)),this.getGui().appendChild(this.groupComp.getGui())}refresh(e){var t;this.chartMenuService.isLegacyFormat()?this.refreshColumnComps(e)||this.recreate(e):(null==(t=this.valuePillSelect)||t.setValues(e,e.filter(e=>e.selected)),this.refreshValueSelect(e),this.refreshAggFuncControls(e,this.chartController.getAggFunc()))}recreate(e){this.isOpen=this.groupComp.isExpanded(),Pt._.clearElement(this.getGui()),this.destroyBean(this.groupComp),this.dimensionCols=e,this.init()}createCategoriesGroup(e){this.createGroup(e,e=>{var t;return null!=(t=e.displayName)?t:""},"categoryAdd","categorySelect",()=>!this.chartController.getAggFunc())}createLegacyCategoriesGroup(e){const t=`chartDimension${this.groupComp.getCompId()}`,i=this.allowMultipleSelection;if(e.forEach(e=>{var r;const n={label:null!=(r=e.displayName)?r:"",value:e.selected,inputName:t},s=this.groupComp.createManagedBean(i?(()=>{const e=new Pt.AgCheckbox(n);return e.addCssClass("ag-data-select-checkbox"),e})():new Pt.AgRadioButton(n));this.addChangeListener(s,e),this.groupComp.addItem(s),this.columnComps.set(e.colId,s),i&&this.addDragHandle(s,e)}),i){const e=this.groupComp.getGui(),t={getIconName:()=>Pt.DragAndDropService.ICON_MOVE,getContainer:()=>e,onDragging:e=>this.onDragging(e),onDragLeave:()=>this.onDragLeave(),isInterestedIn:this.isInterestedIn.bind(this),targetContainsSource:!0};this.dragAndDropService.addDropTarget(t),this.addDestroyFunc(()=>this.dragAndDropService.removeDropTarget(t))}}createAggFuncControls(e){const t=this.chartController.getAggFunc();this.groupComp.addItem(this.aggFuncToggle=this.createBean(new Pt.AgToggleButton({label:this.chartTranslationService.translate("aggregate"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:null!=t,onValueChange:e=>{var t,i;const r=e?"sum":void 0;this.chartController.setAggFunc(r),null==(t=this.aggFuncSelect)||t.setValue(r,!0),null==(i=this.aggFuncSelect)||i.setDisplayed(null!=r)}}))),this.groupComp.addItem(this.aggFuncSelect=this.createBean(new Pt.AgSelect({options:[{value:"sum",text:this.chartTranslationService.translate("sum")},{value:"first",text:this.chartTranslationService.translate("first")},{value:"last",text:this.chartTranslationService.translate("last")},{value:"min",text:this.chartTranslationService.translate("min")},{value:"max",text:this.chartTranslationService.translate("max")},{value:"count",text:this.chartTranslationService.translate("count")},{value:"avg",text:this.chartTranslationService.translate("avg")}],value:"string"==typeof t?t:void 0,onValueChange:e=>{this.chartController.setAggFunc(e)}}))),this.refreshAggFuncControls(e,t)}refreshAggFuncControls(e,t){var i,r,n,s;const o=e.filter(e=>e.selected).some(e=>e.colId!==Or.DEFAULT_CATEGORY);null==(i=this.aggFuncToggle)||i.setValue(null!=t),null==(r=this.aggFuncSelect)||r.setValue("string"==typeof t?t:void 0,!0),null==(n=this.aggFuncToggle)||n.setDisplayed(o),null==(s=this.aggFuncSelect)||s.setDisplayed(o&&null!=t)}clearAggFuncControls(){this.aggFuncToggle=this.aggFuncToggle&&this.destroyBean(this.aggFuncToggle),this.aggFuncSelect=this.aggFuncSelect&&this.destroyBean(this.aggFuncSelect)}destroy(){this.clearAggFuncControls(),this.groupComp=this.destroyBean(this.groupComp),super.destroy()}};hn.TEMPLATE='<div id="categoriesGroup"></div>',gr([(0,Pt.Autowired)("chartMenuService")],hn.prototype,"chartMenuService",2),gr([Pt.PostConstruct],hn.prototype,"init",1);var dn=hn,pn=class e extends un{constructor(t,i,r,n,s,o,a,l){super(t,i,s,o,e.TEMPLATE),this.chartOptionsService=r,this.title=n,this.valueCols=a,this.isOpen=l}init(){if(this.groupComp=this.createBean(new It.AgGroupComponent({title:this.title,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen})),this.chartController.isActiveXYChart()){const e=this.groupComp.createManagedBean(new It.AgToggleButton({label:this.chartTranslationService.translate("paired"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:this.chartOptionsService.getPairedMode(),onValueChange:e=>{this.chartOptionsService.setPairedMode(!!e),this.chartController.updateForGridChange({maintainColState:!0})}}));this.groupComp.addItem(e)}this.chartMenuService.isLegacyFormat()?this.createLegacySeriesGroup(this.valueCols):this.createSeriesGroup(this.valueCols),this.getGui().appendChild(this.groupComp.getGui())}refresh(e){var t,i;if(this.chartMenuService.isLegacyFormat())if(this.refreshColumnComps(e)){if(this.chartController.isActiveXYChart()){const t=this.generateGetSeriesLabel(e);e.forEach(e=>{this.columnComps.get(e.colId).setLabel(t(e))})}}else this.recreate(e);else null==(t=this.valuePillSelect)||t.setValueFormatter(this.generateGetSeriesLabel(e)),null==(i=this.valuePillSelect)||i.setValues(e,e.filter(e=>e.selected)),this.refreshValueSelect(e)}recreate(e){this.isOpen=this.groupComp.isExpanded(),It._.clearElement(this.getGui()),this.destroyBean(this.groupComp),this.valueCols=e,this.init()}createSeriesGroup(e){this.createGroup(e,this.generateGetSeriesLabel(e),"seriesAdd","seriesSelect")}createLegacySeriesGroup(e){const t=this.generateGetSeriesLabel(e);e.forEach(e=>{const i=t(e),r=this.groupComp.createManagedBean(new It.AgCheckbox({label:i,value:e.selected}));r.addCssClass("ag-data-select-checkbox"),this.addChangeListener(r,e),this.groupComp.addItem(r),this.columnComps.set(e.colId,r),this.addDragHandle(r,e)});const i=this.groupComp.getGui(),r={getIconName:()=>It.DragAndDropService.ICON_MOVE,getContainer:()=>i,onDragging:e=>this.onDragging(e),onDragLeave:()=>this.onDragLeave(),isInterestedIn:this.isInterestedIn.bind(this),targetContainsSource:!0};this.dragAndDropService.addDropTarget(r),this.addDestroyFunc(()=>this.dragAndDropService.removeDropTarget(r))}generateGetSeriesLabel(e){if(!this.chartController.isActiveXYChart())return e=>{var t;return null!=(t=e.displayName)?t:""};const t=e.filter(e=>e.selected),i="bubble"===this.chartController.getChartType(),r=this.chartOptionsService.getPairedMode(),n=new Map;return n.set(0,"X"),n.set(1,"Y"),n.set(2,"size"),e=>{var s;const o=null!=(s=e.displayName)?s:"";if(!e.selected)return o;const a=t.indexOf(e);if(-1===a)return o;let l;return l=r?n.get(a%(i?3:2)):0===a?"X":i&&a%2==0?"size":"Y",`${o} (${l})`}}destroy(){this.groupComp=this.destroyBean(this.groupComp),super.destroy()}};pn.TEMPLATE='<div id="seriesGroup"></div>',gr([(0,It.Autowired)("chartMenuService")],pn.prototype,"chartMenuService",2),gr([It.PostConstruct],pn.prototype,"init",1);var gn=pn,fn=class e extends Lt.Component{constructor(t,i,r){super(e.TEMPLATE),this.chartController=t,this.columns=i,this.isOpen=r,this.selectedColIds=[],this.chartTypeComps=new Map,this.secondaryAxisComps=new Map}init(){this.createSeriesChartTypeGroup(this.columns)}refresh(e){Lt._.areEqual(this.getValidColIds(e),this.selectedColIds)?this.refreshComps():this.recreate(e)}recreate(e){this.isOpen=this.seriesChartTypeGroupComp.isExpanded(),Lt._.clearElement(this.getGui()),this.destroyBean(this.seriesChartTypeGroupComp),this.columns=e,this.selectedColIds=[],this.clearComps(),this.init()}getValidColIds(e){const t=this.chartController.getSeriesChartTypes();return e.filter(e=>e.selected&&!!t.filter(t=>t.colId===e.colId)[0]).map(({colId:e})=>e)}createSeriesChartTypeGroup(e){this.seriesChartTypeGroupComp=this.createBean(new Lt.AgGroupComponent({title:this.chartTranslationService.translate("seriesChartType"),enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen}));const t=this.chartController.getSeriesChartTypes();e.forEach(e=>{if(!e.selected)return;const i=t.filter(t=>t.colId===e.colId)[0];if(!i)return;this.selectedColIds.push(e.colId);const r=this.seriesChartTypeGroupComp.createManagedBean(new Lt.AgGroupComponent({title:e.displayName,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-format-sub-level"})),n=this.seriesChartTypeGroupComp.createManagedBean(new Lt.AgCheckbox({label:this.chartTranslationService.translate("secondaryAxis"),labelWidth:"flex",disabled:(s=i.chartType,["groupedColumn","stackedColumn","stackedArea"].includes(s)),value:!!i.secondaryAxis,onValueChange:t=>this.chartController.updateSeriesChartType(e.colId,void 0,t)}));var s;r.addItem(n);const o=e=>this.chartTranslationService.translate(e),a=[{value:"line",text:o("line")},{value:"area",text:o("area")},{value:"stackedArea",text:o("stackedArea")},{value:"groupedColumn",text:o("groupedColumn")},{value:"stackedColumn",text:o("stackedColumn")}],l=r.createManagedBean(new Lt.AgSelect({labelAlignment:"left",labelWidth:"flex",options:a,value:i.chartType,onValueChange:t=>this.chartController.updateSeriesChartType(e.colId,t)}));r.addItem(l),this.seriesChartTypeGroupComp.addItem(r),this.chartTypeComps.set(e.colId,l),this.secondaryAxisComps.set(e.colId,n)}),this.getGui().appendChild(this.seriesChartTypeGroupComp.getGui())}refreshComps(){const e=this.chartController.getSeriesChartTypes();this.selectedColIds.forEach(t=>{const i=e.find(e=>e.colId===t);if(!i)return;const r=this.chartTypeComps.get(t),n=this.secondaryAxisComps.get(t);null==r||r.setValue(i.chartType),null==n||n.setValue(!!i.secondaryAxis),null==n||n.setDisabled(this.isSecondaryAxisDisabled(i.chartType))})}clearComps(){this.chartTypeComps.clear(),this.secondaryAxisComps.clear()}isSecondaryAxisDisabled(e){return["groupedColumn","stackedColumn","stackedArea"].includes(e)}destroy(){this.clearComps(),this.seriesChartTypeGroupComp=this.destroyBean(this.seriesChartTypeGroupComp),super.destroy()}};fn.TEMPLATE='<div id="seriesChartTypeGroup"></div>',gr([(0,Lt.Autowired)("chartTranslationService")],fn.prototype,"chartTranslationService",2),gr([Lt.PostConstruct],fn.prototype,"init",1);var mn=fn,vn=class e extends Nt.Component{constructor(e,t){super(),this.getValue=e,this.setValue=t}init(){this.switchCategorySeriesToggleButton=this.createManagedBean(new Nt.AgToggleButton({label:this.chartTranslationService.translate("switchCategorySeries"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:this.getValue(),onValueChange:e=>{this.setValue(e)}}));const t={title:void 0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-data",expanded:!0,items:[this.switchCategorySeriesToggleButton]};this.setTemplate(e.TEMPLATE,{switchCategorySeriesGroup:t})}refresh(){var e;null==(e=this.switchCategorySeriesToggleButton)||e.setValue(this.getValue(),!0)}};vn.TEMPLATE='<div>\n        <ag-group-component ref="switchCategorySeriesGroup"></ag-group-component>\n    </div>',gr([(0,Nt.Autowired)("chartTranslationService")],vn.prototype,"chartTranslationService",2),gr([Nt.PostConstruct],vn.prototype,"init",1);var Cn=vn,yn={groups:[{type:"categories",isOpen:!0},{type:"series",isOpen:!0},{type:"seriesChartType",isOpen:!0}]},wn=class e extends vt.Component{constructor(t,i){super(e.TEMPLATE),this.chartController=t,this.chartOptionsService=i,this.isSwitchCategorySeriesToggled=!1}init(){this.switchCategorySeriesPanel=this.addComponent(this.createManagedBean(new Cn(()=>this.chartController.isCategorySeriesSwitched(),e=>this.chartController.switchCategorySeries(e)))),this.isSwitchCategorySeriesToggled=this.chartController.isCategorySeriesSwitched(),this.createAutoScrollService(),this.updatePanels(),this.addManagedListener(this.chartController,sn.EVENT_CHART_MODEL_UPDATE,this.updatePanels.bind(this)),this.addManagedListener(this.chartController,sn.EVENT_CHART_API_UPDATE,this.updatePanels.bind(this))}destroy(){this.clearPanelComponents(),super.destroy()}updatePanels(){var e,t,i,r,n;const s=this.chartType,o=this.isSwitchCategorySeriesToggled,{dimensionCols:a,valueCols:l}=this.chartController.getColStateForMenu();this.chartType=this.chartController.getChartType(),this.isSwitchCategorySeriesToggled=this.chartController.isCategorySeriesSwitched();const c=this.isSwitchCategorySeriesToggled!==o;this.canRefresh(s,this.chartType)&&!c?(null==(e=this.categoriesDataPanel)||e.refresh(a),null==(t=this.seriesDataPanel)||t.refresh(l),null==(i=this.seriesChartTypePanel)||i.refresh(l)):this.recreatePanels(a,l),null==(r=this.switchCategorySeriesPanel)||r.setDisplayed(Lr(this.chartType)&&!this.chartMenuService.isLegacyFormat()&&!this.chartController.isGrouping()),c&&(null==(n=this.switchCategorySeriesPanel)||n.refresh())}canRefresh(e,t){if(void 0===e)return!1;if(e===t)return!0;const i=e=>["columnLineCombo","areaColumnCombo","customCombo"].includes(e);return!(!i(e)||!i(t))}recreatePanels(e,t){var i;this.clearPanelComponents();const{chartType:r}=this;if(!r)return;const n=this.chartController.isCategorySeriesSwitched(),s=null==(i=this.getDataPanelDef().groups)?void 0:i.map(({type:i,isOpen:s})=>i===(n?"series":"categories")?this.categoriesDataPanel=this.createBean(new dn(this.chartController,this.autoScrollService,this.getCategoryGroupTitle(n),this.getCategoryGroupMultipleSelect(r,n),e,s)):i===(n?"categories":"series")?this.seriesDataPanel=this.createBean(new gn(this.chartController,this.autoScrollService,this.chartOptionsService,this.getSeriesGroupTitle(n),this.getSeriesGroupMultipleSelect(r,n),this.getSeriesGroupMaxSelection(r,n),t,s)):"seriesChartType"===i?this.chartController.isComboChart()?this.seriesChartTypePanel=this.createBean(new mn(this.chartController,t,s)):null:(vt._.warnOnce(`Invalid charts data panel group name supplied: '${i}'`),null)).filter(e=>null!=e);s&&this.addPanelComponents(s)}addPanelComponents(e){var t;const i=document.createDocumentFragment();for(const t of e)this.registerComponent(t),i.appendChild(t.getGui());const r=null==(t=this.switchCategorySeriesPanel)?void 0:t.getGui();return this.getGui().insertBefore(i,null!=r?r:null),e}clearPanelComponents(){const e=this.getGui();this.categoriesDataPanel&&e.removeChild(this.categoriesDataPanel.getGui()),this.seriesDataPanel&&e.removeChild(this.seriesDataPanel.getGui()),this.seriesChartTypePanel&&e.removeChild(this.seriesChartTypePanel.getGui()),this.categoriesDataPanel=this.destroyBean(this.categoriesDataPanel),this.seriesDataPanel=this.destroyBean(this.seriesDataPanel),this.seriesChartTypePanel=this.destroyBean(this.seriesChartTypePanel)}createAutoScrollService(){const e=this.getGui();this.autoScrollService=new vt.AutoScrollService({scrollContainer:e,scrollAxis:"y",getVerticalPosition:()=>e.scrollTop,setVerticalPosition:t=>e.scrollTop=t})}addComponent(e){return this.registerComponent(e),this.getGui().appendChild(e.getGui()),e}registerComponent(e){e.addCssClass("ag-chart-data-section")}getDataPanelDef(){var e,t;return null!=(t=null==(e=this.gos.get("chartToolPanelsDef"))?void 0:e.dataPanel)?t:yn}getCategoryGroupTitle(e){return e?this.chartTranslationService.translate("seriesLabels"):this.chartTranslationService.translate(this.chartController.isActiveXYChart()?"labels":"categories")}getCategoryGroupMultipleSelect(e,t){return!t&&1!==Dr(e)}getSeriesGroupTitle(e){return e?this.chartTranslationService.translate("categoryValues"):this.chartTranslationService.translate(this.chartController.isActiveXYChart()?"xyValues":"series")}getSeriesGroupMultipleSelect(e,t){return 1!==this.getSeriesGroupMaxSelection(e,t)}getSeriesGroupMaxSelection(e,t){if(!t)return Ir(e)}};wn.TEMPLATE='<div class="ag-chart-data-wrapper ag-scrollable-container"></div>',gr([(0,vt.Autowired)("chartTranslationService")],wn.prototype,"chartTranslationService",2),gr([(0,vt.Autowired)("chartMenuService")],wn.prototype,"chartMenuService",2),gr([vt.PostConstruct],wn.prototype,"init",1);var Sn=wn,bn=class e extends kt.Component{constructor(e){super(),this.activeComps=[],this.params=e,this.chartOptions=e.chartMenuUtils.getChartOptions()}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.params.name||this.chartTranslationService.translate("font"),enabled:this.params.enabled,suppressEnabledCheckbox:!!this.params.suppressEnabledCheckbox,onEnableChange:e=>{this.params.onEnableChange&&this.params.onEnableChange(e)}};this.setTemplate(e.TEMPLATE,{fontGroup:t,familySelect:this.getFamilySelectParams(),weightStyleSelect:this.getWeightStyleSelectParams(),sizeSelect:this.getSizeSelectParams(),colorPicker:this.params.chartMenuUtils.getDefaultColorPickerParams(this.params.keyMapper("color"))})}addCompToPanel(e){this.fontGroup.addItem(e),this.activeComps.push(e)}setEnabled(e){this.fontGroup.setEnabled(e)}getFamilySelectParams(){const e=["Arial, sans-serif","Aria Black, sans-serif","Book Antiqua,  serif","Charcoal, sans-serif","Comic Sans MS, cursive","Courier, monospace","Courier New, monospace","Gadget, sans-serif","Geneva, sans-serif","Helvetica, sans-serif","Impact, sans-serif","Lucida Console, monospace","Lucida Grande, sans-serif","Lucida Sans Unicode,  sans-serif","Monaco, monospace","Palatino Linotype, serif","Palatino, serif","Times New Roman, serif","Times, serif","Verdana, sans-serif"],t=this.getInitialFontValue("fontFamily");let i=e[0];if(t){const r=e.map(e=>e.toLowerCase()).indexOf(t.toLowerCase());if(r>=0)i=e[r];else{const r=kt._.capitalise(t);e.push(r),i=r}}return{options:e.sort().map(e=>({value:e,text:e})),inputWidth:"flex",value:`${i}`,onValueChange:e=>this.setFont({fontFamily:e})}}getSizeSelectParams(){const e=[8,10,12,14,16,18,20,22,24,26,28,30,32,34,36],t=this.getInitialFontValue("fontSize");return kt._.includes(e,t)||e.push(t),{options:e.sort((e,t)=>e-t).map(e=>({value:`${e}`,text:`${e}`})),inputWidth:"flex",value:`${t}`,onValueChange:e=>this.setFont({fontSize:parseInt(e,10)}),label:this.chartTranslationService.translate("size")}}getWeightStyleSelectParams(){var e,t;const i=null!=(e=this.getInitialFontValue("fontWeight"))?e:"normal",r=null!=(t=this.getInitialFontValue("fontStyle"))?t:"normal",n=[{name:"normal",weight:"normal",style:"normal"},{name:"bold",weight:"bold",style:"normal"},{name:"italic",weight:"normal",style:"italic"},{name:"boldItalic",weight:"bold",style:"italic"}];let s=n.find(e=>e.weight===i&&e.style===r);return s||(s={name:"predefined",weight:i,style:r},n.unshift(s)),{options:n.map(e=>({value:e.name,text:this.chartTranslationService.translate(e.name)})),inputWidth:"flex",value:s.name,onValueChange:e=>{const t=n.find(t=>t.name===e);this.setFont({fontWeight:t.weight,fontStyle:t.style})}}}addItemToPanel(e){this.fontGroup.addItem(e),this.activeComps.push(e)}destroyActiveComps(){this.activeComps.forEach(e=>{kt._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActiveComps(),super.destroy()}setFont(e){const{keyMapper:t}=this.params;Object.entries(e).forEach(([e,i])=>{i&&this.chartOptions.setValue(t(e),i)})}getInitialFontValue(e){const{keyMapper:t}=this.params;return this.chartOptions.getValue(t(e))}};bn.TEMPLATE='<div class="ag-font-panel">\n            <ag-group-component ref="fontGroup">\n                <ag-select ref="familySelect"></ag-select>\n                <ag-select ref="weightStyleSelect"></ag-select>\n                <div class="ag-charts-font-size-color">\n                    <ag-select ref="sizeSelect"></ag-select>\n                    <ag-color-picker ref="colorPicker"></ag-color-picker>\n                </div>\n            </ag-group-component>\n        </div>',gr([(0,kt.RefSelector)("fontGroup")],bn.prototype,"fontGroup",2),gr([(0,kt.Autowired)("chartTranslationService")],bn.prototype,"chartTranslationService",2),gr([kt.PostConstruct],bn.prototype,"init",1);var En=bn,An=class e extends Ft.Component{constructor({chartMenuParamsFactory:e,isExpandedOnInit:t=!1}){super(),this.chartMenuUtils=e,this.isExpandedOnInit=t}init(){const t=this.chartMenuUtils.addEnableParams("legend.enabled",{cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("legend"),suppressEnabledCheckbox:!1,suppressToggleExpandOnEnableChange:!0,expanded:this.isExpandedOnInit,items:[this.createLabelPanel()]});this.setTemplate(e.TEMPLATE,{legendGroup:t,legendPositionSelect:this.chartMenuUtils.getDefaultLegendParams("legend.position"),legendPaddingSlider:this.getSliderParams("spacing","spacing",200),markerSizeSlider:this.getSliderParams("item.marker.size","markerSize",40),markerStrokeSlider:this.getSliderParams("item.marker.strokeWidth","markerStroke",10),markerPaddingSlider:this.getSliderParams("item.marker.padding","itemSpacing",20),itemPaddingXSlider:this.getSliderParams("item.paddingX","layoutHorizontalSpacing",50),itemPaddingYSlider:this.getSliderParams("item.paddingY","layoutVerticalSpacing",50)})}getSliderParams(e,t,i){return this.chartMenuUtils.getDefaultSliderParams(`legend.${e}`,t,i)}createLabelPanel(){const e={enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`legend.item.label.${e}`};return this.createManagedBean(new En(e))}};An.TEMPLATE='<div>\n            <ag-group-component ref="legendGroup">\n                <ag-select ref="legendPositionSelect"></ag-select>\n                <ag-slider ref="legendPaddingSlider"></ag-slider>\n                <ag-slider ref="markerSizeSlider"></ag-slider>\n                <ag-slider ref="markerStrokeSlider"></ag-slider>\n                <ag-slider ref="markerPaddingSlider"></ag-slider>\n                <ag-slider ref="itemPaddingXSlider"></ag-slider>\n                <ag-slider ref="itemPaddingYSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Ft.Autowired)("chartTranslationService")],An.prototype,"chartTranslationService",2),gr([Ft.PostConstruct],An.prototype,"init",1);var Tn=An,Mn=class e extends Vt.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t=this.chartMenuUtils.addEnableParams("tick.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("ticks"),suppressEnabledCheckbox:!1}),i=this.chartMenuUtils.getDefaultColorPickerParams("tick.color"),r=this.chartMenuUtils.getDefaultSliderParams("tick.width","width",10),n=this.chartMenuUtils.getDefaultSliderParams("tick.size","length",30);this.setTemplate(e.TEMPLATE,{axisTicksGroup:t,axisTicksColorPicker:i,axisTicksWidthSlider:r,axisTicksSizeSlider:n})}};Mn.TEMPLATE='<div>\n            <ag-group-component ref="axisTicksGroup">\n                <ag-color-picker ref="axisTicksColorPicker"></ag-color-picker>\n                <ag-slider ref="axisTicksWidthSlider"></ag-slider>\n                <ag-slider ref="axisTicksSizeSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Vt.Autowired)("chartTranslationService")],Mn.prototype,"chartTranslationService",2),gr([Vt.PostConstruct],Mn.prototype,"init",1);var Rn=Mn,_n=class e extends Ht.Component{constructor(e){super(),this.chartMenuUtils=e,this.chartOptions=e.getChartOptions()}init(){const t=this.chartMenuUtils.addEnableParams("gridLine.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("gridLines"),suppressEnabledCheckbox:!1}),i=this.getGridLineColorPickerParams("color"),r=this.getGridLineWidthSliderParams("thickness"),n=this.getGridLineDashSliderParams("lineDash");this.setTemplate(e.TEMPLATE,{gridLineGroup:t,gridLineColorPicker:i,gridLineWidthSlider:r,gridLineLineDashSlider:n})}getGridLineColorPickerParams(e){return this.chartMenuUtils.getDefaultColorPickerParams("gridLine.style",e,{formatInputValue:e=>{var t;return null==(t=null==e?void 0:e[0])?void 0:t.stroke},parseInputValue:e=>{var t;const i=null!=(t=this.chartOptions.getValue("gridLine.style"))?t:[];return 0===i.length?[{stroke:e,lineDash:[]}]:[dr(hr({},i[0]),{stroke:e})]}})}getGridLineWidthSliderParams(e){return this.chartMenuUtils.getDefaultSliderParams("gridLine.width",e,10)}getGridLineDashSliderParams(e){var t,i;const r=this.chartOptions.getValue("gridLine.style"),n=null==(i=null==(t=null==r?void 0:r[0])?void 0:t.lineDash)?void 0:i[0],s=this.chartMenuUtils.getDefaultSliderParamsWithoutValueParams(null!=n?n:0,e,30);return s.onValueChange=e=>{const t=this.chartOptions.getValue("gridLine.style.0.stroke");this.chartOptions.setValue("gridLine.style",[{lineDash:[e],stroke:t}])},s}};_n.TEMPLATE='<div>\n            <ag-group-component ref="gridLineGroup">\n                <ag-color-picker ref="gridLineColorPicker"></ag-color-picker>\n                <ag-slider ref="gridLineWidthSlider"></ag-slider>\n                <ag-slider ref="gridLineLineDashSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Ht.Autowired)("chartTranslationService")],_n.prototype,"chartTranslationService",2),gr([Ht.PostConstruct],_n.prototype,"init",1);var Pn=_n,xn=class e extends Bt.AgAbstractLabel{constructor(t){super(t,e.TEMPLATE),this.radius=0,this.offsetX=0,this.offsetY=0}postConstruct(){super.postConstruct();const{value:e,onValueChange:t}=this.config;null!=e&&this.setValue(e,void 0,!0),null!=t&&this.onValueChange(t),this.dragListener={eElement:this.eParentCircle,dragStartPixels:0,onDragStart:e=>{this.parentCircleRect=this.eParentCircle.getBoundingClientRect()},onDragging:e=>this.calculateAngleDrag(e),onDragStop:()=>{}},this.dragService.addDragSource(this.dragListener),this.eAngleValue.setLabel("").setLabelWidth(5).setInputWidth(45).setMin(0).setMax(360).setValue(`${this.degrees}`).onValueChange(e=>{null!=e&&""!==e||(e="0"),e=this.eAngleValue.normalizeValue(e);let t=parseFloat(e);t>180&&(t-=360),this.setValue(t)}),this.updateNumberInput(),Bt._.exists(this.getValue())&&this.eAngleValue.setValue(this.normalizeNegativeValue(this.getValue()).toString()),this.addManagedListener(this,Bt.Events.EVENT_FIELD_VALUE_CHANGED,()=>{this.eAngleValue.getInputElement().contains(this.gos.getActiveDomElement())||this.updateNumberInput()})}updateNumberInput(){const e=this.normalizeNegativeValue(this.getValue());this.eAngleValue.setValue(e.toString())}positionChildCircle(e){const t=this.parentCircleRect||{width:24,height:24},i=this.eChildCircle,r=t.width/2,n=t.height/2;i.style.left=`${r+8*Math.cos(e)}px`,i.style.top=`${n+8*Math.sin(e)}px`}calculatePolar(){const e=this.offsetX,t=this.offsetY,i=Math.atan2(t,e);this.degrees=this.toDegrees(i),this.radius=Math.sqrt(e*e+t*t),this.positionChildCircle(i)}calculateCartesian(){const e=this.toRadians(this.getValue()),t=this.getRadius();this.setOffsetX(Math.cos(e)*t).setOffsetY(Math.sin(e)*t)}setOffsetX(e){return this.offsetX!==e&&(this.offsetX=e,this.calculatePolar()),this}setOffsetY(e){return this.offsetY!==e&&(this.offsetY=e,this.calculatePolar()),this}calculateAngleDrag(e){const t=this.parentCircleRect,i=t.width/2,r=t.height/2,n=e.clientX-t.left-i,s=e.clientY-t.top-r,o=Math.atan2(s,n);this.setValue(o,!0)}toDegrees(e){return e/Math.PI*180}toRadians(e){return e/180*Math.PI}normalizeNegativeValue(e){return e<0?360+e:e}normalizeAngle180(e){return(e%=2*Math.PI)<-Math.PI?e+=2*Math.PI:e>=Math.PI&&(e-=2*Math.PI),e}getRadius(){return this.radius}setRadius(e){return this.radius===e||(this.radius=e,this.calculateCartesian()),this}onValueChange(e){return this.addManagedListener(this,Bt.Events.EVENT_FIELD_VALUE_CHANGED,()=>{e(this.degrees)}),this}getValue(e){return e?this.toRadians(this.degrees):this.degrees}setValue(e,t,i){let r;return r=t?e:this.normalizeAngle180(this.toRadians(e)),e=this.toDegrees(r),this.degrees!==e&&(this.degrees=Math.floor(e),this.calculateCartesian(),this.positionChildCircle(r),i||this.dispatchEvent({type:Bt.Events.EVENT_FIELD_VALUE_CHANGED})),this}setWidth(e){return Bt._.setFixedWidth(this.getGui(),e),this}setDisabled(e){return super.setDisabled(e),this.eAngleValue.setDisabled(e),this}destroy(){this.dragService.removeDragSource(this.dragListener),super.destroy()}};xn.TEMPLATE='<div class="ag-angle-select">\n            <div ref="eLabel"></div>\n            <div class="ag-wrapper ag-angle-select-wrapper">\n                <div ref="eAngleSelectField" class="ag-angle-select-field">\n                    <div ref="eParentCircle" class="ag-angle-select-parent-circle">\n                        <div ref="eChildCircle" class="ag-angle-select-child-circle"></div>\n                    </div>\n                </div>\n                <ag-input-number-field ref="eAngleValue"></ag-input-number-field>\n            </div>\n        </div>',gr([(0,Bt.RefSelector)("eLabel")],xn.prototype,"eLabel",2),gr([(0,Bt.RefSelector)("eParentCircle")],xn.prototype,"eParentCircle",2),gr([(0,Bt.RefSelector)("eChildCircle")],xn.prototype,"eChildCircle",2),gr([(0,Bt.RefSelector)("eAngleValue")],xn.prototype,"eAngleValue",2),gr([(0,Bt.Autowired)("dragService")],xn.prototype,"dragService",2);var Dn=xn,In=class extends zt.BeanStub{constructor(e){super(),this.chartOptionsProxy=e}getDefaultColorPickerParams(e,t,i){return this.addValueParams(e,{label:this.chartTranslationService.translate(null!=t?t:"color"),labelWidth:"flex",inputWidth:"flex"},i)}getDefaultNumberInputParams(e,t,i){return this.addValueParams(e,{label:this.chartTranslationService.translate(t),labelWidth:"flex",inputWidth:"flex",precision:null==i?void 0:i.precision,step:null==i?void 0:i.step,min:null==i?void 0:i.min,max:null==i?void 0:i.max},{parseInputValue:e=>{const t=Number(e);return isNaN(t)?void 0:t},formatInputValue:e=>null==e?"":`${e}`})}getDefaultSliderParams(e,t,i,r){var n;let s=null!=(n=this.chartOptionsProxy.getValue(e))?n:0;r&&Array.isArray(s)&&(s=s[0]);const o=this.getDefaultSliderParamsWithoutValueParams(s,t,i);return o.onValueChange=t=>this.chartOptionsProxy.setValue(e,r?[t]:t),o}getDefaultSliderParamsWithoutValueParams(e,t,i){return{label:this.chartTranslationService.translate(t),minValue:0,maxValue:Math.max(e,i),textFieldWidth:45,value:`${e}`}}getDefaultCheckboxParams(e,t,i){const r=this.chartOptionsProxy.getValue(e),n={label:this.chartTranslationService.translate(t),value:r,readOnly:null==i?void 0:i.readOnly,passive:null==i?void 0:i.passive};return n.onValueChange=t=>{this.chartOptionsProxy.setValue(e,"boolean"==typeof t?t:void 0)},n}getDefaultSelectParams(e,t,i,r){const n=this.chartOptionsProxy.getValue(e),s={label:this.chartTranslationService.translate(t),value:n,options:i,pickerType:null==r?void 0:r.pickerType,pickerAriaLabelKey:null==r?void 0:r.pickerAriaLabelKey,pickerAriaLabelValue:null==r?void 0:r.pickerAriaLabelValue};return s.onValueChange=t=>{this.chartOptionsProxy.setValue(e,t)},s}getDefaultLegendParams(e){return this.addValueParams(e,{label:this.chartTranslationService.translate("position"),labelWidth:"flex",inputWidth:"flex",options:["top","right","bottom","left"].map(e=>({value:e,text:this.chartTranslationService.translate(e)}))})}getDefaultFontPanelParams(e,t){const i=t=>`${e}.${t}`;return this.addEnableParams(i("enabled"),{name:this.chartTranslationService.translate(t),suppressEnabledCheckbox:!1,chartMenuUtils:this,keyMapper:i})}addValueParams(e,t,i){const r=this.chartOptionsProxy.getValue(e);return t.value=(null==i?void 0:i.formatInputValue)?i.formatInputValue(r):r,t.onValueChange=t=>{const r=(null==i?void 0:i.parseInputValue)?i.parseInputValue(t):t;this.chartOptionsProxy.setValue(e,r)},t}addEnableParams(e,t){var i;return t.enabled=null!=(i=this.chartOptionsProxy.getValue(e))&&i,t.onEnableChange=t=>this.chartOptionsProxy.setValue(e,t),t}getChartOptions(){return this.chartOptionsProxy}};gr([(0,zt.Autowired)("chartTranslationService")],In.prototype,"chartTranslationService",2);var Ln=class e extends Gt.Component{constructor(e,{chartController:t,chartOptionsService:i,isExpandedOnInit:r=!1,seriesType:n}){super(),this.activePanels=[],this.axisLabelUpdateFuncs=[],this.axisType=e,this.chartController=t,this.chartAxisOptionsProxy=i.getCartesianAxisOptionsProxy(e),this.chartAxisThemeOverridesProxy=i.getCartesianAxisThemeOverridesProxy(e),this.chartAxisAppliedThemeOverridesProxy=i.getCartesianAxisAppliedThemeOverridesProxy(e),this.chartOptionsSeriesProxy=i.getSeriesOptionsProxy(()=>null!=n?n:this.chartController.getChartSeriesType()),this.chartOptionsService=i,this.isExpandedOnInit=r}init(){var t;const i=this.axisType,r={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate(i),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0},n=this.createManagedBean(new In(this.chartAxisOptionsProxy)),s=this.createManagedBean(new In(this.chartAxisThemeOverridesProxy)),o=this.getAxisTypeSelectParams(n,this.chartAxisAppliedThemeOverridesProxy),a=this.getAxisPositionSelectParams(n),l=this.getAxisTimeFormatSelectParams(n),c=this.getAxisColorInputParams(s),u=this.getAxisLineWidthSliderParams(s);this.setTemplate(e.TEMPLATE,{axisGroup:r,axisTypeSelect:null!=o?o:void 0,axisPositionSelect:null!=a?a:void 0,axisTimeFormatSelect:null!=l?l:void 0,axisColorInput:c,axisLineWidthSlider:u}),this.axisTypeSelect.setDisplayed(!!(null==(t=o.options)?void 0:t.length)),a||this.removeTemplateComponent(this.axisPositionSelect);const h=()=>{const e="time"===this.chartAxisOptionsProxy.getValue("type");Gt._.setDisplayed(this.axisTimeFormatSelect.getGui(),e)};l?(h(),this.addManagedListener(this.eventService,Gt.Events.EVENT_CHART_OPTIONS_CHANGED,e=>{h()})):this.removeTemplateComponent(this.axisTimeFormatSelect),this.initGridLines(s),this.initAxisTicks(s),this.initAxisLabels(s),this.addManagedListener(this.chartController,sn.EVENT_CHART_UPDATED,()=>this.axisLabelUpdateFuncs.forEach(e=>e())),this.addManagedListener(this.chartController,sn.EVENT_CHART_MODEL_UPDATE,()=>setTimeout(()=>{this.refreshAxisTypeSelect(n),h()}))}getAxisTypeSelectParams(e,t){const i=e.getChartOptions(),r=this.getAxisTypeSelectOptions(),n=e.getDefaultSelectParams("type","axisType",r);return n.onValueChange=e=>{var r;const n=i.getValue("type");if(e===n)return;const s=t.getValue("*"),o="time"===e,a="time"===n!==o?o?"%d %B %Y":void 0:null;if(this.chartOptionsService.setCartesianCategoryAxisType(this.axisType,e),null!==a){const e=null!=(r=i.getValue("label"))?r:{};i.setValue("label",dr(hr({},e),{format:a}))}t.setValue("*",s)},n}refreshAxisTypeSelect(e){const t=this.getAxisTypeSelectOptions(),i=!!t.length;this.axisTypeSelect.setDisplayed(i),i&&this.axisTypeSelect.clearOptions().addOptions(t).setValue(e.getChartOptions().getValue("type"))}getAxisTypeSelectOptions(){const e=this.chartController.getChartType();return["heatmap","histogram","boxPlot","rangeBar","scatter","bubble"].includes(e)||this.chartController.isGrouping()||!this.isCategoryAxis()||this.chartController.isCategorySeriesSwitched()||!(()=>{const e=this.chartController.getChartData()[0];return!!e&&this.chartController.getSelectedDimensions().every(t=>!isNaN(parseFloat(e[t.colId])))})()?[]:["category","number","time"].map(e=>({value:e,text:this.translate(e)}))}isCategoryAxis(){const e="horizontal"===this.chartOptionsSeriesProxy.getValue("direction");return e&&"yAxis"===this.axisType||!e&&"xAxis"===this.axisType}getAxisPositionSelectParams(e){const t=((e,t)=>{if("heatmap"===e)return null;switch(t){case"xAxis":return[{value:"top",text:this.translate("top")},{value:"bottom",text:this.translate("bottom")}];case"yAxis":return[{value:"left",text:this.translate("left")},{value:"right",text:this.translate("right")}]}})(this.chartController.getChartType(),this.axisType);return t?e.getDefaultSelectParams("position","position",t):null}getAxisTimeFormatSelectParams(e){if(!this.isCategoryAxis())return null;const t=[{value:"%d/%m/%Y",text:this.translate("timeFormatSlashesDDMMYYYY")},{value:"%m/%d/%Y",text:this.translate("timeFormatSlashesMMDDYYYY")},{value:"%d/%m/%y",text:this.translate("timeFormatSlashesDDMMYY")},{value:"%m/%d/%y",text:this.translate("timeFormatSlashesMMDDYY")},{value:"%d.%e.%y",text:this.translate("timeFormatDotsDDMYY")},{value:"%e.%d.%y",text:this.translate("timeFormatDotsMDDYY")},{value:"%Y-%m-%d",text:this.translate("timeFormatDashesYYYYMMDD")},{value:"%d %B %Y",text:this.translate("timeFormatSpacesDDMMMMYYYY")},{value:"%H:%M:%S",text:this.translate("timeFormatHHMMSS")},{value:"%I:%M:%S %p",text:this.translate("timeFormatHHMMSSAmPm")}];return e.getDefaultSelectParams("label.format","timeFormat",t)}getAxisColorInputParams(e){return e.getDefaultColorPickerParams("line.color")}getAxisLineWidthSliderParams(e){var t;const i=e.getChartOptions(),r=e.getDefaultSliderParamsWithoutValueParams(null!=(t=i.getValue("line.enabled")?i.getValue("line.width"):null)?t:0,"thickness",10);return r.onValueChange=e=>{var t;t=0===e?null:e,i.setValues([{expression:"line.enabled",value:null!=t},{expression:"line.width",value:null!=t?t:0}])},r}initGridLines(e){if("heatmap"!==this.chartController.getChartType()){const t=this.createBean(new Pn(e));this.axisGroup.addItem(t),this.activePanels.push(t)}}initAxisTicks(e){if(!this.hasConfigurableAxisTicks())return;const t=this.createBean(new Rn(e));this.axisGroup.addItem(t),this.activePanels.push(t)}hasConfigurableAxisTicks(){switch(this.chartController.getChartType()){case"radarLine":case"radarArea":case"rangeBar":case"boxPlot":case"waterfall":return!1;default:return!0}}initAxisLabels(e){const t={name:this.translate("labels"),enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:e,keyMapper:e=>`label.${e}`},i=this.createBean(new En(t));this.axisGroup.addItem(i),this.activePanels.push(i),this.addAdditionalLabelComps(i,e)}addAdditionalLabelComps(e,t){this.addLabelPadding(e,t);const i=this.createRotationWidget("labelRotation",t),r=this.initLabelRotation(i,t);e.addCompToPanel(r),e.addCompToPanel(i)}initLabelRotation(e,t){const i=t.getChartOptions(),r=()=>i.getValue("label.rotation"),n="number"!=typeof r()&&i.getValue("label.autoRotate"),s=this.createBean(new Gt.AgCheckbox({label:this.translate("autoRotate"),value:n,onValueChange:t=>{t&&(this.prevRotation=r()),i.setValues([{expression:"label.autoRotate",value:t},{expression:"label.rotation",value:t?void 0:this.prevRotation}]),e.setDisabled(t)}}));return e.setDisabled(n),s}createRotationWidget(e,t){var i;const r=t.getChartOptions(),n=()=>r.getValue("label.rotation"),s=String.fromCharCode(176),o=`${this.chartTranslationService.translate(e)} ${s}`,a=new Dn({label:o,labelWidth:"flex",value:null!=(i=n())?i:0,onValueChange:e=>r.setValue("label.rotation",e)});return this.axisLabelUpdateFuncs.push(()=>{var e;a.setValue(null!=(e=n())?e:0)}),this.createBean(a)}addLabelPadding(e,t){const i=this.createBean(new Gt.AgSlider(t.getDefaultSliderParams("label.padding","padding",30)));e.addCompToPanel(i)}translate(e){return this.chartTranslationService.translate(e)}removeTemplateComponent(e){Gt._.removeFromParent(e.getGui()),this.destroyBean(e)}destroyActivePanels(){this.activePanels.forEach(e=>{Gt._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};Ln.TEMPLATE='<div>\n            <ag-group-component ref="axisGroup">\n                <ag-select ref="axisTypeSelect"></ag-select>\n                <ag-select ref="axisTimeFormatSelect"></ag-select>\n                <ag-select ref="axisPositionSelect"></ag-select>\n                <ag-color-picker ref="axisColorInput"></ag-color-picker>\n                <ag-slider ref="axisLineWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Gt.RefSelector)("axisGroup")],Ln.prototype,"axisGroup",2),gr([(0,Gt.RefSelector)("axisTypeSelect")],Ln.prototype,"axisTypeSelect",2),gr([(0,Gt.RefSelector)("axisPositionSelect")],Ln.prototype,"axisPositionSelect",2),gr([(0,Gt.RefSelector)("axisTimeFormatSelect")],Ln.prototype,"axisTimeFormatSelect",2),gr([(0,Gt.Autowired)("chartTranslationService")],Ln.prototype,"chartTranslationService",2),gr([Gt.PostConstruct],Ln.prototype,"init",1);var Nn=Ln,On=class e extends Ut.Component{constructor({chartController:e,chartAxisMenuParamsFactory:t,isExpandedOnInit:i=!1}){super(),this.chartController=e,this.chartMenuUtils=t,this.isExpandedOnInit=i}init(){const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate("polarAxis"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0},i=this.chartMenuUtils.getDefaultColorPickerParams("line.color"),r=this.chartMenuUtils.getDefaultSliderParams("line.width","thickness",10);this.setTemplate(e.TEMPLATE,{axisGroup:t,axisColorInput:i,axisLineWidthSlider:r}),this.initAxis(),this.initAxisLabels(),this.initRadiusAxis()}initAxis(){const e=this.chartController.getChartType();if(["radarLine","radarArea"].includes(e)){const e=[{value:"circle",text:this.translate("circle")},{value:"polygon",text:this.translate("polygon")}];this.axisGroup.addItem(this.createSelect({labelKey:"shape",options:e,property:"shape"}))}"pie"!==e&&this.axisGroup.addItem(this.createSlider({labelKey:"innerRadius",defaultMaxValue:1,property:"innerRadiusRatio"}))}initAxisLabels(){const e={name:this.translate("labels"),enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`label.${e}`},t=this.createManagedBean(new En(e)),i=this.createOrientationWidget();t.addItemToPanel(i),this.axisGroup.addItem(t)}createOrientationWidget(){const e=[{value:"fixed",text:this.translate("fixed")},{value:"parallel",text:this.translate("parallel")},{value:"perpendicular",text:this.translate("perpendicular")}];return this.createSelect({labelKey:"orientation",options:e,property:"label.orientation"})}initRadiusAxis(){if(!br(Pr(this.chartController.getChartType()),"isRadial"))return;const e=[this.createSlider({labelKey:"groupPadding",defaultMaxValue:1,property:"paddingInner"}),this.createSlider({labelKey:"seriesPadding",defaultMaxValue:1,property:"groupPaddingInner"})],t=this.createManagedBean(new Ut.AgGroupComponent({cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,enabled:!0,suppressEnabledCheckbox:!0,title:this.translate("padding"),items:e})).hideEnabledCheckbox(!0).hideOpenCloseIcons(!0);this.axisGroup.addItem(t)}createSlider(e){const{labelKey:t,defaultMaxValue:i,step:r=.05,property:n}=e,s=this.chartMenuUtils.getDefaultSliderParams(n,t,i);return s.step=r,this.createManagedBean(new Ut.AgSlider(s))}createSelect(e){const{labelKey:t,options:i,property:r}=e;return this.createManagedBean(new Ut.AgSelect(this.chartMenuUtils.addValueParams(r,{label:this.chartTranslationService.translate(t),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:i})))}translate(e){return this.chartTranslationService.translate(e)}};On.TEMPLATE='<div>\n            <ag-group-component ref="axisGroup">\n                <ag-color-picker ref="axisColorInput"></ag-color-picker>\n                <ag-slider ref="axisLineWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Ut.RefSelector)("axisGroup")],On.prototype,"axisGroup",2),gr([(0,Ut.Autowired)("chartTranslationService")],On.prototype,"chartTranslationService",2),gr([Ut.PostConstruct],On.prototype,"init",1);var Fn=On,kn=class e extends jt.Component{constructor(e,t){super(),this.chartMenuUtils=e,this.chartController=t}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("padding"),suppressEnabledCheckbox:!0},i=e=>this.chartMenuUtils.getDefaultSliderParams("padding."+e,e,200);this.setTemplate(e.TEMPLATE,{chartPaddingGroup:t,paddingTopSlider:i("top"),paddingRightSlider:i("right"),paddingBottomSlider:i("bottom"),paddingLeftSlider:i("left")}),this.addManagedListener(this.eventService,jt.Events.EVENT_CHART_OPTIONS_CHANGED,e=>{this.updateTopPadding(e.chartOptions)})}updateTopPadding(e){const t=[...this.chartController.getChartSeriesTypes(),"common"].map(t=>{var i,r;return null==(r=null==(i=e[t])?void 0:i.padding)?void 0:r.top}).find(e=>null!=e);null!=t&&this.paddingTopSlider.setValue(`${t}`)}};kn.TEMPLATE='<div>\n            <ag-group-component ref="chartPaddingGroup">\n                <ag-slider ref="paddingTopSlider"></ag-slider>\n                <ag-slider ref="paddingRightSlider"></ag-slider>\n                <ag-slider ref="paddingBottomSlider"></ag-slider>\n                <ag-slider ref="paddingLeftSlider"></ag-slider>\n            </ag-group-component>\n        <div>',gr([(0,jt.RefSelector)("paddingTopSlider")],kn.prototype,"paddingTopSlider",2),gr([(0,jt.Autowired)("chartTranslationService")],kn.prototype,"chartTranslationService",2),gr([jt.PostConstruct],kn.prototype,"init",1);var Gn=kn,Vn=class e extends Kt.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t=this.chartMenuUtils.addEnableParams("background.visible",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("background"),suppressEnabledCheckbox:!1}),i=this.chartMenuUtils.getDefaultColorPickerParams("background.fill");this.setTemplate(e.TEMPLATE,{chartBackgroundGroup:t,colorPicker:i})}};Vn.TEMPLATE='<div>\n            <ag-group-component ref="chartBackgroundGroup">\n                <ag-color-picker ref="colorPicker"></ag-color-picker>\n            </ag-group-component>\n        <div>',gr([(0,Kt.Autowired)("chartTranslationService")],Vn.prototype,"chartTranslationService",2),gr([Kt.PostConstruct],Vn.prototype,"init",1);var Hn=Vn,Bn=class e extends $t.Component{constructor(t,i){super(e.TEMPLATE),this.chartMenuUtils=t,this.chartController=i,this.activePanels=[],this.chartOptions=t.getChartOptions()}init(){this.initFontPanel(),this.titlePlaceholder=this.chartTranslationService.translate("titlePlaceholder")}hasTitle(){const e=this.chartOptions.getValue("title");return e&&e.enabled&&e.text&&e.text.length>0}initFontPanel(){const e=this.hasTitle(),t={name:this.chartTranslationService.translate("title"),enabled:e,suppressEnabledCheckbox:!1,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`title.${e}`,onEnableChange:e=>{if(this.chartMenuService.doesChartToolbarExist(this.chartController)){const t=this.chartOptions.getValue("padding.top");this.chartOptions.setValue("padding.top",e?t-20:t+20)}this.chartOptions.setValue("title.enabled",e);const t=this.chartOptions.getValue("title.text"),i="Title"===t||0===(null==t?void 0:t.trim().length);e&&i&&this.chartOptions.setValue("title.text",this.titlePlaceholder)}},i=this.createBean(new En(t));i.addItemToPanel(this.createSpacingSlicer()),this.getGui().appendChild(i.getGui()),this.activePanels.push(i),this.addManagedListener(this.eventService,"chartTitleEdit",()=>{i.setEnabled(this.hasTitle())})}createSpacingSlicer(){const e=this.chartMenuUtils.getDefaultSliderParams("title.spacing","spacing",100);return e.value="10",this.createBean(new $t.AgSlider(e))}destroyActivePanels(){this.activePanels.forEach(e=>{$t._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};Bn.TEMPLATE="<div></div>",gr([(0,$t.Autowired)("chartTranslationService")],Bn.prototype,"chartTranslationService",2),gr([(0,$t.Autowired)("chartMenuService")],Bn.prototype,"chartMenuService",2),gr([$t.PostConstruct],Bn.prototype,"init",1);var zn=Bn,Un=class e extends Wt.Component{constructor({chartController:e,chartMenuParamsFactory:t,isExpandedOnInit:i=!1,chartOptionsService:r,seriesType:n}){super(),this.chartController=e,this.chartMenuParamsFactory=t,this.chartOptionsSeriesProxy=r.getSeriesOptionsProxy(()=>null!=n?n:this.chartController.getChartSeriesType()),this.isExpandedOnInit=i}init(){this.chartSeriesMenuParamsFactory=this.createManagedBean(new In(this.chartOptionsSeriesProxy));const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("chart"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0,items:[this.createManagedBean(new zn(this.chartMenuParamsFactory,this.chartController)),this.createManagedBean(new Gn(this.chartMenuParamsFactory,this.chartController)),this.createManagedBean(new Hn(this.chartMenuParamsFactory)),...this.createDirectionSelect()]};this.setTemplate(e.TEMPLATE,{chartGroup:t}),this.addManagedListener(this.eventService,Wt.Events.EVENT_CHART_OPTIONS_CHANGED,()=>this.refresh())}refresh(){this.updateDirectionSelect()}createDirectionSelect(){if(this.chartMenuService.isLegacyFormat())return[];const e=["horizontal","vertical"].map(e=>({value:e,text:this.chartTranslationService.translate(e)})),t=this.chartSeriesMenuParamsFactory.getDefaultSelectParams("direction","direction",e);t.labelWidth="flex",t.inputWidth="flex";const i=t.onValueChange;return t.onValueChange=e=>{i(e),this.chartController.raiseChartModelUpdateEvent()},this.directionSelect=this.createManagedBean(new Wt.AgSelect(t)),this.updateDirectionSelect(),[this.directionSelect]}updateDirectionSelect(){var e;null==(e=this.directionSelect)||e.setDisplayed(br(Pr(this.chartController.getChartType()),"canSwitchDirection"))}};Un.TEMPLATE='<div>\n            <ag-group-component ref="chartGroup"></ag-group-component>\n        </div>',gr([(0,Wt.Autowired)("chartTranslationService")],Un.prototype,"chartTranslationService",2),gr([(0,Wt.Autowired)("chartMenuService")],Un.prototype,"chartMenuService",2),gr([Wt.PostConstruct],Un.prototype,"init",1);var Wn=Un,jn=class e extends Yt.Component{constructor(e,t="shadow"){super(),this.chartMenuUtils=e,this.propertyKey=t}init(){const t=this.propertyKey,i=this.chartMenuUtils.addEnableParams(`${t}.enabled`,{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("shadow"),suppressEnabledCheckbox:!1}),r=this.chartMenuUtils.getDefaultColorPickerParams(`${t}.color`);this.setTemplate(e.TEMPLATE,{shadowGroup:i,shadowColorPicker:r,shadowBlurSlider:this.getSliderParams("blur",0,20),shadowXOffsetSlider:this.getSliderParams("xOffset",-10,10),shadowYOffsetSlider:this.getSliderParams("yOffset",-10,10)})}getSliderParams(e,t,i){const r=`${this.propertyKey}.${e}`,n=this.chartMenuUtils.getDefaultSliderParams(r,e,i);return n.minValue=t,n}};jn.TEMPLATE='<div>\n            <ag-group-component ref="shadowGroup">\n                <ag-color-picker ref="shadowColorPicker"></ag-color-picker>\n                <ag-slider ref="shadowBlurSlider"></ag-slider>\n                <ag-slider ref="shadowXOffsetSlider"></ag-slider>\n                <ag-slider ref="shadowYOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Yt.Autowired)("chartTranslationService")],jn.prototype,"chartTranslationService",2),gr([Yt.PostConstruct],jn.prototype,"init",1);var Kn=jn,$n=class e extends Qt.Component{constructor(e,t){super(),this.chartOptionsService=e,this.chartMenuUtils=t}init(){const t=this.chartOptionsService.getChartType(),i=Qt._.includes(["scatter","bubble"],t),r=this.chartMenuUtils.addEnableParams("marker.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("markers"),suppressEnabledCheckbox:i,suppressOpenCloseIcons:!0}),n="bubble"===t;let s,o;n?(s=this.getSliderParams("marker.maxSize","maxSize",60),o=this.getSliderParams("marker.size","minSize",60)):(s={},o=this.getSliderParams("marker.size","size",60)),this.setTemplate(e.TEMPLATE,{seriesMarkersGroup:r,seriesMarkerShapeSelect:this.getMarkerShapeSelectParams(),seriesMarkerMinSizeSlider:s,seriesMarkerSizeSlider:o,seriesMarkerStrokeWidthSlider:this.getSliderParams("marker.strokeWidth","strokeWidth",10)}),n||this.seriesMarkerMinSizeSlider.setDisplayed(!1)}getMarkerShapeSelectParams(){return this.chartMenuUtils.addValueParams("marker.shape",{options:[{value:"square",text:"Square"},{value:"circle",text:"Circle"},{value:"cross",text:"Cross"},{value:"diamond",text:"Diamond"},{value:"plus",text:"Plus"},{value:"triangle",text:"Triangle"},{value:"heart",text:"Heart"}],label:this.chartTranslationService.translate("shape")})}getSliderParams(e,t,i){return this.chartMenuUtils.getDefaultSliderParams(e,t,i)}};$n.TEMPLATE='<div>\n            <ag-group-component ref="seriesMarkersGroup">\n                <ag-select ref="seriesMarkerShapeSelect"></ag-select>\n                <ag-slider ref="seriesMarkerMinSizeSlider"></ag-slider>\n                <ag-slider ref="seriesMarkerSizeSlider"></ag-slider>\n                <ag-slider ref="seriesMarkerStrokeWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,Qt.RefSelector)("seriesMarkerMinSizeSlider")],$n.prototype,"seriesMarkerMinSizeSlider",2),gr([(0,Qt.Autowired)("chartTranslationService")],$n.prototype,"chartTranslationService",2),gr([Qt.PostConstruct],$n.prototype,"init",1);var qn=$n,Yn=class e extends Xt.Component{constructor(t){super(e.TEMPLATE),this.H=1,this.S=1,this.B=1,this.A=1,this.isSpectrumDragging=!1,this.isSpectrumHueDragging=!1,this.isSpectrumAlphaDragging=!1,this.colorChanged=!1,this.picker=t.picker}postConstruct(){this.initTabIndex(),this.initRecentColors(),this.addGuiEventListener("focus",()=>this.spectrumColor.focus()),this.addGuiEventListener("keydown",e=>{e.key!==Jt.KeyCode.ENTER||e.defaultPrevented||this.destroy()}),this.addManagedListener(this.spectrumColor,"keydown",e=>this.moveDragger(e)),this.addManagedListener(this.spectrumAlphaSlider,"keydown",e=>this.moveAlphaSlider(e)),this.addManagedListener(this.spectrumHueSlider,"keydown",e=>this.moveHueSlider(e)),this.addManagedListener(this.spectrumVal,"mousedown",this.onSpectrumDraggerDown.bind(this)),this.addManagedListener(this.spectrumHue,"mousedown",this.onSpectrumHueDown.bind(this)),this.addManagedListener(this.spectrumAlpha,"mousedown",this.onSpectrumAlphaDown.bind(this)),this.addGuiEventListener("mousemove",e=>{this.onSpectrumDraggerMove(e),this.onSpectrumHueMove(e),this.onSpectrumAlphaMove(e)}),this.addManagedListener(document,"mouseup",this.onMouseUp.bind(this)),this.addManagedListener(this.recentColors,"click",this.onRecentColorClick.bind(this)),this.addManagedListener(this.recentColors,"keydown",e=>{e.key!==Jt.KeyCode.ENTER&&e.key!==Jt.KeyCode.SPACE||(e.preventDefault(),this.onRecentColorClick(e))})}initTabIndex(){const e=this.tabIndex=this.gos.get("tabIndex").toString();this.spectrumColor.setAttribute("tabindex",e),this.spectrumHueSlider.setAttribute("tabindex",e),this.spectrumAlphaSlider.setAttribute("tabindex",e)}refreshSpectrumRect(){return this.spectrumValRect=this.spectrumVal.getBoundingClientRect()}refreshHueRect(){return this.spectrumHueRect=this.spectrumHue.getBoundingClientRect()}refreshAlphaRect(){return this.spectrumAlphaRect=this.spectrumAlpha.getBoundingClientRect()}onSpectrumDraggerDown(e){this.refreshSpectrumRect(),this.isSpectrumDragging=!0,this.moveDragger(e)}onSpectrumDraggerMove(e){this.isSpectrumDragging&&this.moveDragger(e)}onSpectrumHueDown(e){this.refreshHueRect(),this.isSpectrumHueDragging=!0,this.moveHueSlider(e)}onSpectrumHueMove(e){this.isSpectrumHueDragging&&this.moveHueSlider(e)}onSpectrumAlphaDown(e){this.refreshAlphaRect(),this.isSpectrumAlphaDragging=!0,this.moveAlphaSlider(e)}onSpectrumAlphaMove(e){this.isSpectrumAlphaDragging&&this.moveAlphaSlider(e)}onMouseUp(){this.isSpectrumDragging=!1,this.isSpectrumHueDragging=!1,this.isSpectrumAlphaDragging=!1}moveDragger(e){const t=this.spectrumValRect;if(!t)return;let i,r;if(e instanceof MouseEvent)i=e.clientX-t.left,r=e.clientY-t.top;else{const t=e.key===Jt.KeyCode.LEFT,n=e.key===Jt.KeyCode.RIGHT,s=e.key===Jt.KeyCode.UP,o=e.key===Jt.KeyCode.DOWN,a=s||o,l=t||n;if(!a&&!l)return;e.preventDefault();const{x:c,y:u}=this.getSpectrumValue();i=c+(l?t?-5:5:0),r=u+(a?s?-5:5:0)}i=Math.max(i,0),i=Math.min(i,t.width),r=Math.max(r,0),r=Math.min(r,t.height),this.setSpectrumValue(i/t.width,1-r/t.height)}moveHueSlider(e){const t=this.spectrumHueRect;if(!t)return;const i=this.moveSlider(this.spectrumHueSlider,e);null!=i&&(this.H=1-i/t.width,this.update())}moveAlphaSlider(e){const t=this.spectrumAlphaRect;if(!t)return;const i=this.moveSlider(this.spectrumAlphaSlider,e);null!=i&&(this.A=i/t.width,this.update())}moveSlider(e,t){var i;const r=e.getBoundingClientRect(),n=null==(i=e.parentElement)?void 0:i.getBoundingClientRect();if(!e||!n)return null;let s;if(t instanceof MouseEvent)s=t.clientX-n.left;else{const i=t.key===Jt.KeyCode.LEFT,n=t.key===Jt.KeyCode.RIGHT;if(!i&&!n)return null;t.preventDefault();const o=i?-5:5;s=parseFloat(e.style.left)-r.width/2+o}return s=Math.max(s,0),s=Math.min(s,n.width),e.style.left=s+r.width/2+"px",s}update(){const e=Zt._Util.Color.fromHSB(360*this.H,this.S,this.B,this.A),t=Zt._Util.Color.fromHSB(360*this.H,1,1),i=e.toRgbaString(),r=this.picker;Zt._Util.Color.fromString(r.getValue()).toRgbaString()!==i&&(this.colorChanged=!0),r.setValue(i),this.spectrumColor.style.backgroundColor=t.toRgbaString(),this.spectrumDragger.style.backgroundColor=i}setSpectrumValue(e,t){const i=this.spectrumValRect||this.refreshSpectrumRect();if(null==i)return;const r=this.spectrumDragger,n=r.getBoundingClientRect();e=Math.max(0,e),e=Math.min(1,e),t=Math.max(0,t),t=Math.min(1,t),this.S=e,this.B=t,r.style.left=e*i.width-n.width/2+"px",r.style.top=(1-t)*i.height-n.height/2+"px",this.update()}getSpectrumValue(){const e=this.spectrumDragger,t=e.getBoundingClientRect();return{x:parseFloat(e.style.left)+t.width/2,y:parseFloat(e.style.top)+t.height/2}}initRecentColors(){const t=e.recentColors.map((e,t)=>`<div class="ag-recent-color" id=${t} style="background-color: ${e}; width: 15px; height: 15px;" recent-color="${e}" tabIndex="${this.tabIndex}"></div>`);this.recentColors.innerHTML=t.join("")}setValue(e){const t=Zt._Util.Color.fromString(e),[i,r,n]=t.toHSB();this.H=(isNaN(i)?0:i)/360,this.A=t.a;const s=this.spectrumHueRect||this.refreshHueRect(),o=this.spectrumAlphaRect||this.refreshAlphaRect();this.spectrumHueSlider.style.left=(this.H-1)*-s.width+"px",this.spectrumAlphaSlider.style.left=this.A*o.width+"px",this.setSpectrumValue(r,n)}onRecentColorClick(t){const i=t.target;if(!Xt._.exists(i.id))return;const r=parseInt(i.id,10);this.setValue(e.recentColors[r]),this.destroy()}addRecentColor(){const t=Zt._Util.Color.fromHSB(360*this.H,this.S,this.B,this.A).toRgbaString();let i=e.recentColors;this.colorChanged&&i[0]!==t&&(i=i.filter(e=>e!=t),i=[t].concat(i),i.length>e.maxRecentColors&&(i=i.slice(0,e.maxRecentColors)),e.recentColors=i)}destroy(){this.addRecentColor(),super.destroy()}};Yn.maxRecentColors=8,Yn.recentColors=[],Yn.TEMPLATE='<div class="ag-color-panel" tabindex="-1">\n            <div ref="spectrumColor" class="ag-spectrum-color">\n                <div class="ag-spectrum-sat ag-spectrum-fill">\n                    <div ref="spectrumVal" class="ag-spectrum-val ag-spectrum-fill">\n                        <div ref="spectrumDragger" class="ag-spectrum-dragger"></div>\n                    </div>\n                </div>\n            </div>\n            <div class="ag-spectrum-tools">\n                <div ref="spectrumHue" class="ag-spectrum-hue ag-spectrum-tool">\n                    <div class="ag-spectrum-hue-background"></div>\n                    <div ref="spectrumHueSlider" class="ag-spectrum-slider"></div>\n                </div>\n                <div ref="spectrumAlpha" class="ag-spectrum-alpha ag-spectrum-tool">\n                    <div class="ag-spectrum-alpha-background"></div>\n                    <div ref="spectrumAlphaSlider" class="ag-spectrum-slider"></div>\n                </div>\n                <div ref="recentColors" class="ag-recent-colors"></div>\n            </div>\n        </div>',gr([(0,Xt.RefSelector)("spectrumColor")],Yn.prototype,"spectrumColor",2),gr([(0,Xt.RefSelector)("spectrumVal")],Yn.prototype,"spectrumVal",2),gr([(0,Xt.RefSelector)("spectrumDragger")],Yn.prototype,"spectrumDragger",2),gr([(0,Xt.RefSelector)("spectrumHue")],Yn.prototype,"spectrumHue",2),gr([(0,Xt.RefSelector)("spectrumHueSlider")],Yn.prototype,"spectrumHueSlider",2),gr([(0,Xt.RefSelector)("spectrumAlpha")],Yn.prototype,"spectrumAlpha",2),gr([(0,Xt.RefSelector)("spectrumAlphaSlider")],Yn.prototype,"spectrumAlphaSlider",2),gr([(0,Xt.RefSelector)("recentColors")],Yn.prototype,"recentColors",2),gr([Xt.PostConstruct],Yn.prototype,"postConstruct",1);var Qn=Yn,Xn=class extends ei.AgPickerField{constructor(e){super(hr({pickerAriaLabelKey:"ariaLabelColorPicker",pickerAriaLabelValue:"Color Picker",pickerType:"ag-list",className:"ag-color-picker",pickerIcon:"colorPicker"},e))}postConstruct(){super.postConstruct(),this.value&&this.setValue(this.value)}createPickerComponent(){const e=this.getGui().getBoundingClientRect();return this.createBean(new ei.AgDialog({closable:!1,modal:!0,hideTitleBar:!0,minWidth:190,width:190,height:250,x:e.right-190,y:e.top-250}))}renderAndPositionPicker(){const e=this.pickerComponent,t=this.createBean(new Qn({picker:this}));return e.addCssClass("ag-color-dialog"),t.addDestroyFunc(()=>{e.isAlive()&&this.destroyBean(e)}),e.setParentComponent(this),e.setBodyComponent(t),t.setValue(this.getValue()),t.getGui().focus(),e.addDestroyFunc(()=>{this.isDestroyingPicker?this.isDestroyingPicker=!1:(this.beforeHidePicker(),this.isDestroyingPicker=!0,t.isAlive()&&this.destroyBean(t),this.isAlive()&&this.getFocusableElement().focus())}),()=>{var e;return null==(e=this.pickerComponent)?void 0:e.close()}}setValue(e){return this.value===e?this:(this.eDisplayField.style.backgroundColor=e,super.setValue(e))}getValue(){return this.value}},Zn=class e extends ti.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("callout"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{calloutGroup:t,calloutLengthSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLine.length","length",40),calloutStrokeWidthSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLine.strokeWidth","strokeWidth",10),labelOffsetSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLabel.offset","offset",30)})}};Zn.TEMPLATE='<div>\n            <ag-group-component ref="calloutGroup">\n                <ag-slider ref="calloutLengthSlider"></ag-slider>\n                <ag-slider ref="calloutStrokeWidthSlider"></ag-slider>\n                <ag-slider ref="labelOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,ti.Autowired)("chartTranslationService")],Zn.prototype,"chartTranslationService",2),gr([ti.PostConstruct],Zn.prototype,"init",1);var Jn=Zn,es=class e extends ii.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("cap"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0},i=this.chartMenuUtils.getDefaultSliderParams("cap.lengthRatio","capLengthRatio",1);i.step=.05,this.setTemplate(e.TEMPLATE,{capsGroup:t,capLengthRatioSlider:i})}};es.TEMPLATE='<div>\n            <ag-group-component ref="capsGroup">\n                <ag-slider ref="capLengthRatioSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,ii.Autowired)("chartTranslationService")],es.prototype,"chartTranslationService",2),gr([ii.PostConstruct],es.prototype,"init",1);var ts=es,is=class e extends ri.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("connectorLine"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{lineGroup:t,lineColorPicker:this.chartMenuUtils.getDefaultColorPickerParams("line.stroke"),lineStrokeWidthSlider:this.getSliderParams("strokeWidth",10,"line.strokeWidth"),lineDashSlider:this.getSliderParams("lineDash",30,"line.lineDash",1,!0),lineOpacitySlider:this.getSliderParams("strokeOpacity",1,"line.strokeOpacity",.05)})}getSliderParams(e,t,i,r=1,n=!1){const s=this.chartMenuUtils.getDefaultSliderParams(i,e,t,n);return s.step=r,s}};is.TEMPLATE='<div>\n            <ag-group-component ref="lineGroup">\n                <ag-color-picker ref="lineColorPicker"></ag-color-picker>\n                <ag-slider ref="lineStrokeWidthSlider"></ag-slider>\n                <ag-slider ref="lineOpacitySlider"></ag-slider>\n                <ag-slider ref="lineDashSlider"></ag-slider>                \n            </ag-group-component>\n        </div>',gr([(0,ri.Autowired)("chartTranslationService")],is.prototype,"chartTranslationService",2),gr([ri.PostConstruct],is.prototype,"init",1);var rs=is,ns=class e extends ni.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("whisker"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{whiskersGroup:t,whiskerColorPicker:this.chartMenuUtils.getDefaultColorPickerParams("whisker.stroke"),whiskerThicknessSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.strokeWidth","strokeWidth",10),whiskerOpacitySlider:this.chartMenuUtils.getDefaultSliderParams("whisker.strokeOpacity","strokeOpacity",1),whiskerLineDashSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.lineDash","lineDash",30,!0),whiskerLineDashOffsetSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.lineDashOffset","lineDashOffset",30)})}};ns.TEMPLATE='<div>\n            <ag-group-component ref="whiskersGroup">\n                <ag-color-picker ref="whiskerColorPicker"></ag-color-picker>\n                <ag-slider ref="whiskerThicknessSlider"></ag-slider>\n                <ag-slider ref="whiskerOpacitySlider"></ag-slider>\n                <ag-slider ref="whiskerLineDashSlider"></ag-slider>\n                <ag-slider ref="whiskerLineDashOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,ni.Autowired)("chartTranslationService")],ns.prototype,"chartTranslationService",2),gr([ni.PostConstruct],ns.prototype,"init",1);var ss=ns,os=class e extends si.Component{constructor(e){super(),this.chartMenuUtils=e,this.activePanels=[]}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("seriesItems"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{seriesItemsGroup:t,seriesItemSelect:this.getSeriesItemsParams()}),this.initSeriesControls()}getSeriesItemsParams(){const e=[{value:"positive",text:this.chartTranslationService.translate("seriesItemPositive")},{value:"negative",text:this.chartTranslationService.translate("seriesItemNegative")}];return{label:this.chartTranslationService.translate("seriesItemType"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:e,value:"positive",onValueChange:e=>{this.destroyActivePanels(),this.initSeriesControls(e)}}}initSeriesControls(e="positive"){this.initSlider("strokeWidth",10,`item.${e}.strokeWidth`),this.initSlider("lineDash",30,`item.${e}.lineDash`,1,!0),this.initSlider("strokeOpacity",1,`item.${e}.strokeOpacity`,.05,!1),this.initSlider("fillOpacity",1,`item.${e}.fillOpacity`,.05,!1),this.initItemLabels(e)}initSlider(e,t,i,r=1,n=!1){const s=this.chartMenuUtils.getDefaultSliderParams(i,e,t,n);s.step=r;const o=this.seriesItemsGroup.createManagedBean(new si.AgSlider(s));this.seriesItemsGroup.addItem(o),this.activePanels.push(o)}initItemLabels(e){const t=this.chartMenuUtils.getDefaultFontPanelParams(`item.${e}.label`,"seriesItemLabels"),i=this.createBean(new En(t));this.seriesItemsGroup.addItem(i),this.activePanels.push(i)}destroyActivePanels(){this.activePanels.forEach(e=>{si._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};os.TEMPLATE='<div>\n            <ag-group-component ref="seriesItemsGroup">\n                <ag-select ref="seriesItemSelect"></ag-select>\n            </ag-group-component>\n        </div>',gr([(0,si.RefSelector)("seriesItemsGroup")],os.prototype,"seriesItemsGroup",2),gr([(0,si.Autowired)("chartTranslationService")],os.prototype,"chartTranslationService",2),gr([si.PostConstruct],os.prototype,"init",1);var as=os,ls=class e extends oi.Component{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{groupSpacing:dr(hr({},t),{title:this.chartTranslationService.translate("group")}),tileSpacing:dr(hr({},t),{title:this.chartTranslationService.translate("tile")}),groupPaddingSlider:this.getSliderParams("padding","group.padding"),groupSpacingSlider:this.getSliderParams("spacing","group.gap"),tilePaddingSlider:this.getSliderParams("padding","tile.padding"),tileSpacingSlider:this.getSliderParams("spacing","tile.gap")})}getSliderParams(e,t){return this.chartMenuUtils.getDefaultSliderParams(t,e,10)}};ls.TEMPLATE='<div>\n            <ag-group-component ref="groupSpacing">\n                <ag-slider ref="groupPaddingSlider"></ag-slider>\n                <ag-slider ref="groupSpacingSlider"></ag-slider>\n            </ag-group-component>\n            <ag-group-component ref="tileSpacing">\n                <ag-slider ref="tilePaddingSlider"></ag-slider>\n                <ag-slider ref="tileSpacingSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,oi.Autowired)("chartTranslationService")],ls.prototype,"chartTranslationService",2),gr([oi.PostConstruct],ls.prototype,"init",1);var cs=ls,us=class e extends qt.Component{constructor({chartController:e,chartOptionsService:t,seriesType:i,isExpandedOnInit:r=!1}){super(),this.activePanels=[],this.widgetFuncs={lineWidth:()=>this.initStrokeWidth("lineWidth"),strokeWidth:()=>this.initStrokeWidth("strokeWidth"),lineColor:()=>this.initLineColor(),lineDash:()=>this.initLineDash(),lineOpacity:()=>this.initLineOpacity(),fillOpacity:()=>this.initFillOpacity(),markers:()=>this.initMarkers(),labels:()=>this.initLabels(),shadow:()=>this.initShadow(),tooltips:()=>this.initTooltips(),bins:()=>this.initBins(),whiskers:()=>this.initWhiskers(),caps:()=>this.initCaps(),connectorLine:()=>this.initConnectorLine(),seriesItems:()=>this.initSeriesItemsPanel(),tileSpacing:()=>this.initTileSpacingPanel(),groupType:()=>this.initGroupType()},this.seriesWidgetMappings={bar:["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","shadow"],pie:["tooltips","strokeWidth","lineOpacity","fillOpacity","labels","shadow"],donut:["tooltips","strokeWidth","lineOpacity","fillOpacity","labels","shadow"],line:["tooltips","lineWidth","lineDash","lineOpacity","markers","labels"],scatter:["tooltips","markers","labels"],bubble:["tooltips","markers","labels"],area:["tooltips","lineWidth","lineDash","lineOpacity","fillOpacity","markers","labels","shadow"],histogram:["tooltips","bins","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","shadow"],"radial-column":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"radial-bar":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"radar-line":["tooltips","strokeWidth","lineDash","lineOpacity","markers","labels"],"radar-area":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","markers","labels"],nightingale:["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"box-plot":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","whiskers","caps"],"range-bar":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels"],"range-area":["tooltips","lineWidth","lineDash","lineOpacity","fillOpacity","markers","labels","shadow"],treemap:["tooltips","tileSpacing"],sunburst:["tooltips"],heatmap:["tooltips","labels","lineColor","lineWidth","lineOpacity"],waterfall:["tooltips","connectorLine","seriesItems"]},this.chartController=e,this.chartOptionsService=t,this.seriesType=i||this.chartController.getChartSeriesType(),this.isExpandedOnInit=r}init(){const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate("series"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{seriesGroup:t}),this.chartMenuUtils=this.createManagedBean(new In(this.chartOptionsService.getSeriesOptionsProxy(()=>this.seriesType))),this.chartOptions=this.chartMenuUtils.getChartOptions(),this.addManagedListener(this.chartController,sn.EVENT_CHART_SERIES_CHART_TYPE_CHANGED,this.refreshWidgets.bind(this)),this.refreshWidgets()}refreshWidgets(){this.destroyActivePanels(),this.chartController.getChartProxy().getChart().waitForUpdate().then(()=>{var e;!this.isAlive()||(this.chartController.isComboChart()&&(this.updateSeriesType(),this.initSeriesSelect()),(null!=(e=this.seriesWidgetMappings[this.seriesType])?e:[]).forEach(e=>this.widgetFuncs[e]()))}).catch(e=>console.error("AG Grid - chart rendering failed",e))}initSeriesSelect(){const e=this.seriesGroup.createManagedBean(new qt.AgSelect({label:this.translate("seriesType"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:this.getSeriesSelectOptions(),value:`${this.seriesType}`,onValueChange:e=>{this.seriesType=e,this.refreshWidgets()}}));this.seriesGroup.addItem(e),this.activePanels.push(e)}initTooltips(){const e=this.createBean(new qt.AgToggleButton(this.chartMenuUtils.addValueParams("tooltip.enabled",{label:this.translate("tooltips"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex"})));this.addWidget(e)}initLineColor(){const e=this.createBean(new Xn(this.chartMenuUtils.getDefaultColorPickerParams("stroke","strokeColor")));this.addWidget(e)}initStrokeWidth(e){const t=this.createBean(new qt.AgSlider(this.chartMenuUtils.getDefaultSliderParams("strokeWidth",e,10)));this.addWidget(t)}initLineDash(){const e=this.createBean(new qt.AgSlider(this.chartMenuUtils.getDefaultSliderParams("lineDash","lineDash",30,!0)));this.addWidget(e)}initLineOpacity(){const e=this.chartMenuUtils.getDefaultSliderParams("strokeOpacity","strokeOpacity",1);e.step=.05;const t=this.createBean(new qt.AgSlider(e));this.addWidget(t)}initFillOpacity(){const e=this.chartMenuUtils.getDefaultSliderParams("fillOpacity","fillOpacity",1);e.step=.05;const t=this.createBean(new qt.AgSlider(e));this.addWidget(t)}initLabels(){const e=xr(this.seriesType),t=e?"calloutLabel":"label",i=e?"calloutLabels":"labels",r=this.chartMenuUtils.getDefaultFontPanelParams(t,i),n=this.createBean(new En(r));if(e){const e=this.createBean(new Jn(this.chartMenuUtils));n.addCompToPanel(e),this.activePanels.push(e)}if(this.addWidget(n),e){const e=this.chartMenuUtils.getDefaultFontPanelParams("sectorLabel","sectorLabels"),t=this.createBean(new En(e)),i=this.getSectorLabelPositionRatio();t.addCompToPanel(i),this.addWidget(t)}if("range-bar"===this.seriesType){const e=[{value:"inside",text:this.translate("inside")},{value:"outside",text:this.translate("outside")}],t=n.createManagedBean(new qt.AgSelect(this.chartMenuUtils.addValueParams("label.placement",{label:this.translate("labelPlacement"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:e})));n.addCompToPanel(t),this.activePanels.push(t);const i=n.createManagedBean(new qt.AgSlider(this.chartMenuUtils.getDefaultSliderParams("label.padding","padding",200)));n.addCompToPanel(i),this.activePanels.push(i)}}getSectorLabelPositionRatio(){const e=this.chartMenuUtils.getDefaultSliderParams("sectorLabel.positionRatio","positionRatio",1);return e.step=.05,this.createBean(new qt.AgSlider(e))}initShadow(){const e=this.createBean(new Kn(this.chartMenuUtils));this.addWidget(e)}initMarkers(){const e=this.createBean(new qn(this.chartOptionsService,this.chartMenuUtils));this.addWidget(e)}initBins(){var e;const t=this.chartMenuUtils.getDefaultSliderParams("binCount","histogramBinCount",20),i=(null!=(e=this.chartOptions.getValue("bins"))?e:this.chartOptions.getValue("calculatedBins",!0)).length;t.value=`${i}`,t.maxValue=Math.max(i,20);const r=this.createBean(new qt.AgSlider(t));this.addWidget(r)}initWhiskers(){const e=this.createBean(new ss(this.chartMenuUtils));this.addWidget(e)}initCaps(){const e=this.createBean(new ts(this.chartMenuUtils));this.addWidget(e)}initConnectorLine(){const e=this.createBean(new rs(this.chartMenuUtils));this.addWidget(e)}initSeriesItemsPanel(){const e=this.createBean(new as(this.chartMenuUtils));this.addWidget(e)}initTileSpacingPanel(){const e=this.createBean(new cs(this.chartMenuUtils));this.addWidget(e)}initGroupType(){const e=this.createBean(new qt.AgSelect({label:this.chartTranslationService.translate("seriesGroupType"),options:qt.ChartMappings.SERIES_GROUP_TYPES.map(e=>({value:e,text:this.chartTranslationService.translate(`${e}SeriesGroupType`)})),value:this.chartController.getSeriesGroupType(),onValueChange:e=>this.chartController.setSeriesGroupType(e)}));this.addWidget(e)}addWidget(e){this.seriesGroup.addItem(e),this.activePanels.push(e)}getSeriesSelectOptions(){const e=this.getActiveSeriesTypes();return["area","bar","line"].filter(t=>e.includes(t)).map(e=>({value:e,text:this.translate(e)}))}updateSeriesType(){const e=this.getActiveSeriesTypes();!e.includes(this.seriesType)&&e.length>0&&(this.seriesType=e[0])}getActiveSeriesTypes(){return this.chartController.getActiveSeriesChartTypes().map(e=>Pr(e.chartType))}translate(e){return this.chartTranslationService.translate(e)}destroyActivePanels(){this.activePanels.forEach(e=>{qt._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};us.TEMPLATE='<div>\n            <ag-group-component ref="seriesGroup">\n            </ag-group-component>\n        </div>',gr([(0,qt.RefSelector)("seriesGroup")],us.prototype,"seriesGroup",2),gr([(0,qt.Autowired)("chartTranslationService")],us.prototype,"chartTranslationService",2),gr([qt.PostConstruct],us.prototype,"init",1);var hs=us,ds=class e extends ai.Component{constructor({chartMenuParamsFactory:e,isExpandedOnInit:t=!1}){super(),this.chartMenuUtils=e,this.isExpandedOnInit=t}init(){const t=this.chartMenuUtils.addEnableParams("gradientLegend.enabled",{cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("legend"),suppressEnabledCheckbox:!1,suppressToggleExpandOnEnableChange:!0,expanded:this.isExpandedOnInit,items:[this.createLabelPanel()]});this.setTemplate(e.TEMPLATE,{legendGroup:t,legendPositionSelect:this.chartMenuUtils.getDefaultLegendParams("gradientLegend.position"),gradientReverseCheckbox:this.getGradientReverseCheckboxParams(),gradientThicknessSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.gradient.thickness","thickness",40),gradientPreferredLengthSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.gradient.preferredLength","preferredLength",300),legendSpacingSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.spacing","spacing",200)})}getGradientReverseCheckboxParams(){return this.chartMenuUtils.addValueParams("gradientLegend.reverseOrder",{label:this.chartTranslationService.translate("reverseDirection"),labelWidth:"flex"})}createLabelPanel(){const e={enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`gradientLegend.scale.label.${e}`};return this.createManagedBean(new En(e))}};ds.TEMPLATE='<div>\n            <ag-group-component ref="legendGroup">\n                <ag-select ref="legendPositionSelect"></ag-select>\n                <ag-checkbox ref="gradientReverseCheckbox"></ag-checkbox>\n                <ag-slider ref="gradientThicknessSlider"></ag-slider>\n                <ag-slider ref="gradientPreferredLengthSlider"></ag-slider>\n                <ag-slider ref="legendSpacingSlider"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,ai.Autowired)("chartTranslationService")],ds.prototype,"chartTranslationService",2),gr([ai.PostConstruct],ds.prototype,"init",1);var ps=ds,gs=class extends li.BeanStub{constructor(e,t,i,r){super(),this.chartController=e,this.eGui=t,this.cssClass=i,this.createPanels=r,this.panels=[]}postConstruct(){this.addManagedListener(this.chartController,sn.EVENT_CHART_UPDATED,()=>this.refreshPanels(!0)),this.addManagedListener(this.chartController,sn.EVENT_CHART_API_UPDATE,()=>this.refreshPanels(!1))}addComponent(e){this.createBean(e),this.panels.push(e),e.addCssClass(this.cssClass),this.eGui.appendChild(e.getGui())}refreshPanels(e){const t=this.chartController.getChartType(),i=this.chartController.isGrouping(),r=Pr(t);e&&t===this.chartType&&i===this.isGrouping||(this.destroyPanels(),this.createPanels(t,r),this.chartType=t,this.isGrouping=i)}destroyPanels(){this.panels.forEach(e=>{li._.removeFromParent(e.getGui()),this.destroyBean(e)}),this.panels=[]}destroy(){this.destroyPanels(),super.destroy()}};gr([li.PostConstruct],gs.prototype,"postConstruct",1);var fs={groups:[{type:"chart"},{type:"legend"},{type:"series"},{type:"axis"}]},ms=class e extends Ot.Component{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}init(){this.chartPanelFeature=this.createManagedBean(new gs(this.chartMenuContext.chartController,this.getGui(),"ag-chart-format-section",(e,t)=>this.createPanels(e,t))),this.chartPanelFeature.refreshPanels()}createPanels(e,t){var i;null==(i=this.getFormatPanelDef().groups)||i.forEach(i=>{const r=i.type;if(!this.isGroupPanelShownInSeries(r,t))return;const n=dr(hr({},this.chartMenuContext),{isExpandedOnInit:i.isOpen,seriesType:t});switch(r){case"chart":this.chartPanelFeature.addComponent(new Wn(n));break;case"legend":const r=["treemap","sunburst","heatmap"].includes(e)?new ps(n):new Tn(n);this.chartPanelFeature.addComponent(r);break;case"axis":Tr(t)?this.chartPanelFeature.addComponent(new Fn(n)):Ar(t)&&(this.chartPanelFeature.addComponent(new Nn("xAxis",n)),this.chartPanelFeature.addComponent(new Nn("yAxis",n)));break;case"horizontalAxis":this.chartPanelFeature.addComponent(new Nn("xAxis",n));break;case"verticalAxis":this.chartPanelFeature.addComponent(new Nn("yAxis",n));break;case"series":this.chartPanelFeature.addComponent(new hs(n));break;case"navigator":Ot._.warnOnce("'navigator' is now displayed in the charts advanced settings instead of the format panel, and this setting will be ignored.");default:Ot._.warnOnce(`Invalid charts format panel group name supplied: '${i.type}'`)}})}getFormatPanelDef(){var e;return(null==(e=this.gos.get("chartToolPanelsDef"))?void 0:e.formatPanel)||fs}isGroupPanelShownInSeries(e,t){return["chart","legend","series"].includes(e)||Ar(t)&&["axis","horizontalAxis","verticalAxis"].includes(e)||Tr(t)&&"axis"===e}};ms.TEMPLATE='<div class="ag-chart-format-wrapper"></div>',gr([Ot.PostConstruct],ms.prototype,"init",1);var vs=ms,Cs=class extends di.Component{constructor(e,t){super(),this.tooltipName=t,this.size=58,this.padding=5,this.root=new pi._Scene.Group;const i=new pi._Scene.Scene({width:this.size,height:this.size});i.canvas.element.classList.add("ag-chart-mini-thumbnail-canvas"),i.setRoot(this.root),i.setContainer(e),this.scene=i}init(){this.scene.canvas.element.title=this.chartTranslationService.translate(this.tooltipName),this.scene.render().catch(e=>{console.error("AG Grid - chart update failed",e)})}};gr([(0,di.Autowired)("chartTranslationService")],Cs.prototype,"chartTranslationService",2),gr([di.PostConstruct],Cs.prototype,"init",1);var ys=class extends Cs{constructor(e,t){super(e,t),this.stroke="gray",this.axisOvershoot=3}addAxes(){const e=this.size,t=this.padding,i=new gi._Scene.Line;i.x1=t,i.y1=t,i.x2=t,i.y2=e-t+this.axisOvershoot,i.stroke=this.stroke;const r=new gi._Scene.Line;r.x1=t-this.axisOvershoot+1,r.y1=e-t,r.x2=e-t+1,r.y2=e-t,r.stroke=this.stroke;const n=this.root;n.append(i),n.append(r)}};function ws(e){const{stacked:t,size:i,padding:r,xScalePadding:n,xScaleDomain:s,yScaleDomain:o}=e,a=new fi._Scene.BandScale;a.domain=s,a.range=[r,i-r],a.paddingInner=n,a.paddingOuter=n;const l=new fi._Scene.LinearScale;l.domain=o,l.range=[i-r,r];const c=(e,t,i)=>e.map((e,r)=>{const n=i.convert(e),s=new fi._Scene.Rect;return s.x=t.convert(r),s.y=n,s.width=t.bandwidth,s.height=i.convert(0)-n,s.strokeWidth=0,s.crisp=!0,s});return t?e.data.map(e=>c(e,a,l)):c(e.data,a,l)}function Ss(e,t,i,r){const n=new fi._Scene.LinearScale;n.domain=[0,4],n.range=[r,i-r];const s=new fi._Scene.LinearScale;s.domain=[0,10],s.range=[i-r,r];const o=t.map(e=>{const t=new fi._Scene.Path;return t.strokeWidth=3,t.lineCap="round",t.fill=void 0,e.forEach((e,i)=>{t.path[i>0?"lineTo":"moveTo"](n.convert(i),s.convert(e))}),t}),a=new fi._Scene.Group;return a.setClipRectInGroupCoordinateSpace(new fi._Scene.BBox(r,r,i-2*r,i-2*r)),a.append(o),e.append(a),o}function bs(e,t,i,r,n,s=0){const o=new fi._Scene.LinearScale;o.domain=[0,7],o.range=[-Math.PI,Math.PI].map(e=>e+Math.PI/2);const a=new fi._Scene.LinearScale;a.domain=[0,10],a.range=[r,n];const l=[],c=t.map(e=>{const t=new fi._Scene.Path;return t.strokeWidth=1,t.strokeOpacity=.5,t.lineCap="round",t.fill=void 0,t.fillOpacity=.8,e.forEach((e,i)=>{const c=o.convert(i),u=r+n-a.convert(e),h=u*Math.cos(c),d=u*Math.sin(c);if(t.path[i>0?"lineTo":"moveTo"](h,d),s>0){const e=new fi._Scene.Circle;e.x=h,e.y=d,e.size=s,l.push(e)}}),t.path.closePath(),t}),u=new fi._Scene.Group,h=i/2;return u.translationX=h,u.translationY=h,u.append([...c,...l]),e.append(u),{paths:c,markers:l}}function Es(e){let[t,i]=[1/0,-1/0];return{processedData:e.reduce((e,r,n)=>{const s=n>0?e[n-1]:void 0;null!=e[n]||(e[n]=[]);const o=e[n];return r.forEach((e,r)=>{s&&(e+=s[r]),o[r]=e,o[r]<t&&(t=o[r]),o[r]>i&&(i=o[r])}),e},[]),min:t,max:i}}gr([hi.PostConstruct],ys.prototype,"addAxes",1);var As=class extends ys{constructor(e,t,i){super(e,"groupedColumnTooltip"),this.columnData=[2,3,4];const{root:r,columnData:n,size:s,padding:o}=this;this.columns=ws({stacked:!1,root:r,data:n,size:s,padding:o,xScaleDomain:[0,1,2],yScaleDomain:[0,4],xScalePadding:.3}),r.append(this.columns),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};As.chartType="groupedColumn";var Ts=class e extends ys{constructor(t,i,r,n,s,o=e.data,a=[0,16],l="stackedColumnTooltip"){super(t,l);const{root:c,size:u,padding:h}=this;this.stackedColumns=ws({stacked:!0,root:c,data:o,size:u,padding:h,xScaleDomain:[0,1,2],yScaleDomain:a,xScalePadding:.3}),c.append([].concat.apply([],this.stackedColumns)),this.updateColors(i,r)}updateColors(e,t){this.stackedColumns.forEach((i,r)=>i.forEach(i=>{i.fill=e[r],i.stroke=t[r]}))}};Ts.chartType="stackedColumn",Ts.data=[[8,12,16],[6,9,12],[2,3,4]];var Ms=Ts,Rs=class e extends Ms{constructor(t,i,r,n,s){super(t,i,r,n,s,e.data,[0,10],"normalizedColumnTooltip")}};Rs.chartType="normalizedColumn",Rs.data=[[10,10,10],[6,7,8],[2,4,6]];var _s=Rs,Ps=class extends ys{constructor(e,t,i){super(e,"groupedBarTooltip");const r=this.padding,n=this.size,s=new mi._Scene.BandScale;s.domain=[0,1,2],s.range=[r,n-r],s.paddingInner=.3,s.paddingOuter=.3;const o=new mi._Scene.LinearScale;o.domain=[0,4],o.range=[n-r,r];const a=o.convert(0),l=s.bandwidth;this.bars=[2,3,4].map((e,t)=>{const i=new mi._Scene.Rect;return i.x=r,i.y=s.convert(t),i.width=a-o.convert(e),i.height=l,i.strokeWidth=0,i.crisp=!0,i}),this.updateColors(t,i),this.root.append(this.bars)}updateColors(e,t){this.bars.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};Ps.chartType="groupedBar";var xs=class e extends ys{constructor(t,i,r,n,s,o=e.data,a=[0,16],l="stackedBarTooltip"){super(t,l);const c=this.size,u=this.padding,h=new vi._Scene.BandScale;h.domain=[0,1,2],h.range=[u,c-u],h.paddingInner=.3,h.paddingOuter=.3;const d=new vi._Scene.LinearScale;d.domain=a,d.range=[c-u,u];const p=d.convert(0),g=h.bandwidth;this.bars=o.map(e=>e.map((e,t)=>{const i=new vi._Scene.Rect;return i.x=u,i.y=h.convert(t),i.width=p-d.convert(e),i.height=g,i.strokeWidth=0,i.crisp=!0,i})),this.updateColors(i,r),this.root.append([].concat.apply([],this.bars))}updateColors(e,t){this.bars.forEach((i,r)=>i.forEach(i=>{i.fill=e[r],i.stroke=t[r]}))}};xs.chartType="stackedBar",xs.data=[[8,12,16],[6,9,12],[2,3,4]];var Ds=xs,Is=class e extends Ds{constructor(t,i,r,n,s){super(t,i,r,n,s,e.data,[0,10],"normalizedBarTooltip")}};Is.chartType="normalizedBar",Is.data=[[10,10,10],[6,7,8],[2,4,6]];var Ls=Is,Ns=Ci._Scene.toRadians,Os=class extends Cs{constructor(e,t,i,r,n,s=.6,o="donutTooltip"){super(e,o);const a=(this.size-2*this.padding)/2,l=a+this.padding,c=[[Ns(-90),Ns(30)],[Ns(30),Ns(120)],[Ns(120),Ns(180)],[Ns(180),Ns(210)],[Ns(210),Ns(240)],[Ns(240),Ns(270)]];this.sectors=c.map(([e,t])=>{const i=new Ci._Scene.Sector;return i.centerX=l,i.centerY=l,i.innerRadius=a*s,i.outerRadius=a,i.startAngle=e,i.endAngle=t,i.stroke=void 0,i.strokeWidth=0,i.inset=.75,i}),this.updateColors(t,i),this.root.append(this.sectors)}updateColors(e,t){this.sectors.forEach((i,r)=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})}};Os.chartType="donut";var Fs=class extends Os{constructor(e,t,i,r,n){super(e,t,i,r,n,0,"pieTooltip")}};Fs.chartType="pie";var ks=class extends ys{constructor(e,t,i){super(e,"lineTooltip"),this.data=[[9,7,8,5,6],[5,6,3,4,1],[1,3,4,8,7]],this.lines=Ss(this.root,this.data,this.size,this.padding),this.updateColors(t,i)}updateColors(e,t){this.lines.forEach((t,i)=>{t.stroke=e[i]})}};ks.chartType="line";var Gs=class extends ys{constructor(e,t,i){super(e,"scatterTooltip");const r=this.size,n=this.padding,s=new yi._Scene.LinearScale;s.domain=[-.5,4],s.range=[2*n,r-n];const o=new yi._Scene.LinearScale;o.domain=[-.5,3.5],o.range=[r-n,n];const a=[];[[[.3,3],[1.1,.9],[2,.4],[3.4,2.4]],[[0,.3],[1,2],[2.4,1.4],[3,0]]].forEach(e=>{e.forEach(([e,t])=>{const i=new yi._Scene.Arc;i.strokeWidth=0,i.centerX=s.convert(e),i.centerY=o.convert(t),i.radius=2.5,a.push(i)})}),this.points=a,this.updateColors(t,i);const l=new yi._Scene.Group;l.setClipRectInGroupCoordinateSpace(new yi._Scene.BBox(n,n,r-2*n,r-2*n)),l.append(this.points),this.root.append(l)}updateColors(e,t){this.points.forEach((i,r)=>{i.stroke=t[r%t.length],i.fill=e[r%e.length]})}};Gs.chartType="scatter";var Vs=class extends ys{constructor(e,t,i){super(e,"bubbleTooltip");const r=this.size,n=this.padding,s=new wi._Scene.LinearScale;s.domain=[0,1],s.range=[2*n,r-n];const o=new wi._Scene.LinearScale;o.domain=[0,1],o.range=[r-n,n];const a=[];[[[.1,.3,5],[.5,.4,7],[.2,.8,7]],[[.8,.7,5],[.7,.3,9]]].forEach(e=>{e.forEach(([e,t,i])=>{const r=new wi._Scene.Arc;r.strokeWidth=0,r.centerX=s.convert(e),r.centerY=o.convert(t),r.radius=i,r.fillOpacity=.7,a.push(r)})}),this.points=a,this.updateColors(t,i);const l=new wi._Scene.Group;l.setClipRectInGroupCoordinateSpace(new wi._Scene.BBox(n,n,r-2*n,r-2*n)),l.append(this.points),this.root.append(l)}updateColors(e,t){this.points.forEach((i,r)=>{i.stroke=t[r%t.length],i.fill=e[r%e.length]})}};Vs.chartType="bubble";var Hs=class e extends ys{constructor(t,i,r,n,s,o=e.data){super(t,"groupedAreaTooltip");const a=this.size,l=this.padding,c=new Si._Scene.BandScale;c.domain=[0,1,2],c.paddingInner=1,c.paddingOuter=0,c.range=[l+.5,a-l-.5];const u=new Si._Scene.LinearScale;u.domain=[0,6],u.range=[a-l+.5,l];const h=2*o.length-1,d=[],p=u.convert(0);o.forEach((e,t)=>{const i=c.convert(t);e.forEach((e,r)=>{const n=u.convert(e),s=d[r]||(d[r]=[]);s[t]={x:i,y:n},s[h-t]={x:i,y:p}})}),this.areas=d.reverse().map(e=>{const t=new Si._Scene.Path;t.strokeWidth=1,t.strokeOpacity=.75,t.fillOpacity=.7;const i=t.path;return i.clear(),e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),i.closePath(),t}),this.updateColors(i,r),this.root.append(this.areas)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};Hs.chartType="area",Hs.data=[[1,3,5],[2,6,4],[5,3,1]];var Bs=Hs,zs=class e extends ys{constructor(t,i,r,n,s,o=e.data,a="stackedAreaTooltip"){super(t,a);const l=this.size,c=this.padding,u=new bi._Scene.BandScale;u.domain=[0,1,2],u.paddingInner=1,u.paddingOuter=0,u.range=[c+.5,l-c-.5];const h=new bi._Scene.LinearScale;h.domain=[0,16],h.range=[l-c+.5,c+.5];const d=2*o.length-1,p=[];o.forEach((e,t)=>{const i=u.convert(t);let r=0;e.forEach((e,n)=>{const s=h.convert(r+e),o=p[n]||(p[n]=[]);o[t]={x:i,y:s},o[d-t]={x:i,y:h.convert(r)},r+=e})}),this.areas=p.map(e=>{const t=new bi._Scene.Path;t.strokeWidth=0;const i=t.path;return i.clear(),e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),i.closePath(),t}),this.updateColors(i,r),this.root.append(this.areas)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};zs.chartType="stackedArea",zs.data=[[2,3,2],[3,6,5],[6,2,2]];var Us=zs,Ws=class e extends Us{constructor(t,i,r,n,s,o=e.data){super(t,i,r,n,s,o,"normalizedAreaTooltip")}};Ws.chartType="normalizedArea",Ws.data=Us.data.map(e=>{const t=e.reduce((e,t)=>e+t,0);return e.map(e=>e/t*16)});var js=Ws,Ks=class extends ys{constructor(e,t,i){super(e,"histogramTooltip");const r=this.padding,n=this.size,s=[2,5,11,13,10,6,1],o=new Ei._Scene.LinearScale;o.domain=[0,s.length],o.range=[r,n-r];const a=new Ei._Scene.LinearScale;a.domain=[0,s.reduce((e,t)=>Math.max(e,t),0)],a.range=[n-r,r];const l=a.convert(0);this.bars=s.map((e,t)=>{const i=a.convert(e),r=o.convert(t),n=o.convert(t+1),s=new Ei._Scene.Rect;return s.x=r,s.y=i,s.width=n-r,s.height=l-i,s.strokeWidth=1,s.strokeOpacity=.75,s.crisp=!0,s}),this.updateColors(t,i),this.root.append(this.bars)}updateColors([e],[t]){this.bars.forEach(i=>{i.fill=e,i.stroke=t})}};Ks.chartType="histogram";var $s=class extends Cs{constructor(e,t){super(e,t),this.stroke="gray",this.showRadiusAxisLine=!0,this.showAngleAxisLines=!0}addAxes(){const e=this.size,t=this.padding,i=(e-2*t)/2,r=this.showAngleAxisLines?[i,.8*i,.6*i,.4*i]:[],n=new Mi._Scene.Line;n.x1=e/2,n.y1=t,n.x2=e/2,n.y2=e-t-i-r[r.length-1],n.stroke=this.stroke,n.strokeOpacity=.5,n.fill=void 0,n.visible=this.showRadiusAxisLine;const s=t+i;this.gridLines=r.map((e,t)=>{const i=new Mi._Scene.Path;return i.path.arc(s,s,e,0,2*Math.PI),i.strokeWidth=1,i.stroke=this.stroke,i.strokeOpacity=0===t?.5:.2,i.fill=void 0,i});const o=this.root;o.append(n),this.gridLines.length>0&&o.append(this.gridLines)}};gr([Ti.PostConstruct],$s.prototype,"addAxes",1);var qs=class extends $s{constructor(e,t,i){super(e,"radialColumnTooltip"),this.data=[[6,8,10,2,6,5],[4,4,3,6,4,4],[5,4,2,9,8,9]],this.showRadiusAxisLine=!1;const{padding:r,size:n,data:s}=this,o=(n-2*r)/2,a=.4*o,l=new Ai._Scene.BandScale;l.domain=s[0].map((e,t)=>t),l.range=[0,2*Math.PI],l.paddingInner=0,l.paddingOuter=0;const c=.7*l.bandwidth,{processedData:u,max:h}=Es(s),d=new Ai._Scene.LinearScale;d.domain=[0,h],d.range=[a,o];const p=this.size/2;this.series=u.map((e,t)=>{const i=0===t?void 0:u[t-1],r=new Ai._Scene.Group({zIndex:1e6}),n=e.map((e,t)=>{const r=null==i?void 0:i[t],n=d.convert(e),s=d.convert(null!=r?r:0),u=l.convert(t),h=u+c,g=Ai._Scene.getRadialColumnWidth(u,h,o,.5,.5),f=new Ai._Scene.RadialColumnShape;return f.scalingCenterX=p,f.scalingCenterY=p,f.columnWidth=g,f.innerRadius=s,f.outerRadius=n,f.startAngle=u,f.endAngle=h,f.isBeveled=!0,f.axisInnerRadius=a,f.axisOuterRadius=o,f.stroke=void 0,f.strokeWidth=0,f});return r.append(n),r.translationX=p,r.translationY=p,r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};qs.chartType="radialColumn";var Ys=class extends $s{constructor(e,t,i){super(e,"radialBarTooltip"),this.data=[[6,8,10],[4,4,3],[5,4,2]],this.showRadiusAxisLine=!1;const r=(this.size-this.padding)/2,n=.4*r,s=r+n,o=new Ri._Scene.BandScale;o.domain=this.data[0].map((e,t)=>t),o.range=[r,n],o.paddingInner=.5,o.paddingOuter=0;const a=o.bandwidth,{processedData:l,max:c}=Es(this.data),u=new Ri._Scene.LinearScale;u.domain=[0,Math.ceil(1.5*c)];const h=1.5*Math.PI,d=h+2*Math.PI;u.range=[h,d];const p=this.size/2;this.series=l.map((e,t)=>{const i=t<0?void 0:l[t-1],r=new Ri._Scene.Group({zIndex:1e6}),n=e.map((e,t)=>{var r;const n=null!=(r=null==i?void 0:i[t])?r:0,l=s-o.convert(t),c=l+a,h=u.convert(n),d=u.convert(e),g=new Ri._Scene.Sector;return g.centerX=p,g.centerY=p,g.innerRadius=l,g.outerRadius=c,g.startAngle=h,g.endAngle=d,g.stroke=void 0,g.strokeWidth=0,g});return r.append(n),r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};Ys.chartType="radialBar";var Qs=class extends $s{constructor(e,t,i){super(e,"radarLineTooltip"),this.markerSize=4,this.data=[[8,7,8,7,8,8,7,8],[6,8,5,10,6,7,4,6],[0,3,3,5,4,4,2,0]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,{paths:n,markers:s}=bs(this.root,this.data,this.size,r,0,this.markerSize);this.lines=n,this.markers=s,this.updateColors(t,i)}updateColors(e,t){this.lines.forEach((i,r)=>{const n=this.data[r].length;i.stroke=e[r];const s=r*n,o=s+n;this.markers.slice(s,o).forEach(i=>{i.stroke=t[r],i.fill=e[r]})})}};Qs.chartType="radarLine";var Xs=class extends $s{constructor(e,t,i){super(e,"radarAreaTooltip"),this.data=[[8,10,5,7,4,1,5,8],[1,1,2,7,7,8,10,1],[4,5,9,9,4,2,3,4]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,n=r-.3*this.size;this.areas=bs(this.root,this.data,this.size,r,n).paths,this.updateColors(t,i)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};Xs.chartType="radarArea";var Zs=class extends $s{constructor(e,t,i){super(e,"nightingaleTooltip"),this.data=[[6,10,9,8,7,8],[4,6,5,4,5,5],[3,5,4,3,4,7]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,n=new _i._Scene.BandScale;n.domain=this.data[0].map((e,t)=>t),n.range=[-Math.PI,Math.PI],n.paddingInner=0,n.paddingOuter=0;const s=.7*n.bandwidth,{processedData:o,max:a}=Es(this.data),l=new _i._Scene.LinearScale;l.domain=[0,a],l.range=[0,r];const c=this.size/2;this.series=o.map((e,t)=>{const i=t<0?void 0:o[t-1],r=new _i._Scene.Group({zIndex:1e6}),a=e.map((e,t)=>{const r=null==i?void 0:i[t],o=l.convert(e),a=l.convert(null!=r?r:0),u=n.convert(t),h=u+s,d=new _i._Scene.Sector;return d.centerX=c,d.centerY=c,d.innerRadius=a,d.outerRadius=o,d.startAngle=u,d.endAngle=h,d.stroke=void 0,d.strokeWidth=0,d});return r.append(a),r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};Zs.chartType="nightingale";var Js=class extends ys{constructor(e,t,i){super(e,"rangeBarTooltip"),this.bars=this.createRangeBar(this.root,[3,3.5,3],this.size,this.padding,"vertical"),this.updateColors(t,i)}updateColors(e,t){this.bars.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}createRangeBar(e,t,i,r,n){const s="horizontal"===n,o=2*r,a=new Pi._Scene.BandScale;a.domain=t.map((e,t)=>t),a.range=[r,i-r],a.paddingInner=.3,a.paddingOuter=.3;const l=new Pi._Scene.LinearScale;l.domain=[.7*t.reduce((e,t)=>Math.min(e,t),1/0),1.3*t.reduce((e,t)=>Math.max(e,t),0)],l.range=[o,i-o];const c=a.bandwidth,u=t.map((e,t)=>{const[i,r]=[.7*e,1.3*e],n=a.convert(t),o=l.convert(i),u=l.convert(r)-o,h=new Pi._Scene.Rect;return h.x=s?o:n,h.y=s?n:o,h.width=s?u:c,h.height=s?c:u,h.strokeWidth=0,h.crisp=!0,h});return e.append(u),u}};Js.chartType="rangeBar";var eo=class extends ys{constructor(e,t,i){super(e,"rangeAreaTooltip");const r=[to({offset:1.5,length:4,pattern:{low:3,high:5,period:4}}),to({offset:1.5,length:4,pattern:{low:2.25,high:4.25,period:4}}),to({offset:3,length:4,pattern:{low:2.5,high:4.5,period:4}})].map(e=>e.map(([e,t])=>({x:e,low:t-.875,high:t+.875}))),{lines:n,areas:s}=this.createRangeArea(this.root,r,this.size,this.padding);this.lines=n,this.areas=s,this.updateColors(t,i)}updateColors(e,t){e=ro(e,1,2),t=ro(t,1,2),this.lines.forEach(([e,i],r)=>{e.fill=void 0,e.stroke=t[r],i.fill=void 0,i.stroke=t[r]}),this.areas.forEach((t,i)=>{t.fill=e[i]})}createRangeArea(e,t,i,r){const n=t.reduce((e,t)=>t.reduce((e,{x:t})=>Math.min(e,t),e),1/0),s=t.reduce((e,t)=>t.reduce((e,{x:t})=>Math.max(e,t),e),-1/0),o=t.reduce((e,t)=>t.reduce((e,{low:t})=>Math.min(e,t),e),1/0),a=t.reduce((e,t)=>t.reduce((e,{high:t})=>Math.max(e,t),e),-1/0),l=new xi._Scene.LinearScale;l.domain=[n,s],l.range=[r,i-r];const c=2*r,u=new xi._Scene.LinearScale;u.domain=[o,a],u.range=[i-c,c];const h=[],d=[];return t.map(e=>{const t=new xi._Scene.Path,i=new xi._Scene.Path,r=new xi._Scene.Path;return h.push([t,i]),d.push(r),t.strokeWidth=0,i.strokeWidth=0,r.strokeWidth=0,r.fillOpacity=.8,t.path.clear(),i.path.clear(),r.path.clear(),e.map((e,n)=>{const{x:s,low:o,high:a}=e,c=l.convert(s),h=u.convert(o),d=u.convert(a),p=n>0?"lineTo":"moveTo";return t.path[p](c,d),i.path[p](c,h),r.path[p](c,d),[c,h]})}).forEach((e,t)=>{const i=e.length-1,r=d[t];for(let t=i;t>=0;t--){const[i,n]=e[t];r.path.lineTo(i,n)}}),e.append(d.concat(...h)),{lines:h,areas:d}}};function to(e){const{offset:t,length:i,pattern:r}=e,n=function(e,t,i){const{period:r}=i,n=e/r,s=[0,.5].map(e=>e-n).map(io).sort((e,t)=>e-t);return Array.from({length:Math.floor(s.length*(r/t))},(e,t)=>s[t%s.length]+Math.floor(t/s.length)).map(e=>e*r).map(t=>o(t,e,i))}(t,i,r),s=i;return 0!==n.length&&0===n[0][0]||n.unshift(o(0,t,r)),n[n.length-1][0]!==s&&n.push(o(s,t,r)),n;function o(e,t,i){return[e,a(t+e,i)]}function a(e,t){const{low:i,high:r,period:n}=t,s=io(e/n);return i+(r-i)*(s>.5?1-2*(s-.5):2*s)}}function io(e){const t=e%1;return t<0?t+1:t}function ro(e,t,i){const r=[...e],n=r[t];return r[t]=r[i],r[i]=n,r}eo.chartType="rangeArea";var no=class extends ys{constructor(e,t,i,r,n){super(e,"boxPlotTooltip");const s=this.padding,o=this.size,a=[11,11.5,10.5],l=new Di._Scene.LinearScale;l.domain=[.8*a.reduce((e,t)=>Math.min(e,t),1/0),1.2*a.reduce((e,t)=>Math.max(e,t),0)],l.range=[o-1.5*s,s];const c=new Di._Scene.BandScale;c.domain=a.map((e,t)=>t),c.range=[s,o-s],c.paddingInner=.4,c.paddingOuter=.2;const u=Math.round(c.bandwidth),h=Math.round(c.bandwidth/2);this.boxPlotGroups=a.map((e,t)=>{let[i,r,n,s]=[.8*e,.9*e,1.1*e,1.2*e];const o=Math.round(l.convert(n)),a=Math.round(c.convert(t)),d=Math.round(a+u),p=Math.round(l.convert(r)),g=Math.round(l.convert(i)),f=Math.round(l.convert(e)),m=Math.round(l.convert(s)),v=a+h,C=new Di._Scene.Group,y=new Di._Scene.Rect,w=new Di._Scene.Line,S=new Di._Scene.Line,b=new Di._Scene.Line,E=new Di._Scene.Line,A=new Di._Scene.Line;return y.x=a,y.y=o,y.width=u,y.height=p-o,y.strokeWidth=1,y.strokeOpacity=.75,y.crisp=!0,this.setLineProperties(w,a,d,f,f),this.setLineProperties(S,v,v,m,o),this.setLineProperties(b,v,v,g,p),this.setLineProperties(E,a,d,m,m),this.setLineProperties(A,a,d,g,g),C.append([y,w,S,b,E,A]),C}),this.updateColors(t,i,r,n),this.root.append(this.boxPlotGroups)}updateColors(e,t,i,r){var n;const s=null==i?void 0:i.properties.get(Di._Theme.DEFAULT_BACKGROUND_COLOUR),o=null!=(n=Array.isArray(s)?s[0]:s)?n:"white";this.boxPlotGroups.forEach((i,n)=>{var s;null==(s=i.children)||s.forEach(i=>{const s=e[n%e.length];i.fill=r?s:Di._Util.Color.interpolate(s,o)(.7),i.stroke=t[n%t.length]})})}setLineProperties(e,t,i,r,n){e.x1=t,e.x2=i,e.y1=r,e.y2=n,e.strokeOpacity=.75}};no.chartType="boxPlot";var so=class extends Cs{constructor(e,t,i,r,n){super(e,"treemapTooltip");const{size:s,padding:o}=this,a=[[1,1],[3,2,1]],l=a.length%2==0?.3:.2,c=[o,s-o],u=a.length,h=u*(u+1)/2,d=l/(u-1),p=c[1]-c[0],g=p-l;let f=c[0];this.rects=a.reduce((e,t,i)=>{null!=e||(e=[]);const r=g*((u-i)/h),n=t.length,s=t.reduce((e,t)=>e+t,0),o=l/(n-1||1),a=n>1?p-l:p;let m=c[0];const v=t.map(e=>{const t=new Ii._Scene.Rect,i=a*e/s;return t.x=f,t.y=m,t.width=r,t.height=i,t.strokeWidth=.75,t.crisp=!0,m+=i+o,t});return f+=r+d,e.push(...v),e},[]),this.updateColors(t,i,r,n);const m=new Ii._Scene.Group;m.setClipRectInGroupCoordinateSpace(new Ii._Scene.BBox(o,o,s-o,s-o)),m.append(this.rects),this.root.append(m)}updateColors(e,t,i,r){var n;const{properties:s}=null!=i?i:{},o=null==s?void 0:s.get(Ii._Theme.DEFAULT_BACKGROUND_COLOUR),a=null!=(n=Array.isArray(o)?o[0]:o)?n:"white";this.rects.forEach((i,n)=>{i.fill=e[n%t.length],i.stroke=r?t[n%t.length]:a})}};so.chartType="treemap";var oo=class extends $s{constructor(e,t,i){super(e,"sunburstTooltip"),this.data=[[[],[]],[[],[]],[[],[]]],this.angleOffset=-Math.PI/2,this.innerRadiusRatio=0,this.showRadiusAxisLine=!1,this.showAngleAxisLines=!1;const{data:r,size:n,padding:s,angleOffset:o,innerRadiusRatio:a}=this,l=(n-2*s)/2,c=[o+0,o+2*Math.PI],u=Math.abs(c[1]-c[0]),h=[l*a,l],d=Math.abs(h[1]-h[0]);let p=0;const g=(e,t)=>{e.forEach(e=>{const i=t+1;p=Math.max(p,i),g(e,i)})};g(r,0);const f=d/p,m=this.size/2,v=c[0];this.series=[];const C=(e,t,i,r,n)=>{if(!Array.isArray(e))return;const s=t+1;let o=i;e.forEach((e,i,a)=>{let l=n;l||(l=new Li._Scene.Group,this.series.push(l));const c=h[0]+t*f,u=h[0]+s*f,d=1/a.length,p=o,g=p+r*d,v=new Li._Scene.Sector;v.centerX=m,v.centerY=m,v.innerRadius=c,v.outerRadius=u,v.startAngle=p,v.endAngle=g,v.stroke=void 0,v.strokeWidth=0,v.inset=.75,o=g,l.append(v),C(e,s,p,Math.abs(g-p),l)})};C(r,0,v,u),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};oo.chartType="sunburst";var ao=class extends Cs{constructor(e,t,i,r,n){var s,o;super(e,"heatmapTooltip");const{size:a,padding:l}=this,c=Array.from({length:3},(e,t)=>Array.from({length:3},(e,t)=>t)),u=c.map((e,t)=>t),h=new Ni._Scene.BandScale;h.domain=u,h.range=[l,a-l],h.paddingInner=.01,h.paddingOuter=.1;const d=new Ni._Scene.BandScale;d.domain=u,d.range=[l,a-l],d.paddingInner=.01,d.paddingOuter=.1;const p=null!=(s=h.bandwidth)?s:0,g=null!=(o=d.bandwidth)?o:0;this.rects=c.reduce((e,t,i)=>{null!=e||(e=[]);const r=t.map((e,t)=>{const r=new Ni._Scene.Rect;return r.x=h.convert(i),r.y=d.convert(t),r.width=p,r.height=g,r.strokeWidth=0,r.crisp=!0,r});return e.push(...r),e},[]),this.updateColors(t,i,r,n);const f=new Ni._Scene.Group;f.setClipRectInGroupCoordinateSpace(new Ni._Scene.BBox(l,l,a-l,a-l)),f.append(this.rects),this.root.append(f)}updateColors(e,t,i,r){var n;const{properties:s}=null!=i?i:{},o=null==s?void 0:s.get(Ni._Theme.DEFAULT_DIVERGING_SERIES_COLOUR_RANGE),a=null==s?void 0:s.get(Ni._Theme.DEFAULT_BACKGROUND_COLOUR),l=null!=(n=Array.isArray(a)?a[0]:a)?n:"white",c=r?[e[0],e[1]]:o,u=r?t[0]:l;this.rects.forEach((e,t)=>{e.fill=Ni._Util.Color.interpolate(c[0],c[1])(.2*t),e.stroke=u})}};ao.chartType="heatmap";var lo=class extends ys{constructor(e,t,i,r,n){super(e,"waterfallTooltip"),this.data=[4,3,-3,6,-3],this.bars=this.createWaterfall(this.root,this.data,this.size,this.padding,"vertical").bars,this.updateColors(t,i,r,n)}updateColors(e,t,i,r){var n,s;const{data:o}=this,{properties:a}=null!=i?i:{},l={fill:e[0],stroke:t[0]},c={fill:e[1],stroke:t[1]},u=r?l:null!=(n=null==a?void 0:a.get(Oi._Theme.DEFAULT_WATERFALL_SERIES_POSITIVE_COLOURS))?n:l,h=r?c:null!=(s=null==a?void 0:a.get(Oi._Theme.DEFAULT_WATERFALL_SERIES_NEGATIVE_COLOURS))?s:c;this.bars.forEach((e,t)=>{const i=o[t]>=0;e.fill=i?u.fill:h.fill,e.stroke=i?u.stroke:h.stroke})}createWaterfall(e,t,i,r,n){const s=2*r,{processedData:o,min:a,max:l}=Es(t.map(e=>[e])),c=o.reduce((e,t)=>e.concat(t),[]),u=new Oi._Scene.LinearScale;u.domain=[Math.min(a,0),l],u.range=[i-s,s];const h=new Oi._Scene.BandScale;h.domain=t.map((e,t)=>t),h.range=[r,i-r],h.paddingInner=.2,h.paddingOuter=.3;const d=h.bandwidth,p=new Oi._Scene.Path;p.stroke="#575757",p.strokeWidth=0;const g=Math.floor(p.strokeWidth)%2/2,f=p.path;f.clear();const m="horizontal"===n,v=c.map((e,i)=>{const r=i>0?c[i-1]:0,n=t[i]>0,s=Math.round(u.convert(e)),o=Math.round(u.convert(r)),a=(n?s:o)-g,l=(n?o:s)+g,p=Math.abs(l-a),v=h.convert(i),C=new Oi._Scene.Rect;C.x=m?a:v,C.y=m?v:a,C.width=m?p:d,C.height=m?d:p,C.strokeWidth=0,C.crisp=!0;const y=s+g,w=o+g;if(i>0){const e=m?w:C.x,t=m?C.y:w;f.lineTo(e,t)}const S=m?y:C.x,b=m?C.y:y;return f.moveTo(S,b),C});return e.append([p,...v]),{bars:v}}};lo.chartType="waterfall";var co=class extends ys{constructor(e,t,i){super(e,"columnLineComboTooltip"),this.columnData=[3,4],this.lineData=[[5,4,6,5,4]];const{root:r,columnData:n,lineData:s,size:o,padding:a}=this;this.columns=ws({stacked:!1,root:r,data:n,size:o,padding:a,xScaleDomain:[0,1],yScaleDomain:[0,4],xScalePadding:.5}),r.append(this.columns),this.lines=Ss(r,s,o,a),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.lines.forEach((t,i)=>{t.stroke=e[i+2]})}};co.chartType="columnLineCombo";var uo=class extends ys{constructor(e,t,i){super(e,"areaColumnComboTooltip"),this.columnData=[3,4.5],this.areaData=[[5,4,6,5,4]];const{root:r,columnData:n,areaData:s,size:o,padding:a}=this;this.columns=ws({stacked:!1,root:r,data:n,size:o,padding:a,xScaleDomain:[0,1],yScaleDomain:[0,6],xScalePadding:.5});const l=new Fi._Scene.BandScale;l.range=[a,o-a],l.domain=[0,1,2,3,4],l.paddingInner=1,l.paddingOuter=0;const c=new Fi._Scene.LinearScale;c.range=[o-a,a],c.domain=[0,6];const u=[],h=c.convert(0),d=l.convert(0);s.forEach((e,t)=>{const i=u[t]||(u[t]=[]);e.forEach((e,t)=>{const r=e,n=t,s=l.convert(n),o=c.convert(r);i[t]={x:s,y:o}});const r=l.convert(e.length-1);u[t].push({x:r,y:h},{x:d,y:h})}),this.areas=u.map(e=>{const t=new Fi._Scene.Path;t.strokeWidth=0,t.fillOpacity=.8;const i=t.path;return e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),t}),r.append(this.areas),r.append([].concat.apply([],this.columns)),this.updateColors(t,i)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.columns.forEach((i,r)=>{i.fill=e[r+1],i.stroke=t[r+1]})}};uo.chartType="areaColumnCombo";var ho=class extends Cs{constructor(e,t,i){super(e,"customComboTooltip"),this.columnData=[3,4],this.lineData=[[5,4,6,5,4]];const{root:r,columnData:n,lineData:s,size:o,padding:a}=this;this.columns=ws({stacked:!1,root:r,data:n,size:o,padding:a,xScaleDomain:[0,1],yScaleDomain:[0,4],xScalePadding:.5}),r.append(this.columns),this.lines=Ss(r,s,o,a);const l="grey",c=new ki._Scene.Line;c.x1=a,c.y1=a,c.x2=a,c.y2=o-a+3,c.stroke=l;const u=new ki._Scene.Line;u.x1=a-3+1,u.y1=o-a,u.x2=o-a+1,u.y2=o-a,u.stroke=l;const h=new ki._Scene.Path;this.buildPenIconPath(h),h.fill="whitesmoke",h.stroke="darkslategrey",h.strokeWidth=1,r.append([u,c,h]),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.lines.forEach((t,i)=>{t.stroke=e[i+2]})}buildPenIconPath(e){const{path:t}=e;t.moveTo(25.76,43.46),t.lineTo(31.27,48.53),t.moveTo(49.86,22),t.lineTo(49.86,22),t.cubicCurveTo(49.01994659053345,21.317514933510974,47.89593834348529,21.09645997825817,46.86,21.41),t.lineTo(46.86,21.41),t.cubicCurveTo(45.55460035985361,21.77260167850787,44.38777081121966,22.517979360321792,43.51,23.55),t.lineTo(25.51,43.8),t.lineTo(25.43,43.89),t.lineTo(23.01,51.89),t.lineTo(22.83,52.46),t.lineTo(31.02,48.86),t.lineTo(49.02,28.52),t.lineTo(49.02,28.52),t.cubicCurveTo(49.940716461596224,27.521914221246085,50.54302631059587,26.2720342455763,50.75,24.93),t.lineTo(50.75,24.93),t.cubicCurveTo(50.95363374988308,23.866379846512814,50.62080640232334,22.77066734274871,49.86,22),t.closePath(),t.moveTo(41.76,25.5),t.lineTo(47.34,30.5),t.moveTo(40.74,26.65),t.lineTo(46.25,31.71)}};ho.chartType="customCombo";var po={columnGroup:{column:{range:!0,pivot:!0,enterprise:!1,icon:As},stackedColumn:{range:!0,pivot:!0,enterprise:!1,icon:Ms},normalizedColumn:{range:!0,pivot:!0,enterprise:!1,icon:_s}},barGroup:{bar:{range:!0,pivot:!0,enterprise:!1,icon:Ps},stackedBar:{range:!0,pivot:!0,enterprise:!1,icon:Ds},normalizedBar:{range:!0,pivot:!0,enterprise:!1,icon:Ls}},pieGroup:{pie:{range:!0,pivot:!0,enterprise:!1,icon:Fs},donut:{range:!0,pivot:!0,enterprise:!1,icon:Os},doughnut:{range:!0,pivot:!0,enterprise:!1,icon:Os}},lineGroup:{line:{range:!0,pivot:!0,enterprise:!1,icon:ks}},scatterGroup:{scatter:{range:!0,pivot:!0,enterprise:!1,icon:Gs},bubble:{range:!0,pivot:!0,enterprise:!1,icon:Vs}},areaGroup:{area:{range:!0,pivot:!0,enterprise:!1,icon:Bs},stackedArea:{range:!0,pivot:!0,enterprise:!1,icon:Us},normalizedArea:{range:!0,pivot:!0,enterprise:!1,icon:js}},polarGroup:{radarLine:{range:!0,pivot:!1,enterprise:!0,icon:Qs},radarArea:{range:!0,pivot:!1,enterprise:!0,icon:Xs},nightingale:{range:!0,pivot:!1,enterprise:!0,icon:Zs},radialColumn:{range:!0,pivot:!1,enterprise:!0,icon:qs},radialBar:{range:!0,pivot:!1,enterprise:!0,icon:Ys}},statisticalGroup:{boxPlot:{range:!0,pivot:!1,enterprise:!0,icon:no},histogram:{range:!0,pivot:!1,enterprise:!1,icon:Ks},rangeBar:{range:!0,pivot:!1,enterprise:!0,icon:Js},rangeArea:{range:!0,pivot:!1,enterprise:!0,icon:eo}},hierarchicalGroup:{treemap:{range:!0,pivot:!0,enterprise:!0,icon:so},sunburst:{range:!0,pivot:!0,enterprise:!0,icon:oo}},specializedGroup:{heatmap:{range:!0,pivot:!1,enterprise:!0,icon:ao},waterfall:{range:!0,pivot:!1,enterprise:!0,icon:lo}},combinationGroup:{columnLineCombo:{range:!0,pivot:!0,enterprise:!1,icon:co},areaColumnCombo:{range:!0,pivot:!0,enterprise:!1,icon:uo},customCombo:{range:!0,pivot:!0,enterprise:!1,icon:ho}}},go={columnGroup:["column","stackedColumn","normalizedColumn"],barGroup:["bar","stackedBar","normalizedBar"],pieGroup:["pie","donut"],lineGroup:["line"],scatterGroup:["scatter","bubble"],areaGroup:["area","stackedArea","normalizedArea"],polarGroup:["radarLine","radarArea","nightingale","radialColumn","radialBar"],statisticalGroup:["boxPlot","histogram","rangeBar","rangeArea"],hierarchicalGroup:["treemap","sunburst"],specializedGroup:["heatmap","waterfall"],combinationGroup:["columnLineCombo","areaColumnCombo","customCombo"]},fo=class e extends ui.Component{constructor(t,i,r,n,s,o=go){super(e.TEMPLATE),this.wrappers={},this.chartController=t,this.fills=i,this.strokes=r,this.themeTemplateParameters=n,this.isCustomTheme=s,this.chartGroups=hr({},o)}init(){!this.chartController.customComboExists()&&this.chartGroups.combinationGroup&&(this.chartGroups.combinationGroup=this.chartGroups.combinationGroup.filter(e=>"customCombo"!==e));const e=this.getGui(),t=this.chartController.isEnterprise(),i=this.chartController.isPivotChart(),r=!i,n=Object.keys(this.chartGroups).map(e=>{var n;const s=e in po?po[e]:void 0;if(!s)return ui._.warnOnce(`invalid chartGroupsDef config '${e}'`),null;const o=(null!=(n=this.chartGroups[e])?n:[]).map(n=>{const o=n in s?s[n]:void 0;return o?!t&&o.enterprise?null:r&&o.range||i&&o.pivot?o:null:(ui._.warnOnce(`invalid chartGroupsDef config '${e}.${n}'`),null)}).filter(e=>null!=e);return 0===o.length?null:{label:this.chartTranslationService.translate(e),items:o}}).filter(e=>null!=e);for(const{label:t,items:i}of n){const r=this.createBean(new ui.AgGroupComponent({title:t,suppressEnabledCheckbox:!0,enabled:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-settings",direction:"horizontal"}));for(const e of i){const t=e.icon,i=document.createElement("div");i.classList.add("ag-chart-mini-thumbnail");const n=t.chartType;this.addManagedListener(i,"click",()=>{this.chartController.setChartType(n),this.updateSelectedMiniChart()}),this.wrappers[n]=i,this.createBean(new t(i,this.fills,this.strokes,this.themeTemplateParameters,this.isCustomTheme)),r.addItem(i)}e.appendChild(r.getGui())}this.updateSelectedMiniChart()}updateSelectedMiniChart(){const e=this.chartController.getChartType();for(const t in this.wrappers){const i=t===e;this.wrappers[t].classList.toggle("ag-selected",i)}}};fo.TEMPLATE='<div class="ag-chart-settings-mini-wrapper"></div>',gr([(0,ui.Autowired)("chartTranslationService")],fo.prototype,"chartTranslationService",2),gr([ui.PostConstruct],fo.prototype,"init",1);var mo=fo,vo=class e extends ci.Component{constructor(t){super(e.TEMPLATE),this.chartController=t,this.miniChartsContainers=[],this.cardItems=[],this.activePaletteIndex=0,this.palettes=[],this.themes=[]}postConstruct(){this.resetPalettes(),this.ePrevBtn.insertAdjacentElement("afterbegin",ci._.createIconNoSpan("previous",this.gos)),this.eNextBtn.insertAdjacentElement("afterbegin",ci._.createIconNoSpan("next",this.gos)),this.addManagedListener(this.ePrevBtn,"click",()=>this.setActivePalette(this.getPrev(),"left")),this.addManagedListener(this.eNextBtn,"click",()=>this.setActivePalette(this.getNext(),"right")),this.addManagedListener(this.chartController,sn.EVENT_CHART_TYPE_CHANGED,()=>this.resetPalettes(!0)),this.addManagedListener(this.chartController,sn.EVENT_CHART_API_UPDATE,()=>this.resetPalettes(!0)),this.scrollSelectedIntoView()}scrollSelectedIntoView(){setTimeout(()=>{const e=this.miniChartsContainers.find(e=>!e.getGui().classList.contains("ag-hidden")).getGui().querySelector(".ag-selected");if(e){const t=e.offsetParent;t&&this.eMiniChartsContainer.scrollTo(0,t.offsetTop)}},250)}resetPalettes(e){var t,i;const r=this.chartController.getPalettes(),n=this.chartController.getThemeTemplateParameters(),s=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.settingsPanel)?void 0:i.chartGroupsDef;if(ci._.shallowCompare(r,this.palettes)&&!e||this.isAnimating)return;this.palettes=r,this.themes=this.chartController.getThemeNames(),this.activePaletteIndex=this.themes.findIndex(e=>e===this.chartController.getChartThemeName()),this.cardItems=[],ci._.clearElement(this.eCardSelector),this.destroyMiniCharts();const{themes:o}=this;this.palettes.forEach((e,t)=>{const i=this.activePaletteIndex===t,{fills:r,strokes:a}=e,l=!Wr(o[t]),c=this.createBean(new mo(this.chartController,r,a,n[t],l,s));this.miniChartsContainers.push(c),this.eMiniChartsContainer.appendChild(c.getGui()),this.addCardLink(t),i?c.updateSelectedMiniChart():c.setDisplayed(!1)}),ci._.setDisplayed(this.eNavBar,this.palettes.length>1),ci._.radioCssClass(this.cardItems[this.activePaletteIndex],"ag-selected","ag-not-selected")}addCardLink(e){const t=document.createElement("div");t.classList.add("ag-chart-settings-card-item"),this.addManagedListener(t,"click",()=>{this.setActivePalette(e,e<this.activePaletteIndex?"left":"right")}),this.eCardSelector.appendChild(t),this.cardItems.push(t)}getPrev(){let e=this.activePaletteIndex-1;return e<0&&(e=this.palettes.length-1),e}getNext(){let e=this.activePaletteIndex+1;return e>=this.palettes.length&&(e=0),e}setActivePalette(e,t){if(this.isAnimating||this.activePaletteIndex===e)return;ci._.radioCssClass(this.cardItems[e],"ag-selected","ag-not-selected");const i=this.miniChartsContainers[this.activePaletteIndex],r=i.getGui(),n=this.miniChartsContainers[e],s=n.getGui();i.updateSelectedMiniChart(),n.updateSelectedMiniChart();const o="left"===t?-1:1,a=s.style.left=ci._.getAbsoluteWidth(this.getGui())*o+"px";this.activePaletteIndex=e,this.isAnimating=!0;const l="ag-animating";n.setDisplayed(!0),i.addCssClass(l),n.addCssClass(l),this.chartController.setChartThemeName(this.themes[e]),window.setTimeout(()=>{r.style.left=-parseFloat(a)+"px",s.style.left="0px"},0),window.setTimeout(()=>{this.isAnimating=!1,i.removeCssClass(l),n.removeCssClass(l),i.setDisplayed(!1)},300)}destroyMiniCharts(){ci._.clearElement(this.eMiniChartsContainer),this.miniChartsContainers=this.destroyBeans(this.miniChartsContainers)}destroy(){this.destroyMiniCharts(),super.destroy()}};vo.TEMPLATE='<div class="ag-chart-settings-wrapper">\n            <div ref="eMiniChartsContainer" class="ag-chart-settings-mini-charts-container ag-scrollable-container"></div>\n            <div ref="eNavBar" class="ag-chart-settings-nav-bar">\n                <div ref="ePrevBtn" class="ag-chart-settings-prev">\n                    <button type="button" class="ag-button ag-chart-settings-prev-button"></button>\n                </div>\n                <div ref="eCardSelector" class="ag-chart-settings-card-selector"></div>\n                <div ref="eNextBtn" class="ag-chart-settings-next">\n                    <button type="button" class="ag-button ag-chart-settings-next-button"></button>\n                </div>\n            </div>\n        </div>',gr([(0,ci.RefSelector)("eMiniChartsContainer")],vo.prototype,"eMiniChartsContainer",2),gr([(0,ci.RefSelector)("eNavBar")],vo.prototype,"eNavBar",2),gr([(0,ci.RefSelector)("eCardSelector")],vo.prototype,"eCardSelector",2),gr([(0,ci.RefSelector)("ePrevBtn")],vo.prototype,"ePrevBtn",2),gr([(0,ci.RefSelector)("eNextBtn")],vo.prototype,"eNextBtn",2),gr([ci.PostConstruct],vo.prototype,"postConstruct",1);var Co=vo,yo=class e extends mt.Component{constructor(e,t){super(),this.panels=e,this.chartMenuContext=t,this.tabs=[]}init(){this.panels.forEach(e=>{const t=e.replace("chart","").toLowerCase(),i=this.createPanel(t),r=this.createTab(e,t,i);this.tabs.push(r),this.addDestroyFunc(()=>this.destroyBean(i))}),this.tabbedLayout=new mt.TabbedLayout({items:this.tabs,cssClass:"ag-chart-tabbed-menu",keepScrollPosition:!0,suppressFocusBodyOnOpen:!0,suppressTrapFocus:!0,enableCloseButton:!this.chartMenuService.isLegacyFormat(),closeButtonAriaLabel:this.chartTranslationService.translate("ariaChartMenuClose"),onCloseClicked:()=>{var t;null==(t=this.eventSource)||t.focus({preventScroll:!0}),this.dispatchEvent({type:e.EVENT_CLOSED})}}),this.getContext().createBean(this.tabbedLayout)}createTab(e,t,i){const r=document.createElement("div");r.classList.add("ag-chart-tab",`ag-chart-${t}`),this.getContext().createBean(i),r.appendChild(i.getGui());const n=document.createElement("div"),s=this.chartTranslationService.translate(t);return n.innerText=s,{title:n,titleLabel:s,bodyPromise:mt.AgPromise.resolve(r),getScrollableContainer:()=>r.querySelector(".ag-scrollable-container")||r,name:e}}showTab(e){const t=this.tabs[e];this.tabbedLayout.showItem(t)}getGui(){return this.tabbedLayout&&this.tabbedLayout.getGui()}showMenu(e,t){var i;this.eventSource=e,t||null==(i=this.tabbedLayout)||i.focusHeader(!0)}destroy(){this.parentComponent&&this.parentComponent.isAlive()&&this.destroyBean(this.parentComponent),super.destroy()}createPanel(t){const{chartController:i,chartOptionsService:r}=this.chartMenuContext;switch(t){case e.TAB_DATA:return new Sn(i,r);case e.TAB_FORMAT:return new vs(this.chartMenuContext);default:return new Co(i)}}};yo.EVENT_CLOSED="closed",yo.TAB_DATA="data",yo.TAB_FORMAT="format",gr([(0,mt.Autowired)("chartTranslationService")],yo.prototype,"chartTranslationService",2),gr([(0,mt.Autowired)("chartMenuService")],yo.prototype,"chartMenuService",2),gr([mt.PostConstruct],yo.prototype,"init",1);var wo=yo,So=class extends Gi.Component{constructor(){super('<div class="ag-chart-menu" ref="eMenu"></div>'),this.buttonListenersDestroyFuncs=[]}updateParams(e){const{buttons:t}=e;this.createButtons(t)}createButtons(e){this.buttonListenersDestroyFuncs.forEach(e=>null==e?void 0:e()),this.buttonListenersDestroyFuncs=[];const t=this.eMenu;Gi._.clearElement(t),e.forEach(e=>{const{buttonName:i,iconName:r,callback:n}=e,s=this.createButton(r),o=this.chartTranslationService.translate(i+"ToolbarTooltip");o&&s instanceof HTMLElement&&(s.title=o),this.buttonListenersDestroyFuncs.push(this.addManagedListener(s,"click",e=>n(e.target))),t.appendChild(s)})}createButton(e){let t=Gi._.createIconNoSpan(e,this.gos,void 0,!0);return t.classList.add("ag-chart-menu-icon"),this.chartMenuService.isLegacyFormat()||(t=this.wrapButton(t)),t}wrapButton(e){const t=this.gos.getDocument().createElement("button");return t.appendChild(e),t.classList.add("ag-chart-menu-toolbar-button"),t}destroy(){this.buttonListenersDestroyFuncs=[],super.destroy()}};gr([(0,Gi.Autowired)("chartTranslationService")],So.prototype,"chartTranslationService",2),gr([(0,Gi.Autowired)("chartMenuService")],So.prototype,"chartMenuService",2),gr([(0,Gi.RefSelector)("eMenu")],So.prototype,"eMenu",2);var bo=class e extends ft.Component{constructor(t,i,r){super(e.TEMPLATE),this.eChartContainer=t,this.eMenuPanelContainer=i,this.chartMenuContext=r,this.buttons={chartSettings:{iconName:"menu",callback:()=>this.showMenu({panel:this.defaultPanel})},chartData:{iconName:"menu",callback:()=>this.showMenu({panel:"chartData"})},chartFormat:{iconName:"menu",callback:()=>this.showMenu({panel:"chartFormat"})},chartLink:{iconName:"linked",callback:()=>this.chartMenuService.toggleLinked(this.chartMenuContext)},chartUnlink:{iconName:"unlinked",callback:()=>this.chartMenuService.toggleLinked(this.chartMenuContext)},chartDownload:{iconName:"save",callback:()=>this.chartMenuService.downloadChart(this.chartMenuContext)},chartMenu:{iconName:"menuAlt",callback:e=>this.showMenuList(e)}},this.panels=[],this.menuVisible=!1,this.chartController=r.chartController}postConstruct(){this.legacyFormat=this.chartMenuService.isLegacyFormat(),this.chartToolbar=this.createManagedBean(new So),this.getGui().appendChild(this.chartToolbar.getGui()),this.legacyFormat&&this.createLegacyToggleButton(),this.refreshToolbarAndPanels(),this.addManagedListener(this.eventService,ft.Events.EVENT_CHART_CREATED,e=>{var t;e.chartId===this.chartController.getChartId()&&Boolean(null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.defaultToolPanel)&&this.showMenu({panel:this.defaultPanel,animate:!1,suppressFocus:!0})}),this.addManagedListener(this.chartController,sn.EVENT_CHART_LINKED_CHANGED,this.refreshToolbarAndPanels.bind(this)),this.refreshMenuClasses(),this.legacyFormat&&!this.gos.get("suppressChartToolPanelsButton")&&this.panels.length>0&&(this.getGui().classList.add("ag-chart-tool-panel-button-enable"),this.eHideButton&&this.addManagedListener(this.eHideButton,"click",this.toggleMenu.bind(this))),this.legacyFormat||this.getGui().classList.add("ag-chart-menu-wrapper"),this.addManagedListener(this.chartController,sn.EVENT_CHART_API_UPDATE,this.refreshToolbarAndPanels.bind(this))}isVisible(){return this.menuVisible}getExtraPaddingDirections(){const e=[];return["chartMenu","chartLink","chartUnlink","chartDownload"].some(e=>this.chartToolbarOptions.includes(e))&&e.push("top"),["chartSettings","chartData","chartFormat"].some(e=>this.chartToolbarOptions.includes(e))&&e.push(this.gos.get("enableRtl")?"left":"right"),e}createLegacyToggleButton(){const e=this.gos.getDocument();this.eHideButton=e.createElement("button"),this.eHideButton.classList.add("ag-button","ag-chart-menu-close"),this.eHideButtonIcon=e.createElement("span"),this.eHideButtonIcon.classList.add("ag-icon","ag-icon-contracted"),this.eHideButton.appendChild(this.eHideButtonIcon),this.getGui().appendChild(this.eHideButton)}refreshToolbarAndPanels(){this.initToolbarOptionsAndPanels(),this.updateToolbar()}initToolbarOptionsAndPanels(){const{panels:e,defaultPanel:t,chartToolbarOptions:i}=this.chartMenuService.getToolbarOptionsAndPanels(this.chartController);this.panels=e,this.defaultPanel=t,this.chartToolbarOptions=i}updateToolbar(){const e=this.chartToolbarOptions.map(e=>{const{iconName:t,callback:i}=this.buttons[e];return{buttonName:e,iconName:t,callback:i}});this.chartToolbar.updateParams({buttons:e})}createMenuPanel(e){const t=this.environment.chartMenuPanelWidth(),i=this.menuPanel=this.createBean(new ft.AgPanel({minWidth:t,width:t,height:"100%",closable:!0,hideTitleBar:!0,cssIdentifier:"chart-menu"}));return i.setParentComponent(this),this.eMenuPanelContainer.appendChild(i.getGui()),this.tabbedMenu=this.createBean(new wo(this.panels,this.chartMenuContext)),this.addManagedListener(this.tabbedMenu,wo.EVENT_CLOSED,()=>{this.hideMenu(!1)}),this.addManagedListener(i,ft.Component.EVENT_DESTROYED,()=>this.destroyBean(this.tabbedMenu)),new ft.AgPromise(t=>{window.setTimeout(()=>{i.setBodyComponent(this.tabbedMenu),this.tabbedMenu.showTab(e),t(i),this.legacyFormat&&this.addManagedListener(this.eChartContainer,"click",e=>{this.getGui().contains(e.target)||this.menuVisible&&this.hideMenu()})},100)})}showContainer(e,t){this.menuPanel&&(this.menuVisible=!0,this.showParent(this.menuPanel.getWidth()),this.refreshMenuClasses(),this.tabbedMenu.showMenu(e,t))}toggleMenu(){this.menuVisible?this.hideMenu(this.legacyFormat):this.showMenu({animate:this.legacyFormat})}showMenu(e){const{panel:t,animate:i=!0,eventSource:r,suppressFocus:n}=e;if(i||this.eMenuPanelContainer.classList.add("ag-no-transition"),this.menuPanel&&!t)this.showContainer(r,n);else{const e=t||this.defaultPanel;let i=this.panels.indexOf(e);i<0&&(console.warn(`AG Grid: '${t}' is not a valid Chart Tool Panel name`),i=this.panels.indexOf(this.defaultPanel)),this.menuPanel?(this.tabbedMenu.showTab(i),this.showContainer(r,n)):this.createMenuPanel(i).then(()=>this.showContainer(r,n))}i||setTimeout(()=>{this.isAlive()&&this.eMenuPanelContainer.classList.remove("ag-no-transition")},500)}hideMenu(e=!0){e||this.eMenuPanelContainer.classList.add("ag-no-transition"),this.hideParent(),window.setTimeout(()=>{this.menuVisible=!1,this.refreshMenuClasses(),e||this.eMenuPanelContainer.classList.remove("ag-no-transition")},500)}refreshMenuClasses(){this.eChartContainer.classList.toggle("ag-chart-menu-visible",this.menuVisible),this.eChartContainer.classList.toggle("ag-chart-menu-hidden",!this.menuVisible),this.legacyFormat&&!this.gos.get("suppressChartToolPanelsButton")&&(this.eHideButtonIcon.classList.toggle("ag-icon-contracted",this.menuVisible),this.eHideButtonIcon.classList.toggle("ag-icon-expanded",!this.menuVisible))}showParent(e){this.eMenuPanelContainer.style.minWidth=`${e}px`}hideParent(){this.eMenuPanelContainer.style.minWidth="0"}showMenuList(e){this.chartMenuListFactory.showMenuList({eventSource:e,showMenu:()=>this.showMenu({animate:!1,eventSource:e}),chartMenuContext:this.chartMenuContext})}destroy(){super.destroy(),this.menuPanel&&this.menuPanel.isAlive()&&this.destroyBean(this.menuPanel),this.tabbedMenu&&this.tabbedMenu.isAlive()&&this.destroyBean(this.tabbedMenu)}};bo.TEMPLATE="<div></div>",gr([(0,ft.Autowired)("chartMenuService")],bo.prototype,"chartMenuService",2),gr([(0,ft.Autowired)("chartMenuListFactory")],bo.prototype,"chartMenuListFactory",2),gr([ft.PostConstruct],bo.prototype,"postConstruct",1);var Eo=bo,Ao=class e extends Vi.Component{constructor(t){super(e.TEMPLATE),this.chartMenu=t,this.destroyableChartListeners=[],this.editing=!1}init(){this.addManagedListener(this.getGui(),"keydown",e=>{this.editing&&"Enter"===e.key&&!e.shiftKey&&(this.handleEndEditing(),e.preventDefault())}),this.addManagedListener(this.getGui(),"input",()=>{this.editing&&this.updateHeight()}),this.addManagedListener(this.getGui(),"blur",()=>this.endEditing())}refreshTitle(e){this.chartController=e.chartController,this.chartOptionsService=e.chartOptionsService,this.chartMenuUtils=e.chartMenuParamsFactory.getChartOptions();for(const e of this.destroyableChartListeners)e();this.destroyableChartListeners=[];const t=this.chartController.getChartProxy().getChart(),i=t.canvasElement,r=this.addManagedListener(i,"dblclick",e=>{const{title:r}=t;if(r&&r.node.containsPoint(e.offsetX,e.offsetY)){const e=r.node.computeBBox(),t=r.node.inverseTransformPoint(e.x,e.y);this.startEditing(hr(hr({},e),t),i.width)}});let n=!1;const s=this.addManagedListener(i,"mousemove",e=>{const{title:r}=t,s=!!(r&&r.enabled&&r.node.containsPoint(e.offsetX,e.offsetY));n!==s&&(i.style.cursor=s?"pointer":""),n=s});this.destroyableChartListeners=[r,s]}startEditing(e,t){if(this.chartMenuService.isLegacyFormat()&&this.chartMenu&&this.chartMenu.isVisible())return;if(this.editing)return;this.editing=!0;const i=Math.max(Math.min(e.width+20,t),300),r=this.getGui();r.classList.add("currently-editing");const n=r.style;n.fontFamily=this.chartMenuUtils.getValue("title.fontFamily"),n.fontWeight=this.chartMenuUtils.getValue("title.fontWeight"),n.fontStyle=this.chartMenuUtils.getValue("title.fontStyle"),n.fontSize=this.chartMenuUtils.getValue("title.fontSize")+"px",n.color=this.chartMenuUtils.getValue("title.color");const s=this.chartMenuUtils.getValue("title.text"),o=s===this.chartTranslationService.translate("titlePlaceholder");r.value=o?"":s;const a=s.split(/\r?\n/g).length;n.left=Math.round(e.x+e.width/2-i/2-1)+"px",n.top=Math.round(e.y+e.height/2-a*this.getLineHeight()/2-2)+"px",n.width=Math.round(i)+"px",n.lineHeight=this.getLineHeight()+"px",this.updateHeight(),r.focus()}updateHeight(){const e=this.getGui(),t=this.chartMenuUtils.getValue("title.text").split(/\r?\n/g).length,i=e.value.split(/\r?\n/g).length;e.style.height=Math.round(Math.max(t,i)*this.getLineHeight())+4+"px"}getLineHeight(){const e=this.chartMenuUtils.getValue("title.lineHeight");return e?parseInt(e):Math.round(1.2*parseInt(this.chartMenuUtils.getValue("title.fontSize")))}handleEndEditing(){const e=this.chartMenuUtils.getValue("title.color");this.chartMenuUtils.setValue("title.color","rgba(0, 0, 0, 0)"),this.chartOptionsService.awaitChartOptionUpdate(()=>this.endEditing()),this.chartOptionsService.awaitChartOptionUpdate(()=>{this.chartMenuUtils.setValue("title.color",e)})}endEditing(){if(!this.editing)return;this.editing=!1;const e=this.getGui().value;e&&""!==e.trim()?(this.chartMenuUtils.setValue("title.text",e),this.chartMenuUtils.setValue("title.enabled",!0)):(this.chartMenuUtils.setValue("title.text",""),this.chartMenuUtils.setValue("title.enabled",!1)),this.getGui().classList.remove("currently-editing"),this.chartOptionsService.awaitChartOptionUpdate(()=>{this.eventService.dispatchEvent({type:"chartTitleEdit"})})}};Ao.TEMPLATE='<textarea\n             class="ag-chart-title-edit"\n             style="padding:0; border:none; border-radius: 0; min-height: 0; text-align: center; resize: none;" />\n        ',gr([(0,Vi.Autowired)("chartTranslationService")],Ao.prototype,"chartTranslationService",2),gr([(0,Vi.Autowired)("chartMenuService")],Ao.prototype,"chartMenuService",2),gr([Vi.PostConstruct],Ao.prototype,"init",1);var To=Ao;function Mo(e){return null!=e.chart?e.chart:e}var Ro=class{constructor(e){this.chartProxyParams=e,this.clearThemeOverrides=!1,this.isEnterpriseCharts=Bi._ModuleSupport.enterpriseModule.isEnterprise,this.chart=e.chartInstance,this.chartType=e.chartType,this.crossFiltering=e.crossFiltering,this.crossFilterCallback=e.crossFilterCallback,this.standaloneChartType=Pr(this.chartType),null==this.chart?this.chart=Bi.AgCharts.create(this.getCommonChartOptions()):this.clearThemeOverrides=!0}crossFilteringReset(){}update(e){Bi.AgCharts.update(this.getChartRef(),this.getUpdateOptions(e,this.getCommonChartOptions(e.updatedOverrides)))}updateThemeOverrides(e){Bi.AgCharts.updateDelta(this.getChartRef(),{theme:{overrides:e}})}getChart(){return Mo(this.chart)}getChartRef(){return this.chart}downloadChart(e,t,i){const{chart:r}=this,n=Mo(r),s=t||(n.title?n.title.text:"chart"),{width:o,height:a}=e||{};Bi.AgCharts.download(r,{width:o,height:a,fileName:s,fileFormat:i})}getChartImageDataURL(e){return this.getChart().getCanvasDataURL(e)}getChartOptions(){return this.chart.getOptions()}getChartThemeOverrides(){var e;return null!=(e=this.getChartOptions().theme.overrides)?e:{}}getChartPalette(){return Bi._Theme.getChartTheme(this.getChartOptions().theme).palette}setPaired(e){const t=Pr(this.chartProxyParams.chartType);Bi.AgCharts.updateDelta(this.chart,{theme:{overrides:{[t]:{paired:e}}}})}isPaired(){const e=Pr(this.chartProxyParams.chartType);return Ur(this.getChartThemeOverrides(),`${e}.paired`,!0)}lookupCustomChartTheme(e){return $r(this.chartProxyParams,e)}getSeriesGroupType(){}transformCategoryData(e,t){return e.map((e,i)=>{const r=e[t],n=r&&r.toString?r.toString():"",s=hr({},e);return s[t]={id:i,value:r,toString:()=>n},s})}getCommonChartOptions(e){var t,i;const r=this.clearThemeOverrides?{}:null!=(i=null==(t=this.chart)?void 0:t.getOptions())?i:{},n=null!=this.chart?this.getActiveFormattingPanelOverrides():void 0;this.clearThemeOverrides=!1;const s=function(e,t,i,r,n){var s;const{chartOptionsToRestore:o,chartPaletteToRestore:a,chartThemeToRestore:l}=e,c=function(e){let t=e.getChartThemeName();const i=e.getChartThemes();return Tt._.includes(i,t)||(t=i[0]),t}(e),u=Wr(c),h=u?{baseTheme:c}:null!=(s=$r(e,c))?s:{},d=e.getGridOptionsChartThemeOverrides(),p=e.apiChartThemeOverrides,g=Pr(e.chartType),f=e.crossFiltering?function(e,t,i){const r={listeners:{legendItemClick:t=>{e.getChart().series.forEach(e=>{e.toggleSeriesItem(t.itemId,t.enabled),e.toggleSeriesItem(`${t.itemId}-filtered-out`,t.enabled)})}}};return{[i]:{tooltip:{delay:500},legend:r,listeners:{click:e=>t.crossFilterCallback(e,!0)}}}}(t,e,g):void 0,m=[u?Kr(e,i,(()=>{const e=e=>!!e&&Object.keys(e).some(t=>Ur(e[t],"title.enabled",!1));return e(d)||e(p)})()):void 0,r,f,d,p,hr({},null!=o?o:{}),n].filter(e=>!!e).reduce((e,t)=>({baseTheme:e,overrides:t}),h);return a&&c===l&&(function(e,t){const i=(e,t)=>e.length===t.length&&e.every((e,i)=>e===t[i]);return i(e.fills,t.fills)&&i(e.strokes,t.strokes)}(a,Mt._Theme.getChartTheme(h).palette)||(m.palette=a)),m}(this.chartProxyParams,this,this.isEnterpriseCharts,this.getChartThemeDefaults(),null!=e?e:n),o=dr(hr({},r),{mode:"integrated"});return o.theme=s,o.container=this.chartProxyParams.parentElement,o}getChartThemeDefaults(){const e=this.getSeriesChartThemeDefaults(),t=e?{[this.standaloneChartType]:e}:{},i={enabled:!0,snap:!0,label:{enabled:!1}};return hr({common:{navigator:{enabled:!1},zoom:{enabled:!0},animation:{enabled:!0,duration:500},axes:{number:{crosshair:i},category:{crosshair:i},log:{crosshair:i},time:{crosshair:i}}}},t)}getSeriesChartThemeDefaults(){}getActiveFormattingPanelOverrides(){var e,t;if(this.clearThemeOverrides)return{};const i=null==(e=this.chart)?void 0:e.getOptions().theme;return null!=(t=null==i?void 0:i.overrides)?t:{}}destroy({keepChartInstance:e=!1}={}){if(e)return this.chart.resetAnimations(),this.chart;this.destroyChart()}destroyChart(){this.chart&&(this.chart.destroy(),this.chart=void 0)}},_o=class extends Ro{constructor(e){super(e),this.crossFilteringAllPoints=new Set,this.crossFilteringSelectedPoints=[]}getUpdateOptions(e,t){const i=this.getAxes(e,t);return dr(hr({},t),{data:this.getData(e,i),axes:i,series:this.getSeries(e)})}getData(e,t){const i=["area","line"].includes(this.standaloneChartType);return this.crossFiltering&&i?this.getCrossFilterData(e):this.getDataTransformedData(e,t)}getDataTransformedData(e,t){const i=t[0].type,{categories:r,data:n}=e,[s]=r;switch(i){case"category":return this.transformCategoryData(n,s.id);case"time":return this.transformTimeData(n,s.id);default:return n}}getXAxisType(e){return e.grouping?"grouped-category":this.isXAxisOfType(e,"time",e=>e instanceof Date)?"time":this.isXAxisOfType(e,"number")?"number":"category"}isXAxisOfType(e,t,i){const[r]=e.categories;if(null==r?void 0:r.chartDataType)return r.chartDataType===t;if(!i)return!1;const n=e.data[0];return!!n&&i(n[r.id])}transformTimeData(e,t){var i;return(null==(i=e[0])?void 0:i[t])instanceof Date?e:e.map(e=>{const i=e[t];return"string"==typeof i?dr(hr({},e),{[t]:new Date(i)}):e})}crossFilteringReset(){this.crossFilteringSelectedPoints=[],this.crossFilteringAllPoints.clear()}crossFilteringPointSelected(e){return 0==this.crossFilteringSelectedPoints.length||this.crossFilteringSelectedPoints.includes(e)}crossFilteringDeselectedPoints(){return this.crossFilteringSelectedPoints.length>0&&this.crossFilteringAllPoints.size!==this.crossFilteringSelectedPoints.length}extractLineAreaCrossFilterSeries(e,t){const[i]=t.categories,r=e=>"area"===this.standaloneChartType?t.getCrossFilteringContext().lastSelectedChartId===t.chartId?e+"-total":e:e+"-total";return e.map(e=>(e.yKey=r(e.yKey),e.listeners={nodeClick:t=>{const i=t.datum[e.xKey],r=t.event.metaKey||t.event.ctrlKey;this.crossFilteringAddSelectedPoint(r,i),this.crossFilterCallback(t)}},e.marker={formatter:e=>{const t=e.datum[i.id];return{fill:e.highlighted?"yellow":e.fill,size:e.highlighted?14:this.crossFilteringPointSelected(t)?8:0}}},"area"===this.standaloneChartType&&(e.fillOpacity=this.crossFilteringDeselectedPoints()?.3:1),"line"===this.standaloneChartType&&(e.strokeOpacity=this.crossFilteringDeselectedPoints()?.3:1),e))}getCrossFilterData(e){this.crossFilteringAllPoints.clear();const[t]=e.categories,i=e.fields[0].colId,r=`${i}-filtered-out`,n=e.getCrossFilteringContext().lastSelectedChartId;return e.data.map(s=>{const o=s[t.id];this.crossFilteringAllPoints.add(o);const a=this.crossFilteringPointSelected(o);return"area"===this.standaloneChartType&&n===e.chartId&&(s[`${i}-total`]=a?s[i]:s[i]+s[r]),"line"===this.standaloneChartType&&(s[`${i}-total`]=a?s[i]:s[i]+s[r]),s})}crossFilteringAddSelectedPoint(e,t){e?this.crossFilteringSelectedPoints.push(t):this.crossFilteringSelectedPoints=[t]}isHorizontal(e){const t=this.standaloneChartType;if("waterfall"!==t&&"box-plot"!==t&&"range-bar"!==t)return!1;const i=e.theme,r=e=>{var i,n,s;const o=null==(s=null==(n=null==(i=null==e?void 0:e.overrides)?void 0:i[t])?void 0:n.series)?void 0:s.direction;return null!=o?"horizontal"===o:"object"==typeof(null==e?void 0:e.baseTheme)&&r(e.baseTheme)};return r(i)}};function Po(e,t){const i=parseInt(e.slice(1,3),16),r=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16);return t?`rgba(${i}, ${r}, ${n}, ${t})`:`rgba(${i}, ${r}, ${n})`}function xo(e,t){return e.map(e=>{const i=zi._Util.Color.fromString(e);return new zi._Util.Color(i.r,i.g,i.b,t).toHexString()})}var Do=new Set(["bar","groupedBar","stackedBar","normalizedBar"]),Io=class extends _o{constructor(e){super(e)}getAxes(e){const t=[{type:this.getXAxisType(e),position:this.isHorizontal()?"left":"bottom"},{type:"number",position:this.isHorizontal()?"bottom":"left"}];if(this.isNormalised()){const e=t[1];e.label=dr(hr({},e.label),{formatter:e=>Math.round(e.value)+"%"})}return t}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>{return{type:this.standaloneChartType,direction:this.isHorizontal()?"horizontal":"vertical",stacked:this.crossFiltering||(i=this.chartType,Er.has(i)),normalizedTo:this.isNormalised()?100:void 0,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName};var i});return this.crossFiltering?this.extractCrossFilterSeries(i):i}extractCrossFilterSeries(e){const t=this.getChartPalette(),i=(e,i)=>dr(hr({},e),{highlightStyle:{item:{fill:void 0}},fill:null==t?void 0:t.fills[i],stroke:null==t?void 0:t.strokes[i],listeners:{nodeClick:this.crossFilterCallback}}),r=e=>{const t=e.yKey+"-filtered-out";return dr(hr({},zr({},e)),{yKey:t,fill:Po(e.fill,"0.3"),stroke:Po(e.stroke,"0.3"),showInLegend:!1})},n=[];for(let t=0;t<e.length;t++){const s=i(e[t],t);n.push(s),n.push(r(s))}return n}isNormalised(){return!this.crossFiltering&&Hi._.includes(["normalizedColumn","normalizedBar"],this.chartType)}isHorizontal(){return Do.has(this.chartType)}},Lo=class extends _o{constructor(e){super(e)}getAxes(e){const t=[{type:this.getXAxisType(e),position:"bottom"},{type:"number",position:"left"}];if(this.isNormalised()){const e=t[1];e.label=dr(hr({},e.label),{formatter:e=>Math.round(e.value)+"%"})}return t}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>({type:this.standaloneChartType,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName,normalizedTo:"normalizedArea"===this.chartType?100:void 0,stacked:["normalizedArea","stackedArea"].includes(this.chartType)}));return this.crossFiltering?this.extractLineAreaCrossFilterSeries(i,e):i}isNormalised(){return!this.crossFiltering&&"normalizedArea"===this.chartType}},No=class extends _o{constructor(e){super(e)}getAxes(e){return[{type:this.getXAxisType(e),position:"bottom"},{type:"number",position:"left"}]}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>({type:this.standaloneChartType,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName}));return this.crossFiltering?this.extractLineAreaCrossFilterSeries(i,e):i}},Oo=class extends Ro{constructor(e){super(e)}getAxes(e){const t="radial-bar"===this.standaloneChartType;return[{type:t?"angle-number":"angle-category"},{type:t?"radius-category":"radius-number"}]}getSeries(e){const{fields:t,categories:i,seriesGroupType:r}=e,[n]=i,s="radial-bar"===this.standaloneChartType,o=this.getSeriesGroupTypeOptions(r);return t.map(e=>{var t,i;return hr({type:this.standaloneChartType,angleKey:s?e.colId:n.id,angleName:s?null!=(t=e.displayName)?t:void 0:n.name,radiusKey:s?n.id:e.colId,radiusName:s?n.name:null!=(i=e.displayName)?i:void 0},o)})}getSeriesGroupType(){var e,t;const i=this.standaloneChartType;if(!["nightingale","radial-bar","radial-column"].includes(i))return;const r=null==(t=null==(e=this.getChart().series)?void 0:e[0])?void 0:t.properties.toJson(),n=()=>r.normalizedTo?"normalized":"stacked";return"nightingale"===i?r.grouped?"grouped":n():r.stacked?n():"grouped"}getUpdateOptions(e,t){const i=this.getAxes(e);return dr(hr({},t),{data:this.getData(e,i),axes:i,series:this.getSeries(e)})}getData(e,t){if(t.some(e=>"angle-category"===e.type||"radius-category"===e.type)){const[t]=e.categories;return this.transformCategoryData(e.data,t.id)}return e.data}getSeriesGroupTypeOptions(e){return e?{grouped:"grouped"===e||void 0,stacked:"grouped"!==e||void 0,normalizedTo:"normalized"===e?100:void 0}:{}}},Fo=class e extends Ro{constructor(e){super(e)}getUpdateOptions(e,t){return dr(hr({},t),{data:this.crossFiltering?this.getCrossFilterData(e):e.data,series:this.getSeries(e)})}getSeries(t){const[i]=t.categories,r=t.fields.length,n={currentOffset:0,offsetAmount:r>1?20:40},s=this.getFields(t).map(t=>{var s;const o={type:this.standaloneChartType,angleKey:t.colId,angleName:t.displayName,sectorLabelKey:t.colId,calloutLabelName:i.name,calloutLabelKey:i.id};if("donut"===this.chartType||"doughnut"===this.chartType){const{outerRadiusOffset:i,innerRadiusOffset:a}=e.calculateOffsets(n),l=t.displayName?{title:{text:t.displayName,showInLegend:r>1}}:void 0;return dr(hr(dr(hr({},o),{type:"donut",outerRadiusOffset:i,innerRadiusOffset:a}),l),{calloutLine:{colors:null==(s=this.getChartPalette())?void 0:s.strokes}})}return o});return this.crossFiltering?this.extractCrossFilterSeries(s):s}getCrossFilterData(e){const t=e.fields[0].colId,i=`${t}-filtered-out`;return e.data.map(e=>{const r=e[t]+e[i];return e[`${t}-total`]=r,e[i]=1,e[t]=e[t]/r,e})}extractCrossFilterSeries(e){const t=this.getChartPalette(),i=e[0],r=i.angleKey,n=(e=>dr(hr({},e),{legendItemKey:e.calloutLabelKey,calloutLabel:{enabled:!1},highlightStyle:{item:{fill:void 0}},radiusKey:e.angleKey,angleKey:e.angleKey+"-total",radiusMin:0,radiusMax:1,listeners:{nodeClick:this.crossFilterCallback}}))(i);return[(s=i,o=r,dr(hr({},zr({},n)),{radiusKey:o+"-filtered-out",fills:xo(null!=(a=s.fills)?a:t.fills,.3),strokes:xo(null!=(l=s.strokes)?l:t.strokes,.3),showInLegend:!1})),n];var s,o,a,l}static calculateOffsets(e){const t=e.currentOffset;e.currentOffset-=e.offsetAmount;const i=e.currentOffset;return e.currentOffset-=e.offsetAmount,{outerRadiusOffset:t,innerRadiusOffset:i}}getFields(e){return"pie"===this.chartType?e.fields.slice(0,1):e.fields}},ko=class extends _o{constructor(e){super(e)}getAxes(e){return[{type:"number",position:"bottom"},{type:"number",position:"left"}]}getSeries(e){const[t]=e.categories,i=this.isPaired(),r=this.getSeriesDefinitions(e.fields,i),n=t.id===Or.DEFAULT_CATEGORY?void 0:t,s=r.map(e=>{var t,i,r,s,o;return(null==e?void 0:e.sizeField)?{type:"bubble",xKey:e.xField.colId,xName:null!=(t=e.xField.displayName)?t:void 0,yKey:e.yField.colId,yName:null!=(i=e.yField.displayName)?i:void 0,title:`${e.yField.displayName} vs ${e.xField.displayName}`,sizeKey:e.sizeField.colId,sizeName:null!=(r=e.sizeField.displayName)?r:"",labelKey:n?n.id:e.yField.colId,labelName:n?n.name:void 0}:{type:"scatter",xKey:e.xField.colId,xName:null!=(s=e.xField.displayName)?s:void 0,yKey:e.yField.colId,yName:null!=(o=e.yField.displayName)?o:void 0,title:`${e.yField.displayName} vs ${e.xField.displayName}`,labelKey:n?n.id:e.yField.colId,labelName:n?n.name:void 0}});return this.crossFiltering?this.extractCrossFilterSeries(s,e):s}extractCrossFilterSeries(e,t){const{data:i}=t,r=this.getChartPalette(),n=e=>`${e}-filtered-out`,s=e.map((e,t)=>{const s=null==r?void 0:r.fills[t],o=null==r?void 0:r.strokes[t];let a;if("bubble"===e.type){const{sizeKey:t}=e;a=((e,t)=>{var i;const r=[1/0,-1/0];if(null!=t)for(const s of e){const e=null!=(i=s[t])?i:s[n(t)];e<r[0]&&(r[0]=e),e>r[1]&&(r[1]=e)}if(r[0]<=r[1])return r})(i,t)}const l=dr(hr({},e.marker),{fill:s,stroke:o,domain:a});return dr(hr({},e),{marker:l,highlightStyle:{item:{fill:"yellow"}},listeners:dr(hr({},e.listeners),{nodeClick:this.crossFilterCallback})})});return[...s,...s.map(e=>{let{yKey:t,xKey:i}=e,r={};return"bubble"===e.type&&(r={sizeKey:n(e.sizeKey)}),dr(hr(hr({},e),r),{yKey:n(t),xKey:n(i),marker:dr(hr({},e.marker),{fillOpacity:.3,strokeOpacity:.3}),showInLegend:!1,listeners:dr(hr({},e.listeners),{nodeClick:e=>{const t=e.datum[n(i)],r=dr(hr({},e),{xKey:i,datum:dr(hr({},e.datum),{[i]:t})});this.crossFilterCallback(r)}})})})]}getSeriesDefinitions(e,t){if(e.length<2)return[];const i="bubble"===this.chartType;if(t)return i?e.map((t,i)=>i%3==0?{xField:t,yField:e[i+1],sizeField:e[i+2]}:null).filter(e=>e&&e.yField&&e.sizeField):e.map((t,i)=>i%2==0?{xField:t,yField:e[i+1]}:null).filter(e=>e&&e.yField);const r=e[0];return i?e.map((t,i)=>i%2==1?{xField:r,yField:t,sizeField:e[i+1]}:null).filter(e=>e&&e.sizeField):e.filter((e,t)=>t>0).map(e=>({xField:r,yField:e}))}},Go=class extends _o{constructor(e){super(e)}getAxes(e,t){return[{type:this.getXAxisType(e),position:this.isHorizontal(t)?"left":"bottom"},{type:"number",position:this.isHorizontal(t)?"bottom":"left"}]}computeSeriesStatistics(e,t){const{data:i,fields:r}=e,[n]=e.categories,s=n.id||Or.DEFAULT_CATEGORY,o=this.groupDataByCategory(s,i);return Array.from(o).map(([e,i])=>{const s={[n.id]:e};return r.forEach((e,r)=>{const n=i.map(t=>t[e.colId]).filter(e=>"number"==typeof e&&!isNaN(e));Object.entries(t(n)).forEach(([e,t])=>{s[`${e}:${r}`]=n.length>0?t:null})}),s})}groupDataByCategory(e,t){return t.reduce((t,i)=>{let r=(t=>{if(e===Or.DEFAULT_CATEGORY)return 1;const i=t[e];return null==i?"":i instanceof Date?i.getTime():i})(i);const n=t.get(r);return n?n.push(i):t.set(r,[i]),t},new Map)}},Vo=class extends Go{constructor(e){super(e)}getSeries(e){const[t]=e.categories;return e.fields.map((e,i)=>{var r;return{type:this.standaloneChartType,xKey:t.id,xName:t.name,yName:null!=(r=e.displayName)?r:void 0,yLowName:"Min",yHighName:"Max",yLowKey:`min:${i}`,yHighKey:`max:${i}`}})}getData(e){return this.computeSeriesStatistics(e,e=>({min:Math.min(...e),max:Math.max(...e)}))}},Ho=class extends _o{constructor(e){super(e)}getSeries(e){const t=e.fields[0];return[{type:this.standaloneChartType,xKey:t.colId,xName:t.displayName,yName:this.chartProxyParams.translate("histogramFrequency"),areaPlot:!1}]}getAxes(e){return[{type:"number",position:"bottom"},{type:"number",position:"left"}]}},Bo=class extends Go{constructor(e){super(e)}getSeries(e){const[t]=e.categories;return e.fields.map((e,i)=>{var r;return{type:this.standaloneChartType,xKey:t.id,xName:t.name,yName:null!=(r=e.displayName)?r:void 0,minName:"Min",q1Name:"Q1",medianName:"Median",q3Name:"Q3",maxName:"Max",minKey:`min:${i}`,q1Key:`q1:${i}`,medianKey:`median:${i}`,q3Key:`q3:${i}`,maxKey:`max:${i}`}})}getData(e){return this.computeSeriesStatistics(e,e=>{const t=e.sort((e,t)=>e-t);return{min:t[0],q1:this.quantile(t,.25),median:this.quantile(t,.5),q3:this.quantile(t,.75),max:t[t.length-1]}})}quantile(e,t){const i=(e.length-1)*t,r=Math.floor(i),n=i-r;return void 0!==e[r+1]?e[r]+n*(e[r+1]-e[r]):e[r]}},zo=class extends Ro{constructor(e){super(e)}getUpdateOptions(e,t){const i="AG-GRID-DEFAULT-HEATMAP-SERIES-KEY",r="AG-GRID-DEFAULT-HEATMAP-VALUE-KEY",n="AG-GRID-DEFAULT-HEATMAP-CATEGORY-KEY";return dr(hr({},t),{series:this.getSeries(e,i,r,n),data:this.getData(e,i,r,n)})}getSeries(e,t,i,r){const[n]=e.categories;return[{type:this.standaloneChartType,yKey:r,xKey:t,colorKey:i,yName:n.name,xName:void 0,colorName:void 0}]}getData(e,t,i,r){const[n]=e.categories;return s=e.data,o=(s,o)=>{const a=s[n.id],l=null==a?"":String(a),c={id:o,value:a,toString:()=>l};return e.fields.map(({colId:e,displayName:n})=>dr(hr({},s),{[t]:n,[i]:s[e],[r]:c}))},s.reduce((e,t,i,r)=>e.concat(o(t,i)),new Array);var s,o}getSeriesChartThemeDefaults(){return{gradientLegend:{gradient:{preferredLength:200}},series:{tooltip:{renderer:Uo}}}}};function Uo(e){const{xKey:t,yKey:i,colorKey:r,yName:n,datum:s}=e;return{title:"",content:[{label:n,value:s[i]},{label:s[t],value:r&&s[r]}].map(({label:e,value:t})=>`<b>${Wo(String(e))}:</b> ${Wo(String(t))}`).join("<br>")}}function Wo(e){const t={"&":"&amp;","<":"&lt;",">":"&gt;"},i=`[${Object.keys(t).join("")}]`,r=new RegExp(i,"g");return e.replace(r,e=>t[e])}var jo=class extends _o{constructor(e){super(e)}getAxes(e,t){return[{type:this.getXAxisType(e),position:this.isHorizontal(t)?"left":"bottom"},{type:"number",position:this.isHorizontal(t)?"bottom":"left"}]}getSeries(e){var t;const[i]=e.categories,[r]=e.fields;return[{type:this.standaloneChartType,xKey:i.id,xName:i.name,yKey:r.colId,yName:null!=(t=r.displayName)?t:void 0}]}},Ko=["number","category","time","grouped-category"],$o=[...Ko,"angle-category","angle-number","radius-category","radius-number"],qo=class e extends Ui.BeanStub{constructor(e){super(),this.chartController=e}getChartThemeOverridesProxy(){return{getValue:e=>this.getChartOption(e),setValue:(e,t)=>this.setChartThemeOverrides([{expression:e,value:t}]),setValues:e=>this.setChartThemeOverrides(e)}}getAxisThemeOverridesProxy(){return{getValue:e=>this.getAxisProperty(e),setValue:(e,t)=>this.setAxisThemeOverrides([{expression:e,value:t}]),setValues:e=>this.setAxisThemeOverrides(e)}}getCartesianAxisOptionsProxy(e){return{getValue:t=>this.getCartesianAxisProperty(e,t),setValue:(t,i)=>this.setCartesianAxisOptions(e,[{expression:t,value:i}]),setValues:t=>this.setCartesianAxisOptions(e,t)}}getCartesianAxisThemeOverridesProxy(e){return{getValue:t=>this.getCartesianAxisProperty(e,t),setValue:(t,i)=>this.setCartesianAxisThemeOverrides(e,[{expression:t,value:i}]),setValues:t=>this.setCartesianAxisThemeOverrides(e,t)}}getCartesianAxisAppliedThemeOverridesProxy(e){return{getValue:t=>this.getCartesianAxisThemeOverride(e,"*"===t?null:t),setValue:(t,i)=>this.setCartesianAxisThemeOverrides(e,[{expression:"*"===t?null:t,value:i}]),setValues:t=>this.setCartesianAxisThemeOverrides(e,t)}}getSeriesOptionsProxy(e){return{getValue:(t,i)=>this.getSeriesOption(e(),t,i),setValue:(t,i)=>this.setSeriesOptions(e(),[{expression:t,value:i}]),setValues:t=>this.setSeriesOptions(e(),t)}}getPersistedChartThemeOverrides(e,t,i,r){const n=this.getRetainedChartThemeOverrideKeys(i,r),s=this.getRetainedChartAxisThemeOverrideKeys(null,i,r),o=this.createChartOptions();for(const t of n){const n=this.retrieveChartOptionsThemeOverride(e,i,t);void 0!==n&&this.assignChartOptionsThemeOverride(o,r,t,n)}return t&&this.assignPersistedAxisOverrides({existingAxes:t,retainedChartAxisThemeOverrideKeys:s,existingChartOptions:e,targetChartOptions:o,existingChartType:i,targetChartType:r}),o.theme.overrides}assignPersistedAxisOverrides(e){const{existingAxes:t,retainedChartAxisThemeOverrideKeys:i,existingChartOptions:r,targetChartOptions:n,existingChartType:s,targetChartType:o}=e;for(const{expression:e,targetAxisTypes:a}of i)for(const i of t.map(e=>e.type)){const t=this.retrieveChartOptionsThemeOverride(r,s,["axes",i,e].join("."));if(void 0!==t)for(const i of a)this.assignChartOptionsThemeOverride(n,o,["axes",i,e].join("."),t)}}getRetainedChartThemeOverrideKeys(e,t){const i=["zoom","navigator"];return["animation",...((e,t)=>{const r=new Array;return Ar(Pr(e))&&Ar(Pr(t))&&r.push(...i),r})(e,t)]}getRetainedChartAxisThemeOverrideKeys(e,t,i){return Ar(Pr(t))&&Ar(Pr(i))?this.getRetainedCartesianAxisThemeOverrideKeys(e).map(e=>({expression:e,targetAxisTypes:Ko})):[]}getRetainedCartesianAxisThemeOverrideKeys(e){const t="xAxis"===e?["",".top",".bottom"]:"yAxis"===e?["",".left",".right"]:["",".left",".right",".top",".bottom"],i=["crosshair"],r=new Array;for(const e of i)for(const i of t)r.push(`${e}${i}`);return r}getChartOption(e){return Ur(this.getChart(),e,void 0)}setChartThemeOverrides(e){const t=this.getChartType(),i=this.createChartOptions();for(const{expression:r,value:n}of e)this.assignChartOptionsThemeOverride(i,t,r,n);this.applyChartOptions(i)}applyChartOptions(e,t){0!==Object.keys(e).length&&(this.updateChart(e),!(null==t?void 0:t.silent)&&this.raiseChartOptionsChangedEvent())}awaitChartOptionUpdate(e){this.chartController.getChartProxy().getChart().waitForUpdate().then(()=>e()).catch(e=>console.error("AG Grid - chart update failed",e))}getAxisProperty(e){var t;return Ur(null==(t=this.getChart().axes)?void 0:t[0],e,void 0)}setAxisThemeOverrides(e){var t;const i=this.getChart(),r=this.getChartType();let n=this.createChartOptions();for(const{expression:s,value:o}of e){const e=null==(t=i.axes)?void 0:t.filter(e=>{const t=s.split(".");let i=e;for(const e of t){if(!(e in i))return!1;i=i[e]}return!0});if(e)for(const t of e)this.isValidAxisType(t)&&this.assignChartAxisThemeOverride(n,r,t.type,null,s,o)}this.applyChartOptions(n)}getCartesianAxisProperty(e,t){const i=this.getChartAxes();return Ur(this.getCartesianAxis(i,e),t,void 0)}getCartesianAxisThemeOverride(e,t){const i=this.getChartAxes(),r=this.getCartesianAxis(i,e);if(!r||!this.isValidAxisType(r))return;const n=this.getChartType(),s=this.getChart().getOptions();return this.retrieveChartAxisThemeOverride(s,n,r.type,"yAxis"===e?["left","right"]:["bottom","top"],t)}setCartesianAxisThemeOverrides(e,t){const i=this.getChartAxes(),r=this.getCartesianAxis(i,e);if(!r||!this.isValidAxisType(r))return;const n=this.getChartType();let s=this.createChartOptions();for(const{expression:i,value:o}of t)this.assignChartAxisThemeOverride(s,n,r.type,"yAxis"===e?["left","right"]:["bottom","top"],i,o);this.applyChartOptions(s)}setCartesianAxisOptions(e,t){this.updateCartesianAxisOptions(e,(e,i,r)=>{const n=i.indexOf(r);for(const{expression:i,value:r}of t)this.assignChartOption(e,`axes.${n}.${i}`,r)})}updateCartesianAxisOptions(e,t){const i=this.getChart().getOptions(),r="axes"in i?i.axes:void 0;if(!i||!r)return;const n=this.getChartAxes(),s=this.getCartesianAxis(n,e);if(!s)return;let o=this.createChartOptions();o.axes=r,t(o,n,s,i),this.applyChartOptions(o)}setCartesianCategoryAxisType(e,t){this.updateCartesianAxisOptions(e,(i,r,n,s)=>{const o=this.getChartType();this.assignPersistedAxisOverrides({existingAxes:[n],retainedChartAxisThemeOverrideKeys:this.getRetainedChartAxisThemeOverrideKeys(e,o,o),existingChartOptions:s,targetChartOptions:i,existingChartType:o,targetChartType:o}),this.assignChartOption(i,"axes.0.type",t),this.chartController.setCategoryAxisType(t)})}getCartesianAxis(e,t){if(!(e.length<2))switch(t){case"xAxis":return"x"===e[0].direction?e[0]:e[1];case"yAxis":return"y"===e[1].direction?e[1]:e[0]}}getSeriesOption(t,i,r){const n=this.getChart().series.find(i=>e.isMatchingSeries(t,i));return Ur(r?n:null==n?void 0:n.properties.toJson(),i,void 0)}setSeriesOptions(e,t){let i=this.createChartOptions();for(const{expression:r,value:n}of t)this.assignChartOptionsSeriesThemeOverride(i,e,`series.${r}`,n);this.applyChartOptions(i)}getPairedMode(){return this.chartController.getChartProxy().isPaired()}setPairedMode(e){this.chartController.getChartProxy().setPaired(e)}getChartAxes(){var e;return null!=(e=this.getChart().axes)?e:[]}retrieveChartAxisThemeOverride(e,t,i,r,n){if(!r)return this.retrieveChartOptionsThemeOverride(e,t,["axes",i,...n?[n]:[]].join("."));for(const s of r){const r=this.retrieveChartOptionsThemeOverride(e,t,["axes",i,s,...n?[n]:[]].join("."));if(void 0!==r)return r}}assignChartAxisThemeOverride(e,t,i,r,n,s){if(r)for(const o of r)this.assignChartOptionsThemeOverride(e,t,["axes",i,o,...n?[n]:[]].join("."),s);else this.assignChartOptionsThemeOverride(e,t,["axes",i,...n?[n]:[]].join("."),s)}isValidAxisType(e){return $o.includes(e.type)}getChartType(){return this.chartController.getChartType()}getChart(){return this.chartController.getChartProxy().getChart()}updateChart(e){const t=this.chartController.getChartProxy().getChartRef();t.skipAnimations(),Wi.AgCharts.updateDelta(t,e)}createChartOptions(){return{theme:{overrides:{}}}}retrieveChartOptionsThemeOverride(e,t,i){const r=this.getChartThemeOverridesSeriesTypeKeys(t);for(const t of r){const r=this.retrieveChartOptionsSeriesThemeOverride(e,t,i);if(void 0!==r)return r}}assignChartOptionsThemeOverride(e,t,i,r){const n=this.getChartThemeOverridesSeriesTypeKeys(t);for(const t of n)this.assignChartOptionsSeriesThemeOverride(e,t,i,r)}retrieveChartOptionsSeriesThemeOverride(e,t,i){return this.retrieveChartOption(e,["theme","overrides",t,...i?[i]:[]].join("."))}assignChartOptionsSeriesThemeOverride(e,t,i,r){this.assignChartOption(e,["theme","overrides",t,...i?[i]:[]].join("."),r)}getChartThemeOverridesSeriesTypeKeys(e){const t=this.chartController.getChartSeriesTypes(e);return this.chartController.isComboChart()&&t.push("common"),t}retrieveChartOption(e,t){return Ur(e,t,void 0)}assignChartOption(e,t,i){!function(e,t,i){if(null==e)return;const r=t.split(".");let n=e;r.forEach((e,t)=>{n[e]||(n[e]={}),t<r.length-1&&(n=n[e])}),n[r[r.length-1]]=i}(e,t,i)}raiseChartOptionsChangedEvent(){const e=this.chartController.getChartModel(),t={type:Ui.Events.EVENT_CHART_OPTIONS_CHANGED,chartId:e.chartId,chartType:e.chartType,chartThemeName:this.chartController.getChartThemeName(),chartOptions:e.chartOptions};this.eventService.dispatchEvent(t)}static isMatchingSeries(e,t){return function(e){return!!wr[e]}(e)&&t.type===e}destroy(){super.destroy()}},Yo=class extends _o{constructor(e){super(e)}getAxes(e){const t=e?e.fields:[],i=new Map(t.map(e=>[e.colId,e])),{primaryYKeys:r,secondaryYKeys:n}=this.getYKeys(t,e.seriesChartTypes),s=[{type:this.getXAxisType(e),position:"bottom"}];return r.length>0&&s.push({type:"number",keys:r,position:"left"}),n.length>0&&n.forEach(e=>{const t=i.get(e);if(!t||t.colId!==e)return;const r={type:"number",keys:[e],position:"right"};s.push(r)}),s}getSeries(e){const{fields:t,seriesChartTypes:i}=e,[r]=e.categories;return t.map(e=>{const t=i.find(t=>t.colId===e.colId);if(t){const i=t.chartType,n=["groupedColumn","groupedBar"].includes(i)?{grouped:!0}:{};return hr({type:Pr(i),xKey:r.id,yKey:e.colId,yName:e.displayName,stacked:["stackedArea","stackedColumn"].includes(i)},n)}})}getYKeys(e,t){const i=[],r=[];return e.forEach(e=>{const n=e.colId,s=t.find(e=>e.colId===n);s&&(s.secondaryAxis?r.push(n):i.push(n))}),{primaryYKeys:i,secondaryYKeys:r}}},Qo=["chartSettings","chartData","chartFormat"],Xo=["chartUnlink","chartLink","chartDownload"],Zo={settings:"chartSettings",data:"chartData",format:"chartFormat"},Jo=class extends ji.BeanStub{isLegacyFormat(){return!this.chartService.isEnterprise()}downloadChart(e,t,i,r){e.chartController.getChartProxy().downloadChart(t,i,r)}toggleLinked(e){e.chartController.detachChartRange()}openAdvancedSettings(e,t){this.advancedSettingsMenuFactory.showMenu(e,t)}hideAdvancedSettings(){this.advancedSettingsMenuFactory.hideMenu()}getToolbarOptionsAndPanels(e){var t,i,r;const n=this.isLegacyFormat();let s,o,a;if(Boolean(this.gos.get("chartToolPanelsDef"))||!n){const l=n?[e.isChartLinked()?"chartLink":"chartUnlink","chartDownload"]:["chartMenu"],c=this.gos.getCallback("getChartToolbarItems");a=c?c({defaultItems:l}).filter(e=>{if(!(n?Xo:[...Xo,"chartMenu"]).includes(e)){let t;return t=Qo.includes(e)?`'${e}' is a Chart Tool Panel option and will be ignored since 'chartToolPanelsDef' is used. Please use 'chartToolPanelsDef.panels' grid option instead`:"chartMenu"===e?"'chartMenu' is only allowed as a Chart Toolbar Option when using AG Charts Enterprise":`'${e}' is not a valid Chart Toolbar Option`,ji._.warnOnce(t),!1}return!0}):l;const u=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.panels)?void 0:i.map(e=>{const t=Zo[e];return t||ji._.warnOnce(`Invalid panel in chartToolPanelsDef.panels: '${e}'`),t}).filter(e=>Boolean(e));s=u||Object.values(Zo),e.isPivotChart()&&(s=s.filter(e=>"chartData"!==e));const h=null==(r=this.gos.get("chartToolPanelsDef"))?void 0:r.defaultToolPanel;o=h&&Zo[h]||s[0],n&&(a=s.length>0?[s[0],...a]:a)}else{let t=["chartSettings","chartData","chartFormat",e.isChartLinked()?"chartLink":"chartUnlink","chartDownload"];const i=this.gos.getCallback("getChartToolbarItems");if(i){const e=this.gos.get("suppressChartToolPanelsButton");t=i({defaultItems:e?t:Xo}).filter(t=>{if(!Qo.includes(t)&&!Xo.includes(t))return ji._.warnOnce(`'${t}' is not a valid Chart Toolbar Option`),!1;if(!e&&Qo.includes(t)){const e=`'${t}' is a Chart Tool Panel option and will be ignored. Please use 'chartToolPanelsDef.panels' grid option instead`;return ji._.warnOnce(e),!1}return!0}),e||(t=t.concat(Qo))}e.isPivotChart()&&(t=t.filter(e=>"chartData"!==e));const r=["chartUnlink","chartLink","chartDownload"];s=t.filter(e=>-1===r.indexOf(e)),o=s[0],a=t.filter(e=>-1!==r.indexOf(e)||s.length&&e===s[0])}return{panels:s,defaultPanel:o,chartToolbarOptions:a}}doesChartToolbarExist(e){const{chartToolbarOptions:t}=this.getToolbarOptionsAndPanels(e);return["chartMenu",...Xo].some(e=>t.includes(e))}doChartToolPanelsExist(e){const{panels:t}=this.getToolbarOptionsAndPanels(e);return t.length>0}};gr([(0,ji.Autowired)("chartService")],Jo.prototype,"chartService",2),gr([(0,ji.Autowired)("advancedSettingsMenuFactory")],Jo.prototype,"advancedSettingsMenuFactory",2),Jo=gr([(0,ji.Bean)("chartMenuService")],Jo);var ea="AG-GRID-DEFAULT-LABEL-KEY";function ta(e,t=null,i){const{depth:r,rootValues:n,value:s,children:o}=e;if(n)return n.map(e=>hr({[ea]:t},e));if(0===r)return[hr({[ea]:t},s)];const a=[];for(const[e,t]of o.entries())a.push(...ta(t,e,!0));return i?[hr({[ea]:t,children:a},null!=s?s:{})]:a}function ia(e,t,i){const r={depth:0,children:new Map};return e.forEach(e=>{n(e,t(e),i,0,r)}),r;function n(e,t,i,r,s){if(r===t)return 0===r?(s.rootValues||(s.rootValues=[]),s.rootValues.push(e)):s.value=e,s;{const o=i(e,r),a=n(e,t,i,r+1,s.children.get(o)||{depth:0,children:new Map});return s.children.set(o,a),s.depth=Math.max(1+a.depth,s.depth),s}}}var ra=class extends Ro{constructor(e){super(e)}getUpdateOptions(e,t){const{fields:i}=e,[r,n]=i;return dr(hr({},t),{series:this.getSeries(r,n),data:this.getData(e,r,n)})}getSeriesChartThemeDefaults(){return{gradientLegend:{gradient:{preferredLength:200}}}}getSeries(e,t){var i,r;return[{type:this.standaloneChartType,labelKey:ea,sizeKey:null==e?void 0:e.colId,sizeName:null!=(i=null==e?void 0:e.displayName)?i:void 0,colorKey:null==t?void 0:t.colId,colorName:null!=(r=null==t?void 0:t.displayName)?r:void 0}]}getData(e,t,i){var r;const{categories:n,data:s,groupData:o,grouping:a}=e;return a?function(e,t){return ta(ia(e,function(e){var i,r;return null!=(r=null==(i=t(e))?void 0:i.length)?r:0},function(e,i){const r=t(e);return r?r[r.length-1-i]:null}))}(i?s.concat(null!=(r=null==o?void 0:o.map(e=>{const i=hr({},e);return delete i[t.colId],i}))?r:[]):s,e=>{var t,i;return null!=(i=null==(t=e[Ki.GROUP_AUTO_COLUMN_ID])?void 0:t.labels)?i:null}):function(e,t){return ta(ia(e,function(e){return t.length},function(e,i){return null==(r=e[t[i]])?null:String(r);var r}))}(s,n.map(({id:e})=>e))}},na=class e extends gt.Component{constructor(t){super(e.TEMPLATE),this.params=t}init(){const e=dr(hr({},this.params),{chartType:Rr(this.params.chartType),chartThemeName:this.getThemeName()}),t=this.gos.get("enableRtl");this.addCssClass(t?"ag-rtl":"ag-ltr");const i=this.createBean(new Or(e));this.chartController=this.createManagedBean(new sn(i)),this.chartOptionsService=this.createManagedBean(new qo(this.chartController)),this.validateCustomThemes(),this.createChart(),this.params.insideDialog&&this.addDialog(),this.addMenu(),this.addTitleEditComp(),this.addManagedListener(this.getGui(),"focusin",this.setActiveChartCellRange.bind(this)),this.addManagedListener(this.chartController,sn.EVENT_CHART_MODEL_UPDATE,this.update.bind(this)),this.addManagedPropertyListeners(["chartThemeOverrides","chartThemes"],this.reactivePropertyUpdate.bind(this)),this.update(),this.raiseChartCreatedEvent()}createChart(){var t;let i;this.chartProxy&&(i=this.chartProxy.destroy({keepChartInstance:!0}));const r=this.chartController.getChartType(),n={chartType:r,chartInstance:i,getChartThemeName:this.getChartThemeName.bind(this),getChartThemes:this.getChartThemes.bind(this),customChartThemes:this.gos.get("customChartThemes"),getGridOptionsChartThemeOverrides:()=>this.getGridOptionsChartThemeOverrides(),getExtraPaddingDirections:()=>{var e,t;return null!=(t=null==(e=this.chartMenu)?void 0:e.getExtraPaddingDirections())?t:[]},apiChartThemeOverrides:this.params.chartThemeOverrides,crossFiltering:null!=(t=this.params.crossFiltering)&&t,crossFilterCallback:(e,t)=>{this.params.crossFilteringContext.lastSelectedChartId=t?"":this.chartController.getChartId(),t&&this.params.crossFilteringResetCallback(),this.crossFilterService.filter(e,t)},parentElement:this.eChart,grouping:this.chartController.isGrouping(),chartThemeToRestore:this.params.chartThemeName,chartOptionsToRestore:this.params.chartOptionsToRestore,chartPaletteToRestore:this.params.chartPaletteToRestore,seriesChartTypes:this.chartController.getSeriesChartTypes(),translate:e=>this.chartTranslationService.translate(e)};if(this.params.chartOptionsToRestore=void 0,this.chartType=r,this.chartProxy=e.createChartProxy(n),!this.chartProxy)return void console.warn("AG Grid: invalid chart type supplied: ",n.chartType);const s=this.eChart.querySelector("canvas");s&&s.classList.add("ag-charts-canvas"),this.chartController.setChartProxy(this.chartProxy),this.createMenuContext(),this.titleEdit&&this.titleEdit.refreshTitle(this.chartMenuContext)}createMenuContext(){if(this.chartMenuContext)return;const e=this.createManagedBean(new In(this.chartOptionsService.getChartThemeOverridesProxy())),t=this.createManagedBean(new In(this.chartOptionsService.getAxisThemeOverridesProxy()));this.chartMenuContext={chartController:this.chartController,chartOptionsService:this.chartOptionsService,chartMenuParamsFactory:e,chartAxisMenuParamsFactory:t}}getChartThemeName(){return this.chartController.getChartThemeName()}getChartThemes(){return this.chartController.getThemeNames()}getGridOptionsChartThemeOverrides(){return this.gos.get("chartThemeOverrides")}static createChartProxy(e){switch(e.chartType){case"column":case"bar":case"groupedColumn":case"stackedColumn":case"normalizedColumn":case"groupedBar":case"stackedBar":case"normalizedBar":return new Io(e);case"pie":case"donut":case"doughnut":return new Fo(e);case"area":case"stackedArea":case"normalizedArea":return new Lo(e);case"line":return new No(e);case"scatter":case"bubble":return new ko(e);case"histogram":return new Ho(e);case"radarLine":case"radarArea":case"nightingale":case"radialColumn":case"radialBar":return new Oo(e);case"rangeBar":case"rangeArea":return new Vo(e);case"boxPlot":return new Bo(e);case"treemap":case"sunburst":return new ra(e);case"heatmap":return new zo(e);case"waterfall":return new jo(e);case"columnLineCombo":case"areaColumnCombo":case"customCombo":return new Yo(e);default:throw`AG Grid: Unable to create chart as an invalid chartType = '${e.chartType}' was supplied.`}}addDialog(){const e=this.chartTranslationService.translate(this.params.pivotChart?"pivotChartTitle":"rangeChartTitle"),{width:t,height:i}=this.getBestDialogSize();this.chartDialog=new gt.AgDialog({resizable:!0,movable:!0,maximizable:!0,title:e,width:t,height:i,component:this,centered:!0,closable:!0}),this.getContext().createBean(this.chartDialog),this.chartDialog.addEventListener(gt.AgDialog.EVENT_DESTROYED,()=>{this.destroy(),this.chartMenuService.hideAdvancedSettings()})}getBestDialogSize(){const e=this.popupService.getPopupParent(),t=.75*gt._.getAbsoluteWidth(e),i=.75*gt._.getAbsoluteHeight(e),r=this.chartProxy.getChart();let n=this.params.insideDialog?850:r.width,s=this.params.insideDialog?470:r.height;return(n>t||s>i)&&(n=Math.min(n,t),s=Math.round(.553*n),s>i&&(s=i,n=Math.min(n,Math.round(s/.553)))),{width:n,height:s}}addMenu(){this.params.crossFiltering||(this.chartMenu=this.createBean(new Eo(this.eChartContainer,this.eMenuContainer,this.chartMenuContext)),this.eChartContainer.appendChild(this.chartMenu.getGui()))}addTitleEditComp(){this.titleEdit=this.createBean(new To(this.chartMenu)),this.eTitleEditContainer.appendChild(this.titleEdit.getGui()),this.chartProxy&&this.titleEdit.refreshTitle(this.chartMenuContext)}update(e){if((null==e?void 0:e.chartId)&&!this.chartController.update(e))return;const t=this.chartTypeChanged(e),i=t||this.chartEmpty?(e=>{const t=this.chartType,i=e,r=this.chartProxy.getChart(),n=null==r?void 0:r.getOptions(),s=null==r?void 0:r.axes;return this.chartOptionsService.getPersistedChartThemeOverrides(n,s,t,null!=i?i:t)})(t):void 0;t&&this.createChart();const r=i&&(null==e?void 0:e.chartThemeOverrides)?zr(i,e.chartThemeOverrides):i||(null==e?void 0:e.chartThemeOverrides);this.updateChart(r),(null==e?void 0:e.chartId)&&this.chartProxy.getChart().waitForUpdate().then(()=>{this.chartController.raiseChartApiUpdateEvent()})}updateChart(e){const{chartProxy:t}=this,i=this.chartController.getSelectedValueColState(),r=this.chartController.getChartData(),n=this.handleEmptyChart(r,i.length);if(this.chartEmpty=n,n)return void(e&&this.chartController.updateThemeOverrides(e));let s=this.chartController.getChartUpdateParams(e);t.update(s),this.chartProxy.getChart().waitForUpdate().then(()=>{this.chartController.raiseChartUpdatedEvent()}),this.titleEdit.refreshTitle(this.chartMenuContext)}chartTypeChanged(e){const[t,i]=[this.chartController.getChartType(),null==e?void 0:e.chartType],r=i?Rr(i):void 0;return this.chartType!==t?null!=r?r:t:r&&t!==r?r:null}getChartModel(){return this.chartController.getChartModel()}getChartImageDataURL(e){return this.chartProxy.getChartImageDataURL(e)}handleEmptyChart(e,t){const i=this.chartController.isPivotChart()&&!this.chartController.isPivotMode(),r=this.chartController.getChartType();let n=1;this.chartController.isActiveXYChart()?n="bubble"===r?3:2:Mr(Pr(r))&&(n=0);const s=t<n||0===e.length;if(this.eChart){const e=i||s;gt._.setDisplayed(this.eChart,!e),gt._.setDisplayed(this.eEmpty,e)}return i?(this.eEmpty.innerText=this.chartTranslationService.translate("pivotChartRequiresPivotMode"),!0):!!s&&(this.eEmpty.innerText=this.chartTranslationService.translate("noDataToChart"),!0)}downloadChart(e,t,i){this.chartProxy.downloadChart(e,t,i)}openChartToolPanel(e){const t=e?Zo[e]:e;this.chartMenu.showMenu({panel:t})}closeChartToolPanel(){this.chartMenu.hideMenu()}getChartId(){return this.chartController.getChartId()}getUnderlyingChart(){return this.chartProxy.getChartRef()}crossFilteringReset(){this.chartProxy.crossFilteringReset()}setActiveChartCellRange(e){this.getGui().contains(e.relatedTarget)||(this.chartController.setChartRange(!0),this.focusService.clearFocusedCell())}getThemeName(){const e=this.gos.get("chartThemes")||rn;if(0===e.length)throw new Error("Cannot create chart: no chart themes available.");const{chartThemeName:t}=this.params;return gt._.includes(e,t)?t:e[0]}getAllKeysInObjects(e){const t={};return e.filter(e=>null!=e).forEach(e=>{Object.keys(e).forEach(e=>t[e]=null)}),Object.keys(t)}validateCustomThemes(){const e=this.getChartThemes(),t=this.gos.get("customChartThemes");t&&this.getAllKeysInObjects([t]).forEach(t=>{gt._.includes(e,t)||console.warn("AG Grid: a custom chart theme with the name '"+t+"' has been supplied but not added to the 'chartThemes' list")})}reactivePropertyUpdate(){this.chartController.setChartThemeName(this.getThemeName(),!0);const e=this.getChartId(),t=this.chartController.isCrossFilterChart()?"crossFilter":this.getChartModel().modelType,i=this.gos.get("chartThemeOverrides")||{};this.update({type:`${t}ChartUpdate`,chartId:e,chartThemeOverrides:i})}raiseChartCreatedEvent(){const e={type:gt.Events.EVENT_CHART_CREATED,chartId:this.chartController.getChartId()};this.chartProxy.getChart().waitForUpdate().then(()=>{this.eventService.dispatchEvent(e)})}raiseChartDestroyedEvent(){const e={type:gt.Events.EVENT_CHART_DESTROYED,chartId:this.chartController.getChartId()};this.eventService.dispatchEvent(e)}destroy(){var e;super.destroy(),this.chartProxy&&this.chartProxy.destroy(),this.destroyBean(this.chartMenu),this.destroyBean(this.titleEdit),this.chartDialog&&this.chartDialog.isAlive()&&this.destroyBean(this.chartDialog),null==(e=this.onDestroyColorSchemeChangeListener)||e.call(this);const t=this.getGui();gt._.clearElement(t),gt._.removeFromParent(t),this.raiseChartDestroyedEvent()}};na.TEMPLATE='<div class="ag-chart" tabindex="-1">\n            <div ref="eChartContainer" tabindex="-1" class="ag-chart-components-wrapper">\n                <div ref="eChart" class="ag-chart-canvas-wrapper"></div>\n                <div ref="eEmpty" class="ag-chart-empty-text ag-unselectable"></div>\n            </div>\n            <div ref="eTitleEditContainer"></div>\n            <div ref="eMenuContainer" class="ag-chart-docked-container" style="min-width: 0px;"></div>\n        </div>',gr([(0,gt.RefSelector)("eChart")],na.prototype,"eChart",2),gr([(0,gt.RefSelector)("eChartContainer")],na.prototype,"eChartContainer",2),gr([(0,gt.RefSelector)("eMenuContainer")],na.prototype,"eMenuContainer",2),gr([(0,gt.RefSelector)("eEmpty")],na.prototype,"eEmpty",2),gr([(0,gt.RefSelector)("eTitleEditContainer")],na.prototype,"eTitleEditContainer",2),gr([(0,gt.Autowired)("chartCrossFilterService")],na.prototype,"crossFilterService",2),gr([(0,gt.Autowired)("chartTranslationService")],na.prototype,"chartTranslationService",2),gr([(0,gt.Autowired)("chartMenuService")],na.prototype,"chartMenuService",2),gr([(0,gt.Autowired)("focusService")],na.prototype,"focusService",2),gr([(0,gt.Autowired)("popupService")],na.prototype,"popupService",2),gr([gt.PostConstruct],na.prototype,"init",1);var sa=na,oa="31.3.4";function aa(e){return e=Ra("chartOptions.legend.item.marker.type","shape",e),e=Ra("chartOptions.seriesDefaults.marker.type","shape",e),Ra("chartOptions.legend.padding","spacing",e)}function la(e){var t;const i=e=_a("chartOptions.seriesDefaults.marker.minSize",e),{chartType:r,chartPalette:n,chartOptions:s}=i,o=s,{xAxis:a,yAxis:l}=o,c=pr(o,["xAxis","yAxis"]),u=pr(i,["chartType","chartPalette","chartOptions"]),h=function(e){switch(e){case"bar":case"stackedBar":case"normalizedBar":return["number","category"];case"groupedBar":return["number","grouped-category"];case"column":case"stackedColumn":case"normalizedColumn":case"line":case"area":case"stackedArea":case"normalizedArea":case"histogram":return["category","number"];case"groupedColumn":return["grouped-category","number"];case"scatter":case"bubble":return["number","number"];default:return}}(r),d=null==h?void 0:h.map((e,t)=>hr({type:e},0===t?a:l));return hr({chartType:r,chartThemeName:null!=(t={borneo:"ag-default",material:"ag-material",bright:"ag-vivid"}[n])?t:"ag-default",chartOptions:dr(hr({},c),{axes:d,xAxis:a,yAxis:l})},u)}function ca(e){return Ra("chartOptions.seriesDefaults.label.minRequiredAngle","minAngle",e)}function ua(e){return e=_a("chart",e=xa("chartOptions.seriesDefaults.highlightStyle",e,e=>{var t=e,{dimOpacity:i}=t,r=pr(t,["dimOpacity"]);return hr(hr({},r),null!=i?{series:{dimOpacity:i}}:{})})),e=_a("chartOptions.seriesDefaults.tooltipClass",e),e=ba("chartOptions.axes[].label.rotation",0,e=_a("chartOptions.seriesDefaults.tooltipTracking",e)),ba("chartOptions.axes[].label.rotation",335,e)}function ha(e){const t=e=>{var t=e,{item:i,series:r}=t,n=pr(t,["item","series"]);return hr({item:hr(hr({},n),i)},r?{series:r}:{})};return e=xa("chartOptions.seriesDefaults.highlightStyle",e,t),xa("chartOptions.series[].highlightStyle",e,t)}function da(e){e=Ta("chartOptions.seriesDefaults.fill.opacity","chartOptions.seriesDefaults.fillOpacity",e),e=Ta("chartOptions.seriesDefaults.stroke.opacity","chartOptions.seriesDefaults.strokeOpacity",e),e=_a("chartOptions.seriesDefaults.fill",e=Ta("chartOptions.seriesDefaults.stroke.width","chartOptions.seriesDefaults.strokeWidth",e)),e=_a("chartOptions.seriesDefaults.stroke",e),e=_a("chartOptions.seriesDefaults.callout.colors",e),e=_a("chartOptions.xAxis",e);const t=e=_a("chartOptions.yAxis",e),{chartType:i,chartOptions:r}=t,n=r,{axes:s,series:o,seriesDefaults:a}=n,l=pr(n,["axes","series","seriesDefaults"]),c=pr(t,["chartType","chartOptions"]),u=Rr(i),h=Pr(u),d=[h],p={};if(!xr(h)){const e={top:{},bottom:{},left:{},right:{}},t=s.map(t=>{var i=t,{type:r}=i,n=pr(i,["type"]);return{[r]:hr(hr({},e),n)}}).reduce(Da,{});Fr.filter(e=>null==t[e]).forEach(i=>{t[i]=hr({},e)}),p.axes=t}const g=d.map(e=>({[e]:hr(dr(hr({},p),{series:a}),l)})).reduce(Da,{});return dr(hr({},c),{chartType:u,chartOptions:g})}function pa(e){return e=_a("chartOptions.*.title.padding",e),e=_a("chartOptions.*.subtitle.padding",e),Ea("chartOptions.*.axes.*.title.enabled",!1,e=_a("chartOptions.*.axes.*.title.padding",e))}function ga(e){return e=Ra("chartOptions.pie.series.callout","calloutLine",e),e=Ra("chartOptions.pie.series.label","calloutLabel",e),e=Ra("chartOptions.pie.series.labelKey","sectorLabelKey",e),e=Ra("chartOptions.pie.series.labelName","sectorLabelName",e),e=Ra("chartOptions.donut.series.callout","calloutLine",e),e=Ra("chartOptions.donut.series.label","calloutLabel",e),e=Ra("chartOptions.donut.series.labelKey","sectorLabelKey",e),Ra("chartOptions.donut.series.labelName","sectorLabelName",e)}function fa(e){return e=Ma("chartOptions.scatter.series.fill","chartOptions.scatter.series.marker.fill",e),e=Ma("chartOptions.scatter.series.fillOpacity","chartOptions.scatter.series.marker.fillOpacity",e),e=Ma("chartOptions.scatter.series.stroke","chartOptions.scatter.series.marker.stroke",e),e=Ma("chartOptions.scatter.series.strokeOpacity","chartOptions.scatter.series.marker.strokeOpacity",e),Ta("chartOptions.scatter.series.paired","chartOptions.scatter.paired",e=Ma("chartOptions.scatter.series.strokeWidth","chartOptions.scatter.series.marker.strokeWidth",e))}function ma(e){return _a("chartOptions.axes[].tick.count",e)}function va(e){return xa("chartOptions.*.tooltip",e,e=>{var t=e,{tracking:i}=t,r=pr(t,["tracking"]);const n=hr({},r);return!1===i?(null!=n.position||(n.position={type:"pointer"}),null!=n.range||(n.range="nearest")):!0===i&&(null!=n.position||(n.position={type:"node"}),null!=n.range||(n.range="nearest")),n})}function Ca(e){return e=Ra("chartOptions.pie.series.labelKey","sectorLabelKey",e),Ea("chartOptions.common.legend.position","right",e=Aa("chartOptions.common.legend.enabled",!0,e=_a("chartOptions.*.series.flipXY",e=va(e=ma(e=Ra("chartOptions.pie.series.labelName","sectorLabelName",e))))))}function ya(e){const t=Ra("chartOptions.column","bar",e),i={"ag-pastel":"ag-sheets","ag-solar":"ag-polychroma"}[t.chartThemeName]||t.chartThemeName;return dr(hr({},t),{chartThemeName:i})}function wa(e,t,i){if(Sa(e)>Sa(t.version)){const r=i(t);return r.version=e,r}return t}function Sa(e){const{major:t,minor:i,patch:r}=function(e){const t="string"==typeof e?e.split(".").map(e=>Number(e)):[];if(3!==t.length||t.some(e=>isNaN(e)))throw new Error("AG Grid - Illegal version string: "+e);return{major:t[0],minor:t[1],patch:t[2]}}(e);return 1e4*t+100*i+r}function ba(e,t,i){return Pa(e,!0,i,(e,i)=>{e[i]===t&&delete e[i]})}function Ea(e,t,i){return Pa(e,!1,i,(e,i)=>{null==e[i]&&(e[i]=t)})}function Aa(e,t,i){var r;"string"==typeof e&&(e=e.split("."));const n=e[0];return e.length>1&&(i[n]=Aa(e.slice(1),t,null!=(r=i[n])?r:{})),Object.keys(i).includes(n)||(i[n]=t),i}function Ta(e,t,i){let r,n=!1;return i=Pa(e,!0,i,(e,t)=>{n=!0,r=e[t],delete e[t]}),n?Pa(t,!1,i,(e,t)=>{e[t]=r}):i}function Ma(e,t,i){let r,n=!1;return i=Pa(e,!0,i,(e,t)=>{n=!0,r=e[t],delete e[t]}),n?Pa(t,!1,i,(e,t)=>{void 0===e[t]&&(e[t]=r)}):i}function Ra(e,t,i){return Pa(e,!0,i,(e,i)=>{e[t]=e[i],delete e[i]})}function _a(e,t){return Pa(e,!0,t,(e,t)=>delete e[t])}function Pa(e,t,i,r){const n=e instanceof Array?e:e.split("."),s=n.slice(0,n.length-1),o=n[n.length-1];return xa(s,i,e=>{const i=Object.keys(e).includes(o);if(t&&!i)return e;const n=hr({},e);return r(n,o),n})}function xa(e,t,i){const r=e instanceof Array?e:e.split(".");if(t=hr({},t),0===r.length)return i(t);if(r[0].startsWith("{")){const e=r[0].substring(1,r[0].lastIndexOf("}")).split(",");for(const n of e)null!=t[n]&&(t[n]=xa(r.slice(1),t[n],i))}else if(r[0].endsWith("[]")){const n=r[0].substring(0,e[0].indexOf("["));t[n]instanceof Array&&(t[n]=t[n].map(e=>xa(r.slice(1),e,i)))}else if("*"===r[0])for(const e in t)t[e]=xa(r.slice(1),t[e],i);else null!=t[r[0]]&&(t[r[0]]=xa(r.slice(1),t[r[0]],i));return t}var Da=(e,t)=>hr(hr({},e),t),Ia=class extends dt.BeanStub{constructor(){super(...arguments),this.activeCharts=new Set,this.activeChartComps=new Set,this.crossFilteringContext={lastSelectedChartId:""},this.isEnterprise=()=>pt._ModuleSupport.enterpriseModule.isEnterprise}updateChart(e){if(0===this.activeChartComps.size)return void console.warn("AG Grid - No active charts to update.");const t=[...this.activeChartComps].find(t=>t.getChartId()===e.chartId);t?t.update(e):console.warn(`AG Grid - Unable to update chart. No active chart found with ID: ${e.chartId}.`)}getChartModels(){const e=[];return this.activeChartComps.forEach(t=>e.push((e=>dr(hr({},e),{version:oa}))(t.getChartModel()))),e}getChartRef(e){let t;return this.activeCharts.forEach(i=>{i.chartId===e&&(t=i)}),t}getChartComp(e){let t;return this.activeChartComps.forEach(i=>{i.getChartId()===e&&(t=i)}),t}getChartImageDataURL(e){let t;return this.activeChartComps.forEach(i=>{i.getChartId()===e.chartId&&(t=i.getChartImageDataURL(e.fileFormat))}),t}downloadChart(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e.chartId);null==t||t.downloadChart(e.dimensions,e.fileName,e.fileFormat)}openChartToolPanel(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e.chartId);null==t||t.openChartToolPanel(e.panel)}closeChartToolPanel(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e);null==t||t.closeChartToolPanel()}createChartFromCurrentRange(e="groupedColumn"){const t=this.getSelectedRange();return this.createChart({cellRange:t,chartType:e})}restoreChart(e,t){if(!e)return void console.warn("AG Grid - unable to restore chart as no chart model is provided");let i,r,n,s;return e.version!==oa&&(e=function(e){return e.version,null==e.version&&(e.version=function(e){var t,i;const r=e;if(null!=e.version)return e.version;const n=(e,...t)=>Object.keys(e||{}).some(e=>t.includes(e)),s=r.chartOptions,o=n(s,"seriesDefaults")?null==s?void 0:s.seriesDefaults:null==s?void 0:s[Object.keys(s)[0]],a={"27.0.0":n(r,"seriesChartTypes"),"26.2.0":!n(s,"seriesDefaults"),"26.1.0":n(null==o?void 0:o.highlightStyle,"item"),"26.0.0":n(null==o?void 0:o.highlightStyle,"series"),"25.1.0":n(null==o?void 0:o.label,"minAngle"),"25.0.0":n(r,"modelType","aggFunc","unlinkChart","suppressChartRanges")||n(o,"lineDash","lineDashOffset"),"24.0.0":n(r,"chartThemeName","chart")||n(s,"series"),"23.2.0":n(s,"navigator"),"23.0.0":n(null==(i=null==(t=null==s?void 0:s.legend)?void 0:t.item)?void 0:i.marker,"shape"),"22.1.0":n(r,"chartPalette","chartType")},l="27.1.0",c=Object.entries(a).filter(([e,t])=>t),[u=l]=c[0];return u}(e)),e=wa("23.0.0",e,aa),e=wa("24.0.0",e,la),e=wa("25.1.0",e,ca),e=wa("26.0.0",e,ua),e=wa("26.1.0",e,ha),e=wa("26.2.0",e,da),e=wa("28.0.0",e,pa),e=wa("28.2.0",e,ga),e=wa("29.0.0",e,fa),e=wa("29.1.0",e,ma),e=wa("29.2.0",e,va),e=wa("30.0.0",e,Ca),e=function(e){return e=_a("chartOptions.*.width",e),Ea("chartOptions.*.axes.category.label.autoRotate",!0,e=_a("chartOptions.*.height",e))}(e=wa("31.0.0",e,ya)),wa(oa,e,e=>e)}(e)),"pivot"===e.modelType?(this.gos.updateGridOptions({options:{pivotMode:!0},source:"pivotChart"}),i=this.createCellRange(void 0,!0),r=!0,n=!0):(i=this.createCellRange(e.cellRange),s=e.chartPalette),i?this.createChart(dr(hr({},e),{cellRange:i,pivotChart:r,suppressChartRanges:n,chartContainer:t,chartOptionsToRestore:e.chartOptions,chartPaletteToRestore:s})):void 0}createRangeChart(e){const t=this.createCellRange(e.cellRange);if(t)return this.createChart(dr(hr({},e),{cellRange:t}))}createPivotChart(e){this.gos.updateGridOptions({options:{pivotMode:!0},source:"pivotChart"});const t=this.createCellRange(void 0,!0);if(t)return this.createChart(dr(hr({},e),{cellRange:t,pivotChart:!0,suppressChartRanges:!0}))}createCrossFilterChart(e){const t=this.createCellRange(e.cellRange);if(!t)return;const i=!(void 0!==e.suppressChartRanges&&null!==e.suppressChartRanges)||e.suppressChartRanges;return this.createChart(dr(hr({},e),{cellRange:t,suppressChartRanges:i,crossFiltering:!0}))}createChart(e){const t=tn.validateCreateParams(e);if(!t)return;e=!0===t?e:t;const{chartType:i,chartContainer:r}=e,n=this.gos.getCallback("createChartContainer"),s=dr(hr({},e),{chartId:this.generateId(),chartType:Rr(i),insideDialog:!(r||n),crossFilteringContext:this.crossFilteringContext,crossFilteringResetCallback:()=>this.activeChartComps.forEach(e=>e.crossFilteringReset())}),o=new sa(s);this.context.createBean(o);const a=this.createChartRef(o);if(r){r.appendChild(o.getGui());const e=this.environment.getTheme();e.el&&!e.el.contains(r)&&r.classList.add(e.theme)}else n?n(a):o.addEventListener(sa.EVENT_DESTROYED,()=>{this.activeChartComps.delete(o),this.activeCharts.delete(a)});return a}createChartRef(e){const t={destroyChart:()=>{this.activeCharts.has(t)&&(this.context.destroyBean(e),this.activeChartComps.delete(e),this.activeCharts.delete(t))},chartElement:e.getGui(),chart:e.getUnderlyingChart(),chartId:e.getChartModel().chartId};return this.activeCharts.add(t),this.activeChartComps.add(e),t}getSelectedRange(){var e,t;const i=null!=(t=null==(e=this.rangeService)?void 0:e.getCellRanges())?t:[];return i.length>0?i[0]:{columns:[]}}generateId(){return`id-${Math.random().toString(36).substring(2,18)}`}createCellRange(e,t){var i;const r=t?{rowStartIndex:null,rowStartPinned:void 0,rowEndIndex:null,rowEndPinned:void 0,columns:this.columnModel.getAllDisplayedColumns().map(e=>e.getColId())}:e,n=r&&(null==(i=this.rangeService)?void 0:i.createPartialCellRangeFromRangeParams(r,!0));return n||console.warn(`AG Grid - unable to create chart as ${t?"there are no columns in the grid":"no range is selected"}.`),n}destroyAllActiveCharts(){this.activeCharts.forEach(e=>e.destroyChart())}};Ia.CHARTS_VERSION=pt.VERSION,gr([(0,dt.Autowired)("columnModel")],Ia.prototype,"columnModel",2),gr([(0,dt.Optional)("rangeService")],Ia.prototype,"rangeService",2),gr([dt.PreDestroy],Ia.prototype,"destroyAllActiveCharts",1),Ia=gr([(0,dt.Bean)("chartService")],Ia);var La=class extends $i.BeanStub{translate(e){return this.localeService.getLocaleTextFunc()(e,La.DEFAULT_TRANSLATIONS[e])}};La.DEFAULT_TRANSLATIONS={pivotChartTitle:"Pivot Chart",rangeChartTitle:"Range Chart",settings:"Chart",data:"Data",format:"Format",categories:"Categories",defaultCategory:"(None)",series:"Series",switchCategorySeries:"Switch Category / Series",categoryValues:"Category Values",seriesLabels:"Series Labels",aggregate:"Aggregate",xyValues:"X Y Values",paired:"Paired Mode",axis:"Axis",xAxis:"Horizontal Axis",yAxis:"Vertical Axis",polarAxis:"Polar Axis",radiusAxis:"Radius Axis",navigator:"Navigator",zoom:"Zoom",animation:"Animation",crosshair:"Crosshair",color:"Color",thickness:"Thickness",preferredLength:"Preferred Length",xType:"X Type",axisType:"Axis Type",automatic:"Automatic",category:"Category",number:"Number",time:"Time",timeFormat:"Time Format",autoRotate:"Auto Rotate",labelRotation:"Rotation",circle:"Circle",orientation:"Orientation",polygon:"Polygon",fixed:"Fixed",parallel:"Parallel",perpendicular:"Perpendicular",radiusAxisPosition:"Position",ticks:"Ticks",gridLines:"Grid Lines",width:"Width",height:"Height",length:"Length",padding:"Padding",spacing:"Spacing",chart:"Chart",title:"Title",titlePlaceholder:"Chart title - double click to edit",background:"Background",font:"Font",top:"Top",right:"Right",bottom:"Bottom",left:"Left",labels:"Labels",calloutLabels:"Callout Labels",sectorLabels:"Sector Labels",positionRatio:"Position Ratio",size:"Size",shape:"Shape",minSize:"Minimum Size",maxSize:"Maximum Size",legend:"Legend",position:"Position",markerSize:"Marker Size",markerStroke:"Marker Stroke",markerPadding:"Marker Padding",itemSpacing:"Item Spacing",itemPaddingX:"Item Padding X",itemPaddingY:"Item Padding Y",layoutHorizontalSpacing:"Horizontal Spacing",layoutVerticalSpacing:"Vertical Spacing",strokeWidth:"Stroke Width",offset:"Offset",offsets:"Offsets",tooltips:"Tooltips",callout:"Callout",markers:"Markers",shadow:"Shadow",blur:"Blur",xOffset:"X Offset",yOffset:"Y Offset",lineWidth:"Line Width",lineDash:"Line Dash",lineDashOffset:"Dash Offset",scrollingZoom:"Scrolling",scrollingStep:"Scrolling Step",selectingZoom:"Selecting",durationMillis:"Duration (ms)",crosshairLabel:"Label",crosshairSnap:"Snap to Node",normal:"Normal",bold:"Bold",italic:"Italic",boldItalic:"Bold Italic",predefined:"Predefined",fillOpacity:"Fill Opacity",strokeColor:"Line Color",strokeOpacity:"Line Opacity",miniChart:"Mini-Chart",histogramBinCount:"Bin count",connectorLine:"Connector Line",seriesItems:"Series Items",seriesItemType:"Item Type",seriesItemPositive:"Positive",seriesItemNegative:"Negative",seriesItemLabels:"Item Labels",columnGroup:"Column",barGroup:"Bar",pieGroup:"Pie",lineGroup:"Line",scatterGroup:"X Y (Scatter)",areaGroup:"Area",polarGroup:"Polar",statisticalGroup:"Statistical",hierarchicalGroup:"Hierarchical",specializedGroup:"Specialized",combinationGroup:"Combination",groupedColumnTooltip:"Grouped",stackedColumnTooltip:"Stacked",normalizedColumnTooltip:"100% Stacked",groupedBarTooltip:"Grouped",stackedBarTooltip:"Stacked",normalizedBarTooltip:"100% Stacked",pieTooltip:"Pie",donutTooltip:"Donut",lineTooltip:"Line",groupedAreaTooltip:"Area",stackedAreaTooltip:"Stacked",normalizedAreaTooltip:"100% Stacked",scatterTooltip:"Scatter",bubbleTooltip:"Bubble",histogramTooltip:"Histogram",radialColumnTooltip:"Radial Column",radialBarTooltip:"Radial Bar",radarLineTooltip:"Radar Line",radarAreaTooltip:"Radar Area",nightingaleTooltip:"Nightingale",rangeBarTooltip:"Range Bar",rangeAreaTooltip:"Range Area",boxPlotTooltip:"Box Plot",treemapTooltip:"Treemap",sunburstTooltip:"Sunburst",heatmapTooltip:"Heatmap",waterfallTooltip:"Waterfall",columnLineComboTooltip:"Column & Line",areaColumnComboTooltip:"Area & Column",customComboTooltip:"Custom Combination",innerRadius:"Inner Radius",startAngle:"Start Angle",endAngle:"End Angle",reverseDirection:"Reverse Direction",groupPadding:"Group Padding",seriesPadding:"Series Padding",group:"Group",tile:"Tile",whisker:"Whisker",cap:"Cap",capLengthRatio:"Length Ratio",labelPlacement:"Placement",inside:"Inside",outside:"Outside",noDataToChart:"No data available to be charted.",pivotChartRequiresPivotMode:"Pivot Chart requires Pivot Mode enabled.",chartSettingsToolbarTooltip:"Menu",chartLinkToolbarTooltip:"Linked to Grid",chartUnlinkToolbarTooltip:"Unlinked from Grid",chartDownloadToolbarTooltip:"Download Chart",chartMenuToolbarTooltip:"Menu",chartEdit:"Edit Chart",chartAdvancedSettings:"Advanced Settings",chartLink:"Link to Grid",chartUnlink:"Unlink from Grid",chartDownload:"Download Chart",histogramFrequency:"Frequency",seriesChartType:"Series Chart Type",seriesType:"Series Type",secondaryAxis:"Secondary Axis",seriesAdd:"Add a series",categoryAdd:"Add a category",area:"Area",bar:"Bar",column:"Column",line:"Line",scatter:"Scatter",histogram:"Histogram",radialColumn:"Radial Column",radialBar:"Radial Bar",radarLine:"Radar Line",radarArea:"Radar Area",nightingale:"Nightingale",rangeBar:"Range Bar",rangeArea:"Range Area",treemap:"Treemap",sunburst:"Sunburst",waterfall:"Waterfall",boxPlot:"Box Plot",pie:"Pie",donut:"Donut",stackedArea:"StackedArea",groupedColumn:"Grouped Column",stackedColumn:"Stacked Column",advancedSettings:"Advanced Settings",ariaChartMenuClose:"Close Chart Edit Menu",timeFormatSlashesDDMMYYYY:"DD/MM/YYYY",timeFormatSlashesMMDDYYYY:"MM/DD/YYYY",timeFormatSlashesDDMMYY:"DD/MM/YY",timeFormatSlashesMMDDYY:"MM/DD/YY",timeFormatDotsDDMYY:"DD.M.YY",timeFormatDotsMDDYY:"M.DD.YY",timeFormatDashesYYYYMMDD:"YYYY-MM-DD",timeFormatSpacesDDMMMMYYYY:"DD MMMM YYYY",timeFormatHHMMSS:"HH:MM:SS",timeFormatHHMMSSAmPm:"HH:MM:SS AM/PM",sum:"Sum",first:"First",last:"Last",min:"Min",max:"Max",count:"Count",avg:"Average",direction:"Direction",horizontal:"Horizontal",vertical:"Vertical",seriesGroupType:"Group Type",groupedSeriesGroupType:"Grouped",stackedSeriesGroupType:"Stacked",normalizedSeriesGroupType:"100% Stacked"},La=gr([(0,$i.Bean)("chartTranslationService")],La);var Na=class extends qi.BeanStub{filter(e,t=!1){const i=this.gridApi.getFilterModel();if(t)return void this.resetFilters(i);let r=Na.extractFilterColId(e);this.isValidColumnFilter(r)?this.updateFilters(i,e,r):console.warn("AG Grid: cross filtering requires a 'agSetColumnFilter' or 'agMultiColumnFilter' to be defined on the column with id: '"+r+"'")}resetFilters(e){Object.keys(e).length>0&&(this.gridApi.setFilterModel(null),this.gridApi.onFilterChanged())}updateFilters(e,t,i){let r=Na.extractFilterColId(t),n=t.datum[r];if(void 0===n)return;let s=n.toString();if(t.event.metaKey||t.event.ctrlKey){const t=this.getCurrentGridValuesForCategory(i);let r;qi._.includes(t,s)?r=t.filter(e=>e!==s):(r=t,r.push(s)),e[i]=this.getUpdatedFilterModel(i,r)}else{const t=[s];e={[i]:this.getUpdatedFilterModel(i,t)}}this.gridApi.setFilterModel(e)}getUpdatedFilterModel(e,t){return"agMultiColumnFilter"===this.getColumnFilterType(e)?{filterType:"multi",filterModels:[null,{filterType:"set",values:t}]}:{filterType:"set",values:t}}getCurrentGridValuesForCategory(e){let t=[];const i=this.getColumnById(e);return this.gridApi.forEachNodeAfterFilter(e=>{if(i&&!e.group){const r=this.valueService.getValue(i,e)+"";t.includes(r)||t.push(r)}}),t}static extractFilterColId(e){return e.xKey||e.calloutLabelKey}isValidColumnFilter(e){e.indexOf("-filtered-out")&&(e=e.replace("-filtered-out",""));let t=this.getColumnFilterType(e);return"boolean"==typeof t?t:qi._.includes(["agSetColumnFilter","agMultiColumnFilter"],t)}getColumnFilterType(e){let t=this.getColumnById(e);if(t)return t.getColDef().filter}getColumnById(e){return this.columnModel.getGridColumn(e)}};function Oa(e){return e&&e.match(/\d+\.\d+\.\d+/)}function Fa({type:e,gridVersion:t,chartsVersion:i}){const r="AG Grid: AG Grid version is incompatible. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.";if(!t)return r;const n=function(e){if(!e||!Oa(e))return;const[t,i]=e.split(".")||[],r=`${t}.${i}.x`,n=parseInt(t,10)-28+6;return n<0?void 0:{gridMajorMinor:r,chartsMajorMinor:`${n}.${i}.x`}}(t);if(!n)return r;const{gridMajorMinor:s,chartsMajorMinor:o}=n;return"incompatible"===e?`AG Grid version ${t} and AG Charts version ${i} is not supported. AG Grid version ${s} should be used with AG Chart ${o}. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.`:"invalidCharts"===e?`AG Grid version ${s} should be used with AG Chart ${o}. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.`:r}gr([(0,qi.Autowired)("gridApi")],Na.prototype,"gridApi",2),gr([(0,qi.Autowired)("columnModel")],Na.prototype,"columnModel",2),gr([(0,qi.Autowired)("valueService")],Na.prototype,"valueService",2),Na=gr([(0,qi.Bean)("chartCrossFilterService")],Na);var ka=class extends Yi.BeanStub{showMenuList(e){const{eventSource:t,showMenu:i,chartMenuContext:r}=e,n=this.chartMenuService.doChartToolPanelsExist(r.chartController),s=this.mapWithStockItems(this.getMenuItems(r.chartController,n),r,i,t,n);if(!s.length)return;const o=this.createBean(new Ga(s));this.activeChartMenuList=o;let a=-1,l="left";this.gos.get("enableRtl")&&(a=1,l="right");const c=o.getGui();this.popupService.addPopup({modal:!0,eChild:c,closeOnEsc:!0,closedCallback:()=>{this.destroyBean(o),this.activeChartMenuList=void 0;const e=this.gos.getDocument(),i=this.gos.getActiveDomElement();i&&i!==e.body||t.focus({preventScroll:!0})},afterGuiAttached:e=>o.afterGuiAttached(e),positionCallback:()=>{this.popupService.positionPopupByComponent({type:"chartMenu",eventSource:t,ePopup:c,alignSide:l,nudgeX:4*a,nudgeY:4,position:"under",keepWithinBounds:!0})},ariaLabel:"Chart Menu"})}getMenuItems(e,t){const i=[...t?["chartEdit"]:[],...e.isEnterprise()?["chartAdvancedSettings"]:[],e.isChartLinked()?"chartUnlink":"chartLink","chartDownload"],r=this.gos.get("chartMenuItems");return r?Array.isArray(r)?r:r(this.gos.addGridCommonParams({defaultItems:i})):i}mapWithStockItems(e,t,i,r,n){if(!e)return[];const s=[];return e.forEach(e=>{let o;if(o="string"==typeof e?this.getStockMenuItem(e,t,i,r,n):hr({},e),!o)return;const{subMenu:a}=o;Array.isArray(a)&&(o.subMenu=this.mapWithStockItems(a,t,i,r,n)),s.push(o)}),s}getStockMenuItem(e,t,i,r,n){switch(e){case"chartEdit":return n?this.createMenuItem(this.chartTranslationService.translate("chartEdit"),"chartsMenuEdit",i):null;case"chartAdvancedSettings":return this.createMenuItem(this.chartTranslationService.translate("chartAdvancedSettings"),"chartsMenuAdvancedSettings",()=>this.chartMenuService.openAdvancedSettings(t,r));case"chartUnlink":return t.chartController.isChartLinked()?this.createMenuItem(this.chartTranslationService.translate("chartUnlink"),"unlinked",()=>this.chartMenuService.toggleLinked(t)):null;case"chartLink":return t.chartController.isChartLinked()?null:this.createMenuItem(this.chartTranslationService.translate("chartLink"),"linked",()=>this.chartMenuService.toggleLinked(t));case"chartDownload":return this.createMenuItem(this.chartTranslationService.translate("chartDownload"),"save",()=>this.chartMenuService.downloadChart(t))}return null}createMenuItem(e,t,i){return{name:e,icon:Yi._.createIconNoSpan(t,this.gos,null),action:i}}destroy(){this.destroyBean(this.activeChartMenuList),super.destroy()}};gr([(0,Yi.Autowired)("popupService")],ka.prototype,"popupService",2),gr([(0,Yi.Autowired)("chartMenuService")],ka.prototype,"chartMenuService",2),gr([(0,Yi.Autowired)("chartTranslationService")],ka.prototype,"chartTranslationService",2),ka=gr([(0,Yi.Bean)("chartMenuListFactory")],ka);var Ga=class extends Yi.Component{constructor(e){super('\n            <div ref="eChartsMenu" role="presentation" class="ag-menu ag-chart-menu-popup"></div>\n        '),this.menuItems=e}init(){this.mainMenuList=this.createManagedBean(new Yi.AgMenuList(0)),this.mainMenuList.addMenuItems(this.menuItems),this.mainMenuList.addEventListener(Yi.AgMenuItemComponent.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.eChartsMenu.appendChild(this.mainMenuList.getGui())}onHidePopup(){var e;null==(e=this.hidePopupFunc)||e.call(this)}afterGuiAttached({hidePopup:e}){e&&(this.hidePopupFunc=e,this.addDestroyFunc(e)),this.focusService.focusInto(this.mainMenuList.getGui())}};gr([(0,Yi.Autowired)("focusService")],Ga.prototype,"focusService",2),gr([(0,Yi.RefSelector)("eChartsMenu")],Ga.prototype,"eChartsMenu",2),gr([Yi.PostConstruct],Ga.prototype,"init",1);var Va=class e extends Zi.Component{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("animation.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("animation"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultNumberInputParams("animation.duration","durationMillis",{min:0});this.setTemplate(e.TEMPLATE,{animationGroup:t,animationHeightInput:i})}};Va.TEMPLATE='<div>\n            <ag-group-component ref="animationGroup">\n                <ag-input-number-field ref="animationHeightInput"></ag-input>\n            </ag-group-component>\n        </div>',gr([(0,Zi.Autowired)("chartTranslationService")],Va.prototype,"chartTranslationService",2),gr([Zi.PostConstruct],Va.prototype,"init",1);var Ha=Va,Ba=class e extends Ji.Component{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("crosshair.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("crosshair"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultCheckboxParams("crosshair.label.enabled","crosshairLabel"),r=this.chartMenuParamsFactory.getDefaultCheckboxParams("crosshair.snap","crosshairSnap"),n=this.chartMenuParamsFactory.getDefaultColorPickerParams("crosshair.stroke","color");this.setTemplate(e.TEMPLATE,{crosshairGroup:t,crosshairLabelCheckbox:i,crosshairSnapCheckbox:r,crosshairStrokeColorPicker:n})}};Ba.TEMPLATE='<div>\n            <ag-group-component ref="crosshairGroup">\n                <ag-checkbox ref="crosshairLabelCheckbox"></ag-checkbox>\n                <ag-checkbox ref="crosshairSnapCheckbox"></ag-checkbox>\n                <ag-color-picker ref="crosshairStrokeColorPicker"></ag-color-picker>\n            </ag-group-component>\n        </div>',gr([(0,Ji.Autowired)("chartTranslationService")],Ba.prototype,"chartTranslationService",2),gr([Ji.PostConstruct],Ba.prototype,"init",1);var za=Ba,Ua=class e extends er.Component{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("navigator.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("navigator"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultSliderParams("navigator.height","height",60);i.minValue=10;const r=this.chartMenuParamsFactory.getDefaultCheckboxParams("navigator.miniChart.enabled","miniChart");this.setTemplate(e.TEMPLATE,{navigatorGroup:t,navigatorHeightSlider:i,navigatorMiniChartCheckbox:r})}};Ua.TEMPLATE='<div>\n            <ag-group-component ref="navigatorGroup">\n                <ag-slider ref="navigatorHeightSlider"></ag-slider>\n                <ag-checkbox ref="navigatorMiniChartCheckbox"></ag-checkbox>\n            </ag-group-component>\n        </div>',gr([(0,er.Autowired)("chartTranslationService")],Ua.prototype,"chartTranslationService",2),gr([er.PostConstruct],Ua.prototype,"init",1);var Wa=Ua,ja=class e extends tr.Component{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("zoom.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("zoom"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultCheckboxParams("zoom.enableScrolling","scrollingZoom"),r=this.chartMenuParamsFactory.getDefaultSliderParams("zoom.scrollingStep","scrollingStep",1);r.step=.01,r.minValue=r.step;const n=this.chartMenuParamsFactory.getDefaultCheckboxParams("zoom.enableSelecting","selectingZoom");i.onValueChange=(e=>t=>{e&&(e(t),this.zoomScrollingStepInput.setDisabled(!t))})(i.onValueChange),this.setTemplate(e.TEMPLATE,{zoomGroup:t,zoomScrollingCheckbox:i,zoomScrollingStepInput:r,zoomSelectingCheckbox:n}),this.zoomScrollingStepInput.setDisabled(!i.value)}};ja.TEMPLATE='<div>\n            <ag-group-component ref="zoomGroup">\n                <ag-checkbox ref="zoomSelectingCheckbox"></ag-checkbox>\n                <ag-checkbox ref="zoomScrollingCheckbox"></ag-checkbox>\n                <ag-slider ref="zoomScrollingStepInput"></ag-slider>\n            </ag-group-component>\n        </div>',gr([(0,tr.Autowired)("chartTranslationService")],ja.prototype,"chartTranslationService",2),gr([(0,tr.RefSelector)("zoomScrollingStepInput")],ja.prototype,"zoomScrollingStepInput",2),gr([tr.PostConstruct],ja.prototype,"init",1);var Ka=ja,$a=["navigator","zoom","animation","crosshair"],qa=class e extends Xi.Component{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}postConstruct(){this.chartPanelFeature=this.createManagedBean(new gs(this.chartMenuContext.chartController,this.getGui(),"ag-chart-advanced-settings-section",(e,t)=>this.createPanels(e,t))),this.chartPanelFeature.refreshPanels()}createPanels(e,t){$a.forEach(e=>{if(!this.isGroupPanelShownForSeries(e,t))return;const i=this.createPanel(e);this.chartPanelFeature.addComponent(i)})}isGroupPanelShownForSeries(e,t){return"animation"===e||Ar(t)}createPanel(e){const{chartMenuParamsFactory:t,chartAxisMenuParamsFactory:i}=this.chartMenuContext;switch(e){case"navigator":return new Wa(t);case"zoom":return new Ka(t);case"animation":return new Ha(t);case"crosshair":return new za(i)}}};qa.TEMPLATE='<div class="ag-chart-advanced-settings-wrapper"></div>',gr([Xi.PostConstruct],qa.prototype,"postConstruct",1);var Ya=qa,Qa=class extends Qi.BeanStub{showMenu(e,t){this.hideMenu();const i=this.createBean(new Za(e));this.activeDialog=this.createBean(new Qi.AgDialog({title:this.chartTranslationService.translate("advancedSettings"),component:i,width:300,height:400,resizable:!0,movable:!0,centered:!0,closable:!0,afterGuiAttached:()=>{var e;null==(e=this.focusService.findFocusableElements(i.getGui())[0])||e.focus()},closedCallback:()=>{this.activeMenu=this.destroyBean(this.activeMenu),this.activeDialog=void 0,null==t||t.focus({preventScroll:!0})}})),this.activeMenu=i}hideMenu(){this.activeDialog&&this.destroyBean(this.activeDialog)}destroy(){this.activeMenu=this.destroyBean(this.activeMenu),this.activeDialog=this.destroyBean(this.activeDialog),super.destroy()}};gr([(0,Qi.Autowired)("focusService")],Qa.prototype,"focusService",2),gr([(0,Qi.Autowired)("chartTranslationService")],Qa.prototype,"chartTranslationService",2),Qa=gr([(0,Qi.Bean)("advancedSettingsMenuFactory")],Qa);var Xa=class e extends Qi.TabGuardComp{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}postConstruct(){this.advancedSettingsPanel=this.createManagedBean(new Ya(this.chartMenuContext)),this.getGui().appendChild(this.advancedSettingsPanel.getGui()),this.initialiseTabGuard({onTabKeyDown:this.onTabKeyDown.bind(this),focusTrapActive:!0})}onTabKeyDown(e){if(e.defaultPrevented)return;e.preventDefault();const t=e.shiftKey,i=this.advancedSettingsPanel.getGui(),r=this.focusService.findNextFocusableElement(i,!1,t);if(r)r.focus();else{const e=this.focusService.findFocusableElements(i);e.length&&e[t?e.length-1:0].focus()}}};Xa.TEMPLATE='<div class="ag-chart-advanced-settings"></div>',gr([(0,Qi.Autowired)("focusService")],Xa.prototype,"focusService",2),gr([Qi.PostConstruct],Xa.prototype,"postConstruct",1);var Za=Xa,Ja={version:oa,validate:()=>function({gridVersion:e,chartsVersion:t}){if(!Oa(t))return{isValid:!1,message:Fa({type:"invalidCharts",gridVersion:e,chartsVersion:t})};if(!Oa(e))return{isValid:!1,message:Fa({type:"invalidGrid",gridVersion:e,chartsVersion:t})};const[i,r]=e.split(".")||[],[n,s,o]=t.split(".")||[],a=function({gridMajorVersion:e,chartsMajorVersion:t}){const i=parseInt(e,10)-28;return i===parseInt(t,10)-6&&i>=0}({gridMajorVersion:i,chartsMajorVersion:n});return a&&r===s||o.includes("beta")?{isValid:!0}:a&&r===s?{isValid:!1,message:Fa({type:"invalid",gridVersion:e,chartsVersion:t})}:{isValid:!1,message:Fa({type:"incompatible",gridVersion:e,chartsVersion:t})}}({gridVersion:oa,chartsVersion:Ia.CHARTS_VERSION}),moduleName:Ve.ModuleNames.GridChartsModule,beans:[Ia,La,Na,ka,Jo,Qa],agStackComponents:[{componentName:"AgColorPicker",componentClass:Xn},{componentName:"AgAngleSelect",componentClass:Dn},{componentName:"AgPillSelect",componentClass:an}],dependantModules:[ht,_]},el=0,tl={time:ir.time,AgChart:ir.AgChart},il=i(98092),rl=i(98092),nl=i(98092),sl=Object.defineProperty,ol=Object.getOwnPropertyDescriptor,al=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?ol(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&sl(t,i,s),s},ll="paste",cl="dragCopy",ul="clipboard",hl=e=>`AG Grid: Unable to use the Clipboard API (navigator.clipboard.${e}()). The reason why it could not be used has been logged in the previous line. For this reason the grid has defaulted to using a workaround which doesn't perform as well. Either fix why Clipboard API is blocked, OR stop this message from appearing by setting grid property suppressClipboardApi=true (which will default the grid to using the workaround rather than the API.`,dl=class extends nl.BeanStub{constructor(){super(...arguments),this.lastPasteOperationTime=0,this.navigatorApiFailed=!1}init(){this.logger=this.loggerFactory.create("ClipboardService"),"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel),this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl})}pasteFromClipboard(){this.logger.log("pasteFromClipboard"),!this.gos.get("suppressClipboardApi")&&!this.navigatorApiFailed&&navigator.clipboard&&navigator.clipboard.readText?navigator.clipboard.readText().then(this.processClipboardData.bind(this)).catch(e=>{nl._.doOnce(()=>{console.warn(e),console.warn(hl("readText"))},"clipboardApiError"),this.navigatorApiFailed=!0,this.pasteFromClipboardLegacy()}):this.pasteFromClipboardLegacy()}pasteFromClipboardLegacy(){let e=!1;const t=t=>{const i=(new Date).getTime();i-this.lastPasteOperationTime<50&&(e=!0,t.preventDefault()),this.lastPasteOperationTime=i};this.executeOnTempElement(e=>{e.addEventListener("paste",t),e.focus({preventScroll:!0})},i=>{const r=i.value;e?this.refocusLastFocusedCell():this.processClipboardData(r),i.removeEventListener("paste",t)})}refocusLastFocusedCell(){const e=this.focusService.getFocusedCell();e&&this.focusService.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0})}getClipboardDelimiter(){const e=this.gos.get("clipboardDelimiter");return nl._.exists(e)?e:"\t"}processClipboardData(e){if(null==e)return;let t=dl.stringToArray(e,this.getClipboardDelimiter());const i=this.gos.getCallback("processDataFromClipboard");i&&(t=i({data:t})),null!=t&&(this.gos.get("suppressLastEmptyLineOnPaste")&&this.removeLastLineIfBlank(t),this.doPasteOperation((e,i,r,n)=>{var s;(null==(s=this.rangeService)?void 0:s.isMoreThanOneCell())&&!this.hasOnlyOneValueToPaste(t)?this.pasteIntoActiveRange(this.rangeService,t,e,i,n):this.pasteStartingFromFocusedCell(t,e,i,r,n)}))}static stringToArray(e,t=","){const i=[],r=e=>"\r"===e||"\n"===e;let n=!1;if(""===e)return[[""]];for(let s=0,o=0,a=0;a<e.length;a++){const l=e[a-1],c=e[a],u=e[a+1],h=()=>{i[s]||(i[s]=[]),i[s][o]||(i[s][o]="")};if(h(),'"'===c&&(n?'"'===u?(i[s][o]+='"',a++):n=!1:(void 0===l||l===t||r(l))&&(n=!0)),!n&&'"'!==c){if(c===t){o++,h();continue}if(r(c)){o=0,s++,h(),"\r"===c&&"\n"===u&&a++;continue}}i[s][o]+=c}return i}doPasteOperation(e){const t="clipboard";let i;if(this.eventService.dispatchEvent({type:nl.Events.EVENT_PASTE_START,source:t}),this.clientSideRowModel){const e=this.gos.get("aggregateOnlyChangedColumns");i=new nl.ChangedPath(e,this.clientSideRowModel.getRootNode())}const r={},n=[];e(r,n,this.focusService.getFocusedCell(),i);const s=[...n];i&&(this.clientSideRowModel.doAggregate(i),i.forEachChangedNodeDepthFirst(e=>{s.push(e)})),this.rowRenderer.refreshCells({rowNodes:s}),this.dispatchFlashCells(r),this.fireRowChanged(n),this.refocusLastFocusedCell();const o={type:nl.Events.EVENT_PASTE_END,source:t};this.eventService.dispatchEvent(o)}pasteIntoActiveRange(e,t,i,r,n){const s=this.getRangeSize(e)%t.length!=0;let o=0,a=0;this.iterateActiveRanges(!1,(e,l,c,u)=>{if(u-o>=t.length){if(s)return;o+=a,a=0}const h=t[u-o];r.push(l);const d=this.gos.getCallback("processCellFromClipboard");c.forEach((t,r)=>{if(!t.isCellEditable(l)||t.isSuppressPaste(l))return;r>=h.length&&(r%=h.length);const s=this.processCell(l,t,h[r],cl,d,!0);l.setDataValue(t,s,ll),n&&n.addParentNode(l.parent,[t]);const{rowIndex:o,rowPinned:a}=e,c=this.cellPositionUtils.createIdFromValues({rowIndex:o,column:t,rowPinned:a});i[c]=!0}),a++})}getDisplayedColumnsStartingAt(e){let t=e;const i=[];for(;null!=t;)i.push(t),t=this.columnModel.getDisplayedColAfter(t);return i}pasteStartingFromFocusedCell(e,t,i,r,n){if(!r)return;const s={rowIndex:r.rowIndex,rowPinned:r.rowPinned},o=this.getDisplayedColumnsStartingAt(r.column);this.isPasteSingleValueIntoRange(e)?this.pasteSingleValueIntoRange(e,i,t,n):this.pasteMultipleValues(e,s,i,o,t,ul,n)}isPasteSingleValueIntoRange(e){return this.hasOnlyOneValueToPaste(e)&&null!=this.rangeService&&!this.rangeService.isEmpty()}pasteSingleValueIntoRange(e,t,i,r){const n=e[0][0];this.iterateActiveRanges(!1,(e,s,o)=>{t.push(s),o.forEach(e=>this.updateCellValue(s,e,n,i,ul,r))})}hasOnlyOneValueToPaste(e){return 1===e.length&&1===e[0].length}copyRangeDown(){if(!this.rangeService||this.rangeService.isEmpty())return;const e=[];this.doPasteOperation((t,i,r,n)=>{const s=this.gos.getCallback("processCellForClipboard"),o=this.gos.getCallback("processCellFromClipboard");this.iterateActiveRanges(!0,(r,a,l)=>{e.length?(i.push(a),l.forEach((i,s)=>{if(!i.isCellEditable(a)||i.isSuppressPaste(a))return;const l=this.processCell(a,i,e[s],cl,o,!0);a.setDataValue(i,l,ll),n&&n.addParentNode(a.parent,[i]);const{rowIndex:c,rowPinned:u}=r,h=this.cellPositionUtils.createIdFromValues({rowIndex:c,column:i,rowPinned:u});t[h]=!0})):l.forEach(t=>{const i=this.processCell(a,t,this.valueService.getValue(t,a),cl,s,!1,!0);e.push(i)})})})}removeLastLineIfBlank(e){const t=nl._.last(e);if(t&&1===t.length&&""===t[0]){if(1===e.length)return;nl._.removeFromArray(e,t)}}fireRowChanged(e){"fullRow"===this.gos.get("editType")&&e.forEach(e=>{const t={type:nl.Events.EVENT_ROW_VALUE_CHANGED,node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned};this.eventService.dispatchEvent(t)})}pasteMultipleValues(e,t,i,r,n,s,o){let a=t;const l=null!=this.clientSideRowModel&&!this.gos.get("enableGroupEdit")&&!this.gos.get("treeData"),c=()=>{for(;;){if(!a)return null;const e=this.rowPositionUtils.getRowNode(a);if(a=this.cellNavigationService.getRowBelow({rowPinned:a.rowPinned,rowIndex:a.rowIndex}),null==e)return null;if(!(e.detail||e.footer||l&&e.group))return e}};e.forEach(e=>{const t=c();t&&(e.forEach((e,i)=>this.updateCellValue(t,r[i],e,n,s,o)),i.push(t))})}updateCellValue(e,t,i,r,n,s){if(!e||!t||!t.isCellEditable(e)||t.isSuppressPaste(e))return;if(e.group&&t.isValueActive())return;const o=this.processCell(e,t,i,n,this.gos.getCallback("processCellFromClipboard"),!0);e.setDataValue(t,o,ll);const{rowIndex:a,rowPinned:l}=e;r[this.cellPositionUtils.createIdFromValues({rowIndex:a,column:t,rowPinned:l})]=!0,s&&s.addParentNode(e.parent,[t])}copyToClipboard(e={}){this.copyOrCutToClipboard(e)}cutToClipboard(e={},t="api"){if(this.gos.get("suppressCutToClipboard"))return;const i={type:nl.Events.EVENT_CUT_START,source:t};this.eventService.dispatchEvent(i),this.copyOrCutToClipboard(e,!0);const r={type:nl.Events.EVENT_CUT_END,source:t};this.eventService.dispatchEvent(r)}copyOrCutToClipboard(e,t){let{includeHeaders:i,includeGroupHeaders:r}=e;this.logger.log(`copyToClipboard: includeHeaders = ${i}`),null==i&&(i=this.gos.get("copyHeadersToClipboard")),null==r&&(r=this.gos.get("copyGroupHeadersToClipboard"));const n={includeHeaders:i,includeGroupHeaders:r},s=!this.gos.get("suppressCopyRowsToClipboard");let o=null;!this.rangeService||this.rangeService.isEmpty()||this.shouldSkipSingleCellRange(this.rangeService)?s&&!this.selectionService.isEmpty()?(this.copySelectedRowsToClipboard(n),o=1):this.focusService.isAnyCellFocused()&&(this.copyFocusedCellToClipboard(n),o=2):(this.copySelectedRangeToClipboard(n),o=0),t&&null!==o&&this.clearCellsAfterCopy(o)}clearCellsAfterCopy(e){if(this.eventService.dispatchEvent({type:nl.Events.EVENT_KEY_SHORTCUT_CHANGED_CELL_START}),0===e)this.rangeService.clearCellRangeCellValues({cellEventSource:"clipboardService"});else if(1===e)this.clearSelectedRows();else{const e=this.focusService.getFocusedCell();if(null==e)return;const t=this.rowPositionUtils.getRowNode(e);t&&this.clearCellValue(t,e.column)}this.eventService.dispatchEvent({type:nl.Events.EVENT_KEY_SHORTCUT_CHANGED_CELL_END})}clearSelectedRows(){const e=this.selectionService.getSelectedNodes(),t=this.columnModel.getAllDisplayedColumns();for(const i of e)for(const e of t)this.clearCellValue(i,e)}clearCellValue(e,t){var i;if(!t.isCellEditable(e))return;const r=null!=(i=this.valueService.parseValue(t,e,"",e.getValueFromValueService(t)))?i:null;e.setDataValue(t,r,"clipboardService")}shouldSkipSingleCellRange(e){return this.gos.get("suppressCopySingleCellRanges")&&!e.isMoreThanOneCell()}iterateActiveRanges(e,t,i){if(!this.rangeService||this.rangeService.isEmpty())return;const r=this.rangeService.getCellRanges();e?this.iterateActiveRange(r[0],t,i,!0):r.forEach((e,n)=>this.iterateActiveRange(e,t,i,n===r.length-1))}iterateActiveRange(e,t,i,r){if(!this.rangeService)return;let n=this.rangeService.getRangeStartRow(e);const s=this.rangeService.getRangeEndRow(e);i&&e.columns&&i(e.columns);let o=0,a=!1;for(;!a&&null!=n;){const i=this.rowPositionUtils.getRowNode(n);a=this.rowPositionUtils.sameRow(n,s),t(n,i,e.columns,o++,a&&r),n=this.cellNavigationService.getRowBelow(n)}}copySelectedRangeToClipboard(e={}){if(!this.rangeService||this.rangeService.isEmpty())return;const t=this.rangeService.areAllRangesAbleToMerge(),{data:i,cellsToFlash:r}=t?this.buildDataFromMergedRanges(this.rangeService,e):this.buildDataFromRanges(this.rangeService,e);this.copyDataToClipboard(i),this.dispatchFlashCells(r)}buildDataFromMergedRanges(e,t){const i=new Set,r=e.getCellRanges(),n=new Map,s=[],o={};r.forEach(t=>{t.columns.forEach(e=>i.add(e));const{rowPositions:r,cellsToFlash:a}=this.getRangeRowPositionsAndCellsToFlash(e,t);r.forEach(e=>{const t=`${e.rowIndex}-${e.rowPinned||"null"}`;n.get(t)||(n.set(t,!0),s.push(e))}),Object.assign(o,a)});const a=this.columnModel.getAllDisplayedColumns(),l=Array.from(i);return l.sort((e,t)=>a.indexOf(e)-a.indexOf(t)),{data:this.buildExportParams({columns:l,rowPositions:s,includeHeaders:t.includeHeaders,includeGroupHeaders:t.includeGroupHeaders}),cellsToFlash:o}}buildDataFromRanges(e,t){const i=e.getCellRanges(),r=[],n={};return i.forEach(i=>{const{rowPositions:s,cellsToFlash:o}=this.getRangeRowPositionsAndCellsToFlash(e,i);Object.assign(n,o),r.push(this.buildExportParams({columns:i.columns,rowPositions:s,includeHeaders:t.includeHeaders,includeGroupHeaders:t.includeGroupHeaders}))}),{data:r.join("\n"),cellsToFlash:n}}getRangeRowPositionsAndCellsToFlash(e,t){const i=[],r={},n=e.getRangeStartRow(t),s=e.getRangeEndRow(t);let o=n;for(;o&&(i.push(o),t.columns.forEach(e=>{const{rowIndex:t,rowPinned:i}=o,n=this.cellPositionUtils.createIdFromValues({rowIndex:t,column:e,rowPinned:i});r[n]=!0}),!this.rowPositionUtils.sameRow(o,s));)o=this.cellNavigationService.getRowBelow(o);return{rowPositions:i,cellsToFlash:r}}getCellsToFlashFromRowNodes(e){const t=this.columnModel.getAllDisplayedColumns(),i={};for(let r=0;r<e.length;r++){const{rowIndex:n,rowPinned:s}=e[r];if(null!=n)for(let e=0;e<t.length;e++){const r=t[e];i[this.cellPositionUtils.createIdFromValues({rowIndex:n,column:r,rowPinned:s})]=!0}}return i}copyFocusedCellToClipboard(e={}){const t=this.focusService.getFocusedCell();if(null==t)return;const i=this.cellPositionUtils.createId(t),r={rowPinned:t.rowPinned,rowIndex:t.rowIndex},n=t.column,s=this.buildExportParams({columns:[n],rowPositions:[r],includeHeaders:e.includeHeaders,includeGroupHeaders:e.includeGroupHeaders});this.copyDataToClipboard(s),this.dispatchFlashCells({[i]:!0})}copySelectedRowsToClipboard(e={}){const{columnKeys:t,includeHeaders:i,includeGroupHeaders:r}=e,n=this.buildExportParams({columns:t,includeHeaders:i,includeGroupHeaders:r});this.copyDataToClipboard(n);const s=this.selectionService.getSelectedNodes()||[];this.dispatchFlashCells(this.getCellsToFlashFromRowNodes(s))}buildExportParams(e){const{columns:t,rowPositions:i,includeHeaders:r=!1,includeGroupHeaders:n=!1}=e,s={columnKeys:t,rowPositions:i,skipColumnHeaders:!r,skipColumnGroupHeaders:!n,suppressQuotes:!0,columnSeparator:this.getClipboardDelimiter(),onlySelected:!i,processCellCallback:this.gos.getCallback("processCellForClipboard"),processRowGroupCallback:e=>this.processRowGroupCallback(e),processHeaderCallback:this.gos.getCallback("processHeaderForClipboard"),processGroupHeaderCallback:this.gos.getCallback("processGroupHeaderForClipboard")};return this.csvCreator.getDataAsCsv(s,!0)}processRowGroupCallback(e){const{node:t,column:i}=e,r=this.gos.get("treeData"),n=this.gos.get("suppressGroupMaintainValueType");let s=(()=>{var e,s;if(r||n||!i)return t.key;const o=null==(e=t.groupData)?void 0:e[i.getId()];return o&&t.rowGroupColumn&&!1!==t.rowGroupColumn.getColDef().useValueFormatterForExport&&null!=(s=this.valueService.formatValue(t.rowGroupColumn,t,o))?s:o})();if(e.node.footer){let e="";s&&s.length&&(e=` ${s}`),s=`Total${e}`}const o=this.gos.getCallback("processCellForClipboard");if(o){let e=t.rowGroupColumn;return!e&&t.footer&&-1===t.level&&(e=this.columnModel.getRowGroupColumns()[0]),o({value:s,node:t,column:e,type:"clipboard",formatValue:i=>{var r;return null!=(r=this.valueService.formatValue(e,t,i))?r:i},parseValue:i=>this.valueService.parseValue(e,t,i,this.valueService.getValue(e,t))})}return s}dispatchFlashCells(e){window.setTimeout(()=>{const t={type:nl.Events.EVENT_FLASH_CELLS,cells:e};this.eventService.dispatchEvent(t)},0)}processCell(e,t,i,r,n,s,o){var a;return n?n({column:t,node:e,value:i,type:r,formatValue:i=>{var r;return null!=(r=this.valueService.formatValue(t,null!=e?e:null,i))?r:i},parseValue:i=>this.valueService.parseValue(t,null!=e?e:null,i,this.valueService.getValue(t,e))}):s&&!1!==t.getColDef().useValueParserForImport?this.valueService.parseValue(t,null!=e?e:null,i,this.valueService.getValue(t,e)):o&&!1!==t.getColDef().useValueFormatterForExport&&null!=(a=this.valueService.formatValue(t,null!=e?e:null,i))?a:i}copyDataToClipboard(e){const t=this.gos.getCallback("sendToClipboard");t?t({data:e}):!this.gos.get("suppressClipboardApi")&&navigator.clipboard?navigator.clipboard.writeText(e).catch(t=>{nl._.doOnce(()=>{console.warn(t),console.warn(hl("writeText"))},"clipboardApiError"),this.copyDataToClipboardLegacy(e)}):this.copyDataToClipboardLegacy(e)}copyDataToClipboardLegacy(e){this.executeOnTempElement(t=>{const i=this.gos.getDocument(),r=this.gos.getActiveDomElement();t.value=e||" ",t.select(),t.focus({preventScroll:!0}),i.execCommand("copy")||console.warn("AG Grid: Browser did not allow document.execCommand('copy'). Ensure api.copySelectedRowsToClipboard() is invoked via a user event, i.e. button click, otherwise the browser will prevent it for security reasons."),null!=r&&null!=r.focus&&r.focus({preventScroll:!0})})}executeOnTempElement(e,t){const i=this.gos.getDocument(),r=i.createElement("textarea");r.style.width="1px",r.style.height="1px",r.style.top=i.documentElement.scrollTop+"px",r.style.left=i.documentElement.scrollLeft+"px",r.style.position="absolute",r.style.opacity="0";const n=this.gridCtrl.getGui();n.appendChild(r);try{e(r)}catch(e){console.warn("AG Grid: Browser does not support document.execCommand('copy') for clipboard operations")}t?window.setTimeout(()=>{t(r),n.removeChild(r)},100):n.removeChild(r)}getRangeSize(e){const t=e.getCellRanges();let i=0,r=0;return t.length>0&&(i=e.getRangeStartRow(t[0]).rowIndex,r=e.getRangeEndRow(t[0]).rowIndex),i-r+1}};al([(0,nl.Autowired)("csvCreator")],dl.prototype,"csvCreator",2),al([(0,nl.Autowired)("loggerFactory")],dl.prototype,"loggerFactory",2),al([(0,nl.Autowired)("selectionService")],dl.prototype,"selectionService",2),al([(0,nl.Autowired)("rowModel")],dl.prototype,"rowModel",2),al([(0,nl.Autowired)("ctrlsService")],dl.prototype,"ctrlsService",2),al([(0,nl.Autowired)("valueService")],dl.prototype,"valueService",2),al([(0,nl.Autowired)("focusService")],dl.prototype,"focusService",2),al([(0,nl.Autowired)("rowRenderer")],dl.prototype,"rowRenderer",2),al([(0,nl.Autowired)("columnModel")],dl.prototype,"columnModel",2),al([(0,nl.Autowired)("cellNavigationService")],dl.prototype,"cellNavigationService",2),al([(0,nl.Autowired)("cellPositionUtils")],dl.prototype,"cellPositionUtils",2),al([(0,nl.Autowired)("rowPositionUtils")],dl.prototype,"rowPositionUtils",2),al([(0,nl.Optional)("rangeService")],dl.prototype,"rangeService",2),al([nl.PostConstruct],dl.prototype,"init",1),dl=al([(0,nl.Bean)("clipboardService")],dl);var pl={version:"31.3.4",moduleName:il.ModuleNames.ClipboardModule,beans:[dl],dependantModules:[_,rl.CsvExportModule]},gl=i(98092),fl=i(98092),ml=i(98092),vl=i(98092),Cl=i(98092),yl=i(98092),wl=i(98092),Sl=i(98092),bl=i(98092),El=i(98092),Al=i(98092),Tl=i(98092),Ml=i(98092),Rl=i(98092),_l=i(98092),Pl=i(98092),xl=i(98092),Dl=i(98092),Il=i(98092),Ll=i(98092),Nl=i(98092),Ol=i(98092),Fl=i(98092),kl=i(98092),Gl=i(98092),Vl=Object.defineProperty,Hl=Object.defineProperties,Bl=Object.getOwnPropertyDescriptor,zl=Object.getOwnPropertyDescriptors,Ul=Object.getOwnPropertySymbols,Wl=Object.prototype.hasOwnProperty,jl=Object.prototype.propertyIsEnumerable,Kl=(e,t,i)=>t in e?Vl(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,$l=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Bl(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Vl(t,i,s),s},ql=class extends Tl.BeanStub{execute(e){const t=Tl._.missingOrEmpty(this.columnModel.getValueColumns()),i=!this.gos.getCallback("getGroupRowAgg"),r=e.changedPath&&e.changedPath.isActive();if(t&&i&&r)return;const n=this.createAggDetails(e);this.recursivelyCreateAggData(n)}createAggDetails(e){const t=this.columnModel.isPivotActive(),i=this.columnModel.getValueColumns(),r=t?this.columnModel.getPivotColumns():[];return{alwaysAggregateAtRootLevel:this.gos.get("alwaysAggregateAtRootLevel"),groupIncludeTotalFooter:!!this.gos.getGrandTotalRow(),changedPath:e.changedPath,valueColumns:i,pivotColumns:r,filteredOnly:!this.isSuppressAggFilteredOnly(),userAggFunc:this.gos.getCallback("getGroupRowAgg")}}isSuppressAggFilteredOnly(){return void 0!==this.gos.getGroupAggFiltering()||this.gos.get("suppressAggFilteredOnly")}recursivelyCreateAggData(e){e.changedPath.forEachChangedNodeDepthFirst(t=>{if(t.hasChildren()){if(-1===t.level&&!e.groupIncludeTotalFooter){const i=!this.columnModel.isPivotMode();if(!e.alwaysAggregateAtRootLevel&&i)return void t.setAggData(null)}this.aggregateRowNode(t,e)}else t.aggData&&t.setAggData(null)},!0)}aggregateRowNode(e,t){const i=0===t.valueColumns.length,r=0===t.pivotColumns.length;let n;n=t.userAggFunc?t.userAggFunc({nodes:e.childrenAfterFilter}):i?null:r?this.aggregateRowNodeUsingValuesOnly(e,t):this.aggregateRowNodeUsingValuesAndPivot(e),e.setAggData(n),e.sibling&&e.sibling.setAggData(n)}aggregateRowNodeUsingValuesAndPivot(e){var t,i;const r={},n=null!=(t=this.columnModel.getSecondaryColumns())?t:[];let s=!0;for(let t=0;t<n.length;t++){const o=n[t],a=o.getColDef();if(null!=a.pivotTotalColumnIds){s=!1;continue}const l=null!=(i=a.pivotKeys)?i:[];let c;c=e.leafGroup?this.getValuesFromMappedSet(e.childrenMapped,l,a.pivotValueColumn):this.getValuesPivotNonLeaf(e,a.colId),r[a.colId]=this.aggregateValues(c,a.pivotValueColumn.getAggFunc(),a.pivotValueColumn,e,o)}if(!s)for(let t=0;t<n.length;t++){const i=n[t],s=i.getColDef();if(null==s.pivotTotalColumnIds||!s.pivotTotalColumnIds.length)continue;const o=s.pivotTotalColumnIds.map(e=>r[e]);r[s.colId]=this.aggregateValues(o,s.pivotValueColumn.getAggFunc(),s.pivotValueColumn,e,i)}return r}aggregateRowNodeUsingValuesOnly(e,t){const i={},r=t.changedPath.isActive()?t.changedPath.getValueColumnsForNode(e,t.valueColumns):t.valueColumns,n=t.changedPath.isActive()?t.changedPath.getNotValueColumnsForNode(e,t.valueColumns):null,s=this.getValuesNormal(e,r,t.filteredOnly),o=e.aggData;return r.forEach((t,r)=>{i[t.getId()]=this.aggregateValues(s[r],t.getAggFunc(),t,e)}),n&&o&&n.forEach(e=>{i[e.getId()]=o[e.getId()]}),i}getValuesPivotNonLeaf(e,t){return e.childrenAfterFilter.map(e=>e.aggData[t])}getValuesFromMappedSet(e,t,i){let r=e;for(let e=0;e<t.length;e++){const i=t[e];r=r?r[i]:null}return r?r.map(e=>this.valueService.getValue(i,e)):[]}getValuesNormal(e,t,i){const r=[];t.forEach(()=>r.push([]));const n=t.length,s=i?e.childrenAfterFilter:e.childrenAfterGroup,o=s.length;for(let e=0;e<o;e++){const i=s[e];for(let e=0;e<n;e++){const n=t[e],s=this.valueService.getValue(n,i);r[e].push(s)}}return r}aggregateValues(e,t,i,r,n){const s="string"==typeof t?this.aggFuncService.getAggFunc(t):t;return"function"!=typeof s?(console.error(`AG Grid: unrecognised aggregation function ${t}`),null):s(this.gos.addGridCommonParams({values:e,column:i,colDef:i?i.getColDef():void 0,pivotResultColumn:n,rowNode:r,data:r?r.data:void 0}))}};$l([(0,Tl.Autowired)("columnModel")],ql.prototype,"columnModel",2),$l([(0,Tl.Autowired)("valueService")],ql.prototype,"valueService",2),$l([(0,Tl.Autowired)("aggFuncService")],ql.prototype,"aggFuncService",2),ql=$l([(0,Tl.Bean)("aggregationStage")],ql);var Yl=class{constructor(){this.allSets={},this.allParents=[]}removeFromChildrenAfterGroup(e,t){this.getSet(e).removeFromChildrenAfterGroup[t.id]=!0}isRemoveFromAllLeafChildren(e,t){return!!this.getSet(e).removeFromAllLeafChildren[t.id]}preventRemoveFromAllLeafChildren(e,t){delete this.getSet(e).removeFromAllLeafChildren[t.id]}removeFromAllLeafChildren(e,t){this.getSet(e).removeFromAllLeafChildren[t.id]=!0}getSet(e){return this.allSets[e.id]||(this.allSets[e.id]={removeFromAllLeafChildren:{},removeFromChildrenAfterGroup:{}},this.allParents.push(e)),this.allSets[e.id]}getAllParents(){return this.allParents}flush(){this.allParents.forEach(e=>{const t=this.allSets[e.id];e.childrenAfterGroup=e.childrenAfterGroup.filter(e=>!t.removeFromChildrenAfterGroup[e.id]),e.allLeafChildren=e.allLeafChildren.filter(e=>!t.removeFromAllLeafChildren[e.id]),e.updateHasChildren(),e.sibling&&(e.sibling.childrenAfterGroup=e.childrenAfterGroup,e.sibling.allLeafChildren=e.allLeafChildren)}),this.allSets={},this.allParents.length=0}},Ql=class extends Ml.BeanStub{execute(e){const t=this.createGroupingDetails(e);if(t.transactions)this.handleTransaction(t);else{const i=!0===e.afterColumnsChanged;this.shotgunResetEverything(t,i)}t.usingTreeData||(this.positionLeafsAndGroups(e.changedPath),this.orderGroups(t)),this.selectableService.updateSelectableAfterGrouping()}positionLeafsAndGroups(e){e.forEachChangedNodeDepthFirst(e=>{if(e.childrenAfterGroup){const t=[],i=[];let r;e.childrenAfterGroup.forEach(e=>{var n;(null==(n=e.childrenAfterGroup)?void 0:n.length)?""!==e.key||r?i.push(e):r=e:t.push(e)}),r&&i.push(r),e.childrenAfterGroup=[...t,...i]}},!1)}createGroupingDetails(e){var t;const{rowNode:i,changedPath:r,rowNodeTransactions:n,rowNodeOrder:s}=e,o=this.gos.get("treeData"),a=o?null:this.columnModel.getRowGroupColumns();return{includeParents:!this.gos.get("suppressParentsInRowNodes"),expandByDefault:this.gos.get("groupDefaultExpanded"),groupedCols:a,rootNode:i,pivotMode:this.columnModel.isPivotMode(),groupedColCount:o||!a?0:a.length,rowNodeOrder:s,transactions:n,changedPath:r,groupAllowUnbalanced:this.gos.get("groupAllowUnbalanced"),isGroupOpenByDefault:this.gos.getCallback("isGroupOpenByDefault"),initialGroupOrderComparator:this.gos.getCallback("initialGroupOrderComparator"),usingTreeData:o,suppressGroupMaintainValueType:this.gos.get("suppressGroupMaintainValueType"),getDataPath:o?this.gos.get("getDataPath"):void 0,keyCreators:null!=(t=null==a?void 0:a.map(e=>e.getColDef().keyCreator))?t:[]}}handleTransaction(e){e.transactions.forEach(t=>{const i=e.usingTreeData?void 0:new Yl;if(Ml._.existsAndNotEmpty(t.remove)&&this.removeNodes(t.remove,e,i),Ml._.existsAndNotEmpty(t.update)&&this.moveNodesInWrongPath(t.update,e,i),Ml._.existsAndNotEmpty(t.add)&&this.insertNodes(t.add,e,!1),i){const t=i.getAllParents().slice();i.flush(),this.removeEmptyGroups(t,e)}}),e.rowNodeOrder&&this.sortChildren(e)}sortChildren(e){e.changedPath.forEachChangedNodeDepthFirst(t=>{t.childrenAfterGroup&&Ml._.sortRowNodesByOrder(t.childrenAfterGroup,e.rowNodeOrder)&&e.changedPath.addParentNode(t)},!1,!0)}orderGroups(e){const t=e.initialGroupOrderComparator;Ml._.exists(t)&&function e(i){Ml._.exists(i.childrenAfterGroup)&&!i.leafGroup&&(i.childrenAfterGroup.sort((e,i)=>t({nodeA:e,nodeB:i})),i.childrenAfterGroup.forEach(t=>e(t)))}(e.rootNode)}getExistingPathForNode(e,t){const i=[];let r=t.usingTreeData?e:e.parent;for(;r&&r!==t.rootNode;)i.push({key:r.key,rowGroupColumn:r.rowGroupColumn,field:r.field}),r=r.parent;return i.reverse(),i}moveNodesInWrongPath(e,t,i){e.forEach(e=>{t.changedPath.isActive()&&t.changedPath.addParentNode(e.parent);const r=e=>e.key,n=this.getExistingPathForNode(e,t).map(r),s=this.getGroupInfo(e,t).map(r);Ml._.areEqual(n,s)||this.moveNode(e,t,i)})}moveNode(e,t,i){if(this.removeNodesInStages([e],t,i),this.insertOneNode(e,t,!0,i),e.setData(e.data),t.changedPath.isActive()){const i=e.parent;t.changedPath.addParentNode(i)}}removeNodes(e,t,i){this.removeNodesInStages(e,t,i),t.changedPath.isActive()&&e.forEach(e=>t.changedPath.addParentNode(e.parent))}removeNodesInStages(e,t,i){if(this.removeNodesFromParents(e,t,i),t.usingTreeData){this.postRemoveCreateFillerNodes(e,t);const i=e.map(e=>e.parent);this.removeEmptyGroups(i,t)}}forEachParentGroup(e,t,i){let r=t;for(;r&&r!==e.rootNode;)i(r),r=r.parent}removeNodesFromParents(e,t,i){const r=null==i,n=i||new Yl;e.forEach(e=>{this.removeFromParent(e,n),this.forEachParentGroup(t,e.parent,t=>{n.removeFromAllLeafChildren(t,e)})}),r&&n.flush()}postRemoveCreateFillerNodes(e,t){e.forEach(e=>{if(e.hasChildren()){const i=this.getExistingPathForNode(e,t),r=this.findParentForNode(e,i,t);r.expanded=e.expanded,r.allLeafChildren=e.allLeafChildren,r.childrenAfterGroup=e.childrenAfterGroup,r.childrenMapped=e.childrenMapped,r.updateHasChildren(),r.childrenAfterGroup.forEach(e=>e.parent=r)}})}removeEmptyGroups(e,t){let i=!0;const r=e=>{const t=this.getChildrenMappedKey(e.key,e.rowGroupColumn),i=e.parent;return!!(i&&i.childrenMapped&&i.childrenMapped[t]&&e.isEmptyRowGroupNode())};for(;i;){i=!1;const n=new Yl;e.forEach(e=>{this.forEachParentGroup(t,e,e=>{r(e)&&(i=!0,this.removeFromParent(e,n),e.setSelectedParams({newValue:!1,source:"rowGroupChanged"}))})}),n.flush()}}removeFromParent(e,t){e.parent&&(t?t.removeFromChildrenAfterGroup(e.parent,e):(Ml._.removeFromArray(e.parent.childrenAfterGroup,e),e.parent.updateHasChildren()));const i=this.getChildrenMappedKey(e.key,e.rowGroupColumn);e.parent&&e.parent.childrenMapped&&(e.parent.childrenMapped[i]=void 0),e.setRowTop(null),e.setRowIndex(null)}addToParent(e,t){const i=this.getChildrenMappedKey(e.key,e.rowGroupColumn);t&&(null!=t.childrenMapped&&(t.childrenMapped[i]=e),t.childrenAfterGroup.push(e),t.updateHasChildren())}areGroupColsEqual(e,t){return null!=e&&null!=t&&e.pivotMode===t.pivotMode&&Ml._.areEqual(e.groupedCols,t.groupedCols)&&Ml._.areEqual(e.keyCreators,t.keyCreators)}checkAllGroupDataAfterColsChanged(e){const t=i=>{i&&i.forEach(i=>{if(!e.usingTreeData&&!i.group)return;const r={field:i.field,key:i.key,rowGroupColumn:i.rowGroupColumn,leafNode:i.allLeafChildren[0]};this.setGroupData(i,r,e),t(i.childrenAfterGroup)})};t(e.rootNode.childrenAfterGroup)}shotgunResetEverything(e,t){if(this.noChangeInGroupingColumns(e,t))return;this.selectionService.filterFromSelection(e=>e&&!e.group);const{rootNode:i,groupedCols:r}=e;i.leafGroup=!e.usingTreeData&&0===r.length,i.childrenAfterGroup=[],i.childrenMapped={},i.updateHasChildren();const n=i.sibling;n&&(n.childrenAfterGroup=i.childrenAfterGroup,n.childrenMapped=i.childrenMapped),this.insertNodes(i.allLeafChildren,e,!1)}noChangeInGroupingColumns(e,t){let i=!1;const r=this.columnModel.getGroupDisplayColumns(),n=r?r.map(e=>e.getId()).join("-"):"";return t&&(i=e.usingTreeData||this.areGroupColsEqual(e,this.oldGroupingDetails),this.oldGroupDisplayColIds!==n&&this.checkAllGroupDataAfterColsChanged(e)),this.oldGroupingDetails=e,this.oldGroupDisplayColIds=n,i}insertNodes(e,t,i){e.forEach(e=>{this.insertOneNode(e,t,i),t.changedPath.isActive()&&t.changedPath.addParentNode(e.parent)})}insertOneNode(e,t,i,r){const n=this.getGroupInfo(e,t),s=this.findParentForNode(e,n,t,r);s.group||console.warn("AG Grid: duplicate group keys for row data, keys should be unique",[s.data,e.data]),t.usingTreeData?this.swapGroupWithUserNode(s,e,i):(e.parent=s,e.level=n.length,s.childrenAfterGroup.push(e),s.updateHasChildren())}findParentForNode(e,t,i,r){let n=i.rootNode;return t.forEach((t,s)=>{n=this.getOrCreateNextNode(n,t,s,i),(null==r?void 0:r.isRemoveFromAllLeafChildren(n,e))?null==r||r.preventRemoveFromAllLeafChildren(n,e):n.allLeafChildren.push(e)}),n}swapGroupWithUserNode(e,t,i){t.parent=e.parent,t.key=e.key,t.field=e.field,t.groupData=e.groupData,t.level=e.level,i||(t.expanded=e.expanded),t.leafGroup=e.leafGroup,t.rowGroupIndex=e.rowGroupIndex,t.allLeafChildren=e.allLeafChildren,t.childrenAfterGroup=e.childrenAfterGroup,t.childrenMapped=e.childrenMapped,t.sibling=e.sibling,t.updateHasChildren(),this.removeFromParent(e),t.childrenAfterGroup.forEach(e=>e.parent=t),this.addToParent(t,e.parent)}getOrCreateNextNode(e,t,i,r){const n=this.getChildrenMappedKey(t.key,t.rowGroupColumn);let s=e.childrenMapped?e.childrenMapped[n]:void 0;return s||(s=this.createGroup(t,e,i,r),this.addToParent(s,e)),s}createGroup(e,t,i,r){const n=new Ml.RowNode(this.beans);return n.group=!0,n.field=e.field,n.rowGroupColumn=e.rowGroupColumn,this.setGroupData(n,e,r),n.key=e.key,n.id=this.createGroupId(n,t,r.usingTreeData,i),n.level=i,n.leafGroup=!r.usingTreeData&&i===r.groupedColCount-1,n.allLeafChildren=[],n.setAllChildrenCount(0),n.rowGroupIndex=r.usingTreeData?null:i,n.childrenAfterGroup=[],n.childrenMapped={},n.updateHasChildren(),n.parent=r.includeParents?t:null,this.setExpandedInitialValue(r,n),n}createGroupId(e,t,i,r){let n;return n=i?(e,t,i)=>{if(i<0)return null;const r=t?n(t,t.parent,i-1):null;return`${null==r?"":r+"-"}${i}-${e.key}`}:(e,t)=>{if(!e.rowGroupColumn)return null;const i=t?n(t,t.parent,0):null;return`${null==i?"":i+"-"}${e.rowGroupColumn.getColId()}-${e.key}`},Ml.RowNode.ID_PREFIX_ROW_GROUP+n(e,t,r)}setGroupData(e,t,i){e.groupData={},this.columnModel.getGroupDisplayColumns().forEach(r=>{if(i.usingTreeData)return void(e.groupData[r.getColId()]=t.key);const n=e.rowGroupColumn;null!==n&&r.isRowGroupDisplayed(n.getId())&&(i.suppressGroupMaintainValueType?e.groupData[r.getColId()]=t.key:e.groupData[r.getColId()]=this.valueService.getValue(n,t.leafNode))})}getChildrenMappedKey(e,t){return t?t.getId()+"-"+e:e}setExpandedInitialValue(e,t){if(e.pivotMode&&t.leafGroup)return void(t.expanded=!1);const i=e.isGroupOpenByDefault;if(i){const e={rowNode:t,field:t.field,key:t.key,level:t.level,rowGroupColumn:t.rowGroupColumn};return void(t.expanded=1==i(e))}const{expandByDefault:r}=e;-1!==e.expandByDefault?t.expanded=t.level<r:t.expanded=!0}getGroupInfo(e,t){return t.usingTreeData?this.getGroupInfoFromCallback(e,t):this.getGroupInfoFromGroupColumns(e,t)}getGroupInfoFromCallback(e,t){const i=t.getDataPath?t.getDataPath(e.data):null;return null!=i&&0!==i.length||Ml._.warnOnce(`getDataPath() should not return an empty path for data ${e.data}`),i?i.map(e=>({key:e,field:null,rowGroupColumn:null})):[]}getGroupInfoFromGroupColumns(e,t){const i=[];return t.groupedCols.forEach(r=>{let n=this.valueService.getKeyForNode(r,e),s=null!=n&&""!==n;if((t.pivotMode||!t.groupAllowUnbalanced)&&!s&&(n="",s=!0),s){const t={key:n,field:r.getColDef().field,rowGroupColumn:r,leafNode:e};i.push(t)}}),i}};$l([(0,Ml.Autowired)("columnModel")],Ql.prototype,"columnModel",2),$l([(0,Ml.Autowired)("selectableService")],Ql.prototype,"selectableService",2),$l([(0,Ml.Autowired)("valueService")],Ql.prototype,"valueService",2),$l([(0,Ml.Autowired)("beans")],Ql.prototype,"beans",2),$l([(0,Ml.Autowired)("selectionService")],Ql.prototype,"selectionService",2),Ql=$l([(0,Ml.Bean)("groupStage")],Ql);var Xl=class extends Rl.BeanStub{init(){const e=()=>{var e;return null!=(e=this.gos.get("serverSidePivotResultFieldSeparator"))?e:"_"};this.fieldSeparator=e(),this.addManagedPropertyListener("serverSidePivotResultFieldSeparator",()=>{this.fieldSeparator=e()});const t=()=>this.gos.get("pivotDefaultExpanded");this.pivotDefaultExpanded=t(),this.addManagedPropertyListener("pivotDefaultExpanded",()=>{this.pivotDefaultExpanded=t()})}createPivotColumnDefs(e){const t=this.createPivotColumnsFromUniqueValues(e),i=function e(t,i=[]){return t.forEach(t=>{void 0!==t.children?e(t.children,i):i.push(t)}),i}(t);return this.addRowGroupTotals(t,i),this.addExpandablePivotGroups(t,i),this.addPivotTotalsToGroups(t,i),{pivotColumnGroupDefs:t,pivotColumnDefs:i.map(e=>Rl._.cloneObject(e))}}createPivotColumnsFromUniqueValues(e){const t=this.columnModel.getPivotColumns(),i=t.length;return this.recursivelyBuildGroup(0,e,[],i,t)}recursivelyBuildGroup(e,t,i,r,n){const s=this.columnModel.getValueColumns();if(e>=r)return this.buildMeasureCols(i);const o=n[e].getColDef(),a=this.headerNameComparator.bind(this,o.pivotComparator);if(1===s.length&&this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&e===r-1){const e=[];return Rl._.iterateObject(t,t=>{const r=[...i,t],n=this.createColDef(s[0],t,r);n.columnGroupShow="open",e.push(n)}),e.sort(a),e}const l=[];return Rl._.iterateObject(t,(t,s)=>{const o=-1===this.pivotDefaultExpanded||e<this.pivotDefaultExpanded,a=[...i,t];l.push({children:this.recursivelyBuildGroup(e+1,s,a,r,n),headerName:t,pivotKeys:a,columnGroupShow:"open",openByDefault:o,groupId:this.generateColumnGroupId(a)})}),l.sort(a),l}buildMeasureCols(e){const t=this.columnModel.getValueColumns();return 0===t.length?[this.createColDef(null,"-",e)]:t.map(t=>{const i=this.columnModel.getDisplayNameForColumn(t,"header");return r=((e,t)=>{for(var i in t||(t={}))Wl.call(t,i)&&Kl(e,i,t[i]);if(Ul)for(var i of Ul(t))jl.call(t,i)&&Kl(e,i,t[i]);return e})({},this.createColDef(t,i,e)),Hl(r,zl({columnGroupShow:"open"}));var r})}addExpandablePivotGroups(e,t){if(this.gos.get("suppressExpandablePivotGroups")||this.gos.get("pivotColumnGroupTotals"))return;const i=(e,t,r)=>{const n=e;if(n.children){const s=new Map;n.children.forEach(e=>{i(e,t,s)});const o=!n.children.some(e=>e.children);this.columnModel.getValueColumns().forEach(i=>{const r=this.columnModel.getDisplayNameForColumn(i,"header"),n=this.createColDef(i,r,e.pivotKeys);n.pivotTotalColumnIds=s.get(i.getColId()),n.columnGroupShow="closed",n.aggFunc=i.getAggFunc(),o||(e.children.push(n),t.push(n))}),this.merge(r,s)}else{const t=e;if(!t.pivotValueColumn)return;const i=t.pivotValueColumn.getColId(),n=r.has(i)?r.get(i):[];n.push(t.colId),r.set(i,n)}};e.forEach(e=>{i(e,t,new Map)})}addPivotTotalsToGroups(e,t){if(!this.gos.get("pivotColumnGroupTotals"))return;const i="after"===this.gos.get("pivotColumnGroupTotals"),r=this.columnModel.getValueColumns(),n=r.map(e=>e.getAggFunc());if(!n||n.length<1||!this.sameAggFuncs(n))return;const s=r[0];e.forEach(e=>{this.recursivelyAddPivotTotal(e,t,s,i)})}recursivelyAddPivotTotal(e,t,i,r){const n=e;if(!n.children){const t=e;return t.colId?[t.colId]:null}let s=[];if(n.children.forEach(e=>{const n=this.recursivelyAddPivotTotal(e,t,i,r);n&&(s=s.concat(n))}),n.children.length>1){const n=this.localeService.getLocaleTextFunc()("pivotColumnGroupTotals","Total"),o=this.createColDef(i,n,e.pivotKeys,!0);o.pivotTotalColumnIds=s,o.aggFunc=i.getAggFunc();const a=e.children;r?a.push(o):a.unshift(o),t.push(o)}return s}addRowGroupTotals(e,t){if(!this.gos.get("pivotRowTotals"))return;const i="after"===this.gos.get("pivotRowTotals"),r=this.columnModel.getValueColumns(),n=i?r.slice():r.slice().reverse();for(let r=0;r<n.length;r++){const s=n[r];let o=[];e.forEach(e=>{o=o.concat(this.extractColIdsForValueColumn(e,s))});const a=n.length>1||!this.gos.get("removePivotHeaderRowWhenSingleValueColumn");this.createRowGroupTotal(e,t,s,o,i,a)}}extractColIdsForValueColumn(e,t){const i=e;if(!i.children){const e=i;return e.pivotValueColumn===t&&e.colId?[e.colId]:[]}let r=[];return i.children.forEach(e=>{this.extractColIdsForValueColumn(e,t);const i=this.extractColIdsForValueColumn(e,t);r=r.concat(i)}),r}createRowGroupTotal(e,t,i,r,n,s){let o;if(0===this.columnModel.getValueColumns().length)o=this.createColDef(null,"-",[]);else{const e=this.columnModel.getDisplayNameForColumn(i,"header");o=this.createColDef(i,e,[]),o.pivotTotalColumnIds=r}o.colId=Xl.PIVOT_ROW_TOTAL_PREFIX+o.colId,t.push(o);const a=s?{children:[o],pivotKeys:[],groupId:`${Xl.PIVOT_ROW_TOTAL_PREFIX}_pivotGroup_${i.getColId()}`}:o;n?e.push(a):e.unshift(a)}createColDef(e,t,i,r=!1){const n={};if(e){const t=e.getColDef();Object.assign(n,t),n.hide=!1}return n.headerName=t,n.colId=this.generateColumnId(i||[],e&&!r?e.getColId():""),n.field=n.colId,n.valueGetter=e=>{var t;return null==(t=e.data)?void 0:t[e.colDef.field]},n.pivotKeys=i,n.pivotValueColumn=e,!0===n.filter&&(n.filter="agNumberColumnFilter"),n}sameAggFuncs(e){if(1==e.length)return!0;for(let t=1;t<e.length;t++)if(e[t]!==e[0])return!1;return!0}headerNameComparator(e,t,i){return e?e(t.headerName,i.headerName):t.headerName&&!i.headerName?1:!t.headerName&&i.headerName?-1:t.headerName&&i.headerName?t.headerName<i.headerName?-1:t.headerName>i.headerName?1:0:0}merge(e,t){t.forEach((t,i,r)=>{const n=[...e.has(i)?e.get(i):[],...t];e.set(i,n)})}generateColumnGroupId(e){return`pivotGroup_${this.columnModel.getPivotColumns().map(e=>e.getColId()).join("-")}_${e.join("-")}`}generateColumnId(e,t){return`pivot_${this.columnModel.getPivotColumns().map(e=>e.getColId()).join("-")}_${e.join("-")}_${t}`}createColDefsFromFields(e){const t={};for(let i=0;i<e.length;i++){const r=e[i].split(this.fieldSeparator);let n=t;for(let e=0;e<r.length;e++){const t=r[e];null==n[t]&&(n[t]={}),n=n[t]}}const i=(e,t,r,n)=>{var s;const o=[];for(let t in r){const s=r[t],a=i(`${e}${this.fieldSeparator}${t}`,t,s,n+1);o.push(a)}if(0===o.length){const i=this.columnModel.getPrimaryColumn(t);if(i){const r=null!=(s=this.columnModel.getDisplayNameForColumn(i,"header"))?s:t,n=this.createColDef(i,r,void 0,!1);return n.colId=e,n.aggFunc=i.getAggFunc(),n.valueGetter=t=>{var i;return null==(i=t.data)?void 0:i[e]},n}return{colId:e,headerName:t,valueGetter:t=>{var i;return null==(i=t.data)?void 0:i[e]}}}return this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&1===o.length&&"colId"in o[0]?(o[0].headerName=t,o[0]):{openByDefault:-1===this.pivotDefaultExpanded||n<this.pivotDefaultExpanded,groupId:e,headerName:t,children:o}},r=[];for(let e in t){const n=i(e,e,t[e],0);r.push(n)}return r}};Xl.PIVOT_ROW_TOTAL_PREFIX="PivotRowTotal_",$l([(0,Rl.Autowired)("columnModel")],Xl.prototype,"columnModel",2),$l([Rl.PostConstruct],Xl.prototype,"init",1),Xl=$l([(0,Rl.Bean)("pivotColDefService")],Xl);var Zl=class extends _l.BeanStub{constructor(){super(...arguments),this.uniqueValues={},this.lastTimeFailed=!1,this.maxUniqueValues=-1,this.currentUniqueCount=0}execute(e){const t=e.changedPath;this.columnModel.isPivotActive()?this.executePivotOn(t):this.executePivotOff(t)}executePivotOff(e){this.aggregationColumnsHashLastTime=null,this.uniqueValues={},this.columnModel.isSecondaryColumnsPresent()&&(this.columnModel.setSecondaryColumns(null,"rowModelUpdated"),e&&e.setInactive())}executePivotOn(e){var t;const i=null!=(t=this.columnModel.getValueColumns().length)?t:1,r=this.gos.get("pivotMaxGeneratedColumns");let n;this.maxUniqueValues=-1===r?-1:r/i;try{n=this.bucketUpRowNodes(e)}catch(e){if(e.message===Zl.EXCEEDED_MAX_UNIQUE_VALUES){this.columnModel.setSecondaryColumns([],"rowModelUpdated");const t={type:_l.Events.EVENT_PIVOT_MAX_COLUMNS_EXCEEDED,message:e.message};return this.eventService.dispatchEvent(t),void(this.lastTimeFailed=!0)}throw e}const s=this.setUniqueValues(n),o=this.columnModel.getValueColumns(),a=o.map(e=>`${e.getId()}-${e.getColDef().headerName}`).join("#"),l=o.map(e=>e.getAggFunc().toString()).join("#"),c=this.aggregationColumnsHashLastTime!==a,u=this.aggregationFuncsHashLastTime!==l;this.aggregationColumnsHashLastTime=a,this.aggregationFuncsHashLastTime=l;const h=this.columnModel.getRowGroupColumns().map(e=>e.getId()).join("#"),d=h!==this.groupColumnsHashLastTime;this.groupColumnsHashLastTime=h;const p=this.gos.get("pivotRowTotals"),g=this.gos.get("pivotColumnGroupTotals"),f=this.gos.get("suppressExpandablePivotGroups"),m=this.gos.get("removePivotHeaderRowWhenSingleValueColumn"),v=p!==this.pivotRowTotalsLastTime||g!==this.pivotColumnGroupTotalsLastTime||f!==this.suppressExpandablePivotGroupsLastTime||m!==this.removePivotHeaderRowWhenSingleValueColumnLastTime;if(this.pivotRowTotalsLastTime=p,this.pivotColumnGroupTotalsLastTime=g,this.suppressExpandablePivotGroupsLastTime=f,this.removePivotHeaderRowWhenSingleValueColumnLastTime=m,this.lastTimeFailed||s||c||d||u||v){const{pivotColumnGroupDefs:t,pivotColumnDefs:i}=this.pivotColDefService.createPivotColumnDefs(this.uniqueValues);this.pivotColumnDefs=i,this.columnModel.setSecondaryColumns(t,"rowModelUpdated"),e&&e.setInactive()}this.lastTimeFailed=!1}setUniqueValues(e){return!(JSON.stringify(e)===JSON.stringify(this.uniqueValues)||(this.uniqueValues=e,0))}bucketUpRowNodes(e){this.currentUniqueCount=0;const t={};e.forEachChangedNodeDepthFirst(e=>{e.leafGroup&&(e.childrenMapped=null)});const i=e=>{var r;e.leafGroup?this.bucketRowNode(e,t):null==(r=e.childrenAfterFilter)||r.forEach(i)};return e.executeFromRootNode(i),t}bucketRowNode(e,t){const i=this.columnModel.getPivotColumns();0===i.length?e.childrenMapped=null:e.childrenMapped=this.bucketChildren(e.childrenAfterFilter,i,0,t),e.sibling&&(e.sibling.childrenMapped=e.childrenMapped)}bucketChildren(e,t,i,r){const n={},s=t[i];if(e.forEach(e=>{let t=this.valueService.getKeyForNode(s,e);if(_l._.missing(t)&&(t=""),!r[t]){this.currentUniqueCount+=1,r[t]={};const e=-1!==this.maxUniqueValues,i=this.currentUniqueCount>this.maxUniqueValues;if(e&&i)throw Error(Zl.EXCEEDED_MAX_UNIQUE_VALUES)}n[t]||(n[t]=[]),n[t].push(e)}),i===t.length-1)return n;{const e={};return _l._.iterateObject(n,(n,s)=>{e[n]=this.bucketChildren(s,t,i+1,r[n])}),e}}getPivotColumnDefs(){return this.pivotColumnDefs}};Zl.EXCEEDED_MAX_UNIQUE_VALUES="Exceeded maximum allowed pivot column count.",$l([(0,_l.Autowired)("valueService")],Zl.prototype,"valueService",2),$l([(0,_l.Autowired)("columnModel")],Zl.prototype,"columnModel",2),$l([(0,_l.Autowired)("pivotColDefService")],Zl.prototype,"pivotColDefService",2),Zl=$l([(0,_l.Bean)("pivotStage")],Zl);var Jl={sum:"Sum",first:"First",last:"Last",min:"Min",max:"Max",count:"Count",avg:"Average"},ec=class extends Pl.BeanStub{constructor(){super(...arguments),this.aggFuncsMap={},this.initialised=!1}init(){this.initialised||(this.initialiseWithDefaultAggregations(),this.addAggFuncs(this.gos.get("aggFuncs")))}initialiseWithDefaultAggregations(){this.aggFuncsMap[ec.AGG_SUM]=tc,this.aggFuncsMap[ec.AGG_FIRST]=ic,this.aggFuncsMap[ec.AGG_LAST]=rc,this.aggFuncsMap[ec.AGG_MIN]=nc,this.aggFuncsMap[ec.AGG_MAX]=sc,this.aggFuncsMap[ec.AGG_COUNT]=oc,this.aggFuncsMap[ec.AGG_AVG]=ac,this.initialised=!0}isAggFuncPossible(e,t){const i=this.getFuncNames(e),r=Pl._.includes(i,t),n=Pl._.exists(this.aggFuncsMap[t]);return r&&n}getDefaultFuncLabel(e){var t;return null!=(t=Jl[e])?t:e}getDefaultAggFunc(e){const t=e.getColDef().defaultAggFunc;if(Pl._.exists(t)&&this.isAggFuncPossible(e,t))return t;if(this.isAggFuncPossible(e,ec.AGG_SUM))return ec.AGG_SUM;const i=this.getFuncNames(e);return Pl._.existsAndNotEmpty(i)?i[0]:null}addAggFuncs(e){this.init(),Pl._.iterateObject(e,(e,t)=>{this.aggFuncsMap[e]=t})}getAggFunc(e){return this.init(),this.aggFuncsMap[e]}getFuncNames(e){const t=e.getColDef().allowedAggFuncs;return null==t?Object.keys(this.aggFuncsMap).sort():t}clear(){this.aggFuncsMap={}}};function tc(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"==typeof r?null===i?i=r:i+="number"==typeof i?r:BigInt(r):"bigint"==typeof r&&(i=null===i?r:("bigint"==typeof i?i:BigInt(i))+r)}return i}function ic(e){return e.values.length>0?e.values[0]:null}function rc(e){return e.values.length>0?Pl._.last(e.values):null}function nc(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"!=typeof r&&"bigint"!=typeof r||!(null===i||i>r)||(i=r)}return i}function sc(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"!=typeof r&&"bigint"!=typeof r||!(null===i||i<r)||(i=r)}return i}function oc(e){var t,i;const{values:r}=e;let n=0;for(let e=0;e<r.length;e++){const t=r[e];n+=null!=t&&"number"==typeof t.value?t.value:1}const s=null==(i=null==(t=e.rowNode)?void 0:t.aggData)?void 0:i[e.column.getColId()];return s&&s.value===n?s:{value:n,toString:function(){return this.value.toString()},toNumber:function(){return this.value}}}function ac(e){var t,i,r;const{values:n}=e;let s=0,o=0;for(let e=0;e<n.length;e++){const t=n[e];let i=null;"number"==typeof t||"bigint"==typeof t?(i=t,o++):null==t||"number"!=typeof t.value&&"bigint"!=typeof t.value||"number"!=typeof t.count||(i=t.value*("number"==typeof t.value?t.count:BigInt(t.count)),o+=t.count),"number"==typeof i?s+="number"==typeof s?i:BigInt(i):"bigint"==typeof i&&(s=("bigint"==typeof s?s:BigInt(s))+i)}let a=null;o>0&&(a=s/("number"==typeof s?o:BigInt(o)));const l=null==(r=null==(t=e.rowNode)?void 0:t.aggData)?void 0:r[null==(i=e.column)?void 0:i.getColId()];return l&&l.count===o&&l.value===a?l:{count:o,value:a,toString:function(){return"number"==typeof this.value||"bigint"==typeof this.value?this.value.toString():""},toNumber:function(){return this.value}}}ec.AGG_SUM="sum",ec.AGG_FIRST="first",ec.AGG_LAST="last",ec.AGG_MIN="min",ec.AGG_MAX="max",ec.AGG_COUNT="count",ec.AGG_AVG="avg",$l([Pl.PostConstruct],ec.prototype,"init",1),ec=$l([(0,Pl.Bean)("aggFuncService")],ec);var lc=class extends Ll.PillDragComp{constructor(e,t,i,r,n){super(t,i,n,'\n                <span role="option">\n                    <span ref="eDragHandle" class="ag-drag-handle ag-column-drop-cell-drag-handle" role="presentation"></span>\n                    <span ref="eText" class="ag-column-drop-cell-text" aria-hidden="true"></span>\n                    <ag-sort-indicator ref="eSortIndicator"></ag-sort-indicator>\n                    <span ref="eButton" class="ag-column-drop-cell-button" role="presentation"></span>\n                </span>\n            '),this.column=e,this.dropZonePurpose=r,this.popupShowing=!1}init(){this.displayName=this.columnModel.getDisplayNameForColumn(this.column,"columnDrop"),super.init(),this.setupSort(),this.addManagedListener(this.eventService,Ll.Column.EVENT_SORT_CHANGED,()=>{this.setupAria()}),this.isGroupingZone()&&this.addManagedPropertyListener("groupLockGroupColumns",()=>{this.refreshRemove(),this.refreshDraggable(),this.setupAria()})}getItem(){return this.column}getDisplayName(){return this.displayName}getTooltip(){return this.column.getColDef().headerTooltip}addAdditionalAriaInstructions(e,t){const i=this.gos.get("rowGroupPanelSuppressSort"),r=this.gos.get("functionsReadOnly");if(this.isAggregationZone()&&!r){const i=t("ariaDropZoneColumnValueItemDescription","Press ENTER to change the aggregation type");e.push(i)}if(this.isGroupingZone()&&this.column.isSortable()&&!i){const i=t("ariaDropZoneColumnGroupItemDescription","Press ENTER to sort");e.push(i)}super.addAdditionalAriaInstructions(e,t)}isDraggable(){return this.isReadOnly()}isRemovable(){return this.isReadOnly()}isReadOnly(){return!this.isGroupingAndLocked()&&!this.gos.get("functionsReadOnly")}getAriaDisplayName(){const e=this.localeService.getLocaleTextFunc(),{name:t,aggFuncName:i}=this.getColumnAndAggFuncName(),r=e("ariaDropZoneColumnComponentAggFuncSeparator"," of "),n={asc:e("ariaDropZoneColumnComponentSortAscending","ascending"),desc:e("ariaDropZoneColumnComponentSortDescending","descending")},s=this.column.getSort(),o=this.gos.get("rowGroupPanelSuppressSort");return[i&&`${i}${r}`,t,this.isGroupingZone()&&!o&&s&&`, ${n[s]}`].filter(e=>!!e).join("")}getColumnAndAggFuncName(){const e=this.displayName;let t="";if(this.isAggregationZone()){const e=this.column.getAggFunc(),i="string"==typeof e?e:"agg";t=this.localeService.getLocaleTextFunc()(i,i)}return{name:e,aggFuncName:t}}setupSort(){const e=this.column.isSortable(),t=this.isGroupingZone();if(e&&t&&!this.gos.get("rowGroupPanelSuppressSort")){this.eSortIndicator.setupSort(this.column,!0);const e=e=>{e.preventDefault();const t="ctrl"===this.gos.get("multiSortKey")?e.ctrlKey||e.metaKey:e.shiftKey;this.sortController.progressSort(this.column,t,"uiColumnSorted")};this.addGuiEventListener("click",e),this.addGuiEventListener("keydown",t=>{t.key===Ll.KeyCode.ENTER&&this.isGroupingZone()&&e(t)})}}getDefaultIconName(){return Ll.DragAndDropService.ICON_HIDE}createGetDragItem(){const{column:e}=this;return()=>{const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t}}}setupComponents(){super.setupComponents(),this.isAggregationZone()&&!this.gos.get("functionsReadOnly")&&this.addGuiEventListener("click",this.onShowAggFuncSelection.bind(this))}onKeyDown(e){super.onKeyDown(e),e.key===Ll.KeyCode.ENTER&&this.isAggregationZone()&&!this.gos.get("functionsReadOnly")&&(e.preventDefault(),this.onShowAggFuncSelection())}getDisplayValue(){const{name:e,aggFuncName:t}=this.getColumnAndAggFuncName();return this.isAggregationZone()?`${t}(${e})`:e}onShowAggFuncSelection(){if(this.popupShowing)return;this.popupShowing=!0;const e=new Ll.VirtualList({cssIdentifier:"select-agg-func"}),t=this.aggFuncService.getFuncNames(this.column),i=this.getGui(),r=e.getGui();e.setModel({getRow:function(e){return t[e]},getRowCount:function(){return t.length}}),this.getContext().createBean(e);const n=Ll._.loadTemplate('<div class="ag-select-agg-func-popup"></div>');n.style.top="0px",n.style.left="0px",n.appendChild(r),n.style.width=`${i.clientWidth}px`;const s=this.addManagedListener(n,"focusout",e=>{!n.contains(e.relatedTarget)&&a&&a.hideFunc()}),o=this.localeService.getLocaleTextFunc(),a=this.popupService.addPopup({modal:!0,eChild:n,closeOnEsc:!0,closedCallback:t=>{this.destroyBean(e),this.popupShowing=!1,"Escape"===(null==t?void 0:t.key)&&i.focus(),s&&s()},ariaLabel:o("ariaLabelAggregationFunction","Aggregation Function")});a&&e.setComponentCreator(this.createAggSelect.bind(this,a.hideFunc)),e.addGuiEventListener("keydown",t=>{if(t.key===Ll.KeyCode.ENTER||t.key===Ll.KeyCode.SPACE){const t=e.getLastFocusedRow();if(null==t)return;const i=e.getComponentAt(t);i&&i.selectItem()}}),this.popupService.positionPopupByComponent({type:"aggFuncSelect",eventSource:i,ePopup:n,keepWithinBounds:!0,column:this.column,position:"under"}),e.refresh();let l=t.findIndex(e=>e===this.column.getAggFunc());-1===l&&(l=0),e.focusRow(l)}createAggSelect(e,t){const i=this.localeService.getLocaleTextFunc(),r=t.toString(),n=i(r,r);return new cc(()=>{if(e(),this.gos.get("functionsPassive")){const e={type:Ll.Events.EVENT_COLUMN_AGG_FUNC_CHANGE_REQUEST,columns:[this.column],aggFunc:t};this.eventService.dispatchEvent(e)}else this.columnModel.setColumnAggFunc(this.column,t,"toolPanelDragAndDrop")},n)}isGroupingAndLocked(){return this.isGroupingZone()&&this.columnModel.isColumnGroupingLocked(this.column)}isAggregationZone(){return"aggregation"===this.dropZonePurpose}isGroupingZone(){return"rowGroup"===this.dropZonePurpose}getDragSourceType(){return Ll.DragSourceType.ToolPanel}destroy(){super.destroy(),this.column=null}};$l([(0,Ll.Autowired)("popupService")],lc.prototype,"popupService",2),$l([(0,Ll.Autowired)("sortController")],lc.prototype,"sortController",2),$l([(0,Ll.Autowired)("columnModel")],lc.prototype,"columnModel",2),$l([(0,Ll.Optional)("aggFuncService")],lc.prototype,"aggFuncService",2),$l([(0,Ll.RefSelector)("eSortIndicator")],lc.prototype,"eSortIndicator",2);var cc=class extends Ll.Component{constructor(e,t){super('<div class="ag-select-agg-func-item"/>'),this.selectItem=e,this.getGui().innerText=t,this.addGuiEventListener("click",this.selectItem)}},uc=class extends Il.PillDropZonePanel{constructor(e,t){super(e),this.dropZonePurpose=t}init(e){super.init(e),this.addManagedListener(this.eventService,Il.Events.EVENT_NEW_COLUMNS_LOADED,this.refreshGui.bind(this)),this.addManagedPropertyListeners(["functionsReadOnly","rowGroupPanelSuppressSort","groupLockGroupColumns"],this.refreshGui.bind(this))}getItems(e){var t;return null!=(t=e.columns)?t:[]}isInterestedIn(e){return e===Il.DragSourceType.HeaderCell||e===Il.DragSourceType.ToolPanel}minimumAllowedNewInsertIndex(){const e=this.gos.get("groupLockGroupColumns"),t=this.columnModel.getRowGroupColumns().length;return-1===e?t:Math.min(e,t)}showOrHideColumnOnExit(e){return this.isRowGroupPanel()&&!this.gos.get("suppressRowGroupHidesColumns")&&!e.fromNudge}handleDragEnterEnd(e){if(this.showOrHideColumnOnExit(e)){const t=e.dragSource.getDragItem().columns;this.setColumnsVisible(t,!1,"uiColumnDragged")}}handleDragLeaveEnd(e){if(this.showOrHideColumnOnExit(e)){const t=e.dragSource.getDragItem();this.setColumnsVisible(t.columns,!0,"uiColumnDragged")}}setColumnsVisible(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockVisible);this.columnModel.setColumnsVisible(r,t,i)}}isRowGroupPanel(){return"rowGroup"===this.dropZonePurpose}refreshOnDragStop(){return!this.gos.get("functionsPassive")}createPillComponent(e,t,i,r){return new lc(e,t,i,this.dropZonePurpose,r)}};$l([(0,Il.Autowired)("columnModel")],uc.prototype,"columnModel",2);var hc=class extends uc{constructor(e){super(e,"rowGroup")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("rowGroupColumnsEmptyMessage","Drag here to set row groups"),i=e("groups","Row Groups");super.init({icon:Dl._.createIconNoSpan("rowGroupPanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,Dl.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,this.refreshGui.bind(this))}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaRowGroupDropZonePanelLabel","Row Groups")}getTooltipParams(){const e=super.getTooltipParams();return e.location="rowGroupColumnsList",e}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowRowGroup()&&(!e.isRowGroupActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:Dl.Events.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setRowGroupColumns(e,"toolPanelUi")}getIconName(){return this.isPotentialDndItems()?Dl.DragAndDropService.ICON_GROUP:Dl.DragAndDropService.ICON_NOT_ALLOWED}getExistingItems(){return this.columnModel.getRowGroupColumns()}};$l([Dl.PostConstruct],hc.prototype,"passBeansUp",1);var dc=class extends uc{constructor(e){super(e,"pivot")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("pivotColumnsEmptyMessage","Drag here to set column labels"),i=e("pivots","Column Labels");super.init({icon:Nl._.createIconNoSpan("pivotPanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,Nl.Events.EVENT_NEW_COLUMNS_LOADED,this.refresh.bind(this)),this.addManagedListener(this.eventService,Nl.Events.EVENT_COLUMN_PIVOT_CHANGED,this.refresh.bind(this)),this.addManagedListener(this.eventService,Nl.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.checkVisibility.bind(this)),this.refresh()}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaPivotDropZonePanelLabel","Column Labels")}getTooltipParams(){const e=super.getTooltipParams();return e.location="pivotColumnsList",e}refresh(){this.checkVisibility(),this.refreshGui()}checkVisibility(){const e=this.columnModel.isPivotMode();if(this.isHorizontal())switch(this.gos.get("pivotPanelShow")){case"always":this.setDisplayed(e);break;case"onlyWhenPivoting":const t=this.columnModel.isPivotActive();this.setDisplayed(e&&t);break;default:this.setDisplayed(!1)}else this.setDisplayed(e)}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowPivot()&&(!e.isPivotActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:Nl.Events.EVENT_COLUMN_PIVOT_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setPivotColumns(e,"toolPanelUi")}getIconName(){return this.isPotentialDndItems()?Nl.DragAndDropService.ICON_PIVOT:Nl.DragAndDropService.ICON_NOT_ALLOWED}getExistingItems(){return this.columnModel.getPivotColumns()}};$l([Nl.PostConstruct],dc.prototype,"passBeansUp",1);var pc=class extends xl.Component{constructor(){super()}postConstruct(){this.setGui(this.createNorthPanel()),this.addManagedListener(this.eventService,xl.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onRowGroupChanged()),this.addManagedListener(this.eventService,xl.Events.EVENT_NEW_COLUMNS_LOADED,()=>this.onRowGroupChanged()),this.addManagedPropertyListener("rowGroupPanelShow",()=>this.onRowGroupChanged()),this.addManagedPropertyListener("pivotPanelShow",()=>this.onPivotPanelShow()),this.onRowGroupChanged()}createNorthPanel(){const e=document.createElement("div");return e.classList.add("ag-column-drop-wrapper"),xl._.setAriaRole(e,"presentation"),this.rowGroupComp=new hc(!0),this.createManagedBean(this.rowGroupComp),this.pivotComp=new dc(!0),this.createManagedBean(this.pivotComp),e.appendChild(this.rowGroupComp.getGui()),e.appendChild(this.pivotComp.getGui()),this.addManagedListener(this.rowGroupComp,xl.Component.EVENT_DISPLAYED_CHANGED,()=>this.onDropPanelVisible()),this.addManagedListener(this.pivotComp,xl.Component.EVENT_DISPLAYED_CHANGED,()=>this.onDropPanelVisible()),this.onDropPanelVisible(),e}onDropPanelVisible(){const e=this.rowGroupComp.isDisplayed()&&this.pivotComp.isDisplayed();this.rowGroupComp.addOrRemoveCssClass("ag-column-drop-horizontal-half-width",e),this.pivotComp.addOrRemoveCssClass("ag-column-drop-horizontal-half-width",e)}onRowGroupChanged(){if(!this.rowGroupComp)return;const e=this.gos.get("rowGroupPanelShow");if("always"===e)this.rowGroupComp.setDisplayed(!0);else if("onlyWhenGrouping"===e){const e=!this.columnModel.isRowGroupEmpty();this.rowGroupComp.setDisplayed(e)}else this.rowGroupComp.setDisplayed(!1)}onPivotPanelShow(){if(!this.pivotComp)return;const e=this.gos.get("pivotPanelShow");if("always"===e)this.pivotComp.setDisplayed(!0);else if("onlyWhenPivoting"===e){const e=this.columnModel.isPivotActive();this.pivotComp.setDisplayed(e)}else this.pivotComp.setDisplayed(!1)}};$l([(0,xl.Autowired)("columnModel")],pc.prototype,"columnModel",2),$l([xl.PostConstruct],pc.prototype,"postConstruct",1);var gc=class extends Ol.BeanStub{execute(e){const t=this.columnModel.isPivotMode(),i=this.filterManager.isAggregateFilterPresent()||this.filterManager.isAggregateQuickFilterPresent(),r=this.gos.getGroupAggFiltering()||(t?e=>e.node.leafGroup:e=>!e.node.group),{changedPath:n}=e,s=(e,t=!1)=>{e.childrenAfterFilter&&(e.childrenAfterAggFilter=e.childrenAfterFilter,t&&e.childrenAfterAggFilter.forEach(e=>s(e,t)),this.setAllChildrenCount(e)),e.sibling&&(e.sibling.childrenAfterAggFilter=e.childrenAfterAggFilter)};n.forEachChangedNodeDepthFirst(i?e=>{var t;e.childrenAfterAggFilter=(null==(t=e.childrenAfterFilter)?void 0:t.filter(e=>{var t;return r({node:e})&&this.filterManager.doesRowPassAggregateFilters({rowNode:e})?(s(e,!0),!0):null==(t=e.childrenAfterAggFilter)?void 0:t.length}))||null,this.setAllChildrenCount(e),e.sibling&&(e.sibling.childrenAfterAggFilter=e.childrenAfterAggFilter)}:s,!0)}setAllChildrenCountTreeData(e){let t=0;e.childrenAfterAggFilter.forEach(e=>{t++,t+=e.allChildrenCount}),e.setAllChildrenCount(t)}setAllChildrenCountGridGrouping(e){let t=0;e.childrenAfterAggFilter.forEach(e=>{e.group?t+=e.allChildrenCount:t++}),e.setAllChildrenCount(t)}setAllChildrenCount(e){e.hasChildren()?this.gos.get("treeData")?this.setAllChildrenCountTreeData(e):this.setAllChildrenCountGridGrouping(e):e.setAllChildrenCount(null)}};$l([(0,Ol.Autowired)("filterManager")],gc.prototype,"filterManager",2),$l([(0,Ol.Autowired)("columnModel")],gc.prototype,"columnModel",2),gc=$l([(0,Ol.Bean)("filterAggregatesStage")],gc);var fc=class e extends Fl.TabGuardComp{constructor(){super('\n            <div class="ag-group-filter">\n                <div ref="eGroupField"></div>\n                <div ref="eUnderlyingFilter"></div>\n            </div>\n        ')}postConstruct(){this.initialiseTabGuard({})}init(e){return this.params=e,this.validateParams(),this.updateGroups().then(()=>{this.addManagedListener(this.eventService,Fl.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onColumnRowGroupChanged())})}validateParams(){const{colDef:e}=this.params;e.field&&Fl._.warnOnce('Group Column Filter does not work with the colDef property "field". This property will be ignored.'),e.filterValueGetter&&Fl._.warnOnce('Group Column Filter does not work with the colDef property "filterValueGetter". This property will be ignored.'),e.filterParams&&Fl._.warnOnce('Group Column Filter does not work with the colDef property "filterParams". This property will be ignored.')}updateGroups(){const e=this.updateGroupField();return this.getUnderlyingFilters(e)}getSourceColumns(){if(this.groupColumn=this.params.column,this.gos.get("treeData"))return Fl._.warnOnce("Group Column Filter does not work with Tree Data enabled. Please disable Tree Data, or use a different filter."),[];return this.columnModel.getSourceColumnsForGroupColumn(this.groupColumn)||(Fl._.warnOnce("Group Column Filter only works on group columns. Please use a different filter."),[])}updateGroupField(){Fl._.clearElement(this.eGroupField),this.eGroupFieldSelect&&this.destroyBean(this.eGroupFieldSelect);const e=this.getSourceColumns(),t=e.filter(e=>e.isFilterAllowed());return t.length?(1===e.length?(this.selectedColumn=t[0],Fl._.setDisplayed(this.eGroupField,!1)):(this.selectedColumn&&t.some(e=>e.getId()===this.selectedColumn.getId())||(this.selectedColumn=t[0]),this.createGroupFieldSelectElement(t),this.eGroupField.appendChild(this.eGroupFieldSelect.getGui()),this.eGroupField.appendChild(Fl._.loadTemplate('<div class="ag-filter-separator"></div>')),Fl._.setDisplayed(this.eGroupField,!0)),t):(this.selectedColumn=void 0,Fl._.setDisplayed(this.eGroupField,!1),null)}createGroupFieldSelectElement(e){this.eGroupFieldSelect=this.createManagedBean(new Fl.AgSelect);const t=this.localeService.getLocaleTextFunc();this.eGroupFieldSelect.setLabel(t("groupFilterSelect","Select field:")),this.eGroupFieldSelect.setLabelAlignment("top"),this.eGroupFieldSelect.addOptions(e.map(e=>{var t;return{value:e.getId(),text:null!=(t=this.columnModel.getDisplayNameForColumn(e,"groupFilter",!1))?t:void 0}})),this.eGroupFieldSelect.setValue(this.selectedColumn.getId()),this.eGroupFieldSelect.onValueChange(e=>this.updateSelectedColumn(e)),this.eGroupFieldSelect.addCssClass("ag-group-filter-field-select-wrapper"),1===e.length&&this.eGroupFieldSelect.setDisabled(!0)}getUnderlyingFilters(e){if(!e)return this.filterColumnPairs=void 0,this.selectedFilter=void 0,this.groupColumn.setFilterActive(!1,"columnRowGroupChanged"),Fl.AgPromise.resolve();const t=[],i=[];return e.forEach(e=>{const r=this.filterManager.getOrCreateFilterWrapper(e,"COLUMN_MENU");(null==r?void 0:r.filterPromise)&&t.push(r.filterPromise.then(t=>(t&&i.push({filter:t,column:e}),e.getId()===this.selectedColumn.getId()&&(this.selectedFilter=null!=t?t:void 0),t)))}),Fl.AgPromise.all(t).then(()=>{this.filterColumnPairs=i,this.groupColumn.setFilterActive(this.isFilterActive(),"columnRowGroupChanged")})}addUnderlyingFilterElement(){var e,t;if(Fl._.clearElement(this.eUnderlyingFilter),!this.selectedColumn)return Fl.AgPromise.resolve();const i=this.createManagedBean(new Fl.FilterWrapperComp(this.selectedColumn,"COLUMN_MENU"));return this.filterWrapperComp=i,i.hasFilter()?(this.eUnderlyingFilter.appendChild(i.getGui()),null!=(t=null==(e=i.getFilter())?void 0:e.then(()=>{var e,t;null==(e=i.afterGuiAttached)||e.call(i,this.afterGuiAttachedParams),(null==(t=this.afterGuiAttachedParams)?void 0:t.suppressFocus)||!this.eGroupFieldSelect||this.eGroupFieldSelect.isDisabled()||this.eGroupFieldSelect.getFocusableElement().focus()}))?t:Fl.AgPromise.resolve()):Fl.AgPromise.resolve()}updateSelectedColumn(t){var i;if(!t)return;null==(i=this.filterWrapperComp)||i.afterGuiDetached(),this.destroyBean(this.filterWrapperComp);const r=this.getFilterColumnPair(t);this.selectedColumn=null==r?void 0:r.column,this.selectedFilter=null==r?void 0:r.filter,this.dispatchEvent({type:e.EVENT_SELECTED_COLUMN_CHANGED}),this.addUnderlyingFilterElement()}isFilterActive(){var e;return!!(null==(e=this.filterColumnPairs)?void 0:e.some(({filter:e})=>e.isFilterActive()))}doesFilterPass(){return!0}getModel(){return null}setModel(){return Fl.AgPromise.resolve()}afterGuiAttached(e){this.afterGuiAttachedParams=e,this.addUnderlyingFilterElement()}afterGuiDetached(){var e,t;Fl._.clearElement(this.eUnderlyingFilter),null==(t=null==(e=this.selectedFilter)?void 0:e.afterGuiDetached)||t.call(e)}onColumnRowGroupChanged(){this.updateGroups().then(()=>{this.dispatchEvent({type:e.EVENT_COLUMN_ROW_GROUP_CHANGED}),this.eventService.dispatchEvent({type:"filterAllowedUpdated"})})}getFilterColumnPair(e){var t;if(e)return null==(t=this.filterColumnPairs)?void 0:t.find(({column:t})=>t.getId()===e)}getSelectedFilter(){return this.selectedFilter}getSelectedColumn(){return this.selectedColumn}isFilterAllowed(){return!!this.selectedColumn}destroy(){super.destroy()}};fc.EVENT_COLUMN_ROW_GROUP_CHANGED="columnRowGroupChanged",fc.EVENT_SELECTED_COLUMN_CHANGED="selectedColumnChanged",$l([(0,Fl.Autowired)("filterManager")],fc.prototype,"filterManager",2),$l([(0,Fl.Autowired)("columnModel")],fc.prototype,"columnModel",2),$l([(0,Fl.RefSelector)("eGroupField")],fc.prototype,"eGroupField",2),$l([(0,Fl.RefSelector)("eUnderlyingFilter")],fc.prototype,"eUnderlyingFilter",2),$l([Fl.PostConstruct],fc.prototype,"postConstruct",1);var mc=fc,vc=class extends kl.Component{constructor(){super('\n            <div ref="eFloatingFilter" class="ag-group-floating-filter ag-floating-filter-input" role="presentation"></div>\n        '),this.haveAddedColumnListeners=!1}init(e){this.params=e;const t="multipleColumns"===this.gos.get("groupDisplayType");return new kl.AgPromise(e=>{this.params.parentFilterInstance(i=>{this.parentFilterInstance=i,t?this.setupUnderlyingFloatingFilterElement().then(()=>e()):(this.setupReadOnlyFloatingFilterElement(),e())})}).then(()=>{this.addManagedListener(this.parentFilterInstance,mc.EVENT_SELECTED_COLUMN_CHANGED,()=>this.onSelectedColumnChanged()),this.addManagedListener(this.parentFilterInstance,mc.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onColumnRowGroupChanged())})}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams()}setParams(){var e;const t=this.columnModel.getDisplayNameForColumn(this.params.column,"header",!0),i=this.localeService.getLocaleTextFunc();null==(e=this.eFloatingFilterText)||e.setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}setupReadOnlyFloatingFilterElement(){this.eFloatingFilterText||(this.eFloatingFilterText=this.createManagedBean(new kl.AgInputTextField),this.eFloatingFilterText.setDisabled(!0).addGuiEventListener("click",()=>this.params.showParentFilter()),this.setParams()),this.updateDisplayedValue(),this.eFloatingFilter.appendChild(this.eFloatingFilterText.getGui())}setupUnderlyingFloatingFilterElement(){this.showingUnderlyingFloatingFilter=!1,this.underlyingFloatingFilter=void 0,kl._.clearElement(this.eFloatingFilter);const e=this.parentFilterInstance.getSelectedColumn();if(e&&!e.isVisible()){const t=this.filterManager.getFloatingFilterCompDetails(e,this.params.showParentFilter);if(t)return this.compDetails=t,this.haveAddedColumnListeners||(this.haveAddedColumnListeners=!0,this.addManagedListener(e,kl.Column.EVENT_VISIBLE_CHANGED,this.onColumnVisibleChanged.bind(this)),this.addManagedListener(e,kl.Column.EVENT_COL_DEF_CHANGED,this.onColDefChanged.bind(this))),t.newAgStackInstance().then(e=>{var t,i;this.underlyingFloatingFilter=e,null==(i=this.underlyingFloatingFilter)||i.onParentModelChanged(null==(t=this.parentFilterInstance.getSelectedFilter())?void 0:t.getModel()),this.appendChild(e.getGui()),this.showingUnderlyingFloatingFilter=!0})}return this.setupReadOnlyFloatingFilterElement(),kl.AgPromise.resolve()}onColumnVisibleChanged(){this.setupUnderlyingFloatingFilterElement()}onColDefChanged(e){var t,i,r;if(!e.column)return;const n=this.filterManager.getFloatingFilterCompDetails(e.column,this.params.showParentFilter);n&&((null==(t=this.underlyingFloatingFilter)?void 0:t.refresh)?this.underlyingFloatingFilter.refresh(n.params):null==(r=null==(i=this.underlyingFloatingFilter)?void 0:i.onParamsUpdated)||r.call(i,n.params))}onParentModelChanged(e,t){var i,r;this.showingUnderlyingFloatingFilter?null==(r=this.underlyingFloatingFilter)||r.onParentModelChanged(null==(i=this.parentFilterInstance.getSelectedFilter())?void 0:i.getModel(),t):this.updateDisplayedValue()}updateDisplayedValue(){if(!this.parentFilterInstance||!this.eFloatingFilterText)return;const e=this.parentFilterInstance.getSelectedFilter();if(!e)return this.eFloatingFilterText.setValue(""),void this.eFloatingFilterText.setDisplayed(!1);if(this.eFloatingFilterText.setDisplayed(!0),e.getModelAsString){const t=e.getModel();this.eFloatingFilterText.setValue(null==t?"":e.getModelAsString(t))}else this.eFloatingFilterText.setValue("")}onSelectedColumnChanged(){this.showingUnderlyingFloatingFilter||this.updateDisplayedValue()}onColumnRowGroupChanged(){this.showingUnderlyingFloatingFilter||this.updateDisplayedValue()}destroy(){super.destroy()}};$l([(0,kl.Autowired)("columnModel")],vc.prototype,"columnModel",2),$l([(0,kl.Autowired)("filterManager")],vc.prototype,"filterManager",2),$l([(0,kl.RefSelector)("eFloatingFilter")],vc.prototype,"eFloatingFilter",2);var Cc={version:"31.3.4",moduleName:Al.ModuleNames.RowGroupingModule,beans:[ql,gc,Ql,Xl,Zl,ec],agStackComponents:[{componentName:"AgGridHeaderDropZones",componentClass:pc}],userComponents:[{componentName:"agGroupColumnFilter",componentClass:mc},{componentName:"agGroupColumnFloatingFilter",componentClass:vc}],dependantModules:[_]},yc=class extends uc{constructor(e){super(e,"aggregation")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("valueColumnsEmptyMessage","Drag here to aggregate"),i=e("values","Values");super.init({icon:Gl._.createIconNoSpan("valuePanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,Gl.Events.EVENT_COLUMN_VALUE_CHANGED,this.refreshGui.bind(this))}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaValuesDropZonePanelLabel","Values")}getTooltipParams(){const e=super.getTooltipParams();return e.location="valueColumnsList",e}getIconName(){return this.isPotentialDndItems()?Gl.DragAndDropService.ICON_AGGREGATE:Gl.DragAndDropService.ICON_NOT_ALLOWED}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowValue()&&(!e.isValueActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:Gl.Events.EVENT_COLUMN_VALUE_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setValueColumns(e,"toolPanelUi")}getExistingItems(){return this.columnModel.getValueColumns()}};$l([Gl.PostConstruct],yc.prototype,"passBeansUp",1);var wc=i(98092),Sc=i(98092),bc=i(98092),Ec=i(98092),Ac=i(98092),Tc=i(98092),Mc=i(98092),Rc=i(98092),_c=i(98092),Pc=Object.defineProperty,xc=Object.defineProperties,Dc=Object.getOwnPropertyDescriptor,Ic=Object.getOwnPropertyDescriptors,Lc=Object.getOwnPropertySymbols,Nc=Object.prototype.hasOwnProperty,Oc=Object.prototype.propertyIsEnumerable,Fc=(e,t,i)=>t in e?Pc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,kc=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Dc(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Pc(t,i,s),s},Gc=class extends bc.Component{constructor(){super('<div class="ag-tool-panel-horizontal-resize"></div>'),this.minWidth=100,this.maxWidth=null}setElementToResize(e){this.elementToResize=e}postConstruct(){const e=this.horizontalResizeService.addResizeBar({eResizeBar:this.getGui(),dragStartPixels:1,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this),onResizeEnd:this.onResizeEnd.bind(this)});this.addDestroyFunc(e),this.setInverted(this.gos.get("enableRtl"))}dispatchResizeEvent(e,t,i){const r={type:bc.Events.EVENT_TOOL_PANEL_SIZE_CHANGED,width:i,started:e,ended:t};this.eventService.dispatchEvent(r)}onResizeStart(){this.startingWidth=this.elementToResize.offsetWidth,this.dispatchResizeEvent(!0,!1,this.startingWidth)}onResizeEnd(e){return this.onResizing(e,!0)}onResizing(e,t=!1){const i=this.inverted?-1:1;let r=Math.max(this.minWidth,Math.floor(this.startingWidth-e*i));null!=this.maxWidth&&(r=Math.min(this.maxWidth,r)),this.elementToResize.style.width=`${r}px`,this.dispatchResizeEvent(!1,t,r)}setInverted(e){this.inverted=e}setMaxWidth(e){this.maxWidth=e}setMinWidth(e){this.minWidth=null!=e?e:100}};kc([(0,bc.Autowired)("horizontalResizeService")],Gc.prototype,"horizontalResizeService",2),kc([bc.PostConstruct],Gc.prototype,"postConstruct",1);var Vc=class e extends Tc.Component{constructor(e){super(),this.toolPanelDef=e}getToolPanelId(){return this.toolPanelDef.id}postConstruct(){const e=this.createTemplate();this.setTemplate(e),this.setLabel(),this.setIcon(),this.addManagedListener(this.eToggleButton,"click",this.onButtonPressed.bind(this)),this.eToggleButton.setAttribute("id",`ag-${this.getCompId()}-button`)}createTemplate(){return'<div class="ag-side-button" role="presentation">\n                <button type="button" ref="eToggleButton" tabindex="-1" role="tab" aria-expanded="false" class="ag-button ag-side-button-button">\n                    <div ref="eIconWrapper" class="ag-side-button-icon-wrapper" aria-hidden="true"></div>\n                    <span ref ="eLabel" class="ag-side-button-label"></span>\n                </button>\n            </div>'}setLabel(){const e=this.localeService.getLocaleTextFunc(),t=this.toolPanelDef,i=e(t.labelKey,t.labelDefault);this.eLabel.innerText=i}setIcon(){this.eIconWrapper.insertAdjacentElement("afterbegin",Tc._.createIconNoSpan(this.toolPanelDef.iconKey,this.gos))}onButtonPressed(){this.dispatchEvent({type:e.EVENT_TOGGLE_BUTTON_CLICKED})}setSelected(e){this.addOrRemoveCssClass("ag-selected",e),Tc._.setAriaExpanded(this.eToggleButton,e)}getButtonElement(){return this.eToggleButton}};Vc.EVENT_TOGGLE_BUTTON_CLICKED="toggleButtonClicked",kc([(0,Tc.RefSelector)("eToggleButton")],Vc.prototype,"eToggleButton",2),kc([(0,Tc.RefSelector)("eIconWrapper")],Vc.prototype,"eIconWrapper",2),kc([(0,Tc.RefSelector)("eLabel")],Vc.prototype,"eLabel",2),kc([Tc.PostConstruct],Vc.prototype,"postConstruct",1);var Hc=Vc,Bc=class e extends Ac.Component{constructor(){super(e.TEMPLATE),this.buttonComps=[]}postConstruct(){this.addManagedListener(this.getFocusableElement(),"keydown",this.handleKeyDown.bind(this))}handleKeyDown(e){if(e.key!==Ac.KeyCode.TAB||!e.shiftKey)return;const t=Ac._.last(this.columnModel.getAllDisplayedColumns());this.focusService.focusGridView(t,!0)&&e.preventDefault()}setActiveButton(e){this.buttonComps.forEach(t=>{t.setSelected(e===t.getToolPanelId())})}addButtonComp(t){const i=this.createBean(new Hc(t));return this.buttonComps.push(i),this.appendChild(i),i.addEventListener(Hc.EVENT_TOGGLE_BUTTON_CLICKED,()=>{this.dispatchEvent({type:e.EVENT_SIDE_BAR_BUTTON_CLICKED,toolPanelId:t.id})}),i}clearButtons(){this.buttonComps=this.destroyBeans(this.buttonComps),Ac._.clearElement(this.getGui())}};Bc.EVENT_SIDE_BAR_BUTTON_CLICKED="sideBarButtonClicked",Bc.TEMPLATE='<div class="ag-side-buttons" role="tablist"></div>',kc([(0,Ac.Autowired)("focusService")],Bc.prototype,"focusService",2),kc([(0,Ac.Autowired)("columnModel")],Bc.prototype,"columnModel",2),kc([Ac.PostConstruct],Bc.prototype,"postConstruct",1),kc([Ac.PreDestroy],Bc.prototype,"clearButtons",1);var zc=Bc,Uc=class e{static parse(t){if(t){if(!0===t)return{toolPanels:[e.DEFAULT_COLUMN_COMP,e.DEFAULT_FILTER_COMP],defaultToolPanel:"columns"};if("string"==typeof t)return e.parse([t]);if(Array.isArray(t)){const i=[];if(t.forEach(t=>{const r=e.DEFAULT_BY_KEY[t];r?i.push(r):console.warn(`AG Grid: the key ${t} is not a valid key for specifying a tool panel, valid keys are: ${Object.keys(e.DEFAULT_BY_KEY).join(",")}`)}),0===i.length)return;return{toolPanels:i,defaultToolPanel:i[0].id}}return{toolPanels:e.parseComponents(t.toolPanels),defaultToolPanel:t.defaultToolPanel,hiddenByDefault:t.hiddenByDefault,position:t.position}}}static parseComponents(t){const i=[];return t?(t.forEach(t=>{let r=null;if("string"==typeof t){const i=e.DEFAULT_BY_KEY[t];if(!i)return void console.warn(`AG Grid: the key ${t} is not a valid key for specifying a tool panel, valid keys are: ${Object.keys(e.DEFAULT_BY_KEY).join(",")}`);r=i}else r=t;i.push(r)}),i):i}};Uc.DEFAULT_COLUMN_COMP={id:"columns",labelDefault:"Columns",labelKey:"columns",iconKey:"columns",toolPanel:"agColumnsToolPanel"},Uc.DEFAULT_FILTER_COMP={id:"filters",labelDefault:"Filters",labelKey:"filters",iconKey:"filter",toolPanel:"agFiltersToolPanel"},Uc.DEFAULT_BY_KEY={columns:Uc.DEFAULT_COLUMN_COMP,filters:Uc.DEFAULT_FILTER_COMP};var Wc=Uc,jc=class e extends Mc.Component{constructor(){super(e.TEMPLATE)}setupResize(){const e=this.getGui(),t=this.resizeBar=this.createManagedBean(new Gc);e.setAttribute("id",`ag-${this.getCompId()}`),t.setElementToResize(e),this.appendChild(t)}getToolPanelId(){return this.toolPanelId}setToolPanelDef(e,t){const{id:i,minWidth:r,maxWidth:n,width:s}=e;this.toolPanelId=i,this.width=s;const o=this.userComponentFactory.getToolPanelCompDetails(e,t),a=o.newAgStackInstance();this.params=o.params,null!=a?(a.then(this.setToolPanelComponent.bind(this)),null!=r&&this.resizeBar.setMinWidth(r),null!=n&&this.resizeBar.setMaxWidth(n)):console.warn(`AG Grid: error processing tool panel component ${i}. You need to specify 'toolPanel'`)}setToolPanelComponent(e){this.toolPanelCompInstance=e,this.appendChild(e.getGui()),this.addDestroyFunc(()=>{this.destroyBean(e)}),this.width&&(this.getGui().style.width=`${this.width}px`)}getToolPanelInstance(){return this.toolPanelCompInstance}setResizerSizerSide(e){const t="left"===e,i=this.gos.get("enableRtl")?t:!t;this.resizeBar.setInverted(i)}refresh(){this.toolPanelCompInstance.refresh(this.params)}};jc.TEMPLATE='<div class="ag-tool-panel-wrapper" role="tabpanel"/>',kc([(0,Mc.Autowired)("userComponentFactory")],jc.prototype,"userComponentFactory",2),kc([Mc.PostConstruct],jc.prototype,"setupResize",1);var Kc=jc,$c=class e extends Ec.Component{constructor(){super(e.TEMPLATE),this.toolPanelWrappers=[]}postConstruct(){var e;this.sideBarButtonsComp.addEventListener(zc.EVENT_SIDE_BAR_BUTTON_CLICKED,this.onToolPanelButtonClicked.bind(this));const{sideBar:t}=null!=(e=this.gos.get("initialState"))?e:{};this.setSideBarDef({sideBarDef:Wc.parse(this.gos.get("sideBar")),sideBarState:t}),this.addManagedPropertyListener("sideBar",this.onSideBarUpdated.bind(this)),this.sideBarService.registerSideBarComp(this),this.createManagedBean(new Ec.ManagedFocusFeature(this.getFocusableElement(),{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this)}))}onTabKeyDown(e){if(e.defaultPrevented)return;const{focusService:t,sideBarButtonsComp:i}=this,r=this.getGui(),n=i.getGui(),s=this.gos.getActiveDomElement(),o=r.querySelector(".ag-tool-panel-wrapper:not(.ag-hidden)"),a=e.target;if(!o)return;if(n.contains(s))return void(t.focusInto(o,e.shiftKey)&&e.preventDefault());if(!e.shiftKey)return;let l=null;o.contains(s)?l=this.focusService.findNextFocusableElement(o,void 0,!0):t.isTargetUnderManagedComponent(o,a)&&e.shiftKey&&(l=this.focusService.findFocusableElementBeforeTabGuard(o,a)),l||(l=n.querySelector(".ag-selected button")),l&&l!==e.target&&(e.preventDefault(),l.focus())}handleKeyDown(e){const t=this.gos.getActiveDomElement();if(!this.sideBarButtonsComp.getGui().contains(t))return;const i=this.sideBarButtonsComp.getGui(),r=Array.prototype.slice.call(i.querySelectorAll(".ag-side-button")),n=r.findIndex(e=>e.contains(t));let s=null;switch(e.key){case Ec.KeyCode.LEFT:case Ec.KeyCode.UP:s=Math.max(0,n-1);break;case Ec.KeyCode.RIGHT:case Ec.KeyCode.DOWN:s=Math.min(n+1,r.length-1)}if(null===s)return;const o=r[s].querySelector("button");o&&(o.focus(),e.preventDefault())}onToolPanelButtonClicked(e){const t=e.toolPanelId;this.openedItem()===t?this.openToolPanel(void 0,"sideBarButtonClicked"):this.openToolPanel(t,"sideBarButtonClicked")}clearDownUi(){this.sideBarButtonsComp.clearButtons(),this.destroyToolPanelWrappers()}setSideBarDef({sideBarDef:e,sideBarState:t,existingToolPanelWrappers:i}){if(this.setDisplayed(!1),this.sideBar=e,this.sideBar&&this.sideBar.toolPanels){const e=this.sideBar.toolPanels;if(this.createToolPanelsAndSideButtons(e,t,i),!this.toolPanelWrappers.length)return;const r=t?t.visible:!this.sideBar.hiddenByDefault;if(this.setDisplayed(r),this.setSideBarPosition(t?t.position:this.sideBar.position),r)if(t){const{openToolPanel:e}=t;e&&this.openToolPanel(e,"sideBarInitializing")}else this.openToolPanel(this.sideBar.defaultToolPanel,"sideBarInitializing")}}getDef(){return this.sideBar}setSideBarPosition(e){e||(e="right"),this.position=e;const t="left"===e,i=t?"right":"left";return this.addOrRemoveCssClass("ag-side-bar-left",t),this.addOrRemoveCssClass("ag-side-bar-right",!t),this.toolPanelWrappers.forEach(e=>{e.setResizerSizerSide(i)}),this.eventService.dispatchEvent({type:Ec.Events.EVENT_SIDE_BAR_UPDATED}),this}setDisplayed(e,t){super.setDisplayed(e,t),this.eventService.dispatchEvent({type:Ec.Events.EVENT_SIDE_BAR_UPDATED})}getState(){const e={};return this.toolPanelWrappers.forEach(t=>{var i,r;e[t.getToolPanelId()]=null==(r=null==(i=t.getToolPanelInstance())?void 0:i.getState)?void 0:r.call(i)}),{visible:this.isDisplayed(),position:this.position,openToolPanel:this.openedItem(),toolPanels:e}}createToolPanelsAndSideButtons(e,t,i){var r;for(const n of e)this.createToolPanelAndSideButton(n,null==(r=null==t?void 0:t.toolPanels)?void 0:r[n.id],null==i?void 0:i[n.id])}validateDef(e){if(null==e.id)return console.warn("AG Grid: please review all your toolPanel components, it seems like at least one of them doesn't have an id"),!1;if("agColumnsToolPanel"===e.toolPanel&&!Ec.ModuleRegistry.__assertRegistered(Ec.ModuleNames.ColumnsToolPanelModule,"Column Tool Panel",this.context.getGridId()))return!1;if("agFiltersToolPanel"===e.toolPanel){if(!Ec.ModuleRegistry.__assertRegistered(Ec.ModuleNames.FiltersToolPanelModule,"Filters Tool Panel",this.context.getGridId()))return!1;if(this.filterManager.isAdvancedFilterEnabled())return Ec._.warnOnce("Advanced Filter does not work with Filters Tool Panel. Filters Tool Panel has been disabled."),!1}return!0}createToolPanelAndSideButton(e,t,i){if(!this.validateDef(e))return;const r=this.sideBarButtonsComp.addButtonComp(e);let n;i?n=i:(n=this.getContext().createBean(new Kc),n.setToolPanelDef(e,{initialState:t,onStateUpdated:()=>this.eventService.dispatchEvent({type:Ec.Events.EVENT_SIDE_BAR_UPDATED})})),n.setDisplayed(!1);const s=n.getGui();this.appendChild(s),this.toolPanelWrappers.push(n),Ec._.setAriaControls(r.getButtonElement(),s)}refresh(){this.toolPanelWrappers.forEach(e=>e.refresh())}openToolPanel(e,t="api"){const i=this.openedItem();i!==e&&(this.toolPanelWrappers.forEach(t=>{const i=e===t.getToolPanelId();t.setDisplayed(i)}),i!==this.openedItem()&&(this.sideBarButtonsComp.setActiveButton(e),this.raiseToolPanelVisibleEvent(e,null!=i?i:void 0,t)))}getToolPanelInstance(e){const t=this.toolPanelWrappers.filter(t=>t.getToolPanelId()===e)[0];if(t)return t.getToolPanelInstance();console.warn(`AG Grid: unable to lookup Tool Panel as invalid key supplied: ${e}`)}raiseToolPanelVisibleEvent(e,t,i){const r=!!e&&!!t;if(t){const e={type:Ec.Events.EVENT_TOOL_PANEL_VISIBLE_CHANGED,source:i,key:t,visible:!1,switchingToolPanel:r};this.eventService.dispatchEvent(e)}if(e){const t={type:Ec.Events.EVENT_TOOL_PANEL_VISIBLE_CHANGED,source:i,key:e,visible:!0,switchingToolPanel:r};this.eventService.dispatchEvent(t)}}close(e="api"){this.openToolPanel(void 0,e)}isToolPanelShowing(){return!!this.openedItem()}openedItem(){let e=null;return this.toolPanelWrappers.forEach(t=>{t.isDisplayed()&&(e=t.getToolPanelId())}),e}onSideBarUpdated(){var e;const t=Wc.parse(this.gos.get("sideBar"));let i={};t&&this.sideBar&&(null==(e=t.toolPanels)||e.forEach(e=>{var t,r;const{id:n}=e;if(!n)return;const s=null==(t=this.sideBar.toolPanels)?void 0:t.find(e=>e.id===n);if(!s||e.toolPanel!==s.toolPanel)return;const o=this.toolPanelWrappers.find(e=>e.getToolPanelId()===n);if(!o)return;const a=this.gos.addGridCommonParams((l=((e,t)=>{for(var i in t||(t={}))Nc.call(t,i)&&Fc(e,i,t[i]);if(Lc)for(var i of Lc(t))Oc.call(t,i)&&Fc(e,i,t[i]);return e})({},null!=(r=e.toolPanelParams)?r:{}),xc(l,Ic({onStateUpdated:()=>this.eventService.dispatchEvent({type:Ec.Events.EVENT_SIDE_BAR_UPDATED})}))));var l;!0===o.getToolPanelInstance().refresh(a)&&(this.toolPanelWrappers=this.toolPanelWrappers.filter(e=>e!==o),Ec._.removeFromParent(o.getGui()),i[n]=o)})),this.clearDownUi(),this.setSideBarDef({sideBarDef:t,existingToolPanelWrappers:i})}destroyToolPanelWrappers(){this.toolPanelWrappers.forEach(e=>{Ec._.removeFromParent(e.getGui()),this.destroyBean(e)}),this.toolPanelWrappers.length=0}destroy(){this.destroyToolPanelWrappers(),super.destroy()}};$c.TEMPLATE='<div class="ag-side-bar ag-unselectable">\n            <ag-side-bar-buttons ref="sideBarButtons"></ag-side-bar-buttons>\n        </div>',kc([(0,Ec.Autowired)("focusService")],$c.prototype,"focusService",2),kc([(0,Ec.Autowired)("filterManager")],$c.prototype,"filterManager",2),kc([(0,Ec.Autowired)("sideBarService")],$c.prototype,"sideBarService",2),kc([(0,Ec.RefSelector)("sideBarButtons")],$c.prototype,"sideBarButtonsComp",2),kc([Ec.PostConstruct],$c.prototype,"postConstruct",1);var qc=$c,Yc=class extends Rc.BeanStub{constructor(){super(...arguments),this.isColGroupDef=e=>e&&void 0!==e.children,this.getId=e=>this.isColGroupDef(e)?e.groupId:e.colId}createColumnTree(e){const t=[],i=(e,r)=>{if(this.isColGroupDef(e)){const t=e,n=void 0!==t.groupId?t.groupId:t.headerName,s=new Rc.ProvidedColumnGroup(t,n,!1,r),o=[];return t.children.forEach(e=>{const t=i(e,r+1);t&&o.push(t)}),s.setChildren(o),s}{const i=e,r=i.colId?i.colId:i.field,n=this.columnModel.getPrimaryColumn(r);return n||t.push(i),n}},r=[];return e.forEach(e=>{const t=i(e,0);t&&r.push(t)}),t.length>0&&console.warn("AG Grid: unable to find grid columns for the supplied colDef(s):",t),r}syncLayoutWithGrid(e){const t=this.getLeafPathTrees();e(this.mergeLeafPathTrees(t))}getLeafPathTrees(){const e=(t,i)=>{let r;if(t instanceof Rc.ProvidedColumnGroup)if(t.isPadding())r=i;else{const e=Object.assign({},t.getColGroupDef());e.groupId=t.getGroupId(),e.children=[i],r=e}else{const e=Object.assign({},t.getColDef());e.colId=t.getColId(),r=e}const n=t.getOriginalParent();return n?e(n,r):r};return this.columnModel.getAllGridColumns().filter(e=>{const t=e.getColDef();return e.isPrimary()&&!t.showRowGroup}).map(t=>e(t,t.getColDef()))}mergeLeafPathTrees(e){const t=(e,t)=>this.isColGroupDef(e)&&this.isColGroupDef(t)&&this.getId(e)===this.getId(t),i=(e,t)=>{if(!this.isColGroupDef(t))return e;const r=e,n=t;return n.children&&n.groupId&&this.addChildrenToGroup(r,n.groupId,n.children[0])||n.children.forEach(e=>i(r,e)),r},r=[];for(let n=1;n<=e.length;n++){const s=e[n-1],o=e[n];t(s,o)?e[n]=i(s,o):r.push(s)}return r}addChildrenToGroup(e,t,i){if(!this.isColGroupDef(e))return!0;const r=e,n=i;if(((e,t)=>{const i=e.children.map(this.getId),r=Rc._.includes(i,this.getId(t)),n=Rc._.last(e.children),s=n&&this.getId(n)!==this.getId(t);return r&&s})(r,n))return r.children.push(n),!0;if(r.groupId===t){const e=r.children.map(this.getId);if(!Rc._.includes(e,this.getId(n)))return r.children.push(n),!0}return r.children.forEach(e=>this.addChildrenToGroup(e,t,i)),!1}};kc([(0,Rc.Autowired)("columnModel")],Yc.prototype,"columnModel",2),Yc=kc([(0,Rc.Bean)("toolPanelColDefService")],Yc);var Qc=class extends _c.BeanStub{registerSideBarComp(e){this.sideBarComp=e}getSideBarComp(){return this.sideBarComp}};Qc=kc([(0,_c.Bean)("sideBarService")],Qc);var Xc={version:"31.3.4",moduleName:Sc.ModuleNames.SideBarModule,beans:[Yc,Qc],agStackComponents:[{componentName:"AgHorizontalResize",componentClass:Gc},{componentName:"AgSideBar",componentClass:qc},{componentName:"AgSideBarButtons",componentClass:zc}],dependantModules:[_]},Zc=i(98092),Jc=Object.defineProperty,eu=Object.getOwnPropertyDescriptor,tu=Object.getOwnPropertySymbols,iu=Object.prototype.hasOwnProperty,ru=Object.prototype.propertyIsEnumerable,nu=(e,t,i)=>t in e?Jc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,su=(e,t)=>{for(var i in t||(t={}))iu.call(t,i)&&nu(e,i,t[i]);if(tu)for(var i of tu(t))ru.call(t,i)&&nu(e,i,t[i]);return e},ou=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?eu(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Jc(t,i,s),s},au=class e extends fl.Component{constructor(){super(e.TEMPLATE)}postConstruct(){this.createExpandIcons(),this.addManagedListener(this.eExpand,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eExpand,"keydown",e=>{e.key===fl.KeyCode.SPACE&&(e.preventDefault(),this.onExpandClicked())}),this.addManagedListener(this.eSelect.getInputElement(),"click",this.onSelectClicked.bind(this)),this.addManagedPropertyListener("functionsReadOnly",()=>this.onFunctionsReadOnlyPropChanged()),this.eFilterTextField.setAutoComplete(!1).onValueChange(()=>this.onFilterTextChanged()),this.addManagedListener(this.eFilterTextField.getInputElement(),"keydown",this.onMiniFilterKeyDown.bind(this)),this.addManagedListener(this.eventService,fl.Events.EVENT_NEW_COLUMNS_LOADED,this.showOrHideOptions.bind(this));const e=this.localeService.getLocaleTextFunc();this.eSelect.setInputAriaLabel(e("ariaColumnSelectAll","Toggle Select All Columns")),this.eFilterTextField.setInputAriaLabel(e("ariaFilterColumnsInput","Filter Columns Input")),this.activateTabIndex([this.eExpand])}onFunctionsReadOnlyPropChanged(){const e=this.gos.get("functionsReadOnly");this.eSelect.setReadOnly(e),this.eSelect.addOrRemoveCssClass("ag-column-select-column-readonly",e)}init(e){this.params=e;const t=this.gos.get("functionsReadOnly");this.eSelect.setReadOnly(t),this.eSelect.addOrRemoveCssClass("ag-column-select-column-readonly",t),this.columnModel.isReady()&&this.showOrHideOptions()}createExpandIcons(){this.eExpand.appendChild(this.eExpandChecked=fl._.createIconNoSpan("columnSelectOpen",this.gos)),this.eExpand.appendChild(this.eExpandUnchecked=fl._.createIconNoSpan("columnSelectClosed",this.gos)),this.eExpand.appendChild(this.eExpandIndeterminate=fl._.createIconNoSpan("columnSelectIndeterminate",this.gos)),this.setExpandState(0)}showOrHideOptions(){const e=!this.params.suppressColumnFilter,t=!this.params.suppressColumnSelectAll,i=!this.params.suppressColumnExpandAll,r=this.columnModel.isPrimaryColumnGroupsPresent(),n=this.localeService.getLocaleTextFunc();this.eFilterTextField.setInputPlaceholder(n("searchOoo","Search...")),fl._.setDisplayed(this.eFilterTextField.getGui(),e),fl._.setDisplayed(this.eSelect.getGui(),t),fl._.setDisplayed(this.eExpand,i&&r)}onFilterTextChanged(){this.onFilterTextChangedDebounced||(this.onFilterTextChangedDebounced=fl._.debounce(()=>{const e=this.eFilterTextField.getValue();this.dispatchEvent({type:"filterChanged",filterText:e})},e.DEBOUNCE_DELAY)),this.onFilterTextChangedDebounced()}onMiniFilterKeyDown(t){t.key===fl.KeyCode.ENTER&&setTimeout(()=>this.onSelectClicked(),e.DEBOUNCE_DELAY)}onSelectClicked(){this.dispatchEvent({type:this.selectState?"unselectAll":"selectAll"})}onExpandClicked(){this.dispatchEvent({type:0===this.expandState?"collapseAll":"expandAll"})}setExpandState(e){this.expandState=e,fl._.setDisplayed(this.eExpandChecked,0===this.expandState),fl._.setDisplayed(this.eExpandUnchecked,1===this.expandState),fl._.setDisplayed(this.eExpandIndeterminate,2===this.expandState)}setSelectionState(e){this.selectState=e,this.eSelect.setValue(this.selectState)}};au.DEBOUNCE_DELAY=300,au.TEMPLATE='<div class="ag-column-select-header" role="presentation">\n            <div ref="eExpand" class="ag-column-select-header-icon"></div>\n            <ag-checkbox ref="eSelect" class="ag-column-select-header-checkbox"></ag-checkbox>\n            <ag-input-text-field class="ag-column-select-header-filter-wrapper" ref="eFilterTextField"></ag-input-text-field>\n        </div>',ou([(0,fl.Autowired)("columnModel")],au.prototype,"columnModel",2),ou([(0,fl.RefSelector)("eExpand")],au.prototype,"eExpand",2),ou([(0,fl.RefSelector)("eSelect")],au.prototype,"eSelect",2),ou([(0,fl.RefSelector)("eFilterTextField")],au.prototype,"eFilterTextField",2),ou([fl.PostConstruct],au.prototype,"postConstruct",1);var lu=au,cu=class e{constructor(e,t,i,r=!1,n){this.eventService=new yl.EventService,this.displayName=e,this.dept=i,this.group=r,r?(this.columnGroup=t,this.expanded=n,this.children=[]):this.column=t}isGroup(){return this.group}getDisplayName(){return this.displayName}getColumnGroup(){return this.columnGroup}getColumn(){return this.column}getDept(){return this.dept}isExpanded(){return!!this.expanded}getChildren(){return this.children}isPassesFilter(){return this.passesFilter}setExpanded(t){t!==this.expanded&&(this.expanded=t,this.eventService.dispatchEvent({type:e.EVENT_EXPANDED_CHANGED}))}setPassesFilter(e){this.passesFilter=e}addEventListener(e,t){this.eventService.addEventListener(e,t)}removeEventListener(e,t){this.eventService.removeEventListener(e,t)}};cu.EVENT_EXPANDED_CHANGED="expandedChanged";var uu=cu,hu=class extends wl.Component{constructor(e,t,i){super('<div class="ag-menu"></div>'),this.column=e,this.mouseEvent=t,this.parentEl=i,this.displayName=null}postConstruct(){if(this.initializeProperties(this.column),this.buildMenuItemMap(),this.column instanceof wl.Column?this.displayName=this.columnModel.getDisplayNameForColumn(this.column,"columnToolPanel"):this.displayName=this.columnModel.getDisplayNameForProvidedColumnGroup(null,this.column,"columnToolPanel"),this.isActive()){this.mouseEvent.preventDefault();const e=this.getMappedMenuItems();if(0===e.length)return;this.displayContextMenu(e)}}initializeProperties(e){e instanceof wl.ProvidedColumnGroup?this.columns=e.getLeafColumns():this.columns=[e],this.allowGrouping=this.columns.some(e=>e.isPrimary()&&e.isAllowRowGroup()),this.allowValues=this.columns.some(e=>e.isPrimary()&&e.isAllowValue()),this.allowPivoting=this.columnModel.isPivotMode()&&this.columns.some(e=>e.isPrimary()&&e.isAllowPivot())}buildMenuItemMap(){const e=this.localeService.getLocaleTextFunc();this.menuItemMap=new Map,this.menuItemMap.set("rowGroup",{allowedFunction:e=>e.isPrimary()&&e.isAllowRowGroup()&&!this.columnModel.isColumnGroupingLocked(e),activeFunction:e=>e.isRowGroupActive(),activateLabel:()=>`${e("groupBy","Group by")} ${this.displayName}`,deactivateLabel:()=>`${e("ungroupBy","Un-Group by")} ${this.displayName}`,activateFunction:()=>{const e=this.columnModel.getRowGroupColumns();this.columnModel.setRowGroupColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getRowGroupColumns();this.columnModel.setRowGroupColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"menuAddRowGroup",removeIcon:"menuRemoveRowGroup"}),this.menuItemMap.set("value",{allowedFunction:e=>e.isPrimary()&&e.isAllowValue(),activeFunction:e=>e.isValueActive(),activateLabel:()=>e("addToValues",`Add ${this.displayName} to values`,[this.displayName]),deactivateLabel:()=>e("removeFromValues",`Remove ${this.displayName} from values`,[this.displayName]),activateFunction:()=>{const e=this.columnModel.getValueColumns();this.columnModel.setValueColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getValueColumns();this.columnModel.setValueColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"valuePanel",removeIcon:"valuePanel"}),this.menuItemMap.set("pivot",{allowedFunction:e=>this.columnModel.isPivotMode()&&e.isPrimary()&&e.isAllowPivot(),activeFunction:e=>e.isPivotActive(),activateLabel:()=>e("addToLabels",`Add ${this.displayName} to labels`,[this.displayName]),deactivateLabel:()=>e("removeFromLabels",`Remove ${this.displayName} from labels`,[this.displayName]),activateFunction:()=>{const e=this.columnModel.getPivotColumns();this.columnModel.setPivotColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getPivotColumns();this.columnModel.setPivotColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"pivotPanel",removeIcon:"pivotPanel"})}addColumnsToList(e){return[...e].concat(this.columns.filter(t=>-1===e.indexOf(t)))}removeColumnsFromList(e){return e.filter(e=>-1===this.columns.indexOf(e))}displayContextMenu(e){const t=this.getGui(),i=this.createBean(new wl.AgMenuList),r=this.localeService.getLocaleTextFunc();let n=()=>{};t.appendChild(i.getGui()),i.addMenuItems(e),i.addManagedListener(i,wl.AgMenuItemComponent.EVENT_CLOSE_MENU,()=>{this.parentEl.focus(),n()});const s=this.popupService.addPopup({modal:!0,eChild:t,closeOnEsc:!0,afterGuiAttached:()=>this.focusService.focusInto(i.getGui()),ariaLabel:r("ariaLabelContextMenu","Context Menu"),closedCallback:e=>{e instanceof KeyboardEvent&&this.parentEl.focus(),this.destroyBean(i)}});s&&(n=s.hideFunc),this.popupService.positionPopupUnderMouseEvent({type:"columnContextMenu",mouseEvent:this.mouseEvent,ePopup:t})}isActive(){return this.allowGrouping||this.allowValues||this.allowPivoting}getMappedMenuItems(){const e=[];for(const t of this.menuItemMap.values()){const i=this.columns.some(e=>t.allowedFunction(e)&&!t.activeFunction(e)),r=this.columns.some(e=>t.allowedFunction(e)&&t.activeFunction(e));i&&e.push({name:t.activateLabel(this.displayName),icon:wl._.createIconNoSpan(t.addIcon,this.gos,null),action:()=>t.activateFunction()}),r&&e.push({name:t.deactivateLabel(this.displayName),icon:wl._.createIconNoSpan(t.removeIcon,this.gos,null),action:()=>t.deActivateFunction()})}return e}};ou([(0,wl.Autowired)("columnModel")],hu.prototype,"columnModel",2),ou([(0,wl.Autowired)("popupService")],hu.prototype,"popupService",2),ou([(0,wl.Autowired)("focusService")],hu.prototype,"focusService",2),ou([wl.PostConstruct],hu.prototype,"postConstruct",1);var du=class e extends Cl.Component{constructor(e,t,i,r){super(),this.modelItem=e,this.allowDragging=t,this.eventType=i,this.focusWrapper=r,this.processingColumnStateChange=!1,this.modelItem=e,this.columnGroup=e.getColumnGroup(),this.columnDept=e.getDept(),this.displayName=e.getDisplayName(),this.allowDragging=t}init(){this.setTemplate(e.TEMPLATE),this.eDragHandle=Cl._.createIconNoSpan("columnDrag",this.gos),this.eDragHandle.classList.add("ag-drag-handle","ag-column-select-column-group-drag-handle");const t=this.cbSelect.getGui(),i=this.cbSelect.getInputElement();t.insertAdjacentElement("afterend",this.eDragHandle),i.setAttribute("tabindex","-1"),this.eLabel.innerHTML=this.displayName?this.displayName:"",this.setupExpandContract(),this.addCssClass("ag-column-select-indent-"+this.columnDept),this.addManagedListener(this.eventService,Cl.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.eLabel,"click",this.onLabelClicked.bind(this)),this.addManagedListener(this.cbSelect,Cl.Events.EVENT_FIELD_VALUE_CHANGED,this.onCheckboxChanged.bind(this)),this.addManagedListener(this.modelItem,uu.EVENT_EXPANDED_CHANGED,this.onExpandChanged.bind(this)),this.addManagedListener(this.focusWrapper,"keydown",this.handleKeyDown.bind(this)),this.addManagedListener(this.focusWrapper,"contextmenu",this.onContextMenu.bind(this)),this.setOpenClosedIcons(),this.setupDragging(),this.onColumnStateChanged(),this.addVisibilityListenersToAllChildren(),this.refreshAriaExpanded(),this.refreshAriaLabel(),this.setupTooltip(),Cl.CssClassApplier.getToolPanelClassesFromColDef(this.columnGroup.getColGroupDef(),this.gos,null,this.columnGroup).forEach(e=>this.addOrRemoveCssClass(e,!0))}getColumns(){return this.columnGroup.getLeafColumns()}setupTooltip(){const e=this.columnGroup.getColGroupDef();if(!e)return;let t;"whenTruncated"===this.gos.get("tooltipShowMode")&&(t=()=>this.eLabel.scrollWidth>this.eLabel.clientWidth);const i=()=>{const i=e.headerTooltip;this.setTooltip({newTooltipText:i,location:"columnToolPanelColumnGroup",shouldDisplayTooltip:t})};i(),this.addManagedListener(this.eventService,Cl.Events.EVENT_NEW_COLUMNS_LOADED,i)}getTooltipParams(){const e=super.getTooltipParams();return e.location="columnToolPanelColumnGroup",e}handleKeyDown(e){switch(e.key){case Cl.KeyCode.LEFT:e.preventDefault(),this.modelItem.setExpanded(!1);break;case Cl.KeyCode.RIGHT:e.preventDefault(),this.modelItem.setExpanded(!0);break;case Cl.KeyCode.SPACE:e.preventDefault(),this.isSelectable()&&this.onSelectAllChanged(!this.isSelected())}}onContextMenu(e){const{columnGroup:t,gos:i}=this;if(i.get("functionsReadOnly"))return;const r=this.createBean(new hu(t,e,this.focusWrapper));this.addDestroyFunc(()=>{r.isAlive()&&this.destroyBean(r)})}addVisibilityListenersToAllChildren(){this.columnGroup.getLeafColumns().forEach(e=>{this.addManagedListener(e,Cl.Column.EVENT_VISIBLE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,Cl.Column.EVENT_VALUE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,Cl.Column.EVENT_PIVOT_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,Cl.Column.EVENT_ROW_GROUP_CHANGED,this.onColumnStateChanged.bind(this))})}setupDragging(){if(!this.allowDragging)return void Cl._.setDisplayed(this.eDragHandle,!1);let e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:Cl.DragSourceType.ToolPanel,eElement:this.eDragHandle,dragItemName:this.displayName,getDefaultIconName:()=>e?Cl.DragAndDropService.ICON_HIDE:Cl.DragAndDropService.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(),onDragStarted:()=>{e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:Cl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_START,column:this.columnGroup};this.eventService.dispatchEvent(t)},onDragStopped:()=>{const e={type:Cl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_END};this.eventService.dispatchEvent(e)},onGridEnter:t=>{e&&this.modelItemUtils.updateColumns({columns:this.columnGroup.getLeafColumns(),visibleState:null==t?void 0:t.visibleState,pivotState:null==t?void 0:t.pivotState,eventType:this.eventType})},onGridExit:()=>{e&&this.onChangeCommon(!1)}};this.dragAndDropService.addDragSource(t,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(t))}createDragItem(){const e=this.columnGroup.getLeafColumns(),t={},i={};return e.forEach(e=>{const r=e.getId();t[r]=e.isVisible(),i[r]=this.modelItemUtils.createPivotState(e)}),{columns:e,visibleState:t,pivotState:i}}setupExpandContract(){this.eGroupClosedIcon.appendChild(Cl._.createIcon("columnSelectClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild(Cl._.createIcon("columnSelectOpen",this.gos,null)),this.addManagedListener(this.eGroupClosedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.addManagedListener(this.eGroupOpenedIcon,"click",this.onExpandOrContractClicked.bind(this));const e=new Cl.TouchListener(this.eColumnGroupIcons,!0);this.addManagedListener(e,Cl.TouchListener.EVENT_TAP,this.onExpandOrContractClicked.bind(this)),this.addDestroyFunc(e.destroy.bind(e))}onLabelClicked(){const e=!this.cbSelect.getValue();this.onChangeCommon(e)}onCheckboxChanged(e){this.onChangeCommon(e.selected)}getVisibleLeafColumns(){const e=[],t=i=>{i.forEach(i=>{i.isPassesFilter()&&(i.isGroup()?t(i.getChildren()):e.push(i.getColumn()))})};return t(this.modelItem.getChildren()),e}onChangeCommon(e){this.refreshAriaLabel(),this.processingColumnStateChange||this.modelItemUtils.selectAllChildren(this.modelItem.getChildren(),e,this.eventType)}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumnGroup","Column Group"),i=this.cbSelect.getValue(),r=void 0===i?e("ariaIndeterminate","indeterminate"):i?e("ariaVisible","visible"):e("ariaHidden","hidden"),n=e("ariaToggleVisibility","Press SPACE to toggle visibility");Cl._.setAriaLabel(this.focusWrapper,`${this.displayName} ${t}`),this.cbSelect.setInputAriaLabel(`${n} (${r})`),Cl._.setAriaDescribedBy(this.focusWrapper,this.cbSelect.getInputElement().id)}onColumnStateChanged(){const e=this.workOutSelectedValue(),t=this.workOutReadOnlyValue();this.processingColumnStateChange=!0,this.cbSelect.setValue(e),this.cbSelect.setReadOnly(t),this.addOrRemoveCssClass("ag-column-select-column-group-readonly",t),this.processingColumnStateChange=!1}workOutSelectedValue(){const e=this.columnModel.isPivotMode(),t=this.getVisibleLeafColumns();let i=0,r=0;if(t.forEach(t=>{!e&&t.getColDef().lockVisible||(this.isColumnChecked(t,e)?i++:r++)}),!(i>0&&r>0))return i>0}workOutReadOnlyValue(){const e=this.columnModel.isPivotMode();let t=0;return this.columnGroup.getLeafColumns().forEach(i=>{e?i.isAnyFunctionAllowed()&&t++:i.getColDef().lockVisible||t++}),0===t}isColumnChecked(e,t){if(t){const t=e.isPivotActive(),i=e.isRowGroupActive(),r=e.isValueActive();return t||i||r}return e.isVisible()}onExpandOrContractClicked(){const e=this.modelItem.isExpanded();this.modelItem.setExpanded(!e)}onExpandChanged(){this.setOpenClosedIcons(),this.refreshAriaExpanded()}setOpenClosedIcons(){const e=this.modelItem.isExpanded();Cl._.setDisplayed(this.eGroupClosedIcon,!e),Cl._.setDisplayed(this.eGroupOpenedIcon,e)}refreshAriaExpanded(){Cl._.setAriaExpanded(this.focusWrapper,this.modelItem.isExpanded())}getDisplayName(){return this.displayName}onSelectAllChanged(e){const t=this.cbSelect.getValue();!this.cbSelect.isReadOnly()&&(e&&!t||!e&&t)&&this.cbSelect.toggle()}isSelected(){return this.cbSelect.getValue()}isSelectable(){return!this.cbSelect.isReadOnly()}setSelected(e){this.cbSelect.setValue(e,!0)}};du.TEMPLATE='<div class="ag-column-select-column-group" aria-hidden="true">\n            <span class="ag-column-group-icons" ref="eColumnGroupIcons" >\n                <span class="ag-column-group-closed-icon" ref="eGroupClosedIcon"></span>\n                <span class="ag-column-group-opened-icon" ref="eGroupOpenedIcon"></span>\n            </span>\n            <ag-checkbox ref="cbSelect" class="ag-column-select-checkbox"></ag-checkbox>\n            <span class="ag-column-select-column-label" ref="eLabel"></span>\n        </div>',ou([(0,Cl.Autowired)("columnModel")],du.prototype,"columnModel",2),ou([(0,Cl.Autowired)("dragAndDropService")],du.prototype,"dragAndDropService",2),ou([(0,Cl.Autowired)("modelItemUtils")],du.prototype,"modelItemUtils",2),ou([(0,Cl.RefSelector)("cbSelect")],du.prototype,"cbSelect",2),ou([(0,Cl.RefSelector)("eLabel")],du.prototype,"eLabel",2),ou([(0,Cl.RefSelector)("eGroupOpenedIcon")],du.prototype,"eGroupOpenedIcon",2),ou([(0,Cl.RefSelector)("eGroupClosedIcon")],du.prototype,"eGroupClosedIcon",2),ou([(0,Cl.RefSelector)("eColumnGroupIcons")],du.prototype,"eColumnGroupIcons",2),ou([Cl.PostConstruct],du.prototype,"init",1);var pu=du,gu=class extends vl.BeanStub{constructor(e,t){super(),this.comp=e,this.virtualList=t}postConstruct(){this.createManagedBean(new vl.VirtualListDragFeature(this.comp,this.virtualList,{dragSourceType:vl.DragSourceType.ToolPanel,listItemDragStartEvent:vl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_START,listItemDragEndEvent:vl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_END,eventSource:this.eventService,getCurrentDragValue:e=>this.getCurrentDragValue(e),isMoveBlocked:e=>this.isMoveBlocked(e),getNumRows:e=>e.getDisplayedColsList().length,moveItem:(e,t)=>this.moveItem(e,t)}))}getCurrentDragValue(e){return e.column}isMoveBlocked(e){return!!this.gos.get("suppressMovableColumns")||!!this.getCurrentColumns(e).find(e=>{const t=e.getColDef();return!!t.suppressMovable||!!t.lockPosition})}moveItem(e,t){const i=this.getTargetIndex(e,t),r=this.getCurrentColumns(e);null!=i&&this.columnModel.moveColumns(r,i,"toolPanelUi")}getMoveDiff(e,t){const i=this.columnModel.getAllGridColumns(),r=this.getCurrentColumns(e),n=r[0],s=r.length;return i.indexOf(n)<t?s:0}getCurrentColumns(e){return e instanceof vl.ProvidedColumnGroup?e.getLeafColumns():[e]}getTargetIndex(e,t){if(!t)return null;const i=t.component;let r,n="top"===t.position;if(i instanceof pu?(r=i.getColumns()[0],n=!0):r=i.getColumn(),-1!==this.getCurrentColumns(e).indexOf(r))return null;const s=this.columnModel.getAllGridColumns().indexOf(r),o=n?s:s+1;return o-this.getMoveDiff(e,o)}};ou([(0,vl.Autowired)("columnModel")],gu.prototype,"columnModel",2),ou([vl.PostConstruct],gu.prototype,"postConstruct",1);var fu=class e extends Sl.Component{constructor(e,t,i,r){super(),this.allowDragging=t,this.groupsExist=i,this.focusWrapper=r,this.processingColumnStateChange=!1,this.column=e.getColumn(),this.columnDept=e.getDept(),this.displayName=e.getDisplayName()}init(){this.setTemplate(e.TEMPLATE),this.eDragHandle=Sl._.createIconNoSpan("columnDrag",this.gos),this.eDragHandle.classList.add("ag-drag-handle","ag-column-select-column-drag-handle");const t=this.cbSelect.getGui(),i=this.cbSelect.getInputElement();t.insertAdjacentElement("afterend",this.eDragHandle),i.setAttribute("tabindex","-1");const r=Sl._.escapeString(this.displayName);this.eLabel.innerHTML=r;const n=this.columnDept;this.groupsExist&&this.addCssClass("ag-column-select-add-group-indent"),this.addCssClass(`ag-column-select-indent-${n}`),this.setupDragging(),this.addManagedListener(this.eventService,Sl.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,Sl.Column.EVENT_VALUE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,Sl.Column.EVENT_PIVOT_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,Sl.Column.EVENT_ROW_GROUP_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,Sl.Column.EVENT_VISIBLE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.focusWrapper,"keydown",this.handleKeyDown.bind(this)),this.addManagedListener(this.focusWrapper,"contextmenu",this.onContextMenu.bind(this)),this.addManagedPropertyListener("functionsReadOnly",this.onColumnStateChanged.bind(this)),this.addManagedListener(this.cbSelect,Sl.Events.EVENT_FIELD_VALUE_CHANGED,this.onCheckboxChanged.bind(this)),this.addManagedListener(this.eLabel,"click",this.onLabelClicked.bind(this)),this.onColumnStateChanged(),this.refreshAriaLabel(),this.setupTooltip(),Sl.CssClassApplier.getToolPanelClassesFromColDef(this.column.getColDef(),this.gos,this.column,null).forEach(e=>this.addOrRemoveCssClass(e,!0))}getColumn(){return this.column}setupTooltip(){let e;"whenTruncated"===this.gos.get("tooltipShowMode")&&(e=()=>this.eLabel.scrollWidth>this.eLabel.clientWidth);const t=()=>{const t=this.column.getColDef().headerTooltip;this.setTooltip({newTooltipText:t,location:"columnToolPanelColumn",shouldDisplayTooltip:e})};t(),this.addManagedListener(this.eventService,Sl.Events.EVENT_NEW_COLUMNS_LOADED,t)}getTooltipParams(){const e=super.getTooltipParams();return e.location="columnToolPanelColumn",e.colDef=this.column.getColDef(),e}onContextMenu(e){const{column:t,gos:i}=this;if(i.get("functionsReadOnly"))return;const r=this.createBean(new hu(t,e,this.focusWrapper));this.addDestroyFunc(()=>{r.isAlive()&&this.destroyBean(r)})}handleKeyDown(e){e.key===Sl.KeyCode.SPACE&&(e.preventDefault(),this.isSelectable()&&this.onSelectAllChanged(!this.isSelected()))}onLabelClicked(){if(this.gos.get("functionsReadOnly"))return;const e=!this.cbSelect.getValue();this.onChangeCommon(e)}onCheckboxChanged(e){this.onChangeCommon(e.selected)}onChangeCommon(e){this.cbSelect.isReadOnly()||(this.refreshAriaLabel(),this.processingColumnStateChange||this.modelItemUtils.setColumn(this.column,e,"toolPanelUi"))}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumn","Column"),i=this.cbSelect.getValue()?e("ariaVisible","visible"):e("ariaHidden","hidden"),r=e("ariaToggleVisibility","Press SPACE to toggle visibility");Sl._.setAriaLabel(this.focusWrapper,`${this.displayName} ${t}`),this.cbSelect.setInputAriaLabel(`${r} (${i})`),Sl._.setAriaDescribedBy(this.focusWrapper,this.cbSelect.getInputElement().id)}setupDragging(){if(!this.allowDragging)return void Sl._.setDisplayed(this.eDragHandle,!1);let e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:Sl.DragSourceType.ToolPanel,eElement:this.eDragHandle,dragItemName:this.displayName,getDefaultIconName:()=>e?Sl.DragAndDropService.ICON_HIDE:Sl.DragAndDropService.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(),onDragStarted:()=>{e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:Sl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_START,column:this.column};this.eventService.dispatchEvent(t)},onDragStopped:()=>{const e={type:Sl.Events.EVENT_COLUMN_PANEL_ITEM_DRAG_END};this.eventService.dispatchEvent(e)},onGridEnter:t=>{e&&this.modelItemUtils.updateColumns({columns:[this.column],visibleState:null==t?void 0:t.visibleState,pivotState:null==t?void 0:t.pivotState,eventType:"toolPanelUi"})},onGridExit:()=>{e&&this.onChangeCommon(!1)}};this.dragAndDropService.addDragSource(t,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(t))}createDragItem(){const e=this.column.getColId(),t={[e]:this.column.isVisible()},i={[e]:this.modelItemUtils.createPivotState(this.column)};return{columns:[this.column],visibleState:t,pivotState:i}}onColumnStateChanged(){this.processingColumnStateChange=!0;const e=this.columnModel.isPivotMode();if(e){const e=this.column.isAnyFunctionActive();this.cbSelect.setValue(e)}else this.cbSelect.setValue(this.column.isVisible());let t=!0,i=!0;if(e){const e=this.gos.get("functionsReadOnly"),r=!this.column.isAnyFunctionAllowed();t=!e&&!r,i=t}else{const{enableRowGroup:e,enableValue:r,lockPosition:n,suppressMovable:s,lockVisible:o}=this.column.getColDef();t=!o,i=!!e||!!r||!(n||s)}this.cbSelect.setReadOnly(!t),this.eDragHandle.classList.toggle("ag-column-select-column-readonly",!i),this.addOrRemoveCssClass("ag-column-select-column-readonly",!i&&!t);const r=e&&this.gos.get("functionsPassive");this.cbSelect.setPassive(r),this.processingColumnStateChange=!1}getDisplayName(){return this.displayName}onSelectAllChanged(e){e!==this.cbSelect.getValue()&&(this.cbSelect.isReadOnly()||this.cbSelect.toggle())}isSelected(){return this.cbSelect.getValue()}isSelectable(){return!this.cbSelect.isReadOnly()}isExpandable(){return!1}setExpanded(e){console.warn("AG Grid: can not expand a column item that does not represent a column group header")}};fu.TEMPLATE='<div class="ag-column-select-column" aria-hidden="true">\n            <ag-checkbox ref="cbSelect" class="ag-column-select-checkbox"></ag-checkbox>\n            <span class="ag-column-select-column-label" ref="eLabel"></span>\n        </div>',ou([(0,Sl.Autowired)("columnModel")],fu.prototype,"columnModel",2),ou([(0,Sl.Autowired)("dragAndDropService")],fu.prototype,"dragAndDropService",2),ou([(0,Sl.Autowired)("modelItemUtils")],fu.prototype,"modelItemUtils",2),ou([(0,Sl.RefSelector)("eLabel")],fu.prototype,"eLabel",2),ou([(0,Sl.RefSelector)("cbSelect")],fu.prototype,"cbSelect",2),ou([Sl.PostConstruct],fu.prototype,"init",1);var mu=fu,vu=class{constructor(e){this.items=e}getRowCount(){return this.items.length}getRow(e){return this.items[e]}},Cu=class e extends ml.Component{constructor(){super(e.TEMPLATE),this.destroyColumnItemFuncs=[],this.hasLoadedInitialState=!1,this.isInitialState=!1}destroyColumnTree(){this.allColsTree=[],this.destroyColumnItemFuncs.forEach(e=>e()),this.destroyColumnItemFuncs=[]}init(e,t,i){this.params=e,this.allowDragging=t,this.eventType=i,this.params.suppressSyncLayoutWithGrid||this.addManagedListener(this.eventService,ml.Events.EVENT_COLUMN_MOVED,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,ml.Events.EVENT_NEW_COLUMNS_LOADED,this.onColumnsChanged.bind(this)),[ml.Events.EVENT_COLUMN_PIVOT_CHANGED,ml.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,ml.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,ml.Events.EVENT_COLUMN_VALUE_CHANGED,ml.Events.EVENT_COLUMN_VISIBLE,ml.Events.EVENT_NEW_COLUMNS_LOADED].forEach(e=>{this.addManagedListener(this.eventService,e,this.fireSelectionChangedEvent.bind(this))}),this.expandGroupsByDefault=!this.params.contractColumnSelection,this.virtualList=this.createManagedBean(new ml.VirtualList({cssIdentifier:"column-select",ariaRole:"tree"})),this.appendChild(this.virtualList.getGui()),this.virtualList.setComponentCreator((e,t)=>(ml._.setAriaLevel(t,e.getDept()+1),this.createComponentFromItem(e,t))),this.columnModel.isReady()&&this.onColumnsChanged(),this.params.suppressColumnMove||this.createManagedBean(new gu(this,this.virtualList))}createComponentFromItem(e,t){if(e.isGroup()){const i=new pu(e,this.allowDragging,this.eventType,t);return this.getContext().createBean(i),i}const i=new mu(e,this.allowDragging,this.groupsExist,t);return this.getContext().createBean(i),i}onColumnsChanged(){this.hasLoadedInitialState||(this.hasLoadedInitialState=!0,this.isInitialState=!!this.params.initialState);const e=this.getExpandedStates(),t=this.columnModel.isPivotMode();this.params.suppressSyncLayoutWithGrid||t?this.buildTreeFromProvidedColumnDefs():this.buildTreeFromWhatGridIsDisplaying(),this.setExpandedStates(e),this.markFilteredColumns(),this.flattenAndFilterModel(),this.isInitialState=!1}getDisplayedColsList(){return this.displayedColsList}getExpandedStates(){const e={};if(this.isInitialState){const{expandedGroupIds:t}=this.params.initialState;return t.forEach(t=>{e[t]=!0}),e}return this.allColsTree?(this.forEachItem(t=>{if(!t.isGroup())return;const i=t.getColumnGroup();i&&(e[i.getId()]=t.isExpanded())}),e):{}}setExpandedStates(e){if(!this.allColsTree)return;const{isInitialState:t}=this;this.forEachItem(i=>{if(!i.isGroup())return;const r=i.getColumnGroup();if(r){const n=e[r.getId()];(null!=n||t)&&i.setExpanded(!!n)}})}buildTreeFromWhatGridIsDisplaying(){this.colDefService.syncLayoutWithGrid(this.setColumnLayout.bind(this))}setColumnLayout(e){const t=this.colDefService.createColumnTree(e);this.buildListModel(t),this.groupsExist=e.some(e=>e&&void 0!==e.children),this.markFilteredColumns(),this.flattenAndFilterModel()}buildTreeFromProvidedColumnDefs(){this.buildListModel(this.columnModel.getPrimaryColumnTree()),this.groupsExist=this.columnModel.isPrimaryColumnGroupsPresent()}buildListModel(e){const t=this.onColumnExpanded.bind(this),i=e=>{e.addEventListener(uu.EVENT_EXPANDED_CHANGED,t);const i=e.removeEventListener.bind(e,uu.EVENT_EXPANDED_CHANGED,t);this.destroyColumnItemFuncs.push(i)},r=(e,t,i)=>{e.forEach(e=>{e instanceof ml.ProvidedColumnGroup?n(e,t,i):s(e,t,i)})},n=(e,t,n)=>{const s=e.getColGroupDef();if(s&&s.suppressColumnsToolPanel)return;if(e.isPadding())return void r(e.getChildren(),t,n);const o=this.columnModel.getDisplayNameForProvidedColumnGroup(null,e,"columnToolPanel"),a=new uu(o,e,t,!0,this.expandGroupsByDefault);n.push(a),i(a),r(e.getChildren(),t+1,a.getChildren())},s=(e,t,i)=>{if(e.getColDef()&&e.getColDef().suppressColumnsToolPanel)return;const r=this.columnModel.getDisplayNameForColumn(e,"columnToolPanel");i.push(new uu(r,e,t))};this.destroyColumnTree(),r(e,0,this.allColsTree)}onColumnExpanded(){this.flattenAndFilterModel()}flattenAndFilterModel(){this.displayedColsList=[];const e=t=>{t.isPassesFilter()&&(this.displayedColsList.push(t),t.isGroup()&&t.isExpanded()&&t.getChildren().forEach(e))};this.allColsTree.forEach(e),this.virtualList.setModel(new vu(this.displayedColsList));const t=this.virtualList.getLastFocusedRow();this.virtualList.refresh(),null!=t&&this.focusRowIfAlive(t),this.notifyListeners(),this.refreshAriaLabel()}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumnPanelList","Column List"),i=e("columns","Columns"),r=this.displayedColsList.length;ml._.setAriaLabel(this.virtualList.getAriaElement(),`${t} ${r} ${i}`)}focusRowIfAlive(e){window.setTimeout(()=>{this.isAlive()&&this.virtualList.focusRow(e)},0)}forEachItem(e){const t=i=>{i.forEach(i=>{e(i),i.isGroup()&&t(i.getChildren())})};this.allColsTree&&t(this.allColsTree)}doSetExpandedAll(e){this.forEachItem(t=>{t.isGroup()&&t.setExpanded(e)})}setGroupsExpanded(e,t){if(!t)return void this.doSetExpandedAll(e);const i=[];this.forEachItem(r=>{if(!r.isGroup())return;const n=r.getColumnGroup().getId();t.indexOf(n)>=0&&(r.setExpanded(e),i.push(n))});const r=t.filter(e=>!ml._.includes(i,e));r.length>0&&console.warn("AG Grid: unable to find group(s) for supplied groupIds:",r)}getExpandState(){let e=0,t=0;return this.forEachItem(i=>{i.isGroup()&&(i.isExpanded()?e++:t++)}),e>0&&t>0?2:t>0?1:0}doSetSelectedAll(e){this.modelItemUtils.selectAllChildren(this.allColsTree,e,this.eventType)}getSelectionState(){let e=0,t=0;const i=this.columnModel.isPivotMode();if(this.forEachItem(r=>{if(r.isGroup())return;if(!r.isPassesFilter())return;const n=r.getColumn(),s=n.getColDef();let o;if(i){if(!n.isAllowPivot()&&!n.isAllowRowGroup()&&!n.isAllowValue())return;o=n.isValueActive()||n.isPivotActive()||n.isRowGroupActive()}else{if(s.lockVisible)return;o=n.isVisible()}o?e++:t++}),!(e>0&&t>0))return!(0===e||t>0)}setFilterText(e){this.filterText=ml._.exists(e)?e.toLowerCase():null,this.markFilteredColumns(),this.flattenAndFilterModel()}markFilteredColumns(){const e=e=>{if(!ml._.exists(this.filterText))return!0;const t=e.getDisplayName();return null==t||-1!==t.toLowerCase().indexOf(this.filterText)},t=(i,r)=>{let n=!1;if(i.isGroup()){const s=e(i);i.getChildren().forEach(e=>{const i=t(e,s||r);i&&(n=i)})}const s=!(!r&&!n)||e(i);return i.setPassesFilter(s),s};this.allColsTree.forEach(e=>t(e,!1))}notifyListeners(){this.fireGroupExpandedEvent(),this.fireSelectionChangedEvent()}fireGroupExpandedEvent(){const e=this.getExpandState();this.dispatchEvent({type:"groupExpanded",state:e})}fireSelectionChangedEvent(){if(!this.allColsTree)return;const e=this.getSelectionState();this.dispatchEvent({type:"selectionChanged",state:e})}getExpandedGroups(){const e=[];return this.allColsTree?(this.forEachItem(t=>{t.isGroup()&&t.isExpanded()&&e.push(t.getColumnGroup().getId())}),e):e}};Cu.TEMPLATE='<div class="ag-column-select-list" role="presentation"></div>',ou([(0,ml.Autowired)("columnModel")],Cu.prototype,"columnModel",2),ou([(0,ml.Autowired)("toolPanelColDefService")],Cu.prototype,"colDefService",2),ou([(0,ml.Autowired)("modelItemUtils")],Cu.prototype,"modelItemUtils",2),ou([ml.PreDestroy],Cu.prototype,"destroyColumnTree",1);var yu=Cu,wu=class extends El.Component{createTemplate(){return'<div class="ag-pivot-mode-panel">\n                <ag-toggle-button ref="cbPivotMode" class="ag-pivot-mode-select"></ag-toggle-button>\n            </div>'}init(){this.setTemplate(this.createTemplate()),this.cbPivotMode.setValue(this.columnModel.isPivotMode());const e=this.localeService.getLocaleTextFunc();this.cbPivotMode.setLabel(e("pivotMode","Pivot Mode")),this.addManagedListener(this.cbPivotMode,El.Events.EVENT_FIELD_VALUE_CHANGED,this.onBtPivotMode.bind(this)),this.addManagedListener(this.eventService,El.Events.EVENT_NEW_COLUMNS_LOADED,this.onPivotModeChanged.bind(this)),this.addManagedListener(this.eventService,El.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onPivotModeChanged.bind(this))}onBtPivotMode(){const e=!!this.cbPivotMode.getValue();if(e!==this.columnModel.isPivotMode()){this.gos.updateGridOptions({options:{pivotMode:e},source:"toolPanelUi"});const{api:t}=this;t&&t.refreshHeader()}}onPivotModeChanged(){const e=this.columnModel.isPivotMode();this.cbPivotMode.setValue(e)}};ou([(0,El.Autowired)("columnModel")],wu.prototype,"columnModel",2),ou([(0,El.Autowired)("gridApi")],wu.prototype,"api",2),ou([(0,El.RefSelector)("cbPivotMode")],wu.prototype,"cbPivotMode",2),ou([El.PreConstruct],wu.prototype,"init",1);var Su=class e extends wc.Component{constructor(){super(e.TEMPLATE)}init(e,t,i){this.allowDragging=e,this.params=t,this.eventType=i,this.primaryColsHeaderPanel.init(this.params);const r=this.params.suppressColumnFilter,n=this.params.suppressColumnSelectAll;this.params.suppressColumnExpandAll&&r&&n&&this.primaryColsHeaderPanel.setDisplayed(!1),this.addManagedListener(this.primaryColsListPanel,"groupExpanded",this.onGroupExpanded.bind(this)),this.addManagedListener(this.primaryColsListPanel,"selectionChanged",this.onSelectionChange.bind(this)),this.primaryColsListPanel.init(this.params,this.allowDragging,this.eventType),this.addManagedListener(this.primaryColsHeaderPanel,"expandAll",this.onExpandAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"collapseAll",this.onCollapseAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"selectAll",this.onSelectAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"unselectAll",this.onUnselectAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"filterChanged",this.onFilterChanged.bind(this)),this.positionableFeature=new wc.PositionableFeature(this.getGui(),{minHeight:100}),this.createManagedBean(this.positionableFeature)}toggleResizable(e){this.positionableFeature.setResizable(!!e&&{bottom:!0})}onExpandAll(){this.primaryColsListPanel.doSetExpandedAll(!0)}onCollapseAll(){this.primaryColsListPanel.doSetExpandedAll(!1)}expandGroups(e){this.primaryColsListPanel.setGroupsExpanded(!0,e)}collapseGroups(e){this.primaryColsListPanel.setGroupsExpanded(!1,e)}setColumnLayout(e){this.primaryColsListPanel.setColumnLayout(e)}onFilterChanged(e){this.primaryColsListPanel.setFilterText(e.filterText)}syncLayoutWithGrid(){this.primaryColsListPanel.onColumnsChanged()}onSelectAll(){this.primaryColsListPanel.doSetSelectedAll(!0)}onUnselectAll(){this.primaryColsListPanel.doSetSelectedAll(!1)}onGroupExpanded(e){this.primaryColsHeaderPanel.setExpandState(e.state),this.params.onStateUpdated()}onSelectionChange(e){this.primaryColsHeaderPanel.setSelectionState(e.state)}getExpandedGroups(){return this.primaryColsListPanel.getExpandedGroups()}};Su.TEMPLATE='<div class="ag-column-select">\n            <ag-primary-cols-header ref="primaryColsHeaderPanel"></ag-primary-cols-header>\n            <ag-primary-cols-list ref="primaryColsListPanel"></ag-primary-cols-list>\n        </div>',ou([(0,wc.RefSelector)("primaryColsHeaderPanel")],Su.prototype,"primaryColsHeaderPanel",2),ou([(0,wc.RefSelector)("primaryColsListPanel")],Su.prototype,"primaryColsListPanel",2);var bu=Su,Eu=class e extends bl.Component{constructor(){super(e.TEMPLATE),this.initialised=!1,this.childDestroyFuncs=[]}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}init(e){const t=this.gos.addGridCommonParams({suppressColumnMove:!1,suppressColumnSelectAll:!1,suppressColumnFilter:!1,suppressColumnExpandAll:!1,contractColumnSelection:!1,suppressPivotMode:!1,suppressRowGroups:!1,suppressValues:!1,suppressPivots:!1,suppressSyncLayoutWithGrid:!1});if(this.params=su(su({},t),e),this.isRowGroupingModuleLoaded()&&!this.params.suppressPivotMode&&(this.pivotModePanel=this.createBean(new wu),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotModePanel)),this.appendChild(this.pivotModePanel)),this.primaryColsPanel=this.createBean(new bu),this.childDestroyFuncs.push(()=>this.destroyBean(this.primaryColsPanel)),this.primaryColsPanel.init(!0,this.params,"toolPanelUi"),this.primaryColsPanel.addCssClass("ag-column-panel-column-select"),this.appendChild(this.primaryColsPanel),this.isRowGroupingModuleLoaded()){this.params.suppressRowGroups||(this.rowGroupDropZonePanel=this.createBean(new hc(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.rowGroupDropZonePanel)),this.appendChild(this.rowGroupDropZonePanel)),this.params.suppressValues||(this.valuesDropZonePanel=this.createBean(new yc(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.valuesDropZonePanel)),this.appendChild(this.valuesDropZonePanel)),this.params.suppressPivots||(this.pivotDropZonePanel=this.createBean(new dc(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotDropZonePanel)),this.appendChild(this.pivotDropZonePanel)),this.setLastVisible();const e=this.addManagedListener(this.eventService,bl.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>{this.resetChildrenHeight(),this.setLastVisible()});this.childDestroyFuncs.push(()=>e())}this.initialised=!0}setPivotModeSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.pivotModePanel?this.pivotModePanel.setDisplayed(e):e&&(this.pivotModePanel=this.createBean(new wu),this.getGui().insertBefore(this.pivotModePanel.getGui(),this.getGui().firstChild),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotModePanel))),this.setLastVisible())}setRowGroupsSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.rowGroupDropZonePanel?this.rowGroupDropZonePanel.setDisplayed(e):e&&(this.rowGroupDropZonePanel=this.createManagedBean(new hc(!1)),this.appendChild(this.rowGroupDropZonePanel)),this.setLastVisible())}setValuesSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.valuesDropZonePanel?this.valuesDropZonePanel.setDisplayed(e):e&&(this.valuesDropZonePanel=this.createManagedBean(new yc(!1)),this.appendChild(this.valuesDropZonePanel)),this.setLastVisible())}setPivotSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.pivotDropZonePanel?this.pivotDropZonePanel.setDisplayed(e):e&&(this.pivotDropZonePanel=this.createManagedBean(new dc(!1)),this.appendChild(this.pivotDropZonePanel),this.pivotDropZonePanel.setDisplayed(e)),this.setLastVisible())}setResizers(){[this.primaryColsPanel,this.rowGroupDropZonePanel,this.valuesDropZonePanel,this.pivotDropZonePanel].forEach(e=>{if(!e)return;const t=e.getGui();e.toggleResizable(!t.classList.contains("ag-last-column-drop")&&!t.classList.contains("ag-hidden"))})}setLastVisible(){const e=this.getGui();Array.prototype.slice.call(e.querySelectorAll(".ag-column-drop")).forEach(e=>e.classList.remove("ag-last-column-drop"));const t=e.querySelectorAll(".ag-column-drop:not(.ag-hidden)"),i=bl._.last(t);i&&i.classList.add("ag-last-column-drop"),this.setResizers()}resetChildrenHeight(){const e=this.getGui().children;for(let t=0;t<e.length;t++){const i=e[t];i.style.removeProperty("height"),i.style.removeProperty("flex")}}isRowGroupingModuleLoaded(){return bl.ModuleRegistry.__assertRegistered(bl.ModuleNames.RowGroupingModule,"Row Grouping",this.context.getGridId())}expandColumnGroups(e){this.primaryColsPanel.expandGroups(e)}collapseColumnGroups(e){this.primaryColsPanel.collapseGroups(e)}setColumnLayout(e){this.primaryColsPanel.setColumnLayout(e)}syncLayoutWithGrid(){this.primaryColsPanel.syncLayoutWithGrid()}destroyChildren(){this.childDestroyFuncs.forEach(e=>e()),this.childDestroyFuncs.length=0,bl._.clearElement(this.getGui())}refresh(e){return this.destroyChildren(),this.init(e),!0}getState(){return{expandedGroupIds:this.primaryColsPanel.getExpandedGroups()}}destroy(){this.destroyChildren(),super.destroy()}};Eu.TEMPLATE='<div class="ag-column-panel"></div>';var Au=Eu,Tu=class{selectAllChildren(e,t,i){const r=this.extractAllLeafColumns(e);this.setAllColumns(r,t,i)}setColumn(e,t,i){this.setAllColumns([e],t,i)}setAllColumns(e,t,i){this.columnModel.isPivotMode()?this.setAllPivot(e,t,i):this.setAllVisible(e,t,i)}extractAllLeafColumns(e){const t=[],i=e=>{e.forEach(e=>{e.isPassesFilter()&&(e.isGroup()?i(e.getChildren()):t.push(e.getColumn()))})};return i(e),t}setAllVisible(e,t,i){const r=[];e.forEach(e=>{e.getColDef().lockVisible||e.isVisible()!=t&&r.push({colId:e.getId(),hide:!t})}),r.length>0&&this.columnModel.applyColumnState({state:r},i)}setAllPivot(e,t,i){this.gos.get("functionsPassive")?this.setAllPivotPassive(e,t):this.setAllPivotActive(e,t,i)}setAllPivotPassive(e,t){const i=this.columnModel.getPivotColumns().slice(),r=this.columnModel.getValueColumns().slice(),n=this.columnModel.getRowGroupColumns().slice();let s=!1,o=!1,a=!1;const l=t?e=>{e.isAnyFunctionActive()||(e.isAllowValue()?(r.push(e),o=!0):e.isAllowRowGroup()?(n.push(e),s=!0):e.isAllowPivot()&&(i.push(e),a=!0))}:e=>{e.isAnyFunctionActive()&&(i.indexOf(e)>=0&&(Zc._.removeFromArray(i,e),s=!0),r.indexOf(e)>=0&&(Zc._.removeFromArray(r,e),o=!0),n.indexOf(e)>=0&&(Zc._.removeFromArray(n,e),a=!0))};if(e.forEach(l),s){const e={type:Zc.Events.EVENT_COLUMN_PIVOT_CHANGE_REQUEST,columns:i};this.eventService.dispatchEvent(e)}if(a){const e={type:Zc.Events.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST,columns:n};this.eventService.dispatchEvent(e)}if(o){const e={type:Zc.Events.EVENT_COLUMN_VALUE_CHANGE_REQUEST,columns:n};this.eventService.dispatchEvent(e)}}setAllPivotActive(e,t,i){const r=[],n=t?e=>{if(!e.isAnyFunctionActive())if(e.isAllowValue()){const t="string"==typeof e.getAggFunc()?e.getAggFunc():this.aggFuncService.getDefaultAggFunc(e);r.push({colId:e.getId(),aggFunc:t})}else e.isAllowRowGroup()?r.push({colId:e.getId(),rowGroup:!0}):e.isAllowPivot()&&r.push({colId:e.getId(),pivot:!0})}:e=>{(e.isPivotActive()||e.isRowGroupActive()||e.isValueActive())&&r.push({colId:e.getId(),pivot:!1,rowGroup:!1,aggFunc:null})};e.forEach(n),r.length>0&&this.columnModel.applyColumnState({state:r},i)}updateColumns(e){const{columns:t,visibleState:i,pivotState:r,eventType:n}=e,s=t.map(e=>{const t=e.getColId();if(this.columnModel.isPivotMode()){const e=null==r?void 0:r[t];return{colId:t,pivot:null==e?void 0:e.pivot,rowGroup:null==e?void 0:e.rowGroup,aggFunc:null==e?void 0:e.aggFunc}}return{colId:t,hide:!(null==i?void 0:i[t])}});this.columnModel.applyColumnState({state:s},n)}createPivotState(e){return{pivot:e.isPivotActive(),rowGroup:e.isRowGroupActive(),aggFunc:e.isValueActive()?e.getAggFunc():void 0}}};ou([(0,Zc.Autowired)("aggFuncService")],Tu.prototype,"aggFuncService",2),ou([(0,Zc.Autowired)("columnModel")],Tu.prototype,"columnModel",2),ou([(0,Zc.Autowired)("gridOptionsService")],Tu.prototype,"gos",2),ou([(0,Zc.Autowired)("eventService")],Tu.prototype,"eventService",2),Tu=ou([(0,Zc.Bean)("modelItemUtils")],Tu);var Mu,Ru,_u,Pu,xu,Du,Iu,Lu,Nu,Ou={version:"31.3.4",moduleName:gl.ModuleNames.ColumnsToolPanelModule,beans:[Tu],agStackComponents:[{componentName:"AgPrimaryColsHeader",componentClass:lu},{componentName:"AgPrimaryColsList",componentClass:yu},{componentName:"AgPrimaryCols",componentClass:bu}],userComponents:[{componentName:"agColumnsToolPanel",componentClass:Au}],dependantModules:[_,Cc,Xc]},Fu=i(98092),ku=i(98092),Gu=i(98092),Vu=i(98092),Hu=i(98092),Bu=i(98092),zu=i(98092),Uu=i(98092),Wu=i(98092),ju=i(98092),Ku=i(98092),$u=i(98092),qu=i(98092),Yu=Object.defineProperty,Qu=Object.defineProperties,Xu=Object.getOwnPropertyDescriptor,Zu=Object.getOwnPropertyDescriptors,Ju=Object.getOwnPropertySymbols,eh=Object.prototype.hasOwnProperty,th=Object.prototype.propertyIsEnumerable,ih=(e,t,i)=>t in e?Yu(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,rh=(e,t)=>{for(var i in t||(t={}))eh.call(t,i)&&ih(e,i,t[i]);if(Ju)for(var i of Ju(t))th.call(t,i)&&ih(e,i,t[i]);return e},nh=(e,t)=>Qu(e,Zu(t)),sh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Xu(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Yu(t,i,s),s},oh={getTemplate(e){const t=(new Date).toJSON();return{name:"cp:coreProperties",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{cp:"http://schemas.openxmlformats.org/package/2006/metadata/core-properties",dc:"http://purl.org/dc/elements/1.1/",dcterms:"http://purl.org/dc/terms/",dcmitype:"http://purl.org/dc/dcmitype/",xsi:"http://www.w3.org/2001/XMLSchema-instance"}}]},children:[{name:"dc:creator",textNode:e},{name:"dc:title",textNode:"Workbook"},{name:"dcterms:created",properties:{rawMap:{"xsi:type":"dcterms:W3CDTF"}},textNode:t},{name:"dcterms:modified",properties:{rawMap:{"xsi:type":"dcterms:W3CDTF"}},textNode:t}]}}},ah={getTemplate(e){const{name:t,ContentType:i,Extension:r,PartName:n}=e;return{name:t,properties:{rawMap:{Extension:r,PartName:n,ContentType:i}}}}},lh={getTemplate(e){const t=new Array(e).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",PartName:`/xl/worksheets/sheet${t+1}.xml`})),i=Fd.worksheetImages.size,r=Fd.worksheetHeaderFooterImages.size,n=Fd.worksheetDataTables.size,s={};Fd.workbookImageIds.forEach(e=>{const t="jpg"===e.type?"jpeg":e.type;s[t]=!0});const o=new Array(i).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.drawing+xml",PartName:`/xl/drawings/drawing${t+1}.xml`})),a=new Array(n).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml",PartName:`/xl/tables/${Fd.getTableNameFromIndex(t)}.xml`})),l=Object.keys(s).map(e=>({name:"Default",ContentType:`image/${e}`,Extension:e}));return r&&l.push({name:"Default",Extension:"vml",ContentType:"application/vnd.openxmlformats-officedocument.vmlDrawing"}),{name:"Types",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/package/2006/content-types"}},children:[...l,{name:"Default",Extension:"rels",ContentType:"application/vnd.openxmlformats-package.relationships+xml"},{name:"Default",ContentType:"application/xml",Extension:"xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml",PartName:"/xl/workbook.xml"},...t,{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.theme+xml",PartName:"/xl/theme/theme1.xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml",PartName:"/xl/styles.xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml",PartName:"/xl/sharedStrings.xml"},...o,...a,{name:"Override",ContentType:"application/vnd.openxmlformats-package.core-properties+xml",PartName:"/docProps/core.xml"}].map(e=>ah.getTemplate(e))}}},ch={0:1,"0.00":2,"#,##0":3,"#,##0.00":4,"0%":9,"0.00%":10,"0.00E+00":11,"# ?/?":12,"# ??/??":13,"mm-dd-yy":14,"d-mmm-yy":15,"d-mmm":16,"mmm-yy":17,"h:mm AM/PM":18,"h:mm:ss AM/PM":19,"h:mm":20,"h:mm:ss":21,"m/d/yy h:mm":22,"#,##0 ;(#,##0)":37,"#,##0 ;[Red](#,##0)":38,"#,##0.00;(#,##0.00)":39,"#,##0.00;[Red](#,##0.00)":40,"mm:ss":45,"[h]:mm:ss":46,"mmss.0":47,"##0.0E+0":48,"@":49},uh=e=>Math.round(96*e/72),hh=e=>Math.ceil(9525*e),dh=(e,t)=>{if(!t)return;let i;return i="number"==typeof t?t:t({rowIndex:e}),r=i,Math.round(72*r/96);var r},ph=(e,t)=>{const i=Vu.XmlFactory.createHeader({encoding:"UTF-8",standalone:"yes"}),r=Vu.XmlFactory.createXml(e);return t?r:`${i}${r}`},gh=e=>{const t=String.fromCharCode,i=Math.floor(e/26),r=e%26;return i&&26!==e?r?i<26?t(65+i-1)+t(65+r-1):gh(i)+t(65+r-1):gh(i-1)+"Z":t(65+e-1)},fh=(e,t)=>({name:`xdr:${e}`,children:[{name:"xdr:col",textNode:t.col.toString()},{name:"xdr:colOff",textNode:t.offsetX.toString()},{name:"xdr:row",textNode:t.row.toString()},{name:"xdr:rowOff",textNode:t.offsetY.toString()}]}),mh=e=>{const t=[{name:"a:ext",properties:{rawMap:{uri:"{FF2B5EF4-FFF2-40B4-BE49-F238E27FC236}"}},children:[{name:"a16:creationId",properties:{rawMap:{id:"{822E6D20-D7BC-2841-A643-D49A6EF008A2}","xmlns:a16":"http://schemas.microsoft.com/office/drawing/2014/main"}}}]}];switch(e.recolor&&e.recolor.toLowerCase()){case"grayscale":case"sepia":case"washout":t.push({name:"a:ext",properties:{rawMap:{uri:"{C183D7F6-B498-43B3-948B-1728B52AA6E4}"}},children:[{name:"adec:decorative",properties:{rawMap:{val:"0","xmlns:adec":"http://schemas.microsoft.com/office/drawing/2017/decorative"}}}]})}return{name:"a:extLst",children:t}},vh=(e,t)=>({name:"xdr:nvPicPr",children:[{name:"xdr:cNvPr",properties:{rawMap:{id:t,name:e.id,descr:null!=e.altText?e.altText:void 0}},children:[mh(e)]},{name:"xdr:cNvPicPr",properties:{rawMap:{preferRelativeResize:"0"}},children:[{name:"a:picLocks"}]}]}),Ch=e=>{if(!e.saturation&&!e.tint)return;const t=[];return e.saturation&&t.push({name:"a:satMod",properties:{rawMap:{val:1e3*e.saturation}}}),e.tint&&t.push({name:"a:tint",properties:{rawMap:{val:1e3*e.tint}}}),t},yh=(e,t)=>{let i;if(e.transparency){const t=Math.min(Math.max(e.transparency,0),100);i=[{name:"a:alphaModFix",properties:{rawMap:{amt:1e5-Math.round(1e3*t)}}}]}if(e.recolor)switch(i||(i=[]),e.recolor.toLocaleLowerCase()){case"grayscale":i.push({name:"a:grayscl"});break;case"sepia":i.push((n={color:"D9C3A5",tint:50,saturation:180},{name:"a:duotone",children:[{name:"a:prstClr",properties:{rawMap:{val:(r={color:"black"}).color}},children:Ch(r)},{name:"a:srgbClr",properties:{rawMap:{val:n.color}},children:Ch(n)}]}));break;case"washout":i.push({name:"a:lum",properties:{rawMap:{bright:"70000",contrast:"-70000"}}})}var r,n;return{name:"xdr:blipFill",children:[{name:"a:blip",properties:{rawMap:{cstate:"print","r:embed":`rId${t}`,"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}},children:i},{name:"a:stretch",children:[{name:"a:fillRect"}]}]}},wh=(e,t)=>{const i={name:"a:xfrm",children:[{name:"a:off",properties:{rawMap:{x:0,y:0}}},{name:"a:ext",properties:{rawMap:{cx:t.width,cy:t.height}}}]};if(e.rotation){const t=e.rotation;i.properties={rawMap:{rot:6e4*Math.min(Math.max(t,0),360)}}}return{name:"xdr:spPr",children:[i,{name:"a:prstGeom",properties:{rawMap:{prst:"rect"}},children:[{name:"a:avLst"}]}]}},Sh=(e,t,i,r)=>({name:"xdr:pic",children:[vh(e,t+1),yh(e,i+1),wh(e,r)]}),bh={getTemplate(e){const{sheetIndex:t}=e,i=Fd.worksheetImages.get(t),r=Fd.worksheetImageIds.get(t);return{name:"xdr:wsDr",properties:{rawMap:{"xmlns:a":"http://schemas.openxmlformats.org/drawingml/2006/main","xmlns:xdr":"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing"}},children:i.map((e,t)=>{const i=(e=>{e.fitCell=!!e.fitCell||!e.width||!e.height;const{position:t={},fitCell:i,width:r=0,height:n=0,totalHeight:s,totalWidth:o}=e,{offsetX:a=0,offsetY:l=0,row:c=1,rowSpan:u=1,column:h=1,colSpan:d=1}=t;return{from:{row:c-1,col:h-1,offsetX:hh(a),offsetY:hh(l)},to:{row:c-1+(i?1:u-1),col:h-1+(i?1:d-1),offsetX:hh(r+a),offsetY:hh(n+l)},height:hh(s||n),width:hh(o||r)}})(e);return{name:"xdr:twoCellAnchor",properties:{rawMap:{editAs:"absolute"}},children:[fh("from",i.from),fh("to",i.to),Sh(e,t,r.get(e.id).index,i),{name:"xdr:clientData"}]}})}}},Eh={getTemplate(e,t){const{name:i,columns:r,rowCount:n,displayName:s,headerRowIndex:o,showRowStripes:a,showColumnStripes:l,showFilterButtons:c,highlightFirstColumn:u,highlightLastColumn:h}=e||{};if(!(e&&i&&Array.isArray(r)&&r.length&&n))return{name:"table"};const d=r.map((e,t)=>({name:"filterColumn",properties:{rawMap:{colId:t.toString(),hiddenButton:c[t]?0:1}}})),p=o+1,g=(t+1).toString(),f=`A${p}:${String.fromCharCode(64+r.length)}${p+n}`;return{name:"table",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"xr xr3","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision","xmlns:xr3":"http://schemas.microsoft.com/office/spreadsheetml/2016/revision3",name:i,displayName:t?`${s}_${t+1}`:s,ref:f,totalsRowShown:0,id:g}},children:[{name:"autoFilter",properties:{rawMap:{ref:f}},children:d},{name:"tableColumns",properties:{rawMap:{count:r.length}},children:r.map((e,t)=>({name:"tableColumn",properties:{rawMap:{id:(t+1).toString(),name:e,dataCellStyle:"Normal"}}}))},{name:"tableStyleInfo",properties:{rawMap:{name:"TableStyleLight1",showFirstColumn:u?1:0,showLastColumn:h?1:0,showRowStripes:a?1:0,showColumnStripes:l?1:0}}}]}}},Ah=e=>{const[t,i,r,n]=e;return{name:`a:${t}`,children:[{name:`a:${i}`,properties:{rawMap:{val:r,lastClr:n}}}]}},Th=()=>({name:"a:clrScheme",properties:{rawMap:{name:"Office"}},children:[Ah(["dk1","sysClr","windowText","000000"]),Ah(["lt1","sysClr","window","FFFFFF"]),Ah(["dk2","srgbClr","44546A"]),Ah(["lt2","srgbClr","E7E6E6"]),Ah(["accent1","srgbClr","4472C4"]),Ah(["accent2","srgbClr","ED7D31"]),Ah(["accent3","srgbClr","A5A5A5"]),Ah(["accent4","srgbClr","FFC000"]),Ah(["accent5","srgbClr","5B9BD5"]),Ah(["accent6","srgbClr","70AD47"]),Ah(["hlink","srgbClr","0563C1"]),Ah(["folHlink","srgbClr","954F72"])]}),Mh=e=>{const[t,i,r,n]=e;return{name:`a:${t}`,properties:{rawMap:{script:r,typeface:i,panose:n}}}},Rh=()=>({name:"a:fontScheme",properties:{rawMap:{name:"Office"}},children:[{name:"a:majorFont",children:[Mh(["latin","Calibri Light",void 0,"020F0302020204030204"]),Mh(["ea",""]),Mh(["cs",""]),Mh(["font","游ゴシック Light","Jpan"]),Mh(["font","맑은 고딕","Hang"]),Mh(["font","等线 Light","Hans"]),Mh(["font","新細明體","Hant"]),Mh(["font","Times New Roman","Arab"]),Mh(["font","Times New Roman","Hebr"]),Mh(["font","Tahoma","Thai"]),Mh(["font","Nyala","Ethi"]),Mh(["font","Vrinda","Beng"]),Mh(["font","Shruti","Gujr"]),Mh(["font","MoolBoran","Khmr"]),Mh(["font","Tunga","Knda"]),Mh(["font","Raavi","Guru"]),Mh(["font","Euphemia","Cans"]),Mh(["font","Plantagenet Cherokee","Cher"]),Mh(["font","Microsoft Yi Baiti","Yiii"]),Mh(["font","Microsoft Himalaya","Tibt"]),Mh(["font","MV Boli","Thaa"]),Mh(["font","Mangal","Deva"]),Mh(["font","Gautami","Telu"]),Mh(["font","Latha","Taml"]),Mh(["font","Estrangelo Edessa","Syrc"]),Mh(["font","Kalinga","Orya"]),Mh(["font","Kartika","Mlym"]),Mh(["font","DokChampa","Laoo"]),Mh(["font","Iskoola Pota","Sinh"]),Mh(["font","Mongolian Baiti","Mong"]),Mh(["font","Times New Roman","Viet"]),Mh(["font","Microsoft Uighur","Uigh"]),Mh(["font","Sylfaen","Geor"]),Mh(["font","Arial","Armn"]),Mh(["font","Leelawadee UI","Bugi"]),Mh(["font","Microsoft JhengHei","Bopo"]),Mh(["font","Javanese Text","Java"]),Mh(["font","Segoe UI","Lisu"]),Mh(["font","Myanmar Text","Mymr"]),Mh(["font","Ebrima","Nkoo"]),Mh(["font","Nirmala UI","Olck"]),Mh(["font","Ebrima","Osma"]),Mh(["font","Phagspa","Phag"]),Mh(["font","Estrangelo Edessa","Syrn"]),Mh(["font","Estrangelo Edessa","Syrj"]),Mh(["font","Estrangelo Edessa","Syre"]),Mh(["font","Nirmala UI","Sora"]),Mh(["font","Microsoft Tai Le","Tale"]),Mh(["font","Microsoft New Tai Lue","Talu"]),Mh(["font","Ebrima","Tfng"])]},{name:"a:minorFont",children:[Mh(["latin","Calibri",void 0,"020F0502020204030204"]),Mh(["ea",""]),Mh(["cs",""]),Mh(["font","游ゴシック","Jpan"]),Mh(["font","맑은 고딕","Hang"]),Mh(["font","等线","Hans"]),Mh(["font","新細明體","Hant"]),Mh(["font","Arial","Arab"]),Mh(["font","Arial","Hebr"]),Mh(["font","Tahoma","Thai"]),Mh(["font","Nyala","Ethi"]),Mh(["font","Vrinda","Beng"]),Mh(["font","Shruti","Gujr"]),Mh(["font","DaunPenh","Khmr"]),Mh(["font","Tunga","Knda"]),Mh(["font","Raavi","Guru"]),Mh(["font","Euphemia","Cans"]),Mh(["font","Plantagenet Cherokee","Cher"]),Mh(["font","Microsoft Yi Baiti","Yiii"]),Mh(["font","Microsoft Himalaya","Tibt"]),Mh(["font","MV Boli","Thaa"]),Mh(["font","Mangal","Deva"]),Mh(["font","Gautami","Telu"]),Mh(["font","Latha","Taml"]),Mh(["font","Estrangelo Edessa","Syrc"]),Mh(["font","Kalinga","Orya"]),Mh(["font","Kartika","Mlym"]),Mh(["font","DokChampa","Laoo"]),Mh(["font","Iskoola Pota","Sinh"]),Mh(["font","Mongolian Baiti","Mong"]),Mh(["font","Arial","Viet"]),Mh(["font","Microsoft Uighur","Uigh"]),Mh(["font","Sylfaen","Geor"]),Mh(["font","Arial","Armn"]),Mh(["font","Leelawadee UI","Bugi"]),Mh(["font","Microsoft JhengHei","Bopo"]),Mh(["font","Javanese Text","Java"]),Mh(["font","Segoe UI","Lisu"]),Mh(["font","Myanmar Text","Mymr"]),Mh(["font","Ebrima","Nkoo"]),Mh(["font","Nirmala UI","Olck"]),Mh(["font","Ebrima","Osma"]),Mh(["font","Phagspa","Phag"]),Mh(["font","Estrangelo Edessa","Syrn"]),Mh(["font","Estrangelo Edessa","Syrj"]),Mh(["font","Estrangelo Edessa","Syre"]),Mh(["font","Nirmala UI","Sora"]),Mh(["font","Microsoft Tai Le","Tale"]),Mh(["font","Microsoft New Tai Lue","Talu"]),Mh(["font","Ebrima","Tfng"])]}]}),_h=(e,t,i)=>({name:`a:${e}`,properties:{rawMap:{val:t}},children:i}),Ph=e=>{const[t,i,r,n,s,o]=e,a=[];return a.push(_h("satMod",r)),n&&a.push(_h("lumMod",n)),s&&a.push(_h("tint",s)),o&&a.push(_h("shade",o)),{name:"a:gs",properties:{rawMap:{pos:t}},children:[{name:"a:schemeClr",properties:{rawMap:{val:i}},children:a}]}},xh=(e,t)=>({name:"a:solidFill",children:[_h("schemeClr",e,t)]}),Dh=e=>{const[t,i,r,n,s]=e,[o,a]=s;return{name:"a:gradFill",properties:{rawMap:{rotWithShape:t}},children:[{name:"a:gsLst",children:[Ph(i),Ph(r),Ph(n)]},{name:"a:lin",properties:{rawMap:{ang:o,scaled:a}}}]}},Ih=e=>{const[t,i,r,n]=e;return{name:"a:ln",properties:{rawMap:{w:t,cap:i,cmpd:r,algn:n}},children:[xh("phClr"),_h("prstDash","solid"),{name:"a:miter",properties:{rawMap:{lim:"800000"}}}]}},Lh=e=>{const t=[];if(e){const[i,r,n,s,o]=e;t.push({name:"a:outerShdw",properties:{rawMap:{blurRad:i,dist:r,dir:n,algn:s,rotWithShape:o}},children:[_h("srgbClr","000000",[_h("alpha","63000")])]})}return{name:"a:effectStyle",children:[Object.assign({},{name:"a:effectLst"},t.length?{children:t}:{})]}},Nh=()=>({name:"a:fmtScheme",properties:{rawMap:{name:"Office"}},children:[{name:"a:fillStyleLst",children:[xh("phClr"),Dh(["1",["0","phClr","105000","110000","67000"],["50000","phClr","103000","105000","73000"],["100000","phClr","109000","105000","81000"],["5400000","0"]]),Dh(["1",["0","phClr","103000","102000","94000"],["50000","phClr","110000","100000",void 0,"100000"],["100000","phClr","120000","99000",void 0,"78000"],["5400000","0"]])]},{name:"a:lnStyleLst",children:[Ih(["6350","flat","sng","ctr"]),Ih(["12700","flat","sng","ctr"]),Ih(["19050","flat","sng","ctr"])]},{name:"a:effectStyleLst",children:[Lh(),Lh(),Lh(["57150","19050","5400000","ctr","0"])]},{name:"a:bgFillStyleLst",children:[xh("phClr"),xh("phClr",[_h("tint","95000"),_h("satMod","170000")]),Dh(["1",["0","phClr","150000","102000","93000","98000"],["50000","phClr","130000","103000","98000","90000"],["100000","phClr","120000",void 0,void 0,"63000"],["5400000","0"]])]}]}),Oh=()=>({name:"a:themeElements",children:[Th(),Rh(),Nh()]}),Fh=()=>({name:"a:theme",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{a:"http://schemas.openxmlformats.org/drawingml/2006/main"}}],rawMap:{name:"Office Theme"}},children:[Oh(),{name:"a:objectDefaults"},{name:"a:extraClrSchemeLst"}]}),kh=e=>{const t=[];for(const i of e.keys()){const e=i.toString(),r={name:"t",textNode:Hu._.escapeString(e)};e.trim().length!==e.length&&(r.properties={rawMap:{"xml:space":"preserve"}}),t.push({name:"si",children:[r]})}return t},Gh=e=>({name:"sst",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main",count:e.size,uniqueCount:e.size}},children:kh(e)}),Vh={getTemplate(e){let{formatCode:t,numFmtId:i}=e;return t.length&&(t=function(e){const t=e.split(/(\[[^\]]*\])/);for(let e=0;e<t.length;e++){let i=t[e];i.length&&(i.startsWith("[")||(i=i.replace(/\$/g,'"$"')),t[e]=Bu._.escapeString(i))}return t.join("")}(t)),{name:"numFmt",properties:{rawMap:{formatCode:t,numFmtId:i}}}}},Hh=e=>({name:"numFmts",properties:{rawMap:{count:e.length}},children:e.map(e=>Vh.getTemplate(e))}),Bh={getTemplate(e){const{size:t,colorTheme:i,color:r="FF000000",fontName:n="Calibri",family:s,scheme:o,italic:a,bold:l,strikeThrough:c,outline:u,shadow:h,underline:d,verticalAlign:p}=e,g=[{name:"sz",properties:{rawMap:{val:t}}},{name:"color",properties:{rawMap:{theme:i,rgb:r}}},{name:"name",properties:{rawMap:{val:n}}}];return s&&g.push({name:"family",properties:{rawMap:{val:s}}}),o&&g.push({name:"scheme",properties:{rawMap:{val:o}}}),a&&g.push({name:"i"}),l&&g.push({name:"b"}),c&&g.push({name:"strike"}),u&&g.push({name:"outline"}),h&&g.push({name:"shadow"}),d&&g.push({name:"u",properties:{rawMap:{val:d}}}),p&&g.push({name:"vertAlign",properties:{rawMap:{val:p}}}),{name:"font",children:g}}},zh=e=>({name:"fonts",properties:{rawMap:{count:e.length}},children:e.map(e=>Bh.getTemplate(e))}),Uh={getTemplate(e){const{patternType:t,fgTheme:i,fgTint:r,fgRgb:n,bgRgb:s,bgIndexed:o}=e,a={name:"patternFill",properties:{rawMap:{patternType:t}}};return(i||r||n)&&(a.children=[{name:"fgColor",properties:{rawMap:{theme:i,tint:r,rgb:n}}}]),(o||s)&&(a.children||(a.children=[]),a.children.push({name:"bgColor",properties:{rawMap:{indexed:o,rgb:s}}})),{name:"fill",children:[a]}}},Wh=e=>({name:"fills",properties:{rawMap:{count:e.length}},children:e.map(e=>Uh.getTemplate(e))}),jh={None:"None",Dot:"Dotted",Dash:"Dashed",Double:"Double",DashDot:"DashDot",DashDotDot:"DashDotDot",SlantDashDot:"SlantDashDot"},Kh=["Dashed","DashDot","DashDotDot"],$h={None:"none",Solid:"solid",Gray50:"mediumGray",Gray75:"darkGray",Gray25:"lightGray",HorzStripe:"darkHorizontal",VertStripe:"darkVertical",ReverseDiagStripe:"darkDown",DiagStripe:"darkUp",DiagCross:"darkGrid",ThickDiagCross:"darkTrellis",ThinHorzStripe:"lightHorizontal",ThinVertStripe:"lightVertical",ThinReverseDiagStripe:"lightDown",ThinDiagStripe:"lightUp",ThinHorzCross:"lightGrid",ThinDiagCross:"lightTrellis",Gray125:"gray125",Gray0625:"gray0625"},qh={Automatic:"general",Left:"left",Center:"center",Right:"right",Fill:"fill",Justify:"justify",CenterAcrossSelection:"centerContinuous",Distributed:"distributed",JustifyDistributed:"justify"},Yh={Automatic:void 0,Top:"top",Bottom:"bottom",Center:"center",Justify:"justify",Distributed:"distributed",JustifyDistributed:"justify"},Qh=e=>null==e?e:("#"===e.charAt(0)&&(e=e.substring(1)),6===e.length?"FF"+e:e),Xh=(e,t)=>{if(!e)return"thin";const i=(e=>{switch(e){case 1:return"thin";case 2:return"medium";case 3:return"thick";default:return"hair"}})(t),r=jh[e];return"Continuous"===e?i:"medium"===i&&-1!==Kh.indexOf(r)?`medium${r}`:r.charAt(0).toLowerCase()+r.substring(1)},Zh=e=>qh[e]||"general",Jh=e=>Yh[e]||void 0,ed=e=>({name:"color",properties:{rawMap:{rgb:Qh(e||"#000000")}}}),td={getTemplate(e){const{left:t,right:i,top:r,bottom:n,diagonal:s}=e,o=t?[ed(t.color)]:void 0,a=i?[ed(i.color)]:void 0,l=r?[ed(r.color)]:void 0,c=n?[ed(n.color)]:void 0,u=s?[ed(s.color)]:void 0;return{name:"border",children:[{name:"left",properties:{rawMap:{style:t&&t.style}},children:o},{name:"right",properties:{rawMap:{style:i&&i.style}},children:a},{name:"top",properties:{rawMap:{style:r&&r.style}},children:l},{name:"bottom",properties:{rawMap:{style:n&&n.style}},children:c},{name:"diagonal",properties:{rawMap:{style:s&&s.style}},children:u}]}}},id=e=>({name:"borders",properties:{rawMap:{count:e.length}},children:e.map(e=>td.getTemplate(e))}),rd=e=>{const t=["Context","LeftToRight","RightToLeft"].indexOf(e);return Math.max(t,0)},nd={getTemplate(e){const{horizontal:t,indent:i,readingOrder:r,rotate:n,shrinkToFit:s,vertical:o,wrapText:a}=e;return{name:"alignment",properties:{rawMap:{horizontal:t&&Zh(t),indent:i,readingOrder:r&&rd(r),textRotation:n,shrinkToFit:s,vertical:o&&Jh(o),wrapText:a}}}}},sd={getTemplate(e){const t=!1===e.protected?0:1;return{name:"protection",properties:{rawMap:{hidden:!0===e.hideFormula?1:0,locked:t}}}}},od={getTemplate(e){const{alignment:t,borderId:i,fillId:r,fontId:n,numFmtId:s,protection:o,quotePrefix:a,xfId:l}=e,c=[];return t&&c.push(nd.getTemplate(t)),o&&c.push(sd.getTemplate(o)),{name:"xf",properties:{rawMap:{applyAlignment:t?1:void 0,applyProtection:o?1:void 0,applyBorder:i?1:void 0,applyFill:r?1:void 0,borderId:i,fillId:r,applyFont:n?1:void 0,fontId:n,applyNumberFormat:s?1:void 0,numFmtId:s,quotePrefix:a?1:void 0,xfId:l}},children:c.length?c:void 0}}},ad=e=>({name:"cellStyleXfs",properties:{rawMap:{count:e.length}},children:e.map(e=>od.getTemplate(e))}),ld=e=>({name:"cellXfs",properties:{rawMap:{count:e.length}},children:e.map(e=>od.getTemplate(e))}),cd={getTemplate(e){const{builtinId:t,name:i,xfId:r}=e;return{name:"cellStyle",properties:{rawMap:{builtinId:t,name:i,xfId:r}}}}},ud=e=>({name:"cellStyles",properties:{rawMap:{count:e.length}},children:e.map(e=>cd.getTemplate(e))}),hd=(e,t)=>(-1!==e.indexOf("mixedStyle")&&t>1&&(e+=`_${t}`),e),dd=()=>{Mu={base:0},Ru=[],_u=[{fontName:"Calibri",colorTheme:"1",family:"2",scheme:"minor"}],Pu=[{patternType:"none"},{patternType:"gray125"}],xu=[{left:void 0,right:void 0,top:void 0,bottom:void 0,diagonal:void 0}],Du=[{borderId:0,fillId:0,fontId:0,numFmtId:0}],Iu=[{borderId:0,fillId:0,fontId:0,numFmtId:0,xfId:0}],Lu=[{builtinId:0,name:"Normal",xfId:0}]},pd=e=>{const{alignment:t,borders:i,font:r,interior:n,numberFormat:s,protection:o,quotePrefix:a}=e;let{id:l}=e,c=0,u=0,h=0,d=0;l&&(l=hd(l,Nu),null==Mu[l]&&(n&&(c=(e=>{const t=(i=e.pattern)?$h[i]||i:"none";var i;const r=Qh(e.color),n=Qh(e.patternColor);let s=Pu.findIndex(e=>{const{patternType:i,fgRgb:s,bgRgb:o}=e;return i==t&&s==r&&o==n});return-1===s&&(s=Pu.length,Pu.push({patternType:t,fgRgb:r,bgRgb:n})),s})(n)),i&&(u=(e=>{const{borderBottom:t,borderTop:i,borderLeft:r,borderRight:n}=e;let s,o,a,l,c,u,h,d;r&&(a=Xh(r.lineStyle,r.weight),h=Qh(r.color)),n&&(l=Xh(n.lineStyle,n.weight),d=Qh(n.color)),t&&(s=Xh(t.lineStyle,t.weight),c=Qh(t.color)),i&&(o=Xh(i.lineStyle,i.weight),u=Qh(i.color));let p=xu.findIndex(e=>{const{left:t,right:i,top:r,bottom:n}=e;if(!t&&(a||h))return!1;if(!i&&(l||d))return!1;if(!r&&(o||u))return!1;if(!n&&(s||c))return!1;const{style:p,color:g}=t||{},{style:f,color:m}=i||{},{style:v,color:C}=r||{},{style:y,color:w}=n||{};return p==a&&g==h&&f==l&&m==d&&v==o&&C==u&&y==s&&w==c});return-1===p&&(p=xu.length,xu.push({left:{style:a,color:h},right:{style:l,color:d},top:{style:o,color:u},bottom:{style:s,color:c},diagonal:{style:void 0,color:void 0}})),p})(i)),r&&(h=(e=>{const{fontName:t="Calibri",color:i,size:r,bold:n,italic:s,outline:o,shadow:a,strikeThrough:l,underline:c,family:u,verticalAlign:h}=e,d=Qh(i),p=(e=>{if(void 0===e)return;const t=["Automatic","Roman","Swiss","Modern","Script","Decorative"].indexOf(e||"Automatic");return Math.max(t,0)})(u),g=c?c.toLocaleLowerCase():void 0,f=h?h.toLocaleLowerCase():void 0;let m=_u.findIndex(e=>e.fontName==t&&e.color==d&&e.size==r&&e.bold==n&&e.italic==s&&e.outline==o&&e.shadow==a&&e.strikeThrough==l&&e.underline==g&&e.verticalAlign==f&&e.family==p);return-1===m&&(m=_u.length,_u.push({fontName:t,color:d,size:r,bold:n,italic:s,outline:o,shadow:a,strikeThrough:l,underline:g,verticalAlign:f,family:null!=p?p.toString():void 0})),m})(r)),s&&(d=(e=>{if(ch[e])return ch[e];let t=Ru.findIndex(t=>t.formatCode===e);return-1===t?(t=Ru.length+164,Ru.push({formatCode:e,numFmtId:t})):t=Ru[t].numFmtId,t})(s.format)),Mu[l]=Iu.length,Iu.push({alignment:t,borderId:u||0,fillId:c||0,fontId:h||0,numFmtId:d||0,protection:o,quotePrefix:a,xfId:0})))},gd=(e,t)=>Mu[hd(e,t)]||0,fd={getTemplate(e){const t=Hh(Ru),i=zh(_u.map(t=>nh(rh({},t),{size:null!=t.size?t.size:e}))),r=Wh(Pu),n=id(xu),s=ad(Du),o=ld(Iu),a=ud(Lu);return dd(),{name:"styleSheet",properties:{rawMap:{"mc:Ignorable":"x14ac x16r2 xr",xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac","xmlns:x16r2":"http://schemas.microsoft.com/office/spreadsheetml/2015/02/main","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision"}},children:[t,i,r,n,s,o,a,{name:"tableStyles",properties:{rawMap:{count:0,defaultPivotStyle:"PivotStyleLight16",defaultTableStyle:"TableStyleMedium2"}}}]}}},md={getTemplate(e,t){const i=(t+1).toString();return{name:"sheet",properties:{rawMap:{name:e,sheetId:i,"r:id":`rId${i}`}}}}},vd=e=>({name:"sheets",children:e.map((e,t)=>md.getTemplate(e,t))}),Cd=e=>({name:"workbook",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}}],rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},children:[vd(e)]}),yd={getTemplate(e){const{min:t,max:i,outlineLevel:r,s:n,width:s,hidden:o,bestFit:a}=e;let l=1,c="0";return s>1&&(l=(e=>Math.ceil((e-12)/7+1))(s),c="1"),{name:"col",properties:{rawMap:{min:t,max:i,outlineLevel:null!=r?r:void 0,width:l,style:n,hidden:o?"1":"0",bestFit:a?"1":"0",customWidth:c}}}}},wd={getTemplate(e,t,i){const{ref:r,data:n,styleId:s}=e,{type:o,value:a}=n||{type:"empty",value:null};let l=o;"f"===o?l="str":o.charAt(0)===o.charAt(0).toUpperCase()&&(l=(e=>{const t=e.charAt(0).toLowerCase();return"s"===t?"inlineStr":t})(o));const c={name:"c",properties:{rawMap:{r,t:"empty"===l?void 0:l,s:s?gd(s,i):void 0}}};if("empty"===l)return c;let u;return u="str"===l&&"f"===o?[{name:"f",textNode:Uu._.escapeString(a)}]:"inlineStr"===l?[{name:"is",children:[{name:"t",textNode:Uu._.escapeString(a)}]}]:[{name:"v",textNode:a}],Object.assign({},c,{children:u})}},Sd=e=>{var t;return""!==(null==(t=e.data)?void 0:t.value)||void 0!==e.styleId},bd={getTemplate(e,t,i){const{collapsed:r,hidden:n,height:s,outlineLevel:o,cells:a=[]}=e;return((e,t)=>{const i=[];let r=0;for(let t=0;t<e.length;t++){const n=e[t];n.mergeAcross&&(i.push({pos:t,excelPos:r}),r+=n.mergeAcross),r++}if(i.length)for(let r=i.length-1;r>=0;r--){const n=[],s=e[i[r].pos];for(let e=1;e<=s.mergeAcross;e++)n.push({ref:`${gh(i[r].excelPos+1+e)}${t+1}`,styleId:s.styleId,data:{type:"empty",value:null}});n.length&&e.splice(i[r].pos+1,0,...n)}})(a,t),{name:"row",properties:{rawMap:{r:t+1,collapsed:r?"1":"0",hidden:n?"1":"0",ht:s,customHeight:null!=s?"1":"0",spans:"1:1",outlineLevel:o||void 0}},children:a.filter(Sd).map((e,t)=>wd.getTemplate(e,t,i))}}},Ed=e=>({name:"mergeCell",properties:{rawMap:{ref:e}}}),Ad=e=>{if(null==e)return 1;const t=["Letter","Letter Small","Tabloid","Ledger","Legal","Statement","Executive","A3","A4","A4 Small","A5","A6","B4","B5","Folio","Envelope","Envelope DL","Envelope C5","Envelope B5","Envelope C3","Envelope C4","Envelope C6","Envelope Monarch","Japanese Postcard","Japanese Double Postcard"].indexOf(e);return-1===t?1:t+1},Td=(e,t,i)=>e.reduce((e,r,n)=>{const s="Center"===(o=r.position)?"C":"Right"===o?"R":"L";var o;const a=(l=`${e}&amp;${s}`,(c=r.font)?(l+="&amp;&quot;",l+=c.fontName||"Calibri",c.bold!==c.italic?l+=c.bold?",Bold":",Italic":c.bold?l+=",Bold Italic":l+=",Regular",l+="&quot;",c.size&&(l+=`&amp;${c.size}`),c.strikeThrough&&(l+="&amp;S"),c.underline&&(l+="&amp;"+("Double"===c.underline?"E":"U")),c.color&&(l+=`&amp;K${c.color.replace("#","").toUpperCase()}`),l):l);var l,c;r.position||(r.position=["Left","Center","Right"][n]);const{image:u}=r;if("&[Picture]"===r.value&&u){const e=`${s}${t}${i}`;Fd.addHeaderFooterImageToMap(u,e)}return`${a}${zu._.escapeString((h=r.value,zu._.iterateObject({"&[Page]":"&P","&[Pages]":"&N","&[Date]":"&D","&[Time]":"&T","&[Tab]":"&A","&[Path]":"&Z","&[File]":"&F","&[Picture]":"&G"},(e,t)=>{h=h.replace(e,t)}),h))}`;var h},""),Md=e=>{const t=[];return["all","first","even"].forEach(i=>{const r=e[i],n="all"===i?"odd":i;if(r)for(const[e,s]of Object.entries(r)){const r=`${e.charAt(0).toUpperCase()}${e.slice(1)}`,o=e[0].toUpperCase();if(s){const e="all"===i?"":i.toUpperCase();t.push({name:`${n}${r}`,properties:{rawMap:{"xml:space":"preserve"}},textNode:Td(s,o,e)})}}}),t},Rd={getTemplate(e){const{worksheet:t,currentSheet:i,config:r}=e,{margins:n={},pageSetup:s,headerFooterConfig:o,suppressColumnOutline:a}=r,{table:l}=t,{rows:c,columns:u}=l,h=u&&u.length?((e,t,i)=>{const r=[],n=[];e.forEach((e,i)=>{const s=e.cells;let o,a=0;s.forEach((e,s)=>{const l=s+a+1,c=gh(l),u=i+1;if(e.mergeAcross){a+=e.mergeAcross;const t=gh(s+a+1);r.push(`${c}${u}:${t}${u}`)}t[l-1]||(t[l-1]={});const{collapsibleRanges:h}=e;h&&h.forEach(e=>{n.push([l+e[0],l+e[1]])}),o=t[l-1],o.min=l,o.max=l,e.ref=`${c}${u}`})}),n.sort((e,t)=>e[0]!==t[0]?e[0]-t[0]:t[1]-e[1]);const s=new Map,o=new Map;return n.filter(e=>{const t=e.toString();return!s.get(t)&&(s.set(t,!0),!0)}).forEach(e=>{const r=t.find(t=>t.min==e[0]&&t.max==e[1]),n=o.get(e[0]);t.push({min:e[0],max:e[1],outlineLevel:i?void 0:n||1,width:(r||{width:100}).width}),o.set(e[0],(n||0)+1)}),r})(c,u,!!a):[],{worksheetDataTables:d}=Fd,p=d.get(i),g=zu._.compose(e=>(e.children.push({name:"sheetPr",children:[{name:"outlinePr",properties:{rawMap:{summaryBelow:0}}}]}),e),(e=>t=>{const i=e.reduce((e,t)=>t.outlineLevel&&t.outlineLevel>e?t.outlineLevel:e,0);return t.children.push({name:"sheetFormatPr",properties:{rawMap:{baseColWidth:10,defaultRowHeight:16,outlineLevelRow:i||void 0}}}),t})(c),(e=>t=>(e.length&&t.children.push({name:"cols",children:e.map(e=>yd.getTemplate(e))}),t))(u),((e,t)=>i=>(e.length&&i.children.push({name:"sheetData",children:e.map((e,i)=>bd.getTemplate(e,i,t))}),i))(c,i+1),(m=h,e=>(m.length&&e.children.push({name:"mergeCells",properties:{rawMap:{count:m.length}},children:m.map(e=>Ed(e))}),e)),(e=>t=>{const{top:i=.75,right:r=.7,bottom:n=.75,left:s=.7,header:o=.3,footer:a=.3}=e;return t.children.push({name:"pageMargins",properties:{rawMap:{bottom:n,footer:a,header:o,left:s,right:r,top:i}}}),t})(n),(e=>t=>{var i;return e&&t.children.push({name:"pageSetup",properties:{rawMap:{horizontalDpi:0,verticalDpi:0,orientation:(i=e.orientation,!i||"Portrait"!==i&&"Landscape"!==i?"portrait":i.toLocaleLowerCase()),paperSize:Ad(e.pageSize)}}}),t})(s),(e=>t=>{if(!e)return t;const i=null!=e.first?1:0,r=null!=e.even?1:0;return t.children.push({name:"headerFooter",properties:{rawMap:{differentFirst:i,differentOddEven:r}},children:Md(e)}),t})(o),(e=>t=>{const i=Fd.worksheetImages.get(e);return(null==i?void 0:i.length)&&t.children.push({name:"drawing",properties:{rawMap:{"r:id":"rId"+ ++t.rIdCounter}}}),t})(i),(e=>t=>(Fd.worksheetHeaderFooterImages.get(e)&&t.children.push({name:"legacyDrawingHF",properties:{rawMap:{"r:id":"rId"+ ++t.rIdCounter}}}),t))(i),(f=p,e=>(f&&e.children.push({name:"tableParts",properties:{rawMap:{count:"1"}},children:[{name:"tablePart",properties:{rawMap:{"r:id":"rId"+ ++e.rIdCounter}}}]}),e)));var f,m;const{children:v}=g({children:[],rIdCounter:0});return{name:"worksheet",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}}],rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},children:v}}},_d={getTemplate(e){const{Id:t,Type:i,Target:r}=e;return{name:"Relationship",properties:{rawMap:{Id:t,Type:i,Target:r}}}}},Pd=e=>({name:"Relationships",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/package/2006/relationships"}},children:e.map(e=>_d.getTemplate(e))}),xd=e=>{const{aspectratio:t,rotation:i}=e||{},r={};return t&&(r.aspectratio="t"),i&&(r.rotation="t"),{name:"o:lock",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}],rawMap:r}}},Dd={0:"0",5:"6554f",10:"13107f",15:"19661f",20:"26214f",25:".5",30:"39322f",35:"45875f",40:"52429f",45:"58982f",50:"1",55:"72818f",60:"1.25",65:"93623f",70:"109227f",75:"2",80:"2.5",85:"3.4",90:"5",95:"10",96:"12.5",97:"1092267f",98:"25",99:"50",100:"2147483647f"},Id=(e,t)=>{var i;let r;const{recolor:n,brightness:s,contrast:o,id:a}=e;var l;return n&&(r={},"Washout"!==n&&"Grayscale"!==n||(r.gain="19661f",r.blacklevel="22938f"),"Black & White"!==n&&"Grayscale"!==n||(r.grayscale="t","Black & White"===n&&(r.bilevel="t"))),n&&"Grayscale"!==n||(r||(r={}),null!=o&&50!==o&&(r.gain=null!=(i=Dd[o])?i:"1"),null!=s&&50!==s&&(r.blacklevel=(l=s,(l-0)/100*1-.5).toString())),{name:"v:imagedata",properties:{prefixedAttributes:[{prefix:"o:",map:{relid:`rId${t}`,title:a}}],rawMap:r}}},Ld=e=>Math.floor(.74999943307122*(null!=e?e:0)),Nd={getTemplate(e){const t=Fd.worksheetHeaderFooterImages.get(e.sheetIndex)||[];var i;return{name:"xml",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{v:"urn:schemas-microsoft-com:vml",o:"urn:schemas-microsoft-com:office:office",x:"urn:schemas-microsoft-com:office:excel"}}]},children:[{name:"o:shapelayout",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}]},children:[{name:"o:idmap",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}],rawMap:{data:"1"}}}]},{name:"v:shapetype",properties:{prefixedAttributes:[{prefix:"o:",map:{spt:"75",preferrelative:"t"}}],rawMap:{coordsize:"21600,21600",filled:"f",id:"_x0000_t75",path:"m@4@5l@4@11@9@11@9@5xe",stroked:"f"}},children:[{name:"v:stroke",properties:{rawMap:{joinstyle:"miter"}}},(i=["if lineDrawn pixelLineWidth 0","sum @0 1 0","sum 0 0 @1","prod @2 1 2","prod @3 21600 pixelWidth","prod @3 21600 pixelHeight","sum @0 0 1","prod @6 1 2","prod @7 21600 pixelWidth","sum @8 21600 0","prod @7 21600 pixelHeight","sum @10 21600 0"],{name:"v:formulas",children:i.map(e=>({name:"v:f",properties:{rawMap:{eqn:e}}}))}),{name:"v:path",properties:{prefixedAttributes:[{prefix:"o:",map:{connecttype:"rect",extrusionok:"f"}}],rawMap:{gradientshapeok:"t"}}},xd({aspectratio:!0})]},...t.map((e,t)=>((e,t)=>{const{width:i=0,height:r=0,altText:n}=e,s=Ld(i),o=Ld(r);return{name:"v:shape",properties:{rawMap:{id:e.headerFooterPosition,"o:spid":"_x0000_s1025",style:`position: absolute; margin-left: 0; margin-top: 10in; margin-bottom: 0; margin-right: 0; width: ${s}pt; height: ${o}pt; z-index: ${t+1}`,type:"#_x0000_t75",alt:n}},children:[Id(e,t+1),xd({rotation:!0})]}})(e,t))]}}},Od=class e{static createExcel(e,t,i){this.addSheetName(t),((e,t)=>{1===(Nu=t)&&dd(),e.forEach(pd)})(e,this.sheetNames.length);let r=Object.assign({},i);return i.exportAsExcelTable&&(i.columnModel.isPivotActive()&&(this.showExcelTableNonCompatibleFeaturesWarning("pivot mode"),r.exportAsExcelTable=!1),i.gos.get("masterDetail")&&(this.showExcelTableNonCompatibleFeaturesWarning("master/detail"),r.exportAsExcelTable=!1)),this.processTableConfig(t,r),this.createWorksheet(t,r)}static showExcelTableNonCompatibleFeaturesWarning(e){console.warn(`AG Grid: Excel table export does not work with ${e}. The exported Excel file will not contain any Excel tables.\nPlease turn off ${e} to enable Excel table exports.`)}static getTableNameFromIndex(e){return`table${e+1}`}static getSanitizedTableName(e){return e.replace(/^[^a-zA-Z_]+/,"_").replace(/\s/g,"_").replace(/[^a-zA-Z0-9_]/g,"_")}static addTableToSheet(e,t){this.worksheetDataTables.has(e)?console.warn("Unable to add data table to Excel sheet: A table already exists."):this.worksheetDataTables.set(e,t)}static processTableConfig(t,i){var r;if(!i.exportAsExcelTable)return;const n="boolean"==typeof i.exportAsExcelTable?{}:i.exportAsExcelTable,{name:s,showColumnStripes:o,showRowStripes:a,showFilterButton:l,highlightFirstColumn:c,highlightLastColumn:u}=n,h=this.getSanitizedTableName(s||e.defaultTableDisplayName),d=this.sheetNames.length-1,{table:p}=t,{rows:g,columns:f}=p,m=i.columnModel.getHeaderRowCount(),v=m-1,C=g.length,y=f.length,w=[],S=[];for(let e=0;e<y;e++){const t=f[e];w.push(t.displayName||""),S.push("match"===l||void 0===l?null!=(r=t.filterAllowed)&&r:l)}w&&w.length&&C&&h?this.addTableToSheet(d,{name:this.getTableNameFromIndex(d),displayName:h,columns:w,showFilterButtons:S,headerRowIndex:v,rowCount:C-m,showRowStripes:null==a||a,showColumnStripes:null!=o&&o,highlightFirstColumn:null!=c&&c,highlightLastColumn:null!=u&&u}):console.warn("Unable to add data table to Excel sheet: Missing required parameters.")}static addHeaderFooterImageToMap(e,t){const i=this.sheetNames.length-1,r=e;r.headerFooterPosition=t,this.buildImageMap({imageToAdd:r,idx:i});let n=this.worksheetHeaderFooterImages.get(i);n||(n=[],this.worksheetHeaderFooterImages.set(i,n)),n.find(t=>t.id===e.id)||n.push(e)}static addBodyImageToMap(e,t,i,r,n){let s=this.sheetNames.length;const{row:o,column:a}=e.position||{},l=e;r&&(null==t||null==i||o&&a||(e.position||(e.position={}),e.position=Object.assign({},e.position,{row:t,column:r.indexOf(i)+1})),((e,t)=>{const{colSpan:i,column:r}=e.position;if(e.width)if(i){const n=t.slice(r-1,r+i-1);let s=0;for(let t=0;t<n.length;t++){const i=n[t].getActualWidth();if(e.width<s+i){e.position.colSpan=t+1,e.totalWidth=e.width,e.width=e.totalWidth-s;break}s+=i}}else e.totalWidth=e.width})(l,r),((e,t)=>{const{rowSpan:i,row:r}=e.position;if(e.height)if(i){let n=0,s=0;for(let o=r;o<r+i;o++){const i=uh(dh(o,t)||20);if(e.height<n+i){e.position.rowSpan=s+1,e.totalHeight=e.height,e.height=e.totalHeight-n;break}n+=i,s++}}else e.totalHeight=e.height})(l,n)),this.buildImageMap({imageToAdd:l,idx:s});let c=this.worksheetImageIds.get(s);c||(c=new Map,this.worksheetImageIds.set(s,c));const u=this.worksheetImages.get(s);u?u.push(l):this.worksheetImages.set(s,[l]),c.get(e.id)||c.set(e.id,{index:c.size,type:e.imageType})}static buildImageMap(e){const{imageToAdd:t,idx:i}=e,r=this.images.get(t.id);if(r){const e=r.find(e=>e.sheetId===i);e?e.image.push(t):r.push({sheetId:i,image:[t]})}else this.images.set(t.id,[{sheetId:i,image:[t]}]),this.workbookImageIds.set(t.id,{type:t.imageType,index:this.workbookImageIds.size})}static addSheetName(e){const t=Gu._.escapeString(e.name)||"";let i="";for(;-1!==this.sheetNames.indexOf(`${t}${i}`);)if(""===i)i="_1";else{const e=parseInt(i.slice(1),10);i=`_${e+1}`}e.name=`${t}${i}`,this.sheetNames.push(e.name)}static getStringPosition(e){return this.sharedStrings.has(e)?this.sharedStrings.get(e):(this.sharedStrings.set(e,this.sharedStrings.size),this.sharedStrings.size-1)}static resetFactory(){this.sharedStrings=new Map,this.images=new Map,this.worksheetImages=new Map,this.worksheetHeaderFooterImages=new Map,this.workbookImageIds=new Map,this.worksheetImageIds=new Map,this.worksheetDataTables=new Map,this.sheetNames=[],this.factoryMode=Gu.ExcelFactoryMode.SINGLE_SHEET}static createWorkbook(){return ph(Cd(this.sheetNames))}static createStylesheet(e){return ph(fd.getTemplate(e))}static createSharedStrings(){return ph(Gh(this.sharedStrings))}static createCore(e){return ph(oh.getTemplate(e))}static createContentTypes(e){return ph(lh.getTemplate(e))}static createRels(){const e=Pd([{Id:"rId1",Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",Target:"xl/workbook.xml"},{Id:"rId2",Type:"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",Target:"docProps/core.xml"}]);return ph(e)}static createTheme(){return ph(Fh())}static createTable(e,t){return ph(Eh.getTemplate(e,t))}static createWorkbookRels(e){const t=new Array(e).fill(void 0).map((e,t)=>({Id:`rId${t+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",Target:`worksheets/sheet${t+1}.xml`})),i=Pd([...t,{Id:`rId${e+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",Target:"theme/theme1.xml"},{Id:`rId${e+2}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",Target:"styles.xml"},{Id:`rId${e+3}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",Target:"sharedStrings.xml"}]);return ph(i)}static createDrawing(e){return ph(bh.getTemplate({sheetIndex:e}))}static createDrawingRel(e){const t=this.worksheetImageIds.get(e)||[],i=[];for(const[e,r]of t)i.push({Id:`rId${r.index+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/image${this.workbookImageIds.get(e).index+1}.${r.type}`});return ph(Pd(i))}static createVmlDrawing(e){return ph(Nd.getTemplate({sheetIndex:e}),!0)}static createVmlDrawingRel(e){const t=this.worksheetHeaderFooterImages.get(e)||[],i=[];for(let e=0;e<t.length;e++){const r=t[e],n=this.workbookImageIds.get(r.id);if(!n)continue;const{index:s,type:o}=n,a="jpg"===o?"jpeg":o;i.push({Id:`rId${e+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/image${s+1}.${a}`})}return ph(Pd(i))}static createRelationships({drawingIndex:e,vmlDrawingIndex:t,tableIndex:i}={}){if(void 0===e&&void 0===t&&void 0===i)return"";const r=[];null!=e&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",Target:`../drawings/drawing${e+1}.xml`}),null!=t&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",Target:`../drawings/vmlDrawing${t+1}.vml`}),null!=i&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table",Target:`../tables/${this.getTableNameFromIndex(i)}.xml`});const n=Pd(r);return ph(n)}static createWorksheet(e,t){return ph(Rd.getTemplate({worksheet:e,currentSheet:this.sheetNames.length-1,config:t}))}};Od.sharedStrings=new Map,Od.sheetNames=[],Od.images=new Map,Od.worksheetImages=new Map,Od.worksheetHeaderFooterImages=new Map,Od.workbookImageIds=new Map,Od.worksheetImageIds=new Map,Od.worksheetDataTables=new Map,Od.defaultTableDisplayName="AG-GRID-TABLE",Od.factoryMode=Gu.ExcelFactoryMode.SINGLE_SHEET;var Fd=Od,kd=class extends Ku.BaseGridSerializingSession{constructor(e){super(e),this.mixedStyles={},this.mixedStyleCounter=0,this.rows=[],this.config=Object.assign({},e),this.stylesByIds={},this.config.baseExcelStyles.forEach(e=>{this.stylesByIds[e.id]=e}),this.excelStyles=[...this.config.baseExcelStyles,{id:"_quotePrefix",quotePrefix:1}]}addCustomContent(e){e.forEach(e=>{const t=this.rows.length+1;let i;this.config.suppressRowOutline||null==e.outlineLevel||(i=e.outlineLevel);const r={height:dh(t,e.height||this.config.rowHeight),cells:(e.cells||[]).map((e,i)=>{var r,n,s;const o=this.addImage(t,this.columnsToExport[i],null==(r=e.data)?void 0:r.value);let a=null;e.styleId&&(a="string"==typeof e.styleId?[e.styleId]:e.styleId);const l=this.getStyleId(a);if(o)return this.createCell(l,this.getDataTypeForValue(o.value),null==o.value?"":o.value);const c=null!=(s=null==(n=e.data)?void 0:n.value)?s:"",u=this.getDataTypeForValue(c);return e.mergeAcross?this.createMergedCell(l,u,c,e.mergeAcross):this.createCell(l,u,c)}),outlineLevel:i};null!=e.collapsed&&(r.collapsed=e.collapsed),null!=e.hidden&&(r.hidden=e.hidden),this.rows.push(r)})}onNewHeaderGroupingRow(){const e=[];return this.rows.push({cells:e,height:dh(this.rows.length+1,this.config.headerRowHeight)}),{onColumn:(t,i,r,n,s)=>{const o=this.config.styleLinker({rowType:Ku.RowType.HEADER_GROUPING,rowIndex:1,value:`grouping-${i}`,columnGroup:t});e.push(nh(rh({},this.createMergedCell(this.getStyleId(o),this.getDataTypeForValue("string"),i,n)),{collapsibleRanges:s}))}}}onNewHeaderRow(){return this.onNewRow(this.onNewHeaderColumn,this.config.headerRowHeight)}onNewBodyRow(e){const t=this.onNewRow(this.onNewBodyColumn,this.config.rowHeight);return e&&this.addRowOutlineIfNecessary(e),t}prepare(e){super.prepare(e),this.columnsToExport=[...e],this.cols=e.map((e,t)=>this.convertColumnToExcel(e,t))}parse(){const e=this.rows.reduce((e,t)=>Math.max(e,t.cells.length),0);for(;this.cols.length<e;)this.cols.push(this.convertColumnToExcel(null,this.cols.length+1));const t={name:this.config.sheetName,table:{columns:this.cols,rows:this.rows}};return this.createExcel(t)}addRowOutlineIfNecessary(e){const{gos:t,suppressRowOutline:i,rowGroupExpandState:r="expanded"}=this.config;if(t.get("groupHideOpenParents")||i||null==e.level)return;const n=e.footer?1:0,s=ju._.last(this.rows);if(s.outlineLevel=e.level+n,"expanded"===r)return;const o="collapsed"===r;if(e.isExpandable()){const t=!o&&e.expanded;s.collapsed=!t}s.hidden=!!e.parent&&-1!==e.parent.level&&(o||this.isAnyParentCollapsed(e.parent))}isAnyParentCollapsed(e){for(;e&&-1!==e.level;){if(!e.expanded)return!0;e=e.parent}return!1}convertColumnToExcel(e,t){const i=this.config.columnWidth,r=e?this.extractHeaderValue(e):void 0,n=null!=r?r:"",s=!!e&&e.isFilterAllowed();if(i)return"number"==typeof i?{width:i,displayName:n,filterAllowed:s}:{width:i({column:e,index:t}),displayName:n,filterAllowed:s};if(e){const t=75;return{width:Math.max(e.getActualWidth(),t),displayName:n,filterAllowed:s}}return{displayName:n,filterAllowed:s}}onNewHeaderColumn(e,t){return i=>{const r=this.extractHeaderValue(i),n=this.config.styleLinker({rowType:Ku.RowType.HEADER,rowIndex:e,value:r,column:i});t.push(this.createCell(this.getStyleId(n),this.getDataTypeForValue("string"),r))}}onNewBodyColumn(e,t){let i=0;return(r,n,s)=>{if(i>0)return void(i-=1);const{value:o,valueFormatted:a}=this.extractRowCellValue(r,n,e,"excel",s),l=this.config.styleLinker({rowType:Ku.RowType.BODY,rowIndex:e,value:o,column:r,node:s}),c=this.getStyleId(l),u=r.getColSpan(s),h=this.addImage(e,r,o);h?t.push(this.createCell(c,this.getDataTypeForValue(h.value),null==h.value?"":h.value)):u>1?(i=u-1,t.push(this.createMergedCell(c,this.getDataTypeForValue(o),o,u-1))):t.push(this.createCell(c,this.getDataTypeForValue(o),o,a))}}onNewRow(e,t){const i=[];return this.rows.push({cells:i,height:dh(this.rows.length+1,t)}),{onColumn:e.bind(this,this.rows.length,i)()}}createExcel(e){const{excelStyles:t,config:i}=this;return Fd.createExcel(t,e,i)}getDataTypeForValue(e){return void 0===e?"empty":this.isNumerical(e)?"n":"s"}getTypeFromStyle(e,t){if(this.isFormula(t))return"f";if(e&&e.dataType)switch(e.dataType.toLocaleLowerCase()){case"formula":return"f";case"string":return"s";case"number":return"n";case"datetime":return"d";case"error":return"e";case"boolean":return"b";default:console.warn(`AG Grid: Unrecognized data type for excel export [${e.id}.dataType=${e.dataType}]`)}return null}addImage(e,t,i){if(!this.config.addImageToCell)return;const r=this.config.addImageToCell(e,t,i);return r?(Fd.addBodyImageToMap(r.image,e,t,this.columnsToExport,this.config.rowHeight),r):void 0}createCell(e,t,i,r){const n=this.getStyleById(e);!(null==n?void 0:n.dataType)&&"s"===t&&r&&(i=r);const s=this.getTypeFromStyle(n,i)||t,{value:o,escaped:a}=this.getCellValue(s,i),l=[];return n&&l.push(e),a&&l.push("_quotePrefix"),{styleId:e=this.getStyleId(l)||void 0,data:{type:s,value:o}}}createMergedCell(e,t,i,r){const n=null==i?"":i;return{styleId:this.getStyleById(e)?e:void 0,data:{type:t,value:"s"===t?Fd.getStringPosition(n).toString():i},mergeAcross:r}}getCellValue(e,t){let i=!1;if(null==t&&(e="s",t=""),"s"===e)t&&"'"===t[0]&&(i=!0,t=t.slice(1)),t=Fd.getStringPosition(t).toString();else if("f"===e)t=t.slice(1);else if("n"===e){const e=Number(t);isNaN(e)?t="":""!==t&&(t=e.toString())}return{value:t,escaped:i}}getStyleId(e){if(!e||!e.length)return null;if(1===e.length)return e[0];const t=e.join("-");return this.mixedStyles[t]||this.addNewMixedStyle(e),this.mixedStyles[t].excelID}deepCloneObject(e){return JSON.parse(JSON.stringify(e))}addNewMixedStyle(e){this.mixedStyleCounter+=1;const t=`mixedStyle${this.mixedStyleCounter}`,i={};for(const t of e)for(const e of this.excelStyles)e.id===t&&ju._.mergeDeep(i,this.deepCloneObject(e));i.id=t,i.name=t;const r=e.join("-");this.mixedStyles[r]={excelID:t,key:r,result:i},this.excelStyles.push(i),this.stylesByIds[t]=i}isFormula(e){return null!=e&&this.config.autoConvertFormulas&&e.toString().startsWith("=")}isNumerical(e){return"bigint"==typeof e||isFinite(e)&&""!==e&&!isNaN(parseFloat(e))}getStyleById(e){return null==e?null:this.stylesByIds[e]||null}},Gd=(e,t)=>{const i="xl/drawings",r=`${i}/drawing${t+1}.xml`,n=`${i}/_rels/drawing${t+1}.xml.rels`;Wu.ZipContainer.addFile(n,Fd.createDrawingRel(e)),Wu.ZipContainer.addFile(r,Fd.createDrawing(e))},Vd=(e,t)=>{const i="xl/drawings",r=`${i}/vmlDrawing${t+1}.vml`,n=`${i}/_rels/vmlDrawing${t+1}.vml.rels`;Wu.ZipContainer.addFile(r,Fd.createVmlDrawing(e)),Wu.ZipContainer.addFile(n,Fd.createVmlDrawingRel(e))},Hd=(e,t={})=>{if(!e||0===e.length)return console.warn("AG Grid: Invalid params supplied to createExcelFileForExcel() - `ExcelExportParams.data` is empty."),Fd.resetFactory(),!1;const{fontSize:i=11,author:r="AG Grid"}=t;return(()=>{Wu.ZipContainer.addFolders(["_rels/","docProps/","xl/","xl/theme/","xl/_rels/","xl/worksheets/"]);const{images:e}=Fd;if(!e.size)return;Wu.ZipContainer.addFolders(["xl/worksheets/_rels","xl/drawings/","xl/drawings/_rels","xl/media/"]);let t=0;e.forEach(e=>{const i=e[0].image[0],{base64:r,imageType:n}=i,s="jpg"===n?"jpeg":n;Wu.ZipContainer.addFile(`xl/media/image${++t}.${s}`,r,!0)})})(),(()=>{const{worksheetDataTables:e}=Fd,t=e,i=Array.from(t.keys());for(let e=0;e<i.length;e++){const r=i[e],n=t.get(r);n&&Wu.ZipContainer.addFile(`xl/tables/${n.name}.xml`,Fd.createTable(n,e))}})(),(e=>{let t=0,i=0,r=0;const{images:n,worksheetDataTables:s,worksheetImages:o,worksheetHeaderFooterImages:a}=Fd;for(let l=0;l<e.length;l++){const c=e[l];Wu.ZipContainer.addFile(`xl/worksheets/sheet${l+1}.xml`,c,!1);const u=n.size>0&&o.has(l),h=s.size>0&&s.has(l),d=n.size&&a.has(l);if(!u&&!h&&!d)continue;let p,g,f;u&&(Gd(l,t),g=t,t++),d&&(Vd(l,i),f=i,i++),h&&(p=r++);const m=`xl/worksheets/_rels/sheet${l+1}.xml.rels`;Wu.ZipContainer.addFile(m,Fd.createRelationships({tableIndex:p,drawingIndex:g,vmlDrawingIndex:f}))}})(e),((e,t,i)=>{Wu.ZipContainer.addFile("xl/workbook.xml",Fd.createWorkbook()),Wu.ZipContainer.addFile("xl/styles.xml",Fd.createStylesheet(e)),Wu.ZipContainer.addFile("xl/sharedStrings.xml",Fd.createSharedStrings()),Wu.ZipContainer.addFile("xl/theme/theme1.xml",Fd.createTheme()),Wu.ZipContainer.addFile("xl/_rels/workbook.xml.rels",Fd.createWorkbookRels(i)),Wu.ZipContainer.addFile("docProps/core.xml",Fd.createCore(t)),Wu.ZipContainer.addFile("[Content_Types].xml",Fd.createContentTypes(i)),Wu.ZipContainer.addFile("_rels/.rels",Fd.createRels())})(i,r,e.length),Fd.resetFactory(),!0},Bd=e=>{const{data:t,fontSize:i,author:r}=e,n=e.mimeType||"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";return Hd(t,{author:r,fontSize:i})?Wu.ZipContainer.getZipFile(n):Promise.resolve(void 0)},zd=e=>{const{data:t,fontSize:i,author:r}=e,n=e.mimeType||"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";if(Hd(t,{author:r,fontSize:i}))return Wu.ZipContainer.getUncompressedZipFile(n)},Ud=e=>{const{fileName:t="export.xlsx"}=e;Bd(e).then(e=>{if(e){const i="function"==typeof t?t():t;Wu.Downloader.download(i,e)}})},Wd=class extends Wu.BaseCreator{postConstruct(){this.setBeans({gridSerializer:this.gridSerializer,gos:this.gos})}getMergedParams(e){const t=this.gos.get("defaultExcelExportParams");return Object.assign({},t,e)}export(e){if(this.isExportSuppressed())return void console.warn("AG Grid: Export cancelled. Export is not allowed as per your configuration.");const t=this.getMergedParams(e),i={data:[this.getData(t)],fontSize:t.fontSize,author:t.author,mimeType:t.mimeType};this.packageCompressedFile(i).then(e=>{if(e){const{fileName:i}=t,r="function"==typeof i?i(this.gos.getGridCommonParams()):i;Wu.Downloader.download(this.getFileName(r),e)}})}exportDataAsExcel(e){this.export(e)}getDataAsExcel(e){const t=this.getMergedParams(e),i={data:[this.getData(t)],fontSize:t.fontSize,author:t.author,mimeType:t.mimeType};return this.packageFile(i)}setFactoryMode(e){Fd.factoryMode=e}getFactoryMode(){return Fd.factoryMode}getSheetDataForExcel(e){const t=this.getMergedParams(e);return this.getData(t)}getMultipleSheetsAsExcel(e){return zd(e)}exportMultipleSheetsAsExcel(e){Ud(e)}getDefaultFileExtension(){return"xlsx"}createSerializingSession(e){const{columnModel:t,valueService:i,gos:r}=this;let n;if(null!=e.sheetName){const{sheetName:t}=e,i="function"==typeof t?t(this.gos.getGridCommonParams()):t;n=String(i).substring(0,31)}else n="ag-grid";const s=nh(rh({},e),{sheetName:n,columnModel:t,valueService:i,gos:r,suppressRowOutline:e.suppressRowOutline||e.skipRowGroups,headerRowHeight:e.headerRowHeight||e.rowHeight,baseExcelStyles:this.gos.get("excelStyles")||[],styleLinker:this.styleLinker.bind(this)});return new kd(s)}styleLinker(e){const{rowType:t,rowIndex:i,value:r,column:n,columnGroup:s,node:o}=e,a=t===Wu.RowType.HEADER,l=t===Wu.RowType.HEADER_GROUPING,c=a?n:s;let u=[];if(a||l)return u.push("header"),l&&u.push("headerGroup"),c&&(u=u.concat(ku.CssClassApplier.getHeaderClassesFromColDef(c.getDefinition(),this.gos,n||null,s||null))),u;const h=this.gos.get("excelStyles"),d=["cell"];if(!h||!h.length)return d;const p=h.map(e=>e.id);return this.stylingService.processAllCellClasses(n.getDefinition(),this.gos.addGridCommonParams({value:r,data:o.data,node:o,colDef:n.getDefinition(),column:n,rowIndex:i}),e=>{p.indexOf(e)>-1&&d.push(e)}),d.sort((e,t)=>p.indexOf(e)<p.indexOf(t)?-1:1)}isExportSuppressed(){return this.gos.get("suppressExcelExport")}packageCompressedFile(e){return Bd(e)}packageFile(e){return zd(e)}};sh([(0,ku.Autowired)("columnModel")],Wd.prototype,"columnModel",2),sh([(0,ku.Autowired)("valueService")],Wd.prototype,"valueService",2),sh([(0,ku.Autowired)("stylingService")],Wd.prototype,"stylingService",2),sh([(0,ku.Autowired)("gridSerializer")],Wd.prototype,"gridSerializer",2),sh([(0,ku.Autowired)("gridOptionsService")],Wd.prototype,"gos",2),sh([ku.PostConstruct],Wd.prototype,"postConstruct",1),Wd=sh([(0,ku.Bean)("excelCreator")],Wd);var jd={version:"31.3.4",moduleName:Fu.ModuleNames.ExcelExportModule,beans:[Wd,$u.GridSerializer,$u.CsvCreator],dependantModules:[qu.CsvExportModule,_]},Kd=i(98092),$d=i(98092),qd=i(98092),Yd=i(98092),Qd=i(98092),Xd=i(98092),Zd=Object.defineProperty,Jd=Object.getOwnPropertyDescriptor,ep=Object.getOwnPropertySymbols,tp=Object.prototype.hasOwnProperty,ip=Object.prototype.propertyIsEnumerable,rp=(e,t,i)=>t in e?Zd(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,np=(e,t)=>{for(var i in t||(t={}))tp.call(t,i)&&rp(e,i,t[i]);if(ep)for(var i of ep(t))ip.call(t,i)&&rp(e,i,t[i]);return e},sp=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Jd(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Zd(t,i,s),s},op=class extends $d.Component{preConstruct(){this.setTemplate('<div class="ag-filter-toolpanel-search" role="presentation">\n                <div ref="eExpand" class="ag-filter-toolpanel-expand"></div>\n                <ag-input-text-field ref="eFilterTextField" class="ag-filter-toolpanel-search-input"></ag-input-text-field>\n            </div>')}postConstruct(){const e=this.localeService.getLocaleTextFunc();this.eFilterTextField.setAutoComplete(!1).setInputAriaLabel(e("ariaFilterColumnsInput","Filter Columns Input")).onValueChange(this.onSearchTextChanged.bind(this)),this.createExpandIcons(),this.setExpandState(0),this.addManagedListener(this.eExpand,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eventService,$d.Events.EVENT_NEW_COLUMNS_LOADED,this.showOrHideOptions.bind(this))}init(e){this.params=e,this.columnModel.isReady()&&this.showOrHideOptions()}createExpandIcons(){this.eExpand.appendChild(this.eExpandChecked=$d._.createIconNoSpan("columnSelectOpen",this.gos)),this.eExpand.appendChild(this.eExpandUnchecked=$d._.createIconNoSpan("columnSelectClosed",this.gos)),this.eExpand.appendChild(this.eExpandIndeterminate=$d._.createIconNoSpan("columnSelectIndeterminate",this.gos))}showOrHideOptions(){const e=!this.params.suppressFilterSearch,t=!this.params.suppressExpandAll,i=this.localeService.getLocaleTextFunc();this.eFilterTextField.setInputPlaceholder(i("searchOoo","Search..."));const r=this.columnModel.getAllGridColumns().some(e=>e.getOriginalParent()&&e.isFilterAllowed());$d._.setDisplayed(this.eFilterTextField.getGui(),e),$d._.setDisplayed(this.eExpand,t&&r)}onSearchTextChanged(){this.onSearchTextChangedDebounced||(this.onSearchTextChangedDebounced=$d._.debounce(()=>{this.dispatchEvent({type:"searchChanged",searchText:this.eFilterTextField.getValue()})},300)),this.onSearchTextChangedDebounced()}onExpandClicked(){const e=0===this.currentExpandState?{type:"collapseAll"}:{type:"expandAll"};this.dispatchEvent(e)}setExpandState(e){this.currentExpandState=e,$d._.setDisplayed(this.eExpandChecked,0===this.currentExpandState),$d._.setDisplayed(this.eExpandUnchecked,1===this.currentExpandState),$d._.setDisplayed(this.eExpandIndeterminate,2===this.currentExpandState)}};sp([(0,$d.Autowired)("columnModel")],op.prototype,"columnModel",2),sp([(0,$d.RefSelector)("eExpand")],op.prototype,"eExpand",2),sp([(0,$d.RefSelector)("eFilterTextField")],op.prototype,"eFilterTextField",2),sp([$d.PreConstruct],op.prototype,"preConstruct",1),sp([$d.PostConstruct],op.prototype,"postConstruct",1);var ap=class e extends Yd.Component{constructor(t,i){super(e.TEMPLATE),this.expandedCallback=i,this.expanded=!1,this.hideHeader=t}postConstruct(){this.eExpandChecked=Yd._.createIconNoSpan("columnSelectOpen",this.gos),this.eExpandUnchecked=Yd._.createIconNoSpan("columnSelectClosed",this.gos),this.eExpand.appendChild(this.eExpandChecked),this.eExpand.appendChild(this.eExpandUnchecked)}setColumn(e){this.column=e,this.eFilterName.innerText=this.columnModel.getDisplayNameForColumn(this.column,"filterToolPanel",!1)||"",this.addManagedListener(this.eFilterToolPanelHeader,"click",this.toggleExpanded.bind(this)),this.addManagedListener(this.eFilterToolPanelHeader,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(this.eventService,Yd.Events.EVENT_FILTER_OPENED,this.onFilterOpened.bind(this)),this.addInIcon("filter",this.eFilterIcon,this.column),Yd._.setDisplayed(this.eFilterIcon,this.isFilterActive(),{skipAriaHidden:!0}),Yd._.setDisplayed(this.eExpandChecked,!1),this.hideHeader?(Yd._.setDisplayed(this.eFilterToolPanelHeader,!1),this.eFilterToolPanelHeader.removeAttribute("tabindex")):this.eFilterToolPanelHeader.setAttribute("tabindex","0"),this.addManagedListener(this.column,Yd.Column.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this))}onKeyDown(e){const{key:t}=e,{ENTER:i,SPACE:r,LEFT:n,RIGHT:s}=Yd.KeyCode;t!==i&&t!==r&&t!==n&&t!==s||(e.preventDefault(),t===i||t===r?this.toggleExpanded():t===Yd.KeyCode.LEFT?this.collapse():this.expand())}getColumn(){return this.column}getColumnFilterName(){return this.columnModel.getDisplayNameForColumn(this.column,"filterToolPanel",!1)}addCssClassToTitleBar(e){this.eFilterToolPanelHeader.classList.add(e)}addInIcon(e,t,i){if(null==t)return;const r=Yd._.createIconNoSpan(e,this.gos,i);t.appendChild(r)}isFilterActive(){return this.filterManager.isFilterActive(this.column)}onFilterChanged(){Yd._.setDisplayed(this.eFilterIcon,this.isFilterActive(),{skipAriaHidden:!0}),this.dispatchEvent({type:Yd.Column.EVENT_FILTER_CHANGED})}toggleExpanded(){this.expanded?this.collapse():this.expand()}expand(){this.expanded||(this.expanded=!0,Yd._.setAriaExpanded(this.eFilterToolPanelHeader,!0),Yd._.setDisplayed(this.eExpandChecked,!0),Yd._.setDisplayed(this.eExpandUnchecked,!1),this.addFilterElement(),this.expandedCallback())}addFilterElement(e){var t;const i=Yd._.loadTemplate('<div class="ag-filter-toolpanel-instance-filter"></div>'),r=this.createManagedBean(new Yd.FilterWrapperComp(this.column,"TOOLBAR"));this.filterWrapperComp=r,r.hasFilter()&&(null==(t=r.getFilter())||t.then(t=>{this.underlyingFilter=t,t&&(i.appendChild(r.getGui()),this.agFilterToolPanelBody.appendChild(i),r.afterGuiAttached({container:"toolPanel",suppressFocus:e}))}))}collapse(){var e;this.expanded&&(this.expanded=!1,Yd._.setAriaExpanded(this.eFilterToolPanelHeader,!1),this.removeFilterElement(),Yd._.setDisplayed(this.eExpandChecked,!1),Yd._.setDisplayed(this.eExpandUnchecked,!0),null==(e=this.filterWrapperComp)||e.afterGuiDetached(),this.destroyBean(this.filterWrapperComp),this.expandedCallback())}removeFilterElement(){Yd._.clearElement(this.agFilterToolPanelBody)}isExpanded(){return this.expanded}refreshFilter(e){var t;if(!this.expanded)return;const i=this.underlyingFilter;i&&(e?"function"==typeof i.refreshVirtualList&&i.refreshVirtualList():null==(t=i.afterGuiDetached)||t.call(i))}onFilterOpened(e){"COLUMN_MENU"===e.source&&e.column===this.column&&this.expanded&&this.collapse()}};ap.TEMPLATE='\n        <div class="ag-filter-toolpanel-instance">\n            <div class="ag-filter-toolpanel-header ag-filter-toolpanel-instance-header" ref="eFilterToolPanelHeader" role="button" aria-expanded="false">\n                <div ref="eExpand" class="ag-filter-toolpanel-expand"></div>\n                <span ref="eFilterName" class="ag-header-cell-text"></span>\n                <span ref="eFilterIcon" class="ag-header-icon ag-filter-icon ag-filter-toolpanel-instance-header-icon" aria-hidden="true"></span>\n            </div>\n            <div class="ag-filter-toolpanel-instance-body ag-filter" ref="agFilterToolPanelBody"></div>\n        </div>',sp([(0,Yd.RefSelector)("eFilterToolPanelHeader")],ap.prototype,"eFilterToolPanelHeader",2),sp([(0,Yd.RefSelector)("eFilterName")],ap.prototype,"eFilterName",2),sp([(0,Yd.RefSelector)("agFilterToolPanelBody")],ap.prototype,"agFilterToolPanelBody",2),sp([(0,Yd.RefSelector)("eFilterIcon")],ap.prototype,"eFilterIcon",2),sp([(0,Yd.RefSelector)("eExpand")],ap.prototype,"eExpand",2),sp([(0,Yd.Autowired)("filterManager")],ap.prototype,"filterManager",2),sp([(0,Yd.Autowired)("columnModel")],ap.prototype,"columnModel",2),sp([Yd.PostConstruct],ap.prototype,"postConstruct",1);var lp=ap,cp=class e extends Qd.Component{constructor(e,t,i,r,n){super(),this.columnGroup=e,this.childFilterComps=t,this.depth=r,this.expandedCallback=i,this.showingColumn=n}preConstruct(){this.setTemplate(e.TEMPLATE,{filterGroupComp:{cssIdentifier:"filter-toolpanel",direction:"vertical"}})}init(){this.setGroupTitle(),this.filterGroupComp.setAlignItems("stretch"),this.filterGroupComp.addCssClass(`ag-filter-toolpanel-group-level-${this.depth}`),this.filterGroupComp.addCssClassToTitleBar(`ag-filter-toolpanel-group-level-${this.depth}-header`),this.childFilterComps.forEach(e=>{this.filterGroupComp.addItem(e),e.addCssClassToTitleBar(`ag-filter-toolpanel-group-level-${this.depth+1}-header`)}),this.refreshFilterClass(),this.addExpandCollapseListeners(),this.addFilterChangedListeners(),this.setupTooltip(),this.addInIcon("filter")}setupTooltip(){if(!this.showingColumn)return;let e;"whenTruncated"===this.gos.get("tooltipShowMode")&&(e=()=>{const e=this.filterGroupComp.getGui().querySelector(".ag-group-title");return!e||e.scrollWidth>e.clientWidth});const t=()=>{const t=this.columnGroup.getColDef().headerTooltip;this.setTooltip({newTooltipText:t,location:"filterToolPanelColumnGroup",shouldDisplayTooltip:e})};t(),this.addManagedListener(this.eventService,Qd.Events.EVENT_NEW_COLUMNS_LOADED,t)}getTooltipParams(){const e=super.getTooltipParams();return e.location="filterToolPanelColumnGroup",e}addCssClassToTitleBar(e){this.filterGroupComp.addCssClassToTitleBar(e)}refreshFilters(t){this.childFilterComps.forEach(i=>{i instanceof e?i.refreshFilters(t):i.refreshFilter(t)})}isColumnGroup(){return this.columnGroup instanceof Qd.ProvidedColumnGroup}isExpanded(){return this.filterGroupComp.isExpanded()}getChildren(){return this.childFilterComps}getFilterGroupName(){return this.filterGroupName?this.filterGroupName:""}getFilterGroupId(){return this.columnGroup.getId()}hideGroupItem(e,t){this.filterGroupComp.hideItem(e,t)}hideGroup(e){this.setDisplayed(!e)}addInIcon(e){const t=Qd._.createIconNoSpan(e,this.gos);t&&t.classList.add("ag-filter-toolpanel-group-instance-header-icon"),this.filterGroupComp.addTitleBarWidget(t)}forEachToolPanelFilterChild(e){this.childFilterComps.forEach(t=>{t instanceof lp&&e(t)})}addExpandCollapseListeners(){const e=this.isColumnGroup()?()=>this.expandedCallback():()=>this.forEachToolPanelFilterChild(e=>e.expand()),t=this.isColumnGroup()?()=>this.expandedCallback():()=>this.forEachToolPanelFilterChild(e=>e.collapse());this.addManagedListener(this.filterGroupComp,Qd.AgGroupComponent.EVENT_EXPANDED,e),this.addManagedListener(this.filterGroupComp,Qd.AgGroupComponent.EVENT_COLLAPSED,t)}getColumns(){return this.columnGroup instanceof Qd.ProvidedColumnGroup?this.columnGroup.getLeafColumns():[this.columnGroup]}addFilterChangedListeners(){this.getColumns().forEach(e=>{this.addManagedListener(e,Qd.Column.EVENT_FILTER_CHANGED,()=>this.refreshFilterClass())}),this.columnGroup instanceof Qd.ProvidedColumnGroup||this.addManagedListener(this.eventService,Qd.Events.EVENT_FILTER_OPENED,this.onFilterOpened.bind(this))}refreshFilterClass(){const e=this.getColumns();this.filterGroupComp.addOrRemoveCssClass("ag-has-filter",e.some(e=>e.isFilterActive()))}onFilterOpened(e){"COLUMN_MENU"===e.source&&e.column===this.columnGroup&&this.isExpanded()&&this.collapse()}expand(){this.filterGroupComp.toggleGroupExpand(!0)}collapse(){this.filterGroupComp.toggleGroupExpand(!1)}setGroupTitle(){this.filterGroupName=this.columnGroup instanceof Qd.ProvidedColumnGroup?this.getColumnGroupName(this.columnGroup):this.getColumnName(this.columnGroup),this.filterGroupComp.setTitle(this.filterGroupName||"")}getColumnGroupName(e){return this.columnModel.getDisplayNameForProvidedColumnGroup(null,e,"filterToolPanel")}getColumnName(e){return this.columnModel.getDisplayNameForColumn(e,"filterToolPanel",!1)}destroyFilters(){this.childFilterComps=this.destroyBeans(this.childFilterComps),Qd._.clearElement(this.getGui())}destroy(){this.destroyFilters(),super.destroy()}};cp.TEMPLATE='<div class="ag-filter-toolpanel-group-wrapper">\n            <ag-group-component ref="filterGroupComp"></ag-group-component>\n        </div>',sp([(0,Qd.RefSelector)("filterGroupComp")],cp.prototype,"filterGroupComp",2),sp([(0,Qd.Autowired)("columnModel")],cp.prototype,"columnModel",2),sp([Qd.PreConstruct],cp.prototype,"preConstruct",1),sp([Qd.PostConstruct],cp.prototype,"init",1);var up=cp,hp=class e extends qd.Component{constructor(){super(e.TEMPLATE),this.initialised=!1,this.hasLoadedInitialState=!1,this.isInitialState=!1,this.filterGroupComps=[],this.suppressOnColumnsChanged=!1,this.onColumnsChangedPending=!1}init(e){this.initialised=!0;const t=this.gos.addGridCommonParams({suppressExpandAll:!1,suppressFilterSearch:!1,suppressSyncLayoutWithGrid:!1});qd._.mergeDeep(t,e),this.params=t,this.params.suppressSyncLayoutWithGrid||this.addManagedListener(this.eventService,qd.Events.EVENT_COLUMN_MOVED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,qd.Events.EVENT_NEW_COLUMNS_LOADED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,qd.Events.EVENT_TOOL_PANEL_VISIBLE_CHANGED,e=>{"filters"===e.key&&this.refreshFilters(e.visible)}),this.addManagedListener(this.eventService,qd.Events.EVENT_DRAG_STARTED,()=>{this.suppressOnColumnsChanged=!0}),this.addManagedListener(this.eventService,qd.Events.EVENT_DRAG_STOPPED,()=>{this.suppressOnColumnsChanged=!1,this.onColumnsChangedPending&&(this.onColumnsChangedPending=!1,this.onColumnsChanged())}),this.columnModel.isReady()&&this.onColumnsChanged()}onColumnsChanged(){if(this.suppressOnColumnsChanged)return void(this.onColumnsChangedPending=!0);const e=this.columnModel.isPivotMode();this.params.suppressSyncLayoutWithGrid||e?this.buildTreeFromProvidedColumnDefs():this.syncFilterLayout(),this.refreshAriaLabel()}syncFilterLayout(){this.toolPanelColDefService.syncLayoutWithGrid(this.setFiltersLayout.bind(this)),this.refreshAriaLabel()}buildTreeFromProvidedColumnDefs(){const e=this.columnModel.getPrimaryColumnTree();this.recreateFilters(e)}setFiltersLayout(e){const t=this.toolPanelColDefService.createColumnTree(e);this.recreateFilters(t)}recreateFilters(e){const t=this.gos.getActiveDomElement();this.hasLoadedInitialState||(this.hasLoadedInitialState=!0,this.isInitialState=!!this.params.initialState);const i=this.getExpansionState();this.destroyFilters(),this.filterGroupComps=this.recursivelyAddComps(e,0,i);const r=this.filterGroupComps.length;r&&(this.filterGroupComps.forEach(e=>this.appendChild(e)),this.setFirstAndLastVisible(0,r-1)),qd._.exists(this.searchFilterText)&&this.searchFilters(this.searchFilterText),this.fireExpandedEvent(),this.getGui().contains(t)&&t.focus(),this.isInitialState=!1,this.refreshAriaLabel()}recursivelyAddComps(e,t,i){return qd._.flatten(e.map(e=>{if(e instanceof qd.ProvidedColumnGroup)return qd._.flatten(this.recursivelyAddFilterGroupComps(e,t,i));const r=e;if(!this.shouldDisplayFilter(r))return[];const n=new lp(0===t,()=>this.onFilterExpanded());if(this.createBean(n),n.setColumn(r),i.get(r.getId())&&n.expand(),t>0)return n;const s=this.createBean(new up(r,[n],this.onGroupExpanded.bind(this),t,!0));return s.addCssClassToTitleBar("ag-filter-toolpanel-header"),i.get(s.getFilterGroupId())||s.collapse(),s}))}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaFilterPanelList","Filter List"),i=e("filters","Filters"),r=this.getGui().querySelectorAll(".ag-filter-toolpanel-group-item:not(.ag-filter-toolpanel-group-wrapper, .ag-hidden)").length;qd._.setAriaLabel(this.getAriaElement(),`${t} ${r} ${i}`)}recursivelyAddFilterGroupComps(e,t,i){if(!this.filtersExistInChildren(e.getChildren()))return;const r=e.getColGroupDef();if(r&&r.suppressFiltersToolPanel)return[];const n=e.isPadding()?t:t+1,s=qd._.flatten(this.recursivelyAddComps(e.getChildren(),n,i));if(e.isPadding())return s;const o=new up(e,s,this.onGroupExpanded.bind(this),t,!1);this.createBean(o),o.addCssClassToTitleBar("ag-filter-toolpanel-header");const a=i.get(o.getFilterGroupId());return(this.isInitialState&&!a||!1===a)&&o.collapse(),[o]}filtersExistInChildren(e){return e.some(e=>e instanceof qd.ProvidedColumnGroup?this.filtersExistInChildren(e.getChildren()):this.shouldDisplayFilter(e))}shouldDisplayFilter(e){const t=e.getColDef()&&e.getColDef().suppressFiltersToolPanel;return e.isFilterAllowed()&&!t}getExpansionState(){const e=new Map;if(this.isInitialState){const{expandedColIds:t,expandedGroupIds:i}=this.params.initialState;return t.forEach(t=>e.set(t,!0)),i.forEach(t=>e.set(t,!0)),e}const t=i=>{e.set(i.getFilterGroupId(),i.isExpanded()),i.getChildren().forEach(i=>{i instanceof up?t(i):e.set(i.getColumn().getId(),i.isExpanded())})};return this.filterGroupComps.forEach(t),e}refresh(){}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}expandFilterGroups(e,t){const i=[],r=n=>{const s=n.getFilterGroupId();(!t||qd._.includes(t,s))&&(e&&n.isColumnGroup()?n.expand():n.collapse(),i.push(s)),n.getChildren().forEach(e=>{e instanceof up&&r(e)})};if(this.filterGroupComps.forEach(r),this.onGroupExpanded(),t){const e=t.filter(e=>i.indexOf(e)<0);e.length>0&&console.warn("AG Grid: unable to find groups for these supplied groupIds:",e)}}expandFilters(e,t){const i=[],r=n=>{if(n instanceof up){let t=!1;return n.getChildren().forEach(i=>{r(i)&&(e?(n.expand(),t=!0):n.isColumnGroup()||n.collapse())}),t}const s=n.getColumn().getColId(),o=!t||qd._.includes(t,s);return o&&(e?n.expand():n.collapse(),i.push(s)),o};if(this.filterGroupComps.forEach(r),this.onGroupExpanded(),t){const e=t.filter(e=>i.indexOf(e)<0);e.length>0&&console.warn("AG Grid: unable to find columns for these supplied colIds:",e)}}onGroupExpanded(){this.fireExpandedEvent()}onFilterExpanded(){this.dispatchEvent({type:"filterExpanded"})}fireExpandedEvent(){let e=0,t=0;const i=r=>{r.isColumnGroup()&&(r.isExpanded()?e++:t++,r.getChildren().forEach(e=>{e instanceof up&&i(e)}))};let r;this.filterGroupComps.forEach(i),r=e>0&&t>0?2:t>0?1:0,this.dispatchEvent({type:"groupExpanded",state:r})}performFilterSearch(e){this.searchFilterText=qd._.exists(e)?e.toLowerCase():null,this.searchFilters(this.searchFilterText)}searchFilters(e){const t=t=>!qd._.exists(e)||-1!==t.toLowerCase().indexOf(e),i=(e,r)=>{if(!(e instanceof up))return t(e.getColumnFilterName()||"");const n=e.getChildren(),s=t(e.getFilterGroupName()),o=r||s;if(o){e.hideGroup(!1);for(let t=0;t<n.length;t++)i(n[t],o),e.hideGroupItem(!1,t);return!0}let a=!1;return n.forEach((t,n)=>{const s=i(t,r);e.hideGroupItem(!s,n),s&&(a=!0)}),e.hideGroup(!a),a};let r,n;this.filterGroupComps.forEach((e,t)=>{i(e,!1),void 0===r?e.containsCssClass("ag-hidden")||(r=t,n=t):e.containsCssClass("ag-hidden")||n===t||(n=t)}),this.setFirstAndLastVisible(r,n),this.refreshAriaLabel()}setFirstAndLastVisible(e,t){this.filterGroupComps.forEach((i,r)=>{i.removeCssClass("ag-first-group-visible"),i.removeCssClass("ag-last-group-visible"),r===e&&i.addCssClass("ag-first-group-visible"),r===t&&i.addCssClass("ag-last-group-visible")})}refreshFilters(e){this.filterGroupComps.forEach(t=>t.refreshFilters(e))}getExpandedFiltersAndGroups(){const e=[],t=new Set,i=r=>{if(r instanceof up){r.getChildren().forEach(e=>i(e));const n=r.getFilterGroupId();r.isExpanded()&&!t.has(n)&&e.push(n)}else r.isExpanded()&&t.add(r.getColumn().getColId())};return this.filterGroupComps.forEach(i),{expandedGroupIds:e,expandedColIds:Array.from(t)}}destroyFilters(){this.filterGroupComps=this.destroyBeans(this.filterGroupComps),qd._.clearElement(this.getGui())}destroy(){this.destroyFilters(),super.destroy()}};hp.TEMPLATE='<div class="ag-filter-list-panel"></div>',sp([(0,qd.Autowired)("toolPanelColDefService")],hp.prototype,"toolPanelColDefService",2),sp([(0,qd.Autowired)("columnModel")],hp.prototype,"columnModel",2);var dp=hp,pp=class e extends Xd.Component{constructor(){super(e.TEMPLATE),this.initialised=!1,this.listenerDestroyFuncs=[]}init(e){this.initialised&&(this.listenerDestroyFuncs.forEach(e=>e()),this.listenerDestroyFuncs=[]),this.initialised=!0;const t=this.gos.addGridCommonParams({suppressExpandAll:!1,suppressFilterSearch:!1,suppressSyncLayoutWithGrid:!1});this.params=np(np({},t),e),this.filtersToolPanelHeaderPanel.init(this.params),this.filtersToolPanelListPanel.init(this.params);const i=this.params.suppressExpandAll,r=this.params.suppressFilterSearch;i&&r&&this.filtersToolPanelHeaderPanel.setDisplayed(!1),this.listenerDestroyFuncs.push(this.addManagedListener(this.filtersToolPanelHeaderPanel,"expandAll",this.onExpandAll.bind(this)),this.addManagedListener(this.filtersToolPanelHeaderPanel,"collapseAll",this.onCollapseAll.bind(this)),this.addManagedListener(this.filtersToolPanelHeaderPanel,"searchChanged",this.onSearchChanged.bind(this)),this.addManagedListener(this.filtersToolPanelListPanel,"filterExpanded",this.onFilterExpanded.bind(this)),this.addManagedListener(this.filtersToolPanelListPanel,"groupExpanded",this.onGroupExpanded.bind(this)))}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}onExpandAll(){this.filtersToolPanelListPanel.expandFilterGroups(!0)}onCollapseAll(){this.filtersToolPanelListPanel.expandFilterGroups(!1)}onSearchChanged(e){this.filtersToolPanelListPanel.performFilterSearch(e.searchText)}setFilterLayout(e){this.filtersToolPanelListPanel.setFiltersLayout(e)}onFilterExpanded(){this.params.onStateUpdated()}onGroupExpanded(e){this.filtersToolPanelHeaderPanel.setExpandState(e.state),this.params.onStateUpdated()}expandFilterGroups(e){this.filtersToolPanelListPanel.expandFilterGroups(!0,e)}collapseFilterGroups(e){this.filtersToolPanelListPanel.expandFilterGroups(!1,e)}expandFilters(e){this.filtersToolPanelListPanel.expandFilters(!0,e)}collapseFilters(e){this.filtersToolPanelListPanel.expandFilters(!1,e)}syncLayoutWithGrid(){this.filtersToolPanelListPanel.syncFilterLayout()}refresh(e){return this.init(e),!0}getState(){return this.filtersToolPanelListPanel.getExpandedFiltersAndGroups()}destroy(){super.destroy()}};pp.TEMPLATE='<div class="ag-filter-toolpanel">\n            <ag-filters-tool-panel-header ref="filtersToolPanelHeaderPanel"></ag-filters-tool-panel-header>\n            <ag-filters-tool-panel-list ref="filtersToolPanelListPanel"></ag-filters-tool-panel-list>\n         </div>',sp([(0,Xd.RefSelector)("filtersToolPanelHeaderPanel")],pp.prototype,"filtersToolPanelHeaderPanel",2),sp([(0,Xd.RefSelector)("filtersToolPanelListPanel")],pp.prototype,"filtersToolPanelListPanel",2);var gp=pp,fp={version:"31.3.4",moduleName:Kd.ModuleNames.FiltersToolPanelModule,beans:[],agStackComponents:[{componentName:"AgFiltersToolPanelHeader",componentClass:op},{componentName:"AgFiltersToolPanelList",componentClass:dp}],userComponents:[{componentName:"agFiltersToolPanel",componentClass:gp}],dependantModules:[Xc,_]},mp=i(98092),vp=i(98092),Cp=i(98092),yp=Object.defineProperty,wp=Object.getOwnPropertyDescriptor,Sp=Object.getOwnPropertySymbols,bp=Object.prototype.hasOwnProperty,Ep=Object.prototype.propertyIsEnumerable,Ap=(e,t,i)=>t in e?yp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Tp=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?wp(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&yp(t,i,s),s},Mp=class extends Cp.BeanStub{constructor(){super(...arguments),this.loadRowDataVersion=0}init(e,t){this.params=t,this.comp=e,null!=t.pinned||(this.setAutoHeightClasses(),this.setupRefreshStrategy(),this.addThemeToDetailGrid(),this.createDetailGrid(),this.loadRowData(),this.addManagedListener(this.eventService,Cp.Events.EVENT_FULL_WIDTH_ROW_FOCUSED,this.onFullWidthRowFocused.bind(this)))}onFullWidthRowFocused(e){const t=this.params,i={rowIndex:t.node.rowIndex,rowPinned:t.node.rowPinned},r={rowIndex:e.rowIndex,rowPinned:e.rowPinned};this.rowPositionUtils.sameRow(i,r)&&this.focusService.focusInto(this.comp.getGui(),e.fromBelow)}setAutoHeightClasses(){const e=this.gos.get("detailRowAutoHeight"),t=e?"ag-details-row-auto-height":"ag-details-row-fixed-height",i=e?"ag-details-grid-auto-height":"ag-details-grid-fixed-height";this.comp.addOrRemoveCssClass(t,!0),this.comp.addOrRemoveDetailGridCssClass(i,!0)}setupRefreshStrategy(){const e=this.params.refreshStrategy;"everything"==e||"nothing"==e||"rows"==e?this.refreshStrategy=e:(null!=e&&console.warn("AG Grid: invalid cellRendererParams.refreshStrategy = '"+e+"' supplied, defaulting to refreshStrategy = 'rows'."),this.refreshStrategy="rows")}addThemeToDetailGrid(){const{theme:e}=this.environment.getTheme();e&&this.comp.addOrRemoveDetailGridCssClass(e,!0)}createDetailGrid(){if(Cp._.missing(this.params.detailGridOptions))return void console.warn("AG Grid: could not find detail grid options for master detail, please set gridOptions.detailCellRendererParams.detailGridOptions");const e=this.gos.get("detailRowAutoHeight"),t=((e,t)=>{for(var i in t||(t={}))bp.call(t,i)&&Ap(e,i,t[i]);if(Sp)for(var i of Sp(t))Ep.call(t,i)&&Ap(e,i,t[i]);return e})({},this.params.detailGridOptions);e&&(t.domLayout="autoHeight"),this.comp.setDetailGrid(t)}registerDetailWithMaster(e,t){const i=this.params.node.id,r=this.params.api,n={id:i,api:e,columnApi:t},s=this.params.node;r.isDestroyed()||(r.addDetailGridInfo(i,n),s.detailGridInfo=n,this.addDestroyFunc(()=>{s.detailGridInfo===n&&(r.isDestroyed()||r.removeDetailGridInfo(i),s.detailGridInfo=null)}))}loadRowData(){var e,t,i;this.loadRowDataVersion++;const r=this.loadRowDataVersion;if("serverSide"===(null==(e=this.params.detailGridOptions)?void 0:e.rowModelType))return void(null==(i=null==(t=this.params.node.detailGridInfo)?void 0:t.api)||i.refreshServerSide({purge:!0}));const n=this.params.getDetailRowData;n?n({node:this.params.node,data:this.params.node.data,successCallback:e=>{this.loadRowDataVersion===r&&this.comp.setRowData(e)},context:this.gos.getGridCommonParams().context}):console.warn("AG Grid: could not find getDetailRowData for master / detail, please set gridOptions.detailCellRendererParams.getDetailRowData")}refresh(){const e=!0;switch(this.refreshStrategy){case"nothing":return e;case"everything":return!1}return this.loadRowData(),e}};Tp([(0,Cp.Autowired)("rowPositionUtils")],Mp.prototype,"rowPositionUtils",2),Tp([(0,Cp.Autowired)("focusService")],Mp.prototype,"focusService",2);var Rp=class e extends vp.Component{init(e){this.params=e,this.selectAndSetTemplate();const t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),addOrRemoveDetailGridCssClass:(e,t)=>this.eDetailGrid.classList.toggle(e,t),setDetailGrid:e=>this.setDetailGrid(e),setRowData:e=>this.setRowData(e),getGui:()=>this.eDetailGrid};this.ctrl=this.createManagedBean(new Mp),this.ctrl.init(t,e)}refresh(){return this.ctrl&&this.ctrl.refresh()}destroy(){super.destroy()}selectAndSetTemplate(){if(this.params.pinned)return void this.setTemplate('<div class="ag-details-row"></div>');const t=()=>{this.setTemplate(e.TEMPLATE)};if(vp._.missing(this.params.template))t();else if("string"==typeof this.params.template)this.setTemplate(this.params.template);else if("function"==typeof this.params.template){const e=(0,this.params.template)(this.params);this.setTemplate(e)}else console.warn("AG Grid: detailCellRendererParams.template should be function or string"),t();null==this.eDetailGrid&&console.warn('AG Grid: reference to eDetailGrid was missing from the details template. Please add ref="eDetailGrid" to the template.')}setDetailGrid(e){if(!this.eDetailGrid)return;const t=this.context.getBean("agGridReact"),i=t?vp._.cloneObject(t):void 0,r=this.context.getBean("frameworkComponentWrapper"),n=this.getFrameworkOverrides(),s=(0,vp.createGrid)(this.eDetailGrid,e,{frameworkOverrides:n,providedBeanInstances:{agGridReact:i,frameworkComponentWrapper:r},modules:vp.ModuleRegistry.__getGridRegisteredModules(this.params.api.getGridId())});this.detailApi=s,this.ctrl.registerDetailWithMaster(s,new vp.ColumnApi(s)),this.addDestroyFunc(()=>{null==s||s.destroy()})}setRowData(e){this.detailApi&&this.detailApi.setGridOption("rowData",e)}};Rp.TEMPLATE='<div class="ag-details-row" role="gridcell">\n            <div ref="eDetailGrid" class="ag-details-grid" role="presentation"></div>\n        </div>',Tp([(0,vp.RefSelector)("eDetailGrid")],Rp.prototype,"eDetailGrid",2);var _p=Rp,Pp={version:"31.3.4",moduleName:mp.ModuleNames.MasterDetailModule,beans:[],userComponents:[{componentName:"agDetailCellRenderer",componentClass:_p}],controllers:[{controllerName:"detailCellRenderer",controllerClass:Mp}],dependantModules:[_]},xp=i(98092),Dp=i(98092),Ip=i(98092),Lp=i(98092),Np=i(98092),Op=i(98092),Fp=i(98092),kp=i(98092),Gp=Object.defineProperty,Vp=Object.defineProperties,Hp=Object.getOwnPropertyDescriptor,Bp=Object.getOwnPropertyDescriptors,zp=Object.getOwnPropertySymbols,Up=Object.prototype.hasOwnProperty,Wp=Object.prototype.propertyIsEnumerable,jp=(e,t,i)=>t in e?Gp(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Kp=(e,t)=>{for(var i in t||(t={}))Up.call(t,i)&&jp(e,i,t[i]);if(zp)for(var i of zp(t))Wp.call(t,i)&&jp(e,i,t[i]);return e},$p=(e,t)=>Vp(e,Bp(t)),qp=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Hp(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Gp(t,i,s),s},Yp=class extends Dp.BeanStub{hideActiveMenu(){this.destroyBean(this.activeMenu)}showMenuAfterMouseEvent(e,t,i,r){const n=r?"filterMenuTab":void 0;this.showMenu(e,r=>{var s;const o=r.getGui();this.popupService.positionPopupUnderMouseEvent({type:i,column:e,mouseEvent:t,ePopup:o}),n&&(null==(s=r.showTab)||s.call(r,n)),this.dispatchVisibleChangedEvent(!0,!1,e,n)},i,n,void 0,t.target)}showMenuAfterButtonClick(e,t,i,r){let n=-1,s="left";this.gos.get("enableRtl")&&(n=1,s="right");const o=r?"filterMenuTab":void 0,a=o?[o]:void 0,l=this.menuService.isLegacyMenuEnabled();let c=(l?9:4)*n,u=l?-23:4;this.showMenu(e,r=>{var n;const a=r.getGui();this.popupService.positionPopupByComponent({type:i,column:e,eventSource:t,ePopup:a,alignSide:s,nudgeX:c,nudgeY:u,position:"under",keepWithinBounds:!0}),o&&(null==(n=r.showTab)||n.call(r,o)),this.dispatchVisibleChangedEvent(!0,!1,e,o)},i,o,a,t)}showMenu(e,t,i,r,n,s){var o;const{menu:a,eMenuGui:l,anchorToElement:c,restoreFocusParams:u}=this.getMenuParams(e,n,s),h=[];h.push(t=>{const i=a.getGui();this.destroyBean(a),e&&(e.setMenuVisible(!1,"contextMenu"),this.menuUtils.restoreFocusOnClose(u,i,t))});const d=this.localeService.getLocaleTextFunc();if(this.popupService.addPopup({modal:!0,eChild:l,closeOnEsc:!0,closedCallback:t=>{h.forEach(e=>e(t)),this.dispatchVisibleChangedEvent(!1,!1,e,r)},afterGuiAttached:e=>a.afterGuiAttached(Object.assign({},{container:i},e)),positionCallback:r?()=>t(a):void 0,ariaLabel:d("ariaLabelColumnMenu","Column Menu")}),r||(null==(o=a.showTabBasedOnPreviousSelection)||o.call(a),t(a)),this.menuService.isColumnMenuAnchoringEnabled()){const t=this.popupService.setPopupPositionRelatedToElement(l,c);t&&e&&this.addStopAnchoring(t,e,h)}a.addEventListener(Xp.EVENT_TAB_SELECTED,t=>{this.dispatchVisibleChangedEvent(!1,!0,e),this.lastSelectedTab=t.key,this.dispatchVisibleChangedEvent(!0,!0,e)}),null==e||e.setMenuVisible(!0,"contextMenu"),this.activeMenu=a,a.addEventListener(Dp.BeanStub.EVENT_DESTROYED,()=>{this.activeMenu===a&&(this.activeMenu=null)})}addStopAnchoring(e,t,i){e.then(e=>{t.addEventListener("leftChanged",e),t.addEventListener("visibleChanged",e),i.push(()=>{t.removeEventListener("leftChanged",e),t.removeEventListener("visibleChanged",e)})})}getMenuParams(e,t,i){const r={column:e,headerPosition:this.focusService.getFocusedHeader(),columnIndex:this.columnModel.getAllDisplayedColumns().indexOf(e),eventSource:i},n=this.createMenu(e,r,t,i);return{menu:n,eMenuGui:n.getGui(),anchorToElement:i||this.ctrlsService.getGridBodyCtrl().getGui(),restoreFocusParams:r}}createMenu(e,t,i,r){return this.menuService.isLegacyMenuEnabled()?this.createBean(new Xp(e,t,this.lastSelectedTab,i,r)):this.createBean(new Zp(e,t,r))}dispatchVisibleChangedEvent(e,t,i,r){var n,s;const o={type:Dp.Events.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:t,key:null!=(s=null!=(n=this.lastSelectedTab)?n:r)?s:this.menuService.isLegacyMenuEnabled()?Xp.TAB_GENERAL:"columnMenu",column:null!=i?i:null};this.eventService.dispatchEvent(o)}isMenuEnabled(e){var t;if(!this.menuService.isLegacyMenuEnabled())return!0;const i=!this.filterManager.isFilterAllowed(e),r=null!=(t=e.getColDef().menuTabs)?t:Xp.TABS_DEFAULT;return(i&&r.includes(Xp.TAB_FILTER)?r.length-1:r.length)>0}showMenuAfterContextMenuEvent(e,t,i){this.menuUtils.onContextMenu(t,i,t=>(this.showMenuAfterMouseEvent(e,t,"columnMenu"),!0))}};qp([(0,Dp.Autowired)("popupService")],Yp.prototype,"popupService",2),qp([(0,Dp.Autowired)("focusService")],Yp.prototype,"focusService",2),qp([(0,Dp.Autowired)("ctrlsService")],Yp.prototype,"ctrlsService",2),qp([(0,Dp.Autowired)("columnModel")],Yp.prototype,"columnModel",2),qp([(0,Dp.Autowired)("filterManager")],Yp.prototype,"filterManager",2),qp([(0,Dp.Autowired)("menuUtils")],Yp.prototype,"menuUtils",2),qp([(0,Dp.Autowired)("menuService")],Yp.prototype,"menuService",2),Yp=qp([(0,Dp.Bean)("enterpriseMenuFactory")],Yp);var Qp=class e extends Dp.BeanStub{constructor(t,i,r,n,s){super(),this.column=t,this.restoreFocusParams=i,this.initialSelection=r,this.restrictTo=n,this.sourceElement=s,this.tabFactories={},this.includeChecks={},this.tabFactories[e.TAB_GENERAL]=this.createMainPanel.bind(this),this.tabFactories[e.TAB_FILTER]=this.createFilterPanel.bind(this),this.tabFactories[e.TAB_COLUMNS]=this.createColumnsPanel.bind(this),this.includeChecks[e.TAB_GENERAL]=()=>!0,this.includeChecks[e.TAB_FILTER]=()=>!!t&&this.filterManager.isFilterAllowed(t),this.includeChecks[e.TAB_COLUMNS]=()=>!0}init(){const e=this.getTabsToCreate().map(e=>this.createTab(e));this.tabbedLayout=new Dp.TabbedLayout({items:e,cssClass:"ag-menu",onActiveItemClicked:this.onHidePopup.bind(this),onItemClicked:this.onTabItemClicked.bind(this)}),this.createBean(this.tabbedLayout),this.mainMenuList&&this.mainMenuList.setParentComponent(this.tabbedLayout),this.addDestroyFunc(()=>this.destroyBean(this.tabbedLayout))}getTabsToCreate(){var t,i;return this.restrictTo?this.restrictTo:(null!=(i=null==(t=this.column)?void 0:t.getColDef().menuTabs)?i:e.TABS_DEFAULT).filter(e=>this.isValidMenuTabItem(e)).filter(e=>this.isNotSuppressed(e)).filter(e=>this.isModuleLoaded(e))}isModuleLoaded(t){return t!==e.TAB_COLUMNS||Dp.ModuleRegistry.__isRegistered(Dp.ModuleNames.ColumnsToolPanelModule,this.context.getGridId())}isValidMenuTabItem(t){let i=!0,r=e.TABS_DEFAULT;return null!=this.restrictTo&&(i=this.restrictTo.indexOf(t)>-1,r=this.restrictTo),i=i&&e.TABS_DEFAULT.indexOf(t)>-1,i||console.warn(`AG Grid: Trying to render an invalid menu item '${t}'. Check that your 'menuTabs' contains one of [${r}]`),i}isNotSuppressed(e){return this.includeChecks[e]()}createTab(e){return this.tabFactories[e]()}showTabBasedOnPreviousSelection(){this.showTab(this.initialSelection)}showTab(t){this.tabItemColumns&&t===e.TAB_COLUMNS?this.tabbedLayout.showItem(this.tabItemColumns):this.tabItemFilter&&t===e.TAB_FILTER?this.tabbedLayout.showItem(this.tabItemFilter):this.tabItemGeneral&&t===e.TAB_GENERAL?this.tabbedLayout.showItem(this.tabItemGeneral):this.tabbedLayout.showFirstItem()}onTabItemClicked(t){let i=null;switch(t.item){case this.tabItemColumns:i=e.TAB_COLUMNS;break;case this.tabItemFilter:i=e.TAB_FILTER;break;case this.tabItemGeneral:i=e.TAB_GENERAL}i&&this.activateTab(i)}activateTab(t){const i={type:e.EVENT_TAB_SELECTED,key:t};this.dispatchEvent(i)}createMainPanel(){return this.mainMenuList=this.columnMenuFactory.createMenu(this,this.column,()=>{var e;return null!=(e=this.sourceElement)?e:this.getGui()}),this.mainMenuList.addEventListener(Dp.AgMenuItemComponent.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.tabItemGeneral={title:Dp._.createIconNoSpan("menu",this.gos,this.column),titleLabel:e.TAB_GENERAL.replace("MenuTab",""),bodyPromise:Dp.AgPromise.resolve(this.mainMenuList.getGui()),name:e.TAB_GENERAL},this.tabItemGeneral}onHidePopup(e){this.menuUtils.closePopupAndRestoreFocusOnSelect(this.hidePopupFunc,this.restoreFocusParams,e)}createFilterPanel(){const t=this.column?this.createManagedBean(new Dp.FilterWrapperComp(this.column,"COLUMN_MENU")):null;if(!(null==t?void 0:t.hasFilter()))throw new Error("AG Grid - Unable to instantiate filter");return this.tabItemFilter={title:Dp._.createIconNoSpan("filter",this.gos,this.column),titleLabel:e.TAB_FILTER.replace("MenuTab",""),bodyPromise:Dp.AgPromise.resolve(null==t?void 0:t.getGui()),afterAttachedCallback:e=>t.afterGuiAttached(e),afterDetachedCallback:()=>t.afterGuiDetached(),name:e.TAB_FILTER},this.tabItemFilter}createColumnsPanel(){const t=document.createElement("div");t.classList.add("ag-menu-column-select-wrapper");const i=this.columnChooserFactory.createColumnSelectPanel(this,this.column).getGui();return i.classList.add("ag-menu-column-select"),t.appendChild(i),this.tabItemColumns={title:Dp._.createIconNoSpan("columns",this.gos,this.column),titleLabel:e.TAB_COLUMNS.replace("MenuTab",""),bodyPromise:Dp.AgPromise.resolve(t),name:e.TAB_COLUMNS},this.tabItemColumns}afterGuiAttached(e){const{container:t,hidePopup:i}=e;this.tabbedLayout.setAfterAttachedParams({container:t,hidePopup:i}),i&&(this.hidePopupFunc=i,this.addDestroyFunc(i))}getGui(){return this.tabbedLayout.getGui()}};Qp.EVENT_TAB_SELECTED="tabSelected",Qp.TAB_FILTER="filterMenuTab",Qp.TAB_GENERAL="generalMenuTab",Qp.TAB_COLUMNS="columnsMenuTab",Qp.TABS_DEFAULT=[Qp.TAB_GENERAL,Qp.TAB_FILTER,Qp.TAB_COLUMNS],qp([(0,Dp.Autowired)("filterManager")],Qp.prototype,"filterManager",2),qp([(0,Dp.Autowired)("columnChooserFactory")],Qp.prototype,"columnChooserFactory",2),qp([(0,Dp.Autowired)("columnMenuFactory")],Qp.prototype,"columnMenuFactory",2),qp([(0,Dp.Autowired)("menuUtils")],Qp.prototype,"menuUtils",2),qp([Dp.PostConstruct],Qp.prototype,"init",1);var Xp=Qp,Zp=class extends Dp.Component{constructor(e,t,i){super('\n            <div ref="eColumnMenu" role="presentation" class="ag-menu ag-column-menu"></div>\n        '),this.column=e,this.restoreFocusParams=t,this.sourceElement=i}init(){this.mainMenuList=this.columnMenuFactory.createMenu(this,this.column,()=>{var e;return null!=(e=this.sourceElement)?e:this.getGui()}),this.mainMenuList.addEventListener(Dp.AgMenuItemComponent.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.eColumnMenu.appendChild(this.mainMenuList.getGui())}onHidePopup(e){this.menuUtils.closePopupAndRestoreFocusOnSelect(this.hidePopupFunc,this.restoreFocusParams,e)}afterGuiAttached({hidePopup:e}){e&&(this.hidePopupFunc=e,this.addDestroyFunc(e)),this.focusService.focusInto(this.mainMenuList.getGui())}};qp([(0,Dp.Autowired)("columnMenuFactory")],Zp.prototype,"columnMenuFactory",2),qp([(0,Dp.Autowired)("menuUtils")],Zp.prototype,"menuUtils",2),qp([(0,Dp.Autowired)("focusService")],Zp.prototype,"focusService",2),qp([(0,Dp.RefSelector)("eColumnMenu")],Zp.prototype,"eColumnMenu",2),qp([Dp.PostConstruct],Zp.prototype,"init",1);var Jp="ag-context-menu-open",eg=class extends Ip.BeanStub{hideActiveMenu(){this.destroyBean(this.activeMenu)}getMenuItems(e,t,i){const r=[];if(Ip._.exists(e)&&Ip.ModuleRegistry.__isRegistered(Ip.ModuleNames.ClipboardModule,this.context.getGridId())&&t&&(this.gos.get("suppressCutToClipboard")||r.push("cut"),r.push("copy","copyWithHeaders","copyWithGroupHeaders","paste","separator")),this.gos.get("enableCharts")&&Ip.ModuleRegistry.__isRegistered(Ip.ModuleNames.GridChartsModule,this.context.getGridId())&&(this.columnModel.isPivotMode()&&r.push("pivotChart"),this.rangeService&&!this.rangeService.isEmpty()&&r.push("chartRange")),Ip._.exists(e)){const e=!Ip.ModuleRegistry.__isRegistered(Ip.ModuleNames.CsvExportModule,this.context.getGridId()),t=!Ip.ModuleRegistry.__isRegistered(Ip.ModuleNames.ExcelExportModule,this.context.getGridId()),i=this.gos.get("suppressExcelExport")||t,n=this.gos.get("suppressCsvExport")||e;!(Ip._.isIOSUserAgent()||i&&n)&&r.push("export")}const n=r.length?r:void 0,s=null==t?void 0:t.getColDef().contextMenuItems;if(Array.isArray(s))return s;if("function"==typeof s)return s(this.gos.addGridCommonParams({column:t,node:e,value:i,defaultItems:n}));const o=this.gos.getCallback("getContextMenuItems");return o?o({column:t,node:e,value:i,defaultItems:n}):r}onContextMenu(e,t,i,r,n,s){this.menuUtils.onContextMenu(e,t,e=>this.showMenu(i,r,n,e,s))}showMenu(e,t,i,r,n){const s=this.getMenuItems(e,t,i),o=this.ctrlsService.getGridBodyCtrl().getGui();if(void 0===s||Ip._.missingOrEmpty(s))return!1;const a=new tg(s,t,e,i);this.createBean(a);const l=a.getGui(),c={column:t,rowNode:e,type:"contextMenu",mouseEvent:r,ePopup:l,nudgeY:1},u=this.localeService.getLocaleTextFunc(),h=this.popupService.addPopup({modal:!0,eChild:l,closeOnEsc:!0,closedCallback:e=>{o.classList.remove(Jp),this.destroyBean(a),this.dispatchVisibleChangedEvent(!1,void 0===e?"api":"ui")},click:r,positionCallback:()=>{const e=this.gos.get("enableRtl");this.popupService.positionPopupUnderMouseEvent($p(Kp({},c),{nudgeX:e?-1*(l.offsetWidth+1):1}))},anchorToElement:n,ariaLabel:u("ariaLabelContextMenu","Context Menu")});h&&(o.classList.add(Jp),a.afterGuiAttached({container:"contextMenu",hidePopup:h.hideFunc})),this.activeMenu&&this.hideActiveMenu(),this.activeMenu=a,a.addEventListener(Ip.BeanStub.EVENT_DESTROYED,()=>{this.activeMenu===a&&(this.activeMenu=null)}),h&&a.addEventListener(Ip.AgMenuItemComponent.EVENT_CLOSE_MENU,e=>{var t,i;return h.hideFunc({mouseEvent:null!=(t=e.mouseEvent)?t:void 0,keyboardEvent:null!=(i=e.keyboardEvent)?i:void 0,forceHide:!0})});const d=r&&r instanceof MouseEvent&&"mousedown"===r.type;return this.dispatchVisibleChangedEvent(!0,d?"api":"ui"),!0}dispatchVisibleChangedEvent(e,t="ui"){const i={type:Ip.Events.EVENT_CONTEXT_MENU_VISIBLE_CHANGED,visible:e,source:t};this.eventService.dispatchEvent(i)}};qp([(0,Ip.Autowired)("popupService")],eg.prototype,"popupService",2),qp([(0,Ip.Autowired)("ctrlsService")],eg.prototype,"ctrlsService",2),qp([(0,Ip.Autowired)("columnModel")],eg.prototype,"columnModel",2),qp([(0,Ip.Autowired)("menuUtils")],eg.prototype,"menuUtils",2),qp([(0,Ip.Optional)("rangeService")],eg.prototype,"rangeService",2),eg=qp([(0,Ip.Bean)("contextMenuFactory")],eg);var tg=class extends Ip.Component{constructor(e,t,i,r){super('<div class="ag-menu" role="presentation"></div>'),this.menuItems=e,this.column=t,this.node=i,this.value=r,this.menuList=null,this.focusedCell=null}addMenuItems(){const e=this.createManagedBean(new Ip.AgMenuList(0,{column:this.column,node:this.node,value:this.value})),t=this.menuItemMapper.mapWithStockItems(this.menuItems,null,()=>this.getGui());e.addMenuItems(t),this.appendChild(e),this.menuList=e,e.addEventListener(Ip.AgMenuItemComponent.EVENT_CLOSE_MENU,e=>this.dispatchEvent(e))}afterGuiAttached(e){e.hidePopup&&this.addDestroyFunc(e.hidePopup),this.focusedCell=this.focusService.getFocusedCell(),this.menuList&&this.focusService.focusInto(this.menuList.getGui())}restoreFocusedCell(){const e=this.focusService.getFocusedCell();if(e&&this.focusedCell&&this.cellPositionUtils.equals(e,this.focusedCell)){const{rowIndex:e,rowPinned:t,column:i}=this.focusedCell,r=this.gos.getDocument(),n=this.gos.getActiveDomElement();n&&n!==r.body||this.focusService.setFocusedCell({rowIndex:e,column:i,rowPinned:t,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!this.focusService.isKeyboardMode()})}}destroy(){this.restoreFocusedCell(),super.destroy()}};qp([(0,Ip.Autowired)("menuItemMapper")],tg.prototype,"menuItemMapper",2),qp([(0,Ip.Autowired)("focusService")],tg.prototype,"focusService",2),qp([(0,Ip.Autowired)("cellPositionUtils")],tg.prototype,"cellPositionUtils",2),qp([Ip.PostConstruct],tg.prototype,"addMenuItems",1);var ig=class extends Lp.BeanStub{mapWithStockItems(e,t,i){if(!e)return[];const r=[];return e.forEach(e=>{let n;if(n="string"==typeof e?this.getStockMenuItem(e,t,i):Kp({},e),!n)return;const s=n,{subMenu:o}=s;o&&o instanceof Array&&(s.subMenu=this.mapWithStockItems(o,t,i)),null!=n&&r.push(n)}),r}getStockMenuItem(e,t,i){var r;const n=this.localeService.getLocaleTextFunc(),s=this.gos.get("skipHeaderOnAutoSize");switch(e){case"pinSubMenu":return{name:n("pinColumn","Pin Column"),icon:Lp._.createIconNoSpan("menuPin",this.gos,null),subMenu:["clearPinned","pinLeft","pinRight"]};case"pinLeft":return{name:n("pinLeft","Pin Left"),action:()=>this.columnModel.setColumnsPinned([t],"left","contextMenu"),checked:!!t&&t.isPinnedLeft()};case"pinRight":return{name:n("pinRight","Pin Right"),action:()=>this.columnModel.setColumnsPinned([t],"right","contextMenu"),checked:!!t&&t.isPinnedRight()};case"clearPinned":return{name:n("noPin","No Pin"),action:()=>this.columnModel.setColumnsPinned([t],null,"contextMenu"),checked:!!t&&!t.isPinned()};case"valueAggSubMenu":return Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.RowGroupingModule,"Aggregation from Menu",this.context.getGridId())&&((null==t?void 0:t.isPrimary())||(null==t?void 0:t.getColDef().pivotValueColumn))?{name:n("valueAggregation","Value Aggregation"),icon:Lp._.createIconNoSpan("menuValue",this.gos,null),subMenu:this.createAggregationSubMenu(t,this.aggFuncService)}:null;case"autoSizeThis":return{name:n("autosizeThiscolumn","Autosize This Column"),action:()=>this.columnModel.autoSizeColumn(t,"contextMenu",s)};case"autoSizeAll":return{name:n("autosizeAllColumns","Autosize All Columns"),action:()=>this.columnModel.autoSizeAllColumns("contextMenu",s)};case"rowGroup":return{name:n("groupBy","Group by")+" "+Lp._.escapeString(this.columnModel.getDisplayNameForColumn(t,"header")),disabled:(null==t?void 0:t.isRowGroupActive())||!(null==t?void 0:t.getColDef().enableRowGroup),action:()=>this.columnModel.addRowGroupColumns([t],"contextMenu"),icon:Lp._.createIconNoSpan("menuAddRowGroup",this.gos,null)};case"rowUnGroup":const o=Lp._.createIconNoSpan("menuRemoveRowGroup",this.gos,null),a=null==t?void 0:t.getColDef().showRowGroup,l=this.gos.get("groupLockGroupColumns");if(!0===a)return{name:n("ungroupAll","Un-Group All"),disabled:-1===l||l>=this.columnModel.getRowGroupColumns().length,action:()=>this.columnModel.setRowGroupColumns(this.columnModel.getRowGroupColumns().slice(0,l),"contextMenu"),icon:o};if("string"==typeof a){const e=this.columnModel.getPrimaryColumn(a),t=null!=e?Lp._.escapeString(this.columnModel.getDisplayNameForColumn(e,"header")):a;return{name:n("ungroupBy","Un-Group by")+" "+t,disabled:null!=e&&this.columnModel.isColumnGroupingLocked(e),action:()=>this.columnModel.removeRowGroupColumns([a],"contextMenu"),icon:o}}return{name:n("ungroupBy","Un-Group by")+" "+Lp._.escapeString(this.columnModel.getDisplayNameForColumn(t,"header")),disabled:!(null==t?void 0:t.isRowGroupActive())||!(null==t?void 0:t.getColDef().enableRowGroup)||this.columnModel.isColumnGroupingLocked(t),action:()=>this.columnModel.removeRowGroupColumns([t],"contextMenu"),icon:o};case"resetColumns":return{name:n("resetColumns","Reset Columns"),action:()=>this.columnModel.resetColumnState("contextMenu")};case"expandAll":return{name:n("expandAll","Expand All Row Groups"),action:()=>this.gridApi.expandAll()};case"contractAll":return{name:n("collapseAll","Collapse All Row Groups"),action:()=>this.gridApi.collapseAll()};case"copy":return Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.ClipboardModule,"Copy from Menu",this.context.getGridId())?{name:n("copy","Copy"),shortcut:n("ctrlC","Ctrl+C"),icon:Lp._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard()}:null;case"copyWithHeaders":return Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.ClipboardModule,"Copy with Headers from Menu",this.context.getGridId())?{name:n("copyWithHeaders","Copy with Headers"),icon:Lp._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard({includeHeaders:!0})}:null;case"copyWithGroupHeaders":return Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.ClipboardModule,"Copy with Group Headers from Menu",this.context.getGridId())?{name:n("copyWithGroupHeaders","Copy with Group Headers"),icon:Lp._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard({includeHeaders:!0,includeGroupHeaders:!0})}:null;case"cut":if(Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.ClipboardModule,"Cut from Menu",this.context.getGridId())){const e=this.focusService.getFocusedCell(),t=e?this.rowPositionUtils.getRowNode(e):null,i=!!t&&(null==e?void 0:e.column.isCellEditable(t));return{name:n("cut","Cut"),shortcut:n("ctrlX","Ctrl+X"),icon:Lp._.createIconNoSpan("clipboardCut",this.gos,null),disabled:!i||this.gos.get("suppressCutToClipboard"),action:()=>this.clipboardService.cutToClipboard(void 0,"contextMenu")}}return null;case"paste":return Lp.ModuleRegistry.__assertRegistered(Lp.ModuleNames.ClipboardModule,"Paste from Clipboard",this.context.getGridId())?{name:n("paste","Paste"),shortcut:n("ctrlV","Ctrl+V"),disabled:!0,icon:Lp._.createIconNoSpan("clipboardPaste",this.gos,null),action:()=>this.clipboardService.pasteFromClipboard()}:null;case"export":const c=[],u=Lp.ModuleRegistry.__isRegistered(Lp.ModuleNames.CsvExportModule,this.context.getGridId()),h=Lp.ModuleRegistry.__isRegistered(Lp.ModuleNames.ExcelExportModule,this.context.getGridId());return!this.gos.get("suppressCsvExport")&&u&&c.push("csvExport"),!this.gos.get("suppressExcelExport")&&h&&c.push("excelExport"),{name:n("export","Export"),subMenu:c,icon:Lp._.createIconNoSpan("save",this.gos,null)};case"csvExport":return{name:n("csvExport","CSV Export"),icon:Lp._.createIconNoSpan("csvExport",this.gos,null),action:()=>this.gridApi.exportDataAsCsv({})};case"excelExport":return{name:n("excelExport","Excel Export"),icon:Lp._.createIconNoSpan("excelExport",this.gos,null),action:()=>this.gridApi.exportDataAsExcel()};case"separator":return"separator";case"pivotChart":case"chartRange":return null!=(r=this.chartMenuItemMapper.getChartItems(e))?r:null;case"columnFilter":return t?{name:n("columnFilter","Column Filter"),icon:Lp._.createIconNoSpan("filter",this.gos,null),action:()=>this.menuService.showFilterMenu({column:t,buttonElement:i(),containerType:"columnFilter",positionBy:"button"})}:null;case"columnChooser":return Lp.ModuleRegistry.__isRegistered(Lp.ModuleNames.ColumnsToolPanelModule,this.context.getGridId())?{name:n("columnChooser","Choose Columns"),icon:Lp._.createIconNoSpan("columns",this.gos,null),action:()=>this.menuService.showColumnChooser({column:t,eventSource:i()})}:null;case"sortAscending":return{name:n("sortAscending","Sort Ascending"),icon:Lp._.createIconNoSpan("sortAscending",this.gos,null),action:()=>this.sortController.setSortForColumn(t,"asc",!1,"columnMenu")};case"sortDescending":return{name:n("sortDescending","Sort Descending"),icon:Lp._.createIconNoSpan("sortDescending",this.gos,null),action:()=>this.sortController.setSortForColumn(t,"desc",!1,"columnMenu")};case"sortUnSort":return{name:n("sortUnSort","Clear Sort"),icon:Lp._.createIconNoSpan("sortUnSort",this.gos,null),action:()=>this.sortController.setSortForColumn(t,null,!1,"columnMenu")};default:return console.warn(`AG Grid: unknown menu item type ${e}`),null}}createAggregationSubMenu(e,t){const i=this.localeService.getLocaleTextFunc();let r;if(e.isPrimary())r=e;else{const t=e.getColDef().pivotValueColumn;r=Lp._.exists(t)?t:void 0}const n=[];if(r){const e=r.isValueActive(),s=t.getFuncNames(r);n.push({name:i("noAggregation","None"),action:()=>{this.columnModel.removeValueColumns([r],"contextMenu"),this.columnModel.setColumnAggFunc(r,void 0,"contextMenu")},checked:!e}),s.forEach(s=>{n.push({name:i(s,t.getDefaultFuncLabel(s)),action:()=>{this.columnModel.setColumnAggFunc(r,s,"contextMenu"),this.columnModel.addValueColumns([r],"contextMenu")},checked:e&&r.getAggFunc()===s})})}return n}};qp([(0,Lp.Autowired)("columnModel")],ig.prototype,"columnModel",2),qp([(0,Lp.Autowired)("gridApi")],ig.prototype,"gridApi",2),qp([(0,Lp.Autowired)("focusService")],ig.prototype,"focusService",2),qp([(0,Lp.Autowired)("rowPositionUtils")],ig.prototype,"rowPositionUtils",2),qp([(0,Lp.Autowired)("chartMenuItemMapper")],ig.prototype,"chartMenuItemMapper",2),qp([(0,Lp.Autowired)("menuService")],ig.prototype,"menuService",2),qp([(0,Lp.Autowired)("sortController")],ig.prototype,"sortController",2),qp([(0,Lp.Optional)("clipboardService")],ig.prototype,"clipboardService",2),qp([(0,Lp.Optional)("aggFuncService")],ig.prototype,"aggFuncService",2),ig=qp([(0,Lp.Bean)("menuItemMapper")],ig);var rg=class extends Np.BeanStub{getChartItems(e){var t,i;if(!this.chartService)return void Np.ModuleRegistry.__assertRegistered(Np.ModuleNames.GridChartsModule,`the Context Menu key "${e}"`,this.context.getGridId());const r="pivotChart"===e?new ng(this.gos,this.chartService,this.localeService):new sg(this.gos,this.chartService,this.localeService),n=this.chartService.isEnterprise();let s=r.getMenuItem();if(s&&s.subMenu&&!n){const e=t=>{var i;return $p(Kp({},t),{subMenu:null==(i=t.subMenu)?void 0:i.filter(e=>!e._enterprise).map(t=>e(t))})};s=e(s)}const o=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.settingsPanel)?void 0:i.chartGroupsDef;return o&&(s=rg.filterAndOrderChartMenu(s,o,r.getConfigLookup())),this.cleanInternals(s)}cleanInternals(e){if(!e)return e;const t=e=>{var i;return null==e||delete e._key,null==e||delete e._enterprise,null==(i=null==e?void 0:e.subMenu)||i.forEach(e=>t(e)),e};return t(e)}static buildLookup(e){let t={};const i=e=>{t[e._key]=e,e.subMenu&&e.subMenu.forEach(e=>i(e))};return i(e),t}static filterAndOrderChartMenu(e,t,i){var r;const n=this.buildLookup(e);let s=$p(Kp({},e),{subMenu:[]});if(Object.entries(t).forEach(([e,t])=>{var r,o;const a=i[e];if(null===a)return;if(null==a)return void Np._.warnOnce(`invalid chartGroupsDef config '${e}'`);const l=n[a._key];if(l)if(l.subMenu){const i=t.map(t=>{const i=a[t];if(null!=i)return n[i];Np._.warnOnce(`invalid chartGroupsDef config '${e}.${t}'`)}).filter(e=>void 0!==e);i.length>0&&(l.subMenu=i,null==(r=s.subMenu)||r.push(l))}else null==(o=s.subMenu)||o.push(l)}),0!=(null==(r=s.subMenu)?void 0:r.length))return s}};qp([(0,Np.Optional)("chartService")],rg.prototype,"chartService",2),rg=qp([(0,Np.Bean)("chartMenuItemMapper")],rg);var ng=class{constructor(e,t,i){this.gos=e,this.chartService=t,this.localeService=i}getMenuItem(){const e=this.localeService.getLocaleTextFunc(),t=(t,i,r,n,s=!1)=>({name:e(t,i),action:()=>this.chartService.createPivotChart({chartType:r}),_key:n,_enterprise:s});return{name:e("pivotChart","Pivot Chart"),_key:"pivotChart",subMenu:[{_key:"pivotColumnChart",name:e("columnChart","Column"),subMenu:[t("groupedColumn","Grouped&lrm;","groupedColumn","pivotGroupedColumn"),t("stackedColumn","Stacked&lrm;","stackedColumn","pivotStackedColumn"),t("normalizedColumn","100% Stacked&lrm;","normalizedColumn","pivotNormalizedColumn")]},{_key:"pivotBarChart",name:e("barChart","Bar"),subMenu:[t("groupedBar","Grouped&lrm;","groupedBar","pivotGroupedBar"),t("stackedBar","Stacked&lrm;","stackedBar","pivotStackedBar"),t("normalizedBar","100% Stacked&lrm;","normalizedBar","pivotNormalizedBar")]},{_key:"pivotPieChart",name:e("pieChart","Pie"),subMenu:[t("pie","Pie&lrm;","pie","pivotPie"),t("donut","Donut&lrm;","donut","pivotDonut")]},t("line","Line&lrm;","line","pivotLineChart"),{_key:"pivotXYChart",name:e("xyChart","X Y (Scatter)"),subMenu:[t("scatter","Scatter&lrm;","scatter","pivotScatter"),t("bubble","Bubble&lrm;","bubble","pivotBubble")]},{_key:"pivotAreaChart",name:e("areaChart","Area"),subMenu:[t("area","Area&lrm;","area","pivotArea"),t("stackedArea","Stacked&lrm;","stackedArea","pivotStackedArea"),t("normalizedArea","100% Stacked&lrm;","normalizedArea","pivotNormalizedArea")]},{_key:"pivotStatisticalChart",_enterprise:!1,name:e("statisticalChart","Statistical"),subMenu:[t("histogramChart","Histogram&lrm;","histogram","pivotHistogram",!1)]},{_key:"pivotHierarchicalChart",_enterprise:!0,name:e("hierarchicalChart","Hierarchical"),subMenu:[t("treemapChart","Treemap&lrm;","treemap","pivotTreemap",!0),t("sunburstChart","Sunburst&lrm;","sunburst","pivotSunburst",!0)]},{_key:"pivotCombinationChart",name:e("combinationChart","Combination"),subMenu:[t("columnLineCombo","Column & Line&lrm;","columnLineCombo","pivotColumnLineCombo"),t("AreaColumnCombo","Area & Column&lrm;","areaColumnCombo","pivotAreaColumnCombo")]}],icon:Np._.createIconNoSpan("chart",this.gos,void 0)}}getConfigLookup(){return{columnGroup:{_key:"pivotColumnChart",column:"pivotGroupedColumn",stackedColumn:"pivotStackedColumn",normalizedColumn:"pivotNormalizedColumn"},barGroup:{_key:"pivotBarChart",bar:"pivotGroupedBar",stackedBar:"pivotStackedBar",normalizedBar:"pivotNormalizedBar"},pieGroup:{_key:"pivotPieChart",pie:"pivotPie",donut:"pivotDonut",doughnut:"pivotDonut"},lineGroup:{_key:"pivotLineChart",line:"pivotLineChart"},scatterGroup:{_key:"pivotXYChart",bubble:"pivotBubble",scatter:"pivotScatter"},areaGroup:{_key:"pivotAreaChart",area:"pivotArea",stackedArea:"pivotStackedArea",normalizedArea:"pivotNormalizedArea"},combinationGroup:{_key:"pivotCombinationChart",columnLineCombo:"pivotColumnLineCombo",areaColumnCombo:"pivotAreaColumnCombo",customCombo:null},hierarchicalGroup:{_key:"pivotHierarchicalChart",treemap:"pivotTreemap",sunburst:"pivotSunburst"},statisticalGroup:{_key:"pivotStatisticalChart",histogram:"pivotHistogram",rangeBar:null,rangeArea:null,boxPlot:null},polarGroup:null,specializedGroup:null}}},sg=class{constructor(e,t,i){this.gos=e,this.chartService=t,this.localeService=i}getMenuItem(){const e=this.localeService.getLocaleTextFunc(),t=(t,i,r,n,s=!1)=>({name:e(t,i),action:()=>this.chartService.createChartFromCurrentRange(r),_key:n,_enterprise:s});return{name:e("chartRange","Chart Range"),_key:"chartRange",subMenu:[{name:e("columnChart","Column"),subMenu:[t("groupedColumn","Grouped&lrm;","groupedColumn","rangeGroupedColumn"),t("stackedColumn","Stacked&lrm;","stackedColumn","rangeStackedColumn"),t("normalizedColumn","100% Stacked&lrm;","normalizedColumn","rangeNormalizedColumn")],_key:"rangeColumnChart"},{name:e("barChart","Bar"),subMenu:[t("groupedBar","Grouped&lrm;","groupedBar","rangeGroupedBar"),t("stackedBar","Stacked&lrm;","stackedBar","rangeStackedBar"),t("normalizedBar","100% Stacked&lrm;","normalizedBar","rangeNormalizedBar")],_key:"rangeBarChart"},{name:e("pieChart","Pie"),subMenu:[t("pie","Pie&lrm;","pie","rangePie"),t("donut","Donut&lrm;","donut","rangeDonut")],_key:"rangePieChart"},t("line","Line&lrm;","line","rangeLineChart"),{name:e("xyChart","X Y (Scatter)"),subMenu:[t("scatter","Scatter&lrm;","scatter","rangeScatter"),t("bubble","Bubble&lrm;","bubble","rangeBubble")],_key:"rangeXYChart"},{name:e("areaChart","Area"),subMenu:[t("area","Area&lrm;","area","rangeArea"),t("stackedArea","Stacked&lrm;","stackedArea","rangeStackedArea"),t("normalizedArea","100% Stacked&lrm;","normalizedArea","rangeNormalizedArea")],_key:"rangeAreaChart"},{name:e("polarChart","Polar"),subMenu:[t("radarLine","Radar Line&lrm;","radarLine","rangeRadarLine"),t("radarArea","Radar Area&lrm;","radarArea","rangeRadarArea"),t("nightingale","Nightingale&lrm;","nightingale","rangeNightingale"),t("radialColumn","Radial Column&lrm;","radialColumn","rangeRadialColumn"),t("radialBar","Radial Bar&lrm;","radialBar","rangeRadialBar")],_key:"rangePolarChart",_enterprise:!0},{name:e("statisticalChart","Statistical"),subMenu:[t("boxPlot","Box Plot&lrm;","boxPlot","rangeBoxPlot",!0),t("histogramChart","Histogram&lrm;","histogram","rangeHistogram",!1),t("rangeBar","Range Bar&lrm;","rangeBar","rangeRangeBar",!0),t("rangeArea","Range Area&lrm;","rangeArea","rangeRangeArea",!0)],_key:"rangeStatisticalChart",_enterprise:!1},{name:e("hierarchicalChart","Hierarchical"),subMenu:[t("treemap","Treemap&lrm;","treemap","rangeTreemap"),t("sunburst","Sunburst&lrm;","sunburst","rangeSunburst")],_key:"rangeHierarchicalChart",_enterprise:!0},{name:e("specializedChart","Specialized"),subMenu:[t("heatmap","Heatmap&lrm;","heatmap","rangeHeatmap"),t("waterfall","Waterfall&lrm;","waterfall","rangeWaterfall")],_key:"rangeSpecializedChart",_enterprise:!0},{name:e("combinationChart","Combination"),subMenu:[t("columnLineCombo","Column & Line&lrm;","columnLineCombo","rangeColumnLineCombo"),t("AreaColumnCombo","Area & Column&lrm;","areaColumnCombo","rangeAreaColumnCombo")],_key:"rangeCombinationChart"}],icon:Np._.createIconNoSpan("chart",this.gos,void 0)}}getConfigLookup(){return{columnGroup:{_key:"rangeColumnChart",column:"rangeGroupedColumn",stackedColumn:"rangeStackedColumn",normalizedColumn:"rangeNormalizedColumn"},barGroup:{_key:"rangeBarChart",bar:"rangeGroupedBar",stackedBar:"rangeStackedBar",normalizedBar:"rangeNormalizedBar"},pieGroup:{_key:"rangePieChart",pie:"rangePie",donut:"rangeDonut",doughnut:"rangeDonut"},lineGroup:{_key:"rangeLineChart",line:"rangeLineChart"},scatterGroup:{_key:"rangeXYChart",bubble:"rangeBubble",scatter:"rangeScatter"},areaGroup:{_key:"rangeAreaChart",area:"rangeArea",stackedArea:"rangeStackedArea",normalizedArea:"rangeNormalizedArea"},polarGroup:{_key:"rangePolarChart",radarLine:"rangeRadarLine",radarArea:"rangeRadarArea",nightingale:"rangeNightingale",radialColumn:"rangeRadialColumn",radialBar:"rangeRadialBar"},statisticalGroup:{_key:"rangeStatisticalChart",boxPlot:"rangeBoxPlot",histogram:"rangeHistogram",rangeBar:"rangeRangeBar",rangeArea:"rangeRangeArea"},hierarchicalGroup:{_key:"rangeHierarchicalChart",treemap:"rangeTreemap",sunburst:"rangeSunburst"},specializedGroup:{_key:"rangeSpecializedChart",heatmap:"rangeHeatmap",waterfall:"rangeWaterfall"},combinationGroup:{_key:"rangeCombinationChart",columnLineCombo:"rangeColumnLineCombo",areaColumnCombo:"rangeAreaColumnCombo",customCombo:null}}}},og=class extends Op.BeanStub{createColumnSelectPanel(e,t,i,r){var n,s;const o=e.createManagedBean(new bu),a=null!=(s=null!=(n=null!=r?r:null==t?void 0:t.getColDef().columnChooserParams)?n:null==t?void 0:t.getColDef().columnsMenuParams)?s:{},{contractColumnSelection:l,suppressColumnExpandAll:c,suppressColumnFilter:u,suppressColumnSelectAll:h,suppressSyncLayoutWithGrid:d,columnLayout:p}=a;return o.init(!!i,this.gos.addGridCommonParams({suppressColumnMove:!1,suppressValues:!1,suppressPivots:!1,suppressRowGroups:!1,suppressPivotMode:!1,contractColumnSelection:!!l,suppressColumnExpandAll:!!c,suppressColumnFilter:!!u,suppressColumnSelectAll:!!h,suppressSyncLayoutWithGrid:!!p||!!d,onStateUpdated:()=>{}}),"columnMenu"),p&&o.setColumnLayout(p),o}showColumnChooser({column:e,chooserParams:t,eventSource:i}){this.hideActiveColumnChooser();const r=this.createColumnSelectPanel(this,e,!0,t),n=this.localeService.getLocaleTextFunc(),s=this.columnModel.getAllDisplayedColumns().indexOf(e),o=e?this.focusService.getFocusedHeader():null;this.activeColumnChooserDialog=this.createBean(new Op.AgDialog({title:n("chooseColumns","Choose Columns"),component:r,width:300,height:300,resizable:!0,movable:!0,centered:!0,closable:!0,afterGuiAttached:()=>{var t;null==(t=this.focusService.findNextFocusableElement(r.getGui()))||t.focus(),this.dispatchVisibleChangedEvent(!0,e)},closedCallback:t=>{const r=this.activeColumnChooser.getGui();this.destroyBean(this.activeColumnChooser),this.activeColumnChooser=void 0,this.activeColumnChooserDialog=void 0,this.dispatchVisibleChangedEvent(!1,e),e&&this.menuUtils.restoreFocusOnClose({column:e,headerPosition:o,columnIndex:s,eventSource:i},r,t,!0)}})),this.activeColumnChooser=r}hideActiveColumnChooser(){this.activeColumnChooserDialog&&this.destroyBean(this.activeColumnChooserDialog)}dispatchVisibleChangedEvent(e,t){const i={type:Op.Events.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:!1,key:"columnChooser",column:null!=t?t:null};this.eventService.dispatchEvent(i)}};qp([(0,Op.Autowired)("focusService")],og.prototype,"focusService",2),qp([(0,Op.Autowired)("menuUtils")],og.prototype,"menuUtils",2),qp([(0,Op.Autowired)("columnModel")],og.prototype,"columnModel",2),og=qp([(0,Op.Bean)("columnChooserFactory")],og);var ag=class extends Fp.BeanStub{createMenu(e,t,i){const r=e.createManagedBean(new Fp.AgMenuList(0,{column:null!=t?t:null,node:null,value:null})),n=this.getMenuItems(t),s=this.menuItemMapper.mapWithStockItems(n,null!=t?t:null,i);return r.addMenuItems(s),r}getMenuItems(e){const t=this.getDefaultMenuOptions(e);let i;const r=null==e?void 0:e.getColDef().mainMenuItems;if(Array.isArray(r))i=r;else if("function"==typeof r)i=r(this.gos.addGridCommonParams({column:e,defaultItems:t}));else{const r=this.gos.getCallback("getMainMenuItems");i=r&&e?r({column:e,defaultItems:t}):t}return Fp._.removeRepeatsFromArray(i,ag.MENU_ITEM_SEPARATOR),i}getDefaultMenuOptions(e){const t=[],i=this.menuService.isLegacyMenuEnabled();if(!e)return i||t.push("columnChooser"),t.push("resetColumns"),t;const r=!e.getColDef().lockPinned,n=this.columnModel.getRowGroupColumns().length,s=n>0,o=e.isAllowValue(),a=e.isAllowRowGroup(),l=e.isPrimary(),c=this.columnModel.isPivotMode(),u="clientSide"===this.rowModel.getType(),h=this.gos.get("treeData"),d=l&&s&&o||!l;if(!i&&e.isSortable()){const i=e.getSort();"asc"!==i&&t.push("sortAscending"),"desc"!==i&&t.push("sortDescending"),i&&t.push("sortUnSort"),t.push(ag.MENU_ITEM_SEPARATOR)}return this.menuService.isFilterMenuItemEnabled(e)&&(t.push("columnFilter"),t.push(ag.MENU_ITEM_SEPARATOR)),r&&t.push("pinSubMenu"),d&&t.push("valueAggSubMenu"),(r||d)&&t.push(ag.MENU_ITEM_SEPARATOR),t.push("autoSizeThis"),t.push("autoSizeAll"),t.push(ag.MENU_ITEM_SEPARATOR),e.getColDef().showRowGroup?t.push("rowUnGroup"):a&&e.isPrimary()&&(e.isRowGroupActive()?this.columnModel.isColumnGroupingLocked(e)||t.push("rowUnGroup"):t.push("rowGroup")),t.push(ag.MENU_ITEM_SEPARATOR),i||t.push("columnChooser"),t.push("resetColumns"),u&&(h||n>(c?1:0))&&(t.push("expandAll"),t.push("contractAll")),t}};ag.MENU_ITEM_SEPARATOR="separator",qp([(0,Fp.Autowired)("menuItemMapper")],ag.prototype,"menuItemMapper",2),qp([(0,Fp.Autowired)("columnModel")],ag.prototype,"columnModel",2),qp([(0,Fp.Autowired)("rowModel")],ag.prototype,"rowModel",2),qp([(0,Fp.Autowired)("filterManager")],ag.prototype,"filterManager",2),qp([(0,Fp.Autowired)("menuService")],ag.prototype,"menuService",2),ag=qp([(0,Fp.Bean)("columnMenuFactory")],ag);var lg=class extends kp.BeanStub{restoreFocusOnClose(e,t,i,r){const{eventSource:n}=e,s=i instanceof KeyboardEvent;if(!r&&!s||!n)return;const o=this.gos.getDocument(),a=this.gos.getActiveDomElement();(t.contains(a)||a===o.body)&&this.focusHeaderCell(e)}closePopupAndRestoreFocusOnSelect(e,t,i){let r;i&&i.keyboardEvent&&(r=i.keyboardEvent),e(r&&{keyboardEvent:r});const n=this.focusService.getFocusedCell(),s=this.gos.getDocument(),o=this.gos.getActiveDomElement();if(!o||o===s.body)if(n){const{rowIndex:e,rowPinned:t,column:i}=n;this.focusService.setFocusedCell({rowIndex:e,column:i,rowPinned:t,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}else this.focusHeaderCell(t)}onContextMenu(e,t,i){if((this.gos.get("allowContextMenuWithControlKey")||!e||!e.ctrlKey&&!e.metaKey)&&(e&&this.blockMiddleClickScrollsIfNeeded(e),!this.gos.get("suppressContextMenu")&&i(null!=e?e:t.touches[0]))){const i=null!=e?e:t;i&&i.cancelable&&i.preventDefault()}}focusHeaderCell(e){const{column:t,columnIndex:i,headerPosition:r,eventSource:n}=e;if(this.columnModel.getAllDisplayedColumns().some(e=>e===t)&&n&&kp._.isVisible(n)){const e=this.focusService.findTabbableParent(n);e&&(t&&this.headerNavigationService.scrollToColumn(t),e.focus())}else if(r&&-1!==i){const e=this.columnModel.getAllDisplayedColumns(),t=e[i]||kp._.last(e);t&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:r.headerRowIndex,column:t}})}}blockMiddleClickScrollsIfNeeded(e){this.gos.get("suppressMiddleClickScrolls")&&2===e.which&&e.preventDefault()}};qp([(0,kp.Autowired)("focusService")],lg.prototype,"focusService",2),qp([(0,kp.Autowired)("headerNavigationService")],lg.prototype,"headerNavigationService",2),qp([(0,kp.Autowired)("columnModel")],lg.prototype,"columnModel",2),lg=qp([(0,kp.Bean)("menuUtils")],lg);var cg={version:"31.3.4",moduleName:xp.ModuleNames.MenuModule,beans:[Yp,eg,ig,rg,og,ag,lg],dependantModules:[_]},ug=i(98092),hg=i(98092),dg=i(98092),pg=Object.defineProperty,gg=Object.defineProperties,fg=Object.getOwnPropertyDescriptor,mg=Object.getOwnPropertyDescriptors,vg=Object.getOwnPropertySymbols,Cg=Object.prototype.hasOwnProperty,yg=Object.prototype.propertyIsEnumerable,wg=(e,t,i)=>t in e?pg(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Sg=(e,t)=>{for(var i in t||(t={}))Cg.call(t,i)&&wg(e,i,t[i]);if(vg)for(var i of vg(t))yg.call(t,i)&&wg(e,i,t[i]);return e},bg=(e,t)=>gg(e,mg(t)),Eg=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?fg(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&pg(t,i,s),s},Ag=class e extends hg.TabGuardComp{constructor(){super('<div class="ag-multi-filter ag-menu-list-compact"></div>'),this.filterDefs=[],this.filters=[],this.guiDestroyFuncs=[],this.filterGuis=[],this.activeFilterIndices=[],this.lastActivatedMenuItem=null,this.afterFiltersReadyFuncs=[]}postConstruct(){this.initialiseTabGuard({onFocusIn:e=>this.onFocusIn(e)})}static getFilterDefs(e){const{filters:t}=e;return t&&t.length>0?t:[{filter:"agTextColumnFilter"},{filter:"agSetColumnFilter"}]}init(t){this.params=t,this.filterDefs=e.getFilterDefs(t);const{column:i,filterChangedCallback:r}=t;this.column=i,this.filterChangedCallback=r;const n=[];return this.filterDefs.forEach((e,t)=>{const i=this.createFilter(e,t);null!=i&&n.push(i)}),new hg.AgPromise(e=>{hg.AgPromise.all(n).then(t=>{this.filters=t,this.refreshGui("columnMenu").then(()=>{e()})})}).then(()=>{this.afterFiltersReadyFuncs.forEach(e=>e()),this.afterFiltersReadyFuncs.length=0})}refreshGui(e){return e===this.lastOpenedInContainer?hg.AgPromise.resolve():(this.removeAllChildrenExceptTabGuards(),this.destroyChildren(),hg.AgPromise.all(this.filters.map((t,i)=>{const r=this.filterDefs[i],n=this.getFilterTitle(t,r);let s;if("subMenu"===r.display&&"toolPanel"!==e)s=this.insertFilterMenu(t,n).then(e=>e.getGui());else if("subMenu"===r.display||"accordion"===r.display){const e=this.insertFilterGroup(t,n);s=hg.AgPromise.resolve(e.getGui())}else s=hg.AgPromise.resolve(t.getGui());return s})).then(t=>{t.forEach((e,t)=>{t>0&&this.appendChild(hg._.loadTemplate('<div class="ag-filter-separator"></div>')),this.appendChild(e)}),this.filterGuis=t,this.lastOpenedInContainer=e}))}getFilterTitle(e,t){return null!=t.title?t.title:e instanceof hg.ProvidedFilter?e.getFilterTitle():"Filter"}destroyChildren(){this.guiDestroyFuncs.forEach(e=>e()),this.guiDestroyFuncs.length=0,this.filterGuis.length=0}insertFilterMenu(e,t){const i=this.createBean(new hg.AgMenuItemComponent);return i.init({menuItemDef:{name:t,subMenu:[],cssClasses:["ag-multi-filter-menu-item"],menuItem:hg.AgMenuItemRenderer,menuItemParams:{cssClassPrefix:"ag-compact-menu-option",isCompact:!0}},level:0,isAnotherSubMenuOpen:()=>!1,childComponent:e,contextParams:{column:null,node:null,value:null}}).then(()=>{i.setParentComponent(this),this.guiDestroyFuncs.push(()=>this.destroyBean(i)),this.addManagedListener(i,hg.AgMenuItemComponent.EVENT_MENU_ITEM_ACTIVATED,e=>{this.lastActivatedMenuItem&&this.lastActivatedMenuItem!==e.menuItem&&this.lastActivatedMenuItem.deactivate(),this.lastActivatedMenuItem=e.menuItem});const e=i.getGui();return i.addManagedListener(e,"keydown",e=>{const{key:t}=e;switch(t){case hg.KeyCode.UP:case hg.KeyCode.RIGHT:case hg.KeyCode.DOWN:case hg.KeyCode.LEFT:e.preventDefault(),t===hg.KeyCode.RIGHT&&i.openSubMenu(!0)}}),i.addManagedListener(e,"focusin",()=>i.activate()),i.addManagedListener(e,"focusout",()=>{i.isSubMenuOpen()||i.isSubMenuOpening()||i.deactivate()}),i})}insertFilterGroup(e,t){const i=this.createBean(new hg.AgGroupComponent({title:t,cssIdentifier:"multi-filter"}));return this.guiDestroyFuncs.push(()=>this.destroyBean(i)),i.addItem(e.getGui()),i.toggleGroupExpand(!1),e.afterGuiAttached&&i.addManagedListener(i,hg.AgGroupComponent.EVENT_EXPANDED,()=>e.afterGuiAttached({container:this.lastOpenedInContainer,suppressFocus:!0,hidePopup:this.hidePopup})),i}isFilterActive(){return this.filters.some(e=>e.isFilterActive())}getLastActiveFilterIndex(){return this.activeFilterIndices.length>0?this.activeFilterIndices[this.activeFilterIndices.length-1]:null}doesFilterPass(e,t){let i=!0;return this.filters.forEach(r=>{i&&r!==t&&r.isFilterActive()&&(i=r.doesFilterPass(e))}),i}getFilterType(){return"multi"}getModelFromUi(){return{filterType:this.getFilterType(),filterModels:this.filters.map(e=>{const t=e;return"function"==typeof t.getModelFromUi?t.getModelFromUi():null})}}getModel(){return this.isFilterActive()?{filterType:this.getFilterType(),filterModels:this.filters.map(e=>e.isFilterActive()?e.getModel():null)}:null}setModel(e){const t=(e,t)=>new hg.AgPromise(i=>{const r=e.setModel(t);r?r.then(()=>i()):i()});let i=[];return null==e?i=this.filters.map((e,i)=>t(e,null).then(()=>{this.updateActiveList(i)})):this.filters.forEach((r,n)=>{const s=e.filterModels.length>n?e.filterModels[n]:null,o=t(r,s).then(()=>{this.updateActiveList(n)});i.push(o)}),hg.AgPromise.all(i).then(()=>{})}applyModel(e="api"){let t=!1;return this.filters.forEach(i=>{i instanceof hg.ProvidedFilter&&(t=i.applyModel(e)||t)}),t}getChildFilterInstance(e){return this.filters[e]}afterGuiAttached(e){let t;e?(this.hidePopup=e.hidePopup,t=this.refreshGui(e.container)):(this.hidePopup=void 0,t=hg.AgPromise.resolve()),t.then(()=>{const{filterDefs:t}=this;let i=!1;t&&hg._.forEachReverse(t,(t,r)=>{var n;const s=0===r,o=!s||"inline"!==t.display,a=bg(Sg({},null!=e?e:{}),{suppressFocus:o}),l=null==(n=this.filters)?void 0:n[r];if(l&&(this.executeFunctionIfExistsOnFilter(l,"afterGuiAttached",a),s&&(i=!0)),s&&o){const e=this.filterGuis[r];e&&(e.focus(),i=!0)}});const r=this.gos.getDocument(),n=this.gos.getActiveDomElement();i||n&&n!==r.body&&!this.getGui().contains(n)||this.forceFocusOutOfContainer(!0)})}afterGuiDetached(){this.executeFunctionIfExists("afterGuiDetached")}onAnyFilterChanged(){this.executeFunctionIfExists("onAnyFilterChanged")}onNewRowsLoaded(){this.executeFunctionIfExists("onNewRowsLoaded")}destroy(){this.filters.forEach(e=>this.destroyBean(e)),this.filters.length=0,this.destroyChildren(),this.hidePopup=void 0,super.destroy()}executeFunctionIfExists(e,...t){hg._.forEachReverse(this.filters,i=>{this.executeFunctionIfExistsOnFilter(i,e,t)})}executeFunctionIfExistsOnFilter(e,t,...i){const r=e[t];"function"==typeof r&&r.apply(e,i)}createFilter(e,t){const{filterModifiedCallback:i,doesRowPassOtherFilter:r}=this.params;let n;const s=bg(Sg({},this.filterManager.createFilterParams(this.column,this.column.getColDef())),{filterModifiedCallback:i,filterChangedCallback:e=>{this.executeWhenAllFiltersReady(()=>this.filterChanged(t,e))},doesRowPassOtherFilter:e=>r(e)&&this.doesFilterPass({node:e,data:e.data},n)}),o=this.userComponentFactory.getFilterDetails(e,s,"agTextColumnFilter");if(!o)return null;const a=o.newAgStackInstance();return a&&a.then(e=>n=e),a}executeWhenAllFiltersReady(e){this.filters&&this.filters.length>0?e():this.afterFiltersReadyFuncs.push(e)}updateActiveList(e){const t=this.filters[e];hg._.removeFromArray(this.activeFilterIndices,e),t.isFilterActive()&&this.activeFilterIndices.push(e)}filterChanged(e,t){this.updateActiveList(e),this.filterChangedCallback(t);const i=this.filters[e];this.filters.forEach(e=>{e!==i&&"function"==typeof e.onAnyFilterChanged&&e.onAnyFilterChanged()})}onFocusIn(e){null==this.lastActivatedMenuItem||this.lastActivatedMenuItem.getGui().contains(e.target)||(this.lastActivatedMenuItem.deactivate(),this.lastActivatedMenuItem=null)}getModelAsString(e){var t,i,r,n;if(!this.filters||!(null==(t=null==e?void 0:e.filterModels)?void 0:t.length))return"";const s=null!=(i=this.getLastActiveFilterIndex())?i:0,o=this.filters[s];return null!=(n=null==(r=o.getModelAsString)?void 0:r.call(o,e.filterModels[s]))?n:""}};Eg([(0,hg.Autowired)("filterManager")],Ag.prototype,"filterManager",2),Eg([(0,hg.Autowired)("userComponentFactory")],Ag.prototype,"userComponentFactory",2),Eg([hg.PostConstruct],Ag.prototype,"postConstruct",1);var Tg=Ag,Mg=class extends dg.Component{constructor(){super('<div class="ag-multi-floating-filter ag-floating-filter-input"></div>'),this.floatingFilters=[],this.compDetailsList=[]}init(e){this.params=e;const{compDetailsList:t}=this.getCompDetailsList(e);return this.setParams(t)}setParams(e){const t=[];return e.forEach(e=>{const i=null==e?void 0:e.newAgStackInstance();null!=i&&(this.compDetailsList.push(e),t.push(i))}),dg.AgPromise.all(t).then(e=>{e.forEach((e,t)=>{this.floatingFilters.push(e);const i=e.getGui();this.appendChild(i),t>0&&dg._.setDisplayed(i,!1)})})}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e;const{compDetailsList:t,floatingFilterParamsList:i}=this.getCompDetailsList(e);t.length===this.compDetailsList.length&&t.every((e,t)=>!this.filterManager.areFilterCompsDifferent(this.compDetailsList[t],e))?i.forEach((e,t)=>{var i;const r=this.floatingFilters[t];let n=!1;r.refresh&&null!==r.refresh(e)&&(n=!0),n||null==(i=r.onParamsUpdated)||i.call(r,e)}):(dg._.clearElement(this.getGui()),this.destroyBeans(this.floatingFilters),this.floatingFilters=[],this.compDetailsList=[],this.setParams(t))}getCompDetailsList(e){const t=[],i=[],r=e.filterParams;return Tg.getFilterDefs(r).forEach((r,n)=>{const s=bg(Sg({},e),{parentFilterInstance:e=>{this.parentMultiFilterInstance(t=>{const i=t.getChildFilterInstance(n);null!=i&&e(i)})}});dg._.mergeDeep(s.filterParams,r.filterParams);const o=this.getCompDetails(r,s);o&&(t.push(o),i.push(s))}),{compDetailsList:t,floatingFilterParamsList:i}}onParentModelChanged(e,t){t&&t.afterFloatingFilter||this.parentMultiFilterInstance(i=>{if(null==e)this.floatingFilters.forEach((e,i)=>{e.onParentModelChanged(null,t),dg._.setDisplayed(e.getGui(),0===i)});else{const r=i.getLastActiveFilterIndex();this.floatingFilters.forEach((i,n)=>{const s=e.filterModels.length>n?e.filterModels[n]:null;i.onParentModelChanged(s,t);const o=null==r?0===n:n===r;dg._.setDisplayed(i.getGui(),o)})}})}destroy(){this.destroyBeans(this.floatingFilters),this.floatingFilters.length=0,super.destroy()}getCompDetails(e,t){var i;let r=null!=(i=this.userComponentFactory.getDefaultFloatingFilterType(e,()=>this.filterManager.getDefaultFloatingFilter(this.params.column)))?i:"agReadOnlyFloatingFilter";return this.userComponentFactory.getFloatingFilterCompDetails(e,t,r)}parentMultiFilterInstance(e){this.params.parentFilterInstance(t=>{if(!(t instanceof Tg))throw new Error("AG Grid - MultiFloatingFilterComp expects MultiFilter as its parent");e(t)})}};Eg([(0,dg.Autowired)("userComponentFactory")],Mg.prototype,"userComponentFactory",2),Eg([(0,dg.Autowired)("filterManager")],Mg.prototype,"filterManager",2);var Rg={version:"31.3.4",moduleName:ug.ModuleNames.MultiFilterModule,beans:[],userComponents:[{componentName:"agMultiColumnFilter",componentClass:Tg},{componentName:"agMultiColumnFloatingFilter",componentClass:Mg}],dependantModules:[_]},_g=i(98092),Pg=i(98092),xg=class extends Pg.PopupComponent{constructor(){super('<div class="ag-cell-edit-wrapper"></div>')}init(e){this.params=e;const{cellStartedEdit:t,cellHeight:i,values:r}=e;Pg._.missing(r)&&console.warn("AG Grid: agRichSelectCellEditor requires cellEditorParams.values to be set");const{params:n,valuesPromise:s}=this.buildRichSelectParams();this.richSelect=this.createManagedBean(new Pg.AgRichSelect(n)),this.richSelect.addCssClass("ag-cell-editor"),this.appendChild(this.richSelect),s&&s.then(e=>{this.richSelect.setValueList({valueList:e,refresh:!0});const t=this.getSearchStringCallback(e);t&&this.richSelect.setSearchStringCreator(t)}),this.addManagedListener(this.richSelect,Pg.Events.EVENT_FIELD_PICKER_VALUE_SELECTED,this.onEditorPickerValueSelected.bind(this)),this.addManagedListener(this.richSelect.getGui(),"focusout",this.onEditorFocusOut.bind(this)),this.focusAfterAttached=t,Pg._.exists(i)&&this.richSelect.setRowHeight(i)}onEditorPickerValueSelected(e){this.params.stopEditing(!e.fromEnterKey)}onEditorFocusOut(e){this.richSelect.getGui().contains(e.relatedTarget)||this.params.stopEditing(!0)}buildRichSelectParams(){const{cellRenderer:e,value:t,values:i,formatValue:r,searchDebounceDelay:n,valueListGap:s,valueListMaxHeight:o,valueListMaxWidth:a,allowTyping:l,filterList:c,searchType:u,highlightMatch:h,valuePlaceholder:d,eventKey:p}=this.params,g={value:t,cellRenderer:e,searchDebounceDelay:n,valueFormatter:r,pickerAriaLabelKey:"ariaLabelRichSelectField",pickerAriaLabelValue:"Rich Select Field",pickerType:"virtual-list",pickerGap:s,allowTyping:l,filterList:c,searchType:u,highlightMatch:h,maxPickerHeight:o,maxPickerWidth:a,placeholder:d,initialInputValue:1===(null==p?void 0:p.length)?p:void 0};let f,m;return f="function"==typeof i?i(this.params):null!=i?i:[],Array.isArray(f)?(g.valueList=f,g.searchStringCreator=this.getSearchStringCallback(f)):m=f,{params:g,valuesPromise:m}}getSearchStringCallback(e){const{colDef:t}=this.params;if("object"==typeof e[0]&&t.keyCreator)return e=>e.map(e=>{const i=this.gos.addGridCommonParams({value:e,colDef:this.params.colDef,column:this.params.column,node:this.params.node,data:this.params.data});return t.keyCreator(i)})}afterGuiAttached(){const{focusAfterAttached:e,params:t}=this;setTimeout(()=>{if(!this.isAlive())return;if(e){const e=this.richSelect.getFocusableElement();e.focus();const{allowTyping:t,eventKey:i}=this.params;!t||i&&1===i.length||e.select()}this.richSelect.showPicker();const{eventKey:i}=t;i&&1===(null==i?void 0:i.length)&&this.richSelect.searchTextFromString(i)})}getValue(){return this.richSelect.getValue()}isPopup(){return!1}},Dg={version:"31.3.4",moduleName:_g.ModuleNames.RichSelectModule,beans:[],userComponents:[{componentName:"agRichSelect",componentClass:xg},{componentName:"agRichSelectCellEditor",componentClass:xg}],dependantModules:[_]},Ig=i(98092),Lg=i(98092),Ng=i(98092),Og=i(98092),Fg=i(98092),kg=i(98092),Gg=i(98092),Vg=i(98092),Hg=i(98092),Bg=i(98092),zg=i(98092),Ug=i(98092),Wg=i(98092),jg=i(98092),Kg=i(98092),$g=i(98092),qg=i(98092),Yg=i(98092),Qg=i(98092),Xg=Object.defineProperty,Zg=Object.defineProperties,Jg=Object.getOwnPropertyDescriptor,ef=Object.getOwnPropertyDescriptors,tf=Object.getOwnPropertySymbols,rf=Object.prototype.hasOwnProperty,nf=Object.prototype.propertyIsEnumerable,sf=(e,t,i)=>t in e?Xg(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,of=(e,t)=>{for(var i in t||(t={}))rf.call(t,i)&&sf(e,i,t[i]);if(tf)for(var i of tf(t))nf.call(t,i)&&sf(e,i,t[i]);return e},af=(e,t)=>{var i={};for(var r in e)rf.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&tf)for(var r of tf(e))t.indexOf(r)<0&&nf.call(e,r)&&(i[r]=e[r]);return i},lf=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Jg(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Xg(t,i,s),s},cf=class extends Ng.RowNodeBlock{constructor(e,t,i){super(0),this.nodeIdSequence=new Ng.NumberSequence,this.info={},this.ssrmParams=e,this.parentRowNode=i,this.level=i.level+1,this.groupLevel=e.rowGroupCols?this.level<e.rowGroupCols.length:void 0,this.leafGroup=!!e.rowGroupCols&&this.level===e.rowGroupCols.length-1}postConstruct(){if(this.usingTreeData=this.gos.get("treeData"),this.nodeIdPrefix=this.blockUtils.createNodeIdPrefix(this.parentRowNode),!this.usingTreeData&&this.groupLevel){const e=this.ssrmParams.rowGroupCols[this.level];this.groupField=e.field,this.rowGroupColumn=this.columnModel.getRowGroupColumns()[this.level]}let e=1;const t=-1===this.parentRowNode.level,i=this.storeUtils.getServerSideInitialRowCount();t&&null!=i&&(e=i),this.initialiseRowNodes(e),this.rowNodeBlockLoader.addBlock(this),this.addDestroyFunc(()=>this.rowNodeBlockLoader.removeBlock(this)),this.postSortFunc=this.gos.getCallback("postSortRows"),null!=i&&this.eventService.dispatchEventOnce({type:Ng.Events.EVENT_ROW_COUNT_READY})}destroyRowNodes(){this.blockUtils.destroyRowNodes(this.allRowNodes),this.allRowNodes=[],this.nodesAfterSort=[],this.nodesAfterFilter=[],this.allNodesMap={}}initialiseRowNodes(e,t=!1){this.destroyRowNodes();for(let i=0;i<e;i++){const e=this.blockUtils.createRowNode({field:this.groupField,group:this.groupLevel,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn});t&&(e.failedLoad=!0),this.allRowNodes.push(e),this.nodesAfterFilter.push(e),this.nodesAfterSort.push(e)}}getBlockStateJson(){return{id:this.nodeIdPrefix?this.nodeIdPrefix:"",state:this.getState()}}loadFromDatasource(){this.storeUtils.loadFromDatasource({startRow:void 0,endRow:void 0,parentBlock:this,parentNode:this.parentRowNode,storeParams:this.ssrmParams,success:this.success.bind(this,this.getVersion()),fail:this.pageLoadFailed.bind(this,this.getVersion())})}getStartRow(){return 0}getEndRow(){return this.nodesAfterSort.length}createDataNode(e,t){const i=this.blockUtils.createRowNode({field:this.groupField,group:this.groupLevel,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn});null!=t?Ng._.insertIntoArray(this.allRowNodes,i,t):this.allRowNodes.push(i);const r=this.prefixId(this.nodeIdSequence.next());return this.blockUtils.setDataIntoRowNode(i,e,r,void 0),this.nodeManager.addRowNode(i),this.blockUtils.checkOpenByDefault(i),this.allNodesMap[i.id]=i,i}prefixId(e){return this.nodeIdPrefix?this.nodeIdPrefix+"-"+e:e.toString()}processServerFail(){this.initialiseRowNodes(1,!0),this.fireStoreUpdatedEvent(),this.flushAsyncTransactions()}processServerResult(e){if(!this.isAlive())return;const t=e.groupLevelInfo;t&&Object.assign(this.info,t),e.pivotResultFields&&this.serverSideRowModel.generateSecondaryColumns(e.pivotResultFields);const i=this.allRowNodes.length>0?this.allNodesMap:void 0;this.allRowNodes=[],this.nodesAfterSort=[],this.nodesAfterFilter=[],this.allNodesMap={},e.rowData||Ng._.warnOnce('"params.data" is missing from Server-Side Row Model success() callback. Please use the "data" attribute. If no data is returned, set an empty list.'),this.createOrRecycleNodes(i,e.rowData),i&&this.blockUtils.destroyRowNodes(Ng._.getAllValuesInObject(i)),0===this.level&&this.eventService.dispatchEventOnce({type:Ng.Events.EVENT_ROW_COUNT_READY}),this.filterAndSortNodes(),this.fireStoreUpdatedEvent(),this.flushAsyncTransactions()}createOrRecycleNodes(e,t){if(!t)return;const i=t=>{if(!e)return;const i=this.gos.getCallback("getRowId");if(!i)return;const r=this.parentRowNode.getGroupKeys(),n=this.level,s=i({data:t,parentKeys:r.length>0?r:void 0,level:n}),o=e[s];return o?(delete e[s],o):void 0},r=(e,t)=>{this.allNodesMap[e.id]=e,this.blockUtils.updateDataIntoRowNode(e,t),this.allRowNodes.push(e)};t.forEach(e=>{const t=i(e);t?r(t,e):this.createDataNode(e)})}flushAsyncTransactions(){window.setTimeout(()=>this.transactionManager.flushAsyncTransactions(),0)}filterAndSortNodes(){this.filterRowNodes(),this.sortRowNodes()}sortRowNodes(){const e=this.storeUtils.isServerSideSortAllLevels()||this.storeUtils.isServerSideSortOnServer(),t=this.sortController.getSortOptions(),i=!t||0==t.length;if(e||i)this.nodesAfterSort=this.nodesAfterFilter;else if(this.nodesAfterSort=this.rowNodeSorter.doFullSort(this.nodesAfterFilter,t),this.postSortFunc){const e={nodes:this.nodesAfterSort};this.postSortFunc(e)}}filterRowNodes(){const e=!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||this.storeUtils.isServerSideFilterOnServer(),t=this.groupLevel;this.nodesAfterFilter=e||t?this.allRowNodes:this.allRowNodes.filter(e=>this.filterManager.doesRowPassFilter({rowNode:e}))}clearDisplayIndexes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.allRowNodes.forEach(e=>this.blockUtils.clearDisplayIndex(e))}getDisplayIndexEnd(){return this.displayIndexEnd}isDisplayIndexInStore(e){return 0!==this.getRowCount()&&e>=this.displayIndexStart&&e<this.displayIndexEnd}setDisplayIndexes(e,t){this.displayIndexStart=e.peek(),this.topPx=t.value;const i={};this.nodesAfterSort.forEach(r=>{this.blockUtils.setDisplayIndex(r,e,t),i[r.id]=!0}),this.allRowNodes.forEach(e=>{i[e.id]||this.blockUtils.clearDisplayIndex(e)}),this.displayIndexEnd=e.peek(),this.heightPx=t.value-this.topPx}forEachStoreDeep(e,t=new Ng.NumberSequence){e(this,t.next()),this.allRowNodes.forEach(i=>{const r=i.childStore;r&&r.forEachStoreDeep(e,t)})}forEachNodeDeep(e,t=new Ng.NumberSequence){this.allRowNodes.forEach(i=>{e(i,t.next());const r=i.childStore;r&&r.forEachNodeDeep(e,t)})}forEachNodeDeepAfterFilterAndSort(e,t=new Ng.NumberSequence,i=!1){this.nodesAfterSort.forEach(r=>{e(r,t.next());const n=r.childStore;n&&n.forEachNodeDeepAfterFilterAndSort(e,t,i)}),i&&this.parentRowNode.sibling&&e(this.parentRowNode.sibling,t.next())}getRowUsingDisplayIndex(e){if(this.isDisplayIndexInStore(e))return this.blockUtils.binarySearchForDisplayIndex(e,this.nodesAfterSort)}getRowBounds(e){for(let t=0;t<this.nodesAfterSort.length;t++){const i=this.nodesAfterSort[t],r=this.blockUtils.extractRowBounds(i,e);if(r)return r}return null}isPixelInRange(e){return e>=this.topPx&&e<this.topPx+this.heightPx}getRowIndexAtPixel(e){if(e<=this.topPx)return this.nodesAfterSort[0].rowIndex;if(e>=this.topPx+this.heightPx){const t=this.nodesAfterSort[this.nodesAfterSort.length-1],i=t.rowTop+t.rowHeight;if(e>=i&&t.expanded){if(t.childStore&&t.childStore.getRowCount()>0)return t.childStore.getRowIndexAtPixel(e);if(t.detailNode)return t.detailNode.rowIndex}return t.rowIndex}let t=null;return this.nodesAfterSort.forEach(i=>{const r=this.blockUtils.getIndexAtPixel(i,e);null!=r&&(t=r)}),null==t?this.displayIndexEnd-1:t}getChildStore(e){return this.storeUtils.getChildStore(e,this,e=>this.allRowNodes.find(t=>t.key==e))}forEachChildStoreShallow(e){this.allRowNodes.forEach(t=>{const i=t.childStore;i&&e(i)})}refreshAfterFilter(e){const t=this.storeUtils.isServerSideFilterOnServer(),i=this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e);if(!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||t&&i)return this.refreshStore(!0),void this.sortRowNodes();this.filterRowNodes(),this.sortRowNodes(),this.forEachChildStoreShallow(t=>t.refreshAfterFilter(e))}refreshAfterSort(e){const t=this.storeUtils.isServerSideSortOnServer(),i=this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e);if(this.storeUtils.isServerSideSortAllLevels()||t&&i)return this.refreshStore(!0),void this.filterRowNodes();this.filterRowNodes(),this.sortRowNodes(),this.forEachChildStoreShallow(t=>t.refreshAfterSort(e))}applyTransaction(e){switch(this.getState()){case Ng.RowNodeBlock.STATE_FAILED:return{status:Ng.ServerSideTransactionResultStatus.StoreLoadingFailed};case Ng.RowNodeBlock.STATE_LOADING:return{status:Ng.ServerSideTransactionResultStatus.StoreLoading};case Ng.RowNodeBlock.STATE_WAITING_TO_LOAD:return{status:Ng.ServerSideTransactionResultStatus.StoreWaitingToLoad}}const t=this.gos.getCallback("isApplyServerSideTransaction");if(t&&!t({transaction:e,parentNode:this.parentRowNode,groupLevelInfo:this.info}))return{status:Ng.ServerSideTransactionResultStatus.Cancelled};const i={status:Ng.ServerSideTransactionResultStatus.Applied,remove:[],update:[],add:[]},r=[];return this.executeAdd(e,i),this.executeRemove(e,i,r),this.executeUpdate(e,i,r),this.filterAndSortNodes(),this.updateSelection(r),i}updateSelection(e){if(e.length>0){this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,clearSelection:!1,source:"rowDataChanged"});const t={type:Ng.Events.EVENT_SELECTION_CHANGED,source:"rowDataChanged"};this.eventService.dispatchEvent(t)}}executeAdd(e,t){const{add:i,addIndex:r}=e;Ng._.missingOrEmpty(i)||("number"==typeof r&&r>=0?i.reverse().forEach(e=>{const i=this.createDataNode(e,r);t.add.push(i)}):i.forEach(e=>{const i=this.createDataNode(e);t.add.push(i)}))}executeRemove(e,t,i){const{remove:r}=e;if(null==r)return;const n={};r.forEach(e=>{const r=this.lookupRowNode(e);r&&(r.isSelected()&&i.push(r),r.clearRowTopAndRowIndex(),n[r.id]=!0,delete this.allNodesMap[r.id],t.remove.push(r),this.nodeManager.removeNode(r))}),this.allRowNodes=this.allRowNodes.filter(e=>!n[e.id])}executeUpdate(e,t,i){const{update:r}=e;null!=r&&r.forEach(e=>{const r=this.lookupRowNode(e);r&&(this.blockUtils.updateDataIntoRowNode(r,e),!r.selectable&&r.isSelected()&&i.push(r),t.update.push(r))})}lookupRowNode(e){const t=this.gos.getCallback("getRowId");let i;if(null!=t){const r=this.level,n=this.parentRowNode.getGroupKeys(),s=t({data:e,parentKeys:n.length>0?n:void 0,level:r});if(i=this.allNodesMap[s],!i)return console.error(`AG Grid: could not find row id=${s}, data item was not found for this id`),null}else if(i=this.allRowNodes.find(t=>t.data===e),!i)return console.error("AG Grid: could not find data item as object was not found",e),null;return i}addStoreStates(e){e.push({suppressInfiniteScroll:!0,route:this.parentRowNode.getGroupKeys(),rowCount:this.allRowNodes.length,info:this.info}),this.forEachChildStoreShallow(t=>t.addStoreStates(e))}refreshStore(e){if(e){const e=this.nodesAfterSort?this.nodesAfterSort.length:1;this.initialiseRowNodes(e)}this.scheduleLoad(),this.fireStoreUpdatedEvent()}retryLoads(){this.getState()===Ng.RowNodeBlock.STATE_FAILED&&(this.initialiseRowNodes(1),this.scheduleLoad()),this.forEachChildStoreShallow(e=>e.retryLoads())}scheduleLoad(){this.setStateWaitingToLoad(),this.rowNodeBlockLoader.checkBlockToLoad()}fireStoreUpdatedEvent(){const e={type:Ng.Events.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}getRowCount(){return this.nodesAfterSort.length}getTopLevelRowDisplayedIndex(e){return this.nodesAfterSort[e].rowIndex}isLastRowIndexKnown(){return this.getState()==Ng.RowNodeBlock.STATE_LOADED}getRowNodesInRange(e,t){const i=[];let r=!1;return Ng._.missing(e)&&(r=!0),this.nodesAfterSort.forEach(n=>{const s=n===e||n===t;(r||s)&&i.push(n),s&&(r=!r)}),r?[]:i}getStoreBounds(){return{topPx:this.topPx,heightPx:this.heightPx}}};lf([(0,Ng.Autowired)("ssrmStoreUtils")],cf.prototype,"storeUtils",2),lf([(0,Ng.Autowired)("ssrmBlockUtils")],cf.prototype,"blockUtils",2),lf([(0,Ng.Autowired)("columnModel")],cf.prototype,"columnModel",2),lf([(0,Ng.Autowired)("rowNodeBlockLoader")],cf.prototype,"rowNodeBlockLoader",2),lf([(0,Ng.Autowired)("rowNodeSorter")],cf.prototype,"rowNodeSorter",2),lf([(0,Ng.Autowired)("sortController")],cf.prototype,"sortController",2),lf([(0,Ng.Autowired)("selectionService")],cf.prototype,"selectionService",2),lf([(0,Ng.Autowired)("ssrmNodeManager")],cf.prototype,"nodeManager",2),lf([(0,Ng.Autowired)("filterManager")],cf.prototype,"filterManager",2),lf([(0,Ng.Autowired)("ssrmTransactionManager")],cf.prototype,"transactionManager",2),lf([(0,Ng.Autowired)("rowModel")],cf.prototype,"serverSideRowModel",2),lf([Ng.PostConstruct],cf.prototype,"postConstruct",1),lf([Ng.PreDestroy],cf.prototype,"destroyRowNodes",1);var uf=class{constructor(...e){if(e.length<1)throw new Error("AG Grid: At least one index must be provided.");this.indexes=e,this.maps=new Map(this.indexes.map(e=>[e,new Map]))}getSize(){return this.maps.get(this.indexes[0]).size}getBy(e,t){const i=this.maps.get(e);if(!i)throw new Error(`AG Grid: ${String(e)} not found`);return i.get(t)}set(e){this.indexes.forEach(t=>{const i=this.maps.get(t);if(!i)throw new Error(`AG Grid: ${String(t)} not found`);i.set(e[t],e)})}delete(e){this.indexes.forEach(t=>{const i=this.maps.get(t);if(!i)throw new Error(`AG Grid: ${String(t)} not found`);i.delete(e[t])})}clear(){this.maps.forEach(e=>e.clear())}getIterator(e){const t=this.maps.get(e);if(!t)throw new Error(`AG Grid: ${String(e)} not found`);return t.values()}forEach(e){const t=this.getIterator(this.indexes[0]);let i;for(;(i=t.next())&&!i.done;)e(i.value)}find(e){const t=this.getIterator(this.indexes[0]);let i;for(;(i=t.next())&&!i.done;)if(e(i.value))return i.value}filter(e){const t=this.getIterator(this.indexes[0]);let i;const r=[];for(;(i=t.next())&&!i.done;)e(i.value)&&r.push(i.value);return r}},hf=class extends kg.BeanStub{constructor(){super(...arguments),this.cacheLoadingNodesMap=new Map,this.isCheckQueued=!1,this.nextBlockToLoad=void 0}init(){this.addManagedListener(this.rowNodeBlockLoader,kg.RowNodeBlockLoader.BLOCK_LOADED_EVENT,()=>this.queueLoadCheck())}subscribe(e){this.cacheLoadingNodesMap.set(e,new Set)}unsubscribe(e){this.cacheLoadingNodesMap.delete(e)}queueLoadCheck(){this.isCheckQueued||(this.isCheckQueued=!0,window.queueMicrotask(()=>{this.queueLoadAction(),this.isCheckQueued=!1}))}queueLoadAction(){const e=this.getBlockToLoad();if(!e)return;const t=this.nextBlockToLoad&&this.nextBlockToLoad.cache===e.cache&&this.nextBlockToLoad.index===e.index;if(!(t||this.nextBlockToLoad&&t)){this.nextBlockToLoad=e,window.clearTimeout(this.loaderTimeout);const t=Number(this.nextBlockToLoad.index),i=this.nextBlockToLoad.cache,r=e.index+e.cache.getBlockSize();this.loaderTimeout=window.setTimeout(()=>{i.isAlive()&&(this.loaderTimeout=void 0,this.attemptLoad(i,t,r),this.nextBlockToLoad=void 0)},this.gos.get("blockLoadDebounceMillis"))}}attemptLoad(e,t,i){const r=this.rowNodeBlockLoader.getAvailableLoadingCount();null!=r&&0===r||(this.rowNodeBlockLoader.registerLoads(1),this.executeLoad(e,t,i),this.queueLoadCheck())}executeLoad(e,t,i){var r;const n=e.getSsrmParams(),s={startRow:t,endRow:i,rowGroupCols:n.rowGroupCols,valueCols:n.valueCols,pivotCols:n.pivotCols,pivotMode:n.pivotMode,groupKeys:e.store.getParentNode().getGroupKeys(),filterModel:n.filterModel,sortModel:n.sortModel},o=this.cacheLoadingNodesMap.get(e),a=()=>{for(let e=0;e<i-t;e++)o.delete(t+e)},l=this.gos.addGridCommonParams({request:s,success:r=>{this.rowNodeBlockLoader.loadComplete(),e.onLoadSuccess(t,i-t,r),a()},fail:()=>{this.rowNodeBlockLoader.loadComplete(),e.onLoadFailed(t,i-t),a()},parentNode:e.store.getParentNode()});(()=>{for(let e=0;e<i-t;e++)o.add(t+e)})(),null==(r=e.getSsrmParams().datasource)||r.getRows(l)}getBlockToLoad(){var e;const t=this.rowRenderer.getFirstVirtualRenderedRow(),i=this.rowRenderer.getLastVirtualRenderedRow();for(let e=t;e<=i;e++){const t=this.rowModel.getRow(e);if(!t)continue;const i=t.parent&&t.parent.childStore;if(!(i&&i instanceof pf))continue;const r=i.getCache(),n=r.getNodes().getBy("node",t);if(!n)continue;const s=this.cacheLoadingNodesMap.get(r);if(!(null==s?void 0:s.has(n.index))&&(t.__needsRefreshWhenVisible||t.stub&&!t.failedLoad))return{cache:r,index:r.getBlockStartIndex(n.index)}}let r=null,n=null,s=Number.MAX_SAFE_INTEGER;for(const e of this.cacheLoadingNodesMap.keys())e.getNodesToRefresh().forEach(o=>{if(null==o.rowIndex)return n=o,void(r=e);const a=e.getNodes().getBy("node",o);if(!a)return;const l=this.cacheLoadingNodesMap.get(e);if(null==l?void 0:l.has(a.index))return;const c=Math.abs(t-o.rowIndex),u=Math.abs(o.rowIndex-i);c<s&&(n=o,s=c,r=e),u<s&&(n=o,s=u,r=e)});if(!r)return;const o=r,a=null==(e=o.getNodes().getBy("node",n))?void 0:e.index;return null==a?void 0:{cache:o,index:o.getBlockStartIndex(a)}}isRowLoading(e,t){var i,r;return null!=(r=null==(i=this.cacheLoadingNodesMap.get(e))?void 0:i.has(t))&&r}};hf.DEFAULT_BLOCK_SIZE=100,lf([(0,kg.Autowired)("rowNodeBlockLoader")],hf.prototype,"rowNodeBlockLoader",2),lf([(0,kg.Autowired)("rowRenderer")],hf.prototype,"rowRenderer",2),lf([(0,kg.Autowired)("rowModel")],hf.prototype,"rowModel",2),lf([kg.PostConstruct],hf.prototype,"init",1),hf=lf([(0,kg.Bean)("lazyBlockLoadingService")],hf);var df=class extends Fg.BeanStub{constructor(e,t,i){super(),this.live=!0,this.removedNodeCache=new Map,this.store=e,this.numberOfRows=t,this.isLastRowKnown=!1,this.storeParams=i}init(){this.lazyBlockLoadingService.subscribe(this),this.nodeMap=new uf("index","id","node"),this.nodeDisplayIndexMap=new Map,this.nodesToRefresh=new Set,this.defaultNodeIdPrefix=this.blockUtils.createNodeIdPrefix(this.store.getParentNode()),this.getRowIdFunc=this.gos.getCallback("getRowId"),this.isMasterDetail=this.gos.get("masterDetail")}destroyRowNodes(){this.lazyBlockLoadingService.unsubscribe(this),this.numberOfRows=0,this.nodeMap.forEach(e=>this.blockUtils.destroyRowNode(e.node)),this.nodeMap.clear(),this.nodeDisplayIndexMap.clear(),this.nodesToRefresh.clear(),this.live=!1}getRowByDisplayIndex(e){var t,i,r,n;if(!this.store.isDisplayIndexInStore(e))return;const s=this.nodeDisplayIndexMap.get(e);if(s)return(s.stub||s.__needsRefreshWhenVisible)&&this.lazyBlockLoadingService.queueLoadCheck(),s;if(e===this.store.getDisplayIndexStart())return this.createStubNode(0,e);const o=this.nodeDisplayIndexMap.get(e-1);if(o){if(this.isMasterDetail&&o.master&&o.expanded)return o.detailNode;if(o.expanded&&(null==(t=o.childStore)?void 0:t.isDisplayIndexInStore(e)))return null==(i=o.childStore)?void 0:i.getRowUsingDisplayIndex(e);const r=this.nodeMap.getBy("node",o);return this.createStubNode(r.index+1,e)}const a=this.getSurroundingNodesByDisplayIndex(e);if(null==a){const t=this.store.getRowCount()-(this.store.getDisplayIndexEnd()-e);return this.createStubNode(t,e)}const{previousNode:l,nextNode:c}=a;if(l&&l.node.expanded&&(null==(r=l.node.childStore)?void 0:r.isDisplayIndexInStore(e)))return null==(n=l.node.childStore)?void 0:n.getRowUsingDisplayIndex(e);if(c){const t=c.node.rowIndex-e,i=c.index-t;return this.createStubNode(i,e)}const u=this.store.getRowCount()-(this.store.getDisplayIndexEnd()-e);return this.createStubNode(u,e)}createStubNode(e,t){const i=this.store.getRowBounds(t),r=this.createRowAtIndex(e,null,e=>{e.setRowIndex(t),e.setRowTop(i.rowTop),this.nodeDisplayIndexMap.set(t,e)});return this.lazyBlockLoadingService.queueLoadCheck(),r}getRowByStoreIndex(e){var t;return null==(t=this.nodeMap.getBy("index",e))?void 0:t.node}skipDisplayIndexes(e,t,i){if(0===e)return;const r=this.gos.getRowHeightAsNumber();t.skip(e),i.value+=e*r}setDisplayIndexes(e,t){this.nodeDisplayIndexMap.clear();const i={};this.nodeMap.forEach(e=>{i[e.index]=e.node});let r=-1;for(const n in i){const s=i[n],o=Number(n),a=o-1-r;this.skipDisplayIndexes(a,e,t),this.blockUtils.setDisplayIndex(s,e,t),this.nodeDisplayIndexMap.set(s.rowIndex,s),r=o}const n=this.numberOfRows-1-r;this.skipDisplayIndexes(n,e,t),this.purgeExcessRows()}getRowCount(){return this.numberOfRows}setRowCount(e,t){if(e<0)throw new Error("AG Grid: setRowCount can only accept a positive row count.");this.numberOfRows=e,null!=t&&(this.isLastRowKnown=t,!1===t&&(this.numberOfRows+=1)),this.fireStoreUpdatedEvent()}getNodes(){return this.nodeMap}getNodeCachedByDisplayIndex(e){var t;return null!=(t=this.nodeDisplayIndexMap.get(e))?t:null}getNodesToRefresh(){return this.nodesToRefresh}getSurroundingNodesByDisplayIndex(e){let t,i;return this.nodeMap.forEach(r=>{e>r.node.rowIndex?(null==i||i.node.rowIndex<r.node.rowIndex)&&(i=r):(null==t||t.node.rowIndex>r.node.rowIndex)&&(t=r)}),i||t?{previousNode:i,nextNode:t}:null}getDisplayIndexFromStoreIndex(e){var t,i;const r=this.nodeMap.getBy("index",e);if(r)return r.node.rowIndex;let n,s;if(this.nodeMap.forEach(t=>{e>t.index?(null==s||s.index<t.index)&&(s=t):(null==n||n.index>t.index)&&(n=t)}),!n)return this.store.getDisplayIndexEnd()-(this.numberOfRows-e);if(!s)return this.store.getDisplayIndexStart()+e;const o=e-s.index;return(null!=(i=null==(t=s.node.childStore)?void 0:t.getDisplayIndexEnd())?i:s.node.rowIndex)+o}createRowAtIndex(e,t,i){var r,n;const s=this.nodeMap.getBy("index",e);if(s){const{node:i}=s;if(i.__needsRefreshWhenVisible=!1,this.doesNodeMatch(t,i))return this.blockUtils.updateDataIntoRowNode(i,t),this.nodesToRefresh.delete(i),i;if(null==this.getRowIdFunc&&i.hasChildren()&&i.expanded)return this.nodesToRefresh.delete(i),i;this.destroyRowAtIndex(e)}if(t&&null!=this.getRowIdFunc){const i=this.getRowId(t),s=i&&(null==(r=this.removedNodeCache)?void 0:r.get(i));if(s)return null==(n=this.removedNodeCache)||n.delete(i),this.blockUtils.updateDataIntoRowNode(s,t),this.nodeMap.set({id:s.id,node:s,index:e}),s;const o=this.nodeMap.getBy("id",i);if(o){this.nodeMap.delete(o);const{node:i,index:r}=o;return this.blockUtils.updateDataIntoRowNode(i,t),this.nodeMap.set({id:i.id,node:i,index:e}),this.nodesToRefresh.delete(i),this.getBlockStartIndex(r)===this.getBlockStartIndex(e)||this.markBlockForVerify(r),i}}const o=this.blockUtils.createRowNode(this.store.getRowDetails());if(null!=t){const e=this.getPrefixedId(this.store.getIdSequence().next());this.blockUtils.setDataIntoRowNode(o,t,e,void 0),this.serverSideRowModel.setPaused(!0),this.blockUtils.checkOpenByDefault(o),this.serverSideRowModel.setPaused(!1),this.nodeManager.addRowNode(o)}return this.nodeMap.set({id:o.id,node:o,index:e}),i&&i(o),o}getBlockStates(){const e={},t={};this.nodeMap.forEach(({node:i,index:r})=>{var n;const s=this.getBlockStartIndex(r);i.stub||i.failedLoad||(e[s]=(null!=(n=e[s])?n:0)+1);let o="loaded";i.failedLoad?o="failed":this.lazyBlockLoadingService.isRowLoading(this,s)?o="loading":(this.nodesToRefresh.has(i)||i.stub)&&(o="needsLoading"),t[s]||(t[s]=new Set),t[s].add(o)});const i={loading:4,failed:3,needsLoading:2,loaded:1},r=this.blockUtils.createNodeIdPrefix(this.store.getParentNode()),n={};return Object.entries(t).forEach(([t,s])=>{var o;const a=[...s].sort((e,t)=>{var r,n;return(null!=(r=i[e])?r:0)-(null!=(n=i[t])?n:0)})[0],l=Number(t)/this.getBlockSize(),c=r?`${r}-${l}`:String(l);n[c]={blockNumber:l,startRow:Number(t),endRow:Number(t)+this.getBlockSize(),pageStatus:a,loadedRowCount:null!=(o=e[t])?o:0}}),n}destroyRowAtIndex(e){const t=this.nodeMap.getBy("index",e);t&&(this.nodeMap.delete(t),this.nodeDisplayIndexMap.delete(t.node.rowIndex),this.nodesToRefresh.size>0?this.removedNodeCache.set(t.node.id,t.node):this.blockUtils.destroyRowNode(t.node),this.nodesToRefresh.delete(t.node))}getSsrmParams(){return this.store.getSsrmParams()}getPrefixedId(e){return this.defaultNodeIdPrefix?this.defaultNodeIdPrefix+"-"+e:e.toString()}markBlockForVerify(e){const[t,i]=this.getBlockBounds(e);this.nodeMap.filter(e=>e.index>=t&&e.index<i).forEach(({node:e})=>{e.__needsRefreshWhenVisible=!0})}doesNodeMatch(e,t){if(t.stub)return!1;if(null!=this.getRowIdFunc){const i=this.getRowId(e);return t.id===i}return t.data===e}purgeStubsOutsideOfViewport(){const e=this.api.getFirstDisplayedRowIndex(),t=this.api.getLastDisplayedRowIndex(),i=this.getBlockStartIndex(e),[r,n]=this.getBlockBounds(t);this.nodeMap.forEach(e=>{this.lazyBlockLoadingService.isRowLoading(this,e.index)||e.node.failedLoad||e.node.stub&&(e.index<i||e.index>n)&&this.destroyRowAtIndex(e.index)})}getBlocksDistanceFromRow(e,t){const i={};return e.forEach(({node:e,index:r})=>{const[n,s]=this.getBlockBounds(r);if(n in i)return;const o=Math.abs(e.rowIndex-t);let a;const l=this.nodeMap.getBy("index",[s-1]);l&&(a=Math.abs(l.node.rowIndex-t));const c=null==a||o<a?o:a;i[n]=c}),Object.entries(i)}purgeExcessRows(){var e;if(this.purgeStubsOutsideOfViewport(),null==this.store.getDisplayIndexEnd()||null==this.storeParams.maxBlocksInCache)return;const t=this.api.getFirstDisplayedRowIndex(),i=this.api.getLastDisplayedRowIndex(),r=new Set,n=new Set;this.nodeMap.forEach(({index:e,node:s})=>{const o=this.getBlockStartIndex(e);r.add(o),s.rowIndex>=t&&s.rowIndex<=i&&n.add(o)});const s=Math.max(n.size,null!=(e=this.storeParams.maxBlocksInCache)?e:0),o=r.size-s;if(o<=0)return;let a=Number.MAX_SAFE_INTEGER,l=Number.MIN_SAFE_INTEGER;n.forEach(e=>{a>e&&(a=e),l<e&&(l=e)});const c=this.nodeMap.filter(({node:e,index:t})=>{const i=this.getBlockStartIndex(t);return!(i>=a&&i<=l||this.isNodeCached(e))});if(0===c.length)return;const u=t+(i-t)/2,h=this.getBlocksDistanceFromRow(c,u),d=this.getBlockSize();h.sort((e,t)=>Math.sign(t[1]-e[1]));for(let e=0;e<Math.min(o,h.length);e++){const t=Number(h[e][0]);for(let e=t;e<t+d;e++){const t=this.nodeMap.getBy("index",e);t&&!this.isNodeCached(t.node)&&this.destroyRowAtIndex(e)}}}isNodeFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();return!!t&&(null==t.rowPinned&&t.rowIndex===e.rowIndex)}isNodeCached(e){return e.isExpandable()&&e.expanded||this.isNodeFocused(e)}extractDuplicateIds(e){if(null==this.getRowIdFunc)return[];const t=new Set,i=new Set;return e.forEach(e=>{const r=this.getRowId(e);t.has(r)?i.add(r):t.add(r)}),[...i]}onLoadSuccess(e,t,i){if(!this.live)return;const r=i.groupLevelInfo;if(this.store.setStoreInfo(r),null!=this.getRowIdFunc){const r=this.extractDuplicateIds(i.rowData);if(r.length>0){const i=r.join(", ");return console.warn(`AG Grid: Unable to display rows as duplicate row ids (${i}) were returned by the getRowId callback. Please modify the getRowId callback to provide unique ids.`),void this.onLoadFailed(e,t)}}i.pivotResultFields&&this.serverSideRowModel.generateSecondaryColumns(i.pivotResultFields);const n=this.nodesToRefresh.size>0;if(i.rowData.forEach((t,i)=>{var r;const n=e+i,s=this.nodeMap.getBy("index",n);if(!(null==(r=null==s?void 0:s.node)?void 0:r.stub))return s&&this.doesNodeMatch(t,s.node)?(this.blockUtils.updateDataIntoRowNode(s.node,t),this.nodesToRefresh.delete(s.node),void(s.node.__needsRefreshWhenVisible=!1)):void this.createRowAtIndex(n,t);this.createRowAtIndex(n,t)}),null!=i.rowCount&&-1!==i.rowCount)this.numberOfRows=i.rowCount,this.isLastRowKnown=!0;else if(t>i.rowData.length)this.numberOfRows=e+i.rowData.length,this.isLastRowKnown=!0;else if(!this.isLastRowKnown){const t=e+i.rowData.length+1;t>this.numberOfRows&&(this.numberOfRows=t)}this.isLastRowKnown&&this.nodeMap.filter(e=>e.index>=this.numberOfRows).forEach(e=>this.destroyRowAtIndex(e.index)),this.fireStoreUpdatedEvent();const s=0===this.nodesToRefresh.size;n&&s&&this.fireRefreshFinishedEvent()}fireRefreshFinishedEvent(){0===this.nodesToRefresh.size&&(this.removedNodeCache.forEach(e=>{this.blockUtils.destroyRowNode(e)}),this.removedNodeCache=new Map,this.store.fireRefreshFinishedEvent())}isStoreFullyLoaded(){const e=this.isLastRowKnown,t=this.nodeMap.getSize()===this.numberOfRows;if(!e||!t)return;if(this.nodesToRefresh.size>0)return;let i=-1;return null==this.nodeMap.find(e=>(i+=1,e.index!==i||!!e.node.__needsRefreshWhenVisible||!!e.node.stub))}isLastRowIndexKnown(){return this.isLastRowKnown}onLoadFailed(e,t){var i;if(!this.live)return;const r=this.nodesToRefresh.size>0;for(let r=e;r<e+t&&r<this.getRowCount();r++){let{node:e}=null!=(i=this.nodeMap.getBy("index",r))?i:{};e&&this.nodesToRefresh.delete(e),e&&e.stub||(e&&!e.stub&&this.destroyRowAtIndex(r),e=this.createRowAtIndex(r)),e.__needsRefreshWhenVisible=!1,e.failedLoad=!0}const n=0===this.nodesToRefresh.size;r&&n&&this.fireRefreshFinishedEvent(),this.fireStoreUpdatedEvent()}markNodesForRefresh(){this.nodeMap.forEach(e=>{e.node.stub&&!e.node.failedLoad||this.nodesToRefresh.add(e.node)}),this.lazyBlockLoadingService.queueLoadCheck(),this.isLastRowKnown&&0===this.numberOfRows&&(this.numberOfRows=1,this.isLastRowKnown=!1,this.fireStoreUpdatedEvent())}isNodeInCache(e){return!!this.nodeMap.getBy("id",e)}fireStoreUpdatedEvent(){this.live&&this.store.fireStoreUpdatedEvent()}getRowId(e){if(null==this.getRowIdFunc)return null;const{level:t}=this.store.getRowDetails(),i=this.store.getParentNode().getGroupKeys(),r=this.getRowIdFunc({data:e,parentKeys:i.length>0?i:void 0,level:t});return String(r)}getOrderedNodeMap(){const e={};return this.nodeMap.forEach(t=>e[t.index]=t),e}clearDisplayIndexes(){this.nodeDisplayIndexMap.clear()}clientSideSortRows(){const e=this.sortController.getSortOptions();if(!e.some(e=>null!=e.sort))return;const t=new Array(this.nodeMap.getSize());this.nodeMap.forEach(e=>t[e.index]=e.node),this.nodeMap.clear(),this.rowNodeSorter.doFullSort(t,e).forEach((e,t)=>{this.nodeMap.set({id:e.id,node:e,index:t})})}updateRowNodes(e){if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const t=[];return e.forEach(e=>{const i=this.getRowId(e),r=this.nodeMap.getBy("id",i);r&&(this.blockUtils.updateDataIntoRowNode(r.node,e),t.push(r.node))}),t}insertRowNodes(e,t){const i=this.store.getRowCount()-(this.store.getParentNode().sibling?1:0),r=null==t&&this.isLastRowKnown?i:t;if(null==r||i<r)return[];if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const n={};e.forEach(e=>{const t=this.getRowId(e);t&&this.isNodeInCache(t)||(n[t]=e)});const s=Object.values(n);let o=s.length;if(0===o)return[];const a=this.nodeMap.filter(e=>e.index>=r);return a.forEach(e=>this.nodeMap.delete(e)),a.forEach(e=>{this.nodeMap.set({node:e.node,index:e.index+o,id:e.id})}),this.numberOfRows+=o,s.map((e,t)=>this.createRowAtIndex(r+t,e))}removeRowNodes(e){if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const t=[],i=[];let r=0;const n=[...e],s=this.getOrderedNodeMap();let o=-1;for(let e in s){o+=1;const a=s[e],l=n.findIndex(e=>e===a.id);if(-1!==l){n.splice(l,1),this.destroyRowAtIndex(Number(e)),t.push(a.node),r+=1;continue}if(0===r)continue;const c=Number(e);o!==c&&i.push(a.node),this.nodeMap.delete(s[e]),this.nodeMap.set({id:a.id,node:a.node,index:c-r})}return this.numberOfRows-=this.isLastRowIndexKnown()?e.length:r,n.length>0&&i.length>0&&(i.forEach(e=>e.__needsRefreshWhenVisible=!0),this.lazyBlockLoadingService.queueLoadCheck()),t}getBlockSize(){return this.storeParams.cacheBlockSize||hf.DEFAULT_BLOCK_SIZE}getBlockStartIndex(e){return e-e%this.getBlockSize()}getBlockBounds(e){const t=this.getBlockStartIndex(e);return[t,t+this.getBlockSize()]}};lf([(0,Fg.Autowired)("gridApi")],df.prototype,"api",2),lf([(0,Fg.Autowired)("ssrmBlockUtils")],df.prototype,"blockUtils",2),lf([(0,Fg.Autowired)("focusService")],df.prototype,"focusService",2),lf([(0,Fg.Autowired)("ssrmNodeManager")],df.prototype,"nodeManager",2),lf([(0,Fg.Autowired)("rowModel")],df.prototype,"serverSideRowModel",2),lf([(0,Fg.Autowired)("rowNodeSorter")],df.prototype,"rowNodeSorter",2),lf([(0,Fg.Autowired)("sortController")],df.prototype,"sortController",2),lf([(0,Fg.Autowired)("lazyBlockLoadingService")],df.prototype,"lazyBlockLoadingService",2),lf([Fg.PostConstruct],df.prototype,"init",1),lf([Fg.PreDestroy],df.prototype,"destroyRowNodes",1);var pf=class extends Og.BeanStub{constructor(e,t,i){super(),this.idSequence=new Og.NumberSequence,this.ssrmParams=e,this.parentRowNode=i,this.storeParams=t,this.level=i.level+1,this.group=!!e.rowGroupCols&&this.level<e.rowGroupCols.length,this.leafGroup=!!e.rowGroupCols&&this.level===e.rowGroupCols.length-1,this.info={}}init(){var e;let t=1;if(0===this.level&&(t=null!=(e=this.storeUtils.getServerSideInitialRowCount())?e:1,this.eventService.dispatchEventOnce({type:Og.Events.EVENT_ROW_COUNT_READY})),this.cache=this.createManagedBean(new df(this,t,this.storeParams)),!this.gos.get("treeData")&&this.group){const e=this.ssrmParams.rowGroupCols[this.level];this.groupField=e.field,this.rowGroupColumn=this.columnModel.getRowGroupColumns()[this.level]}}destroyRowNodes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.destroyBean(this.cache)}applyRowData(e,t,i){this.cache.onLoadSuccess(t,i,e)}applyTransaction(e){var t,i,r;const n=this.gos.getCallback("getRowId");if(!n)return console.warn("AG Grid: getRowId callback must be implemented for transactions to work. Transaction was ignored."),{status:Og.ServerSideTransactionResultStatus.Cancelled};const s=this.gos.getCallback("isApplyServerSideTransaction");if(s&&!s({transaction:e,parentNode:this.parentRowNode,groupLevelInfo:this.info}))return{status:Og.ServerSideTransactionResultStatus.Cancelled};const o=this.cache.isStoreFullyLoaded();let a,l,c;if((null==(t=e.update)?void 0:t.length)&&(a=this.cache.updateRowNodes(e.update)),null==(i=e.add)?void 0:i.length){let t=e.addIndex;null!=t&&t<0&&(t=void 0),l=this.cache.insertRowNodes(e.add,t)}if(null==(r=e.remove)?void 0:r.length){const t=e.remove.map(e=>n({level:this.level,parentKeys:this.parentRowNode.getGroupKeys(),data:e})),i=[...new Set(t)];c=this.cache.removeRowNodes(i)}const u=this.gos.get("serverSideEnableClientSideSort"),h=(null==a?void 0:a.length)||(null==l?void 0:l.length);return o&&u&&h&&this.cache.clientSideSortRows(),this.updateSelectionAfterTransaction(a,c),{status:Og.ServerSideTransactionResultStatus.Applied,update:a,add:l,remove:c}}updateSelectionAfterTransaction(e,t){const i=[];null==e||e.forEach(e=>{e.isSelected()&&!e.selectable&&i.push(e)}),null==t||t.forEach(e=>{e.isSelected()&&i.push(e)}),i.length&&this.selectionService.setNodesSelected({newValue:!1,clearSelection:!1,nodes:i,source:"rowDataChanged"})}clearDisplayIndexes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.cache.getNodes().forEach(e=>this.blockUtils.clearDisplayIndex(e.node)),this.parentRowNode.sibling&&this.blockUtils.clearDisplayIndex(this.parentRowNode.sibling),this.cache.clearDisplayIndexes()}getDisplayIndexStart(){return this.displayIndexStart}getDisplayIndexEnd(){return this.displayIndexEnd}getRowCount(){return this.parentRowNode.sibling?this.cache.getRowCount()+1:this.cache.getRowCount()}setRowCount(e,t){this.cache.setRowCount(e,t)}isDisplayIndexInStore(e){return 0!==this.cache.getRowCount()&&this.displayIndexStart<=e&&e<this.getDisplayIndexEnd()}setDisplayIndexes(e,t){this.displayIndexStart=e.peek(),this.topPx=t.value;const i=this.parentRowNode.level>-1&&this.gos.getGroupTotalRowCallback()({node:this.parentRowNode});i||this.parentRowNode.destroyFooter(),"top"===i&&(this.parentRowNode.createFooter(),this.blockUtils.setDisplayIndex(this.parentRowNode.sibling,e,t)),this.cache.setDisplayIndexes(e,t),"bottom"===i&&(this.parentRowNode.createFooter(),this.blockUtils.setDisplayIndex(this.parentRowNode.sibling,e,t)),this.displayIndexEnd=e.peek(),this.heightPx=t.value-this.topPx}forEachStoreDeep(e,t=new Og.NumberSequence){e(this,t.next()),this.cache.getNodes().forEach(i=>{const r=i.node.childStore;r&&r.forEachStoreDeep(e,t)})}forEachNodeDeep(e,t=new Og.NumberSequence){this.cache.getNodes().forEach(i=>{e(i.node,t.next());const r=i.node.childStore;r&&r.forEachNodeDeep(e,t)})}forEachNodeDeepAfterFilterAndSort(e,t=new Og.NumberSequence,i=!1){const r=this.parentRowNode.level>-1&&this.gos.getGroupTotalRowCallback()({node:this.parentRowNode});"top"===r&&e(this.parentRowNode.sibling,t.next());const n=this.cache.getOrderedNodeMap();for(let r in n){const s=n[r];e(s.node,t.next());const o=s.node.childStore;o&&o.forEachNodeDeepAfterFilterAndSort(e,t,i)}"bottom"===r&&e(this.parentRowNode.sibling,t.next())}retryLoads(){this.cache.getNodes().forEach(({node:e})=>{e.failedLoad&&(e.failedLoad=!1,e.__needsRefreshWhenVisible=!0,e.stub=!0)}),this.forEachChildStoreShallow(e=>e.retryLoads()),this.fireStoreUpdatedEvent()}getRowUsingDisplayIndex(e){return this.parentRowNode.sibling&&e===this.parentRowNode.sibling.rowIndex?this.parentRowNode.sibling:this.cache.getRowByDisplayIndex(e)}getRowBounds(e){var t;if(!this.isDisplayIndexInStore(e))return null;const i=this.cache.getNodeCachedByDisplayIndex(e);if(i){const t=this.blockUtils.extractRowBounds(i,e);if(t)return t}const{previousNode:r,nextNode:n}=null!=(t=this.cache.getSurroundingNodesByDisplayIndex(e))?t:{};if(r){const t=this.blockUtils.extractRowBounds(r.node,e);if(null!=t)return t}const s=this.gos.getRowHeightAsNumber();if(n){const t=(n.node.rowIndex-e)*s;return{rowTop:n.node.rowTop-t,rowHeight:s}}return{rowTop:this.topPx+this.heightPx-(this.getDisplayIndexEnd()-e)*s,rowHeight:s}}isPixelInRange(e){return e>=this.topPx&&e<this.topPx+this.heightPx}getRowIndexAtPixel(e){if(e<this.topPx)return this.getDisplayIndexStart();if(e>=this.topPx+this.heightPx)return this.getDisplayIndexEnd()-1;if(this.parentRowNode.sibling&&e>this.parentRowNode.sibling.rowTop&&e<this.parentRowNode.sibling.rowTop+this.parentRowNode.sibling.rowHeight)return this.parentRowNode.sibling.rowIndex;let t=Number.MAX_SAFE_INTEGER,i=null,r=Number.MAX_SAFE_INTEGER,n=null;if(this.cache.getNodes().forEach(({node:s})=>{const o=Math.abs(e-s.rowTop);s.rowTop<e?o<t&&(t=o,i=s):o<r&&(r=o,n=s)}),i){const t=this.blockUtils.getIndexAtPixel(i,e);if(null!=t)return t}const s=this.gos.getRowHeightAsNumber();if(n){const t=n.rowTop,i=Math.ceil((t-e)/s);return n.rowIndex-i}const o=this.topPx+this.heightPx,a=Math.floor((o-e)/s);return this.getDisplayIndexEnd()-a}getChildStore(e){return this.storeUtils.getChildStore(e,this,e=>{const t=this.cache.getNodes().find(t=>t.node.key==e);return t?t.node:null})}forEachChildStoreShallow(e){this.cache.getNodes().forEach(({node:t})=>{t.childStore&&e(t.childStore)})}refreshAfterSort(e){if(this.storeUtils.isServerSideSortAllLevels()||this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e)){const e=this.cache.isStoreFullyLoaded(),t=this.gos.get("serverSideEnableClientSideSort");if(!e||!t){const e=this.cache.getRowCount();return this.destroyBean(this.cache),void(this.cache=this.createManagedBean(new df(this,e,this.storeParams)))}this.cache.clientSideSortRows()}this.forEachChildStoreShallow(t=>t.refreshAfterSort(e))}refreshAfterFilter(e){!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e)?this.refreshStore(!0):this.forEachChildStoreShallow(t=>t.refreshAfterFilter(e))}refreshStore(e){if(e)return this.destroyBean(this.cache),this.cache=this.createManagedBean(new df(this,1,this.storeParams)),void this.fireStoreUpdatedEvent();this.cache.markNodesForRefresh()}getTopLevelRowDisplayedIndex(e){const t=this.cache.getDisplayIndexFromStoreIndex(e);return null!=t?t:e}isLastRowIndexKnown(){return this.cache.isLastRowIndexKnown()}getRowNodesInRange(e,t){let i=!1;return Og._.missing(e)&&!0,this.cache.getNodes().filter(({node:i})=>i.rowIndex>=e.rowIndex&&i.rowIndex<=t.rowIndex).map(({node:e})=>e)}addStoreStates(e){e.push({suppressInfiniteScroll:!1,route:this.parentRowNode.getGroupKeys(),rowCount:this.getRowCount(),lastRowIndexKnown:this.isLastRowIndexKnown(),info:this.info,maxBlocksInCache:this.storeParams.maxBlocksInCache,cacheBlockSize:this.storeParams.cacheBlockSize}),this.forEachChildStoreShallow(t=>t.addStoreStates(e))}getIdSequence(){return this.idSequence}getParentNode(){return this.parentRowNode}getRowDetails(){return{field:this.groupField,group:this.group,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn}}getSsrmParams(){return this.ssrmParams}setStoreInfo(e){e&&Object.assign(this.info,e)}fireStoreUpdatedEvent(){const e={type:Og.Events.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}fireRefreshFinishedEvent(){const e={type:Og.Events.EVENT_STORE_REFRESHED,route:this.parentRowNode.getRoute()};this.eventService.dispatchEvent(e)}getBlockStates(){return this.cache.getBlockStates()}getStoreBounds(){return{topPx:this.topPx,heightPx:this.heightPx}}getCache(){return this.cache}};lf([(0,Og.Autowired)("ssrmBlockUtils")],pf.prototype,"blockUtils",2),lf([(0,Og.Autowired)("ssrmStoreUtils")],pf.prototype,"storeUtils",2),lf([(0,Og.Autowired)("columnModel")],pf.prototype,"columnModel",2),lf([(0,Og.Autowired)("selectionService")],pf.prototype,"selectionService",2),lf([Og.PostConstruct],pf.prototype,"init",1),lf([Og.PreDestroy],pf.prototype,"destroyRowNodes",1);var gf=class extends Lg.BeanStub{constructor(){super(...arguments),this.onRowHeightChanged_debounced=Lg._.debounce(this.onRowHeightChanged.bind(this),100),this.pauseStoreUpdateListening=!1,this.started=!1,this.managingPivotResultColumns=!1}ensureRowHeightsValid(){return!1}start(){this.started=!0,this.updateDatasource()}destroyDatasource(){this.datasource&&(this.datasource.destroy&&this.datasource.destroy(),this.rowRenderer.datasourceChanged(),this.datasource=void 0)}addEventListeners(){this.addManagedListener(this.eventService,Lg.Events.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverything.bind(this)),this.addManagedListener(this.eventService,Lg.Events.EVENT_STORE_UPDATED,this.onStoreUpdated.bind(this));const e=this.resetRootStore.bind(this);this.addManagedListener(this.eventService,Lg.Events.EVENT_COLUMN_VALUE_CHANGED,e),this.addManagedListener(this.eventService,Lg.Events.EVENT_COLUMN_PIVOT_CHANGED,e),this.addManagedListener(this.eventService,Lg.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.addManagedListener(this.eventService,Lg.Events.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedPropertyListeners(["masterDetail","treeData","removePivotHeaderRowWhenSingleValueColumn","suppressServerSideInfiniteScroll","cacheBlockSize"],e),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights()),this.verifyProps(),this.addManagedPropertyListener("serverSideDatasource",()=>this.updateDatasource())}updateDatasource(){const e=this.gos.get("serverSideDatasource");e&&this.setDatasource(e)}verifyProps(){this.gos.exists("initialGroupOrderComparator")&&Lg._.warnOnce("initialGroupOrderComparator cannot be used with Server Side Row Model."),this.gos.isRowSelection()&&!this.gos.exists("getRowId")&&Lg._.warnOnce("getRowId callback must be provided for Server Side Row Model selection to work correctly.")}setDatasource(e){this.started&&(this.destroyDatasource(),this.datasource=e,this.resetRootStore())}applyRowData(e,t,i){const r=this.getRootStore();if(!r)return;const n=r.getChildStore(i);n&&(n instanceof pf?n.applyRowData(e,t,e.rowData.length):n instanceof cf&&n.processServerResult(e))}isLastRowIndexKnown(){const e=this.getRootStore();return!!e&&e.isLastRowIndexKnown()}onColumnEverything(){if(!this.storeParams)return void this.resetRootStore();const e=this.columnsToValueObjects(this.columnModel.getRowGroupColumns()),t=this.columnsToValueObjects(this.columnModel.getValueColumns()),i=this.columnsToValueObjects(this.columnModel.getPivotColumns()),r=e=>{const t={};e.oldCols.forEach(e=>t[e.id]=e);const i=e.newCols.every(e=>{const i=t[e.id];return i&&delete t[e.id],i&&i.field===e.field&&i.aggFunc===e.aggFunc}),r=!e.allowRemovedColumns&&!!Object.values(t).length;return i&&!r},n=!Lg._.jsonEquals(this.storeParams.sortModel,this.sortController.getSortModel()),s=!r({oldCols:this.storeParams.rowGroupCols,newCols:e}),o=!r({oldCols:this.storeParams.pivotCols,newCols:i}),a=!!(null==e?void 0:e.length)&&!r({oldCols:this.storeParams.valueCols,newCols:t,allowRemovedColumns:!0});if(n||s||o||a)this.resetRootStore();else{const e=this.createStoreParams();this.storeParams.rowGroupCols=e.rowGroupCols,this.storeParams.pivotCols=e.pivotCols,this.storeParams.valueCols=e.valueCols}}destroyRootStore(){this.rootNode&&this.rootNode.childStore&&(this.rootNode.childStore=this.destroyBean(this.rootNode.childStore),this.nodeManager.clear())}refreshAfterSort(e,t){this.storeParams&&(this.storeParams.sortModel=e);const i=this.getRootStore();i&&(i.refreshAfterSort(t),this.onStoreUpdated())}generateSecondaryColumns(e){if(!this.pivotColDefService)return void Lg.ModuleRegistry.__assertRegistered(Lg.ModuleNames.RowGroupingModule,"pivotResultFields",this.context.getGridId());const t=this.pivotColDefService.createColDefsFromFields(e);this.managingPivotResultColumns=!0,this.columnModel.setSecondaryColumns(t,"rowModelUpdated")}resetRowHeights(){const e=this.resetRowHeightsForAllRowNodes(),t=this.gos.getRowHeightForNode(this.rootNode);if(this.rootNode.setRowHeight(t.height,t.estimated),this.rootNode.sibling){const e=this.gos.getRowHeightForNode(this.rootNode.sibling);this.rootNode.sibling.setRowHeight(e.height,e.estimated)}e&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{const i=this.gos.getRowHeightForNode(t);t.setRowHeight(i.height,i.estimated);const r=t.detailNode;if(r){const e=this.gos.getRowHeightForNode(r);r.setRowHeight(e.height,e.estimated)}if(t.sibling){const e=this.gos.getRowHeightForNode(t.sibling);r.setRowHeight(e.height,e.estimated)}e=!0}),e}resetRootStore(){this.destroyRootStore(),this.rootNode=new Lg.RowNode(this.beans),this.rootNode.group=!0,this.rootNode.level=-1,this.datasource&&(this.storeParams=this.createStoreParams(),this.rootNode.childStore=this.createBean(this.storeFactory.createStore(this.storeParams,this.rootNode)),this.updateRowIndexesAndBounds()),this.managingPivotResultColumns&&(this.columnModel.setSecondaryColumns(null,"api"),this.managingPivotResultColumns=!1),this.dispatchModelUpdated(!0)}columnsToValueObjects(e){return e.map(e=>({id:e.getId(),aggFunc:e.getAggFunc(),displayName:this.columnModel.getDisplayNameForColumn(e,"model"),field:e.getColDef().field}))}createStoreParams(){const e=this.columnsToValueObjects(this.columnModel.getRowGroupColumns()),t=this.columnsToValueObjects(this.columnModel.getValueColumns()),i=this.columnsToValueObjects(this.columnModel.getPivotColumns()),r=this.gos.isGetRowHeightFunction();return{valueCols:t,rowGroupCols:e,pivotCols:i,pivotMode:this.columnModel.isPivotMode(),filterModel:this.filterManager.isAdvancedFilterEnabled()?this.filterManager.getAdvancedFilterModel():this.filterManager.getFilterModel(),sortModel:this.sortController.getSortModel(),datasource:this.datasource,lastAccessedSequence:new Lg.NumberSequence,dynamicRowHeight:r}}getParams(){return this.storeParams}dispatchModelUpdated(e=!1){const t={type:Lg.Events.EVENT_MODEL_UPDATED,animate:!e,keepRenderedRows:!e,newPage:!1,newData:!1};this.eventService.dispatchEvent(t)}onStoreUpdated(){this.pauseStoreUpdateListening||(this.updateRowIndexesAndBounds(),this.dispatchModelUpdated())}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}onRowHeightChanged(){this.updateRowIndexesAndBounds(),this.dispatchModelUpdated()}updateRowIndexesAndBounds(){const e=this.getRootStore();e&&e.setDisplayIndexes(new Lg.NumberSequence,{value:0})}retryLoads(){const e=this.getRootStore();e&&(e.retryLoads(),this.onStoreUpdated())}getRow(e){const t=this.getRootStore();if(t)return t.getRowUsingDisplayIndex(e)}setPaused(e){this.pauseStoreUpdateListening=e}expandAll(e){this.pauseStoreUpdateListening=!0,this.forEachNode(t=>{t.stub||t.hasChildren()&&t.setExpanded(e)}),this.pauseStoreUpdateListening=!1,this.onStoreUpdated()}refreshAfterFilter(e,t){this.storeParams&&(this.storeParams.filterModel=e);const i=this.getRootStore();i&&(i.refreshAfterFilter(t),this.onStoreUpdated())}getRootStore(){if(this.rootNode&&this.rootNode.childStore)return this.rootNode.childStore}getRowCount(){const e=this.getRootStore();return e?e.getDisplayIndexEnd():0}getTopLevelRowCount(){const e=this.getRootStore();return e?e.getRowCount():1}getTopLevelRowDisplayedIndex(e){const t=this.getRootStore();return t?t.getTopLevelRowDisplayedIndex(e):e}getRowBounds(e){const t=this.getRootStore();return t?t.getRowBounds(e):{rowTop:0,rowHeight:this.gos.getRowHeightAsNumber()}}getBlockStates(){const e=this.getRootStore();if(!e)return;const t={};return e.forEachStoreDeep(e=>{if(e instanceof cf){const{id:i,state:r}=e.getBlockStateJson();t[i]=r}else{if(!(e instanceof pf))throw new Error("AG Grid: Unsupported store type");Object.entries(e.getBlockStates()).forEach(([e,i])=>{t[e]=i})}}),t}getRowIndexAtPixel(e){const t=this.getRootStore();return e<=0||!t?0:t.getRowIndexAtPixel(e)}isEmpty(){return!1}isRowsToRender(){return null!=this.getRootStore()&&this.getRowCount()>0}getType(){return"serverSide"}forEachNode(e){const t=this.getRootStore();t&&t.forEachNodeDeep(e)}forEachNodeAfterFilterAndSort(e,t=!1){const i=this.getRootStore();i&&i.forEachNodeDeepAfterFilterAndSort(e,void 0,t)}executeOnStore(e,t){if(!this.started)return!1;const i=this.getRootStore();if(!i)return!0;const r=i.getChildStore(e);return r&&t(r),!0}refreshStore(e={}){const t=e.route?e.route:[];this.executeOnStore(t,t=>t.refreshStore(1==e.purge))}getStoreState(){const e=[],t=this.getRootStore();return t&&t.addStoreStates(e),e}getNodesInRangeForSelection(e,t){if(!Lg._.exists(e))return[];if(!t)return[e];const i=e.rowIndex,r=t.rowIndex;if(null===i||null===r)return[e];const n=[],[s,o]=[i,r].sort((e,t)=>e-t);return this.forEachNode(e=>{const t=e.rowIndex;null==t||e.stub||t>=s&&t<=o&&n.push(e)}),n.length!==o-s+1?[e]:n}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i),i.detailNode&&i.detailNode.id===e&&(t=i.detailNode)}),t}isRowPresent(e){return!!this.getRowNode(e.id)}setRowCount(e,t){const i=this.getRootStore();if(i){if(i instanceof pf)return void i.setRowCount(e,t);console.error("AG Grid: Infinite scrolling must be enabled in order to set the row count.")}}};lf([(0,Lg.Autowired)("columnModel")],gf.prototype,"columnModel",2),lf([(0,Lg.Autowired)("filterManager")],gf.prototype,"filterManager",2),lf([(0,Lg.Autowired)("sortController")],gf.prototype,"sortController",2),lf([(0,Lg.Autowired)("rowRenderer")],gf.prototype,"rowRenderer",2),lf([(0,Lg.Autowired)("ssrmNodeManager")],gf.prototype,"nodeManager",2),lf([(0,Lg.Autowired)("ssrmStoreFactory")],gf.prototype,"storeFactory",2),lf([(0,Lg.Autowired)("beans")],gf.prototype,"beans",2),lf([(0,Lg.Optional)("pivotColDefService")],gf.prototype,"pivotColDefService",2),lf([Lg.PreDestroy],gf.prototype,"destroyDatasource",1),lf([Lg.PostConstruct],gf.prototype,"addEventListeners",1),lf([Lg.PreDestroy],gf.prototype,"destroyRootStore",1),gf=lf([(0,Lg.Bean)("rowModel")],gf);var ff=class extends Gg.BeanStub{loadFromDatasource(e){const{storeParams:t,parentBlock:i,parentNode:r}=e,n=r.getGroupKeys();if(!t.datasource)return;const s={startRow:e.startRow,endRow:e.endRow,rowGroupCols:t.rowGroupCols,valueCols:t.valueCols,pivotCols:t.pivotCols,pivotMode:t.pivotMode,groupKeys:n,filterModel:t.filterModel,sortModel:t.sortModel},o=this.gos.addGridCommonParams({success:e.success,fail:e.fail,request:s,parentNode:e.parentNode});window.setTimeout(()=>{t.datasource&&i.isAlive()?t.datasource.getRows(o):e.fail()},0)}getChildStore(e,t,i){if(Gg._.missingOrEmpty(e))return t;const r=i(e[0]);if(r){if(1===e.length&&!r.childStore){const e=this.serverSideRowModel.getParams();r.childStore=this.createBean(this.storeFactory.createStore(e,r))}const t=e.slice(1,e.length),i=r.childStore;return i?i.getChildStore(t):null}return null}isServerRefreshNeeded(e,t,i){if(i.valueColChanged||i.secondaryColChanged)return!0;const r=e.level+1;if(!(r<t.length))return!0;const n=t[r].id;return i.changedColumns.indexOf(n)>-1||this.columnModel.getAllGridColumns().filter(e=>e.getColDef().showRowGroup&&i.changedColumns.includes(e.getId())).map(e=>e.getColDef().showRowGroup).some(e=>!0===e||e===n)}getServerSideInitialRowCount(){return this.gos.get("serverSideInitialRowCount")}assertRowModelIsServerSide(e){return!!this.gos.isRowModelType("serverSide")||(Gg._.warnOnce(`The '${e}' property can only be used with the Server Side Row Model.`),!1)}assertNotTreeData(e){return!this.gos.get("treeData")||(Gg._.warnOnce(`The '${e}' property cannot be used while using tree data.`),!1)}isServerSideSortAllLevels(){return this.gos.get("serverSideSortAllLevels")&&this.assertRowModelIsServerSide("serverSideSortAllLevels")}isServerSideOnlyRefreshFilteredGroups(){return this.gos.get("serverSideOnlyRefreshFilteredGroups")&&this.assertRowModelIsServerSide("serverSideOnlyRefreshFilteredGroups")}isServerSideSortOnServer(){return this.gos.get("serverSideSortOnServer")&&this.assertRowModelIsServerSide("serverSideSortOnServer")&&this.assertNotTreeData("serverSideSortOnServer")}isServerSideFilterOnServer(){return this.gos.get("serverSideFilterOnServer")&&this.assertRowModelIsServerSide("serverSideFilterOnServer")&&this.assertNotTreeData("serverSideFilterOnServer")}};lf([(0,Gg.Autowired)("columnModel")],ff.prototype,"columnModel",2),lf([(0,Gg.Autowired)("rowModel")],ff.prototype,"serverSideRowModel",2),lf([(0,Gg.Autowired)("ssrmStoreFactory")],ff.prototype,"storeFactory",2),ff=lf([(0,Gg.Bean)("ssrmStoreUtils")],ff);var mf=class extends Vg.BeanStub{createRowNode(e){const t=new Vg.RowNode(this.beans),i=null!=e.rowHeight?e.rowHeight:this.gos.getRowHeightAsNumber();return t.setRowHeight(i),t.group=e.group,t.leafGroup=e.leafGroup,t.level=e.level,t.uiLevel=e.level,t.parent=e.parent,t.stub=!0,t.__needsRefreshWhenVisible=!1,t.group&&(t.expanded=!1,t.field=e.field,t.rowGroupColumn=e.rowGroupColumn),t}destroyRowNodes(e){e&&e.forEach(e=>this.destroyRowNode(e))}destroyRowNode(e,t=!1){e.childStore&&!t&&(this.destroyBean(e.childStore),e.childStore=null),e.sibling&&!e.footer&&this.destroyRowNode(e.sibling,!1),e.clearRowTopAndRowIndex(),null!=e.id&&this.nodeManager.removeNode(e)}setTreeGroupInfo(e){e.updateHasChildren();const t=this.gos.get("getServerSideGroupKey");e.hasChildren()&&null!=t&&(e.key=t(e.data)),e.hasChildren()||null==e.childStore||(this.destroyBean(e.childStore),e.childStore=null,e.expanded=!1)}setRowGroupInfo(e){e.key=this.valueService.getValue(e.rowGroupColumn,e),null!==e.key&&void 0!==e.key||Vg._.doOnce(()=>{console.warn("AG Grid: null and undefined values are not allowed for server side row model keys"),e.rowGroupColumn&&console.warn(`column = ${e.rowGroupColumn.getId()}`),console.warn("data is ",e.data)},"ServerSideBlock-CannotHaveNullOrUndefinedForKey"),this.beans.gos.getGroupTotalRowCallback()({node:e})&&(e.createFooter(),e.sibling&&(e.sibling.uiLevel=e.uiLevel+1))}setMasterDetailInfo(e){const t=this.gos.get("isRowMaster");e.master=null==t||t(e.data)}updateDataIntoRowNode(e,t){e.updateData(t),this.gos.get("treeData")?(this.setTreeGroupInfo(e),this.setChildCountIntoRowNode(e)):e.group?(this.setChildCountIntoRowNode(e),e.footer||(this.beans.gos.getGroupTotalRowCallback()({node:e})?e.sibling?e.sibling.updateData(t):e.createFooter():e.sibling&&e.destroyFooter())):this.gos.get("masterDetail")}setDataIntoRowNode(e,t,i,r){var n;e.stub=!1;const s=this.gos.get("treeData");Vg._.exists(t)?(e.setDataAndId(t,i),s?this.setTreeGroupInfo(e):e.group?this.setRowGroupInfo(e):this.gos.get("masterDetail")&&this.setMasterDetailInfo(e)):(e.setDataAndId(void 0,void 0),e.key=null),(s||e.group)&&(this.setGroupDataIntoRowNode(e),this.setChildCountIntoRowNode(e)),Vg._.exists(t)&&(e.setRowHeight(this.gos.getRowHeightForNode(e,!1,r).height),null==(n=e.sibling)||n.setRowHeight(this.gos.getRowHeightForNode(e.sibling,!1,r).height))}setChildCountIntoRowNode(e){const t=this.gos.get("getChildCount");t&&e.setAllChildrenCount(t(e.data))}setGroupDataIntoRowNode(e){const t=this.columnModel.getGroupDisplayColumns(),i=this.gos.get("treeData");t.forEach(t=>{if(null==e.groupData&&(e.groupData={}),i)e.groupData[t.getColId()]=e.key;else if(t.isRowGroupDisplayed(e.rowGroupColumn.getId())){const i=this.valueService.getValue(e.rowGroupColumn,e);e.groupData[t.getColId()]=i}})}clearDisplayIndex(e){e.clearRowTopAndRowIndex(),e.hasChildren()&&Vg._.exists(e.childStore)&&e.childStore.clearDisplayIndexes(),e.master&&e.detailNode&&e.detailNode.clearRowTopAndRowIndex()}setDisplayIndex(e,t,i){if(e.setRowIndex(t.next()),e.setRowTop(i.value),i.value+=e.rowHeight,!e.footer&&(e.master&&(e.expanded&&e.detailNode?(e.detailNode.setRowIndex(t.next()),e.detailNode.setRowTop(i.value),i.value+=e.detailNode.rowHeight):e.detailNode&&e.detailNode.clearRowTopAndRowIndex()),e.hasChildren()&&Vg._.exists(e.childStore))){const r=e.childStore;e.expanded?r.setDisplayIndexes(t,i):r.clearDisplayIndexes()}}binarySearchForDisplayIndex(e,t){let i=0,r=t.length-1;if(Vg._.missing(r)||Vg._.missing(i))console.warn(`AG Grid: error: topPointer = ${r}, bottomPointer = ${i}`);else for(;;){const n=Math.floor((i+r)/2),s=t[n];if(s.rowIndex===e)return s;const o=s.master&&s.expanded,a=s.detailNode;if(o&&a&&a.rowIndex===e)return s.detailNode;const l=s.childStore;if(s.expanded&&l&&l.isDisplayIndexInStore(e))return l.getRowUsingDisplayIndex(e);if(s.rowIndex<e)i=n+1;else{if(!(s.rowIndex>e))return void console.warn(`AG Grid: error: unable to locate rowIndex = ${e} in cache`);r=n-1}}}extractRowBounds(e,t){const i=e=>({rowHeight:e.rowHeight,rowTop:e.rowTop});if(e.rowIndex===t)return i(e);if(e.hasChildren()&&e.expanded&&Vg._.exists(e.childStore)){const i=e.childStore;if(i.isDisplayIndexInStore(t))return i.getRowBounds(t)}else if(e.master&&e.expanded&&Vg._.exists(e.detailNode)&&e.detailNode.rowIndex===t)return i(e.detailNode)}getIndexAtPixel(e,t){if(e.isPixelInRange(t))return e.rowIndex;const i=e.master&&e.expanded,r=e.detailNode;if(i&&r&&r.isPixelInRange(t))return e.detailNode.rowIndex;if(e.hasChildren()&&e.expanded&&Vg._.exists(e.childStore)){const i=e.childStore;if(i.isPixelInRange(t))return i.getRowIndexAtPixel(t)}return null}createNodeIdPrefix(e){const t=[];let i=e;for(;i&&i.level>=0;)""===i.key?t.push("ag-Grid-MissingKey"):t.push(i.key),i=i.parent;if(t.length>0)return t.reverse().join("-")}checkOpenByDefault(e){return this.expansionService.checkOpenByDefault(e)}};lf([(0,Vg.Autowired)("valueService")],mf.prototype,"valueService",2),lf([(0,Vg.Autowired)("columnModel")],mf.prototype,"columnModel",2),lf([(0,Vg.Autowired)("ssrmNodeManager")],mf.prototype,"nodeManager",2),lf([(0,Vg.Autowired)("beans")],mf.prototype,"beans",2),lf([(0,Vg.Autowired)("expansionService")],mf.prototype,"expansionService",2),mf=lf([(0,Vg.Bean)("ssrmBlockUtils")],mf);var vf=class{constructor(){this.rowNodes={}}addRowNode(e){const t=e.id;this.rowNodes[t]&&(console.warn(`AG Grid: Duplicate node id ${e.id}. Row ID's are provided via the getRowId() callback. Please modify the getRowId() callback code to provide unique row id values.`),console.warn("first instance",this.rowNodes[t].data),console.warn("second instance",e.data)),this.rowNodes[t]=e}removeNode(e){const t=e.id;this.rowNodes[t]&&(this.rowNodes[t]=void 0)}clear(){this.rowNodes={}}};lf([Hg.PreDestroy],vf.prototype,"clear",1),vf=lf([(0,Hg.Bean)("ssrmNodeManager")],vf);var Cf=class extends Bg.BeanStub{constructor(){super(...arguments),this.asyncTransactions=[]}postConstruct(){this.gos.isRowModelType("serverSide")}applyTransactionAsync(e,t){null==this.asyncTransactionsTimeout&&this.scheduleExecuteAsync(),this.asyncTransactions.push({transaction:e,callback:t})}scheduleExecuteAsync(){const e=this.gos.getAsyncTransactionWaitMillis();this.asyncTransactionsTimeout=window.setTimeout(()=>{this.executeAsyncTransactions()},e)}executeAsyncTransactions(){if(!this.asyncTransactions)return;const e=[],t=[],i=[];let r=!1;if(this.asyncTransactions.forEach(n=>{let s;this.serverSideRowModel.executeOnStore(n.transaction.route,e=>{s=e.applyTransaction(n.transaction)})?null==s&&(s={status:Bg.ServerSideTransactionResultStatus.StoreNotFound}):s={status:Bg.ServerSideTransactionResultStatus.StoreNotStarted},t.push(s),s.status==Bg.ServerSideTransactionResultStatus.StoreLoading?i.push(n):(n.callback&&e.push(()=>n.callback(s)),s.status===Bg.ServerSideTransactionResultStatus.Applied&&(r=!0))}),e.length>0&&window.setTimeout(()=>{e.forEach(e=>e())},0),this.asyncTransactionsTimeout=void 0,this.asyncTransactions=i,r&&(this.valueCache.onDataChanged(),this.eventService.dispatchEvent({type:Bg.Events.EVENT_STORE_UPDATED})),t.length>0){const e={type:Bg.Events.EVENT_ASYNC_TRANSACTIONS_FLUSHED,results:t};this.eventService.dispatchEvent(e)}}flushAsyncTransactions(){null!=this.asyncTransactionsTimeout&&clearTimeout(this.asyncTransactionsTimeout),this.executeAsyncTransactions()}applyTransaction(e){let t;if(this.serverSideRowModel.executeOnStore(e.route,i=>{t=i.applyTransaction(e)})){if(t){if(this.valueCache.onDataChanged(),t.remove){const i=t.remove.map(e=>e.id);this.selectionService.deleteSelectionStateFromParent(e.route||[],i)}return this.eventService.dispatchEvent({type:Bg.Events.EVENT_STORE_UPDATED}),t}return{status:Bg.ServerSideTransactionResultStatus.StoreNotFound}}return{status:Bg.ServerSideTransactionResultStatus.StoreNotStarted}}};lf([(0,Bg.Autowired)("rowNodeBlockLoader")],Cf.prototype,"rowNodeBlockLoader",2),lf([(0,Bg.Autowired)("valueCache")],Cf.prototype,"valueCache",2),lf([(0,Bg.Autowired)("rowModel")],Cf.prototype,"serverSideRowModel",2),lf([(0,Bg.Autowired)("rowRenderer")],Cf.prototype,"rowRenderer",2),lf([(0,Bg.Autowired)("selectionService")],Cf.prototype,"selectionService",2),lf([Bg.PostConstruct],Cf.prototype,"postConstruct",1),Cf=lf([(0,Bg.Bean)("ssrmTransactionManager")],Cf);var yf=class extends zg.BeanStub{postConstruct(){this.gos.isRowModelType("serverSide")&&this.addManagedListener(this.eventService,zg.Events.EVENT_ROW_GROUP_OPENED,this.onRowGroupOpened.bind(this))}onRowGroupOpened(e){const t=e.node;if(t.expanded){if(t.master)this.createDetailNode(t);else if(zg._.missing(t.childStore)){const e=this.serverSideRowModel.getParams();t.childStore=this.createBean(this.storeFactory.createStore(e,t))}}else this.gos.get("purgeClosedRowNodes")&&zg._.exists(t.childStore)&&(t.childStore=this.destroyBean(t.childStore));const i={type:zg.Events.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(i)}createDetailNode(e){if(zg._.exists(e.detailNode))return e.detailNode;const t=new zg.RowNode(this.beans);t.detail=!0,t.selectable=!1,t.parent=e,zg._.exists(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1;const i=this.gos.getRowHeightForNode(t).height;return t.rowHeight=i||200,e.detailNode=t,t}};lf([(0,zg.Autowired)("rowModel")],yf.prototype,"serverSideRowModel",2),lf([(0,zg.Autowired)("ssrmStoreFactory")],yf.prototype,"storeFactory",2),lf([(0,zg.Autowired)("beans")],yf.prototype,"beans",2),lf([zg.PostConstruct],yf.prototype,"postConstruct",1),yf=lf([(0,zg.Bean)("ssrmExpandListener")],yf);var wf=class extends Ug.BeanStub{postConstruct(){this.gos.isRowModelType("serverSide")&&this.addManagedListener(this.eventService,Ug.Events.EVENT_SORT_CHANGED,this.onSortChanged.bind(this))}onSortChanged(){const e=this.serverSideRowModel.getParams();if(!e)return;const t=this.sortController.getSortModel(),i=e.sortModel,r=this.findChangedColumnsInSort(t,i),n={valueColChanged:this.listenerUtils.isSortingWithValueColumn(r),secondaryColChanged:this.listenerUtils.isSortingWithSecondaryColumn(r),changedColumns:r};this.serverSideRowModel.refreshAfterSort(t,n)}findChangedColumnsInSort(e,t){let i=[];return[e,t].forEach(e=>{if(e){const t=e.map(e=>e.colId);i=i.concat(t)}}),i.filter(i=>{const r=t.find(e=>e.colId===i),n=e.find(e=>e.colId===i);return((e,t)=>(e?e.sort:null)!==(t?t.sort:null))(r,n)||((i,r)=>(i?t.indexOf(i):-1)!==(r?e.indexOf(r):-1))(r,n)})}};lf([(0,Ug.Autowired)("sortController")],wf.prototype,"sortController",2),lf([(0,Ug.Autowired)("rowModel")],wf.prototype,"serverSideRowModel",2),lf([(0,Ug.Autowired)("ssrmListenerUtils")],wf.prototype,"listenerUtils",2),lf([Ug.PostConstruct],wf.prototype,"postConstruct",1),wf=lf([(0,Ug.Bean)("ssrmSortService")],wf);var Sf=class extends Wg.BeanStub{postConstruct(){this.gos.isRowModelType("serverSide")&&(this.addManagedListener(this.eventService,Wg.Events.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,()=>this.onFilterChanged(!0)),this.addManagedListener(this.eventService,Wg.Events.EVENT_FILTER_CHANGED,()=>this.onFilterChanged()))}onFilterChanged(e){const t=this.serverSideRowModel.getParams();if(!t)return;const i=t.filterModel;let r,n;if(this.filterManager.isAdvancedFilterEnabled()){r=this.filterManager.getAdvancedFilterModel();const t=e?Object.keys(null!=i?i:{}):this.getAdvancedFilterColumns(i),s=this.getAdvancedFilterColumns(r);t.forEach(e=>s.add(e)),n=Array.from(s)}else if(r=this.filterManager.getFilterModel(),e){const e=this.getAdvancedFilterColumns(i);Object.keys(r).forEach(t=>e.add(t)),n=Array.from(e)}else n=this.findChangedColumns(i,r);const s={valueColChanged:this.listenerUtils.isSortingWithValueColumn(n),secondaryColChanged:this.listenerUtils.isSortingWithSecondaryColumn(n),changedColumns:n};this.serverSideRowModel.refreshAfterFilter(r,s)}findChangedColumns(e,t){const i={};Object.keys(e).forEach(e=>i[e]=!0),Object.keys(t).forEach(e=>i[e]=!0);const r=[];return Object.keys(i).forEach(i=>{JSON.stringify(e[i])!=JSON.stringify(t[i])&&r.push(i)}),r}getAdvancedFilterColumns(e){const t=new Set;if(!e)return t;const i=e=>{"join"===e.filterType?e.conditions.forEach(e=>i(e)):t.add(e.colId)};return i(e),t}};lf([(0,Wg.Autowired)("rowModel")],Sf.prototype,"serverSideRowModel",2),lf([(0,Wg.Autowired)("filterManager")],Sf.prototype,"filterManager",2),lf([(0,Wg.Autowired)("ssrmListenerUtils")],Sf.prototype,"listenerUtils",2),lf([Wg.PostConstruct],Sf.prototype,"postConstruct",1),Sf=lf([(0,Wg.Bean)("ssrmFilterListener")],Sf);var bf=class{createStore(e,t){const i=this.getStoreParams(e,t);return new(i.suppressInfiniteScroll?cf:pf)(e,i,t)}getStoreParams(e,t){const i=this.getLevelSpecificParams(t),r=this.isInfiniteScroll(i);return{suppressInfiniteScroll:!r,cacheBlockSize:this.getBlockSize(r,i),maxBlocksInCache:this.getMaxBlocksInCache(r,e,i)}}getMaxBlocksInCache(e,t,i){if(!e)return;const r=i&&null!=i.maxBlocksInCache?i.maxBlocksInCache:this.gos.get("maxBlocksInCache");if(null!=r&&r>=0){if(t.dynamicRowHeight){const e="Server Side Row Model does not support Dynamic Row Height and Cache Purging. Either a) remove getRowHeight() callback or b) remove maxBlocksInCache property. Purging has been disabled.";return void jg._.warnOnce(e)}if(this.columnModel.isAutoRowHeightActive()){const e="Server Side Row Model does not support Auto Row Height and Cache Purging. Either a) remove colDef.autoHeight or b) remove maxBlocksInCache property. Purging has been disabled.";return void jg._.warnOnce(e)}return r}}getBlockSize(e,t){if(!e)return;const i=t&&null!=t.cacheBlockSize?t.cacheBlockSize:this.gos.get("cacheBlockSize");return null!=i&&i>0?i:100}getLevelSpecificParams(e){const t=this.gos.getCallback("getServerSideGroupLevelParams");if(t)return t({level:e.level+1,parentRowNode:e.level>=0?e:void 0,rowGroupColumns:this.columnModel.getRowGroupColumns(),pivotColumns:this.columnModel.getPivotColumns(),pivotMode:this.columnModel.isPivotMode()})}isInfiniteScroll(e){return!(e&&null!=e.suppressInfiniteScroll?e.suppressInfiniteScroll:this.isSuppressServerSideInfiniteScroll())}isSuppressServerSideInfiniteScroll(){return this.gos.get("suppressServerSideInfiniteScroll")}};lf([(0,jg.Autowired)("gridOptionsService")],bf.prototype,"gos",2),lf([(0,jg.Autowired)("columnModel")],bf.prototype,"columnModel",2),bf=lf([(0,jg.Bean)("ssrmStoreFactory")],bf);var Ef=class{isSortingWithValueColumn(e){const t=this.columnModel.getValueColumns().map(e=>e.getColId());for(let i=0;i<e.length;i++)if(t.indexOf(e[i])>-1)return!0;return!1}isSortingWithSecondaryColumn(e){if(!this.columnModel.getSecondaryColumns())return!1;const t=this.columnModel.getSecondaryColumns().map(e=>e.getColId());for(let i=0;i<e.length;i++)if(t.indexOf(e[i])>-1)return!0;return!1}};lf([(0,Kg.Autowired)("columnModel")],Ef.prototype,"columnModel",2),Ef=lf([(0,Kg.Bean)("ssrmListenerUtils")],Ef);var Af=class extends qg.BeanStub{constructor(){super(...arguments),this.selectedState={selectAll:!1,toggledNodes:new Set},this.lastSelected=null,this.selectAllUsed=!1,this.selectedNodes={}}init(){this.rowSelection=this.gos.get("rowSelection"),this.addManagedPropertyListener("rowSelection",e=>{this.rowSelection=e.currentValue})}getSelectedState(){return{selectAll:this.selectedState.selectAll,toggledNodes:[...this.selectedState.toggledNodes]}}setSelectedState(e){const t={selectAll:!1,toggledNodes:new Set};"object"==typeof e?"selectAll"in e&&"boolean"==typeof e.selectAll?(t.selectAll=e.selectAll,"toggledNodes"in e&&Array.isArray(e.toggledNodes)?(e.toggledNodes.forEach(e=>{"string"==typeof e?t.toggledNodes.add(e):console.warn(`AG Grid: Provided ids must be of string type. Invalid id provided: ${e}`)}),this.selectedState=t):console.error("AG Grid: `toggledNodes` must be an array of string ids.")):console.error("AG Grid: Select all status should be of boolean type."):console.error("AG Grid: The provided selection state should be an object.")}deleteSelectionStateFromParent(e,t){if(0===this.selectedState.toggledNodes.size)return!1;let i=!1;return t.forEach(e=>{this.selectedState.toggledNodes.delete(e)&&(i=!0)}),i}setNodesSelected(e){if(0===e.nodes.length)return 0;const t=e.clearSelection&&e.newValue&&!e.rangeSelect;if("multiple"!==this.rowSelection||t){if(e.nodes.length>1)throw new Error("AG Grid: cannot select multiple rows when rowSelection is set to 'single'");const t=e.nodes[0];return e.newValue?(this.selectedNodes={[t.id]:t},this.selectedState={selectAll:!1,toggledNodes:new Set([t.id])}):(this.selectedNodes={},this.selectedState={selectAll:!1,toggledNodes:new Set}),this.lastSelected=t.id,1}const i=t=>{e.newValue?this.selectedNodes[t.id]=t:delete this.selectedNodes[t.id];const i=t.selectable;e.newValue!==this.selectedState.selectAll&&i?this.selectedState.toggledNodes.add(t.id):this.selectedState.toggledNodes.delete(t.id)};if(e.rangeSelect&&this.lastSelected){if(e.nodes.length>1)throw new Error("AG Grid: cannot select multiple rows when using rangeSelect");const t=e.nodes[0],r=this.rowModel.getRowNode(this.lastSelected);return this.rowModel.getNodesInRangeForSelection(t,null!=r?r:null).forEach(i),this.lastSelected=t.id,1}return e.nodes.forEach(i),this.lastSelected=e.nodes[e.nodes.length-1].id,1}processNewRow(e){this.selectedNodes[e.id]&&(this.selectedNodes[e.id]=e)}isNodeSelected(e){const t=this.selectedState.toggledNodes.has(e.id);return this.selectedState.selectAll?!t:t}getSelectedNodes(){return this.selectAllUsed&&console.warn("AG Grid: getSelectedNodes and getSelectedRows functions cannot be used with select all functionality with the server-side row model.\n                Use `api.getServerSideSelectionState()` instead."),Object.values(this.selectedNodes)}getSelectedRows(){return this.getSelectedNodes().map(e=>e.data)}getSelectionCount(){return this.selectedState.selectAll?-1:this.selectedState.toggledNodes.size}clearOtherNodes(e,t){const i=this.selectedState.selectAll?1:this.selectedState.toggledNodes.size-1;this.selectedState={selectAll:!1,toggledNodes:new Set([e.id])},this.rowModel.forEachNode(i=>{i!==e&&i.selectThisNode(!1,void 0,t)});const r={type:qg.Events.EVENT_SELECTION_CHANGED,source:t};return this.eventService.dispatchEvent(r),i}isEmpty(){var e;return!this.selectedState.selectAll&&!(null==(e=this.selectedState.toggledNodes)?void 0:e.size)}selectAllRowNodes(e){this.selectedState={selectAll:!0,toggledNodes:new Set},this.selectedNodes={},this.selectAllUsed=!0}deselectAllRowNodes(e){this.selectedState={selectAll:!1,toggledNodes:new Set},this.selectedNodes={}}getSelectAllState(e,t){return this.selectedState.selectAll?!(this.selectedState.toggledNodes.size>0)||null:this.selectedState.toggledNodes.size>0&&null}};lf([(0,qg.Autowired)("rowModel")],Af.prototype,"rowModel",2),lf([qg.PostConstruct],Af.prototype,"init",1);var Tf=class extends Yg.BeanStub{constructor(){super(...arguments),this.selectedState={selectAllChildren:!1,toggledNodes:new Map},this.lastSelected=null}init(){this.addManagedListener(this.eventService,Yg.Events.EVENT_MODEL_UPDATED,()=>this.removeRedundantState()),this.addManagedListener(this.eventService,Yg.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.selectionService.reset("rowGroupChanged"))}getSelectedState(){const e=this.gos.get("treeData"),t=(i,r,n)=>{const s={nodeId:n};if((e||r<=this.columnModel.getRowGroupColumns().length)&&(s.selectAllChildren=i.selectAllChildren),i.toggledNodes.size){const e=[];i.toggledNodes.forEach((i,n)=>{const s=t(i,r+1,n);e.push(s)}),s.toggledNodes=e}return s};return t(this.selectedState,0)}setSelectedState(e){const t=(e,i)=>{var r,n;if("object"!=typeof e)throw new Error("AG Grid: Each provided state object must be an object.");if("selectAllChildren"in e&&"boolean"!=typeof e.selectAllChildren)throw new Error("AG Grid: `selectAllChildren` must be a boolean value or undefined.");if("toggledNodes"in e){if(!Array.isArray(e.toggledNodes))throw new Error("AG Grid: `toggledNodes` must be an array.");if(!e.toggledNodes.every(e=>"object"==typeof e&&"nodeId"in e&&"string"==typeof e.nodeId))throw new Error("AG Grid: Every `toggledNode` requires an associated string id.")}const s=null!=(r=e.selectAllChildren)?r:!i,o=null==(n=e.toggledNodes)?void 0:n.map(e=>[e.nodeId,t(e,s)]);if(null==o?void 0:o.some(([e,t])=>s===t.selectAllChildren&&0===t.toggledNodes.size))throw new Error("\n                    AG Grid: AG Grid: Row selection state could not be parsed due to invalid data. Ensure all child state has toggledNodes or does not conform with the parent rule.\n                    Please rebuild the selection state and reapply it.\n                ");return{selectAllChildren:s,toggledNodes:new Map(o)}};try{this.selectedState=t(e,!!e.selectAllChildren)}catch(e){console.error(e.message)}}deleteSelectionStateFromParent(e,t){let i=this.selectedState;const r=[...e];for(;i&&r.length;)i=i.toggledNodes.get(r.pop());if(!i)return!1;let n=!1;return t.forEach(e=>{(null==i?void 0:i.toggledNodes.delete(e))&&(n=!0)}),n&&this.removeRedundantState(),n}setNodesSelected(e){const t=e,{nodes:i}=t,r=af(t,["nodes"]);if(0===i.length)return 0;if(e.rangeSelect){if(i.length>1)throw new Error("AG Grid: cannot select multiple rows when using rangeSelect");const e=i[0],t=this.rowModel.getNodesInRangeForSelection(e,this.lastSelected).map(this.getRouteToNode).sort((e,t)=>t.length-e.length),n=new Set;return t.forEach(t=>{n.has(t[t.length-1])||(t.forEach(e=>n.add(e)),this.recursivelySelectNode(t,this.selectedState,of({node:e},r)))}),this.removeRedundantState(),this.lastSelected=e,1}return e.nodes.forEach(e=>{const t=this.getRouteToNode(e);var i;this.recursivelySelectNode(t,this.selectedState,(i=of({},r),Zg(i,ef({node:e}))))}),this.removeRedundantState(),this.lastSelected=e.nodes[e.nodes.length-1],1}isNodeSelected(e){const t=this.getRouteToNode(e);return this.isNodePathSelected(t,this.selectedState)}isNodePathSelected([e,...t],i){if(0===t.length){const t=i.toggledNodes.has(e.id);if(e.hasChildren()){const t=i.toggledNodes.get(e.id);if(t&&t.toggledNodes.size)return}return i.selectAllChildren?!t:t}if(i.toggledNodes.has(e.id)){const r=i.toggledNodes.get(e.id);if(r)return this.isNodePathSelected(t,r)}return!!i.selectAllChildren}getRouteToNode(e){const t=[];let i=e;for(;i.parent;)t.push(i),i=i.parent;return t.reverse()}removeRedundantState(){if(this.filterManager.isAnyFilterPresent())return;const e=(t=this.selectedState,i,r)=>{if(t.toggledNodes.forEach((i,r)=>{e(i,r,t)}),i){const e=this.rowModel.getRowNode(i),r=null==e?void 0:e.childStore;if((null==r?void 0:r.isLastRowIndexKnown())&&t.toggledNodes.size>=r.getRowCount()){for(const e of t.toggledNodes.entries()){const[t,i]=e;if(i.toggledNodes.size>0)return;if(!this.rowModel.getRowNode(t))return}t.selectAllChildren=!t.selectAllChildren,t.toggledNodes.clear()}}const n=0===t.toggledNodes.size,s=(null==r?void 0:r.selectAllChildren)===t.selectAllChildren;n&&s&&(null==r||r.toggledNodes.delete(i))};e()}recursivelySelectNode([e,...t],i,r){if(!e)return;if(!t.length){const t=e.selectable;if(i.selectAllChildren===r.newValue||!t)return void i.toggledNodes.delete(e.id);const n={selectAllChildren:r.newValue,toggledNodes:new Map};return void i.toggledNodes.set(e.id,n)}const n=i.toggledNodes.has(e.id),s=n?i.toggledNodes.get(e.id):{selectAllChildren:i.selectAllChildren,toggledNodes:new Map};n||i.toggledNodes.set(e.id,s),this.recursivelySelectNode(t,s,r),i.selectAllChildren===s.selectAllChildren&&0===s.toggledNodes.size&&i.toggledNodes.delete(e.id)}getSelectedNodes(){console.warn("AG Grid: `getSelectedNodes` and `getSelectedRows` functions cannot be used with `groupSelectsChildren` and the server-side row model.\n            Use `api.getServerSideSelectionState()` instead.");const e=[];return this.rowModel.forEachNode(t=>{t.isSelected()&&e.push(t)}),e}processNewRow(e){}getSelectedRows(){return this.getSelectedNodes().map(e=>e.data)}getSelectionCount(){return-1}isEmpty(){var e;return!this.selectedState.selectAllChildren&&!(null==(e=this.selectedState.toggledNodes)?void 0:e.size)}selectAllRowNodes(e){this.selectedState={selectAllChildren:!0,toggledNodes:new Map}}deselectAllRowNodes(e){this.selectedState={selectAllChildren:!1,toggledNodes:new Map}}getSelectAllState(e,t){return this.selectedState.selectAllChildren?!(this.selectedState.toggledNodes.size>0)||null:this.selectedState.toggledNodes.size>0&&null}};lf([(0,Yg.Autowired)("rowModel")],Tf.prototype,"rowModel",2),lf([(0,Yg.Autowired)("columnModel")],Tf.prototype,"columnModel",2),lf([(0,Yg.Autowired)("filterManager")],Tf.prototype,"filterManager",2),lf([(0,Yg.Autowired)("rowModel")],Tf.prototype,"serverSideRowModel",2),lf([(0,Yg.Autowired)("selectionService")],Tf.prototype,"selectionService",2),lf([Yg.PostConstruct],Tf.prototype,"init",1);var Mf=class extends $g.BeanStub{init(){const e=this.gos.get("groupSelectsChildren");this.addManagedPropertyListener("groupSelectsChildren",e=>{this.destroyBean(this.selectionStrategy);const t=e.currentValue?Tf:Af;this.selectionStrategy=this.createManagedBean(new t),this.shotgunResetNodeSelectionState();const i={type:$g.Events.EVENT_SELECTION_CHANGED,source:"api"};this.eventService.dispatchEvent(i)}),this.addManagedPropertyListener("rowSelection",()=>this.deselectAllRowNodes({source:"api"}));const t=e?Tf:Af;this.selectionStrategy=this.createManagedBean(new t)}getSelectionState(){return this.selectionStrategy.getSelectedState()}setSelectionState(e,t){if(Array.isArray(e))return;this.selectionStrategy.setSelectedState(e),this.shotgunResetNodeSelectionState();const i={type:$g.Events.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(i)}setNodesSelected(e){const t=e,{nodes:i}=t,r=af(t,["nodes"]),n=this.gos.get("rowSelection");if(i.length>1&&"multiple"!==n)return console.warn("AG Grid: cannot multi select while rowSelection='single'"),0;if(i.length>1&&e.rangeSelect)return console.warn("AG Grid: cannot use range selection when multi selecting rows"),0;const s=of({nodes:i.filter(e=>e.selectable)},r);if(!s.nodes.length)return 0;const o=this.selectionStrategy.setNodesSelected(s);this.shotgunResetNodeSelectionState(s.source);const a={type:$g.Events.EVENT_SELECTION_CHANGED,source:s.source};return this.eventService.dispatchEvent(a),o}deleteSelectionStateFromParent(e,t){if(!this.selectionStrategy.deleteSelectionStateFromParent(e,t))return;this.shotgunResetNodeSelectionState();const i={type:$g.Events.EVENT_SELECTION_CHANGED,source:"api"};this.eventService.dispatchEvent(i)}shotgunResetNodeSelectionState(e){this.rowModel.forEachNode(t=>{if(t.stub)return;const i=this.selectionStrategy.isNodeSelected(t);i!==t.isSelected()&&t.selectThisNode(i,void 0,e)})}getSelectedNodes(){return this.selectionStrategy.getSelectedNodes()}getSelectedRows(){return this.selectionStrategy.getSelectedRows()}getSelectionCount(){return this.selectionStrategy.getSelectionCount()}syncInRowNode(e,t){this.selectionStrategy.processNewRow(e);const i=this.selectionStrategy.isNodeSelected(e);if(0!=i&&!e.selectable){this.selectionStrategy.setNodesSelected({nodes:[e],newValue:!1,source:"api"}),this.shotgunResetNodeSelectionState();const t={type:$g.Events.EVENT_SELECTION_CHANGED,source:"api"};return void this.eventService.dispatchEvent(t)}e.setSelectedInitialValue(i)}reset(){this.selectionStrategy.deselectAllRowNodes({source:"api"})}isEmpty(){return this.selectionStrategy.isEmpty()}hasNodesToSelect(e=!1,t=!1){return!0}selectAllRowNodes(e){(e.justCurrentPage||e.justFiltered)&&console.warn("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'"),this.selectionStrategy.selectAllRowNodes(e),this.rowModel.forEachNode(t=>{t.stub||t.selectThisNode(!0,void 0,e.source)});const t={type:$g.Events.EVENT_SELECTION_CHANGED,source:e.source};this.eventService.dispatchEvent(t)}deselectAllRowNodes(e){(e.justCurrentPage||e.justFiltered)&&console.warn("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'"),this.selectionStrategy.deselectAllRowNodes(e),this.rowModel.forEachNode(t=>{t.stub||t.selectThisNode(!1,void 0,e.source)});const t={type:$g.Events.EVENT_SELECTION_CHANGED,source:e.source};this.eventService.dispatchEvent(t)}getSelectAllState(e,t){return this.selectionStrategy.getSelectAllState(e,t)}updateGroupsFromChildrenSelections(e,t){return!1}getBestCostNodeSelection(){console.warn("AG Grid: calling gridApi.getBestCostNodeSelection() is only possible when using rowModelType=`clientSide`.")}filterFromSelection(){}};lf([(0,$g.Autowired)("rowModel")],Mf.prototype,"rowModel",2),lf([$g.PostConstruct],Mf.prototype,"init",1),Mf=lf([(0,$g.Bean)("selectionService")],Mf);var Rf=class extends Qg.ExpansionService{constructor(){super(...arguments),this.queuedRowIds=new Set}postConstruct(){super.postConstruct(),this.addManagedListener(this.eventService,Qg.Events.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>{this.queuedRowIds.clear()})}checkOpenByDefault(e){if(!e.isExpandable())return;if(this.queuedRowIds.has(e.id))return this.queuedRowIds.delete(e.id),void e.setExpanded(!0);const t=this.gos.getCallback("isServerSideGroupOpenByDefault");t&&t({data:e.data,rowNode:e})&&e.setExpanded(!0)}expandRows(e){e.forEach(e=>{const t=this.serverSideRowModel.getRowNode(e);t?t.setExpanded(!0):this.queuedRowIds.add(e)})}expandAll(e){this.serverSideRowModel.expandAll(e)}onGroupExpandedOrCollapsed(){}};lf([(0,Qg.Autowired)("rowModel")],Rf.prototype,"serverSideRowModel",2),Rf=lf([(0,Qg.Bean)("expansionService")],Rf);var _f={version:"31.3.4",moduleName:Ig.ModuleNames.ServerSideRowModelModule,rowModel:"serverSide",beans:[gf,yf,wf,ff,mf,vf,Cf,Sf,bf,Ef,Mf,Rf,hf],dependantModules:[_]},Pf=i(98092),xf=i(98092),Df=i(98092),If=i(98092),Lf=i(98092),Nf=i(98092),Of=i(98092),Ff=Object.defineProperty,kf=Object.getOwnPropertyDescriptor,Gf=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?kf(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Ff(t,i,s),s},Vf=class{constructor(e,t,i,r,n,s,o,a,l,c,u){this.rowModel=e,this.filterParams=t,this.createKey=i,this.caseFormat=r,this.columnModel=n,this.valueService=s,this.treeDataOrGrouping=o,this.treeData=a,this.getDataPath=l,this.groupAllowUnbalanced=c,this.addManagedListener=u}extractUniqueValuesAsync(e,t){return new If.AgPromise(i=>{if(this.rowModel.isRowDataLoaded())i(this.extractUniqueValues(e,t));else{const r=this.addManagedListener(If.Events.EVENT_ROW_COUNT_READY,()=>{null==r||r(),i(this.extractUniqueValues(e,t))})}})}extractUniqueValues(e,t){const i=new Map,r=this.extractExistingFormattedKeys(t),n=new Set,s=this.treeData&&!!this.getDataPath,o=this.columnModel.getRowGroupColumns(),a=(e,s)=>{const o=this.caseFormat(e);if(!n.has(o)){n.add(o);let a=e,l=If._.makeNull(s);const c=null==r?void 0:r.get(o);null!=c&&(a=c,l=t.get(c)),i.set(a,l)}};return this.rowModel.forEachLeafNode(t=>{if(!t.data||!e(t))return;if(this.treeDataOrGrouping)return void this.addValueForTreeDataOrGrouping(t,s,o,a);let i=this.getValue(t);this.filterParams.convertValuesToStrings?this.addValueForConvertValuesToString(t,i,a):null!=i&&Array.isArray(i)?(i.forEach(e=>{a(this.createKey(e,t),e)}),0===i.length&&a(null,null)):a(this.createKey(i,t),i)}),i}addValueForConvertValuesToString(e,t,i){const r=this.createKey(t,e);null!=r&&Array.isArray(r)?(r.forEach(e=>{const t=If._.toStringOrNull(If._.makeNull(e));i(t,t)}),0===r.length&&i(null,null)):i(r,r)}addValueForTreeDataOrGrouping(e,t,i,r){var n;let s;if(t){if(null==(n=e.childrenAfterGroup)?void 0:n.length)return;s=this.getDataPath(e.data)}else s=i.map(t=>this.valueService.getKeyForNode(t,e)),s.push(this.getValue(e));s&&(s=s.map(e=>If._.toStringOrNull(If._.makeNull(e)))),!t&&this.groupAllowUnbalanced&&(null==s?void 0:s.some(e=>null==e))&&(s=s.filter(e=>null!=e)),r(this.createKey(s),s)}getValue(e){return this.filterParams.getValue(e)}extractExistingFormattedKeys(e){if(!e)return null;const t=new Map;return e.forEach((e,i)=>{t.set(this.caseFormat(i),i)}),t}},Hf=class{};Hf.SELECT_ALL="__AG_SELECT_ALL__",Hf.ADD_SELECTION_TO_FILTER="__AG_ADD_SELECTION_TO_FILTER__";var Bf=class{constructor(e,t,i,r){this.valueService=e,this.valueFormatter=t,this.formatter=i,this.column=r,this.displayedKeys=[]}updateDisplayedValuesToAllAvailable(e,t,i){this.displayedKeys=Array.from(i)}updateDisplayedValuesToMatchMiniFilter(e,t,i,r,n){this.displayedKeys=[];for(let t of i)if(null==t)n&&this.displayedKeys.push(t);else{const i=e(t),n=this.valueService.formatValue(this.column,null,i,this.valueFormatter,!1);r(this.formatter(n))&&this.displayedKeys.push(t)}}getDisplayedValueCount(){return this.displayedKeys.length}getDisplayedItem(e){return this.displayedKeys[e]}getSelectAllItem(){return Hf.SELECT_ALL}getAddSelectionToFilterItem(){return Hf.ADD_SELECTION_TO_FILTER}getDisplayedKeys(){return this.displayedKeys}forEachDisplayedKey(e){this.displayedKeys.forEach(e)}someDisplayedKey(e){return this.displayedKeys.some(e)}hasGroups(){return!1}refresh(){}},zf=class e{constructor(e,t,i,r){this.formatter=e,this.treeListPathGetter=t,this.treeListFormatter=i,this.treeDataOrGrouping=r,this.allDisplayedItemsTree=[],this.activeDisplayedItemsFlat=[],this.selectAllItem={depth:0,filterPasses:!0,available:!0,treeKey:Hf.SELECT_ALL,children:this.allDisplayedItemsTree,expanded:!0,key:Hf.SELECT_ALL,parentTreeKeys:[]},this.addSelectionToFilterItem={depth:0,filterPasses:!0,available:!0,treeKey:Hf.ADD_SELECTION_TO_FILTER,expanded:!0,key:Hf.ADD_SELECTION_TO_FILTER,parentTreeKeys:[]}}updateDisplayedValuesToAllAvailable(e,t,i,r){"reload"===r?this.generateItemTree(e,t,i):"otherFilter"===r?(this.updateAvailable(i),this.updateExpandAll()):"miniFilter"===r&&(this.resetFilter(),this.updateExpandAll()),this.flattenItems()}updateDisplayedValuesToMatchMiniFilter(e,t,i,r,n,s){"reload"===s?this.generateItemTree(e,t,i):"otherFilter"===s&&this.updateAvailable(i),this.updateFilter(r,n),this.updateExpandAll(),this.flattenItems()}generateItemTree(e,t,i){var r;this.allDisplayedItemsTree=[],this.groupsExist=!1;const n=this.getTreeListPathGetter(e,i);for(let s of t){const t=null!=(r=n(e(s)))?r:[null];t.length>1&&(this.groupsExist=!0);const o=i.has(s);let a,l=this.allDisplayedItemsTree,c=[];t.forEach((e,i)=>{l||(l=[],a.children=l),a=l.find(t=>{var i;return(null==(i=t.treeKey)?void 0:i.toUpperCase())===(null==e?void 0:e.toUpperCase())}),a||(a={treeKey:e,depth:i,filterPasses:!0,expanded:!1,available:o,parentTreeKeys:c},i===t.length-1&&(a.key=s),l.push(a)),l=a.children,c=[...c,e]})}this.updateAvailable(i),this.selectAllItem.children=this.allDisplayedItemsTree,this.selectAllItem.expanded=!1}getTreeListPathGetter(t,i){if(this.treeListPathGetter)return this.treeListPathGetter;if(this.treeDataOrGrouping)return e=>e;let r=!1;for(const e of i){const i=t(e);if(i instanceof Date){r=!0;break}if(null!=i)break}return r?e.DATE_TREE_LIST_PATH_GETTER:(Lf._.warnOnce("property treeList=true for Set Filter params, but you did not provide a treeListPathGetter or values of type Date."),e=>[String(e)])}flattenItems(){this.activeDisplayedItemsFlat=[];const e=t=>{t.forEach(t=>{t.filterPasses&&t.available&&(this.activeDisplayedItemsFlat.push(t),t.children&&t.expanded&&e(t.children))})};e(this.allDisplayedItemsTree)}resetFilter(){const e=t=>{t.children&&t.children.forEach(t=>{e(t)}),t.filterPasses=!0};this.allDisplayedItemsTree.forEach(t=>e(t))}updateFilter(e,t){const i=i=>!!i.available&&(null==i.treeKey?t:e(this.formatter(this.treeListFormatter?this.treeListFormatter(i.treeKey,i.depth,i.parentTreeKeys):i.treeKey)));this.allDisplayedItemsTree.forEach(e=>this.recursiveItemCheck(e,!1,i,"filterPasses"))}getDisplayedValueCount(){return this.activeDisplayedItemsFlat.length}getDisplayedItem(e){return this.activeDisplayedItemsFlat[e]}getSelectAllItem(){return this.selectAllItem}getAddSelectionToFilterItem(){return this.addSelectionToFilterItem}getDisplayedKeys(){const e=[];return this.forEachDisplayedKey(t=>e.push(t)),e}forEachDisplayedKey(e){const t=(i,r)=>{i.children?i.expanded&&r||i.children.forEach(e=>{e.filterPasses&&t(e,!1)}):e(i.key)};this.activeDisplayedItemsFlat.forEach(e=>t(e,!0))}someDisplayedKey(e){const t=(i,r)=>i.children?(!i.expanded||!r)&&i.children.some(e=>!!e.filterPasses&&t(e,!1)):e(i.key);return this.activeDisplayedItemsFlat.some(e=>t(e,!0))}hasGroups(){return this.groupsExist}refresh(){this.updateExpandAll(),this.flattenItems()}updateExpandAll(){const e=(t,i,r)=>{for(const n of t){if(!n.filterPasses||!n.available||!n.children)continue;if(i=i||!!n.expanded,r=r||!n.expanded,i&&r)return;const t=e(n.children,i,r);if(void 0===t)return;t?i=!0:r=!0}return i&&r?void 0:i},t=this.getSelectAllItem();t.expanded=e(t.children,!1,!1)}recursiveItemCheck(e,t,i,r){let n=!1;e.children&&e.children.forEach(s=>{const o=this.recursiveItemCheck(s,t||i(e),i,r);n=n||o});const s=t||n||i(e);return e[r]=s,s}updateAvailable(e){const t=t=>e.has(t.key);this.allDisplayedItemsTree.forEach(e=>this.recursiveItemCheck(e,!1,t,"available"))}};zf.DATE_TREE_LIST_PATH_GETTER=e=>e?[String(e.getFullYear()),String(e.getMonth()+1),String(e.getDate())]:null;var Uf=zf,Wf=class{constructor({caseFormat:e}){this.filteringKeys=null,this.filteringKeysCaseFormatted=null,this.hasNoAppliedFilteringKeys=!1,this.caseFormat=e}allFilteringKeys(){return this.filteringKeys}allFilteringKeysCaseFormatted(){return this.filteringKeysCaseFormatted}noAppliedFilteringKeys(){return this.hasNoAppliedFilteringKeys}setFilteringKeys(e){this.filteringKeys=new Set(e),this.hasNoAppliedFilteringKeys=!this.filteringKeys||0===this.filteringKeys.size,this.filteringKeysCaseFormatted=new Set,this.filteringKeys.forEach(e=>this.filteringKeysCaseFormatted.add(this.caseFormat(e)))}addFilteringKey(e){null==this.filteringKeys&&(this.filteringKeys=new Set,this.filteringKeysCaseFormatted=new Set),this.filteringKeys.add(e),this.filteringKeysCaseFormatted.add(this.caseFormat(e)),this.hasNoAppliedFilteringKeys&&(this.hasNoAppliedFilteringKeys=!1)}hasCaseFormattedFilteringKey(e){return this.filteringKeysCaseFormatted.has(this.caseFormat(e))}hasFilteringKey(e){return this.filteringKeys.has(e)}reset(){this.filteringKeys=null,this.filteringKeysCaseFormatted=null,this.hasNoAppliedFilteringKeys=!1}},jf=class e{constructor(e){this.localEventService=new Df.EventService,this.miniFilterText=null,this.addCurrentSelectionToFilter=!1,this.providedValues=null,this.allValues=new Map,this.availableKeys=new Set,this.selectedKeys=new Set,this.initialised=!1;const{usingComplexObjects:t,columnModel:i,valueService:r,treeDataTreeList:n,groupingTreeList:s,filterParams:o,gos:a,valueFormatter:l,addManagedListener:c}=e,{column:u,colDef:h,textFormatter:d,doesRowPassOtherFilter:p,suppressSorting:g,comparator:f,rowModel:m,values:v,caseSensitive:C,convertValuesToStrings:y,treeList:w,treeListPathGetter:S,treeListFormatter:b}=o;this.filterParams=o,this.gos=a,this.setIsLoading=e.setIsLoading,this.translate=e.translate,this.caseFormat=e.caseFormat,this.createKey=e.createKey,this.usingComplexObjects=!!e.usingComplexObjects,this.formatter=d||Df.TextFilter.DEFAULT_FORMATTER,this.doesRowPassOtherFilters=p,this.suppressSorting=g||!1,this.convertValuesToStrings=!!y,this.filteringKeys=new Wf({caseFormat:this.caseFormat});const E=null!=f?f:h.comparator,A=!!n||!!s;this.compareByValue=!!(t&&E||A||w&&!S),this.entryComparator=A&&!E?this.createTreeDataOrGroupingComparator():!w||S||E?([e,t],[i,r])=>E(t,r):([e,t],[i,r])=>Df._.defaultComparator(t,r),this.keyComparator=null!=E?E:Df._.defaultComparator,this.caseSensitive=!!C;const T=a.get("getDataPath"),M=a.get("groupAllowUnbalanced");"clientSide"===m.getType()&&(this.clientSideValuesExtractor=new Vf(m,this.filterParams,this.createKey,this.caseFormat,i,r,A,!!n,T,M,c)),null==v?this.valuesType=2:(this.valuesType=Array.isArray(v)?0:1,this.providedValues=v),this.displayValueModel=w?new Uf(this.formatter,S,b,n||s):new Bf(r,l,this.formatter,u),this.updateAllValues().then(e=>this.resetSelectionState(e||[]))}addEventListener(e,t,i){this.localEventService.addEventListener(e,t,i)}removeEventListener(e,t,i){this.localEventService.removeEventListener(e,t,i)}updateOnParamsChange(e){return new Df.AgPromise(t=>{const{values:i,textFormatter:r,suppressSorting:n}=e,s=this.providedValues,o=this.suppressSorting;if(this.filterParams=e,this.formatter=r||Df.TextFilter.DEFAULT_FORMATTER,this.suppressSorting=n||!1,this.providedValues=null!=i?i:null,this.providedValues!==s||this.suppressSorting!==o){i&&0!==i.length?this.valuesType=Array.isArray(i)?0:1:(this.valuesType=2,this.providedValues=null);const e=this.getModel();this.updateAllValues().then(i=>{this.setModel(e).then(()=>t())})}else t()})}refreshValues(){return new Df.AgPromise(e=>{this.allValuesPromise.then(()=>{const t=this.getModel();this.updateAllValues(),this.setModel(t).then(()=>e())})})}overrideValues(e){return new Df.AgPromise(t=>{this.allValuesPromise.then(()=>{this.valuesType=0,this.providedValues=e,this.refreshValues().then(()=>t())})})}refreshAfterAnyFilterChanged(){return this.showAvailableOnly()?this.allValuesPromise.then(e=>(this.updateAvailableKeys(null!=e?e:[],"otherFilter"),!0)):Df.AgPromise.resolve(!1)}isInitialised(){return this.initialised}updateAllValues(){return this.allValuesPromise=new Df.AgPromise(e=>{switch(this.valuesType){case 2:this.getValuesFromRowsAsync(!1).then(t=>e(this.processAllValues(t)));break;case 0:e(this.processAllValues(this.uniqueValues(this.validateProvidedValues(this.providedValues))));break;case 1:{this.setIsLoading(!0);const t=this.providedValues,{column:i,colDef:r}=this.filterParams,n=this.gos.addGridCommonParams({success:t=>{this.setIsLoading(!1),e(this.processAllValues(this.uniqueValues(this.validateProvidedValues(t))))},colDef:r,column:i});window.setTimeout(()=>t(n),0);break}default:throw new Error("Unrecognised valuesType")}}),this.allValuesPromise.then(e=>this.updateAvailableKeys(e||[],"reload")).then(()=>this.initialised=!0),this.allValuesPromise}processAllValues(e){const t=this.sortKeys(e);return this.allValues=null!=e?e:new Map,t}validateProvidedValues(e){if(this.usingComplexObjects&&(null==e?void 0:e.length)){const t=e[0];t&&"object"!=typeof t&&"function"!=typeof t&&(null==this.createKey(t)?Df._.warnOnce("Set Filter Key Creator is returning null for provided values and provided values are primitives. Please provide complex objects or set convertValuesToStrings=true in the filterParams. See https://www.ag-grid.com/javascript-data-grid/filter-set-filter-list/#filter-value-types"):Df._.warnOnce("Set Filter has a Key Creator, but provided values are primitives. Did you mean to provide complex objects or enable convertValuesToStrings?"))}return e}setValuesType(e){this.valuesType=e}getValuesType(){return this.valuesType}isKeyAvailable(e){return this.availableKeys.has(e)}showAvailableOnly(){return 2===this.valuesType}updateAvailableKeys(t,i){const r=this.showAvailableOnly()?this.sortKeys(this.getValuesFromRows(!0)):t;this.availableKeys=new Set(r),this.localEventService.dispatchEvent({type:e.EVENT_AVAILABLE_VALUES_CHANGED}),this.updateDisplayedValues(i,t)}sortKeys(e){const t=null!=e?e:new Map;if(this.suppressSorting)return Array.from(t.keys());let i;return i=this.compareByValue?Array.from(t.entries()).sort(this.entryComparator).map(([e])=>e):Array.from(t.keys()).sort(this.keyComparator),this.filterParams.excelMode&&t.has(null)&&(i=i.filter(e=>null!=e),i.push(null)),i}getParamsForValuesFromRows(e=!1){return this.clientSideValuesExtractor?{predicate:t=>!e||this.doesRowPassOtherFilters(t),existingValues:e&&!this.caseSensitive?this.allValues:void 0}:(Df._.doOnce(()=>{console.error("AG Grid: Set Filter cannot initialise because you are using a row model that does not contain all rows in the browser. Either use a different filter type, or configure Set Filter such that you provide it with values")},"setFilterValueNotCSRM"),null)}getValuesFromRows(e=!1){const t=this.getParamsForValuesFromRows(e);return t?this.clientSideValuesExtractor.extractUniqueValues(t.predicate,t.existingValues):null}getValuesFromRowsAsync(e=!1){const t=this.getParamsForValuesFromRows(e);return t?this.clientSideValuesExtractor.extractUniqueValuesAsync(t.predicate,t.existingValues):Df.AgPromise.resolve(null)}setMiniFilter(e){return e=Df._.makeNull(e),this.miniFilterText!==e&&(null===e&&this.setAddCurrentSelectionToFilter(!1),this.miniFilterText=e,this.updateDisplayedValues("miniFilter"),!0)}getMiniFilter(){return this.miniFilterText}updateDisplayedValues(e,t){if("expansion"===e)return void this.displayValueModel.refresh();if(null==this.miniFilterText)return void this.displayValueModel.updateDisplayedValuesToAllAvailable(e=>this.getValue(e),t,this.availableKeys,e);const i=this.caseFormat(this.formatter(this.miniFilterText)||""),r=e=>null!=e&&this.caseFormat(e).indexOf(i)>=0,n=!!this.filterParams.excelMode&&r(this.translate("blanks"));this.displayValueModel.updateDisplayedValuesToMatchMiniFilter(e=>this.getValue(e),t,this.availableKeys,r,n,e)}getDisplayedValueCount(){return this.displayValueModel.getDisplayedValueCount()}getDisplayedItem(e){return this.displayValueModel.getDisplayedItem(e)}getSelectAllItem(){return this.displayValueModel.getSelectAllItem()}getAddSelectionToFilterItem(){return this.displayValueModel.getAddSelectionToFilterItem()}hasSelections(){return this.filterParams.defaultToNothingSelected?this.selectedKeys.size>0:this.allValues.size!==this.selectedKeys.size}getKeys(){return Array.from(this.allValues.keys())}getValues(){return Array.from(this.allValues.values())}getValue(e){return this.allValues.get(e)}setAddCurrentSelectionToFilter(e){this.addCurrentSelectionToFilter=e}isInWindowsExcelMode(){return"windows"===this.filterParams.excelMode}isAddCurrentSelectionToFilterChecked(){return this.isInWindowsExcelMode()&&this.addCurrentSelectionToFilter}showAddCurrentSelectionToFilter(){return this.isInWindowsExcelMode()&&Df._.exists(this.miniFilterText)&&this.miniFilterText.length>0}selectAllMatchingMiniFilter(e=!1){null==this.miniFilterText?this.selectedKeys=new Set(this.allValues.keys()):(e&&this.selectedKeys.clear(),this.displayValueModel.forEachDisplayedKey(e=>this.selectedKeys.add(e)))}deselectAllMatchingMiniFilter(){null==this.miniFilterText?this.selectedKeys.clear():this.displayValueModel.forEachDisplayedKey(e=>this.selectedKeys.delete(e))}selectKey(e){this.selectedKeys.add(e)}deselectKey(e){this.filterParams.excelMode&&this.isEverythingVisibleSelected()&&this.resetSelectionState(this.displayValueModel.getDisplayedKeys()),this.selectedKeys.delete(e)}isKeySelected(e){return this.selectedKeys.has(e)}isEverythingVisibleSelected(){return!this.displayValueModel.someDisplayedKey(e=>!this.isKeySelected(e))}isNothingVisibleSelected(){return!this.displayValueModel.someDisplayedKey(e=>this.isKeySelected(e))}getModel(){if(!this.hasSelections())return null;const e=this.isAddCurrentSelectionToFilterChecked()?this.filteringKeys.allFilteringKeys():null;if(e&&e.size>0){if(this.selectedKeys){const t=new Set([...Array.from(e),...Array.from(this.selectedKeys).filter(t=>!e.has(t))]);return Array.from(t)}return Array.from(e)}return Array.from(this.selectedKeys)}setModel(e){return this.allValuesPromise.then(t=>{if(null==e)this.resetSelectionState(null!=t?t:[]);else{this.selectedKeys.clear();const t=new Map;this.allValues.forEach((e,i)=>{t.set(this.caseFormat(i),i)}),e.forEach(e=>{const i=this.caseFormat(Df._.makeNull(e)),r=t.get(i);void 0!==r&&this.selectKey(r)})}})}uniqueValues(e){const t=new Map,i=new Set;return(null!=e?e:[]).forEach(e=>{const r=Df._.makeNull(e),n=this.convertAndGetKey(r),s=this.caseFormat(n);i.has(s)||(i.add(s),t.set(n,r))}),t}convertAndGetKey(e){return this.convertValuesToStrings?e:this.createKey(e)}resetSelectionState(e){this.filterParams.defaultToNothingSelected?this.selectedKeys.clear():this.selectedKeys=new Set(e)}hasGroups(){return this.displayValueModel.hasGroups()}createTreeDataOrGroupingComparator(){return([e,t],[i,r])=>{if(null==t)return null==r?0:-1;if(null==r)return 1;for(let e=0;e<t.length;e++){if(e>=r.length)return 1;const i=Df._.defaultComparator(t[e],r[e]);if(0!==i)return i}return 0}}setAppliedModelKeys(e){this.filteringKeys.setFilteringKeys(e)}addToAppliedModelKeys(e){this.filteringKeys.addFilteringKey(e)}getAppliedModelKeys(){return this.filteringKeys.allFilteringKeys()}getCaseFormattedAppliedModelKeys(){return this.filteringKeys.allFilteringKeysCaseFormatted()}hasAppliedModelKey(e){return this.filteringKeys.hasCaseFormattedFilteringKey(e)}hasAnyAppliedModelKey(){return!this.filteringKeys.noAppliedFilteringKeys()}};jf.EVENT_AVAILABLE_VALUES_CHANGED="availableValuesChanged";var Kf=jf,$f=class e extends Nf.Component{constructor(t){var i;super(t.isGroup?e.GROUP_TEMPLATE:e.TEMPLATE),this.focusWrapper=t.focusWrapper,this.value=t.value,this.params=t.params,this.translate=t.translate,this.valueFormatter=t.valueFormatter,this.item=t.item,this.isSelected=t.isSelected,this.isTree=t.isTree,this.depth=null!=(i=t.depth)?i:0,this.isGroup=t.isGroup,this.groupsExist=t.groupsExist,this.isExpanded=t.isExpanded,this.hasIndeterminateExpandState=t.hasIndeterminateExpandState}init(){this.addDestroyFunc(()=>{var e;return null==(e=this.destroyCellRendererComponent)?void 0:e.call(this)}),this.render(),this.eCheckbox.setLabelEllipsis(!0).setValue(this.isSelected,!0).setDisabled(!!this.params.readOnly).getInputElement().setAttribute("tabindex","-1"),this.refreshVariableAriaLabels(),this.isTree&&(this.depth>0&&this.addCssClass("ag-set-filter-indent-"+this.depth),this.isGroup?this.setupExpansion():this.groupsExist&&this.addCssClass("ag-set-filter-add-group-indent"),Nf._.setAriaLevel(this.getAriaElement(),this.depth+1)),this.refreshAriaChecked(),this.params.readOnly||this.eCheckbox.onValueChange(e=>this.onCheckboxChanged(!!e))}getFocusableElement(){return this.focusWrapper}setupExpansion(){this.eGroupClosedIcon.appendChild(Nf._.createIcon("setFilterGroupClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild(Nf._.createIcon("setFilterGroupOpen",this.gos,null)),this.addManagedListener(this.eGroupClosedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.addManagedListener(this.eGroupOpenedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.hasIndeterminateExpandState&&(this.eGroupIndeterminateIcon.appendChild(Nf._.createIcon("setFilterGroupIndeterminate",this.gos,null)),this.addManagedListener(this.eGroupIndeterminateIcon,"click",this.onExpandOrContractClicked.bind(this))),this.setExpandedIcons(),this.refreshAriaExpanded()}onExpandOrContractClicked(){this.setExpanded(!this.isExpanded)}setExpanded(t,i){if(this.isGroup&&t!==this.isExpanded){this.isExpanded=t;const r={type:e.EVENT_EXPANDED_CHANGED,isExpanded:!!t,item:this.item};i||this.dispatchEvent(r),this.setExpandedIcons(),this.refreshAriaExpanded()}}setExpandedIcons(){Nf._.setDisplayed(this.eGroupClosedIcon,this.hasIndeterminateExpandState?!1===this.isExpanded:!this.isExpanded),Nf._.setDisplayed(this.eGroupOpenedIcon,!0===this.isExpanded),this.hasIndeterminateExpandState&&Nf._.setDisplayed(this.eGroupIndeterminateIcon,void 0===this.isExpanded)}onCheckboxChanged(t){this.isSelected=t;const i={type:e.EVENT_SELECTION_CHANGED,isSelected:t,item:this.item};this.dispatchEvent(i),this.refreshVariableAriaLabels(),this.refreshAriaChecked()}toggleSelected(){this.params.readOnly||this.setSelected(!this.isSelected)}setSelected(e,t){this.isSelected=e,this.eCheckbox.setValue(e,t),this.refreshAriaChecked()}refreshVariableAriaLabels(){if(!this.isTree)return;const e=this.localeService.getLocaleTextFunc(),t=this.eCheckbox.getValue(),i=void 0===t?e("ariaIndeterminate","indeterminate"):t?e("ariaVisible","visible"):e("ariaHidden","hidden"),r=e("ariaToggleVisibility","Press SPACE to toggle visibility");Nf._.setAriaLabelledBy(this.eCheckbox.getInputElement(),void 0),this.eCheckbox.setInputAriaLabel(`${r} (${i})`)}setupFixedAriaLabels(e){if(!this.isTree)return;const t=this.localeService.getLocaleTextFunc()("ariaFilterValue","Filter Value"),i=this.getAriaElement();Nf._.setAriaLabel(i,`${e} ${t}`),Nf._.setAriaDescribedBy(i,this.eCheckbox.getInputElement().id)}refreshAriaChecked(){const e=this.getAriaElement();Nf._.setAriaChecked(e,this.eCheckbox.getValue())}refreshAriaExpanded(){Nf._.setAriaExpanded(this.getAriaElement(),!!this.isExpanded)}refresh(e,t,i){var r,n;if(this.item=e,t!==this.isSelected&&this.setSelected(t,!0),this.setExpanded(i,!0),this.valueFunction){const e=this.valueFunction();this.setTooltipAndCellRendererParams(e,e),this.cellRendererComponent||this.renderCellWithoutCellRenderer()}if(this.cellRendererComponent&&!(null==(n=(r=this.cellRendererComponent).refresh)?void 0:n.call(r,this.cellRendererParams))){const e=this.cellRendererComponent;this.renderCell(),this.destroyBean(e)}}render(){const{params:{column:e}}=this;let{value:t}=this,i=null;"function"==typeof t?(this.valueFunction=t,i=this.valueFunction(),t=i):i=this.isTree?Nf._.toStringOrNull(t):this.getFormattedValue(e,t),this.setTooltipAndCellRendererParams(t,i),this.renderCell()}setTooltipAndCellRendererParams(e,t){const i="whenTruncated"===this.gos.get("tooltipShowMode");if(this.params.showTooltips&&(!i||!this.params.cellRenderer)){const r=null!=t?t:Nf._.toStringOrNull(e);let n;i&&(n=()=>{const e=this.eCheckbox.getGui().querySelector(".ag-label");return!e||e.scrollWidth>e.clientWidth}),this.setTooltip({newTooltipText:r,location:"setFilterValue",getColDef:()=>this.params.colDef,getColumn:()=>this.params.column,shouldDisplayTooltip:n})}this.cellRendererParams=this.gos.addGridCommonParams({value:e,valueFormatted:t,colDef:this.params.colDef,column:this.params.column,setTooltip:(e,t)=>{this.setTooltip({newTooltipText:e,getColDef:()=>this.params.colDef,getColumn:()=>this.params.column,location:"setFilterValue",shouldDisplayTooltip:t})}})}getTooltipParams(){const e=super.getTooltipParams();return e.location="setFilterValue",e.colDef=this.getComponentHolder(),this.isTree&&(e.level=this.depth),e}getFormattedValue(e,t){return this.valueService.formatValue(e,null,t,this.valueFormatter,!1)}renderCell(){const e=this.userComponentFactory.getSetFilterCellRendererDetails(this.params,this.cellRendererParams),t=e?e.newAgStackInstance():void 0;null!=t?t.then(e=>{e&&(this.cellRendererComponent=e,this.eCheckbox.setLabel(e.getGui()),this.destroyCellRendererComponent=()=>this.destroyBean(e))}):this.renderCellWithoutCellRenderer()}renderCellWithoutCellRenderer(){var e;let t=null!=(e=null==this.cellRendererParams.valueFormatted?this.cellRendererParams.value:this.cellRendererParams.valueFormatted)?e:this.translate("blanks");"string"!=typeof t&&(Nf._.warnOnce(`Set Filter Value Formatter must return string values. Please ensure the Set Filter Value Formatter returns string values for complex objects, or set convertValuesToStrings=true in the filterParams. See ${this.getFrameworkOverrides().getDocLink("filter-set-filter-list/#filter-value-types")}`),t=""),this.eCheckbox.setLabel(t),this.setupFixedAriaLabels(t)}getComponentHolder(){return this.params.column.getColDef()}};$f.EVENT_SELECTION_CHANGED="selectionChanged",$f.EVENT_EXPANDED_CHANGED="expandedChanged",$f.GROUP_TEMPLATE='\n        <div class="ag-set-filter-item" aria-hidden="true">\n            <span class="ag-set-filter-group-icons">\n                <span class="ag-set-filter-group-closed-icon" ref="eGroupClosedIcon"></span>\n                <span class="ag-set-filter-group-opened-icon" ref="eGroupOpenedIcon"></span>\n                <span class="ag-set-filter-group-indeterminate-icon" ref="eGroupIndeterminateIcon"></span>\n            </span>\n            <ag-checkbox ref="eCheckbox" class="ag-set-filter-item-checkbox"></ag-checkbox>\n        </div>',$f.TEMPLATE='\n        <div class="ag-set-filter-item">\n            <ag-checkbox ref="eCheckbox" class="ag-set-filter-item-checkbox"></ag-checkbox>\n        </div>',Gf([(0,Nf.Autowired)("valueService")],$f.prototype,"valueService",2),Gf([(0,Nf.Autowired)("userComponentFactory")],$f.prototype,"userComponentFactory",2),Gf([(0,Nf.RefSelector)("eCheckbox")],$f.prototype,"eCheckbox",2),Gf([(0,Nf.RefSelector)("eGroupOpenedIcon")],$f.prototype,"eGroupOpenedIcon",2),Gf([(0,Nf.RefSelector)("eGroupClosedIcon")],$f.prototype,"eGroupClosedIcon",2),Gf([(0,Nf.RefSelector)("eGroupIndeterminateIcon")],$f.prototype,"eGroupIndeterminateIcon",2),Gf([Nf.PostConstruct],$f.prototype,"init",1);var qf=$f,Yf={loadingOoo:"Loading...",blanks:"(Blanks)",searchOoo:"Search...",selectAll:"(Select All)",selectAllSearchResults:"(Select All Search Results)",addCurrentSelectionToFilter:"Add current selection to filter",noMatches:"No matches."},Qf=class{getModelAsString(e,t){const{values:i}=e||t.getModel()||{},r=t.getValueModel();if(null==i||null==r)return"";const n=i.filter(e=>r.isKeyAvailable(e)),s=n.length;return`(${s}) ${n.slice(0,10).map(e=>t.getFormattedValue(e)).join(",")}${s>10?",...":""}`}},Xf=class extends xf.ProvidedFilter{constructor(){super("setFilter"),this.valueModel=null,this.setFilterParams=null,this.virtualList=null,this.caseSensitive=!1,this.convertValuesToStrings=!1,this.treeDataTreeList=!1,this.groupingTreeList=!1,this.hardRefreshVirtualList=!1,this.noValueFormatterSupplied=!1,this.filterModelFormatter=new Qf,this.updateSetFilterOnParamsChange=e=>{var t;this.setFilterParams=e,this.convertValuesToStrings=!!e.convertValuesToStrings,this.caseSensitive=!!e.caseSensitive;const i=null!=(t=e.keyCreator)?t:e.colDef.keyCreator;this.setValueFormatter(e.valueFormatter,i,this.convertValuesToStrings,!!e.treeList,!!e.colDef.refData);const r=e.column.getId().startsWith(xf.GROUP_AUTO_COLUMN_ID);this.treeDataTreeList=this.gos.get("treeData")&&!!e.treeList&&r,this.getDataPath=this.gos.get("getDataPath"),this.groupingTreeList=!!this.columnModel.getRowGroupColumns().length&&!!e.treeList&&r,this.createKey=this.generateCreateKey(i,this.convertValuesToStrings,this.treeDataTreeList||this.groupingTreeList)}}postConstruct(){super.postConstruct()}updateUiVisibility(){}createBodyTemplate(){return`\n            <div class="ag-set-filter">\n                <div ref="eFilterLoading" class="ag-filter-loading ag-hidden">${this.translateForSetFilter("loadingOoo")}</div>\n                <ag-input-text-field class="ag-mini-filter" ref="eMiniFilter"></ag-input-text-field>\n                <div ref="eFilterNoMatches" class="ag-filter-no-matches ag-hidden">${this.translateForSetFilter("noMatches")}</div>\n                <div ref="eSetFilterList" class="ag-set-filter-list" role="presentation"></div>\n            </div>`}handleKeyDown(e){if(super.handleKeyDown(e),!e.defaultPrevented)switch(e.key){case xf.KeyCode.SPACE:this.handleKeySpace(e);break;case xf.KeyCode.ENTER:this.handleKeyEnter(e);break;case xf.KeyCode.LEFT:this.handleKeyLeft(e);break;case xf.KeyCode.RIGHT:this.handleKeyRight(e)}}handleKeySpace(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.toggleSelected()}handleKeyEnter(e){if(!this.setFilterParams)return;const{excelMode:t,readOnly:i}=this.setFilterParams||{};t&&!i&&(e.preventDefault(),this.onBtApply(!1,!1,e),"mac"===this.setFilterParams.excelMode&&this.eMiniFilter.getInputElement().select())}handleKeyLeft(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.setExpanded(!1)}handleKeyRight(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.setExpanded(!0)}getComponentForKeyEvent(e){var t;if(!this.eSetFilterList.contains(this.gos.getActiveDomElement())||!this.virtualList)return;const i=this.virtualList.getLastFocusedRow();if(null==i)return;const r=this.virtualList.getComponentAt(i);if(null==r)return;e.preventDefault();const{readOnly:n}=null!=(t=this.setFilterParams)?t:{};return n?void 0:r}getCssIdentifier(){return"set-filter"}setModel(e){var t;return null==e&&null==(null==(t=this.valueModel)?void 0:t.getModel())?(this.setMiniFilter(null),xf.AgPromise.resolve()):super.setModel(e)}refresh(e){var t,i,r;return!!super.refresh(e)&&(!["treeList","treeListFormatter","treeListPathGetter","keyCreator","convertValuesToStrings","caseSensitive","comparator","suppressSelectAll","excelMode"].some(t=>{var i;return e[t]!==(null==(i=this.setFilterParams)?void 0:i[t])})&&!this.haveColDefParamsChanged(e.colDef)&&(super.updateParams(e),this.updateSetFilterOnParamsChange(e),this.updateMiniFilter(),e.cellRenderer===(null==(t=this.setFilterParams)?void 0:t.cellRenderer)&&e.valueFormatter===(null==(i=this.setFilterParams)?void 0:i.valueFormatter)||this.checkAndRefreshVirtualList(),null==(r=this.valueModel)||r.updateOnParamsChange(e).then(()=>{var e;(null==(e=this.valueModel)?void 0:e.hasSelections())&&this.refreshFilterValues()}),!0))}haveColDefParamsChanged(e){var t;const i=null==(t=this.setFilterParams)?void 0:t.colDef;return["keyCreator","filterValueGetter"].some(t=>e[t]!==(null==i?void 0:i[t]))}setModelAndRefresh(e){return this.valueModel?this.valueModel.setModel(e).then(()=>this.checkAndRefreshVirtualList()):xf.AgPromise.resolve()}resetUiToDefaults(){return this.setMiniFilter(null),this.setModelAndRefresh(null)}setModelIntoUi(e){this.setMiniFilter(null);const t=null==e?null:e.values;return this.setModelAndRefresh(t)}getModelFromUi(){if(!this.valueModel)throw new Error("Value model has not been created.");const e=this.valueModel.getModel();return e?{values:e,filterType:this.getFilterType()}:null}getFilterType(){return"set"}getValueModel(){return this.valueModel}areModelsEqual(e,t){return null==e&&null==t||null!=e&&null!=t&&xf._.areEqual(e.values,t.values)}setParams(e){var t;this.applyExcelModeOptions(e),super.setParams(e),this.updateSetFilterOnParamsChange(e);const i=null!=(t=e.keyCreator)?t:e.colDef.keyCreator;this.valueModel=new Kf({filterParams:e,setIsLoading:e=>this.setIsLoading(e),translate:e=>this.translateForSetFilter(e),caseFormat:e=>this.caseFormat(e),createKey:this.createKey,valueFormatter:this.valueFormatter,usingComplexObjects:!!i,gos:this.gos,columnModel:this.columnModel,valueService:this.valueService,treeDataTreeList:this.treeDataTreeList,groupingTreeList:this.groupingTreeList,addManagedListener:(e,t)=>this.addManagedListener(this.eventService,e,t)}),this.initialiseFilterBodyUi(),this.addEventListenersForDataChanges()}onAddCurrentSelectionToFilterChange(e){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.setAddCurrentSelectionToFilter(e)}setValueFormatter(e,t,i,r,n){let s=e;if(!s){if(t&&!i&&!r)throw new Error("AG Grid: Must supply a Value Formatter in Set Filter params when using a Key Creator unless convertValuesToStrings is enabled");this.noValueFormatterSupplied=!0,n||(s=e=>xf._.toStringOrNull(e.value))}this.valueFormatter=s}generateCreateKey(e,t,i){if(i&&!e)throw new Error("AG Grid: Must supply a Key Creator in Set Filter params when `treeList = true` on a group column, and Tree Data or Row Grouping is enabled.");return e?(t,i=null)=>{const r=this.getKeyCreatorParams(t,i);return xf._.makeNull(e(r))}:t?e=>Array.isArray(e)?e:xf._.makeNull(xf._.toStringOrNull(e)):e=>xf._.makeNull(xf._.toStringOrNull(e))}getFormattedValue(e){var t;let i=this.valueModel.getValue(e);this.noValueFormatterSupplied&&(this.treeDataTreeList||this.groupingTreeList)&&Array.isArray(i)&&(i=xf._.last(i));const r=this.valueService.formatValue(this.setFilterParams.column,null,i,this.valueFormatter,!1);return null!=(t=null==r?xf._.toStringOrNull(i):r)?t:this.translateForSetFilter("blanks")}applyExcelModeOptions(e){"windows"===e.excelMode?(e.buttons||(e.buttons=["apply","cancel"]),null==e.closeOnApply&&(e.closeOnApply=!0)):"mac"===e.excelMode&&(e.buttons||(e.buttons=["reset"]),null==e.applyMiniFilterWhileTyping&&(e.applyMiniFilterWhileTyping=!0),null==e.debounceMs&&(e.debounceMs=500)),e.excelMode&&e.defaultToNothingSelected&&(e.defaultToNothingSelected=!1,xf._.warnOnce('The Set Filter Parameter "defaultToNothingSelected" value was ignored because it does not work when "excelMode" is used.'))}addEventListenersForDataChanges(){this.isValuesTakenFromGrid()&&(this.addManagedListener(this.eventService,xf.Events.EVENT_CELL_VALUE_CHANGED,e=>{this.setFilterParams&&e.column===this.setFilterParams.column&&this.syncAfterDataChange()}),this.addManagedPropertyListeners(["treeData","getDataPath","groupAllowUnbalanced"],()=>{this.syncAfterDataChange()}))}syncAfterDataChange(){if(!this.valueModel)throw new Error("Value model has not been created.");return this.valueModel.refreshValues().then(()=>{this.checkAndRefreshVirtualList(),this.onBtApply(!1,!0)})}setIsLoading(e){xf._.setDisplayed(this.eFilterLoading,e),e||(this.hardRefreshVirtualList=!0)}initialiseFilterBodyUi(){this.initVirtualList(),this.initMiniFilter()}initVirtualList(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const e=this.localeService.getLocaleTextFunc()("ariaFilterList","Filter List"),t=!!this.setFilterParams.treeList,i=this.virtualList=this.createBean(new xf.VirtualList({cssIdentifier:"filter",ariaRole:t?"tree":"listbox",listName:e})),r=this.getRefElement("eSetFilterList");t&&r.classList.add("ag-set-filter-tree-list"),r&&r.appendChild(i.getGui());const{cellHeight:n}=this.setFilterParams;let s;null!=n&&i.setRowHeight(n),i.setComponentCreator((e,i)=>this.createSetListItem(e,t,i)),i.setComponentUpdater((e,t)=>this.updateSetListItem(e,t)),s=this.setFilterParams.suppressSelectAll?new Zf(this.valueModel):new Jf(this.valueModel,()=>this.isSelectAllSelected()),t&&(s=new em(s)),i.setModel(s)}getSelectAllLabel(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const e=null!=this.valueModel.getMiniFilter()&&this.setFilterParams.excelMode?"selectAllSearchResults":"selectAll";return this.translateForSetFilter(e)}getAddSelectionToFilterLabel(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");return this.translateForSetFilter("addCurrentSelectionToFilter")}createSetListItem(e,t,i){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const r=this.valueModel.hasGroups(),{isSelected:n,isExpanded:s}=this.isSelectedExpanded(e),{value:o,depth:a,isGroup:l,hasIndeterminateExpandState:c,selectedListener:u,expandedListener:h}=this.newSetListItemAttributes(e,t),d={focusWrapper:i,value:o,params:this.setFilterParams,translate:e=>this.translateForSetFilter(e),valueFormatter:this.valueFormatter,item:e,isSelected:n,isTree:t,depth:a,groupsExist:r,isGroup:l,isExpanded:s,hasIndeterminateExpandState:c},p=this.createBean(new qf(d));return p.addEventListener(qf.EVENT_SELECTION_CHANGED,u),h&&p.addEventListener(qf.EVENT_EXPANDED_CHANGED,h),p}newSetTreeItemAttributes(e,t){var i,r,n,s,o,a;if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const l=this.valueModel.hasGroups();return e.key===Hf.SELECT_ALL?{value:()=>this.getSelectAllLabel(),isGroup:l,depth:e.depth,hasIndeterminateExpandState:!0,selectedListener:e=>this.onSelectAll(e.isSelected),expandedListener:e=>this.onExpandAll(e.item,e.isExpanded)}:e.key===Hf.ADD_SELECTION_TO_FILTER?{value:()=>this.getAddSelectionToFilterLabel(),depth:e.depth,isGroup:!1,hasIndeterminateExpandState:!1,selectedListener:e=>{this.onAddCurrentSelectionToFilterChange(e.isSelected)}}:e.children?{value:null!=(n=null==(r=(i=this.setFilterParams).treeListFormatter)?void 0:r.call(i,e.treeKey,e.depth,e.parentTreeKeys))?n:e.treeKey,depth:e.depth,isGroup:!0,selectedListener:e=>this.onGroupItemSelected(e.item,e.isSelected),expandedListener:e=>this.onExpandedChanged(e.item,e.isExpanded)}:{value:null!=(a=null==(o=(s=this.setFilterParams).treeListFormatter)?void 0:o.call(s,e.treeKey,e.depth,e.parentTreeKeys))?a:e.treeKey,depth:e.depth,selectedListener:e=>this.onItemSelected(e.item.key,e.isSelected)}}newSetListItemAttributes(e,t){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");return this.isSetFilterModelTreeItem(e)?this.newSetTreeItemAttributes(e,t):e===Hf.SELECT_ALL?{value:()=>this.getSelectAllLabel(),selectedListener:e=>this.onSelectAll(e.isSelected)}:e===Hf.ADD_SELECTION_TO_FILTER?{value:()=>this.getAddSelectionToFilterLabel(),selectedListener:e=>{this.onAddCurrentSelectionToFilterChange(e.isSelected)}}:{value:this.valueModel.getValue(e),selectedListener:e=>this.onItemSelected(e.item,e.isSelected)}}updateSetListItem(e,t){const{isSelected:i,isExpanded:r}=this.isSelectedExpanded(e);t.refresh(e,i,r)}isSelectedExpanded(e){let t,i;return this.isSetFilterModelTreeItem(e)?(i=e.expanded,t=e.key===Hf.SELECT_ALL?this.isSelectAllSelected():e.key===Hf.ADD_SELECTION_TO_FILTER?this.valueModel.isAddCurrentSelectionToFilterChecked():e.children?this.areAllChildrenSelected(e):this.valueModel.isKeySelected(e.key)):t=e===Hf.SELECT_ALL?this.isSelectAllSelected():e===Hf.ADD_SELECTION_TO_FILTER?this.valueModel.isAddCurrentSelectionToFilterChecked():this.valueModel.isKeySelected(e),{isSelected:t,isExpanded:i}}isSetFilterModelTreeItem(e){return void 0!==(null==e?void 0:e.treeKey)}initMiniFilter(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{eMiniFilter:e,localeService:t}=this,i=t.getLocaleTextFunc();e.setDisplayed(!this.setFilterParams.suppressMiniFilter),e.setValue(this.valueModel.getMiniFilter()),e.onValueChange(()=>this.onMiniFilterInput()),e.setInputAriaLabel(i("ariaSearchFilterValues","Search filter values")),this.addManagedListener(e.getInputElement(),"keydown",e=>this.onMiniFilterKeyDown(e))}updateMiniFilter(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{eMiniFilter:e}=this;e.isDisplayed()!==!this.setFilterParams.suppressMiniFilter&&e.setDisplayed(!this.setFilterParams.suppressMiniFilter);const t=this.valueModel.getMiniFilter();e.getValue()!==t&&e.setValue(t)}afterGuiAttached(e){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");super.afterGuiAttached(e),this.resetExpansion(),this.refreshVirtualList();const{eMiniFilter:t}=this;t.setInputPlaceholder(this.translateForSetFilter("searchOoo")),e&&e.suppressFocus||t.getFocusableElement().focus()}afterGuiDetached(){var e,t;super.afterGuiDetached(),(null==(e=this.setFilterParams)?void 0:e.excelMode)&&this.resetMiniFilter();const i=this.getModel();!(null==(t=this.setFilterParams)?void 0:t.excelMode)&&this.areModelsEqual(i,this.getModelFromUi())||(this.resetUiToActiveModel(i),this.showOrHideResults())}applyModel(e="api"){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");this.setFilterParams.excelMode&&"rowDataUpdated"!==e&&this.valueModel.isEverythingVisibleSelected()&&this.valueModel.selectAllMatchingMiniFilter();const t=this.valueModel.showAddCurrentSelectionToFilter()&&this.valueModel.isAddCurrentSelectionToFilterChecked();if(t&&!this.getModel())return!1;const i=super.applyModel(e),r=this.getModel();return r?(t||this.valueModel.setAppliedModelKeys(new Set),r.values.forEach(e=>{this.valueModel.addToAppliedModelKeys(e)})):t||this.valueModel.setAppliedModelKeys(null),i}isModelValid(e){return!this.setFilterParams||!this.setFilterParams.excelMode||null==e||e.values.length>0}doesFilterPass(e){if(!this.setFilterParams||!this.valueModel||!this.valueModel.getCaseFormattedAppliedModelKeys())return!0;if(!this.valueModel.hasAnyAppliedModelKey())return!1;const{node:t,data:i}=e;if(this.treeDataTreeList)return this.doesFilterPassForTreeData(t,i);if(this.groupingTreeList)return this.doesFilterPassForGrouping(t);let r=this.getValueFromNode(t);return this.convertValuesToStrings?this.doesFilterPassForConvertValuesToString(t,r):null!=r&&Array.isArray(r)?0===r.length?this.valueModel.hasAppliedModelKey(null):r.some(e=>this.isInAppliedModel(this.createKey(e,t))):this.isInAppliedModel(this.createKey(r,t))}doesFilterPassForConvertValuesToString(e,t){const i=this.createKey(t,e);return null!=i&&Array.isArray(i)?0===i.length?this.valueModel.hasAppliedModelKey(null):i.some(e=>this.isInAppliedModel(e)):this.isInAppliedModel(i)}doesFilterPassForTreeData(e,t){var i;return!(null==(i=e.childrenAfterGroup)?void 0:i.length)&&this.isInAppliedModel(this.createKey(this.checkMakeNullDataPath(this.getDataPath(t))))}doesFilterPassForGrouping(e){const t=this.columnModel.getRowGroupColumns().map(t=>this.valueService.getKeyForNode(t,e));return t.push(this.getValueFromNode(e)),this.isInAppliedModel(this.createKey(this.checkMakeNullDataPath(t)))}checkMakeNullDataPath(e){return e&&(e=e.map(e=>xf._.toStringOrNull(xf._.makeNull(e)))),(null==e?void 0:e.some(e=>null==e))?null:e}isInAppliedModel(e){return this.valueModel.hasAppliedModelKey(e)}getValueFromNode(e){return this.setFilterParams.getValue(e)}getKeyCreatorParams(e,t=null){return{value:e,colDef:this.setFilterParams.colDef,column:this.setFilterParams.column,node:t,data:null==t?void 0:t.data,api:this.setFilterParams.api,columnApi:this.setFilterParams.columnApi,context:this.setFilterParams.context}}onNewRowsLoaded(){this.isValuesTakenFromGrid()&&this.syncAfterDataChange()}isValuesTakenFromGrid(){return!!this.valueModel&&2===this.valueModel.getValuesType()}setFilterValues(e){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.overrideValues(e).then(()=>{this.checkAndRefreshVirtualList(),this.onUiChanged()})}resetFilterValues(){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.setValuesType(2),this.syncAfterDataChange()}refreshFilterValues(){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.isInitialised()&&this.valueModel.refreshValues().then(()=>{this.checkAndRefreshVirtualList(),this.onUiChanged()})}onAnyFilterChanged(){setTimeout(()=>{if(this.isAlive()){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.refreshAfterAnyFilterChanged().then(e=>{e&&(this.checkAndRefreshVirtualList(),this.showOrHideResults())})}},0)}onMiniFilterInput(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.valueModel.setMiniFilter(this.eMiniFilter.getValue()))return;const{applyMiniFilterWhileTyping:e,readOnly:t}=this.setFilterParams||{};!t&&e?this.filterOnAllVisibleValues(!1):this.updateUiAfterMiniFilterChange()}updateUiAfterMiniFilterChange(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{excelMode:e,readOnly:t}=this.setFilterParams||{};null==e||t?this.checkAndRefreshVirtualList():null==this.valueModel.getMiniFilter()?this.resetUiToActiveModel(this.getModel()):(this.valueModel.selectAllMatchingMiniFilter(!0),this.checkAndRefreshVirtualList(),this.onUiChanged()),this.showOrHideResults()}showOrHideResults(){if(!this.valueModel)throw new Error("Value model has not been created.");const e=null!=this.valueModel.getMiniFilter()&&this.valueModel.getDisplayedValueCount()<1;xf._.setDisplayed(this.eNoMatches,e),xf._.setDisplayed(this.eSetFilterList,!e)}resetMiniFilter(){var e;this.eMiniFilter.setValue(null,!0),null==(e=this.valueModel)||e.setMiniFilter(null)}resetUiToActiveModel(e,t){this.setModelAndRefresh(null==e?null:e.values).then(()=>{this.onUiChanged(!1,"prevent"),null==t||t()})}handleCancelEnd(e){this.setMiniFilter(null),super.handleCancelEnd(e)}onMiniFilterKeyDown(e){const{excelMode:t,readOnly:i}=this.setFilterParams||{};e.key!==xf.KeyCode.ENTER||t||i||this.filterOnAllVisibleValues()}filterOnAllVisibleValues(e=!0){const{readOnly:t}=this.setFilterParams||{};if(!this.valueModel)throw new Error("Value model has not been created.");if(t)throw new Error("Unable to filter in readOnly mode.");this.valueModel.selectAllMatchingMiniFilter(!0),this.checkAndRefreshVirtualList(),this.onUiChanged(!1,e?"immediately":"debounce"),this.showOrHideResults()}focusRowIfAlive(e){null!=e&&window.setTimeout(()=>{if(!this.virtualList)throw new Error("Virtual list has not been created.");this.isAlive()&&this.virtualList.focusRow(e)},0)}onSelectAll(e){if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.virtualList)throw new Error("Virtual list has not been created.");e?this.valueModel.selectAllMatchingMiniFilter():this.valueModel.deselectAllMatchingMiniFilter(),this.refreshAfterSelection()}onGroupItemSelected(e,t){const i=e=>{e.children?e.children.forEach(e=>i(e)):this.selectItem(e.key,t)};i(e),this.refreshAfterSelection()}onItemSelected(e,t){if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.virtualList)throw new Error("Virtual list has not been created.");this.selectItem(e,t),this.refreshAfterSelection()}selectItem(e,t){t?this.valueModel.selectKey(e):this.valueModel.deselectKey(e)}onExpandAll(e,t){const i=e=>{e.filterPasses&&e.available&&e.children&&(e.children.forEach(e=>i(e)),e.expanded=t)};i(e),this.refreshAfterExpansion()}onExpandedChanged(e,t){e.expanded=t,this.refreshAfterExpansion()}refreshAfterExpansion(){const e=this.virtualList.getLastFocusedRow();this.valueModel.updateDisplayedValues("expansion"),this.checkAndRefreshVirtualList(),this.focusRowIfAlive(e)}refreshAfterSelection(){const e=this.virtualList.getLastFocusedRow();this.checkAndRefreshVirtualList(),this.onUiChanged(),this.focusRowIfAlive(e)}setMiniFilter(e){this.eMiniFilter.setValue(e),this.onMiniFilterInput()}getMiniFilter(){return this.valueModel?this.valueModel.getMiniFilter():null}checkAndRefreshVirtualList(){if(!this.virtualList)throw new Error("Virtual list has not been created.");this.virtualList.refresh(!this.hardRefreshVirtualList),this.hardRefreshVirtualList&&(this.hardRefreshVirtualList=!1)}getFilterKeys(){return this.valueModel?this.valueModel.getKeys():[]}getFilterValues(){return this.valueModel?this.valueModel.getValues():[]}getValues(){return this.getFilterKeys()}refreshVirtualList(){this.setFilterParams&&this.setFilterParams.refreshValuesOnOpen?this.refreshFilterValues():this.checkAndRefreshVirtualList()}translateForSetFilter(e){return this.localeService.getLocaleTextFunc()(e,Yf[e])}isSelectAllSelected(){if(!this.setFilterParams||!this.valueModel)return!1;if(this.setFilterParams.defaultToNothingSelected){if(this.valueModel.hasSelections()&&this.valueModel.isEverythingVisibleSelected())return!0;if(this.valueModel.isNothingVisibleSelected())return!1}else{if(this.valueModel.hasSelections()&&this.valueModel.isNothingVisibleSelected())return!1;if(this.valueModel.isEverythingVisibleSelected())return!0}}areAllChildrenSelected(e){const t=e=>{if(e.children){let i=!1,r=!1;return e.children.some(e=>{if(!e.filterPasses||!e.available)return!1;const n=t(e);return void 0===n||(n?i=!0:r=!0,i&&r)})?void 0:i}return this.valueModel.isKeySelected(e.key)};return this.setFilterParams.defaultToNothingSelected?this.valueModel.hasSelections()&&t(e):t(e)}destroy(){null!=this.virtualList&&(this.virtualList.destroy(),this.virtualList=null),super.destroy()}caseFormat(e){return null==e||"string"!=typeof e||this.caseSensitive?e:e.toUpperCase()}resetExpansion(){var e,t;if(!(null==(e=this.setFilterParams)?void 0:e.treeList))return;const i=null==(t=this.valueModel)?void 0:t.getSelectAllItem();if(this.isSetFilterModelTreeItem(i)){const e=t=>{t.children&&(t.children.forEach(t=>e(t)),t.expanded=!1)};e(i),this.valueModel.updateDisplayedValues("expansion")}}getModelAsString(e){return this.filterModelFormatter.getModelAsString(e,this)}getPositionableElement(){return this.eSetFilterList}};Gf([(0,xf.RefSelector)("eMiniFilter")],Xf.prototype,"eMiniFilter",2),Gf([(0,xf.RefSelector)("eFilterLoading")],Xf.prototype,"eFilterLoading",2),Gf([(0,xf.RefSelector)("eSetFilterList")],Xf.prototype,"eSetFilterList",2),Gf([(0,xf.RefSelector)("eFilterNoMatches")],Xf.prototype,"eNoMatches",2),Gf([(0,xf.Autowired)("columnModel")],Xf.prototype,"columnModel",2),Gf([(0,xf.Autowired)("valueService")],Xf.prototype,"valueService",2);var Zf=class{constructor(e){this.model=e}getRowCount(){return this.model.getDisplayedValueCount()}getRow(e){return this.model.getDisplayedItem(e)}areRowsEqual(e,t){return e===t}},Jf=class{constructor(e,t){this.model=e,this.isSelectAllSelected=t}getRowCount(){const e=this.model.showAddCurrentSelectionToFilter()?2:1;return this.model.getDisplayedValueCount()+e}getRow(e){if(0===e)return this.model.getSelectAllItem();const t=this.model.showAddCurrentSelectionToFilter(),i=t?2:1;return 1===e&&t?this.model.getAddSelectionToFilterItem():this.model.getDisplayedItem(e-i)}areRowsEqual(e,t){return e===t}},em=class{constructor(e){this.model=e}getRowCount(){return this.model.getRowCount()}getRow(e){return this.model.getRow(e)}areRowsEqual(e,t){return null==e&&null==t||null!=e&&null!=t&&e.treeKey===t.treeKey&&e.depth===t.depth}},tm=class extends Of.Component{constructor(){super('\n            <div class="ag-floating-filter-input ag-set-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eFloatingFilterText"></ag-input-text-field>\n            </div>'),this.availableValuesListenerAdded=!1,this.filterModelFormatter=new Qf}destroy(){super.destroy()}init(e){this.params=e,this.eFloatingFilterText.setDisabled(!0).addGuiEventListener("click",()=>this.params.showParentFilter()),this.setParams(e)}setParams(e){const t=this.columnModel.getDisplayNameForColumn(e.column,"header",!0),i=this.localeService.getLocaleTextFunc();this.eFloatingFilterText.setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams(e)}onParentModelChanged(e){this.updateFloatingFilterText(e)}parentSetFilterInstance(e){this.params.parentFilterInstance(t=>{if(!(t instanceof Xf))throw new Error("AG Grid - SetFloatingFilter expects SetFilter as its parent");e(t)})}addAvailableValuesListener(){this.parentSetFilterInstance(e=>{const t=e.getValueModel();t&&this.addManagedListener(t,Kf.EVENT_AVAILABLE_VALUES_CHANGED,()=>this.updateFloatingFilterText())}),this.availableValuesListenerAdded=!0}updateFloatingFilterText(e){this.availableValuesListenerAdded||this.addAvailableValuesListener(),this.parentSetFilterInstance(t=>{this.eFloatingFilterText.setValue(this.filterModelFormatter.getModelAsString(e,t))})}};Gf([(0,Of.RefSelector)("eFloatingFilterText")],tm.prototype,"eFloatingFilterText",2),Gf([(0,Of.Autowired)("columnModel")],tm.prototype,"columnModel",2);var im={version:"31.3.4",moduleName:Pf.ModuleNames.SetFilterModule,beans:[],userComponents:[{componentName:"agSetColumnFilter",componentClass:Xf},{componentName:"agSetColumnFloatingFilter",componentClass:tm}],dependantModules:[_]},rm=i(98092),nm=i(98092),sm=i(21371),om=i(21371),am=i(21371),lm=i(21371),cm=i(21371),um=i(21371),hm=i(21371),dm=i(21371),pm=i(98092),gm=Object.defineProperty,fm=Object.getOwnPropertyDescriptor,mm=Object.getOwnPropertySymbols,vm=Object.prototype.hasOwnProperty,Cm=Object.prototype.propertyIsEnumerable,ym=(e,t,i)=>t in e?gm(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,wm=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?fm(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&gm(t,i,s),s},{extent:Sm,isNumber:bm,isString:Em,isStringObject:Am,isDate:Tm,createId:Mm,Padding:Rm}=om._Util,{LinearScale:_m,BandScale:Pm,TimeScale:xm}=om._Scale,Dm=class{constructor(){this.type="category",this.stroke="rgb(204, 214, 235)",this.strokeWidth=1}},Im=class e{constructor(){this.id=Mm(this),this.seriesRect={x:0,y:0,width:0,height:0},this._context=void 0,this._container=void 0,this._data=void 0,this.padding=new Rm(3),this.xKey="x",this.yKey="y",this.dataType=void 0,this.xData=[],this.yData=[],this.min=void 0,this.max=void 0,this.yScale=new _m,this.axis=new Dm,this.highlightStyle={size:6,fill:"yellow",stroke:"silver",strokeWidth:1},this._width=100,this._height=100,this.smallestInterval=void 0,this.layoutId=0,this.defaultDateFormatter=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1}),this._onMouseMove=this.onMouseMove.bind(this),this._onMouseOut=this.onMouseOut.bind(this);const t=new om._Scene.Group;this.rootGroup=t;const i=document.createElement("div");i.setAttribute("class","ag-sparkline-wrapper");const r=new om._Scene.Scene({});this.scene=r,this.canvasElement=r.canvas.element,r.setRoot(t),r.setContainer(i),this.resizeAndSetDimensions(this.width,this.height),e.tooltipDocuments.includes(document)||this.initialiseTooltipStyles(),this.setupDomEventListeners(this.canvasElement)}set context(e){this._context!==e&&(this._context=e)}get context(){return this._context}set container(e){if(this._container!==e){const{parentNode:t}=this.canvasElement;null!=t&&t.removeChild(this.canvasElement),e&&e.appendChild(this.canvasElement),this._container=e}}get container(){return this._container}set data(e){this._data!==e&&(this._data=e,this.processData(),this.mouseMoveEvent&&this.highlightedDatum&&this.updateHitPoint(this.mouseMoveEvent))}get data(){return this._data}resizeAndSetDimensions(e,t){this.scene.resize(e,t),this.seriesRect.width=e,this.seriesRect.height=t}initialiseTooltipStyles(){const t=document.createElement("style");t.innerHTML="\n.ag-sparkline-tooltip-wrapper {\n    position: absolute;\n    user-select: none;\n    pointer-events: none;\n}\n\n.ag-sparkline-tooltip {\n    position: relative;\n    font: 12px arial,sans-serif;\n    border-radius: 2px;\n    box-shadow: 0 1px 3px rgb(0 0 0 / 20%), 0 1px 1px rgb(0 0 0 / 14%);\n    line-height: 1.7em;\n    overflow: hidden;\n    white-space: nowrap;\n    z-index: 99999;\n    background-color: rgb(255, 255, 255);\n    color: rgba(0,0,0, 0.67);\n}\n\n.ag-sparkline-tooltip-content {\n    padding: 0 7px;\n    opacity: 1;\n}\n\n.ag-sparkline-tooltip-title {\n    padding-left: 7px;\n    opacity: 1;\n}\n\n.ag-sparkline-tooltip-wrapper-hidden {\n    top: -10000px !important;\n}\n\n.ag-sparkline-wrapper {\n    box-sizing: border-box;\n    overflow: hidden;\n}\n",document.head.insertBefore(t,document.head.querySelector("style")),e.tooltipDocuments.push(document)}set width(e){this._width!==e&&(this._width=e,this.scene.resize(e,this.height),this.scheduleLayout())}get width(){return this._width}set height(e){this._height!==e&&(this._height=e,this.scene.resize(this.width,e),this.scheduleLayout())}get height(){return this._height}update(){}updateYScale(){this.updateYScaleRange(),this.updateYScaleDomain()}updateYScaleDomain(){}updateYScaleRange(){const{yScale:e,seriesRect:t}=this;e.range=[t.height,0]}updateXScale(){const{type:e}=this.axis;this.xScale=this.getXScale(e),this.updateXScaleRange(),this.updateXScaleDomain()}updateXScaleRange(){this.xScale.range=[0,this.seriesRect.width]}updateXScaleDomain(){const{xData:e,xScale:t}=this;let i;(t instanceof _m||t instanceof xm)&&(i=Sm(e)),this.xScale.domain=i?i.slice():e}getXScale(e="category"){switch(e){case"number":return new _m;case"time":return new xm;default:return new Pm}}updateAxisLine(){}updateAxes(){this.updateYScale(),this.updateXScale(),this.updateAxisLine()}updateCrosshairs(){this.updateXCrosshairLine(),this.updateYCrosshairLine()}generateNodeData(){return[]}getNodeData(){return[]}updateNodes(){}updateXCrosshairLine(){}updateYCrosshairLine(){}highlightDatum(e){this.updateNodes()}dehighlightDatum(){this.highlightedDatum=void 0,this.updateNodes(),this.updateCrosshairs()}onMouseMove(e){this.mouseMoveEvent=e,this.updateHitPoint(e)}updateHitPoint(e){var t,i,r;const n=this.pickClosestSeriesNodeDatum(e.offsetX,e.offsetY);if(!n)return;const s=this.highlightedDatum;this.highlightedDatum=n,(this.highlightedDatum&&!s||this.highlightedDatum&&s&&this.highlightedDatum!==s)&&(this.highlightDatum(n),this.updateCrosshairs(),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e))),(null==(r=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.enabled)||r)&&this.handleTooltip(e,n)}onMouseOut(e){this.dehighlightDatum(),this.tooltip.toggle(!1),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e))}processData(){const{data:e,yData:t,xData:i}=this;if(!e||this.invalidData(this.data))return;t.length=0,i.length=0;const r=e.length,n=this.getDataType(e);this.dataType=n;const{type:s}=this.axis,o="number"!==s&&"time"!==s?"category":s,a="number"===o||"time"===o,l=(e,t)=>{null==this.smallestInterval&&(this.smallestInterval={x:1/0,y:1/0});const{x:i}=this.smallestInterval,r=Math.abs(e-t);r>0&&r<i&&(this.smallestInterval.x=r)};let c;if("number"===n)for(let n=0;n<r;n++){const r=n,s=e[n],u=this.getDatum(r,o),h=this.getDatum(s,"number");a&&l(u,c),i.push(u),t.push(h),c=u}else if("array"===n)for(let n=0;n<r;n++){const r=e[n];if(Array.isArray(r)){const e=r[0],n=r[1],s=this.getDatum(e,o),u=this.getDatum(n,"number");if(null==s)continue;a&&l(s,c),i.push(s),t.push(u),c=s}}else if("object"===n){const{yKey:n,xKey:s}=this;for(let u=0;u<r;u++){const r=e[u];if("object"==typeof r&&!Array.isArray(r)){const e=r[s],u=r[n],h=this.getDatum(e,o),d=this.getDatum(u,"number");if(null==h)continue;a&&l(h,c),i.push(h),t.push(d),c=h}}}this.updateAxes(),this.immediateLayout()}getDataType(e){for(const t of e)if(null!=t){if(bm(t))return"number";if(Array.isArray(t))return"array";if("object"==typeof t)return"object"}}getDatum(e,t){if("number"===t&&bm(e)||"time"===t&&(bm(e)||Tm(e)))return e;if("category"===t){if(Em(e)||Tm(e)||bm(e))return{toString:()=>String(e)};if(Am(e))return e}}get layoutScheduled(){return!!this.layoutId}scheduleLayout(){this.layoutId&&cancelAnimationFrame(this.layoutId),this.layoutId=requestAnimationFrame(()=>{this.immediateLayout(),this.layoutId=0})}immediateLayout(){this.setSparklineDimensions(),this.invalidData(this.data)||(this.updateXScaleRange(),this.updateYScaleRange(),this.updateAxisLine(),this.update(),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e)))}setSparklineDimensions(){const{width:e,height:t,padding:i,seriesRect:r,rootGroup:n}=this,s=e-i.left-i.right,o=t-i.top-i.bottom;r.width=s,r.height=o,r.x=i.left,r.y=i.top,n.translationX=r.x,n.translationY=r.y}pickClosestSeriesNodeDatum(e,t){let i,r=1/0;const n=this.rootGroup.transformPoint(e,t),s=this.getNodeData();for(let e=0;e<s.length;e++){const t=s[e];if(!t.point)return;const o=this.getDistance(n,t.point);o<=r&&(r=o,i=t)}return i}getDistance(e,t){return Math.abs(e.x-t.x)}handleTooltip(e,t){var i,r;const{seriesDatum:n}=t,{canvasElement:s}=this,{clientX:o,clientY:a}=e,l=null==(i=this.processedOptions)?void 0:i.tooltip,c={pageX:o,pageY:a,position:{xOffset:null==l?void 0:l.xOffset,yOffset:null==l?void 0:l.yOffset},container:null==l?void 0:l.container};null==c.container&&(c.container=s);const u=n.y,h=n.x;let d=null==(r=null==l?void 0:l.enabled)||r;const p=null==l?void 0:l.renderer;if(p){const e=p({context:this.context,datum:n,yValue:u,xValue:h});d="string"!=typeof e&&void 0!==e.enabled?e.enabled:d}const g=d&&void 0!==n.y&&this.getTooltipHtml(t);g&&this.tooltip.show(c,g)}formatNumericDatum(e){return String(Math.round(10*e)/10)}formatDatum(e){const t=this.axis.type||"category";return"number"===t&&"number"==typeof e?this.formatNumericDatum(e):"time"===t&&(e instanceof Date||bm(e))?this.defaultDateFormatter.format(e):String(e)}setupDomEventListeners(e){e.addEventListener("mousemove",this._onMouseMove),e.addEventListener("mouseout",this._onMouseOut)}cleanupDomEventListeners(e){e.removeEventListener("mousemove",this._onMouseMove),e.removeEventListener("mouseout",this._onMouseOut)}invalidData(e){return!e||!Array.isArray(e)}destroy(){this.cleanupDomEventListeners(this.canvasElement),this.scene.destroy(),this.container=void 0}};Im.tooltipDocuments=[];var Lm=Im;function Nm(e,t){var i,r,n;if("string"==typeof e)return e;t=null!=t?t:{};const{content:s=(null!=(i=t.content)?i:""),title:o=(null!=(r=t.title)?r:void 0),color:a=t.color,backgroundColor:l=t.backgroundColor,opacity:c=(null!=(n=t.opacity)?n:1)}=e;let u,h;a?(u=o?`<span class="${Fm.class}-title"; style="color: ${a}">${o}</span>`:"",h=`<span class="${Fm.class}-content" style="color: ${a}">${s}</span>`):(u=o?`<span class="${Fm.class}-title">${o}</span>`:"",h=`<span class="${Fm.class}-content">${s}</span>`);let d=`opacity: ${c}`;return l&&(d+=`; background-color: ${l.toLowerCase()}`),`<div class="${Fm.class}" style="${d}">\n                ${u}\n                ${h}\n            </div>`}var Om=class e{constructor(){this.element=document.createElement("div"),document.body.appendChild(this.element)}isVisible(){const{element:t}=this;if(t.classList)return!t.classList.contains(`${e.class}-wrapper-hidden`);const i=t.getAttribute("class");return!!i&&i.split(" ").indexOf(`${e.class}-wrapper-hidden`)<0}updateClass(t){const i=[`${e.class}-wrapper`];!0!==t&&i.push(`${e.class}-wrapper-hidden`),this.element.setAttribute("class",i.join(" "))}show(e,t){var i,r,n,s;this.toggle(!1);const{element:o}=this;if(void 0!==t)o.innerHTML=t;else if(!o.innerHTML)return;const a=null!=(r=null==(i=e.position)?void 0:i.xOffset)?r:10,l=null!=(s=null==(n=e.position)?void 0:n.yOffset)?s:0;let c=e.pageX+a,u=e.pageY+l;const h=o.getBoundingClientRect();let d=window.innerWidth-h.width;if(e.container){const t=e.container.getBoundingClientRect();d=t.left+(t.width-h.width)}c>d&&(c=e.pageX-o.clientWidth-a),"undefined"!=typeof scrollX&&(c+=scrollX),"undefined"!=typeof scrollY&&(u+=scrollY),o.style.left=`${Math.round(c)}px`,o.style.top=`${Math.round(u)}px`,this.toggle(!0)}toggle(e){this.updateClass(e)}destroy(){const{parentNode:e}=this.element;e&&e.removeChild(this.element)}};Om.class="ag-sparkline-tooltip";var Fm=Om;function km(e){switch(e){case"circle":default:return am._Scene.Circle;case"square":return am._Scene.Square;case"diamond":return am._Scene.Diamond}}function Gm(e,t="solid"){const i={solid:[],dash:[4,3],dot:[1,3],dashDot:[4,3,1,3],dashDotDot:[4,3,1,3,1,3],shortDot:[1,1],shortDash:[3,1],shortDashDot:[3,1,1,1],shortDashDotDot:[3,1,1,1,1,1],longDash:[8,3],longDashDot:[8,3,1,3],longDashDotDot:[8,3,1,3,1,3]},r={solid:[],dash:[3,3],dot:[0,3],dashDot:[3,3,0,3],dashDotDot:[3,3,0,3,0,3],shortDot:[0,2],shortDash:[2,2],shortDashDot:[2,2,0,2],shortDashDotDot:[2,2,0,2,0,2],longDash:[7,3],longDashDot:[7,3,0,3],longDashDotDot:[7,3,0,3,0,3]};return"round"===e||"square"===e?null==r[t]?(console.warn(`'${t}' is not a valid 'lineDash' option.`),r.solid):r[t]:null==i[t]?(console.warn(`'${t}' is not a valid 'lineDash' option.`),i.solid):i[t]}var{extent:Vm}=sm._Util,{BandScale:Hm}=sm._Scale,Bm=class{constructor(){this.enabled=!0,this.shape="circle",this.size=0,this.fill="rgb(124, 181, 236)",this.stroke="rgb(124, 181, 236)",this.strokeWidth=1,this.formatter=void 0}},zm=class{constructor(){this.stroke="rgb(124, 181, 236)",this.strokeWidth=1}},Um=class{constructor(){this.xLine={enabled:!0,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0},this.yLine={enabled:!1,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0}}},Wm=class extends Lm{constructor(){super(),this.fill="rgba(124, 181, 236, 0.25)",this.strokePath=new sm._Scene.Path,this.fillPath=new sm._Scene.Path,this.xCrosshairLine=new sm._Scene.Line,this.yCrosshairLine=new sm._Scene.Line,this.areaSparklineGroup=new sm._Scene.Group,this.xAxisLine=new sm._Scene.Line,this.markers=new sm._Scene.Group,this.markerSelection=sm._Scene.Selection.select(this.markers,()=>this.markerFactory()),this.markerSelectionData=[],this.marker=new Bm,this.line=new zm,this.crosshairs=new Um,this.rootGroup.append(this.areaSparklineGroup),this.xAxisLine.zIndex=500,this.fillPath.zIndex=50,this.strokePath.zIndex=1e3,this.xCrosshairLine.zIndex=2e3,this.yCrosshairLine.zIndex=2e3,this.markers.zIndex=2500,this.areaSparklineGroup.append([this.fillPath,this.xAxisLine,this.strokePath,this.xCrosshairLine,this.yCrosshairLine,this.markers])}markerFactory(){const{shape:e}=this.marker;return new(km(e))}getNodeData(){return this.markerSelectionData}update(){const e=this.generateNodeData();if(!e)return;const{nodeData:t,fillData:i,strokeData:r}=e;this.markerSelectionData=t,this.updateSelection(t),this.updateNodes(),this.updateStroke(r),this.updateFill(i)}updateYScaleDomain(){const{yData:e,yScale:t}=this,i=Vm(e);let r=0,n=1;void 0!==i&&(r=this.min=i[0],n=this.max=i[1]),r=r<0?r:0,n=n<0?0:n,t.domain=[r,n]}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n}=this;if(!e)return;const s=!(r instanceof Hm),o=s?0:r.bandwidth/2,a=t.length,l=[],c=[],u=[];let h,d,p,g;const f=n.convert(0);for(let e=0;e<a;e++){const m=t[e],v=i[e],C=r.convert(s?r.toDomain(v):v)+o,y=void 0===m?NaN:n.convert(m);e+1<a&&(g=r.convert(s?r.toDomain(i[e+1]):i[e+1])+o),u.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),void 0===m&&void 0!==p?(c.push({seriesDatum:void 0,point:{x:p,y:f}}),void 0!==g&&c.push({seriesDatum:void 0,point:{x:g,y:f}})):void 0!==m&&(c.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),l.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),h=void 0!==h?h:C,d=C),p=C}return c.push({seriesDatum:void 0,point:{x:d,y:f}},{seriesDatum:void 0,point:{x:h,y:f}}),{nodeData:l,fillData:c,strokeData:u}}updateAxisLine(){const{xScale:e,yScale:t,axis:i,xAxisLine:r}=this;r.x1=e.range[0],r.x2=e.range[1],r.y1=r.y2=0,r.stroke=i.stroke,r.strokeWidth=i.strokeWidth;const n=t.convert(0);r.translationY=n}updateSelection(e){this.markerSelection.update(e)}updateNodes(){const{highlightedDatum:e,highlightStyle:t,marker:i}=this,{size:r,fill:n,stroke:s,strokeWidth:o}=t,a=i.formatter;this.markerSelection.each((t,l,c)=>{const{point:u,seriesDatum:h}=l;if(!u)return;const d=l===e,p=d&&void 0!==n?n:i.fill,g=d&&void 0!==s?s:i.stroke,f=d&&void 0!==o?o:i.strokeWidth,m=d&&void 0!==r?r:i.size;let v;if(a){const e=0===c,t=c===this.markerSelectionData.length-1,i=h.y===this.min,r=h.y===this.max;v=a({datum:l,xValue:h.x,yValue:h.y,min:i,max:r,first:e,last:t,fill:p,stroke:g,strokeWidth:f,size:m,highlighted:d})}t.size=v&&null!=v.size?v.size:m,t.fill=v&&null!=v.fill?v.fill:p,t.stroke=v&&null!=v.stroke?v.stroke:g,t.strokeWidth=v&&null!=v.strokeWidth?v.strokeWidth:f,t.translationX=u.x,t.translationY=u.y,t.visible=v&&null!=v.enabled?v.enabled:i.enabled&&t.size>0})}updateStroke(e){const{strokePath:t,yData:i,line:r}=this,n=t.path;if(n.clear(),i.length<2)return;const s=e.length;let o=!0;for(let t=0;t<s;t++){const{point:i,seriesDatum:r}=e[t],s=i.x,a=i.y;null==r.y?o=!0:o?(n.moveTo(s,a),o=!1):n.lineTo(s,a)}t.lineJoin=t.lineCap="round",t.fill=void 0,t.stroke=r.stroke,t.strokeWidth=r.strokeWidth}updateFill(e){const{fillPath:t,yData:i,fill:r}=this,n=t.path,s=e.length;if(n.clear(),!(i.length<2)){for(let t=0;t<s;t++){const{point:i}=e[t],r=i.x,s=i.y;t>0?n.lineTo(r,s):n.moveTo(r,s)}n.closePath(),t.lineJoin="round",t.stroke=void 0,t.fill=r}}updateXCrosshairLine(){var e;const{yScale:t,xCrosshairLine:i,highlightedDatum:r,crosshairs:{xLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.y1=t.range[0],i.y2=t.range[1],i.x1=i.x2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:Gm(i.lineCap,n.lineDash),i.translationX=r.point.x}updateYCrosshairLine(){var e;const{xScale:t,yCrosshairLine:i,highlightedDatum:r,crosshairs:{yLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.x1=t.range[0],i.x2=t.range[1],i.y1=i.y2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:Gm(i.lineCap,n.lineDash),i.translationY=r.point.y}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?Nm(l({context:this.context,datum:n,yValue:s,xValue:o}),a):Nm(a)}};Wm.className="AreaSparkline";var{extent:jm}=lm._Util,{BandScale:Km}=lm._Scale,$m=class{constructor(){this.enabled=!0,this.shape="circle",this.size=0,this.fill="rgb(124, 181, 236)",this.stroke="rgb(124, 181, 236)",this.strokeWidth=1,this.formatter=void 0}},qm=class{constructor(){this.stroke="rgb(124, 181, 236)",this.strokeWidth=1}},Ym=class{constructor(){this.xLine={enabled:!0,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0},this.yLine={enabled:!1,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0}}},Qm=class extends Lm{constructor(){super(),this.linePath=new lm._Scene.Path,this.xCrosshairLine=new lm._Scene.Line,this.yCrosshairLine=new lm._Scene.Line,this.lineSparklineGroup=new lm._Scene.Group,this.markers=new lm._Scene.Group,this.markerSelection=lm._Scene.Selection.select(this.markers,()=>this.markerFactory()),this.markerSelectionData=[],this.marker=new $m,this.line=new qm,this.crosshairs=new Ym,this.rootGroup.append(this.lineSparklineGroup),this.linePath.zIndex=1e3,this.xCrosshairLine.zIndex=2e3,this.yCrosshairLine.zIndex=2e3,this.markers.zIndex=2500,this.lineSparklineGroup.append([this.linePath,this.xCrosshairLine,this.yCrosshairLine,this.markers])}getNodeData(){return this.markerSelectionData}markerFactory(){const{shape:e}=this.marker;return new(km(e))}onMarkerShapeChange(){this.markerSelection=this.markerSelection.clear(),this.scheduleLayout()}update(){const e=this.generateNodeData();e&&(this.markerSelectionData=e,this.updateSelection(e),this.updateNodes(),this.updateLine())}updateYScaleDomain(){const{yData:e,yScale:t}=this,i=jm(e);let r=0,n=1;if(void 0!==i&&(r=this.min=i[0],n=this.max=i[1]),r===n){const e=Math.abs(.01*r);r-=e,n+=e}t.domain=[r,n]}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n}=this;if(!e)return;const s=!(r instanceof Km),o=s?0:r.bandwidth/2,a=[];for(let e=0;e<t.length;e++){const l=t[e],c=i[e];if(null==l)continue;const u=r.convert(s?r.toDomain(c):c)+o,h=void 0===l?NaN:n.convert(l);a.push({seriesDatum:{x:c,y:l},point:{x:u,y:h}})}return a}updateSelection(e){this.markerSelection.update(e)}updateNodes(){const{highlightedDatum:e,highlightStyle:t,marker:i}=this,{size:r,fill:n,stroke:s,strokeWidth:o}=t,a=i.formatter;this.markerSelection.each((t,l,c)=>{const u=l===e,h=u&&void 0!==n?n:i.fill,d=u&&void 0!==s?s:i.stroke,p=u&&void 0!==o?o:i.strokeWidth,g=u&&void 0!==r?r:i.size;let f;const{seriesDatum:m,point:v}=l;if(a){const e=0===c,t=c===this.markerSelectionData.length-1,i=m.y===this.min,r=m.y===this.max;f=a({datum:l,xValue:m.x,yValue:m.y,min:i,max:r,first:e,last:t,fill:h,stroke:d,strokeWidth:p,size:g,highlighted:u})}t.size=f&&null!=f.size?f.size:g,t.fill=f&&null!=f.fill?f.fill:h,t.stroke=f&&null!=f.stroke?f.stroke:d,t.strokeWidth=f&&null!=f.strokeWidth?f.strokeWidth:p,t.translationX=v.x,t.translationY=v.y,t.visible=f&&null!=f.enabled?f.enabled:i.enabled&&t.size>0})}updateLine(){const{linePath:e,yData:t,xData:i,xScale:r,yScale:n,line:s}=this,o=e.path;if(o.clear(),t.length<2)return;const a=!(r instanceof Km),l=t.length,c=a?0:r.bandwidth/2;let u=!0;for(let e=0;e<l;e++){const s=i[e],l=t[e],h=r.convert(a?r.toDomain(s):s)+c,d=void 0===l?NaN:n.convert(l);null==l?u=!0:u?(o.moveTo(h,d),u=!1):o.lineTo(h,d)}e.fill=void 0,e.stroke=s.stroke,e.strokeWidth=s.strokeWidth}updateXCrosshairLine(){var e;const{yScale:t,xCrosshairLine:i,highlightedDatum:r,crosshairs:{xLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.y1=t.range[0],i.y2=t.range[1],i.x1=i.x2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:Gm(i.lineCap,n.lineDash),i.translationX=r.point.x}updateYCrosshairLine(){var e;const{xScale:t,yCrosshairLine:i,highlightedDatum:r,crosshairs:{yLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.x1=t.range[0],i.x2=t.range[1],i.y1=i.y2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:Gm(i.lineCap,n.lineDash),i.translationY=r.point.y}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?Nm(l({context:this.context,datum:n,yValue:s,xValue:o}),a):Nm(a)}};Qm.className="LineSparkline";var Xm=class{constructor(){this.enabled=!0,this.fontSize=8,this.fontFamily="Verdana, sans-serif",this.fontStyle=void 0,this.fontWeight=void 0,this.color="rgba(70, 70, 70, 1)"}},{extent:Zm}=um._Util,Jm=class extends Xm{constructor(){super(...arguments),this.formatter=void 0,this.placement="insideEnd"}},ev=class extends Lm{constructor(){super(),this.fill="rgb(124, 181, 236)",this.stroke="silver",this.strokeWidth=0,this.paddingInner=.1,this.paddingOuter=.2,this.valueAxisDomain=void 0,this.formatter=void 0,this.axisLine=new um._Scene.Line,this.bandWidth=0,this.sparklineGroup=new um._Scene.Group,this.rectGroup=new um._Scene.Group,this.labelGroup=new um._Scene.Group,this.rectSelection=um._Scene.Selection.select(this.rectGroup,um._Scene.Rect),this.labelSelection=um._Scene.Selection.select(this.labelGroup,um._Scene.Text),this.nodeSelectionData=[],this.label=new Jm,this.rootGroup.append(this.sparklineGroup),this.rectGroup.zIndex=50,this.axisLine.zIndex=500,this.labelGroup.zIndex=1500,this.sparklineGroup.append([this.rectGroup,this.axisLine,this.labelGroup]),this.axisLine.lineCap="round",this.label.enabled=!1}getNodeData(){return this.nodeSelectionData}update(){this.updateSelections(),this.updateNodes()}updateSelections(){const e=this.generateNodeData();e&&(this.nodeSelectionData=e,this.updateRectSelection(e),this.updateLabelSelection(e))}updateNodes(){this.updateRectNodes(),this.updateLabelNodes()}calculateStep(e){var t;const{xScale:i,paddingInner:r,paddingOuter:n,smallestInterval:s}=this;let o=(i.domain[1]-i.domain[0])/(null!=(t=null==s?void 0:s.x)?t:1)+1;const a=Math.min(o,50),l=a-1;return e/Math.max(1,2*n+l*r+a)}updateYScaleDomain(){const{yScale:e,yData:t,valueAxisDomain:i}=this,r=Zm(t);let n=0,s=1;void 0!==r&&(n=this.min=r[0],s=this.max=r[1]),n=n<0?n:0,s=s<0?0:s,i&&(i[1]<s&&(i[1]=s),i[0]>n&&(i[0]=n)),e.domain=i||[n,s]}updateRectSelection(e){this.rectSelection.update(e)}updateRectNodes(){const{highlightedDatum:e,formatter:t,fill:i,stroke:r,strokeWidth:n}=this,{fill:s,stroke:o,strokeWidth:a}=this.highlightStyle;this.rectSelection.each((l,c,u)=>{const h=c===e,d=h&&void 0!==s?s:i,p=h&&void 0!==o?o:r,g=h&&void 0!==a?a:n;let f;const{x:m,y:v,width:C,height:y,seriesDatum:w}=c;if(t){const e=0===u,i=u===this.nodeSelectionData.length-1,r=w.y===this.min,n=w.y===this.max;f=t({datum:c,xValue:w.x,yValue:w.y,width:C,height:y,min:r,max:n,first:e,last:i,fill:d,stroke:p,strokeWidth:g,highlighted:h})}l.fill=f&&f.fill||d,l.stroke=f&&f.stroke||p,l.strokeWidth=f&&f.strokeWidth||g,l.x=l.y=0,l.width=C,l.height=y,l.visible=l.height>0,l.translationX=m,l.translationY=v})}updateLabelSelection(e){this.labelSelection.update(e,e=>{e.tag=1,e.pointerEvents=um._Scene.PointerEvents.None})}updateLabelNodes(){const{label:{enabled:e,fontStyle:t,fontWeight:i,fontSize:r,fontFamily:n,color:s}}=this;this.labelSelection.each((o,a)=>{const l=a.label;l&&e?(o.fontStyle=t,o.fontWeight=i,o.fontSize=r,o.fontFamily=n,o.textAlign=l.textAlign,o.textBaseline=l.textBaseline,o.text=l.text,o.x=l.x,o.y=l.y,o.fill=s,o.visible=!0):o.visible=!1})}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?Nm(l({context:this.context,datum:n,yValue:s,xValue:o}),a):Nm(a)}formatLabelValue(e){return e%1!=0?e.toFixed(1):e.toFixed(0)}},{isNumber:tv}=cm._Util,{BandScale:iv}=cm._Scale,rv=class extends ev{updateYScaleRange(){const{seriesRect:e,yScale:t}=this;t.range=[0,e.width]}updateXScaleRange(){const{xScale:e,seriesRect:t,paddingOuter:i,paddingInner:r}=this;if(e instanceof iv)e.range=[0,t.height],e.paddingInner=r,e.paddingOuter=i;else{const n=this.calculateStep(t.height),s=n*i;this.bandWidth=n*(1-r),e.range=[s,t.height-s-this.bandWidth]}}updateAxisLine(){const{yScale:e,axis:t,axisLine:i,seriesRect:r}=this,{strokeWidth:n}=t;i.x1=0,i.x2=0,i.y1=0,i.y2=r.height,i.stroke=t.stroke,i.strokeWidth=n+(n%2==1?1:0);const s=e.convert(0);i.translationX=s}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n,fill:s,stroke:o,strokeWidth:a,label:l}=this;if(!e)return;const{fontStyle:c,fontWeight:u,fontSize:h,fontFamily:d,color:p,formatter:g,placement:f}=l,m=[],v=n.convert(0),C=!(r instanceof iv);for(let e=0,l=t.length;e<l;e++){let l=t[e];const y=i[e],w=void 0===l;w&&(l=0);const S=r.convert(C?r.toDomain(y):y),b=Math.min(void 0===l?NaN:n.convert(l),v),E=Math.max(void 0===l?NaN:n.convert(l),v),A=C?this.bandWidth:r.bandwidth,T=E-b,M={x:v,y:S};let R;R=g?g({value:l}):void 0!==l&&tv(l)?this.formatLabelValue(l):"";const _=S+A/2;let P;const x="middle";let D;const I=void 0!==l&&l>=0,L=4;if("center"===f)P=b+T/2,D="center";else if("outsideEnd"===f)P=b+(I?T+L:-L),D=I?"start":"end";else if("insideEnd"===f){P=b+(I?T-L:L),D=I?"end":"start";const e=cm._Scene.Text.getTextSize(R,d).width||20;(I&&P<v+e||!I&&P>v-e)&&(P=v+L*(I?1:-1),D=I?"start":"end")}else P=v+L*(I?1:-1),D=I?"start":"end";m.push({x:b,y:S,width:T,height:A,fill:s,stroke:o,strokeWidth:a,seriesDatum:{x:y,y:w?void 0:l},point:M,label:{x:P,y:_,text:R,fontStyle:c,fontWeight:u,fontSize:h,fontFamily:d,textAlign:D,textBaseline:x,fill:p}})}return m}getDistance(e,t){return Math.abs(e.y-t.y)}};rv.className="BarSparkline";var{isNumber:nv}=hm._Util,{BandScale:sv}=hm._Scale,ov=class extends ev{updateYScaleRange(){const{seriesRect:e,yScale:t}=this;t.range=[e.height,0]}updateXScaleRange(){const{xScale:e,seriesRect:t,paddingOuter:i,paddingInner:r}=this;if(e instanceof sv)e.range=[0,t.width],e.paddingInner=r,e.paddingOuter=i;else{const n=this.calculateStep(t.width),s=n*i;this.bandWidth=n*(1-r),e.range=[s,t.width-s-this.bandWidth]}}updateAxisLine(){const{yScale:e,axis:t,axisLine:i,seriesRect:r}=this,{strokeWidth:n}=t;i.x1=0,i.x2=r.width,i.y1=0,i.y2=0,i.stroke=t.stroke,i.strokeWidth=n+(n%2==1?1:0);const s=e.convert(0);i.translationY=s}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n,fill:s,stroke:o,strokeWidth:a,label:l}=this;if(!e)return;const{fontStyle:c,fontWeight:u,fontSize:h,fontFamily:d,color:p,formatter:g,placement:f}=l,m=[],v=n.convert(0),C=!(r instanceof sv);for(let e=0,l=t.length;e<l;e++){let l=t[e];const y=i[e],w=void 0===l;w&&(l=0);const S=Math.min(void 0===l?NaN:n.convert(l),v),b=r.convert(C?r.toDomain(y):y),E=Math.max(void 0===l?NaN:n.convert(l),v),A=C?this.bandWidth:r.bandwidth,T=E-S,M={x:b+A/2,y:v};let R;R=g?g({value:l}):void 0!==l&&nv(l)?this.formatLabelValue(l):"";const _=b+A/2;let P;const x="center";let D;const I=void 0!==l&&l>=0,L=2;if("center"===f)P=S+T/2,D="middle";else if("outsideEnd"===f)P=S+(I?-L:T+L),D=I?"bottom":"top";else if("insideEnd"===f){P=S+(I?L:T-L),D=I?"top":"bottom";const e=hm._Scene.Text.getTextSize(R,d).height||10;(I&&P>v-e||!I&&P<v+e)&&(P=v+L*(I?-1:1),D=I?"bottom":"top")}else P=v+L*(I?-1:1),D=I?"bottom":"top";m.push({x:b,y:S,width:A,height:T,fill:s,stroke:o,strokeWidth:a,seriesDatum:{x:y,y:w?void 0:l},point:M,label:{x:_,y:P,text:R,fontStyle:c,fontWeight:u,fontSize:h,fontFamily:d,textAlign:x,textBaseline:D,fill:p}})}return m}};ov.className="ColumnSparkline";var{isNumber:av}=dm._Util,lv=class{static create(e,t){const i=function(e="line"){switch(e){case"column":return new ov;case"bar":return new rv;case"area":return new Wm;default:return new Qm}}((e=dm._Util.deepClone(e)).type);return t&&(i.tooltip=t),function(e,t){mv(e,"context",t.context,t),mv(e,"width",t.width,t),mv(e,"height",t.height,t),mv(e,"container",t.container,t),mv(e,"xKey",t.xKey,t),mv(e,"yKey",t.yKey,t),t.padding&&function(e,t){mv(e,"top",t.top,t),mv(e,"right",t.right,t),mv(e,"bottom",t.bottom,t),mv(e,"left",t.left,t)}(e.padding,t.padding),t.axis&&function(e,t){mv(e,"type",t.type,t),mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t)}(e.axis,t.axis),t.highlightStyle&&function(e,t){mv(e,"fill",t.fill,t),mv(e,"size",t.size,t),mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t)}(e.highlightStyle,t.highlightStyle)}(i,e),function(e,t){switch(t.type){case"bar":case"column":!function(e,t){mv(e,"valueAxisDomain",t.valueAxisDomain,t),mv(e,"fill",t.fill,t),mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t),mv(e,"paddingInner",t.paddingInner,t),mv(e,"paddingOuter",t.paddingOuter,t),mv(e,"formatter",t.formatter,t),t.label&&function(e,t){mv(e,"enabled",t.enabled,t),mv(e,"fontStyle",t.fontStyle,t),mv(e,"fontWeight",t.fontWeight,t),mv(e,"fontSize",t.fontSize,t),mv(e,"fontFamily",t.fontFamily,t),mv(e,"textAlign",t.textAlign,t),mv(e,"textBaseline",t.textBaseline,t),mv(e,"color",t.color,t),mv(e,"formatter",t.formatter,t),mv(e,"placement",t.placement,t)}(e.label,t.label)}(e,t);break;case"area":!function(e,t){mv(e,"fill",t.fill,t),t.marker&&cv(e.marker,t.marker),t.line&&uv(e.line,t.line),t.crosshairs&&hv(e.crosshairs,t.crosshairs)}(e,t);break;default:!function(e,t){t.marker&&cv(e.marker,t.marker),t.line&&uv(e.line,t.line),t.crosshairs&&hv(e.crosshairs,t.crosshairs)}(e,t)}}(i,e),e.data&&(i.data=e.data),i.processedOptions=e,i}};function cv(e,t){mv(e,"enabled",t.enabled,t),mv(e,"size",t.size,t),mv(e,"shape",t.shape,t),mv(e,"fill",t.fill,t),mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t),mv(e,"formatter",t.formatter,t)}function uv(e,t){mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t)}function hv(e,t){e.xLine&&t.xLine&&dv(e.xLine,t.xLine),e.yLine&&t.yLine&&dv(e.yLine,t.yLine)}function dv(e,t){mv(e,"enabled",t.enabled,t),mv(e,"stroke",t.stroke,t),mv(e,"strokeWidth",t.strokeWidth,t),mv(e,"lineDash",t.lineDash,t),mv(e,"lineCap",t.lineCap,t)}var pv={},gv=(e,t,i)=>{if(av(t))return!0;const r=`AG Charts: ${e} must be a number, the value you provided is not a valid number. Using the default of ${i}px.`;var n,s;return n=()=>console.warn(r),pv[s=`${e} not a number`]||(n(),pv[s]=!0),!1},fv={xOffset:gv,yOffset:gv};function mv(e,t,i,r){if(t in r)if(t in e){const r=fv[t];(!r||r(t,i,e[t]))&&e[t]!==i&&(e[t]=i)}else console.warn(`Property ${t} does not exist on the target object.`)}var vv=class e extends nm.Component{constructor(){super(e.TEMPLATE)}init(e){let t=!0;const i=this.resizeObserverService.observeResize(this.getGui(),()=>{const{clientWidth:i,clientHeight:r}=this.getGui();if(0!==i&&0!==r)if(t){const n=((e,t)=>{for(var i in t||(t={}))vm.call(t,i)&&ym(e,i,t[i]);if(mm)for(var i of mm(t))Cm.call(t,i)&&ym(e,i,t[i]);return e})({data:e.value,width:i,height:r,context:{data:e.data}},e.sparklineOptions);this.sparkline=lv.create(n,this.sparklineTooltipSingleton.getSparklineTooltip()),this.eSparkline.appendChild(this.sparkline.canvasElement),t=!1}else this.sparkline.width=i,this.sparkline.height=r});this.addDestroyFunc(()=>i())}refresh(e){return!!this.sparkline&&(this.sparkline.data=e.value,!0)}destroy(){this.sparkline&&this.sparkline.destroy(),super.destroy()}};vv.TEMPLATE='<div class="ag-sparkline-wrapper">\n            <span ref="eSparkline"></span>\n        </div>',wm([(0,nm.RefSelector)("eSparkline")],vv.prototype,"eSparkline",2),wm([(0,nm.Autowired)("resizeObserverService")],vv.prototype,"resizeObserverService",2),wm([(0,nm.Autowired)("sparklineTooltipSingleton")],vv.prototype,"sparklineTooltipSingleton",2);var Cv=vv,yv=class extends pm.BeanStub{postConstruct(){this.tooltip=new Fm}getSparklineTooltip(){return this.tooltip}destroyTooltip(){this.tooltip&&this.tooltip.destroy()}};wm([pm.PostConstruct],yv.prototype,"postConstruct",1),wm([pm.PreDestroy],yv.prototype,"destroyTooltip",1),yv=wm([(0,pm.Bean)("sparklineTooltipSingleton")],yv);var wv={version:"31.3.4",moduleName:rm.ModuleNames.SparklinesModule,beans:[yv],userComponents:[{componentName:"agSparklineCellRenderer",componentClass:Cv}],dependantModules:[_]},Sv=i(98092),bv=i(98092),Ev=class extends bv.BeanStub{constructor(){super(),this.allComponents=new Map}registerStatusPanel(e,t){this.allComponents.set(e,t)}unregisterStatusPanel(e){this.allComponents.delete(e)}unregisterAllComponents(){this.allComponents.clear()}getStatusPanel(e){return this.allComponents.get(e)}destroy(){this.unregisterAllComponents(),super.destroy()}};Ev=h([(0,bv.Bean)("statusBarService")],Ev);var Av=i(98092),Tv=class e extends Av.Component{constructor(){super(e.TEMPLATE),this.compDestroyFunctions={}}postConstruct(){this.processStatusPanels(new Map),this.addManagedPropertyListeners(["statusBar"],this.handleStatusBarChanged.bind(this))}processStatusPanels(e){var t;const i=null==(t=this.gos.get("statusBar"))?void 0:t.statusPanels;if(i){const t=i.filter(e=>"left"===e.align);this.createAndRenderComponents(t,this.eStatusBarLeft,e);const r=i.filter(e=>"center"===e.align);this.createAndRenderComponents(r,this.eStatusBarCenter,e);const n=i.filter(e=>!e.align||"right"===e.align);this.createAndRenderComponents(n,this.eStatusBarRight,e)}else this.setDisplayed(!1)}handleStatusBarChanged(){var e;const t=null==(e=this.gos.get("statusBar"))?void 0:e.statusPanels,i=Array.isArray(t)&&t.length>0;this.setDisplayed(i);const r=new Map;i&&t.forEach(e=>{var t,i;const n=null!=(t=e.key)?t:e.statusPanel,s=this.statusBarService.getStatusPanel(n);if(null==s?void 0:s.refresh){const t=this.gos.addGridCommonParams(null!=(i=e.statusPanelParams)?i:{});s.refresh(t)&&(r.set(n,s),delete this.compDestroyFunctions[n],Av._.removeFromParent(s.getGui()))}}),this.resetStatusBar(),i&&this.processStatusPanels(r)}resetStatusBar(){this.eStatusBarLeft.innerHTML="",this.eStatusBarCenter.innerHTML="",this.eStatusBarRight.innerHTML="",this.destroyComponents(),this.statusBarService.unregisterAllComponents()}destroyComponents(){Object.values(this.compDestroyFunctions).forEach(e=>e()),this.compDestroyFunctions={}}createAndRenderComponents(e,t,i){const r=[];e.forEach(e=>{const t=e.key||e.statusPanel,n=i.get(t);let s;if(n)s=Av.AgPromise.resolve(n);else{const t={};if(s=this.userComponentFactory.getStatusPanelCompDetails(e,t).newAgStackInstance(),!s)return}r.push({key:t,promise:s})}),Av.AgPromise.all(r.map(e=>e.promise)).then(()=>{r.forEach(e=>{e.promise.then(i=>{const r=()=>{this.getContext().destroyBean(i)};this.isAlive()?(this.statusBarService.registerStatusPanel(e.key,i),t.appendChild(i.getGui()),this.compDestroyFunctions[e.key]=r):r()})})})}};Tv.TEMPLATE='<div class="ag-status-bar">\n            <div ref="eStatusBarLeft" class="ag-status-bar-left" role="status"></div>\n            <div ref="eStatusBarCenter" class="ag-status-bar-center" role="status"></div>\n            <div ref="eStatusBarRight" class="ag-status-bar-right" role="status"></div>\n        </div>',h([(0,Av.Autowired)("userComponentFactory")],Tv.prototype,"userComponentFactory",2),h([(0,Av.Autowired)("statusBarService")],Tv.prototype,"statusBarService",2),h([(0,Av.RefSelector)("eStatusBarLeft")],Tv.prototype,"eStatusBarLeft",2),h([(0,Av.RefSelector)("eStatusBarCenter")],Tv.prototype,"eStatusBarCenter",2),h([(0,Av.RefSelector)("eStatusBarRight")],Tv.prototype,"eStatusBarRight",2),h([Av.PostConstruct],Tv.prototype,"postConstruct",1),h([Av.PreDestroy],Tv.prototype,"destroyComponents",1);var Mv=Tv,Rv=i(98092),_v=class e extends Rv.Component{constructor(){super(e.TEMPLATE)}setLabel(e,t){this.setDisplayed(!1);const i=this.localeService.getLocaleTextFunc();this.eLabel.innerHTML=i(e,t)}setValue(e){this.eValue.innerHTML=e}};_v.TEMPLATE='<div class="ag-status-name-value">\n            <span ref="eLabel"></span>:&nbsp;\n            <span ref="eValue" class="ag-status-name-value-value"></span>\n        </div>',h([(0,Rv.RefSelector)("eLabel")],_v.prototype,"eLabel",2),h([(0,Rv.RefSelector)("eValue")],_v.prototype,"eValue",2);var Pv=_v,xv=i(98092),Dv=class extends Pv{postConstruct(){"clientSide"===this.rowModel.getType()?(this.setLabel("totalAndFilteredRows","Rows"),this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-total-and-filtered-row-count"),this.setDisplayed(!0),this.addManagedListener(this.eventService,xv.Events.EVENT_MODEL_UPDATED,this.onDataChanged.bind(this)),this.onDataChanged()):xv._.warnOnce("agTotalAndFilteredRowCountComponent should only be used with the client side row model.")}onDataChanged(){const e=this.localeService.getLocaleTextFunc(),t=e("thousandSeparator",","),i=e("decimalSeparator","."),r=xv._.formatNumberCommas(this.getFilteredRowCountValue(),t,i),n=xv._.formatNumberCommas(this.getTotalRowCount(),t,i);if(r===n)this.setValue(r);else{const e=this.localeService.getLocaleTextFunc();this.setValue(`${r} ${e("of","of")} ${n}`)}}getFilteredRowCountValue(){let e=0;return this.rowModel.forEachNodeAfterFilter(t=>{t.group||e++}),e}getTotalRowCount(){let e=0;return this.rowModel.forEachNode(t=>{t.group||e++}),e}init(){}refresh(){return!0}destroy(){super.destroy()}};h([(0,xv.Autowired)("rowModel")],Dv.prototype,"rowModel",2),h([xv.PostConstruct],Dv.prototype,"postConstruct",1);var Iv=i(98092),Lv=class extends Pv{postConstruct(){if(this.setLabel("filteredRows","Filtered"),"clientSide"!==this.rowModel.getType())return void Iv._.warnOnce("agFilteredRowCountComponent should only be used with the client side row model.");this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-filtered-row-count"),this.setDisplayed(!0);const e=this.onDataChanged.bind(this);this.addManagedListener(this.eventService,Iv.Events.EVENT_MODEL_UPDATED,e),e()}onDataChanged(){const e=this.getTotalRowCountValue(),t=this.getFilteredRowCountValue(),i=this.localeService.getLocaleTextFunc(),r=i("thousandSeparator",","),n=i("decimalSeparator",".");this.setValue(Iv._.formatNumberCommas(t,r,n)),this.setDisplayed(e!==t)}getTotalRowCountValue(){let e=0;return this.rowModel.forEachNode(t=>e+=1),e}getFilteredRowCountValue(){let e=0;return this.rowModel.forEachNodeAfterFilter(t=>{t.group||(e+=1)}),e}init(){}refresh(){return!0}destroy(){super.destroy()}};h([(0,Iv.Autowired)("rowModel")],Lv.prototype,"rowModel",2),h([Iv.PostConstruct],Lv.prototype,"postConstruct",1);var Nv=i(98092),Ov=class extends Pv{postConstruct(){this.setLabel("totalRows","Total Rows"),"clientSide"===this.rowModel.getType()?(this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-total-row-count"),this.setDisplayed(!0),this.addManagedListener(this.eventService,Nv.Events.EVENT_MODEL_UPDATED,this.onDataChanged.bind(this)),this.onDataChanged()):Nv._.warnOnce("agTotalRowCountComponent should only be used with the client side row model.")}onDataChanged(){const e=this.localeService.getLocaleTextFunc(),t=e("thousandSeparator",","),i=e("decimalSeparator",".");this.setValue(Nv._.formatNumberCommas(this.getRowCountValue(),t,i))}getRowCountValue(){let e=0;return this.rowModel.forEachLeafNode(t=>e+=1),e}init(){}refresh(){return!0}destroy(){super.destroy()}};h([(0,Nv.Autowired)("rowModel")],Ov.prototype,"rowModel",2),h([Nv.PostConstruct],Ov.prototype,"postConstruct",1);var Fv=i(98092),kv=class extends Pv{postConstruct(){if(!this.isValidRowModel())return void console.warn("AG Grid: agSelectedRowCountComponent should only be used with the client and server side row model.");this.setLabel("selectedRows","Selected"),this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-selected-row-count"),this.onRowSelectionChanged();const e=this.onRowSelectionChanged.bind(this);this.addManagedListener(this.eventService,Fv.Events.EVENT_MODEL_UPDATED,e),this.addManagedListener(this.eventService,Fv.Events.EVENT_SELECTION_CHANGED,e)}isValidRowModel(){const e=this.rowModel.getType();return"clientSide"===e||"serverSide"===e}onRowSelectionChanged(){const e=this.selectionService.getSelectionCount();if(e<0)return this.setValue("?"),void this.setDisplayed(!0);const t=this.localeService.getLocaleTextFunc(),i=t("thousandSeparator",","),r=t("decimalSeparator",".");this.setValue(Fv._.formatNumberCommas(e,i,r)),this.setDisplayed(e>0)}init(){}refresh(){return!0}destroy(){super.destroy()}};h([(0,Fv.Autowired)("rowModel")],kv.prototype,"rowModel",2),h([(0,Fv.Autowired)("selectionService")],kv.prototype,"selectionService",2),h([Fv.PostConstruct],kv.prototype,"postConstruct",1);var Gv=i(98092),Vv=class e extends Gv.Component{constructor(){super(e.TEMPLATE)}destroy(){super.destroy()}postConstruct(){this.isValidRowModel()?(this.avgAggregationComp.setLabel("avg","Average"),this.countAggregationComp.setLabel("count","Count"),this.minAggregationComp.setLabel("min","Min"),this.maxAggregationComp.setLabel("max","Max"),this.sumAggregationComp.setLabel("sum","Sum"),this.addManagedListener(this.eventService,Gv.Events.EVENT_RANGE_SELECTION_CHANGED,this.onRangeSelectionChanged.bind(this)),this.addManagedListener(this.eventService,Gv.Events.EVENT_MODEL_UPDATED,this.onRangeSelectionChanged.bind(this))):console.warn("AG Grid: agAggregationComponent should only be used with the client and server side row model.")}isValidRowModel(){const e=this.rowModel.getType();return"clientSide"===e||"serverSide"===e}init(e){this.params=e}refresh(e){return this.params=e,this.onRangeSelectionChanged(),!0}setAggregationComponentValue(e,t,i){var r;const n=this.getAllowedAggregationValueComponent(e);if(Gv._.exists(n)&&n){const e=this.localeService.getLocaleTextFunc(),r=e("thousandSeparator",","),s=e("decimalSeparator",".");n.setValue(Gv._.formatNumberTwoDecimalPlacesAndCommas(t,r,s)),n.setDisplayed(i)}else null==(r=this.getAggregationValueComponent(e))||r.setDisplayed(!1)}getAllowedAggregationValueComponent(e){const{aggFuncs:t}=this.params;return!t||t.includes(e)?this.getAggregationValueComponent(e):null}getAggregationValueComponent(e){return this[`${e}AggregationComp`]}onRangeSelectionChanged(){var e;const t=null==(e=this.rangeService)?void 0:e.getCellRanges();let i=0,r=0,n=0,s=null,o=null;const a={};if(t&&!Gv._.missingOrEmpty(t)&&this.rangeService)for(let e=0;e<t.length;e++){const l=t[e];let c=this.rangeService.getRangeStartRow(l);const u=this.rangeService.getRangeEndRow(l);for(;!Gv._.missing(c)&&c&&!this.rowPositionUtils.before(u,c)&&c&&l.columns;)l.columns.forEach(e=>{if(null===c)return;const t=this.cellPositionUtils.createId({rowPinned:c.rowPinned,column:e,rowIndex:c.rowIndex});if(a[t])return;a[t]=!0;const l=this.rowPositionUtils.getRowNode(c);if(Gv._.missing(l))return;let u=this.valueService.getValue(e,l);Gv._.missing(u)||""===u||(r++,"object"==typeof u&&"value"in u&&(u=u.value,""===u)||("string"==typeof u&&(u=Number(u)),"number"!=typeof u||isNaN(u)||(i+=u,(null===o||u>o)&&(o=u),(null===s||u<s)&&(s=u),n++)))}),c=this.cellNavigationService.getRowBelow(c)}const l=r>1,c=n>1;this.setAggregationComponentValue("count",r,l),this.setAggregationComponentValue("sum",i,c),this.setAggregationComponentValue("min",s,c),this.setAggregationComponentValue("max",o,c),this.setAggregationComponentValue("avg",i/n,c)}};Vv.TEMPLATE='<div class="ag-status-panel ag-status-panel-aggregations">\n            <ag-name-value ref="avgAggregationComp"></ag-name-value>\n            <ag-name-value ref="countAggregationComp"></ag-name-value>\n            <ag-name-value ref="minAggregationComp"></ag-name-value>\n            <ag-name-value ref="maxAggregationComp"></ag-name-value>\n            <ag-name-value ref="sumAggregationComp"></ag-name-value>\n        </div>',h([(0,Gv.Optional)("rangeService")],Vv.prototype,"rangeService",2),h([(0,Gv.Autowired)("valueService")],Vv.prototype,"valueService",2),h([(0,Gv.Autowired)("cellNavigationService")],Vv.prototype,"cellNavigationService",2),h([(0,Gv.Autowired)("rowModel")],Vv.prototype,"rowModel",2),h([(0,Gv.Autowired)("cellPositionUtils")],Vv.prototype,"cellPositionUtils",2),h([(0,Gv.Autowired)("rowPositionUtils")],Vv.prototype,"rowPositionUtils",2),h([(0,Gv.RefSelector)("sumAggregationComp")],Vv.prototype,"sumAggregationComp",2),h([(0,Gv.RefSelector)("countAggregationComp")],Vv.prototype,"countAggregationComp",2),h([(0,Gv.RefSelector)("minAggregationComp")],Vv.prototype,"minAggregationComp",2),h([(0,Gv.RefSelector)("maxAggregationComp")],Vv.prototype,"maxAggregationComp",2),h([(0,Gv.RefSelector)("avgAggregationComp")],Vv.prototype,"avgAggregationComp",2),h([Gv.PostConstruct],Vv.prototype,"postConstruct",1);var Hv=Vv,Bv={version:"31.3.4",moduleName:Sv.ModuleNames.StatusBarModule,beans:[Ev],agStackComponents:[{componentName:"AgStatusBar",componentClass:Mv},{componentName:"AgNameValue",componentClass:Pv}],userComponents:[{componentName:"agAggregationComponent",componentClass:Hv},{componentName:"agSelectedRowCountComponent",componentClass:kv},{componentName:"agTotalRowCountComponent",componentClass:Ov},{componentName:"agFilteredRowCountComponent",componentClass:Lv},{componentName:"agTotalAndFilteredRowCountComponent",componentClass:Dv}],dependantModules:[_]},zv=i(98092),Uv=i(98092),Wv=Object.defineProperty,jv=Object.getOwnPropertyDescriptor,Kv=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?jv(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Wv(t,i,s),s},$v=class extends Uv.BeanStub{constructor(){super(...arguments),this.firstRow=-1,this.lastRow=-1,this.rowCount=-1,this.rowNodesByIndex={}}ensureRowHeightsValid(e,t,i,r){return!1}init(){this.rowHeight=this.gos.getRowHeightAsNumber(),this.addManagedListener(this.eventService,Uv.Events.EVENT_VIEWPORT_CHANGED,this.onViewportChanged.bind(this)),this.addManagedPropertyListener("viewportDatasource",()=>this.updateDatasource()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=this.gos.getRowHeightAsNumber(),this.updateRowHeights()})}start(){this.updateDatasource()}isLastRowIndexKnown(){return!0}destroyDatasource(){this.viewportDatasource&&(this.viewportDatasource.destroy&&this.viewportDatasource.destroy(),this.rowRenderer.datasourceChanged(),this.firstRow=-1,this.lastRow=-1)}updateDatasource(){const e=this.gos.get("viewportDatasource");e&&this.setViewportDatasource(e)}getViewportRowModelPageSize(){return this.gos.get("viewportRowModelPageSize")}getViewportRowModelBufferSize(){return this.gos.get("viewportRowModelBufferSize")}calculateFirstRow(e){const t=this.getViewportRowModelBufferSize(),i=this.getViewportRowModelPageSize(),r=e-t;return r<0?0:Math.floor(r/i)*i}calculateLastRow(e){if(-1===e)return e;const t=this.getViewportRowModelBufferSize(),i=this.getViewportRowModelPageSize(),r=e+t,n=Math.ceil(r/i)*i,s=this.rowCount-1;return Math.min(n,s)}onViewportChanged(e){const t=this.calculateFirstRow(e.firstRow),i=this.calculateLastRow(e.lastRow);this.firstRow===t&&this.lastRow===i||(this.firstRow=t,this.lastRow=i,this.purgeRowsNotInViewport(),this.viewportDatasource&&this.viewportDatasource.setViewportRange(this.firstRow,this.lastRow))}purgeRowsNotInViewport(){Object.keys(this.rowNodesByIndex).forEach(e=>{const t=parseInt(e,10);if(t<this.firstRow||t>this.lastRow){if(this.isRowFocused(t))return;delete this.rowNodesByIndex[t]}})}isRowFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();return!!t&&(null==t.rowPinned&&t.rowIndex===e)}setViewportDatasource(e){this.destroyDatasource(),this.viewportDatasource=e,this.rowCount=-1,e.init?e.init({setRowCount:this.setRowCount.bind(this),setRowData:this.setRowData.bind(this),getRow:this.getRow.bind(this)}):console.warn("AG Grid: viewport is missing init method.")}getType(){return"viewport"}getRow(e){return this.rowNodesByIndex[e]||(this.rowNodesByIndex[e]=this.createBlankRowNode(e)),this.rowNodesByIndex[e]}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}getRowCount(){return-1===this.rowCount?0:this.rowCount}getRowIndexAtPixel(e){return 0!==this.rowHeight?Math.floor(e/this.rowHeight):0}getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)});const e={type:Uv.Events.EVENT_MODEL_UPDATED,newData:!1,newPage:!1,keepRenderedRows:!0,animate:!1};this.eventService.dispatchEvent(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}isEmpty(){return this.rowCount>0}isRowsToRender(){return this.rowCount>0}getNodesInRangeForSelection(e,t){const i=Uv._.missing(e)?0:e.rowIndex,r=t.rowIndex,n=i<this.firstRow||i>this.lastRow,s=r<this.firstRow||r>this.lastRow;if(n||s)return[];const o=[],a=i<=r?r:i;for(let e=i<=r?i:r;e<=a;e++)o.push(this.rowNodesByIndex[e]);return o}forEachNode(e){let t=0;Object.keys(this.rowNodesByIndex).forEach(i=>{const r=parseInt(i,10),n=this.rowNodesByIndex[r];e(n,t),t++})}setRowData(e){Uv._.iterateObject(e,(e,t)=>{const i=parseInt(e,10);if(i>=this.firstRow&&i<=this.lastRow){let e=this.rowNodesByIndex[i];Uv._.missing(e)&&(e=this.createBlankRowNode(i),this.rowNodesByIndex[i]=e),e.setDataAndId(t,i.toString())}})}createBlankRowNode(e){const t=new Uv.RowNode(this.beans);return t.setRowHeight(this.rowHeight),t.setRowTop(this.rowHeight*e),t.setRowIndex(e),t}setRowCount(e,t=!1){if(e===this.rowCount)return;this.rowCount=e,this.eventService.dispatchEventOnce({type:Uv.Events.EVENT_ROW_COUNT_READY});const i={type:Uv.Events.EVENT_MODEL_UPDATED,newData:!1,newPage:!1,keepRenderedRows:t,animate:!1};this.eventService.dispatchEvent(i)}isRowPresent(e){return!!this.getRowNode(e.id)}};Kv([(0,Uv.Autowired)("rowRenderer")],$v.prototype,"rowRenderer",2),Kv([(0,Uv.Autowired)("focusService")],$v.prototype,"focusService",2),Kv([(0,Uv.Autowired)("beans")],$v.prototype,"beans",2),Kv([Uv.PostConstruct],$v.prototype,"init",1),Kv([Uv.PreDestroy],$v.prototype,"destroyDatasource",1),$v=Kv([(0,Uv.Bean)("rowModel")],$v);var qv={version:"31.3.4",moduleName:zv.ModuleNames.ViewportRowModelModule,rowModel:"viewport",beans:[$v],dependantModules:[_]},Yv=i(98092),Qv=i(98092),Xv=i(98092),Zv=i(98092),Jv=i(98092),eC=i(98092),tC=i(98092),iC=i(98092),rC=i(98092),nC=i(98092),sC=i(98092),oC=i(98092),aC=i(98092),lC=i(98092),cC=i(98092),uC=i(98092),hC=i(98092),dC=i(98092),pC=i(98092),gC=i(98092),fC=i(98092),mC=i(98092),vC=i(98092),CC=i(98092),yC=i(98092),wC=i(98092),SC=i(98092),bC=i(98092),EC=i(98092),AC=i(98092),TC=i(98092),MC=i(98092),RC=i(98092),_C=i(98092),PC=i(98092),xC=i(98092),DC=i(98092),IC=i(98092),LC=i(98092),NC=i(98092),OC=i(98092),FC=i(98092),kC=i(98092),GC=i(98092),VC=i(98092),HC=i(98092),BC=i(98092),zC=i(98092),UC=i(98092),WC=i(98092),jC=i(98092),KC=i(98092),$C=i(98092),qC=i(98092),YC=i(98092),QC=i(98092),XC=i(98092),ZC=i(98092),JC=i(98092),ey=i(98092),ty=i(98092),iy=i(98092),ry=i(98092),ny=i(98092),sy=i(98092),oy=i(98092),ay=i(98092),ly=i(98092),cy=i(98092),uy=i(98092),hy=i(98092),dy=i(98092),py=i(98092),gy=i(98092),fy=i(98092),my=i(98092),vy=i(98092),Cy=i(98092),yy=i(98092),wy=i(98092),Sy=i(98092),by=i(98092),Ey=i(98092),Ay=i(98092),Ty=i(98092),My=i(98092),Ry=i(98092),_y=i(98092),Py=i(98092),xy=i(98092),Dy=i(98092),Iy=i(98092),Ly=i(98092),Ny=i(98092),Oy=i(98092),Fy=i(98092),ky=i(98092),Gy=i(98092),Vy=i(98092),Hy=i(98092),By=i(98092),zy=i(98092),Uy=i(98092),Wy=i(98092),jy=i(98092),Ky=i(98092),$y=i(98092),qy=i(98092),Yy=i(98092),Qy=i(98092),Xy=i(98092),Zy=i(98092),Jy=i(98092),ew=i(98092),tw=i(98092),iw=i(98092),rw=i(98092),nw=i(98092),sw=i(98092),ow=i(98092),aw=i(98092),lw=i(98092),cw=i(98092),uw=i(98092),hw=i(98092),dw=i(98092),pw=i(98092),gw=i(98092),fw=i(98092),mw=i(98092),vw=i(98092),Cw=i(98092),yw=i(98092),ww=i(98092),Sw=i(98092),bw=i(98092),Ew=i(98092),Aw=i(98092),Tw=i(98092),Mw=i(98092),Rw=i(98092),_w=i(98092),Pw=i(98092),xw=i(98092),Dw=i(98092),Iw=i(98092),Lw=i(98092),Nw=i(98092),Ow=i(98092),Fw=i(98092),kw=i(98092),Gw=i(98092),Vw=i(98092),Hw=i(98092),Bw=i(98092),zw=i(98092),Uw=i(98092),Ww=i(98092),jw=i(98092),Kw=i(98092),$w=i(98092),qw=i(98092),Yw=i(98092),Qw=i(98092),Xw=i(98092),Zw=i(98092),Jw=i(98092),eS=i(98092),tS=i(98092),iS=i(98092),rS=i(98092),nS=i(98092),sS=i(98092),oS=i(98092),aS=i(98092),lS=i(98092),cS=i(98092),uS=i(98092),hS=i(98092),dS=i(98092),pS=i(98092),gS=i(98092),fS=i(98092),mS=i(98092),vS=i(98092),CS=i(98092),yS=i(98092),wS=i(98092),SS=i(98092),bS=i(98092),ES=i(98092),AS=i(98092),TS=i(98092);u(d,Ge,e.exports),p.ModuleRegistry.__registerModules([g.ClientSideRowModelModule,f.InfiniteRowModelModule,m.CsvExportModule,ke,Ja,pl,Ou,jd,fp,Pp,cg,Rg,ht,Dg,Cc,_f,im,Xc,wv,Bv,qv],!1,void 0)},19270(e,t,i){"use strict";var r,n=Object.create,s=Object.defineProperty,o=Object.defineProperties,a=Object.getOwnPropertyDescriptor,l=Object.getOwnPropertyDescriptors,c=Object.getOwnPropertyNames,u=Object.getOwnPropertySymbols,h=Object.getPrototypeOf,d=Object.prototype.hasOwnProperty,p=Object.prototype.propertyIsEnumerable,g=(e,t,i)=>t in e?s(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,f=(e,t)=>{for(var i in t||(t={}))d.call(t,i)&&g(e,i,t[i]);if(u)for(var i of u(t))p.call(t,i)&&g(e,i,t[i]);return e},m=(e,t)=>o(e,l(t)),v=(e,t,i,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of c(t))d.call(e,n)||n===i||s(e,n,{get:()=>t[n],enumerable:!(r=a(t,n))||r.enumerable});return e},C=(e,t,i)=>(i=null!=e?n(h(e)):{},v(!t&&e&&e.__esModule?i:s(i,"default",{value:e,enumerable:!0}),e)),y={};((e,t)=>{for(var i in t)s(e,i,{get:t[i],enumerable:!0})})(y,{AgGridReact:()=>ut,ChangeDetectionStrategyType:()=>ht,getInstance:()=>_e,useGridCellEditor:()=>gt,useGridDate:()=>ft,useGridFilter:()=>mt,useGridFloatingFilter:()=>vt,useGridMenuItem:()=>Ct,warnReactiveCustomComponents:()=>Pe}),e.exports=(r=y,v(s({},"__esModule",{value:!0}),r));var w=C(i(22155)),S=i(98092),b=C(i(22155)),E=i(98092),A=C(i(22155)),T=(0,i(22155).createContext)({setMethods:()=>{}}),M=(0,A.memo)(e=>{const{initialProps:t,addUpdateCallback:i,CustomComponentClass:r,setMethods:n}=e,[s,o]=(0,A.useState)(t);return(0,A.useEffect)(()=>{i(e=>o(e))},[]),A.default.createElement(T.Provider,{value:{setMethods:n}},A.default.createElement(r,f({},s)))}),R=i(22155),_=i(98092),P=0;function x(){return"agPortalKey_"+ ++P}var D=i(70316),I=i(32431),L=class{constructor(e,t,i,r){this.portal=null,this.oldPortal=null,this.reactComponent=e,this.portalManager=t,this.componentType=i,this.suppressFallbackMethods=!!r,this.statelessComponent=this.isStateless(this.reactComponent),this.key=x(),this.portalKey=x(),this.instanceCreated=this.isStatelessComponent()?_.AgPromise.resolve(!1):new _.AgPromise(e=>{this.resolveInstanceCreated=e})}getGui(){return this.eParentElement}getRootElement(){return this.eParentElement.firstChild}destroy(){return this.componentInstance&&"function"==typeof this.componentInstance.destroy&&this.componentInstance.destroy(),this.portalManager.destroyPortal(this.portal)}createParentElement(e){const t=this.portalManager.getComponentWrappingElement(),i=document.createElement(t||"div");return i.classList.add("ag-react-container"),e.reactContainer=i,i}addParentContainerStyleAndClasses(){this.componentInstance&&(this.componentInstance.getReactContainerStyle&&this.componentInstance.getReactContainerStyle()&&(_._.warnOnce('Since v31.1 "getReactContainerStyle" is deprecated. Apply styling directly to ".ag-react-container" if needed.'),Object.assign(this.eParentElement.style,this.componentInstance.getReactContainerStyle())),this.componentInstance.getReactContainerClasses&&this.componentInstance.getReactContainerClasses())&&(_._.warnOnce('Since v31.1 "getReactContainerClasses" is deprecated. Apply styling directly to ".ag-react-container" if needed.'),this.componentInstance.getReactContainerClasses().forEach(e=>this.eParentElement.classList.add(e)))}statelessComponentRendered(){return this.eParentElement.childElementCount>0||this.eParentElement.childNodes.length>0}getFrameworkComponentInstance(){return this.componentInstance}isStatelessComponent(){return this.statelessComponent}getReactComponentName(){return this.reactComponent.name}getMemoType(){return this.hasSymbol()?Symbol.for("react.memo"):60115}hasSymbol(){return"function"==typeof Symbol&&Symbol.for}isStateless(e){return"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===this.getMemoType()}hasMethod(e){const t=this.getFrameworkComponentInstance();return!!t&&null!=t[e]||this.fallbackMethodAvailable(e)}callMethod(e,t){const i=this.getFrameworkComponentInstance();if(this.isStatelessComponent())return this.fallbackMethod(e,t&&t[0]?t[0]:{});if(!i)return void setTimeout(()=>this.callMethod(e,t));const r=i[e];return r?r.apply(i,t):this.fallbackMethodAvailable(e)?this.fallbackMethod(e,t&&t[0]?t[0]:{}):void 0}addMethod(e,t){this[e]=t}init(e){return this.eParentElement=this.createParentElement(e),this.params=e,this.createOrUpdatePortal(e),new _.AgPromise(e=>this.createReactComponent(e))}createOrUpdatePortal(e){this.isStatelessComponent()||(this.ref=e=>{var t;this.componentInstance=e,this.addParentContainerStyleAndClasses(),null==(t=this.resolveInstanceCreated)||t.call(this,!0),this.resolveInstanceCreated=void 0},e.ref=this.ref),this.reactElement=this.createElement(this.reactComponent,m(f({},e),{key:this.key})),this.portal=(0,D.createPortal)(this.reactElement,this.eParentElement,this.portalKey)}createElement(e,t){return(0,R.createElement)(e,t)}createReactComponent(e){this.portalManager.mountReactPortal(this.portal,this,t=>{e(t)})}isNullValue(){return this.valueRenderedIsNull(this.params)}rendered(){return this.isStatelessComponent()&&this.statelessComponentRendered()||!(this.isStatelessComponent()||!this.getFrameworkComponentInstance())}valueRenderedIsNull(e){if(!this.componentType.cellRenderer)return!1;const t=console.error;try{return console.error=()=>{},""===(0,I.renderToStaticMarkup)((0,R.createElement)(this.reactComponent,e))}catch(e){}finally{console.error=t}return!1}refreshComponent(e){this.oldPortal=this.portal,this.createOrUpdatePortal(e),this.portalManager.updateReactPortal(this.oldPortal,this.portal)}fallbackMethod(e,t){const i=this[`${e}Component`];if(!this.suppressFallbackMethods&&i)return i.bind(this)(t)}fallbackMethodAvailable(e){return!this.suppressFallbackMethods&&!!this[`${e}Component`]}};function N(e,t,i){e.forEach(e=>{const r=t[e];r&&(i[e]=r)})}var O=class extends L{constructor(){super(...arguments),this.awaitUpdateCallback=new E.AgPromise(e=>{this.resolveUpdateCallback=e}),this.wrapperComponent=M}init(e){return this.sourceParams=e,super.init(this.getProps())}addMethod(){}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}getFrameworkComponentInstance(){return this}createElement(e,t){return super.createElement(this.wrapperComponent,{initialProps:t,CustomComponentClass:e,setMethods:e=>this.setMethods(e),addUpdateCallback:e=>{this.updateCallback=()=>(e(this.getProps()),new E.AgPromise(e=>{setTimeout(()=>{e()})})),this.resolveUpdateCallback()}})}setMethods(e){this.providedMethods=e,N(this.getOptionalMethods(),this.providedMethods,this)}getOptionalMethods(){return[]}getProps(){return m(f({},this.sourceParams),{key:this.key,ref:this.ref})}refreshProps(){return this.updateCallback?this.updateCallback():new E.AgPromise(e=>this.awaitUpdateCallback.then(()=>{this.updateCallback().then(()=>e())}))}},F=class extends O{constructor(){super(...arguments),this.date=null,this.onDateChange=e=>this.updateDate(e)}getDate(){return this.date}setDate(e){this.date=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled"]}updateDate(e){this.setDate(e),this.sourceParams.onDateChanged()}getProps(){const e=super.getProps();return e.date=this.date,e.onDateChange=this.onDateChange,delete e.onDateChanged,e}},k=class extends O{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e),this.onUiChange=()=>this.sourceParams.filterChangedCallback()}isFilterActive(){return null!=this.model}doesFilterPass(e){return this.providedMethods.doesFilterPass(e)}getModel(){return this.model}setModel(e){return this.model=e,this.refreshProps()}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getOptionalMethods(){return["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onAnyFilterChanged"]}updateModel(e){this.setModel(e).then(()=>this.sourceParams.filterChangedCallback())}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e.onUiChange=this.onUiChange,delete e.filterChangedCallback,delete e.filterModifiedCallback,delete e.valueGetter,e}},G=i(98092);function V(e,t){e.parentFilterInstance(i=>{(i.setModel(t)||G.AgPromise.resolve()).then(()=>{e.filterParams.filterChangedCallback()})})}var H=class{constructor(e,t){this.floatingFilterParams=e,this.refreshProps=t,this.model=null,this.onModelChange=e=>this.updateModel(e)}getProps(){return m(f({},this.floatingFilterParams),{model:this.model,onModelChange:this.onModelChange})}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.floatingFilterParams=e,this.refreshProps()}setMethods(e){N(this.getOptionalMethods(),e,this)}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),V(this.floatingFilterParams,e)}},B=class extends O{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e)}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),V(this.sourceParams,e)}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e}},z=class extends O{refresh(e){this.sourceParams=e,this.refreshProps()}},U=class extends O{constructor(){super(...arguments),this.active=!1,this.expanded=!1,this.onActiveChange=e=>this.updateActive(e)}setActive(e){this.awaitSetActive(e)}setExpanded(e){this.expanded=e,this.refreshProps()}getOptionalMethods(){return["select","configureDefaults"]}awaitSetActive(e){return this.active=e,this.refreshProps()}updateActive(e){const t=this.awaitSetActive(e);e&&t.then(()=>this.sourceParams.onItemActivated())}getProps(){const e=super.getProps();return e.active=this.active,e.expanded=this.expanded,e.onActiveChange=this.onActiveChange,delete e.onItemActivated,e}},W=class extends O{refresh(e){this.sourceParams=e,this.refreshProps()}},j=class extends O{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},K=class extends O{constructor(){super(...arguments),this.onStateChange=e=>this.updateState(e)}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getState(){return this.state}updateState(e){this.state=e,this.refreshProps(),this.sourceParams.onStateUpdated()}getProps(){const e=super.getProps();return e.state=this.state,e.onStateChange=this.onStateChange,e}},$=class e{constructor(t,i,r){this.destroyed=!1,this.portals=[],this.hasPendingPortalUpdate=!1,this.wrappingElement=i||"div",this.refresher=t,this.maxComponentCreationTimeMs=r||e.MAX_COMPONENT_CREATION_TIME_IN_MS}getPortals(){return this.portals}destroy(){this.destroyed=!0}destroyPortal(e){this.portals=this.portals.filter(t=>t!==e),this.batchUpdate()}getComponentWrappingElement(){return this.wrappingElement}mountReactPortal(e,t,i){this.portals=[...this.portals,e],this.waitForInstance(t,i),this.batchUpdate()}updateReactPortal(e,t){this.portals[this.portals.indexOf(e)]=t,this.batchUpdate()}batchUpdate(){this.hasPendingPortalUpdate||(setTimeout(()=>{this.destroyed||(this.refresher(),this.hasPendingPortalUpdate=!1)}),this.hasPendingPortalUpdate=!0)}waitForInstance(e,t,i=Date.now()){if(this.destroyed)t(null);else if(e.rendered())t(e);else{if(Date.now()-i>=this.maxComponentCreationTimeMs&&!this.hasPendingPortalUpdate)return e.isNullValue()?void t(e):(console.error(`AG Grid: React Component '${e.getReactComponentName()}' not created within ${this.maxComponentCreationTimeMs}ms.`),void console.error("    If the component is using `forwardRef` but not `useImperativeHandle`, add the following: `useImperativeHandle(ref, () => ({}));`"));window.setTimeout(()=>{this.waitForInstance(e,t,i)})}}};$.MAX_COMPONENT_CREATION_TIME_IN_MS=1e3;var q=$,Y=C(i(22155)).default.createContext({}),Q=C(i(70316)),X=(...e)=>e.filter(e=>null!=e&&""!==e).join(" "),Z=class e{constructor(...e){this.classesMap={},e.forEach(e=>{this.classesMap[e]=!0})}setClass(t,i){if(!!this.classesMap[t]==i)return this;const r=new e;return r.classesMap=f({},this.classesMap),r.classesMap[t]=i,r}toString(){return Object.keys(this.classesMap).filter(e=>this.classesMap[e]).join(" ")}},J=e=>"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===("function"==typeof Symbol&&Symbol.for?Symbol.for("react.memo"):60115),ee=null!=Q.default.createRoot&&null!=Q.default.flushSync,te=!1,ie=(e,t)=>{ee&&e&&!te?Q.default.flushSync(t):t()};function re(e,t,i){if(null==t||null==e)return t;if(e===t||0===t.length&&0===e.length)return e;if(i||0===e.length&&t.length>0||e.length>0&&0===t.length)return t;const r=[],n=[],s=new Map,o=new Map;for(let e=0;e<t.length;e++){const i=t[e];o.set(i.getInstanceId(),i)}for(let t=0;t<e.length;t++){const i=e[t];s.set(i.getInstanceId(),i),o.has(i.getInstanceId())&&r.push(i)}for(let e=0;e<t.length;e++){const i=t[e],r=i.getInstanceId();s.has(r)||n.push(i)}return r.length===e.length&&0===n.length?e:0===r.length&&n.length===t.length?t:0===r.length?n:0===n.length?r:[...r,...n]}var ne=i(98092),se=C(i(22155)),oe=(e,t,i,r)=>{if(!e||e.componentFromFramework||t.isDestroyed())return;const n=e.newAgStackInstance();if(!n)return;let s,o,a=!1;return n.then(e=>{a?t.destroyBean(e):(s=e,o=s.getGui(),i.appendChild(o),ae(r,s))}),()=>{a=!0,s&&(o&&o.parentElement&&o.parentElement.removeChild(o),t.destroyBean(s),r&&ae(r,void 0))}},ae=(e,t)=>{e&&(e instanceof Function?e(t):e.current=t)},le=(0,se.forwardRef)((e,t)=>{var i;const r=(0,se.useContext)(Y).context,n=(0,se.useRef)(null),s=(0,se.useRef)(null),o=(0,se.useRef)(null),a=(0,se.useRef)(null),l=(0,se.useRef)(null),c=(0,se.useRef)(),[u,h]=(0,se.useState)(),[d,p]=(0,se.useState)(),[g,m]=(0,se.useState)(),[v,C]=(0,se.useState)(()=>new Z),[y,w]=(0,se.useState)(()=>new Z("ag-hidden")),[S,b]=(0,se.useState)(()=>new Z("ag-hidden")),[E,A]=(0,se.useState)(()=>new Z("ag-invisible"));(0,se.useImperativeHandle)(t,()=>({refresh:()=>!1})),(0,se.useLayoutEffect)(()=>oe(u,r,s.current),[u]);const T=(0,se.useCallback)(t=>{if(n.current=t,!n.current)return r.destroyBean(c.current),void(c.current=null);const i={setInnerRenderer:(e,t)=>{h(e),m(t)},setChildCount:e=>p(e),addOrRemoveCssClass:(e,t)=>C(i=>i.setClass(e,t)),setContractedDisplayed:e=>b(t=>t.setClass("ag-hidden",!e)),setExpandedDisplayed:e=>w(t=>t.setClass("ag-hidden",!e)),setCheckboxVisible:e=>A(t=>t.setClass("ag-invisible",!e))};c.current=r.createBean(new ne.GroupCellRendererCtrl),c.current.init(i,n.current,o.current,a.current,l.current,le,e)},[]),M=(0,se.useMemo)(()=>`ag-cell-wrapper ${v.toString()}`,[v]),R=(0,se.useMemo)(()=>`ag-group-expanded ${y.toString()}`,[y]),_=(0,se.useMemo)(()=>`ag-group-contracted ${S.toString()}`,[S]),P=(0,se.useMemo)(()=>`ag-group-checkbox ${E.toString()}`,[E]),x=u&&u.componentFromFramework,D=x?u.componentClass:void 0,I=null==u&&null!=g,L=ne._.escapeString(g,!0);return se.default.createElement("span",f({className:M,ref:T},e.colDef?{}:{role:null==(i=c.current)?void 0:i.getCellAriaRole()}),se.default.createElement("span",{className:R,ref:a}),se.default.createElement("span",{className:_,ref:l}),se.default.createElement("span",{className:P,ref:o}),se.default.createElement("span",{className:"ag-group-value",ref:s},I&&se.default.createElement(se.default.Fragment,null,L),x&&se.default.createElement(D,f({},u.params))),se.default.createElement("span",{className:"ag-group-child-count"},d))}),ce=le,ue=i(98092),he=C(i(22155)),de=i(98092),pe=C(i(22155)),ge=C(i(22155)),fe=i(98092),me=C(i(22155)),ve=i(98092),Ce=i(98092),ye=C(i(22155)),we=C(i(22155)),Se=i(98092),be=(0,we.memo)(e=>{const{ctrl:t}=e,i=t.isAlive(),{context:r}=(0,we.useContext)(Y),n=i?t.getColId():void 0,[s,o]=(0,we.useState)(),a=(0,we.useRef)(null),l=(0,we.useRef)(null),c=(0,we.useRef)(null),u=(0,we.useRef)();let h=(0,we.useRef)();i&&!h.current&&(h.current=new Se.CssClassManager(()=>a.current));const d=(0,we.useCallback)(e=>{var r;if(a.current=e,!a.current||!i)return;const n={setWidth:e=>{a.current&&(a.current.style.width=e)},addOrRemoveCssClass:(e,t)=>h.current.addOrRemoveCssClass(e,t),setAriaSort:e=>{a.current&&(e?Se._.setAriaSort(a.current,e):Se._.removeAriaSort(a.current))},setUserCompDetails:e=>o(e),getUserCompInstance:()=>u.current||void 0};t.setComp(n,a.current,l.current,c.current);const s=t.getSelectAllGui();null==(r=l.current)||r.insertAdjacentElement("afterend",s)},[]);(0,we.useLayoutEffect)(()=>oe(s,r,c.current,u),[s]),(0,we.useEffect)(()=>{t.setDragSource(a.current)},[s]);const p=(0,we.useMemo)(()=>!(!(null==s?void 0:s.componentFromFramework)||!J(s.componentClass)),[s]),g=s&&s.componentFromFramework,v=s&&s.componentClass;return we.default.createElement("div",{ref:d,className:"ag-header-cell","col-id":n,role:"columnheader"},we.default.createElement("div",{ref:l,className:"ag-header-cell-resize",role:"presentation"}),we.default.createElement("div",{ref:c,className:"ag-header-cell-comp-wrapper",role:"presentation"},g&&p&&we.default.createElement(v,f({},s.params)),g&&!p&&we.default.createElement(v,m(f({},s.params),{ref:u}))))}),Ee=C(i(22155)),Ae=(0,Ee.memo)(e=>{const{context:t}=(0,Ee.useContext)(Y),{ctrl:i}=e,[r,n]=(0,Ee.useState)(()=>new Z),[s,o]=(0,Ee.useState)(()=>new Z),[a,l]=(0,Ee.useState)("false"),[c,u]=(0,Ee.useState)(),[h,d]=(0,Ee.useState)(),p=(0,Ee.useMemo)(()=>i.getColId(),[]),g=(0,Ee.useRef)(null),v=(0,Ee.useRef)(null),C=(0,Ee.useRef)(),y=(0,Ee.useCallback)(e=>{if(g.current=e,!g.current)return;const t={setWidth:e=>{g.current&&(g.current.style.width=e)},addOrRemoveCssClass:(e,t)=>n(i=>i.setClass(e,t)),setUserCompDetails:e=>d(e),setResizableDisplayed:e=>{o(t=>t.setClass("ag-hidden",!e)),l(e?"false":"true")},setAriaExpanded:e=>u(e),getUserCompInstance:()=>C.current||void 0};i.setComp(t,g.current,v.current)},[]);(0,Ee.useLayoutEffect)(()=>oe(h,t,g.current),[h]),(0,Ee.useEffect)(()=>{g.current&&i.setDragSource(g.current)},[h]);const w=(0,Ee.useMemo)(()=>!(!(null==h?void 0:h.componentFromFramework)||!J(h.componentClass)),[h]),S=(0,Ee.useMemo)(()=>"ag-header-group-cell "+r.toString(),[r]),b=(0,Ee.useMemo)(()=>"ag-header-cell-resize "+s.toString(),[s]),E=h&&h.componentFromFramework,A=h&&h.componentClass;return Ee.default.createElement("div",{ref:y,className:S,"col-id":p,role:"columnheader","aria-expanded":c},E&&w&&Ee.default.createElement(A,f({},h.params)),E&&!w&&Ee.default.createElement(A,m(f({},h.params),{ref:C})),Ee.default.createElement("div",{ref:v,"aria-hidden":a,className:b}))}),Te=C(i(22155)),Me=i(98092),Re=i(98092);function _e(e,t){var i,r;(null!=(r=null==(i=null==e?void 0:e.getInstance)?void 0:i.call(e))?r:Re.AgPromise.resolve(void 0)).then(e=>t(e))}function Pe(){Re._.warnOnce("Using custom components without `reactiveCustomComponents = true` is deprecated.")}var xe=(0,Te.memo)(e=>{const{context:t,gos:i}=(0,Te.useContext)(Y),[r,n]=(0,Te.useState)(()=>new Z("ag-header-cell","ag-floating-filter")),[s,o]=(0,Te.useState)(()=>new Z),[a,l]=(0,Te.useState)(()=>new Z("ag-floating-filter-button","ag-hidden")),[c,u]=(0,Te.useState)("false"),[h,d]=(0,Te.useState)(),[p,g]=(0,Te.useState)(1),v=(0,Te.useRef)(null),C=(0,Te.useRef)(null),y=(0,Te.useRef)(null),w=(0,Te.useRef)(null),S=(0,Te.useRef)(),b=(0,Te.useRef)(),E=e=>{null!=e&&S.current&&S.current(e)},{ctrl:A}=e,M=(0,Te.useCallback)(e=>{if(v.current=e,!v.current)return;b.current=new Me.AgPromise(e=>{S.current=e});const t={addOrRemoveCssClass:(e,t)=>n(i=>i.setClass(e,t)),addOrRemoveBodyCssClass:(e,t)=>o(i=>i.setClass(e,t)),setButtonWrapperDisplayed:e=>{l(t=>t.setClass("ag-hidden",!e)),u(e?"false":"true")},setWidth:e=>{v.current&&(v.current.style.width=e)},setCompDetails:e=>d(e),getFloatingFilterComp:()=>b.current?b.current:null,setMenuIcon:e=>{var t;return null==(t=w.current)?void 0:t.appendChild(e)}};A.setComp(t,v.current,w.current,C.current)},[]);(0,Te.useLayoutEffect)(()=>oe(h,t,C.current,E),[h]);const R=(0,Te.useMemo)(()=>r.toString(),[r]),_=(0,Te.useMemo)(()=>s.toString(),[s]),P=(0,Te.useMemo)(()=>a.toString(),[a]),x=(0,Te.useMemo)(()=>!!(h&&h.componentFromFramework&&J(h.componentClass)),[h]),D=(0,Te.useMemo)(()=>i.get("reactiveCustomComponents"),[]),I=(0,Te.useMemo)(()=>{if(h){if(D){const e=new H(h.params,()=>g(e=>e+1));return E(e),e}h.componentFromFramework&&Pe()}},[h]),L=null==I?void 0:I.getProps(),N=h&&h.componentFromFramework,O=h&&h.componentClass;return Te.default.createElement("div",{ref:M,className:R,role:"gridcell"},Te.default.createElement("div",{ref:C,className:_,role:"presentation"},N&&!D&&Te.default.createElement(O,m(f({},h.params),{ref:x?()=>{}:E})),N&&D&&Te.default.createElement(T.Provider,{value:{setMethods:e=>I.setMethods(e)}},Te.default.createElement(O,f({},L)))),Te.default.createElement("div",{ref:y,"aria-hidden":c,className:P,role:"presentation"},Te.default.createElement("button",{ref:w,type:"button",className:"ag-button ag-floating-filter-button-button",tabIndex:-1})))}),De=(0,ye.memo)(e=>{const{ctrl:t}=e,{topOffset:i,rowHeight:r}=(0,ye.useMemo)(()=>t.getTopAndHeight(),[]),n=t.getAriaRowIndex(),s=t.getHeaderRowClass(),[o,a]=(0,ye.useState)(()=>r+"px"),[l,c]=(0,ye.useState)(()=>i+"px"),u=(0,ye.useRef)(null),h=(0,ye.useRef)(null),[d,p]=(0,ye.useState)(()=>t.getHeaderCtrls()),g=(0,ye.useRef)(null),f=(0,ye.useCallback)(e=>{if(g.current=e,!e)return;const i={setHeight:e=>a(e),setTop:e=>c(e),setHeaderCtrls:(e,t,i)=>{h.current=u.current,u.current=e;const r=re(h.current,e,t);r!==h.current&&ie(i,()=>p(r))},setWidth:e=>{g.current&&(g.current.style.width=e)}};t.setComp(i,!1)},[]),m=(0,ye.useMemo)(()=>({height:o,top:l}),[o,l]),v=(0,ye.useCallback)(e=>{switch(t.getType()){case Ce.HeaderRowType.COLUMN_GROUP:return ye.default.createElement(Ae,{ctrl:e,key:e.getInstanceId()});case Ce.HeaderRowType.FLOATING_FILTER:return ye.default.createElement(xe,{ctrl:e,key:e.getInstanceId()});default:return ye.default.createElement(be,{ctrl:e,key:e.getInstanceId()})}},[]);return ye.default.createElement("div",{ref:f,className:s,role:"row",style:m,"aria-rowindex":n},d.map(v))}),Ie=(0,me.memo)(e=>{const[t,i]=(0,me.useState)(!0),[r,n]=(0,me.useState)([]),{context:s}=(0,me.useContext)(Y),o=(0,me.useRef)(null),a=(0,me.useRef)(null),l=(0,me.useRef)(null),c="left"===e.pinned,u="right"===e.pinned,h=!c&&!u,d=(0,me.useCallback)(t=>{if(o.current=t,!o.current)return s.destroyBean(l.current),void(l.current=null);const r={setDisplayed:i,setCtrls:e=>n(e),setCenterWidth:e=>{a.current&&(a.current.style.width=e)},setViewportScrollLeft:e=>{o.current&&(o.current.scrollLeft=e)},setPinnedContainerWidth:e=>{o.current&&(o.current.style.width=e,o.current.style.minWidth=e,o.current.style.maxWidth=e)}};l.current=s.createBean(new ve.HeaderRowContainerCtrl(e.pinned)),l.current.setComp(r,o.current)},[]),p=t?"":"ag-hidden",g=()=>r.map(e=>me.default.createElement(De,{ctrl:e,key:e.getInstanceId()}));return me.default.createElement(me.default.Fragment,null,c&&me.default.createElement("div",{ref:d,className:"ag-pinned-left-header "+p,"aria-hidden":!t,role:"rowgroup"},g()),u&&me.default.createElement("div",{ref:d,className:"ag-pinned-right-header "+p,"aria-hidden":!t,role:"rowgroup"},g()),h&&me.default.createElement("div",{ref:d,className:"ag-header-viewport "+p,role:"presentation"},me.default.createElement("div",{ref:a,className:"ag-header-container",role:"rowgroup"},g())))}),Le=(0,ge.memo)(()=>{const[e,t]=(0,ge.useState)(()=>new Z),[i,r]=(0,ge.useState)(),{context:n}=(0,ge.useContext)(Y),s=(0,ge.useRef)(null),o=(0,ge.useRef)(null),a=(0,ge.useCallback)(e=>{if(s.current=e,!e)return n.destroyBean(o.current),void(o.current=null);const i={addOrRemoveCssClass:(e,i)=>t(t=>t.setClass(e,i)),setHeightAndMinHeight:e=>r(e)};o.current=n.createBean(new fe.GridHeaderCtrl),o.current.setComp(i,s.current,s.current)},[]),l=(0,ge.useMemo)(()=>"ag-header "+e.toString(),[e]),c=(0,ge.useMemo)(()=>({height:i,minHeight:i}),[i]);return ge.default.createElement("div",{ref:a,className:l,style:c,role:"presentation"},ge.default.createElement(Ie,{pinned:"left"}),ge.default.createElement(Ie,{pinned:null}),ge.default.createElement(Ie,{pinned:"right"}))}),Ne=i(22155),Oe=(e,t)=>{(0,Ne.useEffect)(()=>{const i=t.current;if(i){const t=i.parentElement;if(t){const r=document.createComment(e);return t.insertBefore(r,i),()=>{t.removeChild(r)}}}},[e])},Fe=i(98092),ke=C(i(22155)),Ge=C(i(22155)),Ve=i(98092),He=i(98092),Be=C(i(22155)),ze=i(98092),Ue=C(i(22155)),We=i(70316),je=i(22155),Ke=(0,Ue.memo)(e=>{const[t,i]=(0,Ue.useState)(),{context:r,popupService:n,localeService:s,gos:o}=(0,Ue.useContext)(Y);return(()=>{const t=(0,je.useRef)(()=>{const{editDetails:t,cellCtrl:a,eParentCell:l}=e,{compDetails:c}=t,u=o.get("stopEditingWhenCellsLoseFocus"),h=r.createBean(new ze.PopupEditorWrapper(c.params)),d=h.getGui();if(e.jsChildComp){const t=e.jsChildComp.getGui();t&&d.appendChild(t)}const p={column:a.getColumn(),rowNode:a.getRowNode(),type:"popupCellEditor",eventSource:l,ePopup:d,position:t.popupPosition,keepWithinBounds:!0},g=n.positionPopupByComponent.bind(n,p),f=s.getLocaleTextFunc(),m=n.addPopup({modal:u,eChild:d,closeOnEsc:!0,closedCallback:()=>{a.onPopupEditorClosed()},anchorToElement:l,positionCallback:g,ariaLabel:f("ariaLabelCellEditor","Cell Editor")}),v=m?m.hideFunc:void 0;return i(h),e.jsChildComp&&e.jsChildComp.afterGuiAttached&&e.jsChildComp.afterGuiAttached(),()=>{null!=v&&v(),r.destroyBean(h)}}),a=(0,je.useRef)(),l=(0,je.useRef)(!1),c=(0,je.useRef)(!1),[,u]=(0,je.useState)(0);l.current&&(c.current=!0),(0,je.useEffect)(()=>(l.current||(a.current=t.current(),l.current=!0),u(e=>e+1),()=>{c.current&&a.current&&a.current()}),[])})(),Ue.default.createElement(Ue.default.Fragment,null,t&&e.wrappedContent&&(0,We.createPortal)(e.wrappedContent,t.getGui()))}),$e=i(22155),qe=i(98092),Ye=class{constructor(e,t){this.cellEditorParams=e,this.refreshProps=t,this.instanceCreated=new qe.AgPromise(e=>{this.resolveInstanceCreated=e}),this.onValueChange=e=>this.updateValue(e),this.value=e.value}getProps(){return m(f({},this.cellEditorParams),{initialValue:this.cellEditorParams.value,value:this.value,onValueChange:this.onValueChange})}getValue(){return this.value}refresh(e){this.cellEditorParams=e,this.refreshProps()}setMethods(e){N(this.getOptionalMethods(),e,this)}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}setRef(e){var t;this.componentInstance=e,null==(t=this.resolveInstanceCreated)||t.call(this),this.resolveInstanceCreated=void 0}getOptionalMethods(){return["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached"]}updateValue(e){this.value=e,this.refreshProps()}},Qe=(e,t,i)=>{const r=e.compProxy;return Be.default.createElement(Be.default.Fragment,null,!r&&Be.default.createElement(t,m(f({},e.compDetails.params),{ref:i})),r&&((e,t,i)=>{const{compProxy:r}=e;i(r);const n=r.getProps(),s=J(t);return Be.default.createElement(T.Provider,{value:{setMethods:e=>r.setMethods(e)}},s&&Be.default.createElement(t,f({},n)),!s&&Be.default.createElement(t,m(f({},n),{ref:e=>r.setRef(e)})))})(e,t,i))},Xe=(0,Be.memo)(e=>{const{context:t}=(0,Be.useContext)(Y),{cellCtrl:i,printLayout:r,editingRow:n}=e,s=i.getTabIndex(),o=i.getColumnIdSanitised(),a=i.getInstanceId(),[l,c]=(0,Be.useState)(()=>i.isCellRenderer()?void 0:{compDetails:void 0,value:i.getValueToDisplay(),force:!1}),[u,h]=(0,Be.useState)(),[d,p]=(0,Be.useState)(1),[g,v]=(0,Be.useState)(),[C,y]=(0,Be.useState)(!1),[w,S]=(0,Be.useState)(!1),[b,E]=(0,Be.useState)(!1),[A,T]=(0,Be.useState)(),M=(0,Be.useMemo)(()=>i.isForceWrapper(),[i]),R=(0,Be.useMemo)(()=>i.getCellAriaRole(),[i]),_=(0,Be.useRef)(null),P=(0,Be.useRef)(null),x=(0,Be.useRef)(),D=(0,Be.useRef)(),I=(0,Be.useRef)(),L=(0,Be.useRef)([]),N=(0,Be.useRef)(),[O,F]=(0,Be.useState)(0),k=(0,Be.useCallback)(e=>{N.current=e,F(e=>e+1)},[]),G=M||null!=l&&(C||b||w),V=(0,Be.useCallback)((e,t)=>{D.current=t,t&&(((e,t,i)=>{const r=i.getColumn();if(!e&&t.isPopup&&t.isPopup()){const e=`AG Grid: Found an issue in column ${r.getColId()}. If using React, specify an editor is a popup using colDef.cellEditorPopup=true. AG Grid React cannot depend on the editor component specifying if it's in a popup (via the isPopup() method on the editor), as React needs to know this information BEFORE the component is created.`;He._.doOnce(()=>console.warn(e),"jsEditorComp-isPopup-"+i.getColumn().getColId())}if(e&&t.getPopupPosition&&null!=t.getPopupPosition()){const e=`AG Grid: Found an issue in column ${r.getColId()}. If using React, specify an editor popup position using colDef.cellEditorPopupPosition=true. AG Grid React cannot depend on the editor component specifying it's position (via the getPopupPosition() method on the editor), as React needs to know this information BEFORE the component is created.`;He._.doOnce(()=>console.warn(e),"jsEditorComp-getPopupPosition-"+i.getColumn().getColId())}})(e,t,i),t.isCancelBeforeStart&&t.isCancelBeforeStart()&&setTimeout(()=>{i.stopEditing(!0),i.focusCell(!0)}))},[i]),H=(0,Be.useCallback)(e=>V(!0,e),[V]),B=(0,Be.useCallback)(e=>V(!1,e),[V]);let z=(0,Be.useRef)();z.current||(z.current=new He.CssClassManager(()=>_.current)),((e,t,i,r,n,s)=>{const{context:o}=(0,$e.useContext)(Y),a=(0,$e.useCallback)(()=>{const e=n.current;if(!e)return;const t=e.getGui();t&&t.parentElement&&t.parentElement.removeChild(t),o.destroyBean(e),n.current=void 0},[]);(0,$e.useEffect)(()=>{const r=null!=e,o=e&&e.compDetails&&!e.compDetails.componentFromFramework;if(!r||!o||t&&null==i)return void a();const l=e.compDetails;if(n.current){const t=n.current,i=!(null==t.refresh||0!=e.force)&&t.refresh(l.params);if(!0===i||void 0===i)return;a()}const c=l.newAgStackInstance();if(!c)return;const u=c.resolveNow(null,e=>e);if(!u)return;const h=u.getGui();h&&((t?i:s.current).appendChild(h),n.current=u)},[e,t,r]),(0,$e.useEffect)(()=>a,[])})(l,G,N.current,O,x,_);const U=(0,Be.useRef)();(0,Be.useLayoutEffect)(()=>{const e=U.current,t=l;if(U.current=l,null==e||null==e.compDetails||null==t||null==t.compDetails)return;const i=e.compDetails,r=t.compDetails;i.componentClass==r.componentClass&&null!=P.current&&null!=P.current.refresh&&1!=P.current.refresh(r.params)&&p(e=>e+1)},[l]),(0,Be.useLayoutEffect)(()=>{if(!u||u.compDetails.componentFromFramework)return;const e=u.compDetails,i=!0===u.popup,r=(e=>{const t=e.newAgStackInstance();if(t)return t.resolveNow(null,e=>e)})(e);if(!r)return;const n=r.getGui();if(V(i,r),!i){const e=(M?I:_).current;null==e||e.appendChild(n),r.afterGuiAttached&&r.afterGuiAttached()}return T(r),()=>{t.destroyBean(r),V(i,void 0),T(void 0),n&&n.parentElement&&n.parentElement.removeChild(n)}},[u]);const W=(0,Be.useCallback)(e=>{if(I.current=e,!I.current)return L.current.forEach(e=>e()),void(L.current=[]);const r=e=>{var i;if(e){const r=e.getGui();null==(i=I.current)||i.insertAdjacentElement("afterbegin",r),L.current.push(()=>{t.destroyBean(e),He._.removeFromParent(r)})}return e};C&&r(i.createSelectionCheckbox()),b&&r(i.createDndSource()),w&&r(i.createRowDragComp())},[i,t,b,w,C]),j=(0,Be.useCallback)(e=>{if(_.current=e,!_.current)return;if(!i)return;const t={addOrRemoveCssClass:(e,t)=>z.current.addOrRemoveCssClass(e,t),setUserStyles:e=>v(e),getFocusableElement:()=>_.current,setIncludeSelection:e=>y(e),setIncludeRowDrag:e=>S(e),setIncludeDndSource:e=>E(e),getCellEditor:()=>D.current||null,getCellRenderer:()=>P.current?P.current:x.current,getParentOfValue:()=>N.current?N.current:I.current?I.current:_.current,setRenderDetails:(e,t,i)=>{c(r=>(null==r?void 0:r.compDetails)!==e||(null==r?void 0:r.value)!==t||(null==r?void 0:r.force)!==i?{value:t,compDetails:e,force:i}:r)},setEditDetails:(e,t,i,r)=>{if(e){let n;r?n=new Ye(e.params,()=>p(e=>e+1)):e.componentFromFramework&&Pe(),h({compDetails:e,popup:t,popupPosition:i,compProxy:n}),t||c(void 0)}else h(e=>{(null==e?void 0:e.compProxy)&&(D.current=void 0)})}},s=I.current||void 0;i.setComp(t,_.current,s,r,n)},[]),K=(0,Be.useMemo)(()=>!!(l&&l.compDetails&&l.compDetails.componentFromFramework&&J(l.compDetails.componentClass)),[l]);(0,Be.useLayoutEffect)(()=>{var e;_.current&&(z.current.addOrRemoveCssClass("ag-cell-value",!G),z.current.addOrRemoveCssClass("ag-cell-inline-editing",!!u&&!u.popup),z.current.addOrRemoveCssClass("ag-cell-popup-editing",!!u&&!!u.popup),z.current.addOrRemoveCssClass("ag-cell-not-inline-editing",!u||!!u.popup),null==(e=i.getRowCtrl())||e.setInlineEditingCss(!!u),i.shouldRestoreFocus()&&!i.isEditing()&&_.current.focus({preventScroll:!0}))});const $=()=>Be.default.createElement(Be.default.Fragment,null,null!=l&&((e,t,i,r,n,s,o)=>{const{compDetails:a,value:l}=e,c=!a,u=a&&a.componentFromFramework,h=a&&a.componentClass,d=(null==l?void 0:l.toString)?l.toString():l,p=()=>Be.default.createElement(Be.default.Fragment,null,c&&Be.default.createElement(Be.default.Fragment,null,d),u&&!s&&Be.default.createElement(h,m(f({},a.params),{key:t,ref:r})),u&&s&&Be.default.createElement(h,m(f({},a.params),{key:t})));return Be.default.createElement(Be.default.Fragment,null,n?Be.default.createElement("span",{role:"presentation",id:`cell-${i}`,className:"ag-cell-value",ref:o},p()):p())})(l,d,a,P,G,K,k),null!=u&&((e,t,i,r,n,s)=>{const o=e.compDetails,a=o.componentClass,l=o.componentFromFramework&&!e.popup,c=o.componentFromFramework&&e.popup,u=!o.componentFromFramework&&e.popup;return Be.default.createElement(Be.default.Fragment,null,l&&Qe(e,a,t),c&&Be.default.createElement(Ke,{editDetails:e,cellCtrl:n,eParentCell:r,wrappedContent:Qe(e,a,i)}),u&&s&&Be.default.createElement(Ke,{editDetails:e,cellCtrl:n,eParentCell:r,jsChildComp:s}))})(u,B,H,_.current,i,A));return Be.default.createElement("div",{ref:j,style:g,tabIndex:s,role:R,"col-id":o},G?Be.default.createElement("div",{className:"ag-cell-wrapper",role:"presentation",ref:W},$()):$())}),Ze=(0,Ge.memo)(e=>{const{context:t,gos:i}=(0,Ge.useContext)(Y),{rowCtrl:r,containerType:n}=e,s=r.getTabIndex(),o=(0,Ge.useRef)(r.getDomOrder()),a=r.isFullWidth(),l=r.getRowNode().displayed,[c,u]=(0,Ge.useState)(()=>l?r.getRowIndex():null),[h,d]=(0,Ge.useState)(()=>r.getRowId()),[p,g]=(0,Ge.useState)(()=>r.getBusinessKey()),[v,C]=(0,Ge.useState)(()=>r.getRowStyles()),y=(0,Ge.useRef)(null),w=(0,Ge.useRef)(null),[S,b]=(0,Ge.useState)(()=>null),[E,A]=(0,Ge.useState)(),[T,M]=(0,Ge.useState)(()=>l?r.getInitialRowTop(n):void 0),[R,_]=(0,Ge.useState)(()=>l?r.getInitialTransform(n):void 0),P=(0,Ge.useRef)(null),x=(0,Ge.useRef)(),D=(0,Ge.useRef)(!1),[I,L]=(0,Ge.useState)(0);(0,Ge.useEffect)(()=>{var e;if(D.current)return;if(!E)return;if(I>10)return;const t=null==(e=P.current)?void 0:e.firstChild;t?(r.setupDetailRowAutoHeight(t),D.current=!0):L(e=>e+1)},[E,I]);let N=(0,Ge.useRef)();N.current||(N.current=new Ve.CssClassManager(()=>P.current));const O=(0,Ge.useCallback)(e=>{if(P.current=e,!P.current)return void r.unsetComp(n);if(!r.isAlive())return;const t={setTop:M,setTransform:_,addOrRemoveCssClass:(e,t)=>N.current.addOrRemoveCssClass(e,t),setDomOrder:e=>o.current=e,setRowIndex:u,setRowId:d,setRowBusinessKey:g,setUserStyles:C,setCellCtrls:(e,t)=>{w.current=y.current,y.current=e;const i=re(w.current,e,o.current);i!==w.current&&ie(t,()=>b(i))},showFullWidth:e=>A(e),getFullWidthCellRenderer:()=>x.current,refreshFullWidth:e=>H.current?(A(t=>m(f({},t),{params:e()})),!0):!(!x.current||!x.current.refresh)&&x.current.refresh(e())};r.setComp(t,P.current,n)},[]);(0,Ge.useLayoutEffect)(()=>oe(E,t,P.current,x),[E]);const F=(0,Ge.useMemo)(()=>{const e={top:T,transform:R};return Object.assign(e,v),e},[T,R,v]),k=a&&E&&E.componentFromFramework,G=!a&&null!=S,V=(0,Ge.useMemo)(()=>!(!(null==E?void 0:E.componentFromFramework)||!J(E.componentClass)),[E]),H=(0,Ge.useRef)(!1);return(0,Ge.useEffect)(()=>{H.current=V&&!!E&&!!i.get("reactiveCustomComponents")},[V,E]),Ge.default.createElement("div",{ref:O,role:"row",style:F,"row-index":c,"row-id":h,"row-business-key":p,tabIndex:s},G&&(null==S?void 0:S.map(e=>Ge.default.createElement(Xe,{cellCtrl:e,editingRow:r.isEditing(),printLayout:r.isPrintLayout(),key:e.getInstanceId()}))),k&&(()=>{const e=E.componentClass;return Ge.default.createElement(Ge.default.Fragment,null,V&&Ge.default.createElement(e,f({},E.params)),!V&&Ge.default.createElement(e,m(f({},E.params),{ref:x})))})())}),Je=(0,ke.memo)(e=>{const{context:t}=(0,ke.useContext)(Y),{name:i}=e,r=(0,ke.useMemo)(()=>(0,Fe.getRowContainerTypeForName)(i),[i]),n=(0,ke.useRef)(null),s=(0,ke.useRef)(null),o=(0,ke.useRef)([]),a=(0,ke.useRef)([]),[l,c]=(0,ke.useState)(()=>[]),u=(0,ke.useRef)(!1),h=(0,ke.useRef)(),d=(0,ke.useMemo)(()=>Fe.RowContainerCtrl.getRowContainerCssClasses(i),[i]),p=(0,ke.useMemo)(()=>X(d.viewport),[d]),g=(0,ke.useMemo)(()=>X(d.container),[d]),f=i===Fe.RowContainerName.CENTER||i===Fe.RowContainerName.TOP_CENTER||i===Fe.RowContainerName.BOTTOM_CENTER||i===Fe.RowContainerName.STICKY_TOP_CENTER||i===Fe.RowContainerName.STICKY_BOTTOM_CENTER;Oe(" AG Row Container "+i+" ",f?n:s);const m=(0,ke.useCallback)(()=>f?null!=n.current&&null!=s.current:null!=s.current,[]),v=(0,ke.useCallback)(()=>f?null==n.current&&null==s.current:null==s.current,[]),C=(0,ke.useCallback)(()=>{if(v()&&(t.destroyBean(h.current),h.current=null),m()){const e=e=>{const t=re(a.current,o.current,u.current);t!==a.current&&(a.current=t,ie(e,()=>c(t)))},r={setViewportHeight:e=>{n.current&&(n.current.style.height=e)},setRowCtrls:({rowCtrls:t,useFlushSync:i})=>{const r=!!i&&o.current.length>0&&t.length>0;o.current=t,e(r)},setDomOrder:t=>{u.current!=t&&(u.current=t,e(!1))},setContainerWidth:e=>{s.current&&(s.current.style.width=e)}};h.current=t.createBean(new Fe.RowContainerCtrl(i)),h.current.setComp(r,s.current,n.current)}},[m,v]),y=(0,ke.useCallback)(e=>{s.current=e,C()},[C]),w=(0,ke.useCallback)(e=>{n.current=e,C()},[C]),S=()=>ke.default.createElement("div",{className:g,ref:y,role:"rowgroup"},l.map(e=>ke.default.createElement(Ze,{rowCtrl:e,containerType:r,key:e.getInstanceId()})));return ke.default.createElement(ke.default.Fragment,null,f?ke.default.createElement("div",{className:p,ref:w,role:"presentation"},S()):S())}),et=(0,pe.memo)(()=>{const{context:e,agStackComponentsRegistry:t,resizeObserverService:i}=(0,pe.useContext)(Y),[r,n]=(0,pe.useState)(""),[s,o]=(0,pe.useState)(0),[a,l]=(0,pe.useState)(0),[c,u]=(0,pe.useState)("0px"),[h,d]=(0,pe.useState)("0px"),[p,g]=(0,pe.useState)("100%"),[f,m]=(0,pe.useState)("0px"),[v,C]=(0,pe.useState)("0px"),[y,w]=(0,pe.useState)("100%"),[S,b]=(0,pe.useState)(""),[E,A]=(0,pe.useState)(""),[T,M]=(0,pe.useState)(null),[R,_]=(0,pe.useState)(""),[P,x]=(0,pe.useState)(null),[D,I]=(0,pe.useState)("ag-layout-normal");let L=(0,pe.useRef)();L.current||(L.current=new de.CssClassManager(()=>N.current));const N=(0,pe.useRef)(null),O=(0,pe.useRef)(null),F=(0,pe.useRef)(null),k=(0,pe.useRef)(null),G=(0,pe.useRef)(null),V=(0,pe.useRef)(null),H=(0,pe.useRef)(null),B=(0,pe.useRef)([]),z=(0,pe.useRef)([]);Oe(" AG Grid Body ",N),Oe(" AG Pinned Top ",O),Oe(" AG Sticky Top ",F),Oe(" AG Middle ",V),Oe(" AG Pinned Bottom ",H);const U=(0,pe.useCallback)(r=>{if(N.current=r,!N.current)return e.destroyBeans(B.current),z.current.forEach(e=>e()),B.current=[],void(z.current=[]);if(!e)return;const s=i=>{const r=t.getComponentClass(i),n=e.createBean(new r);return B.current.push(n),n},a=(e,t)=>{e.appendChild(t),z.current.push(()=>e.removeChild(t))};a(N.current,document.createComment(" AG Fake Horizontal Scroll ")),a(N.current,s("AG-FAKE-HORIZONTAL-SCROLL").getGui()),a(N.current,document.createComment(" AG Overlay Wrapper ")),a(N.current,s("AG-OVERLAY-WRAPPER").getGui()),G.current&&(a(G.current,document.createComment(" AG Fake Vertical Scroll ")),a(G.current,s("AG-FAKE-VERTICAL-SCROLL").getGui()));const c={setRowAnimationCssOnBodyViewport:n,setColumnCount:e=>{N.current&&de._.setAriaColCount(N.current,e)},setRowCount:e=>{N.current&&de._.setAriaRowCount(N.current,e)},setTopHeight:o,setBottomHeight:l,setStickyTopHeight:u,setStickyTopTop:d,setStickyTopWidth:g,setTopDisplay:b,setBottomDisplay:A,setColumnMovingCss:(e,t)=>L.current.addOrRemoveCssClass(e,t),updateLayoutClasses:I,setAlwaysVerticalScrollClass:M,setPinnedTopBottomOverflowY:_,setCellSelectableCss:(e,t)=>x(t?e:null),setBodyViewportWidth:e=>{V.current&&(V.current.style.width=e)},registerBodyViewportResizeListener:e=>{if(V.current){const t=i.observeResize(V.current,e);z.current.push(()=>t())}},setStickyBottomHeight:m,setStickyBottomBottom:C,setStickyBottomWidth:w},h=e.createBean(new de.GridBodyCtrl);B.current.push(h),h.setComp(c,N.current,V.current,O.current,H.current,F.current,k.current)},[]),W=(0,pe.useMemo)(()=>X("ag-root","ag-unselectable",D),[D]),j=(0,pe.useMemo)(()=>X("ag-body-viewport",r,D,T,P),[r,D,T,P]),K=(0,pe.useMemo)(()=>X("ag-body",D),[D]),$=(0,pe.useMemo)(()=>X("ag-floating-top",P),[P]),q=(0,pe.useMemo)(()=>X("ag-sticky-top",P),[P]),Q=(0,pe.useMemo)(()=>X("ag-sticky-bottom",P),[P]),Z=(0,pe.useMemo)(()=>X("ag-floating-bottom",P),[P]),J=(0,pe.useMemo)(()=>({height:s,minHeight:s,display:S,overflowY:R}),[s,S,R]),ee=(0,pe.useMemo)(()=>({height:c,top:h,width:p}),[c,h,p]),te=(0,pe.useMemo)(()=>({height:f,bottom:v,width:y}),[f,v,y]),ie=(0,pe.useMemo)(()=>({height:a,minHeight:a,display:E,overflowY:R}),[a,E,R]),re=e=>pe.default.createElement(Je,{name:e,key:`${e}-container`}),ne=({section:e,children:t,className:i,style:r})=>pe.default.createElement("div",{ref:e,className:i,role:"presentation",style:r},t.map(re));return pe.default.createElement("div",{ref:U,className:W,role:"treegrid"},pe.default.createElement(Le,null),ne({section:O,className:$,style:J,children:[de.RowContainerName.TOP_LEFT,de.RowContainerName.TOP_CENTER,de.RowContainerName.TOP_RIGHT,de.RowContainerName.TOP_FULL_WIDTH]}),pe.default.createElement("div",{className:K,ref:G,role:"presentation"},ne({section:V,className:j,children:[de.RowContainerName.LEFT,de.RowContainerName.CENTER,de.RowContainerName.RIGHT,de.RowContainerName.FULL_WIDTH]})),ne({section:F,className:q,style:ee,children:[de.RowContainerName.STICKY_TOP_LEFT,de.RowContainerName.STICKY_TOP_CENTER,de.RowContainerName.STICKY_TOP_RIGHT,de.RowContainerName.STICKY_TOP_FULL_WIDTH]}),ne({section:k,className:Q,style:te,children:[de.RowContainerName.STICKY_BOTTOM_LEFT,de.RowContainerName.STICKY_BOTTOM_CENTER,de.RowContainerName.STICKY_BOTTOM_RIGHT,de.RowContainerName.STICKY_BOTTOM_FULL_WIDTH]}),ne({section:H,className:Z,style:ie,children:[de.RowContainerName.BOTTOM_LEFT,de.RowContainerName.BOTTOM_CENTER,de.RowContainerName.BOTTOM_RIGHT,de.RowContainerName.BOTTOM_FULL_WIDTH]}))}),tt=C(i(22155)),it=i(98092),rt=(0,tt.forwardRef)((e,t)=>{const{children:i,eFocusableElement:r,onTabKeyDown:n,gridCtrl:s,forceFocusOutWhenTabGuardsAreEmpty:o}=e,{context:a}=(0,tt.useContext)(Y),l=(0,tt.useRef)(null),c=(0,tt.useRef)(null),u=(0,tt.useRef)(),h=e=>{const t=null==e?void 0:parseInt(e,10).toString();[l,c].forEach(e=>{var i,r;void 0===t?null==(i=e.current)||i.removeAttribute("tabindex"):null==(r=e.current)||r.setAttribute("tabindex",t)})};(0,tt.useImperativeHandle)(t,()=>({forceFocusOutOfContainer(e){var t;null==(t=u.current)||t.forceFocusOutOfContainer(e)}}));const d=(0,tt.useCallback)(()=>{if(!l.current&&!c.current)return a.destroyBean(u.current),void(u.current=null);if(l.current&&c.current){const e={setTabIndex:h};u.current=a.createBean(new it.TabGuardCtrl({comp:e,eTopGuard:l.current,eBottomGuard:c.current,eFocusableElement:r,onTabKeyDown:n,forceFocusOutWhenTabGuardsAreEmpty:o,focusInnerElement:e=>s.focusInnerElement(e)}))}},[]),p=(0,tt.useCallback)(e=>{l.current=e,d()},[d]),g=(0,tt.useCallback)(e=>{c.current=e,d()},[d]),f=e=>{const t="top"===e?it.TabGuardClassNames.TAB_GUARD_TOP:it.TabGuardClassNames.TAB_GUARD_BOTTOM;return tt.default.createElement("div",{className:`${it.TabGuardClassNames.TAB_GUARD} ${t}`,role:"presentation",ref:"top"===e?p:g})};return tt.default.createElement(tt.default.Fragment,null,f("top"),i,f("bottom"))}),nt=(0,tt.memo)(rt),st=(0,he.memo)(({context:e})=>{const[t,i]=(0,he.useState)(""),[r,n]=(0,he.useState)(""),[s,o]=(0,he.useState)(""),[a,l]=(0,he.useState)(null),[c,u]=(0,he.useState)(null),[h,d]=(0,he.useState)(!1),[p,g]=(0,he.useState)(),f=(0,he.useRef)(null),m=(0,he.useRef)(null),v=(0,he.useRef)(),[C,y]=(0,he.useState)(null),w=(0,he.useRef)(()=>{}),S=(0,he.useCallback)(()=>{},[]),b=(0,he.useMemo)(()=>e.isDestroyed()?null:e.getBean("beans"),[e]);Oe(" AG Grid ",m);const E=(0,he.useCallback)(t=>{if(m.current=t,!m.current)return e.destroyBean(f.current),void(f.current=null);if(e.isDestroyed())return;f.current=e.createBean(new ue.GridCtrl);const r=f.current;w.current=r.focusInnerElement.bind(r);const n={destroyGridUi:()=>{},setRtlClass:i,forceFocusOutOfContainer:e=>{var t;null==(t=v.current)||t.forceFocusOutOfContainer(e)},updateLayoutClasses:o,getFocusableContainers:()=>{var e,t;const i=[],r=null==(e=m.current)?void 0:e.querySelector(".ag-root"),n=null==(t=m.current)?void 0:t.querySelector(".ag-side-bar:not(.ag-hidden)");return r&&i.push(r),n&&i.push(n),i},setCursor:l,setUserSelect:u};r.setComp(n,m.current,m.current),d(!0)},[]);(0,he.useEffect)(()=>{if(!(p&&b&&f.current&&C&&m.current))return;const t=f.current,i=[],{agStackComponentsRegistry:r}=b,n=r.getComponentClass("AG-GRID-HEADER-DROP-ZONES"),s=r.getComponentClass("AG-SIDE-BAR"),o=r.getComponentClass("AG-STATUS-BAR"),a=r.getComponentClass("AG-WATERMARK"),l=r.getComponentClass("AG-PAGINATION"),c=[],u=m.current;if(t.showDropZones()&&n){const t=e.createBean(new n),r=t.getGui();u.insertAdjacentElement("afterbegin",r),c.push(r),i.push(t)}if(t.showSideBar()&&s){const t=e.createBean(new s),r=t.getGui(),n=C.querySelector(".ag-tab-guard-bottom");n&&(n.insertAdjacentElement("beforebegin",r),c.push(r)),i.push(t)}if(t.showStatusBar()&&o){const t=e.createBean(new o),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}if(l){const t=e.createBean(new l),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}if(t.showWatermark()&&a){const t=e.createBean(new a),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}return()=>{e.destroyBeans(i),c.forEach(e=>{e.parentElement&&e.parentElement.removeChild(e)})}},[p,C,b]);const A=(0,he.useMemo)(()=>X("ag-root-wrapper",t,r,s),[t,r,s]),T=(0,he.useMemo)(()=>X("ag-root-wrapper-body","ag-focus-managed",s),[s]),M=(0,he.useMemo)(()=>({userSelect:null!=c?c:"",WebkitUserSelect:null!=c?c:"",cursor:null!=a?a:""}),[c,a]),R=(0,he.useCallback)(e=>{v.current=e,g(null!==e)},[]);return he.default.createElement("div",{ref:E,className:A,style:M,role:"presentation"},he.default.createElement("div",{className:T,ref:y,role:"presentation"},h&&C&&b&&he.default.createElement(Y.Provider,{value:b},he.default.createElement(nt,{ref:R,eFocusableElement:C,onTabKeyDown:S,gridCtrl:f.current,forceFocusOutWhenTabGuardsAreEmpty:!0},he.default.createElement(et,null)))))}),ot=e=>{var t,i;const r=(0,b.useRef)(),n=(0,b.useRef)(null),s=(0,b.useRef)(null),o=(0,b.useRef)([]),a=(0,b.useRef)([]),l=(0,b.useRef)(e),c=(0,b.useRef)(!1),[u,h]=(0,b.useState)(void 0),[,d]=(0,b.useState)(0),p=(0,b.useCallback)(t=>{if(n.current=t,!n.current)return o.current.forEach(e=>e()),void(o.current.length=0);const i=e.modules||[];s.current||(s.current=new q(()=>d(e=>e+1),e.componentWrappingElement,e.maxComponentCreationTimeMs),o.current.push(()=>{var e;null==(e=s.current)||e.destroy(),s.current=null}));const l=S.ComponentUtil.combineAttributesAndGridOptions(e.gridOptions,e),u={providedBeanInstances:{frameworkComponentWrapper:new at(s.current,!!l.reactiveCustomComponents)},modules:i,frameworkOverrides:new ct},p=new S.GridCoreCreator;r.current=p.create(n.current,l,t=>{h(t),o.current.push(()=>{t.destroy()}),t.getBean(S.CtrlsService.NAME).whenReady(()=>{if(t.isDestroyed())return;const i=r.current;i&&e.setGridApi&&e.setGridApi(i,new S.ColumnApi(i))})},e=>{e.getBean(S.CtrlsService.NAME).whenReady(()=>{a.current.forEach(e=>e()),a.current.length=0,c.current=!0})},u)},[]),g=(0,b.useMemo)(()=>f({height:"100%"},e.containerStyle||{}),[e.containerStyle]),m=(0,b.useCallback)(e=>{c.current?e():a.current.push(e)},[]);return(0,b.useEffect)(()=>{const t=function(e,t){const i={};return Object.keys(t).forEach(r=>{const n=t[r];e[r]!==n&&(i[r]=n)}),i}(l.current,e);l.current=e,m(()=>{r.current&&S.ComponentUtil.processOnChange(t,r.current)})},[e]),b.default.createElement("div",{style:g,className:e.className,ref:p},u&&!u.isDestroyed()?b.default.createElement(st,{context:u}):null,null!=(i=null==(t=s.current)?void 0:t.getPortals())?i:null)},at=class extends S.BaseComponentWrapper{constructor(e,t){super(),this.parent=e,this.reactiveCustomComponents=t}createWrapper(e,t){if(this.reactiveCustomComponents){const i=(e=>{switch(e){case"filter":return k;case"floatingFilterComponent":return B;case"dateComponent":return F;case"loadingOverlayComponent":return z;case"noRowsOverlayComponent":return W;case"statusPanel":return j;case"toolPanel":return K;case"menuItem":return U}})(t.propertyName);if(i)return new i(e,this.parent,t)}else switch(t.propertyName){case"filter":case"floatingFilterComponent":case"dateComponent":case"loadingOverlayComponent":case"noRowsOverlayComponent":case"statusPanel":case"toolPanel":case"menuItem":Pe()}const i=!t.cellRenderer&&"toolPanel"!==t.propertyName;return new L(e,this.parent,t,i)}},lt=(0,b.forwardRef)((e,t)=>{const{ctrlsFactory:i,context:r,gos:n,resizeObserverService:s,clientSideRowModel:o,serverSideRowModel:a}=(0,b.useContext)(Y),[l,c]=(0,b.useState)(()=>new Z),[u,h]=(0,b.useState)(()=>new Z),[d,p]=(0,b.useState)(),[g,v]=(0,b.useState)(),C=(0,b.useRef)(),y=(0,b.useRef)(null),w=(0,b.useRef)(),E=(0,b.useMemo)(()=>S.ModuleRegistry.__getGridRegisteredModules(e.api.getGridId()),[e]),A=(0,b.useMemo)(()=>l.toString()+" ag-details-row",[l]),T=(0,b.useMemo)(()=>u.toString()+" ag-details-grid",[u]);t&&(0,b.useImperativeHandle)(t,()=>({refresh(){var e,t;return null!=(t=null==(e=C.current)?void 0:e.refresh())&&t}})),e.template&&S._.warnOnce("detailCellRendererParams.template is not supported by AG Grid React. To change the template, provide a Custom Detail Cell Renderer. See https://ag-grid.com/react-data-grid/master-detail-custom-detail/");const M=(0,b.useCallback)(t=>{if(y.current=t,!y.current)return r.destroyBean(C.current),void(w.current&&w.current());const l={addOrRemoveCssClass:(e,t)=>c(i=>i.setClass(e,t)),addOrRemoveDetailGridCssClass:(e,t)=>h(i=>i.setClass(e,t)),setDetailGrid:e=>p(e),setRowData:e=>v(e),getGui:()=>y.current},u=i.getInstance("detailCellRenderer");if(u&&(r.createBean(u),u.init(l,e),C.current=u,n.get("detailRowAutoHeight"))){const t=()=>{if(null==y.current)return;const t=y.current.clientHeight;null!=t&&t>0&&setTimeout(()=>{e.node.setRowHeight(t),o?o.onRowHeightChanged():a&&a.onRowHeightChanged()},0)};w.current=s.observeResize(y.current,t),t()}},[]),R=(0,b.useCallback)((e,t)=>{var i;null==(i=C.current)||i.registerDetailWithMaster(e,t)},[]);return b.default.createElement("div",{className:A,ref:M},d&&b.default.createElement(ot,m(f({className:T},d),{modules:E,rowData:g,setGridApi:R})))}),ct=class extends S.VanillaFrameworkOverrides{constructor(){super("react"),this.frameworkComponents={agGroupCellRenderer:ce,agGroupRowRenderer:ce,agDetailCellRenderer:lt},this.wrapIncoming=(e,t)=>{return"ensureVisible"===t?(i=e,te||setTimeout(()=>te=!1,0),te=!0,i()):e();var i},this.renderingEngine="react"}frameworkComponent(e){return this.frameworkComponents[e]}isFrameworkComponent(e){if(!e)return!1;const t=e.prototype;return!(t&&"getGui"in t)}},ut=class extends w.Component{constructor(){super(...arguments),this.apiListeners=[],this.setGridApi=(e,t)=>{this.api=e,this.columnApi=t,this.apiListeners.forEach(t=>t(e))}}registerApiListener(e){this.apiListeners.push(e)}componentWillUnmount(){this.apiListeners.length=0}render(){return w.default.createElement(ot,m(f({},this.props),{setGridApi:this.setGridApi}))}},ht=(e=>(e.IdentityCheck="IdentityCheck",e.DeepValueCheck="DeepValueCheck",e.NoCheck="NoCheck",e))(ht||{}),dt=i(22155);function pt(e){const{setMethods:t}=(0,dt.useContext)(T);t(e)}function gt(e){pt(e)}function ft(e){return pt(e)}function mt(e){return pt(e)}function vt(e){pt(e)}function Ct(e){pt(e)}},32535(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(28825),n=i(38994),s=i(28261),o=i(36023),a=i(28425),l=i(86660),c="errorMessage",u=new r.Name("emUsed"),h={required:"missingProperty",dependencies:"property",dependentRequired:"property"},d=/\$\{[^}]+\}/,p=/\$\{([^}]+)\}/g,g=/^""\s*\+\s*|\s*\+\s*""$/g;const f=(e,t={})=>{if(!e.opts.allErrors)throw new Error("ajv-errors: Ajv option allErrors must be true");if(e.opts.jsPropertySyntax)throw new Error("ajv-errors: ajv option jsPropertySyntax is not supported");return e.addKeyword(function(e){return{keyword:c,schemaType:["string","object"],post:!0,code(t){const{gen:i,data:f,schema:m,schemaValue:v,it:C}=t;if(!1===C.createErrors)return;const y=m,w=n.strConcat(l.default.instancePath,C.errorPath);function S(e,t){return n.and(r._`${e}.keyword !== ${c}`,r._`!${e}.${u}`,r._`${e}.instancePath === ${w}`,r._`${e}.keyword in ${t}`,r._`${e}.schemaPath.indexOf(${C.errSchemaPath}) === 0`,r._`/^\\/[^\\/]*$/.test(${e}.schemaPath.slice(${C.errSchemaPath.length}))`)}function b(e,t){const r=[];for(const i in e){const e=t[i];d.test(e)&&r.push([i,A(e)])}return i.object(...r)}function E(e){return d.test(e)?new s._Code(s.safeStringify(e).replace(p,(e,t)=>`" + JSON.stringify(${o.getData(t,C)}) + "`).replace(g,"")):r.stringify(e)}function A(e){return r._`function(){return ${E(e)}}`}i.if(r._`${l.default.errors} > 0`,()=>{if("object"==typeof y){const[s,o]=function(e){let t,i;for(const r in e){if("properties"===r||"items"===r)continue;const n=e[r];if("object"==typeof n){t||(t={});const e=t[r]={};for(const t in n)e[t]=[]}else i||(i={}),i[r]=[]}return[t,i]}(y);o&&function(n){const s=i.const("emErrors",r.stringify(n)),o=i.const("templates",b(n,m));i.forOf("err",l.default.vErrors,e=>i.if(S(e,s),()=>i.code(r._`${s}[${e}.keyword].push(${e})`).assign(r._`${e}.${u}`,!0)));const{singleError:c}=e;if(c){const e=i.let("message",r._`""`),n=i.let("paramsErrors",r._`[]`);h(t=>{i.if(e,()=>i.code(r._`${e} += ${"string"==typeof c?c:";"}`)),i.code(r._`${e} += ${d(t)}`),i.assign(n,r._`${n}.concat(${s}[${t}])`)}),a.reportError(t,{message:e,params:r._`{errors: ${n}}`})}else h(e=>a.reportError(t,{message:d(e),params:r._`{errors: ${s}[${e}]}`}));function h(e){i.forIn("key",s,t=>i.if(r._`${s}[${t}].length`,()=>e(t)))}function d(e){return r._`${e} in ${o} ? ${o}[${e}]() : ${v}[${e}]`}}(o),s&&function(e){const n=i.const("emErrors",r.stringify(e)),s=[];for(const t in e)s.push([t,b(e[t],m[t])]);const o=i.const("templates",i.object(...s)),c=i.scopeValue("obj",{ref:h,code:r.stringify(h)}),d=i.let("emPropParams"),p=i.let("emParamsErrors");i.forOf("err",l.default.vErrors,e=>i.if(S(e,n),()=>{i.assign(d,r._`${c}[${e}.keyword]`),i.assign(p,r._`${n}[${e}.keyword][${e}.params[${d}]]`),i.if(p,()=>i.code(r._`${p}.push(${e})`).assign(r._`${e}.${u}`,!0))})),i.forIn("key",n,e=>i.forIn("keyProp",r._`${n}[${e}]`,s=>{i.assign(p,r._`${n}[${e}][${s}]`),i.if(r._`${p}.length`,()=>{const n=i.const("tmpl",r._`${o}[${e}] && ${o}[${e}][${s}]`);a.reportError(t,{message:r._`${n} ? ${n}() : ${v}[${e}][${s}]`,params:r._`{errors: ${p}}`})})}))}(s),function(e){const{props:s,items:o}=e;if(!s&&!o)return;const h=r._`typeof ${f} == "object"`,d=r._`Array.isArray(${f})`,p=i.let("emErrors");let g,C;const y=i.let("templates");function S(e,t){i.assign(p,r.stringify(e)),i.assign(y,b(e,t))}s&&o?(g=i.let("emChildKwd"),i.if(h),i.if(d,()=>{S(o,m.items),i.assign(g,r.str`items`)},()=>{S(s,m.properties),i.assign(g,r.str`properties`)}),C=r._`[${g}]`):o?(i.if(d),S(o,m.items),C=r._`.items`):s&&(i.if(n.and(h,n.not(d))),S(s,m.properties),C=r._`.properties`),i.forOf("err",l.default.vErrors,e=>function(e,t,s){i.if(n.and(r._`${e}.keyword !== ${c}`,r._`!${e}.${u}`,r._`${e}.instancePath.indexOf(${w}) === 0`),()=>{const n=i.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:r._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),o=i.const("emMatches",r._`${n}.exec(${e}.instancePath.slice(${w}.length))`),a=i.const("emChild",r._`${o} && ${o}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);i.if(r._`${a} !== undefined && ${a} in ${t}`,()=>s(a))})}(e,p,t=>i.code(r._`${p}[${t}].push(${e})`).assign(r._`${e}.${u}`,!0))),i.forIn("key",p,e=>i.if(r._`${p}[${e}].length`,()=>{a.reportError(t,{message:r._`${e} in ${y} ? ${y}[${e}]() : ${v}${C}[${e}]`,params:r._`{errors: ${p}[${e}]}`}),i.assign(r._`${l.default.vErrors}[${l.default.errors}-1].instancePath`,r._`${w} + "/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),i.endIf()}(function({properties:e,items:t}){const i={};if(e){i.props={};for(const t in e)i.props[t]=[]}if(t){i.items={};for(let e=0;e<t.length;e++)i.items[e]=[]}return i}(y))}const s="string"==typeof y?y:y._;s&&function(e){const s=i.const("emErrs",r._`[]`);i.forOf("err",l.default.vErrors,e=>i.if(function(e){return n.and(r._`${e}.keyword !== ${c}`,r._`!${e}.${u}`,n.or(r._`${e}.instancePath === ${w}`,n.and(r._`${e}.instancePath.indexOf(${w}) === 0`,r._`${e}.instancePath[${w}.length] === "/"`)),r._`${e}.schemaPath.indexOf(${C.errSchemaPath}) === 0`,r._`${e}.schemaPath[${C.errSchemaPath}.length] === "/"`)}(e),()=>i.code(r._`${s}.push(${e})`).assign(r._`${e}.${u}`,!0))),i.if(r._`${s}.length`,()=>a.reportError(t,{message:E(e),params:r._`{errors: ${s}}`}))}(s),e.keepErrors||function(){const e=i.const("emErrs",r._`[]`);i.forOf("err",l.default.vErrors,t=>i.if(r._`!${t}.${u}`,()=>i.code(r._`${e}.push(${t})`))),i.assign(l.default.vErrors,e).assign(l.default.errors,r._`${e}.length`)}()})},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}}}(t))};t.default=f,e.exports=f,e.exports.default=f},5888(e,t){"use strict";function i(e,t){return{validate:e,compare:t}}Object.defineProperty(t,"__esModule",{value:!0}),t.formatNames=t.fastFormats=t.fullFormats=void 0,t.fullFormats={date:i(s,o),time:i(l(!0),c),"date-time":i(d(!0),p),"iso-time":i(l(),u),"iso-date-time":i(d(),g),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:function(e){return f.test(e)&&m.test(e)},"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:function(e){if(y.test(e))return!1;try{return new RegExp(e),!0}catch(e){return!1}},uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:function(e){return v.lastIndex=0,v.test(e)},int32:{type:"number",validate:function(e){return Number.isInteger(e)&&e<=2147483647&&e>=-2147483648}},int64:{type:"number",validate:function(e){return Number.isInteger(e)}},float:{type:"number",validate:C},double:{type:"number",validate:C},password:!0,binary:!0},t.fastFormats={...t.fullFormats,date:i(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,o),time:i(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,c),"date-time":i(/^\d\d\d\d-[0-1]\d-[0-3]\dt(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,p),"iso-time":i(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,u),"iso-date-time":i(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,g),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},t.formatNames=Object.keys(t.fullFormats);const r=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,n=[0,31,28,31,30,31,30,31,31,30,31,30,31];function s(e){const t=r.exec(e);if(!t)return!1;const i=+t[1],s=+t[2],o=+t[3];return s>=1&&s<=12&&o>=1&&o<=(2===s&&function(e){return e%4==0&&(e%100!=0||e%400==0)}(i)?29:n[s])}function o(e,t){if(e&&t)return e>t?1:e<t?-1:0}const a=/^(\d\d):(\d\d):(\d\d(?:\.\d+)?)(z|([+-])(\d\d)(?::?(\d\d))?)?$/i;function l(e){return function(t){const i=a.exec(t);if(!i)return!1;const r=+i[1],n=+i[2],s=+i[3],o=i[4],l="-"===i[5]?-1:1,c=+(i[6]||0),u=+(i[7]||0);if(c>23||u>59||e&&!o)return!1;if(r<=23&&n<=59&&s<60)return!0;const h=n-u*l,d=r-c*l-(h<0?1:0);return(23===d||-1===d)&&(59===h||-1===h)&&s<61}}function c(e,t){if(!e||!t)return;const i=new Date("2020-01-01T"+e).valueOf(),r=new Date("2020-01-01T"+t).valueOf();return i&&r?i-r:void 0}function u(e,t){if(!e||!t)return;const i=a.exec(e),r=a.exec(t);return i&&r?(e=i[1]+i[2]+i[3])>(t=r[1]+r[2]+r[3])?1:e<t?-1:0:void 0}const h=/t|\s/i;function d(e){const t=l(e);return function(e){const i=e.split(h);return 2===i.length&&s(i[0])&&t(i[1])}}function p(e,t){if(!e||!t)return;const i=new Date(e).valueOf(),r=new Date(t).valueOf();return i&&r?i-r:void 0}function g(e,t){if(!e||!t)return;const[i,r]=e.split(h),[n,s]=t.split(h),a=o(i,n);return void 0!==a?a||c(r,s):void 0}const f=/\/|:/,m=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,v=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function C(){return!0}const y=/[^\\]\\Z/},91712(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(5888),n=i(59035),s=i(38994),o=new s.Name("fullFormats"),a=new s.Name("fastFormats"),l=(e,t={keywords:!0})=>{if(Array.isArray(t))return c(e,t,r.fullFormats,o),e;const[i,s]="fast"===t.mode?[r.fastFormats,a]:[r.fullFormats,o];return c(e,t.formats||r.formatNames,i,s),t.keywords&&(0,n.default)(e),e};function c(e,t,i,r){var n,o;null!==(n=(o=e.opts.code).formats)&&void 0!==n||(o.formats=s._`require("ajv-formats/dist/formats").${r}`);for(const r of t)e.addFormat(r,i[r])}l.get=(e,t="full")=>{const i=("fast"===t?r.fastFormats:r.fullFormats)[e];if(!i)throw new Error(`Unknown format "${e}"`);return i},e.exports=t=l,Object.defineProperty(t,"__esModule",{value:!0}),t.default=l},59035(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatLimitDefinition=void 0;const r=i(28825),n=i(38994),s=n.operators,o={formatMaximum:{okStr:"<=",ok:s.LTE,fail:s.GT},formatMinimum:{okStr:">=",ok:s.GTE,fail:s.LT},formatExclusiveMaximum:{okStr:"<",ok:s.LT,fail:s.GTE},formatExclusiveMinimum:{okStr:">",ok:s.GT,fail:s.LTE}},a={message:({keyword:e,schemaCode:t})=>n.str`should be ${o[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>n._`{comparison: ${o[e].okStr}, limit: ${t}}`};t.formatLimitDefinition={keyword:Object.keys(o),type:"string",schemaType:"string",$data:!0,error:a,code(e){const{gen:t,data:i,schemaCode:s,keyword:a,it:l}=e,{opts:c,self:u}=l;if(!c.validateFormats)return;const h=new r.KeywordCxt(l,u.RULES.all.format.definition,"format");function d(e){return n._`${e}.compare(${i}, ${s}) ${o[a].fail} 0`}h.$data?function(){const i=t.scopeValue("formats",{ref:u.formats,code:c.code.formats}),r=t.const("fmt",n._`${i}[${h.schemaCode}]`);e.fail$data((0,n.or)(n._`typeof ${r} != "object"`,n._`${r} instanceof RegExp`,n._`typeof ${r}.compare != "function"`,d(r)))}():function(){const i=h.schema,r=u.formats[i];if(!r||!0===r)return;if("object"!=typeof r||r instanceof RegExp||"function"!=typeof r.compare)throw new Error(`"${a}": format "${i}" does not define "compare" function`);const s=t.scopeValue("formats",{key:i,ref:r,code:c.code.formats?n._`${c.code.formats}${(0,n.getProperty)(i)}`:void 0});e.fail$data(d(s))}()},dependencies:["format"]},t.default=e=>(e.addKeyword(t.formatLimitDefinition),e)},28825(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const r=i(51967),n=i(83959),s=i(29376),o=i(7456),a=["/properties"],l="http://json-schema.org/draft-07/schema";class c extends r.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(e=>this.addVocabulary(e)),this.opts.discriminator&&this.addKeyword(s.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const e=this.opts.$data?this.$dataMetaSchema(o,a):o;this.addMetaSchema(e,l,!1),this.refs["http://json-schema.org/schema"]=l}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(l)?l:void 0)}}t.Ajv=c,e.exports=t=c,e.exports.Ajv=c,Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var u=i(36023);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return u.KeywordCxt}});var h=i(38994);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return h._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return h.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return h.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return h.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return h.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return h.CodeGen}});var d=i(74383);Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return d.default}});var p=i(4220);Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return p.default}})},28261(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.regexpCode=t.getEsmExportName=t.getProperty=t.safeStringify=t.stringify=t.strConcat=t.addCodeArg=t.str=t._=t.nil=t._Code=t.Name=t.IDENTIFIER=t._CodeOrName=void 0;class i{}t._CodeOrName=i,t.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class r extends i{constructor(e){if(super(),!t.IDENTIFIER.test(e))throw new Error("CodeGen: name must be a valid identifier");this.str=e}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}t.Name=r;class n extends i{constructor(e){super(),this._items="string"==typeof e?[e]:e}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const e=this._items[0];return""===e||'""'===e}get str(){var e;return null!==(e=this._str)&&void 0!==e?e:this._str=this._items.reduce((e,t)=>`${e}${t}`,"")}get names(){var e;return null!==(e=this._names)&&void 0!==e?e:this._names=this._items.reduce((e,t)=>(t instanceof r&&(e[t.str]=(e[t.str]||0)+1),e),{})}}function s(e,...t){const i=[e[0]];let r=0;for(;r<t.length;)l(i,t[r]),i.push(e[++r]);return new n(i)}t._Code=n,t.nil=new n(""),t._=s;const o=new n("+");function a(e,...t){const i=[u(e[0])];let r=0;for(;r<t.length;)i.push(o),l(i,t[r]),i.push(o,u(e[++r]));return function(e){let t=1;for(;t<e.length-1;){if(e[t]===o){const i=c(e[t-1],e[t+1]);if(void 0!==i){e.splice(t-1,3,i);continue}e[t++]="+"}t++}}(i),new n(i)}function l(e,t){var i;t instanceof n?e.push(...t._items):t instanceof r?e.push(t):e.push("number"==typeof(i=t)||"boolean"==typeof i||null===i?i:u(Array.isArray(i)?i.join(","):i))}function c(e,t){if('""'===t)return e;if('""'===e)return t;if("string"==typeof e){if(t instanceof r||'"'!==e[e.length-1])return;return"string"!=typeof t?`${e.slice(0,-1)}${t}"`:'"'===t[0]?e.slice(0,-1)+t.slice(1):void 0}return"string"!=typeof t||'"'!==t[0]||e instanceof r?void 0:`"${e}${t.slice(1)}`}function u(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}t.str=a,t.addCodeArg=l,t.strConcat=function(e,t){return t.emptyStr()?e:e.emptyStr()?t:a`${e}${t}`},t.stringify=function(e){return new n(u(e))},t.safeStringify=u,t.getProperty=function(e){return"string"==typeof e&&t.IDENTIFIER.test(e)?new n(`.${e}`):s`[${e}]`},t.getEsmExportName=function(e){if("string"==typeof e&&t.IDENTIFIER.test(e))return new n(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)},t.regexpCode=function(e){return new n(e.toString())}},38994(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.or=t.and=t.not=t.CodeGen=t.operators=t.varKinds=t.ValueScopeName=t.ValueScope=t.Scope=t.Name=t.regexpCode=t.stringify=t.getProperty=t.nil=t.strConcat=t.str=t._=void 0;const r=i(28261),n=i(44490);var s=i(28261);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return s._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return s.str}}),Object.defineProperty(t,"strConcat",{enumerable:!0,get:function(){return s.strConcat}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return s.nil}}),Object.defineProperty(t,"getProperty",{enumerable:!0,get:function(){return s.getProperty}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return s.stringify}}),Object.defineProperty(t,"regexpCode",{enumerable:!0,get:function(){return s.regexpCode}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return s.Name}});var o=i(44490);Object.defineProperty(t,"Scope",{enumerable:!0,get:function(){return o.Scope}}),Object.defineProperty(t,"ValueScope",{enumerable:!0,get:function(){return o.ValueScope}}),Object.defineProperty(t,"ValueScopeName",{enumerable:!0,get:function(){return o.ValueScopeName}}),Object.defineProperty(t,"varKinds",{enumerable:!0,get:function(){return o.varKinds}}),t.operators={GT:new r._Code(">"),GTE:new r._Code(">="),LT:new r._Code("<"),LTE:new r._Code("<="),EQ:new r._Code("==="),NEQ:new r._Code("!=="),NOT:new r._Code("!"),OR:new r._Code("||"),AND:new r._Code("&&"),ADD:new r._Code("+")};class a{optimizeNodes(){return this}optimizeNames(e,t){return this}}class l extends a{constructor(e,t,i){super(),this.varKind=e,this.name=t,this.rhs=i}render({es5:e,_n:t}){const i=e?n.varKinds.var:this.varKind,r=void 0===this.rhs?"":` = ${this.rhs}`;return`${i} ${this.name}${r};`+t}optimizeNames(e,t){if(e[this.name.str])return this.rhs&&(this.rhs=D(this.rhs,e,t)),this}get names(){return this.rhs instanceof r._CodeOrName?this.rhs.names:{}}}class c extends a{constructor(e,t,i){super(),this.lhs=e,this.rhs=t,this.sideEffects=i}render({_n:e}){return`${this.lhs} = ${this.rhs};`+e}optimizeNames(e,t){if(!(this.lhs instanceof r.Name)||e[this.lhs.str]||this.sideEffects)return this.rhs=D(this.rhs,e,t),this}get names(){return x(this.lhs instanceof r.Name?{}:{...this.lhs.names},this.rhs)}}class u extends c{constructor(e,t,i,r){super(e,i,r),this.op=t}render({_n:e}){return`${this.lhs} ${this.op}= ${this.rhs};`+e}}class h extends a{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`${this.label}:`+e}}class d extends a{constructor(e){super(),this.label=e,this.names={}}render({_n:e}){return`break${this.label?` ${this.label}`:""};`+e}}class p extends a{constructor(e){super(),this.error=e}render({_n:e}){return`throw ${this.error};`+e}get names(){return this.error.names}}class g extends a{constructor(e){super(),this.code=e}render({_n:e}){return`${this.code};`+e}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(e,t){return this.code=D(this.code,e,t),this}get names(){return this.code instanceof r._CodeOrName?this.code.names:{}}}class f extends a{constructor(e=[]){super(),this.nodes=e}render(e){return this.nodes.reduce((t,i)=>t+i.render(e),"")}optimizeNodes(){const{nodes:e}=this;let t=e.length;for(;t--;){const i=e[t].optimizeNodes();Array.isArray(i)?e.splice(t,1,...i):i?e[t]=i:e.splice(t,1)}return e.length>0?this:void 0}optimizeNames(e,t){const{nodes:i}=this;let r=i.length;for(;r--;){const n=i[r];n.optimizeNames(e,t)||(I(e,n.names),i.splice(r,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((e,t)=>P(e,t.names),{})}}class m extends f{render(e){return"{"+e._n+super.render(e)+"}"+e._n}}class v extends f{}class C extends m{}C.kind="else";class y extends m{constructor(e,t){super(t),this.condition=e}render(e){let t=`if(${this.condition})`+super.render(e);return this.else&&(t+="else "+this.else.render(e)),t}optimizeNodes(){super.optimizeNodes();const e=this.condition;if(!0===e)return this.nodes;let t=this.else;if(t){const e=t.optimizeNodes();t=this.else=Array.isArray(e)?new C(e):e}return t?!1===e?t instanceof y?t:t.nodes:this.nodes.length?this:new y(L(e),t instanceof y?[t]:t.nodes):!1!==e&&this.nodes.length?this:void 0}optimizeNames(e,t){var i;if(this.else=null===(i=this.else)||void 0===i?void 0:i.optimizeNames(e,t),super.optimizeNames(e,t)||this.else)return this.condition=D(this.condition,e,t),this}get names(){const e=super.names;return x(e,this.condition),this.else&&P(e,this.else.names),e}}y.kind="if";class w extends m{}w.kind="for";class S extends w{constructor(e){super(),this.iteration=e}render(e){return`for(${this.iteration})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iteration=D(this.iteration,e,t),this}get names(){return P(super.names,this.iteration.names)}}class b extends w{constructor(e,t,i,r){super(),this.varKind=e,this.name=t,this.from=i,this.to=r}render(e){const t=e.es5?n.varKinds.var:this.varKind,{name:i,from:r,to:s}=this;return`for(${t} ${i}=${r}; ${i}<${s}; ${i}++)`+super.render(e)}get names(){const e=x(super.names,this.from);return x(e,this.to)}}class E extends w{constructor(e,t,i,r){super(),this.loop=e,this.varKind=t,this.name=i,this.iterable=r}render(e){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(e)}optimizeNames(e,t){if(super.optimizeNames(e,t))return this.iterable=D(this.iterable,e,t),this}get names(){return P(super.names,this.iterable.names)}}class A extends m{constructor(e,t,i){super(),this.name=e,this.args=t,this.async=i}render(e){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(e)}}A.kind="func";class T extends f{render(e){return"return "+super.render(e)}}T.kind="return";class M extends m{render(e){let t="try"+super.render(e);return this.catch&&(t+=this.catch.render(e)),this.finally&&(t+=this.finally.render(e)),t}optimizeNodes(){var e,t;return super.optimizeNodes(),null===(e=this.catch)||void 0===e||e.optimizeNodes(),null===(t=this.finally)||void 0===t||t.optimizeNodes(),this}optimizeNames(e,t){var i,r;return super.optimizeNames(e,t),null===(i=this.catch)||void 0===i||i.optimizeNames(e,t),null===(r=this.finally)||void 0===r||r.optimizeNames(e,t),this}get names(){const e=super.names;return this.catch&&P(e,this.catch.names),this.finally&&P(e,this.finally.names),e}}class R extends m{constructor(e){super(),this.error=e}render(e){return`catch(${this.error})`+super.render(e)}}R.kind="catch";class _ extends m{render(e){return"finally"+super.render(e)}}function P(e,t){for(const i in t)e[i]=(e[i]||0)+(t[i]||0);return e}function x(e,t){return t instanceof r._CodeOrName?P(e,t.names):e}function D(e,t,i){return e instanceof r.Name?s(e):(n=e)instanceof r._Code&&n._items.some(e=>e instanceof r.Name&&1===t[e.str]&&void 0!==i[e.str])?new r._Code(e._items.reduce((e,t)=>(t instanceof r.Name&&(t=s(t)),t instanceof r._Code?e.push(...t._items):e.push(t),e),[])):e;var n;function s(e){const r=i[e.str];return void 0===r||1!==t[e.str]?e:(delete t[e.str],r)}}function I(e,t){for(const i in t)e[i]=(e[i]||0)-(t[i]||0)}function L(e){return"boolean"==typeof e||"number"==typeof e||null===e?!e:r._`!${k(e)}`}_.kind="finally",t.CodeGen=class{constructor(e,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...t,_n:t.lines?"\n":""},this._extScope=e,this._scope=new n.Scope({parent:e}),this._nodes=[new v]}toString(){return this._root.render(this.opts)}name(e){return this._scope.name(e)}scopeName(e){return this._extScope.name(e)}scopeValue(e,t){const i=this._extScope.value(e,t);return(this._values[i.prefix]||(this._values[i.prefix]=new Set)).add(i),i}getScopeValue(e,t){return this._extScope.getValue(e,t)}scopeRefs(e){return this._extScope.scopeRefs(e,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(e,t,i,r){const n=this._scope.toName(t);return void 0!==i&&r&&(this._constants[n.str]=i),this._leafNode(new l(e,n,i)),n}const(e,t,i){return this._def(n.varKinds.const,e,t,i)}let(e,t,i){return this._def(n.varKinds.let,e,t,i)}var(e,t,i){return this._def(n.varKinds.var,e,t,i)}assign(e,t,i){return this._leafNode(new c(e,t,i))}add(e,i){return this._leafNode(new u(e,t.operators.ADD,i))}code(e){return"function"==typeof e?e():e!==r.nil&&this._leafNode(new g(e)),this}object(...e){const t=["{"];for(const[i,n]of e)t.length>1&&t.push(","),t.push(i),(i!==n||this.opts.es5)&&(t.push(":"),(0,r.addCodeArg)(t,n));return t.push("}"),new r._Code(t)}if(e,t,i){if(this._blockNode(new y(e)),t&&i)this.code(t).else().code(i).endIf();else if(t)this.code(t).endIf();else if(i)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(e){return this._elseNode(new y(e))}else(){return this._elseNode(new C)}endIf(){return this._endBlockNode(y,C)}_for(e,t){return this._blockNode(e),t&&this.code(t).endFor(),this}for(e,t){return this._for(new S(e),t)}forRange(e,t,i,r,s=(this.opts.es5?n.varKinds.var:n.varKinds.let)){const o=this._scope.toName(e);return this._for(new b(s,o,t,i),()=>r(o))}forOf(e,t,i,s=n.varKinds.const){const o=this._scope.toName(e);if(this.opts.es5){const e=t instanceof r.Name?t:this.var("_arr",t);return this.forRange("_i",0,r._`${e}.length`,t=>{this.var(o,r._`${e}[${t}]`),i(o)})}return this._for(new E("of",s,o,t),()=>i(o))}forIn(e,t,i,s=(this.opts.es5?n.varKinds.var:n.varKinds.const)){if(this.opts.ownProperties)return this.forOf(e,r._`Object.keys(${t})`,i);const o=this._scope.toName(e);return this._for(new E("in",s,o,t),()=>i(o))}endFor(){return this._endBlockNode(w)}label(e){return this._leafNode(new h(e))}break(e){return this._leafNode(new d(e))}return(e){const t=new T;if(this._blockNode(t),this.code(e),1!==t.nodes.length)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(T)}try(e,t,i){if(!t&&!i)throw new Error('CodeGen: "try" without "catch" and "finally"');const r=new M;if(this._blockNode(r),this.code(e),t){const e=this.name("e");this._currNode=r.catch=new R(e),t(e)}return i&&(this._currNode=r.finally=new _,this.code(i)),this._endBlockNode(R,_)}throw(e){return this._leafNode(new p(e))}block(e,t){return this._blockStarts.push(this._nodes.length),e&&this.code(e).endBlock(t),this}endBlock(e){const t=this._blockStarts.pop();if(void 0===t)throw new Error("CodeGen: not in self-balancing block");const i=this._nodes.length-t;if(i<0||void 0!==e&&i!==e)throw new Error(`CodeGen: wrong number of nodes: ${i} vs ${e} expected`);return this._nodes.length=t,this}func(e,t=r.nil,i,n){return this._blockNode(new A(e,t,i)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(A)}optimize(e=1){for(;e-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(e){return this._currNode.nodes.push(e),this}_blockNode(e){this._currNode.nodes.push(e),this._nodes.push(e)}_endBlockNode(e,t){const i=this._currNode;if(i instanceof e||t&&i instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${e.kind}/${t.kind}`:e.kind}"`)}_elseNode(e){const t=this._currNode;if(!(t instanceof y))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=e,this}get _root(){return this._nodes[0]}get _currNode(){const e=this._nodes;return e[e.length-1]}set _currNode(e){const t=this._nodes;t[t.length-1]=e}},t.not=L;const N=F(t.operators.AND);t.and=function(...e){return e.reduce(N)};const O=F(t.operators.OR);function F(e){return(t,i)=>t===r.nil?i:i===r.nil?t:r._`${k(t)} ${e} ${k(i)}`}function k(e){return e instanceof r.Name?e:r._`(${e})`}t.or=function(...e){return e.reduce(O)}},44490(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ValueScope=t.ValueScopeName=t.Scope=t.varKinds=t.UsedValueState=void 0;const r=i(28261);class n extends Error{constructor(e){super(`CodeGen: "code" for ${e} not defined`),this.value=e.value}}var s;!function(e){e[e.Started=0]="Started",e[e.Completed=1]="Completed"}(s||(t.UsedValueState=s={})),t.varKinds={const:new r.Name("const"),let:new r.Name("let"),var:new r.Name("var")};class o{constructor({prefixes:e,parent:t}={}){this._names={},this._prefixes=e,this._parent=t}toName(e){return e instanceof r.Name?e:this.name(e)}name(e){return new r.Name(this._newName(e))}_newName(e){return`${e}${(this._names[e]||this._nameGroup(e)).index++}`}_nameGroup(e){var t,i;if((null===(i=null===(t=this._parent)||void 0===t?void 0:t._prefixes)||void 0===i?void 0:i.has(e))||this._prefixes&&!this._prefixes.has(e))throw new Error(`CodeGen: prefix "${e}" is not allowed in this scope`);return this._names[e]={prefix:e,index:0}}}t.Scope=o;class a extends r.Name{constructor(e,t){super(t),this.prefix=e}setValue(e,{property:t,itemIndex:i}){this.value=e,this.scopePath=r._`.${new r.Name(t)}[${i}]`}}t.ValueScopeName=a;const l=r._`\n`;t.ValueScope=class extends o{constructor(e){super(e),this._values={},this._scope=e.scope,this.opts={...e,_n:e.lines?l:r.nil}}get(){return this._scope}name(e){return new a(e,this._newName(e))}value(e,t){var i;if(void 0===t.ref)throw new Error("CodeGen: ref must be passed in value");const r=this.toName(e),{prefix:n}=r,s=null!==(i=t.key)&&void 0!==i?i:t.ref;let o=this._values[n];if(o){const e=o.get(s);if(e)return e}else o=this._values[n]=new Map;o.set(s,r);const a=this._scope[n]||(this._scope[n]=[]),l=a.length;return a[l]=t.ref,r.setValue(t,{property:n,itemIndex:l}),r}getValue(e,t){const i=this._values[e];if(i)return i.get(t)}scopeRefs(e,t=this._values){return this._reduceValues(t,t=>{if(void 0===t.scopePath)throw new Error(`CodeGen: name "${t}" has no value`);return r._`${e}${t.scopePath}`})}scopeCode(e=this._values,t,i){return this._reduceValues(e,e=>{if(void 0===e.value)throw new Error(`CodeGen: name "${e}" has no value`);return e.value.code},t,i)}_reduceValues(e,i,o={},a){let l=r.nil;for(const c in e){const u=e[c];if(!u)continue;const h=o[c]=o[c]||new Map;u.forEach(e=>{if(h.has(e))return;h.set(e,s.Started);let o=i(e);if(o){const i=this.opts.es5?t.varKinds.var:t.varKinds.const;l=r._`${l}${i} ${e} = ${o};${this.opts._n}`}else{if(!(o=null==a?void 0:a(e)))throw new n(e);l=r._`${l}${o}${this.opts._n}`}h.set(e,s.Completed)})}return l}}},28425(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extendErrors=t.resetErrorsCount=t.reportExtraError=t.reportError=t.keyword$DataError=t.keywordError=void 0;const r=i(38994),n=i(67218),s=i(86660);function o(e,t){const i=e.const("err",t);e.if(r._`${s.default.vErrors} === null`,()=>e.assign(s.default.vErrors,r._`[${i}]`),r._`${s.default.vErrors}.push(${i})`),e.code(r._`${s.default.errors}++`)}function a(e,t){const{gen:i,validateName:n,schemaEnv:s}=e;s.$async?i.throw(r._`new ${e.ValidationError}(${t})`):(i.assign(r._`${n}.errors`,t),i.return(!1))}t.keywordError={message:({keyword:e})=>r.str`must pass "${e}" keyword validation`},t.keyword$DataError={message:({keyword:e,schemaType:t})=>t?r.str`"${e}" keyword must be ${t} ($data)`:r.str`"${e}" keyword is invalid ($data)`},t.reportError=function(e,i=t.keywordError,n,s){const{it:l}=e,{gen:u,compositeRule:h,allErrors:d}=l,p=c(e,i,n);(null!=s?s:h||d)?o(u,p):a(l,r._`[${p}]`)},t.reportExtraError=function(e,i=t.keywordError,r){const{it:n}=e,{gen:l,compositeRule:u,allErrors:h}=n;o(l,c(e,i,r)),u||h||a(n,s.default.vErrors)},t.resetErrorsCount=function(e,t){e.assign(s.default.errors,t),e.if(r._`${s.default.vErrors} !== null`,()=>e.if(t,()=>e.assign(r._`${s.default.vErrors}.length`,t),()=>e.assign(s.default.vErrors,null)))},t.extendErrors=function({gen:e,keyword:t,schemaValue:i,data:n,errsCount:o,it:a}){if(void 0===o)throw new Error("ajv implementation error");const l=e.name("err");e.forRange("i",o,s.default.errors,o=>{e.const(l,r._`${s.default.vErrors}[${o}]`),e.if(r._`${l}.instancePath === undefined`,()=>e.assign(r._`${l}.instancePath`,(0,r.strConcat)(s.default.instancePath,a.errorPath))),e.assign(r._`${l}.schemaPath`,r.str`${a.errSchemaPath}/${t}`),a.opts.verbose&&(e.assign(r._`${l}.schema`,i),e.assign(r._`${l}.data`,n))})};const l={keyword:new r.Name("keyword"),schemaPath:new r.Name("schemaPath"),params:new r.Name("params"),propertyName:new r.Name("propertyName"),message:new r.Name("message"),schema:new r.Name("schema"),parentSchema:new r.Name("parentSchema")};function c(e,t,i){const{createErrors:n}=e.it;return!1===n?r._`{}`:function(e,t,i={}){const{gen:n,it:o}=e,a=[u(o,i),h(e,i)];return function(e,{params:t,message:i},n){const{keyword:o,data:a,schemaValue:c,it:u}=e,{opts:h,propertyName:d,topSchemaRef:p,schemaPath:g}=u;n.push([l.keyword,o],[l.params,"function"==typeof t?t(e):t||r._`{}`]),h.messages&&n.push([l.message,"function"==typeof i?i(e):i]),h.verbose&&n.push([l.schema,c],[l.parentSchema,r._`${p}${g}`],[s.default.data,a]),d&&n.push([l.propertyName,d])}(e,t,a),n.object(...a)}(e,t,i)}function u({errorPath:e},{instancePath:t}){const i=t?r.str`${e}${(0,n.getErrorPath)(t,n.Type.Str)}`:e;return[s.default.instancePath,(0,r.strConcat)(s.default.instancePath,i)]}function h({keyword:e,it:{errSchemaPath:t}},{schemaPath:i,parentSchema:s}){let o=s?t:r.str`${t}/${e}`;return i&&(o=r.str`${o}${(0,n.getErrorPath)(i,n.Type.Str)}`),[l.schemaPath,o]}},91688(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveSchema=t.getCompilingSchema=t.resolveRef=t.compileSchema=t.SchemaEnv=void 0;const r=i(38994),n=i(74383),s=i(86660),o=i(89008),a=i(67218),l=i(36023);class c{constructor(e){var t;let i;this.refs={},this.dynamicAnchors={},"object"==typeof e.schema&&(i=e.schema),this.schema=e.schema,this.schemaId=e.schemaId,this.root=e.root||this,this.baseId=null!==(t=e.baseId)&&void 0!==t?t:(0,o.normalizeId)(null==i?void 0:i[e.schemaId||"$id"]),this.schemaPath=e.schemaPath,this.localRefs=e.localRefs,this.meta=e.meta,this.$async=null==i?void 0:i.$async,this.refs={}}}function u(e){const t=d.call(this,e);if(t)return t;const i=(0,o.getFullPath)(this.opts.uriResolver,e.root.baseId),{es5:a,lines:c}=this.opts.code,{ownProperties:u}=this.opts,h=new r.CodeGen(this.scope,{es5:a,lines:c,ownProperties:u});let p;e.$async&&(p=h.scopeValue("Error",{ref:n.default,code:r._`require("ajv/dist/runtime/validation_error").default`}));const g=h.scopeName("validate");e.validateName=g;const f={gen:h,allErrors:this.opts.allErrors,data:s.default.data,parentData:s.default.parentData,parentDataProperty:s.default.parentDataProperty,dataNames:[s.default.data],dataPathArr:[r.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:h.scopeValue("schema",!0===this.opts.code.source?{ref:e.schema,code:(0,r.stringify)(e.schema)}:{ref:e.schema}),validateName:g,ValidationError:p,schema:e.schema,schemaEnv:e,rootId:i,baseId:e.baseId||i,schemaPath:r.nil,errSchemaPath:e.schemaPath||(this.opts.jtd?"":"#"),errorPath:r._`""`,opts:this.opts,self:this};let m;try{this._compilations.add(e),(0,l.validateFunctionCode)(f),h.optimize(this.opts.code.optimize);const t=h.toString();m=`${h.scopeRefs(s.default.scope)}return ${t}`,this.opts.code.process&&(m=this.opts.code.process(m,e));const i=new Function(`${s.default.self}`,`${s.default.scope}`,m)(this,this.scope.get());if(this.scope.value(g,{ref:i}),i.errors=null,i.schema=e.schema,i.schemaEnv=e,e.$async&&(i.$async=!0),!0===this.opts.code.source&&(i.source={validateName:g,validateCode:t,scopeValues:h._values}),this.opts.unevaluated){const{props:e,items:t}=f;i.evaluated={props:e instanceof r.Name?void 0:e,items:t instanceof r.Name?void 0:t,dynamicProps:e instanceof r.Name,dynamicItems:t instanceof r.Name},i.source&&(i.source.evaluated=(0,r.stringify)(i.evaluated))}return e.validate=i,e}catch(t){throw delete e.validate,delete e.validateName,m&&this.logger.error("Error compiling schema, function code:",m),t}finally{this._compilations.delete(e)}}function h(e){return(0,o.inlineRef)(e.schema,this.opts.inlineRefs)?e.schema:e.validate?e:u.call(this,e)}function d(e){for(const t of this._compilations)if(p(t,e))return t}function p(e,t){return e.schema===t.schema&&e.root===t.root&&e.baseId===t.baseId}function g(e,t){let i;for(;"string"==typeof(i=this.refs[t]);)t=i;return i||this.schemas[t]||f.call(this,e,t)}function f(e,t){const i=this.opts.uriResolver.parse(t),r=(0,o._getFullPath)(this.opts.uriResolver,i);let n=(0,o.getFullPath)(this.opts.uriResolver,e.baseId,void 0);if(Object.keys(e.schema).length>0&&r===n)return v.call(this,i,e);const s=(0,o.normalizeId)(r),a=this.refs[s]||this.schemas[s];if("string"==typeof a){const t=f.call(this,e,a);if("object"!=typeof(null==t?void 0:t.schema))return;return v.call(this,i,t)}if("object"==typeof(null==a?void 0:a.schema)){if(a.validate||u.call(this,a),s===(0,o.normalizeId)(t)){const{schema:t}=a,{schemaId:i}=this.opts,r=t[i];return r&&(n=(0,o.resolveUrl)(this.opts.uriResolver,n,r)),new c({schema:t,schemaId:i,root:e,baseId:n})}return v.call(this,i,a)}}t.SchemaEnv=c,t.compileSchema=u,t.resolveRef=function(e,t,i){var r;i=(0,o.resolveUrl)(this.opts.uriResolver,t,i);const n=e.refs[i];if(n)return n;let s=g.call(this,e,i);if(void 0===s){const n=null===(r=e.localRefs)||void 0===r?void 0:r[i],{schemaId:o}=this.opts;n&&(s=new c({schema:n,schemaId:o,root:e,baseId:t}))}return void 0!==s?e.refs[i]=h.call(this,s):void 0},t.getCompilingSchema=d,t.resolveSchema=f;const m=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function v(e,{baseId:t,schema:i,root:r}){var n;if("/"!==(null===(n=e.fragment)||void 0===n?void 0:n[0]))return;for(const r of e.fragment.slice(1).split("/")){if("boolean"==typeof i)return;const e=i[(0,a.unescapeFragment)(r)];if(void 0===e)return;const n="object"==typeof(i=e)&&i[this.opts.schemaId];!m.has(r)&&n&&(t=(0,o.resolveUrl)(this.opts.uriResolver,t,n))}let s;if("boolean"!=typeof i&&i.$ref&&!(0,a.schemaHasRulesButRef)(i,this.RULES)){const e=(0,o.resolveUrl)(this.opts.uriResolver,t,i.$ref);s=f.call(this,r,e)}const{schemaId:l}=this.opts;return s=s||new c({schema:i,schemaId:l,root:r,baseId:t}),s.schema!==s.root.schema?s:void 0}},86660(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n={data:new r.Name("data"),valCxt:new r.Name("valCxt"),instancePath:new r.Name("instancePath"),parentData:new r.Name("parentData"),parentDataProperty:new r.Name("parentDataProperty"),rootData:new r.Name("rootData"),dynamicAnchors:new r.Name("dynamicAnchors"),vErrors:new r.Name("vErrors"),errors:new r.Name("errors"),this:new r.Name("this"),self:new r.Name("self"),scope:new r.Name("scope"),json:new r.Name("json"),jsonPos:new r.Name("jsonPos"),jsonLen:new r.Name("jsonLen"),jsonPart:new r.Name("jsonPart")};t.default=n},4220(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(89008);class n extends Error{constructor(e,t,i,n){super(n||`can't resolve reference ${i} from id ${t}`),this.missingRef=(0,r.resolveUrl)(e,t,i),this.missingSchema=(0,r.normalizeId)((0,r.getFullPath)(e,this.missingRef))}}t.default=n},89008(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getSchemaRefs=t.resolveUrl=t.normalizeId=t._getFullPath=t.getFullPath=t.inlineRef=void 0;const r=i(67218),n=i(67371),s=i(50205),o=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);t.inlineRef=function(e,t=!0){return"boolean"==typeof e||(!0===t?!l(e):!!t&&c(e)<=t)};const a=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function l(e){for(const t in e){if(a.has(t))return!0;const i=e[t];if(Array.isArray(i)&&i.some(l))return!0;if("object"==typeof i&&l(i))return!0}return!1}function c(e){let t=0;for(const i in e){if("$ref"===i)return 1/0;if(t++,!o.has(i)&&("object"==typeof e[i]&&(0,r.eachItem)(e[i],e=>t+=c(e)),t===1/0))return 1/0}return t}function u(e,t="",i){!1!==i&&(t=p(t));const r=e.parse(t);return h(e,r)}function h(e,t){return e.serialize(t).split("#")[0]+"#"}t.getFullPath=u,t._getFullPath=h;const d=/#\/?$/;function p(e){return e?e.replace(d,""):""}t.normalizeId=p,t.resolveUrl=function(e,t,i){return i=p(i),e.resolve(t,i)};const g=/^[a-z_][-a-z0-9._]*$/i;t.getSchemaRefs=function(e,t){if("boolean"==typeof e)return{};const{schemaId:i,uriResolver:r}=this.opts,o=p(e[i]||t),a={"":o},l=u(r,o,!1),c={},h=new Set;return s(e,{allKeys:!0},(e,t,r,n)=>{if(void 0===n)return;const s=l+t;let o=a[n];function u(t){const i=this.opts.uriResolver.resolve;if(t=p(o?i(o,t):t),h.has(t))throw f(t);h.add(t);let r=this.refs[t];return"string"==typeof r&&(r=this.refs[r]),"object"==typeof r?d(e,r.schema,t):t!==p(s)&&("#"===t[0]?(d(e,c[t],t),c[t]=e):this.refs[t]=s),t}function m(e){if("string"==typeof e){if(!g.test(e))throw new Error(`invalid anchor "${e}"`);u.call(this,`#${e}`)}}"string"==typeof e[i]&&(o=u.call(this,e[i])),m.call(this,e.$anchor),m.call(this,e.$dynamicAnchor),a[t]=o}),c;function d(e,t,i){if(void 0!==t&&!n(e,t))throw f(i)}function f(e){return new Error(`reference "${e}" resolves to more than one schema`)}}},6247(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getRules=t.isJSONType=void 0;const i=new Set(["string","number","integer","boolean","null","object","array"]);t.isJSONType=function(e){return"string"==typeof e&&i.has(e)},t.getRules=function(){const e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...e,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}},67218(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkStrictMode=t.getErrorPath=t.Type=t.useFunc=t.setEvaluated=t.evaluatedPropsToName=t.mergeEvaluated=t.eachItem=t.unescapeJsonPointer=t.escapeJsonPointer=t.escapeFragment=t.unescapeFragment=t.schemaRefOrVal=t.schemaHasRulesButRef=t.schemaHasRules=t.checkUnknownRules=t.alwaysValidSchema=t.toHash=void 0;const r=i(38994),n=i(28261);function s(e,t=e.schema){const{opts:i,self:r}=e;if(!i.strictSchema)return;if("boolean"==typeof t)return;const n=r.RULES.keywords;for(const i in t)n[i]||g(e,`unknown keyword: "${i}"`)}function o(e,t){if("boolean"==typeof e)return!e;for(const i in e)if(t[i])return!0;return!1}function a(e){return"number"==typeof e?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}function l(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}function c({mergeNames:e,mergeToName:t,mergeValues:i,resultToName:n}){return(s,o,a,l)=>{const c=void 0===a?o:a instanceof r.Name?(o instanceof r.Name?e(s,o,a):t(s,o,a),a):o instanceof r.Name?(t(s,a,o),o):i(o,a);return l!==r.Name||c instanceof r.Name?c:n(s,c)}}function u(e,t){if(!0===t)return e.var("props",!0);const i=e.var("props",r._`{}`);return void 0!==t&&h(e,i,t),i}function h(e,t,i){Object.keys(i).forEach(i=>e.assign(r._`${t}${(0,r.getProperty)(i)}`,!0))}t.toHash=function(e){const t={};for(const i of e)t[i]=!0;return t},t.alwaysValidSchema=function(e,t){return"boolean"==typeof t?t:0===Object.keys(t).length||(s(e,t),!o(t,e.self.RULES.all))},t.checkUnknownRules=s,t.schemaHasRules=o,t.schemaHasRulesButRef=function(e,t){if("boolean"==typeof e)return!e;for(const i in e)if("$ref"!==i&&t.all[i])return!0;return!1},t.schemaRefOrVal=function({topSchemaRef:e,schemaPath:t},i,n,s){if(!s){if("number"==typeof i||"boolean"==typeof i)return i;if("string"==typeof i)return r._`${i}`}return r._`${e}${t}${(0,r.getProperty)(n)}`},t.unescapeFragment=function(e){return l(decodeURIComponent(e))},t.escapeFragment=function(e){return encodeURIComponent(a(e))},t.escapeJsonPointer=a,t.unescapeJsonPointer=l,t.eachItem=function(e,t){if(Array.isArray(e))for(const i of e)t(i);else t(e)},t.mergeEvaluated={props:c({mergeNames:(e,t,i)=>e.if(r._`${i} !== true && ${t} !== undefined`,()=>{e.if(r._`${t} === true`,()=>e.assign(i,!0),()=>e.assign(i,r._`${i} || {}`).code(r._`Object.assign(${i}, ${t})`))}),mergeToName:(e,t,i)=>e.if(r._`${i} !== true`,()=>{!0===t?e.assign(i,!0):(e.assign(i,r._`${i} || {}`),h(e,i,t))}),mergeValues:(e,t)=>!0===e||{...e,...t},resultToName:u}),items:c({mergeNames:(e,t,i)=>e.if(r._`${i} !== true && ${t} !== undefined`,()=>e.assign(i,r._`${t} === true ? true : ${i} > ${t} ? ${i} : ${t}`)),mergeToName:(e,t,i)=>e.if(r._`${i} !== true`,()=>e.assign(i,!0===t||r._`${i} > ${t} ? ${i} : ${t}`)),mergeValues:(e,t)=>!0===e||Math.max(e,t),resultToName:(e,t)=>e.var("items",t)})},t.evaluatedPropsToName=u,t.setEvaluated=h;const d={};var p;function g(e,t,i=e.opts.strictSchema){if(i){if(t=`strict mode: ${t}`,!0===i)throw new Error(t);e.self.logger.warn(t)}}t.useFunc=function(e,t){return e.scopeValue("func",{ref:t,code:d[t.code]||(d[t.code]=new n._Code(t.code))})},function(e){e[e.Num=0]="Num",e[e.Str=1]="Str"}(p||(t.Type=p={})),t.getErrorPath=function(e,t,i){if(e instanceof r.Name){const n=t===p.Num;return i?n?r._`"[" + ${e} + "]"`:r._`"['" + ${e} + "']"`:n?r._`"/" + ${e}`:r._`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return i?(0,r.getProperty)(e).toString():"/"+a(e)},t.checkStrictMode=g},238(e,t){"use strict";function i(e,t){return t.rules.some(t=>r(e,t))}function r(e,t){var i;return void 0!==e[t.keyword]||(null===(i=t.definition.implements)||void 0===i?void 0:i.some(t=>void 0!==e[t]))}Object.defineProperty(t,"__esModule",{value:!0}),t.shouldUseRule=t.shouldUseGroup=t.schemaHasRulesForType=void 0,t.schemaHasRulesForType=function({schema:e,self:t},r){const n=t.RULES.types[r];return n&&!0!==n&&i(e,n)},t.shouldUseGroup=i,t.shouldUseRule=r},40564(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.boolOrEmptySchema=t.topBoolOrEmptySchema=void 0;const r=i(28425),n=i(38994),s=i(86660),o={message:"boolean schema is false"};function a(e,t){const{gen:i,data:n}=e,s={gen:i,keyword:"false schema",data:n,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,r.reportError)(s,o,void 0,t)}t.topBoolOrEmptySchema=function(e){const{gen:t,schema:i,validateName:r}=e;!1===i?a(e,!1):"object"==typeof i&&!0===i.$async?t.return(s.default.data):(t.assign(n._`${r}.errors`,null),t.return(!0))},t.boolOrEmptySchema=function(e,t){const{gen:i,schema:r}=e;!1===r?(i.var(t,!1),a(e)):i.var(t,!0)}},26419(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.reportTypeError=t.checkDataTypes=t.checkDataType=t.coerceAndCheckDataType=t.getJSONTypes=t.getSchemaTypes=t.DataType=void 0;const r=i(6247),n=i(238),s=i(28425),o=i(38994),a=i(67218);var l;function c(e){const t=Array.isArray(e)?e:e?[e]:[];if(t.every(r.isJSONType))return t;throw new Error("type must be JSONType or JSONType[]: "+t.join(","))}!function(e){e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong"}(l||(t.DataType=l={})),t.getSchemaTypes=function(e){const t=c(e.type);if(t.includes("null")){if(!1===e.nullable)throw new Error("type: null contradicts nullable: false")}else{if(!t.length&&void 0!==e.nullable)throw new Error('"nullable" cannot be used without "type"');!0===e.nullable&&t.push("null")}return t},t.getJSONTypes=c,t.coerceAndCheckDataType=function(e,t){const{gen:i,data:r,opts:s}=e,a=function(e,t){return t?e.filter(e=>u.has(e)||"array"===t&&"array"===e):[]}(t,s.coerceTypes),c=t.length>0&&!(0===a.length&&1===t.length&&(0,n.schemaHasRulesForType)(e,t[0]));if(c){const n=d(t,r,s.strictNumbers,l.Wrong);i.if(n,()=>{a.length?function(e,t,i){const{gen:r,data:n,opts:s}=e,a=r.let("dataType",o._`typeof ${n}`),l=r.let("coerced",o._`undefined`);"array"===s.coerceTypes&&r.if(o._`${a} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>r.assign(n,o._`${n}[0]`).assign(a,o._`typeof ${n}`).if(d(t,n,s.strictNumbers),()=>r.assign(l,n))),r.if(o._`${l} !== undefined`);for(const e of i)(u.has(e)||"array"===e&&"array"===s.coerceTypes)&&c(e);function c(e){switch(e){case"string":return void r.elseIf(o._`${a} == "number" || ${a} == "boolean"`).assign(l,o._`"" + ${n}`).elseIf(o._`${n} === null`).assign(l,o._`""`);case"number":return void r.elseIf(o._`${a} == "boolean" || ${n} === null
              || (${a} == "string" && ${n} && ${n} == +${n})`).assign(l,o._`+${n}`);case"integer":return void r.elseIf(o._`${a} === "boolean" || ${n} === null
              || (${a} === "string" && ${n} && ${n} == +${n} && !(${n} % 1))`).assign(l,o._`+${n}`);case"boolean":return void r.elseIf(o._`${n} === "false" || ${n} === 0 || ${n} === null`).assign(l,!1).elseIf(o._`${n} === "true" || ${n} === 1`).assign(l,!0);case"null":return r.elseIf(o._`${n} === "" || ${n} === 0 || ${n} === false`),void r.assign(l,null);case"array":r.elseIf(o._`${a} === "string" || ${a} === "number"
              || ${a} === "boolean" || ${n} === null`).assign(l,o._`[${n}]`)}}r.else(),g(e),r.endIf(),r.if(o._`${l} !== undefined`,()=>{r.assign(n,l),function({gen:e,parentData:t,parentDataProperty:i},r){e.if(o._`${t} !== undefined`,()=>e.assign(o._`${t}[${i}]`,r))}(e,l)})}(e,t,a):g(e)})}return c};const u=new Set(["string","number","integer","boolean","null"]);function h(e,t,i,r=l.Correct){const n=r===l.Correct?o.operators.EQ:o.operators.NEQ;let s;switch(e){case"null":return o._`${t} ${n} null`;case"array":s=o._`Array.isArray(${t})`;break;case"object":s=o._`${t} && typeof ${t} == "object" && !Array.isArray(${t})`;break;case"integer":s=a(o._`!(${t} % 1) && !isNaN(${t})`);break;case"number":s=a();break;default:return o._`typeof ${t} ${n} ${e}`}return r===l.Correct?s:(0,o.not)(s);function a(e=o.nil){return(0,o.and)(o._`typeof ${t} == "number"`,e,i?o._`isFinite(${t})`:o.nil)}}function d(e,t,i,r){if(1===e.length)return h(e[0],t,i,r);let n;const s=(0,a.toHash)(e);if(s.array&&s.object){const e=o._`typeof ${t} != "object"`;n=s.null?e:o._`!${t} || ${e}`,delete s.null,delete s.array,delete s.object}else n=o.nil;s.number&&delete s.integer;for(const e in s)n=(0,o.and)(n,h(e,t,i,r));return n}t.checkDataType=h,t.checkDataTypes=d;const p={message:({schema:e})=>`must be ${e}`,params:({schema:e,schemaValue:t})=>"string"==typeof e?o._`{type: ${e}}`:o._`{type: ${t}}`};function g(e){const t=function(e){const{gen:t,data:i,schema:r}=e,n=(0,a.schemaRefOrVal)(e,r,"type");return{gen:t,keyword:"type",data:i,schema:r.type,schemaCode:n,schemaValue:n,parentSchema:r,params:{},it:e}}(e);(0,s.reportError)(t,p)}t.reportTypeError=g},76593(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.assignDefaults=void 0;const r=i(38994),n=i(67218);function s(e,t,i){const{gen:s,compositeRule:o,data:a,opts:l}=e;if(void 0===i)return;const c=r._`${a}${(0,r.getProperty)(t)}`;if(o)return void(0,n.checkStrictMode)(e,`default is ignored for: ${c}`);let u=r._`${c} === undefined`;"empty"===l.useDefaults&&(u=r._`${u} || ${c} === null || ${c} === ""`),s.if(u,r._`${c} = ${(0,r.stringify)(i)}`)}t.assignDefaults=function(e,t){const{properties:i,items:r}=e.schema;if("object"===t&&i)for(const t in i)s(e,t,i[t].default);else"array"===t&&Array.isArray(r)&&r.forEach((t,i)=>s(e,i,t.default))}},36023(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getData=t.KeywordCxt=t.validateFunctionCode=void 0;const r=i(40564),n=i(26419),s=i(238),o=i(26419),a=i(76593),l=i(29820),c=i(3826),u=i(38994),h=i(86660),d=i(89008),p=i(67218),g=i(28425);function f({gen:e,validateName:t,schema:i,schemaEnv:r,opts:n},s){n.code.es5?e.func(t,u._`${h.default.data}, ${h.default.valCxt}`,r.$async,()=>{e.code(u._`"use strict"; ${m(i,n)}`),function(e,t){e.if(h.default.valCxt,()=>{e.var(h.default.instancePath,u._`${h.default.valCxt}.${h.default.instancePath}`),e.var(h.default.parentData,u._`${h.default.valCxt}.${h.default.parentData}`),e.var(h.default.parentDataProperty,u._`${h.default.valCxt}.${h.default.parentDataProperty}`),e.var(h.default.rootData,u._`${h.default.valCxt}.${h.default.rootData}`),t.dynamicRef&&e.var(h.default.dynamicAnchors,u._`${h.default.valCxt}.${h.default.dynamicAnchors}`)},()=>{e.var(h.default.instancePath,u._`""`),e.var(h.default.parentData,u._`undefined`),e.var(h.default.parentDataProperty,u._`undefined`),e.var(h.default.rootData,h.default.data),t.dynamicRef&&e.var(h.default.dynamicAnchors,u._`{}`)})}(e,n),e.code(s)}):e.func(t,u._`${h.default.data}, ${function(e){return u._`{${h.default.instancePath}="", ${h.default.parentData}, ${h.default.parentDataProperty}, ${h.default.rootData}=${h.default.data}${e.dynamicRef?u._`, ${h.default.dynamicAnchors}={}`:u.nil}}={}`}(n)}`,r.$async,()=>e.code(m(i,n)).code(s))}function m(e,t){const i="object"==typeof e&&e[t.schemaId];return i&&(t.code.source||t.code.process)?u._`/*# sourceURL=${i} */`:u.nil}function v({schema:e,self:t}){if("boolean"==typeof e)return!e;for(const i in e)if(t.RULES.all[i])return!0;return!1}function C(e){return"boolean"!=typeof e.schema}function y(e){(0,p.checkUnknownRules)(e),function(e){const{schema:t,errSchemaPath:i,opts:r,self:n}=e;t.$ref&&r.ignoreKeywordsWithRef&&(0,p.schemaHasRulesButRef)(t,n.RULES)&&n.logger.warn(`$ref: keywords ignored in schema at path "${i}"`)}(e)}function w(e,t){if(e.opts.jtd)return b(e,[],!1,t);const i=(0,n.getSchemaTypes)(e.schema);b(e,i,!(0,n.coerceAndCheckDataType)(e,i),t)}function S({gen:e,schemaEnv:t,schema:i,errSchemaPath:r,opts:n}){const s=i.$comment;if(!0===n.$comment)e.code(u._`${h.default.self}.logger.log(${s})`);else if("function"==typeof n.$comment){const i=u.str`${r}/$comment`,n=e.scopeValue("root",{ref:t.root});e.code(u._`${h.default.self}.opts.$comment(${s}, ${i}, ${n}.schema)`)}}function b(e,t,i,r){const{gen:n,schema:a,data:l,allErrors:c,opts:d,self:g}=e,{RULES:f}=g;function m(p){(0,s.shouldUseGroup)(a,p)&&(p.type?(n.if((0,o.checkDataType)(p.type,l,d.strictNumbers)),E(e,p),1===t.length&&t[0]===p.type&&i&&(n.else(),(0,o.reportTypeError)(e)),n.endIf()):E(e,p),c||n.if(u._`${h.default.errors} === ${r||0}`))}!a.$ref||!d.ignoreKeywordsWithRef&&(0,p.schemaHasRulesButRef)(a,f)?(d.jtd||function(e,t){!e.schemaEnv.meta&&e.opts.strictTypes&&(function(e,t){t.length&&(e.dataTypes.length?(t.forEach(t=>{A(e.dataTypes,t)||T(e,`type "${t}" not allowed by context "${e.dataTypes.join(",")}"`)}),function(e,t){const i=[];for(const r of e.dataTypes)A(t,r)?i.push(r):t.includes("integer")&&"number"===r&&i.push("integer");e.dataTypes=i}(e,t)):e.dataTypes=t)}(e,t),e.opts.allowUnionTypes||function(e,t){t.length>1&&(2!==t.length||!t.includes("null"))&&T(e,"use allowUnionTypes to allow union type keyword")}(e,t),function(e,t){const i=e.self.RULES.all;for(const r in i){const n=i[r];if("object"==typeof n&&(0,s.shouldUseRule)(e.schema,n)){const{type:i}=n.definition;i.length&&!i.some(e=>{return r=e,(i=t).includes(r)||"number"===r&&i.includes("integer");var i,r})&&T(e,`missing type "${i.join(",")}" for keyword "${r}"`)}}}(e,e.dataTypes))}(e,t),n.block(()=>{for(const e of f.rules)m(e);m(f.post)})):n.block(()=>R(e,"$ref",f.all.$ref.definition))}function E(e,t){const{gen:i,schema:r,opts:{useDefaults:n}}=e;n&&(0,a.assignDefaults)(e,t.type),i.block(()=>{for(const i of t.rules)(0,s.shouldUseRule)(r,i)&&R(e,i.keyword,i.definition,t.type)})}function A(e,t){return e.includes(t)||"integer"===t&&e.includes("number")}function T(e,t){t+=` at "${e.schemaEnv.baseId+e.errSchemaPath}" (strictTypes)`,(0,p.checkStrictMode)(e,t,e.opts.strictTypes)}t.validateFunctionCode=function(e){C(e)&&(y(e),v(e))?function(e){const{schema:t,opts:i,gen:r}=e;f(e,()=>{i.$comment&&t.$comment&&S(e),function(e){const{schema:t,opts:i}=e;void 0!==t.default&&i.useDefaults&&i.strictSchema&&(0,p.checkStrictMode)(e,"default is ignored in the schema root")}(e),r.let(h.default.vErrors,null),r.let(h.default.errors,0),i.unevaluated&&function(e){const{gen:t,validateName:i}=e;e.evaluated=t.const("evaluated",u._`${i}.evaluated`),t.if(u._`${e.evaluated}.dynamicProps`,()=>t.assign(u._`${e.evaluated}.props`,u._`undefined`)),t.if(u._`${e.evaluated}.dynamicItems`,()=>t.assign(u._`${e.evaluated}.items`,u._`undefined`))}(e),w(e),function(e){const{gen:t,schemaEnv:i,validateName:r,ValidationError:n,opts:s}=e;i.$async?t.if(u._`${h.default.errors} === 0`,()=>t.return(h.default.data),()=>t.throw(u._`new ${n}(${h.default.vErrors})`)):(t.assign(u._`${r}.errors`,h.default.vErrors),s.unevaluated&&function({gen:e,evaluated:t,props:i,items:r}){i instanceof u.Name&&e.assign(u._`${t}.props`,i),r instanceof u.Name&&e.assign(u._`${t}.items`,r)}(e),t.return(u._`${h.default.errors} === 0`))}(e)})}(e):f(e,()=>(0,r.topBoolOrEmptySchema)(e))};class M{constructor(e,t,i){if((0,l.validateKeywordUsage)(e,t,i),this.gen=e.gen,this.allErrors=e.allErrors,this.keyword=i,this.data=e.data,this.schema=e.schema[i],this.$data=t.$data&&e.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,p.schemaRefOrVal)(e,this.schema,i,this.$data),this.schemaType=t.schemaType,this.parentSchema=e.schema,this.params={},this.it=e,this.def=t,this.$data)this.schemaCode=e.gen.const("vSchema",x(this.$data,e));else if(this.schemaCode=this.schemaValue,!(0,l.validSchemaType)(this.schema,t.schemaType,t.allowUndefined))throw new Error(`${i} value must be ${JSON.stringify(t.schemaType)}`);("code"in t?t.trackErrors:!1!==t.errors)&&(this.errsCount=e.gen.const("_errs",h.default.errors))}result(e,t,i){this.failResult((0,u.not)(e),t,i)}failResult(e,t,i){this.gen.if(e),i?i():this.error(),t?(this.gen.else(),t(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(e,t){this.failResult((0,u.not)(e),void 0,t)}fail(e){if(void 0===e)return this.error(),void(this.allErrors||this.gen.if(!1));this.gen.if(e),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(e){if(!this.$data)return this.fail(e);const{schemaCode:t}=this;this.fail(u._`${t} !== undefined && (${(0,u.or)(this.invalid$data(),e)})`)}error(e,t,i){if(t)return this.setParams(t),this._error(e,i),void this.setParams({});this._error(e,i)}_error(e,t){(e?g.reportExtraError:g.reportError)(this,this.def.error,t)}$dataError(){(0,g.reportError)(this,this.def.$dataError||g.keyword$DataError)}reset(){if(void 0===this.errsCount)throw new Error('add "trackErrors" to keyword definition');(0,g.resetErrorsCount)(this.gen,this.errsCount)}ok(e){this.allErrors||this.gen.if(e)}setParams(e,t){t?Object.assign(this.params,e):this.params=e}block$data(e,t,i=u.nil){this.gen.block(()=>{this.check$data(e,i),t()})}check$data(e=u.nil,t=u.nil){if(!this.$data)return;const{gen:i,schemaCode:r,schemaType:n,def:s}=this;i.if((0,u.or)(u._`${r} === undefined`,t)),e!==u.nil&&i.assign(e,!0),(n.length||s.validateSchema)&&(i.elseIf(this.invalid$data()),this.$dataError(),e!==u.nil&&i.assign(e,!1)),i.else()}invalid$data(){const{gen:e,schemaCode:t,schemaType:i,def:r,it:n}=this;return(0,u.or)(function(){if(i.length){if(!(t instanceof u.Name))throw new Error("ajv implementation error");const e=Array.isArray(i)?i:[i];return u._`${(0,o.checkDataTypes)(e,t,n.opts.strictNumbers,o.DataType.Wrong)}`}return u.nil}(),function(){if(r.validateSchema){const i=e.scopeValue("validate$data",{ref:r.validateSchema});return u._`!${i}(${t})`}return u.nil}())}subschema(e,t){const i=(0,c.getSubschema)(this.it,e);(0,c.extendSubschemaData)(i,this.it,e),(0,c.extendSubschemaMode)(i,e);const n={...this.it,...i,items:void 0,props:void 0};return function(e,t){C(e)&&(y(e),v(e))?function(e,t){const{schema:i,gen:r,opts:n}=e;n.$comment&&i.$comment&&S(e),function(e){const t=e.schema[e.opts.schemaId];t&&(e.baseId=(0,d.resolveUrl)(e.opts.uriResolver,e.baseId,t))}(e),function(e){if(e.schema.$async&&!e.schemaEnv.$async)throw new Error("async schema in sync schema")}(e);const s=r.const("_errs",h.default.errors);w(e,s),r.var(t,u._`${s} === ${h.default.errors}`)}(e,t):(0,r.boolOrEmptySchema)(e,t)}(n,t),n}mergeEvaluated(e,t){const{it:i,gen:r}=this;i.opts.unevaluated&&(!0!==i.props&&void 0!==e.props&&(i.props=p.mergeEvaluated.props(r,e.props,i.props,t)),!0!==i.items&&void 0!==e.items&&(i.items=p.mergeEvaluated.items(r,e.items,i.items,t)))}mergeValidEvaluated(e,t){const{it:i,gen:r}=this;if(i.opts.unevaluated&&(!0!==i.props||!0!==i.items))return r.if(t,()=>this.mergeEvaluated(e,u.Name)),!0}}function R(e,t,i,r){const n=new M(e,i,t);"code"in i?i.code(n,r):n.$data&&i.validate?(0,l.funcKeywordCode)(n,i):"macro"in i?(0,l.macroKeywordCode)(n,i):(i.compile||i.validate)&&(0,l.funcKeywordCode)(n,i)}t.KeywordCxt=M;const _=/^\/(?:[^~]|~0|~1)*$/,P=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function x(e,{dataLevel:t,dataNames:i,dataPathArr:r}){let n,s;if(""===e)return h.default.rootData;if("/"===e[0]){if(!_.test(e))throw new Error(`Invalid JSON-pointer: ${e}`);n=e,s=h.default.rootData}else{const o=P.exec(e);if(!o)throw new Error(`Invalid JSON-pointer: ${e}`);const a=+o[1];if(n=o[2],"#"===n){if(a>=t)throw new Error(l("property/index",a));return r[t-a]}if(a>t)throw new Error(l("data",a));if(s=i[t-a],!n)return s}let o=s;const a=n.split("/");for(const e of a)e&&(s=u._`${s}${(0,u.getProperty)((0,p.unescapeJsonPointer)(e))}`,o=u._`${o} && ${s}`);return o;function l(e,i){return`Cannot access ${e} ${i} levels up, current level is ${t}`}}t.getData=x},29820(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateKeywordUsage=t.validSchemaType=t.funcKeywordCode=t.macroKeywordCode=void 0;const r=i(38994),n=i(86660),s=i(24954),o=i(28425);function a(e){const{gen:t,data:i,it:n}=e;t.if(n.parentData,()=>t.assign(i,r._`${n.parentData}[${n.parentDataProperty}]`))}function l(e,t,i){if(void 0===i)throw new Error(`keyword "${t}" failed to compile`);return e.scopeValue("keyword","function"==typeof i?{ref:i}:{ref:i,code:(0,r.stringify)(i)})}t.macroKeywordCode=function(e,t){const{gen:i,keyword:n,schema:s,parentSchema:o,it:a}=e,c=t.macro.call(a.self,s,o,a),u=l(i,n,c);!1!==a.opts.validateSchema&&a.self.validateSchema(c,!0);const h=i.name("valid");e.subschema({schema:c,schemaPath:r.nil,errSchemaPath:`${a.errSchemaPath}/${n}`,topSchemaRef:u,compositeRule:!0},h),e.pass(h,()=>e.error(!0))},t.funcKeywordCode=function(e,t){var i;const{gen:c,keyword:u,schema:h,parentSchema:d,$data:p,it:g}=e;!function({schemaEnv:e},t){if(t.async&&!e.$async)throw new Error("async keyword in sync schema")}(g,t);const f=!p&&t.compile?t.compile.call(g.self,h,d,g):t.validate,m=l(c,u,f),v=c.let("valid");function C(i=(t.async?r._`await `:r.nil)){const o=g.opts.passContext?n.default.this:n.default.self,a=!("compile"in t&&!p||!1===t.schema);c.assign(v,r._`${i}${(0,s.callValidateCode)(e,m,o,a)}`,t.modifying)}function y(e){var i;c.if((0,r.not)(null!==(i=t.valid)&&void 0!==i?i:v),e)}e.block$data(v,function(){if(!1===t.errors)C(),t.modifying&&a(e),y(()=>e.error());else{const i=t.async?function(){const e=c.let("ruleErrs",null);return c.try(()=>C(r._`await `),t=>c.assign(v,!1).if(r._`${t} instanceof ${g.ValidationError}`,()=>c.assign(e,r._`${t}.errors`),()=>c.throw(t))),e}():function(){const e=r._`${m}.errors`;return c.assign(e,null),C(r.nil),e}();t.modifying&&a(e),y(()=>function(e,t){const{gen:i}=e;i.if(r._`Array.isArray(${t})`,()=>{i.assign(n.default.vErrors,r._`${n.default.vErrors} === null ? ${t} : ${n.default.vErrors}.concat(${t})`).assign(n.default.errors,r._`${n.default.vErrors}.length`),(0,o.extendErrors)(e)},()=>e.error())}(e,i))}}),e.ok(null!==(i=t.valid)&&void 0!==i?i:v)},t.validSchemaType=function(e,t,i=!1){return!t.length||t.some(t=>"array"===t?Array.isArray(e):"object"===t?e&&"object"==typeof e&&!Array.isArray(e):typeof e==t||i&&void 0===e)},t.validateKeywordUsage=function({schema:e,opts:t,self:i,errSchemaPath:r},n,s){if(Array.isArray(n.keyword)?!n.keyword.includes(s):n.keyword!==s)throw new Error("ajv implementation error");const o=n.dependencies;if(null==o?void 0:o.some(t=>!Object.prototype.hasOwnProperty.call(e,t)))throw new Error(`parent schema must have dependencies of ${s}: ${o.join(",")}`);if(n.validateSchema&&!n.validateSchema(e[s])){const e=`keyword "${s}" value is invalid at path "${r}": `+i.errorsText(n.validateSchema.errors);if("log"!==t.validateSchema)throw new Error(e);i.logger.error(e)}}},3826(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.extendSubschemaMode=t.extendSubschemaData=t.getSubschema=void 0;const r=i(38994),n=i(67218);t.getSubschema=function(e,{keyword:t,schemaProp:i,schema:s,schemaPath:o,errSchemaPath:a,topSchemaRef:l}){if(void 0!==t&&void 0!==s)throw new Error('both "keyword" and "schema" passed, only one allowed');if(void 0!==t){const s=e.schema[t];return void 0===i?{schema:s,schemaPath:r._`${e.schemaPath}${(0,r.getProperty)(t)}`,errSchemaPath:`${e.errSchemaPath}/${t}`}:{schema:s[i],schemaPath:r._`${e.schemaPath}${(0,r.getProperty)(t)}${(0,r.getProperty)(i)}`,errSchemaPath:`${e.errSchemaPath}/${t}/${(0,n.escapeFragment)(i)}`}}if(void 0!==s){if(void 0===o||void 0===a||void 0===l)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:s,schemaPath:o,topSchemaRef:l,errSchemaPath:a}}throw new Error('either "keyword" or "schema" must be passed')},t.extendSubschemaData=function(e,t,{dataProp:i,dataPropType:s,data:o,dataTypes:a,propertyName:l}){if(void 0!==o&&void 0!==i)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:c}=t;if(void 0!==i){const{errorPath:o,dataPathArr:a,opts:l}=t;u(c.let("data",r._`${t.data}${(0,r.getProperty)(i)}`,!0)),e.errorPath=r.str`${o}${(0,n.getErrorPath)(i,s,l.jsPropertySyntax)}`,e.parentDataProperty=r._`${i}`,e.dataPathArr=[...a,e.parentDataProperty]}function u(i){e.data=i,e.dataLevel=t.dataLevel+1,e.dataTypes=[],t.definedProperties=new Set,e.parentData=t.data,e.dataNames=[...t.dataNames,i]}void 0!==o&&(u(o instanceof r.Name?o:c.let("data",o,!0)),void 0!==l&&(e.propertyName=l)),a&&(e.dataTypes=a)},t.extendSubschemaMode=function(e,{jtdDiscriminator:t,jtdMetadata:i,compositeRule:r,createErrors:n,allErrors:s}){void 0!==r&&(e.compositeRule=r),void 0!==n&&(e.createErrors=n),void 0!==s&&(e.allErrors=s),e.jtdDiscriminator=t,e.jtdMetadata=i}},51967(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=void 0;var r=i(36023);Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return r.KeywordCxt}});var n=i(38994);Object.defineProperty(t,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return n.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return n.CodeGen}});const s=i(74383),o=i(4220),a=i(6247),l=i(91688),c=i(38994),u=i(89008),h=i(26419),d=i(67218),p=i(10114),g=i(18951),f=(e,t)=>new RegExp(e,t);f.code="new RegExp";const m=["removeAdditional","useDefaults","coerceTypes"],v=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),C={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},y={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'};function w(e){var t,i,r,n,s,o,a,l,c,u,h,d,p,m,v,C,y,w,S,b,E,A,T,M,R;const _=e.strict,P=null===(t=e.code)||void 0===t?void 0:t.optimize,x=!0===P||void 0===P?1:P||0,D=null!==(r=null===(i=e.code)||void 0===i?void 0:i.regExp)&&void 0!==r?r:f,I=null!==(n=e.uriResolver)&&void 0!==n?n:g.default;return{strictSchema:null===(o=null!==(s=e.strictSchema)&&void 0!==s?s:_)||void 0===o||o,strictNumbers:null===(l=null!==(a=e.strictNumbers)&&void 0!==a?a:_)||void 0===l||l,strictTypes:null!==(u=null!==(c=e.strictTypes)&&void 0!==c?c:_)&&void 0!==u?u:"log",strictTuples:null!==(d=null!==(h=e.strictTuples)&&void 0!==h?h:_)&&void 0!==d?d:"log",strictRequired:null!==(m=null!==(p=e.strictRequired)&&void 0!==p?p:_)&&void 0!==m&&m,code:e.code?{...e.code,optimize:x,regExp:D}:{optimize:x,regExp:D},loopRequired:null!==(v=e.loopRequired)&&void 0!==v?v:200,loopEnum:null!==(C=e.loopEnum)&&void 0!==C?C:200,meta:null===(y=e.meta)||void 0===y||y,messages:null===(w=e.messages)||void 0===w||w,inlineRefs:null===(S=e.inlineRefs)||void 0===S||S,schemaId:null!==(b=e.schemaId)&&void 0!==b?b:"$id",addUsedSchema:null===(E=e.addUsedSchema)||void 0===E||E,validateSchema:null===(A=e.validateSchema)||void 0===A||A,validateFormats:null===(T=e.validateFormats)||void 0===T||T,unicodeRegExp:null===(M=e.unicodeRegExp)||void 0===M||M,int32range:null===(R=e.int32range)||void 0===R||R,uriResolver:I}}class S{constructor(e={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,e=this.opts={...e,...w(e)};const{es5:t,lines:i}=this.opts.code;this.scope=new c.ValueScope({scope:{},prefixes:v,es5:t,lines:i}),this.logger=function(e){if(!1===e)return _;if(void 0===e)return console;if(e.log&&e.warn&&e.error)return e;throw new Error("logger must implement log, warn and error methods")}(e.logger);const r=e.validateFormats;e.validateFormats=!1,this.RULES=(0,a.getRules)(),b.call(this,C,e,"NOT SUPPORTED"),b.call(this,y,e,"DEPRECATED","warn"),this._metaOpts=R.call(this),e.formats&&T.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),e.keywords&&M.call(this,e.keywords),"object"==typeof e.meta&&this.addMetaSchema(e.meta),A.call(this),e.validateFormats=r}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:e,meta:t,schemaId:i}=this.opts;let r=p;"id"===i&&(r={...p},r.id=r.$id,delete r.$id),t&&e&&this.addMetaSchema(r,r[i],!1)}defaultMeta(){const{meta:e,schemaId:t}=this.opts;return this.opts.defaultMeta="object"==typeof e?e[t]||e:void 0}validate(e,t){let i;if("string"==typeof e){if(i=this.getSchema(e),!i)throw new Error(`no schema with key or ref "${e}"`)}else i=this.compile(e);const r=i(t);return"$async"in i||(this.errors=i.errors),r}compile(e,t){const i=this._addSchema(e,t);return i.validate||this._compileSchemaEnv(i)}compileAsync(e,t){if("function"!=typeof this.opts.loadSchema)throw new Error("options.loadSchema should be a function");const{loadSchema:i}=this.opts;return r.call(this,e,t);async function r(e,t){await n.call(this,e.$schema);const i=this._addSchema(e,t);return i.validate||s.call(this,i)}async function n(e){e&&!this.getSchema(e)&&await r.call(this,{$ref:e},!0)}async function s(e){try{return this._compileSchemaEnv(e)}catch(t){if(!(t instanceof o.default))throw t;return a.call(this,t),await l.call(this,t.missingSchema),s.call(this,e)}}function a({missingSchema:e,missingRef:t}){if(this.refs[e])throw new Error(`AnySchema ${e} is loaded but ${t} cannot be resolved`)}async function l(e){const i=await c.call(this,e);this.refs[e]||await n.call(this,i.$schema),this.refs[e]||this.addSchema(i,e,t)}async function c(e){const t=this._loading[e];if(t)return t;try{return await(this._loading[e]=i(e))}finally{delete this._loading[e]}}}addSchema(e,t,i,r=this.opts.validateSchema){if(Array.isArray(e)){for(const t of e)this.addSchema(t,void 0,i,r);return this}let n;if("object"==typeof e){const{schemaId:t}=this.opts;if(n=e[t],void 0!==n&&"string"!=typeof n)throw new Error(`schema ${t} must be string`)}return t=(0,u.normalizeId)(t||n),this._checkUnique(t),this.schemas[t]=this._addSchema(e,i,t,r,!0),this}addMetaSchema(e,t,i=this.opts.validateSchema){return this.addSchema(e,t,!0,i),this}validateSchema(e,t){if("boolean"==typeof e)return!0;let i;if(i=e.$schema,void 0!==i&&"string"!=typeof i)throw new Error("$schema must be a string");if(i=i||this.opts.defaultMeta||this.defaultMeta(),!i)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const r=this.validate(i,e);if(!r&&t){const e="schema is invalid: "+this.errorsText();if("log"!==this.opts.validateSchema)throw new Error(e);this.logger.error(e)}return r}getSchema(e){let t;for(;"string"==typeof(t=E.call(this,e));)e=t;if(void 0===t){const{schemaId:i}=this.opts,r=new l.SchemaEnv({schema:{},schemaId:i});if(t=l.resolveSchema.call(this,r,e),!t)return;this.refs[e]=t}return t.validate||this._compileSchemaEnv(t)}removeSchema(e){if(e instanceof RegExp)return this._removeAllSchemas(this.schemas,e),this._removeAllSchemas(this.refs,e),this;switch(typeof e){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const t=E.call(this,e);return"object"==typeof t&&this._cache.delete(t.schema),delete this.schemas[e],delete this.refs[e],this}case"object":{const t=e;this._cache.delete(t);let i=e[this.opts.schemaId];return i&&(i=(0,u.normalizeId)(i),delete this.schemas[i],delete this.refs[i]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(e){for(const t of e)this.addKeyword(t);return this}addKeyword(e,t){let i;if("string"==typeof e)i=e,"object"==typeof t&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),t.keyword=i);else{if("object"!=typeof e||void 0!==t)throw new Error("invalid addKeywords parameters");if(i=(t=e).keyword,Array.isArray(i)&&!i.length)throw new Error("addKeywords: keyword must be string or non-empty array")}if(x.call(this,i,t),!t)return(0,d.eachItem)(i,e=>D.call(this,e)),this;L.call(this,t);const r={...t,type:(0,h.getJSONTypes)(t.type),schemaType:(0,h.getJSONTypes)(t.schemaType)};return(0,d.eachItem)(i,0===r.type.length?e=>D.call(this,e,r):e=>r.type.forEach(t=>D.call(this,e,r,t))),this}getKeyword(e){const t=this.RULES.all[e];return"object"==typeof t?t.definition:!!t}removeKeyword(e){const{RULES:t}=this;delete t.keywords[e],delete t.all[e];for(const i of t.rules){const t=i.rules.findIndex(t=>t.keyword===e);t>=0&&i.rules.splice(t,1)}return this}addFormat(e,t){return"string"==typeof t&&(t=new RegExp(t)),this.formats[e]=t,this}errorsText(e=this.errors,{separator:t=", ",dataVar:i="data"}={}){return e&&0!==e.length?e.map(e=>`${i}${e.instancePath} ${e.message}`).reduce((e,i)=>e+t+i):"No errors"}$dataMetaSchema(e,t){const i=this.RULES.all;e=JSON.parse(JSON.stringify(e));for(const r of t){const t=r.split("/").slice(1);let n=e;for(const e of t)n=n[e];for(const e in i){const t=i[e];if("object"!=typeof t)continue;const{$data:r}=t.definition,s=n[e];r&&s&&(n[e]=O(s))}}return e}_removeAllSchemas(e,t){for(const i in e){const r=e[i];t&&!t.test(i)||("string"==typeof r?delete e[i]:r&&!r.meta&&(this._cache.delete(r.schema),delete e[i]))}}_addSchema(e,t,i,r=this.opts.validateSchema,n=this.opts.addUsedSchema){let s;const{schemaId:o}=this.opts;if("object"==typeof e)s=e[o];else{if(this.opts.jtd)throw new Error("schema must be object");if("boolean"!=typeof e)throw new Error("schema must be object or boolean")}let a=this._cache.get(e);if(void 0!==a)return a;i=(0,u.normalizeId)(s||i);const c=u.getSchemaRefs.call(this,e,i);return a=new l.SchemaEnv({schema:e,schemaId:o,meta:t,baseId:i,localRefs:c}),this._cache.set(a.schema,a),n&&!i.startsWith("#")&&(i&&this._checkUnique(i),this.refs[i]=a),r&&this.validateSchema(e,!0),a}_checkUnique(e){if(this.schemas[e]||this.refs[e])throw new Error(`schema with key or id "${e}" already exists`)}_compileSchemaEnv(e){if(e.meta?this._compileMetaSchema(e):l.compileSchema.call(this,e),!e.validate)throw new Error("ajv implementation error");return e.validate}_compileMetaSchema(e){const t=this.opts;this.opts=this._metaOpts;try{l.compileSchema.call(this,e)}finally{this.opts=t}}}function b(e,t,i,r="error"){for(const n in e){const s=n;s in t&&this.logger[r](`${i}: option ${n}. ${e[s]}`)}}function E(e){return e=(0,u.normalizeId)(e),this.schemas[e]||this.refs[e]}function A(){const e=this.opts.schemas;if(e)if(Array.isArray(e))this.addSchema(e);else for(const t in e)this.addSchema(e[t],t)}function T(){for(const e in this.opts.formats){const t=this.opts.formats[e];t&&this.addFormat(e,t)}}function M(e){if(Array.isArray(e))this.addVocabulary(e);else{this.logger.warn("keywords option as map is deprecated, pass array");for(const t in e){const i=e[t];i.keyword||(i.keyword=t),this.addKeyword(i)}}}function R(){const e={...this.opts};for(const t of m)delete e[t];return e}S.ValidationError=s.default,S.MissingRefError=o.default,t.default=S;const _={log(){},warn(){},error(){}},P=/^[a-z_$][a-z0-9_$:-]*$/i;function x(e,t){const{RULES:i}=this;if((0,d.eachItem)(e,e=>{if(i.keywords[e])throw new Error(`Keyword ${e} is already defined`);if(!P.test(e))throw new Error(`Keyword ${e} has invalid name`)}),t&&t.$data&&!("code"in t)&&!("validate"in t))throw new Error('$data keyword must have "code" or "validate" function')}function D(e,t,i){var r;const n=null==t?void 0:t.post;if(i&&n)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:s}=this;let o=n?s.post:s.rules.find(({type:e})=>e===i);if(o||(o={type:i,rules:[]},s.rules.push(o)),s.keywords[e]=!0,!t)return;const a={keyword:e,definition:{...t,type:(0,h.getJSONTypes)(t.type),schemaType:(0,h.getJSONTypes)(t.schemaType)}};t.before?I.call(this,o,a,t.before):o.rules.push(a),s.all[e]=a,null===(r=t.implements)||void 0===r||r.forEach(e=>this.addKeyword(e))}function I(e,t,i){const r=e.rules.findIndex(e=>e.keyword===i);r>=0?e.rules.splice(r,0,t):(e.rules.push(t),this.logger.warn(`rule ${i} is not defined`))}function L(e){let{metaSchema:t}=e;void 0!==t&&(e.$data&&this.opts.$data&&(t=O(t)),e.validateSchema=this.compile(t,!0))}const N={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function O(e){return{anyOf:[e,N]}}},6013(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(67371);r.code='require("ajv/dist/runtime/equal").default',t.default=r},25532(e,t){"use strict";function i(e){const t=e.length;let i,r=0,n=0;for(;n<t;)r++,i=e.charCodeAt(n++),i>=55296&&i<=56319&&n<t&&(i=e.charCodeAt(n),56320==(64512&i)&&n++);return r}Object.defineProperty(t,"__esModule",{value:!0}),t.default=i,i.code='require("ajv/dist/runtime/ucs2length").default'},18951(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(58041);r.code='require("ajv/dist/runtime/uri").default',t.default=r},74383(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});class i extends Error{constructor(e){super("validation failed"),this.errors=e,this.ajv=this.validation=!0}}t.default=i},30714(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateAdditionalItems=void 0;const r=i(38994),n=i(67218),s={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:e}})=>r.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>r._`{limit: ${e}}`},code(e){const{parentSchema:t,it:i}=e,{items:r}=t;Array.isArray(r)?o(e,r):(0,n.checkStrictMode)(i,'"additionalItems" is ignored when "items" is not an array of schemas')}};function o(e,t){const{gen:i,schema:s,data:o,keyword:a,it:l}=e;l.items=!0;const c=i.const("len",r._`${o}.length`);if(!1===s)e.setParams({len:t.length}),e.pass(r._`${c} <= ${t.length}`);else if("object"==typeof s&&!(0,n.alwaysValidSchema)(l,s)){const s=i.var("valid",r._`${c} <= ${t.length}`);i.if((0,r.not)(s),()=>function(s){i.forRange("i",t.length,c,t=>{e.subschema({keyword:a,dataProp:t,dataPropType:n.Type.Num},s),l.allErrors||i.if((0,r.not)(s),()=>i.break())})}(s)),e.ok(s)}}t.validateAdditionalItems=o,t.default=s},88401(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(24954),n=i(38994),s=i(86660),o=i(67218),a={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:e})=>n._`{additionalProperty: ${e.additionalProperty}}`},code(e){const{gen:t,schema:i,parentSchema:a,data:l,errsCount:c,it:u}=e;if(!c)throw new Error("ajv implementation error");const{allErrors:h,opts:d}=u;if(u.props=!0,"all"!==d.removeAdditional&&(0,o.alwaysValidSchema)(u,i))return;const p=(0,r.allSchemaProperties)(a.properties),g=(0,r.allSchemaProperties)(a.patternProperties);function f(e){t.code(n._`delete ${l}[${e}]`)}function m(r){if("all"===d.removeAdditional||d.removeAdditional&&!1===i)f(r);else{if(!1===i)return e.setParams({additionalProperty:r}),e.error(),void(h||t.break());if("object"==typeof i&&!(0,o.alwaysValidSchema)(u,i)){const i=t.name("valid");"failing"===d.removeAdditional?(v(r,i,!1),t.if((0,n.not)(i),()=>{e.reset(),f(r)})):(v(r,i),h||t.if((0,n.not)(i),()=>t.break()))}}}function v(t,i,r){const n={keyword:"additionalProperties",dataProp:t,dataPropType:o.Type.Str};!1===r&&Object.assign(n,{compositeRule:!0,createErrors:!1,allErrors:!1}),e.subschema(n,i)}t.forIn("key",l,i=>{p.length||g.length?t.if(function(i){let s;if(p.length>8){const e=(0,o.schemaRefOrVal)(u,a.properties,"properties");s=(0,r.isOwnProperty)(t,e,i)}else s=p.length?(0,n.or)(...p.map(e=>n._`${i} === ${e}`)):n.nil;return g.length&&(s=(0,n.or)(s,...g.map(t=>n._`${(0,r.usePattern)(e,t)}.test(${i})`))),(0,n.not)(s)}(i),()=>m(i)):m(i)}),e.ok(n._`${c} === ${s.default.errors}`)}};t.default=a},12003(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(67218),n={keyword:"allOf",schemaType:"array",code(e){const{gen:t,schema:i,it:n}=e;if(!Array.isArray(i))throw new Error("ajv implementation error");const s=t.name("valid");i.forEach((t,i)=>{if((0,r.alwaysValidSchema)(n,t))return;const o=e.subschema({keyword:"allOf",schemaProp:i},s);e.ok(s),e.mergeEvaluated(o)})}};t.default=n},21070(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:i(24954).validateUnion,error:{message:"must match a schema in anyOf"}};t.default=r},32692(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:e,max:t}})=>void 0===t?r.str`must contain at least ${e} valid item(s)`:r.str`must contain at least ${e} and no more than ${t} valid item(s)`,params:({params:{min:e,max:t}})=>void 0===t?r._`{minContains: ${e}}`:r._`{minContains: ${e}, maxContains: ${t}}`},code(e){const{gen:t,schema:i,parentSchema:s,data:o,it:a}=e;let l,c;const{minContains:u,maxContains:h}=s;a.opts.next?(l=void 0===u?1:u,c=h):l=1;const d=t.const("len",r._`${o}.length`);if(e.setParams({min:l,max:c}),void 0===c&&0===l)return void(0,n.checkStrictMode)(a,'"minContains" == 0 without "maxContains": "contains" keyword ignored');if(void 0!==c&&l>c)return(0,n.checkStrictMode)(a,'"minContains" > "maxContains" is always invalid'),void e.fail();if((0,n.alwaysValidSchema)(a,i)){let t=r._`${d} >= ${l}`;return void 0!==c&&(t=r._`${t} && ${d} <= ${c}`),void e.pass(t)}a.items=!0;const p=t.name("valid");function g(){const e=t.name("_valid"),i=t.let("count",0);f(e,()=>t.if(e,()=>function(e){t.code(r._`${e}++`),void 0===c?t.if(r._`${e} >= ${l}`,()=>t.assign(p,!0).break()):(t.if(r._`${e} > ${c}`,()=>t.assign(p,!1).break()),1===l?t.assign(p,!0):t.if(r._`${e} >= ${l}`,()=>t.assign(p,!0)))}(i)))}function f(i,r){t.forRange("i",0,d,t=>{e.subschema({keyword:"contains",dataProp:t,dataPropType:n.Type.Num,compositeRule:!0},i),r()})}void 0===c&&1===l?f(p,()=>t.if(p,()=>t.break())):0===l?(t.let(p,!0),void 0!==c&&t.if(r._`${o}.length > 0`,g)):(t.let(p,!1),g()),e.result(p,()=>e.reset())}};t.default=s},15860(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateSchemaDeps=t.validatePropertyDeps=t.error=void 0;const r=i(38994),n=i(67218),s=i(24954);t.error={message:({params:{property:e,depsCount:t,deps:i}})=>{const n=1===t?"property":"properties";return r.str`must have ${n} ${i} when property ${e} is present`},params:({params:{property:e,depsCount:t,deps:i,missingProperty:n}})=>r._`{property: ${e},
    missingProperty: ${n},
    depsCount: ${t},
    deps: ${i}}`};const o={keyword:"dependencies",type:"object",schemaType:"object",error:t.error,code(e){const[t,i]=function({schema:e}){const t={},i={};for(const r in e)"__proto__"!==r&&((Array.isArray(e[r])?t:i)[r]=e[r]);return[t,i]}(e);a(e,t),l(e,i)}};function a(e,t=e.schema){const{gen:i,data:n,it:o}=e;if(0===Object.keys(t).length)return;const a=i.let("missing");for(const l in t){const c=t[l];if(0===c.length)continue;const u=(0,s.propertyInData)(i,n,l,o.opts.ownProperties);e.setParams({property:l,depsCount:c.length,deps:c.join(", ")}),o.allErrors?i.if(u,()=>{for(const t of c)(0,s.checkReportMissingProp)(e,t)}):(i.if(r._`${u} && (${(0,s.checkMissingProp)(e,c,a)})`),(0,s.reportMissingProp)(e,a),i.else())}}function l(e,t=e.schema){const{gen:i,data:r,keyword:o,it:a}=e,l=i.name("valid");for(const c in t)(0,n.alwaysValidSchema)(a,t[c])||(i.if((0,s.propertyInData)(i,r,c,a.opts.ownProperties),()=>{const t=e.subschema({keyword:o,schemaProp:c},l);e.mergeValidEvaluated(t,l)},()=>i.var(l,!0)),e.ok(l))}t.validatePropertyDeps=a,t.validateSchemaDeps=l,t.default=o},8102(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:e})=>r.str`must match "${e.ifClause}" schema`,params:({params:e})=>r._`{failingKeyword: ${e.ifClause}}`},code(e){const{gen:t,parentSchema:i,it:s}=e;void 0===i.then&&void 0===i.else&&(0,n.checkStrictMode)(s,'"if" without "then" and "else" is ignored');const a=o(s,"then"),l=o(s,"else");if(!a&&!l)return;const c=t.let("valid",!0),u=t.name("_valid");if(function(){const t=e.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},u);e.mergeEvaluated(t)}(),e.reset(),a&&l){const i=t.let("ifClause");e.setParams({ifClause:i}),t.if(u,h("then",i),h("else",i))}else a?t.if(u,h("then")):t.if((0,r.not)(u),h("else"));function h(i,n){return()=>{const s=e.subschema({keyword:i},u);t.assign(c,u),e.mergeValidEvaluated(s,c),n?t.assign(n,r._`${i}`):e.setParams({ifClause:i})}}e.pass(c,()=>e.error(!0))}};function o(e,t){const i=e.schema[t];return void 0!==i&&!(0,n.alwaysValidSchema)(e,i)}t.default=s},88313(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(30714),n=i(51997),s=i(23665),o=i(5153),a=i(32692),l=i(15860),c=i(80374),u=i(88401),h=i(23252),d=i(46398),p=i(84948),g=i(21070),f=i(5368),m=i(12003),v=i(8102),C=i(71871);t.default=function(e=!1){const t=[p.default,g.default,f.default,m.default,v.default,C.default,c.default,u.default,l.default,h.default,d.default];return e?t.push(n.default,o.default):t.push(r.default,s.default),t.push(a.default),t}},23665(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateTuple=void 0;const r=i(38994),n=i(67218),s=i(24954),o={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(e){const{schema:t,it:i}=e;if(Array.isArray(t))return a(e,"additionalItems",t);i.items=!0,(0,n.alwaysValidSchema)(i,t)||e.ok((0,s.validateArray)(e))}};function a(e,t,i=e.schema){const{gen:s,parentSchema:o,data:a,keyword:l,it:c}=e;!function(e){const{opts:r,errSchemaPath:s}=c,o=i.length,a=o===e.minItems&&(o===e.maxItems||!1===e[t]);if(r.strictTuples&&!a){const e=`"${l}" is ${o}-tuple, but minItems or maxItems/${t} are not specified or different at path "${s}"`;(0,n.checkStrictMode)(c,e,r.strictTuples)}}(o),c.opts.unevaluated&&i.length&&!0!==c.items&&(c.items=n.mergeEvaluated.items(s,i.length,c.items));const u=s.name("valid"),h=s.const("len",r._`${a}.length`);i.forEach((t,i)=>{(0,n.alwaysValidSchema)(c,t)||(s.if(r._`${h} > ${i}`,()=>e.subschema({keyword:l,schemaProp:i,dataProp:i},u)),e.ok(u))})}t.validateTuple=a,t.default=o},5153(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s=i(24954),o=i(30714),a={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:e}})=>r.str`must NOT have more than ${e} items`,params:({params:{len:e}})=>r._`{limit: ${e}}`},code(e){const{schema:t,parentSchema:i,it:r}=e,{prefixItems:a}=i;r.items=!0,(0,n.alwaysValidSchema)(r,t)||(a?(0,o.validateAdditionalItems)(e,a):e.ok((0,s.validateArray)(e)))}};t.default=a},84948(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(67218),n={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(e){const{gen:t,schema:i,it:n}=e;if((0,r.alwaysValidSchema)(n,i))return void e.fail();const s=t.name("valid");e.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),e.failResult(s,()=>e.reset(),()=>e.error())},error:{message:"must NOT be valid"}};t.default=n},5368(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:e})=>r._`{passingSchemas: ${e.passing}}`},code(e){const{gen:t,schema:i,parentSchema:s,it:o}=e;if(!Array.isArray(i))throw new Error("ajv implementation error");if(o.opts.discriminator&&s.discriminator)return;const a=i,l=t.let("valid",!1),c=t.let("passing",null),u=t.name("_valid");e.setParams({passing:c}),t.block(function(){a.forEach((i,s)=>{let a;(0,n.alwaysValidSchema)(o,i)?t.var(u,!0):a=e.subschema({keyword:"oneOf",schemaProp:s,compositeRule:!0},u),s>0&&t.if(r._`${u} && ${l}`).assign(l,!1).assign(c,r._`[${c}, ${s}]`).else(),t.if(u,()=>{t.assign(l,!0),t.assign(c,s),a&&e.mergeEvaluated(a,r.Name)})})}),e.result(l,()=>e.reset(),()=>e.error(!0))}};t.default=s},46398(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(24954),n=i(38994),s=i(67218),o=i(67218),a={keyword:"patternProperties",type:"object",schemaType:"object",code(e){const{gen:t,schema:i,data:a,parentSchema:l,it:c}=e,{opts:u}=c,h=(0,r.allSchemaProperties)(i),d=h.filter(e=>(0,s.alwaysValidSchema)(c,i[e]));if(0===h.length||d.length===h.length&&(!c.opts.unevaluated||!0===c.props))return;const p=u.strictSchema&&!u.allowMatchingProperties&&l.properties,g=t.name("valid");!0===c.props||c.props instanceof n.Name||(c.props=(0,o.evaluatedPropsToName)(t,c.props));const{props:f}=c;function m(e){for(const t in p)new RegExp(e).test(t)&&(0,s.checkStrictMode)(c,`property ${t} matches pattern ${e} (use allowMatchingProperties)`)}function v(i){t.forIn("key",a,s=>{t.if(n._`${(0,r.usePattern)(e,i)}.test(${s})`,()=>{const r=d.includes(i);r||e.subschema({keyword:"patternProperties",schemaProp:i,dataProp:s,dataPropType:o.Type.Str},g),c.opts.unevaluated&&!0!==f?t.assign(n._`${f}[${s}]`,!0):r||c.allErrors||t.if((0,n.not)(g),()=>t.break())})})}!function(){for(const e of h)p&&m(e),c.allErrors?v(e):(t.var(g,!0),v(e),t.if(g))}()}};t.default=a},51997(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(23665),n={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:e=>(0,r.validateTuple)(e,"items")};t.default=n},23252(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(36023),n=i(24954),s=i(67218),o=i(88401),a={keyword:"properties",type:"object",schemaType:"object",code(e){const{gen:t,schema:i,parentSchema:a,data:l,it:c}=e;"all"===c.opts.removeAdditional&&void 0===a.additionalProperties&&o.default.code(new r.KeywordCxt(c,o.default,"additionalProperties"));const u=(0,n.allSchemaProperties)(i);for(const e of u)c.definedProperties.add(e);c.opts.unevaluated&&u.length&&!0!==c.props&&(c.props=s.mergeEvaluated.props(t,(0,s.toHash)(u),c.props));const h=u.filter(e=>!(0,s.alwaysValidSchema)(c,i[e]));if(0===h.length)return;const d=t.name("valid");for(const i of h)p(i)?g(i):(t.if((0,n.propertyInData)(t,l,i,c.opts.ownProperties)),g(i),c.allErrors||t.else().var(d,!0),t.endIf()),e.it.definedProperties.add(i),e.ok(d);function p(e){return c.opts.useDefaults&&!c.compositeRule&&void 0!==i[e].default}function g(t){e.subschema({keyword:"properties",schemaProp:t,dataProp:t},d)}}};t.default=a},80374(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:e})=>r._`{propertyName: ${e.propertyName}}`},code(e){const{gen:t,schema:i,data:s,it:o}=e;if((0,n.alwaysValidSchema)(o,i))return;const a=t.name("valid");t.forIn("key",s,i=>{e.setParams({propertyName:i}),e.subschema({keyword:"propertyNames",data:i,dataTypes:["string"],propertyName:i,compositeRule:!0},a),t.if((0,r.not)(a),()=>{e.error(!0),o.allErrors||t.break()})}),e.ok(a)}};t.default=s},71871(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(67218),n={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:e,parentSchema:t,it:i}){void 0===t.if&&(0,r.checkStrictMode)(i,`"${e}" without "if" is ignored`)}};t.default=n},24954(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.validateUnion=t.validateArray=t.usePattern=t.callValidateCode=t.schemaProperties=t.allSchemaProperties=t.noPropertyInData=t.propertyInData=t.isOwnProperty=t.hasPropFunc=t.reportMissingProp=t.checkMissingProp=t.checkReportMissingProp=void 0;const r=i(38994),n=i(67218),s=i(86660),o=i(67218);function a(e){return e.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:r._`Object.prototype.hasOwnProperty`})}function l(e,t,i){return r._`${a(e)}.call(${t}, ${i})`}function c(e,t,i,n){const s=r._`${t}${(0,r.getProperty)(i)} === undefined`;return n?(0,r.or)(s,(0,r.not)(l(e,t,i))):s}function u(e){return e?Object.keys(e).filter(e=>"__proto__"!==e):[]}t.checkReportMissingProp=function(e,t){const{gen:i,data:n,it:s}=e;i.if(c(i,n,t,s.opts.ownProperties),()=>{e.setParams({missingProperty:r._`${t}`},!0),e.error()})},t.checkMissingProp=function({gen:e,data:t,it:{opts:i}},n,s){return(0,r.or)(...n.map(n=>(0,r.and)(c(e,t,n,i.ownProperties),r._`${s} = ${n}`)))},t.reportMissingProp=function(e,t){e.setParams({missingProperty:t},!0),e.error()},t.hasPropFunc=a,t.isOwnProperty=l,t.propertyInData=function(e,t,i,n){const s=r._`${t}${(0,r.getProperty)(i)} !== undefined`;return n?r._`${s} && ${l(e,t,i)}`:s},t.noPropertyInData=c,t.allSchemaProperties=u,t.schemaProperties=function(e,t){return u(t).filter(i=>!(0,n.alwaysValidSchema)(e,t[i]))},t.callValidateCode=function({schemaCode:e,data:t,it:{gen:i,topSchemaRef:n,schemaPath:o,errorPath:a},it:l},c,u,h){const d=h?r._`${e}, ${t}, ${n}${o}`:t,p=[[s.default.instancePath,(0,r.strConcat)(s.default.instancePath,a)],[s.default.parentData,l.parentData],[s.default.parentDataProperty,l.parentDataProperty],[s.default.rootData,s.default.rootData]];l.opts.dynamicRef&&p.push([s.default.dynamicAnchors,s.default.dynamicAnchors]);const g=r._`${d}, ${i.object(...p)}`;return u!==r.nil?r._`${c}.call(${u}, ${g})`:r._`${c}(${g})`};const h=r._`new RegExp`;t.usePattern=function({gen:e,it:{opts:t}},i){const n=t.unicodeRegExp?"u":"",{regExp:s}=t.code,a=s(i,n);return e.scopeValue("pattern",{key:a.toString(),ref:a,code:r._`${"new RegExp"===s.code?h:(0,o.useFunc)(e,s)}(${i}, ${n})`})},t.validateArray=function(e){const{gen:t,data:i,keyword:s,it:o}=e,a=t.name("valid");if(o.allErrors){const e=t.let("valid",!0);return l(()=>t.assign(e,!1)),e}return t.var(a,!0),l(()=>t.break()),a;function l(o){const l=t.const("len",r._`${i}.length`);t.forRange("i",0,l,i=>{e.subschema({keyword:s,dataProp:i,dataPropType:n.Type.Num},a),t.if((0,r.not)(a),o)})}},t.validateUnion=function(e){const{gen:t,schema:i,keyword:s,it:o}=e;if(!Array.isArray(i))throw new Error("ajv implementation error");if(i.some(e=>(0,n.alwaysValidSchema)(o,e))&&!o.opts.unevaluated)return;const a=t.let("valid",!1),l=t.name("_valid");t.block(()=>i.forEach((i,n)=>{const o=e.subschema({keyword:s,schemaProp:n,compositeRule:!0},l);t.assign(a,r._`${a} || ${l}`),e.mergeValidEvaluated(o,l)||t.if((0,r.not)(a))})),e.result(a,()=>e.reset(),()=>e.error(!0))}},33330(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};t.default=i},20500(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(33330),n=i(30930),s=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",r.default,n.default];t.default=s},30930(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.callRef=t.getValidate=void 0;const r=i(4220),n=i(24954),s=i(38994),o=i(86660),a=i(91688),l=i(67218),c={keyword:"$ref",schemaType:"string",code(e){const{gen:t,schema:i,it:n}=e,{baseId:o,schemaEnv:l,validateName:c,opts:d,self:p}=n,{root:g}=l;if(("#"===i||"#/"===i)&&o===g.baseId)return function(){if(l===g)return h(e,c,l,l.$async);const i=t.scopeValue("root",{ref:g});return h(e,s._`${i}.validate`,g,g.$async)}();const f=a.resolveRef.call(p,g,o,i);if(void 0===f)throw new r.default(n.opts.uriResolver,o,i);return f instanceof a.SchemaEnv?function(t){const i=u(e,t);h(e,i,t,t.$async)}(f):function(r){const n=t.scopeValue("schema",!0===d.code.source?{ref:r,code:(0,s.stringify)(r)}:{ref:r}),o=t.name("valid"),a=e.subschema({schema:r,dataTypes:[],schemaPath:s.nil,topSchemaRef:n,errSchemaPath:i},o);e.mergeEvaluated(a),e.ok(o)}(f)}};function u(e,t){const{gen:i}=e;return t.validate?i.scopeValue("validate",{ref:t.validate}):s._`${i.scopeValue("wrapper",{ref:t})}.validate`}function h(e,t,i,r){const{gen:a,it:c}=e,{allErrors:u,schemaEnv:h,opts:d}=c,p=d.passContext?o.default.this:s.nil;function g(e){const t=s._`${e}.errors`;a.assign(o.default.vErrors,s._`${o.default.vErrors} === null ? ${t} : ${o.default.vErrors}.concat(${t})`),a.assign(o.default.errors,s._`${o.default.vErrors}.length`)}function f(e){var t;if(!c.opts.unevaluated)return;const r=null===(t=null==i?void 0:i.validate)||void 0===t?void 0:t.evaluated;if(!0!==c.props)if(r&&!r.dynamicProps)void 0!==r.props&&(c.props=l.mergeEvaluated.props(a,r.props,c.props));else{const t=a.var("props",s._`${e}.evaluated.props`);c.props=l.mergeEvaluated.props(a,t,c.props,s.Name)}if(!0!==c.items)if(r&&!r.dynamicItems)void 0!==r.items&&(c.items=l.mergeEvaluated.items(a,r.items,c.items));else{const t=a.var("items",s._`${e}.evaluated.items`);c.items=l.mergeEvaluated.items(a,t,c.items,s.Name)}}r?function(){if(!h.$async)throw new Error("async schema referenced by sync schema");const i=a.let("valid");a.try(()=>{a.code(s._`await ${(0,n.callValidateCode)(e,t,p)}`),f(t),u||a.assign(i,!0)},e=>{a.if(s._`!(${e} instanceof ${c.ValidationError})`,()=>a.throw(e)),g(e),u||a.assign(i,!1)}),e.ok(i)}():e.result((0,n.callValidateCode)(e,t,p),()=>f(t),()=>g(t))}t.getValidate=u,t.callRef=h,t.default=c},29376(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(15141),s=i(91688),o=i(4220),a=i(67218),l={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:e,tagName:t}})=>e===n.DiscrError.Tag?`tag "${t}" must be string`:`value of tag "${t}" must be in oneOf`,params:({params:{discrError:e,tag:t,tagName:i}})=>r._`{error: ${e}, tag: ${i}, tagValue: ${t}}`},code(e){const{gen:t,data:i,schema:l,parentSchema:c,it:u}=e,{oneOf:h}=c;if(!u.opts.discriminator)throw new Error("discriminator: requires discriminator option");const d=l.propertyName;if("string"!=typeof d)throw new Error("discriminator: requires propertyName");if(l.mapping)throw new Error("discriminator: mapping is not supported");if(!h)throw new Error("discriminator: requires oneOf keyword");const p=t.let("valid",!1),g=t.const("tag",r._`${i}${(0,r.getProperty)(d)}`);function f(i){const n=t.name("valid"),s=e.subschema({keyword:"oneOf",schemaProp:i},n);return e.mergeEvaluated(s,r.Name),n}t.if(r._`typeof ${g} == "string"`,()=>function(){const i=function(){var e;const t={},i=n(c);let r=!0;for(let t=0;t<h.length;t++){let c=h[t];if((null==c?void 0:c.$ref)&&!(0,a.schemaHasRulesButRef)(c,u.self.RULES)){const e=c.$ref;if(c=s.resolveRef.call(u.self,u.schemaEnv.root,u.baseId,e),c instanceof s.SchemaEnv&&(c=c.schema),void 0===c)throw new o.default(u.opts.uriResolver,u.baseId,e)}const p=null===(e=null==c?void 0:c.properties)||void 0===e?void 0:e[d];if("object"!=typeof p)throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${d}"`);r=r&&(i||n(c)),l(p,t)}if(!r)throw new Error(`discriminator: "${d}" must be required`);return t;function n({required:e}){return Array.isArray(e)&&e.includes(d)}function l(e,t){if(e.const)p(e.const,t);else{if(!e.enum)throw new Error(`discriminator: "properties/${d}" must have "const" or "enum"`);for(const i of e.enum)p(i,t)}}function p(e,i){if("string"!=typeof e||e in t)throw new Error(`discriminator: "${d}" values must be unique strings`);t[e]=i}}();t.if(!1);for(const e in i)t.elseIf(r._`${g} === ${e}`),t.assign(p,f(i[e]));t.else(),e.error(!1,{discrError:n.DiscrError.Mapping,tag:g,tagName:d}),t.endIf()}(),()=>e.error(!1,{discrError:n.DiscrError.Tag,tag:g,tagName:d})),e.ok(p)}};t.default=l},15141(e,t){"use strict";var i;Object.defineProperty(t,"__esModule",{value:!0}),t.DiscrError=void 0,function(e){e.Tag="tag",e.Mapping="mapping"}(i||(t.DiscrError=i={}))},83959(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(20500),n=i(30659),s=i(88313),o=i(38563),a=i(44618),l=[r.default,n.default,(0,s.default)(),o.default,a.metadataVocabulary,a.contentVocabulary];t.default=l},40424(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>r.str`must match format "${e}"`,params:({schemaCode:e})=>r._`{format: ${e}}`},code(e,t){const{gen:i,data:n,$data:s,schema:o,schemaCode:a,it:l}=e,{opts:c,errSchemaPath:u,schemaEnv:h,self:d}=l;c.validateFormats&&(s?function(){const s=i.scopeValue("formats",{ref:d.formats,code:c.code.formats}),o=i.const("fDef",r._`${s}[${a}]`),l=i.let("fType"),u=i.let("format");i.if(r._`typeof ${o} == "object" && !(${o} instanceof RegExp)`,()=>i.assign(l,r._`${o}.type || "string"`).assign(u,r._`${o}.validate`),()=>i.assign(l,r._`"string"`).assign(u,o)),e.fail$data((0,r.or)(!1===c.strictSchema?r.nil:r._`${a} && !${u}`,function(){const e=h.$async?r._`(${o}.async ? await ${u}(${n}) : ${u}(${n}))`:r._`${u}(${n})`,i=r._`(typeof ${u} == "function" ? ${e} : ${u}.test(${n}))`;return r._`${u} && ${u} !== true && ${l} === ${t} && !${i}`}()))}():function(){const s=d.formats[o];if(!s)return void function(){if(!1!==c.strictSchema)throw new Error(e());function e(){return`unknown format "${o}" ignored in schema at path "${u}"`}d.logger.warn(e())}();if(!0===s)return;const[a,l,p]=function(e){const t=e instanceof RegExp?(0,r.regexpCode)(e):c.code.formats?r._`${c.code.formats}${(0,r.getProperty)(o)}`:void 0,n=i.scopeValue("formats",{key:o,ref:e,code:t});return"object"!=typeof e||e instanceof RegExp?["string",e,n]:[e.type||"string",e.validate,r._`${n}.validate`]}(s);a===t&&e.pass(function(){if("object"==typeof s&&!(s instanceof RegExp)&&s.async){if(!h.$async)throw new Error("async format in sync schema");return r._`await ${p}(${n})`}return"function"==typeof l?r._`${p}(${n})`:r._`${p}.test(${n})`}())}())}};t.default=n},38563(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=[i(40424).default];t.default=r},44618(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.contentVocabulary=t.metadataVocabulary=void 0,t.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],t.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]},17080(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s=i(6013),o={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:e})=>r._`{allowedValue: ${e}}`},code(e){const{gen:t,data:i,$data:o,schemaCode:a,schema:l}=e;o||l&&"object"==typeof l?e.fail$data(r._`!${(0,n.useFunc)(t,s.default)}(${i}, ${a})`):e.fail(r._`${l} !== ${i}`)}};t.default=o},42977(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s=i(6013),o={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:e})=>r._`{allowedValues: ${e}}`},code(e){const{gen:t,data:i,$data:o,schema:a,schemaCode:l,it:c}=e;if(!o&&0===a.length)throw new Error("enum must have non-empty array");const u=a.length>=c.opts.loopEnum;let h;const d=()=>null!=h?h:h=(0,n.useFunc)(t,s.default);let p;if(u||o)p=t.let("valid"),e.block$data(p,function(){t.assign(p,!1),t.forOf("v",l,e=>t.if(r._`${d()}(${i}, ${e})`,()=>t.assign(p,!0).break()))});else{if(!Array.isArray(a))throw new Error("ajv implementation error");const e=t.const("vSchema",l);p=(0,r.or)(...a.map((t,n)=>function(e,t){const n=a[t];return"object"==typeof n&&null!==n?r._`${d()}(${i}, ${e}[${t}])`:r._`${i} === ${n}`}(e,n)))}e.pass(p)}};t.default=o},30659(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(68997),n=i(89190),s=i(94280),o=i(78805),a=i(12189),l=i(33138),c=i(48870),u=i(11858),h=i(17080),d=i(42977),p=[r.default,n.default,s.default,o.default,a.default,l.default,c.default,u.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},h.default,d.default];t.default=p},48870(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const i="maxItems"===e?"more":"fewer";return r.str`must NOT have ${i} than ${t} items`},params:({schemaCode:e})=>r._`{limit: ${e}}`},code(e){const{keyword:t,data:i,schemaCode:n}=e,s="maxItems"===t?r.operators.GT:r.operators.LT;e.fail$data(r._`${i}.length ${s} ${n}`)}};t.default=n},94280(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=i(67218),s=i(25532),o={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const i="maxLength"===e?"more":"fewer";return r.str`must NOT have ${i} than ${t} characters`},params:({schemaCode:e})=>r._`{limit: ${e}}`},code(e){const{keyword:t,data:i,schemaCode:o,it:a}=e,l="maxLength"===t?r.operators.GT:r.operators.LT,c=!1===a.opts.unicode?r._`${i}.length`:r._`${(0,n.useFunc)(e.gen,s.default)}(${i})`;e.fail$data(r._`${c} ${l} ${o}`)}};t.default=o},68997(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n=r.operators,s={maximum:{okStr:"<=",ok:n.LTE,fail:n.GT},minimum:{okStr:">=",ok:n.GTE,fail:n.LT},exclusiveMaximum:{okStr:"<",ok:n.LT,fail:n.GTE},exclusiveMinimum:{okStr:">",ok:n.GT,fail:n.LTE}},o={message:({keyword:e,schemaCode:t})=>r.str`must be ${s[e].okStr} ${t}`,params:({keyword:e,schemaCode:t})=>r._`{comparison: ${s[e].okStr}, limit: ${t}}`},a={keyword:Object.keys(s),type:"number",schemaType:"number",$data:!0,error:o,code(e){const{keyword:t,data:i,schemaCode:n}=e;e.fail$data(r._`${i} ${s[t].fail} ${n} || isNaN(${i})`)}};t.default=a},12189(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:e,schemaCode:t}){const i="maxProperties"===e?"more":"fewer";return r.str`must NOT have ${i} than ${t} properties`},params:({schemaCode:e})=>r._`{limit: ${e}}`},code(e){const{keyword:t,data:i,schemaCode:n}=e,s="maxProperties"===t?r.operators.GT:r.operators.LT;e.fail$data(r._`Object.keys(${i}).length ${s} ${n}`)}};t.default=n},89190(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(38994),n={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:e})=>r.str`must be multiple of ${e}`,params:({schemaCode:e})=>r._`{multipleOf: ${e}}`},code(e){const{gen:t,data:i,schemaCode:n,it:s}=e,o=s.opts.multipleOfPrecision,a=t.let("res"),l=o?r._`Math.abs(Math.round(${a}) - ${a}) > 1e-${o}`:r._`${a} !== parseInt(${a})`;e.fail$data(r._`(${n} === 0 || (${a} = ${i}/${n}, ${l}))`)}};t.default=n},78805(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(24954),n=i(67218),s=i(38994),o={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:e})=>s.str`must match pattern "${e}"`,params:({schemaCode:e})=>s._`{pattern: ${e}}`},code(e){const{gen:t,data:i,$data:o,schema:a,schemaCode:l,it:c}=e,u=c.opts.unicodeRegExp?"u":"";if(o){const{regExp:r}=c.opts.code,o="new RegExp"===r.code?s._`new RegExp`:(0,n.useFunc)(t,r),a=t.let("valid");t.try(()=>t.assign(a,s._`${o}(${l}, ${u}).test(${i})`),()=>t.assign(a,!1)),e.fail$data(s._`!${a}`)}else{const t=(0,r.usePattern)(e,a);e.fail$data(s._`!${t}.test(${i})`)}}};t.default=o},33138(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(24954),n=i(38994),s=i(67218),o={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:e}})=>n.str`must have required property '${e}'`,params:({params:{missingProperty:e}})=>n._`{missingProperty: ${e}}`},code(e){const{gen:t,schema:i,schemaCode:o,data:a,$data:l,it:c}=e,{opts:u}=c;if(!l&&0===i.length)return;const h=i.length>=u.loopRequired;if(c.allErrors?function(){if(h||l)e.block$data(n.nil,d);else for(const t of i)(0,r.checkReportMissingProp)(e,t)}():function(){const s=t.let("missing");if(h||l){const i=t.let("valid",!0);e.block$data(i,()=>function(i,s){e.setParams({missingProperty:i}),t.forOf(i,o,()=>{t.assign(s,(0,r.propertyInData)(t,a,i,u.ownProperties)),t.if((0,n.not)(s),()=>{e.error(),t.break()})},n.nil)}(s,i)),e.ok(i)}else t.if((0,r.checkMissingProp)(e,i,s)),(0,r.reportMissingProp)(e,s),t.else()}(),u.strictRequired){const t=e.parentSchema.properties,{definedProperties:r}=e.it;for(const e of i)if(void 0===(null==t?void 0:t[e])&&!r.has(e)){const t=`required property "${e}" is not defined at "${c.schemaEnv.baseId+c.errSchemaPath}" (strictRequired)`;(0,s.checkStrictMode)(c,t,c.opts.strictRequired)}}function d(){t.forOf("prop",o,i=>{e.setParams({missingProperty:i}),t.if((0,r.noPropertyInData)(t,a,i,u.ownProperties),()=>e.error())})}}};t.default=o},11858(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});const r=i(26419),n=i(38994),s=i(67218),o=i(6013),a={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:e,j:t}})=>n.str`must NOT have duplicate items (items ## ${t} and ${e} are identical)`,params:({params:{i:e,j:t}})=>n._`{i: ${e}, j: ${t}}`},code(e){const{gen:t,data:i,$data:a,schema:l,parentSchema:c,schemaCode:u,it:h}=e;if(!a&&!l)return;const d=t.let("valid"),p=c.items?(0,r.getSchemaTypes)(c.items):[];function g(s,o){const a=t.name("item"),l=(0,r.checkDataTypes)(p,a,h.opts.strictNumbers,r.DataType.Wrong),c=t.const("indices",n._`{}`);t.for(n._`;${s}--;`,()=>{t.let(a,n._`${i}[${s}]`),t.if(l,n._`continue`),p.length>1&&t.if(n._`typeof ${a} == "string"`,n._`${a} += "_"`),t.if(n._`typeof ${c}[${a}] == "number"`,()=>{t.assign(o,n._`${c}[${a}]`),e.error(),t.assign(d,!1).break()}).code(n._`${c}[${a}] = ${s}`)})}function f(r,a){const l=(0,s.useFunc)(t,o.default),c=t.name("outer");t.label(c).for(n._`;${r}--;`,()=>t.for(n._`${a} = ${r}; ${a}--;`,()=>t.if(n._`${l}(${i}[${r}], ${i}[${a}])`,()=>{e.error(),t.assign(d,!1).break(c)})))}e.block$data(d,function(){const r=t.let("i",n._`${i}.length`),s=t.let("j");e.setParams({i:r,j:s}),t.assign(d,!0),t.if(n._`${r} > 1`,()=>(p.length>0&&!p.some(e=>"object"===e||"array"===e)?g:f)(r,s))},n._`${u} === false`),e.ok(d)}};t.default=a},14538(e,t){!function(e){"use strict";function t(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,r=Array(t);i<t;i++)r[i]=e[i];return r}function i(e,t,i,r,n,s,o){try{var a=e[s](o),l=a.value}catch(e){return void i(e)}a.done?t(l):Promise.resolve(l).then(r,n)}function r(e){return function(){var t=this,r=arguments;return new Promise(function(n,s){var o=e.apply(t,r);function a(e){i(o,n,s,a,l,"next",e)}function l(e){i(o,n,s,a,l,"throw",e)}a(void 0)})}}function n(e,t,i){return t=l(t),function(e,t){if(t&&("object"==typeof t||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(e,u()?Reflect.construct(t,i||[],l(e).constructor):t.apply(e,i))}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function o(e,t,i){return Object.defineProperty(e,"prototype",{writable:!1}),e}function a(e,t,i){return(t=function(e){var t=function(e,t){if("object"!=typeof e||!e)return e;var i=e[Symbol.toPrimitive];if(void 0!==i){var r=i.call(e,t);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e,"string");return"symbol"==typeof t?t:t+""}(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function l(e){return l=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},l(e)}function c(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&m(e,t)}function u(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(u=function(){return!!e})()}function h(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,r)}return i}function d(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?h(Object(i),!0).forEach(function(t){a(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):h(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}function p(e,t){if(null==e)return{};var i,r,n=function(e,t){if(null==e)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;i[r]=e[r]}return i}(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)i=s[r],-1===t.indexOf(i)&&{}.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}function g(){var e,t,i="function"==typeof Symbol?Symbol:{},r=i.iterator||"@@iterator",n=i.toStringTag||"@@toStringTag";function s(i,r,n,s){var l=r&&r.prototype instanceof a?r:a,c=Object.create(l.prototype);return f(c,"_invoke",function(i,r,n){var s,a,l,c=0,u=n||[],h=!1,d={p:0,n:0,v:e,a:p,f:p.bind(e,4),d:function(t,i){return s=t,a=0,l=e,d.n=i,o}};function p(i,r){for(a=i,l=r,t=0;!h&&c&&!n&&t<u.length;t++){var n,s=u[t],p=d.p,g=s[2];i>3?(n=g===r)&&(l=s[(a=s[4])?5:(a=3,3)],s[4]=s[5]=e):s[0]<=p&&((n=i<2&&p<s[1])?(a=0,d.v=r,d.n=s[1]):p<g&&(n=i<3||s[0]>r||r>g)&&(s[4]=i,s[5]=r,d.n=g,a=0))}if(n||i>1)return o;throw h=!0,r}return function(n,u,g){if(c>1)throw TypeError("Generator is already running");for(h&&1===u&&p(u,g),a=u,l=g;(t=a<2?e:l)||!h;){s||(a?a<3?(a>1&&(d.n=-1),p(a,l)):d.n=l:d.v=l);try{if(c=2,s){if(a||(n="next"),t=s[n]){if(!(t=t.call(s,l)))throw TypeError("iterator result is not an object");if(!t.done)return t;l=t.value,a<2&&(a=0)}else 1===a&&(t=s.return)&&t.call(s),a<2&&(l=TypeError("The iterator does not provide a '"+n+"' method"),a=1);s=e}else if((t=(h=d.n<0)?l:i.call(r,d))!==o)break}catch(t){s=e,a=1,l=t}finally{c=1}}return{value:t,done:h}}}(i,n,s),!0),c}var o={};function a(){}function l(){}function c(){}t=Object.getPrototypeOf;var u=[][r]?t(t([][r]())):(f(t={},r,function(){return this}),t),h=c.prototype=a.prototype=Object.create(u);function d(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,c):(e.__proto__=c,f(e,n,"GeneratorFunction")),e.prototype=Object.create(h),e}return l.prototype=c,f(h,"constructor",c),f(c,"constructor",l),l.displayName="GeneratorFunction",f(c,n,"GeneratorFunction"),f(h),f(h,n,"Generator"),f(h,r,function(){return this}),f(h,"toString",function(){return"[object Generator]"}),(g=function(){return{w:s,m:d}})()}function f(e,t,i,r){var n=Object.defineProperty;try{n({},"",{})}catch(e){n=0}f=function(e,t,i,r){function s(t,i){f(e,t,function(e){return this._invoke(t,i,e)})}t?n?n(e,t,{value:i,enumerable:!r,configurable:!r,writable:!r}):e[t]=i:(s("next",0),s("throw",1),s("return",2))},f(e,t,i,r)}function m(e,t){return m=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},m(e,t)}function v(e,i){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var r,n,s,o,a=[],l=!0,c=!1;try{if(s=(i=i.call(e)).next,0===t);else for(;!(l=(r=s.call(i)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,n=e}finally{try{if(!l&&null!=i.return&&(o=i.return(),Object(o)!==o))return}finally{if(c)throw n}}return a}}(e,i)||function(e,i){if(e){if("string"==typeof e)return t(e,i);var r={}.toString.call(e).slice(8,-1);return"Object"===r&&e.constructor&&(r=e.constructor.name),"Map"===r||"Set"===r?Array.from(e):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?t(e,i):void 0}}(e,i)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function C(e){return C="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},C(e)}var y={CALLBACK_OPERATION_INVOKED:"CALLBACK_OPERATION_INVOKED",CONTENT_LOADED:"CONTENT_LOADED",EXPERIENCE_INITIALIZED:"EXPERIENCE_INITIALIZED",ERROR_OCCURRED:"ERROR_OCCURRED",SIZE_CHANGED:"SIZE_CHANGED",PARAMETERS_CHANGED:"PARAMETERS_CHANGED",SELECTED_SHEET_CHANGED:"SELECTED_SHEET_CHANGED",MODAL_OPENED:"MODAL_OPENED",Q_SEARCH_CLOSED:"Q_SEARCH_CLOSED",Q_SEARCH_OPENED:"Q_SEARCH_OPENED",Q_SEARCH_FOCUSED:"Q_SEARCH_FOCUSED",Q_SEARCH_SIZE_CHANGED:"Q_SEARCH_SIZE_CHANGED",Q_SEARCH_ENTERED_FULLSCREEN:"Q_SEARCH_ENTERED_FULLSCREEN",Q_SEARCH_EXITED_FULLSCREEN:"Q_SEARCH_EXITED_FULLSCREEN",Q_PANEL_ENTERED_FULLSCREEN:"Q_PANEL_ENTERED_FULLSCREEN",Q_PANEL_EXITED_FULLSCREEN:"Q_PANEL_EXITED_FULLSCREEN",PAGE_NAVIGATION:"PAGE_NAVIGATION",PARAMETERS_LOADED:"PARAMETERS_LOADED"},w={FRAME_STARTED:"FRAME_STARTED",FRAME_MOUNTED:"FRAME_MOUNTED",FRAME_LOADED:"FRAME_LOADED",FRAME_REMOVED:"FRAME_REMOVED"},S={FRAME_NOT_CREATED:"FRAME_NOT_CREATED",NO_BODY:"NO_BODY",NO_CONTAINER:"NO_CONTAINER",INVALID_CONTAINER:"INVALID_CONTAINER",NO_URL:"NO_URL",INVALID_URL:"INVALID_URL",NO_FRAME_OPTIONS:"NO_FRAME_OPTIONS",INVALID_FRAME_OPTIONS:"INVALID_FRAME_OPTIONS"},b={UNRECOGNIZED_CONTENT_OPTIONS:"UNRECOGNIZED_CONTENT_OPTIONS",UNRECOGNIZED_FRAME_OPTIONS:"UNRECOGNIZED_FRAME_OPTIONS",UNRECOGNIZED_EVENT_TARGET:"UNRECOGNIZED_EVENT_TARGET"},E={SET_PARAMETERS:"SET_PARAMETERS",SET_SELECTED_SHEET_ID:"SET_SELECTED_SHEET_ID",SET_Q_SEARCH_QUESTION:"SET_Q_SEARCH_QUESTION",SET_VISUAL_ACTIONS:"SET_VISUAL_ACTIONS",SET_THEME:"SET_THEME",ADD_FILTER_GROUPS:"ADD_FILTER_GROUPS",UPDATE_FILTER_GROUPS:"UPDATE_FILTER_GROUPS",REMOVE_FILTER_GROUPS:"REMOVE_FILTER_GROUPS",ADD_VISUAL_ACTIONS:"ADD_VISUAL_ACTIONS",REMOVE_VISUAL_ACTIONS:"REMOVE_VISUAL_ACTIONS",SET_THEME_OVERRIDE:"SET_THEME_OVERRIDE",PRELOAD_THEMES:"PRELOAD_THEMES",CREATE_SHARED_VIEW:"CREATE_SHARED_VIEW"},A={GET_PARAMETERS:"GET_PARAMETERS",GET_SHEETS:"GET_SHEETS",GET_SHEET_VISUALS:"GET_SHEET_VISUALS",GET_VISUAL_ACTIONS:"GET_VISUAL_ACTIONS",GET_SELECTED_SHEET_ID:"GET_SELECTED_SHEET_ID",GET_FILTER_GROUPS_FOR_SHEET:"GET_FILTER_GROUPS_FOR_SHEET",GET_FILTER_GROUPS_FOR_VISUAL:"GET_FILTER_GROUPS_FOR_VISUAL"},T={ACKNOWLEDGE:"ACKNOWLEDGE",INITIATE_PRINT:"INITIATE_PRINT",NAVIGATE_TO_DASHBOARD:"NAVIGATE_TO_DASHBOARD",CLOSE_Q_SEARCH:"CLOSE_Q_SEARCH",UNDO:"UNDO",REDO:"REDO",RESET:"RESET",TOGGLE_EXECUTIVE_SUMMARY_PANE:"TOGGLE_EXECUTIVE_SUMMARY_PANE",OPEN_BUILD_VISUAL_PANE:"OPEN_BUILD_VISUAL_PANE",OPEN_DATA_QNA_PANE:"OPEN_DATA_QNA_PANE",TOGGLE_BOOKMARKS_PANE:"TOGGLE_BOOKMARKS_PANE",TOGGLE_THRESHOLD_ALERTS_PANE:"TOGGLE_THRESHOLD_ALERTS_PANE",TOGGLE_SCHEDULING_PANE:"TOGGLE_SCHEDULING_PANE",TOGGLE_RECENT_SNAPSHOTS_PANE:"TOGGLE_RECENT_SNAPSHOTS_PANE",IMPORT_OBJECTS:"IMPORT_OBJECTS",OPEN_BUILD_STORY_PANE:"OPEN_BUILD_STORY_PANE",SEND_PROMPT:"SEND_PROMPT"},M=Object.freeze({__proto__:null,ErrorChangeEventName:S,GetterMessageEventName:A,InfoChangeEventName:w,InfoMessageEventName:y,InvokerMessageEventName:T,SetterMessageEventName:E,WarnChangeEventName:b}),R=d(d(d({},w),S),b),_=d(d(d(d({},y),E),A),T),P={ERROR:"ERROR",INFO:"INFO",WARN:"WARN"},x=Object.freeze({__proto__:null,ChangeEventLevel:P,ChangeEventName:R,MessageEventName:_}),D=Object.freeze({__proto__:null}),I=Object.freeze({__proto__:null}),L=Object.freeze({__proto__:null}),N=Object.freeze({__proto__:null}),O={CONSOLE:"CONSOLE",CONTEXT:"CONTEXT",CONTROL:"CONTROL",VISUAL:"VISUAL",DASHBOARD:"DASHBOARD",QSEARCH:"QSEARCH",GENERATIVEQNA:"QSEARCH",QUICKCHAT:"QUICKCHAT"},F=Object.freeze({__proto__:null,ExperienceType:O}),k=Object.freeze({__proto__:null}),G={NULL:null,OTHER_BUCKET:null},V={INTEGER:null,STRING:null,DECIMAL:null,DATETIME:null},H=Object.freeze({__proto__:null,CALCULATED_METRIC_COLUMN_TYPE:V,SPECIAL_DATAPOINT_VALUE_TYPES:G}),B=Object.freeze({__proto__:null}),z=Object.freeze({__proto__:null}),U=Object.freeze({__proto__:null}),W={FULL:"FULL",SEARCH_BAR:"SEARCH_BAR"},j=Object.freeze({__proto__:null,GenerativeQnAPanelType:W}),K=Object.freeze({__proto__:null}),$=Object.freeze({__proto__:null}),q=o(function e(t,i,r){s(this,e),this.eventName=t,this.message=i,this.data=r}),Y=function(e){function t(e,i,r,o){var a;return s(this,t),(a=n(this,t,[e,r,o])).eventLevel=i,a}return c(t,e),o(t)}(q),Q=function(e){function t(e,i,r){var o;return s(this,t),(o=n(this,t,[e,i,r])).eventName=e,o}return c(t,e),o(t)}(q),X=function(e){function t(e,i,r,o){var a;return s(this,t),(a=n(this,t,[e,r,o])).eventTarget=i,a}return c(t,e),o(t)}(Q),Z=function(e){function t(e,i,r,o,a,l,c){var u;return s(this,t),(u=n(this,t,[e,i,l,c])).timestamp=o,u.version=a,u.eventId=r,u}return c(t,e),o(t)}(X),J=o(function e(){s(this,e)}),ee=o(function e(){s(this,e),a(this,"success",!0)}),te=o(function e(t){s(this,e),a(this,"success",!1),this.errorCode=t.errorCode,this.error=t.error,this.message=t.message}),ie=o(function e(t){s(this,e),a(this,"success",!0),this.message=t});let re;const ne=new Uint8Array(16);function se(){if(!re&&(re="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto),!re))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return re(ne)}const oe=[];for(let e=0;e<256;++e)oe.push((e+256).toString(16).slice(1));var ae={randomUUID:"undefined"!=typeof crypto&&crypto.randomUUID&&crypto.randomUUID.bind(crypto)};function le(e,t,i){if(ae.randomUUID&&!e)return ae.randomUUID();const r=(e=e||{}).random||(e.rng||se)();return r[6]=15&r[6]|64,r[8]=63&r[8]|128,function(e,t=0){return oe[e[t+0]]+oe[e[t+1]]+oe[e[t+2]]+oe[e[t+3]]+"-"+oe[e[t+4]]+oe[e[t+5]]+"-"+oe[e[t+6]]+oe[e[t+7]]+"-"+oe[e[t+8]]+oe[e[t+9]]+"-"+oe[e[t+10]]+oe[e[t+11]]+oe[e[t+12]]+oe[e[t+13]]+oe[e[t+14]]+oe[e[t+15]]}(r)}var ce=o(function e(t,i,n,o){var l=this;s(this,e),a(this,"send",function(){var e=r(g().m(function e(t){var i;return g().w(function(e){for(;;)switch(e.n){case 0:if(l.experienceFrame&&l.internalExperience){e.n=1;break}throw new Error("Experience has not been initialized");case 1:return i=new X(t.eventName,l.internalExperience,t.message,t.data),e.a(2,l.experienceFrame.send(i))}},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"addEventListener",function(e,t){return l.experienceFrame.addInternalEventListener(e,t)}),a(this,"setLogProvider",function(e){return l.logger=e,l}),a(this,"getInternalExperienceInfo",function(t){var i,r,n=-1;do{n++,i=d(d({},t),{},{contextId:l.controlOptions.contextId,discriminator:n}),r=e.getExperienceIdentifier(i)}while(l.experienceIdentifiers.has(r));return l.experienceIdentifiers.add(r),{experienceIdentifier:r,internalExperience:i}}),a(this,"transformContentOptions",function(e,t){return l.warnUnrecognizedContentOptions(Object.keys(t)),e}),a(this,"warnUnrecognizedContentOptions",function(e){var t,i,r;e.length>0&&(null===(t=(i=l.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.UNRECOGNIZED_CONTENT_OPTIONS,P.WARN,"Experience content options contain unrecognized properties",{unrecognizedContentOptions:e}),{frame:null}),null===(r=l.logger)||void 0===r||r.warn("Experience content options contain unrecognized properties"))}),a(this,"validateFrameOptions",function(){if(!l.frameOptions.url){var e,t,i="Url is required for the experience";throw null===(e=(t=l.frameOptions).onChange)||void 0===e||e.call(t,new Y(R.NO_URL,P.ERROR,i),{frame:null}),new Error(i)}}),this.frameOptions=t,this.contentOptions=i,this.controlOptions=n,this.experienceIdentifiers=o,this.validateFrameOptions()});a(ce,"getExperienceIdentifier",function(e){if(e.experienceType===O.DASHBOARD)return[e.contextId,e.experienceType,e.dashboardId,e.discriminator].filter(Boolean).join("-");if(e.experienceType===O.VISUAL)return[e.contextId,e.experienceType,e.dashboardId,e.sheetId,e.visualId,e.discriminator].filter(Boolean).join("-");if([O.CONSOLE,O.CONTROL,O.CONTEXT,O.QSEARCH,O.GENERATIVEQNA,O.QUICKCHAT].includes(e.experienceType))return[e.contextId,e.experienceType,e.discriminator].filter(Boolean).join("-");throw new Error("Invalid experience unable to build experience identifier")});const ue=2147483647,he={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},de=Math.floor,pe=String.fromCharCode;function ge(e){throw new RangeError(he[e])}const fe=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},me=function(e,t,i){let r=0;for(e=i?de(e/700):e>>1,e+=de(e/t);e>455;r+=36)e=de(e/35);return de(r+36*e/(e+38))},ve=function(e){const t=[];e=function(e){const t=[];let i=0;const r=e.length;for(;i<r;){const n=e.charCodeAt(i++);if(n>=55296&&n<=56319&&i<r){const r=e.charCodeAt(i++);56320==(64512&r)?t.push(((1023&n)<<10)+(1023&r)+65536):(t.push(n),i--)}else t.push(n)}return t}(e);const i=e.length;let r=128,n=0,s=72;for(const i of e)i<128&&t.push(pe(i));const o=t.length;let a=o;for(o&&t.push("-");a<i;){let i=ue;for(const t of e)t>=r&&t<i&&(i=t);const l=a+1;i-r>de((ue-n)/l)&&ge("overflow"),n+=(i-r)*l,r=i;for(const i of e)if(i<r&&++n>ue&&ge("overflow"),i===r){let e=n;for(let i=36;;i+=36){const r=i<=s?1:i>=s+26?26:i-s;if(e<r)break;const n=e-r,o=36-r;t.push(pe(fe(r+n%o,0))),e=de(n/o)}t.push(pe(fe(e,0))),s=me(n,l,a===o),n=0,++a}++n,++r}return t.join("")};var Ce=o(function e(t){var i=this;s(this,e),a(this,"classNames",[e.IFRAME_CLASS_NAME]),a(this,"getIframe",function(){return i.iframe}),a(this,"createIframePlaceholder",function(t){if(i.iframePlaceholder=document.createElement("div"),i.iframePlaceholder.id="".concat(i.iframeName,"-placeholder"),i.iframePlaceholder.style.width=i.width,i.iframePlaceholder.style.backgroundColor="rgba(0,0,0,.01)",i.iframePlaceholder.style.display="flex",i.iframePlaceholder.style.justifyContent="center",i.iframePlaceholder.style.alignItems="center",i.iframePlaceholder.className="".concat(e.IFRAME_CLASS_NAME,"-placeholder"),i.height.endsWith("px")&&(i.iframePlaceholder.style.height=i.height),t&&"boolean"!=typeof t)i.iframePlaceholder.appendChild(t);else{var r=i.createLoaderSVG();i.iframePlaceholder.appendChild(r)}i.container.appendChild(i.iframePlaceholder)}),a(this,"createIframe",function(){var e,t,r=document.createElement("iframe");r.className=i.classNames.join(" ").trim(),r.id=i.iframeName,r.name=i.iframeName,r.width=i.width,r.height=i.height,i.loading&&(r.loading=i.loading),r.style.border="0px",r.style.padding="0px",i.iframePlaceholder&&(r.style.opacity="0",r.style.position="absolute"),"0px"===i.width&&"0px"===i.height&&(r.style.position="absolute");var n=[];return null!==(e=i.framePermissions)&&void 0!==e&&e.clipboardRead&&n.push("clipboard-read ".concat(new URL(i.src).origin)),null!==(t=i.framePermissions)&&void 0!==t&&t.clipboardWrite&&n.push("clipboard-write ".concat(new URL(i.src).origin)),n.length&&(r.allow=n.join("; ")),i.container.appendChild(r),i.payload?i.postRequest=i.createPostRequest({src:i.src,target:r.name,container:i.container,payload:i.payload}):r.src=i.src,r}),a(this,"onLoadLocal",function(e){var t,r;i.iframePlaceholder&&(i.iframePlaceholder.remove(),i.iframe.style.position="",i.iframe.style.opacity="1",i.iframe.style.transition="opacity .5s ease-in-out"),null===(t=i.onLoad)||void 0===t||t.call(i,e),null===(r=i.postRequest)||void 0===r||r.remove()}),a(this,"createPostRequest",function(e){var t=e.src,i=e.container,r=e.target,n=e.payload;if(!t)throw new Error("No source has been provided.");var s=document.createElement("form");return s.style.visibility="hidden",s.method="POST",s.action=t,s.target=r,s.name="".concat(r,"-form"),Object.keys(n).forEach(function(e){var t=document.createElement("input");t.type="hidden",t.name=e,t.value=n[e],s.appendChild(t)}),i.appendChild(s),null==s||s.submit(),{remove:function(){s.remove()}}}),a(this,"createSvgElement",function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],n=document.createElementNS("http://www.w3.org/2000/svg",e);return Object.entries(t).forEach(function(e){var t=v(e,2),i=t[0],r=t[1];return n.setAttribute(i,r)}),Object.entries(i).forEach(function(e){var t=v(e,2),i=t[0],r=t[1];return n.style.setProperty(i,r)}),r.forEach(function(e){return n.appendChild(e)}),n}),a(this,"createLoaderSVG",function(){var e=[1,2,3].map(function(e){var t=i.createSvgElement("animate",{attributeName:"opacity",dur:"1s",values:"0;1;0",repeatCount:"indefinite",begin:"".concat(e/10)});return i.createSvgElement("circle",{fill:"#ccc",stroke:"none",cx:"".concat(20*e-14),cy:"50",r:"6"},void 0,[t])});return i.createSvgElement("svg",{version:"1.1",x:"0px",y:"0px",viewBox:"0 0 100 100","enable-background":"new 0 0 0 0"},{width:"100px",height:"100px"},e)});var r=t.id,n=t.src,o=t.width,l=void 0===o?"100%":o,c=t.height,u=void 0===c?"100%":c,h=t.container,d=t.onLoad,p=t.loading,g=t.withIframePlaceholder,f=t.payload,m=t.className,C=t.framePermissions;this.width=l,this.height=u,this.onLoad=d,this.iframeName=r,this.framePermissions=C,this.loading=p,m&&this.classNames.push(m),this.container=h,this.payload=f,this.src=n,g&&this.createIframePlaceholder(g),this.iframe=this.createIframe(),this.iframe.addEventListener("load",this.onLoadLocal)});a(Ce,"IFRAME_CLASS_NAME","quicksight-embedding-iframe");var ye="2.11.2",we=o(function e(t,i,n,o,l,c,u){var h=this;s(this,e),a(this,"MESSAGE_RESPONSE_TIMEOUT",5e3),a(this,"iframe",null),a(this,"send",function(){var e=r(g().m(function e(t){var i,r,n;return g().w(function(e){for(;;)switch(e.n){case 0:if(!h.controlOptions.sendToControlFrame){e.n=1;break}return e.a(2,h.controlOptions.sendToControlFrame(t));case 1:if(h.iframe){e.n=2;break}throw new Error("Cannot send ".concat(t.eventName,": No experience frame found"));case 2:if(r=le(),n=new Z(t.eventName,t.eventTarget,r,Date.now(),ye,t.message,t.data),null===(i=h.iframe)||void 0===i||null===(i=i.contentWindow)||void 0===i||i.postMessage(n,h.url),t.eventName!==_.ACKNOWLEDGE){e.n=3;break}return e.a(2,Promise.resolve(new ee));case 3:return e.a(2,new Promise(function(e,i){var n=function(t){var i,s,o=t.data;(null==o?void 0:o.eventId)===r&&(window.removeEventListener("message",n),!0===(null===(i=o.message)||void 0===i?void 0:i.success)?e(new ee):!1===(null===(s=o.message)||void 0===s?void 0:s.success)?e(new te(o.message)):e(new ie(o.message)))};window.addEventListener("message",n),setTimeout(function(){window.removeEventListener("message",n),i("".concat(t.eventName," timed out"))},h.MESSAGE_RESPONSE_TIMEOUT)}))}},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"buildParameterString",function(e){return e&&"object"===C(e)?Object.entries(e).map(function(e){var t=v(e,2),i=t[0],r=t[1],n=Array.isArray(r)?r:[r],s=encodeURIComponent(i);return n.map(encodeURIComponent).map(function(e){return"p.".concat(s,"=").concat(e)}).join("&")}).join("&"):""}),a(this,"buildQueryString",function(e){var t=Object.entries(e).reduce(function(e,t){var i=v(t,2),r=i[0],n=i[1];return null!=n?d(d({},e),{},a({},r,"".concat(n))):e},{punyCodeEmbedOrigin:ve("".concat(window.location.origin,"/")),sdkVersion:ye});return new URLSearchParams(t).toString()}),a(this,"createExperienceIframe",function(){h.onChange(new Y(R.FRAME_STARTED,P.INFO,"Creating the frame",{experience:h.internalExperience}));try{h.setTimeoutInstance(),h.iframe=new Ce({id:h.experienceId,src:h.url,width:h.frameOptions.width,height:h.frameOptions.height,container:h.container,onLoad:h.onLoadHandler,withIframePlaceholder:h.frameOptions.withIframePlaceholder,className:h.frameOptions.className,framePermissions:h.frameOptions.framePermissions}).getIframe()}catch(e){throw h.onChange(new Y(R.FRAME_NOT_CREATED,P.ERROR,"Failed to create the frame",{experience:h.internalExperience})),e}h.onChange(new Y(R.FRAME_MOUNTED,P.INFO,"The frame mounted",{experience:h.internalExperience,frame:h.iframe}))}),a(this,"addInternalEventListener",function(e,t){var i=function(i,r){i.eventName===e&&t(i,r)};return h.controlOptions.eventManager.addEventListener(h.experienceId,i,!0),{remove:function(){return h.controlOptions.eventManager.removeEventListener(h.experienceId,i)}}}),a(this,"validateBaseUrl",function(e){if(!e)throw h.onChange(new Y(R.NO_URL,P.ERROR,"Url is required for the experience",{experience:h.internalExperience})),new Error("Url is required for the experience");try{new URL(e)}catch(e){throw h.onChange(new Y(R.INVALID_URL,P.ERROR,"Invalid experience url",{experience:h.internalExperience})),new Error("Invalid experience url")}return e}),a(this,"setTimeoutInstance",function(){h.timeoutInstance=setTimeout(function(){throw h.onChange(new Y(R.FRAME_NOT_CREATED,P.ERROR,"Creating the frame timed out",{experience:h.internalExperience})),new Error("Creating the frame timed out")},h.controlOptions.timeout)}),a(this,"onLoadHandler",r(g().m(function e(){return g().w(function(e){for(;;)switch(e.n){case 0:h.timeoutInstance&&clearTimeout(h.timeoutInstance),h.onChange(new Y(R.FRAME_LOADED,P.INFO,"The experience iframe loaded",{experience:h.internalExperience}));case 1:return e.a(2)}},e)}))),a(this,"getContainer",function(e){if(!e){var t="Container is required for the experience";throw h.onChange(new Y(R.NO_CONTAINER,P.ERROR,t,{experience:h.internalExperience})),new Error(t)}var i=null;if("string"==typeof e)try{i=document.querySelector(e)}catch(e){throw e instanceof Error&&h.onChange(new Y(R.INVALID_CONTAINER,P.ERROR,e.message,{experience:h.internalExperience})),e}else"object"===C(e)&&e.nodeName&&(i=e);if(!i){var r="Invalid container '".concat(e,"' for the experience");throw h.onChange(new Y(R.INVALID_CONTAINER,P.ERROR,r,{experience:h.internalExperience})),new Error(r)}return i}),a(this,"decorateOnChange",function(e){return function(t){if(e){var i={frame:h.iframe};e(t,i)}}}),a(this,"decorateOnMessage",function(e,t){return function(i){t&&h.iframe&&t(i,{frame:h.iframe}),e&&e(i,{frame:h.iframe})}}),a(this,"initializeMutationObserver",function(){var e=new MutationObserver(function(t){t.some(function(e){return Array.from(e.removedNodes).some(function(e){return e===h.iframe||e===h.container})})&&(h.controlOptions.eventManager.cleanUpCallbacksForExperience(h.experienceId),e.disconnect(),h.iframe=null,h.onChange(new Y(R.FRAME_REMOVED,P.INFO,"Frame removed from the DOM",{experience:h.internalExperience})))});e.observe(document.body,{childList:!0,subtree:!0})}),this.frameOptions=t,this.contentOptions=n,this.onChange=this.decorateOnChange(t.onChange),this.onMessage=this.decorateOnMessage(n.onMessage,u),this.container=this.getContainer(t.container),this.internalExperience=l,this.controlOptions=i,this.transformedContentOptions=o,this.experienceId=c,this.url=this.validateBaseUrl(t.url),this.controlOptions.eventManager.addEventListener(this.experienceId,this.onMessage,!0),this.initializeMutationObserver()}),Se=["parameters"],be=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.transformedContentOptions,i=t.parameters,r=p(t,Se),n=h.internalExperience,s=n.contextId,o=n.discriminator;return[e,[h.buildQueryString(d(d({},r),{},{contextId:s,discriminator:o})),h.buildParameterString(i)].join("#")].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),Ee=["scaleToContainer","fitToIframeWidth","locale","parameters","themeOptions","onMessage"],Ae=function(e){function t(e,i,o,l){var c;s(this,t),a(c=n(this,t,[e,i,o,l]),"setParameters",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_PARAMETERS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"reset",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.RESET)))},e)}))),a(c,"addFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.ADD_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"updateFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.UPDATE_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"removeFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.REMOVE_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"getFilterGroups",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_FILTER_GROUPS_FOR_VISUAL));case 1:if(t=e.v,Array.isArray(null==t?void 0:t.message)){e.n=2;break}throw new Error("Failed to retrieve filter groups for the visual");case 2:return e.a(2,t.message)}},e)}))),a(c,"getActions",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_VISUAL_ACTIONS));case 1:if(t=e.v,Array.isArray(null==t?void 0:t.message)){e.n=2;break}throw new Error("Failed to retrieve the actions");case 2:return e.a(2,t.message)}},e)}))),a(c,"addActions",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.ADD_VISUAL_ACTIONS,{Actions:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setActions",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_VISUAL_ACTIONS,{Actions:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"removeActions",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.REMOVE_VISUAL_ACTIONS,{Actions:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setTheme",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_THEME,{ThemeArn:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setThemeOverride",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_THEME_OVERRIDE,{ThemeOverride:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setPreloadThemes",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.PRELOAD_THEMES,{PreloadThemes:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"extractExperienceFromUrl",function(e){var t,i,r=/^https:\/\/[^/]+\/embed\/[^/]+\/dashboards\/([\w-]+)\/sheets\/([\w-]+)\/visuals\/([\w-]+)(\?|$)/i.exec(e)||[];if(r.length<5)throw null===(t=(i=c.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid visual experience url",{url:e}),{frame:c.experienceFrame.iframe}),new Error("Invalid visual experience URL");return{experienceType:O.VISUAL,dashboardId:r[1],sheetId:r[2],visualId:r[3]}}),a(c,"interceptMessage",function(e,t){var i,r,n,s,o;"SIZE_CHANGED"===e.eventName&&c.frameOptions.resizeHeightOnSizeChangedEvent&&!c.contentOptions.scaleToContainer&&(null==t||null===(n=t.frame)||void 0===n||null===(s=n.setAttribute)||void 0===s||s.call(n,"height","".concat(null===(o=e.message)||void 0===o?void 0:o.height,"px"))),"EXPERIENCE_INITIALIZED"===e.eventName&&null!==(i=c.contentOptions)&&void 0!==i&&null!==(i=i.themeOptions)&&void 0!==i&&i.themeOverride&&c.setThemeOverride(c.contentOptions.themeOptions.themeOverride),"EXPERIENCE_INITIALIZED"===e.eventName&&null!==(r=c.contentOptions)&&void 0!==r&&null!==(r=r.themeOptions)&&void 0!==r&&r.preloadThemes&&c.setPreloadThemes(c.contentOptions.themeOptions.preloadThemes)}),a(c,"transformVisualContentOptions",function(e){var t=e.scaleToContainer,i=e.fitToIframeWidth,r=e.locale,n=e.parameters,s=e.themeOptions;e.onMessage;var o=p(e,Ee),l=c.transformContentOptions({scaleToContainer:null!=t&&t,fitToIframeWidth:null==i||i,locale:r},o);return Array.isArray(n)&&(l.parameters=n.reduce(function(e,t){return d(d({},e),{},a({},t.Name,t.Values))},{})),null!=s&&s.themeArn&&(l.themeArn=s.themeArn),l}),c.experience=c.extractExperienceFromUrl(e.url);var u=c.getInternalExperienceInfo(c.experience),h=u.experienceIdentifier,f=u.internalExperience;return c.internalExperience=f,c.experienceId=h,c.experienceFrame=new be(e,o,i,c.transformVisualContentOptions(i),f,h,c.interceptMessage),c}return c(t,e),o(t)}(ce),Te=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.internalExperience,i=t.contextId,r=t.discriminator;return[e,h.buildQueryString(d(d({},h.transformedContentOptions),{},{contextId:i,discriminator:r}))].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),Me=["locale","toolbarOptions","onMessage"],Re=function(e){function t(e,i,o,l){var c;s(this,t),a(c=n(this,t,[e,i,o,l]),"createSharedView",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:if("DASHBOARD"===c.currentPage||"DASHBOARD_SHEET"===c.currentPage||"DASHBOARD_VIEW"===c.currentPage){e.n=1;break}throw new Error("Cannot call createSharedView from this page");case 1:return e.n=2,c.send(new Q(_.CREATE_SHARED_VIEW));case 2:if(null!=(t=e.v)&&t.message){e.n=3;break}throw new Error("Failed to create shared view");case 3:return e.a(2,t)}},e)}))),a(c,"toggleExecutiveSummaryPane",r(g().m(function e(){return g().w(function(e){for(;;)switch(e.n){case 0:if("DASHBOARD"===c.currentPage){e.n=1;break}throw new Error("Cannot call toggleExecutiveSummaryPane from this page");case 1:return e.a(2,c.send(new Q(_.TOGGLE_EXECUTIVE_SUMMARY_PANE)))}},e)}))),a(c,"openDataQnAPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.OPEN_DATA_QNA_PANE)))},e)}))),a(c,"openBuildVisualPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.OPEN_BUILD_VISUAL_PANE)))},e)}))),a(c,"buildStoryFromDashboard",r(g().m(function e(){return g().w(function(e){for(;;)switch(e.n){case 0:if("DASHBOARD"===c.currentPage){e.n=1;break}throw new Error('Cannot call buildStoryFromDashboard from "'.concat(c.currentPage,'" page'));case 1:return e.a(2,c.send(new Q(_.OPEN_BUILD_STORY_PANE)))}},e)}))),a(c,"interceptMessage",function(e,t){var i;e.eventName===_.PAGE_NAVIGATION&&(c.currentPage=null==e||null===(i=e.message)||void 0===i?void 0:i.pageType)}),a(c,"extractExperienceFromUrl",function(e){var t,i;if((/^https:\/\/[^/]+\/embedding\/[^/]+\/(start(\/(favorites|dashboards|analyses))?|dashboards\/[\w-]+(\/views\/[\w-]+)?|analyses\/[\w-]+)(\?|$)/i.exec(e)||[]).length<5)throw null===(t=(i=c.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid console experience url",{url:e}),{frame:c.experienceFrame.iframe}),new Error("Invalid console experience URL");return{experienceType:O.CONSOLE}}),a(c,"transformConsoleContentOptions",function(e){var t=e.locale,i=e.toolbarOptions;e.onMessage;var r=p(e,Me),n=c.transformContentOptions({locale:t},r);return!0===(null==i?void 0:i.executiveSummary)&&(n.showExecutiveSummaryIcon=!0),!0===(null==i?void 0:i.dataQnA)&&(n.showDataQnAIcon=!0),!0===(null==i?void 0:i.buildVisual)&&(n.showBuildVisualIcon=!0),!0===(null==i?void 0:i.buildStory)&&(n.showBuildStoryIcon=!0),n}),c.experience=c.extractExperienceFromUrl(e.url);var u=c.getInternalExperienceInfo(c.experience),h=u.experienceIdentifier,d=u.internalExperience;c.internalExperience=d,c.experienceId=h,i.locale,i.onMessage;var f=c.transformConsoleContentOptions(i);return c.experienceFrame=new Te(e,o,i,f,d,h,c.interceptMessage),c.currentPage="START",c}return c(t,e),o(t)}(ce),_e=["parameters"],Pe=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.transformedContentOptions,i=t.parameters,r=p(t,_e),n=h.internalExperience,s=n.contextId,o=n.discriminator,a=h.contentOptions.viewId;if(a){var l=new URL(e);l.pathname=l.pathname.concat("/views/"+a),e=l.href}return[e,[h.buildQueryString(d(d({},r),{},{contextId:s,discriminator:o})),h.buildParameterString(i)].join("#")].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),xe=["parameters","locale","attributionOptions","sheetOptions","toolbarOptions","themeOptions","onMessage"],De=function(e){function t(e,i,o,l){var c;s(this,t),a(c=n(this,t,[e,i,o,l]),"initiatePrint",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.INITIATE_PRINT)))},e)}))),a(c,"undo",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.UNDO)))},e)}))),a(c,"redo",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.REDO)))},e)}))),a(c,"toggleExecutiveSummaryPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.TOGGLE_EXECUTIVE_SUMMARY_PANE)))},e)}))),a(c,"toggleBookmarksPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.TOGGLE_BOOKMARKS_PANE)))},e)}))),a(c,"toggleThresholdAlertsPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.TOGGLE_THRESHOLD_ALERTS_PANE)))},e)}))),a(c,"toggleSchedulingPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.TOGGLE_SCHEDULING_PANE)))},e)}))),a(c,"toggleRecentSnapshotsPane",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.TOGGLE_RECENT_SNAPSHOTS_PANE)))},e)}))),a(c,"getParameters",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_PARAMETERS));case 1:if(t=e.v,Array.isArray(null==t?void 0:t.message)){e.n=2;break}throw new Error("Failed to retrieve the parameters");case 2:return e.a(2,t.message)}},e)}))),a(c,"getSheets",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_SHEETS));case 1:if(t=e.v,Array.isArray(null==t?void 0:t.message)){e.n=2;break}throw new Error("Failed to retrieve the sheets");case 2:return e.a(2,t.message)}},e)}))),a(c,"addFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.ADD_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"updateFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.UPDATE_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"removeFilterGroups",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.REMOVE_FILTER_GROUPS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"getFilterGroupsForSheet",function(){var e=r(g().m(function e(t){var i;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_FILTER_GROUPS_FOR_SHEET,{SheetId:t}));case 1:if(i=e.v,Array.isArray(null==i?void 0:i.message)){e.n=2;break}throw new Error("Failed to retrieve filter groups for the sheet");case 2:return e.a(2,i.message)}},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"getFilterGroupsForVisual",function(){var e=r(g().m(function e(t,i){var r;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_FILTER_GROUPS_FOR_VISUAL,{SheetId:t,VisualId:i}));case 1:if(r=e.v,Array.isArray(null==r?void 0:r.message)){e.n=2;break}throw new Error("Failed to retrieve filter groups for the visual");case 2:return e.a(2,r.message)}},e)}));return function(t,i){return e.apply(this,arguments)}}()),a(c,"getVisualActions",function(){var e=r(g().m(function e(t,i){var r;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_VISUAL_ACTIONS,{SheetId:t,VisualId:i}));case 1:if(r=e.v,Array.isArray(null==r?void 0:r.message)){e.n=2;break}throw new Error("Failed to retrieve the visual actions");case 2:return e.a(2,r.message)}},e)}));return function(t,i){return e.apply(this,arguments)}}()),a(c,"addVisualActions",function(){var e=r(g().m(function e(t,i,r){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.ADD_VISUAL_ACTIONS,{SheetId:t,VisualId:i,Actions:r})))},e)}));return function(t,i,r){return e.apply(this,arguments)}}()),a(c,"setVisualActions",function(){var e=r(g().m(function e(t,i,r){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_VISUAL_ACTIONS,{SheetId:t,VisualId:i,Actions:r})))},e)}));return function(t,i,r){return e.apply(this,arguments)}}()),a(c,"getSelectedSheetId",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_SELECTED_SHEET_ID));case 1:if(null!=(t=e.v)&&t.message){e.n=2;break}throw new Error("Failed to retrieve the selected sheet id");case 2:return e.a(2,t.message)}},e)}))),a(c,"setSelectedSheetId",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_SELECTED_SHEET_ID,{SheetId:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setTheme",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_THEME,{ThemeArn:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"navigateToDashboard",function(){var e=r(g().m(function e(t,i){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.NAVIGATE_TO_DASHBOARD,{DashboardId:t,Parameters:null==i?void 0:i.parameters})))},e)}));return function(t,i){return e.apply(this,arguments)}}()),a(c,"removeVisualActions",function(){var e=r(g().m(function e(t,i,r){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.REMOVE_VISUAL_ACTIONS,{SheetId:t,VisualId:i,Actions:r})))},e)}));return function(t,i,r){return e.apply(this,arguments)}}()),a(c,"getSheetVisuals",function(){var e=r(g().m(function e(t){var i;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.GET_SHEET_VISUALS,{SheetId:t}));case 1:if(i=e.v,Array.isArray(null==i?void 0:i.message)){e.n=2;break}throw new Error("Failed to retrieve the sheet visuals");case 2:return e.a(2,i.message)}},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setParameters",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_PARAMETERS,t)))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"reset",r(g().m(function e(){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.RESET)))},e)}))),a(c,"setThemeOverride",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.SET_THEME_OVERRIDE,{ThemeOverride:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"setPreloadThemes",function(){var e=r(g().m(function e(t){return g().w(function(e){for(;;)if(0===e.n)return e.a(2,c.send(new Q(_.PRELOAD_THEMES,{PreloadThemes:t})))},e)}));return function(t){return e.apply(this,arguments)}}()),a(c,"createSharedView",r(g().m(function e(){var t;return g().w(function(e){for(;;)switch(e.n){case 0:return e.n=1,c.send(new Q(_.CREATE_SHARED_VIEW));case 1:if(null!=(t=e.v)&&t.message){e.n=2;break}throw new Error("Failed to create shared view");case 2:return e.a(2,t)}},e)}))),a(c,"extractExperienceFromUrl",function(e){var t,i,r=/^https:\/\/[^/]+\/embed\/[^/]+\/dashboards\/([\w-]+)(\?|$)/i.exec(e)||[];if(r.length<3)throw null===(t=(i=c.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid dashboard experience url",{url:e}),{frame:null}),new Error("Invalid dashboard experience URL");return{experienceType:O.DASHBOARD,dashboardId:r[1]}}),a(c,"interceptMessage",function(e,t){var i,r,n,s,o;"SIZE_CHANGED"===e.eventName&&c.frameOptions.resizeHeightOnSizeChangedEvent&&(null==t||null===(n=t.frame)||void 0===n||null===(s=n.setAttribute)||void 0===s||s.call(n,"height","".concat(null==e||null===(o=e.message)||void 0===o?void 0:o.height,"px"))),"EXPERIENCE_INITIALIZED"===e.eventName&&null!==(i=c.contentOptions)&&void 0!==i&&null!==(i=i.themeOptions)&&void 0!==i&&i.themeOverride&&c.setThemeOverride(c.contentOptions.themeOptions.themeOverride),"EXPERIENCE_INITIALIZED"===e.eventName&&null!==(r=c.contentOptions)&&void 0!==r&&null!==(r=r.themeOptions)&&void 0!==r&&r.preloadThemes&&c.setPreloadThemes(c.contentOptions.themeOptions.preloadThemes)}),a(c,"transformDashboardContentOptions",function(e){var t,i,r=e.parameters,n=e.locale,s=e.attributionOptions,o=e.sheetOptions,l=e.toolbarOptions,u=e.themeOptions;e.onMessage;var h=p(e,xe),g=c.transformContentOptions({locale:n,fitSheetToWidth:null===(t=null==o?void 0:o.fitSheetToWidth)||void 0===t||t},h);return Array.isArray(r)&&(g.parameters=r.reduce(function(e,t){return d(d({},e),{},a({},t.Name,t.Values))},{})),!0!==(null==s?void 0:s.overlayContent)&&(g.footerPaddingEnabled=!0),(null!=l&&l.export||null!=l&&null!==(i=l.export)&&void 0!==i&&i.print)&&(g.printEnabled=!0),!0!==(null==l?void 0:l.undoRedo)&&(g.undoRedoDisabled=!0),!0!==(null==l?void 0:l.reset)&&(g.resetDisabled=!0),!0===(null==l?void 0:l.bookmarks)&&(g.showBookmarksIcon=!0),!0===(null==l?void 0:l.thresholdAlerts)&&(g.showThresholdAlertsIcon=!0),!0===(null==l?void 0:l.scheduling)&&(g.showSchedulingIcon=!0),!0===(null==l?void 0:l.executiveSummary)&&(g.showExecutiveSummaryIcon=!0),!0===(null==l?void 0:l.recentSnapshots)&&(g.showRecentSnapshotsIcon=!0),null!=o&&o.initialSheetId&&(g.sheetId=o.initialSheetId),"boolean"==typeof(null==o?void 0:o.singleSheet)&&(g.sheetTabsDisabled=o.singleSheet),null!=o&&o.emitSizeChangedEventOnSheetChange&&(g.resizeOnSheetChange=!0),null!=u&&u.themeArn&&(g.themeArn=u.themeArn),g}),c.experience=c.extractExperienceFromUrl(e.url);var u=c.getInternalExperienceInfo(c.experience),h=u.experienceIdentifier,f=u.internalExperience;return c.internalExperience=f,c.experienceId=h,c.experienceFrame=new Pe(e,o,i,c.transformDashboardContentOptions(i),f,h,c.interceptMessage),c}return c(t,e),o(t)}(ce),Ie=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.internalExperience,i=t.contextId,r=t.discriminator;return[e,h.buildQueryString(d(d({},h.transformedContentOptions),{},{contextId:i,discriminator:r}))].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),Le=function(e){function t(){var e;s(this,t);for(var i=arguments.length,o=new Array(i),l=0;l<i;l++)o[l]=arguments[l];return a(e=n(this,t,[].concat(o)),"close",function(){return e.send(new Q(_.CLOSE_Q_SEARCH))}),a(e,"setQuestion",function(t){return e.send(new Q(_.SET_Q_SEARCH_QUESTION,{question:t}))}),a(e,"trackOutsideClicks",function(){var t=function(){var t=r(g().m(function t(i){var r,n;return g().w(function(t){for(;;)switch(t.p=t.n){case 0:if(null!==(r=e.experienceFrame.iframe)&&void 0!==r&&r.contains(i.target)){t.n=5;break}return t.p=1,t.n=2,e.close();case 2:t.n=5;break;case 3:if(t.p=3,n=t.v,e.experienceFrame.iframe){t.n=4;break}return t.a(2);case 4:throw n;case 5:return t.a(2)}},t,null,[[1,3]])}));return function(e){return t.apply(this,arguments)}}();window.addEventListener("click",t),e.controlOptions.eventManager.addEventListenerForCleanup(e.experienceId,function(){return window.removeEventListener("click",t)})}),a(e,"enterFullScreen",function(i){var r,n;!e.frameStyles&&null!=i&&i.frame&&(e.frameStyles={position:null===(r=i.frame)||void 0===r?void 0:r.style.position,top:null===(n=i.frame)||void 0===n?void 0:n.style.top,left:i.frame.style.left,zIndex:i.frame.style.zIndex,width:i.frame.style.width,height:i.frame.style.height},i.frame.style.position="fixed",i.frame.style.top="0px",i.frame.style.left="0px",i.frame.style.zIndex=t.MAX_Z_INDEX,i.frame.style.width="100vw",i.frame.style.height="100vh")}),a(e,"exitFullScreen",function(t){e.frameStyles&&null!=t&&t.frame&&(t.frame.style.position=e.frameStyles.position,t.frame.style.top=e.frameStyles.top,t.frame.style.left=e.frameStyles.left,t.frame.style.zIndex=e.frameStyles.zIndex,t.frame.style.width=e.frameStyles.width,t.frame.style.height=e.frameStyles.height,e.frameStyles=void 0)}),e}return c(t,e),o(t)}(ce);a(Le,"MAX_Z_INDEX","2147483647");var Ne=["hideIcon","hideTopicName","theme","allowTopicSelection","onMessage"],Oe=function(e){function t(e,i,r,o){var l;s(this,t),a(l=n(this,t,[e,i,r,o]),"extractExperienceFromUrl",function(e){var t,i;if((/^https:\/\/[^/]+\/embedding\/[^/]+\/q\/search(\/|\?|$)/i.exec(e)||[]).length<2)throw null===(t=(i=l.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid q-search experience URL",{url:e}),{frame:l.experienceFrame.iframe}),new Error("Invalid q-search experience URL");return{experienceType:O.QSEARCH}}),a(l,"interceptMessage",function(e,t){switch(e.eventName){case _.Q_SEARCH_OPENED:case _.Q_SEARCH_CLOSED:var i,r;"object"===C(e.message)&&(null==t||null===(i=t.frame)||void 0===i||i.style.setProperty("height","".concat(null==e||null===(r=e.message)||void 0===r?void 0:r.height,"px")));break;case _.CONTENT_LOADED:l.trackOutsideClicks();break;case _.Q_SEARCH_ENTERED_FULLSCREEN:l.enterFullScreen(t);break;case _.Q_SEARCH_EXITED_FULLSCREEN:l.exitFullScreen(t)}}),a(l,"transformQSearchContentOptions",function(e){var t=e.hideIcon,i=e.hideTopicName,r=e.theme,n=e.allowTopicSelection;e.onMessage;var s=p(e,Ne),o=l.transformContentOptions({allowTopicSelection:n},s);return void 0!==t&&(o.qBarIconDisabled=t),void 0!==i&&(o.qBarTopicNameDisabled=i),void 0!==r&&(o.themeId=r),o}),l.experience=l.extractExperienceFromUrl(e.url);var c=l.getInternalExperienceInfo(l.experience),u=c.experienceIdentifier,h=c.internalExperience;return l.internalExperience=h,l.experienceId=u,l.experienceFrame=new Ie(e,r,i,l.transformQSearchContentOptions(i),h,u,l.interceptMessage),l}return c(t,e),o(t)}(Le),Fe=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.internalExperience,i=t.contextId,r=t.discriminator;return[e,h.buildQueryString(d(d({},h.transformedContentOptions),{},{contextId:i,discriminator:r}))].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),ke=["onMessage","showTopicName","showPinboard","showSearchBar","showInterpretedAs","showFeedback","showGeneratedNarrative","showDidYouMean","showComplementaryVisuals","showQBusinessInsights","showSeeWhy","allowTopicSelection","allowFullscreen","allowReturn","searchPlaceholderText","panelOptions","themeOptions","initialQuestionId","initialAnswerId"],Ge=["panelType","title","showQIcon"],Ve=["panelType","focusedHeight","expandedHeight"],He=function(e){function t(e,i,r,o){var l;s(this,t),a(l=n(this,t,[e,i,r,o]),"extractExperienceFromUrl",function(e){var t,i;if((/^https:\/\/[^/]+\/embedding\/[^/]+\/q\/search(\/|\?|$)/i.exec(e)||[]).length<2)throw null===(t=(i=l.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid generative-qna experience URL",{url:e}),{frame:l.experienceFrame.iframe}),new Error("Invalid generative-qna experience URL");return{experienceType:O.GENERATIVEQNA}}),a(l,"interceptMessage",function(e,t){switch(e.eventName){case _.Q_SEARCH_OPENED:case _.Q_SEARCH_CLOSED:case _.Q_SEARCH_FOCUSED:var i,r;"object"===C(e.message)&&(null==t||null===(i=t.frame)||void 0===i||i.style.setProperty("height","".concat(null==e||null===(r=e.message)||void 0===r?void 0:r.height)));break;case _.CONTENT_LOADED:var n;(null===(n=l.contentOptions)||void 0===n||null===(n=n.panelOptions)||void 0===n?void 0:n.panelType)===W.SEARCH_BAR&&l.trackOutsideClicks();break;case _.Q_PANEL_ENTERED_FULLSCREEN:l.enterFullScreen(t);break;case _.Q_PANEL_EXITED_FULLSCREEN:l.exitFullScreen(t)}}),a(l,"transformGenerativeQnAContentOptions",function(e){var t=[],i=function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";Object.keys(e).forEach(function(e){t.push(i+e)})};e.onMessage;var r=e.showTopicName,n=e.showPinboard,s=e.showSearchBar,o=e.showInterpretedAs,a=e.showFeedback,c=e.showGeneratedNarrative,u=e.showDidYouMean,h=e.showComplementaryVisuals,d=e.showQBusinessInsights,g=e.showSeeWhy,f=e.allowTopicSelection,m=e.allowFullscreen,v=e.allowReturn,C=e.searchPlaceholderText,y=e.panelOptions,w=e.themeOptions,S=e.initialQuestionId,b=e.initialAnswerId;i(p(e,ke));var E={qShowTopicName:r,qShowPinboard:n,qShowSearchBar:s,qShowInterpretedAs:o,qShowFeedback:a,qShowGeneratedNarrative:c,qShowDidYouMean:u,qShowComplementaryVisuals:h,qShowQBusinessInsights:d,qShowSeeWhy:g,qAllowTopicSelection:f,qAllowFullscreen:m,qAllowReturn:v,questionId:S,answerId:b};if("string"==typeof C&&(l.checkMaxLength(C,"searchPlaceholderText"),E.qSearchPlaceholderText=encodeURIComponent(C)),y){var A=y.panelType;if(E.qPanelType=A,A===W.FULL){y.panelType;var T=y.title,M=y.showQIcon,R=p(y,Ge);"string"==typeof T&&(l.checkMaxLength(T,"panelOptions.title"),E.qPanelTitle=encodeURIComponent(T)),E.qShowPanelIcon=M,i(R,"panelOptions.")}else{if(A!==W.SEARCH_BAR)throw new Error("panelOptions.panelType should be one of following: [FULL, SEARCH_BAR]");y.panelType;var _=y.focusedHeight,P=y.expandedHeight,x=p(y,Ve);E.qPanelFocusedHeight=_,E.qPanelExpandedHeight=P,i(x,"panelOptions.")}}return null!=w&&w.themeArn&&(E.themeArn=w.themeArn),l.warnUnrecognizedContentOptions(t),E}),a(l,"checkMaxLength",function(e,i){var r=t.TEXT_PROPERTY_MAX_LENGTH;if(e.length>r)throw new Error("".concat(i," should be less than ").concat(r," characters"))}),l.experience=l.extractExperienceFromUrl(e.url);var c=l.getInternalExperienceInfo(l.experience),u=c.experienceIdentifier,h=c.internalExperience;return l.internalExperience=h,l.experienceId=u,l.experienceFrame=new Fe(e,r,i,l.transformGenerativeQnAContentOptions(i),h,u,l.interceptMessage),l}return c(t,e),o(t)}(Le);a(He,"TEXT_PROPERTY_MAX_LENGTH",200);var Be=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.internalExperience,i=t.contextId,r=t.discriminator;return[e,h.buildQueryString(d(d({},h.transformedContentOptions),{},{contextId:i,discriminator:r}))].join("?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),ze=o(function e(t,i,r,n){var o=this;s(this,e),a(this,"experience",{experienceType:O.CONTROL}),a(this,"send",function(e){return o.controlExperienceFrame.send(e)}),a(this,"controlFrameMessageListener",function(e){if(o.isMessageEvent(e.data)){var t=e.data;try{if(t.eventTarget){var i=ce.getExperienceIdentifier(t.eventTarget);o.eventManager.invokeEventListener(i,t)}o.sendAcknowledgment(t)}catch(e){var r,n;null===(r=o.onChange)||void 0===r||r.call(o,new Y(R.UNRECOGNIZED_EVENT_TARGET,P.WARN,"Message with unrecognized event target received",{eventTarget:t.eventTarget}),{frame:o.controlExperienceFrame.iframe}),null===(n=o.logger)||void 0===n||n.warn("Message with unrecognized event target received")}}}),a(this,"sendAcknowledgment",function(e){var t,i,r=new X(_.ACKNOWLEDGE,o.internalExperience,{eventName:e.eventName,eventTarget:e.eventTarget});(null===(t=(i=window).requestIdleCallback)||void 0===t?void 0:t.call(i,function(){return o.send(r)}))||o.send(r)}),a(this,"getControlExperienceId",function(){return[o.internalExperience.contextId,o.internalExperience.experienceType,o.internalExperience.discriminator].filter(Boolean).join("-")}),a(this,"getControlExperienceBaseUrl",function(){var e=o.urlInfo,t=e.host,i=e.sessionId,r="".concat(t,"/embed/").concat(i,"/embedControl");return new URL(r).href}),a(this,"isMessageEvent",function(e){return!!e&&!!e.eventTarget&&!!e.eventName}),this.container=t,this.eventManager=i.eventManager,this.urlInfo=i.urlInfo,this.onChange=r,this.logger=n,this.internalExperience=d(d({},this.experience),{},{contextId:i.contextId,discriminator:0});var l=this.getControlExperienceId();this.controlExperienceFrame=new Be({url:this.getControlExperienceBaseUrl(),container:this.container,width:"0px",height:"0px",onChange:this.onChange},{eventManager:this.eventManager,contextId:this.internalExperience.contextId,timeout:e.FRAME_TIMEOUT,urlInfo:this.urlInfo},{},{},this.internalExperience,l),window.addEventListener("message",this.controlFrameMessageListener),this.eventManager.addEventListenerForCleanup(l,function(){return window.removeEventListener("message",o.controlFrameMessageListener)})});a(ze,"FRAME_TIMEOUT",6e4);var Ue=o(function e(){var t=this;s(this,e),a(this,"addEventListener",function(e,i,r){if(!e)throw new Error("Experience identifier is required when calling addEventListener");if("function"!=typeof i)throw new Error("Invalid type provided for event listener");var n=t.eventListeners.get(e);return r&&t.addEventListenerForCleanup(e,function(){return t.removeEventListener(e,i)}),n?(n.push(i),t):(t.eventListeners.set(e,[i]),t)}),a(this,"invokeEventListener",function(e,i){var r=t.eventListeners.get(e);if(!r)throw new Error("Unable to find experience specific event listeners: ".concat(e));return r.forEach(function(e){e(i)}),t}),a(this,"removeEventListener",function(e,i){var r=t.eventListeners.get(e);if(!r)throw new Error("Unable to find experience specific event listeners: ".concat(e));var n=r.filter(function(e){return e!==i});return t.eventListeners.set(e,n),t}),a(this,"addEventListenerForCleanup",function(e,i){var r,n=null!==(r=t.cleanUpCallbacks.get(e))&&void 0!==r?r:[];n.push(i),t.cleanUpCallbacks.set(e,n)}),a(this,"cleanUpCallbacksForExperience",function(e){var i=t.cleanUpCallbacks.get(e);i&&(i.forEach(function(e){return e()}),t.cleanUpCallbacks.delete(e),t.eventListeners.set(e,[]))}),this.eventListeners=new Map,this.cleanUpCallbacks=new Map}),We=o(function e(){s(this,e),a(this,"log",console.log),a(this,"warn",console.warn),a(this,"error",console.error),a(this,"debug",console.debug),a(this,"info",console.info)}),je=function(e){function t(e,i,r,o,l,c,u){var h;return s(this,t),a(h=n(this,t,[e,i,r,o,l,c,u]),"buildExperienceUrl",function(e){var t=h.internalExperience,i=t.contextId,r=t.discriminator;return[e,h.buildQueryString(d({contextId:i,discriminator:r},h.transformedContentOptions))].join(e.includes("?")?"&":"?")}),h.url=h.buildExperienceUrl(e.url),h.createExperienceIframe(),h}return c(t,e),o(t)}(we),Ke=["fixedAgentArn","agentOptions","promptOptions","footerOptions","onMessage"],$e=["fixedAgentId"],qe=["allowFileAttachments","showAgentKnowledgeBoundary","initialPrompt","showWebSearch"],Ye=["showBrandAttribution","showUsagePolicy"],Qe=function(e){function t(e,i,r,o){var l;s(this,t);var c=d({framePermissions:d({clipboardRead:!0,clipboardWrite:!0},e.framePermissions)},e);a(l=n(this,t,[c,i,r,o]),"extractExperienceFromUrl",function(e){var t,i;if((/^https:\/\/[^/]+\/embedding\/[^/]+\/quick\/chat(\/|\?|$)/i.exec(e)||[]).length<2)throw null===(t=(i=l.frameOptions).onChange)||void 0===t||t.call(i,new Y(R.INVALID_URL,P.ERROR,"Invalid quick chat experience url",{url:e}),{frame:null}),new Error("Invalid quick chat experience url");return{experienceType:O.QUICKCHAT}}),a(l,"interceptMessage",function(e,t){var i;e.eventName===_.EXPERIENCE_INITIALIZED&&null!==(i=l.contentOptions.promptOptions)&&void 0!==i&&i.initialPrompt&&l.sendPrompt(l.contentOptions.promptOptions.initialPrompt)}),a(l,"sendPrompt",function(e){return l.send(new Q(_.SEND_PROMPT,{prompt:e}))}),a(l,"transformQuickChatContentOptions",function(e){var t=[],i=function(e){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";Object.keys(e).forEach(function(e){t.push(i+e)})},r=e.fixedAgentArn,n=e.agentOptions,s=void 0===n?{}:n,o=e.promptOptions,a=void 0===o?{}:o,c=e.footerOptions,u=void 0===c?{}:c;e.onMessage,i(p(e,Ke));var h=s.fixedAgentId;i(p(s,$e),"agentOptions.");var d=a.allowFileAttachments,g=a.showAgentKnowledgeBoundary;a.initialPrompt;var f=a.showWebSearch;i(p(a,qe),"promptOptions.");var m=u.showBrandAttribution,v=u.showUsagePolicy;return i(p(u,Ye),"footerOptions."),l.warnUnrecognizedContentOptions(t),{allowFileAttachments:d,showAgentKnowledgeBoundary:g,showBrandAttribution:m,showUsagePolicy:v,showWebSearch:f,fixedAgentId:l.validateFixedAgentId(r,h)}}),a(l,"validateFixedAgentId",function(e,t){if(e&&t)throw new Error("Both fixedAgentArn and agentOptions.fixedAgentId cannot be specified. Use agentOptions.fixedAgentId.");if(t)return t;if(e){var i;null===(i=l.logger)||void 0===i||i.warn("The fixedAgentArn option is deprecated. Use agentOptions.fixedAgentId instead.");var r=e.split("/")[1];if(!r)throw new Error("Invalid fixedAgentArn.");return r}}),l.experience=l.extractExperienceFromUrl(c.url);var u=l.getInternalExperienceInfo(l.experience),h=u.experienceIdentifier,g=u.internalExperience;return l.internalExperience=g,l.experienceId=h,l.experienceFrame=new je(c,r,i,l.transformQuickChatContentOptions(i),g,h,l.interceptMessage),l}return c(t,e),o(t)}(ce),Xe=o(function e(t){var i=this;s(this,e),a(this,"embedVisual",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedVisual"),n=i.buildControlOptions(t),e.a(2,new Ae(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"embedDashboard",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedDashboard"),n=i.buildControlOptions(t),e.a(2,new De(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"embedConsole",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedConsole"),n=i.buildControlOptions(t),e.a(2,new Re(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"embedQSearchBar",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedQSearchBar"),n=i.buildControlOptions(t),e.a(2,new Oe(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"embedGenerativeQnA",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedGenerativeQnA"),n=i.buildControlOptions(t),e.a(2,new He(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"embedQuickChat",function(){var e=r(g().m(function e(t){var r,n,s=arguments;return g().w(function(e){for(;;)if(0===e.n)return r=s.length>1&&void 0!==s[1]?s[1]:{},i.validateFrameOptions(t,"embedQuickChat"),n=i.buildControlOptions(t),e.a(2,new Qe(t,r,n,i.experienceIdentifiers).setLogProvider(i.logger))},e)}));return function(t){return e.apply(this,arguments)}}()),a(this,"validateFrameOptions",function(e,t){if(!e){var r="".concat(t," is called without frameOptions");throw i.onChange(new Y(R.NO_FRAME_OPTIONS,P.ERROR,"".concat(t," is called without frameOptions"),{methodName:t}),{frame:null}),new Error(r)}if("object"!==C(e)||Array.isArray(e)){var n="".concat(t," is called with non-object frameOptions");throw i.onChange(new Y(R.INVALID_FRAME_OPTIONS,P.ERROR,n,{methodName:t,frameOptionsType:Array.isArray(e)?"array":C(e)}),{frame:null}),new Error(n)}var s=["url","container","width","height","resizeHeightOnSizeChangedEvent","withIframePlaceholder","onChange","className","framePermissions"],o=Object.keys(e).filter(function(e){return!s.includes(e)});if(o.length>0){var a,l,c="".concat(t," is called with unrecognized properties");null===(a=e.onChange)||void 0===a||a.call(e,new Y(R.UNRECOGNIZED_FRAME_OPTIONS,P.WARN,c,{unrecognizedFrameOptions:o}),{frame:null}),null===(l=i.logger)||void 0===l||l.warn(c)}}),a(this,"buildControlOptions",function(e){if(!i.controlOptions){if(!e.url)throw new Error("URL is missing in frame options, but is a required field");var t=i.getControlUrlInfo(e.url),r=new ze(i.getBodyElement(),{eventManager:i.eventManager,urlInfo:t,contextId:i.contextId},i.onChange,i.logger);i.controlOptions={eventManager:i.eventManager,sendToControlFrame:r.send,contextId:i.contextId,timeout:ze.FRAME_TIMEOUT,urlInfo:t}}return i.controlOptions}),a(this,"onChange",function(e,t){i.contextOnChange&&i.contextOnChange(e,t)}),a(this,"getControlUrlInfo",function(e){var t=/^(https:\/\/[^/]+)\/(embedding|embed)\/([^/]+)\/[^?]+\?(.*)/i.exec(e)||[];if((null==t?void 0:t.length)<4)throw new Error('Invalid embedding url: "'.concat(e,'"'));return{sessionId:t[3],host:t[1],urlSearchParams:new URLSearchParams(t[4])}}),a(this,"getBodyElement",function(){var e,t=null===(e=document.getElementsByTagName("body"))||void 0===e?void 0:e[0];if(!t){var r="could not locate <body> element in the page";throw i.onChange(new Y(R.NO_BODY,P.ERROR,r),{frame:null}),new Error(r)}return t}),this.contextId=le(),this.experienceIdentifiers=new Set,this.eventManager=new Ue,this.contextOnChange=t.onChange,this.logger=new We}),Ze=function(){var e=r(g().m(function e(){var t,i=arguments;return g().w(function(e){for(;;)if(0===e.n)return t=i.length>0&&void 0!==i[0]?i[0]:{},e.a(2,new Xe(t))},e)}));return function(){return e.apply(this,arguments)}}(),Je=d(d(d(d(d(d(d(d(d(d(d(d(d(d(d({},N),M),x),D),I),L),F),k),H),z),B),U),j),K),$);e.BaseExperience=ce,e.BaseExperienceFrame=we,e.CALCULATED_METRIC_COLUMN_TYPE=V,e.ChangeEvent=Y,e.ChangeEventLevel=P,e.ChangeEventName=R,e.ConsoleExperience=Re,e.ConsoleExperienceFrame=Te,e.ControlExperience=ze,e.ControlExperienceFrame=Be,e.DashboardExperience=De,e.DashboardExperienceFrame=Pe,e.DataResponse=ie,e.DefaultLogger=We,e.EmbeddingContext=Xe,e.EmbeddingEvent=q,e.EmbeddingMessageEvent=Q,e.ErrorChangeEventName=S,e.ErrorResponse=te,e.EventManager=Ue,e.ExperienceType=O,e.GenerativeQnAExperience=He,e.GenerativeQnAExperienceFrame=Fe,e.GenerativeQnAPanelType=W,e.GetterMessageEventName=A,e.Iframe=Ce,e.InfoChangeEventName=w,e.InfoMessageEventName=y,e.InternalQBaseExperience=Le,e.InvokerMessageEventName=T,e.MessageEventName=_,e.PostMessageEvent=Z,e.QSE=Je,e.QSearchExperience=Oe,e.QSearchExperienceFrame=Ie,e.QuickChatExperience=Qe,e.QuickChatExperienceFrame=je,e.ResponseMessage=J,e.SDK_VERSION=ye,e.SPECIAL_DATAPOINT_VALUE_TYPES=G,e.SetterMessageEventName=E,e.SuccessResponse=ee,e.TargetedMessageEvent=X,e.VisualExperience=Ae,e.VisualExperienceFrame=be,e.WarnChangeEventName=b,e.createEmbeddingContext=Ze}(t)},96411(e,t,i){"use strict";i.d(t,{G:()=>v});var r=i(3224),n=i(17303),s=i(74140),o=i(38383),a=i.n(o),l=i(74831);function c(e){return e.query.definitions.find(e=>"OperationDefinition"===e.kind)}var u=i(74579),h=i.n(u);const d={shouldHandleOperation:void 0,uri:void 0,setTransaction:!0,setFingerprint:!0,attachBreadcrumbs:{includeQuery:!1,includeVariables:!1,includeFetchResult:!1,includeError:!1,includeCache:!1,includeContext:!1,transform:void 0}};var p=i(6613),g=i(74765);function f(e){return JSON.stringify(e,null,2)}function m(e,t,i){const r=i.attachBreadcrumbs&&"function"==typeof i.attachBreadcrumbs.transform?i.attachBreadcrumbs.transform(t,e):t;r.data=function(e){const t={};for(const[i,r]of Object.entries(e))t[i]="object"==typeof r?f(r):r;return t}(r.data),(0,g.Z)(r)}class v extends r.C{options;constructor(e={}){super(),this.options=function(e){return h()(d,e)}(e)}request(e,t){const{options:i}=this;if(!(i.shouldHandleOperation?.(e)??1))return t(e);i.setTransaction&&function(e){const t=c(e).name;t&&(0,p.o5)().setTransactionName(t.value)}(e),i.setFingerprint&&function(e){const t=c(e).name;t&&(0,p.o5)().setFingerprint(["{{ default }}",t.value])}(e);const{attachBreadcrumbs:r}=i;if(!r)return t(e);const o=function(e,t){const i=t.attachBreadcrumbs,r=c(e),n={},s=t.uri;s&&(n.url=s);const o=r.name?.value;o&&(n.operationName=o),i.includeQuery&&(n.query=r.loc?.source?.body??(0,l.y)(r)),i.includeVariables&&(n.variables=e.variables),i.includeCache&&(n.cache=e.getContext().cache?.data?.data??void 0);const u=i.includeContext;return u&&(n.context=function(e,t){const i={};return t.forEach(t=>{i[t]=a().get(e,t)}),i}(e.getContext(),u)),{type:"http",category:`graphql.${r.operation}`,data:n}}(e,i);return new s.c(s=>{const a=t(e).subscribe({next:e=>{o.level=function(e){return e.errors&&e.errors.length>0?"error":"info"}(e),r.includeFetchResult&&(o.data.fetchResult=e),r.includeError&&e.errors&&e.errors.length>0&&(o.data.error=new n.K4({graphQLErrors:e.errors})),s.next(e)},complete:()=>{m(e,o,i),s.complete()},error:t=>{let n;if(o.level="error",function(e){return"object"==typeof e&&null!==e&&"response"in e&&"result"in e&&"statusCode"in e}(t)){const{result:e,response:i,...s}=t;n=s,r.includeFetchResult&&(o.data.fetchResult=e)}else n=t;r.includeError&&(o.data.error=n),m(e,o,i),s.error(t)}});return()=>{a.unsubscribe()}})}}},78071(e,t,i){var r=t;r.bignum=i(5630),r.define=i(92300).define,r.base=i(73160),r.constants=i(36622),r.decoders=i(81300),r.encoders=i(36028)},92300(e,t,i){var r=i(78071),n=i(91193);function s(e,t){this.name=e,this.body=t,this.decoders={},this.encoders={}}t.define=function(e,t){return new s(e,t)},s.prototype._createNamed=function(e){var t;try{t=i(92785).runInThisContext("(function "+this.name+"(entity) {\n  this._initNamed(entity);\n})")}catch(e){t=function(e){this._initNamed(e)}}return n(t,e),t.prototype._initNamed=function(t){e.call(this,t)},new t(this)},s.prototype._getDecoder=function(e){return e=e||"der",this.decoders.hasOwnProperty(e)||(this.decoders[e]=this._createNamed(r.decoders[e])),this.decoders[e]},s.prototype.decode=function(e,t,i){return this._getDecoder(t).decode(e,i)},s.prototype._getEncoder=function(e){return e=e||"der",this.encoders.hasOwnProperty(e)||(this.encoders[e]=this._createNamed(r.encoders[e])),this.encoders[e]},s.prototype.encode=function(e,t,i){return this._getEncoder(t).encode(e,i)}},86216(e,t,i){var r=i(91193),n=i(73160).Reporter,s=i(77511).Buffer;function o(e,t){n.call(this,t),s.isBuffer(e)?(this.base=e,this.offset=0,this.length=e.length):this.error("Input not Buffer")}function a(e,t){if(Array.isArray(e))this.length=0,this.value=e.map(function(e){return e instanceof a||(e=new a(e,t)),this.length+=e.length,e},this);else if("number"==typeof e){if(!(0<=e&&e<=255))return t.error("non-byte EncoderBuffer value");this.value=e,this.length=1}else if("string"==typeof e)this.value=e,this.length=s.byteLength(e);else{if(!s.isBuffer(e))return t.error("Unsupported type: "+typeof e);this.value=e,this.length=e.length}}r(o,n),t.t=o,o.prototype.save=function(){return{offset:this.offset,reporter:n.prototype.save.call(this)}},o.prototype.restore=function(e){var t=new o(this.base);return t.offset=e.offset,t.length=this.offset,this.offset=e.offset,n.prototype.restore.call(this,e.reporter),t},o.prototype.isEmpty=function(){return this.offset===this.length},o.prototype.readUInt8=function(e){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(e||"DecoderBuffer overrun")},o.prototype.skip=function(e,t){if(!(this.offset+e<=this.length))return this.error(t||"DecoderBuffer overrun");var i=new o(this.base);return i._reporterState=this._reporterState,i.offset=this.offset,i.length=this.offset+e,this.offset+=e,i},o.prototype.raw=function(e){return this.base.slice(e?e.offset:this.offset,this.length)},t.d=a,a.prototype.join=function(e,t){return e||(e=new s(this.length)),t||(t=0),0===this.length||(Array.isArray(this.value)?this.value.forEach(function(i){i.join(e,t),t+=i.length}):("number"==typeof this.value?e[t]=this.value:"string"==typeof this.value?e.write(this.value,t):s.isBuffer(this.value)&&this.value.copy(e,t),t+=this.length)),e}},73160(e,t,i){var r=t;r.Reporter=i(18031).a,r.DecoderBuffer=i(86216).t,r.EncoderBuffer=i(86216).d,r.Node=i(13558)},13558(e,t,i){var r=i(73160).Reporter,n=i(73160).EncoderBuffer,s=i(73160).DecoderBuffer,o=i(35578),a=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],l=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(a);function c(e,t){var i={};this._baseState=i,i.enc=e,i.parent=t||null,i.children=null,i.tag=null,i.args=null,i.reverseArgs=null,i.choice=null,i.optional=!1,i.any=!1,i.obj=!1,i.use=null,i.useDecoder=null,i.key=null,i.default=null,i.explicit=null,i.implicit=null,i.contains=null,i.parent||(i.children=[],this._wrap())}e.exports=c;var u=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];c.prototype.clone=function(){var e=this._baseState,t={};u.forEach(function(i){t[i]=e[i]});var i=new this.constructor(t.parent);return i._baseState=t,i},c.prototype._wrap=function(){var e=this._baseState;l.forEach(function(t){this[t]=function(){var i=new this.constructor(this);return e.children.push(i),i[t].apply(i,arguments)}},this)},c.prototype._init=function(e){var t=this._baseState;o(null===t.parent),e.call(this),t.children=t.children.filter(function(e){return e._baseState.parent===this},this),o.equal(t.children.length,1,"Root node can have only one child")},c.prototype._useArgs=function(e){var t=this._baseState,i=e.filter(function(e){return e instanceof this.constructor},this);e=e.filter(function(e){return!(e instanceof this.constructor)},this),0!==i.length&&(o(null===t.children),t.children=i,i.forEach(function(e){e._baseState.parent=this},this)),0!==e.length&&(o(null===t.args),t.args=e,t.reverseArgs=e.map(function(e){if("object"!=typeof e||e.constructor!==Object)return e;var t={};return Object.keys(e).forEach(function(i){i==(0|i)&&(i|=0);var r=e[i];t[r]=i}),t}))},["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"].forEach(function(e){c.prototype[e]=function(){var t=this._baseState;throw new Error(e+" not implemented for encoding: "+t.enc)}}),a.forEach(function(e){c.prototype[e]=function(){var t=this._baseState,i=Array.prototype.slice.call(arguments);return o(null===t.tag),t.tag=e,this._useArgs(i),this}}),c.prototype.use=function(e){o(e);var t=this._baseState;return o(null===t.use),t.use=e,this},c.prototype.optional=function(){return this._baseState.optional=!0,this},c.prototype.def=function(e){var t=this._baseState;return o(null===t.default),t.default=e,t.optional=!0,this},c.prototype.explicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.explicit=e,this},c.prototype.implicit=function(e){var t=this._baseState;return o(null===t.explicit&&null===t.implicit),t.implicit=e,this},c.prototype.obj=function(){var e=this._baseState,t=Array.prototype.slice.call(arguments);return e.obj=!0,0!==t.length&&this._useArgs(t),this},c.prototype.key=function(e){var t=this._baseState;return o(null===t.key),t.key=e,this},c.prototype.any=function(){return this._baseState.any=!0,this},c.prototype.choice=function(e){var t=this._baseState;return o(null===t.choice),t.choice=e,this._useArgs(Object.keys(e).map(function(t){return e[t]})),this},c.prototype.contains=function(e){var t=this._baseState;return o(null===t.use),t.contains=e,this},c.prototype._decode=function(e,t){var i=this._baseState;if(null===i.parent)return e.wrapResult(i.children[0]._decode(e,t));var r,n=i.default,o=!0,a=null;if(null!==i.key&&(a=e.enterKey(i.key)),i.optional){var l=null;if(null!==i.explicit?l=i.explicit:null!==i.implicit?l=i.implicit:null!==i.tag&&(l=i.tag),null!==l||i.any){if(o=this._peekTag(e,l,i.any),e.isError(o))return o}else{var c=e.save();try{null===i.choice?this._decodeGeneric(i.tag,e,t):this._decodeChoice(e,t),o=!0}catch(e){o=!1}e.restore(c)}}if(i.obj&&o&&(r=e.enterObject()),o){if(null!==i.explicit){var u=this._decodeTag(e,i.explicit);if(e.isError(u))return u;e=u}var h=e.offset;if(null===i.use&&null===i.choice){i.any&&(c=e.save());var d=this._decodeTag(e,null!==i.implicit?i.implicit:i.tag,i.any);if(e.isError(d))return d;i.any?n=e.raw(c):e=d}if(t&&t.track&&null!==i.tag&&t.track(e.path(),h,e.length,"tagged"),t&&t.track&&null!==i.tag&&t.track(e.path(),e.offset,e.length,"content"),i.any||(n=null===i.choice?this._decodeGeneric(i.tag,e,t):this._decodeChoice(e,t)),e.isError(n))return n;if(i.any||null!==i.choice||null===i.children||i.children.forEach(function(i){i._decode(e,t)}),i.contains&&("octstr"===i.tag||"bitstr"===i.tag)){var p=new s(n);n=this._getUse(i.contains,e._reporterState.obj)._decode(p,t)}}return i.obj&&o&&(n=e.leaveObject(r)),null===i.key||null===n&&!0!==o?null!==a&&e.exitKey(a):e.leaveKey(a,i.key,n),n},c.prototype._decodeGeneric=function(e,t,i){var r=this._baseState;return"seq"===e||"set"===e?null:"seqof"===e||"setof"===e?this._decodeList(t,e,r.args[0],i):/str$/.test(e)?this._decodeStr(t,e,i):"objid"===e&&r.args?this._decodeObjid(t,r.args[0],r.args[1],i):"objid"===e?this._decodeObjid(t,null,null,i):"gentime"===e||"utctime"===e?this._decodeTime(t,e,i):"null_"===e?this._decodeNull(t,i):"bool"===e?this._decodeBool(t,i):"objDesc"===e?this._decodeStr(t,e,i):"int"===e||"enum"===e?this._decodeInt(t,r.args&&r.args[0],i):null!==r.use?this._getUse(r.use,t._reporterState.obj)._decode(t,i):t.error("unknown tag: "+e)},c.prototype._getUse=function(e,t){var i=this._baseState;return i.useDecoder=this._use(e,t),o(null===i.useDecoder._baseState.parent),i.useDecoder=i.useDecoder._baseState.children[0],i.implicit!==i.useDecoder._baseState.implicit&&(i.useDecoder=i.useDecoder.clone(),i.useDecoder._baseState.implicit=i.implicit),i.useDecoder},c.prototype._decodeChoice=function(e,t){var i=this._baseState,r=null,n=!1;return Object.keys(i.choice).some(function(s){var o=e.save(),a=i.choice[s];try{var l=a._decode(e,t);if(e.isError(l))return!1;r={type:s,value:l},n=!0}catch(t){return e.restore(o),!1}return!0},this),n?r:e.error("Choice not matched")},c.prototype._createEncoderBuffer=function(e){return new n(e,this.reporter)},c.prototype._encode=function(e,t,i){var r=this._baseState;if(null===r.default||r.default!==e){var n=this._encodeValue(e,t,i);if(void 0!==n&&!this._skipDefault(n,t,i))return n}},c.prototype._encodeValue=function(e,t,i){var n=this._baseState;if(null===n.parent)return n.children[0]._encode(e,t||new r);var s=null;if(this.reporter=t,n.optional&&void 0===e){if(null===n.default)return;e=n.default}var o=null,a=!1;if(n.any)s=this._createEncoderBuffer(e);else if(n.choice)s=this._encodeChoice(e,t);else if(n.contains)o=this._getUse(n.contains,i)._encode(e,t),a=!0;else if(n.children)o=n.children.map(function(i){if("null_"===i._baseState.tag)return i._encode(null,t,e);if(null===i._baseState.key)return t.error("Child should have a key");var r=t.enterKey(i._baseState.key);if("object"!=typeof e)return t.error("Child expected, but input is not object");var n=i._encode(e[i._baseState.key],t,e);return t.leaveKey(r),n},this).filter(function(e){return e}),o=this._createEncoderBuffer(o);else if("seqof"===n.tag||"setof"===n.tag){if(!n.args||1!==n.args.length)return t.error("Too many args for : "+n.tag);if(!Array.isArray(e))return t.error("seqof/setof, but data is not Array");var l=this.clone();l._baseState.implicit=null,o=this._createEncoderBuffer(e.map(function(i){var r=this._baseState;return this._getUse(r.args[0],e)._encode(i,t)},l))}else null!==n.use?s=this._getUse(n.use,i)._encode(e,t):(o=this._encodePrimitive(n.tag,e),a=!0);if(!n.any&&null===n.choice){var c=null!==n.implicit?n.implicit:n.tag,u=null===n.implicit?"universal":"context";null===c?null===n.use&&t.error("Tag could be omitted only for .use()"):null===n.use&&(s=this._encodeComposite(c,a,u,o))}return null!==n.explicit&&(s=this._encodeComposite(n.explicit,!1,"context",s)),s},c.prototype._encodeChoice=function(e,t){var i=this._baseState,r=i.choice[e.type];return r||o(!1,e.type+" not found in "+JSON.stringify(Object.keys(i.choice))),r._encode(e.value,t)},c.prototype._encodePrimitive=function(e,t){var i=this._baseState;if(/str$/.test(e))return this._encodeStr(t,e);if("objid"===e&&i.args)return this._encodeObjid(t,i.reverseArgs[0],i.args[1]);if("objid"===e)return this._encodeObjid(t,null,null);if("gentime"===e||"utctime"===e)return this._encodeTime(t,e);if("null_"===e)return this._encodeNull();if("int"===e||"enum"===e)return this._encodeInt(t,i.args&&i.reverseArgs[0]);if("bool"===e)return this._encodeBool(t);if("objDesc"===e)return this._encodeStr(t,e);throw new Error("Unsupported tag: "+e)},c.prototype._isNumstr=function(e){return/^[0-9 ]*$/.test(e)},c.prototype._isPrintstr=function(e){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(e)}},18031(e,t,i){var r=i(91193);function n(e){this._reporterState={obj:null,path:[],options:e||{},errors:[]}}function s(e,t){this.path=e,this.rethrow(t)}t.a=n,n.prototype.isError=function(e){return e instanceof s},n.prototype.save=function(){var e=this._reporterState;return{obj:e.obj,pathLen:e.path.length}},n.prototype.restore=function(e){var t=this._reporterState;t.obj=e.obj,t.path=t.path.slice(0,e.pathLen)},n.prototype.enterKey=function(e){return this._reporterState.path.push(e)},n.prototype.exitKey=function(e){var t=this._reporterState;t.path=t.path.slice(0,e-1)},n.prototype.leaveKey=function(e,t,i){var r=this._reporterState;this.exitKey(e),null!==r.obj&&(r.obj[t]=i)},n.prototype.path=function(){return this._reporterState.path.join("/")},n.prototype.enterObject=function(){var e=this._reporterState,t=e.obj;return e.obj={},t},n.prototype.leaveObject=function(e){var t=this._reporterState,i=t.obj;return t.obj=e,i},n.prototype.error=function(e){var t,i=this._reporterState,r=e instanceof s;if(t=r?e:new s(i.path.map(function(e){return"["+JSON.stringify(e)+"]"}).join(""),e.message||e,e.stack),!i.options.partial)throw t;return r||i.errors.push(t),t},n.prototype.wrapResult=function(e){var t=this._reporterState;return t.options.partial?{result:this.isError(e)?null:e,errors:t.errors}:e},r(s,Error),s.prototype.rethrow=function(e){if(this.message=e+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,s),!this.stack)try{throw new Error(this.message)}catch(e){this.stack=e.stack}return this}},4029(e,t,i){var r=i(36622);t.tagClass={0:"universal",1:"application",2:"context",3:"private"},t.tagClassByName=r._reverse(t.tagClass),t.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},t.tagByName=r._reverse(t.tag)},36622(e,t,i){var r=t;r._reverse=function(e){var t={};return Object.keys(e).forEach(function(i){(0|i)==i&&(i|=0);var r=e[i];t[r]=i}),t},r.der=i(4029)},87779(e,t,i){var r=i(91193),n=i(78071),s=n.base,o=n.bignum,a=n.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){s.Node.call(this,"der",e)}function u(e,t){var i=e.readUInt8(t);if(e.isError(i))return i;var r=a.tagClass[i>>6],n=!(32&i);if(31&~i)i&=31;else{var s=i;for(i=0;!(128&~s);){if(s=e.readUInt8(t),e.isError(s))return s;i<<=7,i|=127&s}}return{cls:r,primitive:n,tag:i,tagStr:a.tag[i]}}function h(e,t,i){var r=e.readUInt8(i);if(e.isError(r))return r;if(!t&&128===r)return null;if(!(128&r))return r;var n=127&r;if(n>4)return e.error("length octect is too long");r=0;for(var s=0;s<n;s++){r<<=8;var o=e.readUInt8(i);if(e.isError(o))return o;r|=o}return r}e.exports=l,l.prototype.decode=function(e,t){return e instanceof s.DecoderBuffer||(e=new s.DecoderBuffer(e,t)),this.tree._decode(e,t)},r(c,s.Node),c.prototype._peekTag=function(e,t,i){if(e.isEmpty())return!1;var r=e.save(),n=u(e,'Failed to peek tag: "'+t+'"');return e.isError(n)?n:(e.restore(r),n.tag===t||n.tagStr===t||n.tagStr+"of"===t||i)},c.prototype._decodeTag=function(e,t,i){var r=u(e,'Failed to decode tag of "'+t+'"');if(e.isError(r))return r;var n=h(e,r.primitive,'Failed to get length of "'+t+'"');if(e.isError(n))return n;if(!i&&r.tag!==t&&r.tagStr!==t&&r.tagStr+"of"!==t)return e.error('Failed to match tag: "'+t+'"');if(r.primitive||null!==n)return e.skip(n,'Failed to match body of: "'+t+'"');var s=e.save(),o=this._skipUntilEnd(e,'Failed to skip indefinite length body: "'+this.tag+'"');return e.isError(o)?o:(n=e.offset-s.offset,e.restore(s),e.skip(n,'Failed to match body of: "'+t+'"'))},c.prototype._skipUntilEnd=function(e,t){for(;;){var i=u(e,t);if(e.isError(i))return i;var r,n=h(e,i.primitive,t);if(e.isError(n))return n;if(r=i.primitive||null!==n?e.skip(n):this._skipUntilEnd(e,t),e.isError(r))return r;if("end"===i.tagStr)break}},c.prototype._decodeList=function(e,t,i,r){for(var n=[];!e.isEmpty();){var s=this._peekTag(e,"end");if(e.isError(s))return s;var o=i.decode(e,"der",r);if(e.isError(o)&&s)break;n.push(o)}return n},c.prototype._decodeStr=function(e,t){if("bitstr"===t){var i=e.readUInt8();return e.isError(i)?i:{unused:i,data:e.raw()}}if("bmpstr"===t){var r=e.raw();if(r.length%2==1)return e.error("Decoding of string type: bmpstr length mismatch");for(var n="",s=0;s<r.length/2;s++)n+=String.fromCharCode(r.readUInt16BE(2*s));return n}if("numstr"===t){var o=e.raw().toString("ascii");return this._isNumstr(o)?o:e.error("Decoding of string type: numstr unsupported characters")}if("octstr"===t)return e.raw();if("objDesc"===t)return e.raw();if("printstr"===t){var a=e.raw().toString("ascii");return this._isPrintstr(a)?a:e.error("Decoding of string type: printstr unsupported characters")}return/str$/.test(t)?e.raw().toString():e.error("Decoding of string type: "+t+" unsupported")},c.prototype._decodeObjid=function(e,t,i){for(var r,n=[],s=0;!e.isEmpty();){var o=e.readUInt8();s<<=7,s|=127&o,128&o||(n.push(s),s=0)}128&o&&n.push(s);var a=n[0]/40|0,l=n[0]%40;if(r=i?n:[a,l].concat(n.slice(1)),t){var c=t[r.join(" ")];void 0===c&&(c=t[r.join(".")]),void 0!==c&&(r=c)}return r},c.prototype._decodeTime=function(e,t){var i=e.raw().toString();if("gentime"===t)var r=0|i.slice(0,4),n=0|i.slice(4,6),s=0|i.slice(6,8),o=0|i.slice(8,10),a=0|i.slice(10,12),l=0|i.slice(12,14);else{if("utctime"!==t)return e.error("Decoding "+t+" time is not supported yet");r=0|i.slice(0,2),n=0|i.slice(2,4),s=0|i.slice(4,6),o=0|i.slice(6,8),a=0|i.slice(8,10),l=0|i.slice(10,12),r=r<70?2e3+r:1900+r}return Date.UTC(r,n-1,s,o,a,l,0)},c.prototype._decodeNull=function(e){return null},c.prototype._decodeBool=function(e){var t=e.readUInt8();return e.isError(t)?t:0!==t},c.prototype._decodeInt=function(e,t){var i=e.raw(),r=new o(i);return t&&(r=t[r.toString(10)]||r),r},c.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getDecoder("der").tree}},81300(e,t,i){var r=t;r.der=i(87779),r.pem=i(71222)},71222(e,t,i){var r=i(91193),n=i(77511).Buffer,s=i(87779);function o(e){s.call(this,e),this.enc="pem"}r(o,s),e.exports=o,o.prototype.decode=function(e,t){for(var i=e.toString().split(/[\r\n]+/g),r=t.label.toUpperCase(),o=/^-----(BEGIN|END) ([^-]+)-----$/,a=-1,l=-1,c=0;c<i.length;c++){var u=i[c].match(o);if(null!==u&&u[2]===r){if(-1!==a){if("END"!==u[1])break;l=c;break}if("BEGIN"!==u[1])break;a=c}}if(-1===a||-1===l)throw new Error("PEM section not found for: "+r);var h=i.slice(a+1,l).join("");h.replace(/[^a-z0-9\+\/=]+/gi,"");var d=new n(h,"base64");return s.prototype.decode.call(this,d,t)}},99291(e,t,i){var r=i(91193),n=i(77511).Buffer,s=i(78071),o=s.base,a=s.constants.der;function l(e){this.enc="der",this.name=e.name,this.entity=e,this.tree=new c,this.tree._init(e.body)}function c(e){o.Node.call(this,"der",e)}function u(e){return e<10?"0"+e:e}e.exports=l,l.prototype.encode=function(e,t){return this.tree._encode(e,t).join()},r(c,o.Node),c.prototype._encodeComposite=function(e,t,i,r){var s,o=function(e,t,i,r){var n;if("seqof"===e?e="seq":"setof"===e&&(e="set"),a.tagByName.hasOwnProperty(e))n=a.tagByName[e];else{if("number"!=typeof e||(0|e)!==e)return r.error("Unknown tag: "+e);n=e}return n>=31?r.error("Multi-octet tag encoding unsupported"):(t||(n|=32),n|=a.tagClassByName[i||"universal"]<<6)}(e,t,i,this.reporter);if(r.length<128)return(s=new n(2))[0]=o,s[1]=r.length,this._createEncoderBuffer([s,r]);for(var l=1,c=r.length;c>=256;c>>=8)l++;(s=new n(2+l))[0]=o,s[1]=128|l,c=1+l;for(var u=r.length;u>0;c--,u>>=8)s[c]=255&u;return this._createEncoderBuffer([s,r])},c.prototype._encodeStr=function(e,t){if("bitstr"===t)return this._createEncoderBuffer([0|e.unused,e.data]);if("bmpstr"===t){for(var i=new n(2*e.length),r=0;r<e.length;r++)i.writeUInt16BE(e.charCodeAt(r),2*r);return this._createEncoderBuffer(i)}return"numstr"===t?this._isNumstr(e)?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: numstr supports only digits and space"):"printstr"===t?this._isPrintstr(e)?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(t)||"objDesc"===t?this._createEncoderBuffer(e):this.reporter.error("Encoding of string type: "+t+" unsupported")},c.prototype._encodeObjid=function(e,t,i){if("string"==typeof e){if(!t)return this.reporter.error("string objid given, but no values map found");if(!t.hasOwnProperty(e))return this.reporter.error("objid not found in values map");e=t[e].split(/[\s\.]+/g);for(var r=0;r<e.length;r++)e[r]|=0}else if(Array.isArray(e))for(e=e.slice(),r=0;r<e.length;r++)e[r]|=0;if(!Array.isArray(e))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(e));if(!i){if(e[1]>=40)return this.reporter.error("Second objid identifier OOB");e.splice(0,2,40*e[0]+e[1])}var s=0;for(r=0;r<e.length;r++){var o=e[r];for(s++;o>=128;o>>=7)s++}var a=new n(s),l=a.length-1;for(r=e.length-1;r>=0;r--)for(o=e[r],a[l--]=127&o;(o>>=7)>0;)a[l--]=128|127&o;return this._createEncoderBuffer(a)},c.prototype._encodeTime=function(e,t){var i,r=new Date(e);return"gentime"===t?i=[u(r.getFullYear()),u(r.getUTCMonth()+1),u(r.getUTCDate()),u(r.getUTCHours()),u(r.getUTCMinutes()),u(r.getUTCSeconds()),"Z"].join(""):"utctime"===t?i=[u(r.getFullYear()%100),u(r.getUTCMonth()+1),u(r.getUTCDate()),u(r.getUTCHours()),u(r.getUTCMinutes()),u(r.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+t+" time is not supported yet"),this._encodeStr(i,"octstr")},c.prototype._encodeNull=function(){return this._createEncoderBuffer("")},c.prototype._encodeInt=function(e,t){if("string"==typeof e){if(!t)return this.reporter.error("String int or enum given, but no values map");if(!t.hasOwnProperty(e))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(e));e=t[e]}if("number"!=typeof e&&!n.isBuffer(e)){var i=e.toArray();!e.sign&&128&i[0]&&i.unshift(0),e=new n(i)}if(n.isBuffer(e)){var r=e.length;0===e.length&&r++;var s=new n(r);return e.copy(s),0===e.length&&(s[0]=0),this._createEncoderBuffer(s)}if(e<128)return this._createEncoderBuffer(e);if(e<256)return this._createEncoderBuffer([0,e]);r=1;for(var o=e;o>=256;o>>=8)r++;for(o=(s=new Array(r)).length-1;o>=0;o--)s[o]=255&e,e>>=8;return 128&s[0]&&s.unshift(0),this._createEncoderBuffer(new n(s))},c.prototype._encodeBool=function(e){return this._createEncoderBuffer(e?255:0)},c.prototype._use=function(e,t){return"function"==typeof e&&(e=e(t)),e._getEncoder("der").tree},c.prototype._skipDefault=function(e,t,i){var r,n=this._baseState;if(null===n.default)return!1;var s=e.join();if(void 0===n.defaultBuffer&&(n.defaultBuffer=this._encodeValue(n.default,t,i).join()),s.length!==n.defaultBuffer.length)return!1;for(r=0;r<s.length;r++)if(s[r]!==n.defaultBuffer[r])return!1;return!0}},36028(e,t,i){var r=t;r.der=i(99291),r.pem=i(59678)},59678(e,t,i){var r=i(91193),n=i(99291);function s(e){n.call(this,e),this.enc="pem"}r(s,n),e.exports=s,s.prototype.encode=function(e,t){for(var i=n.prototype.encode.call(this,e).toString("base64"),r=["-----BEGIN "+t.label+"-----"],s=0;s<i.length;s+=64)r.push(i.slice(s,s+64));return r.push("-----END "+t.label+"-----"),r.join("\n")}},28213(e,t){"use strict";t.A=function(e,t){if(e&&t){var i=Array.isArray(t)?t:t.split(",");if(0===i.length)return!0;var r=e.name||"",n=(e.type||"").toLowerCase(),s=n.replace(/\/.*$/,"");return i.some(function(e){var t=e.trim().toLowerCase();return"."===t.charAt(0)?r.toLowerCase().endsWith(t):t.endsWith("/*")?s===t.replace(/\/.*$/,""):n===t})}return!0}},6184(e,t){"use strict";function i(e){var t=void 0;return"undefined"!=typeof Reflect&&"function"==typeof Reflect.ownKeys?t=Reflect.ownKeys(e.prototype):(t=Object.getOwnPropertyNames(e.prototype),"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(e.prototype)))),t.forEach(function(t){if("constructor"!==t){var i=Object.getOwnPropertyDescriptor(e.prototype,t);"function"==typeof i.value&&Object.defineProperty(e.prototype,t,r(e,t,i))}}),e}function r(e,t,i){var r=i.value;if("function"!=typeof r)throw new Error("@autobind decorator can only be applied to methods not: "+typeof r);var n=!1;return{configurable:!0,get:function(){if(n||this===e.prototype||this.hasOwnProperty(t))return r;var i=r.bind(this);return n=!0,Object.defineProperty(this,t,{value:i,configurable:!0,writable:!0}),n=!1,i}}}Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return 1===t.length?i.apply(void 0,t):r.apply(void 0,t)},e.exports=t.default},47187(e,t,i){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),s=this&&this.__assign||function(){return s=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},s.apply(this,arguments)},o=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},a=this&&this.__generator||function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}};Object.defineProperty(t,"__esModule",{value:!0});var l,c=i(16266),u=i(91911),h=i(57845),d=i(71481),p=i(21511),g=i(40501);t.USER_AGENT_HEADER="x-amz-user-agent",t.USER_AGENT="aws-amplify/"+g.version+(p.userAgent&&" ")+p.userAgent,function(e){e.NONE="NONE",e.API_KEY="API_KEY",e.AWS_IAM="AWS_IAM",e.AMAZON_COGNITO_USER_POOLS="AMAZON_COGNITO_USER_POOLS",e.OPENID_CONNECT="OPENID_CONNECT",e.AWS_LAMBDA="AWS_LAMBDA"}(l=t.AUTH_TYPE||(t.AUTH_TYPE={}));var f=function(e){function i(i){var r=e.call(this)||this;return r.link=t.authLink(i),r}return n(i,e),i.prototype.request=function(e,t){return this.link.request(e,t)},i}(c.ApolloLink);t.AuthLink=f;var m=function(e,i,r){var n=void 0===e?{header:"",value:""}:e,l=n.header,c=n.value;return o(void 0,void 0,void 0,function(){var e,n,o,u,h;return a(this,function(a){switch(a.label){case 0:return e=i.getContext(),n=s(s({},e.headers),((u={})[t.USER_AGENT_HEADER]=t.USER_AGENT,u)),l&&c?"function"!=typeof c?[3,2]:[4,c.call(void 0)]:[3,5];case 1:return o=a.sent(),[3,4];case 2:return[4,c];case 3:o=a.sent(),a.label=4;case 4:n=s(((h={})[l]=o,h),n),a.label=5;case 5:return i.setContext(s(s({},e),{headers:n})),[2,r(i)]}})})};t.authLink=function(e){var i=e.url,r=e.region,n=e.auth,u=(void 0===n?{}:n).type,p=e.auth;return new c.ApolloLink(function(e,n){return new c.Observable(function(c){var g,f;switch(u){case l.NONE:f=m(void 0,e,n);break;case l.AWS_IAM:var C=p.credentials;f=function(e,i,r){var n=e.credentials,l=e.region,c=e.url;return o(void 0,void 0,void 0,function(){var e,o,u,p,g,f,m,C,y,w,S,b,E;return a(this,function(a){switch(a.label){case 0:return e="appsync",o=i.getContext(),(u="function"==typeof n?n.call():n||{})&&"function"==typeof u.getPromise?[4,u.getPromise()]:[3,2];case 1:a.sent(),a.label=2;case 2:return[4,u];case 3:return p=a.sent(),g=p.accessKeyId,f=p.secretAccessKey,m=p.sessionToken,C=d.parse(c),y=C.host,w=C.path,S=s(s({},v(i,{})),{service:e,region:l,url:c,host:y,path:w}),b=h.Signer.sign(S,{access_key:g,secret_key:f,session_token:m}).headers,i.setContext(s(s({},o),{headers:s(s(s({},o.headers),b),(E={},E[t.USER_AGENT_HEADER]=t.USER_AGENT,E))})),[2,r(i)]}})})}({credentials:void 0===C?{}:C,region:r,url:i},e,n);break;case l.API_KEY:var y=p.apiKey;f=m({header:"X-Api-Key",value:void 0===y?"":y},e,n);break;case l.AMAZON_COGNITO_USER_POOLS:case l.OPENID_CONNECT:var w=p.jwtToken;f=m({header:"Authorization",value:void 0===w?"":w},e,n);break;case l.AWS_LAMBDA:var S=p.token;f=m({header:"Authorization",value:void 0===S?"":S},e,n);break;default:throw new Error("Invalid AUTH_TYPE: "+p.type)}return f.then(function(e){g=e.subscribe({next:c.next.bind(c),error:c.error.bind(c),complete:c.complete.bind(c)})}),function(){g&&g.unsubscribe()}})})};var v=function(e,t){var i=e.operationName,r=e.variables,n=e.query,o={operationName:i,variables:C(r),query:u.print(n)};return s(s({body:JSON.stringify(o),method:"POST"},t),{headers:s({accept:"*/*","content-type":"application/json; charset=UTF-8"},t.headers)})},C=function(e){return Object.keys(e).filter(function(e){return!e.startsWith("@@")}).reduce(function(t,i){return t[i]=e[i],t},{})}},2662(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(47187);t.AuthLink=r.AuthLink,t.AUTH_TYPE=r.AUTH_TYPE,t.USER_AGENT_HEADER=r.USER_AGENT_HEADER,t.USER_AGENT=r.USER_AGENT,t.createAuthLink=function(e){var t=e.url,i=e.region,n=e.auth;return new r.AuthLink({url:t,region:i,auth:n})};var n=i(57845);t.Signer=n.Signer},21511(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.userAgent=""},57845(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e){for(var i in e)t.hasOwnProperty(i)||(t[i]=e[i])}(i(24799))},24799(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),globalThis.Buffer=globalThis.Buffer||i(77511).Buffer;var r=i(71481),n=i(18558).Sha256,s=i(93065).n,o=function(e,t,i){void 0===i&&(i="");var r=new n(e);r.update(t);var o=r.digestSync();return"hex"===i?s(o):o},a=function(e){var t=e||"",i=new n;return i.update(t),s(i.digestSync())},l=function(e){return Object.keys(e).map(function(e){return e.toLowerCase()}).sort().join(";")},c=function(e,t,i){void 0===i&&(i=null),e.headers=e.headers||{};var n=(new Date).toISOString().replace(/[:-]|\.\d{3}/g,""),s=n.substr(0,8),c="AWS4-HMAC-SHA256",u=r.parse(e.url);e.headers.host=u.host,e.headers["x-amz-date"]=n,t.session_token&&(e.headers["X-Amz-Security-Token"]=t.session_token);var h=function(e){var t,i=r.parse(e.url);return[e.method||"/",i.path,i.query,(t=e.headers,t&&0!==Object.keys(t).length?Object.keys(t).map(function(e){return{key:e.toLowerCase(),value:t[e]?t[e].trim().replace(/\s+/g," "):""}}).sort(function(e,t){return e.key<t.key?-1:1}).map(function(e){return e.key+":"+e.value}).join("\n")+"\n":""),l(e.headers),a(e.body)].join("\n")}(e);i=i||function(e){var t=(r.parse(e.url).host.match(/([^.]+)\.(?:([^.]*)\.)?amazonaws\.com$/)||[]).slice(1,3);return"es"===t[1]&&(t=t.reverse()),{service:e.service||t[0],region:e.region||t[1]}}(e);var d=function(e,t,i){return[e,t,i,"aws4_request"].join("/")}(s,i.region,i.service),p=function(e,t,i,r){return[e,i,r,a(t)].join("\n")}(c,h,n,d),g=function(e,t,i){void 0===e&&(e="");var r=o("AWS4"+e,t),n=o(r,i.region),s=o(n,i.service);return o(s,"aws4_request")}(t.secret_key,s,i),f=function(e,t){return o(e,t,"hex")}(g,p),m=function(e,t,i,r,n){return void 0===t&&(t=""),[e+" Credential="+t+"/"+i,"SignedHeaders="+r,"Signature="+n].join(", ")}(c,t.access_key,d,l(e.headers),f);return e.headers.Authorization=m,e},u=function(){function e(){}return e.sign=c,e}();t.Signer=u,t.default=u},77583(e,t,i){"use strict";var r=this&&this.__rest||function(e,t){var i={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(e);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(e,r[n])&&(i[r[n]]=e[r[n]])}return i};Object.defineProperty(t,"__esModule",{value:!0});var n=i(16491);t.CONTROL_EVENTS_KEY=n.CONTROL_EVENTS_KEY;var s=i(16266),o=i(42007),a=i(89444),l=i(62178),c=i(44635);t.createSubscriptionHandshakeLink=function(e,t){var i,u;if("string"==typeof e)i=t||o.createHttpLink({uri:e}),u=s.ApolloLink.from([new l.NonTerminatingLink("controlMessages",{link:new s.ApolloLink(function(e,t){return new s.Observable(function(t){var i,s=e.variables,o=n.CONTROL_EVENTS_KEY,a=s[o],l=r(s,["symbol"==typeof o?o:o+""]);return void 0!==a&&(e.variables=l),t.next(((i={})[n.CONTROL_EVENTS_KEY]=a,i)),function(){}})})}),new l.NonTerminatingLink("subsInfo",{link:i}),new n.SubscriptionHandshakeLink("subsInfo")]);else{var h=e.url;i=t||o.createHttpLink({uri:h}),u=new c.AppSyncRealTimeSubscriptionHandshakeLink(e)}return s.ApolloLink.split(function(e){var t=e.query,i=a.getMainDefinition(t),r=i.kind,n=i.operation;return"OperationDefinition"===r&&"subscription"===n},u,i)}},62178(e,t,i){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),s=this&&this.__assign||function(){return s=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},s.apply(this,arguments)},o=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},a=this&&this.__generator||function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}};Object.defineProperty(t,"__esModule",{value:!0});var l=i(16266),c=i(36712),u=function(e){function t(t,i){var r=i.link,n=e.call(this)||this;return n.contextKey=t,n.link=r,n}return n(t,e),t.prototype.request=function(e,t){var i=this;return c.setContext(function(t,r){return o(i,void 0,void 0,function(){var t,i,n=this;return a(this,function(o){switch(o.label){case 0:return[4,new Promise(function(t,i){n.link.request(e).subscribe({next:t,error:i})})];case 1:return t=o.sent(),[2,s(s({},r),(i={},i[this.contextKey]=t,i))]}})})}).request(e,t)},t}(l.ApolloLink);t.NonTerminatingLink=u},44635(e,t,i){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),s=this&&this.__assign||function(){return s=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},s.apply(this,arguments)},o=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},a=this&&this.__generator||function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}};Object.defineProperty(t,"__esModule",{value:!0});var l=i(16266),c=i(35497),u=i(2662),h=i(89347),d=i(71481),p=i(32486),g=i(74037),f=i(18639),m=c.rootLogger.extend("subscriptions");t.CONTROL_EVENTS_KEY="@@controlEvents";var v=[400,401,403],C={accept:"application/json, text/javascript","content-encoding":"amz-1.0","content-type":"application/json; charset=UTF-8"},y=/^https:\/\/\w{26}\.appsync\-api\.\w{2}(?:(?:\-\w{2,})+)\-\d\.amazonaws.com\/graphql$/i,w=function(e){function i(t){var i=t.url,r=t.region,n=t.auth,s=t.keepAliveTimeoutMs,o=e.call(this)||this;if(o.socketStatus=g.SOCKET_STATUS.CLOSED,o.keepAliveTimeout=void 0,o.subscriptionObserverMap=new Map,o.promiseArray=[],o.url=i,o.region=r,o.auth=n,o.keepAliveTimeout=s,o.keepAliveTimeout<6e4)throw new Error("keepAliveTimeoutMs must be greater than or equal to 60000 ("+o.keepAliveTimeout+" used).");return o}return n(i,e),i.prototype.isCustomDomain=function(e){return null===e.match(y)},i.prototype.request=function(e){var i,r=this,n=e.query,c=e.variables,d=e.getContext(),f=d.controlMessages,m=t.CONTROL_EVENTS_KEY,v=(void 0===f?(i={},i[t.CONTROL_EVENTS_KEY]=void 0,i):f)[m],C=d.headers;return new l.Observable(function(e){if(r.url){var t=p.v4(),i=r.auth.type===u.AUTH_TYPE.AMAZON_COGNITO_USER_POOLS||r.auth.type===u.AUTH_TYPE.OPENID_CONNECT?r.auth.jwtToken:null;i=r.auth.type===u.AUTH_TYPE.AWS_LAMBDA?r.auth.token:i;var l={appSyncGraphqlEndpoint:r.url,authenticationType:r.auth.type,query:h.print(n),region:r.region,graphql_headers:function(){return C},variables:c,apiKey:r.auth.type===u.AUTH_TYPE.API_KEY?r.auth.apiKey:"",credentials:r.auth.type===u.AUTH_TYPE.AWS_IAM?r.auth.credentials:null,token:i};return r._startSubscriptionWithAWSAppSyncRealTime({options:l,observer:e,subscriptionId:t}),function(){return o(r,void 0,void 0,function(){return a(this,function(e){try{if(this._verifySubscriptionAlreadyStarted(t),this.subscriptionObserverMap.get(t).subscriptionState!==g.SUBSCRIPTION_STATUS.CONNECTED)throw new Error("Subscription has failed, starting to remove subscription.");this._sendUnsubscriptionMessage(t)}catch(e){return this._removeSubscriptionObserver(t),[2]}return[2]})})}}e.error({errors:[s({},new h.GraphQLError("Subscribe only available for AWS AppSync endpoint"))]}),e.complete()}).filter(function(e){var t=e.extensions,i=(void 0===t?{}:t).controlMsgType;return!0===v||!(void 0!==(void 0===i?void 0:i))})},i.prototype._verifySubscriptionAlreadyStarted=function(e){return o(this,void 0,void 0,function(){var t=this;return a(this,function(i){return this.subscriptionObserverMap.get(e).subscriptionState===g.SUBSCRIPTION_STATUS.PENDING?[2,new Promise(function(i,r){var n=t.subscriptionObserverMap.get(e),s=n.observer,o=n.subscriptionState,a=n.variables,l=n.query;t.subscriptionObserverMap.set(e,{observer:s,subscriptionState:o,variables:a,query:l,subscriptionReadyCallback:i,subscriptionFailedCallback:r})})]:[2]})})},i.prototype._sendUnsubscriptionMessage=function(e){try{if(this.awsRealTimeSocket&&this.awsRealTimeSocket.readyState===WebSocket.OPEN&&this.socketStatus===g.SOCKET_STATUS.READY){var t={id:e,type:g.MESSAGE_TYPES.GQL_STOP},i=JSON.stringify(t);this.awsRealTimeSocket.send(i),this._removeSubscriptionObserver(e)}}catch(e){m({err:e})}},i.prototype._removeSubscriptionObserver=function(e){this.subscriptionObserverMap.delete(e),setTimeout(this._closeSocketIfRequired.bind(this),1e3)},i.prototype._closeSocketIfRequired=function(){this.subscriptionObserverMap.size>0||(this.awsRealTimeSocket?this.awsRealTimeSocket.bufferedAmount>0?setTimeout(this._closeSocketIfRequired.bind(this),1e3):(m("closing WebSocket..."),clearTimeout(this.keepAliveTimeoutId),this.awsRealTimeSocket.close(1e3),this.awsRealTimeSocket=null,this.socketStatus=g.SOCKET_STATUS.CLOSED):this.socketStatus=g.SOCKET_STATUS.CLOSED)},i.prototype._startSubscriptionWithAWSAppSyncRealTime=function(e){var t=e.options,i=e.observer,r=e.subscriptionId;return o(this,void 0,void 0,function(){var e,n,o,l,c,d,p,f,m,v,C,y,w,S,b,E,A,T,M,R,_,P,x,D,I,L=this;return a(this,function(a){switch(a.label){case 0:return e=t.appSyncGraphqlEndpoint,n=t.authenticationType,o=t.query,l=t.variables,c=t.apiKey,d=t.region,p=t.graphql_headers,f=void 0===p?function(){return{}}:p,m=t.credentials,v=t.token,C=g.SUBSCRIPTION_STATUS.PENDING,y={query:o,variables:l},this.subscriptionObserverMap.set(r,{observer:i,query:o,variables:l,subscriptionState:C,startAckTimeoutId:null}),w=JSON.stringify(y),b=[{}],[4,this._awsRealTimeHeaderBasedAuth({apiKey:c,appSyncGraphqlEndpoint:e,authenticationType:n,payload:w,canonicalUri:"",region:d,credentials:m,token:v,graphql_headers:f})];case 1:S=s.apply(void 0,[s.apply(void 0,b.concat([a.sent()])),(I={},I[u.USER_AGENT_HEADER]=u.USER_AGENT,I)]),E={id:r,payload:{data:w,extensions:{authorization:s({},S)}},type:g.MESSAGE_TYPES.GQL_START},A=JSON.stringify(E),a.label=2;case 2:return a.trys.push([2,4,,5]),[4,this._initializeWebSocketConnection({apiKey:c,appSyncGraphqlEndpoint:e,authenticationType:n,region:d,credentials:m,token:v})];case 3:return a.sent(),[3,5];case 4:return T=a.sent(),M=T.message,R=void 0===M?"":M,i.error({errors:[s({},new h.GraphQLError("Connection failed: "+R))]}),i.complete(),"function"==typeof(_=(this.subscriptionObserverMap.get(r)||{}).subscriptionFailedCallback)&&_(),[2];case 5:return P=this.subscriptionObserverMap.get(r)||{},x=P.subscriptionFailedCallback,D=P.subscriptionReadyCallback,this.subscriptionObserverMap.set(r,{observer:i,subscriptionState:C,variables:l,query:o,subscriptionReadyCallback:D,subscriptionFailedCallback:x,startAckTimeoutId:setTimeout(function(){L._timeoutStartSubscriptionAck.call(L,r)},15e3)}),this.awsRealTimeSocket&&this.awsRealTimeSocket.send(A),[2]}})})},i.prototype._initializeWebSocketConnection=function(e){var t=this,i=e.appSyncGraphqlEndpoint,r=e.authenticationType,n=e.apiKey,s=e.region,l=e.credentials,c=e.token;if(this.socketStatus!==g.SOCKET_STATUS.READY)return new Promise(function(e,u){return o(t,void 0,void 0,function(){var t,o,h,d,p,f,v,C,y;return a(this,function(a){switch(a.label){case 0:if(this.promiseArray.push({res:e,rej:u}),this.socketStatus!==g.SOCKET_STATUS.CLOSED)return[3,5];a.label=1;case 1:return a.trys.push([1,4,,5]),this.socketStatus=g.SOCKET_STATUS.CONNECTING,t="{}",d=(h=JSON).stringify,[4,this._awsRealTimeHeaderBasedAuth({authenticationType:r,payload:t,canonicalUri:"/connect",apiKey:n,appSyncGraphqlEndpoint:i,region:s,credentials:l,token:c,graphql_headers:function(){}})];case 2:return o=d.apply(h,[a.sent()]),p=Buffer.from(o).toString("base64"),f=Buffer.from(t).toString("base64"),v=i,v=(v=this.isCustomDomain(v)?v.concat("/realtime"):v.replace("appsync-api","appsync-realtime-api").replace("gogi-beta","grt-beta")).replace("https://","wss://").replace("http://","ws://"),C=v+"?header="+p+"&payload="+f,[4,this._initializeRetryableHandshake({awsRealTimeUrl:C})];case 3:return a.sent(),this.promiseArray.forEach(function(e){var t=e.res;m("Notifying connection successful"),t()}),this.socketStatus=g.SOCKET_STATUS.READY,this.promiseArray=[],[3,5];case 4:return y=a.sent(),this.promiseArray.forEach(function(e){return(0,e.rej)(y)}),this.promiseArray=[],this.awsRealTimeSocket&&this.awsRealTimeSocket.readyState===WebSocket.OPEN&&this.awsRealTimeSocket.close(3001),this.awsRealTimeSocket=null,this.socketStatus=g.SOCKET_STATUS.CLOSED,[3,5];case 5:return[2]}})})})},i.prototype._awsRealTimeHeaderBasedAuth=function(e){var t=e.authenticationType,i=e.payload,r=e.canonicalUri,n=e.appSyncGraphqlEndpoint,s=e.apiKey,l=e.region,c=e.credentials,u=e.token,h=e.graphql_headers;return o(this,void 0,void 0,function(){var e,o,p;return a(this,function(a){switch(a.label){case 0:return e={API_KEY:this._awsRealTimeApiKeyHeader.bind(this),AWS_IAM:this._awsRealTimeIAMHeader.bind(this),OPENID_CONNECT:this._awsRealTimeAuthorizationHeader.bind(this),AMAZON_COGNITO_USER_POOLS:this._awsRealTimeAuthorizationHeader.bind(this),AWS_LAMBDA:this._awsRealTimeAuthorizationHeader.bind(this)},"function"!=typeof(o=e[t])?(m("Authentication type "+t+" not supported"),[2,{}]):(p=d.parse(n).host,[4,o({payload:i,canonicalUri:r,appSyncGraphqlEndpoint:n,apiKey:s,region:l,host:p,credentials:c,token:u,graphql_headers:h})]);case 1:return[2,a.sent()]}})})},i.prototype._awsRealTimeAuthorizationHeader=function(e){var t=e.host,i=e.token,r=e.graphql_headers;return o(this,void 0,void 0,function(){var e,n,o;return a(this,function(a){switch(a.label){case 0:return e={},"function"!=typeof i?[3,2]:[4,i.call(void 0)];case 1:return n=a.sent(),[3,4];case 2:return[4,i];case 3:n=a.sent(),a.label=4;case 4:return o=[(e.Authorization=n,e.host=t,e)],[4,r()];case 5:return[2,s.apply(void 0,o.concat([a.sent()]))]}})})},i.prototype._awsRealTimeApiKeyHeader=function(e){var t=e.apiKey,i=e.host,r=e.graphql_headers;return o(this,void 0,void 0,function(){var e,n,o;return a(this,function(a){switch(a.label){case 0:return e=new Date,n=e.toISOString().replace(/[:\-]|\.\d{3}/g,""),o=[{host:i,"x-amz-date":n,"x-api-key":t}],[4,r()];case 1:return[2,s.apply(void 0,o.concat([a.sent()]))]}})})},i.prototype._awsRealTimeIAMHeader=function(e){var t=e.payload,i=e.canonicalUri,r=e.appSyncGraphqlEndpoint,n=e.region,l=e.credentials;return o(this,void 0,void 0,function(){var e,o,c,h,d,p,g,f;return a(this,function(a){switch(a.label){case 0:return e={region:n,service:"appsync"},(o="function"==typeof l?l.call():l||{})&&"function"==typeof o.getPromise?[4,o.getPromise()]:[3,2];case 1:a.sent(),a.label=2;case 2:if(!o)throw new Error("No credentials");return[4,o];case 3:return c=a.sent(),h=c.accessKeyId,d=c.secretAccessKey,p=c.sessionToken,g={access_key:h,secret_key:d,session_token:p},f={url:""+r+i,body:t,method:"POST",headers:s({},C)},[2,u.Signer.sign(f,g,e).headers]}})})},i.prototype._initializeRetryableHandshake=function(e){var t=e.awsRealTimeUrl;return o(this,void 0,void 0,function(){return a(this,function(e){switch(e.label){case 0:return m("Initializaling retryable Handshake"),[4,f.jitteredExponentialRetry(this._initializeHandshake.bind(this),[{awsRealTimeUrl:t}])];case 1:return e.sent(),[2]}})})},i.prototype._initializeHandshake=function(e){var t=e.awsRealTimeUrl;return o(this,void 0,void 0,function(){var e,r,n,s=this;return a(this,function(o){switch(o.label){case 0:m("Initializing handshake "+t),o.label=1;case 1:return o.trys.push([1,4,,5]),[4,new Promise(function(e,r){var n=i.createWebSocket(t,"graphql-ws");n.onerror=function(){m("WebSocket connection error")},n.onclose=function(){r(new Error("Connection handshake error"))},n.onopen=function(){return s.awsRealTimeSocket=n,e()}})];case 2:return o.sent(),[4,new Promise(function(e,t){var i=!1;s.awsRealTimeSocket.onerror=function(e){m("WebSocket closed "+JSON.stringify(e))},s.awsRealTimeSocket.onclose=function(e){m("WebSocket closed "+e.reason),t(new Error(JSON.stringify(e)))},s.awsRealTimeSocket.onmessage=function(r){var n;m("subscription message from AWS AppSyncRealTime: "+r.data+" ");var o=JSON.parse(r.data),a=o.type,l=o.payload,c=(void 0===l?{}:l).connectionTimeoutMs,u=void 0===c?3e5:c;if(a===g.MESSAGE_TYPES.GQL_CONNECTION_ACK)return i=!0,s.keepAliveTimeout=null!==(n=s.keepAliveTimeout)&&void 0!==n?n:u,s.awsRealTimeSocket.onmessage=s._handleIncomingSubscriptionMessage.bind(s),s.awsRealTimeSocket.onerror=function(e){m(e),s._errorDisconnect(g.CONTROL_MSG.CONNECTION_CLOSED)},s.awsRealTimeSocket.onclose=function(e){m("WebSocket closed "+e.reason),s._errorDisconnect(g.CONTROL_MSG.CONNECTION_CLOSED)},void e("Cool, connected to AWS AppSyncRealTime");if(a===g.MESSAGE_TYPES.GQL_CONNECTION_ERROR){var h=o.payload,d=(void 0===h?{}:h).errors,p=(void 0===d?[]:d)[0],f=void 0===p?{}:p,v=f.errorType,C=void 0===v?"":v,y=f.errorCode;t({errorType:C,errorCode:void 0===y?0:y})}};var r={type:g.MESSAGE_TYPES.GQL_CONNECTION_INIT};s.awsRealTimeSocket.send(JSON.stringify(r)),setTimeout(function(){i||t(new Error("Connection timeout: ack from AWSRealTime was not received on 15000 ms"))}.bind(s),15e3)})];case 3:return o.sent(),[3,5];case 4:throw e=o.sent(),r=e.errorType,n=e.errorCode,v.indexOf(n)>=0?new f.NonRetryableError(r):r?new Error(r):e;case 5:return[2]}})})},i.prototype._handleIncomingSubscriptionMessage=function(e){m("subscription message from AWS AppSync RealTime: "+e.data);var t=JSON.parse(e.data),i=t.id,r=void 0===i?"":i,n=t.payload,o=t.type,a=this.subscriptionObserverMap.get(r)||{},l=a.observer,c=void 0===l?null:l,u=a.query,d=void 0===u?"":u,p=a.variables,f=void 0===p?{}:p,v=a.startAckTimeoutId,C=void 0===v?0:v,y=a.subscriptionReadyCallback,w=void 0===y?null:y,S=a.subscriptionFailedCallback,b=void 0===S?null:S;if(m({id:r,observer:c,query:d,variables:f}),o===g.MESSAGE_TYPES.GQL_DATA&&n&&n.data)c?c.next(n):m("observer not found for id: "+r);else if(o!==g.MESSAGE_TYPES.GQL_START_ACK){if(o===g.MESSAGE_TYPES.GQL_CONNECTION_KEEP_ALIVE)return clearTimeout(this.keepAliveTimeoutId),void(this.keepAliveTimeoutId=setTimeout(this._errorDisconnect.bind(this,g.CONTROL_MSG.TIMEOUT_DISCONNECT),this.keepAliveTimeout));o===g.MESSAGE_TYPES.GQL_ERROR&&(E=g.SUBSCRIPTION_STATUS.FAILED,this.subscriptionObserverMap.set(r,{observer:c,query:d,variables:f,startAckTimeoutId:C,subscriptionReadyCallback:w,subscriptionFailedCallback:b,subscriptionState:E}),clearTimeout(C),c?(c.error({errors:[s({},new h.GraphQLError("Connection failed: "+JSON.stringify(n)))]}),c.complete()):m("observer not found for id: "+r),"function"==typeof b&&b())}else{m("subscription ready for "+JSON.stringify({query:d,variables:f})),"function"==typeof w&&w(),clearTimeout(C),c?c.next({data:n,extensions:{controlMsgType:"CONNECTED"}}):m("observer not found for id: "+r);var E=g.SUBSCRIPTION_STATUS.CONNECTED;this.subscriptionObserverMap.set(r,{observer:c,query:d,variables:f,startAckTimeoutId:null,subscriptionState:E,subscriptionReadyCallback:w,subscriptionFailedCallback:b})}},i.prototype._errorDisconnect=function(e){m("Disconnect error: "+e),this.subscriptionObserverMap.forEach(function(t){var i=t.observer;i&&!i.closed&&i.error({errors:[s({},new h.GraphQLError(e))]})}),this.subscriptionObserverMap.clear(),this.awsRealTimeSocket&&this.awsRealTimeSocket.close(),this.socketStatus=g.SOCKET_STATUS.CLOSED},i.prototype._timeoutStartSubscriptionAck=function(e){var t=this.subscriptionObserverMap.get(e)||{},i=t.observer,r=t.query,n=t.variables;i&&(this.subscriptionObserverMap.set(e,{observer:i,query:r,variables:n,subscriptionState:g.SUBSCRIPTION_STATUS.FAILED}),i&&!i.closed&&(i.error({errors:[s({},new h.GraphQLError("Subscription timeout "+JSON.stringify({query:r,variables:n})))]}),i.complete()),m("timeoutStartSubscription",JSON.stringify({query:r,variables:n})))},i.createWebSocket=function(e,t){return new WebSocket(e,t)},i}(l.ApolloLink);t.AppSyncRealTimeSubscriptionHandshakeLink=w},16491(e,t,i){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),s=this&&this.__assign||function(){return s=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},s.apply(this,arguments)},o=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},a=this&&this.__generator||function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}},l=this&&this.__rest||function(e,t){var i={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(r=Object.getOwnPropertySymbols(e);n<r.length;n++)t.indexOf(r[n])<0&&Object.prototype.propertyIsEnumerable.call(e,r[n])&&(i[r[n]]=e[r[n]])}return i};Object.defineProperty(t,"__esModule",{value:!0});var c=i(16266),u=i(35497),h=i(35529),d=i(89444),p=u.rootLogger.extend("subscriptions"),g=p.extend("mqtt");t.CONTROL_EVENTS_KEY="@@controlEvents";var f=function(e){function i(t){var i=e.call(this)||this;return i.topicObservers=new Map,i.clientObservers=new Map,i.onMessage=function(e,t,r){var n=JSON.parse(t),o=i.topicObservers.get(e),a=r.reduce(function(e,t){return e[t]=e[t]||null,e},n.data||{});p("Message received",{data:a,topic:e,observers:o}),o.forEach(function(e){try{e.next(s(s({},n),{data:a}))}catch(e){p(e)}})},i.subsInfoContextKey=t,i}return n(i,e),i.prototype.request=function(e){var i,r=this,n=e.getContext(),o=n[this.subsInfoContextKey],a=n.controlMessages,u=t.CONTROL_EVENTS_KEY,h=(void 0===a?(i={},i[t.CONTROL_EVENTS_KEY]=void 0,i):a)[u],d=o.extensions,p=(void 0===d?{subscription:{newSubscriptions:{},mqttConnections:[]}}:d).subscription,g=p.newSubscriptions,f=p.mqttConnections,m=o.errors,v=void 0===m?[]:m;if(v&&v.length)return new c.Observable(function(e){return e.error(new c.ApolloError({errorMessage:"Error during subscription handshake",extraInfo:{errors:v},graphQLErrors:v})),function(){}});var C=Object.keys(g).map(function(e){return g[e].topic}),y=new Set(C.filter(function(e){return r.topicObservers.has(e)})),w=new Set(C.filter(function(e){return!y.has(e)}));return new c.Observable(function(t){y.forEach(function(e){r.topicObservers.get(e).add(t);var i=Array.from(r.topicObservers.get(e)).find(function(){return!0}),n=Array.from(r.clientObservers).find(function(e){return e[1].observers.has(i)})[0];r.clientObservers.get(n).observers.add(t)});var i=f.filter(function(e){return e.topics.some(function(e){return w.has(e)})}).map(function(e){var t=e.topics,i=l(e,["topics"]);return s(s({},i),{topics:t.filter(function(e){return w.has(e)})})});return r.connectNewClients(i,t,e),function(){var e=Array.from(r.clientObservers).filter(function(e){return e[1].observers.has(t)});e.forEach(function(e){var i=e[0];return r.clientObservers.get(i).observers.delete(t)}),r.clientObservers.forEach(function(e){var t=e.observers,i=e.client;0===t.size&&(i.isConnected()&&i.disconnect(),r.clientObservers.delete(i.clientId))}),r.clientObservers=new Map(Array.from(r.clientObservers).filter(function(e){return e[1].observers.size>0})),r.topicObservers.forEach(function(e){return e.delete(t)}),r.topicObservers=new Map(Array.from(r.topicObservers).filter(function(e){return e[1].size>0}))}}).filter(function(e){var t=e.extensions,i=(void 0===t?{}:t).controlMsgType;return!0===h||!(void 0!==(void 0===i?void 0:i))})},i.prototype.connectNewClients=function(e,t,i){return o(this,void 0,void 0,function(){var r,n,s,o,l=this;return a(this,function(a){return r=i.query,n=d.getMainDefinition(r).selectionSet.selections.map(function(e){return e.name.value}),s=Promise.all(e.map(function(e){return l.connectNewClient(e,t,n)})),o=n.reduce(function(e,t){return e[t]=e[t]||null,e},{}),t.next({data:o,extensions:{controlMsgType:"CONNECTED",controlMsgInfo:{connectionInfo:e}}}),[2,s]})})},i.prototype.connectNewClient=function(e,t,i){return o(this,void 0,void 0,function(){var r,n,o,c,u=this;return a(this,function(a){switch(a.label){case 0:return r=e.client,n=e.url,o=e.topics,(c=new h.Client(n,r)).trace=g.bind(null,r),c.onConnectionLost=function(e){var t=e.errorCode,i=l(e,["errorCode"]);0!==t&&o.forEach(function(e){u.topicObservers.has(e)&&u.topicObservers.get(e).forEach(function(e){return e.error(s(s({},i),{permanent:!0}))})}),o.forEach(function(e){return u.topicObservers.delete(e)})},c.onMessageArrived=function(e){var t=e.destinationName,r=e.payloadString;return u.onMessage(t,r,i)},[4,new Promise(function(e,t){c.connect({useSSL:0===n.indexOf("wss://"),mqttVersion:3,onSuccess:function(){return e(c)},onFailure:t})})];case 1:return a.sent(),[4,this.subscribeToTopics(c,o,t)];case 2:return a.sent(),[2,c]}})})},i.prototype.subscribeToTopics=function(e,t,i){var r=this;return Promise.all(t.map(function(t){return r.subscribeToTopic(e,t,i)}))},i.prototype.subscribeToTopic=function(e,t,i){var r=this;return new Promise(function(n,s){e.subscribe(t,{onSuccess:function(){r.topicObservers.has(t)||r.topicObservers.set(t,new Set),r.clientObservers.has(e.clientId)||r.clientObservers.set(e.clientId,{client:e,observers:new Set}),r.topicObservers.get(t).add(i),r.clientObservers.get(e.clientId).observers.add(i),n(t)},onFailure:s})})},i}(c.ApolloLink);t.SubscriptionHandshakeLink=f},74037(e,t){"use strict";var i,r,n,s;Object.defineProperty(t,"__esModule",{value:!0}),(s=t.SUBSCRIPTION_STATUS||(t.SUBSCRIPTION_STATUS={}))[s.PENDING=0]="PENDING",s[s.CONNECTED=1]="CONNECTED",s[s.FAILED=2]="FAILED",(n=t.SOCKET_STATUS||(t.SOCKET_STATUS={}))[n.CLOSED=0]="CLOSED",n[n.READY=1]="READY",n[n.CONNECTING=2]="CONNECTING",(r=t.MESSAGE_TYPES||(t.MESSAGE_TYPES={})).GQL_CONNECTION_INIT="connection_init",r.GQL_CONNECTION_ERROR="connection_error",r.GQL_CONNECTION_ACK="connection_ack",r.GQL_START="start",r.GQL_START_ACK="start_ack",r.GQL_DATA="data",r.GQL_CONNECTION_KEEP_ALIVE="ka",r.GQL_STOP="stop",r.GQL_COMPLETE="complete",r.GQL_ERROR="error",(i=t.CONTROL_MSG||(t.CONTROL_MSG={})).CONNECTION_CLOSED="Connection closed",i.TIMEOUT_DISCONNECT="Timeout disconnect",i.SUBSCRIPTION_ACK="Subscription ack"},35497(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(77321);t.rootLogger=r.default},77321(e,t,i){"use strict";var r=this&&this.__spreadArrays||function(){for(var e=0,t=0,i=arguments.length;t<i;t++)e+=arguments[t].length;var r=Array(e),n=0;for(t=0;t<i;t++)for(var s=arguments[t],o=0,a=s.length;o<a;o++,n++)r[n]=s[o];return r};Object.defineProperty(t,"__esModule",{value:!0});var n=i(89028),s=n.default("aws-appsync"),o=function(e){void 0===e&&(e="");var t=e?r(this.namespace.split(":"),[e]).join(":"):this.namespace,i=n.default(t);return i.extend=o.bind(i),i};s.extend=o.bind(s),t.default=s},18639(e,t,i){"use strict";var r,n=this&&this.__extends||(r=function(e,t){return r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var i in t)t.hasOwnProperty(i)&&(e[i]=t[i])},r(e,t)},function(e,t){function i(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}),s=this&&this.__awaiter||function(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})},o=this&&this.__generator||function(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}};Object.defineProperty(t,"__esModule",{value:!0});var a=i(35497).rootLogger.extend("retry"),l=function(e){function t(t){var i=e.call(this,t)||this;return i.nonRetryable=!0,i}return n(t,e),t}(Error);function c(e,t,i,r){return void 0===r&&(r=1),s(this,void 0,void 0,function(){var n,s;return o(this,function(o){switch(o.label){case 0:a("Attempt #"+r+" for this vars: "+JSON.stringify(t)),o.label=1;case 1:return o.trys.push([1,3,,8]),[4,e.apply(void 0,t)];case 2:return o.sent(),[3,8];case 3:if(n=o.sent(),a("error "+n),(l=n)&&l.nonRetryable)throw a("non retryable error"),n;return s=i(r,t,n),a("retryIn ",s),!1===s?[3,6]:[4,new Promise(function(e){return setTimeout(e,s)})];case 4:return o.sent(),[4,c(e,t,i,r+1)];case 5:return[2,o.sent()];case 6:throw n;case 7:return[3,8];case 8:return[2]}var l})})}t.NonRetryableError=l,t.retry=c,t.jitteredExponentialRetry=function(e,t,i){return void 0===i&&(i=5e3),c(e,t,function(e){return function(t){var i=100*Math.pow(2,t)+100*Math.random();return!(i>e)&&i}}(i))}},35529(e){var t;t=function(){var e=function(t){var i,r=t.localStorage||(i={},{setItem:function(e,t){i[e]=t},getItem:function(e){return i[e]},removeItem:function(e){delete i[e]}}),n=function(e,t){for(var i in e)if(e.hasOwnProperty(i)){if(!t.hasOwnProperty(i)){var r="Unknown property, "+i+". Valid properties are:";for(var n in t)t.hasOwnProperty(n)&&(r=r+" "+n);throw new Error(r)}if(typeof e[i]!==t[i])throw new Error(l(o.INVALID_TYPE,[typeof e[i],i]))}},s=function(e,t){return function(){return e.apply(t,arguments)}},o={OK:{code:0,text:"AMQJSC0000I OK."},CONNECT_TIMEOUT:{code:1,text:"AMQJSC0001E Connect timed out."},SUBSCRIBE_TIMEOUT:{code:2,text:"AMQJS0002E Subscribe timed out."},UNSUBSCRIBE_TIMEOUT:{code:3,text:"AMQJS0003E Unsubscribe timed out."},PING_TIMEOUT:{code:4,text:"AMQJS0004E Ping timed out."},INTERNAL_ERROR:{code:5,text:"AMQJS0005E Internal error. Error Message: {0}, Stack trace: {1}"},CONNACK_RETURNCODE:{code:6,text:"AMQJS0006E Bad Connack return code:{0} {1}."},SOCKET_ERROR:{code:7,text:"AMQJS0007E Socket error:{0}."},SOCKET_CLOSE:{code:8,text:"AMQJS0008I Socket closed."},MALFORMED_UTF:{code:9,text:"AMQJS0009E Malformed UTF data:{0} {1} {2}."},UNSUPPORTED:{code:10,text:"AMQJS0010E {0} is not supported by this browser."},INVALID_STATE:{code:11,text:"AMQJS0011E Invalid state {0}."},INVALID_TYPE:{code:12,text:"AMQJS0012E Invalid type {0} for {1}."},INVALID_ARGUMENT:{code:13,text:"AMQJS0013E Invalid argument {0} for {1}."},UNSUPPORTED_OPERATION:{code:14,text:"AMQJS0014E Unsupported operation."},INVALID_STORED_DATA:{code:15,text:"AMQJS0015E Invalid data in local storage key={0} value={1}."},INVALID_MQTT_MESSAGE_TYPE:{code:16,text:"AMQJS0016E Invalid MQTT message type {0}."},MALFORMED_UNICODE:{code:17,text:"AMQJS0017E Malformed Unicode string:{0} {1}."},BUFFER_FULL:{code:18,text:"AMQJS0018E Message buffer is full, maximum buffer size: {0}."}},a={0:"Connection Accepted",1:"Connection Refused: unacceptable protocol version",2:"Connection Refused: identifier rejected",3:"Connection Refused: server unavailable",4:"Connection Refused: bad user name or password",5:"Connection Refused: not authorized"},l=function(e,t){var i=e.text;if(t)for(var r,n,s=0;s<t.length;s++)if(r="{"+s+"}",(n=i.indexOf(r))>0){var o=i.substring(0,n),a=i.substring(n+r.length);i=o+t[s]+a}return i},c=[0,6,77,81,73,115,100,112,3],u=[0,4,77,81,84,84,4],h=function(e,t){for(var i in this.type=e,t)t.hasOwnProperty(i)&&(this[i]=t[i])};function d(t,i){var r,n=i,s=t[i],o=s>>4,a=s&=15;i+=1;var l=0,c=1;do{if(i==t.length)return[null,n];l+=(127&(r=t[i++]))*c,c*=128}while(128&r);var u=i+l;if(u>t.length)return[null,n];var d=new h(o);switch(o){case 2:1&t[i++]&&(d.sessionPresent=!0),d.returnCode=t[i++];break;case 3:var p=a>>1&3,g=f(t,i),m=C(t,i+=2,g);i+=g,p>0&&(d.messageIdentifier=f(t,i),i+=2);var v=new e.Message(t.subarray(i,u));1&~a||(v.retained=!0),8&~a||(v.duplicate=!0),v.qos=p,v.destinationName=m,d.payloadMessage=v;break;case 4:case 5:case 6:case 7:case 11:d.messageIdentifier=f(t,i);break;case 9:d.messageIdentifier=f(t,i),i+=2,d.returnCode=t.subarray(i,u)}return[d,u]}function p(e,t,i){return t[i++]=e>>8,t[i++]=e%256,i}function g(e,t,i,r){return v(e,i,r=p(t,i,r)),r+t}function f(e,t){return 256*e[t]+e[t+1]}function m(e){for(var t=0,i=0;i<e.length;i++){var r=e.charCodeAt(i);r>2047?(55296<=r&&r<=56319&&(i++,t++),t+=3):r>127?t+=2:t++}return t}function v(e,t,i){for(var r=i,n=0;n<e.length;n++){var s=e.charCodeAt(n);if(55296<=s&&s<=56319){var a=e.charCodeAt(++n);if(isNaN(a))throw new Error(l(o.MALFORMED_UNICODE,[s,a]));s=a-56320+(s-55296<<10)+65536}s<=127?t[r++]=s:s<=2047?(t[r++]=s>>6&31|192,t[r++]=63&s|128):s<=65535?(t[r++]=s>>12&15|224,t[r++]=s>>6&63|128,t[r++]=63&s|128):(t[r++]=s>>18&7|240,t[r++]=s>>12&63|128,t[r++]=s>>6&63|128,t[r++]=63&s|128)}return t}function C(e,t,i){for(var r,n="",s=t;s<t+i;){var a=e[s++];if(a<128)r=a;else{var c=e[s++]-128;if(c<0)throw new Error(l(o.MALFORMED_UTF,[a.toString(16),c.toString(16),""]));if(a<224)r=64*(a-192)+c;else{var u=e[s++]-128;if(u<0)throw new Error(l(o.MALFORMED_UTF,[a.toString(16),c.toString(16),u.toString(16)]));if(a<240)r=4096*(a-224)+64*c+u;else{var h=e[s++]-128;if(h<0)throw new Error(l(o.MALFORMED_UTF,[a.toString(16),c.toString(16),u.toString(16),h.toString(16)]));if(!(a<248))throw new Error(l(o.MALFORMED_UTF,[a.toString(16),c.toString(16),u.toString(16),h.toString(16)]));r=262144*(a-240)+4096*c+64*u+h}}}r>65535&&(r-=65536,n+=String.fromCharCode(55296+(r>>10)),r=56320+(1023&r)),n+=String.fromCharCode(r)}return n}h.prototype.encode=function(){var e,t=(15&this.type)<<4,i=0,r=[],n=0;switch(void 0!==this.messageIdentifier&&(i+=2),this.type){case 1:switch(this.mqttVersion){case 3:i+=c.length+3;break;case 4:i+=u.length+3}i+=m(this.clientId)+2,void 0!==this.willMessage&&(i+=m(this.willMessage.destinationName)+2,(e=this.willMessage.payloadBytes)instanceof Uint8Array||(e=new Uint8Array(o)),i+=e.byteLength+2),void 0!==this.userName&&(i+=m(this.userName)+2),void 0!==this.password&&(i+=m(this.password)+2);break;case 8:t|=2;for(var s=0;s<this.topics.length;s++)r[s]=m(this.topics[s]),i+=r[s]+2;i+=this.requestedQos.length;break;case 10:for(t|=2,s=0;s<this.topics.length;s++)r[s]=m(this.topics[s]),i+=r[s]+2;break;case 6:t|=2;break;case 3:this.payloadMessage.duplicate&&(t|=8),t=t|=this.payloadMessage.qos<<1,this.payloadMessage.retained&&(t|=1),i+=(n=m(this.payloadMessage.destinationName))+2;var o=this.payloadMessage.payloadBytes;i+=o.byteLength,o instanceof ArrayBuffer?o=new Uint8Array(o):o instanceof Uint8Array||(o=new Uint8Array(o.buffer))}var a=function(e){var t=new Array(1),i=0;do{var r=e%128;(e>>=7)>0&&(r|=128),t[i++]=r}while(e>0&&i<4);return t}(i),l=a.length+1,h=new ArrayBuffer(i+l),d=new Uint8Array(h);if(d[0]=t,d.set(a,1),3==this.type)l=g(this.payloadMessage.destinationName,n,d,l);else if(1==this.type){switch(this.mqttVersion){case 3:d.set(c,l),l+=c.length;break;case 4:d.set(u,l),l+=u.length}var f=0;this.cleanSession&&(f=2),void 0!==this.willMessage&&(f|=4,f|=this.willMessage.qos<<3,this.willMessage.retained&&(f|=32)),void 0!==this.userName&&(f|=128),void 0!==this.password&&(f|=64),d[l++]=f,l=p(this.keepAliveInterval,d,l)}switch(void 0!==this.messageIdentifier&&(l=p(this.messageIdentifier,d,l)),this.type){case 1:l=g(this.clientId,m(this.clientId),d,l),void 0!==this.willMessage&&(l=g(this.willMessage.destinationName,m(this.willMessage.destinationName),d,l),l=p(e.byteLength,d,l),d.set(e,l),l+=e.byteLength),void 0!==this.userName&&(l=g(this.userName,m(this.userName),d,l)),void 0!==this.password&&(l=g(this.password,m(this.password),d,l));break;case 3:d.set(o,l);break;case 8:for(s=0;s<this.topics.length;s++)l=g(this.topics[s],r[s],d,l),d[l++]=this.requestedQos[s];break;case 10:for(s=0;s<this.topics.length;s++)l=g(this.topics[s],r[s],d,l)}return h};var y=function(e,t){this._client=e,this._keepAliveInterval=1e3*t,this.isReset=!1;var i=new h(12).encode(),r=function(e){return function(){return n.apply(e)}},n=function(){this.isReset?(this.isReset=!1,this._client._trace("Pinger.doPing","send PINGREQ"),this._client.socket.send(i),this.timeout=setTimeout(r(this),this._keepAliveInterval)):(this._client._trace("Pinger.doPing","Timed out"),this._client._disconnected(o.PING_TIMEOUT.code,l(o.PING_TIMEOUT)))};this.reset=function(){this.isReset=!0,clearTimeout(this.timeout),this._keepAliveInterval>0&&(this.timeout=setTimeout(r(this),this._keepAliveInterval))},this.cancel=function(){clearTimeout(this.timeout)}},w=function(e,t,i,r){t||(t=30),this.timeout=setTimeout(function(e,t,i){return function(){return e.apply(t,i)}}(i,e,r),1e3*t),this.cancel=function(){clearTimeout(this.timeout)}},S=function(e,i,n,s,a){if(!("WebSocket"in t)||null===t.WebSocket)throw new Error(l(o.UNSUPPORTED,["WebSocket"]));if(!("ArrayBuffer"in t)||null===t.ArrayBuffer)throw new Error(l(o.UNSUPPORTED,["ArrayBuffer"]));for(var c in this._trace("Paho.Client",e,i,n,s,a),this.host=i,this.port=n,this.path=s,this.uri=e,this.clientId=a,this._wsuri=null,this._localKey=i+":"+n+("/mqtt"!=s?":"+s:"")+":"+a+":",this._msg_queue=[],this._buffered_msg_queue=[],this._sentMessages={},this._receivedMessages={},this._notify_msg_sent={},this._message_identifier=1,this._sequence=0,r)0!==c.indexOf("Sent:"+this._localKey)&&0!==c.indexOf("Received:"+this._localKey)||this.restore(c)};S.prototype.host=null,S.prototype.port=null,S.prototype.path=null,S.prototype.uri=null,S.prototype.clientId=null,S.prototype.socket=null,S.prototype.connected=!1,S.prototype.maxMessageIdentifier=65536,S.prototype.connectOptions=null,S.prototype.hostIndex=null,S.prototype.onConnected=null,S.prototype.onConnectionLost=null,S.prototype.onMessageDelivered=null,S.prototype.onMessageArrived=null,S.prototype.traceFunction=null,S.prototype._msg_queue=null,S.prototype._buffered_msg_queue=null,S.prototype._connectTimeout=null,S.prototype.sendPinger=null,S.prototype.receivePinger=null,S.prototype._reconnectInterval=1,S.prototype._reconnecting=!1,S.prototype._reconnectTimeout=null,S.prototype.disconnectedPublishing=!1,S.prototype.disconnectedBufferSize=5e3,S.prototype.receiveBuffer=null,S.prototype._traceBuffer=null,S.prototype._MAX_TRACE_ENTRIES=100,S.prototype.connect=function(e){var t=this._traceMask(e,"password");if(this._trace("Client.connect",t,this.socket,this.connected),this.connected)throw new Error(l(o.INVALID_STATE,["already connected"]));if(this.socket)throw new Error(l(o.INVALID_STATE,["already connected"]));this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),this.connectOptions=e,this._reconnectInterval=1,this._reconnecting=!1,e.uris?(this.hostIndex=0,this._doConnect(e.uris[0])):this._doConnect(this.uri)},S.prototype.subscribe=function(e,t){if(this._trace("Client.subscribe",e,t),!this.connected)throw new Error(l(o.INVALID_STATE,["not connected"]));var i=new h(8);i.topics=[e],void 0!==t.qos?i.requestedQos=[t.qos]:i.requestedQos=[0],t.onSuccess&&(i.onSuccess=function(e){t.onSuccess({invocationContext:t.invocationContext,grantedQos:e})}),t.onFailure&&(i.onFailure=function(e){t.onFailure({invocationContext:t.invocationContext,errorCode:e,errorMessage:l(e)})}),t.timeout&&(i.timeOut=new w(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:o.SUBSCRIBE_TIMEOUT.code,errorMessage:l(o.SUBSCRIBE_TIMEOUT)}])),this._requires_ack(i),this._schedule_message(i)},S.prototype.unsubscribe=function(e,t){if(this._trace("Client.unsubscribe",e,t),!this.connected)throw new Error(l(o.INVALID_STATE,["not connected"]));var i=new h(10);i.topics=[e],t.onSuccess&&(i.callback=function(){t.onSuccess({invocationContext:t.invocationContext})}),t.timeout&&(i.timeOut=new w(this,t.timeout,t.onFailure,[{invocationContext:t.invocationContext,errorCode:o.UNSUBSCRIBE_TIMEOUT.code,errorMessage:l(o.UNSUBSCRIBE_TIMEOUT)}])),this._requires_ack(i),this._schedule_message(i)},S.prototype.send=function(e){this._trace("Client.send",e);var t=new h(3);if(t.payloadMessage=e,this.connected)e.qos>0?this._requires_ack(t):this.onMessageDelivered&&(this._notify_msg_sent[t]=this.onMessageDelivered(t.payloadMessage)),this._schedule_message(t);else{if(!this._reconnecting||!this.disconnectedPublishing)throw new Error(l(o.INVALID_STATE,["not connected"]));if(Object.keys(this._sentMessages).length+this._buffered_msg_queue.length>this.disconnectedBufferSize)throw new Error(l(o.BUFFER_FULL,[this.disconnectedBufferSize]));e.qos>0?this._requires_ack(t):(t.sequence=++this._sequence,this._buffered_msg_queue.unshift(t))}},S.prototype.disconnect=function(){if(this._trace("Client.disconnect"),this._reconnecting&&(this._reconnectTimeout.cancel(),this._reconnectTimeout=null,this._reconnecting=!1),!this.socket)throw new Error(l(o.INVALID_STATE,["not connecting or connected"]));var e=new h(14);this._notify_msg_sent[e]=s(this._disconnected,this),this._schedule_message(e)},S.prototype.getTraceLog=function(){if(null!==this._traceBuffer){for(var e in this._trace("Client.getTraceLog",new Date),this._trace("Client.getTraceLog in flight messages",this._sentMessages.length),this._sentMessages)this._trace("_sentMessages ",e,this._sentMessages[e]);for(var e in this._receivedMessages)this._trace("_receivedMessages ",e,this._receivedMessages[e]);return this._traceBuffer}},S.prototype.startTrace=function(){null===this._traceBuffer&&(this._traceBuffer=[]),this._trace("Client.startTrace",new Date,"@VERSION@-@BUILDLEVEL@")},S.prototype.stopTrace=function(){delete this._traceBuffer},S.prototype._doConnect=function(e){if(this.connectOptions.useSSL){var t=e.split(":");t[0]="wss",e=t.join(":")}this._wsuri=e,this.connected=!1,this.connectOptions.mqttVersion<4?this.socket=new WebSocket(e,["mqttv3.1"]):this.socket=new WebSocket(e,["mqtt"]),this.socket.binaryType="arraybuffer",this.socket.onopen=s(this._on_socket_open,this),this.socket.onmessage=s(this._on_socket_message,this),this.socket.onerror=s(this._on_socket_error,this),this.socket.onclose=s(this._on_socket_close,this),this.sendPinger=new y(this,this.connectOptions.keepAliveInterval),this.receivePinger=new y(this,this.connectOptions.keepAliveInterval),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._connectTimeout=new w(this,this.connectOptions.timeout,this._disconnected,[o.CONNECT_TIMEOUT.code,l(o.CONNECT_TIMEOUT)])},S.prototype._schedule_message=function(e){this._msg_queue.unshift(e),this.connected&&this._process_queue()},S.prototype.store=function(e,t){var i={type:t.type,messageIdentifier:t.messageIdentifier,version:1};if(3!==t.type)throw Error(l(o.INVALID_STORED_DATA,[e+this._localKey+t.messageIdentifier,i]));t.pubRecReceived&&(i.pubRecReceived=!0),i.payloadMessage={};for(var n="",s=t.payloadMessage.payloadBytes,a=0;a<s.length;a++)s[a]<=15?n=n+"0"+s[a].toString(16):n+=s[a].toString(16);i.payloadMessage.payloadHex=n,i.payloadMessage.qos=t.payloadMessage.qos,i.payloadMessage.destinationName=t.payloadMessage.destinationName,t.payloadMessage.duplicate&&(i.payloadMessage.duplicate=!0),t.payloadMessage.retained&&(i.payloadMessage.retained=!0),0===e.indexOf("Sent:")&&(void 0===t.sequence&&(t.sequence=++this._sequence),i.sequence=t.sequence),r.setItem(e+this._localKey+t.messageIdentifier,JSON.stringify(i))},S.prototype.restore=function(t){var i=r.getItem(t),n=JSON.parse(i),s=new h(n.type,n);if(3!==n.type)throw Error(l(o.INVALID_STORED_DATA,[t,i]));for(var a=n.payloadMessage.payloadHex,c=new ArrayBuffer(a.length/2),u=new Uint8Array(c),d=0;a.length>=2;){var p=parseInt(a.substring(0,2),16);a=a.substring(2,a.length),u[d++]=p}var g=new e.Message(u);g.qos=n.payloadMessage.qos,g.destinationName=n.payloadMessage.destinationName,n.payloadMessage.duplicate&&(g.duplicate=!0),n.payloadMessage.retained&&(g.retained=!0),s.payloadMessage=g,0===t.indexOf("Sent:"+this._localKey)?(s.payloadMessage.duplicate=!0,this._sentMessages[s.messageIdentifier]=s):0===t.indexOf("Received:"+this._localKey)&&(this._receivedMessages[s.messageIdentifier]=s)},S.prototype._process_queue=function(){for(var e=null;e=this._msg_queue.pop();)this._socket_send(e),this._notify_msg_sent[e]&&(this._notify_msg_sent[e](),delete this._notify_msg_sent[e])},S.prototype._requires_ack=function(e){var t=Object.keys(this._sentMessages).length;if(t>this.maxMessageIdentifier)throw Error("Too many messages:"+t);for(;void 0!==this._sentMessages[this._message_identifier];)this._message_identifier++;e.messageIdentifier=this._message_identifier,this._sentMessages[e.messageIdentifier]=e,3===e.type&&this.store("Sent:",e),this._message_identifier===this.maxMessageIdentifier&&(this._message_identifier=1)},S.prototype._on_socket_open=function(){var e=new h(1,this.connectOptions);e.clientId=this.clientId,this._socket_send(e)},S.prototype._on_socket_message=function(e){this._trace("Client._on_socket_message",e.data);for(var t=this._deframeMessages(e.data),i=0;i<t.length;i+=1)this._handleMessage(t[i])},S.prototype._deframeMessages=function(e){var t=new Uint8Array(e),i=[];if(this.receiveBuffer){var r=new Uint8Array(this.receiveBuffer.length+t.length);r.set(this.receiveBuffer),r.set(t,this.receiveBuffer.length),t=r,delete this.receiveBuffer}try{for(var n=0;n<t.length;){var s=d(t,n),a=s[0];if(n=s[1],null===a)break;i.push(a)}n<t.length&&(this.receiveBuffer=t.subarray(n))}catch(e){var c="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(o.INTERNAL_ERROR.code,l(o.INTERNAL_ERROR,[e.message,c]))}return i},S.prototype._handleMessage=function(e){this._trace("Client._handleMessage",e);try{switch(e.type){case 2:if(this._connectTimeout.cancel(),this._reconnectTimeout&&this._reconnectTimeout.cancel(),this.connectOptions.cleanSession){for(var t in this._sentMessages){var i=this._sentMessages[t];r.removeItem("Sent:"+this._localKey+i.messageIdentifier)}for(var t in this._sentMessages={},this._receivedMessages){var n=this._receivedMessages[t];r.removeItem("Received:"+this._localKey+n.messageIdentifier)}this._receivedMessages={}}if(0!==e.returnCode){this._disconnected(o.CONNACK_RETURNCODE.code,l(o.CONNACK_RETURNCODE,[e.returnCode,a[e.returnCode]]));break}this.connected=!0,this.connectOptions.uris&&(this.hostIndex=this.connectOptions.uris.length);var s=[];for(var c in this._sentMessages)this._sentMessages.hasOwnProperty(c)&&s.push(this._sentMessages[c]);if(this._buffered_msg_queue.length>0)for(var u=null;u=this._buffered_msg_queue.pop();)s.push(u),this.onMessageDelivered&&(this._notify_msg_sent[u]=this.onMessageDelivered(u.payloadMessage));s=s.sort(function(e,t){return e.sequence-t.sequence});for(var d=0,p=s.length;d<p;d++)if(3==(i=s[d]).type&&i.pubRecReceived){var g=new h(6,{messageIdentifier:i.messageIdentifier});this._schedule_message(g)}else this._schedule_message(i);this.connectOptions.onSuccess&&this.connectOptions.onSuccess({invocationContext:this.connectOptions.invocationContext});var f=!1;this._reconnecting&&(f=!0,this._reconnectInterval=1,this._reconnecting=!1),this._connected(f,this._wsuri),this._process_queue();break;case 3:this._receivePublish(e);break;case 4:(i=this._sentMessages[e.messageIdentifier])&&(delete this._sentMessages[e.messageIdentifier],r.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(i.payloadMessage));break;case 5:(i=this._sentMessages[e.messageIdentifier])&&(i.pubRecReceived=!0,g=new h(6,{messageIdentifier:e.messageIdentifier}),this.store("Sent:",i),this._schedule_message(g));break;case 6:n=this._receivedMessages[e.messageIdentifier],r.removeItem("Received:"+this._localKey+e.messageIdentifier),n&&(this._receiveMessage(n),delete this._receivedMessages[e.messageIdentifier]);var m=new h(7,{messageIdentifier:e.messageIdentifier});this._schedule_message(m);break;case 7:i=this._sentMessages[e.messageIdentifier],delete this._sentMessages[e.messageIdentifier],r.removeItem("Sent:"+this._localKey+e.messageIdentifier),this.onMessageDelivered&&this.onMessageDelivered(i.payloadMessage);break;case 9:(i=this._sentMessages[e.messageIdentifier])&&(i.timeOut&&i.timeOut.cancel(),128===e.returnCode[0]?i.onFailure&&i.onFailure(e.returnCode):i.onSuccess&&i.onSuccess(e.returnCode),delete this._sentMessages[e.messageIdentifier]);break;case 11:(i=this._sentMessages[e.messageIdentifier])&&(i.timeOut&&i.timeOut.cancel(),i.callback&&i.callback(),delete this._sentMessages[e.messageIdentifier]);break;case 13:this.sendPinger.reset();break;default:this._disconnected(o.INVALID_MQTT_MESSAGE_TYPE.code,l(o.INVALID_MQTT_MESSAGE_TYPE,[e.type]))}}catch(e){var v="undefined"==e.hasOwnProperty("stack")?e.stack.toString():"No Error Stack Available";return void this._disconnected(o.INTERNAL_ERROR.code,l(o.INTERNAL_ERROR,[e.message,v]))}},S.prototype._on_socket_error=function(e){this._reconnecting||this._disconnected(o.SOCKET_ERROR.code,l(o.SOCKET_ERROR,[e.data]))},S.prototype._on_socket_close=function(){this._reconnecting||this._disconnected(o.SOCKET_CLOSE.code,l(o.SOCKET_CLOSE))},S.prototype._socket_send=function(e){if(1==e.type){var t=this._traceMask(e,"password");this._trace("Client._socket_send",t)}else this._trace("Client._socket_send",e);this.socket.send(e.encode()),this.sendPinger.reset()},S.prototype._receivePublish=function(e){switch(e.payloadMessage.qos){case"undefined":case 0:this._receiveMessage(e);break;case 1:var t=new h(4,{messageIdentifier:e.messageIdentifier});this._schedule_message(t),this._receiveMessage(e);break;case 2:this._receivedMessages[e.messageIdentifier]=e,this.store("Received:",e);var i=new h(5,{messageIdentifier:e.messageIdentifier});this._schedule_message(i);break;default:throw Error("Invaild qos="+e.payloadMessage.qos)}},S.prototype._receiveMessage=function(e){this.onMessageArrived&&this.onMessageArrived(e.payloadMessage)},S.prototype._connected=function(e,t){this.onConnected&&this.onConnected(e,t)},S.prototype._reconnect=function(){this._trace("Client._reconnect"),this.connected||(this._reconnecting=!0,this.sendPinger.cancel(),this.receivePinger.cancel(),this._reconnectInterval<128&&(this._reconnectInterval=2*this._reconnectInterval),this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri))},S.prototype._disconnected=function(e,t){if(this._trace("Client._disconnected",e,t),void 0!==e&&this._reconnecting)this._reconnectTimeout=new w(this,this._reconnectInterval,this._reconnect);else if(this.sendPinger.cancel(),this.receivePinger.cancel(),this._connectTimeout&&(this._connectTimeout.cancel(),this._connectTimeout=null),this._msg_queue=[],this._buffered_msg_queue=[],this._notify_msg_sent={},this.socket&&(this.socket.onopen=null,this.socket.onmessage=null,this.socket.onerror=null,this.socket.onclose=null,1===this.socket.readyState&&this.socket.close(),delete this.socket),this.connectOptions.uris&&this.hostIndex<this.connectOptions.uris.length-1)this.hostIndex++,this._doConnect(this.connectOptions.uris[this.hostIndex]);else if(void 0===e&&(e=o.OK.code,t=l(o.OK)),this.connected){if(this.connected=!1,this.onConnectionLost&&this.onConnectionLost({errorCode:e,errorMessage:t,reconnect:this.connectOptions.reconnect,uri:this._wsuri}),e!==o.OK.code&&this.connectOptions.reconnect)return this._reconnectInterval=1,void this._reconnect()}else 4===this.connectOptions.mqttVersion&&!1===this.connectOptions.mqttVersionExplicit?(this._trace("Failed to connect V4, dropping back to V3"),this.connectOptions.mqttVersion=3,this.connectOptions.uris?(this.hostIndex=0,this._doConnect(this.connectOptions.uris[0])):this._doConnect(this.uri)):this.connectOptions.onFailure&&this.connectOptions.onFailure({invocationContext:this.connectOptions.invocationContext,errorCode:e,errorMessage:t})},S.prototype._trace=function(){if(this.traceFunction){var e=Array.prototype.slice.call(arguments);for(var t in e)void 0!==e[t]&&e.splice(t,1,JSON.stringify(e[t]));var i=e.join("");this.traceFunction({severity:"Debug",message:i})}if(null!==this._traceBuffer){t=0;for(var r=arguments.length;t<r;t++)this._traceBuffer.length==this._MAX_TRACE_ENTRIES&&this._traceBuffer.shift(),0===t||void 0===arguments[t]?this._traceBuffer.push(arguments[t]):this._traceBuffer.push("  "+JSON.stringify(arguments[t]))}},S.prototype._traceMask=function(e,t){var i={};for(var r in e)e.hasOwnProperty(r)&&(i[r]=r==t?"******":e[r]);return i};var b=function(e){var t,i;if(!("string"==typeof e||e instanceof ArrayBuffer||ArrayBuffer.isView(e)&&!(e instanceof DataView)))throw l(o.INVALID_ARGUMENT,[e,"newPayload"]);t=e;var r=0,n=!1,s=!1;Object.defineProperties(this,{payloadString:{enumerable:!0,get:function(){return"string"==typeof t?t:C(t,0,t.length)}},payloadBytes:{enumerable:!0,get:function(){if("string"==typeof t){var e=new ArrayBuffer(m(t)),i=new Uint8Array(e);return v(t,i,0),i}return t}},destinationName:{enumerable:!0,get:function(){return i},set:function(e){if("string"!=typeof e)throw new Error(l(o.INVALID_ARGUMENT,[e,"newDestinationName"]));i=e}},qos:{enumerable:!0,get:function(){return r},set:function(e){if(0!==e&&1!==e&&2!==e)throw new Error("Invalid argument:"+e);r=e}},retained:{enumerable:!0,get:function(){return n},set:function(e){if("boolean"!=typeof e)throw new Error(l(o.INVALID_ARGUMENT,[e,"newRetained"]));n=e}},topic:{enumerable:!0,get:function(){return i},set:function(e){i=e}},duplicate:{enumerable:!0,get:function(){return s},set:function(e){s=e}}})};return{Client:function(e,t,i,r){var s;if("string"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"host"]));if(2==arguments.length){r=t;var a=(s=e).match(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/);if(!a)throw new Error(l(o.INVALID_ARGUMENT,[e,"host"]));e=a[4]||a[2],t=parseInt(a[7]),i=a[8]}else{if(3==arguments.length&&(r=i,i="/mqtt"),"number"!=typeof t||t<0)throw new Error(l(o.INVALID_TYPE,[typeof t,"port"]));if("string"!=typeof i)throw new Error(l(o.INVALID_TYPE,[typeof i,"path"]));var c=-1!==e.indexOf(":")&&"["!==e.slice(0,1)&&"]"!==e.slice(-1);s="ws://"+(c?"["+e+"]":e)+":"+t+i}for(var u=0,h=0;h<r.length;h++){var d=r.charCodeAt(h);55296<=d&&d<=56319&&h++,u++}if("string"!=typeof r||u>65535)throw new Error(l(o.INVALID_ARGUMENT,[r,"clientId"]));var p=new S(s,e,t,i,r);Object.defineProperties(this,{host:{get:function(){return e},set:function(){throw new Error(l(o.UNSUPPORTED_OPERATION))}},port:{get:function(){return t},set:function(){throw new Error(l(o.UNSUPPORTED_OPERATION))}},path:{get:function(){return i},set:function(){throw new Error(l(o.UNSUPPORTED_OPERATION))}},uri:{get:function(){return s},set:function(){throw new Error(l(o.UNSUPPORTED_OPERATION))}},clientId:{get:function(){return p.clientId},set:function(){throw new Error(l(o.UNSUPPORTED_OPERATION))}},onConnected:{get:function(){return p.onConnected},set:function(e){if("function"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"onConnected"]));p.onConnected=e}},disconnectedPublishing:{get:function(){return p.disconnectedPublishing},set:function(e){p.disconnectedPublishing=e}},disconnectedBufferSize:{get:function(){return p.disconnectedBufferSize},set:function(e){p.disconnectedBufferSize=e}},onConnectionLost:{get:function(){return p.onConnectionLost},set:function(e){if("function"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"onConnectionLost"]));p.onConnectionLost=e}},onMessageDelivered:{get:function(){return p.onMessageDelivered},set:function(e){if("function"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"onMessageDelivered"]));p.onMessageDelivered=e}},onMessageArrived:{get:function(){return p.onMessageArrived},set:function(e){if("function"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"onMessageArrived"]));p.onMessageArrived=e}},trace:{get:function(){return p.traceFunction},set:function(e){if("function"!=typeof e)throw new Error(l(o.INVALID_TYPE,[typeof e,"onTrace"]));p.traceFunction=e}}}),this.connect=function(e){if(n(e=e||{},{timeout:"number",userName:"string",password:"string",willMessage:"object",keepAliveInterval:"number",cleanSession:"boolean",useSSL:"boolean",invocationContext:"object",onSuccess:"function",onFailure:"function",hosts:"object",ports:"object",reconnect:"boolean",mqttVersion:"number",mqttVersionExplicit:"boolean",uris:"object"}),void 0===e.keepAliveInterval&&(e.keepAliveInterval=60),e.mqttVersion>4||e.mqttVersion<3)throw new Error(l(o.INVALID_ARGUMENT,[e.mqttVersion,"connectOptions.mqttVersion"]));if(void 0===e.mqttVersion?(e.mqttVersionExplicit=!1,e.mqttVersion=4):e.mqttVersionExplicit=!0,void 0!==e.password&&void 0===e.userName)throw new Error(l(o.INVALID_ARGUMENT,[e.password,"connectOptions.password"]));if(e.willMessage){if(!(e.willMessage instanceof b))throw new Error(l(o.INVALID_TYPE,[e.willMessage,"connectOptions.willMessage"]));if(e.willMessage.stringPayload=null,void 0===e.willMessage.destinationName)throw new Error(l(o.INVALID_TYPE,[typeof e.willMessage.destinationName,"connectOptions.willMessage.destinationName"]))}if(void 0===e.cleanSession&&(e.cleanSession=!0),e.hosts){if(!(e.hosts instanceof Array))throw new Error(l(o.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));if(e.hosts.length<1)throw new Error(l(o.INVALID_ARGUMENT,[e.hosts,"connectOptions.hosts"]));for(var t=!1,r=0;r<e.hosts.length;r++){if("string"!=typeof e.hosts[r])throw new Error(l(o.INVALID_TYPE,[typeof e.hosts[r],"connectOptions.hosts["+r+"]"]));if(/^(wss?):\/\/((\[(.+)\])|([^\/]+?))(:(\d+))?(\/.*)$/.test(e.hosts[r])){if(0===r)t=!0;else if(!t)throw new Error(l(o.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}else if(t)throw new Error(l(o.INVALID_ARGUMENT,[e.hosts[r],"connectOptions.hosts["+r+"]"]))}if(t)e.uris=e.hosts;else{if(!e.ports)throw new Error(l(o.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(!(e.ports instanceof Array))throw new Error(l(o.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));if(e.hosts.length!==e.ports.length)throw new Error(l(o.INVALID_ARGUMENT,[e.ports,"connectOptions.ports"]));for(e.uris=[],r=0;r<e.hosts.length;r++){if("number"!=typeof e.ports[r]||e.ports[r]<0)throw new Error(l(o.INVALID_TYPE,[typeof e.ports[r],"connectOptions.ports["+r+"]"]));var a=e.hosts[r],c=e.ports[r],u=-1!==a.indexOf(":");s="ws://"+(u?"["+a+"]":a)+":"+c+i,e.uris.push(s)}}}p.connect(e)},this.subscribe=function(e,t){if("string"!=typeof e)throw new Error("Invalid argument:"+e);if(n(t=t||{},{qos:"number",invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("subscribeOptions.timeout specified with no onFailure callback.");if(void 0!==t.qos&&0!==t.qos&&1!==t.qos&&2!==t.qos)throw new Error(l(o.INVALID_ARGUMENT,[t.qos,"subscribeOptions.qos"]));p.subscribe(e,t)},this.unsubscribe=function(e,t){if("string"!=typeof e)throw new Error("Invalid argument:"+e);if(n(t=t||{},{invocationContext:"object",onSuccess:"function",onFailure:"function",timeout:"number"}),t.timeout&&!t.onFailure)throw new Error("unsubscribeOptions.timeout specified with no onFailure callback.");p.unsubscribe(e,t)},this.send=function(e,t,i,r){var n;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof b)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(n=e).destinationName)throw new Error(l(o.INVALID_ARGUMENT,[n.destinationName,"Message.destinationName"]));p.send(n)}else(n=new b(t)).destinationName=e,arguments.length>=3&&(n.qos=i),arguments.length>=4&&(n.retained=r),p.send(n)},this.publish=function(e,t,i,r){var n;if(0===arguments.length)throw new Error("Invalid argument.length");if(1==arguments.length){if(!(e instanceof b)&&"string"!=typeof e)throw new Error("Invalid argument:"+typeof e);if(void 0===(n=e).destinationName)throw new Error(l(o.INVALID_ARGUMENT,[n.destinationName,"Message.destinationName"]));p.send(n)}else(n=new b(t)).destinationName=e,arguments.length>=3&&(n.qos=i),arguments.length>=4&&(n.retained=r),p.send(n)},this.disconnect=function(){p.disconnect()},this.getTraceLog=function(){return p.getTraceLog()},this.startTrace=function(){p.startTrace()},this.stopTrace=function(){p.stopTrace()},this.isConnected=function(){return p.connected}},Message:b}}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{});return e},e.exports=t()},5611(e,t,i){e.exports={default:i(85877),__esModule:!0}},80238(e,t,i){e.exports={default:i(13112),__esModule:!0}},65191(e,t,i){e.exports={default:i(30481),__esModule:!0}},38841(e,t,i){e.exports={default:i(18307),__esModule:!0}},12581(e,t,i){e.exports={default:i(55111),__esModule:!0}},20144(e,t,i){e.exports={default:i(27773),__esModule:!0}},75697(e,t,i){e.exports={default:i(63315),__esModule:!0}},17380(e,t){"use strict";t.__esModule=!0,t.default=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},31354(e,t,i){"use strict";t.__esModule=!0;var r,n=(r=i(65191))&&r.__esModule?r:{default:r};t.default=function(){function e(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),(0,n.default)(e,r.key,r)}}return function(t,i,r){return i&&e(t.prototype,i),r&&e(t,r),t}}()},84011(e,t,i){"use strict";t.__esModule=!0;var r,n=(r=i(5611))&&r.__esModule?r:{default:r};t.default=n.default||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e}},87724(e,t,i){"use strict";t.__esModule=!0;var r=o(i(12581)),n=o(i(80238)),s=o(i(38829));function o(e){return e&&e.__esModule?e:{default:e}}t.default=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+(void 0===t?"undefined":(0,s.default)(t)));e.prototype=(0,n.default)(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(r.default?(0,r.default)(e,t):e.__proto__=t)}},77857(e,t,i){"use strict";t.__esModule=!0;var r,n=(r=i(38829))&&r.__esModule?r:{default:r};t.default=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!==(void 0===t?"undefined":(0,n.default)(t))&&"function"!=typeof t?e:t}},38829(e,t,i){"use strict";t.__esModule=!0;var r=o(i(75697)),n=o(i(20144)),s="function"==typeof n.default&&"symbol"==typeof r.default?function(e){return typeof e}:function(e){return e&&"function"==typeof n.default&&e.constructor===n.default&&e!==n.default.prototype?"symbol":typeof e};function o(e){return e&&e.__esModule?e:{default:e}}t.default="function"==typeof n.default&&"symbol"===s(r.default)?function(e){return void 0===e?"undefined":s(e)}:function(e){return e&&"function"==typeof n.default&&e.constructor===n.default&&e!==n.default.prototype?"symbol":void 0===e?"undefined":s(e)}},92178(e){"use strict";e.exports=function(e){if(e)throw e}},84933(e,t){"use strict";t.byteLength=function(e){var t=a(e),i=t[0],r=t[1];return 3*(i+r)/4-r},t.toByteArray=function(e){var t,i,s=a(e),o=s[0],l=s[1],c=new n(function(e,t,i){return 3*(t+i)/4-i}(0,o,l)),u=0,h=l>0?o-4:o;for(i=0;i<h;i+=4)t=r[e.charCodeAt(i)]<<18|r[e.charCodeAt(i+1)]<<12|r[e.charCodeAt(i+2)]<<6|r[e.charCodeAt(i+3)],c[u++]=t>>16&255,c[u++]=t>>8&255,c[u++]=255&t;return 2===l&&(t=r[e.charCodeAt(i)]<<2|r[e.charCodeAt(i+1)]>>4,c[u++]=255&t),1===l&&(t=r[e.charCodeAt(i)]<<10|r[e.charCodeAt(i+1)]<<4|r[e.charCodeAt(i+2)]>>2,c[u++]=t>>8&255,c[u++]=255&t),c},t.fromByteArray=function(e){for(var t,r=e.length,n=r%3,s=[],o=16383,a=0,l=r-n;a<l;a+=o)s.push(c(e,a,a+o>l?l:a+o));return 1===n?(t=e[r-1],s.push(i[t>>2]+i[t<<4&63]+"==")):2===n&&(t=(e[r-2]<<8)+e[r-1],s.push(i[t>>10]+i[t>>4&63]+i[t<<2&63]+"=")),s.join("")};for(var i=[],r=[],n="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",o=0;o<64;++o)i[o]=s[o],r[s.charCodeAt(o)]=o;function a(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var i=e.indexOf("=");return-1===i&&(i=t),[i,i===t?0:4-i%4]}function l(e){return i[e>>18&63]+i[e>>12&63]+i[e>>6&63]+i[63&e]}function c(e,t,i){for(var r,n=[],s=t;s<i;s+=3)r=(e[s]<<16&16711680)+(e[s+1]<<8&65280)+(255&e[s+2]),n.push(l(r));return n.join("")}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},5630(e,t,i){!function(e,t){"use strict";function r(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var i=function(){};i.prototype=t.prototype,e.prototype=new i,e.prototype.constructor=e}function s(e,t,i){if(s.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(i=t,t=10),this._init(e||0,t||10,i||"be"))}var o;"object"==typeof e?e.exports=s:t.BN=s,s.BN=s,s.wordSize=26;try{o="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:i(46216).Buffer}catch(e){}function a(e,t){var i=e.charCodeAt(t);return i>=65&&i<=70?i-55:i>=97&&i<=102?i-87:i-48&15}function l(e,t,i){var r=a(e,i);return i-1>=t&&(r|=a(e,i-1)<<4),r}function c(e,t,i,r){for(var n=0,s=Math.min(e.length,i),o=t;o<s;o++){var a=e.charCodeAt(o)-48;n*=r,n+=a>=49?a-49+10:a>=17?a-17+10:a}return n}s.isBN=function(e){return e instanceof s||null!==e&&"object"==typeof e&&e.constructor.wordSize===s.wordSize&&Array.isArray(e.words)},s.max=function(e,t){return e.cmp(t)>0?e:t},s.min=function(e,t){return e.cmp(t)<0?e:t},s.prototype._init=function(e,t,i){if("number"==typeof e)return this._initNumber(e,t,i);if("object"==typeof e)return this._initArray(e,t,i);"hex"===t&&(t=16),r(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n<e.length&&(16===t?this._parseHex(e,n,i):(this._parseBase(e,t,n),"le"===i&&this._initArray(this.toArray(),t,i)))},s.prototype._initNumber=function(e,t,i){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(r(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===i&&this._initArray(this.toArray(),t,i)},s.prototype._initArray=function(e,t,i){if(r("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var s,o,a=0;if("be"===i)for(n=e.length-1,s=0;n>=0;n-=3)o=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[s]|=o<<a&67108863,this.words[s+1]=o>>>26-a&67108863,(a+=24)>=26&&(a-=26,s++);else if("le"===i)for(n=0,s=0;n<e.length;n+=3)o=e[n]|e[n+1]<<8|e[n+2]<<16,this.words[s]|=o<<a&67108863,this.words[s+1]=o>>>26-a&67108863,(a+=24)>=26&&(a-=26,s++);return this.strip()},s.prototype._parseHex=function(e,t,i){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var n,s=0,o=0;if("be"===i)for(r=e.length-1;r>=t;r-=2)n=l(e,t,r)<<s,this.words[o]|=67108863&n,s>=18?(s-=18,o+=1,this.words[o]|=n>>>26):s+=8;else for(r=(e.length-t)%2==0?t+1:t;r<e.length;r+=2)n=l(e,t,r)<<s,this.words[o]|=67108863&n,s>=18?(s-=18,o+=1,this.words[o]|=n>>>26):s+=8;this.strip()},s.prototype._parseBase=function(e,t,i){this.words=[0],this.length=1;for(var r=0,n=1;n<=67108863;n*=t)r++;r--,n=n/t|0;for(var s=e.length-i,o=s%r,a=Math.min(s,s-o)+i,l=0,u=i;u<a;u+=r)l=c(e,u,u+r,t),this.imuln(n),this.words[0]+l<67108864?this.words[0]+=l:this._iaddn(l);if(0!==o){var h=1;for(l=c(e,u,e.length,t),u=0;u<o;u++)h*=t;this.imuln(h),this.words[0]+l<67108864?this.words[0]+=l:this._iaddn(l)}this.strip()},s.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},s.prototype.clone=function(){var e=new s(null);return this.copy(e),e},s.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},s.prototype.strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},s.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},s.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var u=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],h=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],d=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function p(e,t,i){i.negative=t.negative^e.negative;var r=e.length+t.length|0;i.length=r,r=r-1|0;var n=0|e.words[0],s=0|t.words[0],o=n*s,a=67108863&o,l=o/67108864|0;i.words[0]=a;for(var c=1;c<r;c++){for(var u=l>>>26,h=67108863&l,d=Math.min(c,t.length-1),p=Math.max(0,c-e.length+1);p<=d;p++){var g=c-p|0;u+=(o=(n=0|e.words[g])*(s=0|t.words[p])+h)/67108864|0,h=67108863&o}i.words[c]=0|h,l=0|u}return 0!==l?i.words[c]=0|l:i.length--,i.strip()}s.prototype.toString=function(e,t){var i;if(t=0|t||1,16===(e=e||10)||"hex"===e){i="";for(var n=0,s=0,o=0;o<this.length;o++){var a=this.words[o],l=(16777215&(a<<n|s)).toString(16);s=a>>>24-n&16777215,(n+=2)>=26&&(n-=26,o--),i=0!==s||o!==this.length-1?u[6-l.length]+l+i:l+i}for(0!==s&&(i=s.toString(16)+i);i.length%t!==0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}if(e===(0|e)&&e>=2&&e<=36){var c=h[e],p=d[e];i="";var g=this.clone();for(g.negative=0;!g.isZero();){var f=g.modn(p).toString(e);i=(g=g.idivn(p)).isZero()?f+i:u[c-f.length]+f+i}for(this.isZero()&&(i="0"+i);i.length%t!==0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}r(!1,"Base should be between 2 and 36")},s.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},s.prototype.toJSON=function(){return this.toString(16)},s.prototype.toBuffer=function(e,t){return r(void 0!==o),this.toArrayLike(o,e,t)},s.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},s.prototype.toArrayLike=function(e,t,i){var n=this.byteLength(),s=i||Math.max(1,n);r(n<=s,"byte array longer than desired length"),r(s>0,"Requested array length <= 0"),this.strip();var o,a,l="le"===t,c=new e(s),u=this.clone();if(l){for(a=0;!u.isZero();a++)o=u.andln(255),u.iushrn(8),c[a]=o;for(;a<s;a++)c[a]=0}else{for(a=0;a<s-n;a++)c[a]=0;for(a=0;!u.isZero();a++)o=u.andln(255),u.iushrn(8),c[s-a-1]=o}return c},Math.clz32?s.prototype._countBits=function(e){return 32-Math.clz32(e)}:s.prototype._countBits=function(e){var t=e,i=0;return t>=4096&&(i+=13,t>>>=13),t>=64&&(i+=7,t>>>=7),t>=8&&(i+=4,t>>>=4),t>=2&&(i+=2,t>>>=2),i+t},s.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,i=0;return 8191&t||(i+=13,t>>>=13),127&t||(i+=7,t>>>=7),15&t||(i+=4,t>>>=4),3&t||(i+=2,t>>>=2),1&t||i++,i},s.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},s.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var i=this._zeroBits(this.words[t]);if(e+=i,26!==i)break}return e},s.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},s.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},s.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},s.prototype.isNeg=function(){return 0!==this.negative},s.prototype.neg=function(){return this.clone().ineg()},s.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},s.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this.strip()},s.prototype.ior=function(e){return r(0===(this.negative|e.negative)),this.iuor(e)},s.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},s.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},s.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var i=0;i<t.length;i++)this.words[i]=this.words[i]&e.words[i];return this.length=t.length,this.strip()},s.prototype.iand=function(e){return r(0===(this.negative|e.negative)),this.iuand(e)},s.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},s.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},s.prototype.iuxor=function(e){var t,i;this.length>e.length?(t=this,i=e):(t=e,i=this);for(var r=0;r<i.length;r++)this.words[r]=t.words[r]^i.words[r];if(this!==t)for(;r<t.length;r++)this.words[r]=t.words[r];return this.length=t.length,this.strip()},s.prototype.ixor=function(e){return r(0===(this.negative|e.negative)),this.iuxor(e)},s.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},s.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},s.prototype.inotn=function(e){r("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),i=e%26;this._expand(t),i>0&&t--;for(var n=0;n<t;n++)this.words[n]=67108863&~this.words[n];return i>0&&(this.words[n]=~this.words[n]&67108863>>26-i),this.strip()},s.prototype.notn=function(e){return this.clone().inotn(e)},s.prototype.setn=function(e,t){r("number"==typeof e&&e>=0);var i=e/26|0,n=e%26;return this._expand(i+1),this.words[i]=t?this.words[i]|1<<n:this.words[i]&~(1<<n),this.strip()},s.prototype.iadd=function(e){var t,i,r;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(i=this,r=e):(i=e,r=this);for(var n=0,s=0;s<r.length;s++)t=(0|i.words[s])+(0|r.words[s])+n,this.words[s]=67108863&t,n=t>>>26;for(;0!==n&&s<i.length;s++)t=(0|i.words[s])+n,this.words[s]=67108863&t,n=t>>>26;if(this.length=i.length,0!==n)this.words[this.length]=n,this.length++;else if(i!==this)for(;s<i.length;s++)this.words[s]=i.words[s];return this},s.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},s.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var i,r,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(i=this,r=e):(i=e,r=this);for(var s=0,o=0;o<r.length;o++)s=(t=(0|i.words[o])-(0|r.words[o])+s)>>26,this.words[o]=67108863&t;for(;0!==s&&o<i.length;o++)s=(t=(0|i.words[o])+s)>>26,this.words[o]=67108863&t;if(0===s&&o<i.length&&i!==this)for(;o<i.length;o++)this.words[o]=i.words[o];return this.length=Math.max(this.length,o),i!==this&&(this.negative=1),this.strip()},s.prototype.sub=function(e){return this.clone().isub(e)};var g=function(e,t,i){var r,n,s,o=e.words,a=t.words,l=i.words,c=0,u=0|o[0],h=8191&u,d=u>>>13,p=0|o[1],g=8191&p,f=p>>>13,m=0|o[2],v=8191&m,C=m>>>13,y=0|o[3],w=8191&y,S=y>>>13,b=0|o[4],E=8191&b,A=b>>>13,T=0|o[5],M=8191&T,R=T>>>13,_=0|o[6],P=8191&_,x=_>>>13,D=0|o[7],I=8191&D,L=D>>>13,N=0|o[8],O=8191&N,F=N>>>13,k=0|o[9],G=8191&k,V=k>>>13,H=0|a[0],B=8191&H,z=H>>>13,U=0|a[1],W=8191&U,j=U>>>13,K=0|a[2],$=8191&K,q=K>>>13,Y=0|a[3],Q=8191&Y,X=Y>>>13,Z=0|a[4],J=8191&Z,ee=Z>>>13,te=0|a[5],ie=8191&te,re=te>>>13,ne=0|a[6],se=8191&ne,oe=ne>>>13,ae=0|a[7],le=8191&ae,ce=ae>>>13,ue=0|a[8],he=8191&ue,de=ue>>>13,pe=0|a[9],ge=8191&pe,fe=pe>>>13;i.negative=e.negative^t.negative,i.length=19;var me=(c+(r=Math.imul(h,B))|0)+((8191&(n=(n=Math.imul(h,z))+Math.imul(d,B)|0))<<13)|0;c=((s=Math.imul(d,z))+(n>>>13)|0)+(me>>>26)|0,me&=67108863,r=Math.imul(g,B),n=(n=Math.imul(g,z))+Math.imul(f,B)|0,s=Math.imul(f,z);var ve=(c+(r=r+Math.imul(h,W)|0)|0)+((8191&(n=(n=n+Math.imul(h,j)|0)+Math.imul(d,W)|0))<<13)|0;c=((s=s+Math.imul(d,j)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,r=Math.imul(v,B),n=(n=Math.imul(v,z))+Math.imul(C,B)|0,s=Math.imul(C,z),r=r+Math.imul(g,W)|0,n=(n=n+Math.imul(g,j)|0)+Math.imul(f,W)|0,s=s+Math.imul(f,j)|0;var Ce=(c+(r=r+Math.imul(h,$)|0)|0)+((8191&(n=(n=n+Math.imul(h,q)|0)+Math.imul(d,$)|0))<<13)|0;c=((s=s+Math.imul(d,q)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,r=Math.imul(w,B),n=(n=Math.imul(w,z))+Math.imul(S,B)|0,s=Math.imul(S,z),r=r+Math.imul(v,W)|0,n=(n=n+Math.imul(v,j)|0)+Math.imul(C,W)|0,s=s+Math.imul(C,j)|0,r=r+Math.imul(g,$)|0,n=(n=n+Math.imul(g,q)|0)+Math.imul(f,$)|0,s=s+Math.imul(f,q)|0;var ye=(c+(r=r+Math.imul(h,Q)|0)|0)+((8191&(n=(n=n+Math.imul(h,X)|0)+Math.imul(d,Q)|0))<<13)|0;c=((s=s+Math.imul(d,X)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,r=Math.imul(E,B),n=(n=Math.imul(E,z))+Math.imul(A,B)|0,s=Math.imul(A,z),r=r+Math.imul(w,W)|0,n=(n=n+Math.imul(w,j)|0)+Math.imul(S,W)|0,s=s+Math.imul(S,j)|0,r=r+Math.imul(v,$)|0,n=(n=n+Math.imul(v,q)|0)+Math.imul(C,$)|0,s=s+Math.imul(C,q)|0,r=r+Math.imul(g,Q)|0,n=(n=n+Math.imul(g,X)|0)+Math.imul(f,Q)|0,s=s+Math.imul(f,X)|0;var we=(c+(r=r+Math.imul(h,J)|0)|0)+((8191&(n=(n=n+Math.imul(h,ee)|0)+Math.imul(d,J)|0))<<13)|0;c=((s=s+Math.imul(d,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,r=Math.imul(M,B),n=(n=Math.imul(M,z))+Math.imul(R,B)|0,s=Math.imul(R,z),r=r+Math.imul(E,W)|0,n=(n=n+Math.imul(E,j)|0)+Math.imul(A,W)|0,s=s+Math.imul(A,j)|0,r=r+Math.imul(w,$)|0,n=(n=n+Math.imul(w,q)|0)+Math.imul(S,$)|0,s=s+Math.imul(S,q)|0,r=r+Math.imul(v,Q)|0,n=(n=n+Math.imul(v,X)|0)+Math.imul(C,Q)|0,s=s+Math.imul(C,X)|0,r=r+Math.imul(g,J)|0,n=(n=n+Math.imul(g,ee)|0)+Math.imul(f,J)|0,s=s+Math.imul(f,ee)|0;var Se=(c+(r=r+Math.imul(h,ie)|0)|0)+((8191&(n=(n=n+Math.imul(h,re)|0)+Math.imul(d,ie)|0))<<13)|0;c=((s=s+Math.imul(d,re)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,r=Math.imul(P,B),n=(n=Math.imul(P,z))+Math.imul(x,B)|0,s=Math.imul(x,z),r=r+Math.imul(M,W)|0,n=(n=n+Math.imul(M,j)|0)+Math.imul(R,W)|0,s=s+Math.imul(R,j)|0,r=r+Math.imul(E,$)|0,n=(n=n+Math.imul(E,q)|0)+Math.imul(A,$)|0,s=s+Math.imul(A,q)|0,r=r+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,X)|0)+Math.imul(S,Q)|0,s=s+Math.imul(S,X)|0,r=r+Math.imul(v,J)|0,n=(n=n+Math.imul(v,ee)|0)+Math.imul(C,J)|0,s=s+Math.imul(C,ee)|0,r=r+Math.imul(g,ie)|0,n=(n=n+Math.imul(g,re)|0)+Math.imul(f,ie)|0,s=s+Math.imul(f,re)|0;var be=(c+(r=r+Math.imul(h,se)|0)|0)+((8191&(n=(n=n+Math.imul(h,oe)|0)+Math.imul(d,se)|0))<<13)|0;c=((s=s+Math.imul(d,oe)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,r=Math.imul(I,B),n=(n=Math.imul(I,z))+Math.imul(L,B)|0,s=Math.imul(L,z),r=r+Math.imul(P,W)|0,n=(n=n+Math.imul(P,j)|0)+Math.imul(x,W)|0,s=s+Math.imul(x,j)|0,r=r+Math.imul(M,$)|0,n=(n=n+Math.imul(M,q)|0)+Math.imul(R,$)|0,s=s+Math.imul(R,q)|0,r=r+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,X)|0)+Math.imul(A,Q)|0,s=s+Math.imul(A,X)|0,r=r+Math.imul(w,J)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(S,J)|0,s=s+Math.imul(S,ee)|0,r=r+Math.imul(v,ie)|0,n=(n=n+Math.imul(v,re)|0)+Math.imul(C,ie)|0,s=s+Math.imul(C,re)|0,r=r+Math.imul(g,se)|0,n=(n=n+Math.imul(g,oe)|0)+Math.imul(f,se)|0,s=s+Math.imul(f,oe)|0;var Ee=(c+(r=r+Math.imul(h,le)|0)|0)+((8191&(n=(n=n+Math.imul(h,ce)|0)+Math.imul(d,le)|0))<<13)|0;c=((s=s+Math.imul(d,ce)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,r=Math.imul(O,B),n=(n=Math.imul(O,z))+Math.imul(F,B)|0,s=Math.imul(F,z),r=r+Math.imul(I,W)|0,n=(n=n+Math.imul(I,j)|0)+Math.imul(L,W)|0,s=s+Math.imul(L,j)|0,r=r+Math.imul(P,$)|0,n=(n=n+Math.imul(P,q)|0)+Math.imul(x,$)|0,s=s+Math.imul(x,q)|0,r=r+Math.imul(M,Q)|0,n=(n=n+Math.imul(M,X)|0)+Math.imul(R,Q)|0,s=s+Math.imul(R,X)|0,r=r+Math.imul(E,J)|0,n=(n=n+Math.imul(E,ee)|0)+Math.imul(A,J)|0,s=s+Math.imul(A,ee)|0,r=r+Math.imul(w,ie)|0,n=(n=n+Math.imul(w,re)|0)+Math.imul(S,ie)|0,s=s+Math.imul(S,re)|0,r=r+Math.imul(v,se)|0,n=(n=n+Math.imul(v,oe)|0)+Math.imul(C,se)|0,s=s+Math.imul(C,oe)|0,r=r+Math.imul(g,le)|0,n=(n=n+Math.imul(g,ce)|0)+Math.imul(f,le)|0,s=s+Math.imul(f,ce)|0;var Ae=(c+(r=r+Math.imul(h,he)|0)|0)+((8191&(n=(n=n+Math.imul(h,de)|0)+Math.imul(d,he)|0))<<13)|0;c=((s=s+Math.imul(d,de)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,r=Math.imul(G,B),n=(n=Math.imul(G,z))+Math.imul(V,B)|0,s=Math.imul(V,z),r=r+Math.imul(O,W)|0,n=(n=n+Math.imul(O,j)|0)+Math.imul(F,W)|0,s=s+Math.imul(F,j)|0,r=r+Math.imul(I,$)|0,n=(n=n+Math.imul(I,q)|0)+Math.imul(L,$)|0,s=s+Math.imul(L,q)|0,r=r+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,X)|0)+Math.imul(x,Q)|0,s=s+Math.imul(x,X)|0,r=r+Math.imul(M,J)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(R,J)|0,s=s+Math.imul(R,ee)|0,r=r+Math.imul(E,ie)|0,n=(n=n+Math.imul(E,re)|0)+Math.imul(A,ie)|0,s=s+Math.imul(A,re)|0,r=r+Math.imul(w,se)|0,n=(n=n+Math.imul(w,oe)|0)+Math.imul(S,se)|0,s=s+Math.imul(S,oe)|0,r=r+Math.imul(v,le)|0,n=(n=n+Math.imul(v,ce)|0)+Math.imul(C,le)|0,s=s+Math.imul(C,ce)|0,r=r+Math.imul(g,he)|0,n=(n=n+Math.imul(g,de)|0)+Math.imul(f,he)|0,s=s+Math.imul(f,de)|0;var Te=(c+(r=r+Math.imul(h,ge)|0)|0)+((8191&(n=(n=n+Math.imul(h,fe)|0)+Math.imul(d,ge)|0))<<13)|0;c=((s=s+Math.imul(d,fe)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,r=Math.imul(G,W),n=(n=Math.imul(G,j))+Math.imul(V,W)|0,s=Math.imul(V,j),r=r+Math.imul(O,$)|0,n=(n=n+Math.imul(O,q)|0)+Math.imul(F,$)|0,s=s+Math.imul(F,q)|0,r=r+Math.imul(I,Q)|0,n=(n=n+Math.imul(I,X)|0)+Math.imul(L,Q)|0,s=s+Math.imul(L,X)|0,r=r+Math.imul(P,J)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(x,J)|0,s=s+Math.imul(x,ee)|0,r=r+Math.imul(M,ie)|0,n=(n=n+Math.imul(M,re)|0)+Math.imul(R,ie)|0,s=s+Math.imul(R,re)|0,r=r+Math.imul(E,se)|0,n=(n=n+Math.imul(E,oe)|0)+Math.imul(A,se)|0,s=s+Math.imul(A,oe)|0,r=r+Math.imul(w,le)|0,n=(n=n+Math.imul(w,ce)|0)+Math.imul(S,le)|0,s=s+Math.imul(S,ce)|0,r=r+Math.imul(v,he)|0,n=(n=n+Math.imul(v,de)|0)+Math.imul(C,he)|0,s=s+Math.imul(C,de)|0;var Me=(c+(r=r+Math.imul(g,ge)|0)|0)+((8191&(n=(n=n+Math.imul(g,fe)|0)+Math.imul(f,ge)|0))<<13)|0;c=((s=s+Math.imul(f,fe)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,r=Math.imul(G,$),n=(n=Math.imul(G,q))+Math.imul(V,$)|0,s=Math.imul(V,q),r=r+Math.imul(O,Q)|0,n=(n=n+Math.imul(O,X)|0)+Math.imul(F,Q)|0,s=s+Math.imul(F,X)|0,r=r+Math.imul(I,J)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(L,J)|0,s=s+Math.imul(L,ee)|0,r=r+Math.imul(P,ie)|0,n=(n=n+Math.imul(P,re)|0)+Math.imul(x,ie)|0,s=s+Math.imul(x,re)|0,r=r+Math.imul(M,se)|0,n=(n=n+Math.imul(M,oe)|0)+Math.imul(R,se)|0,s=s+Math.imul(R,oe)|0,r=r+Math.imul(E,le)|0,n=(n=n+Math.imul(E,ce)|0)+Math.imul(A,le)|0,s=s+Math.imul(A,ce)|0,r=r+Math.imul(w,he)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(S,he)|0,s=s+Math.imul(S,de)|0;var Re=(c+(r=r+Math.imul(v,ge)|0)|0)+((8191&(n=(n=n+Math.imul(v,fe)|0)+Math.imul(C,ge)|0))<<13)|0;c=((s=s+Math.imul(C,fe)|0)+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,r=Math.imul(G,Q),n=(n=Math.imul(G,X))+Math.imul(V,Q)|0,s=Math.imul(V,X),r=r+Math.imul(O,J)|0,n=(n=n+Math.imul(O,ee)|0)+Math.imul(F,J)|0,s=s+Math.imul(F,ee)|0,r=r+Math.imul(I,ie)|0,n=(n=n+Math.imul(I,re)|0)+Math.imul(L,ie)|0,s=s+Math.imul(L,re)|0,r=r+Math.imul(P,se)|0,n=(n=n+Math.imul(P,oe)|0)+Math.imul(x,se)|0,s=s+Math.imul(x,oe)|0,r=r+Math.imul(M,le)|0,n=(n=n+Math.imul(M,ce)|0)+Math.imul(R,le)|0,s=s+Math.imul(R,ce)|0,r=r+Math.imul(E,he)|0,n=(n=n+Math.imul(E,de)|0)+Math.imul(A,he)|0,s=s+Math.imul(A,de)|0;var _e=(c+(r=r+Math.imul(w,ge)|0)|0)+((8191&(n=(n=n+Math.imul(w,fe)|0)+Math.imul(S,ge)|0))<<13)|0;c=((s=s+Math.imul(S,fe)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,r=Math.imul(G,J),n=(n=Math.imul(G,ee))+Math.imul(V,J)|0,s=Math.imul(V,ee),r=r+Math.imul(O,ie)|0,n=(n=n+Math.imul(O,re)|0)+Math.imul(F,ie)|0,s=s+Math.imul(F,re)|0,r=r+Math.imul(I,se)|0,n=(n=n+Math.imul(I,oe)|0)+Math.imul(L,se)|0,s=s+Math.imul(L,oe)|0,r=r+Math.imul(P,le)|0,n=(n=n+Math.imul(P,ce)|0)+Math.imul(x,le)|0,s=s+Math.imul(x,ce)|0,r=r+Math.imul(M,he)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(R,he)|0,s=s+Math.imul(R,de)|0;var Pe=(c+(r=r+Math.imul(E,ge)|0)|0)+((8191&(n=(n=n+Math.imul(E,fe)|0)+Math.imul(A,ge)|0))<<13)|0;c=((s=s+Math.imul(A,fe)|0)+(n>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,r=Math.imul(G,ie),n=(n=Math.imul(G,re))+Math.imul(V,ie)|0,s=Math.imul(V,re),r=r+Math.imul(O,se)|0,n=(n=n+Math.imul(O,oe)|0)+Math.imul(F,se)|0,s=s+Math.imul(F,oe)|0,r=r+Math.imul(I,le)|0,n=(n=n+Math.imul(I,ce)|0)+Math.imul(L,le)|0,s=s+Math.imul(L,ce)|0,r=r+Math.imul(P,he)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(x,he)|0,s=s+Math.imul(x,de)|0;var xe=(c+(r=r+Math.imul(M,ge)|0)|0)+((8191&(n=(n=n+Math.imul(M,fe)|0)+Math.imul(R,ge)|0))<<13)|0;c=((s=s+Math.imul(R,fe)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,r=Math.imul(G,se),n=(n=Math.imul(G,oe))+Math.imul(V,se)|0,s=Math.imul(V,oe),r=r+Math.imul(O,le)|0,n=(n=n+Math.imul(O,ce)|0)+Math.imul(F,le)|0,s=s+Math.imul(F,ce)|0,r=r+Math.imul(I,he)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(L,he)|0,s=s+Math.imul(L,de)|0;var De=(c+(r=r+Math.imul(P,ge)|0)|0)+((8191&(n=(n=n+Math.imul(P,fe)|0)+Math.imul(x,ge)|0))<<13)|0;c=((s=s+Math.imul(x,fe)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863,r=Math.imul(G,le),n=(n=Math.imul(G,ce))+Math.imul(V,le)|0,s=Math.imul(V,ce),r=r+Math.imul(O,he)|0,n=(n=n+Math.imul(O,de)|0)+Math.imul(F,he)|0,s=s+Math.imul(F,de)|0;var Ie=(c+(r=r+Math.imul(I,ge)|0)|0)+((8191&(n=(n=n+Math.imul(I,fe)|0)+Math.imul(L,ge)|0))<<13)|0;c=((s=s+Math.imul(L,fe)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,r=Math.imul(G,he),n=(n=Math.imul(G,de))+Math.imul(V,he)|0,s=Math.imul(V,de);var Le=(c+(r=r+Math.imul(O,ge)|0)|0)+((8191&(n=(n=n+Math.imul(O,fe)|0)+Math.imul(F,ge)|0))<<13)|0;c=((s=s+Math.imul(F,fe)|0)+(n>>>13)|0)+(Le>>>26)|0,Le&=67108863;var Ne=(c+(r=Math.imul(G,ge))|0)+((8191&(n=(n=Math.imul(G,fe))+Math.imul(V,ge)|0))<<13)|0;return c=((s=Math.imul(V,fe))+(n>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,l[0]=me,l[1]=ve,l[2]=Ce,l[3]=ye,l[4]=we,l[5]=Se,l[6]=be,l[7]=Ee,l[8]=Ae,l[9]=Te,l[10]=Me,l[11]=Re,l[12]=_e,l[13]=Pe,l[14]=xe,l[15]=De,l[16]=Ie,l[17]=Le,l[18]=Ne,0!==c&&(l[19]=c,i.length++),i};function f(e,t,i){return(new m).mulp(e,t,i)}function m(e,t){this.x=e,this.y=t}Math.imul||(g=p),s.prototype.mulTo=function(e,t){var i,r=this.length+e.length;return i=10===this.length&&10===e.length?g(this,e,t):r<63?p(this,e,t):r<1024?function(e,t,i){i.negative=t.negative^e.negative,i.length=e.length+t.length;for(var r=0,n=0,s=0;s<i.length-1;s++){var o=n;n=0;for(var a=67108863&r,l=Math.min(s,t.length-1),c=Math.max(0,s-e.length+1);c<=l;c++){var u=s-c,h=(0|e.words[u])*(0|t.words[c]),d=67108863&h;a=67108863&(d=d+a|0),n+=(o=(o=o+(h/67108864|0)|0)+(d>>>26)|0)>>>26,o&=67108863}i.words[s]=a,r=o,o=n}return 0!==r?i.words[s]=r:i.length--,i.strip()}(this,e,t):f(this,e,t),i},m.prototype.makeRBT=function(e){for(var t=new Array(e),i=s.prototype._countBits(e)-1,r=0;r<e;r++)t[r]=this.revBin(r,i,e);return t},m.prototype.revBin=function(e,t,i){if(0===e||e===i-1)return e;for(var r=0,n=0;n<t;n++)r|=(1&e)<<t-n-1,e>>=1;return r},m.prototype.permute=function(e,t,i,r,n,s){for(var o=0;o<s;o++)r[o]=t[e[o]],n[o]=i[e[o]]},m.prototype.transform=function(e,t,i,r,n,s){this.permute(s,e,t,i,r,n);for(var o=1;o<n;o<<=1)for(var a=o<<1,l=Math.cos(2*Math.PI/a),c=Math.sin(2*Math.PI/a),u=0;u<n;u+=a)for(var h=l,d=c,p=0;p<o;p++){var g=i[u+p],f=r[u+p],m=i[u+p+o],v=r[u+p+o],C=h*m-d*v;v=h*v+d*m,m=C,i[u+p]=g+m,r[u+p]=f+v,i[u+p+o]=g-m,r[u+p+o]=f-v,p!==a&&(C=l*h-c*d,d=l*d+c*h,h=C)}},m.prototype.guessLen13b=function(e,t){var i=1|Math.max(t,e),r=1&i,n=0;for(i=i/2|0;i;i>>>=1)n++;return 1<<n+1+r},m.prototype.conjugate=function(e,t,i){if(!(i<=1))for(var r=0;r<i/2;r++){var n=e[r];e[r]=e[i-r-1],e[i-r-1]=n,n=t[r],t[r]=-t[i-r-1],t[i-r-1]=-n}},m.prototype.normalize13b=function(e,t){for(var i=0,r=0;r<t/2;r++){var n=8192*Math.round(e[2*r+1]/t)+Math.round(e[2*r]/t)+i;e[r]=67108863&n,i=n<67108864?0:n/67108864|0}return e},m.prototype.convert13b=function(e,t,i,n){for(var s=0,o=0;o<t;o++)s+=0|e[o],i[2*o]=8191&s,s>>>=13,i[2*o+1]=8191&s,s>>>=13;for(o=2*t;o<n;++o)i[o]=0;r(0===s),r(!(-8192&s))},m.prototype.stub=function(e){for(var t=new Array(e),i=0;i<e;i++)t[i]=0;return t},m.prototype.mulp=function(e,t,i){var r=2*this.guessLen13b(e.length,t.length),n=this.makeRBT(r),s=this.stub(r),o=new Array(r),a=new Array(r),l=new Array(r),c=new Array(r),u=new Array(r),h=new Array(r),d=i.words;d.length=r,this.convert13b(e.words,e.length,o,r),this.convert13b(t.words,t.length,c,r),this.transform(o,s,a,l,r,n),this.transform(c,s,u,h,r,n);for(var p=0;p<r;p++){var g=a[p]*u[p]-l[p]*h[p];l[p]=a[p]*h[p]+l[p]*u[p],a[p]=g}return this.conjugate(a,l,r),this.transform(a,l,d,s,r,n),this.conjugate(d,s,r),this.normalize13b(d,r),i.negative=e.negative^t.negative,i.length=e.length+t.length,i.strip()},s.prototype.mul=function(e){var t=new s(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},s.prototype.mulf=function(e){var t=new s(null);return t.words=new Array(this.length+e.length),f(this,e,t)},s.prototype.imul=function(e){return this.clone().mulTo(e,this)},s.prototype.imuln=function(e){r("number"==typeof e),r(e<67108864);for(var t=0,i=0;i<this.length;i++){var n=(0|this.words[i])*e,s=(67108863&n)+(67108863&t);t>>=26,t+=n/67108864|0,t+=s>>>26,this.words[i]=67108863&s}return 0!==t&&(this.words[i]=t,this.length++),this.length=0===e?1:this.length,this},s.prototype.muln=function(e){return this.clone().imuln(e)},s.prototype.sqr=function(){return this.mul(this)},s.prototype.isqr=function(){return this.imul(this.clone())},s.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),i=0;i<t.length;i++){var r=i/26|0,n=i%26;t[i]=(e.words[r]&1<<n)>>>n}return t}(e);if(0===t.length)return new s(1);for(var i=this,r=0;r<t.length&&0===t[r];r++,i=i.sqr());if(++r<t.length)for(var n=i.sqr();r<t.length;r++,n=n.sqr())0!==t[r]&&(i=i.mul(n));return i},s.prototype.iushln=function(e){r("number"==typeof e&&e>=0);var t,i=e%26,n=(e-i)/26,s=67108863>>>26-i<<26-i;if(0!==i){var o=0;for(t=0;t<this.length;t++){var a=this.words[t]&s,l=(0|this.words[t])-a<<i;this.words[t]=l|o,o=a>>>26-i}o&&(this.words[t]=o,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t<n;t++)this.words[t]=0;this.length+=n}return this.strip()},s.prototype.ishln=function(e){return r(0===this.negative),this.iushln(e)},s.prototype.iushrn=function(e,t,i){var n;r("number"==typeof e&&e>=0),n=t?(t-t%26)/26:0;var s=e%26,o=Math.min((e-s)/26,this.length),a=67108863^67108863>>>s<<s,l=i;if(n-=o,n=Math.max(0,n),l){for(var c=0;c<o;c++)l.words[c]=this.words[c];l.length=o}if(0===o);else if(this.length>o)for(this.length-=o,c=0;c<this.length;c++)this.words[c]=this.words[c+o];else this.words[0]=0,this.length=1;var u=0;for(c=this.length-1;c>=0&&(0!==u||c>=n);c--){var h=0|this.words[c];this.words[c]=u<<26-s|h>>>s,u=h&a}return l&&0!==u&&(l.words[l.length++]=u),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},s.prototype.ishrn=function(e,t,i){return r(0===this.negative),this.iushrn(e,t,i)},s.prototype.shln=function(e){return this.clone().ishln(e)},s.prototype.ushln=function(e){return this.clone().iushln(e)},s.prototype.shrn=function(e){return this.clone().ishrn(e)},s.prototype.ushrn=function(e){return this.clone().iushrn(e)},s.prototype.testn=function(e){r("number"==typeof e&&e>=0);var t=e%26,i=(e-t)/26,n=1<<t;return!(this.length<=i||!(this.words[i]&n))},s.prototype.imaskn=function(e){r("number"==typeof e&&e>=0);var t=e%26,i=(e-t)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=i)return this;if(0!==t&&i++,this.length=Math.min(i,this.length),0!==t){var n=67108863^67108863>>>t<<t;this.words[this.length-1]&=n}return 0===this.length&&(this.words[0]=0,this.length=1),this.strip()},s.prototype.maskn=function(e){return this.clone().imaskn(e)},s.prototype.iaddn=function(e){return r("number"==typeof e),r(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},s.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},s.prototype.isubn=function(e){if(r("number"==typeof e),r(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this.strip()},s.prototype.addn=function(e){return this.clone().iaddn(e)},s.prototype.subn=function(e){return this.clone().isubn(e)},s.prototype.iabs=function(){return this.negative=0,this},s.prototype.abs=function(){return this.clone().iabs()},s.prototype._ishlnsubmul=function(e,t,i){var n,s,o=e.length+i;this._expand(o);var a=0;for(n=0;n<e.length;n++){s=(0|this.words[n+i])+a;var l=(0|e.words[n])*t;a=((s-=67108863&l)>>26)-(l/67108864|0),this.words[n+i]=67108863&s}for(;n<this.length-i;n++)a=(s=(0|this.words[n+i])+a)>>26,this.words[n+i]=67108863&s;if(0===a)return this.strip();for(r(-1===a),a=0,n=0;n<this.length;n++)a=(s=-(0|this.words[n])+a)>>26,this.words[n]=67108863&s;return this.negative=1,this.strip()},s.prototype._wordDiv=function(e,t){var i=(this.length,e.length),r=this.clone(),n=e,o=0|n.words[n.length-1];0!=(i=26-this._countBits(o))&&(n=n.ushln(i),r.iushln(i),o=0|n.words[n.length-1]);var a,l=r.length-n.length;if("mod"!==t){(a=new s(null)).length=l+1,a.words=new Array(a.length);for(var c=0;c<a.length;c++)a.words[c]=0}var u=r.clone()._ishlnsubmul(n,1,l);0===u.negative&&(r=u,a&&(a.words[l]=1));for(var h=l-1;h>=0;h--){var d=67108864*(0|r.words[n.length+h])+(0|r.words[n.length+h-1]);for(d=Math.min(d/o|0,67108863),r._ishlnsubmul(n,d,h);0!==r.negative;)d--,r.negative=0,r._ishlnsubmul(n,1,h),r.isZero()||(r.negative^=1);a&&(a.words[h]=d)}return a&&a.strip(),r.strip(),"div"!==t&&0!==i&&r.iushrn(i),{div:a||null,mod:r}},s.prototype.divmod=function(e,t,i){return r(!e.isZero()),this.isZero()?{div:new s(0),mod:new s(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(o=a.mod.neg(),i&&0!==o.negative&&o.iadd(e)),{div:n,mod:o}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):0!==(this.negative&e.negative)?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(o=a.mod.neg(),i&&0!==o.negative&&o.isub(e)),{div:a.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new s(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new s(this.modn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new s(this.modn(e.words[0]))}:this._wordDiv(e,t);var n,o,a},s.prototype.div=function(e){return this.divmod(e,"div",!1).div},s.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},s.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},s.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var i=0!==t.div.negative?t.mod.isub(e):t.mod,r=e.ushrn(1),n=e.andln(1),s=i.cmp(r);return s<0||1===n&&0===s?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},s.prototype.modn=function(e){r(e<=67108863);for(var t=(1<<26)%e,i=0,n=this.length-1;n>=0;n--)i=(t*i+(0|this.words[n]))%e;return i},s.prototype.idivn=function(e){r(e<=67108863);for(var t=0,i=this.length-1;i>=0;i--){var n=(0|this.words[i])+67108864*t;this.words[i]=n/e|0,t=n%e}return this.strip()},s.prototype.divn=function(e){return this.clone().idivn(e)},s.prototype.egcd=function(e){r(0===e.negative),r(!e.isZero());var t=this,i=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new s(1),o=new s(0),a=new s(0),l=new s(1),c=0;t.isEven()&&i.isEven();)t.iushrn(1),i.iushrn(1),++c;for(var u=i.clone(),h=t.clone();!t.isZero();){for(var d=0,p=1;0===(t.words[0]&p)&&d<26;++d,p<<=1);if(d>0)for(t.iushrn(d);d-- >0;)(n.isOdd()||o.isOdd())&&(n.iadd(u),o.isub(h)),n.iushrn(1),o.iushrn(1);for(var g=0,f=1;0===(i.words[0]&f)&&g<26;++g,f<<=1);if(g>0)for(i.iushrn(g);g-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(u),l.isub(h)),a.iushrn(1),l.iushrn(1);t.cmp(i)>=0?(t.isub(i),n.isub(a),o.isub(l)):(i.isub(t),a.isub(n),l.isub(o))}return{a,b:l,gcd:i.iushln(c)}},s.prototype._invmp=function(e){r(0===e.negative),r(!e.isZero());var t=this,i=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,o=new s(1),a=new s(0),l=i.clone();t.cmpn(1)>0&&i.cmpn(1)>0;){for(var c=0,u=1;0===(t.words[0]&u)&&c<26;++c,u<<=1);if(c>0)for(t.iushrn(c);c-- >0;)o.isOdd()&&o.iadd(l),o.iushrn(1);for(var h=0,d=1;0===(i.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(i.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(i)>=0?(t.isub(i),o.isub(a)):(i.isub(t),a.isub(o))}return(n=0===t.cmpn(1)?o:a).cmpn(0)<0&&n.iadd(e),n},s.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),i=e.clone();t.negative=0,i.negative=0;for(var r=0;t.isEven()&&i.isEven();r++)t.iushrn(1),i.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;i.isEven();)i.iushrn(1);var n=t.cmp(i);if(n<0){var s=t;t=i,i=s}else if(0===n||0===i.cmpn(1))break;t.isub(i)}return i.iushln(r)},s.prototype.invm=function(e){return this.egcd(e).a.umod(e)},s.prototype.isEven=function(){return!(1&this.words[0])},s.prototype.isOdd=function(){return!(1&~this.words[0])},s.prototype.andln=function(e){return this.words[0]&e},s.prototype.bincn=function(e){r("number"==typeof e);var t=e%26,i=(e-t)/26,n=1<<t;if(this.length<=i)return this._expand(i+1),this.words[i]|=n,this;for(var s=n,o=i;0!==s&&o<this.length;o++){var a=0|this.words[o];s=(a+=s)>>>26,a&=67108863,this.words[o]=a}return 0!==s&&(this.words[o]=s,this.length++),this},s.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},s.prototype.cmpn=function(e){var t,i=e<0;if(0!==this.negative&&!i)return-1;if(0===this.negative&&i)return 1;if(this.strip(),this.length>1)t=1;else{i&&(e=-e),r(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:n<e?-1:1}return 0!==this.negative?0|-t:t},s.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},s.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,i=this.length-1;i>=0;i--){var r=0|this.words[i],n=0|e.words[i];if(r!==n){r<n?t=-1:r>n&&(t=1);break}}return t},s.prototype.gtn=function(e){return 1===this.cmpn(e)},s.prototype.gt=function(e){return 1===this.cmp(e)},s.prototype.gten=function(e){return this.cmpn(e)>=0},s.prototype.gte=function(e){return this.cmp(e)>=0},s.prototype.ltn=function(e){return-1===this.cmpn(e)},s.prototype.lt=function(e){return-1===this.cmp(e)},s.prototype.lten=function(e){return this.cmpn(e)<=0},s.prototype.lte=function(e){return this.cmp(e)<=0},s.prototype.eqn=function(e){return 0===this.cmpn(e)},s.prototype.eq=function(e){return 0===this.cmp(e)},s.red=function(e){return new E(e)},s.prototype.toRed=function(e){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},s.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},s.prototype._forceRed=function(e){return this.red=e,this},s.prototype.forceRed=function(e){return r(!this.red,"Already a number in reduction context"),this._forceRed(e)},s.prototype.redAdd=function(e){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},s.prototype.redIAdd=function(e){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},s.prototype.redSub=function(e){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},s.prototype.redISub=function(e){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},s.prototype.redShl=function(e){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},s.prototype.redMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},s.prototype.redIMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},s.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},s.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},s.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},s.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},s.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},s.prototype.redPow=function(e){return r(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var v={k256:null,p224:null,p192:null,p25519:null};function C(e,t){this.name=e,this.p=new s(t,16),this.n=this.p.bitLength(),this.k=new s(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function y(){C.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function w(){C.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function S(){C.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function b(){C.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function E(e){if("string"==typeof e){var t=s._prime(e);this.m=t.p,this.prime=t}else r(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function A(e){E.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new s(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}C.prototype._tmp=function(){var e=new s(null);return e.words=new Array(Math.ceil(this.n/13)),e},C.prototype.ireduce=function(e){var t,i=e;do{this.split(i,this.tmp),t=(i=(i=this.imulK(i)).iadd(this.tmp)).bitLength()}while(t>this.n);var r=t<this.n?-1:i.ucmp(this.p);return 0===r?(i.words[0]=0,i.length=1):r>0?i.isub(this.p):void 0!==i.strip?i.strip():i._strip(),i},C.prototype.split=function(e,t){e.iushrn(this.n,0,t)},C.prototype.imulK=function(e){return e.imul(this.k)},n(y,C),y.prototype.split=function(e,t){for(var i=4194303,r=Math.min(e.length,9),n=0;n<r;n++)t.words[n]=e.words[n];if(t.length=r,e.length<=9)return e.words[0]=0,void(e.length=1);var s=e.words[9];for(t.words[t.length++]=s&i,n=10;n<e.length;n++){var o=0|e.words[n];e.words[n-10]=(o&i)<<4|s>>>22,s=o}s>>>=22,e.words[n-10]=s,0===s&&e.length>10?e.length-=10:e.length-=9},y.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,i=0;i<e.length;i++){var r=0|e.words[i];t+=977*r,e.words[i]=67108863&t,t=64*r+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},n(w,C),n(S,C),n(b,C),b.prototype.imulK=function(e){for(var t=0,i=0;i<e.length;i++){var r=19*(0|e.words[i])+t,n=67108863&r;r>>>=26,e.words[i]=n,t=r}return 0!==t&&(e.words[e.length++]=t),e},s._prime=function(e){if(v[e])return v[e];var t;if("k256"===e)t=new y;else if("p224"===e)t=new w;else if("p192"===e)t=new S;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new b}return v[e]=t,t},E.prototype._verify1=function(e){r(0===e.negative,"red works only with positives"),r(e.red,"red works only with red numbers")},E.prototype._verify2=function(e,t){r(0===(e.negative|t.negative),"red works only with positives"),r(e.red&&e.red===t.red,"red works only with red numbers")},E.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):e.umod(this.m)._forceRed(this)},E.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},E.prototype.add=function(e,t){this._verify2(e,t);var i=e.add(t);return i.cmp(this.m)>=0&&i.isub(this.m),i._forceRed(this)},E.prototype.iadd=function(e,t){this._verify2(e,t);var i=e.iadd(t);return i.cmp(this.m)>=0&&i.isub(this.m),i},E.prototype.sub=function(e,t){this._verify2(e,t);var i=e.sub(t);return i.cmpn(0)<0&&i.iadd(this.m),i._forceRed(this)},E.prototype.isub=function(e,t){this._verify2(e,t);var i=e.isub(t);return i.cmpn(0)<0&&i.iadd(this.m),i},E.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},E.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},E.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},E.prototype.isqr=function(e){return this.imul(e,e.clone())},E.prototype.sqr=function(e){return this.mul(e,e)},E.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(r(t%2==1),3===t){var i=this.m.add(new s(1)).iushrn(2);return this.pow(e,i)}for(var n=this.m.subn(1),o=0;!n.isZero()&&0===n.andln(1);)o++,n.iushrn(1);r(!n.isZero());var a=new s(1).toRed(this),l=a.redNeg(),c=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new s(2*u*u).toRed(this);0!==this.pow(u,c).cmp(l);)u.redIAdd(l);for(var h=this.pow(u,n),d=this.pow(e,n.addn(1).iushrn(1)),p=this.pow(e,n),g=o;0!==p.cmp(a);){for(var f=p,m=0;0!==f.cmp(a);m++)f=f.redSqr();r(m<g);var v=this.pow(h,new s(1).iushln(g-m-1));d=d.redMul(v),h=v.redSqr(),p=p.redMul(h),g=m}return d},E.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},E.prototype.pow=function(e,t){if(t.isZero())return new s(1).toRed(this);if(0===t.cmpn(1))return e.clone();var i=new Array(16);i[0]=new s(1).toRed(this),i[1]=e;for(var r=2;r<i.length;r++)i[r]=this.mul(i[r-1],e);var n=i[0],o=0,a=0,l=t.bitLength()%26;for(0===l&&(l=26),r=t.length-1;r>=0;r--){for(var c=t.words[r],u=l-1;u>=0;u--){var h=c>>u&1;n!==i[0]&&(n=this.sqr(n)),0!==h||0!==o?(o<<=1,o|=h,(4===++a||0===r&&0===u)&&(n=this.mul(n,i[o]),a=0,o=0)):a=0}l=26}return n},E.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},E.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},s.mont=function(e){return new A(e)},n(A,E),A.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},A.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},A.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var i=e.imul(t),r=i.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=i.isub(r).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},A.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new s(0)._forceRed(this);var i=e.mul(t),r=i.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=i.isub(r).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},A.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=i.nmd(e),this)},39286(e,t,i){!function(e,t){"use strict";function r(e,t){if(!e)throw new Error(t||"Assertion failed")}function n(e,t){e.super_=t;var i=function(){};i.prototype=t.prototype,e.prototype=new i,e.prototype.constructor=e}function s(e,t,i){if(s.isBN(e))return e;this.negative=0,this.words=null,this.length=0,this.red=null,null!==e&&("le"!==t&&"be"!==t||(i=t,t=10),this._init(e||0,t||10,i||"be"))}var o;"object"==typeof e?e.exports=s:t.BN=s,s.BN=s,s.wordSize=26;try{o="undefined"!=typeof window&&void 0!==window.Buffer?window.Buffer:i(3308).Buffer}catch(e){}function a(e,t){var i=e.charCodeAt(t);return i>=48&&i<=57?i-48:i>=65&&i<=70?i-55:i>=97&&i<=102?i-87:void r(!1,"Invalid character in "+e)}function l(e,t,i){var r=a(e,i);return i-1>=t&&(r|=a(e,i-1)<<4),r}function c(e,t,i,n){for(var s=0,o=0,a=Math.min(e.length,i),l=t;l<a;l++){var c=e.charCodeAt(l)-48;s*=n,o=c>=49?c-49+10:c>=17?c-17+10:c,r(c>=0&&o<n,"Invalid character"),s+=o}return s}function u(e,t){e.words=t.words,e.length=t.length,e.negative=t.negative,e.red=t.red}if(s.isBN=function(e){return e instanceof s||null!==e&&"object"==typeof e&&e.constructor.wordSize===s.wordSize&&Array.isArray(e.words)},s.max=function(e,t){return e.cmp(t)>0?e:t},s.min=function(e,t){return e.cmp(t)<0?e:t},s.prototype._init=function(e,t,i){if("number"==typeof e)return this._initNumber(e,t,i);if("object"==typeof e)return this._initArray(e,t,i);"hex"===t&&(t=16),r(t===(0|t)&&t>=2&&t<=36);var n=0;"-"===(e=e.toString().replace(/\s+/g,""))[0]&&(n++,this.negative=1),n<e.length&&(16===t?this._parseHex(e,n,i):(this._parseBase(e,t,n),"le"===i&&this._initArray(this.toArray(),t,i)))},s.prototype._initNumber=function(e,t,i){e<0&&(this.negative=1,e=-e),e<67108864?(this.words=[67108863&e],this.length=1):e<4503599627370496?(this.words=[67108863&e,e/67108864&67108863],this.length=2):(r(e<9007199254740992),this.words=[67108863&e,e/67108864&67108863,1],this.length=3),"le"===i&&this._initArray(this.toArray(),t,i)},s.prototype._initArray=function(e,t,i){if(r("number"==typeof e.length),e.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(e.length/3),this.words=new Array(this.length);for(var n=0;n<this.length;n++)this.words[n]=0;var s,o,a=0;if("be"===i)for(n=e.length-1,s=0;n>=0;n-=3)o=e[n]|e[n-1]<<8|e[n-2]<<16,this.words[s]|=o<<a&67108863,this.words[s+1]=o>>>26-a&67108863,(a+=24)>=26&&(a-=26,s++);else if("le"===i)for(n=0,s=0;n<e.length;n+=3)o=e[n]|e[n+1]<<8|e[n+2]<<16,this.words[s]|=o<<a&67108863,this.words[s+1]=o>>>26-a&67108863,(a+=24)>=26&&(a-=26,s++);return this._strip()},s.prototype._parseHex=function(e,t,i){this.length=Math.ceil((e.length-t)/6),this.words=new Array(this.length);for(var r=0;r<this.length;r++)this.words[r]=0;var n,s=0,o=0;if("be"===i)for(r=e.length-1;r>=t;r-=2)n=l(e,t,r)<<s,this.words[o]|=67108863&n,s>=18?(s-=18,o+=1,this.words[o]|=n>>>26):s+=8;else for(r=(e.length-t)%2==0?t+1:t;r<e.length;r+=2)n=l(e,t,r)<<s,this.words[o]|=67108863&n,s>=18?(s-=18,o+=1,this.words[o]|=n>>>26):s+=8;this._strip()},s.prototype._parseBase=function(e,t,i){this.words=[0],this.length=1;for(var r=0,n=1;n<=67108863;n*=t)r++;r--,n=n/t|0;for(var s=e.length-i,o=s%r,a=Math.min(s,s-o)+i,l=0,u=i;u<a;u+=r)l=c(e,u,u+r,t),this.imuln(n),this.words[0]+l<67108864?this.words[0]+=l:this._iaddn(l);if(0!==o){var h=1;for(l=c(e,u,e.length,t),u=0;u<o;u++)h*=t;this.imuln(h),this.words[0]+l<67108864?this.words[0]+=l:this._iaddn(l)}this._strip()},s.prototype.copy=function(e){e.words=new Array(this.length);for(var t=0;t<this.length;t++)e.words[t]=this.words[t];e.length=this.length,e.negative=this.negative,e.red=this.red},s.prototype._move=function(e){u(e,this)},s.prototype.clone=function(){var e=new s(null);return this.copy(e),e},s.prototype._expand=function(e){for(;this.length<e;)this.words[this.length++]=0;return this},s.prototype._strip=function(){for(;this.length>1&&0===this.words[this.length-1];)this.length--;return this._normSign()},s.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for)try{s.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch(e){s.prototype.inspect=h}else s.prototype.inspect=h;function h(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var d=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],p=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],g=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function f(e,t,i){i.negative=t.negative^e.negative;var r=e.length+t.length|0;i.length=r,r=r-1|0;var n=0|e.words[0],s=0|t.words[0],o=n*s,a=67108863&o,l=o/67108864|0;i.words[0]=a;for(var c=1;c<r;c++){for(var u=l>>>26,h=67108863&l,d=Math.min(c,t.length-1),p=Math.max(0,c-e.length+1);p<=d;p++){var g=c-p|0;u+=(o=(n=0|e.words[g])*(s=0|t.words[p])+h)/67108864|0,h=67108863&o}i.words[c]=0|h,l=0|u}return 0!==l?i.words[c]=0|l:i.length--,i._strip()}s.prototype.toString=function(e,t){var i;if(t=0|t||1,16===(e=e||10)||"hex"===e){i="";for(var n=0,s=0,o=0;o<this.length;o++){var a=this.words[o],l=(16777215&(a<<n|s)).toString(16);s=a>>>24-n&16777215,(n+=2)>=26&&(n-=26,o--),i=0!==s||o!==this.length-1?d[6-l.length]+l+i:l+i}for(0!==s&&(i=s.toString(16)+i);i.length%t!==0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}if(e===(0|e)&&e>=2&&e<=36){var c=p[e],u=g[e];i="";var h=this.clone();for(h.negative=0;!h.isZero();){var f=h.modrn(u).toString(e);i=(h=h.idivn(u)).isZero()?f+i:d[c-f.length]+f+i}for(this.isZero()&&(i="0"+i);i.length%t!==0;)i="0"+i;return 0!==this.negative&&(i="-"+i),i}r(!1,"Base should be between 2 and 36")},s.prototype.toNumber=function(){var e=this.words[0];return 2===this.length?e+=67108864*this.words[1]:3===this.length&&1===this.words[2]?e+=4503599627370496+67108864*this.words[1]:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-e:e},s.prototype.toJSON=function(){return this.toString(16,2)},o&&(s.prototype.toBuffer=function(e,t){return this.toArrayLike(o,e,t)}),s.prototype.toArray=function(e,t){return this.toArrayLike(Array,e,t)},s.prototype.toArrayLike=function(e,t,i){this._strip();var n=this.byteLength(),s=i||Math.max(1,n);r(n<=s,"byte array longer than desired length"),r(s>0,"Requested array length <= 0");var o=function(e,t){return e.allocUnsafe?e.allocUnsafe(t):new e(t)}(e,s);return this["_toArrayLike"+("le"===t?"LE":"BE")](o,n),o},s.prototype._toArrayLikeLE=function(e,t){for(var i=0,r=0,n=0,s=0;n<this.length;n++){var o=this.words[n]<<s|r;e[i++]=255&o,i<e.length&&(e[i++]=o>>8&255),i<e.length&&(e[i++]=o>>16&255),6===s?(i<e.length&&(e[i++]=o>>24&255),r=0,s=0):(r=o>>>24,s+=2)}if(i<e.length)for(e[i++]=r;i<e.length;)e[i++]=0},s.prototype._toArrayLikeBE=function(e,t){for(var i=e.length-1,r=0,n=0,s=0;n<this.length;n++){var o=this.words[n]<<s|r;e[i--]=255&o,i>=0&&(e[i--]=o>>8&255),i>=0&&(e[i--]=o>>16&255),6===s?(i>=0&&(e[i--]=o>>24&255),r=0,s=0):(r=o>>>24,s+=2)}if(i>=0)for(e[i--]=r;i>=0;)e[i--]=0},Math.clz32?s.prototype._countBits=function(e){return 32-Math.clz32(e)}:s.prototype._countBits=function(e){var t=e,i=0;return t>=4096&&(i+=13,t>>>=13),t>=64&&(i+=7,t>>>=7),t>=8&&(i+=4,t>>>=4),t>=2&&(i+=2,t>>>=2),i+t},s.prototype._zeroBits=function(e){if(0===e)return 26;var t=e,i=0;return 8191&t||(i+=13,t>>>=13),127&t||(i+=7,t>>>=7),15&t||(i+=4,t>>>=4),3&t||(i+=2,t>>>=2),1&t||i++,i},s.prototype.bitLength=function(){var e=this.words[this.length-1],t=this._countBits(e);return 26*(this.length-1)+t},s.prototype.zeroBits=function(){if(this.isZero())return 0;for(var e=0,t=0;t<this.length;t++){var i=this._zeroBits(this.words[t]);if(e+=i,26!==i)break}return e},s.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},s.prototype.toTwos=function(e){return 0!==this.negative?this.abs().inotn(e).iaddn(1):this.clone()},s.prototype.fromTwos=function(e){return this.testn(e-1)?this.notn(e).iaddn(1).ineg():this.clone()},s.prototype.isNeg=function(){return 0!==this.negative},s.prototype.neg=function(){return this.clone().ineg()},s.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},s.prototype.iuor=function(e){for(;this.length<e.length;)this.words[this.length++]=0;for(var t=0;t<e.length;t++)this.words[t]=this.words[t]|e.words[t];return this._strip()},s.prototype.ior=function(e){return r(0===(this.negative|e.negative)),this.iuor(e)},s.prototype.or=function(e){return this.length>e.length?this.clone().ior(e):e.clone().ior(this)},s.prototype.uor=function(e){return this.length>e.length?this.clone().iuor(e):e.clone().iuor(this)},s.prototype.iuand=function(e){var t;t=this.length>e.length?e:this;for(var i=0;i<t.length;i++)this.words[i]=this.words[i]&e.words[i];return this.length=t.length,this._strip()},s.prototype.iand=function(e){return r(0===(this.negative|e.negative)),this.iuand(e)},s.prototype.and=function(e){return this.length>e.length?this.clone().iand(e):e.clone().iand(this)},s.prototype.uand=function(e){return this.length>e.length?this.clone().iuand(e):e.clone().iuand(this)},s.prototype.iuxor=function(e){var t,i;this.length>e.length?(t=this,i=e):(t=e,i=this);for(var r=0;r<i.length;r++)this.words[r]=t.words[r]^i.words[r];if(this!==t)for(;r<t.length;r++)this.words[r]=t.words[r];return this.length=t.length,this._strip()},s.prototype.ixor=function(e){return r(0===(this.negative|e.negative)),this.iuxor(e)},s.prototype.xor=function(e){return this.length>e.length?this.clone().ixor(e):e.clone().ixor(this)},s.prototype.uxor=function(e){return this.length>e.length?this.clone().iuxor(e):e.clone().iuxor(this)},s.prototype.inotn=function(e){r("number"==typeof e&&e>=0);var t=0|Math.ceil(e/26),i=e%26;this._expand(t),i>0&&t--;for(var n=0;n<t;n++)this.words[n]=67108863&~this.words[n];return i>0&&(this.words[n]=~this.words[n]&67108863>>26-i),this._strip()},s.prototype.notn=function(e){return this.clone().inotn(e)},s.prototype.setn=function(e,t){r("number"==typeof e&&e>=0);var i=e/26|0,n=e%26;return this._expand(i+1),this.words[i]=t?this.words[i]|1<<n:this.words[i]&~(1<<n),this._strip()},s.prototype.iadd=function(e){var t,i,r;if(0!==this.negative&&0===e.negative)return this.negative=0,t=this.isub(e),this.negative^=1,this._normSign();if(0===this.negative&&0!==e.negative)return e.negative=0,t=this.isub(e),e.negative=1,t._normSign();this.length>e.length?(i=this,r=e):(i=e,r=this);for(var n=0,s=0;s<r.length;s++)t=(0|i.words[s])+(0|r.words[s])+n,this.words[s]=67108863&t,n=t>>>26;for(;0!==n&&s<i.length;s++)t=(0|i.words[s])+n,this.words[s]=67108863&t,n=t>>>26;if(this.length=i.length,0!==n)this.words[this.length]=n,this.length++;else if(i!==this)for(;s<i.length;s++)this.words[s]=i.words[s];return this},s.prototype.add=function(e){var t;return 0!==e.negative&&0===this.negative?(e.negative=0,t=this.sub(e),e.negative^=1,t):0===e.negative&&0!==this.negative?(this.negative=0,t=e.sub(this),this.negative=1,t):this.length>e.length?this.clone().iadd(e):e.clone().iadd(this)},s.prototype.isub=function(e){if(0!==e.negative){e.negative=0;var t=this.iadd(e);return e.negative=1,t._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(e),this.negative=1,this._normSign();var i,r,n=this.cmp(e);if(0===n)return this.negative=0,this.length=1,this.words[0]=0,this;n>0?(i=this,r=e):(i=e,r=this);for(var s=0,o=0;o<r.length;o++)s=(t=(0|i.words[o])-(0|r.words[o])+s)>>26,this.words[o]=67108863&t;for(;0!==s&&o<i.length;o++)s=(t=(0|i.words[o])+s)>>26,this.words[o]=67108863&t;if(0===s&&o<i.length&&i!==this)for(;o<i.length;o++)this.words[o]=i.words[o];return this.length=Math.max(this.length,o),i!==this&&(this.negative=1),this._strip()},s.prototype.sub=function(e){return this.clone().isub(e)};var m=function(e,t,i){var r,n,s,o=e.words,a=t.words,l=i.words,c=0,u=0|o[0],h=8191&u,d=u>>>13,p=0|o[1],g=8191&p,f=p>>>13,m=0|o[2],v=8191&m,C=m>>>13,y=0|o[3],w=8191&y,S=y>>>13,b=0|o[4],E=8191&b,A=b>>>13,T=0|o[5],M=8191&T,R=T>>>13,_=0|o[6],P=8191&_,x=_>>>13,D=0|o[7],I=8191&D,L=D>>>13,N=0|o[8],O=8191&N,F=N>>>13,k=0|o[9],G=8191&k,V=k>>>13,H=0|a[0],B=8191&H,z=H>>>13,U=0|a[1],W=8191&U,j=U>>>13,K=0|a[2],$=8191&K,q=K>>>13,Y=0|a[3],Q=8191&Y,X=Y>>>13,Z=0|a[4],J=8191&Z,ee=Z>>>13,te=0|a[5],ie=8191&te,re=te>>>13,ne=0|a[6],se=8191&ne,oe=ne>>>13,ae=0|a[7],le=8191&ae,ce=ae>>>13,ue=0|a[8],he=8191&ue,de=ue>>>13,pe=0|a[9],ge=8191&pe,fe=pe>>>13;i.negative=e.negative^t.negative,i.length=19;var me=(c+(r=Math.imul(h,B))|0)+((8191&(n=(n=Math.imul(h,z))+Math.imul(d,B)|0))<<13)|0;c=((s=Math.imul(d,z))+(n>>>13)|0)+(me>>>26)|0,me&=67108863,r=Math.imul(g,B),n=(n=Math.imul(g,z))+Math.imul(f,B)|0,s=Math.imul(f,z);var ve=(c+(r=r+Math.imul(h,W)|0)|0)+((8191&(n=(n=n+Math.imul(h,j)|0)+Math.imul(d,W)|0))<<13)|0;c=((s=s+Math.imul(d,j)|0)+(n>>>13)|0)+(ve>>>26)|0,ve&=67108863,r=Math.imul(v,B),n=(n=Math.imul(v,z))+Math.imul(C,B)|0,s=Math.imul(C,z),r=r+Math.imul(g,W)|0,n=(n=n+Math.imul(g,j)|0)+Math.imul(f,W)|0,s=s+Math.imul(f,j)|0;var Ce=(c+(r=r+Math.imul(h,$)|0)|0)+((8191&(n=(n=n+Math.imul(h,q)|0)+Math.imul(d,$)|0))<<13)|0;c=((s=s+Math.imul(d,q)|0)+(n>>>13)|0)+(Ce>>>26)|0,Ce&=67108863,r=Math.imul(w,B),n=(n=Math.imul(w,z))+Math.imul(S,B)|0,s=Math.imul(S,z),r=r+Math.imul(v,W)|0,n=(n=n+Math.imul(v,j)|0)+Math.imul(C,W)|0,s=s+Math.imul(C,j)|0,r=r+Math.imul(g,$)|0,n=(n=n+Math.imul(g,q)|0)+Math.imul(f,$)|0,s=s+Math.imul(f,q)|0;var ye=(c+(r=r+Math.imul(h,Q)|0)|0)+((8191&(n=(n=n+Math.imul(h,X)|0)+Math.imul(d,Q)|0))<<13)|0;c=((s=s+Math.imul(d,X)|0)+(n>>>13)|0)+(ye>>>26)|0,ye&=67108863,r=Math.imul(E,B),n=(n=Math.imul(E,z))+Math.imul(A,B)|0,s=Math.imul(A,z),r=r+Math.imul(w,W)|0,n=(n=n+Math.imul(w,j)|0)+Math.imul(S,W)|0,s=s+Math.imul(S,j)|0,r=r+Math.imul(v,$)|0,n=(n=n+Math.imul(v,q)|0)+Math.imul(C,$)|0,s=s+Math.imul(C,q)|0,r=r+Math.imul(g,Q)|0,n=(n=n+Math.imul(g,X)|0)+Math.imul(f,Q)|0,s=s+Math.imul(f,X)|0;var we=(c+(r=r+Math.imul(h,J)|0)|0)+((8191&(n=(n=n+Math.imul(h,ee)|0)+Math.imul(d,J)|0))<<13)|0;c=((s=s+Math.imul(d,ee)|0)+(n>>>13)|0)+(we>>>26)|0,we&=67108863,r=Math.imul(M,B),n=(n=Math.imul(M,z))+Math.imul(R,B)|0,s=Math.imul(R,z),r=r+Math.imul(E,W)|0,n=(n=n+Math.imul(E,j)|0)+Math.imul(A,W)|0,s=s+Math.imul(A,j)|0,r=r+Math.imul(w,$)|0,n=(n=n+Math.imul(w,q)|0)+Math.imul(S,$)|0,s=s+Math.imul(S,q)|0,r=r+Math.imul(v,Q)|0,n=(n=n+Math.imul(v,X)|0)+Math.imul(C,Q)|0,s=s+Math.imul(C,X)|0,r=r+Math.imul(g,J)|0,n=(n=n+Math.imul(g,ee)|0)+Math.imul(f,J)|0,s=s+Math.imul(f,ee)|0;var Se=(c+(r=r+Math.imul(h,ie)|0)|0)+((8191&(n=(n=n+Math.imul(h,re)|0)+Math.imul(d,ie)|0))<<13)|0;c=((s=s+Math.imul(d,re)|0)+(n>>>13)|0)+(Se>>>26)|0,Se&=67108863,r=Math.imul(P,B),n=(n=Math.imul(P,z))+Math.imul(x,B)|0,s=Math.imul(x,z),r=r+Math.imul(M,W)|0,n=(n=n+Math.imul(M,j)|0)+Math.imul(R,W)|0,s=s+Math.imul(R,j)|0,r=r+Math.imul(E,$)|0,n=(n=n+Math.imul(E,q)|0)+Math.imul(A,$)|0,s=s+Math.imul(A,q)|0,r=r+Math.imul(w,Q)|0,n=(n=n+Math.imul(w,X)|0)+Math.imul(S,Q)|0,s=s+Math.imul(S,X)|0,r=r+Math.imul(v,J)|0,n=(n=n+Math.imul(v,ee)|0)+Math.imul(C,J)|0,s=s+Math.imul(C,ee)|0,r=r+Math.imul(g,ie)|0,n=(n=n+Math.imul(g,re)|0)+Math.imul(f,ie)|0,s=s+Math.imul(f,re)|0;var be=(c+(r=r+Math.imul(h,se)|0)|0)+((8191&(n=(n=n+Math.imul(h,oe)|0)+Math.imul(d,se)|0))<<13)|0;c=((s=s+Math.imul(d,oe)|0)+(n>>>13)|0)+(be>>>26)|0,be&=67108863,r=Math.imul(I,B),n=(n=Math.imul(I,z))+Math.imul(L,B)|0,s=Math.imul(L,z),r=r+Math.imul(P,W)|0,n=(n=n+Math.imul(P,j)|0)+Math.imul(x,W)|0,s=s+Math.imul(x,j)|0,r=r+Math.imul(M,$)|0,n=(n=n+Math.imul(M,q)|0)+Math.imul(R,$)|0,s=s+Math.imul(R,q)|0,r=r+Math.imul(E,Q)|0,n=(n=n+Math.imul(E,X)|0)+Math.imul(A,Q)|0,s=s+Math.imul(A,X)|0,r=r+Math.imul(w,J)|0,n=(n=n+Math.imul(w,ee)|0)+Math.imul(S,J)|0,s=s+Math.imul(S,ee)|0,r=r+Math.imul(v,ie)|0,n=(n=n+Math.imul(v,re)|0)+Math.imul(C,ie)|0,s=s+Math.imul(C,re)|0,r=r+Math.imul(g,se)|0,n=(n=n+Math.imul(g,oe)|0)+Math.imul(f,se)|0,s=s+Math.imul(f,oe)|0;var Ee=(c+(r=r+Math.imul(h,le)|0)|0)+((8191&(n=(n=n+Math.imul(h,ce)|0)+Math.imul(d,le)|0))<<13)|0;c=((s=s+Math.imul(d,ce)|0)+(n>>>13)|0)+(Ee>>>26)|0,Ee&=67108863,r=Math.imul(O,B),n=(n=Math.imul(O,z))+Math.imul(F,B)|0,s=Math.imul(F,z),r=r+Math.imul(I,W)|0,n=(n=n+Math.imul(I,j)|0)+Math.imul(L,W)|0,s=s+Math.imul(L,j)|0,r=r+Math.imul(P,$)|0,n=(n=n+Math.imul(P,q)|0)+Math.imul(x,$)|0,s=s+Math.imul(x,q)|0,r=r+Math.imul(M,Q)|0,n=(n=n+Math.imul(M,X)|0)+Math.imul(R,Q)|0,s=s+Math.imul(R,X)|0,r=r+Math.imul(E,J)|0,n=(n=n+Math.imul(E,ee)|0)+Math.imul(A,J)|0,s=s+Math.imul(A,ee)|0,r=r+Math.imul(w,ie)|0,n=(n=n+Math.imul(w,re)|0)+Math.imul(S,ie)|0,s=s+Math.imul(S,re)|0,r=r+Math.imul(v,se)|0,n=(n=n+Math.imul(v,oe)|0)+Math.imul(C,se)|0,s=s+Math.imul(C,oe)|0,r=r+Math.imul(g,le)|0,n=(n=n+Math.imul(g,ce)|0)+Math.imul(f,le)|0,s=s+Math.imul(f,ce)|0;var Ae=(c+(r=r+Math.imul(h,he)|0)|0)+((8191&(n=(n=n+Math.imul(h,de)|0)+Math.imul(d,he)|0))<<13)|0;c=((s=s+Math.imul(d,de)|0)+(n>>>13)|0)+(Ae>>>26)|0,Ae&=67108863,r=Math.imul(G,B),n=(n=Math.imul(G,z))+Math.imul(V,B)|0,s=Math.imul(V,z),r=r+Math.imul(O,W)|0,n=(n=n+Math.imul(O,j)|0)+Math.imul(F,W)|0,s=s+Math.imul(F,j)|0,r=r+Math.imul(I,$)|0,n=(n=n+Math.imul(I,q)|0)+Math.imul(L,$)|0,s=s+Math.imul(L,q)|0,r=r+Math.imul(P,Q)|0,n=(n=n+Math.imul(P,X)|0)+Math.imul(x,Q)|0,s=s+Math.imul(x,X)|0,r=r+Math.imul(M,J)|0,n=(n=n+Math.imul(M,ee)|0)+Math.imul(R,J)|0,s=s+Math.imul(R,ee)|0,r=r+Math.imul(E,ie)|0,n=(n=n+Math.imul(E,re)|0)+Math.imul(A,ie)|0,s=s+Math.imul(A,re)|0,r=r+Math.imul(w,se)|0,n=(n=n+Math.imul(w,oe)|0)+Math.imul(S,se)|0,s=s+Math.imul(S,oe)|0,r=r+Math.imul(v,le)|0,n=(n=n+Math.imul(v,ce)|0)+Math.imul(C,le)|0,s=s+Math.imul(C,ce)|0,r=r+Math.imul(g,he)|0,n=(n=n+Math.imul(g,de)|0)+Math.imul(f,he)|0,s=s+Math.imul(f,de)|0;var Te=(c+(r=r+Math.imul(h,ge)|0)|0)+((8191&(n=(n=n+Math.imul(h,fe)|0)+Math.imul(d,ge)|0))<<13)|0;c=((s=s+Math.imul(d,fe)|0)+(n>>>13)|0)+(Te>>>26)|0,Te&=67108863,r=Math.imul(G,W),n=(n=Math.imul(G,j))+Math.imul(V,W)|0,s=Math.imul(V,j),r=r+Math.imul(O,$)|0,n=(n=n+Math.imul(O,q)|0)+Math.imul(F,$)|0,s=s+Math.imul(F,q)|0,r=r+Math.imul(I,Q)|0,n=(n=n+Math.imul(I,X)|0)+Math.imul(L,Q)|0,s=s+Math.imul(L,X)|0,r=r+Math.imul(P,J)|0,n=(n=n+Math.imul(P,ee)|0)+Math.imul(x,J)|0,s=s+Math.imul(x,ee)|0,r=r+Math.imul(M,ie)|0,n=(n=n+Math.imul(M,re)|0)+Math.imul(R,ie)|0,s=s+Math.imul(R,re)|0,r=r+Math.imul(E,se)|0,n=(n=n+Math.imul(E,oe)|0)+Math.imul(A,se)|0,s=s+Math.imul(A,oe)|0,r=r+Math.imul(w,le)|0,n=(n=n+Math.imul(w,ce)|0)+Math.imul(S,le)|0,s=s+Math.imul(S,ce)|0,r=r+Math.imul(v,he)|0,n=(n=n+Math.imul(v,de)|0)+Math.imul(C,he)|0,s=s+Math.imul(C,de)|0;var Me=(c+(r=r+Math.imul(g,ge)|0)|0)+((8191&(n=(n=n+Math.imul(g,fe)|0)+Math.imul(f,ge)|0))<<13)|0;c=((s=s+Math.imul(f,fe)|0)+(n>>>13)|0)+(Me>>>26)|0,Me&=67108863,r=Math.imul(G,$),n=(n=Math.imul(G,q))+Math.imul(V,$)|0,s=Math.imul(V,q),r=r+Math.imul(O,Q)|0,n=(n=n+Math.imul(O,X)|0)+Math.imul(F,Q)|0,s=s+Math.imul(F,X)|0,r=r+Math.imul(I,J)|0,n=(n=n+Math.imul(I,ee)|0)+Math.imul(L,J)|0,s=s+Math.imul(L,ee)|0,r=r+Math.imul(P,ie)|0,n=(n=n+Math.imul(P,re)|0)+Math.imul(x,ie)|0,s=s+Math.imul(x,re)|0,r=r+Math.imul(M,se)|0,n=(n=n+Math.imul(M,oe)|0)+Math.imul(R,se)|0,s=s+Math.imul(R,oe)|0,r=r+Math.imul(E,le)|0,n=(n=n+Math.imul(E,ce)|0)+Math.imul(A,le)|0,s=s+Math.imul(A,ce)|0,r=r+Math.imul(w,he)|0,n=(n=n+Math.imul(w,de)|0)+Math.imul(S,he)|0,s=s+Math.imul(S,de)|0;var Re=(c+(r=r+Math.imul(v,ge)|0)|0)+((8191&(n=(n=n+Math.imul(v,fe)|0)+Math.imul(C,ge)|0))<<13)|0;c=((s=s+Math.imul(C,fe)|0)+(n>>>13)|0)+(Re>>>26)|0,Re&=67108863,r=Math.imul(G,Q),n=(n=Math.imul(G,X))+Math.imul(V,Q)|0,s=Math.imul(V,X),r=r+Math.imul(O,J)|0,n=(n=n+Math.imul(O,ee)|0)+Math.imul(F,J)|0,s=s+Math.imul(F,ee)|0,r=r+Math.imul(I,ie)|0,n=(n=n+Math.imul(I,re)|0)+Math.imul(L,ie)|0,s=s+Math.imul(L,re)|0,r=r+Math.imul(P,se)|0,n=(n=n+Math.imul(P,oe)|0)+Math.imul(x,se)|0,s=s+Math.imul(x,oe)|0,r=r+Math.imul(M,le)|0,n=(n=n+Math.imul(M,ce)|0)+Math.imul(R,le)|0,s=s+Math.imul(R,ce)|0,r=r+Math.imul(E,he)|0,n=(n=n+Math.imul(E,de)|0)+Math.imul(A,he)|0,s=s+Math.imul(A,de)|0;var _e=(c+(r=r+Math.imul(w,ge)|0)|0)+((8191&(n=(n=n+Math.imul(w,fe)|0)+Math.imul(S,ge)|0))<<13)|0;c=((s=s+Math.imul(S,fe)|0)+(n>>>13)|0)+(_e>>>26)|0,_e&=67108863,r=Math.imul(G,J),n=(n=Math.imul(G,ee))+Math.imul(V,J)|0,s=Math.imul(V,ee),r=r+Math.imul(O,ie)|0,n=(n=n+Math.imul(O,re)|0)+Math.imul(F,ie)|0,s=s+Math.imul(F,re)|0,r=r+Math.imul(I,se)|0,n=(n=n+Math.imul(I,oe)|0)+Math.imul(L,se)|0,s=s+Math.imul(L,oe)|0,r=r+Math.imul(P,le)|0,n=(n=n+Math.imul(P,ce)|0)+Math.imul(x,le)|0,s=s+Math.imul(x,ce)|0,r=r+Math.imul(M,he)|0,n=(n=n+Math.imul(M,de)|0)+Math.imul(R,he)|0,s=s+Math.imul(R,de)|0;var Pe=(c+(r=r+Math.imul(E,ge)|0)|0)+((8191&(n=(n=n+Math.imul(E,fe)|0)+Math.imul(A,ge)|0))<<13)|0;c=((s=s+Math.imul(A,fe)|0)+(n>>>13)|0)+(Pe>>>26)|0,Pe&=67108863,r=Math.imul(G,ie),n=(n=Math.imul(G,re))+Math.imul(V,ie)|0,s=Math.imul(V,re),r=r+Math.imul(O,se)|0,n=(n=n+Math.imul(O,oe)|0)+Math.imul(F,se)|0,s=s+Math.imul(F,oe)|0,r=r+Math.imul(I,le)|0,n=(n=n+Math.imul(I,ce)|0)+Math.imul(L,le)|0,s=s+Math.imul(L,ce)|0,r=r+Math.imul(P,he)|0,n=(n=n+Math.imul(P,de)|0)+Math.imul(x,he)|0,s=s+Math.imul(x,de)|0;var xe=(c+(r=r+Math.imul(M,ge)|0)|0)+((8191&(n=(n=n+Math.imul(M,fe)|0)+Math.imul(R,ge)|0))<<13)|0;c=((s=s+Math.imul(R,fe)|0)+(n>>>13)|0)+(xe>>>26)|0,xe&=67108863,r=Math.imul(G,se),n=(n=Math.imul(G,oe))+Math.imul(V,se)|0,s=Math.imul(V,oe),r=r+Math.imul(O,le)|0,n=(n=n+Math.imul(O,ce)|0)+Math.imul(F,le)|0,s=s+Math.imul(F,ce)|0,r=r+Math.imul(I,he)|0,n=(n=n+Math.imul(I,de)|0)+Math.imul(L,he)|0,s=s+Math.imul(L,de)|0;var De=(c+(r=r+Math.imul(P,ge)|0)|0)+((8191&(n=(n=n+Math.imul(P,fe)|0)+Math.imul(x,ge)|0))<<13)|0;c=((s=s+Math.imul(x,fe)|0)+(n>>>13)|0)+(De>>>26)|0,De&=67108863,r=Math.imul(G,le),n=(n=Math.imul(G,ce))+Math.imul(V,le)|0,s=Math.imul(V,ce),r=r+Math.imul(O,he)|0,n=(n=n+Math.imul(O,de)|0)+Math.imul(F,he)|0,s=s+Math.imul(F,de)|0;var Ie=(c+(r=r+Math.imul(I,ge)|0)|0)+((8191&(n=(n=n+Math.imul(I,fe)|0)+Math.imul(L,ge)|0))<<13)|0;c=((s=s+Math.imul(L,fe)|0)+(n>>>13)|0)+(Ie>>>26)|0,Ie&=67108863,r=Math.imul(G,he),n=(n=Math.imul(G,de))+Math.imul(V,he)|0,s=Math.imul(V,de);var Le=(c+(r=r+Math.imul(O,ge)|0)|0)+((8191&(n=(n=n+Math.imul(O,fe)|0)+Math.imul(F,ge)|0))<<13)|0;c=((s=s+Math.imul(F,fe)|0)+(n>>>13)|0)+(Le>>>26)|0,Le&=67108863;var Ne=(c+(r=Math.imul(G,ge))|0)+((8191&(n=(n=Math.imul(G,fe))+Math.imul(V,ge)|0))<<13)|0;return c=((s=Math.imul(V,fe))+(n>>>13)|0)+(Ne>>>26)|0,Ne&=67108863,l[0]=me,l[1]=ve,l[2]=Ce,l[3]=ye,l[4]=we,l[5]=Se,l[6]=be,l[7]=Ee,l[8]=Ae,l[9]=Te,l[10]=Me,l[11]=Re,l[12]=_e,l[13]=Pe,l[14]=xe,l[15]=De,l[16]=Ie,l[17]=Le,l[18]=Ne,0!==c&&(l[19]=c,i.length++),i};function v(e,t,i){i.negative=t.negative^e.negative,i.length=e.length+t.length;for(var r=0,n=0,s=0;s<i.length-1;s++){var o=n;n=0;for(var a=67108863&r,l=Math.min(s,t.length-1),c=Math.max(0,s-e.length+1);c<=l;c++){var u=s-c,h=(0|e.words[u])*(0|t.words[c]),d=67108863&h;a=67108863&(d=d+a|0),n+=(o=(o=o+(h/67108864|0)|0)+(d>>>26)|0)>>>26,o&=67108863}i.words[s]=a,r=o,o=n}return 0!==r?i.words[s]=r:i.length--,i._strip()}function C(e,t,i){return v(e,t,i)}function y(e,t){this.x=e,this.y=t}Math.imul||(m=f),s.prototype.mulTo=function(e,t){var i=this.length+e.length;return 10===this.length&&10===e.length?m(this,e,t):i<63?f(this,e,t):i<1024?v(this,e,t):C(this,e,t)},y.prototype.makeRBT=function(e){for(var t=new Array(e),i=s.prototype._countBits(e)-1,r=0;r<e;r++)t[r]=this.revBin(r,i,e);return t},y.prototype.revBin=function(e,t,i){if(0===e||e===i-1)return e;for(var r=0,n=0;n<t;n++)r|=(1&e)<<t-n-1,e>>=1;return r},y.prototype.permute=function(e,t,i,r,n,s){for(var o=0;o<s;o++)r[o]=t[e[o]],n[o]=i[e[o]]},y.prototype.transform=function(e,t,i,r,n,s){this.permute(s,e,t,i,r,n);for(var o=1;o<n;o<<=1)for(var a=o<<1,l=Math.cos(2*Math.PI/a),c=Math.sin(2*Math.PI/a),u=0;u<n;u+=a)for(var h=l,d=c,p=0;p<o;p++){var g=i[u+p],f=r[u+p],m=i[u+p+o],v=r[u+p+o],C=h*m-d*v;v=h*v+d*m,m=C,i[u+p]=g+m,r[u+p]=f+v,i[u+p+o]=g-m,r[u+p+o]=f-v,p!==a&&(C=l*h-c*d,d=l*d+c*h,h=C)}},y.prototype.guessLen13b=function(e,t){var i=1|Math.max(t,e),r=1&i,n=0;for(i=i/2|0;i;i>>>=1)n++;return 1<<n+1+r},y.prototype.conjugate=function(e,t,i){if(!(i<=1))for(var r=0;r<i/2;r++){var n=e[r];e[r]=e[i-r-1],e[i-r-1]=n,n=t[r],t[r]=-t[i-r-1],t[i-r-1]=-n}},y.prototype.normalize13b=function(e,t){for(var i=0,r=0;r<t/2;r++){var n=8192*Math.round(e[2*r+1]/t)+Math.round(e[2*r]/t)+i;e[r]=67108863&n,i=n<67108864?0:n/67108864|0}return e},y.prototype.convert13b=function(e,t,i,n){for(var s=0,o=0;o<t;o++)s+=0|e[o],i[2*o]=8191&s,s>>>=13,i[2*o+1]=8191&s,s>>>=13;for(o=2*t;o<n;++o)i[o]=0;r(0===s),r(!(-8192&s))},y.prototype.stub=function(e){for(var t=new Array(e),i=0;i<e;i++)t[i]=0;return t},y.prototype.mulp=function(e,t,i){var r=2*this.guessLen13b(e.length,t.length),n=this.makeRBT(r),s=this.stub(r),o=new Array(r),a=new Array(r),l=new Array(r),c=new Array(r),u=new Array(r),h=new Array(r),d=i.words;d.length=r,this.convert13b(e.words,e.length,o,r),this.convert13b(t.words,t.length,c,r),this.transform(o,s,a,l,r,n),this.transform(c,s,u,h,r,n);for(var p=0;p<r;p++){var g=a[p]*u[p]-l[p]*h[p];l[p]=a[p]*h[p]+l[p]*u[p],a[p]=g}return this.conjugate(a,l,r),this.transform(a,l,d,s,r,n),this.conjugate(d,s,r),this.normalize13b(d,r),i.negative=e.negative^t.negative,i.length=e.length+t.length,i._strip()},s.prototype.mul=function(e){var t=new s(null);return t.words=new Array(this.length+e.length),this.mulTo(e,t)},s.prototype.mulf=function(e){var t=new s(null);return t.words=new Array(this.length+e.length),C(this,e,t)},s.prototype.imul=function(e){return this.clone().mulTo(e,this)},s.prototype.imuln=function(e){var t=e<0;t&&(e=-e),r("number"==typeof e),r(e<67108864);for(var i=0,n=0;n<this.length;n++){var s=(0|this.words[n])*e,o=(67108863&s)+(67108863&i);i>>=26,i+=s/67108864|0,i+=o>>>26,this.words[n]=67108863&o}return 0!==i&&(this.words[n]=i,this.length++),this.length=0===e?1:this.length,t?this.ineg():this},s.prototype.muln=function(e){return this.clone().imuln(e)},s.prototype.sqr=function(){return this.mul(this)},s.prototype.isqr=function(){return this.imul(this.clone())},s.prototype.pow=function(e){var t=function(e){for(var t=new Array(e.bitLength()),i=0;i<t.length;i++){var r=i/26|0,n=i%26;t[i]=e.words[r]>>>n&1}return t}(e);if(0===t.length)return new s(1);for(var i=this,r=0;r<t.length&&0===t[r];r++,i=i.sqr());if(++r<t.length)for(var n=i.sqr();r<t.length;r++,n=n.sqr())0!==t[r]&&(i=i.mul(n));return i},s.prototype.iushln=function(e){r("number"==typeof e&&e>=0);var t,i=e%26,n=(e-i)/26,s=67108863>>>26-i<<26-i;if(0!==i){var o=0;for(t=0;t<this.length;t++){var a=this.words[t]&s,l=(0|this.words[t])-a<<i;this.words[t]=l|o,o=a>>>26-i}o&&(this.words[t]=o,this.length++)}if(0!==n){for(t=this.length-1;t>=0;t--)this.words[t+n]=this.words[t];for(t=0;t<n;t++)this.words[t]=0;this.length+=n}return this._strip()},s.prototype.ishln=function(e){return r(0===this.negative),this.iushln(e)},s.prototype.iushrn=function(e,t,i){var n;r("number"==typeof e&&e>=0),n=t?(t-t%26)/26:0;var s=e%26,o=Math.min((e-s)/26,this.length),a=67108863^67108863>>>s<<s,l=i;if(n-=o,n=Math.max(0,n),l){for(var c=0;c<o;c++)l.words[c]=this.words[c];l.length=o}if(0===o);else if(this.length>o)for(this.length-=o,c=0;c<this.length;c++)this.words[c]=this.words[c+o];else this.words[0]=0,this.length=1;var u=0;for(c=this.length-1;c>=0&&(0!==u||c>=n);c--){var h=0|this.words[c];this.words[c]=u<<26-s|h>>>s,u=h&a}return l&&0!==u&&(l.words[l.length++]=u),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},s.prototype.ishrn=function(e,t,i){return r(0===this.negative),this.iushrn(e,t,i)},s.prototype.shln=function(e){return this.clone().ishln(e)},s.prototype.ushln=function(e){return this.clone().iushln(e)},s.prototype.shrn=function(e){return this.clone().ishrn(e)},s.prototype.ushrn=function(e){return this.clone().iushrn(e)},s.prototype.testn=function(e){r("number"==typeof e&&e>=0);var t=e%26,i=(e-t)/26,n=1<<t;return!(this.length<=i||!(this.words[i]&n))},s.prototype.imaskn=function(e){r("number"==typeof e&&e>=0);var t=e%26,i=(e-t)/26;if(r(0===this.negative,"imaskn works only with positive numbers"),this.length<=i)return this;if(0!==t&&i++,this.length=Math.min(i,this.length),0!==t){var n=67108863^67108863>>>t<<t;this.words[this.length-1]&=n}return 0===this.length&&(this.words[0]=0,this.length=1),this._strip()},s.prototype.maskn=function(e){return this.clone().imaskn(e)},s.prototype.iaddn=function(e){return r("number"==typeof e),r(e<67108864),e<0?this.isubn(-e):0!==this.negative?1===this.length&&(0|this.words[0])<=e?(this.words[0]=e-(0|this.words[0]),this.negative=0,this):(this.negative=0,this.isubn(e),this.negative=1,this):this._iaddn(e)},s.prototype._iaddn=function(e){this.words[0]+=e;for(var t=0;t<this.length&&this.words[t]>=67108864;t++)this.words[t]-=67108864,t===this.length-1?this.words[t+1]=1:this.words[t+1]++;return this.length=Math.max(this.length,t+1),this},s.prototype.isubn=function(e){if(r("number"==typeof e),r(e<67108864),e<0)return this.iaddn(-e);if(0!==this.negative)return this.negative=0,this.iaddn(e),this.negative=1,this;if(this.words[0]-=e,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var t=0;t<this.length&&this.words[t]<0;t++)this.words[t]+=67108864,this.words[t+1]-=1;return this._strip()},s.prototype.addn=function(e){return this.clone().iaddn(e)},s.prototype.subn=function(e){return this.clone().isubn(e)},s.prototype.iabs=function(){return this.negative=0,this},s.prototype.abs=function(){return this.clone().iabs()},s.prototype._ishlnsubmul=function(e,t,i){var n,s,o=e.length+i;this._expand(o);var a=0;for(n=0;n<e.length;n++){s=(0|this.words[n+i])+a;var l=(0|e.words[n])*t;a=((s-=67108863&l)>>26)-(l/67108864|0),this.words[n+i]=67108863&s}for(;n<this.length-i;n++)a=(s=(0|this.words[n+i])+a)>>26,this.words[n+i]=67108863&s;if(0===a)return this._strip();for(r(-1===a),a=0,n=0;n<this.length;n++)a=(s=-(0|this.words[n])+a)>>26,this.words[n]=67108863&s;return this.negative=1,this._strip()},s.prototype._wordDiv=function(e,t){var i=(this.length,e.length),r=this.clone(),n=e,o=0|n.words[n.length-1];0!=(i=26-this._countBits(o))&&(n=n.ushln(i),r.iushln(i),o=0|n.words[n.length-1]);var a,l=r.length-n.length;if("mod"!==t){(a=new s(null)).length=l+1,a.words=new Array(a.length);for(var c=0;c<a.length;c++)a.words[c]=0}var u=r.clone()._ishlnsubmul(n,1,l);0===u.negative&&(r=u,a&&(a.words[l]=1));for(var h=l-1;h>=0;h--){var d=67108864*(0|r.words[n.length+h])+(0|r.words[n.length+h-1]);for(d=Math.min(d/o|0,67108863),r._ishlnsubmul(n,d,h);0!==r.negative;)d--,r.negative=0,r._ishlnsubmul(n,1,h),r.isZero()||(r.negative^=1);a&&(a.words[h]=d)}return a&&a._strip(),r._strip(),"div"!==t&&0!==i&&r.iushrn(i),{div:a||null,mod:r}},s.prototype.divmod=function(e,t,i){return r(!e.isZero()),this.isZero()?{div:new s(0),mod:new s(0)}:0!==this.negative&&0===e.negative?(a=this.neg().divmod(e,t),"mod"!==t&&(n=a.div.neg()),"div"!==t&&(o=a.mod.neg(),i&&0!==o.negative&&o.iadd(e)),{div:n,mod:o}):0===this.negative&&0!==e.negative?(a=this.divmod(e.neg(),t),"mod"!==t&&(n=a.div.neg()),{div:n,mod:a.mod}):0!==(this.negative&e.negative)?(a=this.neg().divmod(e.neg(),t),"div"!==t&&(o=a.mod.neg(),i&&0!==o.negative&&o.isub(e)),{div:a.div,mod:o}):e.length>this.length||this.cmp(e)<0?{div:new s(0),mod:this}:1===e.length?"div"===t?{div:this.divn(e.words[0]),mod:null}:"mod"===t?{div:null,mod:new s(this.modrn(e.words[0]))}:{div:this.divn(e.words[0]),mod:new s(this.modrn(e.words[0]))}:this._wordDiv(e,t);var n,o,a},s.prototype.div=function(e){return this.divmod(e,"div",!1).div},s.prototype.mod=function(e){return this.divmod(e,"mod",!1).mod},s.prototype.umod=function(e){return this.divmod(e,"mod",!0).mod},s.prototype.divRound=function(e){var t=this.divmod(e);if(t.mod.isZero())return t.div;var i=0!==t.div.negative?t.mod.isub(e):t.mod,r=e.ushrn(1),n=e.andln(1),s=i.cmp(r);return s<0||1===n&&0===s?t.div:0!==t.div.negative?t.div.isubn(1):t.div.iaddn(1)},s.prototype.modrn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var i=(1<<26)%e,n=0,s=this.length-1;s>=0;s--)n=(i*n+(0|this.words[s]))%e;return t?-n:n},s.prototype.modn=function(e){return this.modrn(e)},s.prototype.idivn=function(e){var t=e<0;t&&(e=-e),r(e<=67108863);for(var i=0,n=this.length-1;n>=0;n--){var s=(0|this.words[n])+67108864*i;this.words[n]=s/e|0,i=s%e}return this._strip(),t?this.ineg():this},s.prototype.divn=function(e){return this.clone().idivn(e)},s.prototype.egcd=function(e){r(0===e.negative),r(!e.isZero());var t=this,i=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n=new s(1),o=new s(0),a=new s(0),l=new s(1),c=0;t.isEven()&&i.isEven();)t.iushrn(1),i.iushrn(1),++c;for(var u=i.clone(),h=t.clone();!t.isZero();){for(var d=0,p=1;0===(t.words[0]&p)&&d<26;++d,p<<=1);if(d>0)for(t.iushrn(d);d-- >0;)(n.isOdd()||o.isOdd())&&(n.iadd(u),o.isub(h)),n.iushrn(1),o.iushrn(1);for(var g=0,f=1;0===(i.words[0]&f)&&g<26;++g,f<<=1);if(g>0)for(i.iushrn(g);g-- >0;)(a.isOdd()||l.isOdd())&&(a.iadd(u),l.isub(h)),a.iushrn(1),l.iushrn(1);t.cmp(i)>=0?(t.isub(i),n.isub(a),o.isub(l)):(i.isub(t),a.isub(n),l.isub(o))}return{a,b:l,gcd:i.iushln(c)}},s.prototype._invmp=function(e){r(0===e.negative),r(!e.isZero());var t=this,i=e.clone();t=0!==t.negative?t.umod(e):t.clone();for(var n,o=new s(1),a=new s(0),l=i.clone();t.cmpn(1)>0&&i.cmpn(1)>0;){for(var c=0,u=1;0===(t.words[0]&u)&&c<26;++c,u<<=1);if(c>0)for(t.iushrn(c);c-- >0;)o.isOdd()&&o.iadd(l),o.iushrn(1);for(var h=0,d=1;0===(i.words[0]&d)&&h<26;++h,d<<=1);if(h>0)for(i.iushrn(h);h-- >0;)a.isOdd()&&a.iadd(l),a.iushrn(1);t.cmp(i)>=0?(t.isub(i),o.isub(a)):(i.isub(t),a.isub(o))}return(n=0===t.cmpn(1)?o:a).cmpn(0)<0&&n.iadd(e),n},s.prototype.gcd=function(e){if(this.isZero())return e.abs();if(e.isZero())return this.abs();var t=this.clone(),i=e.clone();t.negative=0,i.negative=0;for(var r=0;t.isEven()&&i.isEven();r++)t.iushrn(1),i.iushrn(1);for(;;){for(;t.isEven();)t.iushrn(1);for(;i.isEven();)i.iushrn(1);var n=t.cmp(i);if(n<0){var s=t;t=i,i=s}else if(0===n||0===i.cmpn(1))break;t.isub(i)}return i.iushln(r)},s.prototype.invm=function(e){return this.egcd(e).a.umod(e)},s.prototype.isEven=function(){return!(1&this.words[0])},s.prototype.isOdd=function(){return!(1&~this.words[0])},s.prototype.andln=function(e){return this.words[0]&e},s.prototype.bincn=function(e){r("number"==typeof e);var t=e%26,i=(e-t)/26,n=1<<t;if(this.length<=i)return this._expand(i+1),this.words[i]|=n,this;for(var s=n,o=i;0!==s&&o<this.length;o++){var a=0|this.words[o];s=(a+=s)>>>26,a&=67108863,this.words[o]=a}return 0!==s&&(this.words[o]=s,this.length++),this},s.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},s.prototype.cmpn=function(e){var t,i=e<0;if(0!==this.negative&&!i)return-1;if(0===this.negative&&i)return 1;if(this._strip(),this.length>1)t=1;else{i&&(e=-e),r(e<=67108863,"Number is too big");var n=0|this.words[0];t=n===e?0:n<e?-1:1}return 0!==this.negative?0|-t:t},s.prototype.cmp=function(e){if(0!==this.negative&&0===e.negative)return-1;if(0===this.negative&&0!==e.negative)return 1;var t=this.ucmp(e);return 0!==this.negative?0|-t:t},s.prototype.ucmp=function(e){if(this.length>e.length)return 1;if(this.length<e.length)return-1;for(var t=0,i=this.length-1;i>=0;i--){var r=0|this.words[i],n=0|e.words[i];if(r!==n){r<n?t=-1:r>n&&(t=1);break}}return t},s.prototype.gtn=function(e){return 1===this.cmpn(e)},s.prototype.gt=function(e){return 1===this.cmp(e)},s.prototype.gten=function(e){return this.cmpn(e)>=0},s.prototype.gte=function(e){return this.cmp(e)>=0},s.prototype.ltn=function(e){return-1===this.cmpn(e)},s.prototype.lt=function(e){return-1===this.cmp(e)},s.prototype.lten=function(e){return this.cmpn(e)<=0},s.prototype.lte=function(e){return this.cmp(e)<=0},s.prototype.eqn=function(e){return 0===this.cmpn(e)},s.prototype.eq=function(e){return 0===this.cmp(e)},s.red=function(e){return new M(e)},s.prototype.toRed=function(e){return r(!this.red,"Already a number in reduction context"),r(0===this.negative,"red works only with positives"),e.convertTo(this)._forceRed(e)},s.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},s.prototype._forceRed=function(e){return this.red=e,this},s.prototype.forceRed=function(e){return r(!this.red,"Already a number in reduction context"),this._forceRed(e)},s.prototype.redAdd=function(e){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,e)},s.prototype.redIAdd=function(e){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,e)},s.prototype.redSub=function(e){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,e)},s.prototype.redISub=function(e){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,e)},s.prototype.redShl=function(e){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,e)},s.prototype.redMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.mul(this,e)},s.prototype.redIMul=function(e){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,e),this.red.imul(this,e)},s.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},s.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},s.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},s.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},s.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},s.prototype.redPow=function(e){return r(this.red&&!e.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,e)};var w={k256:null,p224:null,p192:null,p25519:null};function S(e,t){this.name=e,this.p=new s(t,16),this.n=this.p.bitLength(),this.k=new s(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function b(){S.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function E(){S.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function A(){S.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function T(){S.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function M(e){if("string"==typeof e){var t=s._prime(e);this.m=t.p,this.prime=t}else r(e.gtn(1),"modulus must be greater than 1"),this.m=e,this.prime=null}function R(e){M.call(this,e),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new s(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S.prototype._tmp=function(){var e=new s(null);return e.words=new Array(Math.ceil(this.n/13)),e},S.prototype.ireduce=function(e){var t,i=e;do{this.split(i,this.tmp),t=(i=(i=this.imulK(i)).iadd(this.tmp)).bitLength()}while(t>this.n);var r=t<this.n?-1:i.ucmp(this.p);return 0===r?(i.words[0]=0,i.length=1):r>0?i.isub(this.p):void 0!==i.strip?i.strip():i._strip(),i},S.prototype.split=function(e,t){e.iushrn(this.n,0,t)},S.prototype.imulK=function(e){return e.imul(this.k)},n(b,S),b.prototype.split=function(e,t){for(var i=4194303,r=Math.min(e.length,9),n=0;n<r;n++)t.words[n]=e.words[n];if(t.length=r,e.length<=9)return e.words[0]=0,void(e.length=1);var s=e.words[9];for(t.words[t.length++]=s&i,n=10;n<e.length;n++){var o=0|e.words[n];e.words[n-10]=(o&i)<<4|s>>>22,s=o}s>>>=22,e.words[n-10]=s,0===s&&e.length>10?e.length-=10:e.length-=9},b.prototype.imulK=function(e){e.words[e.length]=0,e.words[e.length+1]=0,e.length+=2;for(var t=0,i=0;i<e.length;i++){var r=0|e.words[i];t+=977*r,e.words[i]=67108863&t,t=64*r+(t/67108864|0)}return 0===e.words[e.length-1]&&(e.length--,0===e.words[e.length-1]&&e.length--),e},n(E,S),n(A,S),n(T,S),T.prototype.imulK=function(e){for(var t=0,i=0;i<e.length;i++){var r=19*(0|e.words[i])+t,n=67108863&r;r>>>=26,e.words[i]=n,t=r}return 0!==t&&(e.words[e.length++]=t),e},s._prime=function(e){if(w[e])return w[e];var t;if("k256"===e)t=new b;else if("p224"===e)t=new E;else if("p192"===e)t=new A;else{if("p25519"!==e)throw new Error("Unknown prime "+e);t=new T}return w[e]=t,t},M.prototype._verify1=function(e){r(0===e.negative,"red works only with positives"),r(e.red,"red works only with red numbers")},M.prototype._verify2=function(e,t){r(0===(e.negative|t.negative),"red works only with positives"),r(e.red&&e.red===t.red,"red works only with red numbers")},M.prototype.imod=function(e){return this.prime?this.prime.ireduce(e)._forceRed(this):(u(e,e.umod(this.m)._forceRed(this)),e)},M.prototype.neg=function(e){return e.isZero()?e.clone():this.m.sub(e)._forceRed(this)},M.prototype.add=function(e,t){this._verify2(e,t);var i=e.add(t);return i.cmp(this.m)>=0&&i.isub(this.m),i._forceRed(this)},M.prototype.iadd=function(e,t){this._verify2(e,t);var i=e.iadd(t);return i.cmp(this.m)>=0&&i.isub(this.m),i},M.prototype.sub=function(e,t){this._verify2(e,t);var i=e.sub(t);return i.cmpn(0)<0&&i.iadd(this.m),i._forceRed(this)},M.prototype.isub=function(e,t){this._verify2(e,t);var i=e.isub(t);return i.cmpn(0)<0&&i.iadd(this.m),i},M.prototype.shl=function(e,t){return this._verify1(e),this.imod(e.ushln(t))},M.prototype.imul=function(e,t){return this._verify2(e,t),this.imod(e.imul(t))},M.prototype.mul=function(e,t){return this._verify2(e,t),this.imod(e.mul(t))},M.prototype.isqr=function(e){return this.imul(e,e.clone())},M.prototype.sqr=function(e){return this.mul(e,e)},M.prototype.sqrt=function(e){if(e.isZero())return e.clone();var t=this.m.andln(3);if(r(t%2==1),3===t){var i=this.m.add(new s(1)).iushrn(2);return this.pow(e,i)}for(var n=this.m.subn(1),o=0;!n.isZero()&&0===n.andln(1);)o++,n.iushrn(1);r(!n.isZero());var a=new s(1).toRed(this),l=a.redNeg(),c=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new s(2*u*u).toRed(this);0!==this.pow(u,c).cmp(l);)u.redIAdd(l);for(var h=this.pow(u,n),d=this.pow(e,n.addn(1).iushrn(1)),p=this.pow(e,n),g=o;0!==p.cmp(a);){for(var f=p,m=0;0!==f.cmp(a);m++)f=f.redSqr();r(m<g);var v=this.pow(h,new s(1).iushln(g-m-1));d=d.redMul(v),h=v.redSqr(),p=p.redMul(h),g=m}return d},M.prototype.invm=function(e){var t=e._invmp(this.m);return 0!==t.negative?(t.negative=0,this.imod(t).redNeg()):this.imod(t)},M.prototype.pow=function(e,t){if(t.isZero())return new s(1).toRed(this);if(0===t.cmpn(1))return e.clone();var i=new Array(16);i[0]=new s(1).toRed(this),i[1]=e;for(var r=2;r<i.length;r++)i[r]=this.mul(i[r-1],e);var n=i[0],o=0,a=0,l=t.bitLength()%26;for(0===l&&(l=26),r=t.length-1;r>=0;r--){for(var c=t.words[r],u=l-1;u>=0;u--){var h=c>>u&1;n!==i[0]&&(n=this.sqr(n)),0!==h||0!==o?(o<<=1,o|=h,(4===++a||0===r&&0===u)&&(n=this.mul(n,i[o]),a=0,o=0)):a=0}l=26}return n},M.prototype.convertTo=function(e){var t=e.umod(this.m);return t===e?t.clone():t},M.prototype.convertFrom=function(e){var t=e.clone();return t.red=null,t},s.mont=function(e){return new R(e)},n(R,M),R.prototype.convertTo=function(e){return this.imod(e.ushln(this.shift))},R.prototype.convertFrom=function(e){var t=this.imod(e.mul(this.rinv));return t.red=null,t},R.prototype.imul=function(e,t){if(e.isZero()||t.isZero())return e.words[0]=0,e.length=1,e;var i=e.imul(t),r=i.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=i.isub(r).iushrn(this.shift),s=n;return n.cmp(this.m)>=0?s=n.isub(this.m):n.cmpn(0)<0&&(s=n.iadd(this.m)),s._forceRed(this)},R.prototype.mul=function(e,t){if(e.isZero()||t.isZero())return new s(0)._forceRed(this);var i=e.mul(t),r=i.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),n=i.isub(r).iushrn(this.shift),o=n;return n.cmp(this.m)>=0?o=n.isub(this.m):n.cmpn(0)<0&&(o=n.iadd(this.m)),o._forceRed(this)},R.prototype.invm=function(e){return this.imod(e._invmp(this.m).mul(this.r2))._forceRed(this)}}(e=i.nmd(e),this)},36621(e){e.exports=function(e){var t={};function i(r){if(t[r])return t[r].exports;var n=t[r]={i:r,l:!1,exports:{}};return e[r].call(n.exports,n,n.exports,i),n.l=!0,n.exports}return i.m=e,i.c=t,i.d=function(e,t,r){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(i.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)i.d(r,n,function(t){return e[t]}.bind(null,n));return r},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="",i(i.s=90)}({17:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r=i(18),n=function(){function e(){}return e.getFirstMatch=function(e,t){var i=t.match(e);return i&&i.length>0&&i[1]||""},e.getSecondMatch=function(e,t){var i=t.match(e);return i&&i.length>1&&i[2]||""},e.matchAndReturnConst=function(e,t,i){if(e.test(t))return i},e.getWindowsVersionName=function(e){switch(e){case"NT":return"NT";case"XP":case"NT 5.1":return"XP";case"NT 5.0":return"2000";case"NT 5.2":return"2003";case"NT 6.0":return"Vista";case"NT 6.1":return"7";case"NT 6.2":return"8";case"NT 6.3":return"8.1";case"NT 10.0":return"10";default:return}},e.getMacOSVersionName=function(e){var t=e.split(".").splice(0,2).map(function(e){return parseInt(e,10)||0});t.push(0);var i=t[0],r=t[1];if(10===i)switch(r){case 5:return"Leopard";case 6:return"Snow Leopard";case 7:return"Lion";case 8:return"Mountain Lion";case 9:return"Mavericks";case 10:return"Yosemite";case 11:return"El Capitan";case 12:return"Sierra";case 13:return"High Sierra";case 14:return"Mojave";case 15:return"Catalina";default:return}switch(i){case 11:return"Big Sur";case 12:return"Monterey";case 13:return"Ventura";case 14:return"Sonoma";case 15:return"Sequoia";default:return}},e.getAndroidVersionName=function(e){var t=e.split(".").splice(0,2).map(function(e){return parseInt(e,10)||0});if(t.push(0),!(1===t[0]&&t[1]<5))return 1===t[0]&&t[1]<6?"Cupcake":1===t[0]&&t[1]>=6?"Donut":2===t[0]&&t[1]<2?"Eclair":2===t[0]&&2===t[1]?"Froyo":2===t[0]&&t[1]>2?"Gingerbread":3===t[0]?"Honeycomb":4===t[0]&&t[1]<1?"Ice Cream Sandwich":4===t[0]&&t[1]<4?"Jelly Bean":4===t[0]&&t[1]>=4?"KitKat":5===t[0]?"Lollipop":6===t[0]?"Marshmallow":7===t[0]?"Nougat":8===t[0]?"Oreo":9===t[0]?"Pie":void 0},e.getVersionPrecision=function(e){return e.split(".").length},e.compareVersions=function(t,i,r){void 0===r&&(r=!1);var n=e.getVersionPrecision(t),s=e.getVersionPrecision(i),o=Math.max(n,s),a=0,l=e.map([t,i],function(t){var i=o-e.getVersionPrecision(t),r=t+new Array(i+1).join(".0");return e.map(r.split("."),function(e){return new Array(20-e.length).join("0")+e}).reverse()});for(r&&(a=o-Math.min(n,s)),o-=1;o>=a;){if(l[0][o]>l[1][o])return 1;if(l[0][o]===l[1][o]){if(o===a)return 0;o-=1}else if(l[0][o]<l[1][o])return-1}},e.map=function(e,t){var i,r=[];if(Array.prototype.map)return Array.prototype.map.call(e,t);for(i=0;i<e.length;i+=1)r.push(t(e[i]));return r},e.find=function(e,t){var i,r;if(Array.prototype.find)return Array.prototype.find.call(e,t);for(i=0,r=e.length;i<r;i+=1){var n=e[i];if(t(n,i))return n}},e.assign=function(e){for(var t,i,r=e,n=arguments.length,s=new Array(n>1?n-1:0),o=1;o<n;o++)s[o-1]=arguments[o];if(Object.assign)return Object.assign.apply(Object,[e].concat(s));var a=function(){var e=s[t];"object"==typeof e&&null!==e&&Object.keys(e).forEach(function(t){r[t]=e[t]})};for(t=0,i=s.length;t<i;t+=1)a();return e},e.getBrowserAlias=function(e){return r.BROWSER_ALIASES_MAP[e]},e.getBrowserTypeByAlias=function(e){return r.BROWSER_MAP[e]||""},e}();t.default=n,e.exports=t.default},18:function(e,t,i){"use strict";t.__esModule=!0,t.ENGINE_MAP=t.OS_MAP=t.PLATFORMS_MAP=t.BROWSER_MAP=t.BROWSER_ALIASES_MAP=void 0,t.BROWSER_ALIASES_MAP={AmazonBot:"amazonbot","Amazon Silk":"amazon_silk","Android Browser":"android",BaiduSpider:"baiduspider",Bada:"bada",BingCrawler:"bingcrawler",Brave:"brave",BlackBerry:"blackberry","ChatGPT-User":"chatgpt_user",Chrome:"chrome",ClaudeBot:"claudebot",Chromium:"chromium",Diffbot:"diffbot",DuckDuckBot:"duckduckbot",DuckDuckGo:"duckduckgo",Electron:"electron",Epiphany:"epiphany",FacebookExternalHit:"facebookexternalhit",Firefox:"firefox",Focus:"focus",Generic:"generic","Google Search":"google_search",Googlebot:"googlebot",GPTBot:"gptbot","Internet Explorer":"ie",InternetArchiveCrawler:"internetarchivecrawler","K-Meleon":"k_meleon",LibreWolf:"librewolf",Linespider:"linespider",Maxthon:"maxthon","Meta-ExternalAds":"meta_externalads","Meta-ExternalAgent":"meta_externalagent","Meta-ExternalFetcher":"meta_externalfetcher","Meta-WebIndexer":"meta_webindexer","Microsoft Edge":"edge","MZ Browser":"mz","NAVER Whale Browser":"naver","OAI-SearchBot":"oai_searchbot",Omgilibot:"omgilibot",Opera:"opera","Opera Coast":"opera_coast","Pale Moon":"pale_moon",PerplexityBot:"perplexitybot","Perplexity-User":"perplexity_user",PhantomJS:"phantomjs",PingdomBot:"pingdombot",Puffin:"puffin",QQ:"qq",QQLite:"qqlite",QupZilla:"qupzilla",Roku:"roku",Safari:"safari",Sailfish:"sailfish","Samsung Internet for Android":"samsung_internet",SlackBot:"slackbot",SeaMonkey:"seamonkey",Sleipnir:"sleipnir","Sogou Browser":"sogou",Swing:"swing",Tizen:"tizen","UC Browser":"uc",Vivaldi:"vivaldi","WebOS Browser":"webos",WeChat:"wechat",YahooSlurp:"yahooslurp","Yandex Browser":"yandex",YandexBot:"yandexbot",YouBot:"youbot"},t.BROWSER_MAP={amazonbot:"AmazonBot",amazon_silk:"Amazon Silk",android:"Android Browser",baiduspider:"BaiduSpider",bada:"Bada",bingcrawler:"BingCrawler",blackberry:"BlackBerry",brave:"Brave",chatgpt_user:"ChatGPT-User",chrome:"Chrome",claudebot:"ClaudeBot",chromium:"Chromium",diffbot:"Diffbot",duckduckbot:"DuckDuckBot",duckduckgo:"DuckDuckGo",edge:"Microsoft Edge",electron:"Electron",epiphany:"Epiphany",facebookexternalhit:"FacebookExternalHit",firefox:"Firefox",focus:"Focus",generic:"Generic",google_search:"Google Search",googlebot:"Googlebot",gptbot:"GPTBot",ie:"Internet Explorer",internetarchivecrawler:"InternetArchiveCrawler",k_meleon:"K-Meleon",librewolf:"LibreWolf",linespider:"Linespider",maxthon:"Maxthon",meta_externalads:"Meta-ExternalAds",meta_externalagent:"Meta-ExternalAgent",meta_externalfetcher:"Meta-ExternalFetcher",meta_webindexer:"Meta-WebIndexer",mz:"MZ Browser",naver:"NAVER Whale Browser",oai_searchbot:"OAI-SearchBot",omgilibot:"Omgilibot",opera:"Opera",opera_coast:"Opera Coast",pale_moon:"Pale Moon",perplexitybot:"PerplexityBot",perplexity_user:"Perplexity-User",phantomjs:"PhantomJS",pingdombot:"PingdomBot",puffin:"Puffin",qq:"QQ Browser",qqlite:"QQ Browser Lite",qupzilla:"QupZilla",roku:"Roku",safari:"Safari",sailfish:"Sailfish",samsung_internet:"Samsung Internet for Android",seamonkey:"SeaMonkey",slackbot:"SlackBot",sleipnir:"Sleipnir",sogou:"Sogou Browser",swing:"Swing",tizen:"Tizen",uc:"UC Browser",vivaldi:"Vivaldi",webos:"WebOS Browser",wechat:"WeChat",yahooslurp:"YahooSlurp",yandex:"Yandex Browser",yandexbot:"YandexBot",youbot:"YouBot"},t.PLATFORMS_MAP={bot:"bot",desktop:"desktop",mobile:"mobile",tablet:"tablet",tv:"tv"},t.OS_MAP={Android:"Android",Bada:"Bada",BlackBerry:"BlackBerry",ChromeOS:"Chrome OS",HarmonyOS:"HarmonyOS",iOS:"iOS",Linux:"Linux",MacOS:"macOS",PlayStation4:"PlayStation 4",Roku:"Roku",Tizen:"Tizen",WebOS:"WebOS",Windows:"Windows",WindowsPhone:"Windows Phone"},t.ENGINE_MAP={Blink:"Blink",EdgeHTML:"EdgeHTML",Gecko:"Gecko",Presto:"Presto",Trident:"Trident",WebKit:"WebKit"}},90:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r,n=(r=i(91))&&r.__esModule?r:{default:r},s=i(18);function o(e,t){for(var i=0;i<t.length;i++){var r=t[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var a=function(){function e(){}var t,i;return e.getParser=function(e,t,i){if(void 0===t&&(t=!1),void 0===i&&(i=null),"string"!=typeof e)throw new Error("UserAgent should be a string");return new n.default(e,t,i)},e.parse=function(e,t){return void 0===t&&(t=null),new n.default(e,t).getResult()},t=e,i=[{key:"BROWSER_MAP",get:function(){return s.BROWSER_MAP}},{key:"ENGINE_MAP",get:function(){return s.ENGINE_MAP}},{key:"OS_MAP",get:function(){return s.OS_MAP}},{key:"PLATFORMS_MAP",get:function(){return s.PLATFORMS_MAP}}],null&&o(t.prototype,null),i&&o(t,i),e}();t.default=a,e.exports=t.default},91:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r=l(i(92)),n=l(i(93)),s=l(i(94)),o=l(i(95)),a=l(i(17));function l(e){return e&&e.__esModule?e:{default:e}}var c=function(){function e(e,t,i){if(void 0===t&&(t=!1),void 0===i&&(i=null),null==e||""===e)throw new Error("UserAgent parameter can't be empty");this._ua=e;var r=!1;"boolean"==typeof t?(r=t,this._hints=i):this._hints=null!=t&&"object"==typeof t?t:null,this.parsedResult={},!0!==r&&this.parse()}var t=e.prototype;return t.getHints=function(){return this._hints},t.hasBrand=function(e){if(!this._hints||!Array.isArray(this._hints.brands))return!1;var t=e.toLowerCase();return this._hints.brands.some(function(e){return e.brand&&e.brand.toLowerCase()===t})},t.getBrandVersion=function(e){if(this._hints&&Array.isArray(this._hints.brands)){var t=e.toLowerCase(),i=this._hints.brands.find(function(e){return e.brand&&e.brand.toLowerCase()===t});return i?i.version:void 0}},t.getUA=function(){return this._ua},t.test=function(e){return e.test(this._ua)},t.parseBrowser=function(){var e=this;this.parsedResult.browser={};var t=a.default.find(r.default,function(t){if("function"==typeof t.test)return t.test(e);if(Array.isArray(t.test))return t.test.some(function(t){return e.test(t)});throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.browser=t.describe(this.getUA(),this)),this.parsedResult.browser},t.getBrowser=function(){return this.parsedResult.browser?this.parsedResult.browser:this.parseBrowser()},t.getBrowserName=function(e){return e?String(this.getBrowser().name).toLowerCase()||"":this.getBrowser().name||""},t.getBrowserVersion=function(){return this.getBrowser().version},t.getOS=function(){return this.parsedResult.os?this.parsedResult.os:this.parseOS()},t.parseOS=function(){var e=this;this.parsedResult.os={};var t=a.default.find(n.default,function(t){if("function"==typeof t.test)return t.test(e);if(Array.isArray(t.test))return t.test.some(function(t){return e.test(t)});throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.os=t.describe(this.getUA())),this.parsedResult.os},t.getOSName=function(e){var t=this.getOS().name;return e?String(t).toLowerCase()||"":t||""},t.getOSVersion=function(){return this.getOS().version},t.getPlatform=function(){return this.parsedResult.platform?this.parsedResult.platform:this.parsePlatform()},t.getPlatformType=function(e){void 0===e&&(e=!1);var t=this.getPlatform().type;return e?String(t).toLowerCase()||"":t||""},t.parsePlatform=function(){var e=this;this.parsedResult.platform={};var t=a.default.find(s.default,function(t){if("function"==typeof t.test)return t.test(e);if(Array.isArray(t.test))return t.test.some(function(t){return e.test(t)});throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.platform=t.describe(this.getUA())),this.parsedResult.platform},t.getEngine=function(){return this.parsedResult.engine?this.parsedResult.engine:this.parseEngine()},t.getEngineName=function(e){return e?String(this.getEngine().name).toLowerCase()||"":this.getEngine().name||""},t.parseEngine=function(){var e=this;this.parsedResult.engine={};var t=a.default.find(o.default,function(t){if("function"==typeof t.test)return t.test(e);if(Array.isArray(t.test))return t.test.some(function(t){return e.test(t)});throw new Error("Browser's test function is not valid")});return t&&(this.parsedResult.engine=t.describe(this.getUA())),this.parsedResult.engine},t.parse=function(){return this.parseBrowser(),this.parseOS(),this.parsePlatform(),this.parseEngine(),this},t.getResult=function(){return a.default.assign({},this.parsedResult)},t.satisfies=function(e){var t=this,i={},r=0,n={},s=0;if(Object.keys(e).forEach(function(t){var o=e[t];"string"==typeof o?(n[t]=o,s+=1):"object"==typeof o&&(i[t]=o,r+=1)}),r>0){var o=Object.keys(i),l=a.default.find(o,function(e){return t.isOS(e)});if(l){var c=this.satisfies(i[l]);if(void 0!==c)return c}var u=a.default.find(o,function(e){return t.isPlatform(e)});if(u){var h=this.satisfies(i[u]);if(void 0!==h)return h}}if(s>0){var d=Object.keys(n),p=a.default.find(d,function(e){return t.isBrowser(e,!0)});if(void 0!==p)return this.compareVersion(n[p])}},t.isBrowser=function(e,t){void 0===t&&(t=!1);var i=this.getBrowserName().toLowerCase(),r=e.toLowerCase(),n=a.default.getBrowserTypeByAlias(r);return t&&n&&(r=n.toLowerCase()),r===i},t.compareVersion=function(e){var t=[0],i=e,r=!1,n=this.getBrowserVersion();if("string"==typeof n)return">"===e[0]||"<"===e[0]?(i=e.substr(1),"="===e[1]?(r=!0,i=e.substr(2)):t=[],">"===e[0]?t.push(1):t.push(-1)):"="===e[0]?i=e.substr(1):"~"===e[0]&&(r=!0,i=e.substr(1)),t.indexOf(a.default.compareVersions(n,i,r))>-1},t.isOS=function(e){return this.getOSName(!0)===String(e).toLowerCase()},t.isPlatform=function(e){return this.getPlatformType(!0)===String(e).toLowerCase()},t.isEngine=function(e){return this.getEngineName(!0)===String(e).toLowerCase()},t.is=function(e,t){return void 0===t&&(t=!1),this.isBrowser(e,t)||this.isOS(e)||this.isPlatform(e)},t.some=function(e){var t=this;return void 0===e&&(e=[]),e.some(function(e){return t.is(e)})},e}();t.default=c,e.exports=t.default},92:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r,n=(r=i(17))&&r.__esModule?r:{default:r},s=/version\/(\d+(\.?_?\d+)+)/i,o=[{test:[/gptbot/i],describe:function(e){var t={name:"GPTBot"},i=n.default.getFirstMatch(/gptbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/chatgpt-user/i],describe:function(e){var t={name:"ChatGPT-User"},i=n.default.getFirstMatch(/chatgpt-user\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/oai-searchbot/i],describe:function(e){var t={name:"OAI-SearchBot"},i=n.default.getFirstMatch(/oai-searchbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/claudebot/i,/claude-web/i,/claude-user/i,/claude-searchbot/i],describe:function(e){var t={name:"ClaudeBot"},i=n.default.getFirstMatch(/(?:claudebot|claude-web|claude-user|claude-searchbot)\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/omgilibot/i,/webzio-extended/i],describe:function(e){var t={name:"Omgilibot"},i=n.default.getFirstMatch(/(?:omgilibot|webzio-extended)\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/diffbot/i],describe:function(e){var t={name:"Diffbot"},i=n.default.getFirstMatch(/diffbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/perplexitybot/i],describe:function(e){var t={name:"PerplexityBot"},i=n.default.getFirstMatch(/perplexitybot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/perplexity-user/i],describe:function(e){var t={name:"Perplexity-User"},i=n.default.getFirstMatch(/perplexity-user\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/youbot/i],describe:function(e){var t={name:"YouBot"},i=n.default.getFirstMatch(/youbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/meta-webindexer/i],describe:function(e){var t={name:"Meta-WebIndexer"},i=n.default.getFirstMatch(/meta-webindexer\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/meta-externalads/i],describe:function(e){var t={name:"Meta-ExternalAds"},i=n.default.getFirstMatch(/meta-externalads\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/meta-externalagent/i],describe:function(e){var t={name:"Meta-ExternalAgent"},i=n.default.getFirstMatch(/meta-externalagent\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/meta-externalfetcher/i],describe:function(e){var t={name:"Meta-ExternalFetcher"},i=n.default.getFirstMatch(/meta-externalfetcher\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/googlebot/i],describe:function(e){var t={name:"Googlebot"},i=n.default.getFirstMatch(/googlebot\/(\d+(\.\d+))/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/linespider/i],describe:function(e){var t={name:"Linespider"},i=n.default.getFirstMatch(/(?:linespider)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/amazonbot/i],describe:function(e){var t={name:"AmazonBot"},i=n.default.getFirstMatch(/amazonbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/bingbot/i],describe:function(e){var t={name:"BingCrawler"},i=n.default.getFirstMatch(/bingbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/baiduspider/i],describe:function(e){var t={name:"BaiduSpider"},i=n.default.getFirstMatch(/baiduspider\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/duckduckbot/i],describe:function(e){var t={name:"DuckDuckBot"},i=n.default.getFirstMatch(/duckduckbot\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/ia_archiver/i],describe:function(e){var t={name:"InternetArchiveCrawler"},i=n.default.getFirstMatch(/ia_archiver\/(\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/facebookexternalhit/i,/facebookcatalog/i],describe:function(){return{name:"FacebookExternalHit"}}},{test:[/slackbot/i,/slack-imgProxy/i],describe:function(e){var t={name:"SlackBot"},i=n.default.getFirstMatch(/(?:slackbot|slack-imgproxy)(?:-[-\w]+)?[\s/](\d+(\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/yahoo!?[\s/]*slurp/i],describe:function(){return{name:"YahooSlurp"}}},{test:[/yandexbot/i,/yandexmobilebot/i],describe:function(){return{name:"YandexBot"}}},{test:[/pingdom/i],describe:function(){return{name:"PingdomBot"}}},{test:[/opera/i],describe:function(e){var t={name:"Opera"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:opera)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/opr\/|opios/i],describe:function(e){var t={name:"Opera"},i=n.default.getFirstMatch(/(?:opr|opios)[\s/](\S+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/SamsungBrowser/i],describe:function(e){var t={name:"Samsung Internet for Android"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:SamsungBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/Whale/i],describe:function(e){var t={name:"NAVER Whale Browser"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:whale)[\s/](\d+(?:\.\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/PaleMoon/i],describe:function(e){var t={name:"Pale Moon"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:PaleMoon)[\s/](\d+(?:\.\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/MZBrowser/i],describe:function(e){var t={name:"MZ Browser"},i=n.default.getFirstMatch(/(?:MZBrowser)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/focus/i],describe:function(e){var t={name:"Focus"},i=n.default.getFirstMatch(/(?:focus)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/swing/i],describe:function(e){var t={name:"Swing"},i=n.default.getFirstMatch(/(?:swing)[\s/](\d+(?:\.\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/coast/i],describe:function(e){var t={name:"Opera Coast"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:coast)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/opt\/\d+(?:.?_?\d+)+/i],describe:function(e){var t={name:"Opera Touch"},i=n.default.getFirstMatch(/(?:opt)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/yabrowser/i],describe:function(e){var t={name:"Yandex Browser"},i=n.default.getFirstMatch(/(?:yabrowser)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/ucbrowser/i],describe:function(e){var t={name:"UC Browser"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:ucbrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/Maxthon|mxios/i],describe:function(e){var t={name:"Maxthon"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:Maxthon|mxios)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/epiphany/i],describe:function(e){var t={name:"Epiphany"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:epiphany)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/puffin/i],describe:function(e){var t={name:"Puffin"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:puffin)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/sleipnir/i],describe:function(e){var t={name:"Sleipnir"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:sleipnir)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/k-meleon/i],describe:function(e){var t={name:"K-Meleon"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/(?:k-meleon)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/micromessenger/i],describe:function(e){var t={name:"WeChat"},i=n.default.getFirstMatch(/(?:micromessenger)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/qqbrowser/i],describe:function(e){var t={name:/qqbrowserlite/i.test(e)?"QQ Browser Lite":"QQ Browser"},i=n.default.getFirstMatch(/(?:qqbrowserlite|qqbrowser)[/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/msie|trident/i],describe:function(e){var t={name:"Internet Explorer"},i=n.default.getFirstMatch(/(?:msie |rv:)(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/\sedg\//i],describe:function(e){var t={name:"Microsoft Edge"},i=n.default.getFirstMatch(/\sedg\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/edg([ea]|ios)/i],describe:function(e){var t={name:"Microsoft Edge"},i=n.default.getSecondMatch(/edg([ea]|ios)\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/vivaldi/i],describe:function(e){var t={name:"Vivaldi"},i=n.default.getFirstMatch(/vivaldi\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/seamonkey/i],describe:function(e){var t={name:"SeaMonkey"},i=n.default.getFirstMatch(/seamonkey\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/sailfish/i],describe:function(e){var t={name:"Sailfish"},i=n.default.getFirstMatch(/sailfish\s?browser\/(\d+(\.\d+)?)/i,e);return i&&(t.version=i),t}},{test:[/silk/i],describe:function(e){var t={name:"Amazon Silk"},i=n.default.getFirstMatch(/silk\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/phantom/i],describe:function(e){var t={name:"PhantomJS"},i=n.default.getFirstMatch(/phantomjs\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/slimerjs/i],describe:function(e){var t={name:"SlimerJS"},i=n.default.getFirstMatch(/slimerjs\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(e){var t={name:"BlackBerry"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/blackberry[\d]+\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/(web|hpw)[o0]s/i],describe:function(e){var t={name:"WebOS Browser"},i=n.default.getFirstMatch(s,e)||n.default.getFirstMatch(/w(?:eb)?[o0]sbrowser\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/bada/i],describe:function(e){var t={name:"Bada"},i=n.default.getFirstMatch(/dolfin\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/tizen/i],describe:function(e){var t={name:"Tizen"},i=n.default.getFirstMatch(/(?:tizen\s?)?browser\/(\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/qupzilla/i],describe:function(e){var t={name:"QupZilla"},i=n.default.getFirstMatch(/(?:qupzilla)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/librewolf/i],describe:function(e){var t={name:"LibreWolf"},i=n.default.getFirstMatch(/(?:librewolf)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/firefox|iceweasel|fxios/i],describe:function(e){var t={name:"Firefox"},i=n.default.getFirstMatch(/(?:firefox|iceweasel|fxios)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/electron/i],describe:function(e){var t={name:"Electron"},i=n.default.getFirstMatch(/(?:electron)\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/sogoumobilebrowser/i,/metasr/i,/se 2\.[x]/i],describe:function(e){var t={name:"Sogou Browser"},i=n.default.getFirstMatch(/(?:sogoumobilebrowser)[\s/](\d+(\.?_?\d+)+)/i,e),r=n.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,e),s=n.default.getFirstMatch(/se ([\d.]+)x/i,e),o=i||r||s;return o&&(t.version=o),t}},{test:[/MiuiBrowser/i],describe:function(e){var t={name:"Miui"},i=n.default.getFirstMatch(/(?:MiuiBrowser)[\s/](\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:function(e){return!!e.hasBrand("DuckDuckGo")||e.test(/\sDdg\/[\d.]+$/i)},describe:function(e,t){var i={name:"DuckDuckGo"};if(t){var r=t.getBrandVersion("DuckDuckGo");if(r)return i.version=r,i}var s=n.default.getFirstMatch(/\sDdg\/([\d.]+)$/i,e);return s&&(i.version=s),i}},{test:function(e){return e.hasBrand("Brave")},describe:function(e,t){var i={name:"Brave"};if(t){var r=t.getBrandVersion("Brave");if(r)return i.version=r,i}return i}},{test:[/chromium/i],describe:function(e){var t={name:"Chromium"},i=n.default.getFirstMatch(/(?:chromium)[\s/](\d+(\.?_?\d+)+)/i,e)||n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/chrome|crios|crmo/i],describe:function(e){var t={name:"Chrome"},i=n.default.getFirstMatch(/(?:chrome|crios|crmo)\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/GSA/i],describe:function(e){var t={name:"Google Search"},i=n.default.getFirstMatch(/(?:GSA)\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:function(e){var t=!e.test(/like android/i),i=e.test(/android/i);return t&&i},describe:function(e){var t={name:"Android Browser"},i=n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/playstation 4/i],describe:function(e){var t={name:"PlayStation 4"},i=n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/safari|applewebkit/i],describe:function(e){var t={name:"Safari"},i=n.default.getFirstMatch(s,e);return i&&(t.version=i),t}},{test:[/.*/i],describe:function(e){var t=-1!==e.search("\\(")?/^(.*)\/(.*)[ \t]\((.*)/:/^(.*)\/(.*) /;return{name:n.default.getFirstMatch(t,e),version:n.default.getSecondMatch(t,e)}}}];t.default=o,e.exports=t.default},93:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r,n=(r=i(17))&&r.__esModule?r:{default:r},s=i(18),o=[{test:[/Roku\/DVP/],describe:function(e){var t=n.default.getFirstMatch(/Roku\/DVP-(\d+\.\d+)/i,e);return{name:s.OS_MAP.Roku,version:t}}},{test:[/windows phone/i],describe:function(e){var t=n.default.getFirstMatch(/windows phone (?:os)?\s?(\d+(\.\d+)*)/i,e);return{name:s.OS_MAP.WindowsPhone,version:t}}},{test:[/windows /i],describe:function(e){var t=n.default.getFirstMatch(/Windows ((NT|XP)( \d\d?.\d)?)/i,e),i=n.default.getWindowsVersionName(t);return{name:s.OS_MAP.Windows,version:t,versionName:i}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(e){var t={name:s.OS_MAP.iOS},i=n.default.getSecondMatch(/(Version\/)(\d[\d.]+)/,e);return i&&(t.version=i),t}},{test:[/macintosh/i],describe:function(e){var t=n.default.getFirstMatch(/mac os x (\d+(\.?_?\d+)+)/i,e).replace(/[_\s]/g,"."),i=n.default.getMacOSVersionName(t),r={name:s.OS_MAP.MacOS,version:t};return i&&(r.versionName=i),r}},{test:[/(ipod|iphone|ipad)/i],describe:function(e){var t=n.default.getFirstMatch(/os (\d+([_\s]\d+)*) like mac os x/i,e).replace(/[_\s]/g,".");return{name:s.OS_MAP.iOS,version:t}}},{test:[/OpenHarmony/i],describe:function(e){var t=n.default.getFirstMatch(/OpenHarmony\s+(\d+(\.\d+)*)/i,e);return{name:s.OS_MAP.HarmonyOS,version:t}}},{test:function(e){var t=!e.test(/like android/i),i=e.test(/android/i);return t&&i},describe:function(e){var t=n.default.getFirstMatch(/android[\s/-](\d+(\.\d+)*)/i,e),i=n.default.getAndroidVersionName(t),r={name:s.OS_MAP.Android,version:t};return i&&(r.versionName=i),r}},{test:[/(web|hpw)[o0]s/i],describe:function(e){var t=n.default.getFirstMatch(/(?:web|hpw)[o0]s\/(\d+(\.\d+)*)/i,e),i={name:s.OS_MAP.WebOS};return t&&t.length&&(i.version=t),i}},{test:[/blackberry|\bbb\d+/i,/rim\stablet/i],describe:function(e){var t=n.default.getFirstMatch(/rim\stablet\sos\s(\d+(\.\d+)*)/i,e)||n.default.getFirstMatch(/blackberry\d+\/(\d+([_\s]\d+)*)/i,e)||n.default.getFirstMatch(/\bbb(\d+)/i,e);return{name:s.OS_MAP.BlackBerry,version:t}}},{test:[/bada/i],describe:function(e){var t=n.default.getFirstMatch(/bada\/(\d+(\.\d+)*)/i,e);return{name:s.OS_MAP.Bada,version:t}}},{test:[/tizen/i],describe:function(e){var t=n.default.getFirstMatch(/tizen[/\s](\d+(\.\d+)*)/i,e);return{name:s.OS_MAP.Tizen,version:t}}},{test:[/linux/i],describe:function(){return{name:s.OS_MAP.Linux}}},{test:[/CrOS/],describe:function(){return{name:s.OS_MAP.ChromeOS}}},{test:[/PlayStation 4/],describe:function(e){var t=n.default.getFirstMatch(/PlayStation 4[/\s](\d+(\.\d+)*)/i,e);return{name:s.OS_MAP.PlayStation4,version:t}}}];t.default=o,e.exports=t.default},94:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r,n=(r=i(17))&&r.__esModule?r:{default:r},s=i(18),o=[{test:[/googlebot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Google"}}},{test:[/linespider/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Line"}}},{test:[/amazonbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Amazon"}}},{test:[/gptbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/chatgpt-user/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/oai-searchbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"OpenAI"}}},{test:[/baiduspider/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Baidu"}}},{test:[/bingbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Bing"}}},{test:[/duckduckbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"DuckDuckGo"}}},{test:[/claudebot/i,/claude-web/i,/claude-user/i,/claude-searchbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Anthropic"}}},{test:[/omgilibot/i,/webzio-extended/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Webz.io"}}},{test:[/diffbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Diffbot"}}},{test:[/perplexitybot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Perplexity AI"}}},{test:[/perplexity-user/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Perplexity AI"}}},{test:[/youbot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"You.com"}}},{test:[/ia_archiver/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Internet Archive"}}},{test:[/meta-webindexer/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalads/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalagent/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/meta-externalfetcher/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/facebookexternalhit/i,/facebookcatalog/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Meta"}}},{test:[/slackbot/i,/slack-imgProxy/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Slack"}}},{test:[/yahoo/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Yahoo"}}},{test:[/yandexbot/i,/yandexmobilebot/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Yandex"}}},{test:[/pingdom/i],describe:function(){return{type:s.PLATFORMS_MAP.bot,vendor:"Pingdom"}}},{test:[/huawei/i],describe:function(e){var t=n.default.getFirstMatch(/(can-l01)/i,e)&&"Nova",i={type:s.PLATFORMS_MAP.mobile,vendor:"Huawei"};return t&&(i.model=t),i}},{test:[/nexus\s*(?:7|8|9|10).*/i],describe:function(){return{type:s.PLATFORMS_MAP.tablet,vendor:"Nexus"}}},{test:[/ipad/i],describe:function(){return{type:s.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/Macintosh(.*?) FxiOS(.*?)\//],describe:function(){return{type:s.PLATFORMS_MAP.tablet,vendor:"Apple",model:"iPad"}}},{test:[/kftt build/i],describe:function(){return{type:s.PLATFORMS_MAP.tablet,vendor:"Amazon",model:"Kindle Fire HD 7"}}},{test:[/silk/i],describe:function(){return{type:s.PLATFORMS_MAP.tablet,vendor:"Amazon"}}},{test:[/tablet(?! pc)/i],describe:function(){return{type:s.PLATFORMS_MAP.tablet}}},{test:function(e){var t=e.test(/ipod|iphone/i),i=e.test(/like (ipod|iphone)/i);return t&&!i},describe:function(e){var t=n.default.getFirstMatch(/(ipod|iphone)/i,e);return{type:s.PLATFORMS_MAP.mobile,vendor:"Apple",model:t}}},{test:[/nexus\s*[0-6].*/i,/galaxy nexus/i],describe:function(){return{type:s.PLATFORMS_MAP.mobile,vendor:"Nexus"}}},{test:[/Nokia/i],describe:function(e){var t=n.default.getFirstMatch(/Nokia\s+([0-9]+(\.[0-9]+)?)/i,e),i={type:s.PLATFORMS_MAP.mobile,vendor:"Nokia"};return t&&(i.model=t),i}},{test:[/[^-]mobi/i],describe:function(){return{type:s.PLATFORMS_MAP.mobile}}},{test:function(e){return"blackberry"===e.getBrowserName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.mobile,vendor:"BlackBerry"}}},{test:function(e){return"bada"===e.getBrowserName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.mobile}}},{test:function(e){return"windows phone"===e.getBrowserName()},describe:function(){return{type:s.PLATFORMS_MAP.mobile,vendor:"Microsoft"}}},{test:function(e){var t=Number(String(e.getOSVersion()).split(".")[0]);return"android"===e.getOSName(!0)&&t>=3},describe:function(){return{type:s.PLATFORMS_MAP.tablet}}},{test:function(e){return"android"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.mobile}}},{test:[/smart-?tv|smarttv/i],describe:function(){return{type:s.PLATFORMS_MAP.tv}}},{test:[/netcast/i],describe:function(){return{type:s.PLATFORMS_MAP.tv}}},{test:function(e){return"macos"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.desktop,vendor:"Apple"}}},{test:function(e){return"windows"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.desktop}}},{test:function(e){return"linux"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.desktop}}},{test:function(e){return"playstation 4"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.tv}}},{test:function(e){return"roku"===e.getOSName(!0)},describe:function(){return{type:s.PLATFORMS_MAP.tv}}}];t.default=o,e.exports=t.default},95:function(e,t,i){"use strict";t.__esModule=!0,t.default=void 0;var r,n=(r=i(17))&&r.__esModule?r:{default:r},s=i(18),o=[{test:function(e){return"microsoft edge"===e.getBrowserName(!0)},describe:function(e){if(/\sedg\//i.test(e))return{name:s.ENGINE_MAP.Blink};var t=n.default.getFirstMatch(/edge\/(\d+(\.?_?\d+)+)/i,e);return{name:s.ENGINE_MAP.EdgeHTML,version:t}}},{test:[/trident/i],describe:function(e){var t={name:s.ENGINE_MAP.Trident},i=n.default.getFirstMatch(/trident\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:function(e){return e.test(/presto/i)},describe:function(e){var t={name:s.ENGINE_MAP.Presto},i=n.default.getFirstMatch(/presto\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:function(e){var t=e.test(/gecko/i),i=e.test(/like gecko/i);return t&&!i},describe:function(e){var t={name:s.ENGINE_MAP.Gecko},i=n.default.getFirstMatch(/gecko\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}},{test:[/(apple)?webkit\/537\.36/i],describe:function(){return{name:s.ENGINE_MAP.Blink}}},{test:[/(apple)?webkit/i],describe:function(e){var t={name:s.ENGINE_MAP.WebKit},i=n.default.getFirstMatch(/webkit\/(\d+(\.?_?\d+)+)/i,e);return i&&(t.version=i),t}}];t.default=o,e.exports=t.default}})},65442(e,t,i){var r;function n(e){this.rand=e}if(e.exports=function(e){return r||(r=new n(null)),r.generate(e)},e.exports.Rand=n,n.prototype.generate=function(e){return this._rand(e)},n.prototype._rand=function(e){if(this.rand.getBytes)return this.rand.getBytes(e);for(var t=new Uint8Array(e),i=0;i<t.length;i++)t[i]=this.rand.getByte();return t},"object"==typeof self)self.crypto&&self.crypto.getRandomValues?n.prototype._rand=function(e){var t=new Uint8Array(e);return self.crypto.getRandomValues(t),t}:self.msCrypto&&self.msCrypto.getRandomValues?n.prototype._rand=function(e){var t=new Uint8Array(e);return self.msCrypto.getRandomValues(t),t}:"object"==typeof window&&(n.prototype._rand=function(){throw new Error("Not implemented yet")});else try{var s=i(44507);if("function"!=typeof s.randomBytes)throw new Error("Not supported");n.prototype._rand=function(e){return s.randomBytes(e)}}catch(e){}},87088(e,t,i){var r=i(56608).Buffer;function n(e){r.isBuffer(e)||(e=r.from(e));for(var t=e.length/4|0,i=new Array(t),n=0;n<t;n++)i[n]=e.readUInt32BE(4*n);return i}function s(e){for(;0<e.length;e++)e[0]=0}function o(e,t,i,r,n){for(var s,o,a,l,c=i[0],u=i[1],h=i[2],d=i[3],p=e[0]^t[0],g=e[1]^t[1],f=e[2]^t[2],m=e[3]^t[3],v=4,C=1;C<n;C++)s=c[p>>>24]^u[g>>>16&255]^h[f>>>8&255]^d[255&m]^t[v++],o=c[g>>>24]^u[f>>>16&255]^h[m>>>8&255]^d[255&p]^t[v++],a=c[f>>>24]^u[m>>>16&255]^h[p>>>8&255]^d[255&g]^t[v++],l=c[m>>>24]^u[p>>>16&255]^h[g>>>8&255]^d[255&f]^t[v++],p=s,g=o,f=a,m=l;return s=(r[p>>>24]<<24|r[g>>>16&255]<<16|r[f>>>8&255]<<8|r[255&m])^t[v++],o=(r[g>>>24]<<24|r[f>>>16&255]<<16|r[m>>>8&255]<<8|r[255&p])^t[v++],a=(r[f>>>24]<<24|r[m>>>16&255]<<16|r[p>>>8&255]<<8|r[255&g])^t[v++],l=(r[m>>>24]<<24|r[p>>>16&255]<<16|r[g>>>8&255]<<8|r[255&f])^t[v++],[s>>>=0,o>>>=0,a>>>=0,l>>>=0]}var a=[0,1,2,4,8,16,32,64,128,27,54],l=function(){for(var e=new Array(256),t=0;t<256;t++)e[t]=t<128?t<<1:t<<1^283;for(var i=[],r=[],n=[[],[],[],[]],s=[[],[],[],[]],o=0,a=0,l=0;l<256;++l){var c=a^a<<1^a<<2^a<<3^a<<4;c=c>>>8^255&c^99,i[o]=c,r[c]=o;var u=e[o],h=e[u],d=e[h],p=257*e[c]^16843008*c;n[0][o]=p<<24|p>>>8,n[1][o]=p<<16|p>>>16,n[2][o]=p<<8|p>>>24,n[3][o]=p,p=16843009*d^65537*h^257*u^16843008*o,s[0][c]=p<<24|p>>>8,s[1][c]=p<<16|p>>>16,s[2][c]=p<<8|p>>>24,s[3][c]=p,0===o?o=a=1:(o=u^e[e[e[d^u]]],a^=e[e[a]])}return{SBOX:i,INV_SBOX:r,SUB_MIX:n,INV_SUB_MIX:s}}();function c(e){this._key=n(e),this._reset()}c.blockSize=16,c.keySize=32,c.prototype.blockSize=c.blockSize,c.prototype.keySize=c.keySize,c.prototype._reset=function(){for(var e=this._key,t=e.length,i=t+6,r=4*(i+1),n=[],s=0;s<t;s++)n[s]=e[s];for(s=t;s<r;s++){var o=n[s-1];s%t===0?(o=o<<8|o>>>24,o=l.SBOX[o>>>24]<<24|l.SBOX[o>>>16&255]<<16|l.SBOX[o>>>8&255]<<8|l.SBOX[255&o],o^=a[s/t|0]<<24):t>6&&s%t===4&&(o=l.SBOX[o>>>24]<<24|l.SBOX[o>>>16&255]<<16|l.SBOX[o>>>8&255]<<8|l.SBOX[255&o]),n[s]=n[s-t]^o}for(var c=[],u=0;u<r;u++){var h=r-u,d=n[h-(u%4?0:4)];c[u]=u<4||h<=4?d:l.INV_SUB_MIX[0][l.SBOX[d>>>24]]^l.INV_SUB_MIX[1][l.SBOX[d>>>16&255]]^l.INV_SUB_MIX[2][l.SBOX[d>>>8&255]]^l.INV_SUB_MIX[3][l.SBOX[255&d]]}this._nRounds=i,this._keySchedule=n,this._invKeySchedule=c},c.prototype.encryptBlockRaw=function(e){return o(e=n(e),this._keySchedule,l.SUB_MIX,l.SBOX,this._nRounds)},c.prototype.encryptBlock=function(e){var t=this.encryptBlockRaw(e),i=r.allocUnsafe(16);return i.writeUInt32BE(t[0],0),i.writeUInt32BE(t[1],4),i.writeUInt32BE(t[2],8),i.writeUInt32BE(t[3],12),i},c.prototype.decryptBlock=function(e){var t=(e=n(e))[1];e[1]=e[3],e[3]=t;var i=o(e,this._invKeySchedule,l.INV_SUB_MIX,l.INV_SBOX,this._nRounds),s=r.allocUnsafe(16);return s.writeUInt32BE(i[0],0),s.writeUInt32BE(i[3],4),s.writeUInt32BE(i[2],8),s.writeUInt32BE(i[1],12),s},c.prototype.scrub=function(){s(this._keySchedule),s(this._invKeySchedule),s(this._key)},e.exports.AES=c},55801(e,t,i){var r=i(87088),n=i(56608).Buffer,s=i(36334),o=i(91193),a=i(60050),l=i(10460),c=i(56696);function u(e,t,i,o){s.call(this);var l=n.alloc(4,0);this._cipher=new r.AES(t);var u=this._cipher.encryptBlock(l);this._ghash=new a(u),i=function(e,t,i){if(12===t.length)return e._finID=n.concat([t,n.from([0,0,0,1])]),n.concat([t,n.from([0,0,0,2])]);var r=new a(i),s=t.length,o=s%16;r.update(t),o&&(o=16-o,r.update(n.alloc(o,0))),r.update(n.alloc(8,0));var l=8*s,u=n.alloc(8);u.writeUIntBE(l,0,8),r.update(u),e._finID=r.state;var h=n.from(e._finID);return c(h),h}(this,i,u),this._prev=n.from(i),this._cache=n.allocUnsafe(0),this._secCache=n.allocUnsafe(0),this._decrypt=o,this._alen=0,this._len=0,this._mode=e,this._authTag=null,this._called=!1}o(u,s),u.prototype._update=function(e){if(!this._called&&this._alen){var t=16-this._alen%16;t<16&&(t=n.alloc(t,0),this._ghash.update(t))}this._called=!0;var i=this._mode.encrypt(this,e);return this._decrypt?this._ghash.update(e):this._ghash.update(i),this._len+=e.length,i},u.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var e=l(this._ghash.final(8*this._alen,8*this._len),this._cipher.encryptBlock(this._finID));if(this._decrypt&&function(e,t){var i=0;e.length!==t.length&&i++;for(var r=Math.min(e.length,t.length),n=0;n<r;++n)i+=e[n]^t[n];return i}(e,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=e,this._cipher.scrub()},u.prototype.getAuthTag=function(){if(this._decrypt||!n.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},u.prototype.setAuthTag=function(e){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=e},u.prototype.setAAD=function(e){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(e),this._alen+=e.length},e.exports=u},15007(e,t,i){var r=i(85173),n=i(98733),s=i(3349);t.createCipher=t.Cipher=r.createCipher,t.createCipheriv=t.Cipheriv=r.createCipheriv,t.createDecipher=t.Decipher=n.createDecipher,t.createDecipheriv=t.Decipheriv=n.createDecipheriv,t.listCiphers=t.getCiphers=function(){return Object.keys(s)}},98733(e,t,i){var r=i(55801),n=i(56608).Buffer,s=i(76200),o=i(58116),a=i(36334),l=i(87088),c=i(51804);function u(e,t,i){a.call(this),this._cache=new h,this._last=void 0,this._cipher=new l.AES(t),this._prev=n.from(i),this._mode=e,this._autopadding=!0}function h(){this.cache=n.allocUnsafe(0)}function d(e,t,i){var a=s[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof i&&(i=n.from(i)),"GCM"!==a.mode&&i.length!==a.iv)throw new TypeError("invalid iv length "+i.length);if("string"==typeof t&&(t=n.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);return"stream"===a.type?new o(a.module,t,i,!0):"auth"===a.type?new r(a.module,t,i,!0):new u(a.module,t,i)}i(91193)(u,a),u.prototype._update=function(e){var t,i;this._cache.add(e);for(var r=[];t=this._cache.get(this._autopadding);)i=this._mode.decrypt(this,t),r.push(i);return n.concat(r)},u.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return function(e){var t=e[15];if(t<1||t>16)throw new Error("unable to decrypt data");for(var i=-1;++i<t;)if(e[i+(16-t)]!==t)throw new Error("unable to decrypt data");if(16!==t)return e.slice(0,16-t)}(this._mode.decrypt(this,e));if(e)throw new Error("data not multiple of block length")},u.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},h.prototype.add=function(e){this.cache=n.concat([this.cache,e])},h.prototype.get=function(e){var t;if(e){if(this.cache.length>16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t}else if(this.cache.length>=16)return t=this.cache.slice(0,16),this.cache=this.cache.slice(16),t;return null},h.prototype.flush=function(){if(this.cache.length)return this.cache},t.createDecipher=function(e,t){var i=s[e.toLowerCase()];if(!i)throw new TypeError("invalid suite type");var r=c(t,!1,i.key,i.iv);return d(e,r.key,r.iv)},t.createDecipheriv=d},85173(e,t,i){var r=i(76200),n=i(55801),s=i(56608).Buffer,o=i(58116),a=i(36334),l=i(87088),c=i(51804);function u(e,t,i){a.call(this),this._cache=new d,this._cipher=new l.AES(t),this._prev=s.from(i),this._mode=e,this._autopadding=!0}i(91193)(u,a),u.prototype._update=function(e){var t,i;this._cache.add(e);for(var r=[];t=this._cache.get();)i=this._mode.encrypt(this,t),r.push(i);return s.concat(r)};var h=s.alloc(16,16);function d(){this.cache=s.allocUnsafe(0)}function p(e,t,i){var a=r[e.toLowerCase()];if(!a)throw new TypeError("invalid suite type");if("string"==typeof t&&(t=s.from(t)),t.length!==a.key/8)throw new TypeError("invalid key length "+t.length);if("string"==typeof i&&(i=s.from(i)),"GCM"!==a.mode&&i.length!==a.iv)throw new TypeError("invalid iv length "+i.length);return"stream"===a.type?new o(a.module,t,i):"auth"===a.type?new n(a.module,t,i):new u(a.module,t,i)}u.prototype._final=function(){var e=this._cache.flush();if(this._autopadding)return e=this._mode.encrypt(this,e),this._cipher.scrub(),e;if(!e.equals(h))throw this._cipher.scrub(),new Error("data not multiple of block length")},u.prototype.setAutoPadding=function(e){return this._autopadding=!!e,this},d.prototype.add=function(e){this.cache=s.concat([this.cache,e])},d.prototype.get=function(){if(this.cache.length>15){var e=this.cache.slice(0,16);return this.cache=this.cache.slice(16),e}return null},d.prototype.flush=function(){for(var e=16-this.cache.length,t=s.allocUnsafe(e),i=-1;++i<e;)t.writeUInt8(e,i);return s.concat([this.cache,t])},t.createCipheriv=p,t.createCipher=function(e,t){var i=r[e.toLowerCase()];if(!i)throw new TypeError("invalid suite type");var n=c(t,!1,i.key,i.iv);return p(e,n.key,n.iv)}},60050(e,t,i){var r=i(56608).Buffer,n=r.alloc(16,0);function s(e){var t=r.allocUnsafe(16);return t.writeUInt32BE(e[0]>>>0,0),t.writeUInt32BE(e[1]>>>0,4),t.writeUInt32BE(e[2]>>>0,8),t.writeUInt32BE(e[3]>>>0,12),t}function o(e){this.h=e,this.state=r.alloc(16,0),this.cache=r.allocUnsafe(0)}o.prototype.ghash=function(e){for(var t=-1;++t<e.length;)this.state[t]^=e[t];this._multiply()},o.prototype._multiply=function(){for(var e,t,i,r=[(e=this.h).readUInt32BE(0),e.readUInt32BE(4),e.readUInt32BE(8),e.readUInt32BE(12)],n=[0,0,0,0],o=-1;++o<128;){for(!!(this.state[~~(o/8)]&1<<7-o%8)&&(n[0]^=r[0],n[1]^=r[1],n[2]^=r[2],n[3]^=r[3]),i=!!(1&r[3]),t=3;t>0;t--)r[t]=r[t]>>>1|(1&r[t-1])<<31;r[0]=r[0]>>>1,i&&(r[0]=r[0]^225<<24)}this.state=s(n)},o.prototype.update=function(e){var t;for(this.cache=r.concat([this.cache,e]);this.cache.length>=16;)t=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(t)},o.prototype.final=function(e,t){return this.cache.length&&this.ghash(r.concat([this.cache,n],16)),this.ghash(s([0,e,0,t])),this.state},e.exports=o},56696(e){e.exports=function(e){for(var t,i=e.length;i--;){if(255!==(t=e.readUInt8(i))){t++,e.writeUInt8(t,i);break}e.writeUInt8(0,i)}}},98268(e,t,i){var r=i(10460);t.encrypt=function(e,t){var i=r(t,e._prev);return e._prev=e._cipher.encryptBlock(i),e._prev},t.decrypt=function(e,t){var i=e._prev;e._prev=t;var n=e._cipher.decryptBlock(t);return r(n,i)}},56149(e,t,i){var r=i(56608).Buffer,n=i(10460);function s(e,t,i){var s=t.length,o=n(t,e._cache);return e._cache=e._cache.slice(s),e._prev=r.concat([e._prev,i?t:o]),o}t.encrypt=function(e,t,i){for(var n,o=r.allocUnsafe(0);t.length;){if(0===e._cache.length&&(e._cache=e._cipher.encryptBlock(e._prev),e._prev=r.allocUnsafe(0)),!(e._cache.length<=t.length)){o=r.concat([o,s(e,t,i)]);break}n=e._cache.length,o=r.concat([o,s(e,t.slice(0,n),i)]),t=t.slice(n)}return o}},68394(e,t,i){var r=i(56608).Buffer;function n(e,t,i){for(var r,n,o=-1,a=0;++o<8;)r=t&1<<7-o?128:0,a+=(128&(n=e._cipher.encryptBlock(e._prev)[0]^r))>>o%8,e._prev=s(e._prev,i?r:n);return a}function s(e,t){var i=e.length,n=-1,s=r.allocUnsafe(e.length);for(e=r.concat([e,r.from([t])]);++n<i;)s[n]=e[n]<<1|e[n+1]>>7;return s}t.encrypt=function(e,t,i){for(var s=t.length,o=r.allocUnsafe(s),a=-1;++a<s;)o[a]=n(e,t[a],i);return o}},20193(e,t,i){var r=i(56608).Buffer;function n(e,t,i){var n=e._cipher.encryptBlock(e._prev)[0]^t;return e._prev=r.concat([e._prev.slice(1),r.from([i?t:n])]),n}t.encrypt=function(e,t,i){for(var s=t.length,o=r.allocUnsafe(s),a=-1;++a<s;)o[a]=n(e,t[a],i);return o}},5527(e,t,i){var r=i(10460),n=i(56608).Buffer,s=i(56696);function o(e){var t=e._cipher.encryptBlockRaw(e._prev);return s(e._prev),t}t.encrypt=function(e,t){var i=Math.ceil(t.length/16),s=e._cache.length;e._cache=n.concat([e._cache,n.allocUnsafe(16*i)]);for(var a=0;a<i;a++){var l=o(e),c=s+16*a;e._cache.writeUInt32BE(l[0],c+0),e._cache.writeUInt32BE(l[1],c+4),e._cache.writeUInt32BE(l[2],c+8),e._cache.writeUInt32BE(l[3],c+12)}var u=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),r(t,u)}},60882(e,t){t.encrypt=function(e,t){return e._cipher.encryptBlock(t)},t.decrypt=function(e,t){return e._cipher.decryptBlock(t)}},76200(e,t,i){var r={ECB:i(60882),CBC:i(98268),CFB:i(56149),CFB8:i(20193),CFB1:i(68394),OFB:i(37481),CTR:i(5527),GCM:i(5527)},n=i(3349);for(var s in n)n[s].module=r[n[s].mode];e.exports=n},37481(e,t,i){var r=i(10460);function n(e){return e._prev=e._cipher.encryptBlock(e._prev),e._prev}t.encrypt=function(e,t){for(;e._cache.length<t.length;)e._cache=Buffer.concat([e._cache,n(e)]);var i=e._cache.slice(0,t.length);return e._cache=e._cache.slice(t.length),r(t,i)}},58116(e,t,i){var r=i(87088),n=i(56608).Buffer,s=i(36334);function o(e,t,i,o){s.call(this),this._cipher=new r.AES(t),this._prev=n.from(i),this._cache=n.allocUnsafe(0),this._secCache=n.allocUnsafe(0),this._decrypt=o,this._mode=e}i(91193)(o,s),o.prototype._update=function(e){return this._mode.encrypt(this,e,this._decrypt)},o.prototype._final=function(){this._cipher.scrub()},e.exports=o},18350(e,t,i){var r=i(34487),n=i(15007),s=i(76200),o=i(13811),a=i(51804);function l(e,t,i){if(e=e.toLowerCase(),s[e])return n.createCipheriv(e,t,i);if(o[e])return new r({key:t,iv:i,mode:e});throw new TypeError("invalid suite type")}function c(e,t,i){if(e=e.toLowerCase(),s[e])return n.createDecipheriv(e,t,i);if(o[e])return new r({key:t,iv:i,mode:e,decrypt:!0});throw new TypeError("invalid suite type")}t.createCipher=t.Cipher=function(e,t){var i,r;if(e=e.toLowerCase(),s[e])i=s[e].key,r=s[e].iv;else{if(!o[e])throw new TypeError("invalid suite type");i=8*o[e].key,r=o[e].iv}var n=a(t,!1,i,r);return l(e,n.key,n.iv)},t.createCipheriv=t.Cipheriv=l,t.createDecipher=t.Decipher=function(e,t){var i,r;if(e=e.toLowerCase(),s[e])i=s[e].key,r=s[e].iv;else{if(!o[e])throw new TypeError("invalid suite type");i=8*o[e].key,r=o[e].iv}var n=a(t,!1,i,r);return c(e,n.key,n.iv)},t.createDecipheriv=t.Decipheriv=c,t.listCiphers=t.getCiphers=function(){return Object.keys(o).concat(n.getCiphers())}},34487(e,t,i){var r=i(36334),n=i(88754),s=i(91193),o=i(56608).Buffer,a={"des-ede3-cbc":n.CBC.instantiate(n.EDE),"des-ede3":n.EDE,"des-ede-cbc":n.CBC.instantiate(n.EDE),"des-ede":n.EDE,"des-cbc":n.CBC.instantiate(n.DES),"des-ecb":n.DES};function l(e){r.call(this);var t,i=e.mode.toLowerCase(),n=a[i];t=e.decrypt?"decrypt":"encrypt";var s=e.key;o.isBuffer(s)||(s=o.from(s)),"des-ede"!==i&&"des-ede-cbc"!==i||(s=o.concat([s,s.slice(0,8)]));var l=e.iv;o.isBuffer(l)||(l=o.from(l)),this._des=n.create({key:s,iv:l,type:t})}a.des=a["des-cbc"],a.des3=a["des-ede3-cbc"],e.exports=l,s(l,r),l.prototype._update=function(e){return o.from(this._des.update(e))},l.prototype._final=function(){return o.from(this._des.final())}},13811(e,t){t["des-ecb"]={key:8,iv:0},t["des-cbc"]=t.des={key:8,iv:8},t["des-ede3-cbc"]=t.des3={key:24,iv:8},t["des-ede3"]={key:24,iv:0},t["des-ede-cbc"]={key:16,iv:8},t["des-ede"]={key:16,iv:0}},38538(e,t,i){"use strict";var r=i(39286),n=i(82869),s=i(56608).Buffer;function o(e){var t,i=e.modulus.byteLength();do{t=new r(n(i))}while(t.cmp(e.modulus)>=0||!t.umod(e.prime1)||!t.umod(e.prime2));return t}function a(e,t){var i=function(e){var t=o(e);return{blinder:t.toRed(r.mont(e.modulus)).redPow(new r(e.publicExponent)).fromRed(),unblinder:t.invm(e.modulus)}}(t),n=t.modulus.byteLength(),a=new r(e).mul(i.blinder).umod(t.modulus),l=a.toRed(r.mont(t.prime1)),c=a.toRed(r.mont(t.prime2)),u=t.coefficient,h=t.prime1,d=t.prime2,p=l.redPow(t.exponent1).fromRed(),g=c.redPow(t.exponent2).fromRed(),f=p.isub(g).imul(u).umod(h).imul(d);return g.iadd(f).imul(i.unblinder).umod(t.modulus).toArrayLike(s,"be",n)}a.getr=o,e.exports=a},92761(e,t,i){"use strict";e.exports=i(8049)},80206(e,t,i){"use strict";var r=i(56608).Buffer,n=i(18955),s=i(9464),o=i(91193),a=i(76853),l=i(24757),c=i(8049);function u(e){s.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hashType=t.hash,this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function h(e){s.Writable.call(this);var t=c[e];if(!t)throw new Error("Unknown message digest");this._hash=n(t.hash),this._tag=t.id,this._signType=t.sign}function d(e){return new u(e)}function p(e){return new h(e)}Object.keys(c).forEach(function(e){c[e].id=r.from(c[e].id,"hex"),c[e.toLowerCase()]=c[e]}),o(u,s.Writable),u.prototype._write=function(e,t,i){this._hash.update(e),i()},u.prototype.update=function(e,t){return this._hash.update("string"==typeof e?r.from(e,t):e),this},u.prototype.sign=function(e,t){this.end();var i=this._hash.digest(),r=a(i,e,this._hashType,this._signType,this._tag);return t?r.toString(t):r},o(h,s.Writable),h.prototype._write=function(e,t,i){this._hash.update(e),i()},h.prototype.update=function(e,t){return this._hash.update("string"==typeof e?r.from(e,t):e),this},h.prototype.verify=function(e,t,i){var n="string"==typeof t?r.from(t,i):t;this.end();var s=this._hash.digest();return l(n,s,e,this._signType,this._tag)},e.exports={Sign:d,Verify:p,createSign:d,createVerify:p}},76853(e,t,i){"use strict";var r=i(56608).Buffer,n=i(33053),s=i(38538),o=i(23071).ec,a=i(39286),l=i(21973),c=i(32279);function u(e,t,i,s){if((e=r.from(e.toArray())).length<t.byteLength()){var o=r.alloc(t.byteLength()-e.length);e=r.concat([o,e])}var a=i.length,l=function(e,t){e=(e=h(e,t)).mod(t);var i=r.from(e.toArray());if(i.length<t.byteLength()){var n=r.alloc(t.byteLength()-i.length);i=r.concat([n,i])}return i}(i,t),c=r.alloc(a);c.fill(1);var u=r.alloc(a);return u=n(s,u).update(c).update(r.from([0])).update(e).update(l).digest(),c=n(s,u).update(c).digest(),{k:u=n(s,u).update(c).update(r.from([1])).update(e).update(l).digest(),v:c=n(s,u).update(c).digest()}}function h(e,t){var i=new a(e),r=(e.length<<3)-t.bitLength();return r>0&&i.ishrn(r),i}function d(e,t,i){var s,o;do{for(s=r.alloc(0);8*s.length<e.bitLength();)t.v=n(i,t.k).update(t.v).digest(),s=r.concat([s,t.v]);o=h(s,e),t.k=n(i,t.k).update(t.v).update(r.from([0])).digest(),t.v=n(i,t.k).update(t.v).digest()}while(-1!==o.cmp(e));return o}function p(e,t,i,r){return e.toRed(a.mont(i)).redPow(t).fromRed().mod(r)}e.exports=function(e,t,i,n,g){var f=l(t);if(f.curve){if("ecdsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");return function(e,t){var i=c[t.curve.join(".")];if(!i)throw new Error("unknown curve "+t.curve.join("."));var n=new o(i).keyFromPrivate(t.privateKey).sign(e);return r.from(n.toDER())}(e,f)}if("dsa"===f.type){if("dsa"!==n)throw new Error("wrong private key type");return function(e,t,i){for(var n,s=t.params.priv_key,o=t.params.p,l=t.params.q,c=t.params.g,g=new a(0),f=h(e,l).mod(l),m=!1,v=u(s,l,e,i);!1===m;)g=p(c,n=d(l,v,i),o,l),0===(m=n.invm(l).imul(f.add(s.mul(g))).mod(l)).cmpn(0)&&(m=!1,g=new a(0));return function(e,t){e=e.toArray(),t=t.toArray(),128&e[0]&&(e=[0].concat(e)),128&t[0]&&(t=[0].concat(t));var i=[48,e.length+t.length+4,2,e.length];return i=i.concat(e,[2,t.length],t),r.from(i)}(g,m)}(e,f,i)}if("rsa"!==n&&"ecdsa/rsa"!==n)throw new Error("wrong private key type");if(void 0!==t.padding&&1!==t.padding)throw new Error("illegal or unsupported padding mode");e=r.concat([g,e]);for(var m=f.modulus.byteLength(),v=[0,1];e.length+v.length+1<m;)v.push(255);v.push(0);for(var C=-1;++C<e.length;)v.push(e[C]);return s(v,f)},e.exports.getKey=u,e.exports.makeKey=d},24757(e,t,i){"use strict";var r=i(56608).Buffer,n=i(39286),s=i(23071).ec,o=i(21973),a=i(32279);function l(e,t){if(e.cmpn(0)<=0)throw new Error("invalid sig");if(e.cmp(t)>=0)throw new Error("invalid sig")}e.exports=function(e,t,i,c,u){var h=o(i);if("ec"===h.type){if("ecdsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");return function(e,t,i){var r=a[i.data.algorithm.curve.join(".")];if(!r)throw new Error("unknown curve "+i.data.algorithm.curve.join("."));var n=new s(r),o=i.data.subjectPrivateKey.data;return n.verify(t,e,o)}(e,t,h)}if("dsa"===h.type){if("dsa"!==c)throw new Error("wrong public key type");return function(e,t,i){var r=i.data.p,s=i.data.q,a=i.data.g,c=i.data.pub_key,u=o.signature.decode(e,"der"),h=u.s,d=u.r;l(h,s),l(d,s);var p=n.mont(r),g=h.invm(s);return 0===a.toRed(p).redPow(new n(t).mul(g).mod(s)).fromRed().mul(c.toRed(p).redPow(d.mul(g).mod(s)).fromRed()).mod(r).mod(s).cmp(d)}(e,t,h)}if("rsa"!==c&&"ecdsa/rsa"!==c)throw new Error("wrong public key type");t=r.concat([u,t]);for(var d=h.modulus.byteLength(),p=[1],g=0;t.length+p.length+2<d;)p.push(255),g+=1;p.push(0);for(var f=-1;++f<t.length;)p.push(t[f]);p=r.from(p);var m=n.mont(h.modulus);e=(e=new n(e).toRed(m)).redPow(new n(h.publicExponent)),e=r.from(e.fromRed().toArray());var v=g<8?1:0;for(d=Math.min(e.length,p.length),e.length!==p.length&&(v=1),f=-1;++f<d;)v|=e[f]^p[f];return 0===v}},10460(e){e.exports=function(e,t){for(var i=Math.min(e.length,t.length),r=new Buffer(i),n=0;n<i;++n)r[n]=e[n]^t[n];return r}},51999(e,t,i){"use strict";var r=i(84933),n=i(63328),s=i(85101);function o(){return l.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function a(e,t){if(o()<t)throw new RangeError("Invalid typed array length");return l.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=l.prototype:(null===e&&(e=new l(t)),e.length=t),e}function l(e,t,i){if(!(l.TYPED_ARRAY_SUPPORT||this instanceof l))return new l(e,t,i);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return h(this,e)}return c(this,e,t,i)}function c(e,t,i,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,i,r){if(t.byteLength,i<0||t.byteLength<i)throw new RangeError("'offset' is out of bounds");if(t.byteLength<i+(r||0))throw new RangeError("'length' is out of bounds");return t=void 0===i&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,i):new Uint8Array(t,i,r),l.TYPED_ARRAY_SUPPORT?(e=t).__proto__=l.prototype:e=d(e,t),e}(e,t,i,r):"string"==typeof t?function(e,t,i){if("string"==typeof i&&""!==i||(i="utf8"),!l.isEncoding(i))throw new TypeError('"encoding" must be a valid string encoding');var r=0|g(t,i),n=(e=a(e,r)).write(t,i);return n!==r&&(e=e.slice(0,n)),e}(e,t,i):function(e,t){if(l.isBuffer(t)){var i=0|p(t.length);return 0===(e=a(e,i)).length||t.copy(e,0,0,i),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?a(e,0):d(e,t);if("Buffer"===t.type&&s(t.data))return d(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function h(e,t){if(u(t),e=a(e,t<0?0:0|p(t)),!l.TYPED_ARRAY_SUPPORT)for(var i=0;i<t;++i)e[i]=0;return e}function d(e,t){var i=t.length<0?0:0|p(t.length);e=a(e,i);for(var r=0;r<i;r+=1)e[r]=255&t[r];return e}function p(e){if(e>=o())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o().toString(16)+" bytes");return 0|e}function g(e,t){if(l.isBuffer(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var i=e.length;if(0===i)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return i;case"utf8":case"utf-8":case void 0:return B(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*i;case"hex":return i>>>1;case"base64":return z(e).length;default:if(r)return B(e).length;t=(""+t).toLowerCase(),r=!0}}function f(e,t,i){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===i||i>this.length)&&(i=this.length),i<=0)return"";if((i>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return x(this,t,i);case"utf8":case"utf-8":return M(this,t,i);case"ascii":return _(this,t,i);case"latin1":case"binary":return P(this,t,i);case"base64":return T(this,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return D(this,t,i);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function m(e,t,i){var r=e[t];e[t]=e[i],e[i]=r}function v(e,t,i,r,n){if(0===e.length)return-1;if("string"==typeof i?(r=i,i=0):i>2147483647?i=2147483647:i<-2147483648&&(i=-2147483648),i=+i,isNaN(i)&&(i=n?0:e.length-1),i<0&&(i=e.length+i),i>=e.length){if(n)return-1;i=e.length-1}else if(i<0){if(!n)return-1;i=0}if("string"==typeof t&&(t=l.from(t,r)),l.isBuffer(t))return 0===t.length?-1:C(e,t,i,r,n);if("number"==typeof t)return t&=255,l.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,i):Uint8Array.prototype.lastIndexOf.call(e,t,i):C(e,[t],i,r,n);throw new TypeError("val must be string, number or Buffer")}function C(e,t,i,r,n){var s,o=1,a=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;o=2,a/=2,l/=2,i/=2}function c(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(n){var u=-1;for(s=i;s<a;s++)if(c(e,s)===c(t,-1===u?0:s-u)){if(-1===u&&(u=s),s-u+1===l)return u*o}else-1!==u&&(s-=s-u),u=-1}else for(i+l>a&&(i=a-l),s=i;s>=0;s--){for(var h=!0,d=0;d<l;d++)if(c(e,s+d)!==c(t,d)){h=!1;break}if(h)return s}return-1}function y(e,t,i,r){i=Number(i)||0;var n=e.length-i;r?(r=Number(r))>n&&(r=n):r=n;var s=t.length;if(s%2!=0)throw new TypeError("Invalid hex string");r>s/2&&(r=s/2);for(var o=0;o<r;++o){var a=parseInt(t.substr(2*o,2),16);if(isNaN(a))return o;e[i+o]=a}return o}function w(e,t,i,r){return U(B(t,e.length-i),e,i,r)}function S(e,t,i,r){return U(function(e){for(var t=[],i=0;i<e.length;++i)t.push(255&e.charCodeAt(i));return t}(t),e,i,r)}function b(e,t,i,r){return S(e,t,i,r)}function E(e,t,i,r){return U(z(t),e,i,r)}function A(e,t,i,r){return U(function(e,t){for(var i,r,n,s=[],o=0;o<e.length&&!((t-=2)<0);++o)r=(i=e.charCodeAt(o))>>8,n=i%256,s.push(n),s.push(r);return s}(t,e.length-i),e,i,r)}function T(e,t,i){return 0===t&&i===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,i))}function M(e,t,i){i=Math.min(e.length,i);for(var r=[],n=t;n<i;){var s,o,a,l,c=e[n],u=null,h=c>239?4:c>223?3:c>191?2:1;if(n+h<=i)switch(h){case 1:c<128&&(u=c);break;case 2:128==(192&(s=e[n+1]))&&(l=(31&c)<<6|63&s)>127&&(u=l);break;case 3:s=e[n+1],o=e[n+2],128==(192&s)&&128==(192&o)&&(l=(15&c)<<12|(63&s)<<6|63&o)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:s=e[n+1],o=e[n+2],a=e[n+3],128==(192&s)&&128==(192&o)&&128==(192&a)&&(l=(15&c)<<18|(63&s)<<12|(63&o)<<6|63&a)>65535&&l<1114112&&(u=l)}null===u?(u=65533,h=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),n+=h}return function(e){var t=e.length;if(t<=R)return String.fromCharCode.apply(String,e);for(var i="",r=0;r<t;)i+=String.fromCharCode.apply(String,e.slice(r,r+=R));return i}(r)}t.hp=l,t.IS=50,l.TYPED_ARRAY_SUPPORT=void 0!==globalThis.TYPED_ARRAY_SUPPORT?globalThis.TYPED_ARRAY_SUPPORT:function(){try{var e=new Uint8Array(1);return e.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===e.foo()&&"function"==typeof e.subarray&&0===e.subarray(1,1).byteLength}catch(e){return!1}}(),o(),l.poolSize=8192,l._augment=function(e){return e.__proto__=l.prototype,e},l.from=function(e,t,i){return c(null,e,t,i)},l.TYPED_ARRAY_SUPPORT&&(l.prototype.__proto__=Uint8Array.prototype,l.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&l[Symbol.species]===l&&Object.defineProperty(l,Symbol.species,{value:null,configurable:!0})),l.alloc=function(e,t,i){return function(e,t,i,r){return u(t),t<=0?a(e,t):void 0!==i?"string"==typeof r?a(e,t).fill(i,r):a(e,t).fill(i):a(e,t)}(null,e,t,i)},l.allocUnsafe=function(e){return h(null,e)},l.allocUnsafeSlow=function(e){return h(null,e)},l.isBuffer=function(e){return!(null==e||!e._isBuffer)},l.compare=function(e,t){if(!l.isBuffer(e)||!l.isBuffer(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var i=e.length,r=t.length,n=0,s=Math.min(i,r);n<s;++n)if(e[n]!==t[n]){i=e[n],r=t[n];break}return i<r?-1:r<i?1:0},l.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},l.concat=function(e,t){if(!s(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return l.alloc(0);var i;if(void 0===t)for(t=0,i=0;i<e.length;++i)t+=e[i].length;var r=l.allocUnsafe(t),n=0;for(i=0;i<e.length;++i){var o=e[i];if(!l.isBuffer(o))throw new TypeError('"list" argument must be an Array of Buffers');o.copy(r,n),n+=o.length}return r},l.byteLength=g,l.prototype._isBuffer=!0,l.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)m(this,t,t+1);return this},l.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)m(this,t,t+3),m(this,t+1,t+2);return this},l.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)m(this,t,t+7),m(this,t+1,t+6),m(this,t+2,t+5),m(this,t+3,t+4);return this},l.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?M(this,0,e):f.apply(this,arguments)},l.prototype.equals=function(e){if(!l.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===l.compare(this,e)},l.prototype.inspect=function(){var e="",i=t.IS;return this.length>0&&(e=this.toString("hex",0,i).match(/.{2}/g).join(" "),this.length>i&&(e+=" ... ")),"<Buffer "+e+">"},l.prototype.compare=function(e,t,i,r,n){if(!l.isBuffer(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===i&&(i=e?e.length:0),void 0===r&&(r=0),void 0===n&&(n=this.length),t<0||i>e.length||r<0||n>this.length)throw new RangeError("out of range index");if(r>=n&&t>=i)return 0;if(r>=n)return-1;if(t>=i)return 1;if(this===e)return 0;for(var s=(n>>>=0)-(r>>>=0),o=(i>>>=0)-(t>>>=0),a=Math.min(s,o),c=this.slice(r,n),u=e.slice(t,i),h=0;h<a;++h)if(c[h]!==u[h]){s=c[h],o=u[h];break}return s<o?-1:o<s?1:0},l.prototype.includes=function(e,t,i){return-1!==this.indexOf(e,t,i)},l.prototype.indexOf=function(e,t,i){return v(this,e,t,i,!0)},l.prototype.lastIndexOf=function(e,t,i){return v(this,e,t,i,!1)},l.prototype.write=function(e,t,i,r){if(void 0===t)r="utf8",i=this.length,t=0;else if(void 0===i&&"string"==typeof t)r=t,i=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(i)?(i|=0,void 0===r&&(r="utf8")):(r=i,i=void 0)}var n=this.length-t;if((void 0===i||i>n)&&(i=n),e.length>0&&(i<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var s=!1;;)switch(r){case"hex":return y(this,e,t,i);case"utf8":case"utf-8":return w(this,e,t,i);case"ascii":return S(this,e,t,i);case"latin1":case"binary":return b(this,e,t,i);case"base64":return E(this,e,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,e,t,i);default:if(s)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),s=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var R=4096;function _(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(127&e[n]);return r}function P(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(e[n]);return r}function x(e,t,i){var r=e.length;(!t||t<0)&&(t=0),(!i||i<0||i>r)&&(i=r);for(var n="",s=t;s<i;++s)n+=H(e[s]);return n}function D(e,t,i){for(var r=e.slice(t,i),n="",s=0;s<r.length;s+=2)n+=String.fromCharCode(r[s]+256*r[s+1]);return n}function I(e,t,i){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>i)throw new RangeError("Trying to access beyond buffer length")}function L(e,t,i,r,n,s){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<s)throw new RangeError('"value" argument is out of bounds');if(i+r>e.length)throw new RangeError("Index out of range")}function N(e,t,i,r){t<0&&(t=65535+t+1);for(var n=0,s=Math.min(e.length-i,2);n<s;++n)e[i+n]=(t&255<<8*(r?n:1-n))>>>8*(r?n:1-n)}function O(e,t,i,r){t<0&&(t=4294967295+t+1);for(var n=0,s=Math.min(e.length-i,4);n<s;++n)e[i+n]=t>>>8*(r?n:3-n)&255}function F(e,t,i,r,n,s){if(i+r>e.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("Index out of range")}function k(e,t,i,r,s){return s||F(e,0,i,4),n.write(e,t,i,r,23,4),i+4}function G(e,t,i,r,s){return s||F(e,0,i,8),n.write(e,t,i,r,52,8),i+8}l.prototype.slice=function(e,t){var i,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),l.TYPED_ARRAY_SUPPORT)(i=this.subarray(e,t)).__proto__=l.prototype;else{var n=t-e;i=new l(n,void 0);for(var s=0;s<n;++s)i[s]=this[s+e]}return i},l.prototype.readUIntLE=function(e,t,i){e|=0,t|=0,i||I(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r},l.prototype.readUIntBE=function(e,t,i){e|=0,t|=0,i||I(e,t,this.length);for(var r=this[e+--t],n=1;t>0&&(n*=256);)r+=this[e+--t]*n;return r},l.prototype.readUInt8=function(e,t){return t||I(e,1,this.length),this[e]},l.prototype.readUInt16LE=function(e,t){return t||I(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUInt16BE=function(e,t){return t||I(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUInt32LE=function(e,t){return t||I(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},l.prototype.readUInt32BE=function(e,t){return t||I(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readIntLE=function(e,t,i){e|=0,t|=0,i||I(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r>=(n*=128)&&(r-=Math.pow(2,8*t)),r},l.prototype.readIntBE=function(e,t,i){e|=0,t|=0,i||I(e,t,this.length);for(var r=t,n=1,s=this[e+--r];r>0&&(n*=256);)s+=this[e+--r]*n;return s>=(n*=128)&&(s-=Math.pow(2,8*t)),s},l.prototype.readInt8=function(e,t){return t||I(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},l.prototype.readInt16LE=function(e,t){t||I(e,2,this.length);var i=this[e]|this[e+1]<<8;return 32768&i?4294901760|i:i},l.prototype.readInt16BE=function(e,t){t||I(e,2,this.length);var i=this[e+1]|this[e]<<8;return 32768&i?4294901760|i:i},l.prototype.readInt32LE=function(e,t){return t||I(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return t||I(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readFloatLE=function(e,t){return t||I(e,4,this.length),n.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return t||I(e,4,this.length),n.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return t||I(e,8,this.length),n.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return t||I(e,8,this.length),n.read(this,e,!1,52,8)},l.prototype.writeUIntLE=function(e,t,i,r){e=+e,t|=0,i|=0,r||L(this,e,t,i,Math.pow(2,8*i)-1,0);var n=1,s=0;for(this[t]=255&e;++s<i&&(n*=256);)this[t+s]=e/n&255;return t+i},l.prototype.writeUIntBE=function(e,t,i,r){e=+e,t|=0,i|=0,r||L(this,e,t,i,Math.pow(2,8*i)-1,0);var n=i-1,s=1;for(this[t+n]=255&e;--n>=0&&(s*=256);)this[t+n]=e/s&255;return t+i},l.prototype.writeUInt8=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,1,255,0),l.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},l.prototype.writeUInt16LE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,2,65535,0),l.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},l.prototype.writeUInt16BE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,2,65535,0),l.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},l.prototype.writeUInt32LE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):O(this,e,t,!0),t+4},l.prototype.writeUInt32BE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,4,4294967295,0),l.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):O(this,e,t,!1),t+4},l.prototype.writeIntLE=function(e,t,i,r){if(e=+e,t|=0,!r){var n=Math.pow(2,8*i-1);L(this,e,t,i,n-1,-n)}var s=0,o=1,a=0;for(this[t]=255&e;++s<i&&(o*=256);)e<0&&0===a&&0!==this[t+s-1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},l.prototype.writeIntBE=function(e,t,i,r){if(e=+e,t|=0,!r){var n=Math.pow(2,8*i-1);L(this,e,t,i,n-1,-n)}var s=i-1,o=1,a=0;for(this[t+s]=255&e;--s>=0&&(o*=256);)e<0&&0===a&&0!==this[t+s+1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},l.prototype.writeInt8=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,1,127,-128),l.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},l.prototype.writeInt16LE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):N(this,e,t,!0),t+2},l.prototype.writeInt16BE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,2,32767,-32768),l.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):N(this,e,t,!1),t+2},l.prototype.writeInt32LE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,4,2147483647,-2147483648),l.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):O(this,e,t,!0),t+4},l.prototype.writeInt32BE=function(e,t,i){return e=+e,t|=0,i||L(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),l.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):O(this,e,t,!1),t+4},l.prototype.writeFloatLE=function(e,t,i){return k(this,e,t,!0,i)},l.prototype.writeFloatBE=function(e,t,i){return k(this,e,t,!1,i)},l.prototype.writeDoubleLE=function(e,t,i){return G(this,e,t,!0,i)},l.prototype.writeDoubleBE=function(e,t,i){return G(this,e,t,!1,i)},l.prototype.copy=function(e,t,i,r){if(i||(i=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<i&&(r=i),r===i)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-i&&(r=e.length-t+i);var n,s=r-i;if(this===e&&i<t&&t<r)for(n=s-1;n>=0;--n)e[n+t]=this[n+i];else if(s<1e3||!l.TYPED_ARRAY_SUPPORT)for(n=0;n<s;++n)e[n+t]=this[n+i];else Uint8Array.prototype.set.call(e,this.subarray(i,i+s),t);return s},l.prototype.fill=function(e,t,i,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,i=this.length):"string"==typeof i&&(r=i,i=this.length),1===e.length){var n=e.charCodeAt(0);n<256&&(e=n)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!l.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<i)throw new RangeError("Out of range index");if(i<=t)return this;var s;if(t>>>=0,i=void 0===i?this.length:i>>>0,e||(e=0),"number"==typeof e)for(s=t;s<i;++s)this[s]=e;else{var o=l.isBuffer(e)?e:B(new l(e,r).toString()),a=o.length;for(s=0;s<i-t;++s)this[s+t]=o[s%a]}return this};var V=/[^+\/0-9A-Za-z-_]/g;function H(e){return e<16?"0"+e.toString(16):e.toString(16)}function B(e,t){var i;t=t||1/0;for(var r=e.length,n=null,s=[],o=0;o<r;++o){if((i=e.charCodeAt(o))>55295&&i<57344){if(!n){if(i>56319){(t-=3)>-1&&s.push(239,191,189);continue}if(o+1===r){(t-=3)>-1&&s.push(239,191,189);continue}n=i;continue}if(i<56320){(t-=3)>-1&&s.push(239,191,189),n=i;continue}i=65536+(n-55296<<10|i-56320)}else n&&(t-=3)>-1&&s.push(239,191,189);if(n=null,i<128){if((t-=1)<0)break;s.push(i)}else if(i<2048){if((t-=2)<0)break;s.push(i>>6|192,63&i|128)}else if(i<65536){if((t-=3)<0)break;s.push(i>>12|224,i>>6&63|128,63&i|128)}else{if(!(i<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;s.push(i>>18|240,i>>12&63|128,i>>6&63|128,63&i|128)}}return s}function z(e){return r.toByteArray(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(V,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function U(e,t,i,r){for(var n=0;n<r&&!(n+i>=t.length||n>=e.length);++n)t[n+i]=e[n];return n}},77511(e,t,i){"use strict";var r=i(84933),n=i(63328),s="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;t.Buffer=l,t.SlowBuffer=function(e){return+e!=e&&(e=0),l.alloc(+e)},t.INSPECT_MAX_BYTES=50;var o=2147483647;function a(e){if(e>o)throw new RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,l.prototype),t}function l(e,t,i){if("number"==typeof e){if("string"==typeof t)throw new TypeError('The "string" argument must be of type string. Received type number');return h(e)}return c(e,t,i)}function c(e,t,i){if("string"==typeof e)return function(e,t){if("string"==typeof t&&""!==t||(t="utf8"),!l.isEncoding(t))throw new TypeError("Unknown encoding: "+t);var i=0|f(e,t),r=a(i),n=r.write(e,t);return n!==i&&(r=r.slice(0,n)),r}(e,t);if(ArrayBuffer.isView(e))return d(e);if(null==e)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(z(e,ArrayBuffer)||e&&z(e.buffer,ArrayBuffer))return p(e,t,i);if("undefined"!=typeof SharedArrayBuffer&&(z(e,SharedArrayBuffer)||e&&z(e.buffer,SharedArrayBuffer)))return p(e,t,i);if("number"==typeof e)throw new TypeError('The "value" argument must not be of type number. Received type number');var r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return l.from(r,t,i);var n=function(e){if(l.isBuffer(e)){var t=0|g(e.length),i=a(t);return 0===i.length||e.copy(i,0,0,t),i}return void 0!==e.length?"number"!=typeof e.length||U(e.length)?a(0):d(e):"Buffer"===e.type&&Array.isArray(e.data)?d(e.data):void 0}(e);if(n)return n;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return l.from(e[Symbol.toPrimitive]("string"),t,i);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function u(e){if("number"!=typeof e)throw new TypeError('"size" argument must be of type number');if(e<0)throw new RangeError('The value "'+e+'" is invalid for option "size"')}function h(e){return u(e),a(e<0?0:0|g(e))}function d(e){for(var t=e.length<0?0:0|g(e.length),i=a(t),r=0;r<t;r+=1)i[r]=255&e[r];return i}function p(e,t,i){if(t<0||e.byteLength<t)throw new RangeError('"offset" is outside of buffer bounds');if(e.byteLength<t+(i||0))throw new RangeError('"length" is outside of buffer bounds');var r;return r=void 0===t&&void 0===i?new Uint8Array(e):void 0===i?new Uint8Array(e,t):new Uint8Array(e,t,i),Object.setPrototypeOf(r,l.prototype),r}function g(e){if(e>=o)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+o.toString(16)+" bytes");return 0|e}function f(e,t){if(l.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||z(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var i=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===i)return 0;for(var n=!1;;)switch(t){case"ascii":case"latin1":case"binary":return i;case"utf8":case"utf-8":return V(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*i;case"hex":return i>>>1;case"base64":return H(e).length;default:if(n)return r?-1:V(e).length;t=(""+t).toLowerCase(),n=!0}}function m(e,t,i){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===i||i>this.length)&&(i=this.length),i<=0)return"";if((i>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return D(this,t,i);case"utf8":case"utf-8":return R(this,t,i);case"ascii":return P(this,t,i);case"latin1":case"binary":return x(this,t,i);case"base64":return M(this,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I(this,t,i);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function v(e,t,i){var r=e[t];e[t]=e[i],e[i]=r}function C(e,t,i,r,n){if(0===e.length)return-1;if("string"==typeof i?(r=i,i=0):i>2147483647?i=2147483647:i<-2147483648&&(i=-2147483648),U(i=+i)&&(i=n?0:e.length-1),i<0&&(i=e.length+i),i>=e.length){if(n)return-1;i=e.length-1}else if(i<0){if(!n)return-1;i=0}if("string"==typeof t&&(t=l.from(t,r)),l.isBuffer(t))return 0===t.length?-1:y(e,t,i,r,n);if("number"==typeof t)return t&=255,"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,i):Uint8Array.prototype.lastIndexOf.call(e,t,i):y(e,[t],i,r,n);throw new TypeError("val must be string, number or Buffer")}function y(e,t,i,r,n){var s,o=1,a=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;o=2,a/=2,l/=2,i/=2}function c(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(n){var u=-1;for(s=i;s<a;s++)if(c(e,s)===c(t,-1===u?0:s-u)){if(-1===u&&(u=s),s-u+1===l)return u*o}else-1!==u&&(s-=s-u),u=-1}else for(i+l>a&&(i=a-l),s=i;s>=0;s--){for(var h=!0,d=0;d<l;d++)if(c(e,s+d)!==c(t,d)){h=!1;break}if(h)return s}return-1}function w(e,t,i,r){i=Number(i)||0;var n=e.length-i;r?(r=Number(r))>n&&(r=n):r=n;var s=t.length;r>s/2&&(r=s/2);for(var o=0;o<r;++o){var a=parseInt(t.substr(2*o,2),16);if(U(a))return o;e[i+o]=a}return o}function S(e,t,i,r){return B(V(t,e.length-i),e,i,r)}function b(e,t,i,r){return B(function(e){for(var t=[],i=0;i<e.length;++i)t.push(255&e.charCodeAt(i));return t}(t),e,i,r)}function E(e,t,i,r){return b(e,t,i,r)}function A(e,t,i,r){return B(H(t),e,i,r)}function T(e,t,i,r){return B(function(e,t){for(var i,r,n,s=[],o=0;o<e.length&&!((t-=2)<0);++o)r=(i=e.charCodeAt(o))>>8,n=i%256,s.push(n),s.push(r);return s}(t,e.length-i),e,i,r)}function M(e,t,i){return 0===t&&i===e.length?r.fromByteArray(e):r.fromByteArray(e.slice(t,i))}function R(e,t,i){i=Math.min(e.length,i);for(var r=[],n=t;n<i;){var s,o,a,l,c=e[n],u=null,h=c>239?4:c>223?3:c>191?2:1;if(n+h<=i)switch(h){case 1:c<128&&(u=c);break;case 2:128==(192&(s=e[n+1]))&&(l=(31&c)<<6|63&s)>127&&(u=l);break;case 3:s=e[n+1],o=e[n+2],128==(192&s)&&128==(192&o)&&(l=(15&c)<<12|(63&s)<<6|63&o)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:s=e[n+1],o=e[n+2],a=e[n+3],128==(192&s)&&128==(192&o)&&128==(192&a)&&(l=(15&c)<<18|(63&s)<<12|(63&o)<<6|63&a)>65535&&l<1114112&&(u=l)}null===u?(u=65533,h=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),n+=h}return function(e){var t=e.length;if(t<=_)return String.fromCharCode.apply(String,e);for(var i="",r=0;r<t;)i+=String.fromCharCode.apply(String,e.slice(r,r+=_));return i}(r)}t.kMaxLength=o,l.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),l.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(l.prototype,"parent",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.buffer}}),Object.defineProperty(l.prototype,"offset",{enumerable:!0,get:function(){if(l.isBuffer(this))return this.byteOffset}}),l.poolSize=8192,l.from=function(e,t,i){return c(e,t,i)},Object.setPrototypeOf(l.prototype,Uint8Array.prototype),Object.setPrototypeOf(l,Uint8Array),l.alloc=function(e,t,i){return function(e,t,i){return u(e),e<=0?a(e):void 0!==t?"string"==typeof i?a(e).fill(t,i):a(e).fill(t):a(e)}(e,t,i)},l.allocUnsafe=function(e){return h(e)},l.allocUnsafeSlow=function(e){return h(e)},l.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==l.prototype},l.compare=function(e,t){if(z(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),z(t,Uint8Array)&&(t=l.from(t,t.offset,t.byteLength)),!l.isBuffer(e)||!l.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var i=e.length,r=t.length,n=0,s=Math.min(i,r);n<s;++n)if(e[n]!==t[n]){i=e[n],r=t[n];break}return i<r?-1:r<i?1:0},l.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},l.concat=function(e,t){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return l.alloc(0);var i;if(void 0===t)for(t=0,i=0;i<e.length;++i)t+=e[i].length;var r=l.allocUnsafe(t),n=0;for(i=0;i<e.length;++i){var s=e[i];if(z(s,Uint8Array)&&(s=l.from(s)),!l.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,n),n+=s.length}return r},l.byteLength=f,l.prototype._isBuffer=!0,l.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)v(this,t,t+1);return this},l.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)v(this,t,t+3),v(this,t+1,t+2);return this},l.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)v(this,t,t+7),v(this,t+1,t+6),v(this,t+2,t+5),v(this,t+3,t+4);return this},l.prototype.toString=function(){var e=this.length;return 0===e?"":0===arguments.length?R(this,0,e):m.apply(this,arguments)},l.prototype.toLocaleString=l.prototype.toString,l.prototype.equals=function(e){if(!l.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e||0===l.compare(this,e)},l.prototype.inspect=function(){var e="",i=t.INSPECT_MAX_BYTES;return e=this.toString("hex",0,i).replace(/(.{2})/g,"$1 ").trim(),this.length>i&&(e+=" ... "),"<Buffer "+e+">"},s&&(l.prototype[s]=l.prototype.inspect),l.prototype.compare=function(e,t,i,r,n){if(z(e,Uint8Array)&&(e=l.from(e,e.offset,e.byteLength)),!l.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===i&&(i=e?e.length:0),void 0===r&&(r=0),void 0===n&&(n=this.length),t<0||i>e.length||r<0||n>this.length)throw new RangeError("out of range index");if(r>=n&&t>=i)return 0;if(r>=n)return-1;if(t>=i)return 1;if(this===e)return 0;for(var s=(n>>>=0)-(r>>>=0),o=(i>>>=0)-(t>>>=0),a=Math.min(s,o),c=this.slice(r,n),u=e.slice(t,i),h=0;h<a;++h)if(c[h]!==u[h]){s=c[h],o=u[h];break}return s<o?-1:o<s?1:0},l.prototype.includes=function(e,t,i){return-1!==this.indexOf(e,t,i)},l.prototype.indexOf=function(e,t,i){return C(this,e,t,i,!0)},l.prototype.lastIndexOf=function(e,t,i){return C(this,e,t,i,!1)},l.prototype.write=function(e,t,i,r){if(void 0===t)r="utf8",i=this.length,t=0;else if(void 0===i&&"string"==typeof t)r=t,i=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t>>>=0,isFinite(i)?(i>>>=0,void 0===r&&(r="utf8")):(r=i,i=void 0)}var n=this.length-t;if((void 0===i||i>n)&&(i=n),e.length>0&&(i<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var s=!1;;)switch(r){case"hex":return w(this,e,t,i);case"utf8":case"utf-8":return S(this,e,t,i);case"ascii":return b(this,e,t,i);case"latin1":case"binary":return E(this,e,t,i);case"base64":return A(this,e,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return T(this,e,t,i);default:if(s)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),s=!0}},l.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var _=4096;function P(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(127&e[n]);return r}function x(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(e[n]);return r}function D(e,t,i){var r=e.length;(!t||t<0)&&(t=0),(!i||i<0||i>r)&&(i=r);for(var n="",s=t;s<i;++s)n+=W[e[s]];return n}function I(e,t,i){for(var r=e.slice(t,i),n="",s=0;s<r.length;s+=2)n+=String.fromCharCode(r[s]+256*r[s+1]);return n}function L(e,t,i){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>i)throw new RangeError("Trying to access beyond buffer length")}function N(e,t,i,r,n,s){if(!l.isBuffer(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<s)throw new RangeError('"value" argument is out of bounds');if(i+r>e.length)throw new RangeError("Index out of range")}function O(e,t,i,r,n,s){if(i+r>e.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("Index out of range")}function F(e,t,i,r,s){return t=+t,i>>>=0,s||O(e,0,i,4),n.write(e,t,i,r,23,4),i+4}function k(e,t,i,r,s){return t=+t,i>>>=0,s||O(e,0,i,8),n.write(e,t,i,r,52,8),i+8}l.prototype.slice=function(e,t){var i=this.length;(e=~~e)<0?(e+=i)<0&&(e=0):e>i&&(e=i),(t=void 0===t?i:~~t)<0?(t+=i)<0&&(t=0):t>i&&(t=i),t<e&&(t=e);var r=this.subarray(e,t);return Object.setPrototypeOf(r,l.prototype),r},l.prototype.readUIntLE=function(e,t,i){e>>>=0,t>>>=0,i||L(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r},l.prototype.readUIntBE=function(e,t,i){e>>>=0,t>>>=0,i||L(e,t,this.length);for(var r=this[e+--t],n=1;t>0&&(n*=256);)r+=this[e+--t]*n;return r},l.prototype.readUInt8=function(e,t){return e>>>=0,t||L(e,1,this.length),this[e]},l.prototype.readUInt16LE=function(e,t){return e>>>=0,t||L(e,2,this.length),this[e]|this[e+1]<<8},l.prototype.readUInt16BE=function(e,t){return e>>>=0,t||L(e,2,this.length),this[e]<<8|this[e+1]},l.prototype.readUInt32LE=function(e,t){return e>>>=0,t||L(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},l.prototype.readUInt32BE=function(e,t){return e>>>=0,t||L(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},l.prototype.readIntLE=function(e,t,i){e>>>=0,t>>>=0,i||L(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r>=(n*=128)&&(r-=Math.pow(2,8*t)),r},l.prototype.readIntBE=function(e,t,i){e>>>=0,t>>>=0,i||L(e,t,this.length);for(var r=t,n=1,s=this[e+--r];r>0&&(n*=256);)s+=this[e+--r]*n;return s>=(n*=128)&&(s-=Math.pow(2,8*t)),s},l.prototype.readInt8=function(e,t){return e>>>=0,t||L(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},l.prototype.readInt16LE=function(e,t){e>>>=0,t||L(e,2,this.length);var i=this[e]|this[e+1]<<8;return 32768&i?4294901760|i:i},l.prototype.readInt16BE=function(e,t){e>>>=0,t||L(e,2,this.length);var i=this[e+1]|this[e]<<8;return 32768&i?4294901760|i:i},l.prototype.readInt32LE=function(e,t){return e>>>=0,t||L(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},l.prototype.readInt32BE=function(e,t){return e>>>=0,t||L(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},l.prototype.readFloatLE=function(e,t){return e>>>=0,t||L(e,4,this.length),n.read(this,e,!0,23,4)},l.prototype.readFloatBE=function(e,t){return e>>>=0,t||L(e,4,this.length),n.read(this,e,!1,23,4)},l.prototype.readDoubleLE=function(e,t){return e>>>=0,t||L(e,8,this.length),n.read(this,e,!0,52,8)},l.prototype.readDoubleBE=function(e,t){return e>>>=0,t||L(e,8,this.length),n.read(this,e,!1,52,8)},l.prototype.writeUIntLE=function(e,t,i,r){e=+e,t>>>=0,i>>>=0,r||N(this,e,t,i,Math.pow(2,8*i)-1,0);var n=1,s=0;for(this[t]=255&e;++s<i&&(n*=256);)this[t+s]=e/n&255;return t+i},l.prototype.writeUIntBE=function(e,t,i,r){e=+e,t>>>=0,i>>>=0,r||N(this,e,t,i,Math.pow(2,8*i)-1,0);var n=i-1,s=1;for(this[t+n]=255&e;--n>=0&&(s*=256);)this[t+n]=e/s&255;return t+i},l.prototype.writeUInt8=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,1,255,0),this[t]=255&e,t+1},l.prototype.writeUInt16LE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeUInt16BE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeUInt32LE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},l.prototype.writeUInt32BE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeIntLE=function(e,t,i,r){if(e=+e,t>>>=0,!r){var n=Math.pow(2,8*i-1);N(this,e,t,i,n-1,-n)}var s=0,o=1,a=0;for(this[t]=255&e;++s<i&&(o*=256);)e<0&&0===a&&0!==this[t+s-1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},l.prototype.writeIntBE=function(e,t,i,r){if(e=+e,t>>>=0,!r){var n=Math.pow(2,8*i-1);N(this,e,t,i,n-1,-n)}var s=i-1,o=1,a=0;for(this[t+s]=255&e;--s>=0&&(o*=256);)e<0&&0===a&&0!==this[t+s+1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},l.prototype.writeInt8=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},l.prototype.writeInt16LE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},l.prototype.writeInt16BE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},l.prototype.writeInt32LE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},l.prototype.writeInt32BE=function(e,t,i){return e=+e,t>>>=0,i||N(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},l.prototype.writeFloatLE=function(e,t,i){return F(this,e,t,!0,i)},l.prototype.writeFloatBE=function(e,t,i){return F(this,e,t,!1,i)},l.prototype.writeDoubleLE=function(e,t,i){return k(this,e,t,!0,i)},l.prototype.writeDoubleBE=function(e,t,i){return k(this,e,t,!1,i)},l.prototype.copy=function(e,t,i,r){if(!l.isBuffer(e))throw new TypeError("argument should be a Buffer");if(i||(i=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<i&&(r=i),r===i)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-i&&(r=e.length-t+i);var n=r-i;if(this===e&&"function"==typeof Uint8Array.prototype.copyWithin)this.copyWithin(t,i,r);else if(this===e&&i<t&&t<r)for(var s=n-1;s>=0;--s)e[s+t]=this[s+i];else Uint8Array.prototype.set.call(e,this.subarray(i,r),t);return n},l.prototype.fill=function(e,t,i,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,i=this.length):"string"==typeof i&&(r=i,i=this.length),void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!l.isEncoding(r))throw new TypeError("Unknown encoding: "+r);if(1===e.length){var n=e.charCodeAt(0);("utf8"===r&&n<128||"latin1"===r)&&(e=n)}}else"number"==typeof e?e&=255:"boolean"==typeof e&&(e=Number(e));if(t<0||this.length<t||this.length<i)throw new RangeError("Out of range index");if(i<=t)return this;var s;if(t>>>=0,i=void 0===i?this.length:i>>>0,e||(e=0),"number"==typeof e)for(s=t;s<i;++s)this[s]=e;else{var o=l.isBuffer(e)?e:l.from(e,r),a=o.length;if(0===a)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(s=0;s<i-t;++s)this[s+t]=o[s%a]}return this};var G=/[^+/0-9A-Za-z-_]/g;function V(e,t){var i;t=t||1/0;for(var r=e.length,n=null,s=[],o=0;o<r;++o){if((i=e.charCodeAt(o))>55295&&i<57344){if(!n){if(i>56319){(t-=3)>-1&&s.push(239,191,189);continue}if(o+1===r){(t-=3)>-1&&s.push(239,191,189);continue}n=i;continue}if(i<56320){(t-=3)>-1&&s.push(239,191,189),n=i;continue}i=65536+(n-55296<<10|i-56320)}else n&&(t-=3)>-1&&s.push(239,191,189);if(n=null,i<128){if((t-=1)<0)break;s.push(i)}else if(i<2048){if((t-=2)<0)break;s.push(i>>6|192,63&i|128)}else if(i<65536){if((t-=3)<0)break;s.push(i>>12|224,i>>6&63|128,63&i|128)}else{if(!(i<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;s.push(i>>18|240,i>>12&63|128,i>>6&63|128,63&i|128)}}return s}function H(e){return r.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(G,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function B(e,t,i,r){for(var n=0;n<r&&!(n+i>=t.length||n>=e.length);++n)t[n+i]=e[n];return n}function z(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}function U(e){return e!=e}var W=function(){for(var e="0123456789abcdef",t=new Array(256),i=0;i<16;++i)for(var r=16*i,n=0;n<16;++n)t[r+n]=e[i]+e[n];return t}()},97785(e,t,i){"use strict";var r=i(79524),n=i(64811),s=i(46255),o=i(12728);e.exports=o||r.call(s,n)},96440(e,t,i){"use strict";var r=i(79524),n=i(64811),s=i(97785);e.exports=function(){return s(r,n,arguments)}},64811(e){"use strict";e.exports=Function.prototype.apply},46255(e){"use strict";e.exports=Function.prototype.call},92427(e,t,i){"use strict";var r=i(79524),n=i(71102),s=i(46255),o=i(97785);e.exports=function(e){if(e.length<1||"function"!=typeof e[0])throw new n("a function is required");return o(r,s,e)}},12728(e){"use strict";e.exports="undefined"!=typeof Reflect&&Reflect&&Reflect.apply},17695(e,t,i){"use strict";var r=i(7755),n=i(39886),s=i(92427),o=i(96440);e.exports=function(e){var t=s(arguments),i=e.length-(arguments.length-1);return r(t,1+(i>0?i:0),!0)},n?n(e.exports,"apply",{value:o}):e.exports.apply=o},98801(e,t,i){"use strict";var r=i(49336),n=i(92427),s=n([r("%String.prototype.indexOf%")]);e.exports=function(e,t){var i=r(e,!!t);return"function"==typeof i&&s(e,".prototype.")>-1?n([i]):i}},36334(e,t,i){"use strict";var r=i(56608).Buffer,n=i(66096).Transform,s=i(64323).I,o=i(91193),a=i(26919);function l(e){n.call(this),this.hashMode="string"==typeof e,this.hashMode?this[e]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}o(l,n),l.prototype.update=function(e,t,i){var r=a(e,t),n=this._update(r);return this.hashMode?this:(i&&(n=this._toString(n,i)),n)},l.prototype.setAutoPadding=function(){},l.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},l.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},l.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},l.prototype._transform=function(e,t,i){var r;try{this.hashMode?this._update(e):this.push(this._update(e))}catch(e){r=e}finally{i(r)}},l.prototype._flush=function(e){var t;try{this.push(this.__final())}catch(e){t=e}e(t)},l.prototype._finalOrDigest=function(e){var t=this.__final()||r.alloc(0);return e&&(t=this._toString(t,e,!0)),t},l.prototype._toString=function(e,t,i){if(this._decoder||(this._decoder=new s(t),this._encoding=t),this._encoding!==t)throw new Error("can’t switch encodings");var r=this._decoder.write(e);return i&&(r+=this._decoder.end()),r},e.exports=l},44477(e){function t(){return new DOMException("The request is not allowed","NotAllowedError")}e.exports=async function(e){try{await async function(e){if(!navigator.clipboard)throw t();return navigator.clipboard.writeText(e)}(e)}catch(i){try{await async function(e){const i=document.createElement("span");i.textContent=e,i.style.whiteSpace="pre",i.style.webkitUserSelect="auto",i.style.userSelect="all",document.body.appendChild(i);const r=window.getSelection(),n=window.document.createRange();r.removeAllRanges(),n.selectNode(i),r.addRange(n);let s=!1;try{s=window.document.execCommand("copy")}finally{r.removeAllRanges(),window.document.body.removeChild(i)}if(!s)throw t()}(e)}catch(e){throw e||i||t()}}}},35284(e,t,i){"use strict";function r(e){var t,i,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(i=r(e[t]))&&(n&&(n+=" "),n+=i);else for(t in e)e[t]&&(n&&(n+=" "),n+=t);return n}i.d(t,{A:()=>n});const n=function(){for(var e,t,i=0,n="";i<arguments.length;)(e=arguments[i++])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}},89901(e){function t(e){var i,r,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var s=e.length;for(i=0;i<s;i++)e[i]&&(r=t(e[i]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function i(){for(var e,i,r=0,n="",s=arguments.length;r<s;r++)(e=arguments[r])&&(i=t(e))&&(n&&(n+=" "),n+=i);return n}e.exports=i,e.exports.clsx=i},50703(e){"use strict";e.exports=function(e){return String(e).replace(/\s+/g," ")}},99448(e,t){"use strict";t.q=function(e,t){if("string"!=typeof e)throw new TypeError("argument str must be a string");for(var r={},n=t||{},o=e.split(";"),a=n.decode||i,l=0;l<o.length;l++){var c=o[l],u=c.indexOf("=");if(!(u<0)){var h=c.substring(0,u).trim();if(null==r[h]){var d=c.substring(u+1,c.length).trim();'"'===d[0]&&(d=d.slice(1,-1)),r[h]=s(d,a)}}}return r},t.l=function(e,t,i){var s=i||{},o=s.encode||r;if("function"!=typeof o)throw new TypeError("option encode is invalid");if(!n.test(e))throw new TypeError("argument name is invalid");var a=o(t);if(a&&!n.test(a))throw new TypeError("argument val is invalid");var l=e+"="+a;if(null!=s.maxAge){var c=s.maxAge-0;if(isNaN(c)||!isFinite(c))throw new TypeError("option maxAge is invalid");l+="; Max-Age="+Math.floor(c)}if(s.domain){if(!n.test(s.domain))throw new TypeError("option domain is invalid");l+="; Domain="+s.domain}if(s.path){if(!n.test(s.path))throw new TypeError("option path is invalid");l+="; Path="+s.path}if(s.expires){if("function"!=typeof s.expires.toUTCString)throw new TypeError("option expires is invalid");l+="; Expires="+s.expires.toUTCString()}if(s.httpOnly&&(l+="; HttpOnly"),s.secure&&(l+="; Secure"),s.sameSite)switch("string"==typeof s.sameSite?s.sameSite.toLowerCase():s.sameSite){case!0:l+="; SameSite=Strict";break;case"lax":l+="; SameSite=Lax";break;case"strict":l+="; SameSite=Strict";break;case"none":l+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return l};var i=decodeURIComponent,r=encodeURIComponent,n=/^[\u0009\u0020-\u007e\u0080-\u00ff]+$/;function s(e,t){try{return t(e)}catch(t){return e}}},85877(e,t,i){i(2903),e.exports=i(96595).Object.assign},13112(e,t,i){i(81026);var r=i(96595).Object;e.exports=function(e,t){return r.create(e,t)}},30481(e,t,i){i(92611);var r=i(96595).Object;e.exports=function(e,t,i){return r.defineProperty(e,t,i)}},18307(e,t,i){i(95029),e.exports=i(96595).Object.getPrototypeOf},55111(e,t,i){i(74537),e.exports=i(96595).Object.setPrototypeOf},27773(e,t,i){i(63977),i(83149),i(78993),i(50237),e.exports=i(96595).Symbol},63315(e,t,i){i(91210),i(75505),e.exports=i(36063).f("iterator")},30322(e){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},51453(e){e.exports=function(){}},44655(e,t,i){var r=i(17482);e.exports=function(e){if(!r(e))throw TypeError(e+" is not an object!");return e}},2473(e,t,i){var r=i(51552),n=i(14326),s=i(23138);e.exports=function(e){return function(t,i,o){var a,l=r(t),c=n(l.length),u=s(o,c);if(e&&i!=i){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((e||u in l)&&l[u]===i)return e||u||0;return!e&&-1}}},6486(e){var t={}.toString;e.exports=function(e){return t.call(e).slice(8,-1)}},96595(e){var t=e.exports={version:"2.6.12"};"number"==typeof __e&&(__e=t)},64015(e,t,i){var r=i(30322);e.exports=function(e,t,i){if(r(e),void 0===t)return e;switch(i){case 1:return function(i){return e.call(t,i)};case 2:return function(i,r){return e.call(t,i,r)};case 3:return function(i,r,n){return e.call(t,i,r,n)}}return function(){return e.apply(t,arguments)}}},77095(e){e.exports=function(e){if(null==e)throw TypeError("Can't call method on  "+e);return e}},27828(e,t,i){e.exports=!i(58599)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},35299(e,t,i){var r=i(17482),n=i(79747).document,s=r(n)&&r(n.createElement);e.exports=function(e){return s?n.createElement(e):{}}},46527(e){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},94618(e,t,i){var r=i(46936),n=i(62951),s=i(60092);e.exports=function(e){var t=r(e),i=n.f;if(i)for(var o,a=i(e),l=s.f,c=0;a.length>c;)l.call(e,o=a[c++])&&t.push(o);return t}},9102(e,t,i){var r=i(79747),n=i(96595),s=i(64015),o=i(48324),a=i(21998),l="prototype",c=function(e,t,i){var u,h,d,p=e&c.F,g=e&c.G,f=e&c.S,m=e&c.P,v=e&c.B,C=e&c.W,y=g?n:n[t]||(n[t]={}),w=y[l],S=g?r:f?r[t]:(r[t]||{})[l];for(u in g&&(i=t),i)(h=!p&&S&&void 0!==S[u])&&a(y,u)||(d=h?S[u]:i[u],y[u]=g&&"function"!=typeof S[u]?i[u]:v&&h?s(d,r):C&&S[u]==d?function(e){var t=function(t,i,r){if(this instanceof e){switch(arguments.length){case 0:return new e;case 1:return new e(t);case 2:return new e(t,i)}return new e(t,i,r)}return e.apply(this,arguments)};return t[l]=e[l],t}(d):m&&"function"==typeof d?s(Function.call,d):d,m&&((y.virtual||(y.virtual={}))[u]=d,e&c.R&&w&&!w[u]&&o(w,u,d)))};c.F=1,c.G=2,c.S=4,c.P=8,c.B=16,c.W=32,c.U=64,c.R=128,e.exports=c},58599(e){e.exports=function(e){try{return!!e()}catch(e){return!0}}},79747(e){var t=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=t)},21998(e){var t={}.hasOwnProperty;e.exports=function(e,i){return t.call(e,i)}},48324(e,t,i){var r=i(10788),n=i(25995);e.exports=i(27828)?function(e,t,i){return r.f(e,t,n(1,i))}:function(e,t,i){return e[t]=i,e}},31349(e,t,i){var r=i(79747).document;e.exports=r&&r.documentElement},27941(e,t,i){e.exports=!i(27828)&&!i(58599)(function(){return 7!=Object.defineProperty(i(35299)("div"),"a",{get:function(){return 7}}).a})},6234(e,t,i){var r=i(6486);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==r(e)?e.split(""):Object(e)}},39984(e,t,i){var r=i(6486);e.exports=Array.isArray||function(e){return"Array"==r(e)}},17482(e){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},36099(e,t,i){"use strict";var r=i(69840),n=i(25995),s=i(26343),o={};i(48324)(o,i(78161)("iterator"),function(){return this}),e.exports=function(e,t,i){e.prototype=r(o,{next:n(1,i)}),s(e,t+" Iterator")}},14520(e,t,i){"use strict";var r=i(75549),n=i(9102),s=i(10058),o=i(48324),a=i(71813),l=i(36099),c=i(26343),u=i(23218),h=i(78161)("iterator"),d=!([].keys&&"next"in[].keys()),p="keys",g="values",f=function(){return this};e.exports=function(e,t,i,m,v,C,y){l(i,t,m);var w,S,b,E=function(e){if(!d&&e in R)return R[e];switch(e){case p:case g:return function(){return new i(this,e)}}return function(){return new i(this,e)}},A=t+" Iterator",T=v==g,M=!1,R=e.prototype,_=R[h]||R["@@iterator"]||v&&R[v],P=_||E(v),x=v?T?E("entries"):P:void 0,D="Array"==t&&R.entries||_;if(D&&(b=u(D.call(new e)))!==Object.prototype&&b.next&&(c(b,A,!0),r||"function"==typeof b[h]||o(b,h,f)),T&&_&&_.name!==g&&(M=!0,P=function(){return _.call(this)}),r&&!y||!d&&!M&&R[h]||o(R,h,P),a[t]=P,a[A]=f,v)if(w={values:T?P:E(g),keys:C?P:E(p),entries:x},y)for(S in w)S in R||s(R,S,w[S]);else n(n.P+n.F*(d||M),t,w);return w}},17093(e){e.exports=function(e,t){return{value:t,done:!!e}}},71813(e){e.exports={}},75549(e){e.exports=!0},26853(e,t,i){var r=i(14472)("meta"),n=i(17482),s=i(21998),o=i(10788).f,a=0,l=Object.isExtensible||function(){return!0},c=!i(58599)(function(){return l(Object.preventExtensions({}))}),u=function(e){o(e,r,{value:{i:"O"+ ++a,w:{}}})},h=e.exports={KEY:r,NEED:!1,fastKey:function(e,t){if(!n(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!s(e,r)){if(!l(e))return"F";if(!t)return"E";u(e)}return e[r].i},getWeak:function(e,t){if(!s(e,r)){if(!l(e))return!0;if(!t)return!1;u(e)}return e[r].w},onFreeze:function(e){return c&&h.NEED&&l(e)&&!s(e,r)&&u(e),e}}},33677(e,t,i){"use strict";var r=i(27828),n=i(46936),s=i(62951),o=i(60092),a=i(70749),l=i(6234),c=Object.assign;e.exports=!c||i(58599)(function(){var e={},t={},i=Symbol(),r="abcdefghijklmnopqrst";return e[i]=7,r.split("").forEach(function(e){t[e]=e}),7!=c({},e)[i]||Object.keys(c({},t)).join("")!=r})?function(e,t){for(var i=a(e),c=arguments.length,u=1,h=s.f,d=o.f;c>u;)for(var p,g=l(arguments[u++]),f=h?n(g).concat(h(g)):n(g),m=f.length,v=0;m>v;)p=f[v++],r&&!d.call(g,p)||(i[p]=g[p]);return i}:c},69840(e,t,i){var r=i(44655),n=i(50251),s=i(46527),o=i(81119)("IE_PROTO"),a=function(){},l="prototype",c=function(){var e,t=i(35299)("iframe"),r=s.length;for(t.style.display="none",i(31349).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),c=e.F;r--;)delete c[l][s[r]];return c()};e.exports=Object.create||function(e,t){var i;return null!==e?(a[l]=r(e),i=new a,a[l]=null,i[o]=e):i=c(),void 0===t?i:n(i,t)}},10788(e,t,i){var r=i(44655),n=i(27941),s=i(15873),o=Object.defineProperty;t.f=i(27828)?Object.defineProperty:function(e,t,i){if(r(e),t=s(t,!0),r(i),n)try{return o(e,t,i)}catch(e){}if("get"in i||"set"in i)throw TypeError("Accessors not supported!");return"value"in i&&(e[t]=i.value),e}},50251(e,t,i){var r=i(10788),n=i(44655),s=i(46936);e.exports=i(27828)?Object.defineProperties:function(e,t){n(e);for(var i,o=s(t),a=o.length,l=0;a>l;)r.f(e,i=o[l++],t[i]);return e}},73686(e,t,i){var r=i(60092),n=i(25995),s=i(51552),o=i(15873),a=i(21998),l=i(27941),c=Object.getOwnPropertyDescriptor;t.f=i(27828)?c:function(e,t){if(e=s(e),t=o(t,!0),l)try{return c(e,t)}catch(e){}if(a(e,t))return n(!r.f.call(e,t),e[t])}},90662(e,t,i){var r=i(51552),n=i(4788).f,s={}.toString,o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return o&&"[object Window]"==s.call(e)?function(e){try{return n(e)}catch(e){return o.slice()}}(e):n(r(e))}},4788(e,t,i){var r=i(18556),n=i(46527).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,n)}},62951(e,t){t.f=Object.getOwnPropertySymbols},23218(e,t,i){var r=i(21998),n=i(70749),s=i(81119)("IE_PROTO"),o=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=n(e),r(e,s)?e[s]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?o:null}},18556(e,t,i){var r=i(21998),n=i(51552),s=i(2473)(!1),o=i(81119)("IE_PROTO");e.exports=function(e,t){var i,a=n(e),l=0,c=[];for(i in a)i!=o&&r(a,i)&&c.push(i);for(;t.length>l;)r(a,i=t[l++])&&(~s(c,i)||c.push(i));return c}},46936(e,t,i){var r=i(18556),n=i(46527);e.exports=Object.keys||function(e){return r(e,n)}},60092(e,t){t.f={}.propertyIsEnumerable},72234(e,t,i){var r=i(9102),n=i(96595),s=i(58599);e.exports=function(e,t){var i=(n.Object||{})[e]||Object[e],o={};o[e]=t(i),r(r.S+r.F*s(function(){i(1)}),"Object",o)}},25995(e){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},10058(e,t,i){e.exports=i(48324)},9721(e,t,i){var r=i(17482),n=i(44655),s=function(e,t){if(n(e),!r(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,r){try{(r=i(64015)(Function.call,i(73686).f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,i){return s(e,i),t?e.__proto__=i:r(e,i),e}}({},!1):void 0),check:s}},26343(e,t,i){var r=i(10788).f,n=i(21998),s=i(78161)("toStringTag");e.exports=function(e,t,i){e&&!n(e=i?e:e.prototype,s)&&r(e,s,{configurable:!0,value:t})}},81119(e,t,i){var r=i(27641)("keys"),n=i(14472);e.exports=function(e){return r[e]||(r[e]=n(e))}},27641(e,t,i){var r=i(96595),n=i(79747),s="__core-js_shared__",o=n[s]||(n[s]={});(e.exports=function(e,t){return o[e]||(o[e]=void 0!==t?t:{})})("versions",[]).push({version:r.version,mode:i(75549)?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},62447(e,t,i){var r=i(29358),n=i(77095);e.exports=function(e){return function(t,i){var s,o,a=String(n(t)),l=r(i),c=a.length;return l<0||l>=c?e?"":void 0:(s=a.charCodeAt(l))<55296||s>56319||l+1===c||(o=a.charCodeAt(l+1))<56320||o>57343?e?a.charAt(l):s:e?a.slice(l,l+2):o-56320+(s-55296<<10)+65536}}},23138(e,t,i){var r=i(29358),n=Math.max,s=Math.min;e.exports=function(e,t){return(e=r(e))<0?n(e+t,0):s(e,t)}},29358(e){var t=Math.ceil,i=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?i:t)(e)}},51552(e,t,i){var r=i(6234),n=i(77095);e.exports=function(e){return r(n(e))}},14326(e,t,i){var r=i(29358),n=Math.min;e.exports=function(e){return e>0?n(r(e),9007199254740991):0}},70749(e,t,i){var r=i(77095);e.exports=function(e){return Object(r(e))}},15873(e,t,i){var r=i(17482);e.exports=function(e,t){if(!r(e))return e;var i,n;if(t&&"function"==typeof(i=e.toString)&&!r(n=i.call(e)))return n;if("function"==typeof(i=e.valueOf)&&!r(n=i.call(e)))return n;if(!t&&"function"==typeof(i=e.toString)&&!r(n=i.call(e)))return n;throw TypeError("Can't convert object to primitive value")}},14472(e){var t=0,i=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++t+i).toString(36))}},99225(e,t,i){var r=i(79747),n=i(96595),s=i(75549),o=i(36063),a=i(10788).f;e.exports=function(e){var t=n.Symbol||(n.Symbol=s?{}:r.Symbol||{});"_"==e.charAt(0)||e in t||a(t,e,{value:o.f(e)})}},36063(e,t,i){t.f=i(78161)},78161(e,t,i){var r=i(27641)("wks"),n=i(14472),s=i(79747).Symbol,o="function"==typeof s;(e.exports=function(e){return r[e]||(r[e]=o&&s[e]||(o?s:n)("Symbol."+e))}).store=r},27698(e,t,i){"use strict";var r=i(51453),n=i(17093),s=i(71813),o=i(51552);e.exports=i(14520)(Array,"Array",function(e,t){this._t=o(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,i=this._i++;return!e||i>=e.length?(this._t=void 0,n(1)):n(0,"keys"==t?i:"values"==t?e[i]:[i,e[i]])},"values"),s.Arguments=s.Array,r("keys"),r("values"),r("entries")},2903(e,t,i){var r=i(9102);r(r.S+r.F,"Object",{assign:i(33677)})},81026(e,t,i){var r=i(9102);r(r.S,"Object",{create:i(69840)})},92611(e,t,i){var r=i(9102);r(r.S+r.F*!i(27828),"Object",{defineProperty:i(10788).f})},95029(e,t,i){var r=i(70749),n=i(23218);i(72234)("getPrototypeOf",function(){return function(e){return n(r(e))}})},74537(e,t,i){var r=i(9102);r(r.S,"Object",{setPrototypeOf:i(9721).set})},83149(){},91210(e,t,i){"use strict";var r=i(62447)(!0);i(14520)(String,"String",function(e){this._t=String(e),this._i=0},function(){var e,t=this._t,i=this._i;return i>=t.length?{value:void 0,done:!0}:(e=r(t,i),this._i+=e.length,{value:e,done:!1})})},63977(e,t,i){"use strict";var r=i(79747),n=i(21998),s=i(27828),o=i(9102),a=i(10058),l=i(26853).KEY,c=i(58599),u=i(27641),h=i(26343),d=i(14472),p=i(78161),g=i(36063),f=i(99225),m=i(94618),v=i(39984),C=i(44655),y=i(17482),w=i(70749),S=i(51552),b=i(15873),E=i(25995),A=i(69840),T=i(90662),M=i(73686),R=i(62951),_=i(10788),P=i(46936),x=M.f,D=_.f,I=T.f,L=r.Symbol,N=r.JSON,O=N&&N.stringify,F="prototype",k=p("_hidden"),G=p("toPrimitive"),V={}.propertyIsEnumerable,H=u("symbol-registry"),B=u("symbols"),z=u("op-symbols"),U=Object[F],W="function"==typeof L&&!!R.f,j=r.QObject,K=!j||!j[F]||!j[F].findChild,$=s&&c(function(){return 7!=A(D({},"a",{get:function(){return D(this,"a",{value:7}).a}})).a})?function(e,t,i){var r=x(U,t);r&&delete U[t],D(e,t,i),r&&e!==U&&D(U,t,r)}:D,q=function(e){var t=B[e]=A(L[F]);return t._k=e,t},Y=W&&"symbol"==typeof L.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof L},Q=function(e,t,i){return e===U&&Q(z,t,i),C(e),t=b(t,!0),C(i),n(B,t)?(i.enumerable?(n(e,k)&&e[k][t]&&(e[k][t]=!1),i=A(i,{enumerable:E(0,!1)})):(n(e,k)||D(e,k,E(1,{})),e[k][t]=!0),$(e,t,i)):D(e,t,i)},X=function(e,t){C(e);for(var i,r=m(t=S(t)),n=0,s=r.length;s>n;)Q(e,i=r[n++],t[i]);return e},Z=function(e){var t=V.call(this,e=b(e,!0));return!(this===U&&n(B,e)&&!n(z,e))&&(!(t||!n(this,e)||!n(B,e)||n(this,k)&&this[k][e])||t)},J=function(e,t){if(e=S(e),t=b(t,!0),e!==U||!n(B,t)||n(z,t)){var i=x(e,t);return!i||!n(B,t)||n(e,k)&&e[k][t]||(i.enumerable=!0),i}},ee=function(e){for(var t,i=I(S(e)),r=[],s=0;i.length>s;)n(B,t=i[s++])||t==k||t==l||r.push(t);return r},te=function(e){for(var t,i=e===U,r=I(i?z:S(e)),s=[],o=0;r.length>o;)!n(B,t=r[o++])||i&&!n(U,t)||s.push(B[t]);return s};W||(L=function(){if(this instanceof L)throw TypeError("Symbol is not a constructor!");var e=d(arguments.length>0?arguments[0]:void 0),t=function(i){this===U&&t.call(z,i),n(this,k)&&n(this[k],e)&&(this[k][e]=!1),$(this,e,E(1,i))};return s&&K&&$(U,e,{configurable:!0,set:t}),q(e)},a(L[F],"toString",function(){return this._k}),M.f=J,_.f=Q,i(4788).f=T.f=ee,i(60092).f=Z,R.f=te,s&&!i(75549)&&a(U,"propertyIsEnumerable",Z,!0),g.f=function(e){return q(p(e))}),o(o.G+o.W+o.F*!W,{Symbol:L});for(var ie="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),re=0;ie.length>re;)p(ie[re++]);for(var ne=P(p.store),se=0;ne.length>se;)f(ne[se++]);o(o.S+o.F*!W,"Symbol",{for:function(e){return n(H,e+="")?H[e]:H[e]=L(e)},keyFor:function(e){if(!Y(e))throw TypeError(e+" is not a symbol!");for(var t in H)if(H[t]===e)return t},useSetter:function(){K=!0},useSimple:function(){K=!1}}),o(o.S+o.F*!W,"Object",{create:function(e,t){return void 0===t?A(e):X(A(e),t)},defineProperty:Q,defineProperties:X,getOwnPropertyDescriptor:J,getOwnPropertyNames:ee,getOwnPropertySymbols:te});var oe=c(function(){R.f(1)});o(o.S+o.F*oe,"Object",{getOwnPropertySymbols:function(e){return R.f(w(e))}}),N&&o(o.S+o.F*(!W||c(function(){var e=L();return"[null]"!=O([e])||"{}"!=O({a:e})||"{}"!=O(Object(e))})),"JSON",{stringify:function(e){for(var t,i,r=[e],n=1;arguments.length>n;)r.push(arguments[n++]);if(i=t=r[1],(y(t)||void 0!==e)&&!Y(e))return v(t)||(t=function(e,t){if("function"==typeof i&&(t=i.call(this,e,t)),!Y(t))return t}),r[1]=t,O.apply(N,r)}}),L[F][G]||i(48324)(L[F],G,L[F].valueOf),h(L,"Symbol"),h(Math,"Math",!0),h(r.JSON,"JSON",!0)},78993(e,t,i){i(99225)("asyncIterator")},50237(e,t,i){i(99225)("observable")},75505(e,t,i){i(27698);for(var r=i(79747),n=i(48324),s=i(71813),o=i(78161)("toStringTag"),a="CSSRuleList,CSSStyleDeclaration,CSSValueList,ClientRectList,DOMRectList,DOMStringList,DOMTokenList,DataTransferItemList,FileList,HTMLAllCollection,HTMLCollection,HTMLFormElement,HTMLSelectElement,MediaList,MimeTypeArray,NamedNodeMap,NodeList,PaintRequestList,Plugin,PluginArray,SVGLengthList,SVGNumberList,SVGPathSegList,SVGPointList,SVGStringList,SVGTransformList,SourceBufferList,StyleSheetList,TextTrackCueList,TextTrackList,TouchList".split(","),l=0;l<a.length;l++){var c=a[l],u=r[c],h=u&&u.prototype;h&&!h[o]&&n(h,o,c),s[c]=s.Array}},41166(e,t,i){function r(e){return Object.prototype.toString.call(e)}t.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===r(e)},t.isBoolean=function(e){return"boolean"==typeof e},t.isNull=function(e){return null===e},t.isNullOrUndefined=function(e){return null==e},t.isNumber=function(e){return"number"==typeof e},t.isString=function(e){return"string"==typeof e},t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=function(e){return void 0===e},t.isRegExp=function(e){return"[object RegExp]"===r(e)},t.isObject=function(e){return"object"==typeof e&&null!==e},t.isDate=function(e){return"[object Date]"===r(e)},t.isError=function(e){return"[object Error]"===r(e)||e instanceof Error},t.isFunction=function(e){return"function"==typeof e},t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=i(77511).Buffer.isBuffer},29520(e,t,i){var r=i(23071),n=i(5630);e.exports=function(e){return new o(e)};var s={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};function o(e){this.curveType=s[e],this.curveType||(this.curveType={name:e}),this.curve=new r.ec(this.curveType.name),this.keys=void 0}function a(e,t,i){Array.isArray(e)||(e=e.toArray());var r=new Buffer(e);if(i&&r.length<i){var n=new Buffer(i-r.length);n.fill(0),r=Buffer.concat([n,r])}return t?r.toString(t):r}s.p224=s.secp224r1,s.p256=s.secp256r1=s.prime256v1,s.p192=s.secp192r1=s.prime192v1,s.p384=s.secp384r1,s.p521=s.secp521r1,o.prototype.generateKeys=function(e,t){return this.keys=this.curve.genKeyPair(),this.getPublicKey(e,t)},o.prototype.computeSecret=function(e,t,i){return t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t)),a(this.curve.keyFromPublic(e).getPublic().mul(this.keys.getPrivate()).getX(),i,this.curveType.byteLength)},o.prototype.getPublicKey=function(e,t){var i=this.keys.getPublic("compressed"===t,!0);return"hybrid"===t&&(i[i.length-1]%2?i[0]=7:i[0]=6),a(i,e)},o.prototype.getPrivateKey=function(e){return a(this.keys.getPrivate(),e)},o.prototype.setPublicKey=function(e,t){return t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t)),this.keys._importPublic(e),this},o.prototype.setPrivateKey=function(e,t){t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t));var i=new n(e);return i=i.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(i),this}},18955(e,t,i){"use strict";var r=i(91193),n=i(75035),s=i(47795),o=i(99041),a=i(36334);function l(e){a.call(this,"digest"),this._hash=e}r(l,a),l.prototype._update=function(e){this._hash.update(e)},l.prototype._final=function(){return this._hash.digest()},e.exports=function(e){return"md5"===(e=e.toLowerCase())?new n:"rmd160"===e||"ripemd160"===e?new s:new l(o(e))}},46159(e,t,i){var r=i(75035);e.exports=function(e){return(new r).update(e).digest()}},33053(e,t,i){"use strict";var r=i(91193),n=i(78289),s=i(36334),o=i(56608).Buffer,a=i(46159),l=i(47795),c=i(99041),u=o.alloc(128);function h(e,t){s.call(this,"digest"),"string"==typeof t&&(t=o.from(t));var i="sha512"===e||"sha384"===e?128:64;this._alg=e,this._key=t,t.length>i?t=("rmd160"===e?new l:c(e)).update(t).digest():t.length<i&&(t=o.concat([t,u],i));for(var r=this._ipad=o.allocUnsafe(i),n=this._opad=o.allocUnsafe(i),a=0;a<i;a++)r[a]=54^t[a],n[a]=92^t[a];this._hash="rmd160"===e?new l:c(e),this._hash.update(r)}r(h,s),h.prototype._update=function(e){this._hash.update(e)},h.prototype._final=function(){var e=this._hash.digest();return("rmd160"===this._alg?new l:c(this._alg)).update(this._opad).update(e).digest()},e.exports=function(e,t){return"rmd160"===(e=e.toLowerCase())||"ripemd160"===e?new h("rmd160",t):"md5"===e?new n(a,t):new h(e,t)}},78289(e,t,i){"use strict";var r=i(91193),n=i(56608).Buffer,s=i(36334),o=n.alloc(128),a=64;function l(e,t){s.call(this,"digest"),"string"==typeof t&&(t=n.from(t)),this._alg=e,this._key=t,t.length>a?t=e(t):t.length<a&&(t=n.concat([t,o],a));for(var i=this._ipad=n.allocUnsafe(a),r=this._opad=n.allocUnsafe(a),l=0;l<a;l++)i[l]=54^t[l],r[l]=92^t[l];this._hash=[i]}r(l,s),l.prototype._update=function(e){this._hash.push(e)},l.prototype._final=function(){var e=this._alg(n.concat(this._hash));return this._alg(n.concat([this._opad,e]))},e.exports=l},24215(e,t,i){"use strict";t.randomBytes=t.rng=t.pseudoRandomBytes=t.prng=i(82869),t.createHash=t.Hash=i(18955),t.createHmac=t.Hmac=i(33053);var r=i(92761),n=Object.keys(r),s=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(n);t.getHashes=function(){return s};var o=i(46375);t.pbkdf2=o.pbkdf2,t.pbkdf2Sync=o.pbkdf2Sync;var a=i(18350);t.Cipher=a.Cipher,t.createCipher=a.createCipher,t.Cipheriv=a.Cipheriv,t.createCipheriv=a.createCipheriv,t.Decipher=a.Decipher,t.createDecipher=a.createDecipher,t.Decipheriv=a.Decipheriv,t.createDecipheriv=a.createDecipheriv,t.getCiphers=a.getCiphers,t.listCiphers=a.listCiphers;var l=i(35835);t.DiffieHellmanGroup=l.DiffieHellmanGroup,t.createDiffieHellmanGroup=l.createDiffieHellmanGroup,t.getDiffieHellman=l.getDiffieHellman,t.createDiffieHellman=l.createDiffieHellman,t.DiffieHellman=l.DiffieHellman;var c=i(80206);t.createSign=c.createSign,t.Sign=c.Sign,t.createVerify=c.createVerify,t.Verify=c.Verify,t.createECDH=i(29520);var u=i(32211);t.publicEncrypt=u.publicEncrypt,t.privateEncrypt=u.privateEncrypt,t.publicDecrypt=u.publicDecrypt,t.privateDecrypt=u.privateDecrypt;var h=i(44925);t.randomFill=h.randomFill,t.randomFillSync=h.randomFillSync,t.createCredentials=function(){throw new Error("sorry, createCredentials is not implemented yet\nwe accept pull requests\nhttps://github.com/browserify/crypto-browserify")},t.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}},60095(e,t,i){var r;e.exports=(r=r||function(e){var t;if("undefined"!=typeof window&&window.crypto&&(t=window.crypto),"undefined"!=typeof self&&self.crypto&&(t=self.crypto),"undefined"!=typeof globalThis&&globalThis.crypto&&(t=globalThis.crypto),!t&&"undefined"!=typeof window&&window.msCrypto&&(t=window.msCrypto),!t&&"undefined"!=typeof globalThis&&globalThis.crypto&&(t=globalThis.crypto),!t)try{t=i(57167)}catch(e){}var r=function(){if(t){if("function"==typeof t.getRandomValues)try{return t.getRandomValues(new Uint32Array(1))[0]}catch(e){}if("function"==typeof t.randomBytes)try{return t.randomBytes(4).readInt32LE()}catch(e){}}throw new Error("Native crypto module could not be used to get secure random number.")},n=Object.create||function(){function e(){}return function(t){var i;return e.prototype=t,i=new e,e.prototype=null,i}}(),s={},o=s.lib={},a=o.Base={extend:function(e){var t=n(this);return e&&t.mixIn(e),t.hasOwnProperty("init")&&this.init!==t.init||(t.init=function(){t.$super.init.apply(this,arguments)}),t.init.prototype=t,t.$super=this,t},create:function(){var e=this.extend();return e.init.apply(e,arguments),e},init:function(){},mixIn:function(e){for(var t in e)e.hasOwnProperty(t)&&(this[t]=e[t]);e.hasOwnProperty("toString")&&(this.toString=e.toString)},clone:function(){return this.init.prototype.extend(this)}},l=o.WordArray=a.extend({init:function(e,t){e=this.words=e||[],this.sigBytes=null!=t?t:4*e.length},toString:function(e){return(e||u).stringify(this)},concat:function(e){var t=this.words,i=e.words,r=this.sigBytes,n=e.sigBytes;if(this.clamp(),r%4)for(var s=0;s<n;s++){var o=i[s>>>2]>>>24-s%4*8&255;t[r+s>>>2]|=o<<24-(r+s)%4*8}else for(var a=0;a<n;a+=4)t[r+a>>>2]=i[a>>>2];return this.sigBytes+=n,this},clamp:function(){var t=this.words,i=this.sigBytes;t[i>>>2]&=4294967295<<32-i%4*8,t.length=e.ceil(i/4)},clone:function(){var e=a.clone.call(this);return e.words=this.words.slice(0),e},random:function(e){for(var t=[],i=0;i<e;i+=4)t.push(r());return new l.init(t,e)}}),c=s.enc={},u=c.Hex={stringify:function(e){for(var t=e.words,i=e.sigBytes,r=[],n=0;n<i;n++){var s=t[n>>>2]>>>24-n%4*8&255;r.push((s>>>4).toString(16)),r.push((15&s).toString(16))}return r.join("")},parse:function(e){for(var t=e.length,i=[],r=0;r<t;r+=2)i[r>>>3]|=parseInt(e.substr(r,2),16)<<24-r%8*4;return new l.init(i,t/2)}},h=c.Latin1={stringify:function(e){for(var t=e.words,i=e.sigBytes,r=[],n=0;n<i;n++){var s=t[n>>>2]>>>24-n%4*8&255;r.push(String.fromCharCode(s))}return r.join("")},parse:function(e){for(var t=e.length,i=[],r=0;r<t;r++)i[r>>>2]|=(255&e.charCodeAt(r))<<24-r%4*8;return new l.init(i,t)}},d=c.Utf8={stringify:function(e){try{return decodeURIComponent(escape(h.stringify(e)))}catch(e){throw new Error("Malformed UTF-8 data")}},parse:function(e){return h.parse(unescape(encodeURIComponent(e)))}},p=o.BufferedBlockAlgorithm=a.extend({reset:function(){this._data=new l.init,this._nDataBytes=0},_append:function(e){"string"==typeof e&&(e=d.parse(e)),this._data.concat(e),this._nDataBytes+=e.sigBytes},_process:function(t){var i,r=this._data,n=r.words,s=r.sigBytes,o=this.blockSize,a=s/(4*o),c=(a=t?e.ceil(a):e.max((0|a)-this._minBufferSize,0))*o,u=e.min(4*c,s);if(c){for(var h=0;h<c;h+=o)this._doProcessBlock(n,h);i=n.splice(0,c),r.sigBytes-=u}return new l.init(i,u)},clone:function(){var e=a.clone.call(this);return e._data=this._data.clone(),e},_minBufferSize:0}),g=(o.Hasher=p.extend({cfg:a.extend(),init:function(e){this.cfg=this.cfg.extend(e),this.reset()},reset:function(){p.reset.call(this),this._doReset()},update:function(e){return this._append(e),this._process(),this},finalize:function(e){return e&&this._append(e),this._doFinalize()},blockSize:16,_createHelper:function(e){return function(t,i){return new e.init(i).finalize(t)}},_createHmacHelper:function(e){return function(t,i){return new g.HMAC.init(e,i).finalize(t)}}}),s.algo={});return s}(Math),r)},81716(e,t,i){var r,n,s;e.exports=(r=i(60095),s=(n=r).lib.WordArray,n.enc.Base64={stringify:function(e){var t=e.words,i=e.sigBytes,r=this._map;e.clamp();for(var n=[],s=0;s<i;s+=3)for(var o=(t[s>>>2]>>>24-s%4*8&255)<<16|(t[s+1>>>2]>>>24-(s+1)%4*8&255)<<8|t[s+2>>>2]>>>24-(s+2)%4*8&255,a=0;a<4&&s+.75*a<i;a++)n.push(r.charAt(o>>>6*(3-a)&63));var l=r.charAt(64);if(l)for(;n.length%4;)n.push(l);return n.join("")},parse:function(e){var t=e.length,i=this._map,r=this._reverseMap;if(!r){r=this._reverseMap=[];for(var n=0;n<i.length;n++)r[i.charCodeAt(n)]=n}var o=i.charAt(64);if(o){var a=e.indexOf(o);-1!==a&&(t=a)}return function(e,t,i){for(var r=[],n=0,o=0;o<t;o++)if(o%4){var a=i[e.charCodeAt(o-1)]<<o%4*2|i[e.charCodeAt(o)]>>>6-o%4*2;r[n>>>2]|=a<<24-n%4*8,n++}return s.create(r,n)}(e,t,r)},_map:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="},r.enc.Base64)},31939(e,t,i){var r;e.exports=(r=i(60095),i(9331),i(55979),r.HmacSHA256)},55979(e,t,i){var r,n,s;e.exports=(n=(r=i(60095)).lib.Base,s=r.enc.Utf8,void(r.algo.HMAC=n.extend({init:function(e,t){e=this._hasher=new e.init,"string"==typeof t&&(t=s.parse(t));var i=e.blockSize,r=4*i;t.sigBytes>r&&(t=e.finalize(t)),t.clamp();for(var n=this._oKey=t.clone(),o=this._iKey=t.clone(),a=n.words,l=o.words,c=0;c<i;c++)a[c]^=1549556828,l[c]^=909522486;n.sigBytes=o.sigBytes=r,this.reset()},reset:function(){var e=this._hasher;e.reset(),e.update(this._iKey)},update:function(e){return this._hasher.update(e),this},finalize:function(e){var t=this._hasher,i=t.finalize(e);return t.reset(),t.finalize(this._oKey.clone().concat(i))}})))},74842(e,t,i){var r;e.exports=(r=i(60095),function(){if("function"==typeof ArrayBuffer){var e=r.lib.WordArray,t=e.init,i=e.init=function(e){if(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),(e instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array||e instanceof Float64Array)&&(e=new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),e instanceof Uint8Array){for(var i=e.byteLength,r=[],n=0;n<i;n++)r[n>>>2]|=e[n]<<24-n%4*8;t.call(this,r,i)}else t.apply(this,arguments)};i.prototype=e}}(),r.lib.WordArray)},9331(e,t,i){var r;e.exports=(r=i(60095),function(e){var t=r,i=t.lib,n=i.WordArray,s=i.Hasher,o=t.algo,a=[],l=[];!function(){function t(t){for(var i=e.sqrt(t),r=2;r<=i;r++)if(!(t%r))return!1;return!0}function i(e){return 4294967296*(e-(0|e))|0}for(var r=2,n=0;n<64;)t(r)&&(n<8&&(a[n]=i(e.pow(r,.5))),l[n]=i(e.pow(r,1/3)),n++),r++}();var c=[],u=o.SHA256=s.extend({_doReset:function(){this._hash=new n.init(a.slice(0))},_doProcessBlock:function(e,t){for(var i=this._hash.words,r=i[0],n=i[1],s=i[2],o=i[3],a=i[4],u=i[5],h=i[6],d=i[7],p=0;p<64;p++){if(p<16)c[p]=0|e[t+p];else{var g=c[p-15],f=(g<<25|g>>>7)^(g<<14|g>>>18)^g>>>3,m=c[p-2],v=(m<<15|m>>>17)^(m<<13|m>>>19)^m>>>10;c[p]=f+c[p-7]+v+c[p-16]}var C=r&n^r&s^n&s,y=(r<<30|r>>>2)^(r<<19|r>>>13)^(r<<10|r>>>22),w=d+((a<<26|a>>>6)^(a<<21|a>>>11)^(a<<7|a>>>25))+(a&u^~a&h)+l[p]+c[p];d=h,h=u,u=a,a=o+w|0,o=s,s=n,n=r,r=w+(y+C)|0}i[0]=i[0]+r|0,i[1]=i[1]+n|0,i[2]=i[2]+s|0,i[3]=i[3]+o|0,i[4]=i[4]+a|0,i[5]=i[5]+u|0,i[6]=i[6]+h|0,i[7]=i[7]+d|0},_doFinalize:function(){var t=this._data,i=t.words,r=8*this._nDataBytes,n=8*t.sigBytes;return i[n>>>5]|=128<<24-n%32,i[14+(n+64>>>9<<4)]=e.floor(r/4294967296),i[15+(n+64>>>9<<4)]=r,t.sigBytes=4*i.length,this._process(),this._hash},clone:function(){var e=s.clone.call(this);return e._hash=this._hash.clone(),e}});t.SHA256=s._createHelper(u),t.HmacSHA256=s._createHmacHelper(u)}(Math),r.SHA256)},83160(e,t,i){"use strict";i.d(t,{cO:()=>ie,mR:()=>C,u8:()=>Q});var r=i(42346),n=i(72432),s="",o="",a="",l="",c=r.A&&"ontouchstart"in document.documentElement;if(r.A){var u={Moz:"-moz-",ms:"-ms-",O:"-o-",Webkit:"-webkit-"},h=document.createElement("p").style;for(var d in u)if(d+"Transform"in h){s=d,o=u[d];break}"Webkit"===s&&"msHyphens"in h&&(s="ms",o=u.ms,l="edge"),"Webkit"===s&&"-apple-trailing-word"in h&&(a="apple")}var p=s,g=o,f=a,m=l,v=c;function C(e){return"-"===e[1]||"ms"===p?e:"@"+g+"keyframes"+e.substr(10)}var y={noPrefill:["appearance"],supportedProperty:function(e){return"appearance"===e&&("ms"===p?"-webkit-"+e:g+e)}},w={noPrefill:["color-adjust"],supportedProperty:function(e){return"color-adjust"===e&&("Webkit"===p?g+"print-"+e:e)}},S=/[-\s]+(.)?/g;function b(e,t){return t?t.toUpperCase():""}function E(e){return e.replace(S,b)}function A(e){return E("-"+e)}var T,M={noPrefill:["mask"],supportedProperty:function(e,t){if(!/^mask/.test(e))return!1;if("Webkit"===p){var i="mask-image";if(E(i)in t)return e;if(p+A(i)in t)return g+e}return e}},R={noPrefill:["text-orientation"],supportedProperty:function(e){return"text-orientation"===e&&("apple"!==f||v?e:g+e)}},_={noPrefill:["transform"],supportedProperty:function(e,t,i){return"transform"===e&&(i.transform?e:g+e)}},P={noPrefill:["transition"],supportedProperty:function(e,t,i){return"transition"===e&&(i.transition?e:g+e)}},x={noPrefill:["writing-mode"],supportedProperty:function(e){return"writing-mode"===e&&("Webkit"===p||"ms"===p&&"edge"!==m?g+e:e)}},D={noPrefill:["user-select"],supportedProperty:function(e){return"user-select"===e&&("Moz"===p||"ms"===p||"apple"===f?g+e:e)}},I={supportedProperty:function(e,t){return!!/^break-/.test(e)&&("Webkit"===p?"WebkitColumn"+A(e)in t&&g+"column-"+e:"Moz"===p&&"page"+A(e)in t&&"page-"+e)}},L={supportedProperty:function(e,t){if(!/^(border|margin|padding)-inline/.test(e))return!1;if("Moz"===p)return e;var i=e.replace("-inline","");return p+A(i)in t&&g+i}},N={supportedProperty:function(e,t){return E(e)in t&&e}},O={supportedProperty:function(e,t){var i=A(e);return"-"===e[0]||"-"===e[0]&&"-"===e[1]?e:p+i in t?g+e:"Webkit"!==p&&"Webkit"+i in t&&"-webkit-"+e}},F={supportedProperty:function(e){return"scroll-snap"===e.substring(0,11)&&("ms"===p?""+g+e:e)}},k={supportedProperty:function(e){return"overscroll-behavior"===e&&("ms"===p?g+"scroll-chaining":e)}},G={"flex-grow":"flex-positive","flex-shrink":"flex-negative","flex-basis":"flex-preferred-size","justify-content":"flex-pack",order:"flex-order","align-items":"flex-align","align-content":"flex-line-pack"},V={supportedProperty:function(e,t){var i=G[e];return!!i&&p+A(i)in t&&g+i}},H={flex:"box-flex","flex-grow":"box-flex","flex-direction":["box-orient","box-direction"],order:"box-ordinal-group","align-items":"box-align","flex-flow":["box-orient","box-direction"],"justify-content":"box-pack"},B=Object.keys(H),z=function(e){return g+e},U={supportedProperty:function(e,t,i){var r=i.multiple;if(B.indexOf(e)>-1){var n=H[e];if(!Array.isArray(n))return p+A(n)in t&&g+n;if(!r)return!1;for(var s=0;s<n.length;s++)if(!(p+A(n[0])in t))return!1;return n.map(z)}return!1}},W=[y,w,M,R,_,P,x,D,I,L,N,O,F,k,V,U],j=W.filter(function(e){return e.supportedProperty}).map(function(e){return e.supportedProperty}),K=W.filter(function(e){return e.noPrefill}).reduce(function(e,t){return e.push.apply(e,(0,n.A)(t.noPrefill)),e},[]),$={};if(r.A){T=document.createElement("p");var q=window.getComputedStyle(document.documentElement,"");for(var Y in q)isNaN(Y)||($[q[Y]]=q[Y]);K.forEach(function(e){return delete $[e]})}function Q(e,t){if(void 0===t&&(t={}),!T)return e;if(null!=$[e])return $[e];"transition"!==e&&"transform"!==e||(t[e]=e in T.style);for(var i=0;i<j.length&&($[e]=j[i](e,T.style,t),!$[e]);i++);try{T.style[e]=""}catch(e){return!1}return $[e]}var X,Z={},J={transition:1,"transition-property":1,"-webkit-transition":1,"-webkit-transition-property":1},ee=/(^\s*[\w-]+)|, (\s*[\w-]+)(?![^()]*\))/g;function te(e,t,i){return"var"===t?"var":"all"===t?"all":"all"===i?", all":(t?Q(t):", "+Q(i))||t||i}function ie(e,t){var i=t;if(!X||"content"===e)return t;if("string"!=typeof i||!isNaN(parseInt(i,10)))return i;var r=e+i;if(null!=Z[r])return Z[r];try{X.style[e]=i}catch(e){return Z[r]=!1,!1}if(J[e])i=i.replace(ee,te);else if(""===X.style[e]&&("-ms-flex"===(i=g+i)&&(X.style[e]="-ms-flexbox"),X.style[e]=i,""===X.style[e]))return Z[r]=!1,!1;return X.style[e]="",Z[r]=i,Z[r]}r.A&&(X=document.createElement("p"))},18814(e){e.exports=function(){"use strict";var e=6e4,t=36e5,i="millisecond",r="second",n="minute",s="hour",o="day",a="week",l="month",c="quarter",u="year",h="date",d="Invalid Date",p=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,g=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,f={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],i=e%100;return"["+e+(t[(i-20)%10]||t[i]||t[0])+"]"}},m=function(e,t,i){var r=String(e);return!r||r.length>=t?e:""+Array(t+1-r.length).join(i)+e},v={s:m,z:function(e){var t=-e.utcOffset(),i=Math.abs(t),r=Math.floor(i/60),n=i%60;return(t<=0?"+":"-")+m(r,2,"0")+":"+m(n,2,"0")},m:function e(t,i){if(t.date()<i.date())return-e(i,t);var r=12*(i.year()-t.year())+(i.month()-t.month()),n=t.clone().add(r,l),s=i-n<0,o=t.clone().add(r+(s?-1:1),l);return+(-(r+(i-n)/(s?n-o:o-n))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:l,y:u,w:a,d:o,D:h,h:s,m:n,s:r,ms:i,Q:c}[e]||String(e||"").toLowerCase().replace(/s$/,"")},u:function(e){return void 0===e}},C="en",y={};y[C]=f;var w="$isDayjsObject",S=function(e){return e instanceof T||!(!e||!e[w])},b=function e(t,i,r){var n;if(!t)return C;if("string"==typeof t){var s=t.toLowerCase();y[s]&&(n=s),i&&(y[s]=i,n=s);var o=t.split("-");if(!n&&o.length>1)return e(o[0])}else{var a=t.name;y[a]=t,n=a}return!r&&n&&(C=n),n||!r&&C},E=function(e,t){if(S(e))return e.clone();var i="object"==typeof t?t:{};return i.date=e,i.args=arguments,new T(i)},A=v;A.l=b,A.i=S,A.w=function(e,t){return E(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var T=function(){function f(e){this.$L=b(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[w]=!0}var m=f.prototype;return m.parse=function(e){this.$d=function(e){var t=e.date,i=e.utc;if(null===t)return new Date(NaN);if(A.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var r=t.match(p);if(r){var n=r[2]-1||0,s=(r[7]||"0").substring(0,3);return i?new Date(Date.UTC(r[1],n,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],n,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(t)}(e),this.init()},m.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},m.$utils=function(){return A},m.isValid=function(){return!(this.$d.toString()===d)},m.isSame=function(e,t){var i=E(e);return this.startOf(t)<=i&&i<=this.endOf(t)},m.isAfter=function(e,t){return E(e)<this.startOf(t)},m.isBefore=function(e,t){return this.endOf(t)<E(e)},m.$g=function(e,t,i){return A.u(e)?this[t]:this.set(i,e)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(e,t){var i=this,c=!!A.u(t)||t,d=A.p(e),p=function(e,t){var r=A.w(i.$u?Date.UTC(i.$y,t,e):new Date(i.$y,t,e),i);return c?r:r.endOf(o)},g=function(e,t){return A.w(i.toDate()[e].apply(i.toDate("s"),(c?[0,0,0,0]:[23,59,59,999]).slice(t)),i)},f=this.$W,m=this.$M,v=this.$D,C="set"+(this.$u?"UTC":"");switch(d){case u:return c?p(1,0):p(31,11);case l:return c?p(1,m):p(0,m+1);case a:var y=this.$locale().weekStart||0,w=(f<y?f+7:f)-y;return p(c?v-w:v+(6-w),m);case o:case h:return g(C+"Hours",0);case s:return g(C+"Minutes",1);case n:return g(C+"Seconds",2);case r:return g(C+"Milliseconds",3);default:return this.clone()}},m.endOf=function(e){return this.startOf(e,!1)},m.$set=function(e,t){var a,c=A.p(e),d="set"+(this.$u?"UTC":""),p=(a={},a[o]=d+"Date",a[h]=d+"Date",a[l]=d+"Month",a[u]=d+"FullYear",a[s]=d+"Hours",a[n]=d+"Minutes",a[r]=d+"Seconds",a[i]=d+"Milliseconds",a)[c],g=c===o?this.$D+(t-this.$W):t;if(c===l||c===u){var f=this.clone().set(h,1);f.$d[p](g),f.init(),this.$d=f.set(h,Math.min(this.$D,f.daysInMonth())).$d}else p&&this.$d[p](g);return this.init(),this},m.set=function(e,t){return this.clone().$set(e,t)},m.get=function(e){return this[A.p(e)]()},m.add=function(i,c){var h,d=this;i=Number(i);var p=A.p(c),g=function(e){var t=E(d);return A.w(t.date(t.date()+Math.round(e*i)),d)};if(p===l)return this.set(l,this.$M+i);if(p===u)return this.set(u,this.$y+i);if(p===o)return g(1);if(p===a)return g(7);var f=(h={},h[n]=e,h[s]=t,h[r]=1e3,h)[p]||1,m=this.$d.getTime()+i*f;return A.w(m,this)},m.subtract=function(e,t){return this.add(-1*e,t)},m.format=function(e){var t=this,i=this.$locale();if(!this.isValid())return i.invalidDate||d;var r=e||"YYYY-MM-DDTHH:mm:ssZ",n=A.z(this),s=this.$H,o=this.$m,a=this.$M,l=i.weekdays,c=i.months,u=i.meridiem,h=function(e,i,n,s){return e&&(e[i]||e(t,r))||n[i].slice(0,s)},p=function(e){return A.s(s%12||12,e,"0")},f=u||function(e,t,i){var r=e<12?"AM":"PM";return i?r.toLowerCase():r};return r.replace(g,function(e,r){return r||function(e){switch(e){case"YY":return String(t.$y).slice(-2);case"YYYY":return A.s(t.$y,4,"0");case"M":return a+1;case"MM":return A.s(a+1,2,"0");case"MMM":return h(i.monthsShort,a,c,3);case"MMMM":return h(c,a);case"D":return t.$D;case"DD":return A.s(t.$D,2,"0");case"d":return String(t.$W);case"dd":return h(i.weekdaysMin,t.$W,l,2);case"ddd":return h(i.weekdaysShort,t.$W,l,3);case"dddd":return l[t.$W];case"H":return String(s);case"HH":return A.s(s,2,"0");case"h":return p(1);case"hh":return p(2);case"a":return f(s,o,!0);case"A":return f(s,o,!1);case"m":return String(o);case"mm":return A.s(o,2,"0");case"s":return String(t.$s);case"ss":return A.s(t.$s,2,"0");case"SSS":return A.s(t.$ms,3,"0");case"Z":return n}return null}(e)||n.replace(":","")})},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(i,h,d){var p,g=this,f=A.p(h),m=E(i),v=(m.utcOffset()-this.utcOffset())*e,C=this-m,y=function(){return A.m(g,m)};switch(f){case u:p=y()/12;break;case l:p=y();break;case c:p=y()/3;break;case a:p=(C-v)/6048e5;break;case o:p=(C-v)/864e5;break;case s:p=C/t;break;case n:p=C/e;break;case r:p=C/1e3;break;default:p=C}return d?p:A.a(p)},m.daysInMonth=function(){return this.endOf(l).$D},m.$locale=function(){return y[this.$L]},m.locale=function(e,t){if(!e)return this.$L;var i=this.clone(),r=b(e,t,!0);return r&&(i.$L=r),i},m.clone=function(){return A.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},f}(),M=T.prototype;return E.prototype=M,[["$ms",i],["$s",r],["$m",n],["$H",s],["$W",o],["$M",l],["$y",u],["$D",h]].forEach(function(e){M[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),E.extend=function(e,t){return e.$i||(e(t,T,E),e.$i=!0),E},E.locale=b,E.isDayjs=S,E.unix=function(e){return E(1e3*e)},E.en=y[C],E.Ls=y,E.p={},E}()},73524(e){e.exports=function(){"use strict";return function(e,t){var i=t.prototype,r=i.format;i.format=function(e){var t=this,i=this.$locale();if(!this.isValid())return r.bind(this)(e);var n=this.$utils(),s=(e||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(e){switch(e){case"Q":return Math.ceil((t.$M+1)/3);case"Do":return i.ordinal(t.$D);case"gggg":return t.weekYear();case"GGGG":return t.isoWeekYear();case"wo":return i.ordinal(t.week(),"W");case"w":case"ww":return n.s(t.week(),"w"===e?1:2,"0");case"W":case"WW":return n.s(t.isoWeek(),"W"===e?1:2,"0");case"k":case"kk":return n.s(String(0===t.$H?24:t.$H),"k"===e?1:2,"0");case"X":return Math.floor(t.$d.getTime()/1e3);case"x":return t.$d.getTime();case"z":return"["+t.offsetName()+"]";case"zzz":return"["+t.offsetName("long")+"]";default:return e}});return r.bind(this)(s)}}}()},38588(e){e.exports=function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d/,r=/\d\d/,n=/\d\d?/,s=/\d*[^-_:/,()\s\d]+/,o={},a=function(e){return(e=+e)+(e>68?1900:2e3)},l=function(e){return function(t){this[e]=+t}},c=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e)return 0;if("Z"===e)return 0;var t=e.match(/([+-]|\d\d)/g),i=60*t[1]+(+t[2]||0);return 0===i?0:"+"===t[0]?-i:i}(e)}],u=function(e){var t=o[e];return t&&(t.indexOf?t:t.s.concat(t.f))},h=function(e,t){var i,r=o.meridiem;if(r){for(var n=1;n<=24;n+=1)if(e.indexOf(r(n,0,t))>-1){i=n>12;break}}else i=e===(t?"pm":"PM");return i},d={A:[s,function(e){this.afternoon=h(e,!1)}],a:[s,function(e){this.afternoon=h(e,!0)}],Q:[i,function(e){this.month=3*(e-1)+1}],S:[i,function(e){this.milliseconds=100*+e}],SS:[r,function(e){this.milliseconds=10*+e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[n,l("seconds")],ss:[n,l("seconds")],m:[n,l("minutes")],mm:[n,l("minutes")],H:[n,l("hours")],h:[n,l("hours")],HH:[n,l("hours")],hh:[n,l("hours")],D:[n,l("day")],DD:[r,l("day")],Do:[s,function(e){var t=o.ordinal,i=e.match(/\d+/);if(this.day=i[0],t)for(var r=1;r<=31;r+=1)t(r).replace(/\[|\]/g,"")===e&&(this.day=r)}],w:[n,l("week")],ww:[r,l("week")],M:[n,l("month")],MM:[r,l("month")],MMM:[s,function(e){var t=u("months"),i=(u("monthsShort")||t.map(function(e){return e.slice(0,3)})).indexOf(e)+1;if(i<1)throw new Error;this.month=i%12||i}],MMMM:[s,function(e){var t=u("months").indexOf(e)+1;if(t<1)throw new Error;this.month=t%12||t}],Y:[/[+-]?\d+/,l("year")],YY:[r,function(e){this.year=a(e)}],YYYY:[/\d{4}/,l("year")],Z:c,ZZ:c};function p(i){var r,n;r=i,n=o&&o.formats;for(var s=(i=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t,i,r){var s=r&&r.toUpperCase();return i||n[r]||e[r]||n[s].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e,t,i){return t||i.slice(1)})})).match(t),a=s.length,l=0;l<a;l+=1){var c=s[l],u=d[c],h=u&&u[0],p=u&&u[1];s[l]=p?{regex:h,parser:p}:c.replace(/^\[|\]$/g,"")}return function(e){for(var t={},i=0,r=0;i<a;i+=1){var n=s[i];if("string"==typeof n)r+=n.length;else{var o=n.regex,l=n.parser,c=e.slice(r),u=o.exec(c)[0];l.call(t,u),e=e.replace(u,"")}}return function(e){var t=e.afternoon;if(void 0!==t){var i=e.hours;t?i<12&&(e.hours+=12):12===i&&(e.hours=0),delete e.afternoon}}(t),t}}return function(e,t,i){i.p.customParseFormat=!0,e&&e.parseTwoDigitYear&&(a=e.parseTwoDigitYear);var r=t.prototype,n=r.parse;r.parse=function(e){var t=e.date,r=e.utc,s=e.args;this.$u=r;var a=s[1];if("string"==typeof a){var l=!0===s[2],c=!0===s[3],u=l||c,h=s[2];c&&(h=s[2]),o=this.$locale(),!l&&h&&(o=i.Ls[h]),this.$d=function(e,t,i,r){try{if(["x","X"].indexOf(t)>-1)return new Date(("X"===t?1e3:1)*e);var n=p(t)(e),s=n.year,o=n.month,a=n.day,l=n.hours,c=n.minutes,u=n.seconds,h=n.milliseconds,d=n.zone,g=n.week,f=new Date,m=a||(s||o?1:f.getDate()),v=s||f.getFullYear(),C=0;s&&!o||(C=o>0?o-1:f.getMonth());var y,w=l||0,S=c||0,b=u||0,E=h||0;return d?new Date(Date.UTC(v,C,m,w,S,b,E+60*d.offset*1e3)):i?new Date(Date.UTC(v,C,m,w,S,b,E)):(y=new Date(v,C,m,w,S,b,E),g&&(y=r(y).week(g).toDate()),y)}catch(e){return new Date("")}}(t,a,r,i),this.init(),h&&!0!==h&&(this.$L=this.locale(h).$L),u&&t!=this.format(a)&&(this.$d=new Date("")),o={}}else if(a instanceof Array)for(var d=a.length,g=1;g<=d;g+=1){s[1]=a[g-1];var f=i.apply(this,s);if(f.isValid()){this.$d=f.$d,this.$L=f.$L,this.init();break}g===d&&(this.$d=new Date(""))}else n.call(this,e)}}}()},47045(e){e.exports=function(){"use strict";return function(e,t,i){t.prototype.isBetween=function(e,t,r,n){var s=i(e),o=i(t),a="("===(n=n||"()")[0],l=")"===n[1];return(a?this.isAfter(s,r):!this.isBefore(s,r))&&(l?this.isBefore(o,r):!this.isAfter(o,r))||(a?this.isBefore(s,r):!this.isAfter(s,r))&&(l?this.isAfter(o,r):!this.isBefore(o,r))}}}()},85451(e){e.exports=function(){"use strict";var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(t,i,r){var n=i.prototype,s=n.format;r.en.formats=e,n.format=function(t){void 0===t&&(t="YYYY-MM-DDTHH:mm:ssZ");var i=this.$locale().formats,r=function(t,i){return t.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(t,r,n){var s=n&&n.toUpperCase();return r||i[n]||e[n]||i[s].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e,t,i){return t||i.slice(1)})})}(t,void 0===i?{}:i);return s.call(this,r)}}}()},6105(e){e.exports=function(){"use strict";var e={year:0,month:1,day:2,hour:3,minute:4,second:5},t={};return function(i,r,n){var s,o=function(e,i,r){void 0===r&&(r={});var n=new Date(e),s=function(e,i){void 0===i&&(i={});var r=i.timeZoneName||"short",n=e+"|"+r,s=t[n];return s||(s=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:r}),t[n]=s),s}(i,r);return s.formatToParts(n)},a=function(t,i){for(var r=o(t,i),s=[],a=0;a<r.length;a+=1){var l=r[a],c=l.type,u=l.value,h=e[c];h>=0&&(s[h]=parseInt(u,10))}var d=s[3],p=24===d?0:d,g=s[0]+"-"+s[1]+"-"+s[2]+" "+p+":"+s[4]+":"+s[5]+":000",f=+t;return(n.utc(g).valueOf()-(f-=f%1e3))/6e4},l=r.prototype;l.tz=function(e,t){void 0===e&&(e=s);var i,r=this.utcOffset(),o=this.toDate(),a=o.toLocaleString("en-US",{timeZone:e}),l=Math.round((o-new Date(a))/1e3/60),c=15*-Math.round(o.getTimezoneOffset()/15)-l;if(Number(c)){if(i=n(a,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(c,!0),t){var u=i.utcOffset();i=i.add(r-u,"minute")}}else i=this.utcOffset(0,t);return i.$x.$timezone=e,i},l.offsetName=function(e){var t=this.$x.$timezone||n.tz.guess(),i=o(this.valueOf(),t,{timeZoneName:e}).find(function(e){return"timezonename"===e.type.toLowerCase()});return i&&i.value};var c=l.startOf;l.startOf=function(e,t){if(!this.$x||!this.$x.$timezone)return c.call(this,e,t);var i=n(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return c.call(i,e,t).tz(this.$x.$timezone,!0)},n.tz=function(e,t,i){var r=i&&t,o=i||t||s,l=a(+n(),o);if("string"!=typeof e)return n(e).tz(o);var c=function(e,t,i){var r=e-60*t*1e3,n=a(r,i);if(t===n)return[r,t];var s=a(r-=60*(n-t)*1e3,i);return n===s?[r,n]:[e-60*Math.min(n,s)*1e3,Math.max(n,s)]}(n.utc(e,r).valueOf(),l,o),u=c[0],h=c[1],d=n(u).utcOffset(h);return d.$x.$timezone=o,d},n.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},n.tz.setDefault=function(e){s=e}}}()},61699(e){e.exports=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,i=/([+-]|\d\d)/g;return function(r,n,s){var o=n.prototype;s.utc=function(e){return new n({date:e,utc:!0,args:arguments})},o.utc=function(t){var i=s(this.toDate(),{locale:this.$L,utc:!0});return t?i.add(this.utcOffset(),e):i},o.local=function(){return s(this.toDate(),{locale:this.$L,utc:!1})};var a=o.parse;o.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),a.call(this,e)};var l=o.init;o.init=function(){if(this.$u){var e=this.$d;this.$y=e.getUTCFullYear(),this.$M=e.getUTCMonth(),this.$D=e.getUTCDate(),this.$W=e.getUTCDay(),this.$H=e.getUTCHours(),this.$m=e.getUTCMinutes(),this.$s=e.getUTCSeconds(),this.$ms=e.getUTCMilliseconds()}else l.call(this)};var c=o.utcOffset;o.utcOffset=function(r,n){var s=this.$utils().u;if(s(r))return this.$u?0:s(this.$offset)?c.call(this):this.$offset;if("string"==typeof r&&(r=function(e){void 0===e&&(e="");var r=e.match(t);if(!r)return null;var n=(""+r[0]).match(i)||["-",0,0],s=n[0],o=60*+n[1]+ +n[2];return 0===o?0:"+"===s?o:-o}(r),null===r))return this;var o=Math.abs(r)<=16?60*r:r;if(0===o)return this.utc(n);var a=this.clone();if(n)return a.$offset=o,a.$u=!1,a;var l=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(a=this.local().add(o+l,e)).$offset=o,a.$x.$localOffset=l,a};var u=o.format;o.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return u.call(this,t)},o.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},o.isUTC=function(){return!!this.$u},o.toISOString=function(){return this.toDate().toISOString()},o.toString=function(){return this.toDate().toUTCString()};var h=o.toDate;o.toDate=function(e){return"s"===e&&this.$offset?s(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():h.call(this)};var d=o.diff;o.diff=function(e,t,i){if(e&&this.$u===e.$u)return d.call(this,e,t,i);var r=this.local(),n=s(e).local();return d.call(r,n,t,i)}}}()},64881(e){e.exports=function(){"use strict";var e="week",t="year";return function(i,r,n){var s=r.prototype;s.week=function(i){if(void 0===i&&(i=null),null!==i)return this.add(7*(i-this.week()),"day");var r=this.$locale().yearStart||1;if(11===this.month()&&this.date()>25){var s=n(this).startOf(t).add(1,t).date(r),o=n(this).endOf(e);if(s.isBefore(o))return 1}var a=n(this).startOf(t).date(r).startOf(e).subtract(1,"millisecond"),l=this.diff(a,e,!0);return l<0?n(this).startOf("week").week():Math.ceil(l)},s.weeks=function(e){return void 0===e&&(e=null),this.week(e)}}}()},89028(e,t,i){var r=i(85409);function n(){var e;try{e=t.storage.debug}catch(e){}return!e&&void 0!==r&&"env"in r&&(e={NODE_ENV:"production",REACT_APP_LEARN_THUMBNAIL_UPLOAD:"https://vbmmdf81nl.execute-api.eu-west-2.amazonaws.com/live/learnthumbnailupload",REACT_APP_COGNITO_DOMAIN:"rio.auth.eu-west-2.amazoncognito.com",REACT_APP_RESOLVE_EXTERNAL_USER_URL:"https://zp73c6vc5l.execute-api.eu-west-2.amazonaws.com/current/resolve-external-user",REACT_APP_IDENTITY_POOL_ID:"eu-west-2:2fee832d-d0ba-420c-a056-0ed865cde419",REACT_APP_STRIPE_PUBLIC_KEY:"pk_live_51HLD9AEF3FA3cLa5DWIX6QpW41AHM0f5DALJjUtBoRhvP52iJrBkyGW9HajZ6MHF0M6weW7Nals5CkSZdULWyYyT00Pg5PgL0l",REACT_APP_PROFILE_BUCKET:"https://platform-profilepictures-live.s3.eu-west-2.amazonaws.com",REACT_APP_BANNER_CONTENT:"/VIDEO/LearnBanner.mp4",REACT_APP_AG_GRID_LICENSE_KEY:"Using_this_{AG_Grid}_Enterprise_key_{AG-063287}_in_excess_of_the_licence_granted_is_not_permitted___Please_report_misuse_to_legal@ag-grid.com___For_help_with_changing_this_key_please_contact_info@ag-grid.com___{RIO_ESG_LTD}_is_granted_a_{Single_Application}_Developer_License_for_the_application_{Rio}_only_for_{1}_Front-End_JavaScript_developer___All_Front-End_JavaScript_developers_working_on_{Rio}_need_to_be_licensed___{Rio}_has_been_granted_a_Deployment_License_Add-on_for_{1}_Production_Environment___This_key_works_with_{AG_Grid}_Enterprise_versions_released_before_{30_September_2025}____[v3]_[01]_MTc1OTE4NjgwMDAwMA==8e1b4570338f7c27ca6155479e1e2c14",REACT_APP_DS_URL:"https://rio.ai",REACT_APP_LOCATION_PICTURE_BUCKET:"https://platform-location-pictures-live.s3.eu-west-2.amazonaws.com",REACT_APP_GOOGLE_ANALYTIC_KEY:"UA-74511216-3",REACT_APP_AG_CHARTS_LICENSE_KEY:"Using_this_{AG_Charts}_Enterprise_key_{AG-100671}_in_excess_of_the_licence_granted_is_not_permitted___Please_report_misuse_to_legal@ag-grid.com___For_help_with_changing_this_key_please_contact_info@ag-grid.com___{Rio_AI_Ltd}_is_granted_a_{Single_Application}_Developer_License_for_the_application_{Rio}_only_for_{1}_Front-End_JavaScript_developer___All_Front-End_JavaScript_developers_working_on_{Rio}_need_to_be_licensed___{Rio}_has_been_granted_a_Deployment_License_Add-on_for_{1}_Production_Environment___This_key_works_with_{AG_Charts}_Enterprise_versions_released_before_{28_March_2027}____[v3]_[02]_MTgwNjE5MjAwMDAwMA==388e7d5fd16c7af6f350e7707024b637",REACT_APP_IMPACT_LOCATIONS_MAP_ID:"b3c1bd97c9d0fbf8",REACT_APP_DOCUMENT_UPLOAD:"https://1iyju5wg22.execute-api.eu-west-1.amazonaws.com/dev/documentupload",REACT_APP_INTELLIGENCE_API_STAGE:"live",REACT_APP_CONSULTATIONS_URL:"https://inference-engine.esg-r.io/api",REACT_APP_ENVIRONMENT_NAME:"Live",REACT_APP_USER_POOL_ID:"eu-west-2_CXMj8XQn0",REACT_APP_USER_POOL_WEB_CLIENT_ID:"2a8c10u5721464di89s75deqbr",REACT_APP_ANALYST_AGENT_ENDPOINT:"https://bedrock-agentcore.eu-west-2.amazonaws.com/runtimes/arn%3Aaws%3Abedrock-agentcore%3Aeu-west-2%3A523523762637%3Aruntime%2Fdata_analysis_agent_prod-FHjO5N5Zv7/invocations?qualifier=DEFAULT",REACT_APP_SENTRY_ENV:"LIVE",REACT_APP_BASE_URL:"https://sustainability.rio.ai",REACT_APP_DROMO_LICENSE_KEY:"a1fc32a8-fb02-4546-ad17-74254111f991",REACT_APP_HUBSPOT_TRACKER:"3847934",REACT_APP_GOOGLE_MAP_API_KEY:"AIzaSyD0bNhOInxPo2plOg1oxsYHeOsIXdefauE",REACT_APP_AZURE_SSO_APP_ID:"f7c97800-e70d-43a3-800e-64b6ba778a31",REACT_APP_AWS_REGION:"eu-west-2",REACT_APP_PINPOINT_REGION:"us-east-1",REACT_APP_GRAPHQL_URI:"https://kmkdrdo3dzcvnkzqzfnmfuwt4m.appsync-api.eu-west-2.amazonaws.com/graphql",REACT_APP_PINPOINT_APP_CLIENT_ID:"1b81e38efb7546329dd7eb32e0088b29"}.DEBUG),e}(t=e.exports=i(41111)).log=function(){return"object"==typeof console&&console.log&&Function.prototype.apply.call(console.log,console,arguments)},t.formatArgs=function(e){var i=this.useColors;if(e[0]=(i?"%c":"")+this.namespace+(i?" %c":" ")+e[0]+(i?"%c ":" ")+"+"+t.humanize(this.diff),i){var r="color: "+this.color;e.splice(1,0,r,"color: inherit");var n=0,s=0;e[0].replace(/%[a-zA-Z%]/g,function(e){"%%"!==e&&(n++,"%c"===e&&(s=n))}),e.splice(s,0,r)}},t.save=function(e){try{null==e?t.storage.removeItem("debug"):t.storage.debug=e}catch(e){}},t.load=n,t.useColors=function(){return!("undefined"==typeof window||!window.process||"renderer"!==window.process.type)||("undefined"!=typeof document&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||"undefined"!=typeof window&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/)&&parseInt(RegExp.$1,10)>=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/))},t.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(e){}}(),t.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],t.formatters.j=function(e){try{return JSON.stringify(e)}catch(e){return"[UnexpectedJSONParseError]: "+e.message}},t.enable(n())},41111(e,t,i){var r;function n(e){function i(){if(i.enabled){var e=i,n=+new Date,s=n-(r||n);e.diff=s,e.prev=r,e.curr=n,r=n;for(var o=new Array(arguments.length),a=0;a<o.length;a++)o[a]=arguments[a];o[0]=t.coerce(o[0]),"string"!=typeof o[0]&&o.unshift("%O");var l=0;o[0]=o[0].replace(/%([a-zA-Z%])/g,function(i,r){if("%%"===i)return i;l++;var n=t.formatters[r];if("function"==typeof n){var s=o[l];i=n.call(e,s),o.splice(l,1),l--}return i}),t.formatArgs.call(e,o),(i.log||t.log||console.log.bind(console)).apply(e,o)}}return i.namespace=e,i.enabled=t.enabled(e),i.useColors=t.useColors(),i.color=function(e){var i,r=0;for(i in e)r=(r<<5)-r+e.charCodeAt(i),r|=0;return t.colors[Math.abs(r)%t.colors.length]}(e),"function"==typeof t.init&&t.init(i),i}(t=e.exports=n.debug=n.default=n).coerce=function(e){return e instanceof Error?e.stack||e.message:e},t.disable=function(){t.enable("")},t.enable=function(e){t.save(e),t.names=[],t.skips=[];for(var i=("string"==typeof e?e:"").split(/[\s,]+/),r=i.length,n=0;n<r;n++)i[n]&&("-"===(e=i[n].replace(/\*/g,".*?"))[0]?t.skips.push(new RegExp("^"+e.substr(1)+"$")):t.names.push(new RegExp("^"+e+"$")))},t.enabled=function(e){var i,r;for(i=0,r=t.skips.length;i<r;i++)if(t.skips[i].test(e))return!1;for(i=0,r=t.names.length;i<r;i++)if(t.names[i].test(e))return!0;return!1},t.humanize=i(36644),t.names=[],t.skips=[],t.formatters={}},2858(e){"use strict";var t="%[a-f0-9]{2}",i=new RegExp("("+t+")|([^%]+?)","gi"),r=new RegExp("("+t+")+","gi");function n(e,t){try{return[decodeURIComponent(e.join(""))]}catch(e){}if(1===e.length)return e;t=t||1;var i=e.slice(0,t),r=e.slice(t);return Array.prototype.concat.call([],n(i),n(r))}function s(e){try{return decodeURIComponent(e)}catch(s){for(var t=e.match(i)||[],r=1;r<t.length;r++)t=(e=n(t,r).join("")).match(i)||[];return e}}e.exports=function(e){if("string"!=typeof e)throw new TypeError("Expected `encodedURI` to be of type `string`, got `"+typeof e+"`");try{return e=e.replace(/\+/g," "),decodeURIComponent(e)}catch(t){return function(e){for(var t={"%FE%FF":"��","%FF%FE":"��"},i=r.exec(e);i;){try{t[i[0]]=decodeURIComponent(i[0])}catch(e){var n=s(i[0]);n!==i[0]&&(t[i[0]]=n)}i=r.exec(e)}t["%C2"]="�";for(var o=Object.keys(t),a=0;a<o.length;a++){var l=o[a];e=e.replace(new RegExp(l,"g"),t[l])}return e}(e)}}},90357(e,t,i){var r,n;n=function(e){var t=["N","E","A","D"];function i(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}function r(e,t){Object.defineProperty(this,"kind",{value:e,enumerable:!0}),t&&t.length&&Object.defineProperty(this,"path",{value:t,enumerable:!0})}function n(e,t,i){n.super_.call(this,"E",e),Object.defineProperty(this,"lhs",{value:t,enumerable:!0}),Object.defineProperty(this,"rhs",{value:i,enumerable:!0})}function s(e,t){s.super_.call(this,"N",e),Object.defineProperty(this,"rhs",{value:t,enumerable:!0})}function o(e,t){o.super_.call(this,"D",e),Object.defineProperty(this,"lhs",{value:t,enumerable:!0})}function a(e,t,i){a.super_.call(this,"A",e),Object.defineProperty(this,"index",{value:t,enumerable:!0}),Object.defineProperty(this,"item",{value:i,enumerable:!0})}function l(e,t,i){var r=e.slice((i||t)+1||e.length);return e.length=t<0?e.length+t:t,e.push.apply(e,r),e}function c(e){var t=typeof e;return"object"!==t?t:e===Math?"math":null===e?"null":Array.isArray(e)?"array":"[object Date]"===Object.prototype.toString.call(e)?"date":"function"==typeof e.toString&&/^\/.*\//.test(e.toString())?"regexp":"object"}function u(e){var t=0;if(0===e.length)return t;for(var i=0;i<e.length;i++)t=(t<<5)-t+e.charCodeAt(i),t&=t;return t}function h(e){var t=0,i=c(e);if("array"===i)return e.forEach(function(e){t+=h(e)}),t+u("[type: array, hash: "+t+"]");if("object"===i){for(var r in e)if(e.hasOwnProperty(r)){var n="[ type: object, key: "+r+", value hash: "+h(e[r])+"]";t+=u(n)}return t}return t+u("[ type: "+i+" ; value: "+e+"]")}function d(e,t,i,r,l,u,p,g){i=i||[],p=p||[];var f=(l=l||[]).slice(0);if(null!=u){if(r){if("function"==typeof r&&r(f,u))return;if("object"==typeof r){if(r.prefilter&&r.prefilter(f,u))return;if(r.normalize){var m=r.normalize(f,u,e,t);m&&(e=m[0],t=m[1])}}}f.push(u)}"regexp"===c(e)&&"regexp"===c(t)&&(e=e.toString(),t=t.toString());var v,C,y,w,S=typeof e,b=typeof t,E="undefined"!==S||p&&p.length>0&&p[p.length-1].lhs&&Object.getOwnPropertyDescriptor(p[p.length-1].lhs,u),A="undefined"!==b||p&&p.length>0&&p[p.length-1].rhs&&Object.getOwnPropertyDescriptor(p[p.length-1].rhs,u);if(!E&&A)i.push(new s(f,t));else if(!A&&E)i.push(new o(f,e));else if(c(e)!==c(t))i.push(new n(f,e,t));else if("date"===c(e)&&e-t!==0)i.push(new n(f,e,t));else if("object"===S&&null!==e&&null!==t){for(v=p.length-1;v>-1;--v)if(p[v].lhs===e){w=!0;break}if(w)e!==t&&i.push(new n(f,e,t));else{if(p.push({lhs:e,rhs:t}),Array.isArray(e)){for(g&&(e.sort(function(e,t){return h(e)-h(t)}),t.sort(function(e,t){return h(e)-h(t)})),v=t.length-1,C=e.length-1;v>C;)i.push(new a(f,v,new s(void 0,t[v--])));for(;C>v;)i.push(new a(f,C,new o(void 0,e[C--])));for(;v>=0;--v)d(e[v],t[v],i,r,f,v,p,g)}else{var T=Object.keys(e),M=Object.keys(t);for(v=0;v<T.length;++v)y=T[v],(w=M.indexOf(y))>=0?(d(e[y],t[y],i,r,f,y,p,g),M[w]=null):d(e[y],void 0,i,r,f,y,p,g);for(v=0;v<M.length;++v)(y=M[v])&&d(void 0,t[y],i,r,f,y,p,g)}p.length=p.length-1}}else e!==t&&("number"===S&&isNaN(e)&&isNaN(t)||i.push(new n(f,e,t)))}function p(e,t,i,r,n){var s=[];if(d(e,t,s,r,null,null,null,n),i)for(var o=0;o<s.length;++o)i(s[o]);return s}function g(e,t,i,r){var n=p(e,t,r?function(e){e&&r.push(e)}:void 0,i);return r||(n.length?n:void 0)}function f(e,t,i){if(i.path&&i.path.length){var r,n=e[t],s=i.path.length-1;for(r=0;r<s;r++)n=n[i.path[r]];switch(i.kind){case"A":f(n[i.path[r]],i.index,i.item);break;case"D":delete n[i.path[r]];break;case"E":case"N":n[i.path[r]]=i.rhs}}else switch(i.kind){case"A":f(e[t],i.index,i.item);break;case"D":e=l(e,t);break;case"E":case"N":e[t]=i.rhs}return e}function m(e,i,r){if(void 0===r&&i&&~t.indexOf(i.kind)&&(r=i),e&&r&&r.kind){for(var n=e,s=-1,o=r.path?r.path.length-1:0;++s<o;)void 0===n[r.path[s]]&&(n[r.path[s]]=void 0!==r.path[s+1]&&"number"==typeof r.path[s+1]?[]:{}),n=n[r.path[s]];switch(r.kind){case"A":r.path&&void 0===n[r.path[s]]&&(n[r.path[s]]=[]),f(r.path?n[r.path[s]]:n,r.index,r.item);break;case"D":delete n[r.path[s]];break;case"E":case"N":n[r.path[s]]=r.rhs}}}function v(e,t,i){if(i.path&&i.path.length){var r,n=e[t],s=i.path.length-1;for(r=0;r<s;r++)n=n[i.path[r]];switch(i.kind){case"A":v(n[i.path[r]],i.index,i.item);break;case"D":case"E":n[i.path[r]]=i.lhs;break;case"N":delete n[i.path[r]]}}else switch(i.kind){case"A":v(e[t],i.index,i.item);break;case"D":case"E":e[t]=i.lhs;break;case"N":e=l(e,t)}return e}return i(n,r),i(s,r),i(o,r),i(a,r),Object.defineProperties(g,{diff:{value:g,enumerable:!0},orderIndependentDiff:{value:function(e,t,i,r){var n=p(e,t,r?function(e){e&&r.push(e)}:void 0,i,!0);return r||(n.length?n:void 0)},enumerable:!0},observableDiff:{value:p,enumerable:!0},orderIndependentObservableDiff:{value:function(e,t,i,r,n,s,o){return d(e,t,i,r,n,s,o,!0)},enumerable:!0},orderIndepHash:{value:h,enumerable:!0},applyDiff:{value:function(e,t,i){e&&t&&p(e,t,function(r){i&&!i(e,t,r)||m(e,t,r)})},enumerable:!0},applyChange:{value:m,enumerable:!0},revertChange:{value:function(e,t,i){if(e&&t&&i&&i.kind){var r,n,s=e;for(n=i.path.length-1,r=0;r<n;r++)void 0===s[i.path[r]]&&(s[i.path[r]]={}),s=s[i.path[r]];switch(i.kind){case"A":v(s[i.path[r]],i.index,i.item);break;case"D":case"E":s[i.path[r]]=i.lhs;break;case"N":delete s[i.path[r]]}}},enumerable:!0},isConflict:{value:function(){return"undefined"!=typeof $conflict},enumerable:!0}}),g.DeepDiff=g,e&&(e.DeepDiff=g),g}(this),void 0===(r=function(){return n}.call(t,i,t,e))||(e.exports=r)},66538(e,t,i){"use strict";i.d(t,{A:()=>l});var r=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===n}(e)}(e)},n="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function s(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((i=e,Array.isArray(i)?[]:{}),e,t):e;var i}function o(e,t,i){return e.concat(t).map(function(e){return s(e,i)})}function a(e,t,i){(i=i||{}).arrayMerge=i.arrayMerge||o,i.isMergeableObject=i.isMergeableObject||r;var n=Array.isArray(t);return n===Array.isArray(e)?n?i.arrayMerge(e,t,i):function(e,t,i){var r={};return i.isMergeableObject(e)&&Object.keys(e).forEach(function(t){r[t]=s(e[t],i)}),Object.keys(t).forEach(function(n){i.isMergeableObject(t[n])&&e[n]?r[n]=a(e[n],t[n],i):r[n]=s(t[n],i)}),r}(e,t,i):s(t,i)}a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,i){return a(e,i,t)},{})};const l=a},74579(e){"use strict";var t=function(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){var t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t||function(e){return e.$$typeof===i}(e)}(e)},i="function"==typeof Symbol&&Symbol.for?Symbol.for("react.element"):60103;function r(e,t){return!1!==t.clone&&t.isMergeableObject(e)?a((i=e,Array.isArray(i)?[]:{}),e,t):e;var i}function n(e,t,i){return e.concat(t).map(function(e){return r(e,i)})}function s(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}(e))}function o(e,t){try{return t in e}catch(e){return!1}}function a(e,i,l){(l=l||{}).arrayMerge=l.arrayMerge||n,l.isMergeableObject=l.isMergeableObject||t,l.cloneUnlessOtherwiseSpecified=r;var c=Array.isArray(i);return c===Array.isArray(e)?c?l.arrayMerge(e,i,l):function(e,t,i){var n={};return i.isMergeableObject(e)&&s(e).forEach(function(t){n[t]=r(e[t],i)}),s(t).forEach(function(s){(function(e,t){return o(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,s)||(o(e,s)&&i.isMergeableObject(t[s])?n[s]=function(e,t){if(!t.customMerge)return a;var i=t.customMerge(e);return"function"==typeof i?i:a}(s,i)(e[s],t[s],i):n[s]=r(t[s],i))}),n}(e,i,l):r(i,l)}a.all=function(e,t){if(!Array.isArray(e))throw new Error("first argument should be an array");return e.reduce(function(e,i){return a(e,i,t)},{})};var l=a;e.exports=l},20022(e,t,i){"use strict";var r=i(39886),n=i(63429),s=i(71102),o=i(25667);e.exports=function(e,t,i){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new s("`obj` must be an object or a function`");if("string"!=typeof t&&"symbol"!=typeof t)throw new s("`property` must be a string or a symbol`");if(arguments.length>3&&"boolean"!=typeof arguments[3]&&null!==arguments[3])throw new s("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&"boolean"!=typeof arguments[4]&&null!==arguments[4])throw new s("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&"boolean"!=typeof arguments[5]&&null!==arguments[5])throw new s("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&"boolean"!=typeof arguments[6])throw new s("`loose`, if provided, must be a boolean");var a=arguments.length>3?arguments[3]:null,l=arguments.length>4?arguments[4]:null,c=arguments.length>5?arguments[5]:null,u=arguments.length>6&&arguments[6],h=!!o&&o(e,t);if(r)r(e,t,{configurable:null===c&&h?h.configurable:!c,enumerable:null===a&&h?h.enumerable:!a,value:i,writable:null===l&&h?h.writable:!l});else{if(!u&&(a||l||c))throw new n("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.");e[t]=i}}},88754(e,t,i){"use strict";t.utils=i(26012),t.Cipher=i(96242),t.DES=i(7325),t.CBC=i(39015),t.EDE=i(62597)},39015(e,t,i){"use strict";var r=i(35578),n=i(91193),s={};function o(e){r.equal(e.length,8,"Invalid IV length"),this.iv=new Array(8);for(var t=0;t<this.iv.length;t++)this.iv[t]=e[t]}t.instantiate=function(e){function t(t){e.call(this,t),this._cbcInit()}n(t,e);for(var i=Object.keys(s),r=0;r<i.length;r++){var o=i[r];t.prototype[o]=s[o]}return t.create=function(e){return new t(e)},t},s._cbcInit=function(){var e=new o(this.options.iv);this._cbcState=e},s._update=function(e,t,i,r){var n=this._cbcState,s=this.constructor.super_.prototype,o=n.iv;if("encrypt"===this.type){for(var a=0;a<this.blockSize;a++)o[a]^=e[t+a];for(s._update.call(this,o,0,i,r),a=0;a<this.blockSize;a++)o[a]=i[r+a]}else{for(s._update.call(this,e,t,i,r),a=0;a<this.blockSize;a++)i[r+a]^=o[a];for(a=0;a<this.blockSize;a++)o[a]=e[t+a]}}},96242(e,t,i){"use strict";var r=i(35578);function n(e){this.options=e,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0,this.padding=!1!==e.padding}e.exports=n,n.prototype._init=function(){},n.prototype.update=function(e){return 0===e.length?[]:"decrypt"===this.type?this._updateDecrypt(e):this._updateEncrypt(e)},n.prototype._buffer=function(e,t){for(var i=Math.min(this.buffer.length-this.bufferOff,e.length-t),r=0;r<i;r++)this.buffer[this.bufferOff+r]=e[t+r];return this.bufferOff+=i,i},n.prototype._flushBuffer=function(e,t){return this._update(this.buffer,0,e,t),this.bufferOff=0,this.blockSize},n.prototype._updateEncrypt=function(e){var t=0,i=0,r=(this.bufferOff+e.length)/this.blockSize|0,n=new Array(r*this.blockSize);0!==this.bufferOff&&(t+=this._buffer(e,t),this.bufferOff===this.buffer.length&&(i+=this._flushBuffer(n,i)));for(var s=e.length-(e.length-t)%this.blockSize;t<s;t+=this.blockSize)this._update(e,t,n,i),i+=this.blockSize;for(;t<e.length;t++,this.bufferOff++)this.buffer[this.bufferOff]=e[t];return n},n.prototype._updateDecrypt=function(e){for(var t=0,i=0,r=Math.ceil((this.bufferOff+e.length)/this.blockSize)-1,n=new Array(r*this.blockSize);r>0;r--)t+=this._buffer(e,t),i+=this._flushBuffer(n,i);return t+=this._buffer(e,t),n},n.prototype.final=function(e){var t,i;return e&&(t=this.update(e)),i="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),t?t.concat(i):i},n.prototype._pad=function(e,t){if(0===t)return!1;for(;t<e.length;)e[t++]=0;return!0},n.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var e=new Array(this.blockSize);return this._update(this.buffer,0,e,0),e},n.prototype._unpad=function(e){return e},n.prototype._finalDecrypt=function(){r.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var e=new Array(this.blockSize);return this._flushBuffer(e,0),this._unpad(e)}},7325(e,t,i){"use strict";var r=i(35578),n=i(91193),s=i(26012),o=i(96242);function a(){this.tmp=new Array(2),this.keys=null}function l(e){o.call(this,e);var t=new a;this._desState=t,this.deriveKeys(t,e.key)}n(l,o),e.exports=l,l.create=function(e){return new l(e)};var c=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];l.prototype.deriveKeys=function(e,t){e.keys=new Array(32),r.equal(t.length,this.blockSize,"Invalid key length");var i=s.readUInt32BE(t,0),n=s.readUInt32BE(t,4);s.pc1(i,n,e.tmp,0),i=e.tmp[0],n=e.tmp[1];for(var o=0;o<e.keys.length;o+=2){var a=c[o>>>1];i=s.r28shl(i,a),n=s.r28shl(n,a),s.pc2(i,n,e.keys,o)}},l.prototype._update=function(e,t,i,r){var n=this._desState,o=s.readUInt32BE(e,t),a=s.readUInt32BE(e,t+4);s.ip(o,a,n.tmp,0),o=n.tmp[0],a=n.tmp[1],"encrypt"===this.type?this._encrypt(n,o,a,n.tmp,0):this._decrypt(n,o,a,n.tmp,0),o=n.tmp[0],a=n.tmp[1],s.writeUInt32BE(i,o,r),s.writeUInt32BE(i,a,r+4)},l.prototype._pad=function(e,t){if(!1===this.padding)return!1;for(var i=e.length-t,r=t;r<e.length;r++)e[r]=i;return!0},l.prototype._unpad=function(e){if(!1===this.padding)return e;for(var t=e[e.length-1],i=e.length-t;i<e.length;i++)r.equal(e[i],t);return e.slice(0,e.length-t)},l.prototype._encrypt=function(e,t,i,r,n){for(var o=t,a=i,l=0;l<e.keys.length;l+=2){var c=e.keys[l],u=e.keys[l+1];s.expand(a,e.tmp,0),c^=e.tmp[0],u^=e.tmp[1];var h=s.substitute(c,u),d=a;a=(o^s.permute(h))>>>0,o=d}s.rip(a,o,r,n)},l.prototype._decrypt=function(e,t,i,r,n){for(var o=i,a=t,l=e.keys.length-2;l>=0;l-=2){var c=e.keys[l],u=e.keys[l+1];s.expand(o,e.tmp,0),c^=e.tmp[0],u^=e.tmp[1];var h=s.substitute(c,u),d=o;o=(a^s.permute(h))>>>0,a=d}s.rip(o,a,r,n)}},62597(e,t,i){"use strict";var r=i(35578),n=i(91193),s=i(96242),o=i(7325);function a(e,t){r.equal(t.length,24,"Invalid key length");var i=t.slice(0,8),n=t.slice(8,16),s=t.slice(16,24);this.ciphers="encrypt"===e?[o.create({type:"encrypt",key:i}),o.create({type:"decrypt",key:n}),o.create({type:"encrypt",key:s})]:[o.create({type:"decrypt",key:s}),o.create({type:"encrypt",key:n}),o.create({type:"decrypt",key:i})]}function l(e){s.call(this,e);var t=new a(this.type,this.options.key);this._edeState=t}n(l,s),e.exports=l,l.create=function(e){return new l(e)},l.prototype._update=function(e,t,i,r){var n=this._edeState;n.ciphers[0]._update(e,t,i,r),n.ciphers[1]._update(i,r,i,r),n.ciphers[2]._update(i,r,i,r)},l.prototype._pad=o.prototype._pad,l.prototype._unpad=o.prototype._unpad},26012(e,t){"use strict";t.readUInt32BE=function(e,t){return(e[0+t]<<24|e[1+t]<<16|e[2+t]<<8|e[3+t])>>>0},t.writeUInt32BE=function(e,t,i){e[0+i]=t>>>24,e[1+i]=t>>>16&255,e[2+i]=t>>>8&255,e[3+i]=255&t},t.ip=function(e,t,i,r){for(var n=0,s=0,o=6;o>=0;o-=2){for(var a=0;a<=24;a+=8)n<<=1,n|=t>>>a+o&1;for(a=0;a<=24;a+=8)n<<=1,n|=e>>>a+o&1}for(o=6;o>=0;o-=2){for(a=1;a<=25;a+=8)s<<=1,s|=t>>>a+o&1;for(a=1;a<=25;a+=8)s<<=1,s|=e>>>a+o&1}i[r+0]=n>>>0,i[r+1]=s>>>0},t.rip=function(e,t,i,r){for(var n=0,s=0,o=0;o<4;o++)for(var a=24;a>=0;a-=8)n<<=1,n|=t>>>a+o&1,n<<=1,n|=e>>>a+o&1;for(o=4;o<8;o++)for(a=24;a>=0;a-=8)s<<=1,s|=t>>>a+o&1,s<<=1,s|=e>>>a+o&1;i[r+0]=n>>>0,i[r+1]=s>>>0},t.pc1=function(e,t,i,r){for(var n=0,s=0,o=7;o>=5;o--){for(var a=0;a<=24;a+=8)n<<=1,n|=t>>a+o&1;for(a=0;a<=24;a+=8)n<<=1,n|=e>>a+o&1}for(a=0;a<=24;a+=8)n<<=1,n|=t>>a+o&1;for(o=1;o<=3;o++){for(a=0;a<=24;a+=8)s<<=1,s|=t>>a+o&1;for(a=0;a<=24;a+=8)s<<=1,s|=e>>a+o&1}for(a=0;a<=24;a+=8)s<<=1,s|=e>>a+o&1;i[r+0]=n>>>0,i[r+1]=s>>>0},t.r28shl=function(e,t){return e<<t&268435455|e>>>28-t};var i=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];t.pc2=function(e,t,r,n){for(var s=0,o=0,a=i.length>>>1,l=0;l<a;l++)s<<=1,s|=e>>>i[l]&1;for(l=a;l<i.length;l++)o<<=1,o|=t>>>i[l]&1;r[n+0]=s>>>0,r[n+1]=o>>>0},t.expand=function(e,t,i){var r=0,n=0;r=(1&e)<<5|e>>>27;for(var s=23;s>=15;s-=4)r<<=6,r|=e>>>s&63;for(s=11;s>=3;s-=4)n|=e>>>s&63,n<<=6;n|=(31&e)<<1|e>>>31,t[i+0]=r>>>0,t[i+1]=n>>>0};var r=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];t.substitute=function(e,t){for(var i=0,n=0;n<4;n++)i<<=4,i|=r[64*n+(e>>>18-6*n&63)];for(n=0;n<4;n++)i<<=4,i|=r[256+64*n+(t>>>18-6*n&63)];return i>>>0};var n=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];t.permute=function(e){for(var t=0,i=0;i<n.length;i++)t<<=1,t|=e>>>n[i]&1;return t>>>0},t.padSplit=function(e,t,i){for(var r=e.toString(2);r.length<t;)r="0"+r;for(var n=[],s=0;s<t;s+=i)n.push(r.slice(s,s+i));return n.join(" ")}},35835(e,t,i){var r=i(25122),n=i(37821),s=i(29242),o={binary:!0,hex:!0,base64:!0};t.DiffieHellmanGroup=t.createDiffieHellmanGroup=t.getDiffieHellman=function(e){var t=new Buffer(n[e].prime,"hex"),i=new Buffer(n[e].gen,"hex");return new s(t,i)},t.createDiffieHellman=t.DiffieHellman=function e(t,i,n,a){return Buffer.isBuffer(i)||void 0===o[i]?e(t,"binary",i,n):(i=i||"binary",a=a||"binary",n=n||new Buffer([2]),Buffer.isBuffer(n)||(n=new Buffer(n,a)),"number"==typeof t?new s(r(t,n),n,!0):(Buffer.isBuffer(t)||(t=new Buffer(t,i)),new s(t,n,!0)))}},29242(e,t,i){var r=i(5630),n=new(i(74442)),s=new r(24),o=new r(11),a=new r(10),l=new r(3),c=new r(7),u=i(25122),h=i(82869);function d(e,t){return t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t)),this._pub=new r(e),this}function p(e,t){return t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t)),this._priv=new r(e),this}e.exports=f;var g={};function f(e,t,i){this.setGenerator(t),this.__prime=new r(e),this._prime=r.mont(this.__prime),this._primeLen=e.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,i?(this.setPublicKey=d,this.setPrivateKey=p):this._primeCode=8}function m(e,t){var i=new Buffer(e.toArray());return t?i.toString(t):i}Object.defineProperty(f.prototype,"verifyError",{enumerable:!0,get:function(){return"number"!=typeof this._primeCode&&(this._primeCode=function(e,t){var i=t.toString("hex"),r=[i,e.toString(16)].join("_");if(r in g)return g[r];var h,d=0;if(e.isEven()||!u.simpleSieve||!u.fermatTest(e)||!n.test(e))return d+=1,d+="02"===i||"05"===i?8:4,g[r]=d,d;switch(n.test(e.shrn(1))||(d+=2),i){case"02":e.mod(s).cmp(o)&&(d+=8);break;case"05":(h=e.mod(a)).cmp(l)&&h.cmp(c)&&(d+=8);break;default:d+=4}return g[r]=d,d}(this.__prime,this.__gen)),this._primeCode}}),f.prototype.generateKeys=function(){return this._priv||(this._priv=new r(h(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},f.prototype.computeSecret=function(e){var t=(e=(e=new r(e)).toRed(this._prime)).redPow(this._priv).fromRed(),i=new Buffer(t.toArray()),n=this.getPrime();if(i.length<n.length){var s=new Buffer(n.length-i.length);s.fill(0),i=Buffer.concat([s,i])}return i},f.prototype.getPublicKey=function(e){return m(this._pub,e)},f.prototype.getPrivateKey=function(e){return m(this._priv,e)},f.prototype.getPrime=function(e){return m(this.__prime,e)},f.prototype.getGenerator=function(e){return m(this._gen,e)},f.prototype.setGenerator=function(e,t){return t=t||"utf8",Buffer.isBuffer(e)||(e=new Buffer(e,t)),this.__gen=e,this._gen=new r(e),this}},25122(e,t,i){var r=i(82869);e.exports=C,C.simpleSieve=m,C.fermatTest=v;var n=i(5630),s=new n(24),o=new(i(74442)),a=new n(1),l=new n(2),c=new n(5),u=(new n(16),new n(8),new n(10)),h=new n(3),d=(new n(7),new n(11)),p=new n(4),g=(new n(12),null);function f(){if(null!==g)return g;var e=[];e[0]=2;for(var t=1,i=3;i<1048576;i+=2){for(var r=Math.ceil(Math.sqrt(i)),n=0;n<t&&e[n]<=r&&i%e[n]!==0;n++);t!==n&&e[n]<=r||(e[t++]=i)}return g=e,e}function m(e){for(var t=f(),i=0;i<t.length;i++)if(0===e.modn(t[i]))return 0===e.cmpn(t[i]);return!0}function v(e){var t=n.mont(e);return 0===l.toRed(t).redPow(e.subn(1)).fromRed().cmpn(1)}function C(e,t){if(e<16)return new n(2===t||5===t?[140,123]:[140,39]);var i,g;for(t=new n(t);;){for(i=new n(r(Math.ceil(e/8)));i.bitLength()>e;)i.ishrn(1);if(i.isEven()&&i.iadd(a),i.testn(1)||i.iadd(l),t.cmp(l)){if(!t.cmp(c))for(;i.mod(u).cmp(h);)i.iadd(p)}else for(;i.mod(s).cmp(d);)i.iadd(p);if(m(g=i.shrn(1))&&m(i)&&v(g)&&v(i)&&o.test(g)&&o.test(i))return i}}},24310(e,t,i){"use strict";function r(e,t){e.classList?e.classList.add(t):function(e,t){return e.classList?!!t&&e.classList.contains(t):-1!==(" "+(e.className.baseVal||e.className)+" ").indexOf(" "+t+" ")}(e,t)||("string"==typeof e.className?e.className=e.className+" "+t:e.setAttribute("class",(e.className&&e.className.baseVal||"")+" "+t))}i.d(t,{A:()=>r})},48532(e,t,i){"use strict";function r(e,t){return e.replace(new RegExp("(^|\\s)"+t+"(?:\\s|$)","g"),"$1").replace(/\s+/g," ").replace(/^\s*|\s*$/g,"")}function n(e,t){e.classList?e.classList.remove(t):"string"==typeof e.className?e.className=r(e.className,t):e.setAttribute("class",r(e.className&&e.className.baseVal||"",t))}i.d(t,{A:()=>n})},38383(e,t,i){"use strict";const r=i(72856),n=new Set(["__proto__","prototype","constructor"]);function s(e){const t=e.split("."),i=[];for(let e=0;e<t.length;e++){let r=t[e];for(;"\\"===r[r.length-1]&&void 0!==t[e+1];)r=r.slice(0,-1)+".",r+=t[++e];i.push(r)}return i.some(e=>n.has(e))?[]:i}e.exports={get(e,t,i){if(!r(e)||"string"!=typeof t)return void 0===i?e:i;const n=s(t);if(0!==n.length){for(let t=0;t<n.length;t++)if(null==(e=e[n[t]])){if(t!==n.length-1)return i;break}return void 0===e?i:e}},set(e,t,i){if(!r(e)||"string"!=typeof t)return e;const n=e,o=s(t);for(let t=0;t<o.length;t++){const n=o[t];r(e[n])||(e[n]={}),t===o.length-1&&(e[n]=i),e=e[n]}return n},delete(e,t){if(!r(e)||"string"!=typeof t)return!1;const i=s(t);for(let t=0;t<i.length;t++){const n=i[t];if(t===i.length-1)return delete e[n],!0;if(e=e[n],!r(e))return!1}},has(e,t){if(!r(e)||"string"!=typeof t)return!1;const i=s(t);if(0===i.length)return!1;for(let t=0;t<i.length;t++){if(!r(e))return!1;if(!(i[t]in e))return!1;e=e[i[t]]}return!0}}},86858(e,t,i){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){n(e,t,i[t])})}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(84433),o=i(41671),a=i(40643),l=i(31527),c=i(58267),u=i(59539),h=i(12634),d=i(17595),p=i(99251),g=i(83886),f=d("draft_tree_data_support"),m=f?l:a,v=p.List,C=p.Repeat,y={insertAtomicBlock:function(e,t,i){var n=e.getCurrentContent(),a=e.getSelection(),l=c.removeRange(n,a,"backward"),d=l.getSelectionAfter(),p=c.splitBlock(l,d),g=p.getSelectionAfter(),y=c.setBlockType(p,g,"atomic"),w=o.create({entity:t}),S={key:h(),type:"atomic",text:i,characterList:v(C(w,i.length))},b={key:h(),type:"unstyled"};f&&(S=r({},S,{nextSibling:b.key}),b=r({},b,{prevSibling:S.key}));var E=[new m(S),new m(b)],A=s.createFromArray(E),T=c.replaceWithFragment(y,g,A),M=T.merge({selectionBefore:a,selectionAfter:T.getSelectionAfter().set("hasFocus",!0)});return u.push(e,M,"insert-fragment")},moveAtomicBlock:function(e,t,i,r){var n,s=e.getCurrentContent(),o=e.getSelection();if("before"===r||"after"===r){var a=s.getBlockForKey("before"===r?i.getStartKey():i.getEndKey());n=g(s,t,a,r)}else{var l=c.removeRange(s,i,"backward"),h=l.getSelectionAfter(),d=l.getBlockForKey(h.getFocusKey());if(0===h.getStartOffset())n=g(l,t,d,"before");else if(h.getEndOffset()===d.getLength())n=g(l,t,d,"after");else{var p=c.splitBlock(l,h),f=p.getSelectionAfter(),m=p.getBlockForKey(f.getFocusKey());n=g(p,t,m,"before")}}var v=n.merge({selectionBefore:o,selectionAfter:n.getSelectionAfter().set("hasFocus",!0)});return u.push(e,v,"move-block")}};e.exports=y},84433(e,t,i){"use strict";var r=i(99251).OrderedMap,n={createFromArray:function(e){return r(e.map(function(e){return[e.getKey(),e]}))}};e.exports=n},52568(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(14910),s=i(68768),o=i(99251),a=o.List,l=o.Repeat,c=o.Record,u=function(){return!0},h=c({start:null,end:null}),d=c({start:null,end:null,decoratorKey:null,leaves:null}),p={generate:function(e,t,i){var r=t.getLength();if(!r)return a.of(new d({start:0,end:0,decoratorKey:null,leaves:a.of(new h({start:0,end:0}))}));var s=[],o=i?i.getDecorations(t,e):a(l(null,r)),c=t.getCharacterList();return n(o,g,u,function(e,t){var i,r,l,p;s.push(new d({start:e,end:t,decoratorKey:o.get(e),leaves:(i=c.slice(e,t).toList(),r=e,l=[],p=i.map(function(e){return e.getStyle()}).toList(),n(p,g,u,function(e,t){l.push(new h({start:e+r,end:t+r}))}),a(l))}))}),a(s)},fromJS:function(e){var t=e.leaves,i=function(e,t){if(null==e)return{};var i,r,n={},s=Object.keys(e);for(r=0;r<s.length;r++)i=s[r],t.indexOf(i)>=0||(n[i]=e[i]);return n}(e,["leaves"]);return new d(function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),n.forEach(function(t){r(e,t,i[t])})}return e}({},i,{leaves:null!=t?a(Array.isArray(t)?t:s(t)).map(function(e){return h(e)}):null}))}};function g(e,t){return e===t}e.exports=p},41671(e,t,i){"use strict";var r=i(99251),n=r.Map,s=r.OrderedSet,o=r.Record,a=s(),l={style:a,entity:null},c=function(e){var t,i;function r(){return e.apply(this,arguments)||this}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var o=r.prototype;return o.getStyle=function(){return this.get("style")},o.getEntity=function(){return this.get("entity")},o.hasStyle=function(e){return this.getStyle().includes(e)},r.applyStyle=function(e,t){var i=e.set("style",e.getStyle().add(t));return r.create(i)},r.removeStyle=function(e,t){var i=e.set("style",e.getStyle().remove(t));return r.create(i)},r.applyEntity=function(e,t){var i=e.getEntity()===t?e:e.set("entity",t);return r.create(i)},r.create=function(e){if(!e)return u;var t=n({style:a,entity:null}).merge(e),i=h.get(t);if(i)return i;var s=new r(t);return h=h.set(t,s),s},r.fromJS=function(e){var t=e.style,i=e.entity;return new r({style:Array.isArray(t)?s(t):t,entity:Array.isArray(i)?s(i):i})},r}(o(l)),u=new c,h=n([[n(l),u]]);c.EMPTY=u,e.exports=c},9294(e,t,i){"use strict";var r=i(99251).List,n=function(){function e(e){var t,i;i=void 0,(t="_decorators")in this?Object.defineProperty(this,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):this[t]=i,this._decorators=e.slice()}var t=e.prototype;return t.getDecorations=function(e,t){var i=Array(e.getText().length).fill(null);return this._decorators.forEach(function(r,n){var s=0;(0,r.strategy)(e,function(e,t){(function(e,t,i){for(var r=t;r<i;r++)if(null!=e[r])return!1;return!0})(i,e,t)&&(function(e,t,i,r){for(var n=t;n<i;n++)e[n]=r}(i,e,t,n+"."+s),s++)},t)}),r(i)},t.getComponentForKey=function(e){var t=parseInt(e.split(".")[0],10);return this._decorators[t].component},t.getPropsForKey=function(e){var t=parseInt(e.split(".")[0],10);return this._decorators[t].props},e}();e.exports=n},40643(e,t,i){"use strict";var r=i(41671),n=i(14910),s=i(99251),o=s.List,a=s.Map,l=s.OrderedSet,c=s.Record,u=s.Repeat,h=l(),d=function(e){var t,i;function s(t){return e.call(this,function(e){if(!e)return e;var t=e.characterList,i=e.text;return i&&!t&&(e.characterList=o(u(r.EMPTY,i.length))),e}(t))||this}i=e,(t=s).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var a=s.prototype;return a.getKey=function(){return this.get("key")},a.getType=function(){return this.get("type")},a.getText=function(){return this.get("text")},a.getCharacterList=function(){return this.get("characterList")},a.getLength=function(){return this.getText().length},a.getDepth=function(){return this.get("depth")},a.getData=function(){return this.get("data")},a.getInlineStyleAt=function(e){var t=this.getCharacterList().get(e);return t?t.getStyle():h},a.getEntityAt=function(e){var t=this.getCharacterList().get(e);return t?t.getEntity():null},a.findStyleRanges=function(e,t){n(this.getCharacterList(),p,e,t)},a.findEntityRanges=function(e,t){n(this.getCharacterList(),g,e,t)},s}(c({key:"",type:"unstyled",text:"",characterList:o(),depth:0,data:a()}));function p(e,t){return e.getStyle()===t.getStyle()}function g(e,t){return e.getEntity()===t.getEntity()}e.exports=d},31527(e,t,i){"use strict";var r=i(41671),n=i(14910),s=i(99251),o=s.List,a=s.Map,l=s.OrderedSet,c=s.Record,u=s.Repeat,h=l(),d={parent:null,characterList:o(),data:a(),depth:0,key:"",text:"",type:"unstyled",children:o(),prevSibling:null,nextSibling:null},p=function(e,t){return e.getStyle()===t.getStyle()},g=function(e,t){return e.getEntity()===t.getEntity()},f=function(e){var t,i;function s(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d;return e.call(this,function(e){if(!e)return e;var t=e.characterList,i=e.text;return i&&!t&&(e.characterList=o(u(r.EMPTY,i.length))),e}(t))||this}i=e,(t=s).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var a=s.prototype;return a.getKey=function(){return this.get("key")},a.getType=function(){return this.get("type")},a.getText=function(){return this.get("text")},a.getCharacterList=function(){return this.get("characterList")},a.getLength=function(){return this.getText().length},a.getDepth=function(){return this.get("depth")},a.getData=function(){return this.get("data")},a.getInlineStyleAt=function(e){var t=this.getCharacterList().get(e);return t?t.getStyle():h},a.getEntityAt=function(e){var t=this.getCharacterList().get(e);return t?t.getEntity():null},a.getChildKeys=function(){return this.get("children")},a.getParentKey=function(){return this.get("parent")},a.getPrevSiblingKey=function(){return this.get("prevSibling")},a.getNextSiblingKey=function(){return this.get("nextSibling")},a.findStyleRanges=function(e,t){n(this.getCharacterList(),p,e,t)},a.findEntityRanges=function(e,t){n(this.getCharacterList(),g,e,t)},s}(c(d));e.exports=f},23315(e,t,i){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){n(e,t,i[t])})}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(84433),o=i(41671),a=i(40643),l=i(31527),c=i(70873),u=i(27442),h=i(12634),d=i(68768),p=i(17595),g=i(99251),f=i(10160),m=g.List,v=g.Record,C=g.Repeat,y=g.Map,w=g.OrderedMap,S=v({entityMap:null,blockMap:null,selectionBefore:null,selectionAfter:null}),b=p("draft_tree_data_support")?l:a,E=function(e){var t,i;function n(){return e.apply(this,arguments)||this}i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var a=n.prototype;return a.getEntityMap=function(){return c},a.getBlockMap=function(){return this.get("blockMap")},a.getSelectionBefore=function(){return this.get("selectionBefore")},a.getSelectionAfter=function(){return this.get("selectionAfter")},a.getBlockForKey=function(e){return this.getBlockMap().get(e)},a.getKeyBefore=function(e){return this.getBlockMap().reverse().keySeq().skipUntil(function(t){return t===e}).skip(1).first()},a.getKeyAfter=function(e){return this.getBlockMap().keySeq().skipUntil(function(t){return t===e}).skip(1).first()},a.getBlockAfter=function(e){return this.getBlockMap().skipUntil(function(t,i){return i===e}).skip(1).first()},a.getBlockBefore=function(e){return this.getBlockMap().reverse().skipUntil(function(t,i){return i===e}).skip(1).first()},a.getBlocksAsArray=function(){return this.getBlockMap().toArray()},a.getFirstBlock=function(){return this.getBlockMap().first()},a.getLastBlock=function(){return this.getBlockMap().last()},a.getPlainText=function(e){return this.getBlockMap().map(function(e){return e?e.getText():""}).join(e||"\n")},a.getLastCreatedEntityKey=function(){return c.__getLastCreatedEntityKey()},a.hasText=function(){var e=this.getBlockMap();return e.size>1||escape(e.first().getText()).replace(/%u200B/g,"").length>0},a.createEntity=function(e,t,i){return c.__create(e,t,i),this},a.mergeEntityData=function(e,t){return c.__mergeData(e,t),this},a.replaceEntityData=function(e,t){return c.__replaceData(e,t),this},a.addEntity=function(e){return c.__add(e),this},a.getEntity=function(e){return c.__get(e)},a.getAllEntities=function(){return c.__getAll()},a.loadWithEntities=function(e){return c.__loadWithEntities(e)},n.createFromBlockArray=function(e,t){var i=Array.isArray(e)?e:e.contentBlocks,r=s.createFromArray(i),o=r.isEmpty()?new u:u.createEmpty(r.first().getKey());return new n({blockMap:r,entityMap:t||c,selectionBefore:o,selectionAfter:o})},n.createFromText=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:/\r\n?|\n/g,i=e.split(t).map(function(e){return e=f(e),new b({key:h(),text:e,type:"unstyled",characterList:m(C(o.EMPTY,e.length))})});return n.createFromBlockArray(i)},n.fromJS=function(e){return new n(r({},e,{blockMap:w(e.blockMap).map(n.createContentBlockFromJS),selectionBefore:new u(e.selectionBefore),selectionAfter:new u(e.selectionAfter)}))},n.createContentBlockFromJS=function(e){var t=e.characterList;return new b(r({},e,{data:y(e.data),characterList:null!=t?m((Array.isArray(t)?t:d(t)).map(function(e){return o.fromJS(e)})):void 0}))},n}(S);e.exports=E},61773(e,t,i){"use strict";var r=i(41671),n=i(99251).Map,s={add:function(e,t,i){return o(e,t,i,!0)},remove:function(e,t,i){return o(e,t,i,!1)}};function o(e,t,i,s){var o=e.getBlockMap(),a=t.getStartKey(),l=t.getStartOffset(),c=t.getEndKey(),u=t.getEndOffset(),h=o.skipUntil(function(e,t){return t===a}).takeUntil(function(e,t){return t===c}).concat(n([[c,o.get(c)]])).map(function(e,t){var n,o;a===c?(n=l,o=u):(n=t===a?l:0,o=t===c?u:e.getLength());for(var h,d=e.getCharacterList();n<o;)h=d.get(n),d=d.set(n,s?r.applyStyle(h,i):r.removeStyle(h,i)),n++;return e.set("characterList",d)});return e.merge({blockMap:o.merge(h),selectionBefore:t,selectionAfter:t})}e.exports=s},94199(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(63390),s=i(65461),o=i(82826),a=i(99251),l=i(40041),c=i(25813),u=a.Map,h={subtree:!0,characterData:!0,childList:!0,characterDataOldValue:!1,attributes:!1},d=n.isBrowser("IE <= 11"),p=function(){function e(e){var t=this;r(this,"observer",void 0),r(this,"container",void 0),r(this,"mutations",void 0),r(this,"onCharData",void 0),this.container=e,this.mutations=u();var i=o(e);i.MutationObserver&&!d?this.observer=new i.MutationObserver(function(e){return t.registerMutations(e)}):this.onCharData=function(e){e.target instanceof Node||l(!1),t.registerMutation({type:"characterData",target:e.target})}}var t=e.prototype;return t.start=function(){this.observer?this.observer.observe(this.container,h):this.container.addEventListener("DOMCharacterDataModified",this.onCharData)},t.stopAndFlushMutations=function(){var e=this.observer;e?(this.registerMutations(e.takeRecords()),e.disconnect()):this.container.removeEventListener("DOMCharacterDataModified",this.onCharData);var t=this.mutations;return this.mutations=u(),t},t.registerMutations=function(e){for(var t=0;t<e.length;t++)this.registerMutation(e[t])},t.getMutationTextContent=function(e){var t=e.type,i=e.target,r=e.removedNodes;if("characterData"===t){if(""!==i.textContent)return d?i.textContent.replace("\n",""):i.textContent}else if("childList"===t){if(r&&r.length)return"";if(""!==i.textContent)return i.textContent}return null},t.registerMutation=function(e){var t=this.getMutationTextContent(e);if(null!=t){var i=c(s(e.target));this.mutations=this.mutations.set(i,t)}},e}();e.exports=p},47904(e,t,i){"use strict";var r=i(22155),n=i(22978),s=(0,i(99251).Map)({"header-one":{element:"h1"},"header-two":{element:"h2"},"header-three":{element:"h3"},"header-four":{element:"h4"},"header-five":{element:"h5"},"header-six":{element:"h6"},section:{element:"section"},article:{element:"article"},"unordered-list-item":{element:"li",wrapper:r.createElement("ul",{className:n("public/DraftStyleDefault/ul")})},"ordered-list-item":{element:"li",wrapper:r.createElement("ol",{className:n("public/DraftStyleDefault/ol")})},blockquote:{element:"blockquote"},atomic:{element:"figure"},"code-block":{element:"pre",wrapper:r.createElement("pre",{className:n("public/DraftStyleDefault/pre")})},unstyled:{element:"div",aliasedElements:["p"]}});e.exports=s},55175(e){"use strict";e.exports={BOLD:{fontWeight:"bold"},CODE:{fontFamily:"monospace",wordWrap:"break-word"},ITALIC:{fontStyle:"italic"},STRIKETHROUGH:{textDecoration:"line-through"},UNDERLINE:{textDecoration:"underline"}}},53506(e,t,i){"use strict";var r=i(86858),n=i(84433),s=i(41671),o=i(9294),a=i(40643),l=i(23315),c=i(47904),u=i(55175),h=i(13162),d=i(92063),p=i(70873),g=i(58267),f=i(72066),m=i(59539),v=i(8117),C=i(79198),y=i(75969),w=i(27442),S=i(93613),b=i(12503),E=i(12634),A=i(93564),T=i(50531),M={Editor:h,EditorBlock:d,EditorState:m,CompositeDecorator:o,Entity:p,EntityInstance:f,BlockMapBuilder:n,CharacterMetadata:s,ContentBlock:a,ContentState:l,RawDraftContentState:C,SelectionState:w,AtomicBlockUtils:r,KeyBindingUtil:v,Modifier:g,RichUtils:y,DefaultDraftBlockRenderMap:c,DefaultDraftInlineStyle:u,convertFromHTML:i(86739),convertFromRaw:b,convertToRaw:S,genKey:E,getDefaultKeyBinding:A,getVisibleSelectionRect:T};e.exports=M},13162(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){a(e,t,i[t])})}return e}function o(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function a(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}function l(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}var c=i(47904),u=i(55175),h=i(60913),d=i(74804),p=i(38001),g=i(51163),f=i(94951),m=i(12803),v=i(7618),C=i(59539),y=i(22155),w=i(72528),S=i(98556),b=i(63390),E=i(22978),A=i(12634),T=i(93564),M=i(93987),R=i(17595),_=i(40041),P=i(44110),x=i(25813),D=b.isBrowser("IE"),I=!D,L={edit:g,composite:h,drag:p,cut:null,render:null},N=!1,O=function(e){function t(){return e.apply(this,arguments)||this}l(t,e);var i=t.prototype;return i.render=function(){return null},i.componentDidMount=function(){this._update()},i.componentDidUpdate=function(){this._update()},i._update=function(){var e=this.props.editor;e._latestEditorState=this.props.editorState,e._blockSelectEvents=!0},t}(y.Component),F=function(e){function t(t){var i;return a(o(i=e.call(this,t)||this),"_blockSelectEvents",void 0),a(o(i),"_clipboard",void 0),a(o(i),"_handler",void 0),a(o(i),"_dragCount",void 0),a(o(i),"_internalDrag",void 0),a(o(i),"_editorKey",void 0),a(o(i),"_placeholderAccessibilityID",void 0),a(o(i),"_latestEditorState",void 0),a(o(i),"_latestCommittedEditorState",void 0),a(o(i),"_pendingStateFromBeforeInput",void 0),a(o(i),"_onBeforeInput",void 0),a(o(i),"_onBlur",void 0),a(o(i),"_onCharacterData",void 0),a(o(i),"_onCompositionEnd",void 0),a(o(i),"_onCompositionStart",void 0),a(o(i),"_onCopy",void 0),a(o(i),"_onCut",void 0),a(o(i),"_onDragEnd",void 0),a(o(i),"_onDragOver",void 0),a(o(i),"_onDragStart",void 0),a(o(i),"_onDrop",void 0),a(o(i),"_onInput",void 0),a(o(i),"_onFocus",void 0),a(o(i),"_onKeyDown",void 0),a(o(i),"_onKeyPress",void 0),a(o(i),"_onKeyUp",void 0),a(o(i),"_onMouseDown",void 0),a(o(i),"_onMouseUp",void 0),a(o(i),"_onPaste",void 0),a(o(i),"_onSelect",void 0),a(o(i),"editor",void 0),a(o(i),"editorContainer",void 0),a(o(i),"focus",void 0),a(o(i),"blur",void 0),a(o(i),"setMode",void 0),a(o(i),"exitCurrentMode",void 0),a(o(i),"restoreEditorDOM",void 0),a(o(i),"setClipboard",void 0),a(o(i),"getClipboard",void 0),a(o(i),"getEditorKey",void 0),a(o(i),"update",void 0),a(o(i),"onDragEnter",void 0),a(o(i),"onDragLeave",void 0),a(o(i),"_handleEditorContainerRef",function(e){i.editorContainer=e,i.editor=null!==e?e.firstChild:null}),a(o(i),"focus",function(e){var t=i.props.editorState,r=t.getSelection().getHasFocus(),n=i.editor;if(n){var s=S.getScrollParent(n),o=e||M(s),a=o.x,l=o.y;P(n)||_(!1),n.focus(),s===window?window.scrollTo(a,l):w.setTop(s,l),r||i.update(C.forceSelection(t,t.getSelection()))}}),a(o(i),"blur",function(){var e=i.editor;e&&(P(e)||_(!1),e.blur())}),a(o(i),"setMode",function(e){var t=i.props,r=t.onPaste,n=t.onCut,o=t.onCopy,a=s({},L.edit);r&&(a.onPaste=r),n&&(a.onCut=n),o&&(a.onCopy=o);var l=s({},L,{edit:a});i._handler=l[e]}),a(o(i),"exitCurrentMode",function(){i.setMode("edit")}),a(o(i),"restoreEditorDOM",function(e){i.setState({contentsKey:i.state.contentsKey+1},function(){i.focus(e)})}),a(o(i),"setClipboard",function(e){i._clipboard=e}),a(o(i),"getClipboard",function(){return i._clipboard}),a(o(i),"update",function(e){i._latestEditorState=e,i.props.onChange(e)}),a(o(i),"onDragEnter",function(){i._dragCount++}),a(o(i),"onDragLeave",function(){i._dragCount--,0===i._dragCount&&i.exitCurrentMode()}),i._blockSelectEvents=!1,i._clipboard=null,i._handler=null,i._dragCount=0,i._editorKey=t.editorKey||A(),i._placeholderAccessibilityID="placeholder-"+i._editorKey,i._latestEditorState=t.editorState,i._latestCommittedEditorState=t.editorState,i._onBeforeInput=i._buildHandler("onBeforeInput"),i._onBlur=i._buildHandler("onBlur"),i._onCharacterData=i._buildHandler("onCharacterData"),i._onCompositionEnd=i._buildHandler("onCompositionEnd"),i._onCompositionStart=i._buildHandler("onCompositionStart"),i._onCopy=i._buildHandler("onCopy"),i._onCut=i._buildHandler("onCut"),i._onDragEnd=i._buildHandler("onDragEnd"),i._onDragOver=i._buildHandler("onDragOver"),i._onDragStart=i._buildHandler("onDragStart"),i._onDrop=i._buildHandler("onDrop"),i._onInput=i._buildHandler("onInput"),i._onFocus=i._buildHandler("onFocus"),i._onKeyDown=i._buildHandler("onKeyDown"),i._onKeyPress=i._buildHandler("onKeyPress"),i._onKeyUp=i._buildHandler("onKeyUp"),i._onMouseDown=i._buildHandler("onMouseDown"),i._onMouseUp=i._buildHandler("onMouseUp"),i._onPaste=i._buildHandler("onPaste"),i._onSelect=i._buildHandler("onSelect"),i.getEditorKey=function(){return i._editorKey},i.state={contentsKey:0},i}l(t,e);var i=t.prototype;return i._buildHandler=function(e){var t=this;return function(i){if(!t.props.readOnly){var r=t._handler&&t._handler[e];r&&(f?f(function(){return r(t,i)}):r(t,i))}}},i._showPlaceholder=function(){return!!this.props.placeholder&&!this.props.editorState.isInCompositionMode()&&!this.props.editorState.getCurrentContent().hasText()},i._renderPlaceholder=function(){if(this._showPlaceholder()){var e={text:x(this.props.placeholder),editorState:this.props.editorState,textAlignment:this.props.textAlignment,accessibilityID:this._placeholderAccessibilityID};return y.createElement(m,e)}return null},i._renderARIADescribedBy=function(){var e=this.props.ariaDescribedBy||"",t=this._showPlaceholder()?this._placeholderAccessibilityID:"";return e.replace("{{editor_id_placeholder}}",t)||void 0},i.render=function(){var e=this.props,t=e.blockRenderMap,i=e.blockRendererFn,r=e.blockStyleFn,o=e.customStyleFn,a=e.customStyleMap,l=e.editorState,c=e.preventScroll,h=e.readOnly,p=e.textAlignment,g=e.textDirectionality,f=E({"DraftEditor/root":!0,"DraftEditor/alignLeft":"left"===p,"DraftEditor/alignRight":"right"===p,"DraftEditor/alignCenter":"center"===p}),m=this.props.role||"textbox",v="combobox"===m?!!this.props.ariaExpanded:null,C={blockRenderMap:t,blockRendererFn:i,blockStyleFn:r,customStyleMap:s({},u,a),customStyleFn:o,editorKey:this._editorKey,editorState:l,preventScroll:c,textDirectionality:g};return y.createElement("div",{className:f},this._renderPlaceholder(),y.createElement("div",{className:E("DraftEditor/editorContainer"),ref:this._handleEditorContainerRef},y.createElement("div",{"aria-activedescendant":h?null:this.props.ariaActiveDescendantID,"aria-autocomplete":h?null:this.props.ariaAutoComplete,"aria-controls":h?null:this.props.ariaControls,"aria-describedby":this._renderARIADescribedBy(),"aria-expanded":h?null:v,"aria-label":this.props.ariaLabel,"aria-labelledby":this.props.ariaLabelledBy,"aria-multiline":this.props.ariaMultiline,"aria-owns":h?null:this.props.ariaOwneeID,autoCapitalize:this.props.autoCapitalize,autoComplete:this.props.autoComplete,autoCorrect:this.props.autoCorrect,className:E({notranslate:!h,"public/DraftEditor/content":!0}),contentEditable:!h,"data-testid":this.props.webDriverTestID,onBeforeInput:this._onBeforeInput,onBlur:this._onBlur,onCompositionEnd:this._onCompositionEnd,onCompositionStart:this._onCompositionStart,onCopy:this._onCopy,onCut:this._onCut,onDragEnd:this._onDragEnd,onDragEnter:this.onDragEnter,onDragLeave:this.onDragLeave,onDragOver:this._onDragOver,onDragStart:this._onDragStart,onDrop:this._onDrop,onFocus:this._onFocus,onInput:this._onInput,onKeyDown:this._onKeyDown,onKeyPress:this._onKeyPress,onKeyUp:this._onKeyUp,onMouseUp:this._onMouseUp,onPaste:this._onPaste,onSelect:this._onSelect,ref:this.props.editorRef,role:h?null:m,spellCheck:I&&this.props.spellCheck,style:{outline:"none",userSelect:"text",WebkitUserSelect:"text",whiteSpace:"pre-wrap",wordWrap:"break-word"},suppressContentEditableWarning:!0,tabIndex:this.props.tabIndex},y.createElement(O,{editor:this,editorState:l}),y.createElement(d,n({},C,{key:"contents"+this.state.contentsKey})))))},i.componentDidMount=function(){this._blockSelectEvents=!1,!N&&R("draft_ods_enabled")&&(N=!0,v.initODS()),this.setMode("edit"),D&&(this.editor?this.editor.ownerDocument.execCommand("AutoUrlDetect",!1,!1):globalThis.execCommand("AutoUrlDetect",!1,!1))},i.componentDidUpdate=function(){this._blockSelectEvents=!1,this._latestEditorState=this.props.editorState,this._latestCommittedEditorState=this.props.editorState},t}(y.Component);a(F,"defaultProps",{ariaDescribedBy:"{{editor_id_placeholder}}",blockRenderMap:c,blockRendererFn:function(){return null},blockStyleFn:function(){return""},keyBindingFn:T,readOnly:!1,spellCheck:!1,stripPastedStyles:!1}),e.exports=F},92063(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}var s=i(49162),o=i(13878),a=i(22155),l=i(72528),c=i(98556),u=i(46616),h=i(76675),d=i(22978),p=i(5026),g=i(93987),f=i(68982),m=i(40041),v=i(44110),C=i(25813),y=function(e,t){return e.getAnchorKey()===t||e.getFocusKey()===t},w=function(e){var t,i;function r(){for(var t,i,r,n,s=arguments.length,o=new Array(s),a=0;a<s;a++)o[a]=arguments[a];return n=void 0,(r="_node")in(i=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t=e.call.apply(e,[this].concat(o))||this))?Object.defineProperty(i,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):i[r]=n,t}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var w=r.prototype;return w.shouldComponentUpdate=function(e){return this.props.block!==e.block||this.props.tree!==e.tree||this.props.direction!==e.direction||y(e.selection,e.block.getKey())&&e.forceSelection},w.componentDidMount=function(){if(!this.props.preventScroll){var e=this.props.selection,t=e.getEndKey();if(e.getHasFocus()&&t===this.props.block.getKey()){var i=this._node;if(null!=i){var r,n=c.getScrollParent(i),s=g(n);if(n===window){var o=p(i);(r=o.y+o.height-f().height)>0&&window.scrollTo(s.x,s.y+r+10)}else v(i)||m(!1),(r=i.offsetHeight+i.offsetTop-(n.offsetTop+n.offsetHeight+s.y))>0&&l.setTop(n,l.getTop(n)+r+10)}}}},w._renderChildren=function(){var e=this,t=this.props.block,i=t.getKey(),r=t.getText(),l=this.props.tree.size-1,c=y(this.props.selection,i);return this.props.tree.map(function(d,p){var g=d.get("leaves");if(0===g.size)return null;var f=g.size-1,m=g.map(function(n,u){var h=o.encode(i,p,u),d=n.get("start"),g=n.get("end");return a.createElement(s,{key:h,offsetKey:h,block:t,start:d,selection:c?e.props.selection:null,forceSelection:e.props.forceSelection,text:r.slice(d,g),styleSet:t.getInlineStyleAt(d),customStyleMap:e.props.customStyleMap,customStyleFn:e.props.customStyleFn,isLast:p===l&&u===f})}).toArray(),v=d.get("decoratorKey");if(null==v)return m;if(!e.props.decorator)return m;var y=C(e.props.decorator),w=y.getComponentForKey(v);if(!w)return m;var S=y.getPropsForKey(v),b=o.encode(i,p,0),E=g.first().get("start"),A=g.last().get("end"),T=r.slice(E,A),M=t.getEntityAt(d.get("start")),R=h.getHTMLDirIfDifferent(u.getDirection(T),e.props.direction),_={contentState:e.props.contentState,decoratedText:T,dir:R,start:E,end:A,blockKey:i,entityKey:M,offsetKey:b};return a.createElement(w,n({},S,_,{key:b}),m)}).toArray()},w.render=function(){var e=this,t=this.props,i=t.direction,r=t.offsetKey,n=d({"public/DraftStyleDefault/block":!0,"public/DraftStyleDefault/ltr":"LTR"===i,"public/DraftStyleDefault/rtl":"RTL"===i});return a.createElement("div",{"data-offset-key":r,className:n,ref:function(t){return e._node=t}},this._renderChildren())},r}(a.Component);e.exports=w},35063(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){o(e,t,i[t])})}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var a=i(92694),l=i(13878),c=i(22155),u=i(72528),h=i(98556),d=i(5026),p=i(93987),g=i(68982),f=i(99251),m=i(40041),v=i(44110),C=(f.List,function(e,t){return e.getAnchorKey()===t||e.getFocusKey()===t}),y=function(e,t){var i=t.get(e.getType())||t.get("unstyled"),r=i.wrapper;return{Element:i.element||t.get("unstyled").element,wrapperTemplate:r}},w=function(e,t){var i=t(e);return i?{CustomComponent:i.component,customProps:i.props,customEditable:i.editable}:{}},S=function(e,t,i,r,n,o){var a={"data-block":!0,"data-editor":t,"data-offset-key":i,key:e.getKey(),ref:o},l=r(e);return l&&(a.className=l),void 0!==n.customEditable&&(a=s({},a,{contentEditable:n.customEditable,suppressContentEditableWarning:!0})),a},b=function(e){var t,i;function r(){for(var t,i=arguments.length,r=new Array(i),n=0;n<i;n++)r[n]=arguments[n];return o(function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t=e.call.apply(e,[this].concat(r))||this),"wrapperRef",c.createRef()),t}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var f=r.prototype;return f.shouldComponentUpdate=function(e){var t=this.props,i=t.block,r=t.direction,n=t.tree,s=!i.getChildKeys().isEmpty(),o=i!==e.block||n!==e.tree||r!==e.direction||C(e.selection,e.block.getKey())&&e.forceSelection;return s||o},f.componentDidMount=function(){var e=this.props.selection,t=e.getEndKey();if(e.getHasFocus()&&t===this.props.block.getKey()){var i=this.wrapperRef.current;if(i){var r,n=h.getScrollParent(i),s=p(n);if(n===window){var o=d(i);(r=o.y+o.height-g().height)>0&&window.scrollTo(s.x,s.y+r+10)}else{v(i)||m(!1);var a=i;(r=a.offsetHeight+a.offsetTop-(n.offsetHeight+s.y))>0&&u.setTop(n,u.getTop(n)+r+10)}}}},f.render=function(){var e=this,t=this.props,i=t.block,o=t.blockRenderMap,u=t.blockRendererFn,h=t.blockStyleFn,d=t.contentState,p=t.decorator,g=t.editorKey,f=t.editorState,m=t.customStyleFn,v=t.customStyleMap,b=t.direction,E=t.forceSelection,A=t.selection,T=t.tree,M=null;i.children.size&&(M=i.children.reduce(function(t,i){var n=l.encode(i,0,0),a=d.getBlockForKey(i),p=w(a,u),m=p.CustomComponent||r,v=y(a,o),C=v.Element,b=v.wrapperTemplate,E=S(a,g,n,h,p,null),A=s({},e.props,{tree:f.getBlockTree(i),blockProps:p.customProps,offsetKey:n,block:a});return t.push(c.createElement(C,E,c.createElement(m,A))),!b||function(e,t){var i=e.getNextSiblingKey();return!!i&&t.getBlockForKey(i).getType()===e.getType()}(a,d)||function(e,t,i){var r=[],n=!0,s=!1,o=void 0;try{for(var a,u=i.reverse()[Symbol.iterator]();!(n=(a=u.next()).done);n=!0){var h=a.value;if(h.type!==t)break;r.push(h)}}catch(e){s=!0,o=e}finally{try{n||null==u.return||u.return()}finally{if(s)throw o}}i.splice(i.indexOf(r[0]),r.length+1);var d=r.reverse(),p=d[0].key;i.push(c.cloneElement(e,{key:"".concat(p,"-wrap"),"data-offset-key":l.encode(p,0,0)},d))}(b,C,t),t},[]));var R=i.getKey(),_=l.encode(R,0,0),P=w(i,u),x=P.CustomComponent,D=null!=x?c.createElement(x,n({},this.props,{tree:f.getBlockTree(R),blockProps:P.customProps,offsetKey:_,block:i})):c.createElement(a,{block:i,children:M,contentState:d,customStyleFn:m,customStyleMap:v,decorator:p,direction:b,forceSelection:E,hasSelection:C(A,R),selection:A,tree:T});if(i.getParentKey())return D;var I=y(i,o).Element,L=S(i,g,_,h,P,this.wrapperRef);return c.createElement(I,L,D)},r}(c.Component);e.exports=b},60913(e,t,i){"use strict";var r=i(94199),n=i(58267),s=i(13878),o=i(59539),a=i(4617),l=i(63390),c=i(10292),u=i(71093),h=i(15801),d=i(60836),p=i(25813),g=l.isBrowser("IE"),f=!1,m=!1,v=null,C={onCompositionStart:function(e){m=!0,function(e){v||(v=new r(u(e))).start()}(e)},onCompositionEnd:function(e){f=!1,m=!1,setTimeout(function(){f||C.resolveComposition(e)},20)},onSelect:c,onKeyDown:function(e,t){if(!m)return C.resolveComposition(e),void e._onKeyDown(t);t.which!==a.RIGHT&&t.which!==a.LEFT||t.preventDefault()},onKeyPress:function(e,t){t.which===a.RETURN&&t.preventDefault()},resolveComposition:function(e){if(!m){var t=p(v).stopAndFlushMutations();v=null,f=!0;var i=o.set(e._latestEditorState,{inCompositionMode:!1});if(e.exitCurrentMode(),t.size){var r=i.getCurrentContent();t.forEach(function(e,t){var a=s.decode(t),l=a.blockKey,c=a.decoratorKey,u=a.leafKey,h=i.getBlockTree(l).getIn([c,"leaves",u]),p=h.start,g=h.end,f=i.getSelection().merge({anchorKey:l,focusKey:l,anchorOffset:p,focusOffset:g,isBackward:!1}),m=d(r,f),v=r.getBlockForKey(l).getInlineStyleAt(p);r=n.replaceText(r,f,e,v,m),i=o.set(i,{currentContent:r})});var a=h(i,u(e)).selectionState;e.restoreEditorDOM();var l=g?o.forceSelection(i,a):o.acceptSelection(i,a);e.update(o.push(l,r,"insert-characters"))}else e.update(i)}}};e.exports=C},47672(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){o(e,t,i[t])})}return e}function o(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var a=i(92063),l=i(13878),c=i(22155),u=i(22978),h=i(66145),d=i(25813),p=function(e,t,i,r){return u({"public/DraftStyleDefault/unorderedListItem":"unordered-list-item"===e,"public/DraftStyleDefault/orderedListItem":"ordered-list-item"===e,"public/DraftStyleDefault/reset":i,"public/DraftStyleDefault/depth0":0===t,"public/DraftStyleDefault/depth1":1===t,"public/DraftStyleDefault/depth2":2===t,"public/DraftStyleDefault/depth3":3===t,"public/DraftStyleDefault/depth4":t>=4,"public/DraftStyleDefault/listLTR":"LTR"===r,"public/DraftStyleDefault/listRTL":"RTL"===r})},g=function(e){var t,i;function r(){return e.apply(this,arguments)||this}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var o=r.prototype;return o.shouldComponentUpdate=function(e){var t=this.props.editorState,i=e.editorState;if(t.getDirectionMap()!==i.getDirectionMap())return!0;if(t.getSelection().getHasFocus()!==i.getSelection().getHasFocus())return!0;var r=i.getNativelyRenderedContent(),n=t.isInCompositionMode(),s=i.isInCompositionMode();if(t===i||null!==r&&i.getCurrentContent()===r||n&&s)return!1;var o=t.getCurrentContent(),a=i.getCurrentContent(),l=t.getDecorator(),c=i.getDecorator();return n!==s||o!==a||l!==c||i.mustForceSelection()},o.render=function(){for(var e=this.props,t=e.blockRenderMap,i=e.blockRendererFn,r=e.blockStyleFn,o=e.customStyleMap,u=e.customStyleFn,g=e.editorState,f=e.editorKey,m=e.preventScroll,v=e.textDirectionality,C=g.getCurrentContent(),y=g.getSelection(),w=g.mustForceSelection(),S=g.getDecorator(),b=d(g.getDirectionMap()),E=C.getBlocksAsArray(),A=[],T=null,M=null,R=0;R<E.length;R++){var _=E[R],P=_.getKey(),x=_.getType(),D=i(_),I=void 0,L=void 0,N=void 0;D&&(I=D.component,L=D.props,N=D.editable);var O=v||b.get(P),F=l.encode(P,0,0),k={contentState:C,block:_,blockProps:L,blockStyleFn:r,customStyleMap:o,customStyleFn:u,decorator:S,direction:O,forceSelection:w,offsetKey:F,preventScroll:m,selection:y,tree:g.getBlockTree(P)},G=t.get(x)||t.get("unstyled"),V=G.wrapper,H=G.element||t.get("unstyled").element,B=_.getDepth(),z="";r&&(z=r(_)),"li"===H&&(z=h(z,p(x,B,M!==V||null===T||B>T,O)));var U=I||a,W={className:z,"data-block":!0,"data-editor":f,"data-offset-key":F,key:P};void 0!==N&&(W=s({},W,{contentEditable:N,suppressContentEditableWarning:!0}));var j=c.createElement(H,W,c.createElement(U,n({},k,{key:P})));A.push({block:j,wrapperTemplate:V,key:P,offsetKey:F}),T=V?_.getDepth():null,M=V}for(var K=[],$=0;$<A.length;){var q=A[$];if(q.wrapperTemplate){var Y=[];do{Y.push(A[$].block),$++}while($<A.length&&A[$].wrapperTemplate===q.wrapperTemplate);var Q=c.cloneElement(q.wrapperTemplate,{key:q.key+"-wrap","data-offset-key":q.offsetKey},Y);K.push(Q)}else K.push(q.block),$++}return c.createElement("div",{"data-contents":"true"},K)},r}(c.Component);e.exports=g},74804(e,t,i){"use strict";var r=i(17595)("draft_tree_data_support");e.exports=i(r?88074:47672)},88074(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}var s=i(35063),o=i(13878),a=i(22155),l=i(25813),c=function(e){var t,i;function r(){return e.apply(this,arguments)||this}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var c=r.prototype;return c.shouldComponentUpdate=function(e){var t=this.props.editorState,i=e.editorState;if(t.getDirectionMap()!==i.getDirectionMap())return!0;if(t.getSelection().getHasFocus()!==i.getSelection().getHasFocus())return!0;var r=i.getNativelyRenderedContent(),n=t.isInCompositionMode(),s=i.isInCompositionMode();if(t===i||null!==r&&i.getCurrentContent()===r||n&&s)return!1;var o=t.getCurrentContent(),a=i.getCurrentContent(),l=t.getDecorator(),c=i.getDecorator();return n!==s||o!==a||l!==c||i.mustForceSelection()},c.render=function(){for(var e=this.props,t=e.blockRenderMap,i=e.blockRendererFn,r=e.blockStyleFn,c=e.customStyleMap,u=e.customStyleFn,h=e.editorState,d=e.editorKey,p=e.textDirectionality,g=h.getCurrentContent(),f=h.getSelection(),m=h.mustForceSelection(),v=h.getDecorator(),C=l(h.getDirectionMap()),y=[],w=g.getBlocksAsArray()[0];w;){var S=w.getKey(),b={blockRenderMap:t,blockRendererFn:i,blockStyleFn:r,contentState:g,customStyleFn:u,customStyleMap:c,decorator:v,editorKey:d,editorState:h,forceSelection:m,selection:f,block:w,direction:p||C.get(S),tree:h.getBlockTree(S)},E=(t.get(w.getType())||t.get("unstyled")).wrapper;y.push({block:a.createElement(s,n({key:S},b)),wrapperTemplate:E,key:S,offsetKey:o.encode(S,0,0)});var A=w.getNextSiblingKey();w=A?g.getBlockForKey(A):null}for(var T=[],M=0;M<y.length;){var R=y[M];if(R.wrapperTemplate){var _=[];do{_.push(y[M].block),M++}while(M<y.length&&y[M].wrapperTemplate===R.wrapperTemplate);var P=a.cloneElement(R.wrapperTemplate,{key:R.key+"-wrap","data-offset-key":R.offsetKey},_);T.push(P)}else T.push(R.block),M++}return a.createElement("div",{"data-contents":"true"},T)},r}(a.Component);e.exports=c},859(e,t,i){"use strict";var r=i(46084);function n(){return n=r||function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)Object.prototype.hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},n.apply(this,arguments)}var s=i(13878),o=i(22155),a=i(46616),l=i(76675),c=function(e){var t,i;function r(){return e.apply(this,arguments)||this}return i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i,r.prototype.render=function(){var e=this.props,t=e.block,i=e.children,r=e.contentState,c=e.decorator,u=e.decoratorKey,h=e.direction,d=e.leafSet,p=e.text,g=t.getKey(),f=d.get("leaves"),m=c.getComponentForKey(u),v=c.getPropsForKey(u),C=s.encode(g,parseInt(u,10),0),y=p.slice(f.first().get("start"),f.last().get("end")),w=l.getHTMLDirIfDifferent(a.getDirection(y),h);return o.createElement(m,n({},v,{contentState:r,decoratedText:y,dir:w,key:C,entityKey:t.getEntityAt(d.get("start")),offsetKey:C}),i)},r}(o.Component);e.exports=c},38001(e,t,i){"use strict";var r=i(81354),n=i(58267),s=i(59539),o=i(65461),a=i(82097),l=i(27786),c=i(69397),u=i(82826),h=i(46415),d=i(25813),p={onDragEnd:function(e){e.exitCurrentMode(),g(e)},onDrop:function(e,t){var i=new r(t.nativeEvent.dataTransfer),u=e._latestEditorState,p=function(e,t){var i=null,r=null,n=a(e.currentTarget);if("function"==typeof n.caretRangeFromPoint){var s=n.caretRangeFromPoint(e.x,e.y);i=s.startContainer,r=s.startOffset}else{if(!e.rangeParent)return null;i=e.rangeParent,r=e.rangeOffset}i=d(i),r=d(r);var l=d(o(i));return c(t,l,r,l,r)}(t.nativeEvent,u);if(t.preventDefault(),e._dragCount=0,e.exitCurrentMode(),null!=p){var m=i.getFiles();if(m.length>0){if(e.props.handleDroppedFiles&&h(e.props.handleDroppedFiles(p,m)))return;l(m,function(t){t&&e.update(f(u,p,t))})}else{var v=e._internalDrag?"internal":"external";e.props.handleDrop&&h(e.props.handleDrop(p,i,v))||(e._internalDrag?e.update(function(e,t){var i=n.moveText(e.getCurrentContent(),e.getSelection(),t);return s.push(e,i,"insert-fragment")}(u,p)):e.update(f(u,p,i.getText()))),g(e)}}}};function g(e){e._internalDrag=!1;var t=e.editorContainer;if(t){var i=new MouseEvent("mouseup",{view:u(t),bubbles:!0,cancelable:!0});t.dispatchEvent(i)}}function f(e,t,i){var r=n.insertText(e.getCurrentContent(),t,i,e.getCurrentInlineStyle());return s.push(e,r,"insert-fragment")}e.exports=p},51163(e,t,i){"use strict";var r=i(63390),n=i(45995),s=i(23717),o=i(46438),a=i(78073),l=i(43046),c=i(76100),u=i(92244),h=i(38514),d=i(29830),p=i(41345),g=i(35346),f=i(10292),m=r.isBrowser("Chrome"),v=r.isBrowser("Firefox"),C=m||v?f:function(e){},y={onBeforeInput:n,onBlur:s,onCompositionStart:o,onCopy:a,onCut:l,onDragOver:c,onDragStart:u,onFocus:h,onInput:d,onKeyDown:p,onPaste:g,onSelect:f,onMouseUp:C,onKeyUp:C};e.exports=y},94951(e,t,i){"use strict";var r=i(70316).unstable_flushControlled;e.exports=r},49162(e,t,i){"use strict";var r=i(46084),n=i(5413),s=i(22155),o=i(40041),a=i(4734),l=i(90933).setDraftEditorSelection,c=function(e){var t,i;function c(){for(var t,i,r,n,s=arguments.length,o=new Array(s),a=0;a<s;a++)o[a]=arguments[a];return n=void 0,(r="leaf")in(i=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t=e.call.apply(e,[this].concat(o))||this))?Object.defineProperty(i,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):i[r]=n,t}i=e,(t=c).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var u=c.prototype;return u._setSelection=function(){var e=this.props.selection;if(null!=e&&e.getHasFocus()){var t=this.props,i=t.block,r=t.start,n=t.text,s=i.getKey(),c=r+n.length;if(e.hasEdgeWithin(s,r,c)){var u=this.leaf;u||o(!1);var h,d=u.firstChild;d||o(!1),d.nodeType===Node.TEXT_NODE?h=d:a(d)?h=u:(h=d.firstChild)||o(!1),l(e,h,s,r,c)}}},u.shouldComponentUpdate=function(e){var t=this.leaf;return t||o(!1),t.textContent!==e.text||e.styleSet!==this.props.styleSet||e.forceSelection},u.componentDidUpdate=function(){this._setSelection()},u.componentDidMount=function(){this._setSelection()},u.render=function(){var e=this,t=this.props.block,i=this.props.text;i.endsWith("\n")&&this.props.isLast&&(i+="\n");var o=this.props,a=o.customStyleMap,l=o.customStyleFn,c=o.offsetKey,u=o.styleSet,h=u.reduce(function(e,t){var i={},n=a[t];return void 0!==n&&e.textDecoration!==n.textDecoration&&(i.textDecoration=[e.textDecoration,n.textDecoration].join(" ").trim()),r(e,n,i)},{});if(l){var d=l(u,t);h=r(h,d)}return s.createElement("span",{"data-offset-key":c,ref:function(t){return e.leaf=t},style:h},s.createElement(n,null,i))},c}(s.Component);e.exports=c},92694(e,t,i){"use strict";var r=i(859),n=i(49162),s=i(13878),o=i(99251),a=i(22155),l=i(22978),c=(o.List,function(e){var t,i;function o(){return e.apply(this,arguments)||this}return i=e,(t=o).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i,o.prototype.render=function(){var e=this.props,t=e.block,i=e.contentState,o=e.customStyleFn,c=e.customStyleMap,u=e.decorator,h=e.direction,d=e.forceSelection,p=e.hasSelection,g=e.selection,f=e.tree,m=t.getKey(),v=t.getText(),C=f.size-1,y=this.props.children||f.map(function(e,l){var f=e.get("decoratorKey"),y=e.get("leaves"),w=y.size-1,S=y.map(function(e,i){var r=s.encode(m,l,i),u=e.get("start"),h=e.get("end");return a.createElement(n,{key:r,offsetKey:r,block:t,start:u,selection:p?g:null,forceSelection:d,text:v.slice(u,h),styleSet:t.getInlineStyleAt(u),customStyleMap:c,customStyleFn:o,isLast:f===C&&i===w})}).toArray();return f&&u?a.createElement(r,{block:t,children:S,contentState:i,decorator:u,decoratorKey:f,direction:h,leafSet:e,text:v,key:l}):S}).toArray();return a.createElement("div",{"data-offset-key":s.encode(m,0,0),className:l({"public/DraftStyleDefault/block":!0,"public/DraftStyleDefault/ltr":"LTR"===h,"public/DraftStyleDefault/rtl":"RTL"===h})},y)},o}(a.Component));e.exports=c},12803(e,t,i){"use strict";var r=i(22155),n=i(22978),s=function(e){var t,i;function s(){return e.apply(this,arguments)||this}i=e,(t=s).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var o=s.prototype;return o.shouldComponentUpdate=function(e){return this.props.text!==e.text||this.props.editorState.getSelection().getHasFocus()!==e.editorState.getSelection().getHasFocus()},o.render=function(){var e=this.props.editorState.getSelection().getHasFocus(),t=n({"public/DraftEditorPlaceholder/root":!0,"public/DraftEditorPlaceholder/hasFocus":e});return r.createElement("div",{className:t},r.createElement("div",{className:n("public/DraftEditorPlaceholder/inner"),id:this.props.accessibilityID,style:{whiteSpace:"pre-wrap"}},this.props.text))},s}(r.Component);e.exports=s},5413(e,t,i){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(22155),o=i(63390),a=i(40041),l=i(66305),c=o.isBrowser("IE <= 11"),u=function(e){var t,i;function o(t){var i;return n(r(i=e.call(this,t)||this),"_forceFlag",void 0),n(r(i),"_node",void 0),i._forceFlag=!1,i}i=e,(t=o).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var u=o.prototype;return u.shouldComponentUpdate=function(e){var t=this._node,i=""===e.children;l(t)||a(!1);var r=t;return i?!function(e){return c?"\n"===e.textContent:"BR"===e.tagName}(r):r.textContent!==e.children},u.componentDidMount=function(){this._forceFlag=!this._forceFlag},u.componentDidUpdate=function(){this._forceFlag=!this._forceFlag},u.render=function(){var e,t=this;return""===this.props.children?this._forceFlag?(e=function(e){return t._node=e},c?s.createElement("span",{key:"A","data-text":"true",ref:e},"\n"):s.createElement("br",{key:"A","data-text":"true",ref:e})):function(e){return c?s.createElement("span",{key:"B","data-text":"true",ref:e},"\n"):s.createElement("br",{key:"B","data-text":"true",ref:e})}(function(e){return t._node=e}):s.createElement("span",{key:this._forceFlag?"A":"B","data-text":"true",ref:function(e){return t._node=e}},this.props.children)},o}(s.Component);e.exports=u},7618(e){"use strict";e.exports={initODS:function(){},handleExtensionCausedError:function(){}}},70873(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(72066),s=i(99251),o=i(40041),a=i(10254),l=(0,s.Map)(),c=a();function u(e,t){console.warn("WARNING: "+e+' will be deprecated soon!\nPlease use "'+t+'" instead.')}var h={getLastCreatedEntityKey:function(){return u("DraftEntity.getLastCreatedEntityKey","contentState.getLastCreatedEntityKey"),h.__getLastCreatedEntityKey()},create:function(e,t,i){return u("DraftEntity.create","contentState.createEntity"),h.__create(e,t,i)},add:function(e){return u("DraftEntity.add","contentState.addEntity"),h.__add(e)},get:function(e){return u("DraftEntity.get","contentState.getEntity"),h.__get(e)},__getAll:function(){return l},__loadWithEntities:function(e){l=e,c=a()},mergeData:function(e,t){return u("DraftEntity.mergeData","contentState.mergeEntityData"),h.__mergeData(e,t)},replaceData:function(e,t){return u("DraftEntity.replaceData","contentState.replaceEntityData"),h.__replaceData(e,t)},__getLastCreatedEntityKey:function(){return c},__create:function(e,t,i){return h.__add(new n({type:e,mutability:t,data:i||{}}))},__add:function(e){return c=a(),l=l.set(c,e),c},__get:function(e){var t=l.get(e);return t||o(!1),t},__mergeData:function(e,t){var i=h.__get(e),n=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),n.forEach(function(t){r(e,t,i[t])})}return e}({},i.getData(),t),s=i.set("data",n);return l=l.set(e,s),s},__replaceData:function(e,t){var i=h.__get(e).set("data",t);return l=l.set(e,i),i}};e.exports=h},72066(e,t,i){"use strict";var r=function(e){var t,i;function r(){return e.apply(this,arguments)||this}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var n=r.prototype;return n.getType=function(){return this.get("type")},n.getMutability=function(){return this.get("mutability")},n.getData=function(){return this.get("data")},r}((0,i(99251).Record)({type:"TOKEN",mutability:"IMMUTABLE",data:Object}));e.exports=r},451(e){"use strict";e.exports={getRemovalRange:function(e,t,i,r,n){var s=i.split(" ");s=s.map(function(e,t){if("forward"===n){if(t>0)return" "+e}else if(t<s.length-1)return e+" ";return e});for(var o,a=r,l=null,c=null,u=0;u<s.length;u++){if(e<(o=a+s[u].length)&&a<t)null!==l||(l=a),c=o;else if(null!==l)break;a=o}var h=r+i.length,d=l===r,p=c===h;return(!d&&p||d&&!p)&&("forward"===n?c!==h&&c++:l!==r&&l--),{start:l,end:c}}}},35693(e){"use strict";e.exports={logBlockedSelectionEvent:function(){return null},logSelectionStateFailure:function(){return null}}},58267(e,t,i){"use strict";var r=i(41671),n=i(61773),s=i(40377),o=i(64047),a=i(54095),l=i(99251),c=i(72368),u=i(32983),h=i(40041),d=i(79981),p=i(91825),g=i(5646),f=i(2661),m=l.OrderedSet,v={replaceText:function(e,t,i,n,s){var o=p(e,t),a=g(o,t),l=r.create({style:n||m(),entity:s||null});return u(a,a.getSelectionAfter(),i,l)},insertText:function(e,t,i,r,n){return t.isCollapsed()||h(!1),v.replaceText(e,t,i,r,n)},moveText:function(e,t,i){var r=a(e,t),n=v.removeRange(e,t,"backward");return v.replaceWithFragment(n,i,r)},replaceWithFragment:function(e,t,i){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"REPLACE_WITH_NEW_DATA",n=p(e,t),s=g(n,t);return c(s,s.getSelectionAfter(),i,r)},removeRange:function(e,t,i){var r,n,s,a;t.getIsBackward()&&(t=t.merge({anchorKey:t.getFocusKey(),anchorOffset:t.getFocusOffset(),focusKey:t.getAnchorKey(),focusOffset:t.getAnchorOffset(),isBackward:!1})),r=t.getAnchorKey(),n=t.getFocusKey(),s=e.getBlockForKey(r),a=e.getBlockForKey(n);var l=t.getStartOffset(),c=t.getEndOffset(),u=s.getEntityAt(l),h=a.getEntityAt(c-1);if(r===n&&u&&u===h){var d=o(e.getEntityMap(),s,a,t,i);return g(e,d)}var f=p(e,t);return g(f,t)},splitBlock:function(e,t){var i=p(e,t),r=g(i,t);return f(r,r.getSelectionAfter())},applyInlineStyle:function(e,t,i){return n.add(e,t,i)},removeInlineStyle:function(e,t,i){return n.remove(e,t,i)},setBlockType:function(e,t,i){return d(e,t,function(e){return e.merge({type:i,depth:0})})},setBlockData:function(e,t,i){return d(e,t,function(e){return e.merge({data:i})})},mergeBlockData:function(e,t,i){return d(e,t,function(e){return e.merge({data:e.getData().merge(i)})})},applyEntity:function(e,t,i){var r=p(e,t);return s(r,t,i)}};e.exports=v},13878(e){"use strict";var t="-",i={encode:function(e,i,r){return e+t+i+t+r},decode:function(e){var i=e.split(t).reverse(),r=i[0],n=i[1];return{blockKey:i.slice(2).reverse().join(t),decoratorKey:parseInt(n,10),leafKey:parseInt(r,10)}}};e.exports=i},42471(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(40643),s=i(31527),o=i(86739),a=i(12634),l=i(38413),c=i(17595),u=i(99251),h=i(10160),d=u.List,p=u.Repeat,g=c("draft_tree_data_support"),f=g?s:n,m={processHTML:function(e,t){return o(e,l,t)},processText:function(e,t,i){return e.reduce(function(e,n,s){n=h(n);var o=a(),l={key:o,type:i,text:n,characterList:d(p(t,n.length))};if(g&&0!==s){var c=s-1;l=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),n.forEach(function(t){r(e,t,i[t])})}return e}({},l,{prevSibling:(e[c]=e[c].merge({nextSibling:o})).getKey()})}return e.push(new f(l)),e},[])}};e.exports=m},76425(e,t,i){"use strict";var r="['‘’]",n="\\s|(?![_])"+i(59544).getPunctuation(),s=new RegExp("^(?:"+n+")*(?:"+r+"|(?!"+n+").)*(?:(?!"+n+").)"),o=new RegExp("(?:(?!"+n+").)(?:"+r+"|(?!"+n+").)*(?:"+n+")*$");function a(e,t){var i=t?o.exec(e):s.exec(e);return i?i[0]:e}var l={getBackward:function(e){return a(e,!0)},getForward:function(e){return a(e,!1)}};e.exports=l},93184(e){"use strict";var t={stringify:function(e){return"_"+String(e)},unstringify:function(e){return e.slice(1)}};e.exports=t},85063(e,t,i){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){n(e,t,i[t])})}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(12634),o=i(40041),a=function(e){if(!e||!e.type)return!1;var t=e.type;return"unordered-list-item"===t||"ordered-list-item"===t},l={fromRawTreeStateToRawState:function(e){var t=e.blocks,i=[];return Array.isArray(t)||o(!1),Array.isArray(t)&&t.length?(function(e,t){for(var i=[].concat(e).reverse();i.length;){var r=i.pop();t(r);var n=r.children;Array.isArray(n)||o(!1),i=i.concat([].concat(n.reverse()))}}(t,function(e){var t=r({},e);a(e)&&(t.depth=t.depth||0,function(e){Array.isArray(e.children)&&(e.children=e.children.map(function(t){return t.type===e.type?r({},t,{depth:(e.depth||0)+1}):t}))}(e),null!=e.children&&e.children.length>0)||(delete t.children,i.push(t))}),e.blocks=i,r({},e,{blocks:i})):e},fromRawStateToRawTreeState:function(e){var t=[],i=[];return e.blocks.forEach(function(e){var n=a(e),o=e.depth||0,l=r({},e,{children:[]});if(n){var c=i[0];if(null==c&&0===o)t.push(l);else if(null==c||c.depth<o-1){var u={key:s(),text:"",depth:o-1,type:e.type,children:[],entityRanges:[],inlineStyleRanges:[]};i.unshift(u),1===o?t.push(u):null!=c&&c.children.push(u),u.children.push(l)}else if(c.depth===o-1)c.children.push(l);else{for(;null!=c&&c.depth>=o;)i.shift(),c=i[0];o>0?c.children.push(l):t.push(l)}}else t.push(l)}),r({},e,{blocks:t})}};e.exports=l},59415(e,t,i){"use strict";i(92697),e.exports={isValidBlock:function(e,t){var i=e.getKey(),r=e.getParentKey();if(null!=r&&!t.get(r).getChildKeys().includes(i))return!1;if(!e.getChildKeys().map(function(e){return t.get(e)}).every(function(e){return e.getParentKey()===i}))return!1;var n=e.getPrevSiblingKey();if(null!=n&&t.get(n).getNextSiblingKey()!==i)return!1;var s=e.getNextSiblingKey();return(null==s||t.get(s).getPrevSiblingKey()===i)&&!(null!==s&&null!==n&&n===s||""!=e.text&&e.getChildKeys().size>0)},isConnectedTree:function(e){var t=e.toArray().filter(function(e){return null==e.getParentKey()&&null==e.getPrevSiblingKey()});if(1!==t.length)return!1;for(var i=0,r=t.shift().getKey(),n=[];null!=r;){var s=e.get(r),o=s.getChildKeys(),a=s.getNextSiblingKey();if(o.size>0){null!=a&&n.unshift(a);var l=o.map(function(t){return e.get(t)}).find(function(e){return null==e.getPrevSiblingKey()});if(null==l)return!1;r=l.getKey()}else r=null!=s.getNextSiblingKey()?s.getNextSiblingKey():n.shift();i++}return i===e.size},isValidTree:function(e){var t=this;return!!e.toArray().every(function(i){return t.isValidBlock(i,e)})&&this.isConnectedTree(e)}}},76539(e,t,i){"use strict";var r,n=i(75361),s=i(99251),o=i(25813),a=s.OrderedMap,l={getDirectionMap:function(e,t){r?r.reset():r=new n;var i=e.getBlockMap(),l=i.valueSeq().map(function(e){return o(r).getDirection(e.getText())}),c=a(i.keySeq().zip(l));return null!=t&&s.is(t,c)?t:c}};e.exports=l},59539(e,t,i){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){n(e,t,i[t])})}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(52568),o=i(23315),a=i(76539),l=i(27442),c=i(99251),u=c.OrderedSet,h=c.Record,d=c.Stack,p=c.OrderedMap,g=c.List,f=h({allowUndo:!0,currentContent:null,decorator:null,directionMap:null,forceSelection:!1,inCompositionMode:!1,inlineStyleOverride:null,lastChangeType:null,nativelyRenderedContent:null,redoStack:d(),selection:null,treeMap:null,undoStack:d()}),m=function(){t.createEmpty=function(e){return this.createWithText("",e)},t.createWithText=function(e,i){return t.createWithContent(o.createFromText(e),i)},t.createWithContent=function(e,i){if(0===e.getBlockMap().count())return t.createEmpty(i);var r=e.getBlockMap().first().getKey();return t.create({currentContent:e,undoStack:d(),redoStack:d(),decorator:i||null,selection:l.createEmpty(r)})},t.create=function(e){var i=e.currentContent,n=r({},e,{treeMap:C(i,e.decorator),directionMap:a.getDirectionMap(i)});return new t(new f(n))},t.fromJS=function(e){return new t(new f(r({},e,{directionMap:null!=e.directionMap?p(e.directionMap):e.directionMap,inlineStyleOverride:null!=e.inlineStyleOverride?u(e.inlineStyleOverride):e.inlineStyleOverride,nativelyRenderedContent:null!=e.nativelyRenderedContent?o.fromJS(e.nativelyRenderedContent):e.nativelyRenderedContent,redoStack:null!=e.redoStack?d(e.redoStack.map(function(e){return o.fromJS(e)})):e.redoStack,selection:null!=e.selection?new l(e.selection):e.selection,treeMap:null!=e.treeMap?p(e.treeMap).map(function(e){return g(e).map(function(e){return s.fromJS(e)})}):e.treeMap,undoStack:null!=e.undoStack?d(e.undoStack.map(function(e){return o.fromJS(e)})):e.undoStack,currentContent:o.fromJS(e.currentContent)})))},t.set=function(e,i){return new t(e.getImmutable().withMutations(function(t){var r=t.get("decorator"),n=r;null===i.decorator?n=null:i.decorator&&(n=i.decorator);var o=i.currentContent||e.getCurrentContent();if(n!==r){var a,l=t.get("treeMap");return a=n&&r?function(e,t,i,r,n){return i.merge(t.toSeq().filter(function(t){return r.getDecorations(t,e)!==n.getDecorations(t,e)}).map(function(t){return s.generate(e,t,r)}))}(o,o.getBlockMap(),l,n,r):C(o,n),void t.merge({decorator:n,treeMap:a,nativelyRenderedContent:null})}o!==e.getCurrentContent()&&t.set("treeMap",function(e,t,i,r){var n=e.getCurrentContent().set("entityMap",i),o=n.getBlockMap();return e.getImmutable().get("treeMap").merge(t.toSeq().filter(function(e,t){return e!==o.get(t)}).map(function(e){return s.generate(n,e,r)}))}(e,o.getBlockMap(),o.getEntityMap(),n)),t.merge(i)}))};var e=t.prototype;function t(e){n(this,"_immutable",void 0),this._immutable=e}return e.toJS=function(){return this.getImmutable().toJS()},e.getAllowUndo=function(){return this.getImmutable().get("allowUndo")},e.getCurrentContent=function(){return this.getImmutable().get("currentContent")},e.getUndoStack=function(){return this.getImmutable().get("undoStack")},e.getRedoStack=function(){return this.getImmutable().get("redoStack")},e.getSelection=function(){return this.getImmutable().get("selection")},e.getDecorator=function(){return this.getImmutable().get("decorator")},e.isInCompositionMode=function(){return this.getImmutable().get("inCompositionMode")},e.mustForceSelection=function(){return this.getImmutable().get("forceSelection")},e.getNativelyRenderedContent=function(){return this.getImmutable().get("nativelyRenderedContent")},e.getLastChangeType=function(){return this.getImmutable().get("lastChangeType")},e.getInlineStyleOverride=function(){return this.getImmutable().get("inlineStyleOverride")},t.setInlineStyleOverride=function(e,i){return t.set(e,{inlineStyleOverride:i})},e.getCurrentInlineStyle=function(){var e=this.getInlineStyleOverride();if(null!=e)return e;var t=this.getCurrentContent(),i=this.getSelection();return i.isCollapsed()?function(e,t){var i=t.getStartKey(),r=t.getStartOffset(),n=e.getBlockForKey(i);return r>0?n.getInlineStyleAt(r-1):n.getLength()?n.getInlineStyleAt(0):y(e,i)}(t,i):function(e,t){var i=t.getStartKey(),r=t.getStartOffset(),n=e.getBlockForKey(i);return r<n.getLength()?n.getInlineStyleAt(r):r>0?n.getInlineStyleAt(r-1):y(e,i)}(t,i)},e.getBlockTree=function(e){return this.getImmutable().getIn(["treeMap",e])},e.isSelectionAtStartOfContent=function(){var e=this.getCurrentContent().getBlockMap().first().getKey();return this.getSelection().hasEdgeWithin(e,0,0)},e.isSelectionAtEndOfContent=function(){var e=this.getCurrentContent().getBlockMap().last(),t=e.getLength();return this.getSelection().hasEdgeWithin(e.getKey(),t,t)},e.getDirectionMap=function(){return this.getImmutable().get("directionMap")},t.acceptSelection=function(e,t){return v(e,t,!1)},t.forceSelection=function(e,t){return t.getHasFocus()||(t=t.set("hasFocus",!0)),v(e,t,!0)},t.moveSelectionToEnd=function(e){var i=e.getCurrentContent().getLastBlock(),r=i.getKey(),n=i.getLength();return t.acceptSelection(e,new l({anchorKey:r,anchorOffset:n,focusKey:r,focusOffset:n,isBackward:!1}))},t.moveFocusToEnd=function(e){var i=t.moveSelectionToEnd(e);return t.forceSelection(i,i.getSelection())},t.push=function(e,i,r){var n=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];if(e.getCurrentContent()===i)return e;var s=a.getDirectionMap(i,e.getDirectionMap());if(!e.getAllowUndo())return t.set(e,{currentContent:i,directionMap:s,lastChangeType:r,selection:i.getSelectionAfter(),forceSelection:n,inlineStyleOverride:null});var o=e.getSelection(),l=e.getCurrentContent(),c=e.getUndoStack(),u=i;o!==l.getSelectionAfter()||function(e,t){return t!==e.getLastChangeType()||"insert-characters"!==t&&"backspace-character"!==t&&"delete-character"!==t}(e,r)?(c=c.push(l),u=u.set("selectionBefore",o)):"insert-characters"!==r&&"backspace-character"!==r&&"delete-character"!==r||(u=u.set("selectionBefore",l.getSelectionBefore()));var h=e.getInlineStyleOverride();-1===["adjust-depth","change-block-type","split-block"].indexOf(r)&&(h=null);var p={currentContent:u,directionMap:s,undoStack:c,redoStack:d(),lastChangeType:r,selection:i.getSelectionAfter(),forceSelection:n,inlineStyleOverride:h};return t.set(e,p)},t.undo=function(e){if(!e.getAllowUndo())return e;var i=e.getUndoStack(),r=i.peek();if(!r)return e;var n=e.getCurrentContent(),s=a.getDirectionMap(r,e.getDirectionMap());return t.set(e,{currentContent:r,directionMap:s,undoStack:i.shift(),redoStack:e.getRedoStack().push(n),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"undo",nativelyRenderedContent:null,selection:n.getSelectionBefore()})},t.redo=function(e){if(!e.getAllowUndo())return e;var i=e.getRedoStack(),r=i.peek();if(!r)return e;var n=e.getCurrentContent(),s=a.getDirectionMap(r,e.getDirectionMap());return t.set(e,{currentContent:r,directionMap:s,undoStack:e.getUndoStack().push(n),redoStack:i.shift(),forceSelection:!0,inlineStyleOverride:null,lastChangeType:"redo",nativelyRenderedContent:null,selection:r.getSelectionAfter()})},e.getImmutable=function(){return this._immutable},t}();function v(e,t,i){return m.set(e,{selection:t,forceSelection:i,nativelyRenderedContent:null,inlineStyleOverride:null})}function C(e,t){return e.getBlockMap().map(function(i){return s.generate(e,i,t)}).toOrderedMap()}function y(e,t){var i=e.getBlockMap().reverse().skipUntil(function(e,i){return i===t}).skip(1).skipUntil(function(e,t){return e.getLength()}).first();return i?i.getInlineStyleAt(i.getLength()-1):u()}e.exports=m},8117(e,t,i){"use strict";var r=i(63390),n=i(97253),s=r.isPlatform("Mac OS X"),o={isCtrlKeyCommand:function(e){return!!e.ctrlKey&&!e.altKey},isOptionKeyCommand:function(e){return s&&e.altKey},usesMacOSHeuristics:function(){return s},hasCommandModifier:function(e){return s?!!e.metaKey&&!e.altKey:o.isCtrlKeyCommand(e)},isSoftNewlineEvent:n};e.exports=o},79198(){},75969(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(10563),o=i(25813),a={currentBlockContainsLink:function(e){var t=e.getSelection(),i=e.getCurrentContent(),r=i.getEntityMap();return i.getBlockForKey(t.getAnchorKey()).getCharacterList().slice(t.getStartOffset(),t.getEndOffset()).some(function(e){var t=e.getEntity();return!!t&&"LINK"===r.__get(t).getType()})},getCurrentBlockType:function(e){var t=e.getSelection();return e.getCurrentContent().getBlockForKey(t.getStartKey()).getType()},getDataObjectForLinkURL:function(e){return{url:e.toString()}},handleKeyCommand:function(e,t,i){switch(t){case"bold":return a.toggleInlineStyle(e,"BOLD");case"italic":return a.toggleInlineStyle(e,"ITALIC");case"underline":return a.toggleInlineStyle(e,"UNDERLINE");case"code":return a.toggleCode(e);case"backspace":case"backspace-word":case"backspace-to-start-of-line":return a.onBackspace(e);case"delete":case"delete-word":case"delete-to-end-of-block":return a.onDelete(e);default:return null}},insertSoftNewline:function(e){var t=r.insertText(e.getCurrentContent(),e.getSelection(),"\n",e.getCurrentInlineStyle(),null),i=n.push(e,t,"insert-characters");return n.forceSelection(i,t.getSelectionAfter())},onBackspace:function(e){var t=e.getSelection();if(!t.isCollapsed()||t.getAnchorOffset()||t.getFocusOffset())return null;var i=e.getCurrentContent(),r=t.getStartKey(),s=i.getBlockBefore(r);if(s&&"atomic"===s.getType()){var o=i.getBlockMap().delete(s.getKey()),l=i.merge({blockMap:o,selectionAfter:t});if(l!==i)return n.push(e,l,"remove-range")}var c=a.tryToRemoveBlockStyle(e);return c?n.push(e,c,"change-block-type"):null},onDelete:function(e){var t=e.getSelection();if(!t.isCollapsed())return null;var i=e.getCurrentContent(),s=t.getStartKey(),o=i.getBlockForKey(s).getLength();if(t.getStartOffset()<o)return null;var a=i.getBlockAfter(s);if(!a||"atomic"!==a.getType())return null;var l=t.merge({focusKey:a.getKey(),focusOffset:a.getLength()}),c=r.removeRange(i,l,"forward");return c!==i?n.push(e,c,"remove-range"):null},onTab:function(e,t,i){var r=t.getSelection(),o=r.getAnchorKey();if(o!==r.getFocusKey())return t;var a=t.getCurrentContent(),l=a.getBlockForKey(o),c=l.getType();if("unordered-list-item"!==c&&"ordered-list-item"!==c)return t;e.preventDefault();var u=l.getDepth();if(!e.shiftKey&&u===i)return t;var h=s(a,r,e.shiftKey?-1:1,i);return n.push(t,h,"adjust-depth")},toggleBlockType:function(e,t){var i=e.getSelection(),s=i.getStartKey(),a=i.getEndKey(),l=e.getCurrentContent(),c=i;if(s!==a&&0===i.getEndOffset()){var u=o(l.getBlockBefore(a));a=u.getKey(),c=c.merge({anchorKey:s,anchorOffset:i.getStartOffset(),focusKey:a,focusOffset:u.getLength(),isBackward:!1})}if(l.getBlockMap().skipWhile(function(e,t){return t!==s}).reverse().skipWhile(function(e,t){return t!==a}).some(function(e){return"atomic"===e.getType()}))return e;var h=l.getBlockForKey(s).getType()===t?"unstyled":t;return n.push(e,r.setBlockType(l,c,h),"change-block-type")},toggleCode:function(e){var t=e.getSelection(),i=t.getAnchorKey(),r=t.getFocusKey();return t.isCollapsed()||i!==r?a.toggleBlockType(e,"code-block"):a.toggleInlineStyle(e,"CODE")},toggleInlineStyle:function(e,t){var i=e.getSelection(),s=e.getCurrentInlineStyle();if(i.isCollapsed())return n.setInlineStyleOverride(e,s.has(t)?s.remove(t):s.add(t));var o,a=e.getCurrentContent();return o=s.has(t)?r.removeInlineStyle(a,i,t):r.applyInlineStyle(a,i,t),n.push(e,o,"change-inline-style")},toggleLink:function(e,t,i){var s=r.applyEntity(e.getCurrentContent(),t,i);return n.push(e,s,"apply-entity")},tryToRemoveBlockStyle:function(e){var t=e.getSelection(),i=t.getAnchorOffset();if(t.isCollapsed()&&0===i){var n=t.getAnchorKey(),s=e.getCurrentContent(),o=s.getBlockForKey(n).getType(),a=s.getBlockBefore(n);if("code-block"===o&&a&&"code-block"===a.getType()&&0!==a.getLength())return null;if("unstyled"!==o)return r.setBlockType(s,t,"unstyled")}return null}};e.exports=a},56109(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(54095),o=i(25813),a=null,l={cut:function(e){var t=e.getCurrentContent(),i=e.getSelection(),l=null;if(i.isCollapsed()){var c=i.getAnchorKey(),u=t.getBlockForKey(c).getLength();if(u===i.getAnchorOffset()){var h=t.getKeyAfter(c);if(null==h)return e;l=i.set("focusKey",h).set("focusOffset",0)}else l=i.set("focusOffset",u)}else l=i;l=o(l),a=s(t,l);var d=r.removeRange(t,l,"forward");return d===t?e:n.push(e,d,"remove-range")},paste:function(e){if(!a)return e;var t=r.replaceWithFragment(e.getCurrentContent(),e.getSelection(),a);return n.push(e,t,"insert-fragment")}};e.exports=l},27442(e,t,i){"use strict";var r=function(e){var t,i;function r(){return e.apply(this,arguments)||this}i=e,(t=r).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var n=r.prototype;return n.serialize=function(){return"Anchor: "+this.getAnchorKey()+":"+this.getAnchorOffset()+", Focus: "+this.getFocusKey()+":"+this.getFocusOffset()+", Is Backward: "+String(this.getIsBackward())+", Has Focus: "+String(this.getHasFocus())},n.getAnchorKey=function(){return this.get("anchorKey")},n.getAnchorOffset=function(){return this.get("anchorOffset")},n.getFocusKey=function(){return this.get("focusKey")},n.getFocusOffset=function(){return this.get("focusOffset")},n.getIsBackward=function(){return this.get("isBackward")},n.getHasFocus=function(){return this.get("hasFocus")},n.hasEdgeWithin=function(e,t,i){var r=this.getAnchorKey(),n=this.getFocusKey();if(r===n&&r===e){var s=this.getStartOffset(),o=this.getEndOffset();return t<=s&&s<=i||t<=o&&o<=i}if(e!==r&&e!==n)return!1;var a=e===r?this.getAnchorOffset():this.getFocusOffset();return t<=a&&i>=a},n.isCollapsed=function(){return this.getAnchorKey()===this.getFocusKey()&&this.getAnchorOffset()===this.getFocusOffset()},n.getStartKey=function(){return this.getIsBackward()?this.getFocusKey():this.getAnchorKey()},n.getStartOffset=function(){return this.getIsBackward()?this.getFocusOffset():this.getAnchorOffset()},n.getEndKey=function(){return this.getIsBackward()?this.getAnchorKey():this.getFocusKey()},n.getEndOffset=function(){return this.getIsBackward()?this.getAnchorOffset():this.getFocusOffset()},r.createEmpty=function(e){return new r({anchorKey:e,anchorOffset:0,focusKey:e,focusOffset:0,isBackward:!1,hasFocus:!1})},r}((0,i(99251).Record)({anchorKey:"",anchorOffset:0,focusKey:"",focusOffset:0,isBackward:!1,hasFocus:!1}));e.exports=r},10563(e){"use strict";e.exports=function(e,t,i,r){var n=t.getStartKey(),s=t.getEndKey(),o=e.getBlockMap(),a=o.toSeq().skipUntil(function(e,t){return t===n}).takeUntil(function(e,t){return t===s}).concat([[s,o.get(s)]]).map(function(e){var t=e.getDepth()+i;return t=Math.max(0,Math.min(t,r)),e.set("depth",t)});return o=o.merge(a),e.merge({blockMap:o,selectionBefore:t,selectionAfter:t})}},43253(e,t,i){"use strict";var r=i(41671);e.exports=function(e,t,i,n){for(var s=t,o=e.getCharacterList();s<i;)o=o.set(s,r.applyEntity(o.get(s),n)),s++;return e.set("characterList",o)}},40377(e,t,i){"use strict";var r=i(43253),n=i(99251);e.exports=function(e,t,i){var s=e.getBlockMap(),o=t.getStartKey(),a=t.getStartOffset(),l=t.getEndKey(),c=t.getEndOffset(),u=s.skipUntil(function(e,t){return t===o}).takeUntil(function(e,t){return t===l}).toOrderedMap().merge(n.OrderedMap([[l,s.get(l)]])).map(function(e,t){var n=t===o?a:0,s=t===l?c:e.getLength();return r(e,n,s,i)});return e.merge({blockMap:s.merge(u),selectionBefore:t,selectionAfter:t})}},93613(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(40643),s=i(31527),o=i(93184),a=i(30370),l=i(3399),c=i(40041),u=function(e,t){return{key:e.getKey(),text:e.getText(),type:e.getType(),depth:e.getDepth(),inlineStyleRanges:l(e),entityRanges:a(e,t),data:e.getData().toObject()}};e.exports=function(e){var t={entityMap:{},blocks:[]};return t=function(e,t){var i=t.entityMap,a=[],l={},h={},d=0;return e.getBlockMap().forEach(function(e){e.findEntityRanges(function(e){return null!==e.getEntity()},function(t){var r=e.getEntityAt(t),n=o.stringify(r);h[n]||(h[n]=r,i[n]="".concat(d),d++)}),function(e,t,i,o){if(e instanceof n)i.push(u(e,t));else{e instanceof s||c(!1);var a=e.getParentKey(),l=o[e.getKey()]=function(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},n=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),n.forEach(function(t){r(e,t,i[t])})}return e}({},u(e,t),{children:[]});a?o[a].children.push(l):i.push(l)}}(e,i,a,l)}),{blocks:a,entityMap:i}}(e,t),t=function(e,t){var i=t.blocks,r=t.entityMap,n={};return Object.keys(r).forEach(function(t,i){var r=e.getEntity(o.unstringify(t));n[i]={type:r.getType(),mutability:r.getMutability(),data:r.getData()}}),{blocks:i,entityMap:n}}(e,t),t}},86739(e,t,i){"use strict";var r;function n(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){s(e,t,i[t])})}return e}function s(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var o=i(41671),a=i(40643),l=i(31527),c=i(47904),u=i(70873),h=i(10499),d=i(22978),p=i(12634),g=i(38413),f=i(17595),m=i(99251),v=m.List,C=m.Map,y=m.OrderedSet,w=i(34189),S=i(4734),b=i(44110),E=i(80119),A=f("draft_tree_data_support"),T=new RegExp("\r","g"),M=new RegExp("\n","g"),R=new RegExp("^\n","g"),_=new RegExp("&nbsp;","g"),P=new RegExp("&#13;?","g"),x=new RegExp("&#8203;?","g"),D=["bold","bolder","500","600","700","800","900"],I=["light","lighter","normal","100","200","300","400"],L=["className","href","rel","target","title"],N=["alt","className","height","src","width"],O=(s(r={},d("public/DraftStyleDefault/depth0"),0),s(r,d("public/DraftStyleDefault/depth1"),1),s(r,d("public/DraftStyleDefault/depth2"),2),s(r,d("public/DraftStyleDefault/depth3"),3),s(r,d("public/DraftStyleDefault/depth4"),4),r),F=C({b:"BOLD",code:"CODE",del:"STRIKETHROUGH",em:"ITALIC",i:"ITALIC",s:"STRIKETHROUGH",strike:"STRIKETHROUGH",strong:"BOLD",u:"UNDERLINE",mark:"HIGHLIGHT"}),k=function(e){return b(e)&&e.style.fontFamily.includes("monospace")?"CODE":null},G=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return Object.keys(O).some(function(i){e.classList.contains(i)&&(t=O[i])}),t},V=function(e){if(!w(e))return!1;var t=e;if(!t.href||"http:"!==t.protocol&&"https:"!==t.protocol&&"mailto:"!==t.protocol&&"tel:"!==t.protocol)return!1;try{return new h(t.href),!0}catch(e){return!1}},H=function(e){if(!E(e))return!1;var t=e;return!(!t.attributes.getNamedItem("src")||!t.attributes.getNamedItem("src").value)},B=function(e,t){if(!b(e))return t;var i=e,r=i.style.fontWeight,n=i.style.fontStyle,s=i.style.textDecoration;return t.withMutations(function(e){D.indexOf(r)>=0?e.add("BOLD"):I.indexOf(r)>=0&&e.remove("BOLD"),"italic"===n?e.add("ITALIC"):"normal"===n&&e.remove("ITALIC"),"underline"===s&&e.add("UNDERLINE"),"line-through"===s&&e.add("STRIKETHROUGH"),"none"===s&&(e.remove("UNDERLINE"),e.remove("STRIKETHROUGH"))})},z=function(e){return"ul"===e||"ol"===e},U=function(){function e(e,t){s(this,"characterList",v()),s(this,"currentBlockType","unstyled"),s(this,"currentDepth",0),s(this,"currentEntity",null),s(this,"currentText",""),s(this,"wrapper",null),s(this,"blockConfigs",[]),s(this,"contentBlocks",[]),s(this,"entityMap",u),s(this,"blockTypeMap",void 0),s(this,"disambiguate",void 0),this.clear(),this.blockTypeMap=e,this.disambiguate=t}var t=e.prototype;return t.clear=function(){this.characterList=v(),this.blockConfigs=[],this.currentBlockType="unstyled",this.currentDepth=0,this.currentEntity=null,this.currentText="",this.entityMap=u,this.wrapper=null,this.contentBlocks=[]},t.addDOMNode=function(e){var t;return this.contentBlocks=[],this.currentDepth=0,(t=this.blockConfigs).push.apply(t,this._toBlockConfigs([e],y())),this._trimCurrentText(),""!==this.currentText&&this.blockConfigs.push(this._makeBlockConfig()),this},t.getContentBlocks=function(){return 0===this.contentBlocks.length&&(A?this._toContentBlocks(this.blockConfigs):this._toFlatContentBlocks(this.blockConfigs)),{contentBlocks:this.contentBlocks,entityMap:this.entityMap}},t._makeBlockConfig=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=n({key:e.key||p(),type:this.currentBlockType,text:this.currentText,characterList:this.characterList,depth:this.currentDepth,parent:null,children:v(),prevSibling:null,nextSibling:null,childConfigs:[]},e);return this.characterList=v(),this.currentBlockType="unstyled",this.currentText="",t},t._toBlockConfigs=function(e,t){for(var i=[],r=0;r<e.length;r++){var n=e[r],s=n.nodeName.toLowerCase();if("body"===s||z(s)){this._trimCurrentText(),""!==this.currentText&&i.push(this._makeBlockConfig());var o=this.currentDepth,a=this.wrapper;z(s)&&(this.wrapper=s,z(a)&&this.currentDepth++),i.push.apply(i,this._toBlockConfigs(Array.from(n.childNodes),t)),this.currentDepth=o,this.wrapper=a}else{var l=this.blockTypeMap.get(s);if(void 0===l)if("#text"!==s)if("br"!==s)if(H(n))this._addImgNode(n,t);else if(V(n))this._addAnchorNode(n,i,t);else{var c=t;F.has(s)&&(c=c.add(F.get(s))),c=B(n,c);var u=k(n);null!=u&&(c=c.add(u)),i.push.apply(i,this._toBlockConfigs(Array.from(n.childNodes),c))}else this._addBreakNode(n,t);else this._addTextNode(n,t);else{this._trimCurrentText(),""!==this.currentText&&i.push(this._makeBlockConfig());var h=this.currentDepth,d=this.wrapper;if(this.wrapper="pre"===s?"pre":this.wrapper,"string"!=typeof l&&(l=this.disambiguate(s,this.wrapper)||l[0]||"unstyled"),!A&&b(n)&&("unordered-list-item"===l||"ordered-list-item"===l)){var g=n;this.currentDepth=G(g,this.currentDepth)}var f=p(),m=this._toBlockConfigs(Array.from(n.childNodes),t);this._trimCurrentText(),i.push(this._makeBlockConfig({key:f,childConfigs:m,type:l})),this.currentDepth=h,this.wrapper=d}}}return i},t._appendText=function(e,t){var i;this.currentText+=e;var r=o.create({style:t,entity:this.currentEntity});this.characterList=(i=this.characterList).push.apply(i,Array(e.length).fill(r))},t._trimCurrentText=function(){var e=this.currentText.length,t=e-this.currentText.trimLeft().length,i=this.currentText.trimRight().length,r=this.characterList.findEntry(function(e){return null!==e.getEntity()});(t=void 0!==r?Math.min(t,r[0]):t)>(i=void 0!==(r=this.characterList.reverse().findEntry(function(e){return null!==e.getEntity()}))?Math.max(i,e-r[0]):i)?(this.currentText="",this.characterList=v()):(this.currentText=this.currentText.slice(t,i),this.characterList=this.characterList.slice(t,i))},t._addTextNode=function(e,t){var i=e.textContent;""===i.trim()&&"pre"!==this.wrapper&&(i=" "),"pre"!==this.wrapper&&(i=(i=i.replace(R,"")).replace(M," ")),this._appendText(i,t)},t._addBreakNode=function(e,t){S(e)&&this._appendText("\n",t)},t._addImgNode=function(e,t){if(E(e)){var i=e,r={};N.forEach(function(e){var t=i.getAttribute(e);t&&(r[e]=t)}),this.currentEntity=this.entityMap.__create("IMAGE","IMMUTABLE",r),f("draftjs_fix_paste_for_img")?"presentation"!==i.getAttribute("role")&&this._appendText("📷",t):this._appendText("📷",t),this.currentEntity=null}},t._addAnchorNode=function(e,t,i){if(w(e)){var r=e,n={};L.forEach(function(e){var t=r.getAttribute(e);t&&(n[e]=t)}),n.url=new h(r.href).toString(),this.currentEntity=this.entityMap.__create("LINK","MUTABLE",n||{}),t.push.apply(t,this._toBlockConfigs(Array.from(e.childNodes),i)),this.currentEntity=null}},t._toContentBlocks=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,i=e.length-1,r=0;r<=i;r++){var s=e[r];s.parent=t,s.prevSibling=r>0?e[r-1].key:null,s.nextSibling=r<i?e[r+1].key:null,s.children=v(s.childConfigs.map(function(e){return e.key})),this.contentBlocks.push(new l(n({},s))),this._toContentBlocks(s.childConfigs,s.key)}},t._hoistContainersInBlockConfigs=function(e){var t=this;return v(e).flatMap(function(e){return"unstyled"!==e.type||""!==e.text?[e]:t._hoistContainersInBlockConfigs(e.childConfigs)})},t._toFlatContentBlocks=function(e){var t=this;this._hoistContainersInBlockConfigs(e).forEach(function(e){var i=t._extractTextFromBlockConfigs(e.childConfigs),r=i.text,s=i.characterList;t.contentBlocks.push(new a(n({},e,{text:e.text+r,characterList:e.characterList.concat(s)})))})},t._extractTextFromBlockConfigs=function(e){for(var t=e.length-1,i="",r=v(),n=0;n<=t;n++){var s=e[n];i+=s.text,r=r.concat(s.characterList),""!==i&&"unstyled"!==s.type&&(i+="\n",r=r.push(r.last()));var o=this._extractTextFromBlockConfigs(s.childConfigs);i+=o.text,r=r.concat(o.characterList)}return{text:i,characterList:r}},e}();e.exports=function(e){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:c,i=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:g)(e=e.trim().replace(T,"").replace(_," ").replace(P,"").replace(x,""));if(!i)return null;var r=function(e){var t={};return e.mapKeys(function(e,i){var r=[i.element];void 0!==i.aliasedElements&&r.push.apply(r,i.aliasedElements),r.forEach(function(i){void 0===t[i]?t[i]=e:"string"==typeof t[i]?t[i]=[t[i],e]:t[i].push(e)})}),C(t)}(t);return new U(r,function(e,t){return"li"===e?"ol"===t?"ordered-list-item":"unordered-list-item":null}).addDOMNode(i).getContentBlocks()}},12503(e,t,i){"use strict";function r(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{},r=Object.keys(i);"function"==typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(i).filter(function(e){return Object.getOwnPropertyDescriptor(i,e).enumerable}))),r.forEach(function(t){n(e,t,i[t])})}return e}function n(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var s=i(40643),o=i(31527),a=i(23315),l=i(70873),c=i(85063),u=(i(59415),i(27442)),h=i(59974),d=i(87838),p=i(55107),g=i(12634),f=i(17595),m=i(99251),v=i(40041),C=f("draft_tree_data_support"),y=m.List,w=m.Map,S=m.OrderedMap,b=function(e,t){var i=e.key,r=e.type,n=e.data;return{text:e.text,depth:e.depth||0,type:r||"unstyled",key:i||g(),data:w(n),characterList:E(e,t)}},E=function(e,t){var i=e.text,n=e.entityRanges,s=e.inlineStyleRanges,o=n||[];return h(p(i,s||[]),d(i,o.filter(function(e){return t.hasOwnProperty(e.key)}).map(function(e){return r({},e,{key:t[e.key]})})))},A=function(e){return r({},e,{key:e.key||g()})},T=function(e,t,i){var n=t.map(function(e){return r({},e,{parentRef:i})});return e.concat(n.reverse())};e.exports=function(e){Array.isArray(e.blocks)||v(!1);var t=function(e){var t=e.entityMap,i={};return Object.keys(t).forEach(function(e){var r=t[e],n=r.type,s=r.mutability,o=r.data;i[e]=l.__create(n,s,o||{})}),i}(e),i=function(e,t){var i=e.blocks.find(function(e){return Array.isArray(e.children)&&e.children.length>0}),n=C&&!i?c.fromRawStateToRawTreeState(e).blocks:e.blocks;if(!C)return function(e,t){return S(e.map(function(e){var i=new s(b(e,t));return[i.getKey(),i]}))}(i?c.fromRawTreeStateToRawState(e).blocks:n,t);var a=function(e,t){return e.map(A).reduce(function(i,n,s){Array.isArray(n.children)||v(!1);var a=n.children.map(A),l=new o(r({},b(n,t),{prevSibling:0===s?null:e[s-1].key,nextSibling:s===e.length-1?null:e[s+1].key,children:y(a.map(function(e){return e.key}))}));i=i.set(l.getKey(),l);for(var c=T([],a,l);c.length>0;){var u=c.pop(),h=u.parentRef,d=h.getChildKeys(),p=d.indexOf(u.key),g=Array.isArray(u.children);if(!g){g||v(!1);break}var f=u.children.map(A),m=new o(r({},b(u,t),{parent:h.getKey(),children:y(f.map(function(e){return e.key})),prevSibling:0===p?null:d.get(p-1),nextSibling:p===d.size-1?null:d.get(p+1)}));i=i.set(m.getKey(),m),c=T(c,f,m)}return i},S())}(n,t);return a}(e,t),n=i.isEmpty()?new u:u.createEmpty(i.first().getKey());return new a({blockMap:i,entityMap:t,selectionBefore:n,selectionAfter:n})}},59974(e,t,i){"use strict";var r=i(41671),n=i(99251).List;e.exports=function(e,t){var i=e.map(function(e,i){var n=t[i];return r.create({style:e,entity:n})});return n(i)}},87838(e,t,i){"use strict";var r=i(13145).substr;e.exports=function(e,t){var i=Array(e.length).fill(null);return t&&t.forEach(function(t){for(var n=r(e,0,t.offset).length,s=n+r(e,t.offset,t.length).length,o=n;o<s;o++)i[o]=t.key}),i}},55107(e,t,i){"use strict";var r=i(13145),n=i(99251).OrderedSet,s=r.substr,o=n();e.exports=function(e,t){var i=Array(e.length).fill(o);return t&&t.forEach(function(t){for(var r=s(e,0,t.offset).length,n=r+s(e,t.offset,t.length).length;r<n;)i[r]=i[r].add(t.style),r++}),i}},25070(e){"use strict";e.exports={notEmptyKey:function(e){return null!=e&&""!=e}}},45995(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(63390),o=i(60836),a=i(46415),l=i(65044),c=i(25813),u=i(95136),h=s.isBrowser("Firefox");function d(e,t,i,s,o){var a=r.replaceText(e.getCurrentContent(),e.getSelection(),t,i,s);return n.push(e,a,"insert-characters",o)}e.exports=function(e,t){void 0!==e._pendingStateFromBeforeInput&&(e.update(e._pendingStateFromBeforeInput),e._pendingStateFromBeforeInput=void 0);var i=e._latestEditorState,r=t.data;if(r)if(e.props.handleBeforeInput&&a(e.props.handleBeforeInput(r,i,t.timeStamp)))t.preventDefault();else{var s=i.getSelection(),p=s.getStartOffset(),g=s.getAnchorKey();if(!s.isCollapsed())return t.preventDefault(),void e.update(d(i,r,i.getCurrentInlineStyle(),o(i.getCurrentContent(),i.getSelection()),!0));var f,m=d(i,r,i.getCurrentInlineStyle(),o(i.getCurrentContent(),i.getSelection()),!1),v=!1;if(v||(v=l(e._latestCommittedEditorState)),!v){var C=i.getBlockTree(g),y=m.getBlockTree(g);v=C.size!==y.size||C.zip(y).some(function(e){var t=e[0],i=e[1],n=t.get("start"),s=n+(n>=p?r.length:0),o=t.get("end"),a=o+(o>=p?r.length:0),l=i.get("start"),c=i.get("end"),u=i.get("decoratorKey");return t.get("decoratorKey")!==u||t.get("leaves").size!==i.get("leaves").size||s!==l||a!==c||null!=u&&c-l!==o-n})}if(v||(f=r,v=h&&("'"==f||"/"==f)),v||(v=c(m.getDirectionMap()).get(g)!==c(i.getDirectionMap()).get(g)),v)return t.preventDefault(),m=n.set(m,{forceSelection:!0}),void e.update(m);m=n.set(m,{nativelyRenderedContent:m.getCurrentContent()}),e._pendingStateFromBeforeInput=m,u(function(){void 0!==e._pendingStateFromBeforeInput&&(e.update(e._pendingStateFromBeforeInput),e._pendingStateFromBeforeInput=void 0)})}}},23717(e,t,i){"use strict";var r=i(59539),n=i(68820),s=i(53967);e.exports=function(e,t){var i=t.currentTarget.ownerDocument;if(!Boolean(e.props.preserveSelectionOnBlur)&&s(i)===i.body){var o=i.defaultView.getSelection(),a=e.editor;1===o.rangeCount&&n(a,o.anchorNode)&&n(a,o.focusNode)&&o.removeAllRanges()}var l=e._latestEditorState,c=l.getSelection();if(c.getHasFocus()){var u=c.set("hasFocus",!1);e.props.onBlur&&e.props.onBlur(t),e.update(r.acceptSelection(l,u))}}},46438(e,t,i){"use strict";var r=i(59539);e.exports=function(e,t){e.setMode("composite"),e.update(r.set(e._latestEditorState,{inCompositionMode:!0})),e._onCompositionStart(t)}},78073(e,t,i){"use strict";var r=i(13355);e.exports=function(e,t){e._latestEditorState.getSelection().isCollapsed()?t.preventDefault():e.setClipboard(r(e._latestEditorState))}},43046(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(98556),o=i(13355),a=i(93987),l=i(76871);e.exports=function(e,t){var i,c=e._latestEditorState,u=c.getSelection(),h=t.target;if(u.isCollapsed())t.preventDefault();else{if(l(h)){var d=h;i=a(s.getScrollParent(d))}var p=o(c);e.setClipboard(p),e.setMode("cut"),setTimeout(function(){e.restoreEditorDOM(i),e.exitCurrentMode(),e.update(function(e){var t=r.removeRange(e.getCurrentContent(),e.getSelection(),"forward");return n.push(e,t,"remove-range")}(c))},0)}}},76100(e){"use strict";e.exports=function(e,t){e.setMode("drag"),t.preventDefault()}},92244(e){"use strict";e.exports=function(e){e._internalDrag=!0,e.setMode("drag")}},38514(e,t,i){"use strict";var r=i(59539),n=i(63390);e.exports=function(e,t){var i=e._latestEditorState,s=i.getSelection();if(!s.getHasFocus()){var o=s.set("hasFocus",!0);e.props.onFocus&&e.props.onFocus(t),n.isBrowser("Chrome < 60.0.3081.0")?e.update(r.forceSelection(i,o)):e.update(r.acceptSelection(i,o))}}},29830(e,t,i){"use strict";var r=i(58267),n=i(13878),s=i(59539),o=i(63390),a=i(25070).notEmptyKey,l=i(65461),c=i(97402),u=i(25813),h=o.isEngine("Gecko");e.exports=function(e,t){void 0!==e._pendingStateFromBeforeInput&&(e.update(e._pendingStateFromBeforeInput),e._pendingStateFromBeforeInput=void 0);var i=e.editor.ownerDocument.defaultView.getSelection(),o=i.anchorNode,d=i.isCollapsed,p=(null==o?void 0:o.nodeType)!==Node.TEXT_NODE&&(null==o?void 0:o.nodeType)!==Node.ELEMENT_NODE;if(null!=o&&!p){if(o.nodeType===Node.TEXT_NODE&&(null!==o.previousSibling||null!==o.nextSibling)){var g=o.parentNode;if(null==g)return;o.nodeValue=g.textContent;for(var f=g.firstChild;null!=f;f=f.nextSibling)f!==o&&g.removeChild(f)}var m=o.textContent,v=e._latestEditorState,C=u(l(o)),y=n.decode(C),w=y.blockKey,S=y.decoratorKey,b=y.leafKey,E=v.getBlockTree(w).getIn([S,"leaves",b]),A=E.start,T=E.end,M=v.getCurrentContent(),R=M.getBlockForKey(w),_=R.getText().slice(A,T);if(m.endsWith("\n\n")&&(m=m.slice(0,-1)),m!==_){var P,x,D,I,L=v.getSelection(),N=L.merge({anchorOffset:A,focusOffset:T,isBackward:!1}),O=R.getEntityAt(A),F=a(O)?M.getEntity(O):null,k="MUTABLE"===(null!=F?F.getMutability():null),G=k?"spellcheck-change":"apply-entity",V=r.replaceText(M,N,m,R.getInlineStyleAt(A),k?R.getEntityAt(A):null);if(h)P=i.anchorOffset,x=i.focusOffset,I=(D=A+Math.min(P,x))+Math.abs(P-x),P=D,x=I;else{var H=m.length-_.length;D=L.getStartOffset(),I=L.getEndOffset(),P=d?I+H:D,x=I+H}var B=V.merge({selectionBefore:M.getSelectionAfter(),selectionAfter:L.merge({anchorOffset:P,focusOffset:x})});e.update(s.push(v,B,G))}else{var z=t.nativeEvent.inputType;if(z){var U=function(e,t){return"deleteContentBackward"===e?c(t):t}(z,v);if(U!==v)return e.restoreEditorDOM(),void e.update(U)}}}}},41345(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(8117),o=i(4617),a=i(56109),l=i(63390),c=i(46415),u=i(50976),h=i(44126),d=i(27130),p=i(79774),g=i(11644),f=i(63467),m=i(97402),v=i(12750),C=i(2194),y=i(38707),w=s.isOptionKeyCommand,S=l.isBrowser("Chrome");e.exports=function(e,t){var i=t.which,s=e._latestEditorState;function l(i){var r=e.props[i];return!!r&&(r(t),!0)}switch(i){case o.RETURN:if(t.preventDefault(),e.props.handleReturn&&c(e.props.handleReturn(t,s)))return;break;case o.ESC:if(t.preventDefault(),l("onEscape"))return;break;case o.TAB:if(l("onTab"))return;break;case o.UP:if(l("onUpArrow"))return;break;case o.RIGHT:if(l("onRightArrow"))return;break;case o.DOWN:if(l("onDownArrow"))return;break;case o.LEFT:if(l("onLeftArrow"))return;break;case o.SPACE:S&&w(t)&&t.preventDefault()}var b=e.props.keyBindingFn(t);if(null!=b&&""!==b)if("undo"!==b){if(t.preventDefault(),!e.props.handleKeyCommand||!c(e.props.handleKeyCommand(b,s,t.timeStamp))){var E=function(e,t,i){switch(e){case"redo":return n.redo(t);case"delete":return v(t);case"delete-word":return d(t);case"backspace":return m(t);case"backspace-word":return h(t);case"backspace-to-start-of-line":return u(t,i);case"split-block":return p(t);case"transpose-characters":return C(t);case"move-selection-to-start-of-block":return f(t);case"move-selection-to-end-of-block":return g(t);case"secondary-cut":return a.cut(t);case"secondary-paste":return a.paste(t);default:return t}}(b,s,t);E!==s&&e.update(E)}}else y(t,s,e.update);else if(i===o.SPACE&&S&&w(t)){var A=r.replaceText(s.getCurrentContent(),s.getSelection()," ");e.update(n.push(s,A,"insert-characters"))}}},35346(e,t,i){"use strict";var r=i(84433),n=i(41671),s=i(81354),o=i(58267),a=i(42471),l=i(59539),c=i(75969),u=i(60836),h=i(27786),d=i(46415),p=i(55585);function g(e,t,i){var r=o.replaceWithFragment(e.getCurrentContent(),e.getSelection(),t);return l.push(e,r.set("entityMap",i),"insert-fragment")}e.exports=function(e,t){t.preventDefault();var i=new s(t.clipboardData);if(!i.isRichText()){var f=i.getFiles(),m=i.getText();if(f.length>0){if(e.props.handlePastedFiles&&d(e.props.handlePastedFiles(f)))return;return void h(f,function(t){if(t=t||m){var i=e._latestEditorState,s=p(t),h=n.create({style:i.getCurrentInlineStyle(),entity:u(i.getCurrentContent(),i.getSelection())}),d=c.getCurrentBlockType(i),g=a.processText(s,h,d),f=r.createFromArray(g),v=o.replaceWithFragment(i.getCurrentContent(),i.getSelection(),f);e.update(l.push(i,v,"insert-fragment"))}})}}var v=[],C=i.getText(),y=i.getHTML(),w=e._latestEditorState;if(e.props.formatPastedText){var S=e.props.formatPastedText(C,y);C=S.text,y=S.html}if(!e.props.handlePastedText||!d(e.props.handlePastedText(C,y,w))){if(C&&(v=p(C)),!e.props.stripPastedStyles){var b,E=e.getClipboard();if(!e.props.formatPastedText&&i.isRichText()&&E){if(-1!==(null===(b=y)||void 0===b?void 0:b.indexOf(e.getEditorKey()))||1===v.length&&1===E.size&&E.first().getText()===C)return void e.update(g(e._latestEditorState,E))}else if(E&&i.types.includes("com.apple.webarchive")&&!i.types.includes("text/html")&&function(e,t){return e.length===t.size&&t.valueSeq().every(function(t,i){return t.getText()===e[i]})}(v,E))return void e.update(g(e._latestEditorState,E));if(y){var A=a.processHTML(y,e.props.blockRenderMap);if(A){var T=A.contentBlocks,M=A.entityMap;if(T){var R=r.createFromArray(T);return void e.update(g(e._latestEditorState,R,M))}}}e.setClipboard(null)}if(v.length){var _=n.create({style:w.getCurrentInlineStyle(),entity:u(w.getCurrentContent(),w.getSelection())}),P=c.getCurrentBlockType(w),x=a.processText(v,_,P),D=r.createFromArray(x);e.update(g(e._latestEditorState,D))}}}},10292(e,t,i){"use strict";var r=i(35693),n=i(59539),s=i(71093),o=i(15801);e.exports=function(e){if(e._blockSelectEvents||e._latestEditorState!==e.props.editorState){if(e._blockSelectEvents){var t=e.props.editorState.getSelection();r.logBlockedSelectionEvent({anonymizedDom:"N/A",extraParams:JSON.stringify({stacktrace:(new Error).stack}),selectionState:JSON.stringify(t.toJS())})}}else{var i=e.props.editorState,a=o(i,s(e)),l=a.selectionState;l!==i.getSelection()&&(i=a.needsRecovery?n.forceSelection(i,l):n.acceptSelection(i,l),e.update(i))}}},30370(e,t,i){"use strict";var r=i(93184),n=i(13145).strlen;e.exports=function(e,t){var i=[];return e.findEntityRanges(function(e){return!!e.getEntity()},function(s,o){var a=e.getText(),l=e.getEntityAt(s);i.push({offset:n(a.slice(0,s)),length:n(a.slice(s,o)),key:Number(t[r.stringify(l)])})}),i}},3399(e,t,i){"use strict";var r=i(13145),n=i(14910),s=function(e,t){return e===t},o=function(e){return!!e},a=[];e.exports=function(e){var t=e.getCharacterList().map(function(e){return e.getStyle()}).toList(),i=t.flatten().toSet().map(function(i){return function(e,t,i){var a=[],l=t.map(function(e){return e.has(i)}).toList();return n(l,s,o,function(t,n){var s=e.getText();a.push({offset:r.strlen(s.slice(0,t)),length:r.strlen(s.slice(t,n)),style:i})}),a}(e,t,i)});return Array.prototype.concat.apply(a,i.toJS())}},31950(e,t,i){"use strict";var r=i(13145),n=i(82097),s=i(45072),o=i(40041);function a(e,t){for(var i=1/0,r=1/0,n=-1/0,s=-1/0,o=0;o<e.length;o++){var a=e[o];0!==a.width&&1!==a.width&&(i=Math.min(i,a.top),r=Math.min(r,a.bottom),n=Math.max(n,a.top),s=Math.max(s,a.bottom))}return n<=r&&n-i<t&&s-r<t}function l(e){switch(e.nodeType){case Node.DOCUMENT_TYPE_NODE:return 0;case Node.TEXT_NODE:case Node.PROCESSING_INSTRUCTION_NODE:case Node.COMMENT_NODE:return e.length;default:return e.childNodes.length}}e.exports=function(e){e.collapsed||o(!1);var t=(e=e.cloneRange()).startContainer;1!==t.nodeType&&(t=t.parentNode);var i=function(e){var t=getComputedStyle(e),i=n(e),r=i.createElement("div");r.style.fontFamily=t.fontFamily,r.style.fontSize=t.fontSize,r.style.fontStyle=t.fontStyle,r.style.fontWeight=t.fontWeight,r.style.lineHeight=t.lineHeight,r.style.position="absolute",r.textContent="M";var s=i.body;s||o(!1),s.appendChild(r);var a=r.getBoundingClientRect();return s.removeChild(r),a.height}(t),c=e.endContainer,u=e.endOffset;for(e.setStart(e.startContainer,0);a(s(e),i)&&(c=e.startContainer,u=e.startOffset,c.parentNode||o(!1),e.setStartBefore(c),1!==c.nodeType||"inline"===getComputedStyle(c).display););for(var h=c,d=u-1;;){for(var p=h.nodeValue,g=d;g>=0;g--)if(!(null!=p&&g>0&&r.isSurrogatePair(p,g-1))){if(e.setStart(h,g),!a(s(e),i))break;c=h,u=g}if(-1===g||0===h.childNodes.length)break;d=l(h=h.childNodes[g])}return e.setStart(c,u),e}},65461(e,t,i){"use strict";var r=i(82097),n=i(39762);e.exports=function(e){for(var t=e;t&&t!==r(e).documentElement;){var i=n(t);if(null!=i)return i;t=t.parentNode}return null}},14910(e){"use strict";e.exports=function(e,t,i,r){if(e.size){var n=0;e.reduce(function(e,s,o){return t(e,s)||(i(e)&&r(n,o),n=o),s}),i(e.last())&&r(n,e.count())}}},12634(e){"use strict";var t={},i=Math.pow(2,24);e.exports=function(){for(var e;void 0===e||t.hasOwnProperty(e)||!isNaN(+e);)e=Math.floor(Math.random()*i).toString(32);return t[e]=!0,e}},64047(e,t,i){"use strict";var r=i(451),n=i(23474),s=i(40041);function o(e,t,i,o,a,l,c){var u=i.getStartOffset(),h=i.getEndOffset(),d=e.__get(a).getMutability(),p=c?u:h;if("MUTABLE"===d)return i;var g=n(t,a).filter(function(e){return p<=e.end&&p>=e.start});1!=g.length&&s(!1);var f=g[0];if("IMMUTABLE"===d)return i.merge({anchorOffset:f.start,focusOffset:f.end,isBackward:!1});l||(c?h=f.end:u=f.start);var m=r.getRemovalRange(u,h,t.getText().slice(f.start,f.end),f.start,o);return i.merge({anchorOffset:m.start,focusOffset:m.end,isBackward:!1})}e.exports=function(e,t,i,r,n){var s=r.getStartOffset(),a=r.getEndOffset(),l=t.getEntityAt(s),c=i.getEntityAt(a-1);if(!l&&!c)return r;var u=r;if(l&&l===c)u=o(e,t,u,n,l,!0,!0);else if(l&&c){var h=o(e,t,u,n,l,!1,!0),d=o(e,i,u,n,c,!1,!1);u=u.merge({anchorOffset:h.getAnchorOffset(),focusOffset:d.getFocusOffset(),isBackward:!1})}else if(l){var p=o(e,t,u,n,l,!1,!0);u=u.merge({anchorOffset:p.getStartOffset(),isBackward:!1})}else if(c){var g=o(e,i,u,n,c,!1,!1);u=u.merge({focusOffset:g.getEndOffset(),isBackward:!1})}return u}},71093(e,t,i){"use strict";var r=i(40041),n=i(44110);e.exports=function(e){var t=e.editorContainer;return t||r(!1),n(t.firstChild)||r(!1),t.firstChild}},54095(e,t,i){"use strict";var r=i(30287),n=i(91825);e.exports=function(e,t){var i=t.getStartKey(),s=t.getStartOffset(),o=t.getEndKey(),a=t.getEndOffset(),l=n(e,t).getBlockMap(),c=l.keySeq(),u=c.indexOf(i),h=c.indexOf(o)+1;return r(l.slice(u,h).map(function(e,t){var r=e.getText(),n=e.getCharacterList();return i===o?e.merge({text:r.slice(s,a),characterList:n.slice(s,a)}):t===i?e.merge({text:r.slice(s),characterList:n.slice(s)}):t===o?e.merge({text:r.slice(0,a),characterList:n.slice(0,a)}):e}))}},82097(e){"use strict";e.exports=function(e){return e&&e.ownerDocument?e.ownerDocument:document}},93564(e,t,i){"use strict";var r=i(8117),n=i(4617),s=i(63390),o=s.isPlatform("Mac OS X"),a=o&&s.isBrowser("Firefox < 29"),l=r.hasCommandModifier,c=r.isCtrlKeyCommand;function u(e){return o&&e.altKey||c(e)}e.exports=function(e){switch(e.keyCode){case 66:return l(e)?"bold":null;case 68:return c(e)?"delete":null;case 72:return c(e)?"backspace":null;case 73:return l(e)?"italic":null;case 74:return l(e)?"code":null;case 75:return o&&c(e)?"secondary-cut":null;case 77:case 79:return c(e)?"split-block":null;case 84:return o&&c(e)?"transpose-characters":null;case 85:return l(e)?"underline":null;case 87:return o&&c(e)?"backspace-word":null;case 89:return c(e)?o?"secondary-paste":"redo":null;case 90:return function(e){return l(e)?e.shiftKey?"redo":"undo":null}(e)||null;case n.RETURN:return"split-block";case n.DELETE:return function(e){return!o&&e.shiftKey?null:u(e)?"delete-word":"delete"}(e);case n.BACKSPACE:return function(e){return l(e)&&o?"backspace-to-start-of-line":u(e)?"backspace-word":"backspace"}(e);case n.LEFT:return a&&l(e)?"move-selection-to-start-of-block":null;case n.RIGHT:return a&&l(e)?"move-selection-to-end-of-block":null;default:return null}}},15801(e,t,i){"use strict";var r=i(89668);e.exports=function(e,t){var i=t.ownerDocument.defaultView.getSelection(),n=i.anchorNode,s=i.anchorOffset,o=i.focusNode,a=i.focusOffset;return 0===i.rangeCount||null==n||null==o?{selectionState:e.getSelection().set("hasFocus",!1),needsRecovery:!1}:r(e,t,n,s,o,a)}},89668(e,t,i){"use strict";var r=i(65461),n=i(39762),s=i(69397),o=i(40041),a=i(66305),l=i(25813);function c(e,t,i){var s=t,c=r(s);if(null!=c||e&&(e===s||e.firstChild===s)||o(!1),e===s&&(s=s.firstChild,a(s)||o(!1),"true"!==s.getAttribute("data-contents")&&o(!1),i>0&&(i=s.childNodes.length)),0===i){var h=null;if(null!=c)h=c;else{var d=function(e){for(;e.firstChild&&(a(e.firstChild)&&"true"===e.firstChild.getAttribute("data-blocks")||n(e.firstChild));)e=e.firstChild;return e}(s);h=l(n(d))}return{key:h,offset:0}}var p=s.childNodes[i-1],g=null,f=null;if(n(p)){var m=function(e){for(;e.lastChild&&(a(e.lastChild)&&"true"===e.lastChild.getAttribute("data-blocks")||n(e.lastChild));)e=e.lastChild;return e}(p);g=l(n(m)),f=u(m)}else g=l(c),f=u(p);return{key:g,offset:f}}function u(e){var t=e.textContent;return"\n"===t?0:t.length}e.exports=function(e,t,i,n,o,a){var u=i.nodeType===Node.TEXT_NODE,h=o.nodeType===Node.TEXT_NODE;if(u&&h)return{selectionState:s(e,l(r(i)),n,l(r(o)),a),needsRecovery:!1};var d=null,p=null,g=!0;return u?(d={key:l(r(i)),offset:n},p=c(t,o,a)):h?(p={key:l(r(o)),offset:a},d=c(t,i,n)):(d=c(t,i,n),p=c(t,o,a),i===o&&n===a&&(g=!!i.firstChild&&"BR"!==i.firstChild.nodeName)),{selectionState:s(e,d.key,d.offset,p.key,p.offset),needsRecovery:g}}},60836(e,t,i){"use strict";var r=i(25070).notEmptyKey;function n(e,t){return r(t)&&"MUTABLE"===e.__get(t).getMutability()?t:null}e.exports=function(e,t){var i;if(t.isCollapsed()){var r=t.getAnchorKey(),s=t.getAnchorOffset();return s>0?(i=e.getBlockForKey(r).getEntityAt(s-1))!==e.getBlockForKey(r).getEntityAt(s)?null:n(e.getEntityMap(),i):null}var o=t.getStartKey(),a=t.getStartOffset(),l=e.getBlockForKey(o);return i=a===l.getLength()?null:l.getEntityAt(a),n(e.getEntityMap(),i)}},13355(e,t,i){"use strict";var r=i(54095);e.exports=function(e){var t=e.getSelection();return t.isCollapsed()?null:r(e.getCurrentContent(),t)}},26167(e,t,i){"use strict";var r=i(31527);e.exports=function(e,t){if(!(e instanceof r))return null;var i=e.getNextSiblingKey();if(i)return i;var n=e.getParentKey();if(!n)return null;for(var s=t.get(n);s&&!s.getNextSiblingKey();){var o=s.getParentKey();s=o?t.get(o):null}return s?s.getNextSiblingKey():null}},68768(e){"use strict";e.exports=function(e){return Object.keys(e).map(function(t){return e[t]})}},66017(e,t,i){"use strict";var r=i(45072);e.exports=function(e){var t=r(e),i=0,n=0,s=0,o=0;if(t.length){if(t.length>1&&0===t[0].width){var a=t[1];i=a.top,n=a.right,s=a.bottom,o=a.left}else{var l=t[0];i=l.top,n=l.right,s=l.bottom,o=l.left}for(var c=1;c<t.length;c++){var u=t[c];0!==u.height&&0!==u.width&&(i=Math.min(i,u.top),n=Math.max(n,u.right),s=Math.max(s,u.bottom),o=Math.min(o,u.left))}}return{top:i,right:n,bottom:s,left:o,width:n-o,height:s-i}}},45072(e,t,i){"use strict";var r=i(63390),n=i(40041),s=r.isBrowser("Chrome")?function(e){for(var t=e.cloneRange(),i=[],r=e.endContainer;null!=r;r=r.parentNode){var s=r===e.commonAncestorContainer;s?t.setStart(e.startContainer,e.startOffset):t.setStart(t.endContainer,0);var o,a=Array.from(t.getClientRects());if(i.push(a),s)return i.reverse(),(o=[]).concat.apply(o,i);t.setEndBefore(r)}n(!1)}:function(e){return Array.from(e.getClientRects())};e.exports=s},23474(e,t,i){"use strict";var r=i(40041);e.exports=function(e,t){var i=[];return e.findEntityRanges(function(e){return e.getEntity()===t},function(e,t){i.push({start:e,end:t})}),i.length||r(!1),i}},38413(e,t,i){"use strict";var r=i(63390),n=i(40041),s=r.isBrowser("IE <= 9");e.exports=function(e){var t,i=null;return!s&&document.implementation&&document.implementation.createHTMLDocument&&((t=document.implementation.createHTMLDocument("foo")).documentElement||n(!1),t.documentElement.innerHTML=e,i=t.getElementsByTagName("body")[0]),i}},39762(e,t,i){"use strict";var r=i(66305);e.exports=function e(t){if(r(t)){var i=t,n=i.getAttribute("data-offset-key");if(n)return n;for(var s=0;s<i.childNodes.length;s++){var o=e(i.childNodes[s]);if(o)return o}}return null}},27786(e,t,i){"use strict";var r=i(40041),n=/\.textClipping$/,s={"text/plain":!0,"text/html":!0,"text/rtf":!0};e.exports=function(e,t){var i=0,o=[];e.forEach(function(a){!function(e,t){if(!globalThis.FileReader||e.type&&!(e.type in s))t("");else{if(""===e.type){var i="";return n.test(e.name)&&(i=e.name.replace(n,"")),void t(i)}var o=new FileReader;o.onload=function(){var e=o.result;"string"!=typeof e&&r(!1),t(e)},o.onerror=function(){t("")},o.readAsText(e)}}(a,function(r){i++,r&&o.push(r.slice(0,5e3)),i==e.length&&t(o.join("\r"))})})}},69397(e,t,i){"use strict";var r=i(13878),n=i(25813);e.exports=function(e,t,i,s,o){var a=n(e.getSelection());if(!t||!s)return a;var l=r.decode(t),c=l.blockKey,u=e.getBlockTree(c),h=u&&u.getIn([l.decoratorKey,"leaves",l.leafKey]),d=r.decode(s),p=d.blockKey,g=e.getBlockTree(p),f=g&&g.getIn([d.decoratorKey,"leaves",d.leafKey]);if(!h||!f)return a;var m=h.get("start"),v=f.get("start"),C=h?m+i:null,y=f?v+o:null;if(a.getAnchorKey()===c&&a.getAnchorOffset()===C&&a.getFocusKey()===p&&a.getFocusOffset()===y)return a;var w=!1;if(c===p){var S=h.get("end"),b=f.get("end");w=v===m&&b===S?o<i:v<m}else w=e.getCurrentContent().getBlockMap().keySeq().skipUntil(function(e){return e===c||e===p}).first()===p;return a.merge({anchorKey:c,anchorOffset:C,focusKey:p,focusOffset:y,isBackward:w})}},50531(e,t,i){"use strict";var r=i(66017);e.exports=function(e){var t=e.getSelection();if(!t.rangeCount)return null;var i=t.getRangeAt(0),n=r(i),s=n.top,o=n.right,a=n.bottom,l=n.left;return 0===s&&0===o&&0===a&&0===l?null:n}},82826(e){"use strict";e.exports=function(e){return e&&e.ownerDocument&&e.ownerDocument.defaultView?e.ownerDocument.defaultView:window}},17595(e){"use strict";e.exports=function(e){return!("undefined"==typeof window||!window.__DRAFT_GKX||!window.__DRAFT_GKX[e])}},72368(e,t,i){"use strict";var r=i(84433),n=i(31527),s=i(99251),o=i(86374),a=i(40041),l=i(30287),c=s.List;e.exports=function(e,t,i){var s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"REPLACE_WITH_NEW_DATA";t.isCollapsed()||a(!1);var u=e.getBlockMap(),h=l(i),d=t.getStartKey(),p=t.getStartOffset(),g=u.get(d);return g instanceof n&&(g.getChildKeys().isEmpty()||a(!1)),1===h.size?function(e,t,i,r,n,s){var a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:"REPLACE_WITH_NEW_DATA",l=i.get(n),c=l.getText(),u=l.getCharacterList(),h=n,d=s+r.getText().length,p=null;switch(a){case"MERGE_OLD_DATA_TO_NEW_DATA":p=r.getData().merge(l.getData());break;case"REPLACE_WITH_NEW_DATA":p=r.getData()}var g=l.getType();c&&"unstyled"===g&&(g=r.getType());var f=l.merge({text:c.slice(0,s)+r.getText()+c.slice(s),characterList:o(u,r.getCharacterList(),s),type:g,data:p});return e.merge({blockMap:i.set(n,f),selectionBefore:t,selectionAfter:t.merge({anchorKey:h,anchorOffset:d,focusKey:h,focusOffset:d,isBackward:!1})})}(e,t,u,h.first(),d,p,s):function(e,t,i,s,o,a){var l=i.first()instanceof n,u=[],h=s.size,d=i.get(o),p=s.first(),g=s.last(),f=g.getLength(),m=g.getKey(),v=l&&(!d.getChildKeys().isEmpty()||!p.getChildKeys().isEmpty());i.forEach(function(e,t){t===o?(v?u.push(e):u.push(function(e,t,i){var r=e.getText(),n=e.getCharacterList(),s=r.slice(0,t),o=n.slice(0,t),a=i.first();return e.merge({text:s+a.getText(),characterList:o.concat(a.getCharacterList()),type:s?e.getType():a.getType(),data:a.getData()})}(e,a,s)),s.slice(v?0:1,h-1).forEach(function(e){return u.push(e)}),u.push(function(e,t,i){var r=e.getText(),n=e.getCharacterList(),s=r.length,o=r.slice(t,s),a=n.slice(t,s),l=i.last();return l.merge({text:l.getText()+o,characterList:l.getCharacterList().concat(a),data:l.getData()})}(e,a,s))):u.push(e)});var C=r.createFromArray(u);return l&&(C=function(e,t,i,r){return e.withMutations(function(t){var n=i.getKey(),s=r.getKey(),o=i.getNextSiblingKey(),a=i.getParentKey(),l=function(e,t){var i=e.getKey(),r=e,n=[];for(t.get(i)&&n.push(i);r&&r.getNextSiblingKey();){var s=r.getNextSiblingKey();if(!s)break;n.push(s),r=t.get(s)}return n}(r,e),u=l[l.length-1];if(t.get(s)?(t.setIn([n,"nextSibling"],s),t.setIn([s,"prevSibling"],n)):(t.setIn([n,"nextSibling"],r.getNextSiblingKey()),t.setIn([r.getNextSiblingKey(),"prevSibling"],n)),t.setIn([u,"nextSibling"],o),o&&t.setIn([o,"prevSibling"],u),l.forEach(function(e){return t.setIn([e,"parent"],a)}),a){var h=e.get(a).getChildKeys(),d=h.indexOf(n)+1,p=h.toArray();p.splice.apply(p,[d,0].concat(l)),t.setIn([a,"children"],c(p))}})}(C,0,d,p)),e.merge({blockMap:C,selectionBefore:t,selectionAfter:t.merge({anchorKey:m,anchorOffset:f,focusKey:m,focusOffset:f,isBackward:!1})})}(e,t,u,h,d,p)}},86374(e){"use strict";e.exports=function(e,t,i){var r=e;if(i===r.count())t.forEach(function(e){r=r.push(e)});else if(0===i)t.reverse().forEach(function(e){r=r.unshift(e)});else{var n=r.slice(0,i),s=r.slice(i);r=n.concat(t,s).toList()}return r}},32983(e,t,i){"use strict";var r=i(99251),n=i(86374),s=i(40041),o=r.Repeat;e.exports=function(e,t,i,r){t.isCollapsed()||s(!1);var a=null;if(null!=i&&(a=i.length),null==a||0===a)return e;var l=e.getBlockMap(),c=t.getStartKey(),u=t.getStartOffset(),h=l.get(c),d=h.getText(),p=h.merge({text:d.slice(0,u)+i+d.slice(u,h.getLength()),characterList:n(h.getCharacterList(),o(r,a).toList(),u)}),g=u+a;return e.merge({blockMap:l.set(c,p),selectionAfter:t.merge({anchorOffset:g,focusOffset:g})})}},66305(e){"use strict";e.exports=function(e){return!(!e||!e.ownerDocument)&&e.nodeType===Node.ELEMENT_NODE}},46415(e){"use strict";e.exports=function(e){return"handled"===e||!0===e}},34189(e,t,i){"use strict";var r=i(66305);e.exports=function(e){return!(!e||!e.ownerDocument)&&r(e)&&"A"===e.nodeName}},4734(e,t,i){"use strict";var r=i(66305);e.exports=function(e){return!(!e||!e.ownerDocument)&&r(e)&&"BR"===e.nodeName}},44110(e){"use strict";e.exports=function(e){return!(!e||!e.ownerDocument)&&(e.ownerDocument.defaultView?e instanceof e.ownerDocument.defaultView.HTMLElement:e instanceof HTMLElement)}},80119(e,t,i){"use strict";var r=i(66305);e.exports=function(e){return!(!e||!e.ownerDocument)&&r(e)&&"IMG"===e.nodeName}},76871(e){"use strict";e.exports=function(e){if(!e||!("ownerDocument"in e))return!1;if("ownerDocument"in e){var t=e;if(!t.ownerDocument.defaultView)return t instanceof Node;if(t instanceof t.ownerDocument.defaultView.Node)return!0}return!1}},65044(e){"use strict";e.exports=function(e){var t=e.getSelection(),i=t.getAnchorKey(),r=e.getBlockTree(i),n=t.getStartOffset(),s=!1;return r.some(function(e){return n===e.get("start")?(s=!0,!0):n<e.get("end")&&e.get("leaves").some(function(e){var t=e.get("start");return n===t&&(s=!0,!0)})}),s}},97253(e,t,i){"use strict";var r=i(4617);e.exports=function(e){return e.which===r.RETURN&&(e.getModifierState("Shift")||e.getModifierState("Alt")||e.getModifierState("Control"))}},50976(e,t,i){"use strict";var r=i(59539),n=i(31950),s=i(89668),o=i(95625),a=i(16335);e.exports=function(e,t){var i=a(e,function(e){var i=e.getSelection();if(i.isCollapsed()&&0===i.getAnchorOffset())return o(e,1);var r=t.currentTarget.ownerDocument.defaultView.getSelection().getRangeAt(0);return r=n(r),s(e,null,r.endContainer,r.endOffset,r.startContainer,r.startOffset).selectionState},"backward");return i===e.getCurrentContent()?e:r.push(e,i,"remove-range")}},44126(e,t,i){"use strict";var r=i(76425),n=i(59539),s=i(95625),o=i(16335);e.exports=function(e){var t=o(e,function(e){var t=e.getSelection(),i=t.getStartOffset();if(0===i)return s(e,1);var n=t.getStartKey(),o=e.getCurrentContent().getBlockForKey(n).getText().slice(0,i),a=r.getBackward(o);return s(e,a.length||1)},"backward");return t===e.getCurrentContent()?e:n.push(e,t,"remove-range")}},27130(e,t,i){"use strict";var r=i(76425),n=i(59539),s=i(30919),o=i(16335);e.exports=function(e){var t=o(e,function(e){var t=e.getSelection(),i=t.getStartOffset(),n=t.getStartKey(),o=e.getCurrentContent().getBlockForKey(n).getText().slice(i),a=r.getForward(o);return s(e,a.length||1)},"forward");return t===e.getCurrentContent()?e:n.push(e,t,"remove-range")}},79774(e,t,i){"use strict";var r=i(58267),n=i(59539);e.exports=function(e){var t=r.splitBlock(e.getCurrentContent(),e.getSelection());return n.push(e,t,"split-block")}},11644(e,t,i){"use strict";var r=i(59539);e.exports=function(e){var t=e.getSelection(),i=t.getEndKey(),n=e.getCurrentContent().getBlockForKey(i).getLength();return r.set(e,{selection:t.merge({anchorKey:i,anchorOffset:n,focusKey:i,focusOffset:n,isBackward:!1}),forceSelection:!0})}},63467(e,t,i){"use strict";var r=i(59539);e.exports=function(e){var t=e.getSelection(),i=t.getStartKey();return r.set(e,{selection:t.merge({anchorKey:i,anchorOffset:0,focusKey:i,focusOffset:0,isBackward:!1}),forceSelection:!0})}},97402(e,t,i){"use strict";var r=i(59539),n=i(13145),s=i(95625),o=i(16335);e.exports=function(e){var t=o(e,function(e){var t=e.getSelection(),i=e.getCurrentContent(),r=t.getAnchorKey(),o=t.getAnchorOffset(),a=i.getBlockForKey(r).getText()[o-1];return s(e,a?n.getUTF16Length(a,0):1)},"backward");if(t===e.getCurrentContent())return e;var i=e.getSelection();return r.push(e,t.set("selectionBefore",i),i.isCollapsed()?"backspace-character":"remove-range")}},12750(e,t,i){"use strict";var r=i(59539),n=i(13145),s=i(30919),o=i(16335);e.exports=function(e){var t=o(e,function(e){var t=e.getSelection(),i=e.getCurrentContent(),r=t.getAnchorKey(),o=t.getAnchorOffset(),a=i.getBlockForKey(r).getText()[o];return s(e,a?n.getUTF16Length(a,0):1)},"forward");if(t===e.getCurrentContent())return e;var i=e.getSelection();return r.push(e,t.set("selectionBefore",i),i.isCollapsed()?"delete-character":"remove-range")}},2194(e,t,i){"use strict";var r=i(58267),n=i(59539),s=i(54095);e.exports=function(e){var t=e.getSelection();if(!t.isCollapsed())return e;var i=t.getAnchorOffset();if(0===i)return e;var o,a,l=t.getAnchorKey(),c=e.getCurrentContent(),u=c.getBlockForKey(l).getLength();if(u<=1)return e;i===u?(o=t.set("anchorOffset",i-1),a=t):a=(o=t.set("focusOffset",i+1)).set("anchorOffset",i+1);var h=s(c,o),d=r.removeRange(c,o,"backward"),p=d.getSelectionAfter(),g=p.getAnchorOffset()-1,f=p.merge({anchorOffset:g,focusOffset:g}),m=r.replaceWithFragment(d,f,h),v=n.push(e,m,"insert-fragment");return n.acceptSelection(v,a)}},38707(e,t,i){"use strict";var r=i(59539);e.exports=function(e,t,i){var n=r.undo(t);if("spellcheck-change"!==t.getLastChangeType())e.preventDefault(),t.getNativelyRenderedContent()?(i(r.set(t,{nativelyRenderedContent:null})),setTimeout(function(){i(n)},0)):i(n);else{var s=n.getCurrentContent();i(r.set(n,{nativelyRenderedContent:s}))}}},79981(e,t,i){"use strict";var r=i(99251).Map;e.exports=function(e,t,i){var n=t.getStartKey(),s=t.getEndKey(),o=e.getBlockMap(),a=o.toSeq().skipUntil(function(e,t){return t===n}).takeUntil(function(e,t){return t===s}).concat(r([[s,o.get(s)]])).map(i);return e.merge({blockMap:o.merge(a),selectionBefore:t,selectionAfter:t})}},83886(e,t,i){"use strict";var r=i(31527),n=i(26167),s=i(99251),o=i(40041),a=s.OrderedMap,l=s.List,c=function(e,t,i){if(e){var r=t.get(e);r&&t.set(e,i(r))}},u=function(e,t,i,r,n){if(!n)return e;var s="after"===r,o=t.getKey(),a=i.getKey(),u=t.getParentKey(),h=t.getNextSiblingKey(),d=t.getPrevSiblingKey(),p=i.getParentKey(),g=s?i.getNextSiblingKey():a,f=s?a:i.getPrevSiblingKey();return e.withMutations(function(e){c(u,e,function(e){var t=e.getChildKeys();return e.merge({children:t.delete(t.indexOf(o))})}),c(d,e,function(e){return e.merge({nextSibling:h})}),c(h,e,function(e){return e.merge({prevSibling:d})}),c(g,e,function(e){return e.merge({prevSibling:o})}),c(f,e,function(e){return e.merge({nextSibling:o})}),c(p,e,function(e){var t=e.getChildKeys(),i=t.indexOf(a),r=s?i+1:0!==i?i-1:0,n=t.toArray();return n.splice(r,0,o),e.merge({children:l(n)})}),c(o,e,function(e){return e.merge({nextSibling:g,prevSibling:f,parent:p})})})};e.exports=function(e,t,i,s){"replace"===s&&o(!1);var l=i.getKey(),c=t.getKey();c===l&&o(!1);var h=e.getBlockMap(),d=t instanceof r,p=[t],g=h.delete(c);d&&(p=[],g=h.withMutations(function(e){var i=t.getNextSiblingKey(),r=n(t,e);e.toSeq().skipUntil(function(e){return e.getKey()===c}).takeWhile(function(e){var t=e.getKey(),n=t===c,s=i&&t!==i,o=!i&&e.getParentKey()&&(!r||t!==r);return!!(n||s||o)}).forEach(function(t){p.push(t),e.delete(t.getKey())})}));var f=g.toSeq().takeUntil(function(e){return e===i}),m=g.toSeq().skipUntil(function(e){return e===i}).skip(1),v=p.map(function(e){return[e.getKey(),e]}),C=a();if("before"===s){var y=e.getBlockBefore(l);y&&y.getKey()===t.getKey()&&o(!1),C=f.concat([].concat(v,[[l,i]]),m).toOrderedMap()}else if("after"===s){var w=e.getBlockAfter(l);w&&w.getKey()===c&&o(!1),C=f.concat([[l,i]].concat(v),m).toOrderedMap()}return e.merge({blockMap:u(C,t,i,s,d),selectionBefore:e.getSelectionAfter(),selectionAfter:e.getSelectionAfter().merge({anchorKey:c,focusKey:c})})}},95625(e,t,i){"use strict";i(92697),e.exports=function(e,t){var i=e.getSelection(),r=e.getCurrentContent(),n=i.getStartKey(),s=i.getStartOffset(),o=n,a=0;if(t>s){var l=r.getKeyBefore(n);null==l?o=n:(o=l,a=r.getBlockForKey(l).getText().length)}else a=s-t;return i.merge({focusKey:o,focusOffset:a,isBackward:!0})}},30919(e,t,i){"use strict";i(92697),e.exports=function(e,t){var i,r=e.getSelection(),n=r.getStartKey(),s=r.getStartOffset(),o=e.getCurrentContent(),a=n;return t>o.getBlockForKey(n).getText().length-s?(a=o.getKeyAfter(n),i=0):i=s+t,r.merge({focusKey:a,focusOffset:i})}},30287(e,t,i){"use strict";var r=i(31527),n=i(12634),s=i(99251).OrderedMap;e.exports=function(e){return e.first()instanceof r?function(e){var t,i={};return s(e.withMutations(function(e){e.forEach(function(r,s){var o=r.getKey(),a=r.getNextSiblingKey(),l=r.getPrevSiblingKey(),c=r.getChildKeys(),u=r.getParentKey(),h=n();if(i[o]=h,a&&(e.get(a)?e.setIn([a,"prevSibling"],h):e.setIn([o,"nextSibling"],null)),l&&(e.get(l)?e.setIn([l,"nextSibling"],h):e.setIn([o,"prevSibling"],null)),u&&e.get(u)){var d=e.get(u).getChildKeys();e.setIn([u,"children"],d.set(d.indexOf(r.getKey()),h))}else e.setIn([o,"parent"],null),t&&(e.setIn([t.getKey(),"nextSibling"],h),e.setIn([o,"prevSibling"],i[t.getKey()])),t=e.get(o);c.forEach(function(t){e.get(t)?e.setIn([t,"parent"],h):e.setIn([o,"children"],r.getChildKeys().filter(function(e){return e!==t}))})})}).toArray().map(function(e){return[i[e.getKey()],e.set("key",i[e.getKey()])]}))}(e):function(e){return s(e.toArray().map(function(e){var t=n();return[t,e.set("key",t)]}))}(e)}},91825(e,t,i){"use strict";var r=i(41671),n=i(14910),s=i(40041);function o(e,t,i){var o=t.getCharacterList(),a=i>0?o.get(i-1):void 0,l=i<o.count()?o.get(i):void 0,c=a?a.getEntity():void 0,u=l?l.getEntity():void 0;if(u&&u===c&&"MUTABLE"!==e.__get(u).getMutability()){for(var h,d=function(e,t,i){var r;return n(e,function(e,t){return e.getEntity()===t.getEntity()},function(e){return e.getEntity()===t},function(e,t){e<=i&&t>=i&&(r={start:e,end:t})}),"object"!=typeof r&&s(!1),r}(o,u,i),p=d.start,g=d.end;p<g;)h=o.get(p),o=o.set(p,r.applyEntity(h,null)),p++;return t.set("characterList",o)}return t}e.exports=function(e,t){var i=e.getBlockMap(),r=e.getEntityMap(),n={},s=t.getStartKey(),a=t.getStartOffset(),l=i.get(s),c=o(r,l,a);c!==l&&(n[s]=c);var u=t.getEndKey(),h=t.getEndOffset(),d=i.get(u);s===u&&(d=c);var p=o(r,d,h);return p!==d&&(n[u]=p),Object.keys(n).length?e.merge({blockMap:i.merge(n),selectionAfter:t}):e.set("selectionAfter",t)}},5646(e,t,i){"use strict";var r=i(31527),n=i(26167),s=i(99251),o=(s.List,s.Map),a=function(e,t,i){if(e){var r=t.get(e);r&&t.set(e,i(r))}},l=function(e,t){var i=[];if(!e)return i;for(var r=t.get(e);r&&r.getParentKey();){var n=r.getParentKey();n&&i.push(n),r=n?t.get(n):null}return i},c=function(e,t,i){if(!e)return null;for(var r=i.get(e.getKey()).getNextSiblingKey();r&&!t.get(r);)r=i.get(r).getNextSiblingKey()||null;return r},u=function(e,t,i){if(!e)return null;for(var r=i.get(e.getKey()).getPrevSiblingKey();r&&!t.get(r);)r=i.get(r).getPrevSiblingKey()||null;return r};e.exports=function(e,t){if(t.isCollapsed())return e;var i,s=e.getBlockMap(),h=t.getStartKey(),d=t.getStartOffset(),p=t.getEndKey(),g=t.getEndOffset(),f=s.get(h),m=s.get(p),v=f instanceof r,C=[];if(v){var y=m.getChildKeys(),w=l(p,s);m.getNextSiblingKey()&&(C=C.concat(w)),y.isEmpty()||(C=C.concat(w.concat([p]))),C=C.concat(l(n(m,s),s))}i=f===m?function(e,t,i){if(0===t)for(;t<i;)e=e.shift(),t++;else if(i===e.count())for(;i>t;)e=e.pop(),i--;else{var r=e.slice(0,t),n=e.slice(i);e=r.concat(n).toList()}return e}(f.getCharacterList(),d,g):f.getCharacterList().slice(0,d).concat(m.getCharacterList().slice(g));var S=f.merge({text:f.getText().slice(0,d)+m.getText().slice(g),characterList:i}),b=v&&0===d&&0===g&&m.getParentKey()===h&&null==m.getPrevSiblingKey()?o([[h,null]]):s.toSeq().skipUntil(function(e,t){return t===h}).takeUntil(function(e,t){return t===p}).filter(function(e,t){return-1===C.indexOf(t)}).concat(o([[p,null]])).map(function(e,t){return t===h?S:null}),E=s.merge(b).filter(function(e){return!!e});return v&&f!==m&&(E=function(e,t,i,r){return e.withMutations(function(s){if(a(t.getKey(),s,function(e){return e.merge({nextSibling:c(e,s,r),prevSibling:u(e,s,r)})}),a(i.getKey(),s,function(e){return e.merge({nextSibling:c(e,s,r),prevSibling:u(e,s,r)})}),l(t.getKey(),r).forEach(function(e){return a(e,s,function(e){return e.merge({children:e.getChildKeys().filter(function(e){return s.get(e)}),nextSibling:c(e,s,r),prevSibling:u(e,s,r)})})}),a(t.getNextSiblingKey(),s,function(e){return e.merge({prevSibling:t.getPrevSiblingKey()})}),a(t.getPrevSiblingKey(),s,function(e){return e.merge({nextSibling:c(e,s,r)})}),a(i.getNextSiblingKey(),s,function(e){return e.merge({prevSibling:u(e,s,r)})}),a(i.getPrevSiblingKey(),s,function(e){return e.merge({nextSibling:i.getNextSiblingKey()})}),l(i.getKey(),r).forEach(function(e){a(e,s,function(e){return e.merge({children:e.getChildKeys().filter(function(e){return s.get(e)}),nextSibling:c(e,s,r),prevSibling:u(e,s,r)})})}),function(e,t){var i=[];if(!e)return i;for(var r=n(e,t);r&&t.get(r);){var s=t.get(r);i.push(r),r=s.getParentKey()?n(s,t):null}return i}(i,r).forEach(function(e){return a(e,s,function(e){return e.merge({nextSibling:c(e,s,r),prevSibling:u(e,s,r)})})}),null==e.get(t.getKey())&&null!=e.get(i.getKey())&&i.getParentKey()===t.getKey()&&null==i.getPrevSiblingKey()){var o=t.getPrevSiblingKey();a(i.getKey(),s,function(e){return e.merge({prevSibling:o})}),a(o,s,function(e){return e.merge({nextSibling:i.getKey()})});var h=o?e.get(o):null,d=h?h.getParentKey():null;if(t.getChildKeys().forEach(function(e){a(e,s,function(e){return e.merge({parent:d})})}),null!=d){var p=e.get(d);a(d,s,function(e){return e.merge({children:p.getChildKeys().concat(t.getChildKeys())})})}a(t.getChildKeys().find(function(t){return null===e.get(t).getNextSiblingKey()}),s,function(e){return e.merge({nextSibling:t.getNextSiblingKey()})})}})}(E,f,m,s)),e.merge({blockMap:E,selectionBefore:t,selectionAfter:t.merge({anchorKey:h,anchorOffset:d,focusKey:h,focusOffset:d,isBackward:!1})})}},16335(e,t,i){"use strict";var r=i(58267),n=i(17595)("draft_tree_data_support");e.exports=function(e,t,i){var s=e.getSelection(),o=e.getCurrentContent(),a=s,l=s.getAnchorKey(),c=s.getFocusKey(),u=o.getBlockForKey(l);if(n&&"forward"===i&&l!==c)return o;if(s.isCollapsed()){if("forward"===i){if(e.isSelectionAtEndOfContent())return o;if(n&&s.getAnchorOffset()===o.getBlockForKey(l).getLength()){var h=o.getBlockForKey(u.nextSibling);if(!h||0===h.getLength())return o}}else if(e.isSelectionAtStartOfContent())return o;if((a=t(e))===s)return o}return r.removeRange(o,a,i)}},10160(e){"use strict";var t=new RegExp("\r","g");e.exports=function(e){return e.replace(t,"")}},90933(e,t,i){"use strict";var r=i(7618),n=i(35693),s=i(63390),o=i(68820),a=i(53967),l=i(82097),c=i(40041),u=i(66305),h=s.isBrowser("IE");function d(e,t){if(!e)return"[empty]";var i=p(e,t);return i.nodeType===Node.TEXT_NODE?i.textContent:(u(i)||c(!1),i.outerHTML)}function p(e,t){var i=void 0!==t?t(e):[];if(e.nodeType===Node.TEXT_NODE){var r=e.textContent.length;return l(e).createTextNode("[text "+r+(i.length?" | "+i.join(", "):"")+"]")}var n=e.cloneNode();1===n.nodeType&&i.length&&n.setAttribute("data-labels",i.join(", "));for(var s=e.childNodes,o=0;o<s.length;o++)n.appendChild(p(s[o],t));return n}function g(e,t){for(var i=e,r=i;i;){if(u(i)&&r.hasAttribute("contenteditable"))return d(i,t);r=i=i.parentNode}return"Could not find contentEditable parent of node"}function f(e){return null===e.nodeValue?e.childNodes.length:e.nodeValue.length}function m(e,t,i,r){var s=a();if(e.extend&&null!=t&&o(s,t)){i>f(t)&&n.logSelectionStateFailure({anonymizedDom:g(t),extraParams:JSON.stringify({offset:i}),selectionState:JSON.stringify(r.toJS())});var l=t===e.focusNode;try{e.rangeCount>0&&e.extend&&e.extend(t,i)}catch(o){throw n.logSelectionStateFailure({anonymizedDom:g(t,function(t){var i=[];return t===s&&i.push("active element"),t===e.anchorNode&&i.push("selection anchor node"),t===e.focusNode&&i.push("selection focus node"),i}),extraParams:JSON.stringify({activeElementName:s?s.nodeName:null,nodeIsFocus:t===e.focusNode,nodeWasFocus:l,selectionRangeCount:e.rangeCount,selectionAnchorNodeName:e.anchorNode?e.anchorNode.nodeName:null,selectionAnchorOffset:e.anchorOffset,selectionFocusNodeName:e.focusNode?e.focusNode.nodeName:null,selectionFocusOffset:e.focusOffset,message:o?""+o:null,offset:i},null,2),selectionState:JSON.stringify(r.toJS(),null,2)}),o}}else if(t&&e.rangeCount>0){var c=e.getRangeAt(0);c.setEnd(t,i),e.addRange(c.cloneRange())}}function v(e,t,i,s){var o=l(t).createRange();if(i>f(t)&&(n.logSelectionStateFailure({anonymizedDom:g(t),extraParams:JSON.stringify({offset:i}),selectionState:JSON.stringify(s.toJS())}),r.handleExtensionCausedError()),o.setStart(t,i),h)try{e.addRange(o)}catch(e){}else e.addRange(o)}e.exports={setDraftEditorSelection:function(e,t,i,r,n){var s=l(t);if(o(s.documentElement,t)){var a=s.defaultView.getSelection(),c=e.getAnchorKey(),u=e.getAnchorOffset(),h=e.getFocusKey(),d=e.getFocusOffset(),p=e.getIsBackward();if(!a.extend&&p){var g=c,f=u;c=h,u=d,h=g,d=f,p=!1}var C=c===i&&r<=u&&n>=u,y=h===i&&r<=d&&n>=d;if(C&&y)return a.removeAllRanges(),v(a,t,u-r,e),void m(a,t,d-r,e);if(p){if(y&&(a.removeAllRanges(),v(a,t,d-r,e)),C){var w=a.focusNode,S=a.focusOffset;a.removeAllRanges(),v(a,t,u-r,e),m(a,w,S,e)}}else C&&(a.removeAllRanges(),v(a,t,u-r,e)),y&&m(a,t,d-r,e)}},addFocusToSelection:m}},2661(e,t,i){"use strict";var r=i(31527),n=i(12634),s=i(99251),o=i(40041),a=i(79981),l=s.List,c=s.Map,u=function(e,t,i){if(e){var r=t.get(e);r&&t.set(e,i(r))}};e.exports=function(e,t){t.isCollapsed()||o(!1);var i=t.getAnchorKey(),s=e.getBlockMap(),h=s.get(i),d=h.getText();if(!d){var p=h.getType();if("unordered-list-item"===p||"ordered-list-item"===p)return a(e,t,function(e){return e.merge({type:"unstyled",depth:0})})}var g=t.getAnchorOffset(),f=h.getCharacterList(),m=n(),v=h instanceof r,C=h.merge({text:d.slice(0,g),characterList:f.slice(0,g)}),y=C.merge({key:m,text:d.slice(g),characterList:f.slice(g),data:c()}),w=s.toSeq().takeUntil(function(e){return e===h}),S=s.toSeq().skipUntil(function(e){return e===h}).rest(),b=w.concat([[i,C],[m,y]],S).toOrderedMap();return v&&(h.getChildKeys().isEmpty()||o(!1),b=function(e,t,i){return e.withMutations(function(e){var r=t.getKey(),n=i.getKey();u(t.getParentKey(),e,function(e){var t=e.getChildKeys(),i=t.indexOf(r)+1,s=t.toArray();return s.splice(i,0,n),e.merge({children:l(s)})}),u(t.getNextSiblingKey(),e,function(e){return e.merge({prevSibling:n})}),u(r,e,function(e){return e.merge({nextSibling:n})}),u(n,e,function(e){return e.merge({prevSibling:r})})})}(b,C,y)),e.merge({blockMap:b,selectionBefore:t,selectionAfter:t.merge({anchorKey:m,anchorOffset:0,focusKey:m,focusOffset:0,isBackward:!1})})}},55585(e){"use strict";var t=/\r\n?|\n/g;e.exports=function(e){return e.split(t)}},10254(e){"use strict";e.exports=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"==e?t:3&t|8).toString(16)})}},53692(e){e.exports=function(){"use strict";var e=function(){return e=Object.assign||function(e){for(var t,i=1,r=arguments.length;i<r;i++)for(var n in t=arguments[i])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e},e.apply(this,arguments)};function t(e,t,i,r){return new(i||(i=Promise))(function(n,s){function o(e){try{l(r.next(e))}catch(e){s(e)}}function a(e){try{l(r.throw(e))}catch(e){s(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof i?t:new i(function(e){e(t)})).then(o,a)}l((r=r.apply(e,t||[])).next())})}function i(e,t){var i,r,n,s,o={label:0,sent:function(){if(1&n[0])throw n[1];return n[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(s[Symbol.iterator]=function(){return this}),s;function a(s){return function(a){return function(s){if(i)throw new TypeError("Generator is already executing.");for(;o;)try{if(i=1,r&&(n=2&s[0]?r.return:s[0]?r.throw||((n=r.return)&&n.call(r),0):r.next)&&!(n=n.call(r,s[1])).done)return n;switch(r=0,n&&(s=[2&s[0],n.value]),s[0]){case 0:case 1:n=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!((n=(n=o.trys).length>0&&n[n.length-1])||6!==s[0]&&2!==s[0])){o=0;continue}if(3===s[0]&&(!n||s[1]>n[0]&&s[1]<n[3])){o.label=s[1];break}if(6===s[0]&&o.label<n[1]){o.label=n[1],n=s;break}if(n&&o.label<n[2]){o.label=n[2],o.ops.push(s);break}n[2]&&o.ops.pop(),o.trys.pop();continue}s=t.call(e,o)}catch(e){s=[6,e],r=0}finally{i=n=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,a])}}}var r,n,s,o,a,l;!function(e){e.INIT_IFRAME="INIT_IFRAME"}(r||(r={})),function(e){e.Call="call",e.Reply="reply",e.Syn="syn",e.SynAck="synAck",e.Ack="ack"}(n||(n={})),function(e){e.Fulfilled="fulfilled",e.Rejected="rejected"}(s||(s={})),function(e){e.ConnectionDestroyed="ConnectionDestroyed",e.ConnectionTimeout="ConnectionTimeout",e.NotInIframe="NotInIframe",e.NoIframeSrc="NoIframeSrc"}(o||(o={})),function(e){e.DataCloneError="DataCloneError"}(a||(a={})),function(e){e.Message="message"}(l||(l={}));const c={"http:":"80","https:":"443"},u=/^(https?:)?\/\/([^/:]+)?(:(\d+))?/,h=["file:","data:"],d=({name:e,message:t,stack:i})=>({name:e,message:t,stack:i});let p=0;var g=()=>++p,f=(e,t,i,r,a)=>{const{localName:c,local:u,remote:h,originForSending:d,originForReceiving:p}=t;let f=!1;a(`${c}: Connecting call sender`);return i.reduce((e,t)=>(e[t]=(e=>(...t)=>{let i;a(`${c}: Sending ${e}() call`);try{h.closed&&(i=!0)}catch(e){i=!0}if(i&&r(),f){const t=new Error(`Unable to send ${e}() call due to destroyed connection`);throw t.code=o.ConnectionDestroyed,t}return new Promise((i,r)=>{const o=g(),f=t=>{if(t.source!==h||t.data.penpal!==n.Reply||t.data.id!==o)return;if(t.origin!==p)return void a(`${c} received message from origin ${t.origin} which did not match expected origin ${p}`);const d=t.data;a(`${c}: Received ${e}() reply`),u.removeEventListener(l.Message,f);let g=d.returnValue;d.returnValueIsError&&(g=(e=>{const t=new Error;return Object.keys(e).forEach(i=>t[i]=e[i]),t})(g)),(d.resolution===s.Fulfilled?i:r)(g)};u.addEventListener(l.Message,f);const m={penpal:n.Call,id:o,methodName:e,args:t};h.postMessage(m,d)})})(t),e),e),()=>{f=!0}},m=(e,t,i,r,o)=>{const{destroy:c,onDestroy:u}=r;let h,p;const g={};return r=>{if(r.origin!==t)return void o(`Parent: Handshake - Received ACK message from origin ${r.origin} which did not match expected origin ${t}`);o("Parent: Handshake - Received ACK");const m={localName:"Parent",local:window,remote:r.source,originForSending:i,originForReceiving:t};h&&h(),h=((e,t,i)=>{const{localName:r,local:o,remote:c,originForSending:u,originForReceiving:h}=e;let p=!1;const g=e=>{if(e.source!==c||e.data.penpal!==n.Call)return;if(e.origin!==h)return void i(`${r} received message from origin ${e.origin} which did not match expected origin ${h}`);const o=e.data,{methodName:l,args:g,id:f}=o;i(`${r}: Received ${l}() call`);const m=e=>t=>{if(i(`${r}: Sending ${l}() reply`),p)return void i(`${r}: Unable to send ${l}() reply due to destroyed connection`);const o={penpal:n.Reply,id:f,resolution:e,returnValue:t};e===s.Rejected&&t instanceof Error&&(o.returnValue=d(t),o.returnValueIsError=!0);try{c.postMessage(o,u)}catch(e){if(e.name===a.DataCloneError){const t={penpal:n.Reply,id:f,resolution:s.Rejected,returnValue:d(e),returnValueIsError:!0};c.postMessage(t,u)}throw e}};new Promise(e=>e(t[l].apply(t,g))).then(m(s.Fulfilled),m(s.Rejected))};return o.addEventListener(l.Message,g),()=>{p=!0,o.removeEventListener(l.Message,g)}})(m,e,o),u(h),p&&p.forEach(e=>{delete g[e]}),p=r.data.methodNames;const v=f(g,m,p,c,o);return u(v),g}},v=e=>{let{iframe:t,methods:i={},childOrigin:r,timeout:s,debug:a=!1}=e;const d=(e=>(...t)=>{e&&console.log("[Penpal]",...t)})(a),p=(()=>{const e=[];let t=!1;return{destroy(i){t=!0,e.forEach(e=>{e(i)})},onDestroy(i){t?i():e.push(i)}}})(),{onDestroy:g,destroy:f}=p;r||((e=>{if(!e.src&&!e.srcdoc){const e=new Error("Iframe must have src or srcdoc property defined.");throw e.code=o.NoIframeSrc,e}})(t),r=(e=>{if(e&&h.find(t=>e.startsWith(t)))return"null";const t=document.location,i=u.exec(e);let r,n,s;return i?(r=i[1]?i[1]:t.protocol,n=i[2],s=i[4]):(r=t.protocol,n=t.hostname,s=t.port),`${r}//${n}${s&&s!==c[r]?`:${s}`:""}`})(t.src));const v="null"===r?"*":r,C=((e,t,i,r)=>s=>{if(s.origin!==i)return void e(`Parent: Handshake - Received SYN message from origin ${s.origin} which did not match expected origin ${i}`);e("Parent: Handshake - Received SYN, responding with SYN-ACK");const o={penpal:n.SynAck,methodNames:Object.keys(t)};s.source.postMessage(o,r)})(d,i,r,v),y=m(i,r,v,p,d),w=new Promise((e,i)=>{const r=((e,t)=>{let i;return void 0!==e&&(i=window.setTimeout(()=>{const i=new Error(`Connection timed out after ${e}ms`);i.code=o.ConnectionTimeout,t(i)},e)),()=>{clearTimeout(i)}})(s,f),a=i=>{if(i.source===t.contentWindow&&i.data)if(i.data.penpal!==n.Syn){if(i.data.penpal===n.Ack){const t=y(i);return void(t&&(r(),e(t)))}}else C(i)};window.addEventListener(l.Message,a),d("Parent: Awaiting handshake"),((e,t)=>{const{destroy:i,onDestroy:r}=t,n=setInterval(()=>{e.isConnected||(clearInterval(n),i())},6e4);r(()=>{clearInterval(n)})})(t,p),g(e=>{window.removeEventListener(l.Message,a),e||((e=new Error("Connection destroyed")).code=o.ConnectionDestroyed),i(e)})});return{promise:w,destroy(){f()}}},C=function(e,t){return console.error("[Dromo-External-Error] There was an error running your ".concat(t,"."),e)},y=function(e){return setTimeout(function(){console.warn("[Dromo Error] Slow ".concat(e," detected (>10s). Long running hooks can degrade user experience and importer performance."))},1e4)},w=function(e){clearTimeout(e)},S=function(r,n,s){return t(void 0,void 0,void 0,function(){var o,a,l;return i(this,function(c){switch(c.label){case 0:return o=new Map,a=n.map(function(t){return e({},t)}),[4,r.reduce(function(e,r){return t(void 0,void 0,void 0,function(){return i(this,function(n){switch(n.label){case 0:return[4,e.then(function(){return t(void 0,void 0,void 0,function(){var e,t,n;return i(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),e=y("column hook"),[4,r.callback(a)];case 1:return t=i.sent(),w(e),t.forEach(function(e){if(void 0!==e.value||void 0!==e.info){var t={};void 0!==e.value&&(t.value=e.value,a[e.index].value=e.value),void 0!==e.info&&(t.info=e.info),o.set(e.index,t)}}),[3,3];case 2:return n=i.sent(),s(n,"column hooks"),[3,3];case 3:return[2]}})})})];case 1:return n.sent(),[2]}})})},Promise.resolve())];case 1:return c.sent(),l=[],o.forEach(function(t,i){return l.push(e(e({},t),{index:i}))}),[2,l]}})})},b=function(e){return void 0===e.value&&void 0===e.info&&void 0===e.selectOptions&&void 0===e.manyToOne},E=function(e,r,n,s,o){return t(void 0,void 0,void 0,function(){var a,l,c,u,h,d,p,g,f,m,v,C,S;return i(this,function(E){switch(E.label){case 0:a=new Map,l=new Map(e.map(function(e){return[e.index,e]})),c=function(e,t){for(var i,r=l.get(e),n=function(t,n){if(b(n))return"continue";var s=r.row[t],o=Array.isArray(s.manyToOne),l="manyToOne"in n&&Array.isArray(n.manyToOne);if(o&&!l)throw new Error("".concat(t," should have manyToOne defined as an array."));if(o&&l&&s.manyToOne.length!==n.manyToOne.length)throw new Error("".concat(t," should be array of length ").concat(s.manyToOne.length));var c=a.get(e)||{},u=null!==(i=c[t])&&void 0!==i?i:{},h=[];l?(u.manyToOne=[],n.manyToOne.forEach(function(e,t){if(!b(e)){var i={};u.manyToOne.push(i),h.push({fieldOutput:e,rowDataField:s.manyToOne[t],cellChange:i})}})):h.push({fieldOutput:n,rowDataField:s,cellChange:u}),h.forEach(function(e){var t=e.fieldOutput,i=e.rowDataField,r=e.cellChange;void 0!==t.value&&(r.value=t.value,i.value=t.value),void 0!==t.info&&(r.info=t.info,i.info=t.info),void 0!==t.selectOptions&&(r.selectOptions=t.selectOptions,i.selectOptions=t.selectOptions)}),c[t]=u,a.set(e,c)},s=0,o=Object.entries(null!=t?t:{});s<o.length;s++){var c=o[s];n(c[0],c[1])}},u=0,h=s,E.label=1;case 1:if(!(u<h.length))return[3,6];d=h[u],E.label=2;case 2:return E.trys.push([2,4,,5]),p=y("bulk row hook"),[4,d(e,r)];case 3:for(g=E.sent(),w(p),f=0,m=g;f<m.length;f++)v=m[f],c(v.index,v.row);return[3,5];case 4:return C=E.sent(),o(C,"bulk row hooks"),[3,5];case 5:return u++,[3,1];case 6:return[4,Promise.all(e.map(function(e){return t(void 0,void 0,void 0,function(){var t,s,a,l,u,h;return i(this,function(i){switch(i.label){case 0:t=0,s=n,i.label=1;case 1:if(!(t<s.length))return[3,6];a=s[t],i.label=2;case 2:return i.trys.push([2,4,,5]),l=y("row hook"),[4,a(e,r)];case 3:return u=i.sent(),w(l),c(e.index,u.row),[3,5];case 4:return h=i.sent(),o(h,"row hooks"),[3,5];case 5:return t++,[3,1];case 6:return[2]}})})}))];case 7:return E.sent(),S=[],a.forEach(function(e,t){S.push({index:t,row:e})}),[2,S]}})})},A=function(e,r,n){return t(void 0,void 0,void 0,function(){return i(this,function(s){return[2,Promise.all(e.map(function(e){return t(void 0,void 0,void 0,function(){return i(this,function(s){return r.forEach(function(r){return t(void 0,void 0,void 0,function(){var t,s;return i(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),t=y("row delete hook"),[4,r(e)];case 1:return i.sent(),w(t),[3,3];case 2:return s=i.sent(),n(s,"row delete hooks"),[3,3];case 3:return[2]}})})}),[2]})})}))]})})},T=function(e,r,n,s,o){return t(void 0,void 0,void 0,function(){return i(this,function(a){switch(a.label){case 0:return[4,Promise.all(n.map(function(n){return t(void 0,void 0,void 0,function(){var t;return i(this,function(i){switch(i.label){case 0:if(e!==n.type)return[2,Promise.resolve()];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,n.callback(s,r)];case 2:return[2,i.sent()];case 3:return t=i.sent(),o(t,"step hook ".concat(e)),[2,Promise.resolve()];case 4:return[2]}})})}))];case 1:return a.sent(),[2]}})})},M=function(e,r,n,s,o){return t(void 0,void 0,void 0,function(){var t;return i(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,n(e,r,s)];case 1:return[2,i.sent()];case 2:return t=i.sent(),o(t,"before finish callback"),[3,3];case 3:return[2]}})})},R=function(e,r,n,s){return t(void 0,void 0,void 0,function(){var t;return i(this,function(i){switch(i.label){case 0:return i.trys.push([0,2,,3]),[4,s(e,r)];case 1:return[2,i.sent()];case 2:return t=i.sent(),n(t,"custom file parser callback"),[3,3];case 3:return[2]}})})},_="dromo-container",P=function(t){var i=e({},t);return i.validators&&(i.validators=i.validators.map(function(t){return("regex_match"===t.validate||"regex_exclude"===t.validate)&&t.regex instanceof RegExp?e(e({},t),{regex:t.regex.source,regexOptions:{ignoreCase:t.regex.flags.includes("i"),dotAll:t.regex.flags.includes("s"),multiline:t.regex.flags.includes("m"),unicode:t.regex.flags.includes("u")}}):t})),i};return function(){function r(r,n,s,o){var a=this;this.embedInline=!1,this.columnHooks=[],this.bulkRowHooks=[],this.rowHooks=[],this.stepHooks=[],this.rowDeleteHooks=[],this.fileParsers=[],this.initChild=function(){return t(a,void 0,void 0,function(){var t,r,n,s,o;return i(this,function(i){switch(i.label){case 0:return this.connection?[4,this.connection.promise]:(console.error("shim cannot connect with Dromo service."),alert("There was en error opening the importer. Please contact support if this issue persists."),[2]);case 1:return t=i.sent(),r=Array.from(document.getElementsByTagName("script")).some(function(e){return"https://unpkg.com/dromo-uploader-js/dist/DromoUploader.js"===e.src||"https://cdn.jsdelivr.net/npm/dromo-uploader-js@latest/dist/DromoUploader.js"===e.src}),[4,t.setNumRegisteredRowHooks(this.totalNumRowHooks())];case 2:return i.sent(),[4,t.setNumRegisteredColHooks(this.columnHooks.length)];case 3:return i.sent(),[4,t.setNumRegisteredRowDeleteHooks(this.rowDeleteHooks.length)];case 4:return i.sent(),[4,t.setCustomParserFileExtensions(this.fileParsers.flatMap(function(e){return e.extensions.map(function(e){return e.toLowerCase()})}))];case 5:return i.sent(),[4,t.setEmbedInline(this.embedInline)];case 6:return i.sent(),this.fields&&this.settings&&this.user?(n=e({},this.settings),r||(n.version=null!==(s=n.version)&&void 0!==s?s:"v2"),n.browserExcelParsing=null===(o=n.browserExcelParsing)||void 0===o||o,[4,t.init(this.licenseKey,this.fields,n,this.user,this.appHost)]):[3,8];case 7:return i.sent(),[3,11];case 8:return this.schemaId?[4,t.initFromSavedSchema(this.licenseKey,this.schemaId,this.appHost,{user:this.user,developmentMode:this.developmentMode,headerRowOverride:this.headerRowOverride})]:[3,10];case 9:return i.sent(),[3,11];case 10:console.error("Invalid Dromo configuration"),i.label=11;case 11:return[2]}})})},this.initIFrame=function(){var e,t,i,r,n;if(window.DROMO_WIDGET_OVERRIDE)n=window.DROMO_WIDGET_OVERRIDE;else if(null===(e=a.settings)||void 0===e?void 0:e.alternateDomain){var s=new URL(a.settings.alternateDomain);n=s.protocol+"//widget."+s.host}else n="v1"===(null===(t=a.settings)||void 0===t?void 0:t.version)?"https://widget-v1.dromo.io/":"https://widget.dromo.io/";if(!document.getElementById(a.iframeId)){var o=document.createElement("iframe"),l=null!==(r=null===(i=a.settings)||void 0===i?void 0:i.importIdentifier)&&void 0!==r?r:a.schemaId;o.title=l?"Dromo Importer: ".concat(l):"Dromo Importer",o.src=n,o.id=a.iframeId,o.style.height="100%",o.style.width="100%",o.style.border="0",o.crossorigin="anonymous",a.iframe=o}},this.createConnection=function(){var e=a,r=a.iframe;r?a.connection=v({iframe:r,methods:{handleColumnHooks:function(r,n){return t(this,void 0,void 0,function(){var t;return i(this,function(i){switch(i.label){case 0:return t=e.columnHooks.filter(function(e){return e.fieldName===r}),[4,S(t,n,C)];case 1:return[2,i.sent()]}})})},handleRowHooks:function(r,n){return t(this,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return[4,E(r,n,e.rowHooks.map(function(e){return e.callback}),e.bulkRowHooks,C)];case 1:return[2,t.sent()]}})})},handleStepHook:function(r,n){return t(this,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return[4,T(r,n,e.stepHooks,e,C)];case 1:return[2,t.sent()]}})})},handleParseFileCallback:function(r,n){return t(this,void 0,void 0,function(){var t,s;return i(this,function(i){switch(i.label){case 0:return t=n.split(".").pop(),s=e.fileParsers.find(function(e){return-1!==e.extensions.map(function(e){return e.toLowerCase()}).indexOf(t.toLowerCase())}),[4,R(r,n,C,s.parseFile)];case 1:return[2,i.sent()]}})})},handleRowDeleteHooks:function(r){return t(this,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return[4,A(r,e.rowDeleteHooks,C)];case 1:return t.sent(),[2]}})})},handleBeforeFinishCallback:function(r,n){return t(this,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return e.beforeFinishCallback?[4,M(r,n,e.beforeFinishCallback,e,C)]:[3,2];case 1:return[2,t.sent()];case 2:return[2]}})})},handleResults:function(r,n){return t(this,void 0,void 0,function(){var t;return i(this,function(i){switch(i.label){case 0:if(!e.resultsCallback)return[3,4];i.label=1;case 1:return i.trys.push([1,3,,4]),[4,e.resultsCallback(r,n)];case 2:return i.sent(),[3,4];case 3:return t=i.sent(),console.error("[Dromo-External-Error] There was an error in your onResult callback.",t),[3,4];case 4:return e.close(),[2]}})})},handleCloseModal:function(){e.close()},handleCancel:function(){if(e.cancelCallback)try{e.cancelCallback()}catch(e){console.error("[Dromo-External-Error] There was an error in your cancel callback.",e)}e.close()}}}):console.error("shim cannot connect to Dromo.")},this.mountIFrame=function(){if(!document.getElementById(a.iframeId)){var e=document.createElement("div");e.id=a.wrapperId,e.style.zIndex=Number.MAX_SAFE_INTEGER.toString(),e.style.visibility="hidden",e.style.width="0px",e.style.height="0px",e.style.position="fixed",e.style.top="0px",e.style.left="0px",e.style.right="0px",e.style.bottom="0px",e.appendChild(a.iframe),document.body.appendChild(e),a.wrapper=e}},this.addIFrameToWrapper=function(){a.wrapper&&a.iframe&&(a.iframe.style.visibility="hidden",a.wrapper.appendChild(a.iframe))},this.showIframe=function(){a.iframe&&(a.iframe.style.visibility="visible")},this.showWrapper=function(){a.wrapper&&(a.wrapper.style.visibility="visible",a.wrapper.style.width="100%",a.wrapper.style.height="100%",document.body.style.overflow="hidden")},this.registerColumnHook=function(e,t){a.columnHooks.push({fieldName:e,callback:t}),a.connection&&a.connection.promise.then(function(e){e.setNumRegisteredColHooks(a.columnHooks.length)})},this.totalNumRowHooks=function(){return a.rowHooks.length+a.bulkRowHooks.length},this.registerBulkRowHook=function(e){a.bulkRowHooks.push(e),a.connection&&a.connection.promise.then(function(e){e.setNumRegisteredRowHooks(a.totalNumRowHooks())})},this.registerRowHook=function(e){a.rowHooks.push({callback:e}),a.connection&&a.connection.promise.then(function(e){e.setNumRegisteredRowHooks(a.totalNumRowHooks())})},this.registerStepHook=function(e,t){a.stepHooks.push({type:e,callback:t})},this.registerRowDeleteHook=function(e){a.rowDeleteHooks.push(e),a.connection&&a.connection.promise.then(function(e){e.setNumRegisteredRowDeleteHooks(a.rowDeleteHooks.length)})},this.beforeFinish=function(e){a.beforeFinishCallback=e},this.registerFileParser=function(e){a.fileParsers.push(e),a.connection&&a.connection.promise.then(function(e){e.setCustomParserFileExtensions(a.fileParsers.flatMap(function(e){return e.extensions.map(function(e){return e.toLowerCase()})}))})},this.registerAllHooks=function(e){if(e.columnHooks)for(var t=0,i=e.columnHooks;t<i.length;t++){var r=i[t],n=r.fieldName,s=r.callback;a.registerColumnHook(n,s)}if(e.rowHooks)for(var o=0,l=e.rowHooks;o<l.length;o++){var c=l[o];a.registerRowHook(c)}if(e.bulkRowHooks)for(var u=0,h=e.bulkRowHooks;u<h.length;u++){var d=h[u];a.registerBulkRowHook(d)}if(e.rowDeleteHooks)for(var p=0,g=e.rowDeleteHooks;p<g.length;p++){var f=g[p];a.registerRowDeleteHook(f)}if(e.stepHooks)for(var m=0,v=e.stepHooks;m<v.length;m++){var C=v[m],y=C.type;s=C.callback,a.registerStepHook(y,s)}if(e.beforeFinishCallback&&a.beforeFinish(e.beforeFinishCallback),e.fileParsers)for(var w=0,S=e.fileParsers;w<S.length;w++){var b=S[w];a.registerFileParser(b)}},this.onResults=function(e){a.resultsCallback=e},this.onCancel=function(e){a.cancelCallback=e},this.setUser=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.user=e,this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().setUser(this.user)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},this.addField=function(e,r){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().addField(P(e),r)];case 2:return t.sent(),[3,4];case 3:console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),t.label=4;case 4:return[2]}})})},this.removeField=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().removeField(e)];case 2:return t.sent(),[3,4];case 3:console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),t.label=4;case 4:return[2]}})})},this.updateInfoMessages=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().updateInfoMessages(e)];case 2:return t.sent(),[3,4];case 3:console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),t.label=4;case 4:return[2]}})})},this.setHeaderRowOverride=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.headerRowOverride=e,this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().setHeaderRowOverride(e)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},this.setConfirmationMessage=function(e,r){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().setConfirmationMessage(e,r)];case 2:return t.sent(),[3,4];case 3:console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),t.label=4;case 4:return[2]}})})},this.open=function(){return t(a,void 0,void 0,function(){return i(this,function(e){switch(e.label){case 0:return this.wrapper||(this.initIFrame(),this.createConnection(),this.mountIFrame()),[4,this.initChild()];case 1:return e.sent(),this.showWrapper(),[2]}})})},this.initInline=function(e){return t(a,void 0,void 0,function(){var t,r;return i(this,function(i){switch(i.label){case 0:this.embedInline=!0,i.label=1;case 1:if(i.trys.push([1,3,,4]),e instanceof HTMLElement&&(this.wrapper=e,this.wrapperId=e.id,""!==this.wrapperId&&void 0!==this.wrapperId||(this.wrapperId=Math.random().toString(36).substring(7)+"-"+_)),"string"==typeof e){if(null===(t=document.getElementById(e)))throw new Error("WRAPPER_NOT_FOUND");this.wrapper=t,this.wrapperId=e}return this.iframe||(this.initIFrame(),this.createConnection(),this.addIFrameToWrapper()),[4,this.initChild()];case 2:return i.sent(),this.showIframe(),[3,4];case 3:throw"WRAPPER_NOT_FOUND"===(r=i.sent()).message&&console.error("[Dromo-Error] Could not find wrapper using provided ID."),r;case 4:return[2]}})})},this.addRows=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().addRows(e)];case 2:return[2,t.sent()];case 3:return console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),[2,[]]}})})},this.removeRows=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().removeRows(e)];case 2:return t.sent(),[3,4];case 3:console.error("[Dromo-Error] Invalid connection to Dromo Uploader."),t.label=4;case 4:return[2]}})})},this.close=function(){a.wrapper&&(a.wrapper.style.visibility="hidden",a.wrapper.style.width="0px",a.wrapper.style.height="0px",document.body.style.overflow="inherit")},this.setDevelopmentMode=function(e){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.developmentMode=e,this.connection?[4,this.connection.promise]:[3,3];case 1:return[4,t.sent().setDevelopmentMode(this.developmentMode)];case 2:t.sent(),t.label=3;case 3:return[2]}})})},this.rehydrate=function(e,r){return t(a,void 0,void 0,function(){return i(this,function(t){switch(t.label){case 0:return this.wrapper||(this.initIFrame(),this.createConnection(),this.mountIFrame()),[4,this.initChild()];case 1:return t.sent(),[4,this.connection.promise];case 2:return[4,t.sent().rehydrate(e,r)];case 3:return t.sent(),this.showWrapper(),[2]}})})},this.iframeId=Math.random().toString(36).substring(7)+"-dromo-iframe-element",this.wrapperId=Math.random().toString(36).substring(7)+"-"+_,this.appHost=document.location.hostname,void 0!==s&&void 0!==o?(this.licenseKey=r,this.fields=n.map(P),this.settings=s,this.user=o,this.checkCloneable({licenseKey:this.licenseKey,fields:this.fields,settings:this.settings,user:this.user})):(this.licenseKey=r,this.schemaId=n,this.checkCloneable({licenseKey:this.licenseKey,schemaId:this.schemaId}))}var n;return r.prototype.checkCloneable=function(e){if("function"==typeof structuredClone){var t=Object.entries(e).filter(function(e){e[0];var t=e[1];try{return structuredClone(t),!1}catch(e){return!0}}).map(function(e){return e[0]});if(t.length>0){var i=t.join(", ");throw new Error("[Dromo-External-Error] The Dromo importer received non-cloneable parameters: ".concat(i,". See https://dromo.dev/err/clone"))}}},n=r,r.rehydrateHeadless=function(e){var s=e.licenseKey,o=e.headlessImportId,a=e.fields,l=e.settings,c=e.hooks,u=e.rehydrateState;return t(void 0,void 0,void 0,function(){var e;return i(n,function(t){switch(t.label){case 0:return(e=new r(s,a,l,{id:"headless-review"})).registerAllHooks(c),[4,e.rehydrate(u,o)];case 1:return t.sent(),e.open(),[2,e]}})})},r}()}()},73964(e,t,i){"use strict";i.d(t,{A:()=>o});var r=i(22155),n=i(53692),s=i.n(n);const o=function(e){var t,i;function n(t){var i;return(i=e.call(this,t)||this).inlineRef=null,i.init=function(){if("fields"in i.props&&"settings"in i.props)i.dromo=new(s())(i.props.licenseKey,i.props.fields,i.props.settings,i.props.user);else if("schemaId"in i.props||"schemaName"in i.props){var e="schemaId"in i.props?i.props.schemaId:i.props.schemaName;i.dromo=new(s())(i.props.licenseKey,e),"developmentMode"in i.props&&i.dromo.setDevelopmentMode(i.props.developmentMode),"user"in i.props&&i.dromo.setUser(i.props.user),"headerRowOverride"in i.props&&i.dromo.setHeaderRowOverride(i.props.headerRowOverride)}i.props.rowHooks&&i.props.rowHooks.forEach(function(e){return i.dromo.registerRowHook(e)}),i.props.bulkRowHooks&&i.props.bulkRowHooks.forEach(function(e){return i.dromo.registerBulkRowHook(e)}),i.props.columnHooks&&i.props.columnHooks.forEach(function(e){i.dromo.registerColumnHook(e.fieldName,e.callback)}),i.props.rowDeleteHooks&&i.props.rowDeleteHooks.forEach(function(e){return i.dromo.registerRowDeleteHook(e)}),i.props.beforeFinish&&i.dromo.beforeFinish(i.props.beforeFinish),i.props.onResults&&i.dromo.onResults(i.props.onResults),i.props.onCancel&&i.dromo.onCancel(i.props.onCancel),i.props.stepHooks&&i.props.stepHooks.forEach(function(e){i.dromo.registerStepHook(e.type,e.callback)}),i.props.fileParsers&&i.props.fileParsers.forEach(function(e){i.dromo.registerFileParser(e)})},i.open=function(){i.init(),i.dromo.open()},i.initInline=function(){i.inlineRef&&(i.init(),i.dromo.initInline(i.inlineRef.current))},t.inline&&(i.inlineRef=(0,r.createRef)()),i}i=e,(t=n).prototype=Object.create(i.prototype),t.prototype.constructor=t,t.__proto__=i;var o=n.prototype;return o.componentDidMount=function(){this.props.inline&&this.inlineRef?this.initInline():this.props.open&&this.open()},o.componentDidUpdate=function(e){this.props.inline?this.initInline():(!e.open&&this.props.open&&this.open(),e.open&&!this.props.open&&this.dromo.close())},o.componentWillUnmount=function(){this.props.open&&!this.props.inline&&this.dromo.close()},o.render=function(){return this.props.inline?(0,r.createElement)("div",{ref:this.inlineRef,className:this.props.className,style:this.props.style}):void 0===this.props.children?(0,r.createElement)(r.Fragment,null):(0,r.createElement)("button",{style:this.props.style,className:this.props.className,onClick:this.open},this.props.children)},n}(r.Component)},57678(e,t,i){"use strict";var r,n=i(92427),s=i(25667);try{r=[].__proto__===Array.prototype}catch(e){if(!e||"object"!=typeof e||!("code"in e)||"ERR_PROTO_ACCESS"!==e.code)throw e}var o=!!r&&s&&s(Object.prototype,"__proto__"),a=Object,l=a.getPrototypeOf;e.exports=o&&"function"==typeof o.get?n([o.get]):"function"==typeof l&&function(e){return l(null==e?e:a(e))}},23071(e,t,i){"use strict";var r=t;r.version=i(23718).rE,r.utils=i(9185),r.rand=i(65442),r.curve=i(95228),r.curves=i(25366),r.ec=i(72961),r.eddsa=i(87808)},94499(e,t,i){"use strict";var r=i(5630),n=i(9185),s=n.getNAF,o=n.getJSF,a=n.assert;function l(e,t){this.type=e,this.p=new r(t.p,16),this.red=t.prime?r.red(t.prime):r.mont(this.p),this.zero=new r(0).toRed(this.red),this.one=new r(1).toRed(this.red),this.two=new r(2).toRed(this.red),this.n=t.n&&new r(t.n,16),this.g=t.g&&this.pointFromJSON(t.g,t.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var i=this.n&&this.p.div(this.n);!i||i.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function c(e,t){this.curve=e,this.type=t,this.precomputed=null}e.exports=l,l.prototype.point=function(){throw new Error("Not implemented")},l.prototype.validate=function(){throw new Error("Not implemented")},l.prototype._fixedNafMul=function(e,t){a(e.precomputed);var i=e._getDoubles(),r=s(t,1,this._bitLength),n=(1<<i.step+1)-(i.step%2==0?2:1);n/=3;var o,l,c=[];for(o=0;o<r.length;o+=i.step){l=0;for(var u=o+i.step-1;u>=o;u--)l=(l<<1)+r[u];c.push(l)}for(var h=this.jpoint(null,null,null),d=this.jpoint(null,null,null),p=n;p>0;p--){for(o=0;o<c.length;o++)(l=c[o])===p?d=d.mixedAdd(i.points[o]):l===-p&&(d=d.mixedAdd(i.points[o].neg()));h=h.add(d)}return h.toP()},l.prototype._wnafMul=function(e,t){var i=4,r=e._getNAFPoints(i);i=r.wnd;for(var n=r.points,o=s(t,i,this._bitLength),l=this.jpoint(null,null,null),c=o.length-1;c>=0;c--){for(var u=0;c>=0&&0===o[c];c--)u++;if(c>=0&&u++,l=l.dblp(u),c<0)break;var h=o[c];a(0!==h),l="affine"===e.type?h>0?l.mixedAdd(n[h-1>>1]):l.mixedAdd(n[-h-1>>1].neg()):h>0?l.add(n[h-1>>1]):l.add(n[-h-1>>1].neg())}return"affine"===e.type?l.toP():l},l.prototype._wnafMulAdd=function(e,t,i,r,n){var a,l,c,u=this._wnafT1,h=this._wnafT2,d=this._wnafT3,p=0;for(a=0;a<r;a++){var g=(c=t[a])._getNAFPoints(e);u[a]=g.wnd,h[a]=g.points}for(a=r-1;a>=1;a-=2){var f=a-1,m=a;if(1===u[f]&&1===u[m]){var v=[t[f],null,null,t[m]];0===t[f].y.cmp(t[m].y)?(v[1]=t[f].add(t[m]),v[2]=t[f].toJ().mixedAdd(t[m].neg())):0===t[f].y.cmp(t[m].y.redNeg())?(v[1]=t[f].toJ().mixedAdd(t[m]),v[2]=t[f].add(t[m].neg())):(v[1]=t[f].toJ().mixedAdd(t[m]),v[2]=t[f].toJ().mixedAdd(t[m].neg()));var C=[-3,-1,-5,-7,0,7,5,1,3],y=o(i[f],i[m]);for(p=Math.max(y[0].length,p),d[f]=new Array(p),d[m]=new Array(p),l=0;l<p;l++){var w=0|y[0][l],S=0|y[1][l];d[f][l]=C[3*(w+1)+(S+1)],d[m][l]=0,h[f]=v}}else d[f]=s(i[f],u[f],this._bitLength),d[m]=s(i[m],u[m],this._bitLength),p=Math.max(d[f].length,p),p=Math.max(d[m].length,p)}var b=this.jpoint(null,null,null),E=this._wnafT4;for(a=p;a>=0;a--){for(var A=0;a>=0;){var T=!0;for(l=0;l<r;l++)E[l]=0|d[l][a],0!==E[l]&&(T=!1);if(!T)break;A++,a--}if(a>=0&&A++,b=b.dblp(A),a<0)break;for(l=0;l<r;l++){var M=E[l];0!==M&&(M>0?c=h[l][M-1>>1]:M<0&&(c=h[l][-M-1>>1].neg()),b="affine"===c.type?b.mixedAdd(c):b.add(c))}}for(a=0;a<r;a++)h[a]=null;return n?b:b.toP()},l.BasePoint=c,c.prototype.eq=function(){throw new Error("Not implemented")},c.prototype.validate=function(){return this.curve.validate(this)},l.prototype.decodePoint=function(e,t){e=n.toArray(e,t);var i=this.p.byteLength();if((4===e[0]||6===e[0]||7===e[0])&&e.length-1==2*i)return 6===e[0]?a(e[e.length-1]%2==0):7===e[0]&&a(e[e.length-1]%2==1),this.point(e.slice(1,1+i),e.slice(1+i,1+2*i));if((2===e[0]||3===e[0])&&e.length-1===i)return this.pointFromX(e.slice(1,1+i),3===e[0]);throw new Error("Unknown point format")},c.prototype.encodeCompressed=function(e){return this.encode(e,!0)},c.prototype._encode=function(e){var t=this.curve.p.byteLength(),i=this.getX().toArray("be",t);return e?[this.getY().isEven()?2:3].concat(i):[4].concat(i,this.getY().toArray("be",t))},c.prototype.encode=function(e,t){return n.encode(this._encode(t),e)},c.prototype.precompute=function(e){if(this.precomputed)return this;var t={doubles:null,naf:null,beta:null};return t.naf=this._getNAFPoints(8),t.doubles=this._getDoubles(4,e),t.beta=this._getBeta(),this.precomputed=t,this},c.prototype._hasDoubles=function(e){if(!this.precomputed)return!1;var t=this.precomputed.doubles;return!!t&&t.points.length>=Math.ceil((e.bitLength()+1)/t.step)},c.prototype._getDoubles=function(e,t){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var i=[this],r=this,n=0;n<t;n+=e){for(var s=0;s<e;s++)r=r.dbl();i.push(r)}return{step:e,points:i}},c.prototype._getNAFPoints=function(e){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var t=[this],i=(1<<e)-1,r=1===i?null:this.dbl(),n=1;n<i;n++)t[n]=t[n-1].add(r);return{wnd:e,points:t}},c.prototype._getBeta=function(){return null},c.prototype.dblp=function(e){for(var t=this,i=0;i<e;i++)t=t.dbl();return t}},83544(e,t,i){"use strict";var r=i(9185),n=i(5630),s=i(91193),o=i(94499),a=r.assert;function l(e){this.twisted=1!=(0|e.a),this.mOneA=this.twisted&&-1==(0|e.a),this.extended=this.mOneA,o.call(this,"edwards",e),this.a=new n(e.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new n(e.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new n(e.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),a(!this.twisted||0===this.c.fromRed().cmpn(1)),this.oneC=1==(0|e.c)}function c(e,t,i,r,s){o.BasePoint.call(this,e,"projective"),null===t&&null===i&&null===r?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new n(t,16),this.y=new n(i,16),this.z=r?new n(r,16):this.curve.one,this.t=s&&new n(s,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}s(l,o),e.exports=l,l.prototype._mulA=function(e){return this.mOneA?e.redNeg():this.a.redMul(e)},l.prototype._mulC=function(e){return this.oneC?e:this.c.redMul(e)},l.prototype.jpoint=function(e,t,i,r){return this.point(e,t,i,r)},l.prototype.pointFromX=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var i=e.redSqr(),r=this.c2.redSub(this.a.redMul(i)),s=this.one.redSub(this.c2.redMul(this.d).redMul(i)),o=r.redMul(s.redInvm()),a=o.redSqrt();if(0!==a.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");var l=a.fromRed().isOdd();return(t&&!l||!t&&l)&&(a=a.redNeg()),this.point(e,a)},l.prototype.pointFromY=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var i=e.redSqr(),r=i.redSub(this.c2),s=i.redMul(this.d).redMul(this.c2).redSub(this.a),o=r.redMul(s.redInvm());if(0===o.cmp(this.zero)){if(t)throw new Error("invalid point");return this.point(this.zero,e)}var a=o.redSqrt();if(0!==a.redSqr().redSub(o).cmp(this.zero))throw new Error("invalid point");return a.fromRed().isOdd()!==t&&(a=a.redNeg()),this.point(a,e)},l.prototype.validate=function(e){if(e.isInfinity())return!0;e.normalize();var t=e.x.redSqr(),i=e.y.redSqr(),r=t.redMul(this.a).redAdd(i),n=this.c2.redMul(this.one.redAdd(this.d.redMul(t).redMul(i)));return 0===r.cmp(n)},s(c,o.BasePoint),l.prototype.pointFromJSON=function(e){return c.fromJSON(this,e)},l.prototype.point=function(e,t,i,r){return new c(this,e,t,i,r)},c.fromJSON=function(e,t){return new c(e,t[0],t[1],t[2])},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},c.prototype._extDbl=function(){var e=this.x.redSqr(),t=this.y.redSqr(),i=this.z.redSqr();i=i.redIAdd(i);var r=this.curve._mulA(e),n=this.x.redAdd(this.y).redSqr().redISub(e).redISub(t),s=r.redAdd(t),o=s.redSub(i),a=r.redSub(t),l=n.redMul(o),c=s.redMul(a),u=n.redMul(a),h=o.redMul(s);return this.curve.point(l,c,h,u)},c.prototype._projDbl=function(){var e,t,i,r,n,s,o=this.x.redAdd(this.y).redSqr(),a=this.x.redSqr(),l=this.y.redSqr();if(this.curve.twisted){var c=(r=this.curve._mulA(a)).redAdd(l);this.zOne?(e=o.redSub(a).redSub(l).redMul(c.redSub(this.curve.two)),t=c.redMul(r.redSub(l)),i=c.redSqr().redSub(c).redSub(c)):(n=this.z.redSqr(),s=c.redSub(n).redISub(n),e=o.redSub(a).redISub(l).redMul(s),t=c.redMul(r.redSub(l)),i=c.redMul(s))}else r=a.redAdd(l),n=this.curve._mulC(this.z).redSqr(),s=r.redSub(n).redSub(n),e=this.curve._mulC(o.redISub(r)).redMul(s),t=this.curve._mulC(r).redMul(a.redISub(l)),i=r.redMul(s);return this.curve.point(e,t,i)},c.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},c.prototype._extAdd=function(e){var t=this.y.redSub(this.x).redMul(e.y.redSub(e.x)),i=this.y.redAdd(this.x).redMul(e.y.redAdd(e.x)),r=this.t.redMul(this.curve.dd).redMul(e.t),n=this.z.redMul(e.z.redAdd(e.z)),s=i.redSub(t),o=n.redSub(r),a=n.redAdd(r),l=i.redAdd(t),c=s.redMul(o),u=a.redMul(l),h=s.redMul(l),d=o.redMul(a);return this.curve.point(c,u,d,h)},c.prototype._projAdd=function(e){var t,i,r=this.z.redMul(e.z),n=r.redSqr(),s=this.x.redMul(e.x),o=this.y.redMul(e.y),a=this.curve.d.redMul(s).redMul(o),l=n.redSub(a),c=n.redAdd(a),u=this.x.redAdd(this.y).redMul(e.x.redAdd(e.y)).redISub(s).redISub(o),h=r.redMul(l).redMul(u);return this.curve.twisted?(t=r.redMul(c).redMul(o.redSub(this.curve._mulA(s))),i=l.redMul(c)):(t=r.redMul(c).redMul(o.redSub(s)),i=this.curve._mulC(l).redMul(c)),this.curve.point(h,t,i)},c.prototype.add=function(e){return this.isInfinity()?e:e.isInfinity()?this:this.curve.extended?this._extAdd(e):this._projAdd(e)},c.prototype.mul=function(e){return this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,i){return this.curve._wnafMulAdd(1,[this,t],[e,i],2,!1)},c.prototype.jmulAdd=function(e,t,i){return this.curve._wnafMulAdd(1,[this,t],[e,i],2,!0)},c.prototype.normalize=function(){if(this.zOne)return this;var e=this.z.redInvm();return this.x=this.x.redMul(e),this.y=this.y.redMul(e),this.t&&(this.t=this.t.redMul(e)),this.z=this.curve.one,this.zOne=!0,this},c.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},c.prototype.getX=function(){return this.normalize(),this.x.fromRed()},c.prototype.getY=function(){return this.normalize(),this.y.fromRed()},c.prototype.eq=function(e){return this===e||0===this.getX().cmp(e.getX())&&0===this.getY().cmp(e.getY())},c.prototype.eqXToP=function(e){var t=e.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(t))return!0;for(var i=e.clone(),r=this.curve.redN.redMul(this.z);;){if(i.iadd(this.curve.n),i.cmp(this.curve.p)>=0)return!1;if(t.redIAdd(r),0===this.x.cmp(t))return!0}},c.prototype.toP=c.prototype.normalize,c.prototype.mixedAdd=c.prototype.add},95228(e,t,i){"use strict";var r=t;r.base=i(94499),r.short=i(53970),r.mont=i(50536),r.edwards=i(83544)},50536(e,t,i){"use strict";var r=i(5630),n=i(91193),s=i(94499),o=i(9185);function a(e){s.call(this,"mont",e),this.a=new r(e.a,16).toRed(this.red),this.b=new r(e.b,16).toRed(this.red),this.i4=new r(4).toRed(this.red).redInvm(),this.two=new r(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function l(e,t,i){s.BasePoint.call(this,e,"projective"),null===t&&null===i?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new r(t,16),this.z=new r(i,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}n(a,s),e.exports=a,a.prototype.validate=function(e){var t=e.normalize().x,i=t.redSqr(),r=i.redMul(t).redAdd(i.redMul(this.a)).redAdd(t);return 0===r.redSqrt().redSqr().cmp(r)},n(l,s.BasePoint),a.prototype.decodePoint=function(e,t){return this.point(o.toArray(e,t),1)},a.prototype.point=function(e,t){return new l(this,e,t)},a.prototype.pointFromJSON=function(e){return l.fromJSON(this,e)},l.prototype.precompute=function(){},l.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},l.fromJSON=function(e,t){return new l(e,t[0],t[1]||e.one)},l.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},l.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},l.prototype.dbl=function(){var e=this.x.redAdd(this.z).redSqr(),t=this.x.redSub(this.z).redSqr(),i=e.redSub(t),r=e.redMul(t),n=i.redMul(t.redAdd(this.curve.a24.redMul(i)));return this.curve.point(r,n)},l.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.diffAdd=function(e,t){var i=this.x.redAdd(this.z),r=this.x.redSub(this.z),n=e.x.redAdd(e.z),s=e.x.redSub(e.z).redMul(i),o=n.redMul(r),a=t.z.redMul(s.redAdd(o).redSqr()),l=t.x.redMul(s.redISub(o).redSqr());return this.curve.point(a,l)},l.prototype.mul=function(e){for(var t=e.clone(),i=this,r=this.curve.point(null,null),n=[];0!==t.cmpn(0);t.iushrn(1))n.push(t.andln(1));for(var s=n.length-1;s>=0;s--)0===n[s]?(i=i.diffAdd(r,this),r=r.dbl()):(r=i.diffAdd(r,this),i=i.dbl());return r},l.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},l.prototype.eq=function(e){return 0===this.getX().cmp(e.getX())},l.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},l.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},53970(e,t,i){"use strict";var r=i(9185),n=i(5630),s=i(91193),o=i(94499),a=r.assert;function l(e){o.call(this,"short",e),this.a=new n(e.a,16).toRed(this.red),this.b=new n(e.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(e),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}function c(e,t,i,r){o.BasePoint.call(this,e,"affine"),null===t&&null===i?(this.x=null,this.y=null,this.inf=!0):(this.x=new n(t,16),this.y=new n(i,16),r&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function u(e,t,i,r){o.BasePoint.call(this,e,"jacobian"),null===t&&null===i&&null===r?(this.x=this.curve.one,this.y=this.curve.one,this.z=new n(0)):(this.x=new n(t,16),this.y=new n(i,16),this.z=new n(r,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}s(l,o),e.exports=l,l.prototype._getEndomorphism=function(e){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){var t,i;if(e.beta)t=new n(e.beta,16).toRed(this.red);else{var r=this._getEndoRoots(this.p);t=(t=r[0].cmp(r[1])<0?r[0]:r[1]).toRed(this.red)}if(e.lambda)i=new n(e.lambda,16);else{var s=this._getEndoRoots(this.n);0===this.g.mul(s[0]).x.cmp(this.g.x.redMul(t))?i=s[0]:(i=s[1],a(0===this.g.mul(i).x.cmp(this.g.x.redMul(t))))}return{beta:t,lambda:i,basis:e.basis?e.basis.map(function(e){return{a:new n(e.a,16),b:new n(e.b,16)}}):this._getEndoBasis(i)}}},l.prototype._getEndoRoots=function(e){var t=e===this.p?this.red:n.mont(e),i=new n(2).toRed(t).redInvm(),r=i.redNeg(),s=new n(3).toRed(t).redNeg().redSqrt().redMul(i);return[r.redAdd(s).fromRed(),r.redSub(s).fromRed()]},l.prototype._getEndoBasis=function(e){for(var t,i,r,s,o,a,l,c,u,h=this.n.ushrn(Math.floor(this.n.bitLength()/2)),d=e,p=this.n.clone(),g=new n(1),f=new n(0),m=new n(0),v=new n(1),C=0;0!==d.cmpn(0);){var y=p.div(d);c=p.sub(y.mul(d)),u=m.sub(y.mul(g));var w=v.sub(y.mul(f));if(!r&&c.cmp(h)<0)t=l.neg(),i=g,r=c.neg(),s=u;else if(r&&2===++C)break;l=c,p=d,d=c,m=g,g=u,v=f,f=w}o=c.neg(),a=u;var S=r.sqr().add(s.sqr());return o.sqr().add(a.sqr()).cmp(S)>=0&&(o=t,a=i),r.negative&&(r=r.neg(),s=s.neg()),o.negative&&(o=o.neg(),a=a.neg()),[{a:r,b:s},{a:o,b:a}]},l.prototype._endoSplit=function(e){var t=this.endo.basis,i=t[0],r=t[1],n=r.b.mul(e).divRound(this.n),s=i.b.neg().mul(e).divRound(this.n),o=n.mul(i.a),a=s.mul(r.a),l=n.mul(i.b),c=s.mul(r.b);return{k1:e.sub(o).sub(a),k2:l.add(c).neg()}},l.prototype.pointFromX=function(e,t){(e=new n(e,16)).red||(e=e.toRed(this.red));var i=e.redSqr().redMul(e).redIAdd(e.redMul(this.a)).redIAdd(this.b),r=i.redSqrt();if(0!==r.redSqr().redSub(i).cmp(this.zero))throw new Error("invalid point");var s=r.fromRed().isOdd();return(t&&!s||!t&&s)&&(r=r.redNeg()),this.point(e,r)},l.prototype.validate=function(e){if(e.inf)return!0;var t=e.x,i=e.y,r=this.a.redMul(t),n=t.redSqr().redMul(t).redIAdd(r).redIAdd(this.b);return 0===i.redSqr().redISub(n).cmpn(0)},l.prototype._endoWnafMulAdd=function(e,t,i){for(var r=this._endoWnafT1,n=this._endoWnafT2,s=0;s<e.length;s++){var o=this._endoSplit(t[s]),a=e[s],l=a._getBeta();o.k1.negative&&(o.k1.ineg(),a=a.neg(!0)),o.k2.negative&&(o.k2.ineg(),l=l.neg(!0)),r[2*s]=a,r[2*s+1]=l,n[2*s]=o.k1,n[2*s+1]=o.k2}for(var c=this._wnafMulAdd(1,r,n,2*s,i),u=0;u<2*s;u++)r[u]=null,n[u]=null;return c},s(c,o.BasePoint),l.prototype.point=function(e,t,i){return new c(this,e,t,i)},l.prototype.pointFromJSON=function(e,t){return c.fromJSON(this,e,t)},c.prototype._getBeta=function(){if(this.curve.endo){var e=this.precomputed;if(e&&e.beta)return e.beta;var t=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(e){var i=this.curve,r=function(e){return i.point(e.x.redMul(i.endo.beta),e.y)};e.beta=t,t.precomputed={beta:null,naf:e.naf&&{wnd:e.naf.wnd,points:e.naf.points.map(r)},doubles:e.doubles&&{step:e.doubles.step,points:e.doubles.points.map(r)}}}return t}},c.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},c.fromJSON=function(e,t,i){"string"==typeof t&&(t=JSON.parse(t));var r=e.point(t[0],t[1],i);if(!t[2])return r;function n(t){return e.point(t[0],t[1],i)}var s=t[2];return r.precomputed={beta:null,doubles:s.doubles&&{step:s.doubles.step,points:[r].concat(s.doubles.points.map(n))},naf:s.naf&&{wnd:s.naf.wnd,points:[r].concat(s.naf.points.map(n))}},r},c.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},c.prototype.isInfinity=function(){return this.inf},c.prototype.add=function(e){if(this.inf)return e;if(e.inf)return this;if(this.eq(e))return this.dbl();if(this.neg().eq(e))return this.curve.point(null,null);if(0===this.x.cmp(e.x))return this.curve.point(null,null);var t=this.y.redSub(e.y);0!==t.cmpn(0)&&(t=t.redMul(this.x.redSub(e.x).redInvm()));var i=t.redSqr().redISub(this.x).redISub(e.x),r=t.redMul(this.x.redSub(i)).redISub(this.y);return this.curve.point(i,r)},c.prototype.dbl=function(){if(this.inf)return this;var e=this.y.redAdd(this.y);if(0===e.cmpn(0))return this.curve.point(null,null);var t=this.curve.a,i=this.x.redSqr(),r=e.redInvm(),n=i.redAdd(i).redIAdd(i).redIAdd(t).redMul(r),s=n.redSqr().redISub(this.x.redAdd(this.x)),o=n.redMul(this.x.redSub(s)).redISub(this.y);return this.curve.point(s,o)},c.prototype.getX=function(){return this.x.fromRed()},c.prototype.getY=function(){return this.y.fromRed()},c.prototype.mul=function(e){return e=new n(e,16),this.isInfinity()?this:this._hasDoubles(e)?this.curve._fixedNafMul(this,e):this.curve.endo?this.curve._endoWnafMulAdd([this],[e]):this.curve._wnafMul(this,e)},c.prototype.mulAdd=function(e,t,i){var r=[this,t],n=[e,i];return this.curve.endo?this.curve._endoWnafMulAdd(r,n):this.curve._wnafMulAdd(1,r,n,2)},c.prototype.jmulAdd=function(e,t,i){var r=[this,t],n=[e,i];return this.curve.endo?this.curve._endoWnafMulAdd(r,n,!0):this.curve._wnafMulAdd(1,r,n,2,!0)},c.prototype.eq=function(e){return this===e||this.inf===e.inf&&(this.inf||0===this.x.cmp(e.x)&&0===this.y.cmp(e.y))},c.prototype.neg=function(e){if(this.inf)return this;var t=this.curve.point(this.x,this.y.redNeg());if(e&&this.precomputed){var i=this.precomputed,r=function(e){return e.neg()};t.precomputed={naf:i.naf&&{wnd:i.naf.wnd,points:i.naf.points.map(r)},doubles:i.doubles&&{step:i.doubles.step,points:i.doubles.points.map(r)}}}return t},c.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},s(u,o.BasePoint),l.prototype.jpoint=function(e,t,i){return new u(this,e,t,i)},u.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var e=this.z.redInvm(),t=e.redSqr(),i=this.x.redMul(t),r=this.y.redMul(t).redMul(e);return this.curve.point(i,r)},u.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},u.prototype.add=function(e){if(this.isInfinity())return e;if(e.isInfinity())return this;var t=e.z.redSqr(),i=this.z.redSqr(),r=this.x.redMul(t),n=e.x.redMul(i),s=this.y.redMul(t.redMul(e.z)),o=e.y.redMul(i.redMul(this.z)),a=r.redSub(n),l=s.redSub(o);if(0===a.cmpn(0))return 0!==l.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var c=a.redSqr(),u=c.redMul(a),h=r.redMul(c),d=l.redSqr().redIAdd(u).redISub(h).redISub(h),p=l.redMul(h.redISub(d)).redISub(s.redMul(u)),g=this.z.redMul(e.z).redMul(a);return this.curve.jpoint(d,p,g)},u.prototype.mixedAdd=function(e){if(this.isInfinity())return e.toJ();if(e.isInfinity())return this;var t=this.z.redSqr(),i=this.x,r=e.x.redMul(t),n=this.y,s=e.y.redMul(t).redMul(this.z),o=i.redSub(r),a=n.redSub(s);if(0===o.cmpn(0))return 0!==a.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var l=o.redSqr(),c=l.redMul(o),u=i.redMul(l),h=a.redSqr().redIAdd(c).redISub(u).redISub(u),d=a.redMul(u.redISub(h)).redISub(n.redMul(c)),p=this.z.redMul(o);return this.curve.jpoint(h,d,p)},u.prototype.dblp=function(e){if(0===e)return this;if(this.isInfinity())return this;if(!e)return this.dbl();var t;if(this.curve.zeroA||this.curve.threeA){var i=this;for(t=0;t<e;t++)i=i.dbl();return i}var r=this.curve.a,n=this.curve.tinv,s=this.x,o=this.y,a=this.z,l=a.redSqr().redSqr(),c=o.redAdd(o);for(t=0;t<e;t++){var u=s.redSqr(),h=c.redSqr(),d=h.redSqr(),p=u.redAdd(u).redIAdd(u).redIAdd(r.redMul(l)),g=s.redMul(h),f=p.redSqr().redISub(g.redAdd(g)),m=g.redISub(f),v=p.redMul(m);v=v.redIAdd(v).redISub(d);var C=c.redMul(a);t+1<e&&(l=l.redMul(d)),s=f,a=C,c=v}return this.curve.jpoint(s,c.redMul(n),a)},u.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},u.prototype._zeroDbl=function(){var e,t,i;if(this.zOne){var r=this.x.redSqr(),n=this.y.redSqr(),s=n.redSqr(),o=this.x.redAdd(n).redSqr().redISub(r).redISub(s);o=o.redIAdd(o);var a=r.redAdd(r).redIAdd(r),l=a.redSqr().redISub(o).redISub(o),c=s.redIAdd(s);c=(c=c.redIAdd(c)).redIAdd(c),e=l,t=a.redMul(o.redISub(l)).redISub(c),i=this.y.redAdd(this.y)}else{var u=this.x.redSqr(),h=this.y.redSqr(),d=h.redSqr(),p=this.x.redAdd(h).redSqr().redISub(u).redISub(d);p=p.redIAdd(p);var g=u.redAdd(u).redIAdd(u),f=g.redSqr(),m=d.redIAdd(d);m=(m=m.redIAdd(m)).redIAdd(m),e=f.redISub(p).redISub(p),t=g.redMul(p.redISub(e)).redISub(m),i=(i=this.y.redMul(this.z)).redIAdd(i)}return this.curve.jpoint(e,t,i)},u.prototype._threeDbl=function(){var e,t,i;if(this.zOne){var r=this.x.redSqr(),n=this.y.redSqr(),s=n.redSqr(),o=this.x.redAdd(n).redSqr().redISub(r).redISub(s);o=o.redIAdd(o);var a=r.redAdd(r).redIAdd(r).redIAdd(this.curve.a),l=a.redSqr().redISub(o).redISub(o);e=l;var c=s.redIAdd(s);c=(c=c.redIAdd(c)).redIAdd(c),t=a.redMul(o.redISub(l)).redISub(c),i=this.y.redAdd(this.y)}else{var u=this.z.redSqr(),h=this.y.redSqr(),d=this.x.redMul(h),p=this.x.redSub(u).redMul(this.x.redAdd(u));p=p.redAdd(p).redIAdd(p);var g=d.redIAdd(d),f=(g=g.redIAdd(g)).redAdd(g);e=p.redSqr().redISub(f),i=this.y.redAdd(this.z).redSqr().redISub(h).redISub(u);var m=h.redSqr();m=(m=(m=m.redIAdd(m)).redIAdd(m)).redIAdd(m),t=p.redMul(g.redISub(e)).redISub(m)}return this.curve.jpoint(e,t,i)},u.prototype._dbl=function(){var e=this.curve.a,t=this.x,i=this.y,r=this.z,n=r.redSqr().redSqr(),s=t.redSqr(),o=i.redSqr(),a=s.redAdd(s).redIAdd(s).redIAdd(e.redMul(n)),l=t.redAdd(t),c=(l=l.redIAdd(l)).redMul(o),u=a.redSqr().redISub(c.redAdd(c)),h=c.redISub(u),d=o.redSqr();d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var p=a.redMul(h).redISub(d),g=i.redAdd(i).redMul(r);return this.curve.jpoint(u,p,g)},u.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var e=this.x.redSqr(),t=this.y.redSqr(),i=this.z.redSqr(),r=t.redSqr(),n=e.redAdd(e).redIAdd(e),s=n.redSqr(),o=this.x.redAdd(t).redSqr().redISub(e).redISub(r),a=(o=(o=(o=o.redIAdd(o)).redAdd(o).redIAdd(o)).redISub(s)).redSqr(),l=r.redIAdd(r);l=(l=(l=l.redIAdd(l)).redIAdd(l)).redIAdd(l);var c=n.redIAdd(o).redSqr().redISub(s).redISub(a).redISub(l),u=t.redMul(c);u=(u=u.redIAdd(u)).redIAdd(u);var h=this.x.redMul(a).redISub(u);h=(h=h.redIAdd(h)).redIAdd(h);var d=this.y.redMul(c.redMul(l.redISub(c)).redISub(o.redMul(a)));d=(d=(d=d.redIAdd(d)).redIAdd(d)).redIAdd(d);var p=this.z.redAdd(o).redSqr().redISub(i).redISub(a);return this.curve.jpoint(h,d,p)},u.prototype.mul=function(e,t){return e=new n(e,t),this.curve._wnafMul(this,e)},u.prototype.eq=function(e){if("affine"===e.type)return this.eq(e.toJ());if(this===e)return!0;var t=this.z.redSqr(),i=e.z.redSqr();if(0!==this.x.redMul(i).redISub(e.x.redMul(t)).cmpn(0))return!1;var r=t.redMul(this.z),n=i.redMul(e.z);return 0===this.y.redMul(n).redISub(e.y.redMul(r)).cmpn(0)},u.prototype.eqXToP=function(e){var t=this.z.redSqr(),i=e.toRed(this.curve.red).redMul(t);if(0===this.x.cmp(i))return!0;for(var r=e.clone(),n=this.curve.redN.redMul(t);;){if(r.iadd(this.curve.n),r.cmp(this.curve.p)>=0)return!1;if(i.redIAdd(n),0===this.x.cmp(i))return!0}},u.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},u.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},25366(e,t,i){"use strict";var r,n=t,s=i(61631),o=i(95228),a=i(9185).assert;function l(e){"short"===e.type?this.curve=new o.short(e):"edwards"===e.type?this.curve=new o.edwards(e):this.curve=new o.mont(e),this.g=this.curve.g,this.n=this.curve.n,this.hash=e.hash,a(this.g.validate(),"Invalid curve"),a(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function c(e,t){Object.defineProperty(n,e,{configurable:!0,enumerable:!0,get:function(){var i=new l(t);return Object.defineProperty(n,e,{configurable:!0,enumerable:!0,value:i}),i}})}n.PresetCurve=l,c("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:s.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),c("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:s.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),c("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:s.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),c("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:s.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),c("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:s.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),c("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:s.sha256,gRed:!1,g:["9"]}),c("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:s.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{r=i(67153)}catch(e){r=void 0}c("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:s.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",r]})},72961(e,t,i){"use strict";var r=i(5630),n=i(52519),s=i(9185),o=i(25366),a=i(65442),l=s.assert,c=i(5666),u=i(44375);function h(e){if(!(this instanceof h))return new h(e);"string"==typeof e&&(l(Object.prototype.hasOwnProperty.call(o,e),"Unknown curve "+e),e=o[e]),e instanceof o.PresetCurve&&(e={curve:e}),this.curve=e.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=e.curve.g,this.g.precompute(e.curve.n.bitLength()+1),this.hash=e.hash||e.curve.hash}e.exports=h,h.prototype.keyPair=function(e){return new c(this,e)},h.prototype.keyFromPrivate=function(e,t){return c.fromPrivate(this,e,t)},h.prototype.keyFromPublic=function(e,t){return c.fromPublic(this,e,t)},h.prototype.genKeyPair=function(e){e||(e={});for(var t=new n({hash:this.hash,pers:e.pers,persEnc:e.persEnc||"utf8",entropy:e.entropy||a(this.hash.hmacStrength),entropyEnc:e.entropy&&e.entropyEnc||"utf8",nonce:this.n.toArray()}),i=this.n.byteLength(),s=this.n.sub(new r(2));;){var o=new r(t.generate(i));if(!(o.cmp(s)>0))return o.iaddn(1),this.keyFromPrivate(o)}},h.prototype._truncateToN=function(e,t,i){var n;if(r.isBN(e)||"number"==typeof e)n=(e=new r(e,16)).byteLength();else if("object"==typeof e)n=e.length,e=new r(e,16);else{var s=e.toString();n=s.length+1>>>1,e=new r(s,16)}"number"!=typeof i&&(i=8*n);var o=i-this.n.bitLength();return o>0&&(e=e.ushrn(o)),!t&&e.cmp(this.n)>=0?e.sub(this.n):e},h.prototype.sign=function(e,t,i,s){if("object"==typeof i&&(s=i,i=null),s||(s={}),"string"!=typeof e&&"number"!=typeof e&&!r.isBN(e)){l("object"==typeof e&&e&&"number"==typeof e.length,"Expected message to be an array-like, a hex string, or a BN instance"),l(e.length>>>0===e.length);for(var o=0;o<e.length;o++)l((255&e[o])===e[o])}t=this.keyFromPrivate(t,i),e=this._truncateToN(e,!1,s.msgBitLength),l(!e.isNeg(),"Can not sign a negative message");var a=this.n.byteLength(),c=t.getPrivate().toArray("be",a),h=e.toArray("be",a);l(new r(h).eq(e),"Can not sign message");for(var d=new n({hash:this.hash,entropy:c,nonce:h,pers:s.pers,persEnc:s.persEnc||"utf8"}),p=this.n.sub(new r(1)),g=0;;g++){var f=s.k?s.k(g):new r(d.generate(this.n.byteLength()));if(!((f=this._truncateToN(f,!0)).cmpn(1)<=0||f.cmp(p)>=0)){var m=this.g.mul(f);if(!m.isInfinity()){var v=m.getX(),C=v.umod(this.n);if(0!==C.cmpn(0)){var y=f.invm(this.n).mul(C.mul(t.getPrivate()).iadd(e));if(0!==(y=y.umod(this.n)).cmpn(0)){var w=(m.getY().isOdd()?1:0)|(0!==v.cmp(C)?2:0);return s.canonical&&y.cmp(this.nh)>0&&(y=this.n.sub(y),w^=1),new u({r:C,s:y,recoveryParam:w})}}}}}},h.prototype.verify=function(e,t,i,r,n){n||(n={}),e=this._truncateToN(e,!1,n.msgBitLength),i=this.keyFromPublic(i,r);var s=(t=new u(t,"hex")).r,o=t.s;if(s.cmpn(1)<0||s.cmp(this.n)>=0)return!1;if(o.cmpn(1)<0||o.cmp(this.n)>=0)return!1;var a,l=o.invm(this.n),c=l.mul(e).umod(this.n),h=l.mul(s).umod(this.n);return this.curve._maxwellTrick?!(a=this.g.jmulAdd(c,i.getPublic(),h)).isInfinity()&&a.eqXToP(s):!(a=this.g.mulAdd(c,i.getPublic(),h)).isInfinity()&&0===a.getX().umod(this.n).cmp(s)},h.prototype.recoverPubKey=function(e,t,i,n){l((3&i)===i,"The recovery param is more than two bits"),t=new u(t,n);var s=this.n,o=new r(e),a=t.r,c=t.s,h=1&i,d=i>>1;if(a.cmp(this.curve.p.umod(this.curve.n))>=0&&d)throw new Error("Unable to find sencond key candinate");a=d?this.curve.pointFromX(a.add(this.curve.n),h):this.curve.pointFromX(a,h);var p=t.r.invm(s),g=s.sub(o).mul(p).umod(s),f=c.mul(p).umod(s);return this.g.mulAdd(g,a,f)},h.prototype.getKeyRecoveryParam=function(e,t,i,r){if(null!==(t=new u(t,r)).recoveryParam)return t.recoveryParam;for(var n=0;n<4;n++){var s;try{s=this.recoverPubKey(e,t,n)}catch(e){continue}if(s.eq(i))return n}throw new Error("Unable to find valid recovery factor")}},5666(e,t,i){"use strict";var r=i(5630),n=i(9185).assert;function s(e,t){this.ec=e,this.priv=null,this.pub=null,t.priv&&this._importPrivate(t.priv,t.privEnc),t.pub&&this._importPublic(t.pub,t.pubEnc)}e.exports=s,s.fromPublic=function(e,t,i){return t instanceof s?t:new s(e,{pub:t,pubEnc:i})},s.fromPrivate=function(e,t,i){return t instanceof s?t:new s(e,{priv:t,privEnc:i})},s.prototype.validate=function(){var e=this.getPublic();return e.isInfinity()?{result:!1,reason:"Invalid public key"}:e.validate()?e.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},s.prototype.getPublic=function(e,t){return"string"==typeof e&&(t=e,e=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),t?this.pub.encode(t,e):this.pub},s.prototype.getPrivate=function(e){return"hex"===e?this.priv.toString(16,2):this.priv},s.prototype._importPrivate=function(e,t){this.priv=new r(e,t||16),this.priv=this.priv.umod(this.ec.curve.n)},s.prototype._importPublic=function(e,t){if(e.x||e.y)return"mont"===this.ec.curve.type?n(e.x,"Need x coordinate"):"short"!==this.ec.curve.type&&"edwards"!==this.ec.curve.type||n(e.x&&e.y,"Need both x and y coordinate"),void(this.pub=this.ec.curve.point(e.x,e.y));this.pub=this.ec.curve.decodePoint(e,t)},s.prototype.derive=function(e){return e.validate()||n(e.validate(),"public point not validated"),e.mul(this.priv).getX()},s.prototype.sign=function(e,t,i){return this.ec.sign(e,this,t,i)},s.prototype.verify=function(e,t,i){return this.ec.verify(e,t,this,void 0,i)},s.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}},44375(e,t,i){"use strict";var r=i(5630),n=i(9185),s=n.assert;function o(e,t){if(e instanceof o)return e;this._importDER(e,t)||(s(e.r&&e.s,"Signature without r or s"),this.r=new r(e.r,16),this.s=new r(e.s,16),void 0===e.recoveryParam?this.recoveryParam=null:this.recoveryParam=e.recoveryParam)}function a(){this.place=0}function l(e,t){var i=e[t.place++];if(!(128&i))return i;var r=15&i;if(0===r||r>4)return!1;if(0===e[t.place])return!1;for(var n=0,s=0,o=t.place;s<r;s++,o++)n<<=8,n|=e[o],n>>>=0;return!(n<=127)&&(t.place=o,n)}function c(e){for(var t=0,i=e.length-1;!e[t]&&!(128&e[t+1])&&t<i;)t++;return 0===t?e:e.slice(t)}function u(e,t){if(t<128)e.push(t);else{var i=1+(Math.log(t)/Math.LN2>>>3);for(e.push(128|i);--i;)e.push(t>>>(i<<3)&255);e.push(t)}}e.exports=o,o.prototype._importDER=function(e,t){e=n.toArray(e,t);var i=new a;if(48!==e[i.place++])return!1;var s=l(e,i);if(!1===s)return!1;if(s+i.place!==e.length)return!1;if(2!==e[i.place++])return!1;var o=l(e,i);if(!1===o)return!1;if(128&e[i.place])return!1;var c=e.slice(i.place,o+i.place);if(i.place+=o,2!==e[i.place++])return!1;var u=l(e,i);if(!1===u)return!1;if(e.length!==u+i.place)return!1;if(128&e[i.place])return!1;var h=e.slice(i.place,u+i.place);if(0===c[0]){if(!(128&c[1]))return!1;c=c.slice(1)}if(0===h[0]){if(!(128&h[1]))return!1;h=h.slice(1)}return this.r=new r(c),this.s=new r(h),this.recoveryParam=null,!0},o.prototype.toDER=function(e){var t=this.r.toArray(),i=this.s.toArray();for(128&t[0]&&(t=[0].concat(t)),128&i[0]&&(i=[0].concat(i)),t=c(t),i=c(i);!(i[0]||128&i[1]);)i=i.slice(1);var r=[2];u(r,t.length),(r=r.concat(t)).push(2),u(r,i.length);var s=r.concat(i),o=[48];return u(o,s.length),o=o.concat(s),n.encode(o,e)}},87808(e,t,i){"use strict";var r=i(61631),n=i(25366),s=i(9185),o=s.assert,a=s.parseBytes,l=i(36419),c=i(95406);function u(e){if(o("ed25519"===e,"only tested with ed25519 so far"),!(this instanceof u))return new u(e);e=n[e].curve,this.curve=e,this.g=e.g,this.g.precompute(e.n.bitLength()+1),this.pointClass=e.point().constructor,this.encodingLength=Math.ceil(e.n.bitLength()/8),this.hash=r.sha512}e.exports=u,u.prototype.sign=function(e,t){e=a(e);var i=this.keyFromSecret(t),r=this.hashInt(i.messagePrefix(),e),n=this.g.mul(r),s=this.encodePoint(n),o=this.hashInt(s,i.pubBytes(),e).mul(i.priv()),l=r.add(o).umod(this.curve.n);return this.makeSignature({R:n,S:l,Rencoded:s})},u.prototype.verify=function(e,t,i){if(e=a(e),(t=this.makeSignature(t)).S().gte(t.eddsa.curve.n)||t.S().isNeg())return!1;var r=this.keyFromPublic(i),n=this.hashInt(t.Rencoded(),r.pubBytes(),e),s=this.g.mul(t.S());return t.R().add(r.pub().mul(n)).eq(s)},u.prototype.hashInt=function(){for(var e=this.hash(),t=0;t<arguments.length;t++)e.update(arguments[t]);return s.intFromLE(e.digest()).umod(this.curve.n)},u.prototype.keyFromPublic=function(e){return l.fromPublic(this,e)},u.prototype.keyFromSecret=function(e){return l.fromSecret(this,e)},u.prototype.makeSignature=function(e){return e instanceof c?e:new c(this,e)},u.prototype.encodePoint=function(e){var t=e.getY().toArray("le",this.encodingLength);return t[this.encodingLength-1]|=e.getX().isOdd()?128:0,t},u.prototype.decodePoint=function(e){var t=(e=s.parseBytes(e)).length-1,i=e.slice(0,t).concat(-129&e[t]),r=!!(128&e[t]),n=s.intFromLE(i);return this.curve.pointFromY(n,r)},u.prototype.encodeInt=function(e){return e.toArray("le",this.encodingLength)},u.prototype.decodeInt=function(e){return s.intFromLE(e)},u.prototype.isPoint=function(e){return e instanceof this.pointClass}},36419(e,t,i){"use strict";var r=i(9185),n=r.assert,s=r.parseBytes,o=r.cachedProperty;function a(e,t){this.eddsa=e,this._secret=s(t.secret),e.isPoint(t.pub)?this._pub=t.pub:this._pubBytes=s(t.pub)}a.fromPublic=function(e,t){return t instanceof a?t:new a(e,{pub:t})},a.fromSecret=function(e,t){return t instanceof a?t:new a(e,{secret:t})},a.prototype.secret=function(){return this._secret},o(a,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),o(a,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),o(a,"privBytes",function(){var e=this.eddsa,t=this.hash(),i=e.encodingLength-1,r=t.slice(0,e.encodingLength);return r[0]&=248,r[i]&=127,r[i]|=64,r}),o(a,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),o(a,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),o(a,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),a.prototype.sign=function(e){return n(this._secret,"KeyPair can only verify"),this.eddsa.sign(e,this)},a.prototype.verify=function(e,t){return this.eddsa.verify(e,t,this)},a.prototype.getSecret=function(e){return n(this._secret,"KeyPair is public only"),r.encode(this.secret(),e)},a.prototype.getPublic=function(e){return r.encode(this.pubBytes(),e)},e.exports=a},95406(e,t,i){"use strict";var r=i(5630),n=i(9185),s=n.assert,o=n.cachedProperty,a=n.parseBytes;function l(e,t){this.eddsa=e,"object"!=typeof t&&(t=a(t)),Array.isArray(t)&&(s(t.length===2*e.encodingLength,"Signature has invalid size"),t={R:t.slice(0,e.encodingLength),S:t.slice(e.encodingLength)}),s(t.R&&t.S,"Signature without R or S"),e.isPoint(t.R)&&(this._R=t.R),t.S instanceof r&&(this._S=t.S),this._Rencoded=Array.isArray(t.R)?t.R:t.Rencoded,this._Sencoded=Array.isArray(t.S)?t.S:t.Sencoded}o(l,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),o(l,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),o(l,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),o(l,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),l.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},l.prototype.toHex=function(){return n.encode(this.toBytes(),"hex").toUpperCase()},e.exports=l},67153(e){e.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}},9185(e,t,i){"use strict";var r=t,n=i(5630),s=i(35578),o=i(94209);r.assert=s,r.toArray=o.toArray,r.zero2=o.zero2,r.toHex=o.toHex,r.encode=o.encode,r.getNAF=function(e,t,i){var r,n=new Array(Math.max(e.bitLength(),i)+1);for(r=0;r<n.length;r+=1)n[r]=0;var s=1<<t+1,o=e.clone();for(r=0;r<n.length;r++){var a,l=o.andln(s-1);o.isOdd()?(a=l>(s>>1)-1?(s>>1)-l:l,o.isubn(a)):a=0,n[r]=a,o.iushrn(1)}return n},r.getJSF=function(e,t){var i=[[],[]];e=e.clone(),t=t.clone();for(var r,n=0,s=0;e.cmpn(-n)>0||t.cmpn(-s)>0;){var o,a,l=e.andln(3)+n&3,c=t.andln(3)+s&3;3===l&&(l=-1),3===c&&(c=-1),o=1&l?3!=(r=e.andln(7)+n&7)&&5!==r||2!==c?l:-l:0,i[0].push(o),a=1&c?3!=(r=t.andln(7)+s&7)&&5!==r||2!==l?c:-c:0,i[1].push(a),2*n===o+1&&(n=1-n),2*s===a+1&&(s=1-s),e.iushrn(1),t.iushrn(1)}return i},r.cachedProperty=function(e,t,i){var r="_"+t;e.prototype[t]=function(){return void 0!==this[r]?this[r]:this[r]=i.call(this)}},r.parseBytes=function(e){return"string"==typeof e?r.toArray(e,"hex"):e},r.intFromLE=function(e){return new n(e,"hex","le")}},15120(e){function t(e){if(e)return function(e){for(var i in t.prototype)e[i]=t.prototype[i];return e}(e)}e.exports=t,t.prototype.on=t.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks[e]=this._callbacks[e]||[]).push(t),this},t.prototype.once=function(e,t){var i=this;function r(){i.off(e,r),t.apply(this,arguments)}return this._callbacks=this._callbacks||{},r.fn=t,this.on(e,r),this},t.prototype.off=t.prototype.removeListener=t.prototype.removeAllListeners=t.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var i,r=this._callbacks[e];if(!r)return this;if(1==arguments.length)return delete this._callbacks[e],this;for(var n=0;n<r.length;n++)if((i=r[n])===t||i.fn===t){r.splice(n,1);break}return this},t.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),i=this._callbacks[e];if(i)for(var r=0,n=(i=i.slice(0)).length;r<n;++r)i[r].apply(this,t);return this},t.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks[e]||[]},t.prototype.hasListeners=function(e){return!!this.listeners(e).length}},15726(e,t,i){var r=i(69866),n=i(24758).each;function s(e,t){this.query=e,this.isUnconditional=t,this.handlers=[],this.mql=window.matchMedia(e);var i=this;this.listener=function(e){i.mql=e.currentTarget||e,i.assess()},this.mql.addListener(this.listener)}s.prototype={constuctor:s,addHandler:function(e){var t=new r(e);this.handlers.push(t),this.matches()&&t.on()},removeHandler:function(e){var t=this.handlers;n(t,function(i,r){if(i.equals(e))return i.destroy(),!t.splice(r,1)})},matches:function(){return this.mql.matches||this.isUnconditional},clear:function(){n(this.handlers,function(e){e.destroy()}),this.mql.removeListener(this.listener),this.handlers.length=0},assess:function(){var e=this.matches()?"on":"off";n(this.handlers,function(t){t[e]()})}},e.exports=s},68456(e,t,i){var r=i(15726),n=i(24758),s=n.each,o=n.isFunction,a=n.isArray;function l(){if(!window.matchMedia)throw new Error("matchMedia not present, legacy browsers require a polyfill");this.queries={},this.browserIsIncapable=!window.matchMedia("only all").matches}l.prototype={constructor:l,register:function(e,t,i){var n=this.queries,l=i&&this.browserIsIncapable;return n[e]||(n[e]=new r(e,l)),o(t)&&(t={match:t}),a(t)||(t=[t]),s(t,function(t){o(t)&&(t={match:t}),n[e].addHandler(t)}),this},unregister:function(e,t){var i=this.queries[e];return i&&(t?i.removeHandler(t):(i.clear(),delete this.queries[e])),this}},e.exports=l},69866(e){function t(e){this.options=e,!e.deferSetup&&this.setup()}t.prototype={constructor:t,setup:function(){this.options.setup&&this.options.setup(),this.initialised=!0},on:function(){!this.initialised&&this.setup(),this.options.match&&this.options.match()},off:function(){this.options.unmatch&&this.options.unmatch()},destroy:function(){this.options.destroy?this.options.destroy():this.off()},equals:function(e){return this.options===e||this.options.match===e}},e.exports=t},24758(e){e.exports={isFunction:function(e){return"function"==typeof e},isArray:function(e){return"[object Array]"===Object.prototype.toString.apply(e)},each:function(e,t){for(var i=0,r=e.length;i<r&&!1!==t(e[i],i);i++);}}},78708(e,t,i){var r=i(68456);e.exports=new r},39886(e){"use strict";var t=Object.defineProperty||!1;if(t)try{t({},"a",{value:1})}catch(e){t=!1}e.exports=t},38004(e){"use strict";e.exports=EvalError},41488(e){"use strict";e.exports=Error},96469(e){"use strict";e.exports=RangeError},12557(e){"use strict";e.exports=ReferenceError},63429(e){"use strict";e.exports=SyntaxError},71102(e){"use strict";e.exports=TypeError},85966(e){"use strict";e.exports=URIError},25153(e){"use strict";e.exports=Object},80381(e){"use strict";var t,i="object"==typeof Reflect?Reflect:null,r=i&&"function"==typeof i.apply?i.apply:function(e,t,i){return Function.prototype.apply.call(e,t,i)};t=i&&"function"==typeof i.ownKeys?i.ownKeys:Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:function(e){return Object.getOwnPropertyNames(e)};var n=Number.isNaN||function(e){return e!=e};function s(){s.init.call(this)}e.exports=s,e.exports.once=function(e,t){return new Promise(function(i,r){function n(i){e.removeListener(t,s),r(i)}function s(){"function"==typeof e.removeListener&&e.removeListener("error",n),i([].slice.call(arguments))}f(e,t,s,{once:!0}),"error"!==t&&function(e,t){"function"==typeof e.on&&f(e,"error",t,{once:!0})}(e,n)})},s.EventEmitter=s,s.prototype._events=void 0,s.prototype._eventsCount=0,s.prototype._maxListeners=void 0;var o=10;function a(e){if("function"!=typeof e)throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}function l(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function c(e,t,i,r){var n,s,o,c;if(a(i),void 0===(s=e._events)?(s=e._events=Object.create(null),e._eventsCount=0):(void 0!==s.newListener&&(e.emit("newListener",t,i.listener?i.listener:i),s=e._events),o=s[t]),void 0===o)o=s[t]=i,++e._eventsCount;else if("function"==typeof o?o=s[t]=r?[i,o]:[o,i]:r?o.unshift(i):o.push(i),(n=l(e))>0&&o.length>n&&!o.warned){o.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+o.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=o.length,c=u,console&&console.warn&&console.warn(c)}return e}function u(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,0===arguments.length?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function h(e,t,i){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:i},n=u.bind(r);return n.listener=i,r.wrapFn=n,n}function d(e,t,i){var r=e._events;if(void 0===r)return[];var n=r[t];return void 0===n?[]:"function"==typeof n?i?[n.listener||n]:[n]:i?function(e){for(var t=new Array(e.length),i=0;i<t.length;++i)t[i]=e[i].listener||e[i];return t}(n):g(n,n.length)}function p(e){var t=this._events;if(void 0!==t){var i=t[e];if("function"==typeof i)return 1;if(void 0!==i)return i.length}return 0}function g(e,t){for(var i=new Array(t),r=0;r<t;++r)i[r]=e[r];return i}function f(e,t,i,r){if("function"==typeof e.on)r.once?e.once(t,i):e.on(t,i);else{if("function"!=typeof e.addEventListener)throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e);e.addEventListener(t,function n(s){r.once&&e.removeEventListener(t,n),i(s)})}}Object.defineProperty(s,"defaultMaxListeners",{enumerable:!0,get:function(){return o},set:function(e){if("number"!=typeof e||e<0||n(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");o=e}}),s.init=function(){void 0!==this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||n(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return l(this)},s.prototype.emit=function(e){for(var t=[],i=1;i<arguments.length;i++)t.push(arguments[i]);var n="error"===e,s=this._events;if(void 0!==s)n=n&&void 0===s.error;else if(!n)return!1;if(n){var o;if(t.length>0&&(o=t[0]),o instanceof Error)throw o;var a=new Error("Unhandled error."+(o?" ("+o.message+")":""));throw a.context=o,a}var l=s[e];if(void 0===l)return!1;if("function"==typeof l)r(l,this,t);else{var c=l.length,u=g(l,c);for(i=0;i<c;++i)r(u[i],this,t)}return!0},s.prototype.addListener=function(e,t){return c(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return c(this,e,t,!0)},s.prototype.once=function(e,t){return a(t),this.on(e,h(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){return a(t),this.prependListener(e,h(this,e,t)),this},s.prototype.removeListener=function(e,t){var i,r,n,s,o;if(a(t),void 0===(r=this._events))return this;if(void 0===(i=r[e]))return this;if(i===t||i.listener===t)0===--this._eventsCount?this._events=Object.create(null):(delete r[e],r.removeListener&&this.emit("removeListener",e,i.listener||t));else if("function"!=typeof i){for(n=-1,s=i.length-1;s>=0;s--)if(i[s]===t||i[s].listener===t){o=i[s].listener,n=s;break}if(n<0)return this;0===n?i.shift():function(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}(i,n),1===i.length&&(r[e]=i[0]),void 0!==r.removeListener&&this.emit("removeListener",e,o||t)}return this},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(e){var t,i,r;if(void 0===(i=this._events))return this;if(void 0===i.removeListener)return 0===arguments.length?(this._events=Object.create(null),this._eventsCount=0):void 0!==i[e]&&(0===--this._eventsCount?this._events=Object.create(null):delete i[e]),this;if(0===arguments.length){var n,s=Object.keys(i);for(r=0;r<s.length;++r)"removeListener"!==(n=s[r])&&this.removeAllListeners(n);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if("function"==typeof(t=i[e]))this.removeListener(e,t);else if(void 0!==t)for(r=t.length-1;r>=0;r--)this.removeListener(e,t[r]);return this},s.prototype.listeners=function(e){return d(this,e,!0)},s.prototype.rawListeners=function(e){return d(this,e,!1)},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):p.call(e,t)},s.prototype.listenerCount=p,s.prototype.eventNames=function(){return this._eventsCount>0?t(this._events):[]}},51804(e,t,i){var r=i(56608).Buffer,n=i(75035);e.exports=function(e,t,i,s){if(r.isBuffer(e)||(e=r.from(e,"binary")),t&&(r.isBuffer(t)||(t=r.from(t,"binary")),8!==t.length))throw new RangeError("salt should be Buffer with 8 byte length");for(var o=i/8,a=r.alloc(o),l=r.alloc(s||0),c=r.alloc(0);o>0||s>0;){var u=new n;u.update(c),u.update(e),t&&u.update(t),c=u.digest();var h=0;if(o>0){var d=a.length-o;h=Math.min(o,c.length),c.copy(a,d,0,h),o-=h}if(h<c.length&&s>0){var p=l.length-s,g=Math.min(s,c.length-h);c.copy(l,p,h,h+g),s-=g}}return c.fill(0),{key:a,iv:l}}},52083(e,t,i){var r;!function(){"use strict";var n=!("undefined"==typeof window||!window.document||!window.document.createElement),s={canUseDOM:n,canUseWorkers:"undefined"!=typeof Worker,canUseEventListeners:n&&!(!window.addEventListener&&!window.attachEvent),canUseViewport:n&&!!window.screen};void 0===(r=function(){return s}.call(t,i,t,e))||(e.exports=r)}()},49461(e){"use strict";var t=Object.prototype.hasOwnProperty,i=Object.prototype.toString,r=Object.defineProperty,n=Object.getOwnPropertyDescriptor,s=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===i.call(e)},o=function(e){if(!e||"[object Object]"!==i.call(e))return!1;var r,n=t.call(e,"constructor"),s=e.constructor&&e.constructor.prototype&&t.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!n&&!s)return!1;for(r in e);return void 0===r||t.call(e,r)},a=function(e,t){r&&"__proto__"===t.name?r(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},l=function(e,i){if("__proto__"===i){if(!t.call(e,i))return;if(n)return n(e,i).value}return e[i]};e.exports=function e(){var t,i,r,n,c,u,h=arguments[0],d=1,p=arguments.length,g=!1;for("boolean"==typeof h&&(g=h,h=arguments[1]||{},d=2),(null==h||"object"!=typeof h&&"function"!=typeof h)&&(h={});d<p;++d)if(null!=(t=arguments[d]))for(i in t)r=l(h,i),h!==(n=l(t,i))&&(g&&n&&(o(n)||(c=s(n)))?(c?(c=!1,u=r&&s(r)?r:[]):u=r&&o(r)?r:{},a(h,{name:i,newValue:e(g,u,n)})):void 0!==n&&a(h,{name:i,newValue:n}));return h}},67371(e){"use strict";e.exports=function e(t,i){if(t===i)return!0;if(t&&i&&"object"==typeof t&&"object"==typeof i){if(t.constructor!==i.constructor)return!1;var r,n,s;if(Array.isArray(t)){if((r=t.length)!=i.length)return!1;for(n=r;0!==n--;)if(!e(t[n],i[n]))return!1;return!0}if(t.constructor===RegExp)return t.source===i.source&&t.flags===i.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===i.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===i.toString();if((r=(s=Object.keys(t)).length)!==Object.keys(i).length)return!1;for(n=r;0!==n--;)if(!Object.prototype.hasOwnProperty.call(i,s[n]))return!1;for(n=r;0!==n--;){var o=s[n];if(!e(t[o],i[o]))return!1}return!0}return t!=t&&i!=i}},53039(e,t,i){"use strict";i.d(t,{D4:()=>D});var r=i(84708),n=i(35310);const s=[];for(let e=0;e<256;e++){let t=e;for(let e=0;e<8;e++)1&t?t=3988292384^t>>>1:t>>>=1;s[e]=t}const o=4294967295;function a(e,t,i){const r=e.readUint32(),n=(a=new Uint8Array(e.buffer,e.byteOffset+e.offset-t-4,t),(function(e,t,i){let r=e;for(let e=0;e<i;e++)r=s[255&(r^t[e])]^r>>>8;return r}(o,a,t)^o)>>>0);var a;if(n!==r)throw new Error(`CRC mismatch for chunk ${i}. Expected ${r}, found ${n}`)}function l(e,t,i){for(let r=0;r<i;r++)t[r]=e[r]}function c(e,t,i,r){let n=0;for(;n<r;n++)t[n]=e[n];for(;n<i;n++)t[n]=e[n]+t[n-r]&255}function u(e,t,i,r){let n=0;if(0===i.length)for(;n<r;n++)t[n]=e[n];else for(;n<r;n++)t[n]=e[n]+i[n]&255}function h(e,t,i,r,n){let s=0;if(0===i.length){for(;s<n;s++)t[s]=e[s];for(;s<r;s++)t[s]=e[s]+(t[s-n]>>1)&255}else{for(;s<n;s++)t[s]=e[s]+(i[s]>>1)&255;for(;s<r;s++)t[s]=e[s]+(t[s-n]+i[s]>>1)&255}}function d(e,t,i,r,n){let s=0;if(0===i.length){for(;s<n;s++)t[s]=e[s];for(;s<r;s++)t[s]=e[s]+t[s-n]&255}else{for(;s<n;s++)t[s]=e[s]+i[s]&255;for(;s<r;s++)t[s]=e[s]+p(t[s-n],i[s],i[s-n])&255}}function p(e,t,i){const r=e+t-i,n=Math.abs(r-e),s=Math.abs(r-t),o=Math.abs(r-i);return n<=s&&n<=o?e:s<=o?t:i}function g(e,t,i,r,n,s){switch(e){case 0:l(t,i,n);break;case 1:c(t,i,n,s);break;case 2:u(t,i,r,n);break;case 3:h(t,i,r,n,s);break;case 4:d(t,i,r,n,s);break;default:throw new Error(`Unsupported filter: ${e}`)}}const f=new Uint16Array([255]),m=255===new Uint8Array(f.buffer)[0];function v(e){return(255&e)<<8|e>>8&255}const C=new Uint16Array([255]),y=255===new Uint8Array(C.buffer)[0],w=new Uint8Array(0);function S(e){const{data:t,width:i,height:r,channels:n,depth:s}=e,o=Math.ceil(s/8)*n,a=Math.ceil(s/8*n*i),p=new Uint8Array(r*a);let g,f,m=w,v=0;for(let e=0;e<r;e++){switch(g=t.subarray(v+1,v+1+a),f=p.subarray(e*a,(e+1)*a),t[v]){case 0:l(g,f,a);break;case 1:c(g,f,a,o);break;case 2:u(g,f,m,a);break;case 3:h(g,f,m,a,o);break;case 4:d(g,f,m,a,o);break;default:throw new Error(`Unsupported filter: ${t[v]}`)}m=f,v+=a+1}if(16===s){const e=new Uint16Array(p.buffer);if(y)for(let t=0;t<e.length;t++)e[t]=b(e[t]);return e}return p}function b(e){return(255&e)<<8|e>>8&255}const E=Uint8Array.of(137,80,78,71,13,10,26,10);function A(e){if(!function(e){if(e.length<E.length)return!1;for(let t=0;t<E.length;t++)if(e[t]!==E[t])return!1;return!0}(e.readBytes(E.length)))throw new Error("wrong PNG signature")}const T=new TextDecoder("latin1");function M(e){if(function(e){if(!R.test(e))throw new Error("invalid latin1 text")}(e),0===e.length||e.length>79)throw new Error("keyword length must be between 1 and 79")}const R=/^[\u0000-\u00FF]*$/;function _(e){for(e.mark();0!==e.readByte(););const t=e.offset;e.reset();const i=T.decode(e.readBytes(t-e.offset-1));return e.skip(1),M(i),i}class P extends r.H{_checkCrc;_inflator;_png;_apng;_end;_hasPalette;_palette;_hasTransparency;_transparency;_compressionMethod;_filterMethod;_interlaceMethod;_colorType;_isAnimated;_numberOfFrames;_numberOfPlays;_frames;_writingDataChunks;constructor(e,t={}){super(e);const{checkCrc:i=!1}=t;this._checkCrc=i,this._inflator=new n.EL,this._png={width:-1,height:-1,channels:-1,data:new Uint8Array(0),depth:1,text:{}},this._apng={width:-1,height:-1,channels:-1,depth:1,numberOfFrames:1,numberOfPlays:0,text:{},frames:[]},this._end=!1,this._hasPalette=!1,this._palette=[],this._hasTransparency=!1,this._transparency=new Uint16Array(0),this._compressionMethod=-1,this._filterMethod=-1,this._interlaceMethod=-1,this._colorType=-1,this._isAnimated=!1,this._numberOfFrames=1,this._numberOfPlays=0,this._frames=[],this._writingDataChunks=!1,this.setBigEndian()}decode(){for(A(this);!this._end;){const e=this.readUint32(),t=this.readChars(4);this.decodeChunk(e,t)}return this.decodeImage(),this._png}decodeApng(){for(A(this);!this._end;){const e=this.readUint32(),t=this.readChars(4);this.decodeApngChunk(e,t)}return this.decodeApngImage(),this._apng}decodeChunk(e,t){const i=this.offset;switch(t){case"IHDR":this.decodeIHDR();break;case"PLTE":this.decodePLTE(e);break;case"IDAT":this.decodeIDAT(e);break;case"IEND":this._end=!0;break;case"tRNS":this.decodetRNS(e);break;case"iCCP":this.decodeiCCP(e);break;case"tEXt":!function(e,t,i){const r=_(t);e[r]=function(e,t){return T.decode(e.readBytes(t))}(t,i-r.length-1)}(this._png.text,this,e);break;case"pHYs":this.decodepHYs();break;default:this.skip(e)}if(this.offset-i!==e)throw new Error(`Length mismatch while decoding chunk ${t}`);this._checkCrc?a(this,e+4,t):this.skip(4)}decodeApngChunk(e,t){const i=this.offset;switch("fdAT"!==t&&"IDAT"!==t&&this._writingDataChunks&&this.pushDataToFrame(),t){case"acTL":this.decodeACTL();break;case"fcTL":this.decodeFCTL();break;case"fdAT":this.decodeFDAT(e);break;default:this.decodeChunk(e,t),this.offset=i+e}if(this.offset-i!==e)throw new Error(`Length mismatch while decoding chunk ${t}`);this._checkCrc?a(this,e+4,t):this.skip(4)}decodeIHDR(){const e=this._png;e.width=this.readUint32(),e.height=this.readUint32(),e.depth=function(e){if(1!==e&&2!==e&&4!==e&&8!==e&&16!==e)throw new Error(`invalid bit depth: ${e}`);return e}(this.readUint8());const t=this.readUint8();let i;switch(this._colorType=t,t){case 0:case 3:i=1;break;case 2:i=3;break;case 4:i=2;break;case 6:i=4;break;default:throw new Error(`Unknown color type: ${t}`)}if(this._png.channels=i,this._compressionMethod=this.readUint8(),0!==this._compressionMethod)throw new Error(`Unsupported compression method: ${this._compressionMethod}`);this._filterMethod=this.readUint8(),this._interlaceMethod=this.readUint8()}decodeACTL(){this._numberOfFrames=this.readUint32(),this._numberOfPlays=this.readUint32(),this._isAnimated=!0}decodeFCTL(){const e={sequenceNumber:this.readUint32(),width:this.readUint32(),height:this.readUint32(),xOffset:this.readUint32(),yOffset:this.readUint32(),delayNumber:this.readUint16(),delayDenominator:this.readUint16(),disposeOp:this.readUint8(),blendOp:this.readUint8(),data:new Uint8Array(0)};this._frames.push(e)}decodePLTE(e){if(e%3!=0)throw new RangeError(`PLTE field length must be a multiple of 3. Got ${e}`);const t=e/3;this._hasPalette=!0;const i=[];this._palette=i;for(let e=0;e<t;e++)i.push([this.readUint8(),this.readUint8(),this.readUint8()])}decodeIDAT(e){this._writingDataChunks=!0;const t=e,i=this.offset+this.byteOffset;if(this._inflator.push(new Uint8Array(this.buffer,i,t)),this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);this.skip(e)}decodeFDAT(e){this._writingDataChunks=!0;let t=e,i=this.offset+this.byteOffset;if(i+=4,t-=4,this._inflator.push(new Uint8Array(this.buffer,i,t)),this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);this.skip(e)}decodetRNS(e){switch(this._colorType){case 0:case 2:if(e%2!=0)throw new RangeError(`tRNS chunk length must be a multiple of 2. Got ${e}`);if(e/2>this._png.width*this._png.height)throw new Error(`tRNS chunk contains more alpha values than there are pixels (${e/2} vs ${this._png.width*this._png.height})`);this._hasTransparency=!0,this._transparency=new Uint16Array(e/2);for(let t=0;t<e/2;t++)this._transparency[t]=this.readUint16();break;case 3:{if(e>this._palette.length)throw new Error(`tRNS chunk contains more alpha values than there are palette colors (${e} vs ${this._palette.length})`);let t=0;for(;t<e;t++){const e=this.readByte();this._palette[t].push(e)}for(;t<this._palette.length;t++)this._palette[t].push(255);break}default:throw new Error(`tRNS chunk is not supported for color type ${this._colorType}`)}}decodeiCCP(e){const t=_(this),i=this.readUint8();if(0!==i)throw new Error(`Unsupported iCCP compression method: ${i}`);const r=this.readBytes(e-t.length-2);this._png.iccEmbeddedProfile={name:t,profile:(0,n.UD)(r)}}decodepHYs(){const e=this.readUint32(),t=this.readUint32(),i=this.readByte();this._png.resolution={x:e,y:t,unit:i}}decodeApngImage(){this._apng.width=this._png.width,this._apng.height=this._png.height,this._apng.channels=this._png.channels,this._apng.depth=this._png.depth,this._apng.numberOfFrames=this._numberOfFrames,this._apng.numberOfPlays=this._numberOfPlays,this._apng.text=this._png.text,this._apng.resolution=this._png.resolution;for(let e=0;e<this._numberOfFrames;e++){const t={sequenceNumber:this._frames[e].sequenceNumber,delayNumber:this._frames[e].delayNumber,delayDenominator:this._frames[e].delayDenominator,data:8===this._apng.depth?new Uint8Array(this._apng.width*this._apng.height*this._apng.channels):new Uint16Array(this._apng.width*this._apng.height*this._apng.channels)},i=this._frames.at(e);if(i){if(i.data=S({data:i.data,width:i.width,height:i.height,channels:this._apng.channels,depth:this._apng.depth}),this._hasPalette&&(this._apng.palette=this._palette),this._hasTransparency&&(this._apng.transparency=this._transparency),0===e||0===i.xOffset&&0===i.yOffset&&i.width===this._png.width&&i.height===this._png.height)t.data=i.data;else{const r=this._apng.frames.at(e-1);this.disposeFrame(i,r,t),this.addFrameDataToCanvas(t,i)}this._apng.frames.push(t)}}return this._apng}disposeFrame(e,t,i){switch(e.disposeOp){case 0:break;case 1:for(let t=0;t<this._png.height;t++)for(let r=0;r<this._png.width;r++){const n=(t*e.width+r)*this._png.channels;for(let e=0;e<this._png.channels;e++)i.data[n+e]=0}break;case 2:i.data.set(t.data);break;default:throw new Error("Unknown disposeOp")}}addFrameDataToCanvas(e,t){const i=1<<this._png.depth,r=(e,i)=>({index:((e+t.yOffset)*this._png.width+t.xOffset+i)*this._png.channels,frameIndex:(e*t.width+i)*this._png.channels});switch(t.blendOp){case 0:for(let i=0;i<t.height;i++)for(let n=0;n<t.width;n++){const{index:s,frameIndex:o}=r(i,n);for(let i=0;i<this._png.channels;i++)e.data[s+i]=t.data[o+i]}break;case 1:for(let n=0;n<t.height;n++)for(let s=0;s<t.width;s++){const{index:o,frameIndex:a}=r(n,s);for(let r=0;r<this._png.channels;r++){const n=t.data[a+this._png.channels-1]/i,s=r%(this._png.channels-1)==0?1:t.data[a+r],l=Math.floor(n*s+(1-n)*e.data[o+r]);e.data[o+r]+=l}}break;default:throw new Error("Unknown blendOp")}}decodeImage(){if(this._inflator.err)throw new Error(`Error while decompressing the data: ${this._inflator.err}`);const e=this._isAnimated?(this._frames?.at(0)).data:this._inflator.result;if(0!==this._filterMethod)throw new Error(`Filter method ${this._filterMethod} not supported`);if(0===this._interlaceMethod)this._png.data=S({data:e,width:this._png.width,height:this._png.height,channels:this._png.channels,depth:this._png.depth});else{if(1!==this._interlaceMethod)throw new Error(`Interlace method ${this._interlaceMethod} not supported`);this._png.data=function(e){const{data:t,width:i,height:r,channels:n,depth:s}=e,o=[{x:0,y:0,xStep:8,yStep:8},{x:4,y:0,xStep:8,yStep:8},{x:0,y:4,xStep:4,yStep:8},{x:2,y:0,xStep:4,yStep:4},{x:0,y:2,xStep:2,yStep:4},{x:1,y:0,xStep:2,yStep:2},{x:0,y:1,xStep:1,yStep:2}],a=Math.ceil(s/8)*n,l=new Uint8Array(r*i*a);let c=0;for(let e=0;e<7;e++){const n=o[e],s=Math.ceil((i-n.x)/n.xStep),u=Math.ceil((r-n.y)/n.yStep);if(s<=0||u<=0)continue;const h=s*a,d=new Uint8Array(h);for(let e=0;e<u;e++){const o=t[c++],u=t.subarray(c,c+h);c+=h;const p=new Uint8Array(h);g(o,u,p,d,h,a),d.set(p);for(let t=0;t<s;t++){const s=n.x+t*n.xStep,o=n.y+e*n.yStep;if(!(s>=i||o>=r))for(let e=0;e<a;e++)l[(o*i+s)*a+e]=p[t*a+e]}}}if(16===s){const e=new Uint16Array(l.buffer);if(m)for(let t=0;t<e.length;t++)e[t]=v(e[t]);return e}return l}({data:e,width:this._png.width,height:this._png.height,channels:this._png.channels,depth:this._png.depth})}this._hasPalette&&(this._png.palette=this._palette),this._hasTransparency&&(this._png.transparency=this._transparency)}pushDataToFrame(){const e=this._inflator.result,t=this._frames.at(-1);t?t.data=e:this._frames.push({sequenceNumber:0,width:this._png.width,height:this._png.height,xOffset:0,yOffset:0,delayNumber:0,delayDenominator:0,disposeOp:0,blendOp:0,data:e}),this._inflator=new n.EL,this._writingDataChunks=!1}}var x;function D(e,t){return new P(e,t).decode()}r.H,function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.METRE=1]="METRE"}(x||(x={}))},81354(e,t,i){"use strict";var r=i(7144),n=i(95573),s=i(1948),o=new RegExp("\r\n","g"),a={"text/rtf":1,"text/html":1};function l(e){if("file"==e.kind)return e.getAsFile()}var c=function(){function e(e){this.data=e,this.types=e.types?n(e.types):[]}var t=e.prototype;return t.isRichText=function(){return!(!this.getHTML()||!this.getText())||!this.isImage()&&this.types.some(function(e){return a[e]})},t.getText=function(){var e;return this.data.getData&&(this.types.length?-1!=this.types.indexOf("text/plain")&&(e=this.data.getData("text/plain")):e=this.data.getData("Text")),e?e.replace(o,"\n"):null},t.getHTML=function(){if(this.data.getData){if(!this.types.length)return this.data.getData("Text");if(-1!=this.types.indexOf("text/html"))return this.data.getData("text/html")}},t.isLink=function(){return this.types.some(function(e){return-1!=e.indexOf("Url")||-1!=e.indexOf("text/uri-list")||e.indexOf("text/x-moz-url")})},t.getLink=function(){return this.data.getData?-1!=this.types.indexOf("text/x-moz-url")?this.data.getData("text/x-moz-url").split("\n")[0]:-1!=this.types.indexOf("text/uri-list")?this.data.getData("text/uri-list"):this.data.getData("url"):null},t.isImage=function(){var e=this.types.some(function(e){return-1!=e.indexOf("application/x-moz-file")});if(e)return!0;for(var t=this.getFiles(),i=0;i<t.length;i++){var n=t[i].type;if(!r.isImage(n))return!1}return!0},t.getCount=function(){return this.data.hasOwnProperty("items")?this.data.items.length:this.data.hasOwnProperty("mozItemCount")?this.data.mozItemCount:this.data.files?this.data.files.length:null},t.getFiles=function(){return this.data.items?Array.prototype.slice.call(this.data.items).map(l).filter(s.thatReturnsArgument):this.data.files?Array.prototype.slice.call(this.data.files):[]},t.hasFiles=function(){return this.getFiles().length>0},e}();e.exports=c},4617(e){"use strict";e.exports={BACKSPACE:8,TAB:9,RETURN:13,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46,COMMA:188,PERIOD:190,A:65,Z:90,ZERO:48,NUMPAD_0:96,NUMPAD_9:105}},7144(e){"use strict";var t={isImage:function(e){return"image"===i(e)[0]},isJpeg:function(e){var r=i(e);return t.isImage(e)&&("jpeg"===r[1]||"pjpeg"===r[1])}};function i(e){return e.split("/")}e.exports=t},72528(e){"use strict";function t(e,t){return!!t&&(e===t.documentElement||e===t.body)}var i={getTop:function(e){var i=e.ownerDocument;return t(e,i)?i.body.scrollTop||i.documentElement.scrollTop:e.scrollTop},setTop:function(e,i){var r=e.ownerDocument;t(e,r)?r.body.scrollTop=r.documentElement.scrollTop=i:e.scrollTop=i},getLeft:function(e){var i=e.ownerDocument;return t(e,i)?i.body.scrollLeft||i.documentElement.scrollLeft:e.scrollLeft},setLeft:function(e,i){var r=e.ownerDocument;t(e,r)?r.body.scrollLeft=r.documentElement.scrollLeft=i:e.scrollLeft=i}};e.exports=i},98556(e,t,i){"use strict";function r(e,t){var i=n.get(e,t);return"auto"===i||"scroll"===i}var n={get:i(54973),getScrollParent:function(e){if(!e)return null;for(var t=e.ownerDocument;e&&e!==t.body;){if(r(e,"overflow")||r(e,"overflowY")||r(e,"overflowX"))return e;e=e.parentNode}return t.defaultView||t.parentWindow}};e.exports=n},59544(e){"use strict";e.exports={getPunctuation:function(){return"[.,+*?$|#{}()'\\^\\-\\[\\]\\\\\\/!@%\"~=<>_:;・、。〈-】〔-〟：-？！-／［-｀｛-･⸮؟٪-٬؛،؍﴾﴿᠁।၊။‐-‧‰-⁞¡-±´-¸º»¿]"}}},10499(e){"use strict";var t=function(){function e(e){var t,i;i=void 0,(t="_uri")in this?Object.defineProperty(this,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):this[t]=i,this._uri=e}return e.prototype.toString=function(){return this._uri},e}();e.exports=t},46616(e,t,i){"use strict";var r=i(76675),n=i(40041),s="֐־׀׃׆׈-׏א-ת׫-ׯװ-ײ׳-״׵-׿߀-߉ߊ-ߪߴ-ߵߺ߻-߿ࠀ-ࠕࠚࠤࠨ࠮-࠯࠰-࠾࠿ࡀ-ࡘ࡜-࡝࡞࡟-࢟‏יִײַ-ﬨשׁ-זּ﬷טּ-לּ﬽מּ﬿נּ-סּ﭂ףּ-פּ﭅צּ-ﭏ",o="؈؋؍؛؜؝؞-؟ؠ-ؿـف-ي٭ٮ-ٯٱ-ۓ۔ەۥ-ۦۮ-ۯۺ-ۼ۽-۾ۿ܀-܍܎܏ܐܒ-ܯ݋-݌ݍ-ޥޱ޲-޿ࢠ-ࢲࢳ-ࣣﭐ-ﮱ﮲-﯁﯂-﯒ﯓ-ﴽ﵀-﵏ﵐ-ﶏ﶐-﶑ﶒ-ﷇ﷈-﷏ﷰ-ﷻ﷼﷾-﷿ﹰ-ﹴ﹵ﹶ-ﻼ﻽-﻾",a=new RegExp("[A-Za-zªµºÀ-ÖØ-öø-ƺƻƼ-ƿǀ-ǃǄ-ʓʔʕ-ʯʰ-ʸʻ-ˁː-ˑˠ-ˤˮͰ-ͳͶ-ͷͺͻ-ͽͿΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁ҂Ҋ-ԯԱ-Ֆՙ՚-՟ա-և։ःऄ-हऻऽा-ीॉ-ौॎ-ॏॐक़-ॡ।-॥०-९॰ॱॲ-ঀং-ঃঅ-ঌএ-ঐও-নপ-রলশ-হঽা-ীে-ৈো-ৌৎৗড়-ঢ়য়-ৡ০-৯ৰ-ৱ৴-৹৺ਃਅ-ਊਏ-ਐਓ-ਨਪ-ਰਲ-ਲ਼ਵ-ਸ਼ਸ-ਹਾ-ੀਖ਼-ੜਫ਼੦-੯ੲ-ੴઃઅ-ઍએ-ઑઓ-નપ-રલ-ળવ-હઽા-ીૉો-ૌૐૠ-ૡ૦-૯૰ଂ-ଃଅ-ଌଏ-ଐଓ-ନପ-ରଲ-ଳଵ-ହଽାୀେ-ୈୋ-ୌୗଡ଼-ଢ଼ୟ-ୡ୦-୯୰ୱ୲-୷ஃஅ-ஊஎ-ஐஒ-கங-சஜஞ-டண-தந-பம-ஹா-ிு-ூெ-ைொ-ௌௐௗ௦-௯௰-௲ఁ-ఃఅ-ఌఎ-ఐఒ-నప-హఽు-ౄౘ-ౙౠ-ౡ౦-౯౿ಂ-ಃಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽಾಿೀ-ೄೆೇ-ೈೊ-ೋೕ-ೖೞೠ-ೡ೦-೯ೱ-ೲം-ഃഅ-ഌഎ-ഐഒ-ഺഽാ-ീെ-ൈൊ-ൌൎൗൠ-ൡ൦-൯൰-൵൹ൺ-ൿං-ඃඅ-ඖක-නඳ-රලව-ෆා-ෑෘ-ෟ෦-෯ෲ-ෳ෴ก-ะา-ำเ-ๅๆ๏๐-๙๚-๛ກ-ຂຄງ-ຈຊຍດ-ທນ-ຟມ-ຣລວສ-ຫອ-ະາ-ຳຽເ-ໄໆ໐-໙ໜ-ໟༀ༁-༃༄-༒༓༔༕-༗༚-༟༠-༩༪-༳༴༶༸༾-༿ཀ-ཇཉ-ཬཿ྅ྈ-ྌ྾-࿅࿇-࿌࿎-࿏࿐-࿔࿕-࿘࿙-࿚က-ဪါ-ာေးျ-ြဿ၀-၉၊-၏ၐ-ၕၖ-ၗၚ-ၝၡၢ-ၤၥ-ၦၧ-ၭၮ-ၰၵ-ႁႃ-ႄႇ-ႌႎႏ႐-႙ႚ-ႜ႞-႟Ⴀ-ჅჇჍა-ჺ჻ჼჽ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚ፠-፨፩-፼ᎀ-ᎏᎠ-Ᏼᐁ-ᙬ᙭-᙮ᙯ-ᙿᚁ-ᚚᚠ-ᛪ᛫-᛭ᛮ-ᛰᛱ-ᛸᜀ-ᜌᜎ-ᜑᜠ-ᜱ᜵-᜶ᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳាើ-ៅះ-ៈ។-៖ៗ៘-៚ៜ០-៩᠐-᠙ᠠ-ᡂᡃᡄ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤞᤣ-ᤦᤩ-ᤫᤰ-ᤱᤳ-ᤸ᥆-᥏ᥐ-ᥭᥰ-ᥴᦀ-ᦫᦰ-ᧀᧁ-ᧇᧈ-ᧉ᧐-᧙᧚ᨀ-ᨖᨙ-ᨚ᨞-᨟ᨠ-ᩔᩕᩗᩡᩣ-ᩤᩭ-ᩲ᪀-᪉᪐-᪙᪠-᪦ᪧ᪨-᪭ᬄᬅ-ᬳᬵᬻᬽ-ᭁᭃ-᭄ᭅ-ᭋ᭐-᭙᭚-᭠᭡-᭪᭴-᭼ᮂᮃ-ᮠᮡᮦ-ᮧ᮪ᮮ-ᮯ᮰-᮹ᮺ-ᯥᯧᯪ-ᯬᯮ᯲-᯳᯼-᯿ᰀ-ᰣᰤ-ᰫᰴ-ᰵ᰻-᰿᱀-᱉ᱍ-ᱏ᱐-᱙ᱚ-ᱷᱸ-ᱽ᱾-᱿᳀-᳇᳓᳡ᳩ-ᳬᳮ-ᳱᳲ-ᳳᳵ-ᳶᴀ-ᴫᴬ-ᵪᵫ-ᵷᵸᵹ-ᶚᶛ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼ‎ⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℴℵ-ℸℹℼ-ℿⅅ-ⅉⅎ⅏Ⅰ-ↂↃ-ↄↅ-ↈ⌶-⍺⎕⒜-ⓩ⚬⠀-⣿Ⰰ-Ⱞⰰ-ⱞⱠ-ⱻⱼ-ⱽⱾ-ⳤⳫ-ⳮⳲ-ⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯ⵰ⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞ々〆〇〡-〩〮-〯〱-〵〸-〺〻〼ぁ-ゖゝ-ゞゟァ-ヺー-ヾヿㄅ-ㄭㄱ-ㆎ㆐-㆑㆒-㆕㆖-㆟ㆠ-ㆺㇰ-ㇿ㈀-㈜㈠-㈩㈪-㉇㉈-㉏㉠-㉻㉿㊀-㊉㊊-㊰㋀-㋋㋐-㋾㌀-㍶㍻-㏝㏠-㏾㐀-䶵一-鿌ꀀ-ꀔꀕꀖ-ꒌꓐ-ꓷꓸ-ꓽ꓾-꓿ꔀ-ꘋꘌꘐ-ꘟ꘠-꘩ꘪ-ꘫꙀ-ꙭꙮꚀ-ꚛꚜ-ꚝꚠ-ꛥꛦ-ꛯ꛲-꛷Ꜣ-ꝯꝰꝱ-ꞇ꞉-꞊Ꞌ-ꞎꞐ-ꞭꞰ-Ʇꟷꟸ-ꟹꟺꟻ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꠣ-ꠤꠧ꠰-꠵꠶-꠷ꡀ-ꡳꢀ-ꢁꢂ-ꢳꢴ-ꣃ꣎-꣏꣐-꣙ꣲ-ꣷ꣸-꣺ꣻ꤀-꤉ꤊ-ꤥ꤮-꤯ꤰ-ꥆꥒ-꥓꥟ꥠ-ꥼꦃꦄ-ꦲꦴ-ꦵꦺ-ꦻꦽ-꧀꧁-꧍ꧏ꧐-꧙꧞-꧟ꧠ-ꧤꧦꧧ-ꧯ꧰-꧹ꧺ-ꧾꨀ-ꨨꨯ-ꨰꨳ-ꨴꩀ-ꩂꩄ-ꩋꩍ꩐-꩙꩜-꩟ꩠ-ꩯꩰꩱ-ꩶ꩷-꩹ꩺꩻꩽꩾ-ꪯꪱꪵ-ꪶꪹ-ꪽꫀꫂꫛ-ꫜꫝ꫞-꫟ꫠ-ꫪꫫꫮ-ꫯ꫰-꫱ꫲꫳ-ꫴꫵꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꬰ-ꭚ꭛ꭜ-ꭟꭤ-ꭥꯀ-ꯢꯣ-ꯤꯦ-ꯧꯩ-ꯪ꯫꯬꯰-꯹가-힣ힰ-ퟆퟋ-ퟻ-豈-舘並-龎ﬀ-ﬆﬓ-ﬗＡ-Ｚａ-ｚｦ-ｯｰｱ-ﾝﾞ-ﾟﾠ-ﾾￂ-ￇￊ-ￏￒ-ￗￚ-ￜ"+s+o+"]"),l=new RegExp("["+s+o+"]");function c(e){var t=a.exec(e);return null==t?null:t[0]}function u(e){var t=c(e);return null==t?r.NEUTRAL:l.exec(t)?r.RTL:r.LTR}function h(e,t){if(t=t||r.NEUTRAL,!e.length)return t;var i=u(e);return i===r.NEUTRAL?t:i}function d(e,t){return t||(t=r.getGlobalDir()),r.isStrong(t)||n(!1),h(e,t)}var p={firstStrongChar:c,firstStrongCharDir:u,resolveBlockDir:h,getDirection:d,isDirectionLTR:function(e,t){return d(e,t)===r.LTR},isDirectionRTL:function(e,t){return d(e,t)===r.RTL}};e.exports=p},76675(e,t,i){"use strict";var r=i(40041),n="LTR",s=null;function o(e){return e===n||"RTL"===e}function a(e){return o(e)||r(!1),e===n?"ltr":"rtl"}function l(e){s=e}var c={NEUTRAL:"NEUTRAL",LTR:n,RTL:"RTL",isStrong:o,getHTMLDir:a,getHTMLDirIfDifferent:function(e,t){return o(e)||r(!1),o(t)||r(!1),e===t?null:a(e)},setGlobalDir:l,initGlobalDir:function(){l(n)},getGlobalDir:function(){return s||this.initGlobalDir(),s||r(!1),s}};e.exports=c},75361(e,t,i){"use strict";function r(e,t,i){return t in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}var n=i(46616),s=i(76675),o=i(40041),a=function(){function e(e){r(this,"_defaultDir",void 0),r(this,"_lastDir",void 0),e?s.isStrong(e)||o(!1):e=s.getGlobalDir(),this._defaultDir=e,this.reset()}var t=e.prototype;return t.reset=function(){this._lastDir=this._defaultDir},t.getDirection=function(e){return this._lastDir=n.getDirection(e,this._lastDir),this._lastDir},e}();e.exports=a},13145(e,t,i){"use strict";var r=i(40041),n=/[\uD800-\uDFFF]/;function s(e){return 55296<=e&&e<=57343}function o(e){return n.test(e)}function a(e,t){return 1+s(e.charCodeAt(t))}function l(e,t,i){if(t=t||0,i=void 0===i?1/0:i||0,!o(e))return e.substr(t,i);var r=e.length;if(r<=0||t>r||i<=0)return"";var n=0;if(t>0){for(;t>0&&n<r;t--)n+=a(e,n);if(n>=r)return""}else if(t<0){for(n=r;t<0&&0<n;t++)n-=a(e,n-1);n<0&&(n=0)}var s=r;if(i<r)for(s=n;i>0&&s<r;i--)s+=a(e,s);return e.substring(n,s)}var c={getCodePoints:function(e){for(var t=[],i=0;i<e.length;i+=a(e,i))t.push(e.codePointAt(i));return t},getUTF16Length:a,hasSurrogateUnit:o,isCodeUnitInSurrogateRange:s,isSurrogatePair:function(e,t){if(0<=t&&t<e.length||r(!1),t+1===e.length)return!1;var i=e.charCodeAt(t),n=e.charCodeAt(t+1);return 55296<=i&&i<=56319&&56320<=n&&n<=57343},strlen:function(e){if(!o(e))return e.length;for(var t=0,i=0;i<e.length;i+=a(e,i))t++;return t},substring:function(e,t,i){(t=t||0)<0&&(t=0),(i=void 0===i?1/0:i||0)<0&&(i=0);var r=Math.abs(i-t);return l(e,t=t<i?t:i,r)},substr:l};e.exports=c},63390(e,t,i){"use strict";var r=i(9793),n=i(63504),s=i(27696),o=i(34398);function a(e,t,i,r){if(e===i)return!0;if(!i.startsWith(e))return!1;var s=i.slice(e.length);return!!t&&(s=r?r(s):s,n.contains(s,t))}function l(e){return"Windows"===r.platformName?e.replace(/^\s*NT/,""):e}var c={isBrowser:function(e){return a(r.browserName,r.browserFullVersion,e)},isBrowserArchitecture:function(e){return a(r.browserArchitecture,null,e)},isDevice:function(e){return a(r.deviceName,null,e)},isEngine:function(e){return a(r.engineName,r.engineVersion,e)},isPlatform:function(e){return a(r.platformName,r.platformFullVersion,e,l)},isPlatformArchitecture:function(e){return a(r.platformArchitecture,null,e)}};e.exports=s(c,o)},9793(e,t,i){"use strict";var r,n="Unknown",s=(new(i(17385))).getResult(),o=function(e){if(!e)return{major:"",minor:""};var t=e.split(".");return{major:t[0],minor:t[1]}}(s.browser.version),a={browserArchitecture:s.cpu.architecture||n,browserFullVersion:s.browser.version||n,browserMinorVersion:o.minor||n,browserName:s.browser.name||n,browserVersion:s.browser.major||n,deviceName:s.device.model||n,engineName:s.engine.name||n,engineVersion:s.engine.version||n,platformArchitecture:s.cpu.architecture||n,platformName:(r=s.os.name,{"Mac OS":"Mac OS X"}[r]||r||n),platformVersion:s.os.version||n,platformFullVersion:s.os.version||n};e.exports=a},63504(e,t,i){"use strict";var r=i(40041),n=/\./,s=/\|\|/,o=/\s+\-\s+/,a=/^(<=|<|=|>=|~>|~|>|)?\s*(.+)/,l=/^(\d*)(.*)/;function c(e,t){if(""===(e=e.trim()))return!0;var i,r=t.split(n),s=d(e),o=s.modifier,a=s.rangeComponents;switch(o){case"<":return u(r,a);case"<=":return-1===(i=C(r,a))||0===i;case">=":return h(r,a);case">":return 1===C(r,a);case"~":case"~>":return function(e,t){var i=t.slice(),r=t.slice();r.length>1&&r.pop();var n=r.length-1,s=parseInt(r[n],10);return p(s)&&(r[n]=s+1+""),h(e,i)&&u(e,r)}(r,a);default:return function(e,t){return 0===C(e,t)}(r,a)}}function u(e,t){return-1===C(e,t)}function h(e,t){var i=C(e,t);return 1===i||0===i}function d(e){var t=e.split(n),i=t[0].match(a);return i||r(!1),{modifier:i[1],rangeComponents:[i[2]].concat(t.slice(1))}}function p(e){return!isNaN(e)&&isFinite(e)}function g(e){return!d(e).modifier}function f(e,t){for(var i=e.length;i<t;i++)e[i]="0"}function m(e,t){var i=e.match(l)[1],r=t.match(l)[1],n=parseInt(i,10),s=parseInt(r,10);return p(n)&&p(s)&&n!==s?v(n,s):v(e,t)}function v(e,t){return typeof e!=typeof t&&r(!1),e>t?1:e<t?-1:0}function C(e,t){for(var i=function(e,t){f(e=e.slice(),(t=t.slice()).length);for(var i=0;i<t.length;i++){var r=t[i].match(/^[x*]$/i);if(r&&(t[i]=e[i]="0","*"===r[0]&&i===t.length-1))for(var n=i;n<e.length;n++)e[n]="0"}return f(t,e.length),[e,t]}(e,t),r=i[0],n=i[1],s=0;s<n.length;s++){var o=m(r[s],n[s]);if(o)return o}return 0}var y={contains:function(e,t){return function(e,t){var i=e.split(s);return i.length>1?i.some(function(e){return y.contains(e,t)}):function(e,t){var i=e.split(o);if(i.length>0&&i.length<=2||r(!1),1===i.length)return c(i[0],t);var n=i[0],s=i[1];return g(n)&&g(s)||r(!1),c(">="+n,t)&&c("<="+s,t)}(e=i[0].trim(),t)}(e.trim(),t.trim())}};e.exports=y},26797(e){"use strict";var t=/-(.)/g;e.exports=function(e){return e.replace(t,function(e,t){return t.toUpperCase()})}},68820(e,t,i){"use strict";var r=i(82366);e.exports=function e(t,i){return!(!t||!i)&&(t===i||!r(t)&&(r(i)?e(t,i.parentNode):"contains"in t?t.contains(i):!!t.compareDocumentPosition&&!!(16&t.compareDocumentPosition(i))))}},95573(e,t,i){"use strict";var r=i(40041);e.exports=function(e){return function(e){return!!e&&("object"==typeof e||"function"==typeof e)&&"length"in e&&!("setInterval"in e)&&"number"!=typeof e.nodeType&&(Array.isArray(e)||"callee"in e||"item"in e)}(e)?Array.isArray(e)?e.slice():function(e){var t=e.length;if((Array.isArray(e)||"object"!=typeof e&&"function"!=typeof e)&&r(!1),"number"!=typeof t&&r(!1),0===t||t-1 in e||r(!1),"function"==typeof e.callee&&r(!1),e.hasOwnProperty)try{return Array.prototype.slice.call(e)}catch(e){}for(var i=Array(t),n=0;n<t;n++)i[n]=e[n];return i}(e):[e]}},22978(e){"use strict";function t(e){return e.replace(/\//g,"-")}e.exports=function(e){return"object"==typeof e?Object.keys(e).filter(function(t){return e[t]}).map(t).join(" "):Array.prototype.map.call(arguments,t).join(" ")}},1948(e){"use strict";function t(e){return function(){return e}}var i=function(){};i.thatReturns=t,i.thatReturnsFalse=t(!1),i.thatReturnsTrue=t(!0),i.thatReturnsNull=t(null),i.thatReturnsThis=function(){return this},i.thatReturnsArgument=function(e){return e},e.exports=i},53967(e){"use strict";e.exports=function(e){if(void 0===(e=e||("undefined"!=typeof document?document:void 0)))return null;try{return e.activeElement||e.body}catch(t){return e.body}}},31709(e){"use strict";var t="undefined"!=typeof navigator&&navigator.userAgent.indexOf("AppleWebKit")>-1;e.exports=function(e){return(e=e||document).scrollingElement?e.scrollingElement:t||"CSS1Compat"!==e.compatMode?e.body:e.documentElement}},5026(e,t,i){"use strict";var r=i(25651);e.exports=function(e){var t=r(e);return{x:t.left,y:t.top,width:t.right-t.left,height:t.bottom-t.top}}},25651(e,t,i){"use strict";var r=i(68820);e.exports=function(e){var t=e.ownerDocument.documentElement;if(!("getBoundingClientRect"in e)||!r(t,e))return{left:0,right:0,top:0,bottom:0};var i=e.getBoundingClientRect();return{left:Math.round(i.left)-t.clientLeft,right:Math.round(i.right)-t.clientLeft,top:Math.round(i.top)-t.clientTop,bottom:Math.round(i.bottom)-t.clientTop}}},93987(e,t,i){"use strict";var r=i(31709),n=i(48031);e.exports=function(e){var t=r(e.ownerDocument||e.document);e.Window&&e instanceof e.Window&&(e=t);var i=n(e),s=e===t?e.ownerDocument.documentElement:e,o=e.scrollWidth-s.clientWidth,a=e.scrollHeight-s.clientHeight;return i.x=Math.max(0,Math.min(i.x,o)),i.y=Math.max(0,Math.min(i.y,a)),i}},54973(e,t,i){"use strict";var r=i(26797),n=i(24313);function s(e){return null==e?e:String(e)}e.exports=function(e,t){var i;if(window.getComputedStyle&&(i=window.getComputedStyle(e,null)))return s(i.getPropertyValue(n(t)));if(document.defaultView&&document.defaultView.getComputedStyle){if(i=document.defaultView.getComputedStyle(e,null))return s(i.getPropertyValue(n(t)));if("display"===t)return"none"}return e.currentStyle?s("float"===t?e.currentStyle.cssFloat||e.currentStyle.styleFloat:e.currentStyle[r(t)]):s(e.style&&e.style[r(t)])}},48031(e){"use strict";e.exports=function(e){return e.Window&&e instanceof e.Window?{x:e.pageXOffset||e.document.documentElement.scrollLeft,y:e.pageYOffset||e.document.documentElement.scrollTop}:{x:e.scrollLeft,y:e.scrollTop}}},68982(e){"use strict";function t(){var e;return document.documentElement&&(e=document.documentElement.clientWidth),!e&&document.body&&(e=document.body.clientWidth),e||0}function i(){var e;return document.documentElement&&(e=document.documentElement.clientHeight),!e&&document.body&&(e=document.body.clientHeight),e||0}function r(){return{width:window.innerWidth||t(),height:window.innerHeight||i()}}r.withoutScrollbars=function(){return{width:t(),height:i()}},e.exports=r},24313(e){"use strict";var t=/([A-Z])/g;e.exports=function(e){return e.replace(t,"-$1").toLowerCase()}},40041(e){"use strict";e.exports=function(e,t){for(var i=arguments.length,r=new Array(i>2?i-2:0),n=2;n<i;n++)r[n-2]=arguments[n];if(!e){var s;if(void 0===t)s=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var o=0;(s=new Error(t.replace(/%s/g,function(){return String(r[o++])}))).name="Invariant Violation"}throw s.framesToPop=1,s}}},38157(e){"use strict";e.exports=function(e){var t=(e?e.ownerDocument||e:document).defaultView||window;return!(!e||!("function"==typeof t.Node?e instanceof t.Node:"object"==typeof e&&"number"==typeof e.nodeType&&"string"==typeof e.nodeName))}},82366(e,t,i){"use strict";var r=i(38157);e.exports=function(e){return r(e)&&3==e.nodeType}},66145(e){"use strict";e.exports=function(e){var t=e||"",i=arguments.length;if(i>1)for(var r=1;r<i;r++){var n=arguments[r];n&&(t=(t?t+" ":"")+n)}return t}},27696(e){"use strict";var t=Object.prototype.hasOwnProperty;e.exports=function(e,i,r){if(!e)return null;var n={};for(var s in e)t.call(e,s)&&(n[s]=i.call(r,e[s],s,e));return n}},34398(e){"use strict";e.exports=function(e){var t={};return function(i){return t.hasOwnProperty(i)||(t[i]=e.call(this,i)),t[i]}}},25813(e){"use strict";e.exports=function(e){if(null!=e)return e;throw new Error("Got unexpected null or undefined")}},95136(e,t,i){"use strict";i(7921),e.exports=globalThis.setImmediate},92697(e,t,i){"use strict";var r=i(1948);e.exports=r},32016(e,t,i){"use strict";i.d(t,{$:()=>k});var r=Uint8Array,n=Uint16Array,s=Int32Array,o=new r([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),a=new r([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),l=new r([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),c=function(e,t){for(var i=new n(31),r=0;r<31;++r)i[r]=t+=1<<e[r-1];var o=new s(i[30]);for(r=1;r<30;++r)for(var a=i[r];a<i[r+1];++a)o[a]=a-i[r]<<5|r;return{b:i,r:o}},u=c(o,2),h=u.b,d=u.r;h[28]=258,d[258]=28;for(var p=c(a,0),g=(p.b,p.r),f=new n(32768),m=0;m<32768;++m){var v=(43690&m)>>1|(21845&m)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,f[m]=((65280&v)>>8|(255&v)<<8)>>1}var C=function(e,t,i){for(var r=e.length,s=0,o=new n(t);s<r;++s)e[s]&&++o[e[s]-1];var a,l=new n(t);for(s=1;s<t;++s)l[s]=l[s-1]+o[s-1]<<1;if(i){a=new n(1<<t);var c=15-t;for(s=0;s<r;++s)if(e[s])for(var u=s<<4|e[s],h=t-e[s],d=l[e[s]-1]++<<h,p=d|(1<<h)-1;d<=p;++d)a[f[d]>>c]=u}else for(a=new n(r),s=0;s<r;++s)e[s]&&(a[s]=f[l[e[s]-1]++]>>15-e[s]);return a},y=new r(288);for(m=0;m<144;++m)y[m]=8;for(m=144;m<256;++m)y[m]=9;for(m=256;m<280;++m)y[m]=7;for(m=280;m<288;++m)y[m]=8;var w=new r(32);for(m=0;m<32;++m)w[m]=5;var S=C(y,9,0),b=C(w,5,0),E=function(e){return(e+7)/8|0},A=function(e,t,i){i<<=7&t;var r=t/8|0;e[r]|=i,e[r+1]|=i>>8},T=function(e,t,i){i<<=7&t;var r=t/8|0;e[r]|=i,e[r+1]|=i>>8,e[r+2]|=i>>16},M=function(e,t){for(var i=[],s=0;s<e.length;++s)e[s]&&i.push({s,f:e[s]});var o=i.length,a=i.slice();if(!o)return{t:L,l:0};if(1==o){var l=new r(i[0].s+1);return l[i[0].s]=1,{t:l,l:1}}i.sort(function(e,t){return e.f-t.f}),i.push({s:-1,f:25001});var c=i[0],u=i[1],h=0,d=1,p=2;for(i[0]={s:-1,f:c.f+u.f,l:c,r:u};d!=o-1;)c=i[i[h].f<i[p].f?h++:p++],u=i[h!=d&&i[h].f<i[p].f?h++:p++],i[d++]={s:-1,f:c.f+u.f,l:c,r:u};var g=a[0].s;for(s=1;s<o;++s)a[s].s>g&&(g=a[s].s);var f=new n(g+1),m=R(i[d-1],f,0);if(m>t){s=0;var v=0,C=m-t,y=1<<C;for(a.sort(function(e,t){return f[t.s]-f[e.s]||e.f-t.f});s<o;++s){var w=a[s].s;if(!(f[w]>t))break;v+=y-(1<<m-f[w]),f[w]=t}for(v>>=C;v>0;){var S=a[s].s;f[S]<t?v-=1<<t-f[S]++-1:++s}for(;s>=0&&v;--s){var b=a[s].s;f[b]==t&&(--f[b],++v)}m=t}return{t:new r(f),l:m}},R=function(e,t,i){return-1==e.s?Math.max(R(e.l,t,i+1),R(e.r,t,i+1)):t[e.s]=i},_=function(e){for(var t=e.length;t&&!e[--t];);for(var i=new n(++t),r=0,s=e[0],o=1,a=function(e){i[r++]=e},l=1;l<=t;++l)if(e[l]==s&&l!=t)++o;else{if(!s&&o>2){for(;o>138;o-=138)a(32754);o>2&&(a(o>10?o-11<<5|28690:o-3<<5|12305),o=0)}else if(o>3){for(a(s),--o;o>6;o-=6)a(8304);o>2&&(a(o-3<<5|8208),o=0)}for(;o--;)a(s);o=1,s=e[l]}return{c:i.subarray(0,r),n:t}},P=function(e,t){for(var i=0,r=0;r<t.length;++r)i+=e[r]*t[r];return i},x=function(e,t,i){var r=i.length,n=E(t+2);e[n]=255&r,e[n+1]=r>>8,e[n+2]=255^e[n],e[n+3]=255^e[n+1];for(var s=0;s<r;++s)e[n+s+4]=i[s];return 8*(n+4+r)},D=function(e,t,i,r,s,c,u,h,d,p,g){A(t,g++,i),++s[256];for(var f=M(s,15),m=f.t,v=f.l,E=M(c,15),R=E.t,D=E.l,I=_(m),L=I.c,N=I.n,O=_(R),F=O.c,k=O.n,G=new n(19),V=0;V<L.length;++V)++G[31&L[V]];for(V=0;V<F.length;++V)++G[31&F[V]];for(var H=M(G,7),B=H.t,z=H.l,U=19;U>4&&!B[l[U-1]];--U);var W,j,K,$,q=p+5<<3,Y=P(s,y)+P(c,w)+u,Q=P(s,m)+P(c,R)+u+14+3*U+P(G,B)+2*G[16]+3*G[17]+7*G[18];if(d>=0&&q<=Y&&q<=Q)return x(t,g,e.subarray(d,d+p));if(A(t,g,1+(Q<Y)),g+=2,Q<Y){W=C(m,v,0),j=m,K=C(R,D,0),$=R;var X=C(B,z,0);for(A(t,g,N-257),A(t,g+5,k-1),A(t,g+10,U-4),g+=14,V=0;V<U;++V)A(t,g+3*V,B[l[V]]);g+=3*U;for(var Z=[L,F],J=0;J<2;++J){var ee=Z[J];for(V=0;V<ee.length;++V){var te=31&ee[V];A(t,g,X[te]),g+=B[te],te>15&&(A(t,g,ee[V]>>5&127),g+=ee[V]>>12)}}}else W=S,j=y,K=b,$=w;for(V=0;V<h;++V){var ie=r[V];if(ie>255){T(t,g,W[257+(te=ie>>18&31)]),g+=j[te+257],te>7&&(A(t,g,ie>>23&31),g+=o[te]);var re=31&ie;T(t,g,K[re]),g+=$[re],re>3&&(T(t,g,ie>>5&8191),g+=a[re])}else T(t,g,W[ie]),g+=j[ie]}return T(t,g,W[256]),g+j[256]},I=new s([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),L=new r(0),N=function(e,t,i,l,c,u){var h=u.z||e.length,p=new r(l+h+5*(1+Math.ceil(h/7e3))+c),f=p.subarray(l,p.length-c),m=u.l,v=7&(u.r||0);if(t){v&&(f[0]=u.r>>3);for(var C=I[t-1],y=C>>13,w=8191&C,S=(1<<i)-1,b=u.p||new n(32768),A=u.h||new n(S+1),T=Math.ceil(i/3),M=2*T,R=function(t){return(e[t]^e[t+1]<<T^e[t+2]<<M)&S},_=new s(25e3),P=new n(288),L=new n(32),N=0,O=0,F=u.i||0,k=0,G=u.w||0,V=0;F+2<h;++F){var H=R(F),B=32767&F,z=A[H];if(b[B]=z,A[H]=B,G<=F){var U=h-F;if((N>7e3||k>24576)&&(U>423||!m)){v=D(e,f,0,_,P,L,O,k,V,F-V,v),k=N=O=0,V=F;for(var W=0;W<286;++W)P[W]=0;for(W=0;W<30;++W)L[W]=0}var j=2,K=0,$=w,q=B-z&32767;if(U>2&&H==R(F-q))for(var Y=Math.min(y,U)-1,Q=Math.min(32767,F),X=Math.min(258,U);q<=Q&&--$&&B!=z;){if(e[F+j]==e[F+j-q]){for(var Z=0;Z<X&&e[F+Z]==e[F+Z-q];++Z);if(Z>j){if(j=Z,K=q,Z>Y)break;var J=Math.min(q,Z-2),ee=0;for(W=0;W<J;++W){var te=F-q+W&32767,ie=te-b[te]&32767;ie>ee&&(ee=ie,z=te)}}}q+=(B=z)-(z=b[B])&32767}if(K){_[k++]=268435456|d[j]<<18|g[K];var re=31&d[j],ne=31&g[K];O+=o[re]+a[ne],++P[257+re],++L[ne],G=F+j,++N}else _[k++]=e[F],++P[e[F]]}}for(F=Math.max(F,G);F<h;++F)_[k++]=e[F],++P[e[F]];v=D(e,f,m,_,P,L,O,k,V,F-V,v),m||(u.r=7&v|f[v/8|0]<<3,v-=7,u.h=A,u.p=b,u.i=F,u.w=G)}else{for(F=u.w||0;F<h+m;F+=65535){var se=F+65535;se>=h&&(f[v/8|0]=m,se=h),v=x(f,v+1,e.subarray(F,se))}u.i=h}return function(e,t,i){return(null==t||t<0)&&(t=0),(null==i||i>e.length)&&(i=e.length),new r(e.subarray(t,i))}(p,0,l+E(v)+c)},O=function(){var e=1,t=0;return{p:function(i){for(var r=e,n=t,s=0|i.length,o=0;o!=s;){for(var a=Math.min(o+2655,s);o<a;++o)n+=r+=i[o];r=(65535&r)+15*(r>>16),n=(65535&n)+15*(n>>16)}e=r,t=n},d:function(){return(255&(e%=65521))<<24|(65280&e)<<8|(255&(t%=65521))<<8|t>>8}}},F=function(e,t,i){for(;i;++t)e[t]=i,i>>>=8};function k(e,t){t||(t={});var i=O();i.p(e);var n=function(e,t,i,n,s){if(!s&&(s={l:1},t.dictionary)){var o=t.dictionary.subarray(-32768),a=new r(o.length+e.length);a.set(o),a.set(e,o.length),e=a,s.w=o.length}return N(e,null==t.level?6:t.level,null==t.mem?s.l?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(e.length)))):20:12+t.mem,i,n,s)}(e,t,t.dictionary?6:2,4);return function(e,t){var i=t.level,r=0==i?0:i<6?1:9==i?3:2;if(e[0]=120,e[1]=r<<6|(t.dictionary&&32),e[1]|=31-(e[0]<<8|e[1])%31,t.dictionary){var n=O();n.p(t.dictionary),F(e,2,n.d())}}(n,t),F(n,n.length-4,i.d()),n}var G="undefined"!=typeof TextDecoder&&new TextDecoder;try{G.decode(L,{stream:!0})}catch(e){}"function"==typeof queueMicrotask?queueMicrotask:"function"==typeof setTimeout&&setTimeout},45792(e,t,i){"use strict";i.d(t,{R:()=>a});var r=i(65959),n=new Map([["aac","audio/aac"],["abw","application/x-abiword"],["arc","application/x-freearc"],["avif","image/avif"],["avi","video/x-msvideo"],["azw","application/vnd.amazon.ebook"],["bin","application/octet-stream"],["bmp","image/bmp"],["bz","application/x-bzip"],["bz2","application/x-bzip2"],["cda","application/x-cdf"],["csh","application/x-csh"],["css","text/css"],["csv","text/csv"],["doc","application/msword"],["docx","application/vnd.openxmlformats-officedocument.wordprocessingml.document"],["eot","application/vnd.ms-fontobject"],["epub","application/epub+zip"],["gz","application/gzip"],["gif","image/gif"],["htm","text/html"],["html","text/html"],["ico","image/vnd.microsoft.icon"],["ics","text/calendar"],["jar","application/java-archive"],["jpeg","image/jpeg"],["jpg","image/jpeg"],["js","text/javascript"],["json","application/json"],["jsonld","application/ld+json"],["mid","audio/midi"],["midi","audio/midi"],["mjs","text/javascript"],["mp3","audio/mpeg"],["mp4","video/mp4"],["mpeg","video/mpeg"],["mpkg","application/vnd.apple.installer+xml"],["odp","application/vnd.oasis.opendocument.presentation"],["ods","application/vnd.oasis.opendocument.spreadsheet"],["odt","application/vnd.oasis.opendocument.text"],["oga","audio/ogg"],["ogv","video/ogg"],["ogx","application/ogg"],["opus","audio/opus"],["otf","font/otf"],["png","image/png"],["pdf","application/pdf"],["php","application/x-httpd-php"],["ppt","application/vnd.ms-powerpoint"],["pptx","application/vnd.openxmlformats-officedocument.presentationml.presentation"],["rar","application/vnd.rar"],["rtf","application/rtf"],["sh","application/x-sh"],["svg","image/svg+xml"],["swf","application/x-shockwave-flash"],["tar","application/x-tar"],["tif","image/tiff"],["tiff","image/tiff"],["ts","video/mp2t"],["ttf","font/ttf"],["txt","text/plain"],["vsd","application/vnd.visio"],["wav","audio/wav"],["weba","audio/webm"],["webm","video/webm"],["webp","image/webp"],["woff","font/woff"],["woff2","font/woff2"],["xhtml","application/xhtml+xml"],["xls","application/vnd.ms-excel"],["xlsx","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"],["xml","application/xml"],["xul","application/vnd.mozilla.xul+xml"],["zip","application/zip"],["7z","application/x-7z-compressed"],["mkv","video/x-matroska"],["mov","video/quicktime"],["msg","application/vnd.ms-outlook"]]);function s(e,t){var i=function(e){var t=e.name;if(t&&-1!==t.lastIndexOf(".")&&!e.type){var i=t.split(".").pop().toLowerCase(),r=n.get(i);r&&Object.defineProperty(e,"type",{value:r,writable:!1,configurable:!1,enumerable:!0})}return e}(e);if("string"!=typeof i.path){var r=e.webkitRelativePath;Object.defineProperty(i,"path",{value:"string"==typeof t?t:"string"==typeof r&&r.length>0?r:e.name,writable:!1,configurable:!1,enumerable:!0})}return i}var o=[".DS_Store","Thumbs.db"];function a(e){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(t){return l(e)&&l(e.dataTransfer)?[2,h(e.dataTransfer,e.type)]:l(i=e)&&l(i.target)?[2,c(e)]:Array.isArray(e)&&e.every(function(e){return"getFile"in e&&"function"==typeof e.getFile})?[2,u(e)]:[2,[]];var i})})}function l(e){return"object"==typeof e&&null!==e}function c(e){return p(e.target.files).map(function(e){return s(e)})}function u(e){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(t){switch(t.label){case 0:return[4,Promise.all(e.map(function(e){return e.getFile()}))];case 1:return[2,t.sent().map(function(e){return s(e)})]}})})}function h(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){var i;return(0,r.__generator)(this,function(r){switch(r.label){case 0:return null===e?[2,[]]:e.items?(i=p(e.items).filter(function(e){return"file"===e.kind}),"drop"!==t?[2,i]:[4,Promise.all(i.map(g))]):[3,2];case 1:return[2,d(f(r.sent()))];case 2:return[2,d(p(e.files).map(function(e){return s(e)}))]}})})}function d(e){return e.filter(function(e){return-1===o.indexOf(e.name)})}function p(e){if(null===e)return[];for(var t=[],i=0;i<e.length;i++){var r=e[i];t.push(r)}return t}function g(e){if("function"!=typeof e.webkitGetAsEntry)return m(e);var t=e.webkitGetAsEntry();return t&&t.isDirectory?C(t):m(e)}function f(e){return e.reduce(function(e,t){return(0,r.__spread)(e,Array.isArray(t)?f(t):[t])},[])}function m(e){var t=e.getAsFile();if(!t)return Promise.reject(e+" is not a File");var i=s(t);return Promise.resolve(i)}function v(e){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(t){return[2,e.isDirectory?C(e):y(e)]})})}function C(e){var t=e.createReader();return new Promise(function(e,i){var n=[];!function s(){var o=this;t.readEntries(function(t){return(0,r.__awaiter)(o,void 0,void 0,function(){var o,a,l;return(0,r.__generator)(this,function(r){switch(r.label){case 0:if(t.length)return[3,5];r.label=1;case 1:return r.trys.push([1,3,,4]),[4,Promise.all(n)];case 2:return o=r.sent(),e(o),[3,4];case 3:return a=r.sent(),i(a),[3,4];case 4:return[3,6];case 5:l=Promise.all(t.map(v)),n.push(l),s(),r.label=6;case 6:return[2]}})})},function(e){i(e)})}()})}function y(e){return(0,r.__awaiter)(this,void 0,void 0,function(){return(0,r.__generator)(this,function(t){return[2,new Promise(function(t,i){e.file(function(i){var r=s(i,e.fullPath);t(r)},function(e){i(e)})})]})})}},21702(e){"use strict";e.exports=function(e,t){for(var i={},r=Object.keys(e),n=Array.isArray(t),s=0;s<r.length;s++){var o=r[s],a=e[o];(n?-1!==t.indexOf(o):t(o,a,e))&&(i[o]=a)}return i}},87196(e,t,i){"use strict";var r=i(22956),n=Object.prototype.toString,s=Object.prototype.hasOwnProperty;e.exports=function(e,t,i){if(!r(t))throw new TypeError("iterator must be a function");var o,a;arguments.length>=3&&(o=i),a=e,"[object Array]"===n.call(a)?function(e,t,i){for(var r=0,n=e.length;r<n;r++)s.call(e,r)&&(null==i?t(e[r],r,e):t.call(i,e[r],r,e))}(e,t,o):"string"==typeof e?function(e,t,i){for(var r=0,n=e.length;r<n;r++)null==i?t(e.charAt(r),r,e):t.call(i,e.charAt(r),r,e)}(e,t,o):function(e,t,i){for(var r in e)s.call(e,r)&&(null==i?t(e[r],r,e):t.call(i,e[r],r,e))}(e,t,o)}},69992(e){"use strict";var t=Object.prototype.toString,i=Math.max,r=function(e,t){for(var i=[],r=0;r<e.length;r+=1)i[r]=e[r];for(var n=0;n<t.length;n+=1)i[n+e.length]=t[n];return i};e.exports=function(e){var n=this;if("function"!=typeof n||"[object Function]"!==t.apply(n))throw new TypeError("Function.prototype.bind called on incompatible "+n);for(var s,o=function(e){for(var t=[],i=1,r=0;i<e.length;i+=1,r+=1)t[r]=e[i];return t}(arguments),a=i(0,n.length-o.length),l=[],c=0;c<a;c++)l[c]="$"+c;if(s=Function("binder","return function ("+function(e){for(var t="",i=0;i<e.length;i+=1)t+=e[i],i+1<e.length&&(t+=",");return t}(l)+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof s){var t=n.apply(this,r(o,arguments));return Object(t)===t?t:this}return n.apply(e,r(o,arguments))}),n.prototype){var u=function(){};u.prototype=n.prototype,s.prototype=new u,u.prototype=null}return s}},79524(e,t,i){"use strict";var r=i(69992);e.exports=Function.prototype.bind||r},18910(e,t,i){e.exports=i(21923)},21923(e,t,i){var r,n,s=i(24215),o=function(){(void 0===r||r>=n.length)&&(r=0,n=s.randomBytes(256));var e=n[r];return r+=1,e},a=function(e){for(var t=o();t>=256-256%e;)t=o();return t%e},l=/[ilLI|`oO0]/g,c=[{name:"lowercase",rule:/[a-z]/},{name:"uppercase",rule:/[A-Z]/},{name:"numbers",rule:/[0-9]/},{name:"symbols",rule:/[!@#$%^&*()+_\-=}{[\]|:;"/?.><,`~]/}],u=function(e,t){for(var i="",r=e.length,n=t.length,s=0;s<r;s++)i+=t[a(n)];return e.strict&&!c.every(function(t){return 0==e[t.name]||("symbols"===t.name&&"string"==typeof e[t.name]?new RegExp("["+e[t.name]+"]").test(i):t.rule.test(i))})?u(e,t):i};e.exports.generate=function(e){if(e=e||{},Object.prototype.hasOwnProperty.call(e,"length")||(e.length=10),Object.prototype.hasOwnProperty.call(e,"numbers")||(e.numbers=!1),Object.prototype.hasOwnProperty.call(e,"symbols")||(e.symbols=!1),Object.prototype.hasOwnProperty.call(e,"exclude")||(e.exclude=""),Object.prototype.hasOwnProperty.call(e,"uppercase")||(e.uppercase=!0),Object.prototype.hasOwnProperty.call(e,"lowercase")||(e.lowercase=!0),Object.prototype.hasOwnProperty.call(e,"excludeSimilarCharacters")||(e.excludeSimilarCharacters=!1),Object.prototype.hasOwnProperty.call(e,"strict")||(e.strict=!1),e.strict&&1+(e.numbers?1:0)+(e.symbols?1:0)+(e.uppercase?1:0)>e.length)throw new TypeError("Length must correlate with strict guidelines");var t="";if(e.lowercase&&(t+="abcdefghijklmnopqrstuvwxyz"),e.uppercase&&(t+="ABCDEFGHIJKLMNOPQRSTUVWXYZ"),e.numbers&&(t+="0123456789"),e.symbols&&("string"==typeof e.symbols?t+=e.symbols:t+='!@#$%^&*()+_-=}{[]|:;"/?.><,`~'),!t)throw new TypeError("At least one rule for pools must be true");e.excludeSimilarCharacters&&(t=t.replace(l,""));for(var i=e.exclude.length;i--;)t=t.replace(e.exclude[i],"");return u(e,t)},e.exports.generateMultiple=function(t,i){for(var r=[],n=0;n<t;n++)r[n]=e.exports.generate(i);return r}},49336(e,t,i){"use strict";var r,n=i(25153),s=i(41488),o=i(38004),a=i(96469),l=i(12557),c=i(63429),u=i(71102),h=i(85966),d=i(77412),p=i(52418),g=i(57958),f=i(47384),m=i(250),v=i(51844),C=i(47279),y=Function,w=function(e){try{return y('"use strict"; return ('+e+").constructor;")()}catch(e){}},S=i(25667),b=i(39886),E=function(){throw new u},A=S?function(){try{return E}catch(e){try{return S(arguments,"callee").get}catch(e){return E}}}():E,T=i(21514)(),M=i(14252),R=i(23752),_=i(60248),P=i(64811),x=i(46255),D={},I="undefined"!=typeof Uint8Array&&M?M(Uint8Array):r,L={__proto__:null,"%AggregateError%":"undefined"==typeof AggregateError?r:AggregateError,"%Array%":Array,"%ArrayBuffer%":"undefined"==typeof ArrayBuffer?r:ArrayBuffer,"%ArrayIteratorPrototype%":T&&M?M([][Symbol.iterator]()):r,"%AsyncFromSyncIteratorPrototype%":r,"%AsyncFunction%":D,"%AsyncGenerator%":D,"%AsyncGeneratorFunction%":D,"%AsyncIteratorPrototype%":D,"%Atomics%":"undefined"==typeof Atomics?r:Atomics,"%BigInt%":"undefined"==typeof BigInt?r:BigInt,"%BigInt64Array%":"undefined"==typeof BigInt64Array?r:BigInt64Array,"%BigUint64Array%":"undefined"==typeof BigUint64Array?r:BigUint64Array,"%Boolean%":Boolean,"%DataView%":"undefined"==typeof DataView?r:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":s,"%eval%":eval,"%EvalError%":o,"%Float16Array%":"undefined"==typeof Float16Array?r:Float16Array,"%Float32Array%":"undefined"==typeof Float32Array?r:Float32Array,"%Float64Array%":"undefined"==typeof Float64Array?r:Float64Array,"%FinalizationRegistry%":"undefined"==typeof FinalizationRegistry?r:FinalizationRegistry,"%Function%":y,"%GeneratorFunction%":D,"%Int8Array%":"undefined"==typeof Int8Array?r:Int8Array,"%Int16Array%":"undefined"==typeof Int16Array?r:Int16Array,"%Int32Array%":"undefined"==typeof Int32Array?r:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":T&&M?M(M([][Symbol.iterator]())):r,"%JSON%":"object"==typeof JSON?JSON:r,"%Map%":"undefined"==typeof Map?r:Map,"%MapIteratorPrototype%":"undefined"!=typeof Map&&T&&M?M((new Map)[Symbol.iterator]()):r,"%Math%":Math,"%Number%":Number,"%Object%":n,"%Object.getOwnPropertyDescriptor%":S,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":"undefined"==typeof Promise?r:Promise,"%Proxy%":"undefined"==typeof Proxy?r:Proxy,"%RangeError%":a,"%ReferenceError%":l,"%Reflect%":"undefined"==typeof Reflect?r:Reflect,"%RegExp%":RegExp,"%Set%":"undefined"==typeof Set?r:Set,"%SetIteratorPrototype%":"undefined"!=typeof Set&&T&&M?M((new Set)[Symbol.iterator]()):r,"%SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?r:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":T&&M?M(""[Symbol.iterator]()):r,"%Symbol%":T?Symbol:r,"%SyntaxError%":c,"%ThrowTypeError%":A,"%TypedArray%":I,"%TypeError%":u,"%Uint8Array%":"undefined"==typeof Uint8Array?r:Uint8Array,"%Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?r:Uint8ClampedArray,"%Uint16Array%":"undefined"==typeof Uint16Array?r:Uint16Array,"%Uint32Array%":"undefined"==typeof Uint32Array?r:Uint32Array,"%URIError%":h,"%WeakMap%":"undefined"==typeof WeakMap?r:WeakMap,"%WeakRef%":"undefined"==typeof WeakRef?r:WeakRef,"%WeakSet%":"undefined"==typeof WeakSet?r:WeakSet,"%Function.prototype.call%":x,"%Function.prototype.apply%":P,"%Object.defineProperty%":b,"%Object.getPrototypeOf%":R,"%Math.abs%":d,"%Math.floor%":p,"%Math.max%":g,"%Math.min%":f,"%Math.pow%":m,"%Math.round%":v,"%Math.sign%":C,"%Reflect.getPrototypeOf%":_};if(M)try{null.error}catch(e){var N=M(M(e));L["%Error.prototype%"]=N}var O=function e(t){var i;if("%AsyncFunction%"===t)i=w("async function () {}");else if("%GeneratorFunction%"===t)i=w("function* () {}");else if("%AsyncGeneratorFunction%"===t)i=w("async function* () {}");else if("%AsyncGenerator%"===t){var r=e("%AsyncGeneratorFunction%");r&&(i=r.prototype)}else if("%AsyncIteratorPrototype%"===t){var n=e("%AsyncGenerator%");n&&M&&(i=M(n.prototype))}return L[t]=i,i},F={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},k=i(79524),G=i(75630),V=k.call(x,Array.prototype.concat),H=k.call(P,Array.prototype.splice),B=k.call(x,String.prototype.replace),z=k.call(x,String.prototype.slice),U=k.call(x,RegExp.prototype.exec),W=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,j=/\\(\\)?/g,K=function(e,t){var i,r=e;if(G(F,r)&&(r="%"+(i=F[r])[0]+"%"),G(L,r)){var n=L[r];if(n===D&&(n=O(r)),void 0===n&&!t)throw new u("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:i,name:r,value:n}}throw new c("intrinsic "+e+" does not exist!")};e.exports=function(e,t){if("string"!=typeof e||0===e.length)throw new u("intrinsic name must be a non-empty string");if(arguments.length>1&&"boolean"!=typeof t)throw new u('"allowMissing" argument must be a boolean');if(null===U(/^%?[^%]*%?$/,e))throw new c("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var i=function(e){var t=z(e,0,1),i=z(e,-1);if("%"===t&&"%"!==i)throw new c("invalid intrinsic syntax, expected closing `%`");if("%"===i&&"%"!==t)throw new c("invalid intrinsic syntax, expected opening `%`");var r=[];return B(e,W,function(e,t,i,n){r[r.length]=i?B(n,j,"$1"):t||e}),r}(e),r=i.length>0?i[0]:"",n=K("%"+r+"%",t),s=n.name,o=n.value,a=!1,l=n.alias;l&&(r=l[0],H(i,V([0,1],l)));for(var h=1,d=!0;h<i.length;h+=1){var p=i[h],g=z(p,0,1),f=z(p,-1);if(('"'===g||"'"===g||"`"===g||'"'===f||"'"===f||"`"===f)&&g!==f)throw new c("property names with quotes must have matching quotes");if("constructor"!==p&&d||(a=!0),G(L,s="%"+(r+="."+p)+"%"))o=L[s];else if(null!=o){if(!(p in o)){if(!t)throw new u("base intrinsic for "+e+" exists, but the property is not available.");return}if(S&&h+1>=i.length){var m=S(o,p);o=(d=!!m)&&"get"in m&&!("originalValue"in m.get)?m.get:o[p]}else d=G(o,p),o=o[p];d&&!a&&(L[s]=o)}}return o}},23752(e,t,i){"use strict";var r=i(25153);e.exports=r.getPrototypeOf||null},60248(e){"use strict";e.exports="undefined"!=typeof Reflect&&Reflect.getPrototypeOf||null},14252(e,t,i){"use strict";var r=i(60248),n=i(23752),s=i(57678);e.exports=r?function(e){return r(e)}:n?function(e){if(!e||"object"!=typeof e&&"function"!=typeof e)throw new TypeError("getProto: not an object");return n(e)}:s?function(e){return s(e)}:null},2013(e){var t;t="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},e.exports=t},29530(e){var t,i,r,n,s,o;function a(e,t,i,r,n,s){var o,a,l,c,u,h,d,p,g,f,m,v,C,y;for(g=0;g<s;g++){for(d=g,p=0,c=u=(o=e[h=g*n])*r[6],m=r[0],v=r[1],C=r[4],y=r[5],f=0;f<n;f++)l=(a=e[h])*m+o*v+c*C+u*y,u=c,c=l,o=a,i[p]=c,p++,h++;for(p--,d+=s*(n-1),c=u=(o=e[--h])*r[7],a=o,m=r[2],v=r[3],f=n-1;f>=0;f--)l=a*m+o*v+c*C+u*y,u=c,c=l,o=a,a=e[h],t[d]=i[p]+c,h--,p--,d-=s}}e.exports=function(e,l,c,u){if(u){var h=new Uint16Array(e.length),d=new Float32Array(Math.max(l,c)),p=function(e){e<.5&&(e=.5);var a=Math.exp(.527076)/e,l=Math.exp(-a),c=Math.exp(-2*a),u=(1-l)*(1-l)/(1+2*a*l-c);return t=u,i=u*(a-1)*l,r=u*(a+1)*l,n=-u*c,s=2*l,o=-c,new Float32Array([t,i,r,n,s,o,(t+i)/(1-s-o),(r+n)/(1-s-o)])}(u);a(e,h,d,p,l,c),a(h,e,d,p,c,l)}}},51333(e){"use strict";e.exports=Object.getOwnPropertyDescriptor},25667(e,t,i){"use strict";var r=i(51333);if(r)try{r([],"length")}catch(e){r=null}e.exports=r},767(e,t,i){"use strict";i.r(t)},82022(e,t,i){"use strict";i.r(t)},24387(e,t,i){"use strict";i.r(t)},47114(e){function t(){return e.exports=t=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)({}).hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},e.exports.__esModule=!0,e.exports.default=e.exports,t.apply(null,arguments)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},44898(e){e.exports=function(e){return e&&e.__esModule?e:{default:e}},e.exports.__esModule=!0,e.exports.default=e.exports},24737(e,t,i){var r=i(41930).default;function n(t,i){if("function"==typeof WeakMap)var s=new WeakMap,o=new WeakMap;return(e.exports=n=function(e,t){if(!t&&e&&e.__esModule)return e;var i,n,a={__proto__:null,default:e};if(null===e||"object"!=r(e)&&"function"!=typeof e)return a;if(i=t?o:s){if(i.has(e))return i.get(e);i.set(e,a)}for(var l in e)"default"!==l&&{}.hasOwnProperty.call(e,l)&&((n=(i=Object.defineProperty)&&Object.getOwnPropertyDescriptor(e,l))&&(n.get||n.set)?i(a,l,n):a[l]=e[l]);return a},e.exports.__esModule=!0,e.exports.default=e.exports)(t,i)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports},49613(e){e.exports=function(e,t){if(null==e)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;i[r]=e[r]}return i},e.exports.__esModule=!0,e.exports.default=e.exports},41930(e){function t(i){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(i)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},57506(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CompositeRootContext=void 0,t.useCompositeRootContext=function(e=!1){const t=r.useContext(s);if(void 0===t&&!e)throw new Error("Base UI: CompositeRootContext is missing. Composite parts must be placed within <Composite.Root>.");return t};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=t.CompositeRootContext=r.createContext(void 0)},53079(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DirectionContext=void 0,t.useDirection=function(e=!0){const t=r.useContext(s);if(void 0===t&&!e)throw new Error("Base UI: DirectionContext is missing.");return t?.direction??"ltr"};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=t.DirectionContext=r.createContext(void 0)},80725(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(19571);Object.keys(r).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===r[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return r[e]}}))})},19571(e,t){"use strict";function i(e,t){return n(e)?e(t):e??{}}function r(e,t){return t?e?Object.entries(t).reduce((t,[i,r])=>{var n,o,a,l;return function(e,t){const i=e.charCodeAt(2);return"o"===e[0]&&"n"===e[1]&&i>=65&&i<=90&&"function"==typeof t}(i,r)?t[i]=(n=e[i],o=r,e=>{if(function(e){return null!=e&&"object"==typeof e&&"nativeEvent"in e}(e)){const t=e;s(t);const i=o(t);return t.baseUIHandlerPrevented||n?.(t),i}const t=o(e);return n?.(e),t}):t[i]="style"===i?function(e,t){if(t||e)return{...e,...t}}(e.style,r):"className"===i?(a=e.className,(l=r)?a?l+" "+a:l:a):r,t},{...e}):t:e||{}}function n(e){return"function"==typeof e}function s(e){return e.preventBaseUIHandler=()=>{e.baseUIHandlerPrevented=!0},e}Object.defineProperty(t,"__esModule",{value:!0}),t.makeEventPreventable=s,t.mergeProps=function(...e){if(0===e.length)return{};if(1===e.length)return i(e[0],{});let t=i(e[0],{});for(let i=1;i<e.length;i+=1){const s=e[i];s&&(t=n(s)?s(t):r(t,s))}return t??{}}},85607(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverArrow=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(14434)),o=i(4706),a=i(72204),l=i(13214);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}t.PopoverArrow=n.forwardRef(function(e,t){const{className:i,render:r,...c}=e,{open:u}=(0,o.usePopoverRootContext)(),{arrowRef:h,side:d,align:p,arrowUncentered:g,arrowStyles:f}=(0,s.usePopoverPositionerContext)(),m=n.useMemo(()=>({open:u,side:d,align:p,uncentered:g}),[u,d,p,g]);return(0,l.useRenderElement)("div",e,{state:m,ref:[t,h],props:[{style:f,"aria-hidden":!0},c],customStyleHookMapping:a.popupStateMapping})()})},30509(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverBackdrop=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(72204),a=i(60687),l=i(13214);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}const u={...o.popupStateMapping,...a.transitionStatusMapping};t.PopoverBackdrop=n.forwardRef(function(e,t){const{className:i,render:r,...o}=e,{open:a,mounted:c,transitionStatus:h,openReason:d}=(0,s.usePopoverRootContext)(),p=n.useMemo(()=>({open:a,transitionStatus:h}),[a,h]);return(0,l.useRenderElement)("div",e,{state:p,ref:t,props:[{role:"presentation",hidden:!c,style:{pointerEvents:"hover"===d?"none":void 0,userSelect:"none",WebkitUserSelect:"none"}},o],customStyleHookMapping:u})()})},89101(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverClose=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(13214);function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}t.PopoverClose=n.forwardRef(function(e,t){const{render:i,className:r,...n}=e,{setOpen:a}=(0,s.usePopoverRootContext)();return(0,o.useRenderElement)("button",e,{ref:t,props:[{onClick(){a(!1,void 0,void 0)}},n]})()})},36253(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverDescription=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(26111),a=i(322),l=i(13214);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}t.PopoverDescription=n.forwardRef(function(e,t){const{render:i,className:r,...n}=e,{setDescriptionId:c}=(0,s.usePopoverRootContext)(),u=(0,a.useBaseUiId)(n.id);return(0,o.useEnhancedEffect)(()=>(c(u),()=>{c(void 0)}),[c,u]),(0,l.useRenderElement)("p",e,{ref:t,props:[{id:u},n]})()})},17051(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Popover=void 0;var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(41507));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}t.Popover=r},41507(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Arrow",{enumerable:!0,get:function(){return l.PopoverArrow}}),Object.defineProperty(t,"Backdrop",{enumerable:!0,get:function(){return c.PopoverBackdrop}}),Object.defineProperty(t,"Close",{enumerable:!0,get:function(){return d.PopoverClose}}),Object.defineProperty(t,"Description",{enumerable:!0,get:function(){return h.PopoverDescription}}),Object.defineProperty(t,"Popup",{enumerable:!0,get:function(){return a.PopoverPopup}}),Object.defineProperty(t,"Portal",{enumerable:!0,get:function(){return s.PopoverPortal}}),Object.defineProperty(t,"Positioner",{enumerable:!0,get:function(){return o.PopoverPositioner}}),Object.defineProperty(t,"Root",{enumerable:!0,get:function(){return r.PopoverRoot}}),Object.defineProperty(t,"Title",{enumerable:!0,get:function(){return u.PopoverTitle}}),Object.defineProperty(t,"Trigger",{enumerable:!0,get:function(){return n.PopoverTrigger}});var r=i(1881),n=i(4905),s=i(12309),o=i(53049),a=i(97069),l=i(85607),c=i(30509),u=i(63317),h=i(36253),d=i(89101)},97069(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverPopup=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(6358)),o=i(4706),a=i(14434),l=i(66476),c=i(72204),u=(i(10389),i(60687)),h=i(65635),d=i(13214),p=i(65723);function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}const f={...c.popupStateMapping,...u.transitionStatusMapping};t.PopoverPopup=n.forwardRef(function(e,t){const{className:i,render:r,initialFocus:c,finalFocus:u,...g}=e,{open:m,instantType:v,transitionStatus:C,getPopupProps:y,titleId:w,descriptionId:S,popupRef:b,mounted:E,openReason:A,onOpenChangeComplete:T,modal:M}=(0,o.usePopoverRootContext)(),R=(0,a.usePopoverPositionerContext)();(0,h.useOpenChangeComplete)({open:m,ref:b,onComplete(){m&&T?.(!0)}});const{props:_,resolvedInitialFocus:P}=(0,l.usePopoverPopup)({titleId:w,descriptionId:S,initialFocus:c}),x=n.useMemo(()=>({open:m,side:R.side,align:R.align,instant:v,transitionStatus:C}),[m,R.side,R.align,v,C]),D=(0,d.useRenderElement)("div",e,{state:x,ref:[t,b],props:[_,y,{style:"starting"===C?{transition:"none"}:{}},g],customStyleHookMapping:f});return(0,p.jsx)(s.FloatingFocusManager,{context:R.context,modal:"trap-focus"===M,disabled:!E||"hover"===A,initialFocus:P,returnFocus:u,children:D()})})},66476(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.usePopoverPopup=function(e){const{titleId:t,descriptionId:i,initialFocus:s}=e,{popupRef:o,openMethod:a}=(0,n.usePopoverRootContext)(),l=r.useMemo(()=>({"aria-labelledby":t,"aria-describedby":i}),[t,i]),c=r.useCallback(e=>"touch"===e?o:0,[o]),u=r.useMemo(()=>null==s?c(a??""):"function"==typeof s?s(a??""):s,[c,s,a]);return r.useMemo(()=>({props:l,resolvedInitialFocus:u}),[l,u])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(4706);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},12309(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverPortal=function(e){const{children:t,keepMounted:i=!1,container:r}=e,{mounted:l}=(0,s.usePopoverRootContext)();return l||i?(0,a.jsx)(o.PopoverPortalContext.Provider,{value:i,children:(0,a.jsx)(n.FloatingPortal,{root:r,children:t})}):null},function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}r.default=e,i&&i.set(e,r)}(i(22155)),r(i(5821));var n=i(6358),s=i(4706),o=(i(10389),i(53486)),a=i(65723);function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}},53486(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverPortalContext=void 0,t.usePopoverPortalContext=function(){const e=r.useContext(s);if(void 0===e)throw new Error("Base UI: <Popover.Portal> is missing.");return e};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=t.PopoverPortalContext=r.createContext(void 0)},53049(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverPositioner=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=g(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(35938),a=i(14434),l=i(72204),c=(i(10389),i(53486)),u=i(52454),h=i(42468),d=i(13214),p=i(65723);function g(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(g=function(e){return e?i:t})(e)}t.PopoverPositioner=n.forwardRef(function(e,t){const{render:i,className:r,anchor:g,positionMethod:f="absolute",side:m="bottom",align:v="center",sideOffset:C=0,alignOffset:y=0,collisionBoundary:w="clipping-ancestors",collisionPadding:S=5,arrowPadding:b=5,sticky:E=!1,trackAnchor:A=!0,...T}=e,{floatingRootContext:M,open:R,mounted:_,setPositionerElement:P,modal:x,openReason:D,openMethod:I}=(0,s.usePopoverRootContext)(),L=(0,c.usePopoverPortalContext)(),N=(0,o.usePopoverPositioner)({anchor:g,floatingRootContext:M,positionMethod:f,mounted:_,open:R,side:m,sideOffset:C,align:v,alignOffset:y,arrowPadding:b,collisionBoundary:w,collisionPadding:S,sticky:E,trackAnchor:A,keepMounted:L}),O=n.useMemo(()=>({open:R,side:N.side,align:N.align,anchorHidden:N.anchorHidden}),[R,N.side,N.align,N.anchorHidden]),F=(0,d.useRenderElement)("div",e,{state:O,props:[N.props,T],ref:[t,P],customStyleHookMapping:l.popupStateMapping});return(0,p.jsxs)(a.PopoverPositionerContext.Provider,{value:N,children:[_&&!0===x&&"hover"!==D&&"touch"!==I&&(0,p.jsx)(h.InternalBackdrop,{inert:(0,u.inertValue)(!R)}),F()]})})},14434(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverPositionerContext=void 0,t.usePopoverPositionerContext=function(){const e=r.useContext(s);if(void 0===e)throw new Error("Base UI: PopoverPositionerContext is missing. PopoverPositioner parts must be placed within <Popover.Positioner>.");return e};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=t.PopoverPositionerContext=r.createContext(void 0)},35938(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.usePopoverPositioner=function(e){const{open:t,mounted:i}=(0,s.usePopoverRootContext)(),o=(0,n.useAnchorPositioning)(e),a=r.useMemo(()=>{const e={};return t||(e.pointerEvents="none"),{role:"presentation",hidden:!i,style:{...o.positionerStyles,...e}}},[t,i,o.positionerStyles]);return r.useMemo(()=>({props:a,...o}),[a,o])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=o(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var a=n?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(r,s,a):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(54540),s=i(4706);function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(o=function(e){return e?i:t})(e)}},1881(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverRoot=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(33890),a=i(81324),l=i(65723);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}t.PopoverRoot=function(e){const{defaultOpen:t=!1,onOpenChange:i,open:r,openOnHover:c=!1,delay:u,closeDelay:h=0,actionsRef:d,onOpenChangeComplete:p,modal:g=!1}=e,f=u??a.OPEN_DELAY,m=(0,o.usePopoverRoot)({...e,defaultOpen:t,onOpenChange:i,open:r,openOnHover:c,onOpenChangeComplete:p,delay:f,closeDelay:h,actionsRef:d,modal:g}),v=n.useMemo(()=>({...m,openOnHover:c,delay:f,closeDelay:h,modal:g}),[m,c,f,h,g]);return(0,l.jsx)(s.PopoverRootContext.Provider,{value:v,children:e.children})}},4706(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverRootContext=void 0,t.usePopoverRootContext=function(){const e=r.useContext(s);if(void 0===e)throw new Error("Base UI: PopoverRootContext is missing. Popover parts must be placed within <Popover.Root>.");return e};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=t.PopoverRootContext=r.createContext(void 0)},33890(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.usePopoverRoot=function(e){const{open:t,onOpenChange:i,defaultOpen:m=!1,delay:v,closeDelay:C,openOnHover:y=!1,onOpenChangeComplete:w,modal:S}=e,b=v??c.OPEN_DELAY,E=C??0,[A,T]=r.useState(),[M,R]=r.useState(),[_,P]=r.useState(),[x,D]=r.useState(null),[I,L]=r.useState(null),[N,O]=r.useState(null),[F,k]=r.useState(!0),G=r.useRef(null),V=r.useRef(-1),[H,B]=(0,o.useControlled)({controlled:t,default:m,name:"Popover",state:"open"}),z=(0,a.useEventCallback)(i),{mounted:U,setMounted:W,transitionStatus:j}=(0,l.useTransitionStatus)(H);(0,f.useScrollLock)({enabled:H&&!0===S&&"hover"!==N,mounted:U,open:H,referenceElement:I});const K=(0,a.useEventCallback)((e,t,i)=>{z(e,t,i),B(e),e&&O(i??null)}),$=(0,a.useEventCallback)(()=>{W(!1),k(!0),O(null),w?.(!1)});(0,p.useOpenChangeComplete)({enabled:!e.actionsRef,open:H,ref:G,onComplete(){H||$()}}),r.useImperativeHandle(e.actionsRef,()=>({unmount:$}),[$]);const q=(0,a.useEventCallback)(()=>{clearTimeout(V.current)});r.useEffect(()=>{H||q()},[q,H]),r.useEffect(()=>q,[q]);const Y=(0,s.useFloatingRootContext)({elements:{reference:x,floating:I},open:H,onOpenChange(e,t,i){const r="hover"===i||"safe-polygon"===i,s="click"===i&&0===t.detail,o=!e&&("escape-key"===i||null==i);function a(){K(e,t,(0,d.translateOpenChangeReason)(i))}r?(k(!0),q(),V.current=window.setTimeout(()=>{k(!1)},g.PATIENT_CLICK_THRESHOLD),n.flushSync(a)):a(),T(s||o?s?"click":"dismiss":void 0)}}),{openMethod:Q,triggerProps:X}=(0,h.useOpenInteractionType)(H),Z=b,J=(0,s.useHover)(Y,{enabled:y&&("touch"!==Q||"click"!==N),mouseOnly:!0,move:!1,handleClose:(0,s.safePolygon)({blockPointerEvents:!0}),restMs:Z,delay:{close:E}}),ee=(0,s.useClick)(Y,{stickIfOpen:F}),te=(0,s.useDismiss)(Y),ie=(0,s.useRole)(Y),{getReferenceProps:re,getFloatingProps:ne}=(0,s.useInteractions)([J,ee,te,ie]),se=r.useCallback((e={})=>re((0,u.mergeProps)(X,e)),[re,X]);return r.useMemo(()=>({open:H,setOpen:K,mounted:U,setMounted:W,transitionStatus:j,setTriggerElement:D,positionerElement:I,setPositionerElement:L,popupRef:G,titleId:M,setTitleId:R,descriptionId:_,setDescriptionId:P,getTriggerProps:se,getPopupProps:ne,floatingRootContext:Y,instantType:A,openMethod:Q,openReason:N,onOpenChangeComplete:w}),[H,K,U,W,j,I,M,_,se,ne,Y,A,Q,N,w])};var r=v(i(22155)),n=v(i(70316)),s=i(6358),o=i(46830),a=i(37041),l=i(30973),c=i(81324),u=i(80725),h=i(30626),d=i(861),p=i(65635),g=i(71202),f=i(22130);function m(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(m=function(e){return e?i:t})(e)}function v(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=m(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}},63317(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverTitle=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(13214),a=i(26111),l=i(322);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}t.PopoverTitle=n.forwardRef(function(e,t){const{render:i,className:r,...n}=e,{setTitleId:c}=(0,s.usePopoverRootContext)(),u=(0,l.useBaseUiId)(n.id);return(0,a.useEnhancedEffect)(()=>(c(u),()=>{c(void 0)}),[c,u]),(0,o.useRenderElement)("h2",e,{ref:t,props:[{id:u},n]})()})},4905(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.PopoverTrigger=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(4706)),o=i(1623),a=i(72204),l=i(13214);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}t.PopoverTrigger=n.forwardRef(function(e,t){const{render:i,className:r,disabled:c=!1,...u}=e,{open:h,setTriggerElement:d,getTriggerProps:p,openReason:g}=(0,s.usePopoverRootContext)(),f=n.useMemo(()=>({disabled:c,open:h}),[c,h]),{getButtonProps:m,buttonRef:v}=(0,o.useButton)({disabled:c,buttonRef:t}),C=n.useMemo(()=>({open:e=>e&&"click"===g?a.pressableTriggerOpenStateMapping.open(e):a.triggerOpenStateMapping.open(e)}),[g]);return(0,l.useRenderElement)("button",e,{state:f,ref:[v,d],props:[p,u,m],customStyleHookMapping:C})()})},81324(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.OPEN_DELAY=void 0,t.OPEN_DELAY=300},1623(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useButton=function(e={}){const{buttonRef:t,disabled:i=!1,focusableWhenDisabled:u,tabIndex:h,type:d="button",elementName:p}=e,g=r.useRef(null),{rootElementName:f,updateRootElementName:m}=(0,l.useRootElementName)({rootElementName:p}),v=void 0!==(0,c.useCompositeRootContext)(!0),C=(0,a.useEventCallback)(()=>{const e=g.current;return"BUTTON"===f||"INPUT"===f&&["button","submit","reset"].includes(e?.type)}),y=(0,a.useEventCallback)(()=>{const e=g.current;return Boolean("A"===f&&e?.href)}),w=(0,n.useForkRef)(m,t,g),S=r.useMemo(()=>{const e={};return void 0===h||v||(e.tabIndex=h),"BUTTON"===f||"INPUT"===f?u||v?e["aria-disabled"]=i:v||(e.disabled=i):""!==f&&("A"!==f?(e.role="button",v||(e.tabIndex=h??0)):h&&!v&&(e.tabIndex=h),i&&(e["aria-disabled"]=i,v||(e.tabIndex=u?h??0:-1))),e},[i,f,u,v,h]);return(0,o.useEnhancedEffect)(()=>{const e=g.current;e instanceof HTMLButtonElement&&v&&i&&void 0===S.disabled&&e.disabled&&(e.disabled=!1)},[i,S.disabled,v]),{getButtonProps:r.useCallback((e={})=>{const{onClick:t,onMouseDown:r,onKeyUp:n,onKeyDown:o,onPointerDown:a,...l}=e;return(0,s.mergeProps)({type:"BUTTON"===f||"INPUT"===f?d:void 0,onClick(e){i?e.preventDefault():t?.(e)},onMouseDown(e){i||r?.(e)},onKeyDown(e){(i&&u&&"Tab"!==e.key||e.target===e.currentTarget&&!C()&&" "===e.key)&&e.preventDefault(),i||((0,s.makeEventPreventable)(e),o?.(e)),e.baseUIHandlerPrevented||e.target!==e.currentTarget||C()||y()||"Enter"!==e.key||i||(t?.(e),e.preventDefault())},onKeyUp(e){i||((0,s.makeEventPreventable)(e),n?.(e)),e.baseUIHandlerPrevented||e.target!==e.currentTarget||C()||i||" "!==e.key||t?.(e)},onPointerDown(e){i?e.preventDefault():a?.(e)},ref:w},S,l)},[S,i,f,u,C,y,w,d]),buttonRef:w}};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=u(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(74467),s=i(80725),o=i(56371),a=i(37041),l=i(46489),c=i(57506);function u(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(u=function(e){return e?i:t})(e)}},42468(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.InternalBackdrop=void 0;var n=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=o(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var a=n?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(r,s,a):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),s=(r(i(5821)),i(65723));function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(o=function(e){return e?i:t})(e)}t.InternalBackdrop=n.forwardRef(function(e,t){return(0,s.jsx)("div",{ref:t,role:"presentation","data-floating-ui-inert":!0,...e,style:{position:"fixed",inset:0,userSelect:"none",WebkitUserSelect:"none"}})})},71202(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TYPEAHEAD_RESET_MS=t.PATIENT_CLICK_THRESHOLD=void 0,t.TYPEAHEAD_RESET_MS=500,t.PATIENT_CLICK_THRESHOLD=500},71922(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getNavigatorData=n,t.isFirefox=function(){return/firefox/i.test((0,r.getUserAgent)())},t.isIOS=function(){const e=n();return"MacIntel"===e.platform&&e.maxTouchPoints>1||/iP(hone|ad|od)|iOS/.test(e.platform)},t.isWebKit=function(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter:none")};var r=i(57735);function n(){if("undefined"==typeof navigator)return{platform:"",maxTouchPoints:-1};const e=navigator.userAgentData;return e?.platform?{platform:e.platform,maxTouchPoints:navigator.maxTouchPoints}:{platform:navigator.platform,maxTouchPoints:navigator.maxTouchPoints}}},38454(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.evaluateRenderProp=function(e,t,i){return"function"==typeof e?e(t,i):r.cloneElement(e,{...(0,n.mergeProps)(t,e.props),ref:t.ref})};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(80725);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},95361(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getReactElementRef=function(e){return parseInt(r.version,10)>=19?e?.props?.ref||null:e?.ref||null};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}},87935(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getStyleHookProps=function(e,t){let i={};return Object.entries(e).forEach(([e,r])=>{if(t?.hasOwnProperty(e)){const n=t[e](r);return void(null!=n&&(i={...i,...n}))}!0===r?i[`data-${e.toLowerCase()}`]="":r&&(i[`data-${e.toLowerCase()}`]=r.toString())}),i}},26111(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=i(95361);Object.keys(r).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===r[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return r[e]}}))});var n=i(46830);Object.keys(n).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===n[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return n[e]}}))});var s=i(56371);Object.keys(s).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===s[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return s[e]}}))});var o=i(74467);Object.keys(o).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===o[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return o[e]}}))});var a=i(50901);Object.keys(a).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===a[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return a[e]}}))});var l=i(22130);Object.keys(l).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===l[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return l[e]}}))});var c=i(30973);Object.keys(c).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===c[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return c[e]}}))});var u=i(21932);Object.keys(u).forEach(function(e){"default"!==e&&"__esModule"!==e&&(e in t&&t[e]===u[e]||Object.defineProperty(t,e,{enumerable:!0,get:function(){return u[e]}}))})},52454(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.inertValue=function(e){return(0,r.isReactVersionAtLeast)(19)?e:e?"true":void 0};var r=i(49958)},68736(e,t){"use strict";function i(e){return e&&e.ownerDocument||document}Object.defineProperty(t,"__esModule",{value:!0}),t.ownerDocument=i,t.ownerWindow=function(e){return i(e).defaultView||window}},72204(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.triggerOpenStateMapping=t.pressableTriggerOpenStateMapping=t.popupStateMapping=t.CommonTriggerDataAttributes=t.CommonPopupDataAttributes=void 0;var r=i(60687);let n=t.CommonPopupDataAttributes=function(e){return e.open="data-open",e.closed="data-closed",e[e.startingStyle=r.TransitionStatusDataAttributes.startingStyle]="startingStyle",e[e.endingStyle=r.TransitionStatusDataAttributes.endingStyle]="endingStyle",e.anchorHidden="data-anchor-hidden",e}({}),s=t.CommonTriggerDataAttributes=function(e){return e.popupOpen="data-popup-open",e.pressed="data-pressed",e}({});const o={[s.popupOpen]:""},a={[s.popupOpen]:"",[s.pressed]:""},l={[n.open]:""},c={[n.closed]:""},u={[n.anchorHidden]:""};t.triggerOpenStateMapping={open:e=>e?o:null},t.pressableTriggerOpenStateMapping={open:e=>e?a:null},t.popupStateMapping={open:e=>e?l:c,anchorHidden:e=>e?u:null}},10389(e,t,i){"use strict";var r=i(44898);Object.defineProperty(t,"__esModule",{value:!0}),t.HTMLElementType=function(e,t,i,r,n){return null},t.exactProp=function(e){return e},t.refType=void 0;var n=r(i(5821));t.refType=n.default.oneOfType([n.default.func,n.default.object])},49958(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.isReactVersionAtLeast=function(e){return s>=e};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}const s=parseInt(r.version,10)},74184(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.resolveClassName=function(e,t){return"function"==typeof e?e(t):e}},60687(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.transitionStatusMapping=t.TransitionStatusDataAttributes=void 0;let i=t.TransitionStatusDataAttributes=function(e){return e.startingStyle="data-starting-style",e.endingStyle="data-ending-style",e}({});const r={[i.startingStyle]:""},n={[i.endingStyle]:""};t.transitionStatusMapping={transitionStatus:e=>"starting"===e?r:"ending"===e?n:null}},861(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.translateOpenChangeReason=function(e){if(e)return{click:"click",hover:"hover",focus:"focus","focus-out":"focus-out","escape-key":"escape-key","outside-press":"outside-press","reference-press":"trigger-press","safe-polygon":"hover","ancestor-scroll":void 0,"list-navigation":void 0}[e]}},54540(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useAnchorPositioning=function(e){const{anchor:t,positionMethod:i="absolute",side:c="bottom",sideOffset:d=0,align:p="center",alignOffset:g=0,collisionBoundary:f,collisionPadding:m=5,sticky:v=!1,arrowPadding:C=5,keepMounted:y=!1,floatingRootContext:w,mounted:S,trackAnchor:b=!0,nodeId:E}=e,A="rtl"===(0,a.useDirection)(),T={top:"top",right:"right",bottom:"bottom",left:"left","inline-end":A?"left":"right","inline-start":A?"right":"left"}[c],M="center"===p?T:`${T}-${p}`,R={boundary:"clipping-ancestors"===f?"clippingAncestors":f,padding:m},_=r.useRef(null),P=(0,l.useLatestRef)(d),x=(0,l.useLatestRef)(g),D="function"!=typeof d?d:0,I="function"!=typeof g?g:0,L=[(0,n.offset)(({rects:e,placement:t})=>{const i={side:u(c,(0,s.getSide)(t),A),align:(0,s.getAlignment)(t)||"center",anchor:{width:e.reference.width,height:e.reference.height},positioner:{width:e.floating.width,height:e.floating.height}},r="function"==typeof P.current?P.current(i):P.current,n="function"==typeof x.current?x.current(i):x.current;return{mainAxis:r,crossAxis:n,alignmentAxis:n}},[D,I,A,c])],N=(0,n.flip)(R),O=(0,n.shift)({...R,crossAxis:v,limiter:v?void 0:(0,n.limitShift)(()=>{if(!_.current)return{};const{height:e}=_.current.getBoundingClientRect();return{offset:e/2+("number"==typeof m?m:0)}})});"center"!==p?L.push(N,O):L.push(O,N),L.push((0,n.size)({...R,apply({elements:{floating:e},rects:{reference:t},availableWidth:i,availableHeight:r}){Object.entries({"--available-width":`${i}px`,"--available-height":`${r}px`,"--anchor-width":`${t.width}px`,"--anchor-height":`${t.height}px`}).forEach(([t,i])=>{e.style.setProperty(t,i)})}}),(0,n.arrow)(()=>({element:_.current||document.createElement("div"),padding:C}),[C]),(0,n.hide)(),{name:"transformOrigin",fn({elements:e,middlewareData:t,placement:i}){const r=(0,s.getSide)(i),n=_.current,o=t.arrow?.x??0,a=t.arrow?.y??0,l=o+(n?.clientWidth??0)/2,c=a+(n?.clientHeight??0)/2,u={top:`${l}px calc(100% + ${d}px)`,bottom:`${l}px ${-d}px`,left:`calc(100% + ${d}px) ${c}px`,right:`${-d}px ${c}px`}[r];return e.floating.style.setProperty("--transform-origin",u),{}}});let F=w;!S&&w&&(F={...w,elements:{reference:null,floating:null,domReference:null}});const k=r.useMemo(()=>({elementResize:b&&"undefined"!=typeof ResizeObserver,layoutShift:b&&"undefined"!=typeof IntersectionObserver}),[b]),{refs:G,elements:V,floatingStyles:H,middlewareData:B,update:z,placement:U,context:W,isPositioned:j}=(0,n.useFloating)({rootContext:F,placement:M,middleware:L,strategy:i,whileElementsMounted:y?void 0:(...e)=>(0,n.autoUpdate)(...e,k),nodeId:E}),K=r.useRef(null);(0,o.useEnhancedEffect)(()=>{if(!S)return;const e="function"==typeof t?t():t;if(e){const t=h(e)?e.current:e;G.setPositionReference(t),K.current=t}},[S,G,t]),r.useEffect(()=>{S&&"function"!=typeof t&&h(t)&&t.current!==K.current&&(G.setPositionReference(t.current),K.current=t.current)},[S,G,t]),r.useEffect(()=>{if(y&&S&&V.domReference&&V.floating)return(0,n.autoUpdate)(V.domReference,V.floating,z,k)},[y,S,V,z,k]);const $=(0,s.getSide)(U),q=u(c,$,A),Y=(0,s.getAlignment)(U)||"center",Q=Boolean(B.hide?.referenceHidden),X=r.useMemo(()=>({position:"absolute",top:B.arrow?.y,left:B.arrow?.x}),[B.arrow]),Z=0!==B.arrow?.centerOffset;return r.useMemo(()=>({positionerStyles:H,arrowStyles:X,arrowRef:_,arrowUncentered:Z,side:q,align:Y,anchorHidden:Q,refs:G,context:W,isPositioned:j}),[H,X,_,Z,q,Y,Q,G,W,j])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=c(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(6358),s=i(31924),o=i(56371),a=i(53079),l=i(12618);function c(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(c=function(e){return e?i:t})(e)}function u(e,t,i){const r="inline-start"===e||"inline-end"===e;return{top:"top",right:r?i?"inline-start":"inline-end":"right",bottom:"bottom",left:r?i?"inline-end":"inline-start":"left"}[t]}function h(e){return null!=e&&"current"in e}},6029(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useAnimationsFinished=function(e,t=!1){const i=r.useRef(-1),o=r.useRef(-1),a=(0,s.useEventCallback)(()=>{cancelAnimationFrame(i.current),clearTimeout(o.current)});return r.useEffect(()=>a,[a]),(0,s.useEventCallback)((r,s=null)=>{a();const l=e.current;l&&("function"!=typeof l.getAnimations||globalThis.BASE_UI_ANIMATIONS_DISABLED?r():i.current=requestAnimationFrame(()=>{function e(){l&&Promise.allSettled(l.getAnimations().map(e=>e.finished)).then(()=>{null!=s&&s.aborted||n.flushSync(r)})}t?o.current=window.setTimeout(e):e()}))})};var r=a(i(22155)),n=a(i(70316)),s=i(37041);function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(o=function(e){return e?i:t})(e)}function a(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=o(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var a=n?Object.getOwnPropertyDescriptor(e,s):null;a&&(a.get||a.set)?Object.defineProperty(r,s,a):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}},322(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useBaseUiId=function(e){return(0,r.useId)(e,"base-ui")};var r=i(50901)},46830(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useControlled=function({controlled:e,default:t,name:i,state:n="value"}){const{current:s}=r.useRef(void 0!==e),[o,a]=r.useState(t);return[s?e:o,r.useCallback(e=>{s||a(e)},[])]};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}},24842(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useEnhancedClickHandler=function(e){const t=r.useRef(""),i=r.useCallback(e=>{e.defaultPrevented||(t.current=e.pointerType)},[]);return{onClick:r.useCallback(i=>{0!==i.detail?("pointerType"in i&&e(i,i.pointerType),e(i,t.current),t.current=""):e(i,"keyboard")},[e]),onPointerDown:i}};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}},56371(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useEnhancedEffect=void 0;var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}t.useEnhancedEffect="undefined"!=typeof window?r.useLayoutEffect:r.useEffect},37041(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useEventCallback=function(e){const t=r.useRef(e);return(0,n.useEnhancedEffect)(()=>{t.current=e}),r.useCallback((...e)=>t.current?.(...e),[])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(56371);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},74467(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useForkRef=function(...e){const t=r.useRef(void 0),i=r.useCallback(t=>{const i=e.map(e=>{if(null==e)return null;if("function"==typeof e){const i=e,r=i(t);return"function"==typeof r?r:()=>{i(null)}}return e.current=t,()=>{e.current=null}});return()=>{i.forEach(e=>e?.())}},e);return r.useMemo(()=>e.every(e=>null==e)?null:e=>{t.current&&(t.current(),t.current=void 0),null!=e&&(t.current=i(e))},e)};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}},50901(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useId=function(e,t){if(void 0!==o){const i=o();return e??(t?`${t}-${i}`:i)}return function(e,t="mui"){const[i,n]=r.useState(e),o=e||i;return r.useEffect(()=>{null==i&&(s+=1,n(`${t}-${s}`))},[i,t]),o}(e,t)};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}let s=0;const o={...r}.useId},12618(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useLatestRef=function(e){const t=r.useRef(e);return(0,n.useEnhancedEffect)(()=>{t.current=e}),t};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(56371);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},65635(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useOpenChangeComplete=function(e){const{enabled:t=!0,open:i,ref:a,onComplete:l}=e,c=(0,o.useLatestRef)(i),u=(0,s.useEventCallback)(l),h=(0,n.useAnimationsFinished)(a,i);r.useEffect(()=>{t&&h(()=>{i===c.current&&u()})},[t,i,u,h,c])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=a(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(6029),s=i(37041),o=i(12618);function a(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(a=function(e){return e?i:t})(e)}},30626(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useOpenInteractionType=function(e){const[t,i]=r.useState(null);e||null===t||i(null);const s=r.useCallback((t,r)=>{e||i(r)},[e,i]),{onClick:o,onPointerDown:a}=(0,n.useEnhancedClickHandler)(s);return r.useMemo(()=>({openMethod:t,triggerProps:{onClick:o,onPointerDown:a}}),[t,o,a])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(24842);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},13214(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useRenderElement=function(e,t,i={}){const{className:u,render:d}=t,{propGetter:p=e=>e,state:g=h,ref:f,props:m,customStyleHookMapping:v,styleHooks:C=!0}=i,y=d||("string"==typeof e?(b=e,function(e){return"button"===b?(0,c.jsx)("button",{type:"button",...e}):"img"===b?(0,c.jsx)("img",{alt:"",...e}):(0,c.jsx)(b,{...e})}):e),w=(0,s.resolveClassName)(u,g),S=p({...r.useMemo(()=>C?(0,n.getStyleHookProps)(g,v):h,[g,v,C]),...Array.isArray(m)?(0,l.mergeProps)(...m):m});var b;let E=[];void 0!==f&&(E=Array.isArray(f)?f:[f]);const A={...S,ref:(0,a.useRenderPropForkRef)(y,S.ref,...E)};return void 0!==w&&(A.className=w),()=>(0,o.evaluateRenderProp)(y,A,g)};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=u(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(87935),s=i(74184),o=i(38454),a=i(58064),l=i(80725),c=i(65723);function u(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(u=function(e){return e?i:t})(e)}const h={}},58064(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useRenderPropForkRef=function(e,...t){let i;return i="function"!=typeof e?(0,n.isReactVersionAtLeast)(19)?e.props.ref:e.ref:null,(0,r.useForkRef)(i,...t)};var r=i(74467),n=i(49958)},46489(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useRootElementName=function(e){const{rootElementName:t=""}=e,[i,n]=r.useState(t.toUpperCase());return{rootElementName:i,updateRootElementName:r.useCallback(e=>{n(e?.tagName??"")},[])}};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=n(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},s=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=s?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155));function n(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(n=function(e){return e?i:t})(e)}i(56371),i(6543)},22130(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getPreventScrollCount=function(){return d},t.useScrollLock=function(e){const{enabled:t=!0,mounted:i,open:l,referenceElement:g}=e,f=r.useMemo(()=>t&&((0,s.isIOS)()||!("undefined"!=typeof CSS&&"function"==typeof CSS.supports&&CSS.supports("height","1dvh"))||(0,s.isFirefox)()&&!function(e){if("undefined"==typeof document)return!1;const t=(0,o.ownerDocument)(e);return(0,o.ownerWindow)(t).innerWidth-t.documentElement.clientWidth>0}(g)),[t,g]);(0,a.useEnhancedEffect)(()=>{if(i&&!l&&(0,s.isWebKit)()){const e=(0,o.ownerDocument)(g),t=e.body.style.userSelect,i=e.body.style.webkitUserSelect;return e.body.style.userSelect="none",e.body.style.webkitUserSelect="none",()=>{e.body.style.userSelect=t,e.body.style.webkitUserSelect=i}}},[i,l,g]),(0,n.usePreventScroll)({isDisabled:!f}),(0,a.useEnhancedEffect)(()=>{if(t&&!f)return d+=1,1===d&&(p=function(e){const t=(0,o.ownerDocument)(e),i=t.documentElement,r=t.body,n=(0,o.ownerWindow)(i);let a=0,l=0,d=-1;if((0,s.isWebKit)()&&1!==(n.visualViewport?.scale??1))return()=>{};function p(){const e=n.getComputedStyle(i),t=n.getComputedStyle(r);a=i.scrollTop,l=i.scrollLeft,c={overflowY:i.style.overflowY,overflowX:i.style.overflowX},h=i.style.scrollBehavior,u={position:r.style.position,height:r.style.height,width:r.style.width,boxSizing:r.style.boxSizing,overflowY:r.style.overflowY,overflowX:r.style.overflowX,scrollBehavior:r.style.scrollBehavior};const s=e.scrollbarGutter?.includes("stable"),o=i.scrollHeight>i.clientHeight,d=i.scrollWidth>i.clientWidth,p="scroll"===e.overflowY||"scroll"===t.overflowY,g="scroll"===e.overflowX||"scroll"===t.overflowX,f=Math.max(0,n.innerWidth-i.clientWidth),m=Math.max(0,n.innerHeight-i.clientHeight);Object.assign(i.style,{overflowY:s||!o&&!p?"hidden":"scroll",overflowX:s||!d&&!g?"hidden":"scroll"});const v=parseFloat(t.marginTop)+parseFloat(t.marginBottom),C=parseFloat(t.marginLeft)+parseFloat(t.marginRight);Object.assign(r.style,{position:"relative",height:v||m?`calc(100dvh - ${v+m}px)`:"100dvh",width:C||f?`calc(100vw - ${C+f}px)`:"100vw",boxSizing:"border-box",overflow:"hidden",scrollBehavior:"unset"}),r.scrollTop=a,r.scrollLeft=l,i.setAttribute("data-base-ui-scroll-locked",""),i.style.scrollBehavior="unset"}function g(){Object.assign(i.style,c),Object.assign(r.style,u),i.scrollTop=a,i.scrollLeft=l,i.removeAttribute("data-base-ui-scroll-locked"),i.style.scrollBehavior=h}function f(){g(),cancelAnimationFrame(d),d=requestAnimationFrame(p)}return p(),n.addEventListener("resize",f),()=>{cancelAnimationFrame(d),g(),n.removeEventListener("resize",f)}}(g)),()=>{d-=1,0===d&&p()}},[t,f,g])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=l(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var s in e)if("default"!==s&&{}.hasOwnProperty.call(e,s)){var o=n?Object.getOwnPropertyDescriptor(e,s):null;o&&(o.get||o.set)?Object.defineProperty(r,s,o):r[s]=e[s]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(34446),s=i(71922),o=i(68736),a=i(56371);function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(l=function(e){return e?i:t})(e)}let c={},u={},h="",d=0,p=()=>{}},30973(e,t,i){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.useTransitionStatus=function(e){const[t,i]=r.useState(e?"idle":void 0),[s,o]=r.useState(e);return e&&!s&&(o(!0),i("starting")),!e&&s&&"ending"!==t&&i("ending"),e||s||"ending"!==t||i(void 0),(0,n.useEnhancedEffect)(()=>{if(!e)return;e&&s&&"idle"!==t&&i("starting");const r=requestAnimationFrame(()=>{i("idle")});return()=>{cancelAnimationFrame(r)}},[e,s,i,t]),r.useMemo(()=>({mounted:s,setMounted:o,transitionStatus:t}),[s,t])};var r=function(e,t){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var i=s(t);if(i&&i.has(e))return i.get(e);var r={__proto__:null},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var o in e)if("default"!==o&&{}.hasOwnProperty.call(e,o)){var a=n?Object.getOwnPropertyDescriptor(e,o):null;a&&(a.get||a.set)?Object.defineProperty(r,o,a):r[o]=e[o]}return r.default=e,i&&i.set(e,r),r}(i(22155)),n=i(56371);function s(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,i=new WeakMap;return(s=function(e){return e?i:t})(e)}},21932(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.visuallyHidden=void 0,t.visuallyHidden={clip:"rect(0 0 0 0)",overflow:"hidden",whiteSpace:"nowrap",position:"fixed",top:0,left:0,border:0,padding:0,width:1,height:1,margin:-1}},6543(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.warn=function(...e){}},64379(e,t,i){"use strict";var r=i(7274),n=globalThis;e.exports=function(){for(var e=[],t=0;t<r.length;t++)"function"==typeof n[r[t]]&&(e[e.length]=r[t]);return e}},30395(e,t){var i;!function(){"use strict";var r={}.hasOwnProperty;function n(){for(var e="",t=0;t<arguments.length;t++){var i=arguments[t];i&&(e=o(e,s(i)))}return e}function s(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return n.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var t="";for(var i in e)r.call(e,i)&&e[i]&&(t=o(t,i));return t}function o(e,t){return t?e?e+" "+t:e+t:e}e.exports?(n.default=n,e.exports=n):void 0===(i=function(){return n}.apply(t,[]))||(e.exports=i)}()},58041(e,t,i){"use strict";const{normalizeIPv6:r,removeDotSegments:n,recomposeAuthority:s,normalizePercentEncoding:o,normalizePathEncoding:a,escapePreservingEscapes:l,reescapeHostDelimiters:c,isIPv4:u,nonSimpleDomain:h}=i(1900),{SCHEMES:d,getSchemeHandler:p}=i(41441);function g(e,t,i,r){const s={};return r||(e=C(f(e,i),i),t=C(f(t,i),i)),!(i=i||{}).tolerant&&t.scheme?(s.scheme=t.scheme,s.userinfo=t.userinfo,s.host=t.host,s.port=t.port,s.path=n(t.path||""),s.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(s.userinfo=t.userinfo,s.host=t.host,s.port=t.port,s.path=n(t.path||""),s.query=t.query):(t.path?("/"===t.path[0]?s.path=n(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?s.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:s.path=t.path:s.path="/"+t.path,s.path=n(s.path)),s.query=t.query):(s.path=e.path,void 0!==t.query?s.query=t.query:s.query=e.query),s.userinfo=e.userinfo,s.host=e.host,s.port=e.port),s.scheme=e.scheme),s.fragment=t.fragment,s}function f(e,t){const i={host:e.host,scheme:e.scheme,userinfo:e.userinfo,port:e.port,path:e.path,query:e.query,nid:e.nid,nss:e.nss,uuid:e.uuid,fragment:e.fragment,reference:e.reference,resourceName:e.resourceName,secure:e.secure,error:""},r=Object.assign({},t),a=[],c=p(r.scheme||i.scheme);c&&c.serialize&&c.serialize(i,r),void 0!==i.path&&(r.skipEscape?i.path=o(i.path):(i.path=l(i.path),void 0!==i.scheme&&(i.path=i.path.split("%3A").join(":")))),"suffix"!==r.reference&&i.scheme&&a.push(i.scheme,":");const u=s(i);if(void 0!==u&&("suffix"!==r.reference&&a.push("//"),a.push(u),i.path&&"/"!==i.path[0]&&a.push("/")),void 0!==i.path){let e=i.path;r.absolutePath||c&&c.absolutePath||(e=n(e)),void 0===u&&"/"===e[0]&&"/"===e[1]&&(e="/%2F"+e.slice(2)),a.push(e)}return void 0!==i.query&&a.push("?",i.query),void 0!==i.fragment&&a.push("#",i.fragment),a.join("")}const m=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function v(e,t){const i=Object.assign({},t),n={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let s=!1,o=!1;"suffix"===i.reference&&(e=i.scheme?i.scheme+":"+e:"//"+e);const l=e.match(m);if(l){n.scheme=l[1],n.userinfo=l[3],n.host=l[4],n.port=parseInt(l[5],10),n.path=l[6]||"",n.query=l[7],n.fragment=l[8],isNaN(n.port)&&(n.port=l[5]);const t=function(e,t){return void 0!==t[2]&&e.path&&"/"!==e.path[0]?'URI path must start with "/" when authority is present.':"number"==typeof e.port&&(e.port<0||e.port>65535)?"URI port is malformed.":void 0}(n,l);if(void 0!==t&&(n.error=n.error||t,s=!0),n.host)if(!1===u(n.host)){const e=r(n.host);n.host=e.host.toLowerCase(),o=e.isIPV6}else o=!0;void 0!==n.scheme||void 0!==n.userinfo||void 0!==n.host||void 0!==n.port||void 0!==n.query||n.path?void 0===n.scheme?n.reference="relative":void 0===n.fragment?n.reference="absolute":n.reference="uri":n.reference="same-document",i.reference&&"suffix"!==i.reference&&i.reference!==n.reference&&(n.error=n.error||"URI is not a "+i.reference+" reference.");const d=p(i.scheme||n.scheme);if(!(i.unicodeSupport||d&&d.unicodeSupport)&&n.host&&(i.domainHost||d&&d.domainHost)&&!1===o&&h(n.host))try{n.host=URL.domainToASCII(n.host.toLowerCase())}catch(e){n.error=n.error||"Host's domain name can not be converted to ASCII: "+e}if((!d||d&&!d.skipNormalize)&&(-1!==e.indexOf("%")&&(void 0!==n.scheme&&(n.scheme=unescape(n.scheme)),void 0!==n.host&&(n.host=c(unescape(n.host),o))),n.path&&(n.path=a(n.path)),n.fragment))try{n.fragment=encodeURI(decodeURIComponent(n.fragment))}catch{n.error=n.error||"URI malformed"}d&&d.parse&&d.parse(n,i)}else n.error=n.error||"URI can not be parsed.";return{parsed:n,malformedAuthorityOrPort:s}}function C(e,t){return v(e,t).parsed}function y(e,t){const{parsed:i,malformedAuthorityOrPort:r}=v(e,t);return{normalized:r?e:f(i,t),malformedAuthorityOrPort:r}}function w(e,t){if("string"==typeof e){const{normalized:i,malformedAuthorityOrPort:r}=y(e,t);return r?void 0:i}if("object"==typeof e)return f(e,t)}const S={SCHEMES:d,normalize:function(e,t){return"string"==typeof e?e=function(e,t){return y(e,t).normalized}(e,t):"object"==typeof e&&(e=C(f(e,t),t)),e},resolve:function(e,t,i){const r=i?Object.assign({scheme:"null"},i):{scheme:"null"},n=g(C(e,r),C(t,r),r,!0);return r.skipEscape=!0,f(n,r)},resolveComponent:g,equal:function(e,t,i){const r=w(e,i),n=w(t,i);return void 0!==r&&void 0!==n&&r.toLowerCase()===n.toLowerCase()},serialize:f,parse:C};e.exports=S,e.exports.default=S,e.exports.fastUri=S},41441(e,t,i){"use strict";const{isUUID:r}=i(1900),n=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,s=["http","https","ws","wss","urn","urn:uuid"];function o(e){return!0===e.secure||!1!==e.secure&&!!e.scheme&&!(3!==e.scheme.length||"w"!==e.scheme[0]&&"W"!==e.scheme[0]||"s"!==e.scheme[1]&&"S"!==e.scheme[1]||"s"!==e.scheme[2]&&"S"!==e.scheme[2])}function a(e){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e}function l(e){const t="https"===String(e.scheme).toLowerCase();return e.port!==(t?443:80)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}const c={scheme:"http",domainHost:!0,parse:a,serialize:l},u={scheme:"ws",domainHost:!0,parse:function(e){return e.secure=o(e),e.resourceName=(e.path||"/")+(e.query?"?"+e.query:""),e.path=void 0,e.query=void 0,e},serialize:function(e){if(e.port!==(o(e)?443:80)&&""!==e.port||(e.port=void 0),"boolean"==typeof e.secure&&(e.scheme=e.secure?"wss":"ws",e.secure=void 0),e.resourceName){const[t,i]=e.resourceName.split("?");e.path=t&&"/"!==t?t:void 0,e.query=i,e.resourceName=void 0}return e.fragment=void 0,e}},h={http:c,https:{scheme:"https",domainHost:c.domainHost,parse:a,serialize:l},ws:u,wss:{scheme:"wss",domainHost:u.domainHost,parse:u.parse,serialize:u.serialize},urn:{scheme:"urn",parse:function(e,t){if(!e.path)return e.error="URN can not be parsed",e;const i=e.path.match(n);if(i){const r=t.scheme||e.scheme||"urn";e.nid=i[1].toLowerCase(),e.nss=i[2];const n=d(`${r}:${t.nid||e.nid}`);e.path=void 0,n&&(e=n.parse(e,t))}else e.error=e.error||"URN can not be parsed.";return e},serialize:function(e,t){if(void 0===e.nid)throw new Error("URN without nid cannot be serialized");const i=t.scheme||e.scheme||"urn",r=e.nid.toLowerCase(),n=d(`${i}:${t.nid||r}`);n&&(e=n.serialize(e,t));const s=e,o=e.nss;return s.path=`${r||t.nid}:${o}`,t.skipEscape=!0,s},skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:function(e,t){const i=e;return i.uuid=i.nss,i.nss=void 0,t.tolerant||i.uuid&&r(i.uuid)||(i.error=i.error||"UUID is not valid."),i},serialize:function(e){const t=e;return t.nss=(e.uuid||"").toLowerCase(),t},skipNormalize:!0}};function d(e){return e&&(h[e]||h[e.toLowerCase()])||void 0}Object.setPrototypeOf(h,null),e.exports={wsIsSecure:o,SCHEMES:h,isValidSchemeName:function(e){return-1!==s.indexOf(e)},getSchemeHandler:d}},1900(e){"use strict";const t=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),i=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),r=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),n=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),s=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function o(e){let t="",i=0,r=0;for(r=0;r<e.length;r++)if(i=e[r].charCodeAt(0),48!==i){if(!(i>=48&&i<=57||i>=65&&i<=70||i>=97&&i<=102))return"";t+=e[r];break}for(r+=1;r<e.length;r++){if(i=e[r].charCodeAt(0),!(i>=48&&i<=57||i>=65&&i<=70||i>=97&&i<=102))return"";t+=e[r]}return t}const a=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function l(e){return e.length=0,!0}function c(e,t,i){if(e.length){const r=o(e);if(""===r)return i.error=!0,!1;t.push(r),e.length=0}return!0}function u(e){if(function(e){let t=0;for(let i=0;i<e.length;i++)":"===e[i]&&t++;return t}(e)<2)return{host:e,isIPV6:!1};const t=function(e){let t=0;const i={error:!1,address:"",zone:""},r=[],n=[];let s=!1,a=!1,u=c;for(let o=0;o<e.length;o++){const c=e[o];if("["!==c&&"]"!==c)if(":"!==c)if("%"===c){if(!u(n,r,i))break;u=l}else n.push(c);else{if(!0===s&&(a=!0),!u(n,r,i))break;if(++t>7){i.error=!0;break}o>0&&":"===e[o-1]&&(s=!0),r.push(":")}}return n.length&&(u===l?i.zone=n.join(""):a?r.push(n.join("")):r.push(o(n))),i.address=r.join(""),i}(e);if(t.error)return{host:e,isIPV6:!1};{let e=t.address,i=t.address;return t.zone&&(e+="%"+t.zone,i+="%25"+t.zone),{host:e,isIPV6:!0,escapedHost:i}}}const h={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},d=/[@/?#:]/g,p=/[@/?#]/g;function g(e,t){const i=t?p:d;return i.lastIndex=0,e.replace(i,e=>h[e])}e.exports={nonSimpleDomain:a,recomposeAuthority:function(e){const t=[];if(void 0!==e.userinfo&&(t.push(e.userinfo),t.push("@")),void 0!==e.host){let r=unescape(e.host);if(!i(r)){const e=u(r);r=!0===e.isIPV6?`[${e.escapedHost}]`:g(r,!1)}t.push(r)}return"number"!=typeof e.port&&"string"!=typeof e.port||(t.push(":"),t.push(String(e.port))),t.length?t.join(""):void 0},reescapeHostDelimiters:g,normalizePercentEncoding:function(e,t=!1){if(-1===e.indexOf("%"))return e;let i="";for(let s=0;s<e.length;s++){if("%"===e[s]&&s+2<e.length){const o=e.slice(s+1,s+3);if(r(o)){const e=o.toUpperCase(),r=String.fromCharCode(parseInt(e,16));t&&n(r)?i+=r:i+="%"+e,s+=2;continue}}i+=e[s]}return i},normalizePathEncoding:function(e){let t="";for(let i=0;i<e.length;i++){if("%"===e[i]&&i+2<e.length){const s=e.slice(i+1,i+3);if(r(s)){const e=s.toUpperCase(),r=String.fromCharCode(parseInt(e,16));"."!==r&&n(r)?t+=r:t+="%"+e,i+=2;continue}}s(e[i])?t+=e[i]:t+=escape(e[i])}return t},escapePreservingEscapes:function(e){let t="";for(let i=0;i<e.length;i++){if("%"===e[i]&&i+2<e.length){const n=e.slice(i+1,i+3);if(r(n)){t+="%"+n.toUpperCase(),i+=2;continue}}t+=escape(e[i])}return t},removeDotSegments:function(e){let t=e;const i=[];let r=-1,n=0;for(;n=t.length;){if(1===n){if("."===t)break;if("/"===t){i.push("/");break}i.push(t);break}if(2===n){if("."===t[0]){if("."===t[1])break;if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&("."===t[1]||"/"===t[1])){i.push("/");break}}else if(3===n&&"/.."===t){0!==i.length&&i.pop(),i.push("/");break}if("."===t[0]){if("."===t[1]){if("/"===t[2]){t=t.slice(3);continue}}else if("/"===t[1]){t=t.slice(2);continue}}else if("/"===t[0]&&"."===t[1]){if("/"===t[2]){t=t.slice(2);continue}if("."===t[2]&&"/"===t[3]){t=t.slice(3),0!==i.length&&i.pop();continue}}if(-1===(r=t.indexOf("/",1))){i.push(t);break}i.push(t.slice(0,r)),t=t.slice(r)}return i.join("")},isIPv4:i,isUUID:t,normalizeIPv6:u,stringArrayToHexStripped:o}},30622(e,t,i){"use strict";i.d(t,{k:()=>m});var r=i(65959),n=i(81987),s=i(74140),o=i(19360),a=i(48555),l=i(47812),c=i(45902),u=i(78027),h=i(27231),d=i(47372),p=i(131),g=i(13062),f=i(30301),m=function(){function e(){this.assumeImmutableResults=!1,this.getFragmentDoc=(0,n.LV)(a.ct,{max:o.v["cache.fragmentQueryDocuments"]||1e3,cache:u.l})}return e.prototype.lookupFragment=function(e){return null},e.prototype.batch=function(e){var t,i=this,r="string"==typeof e.optimistic?e.optimistic:!1===e.optimistic?null:void 0;return this.performTransaction(function(){return t=e.update(i)},r),t},e.prototype.recordOptimisticTransaction=function(e,t){this.performTransaction(e,t)},e.prototype.transformDocument=function(e){return e},e.prototype.transformForLink=function(e){return e},e.prototype.identify=function(e){},e.prototype.gc=function(){return[]},e.prototype.modify=function(e){return!1},e.prototype.readQuery=function(e,t){var i=this;return void 0===t&&(t=!!e.optimistic),!1!==globalThis.__DEV__&&(0,f.cc)(e,"canonizeResults","cache.readQuery"),(0,f.lz)("canonizeResults",function(){return i.read((0,r.__assign)((0,r.__assign)({},e),{rootId:e.id||"ROOT_QUERY",optimistic:t}))})},e.prototype.watchFragment=function(e){var t=this,i=e.fragment,n=e.fragmentName,o=e.from,a=e.optimistic,u=void 0===a||a,h=(0,r.__rest)(e,["fragment","fragmentName","from","optimistic"]),f=this.getFragmentDoc(i,n),m=void 0===o||"string"==typeof o?o:this.identify(o),v=!!e[Symbol.for("apollo.dataMasking")];if(!1!==globalThis.__DEV__){var C=n||(0,l.E4)(i).name.value;m||!1!==globalThis.__DEV__&&p.V1.warn(1,C)}var y,w=(0,r.__assign)((0,r.__assign)({},h),{returnPartialData:!0,id:m,query:f,optimistic:u});return new s.c(function(s){return t.watch((0,r.__assign)((0,r.__assign)({},w),{immediate:!0,callback:function(o){var a=v?(0,g.z)(o.result,i,t,n):o.result;if(!y||!(0,d.a)(f,{data:y.result},{data:a},e.variables)){var l={data:a,complete:!!o.complete};o.missing&&(l.missing=(0,c.IM)(o.missing.map(function(e){return e.missing}))),y=(0,r.__assign)((0,r.__assign)({},o),{result:a}),s.next(l)}}}))})},e.prototype.readFragment=function(e,t){var i=this;return void 0===t&&(t=!!e.optimistic),!1!==globalThis.__DEV__&&(0,f.cc)(e,"canonizeResults","cache.readFragment"),(0,f.lz)("canonizeResults",function(){return i.read((0,r.__assign)((0,r.__assign)({},e),{query:i.getFragmentDoc(e.fragment,e.fragmentName),rootId:e.id,optimistic:t}))})},e.prototype.writeQuery=function(e){var t=e.id,i=e.data,n=(0,r.__rest)(e,["id","data"]);return this.write(Object.assign(n,{dataId:t||"ROOT_QUERY",result:i}))},e.prototype.writeFragment=function(e){var t=e.id,i=e.data,n=e.fragment,s=e.fragmentName,o=(0,r.__rest)(e,["id","data","fragment","fragmentName"]);return this.write(Object.assign(o,{query:this.getFragmentDoc(n,s),dataId:t,result:i}))},e.prototype.updateQuery=function(e,t){return!1!==globalThis.__DEV__&&(0,f.cc)(e,"canonizeResults","cache.updateQuery"),this.batch({update:function(i){var n=(0,f.lz)("canonizeResults",function(){return i.readQuery(e)}),s=t(n);return null==s?n:(i.writeQuery((0,r.__assign)((0,r.__assign)({},e),{data:s})),s)}})},e.prototype.updateFragment=function(e,t){return!1!==globalThis.__DEV__&&(0,f.cc)(e,"canonizeResults","cache.updateFragment"),this.batch({update:function(i){var n=(0,f.lz)("canonizeResults",function(){return i.readFragment(e)}),s=t(n);return null==s?n:(i.writeFragment((0,r.__assign)((0,r.__assign)({},e),{data:s})),s)}})},e}();!1!==globalThis.__DEV__&&(m.prototype.getMemoryInternals=h.tQ)},1574(e,t,i){"use strict";i.d(t,{Z:()=>n});var r=i(65959),n=function(e){function t(i,r,n,s){var o,a=e.call(this,i)||this;if(a.message=i,a.path=r,a.query=n,a.variables=s,Array.isArray(a.path)){a.missing=a.message;for(var l=a.path.length-1;l>=0;--l)a.missing=((o={})[a.path[l]]=a.missing,o)}else a.missing=a.path;return a.__proto__=t.prototype,a}return(0,r.__extends)(t,e),t}(Error)},47422(e,t,i){"use strict";i.d(t,{$3:()=>h,I6:()=>f,T9:()=>w,Ui:()=>v,Xx:()=>m,d1:()=>S,gk:()=>C,iJ:()=>y,lq:()=>E,mv:()=>b,or:()=>p});var r=i(14270),n=i(48555),s=i(47812),o=i(99310),a=i(45902),l=i(79e3),c=i(1164),u=i(58173),h=Object.prototype.hasOwnProperty;function d(e){return null==e}function p(e,t){var i=e.__typename,r=e.id,n=e._id;if("string"==typeof i&&(t&&(t.keyObject=d(r)?d(n)?void 0:{_id:n}:{id:r}),d(r)&&!d(n)&&(r=n),!d(r)))return"".concat(i,":").concat("number"==typeof r||"string"==typeof r?r:JSON.stringify(r))}var g={dataIdFromObject:p,addTypename:!0,resultCaching:!0,canonizeResults:!1};function f(e){return(0,u.o)(g,e)}function m(e){var t=e.canonizeResults;return void 0===t?g.canonizeResults:t}function v(e,t){return(0,o.A_)(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var C=/^[_a-z][_0-9a-z]*/i;function y(e){var t=e.match(C);return t?t[0]:e}function w(e,t,i){return!!(0,c.U)(t)&&((0,l.c)(t)?t.every(function(t){return w(e,t,i)}):e.selections.every(function(e){if((0,o.dt)(e)&&(0,r.MS)(e,i)){var n=(0,o.ue)(e);return h.call(t,n)&&(!e.selectionSet||w(e.selectionSet,t[n],i))}return!0}))}function S(e){return(0,c.U)(e)&&!(0,o.A_)(e)&&!(0,l.c)(e)}function b(){return new a.ZI}function E(e,t){var i=(0,n.JG)((0,s.zK)(e));return{fragmentMap:i,lookupFragment:function(e){var r=i[e];return!r&&t&&(r=t.lookup(e)),r||null}}}},70415(e,t,i){"use strict";i.d(t,{D:()=>we});var r=i(65959),n=i(131),s=i(81987),o=i(45063),a=i(30622),l=i(1574),c=i(78917),u=i(83906),h=i(19360),d=i(26497),p=i(33137),g=i(99310),f=i(49270),m=i(97703),v=i(58173),C=i(47812),y=i(45902),w=i(14270),S=i(48555),b=i(12209),E=i(1164),A=i(69796),T=i(47422),M=Object.create(null),R=function(){return M},_=Object.create(null),P=function(){function e(e,t){var i=this;this.policies=e,this.group=t,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(e,t){return(0,b.G)((0,g.A_)(e)?i.get(e.__ref,t):e&&e[t])},this.canRead=function(e){return(0,g.A_)(e)?i.has(e.__ref):"object"==typeof e},this.toReference=function(e,t){if("string"==typeof e)return(0,g.WU)(e);if((0,g.A_)(e))return e;var r=i.policies.identify(e)[0];if(r){var n=(0,g.WU)(r);return t&&i.merge(r,e),n}}}return e.prototype.toObject=function(){return(0,r.__assign)({},this.data)},e.prototype.has=function(e){return void 0!==this.lookup(e,!0)},e.prototype.get=function(e,t){if(this.group.depend(e,t),T.$3.call(this.data,e)){var i=this.data[e];if(i&&T.$3.call(i,t))return i[t]}return"__typename"===t&&T.$3.call(this.policies.rootTypenamesById,e)?this.policies.rootTypenamesById[e]:this instanceof L?this.parent.get(e,t):void 0},e.prototype.lookup=function(e,t){return t&&this.group.depend(e,"__exists"),T.$3.call(this.data,e)?this.data[e]:this instanceof L?this.parent.lookup(e,t):this.policies.rootTypenamesById[e]?Object.create(null):void 0},e.prototype.merge=function(e,t){var i,r=this;(0,g.A_)(e)&&(e=e.__ref),(0,g.A_)(t)&&(t=t.__ref);var s="string"==typeof e?this.lookup(i=e):e,o="string"==typeof t?this.lookup(i=t):t;if(o){(0,n.V1)("string"==typeof i,2);var a=new y.ZI(O).merge(s,o);if(this.data[i]=a,a!==s&&(delete this.refs[i],this.group.caching)){var l=Object.create(null);s||(l.__exists=1),Object.keys(o).forEach(function(e){if(!s||s[e]!==a[e]){l[e]=1;var t=(0,T.iJ)(e);t===e||r.policies.hasKeyArgs(a.__typename,t)||(l[t]=1),void 0!==a[e]||r instanceof L||delete a[e]}}),!l.__typename||s&&s.__typename||this.policies.rootTypenamesById[i]!==a.__typename||delete l.__typename,Object.keys(l).forEach(function(e){return r.group.dirty(i,e)})}}},e.prototype.modify=function(e,t){var i=this,s=this.lookup(e);if(s){var o=Object.create(null),a=!1,l=!0,c={DELETE:M,INVALIDATE:_,isReference:g.A_,toReference:this.toReference,canRead:this.canRead,readField:function(t,r){return i.policies.readField("string"==typeof t?{fieldName:t,from:r||(0,g.WU)(e)}:t,{store:i})}};if(Object.keys(s).forEach(function(u){var h=(0,T.iJ)(u),d=s[u];if(void 0!==d){var p="function"==typeof t?t:t[u]||t[h];if(p){var f=p===R?M:p((0,b.G)(d),(0,r.__assign)((0,r.__assign)({},c),{fieldName:h,storeFieldName:u,storage:i.getStorage(e,u)}));if(f===_)i.group.dirty(e,u);else if(f===M&&(f=void 0),f!==d&&(o[u]=f,a=!0,d=f,!1!==globalThis.__DEV__)){var m=function(e){if(void 0===i.lookup(e.__ref))return!1!==globalThis.__DEV__&&n.V1.warn(3,e),!0};if((0,g.A_)(f))m(f);else if(Array.isArray(f))for(var v=!1,C=void 0,y=0,w=f;y<w.length;y++){var S=w[y];if((0,g.A_)(S)){if(v=!0,m(S))break}else"object"==typeof S&&S&&i.policies.identify(S)[0]&&(C=S);if(v&&void 0!==C){!1!==globalThis.__DEV__&&n.V1.warn(4,C);break}}}}void 0!==d&&(l=!1)}}),a)return this.merge(e,o),l&&(this instanceof L?this.data[e]=void 0:delete this.data[e],this.group.dirty(e,"__exists")),!0}return!1},e.prototype.delete=function(e,t,i){var r,n=this.lookup(e);if(n){var s=this.getFieldValue(n,"__typename"),o=t&&i?this.policies.getStoreFieldName({typename:s,fieldName:t,args:i}):t;return this.modify(e,o?((r={})[o]=R,r):R)}return!1},e.prototype.evict=function(e,t){var i=!1;return e.id&&(T.$3.call(this.data,e.id)&&(i=this.delete(e.id,e.fieldName,e.args)),this instanceof L&&this!==t&&(i=this.parent.evict(e,t)||i),(e.fieldName||i)&&this.group.dirty(e.id,e.fieldName||"__exists")),i},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var e=this,t=this.toObject(),i=[];return this.getRootIdSet().forEach(function(t){T.$3.call(e.policies.rootTypenamesById,t)||i.push(t)}),i.length&&(t.__META={extraRootIds:i.sort()}),t},e.prototype.replace=function(e){var t=this;if(Object.keys(this.data).forEach(function(i){e&&T.$3.call(e,i)||t.delete(i)}),e){var i=e.__META,n=(0,r.__rest)(e,["__META"]);Object.keys(n).forEach(function(e){t.merge(e,n[e])}),i&&i.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(e){return this.rootIds[e]=(this.rootIds[e]||0)+1},e.prototype.release=function(e){if(this.rootIds[e]>0){var t=--this.rootIds[e];return t||delete this.rootIds[e],t}return 0},e.prototype.getRootIdSet=function(e){return void 0===e&&(e=new Set),Object.keys(this.rootIds).forEach(e.add,e),this instanceof L?this.parent.getRootIdSet(e):Object.keys(this.policies.rootTypenamesById).forEach(e.add,e),e},e.prototype.gc=function(){var e=this,t=this.getRootIdSet(),i=this.toObject();t.forEach(function(r){T.$3.call(i,r)&&(Object.keys(e.findChildRefIds(r)).forEach(t.add,t),delete i[r])});var r=Object.keys(i);if(r.length){for(var n=this;n instanceof L;)n=n.parent;r.forEach(function(e){return n.delete(e)})}return r},e.prototype.findChildRefIds=function(e){if(!T.$3.call(this.refs,e)){var t=this.refs[e]=Object.create(null),i=this.data[e];if(!i)return t;var r=new Set([i]);r.forEach(function(e){(0,g.A_)(e)&&(t[e.__ref]=!0),(0,E.U)(e)&&Object.keys(e).forEach(function(t){var i=e[t];(0,E.U)(i)&&r.add(i)})})}return this.refs[e]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),x=function(){function e(e,t){void 0===t&&(t=null),this.caching=e,this.parent=t,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?(0,s.yN)():null,this.keyMaker=new A.b(m.et)},e.prototype.depend=function(e,t){if(this.d){this.d(D(e,t));var i=(0,T.iJ)(t);i!==t&&this.d(D(e,i)),this.parent&&this.parent.depend(e,t)}},e.prototype.dirty=function(e,t){this.d&&this.d.dirty(D(e,t),"__exists"===t?"forget":"setDirty")},e}();function D(e,t){return t+"#"+e}function I(e,t){F(e)&&e.group.depend(t,"__exists")}!function(e){var t=function(e){function t(t){var i=t.policies,r=t.resultCaching,n=void 0===r||r,s=t.seed,o=e.call(this,i,new x(n))||this;return o.stump=new N(o),o.storageTrie=new A.b(m.et),s&&o.replace(s),o}return(0,r.__extends)(t,e),t.prototype.addLayer=function(e,t){return this.stump.addLayer(e,t)},t.prototype.removeLayer=function(){return this},t.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},t}(e);e.Root=t}(P||(P={}));var L=function(e){function t(t,i,r,n){var s=e.call(this,i.policies,n)||this;return s.id=t,s.parent=i,s.replay=r,s.group=n,r(s),s}return(0,r.__extends)(t,e),t.prototype.addLayer=function(e,i){return new t(e,this,i,this.group)},t.prototype.removeLayer=function(e){var t=this,i=this.parent.removeLayer(e);return e===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(e){var r=t.data[e],n=i.lookup(e);n?r?r!==n&&Object.keys(r).forEach(function(i){(0,o.L)(r[i],n[i])||t.group.dirty(e,i)}):(t.group.dirty(e,"__exists"),Object.keys(n).forEach(function(i){t.group.dirty(e,i)})):t.delete(e)}),i):i===this.parent?this:i.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return(0,r.__assign)((0,r.__assign)({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(t){var i=this.parent.findChildRefIds(t);return T.$3.call(this.data,t)?(0,r.__assign)((0,r.__assign)({},i),e.prototype.findChildRefIds.call(this,t)):i},t.prototype.getStorage=function(){for(var e=this.parent;e.parent;)e=e.parent;return e.getStorage.apply(e,arguments)},t}(P),N=function(e){function t(t){return e.call(this,"EntityStore.Stump",t,function(){},new x(t.group.caching,t.group))||this}return(0,r.__extends)(t,e),t.prototype.removeLayer=function(){return this},t.prototype.merge=function(e,t){return this.parent.merge(e,t)},t}(L);function O(e,t,i){var r=e[i],n=t[i];return(0,o.L)(r,n)?r:n}function F(e){return!!(e instanceof P&&e.group.caching)}var k=i(79e3),G=function(){function e(){this.known=new(m.En?WeakSet:Set),this.pool=new A.b(m.et),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(e){return(0,E.U)(e)&&this.known.has(e)},e.prototype.pass=function(e){if((0,E.U)(e)){var t=function(e){return(0,E.U)(e)?(0,k.c)(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e):e}(e);return this.passes.set(t,e),t}return e},e.prototype.admit=function(e){var t=this;if((0,E.U)(e)){var i=this.passes.get(e);if(i)return i;switch(Object.getPrototypeOf(e)){case Array.prototype:if(this.known.has(e))return e;var r=e.map(this.admit,this);return(a=this.pool.lookupArray(r)).array||(this.known.add(a.array=r),!1!==globalThis.__DEV__&&Object.freeze(r)),a.array;case null:case Object.prototype:if(this.known.has(e))return e;var n=Object.getPrototypeOf(e),s=[n],o=this.sortedKeys(e);s.push(o.json);var a,l=s.length;if(o.sorted.forEach(function(i){s.push(t.admit(e[i]))}),!(a=this.pool.lookupArray(s)).object){var c=a.object=Object.create(n);this.known.add(c),o.sorted.forEach(function(e,t){c[e]=s[l+t]}),!1!==globalThis.__DEV__&&Object.freeze(c)}return a.object}}return e},e.prototype.sortedKeys=function(e){var t=Object.keys(e),i=this.pool.lookupArray(t);if(!i.keys){t.sort();var r=JSON.stringify(t);(i.keys=this.keysByJSON.get(r))||this.keysByJSON.set(r,i.keys={sorted:t,json:r})}return i.keys},e}();function V(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var H=function(){function e(e){var t=this;this.knownResults=new(m.et?WeakMap:Map),this.config=(0,v.o)(e,{addTypename:!1!==e.addTypename,canonizeResults:(0,T.Xx)(e)}),this.canon=e.canon||new G,this.executeSelectionSet=(0,s.LV)(function(e){var i,n=e.context.canonizeResults,s=V(e);s[3]=!n;var o=(i=t.executeSelectionSet).peek.apply(i,s);return o?n?(0,r.__assign)((0,r.__assign)({},o),{result:t.canon.admit(o.result)}):o:(I(e.context.store,e.enclosingRef.__ref),t.execSelectionSetImpl(e))},{max:this.config.resultCacheMaxSize||h.v["inMemoryCache.executeSelectionSet"]||5e4,keyArgs:V,makeCacheKey:function(e,t,i,r){if(F(i.store))return i.store.makeCacheKey(e,(0,g.A_)(t)?t.__ref:t,i.varString,r)}}),this.executeSubSelectedArray=(0,s.LV)(function(e){return I(e.context.store,e.enclosingRef.__ref),t.execSubSelectedArrayImpl(e)},{max:this.config.resultCacheMaxSize||h.v["inMemoryCache.executeSubSelectedArray"]||1e4,makeCacheKey:function(e){var t=e.field,i=e.array,r=e.context;if(F(r.store))return r.store.makeCacheKey(t,i,r.varString)}})}return e.prototype.resetCanon=function(){this.canon=new G},e.prototype.diffQueryAgainstStore=function(e){var t=e.store,i=e.query,n=e.rootId,s=void 0===n?"ROOT_QUERY":n,o=e.variables,a=e.returnPartialData,c=void 0===a||a,u=e.canonizeResults,h=void 0===u?this.config.canonizeResults:u,p=this.config.cache.policies;o=(0,r.__assign)((0,r.__assign)({},(0,C.wY)((0,C.AT)(i))),o);var f,m=(0,g.WU)(s),v=this.executeSelectionSet({selectionSet:(0,C.Vn)(i).selectionSet,objectOrReference:m,enclosingRef:m,context:(0,r.__assign)({store:t,query:i,policies:p,variables:o,varString:(0,d.M)(o),canonizeResults:h},(0,T.lq)(i,this.config.fragments))});if(v.missing&&(f=[new l.Z(B(v.missing),v.missing,i,o)],!c))throw f[0];return{result:v.result,complete:!f,missing:f}},e.prototype.isFresh=function(e,t,i,r){if(F(r.store)&&this.knownResults.get(e)===i){var n=this.executeSelectionSet.peek(i,t,r,this.canon.isKnown(e));if(n&&e===n.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(e){var t=this,i=e.selectionSet,r=e.objectOrReference,s=e.enclosingRef,o=e.context;if((0,g.A_)(r)&&!o.policies.rootTypenamesById[r.__ref]&&!o.store.has(r.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(r.__ref," object")};var a,l=o.variables,c=o.policies,h=o.store.getFieldValue(r,"__typename"),d=[],p=new y.ZI;function m(e,t){var i;return e.missing&&(a=p.merge(a,((i={})[t]=e.missing,i))),e.result}this.config.addTypename&&"string"==typeof h&&!c.rootIdsByTypename[h]&&d.push({__typename:h});var v=new Set(i.selections);v.forEach(function(e){var i,C;if((0,w.MS)(e,l))if((0,g.dt)(e)){var y=c.readField({fieldName:e.name.value,field:e,variables:o.variables,from:r},o),b=(0,g.ue)(e);void 0===y?u.XY.added(e)||(a=p.merge(a,((i={})[b]="Can't find field '".concat(e.name.value,"' on ").concat((0,g.A_)(r)?r.__ref+" object":"object "+JSON.stringify(r,null,2)),i))):(0,k.c)(y)?y.length>0&&(y=m(t.executeSubSelectedArray({field:e,array:y,enclosingRef:s,context:o}),b)):e.selectionSet?null!=y&&(y=m(t.executeSelectionSet({selectionSet:e.selectionSet,objectOrReference:y,enclosingRef:(0,g.A_)(y)?y:s,context:o}),b)):o.canonizeResults&&(y=t.canon.pass(y)),void 0!==y&&d.push(((C={})[b]=y,C))}else{var E=(0,S.HQ)(e,o.lookupFragment);if(!E&&e.kind===f.b.FRAGMENT_SPREAD)throw(0,n.vA)(10,e.name.value);E&&c.fragmentMatches(E,h)&&E.selectionSet.selections.forEach(v.add,v)}});var C={result:(0,y.IM)(d),missing:a},E=o.canonizeResults?this.canon.admit(C):(0,b.G)(C);return E.result&&this.knownResults.set(E.result,i),E},e.prototype.execSubSelectedArrayImpl=function(e){var t,i=this,r=e.field,s=e.array,o=e.enclosingRef,a=e.context,l=new y.ZI;function c(e,i){var r;return e.missing&&(t=l.merge(t,((r={})[i]=e.missing,r))),e.result}return r.selectionSet&&(s=s.filter(a.store.canRead)),s=s.map(function(e,t){return null===e?null:(0,k.c)(e)?c(i.executeSubSelectedArray({field:r,array:e,enclosingRef:o,context:a}),t):r.selectionSet?c(i.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:e,enclosingRef:(0,g.A_)(e)?e:o,context:a}),t):(!1!==globalThis.__DEV__&&function(e,t,i){if(!t.selectionSet){var r=new Set([i]);r.forEach(function(i){(0,E.U)(i)&&((0,n.V1)(!(0,g.A_)(i),11,(0,T.Ui)(e,i),t.name.value),Object.values(i).forEach(r.add,r))})}}(a.store,r,e),e)}),{result:a.canonizeResults?this.canon.admit(s):s,missing:t}},e}();function B(e){try{JSON.stringify(e,function(e,t){if("string"==typeof t)throw t;return t})}catch(e){return e}}var z=i(37563),U=i(48670),W=i(67566),j=Object.create(null);function K(e){var t=JSON.stringify(e);return j[t]||(j[t]=Object.create(null))}function $(e){var t=K(e);return t.keyFieldsFn||(t.keyFieldsFn=function(t,i){var r=function(e,t){return i.readField(t,e)},s=i.keyObject=Y(e,function(e){var s=Z(i.storeObject,e,r);return void 0===s&&t!==i.storeObject&&T.$3.call(t,e[0])&&(s=Z(t,e,X)),(0,n.V1)(void 0!==s,5,e.join("."),t),s});return"".concat(i.typename,":").concat(JSON.stringify(s))})}function q(e){var t=K(e);return t.keyArgsFn||(t.keyArgsFn=function(t,i){var r=i.field,n=i.variables,s=i.fieldName,o=Y(e,function(e){var i=e[0],s=i.charAt(0);if("@"!==s)if("$"!==s){if(t)return Z(t,e)}else{var o=i.slice(1);if(n&&T.$3.call(n,o)){var a=e.slice(0);return a[0]=o,Z(n,a)}}else if(r&&(0,k.E)(r.directives)){var l=i.slice(1),c=r.directives.find(function(e){return e.name.value===l}),u=c&&(0,g.MB)(c,n);return u&&Z(u,e.slice(1))}}),a=JSON.stringify(o);return(t||"{}"!==a)&&(s+=":"+a),s})}function Y(e,t){var i=new y.ZI;return Q(e).reduce(function(e,r){var n,s=t(r);if(void 0!==s){for(var o=r.length-1;o>=0;--o)(n={})[r[o]]=s,s=n;e=i.merge(e,s)}return e},Object.create(null))}function Q(e){var t=K(e);if(!t.paths){var i=t.paths=[],r=[];e.forEach(function(t,n){(0,k.c)(t)?(Q(t).forEach(function(e){return i.push(r.concat(e))}),r.length=0):(r.push(t),(0,k.c)(e[n+1])||(i.push(r.slice(0)),r.length=0))})}return t.paths}function X(e,t){return e[t]}function Z(e,t,i){return i=i||X,J(t.reduce(function e(t,r){return(0,k.c)(t)?t.map(function(t){return e(t,r)}):t&&i(t,r)},e))}function J(e){return(0,E.U)(e)?(0,k.c)(e)?e.map(J):Y(Object.keys(e).sort(),function(t){return Z(e,t)}):e}var ee=i(71637);function te(e){return void 0!==e.args?e.args:e.field?(0,g.MB)(e.field,e.variables):null}var ie=function(){},re=function(e,t){return t.fieldName},ne=function(e,t,i){return(0,i.mergeObjects)(e,t)},se=function(e,t){return t},oe=function(){function e(e){this.config=e,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=(0,r.__assign)({dataIdFromObject:T.or},e),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),e.possibleTypes&&this.addPossibleTypes(e.possibleTypes),e.typePolicies&&this.addTypePolicies(e.typePolicies)}return e.prototype.identify=function(e,t){var i,n=this,s=t&&(t.typename||(null===(i=t.storeObject)||void 0===i?void 0:i.__typename))||e.__typename;if(s===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];var o,a=t&&t.storeObject||e,l=(0,r.__assign)((0,r.__assign)({},t),{typename:s,storeObject:a,readField:t&&t.readField||function(){var e=le(arguments,a);return n.readField(e,{store:n.cache.data,variables:e.variables})}}),c=s&&this.getTypePolicy(s),u=c&&c.keyFn||this.config.dataIdFromObject;return ee.yV.withValue(!0,function(){for(;u;){var t=u((0,r.__assign)((0,r.__assign)({},e),a),l);if(!(0,k.c)(t)){o=t;break}u=$(t)}}),o=o?String(o):void 0,l.keyObject?[o,l.keyObject]:[o]},e.prototype.addTypePolicies=function(e){var t=this;Object.keys(e).forEach(function(i){var n=e[i],s=n.queryType,o=n.mutationType,a=n.subscriptionType,l=(0,r.__rest)(n,["queryType","mutationType","subscriptionType"]);s&&t.setRootTypename("Query",i),o&&t.setRootTypename("Mutation",i),a&&t.setRootTypename("Subscription",i),T.$3.call(t.toBeAdded,i)?t.toBeAdded[i].push(l):t.toBeAdded[i]=[l]})},e.prototype.updateTypePolicy=function(e,t,i){var r=this.getTypePolicy(e),n=t.keyFields,s=t.fields;function o(e,t){e.merge="function"==typeof t?t:!0===t?ne:!1===t?se:e.merge}o(r,t.merge),r.keyFn=!1===n?ie:(0,k.c)(n)?$(n):"function"==typeof n?n:r.keyFn,s&&Object.keys(s).forEach(function(t){var r=i[t];r&&(null==r?void 0:r.typename)===e||(r=i[t]={typename:e});var n=s[t];if("function"==typeof n)r.read=n;else{var a=n.keyArgs,l=n.read,c=n.merge;r.keyFn=!1===a?re:(0,k.c)(a)?q(a):"function"==typeof a?a:r.keyFn,"function"==typeof l&&(r.read=l),o(r,c)}r.read&&r.merge&&(r.keyFn=r.keyFn||re)})},e.prototype.setRootTypename=function(e,t){void 0===t&&(t=e);var i="ROOT_"+e.toUpperCase(),r=this.rootTypenamesById[i];t!==r&&((0,n.V1)(!r||r===e,6,e),r&&delete this.rootIdsByTypename[r],this.rootIdsByTypename[t]=i,this.rootTypenamesById[i]=t)},e.prototype.addPossibleTypes=function(e){var t=this;this.usingPossibleTypes=!0,Object.keys(e).forEach(function(i){t.getSupertypeSet(i,!0),e[i].forEach(function(e){t.getSupertypeSet(e,!0).add(i);var r=e.match(T.gk);r&&r[0]===e||t.fuzzySubtypes.set(e,new RegExp(e))})})},e.prototype.getTypePolicy=function(e){var t=this;if(!T.$3.call(this.typePolicies,e)){var i=this.typePolicies[e]=Object.create(null);i.fields=Object.create(null);var n=this.supertypeMap.get(e);!n&&this.fuzzySubtypes.size&&(n=this.getSupertypeSet(e,!0),this.fuzzySubtypes.forEach(function(i,r){if(i.test(e)){var s=t.supertypeMap.get(r);s&&s.forEach(function(e){return n.add(e)})}})),n&&n.size&&n.forEach(function(e){var n=t.getTypePolicy(e),s=n.fields,o=(0,r.__rest)(n,["fields"]);Object.assign(i,o),Object.assign(i.fields,s)})}var s=this.toBeAdded[e];return s&&s.length&&s.splice(0).forEach(function(i){t.updateTypePolicy(e,i,t.typePolicies[e].fields)}),this.typePolicies[e]},e.prototype.getFieldPolicy=function(e,t){if(e)return this.getTypePolicy(e).fields[t]},e.prototype.getSupertypeSet=function(e,t){var i=this.supertypeMap.get(e);return!i&&t&&this.supertypeMap.set(e,i=new Set),i},e.prototype.fragmentMatches=function(e,t,i,r){var s=this;if(!e.typeCondition)return!0;if(!t)return!1;var o=e.typeCondition.name.value;if(t===o)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(o))for(var a=this.getSupertypeSet(t,!0),l=[a],c=function(e){var t=s.getSupertypeSet(e,!1);t&&t.size&&l.indexOf(t)<0&&l.push(t)},u=!(!i||!this.fuzzySubtypes.size),h=!1,d=0;d<l.length;++d){var p=l[d];if(p.has(o))return a.has(o)||(h&&!1!==globalThis.__DEV__&&n.V1.warn(7,t,o),a.add(o)),!0;p.forEach(c),u&&d===l.length-1&&(0,T.T9)(e.selectionSet,i,r)&&(u=!1,h=!0,this.fuzzySubtypes.forEach(function(e,i){var r=t.match(e);r&&r[0]===t&&c(i)}))}return!1},e.prototype.hasKeyArgs=function(e,t){var i=this.getFieldPolicy(e,t);return!(!i||!i.keyFn)},e.prototype.getStoreFieldName=function(e){var t,i=e.typename,r=e.fieldName,n=this.getFieldPolicy(i,r),s=n&&n.keyFn;if(s&&i)for(var o={typename:i,fieldName:r,field:e.field||null,variables:e.variables},a=te(e);s;){var l=s(a,o);if(!(0,k.c)(l)){t=l||r;break}s=q(l)}return void 0===t&&(t=e.field?(0,g.Ii)(e.field,e.variables):(0,g.o5)(r,te(e))),!1===t?r:r===(0,T.iJ)(t)?t:r+":"+t},e.prototype.readField=function(e,t){var i=e.from;if(i&&(e.field||e.fieldName)){if(void 0===e.typename){var r=t.store.getFieldValue(i,"__typename");r&&(e.typename=r)}var n=this.getStoreFieldName(e),s=(0,T.iJ)(n),o=t.store.getFieldValue(i,n),a=this.getFieldPolicy(e.typename,s),l=a&&a.read;if(l){var c=ae(this,i,e,t,t.store.getStorage((0,g.A_)(i)?i.__ref:i,n));return W.bl.withValue(this.cache,l,[o,c])}return o}},e.prototype.getReadFunction=function(e,t){var i=this.getFieldPolicy(e,t);return i&&i.read},e.prototype.getMergeFunction=function(e,t,i){var r=this.getFieldPolicy(e,t),n=r&&r.merge;return!n&&i&&(n=(r=this.getTypePolicy(i))&&r.merge),n},e.prototype.runMergeFunction=function(e,t,i,r,n){var s=i.field,o=i.typename,a=i.merge;return a===ne?ce(r.store)(e,t):a===se?t:(r.overwrite&&(e=void 0),a(e,t,ae(this,void 0,{typename:o,fieldName:s.name.value,field:s,variables:r.variables},r,n||Object.create(null))))},e}();function ae(e,t,i,r,n){var s=e.getStoreFieldName(i),o=(0,T.iJ)(s),a=i.variables||r.variables,l=r.store,c=l.toReference,u=l.canRead;return{args:te(i),field:i.field||null,fieldName:o,storeFieldName:s,variables:a,isReference:g.A_,toReference:c,storage:n,cache:e.cache,canRead:u,readField:function(){return e.readField(le(arguments,t,a),r)},mergeObjects:ce(r.store)}}function le(e,t,i){var s,o=e[0],a=e[1],l=e.length;return"string"==typeof o?s={fieldName:o,from:l>1?a:t}:(s=(0,r.__assign)({},o),T.$3.call(s,"from")||(s.from=t)),!1!==globalThis.__DEV__&&void 0===s.from&&!1!==globalThis.__DEV__&&n.V1.warn(8,(0,U.p)(Array.from(e))),void 0===s.variables&&(s.variables=i),s}function ce(e){return function(t,i){if((0,k.c)(t)||(0,k.c)(i))throw(0,n.vA)(9);if((0,E.U)(t)&&(0,E.U)(i)){var s=e.getFieldValue(t,"__typename"),o=e.getFieldValue(i,"__typename");if(s&&o&&s!==o)return i;if((0,g.A_)(t)&&(0,T.d1)(i))return e.merge(t.__ref,i),t;if((0,T.d1)(t)&&(0,g.A_)(i))return e.merge(t,i.__ref),i;if((0,T.d1)(t)&&(0,T.d1)(i))return(0,r.__assign)((0,r.__assign)({},t),i)}return i}}function ue(e,t,i){var n="".concat(t).concat(i),s=e.flavors.get(n);return s||e.flavors.set(n,s=e.clientOnly===t&&e.deferred===i?e:(0,r.__assign)((0,r.__assign)({},e),{clientOnly:t,deferred:i})),s}var he=function(){function e(e,t,i){this.cache=e,this.reader=t,this.fragments=i}return e.prototype.writeToStore=function(e,t){var i=this,s=t.query,a=t.result,l=t.dataId,c=t.variables,u=t.overwrite,h=(0,C.Vu)(s),p=(0,T.mv)();c=(0,r.__assign)((0,r.__assign)({},(0,C.wY)(h)),c);var f=(0,r.__assign)((0,r.__assign)({store:e,written:Object.create(null),merge:function(e,t){return p.merge(e,t)},variables:c,varString:(0,d.M)(c)},(0,T.lq)(s,this.fragments)),{overwrite:!!u,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),m=this.processSelectionSet({result:a||Object.create(null),dataId:l,selectionSet:h.selectionSet,mergeTree:{map:new Map},context:f});if(!(0,g.A_)(m))throw(0,n.vA)(12,a);return f.incomingById.forEach(function(t,s){var a=t.storeObject,l=t.mergeTree,c=t.fieldNodeSet,u=(0,g.WU)(s);if(l&&l.map.size){var h=i.applyMerges(l,u,a,f);if((0,g.A_)(h))return;a=h}if(!1!==globalThis.__DEV__&&!f.overwrite){var d=Object.create(null);c.forEach(function(e){e.selectionSet&&(d[e.name.value]=!0)}),Object.keys(a).forEach(function(e){(function(e){return!0===d[(0,T.iJ)(e)]})(e)&&!function(e){var t=l&&l.map.get(e);return Boolean(t&&t.info&&t.info.merge)}(e)&&function(e,t,i,s){var a=function(e){var t=s.getFieldValue(e,i);return"object"==typeof t&&t},l=a(e);if(l){var c=a(t);if(c&&!(0,g.A_)(l)&&!(0,o.L)(l,c)&&!Object.keys(l).every(function(e){return void 0!==s.getFieldValue(c,e)})){var u=s.getFieldValue(e,"__typename")||s.getFieldValue(t,"__typename"),h=(0,T.iJ)(i),d="".concat(u,".").concat(h);if(!ve.has(d)){ve.add(d);var p=[];(0,k.c)(l)||(0,k.c)(c)||[l,c].forEach(function(e){var t=s.getFieldValue(e,"__typename");"string"!=typeof t||p.includes(t)||p.push(t)}),!1!==globalThis.__DEV__&&n.V1.warn(15,h,u,p.length?"either ensure all objects of type "+p.join(" and ")+" have an ID or a custom merge function, or ":"",d,(0,r.__assign)({},l),(0,r.__assign)({},c))}}}}(u,a,e,f.store)})}e.merge(s,a)}),e.retain(m.__ref),m},e.prototype.processSelectionSet=function(e){var t=this,i=e.dataId,s=e.result,o=e.selectionSet,a=e.context,l=e.mergeTree,c=this.cache.policies,h=Object.create(null),d=i&&c.rootTypenamesById[i]||(0,g.D$)(s,o,a.fragmentMap)||i&&a.store.get(i,"__typename");"string"==typeof d&&(h.__typename=d);var p=function(){var e=le(arguments,h,a.variables);if((0,g.A_)(e.from)){var t=a.incomingById.get(e.from.__ref);if(t){var i=c.readField((0,r.__assign)((0,r.__assign)({},e),{from:t.storeObject}),a);if(void 0!==i)return i}}return c.readField(e,a)},f=new Set;this.flattenFields(o,s,a,d).forEach(function(e,i){var r,o=(0,g.ue)(i),a=s[o];if(f.add(i),void 0!==a){var m=c.getStoreFieldName({typename:d,fieldName:i.name.value,field:i,variables:e.variables}),v=pe(l,m),C=t.processFieldValue(a,i,i.selectionSet?ue(e,!1,!1):e,v),y=void 0;i.selectionSet&&((0,g.A_)(C)||(0,T.d1)(C))&&(y=p("__typename",C));var w=c.getMergeFunction(d,i.name.value,y);w?v.info={field:i,typename:d,merge:w}:me(l,m),h=e.merge(h,((r={})[m]=C,r))}else!1===globalThis.__DEV__||e.clientOnly||e.deferred||u.XY.added(i)||c.getReadFunction(d,i.name.value)||!1!==globalThis.__DEV__&&n.V1.error(13,(0,g.ue)(i),s)});try{var m=c.identify(s,{typename:d,selectionSet:o,fragmentMap:a.fragmentMap,storeObject:h,readField:p}),v=m[0],C=m[1];i=i||v,C&&(h=a.merge(h,C))}catch(e){if(!i)throw e}if("string"==typeof i){var y=(0,g.WU)(i),w=a.written[i]||(a.written[i]=[]);if(w.indexOf(o)>=0)return y;if(w.push(o),this.reader&&this.reader.isFresh(s,y,o,a))return y;var S=a.incomingById.get(i);return S?(S.storeObject=a.merge(S.storeObject,h),S.mergeTree=ge(S.mergeTree,l),f.forEach(function(e){return S.fieldNodeSet.add(e)})):a.incomingById.set(i,{storeObject:h,mergeTree:fe(l)?void 0:l,fieldNodeSet:f}),y}return h},e.prototype.processFieldValue=function(e,t,i,r){var n=this;return t.selectionSet&&null!==e?(0,k.c)(e)?e.map(function(e,s){var o=n.processFieldValue(e,t,i,pe(r,s));return me(r,s),o}):this.processSelectionSet({result:e,selectionSet:t.selectionSet,context:i,mergeTree:r}):!1!==globalThis.__DEV__?(0,z.m)(e):e},e.prototype.flattenFields=function(e,t,i,r){void 0===r&&(r=(0,g.D$)(t,e,i.fragmentMap));var s=new Map,o=this.cache.policies,a=new A.b(!1);return function e(l,c){var u=a.lookup(l,c.clientOnly,c.deferred);u.visited||(u.visited=!0,l.selections.forEach(function(a){if((0,w.MS)(a,i.variables)){var l=c.clientOnly,u=c.deferred;if(l&&u||!(0,k.E)(a.directives)||a.directives.forEach(function(e){var t=e.name.value;if("client"===t&&(l=!0),"defer"===t){var r=(0,g.MB)(e,i.variables);r&&!1===r.if||(u=!0)}}),(0,g.dt)(a)){var h=s.get(a);h&&(l=l&&h.clientOnly,u=u&&h.deferred),s.set(a,ue(i,l,u))}else{var d=(0,S.HQ)(a,i.lookupFragment);if(!d&&a.kind===f.b.FRAGMENT_SPREAD)throw(0,n.vA)(14,a.name.value);d&&o.fragmentMatches(d,r,t,i.variables)&&e(d.selectionSet,ue(i,l,u))}}}))}(e,i),s},e.prototype.applyMerges=function(e,t,i,s,o){var a,l=this;if(e.map.size&&!(0,g.A_)(i)){var c,u=(0,k.c)(i)||!(0,g.A_)(t)&&!(0,T.d1)(t)?void 0:t,h=i;u&&!o&&(o=[(0,g.A_)(u)?u.__ref:u]);var d=function(e,t){return(0,k.c)(e)?"number"==typeof t?e[t]:void 0:s.store.getFieldValue(e,String(t))};e.map.forEach(function(e,t){var i=d(u,t),r=d(h,t);if(void 0!==r){o&&o.push(t);var a=l.applyMerges(e,i,r,s,o);a!==r&&(c=c||new Map).set(t,a),o&&(0,n.V1)(o.pop()===t)}}),c&&(i=(0,k.c)(h)?h.slice(0):(0,r.__assign)({},h),c.forEach(function(e,t){i[t]=e}))}return e.info?this.cache.policies.runMergeFunction(t,i,e.info,s,o&&(a=s.store).getStorage.apply(a,o)):i},e}(),de=[];function pe(e,t){var i=e.map;return i.has(t)||i.set(t,de.pop()||{map:new Map}),i.get(t)}function ge(e,t){if(e===t||!t||fe(t))return e;if(!e||fe(e))return t;var i=e.info&&t.info?(0,r.__assign)((0,r.__assign)({},e.info),t.info):e.info||t.info,n=e.map.size&&t.map.size,s={info:i,map:n?new Map:e.map.size?e.map:t.map};if(n){var o=new Set(t.map.keys());e.map.forEach(function(e,i){s.map.set(i,ge(e,t.map.get(i))),o.delete(i)}),o.forEach(function(i){s.map.set(i,ge(t.map.get(i),e.map.get(i)))})}return s}function fe(e){return!e||!(e.info||e.map.size)}function me(e,t){var i=e.map,r=i.get(t);r&&fe(r)&&(de.push(r),i.delete(t))}var ve=new Set,Ce=i(27231),ye=i(30301),we=function(e){function t(t){void 0===t&&(t={});var i=e.call(this)||this;return i.watches=new Set,i.addTypenameTransform=new c.c(u.XY),i.assumeImmutableResults=!0,i.makeVar=W.UT,i.txCount=0,!1!==globalThis.__DEV__&&((0,ye.cc)(t,"addTypename","InMemoryCache","Please remove the `addTypename` option when initializing `InMemoryCache`."),(0,ye.cc)(t,"canonizeResults","InMemoryCache","Please remove the `canonizeResults` option when initializing `InMemoryCache`.")),i.config=(0,T.I6)(t),i.addTypename=!!i.config.addTypename,i.policies=new oe({cache:i,dataIdFromObject:i.config.dataIdFromObject,possibleTypes:i.config.possibleTypes,typePolicies:i.config.typePolicies}),i.init(),i}return(0,r.__extends)(t,e),t.prototype.init=function(){var e=this.data=new P.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=e.stump,this.resetResultCache()},t.prototype.resetResultCache=function(e){var t=this,i=this.storeReader,r=this.config.fragments;this.addTypenameTransform.resetCache(),null==r||r.resetCaches(),this.storeWriter=new he(this,this.storeReader=new H({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:(0,T.Xx)(this.config),canon:e?void 0:i&&i.canon,fragments:r}),r),this.maybeBroadcastWatch=(0,s.LV)(function(e,i){return t.broadcastWatch(e,i)},{max:this.config.resultCacheMaxSize||h.v["inMemoryCache.maybeBroadcastWatch"]||5e3,makeCacheKey:function(e){var i=e.optimistic?t.optimisticData:t.data;if(F(i)){var r=e.optimistic,n=e.id,s=e.variables;return i.makeCacheKey(e.query,e.callback,(0,d.M)({optimistic:r,id:n,variables:s}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(e){return e.resetCaching()})},t.prototype.restore=function(e){return this.init(),e&&this.data.replace(e),this},t.prototype.extract=function(e){return void 0===e&&(e=!1),(e?this.optimisticData:this.data).extract()},t.prototype.read=function(e){!1!==globalThis.__DEV__&&(0,ye.cc)(e,"canonizeResults","cache.read");var t=e.returnPartialData,i=void 0!==t&&t;try{return this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:i})).result||null}catch(e){if(e instanceof l.Z)return null;throw e}},t.prototype.write=function(e){try{return++this.txCount,this.storeWriter.writeToStore(this.data,e)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.modify=function(e){if(T.$3.call(e,"id")&&!e.id)return!1;var t=e.optimistic?this.optimisticData:this.data;try{return++this.txCount,t.modify(e.id||"ROOT_QUERY",e.fields)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.diff=function(e){return!1!==globalThis.__DEV__&&(0,ye.cc)(e,"canonizeResults","cache.diff"),this.storeReader.diffQueryAgainstStore((0,r.__assign)((0,r.__assign)({},e),{store:e.optimistic?this.optimisticData:this.data,rootId:e.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(e){var t=this;return this.watches.size||(0,W.MS)(this),this.watches.add(e),e.immediate&&this.maybeBroadcastWatch(e),function(){t.watches.delete(e)&&!t.watches.size&&(0,W.WR)(t),t.maybeBroadcastWatch.forget(e)}},t.prototype.gc=function(e){!1!==globalThis.__DEV__&&(0,ye.cc)(e||{},"resetResultIdentities","cache.gc","First ensure all usages of `canonizeResults` are removed, then remove this option."),d.M.reset(),p.y.reset();var t=this.optimisticData.gc();return e&&!this.txCount&&(e.resetResultCache?this.resetResultCache(e.resetResultIdentities):e.resetResultIdentities&&this.storeReader.resetCanon()),t},t.prototype.retain=function(e,t){return(t?this.optimisticData:this.data).retain(e)},t.prototype.release=function(e,t){return(t?this.optimisticData:this.data).release(e)},t.prototype.identify=function(e){if((0,g.A_)(e))return e.__ref;try{return this.policies.identify(e)[0]}catch(e){!1!==globalThis.__DEV__&&n.V1.warn(e)}},t.prototype.evict=function(e){if(!e.id){if(T.$3.call(e,"id"))return!1;e=(0,r.__assign)((0,r.__assign)({},e),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(e,this.data)}finally{--this.txCount||!1===e.broadcast||this.broadcastWatches()}},t.prototype.reset=function(e){var t=this;return this.init(),d.M.reset(),e&&e.discardWatches?(this.watches.forEach(function(e){return t.maybeBroadcastWatch.forget(e)}),this.watches.clear(),(0,W.WR)(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(e){var t=this.optimisticData.removeLayer(e);t!==this.optimisticData&&(this.optimisticData=t,this.broadcastWatches())},t.prototype.batch=function(e){var t,i=this,n=e.update,s=e.optimistic,o=void 0===s||s,a=e.removeOptimistic,l=e.onWatchUpdated,c=function(e){var r=i,s=r.data,o=r.optimisticData;++i.txCount,e&&(i.data=i.optimisticData=e);try{return t=n(i)}finally{--i.txCount,i.data=s,i.optimisticData=o}},u=new Set;return l&&!this.txCount&&this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e){return u.add(e),!1}})),"string"==typeof o?this.optimisticData=this.optimisticData.addLayer(o,c):!1===o?c(this.data):c(),"string"==typeof a&&(this.optimisticData=this.optimisticData.removeLayer(a)),l&&u.size?(this.broadcastWatches((0,r.__assign)((0,r.__assign)({},e),{onWatchUpdated:function(e,t){var i=l.call(this,e,t);return!1!==i&&u.delete(e),i}})),u.size&&u.forEach(function(e){return i.maybeBroadcastWatch.dirty(e)})):this.broadcastWatches(e),t},t.prototype.performTransaction=function(e,t){return this.batch({update:e,optimistic:t||null!==t})},t.prototype.transformDocument=function(e){return this.addTypenameToDocument(this.addFragmentsToDocument(e))},t.prototype.fragmentMatches=function(e,t){return this.policies.fragmentMatches(e,t)},t.prototype.lookupFragment=function(e){var t;return(null===(t=this.config.fragments)||void 0===t?void 0:t.lookup(e))||null},t.prototype.broadcastWatches=function(e){var t=this;this.txCount||this.watches.forEach(function(i){return t.maybeBroadcastWatch(i,e)})},t.prototype.addFragmentsToDocument=function(e){var t=this.config.fragments;return t?t.transform(e):e},t.prototype.addTypenameToDocument=function(e){return this.addTypename?this.addTypenameTransform.transformDocument(e):e},t.prototype.broadcastWatch=function(e,t){var i=this,r=e.lastDiff,n=(0,ye.lz)("canonizeResults",function(){return i.diff(e)});t&&(e.optimistic&&"string"==typeof t.optimistic&&(n.fromOptimisticTransaction=!0),t.onWatchUpdated&&!1===t.onWatchUpdated.call(this,e,n,r))||r&&(0,o.L)(r.result,n.result)||e.callback(e.lastDiff=n,r)},t}(a.k);!1!==globalThis.__DEV__&&(we.prototype.getMemoryInternals=Ce.cM)},67566(e,t,i){"use strict";i.d(t,{MS:()=>l,UT:()=>c,WR:()=>a,bl:()=>n});var r=i(81987),n=new r.DX,s=new WeakMap;function o(e){var t=s.get(e);return t||s.set(e,t={vars:new Set,dep:(0,r.yN)()}),t}function a(e){o(e).vars.forEach(function(t){return t.forgetCache(e)})}function l(e){o(e).vars.forEach(function(t){return t.attachCache(e)})}function c(e){var t=new Set,i=new Set,r=function(a){if(arguments.length>0){if(e!==a){e=a,t.forEach(function(e){o(e).dep.dirty(r),function(e){e.broadcastWatches&&e.broadcastWatches()}(e)});var l=Array.from(i);i.clear(),l.forEach(function(t){return t(e)})}}else{var c=n.getValue();c&&(s(c),o(c).dep(r))}return e};r.onNextChange=function(e){return i.add(e),function(){i.delete(e)}};var s=r.attachCache=function(e){return t.add(e),o(e).vars.add(r),r};return r.forgetCache=function(e){return t.delete(e)},r}},50953(e,t,i){"use strict";i.d(t,{R:()=>Z});var r=i(65959),n=i(131),s=i(3224),o=i(34109),a=i(29527),l=i(39781),c=i(45063),u=i(94537),h=i(14270),d=i(83906),p=i(48555),g=i(26497),f=i(78917),m=i(34471),v=i(28931),C=i(79e3),y=i(47812),w=i(99310),S=i(1164),b=i(66566),E=i(74140),A=i(84382),T=i(17303),M=i(78440),R=i(49995),_=i(45902),P=i(97703),x=i(30301),D=new(P.et?WeakMap:Map);function I(e,t){var i=e[t];"function"==typeof i&&(e[t]=function(){return D.set(e,(D.get(e)+1)%1e15),i.apply(this,arguments)})}var L=function(){function e(e,t){void 0===t&&(t=e.generateQueryId()),this.queryId=t,this.document=null,this.lastRequestId=1,this.stopped=!1,this.observableQuery=null;var i=this.cache=e.cache;D.has(i)||(D.set(i,0),I(i,"evict"),I(i,"modify"),I(i,"reset"))}return e.prototype.init=function(e){var t=e.networkStatus||R.pT.loading;return this.variables&&this.networkStatus!==R.pT.loading&&!(0,c.L)(this.variables,e.variables)&&(t=R.pT.setVariables),(0,c.L)(e.variables,this.variables)||(this.lastDiff=void 0,this.cancel()),Object.assign(this,{document:e.document,variables:e.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:t}),e.observableQuery&&this.setObservableQuery(e.observableQuery),e.lastRequestId&&(this.lastRequestId=e.lastRequestId),this},e.prototype.resetDiff=function(){this.lastDiff=void 0},e.prototype.getDiff=function(){var e=this,t=this.getDiffOptions();if(this.lastDiff&&(0,c.L)(t,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var i=this.observableQuery;if(i&&"no-cache"===i.options.fetchPolicy)return{complete:!1};var r=(0,x.lz)("canonizeResults",function(){return e.cache.diff(t)});return this.updateLastDiff(r,t),r},e.prototype.updateLastDiff=function(e,t){this.lastDiff=e?{diff:e,options:t||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(e){var t;return void 0===e&&(e=this.variables),{query:this.document,variables:e,returnPartialData:!0,optimistic:!0,canonizeResults:null===(t=this.observableQuery)||void 0===t?void 0:t.options.canonizeResults}},e.prototype.setDiff=function(e){var t,i=this,r=this.lastDiff&&this.lastDiff.diff;e&&!e.complete&&(0,x.lz)("getLastError",function(){var e;return null===(e=i.observableQuery)||void 0===e?void 0:e.getLastError()})||(this.updateLastDiff(e),(0,c.L)(r&&r.result,e&&e.result)||null===(t=this.observableQuery)||void 0===t||t.scheduleNotify())},e.prototype.setObservableQuery=function(e){e!==this.observableQuery&&(this.observableQuery=e,e&&(e.queryInfo=this))},e.prototype.stop=function(){var e;if(!this.stopped){this.stopped=!0,null===(e=this.observableQuery)||void 0===e||e.resetNotifications(),this.cancel();var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){var e;null===(e=this.cancelWatch)||void 0===e||e.call(this),this.cancelWatch=void 0},e.prototype.updateWatch=function(e){var t=this;void 0===e&&(e=this.variables);var i=this.observableQuery;if(!i||"no-cache"!==i.options.fetchPolicy){var n=(0,r.__assign)((0,r.__assign)({},this.getDiffOptions(e)),{watcher:this,callback:function(e){return t.setDiff(e)}});this.lastWatch&&(0,c.L)(n,this.lastWatch)||(this.cancel(),this.cancelWatch=this.cache.watch(this.lastWatch=n))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(e,t){var i=this.lastWrite;return!(i&&i.dmCount===D.get(this.cache)&&(0,c.L)(t,i.variables)&&(0,c.L)(e.data,i.result.data))},e.prototype.markResult=function(e,t,i,r){var n,s=this,o=new _.ZI,a=(0,C.E)(e.errors)?e.errors.slice(0):[];if(null===(n=this.observableQuery)||void 0===n||n.resetNotifications(),"incremental"in e&&(0,C.E)(e.incremental)){var l=(0,u.bd)(this.getDiff().result,e);e.data=l}else if("hasNext"in e&&e.hasNext){var h=this.getDiff();e.data=o.merge(h.result,e.data)}this.graphQLErrors=a,"no-cache"===i.fetchPolicy?this.updateLastDiff({result:e.data,complete:!0},this.getDiffOptions(i.variables)):0!==r&&(N(e,i.errorPolicy)?this.cache.performTransaction(function(n){if(s.shouldWrite(e,i.variables))n.writeQuery({query:t,data:e.data,variables:i.variables,overwrite:1===r}),s.lastWrite={result:e,variables:i.variables,dmCount:D.get(s.cache)};else if(s.lastDiff&&s.lastDiff.diff.complete)return void(e.data=s.lastDiff.diff.result);var o=s.getDiffOptions(i.variables),a=(0,x.lz)("canonizeResults",function(){return n.diff(o)});!s.stopped&&(0,c.L)(s.variables,i.variables)&&s.updateWatch(i.variables),s.updateLastDiff(a,o),a.complete&&(e.data=a.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=R.pT.ready},e.prototype.markError=function(e){var t;return this.networkStatus=R.pT.error,this.lastWrite=void 0,null===(t=this.observableQuery)||void 0===t||t.resetNotifications(),e.graphQLErrors&&(this.graphQLErrors=e.graphQLErrors),e.networkError&&(this.networkError=e.networkError),e},e}();function N(e,t){void 0===t&&(t="none");var i="ignore"===t||"all"===t,r=!(0,v.t)(e);return!r&&i&&e.data&&(r=!0),r}var O=i(33137),F=i(69796),k=i(75859),G=i(19360),V=i(94959),H=i(71637),B=i(13062),z=Object.prototype.hasOwnProperty,U=Object.create(null),W=function(){function e(e){var t=this;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new k.A(G.v["queryManager.getDocumentInfo"]||2e3),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new F.b(!1),this.noCacheWarningsByQueryId=new Set;var i=new f.c(function(e){return t.cache.transformDocument(e)},{cache:!1});this.cache=e.cache,this.link=e.link,this.defaultOptions=e.defaultOptions,this.queryDeduplication=e.queryDeduplication,this.clientAwareness=e.clientAwareness,this.localState=e.localState,this.ssrMode=e.ssrMode,this.assumeImmutableResults=e.assumeImmutableResults,this.dataMasking=e.dataMasking;var r=e.documentTransform;this.documentTransform=r?i.concat(r).concat(i):i,this.defaultContext=e.defaultContext||Object.create(null),(this.onBroadcast=e.onBroadcast)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var e=this;this.queries.forEach(function(t,i){e.stopQueryNoBroadcast(i)}),this.cancelPendingFetches((0,n.vA)(35))},e.prototype.cancelPendingFetches=function(e){this.fetchCancelFns.forEach(function(t){return t(e)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(e){return(0,r.__awaiter)(this,arguments,void 0,function(e){var t,i,s,o,a,l,c,u=e.mutation,h=e.variables,d=e.optimisticResponse,p=e.updateQueries,g=e.refetchQueries,f=void 0===g?[]:g,C=e.awaitRefetchQueries,y=void 0!==C&&C,w=e.update,S=e.onQueryUpdated,b=e.fetchPolicy,E=void 0===b?(null===(l=this.defaultOptions.mutate)||void 0===l?void 0:l.fetchPolicy)||"network-only":b,A=e.errorPolicy,M=void 0===A?(null===(c=this.defaultOptions.mutate)||void 0===c?void 0:c.errorPolicy)||"none":A,R=e.keepRootFields,_=e.context;return(0,r.__generator)(this,function(e){switch(e.label){case 0:return(0,n.V1)(u,36),(0,n.V1)("network-only"===E||"no-cache"===E,37),t=this.generateMutationId(),u=this.cache.transformForLink(this.transform(u)),i=this.getDocumentInfo(u).hasClientExports,h=this.getVariables(u,h),i?[4,this.localState.addExportedVariables(u,h,_)]:[3,2];case 1:h=e.sent(),e.label=2;case 2:return s=this.mutationStore&&(this.mutationStore[t]={mutation:u,variables:h,loading:!0,error:null}),o=d&&this.markMutationOptimistic(d,{mutationId:t,document:u,variables:h,fetchPolicy:E,errorPolicy:M,context:_,updateQueries:p,update:w,keepRootFields:R}),this.broadcastQueries(),a=this,[2,new Promise(function(e,i){return(0,m.x)(a.getObservableFromLink(u,(0,r.__assign)((0,r.__assign)({},_),{optimisticResponse:o?d:void 0}),h,{},!1),function(e){if((0,v.t)(e)&&"none"===M)throw new T.K4({graphQLErrors:(0,v.M)(e)});s&&(s.loading=!1,s.error=null);var i=(0,r.__assign)({},e);return"function"==typeof f&&(f=f(i)),"ignore"===M&&(0,v.t)(i)&&delete i.errors,a.markMutationResult({mutationId:t,result:i,document:u,variables:h,fetchPolicy:E,errorPolicy:M,context:_,update:w,updateQueries:p,awaitRefetchQueries:y,refetchQueries:f,removeOptimistic:o?t:void 0,onQueryUpdated:S,keepRootFields:R})}).subscribe({next:function(i){a.broadcastQueries(),"hasNext"in i&&!1!==i.hasNext||e((0,r.__assign)((0,r.__assign)({},i),{data:a.maskOperation({document:u,data:i.data,fetchPolicy:E,id:t})}))},error:function(e){s&&(s.loading=!1,s.error=e),o&&a.cache.removeOptimistic(t),a.broadcastQueries(),i(e instanceof T.K4?e:new T.K4({networkError:e}))}})})]}})})},e.prototype.markMutationResult=function(e,t){var i=this;void 0===t&&(t=this.cache);var n=e.result,s=[],o="no-cache"===e.fetchPolicy;if(!o&&N(n,e.errorPolicy)){if((0,u.ST)(n)||s.push({result:n.data,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}),(0,u.ST)(n)&&(0,C.E)(n.incremental)){var a=t.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0}),l=void 0;a.result&&(l=(0,u.bd)(a.result,n)),void 0!==l&&(n.data=l,s.push({result:l,dataId:"ROOT_MUTATION",query:e.document,variables:e.variables}))}var c=e.updateQueries;c&&this.queries.forEach(function(e,r){var o=e.observableQuery,a=o&&o.queryName;if(a&&z.call(c,a)){var l=c[a],u=i.queries.get(r),h=u.document,d=u.variables,p=t.diff({query:h,variables:d,returnPartialData:!0,optimistic:!1}),g=p.result;if(p.complete&&g){var f=l(g,{mutationResult:n,queryName:h&&(0,y.n4)(h)||void 0,queryVariables:d});f&&s.push({result:f,dataId:"ROOT_QUERY",query:h,variables:d})}}})}if(s.length>0||(e.refetchQueries||"").length>0||e.update||e.onQueryUpdated||e.removeOptimistic){var h=[];if(this.refetchQueries({updateCache:function(t){o||s.forEach(function(e){return t.write(e)});var a=e.update,l=!(0,u.YX)(n)||(0,u.ST)(n)&&!n.hasNext;if(a){if(!o){var c=t.diff({id:"ROOT_MUTATION",query:i.getDocumentInfo(e.document).asQuery,variables:e.variables,optimistic:!1,returnPartialData:!0});c.complete&&("incremental"in(n=(0,r.__assign)((0,r.__assign)({},n),{data:c.result}))&&delete n.incremental,"hasNext"in n&&delete n.hasNext)}l&&a(t,n,{context:e.context,variables:e.variables})}o||e.keepRootFields||!l||t.modify({id:"ROOT_MUTATION",fields:function(e,t){var i=t.fieldName,r=t.DELETE;return"__typename"===i?e:r}})},include:e.refetchQueries,optimistic:!1,removeOptimistic:e.removeOptimistic,onQueryUpdated:e.onQueryUpdated||null}).forEach(function(e){return h.push(e)}),e.awaitRefetchQueries||e.onQueryUpdated)return Promise.all(h).then(function(){return n})}return Promise.resolve(n)},e.prototype.markMutationOptimistic=function(e,t){var i=this,s="function"==typeof e?e(t.variables,{IGNORE:U}):e;return s!==U&&(this.cache.recordOptimisticTransaction(function(e){try{i.markMutationResult((0,r.__assign)((0,r.__assign)({},t),{result:{data:s}}),e)}catch(e){!1!==globalThis.__DEV__&&n.V1.error(e)}},t.mutationId),!0)},e.prototype.fetchQuery=function(e,t,i){return this.fetchConcastWithInfo(this.getOrCreateQuery(e),t,i).concast.promise},e.prototype.getQueryStore=function(){var e=Object.create(null);return this.queries.forEach(function(t,i){e[i]={variables:t.variables,networkStatus:t.networkStatus,networkError:t.networkError,graphQLErrors:t.graphQLErrors}}),e},e.prototype.resetErrors=function(e){var t=this.queries.get(e);t&&(t.networkError=void 0,t.graphQLErrors=[])},e.prototype.transform=function(e){return this.documentTransform.transformDocument(e)},e.prototype.getDocumentInfo=function(e){var t=this.transformCache;if(!t.has(e)){var i={hasClientExports:(0,h.f2)(e),hasForcedResolvers:this.localState.shouldForceResolvers(e),hasNonreactiveDirective:(0,h.d8)(["nonreactive"],e),nonReactiveQuery:(0,d.x3)(e),clientQuery:this.localState.clientQuery(e),serverQuery:(0,d.iz)([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"},{name:"unmask"}],e),defaultVars:(0,y.wY)((0,y.Vu)(e)),asQuery:(0,r.__assign)((0,r.__assign)({},e),{definitions:e.definitions.map(function(e){return"OperationDefinition"===e.kind&&"query"!==e.operation?(0,r.__assign)((0,r.__assign)({},e),{operation:"query"}):e})})};t.set(e,i)}return t.get(e)},e.prototype.getVariables=function(e,t){return(0,r.__assign)((0,r.__assign)({},this.getDocumentInfo(e).defaultVars),t)},e.prototype.watchQuery=function(e){var t=this.transform(e.query);void 0===(e=(0,r.__assign)((0,r.__assign)({},e),{variables:this.getVariables(t,e.variables)})).notifyOnNetworkStatusChange&&(e.notifyOnNetworkStatusChange=!1);var i=new L(this),n=new M.U({queryManager:this,queryInfo:i,options:e});return n.lastQuery=t,M.U.inactiveOnCreation.getValue()||this.queries.set(n.queryId,i),i.init({document:t,observableQuery:n,variables:n.variables}),n},e.prototype.query=function(e,t){var i=this;void 0===t&&(t=this.generateQueryId()),(0,n.V1)(e.query,38),(0,n.V1)("Document"===e.query.kind,39),(0,n.V1)(!e.returnPartialData,40),(0,n.V1)(!e.pollInterval,41);var s=this.transform(e.query);return this.fetchQuery(t,(0,r.__assign)((0,r.__assign)({},e),{query:s})).then(function(n){return n&&(0,r.__assign)((0,r.__assign)({},n),{data:i.maskOperation({document:s,data:n.data,fetchPolicy:e.fetchPolicy,id:t})})}).finally(function(){return i.stopQuery(t)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(e){this.stopQueryInStoreNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(e){var t=this.queries.get(e);t&&t.stop()},e.prototype.clearStore=function(e){return void 0===e&&(e={discardWatches:!0}),this.cancelPendingFetches((0,n.vA)(42)),this.queries.forEach(function(e){e.observableQuery?e.networkStatus=R.pT.loading:e.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(e)},e.prototype.getObservableQueries=function(e){var t=this;void 0===e&&(e="active");var i=new Map,s=new Map,o=new Map,a=new Set;return Array.isArray(e)&&e.forEach(function(e){if("string"==typeof e)s.set(e,e),o.set(e,!1);else if((0,w.Kc)(e)){var i=(0,O.y)(t.transform(e));s.set(i,(0,y.n4)(e)),o.set(i,!1)}else(0,S.U)(e)&&e.query&&a.add(e)}),this.queries.forEach(function(t,r){var n=t.observableQuery,s=t.document;if(n){if("all"===e)return void i.set(r,n);var a=n.queryName;if("standby"===n.options.fetchPolicy||"active"===e&&!n.hasObservers())return;("active"===e||a&&o.has(a)||s&&o.has((0,O.y)(s)))&&(i.set(r,n),a&&o.set(a,!0),s&&o.set((0,O.y)(s),!0))}}),a.size&&a.forEach(function(e){var s=(0,b.v)("legacyOneTimeQuery"),o=t.getOrCreateQuery(s).init({document:e.query,variables:e.variables}),a=new M.U({queryManager:t,queryInfo:o,options:(0,r.__assign)((0,r.__assign)({},e),{fetchPolicy:"network-only"})});(0,n.V1)(a.queryId===s),o.setObservableQuery(a),i.set(s,a)}),!1!==globalThis.__DEV__&&o.size&&o.forEach(function(e,t){if(!e){var i=s.get(t);i?!1!==globalThis.__DEV__&&n.V1.warn(43,i):!1!==globalThis.__DEV__&&n.V1.warn(44)}}),i},e.prototype.reFetchObservableQueries=function(e){var t=this;void 0===e&&(e=!1);var i=[];return this.getObservableQueries(e?"all":"active").forEach(function(r,n){var s=r.options.fetchPolicy;(0,x.lz)("resetLastResults",function(){return r.resetLastResults()}),(e||"standby"!==s&&"cache-only"!==s)&&i.push(r.refetch()),(t.queries.get(n)||r.queryInfo).setDiff(null)}),this.broadcastQueries(),Promise.all(i)},e.prototype.startGraphQLSubscription=function(e){var t=this,i=e.query,r=e.variables,n=e.fetchPolicy,s=e.errorPolicy,o=void 0===s?"none":s,a=e.context,l=void 0===a?{}:a,c=e.extensions,u=void 0===c?{}:c;i=this.transform(i),r=this.getVariables(i,r);var h=function(e){return t.getObservableFromLink(i,l,e,u).map(function(r){"no-cache"!==n&&(N(r,o)&&t.cache.write({query:i,result:r.data,dataId:"ROOT_SUBSCRIPTION",variables:e}),t.broadcastQueries());var s=(0,v.t)(r),a=(0,T.uR)(r);if(s||a){var l={};if(s&&(l.graphQLErrors=r.errors),a&&(l.protocolErrors=r.extensions[T.K$]),"none"===o||a)throw new T.K4(l)}return"ignore"===o&&delete r.errors,r})};if(this.getDocumentInfo(i).hasClientExports){var d=this.localState.addExportedVariables(i,r,l).then(h);return new E.c(function(e){var t=null;return d.then(function(i){return t=i.subscribe(e)},e.error),function(){return t&&t.unsubscribe()}})}return h(r)},e.prototype.stopQuery=function(e){this.stopQueryNoBroadcast(e),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(e){this.stopQueryInStoreNoBroadcast(e),this.removeQuery(e)},e.prototype.removeQuery=function(e){var t;this.fetchCancelFns.delete(e),this.queries.has(e)&&(null===(t=this.queries.get(e))||void 0===t||t.stop(),this.queries.delete(e))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(e){var t;return null===(t=e.observableQuery)||void 0===t?void 0:t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(e,t,i,n,s){var a,l,c=this;void 0===s&&(s=null!==(a=null==t?void 0:t.queryDeduplication)&&void 0!==a?a:this.queryDeduplication);var u=this.getDocumentInfo(e),h=u.serverQuery,d=u.clientQuery;if(h){var p=this.inFlightLinkObservables,f=this.link,v={query:h,variables:i,operationName:(0,y.n4)(h)||void 0,context:this.prepareContext((0,r.__assign)((0,r.__assign)({},t),{forceFetch:!s})),extensions:n};if(t=v.context,s){var C=(0,O.y)(h),w=(0,g.M)(i),S=p.lookup(C,w);if(!(l=S.observable)){var b=new A.E([(0,o.g)(f,v)]);l=S.observable=b,b.beforeNext(function e(t,i){"next"===t&&"hasNext"in i&&i.hasNext?b.beforeNext(e):p.remove(C,w)})}}else l=new A.E([(0,o.g)(f,v)])}else l=new A.E([E.c.of({data:{}})]),t=this.prepareContext(t);return d&&(l=(0,m.x)(l,function(e){return c.localState.runResolvers({document:d,remoteResult:e,context:t,variables:i})})),l},e.prototype.getResultsFromLink=function(e,t,i){var r=e.lastRequestId=this.generateRequestId(),n=this.cache.transformForLink(i.query);return(0,m.x)(this.getObservableFromLink(n,i.context,i.variables),function(s){var o=(0,v.M)(s),a=o.length>0,l=i.errorPolicy;if(r>=e.lastRequestId){if(a&&"none"===l)throw e.markError(new T.K4({graphQLErrors:o}));e.markResult(s,n,i,t),e.markReady()}var c={data:s.data,loading:!1,networkStatus:R.pT.ready};return a&&"none"===l&&(c.data=void 0),a&&"ignore"!==l&&(c.errors=o,c.networkStatus=R.pT.error),c},function(t){var i=(0,T.Mn)(t)?t:new T.K4({networkError:t});throw r>=e.lastRequestId&&e.markError(i),i})},e.prototype.fetchConcastWithInfo=function(e,t,i,r){var n=this;void 0===i&&(i=R.pT.loading),void 0===r&&(r=t.query);var s,o,a=this.getVariables(r,t.variables),l=this.defaultOptions.watchQuery,c=t.fetchPolicy,u=void 0===c?l&&l.fetchPolicy||"cache-first":c,h=t.errorPolicy,d=void 0===h?l&&l.errorPolicy||"none":h,p=t.returnPartialData,g=void 0!==p&&p,f=t.notifyOnNetworkStatusChange,m=void 0!==f&&f,v=t.context,C=void 0===v?{}:v,y=Object.assign({},t,{query:r,variables:a,fetchPolicy:u,errorPolicy:d,returnPartialData:g,notifyOnNetworkStatusChange:m,context:C}),w=function(r){y.variables=r;var s=n.fetchQueryByPolicy(e,y,i);return"standby"!==y.fetchPolicy&&s.sources.length>0&&e.observableQuery&&e.observableQuery.applyNextFetchPolicy("after-fetch",t),s},S=function(){return n.fetchCancelFns.delete(e.queryId)};if(this.fetchCancelFns.set(e.queryId,function(e){S(),setTimeout(function(){return s.cancel(e)})}),this.getDocumentInfo(y.query).hasClientExports)s=new A.E(this.localState.addExportedVariables(y.query,y.variables,y.context).then(w).then(function(e){return e.sources})),o=!0;else{var b=w(y.variables);o=b.fromLink,s=new A.E(b.sources)}return s.promise.then(S,S),{concast:s,fromLink:o}},e.prototype.refetchQueries=function(e){var t=this,i=e.updateCache,r=e.include,n=e.optimistic,s=void 0!==n&&n,o=e.removeOptimistic,a=void 0===o?s?(0,b.v)("refetchQueries"):void 0:o,l=e.onQueryUpdated,c=new Map;r&&this.getObservableQueries(r).forEach(function(e,i){c.set(i,{oq:e,lastDiff:(t.queries.get(i)||e.queryInfo).getDiff()})});var u=new Map;return i&&this.cache.batch({update:i,optimistic:s&&a||!1,removeOptimistic:a,onWatchUpdated:function(e,t,i){var r=e.watcher instanceof L&&e.watcher.observableQuery;if(r){if(l){c.delete(r.queryId);var n=l(r,t,i);return!0===n&&(n=r.refetch()),!1!==n&&u.set(r,n),n}null!==l&&c.set(r.queryId,{oq:r,lastDiff:i,diff:t})}}}),c.size&&c.forEach(function(e,i){var r,n=e.oq,s=e.lastDiff,o=e.diff;l&&(o||(o=(0,x.lz)("canonizeResults",function(){return t.cache.diff(n.queryInfo.getDiffOptions())})),r=l(n,o,s)),l&&!0!==r||(r=n.refetch()),!1!==r&&u.set(n,r),i.indexOf("legacyOneTimeQuery")>=0&&t.stopQueryNoBroadcast(i)}),a&&this.cache.removeOptimistic(a),u},e.prototype.maskOperation=function(e){var t,i,r,s=e.document,o=e.data;if(!1!==globalThis.__DEV__){var a=e.fetchPolicy,l=e.id,c=null===(t=(0,y.Vu)(s))||void 0===t?void 0:t.operation,u=(null!==(i=null==c?void 0:c[0])&&void 0!==i?i:"o")+l;!this.dataMasking||"no-cache"!==a||(0,p.s6)(s)||this.noCacheWarningsByQueryId.has(u)||(this.noCacheWarningsByQueryId.add(u),!1!==globalThis.__DEV__&&n.V1.warn(45,null!==(r=(0,y.n4)(s))&&void 0!==r?r:"Unnamed ".concat(null!=c?c:"operation")))}return this.dataMasking?function(e,t,i){var r;if(!i.fragmentMatches)return!1!==globalThis.__DEV__&&(0,H.Ki)(),e;var s=(0,y.Vu)(t);return(0,n.V1)(s,63),null==e?e:(0,V.S)(e,s.selectionSet,{operationType:s.operation,operationName:null===(r=s.name)||void 0===r?void 0:r.value,fragmentMap:(0,p.JG)((0,y.zK)(t)),cache:i,mutableTargets:new H.jq,knownChanged:new H.xm})}(o,s,this.cache):o},e.prototype.maskFragment=function(e){var t=e.data,i=e.fragment,r=e.fragmentName;return this.dataMasking?(0,B.z)(t,i,this.cache,r):t},e.prototype.fetchQueryByPolicy=function(e,t,i){var n=this,s=t.query,o=t.variables,a=t.fetchPolicy,l=t.refetchWritePolicy,u=t.errorPolicy,h=t.returnPartialData,d=t.context,p=t.notifyOnNetworkStatusChange,g=e.networkStatus;e.init({document:s,variables:o,networkStatus:i});var f=function(){return e.getDiff()},m=function(t,i){void 0===i&&(i=e.networkStatus||R.pT.loading);var a=t.result;!1===globalThis.__DEV__||h||(0,c.L)(a,{})||(0,M.y)(t.missing);var l=function(e){return E.c.of((0,r.__assign)({data:e,loading:(0,R.bi)(i),networkStatus:i},t.complete?null:{partial:!0}))};return a&&n.getDocumentInfo(s).hasForcedResolvers?n.localState.runResolvers({document:s,remoteResult:{data:a},context:d,variables:o,onlyRunForcedResolvers:!0}).then(function(e){return l(e.data||void 0)}):"none"===u&&i===R.pT.refetch&&Array.isArray(t.missing)?l(void 0):l(a)},v="no-cache"===a?0:i===R.pT.refetch&&"merge"!==l?1:2,C=function(){return n.getResultsFromLink(e,v,{query:s,variables:o,context:d,fetchPolicy:a,errorPolicy:u})},y=p&&"number"==typeof g&&g!==i&&(0,R.bi)(i);switch(a){default:case"cache-first":return(w=f()).complete?{fromLink:!1,sources:[m(w,e.markReady())]}:h||y?{fromLink:!0,sources:[m(w),C()]}:{fromLink:!0,sources:[C()]};case"cache-and-network":var w;return(w=f()).complete||h||y?{fromLink:!0,sources:[m(w),C()]}:{fromLink:!0,sources:[C()]};case"cache-only":return{fromLink:!1,sources:[m(f(),e.markReady())]};case"network-only":return y?{fromLink:!0,sources:[m(f()),C()]}:{fromLink:!0,sources:[C()]};case"no-cache":return y?{fromLink:!0,sources:[m(e.getDiff()),C()]}:{fromLink:!0,sources:[C()]};case"standby":return{fromLink:!1,sources:[]}}},e.prototype.getOrCreateQuery=function(e){return e&&!this.queries.has(e)&&this.queries.set(e,new L(this,e)),this.queries.get(e)},e.prototype.prepareContext=function(e){void 0===e&&(e={});var t=this.localState.prepareContext(e);return(0,r.__assign)((0,r.__assign)((0,r.__assign)({},this.defaultContext),t),{clientAwareness:this.clientAwareness})},e}(),j=i(85517),K=i(96891),$=i(67566),q=function(){function e(e){var t=e.cache,i=e.client,r=e.resolvers,n=e.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=t,i&&(this.client=i),r&&this.addResolvers(r),n&&this.setFragmentMatcher(n)}return e.prototype.addResolvers=function(e){var t=this;this.resolvers=this.resolvers||{},Array.isArray(e)?e.forEach(function(e){t.resolvers=(0,_.D9)(t.resolvers,e)}):this.resolvers=(0,_.D9)(this.resolvers,e)},e.prototype.setResolvers=function(e){this.resolvers={},this.addResolvers(e)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(e){return(0,r.__awaiter)(this,arguments,void 0,function(e){var t=e.document,i=e.remoteResult,n=e.context,s=e.variables,o=e.onlyRunForcedResolvers,a=void 0!==o&&o;return(0,r.__generator)(this,function(e){return t?[2,this.resolveDocument(t,i.data,n,s,this.fragmentMatcher,a).then(function(e){return(0,r.__assign)((0,r.__assign)({},i),{data:e.result})})]:[2,i]})})},e.prototype.setFragmentMatcher=function(e){this.fragmentMatcher=e},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(e){return(0,h.d8)(["client"],e)&&this.resolvers?e:null},e.prototype.serverQuery=function(e){return(0,d.er)(e)},e.prototype.prepareContext=function(e){var t=this.cache;return(0,r.__assign)((0,r.__assign)({},e),{cache:t,getCacheKey:function(e){return t.identify(e)}})},e.prototype.addExportedVariables=function(e){return(0,r.__awaiter)(this,arguments,void 0,function(e,t,i){return void 0===t&&(t={}),void 0===i&&(i={}),(0,r.__generator)(this,function(n){return e?[2,this.resolveDocument(e,this.buildRootValueFromCache(e,t)||{},this.prepareContext(i),t).then(function(e){return(0,r.__assign)((0,r.__assign)({},t),e.exportedVariables)})]:[2,(0,r.__assign)({},t)]})})},e.prototype.shouldForceResolvers=function(e){var t=!1;return(0,j.YR)(e,{Directive:{enter:function(e){if("client"===e.name.value&&e.arguments&&(t=e.arguments.some(function(e){return"always"===e.name.value&&"BooleanValue"===e.value.kind&&!0===e.value.value})))return j.sP}}}),t},e.prototype.buildRootValueFromCache=function(e,t){return this.cache.diff({query:(0,d.zc)(e),variables:t,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(e,t){return(0,r.__awaiter)(this,arguments,void 0,function(e,t,i,n,s,o){var a,l,c,u,h,d,g,f,m,v;return void 0===i&&(i={}),void 0===n&&(n={}),void 0===s&&(s=function(){return!0}),void 0===o&&(o=!1),(0,r.__generator)(this,function(C){return a=(0,y.Vn)(e),l=(0,y.zK)(e),c=(0,p.JG)(l),u=this.collectSelectionsToResolve(a,c),h=a.operation,d=h?h.charAt(0).toUpperCase()+h.slice(1):"Query",f=(g=this).cache,m=g.client,v={fragmentMap:c,context:(0,r.__assign)((0,r.__assign)({},i),{cache:f,client:m}),variables:n,fragmentMatcher:s,defaultOperationType:d,exportedVariables:{},selectionsToResolve:u,onlyRunForcedResolvers:o},[2,this.resolveSelectionSet(a.selectionSet,!1,t,v).then(function(e){return{result:e,exportedVariables:v.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(e,t,i,s){return(0,r.__awaiter)(this,void 0,void 0,function(){var o,a,l,c,u,d=this;return(0,r.__generator)(this,function(p){return o=s.fragmentMap,a=s.context,l=s.variables,c=[i],u=function(e){return(0,r.__awaiter)(d,void 0,void 0,function(){var u,d;return(0,r.__generator)(this,function(r){return(t||s.selectionsToResolve.has(e))&&(0,h.MS)(e,l)?(0,w.dt)(e)?[2,this.resolveField(e,t,i,s).then(function(t){var i;void 0!==t&&c.push(((i={})[(0,w.ue)(e)]=t,i))})]:((0,w.kd)(e)?u=e:(u=o[e.name.value],(0,n.V1)(u,21,e.name.value)),u&&u.typeCondition&&(d=u.typeCondition.name.value,s.fragmentMatcher(i,d,a))?[2,this.resolveSelectionSet(u.selectionSet,t,i,s).then(function(e){c.push(e)})]:[2]):[2]})})},[2,Promise.all(e.selections.map(u)).then(function(){return(0,_.IM)(c)})]})})},e.prototype.resolveField=function(e,t,i,n){return(0,r.__awaiter)(this,void 0,void 0,function(){var s,o,a,l,c,u,h,d,p,g=this;return(0,r.__generator)(this,function(r){return i?(s=n.variables,o=e.name.value,a=(0,w.ue)(e),l=o!==a,c=i[a]||i[o],u=Promise.resolve(c),n.onlyRunForcedResolvers&&!this.shouldForceResolvers(e)||(h=i.__typename||n.defaultOperationType,(d=this.resolvers&&this.resolvers[h])&&(p=d[l?o:a])&&(u=Promise.resolve($.bl.withValue(this.cache,p,[i,(0,w.MB)(e,s),n.context,{field:e,fragmentMap:n.fragmentMap}])))),[2,u.then(function(i){var r,s;if(void 0===i&&(i=c),e.directives&&e.directives.forEach(function(e){"export"===e.name.value&&e.arguments&&e.arguments.forEach(function(e){"as"===e.name.value&&"StringValue"===e.value.kind&&(n.exportedVariables[e.value.value]=i)})}),!e.selectionSet)return i;if(null==i)return i;var o=null!==(s=null===(r=e.directives)||void 0===r?void 0:r.some(function(e){return"client"===e.name.value}))&&void 0!==s&&s;return Array.isArray(i)?g.resolveSubSelectedArray(e,t||o,i,n):e.selectionSet?g.resolveSelectionSet(e.selectionSet,t||o,i,n):void 0})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(e,t,i,r){var n=this;return Promise.all(i.map(function(i){return null===i?null:Array.isArray(i)?n.resolveSubSelectedArray(e,t,i,r):e.selectionSet?n.resolveSelectionSet(e.selectionSet,t,i,r):void 0}))},e.prototype.collectSelectionsToResolve=function(e,t){var i=function(e){return!Array.isArray(e)},r=this.selectionsToResolveCache;return function e(s){if(!r.has(s)){var o=new Set;r.set(s,o),(0,j.YR)(s,{Directive:function(e,t,r,n,s){"client"===e.name.value&&s.forEach(function(e){i(e)&&(0,K.VK)(e)&&o.add(e)})},FragmentSpread:function(r,s,a,l,c){var u=t[r.name.value];(0,n.V1)(u,22,r.name.value);var h=e(u);h.size>0&&(c.forEach(function(e){i(e)&&(0,K.VK)(e)&&o.add(e)}),o.add(r),h.forEach(function(e){o.add(e)}))}})}return r.get(s)}(e)},e}(),Y=i(97460),Q=i(27231),X=!1,Z=function(){function e(e){var t,i,o,c=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!e.cache)throw(0,n.vA)(16);var u=e.uri,h=e.credentials,d=e.headers,p=e.cache,g=e.documentTransform,f=e.ssrMode,m=void 0!==f&&f,v=e.ssrForceFetchDelay,C=void 0===v?0:v,y=e.connectToDevTools,w=e.queryDeduplication,S=void 0===w||w,b=e.defaultOptions,E=e.defaultContext,A=e.assumeImmutableResults,T=void 0===A?p.assumeImmutableResults:A,M=e.resolvers,R=e.typeDefs,_=e.fragmentMatcher,P=e.clientAwareness,D=e.name,I=e.version,L=e.devtools,N=e.dataMasking;!1!==globalThis.__DEV__&&((0,x.cc)(e,"connectToDevTools","ApolloClient","Please use `devtools.enabled` instead."),(0,x.cc)(e,"uri","ApolloClient","Please initialize an instance of `HttpLink` with `uri` instead."),(0,x.cc)(e,"credentials","ApolloClient","Please initialize an instance of `HttpLink` with `credentials` instead."),(0,x.cc)(e,"headers","ApolloClient","Please initialize an instance of `HttpLink` with `headers` instead."),(0,x.cc)(e,"name","ApolloClient","Please use the `clientAwareness.name` option instead."),(0,x.cc)(e,"version","ApolloClient","Please use the `clientAwareness.version` option instead."),(0,x.cc)(e,"typeDefs","ApolloClient"),e.link||!1!==globalThis.__DEV__&&n.V1.warn(17));var O=e.link;O||(O=u?new l.P({uri:u,credentials:h,headers:d}):s.C.empty()),this.link=O,this.cache=p,this.disableNetworkFetches=m||C>0,this.queryDeduplication=S,this.defaultOptions=b||Object.create(null),this.typeDefs=R,this.devtoolsConfig=(0,r.__assign)((0,r.__assign)({},L),{enabled:null!==(t=null==L?void 0:L.enabled)&&void 0!==t?t:y}),void 0===this.devtoolsConfig.enabled&&(this.devtoolsConfig.enabled=!1!==globalThis.__DEV__),C&&setTimeout(function(){return c.disableNetworkFetches=!1},C),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.watchFragment=this.watchFragment.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version=a.r,this.localState=new q({cache:p,client:this,resolvers:M,fragmentMatcher:_}),this.queryManager=new W({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,defaultContext:E,documentTransform:g,queryDeduplication:S,ssrMode:m,dataMasking:!!N,clientAwareness:{name:null!==(i=null==P?void 0:P.name)&&void 0!==i?i:D,version:null!==(o=null==P?void 0:P.version)&&void 0!==o?o:I},localState:this.localState,assumeImmutableResults:T,onBroadcast:this.devtoolsConfig.enabled?function(){c.devToolsHookCb&&c.devToolsHookCb({action:{},state:{queries:c.queryManager.getQueryStore(),mutations:c.queryManager.mutationStore||{}},dataWithOptimisticResults:c.cache.extract(!0)})}:void 0}),this.devtoolsConfig.enabled&&this.connectToDevTools()}return Object.defineProperty(e.prototype,"prioritizeCacheValues",{get:function(){return this.disableNetworkFetches},set:function(e){this.disableNetworkFetches=e},enumerable:!1,configurable:!0}),e.prototype.connectToDevTools=function(){if("undefined"!=typeof window){var e=window,t=Symbol.for("apollo.devtools");(e[t]=e[t]||[]).push(this),e.__APOLLO_CLIENT__=this,X||!1===globalThis.__DEV__||(X=!0,window.document&&window.top===window.self&&/^(https?|file):$/.test(window.location.protocol)&&setTimeout(function(){if(!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var e=window.navigator,t=e&&e.userAgent,i=void 0;"string"==typeof t&&(t.indexOf("Chrome/")>-1?i="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":t.indexOf("Firefox/")>-1&&(i="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),i&&!1!==globalThis.__DEV__&&n.V1.log("Download the Apollo DevTools for a better development experience: %s",i)}},1e4))}},Object.defineProperty(e.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform},enumerable:!1,configurable:!0}),e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(e){return this.defaultOptions.watchQuery&&(e=(0,Y.l)(this.defaultOptions.watchQuery,e)),!this.disableNetworkFetches||"network-only"!==e.fetchPolicy&&"cache-and-network"!==e.fetchPolicy||(e=(0,r.__assign)((0,r.__assign)({},e),{fetchPolicy:"cache-first"})),!1!==globalThis.__DEV__&&((0,x.cc)(e,"canonizeResults","client.watchQuery"),(0,x.cc)(e,"partialRefetch","client.watchQuery")),this.queryManager.watchQuery(e)},e.prototype.query=function(e){return this.defaultOptions.query&&(e=(0,Y.l)(this.defaultOptions.query,e)),(0,n.V1)("cache-and-network"!==e.fetchPolicy,18),this.disableNetworkFetches&&"network-only"===e.fetchPolicy&&(e=(0,r.__assign)((0,r.__assign)({},e),{fetchPolicy:"cache-first"})),!1!==globalThis.__DEV__&&((0,x.cc)(e,"canonizeResults","client.query"),(0,x.cc)(e,"notifyOnNetworkStatusChange","client.query","This option does not affect `client.query` and can be safely removed."),"standby"===e.fetchPolicy&&!1!==globalThis.__DEV__&&n.V1.warn(19)),this.queryManager.query(e)},e.prototype.mutate=function(e){return this.defaultOptions.mutate&&(e=(0,Y.l)(this.defaultOptions.mutate,e)),this.queryManager.mutate(e)},e.prototype.subscribe=function(e){var t=this,i=this.queryManager.generateQueryId();return this.queryManager.startGraphQLSubscription(e).map(function(n){return(0,r.__assign)((0,r.__assign)({},n),{data:t.queryManager.maskOperation({document:e.query,data:n.data,fetchPolicy:e.fetchPolicy,id:i})})})},e.prototype.readQuery=function(e,t){return void 0===t&&(t=!1),this.cache.readQuery(e,t)},e.prototype.watchFragment=function(e){var t;return this.cache.watchFragment((0,r.__assign)((0,r.__assign)({},e),((t={})[Symbol.for("apollo.dataMasking")]=this.queryManager.dataMasking,t)))},e.prototype.readFragment=function(e,t){return void 0===t&&(t=!1),this.cache.readFragment(e,t)},e.prototype.writeQuery=function(e){var t=this.cache.writeQuery(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.writeFragment=function(e){var t=this.cache.writeFragment(e);return!1!==e.broadcast&&this.queryManager.broadcastQueries(),t},e.prototype.__actionHookForDevTools=function(e){this.devToolsHookCb=e},e.prototype.__requestRaw=function(e){return(0,o.g)(this.link,e)},e.prototype.resetStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(e.resetStoreCallbacks.map(function(e){return e()}))}).then(function(){return e.reFetchObservableQueries()})},e.prototype.clearStore=function(){var e=this;return Promise.resolve().then(function(){return e.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(e.clearStoreCallbacks.map(function(e){return e()}))})},e.prototype.onResetStore=function(e){var t=this;return this.resetStoreCallbacks.push(e),function(){t.resetStoreCallbacks=t.resetStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.onClearStore=function(e){var t=this;return this.clearStoreCallbacks.push(e),function(){t.clearStoreCallbacks=t.clearStoreCallbacks.filter(function(t){return t!==e})}},e.prototype.reFetchObservableQueries=function(e){return this.queryManager.reFetchObservableQueries(e)},e.prototype.refetchQueries=function(e){var t=this.queryManager.refetchQueries(e),i=[],r=[];t.forEach(function(e,t){i.push(t),r.push(e)});var s=Promise.all(r);return s.queries=i,s.results=r,s.catch(function(e){!1!==globalThis.__DEV__&&n.V1.debug(20,e)}),s},e.prototype.getObservableQueries=function(e){return void 0===e&&(e="active"),this.queryManager.getObservableQueries(e)},e.prototype.extract=function(e){return this.cache.extract(e)},e.prototype.restore=function(e){return this.cache.restore(e)},e.prototype.addResolvers=function(e){this.localState.addResolvers(e)},e.prototype.setResolvers=function(e){this.localState.setResolvers(e)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(e){this.localState.setFragmentMatcher(e)},e.prototype.setLink=function(e){this.link=this.queryManager.link=e},Object.defineProperty(e.prototype,"defaultContext",{get:function(){return this.queryManager.defaultContext},enumerable:!1,configurable:!0}),e}();!1!==globalThis.__DEV__&&(Z.prototype.getMemoryInternals=Q.ep)},78440(e,t,i){"use strict";i.d(t,{U:()=>w,y:()=>b});var r=i(65959),n=i(131),s=i(45063),o=i(49995),a=i(74140),l=i(47812),c=i(90767),u=i(37563),h=i(20658),d=i(24783),p=i(58173),g=i(17303),f=i(47372),m=i(81987),v=i(30301),C=Object.assign,y=Object.hasOwnProperty,w=function(e){function t(i){var n=i.queryManager,s=i.queryInfo,o=i.options,a=this,c=t.inactiveOnCreation.getValue();(a=e.call(this,function(e){a._getOrCreateQuery();try{var t=e._subscription._observer;t&&!t.error&&(t.error=S)}catch(e){}var i=!a.observers.size;a.observers.add(e);var r=a.last;return r&&r.error?e.error&&e.error(r.error):r&&r.result&&e.next&&e.next(a.maskResult(r.result)),i&&a.reobserve().catch(function(){}),function(){a.observers.delete(e)&&!a.observers.size&&a.tearDownQuery()}})||this).observers=new Set,a.subscriptions=new Set,a.dirty=!1,a._getOrCreateQuery=function(){return c&&(n.queries.set(a.queryId,s),c=!1),a.queryManager.getOrCreateQuery(a.queryId)},a.queryInfo=s,a.queryManager=n,a.waitForOwnResult=E(o.fetchPolicy),a.isTornDown=!1,a.subscribeToMore=a.subscribeToMore.bind(a),a.maskResult=a.maskResult.bind(a);var u=n.defaultOptions.watchQuery,h=(void 0===u?{}:u).fetchPolicy,d=void 0===h?"cache-first":h,p=o.fetchPolicy,g=void 0===p?d:p,f=o.initialFetchPolicy,m=void 0===f?"standby"===g?d:g:f;a.options=(0,r.__assign)((0,r.__assign)({},o),{initialFetchPolicy:m,fetchPolicy:g}),a.queryId=s.queryId||n.generateQueryId();var v=(0,l.Vu)(a.query);return a.queryName=v&&v.name&&v.name.value,a}return(0,r.__extends)(t,e),Object.defineProperty(t.prototype,"query",{get:function(){return this.lastQuery||this.options.query},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),t.prototype.result=function(){var e=this;return!1!==globalThis.__DEV__&&(0,v.S2)("observableQuery.result",function(){!1!==globalThis.__DEV__&&n.V1.warn(23)}),new Promise(function(t,i){var r={next:function(i){t(i),e.observers.delete(r),e.observers.size||e.queryManager.removeQuery(e.queryId),setTimeout(function(){n.unsubscribe()},0)},error:i},n=e.subscribe(r)})},t.prototype.resetDiff=function(){this.queryInfo.resetDiff()},t.prototype.getCurrentFullResult=function(e){var t=this;void 0===e&&(e=!0);var i=(0,v.lz)("getLastResult",function(){return t.getLastResult(!0)}),n=this.queryInfo.networkStatus||i&&i.networkStatus||o.pT.ready,a=(0,r.__assign)((0,r.__assign)({},i),{loading:(0,o.bi)(n),networkStatus:n}),l=this.options.fetchPolicy,c=void 0===l?"cache-first":l;if(E(c)||this.queryManager.getDocumentInfo(this.query).hasForcedResolvers);else if(this.waitForOwnResult)this.queryInfo.updateWatch();else{var u=this.queryInfo.getDiff();(u.complete||this.options.returnPartialData)&&(a.data=u.result),(0,s.L)(a.data,{})&&(a.data=void 0),u.complete?(delete a.partial,!u.complete||a.networkStatus!==o.pT.loading||"cache-first"!==c&&"cache-only"!==c||(a.networkStatus=o.pT.ready,a.loading=!1)):a.partial=!0,a.networkStatus===o.pT.ready&&(a.error||a.errors)&&(a.networkStatus=o.pT.error),!1===globalThis.__DEV__||u.complete||this.options.partialRefetch||a.loading||a.data||a.error||b(u.missing)}return e&&this.updateLastResult(a),a},t.prototype.getCurrentResult=function(e){return void 0===e&&(e=!0),this.maskResult(this.getCurrentFullResult(e))},t.prototype.isDifferentFromLastResult=function(e,t){if(!this.last)return!0;var i=this.queryManager.getDocumentInfo(this.query),r=this.queryManager.dataMasking,n=r?i.nonReactiveQuery:this.query;return(r||i.hasNonreactiveDirective?!(0,f.a)(n,this.last.result,e,this.variables):!(0,s.L)(this.last.result,e))||t&&!(0,s.L)(this.last.variables,t)},t.prototype.getLast=function(e,t){var i=this.last;if(i&&i[e]&&(!t||(0,s.L)(i.variables,this.variables)))return i[e]},t.prototype.getLastResult=function(e){return!1!==globalThis.__DEV__&&(0,v.S2)("getLastResult",function(){!1!==globalThis.__DEV__&&n.V1.warn(24)}),this.getLast("result",e)},t.prototype.getLastError=function(e){return!1!==globalThis.__DEV__&&(0,v.S2)("getLastError",function(){!1!==globalThis.__DEV__&&n.V1.warn(25)}),this.getLast("error",e)},t.prototype.resetLastResults=function(){!1!==globalThis.__DEV__&&(0,v.S2)("resetLastResults",function(){!1!==globalThis.__DEV__&&n.V1.warn(26)}),delete this.last,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){!1!==globalThis.__DEV__&&!1!==globalThis.__DEV__&&n.V1.warn(27),this.queryManager.resetErrors(this.queryId)},t.prototype.refetch=function(e){var t,i={pollInterval:0},a=this.options.fetchPolicy;if(i.fetchPolicy="no-cache"===a?"no-cache":"network-only",!1!==globalThis.__DEV__&&e&&y.call(e,"variables")){var c=(0,l.AT)(this.query),u=c.variableDefinitions;u&&u.some(function(e){return"variables"===e.variable.name.value})||!1!==globalThis.__DEV__&&n.V1.warn(28,e,(null===(t=c.name)||void 0===t?void 0:t.value)||c)}return e&&!(0,s.L)(this.options.variables,e)&&(i.variables=this.options.variables=(0,r.__assign)((0,r.__assign)({},this.options.variables),e)),this.queryInfo.resetLastWrite(),this.reobserve(i,o.pT.refetch)},t.prototype.fetchMore=function(e){var t=this,i=(0,r.__assign)((0,r.__assign)({},e.query?e:(0,r.__assign)((0,r.__assign)((0,r.__assign)((0,r.__assign)({},this.options),{query:this.options.query}),e),{variables:(0,r.__assign)((0,r.__assign)({},this.options.variables),e.variables)})),{fetchPolicy:"no-cache"});i.query=this.transformDocument(i.query);var s=this.queryManager.generateQueryId();this.lastQuery=e.query?this.transformDocument(this.options.query):i.query;var a=this.queryInfo,l=a.networkStatus;a.networkStatus=o.pT.fetchMore,i.notifyOnNetworkStatusChange&&this.observe();var c=new Set,u=null==e?void 0:e.updateQuery,h="no-cache"!==this.options.fetchPolicy;return h||(0,n.V1)(u,29),this.queryManager.fetchQuery(s,i,o.pT.fetchMore).then(function(n){if(t.queryManager.removeQuery(s),a.networkStatus===o.pT.fetchMore&&(a.networkStatus=l),h)t.queryManager.cache.batch({update:function(r){var s=e.updateQuery;s?r.updateQuery({query:t.query,variables:t.variables,returnPartialData:!0,optimistic:!1},function(e){return s(e,{fetchMoreResult:n.data,variables:i.variables})}):r.writeQuery({query:i.query,variables:i.variables,data:n.data})},onWatchUpdated:function(e){c.add(e.query)}});else{var d=t.getLast("result"),p=u(d.data,{fetchMoreResult:n.data,variables:i.variables});t.reportResult((0,r.__assign)((0,r.__assign)({},d),{networkStatus:l,loading:(0,o.bi)(l),data:p}),t.variables)}return t.maskResult(n)}).finally(function(){h&&!c.has(t.query)&&t.reobserveCacheFirst()})},t.prototype.subscribeToMore=function(e){var t=this,i=this.queryManager.startGraphQLSubscription({query:e.document,variables:e.variables,context:e.context}).subscribe({next:function(i){var n=e.updateQuery;n&&t.updateQuery(function(e,t){return n(e,(0,r.__assign)({subscriptionData:i},t))})},error:function(t){e.onError?e.onError(t):!1!==globalThis.__DEV__&&n.V1.error(30,t)}});return this.subscriptions.add(i),function(){t.subscriptions.delete(i)&&i.unsubscribe()}},t.prototype.setOptions=function(e){return!1!==globalThis.__DEV__&&((0,v.cc)(e,"canonizeResults","setOptions"),(0,v.S2)("setOptions",function(){!1!==globalThis.__DEV__&&n.V1.warn(31)})),this.reobserve(e)},t.prototype.silentSetOptions=function(e){var t=(0,p.o)(this.options,e||{});C(this.options,t)},t.prototype.setVariables=function(e){var t=this;return(0,s.L)(this.variables,e)?this.observers.size?(0,v.lz)("observableQuery.result",function(){return t.result()}):Promise.resolve():(this.options.variables=e,this.observers.size?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:e},o.pT.setVariables):Promise.resolve())},t.prototype.updateQuery=function(e){var t=this.queryManager,i=t.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}),r=i.result,n=i.complete,s=e(r,{variables:this.variables,complete:!!n,previousData:r});s&&(t.cache.writeQuery({query:this.options.query,data:s,variables:this.variables}),t.broadcastQueries())},t.prototype.startPolling=function(e){this.options.pollInterval=e,this.updatePolling()},t.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},t.prototype.applyNextFetchPolicy=function(e,t){if(t.nextFetchPolicy){var i=t.fetchPolicy,r=void 0===i?"cache-first":i,n=t.initialFetchPolicy,s=void 0===n?r:n;"standby"===r||("function"==typeof t.nextFetchPolicy?t.fetchPolicy=t.nextFetchPolicy(r,{reason:e,options:t,observable:this,initialFetchPolicy:s}):t.fetchPolicy="variables-changed"===e?s:t.nextFetchPolicy)}return t.fetchPolicy},t.prototype.fetch=function(e,t,i){var r=this._getOrCreateQuery();return r.setObservableQuery(this),this.queryManager.fetchConcastWithInfo(r,e,t,i)},t.prototype.updatePolling=function(){var e=this;if(!this.queryManager.ssrMode){var t=this.pollingInfo,i=this.options.pollInterval;if(i&&this.hasObservers()){if(!t||t.interval!==i){(0,n.V1)(i,32),(t||(this.pollingInfo={})).interval=i;var r=function(){var t,i;e.pollingInfo&&((0,o.bi)(e.queryInfo.networkStatus)||(null===(i=(t=e.options).skipPollAttempt)||void 0===i?void 0:i.call(t))?s():e.reobserve({fetchPolicy:"no-cache"===e.options.initialFetchPolicy?"no-cache":"network-only"},o.pT.poll).then(s,s))},s=function(){var t=e.pollingInfo;t&&(clearTimeout(t.timeout),t.timeout=setTimeout(r,t.interval))};s()}}else t&&(clearTimeout(t.timeout),delete this.pollingInfo)}},t.prototype.updateLastResult=function(e,t){var i=this;void 0===t&&(t=this.variables);var n=(0,v.lz)("getLastError",function(){return i.getLastError()});return n&&this.last&&!(0,s.L)(t,this.last.variables)&&(n=void 0),this.last=(0,r.__assign)({result:this.queryManager.assumeImmutableResults?e:(0,u.m)(e),variables:t},n?{error:n}:null)},t.prototype.reobserveAsConcast=function(e,t){var i=this;this.isTornDown=!1;var n=t===o.pT.refetch||t===o.pT.fetchMore||t===o.pT.poll,a=this.options.variables,l=this.options.fetchPolicy,c=(0,p.o)(this.options,e||{}),u=n?c:C(this.options,c),h=this.transformDocument(u.query);this.lastQuery=h,n||(this.updatePolling(),!e||!e.variables||(0,s.L)(e.variables,a)||"standby"===u.fetchPolicy||u.fetchPolicy!==l&&"function"!=typeof u.nextFetchPolicy||(this.applyNextFetchPolicy("variables-changed",u),void 0===t&&(t=o.pT.setVariables))),this.waitForOwnResult&&(this.waitForOwnResult=E(u.fetchPolicy));var d=function(){i.concast===v&&(i.waitForOwnResult=!1)},f=u.variables&&(0,r.__assign)({},u.variables),m=this.fetch(u,t,h),v=m.concast,y=m.fromLink,w={next:function(e){(0,s.L)(i.variables,f)&&(d(),i.reportResult(e,f))},error:function(e){(0,s.L)(i.variables,f)&&((0,g.Mn)(e)||(e=new g.K4({networkError:e})),d(),i.reportError(e,f))}};return n||!y&&this.concast||(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=v,this.observer=w),v.addObserver(w),v},t.prototype.reobserve=function(e,t){return(0,c.X)(this.reobserveAsConcast(e,t).promise.then(this.maskResult))},t.prototype.resubscribeAfterError=function(){for(var e=this,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var r=this.last;(0,v.lz)("resetLastResults",function(){return e.resetLastResults()});var n=this.subscribe.apply(this,t);return this.last=r,n},t.prototype.observe=function(){this.reportResult(this.getCurrentFullResult(!1),this.variables)},t.prototype.reportResult=function(e,t){var i=this,r=(0,v.lz)("getLastError",function(){return i.getLastError()}),n=this.isDifferentFromLastResult(e,t);(r||!e.partial||this.options.returnPartialData)&&this.updateLastResult(e,t),(r||n)&&(0,h.w)(this.observers,"next",this.maskResult(e))},t.prototype.reportError=function(e,t){var i=this,n=(0,r.__assign)((0,r.__assign)({},(0,v.lz)("getLastResult",function(){return i.getLastResult()})),{error:e,errors:e.graphQLErrors,networkStatus:o.pT.error,loading:!1});this.updateLastResult(n,t),(0,h.w)(this.observers,"error",this.last.error=e)},t.prototype.hasObservers=function(){return this.observers.size>0},t.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(e){return e.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},t.prototype.transformDocument=function(e){return this.queryManager.transform(e)},t.prototype.maskResult=function(e){return e&&"data"in e?(0,r.__assign)((0,r.__assign)({},e),{data:this.queryManager.maskOperation({document:this.query,data:e.data,fetchPolicy:this.options.fetchPolicy,id:this.queryId})}):e},t.prototype.resetNotifications=function(){this.cancelNotifyTimeout(),this.dirty=!1},t.prototype.cancelNotifyTimeout=function(){this.notifyTimeout&&(clearTimeout(this.notifyTimeout),this.notifyTimeout=void 0)},t.prototype.scheduleNotify=function(){var e=this;this.dirty||(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return e.notify()},0)))},t.prototype.notify=function(){this.cancelNotifyTimeout(),this.dirty&&("cache-only"!=this.options.fetchPolicy&&"cache-and-network"!=this.options.fetchPolicy&&(0,o.bi)(this.queryInfo.networkStatus)||(this.queryInfo.getDiff().fromOptimisticTransaction?this.observe():this.reobserveCacheFirst())),this.dirty=!1},t.prototype.reobserveCacheFirst=function(){var e=this.options,t=e.fetchPolicy,i=e.nextFetchPolicy;return"cache-and-network"===t||"network-only"===t?this.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(e,r){return this.nextFetchPolicy=i,"function"==typeof this.nextFetchPolicy?this.nextFetchPolicy(e,r):t}}):this.reobserve()},t.inactiveOnCreation=new m.DX,t}(a.c);function S(e){!1!==globalThis.__DEV__&&n.V1.error(33,e.message,e.stack)}function b(e){!1!==globalThis.__DEV__&&e&&!1!==globalThis.__DEV__&&n.V1.debug(34,e)}function E(e){return"network-only"===e||"no-cache"===e||"standby"===e}(0,d.r)(w)},47372(e,t,i){"use strict";i.d(t,{a:()=>c});var r=i(65959),n=i(45063),s=i(14270),o=i(48555),a=i(47812),l=i(99310);function c(e,t,i,s){var l=t.data,c=(0,r.__rest)(t,["data"]),h=i.data,d=(0,r.__rest)(i,["data"]);return(0,n.A)(c,d)&&u((0,a.Vn)(e).selectionSet,l,h,{fragmentMap:(0,o.JG)((0,a.zK)(e)),variables:s})}function u(e,t,i,r){if(t===i)return!0;var a=new Set;return e.selections.every(function(e){if(a.has(e))return!0;if(a.add(e),!(0,s.MS)(e,r.variables))return!0;if(h(e))return!0;if((0,l.dt)(e)){var c=(0,l.ue)(e),d=t&&t[c],p=i&&i[c],g=e.selectionSet;if(!g)return(0,n.A)(d,p);var f=Array.isArray(d),m=Array.isArray(p);if(f!==m)return!1;if(f&&m){var v=d.length;if(p.length!==v)return!1;for(var C=0;C<v;++C)if(!u(g,d[C],p[C],r))return!1;return!0}return u(g,d,p,r)}var y=(0,o.HQ)(e,r.fragmentMap);return y?!!h(y)||u(y.selectionSet,t,i,r):void 0})}function h(e){return!!e.directives&&e.directives.some(d)}function d(e){return"nonreactive"===e.name.value}},16266(e,t,i){"use strict";i.r(t),i.d(t,{ApolloCache:()=>c.k,ApolloClient:()=>n.R,ApolloError:()=>l.K4,ApolloLink:()=>f.C,Cache:()=>r,DocumentTransform:()=>R.c,HttpLink:()=>S.HttpLink,InMemoryCache:()=>u.D,MissingFieldError:()=>h.Z,NetworkStatus:()=>a.pT,Observable:()=>E.c,ObservableQuery:()=>o.U,checkFetcher:()=>S.checkFetcher,concat:()=>y,createHttpLink:()=>S.createHttpLink,createSignalIfSupported:()=>S.createSignalIfSupported,defaultDataIdFromObject:()=>d.or,defaultPrinter:()=>S.defaultPrinter,disableExperimentalFragmentVariables:()=>x.qj,disableFragmentWarnings:()=>x.gi,empty:()=>m,enableExperimentalFragmentVariables:()=>x.VC,execute:()=>w.g,fallbackHttpConfig:()=>S.fallbackHttpConfig,from:()=>v,fromError:()=>T.N,fromPromise:()=>A,gql:()=>x.J1,isApolloError:()=>l.Mn,isNetworkRequestSettled:()=>a.D2,isReference:()=>_.A_,makeReference:()=>_.WU,makeVar:()=>p.UT,mergeOptions:()=>s.l,parseAndCheckHttpResponse:()=>S.parseAndCheckHttpResponse,resetCaches:()=>x.Nh,rewriteURIForGET:()=>S.rewriteURIForGET,selectHttpOptionsAndBody:()=>S.selectHttpOptionsAndBody,selectHttpOptionsAndBodyInternal:()=>S.selectHttpOptionsAndBodyInternal,selectURI:()=>S.selectURI,serializeFetchParameter:()=>S.serializeFetchParameter,setLogVerbosity:()=>P.Q9,split:()=>C,throwServerError:()=>M.A,toPromise:()=>b});var r,n=i(50953),s=i(97460),o=i(78440),a=i(49995),l=i(17303);r||(r={});var c=i(30622),u=i(70415),h=i(1574),d=i(47422),p=i(67566),g=i(131),f=i(3224),m=f.C.empty,v=f.C.from,C=f.C.split,y=f.C.concat,w=i(34109),S=i(42007);function b(e){var t=!1;return new Promise(function(i,r){e.subscribe({next:function(e){t?!1!==globalThis.__DEV__&&g.V1.warn(57):(t=!0,i(e))},error:r})})}var E=i(74140);function A(e){return new E.c(function(t){e.then(function(e){t.next(e),t.complete()}).catch(t.error.bind(t))})}var T=i(47752),M=i(49703),R=i(78917),_=i(99310),P=i(92981),x=i(27477);(0,P.Q9)(!1!==globalThis.__DEV__?"log":"silent")},49995(e,t,i){"use strict";var r;function n(e){return!!e&&e<7}function s(e){return 7===e||8===e}i.d(t,{D2:()=>s,bi:()=>n,pT:()=>r}),function(e){e[e.loading=1]="loading",e[e.setVariables=2]="setVariables",e[e.fetchMore=3]="fetchMore",e[e.refetch=4]="refetch",e[e.poll=6]="poll",e[e.ready=7]="ready",e[e.error=8]="error"}(r||(r={}))},17303(e,t,i){"use strict";i.d(t,{K$:()=>s,K4:()=>l,Mn:()=>a,uR:()=>o});var r=i(65959),n=(i(131),i(1164)),s=Symbol();function o(e){return!!e.extensions&&Array.isArray(e.extensions[s])}function a(e){return e.hasOwnProperty("graphQLErrors")}var l=function(e){function t(i){var s,o,a=i.graphQLErrors,l=i.protocolErrors,c=i.clientErrors,u=i.networkError,h=i.errorMessage,d=i.extraInfo,p=e.call(this,h)||this;return p.name="ApolloError",p.graphQLErrors=a||[],p.protocolErrors=l||[],p.clientErrors=c||[],p.networkError=u||null,p.message=h||(s=p,o=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([],s.graphQLErrors,!0),s.clientErrors,!0),s.protocolErrors,!0),s.networkError&&o.push(s.networkError),o.map(function(e){return(0,n.U)(e)&&e.message||"Error message not found."}).join("\n")),p.extraInfo=d,p.cause=(0,r.__spreadArray)((0,r.__spreadArray)((0,r.__spreadArray)([u],a||[],!0),l||[],!0),c||[],!0).find(function(e){return!!e})||null,p.__proto__=t.prototype,p}return(0,r.__extends)(t,e),t}(Error)},36712(e,t,i){"use strict";i.r(t),i.d(t,{setContext:()=>o});var r=i(65959),n=i(3224),s=i(74140);function o(e){return new n.C(function(t,i){var n=(0,r.__rest)(t,[]);return new s.c(function(r){var s,o=!1;return Promise.resolve(n).then(function(i){return e(i,t.getContext())}).then(t.setContext).then(function(){o||(s=i(t).subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)}))}).catch(r.error.bind(r)),function(){o=!0,s&&s.unsubscribe()}})})}},3224(e,t,i){"use strict";i.d(t,{C:()=>h});var r=i(131),n=i(74140),s=i(65959),o=i(47812),a=i(30301);function l(e,t){return t?t(e):n.c.of()}function c(e){return"function"==typeof e?new h(e):e}function u(e){return e.request.length<=1}var h=function(){function e(e){e&&(this.request=e)}return e.empty=function(){return new e(function(){return n.c.of()})},e.from=function(t){return 0===t.length?e.empty():t.map(c).reduce(function(e,t){return e.concat(t)})},e.split=function(t,i,r){var s,o=c(i),a=c(r||new e(l));return s=u(o)&&u(a)?new e(function(e){return t(e)?o.request(e)||n.c.of():a.request(e)||n.c.of()}):new e(function(e,i){return t(e)?o.request(e,i)||n.c.of():a.request(e,i)||n.c.of()}),Object.assign(s,{left:o,right:a})},e.execute=function(e,t){return e.request(function(e,t){var i=(0,s.__assign)({},e);return Object.defineProperty(t,"setContext",{enumerable:!1,value:function(e){i="function"==typeof e?(0,s.__assign)((0,s.__assign)({},i),e(i)):(0,s.__assign)((0,s.__assign)({},i),e)}}),Object.defineProperty(t,"getContext",{enumerable:!1,value:function(){return(0,s.__assign)({},i)}}),t}(t.context,function(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName="string"!=typeof t.query?(0,o.n4)(t.query)||void 0:""),t}(function(e){for(var t=["query","operationName","variables","extensions","context"],i=0,n=Object.keys(e);i<n.length;i++){var s=n[i];if(t.indexOf(s)<0)throw(0,r.vA)(58,s)}return e}(t))))||n.c.of()},e.concat=function(t,i){var s=c(t);if(u(s))return!1!==globalThis.__DEV__&&r.V1.warn(47,s),s;var o,a=c(i);return o=u(a)?new e(function(e){return s.request(e,function(e){return a.request(e)||n.c.of()})||n.c.of()}):new e(function(e,t){return s.request(e,function(e){return a.request(e,t)||n.c.of()})||n.c.of()}),Object.assign(o,{left:s,right:a})},e.prototype.split=function(t,i,r){return this.concat(e.split(t,i,r||new e(l)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(e,t){throw(0,r.vA)(48)},e.prototype.onError=function(e,t){if(!1!==globalThis.__DEV__&&(0,a.S2)("onError",function(){!1!==globalThis.__DEV__&&r.V1.warn(49)}),t&&t.error)return t.error(e),!1;throw e},e.prototype.setOnError=function(e){return!1!==globalThis.__DEV__&&!1!==globalThis.__DEV__&&r.V1.warn(50),this.onError=e,this},e}()},34109(e,t,i){"use strict";i.d(t,{g:()=>r});var r=i(3224).C.execute},81381(e,t,i){"use strict";i.d(t,{S:()=>a});var r=i(65959),n=i(17303),s=i(74140),o=i(3224);function a(e){return new o.C(function(t,i){return new s.c(function(r){var s,o,a;try{s=i(t).subscribe({next:function(s){s.errors?a=e({graphQLErrors:s.errors,response:s,operation:t,forward:i}):(0,n.uR)(s)&&(a=e({protocolErrors:s.extensions[n.K$],response:s,operation:t,forward:i})),a?o=a.subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)}):r.next(s)},error:function(n){(a=e({operation:t,networkError:n,graphQLErrors:n&&n.result&&n.result.errors||void 0,forward:i}))?o=a.subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)}):r.error(n)},complete:function(){a||r.complete.bind(r)()}})}catch(n){e({networkError:n,operation:t,forward:i}),r.error(n)}return function(){s&&s.unsubscribe(),o&&s.unsubscribe()}})})}!function(e){function t(t){var i=e.call(this)||this;return i.link=a(t),i}(0,r.__extends)(t,e),t.prototype.request=function(e,t){return this.link.request(e,t)}}(o.C)},39781(e,t,i){"use strict";i.d(t,{P:()=>o});var r=i(65959),n=i(3224),s=i(48674),o=function(e){function t(t){void 0===t&&(t={});var i=e.call(this,(0,s.$)(t).request)||this;return i.options=t,i}return(0,r.__extends)(t,e),t}(n.C)},75938(e,t,i){"use strict";i.d(t,{S:()=>n});var r=i(131),n=function(e){if(!e&&"undefined"==typeof fetch)throw(0,r.vA)(51)}},48674(e,t,i){"use strict";i.d(t,{$:()=>y});var r=i(65959),n=i(131),s=i(3224),o=i(14270),a=i(74140),l=i(87708),c=i(61555),u=i(80243),h=i(75938),d=i(55662),p=i(76662),g=i(47752),f=i(85517),m=i(83906),v=i(47812),C=(0,n.no)(function(){return fetch}),y=function(e){void 0===e&&(e={});var t=e.uri,i=void 0===t?"/graphql":t,y=e.fetch,w=e.print,S=void 0===w?d.i1:w,b=e.includeExtensions,E=e.preserveHeaderCase,A=e.useGETForQueries,T=e.includeUnusedVariables,M=void 0!==T&&T,R=(0,r.__rest)(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);!1!==globalThis.__DEV__&&(0,h.S)(y||C);var _={http:{includeExtensions:b,preserveHeaderCase:E},options:R.fetchOptions,credentials:R.credentials,headers:R.headers};return new s.C(function(e){var t=(0,c.z)(e,i),s=e.getContext(),h={};if(s.clientAwareness){var w=s.clientAwareness,b=w.name,E=w.version;b&&(h["apollographql-client-name"]=b),E&&(h["apollographql-client-version"]=E)}var T=(0,r.__assign)((0,r.__assign)({},h),s.headers),R={http:s.http,options:s.fetchOptions,credentials:s.credentials,headers:T};if((0,o.d8)(["client"],e.query)){!1!==globalThis.__DEV__&&!1!==globalThis.__DEV__&&n.V1.warn(52);var P=(0,m.er)(e.query);if(!P)return(0,g.N)(new Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));e.query=P}var x,D,I,L,N,O=(0,d.HY)(e,S,d.R4,_,R),F=O.options,k=O.body;k.variables&&!M&&(k.variables=(x=k.variables,D=e.query,I=(0,r.__assign)({},x),L=new Set(Object.keys(x)),(0,f.YR)(D,{Variable:function(e,t,i){i&&"VariableDefinition"!==i.kind&&L.delete(e.name.value)}}),L.forEach(function(e){delete I[e]}),I)),F.signal||"undefined"==typeof AbortController||(N=new AbortController,F.signal=N.signal);var G,V="OperationDefinition"===(G=(0,v.Vn)(e.query)).kind&&"subscription"===G.operation,H=(0,o.d8)(["defer"],e.query);if(A&&!e.query.definitions.some(function(e){return"OperationDefinition"===e.kind&&"mutation"===e.operation})&&(F.method="GET"),H||V){F.headers=F.headers||{};var B="multipart/mixed;";V&&H&&!1!==globalThis.__DEV__&&n.V1.warn(53),V?B+="boundary=graphql;subscriptionSpec=1.0,application/json":H&&(B+="deferSpec=20220824,application/json"),F.headers.accept=B}if("GET"===F.method){var z=(0,p.E)(t,k),U=z.newURI,W=z.parseError;if(W)return(0,g.N)(W);t=U}else try{F.body=(0,l.Y)(k,"Payload")}catch(W){return(0,g.N)(W)}return new a.c(function(i){var r=y||(0,n.no)(function(){return fetch})||C,s=i.next.bind(i);return r(t,F).then(function(t){var i;e.setContext({response:t});var r=null===(i=t.headers)||void 0===i?void 0:i.get("content-type");return null!==r&&/^multipart\/mixed/i.test(r)?(0,u.tD)(t,s):(0,u.OQ)(e)(t).then(s)}).then(function(){N=void 0,i.complete()}).catch(function(e){N=void 0,(0,u.H4)(e,i)}),function(){N&&N.abort()}})})}},42007(e,t,i){"use strict";i.r(t),i.d(t,{HttpLink:()=>u.P,checkFetcher:()=>o.S,createHttpLink:()=>c.$,createSignalIfSupported:()=>a,defaultPrinter:()=>s.i1,fallbackHttpConfig:()=>s.R4,parseAndCheckHttpResponse:()=>r.OQ,rewriteURIForGET:()=>h.E,selectHttpOptionsAndBody:()=>s.Wz,selectHttpOptionsAndBodyInternal:()=>s.HY,selectURI:()=>l.z,serializeFetchParameter:()=>n.Y}),i(131);var r=i(80243),n=i(87708),s=i(55662),o=i(75938),a=function(){if("undefined"==typeof AbortController)return{controller:!1,signal:!1};var e=new AbortController;return{controller:e,signal:e.signal}},l=i(61555),c=i(48674),u=i(39781),h=i(76662)},80243(e,t,i){"use strict";i.d(t,{H4:()=>g,OQ:()=>f,tD:()=>h});var r=i(65959),n=i(97703);function s(e){var t={next:function(){return e.read()}};return n.uJ&&(t[Symbol.asyncIterator]=function(){return this}),t}function o(e){var t,i,r,o=e;if(e.body&&(o=e.body),r=o,n.uJ&&r[Symbol.asyncIterator])return i=o[Symbol.asyncIterator](),(t={next:function(){return i.next()}})[Symbol.asyncIterator]=function(){return this},t;if(function(e){return!!e.getReader}(o))return s(o.getReader());if(function(e){return!!e.stream}(o))return s(o.stream().getReader());if(function(e){return!!e.arrayBuffer}(o))return function(e){var t=!1,i={next:function(){return t?Promise.resolve({value:void 0,done:!0}):(t=!0,new Promise(function(t,i){e.then(function(e){t({value:e,done:!1})}).catch(i)}))}};return n.uJ&&(i[Symbol.asyncIterator]=function(){return this}),i}(o.arrayBuffer());if(function(e){return!!e.pipe}(o))return function(e){var t=null,i=null,r=!1,s=[],o=[];function a(e){if(!i){if(o.length){var t=o.shift();if(Array.isArray(t)&&t[0])return t[0]({value:e,done:!1})}s.push(e)}}function l(e){i=e,o.slice().forEach(function(t){t[1](e)}),!t||t()}function c(){r=!0,o.slice().forEach(function(e){e[0]({value:void 0,done:!0})}),!t||t()}t=function(){t=null,e.removeListener("data",a),e.removeListener("error",l),e.removeListener("end",c),e.removeListener("finish",c),e.removeListener("close",c)},e.on("data",a),e.on("error",l),e.on("end",c),e.on("finish",c),e.on("close",c);var u={next:function(){return new Promise(function(e,t){return i?t(i):s.length?e({value:s.shift(),done:!1}):r?e({value:void 0,done:!0}):void o.push([e,t])})}};return n.uJ&&(u[Symbol.asyncIterator]=function(){return this}),u}(o);throw new Error("Unknown body type for responseIterator. Please pass a streamable response.")}var a=i(49703),l=i(17303),c=i(94537),u=Object.prototype.hasOwnProperty;function h(e,t){return(0,r.__awaiter)(this,void 0,void 0,function(){var i,n,s,a,u,h,g,f,m,v,C,y,w,S,b,E,A,T,M,R,_,P,x,D;return(0,r.__generator)(this,function(I){switch(I.label){case 0:if(void 0===TextDecoder)throw new Error("TextDecoder must be defined in the environment: please import a polyfill.");i=new TextDecoder("utf-8"),n=null===(D=e.headers)||void 0===D?void 0:D.get("content-type"),s="boundary=",a=(null==n?void 0:n.includes(s))?null==n?void 0:n.substring((null==n?void 0:n.indexOf(s))+9).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",u="\r\n--".concat(a),h="",g=o(e),f=!0,I.label=1;case 1:return f?[4,g.next()]:[3,3];case 2:for(m=I.sent(),v=m.value,C=m.done,y="string"==typeof v?v:i.decode(v),w=h.length-u.length+1,f=!C,S=(h+=y).indexOf(u,w);S>-1;){if(b=void 0,P=[h.slice(0,S),h.slice(S+u.length)],h=P[1],E=(b=P[0]).indexOf("\r\n\r\n"),A=d(b.slice(0,E)),(T=A["content-type"])&&-1===T.toLowerCase().indexOf("application/json"))throw new Error("Unsupported patch content type: application/json is required.");if(M=b.slice(E))if(R=p(e,M),Object.keys(R).length>1||"data"in R||"incremental"in R||"errors"in R||"payload"in R)if((0,c.Nw)(R)){if(_={},"payload"in R){if(1===Object.keys(R).length&&null===R.payload)return[2];_=(0,r.__assign)({},R.payload)}"errors"in R&&(_=(0,r.__assign)((0,r.__assign)({},_),{extensions:(0,r.__assign)((0,r.__assign)({},"extensions"in _?_.extensions:null),(x={},x[l.K$]=R.errors,x))})),t(_)}else t(R);else if(1===Object.keys(R).length&&"hasNext"in R&&!R.hasNext)return[2];S=h.indexOf(u)}return[3,1];case 3:return[2]}})})}function d(e){var t={};return e.split("\n").forEach(function(e){var i=e.indexOf(":");if(i>-1){var r=e.slice(0,i).trim().toLowerCase(),n=e.slice(i+1).trim();t[r]=n}}),t}function p(e,t){e.status>=300&&(0,a.A)(e,function(){try{return JSON.parse(t)}catch(e){return t}}(),"Response not successful: Received status code ".concat(e.status));try{return JSON.parse(t)}catch(r){var i=r;throw i.name="ServerParseError",i.response=e,i.statusCode=e.status,i.bodyText=t,i}}function g(e,t){e.result&&e.result.errors&&e.result.data&&t.next(e.result),t.error(e)}function f(e){return function(t){return t.text().then(function(e){return p(t,e)}).then(function(i){return Array.isArray(i)||u.call(i,"data")||u.call(i,"errors")||(0,a.A)(t,i,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(e){return e.operationName}):e.operationName,"'.")),i})}}},76662(e,t,i){"use strict";i.d(t,{E:()=>n});var r=i(87708);function n(e,t){var i=[],n=function(e,t){i.push("".concat(e,"=").concat(encodeURIComponent(t)))};if("query"in t&&n("query",t.query),t.operationName&&n("operationName",t.operationName),t.variables){var s=void 0;try{s=(0,r.Y)(t.variables,"Variables map")}catch(e){return{parseError:e}}n("variables",s)}if(t.extensions){var o=void 0;try{o=(0,r.Y)(t.extensions,"Extensions map")}catch(e){return{parseError:e}}n("extensions",o)}var a="",l=e,c=e.indexOf("#");-1!==c&&(a=e.substr(c),l=e.substr(0,c));var u=-1===l.indexOf("?")?"?":"&";return{newURI:l+u+i.join("&")+a}}},55662(e,t,i){"use strict";i.d(t,{HY:()=>l,R4:()=>s,Wz:()=>a,i1:()=>o});var r=i(65959),n=i(33137),s={http:{includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},headers:{accept:"*/*","content-type":"application/json"},options:{method:"POST"}},o=function(e,t){return t(e)};function a(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];return i.unshift(t),l.apply(void 0,(0,r.__spreadArray)([e,o],i,!1))}function l(e,t){for(var i=[],s=2;s<arguments.length;s++)i[s-2]=arguments[s];var o={},a={};i.forEach(function(e){o=(0,r.__assign)((0,r.__assign)((0,r.__assign)({},o),e.options),{headers:(0,r.__assign)((0,r.__assign)({},o.headers),e.headers)}),e.credentials&&(o.credentials=e.credentials),a=(0,r.__assign)((0,r.__assign)({},a),e.http)}),o.headers&&(o.headers=function(e,t){if(!t){var i={};return Object.keys(Object(e)).forEach(function(t){i[t.toLowerCase()]=e[t]}),i}var r={};Object.keys(Object(e)).forEach(function(t){r[t.toLowerCase()]={originalName:t,value:e[t]}});var n={};return Object.keys(r).forEach(function(e){n[r[e].originalName]=r[e].value}),n}(o.headers,a.preserveHeaderCase));var l=e.operationName,c=e.extensions,u=e.variables,h=e.query,d={operationName:l,variables:u};return a.includeExtensions&&(d.extensions=c),a.includeQuery&&(d.query=t(h,n.y)),{options:o,body:d}}},61555(e,t,i){"use strict";i.d(t,{z:()=>r});var r=function(e,t){return e.getContext().uri||("function"==typeof t?t(e):t||"/graphql")}},87708(e,t,i){"use strict";i.d(t,{Y:()=>n});var r=i(131),n=function(e,t){var i;try{i=JSON.stringify(e)}catch(e){var n=(0,r.vA)(54,t,e.message);throw n.parseError=e,n}return i}},47752(e,t,i){"use strict";i.d(t,{N:()=>n});var r=i(74140);function n(e){return new r.c(function(t){t.error(e)})}},49703(e,t,i){"use strict";i.d(t,{A:()=>r});var r=function(e,t,i){var r=new Error(i);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r}},94959(e,t,i){"use strict";i.d(t,{S:()=>c});var r=i(49270),n=i(14270),s=i(99310),o=i(12209),a=i(71637),l=i(131);function c(e,t,i){return a.yV.withValue(!0,function(){var r=u(e,t,i,!1);return Object.isFrozen(e)&&(0,o.G)(r),r})}function u(e,t,i,o,a){var c,d=i.knownChanged,p=function(e,t){if(t.has(e))return t.get(e);var i=Array.isArray(e)?[]:Object.create(null);return t.set(e,i),i}(e,i.mutableTargets);if(Array.isArray(e)){for(var g=0,f=Array.from(e.entries());g<f.length;g++){var m=f[g],v=m[0],C=m[1];if(null!==C){var y=u(C,t,i,o,!1!==globalThis.__DEV__?"".concat(a||"","[").concat(v,"]"):void 0);d.has(y)&&d.add(p),p[v]=y}else p[v]=null}return d.has(p)?p:e}for(var w=0,S=t.selections;w<S.length;w++){var b=S[w],E=void 0;if(o&&d.add(p),b.kind===r.b.FIELD){var A=(0,s.ue)(b),T=b.selectionSet;if(void 0===(E=p[A]||e[A]))continue;T&&null!==E&&(y=u(e[A],T,i,o,!1!==globalThis.__DEV__?"".concat(a||"",".").concat(A):void 0),d.has(y)&&(E=y)),!1===globalThis.__DEV__&&(p[A]=E),!1!==globalThis.__DEV__&&(o&&"__typename"!==A&&!(null===(c=Object.getOwnPropertyDescriptor(p,A))||void 0===c?void 0:c.value)?Object.defineProperty(p,A,h(A,E,a||"",i.operationName,i.operationType)):(delete p[A],p[A]=E))}if(b.kind!==r.b.INLINE_FRAGMENT||b.typeCondition&&!i.cache.fragmentMatches(b,e.__typename)||(E=u(e,b.selectionSet,i,o,a)),b.kind===r.b.FRAGMENT_SPREAD){var M=b.name.value,R=i.fragmentMap[M]||(i.fragmentMap[M]=i.cache.lookupFragment(M));(0,l.V1)(R,59,M);var _=(0,n.s7)(b);"mask"!==_&&(E=u(e,R.selectionSet,i,"migrate"===_,a))}d.has(E)&&d.add(p)}return"__typename"in e&&!("__typename"in p)&&(p.__typename=e.__typename),Object.keys(p).length!==Object.keys(e).length&&d.add(p),d.has(p)?p:e}function h(e,t,i,r,n){var s=function(){return a.yV.getValue()||(!1!==globalThis.__DEV__&&l.V1.warn(60,r?"".concat(n," '").concat(r,"'"):"anonymous ".concat(n),"".concat(i,".").concat(e).replace(/^\./,"")),s=function(){return t}),t};return{get:function(){return s()},set:function(e){s=function(){return e}},enumerable:!0,configurable:!0}}},13062(e,t,i){"use strict";i.d(t,{z:()=>u});var r=i(49270),n=i(71637),s=i(131),o=i(45063),a=i(94959),l=i(48555),c=i(47812);function u(e,t,i,u){if(!i.fragmentMatches)return!1!==globalThis.__DEV__&&(0,n.Ki)(),e;var h=t.definitions.filter(function(e){return e.kind===r.b.FRAGMENT_DEFINITION});void 0===u&&((0,s.V1)(1===h.length,61,h.length),u=h[0].name.value);var d=h.find(function(e){return e.name.value===u});return(0,s.V1)(!!d,62,u),null==e||(0,o.A)(e,{})?e:(0,a.S)(e,d.selectionSet,{operationType:"fragment",operationName:d.name.value,fragmentMap:(0,l.JG)((0,c.zK)(t)),cache:i,mutableTargets:new n.jq,knownChanged:new n.xm})}},71637(e,t,i){"use strict";i.d(t,{Ki:()=>u,jq:()=>o,xm:()=>a,yV:()=>l});var r=i(81987),n=i(131),s=i(97703),o=s.et?WeakMap:Map,a=s.En?WeakSet:Set,l=new r.DX,c=!1;function u(){c||(c=!0,!1!==globalThis.__DEV__&&n.V1.warn(64))}},76013(e,t,i){"use strict";i.d(t,{s:()=>a});var r=i(5821),n=i(38640),s=i(66003),o=i(131);function a(e){(0,s.k)("<Mutation />",function(){!1!==globalThis.__DEV__&&o.V1.warn(65)});var t=(0,n.n)(e.mutation,e),i=t[0],r=t[1];return e.children?e.children(i,r):null}a.propTypes={mutation:r.object.isRequired,variables:r.object,optimisticResponse:r.oneOfType([r.object,r.func]),refetchQueries:r.oneOfType([r.arrayOf(r.oneOfType([r.string,r.object])),r.func]),awaitRefetchQueries:r.bool,update:r.func,children:r.func.isRequired,onCompleted:r.func,onError:r.func,fetchPolicy:r.string}},95115(e,t,i){"use strict";i.d(t,{X:()=>l});var r=i(65959),n=i(5821),s=i(10344),o=i(131),a=i(66003);function l(e){(0,a.k)("<Query />",function(){!1!==globalThis.__DEV__&&o.V1.warn(66)});var t=e.children,i=e.query,n=(0,r.__rest)(e,["children","query"]),l=(0,s.IT)(i,n);return l?t(l):null}l.propTypes={client:n.object,children:n.func.isRequired,fetchPolicy:n.string,notifyOnNetworkStatusChange:n.bool,onCompleted:n.func,onError:n.func,pollInterval:n.number,query:n.object.isRequired,variables:n.object,ssr:n.bool,partialRefetch:n.bool,returnPartialData:n.bool}},69177(e,t,i){"use strict";var r;i.d(t,{l:()=>l});var n=i(63780),s=i(97703),o=i(131),a=s.ol?Symbol.for("__APOLLO_CONTEXT__"):"__APOLLO_CONTEXT__";function l(){(0,o.V1)("createContext"in(r||(r=i.t(n,2))),69);var e=n.createContext[a];return e||(Object.defineProperty(n.createContext,a,{value:e=n.createContext({}),enumerable:!1,writable:!1,configurable:!0}),e.displayName="ApolloContext"),e}},40833(e,t,i){"use strict";i.d(t,{X:()=>a});var r=i(65959),n=i(131),s=i(63780),o=i(69177),a=function(e){var t=e.client,i=e.children,a=(0,o.l)(),l=s.useContext(a),c=s.useMemo(function(){return(0,r.__assign)((0,r.__assign)({},l),{client:t||l.client})},[l,t]);return(0,n.V1)(c.client,71),s.createElement(a.Provider,{value:c},i)}},17084(e,t,i){"use strict";i.d(t,{U:()=>S});var r=i(28367),n=i(65959),s=i(63780),o=i(4674),a=i(95115),l=i(131),c=function(){return{}},u=function(){return!1};function h(e){return e.displayName||e.name||"Component"}function d(e,t){for(var i={},r=0,n=e.variables;r<n.length;r++){var s=n[r],o=s.variable,a=s.type;if(o.name&&o.name.value){var l=o.name.value,c=t[l];void 0===c?"NonNullType"!==a.kind&&(i[l]=void 0):i[l]=c}}return i}var p=function(e){function t(t){var i=e.call(this,t)||this;return i.withRef=!1,i.setWrappedInstance=i.setWrappedInstance.bind(i),i}return(0,n.__extends)(t,e),t.prototype.getWrappedInstance=function(){return(0,l.V1)(this.withRef,73),this.wrappedInstance},t.prototype.setWrappedInstance=function(e){this.wrappedInstance=e},t}(s.Component),g=i(92981),f=i(30301),m=i(76013),v=i(5821),C=i(72634),y=i(66003);function w(e){(0,y.k)("<Subscription />",function(){!1!==globalThis.__DEV__&&l.V1.warn(67)});var t=(0,C.R)(e.subscription,e);return e.children&&t?e.children(t):null}function S(e,t){switch(void 0===t&&(t={}),!1!==globalThis.__DEV__&&(0,f.S2)("graphql",function(){!1!==globalThis.__DEV__&&l.V1.warn(72)}),(0,f.lz)("parser",function(){return(0,r.K3)(e).type})){case r.KG.Mutation:return(0,f.lz)("withMutation",function(){return function(e,t){void 0===t&&(t={}),!1!==globalThis.__DEV__&&(0,f.S2)("withMutation",function(){!1!==globalThis.__DEV__&&l.V1.warn(74)});var i=(0,f.lz)("parser",r.K3,[e]),a=t.options,u=void 0===a?c:a,g=t.alias,v=void 0===g?"Apollo":g,C=u;return"function"!=typeof C&&(C=function(){return u}),function(r){var a="".concat(v,"(").concat(h(r),")"),l=function(o){function l(){return null!==o&&o.apply(this,arguments)||this}return(0,n.__extends)(l,o),l.prototype.render=function(){var o=this.props,a=C(o);return t.withRef&&(this.withRef=!0,o=Object.assign({},o,{ref:this.setWrappedInstance})),!a.variables&&i.variables.length>0&&(a.variables=d(i,o)),s.createElement(m.s,(0,n.__assign)({ignoreResults:!0},a,{mutation:e}),function(e,i){var a,l,c=i.data,u=(0,n.__rest)(i,["data"]),h=Object.assign(u,c||{}),d=t.name||"mutate",p=t.name?"".concat(d,"Result"):"result",g=((a={})[d]=e,a[p]=h,a);if(t.props){var f=((l={})[d]=e,l[p]=h,l.ownProps=o,l);g=t.props(f)}return s.createElement(r,(0,n.__assign)({},o,g))})},l.displayName=a,l.WrappedComponent=r,l}(p);return o(l,r,{})}}(e,t)});case r.KG.Subscription:return(0,f.lz)("withSubscription",function(){return function(e,t){void 0===t&&(t={}),!1!==globalThis.__DEV__&&(0,f.S2)("withSubscription",function(){!1!==globalThis.__DEV__&&l.V1.warn(76)});var i=(0,f.lz)("parser",r.K3,[e]),a=t.options,g=void 0===a?c:a,m=t.skip,v=void 0===m?u:m,C=t.alias,y=void 0===C?"Apollo":C,S=t.shouldResubscribe,b=g;"function"!=typeof b&&(b=function(){return g});var E,A=v;return"function"!=typeof A&&(A=function(){return v}),function(r){var a="".concat(y,"(").concat(h(r),")"),l=function(o){function l(e){var t=o.call(this,e)||this;return t.state={resubscribe:!1},t}return(0,n.__extends)(l,o),l.prototype.updateResubscribe=function(e){this.setState({resubscribe:e})},l.prototype.componentDidUpdate=function(e){var t=!(!S||!S(e,this.props));this.state.resubscribe!==t&&this.updateResubscribe(t)},l.prototype.render=function(){var o=this,l=this.props,c=A(l),u=c?Object.create(null):b(l);return!c&&!u.variables&&i.variables.length>0&&(u.variables=d(i,l)),s.createElement(w,(0,n.__assign)({},u,{displayName:a,skip:c,subscription:e,shouldResubscribe:this.state.resubscribe}),function(e){var i,a,u=e.data,h=(0,n.__rest)(e,["data"]);if(t.withRef&&(o.withRef=!0,l=Object.assign({},l,{ref:o.setWrappedInstance})),c)return s.createElement(r,(0,n.__assign)({},l,{}));var d=Object.assign(h,u||{}),p=t.name||"data",g=((i={})[p]=d,i);if(t.props){var f=((a={})[p]=d,a.ownProps=l,a);g=E=t.props(f,E)}return s.createElement(r,(0,n.__assign)({},l,g))})},l.displayName=a,l.WrappedComponent=r,l}(p);return o(l,r,{})}}(e,t)});case r.KG.Query:default:return(0,f.lz)("withQuery",function(){return function(e,t){void 0===t&&(t={}),!1!==globalThis.__DEV__&&(0,f.S2)("withQuery",function(){!1!==globalThis.__DEV__&&g.Ay.warn(75)});var i=(0,f.lz)("parser",r.K3,[e]),l=t.options,m=void 0===l?c:l,v=t.skip,C=void 0===v?u:v,y=t.alias,w=void 0===y?"Apollo":y,S=m;"function"!=typeof S&&(S=function(){return m});var b,E=C;return"function"!=typeof E&&(E=function(){return C}),function(r){var l="".concat(w,"(").concat(h(r),")"),c=function(o){function c(){return null!==o&&o.apply(this,arguments)||this}return(0,n.__extends)(c,o),c.prototype.render=function(){var o=this,c=this.props,u=E(c),h=u?Object.create(null):(0,n.__assign)({},S(c));return!u&&!h.variables&&i.variables.length>0&&(h.variables=d(i,c)),s.createElement(a.X,(0,n.__assign)({},h,{displayName:l,skip:u,query:e}),function(e){e.client;var i,a,l=e.data,h=(0,n.__rest)(e,["client","data"]);if(t.withRef&&(o.withRef=!0,c=Object.assign({},c,{ref:o.setWrappedInstance})),u)return s.createElement(r,(0,n.__assign)({},c,{}));var d=Object.assign(h,l||{}),p=t.name||"data",g=((i={})[p]=d,i);if(t.props){var f=((a={})[p]=d,a.ownProps=c,a);g=b=t.props(f,b)}return s.createElement(r,(0,n.__assign)({},c,g))})},c.displayName=l,c.WrappedComponent=r,c}(p);return o(c,r,{})}}(e,t)})}}w.propTypes={subscription:v.object.isRequired,variables:v.object,children:v.func,onSubscriptionData:v.func,onData:v.func,onSubscriptionComplete:v.func,onComplete:v.func,shouldResubscribe:v.oneOfType([v.func,v.bool])}},2374(e,t,i){"use strict";i.d(t,{W:()=>c});var r=i(65959),n=i(131),s=i(63780),o=i(4674),a=i(69177),l=function(e){var t=(0,a.l)();return s.createElement(t.Consumer,null,function(t){return(0,n.V1)(t&&t.client,68),e.children(t.client)})};function c(e,t){void 0===t&&(t={});var i="withApollo(".concat(function(e){return e.displayName||e.name||"Component"}(e),")"),a=function(o){function a(e){var t=o.call(this,e)||this;return t.setWrappedInstance=t.setWrappedInstance.bind(t),t}return(0,r.__extends)(a,o),a.prototype.getWrappedInstance=function(){return(0,n.V1)(t.withRef,77),this.wrappedInstance},a.prototype.setWrappedInstance=function(e){this.wrappedInstance=e},a.prototype.render=function(){var i=this;return s.createElement(l,null,function(n){var o=Object.assign({},i.props,{client:n,ref:t.withRef?i.setWrappedInstance:void 0});return s.createElement(e,(0,r.__assign)({},o))})},a.displayName=i,a.WrappedComponent=e,a}(s.Component);return o(a,e,{})}},99449(e,t,i){"use strict";i.d(t,{E:()=>n});var r=i(63780),n=i(97703).Sw?r.useLayoutEffect:r.useEffect},66003(e,t,i){"use strict";i.d(t,{k:()=>s});var r=i(63780),n=i(30301);function s(e,t){var i=r.useRef(!1);!1!==globalThis.__DEV__&&(i.current||(0,n.S2)(e,t),i.current=!0)}},25302(e,t,i){"use strict";i.d(t,{h:()=>s});var r=i(63780),n=i(131);function s(e,t,i,s){void 0===s&&(s="Please remove this option.");var o=r.useRef(!1);t in e&&!o.current&&(!1!==globalThis.__DEV__&&n.V1.warn(78,i,t,s),o.current=!0)}},62659(e,t,i){"use strict";i.d(t,{m:()=>o});var r=i(131),n=i(63780),s=i(69177);function o(e){var t=n.useContext((0,s.l)()),i=e||t.client;return(0,r.V1)(!!i,79),i}},13542(e,t,i){"use strict";i.d(t,{_:()=>m});var r,n=i(65959),s=i(63780),o=i(97460),a=i(10344),l=i(99449),c=i(25302),u=i(27119),h=i(30301);function d(){}var p=["refetch","reobserve","fetchMore","updateQuery","startPolling","stopPolling","subscribeToMore"],g=["initialFetchPolicy","onCompleted","onError","defaultOptions","partialRefetch","canonizeResults"],f=["query","ssr","client","fetchPolicy","nextFetchPolicy","refetchWritePolicy","errorPolicy","pollInterval","notifyOnNetworkStatusChange","returnPartialData","skipPollAttempt"];function m(e,t){var i;if(!1!==globalThis.__DEV__){var m=t||{};(0,c.h)(m,"canonizeResults","useLazyQuery"),(0,c.h)(m,"variables","useLazyQuery","Pass all `variables` to the returned `execute` function instead."),(0,c.h)(m,"context","useLazyQuery","Pass `context` to the returned `execute` function instead."),(0,c.h)(m,"onCompleted","useLazyQuery","If your `onCompleted` callback sets local state, switch to use derived state using `data` returned from the hook instead. Use `useEffect` to perform side-effects as a result of updates to `data`."),(0,c.h)(m,"onError","useLazyQuery","If your `onError` callback sets local state, switch to use derived state using `data`, `error` or `errors` returned from the hook instead. Use `useEffect` if you need to perform side-effects as a result of updates to `data`, `error` or `errors`."),(0,c.h)(m,"defaultOptions","useLazyQuery","Pass the options directly to the hook instead."),(0,c.h)(m,"initialFetchPolicy","useLazyQuery","Use the `fetchPolicy` option instead."),(0,c.h)(m,"partialRefetch","useLazyQuery")}var v=s.useRef(void 0),C=s.useRef(void 0),y=s.useRef(void 0),w=(0,o.l)(t,v.current||{}),S=null!==(i=null==w?void 0:w.query)&&void 0!==i?i:e;C.current=t,y.current=S;var b=(0,n.__assign)((0,n.__assign)({},w),{skip:!v.current}),E=(0,a.SX)(S,b),A=E.obsQueryFields,T=E.result,M=E.client,R=E.resultData,_=E.observable,P=E.onQueryExecuted,x=_.options.initialFetchPolicy||(0,a.kk)(b.defaultOptions,M.defaultOptions),D=s.useReducer(function(e){return e+1},0)[1],I=s.useMemo(function(){for(var e={},t=function(t){var i=A[t];e[t]=function(){return!1!==globalThis.__DEV__&&"reobserve"===t&&!1!==globalThis.__DEV__&&u.V1.warn(80),v.current||(v.current=Object.create(null),D()),i.apply(this,arguments)}},i=0,r=p;i<r.length;i++)t(r[i]);return e},[D,A]),L=!!v.current,N=s.useMemo(function(){return(0,n.__assign)((0,n.__assign)((0,n.__assign)({},T),I),{called:L})},[T,I,L]),O=(r||(r=s.createContext(null)),s.useCallback(function(){var e=console.error;try{return console.error=d,s.useContext(r),!0}catch(e){return!1}finally{console.error=e}},[])),F=s.useRef(new Set),k=s.useCallback(function(e){if(!1!==globalThis.__DEV__){O()&&!1!==globalThis.__DEV__&&u.V1.warn(81);for(var t=0,i=g;t<i.length;t++){var r=i[t];F.current.has(r)||((0,h.cc)(e||{},r,"useLazyQuery.execute"),F.current.add(r))}for(var s=0,l=f;s<l.length;s++){var c=l[s];F.current.has(c)||((0,h.cc)(e||{},c,"useLazyQuery.execute","Please pass the option to the `useLazyQuery` hook instead."),F.current.add(c))}}v.current=e?(0,n.__assign)((0,n.__assign)({},e),{fetchPolicy:e.fetchPolicy||x}):{fetchPolicy:x};var d=(0,o.l)(C.current,(0,n.__assign)({query:y.current},v.current)),p=function(e,t,i,r,n,s){var o=n.query||r,l=(0,a.Er)(i,o,n,!1)(t),c=t.reobserveAsConcast((0,a.t_)(t,i,n,l));return s(l),new Promise(function(r){var n;c.subscribe({next:function(e){n=e},error:function(){r((0,a.$X)(t.getCurrentResult(),e.previousData,t,i))},complete:function(){r((0,a.$X)(t.maskResult(n),e.previousData,t,i))}})})}(R,_,M,S,(0,n.__assign)((0,n.__assign)({},d),{skip:!1}),P).then(function(e){return Object.assign(e,I)});return p.catch(function(){}),p},[O,M,S,I,x,_,R,P]),G=s.useRef(k);(0,l.E)(function(){G.current=k});var V=s.useCallback(function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return G.current.apply(G,e)},[]);return[V,N]}},38640(e,t,i){"use strict";i.d(t,{n:()=>d});var r=i(65959),n=i(63780),s=i(97460),o=i(45063),a=i(28367),l=i(17303),c=i(62659),u=i(99449),h=i(25302);function d(e,t){!1!==globalThis.__DEV__&&(0,h.h)(t||{},"ignoreResults","useMutation","If you don't want to synchronize component state with the mutation, please use the `useApolloClient` hook to get the client instance and call `client.mutate` directly.");var i=(0,c.m)(null==t?void 0:t.client);(0,a.D$)(e,a.KG.Mutation);var d=n.useState({called:!1,loading:!1,client:i}),p=d[0],g=d[1],f=n.useRef({result:p,mutationId:0,isMounted:!0,client:i,mutation:e,options:t});(0,u.E)(function(){Object.assign(f.current,{client:i,options:t,mutation:e})});var m=n.useCallback(function(e){void 0===e&&(e={});var t=f.current,i=t.options,n=t.mutation,a=(0,r.__assign)((0,r.__assign)({},i),{mutation:n}),c=e.client||f.current.client;f.current.result.loading||a.ignoreResults||!f.current.isMounted||g(f.current.result={loading:!0,error:void 0,data:void 0,called:!0,client:c});var u=++f.current.mutationId,h=(0,s.l)(a,e);return c.mutate(h).then(function(t){var i,r,n=t.data,s=t.errors,a=s&&s.length>0?new l.K4({graphQLErrors:s}):void 0,d=e.onError||(null===(i=f.current.options)||void 0===i?void 0:i.onError);if(a&&d&&d(a,h),u===f.current.mutationId&&!h.ignoreResults){var p={called:!0,loading:!1,data:n,error:a,client:c};f.current.isMounted&&!(0,o.L)(f.current.result,p)&&g(f.current.result=p)}var m=e.onCompleted||(null===(r=f.current.options)||void 0===r?void 0:r.onCompleted);return a||null==m||m(t.data,h),t},function(t){var i;if(u===f.current.mutationId&&f.current.isMounted){var r={loading:!1,error:t,data:void 0,called:!0,client:c};(0,o.L)(f.current.result,r)||g(f.current.result=r)}var n=e.onError||(null===(i=f.current.options)||void 0===i?void 0:i.onError);if(n)return n(t,h),{data:void 0,errors:t};throw t})},[]),v=n.useCallback(function(){if(f.current.isMounted){var e={called:!1,loading:!1,client:f.current.client};Object.assign(f.current,{mutationId:0,result:e}),g(e)}},[]);return n.useEffect(function(){var e=f.current;return e.isMounted=!0,function(){e.isMounted=!1}},[]),[m,(0,r.__assign)({reset:v},p)]}},10344(e,t,i){"use strict";i.d(t,{Er:()=>R,kk:()=>D,t_:()=>_,jy:()=>I,$X:()=>L,IT:()=>A,SX:()=>M});var r=i(65959),n=i(131),s=i(63780),o=i(8590),a=i(45063),l=i(97460),c=i(69177),u=i(17303),h=i(78440),d=i(49995),p=i(28367),g=i(62659),f=i(58173),m=i(79e3),v=i(12209),C=Symbol.for("apollo.hook.wrappers"),y=i(25302),w=i(30301),S=Object.prototype.hasOwnProperty;function b(){}var E=Symbol();function A(e,t){return void 0===t&&(t=Object.create(null)),(i=T,(s=(n=(r=(0,g.m)(t&&t.client).queryManager)&&r[C])&&n.useQuery)?s(i):i)(e,t);var i,r,n,s}function T(e,t){!1!==globalThis.__DEV__&&((0,y.h)(t,"canonizeResults","useQuery"),(0,y.h)(t,"partialRefetch","useQuery"),(0,y.h)(t,"defaultOptions","useQuery","Pass the options directly to the hook instead."),(0,y.h)(t,"onCompleted","useQuery","If your `onCompleted` callback sets local state, switch to use derived state using `data` returned from the hook instead. Use `useEffect` to perform side-effects as a result of updates to `data`."),(0,y.h)(t,"onError","useQuery","If your `onError` callback sets local state, switch to use derived state using `data`, `error` or `errors` returned from the hook instead. Use `useEffect` if you need to perform side-effects as a result of updates to `data`, `error` or `errors`."));var i=M(e,t),n=i.result,o=i.obsQueryFields;return s.useMemo(function(){return(0,r.__assign)((0,r.__assign)({},n),o)},[n,o])}function M(e,t){var i=(0,g.m)(t.client),l=s.useContext((0,c.l)()).renderPromises,u=!!l,f=i.disableNetworkFetches,m=!1!==t.ssr&&!t.skip,v=t.partialRefetch,C=R(i,e,t,u),y=function(e,t,i,n,o){function a(r){var s;return(0,p.D$)(t,p.KG.Query),{client:e,query:t,observable:n&&n.getSSRObservable(o())||h.U.inactiveOnCreation.withValue(!n,function(){return(0,w.lz)("canonizeResults",function(){return e.watchQuery(_(void 0,e,i,o()))})}),resultData:{previousData:null===(s=null==r?void 0:r.resultData.current)||void 0===s?void 0:s.data}}}var l=s.useState(a),c=l[0],u=l[1];function d(e){var t,i;Object.assign(c.observable,((t={})[E]=e,t));var n=c.resultData;u((0,r.__assign)((0,r.__assign)({},c),{query:e.query,resultData:Object.assign(n,{previousData:(null===(i=n.current)||void 0===i?void 0:i.data)||n.previousData,current:void 0})}))}if(e!==c.client||t!==c.query){var g=a(c);return u(g),[g,d]}return[c,d]}(i,e,t,l,C),A=y[0],T=A.observable,M=A.resultData,D=y[1],I=C(T);!function(e,t,i,r,n){var s;t[E]&&!(0,a.L)(t[E],n)&&(t.reobserve(_(t,i,r,n)),e.previousData=(null===(s=e.current)||void 0===s?void 0:s.data)||e.previousData,e.current=void 0),t[E]=n}(M,T,i,t,I);var F=s.useMemo(function(){return function(e){return{refetch:e.refetch.bind(e),reobserve:function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return!1!==globalThis.__DEV__&&!1!==globalThis.__DEV__&&n.V1.warn(84),e.reobserve.apply(e,t)},fetchMore:e.fetchMore.bind(e),updateQuery:e.updateQuery.bind(e),startPolling:e.startPolling.bind(e),stopPolling:e.stopPolling.bind(e),subscribeToMore:e.subscribeToMore.bind(e)}}(T)},[T]);!function(e,t,i){t&&i&&(t.registerSSRObservable(e),e.getCurrentResult().loading&&t.addObservableQueryPromise(e))}(T,l,m);var k=function(e,t,i,r,n,l,c,u,h){var p=s.useRef(h);s.useEffect(function(){p.current=h});var g=!u&&!l||!1!==r.ssr||r.skip?r.skip||"standby"===n.fetchPolicy?O:void 0:N,f=e.previousData,m=s.useMemo(function(){return g&&L(g,f,t,i)},[i,t,g,f]);return(0,o.r)(s.useCallback(function(r){if(u)return function(){};var n=function(){var n=e.current,s=t.getCurrentResult();n&&n.loading===s.loading&&n.networkStatus===s.networkStatus&&(0,a.L)(n.data,s.data)||P(s,e,t,i,c,r,p.current)},s=function(l){if(o.current.unsubscribe(),o.current=t.resubscribeAfterError(n,s),!S.call(l,"graphQLErrors"))throw l;var u=e.current;(!u||u&&u.loading||!(0,a.L)(l,u.error))&&P({data:u&&u.data,error:l,loading:!1,networkStatus:d.pT.error},e,t,i,c,r,p.current)},o={current:t.subscribe(n,s)};return function(){setTimeout(function(){return o.current.unsubscribe()})}},[l,u,t,e,c,i]),function(){return m||x(e,t,p.current,c,i)},function(){return m||x(e,t,p.current,c,i)})}(M,T,i,t,I,f,v,u,{onCompleted:t.onCompleted||b,onError:t.onError||b});return{result:k,obsQueryFields:F,observable:T,resultData:M,client:i,onQueryExecuted:D}}function R(e,t,i,n){void 0===i&&(i={});var s=i.skip,o=(i.ssr,i.onCompleted,i.onError,i.defaultOptions),a=(0,r.__rest)(i,["skip","ssr","onCompleted","onError","defaultOptions"]);return function(i){var r=Object.assign(a,{query:t});return!n||"network-only"!==r.fetchPolicy&&"cache-and-network"!==r.fetchPolicy||(r.fetchPolicy="cache-first"),r.variables||(r.variables={}),s?(r.initialFetchPolicy=r.initialFetchPolicy||r.fetchPolicy||D(o,e.defaultOptions),r.fetchPolicy="standby"):r.fetchPolicy||(r.fetchPolicy=(null==i?void 0:i.options.initialFetchPolicy)||D(o,e.defaultOptions)),r}}function _(e,t,i,r){var n=[],s=t.defaultOptions.watchQuery;return s&&n.push(s),i.defaultOptions&&n.push(i.defaultOptions),n.push((0,f.o)(e&&e.options,r)),n.reduce(l.l)}function P(e,t,i,s,o,a,l){var c=t.current;c&&c.data&&(t.previousData=c.data),!e.error&&(0,m.E)(e.errors)&&(e.error=new u.K4({graphQLErrors:e.errors})),t.current=L(function(e,t,i){return!e.partial||!i||e.loading||e.data&&0!==Object.keys(e.data).length||"cache-only"===t.options.fetchPolicy?e:(t.refetch(),(0,r.__assign)((0,r.__assign)({},e),{loading:!0,networkStatus:d.pT.refetch}))}(e,i,o),t.previousData,i,s),a(),function(e,t,i){if(!e.loading){var r=I(e);Promise.resolve().then(function(){r?i.onError(r):e.data&&t!==e.networkStatus&&e.networkStatus===d.pT.ready&&i.onCompleted(e.data)}).catch(function(e){!1!==globalThis.__DEV__&&n.V1.warn(e)})}}(e,null==c?void 0:c.networkStatus,l)}function x(e,t,i,r,n){return e.current||P(t.getCurrentResult(),e,t,n,r,function(){},i),e.current}function D(e,t){var i;return(null==e?void 0:e.fetchPolicy)||(null===(i=null==t?void 0:t.watchQuery)||void 0===i?void 0:i.fetchPolicy)||"cache-first"}function I(e){return(0,m.E)(e.errors)?new u.K4({graphQLErrors:e.errors}):e.error}function L(e,t,i,n){var s=e.data,o=(e.partial,(0,r.__rest)(e,["data","partial"]));return(0,r.__assign)((0,r.__assign)({data:s},o),{client:n,observable:i,variables:i.variables,called:e!==N&&e!==O,previousData:t})}var N=(0,v.G)({loading:!0,data:void 0,error:void 0,networkStatus:d.pT.loading}),O=(0,v.G)({loading:!1,data:void 0,error:void 0,networkStatus:d.pT.ready})},72634(e,t,i){"use strict";i.d(t,{R:()=>g});var r=i(65959),n=i(131),s=i(63780),o=i(45063),a=i(28367),l=i(17303),c=i(74140),u=i(62659),h=i(8590),d=i(10344),p=i(99449);function g(e,t){void 0===t&&(t=Object.create(null));var i=s.useRef(!1),g=(0,u.m)(t.client);(0,a.D$)(e,a.KG.Subscription),i.current||(i.current=!0,t.onSubscriptionData&&!1!==globalThis.__DEV__&&n.V1.warn(t.onData?85:86),t.onSubscriptionComplete&&!1!==globalThis.__DEV__&&n.V1.warn(t.onComplete?87:88));var f,m,v,C=t.skip,y=t.fetchPolicy,w=t.errorPolicy,S=t.shouldResubscribe,b=t.context,E=t.extensions,A=t.ignoreResults,T=(f=function(){return t.variables},m=[t.variables],(v=s.useRef(void 0)).current&&(0,o.L)(v.current.deps,m)||(v.current={value:f(),deps:m}),v.current.value),M=function(){return function(e,t,i,n,s,o,a){var l={query:t,variables:i,fetchPolicy:n,errorPolicy:s,context:o,extensions:a},u=(0,r.__assign)((0,r.__assign)({},l),{client:e,result:{loading:!0,data:void 0,error:void 0,variables:i},setResult:function(e){u.result=e}}),h=null;return Object.assign(new c.c(function(t){h||(h=e.subscribe(l));var i=h.subscribe(t);return function(){return i.unsubscribe()}}),{__:u})}(g,e,T,y,w,b,E)},R=s.useState(t.skip?null:M),_=R[0],P=R[1],x=s.useRef(M);(0,p.E)(function(){x.current=M}),C?_&&P(_=null):_&&(g===_.__.client&&e===_.__.query&&y===_.__.fetchPolicy&&w===_.__.errorPolicy&&(0,o.L)(T,_.__.variables)||!1===("function"==typeof S?!!S(t):S))||P(_=M());var D=s.useRef(t);s.useEffect(function(){D.current=t});var I=!C&&!A,L=s.useMemo(function(){return{loading:I,error:void 0,data:void 0,variables:T}},[I,T]),N=s.useRef(A);(0,p.E)(function(){N.current=A});var O=(0,h.r)(s.useCallback(function(e){if(!_)return function(){};var t=!1,i=_.__.variables,r=_.__.client,n=_.subscribe({next:function(n){var s,o;if(!t){var a={loading:!1,data:n.data,error:(0,d.jy)(n),variables:i};_.__.setResult(a),N.current||e(),a.error?null===(o=(s=D.current).onError)||void 0===o||o.call(s,a.error):D.current.onData?D.current.onData({client:r,data:a}):D.current.onSubscriptionData&&D.current.onSubscriptionData({client:r,subscriptionData:a})}},error:function(r){var n,s;r=r instanceof l.K4?r:new l.K4({protocolErrors:[r]}),t||(_.__.setResult({loading:!1,data:void 0,error:r,variables:i}),N.current||e(),null===(s=(n=D.current).onError)||void 0===s||s.call(n,r))},complete:function(){t||(D.current.onComplete?D.current.onComplete():D.current.onSubscriptionComplete&&D.current.onSubscriptionComplete())}});return function(){t=!0,setTimeout(function(){n.unsubscribe()})}},[_]),function(){return!_||C||A?L:_.__.result},function(){return L}),F=s.useCallback(function(){(0,n.V1)(!D.current.skip,89),P(x.current())},[D,x]);return s.useMemo(function(){return(0,r.__assign)((0,r.__assign)({},O),{restart:F})},[O,F])}},8590(e,t,i){"use strict";var r;i.d(t,{r:()=>l});var n=i(131),s=i(63780),o=i(97703),a=!1,l=(r||(r=i.t(s,2))).useSyncExternalStore||function(e,t,i){var r=t();!1===globalThis.__DEV__||a||r===t()||(a=!0,!1!==globalThis.__DEV__&&n.V1.error(92));var l=s.useState({inst:{value:r,getSnapshot:t}}),u=l[0].inst,h=l[1];return o.JR?s.useLayoutEffect(function(){Object.assign(u,{value:r,getSnapshot:t}),c(u)&&h({inst:u})},[e,r,t]):Object.assign(u,{value:r,getSnapshot:t}),s.useEffect(function(){return c(u)&&h({inst:u}),e(function(){c(u)&&h({inst:u})})},[e]),r};function c(e){var t=e.value,i=e.getSnapshot;try{return t!==i()}catch(e){return!0}}},28367(e,t,i){"use strict";i.d(t,{D$:()=>d,K3:()=>h,KG:()=>r});var r,n,s=i(131),o=i(75859),a=i(19360),l=i(27231),c=i(30301);function u(e){var t;switch(e){case r.Query:t="Query";break;case r.Mutation:t="Mutation";break;case r.Subscription:t="Subscription"}return t}function h(e){(0,c.S2)("parser",function(){!1!==globalThis.__DEV__&&s.V1.warn(94)}),n||(n=new o.A(a.v.parser||1e3));var t,i,l=n.get(e);if(l)return l;(0,s.V1)(!!e&&!!e.kind,95,e);for(var u=[],h=[],d=[],p=[],g=0,f=e.definitions;g<f.length;g++){var m=f[g];if("FragmentDefinition"!==m.kind){if("OperationDefinition"===m.kind)switch(m.operation){case"query":h.push(m);break;case"mutation":d.push(m);break;case"subscription":p.push(m)}}else u.push(m)}(0,s.V1)(!u.length||h.length||d.length||p.length,96),(0,s.V1)(h.length+d.length+p.length<=1,97,e,h.length,p.length,d.length),i=h.length?r.Query:r.Mutation,h.length||d.length||(i=r.Subscription);var v=h.length?h:d.length?d:p;(0,s.V1)(1===v.length,98,e,v.length);var C=v[0];t=C.variableDefinitions||[];var y={name:C.name&&"Name"===C.name.kind?C.name.value:"data",type:i,variables:t};return n.set(e,y),y}function d(e,t){var i=(0,c.lz)("parser",h,[e]),r=u(t),n=u(i.type);(0,s.V1)(i.type===t,99,r,r,n)}!function(e){e[e.Query=0]="Query",e[e.Mutation=1]="Mutation",e[e.Subscription=2]="Subscription"}(r||(r={})),h.resetCache=function(){n=void 0},!1!==globalThis.__DEV__&&(0,l.D_)("parser",function(){return n?n.size:0})},75859(e,t,i){"use strict";i.d(t,{A:()=>a,V:()=>l});var r=i(23336),n=i(78027),s=new WeakSet;function o(e){e.size<=(e.max||-1)||s.has(e)||(s.add(e),setTimeout(function(){e.clean(),s.delete(e)},100))}var a=function(e,t){var i=new n.l(e,t);return i.set=function(e,t){var i=n.l.prototype.set.call(this,e,t);return o(this),i},i},l=function(e,t){var i=new r.C(e,t);return i.set=function(e,t){var i=r.C.prototype.set.call(this,e,t);return o(this),i},i}},27231(e,t,i){"use strict";i.d(t,{D_:()=>o,cM:()=>l,ep:()=>a,tQ:()=>c});var r=i(65959),n=i(19360),s={};function o(e,t){s[e]=t}var a=!1!==globalThis.__DEV__?function(){var e,t,i,o,a;if(!1===globalThis.__DEV__)throw new Error("only supported in development mode");return{limits:Object.fromEntries(Object.entries({parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4}).map(function(e){var t=e[0],i=e[1];return[t,n.v[t]||i]})),sizes:(0,r.__assign)({print:null===(e=s.print)||void 0===e?void 0:e.call(s),parser:null===(t=s.parser)||void 0===t?void 0:t.call(s),canonicalStringify:null===(i=s.canonicalStringify)||void 0===i?void 0:i.call(s),links:f(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:p(this.queryManager.documentTransform)}},null===(a=(o=this.cache).getMemoryInternals)||void 0===a?void 0:a.call(o))}}:void 0,l=!1!==globalThis.__DEV__?function(){var e=this.config.fragments;return(0,r.__assign)((0,r.__assign)({},u.apply(this)),{addTypenameDocumentTransform:p(this.addTypenameTransform),inMemoryCache:{executeSelectionSet:h(this.storeReader.executeSelectionSet),executeSubSelectedArray:h(this.storeReader.executeSubSelectedArray),maybeBroadcastWatch:h(this.maybeBroadcastWatch)},fragmentRegistry:{findFragmentSpreads:h(null==e?void 0:e.findFragmentSpreads),lookup:h(null==e?void 0:e.lookup),transform:h(null==e?void 0:e.transform)}})}:void 0,c=!1!==globalThis.__DEV__?u:void 0;function u(){return{cache:{fragmentQueryDocuments:h(this.getFragmentDoc)}}}function h(e){return function(e){return!!e&&"dirtyKey"in e}(e)?e.size:void 0}function d(e){return null!=e}function p(e){return g(e).map(function(e){return{cache:e}})}function g(e){return e?(0,r.__spreadArray)((0,r.__spreadArray)([h(null==e?void 0:e.performWork)],g(null==e?void 0:e.left),!0),g(null==e?void 0:e.right),!0).filter(d):[]}function f(e){var t;return e?(0,r.__spreadArray)((0,r.__spreadArray)([null===(t=null==e?void 0:e.getMemoryInternals)||void 0===t?void 0:t.call(e)],f(null==e?void 0:e.left),!0),f(null==e?void 0:e.right),!0).filter(d):[]}},19360(e,t,i){"use strict";i.d(t,{v:()=>o});var r=i(65959),n=i(131),s=Symbol.for("apollo.cacheSize"),o=(0,r.__assign)({},n.Sf[s])},79e3(e,t,i){"use strict";i.d(t,{E:()=>n,c:()=>r});var r=Array.isArray;function n(e){return Array.isArray(e)&&e.length>0}},97703(e,t,i){"use strict";i.d(t,{En:()=>o,JR:()=>h,Sw:()=>c,et:()=>s,ol:()=>a,uJ:()=>l});var r=i(131),n="ReactNative"==(0,r.no)(function(){return navigator.product}),s="function"==typeof WeakMap&&!(n&&!globalThis.HermesInternal),o="function"==typeof WeakSet,a="function"==typeof Symbol&&"function"==typeof Symbol.for,l=a&&Symbol.asyncIterator,c="function"==typeof(0,r.no)(function(){return window.document.createElement}),u=(0,r.no)(function(){return navigator.userAgent.indexOf("jsdom")>=0})||!1,h=(c||n)&&!u},26497(e,t,i){"use strict";i.d(t,{M:()=>a});var r,n=i(75859),s=i(19360),o=i(27231),a=Object.assign(function(e){return JSON.stringify(e,l)},{reset:function(){r=new n.V(s.v.canonicalStringify||1e3)}});function l(e,t){if(t&&"object"==typeof t){var i=Object.getPrototypeOf(t);if(i===Object.prototype||null===i){var n=Object.keys(t);if(n.every(c))return t;var s=JSON.stringify(n),o=r.get(s);if(!o){n.sort();var a=JSON.stringify(n);o=r.get(a)||n,r.set(s,o),r.set(a,o)}var l=Object.create(i);return o.forEach(function(e){l[e]=t[e]}),l}}return t}function c(e,t,i){return 0===t||i[t-1]<=e}!1!==globalThis.__DEV__&&(0,o.D_)("canonicalStringify",function(){return r.size}),a.reset()},37563(e,t,i){"use strict";i.d(t,{m:()=>n});var r=Object.prototype.toString;function n(e){return s(e)}function s(e,t){switch(r.call(e)){case"[object Array]":if((t=t||new Map).has(e))return t.get(e);var i=e.slice(0);return t.set(e,i),i.forEach(function(e,r){i[r]=s(e,t)}),i;case"[object Object]":if((t=t||new Map).has(e))return t.get(e);var n=Object.create(Object.getPrototypeOf(e));return t.set(e,n),Object.keys(e).forEach(function(i){n[i]=s(e[i],t)}),n;default:return e}}},58173(e,t,i){"use strict";function r(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var i=Object.create(null);return e.forEach(function(e){e&&Object.keys(e).forEach(function(t){var r=e[t];void 0!==r&&(i[t]=r)})}),i}i.d(t,{o:()=>r})},28931(e,t,i){"use strict";i.d(t,{M:()=>o,t:()=>s});var r=i(79e3),n=i(94537);function s(e){var t=o(e);return(0,r.E)(t)}function o(e){var t=(0,r.E)(e.errors)?e.errors.slice(0):[];return(0,n.ST)(e)&&(0,r.E)(e.incremental)&&e.incremental.forEach(function(e){e.errors&&t.push.apply(t,e.errors)}),t}},94537(e,t,i){"use strict";i.d(t,{EQ:()=>a,Nw:()=>c,ST:()=>o,YX:()=>l,bd:()=>u});var r=i(1164),n=i(79e3),s=i(45902);function o(e){return"incremental"in e}function a(e){return"hasNext"in e&&"data"in e}function l(e){return o(e)||a(e)}function c(e){return(0,r.U)(e)&&"payload"in e}function u(e,t){var i=e,r=new s.ZI;return o(t)&&(0,n.E)(t.incremental)&&t.incremental.forEach(function(e){for(var t=e.data,n=e.path,s=n.length-1;s>=0;--s){var o=n[s],a=isNaN(+o)?{}:[];a[o]=t,t=a}i=r.merge(i,t)}),i}},66566(e,t,i){"use strict";i.d(t,{v:()=>n});var r=new Map;function n(e){var t=r.get(e)||1;return r.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}},12209(e,t,i){"use strict";i.d(t,{G:()=>n});var r=i(1164);function n(e){return!1!==globalThis.__DEV__&&(t=e,(i=new Set([t])).forEach(function(e){(0,r.U)(e)&&function(e){if(!1!==globalThis.__DEV__&&!Object.isFrozen(e))try{Object.freeze(e)}catch(e){if(e instanceof TypeError)return null;throw e}return e}(e)===e&&Object.getOwnPropertyNames(e).forEach(function(t){(0,r.U)(e[t])&&i.add(e[t])})})),e;var t,i}},45902(e,t,i){"use strict";i.d(t,{D9:()=>o,IM:()=>a,ZI:()=>c});var r=i(65959),n=i(1164),s=Object.prototype.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return a(e)}function a(e){var t=e[0]||{},i=e.length;if(i>1)for(var r=new c,n=1;n<i;++n)t=r.merge(t,e[n]);return t}var l=function(e,t,i){return this.merge(e[i],t[i])},c=function(){function e(e){void 0===e&&(e=l),this.reconciler=e,this.isObject=n.U,this.pastCopies=new Set}return e.prototype.merge=function(e,t){for(var i=this,o=[],a=2;a<arguments.length;a++)o[a-2]=arguments[a];return(0,n.U)(t)&&(0,n.U)(e)?(Object.keys(t).forEach(function(n){if(s.call(e,n)){var a=e[n];if(t[n]!==a){var l=i.reconciler.apply(i,(0,r.__spreadArray)([e,t,n],o,!1));l!==a&&((e=i.shallowCopyForMerge(e))[n]=l)}}else(e=i.shallowCopyForMerge(e))[n]=t[n]}),e):t},e.prototype.shallowCopyForMerge=function(e){return(0,n.U)(e)&&(this.pastCopies.has(e)||(e=Array.isArray(e)?e.slice(0):(0,r.__assign)({__proto__:Object.getPrototypeOf(e)},e),this.pastCopies.add(e))),e},e}()},97460(e,t,i){"use strict";i.d(t,{l:()=>s});var r=i(65959),n=i(58173);function s(e,t){return(0,n.o)(e,t,t.variables&&{variables:(0,n.o)((0,r.__assign)((0,r.__assign)({},e&&e.variables),t.variables))})}},1164(e,t,i){"use strict";function r(e){return null!==e&&"object"==typeof e}function n(e){return null!==e&&"object"==typeof e&&(Object.getPrototypeOf(e)===Object.prototype||null===Object.getPrototypeOf(e))}i.d(t,{Q:()=>n,U:()=>r})},48670(e,t,i){"use strict";i.d(t,{p:()=>n});var r=i(66566);function n(e,t){void 0===t&&(t=0);var i=(0,r.v)("stringifyForDisplay");return JSON.stringify(e,function(e,t){return void 0===t?i:t},t).split(JSON.stringify(i)).join("<undefined>")}},30301(e,t,i){"use strict";i.d(t,{S2:()=>h,cc:()=>u,lz:()=>c});var r=i(65959),n=i(81987),s=i(131),o=Symbol.for("apollo.deprecations"),a=s.Sf,l=new n.DX;function c(e){for(var t=[],i=1;i<arguments.length;i++)t[i-1]=arguments[i];return l.withValue.apply(l,(0,r.__spreadArray)([Array.isArray(e)?e:[e]],t,!1))}function u(e,t,i,r){void 0===r&&(r="Please remove this option."),h(t,function(){t in e&&!1!==globalThis.__DEV__&&s.V1.warn(104,i,t,r)})}function h(e,t){(function(e){return a[o]||(l.getValue()||[]).includes(e)})(e)||t()}},18084(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(86483);const n=(0,r.n)(function(){return globalThis})||(0,r.n)(function(){return window})||(0,r.n)(function(){return self})||(0,r.n)(function(){return globalThis})||(0,r.n)(function(){return r.n.constructor("return this")()})},131(e,t,i){"use strict";i.d(t,{IJ:()=>o,Sf:()=>s.A,V1:()=>r.V1,no:()=>n.n,vA:()=>r.vA});var r=i(27119),n=i(86483),s=i(18084),o=!1!==globalThis.__DEV__},27119(e,t,i){"use strict";i.d(t,{V1:()=>l,vA:()=>c});var r=i(92981),n=i(29527),s=i(18084),o=i(48670);function a(e){return function(t){for(var i=[],r=1;r<arguments.length;r++)i[r-1]=arguments[r];if("number"==typeof t){var n=t;(t=d(n))||(t=p(n,i),i=[])}e.apply(void 0,[t].concat(i))}}var l=Object.assign(function(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];e||(0,r.V1)(e,d(t,i)||p(t,i))},{debug:a(r.V1.debug),log:a(r.V1.log),warn:a(r.V1.warn),error:a(r.V1.error)});function c(e){for(var t=[],i=1;i<arguments.length;i++)t[i-1]=arguments[i];return new r.zU(d(e,t)||p(e,t))}var u=Symbol.for("ApolloErrorMessageHandler_"+n.r);function h(e){if("string"==typeof e)return e;try{return(0,o.p)(e,2).slice(0,1e3)}catch(e){return"<non-serializable>"}}function d(e,t){if(void 0===t&&(t=[]),e)return s.A[u]&&s.A[u](e,t.map(h))}function p(e,t){if(void 0===t&&(t=[]),e)return"An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({version:n.r,message:e,args:t.map(h)})))}},86483(e,t,i){"use strict";function r(e){try{return e()}catch(e){}}i.d(t,{n:()=>r})},78917(e,t,i){"use strict";i.d(t,{c:()=>h});var r=i(69796),n=i(97703),s=i(47812),o=i(131),a=i(78027),l=i(81987),c=i(19360);function u(e){return e}var h=function(){function e(e,t){void 0===t&&(t=Object.create(null)),this.resultCache=n.En?new WeakSet:new Set,this.transform=e,t.getCacheKey&&(this.getCacheKey=t.getCacheKey),this.cached=!1!==t.cache,this.resetCache()}return e.prototype.getCacheKey=function(e){return[e]},e.identity=function(){return new e(u,{cache:!1})},e.split=function(t,i,r){return void 0===r&&(r=e.identity()),Object.assign(new e(function(e){return(t(e)?i:r).transformDocument(e)},{cache:!1}),{left:i,right:r})},e.prototype.resetCache=function(){var t=this;if(this.cached){var i=new r.b(n.et);this.performWork=(0,l.LV)(e.prototype.performWork.bind(this),{makeCacheKey:function(e){var r=t.getCacheKey(e);if(r)return(0,o.V1)(Array.isArray(r),105),i.lookupArray(r)},max:c.v["documentTransform.cache"],cache:a.l})}},e.prototype.performWork=function(e){return(0,s.sw)(e),this.transform(e)},e.prototype.transformDocument=function(e){if(this.resultCache.has(e))return e;var t=this.performWork(e);return this.resultCache.add(t),t},e.prototype.concat=function(t){var i=this;return Object.assign(new e(function(e){return t.transformDocument(i.transformDocument(e))},{cache:!1}),{left:this,right:t})},e}()},14270(e,t,i){"use strict";i.d(t,{I5:()=>c,MS:()=>o,d8:()=>u,f2:()=>h,hE:()=>l,s7:()=>p,sx:()=>a,tY:()=>d});var r=i(131),n=i(49270),s=i(85517);function o(e,t){var i=e.directives;return!i||!i.length||d(i).every(function(e){var i=e.directive,n=e.ifArgument,s=!1;return"Variable"===n.value.kind?(s=t&&t[n.value.name.value],(0,r.V1)(void 0!==s,106,i.name.value)):s=n.value.value,"skip"===i.name.value?!s:s})}function a(e){var t=[];return(0,s.YR)(e,{Directive:function(e){t.push(e.name.value)}}),t}var l=function(e,t){return u(e,t,!1)},c=function(e,t){return u(e,t,!0)};function u(e,t,i){var r=new Set(e),n=r.size;return(0,s.YR)(t,{Directive:function(e){if(r.delete(e.name.value)&&(!i||!r.size))return s.sP}}),i?!r.size:r.size<n}function h(e){return e&&u(["client","export"],e,!0)}function d(e){var t=[];return e&&e.length&&e.forEach(function(e){if("skip"===(i=e.name.value)||"include"===i){var i,n=e.arguments,s=e.name.value;(0,r.V1)(n&&1===n.length,107,s);var o=n[0];(0,r.V1)(o.name&&"if"===o.name.value,108,s);var a=o.value;(0,r.V1)(a&&("Variable"===a.kind||"BooleanValue"===a.kind),109,s),t.push({directive:e,ifArgument:o})}}),t}function p(e){var t,i,s=null===(t=e.directives)||void 0===t?void 0:t.find(function(e){return"unmask"===e.name.value});if(!s)return"mask";var o=null===(i=s.arguments)||void 0===i?void 0:i.find(function(e){return"mode"===e.name.value});return!1!==globalThis.__DEV__&&o&&(o.value.kind===n.b.VARIABLE?!1!==globalThis.__DEV__&&r.V1.warn(110):o.value.kind!==n.b.STRING?!1!==globalThis.__DEV__&&r.V1.warn(111):"migrate"!==o.value.value&&!1!==globalThis.__DEV__&&r.V1.warn(112,o.value.value)),o&&"value"in o.value&&"migrate"===o.value.value?"migrate":"unmask"}},48555(e,t,i){"use strict";i.d(t,{HQ:()=>l,JG:()=>a,ct:()=>o,s6:()=>c});var r=i(65959),n=i(131),s=i(85517);function o(e,t){var i=t,s=[];return e.definitions.forEach(function(e){if("OperationDefinition"===e.kind)throw(0,n.vA)(113,e.operation,e.name?" named '".concat(e.name.value,"'"):"");"FragmentDefinition"===e.kind&&s.push(e)}),void 0===i&&((0,n.V1)(1===s.length,114,s.length),i=s[0].name.value),(0,r.__assign)((0,r.__assign)({},e),{definitions:(0,r.__spreadArray)([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:i}}]}}],e.definitions,!0)})}function a(e){void 0===e&&(e=[]);var t={};return e.forEach(function(e){t[e.name.value]=e}),t}function l(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":var i=e.name.value;if("function"==typeof t)return t(i);var r=t&&t[i];return(0,n.V1)(r,115,i),r||null;default:return null}}function c(e){var t=!0;return(0,s.YR)(e,{FragmentSpread:function(e){if(!(t=!!e.directives&&e.directives.some(function(e){return"unmask"===e.name.value})))return s.sP}}),t}},47812(e,t,i){"use strict";i.d(t,{AT:()=>c,E4:()=>u,Vn:()=>h,Vu:()=>o,n4:()=>a,sw:()=>s,wY:()=>d,zK:()=>l});var r=i(131),n=i(99310);function s(e){(0,r.V1)(e&&"Document"===e.kind,116);var t=e.definitions.filter(function(e){return"FragmentDefinition"!==e.kind}).map(function(e){if("OperationDefinition"!==e.kind)throw(0,r.vA)(117,e.kind);return e});return(0,r.V1)(t.length<=1,118,t.length),e}function o(e){return s(e),e.definitions.filter(function(e){return"OperationDefinition"===e.kind})[0]}function a(e){return e.definitions.filter(function(e){return"OperationDefinition"===e.kind&&!!e.name}).map(function(e){return e.name.value})[0]||null}function l(e){return e.definitions.filter(function(e){return"FragmentDefinition"===e.kind})}function c(e){var t=o(e);return(0,r.V1)(t&&"query"===t.operation,119),t}function u(e){(0,r.V1)("Document"===e.kind,120),(0,r.V1)(e.definitions.length<=1,121);var t=e.definitions[0];return(0,r.V1)("FragmentDefinition"===t.kind,122),t}function h(e){var t;s(e);for(var i=0,n=e.definitions;i<n.length;i++){var o=n[i];if("OperationDefinition"===o.kind){var a=o.operation;if("query"===a||"mutation"===a||"subscription"===a)return o}"FragmentDefinition"!==o.kind||t||(t=o)}if(t)return t;throw(0,r.vA)(123)}function d(e){var t=Object.create(null),i=e&&e.variableDefinitions;return i&&i.length&&i.forEach(function(e){e.defaultValue&&(0,n.J)(t,e.variable.name,e.defaultValue)}),t}},33137(e,t,i){"use strict";i.d(t,{y:()=>l});var r,n=i(74831),s=i(75859),o=i(19360),a=i(27231),l=Object.assign(function(e){var t=r.get(e);return t||(t=(0,n.y)(e),r.set(e,t)),t},{reset:function(){r=new s.A(o.v.print||2e3)}});l.reset(),!1!==globalThis.__DEV__&&(0,a.D_)("print",function(){return r?r.size:0})},99310(e,t,i){"use strict";i.d(t,{A_:()=>l,D$:()=>v,Ii:()=>h,J:()=>u,Kc:()=>c,MB:()=>f,WU:()=>a,dt:()=>C,kd:()=>y,o5:()=>g,ue:()=>m});var r=i(131),n=i(1164),s=i(48555),o=i(26497);function a(e){return{__ref:String(e)}}function l(e){return Boolean(e&&"object"==typeof e&&"string"==typeof e.__ref)}function c(e){return(0,n.U)(e)&&"Document"===e.kind&&Array.isArray(e.definitions)}function u(e,t,i,n){if(function(e){return"IntValue"===e.kind}(i)||function(e){return"FloatValue"===e.kind}(i))e[t.value]=Number(i.value);else if(function(e){return"BooleanValue"===e.kind}(i)||function(e){return"StringValue"===e.kind}(i))e[t.value]=i.value;else if(function(e){return"ObjectValue"===e.kind}(i)){var s={};i.fields.map(function(e){return u(s,e.name,e.value,n)}),e[t.value]=s}else if(function(e){return"Variable"===e.kind}(i)){var o=(n||{})[i.name.value];e[t.value]=o}else if(function(e){return"ListValue"===e.kind}(i))e[t.value]=i.values.map(function(e){var i={};return u(i,t,e,n),i[t.value]});else if(function(e){return"EnumValue"===e.kind}(i))e[t.value]=i.value;else{if(!function(e){return"NullValue"===e.kind}(i))throw(0,r.vA)(124,t.value,i.kind);e[t.value]=null}}function h(e,t){var i=null;e.directives&&(i={},e.directives.forEach(function(e){i[e.name.value]={},e.arguments&&e.arguments.forEach(function(r){var n=r.name,s=r.value;return u(i[e.name.value],n,s,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(e){var i=e.name,n=e.value;return u(r,i,n,t)})),g(e.name.value,r,i)}var d=["connection","include","skip","client","rest","export","nonreactive"],p=o.M,g=Object.assign(function(e,t,i){if(t&&i&&i.connection&&i.connection.key){if(i.connection.filter&&i.connection.filter.length>0){var r=i.connection.filter?i.connection.filter:[];r.sort();var n={};return r.forEach(function(e){n[e]=t[e]}),"".concat(i.connection.key,"(").concat(p(n),")")}return i.connection.key}var s=e;if(t){var o=p(t);s+="(".concat(o,")")}return i&&Object.keys(i).forEach(function(e){-1===d.indexOf(e)&&(i[e]&&Object.keys(i[e]).length?s+="@".concat(e,"(").concat(p(i[e]),")"):s+="@".concat(e))}),s},{setStringify:function(e){var t=p;return p=e,t}});function f(e,t){if(e.arguments&&e.arguments.length){var i={};return e.arguments.forEach(function(e){var r=e.name,n=e.value;return u(i,r,n,t)}),i}return null}function m(e){return e.alias?e.alias.value:e.name.value}function v(e,t,i){for(var r,n=0,o=t.selections;n<o.length;n++)if(C(c=o[n])){if("__typename"===c.name.value)return e[m(c)]}else r?r.push(c):r=[c];if("string"==typeof e.__typename)return e.__typename;if(r)for(var a=0,l=r;a<l.length;a++){var c=l[a],u=v(e,(0,s.HQ)(c,i).selectionSet,i);if("string"==typeof u)return u}}function C(e){return"Field"===e.kind}function y(e){return"InlineFragment"===e.kind}},83906(e,t,i){"use strict";i.d(t,{TC:()=>w,XY:()=>m,er:()=>b,hX:()=>C,it:()=>y,iz:()=>f,x3:()=>E,zc:()=>S});var r=i(65959),n=i(131),s=i(49270),o=i(85517),a=i(47812),l=i(99310),c=i(48555),u=i(79e3),h={kind:s.b.FIELD,name:{kind:s.b.NAME,value:"__typename"}};function d(e,t){return!e||e.selectionSet.selections.every(function(e){return e.kind===s.b.FRAGMENT_SPREAD&&d(t[e.name.value],t)})}function p(e){return d((0,a.Vu)(e)||(0,a.E4)(e),(0,c.JG)((0,a.zK)(e)))?null:e}function g(e){var t=new Map;return function(i){void 0===i&&(i=e);var r=t.get(i);return r||t.set(i,r={variables:new Set,fragmentSpreads:new Set}),r}}function f(e,t){(0,a.sw)(t);for(var i=g(""),l=g(""),c=function(e){for(var t=0,r=void 0;t<e.length&&(r=e[t]);++t)if(!(0,u.c)(r)){if(r.kind===s.b.OPERATION_DEFINITION)return i(r.name&&r.name.value);if(r.kind===s.b.FRAGMENT_DEFINITION)return l(r.name.value)}return!1!==globalThis.__DEV__&&n.V1.error(125),null},h=0,d=t.definitions.length-1;d>=0;--d)t.definitions[d].kind===s.b.OPERATION_DEFINITION&&++h;var f,m,v,C=(f=e,m=new Map,v=new Map,f.forEach(function(e){e&&(e.name?m.set(e.name,e):e.test&&v.set(e.test,e))}),function(e){var t=m.get(e.name.value);return!t&&v.size&&v.forEach(function(i,r){r(e)&&(t=i)}),t}),y=function(e){return(0,u.E)(e)&&e.map(C).some(function(e){return e&&e.remove})},w=new Map,S=!1,b={enter:function(e){if(y(e.directives))return S=!0,null}},E=(0,o.YR)(t,{Field:b,InlineFragment:b,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(e,t,i,r,n){var s=c(n);s&&s.variables.add(e.name.value)}},FragmentSpread:{enter:function(e,t,i,r,n){if(y(e.directives))return S=!0,null;var s=c(n);s&&s.fragmentSpreads.add(e.name.value)}},FragmentDefinition:{enter:function(e,t,i,r){w.set(JSON.stringify(r),e)},leave:function(e,t,i,r){return e===w.get(JSON.stringify(r))?e:h>0&&e.selectionSet.selections.every(function(e){return e.kind===s.b.FIELD&&"__typename"===e.name.value})?(l(e.name.value).removed=!0,S=!0,null):void 0}},Directive:{leave:function(e){if(C(e))return S=!0,null}}});if(!S)return t;var A=function(e){return e.transitiveVars||(e.transitiveVars=new Set(e.variables),e.removed||e.fragmentSpreads.forEach(function(t){A(l(t)).transitiveVars.forEach(function(t){e.transitiveVars.add(t)})})),e},T=new Set;E.definitions.forEach(function(e){e.kind===s.b.OPERATION_DEFINITION?A(i(e.name&&e.name.value)).fragmentSpreads.forEach(function(e){T.add(e)}):e.kind!==s.b.FRAGMENT_DEFINITION||0!==h||l(e.name.value).removed||T.add(e.name.value)}),T.forEach(function(e){A(l(e)).fragmentSpreads.forEach(function(e){T.add(e)})});var M={enter:function(e){if(t=e.name.value,!T.has(t)||l(t).removed)return null;var t}};return p((0,o.YR)(E,{FragmentSpread:M,FragmentDefinition:M,OperationDefinition:{leave:function(e){if(e.variableDefinitions){var t=A(i(e.name&&e.name.value)).transitiveVars;if(t.size<e.variableDefinitions.length)return(0,r.__assign)((0,r.__assign)({},e),{variableDefinitions:e.variableDefinitions.filter(function(e){return t.has(e.variable.name.value)})})}}}}))}var m=Object.assign(function(e){return(0,o.YR)(e,{SelectionSet:{enter:function(e,t,i){if(!i||i.kind!==s.b.OPERATION_DEFINITION){var n=e.selections;if(n&&!n.some(function(e){return(0,l.dt)(e)&&("__typename"===e.name.value||0===e.name.value.lastIndexOf("__",0))})){var o=i;if(!((0,l.dt)(o)&&o.directives&&o.directives.some(function(e){return"export"===e.name.value})))return(0,r.__assign)((0,r.__assign)({},e),{selections:(0,r.__spreadArray)((0,r.__spreadArray)([],n,!0),[h],!1)})}}}}})},{added:function(e){return e===h}}),v={test:function(e){var t="connection"===e.name.value;return t&&(e.arguments&&e.arguments.some(function(e){return"key"===e.name.value})||!1!==globalThis.__DEV__&&n.V1.warn(126)),t}};function C(e){return f([v],(0,a.sw)(e))}function y(e,t){var i=function(e){return function(t){return e.some(function(e){return t.value&&t.value.kind===s.b.VARIABLE&&t.value.name&&(e.name===t.value.name.value||e.test&&e.test(t))})}}(e);return p((0,o.YR)(t,{OperationDefinition:{enter:function(t){return(0,r.__assign)((0,r.__assign)({},t),{variableDefinitions:t.variableDefinitions?t.variableDefinitions.filter(function(t){return!e.some(function(e){return e.name===t.variable.name.value})}):[]})}},Field:{enter:function(t){if(e.some(function(e){return e.remove})){var r=0;if(t.arguments&&t.arguments.forEach(function(e){i(e)&&(r+=1)}),1===r)return null}}},Argument:{enter:function(e){if(i(e))return null}}}))}function w(e,t){function i(t){if(e.some(function(e){return e.name===t.name.value}))return null}return p((0,o.YR)(t,{FragmentSpread:{enter:i},FragmentDefinition:{enter:i}}))}function S(e){return"query"===(0,a.Vn)(e).operation?e:(0,o.YR)(e,{OperationDefinition:{enter:function(e){return(0,r.__assign)((0,r.__assign)({},e),{operation:"query"})}}})}function b(e){return(0,a.sw)(e),f([{test:function(e){return"client"===e.name.value},remove:!0}],e)}function E(e){return(0,a.sw)(e),(0,o.YR)(e,{FragmentSpread:function(e){var t;if(!(null===(t=e.directives)||void 0===t?void 0:t.some(function(e){return"unmask"===e.name.value})))return(0,r.__assign)((0,r.__assign)({},e),{directives:(0,r.__spreadArray)((0,r.__spreadArray)([],e.directives||[],!0),[{kind:s.b.DIRECTIVE,name:{kind:s.b.NAME,value:"nonreactive"}}],!1)})}})}},89444(e,t,i){"use strict";i.r(t),i.d(t,{AutoCleanedStrongCache:()=>$.V,AutoCleanedWeakCache:()=>$.A,Concast:()=>I.E,DEV:()=>r.IJ,DeepMerger:()=>m.ZI,DocumentTransform:()=>s.c,Observable:()=>b.c,addNonReactiveToNamedFragments:()=>u.x3,addTypenameToDocument:()=>u.XY,argumentsObjectFromField:()=>c.MB,asyncMap:()=>D.x,buildQueryFromSelectionSet:()=>u.zc,cacheSizes:()=>q.v,canUseAsyncIteratorSymbol:()=>k.uJ,canUseDOM:()=>k.Sw,canUseLayoutEffect:()=>k.JR,canUseSymbol:()=>k.ol,canUseWeakMap:()=>k.et,canUseWeakSet:()=>k.En,canonicalStringify:()=>U.M,checkDocument:()=>a.sw,cloneDeep:()=>_.m,compact:()=>G.o,concatPagination:()=>v,createFragmentMap:()=>o.JG,createFulfilledPromise:()=>E,createRejectedPromise:()=>A,fixObservableSubclass:()=>L.r,getDefaultValues:()=>a.wY,getDirectiveNames:()=>n.sx,getFragmentDefinition:()=>a.E4,getFragmentDefinitions:()=>a.zK,getFragmentFromSelection:()=>o.HQ,getFragmentMaskMode:()=>n.s7,getFragmentQueryDocument:()=>o.ct,getGraphQLErrorsFromResult:()=>F.M,getInclusionDirectives:()=>n.tY,getMainDefinition:()=>a.Vn,getOperationDefinition:()=>a.Vu,getOperationName:()=>a.n4,getQueryDefinition:()=>a.AT,getStoreKeyName:()=>c.o5,getTypenameFromResult:()=>c.D$,graphQLResultHasError:()=>F.t,hasAllDirectives:()=>n.I5,hasAnyDirectives:()=>n.hE,hasClientExports:()=>n.f2,hasDirectives:()=>n.d8,isApolloPayloadResult:()=>z.Nw,isArray:()=>N.c,isDocumentNode:()=>c.Kc,isExecutionPatchIncrementalResult:()=>z.ST,isExecutionPatchInitialResult:()=>z.EQ,isExecutionPatchResult:()=>z.YX,isField:()=>c.dt,isFullyUnmaskedOperation:()=>o.s6,isInlineFragment:()=>c.kd,isMutationOperation:()=>d,isNonEmptyArray:()=>N.E,isNonNullObject:()=>O.U,isPlainObject:()=>O.Q,isQueryOperation:()=>p,isReference:()=>c.A_,isStatefulPromise:()=>T,isSubscriptionOperation:()=>g,iterateObserversSafely:()=>x.w,makeReference:()=>c.WU,makeUniqueId:()=>V.v,maybe:()=>r.no,maybeDeepFreeze:()=>P.G,mergeDeep:()=>m.D9,mergeDeepArray:()=>m.IM,mergeIncrementalData:()=>z.bd,mergeOptions:()=>B.l,offsetLimitPagination:()=>C,omitDeep:()=>W,preventUnhandledRejection:()=>R.X,print:()=>l.y,relayStylePagination:()=>y,removeArgumentsFromDocument:()=>u.it,removeClientSetsFromDocument:()=>u.er,removeConnectionDirectiveFromDocument:()=>u.hX,removeDirectivesFromDocument:()=>u.iz,removeFragmentSpreadFromDocument:()=>u.TC,resultKeyNameFromField:()=>c.ue,shouldInclude:()=>n.MS,storeKeyNameFromField:()=>c.Ii,stringifyForDisplay:()=>H.p,stripTypename:()=>K,valueToObjectRepresentation:()=>c.J,wrapPromiseWithState:()=>M});var r=i(131),n=i(14270),s=i(78917),o=i(48555),a=i(47812),l=i(33137),c=i(99310),u=i(83906);function h(e,t){var i;return(null===(i=(0,a.Vu)(e))||void 0===i?void 0:i.operation)===t}function d(e){return h(e,"mutation")}function p(e){return h(e,"query")}function g(e){return h(e,"subscription")}var f=i(65959),m=i(45902);function v(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t){return e?(0,f.__spreadArray)((0,f.__spreadArray)([],e,!0),t,!0):t}}}function C(e){return void 0===e&&(e=!1),{keyArgs:e,merge:function(e,t,i){var r=i.args,n=e?e.slice(0):[];if(t)if(r)for(var s=r.offset,o=void 0===s?0:s,a=0;a<t.length;++a)n[o+a]=t[a];else n.push.apply(n,t);return n}}}function y(e){return void 0===e&&(e=!1),{keyArgs:e,read:function(e,t){var i=t.canRead,r=t.readField;if(!e)return e;var n=[],s="",o="";e.edges.forEach(function(e){i(r("node",e))&&(n.push(e),e.cursor&&(s=s||e.cursor||"",o=e.cursor||o))}),n.length>1&&s===o&&(s="");var a=e.pageInfo||{},l=a.startCursor,c=a.endCursor;return(0,f.__assign)((0,f.__assign)({},w(e)),{edges:n,pageInfo:(0,f.__assign)((0,f.__assign)({},e.pageInfo),{startCursor:l||s,endCursor:c||o})})},merge:function(e,t,i){var r=i.args,n=i.isReference,s=i.readField;if(e||(e={edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:"",endCursor:""}}),!t)return e;var o=t.edges?t.edges.map(function(e){return n(e=(0,f.__assign)({},e))&&(e.cursor=s("cursor",e)),e}):[];if(t.pageInfo){var a=t.pageInfo,l=a.startCursor,c=a.endCursor,u=o[0],h=o[o.length-1];u&&l&&(u.cursor=l),h&&c&&(h.cursor=c);var d=u&&u.cursor;d&&!l&&(t=(0,m.D9)(t,{pageInfo:{startCursor:d}}));var p=h&&h.cursor;p&&!c&&(t=(0,m.D9)(t,{pageInfo:{endCursor:p}}))}var g=e.edges,v=[];if(r&&r.after)(C=g.findIndex(function(e){return e.cursor===r.after}))>=0&&(g=g.slice(0,C+1));else if(r&&r.before){var C;v=(C=g.findIndex(function(e){return e.cursor===r.before}))<0?g:g.slice(C),g=[]}else t.edges&&(g=[]);var y=(0,f.__spreadArray)((0,f.__spreadArray)((0,f.__spreadArray)([],g,!0),o,!0),v,!0),S=(0,f.__assign)((0,f.__assign)({},t.pageInfo),e.pageInfo);if(t.pageInfo){var b=t.pageInfo,E=b.hasPreviousPage,A=b.hasNextPage,T=(l=b.startCursor,c=b.endCursor,(0,f.__rest)(b,["hasPreviousPage","hasNextPage","startCursor","endCursor"]));Object.assign(S,T),g.length||(void 0!==E&&(S.hasPreviousPage=E),void 0!==l&&(S.startCursor=l)),v.length||(void 0!==A&&(S.hasNextPage=A),void 0!==c&&(S.endCursor=c))}return(0,f.__assign)((0,f.__assign)((0,f.__assign)({},w(e)),w(t)),{edges:y,pageInfo:S})}}}var w=function(e){return(0,f.__rest)(e,S)},S=["edges","pageInfo"],b=i(74140);function E(e){var t=Promise.resolve(e);return t.status="fulfilled",t.value=e,t}function A(e){var t=Promise.reject(e);return t.catch(function(){}),t.status="rejected",t.reason=e,t}function T(e){return"status"in e}function M(e){if(T(e))return e;var t=e;return t.status="pending",t.then(function(e){if("pending"===t.status){var i=t;i.status="fulfilled",i.value=e}},function(e){if("pending"===t.status){var i=t;i.status="rejected",i.reason=e}}),e}var R=i(90767),_=i(37563),P=i(12209),x=i(20658),D=i(34471),I=i(84382),L=i(24783),N=i(79e3),O=i(1164),F=i(28931),k=i(97703),G=i(58173),V=i(66566),H=i(48670),B=i(97460),z=i(94537),U=i(26497);function W(e,t){return j(e,t)}function j(e,t,i){if(void 0===i&&(i=new Map),i.has(e))return i.get(e);var r=!1;if(Array.isArray(e)){var n=[];if(i.set(e,n),e.forEach(function(e,s){var o=j(e,t,i);r||(r=o!==e),n[s]=o}),r)return n}else if((0,O.Q)(e)){var s=Object.create(Object.getPrototypeOf(e));if(i.set(e,s),Object.keys(e).forEach(function(n){if(n!==t){var o=j(e[n],t,i);r||(r=o!==e[n]),s[n]=o}else r=!0}),r)return s}return e}function K(e){return W(e,"__typename")}var $=i(75859),q=i(19360)},84382(e,t,i){"use strict";i.d(t,{E:()=>l});var r=i(65959),n=i(74140),s=i(20658),o=i(24783);function a(e){return e&&"function"==typeof e.then}var l=function(e){function t(t){var i=e.call(this,function(e){return i.addObserver(e),function(){return i.removeObserver(e)}})||this;return i.observers=new Set,i.promise=new Promise(function(e,t){i.resolve=e,i.reject=t}),i.handlers={next:function(e){null!==i.sub&&(i.latest=["next",e],i.notify("next",e),(0,s.w)(i.observers,"next",e))},error:function(e){var t=i.sub;null!==t&&(t&&setTimeout(function(){return t.unsubscribe()}),i.sub=null,i.latest=["error",e],i.reject(e),i.notify("error",e),(0,s.w)(i.observers,"error",e))},complete:function(){var e=i,t=e.sub,r=e.sources;if(null!==t){var n=(void 0===r?[]:r).shift();n?a(n)?n.then(function(e){return i.sub=e.subscribe(i.handlers)},i.handlers.error):i.sub=n.subscribe(i.handlers):(t&&setTimeout(function(){return t.unsubscribe()}),i.sub=null,i.latest&&"next"===i.latest[0]?i.resolve(i.latest[1]):i.resolve(),i.notify("complete"),(0,s.w)(i.observers,"complete"))}}},i.nextResultListeners=new Set,i.cancel=function(e){i.reject(e),i.sources=[],i.handlers.error(e)},i.promise.catch(function(e){}),"function"==typeof t&&(t=[new n.c(t)]),a(t)?t.then(function(e){return i.start(e)},i.handlers.error):i.start(t),i}return(0,r.__extends)(t,e),t.prototype.start=function(e){void 0===this.sub&&(this.sources=Array.from(e),this.handlers.complete())},t.prototype.deliverLastMessage=function(e){if(this.latest){var t=this.latest[0],i=e[t];i&&i.call(e,this.latest[1]),null===this.sub&&"next"===t&&e.complete&&e.complete()}},t.prototype.addObserver=function(e){this.observers.has(e)||(this.deliverLastMessage(e),this.observers.add(e))},t.prototype.removeObserver=function(e){this.observers.delete(e)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(e,t){var i=this.nextResultListeners;i.size&&(this.nextResultListeners=new Set,i.forEach(function(i){return i(e,t)}))},t.prototype.beforeNext=function(e){var t=!1;this.nextResultListeners.add(function(i,r){t||(t=!0,e(i,r))})},t}(n.c);(0,o.r)(l)},34471(e,t,i){"use strict";i.d(t,{x:()=>n});var r=i(74140);function n(e,t,i){return new r.c(function(r){var n={then:function(e){return new Promise(function(t){return t(e())})}};function s(e,t){return function(i){if(e){var s=function(){return r.closed?0:e(i)};n=n.then(s,s).then(function(e){return r.next(e)},function(e){return r.error(e)})}else r[t](i)}}var o={next:s(t,"next"),error:s(i,"error"),complete:function(){n.then(function(){return r.complete()})}},a=e.subscribe(o);return function(){return a.unsubscribe()}})}},20658(e,t,i){"use strict";function r(e,t,i){var r=[];e.forEach(function(e){return e[t]&&r.push(e)}),r.forEach(function(e){return e[t](i)})}i.d(t,{w:()=>r})},24783(e,t,i){"use strict";i.d(t,{r:()=>s});var r=i(74140),n=i(97703);function s(e){function t(t){Object.defineProperty(e,t,{value:r.c})}return n.ol&&Symbol.species&&t(Symbol.species),t("@@species"),e}},90767(e,t,i){"use strict";function r(e){return e.catch(function(){}),e}i.d(t,{X:()=>r})},29527(e,t,i){"use strict";i.d(t,{r:()=>r});var r="3.14.0"},45688(e,t,i){"use strict";i.d(t,{vq:()=>fs});var r=i(95177),n=i(14927);const s="AAD",o="OIDC",a="none";var l=i(90865);const c="client_info_decoding_error",u="client_info_empty_error",h="token_parsing_error",d="null_or_empty_token",p="endpoints_resolution_error",g="network_error",f="openid_config_error",m="hash_not_deserialized",v="invalid_state",C="state_mismatch",y="state_not_found",w="nonce_mismatch",S="auth_time_not_found",b="max_age_transpired",E="multiple_matching_tokens",A="multiple_matching_accounts",T="multiple_matching_appMetadata",M="request_cannot_be_made",R="cannot_remove_empty_scope",_="cannot_append_scopeset",P="empty_input_scopeset",x="device_code_polling_cancelled",D="device_code_expired",I="device_code_unknown_error",L="no_account_in_silent_request",N="invalid_cache_record",O="invalid_cache_environment",F="no_account_found",k="no_crypto_object",G="unexpected_credential_type",V="invalid_assertion",H="invalid_client_credential",B="token_refresh_required",z="user_timeout_reached",U="token_claims_cnf_required_for_signedjwt",W="authorization_code_missing_from_server_response",j="binding_key_not_removed",K="end_session_endpoint_not_supported",$="key_id_missing",q="no_network_connectivity",Y="user_canceled",Q="missing_tenant_id_error",X="method_not_implemented",Z="nested_app_auth_bridge_disabled",J={[c]:"The client info could not be parsed/decoded correctly",[u]:"The client info was empty",[h]:"Token cannot be parsed",[d]:"The token is null or empty",[p]:"Endpoints cannot be resolved",[g]:"Network request failed",[f]:"Could not retrieve endpoints. Check your authority and verify the .well-known/openid-configuration endpoint returns the required endpoints.",[m]:"The hash parameters could not be deserialized",[v]:"State was not the expected format",[C]:"State mismatch error",[y]:"State not found",[w]:"Nonce mismatch error",[S]:"Max Age was requested and the ID token is missing the auth_time variable. auth_time is an optional claim and is not enabled by default - it must be enabled. See https://aka.ms/msaljs/optional-claims for more information.",[b]:"Max Age is set to 0, or too much time has elapsed since the last end-user authentication.",[E]:"The cache contains multiple tokens satisfying the requirements. Call AcquireToken again providing more requirements such as authority or account.",[A]:"The cache contains multiple accounts satisfying the given parameters. Please pass more info to obtain the correct account",[T]:"The cache contains multiple appMetadata satisfying the given parameters. Please pass more info to obtain the correct appMetadata",[M]:"Token request cannot be made without authorization code or refresh token.",[R]:"Cannot remove null or empty scope from ScopeSet",[_]:"Cannot append ScopeSet",[P]:"Empty input ScopeSet cannot be processed",[x]:"Caller has cancelled token endpoint polling during device code flow by setting DeviceCodeRequest.cancel = true.",[D]:"Device code is expired.",[I]:"Device code stopped polling for unknown reasons.",[L]:"Please pass an account object, silent flow is not supported without account information",[N]:"Cache record object was null or undefined.",[O]:"Invalid environment when attempting to create cache entry",[F]:"No account found in cache for given key.",[k]:"No crypto object detected.",[G]:"Unexpected credential type.",[V]:"Client assertion must meet requirements described in https://tools.ietf.org/html/rfc7515",[H]:"Client credential (secret, certificate, or assertion) must not be empty when creating a confidential client. An application should at most have one credential",[B]:"Cannot return token from cache because it must be refreshed. This may be due to one of the following reasons: forceRefresh parameter is set to true, claims have been requested, there is no cached access token or it is expired.",[z]:"User defined timeout for device code polling reached",[U]:"Cannot generate a POP jwt if the token_claims are not populated",[W]:"Server response does not contain an authorization code to proceed",[j]:"Could not remove the credential's binding key from storage.",[K]:"The provided authority does not support logout",[$]:"A keyId value is missing from the requested bound token's cache record and is required to match the token to it's stored binding key.",[q]:"No network connectivity. Check your internet connection.",[Y]:"User cancelled the flow.",[Q]:"A tenant id - not common, organizations, or consumers - must be specified when using the client_credentials flow.",[X]:"This method has not been implemented",[Z]:"The nested app auth bridge is disabled"};class ee extends l.lR{constructor(e,t){super(e,t?`${J[e]}: ${t}`:J[e]),this.name="ClientAuthError",Object.setPrototypeOf(this,ee.prototype)}}function te(e,t){return new ee(e,t)}const ie={createNewGuid:()=>{throw te(X)},base64Decode:()=>{throw te(X)},base64Encode:()=>{throw te(X)},base64UrlEncode:()=>{throw te(X)},encodeKid:()=>{throw te(X)},async getPublicKeyThumbprint(){throw te(X)},async removeTokenBindingKey(){throw te(X)},async clearKeystore(){throw te(X)},async signJwt(){throw te(X)},async hashString(){throw te(X)}},re="@azure/msal-common",ne="14.15.0";function se(e,t){const i=function(e){if(!e)throw te(d);const t=/^([^\.\s]*)\.([^\.\s]+)\.([^\.\s]*)$/.exec(e);if(!t||t.length<4)throw te(h);return t[2]}(e);try{const e=t(i);return JSON.parse(e)}catch(e){throw te(h)}}function oe(e,t){if(0===t||Date.now()-3e5>e+t)throw te(b)}function ae(){return Math.round((new Date).getTime()/1e3)}function le(e,t){const i=Number(e)||0;return ae()+t>i}function ce(e){return[ve(e),Ce(e),ye(e),we(e),Se(e)].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}function ue(e,t,i,r,s){return{credentialType:n.aG.ID_TOKEN,homeAccountId:e,environment:t,clientId:r,secret:i,realm:s}}function he(e,t,i,r,s,o,a,l,c,u,h,d,p,g,f){const m={homeAccountId:e,credentialType:n.aG.ACCESS_TOKEN,secret:i,cachedAt:ae().toString(),expiresOn:a.toString(),extendedExpiresOn:l.toString(),environment:t,clientId:r,realm:s,target:o,tokenType:h||n.IO.BEARER};if(d&&(m.userAssertionHash=d),u&&(m.refreshOn=u.toString()),g&&(m.requestedClaims=g,m.requestedClaimsHash=f),m.tokenType?.toLowerCase()!==n.IO.BEARER.toLowerCase())switch(m.credentialType=n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME,m.tokenType){case n.IO.POP:const e=se(i,c);if(!e?.cnf?.kid)throw te(U);m.keyId=e.cnf.kid;break;case n.IO.SSH:m.keyId=p}return m}function de(e,t,i,r,s,o,a){const l={credentialType:n.aG.REFRESH_TOKEN,homeAccountId:e,environment:t,clientId:r,secret:i};return o&&(l.userAssertionHash=o),s&&(l.familyId=s),a&&(l.expiresOn=a.toString()),l}function pe(e){return e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("credentialType")&&e.hasOwnProperty("clientId")&&e.hasOwnProperty("secret")}function ge(e){return!!e&&pe(e)&&e.hasOwnProperty("realm")&&e.hasOwnProperty("target")&&(e.credentialType===n.aG.ACCESS_TOKEN||e.credentialType===n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME)}function fe(e){return!!e&&pe(e)&&e.hasOwnProperty("realm")&&e.credentialType===n.aG.ID_TOKEN}function me(e){return!!e&&pe(e)&&e.credentialType===n.aG.REFRESH_TOKEN}function ve(e){return[e.homeAccountId,e.environment].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}function Ce(e){const t=e.credentialType===n.aG.REFRESH_TOKEN&&e.familyId||e.clientId;return[e.credentialType,t,e.realm||""].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}function ye(e){return(e.target||"").toLowerCase()}function we(e){return(e.requestedClaimsHash||"").toLowerCase()}function Se(e){return e.tokenType&&e.tokenType.toLowerCase()!==n.IO.BEARER.toLowerCase()?e.tokenType.toLowerCase():""}function be(){return ae()+n.u0.REFRESH_TIME_SECONDS}function Ee(e,t,i){e.authorization_endpoint=t.authorization_endpoint,e.token_endpoint=t.token_endpoint,e.end_session_endpoint=t.end_session_endpoint,e.issuer=t.issuer,e.endpointsFromNetwork=i,e.jwks_uri=t.jwks_uri}function Ae(e,t,i){e.aliases=t.aliases,e.preferred_cache=t.preferred_cache,e.preferred_network=t.preferred_network,e.aliasesFromNetwork=i}function Te(e){return e.expiresAt<=ae()}const Me="redirect_uri_empty",Re="claims_request_parsing_error",_e="authority_uri_insecure",Pe="url_parse_error",xe="empty_url_error",De="empty_input_scopes_error",Ie="invalid_prompt_value",Le="invalid_claims",Ne="token_request_empty",Oe="logout_request_empty",Fe="invalid_code_challenge_method",ke="pkce_params_missing",Ge="invalid_cloud_discovery_metadata",Ve="invalid_authority_metadata",He="untrusted_authority",Be="missing_ssh_jwk",ze="missing_ssh_kid",Ue="missing_nonce_authentication_header",We="invalid_authentication_header",je="cannot_set_OIDCOptions",Ke="cannot_allow_native_broker",$e="authority_mismatch",qe={[Me]:"A redirect URI is required for all calls, and none has been set.",[Re]:"Could not parse the given claims request object.",[_e]:"Authority URIs must use https.  Please see here for valid authority configuration options: https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-js-initializing-client-applications#configuration-options",[Pe]:"URL could not be parsed into appropriate segments.",[xe]:"URL was empty or null.",[De]:"Scopes cannot be passed as null, undefined or empty array because they are required to obtain an access token.",[Ie]:"Please see here for valid configuration options: https://azuread.github.io/microsoft-authentication-library-for-js/ref/modules/_azure_msal_common.html#commonauthorizationurlrequest",[Le]:"Given claims parameter must be a stringified JSON object.",[Ne]:"Token request was empty and not found in cache.",[Oe]:"The logout request was null or undefined.",[Fe]:'code_challenge_method passed is invalid. Valid values are "plain" and "S256".',[ke]:"Both params: code_challenge and code_challenge_method are to be passed if to be sent in the request",[Ge]:"Invalid cloudDiscoveryMetadata provided. Must be a stringified JSON object containing tenant_discovery_endpoint and metadata fields",[Ve]:"Invalid authorityMetadata provided. Must by a stringified JSON object containing authorization_endpoint, token_endpoint, issuer fields.",[He]:"The provided authority is not a trusted authority. Please include this authority in the knownAuthorities config parameter.",[Be]:"Missing sshJwk in SSH certificate request. A stringified JSON Web Key is required when using the SSH authentication scheme.",[ze]:"Missing sshKid in SSH certificate request. A string that uniquely identifies the public SSH key is required when using the SSH authentication scheme.",[Ue]:"Unable to find an authentication header containing server nonce. Either the Authentication-Info or WWW-Authenticate headers must be present in order to obtain a server nonce.",[We]:"Invalid authentication header provided",[je]:"Cannot set OIDCOptions parameter. Please change the protocol mode to OIDC or use a non-Microsoft authority.",[Ke]:"Cannot set allowNativeBroker parameter to true when not in AAD protocol mode.",[$e]:"Authority mismatch error. Authority provided in login request or PublicClientApplication config does not match the environment of the provided account. Please use a matching account or make an interactive request to login to this authority."};class Ye extends l.lR{constructor(e){super(e,qe[e]),this.name="ClientConfigurationError",Object.setPrototypeOf(this,Ye.prototype)}}function Qe(e){return new Ye(e)}class Xe{static isEmptyObj(e){if(e)try{const t=JSON.parse(e);return 0===Object.keys(t).length}catch(e){}return!0}static startsWith(e,t){return 0===e.indexOf(t)}static endsWith(e,t){return e.length>=t.length&&e.lastIndexOf(t)===e.length-t.length}static queryStringToObject(e){const t={},i=e.split("&"),r=e=>decodeURIComponent(e.replace(/\+/g," "));return i.forEach(e=>{if(e.trim()){const[i,n]=e.split(/=(.+)/g,2);i&&n&&(t[r(i)]=r(n))}}),t}static trimArrayEntries(e){return e.map(e=>e.trim())}static removeEmptyStringsFromArray(e){return e.filter(e=>!!e)}static jsonParseHelper(e){try{return JSON.parse(e)}catch(e){return null}}static matchPattern(e,t){return new RegExp(e.replace(/\\/g,"\\\\").replace(/\*/g,"[^ ]*").replace(/\?/g,"\\?")).test(t)}}class Ze{constructor(e){const t=e?Xe.trimArrayEntries([...e]):[],i=t?Xe.removeEmptyStringsFromArray(t):[];this.validateInputScopes(i),this.scopes=new Set,i.forEach(e=>this.scopes.add(e))}static fromString(e){const t=(e||n.YM.EMPTY_STRING).split(" ");return new Ze(t)}static createSearchScopes(e){const t=new Ze(e);return t.containsOnlyOIDCScopes()?t.removeScope(n.YM.OFFLINE_ACCESS_SCOPE):t.removeOIDCScopes(),t}validateInputScopes(e){if(!e||e.length<1)throw Qe(De)}containsScope(e){const t=this.printScopesLowerCase().split(" "),i=new Ze(t);return!!e&&i.scopes.has(e.toLowerCase())}containsScopeSet(e){return!(!e||e.scopes.size<=0)&&this.scopes.size>=e.scopes.size&&e.asArray().every(e=>this.containsScope(e))}containsOnlyOIDCScopes(){let e=0;return n._A.forEach(t=>{this.containsScope(t)&&(e+=1)}),this.scopes.size===e}appendScope(e){e&&this.scopes.add(e.trim())}appendScopes(e){try{e.forEach(e=>this.appendScope(e))}catch(e){throw te(_)}}removeScope(e){if(!e)throw te(R);this.scopes.delete(e.trim())}removeOIDCScopes(){n._A.forEach(e=>{this.scopes.delete(e)})}unionScopeSets(e){if(!e)throw te(P);const t=new Set;return e.scopes.forEach(e=>t.add(e.toLowerCase())),this.scopes.forEach(e=>t.add(e.toLowerCase())),t}intersectingScopeSets(e){if(!e)throw te(P);e.containsOnlyOIDCScopes()||e.removeOIDCScopes();const t=this.unionScopeSets(e),i=e.getScopeCount(),r=this.getScopeCount();return t.size<r+i}getScopeCount(){return this.scopes.size}asArray(){const e=[];return this.scopes.forEach(t=>e.push(t)),e}printScopes(){return this.scopes?this.asArray().join(" "):n.YM.EMPTY_STRING}printScopesLowerCase(){return this.printScopes().toLowerCase()}}function Je(e,t){if(!e)throw te(u);try{const i=t(e);return JSON.parse(i)}catch(e){throw te(c)}}function et(e){if(!e)throw te(c);const t=e.split(n.LR.CLIENT_INFO_SEPARATOR,2);return{uid:t[0],utid:t.length<2?n.YM.EMPTY_STRING:t[1]}}function tt(e,t){return!!e&&!!t&&e===t.split(".")[1]}function it(e,t,i,r){if(r){const{oid:t,sub:i,tid:n,name:s,tfp:o,acr:a}=r,l=n||o||a||"";return{tenantId:l,localAccountId:t||i||"",name:s,isHomeTenant:tt(l,e)}}return{tenantId:i,localAccountId:t,isHomeTenant:tt(i,e)}}function rt(e,t,i,r){let n=e;if(t){const{isHomeTenant:i,...r}=t;n={...e,...r}}if(i){const{isHomeTenant:t,...s}=it(e.homeAccountId,e.localAccountId,e.tenantId,i);return n={...n,...s,idTokenClaims:i,idToken:r},n}return n}function nt(e){return e&&(e.tid||e.tfp||e.acr)||null}class st{generateAccountId(){return[this.homeAccountId,this.environment].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}generateAccountKey(){return st.generateAccountCacheKey({homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId})}getAccountInfo(){return{homeAccountId:this.homeAccountId,environment:this.environment,tenantId:this.realm,username:this.username,localAccountId:this.localAccountId,name:this.name,nativeAccountId:this.nativeAccountId,authorityType:this.authorityType,tenantProfiles:new Map((this.tenantProfiles||[]).map(e=>[e.tenantId,e]))}}isSingleTenant(){return!this.tenantProfiles}static generateAccountCacheKey(e){const t=e.homeAccountId.split(".")[1];return[e.homeAccountId,e.environment||"",t||e.tenantId||""].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}static createAccount(e,t,i){const r=new st;let o;1===t.authorityType?r.authorityType=n.Qd.ADFS_ACCOUNT_TYPE:t.protocolMode===s?r.authorityType=n.Qd.MSSTS_ACCOUNT_TYPE:r.authorityType=n.Qd.GENERIC_ACCOUNT_TYPE,e.clientInfo&&i&&(o=Je(e.clientInfo,i)),r.clientInfo=e.clientInfo,r.homeAccountId=e.homeAccountId,r.nativeAccountId=e.nativeAccountId;const a=e.environment||t&&t.getPreferredCache();if(!a)throw te(O);r.environment=a,r.realm=o?.utid||nt(e.idTokenClaims)||"",r.localAccountId=o?.uid||e.idTokenClaims?.oid||e.idTokenClaims?.sub||"";const l=e.idTokenClaims?.preferred_username||e.idTokenClaims?.upn,c=e.idTokenClaims?.emails?e.idTokenClaims.emails[0]:null;if(r.username=l||c||"",r.name=e.idTokenClaims?.name||"",r.cloudGraphHostName=e.cloudGraphHostName,r.msGraphHost=e.msGraphHost,e.tenantProfiles)r.tenantProfiles=e.tenantProfiles;else{const t=it(e.homeAccountId,r.localAccountId,r.realm,e.idTokenClaims);r.tenantProfiles=[t]}return r}static createFromAccountInfo(e,t,i){const r=new st;return r.authorityType=e.authorityType||n.Qd.GENERIC_ACCOUNT_TYPE,r.homeAccountId=e.homeAccountId,r.localAccountId=e.localAccountId,r.nativeAccountId=e.nativeAccountId,r.realm=e.tenantId,r.environment=e.environment,r.username=e.username,r.name=e.name,r.cloudGraphHostName=t,r.msGraphHost=i,r.tenantProfiles=Array.from(e.tenantProfiles?.values()||[]),r}static generateHomeAccountId(e,t,i,r,n){if(1!==t&&2!==t){if(e)try{const t=Je(e,r.base64Decode);if(t.uid&&t.utid)return`${t.uid}.${t.utid}`}catch(e){}i.warning("No client info in response")}return n?.sub||""}static isAccountEntity(e){return!!e&&e.hasOwnProperty("homeAccountId")&&e.hasOwnProperty("environment")&&e.hasOwnProperty("realm")&&e.hasOwnProperty("localAccountId")&&e.hasOwnProperty("username")&&e.hasOwnProperty("authorityType")}static accountInfoIsEqual(e,t,i){if(!e||!t)return!1;let r=!0;if(i){const i=e.idTokenClaims||{},n=t.idTokenClaims||{};r=i.iat===n.iat&&i.nonce===n.nonce}return e.homeAccountId===t.homeAccountId&&e.localAccountId===t.localAccountId&&e.username===t.username&&e.tenantId===t.tenantId&&e.environment===t.environment&&e.nativeAccountId===t.nativeAccountId&&r}}function ot(e){return e.startsWith("#/")?e.substring(2):e.startsWith("#")||e.startsWith("?")?e.substring(1):e}function at(e){if(!e||e.indexOf("=")<0)return null;try{const t=ot(e),i=Object.fromEntries(new URLSearchParams(t));if(i.code||i.error||i.error_description||i.state)return i}catch(e){throw te(m)}return null}class lt{get urlString(){return this._urlString}constructor(e){if(this._urlString=e,!this._urlString)throw Qe(xe);e.includes("#")||(this._urlString=lt.canonicalizeUri(e))}static canonicalizeUri(e){if(e){let t=e.toLowerCase();return Xe.endsWith(t,"?")?t=t.slice(0,-1):Xe.endsWith(t,"?/")&&(t=t.slice(0,-2)),Xe.endsWith(t,"/")||(t+="/"),t}return e}validateAsUri(){let e;try{e=this.getUrlComponents()}catch(e){throw Qe(Pe)}if(!e.HostNameAndPort||!e.PathSegments)throw Qe(Pe);if(!e.Protocol||"https:"!==e.Protocol.toLowerCase())throw Qe(_e)}static appendQueryString(e,t){return t?e.indexOf("?")<0?`${e}?${t}`:`${e}&${t}`:e}static removeHashFromUrl(e){return lt.canonicalizeUri(e.split("#")[0])}replaceTenantPath(e){const t=this.getUrlComponents(),i=t.PathSegments;return!e||0===i.length||i[0]!==n.v2.COMMON&&i[0]!==n.v2.ORGANIZATIONS||(i[0]=e),lt.constructAuthorityUriFromObject(t)}getUrlComponents(){const e=RegExp("^(([^:/?#]+):)?(//([^/?#]*))?([^?#]*)(\\?([^#]*))?(#(.*))?"),t=this.urlString.match(e);if(!t)throw Qe(Pe);const i={Protocol:t[1],HostNameAndPort:t[4],AbsolutePath:t[5],QueryString:t[7]};let r=i.AbsolutePath.split("/");return r=r.filter(e=>e&&e.length>0),i.PathSegments=r,i.QueryString&&i.QueryString.endsWith("/")&&(i.QueryString=i.QueryString.substring(0,i.QueryString.length-1)),i}static getDomainFromUrl(e){const t=RegExp("^([^:/?#]+://)?([^/?#]*)"),i=e.match(t);if(!i)throw Qe(Pe);return i[2]}static getAbsoluteUrl(e,t){if(e[0]===n.YM.FORWARD_SLASH){const i=new lt(t).getUrlComponents();return i.Protocol+"//"+i.HostNameAndPort+e}return e}static constructAuthorityUriFromObject(e){return new lt(e.Protocol+"//"+e.HostNameAndPort+"/"+e.PathSegments.join("/"))}static hashContainsKnownProperties(e){return!!at(e)}}const ct={"login.microsoftonline.com":{token_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.com/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.com/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.com/{tenantid}/oauth2/v2.0/logout"},"login.chinacloudapi.cn":{token_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.chinacloudapi.cn/{tenantid}/discovery/v2.0/keys",issuer:"https://login.partner.microsoftonline.cn/{tenantid}/v2.0",authorization_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.chinacloudapi.cn/{tenantid}/oauth2/v2.0/logout"},"login.microsoftonline.us":{token_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/token",jwks_uri:"https://login.microsoftonline.us/{tenantid}/discovery/v2.0/keys",issuer:"https://login.microsoftonline.us/{tenantid}/v2.0",authorization_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/authorize",end_session_endpoint:"https://login.microsoftonline.us/{tenantid}/oauth2/v2.0/logout"}},ut={tenant_discovery_endpoint:"https://{canonicalAuthority}/v2.0/.well-known/openid-configuration",metadata:[{preferred_network:"login.microsoftonline.com",preferred_cache:"login.windows.net",aliases:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"]},{preferred_network:"login.partner.microsoftonline.cn",preferred_cache:"login.partner.microsoftonline.cn",aliases:["login.partner.microsoftonline.cn","login.chinacloudapi.cn"]},{preferred_network:"login.microsoftonline.de",preferred_cache:"login.microsoftonline.de",aliases:["login.microsoftonline.de"]},{preferred_network:"login.microsoftonline.us",preferred_cache:"login.microsoftonline.us",aliases:["login.microsoftonline.us","login.usgovcloudapi.net"]},{preferred_network:"login-us.microsoftonline.com",preferred_cache:"login-us.microsoftonline.com",aliases:["login-us.microsoftonline.com"]}]},ht=new Set;function dt(e,t,i,r){if(r?.trace(`getAliasesFromMetadata called with source: ${i}`),e&&t){const n=pt(t,e);if(n)return r?.trace(`getAliasesFromMetadata: found cloud discovery metadata in ${i}, returning aliases`),n.aliases;r?.trace(`getAliasesFromMetadata: did not find cloud discovery metadata in ${i}`)}return null}function pt(e,t){for(let i=0;i<e.length;i++){const r=e[i];if(r.aliases.includes(t))return r}return null}ut.metadata.forEach(e=>{e.aliases.forEach(e=>{ht.add(e)})});const gt="cache_quota_exceeded",ft="cache_error_unknown",mt={[gt]:"Exceeded cache storage capacity.",[ft]:"Unexpected error occurred when using cache storage."};class vt extends Error{constructor(e,t){const i=t||(mt[e]?mt[e]:mt[ft]);super(`${e}: ${i}`),Object.setPrototypeOf(this,vt.prototype),this.name="CacheError",this.errorCode=e,this.errorMessage=i}}class Ct{constructor(e,t,i,r){this.clientId=e,this.cryptoImpl=t,this.commonLogger=i.clone(re,ne),this.staticAuthorityOptions=r}getAllAccounts(e){return this.buildTenantProfiles(this.getAccountsFilteredBy(e||{}),e)}getAccountInfoFilteredBy(e){const t=this.getAllAccounts(e);return t.length>1?t.sort(e=>e.idTokenClaims?-1:1)[0]:1===t.length?t[0]:null}getBaseAccountInfo(e){const t=this.getAccountsFilteredBy(e);return t.length>0?t[0].getAccountInfo():null}buildTenantProfiles(e,t){return e.flatMap(e=>this.getTenantProfilesFromAccountEntity(e,t?.tenantId,t))}getTenantedAccountInfoByFilter(e,t,i,r){let n,s=null;if(r&&!this.tenantProfileMatchesFilter(i,r))return null;const o=this.getIdToken(e,t,i.tenantId);return o&&(n=se(o.secret,this.cryptoImpl.base64Decode),!this.idTokenClaimsMatchTenantProfileFilter(n,r))?null:(s=rt(e,i,n,o?.secret),s)}getTenantProfilesFromAccountEntity(e,t,i){const r=e.getAccountInfo();let n=r.tenantProfiles||new Map;const s=this.getTokenKeys();if(t){const e=n.get(t);if(!e)return[];n=new Map([[t,e]])}const o=[];return n.forEach(e=>{const t=this.getTenantedAccountInfoByFilter(r,s,e,i);t&&o.push(t)}),o}tenantProfileMatchesFilter(e,t){return!(t.localAccountId&&!this.matchLocalAccountIdFromTenantProfile(e,t.localAccountId)||t.name&&e.name!==t.name||void 0!==t.isHomeTenant&&e.isHomeTenant!==t.isHomeTenant)}idTokenClaimsMatchTenantProfileFilter(e,t){if(t){if(t.localAccountId&&!this.matchLocalAccountIdFromTokenClaims(e,t.localAccountId))return!1;if(t.loginHint&&!this.matchLoginHintFromTokenClaims(e,t.loginHint))return!1;if(t.username&&!this.matchUsername(e.preferred_username,t.username))return!1;if(t.name&&!this.matchName(e,t.name))return!1;if(t.sid&&!this.matchSid(e,t.sid))return!1}return!0}async saveCacheRecord(e,t,i){if(!e)throw te(N);try{e.account&&this.setAccount(e.account),e.idToken&&!1!==t?.idToken&&this.setIdTokenCredential(e.idToken),e.accessToken&&!1!==t?.accessToken&&await this.saveAccessToken(e.accessToken),e.refreshToken&&!1!==t?.refreshToken&&this.setRefreshTokenCredential(e.refreshToken),e.appMetadata&&this.setAppMetadata(e.appMetadata)}catch(e){throw this.commonLogger?.error("CacheManager.saveCacheRecord: failed"),e instanceof Error?(this.commonLogger?.errorPii(`CacheManager.saveCacheRecord: ${e.message}`,i),"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name||e.message.includes("exceeded the quota")?(this.commonLogger?.error("CacheManager.saveCacheRecord: exceeded storage quota",i),new vt(gt)):new vt(e.name,e.message)):(this.commonLogger?.errorPii(`CacheManager.saveCacheRecord: ${e}`,i),new vt(ft))}}async saveAccessToken(e){const t={clientId:e.clientId,credentialType:e.credentialType,environment:e.environment,homeAccountId:e.homeAccountId,realm:e.realm,tokenType:e.tokenType,requestedClaimsHash:e.requestedClaimsHash},i=this.getTokenKeys(),r=Ze.fromString(e.target),n=[];i.accessToken.forEach(e=>{if(!this.accessTokenKeyMatchesFilter(e,t,!1))return;const i=this.getAccessTokenCredential(e);i&&this.credentialMatchesFilter(i,t)&&Ze.fromString(i.target).intersectingScopeSets(r)&&n.push(this.removeAccessToken(e))}),await Promise.all(n),this.setAccessTokenCredential(e)}getAccountsFilteredBy(e){const t=this.getAccountKeys(),i=[];return t.forEach(t=>{if(!this.isAccountKey(t,e.homeAccountId))return;const r=this.getAccount(t,this.commonLogger);if(!r)return;if(e.homeAccountId&&!this.matchHomeAccountId(r,e.homeAccountId))return;if(e.username&&!this.matchUsername(r.username,e.username))return;if(e.environment&&!this.matchEnvironment(r,e.environment))return;if(e.realm&&!this.matchRealm(r,e.realm))return;if(e.nativeAccountId&&!this.matchNativeAccountId(r,e.nativeAccountId))return;if(e.authorityType&&!this.matchAuthorityType(r,e.authorityType))return;const n={localAccountId:e?.localAccountId,name:e?.name},s=r.tenantProfiles?.filter(e=>this.tenantProfileMatchesFilter(e,n));s&&0===s.length||i.push(r)}),i}isAccountKey(e,t,i){return!(e.split(n.LR.CACHE_KEY_SEPARATOR).length<3||t&&!e.toLowerCase().includes(t.toLowerCase())||i&&!e.toLowerCase().includes(i.toLowerCase()))}isCredentialKey(e){if(e.split(n.LR.CACHE_KEY_SEPARATOR).length<6)return!1;const t=e.toLowerCase();if(-1===t.indexOf(n.aG.ID_TOKEN.toLowerCase())&&-1===t.indexOf(n.aG.ACCESS_TOKEN.toLowerCase())&&-1===t.indexOf(n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase())&&-1===t.indexOf(n.aG.REFRESH_TOKEN.toLowerCase()))return!1;if(t.indexOf(n.aG.REFRESH_TOKEN.toLowerCase())>-1){const e=`${n.aG.REFRESH_TOKEN}${n.LR.CACHE_KEY_SEPARATOR}${this.clientId}${n.LR.CACHE_KEY_SEPARATOR}`,i=`${n.aG.REFRESH_TOKEN}${n.LR.CACHE_KEY_SEPARATOR}${n.hB}${n.LR.CACHE_KEY_SEPARATOR}`;if(-1===t.indexOf(e.toLowerCase())&&-1===t.indexOf(i.toLowerCase()))return!1}else if(-1===t.indexOf(this.clientId.toLowerCase()))return!1;return!0}credentialMatchesFilter(e,t){if(t.clientId&&!this.matchClientId(e,t.clientId))return!1;if(t.userAssertionHash&&!this.matchUserAssertionHash(e,t.userAssertionHash))return!1;if("string"==typeof t.homeAccountId&&!this.matchHomeAccountId(e,t.homeAccountId))return!1;if(t.environment&&!this.matchEnvironment(e,t.environment))return!1;if(t.realm&&!this.matchRealm(e,t.realm))return!1;if(t.credentialType&&!this.matchCredentialType(e,t.credentialType))return!1;if(t.familyId&&!this.matchFamilyId(e,t.familyId))return!1;if(t.target&&!this.matchTarget(e,t.target))return!1;if((t.requestedClaimsHash||e.requestedClaimsHash)&&e.requestedClaimsHash!==t.requestedClaimsHash)return!1;if(e.credentialType===n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME){if(t.tokenType&&!this.matchTokenType(e,t.tokenType))return!1;if(t.tokenType===n.IO.SSH&&t.keyId&&!this.matchKeyId(e,t.keyId))return!1}return!0}getAppMetadataFilteredBy(e){const t=this.getKeys(),i={};return t.forEach(t=>{if(!this.isAppMetadata(t))return;const r=this.getAppMetadata(t);r&&(e.environment&&!this.matchEnvironment(r,e.environment)||e.clientId&&!this.matchClientId(r,e.clientId)||(i[t]=r))}),i}getAuthorityMetadataByAlias(e){const t=this.getAuthorityMetadataKeys();let i=null;return t.forEach(t=>{if(!this.isAuthorityMetadata(t)||-1===t.indexOf(this.clientId))return;const r=this.getAuthorityMetadata(t);r&&-1!==r.aliases.indexOf(e)&&(i=r)}),i}async removeAllAccounts(){const e=this.getAccountKeys(),t=[];e.forEach(e=>{t.push(this.removeAccount(e))}),await Promise.all(t)}async removeAccount(e){const t=this.getAccount(e,this.commonLogger);t&&(await this.removeAccountContext(t),this.removeItem(e))}async removeAccountContext(e){const t=this.getTokenKeys(),i=e.generateAccountId(),r=[];t.idToken.forEach(e=>{0===e.indexOf(i)&&this.removeIdToken(e)}),t.accessToken.forEach(e=>{0===e.indexOf(i)&&r.push(this.removeAccessToken(e))}),t.refreshToken.forEach(e=>{0===e.indexOf(i)&&this.removeRefreshToken(e)}),await Promise.all(r)}updateOutdatedCachedAccount(e,t,i){if(t&&t.isSingleTenant()){this.commonLogger?.verbose("updateOutdatedCachedAccount: Found a single-tenant (outdated) account entity in the cache, migrating to multi-tenant account entity");const r=this.getAccountKeys().filter(e=>e.startsWith(t.homeAccountId)),n=[];r.forEach(e=>{const t=this.getCachedAccountEntity(e);t&&n.push(t)});const s=n.find(e=>tt(e.realm,e.homeAccountId))||n[0];s.tenantProfiles=n.map(e=>({tenantId:e.realm,localAccountId:e.localAccountId,name:e.name,isHomeTenant:tt(e.realm,e.homeAccountId)}));const o=Ct.toObject(new st,{...s}),a=o.generateAccountKey();return r.forEach(t=>{t!==a&&this.removeOutdatedAccount(e)}),this.setAccount(o),i?.verbose("Updated an outdated account entity in the cache"),o}return t}async removeAccessToken(e){const t=this.getAccessTokenCredential(e);if(t){if(t.credentialType.toLowerCase()===n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME.toLowerCase()&&t.tokenType===n.IO.POP){const e=t.keyId;if(e)try{await this.cryptoImpl.removeTokenBindingKey(e)}catch(e){throw te(j)}}return this.removeItem(e)}}removeAppMetadata(){return this.getKeys().forEach(e=>{this.isAppMetadata(e)&&this.removeItem(e)}),!0}readAccountFromCache(e){const t=st.generateAccountCacheKey(e);return this.getAccount(t,this.commonLogger)}getIdToken(e,t,i,r,s){this.commonLogger.trace("CacheManager - getIdToken called");const o={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:n.aG.ID_TOKEN,clientId:this.clientId,realm:i},a=this.getIdTokensByFilter(o,t),l=a.size;if(l<1)return this.commonLogger.info("CacheManager:getIdToken - No token found"),null;if(l>1){let t=a;if(!i){const i=new Map;a.forEach((t,r)=>{t.realm===e.tenantId&&i.set(r,t)});const r=i.size;if(r<1)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account but none match account entity tenant id, returning first result"),a.values().next().value;if(1===r)return this.commonLogger.info("CacheManager:getIdToken - Multiple ID tokens found for account, defaulting to home tenant profile"),i.values().next().value;t=i}return this.commonLogger.info("CacheManager:getIdToken - Multiple matching ID tokens found, clearing them"),t.forEach((e,t)=>{this.removeIdToken(t)}),r&&s&&r.addFields({multiMatchedID:a.size},s),null}return this.commonLogger.info("CacheManager:getIdToken - Returning ID token"),a.values().next().value}getIdTokensByFilter(e,t){const i=t&&t.idToken||this.getTokenKeys().idToken,r=new Map;return i.forEach(t=>{if(!this.idTokenKeyMatchesFilter(t,{clientId:this.clientId,...e}))return;const i=this.getIdTokenCredential(t);i&&this.credentialMatchesFilter(i,e)&&r.set(t,i)}),r}idTokenKeyMatchesFilter(e,t){const i=e.toLowerCase();return!(t.clientId&&-1===i.indexOf(t.clientId.toLowerCase())||t.homeAccountId&&-1===i.indexOf(t.homeAccountId.toLowerCase()))}removeIdToken(e){this.removeItem(e)}removeRefreshToken(e){this.removeItem(e)}getAccessToken(e,t,i,r,s,o){this.commonLogger.trace("CacheManager - getAccessToken called");const a=Ze.createSearchScopes(t.scopes),l=t.authenticationScheme||n.IO.BEARER,c=l&&l.toLowerCase()!==n.IO.BEARER.toLowerCase()?n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME:n.aG.ACCESS_TOKEN,u={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:c,clientId:this.clientId,realm:r||e.tenantId,target:a,tokenType:l,keyId:t.sshKid,requestedClaimsHash:t.requestedClaimsHash},h=i&&i.accessToken||this.getTokenKeys().accessToken,d=[];h.forEach(e=>{if(this.accessTokenKeyMatchesFilter(e,u,!0)){const t=this.getAccessTokenCredential(e);t&&this.credentialMatchesFilter(t,u)&&d.push(t)}});const p=d.length;return p<1?(this.commonLogger.info("CacheManager:getAccessToken - No token found"),null):p>1?(this.commonLogger.info("CacheManager:getAccessToken - Multiple access tokens found, clearing them"),d.forEach(e=>{this.removeAccessToken(ce(e))}),s&&o&&s.addFields({multiMatchedAT:d.length},o),null):(this.commonLogger.info("CacheManager:getAccessToken - Returning access token"),d[0])}accessTokenKeyMatchesFilter(e,t,i){const r=e.toLowerCase();if(t.clientId&&-1===r.indexOf(t.clientId.toLowerCase()))return!1;if(t.homeAccountId&&-1===r.indexOf(t.homeAccountId.toLowerCase()))return!1;if(t.realm&&-1===r.indexOf(t.realm.toLowerCase()))return!1;if(t.requestedClaimsHash&&-1===r.indexOf(t.requestedClaimsHash.toLowerCase()))return!1;if(t.target){const e=t.target.asArray();for(let t=0;t<e.length;t++){if(i&&!r.includes(e[t].toLowerCase()))return!1;if(!i&&r.includes(e[t].toLowerCase()))return!0}}return!0}getAccessTokensByFilter(e){const t=this.getTokenKeys(),i=[];return t.accessToken.forEach(t=>{if(!this.accessTokenKeyMatchesFilter(t,e,!0))return;const r=this.getAccessTokenCredential(t);r&&this.credentialMatchesFilter(r,e)&&i.push(r)}),i}getRefreshToken(e,t,i,r,s){this.commonLogger.trace("CacheManager - getRefreshToken called");const o=t?n.hB:void 0,a={homeAccountId:e.homeAccountId,environment:e.environment,credentialType:n.aG.REFRESH_TOKEN,clientId:this.clientId,familyId:o},l=i&&i.refreshToken||this.getTokenKeys().refreshToken,c=[];l.forEach(e=>{if(this.refreshTokenKeyMatchesFilter(e,a)){const t=this.getRefreshTokenCredential(e);t&&this.credentialMatchesFilter(t,a)&&c.push(t)}});const u=c.length;return u<1?(this.commonLogger.info("CacheManager:getRefreshToken - No refresh token found."),null):(u>1&&r&&s&&r.addFields({multiMatchedRT:u},s),this.commonLogger.info("CacheManager:getRefreshToken - returning refresh token"),c[0])}refreshTokenKeyMatchesFilter(e,t){const i=e.toLowerCase();return!(t.familyId&&-1===i.indexOf(t.familyId.toLowerCase())||!t.familyId&&t.clientId&&-1===i.indexOf(t.clientId.toLowerCase())||t.homeAccountId&&-1===i.indexOf(t.homeAccountId.toLowerCase()))}readAppMetadataFromCache(e){const t={environment:e,clientId:this.clientId},i=this.getAppMetadataFilteredBy(t),r=Object.keys(i).map(e=>i[e]),n=r.length;if(n<1)return null;if(n>1)throw te(T);return r[0]}isAppMetadataFOCI(e){const t=this.readAppMetadataFromCache(e);return!(!t||t.familyId!==n.hB)}matchHomeAccountId(e,t){return!("string"!=typeof e.homeAccountId||t!==e.homeAccountId)}matchLocalAccountIdFromTokenClaims(e,t){return t===(e.oid||e.sub)}matchLocalAccountIdFromTenantProfile(e,t){return e.localAccountId===t}matchName(e,t){return!(t.toLowerCase()!==e.name?.toLowerCase())}matchUsername(e,t){return!(!e||"string"!=typeof e||t?.toLowerCase()!==e.toLowerCase())}matchUserAssertionHash(e,t){return!(!e.userAssertionHash||t!==e.userAssertionHash)}matchEnvironment(e,t){if(this.staticAuthorityOptions){const i=function(e,t){let i;const r=e.canonicalAuthority;if(r){const s=new lt(r).getUrlComponents().HostNameAndPort;i=dt(s,e.cloudDiscoveryMetadata?.metadata,n.E_.CONFIG,t)||dt(s,ut.metadata,n.E_.HARDCODED_VALUES,t)||e.knownAuthorities}return i||[]}(this.staticAuthorityOptions,this.commonLogger);if(i.includes(t)&&i.includes(e.environment))return!0}const i=this.getAuthorityMetadataByAlias(t);return!!(i&&i.aliases.indexOf(e.environment)>-1)}matchCredentialType(e,t){return e.credentialType&&t.toLowerCase()===e.credentialType.toLowerCase()}matchClientId(e,t){return!(!e.clientId||t!==e.clientId)}matchFamilyId(e,t){return!(!e.familyId||t!==e.familyId)}matchRealm(e,t){return!(e.realm?.toLowerCase()!==t.toLowerCase())}matchNativeAccountId(e,t){return!(!e.nativeAccountId||t!==e.nativeAccountId)}matchLoginHintFromTokenClaims(e,t){return e.login_hint===t||e.preferred_username===t||e.upn===t}matchSid(e,t){return e.sid===t}matchAuthorityType(e,t){return!(!e.authorityType||t.toLowerCase()!==e.authorityType.toLowerCase())}matchTarget(e,t){return!(e.credentialType!==n.aG.ACCESS_TOKEN&&e.credentialType!==n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME||!e.target)&&Ze.fromString(e.target).containsScopeSet(t)}matchTokenType(e,t){return!(!e.tokenType||e.tokenType!==t)}matchKeyId(e,t){return!(!e.keyId||e.keyId!==t)}isAppMetadata(e){return-1!==e.indexOf(n.GU)}isAuthorityMetadata(e){return-1!==e.indexOf(n.u0.CACHE_KEY)}generateAuthorityMetadataCacheKey(e){return`${n.u0.CACHE_KEY}-${this.clientId}-${e}`}static toObject(e,t){for(const i in t)e[i]=t[i];return e}}class yt extends Ct{setAccount(){throw te(X)}getAccount(){throw te(X)}getCachedAccountEntity(){throw te(X)}setIdTokenCredential(){throw te(X)}getIdTokenCredential(){throw te(X)}setAccessTokenCredential(){throw te(X)}getAccessTokenCredential(){throw te(X)}setRefreshTokenCredential(){throw te(X)}getRefreshTokenCredential(){throw te(X)}setAppMetadata(){throw te(X)}getAppMetadata(){throw te(X)}setServerTelemetry(){throw te(X)}getServerTelemetry(){throw te(X)}setAuthorityMetadata(){throw te(X)}getAuthorityMetadata(){throw te(X)}getAuthorityMetadataKeys(){throw te(X)}setThrottlingCache(){throw te(X)}getThrottlingCache(){throw te(X)}removeItem(){throw te(X)}getKeys(){throw te(X)}getAccountKeys(){throw te(X)}getTokenKeys(){throw te(X)}async clear(){throw te(X)}updateCredentialCacheKey(){throw te(X)}removeOutdatedAccount(){throw te(X)}}const wt={tokenRenewalOffsetSeconds:n.F0,preventCorsPreflight:!1},St={loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:r.$.Info,correlationId:n.YM.EMPTY_STRING},bt={claimsBasedCachingEnabled:!1},Et={async sendGetRequestAsync(){throw te(X)},async sendPostRequestAsync(){throw te(X)}},At={sku:n.YM.SKU,version:ne,cpu:n.YM.EMPTY_STRING,os:n.YM.EMPTY_STRING},Tt={clientSecret:n.YM.EMPTY_STRING,clientAssertion:void 0},Mt={azureCloudInstance:a,tenant:`${n.YM.DEFAULT_COMMON_TENANT}`},Rt={application:{appName:"",appVersion:""}};function _t(e){return e.authOptions.authority.options.protocolMode===o}const Pt={sendGetRequestAsync:()=>Promise.reject(te(X)),sendPostRequestAsync:()=>Promise.reject(te(X))},xt="acquireTokenByCode",Dt="acquireTokenByRefreshToken",It="acquireTokenSilent",Lt="acquireTokenSilentAsync",Nt="acquireTokenPopup",Ot="acquireTokenRedirect",Ft="cryptoOptsGetPublicKeyThumbprint",kt="cryptoOptsSignJwt",Gt="silentCacheClientAcquireToken",Vt="silentIframeClientAcquireToken",Ht="silentRefreshClientAcquireToken",Bt="ssoSilent",zt="standardInteractionClientGetDiscoveredAuthority",Ut="fetchAccountIdWithNativeBroker",Wt="nativeInteractionClientAcquireToken",jt="refreshTokenClientExecutePostToTokenEndpoint",Kt="authorizationCodeClientExecutePostToTokenEndpoint",$t="refreshTokenClientExecuteTokenRequest",qt="refreshTokenClientAcquireToken",Yt="refreshTokenClientAcquireTokenWithCachedRefreshToken",Qt="refreshTokenClientAcquireTokenByRefreshToken",Xt="refreshTokenClientCreateTokenRequestBody",Zt="acquireTokenFromCache",Jt="silentFlowClientAcquireCachedToken",ei="silentFlowClientGenerateResultFromCacheRecord",ti="acquireTokenBySilentIframe",ii="initializeBaseRequest",ri="initializeSilentRequest",ni="initializeClientApplication",si="silentIframeClientTokenHelper",oi="silentHandlerInitiateAuthRequest",ai="silentHandlerMonitorIframeForHash",li="silentHandlerLoadFrame",ci="silentHandlerLoadFrameSync",ui="standardInteractionClientCreateAuthCodeClient",hi="standardInteractionClientGetClientConfiguration",di="standardInteractionClientInitializeAuthorizationRequest",pi="standardInteractionClientInitializeAuthorizationCodeRequest",gi="getAuthCodeUrl",fi="handleCodeResponseFromServer",mi="handleCodeResponse",vi="updateTokenEndpointAuthority",Ci="authClientAcquireToken",yi="authClientExecuteTokenRequest",wi="authClientCreateTokenRequestBody",Si="authClientCreateQueryString",bi="popTokenGenerateCnf",Ei="popTokenGenerateKid",Ai="handleServerTokenResponse",Ti="deserializeResponse",Mi="authorityFactoryCreateDiscoveredInstance",Ri="authorityResolveEndpointsAsync",_i="authorityGetCloudDiscoveryMetadataFromNetwork",Pi="authorityUpdateCloudDiscoveryMetadata",xi="authorityGetEndpointMetadataFromNetwork",Di="authorityUpdateEndpointMetadata",Ii="authorityUpdateMetadataWithRegionalInformation",Li="regionDiscoveryDetectRegion",Ni="regionDiscoveryGetRegionFromIMDS",Oi="regionDiscoveryGetCurrentVersion",Fi="acquireTokenByCodeAsync",ki="handleRedirectPromise",Gi="handleNativeRedirectPromise",Vi="nativeMessageHandlerHandshake",Hi="removeHiddenIframe",Bi="clearTokensAndKeysWithClaims",zi="cacheManagerGetRefreshToken",Ui="generatePkceCodes",Wi="generateCodeVerifier",ji="generateCodeChallengeFromVerifier",Ki="sha256Digest",$i="getRandomValues",qi=(new Map([[xt,"ATByCode"],[Dt,"ATByRT"],[It,"ATS"],[Lt,"ATSAsync"],[Nt,"ATPopup"],[Ot,"ATRedirect"],[Ft,"CryptoGetPKThumb"],[kt,"CryptoSignJwt"],[Gt,"SltCacheClientAT"],[Vt,"SltIframeClientAT"],[Ht,"SltRClientAT"],[Bt,"SsoSlt"],[zt,"StdIntClientGetDiscAuth"],[Ut,"FetchAccIdWithNtvBroker"],[Wt,"NtvIntClientAT"],["baseClientCreateTokenRequestHeaders","BaseClientCreateTReqHead"],[jt,"RTClientExecPost"],[Kt,"AuthCodeClientExecPost"],["brokerHandshake","BrokerHandshake"],["acquireTokenByRefreshTokenInBroker","ATByRTInBroker"],["acquireTokenByBroker","ATByBroker"],[$t,"RTClientExecTReq"],[qt,"RTClientAT"],[Yt,"RTClientATWithCachedRT"],[Qt,"RTClientATByRT"],[Xt,"RTClientCreateTReqBody"],[Zt,"ATFromCache"],[Jt,"SltFlowClientATCached"],[ei,"SltFlowClientGenResFromCache"],[ti,"ATBySltIframe"],[ii,"InitBaseReq"],[ri,"InitSltReq"],[ni,"InitClientApplication"],[si,"SIClientTHelper"],[oi,"SHandlerInitAuthReq"],[ai,"SltHandlerMonitorIframeForHash"],[li,"SHandlerLoadFrame"],[ci,"SHandlerLoadFrameSync"],[ui,"StdIntClientCreateAuthCodeClient"],[hi,"StdIntClientGetClientConf"],[di,"StdIntClientInitAuthReq"],[pi,"StdIntClientInitAuthCodeReq"],[gi,"GetAuthCodeUrl"],[fi,"HandleCodeResFromServer"],[mi,"HandleCodeResp"],[vi,"UpdTEndpointAuth"],[Ci,"AuthClientAT"],[yi,"AuthClientExecTReq"],[wi,"AuthClientCreateTReqBody"],[Si,"AuthClientCreateQueryStr"],[bi,"PopTGenCnf"],[Ei,"PopTGenKid"],[Ai,"HandleServerTRes"],[Ti,"DeserializeRes"],[Mi,"AuthFactCreateDiscInst"],[Ri,"AuthResolveEndpointsAsync"],["authorityResolveEndpointsFromLocalSources","AuthResolveEndpointsFromLocal"],[_i,"AuthGetCDMetaFromNet"],[Pi,"AuthUpdCDMeta"],[xi,"AuthUpdCDMetaFromNet"],[Di,"AuthUpdEndpointMeta"],[Ii,"AuthUpdMetaWithRegInfo"],[Li,"RegDiscDetectReg"],[Ni,"RegDiscGetRegFromIMDS"],[Oi,"RegDiscGetCurrentVer"],[Fi,"ATByCodeAsync"],["getEndpointMetadataFromNetwork","GetEndpointMetaFromNet"],["getCloudDiscoveryMetadataFromNetworkMeasurement","GetCDMetaFromNet"],[ki,"HandleRedirectPromise"],[Gi,"HandleNtvRedirectPromise"],["updateCloudDiscoveryMetadataMeasurement","UpdateCDMeta"],["usernamePasswordClientAcquireToken","UserPassClientAT"],[Vi,"NtvMsgHandlerHandshake"],["nativeGenerateAuthResult","NtvGenAuthRes"],[Hi,"RemoveHiddenIframe"],[Bi,"ClearTAndKeysWithClaims"],[zi,"CacheManagerGetRT"],[Ui,"GenPkceCodes"],[Wi,"GenCodeVerifier"],[ji,"GenCodeChallengeFromVerifier"],[Ki,"Sha256Digest"],[$i,"GetRandomValues"]]),1);new Set(["accessTokenSize","durationMs","idTokenSize","matsSilentStatus","matsHttpStatus","refreshTokenSize","queuedTimeMs","startTimeMs","status","multiMatchedAT","multiMatchedID","multiMatchedRT"]);class Yi{startMeasurement(){}endMeasurement(){}flushMeasurement(){return null}}class Qi{generateId(){return"callback-id"}startMeasurement(e,t){return{end:()=>null,discard:()=>{},add:()=>{},increment:()=>{},event:{eventId:this.generateId(),status:qi,authority:"",libraryName:"",libraryVersion:"",clientId:"",name:e,startTimeMs:Date.now(),correlationId:t||""},measurement:new Yi}}startPerformanceMeasurement(){return new Yi}calculateQueuedTime(){return 0}addQueueMeasurement(){}setPreQueueTime(){}endMeasurement(){return null}discardMeasurements(){}removePerformanceCallback(){return!0}addPerformanceCallback(){return""}emitEvents(){}addFields(){}incrementFields(){}cacheEventByCorrelationId(){}}var Xi=i(58090);class Zi{navigateInternal(e,t){return Zi.defaultNavigateWindow(e,t)}navigateExternal(e,t){return Zi.defaultNavigateWindow(e,t)}static defaultNavigateWindow(e,t){return t.noHistory?window.location.replace(e):window.location.assign(e),new Promise(e=>{setTimeout(()=>{e(!0)},t.timeout)})}}var Ji=i(75970),er=i(2919);class tr{async sendGetRequestAsync(e,t){let i;try{i=await fetch(e,{method:Xi.CC.GET,headers:this.getFetchHeaders(t)})}catch(e){throw window.navigator.onLine?(0,Ji.bD)(er.Zw):(0,Ji.bD)(er.l7)}try{return{headers:this.getHeaderDict(i.headers),body:await i.json(),status:i.status}}catch(e){throw(0,Ji.bD)(er.db)}}async sendPostRequestAsync(e,t){const i=t&&t.body||n.YM.EMPTY_STRING;let r;try{r=await fetch(e,{method:Xi.CC.POST,headers:this.getFetchHeaders(t),body:i})}catch(e){throw window.navigator.onLine?(0,Ji.bD)(er.zv):(0,Ji.bD)(er.l7)}try{return{headers:this.getHeaderDict(r.headers),body:await r.json(),status:r.status}}catch(e){throw(0,Ji.bD)(er.db)}}getFetchHeaders(e){const t=new Headers;if(!e||!e.headers)return t;const i=e.headers;return Object.keys(i).forEach(e=>{t.append(e,i[e])}),t}getHeaderDict(e){const t={};return e.forEach((e,i)=>{t[i]=e}),t}}const ir="3.26.1";class rr{static loggerCallback(e,t){switch(e){case r.$.Error:return void console.error(t);case r.$.Info:return void console.info(t);case r.$.Verbose:return void console.debug(t);case r.$.Warning:return void console.warn(t);default:return void console.log(t)}}constructor(e){let t;this.browserEnvironment="undefined"!=typeof window,this.config=function({auth:e,cache:t,system:i,telemetry:l},c){const u={clientId:n.YM.EMPTY_STRING,authority:`${n.YM.DEFAULT_AUTHORITY}`,knownAuthorities:[],cloudDiscoveryMetadata:n.YM.EMPTY_STRING,authorityMetadata:n.YM.EMPTY_STRING,redirectUri:n.YM.EMPTY_STRING,postLogoutRedirectUri:n.YM.EMPTY_STRING,navigateToLoginRequestUrl:!0,clientCapabilities:[],protocolMode:s,OIDCOptions:{serverResponseType:n.zL.FRAGMENT,defaultScopes:[n.YM.OPENID_SCOPE,n.YM.PROFILE_SCOPE,n.YM.OFFLINE_ACCESS_SCOPE]},azureCloudOptions:{azureCloudInstance:a,tenant:n.YM.EMPTY_STRING},skipAuthorityMetadataCache:!1,supportsNestedAppAuth:!1,instanceAware:!1},h={cacheLocation:Xi.Al.SessionStorage,temporaryCacheLocation:Xi.Al.SessionStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!(!t||t.cacheLocation!==Xi.Al.LocalStorage),claimsBasedCachingEnabled:!1},d={loggerCallback:()=>{},logLevel:r.$.Info,piiLoggingEnabled:!1},p={...{...wt,loggerOptions:d,networkClient:c?new tr:Pt,navigationClient:new Zi,loadFrameTimeout:0,windowHashTimeout:i?.loadFrameTimeout||6e4,iframeHashTimeout:i?.loadFrameTimeout||1e4,navigateFrameWait:0,redirectNavigationTimeout:3e4,asyncPopups:!1,allowRedirectInIframe:!1,allowNativeBroker:!1,nativeBrokerHandshakeTimeout:i?.nativeBrokerHandshakeTimeout||2e3,pollIntervalMilliseconds:Xi.Q1.DEFAULT_POLL_INTERVAL_MS},...i,loggerOptions:i?.loggerOptions||d},g={application:{appName:n.YM.EMPTY_STRING,appVersion:n.YM.EMPTY_STRING},client:new Qi};if(e?.protocolMode!==o&&e?.OIDCOptions&&new r.V(p.loggerOptions).warning(JSON.stringify(Qe(je))),e?.protocolMode&&e.protocolMode!==s&&p?.allowNativeBroker)throw Qe(Ke);return{auth:{...u,...e,OIDCOptions:{...u.OIDCOptions,...e?.OIDCOptions}},cache:{...h,...t},system:p,telemetry:{...g,...l}}}(e,this.browserEnvironment);try{t=window[Xi.Al.SessionStorage]}catch(e){}const i=t?.getItem(Xi.L$),l=t?.getItem(Xi.P3)?.toLowerCase(),c="true"===l||"false"!==l&&void 0,u={...this.config.system.loggerOptions},h=i&&Object.keys(r.$).includes(i)?r.$[i]:void 0;h&&(u.loggerCallback=rr.loggerCallback,u.logLevel=h),void 0!==c&&(u.piiLoggingEnabled=c),this.logger=new r.V(u,"@azure/msal-browser",ir),this.available=!1}getConfig(){return this.config}getLogger(){return this.logger}isAvailable(){return this.available}isBrowserEnvironment(){return this.browserEnvironment}}class nr extends rr{getModuleName(){return nr.MODULE_NAME}getId(){return nr.ID}async initialize(){return this.available="undefined"!=typeof window,this.available}}nr.MODULE_NAME="",nr.ID="StandardOperatingContext";const sr="missing_kid_error",or="missing_alg_error",ar={[sr]:"The JOSE Header for the requested JWT, JWS or JWK object requires a keyId to be configured as the 'kid' header claim. No 'kid' value was provided.",[or]:"The JOSE Header for the requested JWT, JWS or JWK object requires an algorithm to be specified as the 'alg' header claim. No 'alg' value was provided."};class lr extends l.lR{constructor(e,t){super(e,t),this.name="JoseHeaderError",Object.setPrototypeOf(this,lr.prototype)}}function cr(e){return new lr(e,ar[e])}class ur{constructor(e){this.typ=e.typ,this.alg=e.alg,this.kid=e.kid}static getShrHeaderString(e){if(!e.kid)throw cr(sr);if(!e.alg)throw cr(or);const t=new ur({typ:e.typ||n.Lz.Pop,kid:e.kid,alg:e.alg});return JSON.stringify(t)}}function hr(e){return encodeURIComponent(pr(e).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"))}function dr(e){return gr(e).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function pr(e){return gr((new TextEncoder).encode(e))}function gr(e){const t=Array.from(e,e=>String.fromCodePoint(e)).join("");return btoa(t)}function fr(e){return(new TextDecoder).decode(function(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw(0,Ji.bD)(er._t)}const i=atob(t);return Uint8Array.from(i,e=>e.codePointAt(0)||0)}(e))}const mr="SHA-256",vr=new Uint8Array([1,0,1]),Cr="0123456789abcdef",yr=new Uint32Array(1),wr={name:"RSASSA-PKCS1-v1_5",hash:mr,modulusLength:2048,publicExponent:vr};async function Sr(e,t,i){t?.addQueueMeasurement(Ki,i);const r=(new TextEncoder).encode(e);return window.crypto.subtle.digest(mr,r)}function br(e){return window.crypto.getRandomValues(e)}function Er(){return window.crypto.getRandomValues(yr),yr[0]}function Ar(){const e=Date.now(),t=1024*Er()+(1023&Er()),i=new Uint8Array(16),r=Math.trunc(t/2**30),n=t&2**30-1,s=Er();i[0]=e/2**40,i[1]=e/2**32,i[2]=e/2**24,i[3]=e/65536,i[4]=e/256,i[5]=e,i[6]=112|r>>>8,i[7]=r,i[8]=128|n>>>24,i[9]=n>>>16,i[10]=n>>>8,i[11]=n,i[12]=s>>>24,i[13]=s>>>16,i[14]=s>>>8,i[15]=s;let o="";for(let e=0;e<i.length;e++)o+=Cr.charAt(i[e]>>>4),o+=Cr.charAt(15&i[e]),3!==e&&5!==e&&7!==e&&9!==e||(o+="-");return o}async function Tr(e){return window.crypto.subtle.exportKey(Xi.jb,e)}async function Mr(e){const t=await Sr(e);return dr(new Uint8Array(t))}class Rr{constructor(){this.dbName=Xi.$u,this.version=Xi.G8,this.tableName=Xi.WJ,this.dbOpen=!1}async open(){return new Promise((e,t)=>{const i=window.indexedDB.open(this.dbName,this.version);i.addEventListener("upgradeneeded",e=>{e.target.result.createObjectStore(this.tableName)}),i.addEventListener("success",t=>{const i=t;this.db=i.target.result,this.dbOpen=!0,e()}),i.addEventListener("error",()=>t((0,Ji.bD)(er.MG)))})}closeConnection(){const e=this.db;e&&this.dbOpen&&(e.close(),this.dbOpen=!1)}async validateDbIsOpen(){if(!this.dbOpen)return this.open()}async getItem(e){return await this.validateDbIsOpen(),new Promise((t,i)=>{if(!this.db)return i((0,Ji.bD)(er.rn));const r=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).get(e);r.addEventListener("success",e=>{const i=e;this.closeConnection(),t(i.target.result)}),r.addEventListener("error",e=>{this.closeConnection(),i(e)})})}async setItem(e,t){return await this.validateDbIsOpen(),new Promise((i,r)=>{if(!this.db)return r((0,Ji.bD)(er.rn));const n=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).put(t,e);n.addEventListener("success",()=>{this.closeConnection(),i()}),n.addEventListener("error",e=>{this.closeConnection(),r(e)})})}async removeItem(e){return await this.validateDbIsOpen(),new Promise((t,i)=>{if(!this.db)return i((0,Ji.bD)(er.rn));const r=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).delete(e);r.addEventListener("success",()=>{this.closeConnection(),t()}),r.addEventListener("error",e=>{this.closeConnection(),i(e)})})}async getKeys(){return await this.validateDbIsOpen(),new Promise((e,t)=>{if(!this.db)return t((0,Ji.bD)(er.rn));const i=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).getAllKeys();i.addEventListener("success",t=>{const i=t;this.closeConnection(),e(i.target.result)}),i.addEventListener("error",e=>{this.closeConnection(),t(e)})})}async containsKey(e){return await this.validateDbIsOpen(),new Promise((t,i)=>{if(!this.db)return i((0,Ji.bD)(er.rn));const r=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).count(e);r.addEventListener("success",e=>{const i=e;this.closeConnection(),t(1===i.target.result)}),r.addEventListener("error",e=>{this.closeConnection(),i(e)})})}async deleteDatabase(){return this.db&&this.dbOpen&&this.closeConnection(),new Promise((e,t)=>{const i=window.indexedDB.deleteDatabase(Xi.$u),r=setTimeout(()=>t(!1),200);i.addEventListener("success",()=>(clearTimeout(r),e(!0))),i.addEventListener("blocked",()=>(clearTimeout(r),e(!0))),i.addEventListener("error",()=>(clearTimeout(r),t(!1)))})}}class _r{constructor(){this.cache=new Map}getItem(e){return this.cache.get(e)||null}setItem(e,t){this.cache.set(e,t)}removeItem(e){this.cache.delete(e)}getKeys(){const e=[];return this.cache.forEach((t,i)=>{e.push(i)}),e}containsKey(e){return this.cache.has(e)}clear(){this.cache.clear()}}class Pr{constructor(e){this.inMemoryCache=new _r,this.indexedDBCache=new Rr,this.logger=e}handleDatabaseAccessError(e){if(!(e instanceof Ji.jT&&e.errorCode===er.MG))throw e;this.logger.error("Could not access persistent storage. This may be caused by browser privacy features which block persistent storage in third-party contexts.")}async getItem(e){const t=this.inMemoryCache.getItem(e);if(!t)try{return this.logger.verbose("Queried item not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.getItem(e)}catch(e){this.handleDatabaseAccessError(e)}return t}async setItem(e,t){this.inMemoryCache.setItem(e,t);try{await this.indexedDBCache.setItem(e,t)}catch(e){this.handleDatabaseAccessError(e)}}async removeItem(e){this.inMemoryCache.removeItem(e);try{await this.indexedDBCache.removeItem(e)}catch(e){this.handleDatabaseAccessError(e)}}async getKeys(){const e=this.inMemoryCache.getKeys();if(0===e.length)try{return this.logger.verbose("In-memory cache is empty, now querying persistent storage."),await this.indexedDBCache.getKeys()}catch(e){this.handleDatabaseAccessError(e)}return e}async containsKey(e){const t=this.inMemoryCache.containsKey(e);if(!t)try{return this.logger.verbose("Key not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.containsKey(e)}catch(e){this.handleDatabaseAccessError(e)}return t}clearInMemory(){this.logger.verbose("Deleting in-memory keystore"),this.inMemoryCache.clear(),this.logger.verbose("In-memory keystore deleted")}async clearPersistent(){try{this.logger.verbose("Deleting persistent keystore");const e=await this.indexedDBCache.deleteDatabase();return e&&this.logger.verbose("Persistent keystore deleted"),e}catch(e){return this.handleDatabaseAccessError(e),!1}}}class xr{constructor(e,t){this.logger=e,function(e){if(!("crypto"in window))throw e.error("BrowserCrypto: crypto interface is unavailable"),(0,Ji.bD)(er.rc);e.verbose("BrowserCrypto: modern crypto interface available")}(e),this.cache=new Pr(this.logger),this.performanceClient=t}createNewGuid(){return Ar()}base64Encode(e){return pr(e)}base64Decode(e){return fr(e)}base64UrlEncode(e){return hr(e)}encodeKid(e){return this.base64UrlEncode(JSON.stringify({kid:e}))}async getPublicKeyThumbprint(e){const t=this.performanceClient?.startMeasurement(Ft,e.correlationId),i=await async function(e,t){return window.crypto.subtle.generateKey(wr,e,t)}(xr.EXTRACTABLE,xr.POP_KEY_USAGES),r=await Tr(i.publicKey),n=Dr({e:r.e,kty:r.kty,n:r.n}),s=await this.hashString(n),o=await Tr(i.privateKey),a=await async function(e){return window.crypto.subtle.importKey(Xi.jb,e,wr,!1,["sign"])}(o);return await this.cache.setItem(s,{privateKey:a,publicKey:i.publicKey,requestMethod:e.resourceRequestMethod,requestUri:e.resourceRequestUri}),t&&t.end({success:!0}),s}async removeTokenBindingKey(e){return await this.cache.removeItem(e),!await this.cache.containsKey(e)}async clearKeystore(){this.cache.clearInMemory();try{return await this.cache.clearPersistent(),!0}catch(e){return e instanceof Error?this.logger.error(`Clearing keystore failed with error: ${e.message}`):this.logger.error("Clearing keystore failed with unknown error"),!1}}async signJwt(e,t,i,r){const n=this.performanceClient?.startMeasurement(kt,r),s=await this.cache.getItem(t);if(!s)throw(0,Ji.bD)(er.e0);const o=await Tr(s.publicKey),a=Dr(o),l=hr(JSON.stringify({kid:t})),c=hr(ur.getShrHeaderString({...i?.header,alg:o.alg,kid:l}));e.cnf={jwk:JSON.parse(a)};const u=`${c}.${hr(JSON.stringify(e))}`,h=(new TextEncoder).encode(u),d=await async function(e,t){return window.crypto.subtle.sign(wr,e,t)}(s.privateKey,h),p=`${u}.${dr(new Uint8Array(d))}`;return n&&n.end({success:!0}),p}async hashString(e){return Mr(e)}}function Dr(e){return JSON.stringify(e,Object.keys(e).sort())}xr.POP_KEY_USAGES=["sign","verify"],xr.EXTRACTABLE=!0;const Ir=(e,t,i,r,n)=>(...s)=>{i.trace(`Executing function ${t}`);const o=r?.startMeasurement(t,n);if(n){const e=t+"CallCount";r?.incrementFields({[e]:1},n)}try{const r=e(...s);return o?.end({success:!0}),i.trace(`Returning result from ${t}`),r}catch(e){i.trace(`Error occurred in ${t}`);try{i.trace(JSON.stringify(e))}catch(e){i.trace("Unable to print error message.")}throw o?.end({success:!1},e),e}},Lr=(e,t,i,r,n)=>(...s)=>{i.trace(`Executing function ${t}`);const o=r?.startMeasurement(t,n);if(n){const e=t+"CallCount";r?.incrementFields({[e]:1},n)}return r?.setPreQueueTime(t,n),e(...s).then(e=>(i.trace(`Returning result from ${t}`),o?.end({success:!0}),e)).catch(e=>{i.trace(`Error occurred in ${t}`);try{i.trace(JSON.stringify(e))}catch(e){i.trace("Unable to print error message.")}throw o?.end({success:!1},e),e})};class Nr{constructor(e,t,i,r){this.networkInterface=e,this.logger=t,this.performanceClient=i,this.correlationId=r}async detectRegion(e,t){this.performanceClient?.addQueueMeasurement(Li,this.correlationId);let i=e;if(i)t.region_source=n.jZ.ENVIRONMENT_VARIABLE;else{const e=Nr.IMDS_OPTIONS;try{const r=await Lr(this.getRegionFromIMDS.bind(this),Ni,this.logger,this.performanceClient,this.correlationId)(n.YM.IMDS_VERSION,e);if(r.status===n.Kk.httpSuccess&&(i=r.body,t.region_source=n.jZ.IMDS),r.status===n.Kk.httpBadRequest){const r=await Lr(this.getCurrentVersion.bind(this),Oi,this.logger,this.performanceClient,this.correlationId)(e);if(!r)return t.region_source=n.jZ.FAILED_AUTO_DETECTION,null;const s=await Lr(this.getRegionFromIMDS.bind(this),Ni,this.logger,this.performanceClient,this.correlationId)(r,e);s.status===n.Kk.httpSuccess&&(i=s.body,t.region_source=n.jZ.IMDS)}}catch(e){return t.region_source=n.jZ.FAILED_AUTO_DETECTION,null}}return i||(t.region_source=n.jZ.FAILED_AUTO_DETECTION),i||null}async getRegionFromIMDS(e,t){return this.performanceClient?.addQueueMeasurement(Ni,this.correlationId),this.networkInterface.sendGetRequestAsync(`${n.YM.IMDS_ENDPOINT}?api-version=${e}&format=text`,t,n.YM.IMDS_TIMEOUT)}async getCurrentVersion(e){this.performanceClient?.addQueueMeasurement(Oi,this.correlationId);try{const t=await this.networkInterface.sendGetRequestAsync(`${n.YM.IMDS_ENDPOINT}?format=json`,e);return t.status===n.Kk.httpBadRequest&&t.body&&t.body["newest-versions"]&&t.body["newest-versions"].length>0?t.body["newest-versions"][0]:null}catch(e){return null}}}Nr.IMDS_OPTIONS={headers:{Metadata:"true"}};class Or{constructor(e,t,i,r,n,s,o,a){this.canonicalAuthority=e,this._canonicalAuthority.validateAsUri(),this.networkInterface=t,this.cacheManager=i,this.authorityOptions=r,this.regionDiscoveryMetadata={region_used:void 0,region_source:void 0,region_outcome:void 0},this.logger=n,this.performanceClient=o,this.correlationId=s,this.managedIdentity=a||!1,this.regionDiscovery=new Nr(t,this.logger,this.performanceClient,this.correlationId)}getAuthorityType(e){if(e.HostNameAndPort.endsWith(n.YM.CIAM_AUTH_URL))return 3;const t=e.PathSegments;if(t.length)switch(t[0].toLowerCase()){case n.YM.ADFS:return 1;case n.YM.DSTS:return 2}return 0}get authorityType(){return this.getAuthorityType(this.canonicalAuthorityUrlComponents)}get protocolMode(){return this.authorityOptions.protocolMode}get options(){return this.authorityOptions}get canonicalAuthority(){return this._canonicalAuthority.urlString}set canonicalAuthority(e){this._canonicalAuthority=new lt(e),this._canonicalAuthority.validateAsUri(),this._canonicalAuthorityUrlComponents=null}get canonicalAuthorityUrlComponents(){return this._canonicalAuthorityUrlComponents||(this._canonicalAuthorityUrlComponents=this._canonicalAuthority.getUrlComponents()),this._canonicalAuthorityUrlComponents}get hostnameAndPort(){return this.canonicalAuthorityUrlComponents.HostNameAndPort.toLowerCase()}get tenant(){return this.canonicalAuthorityUrlComponents.PathSegments[0]}get authorizationEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.authorization_endpoint);throw te(p)}get tokenEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint);throw te(p)}get deviceCodeEndpoint(){if(this.discoveryComplete())return this.replacePath(this.metadata.token_endpoint.replace("/token","/devicecode"));throw te(p)}get endSessionEndpoint(){if(this.discoveryComplete()){if(!this.metadata.end_session_endpoint)throw te(K);return this.replacePath(this.metadata.end_session_endpoint)}throw te(p)}get selfSignedJwtAudience(){if(this.discoveryComplete())return this.replacePath(this.metadata.issuer);throw te(p)}get jwksUri(){if(this.discoveryComplete())return this.replacePath(this.metadata.jwks_uri);throw te(p)}canReplaceTenant(e){return 1===e.PathSegments.length&&!Or.reservedTenantDomains.has(e.PathSegments[0])&&0===this.getAuthorityType(e)&&this.protocolMode===s}replaceTenant(e){return e.replace(/{tenant}|{tenantid}/g,this.tenant)}replacePath(e){let t=e;const i=new lt(this.metadata.canonical_authority).getUrlComponents(),r=i.PathSegments;return this.canonicalAuthorityUrlComponents.PathSegments.forEach((e,n)=>{let s=r[n];if(0===n&&this.canReplaceTenant(i)){const e=new lt(this.metadata.authorization_endpoint).getUrlComponents().PathSegments[0];s!==e&&(this.logger.verbose(`Replacing tenant domain name ${s} with id ${e}`),s=e)}e!==s&&(t=t.replace(`/${s}/`,`/${e}/`))}),this.replaceTenant(t)}get defaultOpenIdConfigurationEndpoint(){const e=this.hostnameAndPort;return this.canonicalAuthority.endsWith("v2.0/")||1===this.authorityType||this.protocolMode!==s&&!this.isAliasOfKnownMicrosoftAuthority(e)?`${this.canonicalAuthority}.well-known/openid-configuration`:`${this.canonicalAuthority}v2.0/.well-known/openid-configuration`}discoveryComplete(){return!!this.metadata}async resolveEndpointsAsync(){this.performanceClient?.addQueueMeasurement(Ri,this.correlationId);const e=this.getCurrentMetadataEntity(),t=await Lr(this.updateCloudDiscoveryMetadata.bind(this),Pi,this.logger,this.performanceClient,this.correlationId)(e);this.canonicalAuthority=this.canonicalAuthority.replace(this.hostnameAndPort,e.preferred_network);const i=await Lr(this.updateEndpointMetadata.bind(this),Di,this.logger,this.performanceClient,this.correlationId)(e);this.updateCachedMetadata(e,t,{source:i}),this.performanceClient?.addFields({cloudDiscoverySource:t,authorityEndpointSource:i},this.correlationId)}getCurrentMetadataEntity(){let e=this.cacheManager.getAuthorityMetadataByAlias(this.hostnameAndPort);return e||(e={aliases:[],preferred_cache:this.hostnameAndPort,preferred_network:this.hostnameAndPort,canonical_authority:this.canonicalAuthority,authorization_endpoint:"",token_endpoint:"",end_session_endpoint:"",issuer:"",aliasesFromNetwork:!1,endpointsFromNetwork:!1,expiresAt:be(),jwks_uri:""}),e}updateCachedMetadata(e,t,i){t!==n.E_.CACHE&&i?.source!==n.E_.CACHE&&(e.expiresAt=be(),e.canonical_authority=this.canonicalAuthority);const r=this.cacheManager.generateAuthorityMetadataCacheKey(e.preferred_cache);this.cacheManager.setAuthorityMetadata(r,e),this.metadata=e}async updateEndpointMetadata(e){this.performanceClient?.addQueueMeasurement(Di,this.correlationId);const t=this.updateEndpointMetadataFromLocalSources(e);if(t)return t.source===n.E_.HARDCODED_VALUES&&this.authorityOptions.azureRegionConfiguration?.azureRegion&&t.metadata&&(Ee(e,await Lr(this.updateMetadataWithRegionalInformation.bind(this),Ii,this.logger,this.performanceClient,this.correlationId)(t.metadata),!1),e.canonical_authority=this.canonicalAuthority),t.source;let i=await Lr(this.getEndpointMetadataFromNetwork.bind(this),xi,this.logger,this.performanceClient,this.correlationId)();if(i)return this.authorityOptions.azureRegionConfiguration?.azureRegion&&(i=await Lr(this.updateMetadataWithRegionalInformation.bind(this),Ii,this.logger,this.performanceClient,this.correlationId)(i)),Ee(e,i,!0),n.E_.NETWORK;throw te(f,this.defaultOpenIdConfigurationEndpoint)}updateEndpointMetadataFromLocalSources(e){this.logger.verbose("Attempting to get endpoint metadata from authority configuration");const t=this.getEndpointMetadataFromConfig();if(t)return this.logger.verbose("Found endpoint metadata in authority configuration"),Ee(e,t,!1),{source:n.E_.CONFIG};if(this.logger.verbose("Did not find endpoint metadata in the config... Attempting to get endpoint metadata from the hardcoded values."),this.authorityOptions.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get endpoint metadata from the network metadata cache.");else{const t=this.getEndpointMetadataFromHardcodedValues();if(t)return Ee(e,t,!1),{source:n.E_.HARDCODED_VALUES,metadata:t};this.logger.verbose("Did not find endpoint metadata in hardcoded values... Attempting to get endpoint metadata from the network metadata cache.")}const i=Te(e);return this.isAuthoritySameType(e)&&e.endpointsFromNetwork&&!i?(this.logger.verbose("Found endpoint metadata in the cache."),{source:n.E_.CACHE}):(i&&this.logger.verbose("The metadata entity is expired."),null)}isAuthoritySameType(e){return new lt(e.canonical_authority).getUrlComponents().PathSegments.length===this.canonicalAuthorityUrlComponents.PathSegments.length}getEndpointMetadataFromConfig(){if(this.authorityOptions.authorityMetadata)try{return JSON.parse(this.authorityOptions.authorityMetadata)}catch(e){throw Qe(Ve)}return null}async getEndpointMetadataFromNetwork(){this.performanceClient?.addQueueMeasurement(xi,this.correlationId);const e={},t=this.defaultOpenIdConfigurationEndpoint;this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: attempting to retrieve OAuth endpoints from ${t}`);try{const i=await this.networkInterface.sendGetRequestAsync(t,e),r=function(e){return e.hasOwnProperty("authorization_endpoint")&&e.hasOwnProperty("token_endpoint")&&e.hasOwnProperty("issuer")&&e.hasOwnProperty("jwks_uri")}(i.body);return r?i.body:(this.logger.verbose("Authority.getEndpointMetadataFromNetwork: could not parse response as OpenID configuration"),null)}catch(e){return this.logger.verbose(`Authority.getEndpointMetadataFromNetwork: ${e}`),null}}getEndpointMetadataFromHardcodedValues(){return this.hostnameAndPort in ct?ct[this.hostnameAndPort]:null}async updateMetadataWithRegionalInformation(e){this.performanceClient?.addQueueMeasurement(Ii,this.correlationId);const t=this.authorityOptions.azureRegionConfiguration?.azureRegion;if(t){if(t!==n.YM.AZURE_REGION_AUTO_DISCOVER_FLAG)return this.regionDiscoveryMetadata.region_outcome=n._2.CONFIGURED_NO_AUTO_DETECTION,this.regionDiscoveryMetadata.region_used=t,Or.replaceWithRegionalInformation(e,t);const i=await Lr(this.regionDiscovery.detectRegion.bind(this.regionDiscovery),Li,this.logger,this.performanceClient,this.correlationId)(this.authorityOptions.azureRegionConfiguration?.environmentRegion,this.regionDiscoveryMetadata);if(i)return this.regionDiscoveryMetadata.region_outcome=n._2.AUTO_DETECTION_REQUESTED_SUCCESSFUL,this.regionDiscoveryMetadata.region_used=i,Or.replaceWithRegionalInformation(e,i);this.regionDiscoveryMetadata.region_outcome=n._2.AUTO_DETECTION_REQUESTED_FAILED}return e}async updateCloudDiscoveryMetadata(e){this.performanceClient?.addQueueMeasurement(Pi,this.correlationId);const t=this.updateCloudDiscoveryMetadataFromLocalSources(e);if(t)return t;const i=await Lr(this.getCloudDiscoveryMetadataFromNetwork.bind(this),_i,this.logger,this.performanceClient,this.correlationId)();if(i)return Ae(e,i,!0),n.E_.NETWORK;throw Qe(He)}updateCloudDiscoveryMetadataFromLocalSources(e){this.logger.verbose("Attempting to get cloud discovery metadata  from authority configuration"),this.logger.verbosePii(`Known Authorities: ${this.authorityOptions.knownAuthorities||n.YM.NOT_APPLICABLE}`),this.logger.verbosePii(`Authority Metadata: ${this.authorityOptions.authorityMetadata||n.YM.NOT_APPLICABLE}`),this.logger.verbosePii(`Canonical Authority: ${e.canonical_authority||n.YM.NOT_APPLICABLE}`);const t=this.getCloudDiscoveryMetadataFromConfig();if(t)return this.logger.verbose("Found cloud discovery metadata in authority configuration"),Ae(e,t,!1),n.E_.CONFIG;if(this.logger.verbose("Did not find cloud discovery metadata in the config... Attempting to get cloud discovery metadata from the hardcoded values."),this.options.skipAuthorityMetadataCache)this.logger.verbose("Skipping hardcoded cloud discovery metadata cache since skipAuthorityMetadataCache is set to true. Attempting to get cloud discovery metadata from the network metadata cache.");else{const t=(i=this.hostnameAndPort,pt(ut.metadata,i));if(t)return this.logger.verbose("Found cloud discovery metadata from hardcoded values."),Ae(e,t,!1),n.E_.HARDCODED_VALUES;this.logger.verbose("Did not find cloud discovery metadata in hardcoded values... Attempting to get cloud discovery metadata from the network metadata cache.")}var i;const r=Te(e);return this.isAuthoritySameType(e)&&e.aliasesFromNetwork&&!r?(this.logger.verbose("Found cloud discovery metadata in the cache."),n.E_.CACHE):(r&&this.logger.verbose("The metadata entity is expired."),null)}getCloudDiscoveryMetadataFromConfig(){if(3===this.authorityType)return this.logger.verbose("CIAM authorities do not support cloud discovery metadata, generate the aliases from authority host."),Or.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort);if(this.authorityOptions.cloudDiscoveryMetadata){this.logger.verbose("The cloud discovery metadata has been provided as a network response, in the config.");try{this.logger.verbose("Attempting to parse the cloud discovery metadata.");const e=pt(JSON.parse(this.authorityOptions.cloudDiscoveryMetadata).metadata,this.hostnameAndPort);if(this.logger.verbose("Parsed the cloud discovery metadata."),e)return this.logger.verbose("There is returnable metadata attached to the parsed cloud discovery metadata."),e;this.logger.verbose("There is no metadata attached to the parsed cloud discovery metadata.")}catch(e){throw this.logger.verbose("Unable to parse the cloud discovery metadata. Throwing Invalid Cloud Discovery Metadata Error."),Qe(Ge)}}return this.isInKnownAuthorities()?(this.logger.verbose("The host is included in knownAuthorities. Creating new cloud discovery metadata from the host."),Or.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)):null}async getCloudDiscoveryMetadataFromNetwork(){this.performanceClient?.addQueueMeasurement(_i,this.correlationId);const e=`${n.YM.AAD_INSTANCE_DISCOVERY_ENDPT}${this.canonicalAuthority}oauth2/v2.0/authorize`,t={};let i=null;try{const r=await this.networkInterface.sendGetRequestAsync(e,t);let s,o;if(function(e){return e.hasOwnProperty("tenant_discovery_endpoint")&&e.hasOwnProperty("metadata")}(r.body))s=r.body,o=s.metadata,this.logger.verbosePii(`tenant_discovery_endpoint is: ${s.tenant_discovery_endpoint}`);else{if(!function(e){return e.hasOwnProperty("error")&&e.hasOwnProperty("error_description")}(r.body))return this.logger.error("AAD did not return a CloudInstanceDiscoveryResponse or CloudInstanceDiscoveryErrorResponse"),null;if(this.logger.warning(`A CloudInstanceDiscoveryErrorResponse was returned. The cloud instance discovery network request's status code is: ${r.status}`),s=r.body,s.error===n.YM.INVALID_INSTANCE)return this.logger.error("The CloudInstanceDiscoveryErrorResponse error is invalid_instance."),null;this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error is ${s.error}`),this.logger.warning(`The CloudInstanceDiscoveryErrorResponse error description is ${s.error_description}`),this.logger.warning("Setting the value of the CloudInstanceDiscoveryMetadata (returned from the network) to []"),o=[]}this.logger.verbose("Attempting to find a match between the developer's authority and the CloudInstanceDiscoveryMetadata returned from the network request."),i=pt(o,this.hostnameAndPort)}catch(e){if(e instanceof l.lR)this.logger.error(`There was a network error while attempting to get the cloud discovery instance metadata.\nError: ${e.errorCode}\nError Description: ${e.errorMessage}`);else{const t=e;this.logger.error(`A non-MSALJS error was thrown while attempting to get the cloud instance discovery metadata.\nError: ${t.name}\nError Description: ${t.message}`)}return null}return i||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),i=Or.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),i}isInKnownAuthorities(){return this.authorityOptions.knownAuthorities.filter(e=>e&&lt.getDomainFromUrl(e).toLowerCase()===this.hostnameAndPort).length>0}static generateAuthority(e,t){let i;if(t&&t.azureCloudInstance!==a){const e=t.tenant?t.tenant:n.YM.DEFAULT_COMMON_TENANT;i=`${t.azureCloudInstance}/${e}/`}return i||e}static createCloudDiscoveryMetadataFromHost(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}}getPreferredCache(){if(this.managedIdentity)return n.YM.DEFAULT_AUTHORITY_HOST;if(this.discoveryComplete())return this.metadata.preferred_cache;throw te(p)}isAlias(e){return this.metadata.aliases.indexOf(e)>-1}isAliasOfKnownMicrosoftAuthority(e){return ht.has(e)}static isPublicCloudAuthority(e){return n.YM.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0}static buildRegionalAuthorityString(e,t,i){const r=new lt(e);r.validateAsUri();const s=r.getUrlComponents();let o=`${t}.${s.HostNameAndPort}`;this.isPublicCloudAuthority(s.HostNameAndPort)&&(o=`${t}.${n.YM.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX}`);const a=lt.constructAuthorityUriFromObject({...r.getUrlComponents(),HostNameAndPort:o}).urlString;return i?`${a}?${i}`:a}static replaceWithRegionalInformation(e,t){const i={...e};return i.authorization_endpoint=Or.buildRegionalAuthorityString(i.authorization_endpoint,t),i.token_endpoint=Or.buildRegionalAuthorityString(i.token_endpoint,t),i.end_session_endpoint&&(i.end_session_endpoint=Or.buildRegionalAuthorityString(i.end_session_endpoint,t)),i}static transformCIAMAuthority(e){let t=e;const i=new lt(e).getUrlComponents();return 0===i.PathSegments.length&&i.HostNameAndPort.endsWith(n.YM.CIAM_AUTH_URL)&&(t=`${t}${i.HostNameAndPort.split(".")[0]}${n.YM.AAD_TENANT_DOMAIN_SUFFIX}`),t}}function Fr(e){return e.endsWith(n.YM.FORWARD_SLASH)?e:`${e}${n.YM.FORWARD_SLASH}`}Or.reservedTenantDomains=new Set(["{tenant}","{tenantid}",n.v2.COMMON,n.v2.CONSUMERS,n.v2.ORGANIZATIONS]);const kr="no_tokens_found",Gr="native_account_unavailable",Vr="refresh_token_expired",Hr="bad_token",Br=["interaction_required","consent_required","login_required",Hr],zr=["message_only","additional_action","basic_action","user_password_expired","consent_required","bad_token"],Ur={[kr]:"No refresh token found in the cache. Please sign-in.",[Gr]:"The requested account is not available in the native broker. It may have been deleted or logged out. Please sign-in again using an interactive API.",[Vr]:"Refresh token has expired.",[Hr]:"Identity provider returned bad_token due to an expired or invalid refresh token. Please invoke an interactive API to resolve."};class Wr extends l.lR{constructor(e,t,i,r,s,o,a,l){super(e,t,i),Object.setPrototypeOf(this,Wr.prototype),this.timestamp=r||n.YM.EMPTY_STRING,this.traceId=s||n.YM.EMPTY_STRING,this.correlationId=o||n.YM.EMPTY_STRING,this.claims=a||n.YM.EMPTY_STRING,this.name="InteractionRequiredAuthError",this.errorNo=l}}function jr(e,t,i){const r=!!e&&Br.indexOf(e)>-1,n=!!i&&zr.indexOf(i)>-1,s=!!t&&Br.some(e=>t.indexOf(e)>-1);return r||s||n}function Kr(e){return new Wr(e,Ur[e])}class $r{static setRequestState(e,t,i){const r=$r.generateLibraryState(e,i);return t?`${r}${n.YM.RESOURCE_DELIM}${t}`:r}static generateLibraryState(e,t){if(!e)throw te(k);const i={id:e.createNewGuid()};t&&(i.meta=t);const r=JSON.stringify(i);return e.base64Encode(r)}static parseRequestState(e,t){if(!e)throw te(k);if(!t)throw te(v);try{const i=t.split(n.YM.RESOURCE_DELIM),r=i[0],s=i.length>1?i.slice(1).join(n.YM.RESOURCE_DELIM):n.YM.EMPTY_STRING,o=e.base64Decode(r),a=JSON.parse(o);return{userRequestState:s||n.YM.EMPTY_STRING,libraryState:a}}catch(e){throw te(v)}}}const qr="home_account_id",Yr="UPN";var Qr=i(24680),Xr=i(85362);class Zr{constructor(e){this.validateWindowStorage(e),this.windowStorage=window[e]}validateWindowStorage(e){if(e!==Xi.Al.LocalStorage&&e!==Xi.Al.SessionStorage||!window[e])throw(0,Qr.jz)(Xr.xz)}getItem(e){return this.windowStorage.getItem(e)}setItem(e,t){this.windowStorage.setItem(e,t)}removeItem(e){this.windowStorage.removeItem(e)}getKeys(){return Object.keys(this.windowStorage)}containsKey(e){return this.windowStorage.hasOwnProperty(e)}}function Jr(e,t){if(!t)return null;try{return $r.parseRequestState(e,t).libraryState.meta}catch(e){throw te(v)}}class en extends Ct{constructor(e,t,i,r,n,s){super(e,i,r,n),this.COOKIE_LIFE_MULTIPLIER=864e5,this.cacheConfig=t,this.logger=r,this.internalStorage=new _r,this.browserStorage=this.setupBrowserStorage(this.cacheConfig.cacheLocation),this.temporaryCacheStorage=this.setupTemporaryCacheStorage(this.cacheConfig.temporaryCacheLocation,this.cacheConfig.cacheLocation),t.cacheMigrationEnabled&&(this.migrateCacheEntries(),this.createKeyMaps()),this.performanceClient=s}setupBrowserStorage(e){switch(e){case Xi.Al.LocalStorage:case Xi.Al.SessionStorage:try{return new Zr(e)}catch(e){this.logger.verbose(e);break}}return this.cacheConfig.cacheLocation=Xi.Al.MemoryStorage,new _r}setupTemporaryCacheStorage(e,t){switch(t){case Xi.Al.LocalStorage:case Xi.Al.SessionStorage:try{return new Zr(e||Xi.Al.SessionStorage)}catch(e){return this.logger.verbose(e),this.internalStorage}case Xi.Al.MemoryStorage:default:return this.internalStorage}}migrateCacheEntries(){const e=`${n.YM.CACHE_PREFIX}.${n.Gd.ID_TOKEN}`,t=`${n.YM.CACHE_PREFIX}.${n.Gd.CLIENT_INFO}`,i=`${n.YM.CACHE_PREFIX}.${n.Gd.ERROR}`,r=`${n.YM.CACHE_PREFIX}.${n.Gd.ERROR_DESC}`,s=[this.browserStorage.getItem(e),this.browserStorage.getItem(t),this.browserStorage.getItem(i),this.browserStorage.getItem(r)];[n.Gd.ID_TOKEN,n.Gd.CLIENT_INFO,n.Gd.ERROR,n.Gd.ERROR_DESC].forEach((e,t)=>{const i=s[t];i&&this.setTemporaryCache(e,i,!0)})}createKeyMaps(){this.logger.trace("BrowserCacheManager - createKeyMaps called.");const e=this.getItem(Xi.dh.ACCOUNT_KEYS),t=this.getItem(`${Xi.dh.TOKEN_KEYS}.${this.clientId}`);e&&t?this.logger.verbose("BrowserCacheManager:createKeyMaps - account and token key maps already exist, skipping migration."):this.browserStorage.getKeys().forEach(e=>{if(this.isCredentialKey(e)){const t=this.getItem(e);if(t){const i=this.validateAndParseJson(t);if(i&&i.hasOwnProperty("credentialType"))switch(i.credentialType){case n.aG.ID_TOKEN:if(fe(i)){this.logger.trace("BrowserCacheManager:createKeyMaps - idToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - idToken with key: ${e} found, saving key to token key map`);const t=i,r=this.updateCredentialCacheKey(e,t);return void this.addTokenKey(r,n.aG.ID_TOKEN)}this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching idToken schema with value containing idToken credentialType field but value failed IdTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed idToken validation on key: ${e}`);break;case n.aG.ACCESS_TOKEN:case n.aG.ACCESS_TOKEN_WITH_AUTH_SCHEME:if(ge(i)){this.logger.trace("BrowserCacheManager:createKeyMaps - accessToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - accessToken with key: ${e} found, saving key to token key map`);const t=i,r=this.updateCredentialCacheKey(e,t);return void this.addTokenKey(r,n.aG.ACCESS_TOKEN)}this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching accessToken schema with value containing accessToken credentialType field but value failed AccessTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed accessToken validation on key: ${e}`);break;case n.aG.REFRESH_TOKEN:if(me(i)){this.logger.trace("BrowserCacheManager:createKeyMaps - refreshToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - refreshToken with key: ${e} found, saving key to token key map`);const t=i,r=this.updateCredentialCacheKey(e,t);return void this.addTokenKey(r,n.aG.REFRESH_TOKEN)}this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching refreshToken schema with value containing refreshToken credentialType field but value failed RefreshTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed refreshToken validation on key: ${e}`)}}}if(this.isAccountKey(e)){const t=this.getItem(e);if(t){const i=this.validateAndParseJson(t);i&&st.isAccountEntity(i)&&(this.logger.trace("BrowserCacheManager:createKeyMaps - account found, saving key to account key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - account with key: ${e} found, saving key to account key map`),this.addAccountKeyToMap(e))}}})}validateAndParseJson(e){try{const t=JSON.parse(e);return t&&"object"==typeof t?t:null}catch(e){return null}}getItem(e){return this.browserStorage.getItem(e)}setItem(e,t){this.browserStorage.setItem(e,t)}getAccount(e,t){this.logger.trace("BrowserCacheManager.getAccount called");const i=this.getCachedAccountEntity(e);return this.updateOutdatedCachedAccount(e,i,t)}getCachedAccountEntity(e){const t=this.getItem(e);if(!t)return this.removeAccountKeyFromMap(e),null;const i=this.validateAndParseJson(t);return i&&st.isAccountEntity(i)?Ct.toObject(new st,i):(this.removeAccountKeyFromMap(e),null)}setAccount(e){this.logger.trace("BrowserCacheManager.setAccount called");const t=e.generateAccountKey();this.setItem(t,JSON.stringify(e)),this.addAccountKeyToMap(t)}getAccountKeys(){this.logger.trace("BrowserCacheManager.getAccountKeys called");const e=this.getItem(Xi.dh.ACCOUNT_KEYS);return e?JSON.parse(e):(this.logger.verbose("BrowserCacheManager.getAccountKeys - No account keys found"),[])}addAccountKeyToMap(e){this.logger.trace("BrowserCacheManager.addAccountKeyToMap called"),this.logger.tracePii(`BrowserCacheManager.addAccountKeyToMap called with key: ${e}`);const t=this.getAccountKeys();-1===t.indexOf(e)?(t.push(e),this.setItem(Xi.dh.ACCOUNT_KEYS,JSON.stringify(t)),this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key added")):this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key already exists in map")}removeAccountKeyFromMap(e){this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap called"),this.logger.tracePii(`BrowserCacheManager.removeAccountKeyFromMap called with key: ${e}`);const t=this.getAccountKeys(),i=t.indexOf(e);i>-1?(t.splice(i,1),this.setItem(Xi.dh.ACCOUNT_KEYS,JSON.stringify(t)),this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap account key removed")):this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap key not found in existing map")}async removeAccount(e){super.removeAccount(e),this.removeAccountKeyFromMap(e)}removeOutdatedAccount(e){this.removeItem(e),this.removeAccountKeyFromMap(e)}removeIdToken(e){super.removeIdToken(e),this.removeTokenKey(e,n.aG.ID_TOKEN)}async removeAccessToken(e){super.removeAccessToken(e),this.removeTokenKey(e,n.aG.ACCESS_TOKEN)}removeRefreshToken(e){super.removeRefreshToken(e),this.removeTokenKey(e,n.aG.REFRESH_TOKEN)}getTokenKeys(){this.logger.trace("BrowserCacheManager.getTokenKeys called");const e=this.getItem(`${Xi.dh.TOKEN_KEYS}.${this.clientId}`);if(e){const t=this.validateAndParseJson(e);if(t&&t.hasOwnProperty("idToken")&&t.hasOwnProperty("accessToken")&&t.hasOwnProperty("refreshToken"))return t;this.logger.error("BrowserCacheManager.getTokenKeys - Token keys found but in an unknown format. Returning empty key map.")}else this.logger.verbose("BrowserCacheManager.getTokenKeys - No token keys found");return{idToken:[],accessToken:[],refreshToken:[]}}addTokenKey(e,t){this.logger.trace("BrowserCacheManager addTokenKey called");const i=this.getTokenKeys();switch(t){case n.aG.ID_TOKEN:-1===i.idToken.indexOf(e)&&(this.logger.info("BrowserCacheManager: addTokenKey - idToken added to map"),i.idToken.push(e));break;case n.aG.ACCESS_TOKEN:-1===i.accessToken.indexOf(e)&&(this.logger.info("BrowserCacheManager: addTokenKey - accessToken added to map"),i.accessToken.push(e));break;case n.aG.REFRESH_TOKEN:-1===i.refreshToken.indexOf(e)&&(this.logger.info("BrowserCacheManager: addTokenKey - refreshToken added to map"),i.refreshToken.push(e));break;default:throw this.logger.error(`BrowserCacheManager:addTokenKey - CredentialType provided invalid. CredentialType: ${t}`),te(G)}this.setItem(`${Xi.dh.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(i))}removeTokenKey(e,t){this.logger.trace("BrowserCacheManager removeTokenKey called");const i=this.getTokenKeys();switch(t){case n.aG.ID_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove idToken with key: ${e} from map`);const r=i.idToken.indexOf(e);r>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - idToken removed from map"),i.idToken.splice(r,1)):this.logger.info("BrowserCacheManager: removeTokenKey - idToken does not exist in map. Either it was previously removed or it was never added.");break;case n.aG.ACCESS_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove accessToken with key: ${e} from map`);const s=i.accessToken.indexOf(e);s>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - accessToken removed from map"),i.accessToken.splice(s,1)):this.logger.info("BrowserCacheManager: removeTokenKey - accessToken does not exist in map. Either it was previously removed or it was never added.");break;case n.aG.REFRESH_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove refreshToken with key: ${e} from map`);const o=i.refreshToken.indexOf(e);o>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken removed from map"),i.refreshToken.splice(o,1)):this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken does not exist in map. Either it was previously removed or it was never added.");break;default:throw this.logger.error(`BrowserCacheManager:removeTokenKey - CredentialType provided invalid. CredentialType: ${t}`),te(G)}this.setItem(`${Xi.dh.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(i))}getIdTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.ID_TOKEN),null;const i=this.validateAndParseJson(t);return i&&fe(i)?(this.logger.trace("BrowserCacheManager.getIdTokenCredential: cache hit"),i):(this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.ID_TOKEN),null)}setIdTokenCredential(e){this.logger.trace("BrowserCacheManager.setIdTokenCredential called");const t=ce(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,n.aG.ID_TOKEN)}getAccessTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.ACCESS_TOKEN),null;const i=this.validateAndParseJson(t);return i&&ge(i)?(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: cache hit"),i):(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.ACCESS_TOKEN),null)}setAccessTokenCredential(e){this.logger.trace("BrowserCacheManager.setAccessTokenCredential called");const t=ce(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,n.aG.ACCESS_TOKEN)}getRefreshTokenCredential(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.REFRESH_TOKEN),null;const i=this.validateAndParseJson(t);return i&&me(i)?(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: cache hit"),i):(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,n.aG.REFRESH_TOKEN),null)}setRefreshTokenCredential(e){this.logger.trace("BrowserCacheManager.setRefreshTokenCredential called");const t=ce(e);this.setItem(t,JSON.stringify(e)),this.addTokenKey(t,n.aG.REFRESH_TOKEN)}getAppMetadata(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null;const i=this.validateAndParseJson(t);return i&&((r=i)&&0===e.indexOf(n.GU)&&r.hasOwnProperty("clientId")&&r.hasOwnProperty("environment"))?(this.logger.trace("BrowserCacheManager.getAppMetadata: cache hit"),i):(this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null);var r}setAppMetadata(e){this.logger.trace("BrowserCacheManager.setAppMetadata called");const t=function({environment:e,clientId:t}){return[n.GU,e,t].join(n.LR.CACHE_KEY_SEPARATOR).toLowerCase()}(e);this.setItem(t,JSON.stringify(e))}getServerTelemetry(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null;const i=this.validateAndParseJson(t);return i&&function(e,t){const i=0===e.indexOf(n.gT.CACHE_KEY);let r=!0;return t&&(r=t.hasOwnProperty("failedRequests")&&t.hasOwnProperty("errors")&&t.hasOwnProperty("cacheHits")),i&&r}(e,i)?(this.logger.trace("BrowserCacheManager.getServerTelemetry: cache hit"),i):(this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null)}setServerTelemetry(e,t){this.logger.trace("BrowserCacheManager.setServerTelemetry called"),this.setItem(e,JSON.stringify(t))}getAuthorityMetadata(e){const t=this.internalStorage.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getAuthorityMetadata: called, no cache hit"),null;const i=this.validateAndParseJson(t);return i&&function(e,t){return!!t&&0===e.indexOf(n.u0.CACHE_KEY)&&t.hasOwnProperty("aliases")&&t.hasOwnProperty("preferred_cache")&&t.hasOwnProperty("preferred_network")&&t.hasOwnProperty("canonical_authority")&&t.hasOwnProperty("authorization_endpoint")&&t.hasOwnProperty("token_endpoint")&&t.hasOwnProperty("issuer")&&t.hasOwnProperty("aliasesFromNetwork")&&t.hasOwnProperty("endpointsFromNetwork")&&t.hasOwnProperty("expiresAt")&&t.hasOwnProperty("jwks_uri")}(e,i)?(this.logger.trace("BrowserCacheManager.getAuthorityMetadata: cache hit"),i):null}getAuthorityMetadataKeys(){return this.internalStorage.getKeys().filter(e=>this.isAuthorityMetadata(e))}setWrapperMetadata(e,t){this.internalStorage.setItem(Xi.H3.WRAPPER_SKU,e),this.internalStorage.setItem(Xi.H3.WRAPPER_VER,t)}getWrapperMetadata(){return[this.internalStorage.getItem(Xi.H3.WRAPPER_SKU)||n.YM.EMPTY_STRING,this.internalStorage.getItem(Xi.H3.WRAPPER_VER)||n.YM.EMPTY_STRING]}setAuthorityMetadata(e,t){this.logger.trace("BrowserCacheManager.setAuthorityMetadata called"),this.internalStorage.setItem(e,JSON.stringify(t))}getActiveAccount(){const e=this.generateCacheKey(n.Gd.ACTIVE_ACCOUNT_FILTERS),t=this.getItem(e);if(!t){this.logger.trace("BrowserCacheManager.getActiveAccount: No active account filters cache schema found, looking for legacy schema");const e=this.generateCacheKey(n.Gd.ACTIVE_ACCOUNT),t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null;const i=this.getAccountInfoFilteredBy({localAccountId:t});return i?(this.logger.trace("BrowserCacheManager.getActiveAccount: Legacy active account cache schema found"),this.logger.trace("BrowserCacheManager.getActiveAccount: Adding active account filters cache schema"),this.setActiveAccount(i),i):null}const i=this.validateAndParseJson(t);return i?(this.logger.trace("BrowserCacheManager.getActiveAccount: Active account filters schema found"),this.getAccountInfoFilteredBy({homeAccountId:i.homeAccountId,localAccountId:i.localAccountId,tenantId:i.tenantId})):(this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null)}setActiveAccount(e){const t=this.generateCacheKey(n.Gd.ACTIVE_ACCOUNT_FILTERS),i=this.generateCacheKey(n.Gd.ACTIVE_ACCOUNT);if(e){this.logger.verbose("setActiveAccount: Active account set");const r={homeAccountId:e.homeAccountId,localAccountId:e.localAccountId,tenantId:e.tenantId};this.browserStorage.setItem(t,JSON.stringify(r)),this.browserStorage.setItem(i,e.localAccountId)}else this.logger.verbose("setActiveAccount: No account passed, active account not set"),this.browserStorage.removeItem(t),this.browserStorage.removeItem(i)}getThrottlingCache(e){const t=this.getItem(e);if(!t)return this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null;const i=this.validateAndParseJson(t);return i&&function(e,t){let i=!1;e&&(i=0===e.indexOf(n.Xw.THROTTLING_PREFIX));let r=!0;return t&&(r=t.hasOwnProperty("throttleTime")),i&&r}(e,i)?(this.logger.trace("BrowserCacheManager.getThrottlingCache: cache hit"),i):(this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null)}setThrottlingCache(e,t){this.logger.trace("BrowserCacheManager.setThrottlingCache called"),this.setItem(e,JSON.stringify(t))}getTemporaryCache(e,t){const i=t?this.generateCacheKey(e):e;if(this.cacheConfig.storeAuthStateInCookie){const e=this.getItemCookie(i);if(e)return this.logger.trace("BrowserCacheManager.getTemporaryCache: storeAuthStateInCookies set to true, retrieving from cookies"),e}const r=this.temporaryCacheStorage.getItem(i);if(!r){if(this.cacheConfig.cacheLocation===Xi.Al.LocalStorage){const e=this.browserStorage.getItem(i);if(e)return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item found in local storage"),e}return this.logger.trace("BrowserCacheManager.getTemporaryCache: No cache item found in local storage"),null}return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item returned"),r}setTemporaryCache(e,t,i){const r=i?this.generateCacheKey(e):e;this.temporaryCacheStorage.setItem(r,t),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.setTemporaryCache: storeAuthStateInCookie set to true, setting item cookie"),this.setItemCookie(r,t))}removeItem(e){this.browserStorage.removeItem(e)}removeTemporaryItem(e){this.temporaryCacheStorage.removeItem(e),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.removeItem: storeAuthStateInCookie is true, clearing item cookie"),this.clearItemCookie(e))}getKeys(){return this.browserStorage.getKeys()}async clear(){await this.removeAllAccounts(),this.removeAppMetadata(),this.temporaryCacheStorage.getKeys().forEach(e=>{-1===e.indexOf(n.YM.CACHE_PREFIX)&&-1===e.indexOf(this.clientId)||this.removeTemporaryItem(e)}),this.browserStorage.getKeys().forEach(e=>{-1===e.indexOf(n.YM.CACHE_PREFIX)&&-1===e.indexOf(this.clientId)||this.browserStorage.removeItem(e)}),this.internalStorage.clear()}async clearTokensAndKeysWithClaims(e,t){e.addQueueMeasurement(Bi,t);const i=this.getTokenKeys(),r=[];i.accessToken.forEach(e=>{const t=this.getAccessTokenCredential(e);t?.requestedClaimsHash&&e.includes(t.requestedClaimsHash.toLowerCase())&&r.push(this.removeAccessToken(e))}),await Promise.all(r),r.length>0&&this.logger.warning(`${r.length} access tokens with claims in the cache keys have been removed from the cache.`)}setItemCookie(e,t,i){let r=`${encodeURIComponent(e)}=${encodeURIComponent(t)};path=/;SameSite=Lax;`;i&&(r+=`expires=${this.getCookieExpirationTime(i)};`),this.cacheConfig.secureCookies&&(r+="Secure;"),document.cookie=r}getItemCookie(e){const t=`${encodeURIComponent(e)}=`,i=document.cookie.split(";");for(let e=0;e<i.length;e++){let r=i[e];for(;" "===r.charAt(0);)r=r.substring(1);if(0===r.indexOf(t))return decodeURIComponent(r.substring(t.length,r.length))}return n.YM.EMPTY_STRING}clearMsalCookies(){const e=`${n.YM.CACHE_PREFIX}.${this.clientId}`;document.cookie.split(";").forEach(t=>{for(;" "===t.charAt(0);)t=t.substring(1);if(0===t.indexOf(e)){const e=t.split("=")[0];this.clearItemCookie(e)}})}clearItemCookie(e){this.setItemCookie(e,n.YM.EMPTY_STRING,-1)}getCookieExpirationTime(e){const t=new Date;return new Date(t.getTime()+e*this.COOKIE_LIFE_MULTIPLIER).toUTCString()}generateCacheKey(e){return this.validateAndParseJson(e)?JSON.stringify(e):Xe.startsWith(e,n.YM.CACHE_PREFIX)||Xe.startsWith(e,n.Gd.ADAL_ID_TOKEN)?e:`${n.YM.CACHE_PREFIX}.${this.clientId}.${e}`}generateAuthorityKey(e){const{libraryState:{id:t}}=$r.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Xi._p.AUTHORITY}.${t}`)}generateNonceKey(e){const{libraryState:{id:t}}=$r.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Xi._p.NONCE_IDTOKEN}.${t}`)}generateStateKey(e){const{libraryState:{id:t}}=$r.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Xi._p.REQUEST_STATE}.${t}`)}getCachedAuthority(e){const t=this.generateStateKey(e),i=this.getTemporaryCache(t);if(!i)return null;const r=this.generateAuthorityKey(i);return this.getTemporaryCache(r)}updateCacheEntries(e,t,i,r,n){this.logger.trace("BrowserCacheManager.updateCacheEntries called");const s=this.generateStateKey(e);this.setTemporaryCache(s,e,!1);const o=this.generateNonceKey(e);this.setTemporaryCache(o,t,!1);const a=this.generateAuthorityKey(e);if(this.setTemporaryCache(a,i,!1),n){const e={credential:n.homeAccountId,type:qr};this.setTemporaryCache(Xi._p.CCS_CREDENTIAL,JSON.stringify(e),!0)}else if(r){const e={credential:r,type:Yr};this.setTemporaryCache(Xi._p.CCS_CREDENTIAL,JSON.stringify(e),!0)}}resetRequestCache(e){this.logger.trace("BrowserCacheManager.resetRequestCache called"),e&&(this.temporaryCacheStorage.getKeys().forEach(t=>{-1!==t.indexOf(e)&&this.removeTemporaryItem(t)}),this.removeTemporaryItem(this.generateStateKey(e)),this.removeTemporaryItem(this.generateNonceKey(e)),this.removeTemporaryItem(this.generateAuthorityKey(e))),this.removeTemporaryItem(this.generateCacheKey(Xi._p.REQUEST_PARAMS)),this.removeTemporaryItem(this.generateCacheKey(Xi._p.ORIGIN_URI)),this.removeTemporaryItem(this.generateCacheKey(Xi._p.URL_HASH)),this.removeTemporaryItem(this.generateCacheKey(Xi._p.CORRELATION_ID)),this.removeTemporaryItem(this.generateCacheKey(Xi._p.CCS_CREDENTIAL)),this.removeTemporaryItem(this.generateCacheKey(Xi._p.NATIVE_REQUEST)),this.setInteractionInProgress(!1)}cleanRequestByState(e){if(this.logger.trace("BrowserCacheManager.cleanRequestByState called"),e){const t=this.generateStateKey(e),i=this.temporaryCacheStorage.getItem(t);this.logger.infoPii(`BrowserCacheManager.cleanRequestByState: Removing temporary cache items for state: ${i}`),this.resetRequestCache(i||n.YM.EMPTY_STRING)}this.clearMsalCookies()}cleanRequestByInteractionType(e){this.logger.trace("BrowserCacheManager.cleanRequestByInteractionType called"),this.temporaryCacheStorage.getKeys().forEach(t=>{if(-1===t.indexOf(Xi._p.REQUEST_STATE))return;const i=this.temporaryCacheStorage.getItem(t);if(!i)return;const r=Jr(this.cryptoImpl,i);r&&r.interactionType===e&&(this.logger.infoPii(`BrowserCacheManager.cleanRequestByInteractionType: Removing temporary cache items for state: ${i}`),this.resetRequestCache(i))}),this.clearMsalCookies(),this.setInteractionInProgress(!1)}cacheCodeRequest(e){this.logger.trace("BrowserCacheManager.cacheCodeRequest called");const t=pr(JSON.stringify(e));this.setTemporaryCache(Xi._p.REQUEST_PARAMS,t,!0)}getCachedRequest(e){this.logger.trace("BrowserCacheManager.getCachedRequest called");const t=this.getTemporaryCache(Xi._p.REQUEST_PARAMS,!0);if(!t)throw(0,Ji.bD)(er.y6);let i;try{i=JSON.parse(fr(t))}catch(e){throw this.logger.errorPii(`Attempted to parse: ${t}`),this.logger.error(`Parsing cached token request threw with error: ${e}`),(0,Ji.bD)(er.ot)}if(this.removeTemporaryItem(this.generateCacheKey(Xi._p.REQUEST_PARAMS)),!i.authority){const t=this.generateAuthorityKey(e),r=this.getTemporaryCache(t);if(!r)throw(0,Ji.bD)(er.Ne);i.authority=r}return i}getCachedNativeRequest(){this.logger.trace("BrowserCacheManager.getCachedNativeRequest called");const e=this.getTemporaryCache(Xi._p.NATIVE_REQUEST,!0);if(!e)return this.logger.trace("BrowserCacheManager.getCachedNativeRequest: No cached native request found"),null;return this.validateAndParseJson(e)||(this.logger.error("BrowserCacheManager.getCachedNativeRequest: Unable to parse native request"),null)}isInteractionInProgress(e){const t=this.getInteractionInProgress();return e?t===this.clientId:!!t}getInteractionInProgress(){const e=`${n.YM.CACHE_PREFIX}.${Xi._p.INTERACTION_STATUS_KEY}`;return this.getTemporaryCache(e,!1)}setInteractionInProgress(e){const t=`${n.YM.CACHE_PREFIX}.${Xi._p.INTERACTION_STATUS_KEY}`;if(e){if(this.getInteractionInProgress())throw(0,Ji.bD)(er.b);this.setTemporaryCache(t,this.clientId,!1)}else e||this.getInteractionInProgress()!==this.clientId||this.removeTemporaryItem(t)}getLegacyLoginHint(){const e=this.getTemporaryCache(n.Gd.ADAL_ID_TOKEN);e&&(this.browserStorage.removeItem(n.Gd.ADAL_ID_TOKEN),this.logger.verbose("Cached ADAL id token retrieved."));const t=this.getTemporaryCache(n.Gd.ID_TOKEN,!0);t&&(this.browserStorage.removeItem(this.generateCacheKey(n.Gd.ID_TOKEN)),this.logger.verbose("Cached MSAL.js v1 id token retrieved"));const i=t||e;if(i){const e=se(i,fr);if(e.preferred_username)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 preferred_username as loginHint"),e.preferred_username;if(e.upn)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 upn as loginHint"),e.upn;this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, however, no account hint claim found. Enable preferred_username or upn id token claim to get SSO.")}return null}updateCredentialCacheKey(e,t){const i=ce(t);if(e!==i){const r=this.getItem(e);if(r)return this.browserStorage.removeItem(e),this.setItem(i,r),this.logger.verbose(`Updated an outdated ${t.credentialType} cache key`),i;this.logger.error(`Attempted to update an outdated ${t.credentialType} cache key but no item matching the outdated key was found in storage`)}return e}async hydrateCache(e,t){const i=ue(e.account?.homeAccountId,e.account?.environment,e.idToken,this.clientId,e.tenantId);let r;t.claims&&(r=await this.cryptoImpl.hashString(t.claims));const n={idToken:i,accessToken:he(e.account?.homeAccountId,e.account.environment,e.accessToken,this.clientId,e.tenantId,e.scopes.join(" "),e.expiresOn?e.expiresOn.getTime()/1e3:0,e.extExpiresOn?e.extExpiresOn.getTime()/1e3:0,fr,void 0,e.tokenType,void 0,t.sshKid,t.claims,r)};return this.saveCacheRecord(n)}async saveCacheRecord(e,t,i){try{await super.saveCacheRecord(e,t,i)}catch(e){if(e instanceof vt&&this.performanceClient&&i)try{const e=this.getTokenKeys();this.performanceClient.addFields({cacheRtCount:e.refreshToken.length,cacheIdCount:e.idToken.length,cacheAtCount:e.accessToken.length},i)}catch(e){}throw e}}}function tn(){return window.parent!==window}function rn(){return window.location.href.split("?")[0].split("#")[0]}function nn(){if("undefined"==typeof window)throw(0,Ji.bD)(er.tI)}function sn(e){if(!e)throw(0,Ji.bD)(er.IR)}function on(e){nn(),function(){if(lt.hashContainsKnownProperties(window.location.hash)&&tn())throw(0,Ji.bD)(er.tZ)}(),function(){if("undefined"!=typeof window&&window.opener&&window.opener!==window&&"string"==typeof window.name&&0===window.name.indexOf(`${Xi.Q1.POPUP_NAME_PREFIX}.`))throw(0,Ji.bD)(er.aH)}(),sn(e)}function an(e,t){if(on(e),function(e){if(tn()&&!e)throw(0,Ji.bD)(er.OT)}(t.system.allowRedirectInIframe),t.cache.cacheLocation===Xi.Al.MemoryStorage&&!t.cache.storeAuthStateInCookie)throw(0,Qr.jz)(Xr.jE)}function ln(e){const t=document.createElement("link");t.rel="preconnect",t.href=new URL(e).origin,t.crossOrigin="anonymous",document.head.appendChild(t),window.setTimeout(()=>{try{document.head.removeChild(t)}catch{}},1e4)}var cn=i(99268);class un{constructor(e){this.eventCallbacks=new Map,this.logger=e||new r.V({})}addEventCallback(e,t,i){if("undefined"!=typeof window){const r=i||Ar();return this.eventCallbacks.has(r)?(this.logger.error(`Event callback with id: ${r} is already registered. Please provide a unique id or remove the existing callback and try again.`),null):(this.eventCallbacks.set(r,[e,t||[]]),this.logger.verbose(`Event callback registered with id: ${r}`),r)}return null}removeEventCallback(e){this.eventCallbacks.delete(e),this.logger.verbose(`Event callback ${e} removed.`)}emitEvent(e,t,i,r){if("undefined"!=typeof window){const n={eventType:e,interactionType:t||null,payload:i||null,error:r||null,timestamp:Date.now()};this.eventCallbacks.forEach(([t,i],r)=>{(0===i.length||i.includes(e))&&(this.logger.verbose(`Emitting event to callback ${r}: ${e}`),t.apply(null,[n]))})}}}class hn extends l.lR{constructor(e,t,i,r,n){super(e,t,i),this.name="ServerError",this.errorNo=r,this.status=n,Object.setPrototypeOf(this,hn.prototype)}}class dn{static generateThrottlingStorageKey(e){return`${n.Xw.THROTTLING_PREFIX}.${JSON.stringify(e)}`}static preProcess(e,t){const i=dn.generateThrottlingStorageKey(t),r=e.getThrottlingCache(i);if(r){if(r.throttleTime<Date.now())return void e.removeItem(i);throw new hn(r.errorCodes?.join(" ")||n.YM.EMPTY_STRING,r.errorMessage,r.subError)}}static postProcess(e,t,i){if(dn.checkResponseStatus(i)||dn.checkResponseForRetryAfter(i)){const r={throttleTime:dn.calculateThrottleTime(parseInt(i.headers[n.OK.RETRY_AFTER])),error:i.body.error,errorCodes:i.body.error_codes,errorMessage:i.body.error_description,subError:i.body.suberror};e.setThrottlingCache(dn.generateThrottlingStorageKey(t),r)}}static checkResponseStatus(e){return 429===e.status||e.status>=500&&e.status<600}static checkResponseForRetryAfter(e){return!!e.headers&&e.headers.hasOwnProperty(n.OK.RETRY_AFTER)&&(e.status<200||e.status>=300)}static calculateThrottleTime(e){const t=e<=0?0:e,i=Date.now()/1e3;return Math.floor(1e3*Math.min(i+(t||n.Xw.DEFAULT_THROTTLE_TIME_SECONDS),i+n.Xw.DEFAULT_MAX_THROTTLE_TIME_SECONDS))}static removeThrottle(e,t,i,r){const n={clientId:t,authority:i.authority,scopes:i.scopes,homeAccountIdentifier:r,claims:i.claims,authenticationScheme:i.authenticationScheme,resourceRequestMethod:i.resourceRequestMethod,resourceRequestUri:i.resourceRequestUri,shrClaims:i.shrClaims,sshKid:i.sshKid},s=this.generateThrottlingStorageKey(n);e.removeItem(s)}}class pn{constructor(e,t){this.networkClient=e,this.cacheManager=t}async sendPostRequest(e,t,i){let r;dn.preProcess(this.cacheManager,e);try{r=await this.networkClient.sendPostRequestAsync(t,i)}catch(e){throw e instanceof l.lR?e:te(g)}return dn.postProcess(this.cacheManager,e,r),r}}const gn="client_id",fn="response_type",mn="token_type",vn="req_cnf",Cn="return_spa_code",yn="x-client-xtra-sku";class wn{static validateRedirectUri(e){if(!e)throw Qe(Me)}static validatePrompt(e){const t=[];for(const e in n._M)t.push(n._M[e]);if(t.indexOf(e)<0)throw Qe(Ie)}static validateClaims(e){try{JSON.parse(e)}catch(e){throw Qe(Le)}}static validateCodeChallengeParams(e,t){if(!e||!t)throw Qe(ke);this.validateCodeChallengeMethod(t)}static validateCodeChallengeMethod(e){if([n.iF.PLAIN,n.iF.S256].indexOf(e)<0)throw Qe(Fe)}}class Sn{constructor(){this.parameters=new Map}addResponseTypeCode(){this.parameters.set(fn,encodeURIComponent(n.YM.CODE_RESPONSE_TYPE))}addResponseTypeForTokenAndIdToken(){this.parameters.set(fn,encodeURIComponent(`${n.YM.TOKEN_RESPONSE_TYPE} ${n.YM.ID_TOKEN_RESPONSE_TYPE}`))}addResponseMode(e){this.parameters.set("response_mode",encodeURIComponent(e||n.p.QUERY))}addNativeBroker(){this.parameters.set("nativebroker",encodeURIComponent("1"))}addScopes(e,t=!0,i=n.aZ){!t||i.includes("openid")||e.includes("openid")||i.push("openid");const r=t?[...e||[],...i]:e||[],s=new Ze(r);this.parameters.set("scope",encodeURIComponent(s.printScopes()))}addClientId(e){this.parameters.set(gn,encodeURIComponent(e))}addRedirectUri(e){wn.validateRedirectUri(e),this.parameters.set("redirect_uri",encodeURIComponent(e))}addPostLogoutRedirectUri(e){wn.validateRedirectUri(e),this.parameters.set("post_logout_redirect_uri",encodeURIComponent(e))}addIdTokenHint(e){this.parameters.set("id_token_hint",encodeURIComponent(e))}addDomainHint(e){this.parameters.set("domain_hint",encodeURIComponent(e))}addLoginHint(e){this.parameters.set("login_hint",encodeURIComponent(e))}addCcsUpn(e){this.parameters.set(n.OK.CCS_HEADER,encodeURIComponent(`UPN:${e}`))}addCcsOid(e){this.parameters.set(n.OK.CCS_HEADER,encodeURIComponent(`Oid:${e.uid}@${e.utid}`))}addSid(e){this.parameters.set("sid",encodeURIComponent(e))}addClaims(e,t){const i=this.addClientCapabilitiesToClaims(e,t);wn.validateClaims(i),this.parameters.set("claims",encodeURIComponent(i))}addCorrelationId(e){this.parameters.set("client-request-id",encodeURIComponent(e))}addLibraryInfo(e){this.parameters.set("x-client-SKU",e.sku),this.parameters.set("x-client-VER",e.version),e.os&&this.parameters.set("x-client-OS",e.os),e.cpu&&this.parameters.set("x-client-CPU",e.cpu)}addApplicationTelemetry(e){e?.appName&&this.parameters.set("x-app-name",e.appName),e?.appVersion&&this.parameters.set("x-app-ver",e.appVersion)}addPrompt(e){wn.validatePrompt(e),this.parameters.set("prompt",encodeURIComponent(e))}addState(e){e&&this.parameters.set("state",encodeURIComponent(e))}addNonce(e){this.parameters.set("nonce",encodeURIComponent(e))}addCodeChallengeParams(e,t){if(wn.validateCodeChallengeParams(e,t),!e||!t)throw Qe(ke);this.parameters.set("code_challenge",encodeURIComponent(e)),this.parameters.set("code_challenge_method",encodeURIComponent(t))}addAuthorizationCode(e){this.parameters.set("code",encodeURIComponent(e))}addDeviceCode(e){this.parameters.set("device_code",encodeURIComponent(e))}addRefreshToken(e){this.parameters.set("refresh_token",encodeURIComponent(e))}addCodeVerifier(e){this.parameters.set("code_verifier",encodeURIComponent(e))}addClientSecret(e){this.parameters.set("client_secret",encodeURIComponent(e))}addClientAssertion(e){e&&this.parameters.set("client_assertion",encodeURIComponent(e))}addClientAssertionType(e){e&&this.parameters.set("client_assertion_type",encodeURIComponent(e))}addOboAssertion(e){this.parameters.set("assertion",encodeURIComponent(e))}addRequestTokenUse(e){this.parameters.set("requested_token_use",encodeURIComponent(e))}addGrantType(e){this.parameters.set("grant_type",encodeURIComponent(e))}addClientInfo(){this.parameters.set(n.JR,"1")}addExtraQueryParameters(e){Object.entries(e).forEach(([e,t])=>{!this.parameters.has(e)&&t&&this.parameters.set(e,t)})}addClientCapabilitiesToClaims(e,t){let i;if(e)try{i=JSON.parse(e)}catch(e){throw Qe(Le)}else i={};return t&&t.length>0&&(i.hasOwnProperty(n.Fq.ACCESS_TOKEN)||(i[n.Fq.ACCESS_TOKEN]={}),i[n.Fq.ACCESS_TOKEN][n.Fq.XMS_CC]={values:t}),JSON.stringify(i)}addUsername(e){this.parameters.set(n.Tq.username,encodeURIComponent(e))}addPassword(e){this.parameters.set(n.Tq.password,encodeURIComponent(e))}addPopToken(e){e&&(this.parameters.set(mn,n.IO.POP),this.parameters.set(vn,encodeURIComponent(e)))}addSshJwk(e){e&&(this.parameters.set(mn,n.IO.SSH),this.parameters.set(vn,encodeURIComponent(e)))}addServerTelemetry(e){this.parameters.set("x-client-current-telemetry",e.generateCurrentRequestHeaderValue()),this.parameters.set("x-client-last-telemetry",e.generateLastRequestHeaderValue())}addThrottling(){this.parameters.set("x-ms-lib-capability",n.Xw.X_MS_LIB_CAPABILITY_VALUE)}addLogoutHint(e){this.parameters.set("logout_hint",encodeURIComponent(e))}createQueryString(){const e=new Array;return this.parameters.forEach((t,i)=>{e.push(`${i}=${t}`)}),e.join("&")}}async function bn(e,t,i,r,n,s,o){o?.addQueueMeasurement(Mi,s);const a=Or.transformCIAMAuthority(Fr(e)),l=new Or(a,t,i,r,n,s,o);try{return await Lr(l.resolveEndpointsAsync.bind(l),Ri,n,o,s)(),l}catch(e){throw te(p)}}class En{constructor(e,t){this.config=function({authOptions:e,systemOptions:t,loggerOptions:i,cacheOptions:n,storageInterface:s,networkInterface:o,cryptoInterface:a,clientCredentials:l,libraryInfo:c,telemetry:u,serverTelemetryManager:h,persistencePlugin:d,serializableCache:p}){const g={...St,...i};return{authOptions:(f=e,{clientCapabilities:[],azureCloudOptions:Mt,skipAuthorityMetadataCache:!1,instanceAware:!1,...f}),systemOptions:{...wt,...t},loggerOptions:g,cacheOptions:{...bt,...n},storageInterface:s||new yt(e.clientId,ie,new r.V(g)),networkInterface:o||Et,cryptoInterface:a||ie,clientCredentials:l||Tt,libraryInfo:{...At,...c},telemetry:{...Rt,...u},serverTelemetryManager:h||null,persistencePlugin:d||null,serializableCache:p||null};var f}(e),this.logger=new r.V(this.config.loggerOptions,re,ne),this.cryptoUtils=this.config.cryptoInterface,this.cacheManager=this.config.storageInterface,this.networkClient=this.config.networkInterface,this.networkManager=new pn(this.networkClient,this.cacheManager),this.serverTelemetryManager=this.config.serverTelemetryManager,this.authority=this.config.authOptions.authority,this.performanceClient=t}createTokenRequestHeaders(e){const t={};if(t[n.OK.CONTENT_TYPE]=n.YM.URL_FORM_CONTENT_TYPE,!this.config.systemOptions.preventCorsPreflight&&e)switch(e.type){case qr:try{const i=et(e.credential);t[n.OK.CCS_HEADER]=`Oid:${i.uid}@${i.utid}`}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case Yr:t[n.OK.CCS_HEADER]=`UPN: ${e.credential}`}return t}async executePostToTokenEndpoint(e,t,i,r,s,o){o&&this.performanceClient?.addQueueMeasurement(o,s);const a=await this.networkManager.sendPostRequest(r,e,{body:t,headers:i});return this.performanceClient?.addFields({refreshTokenSize:a.body.refresh_token?.length||0,httpVerToken:a.headers?.[n.OK.X_MS_HTTP_VERSION]||""},s),this.config.serverTelemetryManager&&a.status<500&&429!==a.status&&this.config.serverTelemetryManager.clearTelemetryCache(),a}async updateAuthority(e,t){this.performanceClient?.addQueueMeasurement(vi,t);const i=`https://${e}/${this.authority.tenant}/`,r=await bn(i,this.networkClient,this.cacheManager,this.authority.options,this.logger,t,this.performanceClient);this.authority=r}createTokenQueryParameters(e){const t=new Sn;return e.tokenQueryParameters&&t.addExtraQueryParameters(e.tokenQueryParameters),t.createQueryString()}}class An{constructor(e,t){this.cryptoUtils=e,this.performanceClient=t}async generateCnf(e,t){this.performanceClient?.addQueueMeasurement(bi,e.correlationId);const i=await Lr(this.generateKid.bind(this),bi,t,this.performanceClient,e.correlationId)(e),r=this.cryptoUtils.base64UrlEncode(JSON.stringify(i));return{kid:i.kid,reqCnfString:r}}async generateKid(e){return this.performanceClient?.addQueueMeasurement(Ei,e.correlationId),{kid:await this.cryptoUtils.getPublicKeyThumbprint(e),xms_ksl:"sw"}}async signPopToken(e,t,i){return this.signPayload(e,t,i)}async signPayload(e,t,i,r){const{resourceRequestMethod:n,resourceRequestUri:s,shrClaims:o,shrNonce:a,shrOptions:l}=i,c=s?new lt(s):void 0,u=c?.getUrlComponents();return this.cryptoUtils.signJwt({at:e,ts:ae(),m:n?.toUpperCase(),u:u?.HostNameAndPort,nonce:a||this.cryptoUtils.createNewGuid(),p:u?.AbsolutePath,q:u?.QueryString?[[],u.QueryString]:void 0,client_claims:o||void 0,...r},t,l,i.correlationId)}}class Tn{constructor(e,t){this.cache=e,this.hasChanged=t}get cacheHasChanged(){return this.hasChanged}get tokenCache(){return this.cache}}class Mn{constructor(e,t,i,r,n,s,o){this.clientId=e,this.cacheStorage=t,this.cryptoObj=i,this.logger=r,this.serializableCache=n,this.persistencePlugin=s,this.performanceClient=o}validateServerAuthorizationCodeResponse(e,t){if(!e.state||!t)throw e.state?te(y,"Cached State"):te(y,"Server State");let i,r;try{i=decodeURIComponent(e.state)}catch(t){throw te(v,e.state)}try{r=decodeURIComponent(t)}catch(t){throw te(v,e.state)}if(i!==r)throw te(C);if(e.error||e.error_description||e.suberror){const t=function(e){const t=e.error_uri?.lastIndexOf("code=");return t&&t>=0?e.error_uri?.substring(t+5):void 0}(e);if(jr(e.error,e.error_description,e.suberror))throw new Wr(e.error||"",e.error_description,e.suberror,e.timestamp||"",e.trace_id||"",e.correlation_id||"",e.claims||"",t);throw new hn(e.error||"",e.error_description,e.suberror,t)}}validateTokenResponse(e,t){if(e.error||e.error_description||e.suberror){const i=`Error(s): ${e.error_codes||n.YM.NOT_AVAILABLE} - Timestamp: ${e.timestamp||n.YM.NOT_AVAILABLE} - Description: ${e.error_description||n.YM.NOT_AVAILABLE} - Correlation ID: ${e.correlation_id||n.YM.NOT_AVAILABLE} - Trace ID: ${e.trace_id||n.YM.NOT_AVAILABLE}`,r=e.error_codes?.length?e.error_codes[0]:void 0,s=new hn(e.error,i,e.suberror,r,e.status);if(t&&e.status&&e.status>=n.t3.SERVER_ERROR_RANGE_START&&e.status<=n.t3.SERVER_ERROR_RANGE_END)return void this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently unavailable and the access token is unable to be refreshed.\n${s}`);if(t&&e.status&&e.status>=n.t3.CLIENT_ERROR_RANGE_START&&e.status<=n.t3.CLIENT_ERROR_RANGE_END)return void this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently available but is unable to refresh the access token.\n${s}`);if(jr(e.error,e.error_description,e.suberror))throw new Wr(e.error,e.error_description,e.suberror,e.timestamp||n.YM.EMPTY_STRING,e.trace_id||n.YM.EMPTY_STRING,e.correlation_id||n.YM.EMPTY_STRING,e.claims||n.YM.EMPTY_STRING,r);throw s}}async handleServerTokenResponse(e,t,i,r,s,o,a,l,c){let u,h;if(this.performanceClient?.addQueueMeasurement(Ai,e.correlation_id),e.id_token){if(u=se(e.id_token||n.YM.EMPTY_STRING,this.cryptoObj.base64Decode),s&&s.nonce&&u.nonce!==s.nonce)throw te(w);if(r.maxAge||0===r.maxAge){const e=u.auth_time;if(!e)throw te(S);oe(e,r.maxAge)}}this.homeAccountIdentifier=st.generateHomeAccountId(e.client_info||n.YM.EMPTY_STRING,t.authorityType,this.logger,this.cryptoObj,u),s&&s.state&&(h=$r.parseRequestState(this.cryptoObj,s.state)),e.key_id=e.key_id||r.sshKid||void 0;const d=this.generateCacheRecord(e,t,i,r,u,o,s);let p;try{if(this.persistencePlugin&&this.serializableCache&&(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),p=new Tn(this.serializableCache,!0),await this.persistencePlugin.beforeCacheAccess(p)),a&&!l&&d.account){const e=d.account.generateAccountKey();if(!this.cacheStorage.getAccount(e,this.logger))return this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),await Mn.generateAuthenticationResult(this.cryptoObj,t,d,!1,r,u,h,void 0,c)}await this.cacheStorage.saveCacheRecord(d,r.storeInCache,r.correlationId)}finally{this.persistencePlugin&&this.serializableCache&&p&&(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),await this.persistencePlugin.afterCacheAccess(p))}return Mn.generateAuthenticationResult(this.cryptoObj,t,d,!1,r,u,h,e,c)}generateCacheRecord(e,t,i,r,n,s,o){const a=t.getPreferredCache();if(!a)throw te(O);const l=nt(n);let c,u;e.id_token&&n&&(c=ue(this.homeAccountIdentifier,a,e.id_token,this.clientId,l||""),u=Rn(this.cacheStorage,t,this.homeAccountIdentifier,this.cryptoObj.base64Decode,n,e.client_info,a,l,o,void 0,this.logger));let h=null;if(e.access_token){const n=e.scope?Ze.fromString(e.scope):new Ze(r.scopes||[]),o=("string"==typeof e.expires_in?parseInt(e.expires_in,10):e.expires_in)||0,c=("string"==typeof e.ext_expires_in?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,u=("string"==typeof e.refresh_in?parseInt(e.refresh_in,10):e.refresh_in)||void 0,d=i+o,p=d+c,g=u&&u>0?i+u:void 0;h=he(this.homeAccountIdentifier,a,e.access_token,this.clientId,l||t.tenant||"",n.printScopes(),d,p,this.cryptoObj.base64Decode,g,e.token_type,s,e.key_id,r.claims,r.requestedClaimsHash)}let d=null;if(e.refresh_token){let t;e.refresh_token_expires_in&&(t=i+("string"==typeof e.refresh_token_expires_in?parseInt(e.refresh_token_expires_in,10):e.refresh_token_expires_in)),d=de(this.homeAccountIdentifier,a,e.refresh_token,this.clientId,e.foci,s,t)}let p=null;return e.foci&&(p={clientId:this.clientId,environment:a,familyId:e.foci}),{account:u,idToken:c,accessToken:h,refreshToken:d,appMetadata:p}}static async generateAuthenticationResult(e,t,i,r,s,o,a,l,c){let u,h,d=n.YM.EMPTY_STRING,p=[],g=null,f=n.YM.EMPTY_STRING;if(i.accessToken){if(i.accessToken.tokenType!==n.IO.POP||s.popKid)d=i.accessToken.secret;else{const t=new An(e),{secret:r,keyId:n}=i.accessToken;if(!n)throw te($);d=await t.signPopToken(r,n,s)}p=Ze.fromString(i.accessToken.target).asArray(),g=new Date(1e3*Number(i.accessToken.expiresOn)),u=new Date(1e3*Number(i.accessToken.extendedExpiresOn)),i.accessToken.refreshOn&&(h=new Date(1e3*Number(i.accessToken.refreshOn)))}i.appMetadata&&(f=i.appMetadata.familyId===n.hB?n.hB:"");const m=o?.oid||o?.sub||"",v=o?.tid||"";l?.spa_accountid&&i.account&&(i.account.nativeAccountId=l?.spa_accountid);const C=i.account?rt(i.account.getAccountInfo(),void 0,o,i.idToken?.secret):null;return{authority:t.canonicalAuthority,uniqueId:m,tenantId:v,scopes:p,account:C,idToken:i?.idToken?.secret||"",idTokenClaims:o||{},accessToken:d,fromCache:r,expiresOn:g,extExpiresOn:u,refreshOn:h,correlationId:s.correlationId,requestId:c||n.YM.EMPTY_STRING,familyId:f,tokenType:i.accessToken?.tokenType||n.YM.EMPTY_STRING,state:a?a.userRequestState:n.YM.EMPTY_STRING,cloudGraphHostName:i.account?.cloudGraphHostName||n.YM.EMPTY_STRING,msGraphHost:i.account?.msGraphHost||n.YM.EMPTY_STRING,code:l?.spa_code,fromNativeBroker:!1}}}function Rn(e,t,i,r,n,s,o,a,l,c,u){u?.verbose("setCachedAccount called");const h=e.getAccountKeys().find(e=>e.startsWith(i));let d=null;h&&(d=e.getAccount(h,u));const p=d||st.createAccount({homeAccountId:i,idTokenClaims:n,clientInfo:s,environment:o,cloudGraphHostName:l?.cloud_graph_host_name,msGraphHost:l?.msgraph_host,nativeAccountId:c},t,r),g=p.tenantProfiles||[],f=a||p.realm;if(f&&!g.find(e=>e.tenantId===f)){const e=it(i,p.localAccountId,f,n);g.push(e)}return p.tenantProfiles=g,p}async function _n(e,t,i){return"string"==typeof e?e:e({clientId:t,tokenEndpoint:i})}class Pn extends En{constructor(e,t){super(e,t),this.includeRedirectUri=!0,this.oidcDefaultScopes=this.config.authOptions.authority.options.OIDCOptions?.defaultScopes}async getAuthCodeUrl(e){this.performanceClient?.addQueueMeasurement(gi,e.correlationId);const t=await Lr(this.createAuthCodeUrlQueryString.bind(this),Si,this.logger,this.performanceClient,e.correlationId)(e);return lt.appendQueryString(this.authority.authorizationEndpoint,t)}async acquireToken(e,t){if(this.performanceClient?.addQueueMeasurement(Ci,e.correlationId),!e.code)throw te(M);const i=ae(),r=await Lr(this.executeTokenRequest.bind(this),yi,this.logger,this.performanceClient,e.correlationId)(this.authority,e),s=r.headers?.[n.OK.X_MS_REQUEST_ID],o=new Mn(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient);return o.validateTokenResponse(r.body),Lr(o.handleServerTokenResponse.bind(o),Ai,this.logger,this.performanceClient,e.correlationId)(r.body,this.authority,i,e,t,void 0,void 0,void 0,s)}handleFragmentResponse(e,t){if(new Mn(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null).validateServerAuthorizationCodeResponse(e,t),!e.code)throw te(W);return e}getLogoutUri(e){if(!e)throw Qe(Oe);const t=this.createLogoutUrlQueryString(e);return lt.appendQueryString(this.authority.endSessionEndpoint,t)}async executeTokenRequest(e,t){this.performanceClient?.addQueueMeasurement(yi,t.correlationId);const i=this.createTokenQueryParameters(t),r=lt.appendQueryString(e.tokenEndpoint,i),s=await Lr(this.createTokenRequestBody.bind(this),wi,this.logger,this.performanceClient,t.correlationId)(t);let o;if(t.clientInfo)try{const e=Je(t.clientInfo,this.cryptoUtils.base64Decode);o={credential:`${e.uid}${n.LR.CLIENT_INFO_SEPARATOR}${e.utid}`,type:qr}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}const a=this.createTokenRequestHeaders(o||t.ccsCredential),l={clientId:t.tokenBodyParameters?.clientId||this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:t.scopes,claims:t.claims,authenticationScheme:t.authenticationScheme,resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,sshKid:t.sshKid};return Lr(this.executePostToTokenEndpoint.bind(this),Kt,this.logger,this.performanceClient,t.correlationId)(r,s,a,l,t.correlationId,Kt)}async createTokenRequestBody(e){this.performanceClient?.addQueueMeasurement(wi,e.correlationId);const t=new Sn;if(t.addClientId(e.tokenBodyParameters?.[gn]||this.config.authOptions.clientId),this.includeRedirectUri?t.addRedirectUri(e.redirectUri):wn.validateRedirectUri(e.redirectUri),t.addScopes(e.scopes,!0,this.oidcDefaultScopes),t.addAuthorizationCode(e.code),t.addLibraryInfo(this.config.libraryInfo),t.addApplicationTelemetry(this.config.telemetry.application),t.addThrottling(),this.serverTelemetryManager&&!_t(this.config)&&t.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&t.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&t.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const i=this.config.clientCredentials.clientAssertion;t.addClientAssertion(await _n(i.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),t.addClientAssertionType(i.assertionType)}if(t.addGrantType(n.$x.AUTHORIZATION_CODE_GRANT),t.addClientInfo(),e.authenticationScheme===n.IO.POP){const i=new An(this.cryptoUtils,this.performanceClient);let r;r=e.popKid?this.cryptoUtils.encodeKid(e.popKid):(await Lr(i.generateCnf.bind(i),bi,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,t.addPopToken(r)}else if(e.authenticationScheme===n.IO.SSH){if(!e.sshJwk)throw Qe(Be);t.addSshJwk(e.sshJwk)}const i=e.correlationId||this.config.cryptoInterface.createNewGuid();let r;if(t.addCorrelationId(i),(!Xe.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.clientInfo)try{const t=Je(e.clientInfo,this.cryptoUtils.base64Decode);r={credential:`${t.uid}${n.LR.CLIENT_INFO_SEPARATOR}${t.utid}`,type:qr}}catch(e){this.logger.verbose("Could not parse client info for CCS Header: "+e)}else r=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&r)switch(r.type){case qr:try{const e=et(r.credential);t.addCcsOid(e)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case Yr:t.addCcsUpn(r.credential)}return e.tokenBodyParameters&&t.addExtraQueryParameters(e.tokenBodyParameters),!e.enableSpaAuthorizationCode||e.tokenBodyParameters&&e.tokenBodyParameters[Cn]||t.addExtraQueryParameters({[Cn]:"1"}),t.createQueryString()}async createAuthCodeUrlQueryString(e){this.performanceClient?.addQueueMeasurement(Si,e.correlationId);const t=new Sn;t.addClientId(e.extraQueryParameters?.[gn]||this.config.authOptions.clientId);const i=[...e.scopes||[],...e.extraScopesToConsent||[]];t.addScopes(i,!0,this.oidcDefaultScopes),t.addRedirectUri(e.redirectUri);const r=e.correlationId||this.config.cryptoInterface.createNewGuid();if(t.addCorrelationId(r),t.addResponseMode(e.responseMode),t.addResponseTypeCode(),t.addLibraryInfo(this.config.libraryInfo),_t(this.config)||t.addApplicationTelemetry(this.config.telemetry.application),t.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&t.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&t.addPrompt(e.prompt),e.domainHint&&t.addDomainHint(e.domainHint),e.prompt!==n._M.SELECT_ACCOUNT)if(e.sid&&e.prompt===n._M.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),t.addSid(e.sid);else if(e.account){const i=this.extractAccountSid(e.account);let r=this.extractLoginHint(e.account);if(r&&e.domainHint&&(this.logger.warning('AuthorizationCodeClient.createAuthCodeUrlQueryString: "domainHint" param is set, skipping opaque "login_hint" claim. Please consider not passing domainHint'),r=null),r){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),t.addLoginHint(r);try{const i=et(e.account.homeAccountId);t.addCcsOid(i)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(i&&e.prompt===n._M.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),t.addSid(i);try{const i=et(e.account.homeAccountId);t.addCcsOid(i)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),t.addLoginHint(e.loginHint),t.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),t.addLoginHint(e.account.username);try{const i=et(e.account.homeAccountId);t.addCcsOid(i)}catch(e){this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),t.addLoginHint(e.loginHint),t.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");if(e.nonce&&t.addNonce(e.nonce),e.state&&t.addState(e.state),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&t.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.addExtraQueryParams(e,t),e.nativeBroker&&(t.addNativeBroker(),e.authenticationScheme===n.IO.POP)){const i=new An(this.cryptoUtils);let r;r=e.popKid?this.cryptoUtils.encodeKid(e.popKid):(await Lr(i.generateCnf.bind(i),bi,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,t.addPopToken(r)}return t.createQueryString()}createLogoutUrlQueryString(e){const t=new Sn;return e.postLogoutRedirectUri&&t.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&t.addCorrelationId(e.correlationId),e.idTokenHint&&t.addIdTokenHint(e.idTokenHint),e.state&&t.addState(e.state),e.logoutHint&&t.addLogoutHint(e.logoutHint),this.addExtraQueryParams(e,t),t.createQueryString()}addExtraQueryParams(e,t){!(e.extraQueryParameters&&e.extraQueryParameters.hasOwnProperty("instance_aware"))&&this.config.authOptions.instanceAware&&(e.extraQueryParameters=e.extraQueryParameters||{},e.extraQueryParameters.instance_aware="true"),e.extraQueryParameters&&t.addExtraQueryParameters(e.extraQueryParameters)}extractAccountSid(e){return e.idTokenClaims?.sid||null}extractLoginHint(e){return e.idTokenClaims?.login_hint||null}}class xn{constructor(e,t){this.cacheOutcome=n.Rv.NOT_APPLICABLE,this.cacheManager=t,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||n.YM.EMPTY_STRING,this.wrapperVer=e.wrapperVer||n.YM.EMPTY_STRING,this.telemetryCacheKey=n.gT.CACHE_KEY+n.LR.CACHE_KEY_SEPARATOR+e.clientId}generateCurrentRequestHeaderValue(){const e=`${this.apiId}${n.gT.VALUE_SEPARATOR}${this.cacheOutcome}`,t=[this.wrapperSKU,this.wrapperVer],i=this.getNativeBrokerErrorCode();i?.length&&t.push(`broker_error=${i}`);const r=t.join(n.gT.VALUE_SEPARATOR),s=[e,this.getRegionDiscoveryFields()].join(n.gT.VALUE_SEPARATOR);return[n.gT.SCHEMA_VERSION,s,r].join(n.gT.CATEGORY_SEPARATOR)}generateLastRequestHeaderValue(){const e=this.getLastRequests(),t=xn.maxErrorsToSend(e),i=e.failedRequests.slice(0,2*t).join(n.gT.VALUE_SEPARATOR),r=e.errors.slice(0,t).join(n.gT.VALUE_SEPARATOR),s=e.errors.length,o=[s,t<s?n.gT.OVERFLOW_TRUE:n.gT.OVERFLOW_FALSE].join(n.gT.VALUE_SEPARATOR);return[n.gT.SCHEMA_VERSION,e.cacheHits,i,r,o].join(n.gT.CATEGORY_SEPARATOR)}cacheFailedRequest(e){const t=this.getLastRequests();t.errors.length>=n.gT.MAX_CACHED_ERRORS&&(t.failedRequests.shift(),t.failedRequests.shift(),t.errors.shift()),t.failedRequests.push(this.apiId,this.correlationId),e instanceof Error&&e&&e.toString()?e instanceof l.lR?e.subError?t.errors.push(e.subError):e.errorCode?t.errors.push(e.errorCode):t.errors.push(e.toString()):t.errors.push(e.toString()):t.errors.push(n.gT.UNKNOWN_ERROR),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)}incrementCacheHits(){const e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e),e.cacheHits}getLastRequests(){return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||{failedRequests:[],errors:[],cacheHits:0}}clearTelemetryCache(){const e=this.getLastRequests(),t=xn.maxErrorsToSend(e);if(t===e.errors.length)this.cacheManager.removeItem(this.telemetryCacheKey);else{const i={failedRequests:e.failedRequests.slice(2*t),errors:e.errors.slice(t),cacheHits:0};this.cacheManager.setServerTelemetry(this.telemetryCacheKey,i)}}static maxErrorsToSend(e){let t,i=0,r=0;const s=e.errors.length;for(t=0;t<s;t++){const s=e.failedRequests[2*t]||n.YM.EMPTY_STRING,o=e.failedRequests[2*t+1]||n.YM.EMPTY_STRING,a=e.errors[t]||n.YM.EMPTY_STRING;if(r+=s.toString().length+o.toString().length+a.length+3,!(r<n.gT.MAX_LAST_HEADER_BYTES))break;i+=1}return i}getRegionDiscoveryFields(){const e=[];return e.push(this.regionUsed||n.YM.EMPTY_STRING),e.push(this.regionSource||n.YM.EMPTY_STRING),e.push(this.regionOutcome||n.YM.EMPTY_STRING),e.join(",")}updateRegionDiscoveryMetadata(e){this.regionUsed=e.region_used,this.regionSource=e.region_source,this.regionOutcome=e.region_outcome}setCacheOutcome(e){this.cacheOutcome=e}setNativeBrokerErrorCode(e){const t=this.getLastRequests();t.nativeBrokerErrorCode=e,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,t)}getNativeBrokerErrorCode(){return this.getLastRequests().nativeBrokerErrorCode}clearNativeBrokerErrorCode(){const e=this.getLastRequests();delete e.nativeBrokerErrorCode,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e)}static makeExtraSkuString(e){return function(e){const{skus:t,libraryName:i,libraryVersion:r,extensionName:n,extensionVersion:s}=e,o=new Map([[0,[i,r]],[2,[n,s]]]);let a=[];if(t?.length){if(a=t.split(","),a.length<4)return t}else a=Array.from({length:4},()=>"|");return o.forEach((e,t)=>{2===e.length&&e[0]?.length&&e[1]?.length&&function(e){const{skuArr:t,index:i,skuName:r,skuVersion:n}=e;i>=t.length||(t[i]=[r,n].join("|"))}({skuArr:a,index:t,skuName:e[0],skuVersion:e[1]})}),a.join(",")}(e)}}class Dn{constructor(e,t,i,r,n,s,o,a,l){this.config=e,this.browserStorage=t,this.browserCrypto=i,this.networkClient=this.config.system.networkClient,this.eventHandler=n,this.navigationClient=s,this.nativeMessageHandler=a,this.correlationId=l||Ar(),this.logger=r.clone(Xi.Q1.MSAL_SKU,ir,this.correlationId),this.performanceClient=o}async clearCacheOnLogout(e){if(e){st.accountInfoIsEqual(e,this.browserStorage.getActiveAccount(),!1)&&(this.logger.verbose("Setting active account to null"),this.browserStorage.setActiveAccount(null));try{await this.browserStorage.removeAccount(st.generateAccountCacheKey(e)),this.logger.verbose("Cleared cache items belonging to the account provided in the logout request.")}catch(e){this.logger.error("Account provided in logout request was not found. Local cache unchanged.")}}else try{this.logger.verbose("No account provided in logout request, clearing all cache items.",this.correlationId),await this.browserStorage.clear(),await this.browserCrypto.clearKeystore()}catch(e){this.logger.error("Attempted to clear all MSAL cache items and failed. Local cache unchanged.")}}getRedirectUri(e){this.logger.verbose("getRedirectUri called");const t=e||this.config.auth.redirectUri||rn();return lt.getAbsoluteUrl(t,rn())}initializeServerTelemetryManager(e,t){this.logger.verbose("initializeServerTelemetryManager called");const i={clientId:this.config.auth.clientId,correlationId:this.correlationId,apiId:e,forceRefresh:t||!1,wrapperSKU:this.browserStorage.getWrapperMetadata()[0],wrapperVer:this.browserStorage.getWrapperMetadata()[1]};return new xn(i,this.browserStorage)}async getDiscoveredAuthority(e){const{account:t}=e,i=e.requestExtraQueryParameters&&e.requestExtraQueryParameters.hasOwnProperty("instance_aware")?e.requestExtraQueryParameters.instance_aware:void 0;this.performanceClient.addQueueMeasurement(zt,this.correlationId);const r={protocolMode:this.config.auth.protocolMode,OIDCOptions:this.config.auth.OIDCOptions,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},n=e.requestAuthority||this.config.auth.authority,s=i?.length?"true"===i:this.config.auth.instanceAware,o=t&&s?this.config.auth.authority.replace(lt.getDomainFromUrl(n),t.environment):n,a=Or.generateAuthority(o,e.requestAzureCloudOptions||this.config.auth.azureCloudOptions),l=await Lr(bn,Mi,this.logger,this.performanceClient,this.correlationId)(a,this.config.system.networkClient,this.browserStorage,r,this.logger,this.correlationId,this.performanceClient);if(t&&!l.isAlias(t.environment))throw Qe($e);return l}}async function In(e,t,i){e.addQueueMeasurement(Ui,i);const r=Ir(Ln,Wi,t,e,i)(e,t,i);return{verifier:r,challenge:await Lr(Nn,ji,t,e,i)(r,e,t,i)}}function Ln(e,t,i){try{const r=new Uint8Array(32);return Ir(br,$i,t,e,i)(r),dr(r)}catch(e){throw(0,Ji.bD)(er.p5)}}async function Nn(e,t,i,r){t.addQueueMeasurement(ji,r);try{const n=await Lr(Sr,Ki,i,t,r)(e,t,r);return dr(new Uint8Array(n))}catch(e){throw(0,Ji.bD)(er.p5)}}async function On(e,t,i,r){i.addQueueMeasurement(ii,e.correlationId);const s=e.authority||t.auth.authority,o=[...e&&e.scopes||[]],a={...e,correlationId:e.correlationId,authority:s,scopes:o};if(a.authenticationScheme){if(a.authenticationScheme===n.IO.SSH){if(!e.sshJwk)throw Qe(Be);if(!e.sshKid)throw Qe(ze)}r.verbose(`Authentication Scheme set to "${a.authenticationScheme}" as configured in Auth request`)}else a.authenticationScheme=n.IO.BEARER,r.verbose('Authentication Scheme wasn\'t explicitly set in request, defaulting to "Bearer" request');return t.cache.claimsBasedCachingEnabled&&e.claims&&!Xe.isEmptyObj(e.claims)&&(a.requestedClaimsHash=await Mr(e.claims)),a}async function Fn(e,t,i,r,n){r.addQueueMeasurement(ri,e.correlationId);const s=await Lr(On,ii,n,r,e.correlationId)(e,i,r,n);return{...e,...s,account:t,forceRefresh:e.forceRefresh||!1}}class kn extends Dn{async initializeAuthorizationCodeRequest(e){this.performanceClient.addQueueMeasurement(pi,this.correlationId);const t=await Lr(In,Ui,this.logger,this.performanceClient,this.correlationId)(this.performanceClient,this.logger,this.correlationId),i={...e,redirectUri:e.redirectUri,code:n.YM.EMPTY_STRING,codeVerifier:t.verifier};return e.codeChallenge=t.challenge,e.codeChallengeMethod=n.YM.S256_CODE_CHALLENGE_METHOD,i}initializeLogoutRequest(e){this.logger.verbose("initializeLogoutRequest called",e?.correlationId);const t={correlationId:this.correlationId||Ar(),...e};if(e)if(e.logoutHint)this.logger.verbose("logoutHint has already been set in logoutRequest");else if(e.account){const i=this.getLogoutHintFromIdTokenClaims(e.account);i&&(this.logger.verbose("Setting logoutHint to login_hint ID Token Claim value for the account provided"),t.logoutHint=i)}else this.logger.verbose("logoutHint was not set and account was not passed into logout request, logoutHint will not be set");else this.logger.verbose("logoutHint will not be set since no logout request was configured");return e&&null===e.postLogoutRedirectUri?this.logger.verbose("postLogoutRedirectUri passed as null, not setting post logout redirect uri",t.correlationId):e&&e.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to uri set on logout request",t.correlationId),t.postLogoutRedirectUri=lt.getAbsoluteUrl(e.postLogoutRedirectUri,rn())):null===this.config.auth.postLogoutRedirectUri?this.logger.verbose("postLogoutRedirectUri configured as null and no uri set on request, not passing post logout redirect",t.correlationId):this.config.auth.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to configured uri",t.correlationId),t.postLogoutRedirectUri=lt.getAbsoluteUrl(this.config.auth.postLogoutRedirectUri,rn())):(this.logger.verbose("Setting postLogoutRedirectUri to current page",t.correlationId),t.postLogoutRedirectUri=lt.getAbsoluteUrl(rn(),rn())),t}getLogoutHintFromIdTokenClaims(e){const t=e.idTokenClaims;if(t){if(t.login_hint)return t.login_hint;this.logger.verbose("The ID Token Claims tied to the provided account do not contain a login_hint claim, logoutHint will not be added to logout request")}else this.logger.verbose("The provided account does not contain ID Token Claims, logoutHint will not be added to logout request");return null}async createAuthCodeClient(e){this.performanceClient.addQueueMeasurement(ui,this.correlationId);const t=await Lr(this.getClientConfiguration.bind(this),hi,this.logger,this.performanceClient,this.correlationId)(e);return new Pn(t,this.performanceClient)}async getClientConfiguration(e){const{serverTelemetryManager:t,requestAuthority:i,requestAzureCloudOptions:r,requestExtraQueryParameters:s,account:o}=e;this.performanceClient.addQueueMeasurement(hi,this.correlationId);const a=await Lr(this.getDiscoveredAuthority.bind(this),zt,this.logger,this.performanceClient,this.correlationId)({requestAuthority:i,requestAzureCloudOptions:r,requestExtraQueryParameters:s,account:o}),l=this.config.system.loggerOptions;return{authOptions:{clientId:this.config.auth.clientId,authority:a,clientCapabilities:this.config.auth.clientCapabilities},systemOptions:{tokenRenewalOffsetSeconds:this.config.system.tokenRenewalOffsetSeconds,preventCorsPreflight:!0},loggerOptions:{loggerCallback:l.loggerCallback,piiLoggingEnabled:l.piiLoggingEnabled,logLevel:l.logLevel,correlationId:this.correlationId},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.browserCrypto,networkInterface:this.networkClient,storageInterface:this.browserStorage,serverTelemetryManager:t,libraryInfo:{sku:Xi.Q1.MSAL_SKU,version:ir,cpu:n.YM.EMPTY_STRING,os:n.YM.EMPTY_STRING},telemetry:this.config.telemetry}}async initializeAuthorizationRequest(e,t){this.performanceClient.addQueueMeasurement(di,this.correlationId);const i=this.getRedirectUri(e.redirectUri),r={interactionType:t},s=$r.setRequestState(this.browserCrypto,e&&e.state||n.YM.EMPTY_STRING,r),o={...await Lr(On,ii,this.logger,this.performanceClient,this.correlationId)({...e,correlationId:this.correlationId},this.config,this.performanceClient,this.logger),redirectUri:i,state:s,nonce:e.nonce||Ar(),responseMode:this.config.auth.OIDCOptions.serverResponseType},a=e.account||this.browserStorage.getActiveAccount();if(a&&(this.logger.verbose("Setting validated request account",this.correlationId),this.logger.verbosePii(`Setting validated request account: ${a.homeAccountId}`,this.correlationId),o.account=a),!o.loginHint&&!a){const e=this.browserStorage.getLegacyLoginHint();e&&(o.loginHint=e)}return o}}var Gn=i(5841);const Vn="user_switch",Hn={[Vn]:"User attempted to switch accounts in the native broker, which is not allowed. All new accounts must sign-in through the standard web flow first, please try again."};class Bn extends l.lR{constructor(e,t,i){super(e,t),Object.setPrototypeOf(this,Bn.prototype),this.name="NativeAuthError",this.ext=i}}function zn(e){return!(!e.ext||!e.ext.status||"PERSISTENT_ERROR"!==e.ext.status&&"DISABLED"!==e.ext.status)||!(!e.ext||!e.ext.error||-2147186943!==e.ext.error)||"ContentError"===e.errorCode}function Un(e,t,i){if(i&&i.status)switch(i.status){case"ACCOUNT_UNAVAILABLE":return Kr(Gr);case"USER_INTERACTION_REQUIRED":return new Wr(e,t);case"USER_CANCEL":return(0,Ji.bD)(er.fN);case"NO_NETWORK":return(0,Ji.bD)(er.l7)}return new Bn(e,Hn[e]||t,i)}class Wn extends En{constructor(e,t){super(e,t)}async acquireToken(e){this.performanceClient?.addQueueMeasurement(qt,e.correlationId);const t=ae(),i=await Lr(this.executeTokenRequest.bind(this),$t,this.logger,this.performanceClient,e.correlationId)(e,this.authority),r=i.headers?.[n.OK.X_MS_REQUEST_ID],s=new Mn(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return s.validateTokenResponse(i.body),Lr(s.handleServerTokenResponse.bind(s),Ai,this.logger,this.performanceClient,e.correlationId)(i.body,this.authority,t,e,void 0,void 0,!0,e.forceCache,r)}async acquireTokenByRefreshToken(e){if(!e)throw Qe(Ne);if(this.performanceClient?.addQueueMeasurement(Qt,e.correlationId),!e.account)throw te(L);if(this.cacheManager.isAppMetadataFOCI(e.account.environment))try{return await Lr(this.acquireTokenWithCachedRefreshToken.bind(this),Yt,this.logger,this.performanceClient,e.correlationId)(e,!0)}catch(t){const i=t instanceof Wr&&t.errorCode===kr,r=t instanceof hn&&t.errorCode===n.I.INVALID_GRANT_ERROR&&t.subError===n.I.CLIENT_MISMATCH_ERROR;if(i||r)return Lr(this.acquireTokenWithCachedRefreshToken.bind(this),Yt,this.logger,this.performanceClient,e.correlationId)(e,!1);throw t}return Lr(this.acquireTokenWithCachedRefreshToken.bind(this),Yt,this.logger,this.performanceClient,e.correlationId)(e,!1)}async acquireTokenWithCachedRefreshToken(e,t){this.performanceClient?.addQueueMeasurement(Yt,e.correlationId);const i=Ir(this.cacheManager.getRefreshToken.bind(this.cacheManager),zi,this.logger,this.performanceClient,e.correlationId)(e.account,t,void 0,this.performanceClient,e.correlationId);if(!i)throw Kr(kr);if(i.expiresOn&&le(i.expiresOn,e.refreshTokenExpirationOffsetSeconds||300))throw Kr(Vr);const r={...e,refreshToken:i.secret,authenticationScheme:e.authenticationScheme||n.IO.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:qr}};try{return await Lr(this.acquireToken.bind(this),qt,this.logger,this.performanceClient,e.correlationId)(r)}catch(e){if(e instanceof Wr&&e.subError===Hr){this.logger.verbose("acquireTokenWithRefreshToken: bad refresh token, removing from cache");const e=ce(i);this.cacheManager.removeRefreshToken(e)}throw e}}async executeTokenRequest(e,t){this.performanceClient?.addQueueMeasurement($t,e.correlationId);const i=this.createTokenQueryParameters(e),r=lt.appendQueryString(t.tokenEndpoint,i),n=await Lr(this.createTokenRequestBody.bind(this),Xt,this.logger,this.performanceClient,e.correlationId)(e),s=this.createTokenRequestHeaders(e.ccsCredential),o={clientId:e.tokenBodyParameters?.clientId||this.config.authOptions.clientId,authority:t.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return Lr(this.executePostToTokenEndpoint.bind(this),jt,this.logger,this.performanceClient,e.correlationId)(r,n,s,o,e.correlationId,jt)}async createTokenRequestBody(e){this.performanceClient?.addQueueMeasurement(Xt,e.correlationId);const t=e.correlationId,i=new Sn;if(i.addClientId(e.tokenBodyParameters?.[gn]||this.config.authOptions.clientId),e.redirectUri&&i.addRedirectUri(e.redirectUri),i.addScopes(e.scopes,!0,this.config.authOptions.authority.options.OIDCOptions?.defaultScopes),i.addGrantType(n.$x.REFRESH_TOKEN_GRANT),i.addClientInfo(),i.addLibraryInfo(this.config.libraryInfo),i.addApplicationTelemetry(this.config.telemetry.application),i.addThrottling(),this.serverTelemetryManager&&!_t(this.config)&&i.addServerTelemetry(this.serverTelemetryManager),i.addCorrelationId(t),i.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&i.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const t=this.config.clientCredentials.clientAssertion;i.addClientAssertion(await _n(t.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),i.addClientAssertionType(t.assertionType)}if(e.authenticationScheme===n.IO.POP){const t=new An(this.cryptoUtils,this.performanceClient);let r;r=e.popKid?this.cryptoUtils.encodeKid(e.popKid):(await Lr(t.generateCnf.bind(t),bi,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,i.addPopToken(r)}else if(e.authenticationScheme===n.IO.SSH){if(!e.sshJwk)throw Qe(Be);i.addSshJwk(e.sshJwk)}if((!Xe.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&i.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case qr:try{const t=et(e.ccsCredential.credential);i.addCcsOid(t)}catch(e){this.logger.verbose("Could not parse home account ID for CCS Header: "+e)}break;case Yr:i.addCcsUpn(e.ccsCredential.credential)}return e.tokenBodyParameters&&i.addExtraQueryParameters(e.tokenBodyParameters),i.createQueryString()}}class jn extends En{constructor(e,t){super(e,t)}async acquireToken(e){try{const[t,i]=await this.acquireCachedToken({...e,scopes:e.scopes?.length?e.scopes:[...n.aZ]});return i===n.Rv.PROACTIVELY_REFRESHED&&(this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'. It's not expired, but must be refreshed."),new Wn(this.config,this.performanceClient).acquireTokenByRefreshToken(e).catch(()=>{})),t}catch(t){if(t instanceof ee&&t.errorCode===B)return new Wn(this.config,this.performanceClient).acquireTokenByRefreshToken(e);throw t}}async acquireCachedToken(e){this.performanceClient?.addQueueMeasurement(Jt,e.correlationId);let t=n.Rv.NOT_APPLICABLE;if(e.forceRefresh||!this.config.cacheOptions.claimsBasedCachingEnabled&&!Xe.isEmptyObj(e.claims))throw this.setCacheOutcome(n.Rv.FORCE_REFRESH_OR_CLAIMS,e.correlationId),te(B);if(!e.account)throw te(L);const i=e.account.tenantId||function(e){const t=new lt(e).getUrlComponents(),i=t.PathSegments.slice(-1)[0]?.toLowerCase();switch(i){case n.v2.COMMON:case n.v2.ORGANIZATIONS:case n.v2.CONSUMERS:return;default:return i}}(e.authority),r=this.cacheManager.getTokenKeys(),s=this.cacheManager.getAccessToken(e.account,e,r,i,this.performanceClient,e.correlationId);if(!s)throw this.setCacheOutcome(n.Rv.NO_CACHED_ACCESS_TOKEN,e.correlationId),te(B);if(o=s.cachedAt,Number(o)>ae()||le(s.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw this.setCacheOutcome(n.Rv.CACHED_ACCESS_TOKEN_EXPIRED,e.correlationId),te(B);var o;s.refreshOn&&le(s.refreshOn,0)&&(t=n.Rv.PROACTIVELY_REFRESHED);const a=e.authority||this.authority.getPreferredCache(),l={account:this.cacheManager.readAccountFromCache(e.account),accessToken:s,idToken:this.cacheManager.getIdToken(e.account,r,i,this.performanceClient,e.correlationId),refreshToken:null,appMetadata:this.cacheManager.readAppMetadataFromCache(a)};return this.setCacheOutcome(t,e.correlationId),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[await Lr(this.generateResultFromCacheRecord.bind(this),ei,this.logger,this.performanceClient,e.correlationId)(l,e),t]}setCacheOutcome(e,t){this.serverTelemetryManager?.setCacheOutcome(e),this.performanceClient?.addFields({cacheOutcome:e},t),e!==n.Rv.NOT_APPLICABLE&&this.logger.info(`Token refresh is required due to cache outcome: ${e}`)}async generateResultFromCacheRecord(e,t){let i;if(this.performanceClient?.addQueueMeasurement(ei,t.correlationId),e.idToken&&(i=se(e.idToken.secret,this.config.cryptoInterface.base64Decode)),t.maxAge||0===t.maxAge){const e=i?.auth_time;if(!e)throw te(S);oe(e,t.maxAge)}return Mn.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,t,i)}}class Kn extends kn{async acquireToken(e){this.performanceClient.addQueueMeasurement(Gt,e.correlationId);const t=this.initializeServerTelemetryManager(Xi.sA.acquireTokenSilent_silentFlow),i=await Lr(this.getClientConfiguration.bind(this),hi,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:t,requestAuthority:e.authority,requestAzureCloudOptions:e.azureCloudOptions,account:e.account}),r=new jn(i,this.performanceClient);this.logger.verbose("Silent auth client created");try{const t=(await Lr(r.acquireCachedToken.bind(r),Jt,this.logger,this.performanceClient,e.correlationId)(e))[0];return this.performanceClient.addFields({fromCache:!0},e.correlationId),t}catch(e){throw e instanceof Ji.jT&&e.errorCode===er.e0&&this.logger.verbose("Signing keypair for bound access token not found. Refreshing bound access token and generating a new crypto keypair."),e}}logout(e){this.logger.verbose("logoutRedirect called");const t=this.initializeLogoutRequest(e);return this.clearCacheOnLogout(t?.account)}}const $n="brk_redirect_uri";class qn extends Dn{constructor(e,t,i,r,n,s,o,a,l,c,u,h){super(e,t,i,r,n,s,a,l,h),this.apiId=o,this.accountId=c,this.nativeMessageHandler=l,this.nativeStorageManager=u,this.silentCacheClient=new Kn(e,this.nativeStorageManager,i,r,n,s,a,l,h),this.serverTelemetryManager=this.initializeServerTelemetryManager(this.apiId);const d=this.nativeMessageHandler.getExtensionId()===Xi.JD.PREFERRED_EXTENSION_ID?"chrome":this.nativeMessageHandler.getExtensionId()?.length?"unknown":void 0;this.skus=xn.makeExtraSkuString({libraryName:Xi.Q1.MSAL_SKU,libraryVersion:ir,extensionName:d,extensionVersion:this.nativeMessageHandler.getExtensionVersion()})}addRequestSKUs(e){e.extraParameters={...e.extraParameters,[yn]:this.skus}}async acquireToken(e){this.performanceClient.addQueueMeasurement(Wt,e.correlationId),this.logger.trace("NativeInteractionClient - acquireToken called.");const t=this.performanceClient.startMeasurement(Wt,e.correlationId),i=ae();try{const r=await this.initializeNativeRequest(e);try{const e=await this.acquireTokensFromCache(this.accountId,r);return t.end({success:!0,isNativeBroker:!1,fromCache:!0}),e}catch(e){this.logger.info("MSAL internal Cache does not contain tokens, proceed to make a native call")}const{...n}=r,s={method:Xi.Ct.GetToken,request:n},o=await this.nativeMessageHandler.sendMessage(s),a=this.validateNativeResponse(o);return await this.handleNativeResponse(a,r,i).then(e=>(t.end({success:!0,isNativeBroker:!0,requestId:e.requestId}),this.serverTelemetryManager.clearNativeBrokerErrorCode(),e)).catch(e=>{throw t.end({success:!1,errorCode:e.errorCode,subErrorCode:e.subError,isNativeBroker:!0}),e})}catch(e){throw e instanceof Bn&&this.serverTelemetryManager.setNativeBrokerErrorCode(e.errorCode),e}}createSilentCacheRequest(e,t){return{authority:e.authority,correlationId:this.correlationId,scopes:Ze.fromString(e.scope).asArray(),account:t,forceRefresh:!1}}async acquireTokensFromCache(e,t){if(!e)throw this.logger.warning("NativeInteractionClient:acquireTokensFromCache - No nativeAccountId provided"),te(F);const i=this.browserStorage.getBaseAccountInfo({nativeAccountId:e});if(!i)throw te(F);try{const e=this.createSilentCacheRequest(t,i),r=await this.silentCacheClient.acquireToken(e),n={...i,idTokenClaims:r?.idTokenClaims,idToken:r?.idToken};return{...r,account:n}}catch(e){throw e}}async acquireTokenRedirect(e,t){this.logger.trace("NativeInteractionClient - acquireTokenRedirect called.");const{...i}=e;delete i.onRedirectNavigate;const r=await this.initializeNativeRequest(i),n={method:Xi.Ct.GetToken,request:r};try{const e=await this.nativeMessageHandler.sendMessage(n);this.validateNativeResponse(e)}catch(e){if(e instanceof Bn&&(this.serverTelemetryManager.setNativeBrokerErrorCode(e.errorCode),zn(e)))throw e}this.browserStorage.setTemporaryCache(Xi._p.NATIVE_REQUEST,JSON.stringify(r),!0);const s={apiId:Xi.sA.acquireTokenRedirect,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},o=this.config.auth.navigateToLoginRequestUrl?window.location.href:this.getRedirectUri(e.redirectUri);t.end({success:!0}),await this.navigationClient.navigateExternal(o,s)}async handleRedirectPromise(e,t){if(this.logger.trace("NativeInteractionClient - handleRedirectPromise called."),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const i=this.browserStorage.getCachedNativeRequest();if(!i)return this.logger.verbose("NativeInteractionClient - handleRedirectPromise called but there is no cached request, returning null."),e&&t&&e?.addFields({errorCode:"no_cached_request"},t),null;const{prompt:r,...n}=i;r&&this.logger.verbose("NativeInteractionClient - handleRedirectPromise called and prompt was included in the original request, removing prompt from cached request to prevent second interaction with native broker window."),this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Xi._p.NATIVE_REQUEST));const s={method:Xi.Ct.GetToken,request:n},o=ae();try{this.logger.verbose("NativeInteractionClient - handleRedirectPromise sending message to native broker.");const e=await this.nativeMessageHandler.sendMessage(s);this.validateNativeResponse(e);const t=this.handleNativeResponse(e,n,o);this.browserStorage.setInteractionInProgress(!1);const i=await t;return this.serverTelemetryManager.clearNativeBrokerErrorCode(),i}catch(e){throw this.browserStorage.setInteractionInProgress(!1),e}}logout(){return this.logger.trace("NativeInteractionClient - logout called."),Promise.reject("Logout not implemented yet")}async handleNativeResponse(e,t,i){this.logger.trace("NativeInteractionClient - handleNativeResponse called.");const r=se(e.id_token,fr),n=this.createHomeAccountIdentifier(e,r),s=this.browserStorage.getAccountInfoFilteredBy({nativeAccountId:t.accountId})?.homeAccountId;if(n!==s&&e.account.id!==t.accountId)throw Un(Vn);const o=await this.getDiscoveredAuthority({requestAuthority:t.authority}),a=Rn(this.browserStorage,o,n,fr,r,e.client_info,void 0,r.tid,void 0,e.account.id,this.logger),l=await this.generateAuthenticationResult(e,t,r,a,o.canonicalAuthority,i);return this.cacheAccount(a),this.cacheNativeTokens(e,t,n,r,e.access_token,l.tenantId,i),l}createHomeAccountIdentifier(e,t){return st.generateHomeAccountId(e.client_info||n.YM.EMPTY_STRING,0,this.logger,this.browserCrypto,t)}generateScopes(e,t){return e.scope?Ze.fromString(e.scope):Ze.fromString(t.scope)}async generatePopAccessToken(e,t){if(t.tokenType===n.IO.POP&&t.signPopToken){if(e.shr)return this.logger.trace("handleNativeServerResponse: SHR is enabled in native layer"),e.shr;const i=new An(this.browserCrypto),r={resourceRequestMethod:t.resourceRequestMethod,resourceRequestUri:t.resourceRequestUri,shrClaims:t.shrClaims,shrNonce:t.shrNonce};if(!t.keyId)throw te($);return i.signPopToken(e.access_token,t.keyId,r)}return e.access_token}async generateAuthenticationResult(e,t,i,r,s,o){const a=this.addTelemetryFromNativeResponse(e),l=e.scope?Ze.fromString(e.scope):Ze.fromString(t.scope),c=e.account.properties||{},u=c.UID||i.oid||i.sub||n.YM.EMPTY_STRING,h=c.TenantId||i.tid||n.YM.EMPTY_STRING,d=rt(r.getAccountInfo(),void 0,i,e.id_token);d.nativeAccountId!==e.account.id&&(d.nativeAccountId=e.account.id);const p=await this.generatePopAccessToken(e,t),g=t.tokenType===n.IO.POP?n.IO.POP:n.IO.BEARER;return{authority:s,uniqueId:u,tenantId:h,scopes:l.asArray(),account:d,idToken:e.id_token,idTokenClaims:i,accessToken:p,fromCache:!!a&&this.isResponseFromCache(a),expiresOn:new Date(1e3*Number(o+e.expires_in)),tokenType:g,correlationId:this.correlationId,state:e.state,fromNativeBroker:!0}}cacheAccount(e){this.browserStorage.setAccount(e),this.browserStorage.removeAccountContext(e).catch(e=>{this.logger.error(`Error occurred while removing account context from browser storage. ${e}`)})}cacheNativeTokens(e,t,i,r,s,o,a){const l=ue(i,t.authority,e.id_token||"",t.clientId,r.tid||""),c=a+(t.tokenType===n.IO.POP?n.YM.SHR_NONCE_VALIDITY:("string"==typeof e.expires_in?parseInt(e.expires_in,10):e.expires_in)||0),u=this.generateScopes(e,t),h={idToken:l,accessToken:he(i,t.authority,s,t.clientId,r.tid||o,u.printScopes(),c,0,fr,void 0,t.tokenType,void 0,t.keyId)};this.nativeStorageManager.saveCacheRecord(h,t.storeInCache)}addTelemetryFromNativeResponse(e){const t=this.getMATSFromResponse(e);return t?(this.performanceClient.addFields({extensionId:this.nativeMessageHandler.getExtensionId(),extensionVersion:this.nativeMessageHandler.getExtensionVersion(),matsBrokerVersion:t.broker_version,matsAccountJoinOnStart:t.account_join_on_start,matsAccountJoinOnEnd:t.account_join_on_end,matsDeviceJoin:t.device_join,matsPromptBehavior:t.prompt_behavior,matsApiErrorCode:t.api_error_code,matsUiVisible:t.ui_visible,matsSilentCode:t.silent_code,matsSilentBiSubCode:t.silent_bi_sub_code,matsSilentMessage:t.silent_message,matsSilentStatus:t.silent_status,matsHttpStatus:t.http_status,matsHttpEventCount:t.http_event_count},this.correlationId),t):null}validateNativeResponse(e){if(e.hasOwnProperty("access_token")&&e.hasOwnProperty("id_token")&&e.hasOwnProperty("client_info")&&e.hasOwnProperty("account")&&e.hasOwnProperty("scope")&&e.hasOwnProperty("expires_in"))return e;throw(0,l.pz)(Gn.W,"Response missing expected properties.")}getMATSFromResponse(e){if(e.properties.MATS)try{return JSON.parse(e.properties.MATS)}catch(e){this.logger.error("NativeInteractionClient - Error parsing MATS telemetry, returning null instead")}return null}isResponseFromCache(e){return void 0===e.is_cached?(this.logger.verbose("NativeInteractionClient - MATS telemetry does not contain field indicating if response was served from cache. Returning false."),!1):!!e.is_cached}async initializeNativeRequest(e){this.logger.trace("NativeInteractionClient - initializeNativeRequest called");const t=e.authority||this.config.auth.authority;e.account&&await this.getDiscoveredAuthority({requestAuthority:t,requestAzureCloudOptions:e.azureCloudOptions,account:e.account});const i=new lt(t);i.validateAsUri();const{scopes:r,...s}=e,o=new Ze(r||[]);o.appendScopes(n.aZ);const a={...s,accountId:this.accountId,clientId:this.config.auth.clientId,authority:i.urlString,scope:o.printScopes(),redirectUri:this.getRedirectUri(e.redirectUri),prompt:(()=>{switch(this.apiId){case Xi.sA.ssoSilent:case Xi.sA.acquireTokenSilent_silentFlow:return this.logger.trace("initializeNativeRequest: silent request sets prompt to none"),n._M.NONE}if(e.prompt)switch(e.prompt){case n._M.NONE:case n._M.CONSENT:case n._M.LOGIN:return this.logger.trace("initializeNativeRequest: prompt is compatible with native flow"),e.prompt;default:throw this.logger.trace(`initializeNativeRequest: prompt = ${e.prompt} is not compatible with native flow`),(0,Ji.bD)(er.nF)}else this.logger.trace("initializeNativeRequest: prompt was not provided")})(),correlationId:this.correlationId,tokenType:e.authenticationScheme,windowTitleSubstring:document.title,extraParameters:{...e.extraQueryParameters,...e.tokenQueryParameters},extendedExpiryToken:!1,keyId:e.popKid};if(a.signPopToken&&e.popKid)throw(0,Ji.bD)(er.bT);if(this.handleExtraBrokerParams(a),a.extraParameters=a.extraParameters||{},a.extraParameters.telemetry=Xi.JD.MATS_TELEMETRY,e.authenticationScheme===n.IO.POP){const t={resourceRequestUri:e.resourceRequestUri,resourceRequestMethod:e.resourceRequestMethod,shrClaims:e.shrClaims,shrNonce:e.shrNonce},i=new An(this.browserCrypto);let r;if(a.keyId)r=this.browserCrypto.base64UrlEncode(JSON.stringify({kid:a.keyId})),a.signPopToken=!1;else{const n=await Lr(i.generateCnf.bind(i),bi,this.logger,this.performanceClient,e.correlationId)(t,this.logger);r=n.reqCnfString,a.keyId=n.kid,a.signPopToken=!0}a.reqCnf=r}return this.addRequestSKUs(a),a}handleExtraBrokerParams(e){if(e.extraParameters&&e.extraParameters.hasOwnProperty("brk_client_id")&&e.extraParameters.hasOwnProperty($n)&&e.extraParameters.hasOwnProperty(gn)){const t=e.extraParameters[gn],i=e.redirectUri,r=e.extraParameters[$n];e.extraParameters={child_client_id:t,child_redirect_uri:i},e.redirectUri=r}}}class Yn{constructor(e,t,i,r){this.logger=e,this.handshakeTimeoutMs=t,this.extensionId=r,this.resolvers=new Map,this.handshakeResolvers=new Map,this.messageChannel=new MessageChannel,this.windowListener=this.onWindowMessage.bind(this),this.performanceClient=i,this.handshakeEvent=i.startMeasurement(Vi)}async sendMessage(e){this.logger.trace("NativeMessageHandler - sendMessage called.");const t={channel:Xi.JD.CHANNEL_ID,extensionId:this.extensionId,responseId:Ar(),body:e};return this.logger.trace("NativeMessageHandler - Sending request to browser extension"),this.logger.tracePii(`NativeMessageHandler - Sending request to browser extension: ${JSON.stringify(t)}`),this.messageChannel.port1.postMessage(t),new Promise((e,i)=>{this.resolvers.set(t.responseId,{resolve:e,reject:i})})}static async createProvider(e,t,i){e.trace("NativeMessageHandler - createProvider called.");try{const r=new Yn(e,t,i,Xi.JD.PREFERRED_EXTENSION_ID);return await r.sendHandshakeRequest(),r}catch(r){const n=new Yn(e,t,i);return await n.sendHandshakeRequest(),n}}async sendHandshakeRequest(){this.logger.trace("NativeMessageHandler - sendHandshakeRequest called."),window.addEventListener("message",this.windowListener,!1);const e={channel:Xi.JD.CHANNEL_ID,extensionId:this.extensionId,responseId:Ar(),body:{method:Xi.Ct.HandshakeRequest}};return this.handshakeEvent.add({extensionId:this.extensionId,extensionHandshakeTimeoutMs:this.handshakeTimeoutMs}),this.messageChannel.port1.onmessage=e=>{this.onChannelMessage(e)},window.postMessage(e,window.origin,[this.messageChannel.port2]),new Promise((t,i)=>{this.handshakeResolvers.set(e.responseId,{resolve:t,reject:i}),this.timeoutId=window.setTimeout(()=>{window.removeEventListener("message",this.windowListener,!1),this.messageChannel.port1.close(),this.messageChannel.port2.close(),this.handshakeEvent.end({extensionHandshakeTimedOut:!0,success:!1}),i((0,Ji.bD)(er.y3)),this.handshakeResolvers.delete(e.responseId)},this.handshakeTimeoutMs)})}onWindowMessage(e){if(this.logger.trace("NativeMessageHandler - onWindowMessage called"),e.source!==window)return;const t=e.data;if(t.channel&&t.channel===Xi.JD.CHANNEL_ID&&(!t.extensionId||t.extensionId===this.extensionId)&&t.body.method===Xi.Ct.HandshakeRequest){const e=this.handshakeResolvers.get(t.responseId);if(!e)return void this.logger.trace(`NativeMessageHandler.onWindowMessage - resolver can't be found for request ${t.responseId}`);this.logger.verbose(t.extensionId?`Extension with id: ${t.extensionId} not installed`:"No extension installed"),clearTimeout(this.timeoutId),this.messageChannel.port1.close(),this.messageChannel.port2.close(),window.removeEventListener("message",this.windowListener,!1),this.handshakeEvent.end({success:!1,extensionInstalled:!1}),e.reject((0,Ji.bD)(er.cq))}}onChannelMessage(e){this.logger.trace("NativeMessageHandler - onChannelMessage called.");const t=e.data,i=this.resolvers.get(t.responseId),r=this.handshakeResolvers.get(t.responseId);try{const e=t.body.method;if(e===Xi.Ct.Response){if(!i)return;const e=t.body.response;if(this.logger.trace("NativeMessageHandler - Received response from browser extension"),this.logger.tracePii(`NativeMessageHandler - Received response from browser extension: ${JSON.stringify(e)}`),"Success"!==e.status)i.reject(Un(e.code,e.description,e.ext));else{if(!e.result)throw(0,l.pz)(Gn.W,"Event does not contain result.");e.result.code&&e.result.description?i.reject(Un(e.result.code,e.result.description,e.result.ext)):i.resolve(e.result)}this.resolvers.delete(t.responseId)}else if(e===Xi.Ct.HandshakeResponse){if(!r)return void this.logger.trace(`NativeMessageHandler.onChannelMessage - resolver can't be found for request ${t.responseId}`);clearTimeout(this.timeoutId),window.removeEventListener("message",this.windowListener,!1),this.extensionId=t.extensionId,this.extensionVersion=t.body.version,this.logger.verbose(`NativeMessageHandler - Received HandshakeResponse from extension: ${this.extensionId}`),this.handshakeEvent.end({extensionInstalled:!0,success:!0}),r.resolve(),this.handshakeResolvers.delete(t.responseId)}}catch(t){this.logger.error("Error parsing response from WAM Extension"),this.logger.errorPii(`Error parsing response from WAM Extension: ${t}`),this.logger.errorPii(`Unable to parse ${e}`),i?i.reject(t):r&&r.reject(t)}}getExtensionId(){return this.extensionId}getExtensionVersion(){return this.extensionVersion}static isNativeAvailable(e,t,i,r){if(t.trace("isNativeAvailable called"),!e.system.allowNativeBroker)return t.trace("isNativeAvailable: allowNativeBroker is not enabled, returning false"),!1;if(!i)return t.trace("isNativeAvailable: WAM extension provider is not initialized, returning false"),!1;if(r)switch(r){case n.IO.BEARER:case n.IO.POP:return t.trace("isNativeAvailable: authenticationScheme is supported, returning true"),!0;default:return t.trace("isNativeAvailable: authenticationScheme is not supported, returning false"),!1}return!0}}class Qn{constructor(e,t,i,r,n){this.authModule=e,this.browserStorage=t,this.authCodeRequest=i,this.logger=r,this.performanceClient=n}async handleCodeResponse(e,t){let i;this.performanceClient.addQueueMeasurement(mi,t.correlationId);try{i=this.authModule.handleFragmentResponse(e,t.state)}catch(e){throw e instanceof hn&&e.subError===er.fN?(0,Ji.bD)(er.fN):e}return Lr(this.handleCodeResponseFromServer.bind(this),fi,this.logger,this.performanceClient,t.correlationId)(i,t)}async handleCodeResponseFromServer(e,t,i=!0){if(this.performanceClient.addQueueMeasurement(fi,t.correlationId),this.logger.trace("InteractionHandler.handleCodeResponseFromServer called"),this.authCodeRequest.code=e.code,e.cloud_instance_host_name&&await Lr(this.authModule.updateAuthority.bind(this.authModule),vi,this.logger,this.performanceClient,t.correlationId)(e.cloud_instance_host_name,t.correlationId),i&&(e.nonce=t.nonce||void 0),e.state=t.state,e.client_info)this.authCodeRequest.clientInfo=e.client_info;else{const e=this.createCcsCredentials(t);e&&(this.authCodeRequest.ccsCredential=e)}return await Lr(this.authModule.acquireToken.bind(this.authModule),Ci,this.logger,this.performanceClient,t.correlationId)(this.authCodeRequest,e)}createCcsCredentials(e){return e.account?{credential:e.account.homeAccountId,type:qr}:e.loginHint?{credential:e.loginHint,type:Yr}:null}}function Xn(e,t,i){const r=at(e);if(!r)throw ot(e)?(i.error(`A ${t} is present in the iframe but it does not contain known properties. It's likely that the ${t} has been replaced by code running on the redirectUri page.`),i.errorPii(`The ${t} detected is: ${e}`),(0,Ji.bD)(er.Lm)):(i.error(`The request has returned to the redirectUri but a ${t} is not present. It's likely that the ${t} has been removed or the page has been redirected by code running on the redirectUri page.`),(0,Ji.bD)(er.wv));return r}class Zn extends kn{constructor(e,t,i,r,n,s,o,a,l,c){super(e,t,i,r,n,s,o,l,c),this.unloadWindow=this.unloadWindow.bind(this),this.nativeStorage=a}acquireToken(e){try{const t={popupName:this.generatePopupName(e.scopes||n.aZ,e.authority||this.config.auth.authority),popupWindowAttributes:e.popupWindowAttributes||{},popupWindowParent:e.popupWindowParent??window};return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true, acquiring token"),this.acquireTokenPopupAsync(e,t)):(this.logger.verbose("asyncPopup set to false, opening popup before acquiring token"),t.popup=this.openSizedPopup("about:blank",t),this.acquireTokenPopupAsync(e,t))}catch(e){return Promise.reject(e)}}logout(e){try{this.logger.verbose("logoutPopup called");const t=this.initializeLogoutRequest(e),i={popupName:this.generateLogoutPopupName(t),popupWindowAttributes:e?.popupWindowAttributes||{},popupWindowParent:e?.popupWindowParent??window},r=e&&e.authority,n=e&&e.mainWindowRedirectUri;return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true"),this.logoutPopupAsync(t,i,r,n)):(this.logger.verbose("asyncPopup set to false, opening popup"),i.popup=this.openSizedPopup("about:blank",i),this.logoutPopupAsync(t,i,r,n))}catch(e){return Promise.reject(e)}}async acquireTokenPopupAsync(e,t){this.logger.verbose("acquireTokenPopupAsync called");const i=this.initializeServerTelemetryManager(Xi.sA.acquireTokenPopup),r=await Lr(this.initializeAuthorizationRequest.bind(this),di,this.logger,this.performanceClient,this.correlationId)(e,Xi.X8.Popup);ln(r.authority);try{const n=await Lr(this.initializeAuthorizationCodeRequest.bind(this),pi,this.logger,this.performanceClient,this.correlationId)(r),s=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:i,requestAuthority:r.authority,requestAzureCloudOptions:r.azureCloudOptions,requestExtraQueryParameters:r.extraQueryParameters,account:r.account}),o=Yn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme);let a;o&&(a=this.performanceClient.startMeasurement(Ut,e.correlationId));const l=await s.getAuthCodeUrl({...r,nativeBroker:o}),c=new Qn(s,this.browserStorage,n,this.logger,this.performanceClient),u=this.initiateAuthRequest(l,t);this.eventHandler.emitEvent(cn.B.POPUP_OPENED,Xi.X8.Popup,{popupWindow:u},null);const h=await this.monitorPopupForHash(u,t.popupWindowParent),d=Ir(Xn,Ti,this.logger,this.performanceClient,this.correlationId)(h,this.config.auth.OIDCOptions.serverResponseType,this.logger);if(dn.removeThrottle(this.browserStorage,this.config.auth.clientId,n),d.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),a&&a.end({success:!0,isNativeBroker:!0}),!this.nativeMessageHandler)throw(0,Ji.bD)(er.XC);const e=new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,d.accountId,this.nativeStorage,r.correlationId),{userRequestState:t}=$r.parseRequestState(this.browserCrypto,r.state);return await e.acquireToken({...r,state:t,prompt:void 0})}return await c.handleCodeResponse(d,r)}catch(e){throw t.popup?.close(),e instanceof l.lR&&(e.setCorrelationId(this.correlationId),i.cacheFailedRequest(e)),e}}async logoutPopupAsync(e,t,i,r){this.logger.verbose("logoutPopupAsync called"),this.eventHandler.emitEvent(cn.B.LOGOUT_START,Xi.X8.Popup,e);const n=this.initializeServerTelemetryManager(Xi.sA.logoutPopup);try{await this.clearCacheOnLogout(e.account);const s=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:n,requestAuthority:i,account:e.account||void 0});try{s.authority.endSessionEndpoint}catch{if(e.account?.homeAccountId&&e.postLogoutRedirectUri&&s.authority.protocolMode===o){if(this.browserStorage.removeAccount(e.account?.homeAccountId),this.eventHandler.emitEvent(cn.B.LOGOUT_SUCCESS,Xi.X8.Popup,e),r){const e={apiId:Xi.sA.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},t=lt.getAbsoluteUrl(r,rn());await this.navigationClient.navigateInternal(t,e)}return void t.popup?.close()}}const a=s.getLogoutUri(e);this.eventHandler.emitEvent(cn.B.LOGOUT_SUCCESS,Xi.X8.Popup,e);const l=this.openPopup(a,t);if(this.eventHandler.emitEvent(cn.B.POPUP_OPENED,Xi.X8.Popup,{popupWindow:l},null),await this.monitorPopupForHash(l,t.popupWindowParent).catch(()=>{}),r){const e={apiId:Xi.sA.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},t=lt.getAbsoluteUrl(r,rn());this.logger.verbose("Redirecting main window to url specified in the request"),this.logger.verbosePii(`Redirecting main window to: ${t}`),await this.navigationClient.navigateInternal(t,e)}else this.logger.verbose("No main window navigation requested")}catch(e){throw t.popup?.close(),e instanceof l.lR&&(e.setCorrelationId(this.correlationId),n.cacheFailedRequest(e)),this.browserStorage.setInteractionInProgress(!1),this.eventHandler.emitEvent(cn.B.LOGOUT_FAILURE,Xi.X8.Popup,null,e),this.eventHandler.emitEvent(cn.B.LOGOUT_END,Xi.X8.Popup),e}this.eventHandler.emitEvent(cn.B.LOGOUT_END,Xi.X8.Popup)}initiateAuthRequest(e,t){if(e)return this.logger.infoPii(`Navigate to: ${e}`),this.openPopup(e,t);throw this.logger.error("Navigate url is empty"),(0,Ji.bD)(er.B2)}monitorPopupForHash(e,t){return new Promise((t,i)=>{this.logger.verbose("PopupHandler.monitorPopupForHash - polling started");const r=setInterval(()=>{if(e.closed)return this.logger.error("PopupHandler.monitorPopupForHash - window closed"),clearInterval(r),void i((0,Ji.bD)(er.fN));let s="";try{s=e.location.href}catch(e){}if(!s||"about:blank"===s)return;clearInterval(r);let o="";const a=this.config.auth.OIDCOptions.serverResponseType;e&&(o=a===n.zL.QUERY?e.location.search:e.location.hash),this.logger.verbose("PopupHandler.monitorPopupForHash - popup window is on same origin as caller"),t(o)},this.config.system.pollIntervalMilliseconds)}).finally(()=>{this.cleanPopup(e,t)})}openPopup(e,t){try{let i;if(t.popup?(i=t.popup,this.logger.verbosePii(`Navigating popup window to: ${e}`),i.location.assign(e)):void 0===t.popup&&(this.logger.verbosePii(`Opening popup window to: ${e}`),i=this.openSizedPopup(e,t)),!i)throw(0,Ji.bD)(er.MP);return i.focus&&i.focus(),this.currentWindow=i,t.popupWindowParent.addEventListener("beforeunload",this.unloadWindow),i}catch(e){throw this.logger.error("error opening popup "+e.message),this.browserStorage.setInteractionInProgress(!1),(0,Ji.bD)(er.hs)}}openSizedPopup(e,{popupName:t,popupWindowAttributes:i,popupWindowParent:r}){const n=r.screenLeft?r.screenLeft:r.screenX,s=r.screenTop?r.screenTop:r.screenY,o=r.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,a=r.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;let l=i.popupSize?.width,c=i.popupSize?.height,u=i.popupPosition?.top,h=i.popupPosition?.left;return(!l||l<0||l>o)&&(this.logger.verbose("Default popup window width used. Window width not configured or invalid."),l=Xi.Q1.POPUP_WIDTH),(!c||c<0||c>a)&&(this.logger.verbose("Default popup window height used. Window height not configured or invalid."),c=Xi.Q1.POPUP_HEIGHT),(!u||u<0||u>a)&&(this.logger.verbose("Default popup window top position used. Window top not configured or invalid."),u=Math.max(0,a/2-Xi.Q1.POPUP_HEIGHT/2+s)),(!h||h<0||h>o)&&(this.logger.verbose("Default popup window left position used. Window left not configured or invalid."),h=Math.max(0,o/2-Xi.Q1.POPUP_WIDTH/2+n)),r.open(e,t,`width=${l}, height=${c}, top=${u}, left=${h}, scrollbars=yes`)}unloadWindow(e){this.browserStorage.cleanRequestByInteractionType(Xi.X8.Popup),this.currentWindow&&this.currentWindow.close(),e.preventDefault()}cleanPopup(e,t){e.close(),t.removeEventListener("beforeunload",this.unloadWindow),this.browserStorage.setInteractionInProgress(!1)}generatePopupName(e,t){return`${Xi.Q1.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${e.join("-")}.${t}.${this.correlationId}`}generateLogoutPopupName(e){const t=e.account&&e.account.homeAccountId;return`${Xi.Q1.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${t}.${this.correlationId}`}}class Jn{constructor(e,t,i,r,n){this.authModule=e,this.browserStorage=t,this.authCodeRequest=i,this.logger=r,this.performanceClient=n}async initiateAuthRequest(e,t){if(this.logger.verbose("RedirectHandler.initiateAuthRequest called"),e){t.redirectStartPage&&(this.logger.verbose("RedirectHandler.initiateAuthRequest: redirectStartPage set, caching start page"),this.browserStorage.setTemporaryCache(Xi._p.ORIGIN_URI,t.redirectStartPage,!0)),this.browserStorage.setTemporaryCache(Xi._p.CORRELATION_ID,this.authCodeRequest.correlationId,!0),this.browserStorage.cacheCodeRequest(this.authCodeRequest),this.logger.infoPii(`RedirectHandler.initiateAuthRequest: Navigate to: ${e}`);const i={apiId:Xi.sA.acquireTokenRedirect,timeout:t.redirectTimeout,noHistory:!1};return"function"==typeof t.onRedirectNavigate?(this.logger.verbose("RedirectHandler.initiateAuthRequest: Invoking onRedirectNavigate callback"),!1!==t.onRedirectNavigate(e)?(this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate did not return false, navigating"),void await t.navigationClient.navigateExternal(e,i)):void this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate returned false, stopping navigation")):(this.logger.verbose("RedirectHandler.initiateAuthRequest: Navigating window to navigate url"),void await t.navigationClient.navigateExternal(e,i))}throw this.logger.info("RedirectHandler.initiateAuthRequest: Navigate url is empty"),(0,Ji.bD)(er.B2)}async handleCodeResponse(e,t){this.logger.verbose("RedirectHandler.handleCodeResponse called"),this.browserStorage.setInteractionInProgress(!1);const i=this.browserStorage.generateStateKey(t),r=this.browserStorage.getTemporaryCache(i);if(!r)throw te(y,"Cached State");let n;try{n=this.authModule.handleFragmentResponse(e,r)}catch(e){throw e instanceof hn&&e.subError===er.fN?(0,Ji.bD)(er.fN):e}const s=this.browserStorage.generateNonceKey(r),o=this.browserStorage.getTemporaryCache(s);if(this.authCodeRequest.code=n.code,n.cloud_instance_host_name&&await Lr(this.authModule.updateAuthority.bind(this.authModule),vi,this.logger,this.performanceClient,this.authCodeRequest.correlationId)(n.cloud_instance_host_name,this.authCodeRequest.correlationId),n.nonce=o||void 0,n.state=r,n.client_info)this.authCodeRequest.clientInfo=n.client_info;else{const e=this.checkCcsCredentials();e&&(this.authCodeRequest.ccsCredential=e)}const a=await this.authModule.acquireToken(this.authCodeRequest,n);return this.browserStorage.cleanRequestByState(t),a}checkCcsCredentials(){const e=this.browserStorage.getTemporaryCache(Xi._p.CCS_CREDENTIAL,!0);if(e)try{return JSON.parse(e)}catch(t){this.authModule.logger.error("Cache credential could not be parsed"),this.authModule.logger.errorPii(`Cache credential could not be parsed: ${e}`)}return null}}class es extends kn{constructor(e,t,i,r,n,s,o,a,l,c){super(e,t,i,r,n,s,o,l,c),this.nativeStorage=a}async acquireToken(e){const t=await Lr(this.initializeAuthorizationRequest.bind(this),di,this.logger,this.performanceClient,this.correlationId)(e,Xi.X8.Redirect);this.browserStorage.updateCacheEntries(t.state,t.nonce,t.authority,t.loginHint||"",t.account||null);const i=this.initializeServerTelemetryManager(Xi.sA.acquireTokenRedirect),r=e=>{e.persisted&&(this.logger.verbose("Page was restored from back/forward cache. Clearing temporary cache."),this.browserStorage.cleanRequestByState(t.state),this.eventHandler.emitEvent(cn.B.RESTORE_FROM_BFCACHE,Xi.X8.Redirect))};try{const n=await Lr(this.initializeAuthorizationCodeRequest.bind(this),pi,this.logger,this.performanceClient,this.correlationId)(t),s=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:i,requestAuthority:t.authority,requestAzureCloudOptions:t.azureCloudOptions,requestExtraQueryParameters:t.extraQueryParameters,account:t.account}),o=new Jn(s,this.browserStorage,n,this.logger,this.performanceClient),a=await s.getAuthCodeUrl({...t,nativeBroker:Yn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme)}),l=this.getRedirectStartPage(e.redirectStartPage);return this.logger.verbosePii(`Redirect start page: ${l}`),window.addEventListener("pageshow",r),await o.initiateAuthRequest(a,{navigationClient:this.navigationClient,redirectTimeout:this.config.system.redirectNavigationTimeout,redirectStartPage:l,onRedirectNavigate:e.onRedirectNavigate||this.config.auth.onRedirectNavigate})}catch(e){throw e instanceof l.lR&&(e.setCorrelationId(this.correlationId),i.cacheFailedRequest(e)),window.removeEventListener("pageshow",r),this.browserStorage.cleanRequestByState(t.state),e}}async handleRedirectPromise(e="",t){const i=this.initializeServerTelemetryManager(Xi.sA.handleRedirectPromise);try{if(!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const[r,s]=this.getRedirectResponse(e||"");if(!r)return this.logger.info("handleRedirectPromise did not detect a response as a result of a redirect. Cleaning temporary cache."),this.browserStorage.cleanRequestByInteractionType(Xi.X8.Redirect),"back_forward"!==function(){if("undefined"==typeof window||void 0===window.performance||"function"!=typeof window.performance.getEntriesByType)return;const e=window.performance.getEntriesByType("navigation"),t=e.length?e[0]:void 0;return t?.type}()?t.event.errorCode="no_server_response":this.logger.verbose("Back navigation event detected. Muting no_server_response error"),null;const o=this.browserStorage.getTemporaryCache(Xi._p.ORIGIN_URI,!0)||n.YM.EMPTY_STRING;if(lt.removeHashFromUrl(o)===lt.removeHashFromUrl(window.location.href)&&this.config.auth.navigateToLoginRequestUrl)return this.logger.verbose("Current page is loginRequestUrl, handling response"),o.indexOf("#")>-1&&function(e){const t=e.split("#");t.shift(),window.location.hash=t.length>0?t.join("#"):""}(o),await this.handleResponse(r,i);if(!this.config.auth.navigateToLoginRequestUrl)return this.logger.verbose("NavigateToLoginRequestUrl set to false, handling response"),await this.handleResponse(r,i);if(!tn()||this.config.system.allowRedirectInIframe){this.browserStorage.setTemporaryCache(Xi._p.URL_HASH,s,!0);const e={apiId:Xi.sA.handleRedirectPromise,timeout:this.config.system.redirectNavigationTimeout,noHistory:!0};let t=!0;if(o&&"null"!==o)this.logger.verbose(`Navigating to loginRequestUrl: ${o}`),t=await this.navigationClient.navigateInternal(o,e);else{const i=function(){const e=new lt(window.location.href).getUrlComponents();return`${e.Protocol}//${e.HostNameAndPort}/`}();this.browserStorage.setTemporaryCache(Xi._p.ORIGIN_URI,i,!0),this.logger.warning("Unable to get valid login request url from cache, redirecting to home page"),t=await this.navigationClient.navigateInternal(i,e)}if(!t)return await this.handleResponse(r,i)}return null}catch(e){throw e instanceof l.lR&&(e.setCorrelationId(this.correlationId),i.cacheFailedRequest(e)),this.browserStorage.cleanRequestByInteractionType(Xi.X8.Redirect),e}}getRedirectResponse(e){this.logger.verbose("getRedirectResponseHash called");let t=e;t||(t=this.config.auth.OIDCOptions.serverResponseType===n.zL.QUERY?window.location.search:window.location.hash);let i=at(t);if(i){try{!function(e,t,i){if(!e.state)throw(0,Ji.bD)(er.c$);const r=Jr(t,e.state);if(!r)throw(0,Ji.bD)(er.fA);if(r.interactionType!==i)throw(0,Ji.bD)(er.oe)}(i,this.browserCrypto,Xi.X8.Redirect)}catch(e){return e instanceof l.lR&&this.logger.error(`Interaction type validation failed due to ${e.errorCode}: ${e.errorMessage}`),[null,""]}return(r=window).location.hash="","function"==typeof r.history.replaceState&&r.history.replaceState(null,"",`${r.location.origin}${r.location.pathname}${r.location.search}`),this.logger.verbose("Hash contains known properties, returning response hash"),[i,t]}var r;const s=this.browserStorage.getTemporaryCache(Xi._p.URL_HASH,!0);return this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Xi._p.URL_HASH)),s&&(i=at(s),i)?(this.logger.verbose("Hash does not contain known properties, returning cached hash"),[i,s]):[null,""]}async handleResponse(e,t){const i=e.state;if(!i)throw(0,Ji.bD)(er.c$);const r=this.browserStorage.getCachedRequest(i);if(this.logger.verbose("handleResponse called, retrieved cached request"),e.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw(0,Ji.bD)(er.XC);const t=new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,e.accountId,this.nativeStorage,r.correlationId),{userRequestState:n}=$r.parseRequestState(this.browserCrypto,i);return t.acquireToken({...r,state:n,prompt:void 0}).finally(()=>{this.browserStorage.cleanRequestByState(i)})}const n=this.browserStorage.getCachedAuthority(i);if(!n)throw(0,Ji.bD)(er.Ne);const s=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:t,requestAuthority:n});return dn.removeThrottle(this.browserStorage,this.config.auth.clientId,r),new Jn(s,this.browserStorage,r,this.logger,this.performanceClient).handleCodeResponse(e,i)}async logout(e){this.logger.verbose("logoutRedirect called");const t=this.initializeLogoutRequest(e),i=this.initializeServerTelemetryManager(Xi.sA.logout);try{this.eventHandler.emitEvent(cn.B.LOGOUT_START,Xi.X8.Redirect,e),await this.clearCacheOnLogout(t.account);const r={apiId:Xi.sA.logout,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},n=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:i,requestAuthority:e&&e.authority,requestExtraQueryParameters:e?.extraQueryParameters,account:e&&e.account||void 0});if(n.authority.protocolMode===o)try{n.authority.endSessionEndpoint}catch{if(t.account?.homeAccountId)return this.browserStorage.removeAccount(t.account?.homeAccountId),void this.eventHandler.emitEvent(cn.B.LOGOUT_SUCCESS,Xi.X8.Redirect,t)}const s=n.getLogoutUri(t);if(this.eventHandler.emitEvent(cn.B.LOGOUT_SUCCESS,Xi.X8.Redirect,t),!e||"function"!=typeof e.onRedirectNavigate)return this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),void await this.navigationClient.navigateExternal(s,r);if(!1!==e.onRedirectNavigate(s))return this.logger.verbose("Logout onRedirectNavigate did not return false, navigating"),this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),void await this.navigationClient.navigateExternal(s,r);this.browserStorage.setInteractionInProgress(!1),this.logger.verbose("Logout onRedirectNavigate returned false, stopping navigation")}catch(e){throw e instanceof l.lR&&(e.setCorrelationId(this.correlationId),i.cacheFailedRequest(e)),this.eventHandler.emitEvent(cn.B.LOGOUT_FAILURE,Xi.X8.Redirect,null,e),this.eventHandler.emitEvent(cn.B.LOGOUT_END,Xi.X8.Redirect),e}this.eventHandler.emitEvent(cn.B.LOGOUT_END,Xi.X8.Redirect)}getRedirectStartPage(e){const t=e||window.location.href;return lt.getAbsoluteUrl(t,rn())}}async function ts(e,t,i,r,n){if(t.addQueueMeasurement(oi,r),!e)throw i.info("Navigate url is empty"),(0,Ji.bD)(er.B2);return n?Lr(rs,li,i,t,r)(e,n,t,r):Ir(ns,ci,i,t,r)(e)}async function is(e,t,i,r,s,o,a){return r.addQueueMeasurement(ai,o),new Promise((r,o)=>{t<1e4&&s.warning(`system.loadFrameTimeout or system.iframeHashTimeout set to lower (${t}ms) than the default (10000ms). This may result in timeouts.`);const l=window.setTimeout(()=>{window.clearInterval(c),o((0,Ji.bD)(er.Uf))},t),c=window.setInterval(()=>{let t="";const i=e.contentWindow;try{t=i?i.location.href:""}catch(e){}if(!t||"about:blank"===t)return;let s="";i&&(s=a===n.zL.QUERY?i.location.search:i.location.hash),window.clearTimeout(l),window.clearInterval(c),r(s)},i)}).finally(()=>{Ir(os,Hi,s,r,o)(e)})}function rs(e,t,i,r){return i.addQueueMeasurement(li,r),new Promise((i,r)=>{const n=ss();window.setTimeout(()=>{n?(n.src=e,i(n)):r("Unable to load iframe")},t)})}function ns(e){const t=ss();return t.src=e,t}function ss(){const e=document.createElement("iframe");return e.className="msalSilentIframe",e.style.visibility="hidden",e.style.position="absolute",e.style.width=e.style.height="0",e.style.border="0",e.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms"),document.body.appendChild(e),e}function os(e){document.body===e.parentNode&&document.body.removeChild(e)}class as extends kn{constructor(e,t,i,r,n,s,o,a,l,c,u){super(e,t,i,r,n,s,a,c,u),this.apiId=o,this.nativeStorage=l}async acquireToken(e){this.performanceClient.addQueueMeasurement(Vt,e.correlationId),e.loginHint||e.sid||e.account&&e.account.username||this.logger.warning("No user hint provided. The authorization server may need more information to complete this request.");const t={...e};t.prompt?t.prompt!==n._M.NONE&&t.prompt!==n._M.NO_SESSION&&(this.logger.warning(`SilentIframeClient. Replacing invalid prompt ${t.prompt} with ${n._M.NONE}`),t.prompt=n._M.NONE):t.prompt=n._M.NONE;const i=await Lr(this.initializeAuthorizationRequest.bind(this),di,this.logger,this.performanceClient,e.correlationId)(t,Xi.X8.Silent);ln(i.authority);const r=this.initializeServerTelemetryManager(this.apiId);let s;try{return s=await Lr(this.createAuthCodeClient.bind(this),ui,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:r,requestAuthority:i.authority,requestAzureCloudOptions:i.azureCloudOptions,requestExtraQueryParameters:i.extraQueryParameters,account:i.account}),await Lr(this.silentTokenHelper.bind(this),si,this.logger,this.performanceClient,e.correlationId)(s,i)}catch(i){if(i instanceof l.lR&&(i.setCorrelationId(this.correlationId),r.cacheFailedRequest(i)),!(s&&i instanceof l.lR&&i.errorCode===Xi.Q1.INVALID_GRANT_ERROR))throw i;this.performanceClient.addFields({retryError:i.errorCode},this.correlationId);const n=await Lr(this.initializeAuthorizationRequest.bind(this),di,this.logger,this.performanceClient,e.correlationId)(t,Xi.X8.Silent);return await Lr(this.silentTokenHelper.bind(this),si,this.logger,this.performanceClient,this.correlationId)(s,n)}}logout(){return Promise.reject((0,Ji.bD)(er.v7))}async silentTokenHelper(e,t){const i=t.correlationId;this.performanceClient.addQueueMeasurement(si,i);const r=await Lr(this.initializeAuthorizationCodeRequest.bind(this),pi,this.logger,this.performanceClient,i)(t),s=await Lr(e.getAuthCodeUrl.bind(e),gi,this.logger,this.performanceClient,i)({...t,nativeBroker:Yn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,t.authenticationScheme)}),o=new Qn(e,this.browserStorage,r,this.logger,this.performanceClient),a=await Lr(ts,oi,this.logger,this.performanceClient,i)(s,this.performanceClient,this.logger,i,this.config.system.navigateFrameWait),l=this.config.auth.OIDCOptions.serverResponseType,c=await Lr(is,ai,this.logger,this.performanceClient,i)(a,this.config.system.iframeHashTimeout,this.config.system.pollIntervalMilliseconds,this.performanceClient,this.logger,i,l),u=Ir(Xn,Ti,this.logger,this.performanceClient,this.correlationId)(c,l,this.logger);if(u.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw(0,Ji.bD)(er.XC);const e=new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.apiId,this.performanceClient,this.nativeMessageHandler,u.accountId,this.browserStorage,i),{userRequestState:r}=$r.parseRequestState(this.browserCrypto,t.state);return Lr(e.acquireToken.bind(e),Wt,this.logger,this.performanceClient,i)({...t,state:r,prompt:t.prompt||n._M.NONE})}return Lr(o.handleCodeResponse.bind(o),mi,this.logger,this.performanceClient,i)(u,t)}}class ls extends kn{async acquireToken(e){this.performanceClient.addQueueMeasurement(Ht,e.correlationId);const t=await Lr(On,ii,this.logger,this.performanceClient,e.correlationId)(e,this.config,this.performanceClient,this.logger),i={...e,...t};e.redirectUri&&(i.redirectUri=this.getRedirectUri(e.redirectUri));const r=this.initializeServerTelemetryManager(Xi.sA.acquireTokenSilent_silentFlow),n=await this.createRefreshTokenClient({serverTelemetryManager:r,authorityUrl:i.authority,azureCloudOptions:i.azureCloudOptions,account:i.account});return Lr(n.acquireTokenByRefreshToken.bind(n),Qt,this.logger,this.performanceClient,e.correlationId)(i).catch(e=>{throw e.setCorrelationId(this.correlationId),r.cacheFailedRequest(e),e})}logout(){return Promise.reject((0,Ji.bD)(er.v7))}async createRefreshTokenClient(e){const t=await Lr(this.getClientConfiguration.bind(this),hi,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:e.serverTelemetryManager,requestAuthority:e.authorityUrl,requestAzureCloudOptions:e.azureCloudOptions,requestExtraQueryParameters:e.extraQueryParameters,account:e.account});return new Wn(t,this.performanceClient)}}class cs{constructor(e,t,i,r){this.isBrowserEnvironment="undefined"!=typeof window,this.config=e,this.storage=t,this.logger=i,this.cryptoObj=r}loadExternalTokens(e,t,i){if(!this.isBrowserEnvironment)throw(0,Ji.bD)(er.tI);const r=t.id_token?se(t.id_token,fr):void 0,n={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},s=e.authority?new Or(Or.generateAuthority(e.authority,e.azureCloudOptions),this.config.system.networkClient,this.storage,n,this.logger,e.correlationId||Ar()):void 0,o=this.loadAccount(e,i.clientInfo||t.client_info||"",r,s),a=this.loadIdToken(t,o.homeAccountId,o.environment,o.realm),l=this.loadAccessToken(e,t,o.homeAccountId,o.environment,o.realm,i),c=this.loadRefreshToken(t,o.homeAccountId,o.environment);return this.generateAuthenticationResult(e,{account:o,idToken:a,accessToken:l,refreshToken:c},r,s)}loadAccount(e,t,i,r){if(this.logger.verbose("TokenCache - loading account"),e.account){const t=st.createFromAccountInfo(e.account);return this.storage.setAccount(t),t}if(!r||!t&&!i)throw this.logger.error("TokenCache - if an account is not provided on the request, authority and either clientInfo or idToken must be provided instead."),(0,Ji.bD)(er.s9);const n=st.generateHomeAccountId(t,r.authorityType,this.logger,this.cryptoObj,i),s=i?.tid,o=Rn(this.storage,r,n,fr,i,t,r.hostnameAndPort,s,void 0,void 0,this.logger);return this.storage.setAccount(o),o}loadIdToken(e,t,i,r){if(!e.id_token)return this.logger.verbose("TokenCache - no id token found in response"),null;this.logger.verbose("TokenCache - loading id token");const n=ue(t,i,e.id_token,this.config.auth.clientId,r);return this.storage.setIdTokenCredential(n),n}loadAccessToken(e,t,i,r,n,s){if(!t.access_token)return this.logger.verbose("TokenCache - no access token found in response"),null;if(!t.expires_in)return this.logger.error("TokenCache - no expiration set on the access token. Cannot add it to the cache."),null;if(!(t.scope||e.scopes&&e.scopes.length))return this.logger.error("TokenCache - scopes not specified in the request or response. Cannot add token to the cache."),null;this.logger.verbose("TokenCache - loading access token");const o=t.scope?Ze.fromString(t.scope):new Ze(e.scopes),a=s.expiresOn||t.expires_in+(new Date).getTime()/1e3,l=s.extendedExpiresOn||(t.ext_expires_in||t.expires_in)+(new Date).getTime()/1e3,c=he(i,r,t.access_token,this.config.auth.clientId,n,o.printScopes(),a,l,fr);return this.storage.setAccessTokenCredential(c),c}loadRefreshToken(e,t,i){if(!e.refresh_token)return this.logger.verbose("TokenCache - no refresh token found in response"),null;this.logger.verbose("TokenCache - loading refresh token");const r=de(t,i,e.refresh_token,this.config.auth.clientId,e.foci,void 0,e.refresh_token_expires_in);return this.storage.setRefreshTokenCredential(r),r}generateAuthenticationResult(e,t,i,r){let n,s="",o=[],a=null;t?.accessToken&&(s=t.accessToken.secret,o=Ze.fromString(t.accessToken.target).asArray(),a=new Date(1e3*Number(t.accessToken.expiresOn)),n=new Date(1e3*Number(t.accessToken.extendedExpiresOn)));const l=t.account;return{authority:r?r.canonicalAuthority:"",uniqueId:t.account.localAccountId,tenantId:t.account.realm,scopes:o,account:l.getAccountInfo(),idToken:t.idToken?.secret||"",idTokenClaims:i||{},accessToken:s,fromCache:!0,expiresOn:a,correlationId:e.correlationId||"",requestId:"",extExpiresOn:n,familyId:t.refreshToken?.familyId||"",tokenType:t?.accessToken?.tokenType||"",state:e.state||"",cloudGraphHostName:l.cloudGraphHostName||"",msGraphHost:l.msGraphHost||"",fromNativeBroker:!1}}}class us extends Pn{constructor(e){super(e),this.includeRedirectUri=!1}}class hs extends kn{constructor(e,t,i,r,n,s,o,a,l,c){super(e,t,i,r,n,s,a,l,c),this.apiId=o}async acquireToken(e){if(!e.code)throw(0,Ji.bD)(er.R3);const t=await Lr(this.initializeAuthorizationRequest.bind(this),di,this.logger,this.performanceClient,e.correlationId)(e,Xi.X8.Silent),i=this.initializeServerTelemetryManager(this.apiId);try{const r={...t,code:e.code},n=await Lr(this.getClientConfiguration.bind(this),hi,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:i,requestAuthority:t.authority,requestAzureCloudOptions:t.azureCloudOptions,requestExtraQueryParameters:t.extraQueryParameters,account:t.account}),s=new us(n);this.logger.verbose("Auth code client created");const o=new Qn(s,this.browserStorage,r,this.logger,this.performanceClient);return await Lr(o.handleCodeResponseFromServer.bind(o),fi,this.logger,this.performanceClient,e.correlationId)({code:e.code,msgraph_host:e.msGraphHost,cloud_graph_host_name:e.cloudGraphHostName,cloud_instance_host_name:e.cloudInstanceHostName},t,!1)}catch(e){throw e instanceof l.lR&&(e.setCorrelationId(this.correlationId),i.cacheFailedRequest(e)),e}}logout(){return Promise.reject((0,Ji.bD)(er.v7))}}function ds(e){const t=e?.idTokenClaims;return t?.tfp||t?.acr?"B2C":t?.tid?"9188040d-6c67-4c5b-b112-36a304b66dad"===t?.tid?"MSA":"AAD":void 0}function ps(e,t){try{on(e)}catch(e){throw t.end({success:!1},e),e}}class gs{constructor(e){this.operatingContext=e,this.isBrowserEnvironment=this.operatingContext.isBrowserEnvironment(),this.config=e.getConfig(),this.initialized=!1,this.logger=this.operatingContext.getLogger(),this.networkClient=this.config.system.networkClient,this.navigationClient=this.config.system.navigationClient,this.redirectResponse=new Map,this.hybridAuthCodeResponses=new Map,this.performanceClient=this.config.telemetry.client,this.browserCrypto=this.isBrowserEnvironment?new xr(this.logger,this.performanceClient):ie,this.eventHandler=new un(this.logger),this.browserStorage=this.isBrowserEnvironment?new en(this.config.auth.clientId,this.config.cache,this.browserCrypto,this.logger,function(e){const t=e.cloudDiscoveryMetadata;let i;if(t)try{i=JSON.parse(t)}catch(e){throw Qe(Ge)}return{canonicalAuthority:e.authority?Fr(e.authority):void 0,knownAuthorities:e.knownAuthorities,cloudDiscoveryMetadata:i}}(this.config.auth),this.performanceClient):((e,t)=>{const i={cacheLocation:Xi.Al.MemoryStorage,temporaryCacheLocation:Xi.Al.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};return new en(e,i,ie,t)})(this.config.auth.clientId,this.logger);const t={cacheLocation:Xi.Al.MemoryStorage,temporaryCacheLocation:Xi.Al.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};this.nativeInternalStorage=new en(this.config.auth.clientId,t,this.browserCrypto,this.logger,void 0,this.performanceClient),this.tokenCache=new cs(this.config,this.browserStorage,this.logger,this.browserCrypto),this.activeSilentTokenRequests=new Map,this.trackPageVisibility=this.trackPageVisibility.bind(this),this.trackPageVisibilityWithMeasurement=this.trackPageVisibilityWithMeasurement.bind(this),this.listeningToStorageEvents=!1,this.handleAccountCacheChange=this.handleAccountCacheChange.bind(this)}static async createController(e,t){const i=new gs(e);return await i.initialize(t),i}trackPageVisibility(e){e&&(this.logger.info("Perf: Visibility change detected"),this.performanceClient.incrementFields({visibilityChangeCount:1},e))}async initialize(e){if(this.logger.trace("initialize called"),this.initialized)return void this.logger.info("initialize has already been called, exiting early.");if(!this.isBrowserEnvironment)return this.logger.info("in non-browser environment, exiting early."),this.initialized=!0,void this.eventHandler.emitEvent(cn.B.INITIALIZE_END);const t=e?.correlationId||this.getRequestCorrelationId(),i=this.config.system.allowNativeBroker,r=this.performanceClient.startMeasurement(ni,t);if(this.eventHandler.emitEvent(cn.B.INITIALIZE_START),i)try{this.nativeExtensionProvider=await Yn.createProvider(this.logger,this.config.system.nativeBrokerHandshakeTimeout,this.performanceClient)}catch(e){this.logger.verbose(e)}this.config.cache.claimsBasedCachingEnabled||(this.logger.verbose("Claims-based caching is disabled. Clearing the previous cache with claims"),await Lr(this.browserStorage.clearTokensAndKeysWithClaims.bind(this.browserStorage),Bi,this.logger,this.performanceClient,t)(this.performanceClient,t)),this.initialized=!0,this.eventHandler.emitEvent(cn.B.INITIALIZE_END),r.end({allowNativeBroker:i,success:!0})}async handleRedirectPromise(e){if(this.logger.verbose("handleRedirectPromise called"),sn(this.initialized),this.isBrowserEnvironment){const t=e||"";let i=this.redirectResponse.get(t);return void 0===i?(i=this.handleRedirectPromiseInternal(e),this.redirectResponse.set(t,i),this.logger.verbose("handleRedirectPromise has been called for the first time, storing the promise")):this.logger.verbose("handleRedirectPromise has been called previously, returning the result from the first call"),i}return this.logger.verbose("handleRedirectPromise returns null, not browser environment"),null}async handleRedirectPromiseInternal(e){const t=this.getAllAccounts(),i=this.browserStorage.getCachedNativeRequest(),r=i&&Yn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider)&&this.nativeExtensionProvider&&!e,n=r?i?.correlationId:this.browserStorage.getTemporaryCache(Xi._p.CORRELATION_ID,!0)||"",s=this.performanceClient.startMeasurement(Ot,n);let o;if(this.eventHandler.emitEvent(cn.B.HANDLE_REDIRECT_START,Xi.X8.Redirect),r&&this.nativeExtensionProvider){this.logger.trace("handleRedirectPromise - acquiring token from native platform");const e=new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.handleRedirectPromise,this.performanceClient,this.nativeExtensionProvider,i.accountId,this.nativeInternalStorage,i.correlationId);o=Lr(e.handleRedirectPromise.bind(e),Gi,this.logger,this.performanceClient,s.event.correlationId)(this.performanceClient,s.event.correlationId)}else{this.logger.trace("handleRedirectPromise - acquiring token from web flow");const t=this.createRedirectClient(n);o=Lr(t.handleRedirectPromise.bind(t),ki,this.logger,this.performanceClient,s.event.correlationId)(e,s)}return o.then(e=>(e?(t.length<this.getAllAccounts().length?(this.eventHandler.emitEvent(cn.B.LOGIN_SUCCESS,Xi.X8.Redirect,e),this.logger.verbose("handleRedirectResponse returned result, login success")):(this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_SUCCESS,Xi.X8.Redirect,e),this.logger.verbose("handleRedirectResponse returned result, acquire token success")),s.end({success:!0,accountType:ds(e.account)})):s.event.errorCode?s.end({success:!1}):s.discard(),this.eventHandler.emitEvent(cn.B.HANDLE_REDIRECT_END,Xi.X8.Redirect),e)).catch(e=>{const i=e;throw t.length>0?this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_FAILURE,Xi.X8.Redirect,null,i):this.eventHandler.emitEvent(cn.B.LOGIN_FAILURE,Xi.X8.Redirect,null,i),this.eventHandler.emitEvent(cn.B.HANDLE_REDIRECT_END,Xi.X8.Redirect),s.end({success:!1},i),e})}async acquireTokenRedirect(e){const t=this.getRequestCorrelationId(e);this.logger.verbose("acquireTokenRedirect called",t);const i=this.performanceClient.startMeasurement("acquireTokenPreRedirect",t);i.add({accountType:ds(e.account),scenarioId:e.scenarioId});const r=e.onRedirectNavigate;if(r)e.onRedirectNavigate=e=>{const t="function"==typeof r?r(e):void 0;return!1!==t?i.end({success:!0}):i.discard(),t};else{const e=this.config.auth.onRedirectNavigate;this.config.auth.onRedirectNavigate=t=>{const r="function"==typeof e?e(t):void 0;return!1!==r?i.end({success:!0}):i.discard(),r}}const n=this.getAllAccounts().length>0;try{let r;return an(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),n?this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_START,Xi.X8.Redirect,e):this.eventHandler.emitEvent(cn.B.LOGIN_START,Xi.X8.Redirect,e),r=this.nativeExtensionProvider&&this.canUseNative(e)?new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.acquireTokenRedirect,this.performanceClient,this.nativeExtensionProvider,this.getNativeAccountId(e),this.nativeInternalStorage,t).acquireTokenRedirect(e,i).catch(i=>{if(i instanceof Bn&&zn(i))return this.nativeExtensionProvider=void 0,this.createRedirectClient(t).acquireToken(e);if(i instanceof Wr)return this.logger.verbose("acquireTokenRedirect - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createRedirectClient(t).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),i}):this.createRedirectClient(t).acquireToken(e),await r}catch(e){throw i.end({success:!1},e),n?this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_FAILURE,Xi.X8.Redirect,null,e):this.eventHandler.emitEvent(cn.B.LOGIN_FAILURE,Xi.X8.Redirect,null,e),e}}acquireTokenPopup(e){const t=this.getRequestCorrelationId(e),i=this.performanceClient.startMeasurement(Nt,t);i.add({scenarioId:e.scenarioId,accountType:ds(e.account)});try{this.logger.verbose("acquireTokenPopup called",t),ps(this.initialized,i),this.browserStorage.setInteractionInProgress(!0)}catch(e){return Promise.reject(e)}const r=this.getAllAccounts();let n;return r.length>0?this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_START,Xi.X8.Popup,e):this.eventHandler.emitEvent(cn.B.LOGIN_START,Xi.X8.Popup,e),n=this.canUseNative(e)?this.acquireTokenNative({...e,correlationId:t},Xi.sA.acquireTokenPopup).then(e=>(this.browserStorage.setInteractionInProgress(!1),i.end({success:!0,isNativeBroker:!0,requestId:e.requestId,accountType:ds(e.account)}),e)).catch(i=>{if(i instanceof Bn&&zn(i))return this.nativeExtensionProvider=void 0,this.createPopupClient(t).acquireToken(e);if(i instanceof Wr)return this.logger.verbose("acquireTokenPopup - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createPopupClient(t).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),i}):this.createPopupClient(t).acquireToken(e),n.then(e=>(r.length<this.getAllAccounts().length?this.eventHandler.emitEvent(cn.B.LOGIN_SUCCESS,Xi.X8.Popup,e):this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_SUCCESS,Xi.X8.Popup,e),i.end({success:!0,requestId:e.requestId,accessTokenSize:e.accessToken.length,idTokenSize:e.idToken.length,accountType:ds(e.account)}),e)).catch(e=>(r.length>0?this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_FAILURE,Xi.X8.Popup,null,e):this.eventHandler.emitEvent(cn.B.LOGIN_FAILURE,Xi.X8.Popup,null,e),i.end({success:!1},e),Promise.reject(e)))}trackPageVisibilityWithMeasurement(){const e=this.ssoSilentMeasurement||this.acquireTokenByCodeAsyncMeasurement;e&&(this.logger.info("Perf: Visibility change detected in ",e.event.name),e.increment({visibilityChangeCount:1}))}async ssoSilent(e){const t=this.getRequestCorrelationId(e),i={...e,prompt:e.prompt,correlationId:t};let r;return this.ssoSilentMeasurement=this.performanceClient.startMeasurement(Bt,t),this.ssoSilentMeasurement?.add({scenarioId:e.scenarioId,accountType:ds(e.account)}),ps(this.initialized,this.ssoSilentMeasurement),this.ssoSilentMeasurement?.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),this.logger.verbose("ssoSilent called",t),this.eventHandler.emitEvent(cn.B.SSO_SILENT_START,Xi.X8.Silent,i),r=this.canUseNative(i)?this.acquireTokenNative(i,Xi.sA.ssoSilent).catch(e=>{if(e instanceof Bn&&zn(e))return this.nativeExtensionProvider=void 0,this.createSilentIframeClient(i.correlationId).acquireToken(i);throw e}):this.createSilentIframeClient(i.correlationId).acquireToken(i),r.then(e=>(this.eventHandler.emitEvent(cn.B.SSO_SILENT_SUCCESS,Xi.X8.Silent,e),this.ssoSilentMeasurement?.end({success:!0,isNativeBroker:e.fromNativeBroker,requestId:e.requestId,accessTokenSize:e.accessToken.length,idTokenSize:e.idToken.length,accountType:ds(e.account)}),e)).catch(e=>{throw this.eventHandler.emitEvent(cn.B.SSO_SILENT_FAILURE,Xi.X8.Silent,null,e),this.ssoSilentMeasurement?.end({success:!1},e),e}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenByCode(e){const t=this.getRequestCorrelationId(e);this.logger.trace("acquireTokenByCode called",t);const i=this.performanceClient.startMeasurement(xt,t);ps(this.initialized,i),this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_BY_CODE_START,Xi.X8.Silent,e),i.add({scenarioId:e.scenarioId});try{if(e.code&&e.nativeAccountId)throw(0,Ji.bD)(er.$c);if(e.code){const r=e.code;let n=this.hybridAuthCodeResponses.get(r);return n?(this.logger.verbose("Existing acquireTokenByCode request found",t),i.discard()):(this.logger.verbose("Initiating new acquireTokenByCode request",t),n=this.acquireTokenByCodeAsync({...e,correlationId:t}).then(e=>(this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_BY_CODE_SUCCESS,Xi.X8.Silent,e),this.hybridAuthCodeResponses.delete(r),i.end({success:!0,isNativeBroker:e.fromNativeBroker,requestId:e.requestId,accessTokenSize:e.accessToken.length,idTokenSize:e.idToken.length,accountType:ds(e.account)}),e)).catch(e=>{throw this.hybridAuthCodeResponses.delete(r),this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_BY_CODE_FAILURE,Xi.X8.Silent,null,e),i.end({success:!1},e),e}),this.hybridAuthCodeResponses.set(r,n)),await n}if(e.nativeAccountId){if(this.canUseNative(e,e.nativeAccountId)){const r=await this.acquireTokenNative({...e,correlationId:t},Xi.sA.acquireTokenByCode,e.nativeAccountId).catch(e=>{throw e instanceof Bn&&zn(e)&&(this.nativeExtensionProvider=void 0),e});return i.end({accountType:ds(r.account),success:!0}),r}throw(0,Ji.bD)(er.gU)}throw(0,Ji.bD)(er.xp)}catch(e){throw this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_BY_CODE_FAILURE,Xi.X8.Silent,null,e),i.end({success:!1},e),e}}async acquireTokenByCodeAsync(e){this.logger.trace("acquireTokenByCodeAsync called",e.correlationId),this.acquireTokenByCodeAsyncMeasurement=this.performanceClient.startMeasurement(Fi,e.correlationId),this.acquireTokenByCodeAsyncMeasurement?.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement);const t=this.createSilentAuthCodeClient(e.correlationId);return await t.acquireToken(e).then(e=>(this.acquireTokenByCodeAsyncMeasurement?.end({success:!0,fromCache:e.fromCache,isNativeBroker:e.fromNativeBroker,requestId:e.requestId}),e)).catch(e=>{throw this.acquireTokenByCodeAsyncMeasurement?.end({success:!1},e),e}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenFromCache(e,t){switch(this.performanceClient.addQueueMeasurement(Zt,e.correlationId),t){case Xi.nN.Default:case Xi.nN.AccessToken:case Xi.nN.AccessTokenAndRefreshToken:const t=this.createSilentCacheClient(e.correlationId);return Lr(t.acquireToken.bind(t),Gt,this.logger,this.performanceClient,e.correlationId)(e);default:throw te(B)}}async acquireTokenByRefreshToken(e,t){switch(this.performanceClient.addQueueMeasurement(Dt,e.correlationId),t){case Xi.nN.Default:case Xi.nN.AccessTokenAndRefreshToken:case Xi.nN.RefreshToken:case Xi.nN.RefreshTokenAndNetwork:const t=this.createSilentRefreshClient(e.correlationId);return Lr(t.acquireToken.bind(t),Ht,this.logger,this.performanceClient,e.correlationId)(e);default:throw te(B)}}async acquireTokenBySilentIframe(e){this.performanceClient.addQueueMeasurement(ti,e.correlationId);const t=this.createSilentIframeClient(e.correlationId);return Lr(t.acquireToken.bind(t),Vt,this.logger,this.performanceClient,e.correlationId)(e)}async logout(e){const t=this.getRequestCorrelationId(e);return this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.",t),this.logoutRedirect({correlationId:t,...e})}async logoutRedirect(e){const t=this.getRequestCorrelationId(e);return an(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),this.createRedirectClient(t).logout(e)}logoutPopup(e){try{const t=this.getRequestCorrelationId(e);return on(this.initialized),this.browserStorage.setInteractionInProgress(!0),this.createPopupClient(t).logout(e)}catch(e){return Promise.reject(e)}}async clearCache(e){if(!this.isBrowserEnvironment)return void this.logger.info("in non-browser environment, returning early.");const t=this.getRequestCorrelationId(e);return this.createSilentCacheClient(t).logout(e)}getAllAccounts(e){return function(e,t,i,r){return e.verbose("getAllAccounts called"),i?t.getAllAccounts(r):[]}(this.logger,this.browserStorage,this.isBrowserEnvironment,e)}getAccount(e){return function(e,t,i){if(t.trace("getAccount called"),0===Object.keys(e).length)return t.warning("getAccount: No accountFilter provided"),null;const r=i.getAccountInfoFilteredBy(e);return r?(t.verbose("getAccount: Account matching provided filter found, returning"),r):(t.verbose("getAccount: No matching account found, returning null"),null)}(e,this.logger,this.browserStorage)}getAccountByUsername(e){return function(e,t,i){if(t.trace("getAccountByUsername called"),!e)return t.warning("getAccountByUsername: No username provided"),null;const r=i.getAccountInfoFilteredBy({username:e});return r?(t.verbose("getAccountByUsername: Account matching username found, returning"),t.verbosePii(`getAccountByUsername: Returning signed-in accounts matching username: ${e}`),r):(t.verbose("getAccountByUsername: No matching account found, returning null"),null)}(e,this.logger,this.browserStorage)}getAccountByHomeId(e){return function(e,t,i){if(t.trace("getAccountByHomeId called"),!e)return t.warning("getAccountByHomeId: No homeAccountId provided"),null;const r=i.getAccountInfoFilteredBy({homeAccountId:e});return r?(t.verbose("getAccountByHomeId: Account matching homeAccountId found, returning"),t.verbosePii(`getAccountByHomeId: Returning signed-in accounts matching homeAccountId: ${e}`),r):(t.verbose("getAccountByHomeId: No matching account found, returning null"),null)}(e,this.logger,this.browserStorage)}getAccountByLocalId(e){return function(e,t,i){if(t.trace("getAccountByLocalId called"),!e)return t.warning("getAccountByLocalId: No localAccountId provided"),null;const r=i.getAccountInfoFilteredBy({localAccountId:e});return r?(t.verbose("getAccountByLocalId: Account matching localAccountId found, returning"),t.verbosePii(`getAccountByLocalId: Returning signed-in accounts matching localAccountId: ${e}`),r):(t.verbose("getAccountByLocalId: No matching account found, returning null"),null)}(e,this.logger,this.browserStorage)}setActiveAccount(e){!function(e,t){t.setActiveAccount(e)}(e,this.browserStorage)}getActiveAccount(){return this.browserStorage.getActiveAccount()}async hydrateCache(e,t){this.logger.verbose("hydrateCache called");const i=st.createFromAccountInfo(e.account,e.cloudGraphHostName,e.msGraphHost);return this.browserStorage.setAccount(i),e.fromNativeBroker?(this.logger.verbose("Response was from native broker, storing in-memory"),this.nativeInternalStorage.hydrateCache(e,t)):this.browserStorage.hydrateCache(e,t)}async acquireTokenNative(e,t,i){if(this.logger.trace("acquireTokenNative called"),!this.nativeExtensionProvider)throw(0,Ji.bD)(er.XC);return new qn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,t,this.performanceClient,this.nativeExtensionProvider,i||this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId).acquireToken(e)}canUseNative(e,t){if(this.logger.trace("canUseNative called"),!Yn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme))return this.logger.trace("canUseNative: isNativeAvailable returned false, returning false"),!1;if(e.prompt)switch(e.prompt){case n._M.NONE:case n._M.CONSENT:case n._M.LOGIN:this.logger.trace("canUseNative: prompt is compatible with native flow");break;default:return this.logger.trace(`canUseNative: prompt = ${e.prompt} is not compatible with native flow, returning false`),!1}return!(!t&&!this.getNativeAccountId(e)&&(this.logger.trace("canUseNative: nativeAccountId is not available, returning false"),1))}getNativeAccountId(e){const t=e.account||this.getAccount({loginHint:e.loginHint,sid:e.sid})||this.getActiveAccount();return t&&t.nativeAccountId||""}createPopupClient(e){return new Zn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createRedirectClient(e){return new es(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentIframeClient(e){return new as(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.ssoSilent,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentCacheClient(e){return new Kn(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentRefreshClient(e){return new ls(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentAuthCodeClient(e){return new hs(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,Xi.sA.acquireTokenByCode,this.performanceClient,this.nativeExtensionProvider,e)}addEventCallback(e,t){return this.eventHandler.addEventCallback(e,t)}removeEventCallback(e){this.eventHandler.removeEventCallback(e)}addPerformanceCallback(e){return nn(),this.performanceClient.addPerformanceCallback(e)}removePerformanceCallback(e){return this.performanceClient.removePerformanceCallback(e)}enableAccountStorageEvents(){"undefined"!=typeof window&&(this.listeningToStorageEvents?this.logger.verbose("Account storage listener already registered."):(this.logger.verbose("Adding account storage listener."),this.listeningToStorageEvents=!0,window.addEventListener("storage",this.handleAccountCacheChange)))}disableAccountStorageEvents(){"undefined"!=typeof window&&(this.listeningToStorageEvents?(this.logger.verbose("Removing account storage listener."),window.removeEventListener("storage",this.handleAccountCacheChange),this.listeningToStorageEvents=!1):this.logger.verbose("No account storage listener registered."))}handleAccountCacheChange(e){try{e.key?.includes(n.Gd.ACTIVE_ACCOUNT_FILTERS)&&this.eventHandler.emitEvent(cn.B.ACTIVE_ACCOUNT_CHANGED);const t=e.newValue||e.oldValue;if(!t)return;const i=JSON.parse(t);if("object"!=typeof i||!st.isAccountEntity(i))return;const r=Ct.toObject(new st,i).getAccountInfo();!e.oldValue&&e.newValue?(this.logger.info("Account was added to cache in a different window"),this.eventHandler.emitEvent(cn.B.ACCOUNT_ADDED,void 0,r)):!e.newValue&&e.oldValue&&(this.logger.info("Account was removed from cache in a different window"),this.eventHandler.emitEvent(cn.B.ACCOUNT_REMOVED,void 0,r))}catch(e){return}}getTokenCache(){return this.tokenCache}getLogger(){return this.logger}setLogger(e){this.logger=e}initializeWrapperLibrary(e,t){this.browserStorage.setWrapperMetadata(e,t)}setNavigationClient(e){this.navigationClient=e}getConfiguration(){return this.config}getPerformanceClient(){return this.performanceClient}isBrowserEnv(){return this.isBrowserEnvironment}getRequestCorrelationId(e){return e?.correlationId?e.correlationId:this.isBrowserEnvironment?Ar():n.YM.EMPTY_STRING}async loginRedirect(e){const t=this.getRequestCorrelationId(e);return this.logger.verbose("loginRedirect called",t),this.acquireTokenRedirect({correlationId:t,...e||Xi.uq})}loginPopup(e){const t=this.getRequestCorrelationId(e);return this.logger.verbose("loginPopup called",t),this.acquireTokenPopup({correlationId:t,...e||Xi.uq})}async acquireTokenSilent(e){const t=this.getRequestCorrelationId(e),i=this.performanceClient.startMeasurement(It,t);i.add({cacheLookupPolicy:e.cacheLookupPolicy,scenarioId:e.scenarioId}),ps(this.initialized,i),this.logger.verbose("acquireTokenSilent called",t);const r=e.account||this.getActiveAccount();if(!r)throw(0,Ji.bD)(er.rR);i.add({accountType:ds(r)});const s={clientId:this.config.auth.clientId,authority:e.authority||n.YM.EMPTY_STRING,scopes:e.scopes,homeAccountIdentifier:r.homeAccountId,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid,shrOptions:e.shrOptions},o=JSON.stringify(s),a=this.activeSilentTokenRequests.get(o);if(void 0===a){this.logger.verbose("acquireTokenSilent called for the first time, storing active request",t);const n=Lr(this.acquireTokenSilentAsync.bind(this),Lt,this.logger,this.performanceClient,t)({...e,correlationId:t},r).then(t=>(this.activeSilentTokenRequests.delete(o),i.end({success:!0,fromCache:t.fromCache,isNativeBroker:t.fromNativeBroker,cacheLookupPolicy:e.cacheLookupPolicy,requestId:t.requestId,accessTokenSize:t.accessToken.length,idTokenSize:t.idToken.length}),t)).catch(e=>{throw this.activeSilentTokenRequests.delete(o),i.end({success:!1},e),e});return this.activeSilentTokenRequests.set(o,n),{...await n,state:e.state}}return this.logger.verbose("acquireTokenSilent has been called previously, returning the result from the first call",t),i.discard(),{...await a,state:e.state}}async acquireTokenSilentAsync(e,t){const i=()=>this.trackPageVisibility(e.correlationId);this.performanceClient.addQueueMeasurement(Lt,e.correlationId),this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_START,Xi.X8.Silent,e),e.correlationId&&this.performanceClient.incrementFields({visibilityChangeCount:0},e.correlationId),document.addEventListener("visibilitychange",i);const r=await Lr(Fn,ri,this.logger,this.performanceClient,e.correlationId)(e,t,this.config,this.performanceClient,this.logger),n=e.cacheLookupPolicy||Xi.nN.Default;return this.acquireTokenSilentNoIframe(r,n).catch(async e=>{const t=function(e,t){const i=!(e instanceof Wr&&e.subError!==Hr),r=e.errorCode===Xi.Q1.INVALID_GRANT_ERROR||e.errorCode===B,n=i&&r||e.errorCode===kr||e.errorCode===Vr,s=Xi.JE.includes(t);return n&&s}(e,n);if(t){if(this.activeIframeRequest){if(n!==Xi.nN.Skip){const[t,i]=this.activeIframeRequest;this.logger.verbose(`Iframe request is already in progress, awaiting resolution for request with correlationId: ${i}`,r.correlationId);const s=this.performanceClient.startMeasurement("awaitConcurrentIframe",r.correlationId);s.add({awaitIframeCorrelationId:i});const o=await t;if(s.end({success:o}),o)return this.logger.verbose(`Parallel iframe request with correlationId: ${i} succeeded. Retrying cache and/or RT redemption`,r.correlationId),this.acquireTokenSilentNoIframe(r,n);throw this.logger.info(`Iframe request with correlationId: ${i} failed. Interaction is required.`),e}return this.logger.warning("Another iframe request is currently in progress and CacheLookupPolicy is set to Skip. This may result in degraded performance and/or reliability for both calls. Please consider changing the CacheLookupPolicy to take advantage of request queuing and token cache.",r.correlationId),Lr(this.acquireTokenBySilentIframe.bind(this),ti,this.logger,this.performanceClient,r.correlationId)(r)}{let e;return this.activeIframeRequest=[new Promise(t=>{e=t}),r.correlationId],this.logger.verbose("Refresh token expired/invalid or CacheLookupPolicy is set to Skip, attempting acquire token by iframe.",r.correlationId),Lr(this.acquireTokenBySilentIframe.bind(this),ti,this.logger,this.performanceClient,r.correlationId)(r).then(t=>(e(!0),t)).catch(t=>{throw e(!1),t}).finally(()=>{this.activeIframeRequest=void 0})}}throw e}).then(t=>(this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_SUCCESS,Xi.X8.Silent,t),e.correlationId&&this.performanceClient.addFields({fromCache:t.fromCache,isNativeBroker:t.fromNativeBroker,requestId:t.requestId},e.correlationId),t)).catch(e=>{throw this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_FAILURE,Xi.X8.Silent,null,e),e}).finally(()=>{document.removeEventListener("visibilitychange",i)})}async acquireTokenSilentNoIframe(e,t){return Yn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme)&&e.account.nativeAccountId?(this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform"),this.acquireTokenNative(e,Xi.sA.acquireTokenSilent_silentFlow).catch(async e=>{if(e instanceof Bn&&zn(e))throw this.logger.verbose("acquireTokenSilent - native platform unavailable, falling back to web flow"),this.nativeExtensionProvider=void 0,te(B);throw e})):(this.logger.verbose("acquireTokenSilent - attempting to acquire token from web flow"),Lr(this.acquireTokenFromCache.bind(this),Zt,this.logger,this.performanceClient,e.correlationId)(e,t).catch(i=>{if(t===Xi.nN.AccessToken)throw i;return this.eventHandler.emitEvent(cn.B.ACQUIRE_TOKEN_NETWORK_START,Xi.X8.Silent,e),Lr(this.acquireTokenByRefreshToken.bind(this),Dt,this.logger,this.performanceClient,e.correlationId)(e,t)}))}}class fs{static async createPublicClientApplication(e){const t=await async function(e){const t=new nr(e);return await t.initialize(),gs.createController(t,void 0)}(e);return new fs(e,t)}constructor(e,t){this.controller=t||new gs(new nr(e))}async initialize(e){return this.controller.initialize(e)}async acquireTokenPopup(e){return this.controller.acquireTokenPopup(e)}acquireTokenRedirect(e){return this.controller.acquireTokenRedirect(e)}acquireTokenSilent(e){return this.controller.acquireTokenSilent(e)}acquireTokenByCode(e){return this.controller.acquireTokenByCode(e)}addEventCallback(e,t){return this.controller.addEventCallback(e,t)}removeEventCallback(e){return this.controller.removeEventCallback(e)}addPerformanceCallback(e){return this.controller.addPerformanceCallback(e)}removePerformanceCallback(e){return this.controller.removePerformanceCallback(e)}enableAccountStorageEvents(){this.controller.enableAccountStorageEvents()}disableAccountStorageEvents(){this.controller.disableAccountStorageEvents()}getAccount(e){return this.controller.getAccount(e)}getAccountByHomeId(e){return this.controller.getAccountByHomeId(e)}getAccountByLocalId(e){return this.controller.getAccountByLocalId(e)}getAccountByUsername(e){return this.controller.getAccountByUsername(e)}getAllAccounts(e){return this.controller.getAllAccounts(e)}handleRedirectPromise(e){return this.controller.handleRedirectPromise(e)}loginPopup(e){return this.controller.loginPopup(e)}loginRedirect(e){return this.controller.loginRedirect(e)}logout(e){return this.controller.logout(e)}logoutRedirect(e){return this.controller.logoutRedirect(e)}logoutPopup(e){return this.controller.logoutPopup(e)}ssoSilent(e){return this.controller.ssoSilent(e)}getTokenCache(){return this.controller.getTokenCache()}getLogger(){return this.controller.getLogger()}setLogger(e){this.controller.setLogger(e)}setActiveAccount(e){this.controller.setActiveAccount(e)}getActiveAccount(){return this.controller.getActiveAccount()}initializeWrapperLibrary(e,t){return this.controller.initializeWrapperLibrary(e,t)}setNavigationClient(e){this.controller.setNavigationClient(e)}getConfiguration(){return this.controller.getConfiguration()}async hydrateCache(e,t){return this.controller.hydrateCache(e,t)}clearCache(e){return this.controller.clearCache(e)}}},75970(e,t,i){"use strict";i.d(t,{bD:()=>l,jT:()=>a});var r=i(90865),n=i(2919);const s="For more visit: aka.ms/msaljs/browser-errors",o={[n.p5]:"The PKCE code challenge and verifier could not be generated.",[n.rc]:"The crypto object or function is not available.",[n.B2]:"Navigation URI is empty. Please check stack trace for more info.",[n.wv]:`Hash value cannot be processed because it is empty. Please verify that your redirectUri is not clearing the hash. ${s}`,[n.c$]:"Hash does not contain state. Please verify that the request originated from msal.",[n.Lm]:`Hash does not contain known properites. Please verify that your redirectUri is not changing the hash.  ${s}`,[n.fA]:"Unable to parse state. Please verify that the request originated from msal.",[n.oe]:"Hash contains state but the interaction type does not match the caller.",[n.b]:`Interaction is currently in progress. Please ensure that this interaction has been completed before calling an interactive API.   ${s}`,[n.hs]:"Error opening popup window. This can happen if you are using IE or if popups are blocked in the browser.",[n.MP]:"window.open returned null or undefined window object.",[n.fN]:"User cancelled the flow.",[n.OM]:`Token acquisition in popup failed due to timeout.  ${s}`,[n.Uf]:`Token acquisition in iframe failed due to timeout.  ${s}`,[n.OT]:"Redirects are not supported for iframed or brokered applications. Please ensure you are using MSAL.js in a top frame of the window if using the redirect APIs, or use the popup APIs.",[n.tZ]:`Request was blocked inside an iframe because MSAL detected an authentication response.  ${s}`,[n.aH]:"Request was blocked inside a popup because MSAL detected it was running in a popup.",[n.lg]:"The iframe being monitored was closed prematurely.",[n.v7]:"Silent logout not supported. Please call logoutRedirect or logoutPopup instead.",[n.rR]:"No account object provided to acquireTokenSilent and no active account has been set. Please call setActiveAccount or provide an account on the request.",[n.hZ]:"The value given for the prompt value is not valid for silent requests - must be set to 'none' or 'no_session'.",[n.y6]:"No token request found in cache.",[n.ot]:"The cached token request could not be parsed.",[n.Ne]:"No cached authority found.",[n.LW]:"Auth Request not set. Please ensure initiateAuthRequest was called from the InteractionHandler",[n.Mm]:"Invalid cache type",[n.tI]:"Login and token requests are not supported in non-browser environments.",[n.rn]:"Database is not open!",[n.l7]:"No network connectivity. Check your internet connection.",[n.zv]:"Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA'",[n.Zw]:"Network request failed. Please check the network trace to determine root cause.",[n.db]:"Failed to parse network response. Check network trace.",[n.s9]:"Error loading token to cache.",[n.e0]:"Cryptographic Key or Keypair not found in browser storage.",[n.R3]:"An authorization code must be provided (as the `code` property on the request) to this flow.",[n.xp]:"An authorization code or nativeAccountId must be provided to this flow.",[n.$c]:"Request cannot contain both spa code and native account id.",[n.MG]:"IndexedDB, which is required for persistent cryptographic key storage, is unavailable. This may be caused by browser privacy features which block persistent storage in third-party contexts.",[n.gU]:`Unable to acquire token from native platform.  ${s}`,[n.y3]:"Timed out while attempting to establish connection to browser extension",[n.cq]:"Native extension is not installed. If you think this is a mistake call the initialize function.",[n.XC]:`Connection to native platform has not been established. Please install a compatible browser extension and run initialize().  ${s}`,[n.IR]:`You must call and await the initialize function before attempting to call any other MSAL API.  ${s}`,[n.nF]:"The provided prompt is not supported by the native platform. This request should be routed to the web based flow.",[n._t]:"Invalid base64 encoded string.",[n.bT]:"Invalid PoP token request. The request should not have both a popKid value and signPopToken set to true."};n.p5,n.p5,n.rc,n.rc,n.B2,n.B2,n.wv,n.wv,n.c$,n.c$,n.Lm,n.Lm,n.fA,n.fA,n.oe,n.oe,n.b,n.b,n.hs,n.hs,n.MP,n.MP,n.fN,n.fN,n.OM,n.OM,n.Uf,n.Uf,n.OT,n.OT,n.tZ,n.tZ,n.aH,n.aH,n.lg,n.lg,n.v7,n.v7,n.rR,n.rR,n.hZ,n.hZ,n.y6,n.y6,n.ot,n.ot,n.Ne,n.Ne,n.LW,n.LW,n.Mm,n.Mm,n.tI,n.tI,n.rn,n.rn,n.l7,n.l7,n.zv,n.zv,n.Zw,n.Zw,n.db,n.db,n.s9,n.s9,n.e0,n.e0,n.R3,n.R3,n.xp,n.xp,n.$c,n.$c,n.MG,n.MG,n.gU,n.gU,n.y3,n.y3,n.cq,n.cq,n.XC,n.XC,n.IR,n.IR,n.nF,n.nF,n._t,n._t,n.bT,n.bT;class a extends r.lR{constructor(e){super(e,o[e]),Object.setPrototypeOf(this,a.prototype),this.name="BrowserAuthError"}}function l(e){return new a(e)}},2919(e,t,i){"use strict";i.d(t,{$c:()=>V,B2:()=>s,IR:()=>j,LW:()=>R,Lm:()=>l,MG:()=>H,MP:()=>p,Mm:()=>_,Ne:()=>M,OM:()=>f,OT:()=>v,R3:()=>k,Uf:()=>m,XC:()=>W,Zw:()=>L,_t:()=>$,aH:()=>y,b:()=>h,bT:()=>q,c$:()=>a,cq:()=>U,db:()=>N,e0:()=>F,fA:()=>c,fN:()=>g,gU:()=>B,hZ:()=>E,hs:()=>d,l7:()=>D,lg:()=>w,nF:()=>K,oe:()=>u,ot:()=>T,p5:()=>r,rR:()=>b,rc:()=>n,rn:()=>x,s9:()=>O,tI:()=>P,tZ:()=>C,v7:()=>S,wv:()=>o,xp:()=>G,y3:()=>z,y6:()=>A,zv:()=>I});const r="pkce_not_created",n="crypto_nonexistent",s="empty_navigate_uri",o="hash_empty_error",a="no_state_in_hash",l="hash_does_not_contain_known_properties",c="unable_to_parse_state",u="state_interaction_type_mismatch",h="interaction_in_progress",d="popup_window_error",p="empty_window_error",g="user_cancelled",f="monitor_popup_timeout",m="monitor_window_timeout",v="redirect_in_iframe",C="block_iframe_reload",y="block_nested_popups",w="iframe_closed_prematurely",S="silent_logout_unsupported",b="no_account_error",E="silent_prompt_value_error",A="no_token_request_cache_error",T="unable_to_parse_token_request_cache_error",M="no_cached_authority_error",R="auth_request_not_set_error",_="invalid_cache_type",P="non_browser_environment",x="database_not_open",D="no_network_connectivity",I="post_request_failed",L="get_request_failed",N="failed_to_parse_response",O="unable_to_load_token",F="crypto_key_not_found",k="auth_code_required",G="auth_code_or_nativeAccountId_required",V="spa_code_and_nativeAccountId_present",H="database_unavailable",B="unable_to_acquire_token_from_native_platform",z="native_handshake_timeout",U="native_extension_not_installed",W="native_connection_not_established",j="uninitialized_public_client_application",K="native_prompt_not_supported",$="invalid_base64_string",q="invalid_pop_token_request"},24680(e,t,i){"use strict";i.d(t,{jz:()=>a});var r=i(90865),n=i(85362);const s={[n.xz]:"Given storage configuration option was not supported.",[n.dg]:"Stub instance of Public Client Application was called. If using msal-react, please ensure context is not used without a provider. For more visit: aka.ms/msaljs/browser-errors",[n.jE]:"Redirect cannot be supported. In-memory storage was selected and storeAuthStateInCookie=false, which would cause the library to be unable to handle the incoming hash. If you would like to use the redirect API, please use session/localStorage or set storeAuthStateInCookie=true."};n.xz,n.xz,n.dg,n.dg,n.jE,n.jE;class o extends r.lR{constructor(e,t){super(e,t),this.name="BrowserConfigurationAuthError",Object.setPrototypeOf(this,o.prototype)}}function a(e){return new o(e,s[e])}},85362(e,t,i){"use strict";i.d(t,{dg:()=>n,jE:()=>s,xz:()=>r});const r="storage_not_supported",n="stubbed_public_client_application_called",s="in_mem_redirect_unavailable"},99268(e,t,i){"use strict";i.d(t,{B:()=>r});const r={INITIALIZE_START:"msal:initializeStart",INITIALIZE_END:"msal:initializeEnd",ACCOUNT_ADDED:"msal:accountAdded",ACCOUNT_REMOVED:"msal:accountRemoved",ACTIVE_ACCOUNT_CHANGED:"msal:activeAccountChanged",LOGIN_START:"msal:loginStart",LOGIN_SUCCESS:"msal:loginSuccess",LOGIN_FAILURE:"msal:loginFailure",ACQUIRE_TOKEN_START:"msal:acquireTokenStart",ACQUIRE_TOKEN_SUCCESS:"msal:acquireTokenSuccess",ACQUIRE_TOKEN_FAILURE:"msal:acquireTokenFailure",ACQUIRE_TOKEN_NETWORK_START:"msal:acquireTokenFromNetworkStart",SSO_SILENT_START:"msal:ssoSilentStart",SSO_SILENT_SUCCESS:"msal:ssoSilentSuccess",SSO_SILENT_FAILURE:"msal:ssoSilentFailure",ACQUIRE_TOKEN_BY_CODE_START:"msal:acquireTokenByCodeStart",ACQUIRE_TOKEN_BY_CODE_SUCCESS:"msal:acquireTokenByCodeSuccess",ACQUIRE_TOKEN_BY_CODE_FAILURE:"msal:acquireTokenByCodeFailure",HANDLE_REDIRECT_START:"msal:handleRedirectStart",HANDLE_REDIRECT_END:"msal:handleRedirectEnd",POPUP_OPENED:"msal:popupOpened",LOGOUT_START:"msal:logoutStart",LOGOUT_SUCCESS:"msal:logoutSuccess",LOGOUT_FAILURE:"msal:logoutFailure",LOGOUT_END:"msal:logoutEnd",RESTORE_FROM_BFCACHE:"msal:restoreFromBFCache"}},58090(e,t,i){"use strict";i.d(t,{$u:()=>C,Al:()=>a,CC:()=>l,Ct:()=>o,G8:()=>y,H3:()=>h,JD:()=>s,JE:()=>b,L$:()=>E,P3:()=>A,Q1:()=>n,T$:()=>g,WJ:()=>w,X8:()=>p,_p:()=>c,dh:()=>u,f7:()=>v,jb:()=>m,nN:()=>S,sA:()=>d,uq:()=>f});var r=i(14927);const n={INTERACTION_IN_PROGRESS_VALUE:"interaction_in_progress",INVALID_GRANT_ERROR:"invalid_grant",POPUP_WIDTH:483,POPUP_HEIGHT:600,POPUP_NAME_PREFIX:"msal",DEFAULT_POLL_INTERVAL_MS:30,MSAL_SKU:"msal.js.browser"},s={CHANNEL_ID:"53ee284d-920a-4b59-9d30-a60315b26836",PREFERRED_EXTENSION_ID:"ppnbnpeolgkicgegkbkbjmhlideopiji",MATS_TELEMETRY:"MATS"},o={HandshakeRequest:"Handshake",HandshakeResponse:"HandshakeResponse",GetToken:"GetToken",Response:"Response"},a={LocalStorage:"localStorage",SessionStorage:"sessionStorage",MemoryStorage:"memoryStorage"},l={GET:"GET",POST:"POST"},c={AUTHORITY:"authority",ACQUIRE_TOKEN_ACCOUNT:"acquireToken.account",SESSION_STATE:"session.state",REQUEST_STATE:"request.state",NONCE_IDTOKEN:"nonce.id_token",ORIGIN_URI:"request.origin",RENEW_STATUS:"token.renew.status",URL_HASH:"urlHash",REQUEST_PARAMS:"request.params",SCOPES:"scopes",INTERACTION_STATUS_KEY:"interaction.status",CCS_CREDENTIAL:"ccs.credential",CORRELATION_ID:"request.correlationId",NATIVE_REQUEST:"request.native",REDIRECT_CONTEXT:"request.redirect.context"},u={ACCOUNT_KEYS:"msal.account.keys",TOKEN_KEYS:"msal.token.keys"},h={WRAPPER_SKU:"wrapper.sku",WRAPPER_VER:"wrapper.version"},d={acquireTokenRedirect:861,acquireTokenPopup:862,ssoSilent:863,acquireTokenSilent_authCode:864,handleRedirectPromise:865,acquireTokenByCode:866,acquireTokenSilent_silentFlow:61,logout:961,logoutPopup:962};var p;!function(e){e.Redirect="redirect",e.Popup="popup",e.Silent="silent",e.None="none"}(p||(p={}));const g={Startup:"startup",Login:"login",Logout:"logout",AcquireToken:"acquireToken",SsoSilent:"ssoSilent",HandleRedirect:"handleRedirect",None:"none"},f={scopes:r.aZ},m="jwk",v={React:"@azure/msal-react",Angular:"@azure/msal-angular"},C="msal.db",y=1,w=`${C}.keys`,S={Default:0,AccessToken:1,AccessTokenAndRefreshToken:2,RefreshToken:3,RefreshTokenAndNetwork:4,Skip:5},b=[S.Default,S.Skip,S.RefreshTokenAndNetwork],E="msal.browser.log.level",A="msal.browser.log.pii"},90865(e,t,i){"use strict";i.d(t,{lR:()=>o,pz:()=>a});var r=i(14927),n=i(5841);const s={[n.W]:"Unexpected error in authentication.",[n.z]:"Post request failed from the network, could be a 4xx/5xx or a network unavailability. Please check the exact error code for details."};n.W,n.W,n.z,n.z;class o extends Error{constructor(e,t,i){super(t?`${e}: ${t}`:e),Object.setPrototypeOf(this,o.prototype),this.errorCode=e||r.YM.EMPTY_STRING,this.errorMessage=t||r.YM.EMPTY_STRING,this.subError=i||r.YM.EMPTY_STRING,this.name="AuthError"}setCorrelationId(e){this.correlationId=e}}function a(e,t){return new o(e,t?`${s[e]} ${t}`:s[e])}},5841(e,t,i){"use strict";i.d(t,{W:()=>r,z:()=>n});const r="unexpected_error",n="post_request_failed"},95177(e,t,i){"use strict";i.d(t,{$:()=>r,V:()=>s});var r,n=i(14927);!function(e){e[e.Error=0]="Error",e[e.Warning=1]="Warning",e[e.Info=2]="Info",e[e.Verbose=3]="Verbose",e[e.Trace=4]="Trace"}(r||(r={}));class s{constructor(e,t,i){this.level=r.Info;const o=e||s.createDefaultLoggerOptions();this.localCallback=o.loggerCallback||(()=>{}),this.piiLoggingEnabled=o.piiLoggingEnabled||!1,this.level="number"==typeof o.logLevel?o.logLevel:r.Info,this.correlationId=o.correlationId||n.YM.EMPTY_STRING,this.packageName=t||n.YM.EMPTY_STRING,this.packageVersion=i||n.YM.EMPTY_STRING}static createDefaultLoggerOptions(){return{loggerCallback:()=>{},piiLoggingEnabled:!1,logLevel:r.Info}}clone(e,t,i){return new s({loggerCallback:this.localCallback,piiLoggingEnabled:this.piiLoggingEnabled,logLevel:this.level,correlationId:i||this.correlationId},e,t)}logMessage(e,t){if(t.logLevel>this.level||!this.piiLoggingEnabled&&t.containsPii)return;const i=`[${(new Date).toUTCString()}] : [${t.correlationId||this.correlationId||""}] : ${this.packageName}@${this.packageVersion} : ${r[t.logLevel]} - ${e}`;this.executeCallback(t.logLevel,i,t.containsPii||!1)}executeCallback(e,t,i){this.localCallback&&this.localCallback(e,t,i)}error(e,t){this.logMessage(e,{logLevel:r.Error,containsPii:!1,correlationId:t||n.YM.EMPTY_STRING})}errorPii(e,t){this.logMessage(e,{logLevel:r.Error,containsPii:!0,correlationId:t||n.YM.EMPTY_STRING})}warning(e,t){this.logMessage(e,{logLevel:r.Warning,containsPii:!1,correlationId:t||n.YM.EMPTY_STRING})}warningPii(e,t){this.logMessage(e,{logLevel:r.Warning,containsPii:!0,correlationId:t||n.YM.EMPTY_STRING})}info(e,t){this.logMessage(e,{logLevel:r.Info,containsPii:!1,correlationId:t||n.YM.EMPTY_STRING})}infoPii(e,t){this.logMessage(e,{logLevel:r.Info,containsPii:!0,correlationId:t||n.YM.EMPTY_STRING})}verbose(e,t){this.logMessage(e,{logLevel:r.Verbose,containsPii:!1,correlationId:t||n.YM.EMPTY_STRING})}verbosePii(e,t){this.logMessage(e,{logLevel:r.Verbose,containsPii:!0,correlationId:t||n.YM.EMPTY_STRING})}trace(e,t){this.logMessage(e,{logLevel:r.Trace,containsPii:!1,correlationId:t||n.YM.EMPTY_STRING})}tracePii(e,t){this.logMessage(e,{logLevel:r.Trace,containsPii:!0,correlationId:t||n.YM.EMPTY_STRING})}isPiiLoggingEnabled(){return this.piiLoggingEnabled||!1}}},14927(e,t,i){"use strict";i.d(t,{$x:()=>f,E_:()=>E,F0:()=>N,Fq:()=>u,GU:()=>y,Gd:()=>l,I:()=>R,IO:()=>T,JR:()=>w,Kk:()=>P,LR:()=>v,Lz:()=>L,OK:()=>a,Qd:()=>m,Rv:()=>I,Tq:()=>_,Xw:()=>M,YM:()=>r,_2:()=>D,_A:()=>o,_M:()=>h,aG:()=>C,aZ:()=>s,gT:()=>A,hB:()=>S,iF:()=>d,jZ:()=>x,p:()=>g,t3:()=>n,u0:()=>b,v2:()=>c,zL:()=>p});const r={LIBRARY_NAME:"MSAL.JS",SKU:"msal.js.common",CACHE_PREFIX:"msal",DEFAULT_AUTHORITY:"https://login.microsoftonline.com/common/",DEFAULT_AUTHORITY_HOST:"login.microsoftonline.com",DEFAULT_COMMON_TENANT:"common",ADFS:"adfs",DSTS:"dstsv2",AAD_INSTANCE_DISCOVERY_ENDPT:"https://login.microsoftonline.com/common/discovery/instance?api-version=1.1&authorization_endpoint=",CIAM_AUTH_URL:".ciamlogin.com",AAD_TENANT_DOMAIN_SUFFIX:".onmicrosoft.com",RESOURCE_DELIM:"|",NO_ACCOUNT:"NO_ACCOUNT",CLAIMS:"claims",CONSUMER_UTID:"9188040d-6c67-4c5b-b112-36a304b66dad",OPENID_SCOPE:"openid",PROFILE_SCOPE:"profile",OFFLINE_ACCESS_SCOPE:"offline_access",EMAIL_SCOPE:"email",CODE_RESPONSE_TYPE:"code",CODE_GRANT_TYPE:"authorization_code",RT_GRANT_TYPE:"refresh_token",FRAGMENT_RESPONSE_MODE:"fragment",S256_CODE_CHALLENGE_METHOD:"S256",URL_FORM_CONTENT_TYPE:"application/x-www-form-urlencoded;charset=utf-8",AUTHORIZATION_PENDING:"authorization_pending",NOT_DEFINED:"not_defined",EMPTY_STRING:"",NOT_APPLICABLE:"N/A",NOT_AVAILABLE:"Not Available",FORWARD_SLASH:"/",IMDS_ENDPOINT:"http://169.254.169.254/metadata/instance/compute/location",IMDS_VERSION:"2020-06-01",IMDS_TIMEOUT:2e3,AZURE_REGION_AUTO_DISCOVER_FLAG:"TryAutoDetect",REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX:"login.microsoft.com",KNOWN_PUBLIC_CLOUDS:["login.microsoftonline.com","login.windows.net","login.microsoft.com","sts.windows.net"],TOKEN_RESPONSE_TYPE:"token",ID_TOKEN_RESPONSE_TYPE:"id_token",SHR_NONCE_VALIDITY:240,INVALID_INSTANCE:"invalid_instance"},n={SUCCESS:200,SUCCESS_RANGE_START:200,SUCCESS_RANGE_END:299,REDIRECT:302,CLIENT_ERROR:400,CLIENT_ERROR_RANGE_START:400,BAD_REQUEST:400,UNAUTHORIZED:401,NOT_FOUND:404,REQUEST_TIMEOUT:408,TOO_MANY_REQUESTS:429,CLIENT_ERROR_RANGE_END:499,SERVER_ERROR:500,SERVER_ERROR_RANGE_START:500,SERVICE_UNAVAILABLE:503,GATEWAY_TIMEOUT:504,SERVER_ERROR_RANGE_END:599,MULTI_SIDED_ERROR:600},s=[r.OPENID_SCOPE,r.PROFILE_SCOPE,r.OFFLINE_ACCESS_SCOPE],o=[...s,r.EMAIL_SCOPE],a={CONTENT_TYPE:"Content-Type",RETRY_AFTER:"Retry-After",CCS_HEADER:"X-AnchorMailbox",WWWAuthenticate:"WWW-Authenticate",AuthenticationInfo:"Authentication-Info",X_MS_REQUEST_ID:"x-ms-request-id",X_MS_HTTP_VERSION:"x-ms-httpver"},l={ID_TOKEN:"idtoken",CLIENT_INFO:"client.info",ADAL_ID_TOKEN:"adal.idtoken",ERROR:"error",ERROR_DESC:"error.description",ACTIVE_ACCOUNT:"active-account",ACTIVE_ACCOUNT_FILTERS:"active-account-filters"},c={COMMON:"common",ORGANIZATIONS:"organizations",CONSUMERS:"consumers"},u={ACCESS_TOKEN:"access_token",XMS_CC:"xms_cc"},h={LOGIN:"login",SELECT_ACCOUNT:"select_account",CONSENT:"consent",NONE:"none",CREATE:"create",NO_SESSION:"no_session"},d={PLAIN:"plain",S256:"S256"},p={QUERY:"query",FRAGMENT:"fragment"},g={...p,FORM_POST:"form_post"},f={IMPLICIT_GRANT:"implicit",AUTHORIZATION_CODE_GRANT:"authorization_code",CLIENT_CREDENTIALS_GRANT:"client_credentials",RESOURCE_OWNER_PASSWORD_GRANT:"password",REFRESH_TOKEN_GRANT:"refresh_token",DEVICE_CODE_GRANT:"device_code",JWT_BEARER:"urn:ietf:params:oauth:grant-type:jwt-bearer"},m={MSSTS_ACCOUNT_TYPE:"MSSTS",ADFS_ACCOUNT_TYPE:"ADFS",MSAV1_ACCOUNT_TYPE:"MSA",GENERIC_ACCOUNT_TYPE:"Generic"},v={CACHE_KEY_SEPARATOR:"-",CLIENT_INFO_SEPARATOR:"."},C={ID_TOKEN:"IdToken",ACCESS_TOKEN:"AccessToken",ACCESS_TOKEN_WITH_AUTH_SCHEME:"AccessToken_With_AuthScheme",REFRESH_TOKEN:"RefreshToken"},y="appmetadata",w="client_info",S="1",b={CACHE_KEY:"authority-metadata",REFRESH_TIME_SECONDS:86400},E={CONFIG:"config",CACHE:"cache",NETWORK:"network",HARDCODED_VALUES:"hardcoded_values"},A={SCHEMA_VERSION:5,MAX_CUR_HEADER_BYTES:80,MAX_LAST_HEADER_BYTES:330,MAX_CACHED_ERRORS:50,CACHE_KEY:"server-telemetry",CATEGORY_SEPARATOR:"|",VALUE_SEPARATOR:",",OVERFLOW_TRUE:"1",OVERFLOW_FALSE:"0",UNKNOWN_ERROR:"unknown_error"},T={BEARER:"Bearer",POP:"pop",SSH:"ssh-cert"},M={DEFAULT_THROTTLE_TIME_SECONDS:60,DEFAULT_MAX_THROTTLE_TIME_SECONDS:3600,THROTTLING_PREFIX:"throttling",X_MS_LIB_CAPABILITY_VALUE:"retry-after, h429"},R={INVALID_GRANT_ERROR:"invalid_grant",CLIENT_MISMATCH_ERROR:"client_mismatch"},_={username:"username",password:"password"},P={httpSuccess:200,httpBadRequest:400},x={FAILED_AUTO_DETECTION:"1",INTERNAL_CACHE:"2",ENVIRONMENT_VARIABLE:"3",IMDS:"4"},D={CONFIGURED_MATCHES_DETECTED:"1",CONFIGURED_NO_AUTO_DETECTION:"2",CONFIGURED_NOT_DETECTED:"3",AUTO_DETECTION_REQUESTED_SUCCESSFUL:"4",AUTO_DETECTION_REQUESTED_FAILED:"5"},I={NOT_APPLICABLE:"0",FORCE_REFRESH_OR_CLAIMS:"1",NO_CACHED_ACCESS_TOKEN:"2",CACHED_ACCESS_TOKEN_EXPIRED:"3",PROACTIVELY_REFRESHED:"4"},L={Jwt:"JWT",Jwk:"JWK",Pop:"pop"},N=300},55534(e,t,i){"use strict";i.d(t,{r7:()=>C,dk:()=>y});var r=i(22155),n=i(24680),s=i(85362);const o={initialize:()=>Promise.reject((0,n.jz)(s.dg)),acquireTokenPopup:()=>Promise.reject((0,n.jz)(s.dg)),acquireTokenRedirect:()=>Promise.reject((0,n.jz)(s.dg)),acquireTokenSilent:()=>Promise.reject((0,n.jz)(s.dg)),acquireTokenByCode:()=>Promise.reject((0,n.jz)(s.dg)),getAllAccounts:()=>[],getAccount:()=>null,getAccountByHomeId:()=>null,getAccountByUsername:()=>null,getAccountByLocalId:()=>null,handleRedirectPromise:()=>Promise.reject((0,n.jz)(s.dg)),loginPopup:()=>Promise.reject((0,n.jz)(s.dg)),loginRedirect:()=>Promise.reject((0,n.jz)(s.dg)),logout:()=>Promise.reject((0,n.jz)(s.dg)),logoutRedirect:()=>Promise.reject((0,n.jz)(s.dg)),logoutPopup:()=>Promise.reject((0,n.jz)(s.dg)),ssoSilent:()=>Promise.reject((0,n.jz)(s.dg)),addEventCallback:()=>null,removeEventCallback:()=>{},addPerformanceCallback:()=>"",removePerformanceCallback:()=>!1,enableAccountStorageEvents:()=>{},disableAccountStorageEvents:()=>{},getTokenCache:()=>{throw(0,n.jz)(s.dg)},getLogger:()=>{throw(0,n.jz)(s.dg)},setLogger:()=>{},setActiveAccount:()=>{},getActiveAccount:()=>null,initializeWrapperLibrary:()=>{},setNavigationClient:()=>{},getConfiguration:()=>{throw(0,n.jz)(s.dg)},hydrateCache:()=>Promise.reject((0,n.jz)(s.dg)),clearCache:()=>Promise.reject((0,n.jz)(s.dg))};var a=i(58090),l=i(95177);const c={instance:o,inProgress:a.T$.None,accounts:[],logger:new l.V({})},u=r.createContext(c);u.Consumer;var h=i(99268);class d{static getInteractionStatusFromEvent(e,t){switch(e.eventType){case h.B.LOGIN_START:return a.T$.Login;case h.B.SSO_SILENT_START:return a.T$.SsoSilent;case h.B.ACQUIRE_TOKEN_START:if(e.interactionType===a.X8.Redirect||e.interactionType===a.X8.Popup)return a.T$.AcquireToken;break;case h.B.HANDLE_REDIRECT_START:return a.T$.HandleRedirect;case h.B.LOGOUT_START:return a.T$.Logout;case h.B.SSO_SILENT_SUCCESS:case h.B.SSO_SILENT_FAILURE:if(t&&t!==a.T$.SsoSilent)break;return a.T$.None;case h.B.LOGOUT_END:if(t&&t!==a.T$.Logout)break;return a.T$.None;case h.B.HANDLE_REDIRECT_END:if(t&&t!==a.T$.HandleRedirect)break;return a.T$.None;case h.B.LOGIN_SUCCESS:case h.B.LOGIN_FAILURE:case h.B.ACQUIRE_TOKEN_SUCCESS:case h.B.ACQUIRE_TOKEN_FAILURE:case h.B.RESTORE_FROM_BFCACHE:if(e.interactionType===a.X8.Redirect||e.interactionType===a.X8.Popup){if(t&&t!==a.T$.Login&&t!==a.T$.AcquireToken)break;return a.T$.None}}return null}}function p(e,t){if(e.length!==t.length)return!1;const i=[...t];return e.every(e=>{const t=i.shift();return!(!e||!t)&&e.homeAccountId===t.homeAccountId&&e.localAccountId===t.localAccountId&&e.username===t.username})}const g="2.1.1",f="UNBLOCK_INPROGRESS",m="EVENT",v=(e,t)=>{const{type:i,payload:r}=t;let n=e.inProgress;switch(i){case f:e.inProgress===a.T$.Startup&&(n=a.T$.None,r.logger.info("MsalProvider - handleRedirectPromise resolved, setting inProgress to 'none'"));break;case m:const t=r.message,s=d.getInteractionStatusFromEvent(t,e.inProgress);s&&(r.logger.info(`MsalProvider - ${t.eventType} results in setting inProgress from ${e.inProgress} to ${s}`),n=s);break;default:throw new Error(`Unknown action type: ${i}`)}const s=r.instance.getAllAccounts();return n===e.inProgress||p(s,e.accounts)?n!==e.inProgress?{...e,inProgress:n}:p(s,e.accounts)?e:{...e,accounts:s}:{...e,inProgress:n,accounts:s}};function C({instance:e,children:t}){(0,r.useEffect)(()=>{e.initializeWrapperLibrary(a.f7.React,g)},[e]);const i=(0,r.useMemo)(()=>e.getLogger().clone("@azure/msal-react",g),[e]),[n,s]=(0,r.useReducer)(v,void 0,()=>({inProgress:a.T$.Startup,accounts:e.getAllAccounts()}));(0,r.useEffect)(()=>{const t=e.addEventCallback(t=>{s({payload:{instance:e,logger:i,message:t},type:m})});return i.verbose(`MsalProvider - Registered event callback with id: ${t}`),e.initialize().then(()=>{e.handleRedirectPromise().catch(()=>{}).finally(()=>{s({payload:{instance:e,logger:i},type:f})})}).catch(()=>{}),()=>{t&&(i.verbose(`MsalProvider - Removing event callback ${t}`),e.removeEventCallback(t))}},[e,i]);const o={instance:e,inProgress:n.inProgress,accounts:n.accounts,logger:i};return r.createElement(u.Provider,{value:o},t)}const y=()=>(0,r.useContext)(u);i(90865).lR},20301(e,t,i){"use strict";function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var i=0,r=Array(t);i<t;i++)r[i]=e[i];return r}i.d(t,{A:()=>r})},96701(e,t,i){"use strict";function r(e){if(Array.isArray(e))return e}i.d(t,{A:()=>r})},13925(e,t,i){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}i.d(t,{A:()=>r})},77401(e,t,i){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}i.d(t,{A:()=>r})},48209(e,t,i){"use strict";i.d(t,{A:()=>s});var r=i(61444);function n(e,t){for(var i=0;i<t.length;i++){var n=t[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,(0,r.A)(n.key),n)}}function s(e,t,i){return t&&n(e.prototype,t),i&&n(e,i),Object.defineProperty(e,"prototype",{writable:!1}),e}},42750(e,t,i){"use strict";function r(e){return r=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},r(e)}function n(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(e){}return(n=function(){return!!e})()}i.d(t,{A:()=>a});var s=i(97408),o=i(13925);function a(e){var t=n();return function(){var i,n=r(e);if(t){var a=r(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return function(e,t){if(t&&("object"==(0,s.A)(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return(0,o.A)(e)}(this,i)}}},80663(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(61444);function n(e,t,i){return(t=(0,r.A)(t))in e?Object.defineProperty(e,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):e[t]=i,e}},69932(e,t,i){"use strict";function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var r in i)({}).hasOwnProperty.call(i,r)&&(e[r]=i[r])}return e},r.apply(null,arguments)}i.d(t,{A:()=>r})},92041(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(60074);function n(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&(0,r.A)(e,t)}},20415(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(60074);function n(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,(0,r.A)(e,t)}},88753(e,t,i){"use strict";function r(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}i.d(t,{A:()=>r})},55222(e,t,i){"use strict";function r(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}i.d(t,{A:()=>r})},83479(e,t,i){"use strict";i.d(t,{A:()=>s});var r=i(80663);function n(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),i.push.apply(i,r)}return i}function s(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?n(Object(i),!0).forEach(function(t){(0,r.A)(e,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):n(Object(i)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))})}return e}},90009(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(12975);function n(e,t){if(null==e)return{};var i,n,s=(0,r.A)(e,t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(n=0;n<o.length;n++)i=o[n],-1===t.indexOf(i)&&{}.propertyIsEnumerable.call(e,i)&&(s[i]=e[i])}return s}},12975(e,t,i){"use strict";function r(e,t){if(null==e)return{};var i={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(-1!==t.indexOf(r))continue;i[r]=e[r]}return i}i.d(t,{A:()=>r})},60074(e,t,i){"use strict";function r(e,t){return r=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},r(e,t)}i.d(t,{A:()=>r})},89324(e,t,i){"use strict";i.d(t,{A:()=>o});var r=i(96701),n=i(89876),s=i(55222);function o(e,t){return(0,r.A)(e)||function(e,t){var i=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=i){var r,n,s,o,a=[],l=!0,c=!1;try{if(s=(i=i.call(e)).next,0===t){if(Object(i)!==i)return;l=!1}else for(;!(l=(r=s.call(i)).done)&&(a.push(r.value),a.length!==t);l=!0);}catch(e){c=!0,n=e}finally{try{if(!l&&null!=i.return&&(o=i.return(),Object(o)!==o))return}finally{if(c)throw n}}return a}}(e,t)||(0,n.A)(e,t)||(0,s.A)()}},14364(e,t,i){"use strict";function r(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}i.d(t,{A:()=>r})},54523(e,t,i){"use strict";i.d(t,{A:()=>a});var r=i(96701),n=i(88753),s=i(89876),o=i(55222);function a(e){return(0,r.A)(e)||(0,n.A)(e)||(0,s.A)(e)||(0,o.A)()}},72432(e,t,i){"use strict";i.d(t,{A:()=>o});var r=i(20301),n=i(88753),s=i(89876);function o(e){return function(e){if(Array.isArray(e))return(0,r.A)(e)}(e)||(0,n.A)(e)||(0,s.A)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},61444(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(97408);function n(e){var t=function(e){if("object"!=(0,r.A)(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var i=t.call(e,"string");if("object"!=(0,r.A)(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==(0,r.A)(t)?t:t+""}},97408(e,t,i){"use strict";function r(e){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r(e)}i.d(t,{A:()=>r})},89876(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(20301);function n(e,t){if(e){if("string"==typeof e)return(0,r.A)(e,t);var i={}.toString.call(e).slice(8,-1);return"Object"===i&&e.constructor&&(i=e.constructor.name),"Map"===i||"Set"===i?Array.from(e):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?(0,r.A)(e,t):void 0}}},4830(e,t,i){"use strict";i.d(t,{UE:()=>O,RK:()=>x,ll:()=>R,rD:()=>G,__:()=>_,UU:()=>I,jD:()=>N,mG:()=>F,ER:()=>k,cY:()=>P,iD:()=>T,BN:()=>D,Ej:()=>L});var r=i(51771);function n(e,t,i){let{reference:n,floating:s}=e;const o=(0,r.TV)(t),a=(0,r.Dz)(t),l=(0,r.sq)(a),c=(0,r.C0)(t),u="y"===o,h=n.x+n.width/2-s.width/2,d=n.y+n.height/2-s.height/2,p=n[l]/2-s[l]/2;let g;switch(c){case"top":g={x:h,y:n.y-s.height};break;case"bottom":g={x:h,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:d};break;case"left":g={x:n.x-s.width,y:d};break;default:g={x:n.x,y:n.y}}switch((0,r.Sg)(t)){case"start":g[a]-=p*(i&&u?-1:1);break;case"end":g[a]+=p*(i&&u?-1:1)}return g}async function s(e,t){var i;void 0===t&&(t={});const{x:n,y:s,platform:o,rects:a,elements:l,strategy:c}=e,{boundary:u="clippingAncestors",rootBoundary:h="viewport",elementContext:d="floating",altBoundary:p=!1,padding:g=0}=(0,r._3)(t,e),f=(0,r.nI)(g),m=l[p?"floating"===d?"reference":"floating":d],v=(0,r.B1)(await o.getClippingRect({element:null==(i=await(null==o.isElement?void 0:o.isElement(m)))||i?m:m.contextElement||await(null==o.getDocumentElement?void 0:o.getDocumentElement(l.floating)),boundary:u,rootBoundary:h,strategy:c})),C="floating"===d?{x:n,y:s,width:a.floating.width,height:a.floating.height}:a.reference,y=await(null==o.getOffsetParent?void 0:o.getOffsetParent(l.floating)),w=await(null==o.isElement?void 0:o.isElement(y))&&await(null==o.getScale?void 0:o.getScale(y))||{x:1,y:1},S=(0,r.B1)(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:C,offsetParent:y,strategy:c}):C);return{top:(v.top-S.top+f.top)/w.y,bottom:(S.bottom-v.bottom+f.bottom)/w.y,left:(v.left-S.left+f.left)/w.x,right:(S.right-v.right+f.right)/w.x}}function o(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function a(e){return r.r_.some(t=>e[t]>=0)}function l(e){const t=(0,r.jk)(...e.map(e=>e.left)),i=(0,r.jk)(...e.map(e=>e.top));return{x:t,y:i,width:(0,r.T9)(...e.map(e=>e.right))-t,height:(0,r.T9)(...e.map(e=>e.bottom))-i}}const c=new Set(["left","top"]);var u=i(32125);function h(e){const t=(0,u.L9)(e);let i=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const s=(0,u.sb)(e),o=s?e.offsetWidth:i,a=s?e.offsetHeight:n,l=(0,r.LI)(i)!==o||(0,r.LI)(n)!==a;return l&&(i=o,n=a),{width:i,height:n,$:l}}function d(e){return(0,u.vq)(e)?e:e.contextElement}function p(e){const t=d(e);if(!(0,u.sb)(t))return(0,r.Jx)(1);const i=t.getBoundingClientRect(),{width:n,height:s,$:o}=h(t);let a=(o?(0,r.LI)(i.width):i.width)/n,l=(o?(0,r.LI)(i.height):i.height)/s;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const g=(0,r.Jx)(0);function f(e){const t=(0,u.zk)(e);return(0,u.Tc)()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:g}function m(e,t,i,n){void 0===t&&(t=!1),void 0===i&&(i=!1);const s=e.getBoundingClientRect(),o=d(e);let a=(0,r.Jx)(1);t&&(n?(0,u.vq)(n)&&(a=p(n)):a=p(e));const l=function(e,t,i){return void 0===t&&(t=!1),!(!i||t&&i!==(0,u.zk)(e))&&t}(o,i,n)?f(o):(0,r.Jx)(0);let c=(s.left+l.x)/a.x,h=(s.top+l.y)/a.y,g=s.width/a.x,m=s.height/a.y;if(o){const e=(0,u.zk)(o),t=n&&(0,u.vq)(n)?(0,u.zk)(n):n;let i=e,r=(0,u._m)(i);for(;r&&n&&t!==i;){const e=p(r),t=r.getBoundingClientRect(),n=(0,u.L9)(r),s=t.left+(r.clientLeft+parseFloat(n.paddingLeft))*e.x,o=t.top+(r.clientTop+parseFloat(n.paddingTop))*e.y;c*=e.x,h*=e.y,g*=e.x,m*=e.y,c+=s,h+=o,i=(0,u.zk)(r),r=(0,u._m)(i)}}return(0,r.B1)({width:g,height:m,x:c,y:h})}function v(e,t){const i=(0,u.CP)(e).scrollLeft;return t?t.left+i:m((0,u.ep)(e)).left+i}function C(e,t){const i=e.getBoundingClientRect();return{x:i.left+t.scrollLeft-v(e,i),y:i.top+t.scrollTop}}function y(e,t,i){let n;if("viewport"===t)n=function(e,t){const i=(0,u.zk)(e),r=(0,u.ep)(e),n=i.visualViewport;let s=r.clientWidth,o=r.clientHeight,a=0,l=0;if(n){s=n.width,o=n.height;const e=(0,u.Tc)();(!e||e&&"fixed"===t)&&(a=n.offsetLeft,l=n.offsetTop)}const c=v(r);if(c<=0){const e=r.ownerDocument,t=e.body,i=getComputedStyle(t),n="CSS1Compat"===e.compatMode&&parseFloat(i.marginLeft)+parseFloat(i.marginRight)||0,o=Math.abs(r.clientWidth-t.clientWidth-n);o<=25&&(s-=o)}else c<=25&&(s+=c);return{width:s,height:o,x:a,y:l}}(e,i);else if("document"===t)n=function(e){const t=(0,u.ep)(e),i=(0,u.CP)(e),n=e.ownerDocument.body,s=(0,r.T9)(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),o=(0,r.T9)(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let a=-i.scrollLeft+v(e);const l=-i.scrollTop;return"rtl"===(0,u.L9)(n).direction&&(a+=(0,r.T9)(t.clientWidth,n.clientWidth)-s),{width:s,height:o,x:a,y:l}}((0,u.ep)(e));else if((0,u.vq)(t))n=function(e,t){const i=m(e,!0,"fixed"===t),n=i.top+e.clientTop,s=i.left+e.clientLeft,o=(0,u.sb)(e)?p(e):(0,r.Jx)(1);return{width:e.clientWidth*o.x,height:e.clientHeight*o.y,x:s*o.x,y:n*o.y}}(t,i);else{const i=f(e);n={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return(0,r.B1)(n)}function w(e,t){const i=(0,u.$4)(e);return!(i===t||!(0,u.vq)(i)||(0,u.eu)(i))&&("fixed"===(0,u.L9)(i).position||w(i,t))}function S(e,t,i){const n=(0,u.sb)(t),s=(0,u.ep)(t),o="fixed"===i,a=m(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const c=(0,r.Jx)(0);function h(){c.x=v(s)}if(n||!n&&!o)if(("body"!==(0,u.mq)(t)||(0,u.ZU)(s))&&(l=(0,u.CP)(t)),n){const e=m(t,!0,o,t);c.x=e.x+t.clientLeft,c.y=e.y+t.clientTop}else s&&h();o&&!n&&s&&h();const d=!s||n||o?(0,r.Jx)(0):C(s,l);return{x:a.left+l.scrollLeft-c.x-d.x,y:a.top+l.scrollTop-c.y-d.y,width:a.width,height:a.height}}function b(e){return"static"===(0,u.L9)(e).position}function E(e,t){if(!(0,u.sb)(e)||"fixed"===(0,u.L9)(e).position)return null;if(t)return t(e);let i=e.offsetParent;return(0,u.ep)(e)===i&&(i=i.ownerDocument.body),i}function A(e,t){const i=(0,u.zk)(e);if((0,u.Tf)(e))return i;if(!(0,u.sb)(e)){let t=(0,u.$4)(e);for(;t&&!(0,u.eu)(t);){if((0,u.vq)(t)&&!b(t))return t;t=(0,u.$4)(t)}return i}let r=E(e,t);for(;r&&(0,u.Lv)(r)&&b(r);)r=E(r,t);return r&&(0,u.eu)(r)&&b(r)&&!(0,u.sQ)(r)?i:r||(0,u.gJ)(e)||i}const T={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:i,offsetParent:n,strategy:s}=e;const o="fixed"===s,a=(0,u.ep)(n),l=!!t&&(0,u.Tf)(t.floating);if(n===a||l&&o)return i;let c={scrollLeft:0,scrollTop:0},h=(0,r.Jx)(1);const d=(0,r.Jx)(0),g=(0,u.sb)(n);if((g||!g&&!o)&&(("body"!==(0,u.mq)(n)||(0,u.ZU)(a))&&(c=(0,u.CP)(n)),g)){const e=m(n);h=p(n),d.x=e.x+n.clientLeft,d.y=e.y+n.clientTop}const f=!a||g||o?(0,r.Jx)(0):C(a,c);return{width:i.width*h.x,height:i.height*h.y,x:i.x*h.x-c.scrollLeft*h.x+d.x+f.x,y:i.y*h.y-c.scrollTop*h.y+d.y+f.y}},getDocumentElement:u.ep,getClippingRect:function(e){let{element:t,boundary:i,rootBoundary:n,strategy:s}=e;const o=[..."clippingAncestors"===i?(0,u.Tf)(t)?[]:function(e,t){const i=t.get(e);if(i)return i;let r=(0,u.v9)(e,[],!1).filter(e=>(0,u.vq)(e)&&"body"!==(0,u.mq)(e)),n=null;const s="fixed"===(0,u.L9)(e).position;let o=s?(0,u.$4)(e):e;for(;(0,u.vq)(o)&&!(0,u.eu)(o);){const t=(0,u.L9)(o),i=(0,u.sQ)(o);i||"fixed"!==t.position||(n=null),(s?!i&&!n:!i&&"static"===t.position&&n&&("absolute"===n.position||"fixed"===n.position)||(0,u.ZU)(o)&&!i&&w(e,o))?r=r.filter(e=>e!==o):n=t,o=(0,u.$4)(o)}return t.set(e,r),r}(t,this._c):[].concat(i),n],a=y(t,o[0],s);let l=a.top,c=a.right,h=a.bottom,d=a.left;for(let e=1;e<o.length;e++){const i=y(t,o[e],s);l=(0,r.T9)(i.top,l),c=(0,r.jk)(i.right,c),h=(0,r.jk)(i.bottom,h),d=(0,r.T9)(i.left,d)}return{width:c-d,height:h-l,x:d,y:l}},getOffsetParent:A,getElementRects:async function(e){const t=this.getOffsetParent||A,i=this.getDimensions,r=await i(e.floating);return{reference:S(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:i}=h(e);return{width:t,height:i}},getScale:p,isElement:u.vq,isRTL:function(e){return"rtl"===(0,u.L9)(e).direction}};function M(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function R(e,t,i,n){void 0===n&&(n={});const{ancestorScroll:s=!0,ancestorResize:o=!0,elementResize:a="function"==typeof ResizeObserver,layoutShift:l="function"==typeof IntersectionObserver,animationFrame:c=!1}=n,h=d(e),p=s||o?[...h?(0,u.v9)(h):[],...t?(0,u.v9)(t):[]]:[];p.forEach(e=>{s&&e.addEventListener("scroll",i,{passive:!0}),o&&e.addEventListener("resize",i)});const g=h&&l?function(e,t){let i,n=null;const s=(0,u.ep)(e);function o(){var e;clearTimeout(i),null==(e=n)||e.disconnect(),n=null}return function a(l,c){void 0===l&&(l=!1),void 0===c&&(c=1),o();const u=e.getBoundingClientRect(),{left:h,top:d,width:p,height:g}=u;if(l||t(),!p||!g)return;const f={rootMargin:-(0,r.RI)(d)+"px "+-(0,r.RI)(s.clientWidth-(h+p))+"px "+-(0,r.RI)(s.clientHeight-(d+g))+"px "+-(0,r.RI)(h)+"px",threshold:(0,r.T9)(0,(0,r.jk)(1,c))||1};let m=!0;function v(t){const r=t[0].intersectionRatio;if(r!==c){if(!m)return a();r?a(!1,r):i=setTimeout(()=>{a(!1,1e-7)},1e3)}1!==r||M(u,e.getBoundingClientRect())||a(),m=!1}try{n=new IntersectionObserver(v,{...f,root:s.ownerDocument})}catch(e){n=new IntersectionObserver(v,f)}n.observe(e)}(!0),o}(h,i):null;let f,v=-1,C=null;a&&(C=new ResizeObserver(e=>{let[r]=e;r&&r.target===h&&C&&t&&(C.unobserve(t),cancelAnimationFrame(v),v=requestAnimationFrame(()=>{var e;null==(e=C)||e.observe(t)})),i()}),h&&!c&&C.observe(h),t&&C.observe(t));let y=c?m(e):null;return c&&function t(){const r=m(e);y&&!M(y,r)&&i(),y=r,f=requestAnimationFrame(t)}(),i(),()=>{var e;p.forEach(e=>{s&&e.removeEventListener("scroll",i),o&&e.removeEventListener("resize",i)}),null==g||g(),null==(e=C)||e.disconnect(),C=null,c&&cancelAnimationFrame(f)}}const _=s,P=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var i,n;const{x:s,y:o,placement:a,middlewareData:l}=t,u=await async function(e,t){const{placement:i,platform:n,elements:s}=e,o=await(null==n.isRTL?void 0:n.isRTL(s.floating)),a=(0,r.C0)(i),l=(0,r.Sg)(i),u="y"===(0,r.TV)(i),h=c.has(a)?-1:1,d=o&&u?-1:1,p=(0,r._3)(t,e);let{mainAxis:g,crossAxis:f,alignmentAxis:m}="number"==typeof p?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return l&&"number"==typeof m&&(f="end"===l?-1*m:m),u?{x:f*d,y:g*h}:{x:g*h,y:f*d}}(t,e);return a===(null==(i=l.offset)?void 0:i.placement)&&null!=(n=l.arrow)&&n.alignmentOffset?{}:{x:s+u.x,y:o+u.y,data:{...u,placement:a}}}}},x=function(e){return void 0===e&&(e={}),{name:"autoPlacement",options:e,async fn(t){var i,n,s;const{rects:o,middlewareData:a,placement:l,platform:c,elements:u}=t,{crossAxis:h=!1,alignment:d,allowedPlacements:p=r.DD,autoAlignment:g=!0,...f}=(0,r._3)(e,t),m=void 0!==d||p===r.DD?function(e,t,i){return(e?[...i.filter(t=>(0,r.Sg)(t)===e),...i.filter(t=>(0,r.Sg)(t)!==e)]:i.filter(e=>(0,r.C0)(e)===e)).filter(i=>!e||(0,r.Sg)(i)===e||!!t&&(0,r.aD)(i)!==i)}(d||null,g,p):p,v=await c.detectOverflow(t,f),C=(null==(i=a.autoPlacement)?void 0:i.index)||0,y=m[C];if(null==y)return{};const w=(0,r.w7)(y,o,await(null==c.isRTL?void 0:c.isRTL(u.floating)));if(l!==y)return{reset:{placement:m[0]}};const S=[v[(0,r.C0)(y)],v[w[0]],v[w[1]]],b=[...(null==(n=a.autoPlacement)?void 0:n.overflows)||[],{placement:y,overflows:S}],E=m[C+1];if(E)return{data:{index:C+1,overflows:b},reset:{placement:E}};const A=b.map(e=>{const t=(0,r.Sg)(e.placement);return[e.placement,t&&h?e.overflows.slice(0,2).reduce((e,t)=>e+t,0):e.overflows[0],e.overflows]}).sort((e,t)=>e[1]-t[1]),T=(null==(s=A.filter(e=>e[2].slice(0,(0,r.Sg)(e[0])?2:3).every(e=>e<=0))[0])?void 0:s[0])||A[0][0];return T!==l?{data:{index:C+1,overflows:b},reset:{placement:T}}:{}}}},D=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:i,y:n,placement:s,platform:o}=t,{mainAxis:a=!0,crossAxis:l=!1,limiter:c={fn:e=>{let{x:t,y:i}=e;return{x:t,y:i}}},...u}=(0,r._3)(e,t),h={x:i,y:n},d=await o.detectOverflow(t,u),p=(0,r.TV)((0,r.C0)(s)),g=(0,r.PG)(p);let f=h[g],m=h[p];if(a){const e="y"===g?"bottom":"right",t=f+d["y"===g?"top":"left"],i=f-d[e];f=(0,r.qE)(t,f,i)}if(l){const e="y"===p?"bottom":"right",t=m+d["y"===p?"top":"left"],i=m-d[e];m=(0,r.qE)(t,m,i)}const v=c.fn({...t,[g]:f,[p]:m});return{...v,data:{x:v.x-i,y:v.y-n,enabled:{[g]:a,[p]:l}}}}}},I=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var i,n;const{placement:s,middlewareData:o,rects:a,initialPlacement:l,platform:c,elements:u}=t,{mainAxis:h=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:g="bestFit",fallbackAxisSideDirection:f="none",flipAlignment:m=!0,...v}=(0,r._3)(e,t);if(null!=(i=o.arrow)&&i.alignmentOffset)return{};const C=(0,r.C0)(s),y=(0,r.TV)(l),w=(0,r.C0)(l)===l,S=await(null==c.isRTL?void 0:c.isRTL(u.floating)),b=p||(w||!m?[(0,r.bV)(l)]:(0,r.WJ)(l)),E="none"!==f;!p&&E&&b.push(...(0,r.lP)(l,m,f,S));const A=[l,...b],T=await c.detectOverflow(t,v),M=[];let R=(null==(n=o.flip)?void 0:n.overflows)||[];if(h&&M.push(T[C]),d){const e=(0,r.w7)(s,a,S);M.push(T[e[0]],T[e[1]])}if(R=[...R,{placement:s,overflows:M}],!M.every(e=>e<=0)){var _,P;const e=((null==(_=o.flip)?void 0:_.index)||0)+1,t=A[e];if(t&&("alignment"!==d||y===(0,r.TV)(t)||R.every(e=>(0,r.TV)(e.placement)!==y||e.overflows[0]>0)))return{data:{index:e,overflows:R},reset:{placement:t}};let i=null==(P=R.filter(e=>e.overflows[0]<=0).sort((e,t)=>e.overflows[1]-t.overflows[1])[0])?void 0:P.placement;if(!i)switch(g){case"bestFit":{var x;const e=null==(x=R.filter(e=>{if(E){const t=(0,r.TV)(e.placement);return t===y||"y"===t}return!0}).map(e=>[e.placement,e.overflows.filter(e=>e>0).reduce((e,t)=>e+t,0)]).sort((e,t)=>e[1]-t[1])[0])?void 0:x[0];e&&(i=e);break}case"initialPlacement":i=l}if(s!==i)return{reset:{placement:i}}}return{}}}},L=function(e){return void 0===e&&(e={}),{name:"size",options:e,async fn(t){var i,n;const{placement:s,rects:o,platform:a,elements:l}=t,{apply:c=()=>{},...u}=(0,r._3)(e,t),h=await a.detectOverflow(t,u),d=(0,r.C0)(s),p=(0,r.Sg)(s),g="y"===(0,r.TV)(s),{width:f,height:m}=o.floating;let v,C;"top"===d||"bottom"===d?(v=d,C=p===(await(null==a.isRTL?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(C=d,v="end"===p?"top":"bottom");const y=m-h.top-h.bottom,w=f-h.left-h.right,S=(0,r.jk)(m-h[v],y),b=(0,r.jk)(f-h[C],w),E=!t.middlewareData.shift;let A=S,T=b;if(null!=(i=t.middlewareData.shift)&&i.enabled.x&&(T=w),null!=(n=t.middlewareData.shift)&&n.enabled.y&&(A=y),E&&!p){const e=(0,r.T9)(h.left,0),t=(0,r.T9)(h.right,0),i=(0,r.T9)(h.top,0),n=(0,r.T9)(h.bottom,0);g?T=f-2*(0!==e||0!==t?e+t:(0,r.T9)(h.left,h.right)):A=m-2*(0!==i||0!==n?i+n:(0,r.T9)(h.top,h.bottom))}await c({...t,availableWidth:T,availableHeight:A});const M=await a.getDimensions(l.floating);return f!==M.width||m!==M.height?{reset:{rects:!0}}:{}}}},N=function(e){return void 0===e&&(e={}),{name:"hide",options:e,async fn(t){const{rects:i,platform:n}=t,{strategy:s="referenceHidden",...l}=(0,r._3)(e,t);switch(s){case"referenceHidden":{const e=o(await n.detectOverflow(t,{...l,elementContext:"reference"}),i.reference);return{data:{referenceHiddenOffsets:e,referenceHidden:a(e)}}}case"escaped":{const e=o(await n.detectOverflow(t,{...l,altBoundary:!0}),i.floating);return{data:{escapedOffsets:e,escaped:a(e)}}}default:return{}}}}},O=e=>({name:"arrow",options:e,async fn(t){const{x:i,y:n,placement:s,rects:o,platform:a,elements:l,middlewareData:c}=t,{element:u,padding:h=0}=(0,r._3)(e,t)||{};if(null==u)return{};const d=(0,r.nI)(h),p={x:i,y:n},g=(0,r.Dz)(s),f=(0,r.sq)(g),m=await a.getDimensions(u),v="y"===g,C=v?"top":"left",y=v?"bottom":"right",w=v?"clientHeight":"clientWidth",S=o.reference[f]+o.reference[g]-p[g]-o.floating[f],b=p[g]-o.reference[g],E=await(null==a.getOffsetParent?void 0:a.getOffsetParent(u));let A=E?E[w]:0;A&&await(null==a.isElement?void 0:a.isElement(E))||(A=l.floating[w]||o.floating[f]);const T=S/2-b/2,M=A/2-m[f]/2-1,R=(0,r.jk)(d[C],M),_=(0,r.jk)(d[y],M),P=R,x=A-m[f]-_,D=A/2-m[f]/2+T,I=(0,r.qE)(P,D,x),L=!c.arrow&&null!=(0,r.Sg)(s)&&D!==I&&o.reference[f]/2-(D<P?R:_)-m[f]/2<0,N=L?D<P?D-P:D-x:0;return{[g]:p[g]+N,data:{[g]:I,centerOffset:D-I-N,...L&&{alignmentOffset:N}},reset:L}}}),F=function(e){return void 0===e&&(e={}),{name:"inline",options:e,async fn(t){const{placement:i,elements:n,rects:s,platform:o,strategy:a}=t,{padding:c=2,x:u,y:h}=(0,r._3)(e,t),d=Array.from(await(null==o.getClientRects?void 0:o.getClientRects(n.reference))||[]),p=function(e){const t=e.slice().sort((e,t)=>e.y-t.y),i=[];let n=null;for(let e=0;e<t.length;e++){const r=t[e];!n||r.y-n.y>n.height/2?i.push([r]):i[i.length-1].push(r),n=r}return i.map(e=>(0,r.B1)(l(e)))}(d),g=(0,r.B1)(l(d)),f=(0,r.nI)(c),m=await o.getElementRects({reference:{getBoundingClientRect:function(){if(2===p.length&&p[0].left>p[1].right&&null!=u&&null!=h)return p.find(e=>u>e.left-f.left&&u<e.right+f.right&&h>e.top-f.top&&h<e.bottom+f.bottom)||g;if(p.length>=2){if("y"===(0,r.TV)(i)){const e=p[0],t=p[p.length-1],n="top"===(0,r.C0)(i),s=e.top,o=t.bottom,a=n?e.left:t.left,l=n?e.right:t.right;return{top:s,bottom:o,left:a,right:l,width:l-a,height:o-s,x:a,y:s}}const e="left"===(0,r.C0)(i),t=(0,r.T9)(...p.map(e=>e.right)),n=(0,r.jk)(...p.map(e=>e.left)),s=p.filter(i=>e?i.left===n:i.right===t),o=s[0].top,a=s[s.length-1].bottom;return{top:o,bottom:a,left:n,right:t,width:t-n,height:a-o,x:n,y:o}}return g}},floating:n.floating,strategy:a});return s.reference.x!==m.reference.x||s.reference.y!==m.reference.y||s.reference.width!==m.reference.width||s.reference.height!==m.reference.height?{reset:{rects:m}}:{}}}},k=function(e){return void 0===e&&(e={}),{options:e,fn(t){const{x:i,y:n,placement:s,rects:o,middlewareData:a}=t,{offset:l=0,mainAxis:u=!0,crossAxis:h=!0}=(0,r._3)(e,t),d={x:i,y:n},p=(0,r.TV)(s),g=(0,r.PG)(p);let f=d[g],m=d[p];const v=(0,r._3)(l,t),C="number"==typeof v?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(u){const e="y"===g?"height":"width",t=o.reference[g]-o.floating[e]+C.mainAxis,i=o.reference[g]+o.reference[e]-C.mainAxis;f<t?f=t:f>i&&(f=i)}if(h){var y,w;const e="y"===g?"width":"height",t=c.has((0,r.C0)(s)),i=o.reference[p]-o.floating[e]+(t&&(null==(y=a.offset)?void 0:y[p])||0)+(t?0:C.crossAxis),n=o.reference[p]+o.reference[e]+(t?0:(null==(w=a.offset)?void 0:w[p])||0)-(t?C.crossAxis:0);m<i?m=i:m>n&&(m=n)}return{[g]:f,[p]:m}}}},G=(e,t,i)=>{const r=new Map,o={platform:T,...i},a={...o.platform,_c:r};return(async(e,t,i)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:l}=i,c=l.detectOverflow?l:{...l,detectOverflow:s},u=await(null==l.isRTL?void 0:l.isRTL(t));let h=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:d,y:p}=n(h,r,u),g=r,f=0;const m={};for(let i=0;i<a.length;i++){const s=a[i];if(!s)continue;const{name:v,fn:C}=s,{x:y,y:w,data:S,reset:b}=await C({x:d,y:p,initialPlacement:r,placement:g,strategy:o,middlewareData:m,rects:h,platform:c,elements:{reference:e,floating:t}});d=null!=y?y:d,p=null!=w?w:p,m[v]={...m[v],...S},b&&f<50&&(f++,"object"==typeof b&&(b.placement&&(g=b.placement),b.rects&&(h=!0===b.rects?await l.getElementRects({reference:e,floating:t,strategy:o}):b.rects),({x:d,y:p}=n(h,g,u))),i=-1)}return{x:d,y:p,placement:g,strategy:o,middlewareData:m}})(e,t,{...o,platform:a})}},32125(e,t,i){"use strict";function r(){return"undefined"!=typeof window}function n(e){return a(e)?(e.nodeName||"").toLowerCase():"#document"}function s(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function o(e){var t;return null==(t=(a(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function a(e){return!!r()&&(e instanceof Node||e instanceof s(e).Node)}function l(e){return!!r()&&(e instanceof Element||e instanceof s(e).Element)}function c(e){return!!r()&&(e instanceof HTMLElement||e instanceof s(e).HTMLElement)}function u(e){return!(!r()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof s(e).ShadowRoot)}function h(e){const{overflow:t,overflowX:i,overflowY:r,display:n}=b(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+i)&&"inline"!==n&&"contents"!==n}function d(e){return/^(table|td|th)$/.test(n(e))}function p(e){try{if(e.matches(":popover-open"))return!0}catch(e){}try{return e.matches(":modal")}catch(e){return!1}}i.d(t,{$4:()=>A,CP:()=>E,L9:()=>b,Ll:()=>a,Lv:()=>d,Ng:()=>u,Tc:()=>w,Tf:()=>p,ZU:()=>h,_m:()=>R,ep:()=>o,eu:()=>S,gJ:()=>y,mq:()=>n,sQ:()=>C,sb:()=>c,v9:()=>M,vq:()=>l,zk:()=>s});const g=/transform|translate|scale|rotate|perspective|filter/,f=/paint|layout|strict|content/,m=e=>!!e&&"none"!==e;let v;function C(e){const t=l(e)?b(e):e;return m(t.transform)||m(t.translate)||m(t.scale)||m(t.rotate)||m(t.perspective)||!w()&&(m(t.backdropFilter)||m(t.filter))||g.test(t.willChange||"")||f.test(t.contain||"")}function y(e){let t=A(e);for(;c(t)&&!S(t);){if(C(t))return t;if(p(t))return null;t=A(t)}return null}function w(){return null==v&&(v="undefined"!=typeof CSS&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),v}function S(e){return/^(html|body|#document)$/.test(n(e))}function b(e){return s(e).getComputedStyle(e)}function E(e){return l(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function A(e){if("html"===n(e))return e;const t=e.assignedSlot||e.parentNode||u(e)&&e.host||o(e);return u(t)?t.host:t}function T(e){const t=A(e);return S(t)?e.ownerDocument?e.ownerDocument.body:e.body:c(t)&&h(t)?t:T(t)}function M(e,t,i){var r;void 0===t&&(t=[]),void 0===i&&(i=!0);const n=T(e),o=n===(null==(r=e.ownerDocument)?void 0:r.body),a=s(n);if(o){const e=R(a);return t.concat(a,a.visualViewport||[],h(n)?n:[],e&&i?M(e):[])}return t.concat(n,M(n,[],i))}function R(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}},51771(e,t,i){"use strict";i.d(t,{B1:()=>x,C0:()=>g,DD:()=>s,Dz:()=>y,Jx:()=>u,LI:()=>l,PG:()=>m,RI:()=>c,Sg:()=>f,T9:()=>a,TV:()=>C,WJ:()=>S,_3:()=>p,aD:()=>b,bV:()=>_,jk:()=>o,lP:()=>R,nI:()=>P,qE:()=>d,r_:()=>r,sq:()=>v,w7:()=>w});const r=["top","right","bottom","left"],n=["start","end"],s=r.reduce((e,t)=>e.concat(t,t+"-"+n[0],t+"-"+n[1]),[]),o=Math.min,a=Math.max,l=Math.round,c=Math.floor,u=e=>({x:e,y:e}),h={left:"right",right:"left",bottom:"top",top:"bottom"};function d(e,t,i){return a(e,o(t,i))}function p(e,t){return"function"==typeof e?e(t):e}function g(e){return e.split("-")[0]}function f(e){return e.split("-")[1]}function m(e){return"x"===e?"y":"x"}function v(e){return"y"===e?"height":"width"}function C(e){const t=e[0];return"t"===t||"b"===t?"y":"x"}function y(e){return m(C(e))}function w(e,t,i){void 0===i&&(i=!1);const r=f(e),n=y(e),s=v(n);let o="x"===n?r===(i?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[s]>t.floating[s]&&(o=_(o)),[o,_(o)]}function S(e){const t=_(e);return[b(e),t,b(t)]}function b(e){return e.includes("start")?e.replace("start","end"):e.replace("end","start")}const E=["left","right"],A=["right","left"],T=["top","bottom"],M=["bottom","top"];function R(e,t,i,r){const n=f(e);let s=function(e,t,i){switch(e){case"top":case"bottom":return i?t?A:E:t?E:A;case"left":case"right":return t?T:M;default:return[]}}(g(e),"start"===i,r);return n&&(s=s.map(e=>e+"-"+n),t&&(s=s.concat(s.map(b)))),s}function _(e){const t=g(e);return h[t]+e.slice(t.length)}function P(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function x(e){const{x:t,y:i,width:r,height:n}=e;return{width:r,height:n,top:i,left:t,right:t+r,bottom:i+n,x:t,y:i}}},54989(e,t,i){"use strict";i.d(t,{$1h:()=>xl,$Y_:()=>Ja,BFs:()=>gl,B_v:()=>Ha,CJG:()=>va,CS5:()=>nu,CSq:()=>Ra,Cf3:()=>Bu,CvR:()=>mn,D45:()=>Ee,DDm:()=>Yr,DKR:()=>Nn,Dvw:()=>ku,E1g:()=>zu,E3M:()=>Su,EJF:()=>zl,FiP:()=>No,G21:()=>_n,GPp:()=>Ts,GsR:()=>lu,HDb:()=>_t,HHt:()=>Fn,HLc:()=>Xc,HM$:()=>Zc,H_$:()=>js,HiW:()=>il,HvL:()=>Mh,Hyp:()=>Qa,IGk:()=>Zo,IqQ:()=>Ia,Iu8:()=>Fs,J1w:()=>Hh,JPk:()=>ht,JWk:()=>On,Ju4:()=>Hn,K02:()=>Tt,K42:()=>Dt,K4S:()=>$c,Kb3:()=>ll,LFT:()=>Wa,LIk:()=>ta,LT8:()=>cc,LfH:()=>Tl,Lhl:()=>sl,M4G:()=>dn,MDK:()=>aa,MSA:()=>Fo,MVO:()=>ms,NF5:()=>Eh,Nat:()=>Fu,OH$:()=>jc,OPU:()=>hl,OQA:()=>Un,OQU:()=>dc,OnL:()=>ia,PC7:()=>ha,PIB:()=>Sn,PJL:()=>Kn,PLc:()=>xc,Pk_:()=>ec,Pmj:()=>wl,Q5x:()=>Ln,Q90:()=>eh,QBm:()=>yl,Qgm:()=>Dl,R4L:()=>Ba,RI_:()=>cn,RRV:()=>Hl,RYS:()=>jl,Rdv:()=>Na,Rlq:()=>Da,Ry8:()=>fl,SEh:()=>un,Sko:()=>ch,SpC:()=>is,T6X:()=>Rh,TJD:()=>Ns,TOO:()=>Bl,TUE:()=>Ls,TYQ:()=>Tc,TaT:()=>$n,U$F:()=>cs,U3q:()=>pl,USV:()=>fe,U_L:()=>gs,Udn:()=>bl,Ug$:()=>Hu,Unm:()=>zn,VPZ:()=>Se,Vf_:()=>pe,VyI:()=>Dc,WO_:()=>Gs,XQb:()=>rt,Xx1:()=>he,Y0b:()=>uo,YD7:()=>Zl,YEH:()=>xs,YHi:()=>Vc,YtK:()=>Ya,Yx9:()=>ct,YzF:()=>bh,ZvW:()=>Xn,_:()=>ln,_7R:()=>Ah,a1W:()=>_,a8A:()=>Fl,aBp:()=>Ac,aJZ:()=>El,aP4:()=>Ol,aS7:()=>Dh,aq:()=>Io,atK:()=>Go,auO:()=>Ua,bB5:()=>vc,bBw:()=>_c,bLJ:()=>Ul,c4$:()=>Oc,dR4:()=>ce,dcM:()=>io,dsm:()=>ue,eAL:()=>Ms,ehA:()=>Ga,fAn:()=>zo,fK3:()=>oe,fNJ:()=>uc,fNO:()=>Sc,fRK:()=>ul,fVA:()=>La,fnn:()=>Uu,gay:()=>Yo,gvq:()=>Ru,hK9:()=>Rl,hv8:()=>pn,i9O:()=>nc,iEP:()=>Vl,iH9:()=>bu,ia$:()=>Ho,ihO:()=>Us,j19:()=>co,jf3:()=>Rc,jfj:()=>jo,k$d:()=>kl,k4Y:()=>Pc,k7d:()=>Ll,kNx:()=>Lt,kOq:()=>Ds,kem:()=>Ml,lon:()=>Ta,m20:()=>ea,m5s:()=>Oo,mE1:()=>au,mSN:()=>fn,mqe:()=>Os,n76:()=>Ph,o7C:()=>ae,oY$:()=>hn,o_p:()=>Oa,obS:()=>se,ock:()=>at,ofN:()=>no,pA9:()=>Sl,pE7:()=>Cs,pK6:()=>_h,pNP:()=>Ql,pkb:()=>Pl,pow:()=>Ec,qRA:()=>ks,qdQ:()=>Lc,qh$:()=>Wo,qkt:()=>sc,qyQ:()=>Dn,rdE:()=>qo,s1r:()=>Ic,sVA:()=>lt,stt:()=>ts,syG:()=>ne,tbO:()=>nt,tj3:()=>lo,tyx:()=>oo,uAl:()=>yn,uf_:()=>ut,uij:()=>el,utH:()=>ho,uvO:()=>Ma,v26:()=>yc,vBt:()=>ml,vXh:()=>Wl,wX9:()=>ga,wjn:()=>Yl,xA9:()=>Gu,xMA:()=>Lo,xSC:()=>Nc,yGC:()=>Es,yLQ:()=>os,yLT:()=>wn,yOL:()=>Nt,yah:()=>le,ycK:()=>Kl,yuY:()=>ac,zCV:()=>Cl,zIT:()=>Ps,zOQ:()=>_l,zmE:()=>ka,zsj:()=>ie});var r=Object.defineProperty,n=Object.defineProperties,s=Object.getOwnPropertyDescriptor,o=Object.getOwnPropertyDescriptors,a=Object.getOwnPropertySymbols,l=Object.prototype.hasOwnProperty,c=Object.prototype.propertyIsEnumerable,u=(e,t,i)=>t in e?r(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,h=(e,t)=>{for(var i in t||(t={}))l.call(t,i)&&u(e,i,t[i]);if(a)for(var i of a(t))c.call(t,i)&&u(e,i,t[i]);return e},d=(e,t)=>n(e,o(t)),p=(e,t)=>{for(var i in t)r(e,i,{get:t[i],enumerable:!0})},g=(e,t,i,n)=>{for(var o,a=n>1?void 0:n?s(t,i):t,l=e.length-1;l>=0;l--)(o=e[l])&&(a=(n?o(t,i,a):o(a))||a);return n&&a&&r(t,i,a),a},f=(e,t)=>(i,r)=>t(i,r,e),m={};function v(e){return null==e||""===e?null:e}function C(e,t=!1){return null!=e&&(""!==e||t)}function y(e){return!C(e)}function w(e){return null==e||0===e.length}function S(e){return null!=e&&"function"==typeof e.toString?e.toString():null}function b(e){if(void 0===e)return;if(null===e||""===e)return null;if("number"==typeof e)return isNaN(e)?void 0:e;const t=parseInt(e,10);return isNaN(t)?void 0:t}function E(e){if(void 0!==e)return null!==e&&""!==e&&("boolean"==typeof e?e:/true/i.test(e))}function A(e){if(null!=e&&""!==e)return e}function T(e,t){return(e?JSON.stringify(e):null)===(t?JSON.stringify(t):null)}function M(e,t,i=!1){const r=null==e,n=null==t;if(e&&e.toNumber&&(e=e.toNumber()),t&&t.toNumber&&(t=t.toNumber()),r&&n)return 0;if(r)return-1;if(n)return 1;function s(e,t){return e>t?1:e<t?-1:0}if("string"!=typeof e)return s(e,t);if(!i)return s(e,t);try{return e.localeCompare(t)}catch(i){return s(e,t)}}function R(e){if(e instanceof Set||e instanceof Map){const t=[];return e.forEach(e=>t.push(e)),t}return Object.values(e)}p(m,{attrToBoolean:()=>E,attrToNumber:()=>b,attrToString:()=>A,defaultComparator:()=>M,exists:()=>C,jsonEquals:()=>T,makeNull:()=>v,missing:()=>y,missingOrEmpty:()=>w,toStringOrNull:()=>S,values:()=>R});var _=class{constructor(){this.existingKeys={}}addExistingKeys(e){for(let t=0;t<e.length;t++)this.existingKeys[e[t]]=!0}getUniqueKey(e,t){e=S(e);let i=0;for(;;){let r;if(e?(r=e,0!==i&&(r+="_"+i)):t?(r=t,0!==i&&(r+="_"+i)):r=i,!this.existingKeys[r])return this.existingKeys[r]=!0,String(r);i++}}},P={};p(P,{SKIP_JS_BUILTINS:()=>x,cloneObject:()=>I,deepCloneDefinition:()=>L,getAllValuesInObject:()=>N,getValueUsingField:()=>F,isNonNullObject:()=>G,iterateObject:()=>D,mergeDeep:()=>O,removeAllReferences:()=>k});var x=new Set(["__proto__","constructor","prototype"]);function D(e,t){if(null!=e)if(Array.isArray(e))for(let i=0;i<e.length;i++)t(i.toString(),e[i]);else for(const[i,r]of Object.entries(e))t(i,r)}function I(e){const t={},i=Object.keys(e);for(let r=0;r<i.length;r++){if(x.has(i[r]))continue;const n=i[r],s=e[n];t[n]=s}return t}function L(e,t){if(!e)return;const i=e,r={};return Object.keys(i).forEach(e=>{if(t&&t.indexOf(e)>=0||x.has(e))return;const n=i[e],s=G(n)&&n.constructor===Object;r[e]=s?L(n):n}),r}function N(e){if(!e)return[];const t=Object;if("function"==typeof t.values)return t.values(e);const i=[];for(const t in e)e.hasOwnProperty(t)&&e.propertyIsEnumerable(t)&&i.push(e[t]);return i}function O(e,t,i=!0,r=!1){C(t)&&D(t,(t,n)=>{if(x.has(t))return;let s=e[t];s!==n&&(r&&null==s&&null!=n&&"object"==typeof n&&n.constructor===Object&&(s={},e[t]=s),G(n)&&G(s)&&!Array.isArray(s)?O(s,n,i,r):(i||void 0!==n)&&(e[t]=n))})}function F(e,t,i){if(!t||!e)return;if(!i)return e[t];const r=t.split(".");let n=e;for(let e=0;e<r.length;e++){if(null==n)return;n=n[r[e]]}return n}function k(e,t=[],i){Object.keys(e).forEach(i=>{"object"!=typeof e[i]||t.includes(i)||(e[i]=void 0)});const r=Object.getPrototypeOf(e),n={};Object.getOwnPropertyNames(r).forEach(e=>{if("function"==typeof r[e]&&!t.includes(e)){const t=()=>{console.warn((e=>`AG Grid: Grid API function ${e}() cannot be called as the grid has been destroyed.\n    It is recommended to remove local references to the grid api. Alternatively, check gridApi.isDestroyed() to avoid calling methods against a destroyed grid.\n    To run logic when the grid is about to be destroyed use the gridPreDestroy event. See: ${i}`)(e))};n[e]={value:t,writable:!0}}}),Object.defineProperties(e,n)}function G(e){return"object"==typeof e&&null!==e}var V={};p(V,{compose:()=>ee,debounce:()=>X,doOnce:()=>B,errorOnce:()=>U,executeAfter:()=>Q,executeInAWhile:()=>K,executeNextVMTurn:()=>Y,getFunctionName:()=>W,isFunction:()=>j,noop:()=>te,throttle:()=>Z,waitUntil:()=>J,warnOnce:()=>z});var H={};function B(e,t){H[t]||(e(),H[t]=!0)}function z(e){B(()=>console.warn("AG Grid: "+e),e)}function U(e){B(()=>console.error("AG Grid: "+e),e)}function W(e){if(e.name)return e.name;const t=/function\s+([^\(]+)/.exec(e.toString());return t&&2===t.length?t[1].trim():null}function j(e){return!!(e&&e.constructor&&e.call&&e.apply)}function K(e){Q(e,400)}var $=[],q=!1;function Y(e){$.push(e),q||(q=!0,window.setTimeout(()=>{const e=$.slice();$.length=0,q=!1,e.forEach(e=>e())},0))}function Q(e,t=0){e.length>0&&window.setTimeout(()=>e.forEach(e=>e()),t)}function X(e,t){let i;return function(...r){const n=this;window.clearTimeout(i),i=window.setTimeout(function(){e.apply(n,r)},t)}}function Z(e,t){let i=0;return function(...r){const n=(new Date).getTime();n-i<t||(i=n,e.apply(this,r))}}function J(e,t,i=100,r){const n=(new Date).getTime();let s=null,o=!1;const a=()=>{const a=(new Date).getTime()-n>i;(e()||a)&&(t(),o=!0,null!=s&&(window.clearInterval(s),s=null),a&&r&&console.warn(r))};a(),o||(s=window.setInterval(a,10))}function ee(...e){return t=>e.reduce((e,t)=>t(e),t)}var te=()=>{},ie=(e=>(e.CommunityCoreModule="@ag-grid-community/core",e.InfiniteRowModelModule="@ag-grid-community/infinite-row-model",e.ClientSideRowModelModule="@ag-grid-community/client-side-row-model",e.CsvExportModule="@ag-grid-community/csv-export",e.EnterpriseCoreModule="@ag-grid-enterprise/core",e.RowGroupingModule="@ag-grid-enterprise/row-grouping",e.ColumnsToolPanelModule="@ag-grid-enterprise/column-tool-panel",e.FiltersToolPanelModule="@ag-grid-enterprise/filter-tool-panel",e.MenuModule="@ag-grid-enterprise/menu",e.SetFilterModule="@ag-grid-enterprise/set-filter",e.MultiFilterModule="@ag-grid-enterprise/multi-filter",e.StatusBarModule="@ag-grid-enterprise/status-bar",e.SideBarModule="@ag-grid-enterprise/side-bar",e.RangeSelectionModule="@ag-grid-enterprise/range-selection",e.MasterDetailModule="@ag-grid-enterprise/master-detail",e.RichSelectModule="@ag-grid-enterprise/rich-select",e.GridChartsModule="@ag-grid-enterprise/charts",e.ViewportRowModelModule="@ag-grid-enterprise/viewport-row-model",e.ServerSideRowModelModule="@ag-grid-enterprise/server-side-row-model",e.ExcelExportModule="@ag-grid-enterprise/excel-export",e.ClipboardModule="@ag-grid-enterprise/clipboard",e.SparklinesModule="@ag-grid-enterprise/sparklines",e.AdvancedFilterModule="@ag-grid-enterprise/advanced-filter",e.AngularModule="@ag-grid-community/angular",e.ReactModule="@ag-grid-community/react",e.VueModule="@ag-grid-community/vue",e))(ie||{}),re=class e{static register(t){e.__register(t,!0,void 0)}static registerModules(t){e.__registerModules(t,!0,void 0)}static __register(t,i,r){e.runVersionChecks(t),void 0!==r?(e.areGridScopedModules=!0,void 0===e.gridModulesMap[r]&&(e.gridModulesMap[r]={}),e.gridModulesMap[r][t.moduleName]=t):e.globalModulesMap[t.moduleName]=t,e.setModuleBased(i)}static __unRegisterGridModules(t){delete e.gridModulesMap[t]}static __registerModules(t,i,r){e.setModuleBased(i),t&&t.forEach(t=>e.__register(t,i,r))}static isValidModuleVersion(t){const[i,r]=t.version.split(".")||[],[n,s]=e.currentModuleVersion.split(".")||[];return i===n&&r===s}static runVersionChecks(t){if(e.currentModuleVersion||(e.currentModuleVersion=t.version),t.version?e.isValidModuleVersion(t)||console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is version ${t.version} but the other modules are version ${this.currentModuleVersion}. Please update all modules to the same version.`):console.error(`AG Grid: You are using incompatible versions of AG Grid modules. Major and minor versions should always match across modules. '${t.moduleName}' is incompatible. Please update all modules to the same version.`),t.validate){const e=t.validate();if(!e.isValid){const t=e;console.error(`AG Grid: ${t.message}`)}}}static setModuleBased(t){void 0===e.moduleBased?e.moduleBased=t:e.moduleBased!==t&&B(()=>{console.warn("AG Grid: You are mixing modules (i.e. @ag-grid-community/core) and packages (ag-grid-community) - you can only use one or the other of these mechanisms."),console.warn("Please see https://www.ag-grid.com/javascript-grid/modules/ for more information.")},"ModulePackageCheck")}static __setIsBundled(){e.isBundled=!0}static __assertRegistered(t,i,r){var n;if(this.__isRegistered(t,r))return!0;const s=i+t;let o;if(e.isBundled)o=`AG Grid: unable to use ${i} as 'ag-grid-enterprise' has not been loaded. Check you are using the Enterprise bundle:\n        \n        <script src="https://cdn.jsdelivr.net/npm/ag-grid-enterprise@AG_GRID_VERSION/dist/ag-grid-enterprise.min.js"><\/script>\n        \nFor more info see: https://ag-grid.com/javascript-data-grid/getting-started/#getting-started-with-ag-grid-enterprise`;else if(e.moduleBased||void 0===e.moduleBased){let s=null==(n=Object.entries(ie).find(([e,i])=>i===t))?void 0:n[0];o=`AG Grid: unable to use ${i} as the ${s} is not registered${e.areGridScopedModules?` for gridId: ${r}`:""}. Check if you have registered the module:\n           \n    import { ModuleRegistry } from '@ag-grid-community/core';\n    import { ${s} } from '${t}';\n    \n    ModuleRegistry.registerModules([ ${s} ]);\n\nFor more info see: https://www.ag-grid.com/javascript-grid/modules/`}else o=`AG Grid: unable to use ${i} as package 'ag-grid-enterprise' has not been imported. Check that you have imported the package:\n            \n    import 'ag-grid-enterprise';`;return B(()=>{console.warn(o)},s),!1}static __isRegistered(t,i){var r;return!!e.globalModulesMap[t]||!!(null==(r=e.gridModulesMap[i])?void 0:r[t])}static __getRegisteredModules(t){return[...R(e.globalModulesMap),...R(e.gridModulesMap[t]||{})]}static __getGridRegisteredModules(t){var i;return R(null!=(i=e.gridModulesMap[t])?i:{})||[]}static __isPackageBased(){return!e.moduleBased}};re.globalModulesMap={},re.gridModulesMap={},re.areGridScopedModules=!1;var ne=re,se=class{constructor(e,t){if(this.beanWrappers={},this.destroyed=!1,!e||!e.beanClasses)return;this.contextParams=e,this.logger=t,this.logger.log(">> creating ag-Application Context"),this.createBeans();const i=this.getBeanInstances();this.wireBeans(i),this.logger.log(">> ag-Application Context ready - component is alive")}getBeanInstances(){return R(this.beanWrappers).map(e=>e.beanInstance)}createBean(e,t){if(!e)throw Error("Can't wire to bean since it is null");return this.wireBeans([e],t),e}wireBeans(e,t){this.autoWireBeans(e),this.methodWireBeans(e),this.callLifeCycleMethods(e,"preConstructMethods"),C(t)&&e.forEach(t),this.callLifeCycleMethods(e,"postConstructMethods")}createBeans(){this.contextParams.beanClasses.forEach(this.createBeanWrapper.bind(this)),D(this.beanWrappers,(e,t)=>{let i;t.bean.__agBeanMetaData&&t.bean.__agBeanMetaData.autowireMethods&&t.bean.__agBeanMetaData.autowireMethods.agConstructor&&(i=t.bean.__agBeanMetaData.autowireMethods.agConstructor);const r=this.getBeansForParameters(i,t.bean.name),n=new(t.bean.bind.apply(t.bean,[null,...r]));t.beanInstance=n});const e=Object.keys(this.beanWrappers).join(", ");this.logger.log(`created beans: ${e}`)}createBeanWrapper(e){const t=e.__agBeanMetaData;if(!t){let t;return t=e.prototype.constructor?W(e.prototype.constructor):""+e,void console.error(`Context item ${t} is not a bean`)}const i={bean:e,beanInstance:null,beanName:t.beanName};this.beanWrappers[t.beanName]=i}autoWireBeans(e){e.forEach(e=>{this.forEachMetaDataInHierarchy(e,(t,i)=>{const r=t.agClassAttributes;r&&r.forEach(t=>{const r=this.lookupBeanInstance(i,t.beanName,t.optional);e[t.attributeName]=r})})})}methodWireBeans(e){e.forEach(e=>{this.forEachMetaDataInHierarchy(e,(t,i)=>{D(t.autowireMethods,(t,r)=>{if("agConstructor"===t)return;const n=this.getBeansForParameters(r,i);e[t].apply(e,n)})})})}forEachMetaDataInHierarchy(e,t){let i=Object.getPrototypeOf(e);for(;null!=i;){const e=i.constructor;e.hasOwnProperty("__agBeanMetaData")&&t(e.__agBeanMetaData,this.getBeanName(e)),i=Object.getPrototypeOf(i)}}getBeanName(e){if(e.__agBeanMetaData&&e.__agBeanMetaData.beanName)return e.__agBeanMetaData.beanName;const t=e.toString();return t.substring(9,t.indexOf("("))}getBeansForParameters(e,t){const i=[];return e&&D(e,(e,r)=>{const n=this.lookupBeanInstance(t,r);i[Number(e)]=n}),i}lookupBeanInstance(e,t,i=!1){if(this.destroyed)return this.logger.log(`AG Grid: bean reference ${t} is used after the grid is destroyed!`),null;if("context"===t)return this;if(this.contextParams.providedBeanInstances&&this.contextParams.providedBeanInstances.hasOwnProperty(t))return this.contextParams.providedBeanInstances[t];const r=this.beanWrappers[t];return r?r.beanInstance:(i||console.error(`AG Grid: unable to find bean reference ${t} while initialising ${e}`),null)}callLifeCycleMethods(e,t){e.forEach(e=>this.callLifeCycleMethodsOnBean(e,t))}callLifeCycleMethodsOnBean(e,t,i){const r={};this.forEachMetaDataInHierarchy(e,e=>{const n=e[t];n&&n.forEach(e=>{e!=i&&(r[e]=!0)})}),Object.keys(r).forEach(t=>e[t]())}getBean(e){return this.lookupBeanInstance("getBean",e,!0)}destroy(){if(this.destroyed)return;this.destroyed=!0,this.logger.log(">> Shutting down ag-Application Context");const e=this.getBeanInstances();this.destroyBeans(e),this.contextParams.providedBeanInstances=null,ne.__unRegisterGridModules(this.contextParams.gridId),this.logger.log(">> ag-Application Context shut down - component is dead")}destroyBean(e){e&&this.destroyBeans([e])}destroyBeans(e){return e?(e.forEach(e=>{this.callLifeCycleMethodsOnBean(e,"preDestroyMethods","destroy");const t=e;"function"==typeof t.destroy&&t.destroy()}),[]):[]}isDestroyed(){return this.destroyed}getGridId(){return this.contextParams.gridId}};function oe(e,t,i){const r=ge(e.constructor);r.preConstructMethods||(r.preConstructMethods=[]),r.preConstructMethods.push(t)}function ae(e,t,i){const r=ge(e.constructor);r.postConstructMethods||(r.postConstructMethods=[]),r.postConstructMethods.push(t)}function le(e,t,i){const r=ge(e.constructor);r.preDestroyMethods||(r.preDestroyMethods=[]),r.preDestroyMethods.push(t)}function ce(e){return t=>{ge(t).beanName=e}}function ue(e){return(t,i,r)=>{de(t,e,!1,0,i,null)}}function he(e){return(t,i,r)=>{de(t,e,!0,0,i,null)}}function de(e,t,i,r,n,s){if(null===t)return void console.error("AG Grid: Autowired name should not be null");if("number"==typeof s)return void console.error("AG Grid: Autowired should be on an attribute");const o=ge(e.constructor);o.agClassAttributes||(o.agClassAttributes=[]),o.agClassAttributes.push({attributeName:n,beanName:t,optional:i})}function pe(e){return(t,i,r)=>{const n="function"==typeof t?t:t.constructor;let s;if("number"==typeof r){let t;i?(s=ge(n),t=i):(s=ge(n),t="agConstructor"),s.autowireMethods||(s.autowireMethods={}),s.autowireMethods[t]||(s.autowireMethods[t]={}),s.autowireMethods[t][r]=e}}}function ge(e){return e.hasOwnProperty("__agBeanMetaData")||(e.__agBeanMetaData={}),e.__agBeanMetaData}var fe=class{constructor(){this.allSyncListeners=new Map,this.allAsyncListeners=new Map,this.globalSyncListeners=new Set,this.globalAsyncListeners=new Set,this.asyncFunctionsQueue=[],this.scheduled=!1,this.firedEvents={}}setBeans(e,t,i=null,r=null){if(this.frameworkOverrides=t,this.gos=e,i){const t=e.useAsyncEvents();this.addGlobalListener(i,t)}r&&this.addGlobalListener(r,!1)}setFrameworkOverrides(e){this.frameworkOverrides=e}getListeners(e,t,i){const r=t?this.allAsyncListeners:this.allSyncListeners;let n=r.get(e);return!n&&i&&(n=new Set,r.set(e,n)),n}noRegisteredListenersExist(){return 0===this.allSyncListeners.size&&0===this.allAsyncListeners.size&&0===this.globalSyncListeners.size&&0===this.globalAsyncListeners.size}addEventListener(e,t,i=!1){this.getListeners(e,i,!0).add(t)}removeEventListener(e,t,i=!1){const r=this.getListeners(e,i,!1);r&&(r.delete(t),0===r.size)&&(i?this.allAsyncListeners:this.allSyncListeners).delete(e)}addGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).add(e)}removeGlobalListener(e,t=!1){(t?this.globalAsyncListeners:this.globalSyncListeners).delete(e)}dispatchEvent(e){let t=e;this.gos&&this.gos.addGridCommonParams(t),this.dispatchToListeners(t,!0),this.dispatchToListeners(t,!1),this.firedEvents[t.type]=!0}dispatchEventOnce(e){this.firedEvents[e.type]||this.dispatchEvent(e)}dispatchToListeners(e,t){var i;const r=e.type;if(t&&"event"in e){const t=e.event;t instanceof Event&&(e.eventPath=t.composedPath())}const n=null!=(i=this.getListeners(r,t,!1))?i:new Set,s=new Set(n);s.size>0&&((i,r)=>{i.forEach(i=>{if(!r.has(i))return;const n=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>i(e)):()=>i(e);t?this.dispatchAsync(n):n()})})(s,n),new Set(t?this.globalAsyncListeners:this.globalSyncListeners).forEach(i=>{const n=this.frameworkOverrides?()=>this.frameworkOverrides.wrapIncoming(()=>i(r,e)):()=>i(r,e);t?this.dispatchAsync(n):n()})}dispatchAsync(e){this.asyncFunctionsQueue.push(e),this.scheduled||(this.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(this.flushAsyncQueue.bind(this),0)}),this.scheduled=!0)}flushAsyncQueue(){this.scheduled=!1;const e=this.asyncFunctionsQueue.slice();this.asyncFunctionsQueue=[],e.forEach(e=>e())}};g([f(0,pe("gridOptionsService")),f(1,pe("frameworkOverrides")),f(2,pe("globalEventListener")),f(3,pe("globalSyncEventListener"))],fe.prototype,"setBeans",1),fe=g([ce("eventService")],fe);var me=class{constructor(e){this.frameworkOverrides=e,this.wrappedListeners=new Map,this.wrappedGlobalListeners=new Map}wrap(e){let t=e;return this.frameworkOverrides.shouldWrapOutgoing&&(t=t=>{this.frameworkOverrides.wrapOutgoing(()=>e(t))},this.wrappedListeners.set(e,t)),t}wrapGlobal(e){let t=e;return this.frameworkOverrides.shouldWrapOutgoing&&(t=(t,i)=>{this.frameworkOverrides.wrapOutgoing(()=>e(t,i))},this.wrappedGlobalListeners.set(e,t)),t}unwrap(e){var t;return null!=(t=this.wrappedListeners.get(e))?t:e}unwrapGlobal(e){var t;return null!=(t=this.wrappedGlobalListeners.get(e))?t:e}},ve={resizable:!0,sortable:!0},Ce=0;function ye(){return Ce++}var we=class e{constructor(e,t,i,r){this.instanceId=ye(),this.autoHeaderHeight=null,this.moving=!1,this.menuVisible=!1,this.lastLeftPinned=!1,this.firstRightPinned=!1,this.filterActive=!1,this.eventService=new fe,this.tooltipEnabled=!1,this.rowGroupActive=!1,this.pivotActive=!1,this.aggregationActive=!1,this.colDef=e,this.userProvidedColDef=t,this.colId=i,this.primary=r,this.setState(e)}getInstanceId(){return this.instanceId}setState(e){void 0!==e.sort?"asc"!==e.sort&&"desc"!==e.sort||(this.sort=e.sort):"asc"!==e.initialSort&&"desc"!==e.initialSort||(this.sort=e.initialSort);const t=e.sortIndex,i=e.initialSortIndex;void 0!==t?null!==t&&(this.sortIndex=t):null!==i&&(this.sortIndex=i);const r=e.hide,n=e.initialHide;this.visible=void 0!==r?!r:!n,void 0!==e.pinned?this.setPinned(e.pinned):this.setPinned(e.initialPinned);const s=e.flex,o=e.initialFlex;void 0!==s?this.flex=s:void 0!==o&&(this.flex=o)}setColDef(e,t,i){this.colDef=e,this.userProvidedColDef=t,this.initMinAndMaxWidths(),this.initDotNotation(),this.initTooltip(),this.eventService.dispatchEvent(this.createColumnEvent("colDefChanged",i))}getUserProvidedColDef(){return this.userProvidedColDef}setParent(e){this.parent=e}getParent(){return this.parent}setOriginalParent(e){this.originalParent=e}getOriginalParent(){return this.originalParent}initialise(){this.initMinAndMaxWidths(),this.resetActualWidth("gridInitializing"),this.initDotNotation(),this.initTooltip()}initDotNotation(){const e=this.gos.get("suppressFieldDotNotation");this.fieldContainsDots=C(this.colDef.field)&&this.colDef.field.indexOf(".")>=0&&!e,this.tooltipFieldContainsDots=C(this.colDef.tooltipField)&&this.colDef.tooltipField.indexOf(".")>=0&&!e}initMinAndMaxWidths(){var e,t;const i=this.colDef;this.minWidth=null!=(e=i.minWidth)?e:this.environment.getMinColWidth(),this.maxWidth=null!=(t=i.maxWidth)?t:Number.MAX_SAFE_INTEGER}initTooltip(){this.tooltipEnabled=C(this.colDef.tooltipField)||C(this.colDef.tooltipValueGetter)||C(this.colDef.tooltipComponent)}resetActualWidth(e){const t=this.calculateColInitialWidth(this.colDef);this.setActualWidth(t,e,!0)}calculateColInitialWidth(e){var t,i;const r=null!=(t=e.minWidth)?t:this.environment.getMinColWidth(),n=null!=(i=e.maxWidth)?i:Number.MAX_SAFE_INTEGER;let s;const o=b(e.width),a=b(e.initialWidth);return s=null!=o?o:null!=a?a:200,Math.max(Math.min(s,n),r)}isEmptyGroup(){return!1}isRowGroupDisplayed(e){if(y(this.colDef)||y(this.colDef.showRowGroup))return!1;const t=!0===this.colDef.showRowGroup,i=this.colDef.showRowGroup===e;return t||i}isPrimary(){return this.primary}isFilterAllowed(){return!!this.colDef.filter}isFieldContainsDots(){return this.fieldContainsDots}isTooltipEnabled(){return this.tooltipEnabled}isTooltipFieldContainsDots(){return this.tooltipFieldContainsDots}addEventListener(e,t){var i,r;this.frameworkOverrides.shouldWrapOutgoing&&!this.frameworkEventListenerService&&(this.eventService.setFrameworkOverrides(this.frameworkOverrides),this.frameworkEventListenerService=new me(this.frameworkOverrides));const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.wrap(t))?r:t;this.eventService.addEventListener(e,n)}removeEventListener(e,t){var i,r;const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.unwrap(t))?r:t;this.eventService.removeEventListener(e,n)}createColumnFunctionCallbackParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,column:this,colDef:this.colDef})}isSuppressNavigable(e){if("boolean"==typeof this.colDef.suppressNavigable)return this.colDef.suppressNavigable;if("function"==typeof this.colDef.suppressNavigable){const t=this.createColumnFunctionCallbackParams(e);return(0,this.colDef.suppressNavigable)(t)}return!1}isCellEditable(e){return!(e.group&&!this.gos.get("enableGroupEdit"))&&this.isColumnFunc(e,this.colDef.editable)}isSuppressFillHandle(){return!!this.colDef.suppressFillHandle}isAutoHeight(){return!!this.colDef.autoHeight}isAutoHeaderHeight(){return!!this.colDef.autoHeaderHeight}isRowDrag(e){return this.isColumnFunc(e,this.colDef.rowDrag)}isDndSource(e){return this.isColumnFunc(e,this.colDef.dndSource)}isCellCheckboxSelection(e){return this.isColumnFunc(e,this.colDef.checkboxSelection)}isSuppressPaste(e){return this.isColumnFunc(e,this.colDef?this.colDef.suppressPaste:null)}isResizable(){return!!this.getColDefValue("resizable")}getColDefValue(e){var t;return null!=(t=this.colDef[e])?t:ve[e]}isColumnFunc(e,t){return"boolean"==typeof t?t:"function"==typeof t&&t(this.createColumnFunctionCallbackParams(e))}setMoving(e,t){this.moving=e,this.eventService.dispatchEvent(this.createColumnEvent("movingChanged",t))}createColumnEvent(e,t){return this.gos.addGridCommonParams({type:e,column:this,columns:[this],source:t})}isMoving(){return this.moving}getSort(){return this.sort}setSort(e,t){this.sort!==e&&(this.sort=e,this.eventService.dispatchEvent(this.createColumnEvent("sortChanged",t))),this.dispatchStateUpdatedEvent("sort")}setMenuVisible(e,t){this.menuVisible!==e&&(this.menuVisible=e,this.eventService.dispatchEvent(this.createColumnEvent("menuVisibleChanged",t)))}isMenuVisible(){return this.menuVisible}isSortable(){return!!this.getColDefValue("sortable")}isSortAscending(){return"asc"===this.sort}isSortDescending(){return"desc"===this.sort}isSortNone(){return y(this.sort)}isSorting(){return C(this.sort)}getSortIndex(){return this.sortIndex}setSortIndex(e){this.sortIndex=e,this.dispatchStateUpdatedEvent("sortIndex")}setAggFunc(e){this.aggFunc=e,this.dispatchStateUpdatedEvent("aggFunc")}getAggFunc(){return this.aggFunc}getLeft(){return this.left}getOldLeft(){return this.oldLeft}getRight(){return this.left+this.actualWidth}setLeft(e,t){this.oldLeft=this.left,this.left!==e&&(this.left=e,this.eventService.dispatchEvent(this.createColumnEvent("leftChanged",t)))}isFilterActive(){return this.filterActive}setFilterActive(e,t,i){this.filterActive!==e&&(this.filterActive=e,this.eventService.dispatchEvent(this.createColumnEvent("filterActiveChanged",t)));const r=this.createColumnEvent("filterChanged",t);i&&O(r,i),this.eventService.dispatchEvent(r)}isHovered(){return this.columnHoverService.isHovered(this)}setPinned(e){this.pinned=!0===e||"left"===e?"left":"right"===e?"right":null,this.dispatchStateUpdatedEvent("pinned")}setFirstRightPinned(e,t){this.firstRightPinned!==e&&(this.firstRightPinned=e,this.eventService.dispatchEvent(this.createColumnEvent("firstRightPinnedChanged",t)))}setLastLeftPinned(e,t){this.lastLeftPinned!==e&&(this.lastLeftPinned=e,this.eventService.dispatchEvent(this.createColumnEvent("lastLeftPinnedChanged",t)))}isFirstRightPinned(){return this.firstRightPinned}isLastLeftPinned(){return this.lastLeftPinned}isPinned(){return"left"===this.pinned||"right"===this.pinned}isPinnedLeft(){return"left"===this.pinned}isPinnedRight(){return"right"===this.pinned}getPinned(){return this.pinned}setVisible(e,t){const i=!0===e;this.visible!==i&&(this.visible=i,this.eventService.dispatchEvent(this.createColumnEvent("visibleChanged",t))),this.dispatchStateUpdatedEvent("hide")}isVisible(){return this.visible}isSpanHeaderHeight(){const e=this.getColDef();return!e.suppressSpanHeaderHeight&&!e.autoHeaderHeight}getColumnGroupPaddingInfo(){let e=this.getParent();if(!e||!e.isPadding())return{numberOfParents:0,isSpanningTotal:!1};const t=e.getPaddingLevel()+1;let i=!0;for(;e;){if(!e.isPadding()){i=!1;break}e=e.getParent()}return{numberOfParents:t,isSpanningTotal:i}}getColDef(){return this.colDef}getColumnGroupShow(){return this.colDef.columnGroupShow}getColId(){return this.colId}getId(){return this.colId}getUniqueId(){return this.colId}getDefinition(){return this.colDef}getActualWidth(){return this.actualWidth}getAutoHeaderHeight(){return this.autoHeaderHeight}setAutoHeaderHeight(e){const t=e!==this.autoHeaderHeight;return this.autoHeaderHeight=e,t}createBaseColDefParams(e){return this.gos.addGridCommonParams({node:e,data:e.data,colDef:this.colDef,column:this})}getColSpan(e){if(y(this.colDef.colSpan))return 1;const t=this.createBaseColDefParams(e),i=this.colDef.colSpan(t);return Math.max(i,1)}getRowSpan(e){if(y(this.colDef.rowSpan))return 1;const t=this.createBaseColDefParams(e),i=this.colDef.rowSpan(t);return Math.max(i,1)}setActualWidth(e,t,i=!1){null!=this.minWidth&&(e=Math.max(e,this.minWidth)),null!=this.maxWidth&&(e=Math.min(e,this.maxWidth)),this.actualWidth!==e&&(this.actualWidth=e,this.flex&&"flex"!==t&&"gridInitializing"!==t&&(this.flex=null),i||this.fireColumnWidthChangedEvent(t)),this.dispatchStateUpdatedEvent("width")}fireColumnWidthChangedEvent(e){this.eventService.dispatchEvent(this.createColumnEvent("widthChanged",e))}isGreaterThanMax(e){return null!=this.maxWidth&&e>this.maxWidth}getMinWidth(){return this.minWidth}getMaxWidth(){return this.maxWidth}getFlex(){return this.flex||0}setFlex(e){this.flex!==e&&(this.flex=e),this.dispatchStateUpdatedEvent("flex")}setMinimum(e){C(this.minWidth)&&this.setActualWidth(this.minWidth,e)}setRowGroupActive(e,t){this.rowGroupActive!==e&&(this.rowGroupActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnRowGroupChanged",t))),this.dispatchStateUpdatedEvent("rowGroup")}isRowGroupActive(){return this.rowGroupActive}setPivotActive(e,t){this.pivotActive!==e&&(this.pivotActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnPivotChanged",t))),this.dispatchStateUpdatedEvent("pivot")}isPivotActive(){return this.pivotActive}isAnyFunctionActive(){return this.isPivotActive()||this.isRowGroupActive()||this.isValueActive()}isAnyFunctionAllowed(){return this.isAllowPivot()||this.isAllowRowGroup()||this.isAllowValue()}setValueActive(e,t){this.aggregationActive!==e&&(this.aggregationActive=e,this.eventService.dispatchEvent(this.createColumnEvent("columnValueChanged",t)))}isValueActive(){return this.aggregationActive}isAllowPivot(){return!0===this.colDef.enablePivot}isAllowValue(){return!0===this.colDef.enableValue}isAllowRowGroup(){return!0===this.colDef.enableRowGroup}getMenuTabs(e){z("As of v31.1, 'getMenuTabs' is deprecated. Use 'getColDef().menuTabs ?? defaultValues' instead.");let t=this.getColDef().menuTabs;return null==t&&(t=e),t}dispatchStateUpdatedEvent(t){this.eventService.dispatchEvent({type:e.EVENT_STATE_UPDATED,key:t})}};we.EVENT_MOVING_CHANGED="movingChanged",we.EVENT_LEFT_CHANGED="leftChanged",we.EVENT_WIDTH_CHANGED="widthChanged",we.EVENT_LAST_LEFT_PINNED_CHANGED="lastLeftPinnedChanged",we.EVENT_FIRST_RIGHT_PINNED_CHANGED="firstRightPinnedChanged",we.EVENT_VISIBLE_CHANGED="visibleChanged",we.EVENT_FILTER_CHANGED="filterChanged",we.EVENT_FILTER_ACTIVE_CHANGED="filterActiveChanged",we.EVENT_SORT_CHANGED="sortChanged",we.EVENT_COL_DEF_CHANGED="colDefChanged",we.EVENT_MENU_VISIBLE_CHANGED="menuVisibleChanged",we.EVENT_ROW_GROUP_CHANGED="columnRowGroupChanged",we.EVENT_PIVOT_CHANGED="columnPivotChanged",we.EVENT_VALUE_CHANGED="columnValueChanged",we.EVENT_STATE_UPDATED="columnStateUpdated",g([ue("gridOptionsService")],we.prototype,"gos",2),g([ue("environment")],we.prototype,"environment",2),g([ue("columnHoverService")],we.prototype,"columnHoverService",2),g([ue("frameworkOverrides")],we.prototype,"frameworkOverrides",2),g([ae],we.prototype,"initialise",1);var Se=we,be=class e{constructor(e,t,i,r){this.localEventService=new fe,this.expandable=!1,this.instanceId=ye(),this.expandableListenerRemoveCallback=null,this.colGroupDef=e,this.groupId=t,this.expanded=!!e&&!!e.openByDefault,this.padding=i,this.level=r}destroy(){this.expandableListenerRemoveCallback&&this.reset(null,void 0)}reset(e,t){this.colGroupDef=e,this.level=t,this.originalParent=null,this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback(),this.children=void 0,this.expandable=void 0}getInstanceId(){return this.instanceId}setOriginalParent(e){this.originalParent=e}getOriginalParent(){return this.originalParent}getLevel(){return this.level}isVisible(){return!!this.children&&this.children.some(e=>e.isVisible())}isPadding(){return this.padding}setExpanded(t){this.expanded=void 0!==t&&t;const i={type:e.EVENT_EXPANDED_CHANGED};this.localEventService.dispatchEvent(i)}isExpandable(){return this.expandable}isExpanded(){return this.expanded}getGroupId(){return this.groupId}getId(){return this.getGroupId()}setChildren(e){this.children=e}getChildren(){return this.children}getColGroupDef(){return this.colGroupDef}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}addLeafColumns(t){this.children&&this.children.forEach(i=>{i instanceof Se?t.push(i):i instanceof e&&i.addLeafColumns(t)})}getColumnGroupShow(){const e=this.colGroupDef;if(e)return e.columnGroupShow}setupExpandable(){this.setExpandable(),this.expandableListenerRemoveCallback&&this.expandableListenerRemoveCallback();const e=this.onColumnVisibilityChanged.bind(this);this.getLeafColumns().forEach(t=>t.addEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=()=>{this.getLeafColumns().forEach(t=>t.removeEventListener("visibleChanged",e)),this.expandableListenerRemoveCallback=null}}setExpandable(){if(this.isPadding())return;let t=!1,i=!1,r=!1;const n=this.findChildrenRemovingPadding();for(let e=0,s=n.length;e<s;e++){const s=n[e];if(!s.isVisible())continue;const o=s.getColumnGroupShow();"open"===o?(t=!0,r=!0):"closed"===o?(i=!0,r=!0):(t=!0,i=!0)}const s=t&&i&&r;if(this.expandable!==s){this.expandable=s;const t={type:e.EVENT_EXPANDABLE_CHANGED};this.localEventService.dispatchEvent(t)}}findChildrenRemovingPadding(){const t=[],i=r=>{r.forEach(r=>{r instanceof e&&r.isPadding()?i(r.children):t.push(r)})};return i(this.children),t}onColumnVisibilityChanged(){this.setExpandable()}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}};be.EVENT_EXPANDED_CHANGED="expandedChanged",be.EVENT_EXPANDABLE_CHANGED="expandableChanged",g([le],be.prototype,"destroy",1);var Ee=be,Ae={numericColumn:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"},rightAligned:{headerClass:"ag-right-aligned-header",cellClass:"ag-right-aligned-cell"}},Te={};p(Te,{addSafePassiveEventListener:()=>tt,createEventPath:()=>Je,getCtrlForEventTarget:()=>Xe,getEventPath:()=>et,isElementInEventPath:()=>Ze,isEventSupported:()=>Qe,isStopPropagationForAgGrid:()=>Ye,stopPropagationForAgGrid:()=>qe});var Me={};function Re(e){return null!=e&&e.length>0}function _e(e){if(e&&e.length)return e[e.length-1]}function Pe(e,t,i){return null==e&&null==t||null!=e&&null!=t&&e.length===t.length&&e.every((e,r)=>i?i(e,t[r]):t[r]===e)}function xe(e,t){return Pe(e,t)}function De(e){return e.sort((e,t)=>e-t)}function Ie(e,t){if(e)for(let i=e.length-2;i>=0;i--){const r=e[i]===t,n=e[i+1]===t;r&&n&&e.splice(i+1,1)}}function Le(e,t){const i=e.indexOf(t);i>=0&&(e[i]=e[e.length-1],e.pop())}function Ne(e,t){const i=e.indexOf(t);i>=0&&e.splice(i,1)}function Oe(e,t){for(let i=0;i<t.length;i++)Le(e,t[i])}function Fe(e,t){for(let i=0;i<t.length;i++)Ne(e,t[i])}function ke(e,t,i){e.splice(i,0,t)}function Ge(e,t,i){if(null!=e&&null!=t)for(let r=t.length-1;r>=0;r--)ke(e,t[r],i)}function Ve(e,t,i){Fe(e,t),t.slice().reverse().forEach(t=>ke(e,t,i))}function He(e,t){return e.indexOf(t)>-1}function Be(e){return[].concat.apply([],e)}function ze(e,t){null!=t&&null!=e&&t.forEach(t=>e.push(t))}function Ue(e){return e.map(S)}function We(e,t){if(null!=e)for(let i=e.length-1;i>=0;i--)t(e[i],i)}p(Me,{areEqual:()=>Pe,existsAndNotEmpty:()=>Re,flatten:()=>Be,forEachReverse:()=>We,includes:()=>He,insertArrayIntoArray:()=>Ge,insertIntoArray:()=>ke,last:()=>_e,moveInArray:()=>Ve,pushAll:()=>ze,removeAllFromArray:()=>Fe,removeAllFromUnorderedArray:()=>Oe,removeFromArray:()=>Ne,removeFromUnorderedArray:()=>Le,removeRepeatsFromArray:()=>Ie,shallowCompare:()=>xe,sortNumerically:()=>De,toStrings:()=>Ue});var je="__ag_Grid_Stop_Propagation",Ke=["touchstart","touchend","touchmove","touchcancel","scroll"],$e={};function qe(e){e[je]=!0}function Ye(e){return!0===e[je]}var Qe=(()=>{const e={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return t=>{if("boolean"==typeof $e[t])return $e[t];const i=document.createElement(e[t]||"div");return $e[t="on"+t]=t in i}})();function Xe(e,t,i){let r=t;for(;r;){const t=e.getDomData(r,i);if(t)return t;r=r.parentElement}return null}function Ze(e,t){return!(!t||!e)&&et(t).indexOf(e)>=0}function Je(e){const t=[];let i=e.target;for(;i;)t.push(i),i=i.parentElement;return t}function et(e){const t=e;return t.path?t.path:t.composedPath?t.composedPath():Je(t)}function tt(e,t,i,r){const n=He(Ke,i)?{passive:!0}:void 0;e&&e.addEventListener&&e.addEventListener(t,i,r,n)}var it=class e{constructor(){this.destroyFunctions=[],this.destroyed=!1,this.__v_skip=!0,this.lastChangeSetIdLookup={},this.propertyListenerId=0,this.isAlive=()=>!this.destroyed}getFrameworkOverrides(){return this.frameworkOverrides}getContext(){return this.context}destroy(){for(let e=0;e<this.destroyFunctions.length;e++)this.destroyFunctions[e]();this.destroyFunctions.length=0,this.destroyed=!0,this.dispatchEvent({type:e.EVENT_DESTROYED})}addEventListener(e,t){this.localEventService||(this.localEventService=new fe),this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService&&this.localEventService.removeEventListener(e,t)}dispatchEvent(e){this.localEventService&&this.localEventService.dispatchEvent(e)}addManagedListener(e,t,i){if(this.destroyed)return;e instanceof HTMLElement?tt(this.getFrameworkOverrides(),e,t,i):e.addEventListener(t,i);const r=()=>(e.removeEventListener(t,i),null);return this.destroyFunctions.push(r),()=>(r(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==r),null)}setupGridOptionListener(e,t){this.gos.addEventListener(e,t);const i=()=>(this.gos.removeEventListener(e,t),null);return this.destroyFunctions.push(i),()=>(i(),this.destroyFunctions=this.destroyFunctions.filter(e=>e!==i),null)}addManagedPropertyListener(e,t){return this.destroyed?()=>null:this.setupGridOptionListener(e,t)}addManagedPropertyListeners(e,t){if(this.destroyed)return;const i=e.join("-")+this.propertyListenerId++,r=e=>{if(e.changeSet){if(e.changeSet&&e.changeSet.id===this.lastChangeSetIdLookup[i])return;this.lastChangeSetIdLookup[i]=e.changeSet.id}const r={type:"gridPropertyChanged",changeSet:e.changeSet,source:e.source};t(r)};e.forEach(e=>this.setupGridOptionListener(e,r))}addDestroyFunc(e){this.isAlive()?this.destroyFunctions.push(e):e()}createManagedBean(e,t){const i=this.createBean(e,t);return this.addDestroyFunc(this.destroyBean.bind(this,e,t)),i}createBean(e,t,i){return(t||this.getContext()).createBean(e,i)}destroyBean(e,t){return(t||this.getContext()).destroyBean(e)}destroyBeans(e,t){if(e)for(let i=0;i<e.length;i++)this.destroyBean(e[i],t);return[]}};it.EVENT_DESTROYED="destroyed",g([ue("frameworkOverrides")],it.prototype,"frameworkOverrides",2),g([ue("context")],it.prototype,"context",2),g([ue("eventService")],it.prototype,"eventService",2),g([ue("gridOptionsService")],it.prototype,"gos",2),g([ue("localeService")],it.prototype,"localeService",2),g([ue("environment")],it.prototype,"environment",2),g([le],it.prototype,"destroy",1);var rt=it,nt=class extends rt{setBeans(e){this.logger=e.create("ColumnFactory")}createColumnTree(e,t,i,r){const n=new _,{existingCols:s,existingGroups:o,existingColKeys:a}=this.extractExistingTreeData(i);n.addExistingKeys(a);const l=this.recursivelyCreateColumns(e,0,t,s,n,o,r),c=this.findMaxDept(l,0);this.logger.log("Number of levels for grouped columns is "+c);const u=this.balanceColumnTree(l,0,c,n);return st(null,u,(e,t)=>{e instanceof Ee&&e.setupExpandable(),e.setOriginalParent(t)}),{columnTree:u,treeDept:c}}extractExistingTreeData(e){const t=[],i=[],r=[];return e&&st(null,e,e=>{if(e instanceof Ee){const t=e;i.push(t)}else{const i=e;r.push(i.getId()),t.push(i)}}),{existingCols:t,existingGroups:i,existingColKeys:r}}createForAutoGroups(e,t){return e.map(e=>this.createAutoGroupTreeItem(t,e))}createAutoGroupTreeItem(e,t){const i=this.findDepth(e);let r=t;for(let e=i-1;e>=0;e--){const i=new Ee(null,`FAKE_PATH_${t.getId()}}_${e}`,!0,e);this.createBean(i),i.setChildren([r]),r.setOriginalParent(i),r=i}return 0===i&&t.setOriginalParent(null),r}findDepth(e){let t=0,i=e;for(;i&&i[0]&&i[0]instanceof Ee;)t++,i=i[0].getChildren();return t}balanceColumnTree(e,t,i,r){const n=[];for(let s=0;s<e.length;s++){const o=e[s];if(o instanceof Ee){const e=o,s=this.balanceColumnTree(e.getChildren(),t+1,i,r);e.setChildren(s),n.push(e)}else{let s,a;for(let e=i-1;e>=t;e--){const e=r.getUniqueKey(null,null),i=this.createMergedColGroupDef(null),n=new Ee(i,e,!0,t);this.createBean(n),a&&a.setChildren([n]),a=n,s||(s=a)}if(s&&a){if(n.push(s),e.some(e=>e instanceof Ee)){a.setChildren([o]);continue}a.setChildren(e);break}n.push(o)}}return n}findMaxDept(e,t){let i=t;for(let r=0;r<e.length;r++){const n=e[r];if(n instanceof Ee){const e=n,r=this.findMaxDept(e.getChildren(),t+1);i<r&&(i=r)}}return i}recursivelyCreateColumns(e,t,i,r,n,s,o){if(!e)return[];const a=new Array(e.length);for(let l=0;l<a.length;l++){const c=e[l];this.isColumnGroup(c)?a[l]=this.createColumnGroup(i,c,t,r,n,s,o):a[l]=this.createColumn(i,c,r,n,o)}return a}createColumnGroup(e,t,i,r,n,s,o){const a=this.createMergedColGroupDef(t),l=n.getUniqueKey(a.groupId||null,null),c=new Ee(a,l,!1,i);this.createBean(c);const u=this.findExistingGroup(t,s);u&&s.splice(u.idx,1);let h=null==u?void 0:u.group;h&&c.setExpanded(h.isExpanded());const d=this.recursivelyCreateColumns(a.children,i+1,e,r,n,s,o);return c.setChildren(d),c}createMergedColGroupDef(e){const t={};return Object.assign(t,this.gos.get("defaultColGroupDef")),Object.assign(t,e),t}createColumn(e,t,i,r,n){const s=this.findExistingColumn(t,i);s&&(null==i||i.splice(s.idx,1));let o=null==s?void 0:s.column;if(o){const e=this.addColumnDefaultAndTypes(t,o.getColId());o.setColDef(e,t,n),this.applyColumnState(o,e,n)}else{const i=r.getUniqueKey(t.colId,t.field),n=this.addColumnDefaultAndTypes(t,i);o=new Se(n,t,i,e),this.context.createBean(o)}return this.dataTypeService.addColumnListeners(o),o}applyColumnState(e,t,i){const r=b(t.flex);if(void 0!==r&&e.setFlex(r),e.getFlex()<=0){const r=b(t.width);if(null!=r)e.setActualWidth(r,i);else{const t=e.getActualWidth();e.setActualWidth(t,i)}}void 0!==t.sort&&("asc"==t.sort||"desc"==t.sort?e.setSort(t.sort,i):e.setSort(void 0,i));const n=b(t.sortIndex);void 0!==n&&e.setSortIndex(n);const s=E(t.hide);void 0!==s&&e.setVisible(!s,i),void 0!==t.pinned&&e.setPinned(t.pinned)}findExistingColumn(e,t){if(t)for(let i=0;i<t.length;i++){const r=t[i].getUserProvidedColDef();if(r)if(null==e.colId){if(null!=e.field){if(r.field===e.field)return{idx:i,column:t[i]}}else if(r===e)return{idx:i,column:t[i]}}else if(t[i].getId()===e.colId)return{idx:i,column:t[i]}}}findExistingGroup(e,t){if(null!=e.groupId)for(let i=0;i<t.length;i++){const r=t[i];if(r.getColGroupDef()&&r.getId()===e.groupId)return{idx:i,group:r}}}addColumnDefaultAndTypes(e,t){const i={};O(i,this.gos.get("defaultColDef"),!1,!0);const r=this.dataTypeService.updateColDefAndGetColumnType(i,e,t);r&&this.assignColumnTypes(r,i),O(i,e,!1,!0);const n=this.gos.get("autoGroupColumnDef"),s=this.gos.isColumnsSortingCoupledToGroup();return e.rowGroup&&n&&s&&O(i,{sort:n.sort,initialSort:n.initialSort},!1,!0),this.dataTypeService.validateColDef(i),i}assignColumnTypes(e,t){if(!e.length)return;const i=Object.assign({},Ae);D(this.gos.get("columnTypes")||{},(e,t)=>{e in i?console.warn(`AG Grid: the column type '${e}' is a default column type and cannot be overridden.`):(t.type&&z("Column type definitions 'columnTypes' with a 'type' attribute are not supported because a column type cannot refer to another column type. Only column definitions 'columnDefs' can use the 'type' attribute to refer to a column type."),i[e]=t)}),e.forEach(e=>{const r=i[e.trim()];r?O(t,r,!1,!0):console.warn("AG Grid: colDef.type '"+e+"' does not correspond to defined gridOptions.columnTypes")})}isColumnGroup(e){return void 0!==e.children}};function st(e,t,i){if(t)for(let r=0;r<t.length;r++){const n=t[r];n instanceof Ee&&st(n,n.getChildren(),i),i(n,e)}}g([ue("dataTypeService")],nt.prototype,"dataTypeService",2),g([f(0,pe("loggerFactory"))],nt.prototype,"setBeans",1),nt=g([ce("columnFactory")],nt);var ot=class e{constructor(e,t,i,r){this.displayedChildren=[],this.localEventService=new fe,this.groupId=t,this.partId=i,this.providedColumnGroup=e,this.pinned=r}static createUniqueId(e,t){return e+"_"+t}reset(){this.parent=null,this.children=null,this.displayedChildren=null}getParent(){return this.parent}setParent(e){this.parent=e}getUniqueId(){return e.createUniqueId(this.groupId,this.partId)}isEmptyGroup(){return 0===this.displayedChildren.length}isMoving(){const e=this.getProvidedColumnGroup().getLeafColumns();return!(!e||0===e.length)&&e.every(e=>e.isMoving())}checkLeft(){if(this.displayedChildren.forEach(t=>{t instanceof e&&t.checkLeft()}),this.displayedChildren.length>0)if(this.gos.get("enableRtl")){const e=_e(this.displayedChildren).getLeft();this.setLeft(e)}else{const e=this.displayedChildren[0].getLeft();this.setLeft(e)}else this.setLeft(null)}getLeft(){return this.left}getOldLeft(){return this.oldLeft}setLeft(t){this.oldLeft=this.left,this.left!==t&&(this.left=t,this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_LEFT_CHANGED)))}getPinned(){return this.pinned}createAgEvent(e){return{type:e}}addEventListener(e,t){this.localEventService.addEventListener(e,t)}removeEventListener(e,t){this.localEventService.removeEventListener(e,t)}getGroupId(){return this.groupId}getPartId(){return this.partId}isChildInThisGroupDeepSearch(t){let i=!1;return this.children.forEach(r=>{t===r&&(i=!0),r instanceof e&&r.isChildInThisGroupDeepSearch(t)&&(i=!0)}),i}getActualWidth(){let e=0;return this.displayedChildren&&this.displayedChildren.forEach(t=>{e+=t.getActualWidth()}),e}isResizable(){if(!this.displayedChildren)return!1;let e=!1;return this.displayedChildren.forEach(t=>{t.isResizable()&&(e=!0)}),e}getMinWidth(){let e=0;return this.displayedChildren.forEach(t=>{e+=t.getMinWidth()||0}),e}addChild(e){this.children||(this.children=[]),this.children.push(e)}getDisplayedChildren(){return this.displayedChildren}getLeafColumns(){const e=[];return this.addLeafColumns(e),e}getDisplayedLeafColumns(){const e=[];return this.addDisplayedLeafColumns(e),e}getDefinition(){return this.providedColumnGroup.getColGroupDef()}getColGroupDef(){return this.providedColumnGroup.getColGroupDef()}isPadding(){return this.providedColumnGroup.isPadding()}isExpandable(){return this.providedColumnGroup.isExpandable()}isExpanded(){return this.providedColumnGroup.isExpanded()}setExpanded(e){this.providedColumnGroup.setExpanded(e)}addDisplayedLeafColumns(t){this.displayedChildren.forEach(i=>{i instanceof Se?t.push(i):i instanceof e&&i.addDisplayedLeafColumns(t)})}addLeafColumns(t){this.children.forEach(i=>{i instanceof Se?t.push(i):i instanceof e&&i.addLeafColumns(t)})}getChildren(){return this.children}getColumnGroupShow(){return this.providedColumnGroup.getColumnGroupShow()}getProvidedColumnGroup(){return this.providedColumnGroup}getPaddingLevel(){const e=this.getParent();return this.isPadding()&&e&&e.isPadding()?1+e.getPaddingLevel():0}calculateDisplayedColumns(){this.displayedChildren=[];let t=this;for(;null!=t&&t.isPadding();)t=t.getParent();if(!t||!t.providedColumnGroup.isExpandable())return this.displayedChildren=this.children,void this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_DISPLAYED_CHILDREN_CHANGED));this.children.forEach(i=>{if(!(i instanceof e)||i.displayedChildren&&i.displayedChildren.length)switch(i.getColumnGroupShow()){case"open":t.providedColumnGroup.isExpanded()&&this.displayedChildren.push(i);break;case"closed":t.providedColumnGroup.isExpanded()||this.displayedChildren.push(i);break;default:this.displayedChildren.push(i)}}),this.localEventService.dispatchEvent(this.createAgEvent(e.EVENT_DISPLAYED_CHILDREN_CHANGED))}};ot.EVENT_LEFT_CHANGED="leftChanged",ot.EVENT_DISPLAYED_CHILDREN_CHANGED="displayedChildrenChanged",g([ue("gridOptionsService")],ot.prototype,"gos",2);var at=ot,lt=class{};lt.EVENT_COLUMN_EVERYTHING_CHANGED="columnEverythingChanged",lt.EVENT_NEW_COLUMNS_LOADED="newColumnsLoaded",lt.EVENT_COLUMN_PIVOT_MODE_CHANGED="columnPivotModeChanged",lt.EVENT_PIVOT_MAX_COLUMNS_EXCEEDED="pivotMaxColumnsExceeded",lt.EVENT_COLUMN_ROW_GROUP_CHANGED="columnRowGroupChanged",lt.EVENT_EXPAND_COLLAPSE_ALL="expandOrCollapseAll",lt.EVENT_COLUMN_PIVOT_CHANGED="columnPivotChanged",lt.EVENT_GRID_COLUMNS_CHANGED="gridColumnsChanged",lt.EVENT_COLUMN_VALUE_CHANGED="columnValueChanged",lt.EVENT_COLUMN_MOVED="columnMoved",lt.EVENT_COLUMN_VISIBLE="columnVisible",lt.EVENT_COLUMN_PINNED="columnPinned",lt.EVENT_COLUMN_GROUP_OPENED="columnGroupOpened",lt.EVENT_COLUMN_RESIZED="columnResized",lt.EVENT_DISPLAYED_COLUMNS_CHANGED="displayedColumnsChanged",lt.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED="suppressMovableColumns",lt.EVENT_SUPPRESS_MENU_HIDE_CHANGED="suppressMenuHide",lt.EVENT_SUPPRESS_FIELD_DOT_NOTATION="suppressFieldDotNotation",lt.EVENT_VIRTUAL_COLUMNS_CHANGED="virtualColumnsChanged",lt.EVENT_COLUMN_HEADER_MOUSE_OVER="columnHeaderMouseOver",lt.EVENT_COLUMN_HEADER_MOUSE_LEAVE="columnHeaderMouseLeave",lt.EVENT_COLUMN_HEADER_CLICKED="columnHeaderClicked",lt.EVENT_COLUMN_HEADER_CONTEXT_MENU="columnHeaderContextMenu",lt.EVENT_ASYNC_TRANSACTIONS_FLUSHED="asyncTransactionsFlushed",lt.EVENT_ROW_GROUP_OPENED="rowGroupOpened",lt.EVENT_ROW_DATA_UPDATED="rowDataUpdated",lt.EVENT_PINNED_ROW_DATA_CHANGED="pinnedRowDataChanged",lt.EVENT_RANGE_SELECTION_CHANGED="rangeSelectionChanged",lt.EVENT_CHART_CREATED="chartCreated",lt.EVENT_CHART_RANGE_SELECTION_CHANGED="chartRangeSelectionChanged",lt.EVENT_CHART_OPTIONS_CHANGED="chartOptionsChanged",lt.EVENT_CHART_DESTROYED="chartDestroyed",lt.EVENT_TOOL_PANEL_VISIBLE_CHANGED="toolPanelVisibleChanged",lt.EVENT_TOOL_PANEL_SIZE_CHANGED="toolPanelSizeChanged",lt.EVENT_COLUMN_PANEL_ITEM_DRAG_START="columnPanelItemDragStart",lt.EVENT_COLUMN_PANEL_ITEM_DRAG_END="columnPanelItemDragEnd",lt.EVENT_MODEL_UPDATED="modelUpdated",lt.EVENT_CUT_START="cutStart",lt.EVENT_CUT_END="cutEnd",lt.EVENT_PASTE_START="pasteStart",lt.EVENT_PASTE_END="pasteEnd",lt.EVENT_FILL_START="fillStart",lt.EVENT_FILL_END="fillEnd",lt.EVENT_RANGE_DELETE_START="rangeDeleteStart",lt.EVENT_RANGE_DELETE_END="rangeDeleteEnd",lt.EVENT_UNDO_STARTED="undoStarted",lt.EVENT_UNDO_ENDED="undoEnded",lt.EVENT_REDO_STARTED="redoStarted",lt.EVENT_REDO_ENDED="redoEnded",lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_START="keyShortcutChangedCellStart",lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_END="keyShortcutChangedCellEnd",lt.EVENT_CELL_CLICKED="cellClicked",lt.EVENT_CELL_DOUBLE_CLICKED="cellDoubleClicked",lt.EVENT_CELL_MOUSE_DOWN="cellMouseDown",lt.EVENT_CELL_CONTEXT_MENU="cellContextMenu",lt.EVENT_CELL_VALUE_CHANGED="cellValueChanged",lt.EVENT_CELL_EDIT_REQUEST="cellEditRequest",lt.EVENT_ROW_VALUE_CHANGED="rowValueChanged",lt.EVENT_CELL_FOCUSED="cellFocused",lt.EVENT_CELL_FOCUS_CLEARED="cellFocusCleared",lt.EVENT_FULL_WIDTH_ROW_FOCUSED="fullWidthRowFocused",lt.EVENT_ROW_SELECTED="rowSelected",lt.EVENT_SELECTION_CHANGED="selectionChanged",lt.EVENT_TOOLTIP_SHOW="tooltipShow",lt.EVENT_TOOLTIP_HIDE="tooltipHide",lt.EVENT_CELL_KEY_DOWN="cellKeyDown",lt.EVENT_CELL_MOUSE_OVER="cellMouseOver",lt.EVENT_CELL_MOUSE_OUT="cellMouseOut",lt.EVENT_FILTER_CHANGED="filterChanged",lt.EVENT_FILTER_MODIFIED="filterModified",lt.EVENT_FILTER_OPENED="filterOpened",lt.EVENT_ADVANCED_FILTER_BUILDER_VISIBLE_CHANGED="advancedFilterBuilderVisibleChanged",lt.EVENT_SORT_CHANGED="sortChanged",lt.EVENT_VIRTUAL_ROW_REMOVED="virtualRowRemoved",lt.EVENT_ROW_CLICKED="rowClicked",lt.EVENT_ROW_DOUBLE_CLICKED="rowDoubleClicked",lt.EVENT_GRID_READY="gridReady",lt.EVENT_GRID_PRE_DESTROYED="gridPreDestroyed",lt.EVENT_GRID_SIZE_CHANGED="gridSizeChanged",lt.EVENT_VIEWPORT_CHANGED="viewportChanged",lt.EVENT_SCROLLBAR_WIDTH_CHANGED="scrollbarWidthChanged",lt.EVENT_FIRST_DATA_RENDERED="firstDataRendered",lt.EVENT_DRAG_STARTED="dragStarted",lt.EVENT_DRAG_STOPPED="dragStopped",lt.EVENT_CHECKBOX_CHANGED="checkboxChanged",lt.EVENT_ROW_EDITING_STARTED="rowEditingStarted",lt.EVENT_ROW_EDITING_STOPPED="rowEditingStopped",lt.EVENT_CELL_EDITING_STARTED="cellEditingStarted",lt.EVENT_CELL_EDITING_STOPPED="cellEditingStopped",lt.EVENT_BODY_SCROLL="bodyScroll",lt.EVENT_BODY_SCROLL_END="bodyScrollEnd",lt.EVENT_HEIGHT_SCALE_CHANGED="heightScaleChanged",lt.EVENT_PAGINATION_CHANGED="paginationChanged",lt.EVENT_COMPONENT_STATE_CHANGED="componentStateChanged",lt.EVENT_STORE_REFRESHED="storeRefreshed",lt.EVENT_STATE_UPDATED="stateUpdated",lt.EVENT_COLUMN_MENU_VISIBLE_CHANGED="columnMenuVisibleChanged",lt.EVENT_CONTEXT_MENU_VISIBLE_CHANGED="contextMenuVisibleChanged",lt.EVENT_BODY_HEIGHT_CHANGED="bodyHeightChanged",lt.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED="columnContainerWidthChanged",lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED="displayedColumnsWidthChanged",lt.EVENT_SCROLL_VISIBILITY_CHANGED="scrollVisibilityChanged",lt.EVENT_COLUMN_HOVER_CHANGED="columnHoverChanged",lt.EVENT_FLASH_CELLS="flashCells",lt.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED="paginationPixelOffsetChanged",lt.EVENT_DISPLAYED_ROWS_CHANGED="displayedRowsChanged",lt.EVENT_LEFT_PINNED_WIDTH_CHANGED="leftPinnedWidthChanged",lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED="rightPinnedWidthChanged",lt.EVENT_ROW_CONTAINER_HEIGHT_CHANGED="rowContainerHeightChanged",lt.EVENT_HEADER_HEIGHT_CHANGED="headerHeightChanged",lt.EVENT_COLUMN_HEADER_HEIGHT_CHANGED="columnHeaderHeightChanged",lt.EVENT_ROW_DRAG_ENTER="rowDragEnter",lt.EVENT_ROW_DRAG_MOVE="rowDragMove",lt.EVENT_ROW_DRAG_LEAVE="rowDragLeave",lt.EVENT_ROW_DRAG_END="rowDragEnd",lt.EVENT_GRID_STYLES_CHANGED="gridStylesChanged",lt.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST="columnRowGroupChangeRequest",lt.EVENT_COLUMN_PIVOT_CHANGE_REQUEST="columnPivotChangeRequest",lt.EVENT_COLUMN_VALUE_CHANGE_REQUEST="columnValueChangeRequest",lt.EVENT_COLUMN_AGG_FUNC_CHANGE_REQUEST="columnAggFuncChangeRequest",lt.EVENT_STORE_UPDATED="storeUpdated",lt.EVENT_FILTER_DESTROYED="filterDestroyed",lt.EVENT_ROW_DATA_UPDATE_STARTED="rowDataUpdateStarted",lt.EVENT_ROW_COUNT_READY="rowCountReady",lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED="advancedFilterEnabledChanged",lt.EVENT_DATA_TYPES_INFERRED="dataTypesInferred",lt.EVENT_FIELD_VALUE_CHANGED="fieldValueChanged",lt.EVENT_FIELD_PICKER_VALUE_SELECTED="fieldPickerValueSelected",lt.EVENT_SIDE_BAR_UPDATED="sideBarUpdated";var ct=new Set([lt.EVENT_GRID_PRE_DESTROYED,lt.EVENT_FILL_START]),ut=class{constructor(){this.existingIds={}}getInstanceIdForKey(e){const t=this.existingIds[e];let i;return i="number"!=typeof t?0:t+1,this.existingIds[e]=i,i}},ht="ag-Grid-AutoColumn",dt=class extends rt{createAutoGroupColumns(e){const t=[],i=this.gos.get("treeData");let r=this.gos.isGroupMultiAutoColumn();return i&&r&&(console.warn('AG Grid: you cannot mix groupDisplayType = "multipleColumns" with treeData, only one column can be used to display groups when doing tree data'),r=!1),r?e.forEach((e,i)=>{t.push(this.createOneAutoGroupColumn(e,i))}):t.push(this.createOneAutoGroupColumn()),t}updateAutoGroupColumns(e,t){e.forEach((e,i)=>this.updateOneAutoGroupColumn(e,i,t))}createOneAutoGroupColumn(e,t){let i;i=e?`${ht}-${e.getId()}`:ht;const r=this.createAutoGroupColDef(i,e,t);r.colId=i;const n=new Se(r,null,i,!0);return this.context.createBean(n),n}updateOneAutoGroupColumn(e,t,i){const r=e.getColDef(),n="string"==typeof r.showRowGroup?r.showRowGroup:void 0,s=null!=n?this.columnModel.getPrimaryColumn(n):void 0,o=this.createAutoGroupColDef(e.getId(),null!=s?s:void 0,t);e.setColDef(o,null,i),this.columnFactory.applyColumnState(e,o,i)}createAutoGroupColDef(e,t,i){let r=this.createBaseColDef(t);O(r,this.gos.get("autoGroupColumnDef")),r=this.columnFactory.addColumnDefaultAndTypes(r,e),this.gos.get("treeData")||y(r.field)&&y(r.valueGetter)&&y(r.filterValueGetter)&&"agGroupColumnFilter"!==r.filter&&(r.filter=!1),i&&i>0&&(r.headerCheckboxSelection=!1);const n=this.gos.isColumnsSortingCoupledToGroup(),s=r.valueGetter||null!=r.field;return n&&!s&&(r.sortIndex=void 0,r.initialSort=void 0),r}createBaseColDef(e){const t=this.gos.get("autoGroupColumnDef"),i={headerName:this.localeService.getLocaleTextFunc()("group","Group")};if(t&&(t.cellRenderer||t.cellRendererSelector)||(i.cellRenderer="agGroupCellRenderer"),e){const t=e.getColDef();Object.assign(i,{headerName:this.columnModel.getDisplayNameForColumn(e,"header"),headerValueGetter:t.headerValueGetter}),t.cellRenderer&&Object.assign(i,{cellRendererParams:{innerRenderer:t.cellRenderer,innerRendererParams:t.cellRendererParams}}),i.showRowGroup=e.getColId()}else i.showRowGroup=!0;return i}};g([ue("columnModel")],dt.prototype,"columnModel",2),g([ue("columnFactory")],dt.prototype,"columnFactory",2),dt=g([ce("autoGroupColService")],dt);var pt={};p(pt,{camelCaseToHumanText:()=>yt,camelCaseToHyphenated:()=>wt,capitalise:()=>vt,escapeString:()=>Ct,utf8_encode:()=>mt});var gt=/[&<>"']/g,ft={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"};function mt(e){const t=String.fromCharCode;function i(e,i){return t(e>>i&63|128)}function r(e){if(e>=0&&e<=31&&10!==e)return`_x${e.toString(16).toUpperCase().padStart(4,"0")}_`;if(!(4294967168&e))return t(e);let r="";return 4294965248&e?4294901760&e?4292870144&e||(r=t(e>>18&7|240),r+=i(e,12),r+=i(e,6)):(function(e){if(e>=55296&&e<=57343)throw Error("Lone surrogate U+"+e.toString(16).toUpperCase()+" is not a scalar value")}(e),r=t(e>>12&15|224),r+=i(e,6)):r=t(e>>6&31|192),r+=t(63&e|128),r}const n=function(e){const t=[];if(!e)return[];const i=e.length;let r,n,s=0;for(;s<i;)r=e.charCodeAt(s++),r>=55296&&r<=56319&&s<i?(n=e.charCodeAt(s++),56320==(64512&n)?t.push(((1023&r)<<10)+(1023&n)+65536):(t.push(r),s--)):t.push(r);return t}(e),s=n.length;let o,a=-1,l="";for(;++a<s;)o=n[a],l+=r(o);return l}function vt(e){return e[0].toUpperCase()+e.substring(1).toLowerCase()}function Ct(e,t){if(null==e)return null;const i=e.toString().toString();return t?i:i.replace(gt,e=>ft[e])}function yt(e){return e&&null!=e?e.replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z])([a-z])/g,"$1 $2$3").replace(/\./g," ").split(" ").map(e=>e.substring(0,1).toUpperCase()+(e.length>1?e.substring(1,e.length):"")).join(" "):null}function wt(e){return e.replace(/[A-Z]/g,e=>`-${e.toLocaleLowerCase()}`)}var St={};function bt(e){const t=new Map;return e.forEach(e=>t.set(e[0],e[1])),t}function Et(e,t){const i=new Map;return e.forEach(e=>i.set(t(e),e)),i}function At(e){const t=[];return e.forEach((e,i)=>t.push(i)),t}p(St,{convertToMap:()=>bt,keys:()=>At,mapById:()=>Et});var Tt=class extends rt{constructor(){super(...arguments),this.primaryHeaderRowCount=0,this.secondaryHeaderRowCount=0,this.gridHeaderRowCount=0,this.displayedColumnsLeft=[],this.displayedColumnsRight=[],this.displayedColumnsCenter=[],this.displayedColumns=[],this.displayedColumnsAndGroupsMap={},this.viewportColumns=[],this.viewportColumnsHash="",this.headerViewportColumns=[],this.viewportColumnsCenter=[],this.headerViewportColumnsCenter=[],this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={},this.autoHeightActiveAtLeastOnce=!1,this.rowGroupColumns=[],this.valueColumns=[],this.pivotColumns=[],this.ready=!1,this.changeEventsDispatching=!1,this.autoGroupsNeedBuilding=!1,this.forceRecreateAutoGroups=!1,this.pivotMode=!1,this.bodyWidth=0,this.leftWidth=0,this.rightWidth=0,this.bodyWidthDirty=!0,this.shouldQueueResizeOperations=!1,this.resizeOperationQueue=[]}init(){this.suppressColumnVirtualisation=this.gos.get("suppressColumnVirtualisation");const e=this.gos.get("pivotMode");this.isPivotSettingAllowed(e)&&(this.pivotMode=e),this.addManagedPropertyListeners(["groupDisplayType","treeData","treeDataDisplayType","groupHideOpenParents"],e=>this.buildAutoGroupColumns(Mt(e.source))),this.addManagedPropertyListener("autoGroupColumnDef",e=>this.onAutoGroupColumnDefChanged(Mt(e.source))),this.addManagedPropertyListeners(["defaultColDef","columnTypes","suppressFieldDotNotation"],e=>this.onSharedColDefChanged(Mt(e.source))),this.addManagedPropertyListener("pivotMode",e=>this.setPivotMode(this.gos.get("pivotMode"),Mt(e.source))),this.addManagedListener(this.eventService,lt.EVENT_FIRST_DATA_RENDERED,()=>this.onFirstDataRendered())}buildAutoGroupColumns(e){this.columnDefs&&(this.autoGroupsNeedBuilding=!0,this.forceRecreateAutoGroups=!0,this.updateGridColumns(),this.updateDisplayedColumns(e))}onAutoGroupColumnDefChanged(e){this.groupAutoColumns&&this.autoGroupColService.updateAutoGroupColumns(this.groupAutoColumns,e)}onSharedColDefChanged(e){this.gridColumns&&(this.groupAutoColumns&&this.autoGroupColService.updateAutoGroupColumns(this.groupAutoColumns,e),this.createColumnsFromColumnDefs(!0,e))}setColumnDefs(e,t){const i=!!this.columnDefs;this.columnDefs=e,this.createColumnsFromColumnDefs(i,t)}recreateColumnDefs(e){this.onSharedColDefChanged(e)}destroyOldColumns(e,t){const i={};if(!e)return;st(null,e,e=>{i[e.getInstanceId()]=e}),t&&st(null,t,e=>{i[e.getInstanceId()]=null});const r=Object.values(i).filter(e=>null!=e);this.destroyBeans(r)}destroyColumns(){this.destroyOldColumns(this.primaryColumnTree),this.destroyOldColumns(this.secondaryBalancedTree),this.destroyOldColumns(this.groupAutoColsBalancedTree)}createColumnsFromColumnDefs(e,t){const i=e?this.compareColumnStatesAndDispatchEvents(t):void 0;this.valueCache.expire(),this.autoGroupsNeedBuilding=!0;const r=this.primaryColumns,n=this.primaryColumnTree,s=this.columnFactory.createColumnTree(this.columnDefs,!0,n,t);this.destroyOldColumns(this.primaryColumnTree,s.columnTree),this.primaryColumnTree=s.columnTree,this.primaryHeaderRowCount=s.treeDept+1,this.primaryColumns=this.getColumnsFromTree(this.primaryColumnTree),this.primaryColumnsMap={},this.primaryColumns.forEach(e=>this.primaryColumnsMap[e.getId()]=e),this.extractRowGroupColumns(t,r),this.extractPivotColumns(t,r),this.extractValueColumns(t,r),this.ready=!0;const o=void 0===this.gridColsArePrimary;(this.gridColsArePrimary||o||this.autoGroupsNeedBuilding)&&(this.updateGridColumns(),e&&this.gridColsArePrimary&&!this.gos.get("maintainColumnOrder")&&this.orderGridColumnsLikePrimary(),this.updateDisplayedColumns(t),this.checkViewportColumns()),this.dispatchEverythingChanged(t),this.changeEventsDispatching=!0,i&&i(),this.changeEventsDispatching=!1,this.dispatchNewColumnsLoaded(t)}shouldRowModelIgnoreRefresh(){return this.changeEventsDispatching}dispatchNewColumnsLoaded(e){const t={type:lt.EVENT_NEW_COLUMNS_LOADED,source:e};this.eventService.dispatchEvent(t),"gridInitializing"===e&&this.onColumnsReady()}dispatchEverythingChanged(e){const t={type:lt.EVENT_COLUMN_EVERYTHING_CHANGED,source:e};this.eventService.dispatchEvent(t)}orderGridColumnsLikePrimary(){const e=this.primaryColumns;if(!e)return;const t=e.filter(e=>this.gridColumns.indexOf(e)>=0),i=this.gridColumns.filter(e=>t.indexOf(e)<0);this.gridColumns=[...i,...t],this.gridColumns=this.placeLockedColumns(this.gridColumns)}getAllDisplayedAutoHeightCols(){return this.displayedAutoHeightCols}setViewport(){this.gos.get("enableRtl")?(this.viewportLeft=this.bodyWidth-this.scrollPosition-this.scrollWidth,this.viewportRight=this.bodyWidth-this.scrollPosition):(this.viewportLeft=this.scrollPosition,this.viewportRight=this.scrollWidth+this.scrollPosition)}checkViewportColumns(e=!1){if(null==this.displayedColumnsCenter)return;if(!this.extractViewport())return;const t={type:lt.EVENT_VIRTUAL_COLUMNS_CHANGED,afterScroll:e};this.eventService.dispatchEvent(t)}setViewportPosition(e,t,i=!1){(e!==this.scrollWidth||t!==this.scrollPosition||this.bodyWidthDirty)&&(this.scrollWidth=e,this.scrollPosition=t,this.bodyWidthDirty=!0,this.setViewport(),this.ready&&this.checkViewportColumns(i))}isPivotMode(){return this.pivotMode}isPivotSettingAllowed(e){return!e||!this.gos.get("treeData")||(z("Pivot mode not available with treeData."),!1)}setPivotMode(e,t){if(e===this.pivotMode||!this.isPivotSettingAllowed(this.pivotMode))return;if(this.pivotMode=e,!this.gridColumns)return;this.autoGroupsNeedBuilding=!0,this.updateGridColumns(),this.updateDisplayedColumns(t);const i={type:lt.EVENT_COLUMN_PIVOT_MODE_CHANGED};this.eventService.dispatchEvent(i)}getSecondaryPivotColumn(e,t){if(y(this.secondaryColumns))return null;const i=this.getPrimaryColumn(t);let r=null;return this.secondaryColumns.forEach(t=>{const n=t.getColDef().pivotKeys,s=t.getColDef().pivotValueColumn;Pe(n,e)&&s===i&&(r=t)}),r}setBeans(e){this.logger=e.create("columnModel")}setFirstRightAndLastLeftPinned(e){let t,i;this.gos.get("enableRtl")?(t=this.displayedColumnsLeft?this.displayedColumnsLeft[0]:null,i=this.displayedColumnsRight?_e(this.displayedColumnsRight):null):(t=this.displayedColumnsLeft?_e(this.displayedColumnsLeft):null,i=this.displayedColumnsRight?this.displayedColumnsRight[0]:null),this.gridColumns.forEach(r=>{r.setLastLeftPinned(r===t,e),r.setFirstRightPinned(r===i,e)})}autoSizeColumns(e){if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.autoSizeColumns(e));const{columns:t,skipHeader:i,skipHeaderGroups:r,stopAtGroup:n,source:s="api"}=e;this.animationFrameService.flushAllFrames();const o=[];let a=-1;const l=null!=i?i:this.gos.get("skipHeaderOnAutoSize"),c=null!=r?r:l;for(;0!==a;)a=0,this.actionOnGridColumns(t,e=>{if(o.indexOf(e)>=0)return!1;const t=this.autoWidthCalculator.getPreferredWidthForColumn(e,l);if(t>0){const i=this.normaliseColumnWidth(e,t);e.setActualWidth(i,s),o.push(e),a++}return!0},s);c||this.autoSizeColumnGroupsByColumns(t,s,n),this.dispatchColumnResizedEvent(o,!0,"autosizeColumns")}dispatchColumnResizedEvent(e,t,i,r=null){if(e&&e.length){const n={type:lt.EVENT_COLUMN_RESIZED,columns:e,column:1===e.length?e[0]:null,flexColumns:r,finished:t,source:i};this.eventService.dispatchEvent(n)}}dispatchColumnChangedEvent(e,t,i){const r={type:e,columns:t,column:t&&1==t.length?t[0]:null,source:i};this.eventService.dispatchEvent(r)}dispatchColumnMovedEvent(e){const{movedColumns:t,source:i,toIndex:r,finished:n}=e,s={type:lt.EVENT_COLUMN_MOVED,columns:t,column:t&&1===t.length?t[0]:null,toIndex:r,finished:n,source:i};this.eventService.dispatchEvent(s)}dispatchColumnPinnedEvent(e,t){if(!e.length)return;const i=1===e.length?e[0]:null,r=this.getCommonValue(e,e=>e.getPinned()),n={type:lt.EVENT_COLUMN_PINNED,pinned:null!=r?r:null,columns:e,column:i,source:t};this.eventService.dispatchEvent(n)}dispatchColumnVisibleEvent(e,t){if(!e.length)return;const i=1===e.length?e[0]:null,r=this.getCommonValue(e,e=>e.isVisible()),n={type:lt.EVENT_COLUMN_VISIBLE,visible:r,columns:e,column:i,source:t};this.eventService.dispatchEvent(n)}autoSizeColumn(e,t,i){e&&this.autoSizeColumns({columns:[e],skipHeader:i,skipHeaderGroups:!0,source:t})}autoSizeColumnGroupsByColumns(e,t,i){const r=new Set;let n;this.getGridColumns(e).forEach(e=>{let t=e.getParent();for(;t&&t!=i;)t.isPadding()||r.add(t),t=t.getParent()});for(const e of r){for(const t of this.ctrlsService.getHeaderRowContainerCtrls())if(n=t.getHeaderCtrlForColumn(e),n)break;n&&n.resizeLeafColumnsToFit(t)}return[]}autoSizeAllColumns(e,t){if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.autoSizeAllColumns(e,t));const i=this.getAllDisplayedColumns();this.autoSizeColumns({columns:i,skipHeader:t,source:e})}getColumnsFromTree(e){const t=[],i=e=>{for(let r=0;r<e.length;r++){const n=e[r];n instanceof Se?t.push(n):n instanceof Ee&&i(n.getChildren())}};return i(e),t}getAllDisplayedTrees(){return this.displayedTreeLeft&&this.displayedTreeRight&&this.displayedTreeCentre?this.displayedTreeLeft.concat(this.displayedTreeCentre).concat(this.displayedTreeRight):null}getPrimaryColumnTree(){return this.primaryColumnTree}getHeaderRowCount(){return this.gridHeaderRowCount}getDisplayedTreeLeft(){return this.displayedTreeLeft}getDisplayedTreeRight(){return this.displayedTreeRight}getDisplayedTreeCentre(){return this.displayedTreeCentre}isColumnDisplayed(e){return this.getAllDisplayedColumns().indexOf(e)>=0}getAllDisplayedColumns(){return this.displayedColumns}getViewportColumns(){return this.viewportColumns}getDisplayedLeftColumnsForRow(e){return this.colSpanActive?this.getDisplayedColumnsForRow(e,this.displayedColumnsLeft):this.displayedColumnsLeft}getDisplayedRightColumnsForRow(e){return this.colSpanActive?this.getDisplayedColumnsForRow(e,this.displayedColumnsRight):this.displayedColumnsRight}isColSpanActive(){return this.colSpanActive}getDisplayedColumnsForRow(e,t,i,r){const n=[];let s=null;for(let o=0;o<t.length;o++){const a=t[o],l=t.length-o,c=Math.min(a.getColSpan(e),l),u=[a];if(c>1){const e=c-1;for(let i=1;i<=e;i++)u.push(t[o+i]);o+=e}let h;i?(h=!1,u.forEach(e=>{i(e)&&(h=!0)})):h=!0,h&&(0===n.length&&s&&r&&r(a)&&n.push(s),n.push(a)),s=a}return n}getViewportCenterColumnsForRow(e){if(!this.colSpanActive)return this.viewportColumnsCenter;const t=this.isColumnVirtualisationSuppressed()?null:this.isColumnInRowViewport.bind(this);return this.getDisplayedColumnsForRow(e,this.displayedColumnsCenter,t,e=>{const t=e.getLeft();return C(t)&&t>this.viewportLeft})}isColumnAtEdge(e,t){const i=this.getAllDisplayedColumns();if(!i.length)return!1;const r="first"===t;let n;if(e instanceof at){const t=e.getDisplayedLeafColumns();if(!t.length)return!1;n=r?t[0]:_e(t)}else n=e;return(r?i[0]:_e(i))===n}getAriaColumnIndex(e){let t;return t=e instanceof at?e.getLeafColumns()[0]:e,this.ariaOrderColumns.indexOf(t)+1}isColumnInHeaderViewport(e){return!!e.isAutoHeaderHeight()||this.isColumnInRowViewport(e)}isColumnInRowViewport(e){if(e.isAutoHeight())return!0;const t=e.getLeft()||0,i=t+e.getActualWidth(),r=this.viewportLeft-200,n=this.viewportRight+200;return!(t<r&&i<r||t>n&&i>n)}getDisplayedColumnsLeftWidth(){return this.getWidthOfColsInList(this.displayedColumnsLeft)}getDisplayedColumnsRightWidth(){return this.getWidthOfColsInList(this.displayedColumnsRight)}updatePrimaryColumnList(e,t,i,r,n,s){if(!e||w(e))return;let o=!1;if(e.forEach(e=>{if(!e)return;const n=this.getPrimaryColumn(e);if(n){if(i){if(t.indexOf(n)>=0)return;t.push(n)}else{if(t.indexOf(n)<0)return;Ne(t,n)}r(n),o=!0}}),!o)return;this.autoGroupsNeedBuilding&&this.updateGridColumns(),this.updateDisplayedColumns(s);const a={type:n,columns:t,column:1===t.length?t[0]:null,source:s};this.eventService.dispatchEvent(a)}setRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.setPrimaryColumnList(e,this.rowGroupColumns,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,!0,this.setRowGroupActive.bind(this),t)}setRowGroupActive(e,t,i){e!==t.isRowGroupActive()&&(t.setRowGroupActive(e,i),e&&!this.gos.get("suppressRowGroupHidesColumns")&&this.setColumnsVisible([t],!1,i),e||this.gos.get("suppressMakeColumnVisibleAfterUnGroup")||this.setColumnsVisible([t],!0,i))}addRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.updatePrimaryColumnList(e,this.rowGroupColumns,!0,this.setRowGroupActive.bind(this,!0),lt.EVENT_COLUMN_ROW_GROUP_CHANGED,t)}removeRowGroupColumns(e,t){this.autoGroupsNeedBuilding=!0,this.updatePrimaryColumnList(e,this.rowGroupColumns,!1,this.setRowGroupActive.bind(this,!1),lt.EVENT_COLUMN_ROW_GROUP_CHANGED,t)}addPivotColumns(e,t){this.updatePrimaryColumnList(e,this.pivotColumns,!0,e=>e.setPivotActive(!0,t),lt.EVENT_COLUMN_PIVOT_CHANGED,t)}setPivotColumns(e,t){this.setPrimaryColumnList(e,this.pivotColumns,lt.EVENT_COLUMN_PIVOT_CHANGED,!0,(e,i)=>{i.setPivotActive(e,t)},t)}removePivotColumns(e,t){this.updatePrimaryColumnList(e,this.pivotColumns,!1,e=>e.setPivotActive(!1,t),lt.EVENT_COLUMN_PIVOT_CHANGED,t)}setPrimaryColumnList(e,t,i,r,n,s){if(!this.gridColumns)return;const o=new Map;t.forEach((e,t)=>o.set(e,t)),t.length=0,C(e)&&e.forEach(e=>{const i=this.getPrimaryColumn(e);i&&t.push(i)}),t.forEach((e,t)=>{const i=o.get(e);void 0!==i?r&&i!==t||o.delete(e):o.set(e,0)}),(this.primaryColumns||[]).forEach(e=>{const i=t.indexOf(e)>=0;n(i,e)}),this.autoGroupsNeedBuilding&&this.updateGridColumns(),this.updateDisplayedColumns(s),this.dispatchColumnChangedEvent(i,[...o.keys()],s)}setValueColumns(e,t){this.setPrimaryColumnList(e,this.valueColumns,lt.EVENT_COLUMN_VALUE_CHANGED,!1,this.setValueActive.bind(this),t)}setValueActive(e,t,i){if(e!==t.isValueActive()&&(t.setValueActive(e,i),e&&!t.getAggFunc()&&this.aggFuncService)){const e=this.aggFuncService.getDefaultAggFunc(t);t.setAggFunc(e)}}addValueColumns(e,t){this.updatePrimaryColumnList(e,this.valueColumns,!0,this.setValueActive.bind(this,!0),lt.EVENT_COLUMN_VALUE_CHANGED,t)}removeValueColumns(e,t){this.updatePrimaryColumnList(e,this.valueColumns,!1,this.setValueActive.bind(this,!1),lt.EVENT_COLUMN_VALUE_CHANGED,t)}normaliseColumnWidth(e,t){const i=e.getMinWidth();C(i)&&t<i&&(t=i);const r=e.getMaxWidth();return C(r)&&e.isGreaterThanMax(t)&&(t=r),t}getPrimaryOrGridColumn(e){return this.getPrimaryColumn(e)||this.getGridColumn(e)}setColumnWidths(e,t,i,r){const n=[];e.forEach(e=>{const i=this.getPrimaryOrGridColumn(e.key);if(i&&(n.push({width:e.newWidth,ratios:[1],columns:[i]}),"shift"===this.gos.get("colResizeDefault")&&(t=!t),t)){const t=this.getDisplayedColAfter(i);if(!t)return;const r=i.getActualWidth()-e.newWidth,s=t.getActualWidth()+r;n.push({width:s,ratios:[1],columns:[t]})}}),0!==n.length&&this.resizeColumnSets({resizeSets:n,finished:i,source:r})}checkMinAndMaxWidthsForSet(e){const{columns:t,width:i}=e;let r=0,n=0,s=!0;return t.forEach(e=>{const t=e.getMinWidth();r+=t||0;const i=e.getMaxWidth();C(i)&&i>0?n+=i:s=!1}),i>=r&&(!s||i<=n)}resizeColumnSets(e){const{resizeSets:t,finished:i,source:r}=e;if(t&&!t.every(e=>this.checkMinAndMaxWidthsForSet(e))){if(i){const e=t&&t.length>0?t[0].columns:null;this.dispatchColumnResizedEvent(e,i,r)}return}const n=[],s=[];t.forEach(e=>{const{width:t,columns:i,ratios:o}=e,a={},l={};i.forEach(e=>s.push(e));let c=!0,u=0;for(;c;){if(u++,u>1e3){console.error("AG Grid: infinite loop in resizeColumnSets");break}c=!1;const e=[];let r=0,n=t;i.forEach((t,i)=>{if(l[t.getId()])n-=a[t.getId()];else{e.push(t);const n=o[i];r+=n}});const s=1/r;e.forEach((i,r)=>{let u;r===e.length-1?u=n:(u=Math.round(o[r]*t*s),n-=u);const h=i.getMinWidth(),d=i.getMaxWidth();C(h)&&u<h?(u=h,l[i.getId()]=!0,c=!0):C(d)&&d>0&&u>d&&(u=d,l[i.getId()]=!0,c=!0),a[i.getId()]=u})}i.forEach(e=>{const t=a[e.getId()];e.getActualWidth()!==t&&(e.setActualWidth(t,r),n.push(e))})});const o=n.length>0;let a=[];o&&(a=this.refreshFlexedColumns({resizingCols:s,skipSetLeft:!0}),this.setLeftValues(r),this.updateBodyWidths(),this.checkViewportColumns());const l=s.concat(a);(o||i)&&this.dispatchColumnResizedEvent(l,i,r,a)}setColumnAggFunc(e,t,i){if(!e)return;const r=this.getPrimaryColumn(e);r&&(r.setAggFunc(t),this.dispatchColumnChangedEvent(lt.EVENT_COLUMN_VALUE_CHANGED,[r],i))}moveRowGroupColumn(e,t,i){if(this.isRowGroupEmpty())return;const r=this.rowGroupColumns[e],n=this.rowGroupColumns.slice(e,t);this.rowGroupColumns.splice(e,1),this.rowGroupColumns.splice(t,0,r);const s={type:lt.EVENT_COLUMN_ROW_GROUP_CHANGED,columns:n,column:1===n.length?n[0]:null,source:i};this.eventService.dispatchEvent(s)}moveColumns(e,t,i,r=!0){if(!this.gridColumns)return;if(this.columnAnimationService.start(),t>this.gridColumns.length-e.length)return console.warn("AG Grid: tried to insert columns in invalid location, toIndex = "+t),void console.warn("AG Grid: remember that you should not count the moving columns when calculating the new index");const n=this.getGridColumns(e);!this.doesMovePassRules(n,t)||(Ve(this.gridColumns,n,t),this.updateDisplayedColumns(i),this.dispatchColumnMovedEvent({movedColumns:n,source:i,toIndex:t,finished:r}),this.columnAnimationService.finish())}doesMovePassRules(e,t){const i=this.getProposedColumnOrder(e,t);return this.doesOrderPassRules(i)}doesOrderPassRules(e){return!!this.doesMovePassMarryChildren(e)&&!!this.doesMovePassLockedPositions(e)}getProposedColumnOrder(e,t){const i=this.gridColumns.slice();return Ve(i,e,t),i}sortColumnsLikeGridColumns(e){!e||e.length<=1||e.filter(e=>this.gridColumns.indexOf(e)<0).length>0||e.sort((e,t)=>this.gridColumns.indexOf(e)-this.gridColumns.indexOf(t))}doesMovePassLockedPositions(e){let t=0,i=!0;return e.forEach(e=>{const r=(n=e.getColDef().lockPosition)?!0===n||"left"===n?0:2:1;var n;r<t&&(i=!1),t=r}),i}doesMovePassMarryChildren(e){let t=!0;return st(null,this.gridBalancedTree,i=>{if(!(i instanceof Ee))return;const r=i,n=r.getColGroupDef();if(!n||!n.marryChildren)return;const s=[];r.getLeafColumns().forEach(t=>{const i=e.indexOf(t);s.push(i)}),Math.max.apply(Math,s)-Math.min.apply(Math,s)>r.getLeafColumns().length-1&&(t=!1)}),t}moveColumnByIndex(e,t,i){if(!this.gridColumns)return;const r=this.gridColumns[e];this.moveColumns([r],t,i)}getColumnDefs(){if(!this.primaryColumns)return;const e=this.primaryColumns.slice();return this.gridColsArePrimary?e.sort((e,t)=>this.gridColumns.indexOf(e)-this.gridColumns.indexOf(t)):this.lastPrimaryOrder&&e.sort((e,t)=>this.lastPrimaryOrder.indexOf(e)-this.lastPrimaryOrder.indexOf(t)),this.columnDefFactory.buildColumnDefs(e,this.rowGroupColumns,this.pivotColumns)}getBodyContainerWidth(){return this.bodyWidth}getContainerWidth(e){switch(e){case"left":return this.leftWidth;case"right":return this.rightWidth;default:return this.bodyWidth}}updateBodyWidths(){const e=this.getWidthOfColsInList(this.displayedColumnsCenter),t=this.getWidthOfColsInList(this.displayedColumnsLeft),i=this.getWidthOfColsInList(this.displayedColumnsRight);if(this.bodyWidthDirty=this.bodyWidth!==e,this.bodyWidth!==e||this.leftWidth!==t||this.rightWidth!==i){this.bodyWidth=e,this.leftWidth=t,this.rightWidth=i;const r={type:lt.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED};this.eventService.dispatchEvent(r);const n={type:lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED};this.eventService.dispatchEvent(n)}}getValueColumns(){return this.valueColumns?this.valueColumns:[]}getPivotColumns(){return this.pivotColumns?this.pivotColumns:[]}isPivotActive(){return this.pivotColumns&&this.pivotColumns.length>0&&this.pivotMode}getRowGroupColumns(){return this.rowGroupColumns?this.rowGroupColumns:[]}getDisplayedCenterColumns(){return this.displayedColumnsCenter}getDisplayedLeftColumns(){return this.displayedColumnsLeft}getDisplayedRightColumns(){return this.displayedColumnsRight}getAllPrimaryColumns(){return this.primaryColumns?this.primaryColumns:null}getSecondaryColumns(){return this.secondaryColumns?this.secondaryColumns:null}getAllColumnsForQuickFilter(){return this.columnsForQuickFilter}getAllGridColumns(){var e;return null!=(e=this.gridColumns)?e:[]}isRowGroupEmpty(){return w(this.rowGroupColumns)}setColumnsVisible(e,t=!1,i){this.applyColumnState({state:e.map(e=>({colId:"string"==typeof e?e:e.getColId(),hide:!t}))},i)}setColumnsPinned(e,t,i){if(!this.gridColumns)return;if(this.gos.isDomLayout("print"))return void console.warn("AG Grid: Changing the column pinning status is not allowed with domLayout='print'");let r;this.columnAnimationService.start(),r=!0===t||"left"===t?"left":"right"===t?"right":null,this.actionOnGridColumns(e,e=>e.getPinned()!==r&&(e.setPinned(r),!0),i,()=>({type:lt.EVENT_COLUMN_PINNED,pinned:r,column:null,columns:null,source:i})),this.columnAnimationService.finish()}actionOnGridColumns(e,t,i,r){if(w(e))return;const n=[];if(e.forEach(e=>{if(!e)return;const i=this.getGridColumn(e);i&&!1!==t(i)&&n.push(i)}),n.length&&(this.updateDisplayedColumns(i),C(r)&&r)){const e=r();e.columns=n,e.column=1===n.length?n[0]:null,this.eventService.dispatchEvent(e)}}getDisplayedColBefore(e){const t=this.getAllDisplayedColumns(),i=t.indexOf(e);return i>0?t[i-1]:null}getDisplayedColAfter(e){const t=this.getAllDisplayedColumns(),i=t.indexOf(e);return i<t.length-1?t[i+1]:null}getDisplayedGroupAtDirection(e,t){const i=e.getProvidedColumnGroup().getLevel()+e.getPaddingLevel(),r=e.getDisplayedLeafColumns(),n="After"===t?_e(r):r[0],s=`getDisplayedCol${t}`;for(;;){const t=this[s](n);if(!t)return null;const r=this.getColumnGroupAtLevel(t,i);if(r!==e)return r}}getColumnGroupAtLevel(e,t){let i,r,n=e.getParent();for(;i=n.getProvidedColumnGroup().getLevel(),r=n.getPaddingLevel(),!(i+r<=t);)n=n.getParent();return n}isPinningLeft(){return this.displayedColumnsLeft.length>0}isPinningRight(){return this.displayedColumnsRight.length>0}getPrimaryAndSecondaryAndAutoColumns(){return[].concat(this.primaryColumns||[],this.groupAutoColumns||[],this.secondaryColumns||[])}createStateItemFromColumn(e){const t=e.isRowGroupActive()?this.rowGroupColumns.indexOf(e):null,i=e.isPivotActive()?this.pivotColumns.indexOf(e):null,r=e.isValueActive()?e.getAggFunc():null,n=null!=e.getSort()?e.getSort():null,s=null!=e.getSortIndex()?e.getSortIndex():null,o=null!=e.getFlex()&&e.getFlex()>0?e.getFlex():null;return{colId:e.getColId(),width:e.getActualWidth(),hide:!e.isVisible(),pinned:e.getPinned(),sort:n,sortIndex:s,aggFunc:r,rowGroup:e.isRowGroupActive(),rowGroupIndex:t,pivot:e.isPivotActive(),pivotIndex:i,flex:o}}getColumnState(){if(y(this.primaryColumns)||!this.isAlive())return[];const e=this.getPrimaryAndSecondaryAndAutoColumns().map(this.createStateItemFromColumn.bind(this));return this.orderColumnStateList(e),e}orderColumnStateList(e){const t=bt(this.gridColumns.map((e,t)=>[e.getColId(),t]));e.sort((e,i)=>(t.has(e.colId)?t.get(e.colId):-1)-(t.has(i.colId)?t.get(i.colId):-1))}resetColumnState(e){if(w(this.primaryColumns))return;const t=this.getColumnsFromTree(this.primaryColumnTree),i=[];let r=1e3,n=1e3,s=[];this.groupAutoColumns&&(s=s.concat(this.groupAutoColumns)),t&&(s=s.concat(t)),s.forEach(e=>{const t=this.getColumnStateFromColDef(e);y(t.rowGroupIndex)&&t.rowGroup&&(t.rowGroupIndex=r++),y(t.pivotIndex)&&t.pivot&&(t.pivotIndex=n++),i.push(t)}),this.applyColumnState({state:i,applyOrder:!0},e)}getColumnStateFromColDef(e){const t=(e,t)=>null!=e?e:null!=t?t:null,i=e.getColDef(),r=t(i.sort,i.initialSort),n=t(i.sortIndex,i.initialSortIndex),s=t(i.hide,i.initialHide),o=t(i.pinned,i.initialPinned),a=t(i.width,i.initialWidth),l=t(i.flex,i.initialFlex);let c=t(i.rowGroupIndex,i.initialRowGroupIndex),u=t(i.rowGroup,i.initialRowGroup);null!=c||null!=u&&0!=u||(c=null,u=null);let h=t(i.pivotIndex,i.initialPivotIndex),d=t(i.pivot,i.initialPivot);null!=h||null!=d&&0!=d||(h=null,d=null);const p=t(i.aggFunc,i.initialAggFunc);return{colId:e.getColId(),sort:r,sortIndex:n,hide:s,pinned:o,width:a,flex:l,rowGroup:u,rowGroupIndex:c,pivot:d,pivotIndex:h,aggFunc:p}}applyColumnState(e,t){if(w(this.primaryColumns))return!1;if(e&&e.state&&!e.state.forEach)return console.warn("AG Grid: applyColumnState() - the state attribute should be an array, however an array was not found. Please provide an array of items (one for each col you want to change) for state."),!1;const i=(i,r,n)=>{const s=this.compareColumnStatesAndDispatchEvents(t);this.autoGroupsNeedBuilding=!0;const o=r.slice(),a={},l={},c=[],u=[];let h=0;const d=this.rowGroupColumns.slice(),p=this.pivotColumns.slice();i.forEach(i=>{const r=i.colId||"";if(r.startsWith(ht))return c.push(i),void u.push(i);const s=n(r);s?(this.syncColumnWithStateItem(s,i,e.defaultState,a,l,!1,t),Ne(o,s)):(u.push(i),h+=1)});const g=i=>this.syncColumnWithStateItem(i,null,e.defaultState,a,l,!1,t);o.forEach(g);const f=(e,t,i,r)=>{const n=e[i.getId()],s=e[r.getId()],o=null!=n,a=null!=s;if(o&&a)return n-s;if(o)return-1;if(a)return 1;const l=t.indexOf(i),c=t.indexOf(r),u=l>=0;return u&&c>=0?l-c:u?-1:1};this.rowGroupColumns.sort(f.bind(this,a,d)),this.pivotColumns.sort(f.bind(this,l,p)),this.updateGridColumns();const m=this.groupAutoColumns?this.groupAutoColumns.slice():[];return c.forEach(i=>{const r=this.getAutoColumn(i.colId);Ne(m,r),this.syncColumnWithStateItem(r,i,e.defaultState,null,null,!0,t)}),m.forEach(g),this.applyOrderAfterApplyState(e),this.updateDisplayedColumns(t),this.dispatchEverythingChanged(t),s(),{unmatchedAndAutoStates:u,unmatchedCount:h}};this.columnAnimationService.start();let{unmatchedAndAutoStates:r,unmatchedCount:n}=i(e.state||[],this.primaryColumns||[],e=>this.getPrimaryColumn(e));return(r.length>0||C(e.defaultState))&&(n=i(r,this.secondaryColumns||[],e=>this.getSecondaryColumn(e)).unmatchedCount),this.columnAnimationService.finish(),0===n}applyOrderAfterApplyState(e){if(!e.applyOrder||!e.state)return;let t=[];const i={};e.state.forEach(e=>{if(!e.colId||i[e.colId])return;const r=this.gridColumnsMap[e.colId];r&&(t.push(r),i[e.colId]=!0)});let r=0;this.gridColumns.forEach(e=>{const n=e.getColId();null==i[n]&&(n.startsWith(ht)?ke(t,e,r++):t.push(e))}),t=this.placeLockedColumns(t),this.doesMovePassMarryChildren(t)?this.gridColumns=t:console.warn("AG Grid: Applying column order broke a group where columns should be married together. Applying new order has been discarded.")}compareColumnStatesAndDispatchEvents(e){const t={rowGroupColumns:this.rowGroupColumns.slice(),pivotColumns:this.pivotColumns.slice(),valueColumns:this.valueColumns.slice()},i=this.getColumnState(),r={};return i.forEach(e=>{r[e.colId]=e}),()=>{const n=this.getPrimaryAndSecondaryAndAutoColumns(),s=(t,i,r,n)=>{if(Pe(i.map(n),r.map(n)))return;const s=new Set(i);r.forEach(e=>{s.delete(e)||s.add(e)});const o=[...s],a={type:t,columns:o,column:1===o.length?o[0]:null,source:e};this.eventService.dispatchEvent(a)},o=e=>{const t=[];return n.forEach(i=>{const n=r[i.getColId()];n&&e(n,i)&&t.push(i)}),t},a=e=>e.getColId();s(lt.EVENT_COLUMN_ROW_GROUP_CHANGED,t.rowGroupColumns,this.rowGroupColumns,a),s(lt.EVENT_COLUMN_PIVOT_CHANGED,t.pivotColumns,this.pivotColumns,a);const l=o((e,t)=>{const i=null!=e.aggFunc,r=i!=t.isValueActive(),n=i&&e.aggFunc!=t.getAggFunc();return r||n});l.length>0&&this.dispatchColumnChangedEvent(lt.EVENT_COLUMN_VALUE_CHANGED,l,e),this.dispatchColumnResizedEvent(o((e,t)=>e.width!=t.getActualWidth()),!0,e),this.dispatchColumnPinnedEvent(o((e,t)=>e.pinned!=t.getPinned()),e),this.dispatchColumnVisibleEvent(o((e,t)=>e.hide==t.isVisible()),e);const c=o((e,t)=>e.sort!=t.getSort()||e.sortIndex!=t.getSortIndex());c.length>0&&this.sortController.dispatchSortChangedEvents(e,c),this.normaliseColumnMovedEventForColumnState(i,e)}}getCommonValue(e,t){if(!e||0==e.length)return;const i=t(e[0]);for(let r=1;r<e.length;r++)if(i!==t(e[r]))return;return i}normaliseColumnMovedEventForColumnState(e,t){const i=this.getColumnState(),r={};i.forEach(e=>r[e.colId]=e);const n={};e.forEach(e=>{r[e.colId]&&(n[e.colId]=!0)});const s=e.filter(e=>n[e.colId]),o=i.filter(e=>n[e.colId]),a=[];o.forEach((e,t)=>{const i=s&&s[t];if(i&&i.colId!==e.colId){const e=this.getGridColumn(i.colId);e&&a.push(e)}}),a.length&&this.dispatchColumnMovedEvent({movedColumns:a,source:t,finished:!0})}syncColumnWithStateItem(e,t,i,r,n,s,o){var a;if(!e)return;const l=(e,r)=>{const n={value1:void 0,value2:void 0};let s=!1;return t&&(void 0!==t[e]&&(n.value1=t[e],s=!0),C(r)&&void 0!==t[r]&&(n.value2=t[r],s=!0)),!s&&i&&(void 0!==i[e]&&(n.value1=i[e]),C(r)&&void 0!==i[r]&&(n.value2=i[r])),n},c=l("hide").value1;void 0!==c&&e.setVisible(!c,o);const u=l("pinned").value1;void 0!==u&&e.setPinned(u);const h=null!=(a=e.getColDef().minWidth)?a:this.environment.getMinColWidth(),d=l("flex").value1;if(void 0!==d&&e.setFlex(d),null==d){const t=l("width").value1;null!=t&&null!=h&&t>=h&&e.setActualWidth(t,o)}const p=l("sort").value1;void 0!==p&&("desc"===p||"asc"===p?e.setSort(p,o):e.setSort(void 0,o));const g=l("sortIndex").value1;if(void 0!==g&&e.setSortIndex(g),s||!e.isPrimary())return;const f=l("aggFunc").value1;void 0!==f&&("string"==typeof f?(e.setAggFunc(f),e.isValueActive()||(e.setValueActive(!0,o),this.valueColumns.push(e))):(C(f)&&console.warn("AG Grid: stateItem.aggFunc must be a string. if using your own aggregation functions, register the functions first before using them in get/set state. This is because it is intended for the column state to be stored and retrieved as simple JSON."),e.isValueActive()&&(e.setValueActive(!1,o),Ne(this.valueColumns,e))));const{value1:m,value2:v}=l("rowGroup","rowGroupIndex");void 0===m&&void 0===v||("number"==typeof v||m?(e.isRowGroupActive()||(e.setRowGroupActive(!0,o),this.rowGroupColumns.push(e)),r&&"number"==typeof v&&(r[e.getId()]=v)):e.isRowGroupActive()&&(e.setRowGroupActive(!1,o),Ne(this.rowGroupColumns,e)));const{value1:y,value2:w}=l("pivot","pivotIndex");void 0===y&&void 0===w||("number"==typeof w||y?(e.isPivotActive()||(e.setPivotActive(!0,o),this.pivotColumns.push(e)),n&&"number"==typeof w&&(n[e.getId()]=w)):e.isPivotActive()&&(e.setPivotActive(!1,o),Ne(this.pivotColumns,e)))}getGridColumns(e){return this.getColumns(e,this.getGridColumn.bind(this))}getColumns(e,t){const i=[];return e&&e.forEach(e=>{const r=t(e);r&&i.push(r)}),i}getColumnWithValidation(e){if(null==e)return null;const t=this.getGridColumn(e);return t||console.warn("AG Grid: could not find column "+e),t}getPrimaryColumn(e){return this.primaryColumns?this.getColumn(e,this.primaryColumns,this.primaryColumnsMap):null}getGridColumn(e){return this.getColumn(e,this.gridColumns,this.gridColumnsMap)}lookupGridColumn(e){return this.gridColumnsMap[e]}getSecondaryColumn(e){return this.secondaryColumns?this.getColumn(e,this.secondaryColumns,this.secondaryColumnsMap):null}getColumn(e,t,i){if(!e||!i)return null;if("string"==typeof e&&i[e])return i[e];for(let i=0;i<t.length;i++)if(this.columnsMatch(t[i],e))return t[i];return this.getAutoColumn(e)}getSourceColumnsForGroupColumn(e){const t=e.getColDef().showRowGroup;if(!t)return null;if(!0===t)return this.rowGroupColumns.slice(0);const i=this.getPrimaryColumn(t);return i?[i]:null}getAutoColumn(e){return this.groupAutoColumns&&C(this.groupAutoColumns)&&!y(this.groupAutoColumns)&&this.groupAutoColumns.find(t=>this.columnsMatch(t,e))||null}columnsMatch(e,t){const i=e===t,r=e.getColDef()===t,n=e.getColId()==t;return i||r||n}getDisplayNameForColumn(e,t,i=!1){if(!e)return null;const r=this.getHeaderName(e.getColDef(),e,null,null,t);return i?this.wrapHeaderNameWithAggFunc(e,r):r}getDisplayNameForProvidedColumnGroup(e,t,i){const r=t?t.getColGroupDef():null;return r?this.getHeaderName(r,null,e,t,i):null}getDisplayNameForColumnGroup(e,t){return this.getDisplayNameForProvidedColumnGroup(e,e.getProvidedColumnGroup(),t)}getHeaderName(e,t,i,r,n){const s=e.headerValueGetter;if(s){const o=this.gos.addGridCommonParams({colDef:e,column:t,columnGroup:i,providedColumnGroup:r,location:n});return"function"==typeof s?s(o):"string"==typeof s?this.expressionService.evaluate(s,o):(console.warn("AG Grid: headerValueGetter must be a function or a string"),"")}return null!=e.headerName?e.headerName:e.field?yt(e.field):""}wrapHeaderNameWithAggFunc(e,t){if(this.gos.get("suppressAggFuncInHeader"))return t;const i=e.getColDef().pivotValueColumn;let r,n=null;if(C(i)){const s=this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&1===this.valueColumns.length,o=void 0!==e.getColDef().pivotTotalColumnIds;if(s&&!o)return t;n=i?i.getAggFunc():null,r=!0}else{const t=e.isValueActive(),i=this.pivotMode||!this.isRowGroupEmpty();t&&i?(n=e.getAggFunc(),r=!0):r=!1}if(r){const e="string"==typeof n?n:"func";return`${this.localeService.getLocaleTextFunc()(e,e)}(${t})`}return t}getColumnGroup(e,t){if(!e)return null;if(e instanceof at)return e;const i=this.getAllDisplayedTrees(),r="number"==typeof t;let n=null;return Rt(i,!1,i=>{if(i instanceof at){const s=i;let o;o=r?e===s.getGroupId()&&t===s.getPartId():e===s.getGroupId(),o&&(n=s)}}),n}isReady(){return this.ready}extractValueColumns(e,t){this.valueColumns=this.extractColumns(t,this.valueColumns,(t,i)=>t.setValueActive(i,e),()=>{},()=>{},e=>{const t=e.aggFunc;return null===t||""===t?null:void 0!==t?!!t:void 0},e=>null!=e.initialAggFunc&&""!=e.initialAggFunc),this.valueColumns.forEach(e=>{const t=e.getColDef();null!=t.aggFunc&&""!=t.aggFunc?e.setAggFunc(t.aggFunc):e.getAggFunc()||e.setAggFunc(t.initialAggFunc)})}extractRowGroupColumns(e,t){this.rowGroupColumns=this.extractColumns(t,this.rowGroupColumns,(t,i)=>t.setRowGroupActive(i,e),e=>e.rowGroupIndex,e=>e.initialRowGroupIndex,e=>e.rowGroup,e=>e.initialRowGroup)}extractColumns(e=[],t=[],i,r,n,s,o){const a=[],l=[];(this.primaryColumns||[]).forEach(i=>{const c=e.indexOf(i)<0,u=i.getColDef(),h=E(s(u)),d=E(o(u)),p=b(r(u)),g=b(n(u));let f;f=void 0!==h?h:void 0!==p?null!==p&&p>=0:c?void 0!==d?d:!(void 0===g)&&null!=g&&g>=0:t.indexOf(i)>=0,f&&((c?null!=p||null!=g:null!=p)?a.push(i):l.push(i))});const c=e=>{const t=r(e.getColDef()),i=n(e.getColDef());return null!=t?t:i};a.sort((e,t)=>{const i=c(e),r=c(t);return i===r?0:i<r?-1:1});const u=[].concat(a);return t.forEach(e=>{l.indexOf(e)>=0&&u.push(e)}),l.forEach(e=>{u.indexOf(e)<0&&u.push(e)}),t.forEach(e=>{u.indexOf(e)<0&&i(e,!1)}),u.forEach(e=>{t.indexOf(e)<0&&i(e,!0)}),u}extractPivotColumns(e,t){this.pivotColumns=this.extractColumns(t,this.pivotColumns,(t,i)=>t.setPivotActive(i,e),e=>e.pivotIndex,e=>e.initialPivotIndex,e=>e.pivot,e=>e.initialPivot)}resetColumnGroupState(e){if(!this.primaryColumnTree)return;const t=[];st(null,this.primaryColumnTree,e=>{if(e instanceof Ee){const i=e.getColGroupDef(),r={groupId:e.getGroupId(),open:i?i.openByDefault:void 0};t.push(r)}}),this.setColumnGroupState(t,e)}getColumnGroupState(){const e=[];return st(null,this.gridBalancedTree,t=>{t instanceof Ee&&e.push({groupId:t.getGroupId(),open:t.isExpanded()})}),e}setColumnGroupState(e,t){if(!this.gridBalancedTree)return;this.columnAnimationService.start();const i=[];if(e.forEach(e=>{const t=e.groupId,r=e.open,n=this.getProvidedColumnGroup(t);n&&n.isExpanded()!==r&&(this.logger.log("columnGroupOpened("+n.getGroupId()+","+r+")"),n.setExpanded(r),i.push(n))}),this.updateGroupsAndDisplayedColumns(t),this.setFirstRightAndLastLeftPinned(t),i.length){const e={type:lt.EVENT_COLUMN_GROUP_OPENED,columnGroup:1===Ee.length?i[0]:void 0,columnGroups:i};this.eventService.dispatchEvent(e)}this.columnAnimationService.finish()}setColumnGroupOpened(e,t,i){let r;r=e instanceof Ee?e.getId():e||"",this.setColumnGroupState([{groupId:r,open:t}],i)}getProvidedColumnGroup(e){"string"!=typeof e&&console.error("AG Grid: group key must be a string");let t=null;return st(null,this.gridBalancedTree,i=>{i instanceof Ee&&i.getId()===e&&(t=i)}),t}calculateColumnsForDisplay(){let e;return e=this.pivotMode&&y(this.secondaryColumns)?this.gridColumns.filter(e=>{const t=this.groupAutoColumns&&He(this.groupAutoColumns,e),i=this.valueColumns&&He(this.valueColumns,e);return t||i}):this.gridColumns.filter(e=>this.groupAutoColumns&&He(this.groupAutoColumns,e)||e.isVisible()),e}checkColSpanActiveInCols(e){let t=!1;return e.forEach(e=>{C(e.getColDef().colSpan)&&(t=!0)}),t}calculateColumnsForGroupDisplay(){this.groupDisplayColumns=[],this.groupDisplayColumnsMap={},this.gridColumns.forEach(e=>{const t=e.getColDef(),i=t.showRowGroup;t&&C(i)&&(this.groupDisplayColumns.push(e),"string"==typeof i?this.groupDisplayColumnsMap[i]=e:!0===i&&this.getRowGroupColumns().forEach(t=>{this.groupDisplayColumnsMap[t.getId()]=e}))})}getGroupDisplayColumns(){return this.groupDisplayColumns}getGroupDisplayColumnForGroup(e){return this.groupDisplayColumnsMap[e]}updateDisplayedColumns(e){const t=this.calculateColumnsForDisplay();this.buildDisplayedTrees(t),this.updateGroupsAndDisplayedColumns(e),this.setFirstRightAndLastLeftPinned(e)}isSecondaryColumnsPresent(){return C(this.secondaryColumns)}setSecondaryColumns(e,t){if(!this.gridColumns)return;const i=e;if(i||!y(this.secondaryColumns)){if(i){this.processSecondaryColumnDefinitions(e);const i=this.columnFactory.createColumnTree(e,!1,this.secondaryBalancedTree||this.previousSecondaryColumns||void 0,t);this.destroyOldColumns(this.secondaryBalancedTree,i.columnTree),this.secondaryBalancedTree=i.columnTree,this.secondaryHeaderRowCount=i.treeDept+1,this.secondaryColumns=this.getColumnsFromTree(this.secondaryBalancedTree),this.secondaryColumnsMap={},this.secondaryColumns.forEach(e=>this.secondaryColumnsMap[e.getId()]=e),this.previousSecondaryColumns=null}else this.previousSecondaryColumns=this.secondaryBalancedTree,this.secondaryBalancedTree=null,this.secondaryHeaderRowCount=-1,this.secondaryColumns=null,this.secondaryColumnsMap={};this.updateGridColumns(),this.updateDisplayedColumns(t)}}processSecondaryColumnDefinitions(e){const t=this.gos.get("processPivotResultColDef"),i=this.gos.get("processPivotResultColGroupDef");if(!t&&!i)return;const r=e=>{e.forEach(e=>{if(C(e.children)){const t=e;i&&i(t),r(t.children)}else t&&t(e)})};e&&r(e)}updateGridColumns(){const e=this.gridBalancedTree;if(this.gridColsArePrimary?this.lastPrimaryOrder=this.gridColumns:this.lastSecondaryOrder=this.gridColumns,this.createGroupAutoColumnsIfNeeded()){const e=bt(this.groupAutoColumns.map(e=>[e,!0]));this.lastPrimaryOrder&&(this.lastPrimaryOrder=this.lastPrimaryOrder.filter(t=>!e.has(t)),this.lastPrimaryOrder=[...this.groupAutoColumns,...this.lastPrimaryOrder]),this.lastSecondaryOrder&&(this.lastSecondaryOrder=this.lastSecondaryOrder.filter(t=>!e.has(t)),this.lastSecondaryOrder=[...this.groupAutoColumns,...this.lastSecondaryOrder])}let t;if(this.secondaryColumns&&this.secondaryBalancedTree){const e=this.secondaryColumns.some(e=>void 0!==this.gridColumnsMap[e.getColId()]);this.gridBalancedTree=this.secondaryBalancedTree.slice(),this.gridHeaderRowCount=this.secondaryHeaderRowCount,this.gridColumns=this.secondaryColumns.slice(),this.gridColsArePrimary=!1,e&&(t=this.lastSecondaryOrder)}else this.primaryColumns&&(this.gridBalancedTree=this.primaryColumnTree.slice(),this.gridHeaderRowCount=this.primaryHeaderRowCount,this.gridColumns=this.primaryColumns.slice(),this.gridColsArePrimary=!0,t=this.lastPrimaryOrder);if(this.addAutoGroupToGridColumns(),this.orderGridColsLike(t),this.gridColumns=this.placeLockedColumns(this.gridColumns),this.calculateColumnsForGroupDisplay(),this.refreshQuickFilterColumns(),this.clearDisplayedAndViewportColumns(),this.colSpanActive=this.checkColSpanActiveInCols(this.gridColumns),this.gridColumnsMap={},this.gridColumns.forEach(e=>this.gridColumnsMap[e.getId()]=e),this.setAutoHeightActive(),!Pe(e,this.gridBalancedTree)){const e={type:lt.EVENT_GRID_COLUMNS_CHANGED};this.eventService.dispatchEvent(e)}}setAutoHeightActive(){this.autoHeightActive=this.gridColumns.filter(e=>e.isAutoHeight()).length>0,this.autoHeightActive&&(this.autoHeightActiveAtLeastOnce=!0,this.gos.isRowModelType("clientSide")||this.gos.isRowModelType("serverSide")||z("autoHeight columns only work with Client Side Row Model and Server Side Row Model."))}orderGridColsLike(e){if(y(e))return;const t=bt(e.map((e,t)=>[e,t]));let i=!0;if(this.gridColumns.forEach(e=>{t.has(e)&&(i=!1)}),i)return;const r=bt(this.gridColumns.map(e=>[e,!0])),n=e.filter(e=>r.has(e)),s=bt(n.map(e=>[e,!0])),o=this.gridColumns.filter(e=>!s.has(e)),a=n.slice();o.forEach(e=>{let t=e.getOriginalParent();if(!t)return void a.push(e);const i=[];for(;!i.length&&t;)t.getLeafColumns().forEach(e=>{const t=a.indexOf(e)>=0,r=i.indexOf(e)<0;t&&r&&i.push(e)}),t=t.getOriginalParent();if(!i.length)return void a.push(e);const r=i.map(e=>a.indexOf(e)),n=Math.max(...r);ke(a,e,n+1)}),this.gridColumns=a}isPrimaryColumnGroupsPresent(){return this.primaryHeaderRowCount>1}refreshQuickFilterColumns(){var e;let t=null!=(e=this.isPivotMode()&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")?this.secondaryColumns:this.primaryColumns)?e:[];this.groupAutoColumns&&(t=t.concat(this.groupAutoColumns)),this.columnsForQuickFilter=this.gos.get("includeHiddenColumnsInQuickFilter")?t:t.filter(e=>e.isVisible()||e.isRowGroupActive())}placeLockedColumns(e){const t=[],i=[],r=[];return e.forEach(e=>{const n=e.getColDef().lockPosition;"right"===n?r.push(e):"left"===n||!0===n?t.push(e):i.push(e)}),[...t,...i,...r]}addAutoGroupToGridColumns(){if(y(this.groupAutoColumns))return this.destroyOldColumns(this.groupAutoColsBalancedTree),void(this.groupAutoColsBalancedTree=null);this.gridColumns=this.groupAutoColumns?this.groupAutoColumns.concat(this.gridColumns):this.gridColumns;const e=this.columnFactory.createForAutoGroups(this.groupAutoColumns,this.gridBalancedTree);this.destroyOldColumns(this.groupAutoColsBalancedTree,e),this.groupAutoColsBalancedTree=e,this.gridBalancedTree=e.concat(this.gridBalancedTree)}clearDisplayedAndViewportColumns(){this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={},this.displayedColumnsLeft=[],this.displayedColumnsRight=[],this.displayedColumnsCenter=[],this.displayedColumns=[],this.ariaOrderColumns=[],this.viewportColumns=[],this.headerViewportColumns=[],this.viewportColumnsHash=""}updateGroupsAndDisplayedColumns(e){this.updateOpenClosedVisibilityInColumnGroups(),this.deriveDisplayedColumns(e),this.refreshFlexedColumns(),this.extractViewport(),this.updateBodyWidths();const t={type:lt.EVENT_DISPLAYED_COLUMNS_CHANGED};this.eventService.dispatchEvent(t)}deriveDisplayedColumns(e){this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeLeft,this.displayedColumnsLeft),this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeCentre,this.displayedColumnsCenter),this.derivedDisplayedColumnsFromDisplayedTree(this.displayedTreeRight,this.displayedColumnsRight),this.joinColumnsAriaOrder(),this.joinDisplayedColumns(),this.setLeftValues(e),this.displayedAutoHeightCols=this.displayedColumns.filter(e=>e.isAutoHeight())}isAutoRowHeightActive(){return this.autoHeightActive}wasAutoRowHeightEverActive(){return this.autoHeightActiveAtLeastOnce}joinColumnsAriaOrder(){const e=this.getAllGridColumns(),t=[],i=[],r=[];for(const n of e){const e=n.getPinned();e?!0===e||"left"===e?t.push(n):r.push(n):i.push(n)}this.ariaOrderColumns=t.concat(i).concat(r)}joinDisplayedColumns(){this.gos.get("enableRtl")?this.displayedColumns=this.displayedColumnsRight.concat(this.displayedColumnsCenter).concat(this.displayedColumnsLeft):this.displayedColumns=this.displayedColumnsLeft.concat(this.displayedColumnsCenter).concat(this.displayedColumnsRight)}setLeftValues(e){this.setLeftValuesOfColumns(e),this.setLeftValuesOfGroups()}setLeftValuesOfColumns(e){if(!this.primaryColumns)return;const t=this.getPrimaryAndSecondaryAndAutoColumns().slice(0),i=this.gos.get("enableRtl");[this.displayedColumnsLeft,this.displayedColumnsRight,this.displayedColumnsCenter].forEach(r=>{if(i){let t=this.getWidthOfColsInList(r);r.forEach(i=>{t-=i.getActualWidth(),i.setLeft(t,e)})}else{let t=0;r.forEach(i=>{i.setLeft(t,e),t+=i.getActualWidth()})}Oe(t,r)}),t.forEach(t=>{t.setLeft(null,e)})}setLeftValuesOfGroups(){[this.displayedTreeLeft,this.displayedTreeRight,this.displayedTreeCentre].forEach(e=>{e.forEach(e=>{e instanceof at&&e.checkLeft()})})}derivedDisplayedColumnsFromDisplayedTree(e,t){t.length=0,Rt(e,!0,e=>{e instanceof Se&&t.push(e)})}isColumnVirtualisationSuppressed(){return this.suppressColumnVirtualisation||0===this.viewportRight}extractViewportColumns(){this.isColumnVirtualisationSuppressed()?(this.viewportColumnsCenter=this.displayedColumnsCenter,this.headerViewportColumnsCenter=this.displayedColumnsCenter):(this.viewportColumnsCenter=this.displayedColumnsCenter.filter(this.isColumnInRowViewport.bind(this)),this.headerViewportColumnsCenter=this.displayedColumnsCenter.filter(this.isColumnInHeaderViewport.bind(this))),this.viewportColumns=this.viewportColumnsCenter.concat(this.displayedColumnsLeft).concat(this.displayedColumnsRight),this.headerViewportColumns=this.headerViewportColumnsCenter.concat(this.displayedColumnsLeft).concat(this.displayedColumnsRight)}getVirtualHeaderGroupRow(e,t){let i;switch(e){case"left":i=this.viewportRowLeft[t];break;case"right":i=this.viewportRowRight[t];break;default:i=this.viewportRowCenter[t]}return y(i)&&(i=[]),i}calculateHeaderRows(){this.viewportRowLeft={},this.viewportRowRight={},this.viewportRowCenter={};const e={};this.headerViewportColumns.forEach(t=>e[t.getId()]=!0);const t=(i,r,n)=>{let s=!1;for(let o=0;o<i.length;o++){const a=i[o];let l=!1;if(a instanceof Se)l=!0===e[a.getId()];else{const e=a.getDisplayedChildren();e&&(l=t(e,r,n+1))}l&&(s=!0,r[n]||(r[n]=[]),r[n].push(a))}return s};t(this.displayedTreeLeft,this.viewportRowLeft,0),t(this.displayedTreeRight,this.viewportRowRight,0),t(this.displayedTreeCentre,this.viewportRowCenter,0)}extractViewport(){this.extractViewportColumns();const e=this.viewportColumns.map(e=>`${e.getId()}-${e.getPinned()||"normal"}`).join("#"),t=this.viewportColumnsHash!==e;return t&&(this.viewportColumnsHash=e,this.calculateHeaderRows()),t}refreshFlexedColumns(e={}){var t;const i=e.source?e.source:"flex";if(null!=e.viewportWidth&&(this.flexViewportWidth=e.viewportWidth),!this.flexViewportWidth)return[];let r=-1;if(e.resizingCols){const t=new Set(e.resizingCols);let i=this.displayedColumnsCenter;for(let e=i.length-1;e>=0;e--)if(t.has(i[e])){r=e;break}}let n=0,s=[],o=0,a=0;for(let e=0;e<this.displayedColumnsCenter.length;e++)this.displayedColumnsCenter[e].getFlex()&&e>r?(s.push(this.displayedColumnsCenter[e]),a+=this.displayedColumnsCenter[e].getFlex(),o+=null!=(t=this.displayedColumnsCenter[e].getMinWidth())?t:0):n+=this.displayedColumnsCenter[e].getActualWidth();if(!s.length)return[];let l=[];n+o>this.flexViewportWidth&&(s.forEach(e=>{var t;return e.setActualWidth(null!=(t=e.getMinWidth())?t:0,i)}),l=s,s=[]);const c=[];let u;e:for(;;){u=this.flexViewportWidth-n;const e=u/a;for(let t=0;t<s.length;t++){const r=s[t],o=e*r.getFlex();let u=0;const h=r.getMinWidth(),d=r.getMaxWidth();if(C(h)&&o<h?u=h:C(d)&&o>d&&(u=d),u){r.setActualWidth(u,i),Le(s,r),a-=r.getFlex(),l.push(r),n+=r.getActualWidth();continue e}c[t]=Math.round(o)}break}let h=u;return s.forEach((e,t)=>{e.setActualWidth(Math.min(c[t],h),i),l.push(e),h-=c[t]}),e.skipSetLeft||this.setLeftValues(i),e.updateBodyWidths&&this.updateBodyWidths(),e.fireResizedEvent&&this.dispatchColumnResizedEvent(l,!0,i,s),s}sizeColumnsToFit(e,t="sizeColumnsToFit",i,r){var n,s,o,u,h;if(this.shouldQueueResizeOperations)return void this.resizeOperationQueue.push(()=>this.sizeColumnsToFit(e,t,i,r));const d={};r&&(null==(n=null==r?void 0:r.columnLimits)||n.forEach(e=>{var t=e,{key:i}=t,r=((e,t)=>{var i={};for(var r in e)l.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&a)for(var r of a(e))t.indexOf(r)<0&&c.call(e,r)&&(i[r]=e[r]);return i})(t,["key"]);d["string"==typeof i?i:i.getColId()]=r}));const p=this.getAllDisplayedColumns(),g=e===this.getWidthOfColsInList(p);if(e<=0||!p.length||g)return;const f=[],m=[];p.forEach(e=>{!0===e.getColDef().suppressSizeToFit?m.push(e):f.push(e)});const v=f.slice(0);let y=!1;const w=e=>{Ne(f,e),m.push(e)};for(f.forEach(e=>{var i,n;e.resetActualWidth(t);const s=null==d?void 0:d[e.getId()],o=null!=(i=null==s?void 0:s.minWidth)?i:null==r?void 0:r.defaultMinWidth,a=null!=(n=null==s?void 0:s.maxWidth)?n:null==r?void 0:r.defaultMaxWidth,l=e.getActualWidth();"number"==typeof o&&l<o?e.setActualWidth(o,t,!0):"number"==typeof a&&l>a&&e.setActualWidth(a,t,!0)});!y;){y=!0;const i=e-this.getWidthOfColsInList(m);if(i<=0)f.forEach(e=>{var i,n;const s=null!=(n=null==(i=null==d?void 0:d[e.getId()])?void 0:i.minWidth)?n:null==r?void 0:r.defaultMinWidth;"number"!=typeof s?e.setMinimum(t):e.setActualWidth(s,t,!0)});else{const e=i/this.getWidthOfColsInList(f);let n=i;for(let i=f.length-1;i>=0;i--){const a=f[i],l=null==d?void 0:d[a.getId()],c=null!=(s=null==l?void 0:l.minWidth)?s:null==r?void 0:r.defaultMinWidth,p=null!=(o=null==l?void 0:l.maxWidth)?o:null==r?void 0:r.defaultMaxWidth,g=null!=(u=a.getMinWidth())?u:0,m=null!=(h=a.getMaxWidth())?h:Number.MAX_VALUE,v="number"==typeof c&&c>g?c:a.getMinWidth(),S="number"==typeof p&&p<m?p:a.getMaxWidth();let b=Math.round(a.getActualWidth()*e);C(v)&&b<v?(b=v,w(a),y=!1):C(S)&&b>S?(b=S,w(a),y=!1):0===i&&(b=n),a.setActualWidth(b,t,!0),n-=b}}}v.forEach(e=>{e.fireColumnWidthChangedEvent(t)}),this.setLeftValues(t),this.updateBodyWidths(),i||this.dispatchColumnResizedEvent(v,!0,t)}buildDisplayedTrees(e){const t=[],i=[],r=[];e.forEach(e=>{switch(e.getPinned()){case"left":t.push(e);break;case"right":i.push(e);break;default:r.push(e)}});const n=new ut;this.displayedTreeLeft=this.displayedGroupCreator.createDisplayedGroups(t,n,"left",this.displayedTreeLeft),this.displayedTreeRight=this.displayedGroupCreator.createDisplayedGroups(i,n,"right",this.displayedTreeRight),this.displayedTreeCentre=this.displayedGroupCreator.createDisplayedGroups(r,n,null,this.displayedTreeCentre),this.updateDisplayedMap()}updateDisplayedMap(){this.displayedColumnsAndGroupsMap={};const e=e=>{this.displayedColumnsAndGroupsMap[e.getUniqueId()]=e};Rt(this.displayedTreeCentre,!1,e),Rt(this.displayedTreeLeft,!1,e),Rt(this.displayedTreeRight,!1,e)}isDisplayed(e){return this.displayedColumnsAndGroupsMap[e.getUniqueId()]===e}updateOpenClosedVisibilityInColumnGroups(){Rt(this.getAllDisplayedTrees(),!1,e=>{e instanceof at&&e.calculateDisplayedColumns()})}getGroupAutoColumns(){return this.groupAutoColumns}createGroupAutoColumnsIfNeeded(){const e=this.forceRecreateAutoGroups;if(this.forceRecreateAutoGroups=!1,!this.autoGroupsNeedBuilding)return!1;this.autoGroupsNeedBuilding=!1;const t=this.gos.isGroupUseEntireRow(this.pivotMode),i=this.pivotMode?this.gos.get("pivotSuppressAutoColumn"):this.isGroupSuppressAutoColumn();if(!(this.rowGroupColumns.length>0||this.gos.get("treeData"))||i||t)this.groupAutoColumns=null;else{const t=this.autoGroupColService.createAutoGroupColumns(this.rowGroupColumns);if(!this.autoColsEqual(t,this.groupAutoColumns)||e)return this.groupAutoColumns=t,!0}return!1}isGroupSuppressAutoColumn(){return"custom"===this.gos.get("groupDisplayType")||"custom"===this.gos.get("treeDataDisplayType")}autoColsEqual(e,t){return Pe(e,t,(e,t)=>e.getColId()===t.getColId())}getWidthOfColsInList(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}getFirstDisplayedColumn(){const e=this.gos.get("enableRtl"),t=["getDisplayedLeftColumns","getDisplayedCenterColumns","getDisplayedRightColumns"];e&&t.reverse();for(let i=0;i<t.length;i++){const r=this[t[i]]();if(r.length)return e?_e(r):r[0]}return null}setColumnHeaderHeight(e,t){if(e.setAutoHeaderHeight(t)){const t={type:lt.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,column:e,columns:[e],source:"autosizeColumnHeaderHeight"};this.eventService.dispatchEvent(t)}}getColumnGroupHeaderRowHeight(){return this.isPivotMode()?this.getPivotGroupHeaderHeight():this.getGroupHeaderHeight()}getColumnHeaderRowHeight(){const e=this.isPivotMode()?this.getPivotHeaderHeight():this.getHeaderHeight(),t=this.getAllDisplayedColumns().filter(e=>e.isAutoHeaderHeight()).map(e=>e.getAutoHeaderHeight()||0);return Math.max(e,...t)}getHeaderHeight(){var e;return null!=(e=this.gos.get("headerHeight"))?e:this.environment.getFromTheme(25,"headerHeight")}getFloatingFiltersHeight(){var e;return null!=(e=this.gos.get("floatingFiltersHeight"))?e:this.getHeaderHeight()}getGroupHeaderHeight(){var e;return null!=(e=this.gos.get("groupHeaderHeight"))?e:this.getHeaderHeight()}getPivotHeaderHeight(){var e;return null!=(e=this.gos.get("pivotHeaderHeight"))?e:this.getHeaderHeight()}getPivotGroupHeaderHeight(){var e;return null!=(e=this.gos.get("pivotGroupHeaderHeight"))?e:this.getGroupHeaderHeight()}queueResizeOperations(){this.shouldQueueResizeOperations=!0}processResizeOperations(){this.shouldQueueResizeOperations=!1,this.resizeOperationQueue.forEach(e=>e()),this.resizeOperationQueue=[]}resetColumnDefIntoColumn(e,t){const i=e.getUserProvidedColDef();if(!i)return!1;const r=this.columnFactory.addColumnDefaultAndTypes(i,e.getColId());return e.setColDef(r,i,t),!0}isColumnGroupingLocked(e){const t=this.gos.get("groupLockGroupColumns");return!(!e.isRowGroupActive()||0===t)&&(-1===t||t>this.rowGroupColumns.findIndex(t=>t.getColId()===e.getColId()))}generateColumnStateForRowGroupAndPivotIndexes(e,t){let i={};const r=(e,t,r,n,s,o)=>{if(!t.length||!this.primaryColumns)return[];const a=Object.keys(e),l=new Set(a),c=new Set(a),u=new Set(t.map(e=>{const t=e.getColId();return c.delete(t),t}).concat(a)),h=[],d={};let p=0;for(let e=0;e<this.primaryColumns.length;e++){const t=this.primaryColumns[e].getColId();u.has(t)&&(h.push(t),d[t]=p++)}let g=1e3,f=!1,m=0;const v=t=>{const i=d[t];for(let t=m;t<i;t++){const i=h[t];c.has(i)&&(e[i][s]=g++,c.delete(i))}m=i};t.forEach(t=>{const a=t.getColId();if(l.has(a))v(a),e[a][s]=g++;else{const l=t.getColDef();(null===l[s]||void 0===l[s]&&null==l[o])&&(f||(l[r]||void 0===l[r]&&l[n]?v(a):(c.forEach(t=>{e[t][s]=g+d[t]}),g+=h.length,f=!0)),i[a]||(i[a]={colId:a}),i[a][s]=g++)}})};return r(e,this.rowGroupColumns,"rowGroup","initialRowGroup","rowGroupIndex","initialRowGroupIndex"),r(t,this.pivotColumns,"pivot","initialPivot","pivotIndex","initialPivotIndex"),Object.values(i)}onColumnsReady(){const e=this.gos.get("autoSizeStrategy");if(!e)return;const{type:t}=e;setTimeout(()=>{if("fitGridWidth"===t){const{columnLimits:t,defaultMinWidth:i,defaultMaxWidth:r}=e,n=null==t?void 0:t.map(({colId:e,minWidth:t,maxWidth:i})=>({key:e,minWidth:t,maxWidth:i}));this.ctrlsService.getGridBodyCtrl().sizeColumnsToFit({defaultMinWidth:i,defaultMaxWidth:r,columnLimits:n})}else"fitProvidedWidth"===t&&this.sizeColumnsToFit(e.width,"sizeColumnsToFit")})}onFirstDataRendered(){const e=this.gos.get("autoSizeStrategy");if("fitCellContents"!==(null==e?void 0:e.type))return;const{colIds:t,skipHeader:i}=e;setTimeout(()=>{t?this.autoSizeColumns({columns:t,skipHeader:i,source:"autosizeColumns"}):this.autoSizeAllColumns("autosizeColumns",i)})}};function Mt(e){return"gridOptionsUpdated"===e?"gridOptionsChanged":e}function Rt(e,t,i){if(e)for(let r=0;r<e.length;r++){const n=e[r];n instanceof at&&Rt(t?n.getDisplayedChildren():n.getChildren(),t,i),i(n)}}g([ue("expressionService")],Tt.prototype,"expressionService",2),g([ue("columnFactory")],Tt.prototype,"columnFactory",2),g([ue("displayedGroupCreator")],Tt.prototype,"displayedGroupCreator",2),g([ue("ctrlsService")],Tt.prototype,"ctrlsService",2),g([ue("autoWidthCalculator")],Tt.prototype,"autoWidthCalculator",2),g([ue("columnAnimationService")],Tt.prototype,"columnAnimationService",2),g([ue("autoGroupColService")],Tt.prototype,"autoGroupColService",2),g([ue("valueCache")],Tt.prototype,"valueCache",2),g([ue("animationFrameService")],Tt.prototype,"animationFrameService",2),g([ue("sortController")],Tt.prototype,"sortController",2),g([ue("columnDefFactory")],Tt.prototype,"columnDefFactory",2),g([he("aggFuncService")],Tt.prototype,"aggFuncService",2),g([ae],Tt.prototype,"init",1),g([le],Tt.prototype,"destroyColumns",1),g([f(0,pe("loggerFactory"))],Tt.prototype,"setBeans",1),Tt=g([ce("columnModel")],Tt);var _t=class extends rt{createDisplayedGroups(e,t,i,r){const n=this.mapOldGroupsById(r),s=[];let o=e;for(;o.length;){const e=o;o=[];let r=0;const a=a=>{const l=r;r=a;const c=e[l],u=(c instanceof at?c.getProvidedColumnGroup():c).getOriginalParent();if(null==u){for(let t=l;t<a;t++)s.push(e[t]);return}const h=this.createColumnGroup(u,t,n,i);for(let t=l;t<a;t++)h.addChild(e[t]);o.push(h)};for(let t=1;t<e.length;t++){const i=e[t],n=(i instanceof at?i.getProvidedColumnGroup():i).getOriginalParent(),s=e[r];n!==(s instanceof at?s.getProvidedColumnGroup():s).getOriginalParent()&&a(t)}r<e.length&&a(e.length)}return this.setupParentsIntoColumns(s,null),s}createColumnGroup(e,t,i,r){const n=e.getGroupId(),s=t.getInstanceIdForKey(n);let o=i[at.createUniqueId(n,s)];return o&&o.getProvidedColumnGroup()!==e&&(o=null),C(o)?o.reset():(o=new at(e,n,s,r),this.context.createBean(o)),o}mapOldGroupsById(e){const t={},i=e=>{e.forEach(e=>{if(e instanceof at){const r=e;t[e.getUniqueId()]=r,i(r.getChildren())}})};return e&&i(e),t}setupParentsIntoColumns(e,t){e.forEach(e=>{if(e.setParent(t),e instanceof at){const t=e;this.setupParentsIntoColumns(t.getChildren(),t)}})}};_t=g([ce("displayedGroupCreator")],_t);var Pt={enableBrowserTooltips:!0,tooltipTrigger:!0,tooltipMouseTrack:!0,tooltipShowMode:!0,tooltipInteraction:!0,defaultColGroupDef:!0,suppressAutoSize:!0,skipHeaderOnAutoSize:!0,autoSizeStrategy:!0,components:!0,stopEditingWhenCellsLoseFocus:!0,undoRedoCellEditing:!0,undoRedoCellEditingLimit:!0,excelStyles:!0,cacheQuickFilter:!0,excludeHiddenColumnsFromQuickFilter:!0,advancedFilterModel:!0,customChartThemes:!0,chartThemeOverrides:!0,enableChartToolPanelsButton:!0,suppressChartToolPanelsButton:!0,chartToolPanelsDef:!0,loadingCellRendererSelector:!0,localeText:!0,keepDetailRows:!0,keepDetailRowsCount:!0,detailRowHeight:!0,detailRowAutoHeight:!0,tabIndex:!0,valueCache:!0,valueCacheNeverExpires:!0,enableCellExpressions:!0,suppressParentsInRowNodes:!0,suppressTouch:!0,suppressAsyncEvents:!0,suppressBrowserResizeObserver:!0,suppressPropertyNamesCheck:!0,debug:!0,loadingOverlayComponent:!0,suppressLoadingOverlay:!0,noRowsOverlayComponent:!0,paginationPageSizeSelector:!0,paginateChildRows:!0,pivotPanelShow:!0,pivotSuppressAutoColumn:!0,suppressExpandablePivotGroups:!0,aggFuncs:!0,suppressAggFuncInHeader:!0,suppressAggAtRootLevel:!0,removePivotHeaderRowWhenSingleValueColumn:!0,allowShowChangeAfterFilter:!0,ensureDomOrder:!0,enableRtl:!0,suppressColumnVirtualisation:!0,suppressMaxRenderedRowRestriction:!0,suppressRowVirtualisation:!0,rowDragText:!0,suppressGroupMaintainValueType:!0,groupLockGroupColumns:!0,rowGroupPanelSuppressSort:!0,suppressGroupRowsSticky:!0,rowModelType:!0,cacheOverflowSize:!0,infiniteInitialRowCount:!0,serverSideInitialRowCount:!0,suppressServerSideInfiniteScroll:!0,maxBlocksInCache:!0,maxConcurrentDatasourceRequests:!0,blockLoadDebounceMillis:!0,serverSideOnlyRefreshFilteredGroups:!0,serverSidePivotResultFieldSeparator:!0,viewportRowModelPageSize:!0,viewportRowModelBufferSize:!0,debounceVerticalScrollbar:!0,suppressAnimationFrame:!0,suppressPreventDefaultOnMouseWheel:!0,scrollbarWidth:!0,icons:!0,suppressRowTransform:!0,gridId:!0,functionsPassive:!0,enableGroupEdit:!0,initialState:!0,processUnpinnedColumns:!0,createChartContainer:!0,getLocaleText:!0,getRowId:!0,reactiveCustomComponents:!0,columnMenu:!0},xt=class{};xt.STRING_PROPERTIES=["rowSelection","overlayLoadingTemplate","overlayNoRowsTemplate","gridId","quickFilterText","rowModelType","editType","domLayout","clipboardDelimiter","rowGroupPanelShow","multiSortKey","pivotColumnGroupTotals","pivotRowTotals","pivotPanelShow","fillHandleDirection","groupDisplayType","treeDataDisplayType","colResizeDefault","tooltipTrigger","serverSidePivotResultFieldSeparator","columnMenu","tooltipShowMode","grandTotalRow"],xt.OBJECT_PROPERTIES=["components","rowStyle","context","autoGroupColumnDef","localeText","icons","datasource","serverSideDatasource","viewportDatasource","groupRowRendererParams","aggFuncs","fullWidthCellRendererParams","defaultColGroupDef","defaultColDef","defaultCsvExportParams","defaultExcelExportParams","columnTypes","rowClassRules","detailCellRendererParams","loadingCellRendererParams","loadingOverlayComponentParams","noRowsOverlayComponentParams","popupParent","statusBar","sideBar","chartThemeOverrides","customChartThemes","chartToolPanelsDef","dataTypeDefinitions","advancedFilterModel","advancedFilterParent","advancedFilterBuilderParams","initialState","autoSizeStrategy"],xt.ARRAY_PROPERTIES=["sortingOrder","alignedGrids","rowData","columnDefs","excelStyles","pinnedTopRowData","pinnedBottomRowData","chartThemes","rowClass","paginationPageSizeSelector"],xt.NUMBER_PROPERTIES=["rowHeight","detailRowHeight","rowBuffer","headerHeight","groupHeaderHeight","groupLockGroupColumns","floatingFiltersHeight","pivotHeaderHeight","pivotGroupHeaderHeight","groupDefaultExpanded","pivotDefaultExpanded","viewportRowModelPageSize","viewportRowModelBufferSize","autoSizePadding","maxBlocksInCache","maxConcurrentDatasourceRequests","tooltipShowDelay","tooltipHideDelay","cacheOverflowSize","paginationPageSize","cacheBlockSize","infiniteInitialRowCount","serverSideInitialRowCount","scrollbarWidth","asyncTransactionWaitMillis","blockLoadDebounceMillis","keepDetailRowsCount","undoRedoCellEditingLimit","cellFlashDelay","cellFadeDelay","cellFlashDuration","cellFadeDuration","tabIndex","pivotMaxGeneratedColumns"],xt.BOOLEAN_PROPERTIES=["suppressMakeColumnVisibleAfterUnGroup","suppressRowClickSelection","suppressCellFocus","suppressHeaderFocus","suppressHorizontalScroll","groupSelectsChildren","alwaysShowHorizontalScroll","alwaysShowVerticalScroll","debug","enableBrowserTooltips","enableCellExpressions","groupIncludeTotalFooter","groupSuppressBlankHeader","suppressMenuHide","suppressRowDeselection","unSortIcon","suppressMultiSort","alwaysMultiSort","singleClickEdit","suppressLoadingOverlay","suppressNoRowsOverlay","suppressAutoSize","skipHeaderOnAutoSize","suppressParentsInRowNodes","suppressColumnMoveAnimation","suppressMovableColumns","suppressFieldDotNotation","enableRangeSelection","enableRangeHandle","enableFillHandle","suppressClearOnFillReduction","deltaSort","suppressTouch","suppressAsyncEvents","allowContextMenuWithControlKey","suppressContextMenu","enableCellChangeFlash","suppressDragLeaveHidesColumns","suppressRowGroupHidesColumns","suppressMiddleClickScrolls","suppressPreventDefaultOnMouseWheel","suppressCopyRowsToClipboard","copyHeadersToClipboard","copyGroupHeadersToClipboard","pivotMode","suppressAggFuncInHeader","suppressColumnVirtualisation","alwaysAggregateAtRootLevel","suppressAggAtRootLevel","suppressFocusAfterRefresh","functionsPassive","functionsReadOnly","animateRows","groupSelectsFiltered","groupRemoveSingleChildren","groupRemoveLowestSingleChildren","enableRtl","suppressClickEdit","rowDragEntireRow","rowDragManaged","suppressRowDrag","suppressMoveWhenRowDragging","rowDragMultiRow","enableGroupEdit","embedFullWidthRows","suppressPaginationPanel","groupHideOpenParents","groupAllowUnbalanced","pagination","paginationAutoPageSize","suppressScrollOnNewData","suppressScrollWhenPopupsAreOpen","purgeClosedRowNodes","cacheQuickFilter","includeHiddenColumnsInQuickFilter","excludeHiddenColumnsFromQuickFilter","ensureDomOrder","accentedSort","suppressChangeDetection","valueCache","valueCacheNeverExpires","aggregateOnlyChangedColumns","suppressAnimationFrame","suppressExcelExport","suppressCsvExport","includeHiddenColumnsInAdvancedFilter","suppressMultiRangeSelection","enterMovesDown","enterMovesDownAfterEdit","enterNavigatesVerticallyAfterEdit","enterNavigatesVertically","suppressPropertyNamesCheck","rowMultiSelectWithClick","suppressRowHoverHighlight","suppressRowTransform","suppressClipboardPaste","suppressLastEmptyLineOnPaste","enableCharts","enableChartToolPanelsButton","suppressChartToolPanelsButton","suppressMaintainUnsortedOrder","enableCellTextSelection","suppressBrowserResizeObserver","suppressMaxRenderedRowRestriction","excludeChildrenWhenTreeDataFiltering","tooltipMouseTrack","tooltipInteraction","keepDetailRows","paginateChildRows","preventDefaultOnContextMenu","undoRedoCellEditing","allowDragFromColumnsToolPanel","pivotSuppressAutoColumn","suppressExpandablePivotGroups","debounceVerticalScrollbar","detailRowAutoHeight","serverSideFilterAllLevels","serverSideSortAllLevels","serverSideEnableClientSideSort","serverSideOnlyRefreshFilteredGroups","serverSideSortOnServer","serverSideFilterOnServer","suppressAggFilteredOnly","showOpenedGroup","suppressClipboardApi","suppressModelUpdateAfterUpdateTransaction","stopEditingWhenCellsLoseFocus","maintainColumnOrder","groupMaintainOrder","columnHoverHighlight","readOnlyEdit","suppressRowVirtualisation","enableCellEditingOnBackspace","resetRowDataOnUpdate","removePivotHeaderRowWhenSingleValueColumn","suppressCopySingleCellRanges","suppressGroupRowsSticky","suppressCutToClipboard","suppressServerSideInfiniteScroll","rowGroupPanelSuppressSort","allowShowChangeAfterFilter","enableAdvancedFilter","masterDetail","treeData","suppressGroupMaintainValueType","reactiveCustomComponents","applyQuickFilterBeforePivotOrAgg","suppressServerSideFullWidthLoadingRow","suppressAdvancedFilterEval"],xt.OTHER_PROPERTIES=["suppressStickyTotalRow"],xt.FUNCTIONAL_PROPERTIES=["doesExternalFilterPass","processPivotResultColDef","processPivotResultColGroupDef","getBusinessKeyForNode","isRowSelectable","rowDragText","groupRowRenderer","fullWidthCellRenderer","loadingCellRenderer","loadingOverlayComponent","noRowsOverlayComponent","detailCellRenderer","quickFilterParser","quickFilterMatcher"],xt.CALLBACK_PROPERTIES=["getLocaleText","isExternalFilterPresent","getRowHeight","getRowClass","getRowStyle","getContextMenuItems","getMainMenuItems","processRowPostCreate","processCellForClipboard","getGroupRowAgg","isFullWidthRow","sendToClipboard","navigateToNextHeader","tabToNextHeader","navigateToNextCell","tabToNextCell","processCellFromClipboard","getDocument","postProcessPopup","getChildCount","getDataPath","isRowMaster","postSortRows","processHeaderForClipboard","processUnpinnedColumns","processGroupHeaderForClipboard","paginationNumberFormatter","processDataFromClipboard","getServerSideGroupKey","isServerSideGroup","createChartContainer","getChartToolbarItems","fillOperation","isApplyServerSideTransaction","getServerSideGroupLevelParams","isServerSideGroupOpenByDefault","isGroupOpenByDefault","initialGroupOrderComparator","groupIncludeFooter","loadingCellRendererSelector","getRowId","groupAggFiltering","chartMenuItems","groupTotalRow"],xt.FUNCTION_PROPERTIES=[...xt.FUNCTIONAL_PROPERTIES,...xt.CALLBACK_PROPERTIES],xt.ALL_PROPERTIES=[...xt.ARRAY_PROPERTIES,...xt.OBJECT_PROPERTIES,...xt.STRING_PROPERTIES,...xt.NUMBER_PROPERTIES,...xt.FUNCTION_PROPERTIES,...xt.BOOLEAN_PROPERTIES,...xt.OTHER_PROPERTIES];var Dt=xt,It=class e{static getCallbackForEvent(e){return!e||e.length<2?e:"on"+e[0].toUpperCase()+e.substring(1)}static getGridOptionKeys(){return this.ALL_PROPERTIES_AND_CALLBACKS}static combineAttributesAndGridOptions(t,i){"object"!=typeof t&&(t={});const r=h({},t);return e.getGridOptionKeys().forEach(t=>{const n=i[t];void 0!==n&&n!==e.VUE_OMITTED_PROPERTY&&(r[t]=n)}),r}static processOnChange(t,i,r){if(!t)return;const n={};let s=!1;if(Object.keys(t).filter(t=>e.ALL_PROPERTIES_AND_CALLBACKS_SET.has(t)).forEach(e=>{n[e]=t[e],s=!0}),!s)return;i.__internalUpdateGridOptions(n,!0);const o={type:lt.EVENT_COMPONENT_STATE_CHANGED};D(n,(e,t)=>{o[e]=t}),i.dispatchEvent(o)}};It.EVENTS=R(lt),It.VUE_OMITTED_PROPERTY="AG-VUE-OMITTED-PROPERTY",It.EXCLUDED_INTERNAL_EVENTS=[lt.EVENT_SCROLLBAR_WIDTH_CHANGED,lt.EVENT_CHECKBOX_CHANGED,lt.EVENT_HEIGHT_SCALE_CHANGED,lt.EVENT_BODY_HEIGHT_CHANGED,lt.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,lt.EVENT_SCROLL_VISIBILITY_CHANGED,lt.EVENT_COLUMN_HOVER_CHANGED,lt.EVENT_FLASH_CELLS,lt.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED,lt.EVENT_DISPLAYED_ROWS_CHANGED,lt.EVENT_LEFT_PINNED_WIDTH_CHANGED,lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED,lt.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,lt.EVENT_STORE_UPDATED,lt.EVENT_COLUMN_PANEL_ITEM_DRAG_START,lt.EVENT_COLUMN_PANEL_ITEM_DRAG_END,lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_START,lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_END,lt.EVENT_FULL_WIDTH_ROW_FOCUSED,lt.EVENT_HEADER_HEIGHT_CHANGED,lt.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,lt.EVENT_CELL_FOCUS_CLEARED,lt.EVENT_GRID_STYLES_CHANGED,lt.EVENT_FILTER_DESTROYED,lt.EVENT_ROW_DATA_UPDATE_STARTED,lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,lt.EVENT_DATA_TYPES_INFERRED,lt.EVENT_FIELD_VALUE_CHANGED,lt.EVENT_FIELD_PICKER_VALUE_SELECTED,lt.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED,lt.EVENT_SUPPRESS_MENU_HIDE_CHANGED,lt.EVENT_SUPPRESS_FIELD_DOT_NOTATION,lt.EVENT_ROW_COUNT_READY,lt.EVENT_SIDE_BAR_UPDATED],It.PUBLIC_EVENTS=It.EVENTS.filter(e=>!He(It.EXCLUDED_INTERNAL_EVENTS,e)),It.EVENT_CALLBACKS=It.EVENTS.map(e=>It.getCallbackForEvent(e)),It.BOOLEAN_PROPERTIES=Dt.BOOLEAN_PROPERTIES,It.ALL_PROPERTIES=Dt.ALL_PROPERTIES,It.ALL_PROPERTIES_AND_CALLBACKS=[...It.ALL_PROPERTIES,...It.EVENT_CALLBACKS],It.ALL_PROPERTIES_AND_CALLBACKS_SET=new Set(It.ALL_PROPERTIES_AND_CALLBACKS);var Lt=It,Nt=class extends rt{constructor(){super(...arguments),this.componentsMappedByName={}}setupComponents(e){e&&e.forEach(e=>this.addComponent(e))}addComponent(e){const t=e.componentName.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase().toUpperCase();this.componentsMappedByName[t]=e.componentClass}getComponentClass(e){return this.componentsMappedByName[e]}};Nt=g([ce("agStackComponentsRegistry")],Nt);var Ot={};function Ft(e,t,i){null==i||"string"==typeof i&&""==i?Gt(e,t):kt(e,t,i)}function kt(e,t,i){e.setAttribute(Vt(t),i.toString())}function Gt(e,t){e.removeAttribute(Vt(t))}function Vt(e){return`aria-${e}`}function Ht(e,t){t?e.setAttribute("role",t):e.removeAttribute("role")}function Bt(e){let t;return t="asc"===e?"ascending":"desc"===e?"descending":"mixed"===e?"other":"none",t}function zt(e){return parseInt(e.getAttribute("aria-level"),10)}function Ut(e){return parseInt(e.getAttribute("aria-posinset"),10)}function Wt(e){return e.getAttribute("aria-label")}function jt(e,t){Ft(e,"label",t)}function Kt(e,t){Ft(e,"labelledby",t)}function $t(e,t){Ft(e,"describedby",t)}function qt(e,t){Ft(e,"live",t)}function Yt(e,t){Ft(e,"atomic",t)}function Qt(e,t){Ft(e,"relevant",t)}function Xt(e,t){Ft(e,"level",t)}function Zt(e,t){Ft(e,"disabled",t)}function Jt(e,t){Ft(e,"hidden",t)}function ei(e,t){Ft(e,"activedescendant",t)}function ti(e,t){kt(e,"expanded",t)}function ii(e){Gt(e,"expanded")}function ri(e,t){kt(e,"setsize",t)}function ni(e,t){kt(e,"posinset",t)}function si(e,t){kt(e,"multiselectable",t)}function oi(e,t){kt(e,"rowcount",t)}function ai(e,t){kt(e,"rowindex",t)}function li(e,t){kt(e,"colcount",t)}function ci(e,t){kt(e,"colindex",t)}function ui(e,t){kt(e,"colspan",t)}function hi(e,t){kt(e,"sort",t)}function di(e){Gt(e,"sort")}function pi(e,t){Ft(e,"selected",t)}function gi(e,t){kt(e,"checked",void 0===t?"mixed":t)}function fi(e,t){Ft(e,"controls",t.id),Kt(t,e.id)}function mi(e,t){return void 0===t?e("ariaIndeterminate","indeterminate"):!0===t?e("ariaChecked","checked"):e("ariaUnchecked","unchecked")}p(Ot,{getAriaCheckboxStateName:()=>mi,getAriaLabel:()=>Wt,getAriaLevel:()=>zt,getAriaPosInSet:()=>Ut,getAriaSortState:()=>Bt,removeAriaExpanded:()=>ii,removeAriaSort:()=>di,setAriaActiveDescendant:()=>ei,setAriaAtomic:()=>Yt,setAriaChecked:()=>gi,setAriaColCount:()=>li,setAriaColIndex:()=>ci,setAriaColSpan:()=>ui,setAriaControls:()=>fi,setAriaDescribedBy:()=>$t,setAriaDisabled:()=>Zt,setAriaExpanded:()=>ti,setAriaHidden:()=>Jt,setAriaLabel:()=>jt,setAriaLabelledBy:()=>Kt,setAriaLevel:()=>Xt,setAriaLive:()=>qt,setAriaMultiSelectable:()=>si,setAriaPosInSet:()=>ni,setAriaRelevant:()=>Qt,setAriaRole:()=>Ht,setAriaRowCount:()=>oi,setAriaRowIndex:()=>ai,setAriaSelected:()=>pi,setAriaSetSize:()=>ri,setAriaSort:()=>hi});var vi,Ci,yi,wi,Si,bi,Ei,Ai,Ti={};function Mi(){return void 0===vi&&(vi=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),vi}function Ri(){if(void 0===Ci)if(Mi()){const e=navigator.userAgent.match(/version\/(\d+)/i);e&&(Ci=null!=e[1]?parseFloat(e[1]):0)}else Ci=0;return Ci}function _i(){if(void 0===yi){const e=window;yi=!!e.chrome&&(!!e.chrome.webstore||!!e.chrome.runtime)||/Chrome/.test(navigator.userAgent)&&/Google Inc/.test(navigator.vendor)}return yi}function Pi(){return void 0===wi&&(wi=/(firefox)/i.test(navigator.userAgent)),wi}function xi(){return void 0===Si&&(Si=/(Mac|iPhone|iPod|iPad)/i.test(navigator.platform)),Si}function Di(){return void 0===bi&&(bi=/iPad|iPhone|iPod/.test(navigator.platform)||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1),bi}function Ii(){return!Mi()||Ri()>=15}function Li(e){if(!e)return null;const t=e.tabIndex,i=e.getAttribute("tabIndex");return-1!==t||null!==i&&(""!==i||Pi())?t.toString():null}function Ni(){if(!document.body)return-1;let e=1e6;const t=navigator.userAgent.toLowerCase().match(/firefox/)?6e6:1e9,i=document.createElement("div");for(document.body.appendChild(i);;){const r=2*e;if(i.style.height=r+"px",r>t||i.clientHeight!==r)break;e=r}return document.body.removeChild(i),e}function Oi(){var e,t,i;return null!=(i=null==(e=document.body)?void 0:e.clientWidth)?i:window.innerHeight||(null==(t=document.documentElement)?void 0:t.clientWidth)||-1}function Fi(){var e,t,i;return null!=(i=null==(e=document.body)?void 0:e.clientHeight)?i:window.innerHeight||(null==(t=document.documentElement)?void 0:t.clientHeight)||-1}function ki(){return null==Ai&&Gi(),Ai}function Gi(){const e=document.body,t=document.createElement("div");t.style.width=t.style.height="100px",t.style.opacity="0",t.style.overflow="scroll",t.style.msOverflowStyle="scrollbar",t.style.position="absolute",e.appendChild(t);let i=t.offsetWidth-t.clientWidth;0===i&&0===t.clientWidth&&(i=null),t.parentNode&&t.parentNode.removeChild(t),null!=i&&(Ai=i,Ei=0===i)}function Vi(){return null==Ei&&Gi(),Ei}p(Ti,{browserSupportsPreventScroll:()=>Ii,getBodyHeight:()=>Fi,getBodyWidth:()=>Oi,getMaxDivHeight:()=>Ni,getSafariVersion:()=>Ri,getScrollbarWidth:()=>ki,getTabIndex:()=>Li,isBrowserChrome:()=>_i,isBrowserFirefox:()=>Pi,isBrowserSafari:()=>Mi,isIOSUserAgent:()=>Di,isInvisibleScrollbar:()=>Vi,isMacOsUserAgent:()=>xi});var Hi={};p(Hi,{dateToFormattedString:()=>Xi,parseDateTimeFromString:()=>Zi,serialiseDate:()=>Yi});var Bi={};function zi(e,t){return e.toString().padStart(t,"0")}function Ui(e,t){const i=[];for(let r=e;r<=t;r++)i.push(r);return i}function Wi(e){return"string"==typeof e&&(e=parseInt(e,10)),"number"==typeof e?Math.floor(e):null}function ji(e,t){let i="";for(let r=0;r<t;r++)i+=String.fromCharCode(255&e),e>>>=8;return i}function Ki(e,t,i){return"number"!=typeof e?"":$i(Math.round(100*e)/100,t,i)}function $i(e,t,i){return"number"!=typeof e?"":e.toString().replace(".",i).replace(/(\d)(?=(\d{3})+(?!\d))/g,`$1${t}`)}function qi(e){return null==e?null:e.reduce((e,t)=>e+t,0)}function Yi(e,t=!0,i="-"){if(!e)return null;let r=[e.getFullYear(),e.getMonth()+1,e.getDate()].map(e=>zi(e,2)).join(i);return t&&(r+=" "+[e.getHours(),e.getMinutes(),e.getSeconds()].map(e=>zi(e,2)).join(":")),r}p(Bi,{cleanNumber:()=>Wi,createArrayOfNumbers:()=>Ui,decToHex:()=>ji,formatNumberCommas:()=>$i,formatNumberTwoDecimalPlacesAndCommas:()=>Ki,padStartWidthZeros:()=>zi,sum:()=>qi});var Qi=e=>{if(e>3&&e<21)return"th";switch(e%10){case 1:return"st";case 2:return"nd";case 3:return"rd"}return"th"};function Xi(e,t="YYYY-MM-DD"){const i=zi(e.getFullYear(),4),r=["January","February","March","April","May","June","July","August","September","October","November","December"],n=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],s={YYYY:()=>i.slice(i.length-4,i.length),YY:()=>i.slice(i.length-2,i.length),Y:()=>`${e.getFullYear()}`,MMMM:()=>r[e.getMonth()],MMM:()=>r[e.getMonth()].slice(0,3),MM:()=>zi(e.getMonth()+1,2),Mo:()=>`${e.getMonth()+1}${Qi(e.getMonth()+1)}`,M:()=>`${e.getMonth()+1}`,Do:()=>`${e.getDate()}${Qi(e.getDate())}`,DD:()=>zi(e.getDate(),2),D:()=>`${e.getDate()}`,dddd:()=>n[e.getDay()],ddd:()=>n[e.getDay()].slice(0,3),dd:()=>n[e.getDay()].slice(0,2),do:()=>`${e.getDay()}${Qi(e.getDay())}`,d:()=>`${e.getDay()}`},o=new RegExp(Object.keys(s).join("|"),"g");return t.replace(o,e=>e in s?s[e]():e)}function Zi(e){if(!e)return null;const[t,i]=e.split(" ");if(!t)return null;const r=t.split("-").map(e=>parseInt(e,10));if(3!==r.filter(e=>!isNaN(e)).length)return null;const[n,s,o]=r,a=new Date(n,s-1,o);if(a.getFullYear()!==n||a.getMonth()!==s-1||a.getDate()!==o)return null;if(!i||"00:00:00"===i)return a;const[l,c,u]=i.split(":").map(e=>parseInt(e,10));return l>=0&&l<24&&a.setHours(l),c>=0&&c<60&&a.setMinutes(c),u>=0&&u<60&&a.setSeconds(u),a}var Ji,er={};function tr(e,t,i){const r=e.parentElement;let n=r&&r.firstChild;for(;n;)t&&n.classList.toggle(t,n===e),i&&n.classList.toggle(i,n!==e),n=n.nextSibling}p(er,{FOCUSABLE_EXCLUDE:()=>rr,FOCUSABLE_SELECTOR:()=>ir,addOrRemoveAttribute:()=>kr,addStylesToElement:()=>Mr,bindCellRendererToHtmlElement:()=>Vr,clearElement:()=>Cr,copyNodeList:()=>Or,ensureDomOrder:()=>Er,formatSize:()=>Lr,getAbsoluteHeight:()=>dr,getAbsoluteWidth:()=>pr,getElementRectWithOffset:()=>gr,getElementSize:()=>cr,getInnerHeight:()=>ur,getInnerWidth:()=>hr,getScrollLeft:()=>mr,insertWithDomOrder:()=>Tr,isElementChildOfClass:()=>lr,isFocusableFormField:()=>nr,isHorizontalScrollShowing:()=>Rr,isInDOM:()=>wr,isNodeOrElement:()=>Nr,isRtlNegativeScroll:()=>fr,isVerticalScrollShowing:()=>_r,isVisible:()=>Sr,iterateNamedNodeMap:()=>Fr,loadTemplate:()=>br,nodeListForEach:()=>Gr,radioCssClass:()=>tr,removeFromParent:()=>yr,setDisabled:()=>ar,setDisplayed:()=>sr,setDomChildOrder:()=>Ar,setElementHeight:()=>Dr,setElementWidth:()=>Pr,setFixedHeight:()=>Ir,setFixedWidth:()=>xr,setScrollLeft:()=>vr,setVisible:()=>or});var ir="[tabindex], input, select, button, textarea, [href]",rr="[disabled], .ag-disabled:not(.ag-button), .ag-disabled *";function nr(e){const t=Element.prototype.matches||Element.prototype.msMatchesSelector,i=t.call(e,"input, select, button, textarea"),r=t.call(e,rr),n=Sr(e);return i&&!r&&n}function sr(e,t,i={}){const{skipAriaHidden:r}=i;e.classList.toggle("ag-hidden",!t),r||Jt(e,!t)}function or(e,t,i={}){const{skipAriaHidden:r}=i;e.classList.toggle("ag-invisible",!t),r||Jt(e,!t)}function ar(e,t){const i="disabled",r=t?e=>e.setAttribute(i,""):e=>e.removeAttribute(i);r(e),Gr(e.querySelectorAll("input"),e=>r(e))}function lr(e,t,i){let r=0;for(;e;){if(e.classList.contains(t))return!0;if(e=e.parentElement,"number"==typeof i){if(++r>i)break}else if(e===i)break}return!1}function cr(e){const{height:t,width:i,borderTopWidth:r,borderRightWidth:n,borderBottomWidth:s,borderLeftWidth:o,paddingTop:a,paddingRight:l,paddingBottom:c,paddingLeft:u,marginTop:h,marginRight:d,marginBottom:p,marginLeft:g,boxSizing:f}=window.getComputedStyle(e);return{height:parseFloat(t||"0"),width:parseFloat(i||"0"),borderTopWidth:parseFloat(r||"0"),borderRightWidth:parseFloat(n||"0"),borderBottomWidth:parseFloat(s||"0"),borderLeftWidth:parseFloat(o||"0"),paddingTop:parseFloat(a||"0"),paddingRight:parseFloat(l||"0"),paddingBottom:parseFloat(c||"0"),paddingLeft:parseFloat(u||"0"),marginTop:parseFloat(h||"0"),marginRight:parseFloat(d||"0"),marginBottom:parseFloat(p||"0"),marginLeft:parseFloat(g||"0"),boxSizing:f}}function ur(e){const t=cr(e);return"border-box"===t.boxSizing?t.height-t.paddingTop-t.paddingBottom:t.height}function hr(e){const t=cr(e);return"border-box"===t.boxSizing?t.width-t.paddingLeft-t.paddingRight:t.width}function dr(e){const t=cr(e),i=t.marginBottom+t.marginTop;return Math.ceil(e.offsetHeight+i)}function pr(e){const t=cr(e),i=t.marginLeft+t.marginRight;return Math.ceil(e.offsetWidth+i)}function gr(e){const t=e.getBoundingClientRect(),{borderTopWidth:i,borderLeftWidth:r,borderRightWidth:n,borderBottomWidth:s}=cr(e);return{top:t.top+(i||0),left:t.left+(r||0),right:t.right+(n||0),bottom:t.bottom+(s||0)}}function fr(){if("boolean"==typeof Ji)return Ji;const e=document.createElement("div");return e.style.direction="rtl",e.style.width="1px",e.style.height="1px",e.style.position="fixed",e.style.top="0px",e.style.overflow="hidden",e.dir="rtl",e.innerHTML='<div style="width: 2px">\n            <span style="display: inline-block; width: 1px"></span>\n            <span style="display: inline-block; width: 1px"></span>\n        </div>',document.body.appendChild(e),e.scrollLeft=1,Ji=0===Math.floor(e.scrollLeft),document.body.removeChild(e),Ji}function mr(e,t){let i=e.scrollLeft;return t&&(i=Math.abs(i),_i()&&!fr()&&(i=e.scrollWidth-e.clientWidth-i)),i}function vr(e,t,i){i&&(fr()?t*=-1:(Mi()||_i())&&(t=e.scrollWidth-e.clientWidth-t)),e.scrollLeft=t}function Cr(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}function yr(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function wr(e){return!!e.offsetParent}function Sr(e){const t=e;return t.checkVisibility?t.checkVisibility({checkVisibilityCSS:!0}):!(!wr(e)||"visible"!==window.getComputedStyle(e).visibility)}function br(e){const t=document.createElement("div");return t.innerHTML=(e||"").trim(),t.firstChild}function Er(e,t,i){i&&i.nextSibling===t||(i?i.nextSibling?e.insertBefore(t,i.nextSibling):e.appendChild(t):e.firstChild&&e.firstChild!==t&&e.insertAdjacentElement("afterbegin",t))}function Ar(e,t){for(let i=0;i<t.length;i++){const r=t[i],n=e.children[i];n!==r&&e.insertBefore(r,n)}}function Tr(e,t,i){i?i.insertAdjacentElement("afterend",t):e.firstChild?e.insertAdjacentElement("afterbegin",t):e.appendChild(t)}function Mr(e,t){if(t)for(const[i,r]of Object.entries(t)){if(!i||!i.length||null==r)continue;const t=wt(i),n=r.toString(),s=n.replace(/\s*!important/g,""),o=s.length!=n.length?"important":void 0;e.style.setProperty(t,s,o)}}function Rr(e){return e.clientWidth<e.scrollWidth}function _r(e){return e.clientHeight<e.scrollHeight}function Pr(e,t){"flex"===t?(e.style.removeProperty("width"),e.style.removeProperty("minWidth"),e.style.removeProperty("maxWidth"),e.style.flex="1 1 auto"):xr(e,t)}function xr(e,t){t=Lr(t),e.style.width=t.toString(),e.style.maxWidth=t.toString(),e.style.minWidth=t.toString()}function Dr(e,t){"flex"===t?(e.style.removeProperty("height"),e.style.removeProperty("minHeight"),e.style.removeProperty("maxHeight"),e.style.flex="1 1 auto"):Ir(e,t)}function Ir(e,t){t=Lr(t),e.style.height=t.toString(),e.style.maxHeight=t.toString(),e.style.minHeight=t.toString()}function Lr(e){return"number"==typeof e?`${e}px`:e}function Nr(e){return e instanceof Node||e instanceof HTMLElement}function Or(e){if(null==e)return[];const t=[];return Gr(e,e=>t.push(e)),t}function Fr(e,t){if(e)for(let i=0;i<e.length;i++){const r=e[i];t(r.name,r.value)}}function kr(e,t,i){null==i?e.removeAttribute(t):e.setAttribute(t,i.toString())}function Gr(e,t){if(null!=e)for(let i=0;i<e.length;i++)t(e[i])}function Vr(e,t){e.then(e=>{const i=e.getGui();null!=i&&("object"==typeof i?t.appendChild(i):t.innerHTML=i)})}var Hr={};function Br(e,t,i){const r={},n=e.filter(e=>!t.some(t=>t===e));return n.length>0&&n.forEach(e=>r[e]=zr(e,i).values),r}function zr(e,t,i,r){let n=t.map((t,i)=>({value:t,relevance:Ur(e.toLowerCase(),t.toLocaleLowerCase()),idx:i}));if(n.sort((e,t)=>t.relevance-e.relevance),i&&(n=n.filter(e=>0!==e.relevance)),n.length>0&&r&&r>0){const e=n[0].relevance*r;n=n.filter(t=>e-t.relevance<0)}const s=[],o=[];for(const e of n)s.push(e.value),o.push(e.idx);return{values:s,indices:o}}function Ur(e,t){const i=e.replace(/\s/g,""),r=t.replace(/\s/g,"");let n=0,s=-1;for(let e=0;e<i.length;e++){const t=r.indexOf(i[e],s+1);-1!==t&&(s=t,n+=100-100*s/1e4*100)}return n}p(Hr,{fuzzyCheckStrings:()=>Br,fuzzySuggestions:()=>zr});var Wr={};p(Wr,{createIcon:()=>Kr,createIconNoSpan:()=>$r,iconNameClassMap:()=>jr});var jr={columnGroupOpened:"expanded",columnGroupClosed:"contracted",columnSelectClosed:"tree-closed",columnSelectOpen:"tree-open",columnSelectIndeterminate:"tree-indeterminate",columnMovePin:"pin",columnMoveHide:"eye-slash",columnMoveMove:"arrows",columnMoveLeft:"left",columnMoveRight:"right",columnMoveGroup:"group",columnMoveValue:"aggregation",columnMovePivot:"pivot",dropNotAllowed:"not-allowed",groupContracted:"tree-closed",groupExpanded:"tree-open",setFilterGroupClosed:"tree-closed",setFilterGroupOpen:"tree-open",setFilterGroupIndeterminate:"tree-indeterminate",chart:"chart",close:"cross",cancel:"cancel",check:"tick",first:"first",previous:"previous",next:"next",last:"last",linked:"linked",unlinked:"unlinked",colorPicker:"color-picker",groupLoading:"loading",menu:"menu",menuAlt:"menu-alt",filter:"filter",columns:"columns",maximize:"maximize",minimize:"minimize",menuPin:"pin",menuValue:"aggregation",menuAddRowGroup:"group",menuRemoveRowGroup:"group",clipboardCopy:"copy",clipboardCut:"cut",clipboardPaste:"paste",pivotPanel:"pivot",rowGroupPanel:"group",valuePanel:"aggregation",columnDrag:"grip",rowDrag:"grip",save:"save",csvExport:"csv",excelExport:"excel",smallDown:"small-down",smallLeft:"small-left",smallRight:"small-right",smallUp:"small-up",sortAscending:"asc",sortDescending:"desc",sortUnSort:"none",advancedFilterBuilder:"group",advancedFilterBuilderDrag:"grip",advancedFilterBuilderInvalid:"not-allowed",advancedFilterBuilderMoveUp:"up",advancedFilterBuilderMoveDown:"down",advancedFilterBuilderAdd:"plus",advancedFilterBuilderRemove:"minus",chartsMenuEdit:"chart",chartsMenuAdvancedSettings:"settings",chartsMenuAdd:"plus"};function Kr(e,t,i){const r=$r(e,t,i);if(r){const{className:e}=r;if("string"==typeof e&&e.indexOf("ag-icon")>-1||"object"==typeof e&&e["ag-icon"])return r}const n=document.createElement("span");return n.appendChild(r),n}function $r(e,t,i,r){let n=null;const s=i&&i.getColDef().icons;if(s&&(n=s[e]),t&&!n){const i=t.get("icons");i&&(n=i[e])}if(!n){const t=document.createElement("span");let i=jr[e];return i||(r?i=e:(console.warn(`AG Grid: Did not find icon ${e}`),i="")),t.setAttribute("class",`ag-icon ag-icon-${i}`),t.setAttribute("unselectable","on"),Ht(t,"presentation"),t}{let e;if("function"==typeof n)e=n();else{if("string"!=typeof n)throw new Error("icon from grid options needs to be a string or a function");e=n}if("string"==typeof e)return br(e);if(Nr(e))return e;console.warn("AG Grid: iconRenderer should return back a string or a dom object")}}var qr={};p(qr,{isDeleteKey:()=>en,isEventFromPrintableCharacter:()=>Qr,isUserSuppressingHeaderKeyboardEvent:()=>Zr,isUserSuppressingKeyboardEvent:()=>Xr,normaliseQwertyAzerty:()=>Jr});var Yr=class{};function Qr(e){return!(e.altKey||e.ctrlKey||e.metaKey)&&1===e.key.length}function Xr(e,t,i,r,n){const s=r?r.getColDef().suppressKeyboardEvent:void 0;if(!s)return!1;const o=e.addGridCommonParams({event:t,editing:n,column:r,node:i,data:i.data,colDef:r.getColDef()});return!(!s||!s(o))}function Zr(e,t,i,r){const n=r.getDefinition(),s=n&&n.suppressHeaderKeyboardEvent;return!!C(s)&&!!s(e.addGridCommonParams({colDef:n,column:r,headerRowIndex:i,event:t}))}function Jr(e){const{keyCode:t}=e;let i;switch(t){case 65:i=Yr.A;break;case 67:i=Yr.C;break;case 86:i=Yr.V;break;case 68:i=Yr.D;break;case 90:i=Yr.Z;break;case 89:i=Yr.Y;break;default:i=e.code}return i}function en(e,t=!1){return e===Yr.DELETE||!t&&e===Yr.BACKSPACE&&xi()}Yr.BACKSPACE="Backspace",Yr.TAB="Tab",Yr.ENTER="Enter",Yr.ESCAPE="Escape",Yr.SPACE=" ",Yr.LEFT="ArrowLeft",Yr.UP="ArrowUp",Yr.RIGHT="ArrowRight",Yr.DOWN="ArrowDown",Yr.DELETE="Delete",Yr.F2="F2",Yr.PAGE_UP="PageUp",Yr.PAGE_DOWN="PageDown",Yr.PAGE_HOME="Home",Yr.PAGE_END="End",Yr.A="KeyA",Yr.C="KeyC",Yr.D="KeyD",Yr.V="KeyV",Yr.X="KeyX",Yr.Y="KeyY",Yr.Z="KeyZ";var tn={};function rn(e,t,i){if(0===i)return!1;const r=Math.abs(e.clientX-t.clientX),n=Math.abs(e.clientY-t.clientY);return Math.max(r,n)<=i}p(tn,{areEventsNear:()=>rn});var nn={};function sn(e,t){if(!e)return!1;const i=(e,i)=>{const r=t[e.id],n=t[i.id],s=void 0!==r,o=void 0!==n;return s&&o?r-n:s||o?s?1:-1:e.__objectId-i.__objectId};let r,n,s=!1;for(let t=0;t<e.length-1;t++)if(r=e[t],n=e[t+1],i(r,n)>0){s=!0;break}return!!s&&(e.sort(i),!0)}p(nn,{sortRowNodesByOrder:()=>sn});var on={};function an(e){const t=new Set;return e.forEach(e=>t.add(e)),t}p(on,{convertToSet:()=>an});var ln=h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h(h({},Ot),Me),Ti),Hi),er),Te),V),Hr),m),Wr),qr),St),tn),Bi),P),nn),on),pt),cn=class{constructor(e=0,t=1){this.nextValue=e,this.step=t}next(){const e=this.nextValue;return this.nextValue+=this.step,e}peek(){return this.nextValue}skip(e){this.nextValue+=e}},un=(e=>(e[e.IN_PROGRESS=0]="IN_PROGRESS",e[e.RESOLVED=1]="RESOLVED",e))(un||{}),hn=class e{constructor(e){this.status=0,this.resolution=null,this.waiters=[],e(e=>this.onDone(e),e=>this.onReject(e))}static all(t){return new e(e=>{let i=t.length;const r=new Array(i);t.forEach((t,n)=>{t.then(t=>{r[n]=t,i--,0===i&&e(r)})})})}static resolve(t=null){return new e(e=>e(t))}then(t){return new e(e=>{1===this.status?e(t(this.resolution)):this.waiters.push(i=>e(t(i)))})}resolveNow(e,t){return 1===this.status?t(this.resolution):e}onDone(e){this.status=1,this.resolution=e,this.waiters.forEach(t=>t(e))}onReject(e){console.warn("TBI")}},dn=class{constructor(){this.timestamp=(new Date).getTime()}print(e){const t=(new Date).getTime()-this.timestamp;console.info(`${e} = ${t}`),this.timestamp=(new Date).getTime()}},pn=class{constructor(e){this.cssClassStates={},this.getGui=e}addCssClass(e){const t=(e||"").split(" ");if(t.length>1)t.forEach(e=>this.addCssClass(e));else if(!0!==this.cssClassStates[e]&&e.length){const t=this.getGui();t&&t.classList.add(e),this.cssClassStates[e]=!0}}removeCssClass(e){const t=(e||"").split(" ");if(t.length>1)t.forEach(e=>this.removeCssClass(e));else if(!1!==this.cssClassStates[e]&&e.length){const t=this.getGui();t&&t.classList.remove(e),this.cssClassStates[e]=!1}}containsCssClass(e){const t=this.getGui();return!!t&&t.classList.contains(e)}addOrRemoveCssClass(e,t){if(e){if(e.indexOf(" ")>=0){const i=(e||"").split(" ");if(i.length>1)return void i.forEach(e=>this.addOrRemoveCssClass(e,t))}if(this.cssClassStates[e]!==t&&e.length){const i=this.getGui();i&&i.classList.toggle(e,t),this.cssClassStates[e]=t}}}},gn=class e extends rt{constructor(e,t,i,r){super(),this.parentComp=e,this.tooltipShowDelayOverride=t,this.tooltipHideDelayOverride=i,this.shouldDisplayTooltip=r,this.SHOW_QUICK_TOOLTIP_DIFF=1e3,this.FADE_OUT_TOOLTIP_TIMEOUT=1e3,this.INTERACTIVE_HIDE_DELAY=100,this.interactionEnabled=!1,this.isInteractingWithTooltip=!1,this.state=0,this.tooltipInstanceCount=0,this.tooltipMouseTrack=!1}postConstruct(){this.gos.get("tooltipInteraction")&&(this.interactionEnabled=!0),this.tooltipTrigger=this.getTooltipTrigger(),this.tooltipMouseTrack=this.gos.get("tooltipMouseTrack");const e=this.parentComp.getGui();0===this.tooltipTrigger&&(this.addManagedListener(e,"mouseenter",this.onMouseEnter.bind(this)),this.addManagedListener(e,"mouseleave",this.onMouseLeave.bind(this))),1===this.tooltipTrigger&&(this.addManagedListener(e,"focusin",this.onFocusIn.bind(this)),this.addManagedListener(e,"focusout",this.onFocusOut.bind(this))),this.addManagedListener(e,"mousemove",this.onMouseMove.bind(this)),this.interactionEnabled||(this.addManagedListener(e,"mousedown",this.onMouseDown.bind(this)),this.addManagedListener(e,"keydown",this.onKeyDown.bind(this)))}getGridOptionsTooltipDelay(e){const t=this.gos.get(e);return t<0&&z(`${e} should not be lower than 0`),Math.max(200,t)}getTooltipDelay(e){var t,i;return"show"===e?null!=(t=this.tooltipShowDelayOverride)?t:this.getGridOptionsTooltipDelay("tooltipShowDelay"):null!=(i=this.tooltipHideDelayOverride)?i:this.getGridOptionsTooltipDelay("tooltipHideDelay")}destroy(){this.setToDoNothing(),super.destroy()}getTooltipTrigger(){const e=this.gos.get("tooltipTrigger");return e&&"hover"!==e?1:0}onMouseEnter(t){this.interactionEnabled&&this.interactiveTooltipTimeoutId&&(this.unlockService(),this.startHideTimeout()),Di()||(e.isLocked?this.showTooltipTimeoutId=window.setTimeout(()=>{this.prepareToShowTooltip(t)},this.INTERACTIVE_HIDE_DELAY):this.prepareToShowTooltip(t))}onMouseMove(e){this.lastMouseEvent&&(this.lastMouseEvent=e),this.tooltipMouseTrack&&2===this.state&&this.tooltipComp&&this.positionTooltip()}onMouseDown(){this.setToDoNothing()}onMouseLeave(){this.interactionEnabled?this.lockService():this.setToDoNothing()}onFocusIn(){this.prepareToShowTooltip()}onFocusOut(e){var t;const i=e.relatedTarget,r=this.parentComp.getGui(),n=null==(t=this.tooltipComp)?void 0:t.getGui();this.isInteractingWithTooltip||r.contains(i)||this.interactionEnabled&&(null==n?void 0:n.contains(i))||this.setToDoNothing()}onKeyDown(){this.setToDoNothing()}prepareToShowTooltip(t){if(0!=this.state||e.isLocked)return;let i=0;t&&(i=this.isLastTooltipHiddenRecently()?200:this.getTooltipDelay("show")),this.lastMouseEvent=t||null,this.showTooltipTimeoutId=window.setTimeout(this.showTooltip.bind(this),i),this.state=1}isLastTooltipHiddenRecently(){return(new Date).getTime()-e.lastTooltipHideTime<this.SHOW_QUICK_TOOLTIP_DIFF}setToDoNothing(){2===this.state&&this.hideTooltip(),this.onBodyScrollEventCallback&&(this.onBodyScrollEventCallback(),this.onBodyScrollEventCallback=void 0),this.onColumnMovedEventCallback&&(this.onColumnMovedEventCallback(),this.onColumnMovedEventCallback=void 0),this.clearTimeouts(),this.state=0,this.lastMouseEvent=null}showTooltip(){const e=h({},this.parentComp.getTooltipParams());if(!C(e.value)||this.shouldDisplayTooltip&&!this.shouldDisplayTooltip())return void this.setToDoNothing();this.state=2,this.tooltipInstanceCount++;const t=this.newTooltipComponentCallback.bind(this,this.tooltipInstanceCount);this.userComponentFactory.getTooltipCompDetails(e).newAgStackInstance().then(t)}hideTooltip(t){if(!t&&this.isInteractingWithTooltip)return;this.tooltipComp&&(this.destroyTooltipComp(),e.lastTooltipHideTime=(new Date).getTime());const i={type:lt.EVENT_TOOLTIP_HIDE,parentGui:this.parentComp.getGui()};this.eventService.dispatchEvent(i),this.state=0}newTooltipComponentCallback(e,t){if(2!==this.state||this.tooltipInstanceCount!==e)return void this.getContext().destroyBean(t);const i=t.getGui();this.tooltipComp=t,i.classList.contains("ag-tooltip")||i.classList.add("ag-tooltip-custom"),0===this.tooltipTrigger&&i.classList.add("ag-tooltip-animate"),this.interactionEnabled&&i.classList.add("ag-tooltip-interactive");const r=this.localeService.getLocaleTextFunc(),n=this.popupService.addPopup({eChild:i,ariaLabel:r("ariaLabelTooltip","Tooltip")});n&&(this.tooltipPopupDestroyFunc=n.hideFunc),this.positionTooltip(),1===this.tooltipTrigger&&(this.onBodyScrollEventCallback=this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL,this.setToDoNothing.bind(this)),this.onColumnMovedEventCallback=this.addManagedListener(this.eventService,lt.EVENT_COLUMN_MOVED,this.setToDoNothing.bind(this))),this.interactionEnabled&&(0===this.tooltipTrigger?(this.tooltipMouseEnterListener=this.addManagedListener(i,"mouseenter",this.onTooltipMouseEnter.bind(this))||null,this.tooltipMouseLeaveListener=this.addManagedListener(i,"mouseleave",this.onTooltipMouseLeave.bind(this))||null):(this.tooltipFocusInListener=this.addManagedListener(i,"focusin",this.onTooltipFocusIn.bind(this))||null,this.tooltipFocusOutListener=this.addManagedListener(i,"focusout",this.onTooltipFocusOut.bind(this))||null));const s={type:lt.EVENT_TOOLTIP_SHOW,tooltipGui:i,parentGui:this.parentComp.getGui()};this.eventService.dispatchEvent(s),this.startHideTimeout()}onTooltipMouseEnter(){this.isInteractingWithTooltip=!0,this.unlockService()}onTooltipMouseLeave(){this.isInteractingWithTooltip=!1,this.lockService()}onTooltipFocusIn(){this.isInteractingWithTooltip=!0}onTooltipFocusOut(e){var t;const i=this.parentComp.getGui(),r=null==(t=this.tooltipComp)?void 0:t.getGui(),n=e.relatedTarget;(null==r?void 0:r.contains(n))||(this.isInteractingWithTooltip=!1,i.contains(n)?this.startHideTimeout():this.hideTooltip())}positionTooltip(){const e={type:"tooltip",ePopup:this.tooltipComp.getGui(),nudgeY:18,skipObserver:this.tooltipMouseTrack};this.lastMouseEvent?this.popupService.positionPopupUnderMouseEvent(d(h({},e),{mouseEvent:this.lastMouseEvent})):this.popupService.positionPopupByComponent(d(h({},e),{eventSource:this.parentComp.getGui(),position:"under",keepWithinBounds:!0,nudgeY:5}))}destroyTooltipComp(){this.tooltipComp.getGui().classList.add("ag-tooltip-hiding");const e=this.tooltipPopupDestroyFunc,t=this.tooltipComp,i=0===this.tooltipTrigger?this.FADE_OUT_TOOLTIP_TIMEOUT:0;window.setTimeout(()=>{e(),this.getContext().destroyBean(t)},i),this.clearTooltipListeners(),this.tooltipPopupDestroyFunc=void 0,this.tooltipComp=void 0}clearTooltipListeners(){[this.tooltipMouseEnterListener,this.tooltipMouseLeaveListener,this.tooltipFocusInListener,this.tooltipFocusOutListener].forEach(e=>{e&&e()}),this.tooltipMouseEnterListener=this.tooltipMouseLeaveListener=this.tooltipFocusInListener=this.tooltipFocusOutListener=null}lockService(){e.isLocked=!0,this.interactiveTooltipTimeoutId=window.setTimeout(()=>{this.unlockService(),this.setToDoNothing()},this.INTERACTIVE_HIDE_DELAY)}unlockService(){e.isLocked=!1,this.clearInteractiveTimeout()}startHideTimeout(){this.clearHideTimeout(),this.hideTooltipTimeoutId=window.setTimeout(this.hideTooltip.bind(this),this.getTooltipDelay("hide"))}clearShowTimeout(){this.showTooltipTimeoutId&&(window.clearTimeout(this.showTooltipTimeoutId),this.showTooltipTimeoutId=void 0)}clearHideTimeout(){this.hideTooltipTimeoutId&&(window.clearTimeout(this.hideTooltipTimeoutId),this.hideTooltipTimeoutId=void 0)}clearInteractiveTimeout(){this.interactiveTooltipTimeoutId&&(window.clearTimeout(this.interactiveTooltipTimeoutId),this.interactiveTooltipTimeoutId=void 0)}clearTimeouts(){this.clearShowTimeout(),this.clearHideTimeout(),this.clearInteractiveTimeout()}};gn.isLocked=!1,g([ue("popupService")],gn.prototype,"popupService",2),g([ue("userComponentFactory")],gn.prototype,"userComponentFactory",2),g([ae],gn.prototype,"postConstruct",1);var fn=gn,mn=class extends rt{constructor(e,t){super(),this.ctrl=e,t&&(this.beans=t)}postConstruct(){this.refreshToolTip()}setBrowserTooltip(e){const t="title",i=this.ctrl.getGui();i&&(null!=e&&""!=e?i.setAttribute(t,e):i.removeAttribute(t))}updateTooltipText(){this.tooltip=this.ctrl.getTooltipValue()}createTooltipFeatureIfNeeded(){var e,t,i,r;if(null!=this.tooltipManager)return;const n={getTooltipParams:()=>this.getTooltipParams(),getGui:()=>this.ctrl.getGui()};this.tooltipManager=this.createBean(new fn(n,null==(t=(e=this.ctrl).getTooltipShowDelayOverride)?void 0:t.call(e),null==(r=(i=this.ctrl).getTooltipHideDelayOverride)?void 0:r.call(i),this.ctrl.shouldDisplayTooltip),this.beans.context)}refreshToolTip(){this.browserTooltips=this.beans.gos.get("enableBrowserTooltips"),this.updateTooltipText(),this.browserTooltips?(this.setBrowserTooltip(this.tooltip),this.tooltipManager&&(this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context))):(this.setBrowserTooltip(null),this.createTooltipFeatureIfNeeded())}getTooltipParams(){const e=this.ctrl,t=e.getColumn?e.getColumn():void 0,i=e.getColDef?e.getColDef():void 0,r=e.getRowNode?e.getRowNode():void 0;return{location:e.getLocation(),colDef:i,column:t,rowIndex:e.getRowIndex?e.getRowIndex():void 0,node:r,data:r?r.data:void 0,value:this.getTooltipText(),valueFormatted:e.getValueFormatted?e.getValueFormatted():void 0,hideTooltipCallback:()=>{var e;return null==(e=this.tooltipManager)?void 0:e.hideTooltip(!0)}}}getTooltipText(){return this.tooltip}destroy(){this.tooltipManager&&(this.tooltipManager=this.destroyBean(this.tooltipManager,this.beans.context)),super.destroy()}};g([ue("beans")],mn.prototype,"beans",2),g([ae],mn.prototype,"postConstruct",1);var vn=new cn,Cn=class e extends rt{constructor(e){super(),this.displayed=!0,this.visible=!0,this.compId=vn.next(),this.cssClassManager=new pn(()=>this.eGui),e&&this.setTemplate(e)}preConstructOnComponent(){this.usingBrowserTooltips=this.gos.get("enableBrowserTooltips")}getCompId(){return this.compId}getTooltipParams(){return{value:this.tooltipText,location:"UNKNOWN"}}setTooltip(e){const{newTooltipText:t,showDelayOverride:i,hideDelayOverride:r,location:n,shouldDisplayTooltip:s}=e||{};this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),this.tooltipText!==t&&(this.tooltipText=t);null!=t&&(this.tooltipFeature=this.createBean(new mn({getTooltipValue:()=>this.tooltipText,getGui:()=>this.getGui(),getLocation:()=>null!=n?n:"UNKNOWN",getColDef:null==e?void 0:e.getColDef,getColumn:null==e?void 0:e.getColumn,getTooltipShowDelayOverride:null!=i?()=>i:void 0,getTooltipHideDelayOverride:null!=r?()=>r:void 0,shouldDisplayTooltip:s})))}createChildComponentsFromTags(e,t){Or(e.childNodes).forEach(i=>{if(!(i instanceof HTMLElement))return;const r=this.createComponentFromElement(i,e=>{e.getGui()&&this.copyAttributesFromNode(i,e.getGui())},t);if(r){if(r.addItems&&i.children.length){this.createChildComponentsFromTags(i,t);const e=Array.prototype.slice.call(i.children);r.addItems(e)}this.swapComponentForNode(r,e,i)}else i.childNodes&&this.createChildComponentsFromTags(i,t)})}createComponentFromElement(t,i,r){const n=t.nodeName,s=r?r[t.getAttribute("ref")]:void 0,o=this.agStackComponentsRegistry.getComponentClass(n);if(o){e.elementGettingCreated=t;const r=new o(s);return r.setParentComponent(this),this.createBean(r,null,i),r}return null}copyAttributesFromNode(e,t){Fr(e.attributes,(e,i)=>t.setAttribute(e,i))}swapComponentForNode(e,t,i){const r=e.getGui();t.replaceChild(r,i),t.insertBefore(document.createComment(i.nodeName),r),this.addDestroyFunc(this.destroyBean.bind(this,e)),this.swapInComponentForQuerySelectors(e,i)}swapInComponentForQuerySelectors(e,t){const i=this;this.iterateOverQuerySelectors(r=>{i[r.attributeName]===t&&(i[r.attributeName]=e)})}iterateOverQuerySelectors(e){let t=Object.getPrototypeOf(this);for(;null!=t;){const i=t.__agComponentMetaData,r=W(t.constructor);i&&i[r]&&i[r].querySelectors&&i[r].querySelectors.forEach(t=>e(t)),t=Object.getPrototypeOf(t)}}activateTabIndex(e){const t=this.gos.get("tabIndex");e||(e=[]),e.length||e.push(this.getGui()),e.forEach(e=>e.setAttribute("tabindex",t.toString()))}setTemplate(e,t){const i=br(e);this.setTemplateFromElement(i,t)}setTemplateFromElement(e,t){this.eGui=e,this.eGui.__agComponent=this,this.wireQuerySelectors(),this.getContext()&&this.createChildComponentsFromTags(this.getGui(),t)}createChildComponentsPreConstruct(){this.getGui()&&this.createChildComponentsFromTags(this.getGui())}wireQuerySelectors(){if(!this.eGui)return;const e=this;this.iterateOverQuerySelectors(t=>{const i=i=>e[t.attributeName]=i;if(t.refSelector&&this.getAttribute("ref")===t.refSelector)i(this.eGui);else{const e=this.eGui.querySelector(t.querySelector);e&&i(e.__agComponent||e)}})}getGui(){return this.eGui}getFocusableElement(){return this.eGui}getAriaElement(){return this.getFocusableElement()}setParentComponent(e){this.parentComponent=e}getParentComponent(){return this.parentComponent}setGui(e){this.eGui=e}queryForHtmlElement(e){return this.eGui.querySelector(e)}queryForHtmlInputElement(e){return this.eGui.querySelector(e)}appendChild(e,t){if(null!=e)if(t||(t=this.eGui),Nr(e))t.appendChild(e);else{const i=e;t.appendChild(i.getGui())}}isDisplayed(){return this.displayed}setVisible(e,t={}){if(e!==this.visible){this.visible=e;const{skipAriaHidden:i}=t;or(this.eGui,e,{skipAriaHidden:i})}}setDisplayed(t,i={}){if(t!==this.displayed){this.displayed=t;const{skipAriaHidden:r}=i;sr(this.eGui,t,{skipAriaHidden:r});const n={type:e.EVENT_DISPLAYED_CHANGED,visible:this.displayed};this.dispatchEvent(n)}}destroy(){this.parentComponent&&(this.parentComponent=void 0),this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const e=this.eGui;e&&e.__agComponent&&(e.__agComponent=void 0),super.destroy()}addGuiEventListener(e,t,i){this.eGui.addEventListener(e,t,i),this.addDestroyFunc(()=>this.eGui.removeEventListener(e,t))}addCssClass(e){this.cssClassManager.addCssClass(e)}removeCssClass(e){this.cssClassManager.removeCssClass(e)}containsCssClass(e){return this.cssClassManager.containsCssClass(e)}addOrRemoveCssClass(e,t){this.cssClassManager.addOrRemoveCssClass(e,t)}getAttribute(e){const{eGui:t}=this;return t?t.getAttribute(e):null}getRefElement(e){return this.queryForHtmlElement(`[ref="${e}"]`)}};Cn.EVENT_DISPLAYED_CHANGED="displayedChanged",g([ue("agStackComponentsRegistry")],Cn.prototype,"agStackComponentsRegistry",2),g([oe],Cn.prototype,"preConstructOnComponent",1),g([oe],Cn.prototype,"createChildComponentsPreConstruct",1);var yn=Cn;function wn(e){return bn.bind(this,e,void 0)}function Sn(e){return bn.bind(this,`[ref=${e}]`,e)}function bn(e,t,i,r,n){null!==e?"number"!=typeof n?function(e,t,i){const r=function(e,t){return e.__agComponentMetaData||(e.__agComponentMetaData={}),e.__agComponentMetaData[t]||(e.__agComponentMetaData[t]={}),e.__agComponentMetaData[t]}(e,W(e.constructor));r[t]||(r[t]=[]),r[t].push(i)}(i,"querySelectors",{attributeName:r,querySelector:e,refSelector:t}):console.error("AG Grid: QuerySelector should be on an attribute"):console.error("AG Grid: QuerySelector selector should not be null")}var En=class extends yn{constructor(){super('\n            <div class="ag-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eFloatingFilterText"></ag-input-text-field>\n            </div>')}destroy(){super.destroy()}init(e){this.params=e;const t=this.columnModel.getDisplayNameForColumn(e.column,"header",!0),i=this.localeService.getLocaleTextFunc();this.eFloatingFilterText.setDisabled(!0).setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}onParentModelChanged(e){null!=e?this.params.parentFilterInstance(t=>{if(t.getModelAsString){const i=t.getModelAsString(e);this.eFloatingFilterText.setValue(i)}}):this.eFloatingFilterText.setValue("")}onParamsUpdated(e){this.refresh(e)}refresh(e){this.init(e)}};g([Sn("eFloatingFilterText")],En.prototype,"eFloatingFilterText",2),g([ue("columnModel")],En.prototype,"columnModel",2);var An=class{constructor(e,t,i,r,n){this.alive=!0,this.context=e,this.eParent=r,t.getDateCompDetails(i).newAgStackInstance().then(t=>{this.alive?(this.dateComp=t,t&&(r.appendChild(t.getGui()),t.afterGuiAttached&&t.afterGuiAttached(),this.tempValue&&t.setDate(this.tempValue),null!=this.disabled&&this.setDateCompDisabled(this.disabled),null==n||n(this))):e.destroyBean(t)})}destroy(){this.alive=!1,this.dateComp=this.context.destroyBean(this.dateComp)}getDate(){return this.dateComp?this.dateComp.getDate():this.tempValue}setDate(e){this.dateComp?this.dateComp.setDate(e):this.tempValue=e}setDisabled(e){this.dateComp?this.setDateCompDisabled(e):this.disabled=e}setDisplayed(e){sr(this.eParent,e)}setInputPlaceholder(e){this.dateComp&&this.dateComp.setInputPlaceholder&&this.dateComp.setInputPlaceholder(e)}setInputAriaLabel(e){this.dateComp&&this.dateComp.setInputAriaLabel&&this.dateComp.setInputAriaLabel(e)}afterGuiAttached(e){this.dateComp&&"function"==typeof this.dateComp.afterGuiAttached&&this.dateComp.afterGuiAttached(e)}updateParams(e){var t,i;let r=!1;(null==(t=this.dateComp)?void 0:t.refresh)&&"function"==typeof this.dateComp.refresh&&null!==this.dateComp.refresh(e)&&(r=!0),!r&&(null==(i=this.dateComp)?void 0:i.onParamsUpdated)&&"function"==typeof this.dateComp.onParamsUpdated&&null!==this.dateComp.onParamsUpdated(e)&&z("Custom date component method 'onParamsUpdated' is deprecated. Use 'refresh' instead.")}setDateCompDisabled(e){null!=this.dateComp&&null!=this.dateComp.setDisabled&&this.dateComp.setDisabled(e)}},Tn=class{constructor(){this.customFilterOptions={}}init(e,t){this.filterOptions=e.filterOptions||t,this.mapCustomOptions(),this.selectDefaultItem(e)}getFilterOptions(){return this.filterOptions}mapCustomOptions(){this.filterOptions&&this.filterOptions.forEach(e=>{"string"!=typeof e&&([["displayKey"],["displayName"],["predicate","test"]].every(t=>!!t.some(t=>null!=e[t])||(console.warn(`AG Grid: ignoring FilterOptionDef as it doesn't contain one of '${t}'`),!1))?this.customFilterOptions[e.displayKey]=e:this.filterOptions=this.filterOptions.filter(t=>t===e)||[])})}selectDefaultItem(e){if(e.defaultOption)this.defaultOption=e.defaultOption;else if(this.filterOptions.length>=1){const e=this.filterOptions[0];"string"==typeof e?this.defaultOption=e:e.displayKey?this.defaultOption=e.displayKey:console.warn("AG Grid: invalid FilterOptionDef supplied as it doesn't contain a 'displayKey'")}else console.warn("AG Grid: no filter options for filter")}getDefaultOption(){return this.defaultOption}getCustomOption(e){return this.customFilterOptions[e]}},Mn={applyFilter:"Apply",clearFilter:"Clear",resetFilter:"Reset",cancelFilter:"Cancel",textFilter:"Text Filter",numberFilter:"Number Filter",dateFilter:"Date Filter",setFilter:"Set Filter",filterOoo:"Filter...",empty:"Choose one",equals:"Equals",notEqual:"Does not equal",lessThan:"Less than",greaterThan:"Greater than",inRange:"Between",inRangeStart:"From",inRangeEnd:"To",lessThanOrEqual:"Less than or equal to",greaterThanOrEqual:"Greater than or equal to",contains:"Contains",notContains:"Does not contain",startsWith:"Begins with",endsWith:"Ends with",blank:"Blank",notBlank:"Not blank",before:"Before",after:"After",andCondition:"AND",orCondition:"OR",dateFormatOoo:"yyyy-mm-dd"},Rn=class e extends rt{constructor(e,t={}){super(),this.eFocusableElement=e,this.callbacks=t,this.callbacks=h({shouldStopEventPropagation:()=>!1,onTabKeyDown:e=>{if(e.defaultPrevented)return;const t=this.focusService.findNextFocusableElement(this.eFocusableElement,!1,e.shiftKey);t&&(t.focus(),e.preventDefault())}},t)}postConstruct(){this.eFocusableElement.classList.add(e.FOCUS_MANAGED_CLASS),this.addKeyDownListeners(this.eFocusableElement),this.callbacks.onFocusIn&&this.addManagedListener(this.eFocusableElement,"focusin",this.callbacks.onFocusIn),this.callbacks.onFocusOut&&this.addManagedListener(this.eFocusableElement,"focusout",this.callbacks.onFocusOut)}addKeyDownListeners(e){this.addManagedListener(e,"keydown",e=>{e.defaultPrevented||Ye(e)||(this.callbacks.shouldStopEventPropagation(e)?qe(e):e.key===Yr.TAB?this.callbacks.onTabKeyDown(e):this.callbacks.handleKeyDown&&this.callbacks.handleKeyDown(e))})}};Rn.FOCUS_MANAGED_CLASS="ag-focus-managed",g([ue("focusService")],Rn.prototype,"focusService",2),g([ae],Rn.prototype,"postConstruct",1);var _n=Rn,Pn="ag-resizer-wrapper",xn=`<div class="${Pn}">\n        <div ref="eTopLeftResizer" class="ag-resizer ag-resizer-topLeft"></div>\n        <div ref="eTopResizer" class="ag-resizer ag-resizer-top"></div>\n        <div ref="eTopRightResizer" class="ag-resizer ag-resizer-topRight"></div>\n        <div ref="eRightResizer" class="ag-resizer ag-resizer-right"></div>\n        <div ref="eBottomRightResizer" class="ag-resizer ag-resizer-bottomRight"></div>\n        <div ref="eBottomResizer" class="ag-resizer ag-resizer-bottom"></div>\n        <div ref="eBottomLeftResizer" class="ag-resizer ag-resizer-bottomLeft"></div>\n        <div ref="eLeftResizer" class="ag-resizer ag-resizer-left"></div>\n    </div>`,Dn=class extends rt{constructor(e,t){super(),this.element=e,this.dragStartPosition={x:0,y:0},this.position={x:0,y:0},this.lastSize={width:-1,height:-1},this.positioned=!1,this.resizersAdded=!1,this.resizeListeners=[],this.boundaryEl=null,this.isResizing=!1,this.isMoving=!1,this.resizable={},this.movable=!1,this.currentResizer=null,this.config=Object.assign({},{popup:!1},t)}center(){const{clientHeight:e,clientWidth:t}=this.offsetParent,i=t/2-this.getWidth()/2,r=e/2-this.getHeight()/2;this.offsetElement(i,r)}initialisePosition(){if(this.positioned)return;const{centered:e,forcePopupParentAsOffsetParent:t,minWidth:i,width:r,minHeight:n,height:s,x:o,y:a}=this.config;this.offsetParent||this.setOffsetParent();let l=0,c=0;const u=Sr(this.element);if(u){const e=this.findBoundaryElement(),t=window.getComputedStyle(e);if(null!=t.minWidth){const i=e.offsetWidth-this.element.offsetWidth;c=parseInt(t.minWidth,10)-i}if(null!=t.minHeight){const i=e.offsetHeight-this.element.offsetHeight;l=parseInt(t.minHeight,10)-i}}if(this.minHeight=n||l,this.minWidth=i||c,r&&this.setWidth(r),s&&this.setHeight(s),r&&s||this.refreshSize(),e)this.center();else if(o||a)this.offsetElement(o,a);else if(u&&t){let e=this.boundaryEl,t=!0;if(e||(e=this.findBoundaryElement(),t=!1),e){const i=parseFloat(e.style.top),r=parseFloat(e.style.left);t?this.offsetElement(isNaN(r)?0:r,isNaN(i)?0:i):this.setPosition(r,i)}}this.positioned=!!this.offsetParent}isPositioned(){return this.positioned}getPosition(){return this.position}setMovable(e,t){if(!this.config.popup||e===this.movable)return;this.movable=e;const i=this.moveElementDragListener||{eElement:t,onDragStart:this.onMoveStart.bind(this),onDragging:this.onMove.bind(this),onDragStop:this.onMoveEnd.bind(this)};e?(this.dragService.addDragSource(i),this.moveElementDragListener=i):(this.dragService.removeDragSource(i),this.moveElementDragListener=void 0)}setResizable(e){if(this.clearResizeListeners(),e?this.addResizers():this.removeResizers(),"boolean"==typeof e){if(!1===e)return;e={topLeft:e,top:e,topRight:e,right:e,bottomRight:e,bottom:e,bottomLeft:e,left:e}}Object.keys(e).forEach(t=>{const i=!!e[t],r=this.getResizerElement(t),n={dragStartPixels:0,eElement:r,onDragStart:e=>this.onResizeStart(e,t),onDragging:this.onResize.bind(this),onDragStop:e=>this.onResizeEnd(e,t)};(i||!this.isAlive()&&!i)&&(i?(this.dragService.addDragSource(n),this.resizeListeners.push(n),r.style.pointerEvents="all"):r.style.pointerEvents="none",this.resizable[t]=i)})}removeSizeFromEl(){this.element.style.removeProperty("height"),this.element.style.removeProperty("width"),this.element.style.removeProperty("flex")}restoreLastSize(){this.element.style.flex="0 0 auto";const{height:e,width:t}=this.lastSize;-1!==t&&(this.element.style.width=`${t}px`),-1!==e&&(this.element.style.height=`${e}px`)}getHeight(){return this.element.offsetHeight}setHeight(e){const{popup:t}=this.config,i=this.element;let r=!1;if("string"==typeof e&&-1!==e.indexOf("%"))Ir(i,e),e=dr(i),r=!0;else if(e=Math.max(this.minHeight,e),this.positioned){const t=this.getAvailableHeight();t&&e>t&&(e=t)}this.getHeight()!==e&&(r?(i.style.maxHeight="unset",i.style.minHeight="unset"):t?Ir(i,e):(i.style.height=`${e}px`,i.style.flex="0 0 auto",this.lastSize.height="number"==typeof e?e:parseFloat(e)))}getAvailableHeight(){const{popup:e,forcePopupParentAsOffsetParent:t}=this.config;this.positioned||this.initialisePosition();const{clientHeight:i}=this.offsetParent;if(!i)return null;const r=this.element.getBoundingClientRect(),n=this.offsetParent.getBoundingClientRect(),s=e?this.position.y:r.top,o=e?0:n.top;let a=0;if(t){const e=this.element.parentElement;if(e){const{bottom:t}=e.getBoundingClientRect();a=t-r.bottom}}return i+o-s-a}getWidth(){return this.element.offsetWidth}setWidth(e){const t=this.element,{popup:i}=this.config;let r=!1;if("string"==typeof e&&-1!==e.indexOf("%"))xr(t,e),e=pr(t),r=!0;else if(this.positioned){e=Math.max(this.minWidth,e);const{clientWidth:t}=this.offsetParent,r=i?this.position.x:this.element.getBoundingClientRect().left;t&&e+r>t&&(e=t-r)}this.getWidth()!==e&&(r?(t.style.maxWidth="unset",t.style.minWidth="unset"):this.config.popup?xr(t,e):(t.style.width=`${e}px`,t.style.flex=" unset",this.lastSize.width="number"==typeof e?e:parseFloat(e)))}offsetElement(e=0,t=0){const{forcePopupParentAsOffsetParent:i}=this.config,r=i?this.boundaryEl:this.element;r&&(this.popupService.positionPopup({ePopup:r,keepWithinBounds:!0,skipObserver:this.movable||this.isResizable(),updatePosition:()=>({x:e,y:t})}),this.setPosition(parseFloat(r.style.left),parseFloat(r.style.top)))}constrainSizeToAvailableHeight(e){if(!this.config.forcePopupParentAsOffsetParent)return;e?this.resizeObserverSubscriber=this.resizeObserverService.observeResize(this.popupService.getPopupParent(),()=>{const e=this.getAvailableHeight();this.element.style.setProperty("max-height",`${e}px`)}):(this.element.style.removeProperty("max-height"),this.resizeObserverSubscriber&&(this.resizeObserverSubscriber(),this.resizeObserverSubscriber=void 0))}setPosition(e,t){this.position.x=e,this.position.y=t}updateDragStartPosition(e,t){this.dragStartPosition={x:e,y:t}}calculateMouseMovement(e){const{e:t,isLeft:i,isTop:r,anywhereWithin:n,topBuffer:s}=e,o=t.clientX-this.dragStartPosition.x,a=t.clientY-this.dragStartPosition.y;return{movementX:this.shouldSkipX(t,!!i,!!n,o)?0:o,movementY:this.shouldSkipY(t,!!r,s,a)?0:a}}shouldSkipX(e,t,i,r){const n=this.element.getBoundingClientRect(),s=this.offsetParent.getBoundingClientRect(),o=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.x:n.left;let l=a<=0&&s.left>=e.clientX||s.right<=e.clientX&&s.right<=o.right;return!!l||(l=t?r<0&&e.clientX>a+s.left||r>0&&e.clientX<a+s.left:i?r<0&&e.clientX>o.right||r>0&&e.clientX<a+s.left:r<0&&e.clientX>o.right||r>0&&e.clientX<o.right,l)}shouldSkipY(e,t,i=0,r){const n=this.element.getBoundingClientRect(),s=this.offsetParent.getBoundingClientRect(),o=this.boundaryEl.getBoundingClientRect(),a=this.config.popup?this.position.y:n.top;let l=a<=0&&s.top>=e.clientY||s.bottom<=e.clientY&&s.bottom<=o.bottom;return!!l||(l=t?r<0&&e.clientY>a+s.top+i||r>0&&e.clientY<a+s.top:r<0&&e.clientY>o.bottom||r>0&&e.clientY<o.bottom,l)}createResizeMap(){const e=this.element;this.resizerMap={topLeft:{element:e.querySelector("[ref=eTopLeftResizer]")},top:{element:e.querySelector("[ref=eTopResizer]")},topRight:{element:e.querySelector("[ref=eTopRightResizer]")},right:{element:e.querySelector("[ref=eRightResizer]")},bottomRight:{element:e.querySelector("[ref=eBottomRightResizer]")},bottom:{element:e.querySelector("[ref=eBottomResizer]")},bottomLeft:{element:e.querySelector("[ref=eBottomLeftResizer]")},left:{element:e.querySelector("[ref=eLeftResizer]")}}}addResizers(){if(this.resizersAdded)return;const e=this.element;if(!e)return;const t=(new DOMParser).parseFromString(xn,"text/html").body;e.appendChild(t.firstChild),this.createResizeMap(),this.resizersAdded=!0}removeResizers(){this.resizerMap=void 0;const e=this.element.querySelector(`.${Pn}`);e&&this.element.removeChild(e),this.resizersAdded=!1}getResizerElement(e){return this.resizerMap[e].element}onResizeStart(e,t){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.currentResizer={isTop:!!t.match(/top/i),isRight:!!t.match(/right/i),isBottom:!!t.match(/bottom/i),isLeft:!!t.match(/left/i)},this.element.classList.add("ag-resizing"),this.resizerMap[t].element.classList.add("ag-active");const{popup:i,forcePopupParentAsOffsetParent:r}=this.config;i||r||this.applySizeToSiblings(this.currentResizer.isBottom||this.currentResizer.isTop),this.isResizing=!0,this.updateDragStartPosition(e.clientX,e.clientY)}getSiblings(){const e=this.element.parentElement;return e?Array.prototype.slice.call(e.children).filter(e=>!e.classList.contains("ag-hidden")):null}getMinSizeOfSiblings(){const e=this.getSiblings()||[];let t=0,i=0;for(let r=0;r<e.length;r++){const n=e[r],s=!!n.style.flex&&"0 0 auto"!==n.style.flex;if(n===this.element)continue;let o=this.minHeight||0,a=this.minWidth||0;if(s){const e=window.getComputedStyle(n);e.minHeight&&(o=parseInt(e.minHeight,10)),e.minWidth&&(a=parseInt(e.minWidth,10))}else o=n.offsetHeight,a=n.offsetWidth;t+=o,i+=a}return{height:t,width:i}}applySizeToSiblings(e){let t=null;const i=this.getSiblings();if(i){for(let r=0;r<i.length;r++){const n=i[r];n!==t&&(e?n.style.height=`${n.offsetHeight}px`:n.style.width=`${n.offsetWidth}px`,n.style.flex="0 0 auto",n===this.element&&(t=i[r+1]))}t&&(t.style.removeProperty("height"),t.style.removeProperty("min-height"),t.style.removeProperty("max-height"),t.style.flex="1 1 auto")}}isResizable(){return Object.values(this.resizable).some(e=>e)}onResize(e){if(!this.isResizing||!this.currentResizer)return;const{popup:t,forcePopupParentAsOffsetParent:i}=this.config,{isTop:r,isRight:n,isBottom:s,isLeft:o}=this.currentResizer,a=n||o,l=s||r,{movementX:c,movementY:u}=this.calculateMouseMovement({e,isLeft:o,isTop:r}),h=this.position.x,d=this.position.y;let p=0,g=0;if(a&&c){const e=o?-1:1,t=this.getWidth(),i=t+c*e;let r=!1;o&&(p=t-i,(h+p<=0||i<=this.minWidth)&&(r=!0,p=0)),r||this.setWidth(i)}if(l&&u){const e=r?-1:1,t=this.getHeight(),i=t+u*e;let n=!1;r?(g=t-i,(d+g<=0||i<=this.minHeight)&&(n=!0,g=0)):!this.config.popup&&!this.config.forcePopupParentAsOffsetParent&&t<i&&this.getMinSizeOfSiblings().height+i>this.element.parentElement.offsetHeight&&(n=!0),n||this.setHeight(i)}this.updateDragStartPosition(e.clientX,e.clientY),((t||i)&&p||g)&&this.offsetElement(h+p,d+g)}onResizeEnd(e,t){this.isResizing=!1,this.currentResizer=null,this.boundaryEl=null,this.element.classList.remove("ag-resizing"),this.resizerMap[t].element.classList.remove("ag-active"),this.dispatchEvent({type:"resize"})}refreshSize(){const e=this.element;this.config.popup&&(this.config.width||this.setWidth(e.offsetWidth),this.config.height||this.setHeight(e.offsetHeight))}onMoveStart(e){this.boundaryEl=this.findBoundaryElement(),this.positioned||this.initialisePosition(),this.isMoving=!0,this.element.classList.add("ag-moving"),this.updateDragStartPosition(e.clientX,e.clientY)}onMove(e){if(!this.isMoving)return;const{x:t,y:i}=this.position;let r;this.config.calculateTopBuffer&&(r=this.config.calculateTopBuffer());const{movementX:n,movementY:s}=this.calculateMouseMovement({e,isTop:!0,anywhereWithin:!0,topBuffer:r});this.offsetElement(t+n,i+s),this.updateDragStartPosition(e.clientX,e.clientY)}onMoveEnd(){this.isMoving=!1,this.boundaryEl=null,this.element.classList.remove("ag-moving")}setOffsetParent(){this.config.forcePopupParentAsOffsetParent?this.offsetParent=this.popupService.getPopupParent():this.offsetParent=this.element.offsetParent}findBoundaryElement(){let e=this.element;for(;e;){if("static"!==window.getComputedStyle(e).position)return e;e=e.parentElement}return this.element}clearResizeListeners(){for(;this.resizeListeners.length;){const e=this.resizeListeners.pop();this.dragService.removeDragSource(e)}}destroy(){super.destroy(),this.moveElementDragListener&&this.dragService.removeDragSource(this.moveElementDragListener),this.constrainSizeToAvailableHeight(!1),this.clearResizeListeners(),this.removeResizers()}};g([ue("popupService")],Dn.prototype,"popupService",2),g([ue("resizeObserverService")],Dn.prototype,"resizeObserverService",2),g([ue("dragService")],Dn.prototype,"dragService",2);var In=class e extends yn{constructor(e){super(),this.filterNameKey=e,this.applyActive=!1,this.hidePopup=null,this.debouncePending=!1,this.appliedModel=null,this.buttonListeners=[]}postConstruct(){this.resetTemplate(),this.createManagedBean(new _n(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.positionableFeature=new Dn(this.getPositionableElement(),{forcePopupParentAsOffsetParent:!0}),this.createBean(this.positionableFeature)}handleKeyDown(e){}getFilterTitle(){return this.translate(this.filterNameKey)}isFilterActive(){return!!this.appliedModel}resetTemplate(e){let t=this.getGui();t&&t.removeEventListener("submit",this.onFormSubmit);const i=`\n            <form class="ag-filter-wrapper">\n                <div class="ag-filter-body-wrapper ag-${this.getCssIdentifier()}-body-wrapper" ref="eFilterBody">\n                    ${this.createBodyTemplate()}\n                </div>\n            </form>`;this.setTemplate(i,e),t=this.getGui(),t&&t.addEventListener("submit",this.onFormSubmit)}isReadOnly(){return!!this.providedFilterParams.readOnly}init(e){this.setParams(e),this.resetUiToDefaults(!0).then(()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}setParams(t){this.providedFilterParams=t,this.applyActive=e.isUseApplyButton(t),this.resetButtonsPanel()}updateParams(t){this.providedFilterParams=t,this.applyActive=e.isUseApplyButton(t),this.resetUiToActiveModel(this.getModel(),()=>{this.updateUiVisibility(),this.setupOnBtApplyDebounce()})}resetButtonsPanel(){const{buttons:e}=this.providedFilterParams,t=e&&e.length>0&&!this.isReadOnly();if(this.eButtonsPanel?(Cr(this.eButtonsPanel),this.buttonListeners.forEach(e=>null==e?void 0:e()),this.buttonListeners=[]):t&&(this.eButtonsPanel=document.createElement("div"),this.eButtonsPanel.classList.add("ag-filter-apply-panel")),!t)return void(this.eButtonsPanel&&yr(this.eButtonsPanel));const i=document.createDocumentFragment(),r=e=>{let t,r;switch(e){case"apply":t=this.translate("applyFilter"),r=e=>this.onBtApply(!1,!1,e);break;case"clear":t=this.translate("clearFilter"),r=()=>this.onBtClear();break;case"reset":t=this.translate("resetFilter"),r=()=>this.onBtReset();break;case"cancel":t=this.translate("cancelFilter"),r=e=>{this.onBtCancel(e)};break;default:return void console.warn("AG Grid: Unknown button type specified")}const n=br(`<button\n                    type="${"apply"===e?"submit":"button"}"\n                    ref="${e}FilterButton"\n                    class="ag-button ag-standard-button ag-filter-apply-panel-button"\n                >${t}\n                </button>`);this.buttonListeners.push(this.addManagedListener(n,"click",r)),i.append(n)};an(e).forEach(e=>r(e)),this.eButtonsPanel.append(i),this.getGui().appendChild(this.eButtonsPanel)}getDefaultDebounceMs(){return 0}setupOnBtApplyDebounce(){const t=e.getDebounceMs(this.providedFilterParams,this.getDefaultDebounceMs()),i=X(this.checkApplyDebounce.bind(this),t);this.onBtApplyDebounce=()=>{this.debouncePending=!0,i()}}checkApplyDebounce(){this.debouncePending&&(this.debouncePending=!1,this.onBtApply())}getModel(){return this.appliedModel?this.appliedModel:null}setModel(e){return(null!=e?this.setModelIntoUi(e):this.resetUiToDefaults()).then(()=>{this.updateUiVisibility(),this.applyModel("api")})}onBtCancel(e){this.resetUiToActiveModel(this.getModel(),()=>{this.handleCancelEnd(e)})}handleCancelEnd(e){this.providedFilterParams.closeOnApply&&this.close(e)}resetUiToActiveModel(e,t){const i=()=>{this.onUiChanged(!1,"prevent"),null==t||t()};null!=e?this.setModelIntoUi(e).then(i):this.resetUiToDefaults().then(i)}onBtClear(){this.resetUiToDefaults().then(()=>this.onUiChanged())}onBtReset(){this.onBtClear(),this.onBtApply()}applyModel(e="api"){const t=this.getModelFromUi();if(!this.isModelValid(t))return!1;const i=this.appliedModel;return this.appliedModel=t,!this.areModelsEqual(i,t)}isModelValid(e){return!0}onFormSubmit(e){e.preventDefault()}onBtApply(e=!1,t=!1,i){if(i&&i.preventDefault(),this.applyModel(t?"rowDataUpdated":"ui")){const i="columnFilter";this.providedFilterParams.filterChangedCallback({afterFloatingFilter:e,afterDataChange:t,source:i})}const{closeOnApply:r}=this.providedFilterParams;r&&this.applyActive&&!e&&!t&&this.close(i)}onNewRowsLoaded(){}close(e){if(!this.hidePopup)return;const t=e,i=t&&t.key;let r;"Enter"!==i&&"Space"!==i||(r={keyboardEvent:t}),this.hidePopup(r),this.hidePopup=null}onUiChanged(e=!1,t){if(this.updateUiVisibility(),this.providedFilterParams.filterModifiedCallback(),this.applyActive&&!this.isReadOnly()){const e=this.isModelValid(this.getModelFromUi()),t=this.getRefElement("applyFilterButton");t&&ar(t,!e)}e&&!t||"immediately"===t?this.onBtApply(e):(this.applyActive||t)&&"debounce"!==t||this.onBtApplyDebounce()}afterGuiAttached(e){e&&(this.hidePopup=e.hidePopup),this.refreshFilterResizer(null==e?void 0:e.container)}refreshFilterResizer(e){if(!this.positionableFeature||"toolPanel"===e)return;const t="floatingFilter"===e||"columnFilter"===e,{positionableFeature:i,gos:r}=this;t?(i.restoreLastSize(),i.setResizable(r.get("enableRtl")?{bottom:!0,bottomLeft:!0,left:!0}:{bottom:!0,bottomRight:!0,right:!0})):(this.positionableFeature.removeSizeFromEl(),this.positionableFeature.setResizable(!1)),this.positionableFeature.constrainSizeToAvailableHeight(!0)}afterGuiDetached(){this.checkApplyDebounce(),this.positionableFeature&&this.positionableFeature.constrainSizeToAvailableHeight(!1)}static getDebounceMs(t,i){return e.isUseApplyButton(t)?(null!=t.debounceMs&&console.warn("AG Grid: debounceMs is ignored when apply button is present"),0):null!=t.debounceMs?t.debounceMs:i}static isUseApplyButton(e){return!!e.buttons&&e.buttons.indexOf("apply")>=0}refresh(e){return this.providedFilterParams=e,!0}destroy(){const e=this.getGui();e&&e.removeEventListener("submit",this.onFormSubmit),this.hidePopup=null,this.positionableFeature&&(this.positionableFeature=this.destroyBean(this.positionableFeature)),this.appliedModel=null,super.destroy()}translate(e){return this.localeService.getLocaleTextFunc()(e,Mn[e])}getCellValue(e){return this.providedFilterParams.getValue(e)}getPositionableElement(){return this.eFilterBody}};g([ue("rowModel")],In.prototype,"rowModel",2),g([Sn("eFilterBody")],In.prototype,"eFilterBody",2),g([ae],In.prototype,"postConstruct",1);var Ln=In,Nn=class extends yn{constructor(e,t){super(t),this.labelSeparator="",this.labelAlignment="left",this.disabled=!1,this.label="",this.config=e||{}}postConstruct(){this.addCssClass("ag-labeled"),this.eLabel.classList.add("ag-label");const{labelSeparator:e,label:t,labelWidth:i,labelAlignment:r,disabled:n}=this.config;null!=n&&this.setDisabled(n),null!=e&&this.setLabelSeparator(e),null!=t&&this.setLabel(t),null!=i&&this.setLabelWidth(i),this.setLabelAlignment(r||this.labelAlignment),this.refreshLabel()}refreshLabel(){Cr(this.eLabel),"string"==typeof this.label?this.eLabel.innerText=this.label+this.labelSeparator:this.label&&this.eLabel.appendChild(this.label),""===this.label?(sr(this.eLabel,!1),Ht(this.eLabel,"presentation")):(sr(this.eLabel,!0),Ht(this.eLabel,null))}setLabelSeparator(e){return this.labelSeparator===e||(this.labelSeparator=e,null!=this.label&&this.refreshLabel()),this}getLabelId(){return this.eLabel.id=this.eLabel.id||`ag-${this.getCompId()}-label`,this.eLabel.id}getLabel(){return this.label}setLabel(e){return this.label===e||(this.label=e,this.refreshLabel()),this}setLabelAlignment(e){const t=this.getGui().classList;return t.toggle("ag-label-align-left","left"===e),t.toggle("ag-label-align-right","right"===e),t.toggle("ag-label-align-top","top"===e),this}setLabelEllipsis(e){return this.eLabel.classList.toggle("ag-label-ellipsis",e),this}setLabelWidth(e){return null==this.label||Pr(this.eLabel,e),this}setDisabled(e){e=!!e;const t=this.getGui();return ar(t,e),t.classList.toggle("ag-disabled",e),this.disabled=e,this}isDisabled(){return!!this.disabled}};g([ae],Nn.prototype,"postConstruct",1);var On=class extends Nn{constructor(e,t,i){super(e,t),this.className=i}postConstruct(){super.postConstruct();const{width:e,value:t,onValueChange:i}=this.config;null!=e&&this.setWidth(e),null!=t&&this.setValue(t),null!=i&&this.onValueChange(i),this.className&&this.addCssClass(this.className),this.refreshAriaLabelledBy()}refreshAriaLabelledBy(){const e=this.getAriaElement(),t=this.getLabelId();null!==Wt(e)?Kt(e,""):Kt(e,null!=t?t:"")}setAriaLabel(e){return jt(this.getAriaElement(),e),this.refreshAriaLabelledBy(),this}onValueChange(e){return this.addManagedListener(this,lt.EVENT_FIELD_VALUE_CHANGED,()=>e(this.getValue())),this}getWidth(){return this.getGui().clientWidth}setWidth(e){return xr(this.getGui(),e),this}getPreviousValue(){return this.previousValue}getValue(){return this.value}setValue(e,t){return this.value===e||(this.previousValue=this.value,this.value=e,t||this.dispatchEvent({type:lt.EVENT_FIELD_VALUE_CHANGED})),this}},Fn=class extends On{constructor(e){if(super(e,(null==e?void 0:e.template)||'\n    <div class="ag-picker-field" role="presentation">\n        <div ref="eLabel"></div>\n            <div ref="eWrapper" class="ag-wrapper ag-picker-field-wrapper ag-picker-collapsed">\n            <div ref="eDisplayField" class="ag-picker-field-display"></div>\n            <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n        </div>\n    </div>',null==e?void 0:e.className),this.isPickerDisplayed=!1,this.skipClick=!1,this.pickerGap=4,this.hideCurrentPicker=null,this.ariaRole=null==e?void 0:e.ariaRole,this.onPickerFocusIn=this.onPickerFocusIn.bind(this),this.onPickerFocusOut=this.onPickerFocusOut.bind(this),!e)return;const{pickerGap:t,maxPickerHeight:i,variableWidth:r,minPickerWidth:n,maxPickerWidth:s}=e;null!=t&&(this.pickerGap=t),this.variableWidth=!!r,null!=i&&this.setPickerMaxHeight(i),null!=n&&this.setPickerMinWidth(n),null!=s&&this.setPickerMaxWidth(s)}postConstruct(){super.postConstruct(),this.setupAria();const e=`ag-${this.getCompId()}-display`;this.eDisplayField.setAttribute("id",e);const t=this.getAriaElement();this.addManagedListener(t,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(this.eLabel,"mousedown",this.onLabelOrWrapperMouseDown.bind(this)),this.addManagedListener(this.eWrapper,"mousedown",this.onLabelOrWrapperMouseDown.bind(this));const{pickerIcon:i,inputWidth:r}=this.config;if(i){const e=$r(i,this.gos);e&&this.eIcon.appendChild(e)}null!=r&&this.setInputWidth(r)}setupAria(){const e=this.getAriaElement();e.setAttribute("tabindex",this.gos.get("tabIndex").toString()),ti(e,!1),this.ariaRole&&Ht(e,this.ariaRole)}onLabelOrWrapperMouseDown(e){if(e){const t=this.getFocusableElement();if(t!==this.eWrapper&&(null==e?void 0:e.target)===t)return;e.preventDefault(),this.getFocusableElement().focus()}this.skipClick?this.skipClick=!1:this.isDisabled()||(this.isPickerDisplayed?this.hidePicker():this.showPicker())}onKeyDown(e){switch(e.key){case Yr.UP:case Yr.DOWN:case Yr.ENTER:case Yr.SPACE:e.preventDefault(),this.onLabelOrWrapperMouseDown();break;case Yr.ESCAPE:this.isPickerDisplayed&&(e.preventDefault(),e.stopPropagation(),this.hideCurrentPicker&&this.hideCurrentPicker())}}showPicker(){this.isPickerDisplayed=!0,this.pickerComponent||(this.pickerComponent=this.createPickerComponent());const e=this.pickerComponent.getGui();e.addEventListener("focusin",this.onPickerFocusIn),e.addEventListener("focusout",this.onPickerFocusOut),this.hideCurrentPicker=this.renderAndPositionPicker(),this.toggleExpandedStyles(!0)}renderAndPositionPicker(){const e=this.gos.getDocument(),t=this.pickerComponent.getGui();this.gos.get("suppressScrollWhenPopupsAreOpen")||(this.destroyMouseWheelFunc=this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL,()=>{this.hidePicker()}));const i=this.localeService.getLocaleTextFunc(),{pickerAriaLabelKey:r,pickerAriaLabelValue:n,modalPicker:s=!0}=this.config,o={modal:s,eChild:t,closeOnEsc:!0,closedCallback:()=>{const t=this.gos.getActiveDomElement(),i=!t||t===e.body;this.beforeHidePicker(),i&&this.isAlive()&&this.getFocusableElement().focus()},ariaLabel:i(r,n)},a=this.popupService.addPopup(o),{maxPickerHeight:l,minPickerWidth:c,maxPickerWidth:u,variableWidth:h}=this;h?(c&&(t.style.minWidth=c),t.style.width=Lr(pr(this.eWrapper)),u&&(t.style.maxWidth=u)):Pr(t,null!=u?u:pr(this.eWrapper));const d=null!=l?l:`${ur(this.popupService.getPopupParent())}px`;return t.style.setProperty("max-height",d),t.style.position="absolute",this.alignPickerToComponent(),a.hideFunc}alignPickerToComponent(){if(!this.pickerComponent)return;const{pickerType:e}=this.config,{pickerGap:t}=this,i=this.gos.get("enableRtl")?"right":"left";this.popupService.positionPopupByComponent({type:e,eventSource:this.eWrapper,ePopup:this.pickerComponent.getGui(),position:"under",alignSide:i,keepWithinBounds:!0,nudgeY:t})}beforeHidePicker(){this.destroyMouseWheelFunc&&(this.destroyMouseWheelFunc(),this.destroyMouseWheelFunc=void 0),this.toggleExpandedStyles(!1);const e=this.pickerComponent.getGui();e.removeEventListener("focusin",this.onPickerFocusIn),e.removeEventListener("focusout",this.onPickerFocusOut),this.isPickerDisplayed=!1,this.pickerComponent=void 0,this.hideCurrentPicker=null}toggleExpandedStyles(e){this.isAlive()&&(ti(this.getAriaElement(),e),this.eWrapper.classList.toggle("ag-picker-expanded",e),this.eWrapper.classList.toggle("ag-picker-collapsed",!e))}onPickerFocusIn(){this.togglePickerHasFocus(!0)}onPickerFocusOut(e){var t;(null==(t=this.pickerComponent)?void 0:t.getGui().contains(e.relatedTarget))||this.togglePickerHasFocus(!1)}togglePickerHasFocus(e){this.pickerComponent&&this.eWrapper.classList.toggle("ag-picker-has-focus",e)}hidePicker(){this.hideCurrentPicker&&this.hideCurrentPicker()}setInputWidth(e){return Pr(this.eWrapper,e),this}getFocusableElement(){return this.eWrapper}setPickerGap(e){return this.pickerGap=e,this}setPickerMinWidth(e){return"number"==typeof e&&(e=`${e}px`),this.minPickerWidth=null==e?void 0:e,this}setPickerMaxWidth(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerWidth=null==e?void 0:e,this}setPickerMaxHeight(e){return"number"==typeof e&&(e=`${e}px`),this.maxPickerHeight=null==e?void 0:e,this}destroy(){this.hidePicker(),super.destroy()}};g([ue("popupService")],Fn.prototype,"popupService",2),g([Sn("eLabel")],Fn.prototype,"eLabel",2),g([Sn("eWrapper")],Fn.prototype,"eWrapper",2),g([Sn("eDisplayField")],Fn.prototype,"eDisplayField",2),g([Sn("eIcon")],Fn.prototype,"eIcon",2);var kn=class e extends yn{constructor(e="default",t=!1){super(`<div class="ag-list ag-${e}-list" role="listbox"></div>`),this.cssIdentifier=e,this.unFocusable=t,this.options=[],this.itemEls=[]}init(){const e=this.getGui();this.addManagedListener(e,"mouseleave",()=>this.clearHighlighted()),this.unFocusable||this.addManagedListener(e,"keydown",this.handleKeyDown.bind(this))}handleKeyDown(e){const t=e.key;switch(t){case Yr.ENTER:if(this.highlightedEl){const e=this.itemEls.indexOf(this.highlightedEl);this.setValueByIndex(e)}else this.setValue(this.getValue());break;case Yr.DOWN:case Yr.UP:e.preventDefault(),this.navigate(t);break;case Yr.PAGE_DOWN:case Yr.PAGE_UP:case Yr.PAGE_HOME:case Yr.PAGE_END:e.preventDefault(),this.navigateToPage(t)}}navigate(e){const t=e===Yr.DOWN;let i;if(this.highlightedEl){let e=this.itemEls.indexOf(this.highlightedEl)+(t?1:-1);e=Math.min(Math.max(e,0),this.itemEls.length-1),i=this.itemEls[e]}else i=this.itemEls[t?0:this.itemEls.length-1];this.highlightItem(i)}navigateToPage(e){if(!this.highlightedEl||0===this.itemEls.length)return;const t=this.itemEls.indexOf(this.highlightedEl),i=this.options.length-1,r=this.itemEls[0].clientHeight,n=Math.floor(this.getGui().clientHeight/r);let s=-1;e===Yr.PAGE_HOME?s=0:e===Yr.PAGE_END?s=i:e===Yr.PAGE_DOWN?s=Math.min(t+n,i):e===Yr.PAGE_UP&&(s=Math.max(t-n,0)),-1!==s&&this.highlightItem(this.itemEls[s])}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){const{value:t,text:i}=e,r=i||t;return this.options.push({value:t,text:r}),this.renderOption(t,r),this.updateIndices(),this}clearOptions(){this.options=[],this.reset(!0),this.itemEls.forEach(e=>{yr(e)}),this.itemEls=[]}updateIndices(){const e=this.getGui().querySelectorAll(".ag-list-item");e.forEach((t,i)=>{ni(t,i+1),ri(t,e.length)})}renderOption(e,t){const i=this.gos.getDocument(),r=i.createElement("div");Ht(r,"option"),r.classList.add("ag-list-item",`ag-${this.cssIdentifier}-list-item`);const n=i.createElement("span");r.appendChild(n),n.textContent=t,this.unFocusable||(r.tabIndex=-1),this.itemEls.push(r),this.addManagedListener(r,"mousemove",()=>this.highlightItem(r)),this.addManagedListener(r,"mousedown",t=>{t.preventDefault(),this.setValue(e)}),this.createManagedBean(new mn({getTooltipValue:()=>t,getGui:()=>r,getLocation:()=>"UNKNOWN",shouldDisplayTooltip:()=>n.scrollWidth>n.clientWidth})),this.getGui().appendChild(r)}setValue(e,t){if(this.value===e)return this.fireItemSelected(),this;if(null==e)return this.reset(t),this;const i=this.options.findIndex(t=>t.value===e);if(-1!==i){const e=this.options[i];this.value=e.value,this.displayValue=e.text,this.highlightItem(this.itemEls[i]),t||this.fireChangeEvent()}return this}setValueByIndex(e){return this.setValue(this.options[e].value)}getValue(){return this.value}getDisplayValue(){return this.displayValue}refreshHighlighted(){this.clearHighlighted();const e=this.options.findIndex(e=>e.value===this.value);-1!==e&&this.highlightItem(this.itemEls[e])}reset(e){this.value=null,this.displayValue=null,this.clearHighlighted(),e||this.fireChangeEvent()}highlightItem(t){if(!Sr(t))return;this.clearHighlighted(),this.highlightedEl=t,this.highlightedEl.classList.add(e.ACTIVE_CLASS),pi(this.highlightedEl,!0);const i=this.getGui(),{scrollTop:r,clientHeight:n}=i,{offsetTop:s,offsetHeight:o}=t;(s+o>r+n||s<r)&&this.highlightedEl.scrollIntoView({block:"nearest"}),this.unFocusable||this.highlightedEl.focus()}clearHighlighted(){this.highlightedEl&&Sr(this.highlightedEl)&&(this.highlightedEl.classList.remove(e.ACTIVE_CLASS),pi(this.highlightedEl,!1),this.highlightedEl=null)}fireChangeEvent(){this.dispatchEvent({type:lt.EVENT_FIELD_VALUE_CHANGED}),this.fireItemSelected()}fireItemSelected(){this.dispatchEvent({type:e.EVENT_ITEM_SELECTED})}};kn.EVENT_ITEM_SELECTED="selectedItem",kn.ACTIVE_CLASS="ag-active-item",g([ae],kn.prototype,"init",1);var Gn=kn,Vn=class e extends Fn{constructor(e){super(h({pickerAriaLabelKey:"ariaLabelSelectField",pickerAriaLabelValue:"Select Field",pickerType:"ag-list",className:"ag-select",pickerIcon:"smallDown",ariaRole:"combobox"},e))}postConstruct(){super.postConstruct(),this.createListComponent(),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{options:e,value:t,placeholder:i}=this.config;null!=e&&this.addOptions(e),null!=t&&this.setValue(t,!0),i&&null==t&&(this.eDisplayField.textContent=i),this.addManagedListener(this.eWrapper,"focusout",this.onWrapperFocusOut.bind(this))}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}createListComponent(){this.listComponent=this.createBean(new Gn("select",!0)),this.listComponent.setParentComponent(this);const t=this.listComponent.getAriaElement(),i=`ag-select-list-${this.listComponent.getCompId()}`;t.setAttribute("id",i),fi(this.getAriaElement(),t),this.listComponent.addManagedListener(this.listComponent,Gn.EVENT_ITEM_SELECTED,()=>{this.hidePicker(),this.dispatchEvent({type:e.EVENT_ITEM_SELECTED})}),this.listComponent.addManagedListener(this.listComponent,lt.EVENT_FIELD_VALUE_CHANGED,()=>{this.listComponent&&(this.setValue(this.listComponent.getValue(),!1,!0),this.hidePicker())})}createPickerComponent(){return this.listComponent}onKeyDown(e){var t;const{key:i}=e;switch(i===Yr.TAB&&this.hidePicker(),i){case Yr.ENTER:case Yr.UP:case Yr.DOWN:case Yr.PAGE_UP:case Yr.PAGE_DOWN:case Yr.PAGE_HOME:case Yr.PAGE_END:e.preventDefault(),this.isPickerDisplayed?null==(t=this.listComponent)||t.handleKeyDown(e):super.onKeyDown(e);break;case Yr.ESCAPE:super.onKeyDown(e)}}showPicker(){this.listComponent&&(super.showPicker(),this.listComponent.refreshHighlighted())}addOptions(e){return e.forEach(e=>this.addOption(e)),this}addOption(e){return this.listComponent.addOption(e),this}clearOptions(){var e;return null==(e=this.listComponent)||e.clearOptions(),this}setValue(e,t,i){if(this.value===e||!this.listComponent)return this;if(i||this.listComponent.setValue(e,!0),this.listComponent.getValue()===this.getValue())return this;let r=this.listComponent.getDisplayValue();return null==r&&this.config.placeholder&&(r=this.config.placeholder),this.eDisplayField.textContent=r,this.setTooltip({newTooltipText:null!=r?r:null,shouldDisplayTooltip:()=>this.eDisplayField.scrollWidth>this.eDisplayField.clientWidth}),super.setValue(e,t)}destroy(){this.listComponent&&(this.destroyBean(this.listComponent),this.listComponent=void 0),super.destroy()}};Vn.EVENT_ITEM_SELECTED="selectedItem";var Hn=Vn,Bn=class extends On{constructor(e,t,i="text",r="input"){super(e,`\n            <div role="presentation">\n                <div ref="eLabel" class="ag-input-field-label"></div>\n                <div ref="eWrapper" class="ag-wrapper ag-input-wrapper" role="presentation">\n                    <${r} ref="eInput" class="ag-input-field-input"></${r}>\n                </div>\n            </div>`,t),this.inputType=i,this.displayFieldTag=r}postConstruct(){super.postConstruct(),this.setInputType(),this.eLabel.classList.add(`${this.className}-label`),this.eWrapper.classList.add(`${this.className}-input-wrapper`),this.eInput.classList.add(`${this.className}-input`),this.addCssClass("ag-input-field"),this.eInput.id=this.eInput.id||`ag-${this.getCompId()}-input`;const{inputName:e,inputWidth:t}=this.config;null!=e&&this.setInputName(e),null!=t&&this.setInputWidth(t),this.addInputListeners(),this.activateTabIndex([this.eInput])}addInputListeners(){this.addManagedListener(this.eInput,"input",e=>this.setValue(e.target.value))}setInputType(){"input"===this.displayFieldTag&&this.eInput.setAttribute("type",this.inputType)}getInputElement(){return this.eInput}setInputWidth(e){return Pr(this.eWrapper,e),this}setInputName(e){return this.getInputElement().setAttribute("name",e),this}getFocusableElement(){return this.eInput}setMaxLength(e){return this.eInput.maxLength=e,this}setInputPlaceholder(e){return kr(this.eInput,"placeholder",e),this}setInputAriaLabel(e){return jt(this.eInput,e),this.refreshAriaLabelledBy(),this}setDisabled(e){return ar(this.eInput,e),super.setDisabled(e)}setAutoComplete(e){if(!0===e)kr(this.eInput,"autocomplete",null);else{const t="string"==typeof e?e:"off";kr(this.eInput,"autocomplete",t)}return this}};g([Sn("eLabel")],Bn.prototype,"eLabel",2),g([Sn("eWrapper")],Bn.prototype,"eWrapper",2),g([Sn("eInput")],Bn.prototype,"eInput",2);var zn=class extends Bn{constructor(e,t="ag-checkbox",i="checkbox"){super(e,t,i),this.labelAlignment="right",this.selected=!1,this.readOnly=!1,this.passive=!1}postConstruct(){super.postConstruct();const{readOnly:e,passive:t}=this.config;"boolean"==typeof e&&this.setReadOnly(e),"boolean"==typeof t&&this.setPassive(t)}addInputListeners(){this.addManagedListener(this.eInput,"click",this.onCheckboxClick.bind(this)),this.addManagedListener(this.eLabel,"click",this.toggle.bind(this))}getNextValue(){return void 0===this.selected||!this.selected}setPassive(e){this.passive=e}isReadOnly(){return this.readOnly}setReadOnly(e){this.eWrapper.classList.toggle("ag-disabled",e),this.eInput.disabled=e,this.readOnly=e}setDisabled(e){return this.eWrapper.classList.toggle("ag-disabled",e),super.setDisabled(e)}toggle(){if(this.eInput.disabled)return;const e=this.isSelected(),t=this.getNextValue();this.passive?this.dispatchChange(t,e):this.setValue(t)}getValue(){return this.isSelected()}setValue(e,t){return this.refreshSelectedClass(e),this.setSelected(e,t),this}setName(e){return this.getInputElement().name=e,this}isSelected(){return this.selected}setSelected(e,t){this.isSelected()!==e&&(this.previousValue=this.isSelected(),e=this.selected="boolean"==typeof e?e:void 0,this.eInput.checked=e,this.eInput.indeterminate=void 0===e,t||this.dispatchChange(this.selected,this.previousValue))}dispatchChange(e,t,i){this.dispatchEvent({type:lt.EVENT_FIELD_VALUE_CHANGED,selected:e,previousValue:t,event:i});const r=this.getInputElement(),n={type:lt.EVENT_CHECKBOX_CHANGED,id:r.id,name:r.name,selected:e,previousValue:t};this.eventService.dispatchEvent(n)}onCheckboxClick(e){if(this.passive||this.eInput.disabled)return;const t=this.isSelected(),i=this.selected=e.target.checked;this.refreshSelectedClass(i),this.dispatchChange(i,t,e)}refreshSelectedClass(e){this.eWrapper.classList.toggle("ag-checked",!0===e),this.eWrapper.classList.toggle("ag-indeterminate",null==e)}},Un=class extends zn{constructor(e){super(e,"ag-radio-button","radio")}isSelected(){return this.eInput.checked}toggle(){this.eInput.disabled||this.isSelected()||this.setValue(!0)}addInputListeners(){super.addInputListeners(),this.addManagedListener(this.eventService,lt.EVENT_CHECKBOX_CHANGED,this.onChange.bind(this))}onChange(e){e.selected&&e.name&&this.eInput.name&&this.eInput.name===e.name&&e.id&&this.eInput.id!==e.id&&this.setValue(!1,!0)}},Wn=class{constructor(e,t,i){this.localeService=e,this.optionsFactory=t,this.valueFormatter=i}getModelAsString(e){if(!e)return null;const t=null!=e.operator,i=this.localeService.getLocaleTextFunc();if(t){const t=e;let{conditions:r}=t;if(!r){const{condition1:e,condition2:i}=t;r=[e,i]}const n=r.map(e=>this.getModelAsString(e)),s="AND"===t.operator?"andCondition":"orCondition";return n.join(` ${i(s,Mn[s])} `)}if(e.type===Kn.BLANK||e.type===Kn.NOT_BLANK)return i(e.type,e.type);{const t=e,r=this.optionsFactory.getCustomOption(t.type),{displayKey:n,displayName:s,numberOfInputs:o}=r||{};return n&&s&&0===o?(i(n,s),s):this.conditionToString(t,r)}}updateParams(e){this.optionsFactory=e.optionsFactory}formatValue(e){var t;return this.valueFormatter?null!=(t=this.valueFormatter(null!=e?e:null))?t:"":String(e)}},jn=class e extends Ln{constructor(){super(...arguments),this.eTypes=[],this.eJoinOperatorPanels=[],this.eJoinOperatorsAnd=[],this.eJoinOperatorsOr=[],this.eConditionBodies=[],this.listener=()=>this.onUiChanged(),this.lastUiCompletePosition=null,this.joinOperatorId=0}getNumberOfInputs(t){const i=this.optionsFactory.getCustomOption(t);if(i){const{numberOfInputs:e}=i;return null!=e?e:1}const r=[e.EMPTY,e.NOT_BLANK,e.BLANK];return t&&r.indexOf(t)>=0?0:t===e.IN_RANGE?2:1}onFloatingFilterChanged(e,t){this.setTypeFromFloatingFilter(e),this.setValueFromFloatingFilter(t),this.onUiChanged(!0)}setTypeFromFloatingFilter(e){this.eTypes.forEach((t,i)=>{0===i?t.setValue(e,!0):t.setValue(this.optionsFactory.getDefaultOption(),!0)})}getModelFromUi(){const e=this.getUiCompleteConditions();return 0===e.length?null:this.maxNumConditions>1&&e.length>1?{filterType:this.getFilterType(),operator:this.getJoinOperator(),condition1:e[0],condition2:e[1],conditions:e}:e[0]}getConditionTypes(){return this.eTypes.map(e=>e.getValue())}getConditionType(e){return this.eTypes[e].getValue()}getJoinOperator(){return 0===this.eJoinOperatorsOr.length?this.defaultJoinOperator:!0===this.eJoinOperatorsOr[0].getValue()?"OR":"AND"}areModelsEqual(e,t){if(!e&&!t)return!0;if(!e&&t||e&&!t)return!1;const i=!e.operator,r=!t.operator;if(!i&&r||i&&!r)return!1;let n;if(i){const i=e,r=t;n=this.areSimpleModelsEqual(i,r)}else{const i=e,r=t;n=i.operator===r.operator&&Pe(i.conditions,r.conditions,(e,t)=>this.areSimpleModelsEqual(e,t))}return n}shouldRefresh(e){var t,i,r;const n=this.getModel(),s=n?null!=(t=n.conditions)?t:[n]:null,o=null!=(r=null==(i=e.filterOptions)?void 0:i.map(e=>"string"==typeof e?e:e.displayKey))?r:this.getDefaultFilterOptions();return!(s&&!s.every(e=>void 0!==o.find(t=>t===e.type))||"number"==typeof e.maxNumConditions&&s&&s.length>e.maxNumConditions)}refresh(e){return!!this.shouldRefresh(e)&&(!!super.refresh(e)&&(this.setParams(e),this.removeConditionsAndOperators(0),this.createOption(),this.setModel(this.getModel()),!0))}setModelIntoUi(e){if(e.operator){let t=e;t.conditions||(t.conditions=[t.condition1,t.condition2]);const i=this.validateAndUpdateConditions(t.conditions),r=this.getNumConditions();if(i<r)this.removeConditionsAndOperators(i);else if(i>r)for(let e=r;e<i;e++)this.createJoinOperatorPanel(),this.createOption();const n="OR"===t.operator;this.eJoinOperatorsAnd.forEach(e=>e.setValue(!n,!0)),this.eJoinOperatorsOr.forEach(e=>e.setValue(n,!0)),t.conditions.forEach((e,t)=>{this.eTypes[t].setValue(e.type,!0),this.setConditionIntoUi(e,t)})}else{const t=e;this.getNumConditions()>1&&this.removeConditionsAndOperators(1),this.eTypes[0].setValue(t.type,!0),this.setConditionIntoUi(t,0)}return this.lastUiCompletePosition=this.getNumConditions()-1,this.createMissingConditionsAndOperators(),this.onUiChanged(),hn.resolve()}validateAndUpdateConditions(e){let t=e.length;return t>this.maxNumConditions&&(e.splice(this.maxNumConditions),z('Filter Model contains more conditions than "filterParams.maxNumConditions". Additional conditions have been ignored.'),t=this.maxNumConditions),t}doesFilterPass(e){var t;const i=this.getModel();if(null==i)return!0;const{operator:r}=i,n=[];if(r){const e=i;n.push(...null!=(t=e.conditions)?t:[])}else n.push(i);return n[r&&"OR"===r?"some":"every"](t=>this.individualConditionPasses(e,t))}setParams(e){super.setParams(e),this.setNumConditions(e),this.defaultJoinOperator=this.getDefaultJoinOperator(e.defaultJoinOperator),this.filterPlaceholder=e.filterPlaceholder,this.optionsFactory=new Tn,this.optionsFactory.init(e,this.getDefaultFilterOptions()),this.createFilterListOptions(),this.createOption(),this.createMissingConditionsAndOperators(),this.isReadOnly()&&this.eFilterBody.setAttribute("tabindex","-1")}setNumConditions(e){var t,i;null!=e.suppressAndOrCondition&&z('Since v29.2 "filterParams.suppressAndOrCondition" is deprecated. Use "filterParams.maxNumConditions = 1" instead.'),null!=e.alwaysShowBothConditions&&z('Since v29.2 "filterParams.alwaysShowBothConditions" is deprecated. Use "filterParams.numAlwaysVisibleConditions = 2" instead.'),this.maxNumConditions=null!=(t=e.maxNumConditions)?t:e.suppressAndOrCondition?1:2,this.maxNumConditions<1&&(z('"filterParams.maxNumConditions" must be greater than or equal to zero.'),this.maxNumConditions=1),this.numAlwaysVisibleConditions=null!=(i=e.numAlwaysVisibleConditions)?i:e.alwaysShowBothConditions?2:1,this.numAlwaysVisibleConditions<1&&(z('"filterParams.numAlwaysVisibleConditions" must be greater than or equal to zero.'),this.numAlwaysVisibleConditions=1),this.numAlwaysVisibleConditions>this.maxNumConditions&&(z('"filterParams.numAlwaysVisibleConditions" cannot be greater than "filterParams.maxNumConditions".'),this.numAlwaysVisibleConditions=this.maxNumConditions)}createOption(){const e=this.createManagedBean(new Hn);this.eTypes.push(e),e.addCssClass("ag-filter-select"),this.eFilterBody.appendChild(e.getGui());const t=this.createValueElement();this.eConditionBodies.push(t),this.eFilterBody.appendChild(t),this.putOptionsIntoDropdown(e),this.resetType(e);const i=this.getNumConditions()-1;this.forEachPositionInput(i,e=>this.resetInput(e)),this.addChangedListeners(e,i)}createJoinOperatorPanel(){const e=document.createElement("div");this.eJoinOperatorPanels.push(e),e.classList.add("ag-filter-condition");const t=this.createJoinOperator(this.eJoinOperatorsAnd,e,"and"),i=this.createJoinOperator(this.eJoinOperatorsOr,e,"or");this.eFilterBody.appendChild(e);const r=this.eJoinOperatorPanels.length-1,n=this.joinOperatorId++;this.resetJoinOperatorAnd(t,r,n),this.resetJoinOperatorOr(i,r,n),this.isReadOnly()||(t.onValueChange(this.listener),i.onValueChange(this.listener))}createJoinOperator(e,t,i){const r=this.createManagedBean(new Un);return e.push(r),r.addCssClass("ag-filter-condition-operator"),r.addCssClass(`ag-filter-condition-operator-${i}`),t.appendChild(r.getGui()),r}getDefaultJoinOperator(e){return"AND"===e||"OR"===e?e:"AND"}createFilterListOptions(){const e=this.optionsFactory.getFilterOptions();this.filterListOptions=e.map(e=>"string"==typeof e?this.createBoilerplateListOption(e):this.createCustomListOption(e))}putOptionsIntoDropdown(e){this.filterListOptions.forEach(t=>{e.addOption(t)}),e.setDisabled(this.filterListOptions.length<=1)}createBoilerplateListOption(e){return{value:e,text:this.translate(e)}}createCustomListOption(e){const{displayKey:t}=e,i=this.optionsFactory.getCustomOption(e.displayKey);return{value:t,text:i?this.localeService.getLocaleTextFunc()(i.displayKey,i.displayName):this.translate(t)}}isAllowTwoConditions(){return this.maxNumConditions>=2}createBodyTemplate(){return""}getCssIdentifier(){return"simple-filter"}updateUiVisibility(){const e=this.getJoinOperator();this.updateNumConditions(),this.updateConditionStatusesAndValues(this.lastUiCompletePosition,e)}updateNumConditions(){var e;let t=-1,i=!0;for(let e=0;e<this.getNumConditions();e++)this.isConditionUiComplete(e)?t=e:i=!1;if(this.shouldAddNewConditionAtEnd(i))this.createJoinOperatorPanel(),this.createOption();else{const i=null!=(e=this.lastUiCompletePosition)?e:this.getNumConditions()-2;if(t<i){this.removeConditionsAndOperators(i+1);const e=t+1,r=i-e;r>0&&this.removeConditionsAndOperators(e,r),this.createMissingConditionsAndOperators()}}this.lastUiCompletePosition=t}updateConditionStatusesAndValues(e,t){this.eTypes.forEach((t,i)=>{const r=this.isConditionDisabled(i,e);t.setDisabled(r||this.filterListOptions.length<=1),1===i&&(ar(this.eJoinOperatorPanels[0],r),this.eJoinOperatorsAnd[0].setDisabled(r),this.eJoinOperatorsOr[0].setDisabled(r))}),this.eConditionBodies.forEach((e,t)=>{sr(e,this.isConditionBodyVisible(t))});const i="OR"===(null!=t?t:this.getJoinOperator());this.eJoinOperatorsAnd.forEach((e,t)=>{e.setValue(!i,!0)}),this.eJoinOperatorsOr.forEach((e,t)=>{e.setValue(i,!0)}),this.forEachInput((t,i,r,n)=>{this.setElementDisplayed(t,i<n),this.setElementDisabled(t,this.isConditionDisabled(r,e))}),this.resetPlaceholder()}shouldAddNewConditionAtEnd(e){return e&&this.getNumConditions()<this.maxNumConditions&&!this.isReadOnly()}removeConditionsAndOperators(e,t){if(e>=this.getNumConditions())return;this.removeComponents(this.eTypes,e,t),this.removeElements(this.eConditionBodies,e,t),this.removeValueElements(e,t);const i=Math.max(e-1,0);this.removeElements(this.eJoinOperatorPanels,i,t),this.removeComponents(this.eJoinOperatorsAnd,i,t),this.removeComponents(this.eJoinOperatorsOr,i,t)}removeElements(e,t,i){this.removeItems(e,t,i).forEach(e=>yr(e))}removeComponents(e,t,i){this.removeItems(e,t,i).forEach(e=>{yr(e.getGui()),this.destroyBean(e)})}removeItems(e,t,i){return null==i?e.splice(t):e.splice(t,i)}afterGuiAttached(e){if(super.afterGuiAttached(e),this.resetPlaceholder(),!(null==e?void 0:e.suppressFocus))if(this.isReadOnly())this.eFilterBody.focus();else{const e=this.getInputs(0)[0];if(!e)return;e instanceof Bn&&e.getInputElement().focus()}}afterGuiDetached(){super.afterGuiDetached();const e=this.getModel();this.resetUiToActiveModel(e);let t=-1,i=-1,r=!1;const n=this.getJoinOperator();for(let e=this.getNumConditions()-1;e>=0;e--)if(this.isConditionUiComplete(e))-1===t&&(t=e,i=e);else{const n=e<t;(e>=this.numAlwaysVisibleConditions&&!this.isConditionUiComplete(e-1)||n)&&(this.removeConditionsAndOperators(e,1),r=!0,n&&i--)}let s=!1;this.getNumConditions()<this.numAlwaysVisibleConditions&&(this.createMissingConditionsAndOperators(),s=!0),this.shouldAddNewConditionAtEnd(i===this.getNumConditions()-1)&&(this.createJoinOperatorPanel(),this.createOption(),s=!0),s&&this.updateConditionStatusesAndValues(i,n),r&&this.updateJoinOperatorsDisabled(),this.lastUiCompletePosition=i}getPlaceholderText(e,t){let i=this.translate(e);if(j(this.filterPlaceholder)){const e=this.filterPlaceholder,r=this.eTypes[t].getValue();i=e({filterOptionKey:r,filterOption:this.translate(r),placeholder:i})}else"string"==typeof this.filterPlaceholder&&(i=this.filterPlaceholder);return i}resetPlaceholder(){const e=this.localeService.getLocaleTextFunc();this.forEachInput((t,i,r,n)=>{if(!(t instanceof Bn))return;const s=0===i&&n>1?"inRangeStart":0===i?"filterOoo":"inRangeEnd",o=0===i&&n>1?e("ariaFilterFromValue","Filter from value"):0===i?e("ariaFilterValue","Filter Value"):e("ariaFilterToValue","Filter to Value");t.setInputPlaceholder(this.getPlaceholderText(s,r)),t.setInputAriaLabel(o)})}setElementValue(e,t,i){e instanceof Bn&&e.setValue(null!=t?String(t):null,!0)}setElementDisplayed(e,t){e instanceof yn&&sr(e.getGui(),t)}setElementDisabled(e,t){e instanceof yn&&ar(e.getGui(),t)}attachElementOnChange(e,t){e instanceof Bn&&e.onValueChange(t)}forEachInput(e){this.getConditionTypes().forEach((t,i)=>{this.forEachPositionTypeInput(i,t,e)})}forEachPositionInput(e,t){const i=this.getConditionType(e);this.forEachPositionTypeInput(e,i,t)}forEachPositionTypeInput(e,t,i){const r=this.getNumberOfInputs(t),n=this.getInputs(e);for(let t=0;t<n.length;t++){const s=n[t];null!=s&&i(s,t,e,r)}}isConditionDisabled(e,t){return!!this.isReadOnly()||0!==e&&e>t+1}isConditionBodyVisible(e){const t=this.getConditionType(e);return this.getNumberOfInputs(t)>0}isConditionUiComplete(t){return!(t>=this.getNumConditions())&&(this.getConditionType(t)!==e.EMPTY&&!this.getValues(t).some(e=>null==e))}getNumConditions(){return this.eTypes.length}getUiCompleteConditions(){const e=[];for(let t=0;t<this.getNumConditions();t++)this.isConditionUiComplete(t)&&e.push(this.createCondition(t));return e}createMissingConditionsAndOperators(){if(!this.isReadOnly())for(let e=this.getNumConditions();e<this.numAlwaysVisibleConditions;e++)this.createJoinOperatorPanel(),this.createOption()}resetUiToDefaults(e){return this.removeConditionsAndOperators(this.isReadOnly()?1:this.numAlwaysVisibleConditions),this.eTypes.forEach(e=>this.resetType(e)),this.eJoinOperatorsAnd.forEach((e,t)=>this.resetJoinOperatorAnd(e,t,this.joinOperatorId+t)),this.eJoinOperatorsOr.forEach((e,t)=>this.resetJoinOperatorOr(e,t,this.joinOperatorId+t)),this.joinOperatorId++,this.forEachInput(e=>this.resetInput(e)),this.resetPlaceholder(),this.createMissingConditionsAndOperators(),this.lastUiCompletePosition=null,e||this.onUiChanged(),hn.resolve()}resetType(e){const t=this.localeService.getLocaleTextFunc()("ariaFilteringOperator","Filtering operator");e.setValue(this.optionsFactory.getDefaultOption(),!0).setAriaLabel(t).setDisabled(this.isReadOnly()||this.filterListOptions.length<=1)}resetJoinOperatorAnd(e,t,i){this.resetJoinOperator(e,t,this.isDefaultOperator("AND"),this.translate("andCondition"),i)}resetJoinOperatorOr(e,t,i){this.resetJoinOperator(e,t,this.isDefaultOperator("OR"),this.translate("orCondition"),i)}resetJoinOperator(e,t,i,r,n){this.updateJoinOperatorDisabled(e.setValue(i,!0).setName(`ag-simple-filter-and-or-${this.getCompId()}-${n}`).setLabel(r),t)}updateJoinOperatorsDisabled(){this.eJoinOperatorsAnd.forEach((e,t)=>this.updateJoinOperatorDisabled(e,t)),this.eJoinOperatorsOr.forEach((e,t)=>this.updateJoinOperatorDisabled(e,t))}updateJoinOperatorDisabled(e,t){e.setDisabled(this.isReadOnly()||t>0)}resetInput(e){this.setElementValue(e,null),this.setElementDisabled(e,this.isReadOnly())}setConditionIntoUi(e,t){const i=this.mapValuesFromModel(e);this.forEachInput((e,r,n,s)=>{n===t&&this.setElementValue(e,null!=i[r]?i[r]:null)})}setValueFromFloatingFilter(e){this.forEachInput((t,i,r,n)=>{this.setElementValue(t,0===i&&0===r?e:null,!0)})}isDefaultOperator(e){return e===this.defaultJoinOperator}addChangedListeners(e,t){this.isReadOnly()||(e.onValueChange(this.listener),this.forEachPositionInput(t,e=>{this.attachElementOnChange(e,this.listener)}))}individualConditionPasses(e,t){const i=this.getCellValue(e.node),r=this.mapValuesFromModel(t),n=this.optionsFactory.getCustomOption(t.type),s=this.evaluateCustomFilter(n,r,i);return null!=s?s:null==i?this.evaluateNullValue(t.type):this.evaluateNonNullValue(r,i,t,e)}evaluateCustomFilter(e,t,i){if(null==e)return;const{predicate:r}=e;return null==r||t.some(e=>null==e)?void 0:r(t,i)}isBlank(e){return null==e||"string"==typeof e&&0===e.trim().length}hasInvalidInputs(){return!1}};jn.EMPTY="empty",jn.BLANK="blank",jn.NOT_BLANK="notBlank",jn.EQUALS="equals",jn.NOT_EQUAL="notEqual",jn.LESS_THAN="lessThan",jn.LESS_THAN_OR_EQUAL="lessThanOrEqual",jn.GREATER_THAN="greaterThan",jn.GREATER_THAN_OR_EQUAL="greaterThanOrEqual",jn.IN_RANGE="inRange",jn.CONTAINS="contains",jn.NOT_CONTAINS="notContains",jn.STARTS_WITH="startsWith",jn.ENDS_WITH="endsWith";var Kn=jn,$n=class e extends Kn{setParams(e){super.setParams(e),this.scalarFilterParams=e}evaluateNullValue(t){switch(t){case e.EQUALS:case e.NOT_EQUAL:if(this.scalarFilterParams.includeBlanksInEquals)return!0;break;case e.GREATER_THAN:case e.GREATER_THAN_OR_EQUAL:if(this.scalarFilterParams.includeBlanksInGreaterThan)return!0;break;case e.LESS_THAN:case e.LESS_THAN_OR_EQUAL:if(this.scalarFilterParams.includeBlanksInLessThan)return!0;break;case e.IN_RANGE:if(this.scalarFilterParams.includeBlanksInRange)return!0;break;case e.BLANK:return!0;case e.NOT_BLANK:return!1}return!1}evaluateNonNullValue(t,i,r){const n=this.comparator(),s=null!=t[0]?n(t[0],i):0;switch(r.type){case e.EQUALS:return 0===s;case e.NOT_EQUAL:return 0!==s;case e.GREATER_THAN:return s>0;case e.GREATER_THAN_OR_EQUAL:return s>=0;case e.LESS_THAN:return s<0;case e.LESS_THAN_OR_EQUAL:return s<=0;case e.IN_RANGE:{const e=n(t[1],i);return this.scalarFilterParams.inRangeInclusive?s>=0&&e<=0:s>0&&e<0}case e.BLANK:return this.isBlank(i);case e.NOT_BLANK:return!this.isBlank(i);default:return console.warn('AG Grid: Unexpected type of filter "'+r.type+'", it looks like the filter was configured with incorrect Filter Options'),!0}}},qn=1/0,Yn=class extends Wn{constructor(e,t,i){super(t,i),this.dateFilterParams=e}conditionToString(e,t){const{type:i}=e,{numberOfInputs:r}=t||{},n=i==Kn.IN_RANGE||2===r,s=Zi(e.dateFrom),o=Zi(e.dateTo),a=this.dateFilterParams.inRangeFloatingFilterDateFormat;return n?`${null!==s?Xi(s,a):"null"}-${null!==o?Xi(o,a):"null"}`:null!=s?Xi(s,a):`${i}`}updateParams(e){super.updateParams(e),this.dateFilterParams=e.dateFilterParams}},Qn=class e extends $n{constructor(){super("dateFilter"),this.eConditionPanelsFrom=[],this.eConditionPanelsTo=[],this.dateConditionFromComps=[],this.dateConditionToComps=[],this.minValidYear=1e3,this.maxValidYear=qn,this.minValidDate=null,this.maxValidDate=null}afterGuiAttached(e){super.afterGuiAttached(e),this.dateConditionFromComps[0].afterGuiAttached(e)}mapValuesFromModel(e){const{dateFrom:t,dateTo:i,type:r}=e||{};return[t&&Zi(t)||null,i&&Zi(i)||null].slice(0,this.getNumberOfInputs(r))}comparator(){return this.dateFilterParams.comparator?this.dateFilterParams.comparator:this.defaultComparator.bind(this)}defaultComparator(e,t){return null==t||t<e?-1:t>e?1:0}setParams(e){this.dateFilterParams=e,super.setParams(e);const t=(t,i)=>{if(null!=e[t]){if(!isNaN(e[t]))return null==e[t]?i:Number(e[t]);console.warn(`AG Grid: DateFilter ${t} is not a number`)}return i};this.minValidYear=t("minValidYear",1e3),this.maxValidYear=t("maxValidYear",qn),this.minValidYear>this.maxValidYear&&console.warn("AG Grid: DateFilter minValidYear should be <= maxValidYear"),e.minValidDate?this.minValidDate=e.minValidDate instanceof Date?e.minValidDate:Zi(e.minValidDate):this.minValidDate=null,e.maxValidDate?this.maxValidDate=e.maxValidDate instanceof Date?e.maxValidDate:Zi(e.maxValidDate):this.maxValidDate=null,this.minValidDate&&this.maxValidDate&&this.minValidDate>this.maxValidDate&&console.warn("AG Grid: DateFilter minValidDate should be <= maxValidDate"),this.filterModelFormatter=new Yn(this.dateFilterParams,this.localeService,this.optionsFactory)}createDateCompWrapper(e){const t=new An(this.getContext(),this.userComponentFactory,{onDateChanged:()=>this.onUiChanged(),filterParams:this.dateFilterParams},e);return this.addDestroyFunc(()=>t.destroy()),t}setElementValue(e,t){e.setDate(t)}setElementDisplayed(e,t){e.setDisplayed(t)}setElementDisabled(e,t){e.setDisabled(t)}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}createValueElement(){const e=this.gos.getDocument().createElement("div");return e.classList.add("ag-filter-body"),this.createFromToElement(e,this.eConditionPanelsFrom,this.dateConditionFromComps,"from"),this.createFromToElement(e,this.eConditionPanelsTo,this.dateConditionToComps,"to"),e}createFromToElement(e,t,i,r){const n=this.gos.getDocument().createElement("div");n.classList.add(`ag-filter-${r}`),n.classList.add(`ag-filter-date-${r}`),t.push(n),e.appendChild(n),i.push(this.createDateCompWrapper(n))}removeValueElements(e,t){this.removeDateComps(this.dateConditionFromComps,e,t),this.removeDateComps(this.dateConditionToComps,e,t),this.removeItems(this.eConditionPanelsFrom,e,t),this.removeItems(this.eConditionPanelsTo,e,t)}removeDateComps(e,t,i){this.removeItems(e,t,i).forEach(e=>e.destroy())}isValidDateValue(e){if(null===e)return!1;if(this.minValidDate){if(e<this.minValidDate)return!1}else if(e.getUTCFullYear()<this.minValidYear)return!1;if(this.maxValidDate){if(e>this.maxValidDate)return!1}else if(e.getUTCFullYear()>this.maxValidYear)return!1;return!0}isConditionUiComplete(e){if(!super.isConditionUiComplete(e))return!1;let t=!0;return this.forEachInput((i,r,n,s)=>{n!==e||!t||r>=s||(t=t&&this.isValidDateValue(i.getDate()))}),t}areSimpleModelsEqual(e,t){return e.dateFrom===t.dateFrom&&e.dateTo===t.dateTo&&e.type===t.type}getFilterType(){return"date"}createCondition(e){const t=this.getConditionType(e),i={},r=this.getValues(e);return r.length>0&&(i.dateFrom=Yi(r[0])),r.length>1&&(i.dateTo=Yi(r[1])),h({dateFrom:null,dateTo:null,filterType:this.getFilterType(),type:t},i)}resetPlaceholder(){const e=this.localeService.getLocaleTextFunc(),t=this.translate("dateFormatOoo"),i=e("ariaFilterValue","Filter Value");this.forEachInput(e=>{e.setInputPlaceholder(t),e.setInputAriaLabel(i)})}getInputs(e){return e>=this.dateConditionFromComps.length?[null,null]:[this.dateConditionFromComps[e],this.dateConditionToComps[e]]}getValues(e){const t=[];return this.forEachPositionInput(e,(e,i,r,n)=>{i<n&&t.push(e.getDate())}),t}translate(e){return e===$n.LESS_THAN?super.translate("before"):e===$n.GREATER_THAN?super.translate("after"):super.translate(e)}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}};Qn.DEFAULT_FILTER_OPTIONS=[$n.EQUALS,$n.NOT_EQUAL,$n.LESS_THAN,$n.GREATER_THAN,$n.IN_RANGE,$n.BLANK,$n.NOT_BLANK],g([ue("userComponentFactory")],Qn.prototype,"userComponentFactory",2);var Xn=Qn,Zn=class extends yn{getDefaultDebounceMs(){return 0}destroy(){super.destroy()}isEventFromFloatingFilter(e){return e&&e.afterFloatingFilter}isEventFromDataChange(e){return null==e?void 0:e.afterDataChange}getLastType(){return this.lastType}isReadOnly(){return this.readOnly}setLastTypeFromModel(e){if(!e)return void(this.lastType=this.optionsFactory.getDefaultOption());let t;t=e.operator?e.conditions[0]:e,this.lastType=t.type}canWeEditAfterModelFromParentFilter(e){if(!e)return this.isTypeEditable(this.lastType);if(e.operator)return!1;const t=e;return this.isTypeEditable(t.type)}init(e){this.setSimpleParams(e,!1)}setSimpleParams(e,t=!0){this.optionsFactory=new Tn,this.optionsFactory.init(e.filterParams,this.getDefaultFilterOptions()),t||(this.lastType=this.optionsFactory.getDefaultOption()),this.readOnly=!!e.filterParams.readOnly;const i=this.isTypeEditable(this.optionsFactory.getDefaultOption());this.setEditable(i)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.setSimpleParams(e)}doesFilterHaveSingleInput(e){const t=this.optionsFactory.getCustomOption(e),{numberOfInputs:i}=t||{};return null==i||1==i}isTypeEditable(e){const t=[Kn.IN_RANGE,Kn.EMPTY,Kn.BLANK,Kn.NOT_BLANK];return!!e&&!this.isReadOnly()&&this.doesFilterHaveSingleInput(e)&&t.indexOf(e)<0}getAriaLabel(e){return`${this.columnModel.getDisplayNameForColumn(e.column,"header",!0)} ${this.localeService.getLocaleTextFunc()("ariaFilterInput","Filter Input")}`}};g([ue("columnModel")],Zn.prototype,"columnModel",2);var Jn=class extends Zn{constructor(){super('\n            <div class="ag-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eReadOnlyText"></ag-input-text-field>\n                <div ref="eDateWrapper" style="display: flex;"></div>\n            </div>')}getDefaultFilterOptions(){return Xn.DEFAULT_FILTER_OPTIONS}init(e){super.init(e),this.params=e,this.filterParams=e.filterParams,this.createDateComponent(),this.filterModelFormatter=new Yn(this.filterParams,this.localeService,this.optionsFactory);const t=this.localeService.getLocaleTextFunc();this.eReadOnlyText.setDisabled(!0).setInputAriaLabel(t("ariaDateFilterInput","Date Filter Input"))}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.params=e,this.filterParams=e.filterParams,this.updateDateComponent(),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory,dateFilterParams:this.filterParams}),this.updateCompOnModelChange(e.currentParentModel())}updateCompOnModelChange(e){const t=!this.isReadOnly()&&this.canWeEditAfterModelFromParentFilter(e);if(this.setEditable(t),t){if(e){const t=e;this.dateComp.setDate(Zi(t.dateFrom))}else this.dateComp.setDate(null);this.eReadOnlyText.setValue("")}else this.eReadOnlyText.setValue(this.filterModelFormatter.getModelAsString(e)),this.dateComp.setDate(null)}setEditable(e){sr(this.eDateWrapper,e),sr(this.eReadOnlyText.getGui(),!e)}onParentModelChanged(e,t){this.isEventFromFloatingFilter(t)||this.isEventFromDataChange(t)||(super.setLastTypeFromModel(e),this.updateCompOnModelChange(e))}onDateChanged(){const e=Yi(this.dateComp.getDate());this.params.parentFilterInstance(t=>{if(t){const i=Zi(e);t.onFloatingFilterChanged(this.getLastType()||null,i)}})}getDateComponentParams(){const e=Ln.getDebounceMs(this.params.filterParams,this.getDefaultDebounceMs());return{onDateChanged:X(this.onDateChanged.bind(this),e),filterParams:this.params.column.getColDef().filterParams}}createDateComponent(){this.dateComp=new An(this.getContext(),this.userComponentFactory,this.getDateComponentParams(),this.eDateWrapper,e=>{e.setInputAriaLabel(this.getAriaLabel(this.params))}),this.addDestroyFunc(()=>this.dateComp.destroy())}updateDateComponent(){const e=this.gos.addGridCommonParams(this.getDateComponentParams());this.dateComp.updateParams(e)}getFilterModelFormatter(){return this.filterModelFormatter}};g([ue("userComponentFactory")],Jn.prototype,"userComponentFactory",2),g([Sn("eReadOnlyText")],Jn.prototype,"eReadOnlyText",2),g([Sn("eDateWrapper")],Jn.prototype,"eDateWrapper",2);var es=class extends yn{constructor(){super('\n            <div class="ag-filter-filter">\n                <ag-input-text-field class="ag-date-filter" ref="eDateInput"></ag-input-text-field>\n            </div>')}destroy(){super.destroy()}init(e){this.params=e,this.setParams(e);const t=this.eDateInput.getInputElement();this.addManagedListener(t,"mousedown",()=>{this.eDateInput.isDisabled()||this.usingSafariDatePicker||t.focus()}),this.addManagedListener(t,"input",e=>{e.target===this.gos.getActiveDomElement()&&(this.eDateInput.isDisabled()||this.params.onDateChanged())})}setParams(e){const t=this.eDateInput.getInputElement(),i=this.shouldUseBrowserDatePicker(e);this.usingSafariDatePicker=i&&Mi(),t.type=i?"date":"text";const{minValidYear:r,maxValidYear:n,minValidDate:s,maxValidDate:o}=e.filterParams||{};if(s&&r&&z("DateFilter should not have both minValidDate and minValidYear parameters set at the same time! minValidYear will be ignored."),o&&n&&z("DateFilter should not have both maxValidDate and maxValidYear parameters set at the same time! maxValidYear will be ignored."),s&&o){const[e,t]=[s,o].map(e=>e instanceof Date?e:Zi(e));e&&t&&e.getTime()>t.getTime()&&z("DateFilter parameter minValidDate should always be lower than or equal to parameter maxValidDate.")}s?s instanceof Date?t.min=Xi(s):t.min=s:r&&(t.min=`${r}-01-01`),o?o instanceof Date?t.max=Xi(o):t.max=o:n&&(t.max=`${n}-12-31`)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams(e)}getDate(){return Zi(this.eDateInput.getValue())}setDate(e){this.eDateInput.setValue(Yi(e,!1))}setInputPlaceholder(e){this.eDateInput.setInputPlaceholder(e)}setInputAriaLabel(e){this.eDateInput.setAriaLabel(e)}setDisabled(e){this.eDateInput.setDisabled(e)}afterGuiAttached(e){e&&e.suppressFocus||this.eDateInput.getInputElement().focus()}shouldUseBrowserDatePicker(e){return e.filterParams&&null!=e.filterParams.browserDatePicker?e.filterParams.browserDatePicker:_i()||Pi()||Mi()&&Ri()>=14.1}};g([Sn("eDateInput")],es.prototype,"eDateInput",2);var ts=class extends Bn{constructor(e,t="ag-text-field",i="text"){super(e,t,i)}postConstruct(){super.postConstruct(),this.config.allowedCharPattern&&this.preventDisallowedCharacters()}setValue(e,t){return this.eInput.value!==e&&(this.eInput.value=C(e)?e:""),super.setValue(e,t)}setStartValue(e){this.setValue(e,!0)}preventDisallowedCharacters(){const e=new RegExp(`[${this.config.allowedCharPattern}]`);this.addManagedListener(this.eInput,"keydown",t=>{Qr(t)&&t.key&&!e.test(t.key)&&t.preventDefault()}),this.addManagedListener(this.eInput,"paste",t=>{var i;const r=null==(i=t.clipboardData)?void 0:i.getData("text");r&&r.split("").some(t=>!e.test(t))&&t.preventDefault()})}},is=class extends ts{constructor(e){super(e,"ag-number-field","number")}postConstruct(){super.postConstruct(),this.addManagedListener(this.eInput,"blur",()=>{const e=parseFloat(this.eInput.value),t=isNaN(e)?"":this.normalizeValue(e.toString());this.value!==t&&this.setValue(t)}),this.addManagedListener(this.eInput,"wheel",this.onWheel.bind(this)),this.eInput.step="any";const{precision:e,min:t,max:i,step:r}=this.config;"number"==typeof e&&this.setPrecision(e),"number"==typeof t&&this.setMin(t),"number"==typeof i&&this.setMax(i),"number"==typeof r&&this.setStep(r)}onWheel(e){this.gos.getActiveDomElement()===this.eInput&&e.preventDefault()}normalizeValue(e){if(""===e)return"";null!=this.precision&&(e=this.adjustPrecision(e));const t=parseFloat(e);return null!=this.min&&t<this.min?e=this.min.toString():null!=this.max&&t>this.max&&(e=this.max.toString()),e}adjustPrecision(e,t){if(null==this.precision)return e;if(t){const t=parseFloat(e).toFixed(this.precision);return parseFloat(t).toString()}const i=String(e).split(".");if(i.length>1){if(i[1].length<=this.precision)return e;if(this.precision>0)return`${i[0]}.${i[1].slice(0,this.precision)}`}return i[0]}setMin(e){return this.min===e||(this.min=e,kr(this.eInput,"min",e)),this}setMax(e){return this.max===e||(this.max=e,kr(this.eInput,"max",e)),this}setPrecision(e){return this.precision=e,this}setStep(e){return this.step===e||(this.step=e,kr(this.eInput,"step",e)),this}setValue(e,t){return this.setValueOrInputValue(e=>super.setValue(e,t),()=>this,e)}setStartValue(e){return this.setValueOrInputValue(e=>super.setValue(e,!0),e=>{this.eInput.value=e},e)}setValueOrInputValue(e,t,i){if(C(i)){let r=this.isScientificNotation(i);if(r&&this.eInput.validity.valid)return e(i);if(r||(r=(i=this.adjustPrecision(i))!=this.normalizeValue(i)),r)return t(i)}return e(i)}getValue(){if(!this.eInput.validity.valid)return;const e=this.eInput.value;return this.isScientificNotation(e)?this.adjustPrecision(e,!0):super.getValue()}isScientificNotation(e){return"string"==typeof e&&e.includes("e")}},rs=class extends Wn{conditionToString(e,t){const{numberOfInputs:i}=t||{};return e.type==Kn.IN_RANGE||2===i?`${this.formatValue(e.filter)}-${this.formatValue(e.filterTo)}`:null!=e.filter?this.formatValue(e.filter):`${e.type}`}};function ns(e){const{allowedCharPattern:t}=null!=e?e:{};return null!=t?t:null}var ss=class e extends $n{constructor(){super("numberFilter"),this.eValuesFrom=[],this.eValuesTo=[]}refresh(e){return this.numberFilterParams.allowedCharPattern===e.allowedCharPattern&&super.refresh(e)}mapValuesFromModel(e){const{filter:t,filterTo:i,type:r}=e||{};return[this.processValue(t),this.processValue(i)].slice(0,this.getNumberOfInputs(r))}getDefaultDebounceMs(){return 500}comparator(){return(e,t)=>e===t?0:e<t?1:-1}setParams(e){this.numberFilterParams=e,super.setParams(e),this.filterModelFormatter=new rs(this.localeService,this.optionsFactory,this.numberFilterParams.numberFormatter)}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}setElementValue(e,t,i){const r=!i&&this.numberFilterParams.numberFormatter?this.numberFilterParams.numberFormatter(null!=t?t:null):t;super.setElementValue(e,r)}createValueElement(){const e=ns(this.numberFilterParams),t=document.createElement("div");return t.classList.add("ag-filter-body"),Ht(t,"presentation"),this.createFromToElement(t,this.eValuesFrom,"from",e),this.createFromToElement(t,this.eValuesTo,"to",e),t}createFromToElement(e,t,i,r){const n=this.createManagedBean(r?new ts({allowedCharPattern:r}):new is);n.addCssClass(`ag-filter-${i}`),n.addCssClass("ag-filter-filter"),t.push(n),e.appendChild(n.getGui())}removeValueElements(e,t){this.removeComponents(this.eValuesFrom,e,t),this.removeComponents(this.eValuesTo,e,t)}getValues(e){const t=[];return this.forEachPositionInput(e,(e,i,r,n)=>{i<n&&t.push(this.processValue(this.stringToFloat(e.getValue())))}),t}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getFilterType(){return"number"}processValue(e){return null==e||isNaN(e)?null:e}stringToFloat(e){if("number"==typeof e)return e;let t=v(e);return null!=t&&""===t.trim()&&(t=null),this.numberFilterParams.numberParser?this.numberFilterParams.numberParser(t):null==t||"-"===t.trim()?null:parseFloat(t)}createCondition(e){const t=this.getConditionType(e),i={filterType:this.getFilterType(),type:t},r=this.getValues(e);return r.length>0&&(i.filter=r[0]),r.length>1&&(i.filterTo=r[1]),i}getInputs(e){return e>=this.eValuesFrom.length?[null,null]:[this.eValuesFrom[e],this.eValuesTo[e]]}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}hasInvalidInputs(){let e=!1;return this.forEachInput(t=>{t.getInputElement().validity.valid||(e=!0)}),e}};ss.DEFAULT_FILTER_OPTIONS=[$n.EQUALS,$n.NOT_EQUAL,$n.GREATER_THAN,$n.GREATER_THAN_OR_EQUAL,$n.LESS_THAN,$n.LESS_THAN_OR_EQUAL,$n.IN_RANGE,$n.BLANK,$n.NOT_BLANK];var os=ss,as=class extends Wn{conditionToString(e,t){const{numberOfInputs:i}=t||{};return e.type==Kn.IN_RANGE||2===i?`${e.filter}-${e.filterTo}`:null!=e.filter?`${e.filter}`:`${e.type}`}},ls=class e extends Kn{constructor(){super("textFilter"),this.eValuesFrom=[],this.eValuesTo=[]}static trimInput(e){const t=e&&e.trim();return""===t?e:t}getDefaultDebounceMs(){return 500}setParams(t){this.textFilterParams=t,super.setParams(t),this.matcher=this.getTextMatcher(),this.formatter=this.textFilterParams.textFormatter||(this.textFilterParams.caseSensitive?e.DEFAULT_FORMATTER:e.DEFAULT_LOWERCASE_FORMATTER),this.filterModelFormatter=new as(this.localeService,this.optionsFactory)}getTextMatcher(){const t=this.textFilterParams.textCustomComparator;return t?(ln.warnOnce("textCustomComparator is deprecated, use textMatcher instead."),({filterOption:e,value:i,filterText:r})=>t(e,i,r)):this.textFilterParams.textMatcher||e.DEFAULT_MATCHER}createCondition(e){const t=this.getConditionType(e),i={filterType:this.getFilterType(),type:t},r=this.getValuesWithSideEffects(e,!0);return r.length>0&&(i.filter=r[0]),r.length>1&&(i.filterTo=r[1]),i}getFilterType(){return"text"}areSimpleModelsEqual(e,t){return e.filter===t.filter&&e.filterTo===t.filterTo&&e.type===t.type}getInputs(e){return e>=this.eValuesFrom.length?[null,null]:[this.eValuesFrom[e],this.eValuesTo[e]]}getValues(e){return this.getValuesWithSideEffects(e,!1)}getValuesWithSideEffects(t,i){const r=[];return this.forEachPositionInput(t,(t,n,s,o)=>{var a;if(n<o){let n=v(t.getValue());i&&this.textFilterParams.trimInput&&(n=null!=(a=e.trimInput(n))?a:null,t.setValue(n,!0)),r.push(n)}}),r}getDefaultFilterOptions(){return e.DEFAULT_FILTER_OPTIONS}createValueElement(){const e=document.createElement("div");return e.classList.add("ag-filter-body"),Ht(e,"presentation"),this.createFromToElement(e,this.eValuesFrom,"from"),this.createFromToElement(e,this.eValuesTo,"to"),e}createFromToElement(e,t,i){const r=this.createManagedBean(new ts);r.addCssClass(`ag-filter-${i}`),r.addCssClass("ag-filter-filter"),t.push(r),e.appendChild(r.getGui())}removeValueElements(e,t){this.removeComponents(this.eValuesFrom,e,t),this.removeComponents(this.eValuesTo,e,t)}mapValuesFromModel(e){const{filter:t,filterTo:i,type:r}=e||{};return[t||null,i||null].slice(0,this.getNumberOfInputs(r))}evaluateNullValue(e){const t=[Kn.NOT_EQUAL,Kn.NOT_CONTAINS,Kn.BLANK];return!!e&&t.indexOf(e)>=0}evaluateNonNullValue(e,t,i,r){const n=e.map(e=>this.formatter(e))||[],s=this.formatter(t),{api:o,colDef:a,column:l,columnApi:c,context:u,textFormatter:p}=this.textFilterParams;if(i.type===Kn.BLANK)return this.isBlank(t);if(i.type===Kn.NOT_BLANK)return!this.isBlank(t);const g={api:o,colDef:a,column:l,columnApi:c,context:u,node:r.node,data:r.data,filterOption:i.type,value:s,textFormatter:p};return n.some(e=>this.matcher(d(h({},g),{filterText:e})))}getModelAsString(e){var t;return null!=(t=this.filterModelFormatter.getModelAsString(e))?t:""}};ls.DEFAULT_FILTER_OPTIONS=[Kn.CONTAINS,Kn.NOT_CONTAINS,Kn.EQUALS,Kn.NOT_EQUAL,Kn.STARTS_WITH,Kn.ENDS_WITH,Kn.BLANK,Kn.NOT_BLANK],ls.DEFAULT_FORMATTER=e=>e,ls.DEFAULT_LOWERCASE_FORMATTER=e=>null==e?null:e.toString().toLowerCase(),ls.DEFAULT_MATCHER=({filterOption:e,value:t,filterText:i})=>{if(null==i)return!1;switch(e){case ls.CONTAINS:return t.indexOf(i)>=0;case ls.NOT_CONTAINS:return t.indexOf(i)<0;case ls.EQUALS:return t===i;case ls.NOT_EQUAL:return t!=i;case ls.STARTS_WITH:return 0===t.indexOf(i);case ls.ENDS_WITH:const e=t.lastIndexOf(i);return e>=0&&e===t.length-i.length;default:return!1}};var cs=ls,us=class extends rt{constructor(e){super(),this.params=e,this.valueChangedListener=()=>{}}setupGui(e){var t;this.eFloatingFilterTextInput=this.createManagedBean(new ts(null==(t=this.params)?void 0:t.config));const i=this.eFloatingFilterTextInput.getGui();e.appendChild(i),this.addManagedListener(i,"input",e=>this.valueChangedListener(e)),this.addManagedListener(i,"keydown",e=>this.valueChangedListener(e))}setEditable(e){this.eFloatingFilterTextInput.setDisabled(!e)}setAutoComplete(e){this.eFloatingFilterTextInput.setAutoComplete(e)}getValue(){return this.eFloatingFilterTextInput.getValue()}setValue(e,t){this.eFloatingFilterTextInput.setValue(e,t)}setValueChangedListener(e){this.valueChangedListener=e}setParams(e){this.setAriaLabel(e.ariaLabel),void 0!==e.autoComplete&&this.setAutoComplete(e.autoComplete)}setAriaLabel(e){this.eFloatingFilterTextInput.setInputAriaLabel(e)}},hs=class extends Zn{postConstruct(){this.setTemplate('\n            <div class="ag-floating-filter-input" role="presentation" ref="eFloatingFilterInputContainer"></div>\n        ')}getDefaultDebounceMs(){return 500}onParentModelChanged(e,t){this.isEventFromFloatingFilter(t)||this.isEventFromDataChange(t)||(this.setLastTypeFromModel(e),this.setEditable(this.canWeEditAfterModelFromParentFilter(e)),this.floatingFilterInputService.setValue(this.getFilterModelFormatter().getModelAsString(e)))}init(e){this.setupFloatingFilterInputService(e),super.init(e),this.setTextInputParams(e)}setupFloatingFilterInputService(e){this.floatingFilterInputService=this.createFloatingFilterInputService(e),this.floatingFilterInputService.setupGui(this.eFloatingFilterInputContainer)}setTextInputParams(e){var t;this.params=e;const i=null!=(t=e.browserAutoComplete)&&t;if(this.floatingFilterInputService.setParams({ariaLabel:this.getAriaLabel(e),autoComplete:i}),this.applyActive=Ln.isUseApplyButton(this.params.filterParams),!this.isReadOnly()){const e=Ln.getDebounceMs(this.params.filterParams,this.getDefaultDebounceMs()),t=X(this.syncUpWithParentFilter.bind(this),e);this.floatingFilterInputService.setValueChangedListener(t)}}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.setTextInputParams(e)}recreateFloatingFilterInputService(e){const t=this.floatingFilterInputService.getValue();Cr(this.eFloatingFilterInputContainer),this.destroyBean(this.floatingFilterInputService),this.setupFloatingFilterInputService(e),this.floatingFilterInputService.setValue(t,!0)}syncUpWithParentFilter(e){const t=e.key===Yr.ENTER;if(this.applyActive&&!t)return;let i=this.floatingFilterInputService.getValue();this.params.filterParams.trimInput&&(i=cs.trimInput(i),this.floatingFilterInputService.setValue(i,!0)),this.params.parentFilterInstance(e=>{e&&e.onFloatingFilterChanged(this.getLastType()||null,i||null)})}setEditable(e){this.floatingFilterInputService.setEditable(e)}};g([Sn("eFloatingFilterInputContainer")],hs.prototype,"eFloatingFilterInputContainer",2),g([ae],hs.prototype,"postConstruct",1);var ds=class extends rt{constructor(){super(...arguments),this.valueChangedListener=()=>{},this.numberInputActive=!0}setupGui(e){this.eFloatingFilterNumberInput=this.createManagedBean(new is),this.eFloatingFilterTextInput=this.createManagedBean(new ts),this.eFloatingFilterTextInput.setDisabled(!0);const t=this.eFloatingFilterNumberInput.getGui(),i=this.eFloatingFilterTextInput.getGui();e.appendChild(t),e.appendChild(i),this.setupListeners(t,e=>this.valueChangedListener(e)),this.setupListeners(i,e=>this.valueChangedListener(e))}setEditable(e){this.numberInputActive=e,this.eFloatingFilterNumberInput.setDisplayed(this.numberInputActive),this.eFloatingFilterTextInput.setDisplayed(!this.numberInputActive)}setAutoComplete(e){this.eFloatingFilterNumberInput.setAutoComplete(e),this.eFloatingFilterTextInput.setAutoComplete(e)}getValue(){return this.getActiveInputElement().getValue()}setValue(e,t){this.getActiveInputElement().setValue(e,t)}getActiveInputElement(){return this.numberInputActive?this.eFloatingFilterNumberInput:this.eFloatingFilterTextInput}setValueChangedListener(e){this.valueChangedListener=e}setupListeners(e,t){this.addManagedListener(e,"input",t),this.addManagedListener(e,"keydown",t)}setParams(e){this.setAriaLabel(e.ariaLabel),void 0!==e.autoComplete&&this.setAutoComplete(e.autoComplete)}setAriaLabel(e){this.eFloatingFilterNumberInput.setInputAriaLabel(e),this.eFloatingFilterTextInput.setInputAriaLabel(e)}},ps=class extends hs{init(e){var t;super.init(e),this.filterModelFormatter=new rs(this.localeService,this.optionsFactory,null==(t=e.filterParams)?void 0:t.numberFormatter)}onParamsUpdated(e){this.refresh(e)}refresh(e){ns(e.filterParams)!==this.allowedCharPattern&&this.recreateFloatingFilterInputService(e),super.refresh(e),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory})}getDefaultFilterOptions(){return os.DEFAULT_FILTER_OPTIONS}getFilterModelFormatter(){return this.filterModelFormatter}createFloatingFilterInputService(e){return this.allowedCharPattern=ns(e.filterParams),this.allowedCharPattern?this.createManagedBean(new us({config:{allowedCharPattern:this.allowedCharPattern}})):this.createManagedBean(new ds)}},gs=class extends hs{init(e){super.init(e),this.filterModelFormatter=new as(this.localeService,this.optionsFactory)}onParamsUpdated(e){this.refresh(e)}refresh(e){super.refresh(e),this.filterModelFormatter.updateParams({optionsFactory:this.optionsFactory})}getDefaultFilterOptions(){return cs.DEFAULT_FILTER_OPTIONS}getFilterModelFormatter(){return this.filterModelFormatter}createFloatingFilterInputService(){return this.createManagedBean(new us)}},fs=class e{constructor(e,t=!1){this.destroyFuncs=[],this.touching=!1,this.eventService=new fe,this.eElement=e,this.preventMouseClick=t;const i=this.onTouchStart.bind(this),r=this.onTouchMove.bind(this),n=this.onTouchEnd.bind(this);this.eElement.addEventListener("touchstart",i,{passive:!0}),this.eElement.addEventListener("touchmove",r,{passive:!0}),this.eElement.addEventListener("touchend",n,{passive:!1}),this.destroyFuncs.push(()=>{this.eElement.removeEventListener("touchstart",i,{passive:!0}),this.eElement.removeEventListener("touchmove",r,{passive:!0}),this.eElement.removeEventListener("touchend",n,{passive:!1})})}getActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}addEventListener(e,t){this.eventService.addEventListener(e,t)}removeEventListener(e,t){this.eventService.removeEventListener(e,t)}onTouchStart(t){if(this.touching)return;this.touchStart=t.touches[0],this.touching=!0,this.moved=!1;const i=this.touchStart;window.setTimeout(()=>{const r=this.touchStart===i;if(this.touching&&r&&!this.moved){this.moved=!0;const i={type:e.EVENT_LONG_TAP,touchStart:this.touchStart,touchEvent:t};this.eventService.dispatchEvent(i)}},500)}onTouchMove(e){if(!this.touching)return;const t=this.getActiveTouch(e.touches);t&&!rn(t,this.touchStart,4)&&(this.moved=!0)}onTouchEnd(t){if(this.touching){if(!this.moved){const t={type:e.EVENT_TAP,touchStart:this.touchStart};this.eventService.dispatchEvent(t),this.checkForDoubleTap()}this.preventMouseClick&&t.cancelable&&t.preventDefault(),this.touching=!1}}checkForDoubleTap(){const t=(new Date).getTime();if(this.lastTapTime&&this.lastTapTime>0)if(t-this.lastTapTime>e.DOUBLE_TAP_MILLIS){const t={type:e.EVENT_DOUBLE_TAP,touchStart:this.touchStart};this.eventService.dispatchEvent(t),this.lastTapTime=null}else this.lastTapTime=t;else this.lastTapTime=t}destroy(){this.destroyFuncs.forEach(e=>e())}};fs.EVENT_TAP="tap",fs.EVENT_DOUBLE_TAP="doubleTap",fs.EVENT_LONG_TAP="longTap",fs.DOUBLE_TAP_MILLIS=500;var ms=fs,vs=class e extends yn{constructor(t){super(),t||this.setTemplate(e.TEMPLATE)}attachCustomElements(e,t,i,r,n){this.eSortOrder=e,this.eSortAsc=t,this.eSortDesc=i,this.eSortMixed=r,this.eSortNone=n}setupSort(e,t=!1){this.column=e,this.suppressOrder=t,this.setupMultiSortIndicator(),(this.column.isSortable()||this.column.getColDef().showRowGroup)&&(this.addInIcon("sortAscending",this.eSortAsc,e),this.addInIcon("sortDescending",this.eSortDesc,e),this.addInIcon("sortUnSort",this.eSortNone,e),this.addManagedPropertyListener("unSortIcon",()=>this.updateIcons()),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.updateIcons()),this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,()=>this.onSortChanged()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onSortChanged()),this.onSortChanged())}addInIcon(e,t,i){if(null==t)return;const r=$r(e,this.gos,i);r&&t.appendChild(r)}onSortChanged(){this.updateIcons(),this.suppressOrder||this.updateSortOrder()}updateIcons(){const e=this.sortController.getDisplaySortForColumn(this.column);if(this.eSortAsc){const t="asc"===e;sr(this.eSortAsc,t,{skipAriaHidden:!0})}if(this.eSortDesc){const t="desc"===e;sr(this.eSortDesc,t,{skipAriaHidden:!0})}if(this.eSortNone){const t=!this.column.getColDef().unSortIcon&&!this.gos.get("unSortIcon"),i=null==e;sr(this.eSortNone,!t&&i,{skipAriaHidden:!0})}}setupMultiSortIndicator(){this.addInIcon("sortUnSort",this.eSortMixed,this.column);const e=this.column.getColDef().showRowGroup;this.gos.isColumnsSortingCoupledToGroup()&&e&&(this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,()=>this.updateMultiSortIndicator()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.updateMultiSortIndicator()),this.updateMultiSortIndicator())}updateMultiSortIndicator(){if(this.eSortMixed){const e="mixed"===this.sortController.getDisplaySortForColumn(this.column);sr(this.eSortMixed,e,{skipAriaHidden:!0})}}updateSortOrder(){var e;if(!this.eSortOrder)return;const t=this.sortController.getColumnsWithSortingOrdered(),i=null!=(e=this.sortController.getDisplaySortIndexForColumn(this.column))?e:-1,r=t.some(e=>{var t;return null!=(t=this.sortController.getDisplaySortIndexForColumn(e))&&t}),n=i>=0&&r;sr(this.eSortOrder,n,{skipAriaHidden:!0}),i>=0?this.eSortOrder.textContent=(i+1).toString():Cr(this.eSortOrder)}};vs.TEMPLATE='<span class="ag-sort-indicator-container">\n            <span ref="eSortOrder" class="ag-sort-indicator-icon ag-sort-order ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortAsc" class="ag-sort-indicator-icon ag-sort-ascending-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortDesc" class="ag-sort-indicator-icon ag-sort-descending-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortMixed" class="ag-sort-indicator-icon ag-sort-mixed-icon ag-hidden" aria-hidden="true"></span>\n            <span ref="eSortNone" class="ag-sort-indicator-icon ag-sort-none-icon ag-hidden" aria-hidden="true"></span>\n        </span>',g([Sn("eSortOrder")],vs.prototype,"eSortOrder",2),g([Sn("eSortAsc")],vs.prototype,"eSortAsc",2),g([Sn("eSortDesc")],vs.prototype,"eSortDesc",2),g([Sn("eSortMixed")],vs.prototype,"eSortMixed",2),g([Sn("eSortNone")],vs.prototype,"eSortNone",2),g([ue("columnModel")],vs.prototype,"columnModel",2),g([ue("sortController")],vs.prototype,"sortController",2);var Cs=vs,ys=class e extends yn{constructor(){super(...arguments),this.lastMovingChanged=0}destroy(){super.destroy()}refresh(e){const t=this.params;return this.params=e,this.workOutTemplate()==this.currentTemplate&&this.workOutShowMenu()==this.currentShowMenu&&this.workOutSort()==this.currentSort&&this.shouldSuppressMenuHide()==this.currentSuppressMenuHide&&t.enableFilterButton==e.enableFilterButton&&t.enableFilterIcon==e.enableFilterIcon&&(this.setDisplayName(e),!0)}workOutTemplate(){var t;let i=null!=(t=this.params.template)?t:e.TEMPLATE;return i=i&&i.trim?i.trim():i,i}init(e){this.params=e,this.currentTemplate=this.workOutTemplate(),this.setTemplate(this.currentTemplate),this.setupTap(),this.setMenu(),this.setupSort(),this.setupFilterIcon(),this.setupFilterButton(),this.setDisplayName(e)}setDisplayName(e){if(this.currentDisplayName!=e.displayName){this.currentDisplayName=e.displayName;const t=Ct(this.currentDisplayName,!0);this.eText&&(this.eText.textContent=t)}}addInIcon(e,t,i){if(null==t)return;const r=$r(e,this.gos,i);r&&t.appendChild(r)}setupTap(){const{gos:e}=this;if(e.get("suppressTouch"))return;const t=new ms(this.getGui(),!0),i=this.shouldSuppressMenuHide(),r=i&&C(this.eMenu),n=r?new ms(this.eMenu,!0):t;if(this.params.enableMenu){const e=r?"EVENT_TAP":"EVENT_LONG_TAP",t=e=>this.params.showColumnMenuAfterMouseClick(e.touchStart);this.addManagedListener(n,ms[e],t)}if(this.params.enableSorting){const e=e=>{var t,r;const n=e.touchStart.target;i&&((null==(t=this.eMenu)?void 0:t.contains(n))||(null==(r=this.eFilterButton)?void 0:r.contains(n)))||this.sortController.progressSort(this.params.column,!1,"uiColumnSorted")};this.addManagedListener(t,ms.EVENT_TAP,e)}if(this.params.enableFilterButton){const e=new ms(this.eFilterButton,!0);this.addManagedListener(e,"tap",()=>this.params.showFilter(this.eFilterButton)),this.addDestroyFunc(()=>e.destroy())}this.addDestroyFunc(()=>t.destroy()),r&&this.addDestroyFunc(()=>n.destroy())}workOutShowMenu(){return this.params.enableMenu&&this.menuService.isHeaderMenuButtonEnabled()}shouldSuppressMenuHide(){return this.menuService.isHeaderMenuButtonAlwaysShowEnabled()}setMenu(){if(!this.eMenu)return;if(this.currentShowMenu=this.workOutShowMenu(),!this.currentShowMenu)return yr(this.eMenu),void(this.eMenu=void 0);const e=this.menuService.isLegacyMenuEnabled();this.addInIcon(e?"menu":"menuAlt",this.eMenu,this.params.column),this.eMenu.classList.toggle("ag-header-menu-icon",!e),this.currentSuppressMenuHide=this.shouldSuppressMenuHide(),this.addManagedListener(this.eMenu,"click",()=>this.params.showColumnMenu(this.eMenu)),this.eMenu.classList.toggle("ag-header-menu-always-show",this.currentSuppressMenuHide)}onMenuKeyboardShortcut(e){var t,i,r,n;const{column:s}=this.params,o=this.menuService.isLegacyMenuEnabled();if(e&&!o){if(this.menuService.isFilterMenuInHeaderEnabled(s))return this.params.showFilter(null!=(i=null!=(t=this.eFilterButton)?t:this.eMenu)?i:this.getGui()),!0}else if(this.params.enableMenu)return this.params.showColumnMenu(null!=(n=null!=(r=this.eMenu)?r:this.eFilterButton)?n:this.getGui()),!0;return!1}workOutSort(){return this.params.enableSorting}setupSort(){if(this.currentSort=this.params.enableSorting,this.eSortIndicator||(this.eSortIndicator=this.context.createBean(new Cs(!0)),this.eSortIndicator.attachCustomElements(this.eSortOrder,this.eSortAsc,this.eSortDesc,this.eSortMixed,this.eSortNone)),this.eSortIndicator.setupSort(this.params.column),!this.currentSort)return;this.addManagedListener(this.params.column,Se.EVENT_MOVING_CHANGED,()=>{this.lastMovingChanged=(new Date).getTime()}),this.eLabel&&this.addManagedListener(this.eLabel,"click",e=>{const t=this.params.column.isMoving(),i=(new Date).getTime()-this.lastMovingChanged<50;if(!t&&!i){const t="ctrl"===this.gos.get("multiSortKey")?e.ctrlKey||e.metaKey:e.shiftKey;this.params.progressSort(t)}});const e=()=>{if(this.addOrRemoveCssClass("ag-header-cell-sorted-asc",this.params.column.isSortAscending()),this.addOrRemoveCssClass("ag-header-cell-sorted-desc",this.params.column.isSortDescending()),this.addOrRemoveCssClass("ag-header-cell-sorted-none",this.params.column.isSortNone()),this.params.column.getColDef().showRowGroup){const e=this.columnModel.getSourceColumnsForGroupColumn(this.params.column),t=!(null==e?void 0:e.every(e=>this.params.column.getSort()==e.getSort()));this.addOrRemoveCssClass("ag-header-cell-sorted-mixed",t)}};this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,e)}setupFilterIcon(){this.eFilter&&this.configureFilter(this.params.enableFilterIcon,this.eFilter,this.onFilterChangedIcon.bind(this))}setupFilterButton(){this.eFilterButton&&(this.configureFilter(this.params.enableFilterButton,this.eFilterButton,this.onFilterChangedButton.bind(this))?this.addManagedListener(this.eFilterButton,"click",()=>this.params.showFilter(this.eFilterButton)):this.eFilterButton=void 0)}configureFilter(e,t,i){if(!e)return yr(t),!1;const{column:r}=this.params;return this.addInIcon("filter",t,r),this.addManagedListener(r,Se.EVENT_FILTER_CHANGED,i),i(),!0}onFilterChangedIcon(){const e=this.params.column.isFilterActive();sr(this.eFilter,e,{skipAriaHidden:!0})}onFilterChangedButton(){const e=this.params.column.isFilterActive();this.eFilterButton.classList.toggle("ag-filter-active",e)}getAnchorElementForMenu(e){var t,i,r,n;return e?null!=(i=null!=(t=this.eFilterButton)?t:this.eMenu)?i:this.getGui():null!=(n=null!=(r=this.eMenu)?r:this.eFilterButton)?n:this.getGui()}};ys.TEMPLATE='<div class="ag-cell-label-container" role="presentation">\n            <span ref="eMenu" class="ag-header-icon ag-header-cell-menu-button" aria-hidden="true"></span>\n            <span ref="eFilterButton" class="ag-header-icon ag-header-cell-filter-button" aria-hidden="true"></span>\n            <div ref="eLabel" class="ag-header-cell-label" role="presentation">\n                <span ref="eText" class="ag-header-cell-text"></span>\n                <span ref="eFilter" class="ag-header-icon ag-header-label-icon ag-filter-icon" aria-hidden="true"></span>\n                <ag-sort-indicator ref="eSortIndicator"></ag-sort-indicator>\n            </div>\n        </div>',g([ue("sortController")],ys.prototype,"sortController",2),g([ue("menuService")],ys.prototype,"menuService",2),g([ue("columnModel")],ys.prototype,"columnModel",2),g([Sn("eFilter")],ys.prototype,"eFilter",2),g([Sn("eFilterButton")],ys.prototype,"eFilterButton",2),g([Sn("eSortIndicator")],ys.prototype,"eSortIndicator",2),g([Sn("eMenu")],ys.prototype,"eMenu",2),g([Sn("eLabel")],ys.prototype,"eLabel",2),g([Sn("eText")],ys.prototype,"eText",2),g([Sn("eSortOrder")],ys.prototype,"eSortOrder",2),g([Sn("eSortAsc")],ys.prototype,"eSortAsc",2),g([Sn("eSortDesc")],ys.prototype,"eSortDesc",2),g([Sn("eSortMixed")],ys.prototype,"eSortMixed",2),g([Sn("eSortNone")],ys.prototype,"eSortNone",2);var ws=ys,Ss=class e extends yn{constructor(){super(e.TEMPLATE)}destroy(){super.destroy()}init(e){this.params=e,this.checkWarnings(),this.setupLabel(),this.addGroupExpandIcon(),this.setupExpandIcons()}checkWarnings(){this.params.template&&z("A template was provided for Header Group Comp - templates are only supported for Header Comps (not groups)")}setupExpandIcons(){this.addInIcon("columnGroupOpened","agOpened"),this.addInIcon("columnGroupClosed","agClosed");const e=e=>{if(Ye(e))return;const t=!this.params.columnGroup.isExpanded();this.columnModel.setColumnGroupOpened(this.params.columnGroup.getProvidedColumnGroup(),t,"uiColumnExpanded")};this.addTouchAndClickListeners(this.eCloseIcon,e),this.addTouchAndClickListeners(this.eOpenIcon,e);const t=e=>{qe(e)};this.addManagedListener(this.eCloseIcon,"dblclick",t),this.addManagedListener(this.eOpenIcon,"dblclick",t),this.addManagedListener(this.getGui(),"dblclick",e),this.updateIconVisibility();const i=this.params.columnGroup.getProvidedColumnGroup();this.addManagedListener(i,Ee.EVENT_EXPANDED_CHANGED,this.updateIconVisibility.bind(this)),this.addManagedListener(i,Ee.EVENT_EXPANDABLE_CHANGED,this.updateIconVisibility.bind(this))}addTouchAndClickListeners(e,t){const i=new ms(e,!0);this.addManagedListener(i,ms.EVENT_TAP,t),this.addDestroyFunc(()=>i.destroy()),this.addManagedListener(e,"click",t)}updateIconVisibility(){if(this.params.columnGroup.isExpandable()){const e=this.params.columnGroup.isExpanded();sr(this.eOpenIcon,e),sr(this.eCloseIcon,!e)}else sr(this.eOpenIcon,!1),sr(this.eCloseIcon,!1)}addInIcon(e,t){const i=$r(e,this.gos,null);i&&this.getRefElement(t).appendChild(i)}addGroupExpandIcon(){if(!this.params.columnGroup.isExpandable())return sr(this.eOpenIcon,!1),void sr(this.eCloseIcon,!1)}setupLabel(){var e;const{displayName:t,columnGroup:i}=this.params;if(C(t)){const e=Ct(t,!0);this.getRefElement("agLabel").textContent=e}this.addOrRemoveCssClass("ag-sticky-label",!(null==(e=i.getColGroupDef())?void 0:e.suppressStickyLabel))}};Ss.TEMPLATE='<div class="ag-header-group-cell-label" ref="agContainer" role="presentation">\n            <span ref="agLabel" class="ag-header-group-text" role="presentation"></span>\n            <span ref="agOpened" class="ag-header-icon ag-header-expand-icon ag-header-expand-icon-expanded"></span>\n            <span ref="agClosed" class="ag-header-icon ag-header-expand-icon ag-header-expand-icon-collapsed"></span>\n        </div>',g([ue("columnModel")],Ss.prototype,"columnModel",2),g([Sn("agOpened")],Ss.prototype,"eOpenIcon",2),g([Sn("agClosed")],Ss.prototype,"eCloseIcon",2);var bs=Ss,Es=class extends yn{isPopup(){return!0}setParentComponent(e){e.addCssClass("ag-has-popup"),super.setParentComponent(e)}destroy(){const e=this.parentComponent;e&&e.isAlive()&&e.getGui().classList.remove("ag-has-popup"),super.destroy()}},As=class e extends Es{constructor(){super(e.TEMPLATE)}init(e){this.params=e,this.focusAfterAttached=e.cellStartedEdit,this.eTextArea.setMaxLength(e.maxLength||200).setCols(e.cols||60).setRows(e.rows||10),C(e.value,!0)&&this.eTextArea.setValue(e.value.toString(),!0),this.addGuiEventListener("keydown",this.onKeyDown.bind(this)),this.activateTabIndex()}onKeyDown(e){const t=e.key;(t===Yr.LEFT||t===Yr.UP||t===Yr.RIGHT||t===Yr.DOWN||e.shiftKey&&t===Yr.ENTER)&&e.stopPropagation()}afterGuiAttached(){const e=this.localeService.getLocaleTextFunc();this.eTextArea.setInputAriaLabel(e("ariaInputEditor","Input Editor")),this.focusAfterAttached&&this.eTextArea.getFocusableElement().focus()}getValue(){const e=this.eTextArea.getValue();return C(e)||C(this.params.value)?this.params.parseValue(e):this.params.value}};As.TEMPLATE='<div class="ag-large-text">\n            <ag-input-text-area ref="eTextArea" class="ag-large-text-input"></ag-input-text-area>\n        </div>',g([Sn("eTextArea")],As.prototype,"eTextArea",2);var Ts=As,Ms=class extends Es{constructor(){super('<div class="ag-cell-edit-wrapper">\n                <ag-select class="ag-cell-editor" ref="eSelect"></ag-select>\n            </div>'),this.startedByEnter=!1}init(e){this.focusAfterAttached=e.cellStartedEdit;const{eSelect:t,valueService:i,gos:r}=this,{values:n,value:s,eventKey:o}=e;if(y(n))return void console.warn("AG Grid: no values found for select cellEditor");this.startedByEnter=null!=o&&o===Yr.ENTER;let a=!1;n.forEach(r=>{const n={value:r},o=i.formatValue(e.column,null,r),l=null!=o;n.text=l?o:r,t.addOption(n),a=a||s===r}),a?t.setValue(e.value,!0):e.values.length&&t.setValue(e.values[0],!0);const{valueListGap:l,valueListMaxWidth:c,valueListMaxHeight:u}=e;null!=l&&t.setPickerGap(l),null!=u&&t.setPickerMaxHeight(u),null!=c&&t.setPickerMaxWidth(c),"fullRow"!==r.get("editType")&&this.addManagedListener(this.eSelect,Hn.EVENT_ITEM_SELECTED,()=>e.stopEditing())}afterGuiAttached(){this.focusAfterAttached&&this.eSelect.getFocusableElement().focus(),this.startedByEnter&&setTimeout(()=>{this.isAlive()&&this.eSelect.showPicker()})}focusIn(){this.eSelect.getFocusableElement().focus()}getValue(){return this.eSelect.getValue()}isPopup(){return!1}};g([ue("valueService")],Ms.prototype,"valueService",2),g([Sn("eSelect")],Ms.prototype,"eSelect",2);var Rs=class extends Es{constructor(e){super(`\n            <div class="ag-cell-edit-wrapper">\n                ${e.getTemplate()}\n            </div>`),this.cellEditorInput=e}init(e){this.params=e;const t=this.eInput;let i;if(this.cellEditorInput.init(t,e),e.cellStartedEdit){this.focusAfterAttached=!0;const t=e.eventKey;t===Yr.BACKSPACE||e.eventKey===Yr.DELETE?i="":t&&1===t.length?i=t:(i=this.cellEditorInput.getStartValue(),t!==Yr.F2&&(this.highlightAllOnFocus=!0))}else this.focusAfterAttached=!1,i=this.cellEditorInput.getStartValue();null!=i&&t.setStartValue(i),this.addManagedListener(t.getGui(),"keydown",e=>{const{key:t}=e;t!==Yr.PAGE_UP&&t!==Yr.PAGE_DOWN||e.preventDefault()})}afterGuiAttached(){var e,t;const i=this.localeService.getLocaleTextFunc(),r=this.eInput;if(r.setInputAriaLabel(i("ariaInputEditor","Input Editor")),!this.focusAfterAttached)return;Mi()||r.getFocusableElement().focus();const n=r.getInputElement();this.highlightAllOnFocus?n.select():null==(t=(e=this.cellEditorInput).setCaret)||t.call(e)}focusIn(){const e=this.eInput,t=e.getFocusableElement(),i=e.getInputElement();t.focus(),i.select()}getValue(){return this.cellEditorInput.getValue()}isPopup(){return!1}};g([Sn("eInput")],Rs.prototype,"eInput",2);var _s=class{getTemplate(){return'<ag-input-text-field class="ag-cell-editor" ref="eInput"></ag-input-text-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.maxLength&&e.setMaxLength(t.maxLength)}getValue(){const e=this.eInput.getValue();return C(e)||C(this.params.value)?this.params.parseValue(e):this.params.value}getStartValue(){return this.params.useFormatter||this.params.column.getColDef().refData?this.params.formatValue(this.params.value):this.params.value}setCaret(){const e=this.eInput.getValue(),t=C(e)&&e.length||0;t&&this.eInput.getInputElement().setSelectionRange(t,t)}},Ps=class extends Rs{constructor(){super(new _s)}},xs=class extends yn{constructor(){super(),this.refreshCount=0;const e=document.createElement("span"),t=document.createElement("span");t.setAttribute("class","ag-value-change-delta");const i=document.createElement("span");i.setAttribute("class","ag-value-change-value"),e.appendChild(t),e.appendChild(i),this.setTemplateFromElement(e)}init(e){this.eValue=this.queryForHtmlElement(".ag-value-change-value"),this.eDelta=this.queryForHtmlElement(".ag-value-change-delta"),this.refresh(e,!0)}showDelta(e,t){const i=Math.abs(t),r=e.formatValue(i),n=C(r)?r:i,s=t>=0;this.eDelta.textContent=s?"↑"+n:"↓"+n,this.eDelta.classList.toggle("ag-value-change-delta-up",s),this.eDelta.classList.toggle("ag-value-change-delta-down",!s)}setTimerToRemoveDelta(){this.refreshCount++;const e=this.refreshCount;this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.hideDeltaValue()},2e3)})}hideDeltaValue(){this.eValue.classList.remove("ag-value-change-value-highlight"),Cr(this.eDelta)}refresh(e,t=!1){const i=e.value;if(i===this.lastValue)return!1;if(C(e.valueFormatted)?this.eValue.textContent=e.valueFormatted:C(e.value)?this.eValue.textContent=i:Cr(this.eValue),this.filterManager.isSuppressFlashingCellsBecauseFiltering())return!1;if("number"==typeof i&&"number"==typeof this.lastValue){const t=i-this.lastValue;this.showDelta(e,t)}return this.lastValue&&this.eValue.classList.add("ag-value-change-value-highlight"),t||this.setTimerToRemoveDelta(),this.lastValue=i,!0}};g([ue("filterManager")],xs.prototype,"filterManager",2);var Ds=class extends yn{constructor(){super(),this.refreshCount=0;const e=document.createElement("span"),t=document.createElement("span");t.setAttribute("class","ag-value-slide-current"),e.appendChild(t),this.setTemplateFromElement(e),this.eCurrent=this.queryForHtmlElement(".ag-value-slide-current")}init(e){this.refresh(e,!0)}addSlideAnimation(){this.refreshCount++;const e=this.refreshCount;this.ePrevious&&this.getGui().removeChild(this.ePrevious);const t=document.createElement("span");t.setAttribute("class","ag-value-slide-previous ag-value-slide-out"),this.ePrevious=t,this.ePrevious.textContent=this.eCurrent.textContent,this.getGui().insertBefore(this.ePrevious,this.eCurrent),this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>{e===this.refreshCount&&this.ePrevious.classList.add("ag-value-slide-out-end")},50),window.setTimeout(()=>{e===this.refreshCount&&(this.getGui().removeChild(this.ePrevious),this.ePrevious=null)},3e3)})}refresh(e,t=!1){let i=e.value;return y(i)&&(i=""),i!==this.lastValue&&!this.filterManager.isSuppressFlashingCellsBecauseFiltering()&&(t||this.addSlideAnimation(),this.lastValue=i,C(e.valueFormatted)?this.eCurrent.textContent=e.valueFormatted:C(e.value)?this.eCurrent.textContent=i:Cr(this.eCurrent),!0)}};g([ue("filterManager")],Ds.prototype,"filterManager",2);var Is=class e{constructor(t){this.rowIndex=null,this.key=null,this.childrenMapped={},this.displayed=!1,this.rowTop=null,this.oldRowTop=null,this.selectable=!0,this.__objectId=e.OBJECT_ID_SEQUENCE++,this.__autoHeights={},this.alreadyRendered=!1,this.highlighted=null,this.hovered=!1,this.selected=!1,this.beans=t}setData(e){this.setDataCommon(e,!1)}updateData(e){this.setDataCommon(e,!0)}setDataCommon(e,t){const i=this.data;this.data=e,this.beans.valueCache.onDataChanged(),this.updateDataOnDetailNode(),this.checkRowSelectable(),this.resetQuickFilterAggregateText();const r=this.createDataChangedEvent(e,i,t);this.dispatchLocalEvent(r)}updateDataOnDetailNode(){this.detailNode&&(this.detailNode.data=this.data)}createDataChangedEvent(t,i,r){return{type:e.EVENT_DATA_CHANGED,node:this,oldData:i,newData:t,update:r}}createLocalRowEvent(e){return{type:e,node:this}}getRowIndexString(){return"top"===this.rowPinned?"t-"+this.rowIndex:"bottom"===this.rowPinned?"b-"+this.rowIndex:this.rowIndex.toString()}createDaemonNode(){const t=new e(this.beans);return t.id=this.id,t.data=this.data,t.__daemon=!0,t.selected=this.selected,t.level=this.level,t}setDataAndId(e,t){const i=C(this.id)?this.createDaemonNode():null,r=this.data;this.data=e,this.updateDataOnDetailNode(),this.setId(t),this.checkRowSelectable(),this.beans.selectionService.syncInRowNode(this,i);const n=this.createDataChangedEvent(e,r,!1);this.dispatchLocalEvent(n)}checkRowSelectable(){const e=this.beans.gos.get("isRowSelectable");this.setRowSelectable(!e||e(this))}setRowSelectable(t,i){if(this.selectable!==t){if(this.selectable=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_SELECTABLE_CHANGED)),i)return;if(this.beans.gos.get("groupSelectsChildren")){const e=this.calculateSelectedFromChildren();return void this.setSelectedParams({newValue:null!=e&&e,source:"selectableChanged"})}this.isSelected()&&!this.selectable&&this.setSelectedParams({newValue:!1,source:"selectableChanged"})}}setId(t){const i=this.beans.gos.getCallback("getRowId");if(i)if(this.data){const t=this.getGroupKeys(!0);this.id=i({data:this.data,parentKeys:t.length>0?t:void 0,level:this.level}),null!==this.id&&"string"==typeof this.id&&this.id.startsWith(e.ID_PREFIX_ROW_GROUP)&&console.error(`AG Grid: Row IDs cannot start with ${e.ID_PREFIX_ROW_GROUP}, this is a reserved prefix for AG Grid's row grouping feature.`),null!==this.id&&"string"!=typeof this.id&&(this.id=""+this.id)}else this.id=void 0;else this.id=t}getGroupKeys(e=!1){const t=[];let i=this;for(e&&(i=i.parent);i&&i.level>=0;)t.push(i.key),i=i.parent;return t.reverse(),t}isPixelInRange(e){return!(!C(this.rowTop)||!C(this.rowHeight))&&e>=this.rowTop&&e<this.rowTop+this.rowHeight}setFirstChild(t){this.firstChild!==t&&(this.firstChild=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_FIRST_CHILD_CHANGED)))}setLastChild(t){this.lastChild!==t&&(this.lastChild=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_LAST_CHILD_CHANGED)))}setChildIndex(t){this.childIndex!==t&&(this.childIndex=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_CHILD_INDEX_CHANGED)))}setRowTop(t){this.oldRowTop=this.rowTop,this.rowTop!==t&&(this.rowTop=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_TOP_CHANGED)),this.setDisplayed(null!==t))}clearRowTopAndRowIndex(){this.oldRowTop=null,this.setRowTop(null),this.setRowIndex(null)}setDisplayed(t){this.displayed!==t&&(this.displayed=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_DISPLAYED_CHANGED)))}setDragging(t){this.dragging!==t&&(this.dragging=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_DRAGGING_CHANGED)))}setHighlighted(t){t!==this.highlighted&&(this.highlighted=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HIGHLIGHT_CHANGED)))}setHovered(e){this.hovered!==e&&(this.hovered=e)}isHovered(){return this.hovered}setAllChildrenCount(t){this.allChildrenCount!==t&&(this.allChildrenCount=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_ALL_CHILDREN_COUNT_CHANGED)))}setMaster(t){this.master!==t&&(this.master&&!t&&(this.expanded=!1),this.master=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_MASTER_CHANGED)))}setGroup(t){this.group!==t&&(this.group&&!t&&(this.expanded=!1),this.group=t,this.updateHasChildren(),this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_GROUP_CHANGED)))}setRowHeight(t,i=!1){this.rowHeight=t,this.rowHeightEstimated=i,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HEIGHT_CHANGED))}setRowAutoHeight(e,t){this.__autoHeights||(this.__autoHeights={}),this.__autoHeights[t.getId()]=e,null!=e&&(null==this.checkAutoHeightsDebounced&&(this.checkAutoHeightsDebounced=X(this.checkAutoHeights.bind(this),1)),this.checkAutoHeightsDebounced())}checkAutoHeights(){let e=!1,t=!0,i=0;const r=this.__autoHeights;if(null==r)return;if(this.beans.columnModel.getAllDisplayedAutoHeightCols().forEach(n=>{let s=r[n.getId()];if(null==s){if(!this.beans.columnModel.isColSpanActive())return void(e=!0);{let t=[];switch(n.getPinned()){case"left":t=this.beans.columnModel.getDisplayedLeftColumnsForRow(this);break;case"right":t=this.beans.columnModel.getDisplayedRightColumnsForRow(this);break;case null:t=this.beans.columnModel.getViewportCenterColumnsForRow(this)}if(t.includes(n))return void(e=!0);s=-1}}else t=!1;s>i&&(i=s)}),e)return;if((t||i<10)&&(i=this.beans.gos.getRowHeightForNode(this).height),i==this.rowHeight)return;this.setRowHeight(i);const n=this.beans.rowModel;n.onRowHeightChangedDebounced&&n.onRowHeightChangedDebounced()}setRowIndex(t){this.rowIndex!==t&&(this.rowIndex=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_ROW_INDEX_CHANGED)))}setUiLevel(t){this.uiLevel!==t&&(this.uiLevel=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_UI_LEVEL_CHANGED)))}setExpanded(t,i,r){if(this.expanded===t)return;this.expanded=t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_EXPANDED_CHANGED));const n=Object.assign({},this.createGlobalRowEvent(lt.EVENT_ROW_GROUP_OPENED),{expanded:t,event:i||null});this.beans.rowNodeEventThrottle.dispatchExpanded(n,r),this.beans.rowRenderer.refreshCells({rowNodes:[this]})}createGlobalRowEvent(e){return this.beans.gos.addGridCommonParams({type:e,node:this,data:this.data,rowIndex:this.rowIndex,rowPinned:this.rowPinned})}dispatchLocalEvent(e){this.eventService&&this.eventService.dispatchEvent(e)}setDataValue(e,t,i){const r=(()=>{var t;return"string"!=typeof e?e:null!=(t=this.beans.columnModel.getGridColumn(e))?t:this.beans.columnModel.getPrimaryColumn(e)})(),n=this.getValueFromValueService(r);if(this.beans.gos.get("readOnlyEdit"))return this.dispatchEventForSaveValueReadOnly(r,n,t,i),!1;const s=this.beans.valueService.setValue(this,r,t,i);return this.dispatchCellChangedEvent(r,t,n),this.checkRowSelectable(),s}getValueFromValueService(e){var t,i;const r=this.leafGroup&&this.beans.columnModel.isPivotMode(),n=this.group&&this.expanded&&!this.footer&&!r;let s=!1;const o=null!=(t=this.beans.gos.get("groupTotalRow"))?t:this.beans.gos.get("groupIncludeFooter");s="function"!=typeof o?!!o:!!(null!=(i=this.beans.gos.getCallback("groupTotalRow"))?i:this.beans.gos.getCallback("groupIncludeFooter"))({node:this});const a=this.beans.gos.get("groupSuppressBlankHeader"),l=n&&s&&!a;return this.beans.valueService.getValue(e,this,!1,l)}dispatchEventForSaveValueReadOnly(e,t,i,r){const n=this.beans.gos.addGridCommonParams({type:lt.EVENT_CELL_EDIT_REQUEST,event:null,rowIndex:this.rowIndex,rowPinned:this.rowPinned,column:e,colDef:e.getColDef(),data:this.data,node:this,oldValue:t,newValue:i,value:i,source:r});this.beans.eventService.dispatchEvent(n)}setGroupValue(e,t){const i=this.beans.columnModel.getGridColumn(e);y(this.groupData)&&(this.groupData={});const r=i.getColId(),n=this.groupData[r];n!==t&&(this.groupData[r]=t,this.dispatchCellChangedEvent(i,t,n))}setAggData(e){const t=this.aggData;if(this.aggData=e,this.eventService){const i=e=>{const i=this.aggData?this.aggData[e]:void 0,r=t?t[e]:void 0;if(i===r)return;const n=this.beans.columnModel.lookupGridColumn(e);n&&this.dispatchCellChangedEvent(n,i,r)};for(const e in this.aggData)i(e);for(const t in e)t in this.aggData||i(t)}}updateHasChildren(){let t=this.group&&!this.footer||this.childrenAfterGroup&&this.childrenAfterGroup.length>0;if(this.beans.gos.isRowModelType("serverSide")){const e=this.beans.gos.get("treeData"),i=this.beans.gos.get("isServerSideGroup");t=!this.stub&&!this.footer&&(e?!!i&&i(this.data):!!this.group)}t!==this.__hasChildren&&(this.__hasChildren=!!t,this.eventService&&this.eventService.dispatchEvent(this.createLocalRowEvent(e.EVENT_HAS_CHILDREN_CHANGED)))}hasChildren(){return null==this.__hasChildren&&this.updateHasChildren(),this.__hasChildren}isEmptyRowGroupNode(){return this.group&&w(this.childrenAfterGroup)}dispatchCellChangedEvent(t,i,r){const n={type:e.EVENT_CELL_CHANGED,node:this,column:t,newValue:i,oldValue:r};this.dispatchLocalEvent(n)}resetQuickFilterAggregateText(){this.quickFilterAggregateText=null}isExpandable(){return!this.footer&&(this.beans.columnModel.isPivotMode()?this.hasChildren()&&!this.leafGroup:this.hasChildren()||!!this.master)}isSelected(){return this.footer?this.sibling.isSelected():this.selected}depthFirstSearch(e){this.childrenAfterGroup&&this.childrenAfterGroup.forEach(t=>t.depthFirstSearch(e)),e(this)}calculateSelectedFromChildren(){var e;let t=!1,i=!1,r=!1;if(!(null==(e=this.childrenAfterGroup)?void 0:e.length))return this.selectable?this.selected:null;for(let e=0;e<this.childrenAfterGroup.length;e++){const n=this.childrenAfterGroup[e];let s=n.isSelected();if(!n.selectable){const e=n.calculateSelectedFromChildren();if(null===e)continue;s=e}switch(s){case!0:t=!0;break;case!1:i=!0;break;default:r=!0}}return r||t&&i?void 0:!!t||!i&&(this.selectable?this.selected:null)}setSelectedInitialValue(e){this.selected=e}selectThisNode(t,i,r="api"){const n=!this.selectable&&t,s=this.selected===t;if(n||s)return!1;this.selected=t,this.eventService&&this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_ROW_SELECTED));const o=this.sibling;o&&o.footer&&o.eventService&&o.dispatchLocalEvent(o.createLocalRowEvent(e.EVENT_ROW_SELECTED));const a=d(h({},this.createGlobalRowEvent(lt.EVENT_ROW_SELECTED)),{event:i||null,source:r});return this.beans.eventService.dispatchEvent(a),!0}setSelected(e,t=!1,i="api"){"boolean"!=typeof i?this.setSelectedParams({newValue:e,clearSelection:t,rangeSelect:!1,source:i}):console.warn("AG Grid: since version v30, rowNode.setSelected() property `suppressFinishActions` has been removed, please use `gridApi.setNodesSelected()` for bulk actions, and the event `source` property for ignoring events instead.")}setSelectedParams(e){return this.rowPinned?(console.warn("AG Grid: cannot select pinned rows"),0):void 0===this.id?(console.warn("AG Grid: cannot select node until id for node is known"),0):this.beans.selectionService.setNodesSelected(d(h({},e),{nodes:[this.footer?this.sibling:this]}))}isRowPinned(){return"top"===this.rowPinned||"bottom"===this.rowPinned}isParentOfNode(e){let t=this.parent;for(;t;){if(t===e)return!0;t=t.parent}return!1}addEventListener(e,t){var i,r;this.eventService||(this.eventService=new fe),this.beans.frameworkOverrides.shouldWrapOutgoing&&!this.frameworkEventListenerService&&(this.eventService.setFrameworkOverrides(this.beans.frameworkOverrides),this.frameworkEventListenerService=new me(this.beans.frameworkOverrides));const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.wrap(t))?r:t;this.eventService.addEventListener(e,n)}removeEventListener(e,t){var i,r;if(!this.eventService)return;const n=null!=(r=null==(i=this.frameworkEventListenerService)?void 0:i.unwrap(t))?r:t;this.eventService.removeEventListener(e,n),this.eventService.noRegisteredListenersExist()&&(this.eventService=null)}onMouseEnter(){this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_MOUSE_ENTER))}onMouseLeave(){this.dispatchLocalEvent(this.createLocalRowEvent(e.EVENT_MOUSE_LEAVE))}getFirstChildOfFirstChild(e){let t=this,i=!0,r=!1,n=null;for(;i&&!r;){const s=t.parent;C(s)&&t.firstChild?s.rowGroupColumn===e&&(r=!0,n=s):i=!1,t=s}return r?n:null}isFullWidthCell(){if(this.detail)return!0;const e=this.beans.gos.getCallback("isFullWidthRow");return!!e&&e({rowNode:this})}getRoute(){if(null==this.key)return;const e=[];let t=this;for(;null!=t.key;)e.push(t.key),t=t.parent;return e.reverse()}createFooter(){if(this.sibling)return;const t=new Set(["eventService","__objectId","sticky"]),i=new e(this.beans);Object.keys(this).forEach(e=>{t.has(e)||(i[e]=this[e])}),i.footer=!0,i.setRowTop(null),i.setRowIndex(null),i.oldRowTop=null,i.id="rowGroupFooter_"+this.id,i.sibling=this,this.sibling=i}destroyFooter(){this.sibling&&(this.sibling.setRowTop(null),this.sibling.setRowIndex(null),this.sibling=void 0)}};Is.ID_PREFIX_ROW_GROUP="row-group-",Is.ID_PREFIX_TOP_PINNED="t-",Is.ID_PREFIX_BOTTOM_PINNED="b-",Is.OBJECT_ID_SEQUENCE=0,Is.EVENT_ROW_SELECTED="rowSelected",Is.EVENT_DATA_CHANGED="dataChanged",Is.EVENT_CELL_CHANGED="cellChanged",Is.EVENT_ALL_CHILDREN_COUNT_CHANGED="allChildrenCountChanged",Is.EVENT_MASTER_CHANGED="masterChanged",Is.EVENT_GROUP_CHANGED="groupChanged",Is.EVENT_MOUSE_ENTER="mouseEnter",Is.EVENT_MOUSE_LEAVE="mouseLeave",Is.EVENT_HEIGHT_CHANGED="heightChanged",Is.EVENT_TOP_CHANGED="topChanged",Is.EVENT_DISPLAYED_CHANGED="displayedChanged",Is.EVENT_FIRST_CHILD_CHANGED="firstChildChanged",Is.EVENT_LAST_CHILD_CHANGED="lastChildChanged",Is.EVENT_CHILD_INDEX_CHANGED="childIndexChanged",Is.EVENT_ROW_INDEX_CHANGED="rowIndexChanged",Is.EVENT_EXPANDED_CHANGED="expandedChanged",Is.EVENT_HAS_CHILDREN_CHANGED="hasChildrenChanged",Is.EVENT_SELECTABLE_CHANGED="selectableChanged",Is.EVENT_UI_LEVEL_CHANGED="uiLevelChanged",Is.EVENT_HIGHLIGHT_CHANGED="rowHighlightChanged",Is.EVENT_DRAGGING_CHANGED="draggingChanged";var Ls=Is,Ns=class extends yn{constructor(){super('\n            <div class="ag-selection-checkbox" role="presentation">\n                <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n            </div>')}postConstruct(){this.eCheckbox.setPassive(!0)}getCheckboxId(){return this.eCheckbox.getInputElement().id}onDataChanged(){this.onSelectionChanged()}onSelectableChanged(){this.showOrHideSelect()}onSelectionChanged(){const e=this.localeService.getLocaleTextFunc(),t=this.rowNode.isSelected(),i=mi(e,t),[r,n]=this.rowNode.selectable?["ariaRowToggleSelection","Press Space to toggle row selection"]:["ariaRowSelectionDisabled","Row Selection is disabled for this row"],s=e(r,n);this.eCheckbox.setValue(t,!0),this.eCheckbox.setInputAriaLabel(`${s} (${i})`)}onClicked(e,t,i){return this.rowNode.setSelectedParams({newValue:e,rangeSelect:i.shiftKey,groupSelectsFiltered:t,event:i,source:"checkboxSelected"})}init(e){if(this.rowNode=e.rowNode,this.column=e.column,this.overrides=e.overrides,this.onSelectionChanged(),this.addManagedListener(this.eCheckbox.getInputElement(),"dblclick",e=>{qe(e)}),this.addManagedListener(this.eCheckbox.getInputElement(),"click",e=>{qe(e);const t=this.gos.get("groupSelectsFiltered"),i=this.eCheckbox.getValue();this.shouldHandleIndeterminateState(i,t)?0===this.onClicked(!0,t,e||{})&&this.onClicked(!1,t,e):i?this.onClicked(!1,t,e):this.onClicked(!0,t,e||{})}),this.addManagedListener(this.rowNode,Ls.EVENT_ROW_SELECTED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_DATA_CHANGED,this.onDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_SELECTABLE_CHANGED,this.onSelectableChanged.bind(this)),this.gos.get("isRowSelectable")||"function"==typeof this.getIsVisible()){const e=this.showOrHideSelect.bind(this);this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.rowNode,Ls.EVENT_DATA_CHANGED,e),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,e),this.showOrHideSelect()}this.eCheckbox.getInputElement().setAttribute("tabindex","-1")}shouldHandleIndeterminateState(e,t){return t&&(void 0===this.eCheckbox.getPreviousValue()||void 0===e)&&this.gos.isRowModelType("clientSide")}showOrHideSelect(){var e,t,i;let r=this.rowNode.selectable;const n=this.getIsVisible();if(r)if("function"==typeof n){const t=null==(e=this.overrides)?void 0:e.callbackParams;if(this.column){const e=this.column.createColumnFunctionCallbackParams(this.rowNode);r=n(h(h({},t),e))}else r=n(d(h({},t),{node:this.rowNode,data:this.rowNode.data}))}else r=null!=n&&n;if(null==(t=this.column)?void 0:t.getColDef().showDisabledCheckboxes)return this.eCheckbox.setDisabled(!r),this.setVisible(!0),void this.setDisplayed(!0);(null==(i=this.overrides)?void 0:i.removeHidden)?this.setDisplayed(r):this.setVisible(r)}getIsVisible(){var e,t;return this.overrides?this.overrides.isVisible:null==(t=null==(e=this.column)?void 0:e.getColDef())?void 0:t.checkboxSelection}};g([Sn("eCheckbox")],Ns.prototype,"eCheckbox",2),g([ae],Ns.prototype,"postConstruct",1);var Os=(e=>(e[e.Up=0]="Up",e[e.Down=1]="Down",e))(Os||{}),Fs=(e=>(e[e.Left=0]="Left",e[e.Right=1]="Right",e))(Fs||{}),ks=(e=>(e[e.ToolPanel=0]="ToolPanel",e[e.HeaderCell=1]="HeaderCell",e[e.RowDrag=2]="RowDrag",e[e.ChartPanel=3]="ChartPanel",e[e.AdvancedFilterBuilder=4]="AdvancedFilterBuilder",e))(ks||{}),Gs=class extends rt{constructor(){super(...arguments),this.dragSourceAndParamsList=[],this.dropTargets=[]}init(){this.ePinnedIcon=Kr("columnMovePin",this.gos,null),this.eHideIcon=Kr("columnMoveHide",this.gos,null),this.eMoveIcon=Kr("columnMoveMove",this.gos,null),this.eLeftIcon=Kr("columnMoveLeft",this.gos,null),this.eRightIcon=Kr("columnMoveRight",this.gos,null),this.eGroupIcon=Kr("columnMoveGroup",this.gos,null),this.eAggregateIcon=Kr("columnMoveValue",this.gos,null),this.ePivotIcon=Kr("columnMovePivot",this.gos,null),this.eDropNotAllowedIcon=Kr("dropNotAllowed",this.gos,null)}addDragSource(e,t=!1){const i={eElement:e.eElement,dragStartPixels:e.dragStartPixels,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this),onDragging:this.onDragging.bind(this),includeTouch:t};this.dragSourceAndParamsList.push({params:i,dragSource:e}),this.dragService.addDragSource(i)}removeDragSource(e){const t=this.dragSourceAndParamsList.find(t=>t.dragSource===e);t&&(this.dragService.removeDragSource(t.params),Ne(this.dragSourceAndParamsList,t))}clearDragSourceParamsList(){this.dragSourceAndParamsList.forEach(e=>this.dragService.removeDragSource(e.params)),this.dragSourceAndParamsList.length=0,this.dropTargets.length=0}nudge(){this.dragging&&this.onDragging(this.eventLastTime,!0)}onDragStart(e,t){this.dragging=!0,this.dragSource=e,this.eventLastTime=t,this.dragItem=this.dragSource.getDragItem(),this.lastDropTarget=void 0,this.dragSource.onDragStarted&&this.dragSource.onDragStarted(),this.createGhost()}onDragStop(e){if(this.eventLastTime=null,this.dragging=!1,this.dragSource.onDragStopped&&this.dragSource.onDragStopped(),this.lastDropTarget&&this.lastDropTarget.onDragStop){const t=this.createDropTargetEvent(this.lastDropTarget,e,null,null,!1);this.lastDropTarget.onDragStop(t)}this.lastDropTarget=null,this.dragItem=null,this.removeGhost()}onDragging(e,t){var i,r,n,s;const o=this.getHorizontalDirection(e),a=this.getVerticalDirection(e);this.eventLastTime=e,this.positionGhost(e);const l=this.dropTargets.filter(t=>this.isMouseOnDropTarget(e,t)),c=this.findCurrentDropTarget(e,l);if(c!==this.lastDropTarget)this.leaveLastTargetIfExists(e,o,a,t),null!==this.lastDropTarget&&null===c&&(null==(r=(i=this.dragSource).onGridExit)||r.call(i,this.dragItem)),null===this.lastDropTarget&&null!==c&&(null==(s=(n=this.dragSource).onGridEnter)||s.call(n,this.dragItem)),this.enterDragTargetIfExists(c,e,o,a,t),this.lastDropTarget=c;else if(c&&c.onDragging){const i=this.createDropTargetEvent(c,e,o,a,t);c.onDragging(i)}}getAllContainersFromDropTarget(e){const t=e.getSecondaryContainers?e.getSecondaryContainers():null,i=[[e.getContainer()]];return t?i.concat(t):i}allContainersIntersect(e,t){for(const i of t){const t=i.getBoundingClientRect();if(0===t.width||0===t.height)return!1;const r=e.clientX>=t.left&&e.clientX<t.right,n=e.clientY>=t.top&&e.clientY<t.bottom;if(!r||!n)return!1}return!0}isMouseOnDropTarget(e,t){const i=this.getAllContainersFromDropTarget(t);let r=!1;for(const t of i)if(this.allContainersIntersect(e,t)){r=!0;break}return!(t.targetContainsSource&&!t.getContainer().contains(this.dragSource.eElement))&&r&&t.isInterestedIn(this.dragSource.type,this.dragSource.eElement)}findCurrentDropTarget(e,t){const i=t.length;if(0===i)return null;if(1===i)return t[0];const r=this.gos.getRootNode().elementsFromPoint(e.clientX,e.clientY);for(const e of r)for(const i of t)if(-1!==Be(this.getAllContainersFromDropTarget(i)).indexOf(e))return i;return null}enterDragTargetIfExists(e,t,i,r,n){if(e){if(e.onDragEnter){const s=this.createDropTargetEvent(e,t,i,r,n);e.onDragEnter(s)}this.setGhostIcon(e.getIconName?e.getIconName():null)}}leaveLastTargetIfExists(e,t,i,r){if(this.lastDropTarget){if(this.lastDropTarget.onDragLeave){const n=this.createDropTargetEvent(this.lastDropTarget,e,t,i,r);this.lastDropTarget.onDragLeave(n)}this.setGhostIcon(null)}}addDropTarget(e){this.dropTargets.push(e)}removeDropTarget(e){this.dropTargets=this.dropTargets.filter(t=>t.getContainer()!==e.getContainer())}hasExternalDropZones(){return this.dropTargets.some(e=>e.external)}findExternalZone(e){return this.dropTargets.filter(e=>e.external).find(t=>t.getContainer()===e.getContainer())||null}getHorizontalDirection(e){const t=this.eventLastTime&&this.eventLastTime.clientX,i=e.clientX;return t===i?null:t>i?0:1}getVerticalDirection(e){const t=this.eventLastTime&&this.eventLastTime.clientY,i=e.clientY;return t===i?null:t>i?0:1}createDropTargetEvent(e,t,i,r,n){const s=e.getContainer(),o=s.getBoundingClientRect(),{gridApi:a,columnApi:l,dragItem:c,dragSource:u}=this;return{event:t,x:t.clientX-o.left,y:t.clientY-o.top,vDirection:r,hDirection:i,dragSource:u,fromNudge:n,dragItem:c,api:a,columnApi:l,dropZoneTarget:s}}positionGhost(e){const t=this.eGhost;if(!t)return;const i=t.getBoundingClientRect().height,r=Oi()-2,n=Fi()-2,s=gr(t.offsetParent),{clientY:o,clientX:a}=e;let l=o-s.top-i/2,c=a-s.left-10;const u=this.gos.getDocument(),h=u.defaultView||window,d=h.pageYOffset||u.documentElement.scrollTop,p=h.pageXOffset||u.documentElement.scrollLeft;r>0&&c+t.clientWidth>r+p&&(c=r+p-t.clientWidth),c<0&&(c=0),n>0&&l+t.clientHeight>n+d&&(l=n+d-t.clientHeight),l<0&&(l=0),t.style.left=`${c}px`,t.style.top=`${l}px`}removeGhost(){this.eGhost&&this.eGhostParent&&this.eGhostParent.removeChild(this.eGhost),this.eGhost=null}createGhost(){this.eGhost=br(Gs.GHOST_TEMPLATE),this.mouseEventService.stampTopLevelGridCompWithGridInstance(this.eGhost);const{theme:e}=this.environment.getTheme();e&&this.eGhost.classList.add(e),this.eGhostIcon=this.eGhost.querySelector(".ag-dnd-ghost-icon"),this.setGhostIcon(null);const t=this.eGhost.querySelector(".ag-dnd-ghost-label");let i=this.dragSource.dragItemName;j(i)&&(i=i()),t.innerHTML=Ct(i)||"",this.eGhost.style.height="25px",this.eGhost.style.top="20px",this.eGhost.style.left="20px";const r=this.gos.getDocument();let n=null,s=null;try{n=r.fullscreenElement}catch(e){}finally{n||(n=this.gos.getRootNode());s=n.querySelector("body")||(n instanceof ShadowRoot?n:n instanceof Document?null==n?void 0:n.documentElement:n)}this.eGhostParent=s,this.eGhostParent?this.eGhostParent.appendChild(this.eGhost):console.warn("AG Grid: could not find document body, it is needed for dragging columns")}setGhostIcon(e,t=!1){Cr(this.eGhostIcon);let i=null;switch(e||(e=this.dragSource.getDefaultIconName?this.dragSource.getDefaultIconName():Gs.ICON_NOT_ALLOWED),e){case Gs.ICON_PINNED:i=this.ePinnedIcon;break;case Gs.ICON_MOVE:i=this.eMoveIcon;break;case Gs.ICON_LEFT:i=this.eLeftIcon;break;case Gs.ICON_RIGHT:i=this.eRightIcon;break;case Gs.ICON_GROUP:i=this.eGroupIcon;break;case Gs.ICON_AGGREGATE:i=this.eAggregateIcon;break;case Gs.ICON_PIVOT:i=this.ePivotIcon;break;case Gs.ICON_NOT_ALLOWED:i=this.eDropNotAllowedIcon;break;case Gs.ICON_HIDE:i=this.eHideIcon}this.eGhostIcon.classList.toggle("ag-shake-left-to-right",t),i===this.eHideIcon&&this.gos.get("suppressDragLeaveHidesColumns")||i&&this.eGhostIcon.appendChild(i)}};Gs.ICON_PINNED="pinned",Gs.ICON_MOVE="move",Gs.ICON_LEFT="left",Gs.ICON_RIGHT="right",Gs.ICON_GROUP="group",Gs.ICON_AGGREGATE="aggregate",Gs.ICON_PIVOT="pivot",Gs.ICON_NOT_ALLOWED="notAllowed",Gs.ICON_HIDE="hide",Gs.GHOST_TEMPLATE='<div class="ag-dnd-ghost ag-unselectable">\n            <span class="ag-dnd-ghost-icon ag-shake-left-to-right"></span>\n            <div class="ag-dnd-ghost-label"></div>\n        </div>',g([ue("dragService")],Gs.prototype,"dragService",2),g([ue("mouseEventService")],Gs.prototype,"mouseEventService",2),g([ue("columnApi")],Gs.prototype,"columnApi",2),g([ue("gridApi")],Gs.prototype,"gridApi",2),g([ae],Gs.prototype,"init",1),g([le],Gs.prototype,"clearDragSourceParamsList",1),Gs=g([ce("dragAndDropService")],Gs);var Vs=class extends yn{constructor(e,t,i,r,n,s){super(),this.cellValueFn=e,this.rowNode=t,this.column=i,this.customGui=r,this.dragStartPixels=n,this.suppressVisibilityChange=s,this.dragSource=null}isCustomGui(){return null!=this.customGui}postConstruct(){if(this.customGui?this.setDragElement(this.customGui,this.dragStartPixels):(this.setTemplate('<div class="ag-drag-handle ag-row-drag" aria-hidden="true"></div>'),this.getGui().appendChild($r("rowDrag",this.gos,null)),this.addDragSource()),this.checkCompatibility(),!this.suppressVisibilityChange){const e=this.gos.get("rowDragManaged")?new zs(this,this.beans,this.rowNode,this.column):new Bs(this,this.beans,this.rowNode,this.column);this.createManagedBean(e,this.beans.context)}}setDragElement(e,t){this.setTemplateFromElement(e),this.addDragSource(t)}getSelectedNodes(){if(!this.gos.get("rowDragMultiRow"))return[this.rowNode];const e=this.beans.selectionService.getSelectedNodes();return-1!==e.indexOf(this.rowNode)?e:[this.rowNode]}checkCompatibility(){const e=this.gos.get("rowDragManaged");this.gos.get("treeData")&&e&&z("If using row drag with tree data, you cannot have rowDragManaged=true")}getDragItem(){return{rowNode:this.rowNode,rowNodes:this.getSelectedNodes(),columns:this.column?[this.column]:void 0,defaultTextValue:this.cellValueFn()}}getRowDragText(e){if(e){const t=e.getColDef();if(t.rowDragText)return t.rowDragText}return this.gos.get("rowDragText")}addDragSource(e=4){this.dragSource&&this.removeDragSource();const t=this.localeService.getLocaleTextFunc();this.dragSource={type:2,eElement:this.getGui(),dragItemName:()=>{var e;const i=this.getDragItem(),r=(null==(e=i.rowNodes)?void 0:e.length)||1,n=this.getRowDragText(this.column);return n?n(i,r):1===r?this.cellValueFn():`${r} ${t("rowDragRows","rows")}`},getDragItem:()=>this.getDragItem(),dragStartPixels:e,dragSourceDomDataKey:this.gos.getDomDataKey()},this.beans.dragAndDropService.addDragSource(this.dragSource,!0)}removeDragSource(){this.dragSource&&this.beans.dragAndDropService.removeDragSource(this.dragSource),this.dragSource=null}};g([ue("beans")],Vs.prototype,"beans",2),g([ae],Vs.prototype,"postConstruct",1),g([le],Vs.prototype,"removeDragSource",1);var Hs=class extends rt{constructor(e,t,i){super(),this.parent=e,this.rowNode=t,this.column=i}setDisplayedOrVisible(e){const t={skipAriaHidden:!0};if(e)this.parent.setDisplayed(!1,t);else{let e=!0,i=!1;this.column&&(e=this.column.isRowDrag(this.rowNode)||this.parent.isCustomGui(),i=j(this.column.getColDef().rowDrag)),i?(this.parent.setDisplayed(!0,t),this.parent.setVisible(e,t)):(this.parent.setDisplayed(e,t),this.parent.setVisible(!0,t))}}},Bs=class extends Hs{constructor(e,t,i,r){super(e,i,r),this.beans=t}postConstruct(){this.addManagedPropertyListener("suppressRowDrag",this.onSuppressRowDrag.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_DATA_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.workOutVisibility.bind(this)),this.workOutVisibility()}onSuppressRowDrag(){this.workOutVisibility()}workOutVisibility(){const e=this.gos.get("suppressRowDrag");this.setDisplayedOrVisible(e)}};g([ae],Bs.prototype,"postConstruct",1);var zs=class extends Hs{constructor(e,t,i,r){super(e,i,r),this.beans=t}postConstruct(){this.addManagedListener(this.beans.eventService,lt.EVENT_SORT_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,lt.EVENT_FILTER_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.beans.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_DATA_CHANGED,this.workOutVisibility.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,this.workOutVisibility.bind(this)),this.addManagedPropertyListener("suppressRowDrag",this.onSuppressRowDrag.bind(this)),this.workOutVisibility()}onSuppressRowDrag(){this.workOutVisibility()}workOutVisibility(){const e=this.beans.ctrlsService.getGridBodyCtrl().getRowDragFeature(),t=e&&e.shouldPreventRowMove(),i=this.gos.get("suppressRowDrag"),r=this.beans.dragAndDropService.hasExternalDropZones(),n=t&&!r||i;this.setDisplayedOrVisible(n)}};g([ae],zs.prototype,"postConstruct",1);var Us=class extends rt{init(e,t,i,r,n,s,o){var a,l,c,u;this.params=o,this.eGui=t,this.eCheckbox=i,this.eExpanded=r,this.eContracted=n,this.comp=e,this.compClass=s;const{node:h,value:d,colDef:p}=o,g=this.isTopLevelFooter();if(!g){if(this.isEmbeddedRowMismatch())return;if(h.footer&&this.gos.get("groupHideOpenParents")&&(p&&p.showRowGroup)!==(h.rowGroupColumn&&h.rowGroupColumn.getColId()))return}if(this.setupShowingValueForOpenedParent(),this.findDisplayedGroupNode(),!g){const e=o.node.footer&&o.node.rowGroupIndex===this.columnModel.getRowGroupColumns().findIndex(e=>{var t;return e.getColId()===(null==(t=o.colDef)?void 0:t.showRowGroup)}),t="multipleColumns"!=this.gos.get("groupDisplayType")||this.gos.get("treeData")||this.gos.get("showOpenedGroup")&&!o.node.footer&&(!o.node.group||null!=o.node.rowGroupIndex&&o.node.rowGroupIndex>this.columnModel.getRowGroupColumns().findIndex(e=>{var t;return e.getColId()===(null==(t=o.colDef)?void 0:t.showRowGroup)})),i=!h.group&&((null==(a=this.params.colDef)?void 0:a.field)||(null==(l=this.params.colDef)?void 0:l.valueGetter)),r=this.isExpandable(),n=this.columnModel.isPivotMode()&&h.leafGroup&&(null==(c=h.rowGroupColumn)?void 0:c.getColId())===(null==(u=o.column)?void 0:u.getColDef().showRowGroup);if(!(this.showingValueForOpenedParent||r||i||t||e||n))return}this.addExpandAndContract(),this.addFullWidthRowDraggerIfNeeded(),this.addCheckboxIfNeeded(),this.addValueElement(),this.setupIndent(),this.refreshAriaExpanded()}getCellAriaRole(){var e,t;const i=null==(e=this.params.colDef)?void 0:e.cellAriaRole,r=null==(t=this.params.column)?void 0:t.getColDef().cellAriaRole;return i||r||"gridcell"}destroy(){super.destroy(),this.expandListener=null}refreshAriaExpanded(){const{node:e,eGridCell:t}=this.params;if(this.expandListener&&(this.expandListener=this.expandListener()),!this.isExpandable())return void ii(t);const i=()=>{ti(t,!!e.expanded)};this.expandListener=this.addManagedListener(e,Ls.EVENT_EXPANDED_CHANGED,i)||null,i()}isTopLevelFooter(){if(!this.gos.getGrandTotalRow())return!1;if(null!=this.params.value||-1!=this.params.node.level)return!1;const e=this.params.colDef;if(null==e)return!0;if(!0===e.showRowGroup)return!0;const t=this.columnModel.getRowGroupColumns();return!t||0===t.length||t[0].getId()===e.showRowGroup}isEmbeddedRowMismatch(){if(!this.params.fullWidth||!this.gos.get("embedFullWidthRows"))return!1;const e="left"===this.params.pinned,t="right"===this.params.pinned,i=!e&&!t;return this.gos.get("enableRtl")?this.columnModel.isPinningLeft()?!t:!i:this.columnModel.isPinningLeft()?!e:!i}findDisplayedGroupNode(){const e=this.params.column,t=this.params.node;if(this.showingValueForOpenedParent){let i=t.parent;for(;null!=i;){if(i.rowGroupColumn&&e.isRowGroupDisplayed(i.rowGroupColumn.getId())){this.displayedGroupNode=i;break}i=i.parent}}y(this.displayedGroupNode)&&(this.displayedGroupNode=t)}setupShowingValueForOpenedParent(){const e=this.params.node,t=this.params.column;if(!this.gos.get("groupHideOpenParents"))return void(this.showingValueForOpenedParent=!1);if(!e.groupData)return void(this.showingValueForOpenedParent=!1);if(null!=e.rowGroupColumn){const i=e.rowGroupColumn.getId();if(t.isRowGroupDisplayed(i))return void(this.showingValueForOpenedParent=!1)}const i=null!=e.groupData[t.getId()];this.showingValueForOpenedParent=i}addValueElement(){this.displayedGroupNode.footer?this.addFooterValue():(this.addGroupValue(),this.addChildCount())}addGroupValue(){var e;const t=this.adjustParamsWithDetailsFromRelatedColumn(),i=this.getInnerCompDetails(t),{valueFormatted:r,value:n}=t;let s=r;if(null==s){const t=this.displayedGroupNode.rowGroupColumn&&(null==(e=this.params.column)?void 0:e.isRowGroupDisplayed(this.displayedGroupNode.rowGroupColumn.getId()));s=""===this.displayedGroupNode.key&&this.displayedGroupNode.group&&t?this.localeService.getLocaleTextFunc()("blanks","(Blanks)"):null!=n?n:null}this.comp.setInnerRenderer(i,s)}adjustParamsWithDetailsFromRelatedColumn(){const e=this.displayedGroupNode.rowGroupColumn,t=this.params.column;if(!e)return this.params;if(null!=t&&!t.isRowGroupDisplayed(e.getId()))return this.params;const i=this.params,{value:r,node:n}=this.params,s=this.valueService.formatValue(e,n,r);return d(h({},i),{valueFormatted:s})}addFooterValue(){let e=this.params.totalValueGetter;if(!e){const t=this.params.footerValueGetter;t&&(e=t,z("As of v31.3, footerValueGetter is deprecated. Use `totalValueGetter` instead."))}let t="";if(e){const i=I(this.params);i.value=this.params.value,"function"==typeof e?t=e(i):"string"==typeof e?t=this.expressionService.evaluate(e,i):console.warn("AG Grid: footerValueGetter should be either a function or a string (expression)")}else t=this.localeService.getLocaleTextFunc()("footerTotal","Total")+" "+(null!=this.params.value?this.params.value:"");const i=this.getInnerCompDetails(this.params);this.comp.setInnerRenderer(i,t)}getInnerCompDetails(e){if(e.fullWidth)return this.userComponentFactory.getFullWidthGroupRowInnerCellRenderer(this.gos.get("groupRowRendererParams"),e);const t=this.userComponentFactory.getInnerRendererDetails(e,e),i=e=>e&&e.componentClass==this.compClass;if(t&&!i(t))return t;const r=this.displayedGroupNode.rowGroupColumn,n=r?r.getColDef():void 0;if(!n)return;const s=this.userComponentFactory.getCellRendererDetails(n,e);return s&&!i(s)?s:i(s)&&n.cellRendererParams&&n.cellRendererParams.innerRenderer?this.userComponentFactory.getInnerRendererDetails(n.cellRendererParams,e):void 0}addChildCount(){this.params.suppressCount||(this.addManagedListener(this.displayedGroupNode,Ls.EVENT_ALL_CHILDREN_COUNT_CHANGED,this.updateChildCount.bind(this)),this.updateChildCount())}updateChildCount(){const e=this.displayedGroupNode.allChildrenCount,t=this.isShowRowGroupForThisRow()&&null!=e&&e>=0?`(${e})`:"";this.comp.setChildCount(t)}isShowRowGroupForThisRow(){if(this.gos.get("treeData"))return!0;const e=this.displayedGroupNode.rowGroupColumn;if(!e)return!1;const t=this.params.column;return null==t||t.isRowGroupDisplayed(e.getId())}addExpandAndContract(){var e;const t=this.params,i=$r("groupExpanded",this.gos,null),r=$r("groupContracted",this.gos,null);i&&this.eExpanded.appendChild(i),r&&this.eContracted.appendChild(r);const n=t.eGridCell;(null==(e=this.params.column)?void 0:e.isCellEditable(t.node))&&this.gos.get("enableGroupEdit")||!this.isExpandable()||t.suppressDoubleClickExpand||this.addManagedListener(n,"dblclick",this.onCellDblClicked.bind(this)),this.addManagedListener(this.eExpanded,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eContracted,"click",this.onExpandClicked.bind(this)),this.addManagedListener(n,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(t.node,Ls.EVENT_EXPANDED_CHANGED,this.showExpandAndContractIcons.bind(this)),this.showExpandAndContractIcons();const s=this.onRowNodeIsExpandableChanged.bind(this);this.addManagedListener(this.displayedGroupNode,Ls.EVENT_ALL_CHILDREN_COUNT_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ls.EVENT_MASTER_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ls.EVENT_GROUP_CHANGED,s),this.addManagedListener(this.displayedGroupNode,Ls.EVENT_HAS_CHILDREN_CHANGED,s)}onExpandClicked(e){Ye(e)||(qe(e),this.onExpandOrContract(e))}onExpandOrContract(e){const t=this.displayedGroupNode,i=!t.expanded;!i&&t.sticky&&this.scrollToStickyNode(t),t.setExpanded(i,e)}scrollToStickyNode(e){this.ctrlsService.getGridBodyCtrl().getScrollFeature().setVerticalScrollPosition(e.rowTop-e.stickyRowTop)}isExpandable(){if(this.showingValueForOpenedParent)return!0;const e=this.displayedGroupNode,t=this.columnModel.isPivotMode()&&e.leafGroup;if(!e.isExpandable()||e.footer||t)return!1;const i=this.params.column;return null==i||"string"!=typeof i.getColDef().showRowGroup||this.isShowRowGroupForThisRow()}showExpandAndContractIcons(){const{params:e,displayedGroupNode:t,columnModel:i}=this,{node:r}=e,n=this.isExpandable();if(n){const e=!!this.showingValueForOpenedParent||r.expanded;this.comp.setExpandedDisplayed(e),this.comp.setContractedDisplayed(!e)}else this.comp.setExpandedDisplayed(!1),this.comp.setContractedDisplayed(!1);const s=i.isPivotMode(),o=s&&t.leafGroup,a=n&&!o,l=r.footer&&-1===r.level;this.comp.addOrRemoveCssClass("ag-cell-expandable",a),this.comp.addOrRemoveCssClass("ag-row-group",a),s?this.comp.addOrRemoveCssClass("ag-pivot-leaf-group",o):l||this.comp.addOrRemoveCssClass("ag-row-group-leaf-indent",!a)}onRowNodeIsExpandableChanged(){this.showExpandAndContractIcons(),this.setIndent(),this.refreshAriaExpanded()}setupIndent(){const e=this.params.node;this.params.suppressPadding||(this.addManagedListener(e,Ls.EVENT_UI_LEVEL_CHANGED,this.setIndent.bind(this)),this.setIndent())}setIndent(){if(this.gos.get("groupHideOpenParents"))return;const e=this.params,t=e.node,i=!!e.colDef,r=this.gos.get("treeData"),n=!i||r||!0===e.colDef.showRowGroup?t.uiLevel:0;this.indentClass&&this.comp.addOrRemoveCssClass(this.indentClass,!1),this.indentClass="ag-row-group-indent-"+n,this.comp.addOrRemoveCssClass(this.indentClass,!0)}addFullWidthRowDraggerIfNeeded(){if(!this.params.fullWidth||!this.params.rowDrag)return;const e=new Vs(()=>this.params.value,this.params.node);this.createManagedBean(e,this.context),this.eGui.insertAdjacentElement("afterbegin",e.getGui())}isUserWantsSelected(){const e=this.params.checkbox;return"function"==typeof e||!0===e}addCheckboxIfNeeded(){const e=this.displayedGroupNode,t=this.isUserWantsSelected()&&!e.footer&&!e.rowPinned&&!e.detail;if(t){const e=new Ns;this.getContext().createBean(e),e.init({rowNode:this.params.node,column:this.params.column,overrides:{isVisible:this.params.checkbox,callbackParams:this.params,removeHidden:!0}}),this.eCheckbox.appendChild(e.getGui()),this.addDestroyFunc(()=>this.getContext().destroyBean(e))}this.comp.setCheckboxVisible(t)}onKeyDown(e){e.key!==Yr.ENTER||this.params.suppressEnterExpand||this.params.column&&this.params.column.isCellEditable(this.params.node)||this.onExpandOrContract(e)}onCellDblClicked(e){Ye(e)||Ze(this.eExpanded,e)||Ze(this.eContracted,e)||this.onExpandOrContract(e)}};g([ue("expressionService")],Us.prototype,"expressionService",2),g([ue("valueService")],Us.prototype,"valueService",2),g([ue("columnModel")],Us.prototype,"columnModel",2),g([ue("userComponentFactory")],Us.prototype,"userComponentFactory",2),g([ue("ctrlsService")],Us.prototype,"ctrlsService",2);var Ws=class e extends yn{constructor(){super(e.TEMPLATE)}init(e){const t={setInnerRenderer:(e,t)=>this.setRenderDetails(e,t),setChildCount:e=>this.eChildCount.textContent=e,addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setContractedDisplayed:e=>sr(this.eContracted,e),setExpandedDisplayed:e=>sr(this.eExpanded,e),setCheckboxVisible:e=>this.eCheckbox.classList.toggle("ag-invisible",!e)},i=this.createManagedBean(new Us),r=!e.colDef,n=this.getGui();i.init(t,n,this.eCheckbox,this.eExpanded,this.eContracted,this.constructor,e),r&&Ht(n,i.getCellAriaRole())}setRenderDetails(e,t){if(e){const t=e.newAgStackInstance();if(!t)return;t.then(e=>{if(!e)return;const t=()=>this.context.destroyBean(e);this.isAlive()?(this.eValue.appendChild(e.getGui()),this.addDestroyFunc(t)):t()})}else this.eValue.innerText=t}destroy(){this.getContext().destroyBean(this.innerCellRenderer),super.destroy()}refresh(){return!1}};Ws.TEMPLATE='<span class="ag-cell-wrapper">\n            <span class="ag-group-expanded" ref="eExpanded"></span>\n            <span class="ag-group-contracted" ref="eContracted"></span>\n            <span class="ag-group-checkbox ag-invisible" ref="eCheckbox"></span>\n            <span class="ag-group-value" ref="eValue"></span>\n            <span class="ag-group-child-count" ref="eChildCount"></span>\n        </span>',g([Sn("eExpanded")],Ws.prototype,"eExpanded",2),g([Sn("eContracted")],Ws.prototype,"eContracted",2),g([Sn("eCheckbox")],Ws.prototype,"eCheckbox",2),g([Sn("eValue")],Ws.prototype,"eValue",2),g([Sn("eChildCount")],Ws.prototype,"eChildCount",2);var js=Ws,Ks=class e extends yn{constructor(){super(e.TEMPLATE)}init(e){e.node.failedLoad?this.setupFailed():this.setupLoading()}setupFailed(){const e=this.localeService.getLocaleTextFunc();this.eLoadingText.innerText=e("loadingError","ERR")}setupLoading(){const e=$r("groupLoading",this.gos,null);e&&this.eLoadingIcon.appendChild(e);const t=this.localeService.getLocaleTextFunc();this.eLoadingText.innerText=t("loadingOoo","Loading")}refresh(e){return!1}destroy(){super.destroy()}};Ks.TEMPLATE='<div class="ag-loading">\n            <span class="ag-loading-icon" ref="eLoadingIcon"></span>\n            <span class="ag-loading-text" ref="eLoadingText"></span>\n        </div>',g([Sn("eLoadingIcon")],Ks.prototype,"eLoadingIcon",2),g([Sn("eLoadingText")],Ks.prototype,"eLoadingText",2);var $s=Ks,qs=class e extends yn{constructor(){super(e.TEMPLATE)}init(e){const t=`ag-cell-skeleton-renderer-${this.getCompId()}`;this.getGui().setAttribute("id",t),this.addDestroyFunc(()=>Kt(e.eParentOfValue)),Kt(e.eParentOfValue,t),e.node.failedLoad?this.setupFailed():this.setupLoading()}setupFailed(){const e=this.localeService.getLocaleTextFunc();this.getGui().innerText=e("loadingError","ERR");const t=e("ariaSkeletonCellLoadingFailed","Row failed to load");jt(this.getGui(),t)}setupLoading(){const e=this.gos.getDocument().createElement("div");e.classList.add("ag-skeleton-effect"),this.getGui().appendChild(e);const t=this.localeService.getLocaleTextFunc()("ariaSkeletonCellLoading","Row data is loading");jt(this.getGui(),t)}refresh(e){return!1}destroy(){super.destroy()}};qs.TEMPLATE='<div class="ag-skeleton-container"></div>';var Ys=qs,Qs=class e extends yn{constructor(){super()}destroy(){super.destroy()}init(t){const i=this.gos.get("overlayLoadingTemplate");if(this.setTemplate(null!=i?i:e.DEFAULT_LOADING_OVERLAY_TEMPLATE),!i){const e=this.localeService.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=e("loadingOoo","Loading...")})}}};Qs.DEFAULT_LOADING_OVERLAY_TEMPLATE='<span aria-live="polite" aria-atomic="true" class="ag-overlay-loading-center"></span>';var Xs=Qs,Zs=class e extends yn{constructor(){super()}destroy(){super.destroy()}init(t){const i=this.gos.get("overlayNoRowsTemplate");if(this.setTemplate(null!=i?i:e.DEFAULT_NO_ROWS_TEMPLATE),!i){const e=this.localeService.getLocaleTextFunc();setTimeout(()=>{this.getGui().textContent=e("noRowsToShow","No Rows To Show")})}}};Zs.DEFAULT_NO_ROWS_TEMPLATE='<span class="ag-overlay-no-rows-center"></span>';var Js=Zs,eo=class extends Es{constructor(){super('<div class="ag-tooltip"></div>')}init(e){const{value:t}=e;this.getGui().textContent=Ct(t,!0)}},to=class{getTemplate(){return'<ag-input-number-field class="ag-cell-editor" ref="eInput"></ag-input-number-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.max&&e.setMax(t.max),null!=t.min&&e.setMin(t.min),null!=t.precision&&e.setPrecision(t.precision),null!=t.step&&e.setStep(t.step);const i=e.getInputElement();t.preventStepping?e.addManagedListener(i,"keydown",this.preventStepping):t.showStepperButtons&&i.classList.add("ag-number-field-input-stepper")}preventStepping(e){e.key!==Yr.UP&&e.key!==Yr.DOWN||e.preventDefault()}getValue(){const e=this.eInput.getValue();if(!C(e)&&!C(this.params.value))return this.params.value;let t=this.params.parseValue(e);if(null==t)return t;if("string"==typeof t){if(""===t)return null;t=Number(t)}return isNaN(t)?null:t}getStartValue(){return this.params.value}},io=class extends Rs{constructor(){super(new to)}},ro=class{getTemplate(){return'<ag-input-date-field class="ag-cell-editor" ref="eInput"></ag-input-date-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.min&&e.setMin(t.min),null!=t.max&&e.setMax(t.max),null!=t.step&&e.setStep(t.step)}getValue(){const e=this.eInput.getDate();return C(e)||C(this.params.value)?null!=e?e:null:this.params.value}getStartValue(){const{value:e}=this.params;if(e instanceof Date)return Yi(e,!1)}},no=class extends Rs{constructor(){super(new ro)}},so=class{constructor(e){this.getDataTypeService=e}getTemplate(){return'<ag-input-date-field class="ag-cell-editor" ref="eInput"></ag-input-date-field>'}init(e,t){this.eInput=e,this.params=t,null!=t.min&&e.setMin(t.min),null!=t.max&&e.setMax(t.max),null!=t.step&&e.setStep(t.step)}getValue(){const e=this.formatDate(this.eInput.getDate());return C(e)||C(this.params.value)?this.params.parseValue(null!=e?e:""):this.params.value}getStartValue(){var e,t;return Yi(null!=(t=this.parseDate(null!=(e=this.params.value)?e:void 0))?t:null,!1)}parseDate(e){return this.getDataTypeService().getDateParserFunction(this.params.column)(e)}formatDate(e){return this.getDataTypeService().getDateFormatterFunction(this.params.column)(e)}},oo=class extends Rs{constructor(){super(new so(()=>this.dataTypeService))}};g([ue("dataTypeService")],oo.prototype,"dataTypeService",2);var ao=class e extends yn{constructor(){super(e.TEMPLATE)}init(e){this.params=e,this.updateCheckbox(e);const t=this.eCheckbox.getInputElement();t.setAttribute("tabindex","-1"),qt(t,"polite"),this.addManagedListener(t,"click",e=>{if(qe(e),this.eCheckbox.isDisabled())return;const t=this.eCheckbox.getValue();this.onCheckboxChanged(t)}),this.addManagedListener(t,"dblclick",e=>{qe(e)}),this.addManagedListener(this.params.eGridCell,"keydown",e=>{if(e.key===Yr.SPACE&&!this.eCheckbox.isDisabled()){this.params.eGridCell===this.gos.getActiveDomElement()&&this.eCheckbox.toggle();const t=this.eCheckbox.getValue();this.onCheckboxChanged(t),e.preventDefault()}})}refresh(e){return this.params=e,this.updateCheckbox(e),!0}updateCheckbox(e){var t,i,r;let n,s=!0;if(e.node.group&&e.column){const i=e.column.getColId();i.startsWith(ht)?n=null==e.value||""===e.value?void 0:"true"===e.value:e.node.aggData&&void 0!==e.node.aggData[i]?n=null!=(t=e.value)?t:void 0:s=!1}else n=null!=(i=e.value)?i:void 0;if(!s)return void this.eCheckbox.setDisplayed(!1);this.eCheckbox.setValue(n);const o=null!=e.disabled?e.disabled:!(null==(r=e.column)?void 0:r.isCellEditable(e.node));this.eCheckbox.setDisabled(o);const a=this.localeService.getLocaleTextFunc(),l=mi(a,n),c=o?l:`${a("ariaToggleCellValue","Press SPACE to toggle cell value")} (${l})`;this.eCheckbox.setInputAriaLabel(c)}onCheckboxChanged(e){const{column:t,node:i,rowIndex:r,value:n}=this.params,s={type:lt.EVENT_CELL_EDITING_STARTED,column:t,colDef:null==t?void 0:t.getColDef(),data:i.data,node:i,rowIndex:r,rowPinned:i.rowPinned,value:n};this.eventService.dispatchEvent(s);const o=this.params.node.setDataValue(this.params.column,e,"edit"),a={type:lt.EVENT_CELL_EDITING_STOPPED,column:t,colDef:null==t?void 0:t.getColDef(),data:i.data,node:i,rowIndex:r,rowPinned:i.rowPinned,value:n,oldValue:n,newValue:e,valueChanged:o};this.eventService.dispatchEvent(a)}};ao.TEMPLATE='\n        <div class="ag-cell-wrapper ag-checkbox-cell" role="presentation">\n            <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n        </div>',g([Sn("eCheckbox")],ao.prototype,"eCheckbox",2);var lo=ao,co=class extends Es{constructor(){super('\n            <div class="ag-cell-wrapper ag-cell-edit-wrapper ag-checkbox-edit">\n                <ag-checkbox role="presentation" ref="eCheckbox"></ag-checkbox>\n            </div>')}init(e){var t;this.params=e;const i=null!=(t=e.value)?t:void 0;this.eCheckbox.setValue(i),this.eCheckbox.getInputElement().setAttribute("tabindex","-1"),this.setAriaLabel(i),this.addManagedListener(this.eCheckbox,lt.EVENT_FIELD_VALUE_CHANGED,e=>this.setAriaLabel(e.selected))}getValue(){return this.eCheckbox.getValue()}focusIn(){this.eCheckbox.getFocusableElement().focus()}afterGuiAttached(){this.params.cellStartedEdit&&this.focusIn()}isPopup(){return!1}setAriaLabel(e){const t=this.localeService.getLocaleTextFunc(),i=mi(t,e),r=t("ariaToggleCellValue","Press SPACE to toggle cell value");this.eCheckbox.setInputAriaLabel(`${r} (${i})`)}};g([Sn("eCheckbox")],co.prototype,"eCheckbox",2);var uo=class extends yn{constructor(){super(),this.setTemplate("<div></div>")}init(e){var t;this.params=e,this.cssClassPrefix=null!=(t=this.params.cssClassPrefix)?t:"ag-menu-option",this.addIcon(),this.addName(),this.addShortcut(),this.addSubMenu()}configureDefaults(){return!0}addIcon(){if(this.params.isCompact)return;const e=br(`<span ref="eIcon" class="${this.getClassName("part")} ${this.getClassName("icon")}" role="presentation"></span>`);this.params.checked?e.appendChild($r("check",this.gos)):this.params.icon&&(Nr(this.params.icon)?e.appendChild(this.params.icon):"string"==typeof this.params.icon?e.innerHTML=this.params.icon:console.warn("AG Grid: menu item icon must be DOM node or string")),this.getGui().appendChild(e)}addName(){const e=br(`<span ref="eName" class="${this.getClassName("part")} ${this.getClassName("text")}">${this.params.name||""}</span>`);this.getGui().appendChild(e)}addShortcut(){if(this.params.isCompact)return;const e=br(`<span ref="eShortcut" class="${this.getClassName("part")} ${this.getClassName("shortcut")}">${this.params.shortcut||""}</span>`);this.getGui().appendChild(e)}addSubMenu(){const e=br(`<span ref="ePopupPointer" class="${this.getClassName("part")} ${this.getClassName("popup-pointer")}"></span>`),t=this.getGui();if(this.params.subMenu){const i=this.gos.get("enableRtl")?"smallLeft":"smallRight";ti(t,!1),e.appendChild($r(i,this.gos))}t.appendChild(e)}getClassName(e){return`${this.cssClassPrefix}-${e}`}destroy(){super.destroy()}},ho=class extends rt{constructor(){super(...arguments),this.agGridDefaults={agDateInput:es,agColumnHeader:ws,agColumnGroupHeader:bs,agSortIndicator:Cs,agTextColumnFloatingFilter:gs,agNumberColumnFloatingFilter:ps,agDateColumnFloatingFilter:Jn,agReadOnlyFloatingFilter:En,agAnimateShowChangeCellRenderer:xs,agAnimateSlideCellRenderer:Ds,agGroupCellRenderer:js,agGroupRowRenderer:js,agLoadingCellRenderer:$s,agSkeletonCellRenderer:Ys,agCheckboxCellRenderer:lo,agCellEditor:Ps,agTextCellEditor:Ps,agNumberCellEditor:io,agDateCellEditor:no,agDateStringCellEditor:oo,agSelectCellEditor:Ms,agLargeTextCellEditor:Ts,agCheckboxCellEditor:co,agTextColumnFilter:cs,agNumberColumnFilter:os,agDateColumnFilter:Xn,agLoadingOverlay:Xs,agNoRowsOverlay:Js,agTooltipComponent:eo,agMenuItem:uo},this.enterpriseAgDefaultCompsModule={agSetColumnFilter:"@ag-grid-enterprise/set-filter",agSetColumnFloatingFilter:"@ag-grid-enterprise/set-filter",agMultiColumnFilter:"@ag-grid-enterprise/multi-filter",agMultiColumnFloatingFilter:"@ag-grid-enterprise/multi-filter",agGroupColumnFilter:"@ag-grid-enterprise/row-grouping",agGroupColumnFloatingFilter:"@ag-grid-enterprise/row-grouping",agRichSelect:"@ag-grid-enterprise/rich-select",agRichSelectCellEditor:"@ag-grid-enterprise/rich-select",agDetailCellRenderer:"@ag-grid-enterprise/master-detail",agSparklineCellRenderer:"@ag-grid-enterprise/sparklines"},this.jsComps={}}init(){const e=this.gos.get("components");null!=e&&D(e,(e,t)=>this.registerJsComponent(e,t))}registerDefaultComponent(e,t){this.agGridDefaults[e]?console.error("Trying to overwrite a default component. You should call registerComponent"):this.agGridDefaults[e]=t}registerJsComponent(e,t){this.jsComps[e]=t}retrieve(e,t){const i=(e,t)=>({componentFromFramework:t,component:e}),r=this.getFrameworkOverrides().frameworkComponent(t,this.gos.get("components"));if(null!=r)return i(r,!0);const n=this.jsComps[t];if(n)return i(n,this.getFrameworkOverrides().isFrameworkComponent(n));const s=this.agGridDefaults[t];if(s)return i(s,!1);const o=this.enterpriseAgDefaultCompsModule[t];return o?ne.__assertRegistered(o,`AG Grid '${e}' component: ${t}`,this.context.getGridId()):B(()=>{this.warnAboutMissingComponent(e,t)},"MissingComp"+t),null}warnAboutMissingComponent(e,t){const i=zr(t,[...Object.keys(this.agGridDefaults).filter(e=>!["agCellEditor","agGroupRowRenderer","agSortIndicator"].includes(e)),...Object.keys(this.jsComps)],!0,.8).values;console.warn(`AG Grid: Could not find '${t}' component. It was configured as "${e}: '${t}'" but it wasn't found in the list of registered components.`),i.length>0&&console.warn(`         Did you mean: [${i.slice(0,3)}]?`),console.warn(`If using a custom component check it has been registered as described in: ${this.getFrameworkOverrides().getDocLink("components/")}`)}};g([ae],ho.prototype,"init",1),ho=g([ce("userComponentRegistry")],ho);var po={propertyName:"dateComponent",cellRenderer:!1},go={propertyName:"headerComponent",cellRenderer:!1},fo={propertyName:"headerGroupComponent",cellRenderer:!1},mo={propertyName:"cellRenderer",cellRenderer:!0},vo={propertyName:"loadingCellRenderer",cellRenderer:!0},Co={propertyName:"cellEditor",cellRenderer:!1},yo={propertyName:"innerRenderer",cellRenderer:!0},wo={propertyName:"loadingOverlayComponent",cellRenderer:!1},So={propertyName:"noRowsOverlayComponent",cellRenderer:!1},bo={propertyName:"tooltipComponent",cellRenderer:!1},Eo={propertyName:"filter",cellRenderer:!1},Ao={propertyName:"floatingFilterComponent",cellRenderer:!1},To={propertyName:"toolPanel",cellRenderer:!1},Mo={propertyName:"statusPanel",cellRenderer:!1},Ro={propertyName:"fullWidthCellRenderer",cellRenderer:!0},_o={propertyName:"loadingCellRenderer",cellRenderer:!0},Po={propertyName:"groupRowRenderer",cellRenderer:!0},xo={propertyName:"detailCellRenderer",cellRenderer:!0},Do={propertyName:"menuItem",cellRenderer:!1},Io=class{static getFloatingFilterType(e){return this.filterToFloatingFilterMapping[e]}};Io.filterToFloatingFilterMapping={set:"agSetColumnFloatingFilter",agSetColumnFilter:"agSetColumnFloatingFilter",multi:"agMultiColumnFloatingFilter",agMultiColumnFilter:"agMultiColumnFloatingFilter",group:"agGroupColumnFloatingFilter",agGroupColumnFilter:"agGroupColumnFloatingFilter",number:"agNumberColumnFloatingFilter",agNumberColumnFilter:"agNumberColumnFloatingFilter",date:"agDateColumnFloatingFilter",agDateColumnFilter:"agDateColumnFloatingFilter",text:"agTextColumnFloatingFilter",agTextColumnFilter:"agTextColumnFloatingFilter"};var Lo=class extends rt{getHeaderCompDetails(e,t){return this.getCompDetails(e,go,"agColumnHeader",t)}getHeaderGroupCompDetails(e){const t=e.columnGroup.getColGroupDef();return this.getCompDetails(t,fo,"agColumnGroupHeader",e)}getFullWidthCellRendererDetails(e){return this.getCompDetails(this.gridOptions,Ro,null,e,!0)}getFullWidthLoadingCellRendererDetails(e){return this.getCompDetails(this.gridOptions,_o,"agLoadingCellRenderer",e,!0)}getFullWidthGroupCellRendererDetails(e){return this.getCompDetails(this.gridOptions,Po,"agGroupRowRenderer",e,!0)}getFullWidthDetailCellRendererDetails(e){return this.getCompDetails(this.gridOptions,xo,"agDetailCellRenderer",e,!0)}getInnerRendererDetails(e,t){return this.getCompDetails(e,yo,null,t)}getFullWidthGroupRowInnerCellRenderer(e,t){return this.getCompDetails(e,yo,null,t)}getCellRendererDetails(e,t){return this.getCompDetails(e,mo,null,t)}getLoadingCellRendererDetails(e,t){return this.getCompDetails(e,vo,"agSkeletonCellRenderer",t,!0)}getCellEditorDetails(e,t){return this.getCompDetails(e,Co,"agCellEditor",t,!0)}getFilterDetails(e,t,i){return this.getCompDetails(e,Eo,i,t,!0)}getDateCompDetails(e){return this.getCompDetails(this.gridOptions,po,"agDateInput",e,!0)}getLoadingOverlayCompDetails(e){return this.getCompDetails(this.gridOptions,wo,"agLoadingOverlay",e,!0)}getNoRowsOverlayCompDetails(e){return this.getCompDetails(this.gridOptions,So,"agNoRowsOverlay",e,!0)}getTooltipCompDetails(e){return this.getCompDetails(e.colDef,bo,"agTooltipComponent",e,!0)}getSetFilterCellRendererDetails(e,t){return this.getCompDetails(e,mo,null,t)}getFloatingFilterCompDetails(e,t,i){return this.getCompDetails(e,Ao,i,t)}getToolPanelCompDetails(e,t){return this.getCompDetails(e,To,null,t,!0)}getStatusPanelCompDetails(e,t){return this.getCompDetails(e,Mo,null,t,!0)}getMenuItemCompDetails(e,t){return this.getCompDetails(e,Do,"agMenuItem",t,!0)}getCompDetails(e,t,i,r,n=!1){const{propertyName:s,cellRenderer:o}=t;let{compName:a,jsComp:l,fwComp:c,paramsFromSelector:u,popupFromSelector:h,popupPositionFromSelector:d}=this.getCompKeys(e,t,r);const p=e=>{const t=this.userComponentRegistry.retrieve(s,e);t&&(l=t.componentFromFramework?void 0:t.component,c=t.componentFromFramework?t.component:void 0)};if(null!=a&&p(a),null==l&&null==c&&null!=i&&p(i),l&&o&&!this.agComponentUtils.doesImplementIComponent(l)&&(l=this.agComponentUtils.adaptFunction(s,l)),!l&&!c)return void(n&&console.error(`AG Grid: Could not find component ${a}, did you forget to configure this component?`));const g=this.mergeParamsWithApplicationProvidedParams(e,t,r,u),f=null==l,m=l||c;return{componentFromFramework:f,componentClass:m,params:g,type:t,popupFromSelector:h,popupPositionFromSelector:d,newAgStackInstance:()=>this.newAgStackInstance(m,f,g,t)}}getCompKeys(e,t,i){const{propertyName:r}=t;let n,s,o,a,l,c;if(e){const t=e,u=t[r+"Selector"],h=u?u(i):null,d=e=>{"string"==typeof e?n=e:null!=e&&!0!==e&&(this.getFrameworkOverrides().isFrameworkComponent(e)?o=e:s=e)};h?(d(h.component),a=h.params,l=h.popup,c=h.popupPosition):d(t[r])}return{compName:n,jsComp:s,fwComp:o,paramsFromSelector:a,popupFromSelector:l,popupPositionFromSelector:c}}newAgStackInstance(e,t,i,r){const n=r.propertyName;let s;if(t){const t=this.componentMetadataProvider.retrieve(n);s=this.frameworkComponentWrapper.wrap(e,t.mandatoryMethodList,t.optionalMethodList,r)}else s=new e;const o=this.initComponent(s,i);return null==o?hn.resolve(s):o.then(()=>s)}mergeParamsWithApplicationProvidedParams(e,t,i,r=null){const n=this.gos.getGridCommonParams();O(n,i);const s=e&&e[t.propertyName+"Params"];return"function"==typeof s?O(n,s(i)):"object"==typeof s&&O(n,s),O(n,r),n}initComponent(e,t){if(this.context.createBean(e),null!=e.init)return e.init(t)}getDefaultFloatingFilterType(e,t){if(null==e)return null;let i=null,{compName:r,jsComp:n,fwComp:s}=this.getCompKeys(e,Eo);return r?i=Io.getFloatingFilterType(r):null==n&&null==s&&!0===e.filter&&(i=t()),i}};g([ue("gridOptions")],Lo.prototype,"gridOptions",2),g([ue("agComponentUtils")],Lo.prototype,"agComponentUtils",2),g([ue("componentMetadataProvider")],Lo.prototype,"componentMetadataProvider",2),g([ue("userComponentRegistry")],Lo.prototype,"userComponentRegistry",2),g([he("frameworkComponentWrapper")],Lo.prototype,"frameworkComponentWrapper",2),Lo=g([ce("userComponentFactory")],Lo);var No=(e=>(e[e.SINGLE_SHEET=0]="SINGLE_SHEET",e[e.MULTI_SHEET=1]="MULTI_SHEET",e))(No||{}),Oo=(e=>(e[e.Above=0]="Above",e[e.Below=1]="Below",e))(Oo||{}),Fo=class{constructor(e){this.tickingInterval=null,this.onScrollCallback=null,this.scrollContainer=e.scrollContainer,this.scrollHorizontally=-1!==e.scrollAxis.indexOf("x"),this.scrollVertically=-1!==e.scrollAxis.indexOf("y"),this.scrollByTick=null!=e.scrollByTick?e.scrollByTick:20,e.onScrollCallback&&(this.onScrollCallback=e.onScrollCallback),this.scrollVertically&&(this.getVerticalPosition=e.getVerticalPosition,this.setVerticalPosition=e.setVerticalPosition),this.scrollHorizontally&&(this.getHorizontalPosition=e.getHorizontalPosition,this.setHorizontalPosition=e.setHorizontalPosition),this.shouldSkipVerticalScroll=e.shouldSkipVerticalScroll||(()=>!1),this.shouldSkipHorizontalScroll=e.shouldSkipHorizontalScroll||(()=>!1)}check(e,t=!1){const i=t||this.shouldSkipVerticalScroll();if(i&&this.shouldSkipHorizontalScroll())return;const r=this.scrollContainer.getBoundingClientRect(),n=this.scrollByTick;this.tickLeft=e.clientX<r.left+n,this.tickRight=e.clientX>r.right-n,this.tickUp=e.clientY<r.top+n&&!i,this.tickDown=e.clientY>r.bottom-n&&!i,this.tickLeft||this.tickRight||this.tickUp||this.tickDown?this.ensureTickingStarted():this.ensureCleared()}ensureTickingStarted(){null===this.tickingInterval&&(this.tickingInterval=window.setInterval(this.doTick.bind(this),100),this.tickCount=0)}doTick(){let e;if(this.tickCount++,e=this.tickCount>20?200:this.tickCount>10?80:40,this.scrollVertically){const t=this.getVerticalPosition();this.tickUp&&this.setVerticalPosition(t-e),this.tickDown&&this.setVerticalPosition(t+e)}if(this.scrollHorizontally){const t=this.getHorizontalPosition();this.tickLeft&&this.setHorizontalPosition(t-e),this.tickRight&&this.setHorizontalPosition(t+e)}this.onScrollCallback&&this.onScrollCallback()}ensureCleared(){this.tickingInterval&&(window.clearInterval(this.tickingInterval),this.tickingInterval=null)}},ko=class extends rt{constructor(e){super(),this.eContainer=e}postConstruct(){this.gos.isRowModelType("clientSide")&&(this.clientSideRowModel=this.rowModel),this.ctrlsService.whenReady(e=>{const t=e.gridBodyCtrl;this.autoScrollService=new Fo({scrollContainer:t.getBodyViewportElement(),scrollAxis:"y",getVerticalPosition:()=>t.getScrollFeature().getVScrollPosition().top,setVerticalPosition:e=>t.getScrollFeature().setVerticalScrollPosition(e),onScrollCallback:()=>{this.onDragging(this.lastDraggingEvent)}})})}getContainer(){return this.eContainer}isInterestedIn(e){return 2===e}getIconName(){return this.gos.get("rowDragManaged")&&this.shouldPreventRowMove()?Gs.ICON_NOT_ALLOWED:Gs.ICON_MOVE}shouldPreventRowMove(){return!!this.columnModel.getRowGroupColumns().length||(!!this.filterManager.isAnyFilterPresent()||!!this.sortController.isSortActive())}getRowNodes(e){if(!this.isFromThisGrid(e))return e.dragItem.rowNodes||[];const t=e.dragItem.rowNode;if(this.gos.get("rowDragMultiRow")){const e=[...this.selectionService.getSelectedNodes()].sort((e,t)=>null==e.rowIndex||null==t.rowIndex?0:this.getRowIndexNumber(e)-this.getRowIndexNumber(t));if(-1!==e.indexOf(t))return e}return[t]}onDragEnter(e){e.dragItem.rowNodes=this.getRowNodes(e),this.dispatchGridEvent(lt.EVENT_ROW_DRAG_ENTER,e),this.getRowNodes(e).forEach(e=>{e.setDragging(!0)}),this.onEnterOrDragging(e)}onDragging(e){this.onEnterOrDragging(e)}isFromThisGrid(e){const{dragSourceDomDataKey:t}=e.dragSource;return t===this.gos.getDomDataKey()}isDropZoneWithinThisGrid(e){const t=this.ctrlsService.getGridBodyCtrl().getGui(),{dropZoneTarget:i}=e;return!t.contains(i)}onEnterOrDragging(e){this.dispatchGridEvent(lt.EVENT_ROW_DRAG_MOVE,e),this.lastDraggingEvent=e;const t=this.mouseEventService.getNormalisedPosition(e).y;this.gos.get("rowDragManaged")&&this.doManagedDrag(e,t),this.autoScrollService.check(e.event)}doManagedDrag(e,t){const i=this.isFromThisGrid(e),r=this.gos.get("rowDragManaged"),n=e.dragItem.rowNodes;r&&this.shouldPreventRowMove()||(this.gos.get("suppressMoveWhenRowDragging")||!i?this.isDropZoneWithinThisGrid(e)||this.clientSideRowModel.highlightRowAtPixel(n[0],t):this.moveRows(n,t))}getRowIndexNumber(e){return parseInt(_e(e.getRowIndexString().split("-")),10)}moveRowAndClearHighlight(e){const t=this.clientSideRowModel.getLastHighlightedRowNode(),i=t&&1===t.highlighted,r=this.mouseEventService.getNormalisedPosition(e).y,n=e.dragItem.rowNodes;let s=i?1:0;if(this.isFromThisGrid(e))n.forEach(e=>{e.rowTop<r&&(s-=1)}),this.moveRows(n,r,s);else{const e=this.gos.getCallback("getRowId");let t=this.clientSideRowModel.getRowIndexAtPixel(r)+1;0===this.clientSideRowModel.getHighlightPosition(r)&&t--,this.clientSideRowModel.updateRowData({add:n.map(e=>e.data).filter(t=>!this.clientSideRowModel.getRowNode(e?e({data:t,level:0}):t.id)),addIndex:t})}this.clearRowHighlight()}clearRowHighlight(){this.clientSideRowModel.highlightRowAtPixel(null)}moveRows(e,t,i=0){var r;this.clientSideRowModel.ensureRowsAtPixel(e,t,i)&&(this.focusService.clearFocusedCell(),null==(r=this.rangeService)||r.removeAllCellRanges())}addRowDropZone(e){if(!e.getContainer())return void z("addRowDropZone - A container target needs to be provided");if(this.dragAndDropService.findExternalZone(e))return void console.warn("AG Grid: addRowDropZone - target already exists in the list of DropZones. Use `removeRowDropZone` before adding it again.");let t={getContainer:e.getContainer};e.fromGrid?t=e:(e.onDragEnter&&(t.onDragEnter=t=>{e.onDragEnter(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_ENTER,t))}),e.onDragLeave&&(t.onDragLeave=t=>{e.onDragLeave(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_LEAVE,t))}),e.onDragging&&(t.onDragging=t=>{e.onDragging(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_MOVE,t))}),e.onDragStop&&(t.onDragStop=t=>{e.onDragStop(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_END,t))})),this.dragAndDropService.addDropTarget(h({isInterestedIn:e=>2===e,getIconName:()=>Gs.ICON_MOVE,external:!0},t))}getRowDropZone(e){const t=this.getContainer.bind(this),i=this.onDragEnter.bind(this),r=this.onDragLeave.bind(this),n=this.onDragging.bind(this),s=this.onDragStop.bind(this);return e?{getContainer:t,onDragEnter:e.onDragEnter?t=>{i(t),e.onDragEnter(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_ENTER,t))}:i,onDragLeave:e.onDragLeave?t=>{r(t),e.onDragLeave(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_LEAVE,t))}:r,onDragging:e.onDragging?t=>{n(t),e.onDragging(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_MOVE,t))}:n,onDragStop:e.onDragStop?t=>{s(t),e.onDragStop(this.draggingToRowDragEvent(lt.EVENT_ROW_DRAG_END,t))}:s,fromGrid:!0}:{getContainer:t,onDragEnter:i,onDragLeave:r,onDragging:n,onDragStop:s,fromGrid:!0}}draggingToRowDragEvent(e,t){const i=this.mouseEventService.getNormalisedPosition(t).y;let r,n,s=-1;switch(i>this.paginationProxy.getCurrentPageHeight()||(s=this.rowModel.getRowIndexAtPixel(i),r=this.rowModel.getRow(s)),t.vDirection){case 1:n="down";break;case 0:n="up";break;default:n=null}return this.gos.addGridCommonParams({type:e,event:t.event,node:t.dragItem.rowNode,nodes:t.dragItem.rowNodes,overIndex:s,overNode:r,y:i,vDirection:n})}dispatchGridEvent(e,t){const i=this.draggingToRowDragEvent(e,t);this.eventService.dispatchEvent(i)}onDragLeave(e){this.dispatchGridEvent(lt.EVENT_ROW_DRAG_LEAVE,e),this.stopDragging(e),this.gos.get("rowDragManaged")&&this.clearRowHighlight()}onDragStop(e){this.dispatchGridEvent(lt.EVENT_ROW_DRAG_END,e),this.stopDragging(e),!this.gos.get("rowDragManaged")||!this.gos.get("suppressMoveWhenRowDragging")&&this.isFromThisGrid(e)||this.isDropZoneWithinThisGrid(e)||this.moveRowAndClearHighlight(e)}stopDragging(e){this.autoScrollService.ensureCleared(),this.getRowNodes(e).forEach(e=>{e.setDragging(!1)})}};g([ue("dragAndDropService")],ko.prototype,"dragAndDropService",2),g([ue("rowModel")],ko.prototype,"rowModel",2),g([ue("paginationProxy")],ko.prototype,"paginationProxy",2),g([ue("columnModel")],ko.prototype,"columnModel",2),g([ue("focusService")],ko.prototype,"focusService",2),g([ue("sortController")],ko.prototype,"sortController",2),g([ue("filterManager")],ko.prototype,"filterManager",2),g([ue("selectionService")],ko.prototype,"selectionService",2),g([ue("mouseEventService")],ko.prototype,"mouseEventService",2),g([ue("ctrlsService")],ko.prototype,"ctrlsService",2),g([he("rangeService")],ko.prototype,"rangeService",2),g([ae],ko.prototype,"postConstruct",1);var Go=class extends rt{constructor(){super(...arguments),this.dragEndFunctions=[],this.dragSources=[]}removeAllListeners(){this.dragSources.forEach(this.removeListener.bind(this)),this.dragSources.length=0}removeListener(e){const t=e.dragSource.eElement,i=e.mouseDownListener;if(t.removeEventListener("mousedown",i),e.touchEnabled){const i=e.touchStartListener;t.removeEventListener("touchstart",i,{passive:!0})}}removeDragSource(e){const t=this.dragSources.find(t=>t.dragSource===e);t&&(this.removeListener(t),Ne(this.dragSources,t))}isDragging(){return this.dragging}addDragSource(e){const t=this.onMouseDown.bind(this,e),{eElement:i,includeTouch:r,stopPropagationForTouch:n}=e;i.addEventListener("mousedown",t);let s=null;const o=this.gos.get("suppressTouch");r&&!o&&(s=t=>{nr(t.target)||(t.cancelable&&(t.preventDefault(),n&&t.stopPropagation()),this.onTouchStart(e,t))},i.addEventListener("touchstart",s,{passive:!1})),this.dragSources.push({dragSource:e,mouseDownListener:t,touchStartListener:s,touchEnabled:!!r})}getStartTarget(){return this.startTarget}onTouchStart(e,t){this.currentDragParams=e,this.dragging=!1;const i=t.touches[0];this.touchLastTime=i,this.touchStart=i;const r=t=>this.onTouchUp(t,e.eElement),n=t.target,s=[{target:this.gos.getRootNode(),type:"touchmove",listener:e=>{e.cancelable&&e.preventDefault()},options:{passive:!1}},{target:n,type:"touchmove",listener:t=>this.onTouchMove(t,e.eElement),options:{passive:!0}},{target:n,type:"touchend",listener:r,options:{passive:!0}},{target:n,type:"touchcancel",listener:r,options:{passive:!0}}];this.addTemporaryEvents(s),0===e.dragStartPixels&&this.onCommonMove(i,this.touchStart,e.eElement)}onMouseDown(e,t){const i=t;if(e.skipMouseEvent&&e.skipMouseEvent(t))return;if(i._alreadyProcessedByDragService)return;if(i._alreadyProcessedByDragService=!0,0!==t.button)return;this.shouldPreventMouseEvent(t)&&t.preventDefault(),this.currentDragParams=e,this.dragging=!1,this.mouseStartEvent=t,this.startTarget=t.target;const r=this.gos.getRootNode(),n=[{target:r,type:"mousemove",listener:t=>this.onMouseMove(t,e.eElement)},{target:r,type:"mouseup",listener:t=>this.onMouseUp(t,e.eElement)},{target:r,type:"contextmenu",listener:e=>e.preventDefault()}];this.addTemporaryEvents(n),0===e.dragStartPixels&&this.onMouseMove(t,e.eElement)}addTemporaryEvents(e){e.forEach(e=>{const{target:t,type:i,listener:r,options:n}=e;t.addEventListener(i,r,n)}),this.dragEndFunctions.push(()=>{e.forEach(e=>{const{target:t,type:i,listener:r,options:n}=e;t.removeEventListener(i,r,n)})})}isEventNearStartEvent(e,t){const{dragStartPixels:i}=this.currentDragParams;return rn(e,t,C(i)?i:4)}getFirstActiveTouch(e){for(let t=0;t<e.length;t++)if(e[t].identifier===this.touchStart.identifier)return e[t];return null}onCommonMove(e,t,i){if(!this.dragging){if(!this.dragging&&this.isEventNearStartEvent(e,t))return;this.dragging=!0;const r={type:lt.EVENT_DRAG_STARTED,target:i};this.eventService.dispatchEvent(r),this.currentDragParams.onDragStart(t),this.currentDragParams.onDragging(t)}this.currentDragParams.onDragging(e)}onTouchMove(e,t){const i=this.getFirstActiveTouch(e.touches);i&&this.onCommonMove(i,this.touchStart,t)}onMouseMove(e,t){var i;Mi()&&(null==(i=this.gos.getDocument().getSelection())||i.removeAllRanges()),this.shouldPreventMouseEvent(e)&&e.preventDefault(),this.onCommonMove(e,this.mouseStartEvent,t)}shouldPreventMouseEvent(e){const t=this.gos.get("enableCellTextSelection"),i="mousemove"===e.type;return t&&i&&e.cancelable&&this.mouseEventService.isEventFromThisGrid(e)&&!this.isOverFormFieldElement(e)}isOverFormFieldElement(e){const t=e.target,i=null==t?void 0:t.tagName.toLocaleLowerCase();return!!(null==i?void 0:i.match("^a$|textarea|input|select|button"))}onTouchUp(e,t){let i=this.getFirstActiveTouch(e.changedTouches);i||(i=this.touchLastTime),this.onUpCommon(i,t)}onMouseUp(e,t){this.onUpCommon(e,t)}onUpCommon(e,t){if(this.dragging){this.dragging=!1,this.currentDragParams.onDragStop(e);const i={type:lt.EVENT_DRAG_STOPPED,target:t};this.eventService.dispatchEvent(i)}this.mouseStartEvent=null,this.startTarget=null,this.touchStart=null,this.touchLastTime=null,this.currentDragParams=null,this.dragEndFunctions.forEach(e=>e()),this.dragEndFunctions.length=0}};g([ue("mouseEventService")],Go.prototype,"mouseEventService",2),g([le],Go.prototype,"removeAllListeners",1),Go=g([ce("dragService")],Go);var Vo="ag-list-item-hovered",Ho=class extends rt{constructor(e,t,i){super(),this.comp=e,this.virtualList=t,this.params=i,this.currentDragValue=null,this.lastHoveredListItem=null}postConstruct(){this.addManagedListener(this.params.eventSource,this.params.listItemDragStartEvent,this.listItemDragStart.bind(this)),this.addManagedListener(this.params.eventSource,this.params.listItemDragEndEvent,this.listItemDragEnd.bind(this)),this.createDropTarget(),this.createAutoScrollService()}listItemDragStart(e){this.currentDragValue=this.params.getCurrentDragValue(e),this.moveBlocked=this.params.isMoveBlocked(this.currentDragValue)}listItemDragEnd(){window.setTimeout(()=>{this.currentDragValue=null,this.moveBlocked=!1},10)}createDropTarget(){const e={isInterestedIn:e=>e===this.params.dragSourceType,getIconName:()=>this.moveBlocked?Gs.ICON_PINNED:Gs.ICON_MOVE,getContainer:()=>this.comp.getGui(),onDragging:e=>this.onDragging(e),onDragStop:()=>this.onDragStop(),onDragLeave:()=>this.onDragLeave()};this.dragAndDropService.addDropTarget(e)}createAutoScrollService(){const e=this.virtualList.getGui();this.autoScrollService=new Fo({scrollContainer:e,scrollAxis:"y",getVerticalPosition:()=>e.scrollTop,setVerticalPosition:t=>e.scrollTop=t})}onDragging(e){if(!this.currentDragValue||this.moveBlocked)return;const t=this.getListDragItem(e),i=this.virtualList.getComponentAt(t.rowIndex);if(!i)return;const r=i.getGui().parentElement;this.lastHoveredListItem&&this.lastHoveredListItem.rowIndex===t.rowIndex&&this.lastHoveredListItem.position===t.position||(this.autoScrollService.check(e.event),this.clearHoveredItems(),this.lastHoveredListItem=t,tr(r,Vo),tr(r,`ag-item-highlight-${t.position}`))}getListDragItem(e){const t=this.virtualList.getGui(),i=parseFloat(window.getComputedStyle(t).paddingTop),r=this.virtualList.getRowHeight(),n=this.virtualList.getScrollTop(),s=Math.max(0,(e.y-i+n)/r),o=this.params.getNumRows(this.comp)-1,a=0|Math.min(o,s);return{rowIndex:a,position:Math.round(s)>s||s>o?"bottom":"top",component:this.virtualList.getComponentAt(a)}}onDragStop(){this.moveBlocked||(this.params.moveItem(this.currentDragValue,this.lastHoveredListItem),this.clearHoveredItems(),this.autoScrollService.ensureCleared())}onDragLeave(){this.clearHoveredItems(),this.autoScrollService.ensureCleared()}clearHoveredItems(){this.virtualList.getGui().querySelectorAll(`.${Vo}`).forEach(e=>{[Vo,"ag-item-highlight-top","ag-item-highlight-bottom"].forEach(t=>{e.classList.remove(t)})}),this.lastHoveredListItem=null}};function Bo(e){const t=e;return null!=t&&null!=t.getFrameworkComponentInstance?t.getFrameworkComponentInstance():e}g([ue("dragAndDropService")],Ho.prototype,"dragAndDropService",2),g([ae],Ho.prototype,"postConstruct",1);var zo=class{constructor(){this.detailGridInfoMap={},this.destroyCalled=!1}init(){switch(this.rowModel.getType()){case"clientSide":this.clientSideRowModel=this.rowModel;break;case"infinite":this.infiniteRowModel=this.rowModel;break;case"serverSide":this.serverSideRowModel=this.rowModel}this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl})}__getAlignedGridService(){return this.alignedGridsService}getGridId(){return this.context.getGridId()}addDetailGridInfo(e,t){this.detailGridInfoMap[e]=t}removeDetailGridInfo(e){delete this.detailGridInfoMap[e]}getDetailGridInfo(e){return this.detailGridInfoMap[e]}forEachDetailGridInfo(e){let t=0;D(this.detailGridInfoMap,(i,r)=>{C(r)&&(e(r,t),t++)})}getDataAsCsv(e){if(ne.__assertRegistered("@ag-grid-community/csv-export","api.getDataAsCsv",this.context.getGridId()))return this.csvCreator.getDataAsCsv(e)}exportDataAsCsv(e){ne.__assertRegistered("@ag-grid-community/csv-export","api.exportDataAsCsv",this.context.getGridId())&&this.csvCreator.exportDataAsCsv(e)}assertNotExcelMultiSheet(e,t){return!(!ne.__assertRegistered("@ag-grid-enterprise/excel-export","api."+e,this.context.getGridId())||1===this.excelCreator.getFactoryMode()&&(console.warn("AG Grid: The Excel Exporter is currently on Multi Sheet mode. End that operation by calling 'api.getMultipleSheetAsExcel()' or 'api.exportMultipleSheetsAsExcel()'"),1))}getDataAsExcel(e){if(this.assertNotExcelMultiSheet("getDataAsExcel",e))return this.excelCreator.getDataAsExcel(e)}exportDataAsExcel(e){this.assertNotExcelMultiSheet("exportDataAsExcel",e)&&this.excelCreator.exportDataAsExcel(e)}getSheetDataForExcel(e){if(ne.__assertRegistered("@ag-grid-enterprise/excel-export","api.getSheetDataForExcel",this.context.getGridId()))return this.excelCreator.setFactoryMode(1),this.excelCreator.getSheetDataForExcel(e)}getMultipleSheetsAsExcel(e){if(ne.__assertRegistered("@ag-grid-enterprise/excel-export","api.getMultipleSheetsAsExcel",this.context.getGridId()))return this.excelCreator.getMultipleSheetsAsExcel(e)}exportMultipleSheetsAsExcel(e){ne.__assertRegistered("@ag-grid-enterprise/excel-export","api.exportMultipleSheetsAsExcel",this.context.getGridId())&&this.excelCreator.exportMultipleSheetsAsExcel(e)}setGridAriaProperty(e,t){if(!e)return;const i=this.ctrlsService.getGridBodyCtrl().getGui(),r=`aria-${e}`;null===t?i.removeAttribute(r):i.setAttribute(r,t)}logMissingRowModel(e,...t){console.error(`AG Grid: api.${e} can only be called when gridOptions.rowModelType is ${t.join(" or ")}`)}logDeprecation(e,t,i,r){z(`Since ${e} api.${t} is deprecated. Please use ${i} instead. ${null!=r?r:""}`)}getPinnedTopRowCount(){return this.pinnedRowModel.getPinnedTopRowCount()}getPinnedBottomRowCount(){return this.pinnedRowModel.getPinnedBottomRowCount()}getPinnedTopRow(e){return this.pinnedRowModel.getPinnedTopRow(e)}getPinnedBottomRow(e){return this.pinnedRowModel.getPinnedBottomRow(e)}expireValueCache(){this.valueCache.expire()}getVerticalPixelRange(){return this.gridBodyCtrl.getScrollFeature().getVScrollPosition()}getHorizontalPixelRange(){return this.gridBodyCtrl.getScrollFeature().getHScrollPosition()}refreshCells(e={}){this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.refreshCells(e))}flashCells(e={}){const t=e=>z(`Since v31.1 api.flashCells parameter '${e}Delay' is deprecated. Please use '${e}Duration' instead.`);C(e.fadeDelay)&&t("fade"),C(e.flashDelay)&&t("flash"),this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.flashCells(e))}redrawRows(e={}){const t=e?e.rowNodes:void 0;this.frameworkOverrides.wrapIncoming(()=>this.rowRenderer.redrawRows(t))}refreshHeader(){this.frameworkOverrides.wrapIncoming(()=>this.ctrlsService.getHeaderRowContainerCtrls().forEach(e=>e.refresh()))}isAnyFilterPresent(){return this.filterManager.isAnyFilterPresent()}isColumnFilterPresent(){return this.filterManager.isColumnFilterPresent()||this.filterManager.isAggregateFilterPresent()}isQuickFilterPresent(){return this.filterManager.isQuickFilterPresent()}getModel(){return z("Since v31.1 getModel() is deprecated. Please use the appropriate grid API methods instead."),this.rowModel}setRowNodeExpanded(e,t,i,r){this.expansionService.setRowNodeExpanded(e,t,i,r)}onGroupExpandedOrCollapsed(){y(this.clientSideRowModel)?this.logMissingRowModel("onGroupExpandedOrCollapsed","clientSide"):this.expansionService.onGroupExpandedOrCollapsed()}refreshClientSideRowModel(e){y(this.clientSideRowModel)?this.logMissingRowModel("refreshClientSideRowModel","clientSide"):this.clientSideRowModel.refreshModel(e)}isAnimationFrameQueueEmpty(){return this.animationFrameService.isQueueEmpty()}flushAllAnimationFrames(){this.animationFrameService.flushAllFrames()}getRowNode(e){return this.rowModel.getRowNode(e)}getSizesForCurrentTheme(){return{rowHeight:this.gos.getRowHeightAsNumber(),headerHeight:this.columnModel.getHeaderHeight()}}expandAll(){this.clientSideRowModel||this.serverSideRowModel?this.expansionService.expandAll(!0):this.logMissingRowModel("expandAll","clientSide","serverSide")}collapseAll(){this.clientSideRowModel||this.serverSideRowModel?this.expansionService.expandAll(!1):this.logMissingRowModel("collapseAll","clientSide","serverSide")}addRenderedRowListener(e,t,i){this.rowRenderer.addRenderedRowListener(e,t,i)}getQuickFilter(){return this.gos.get("quickFilterText")}getAdvancedFilterModel(){return ne.__assertRegistered("@ag-grid-enterprise/advanced-filter","api.getAdvancedFilterModel",this.context.getGridId())?this.filterManager.getAdvancedFilterModel():null}setAdvancedFilterModel(e){this.filterManager.setAdvancedFilterModel(e)}showAdvancedFilterBuilder(){ne.__assertRegistered("@ag-grid-enterprise/advanced-filter","api.setAdvancedFilterModel",this.context.getGridId())&&this.filterManager.showAdvancedFilterBuilder("api")}setNodesSelected(e){if(!e.nodes.every(e=>e.rowPinned?(console.warn("AG Grid: cannot select pinned rows"),!1):void 0!==e.id||(console.warn("AG Grid: cannot select node until id for node is known"),!1)))return;const{nodes:t,source:i,newValue:r}=e,n=t;this.selectionService.setNodesSelected({nodes:n,source:null!=i?i:"api",newValue:r})}selectAll(e="apiSelectAll"){this.selectionService.selectAllRowNodes({source:e})}deselectAll(e="apiSelectAll"){this.selectionService.deselectAllRowNodes({source:e})}selectAllFiltered(e="apiSelectAllFiltered"){this.selectionService.selectAllRowNodes({source:e,justFiltered:!0})}deselectAllFiltered(e="apiSelectAllFiltered"){this.selectionService.deselectAllRowNodes({source:e,justFiltered:!0})}getServerSideSelectionState(){return y(this.serverSideRowModel)?(this.logMissingRowModel("getServerSideSelectionState","serverSide"),null):this.selectionService.getSelectionState()}setServerSideSelectionState(e){y(this.serverSideRowModel)?this.logMissingRowModel("setServerSideSelectionState","serverSide"):this.selectionService.setSelectionState(e,"api")}selectAllOnCurrentPage(e="apiSelectAllCurrentPage"){this.selectionService.selectAllRowNodes({source:e,justCurrentPage:!0})}deselectAllOnCurrentPage(e="apiSelectAllCurrentPage"){this.selectionService.deselectAllRowNodes({source:e,justCurrentPage:!0})}showLoadingOverlay(){this.overlayService.showLoadingOverlay()}showNoRowsOverlay(){this.overlayService.showNoRowsOverlay()}hideOverlay(){this.overlayService.hideOverlay()}getSelectedNodes(){return this.selectionService.getSelectedNodes()}getSelectedRows(){return this.selectionService.getSelectedRows()}getBestCostNodeSelection(){if(!y(this.clientSideRowModel))return this.selectionService.getBestCostNodeSelection();this.logMissingRowModel("getBestCostNodeSelection","clientSide")}getRenderedNodes(){return this.rowRenderer.getRenderedNodes()}ensureColumnVisible(e,t="auto"){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureColumnVisible(e,t),"ensureVisible")}ensureIndexVisible(e,t){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureIndexVisible(e,t),"ensureVisible")}ensureNodeVisible(e,t=null){this.frameworkOverrides.wrapIncoming(()=>this.gridBodyCtrl.getScrollFeature().ensureNodeVisible(e,t),"ensureVisible")}forEachLeafNode(e){y(this.clientSideRowModel)?this.logMissingRowModel("forEachLeafNode","clientSide"):this.clientSideRowModel.forEachLeafNode(e)}forEachNode(e,t){this.rowModel.forEachNode(e,t)}forEachNodeAfterFilter(e){y(this.clientSideRowModel)?this.logMissingRowModel("forEachNodeAfterFilter","clientSide"):this.clientSideRowModel.forEachNodeAfterFilter(e)}forEachNodeAfterFilterAndSort(e){y(this.clientSideRowModel)?this.logMissingRowModel("forEachNodeAfterFilterAndSort","clientSide"):this.clientSideRowModel.forEachNodeAfterFilterAndSort(e)}getFilterInstance(e,t){return z("'getFilterInstance' is deprecated. To get/set individual filter models, use 'getColumnFilterModel' or 'setColumnFilterModel' instead. To get hold of the filter instance, use 'getColumnFilterInstance' which returns the instance asynchronously."),this.filterManager.getFilterInstance(e,t)}getColumnFilterInstance(e){return this.filterManager.getColumnFilterInstance(e)}destroyFilter(e){const t=this.columnModel.getPrimaryColumn(e);if(t)return this.filterManager.destroyFilter(t,"api")}getStatusPanel(e){if(ne.__assertRegistered("@ag-grid-enterprise/status-bar","api.getStatusPanel",this.context.getGridId()))return Bo(this.statusBarService.getStatusPanel(e))}getColumnDef(e){const t=this.columnModel.getPrimaryColumn(e);return t?t.getColDef():null}getColumnDefs(){return this.columnModel.getColumnDefs()}onFilterChanged(e="api"){this.filterManager.onFilterChanged({source:e})}onSortChanged(){this.sortController.onSortChanged("api")}setFilterModel(e){this.frameworkOverrides.wrapIncoming(()=>this.filterManager.setFilterModel(e))}getFilterModel(){return this.filterManager.getFilterModel()}getColumnFilterModel(e){return this.filterManager.getColumnFilterModel(e)}setColumnFilterModel(e,t){return this.filterManager.setColumnFilterModel(e,t)}getFocusedCell(){return this.focusService.getFocusedCell()}clearFocusedCell(){return this.focusService.clearFocusedCell()}setFocusedCell(e,t,i){this.focusService.setFocusedCell({rowIndex:e,column:t,rowPinned:i,forceBrowserFocus:!0})}addRowDropZone(e){this.gridBodyCtrl.getRowDragFeature().addRowDropZone(e)}removeRowDropZone(e){const t=this.dragAndDropService.findExternalZone(e);t&&this.dragAndDropService.removeDropTarget(t)}getRowDropZoneParams(e){return this.gridBodyCtrl.getRowDragFeature().getRowDropZone(e)}assertSideBarLoaded(e){return ne.__assertRegistered("@ag-grid-enterprise/side-bar","api."+e,this.context.getGridId())}isSideBarVisible(){return this.assertSideBarLoaded("isSideBarVisible")&&this.sideBarService.getSideBarComp().isDisplayed()}setSideBarVisible(e){this.assertSideBarLoaded("setSideBarVisible")&&this.sideBarService.getSideBarComp().setDisplayed(e)}setSideBarPosition(e){this.assertSideBarLoaded("setSideBarPosition")&&this.sideBarService.getSideBarComp().setSideBarPosition(e)}openToolPanel(e){this.assertSideBarLoaded("openToolPanel")&&this.sideBarService.getSideBarComp().openToolPanel(e,"api")}closeToolPanel(){this.assertSideBarLoaded("closeToolPanel")&&this.sideBarService.getSideBarComp().close("api")}getOpenedToolPanel(){return this.assertSideBarLoaded("getOpenedToolPanel")?this.sideBarService.getSideBarComp().openedItem():null}refreshToolPanel(){this.assertSideBarLoaded("refreshToolPanel")&&this.sideBarService.getSideBarComp().refresh()}isToolPanelShowing(){return this.assertSideBarLoaded("isToolPanelShowing")&&this.sideBarService.getSideBarComp().isToolPanelShowing()}getToolPanelInstance(e){if(this.assertSideBarLoaded("getToolPanelInstance"))return Bo(this.sideBarService.getSideBarComp().getToolPanelInstance(e))}getSideBar(){if(this.assertSideBarLoaded("getSideBar"))return this.sideBarService.getSideBarComp().getDef()}resetRowHeights(){if(C(this.clientSideRowModel)){if(this.columnModel.isAutoRowHeightActive())return void console.warn("AG Grid: calling gridApi.resetRowHeights() makes no sense when using Auto Row Height.");this.clientSideRowModel.resetRowHeights()}}setRowCount(e,t){if(this.serverSideRowModel)return this.columnModel.isRowGroupEmpty()?void this.serverSideRowModel.setRowCount(e,t):void console.error("AG Grid: setRowCount cannot be used while using row grouping.");this.infiniteRowModel?this.infiniteRowModel.setRowCount(e,t):this.logMissingRowModel("setRowCount","infinite","serverSide")}onRowHeightChanged(){this.clientSideRowModel?this.clientSideRowModel.onRowHeightChanged():this.serverSideRowModel&&this.serverSideRowModel.onRowHeightChanged()}getValue(e,t){return this.logDeprecation("31.3","getValue","getCellValue"),this.getCellValue({colKey:e,rowNode:t})}getCellValue(e){var t;const{colKey:i,rowNode:r,useFormatter:n}=e;let s=null!=(t=this.columnModel.getPrimaryColumn(i))?t:this.columnModel.getGridColumn(i);if(y(s))return null;const o=this.valueService.getValue(s,r);if(n){const e=this.valueService.formatValue(s,r,o);return null!=e?e:Ct(o,!0)}return o}addEventListener(e,t){this.apiEventService.addEventListener(e,t)}addGlobalListener(e){this.apiEventService.addGlobalListener(e)}removeEventListener(e,t){this.apiEventService.removeEventListener(e,t)}removeGlobalListener(e){this.apiEventService.removeGlobalListener(e)}dispatchEvent(e){this.eventService.dispatchEvent(e)}destroy(){var e;const t=`See ${this.frameworkOverrides.getDocLink("grid-lifecycle/#grid-pre-destroyed")}`;if(this.destroyCalled)return;const i={type:lt.EVENT_GRID_PRE_DESTROYED,state:this.getState()};this.dispatchEvent(i),this.destroyCalled=!0,null==(e=this.ctrlsService.get("gridCtrl"))||e.destroyGridUi(),this.context.destroy(),this.detailGridInfoMap={},k(this,["isDestroyed"],t)}isDestroyed(){return this.destroyCalled}resetQuickFilter(){this.filterManager.resetQuickFilterCache()}getCellRanges(){return this.rangeService?this.rangeService.getCellRanges():(ne.__assertRegistered("@ag-grid-enterprise/range-selection","api.getCellRanges",this.context.getGridId()),null)}addCellRange(e){this.rangeService?this.rangeService.addCellRange(e):ne.__assertRegistered("@ag-grid-enterprise/range-selection","api.addCellRange",this.context.getGridId())}clearRangeSelection(){this.rangeService&&this.rangeService.removeAllCellRanges(),ne.__assertRegistered("@ag-grid-enterprise/range-selection","gridApi.clearRangeSelection",this.context.getGridId())}undoCellEditing(){this.undoRedoService.undo("api")}redoCellEditing(){this.undoRedoService.redo("api")}getCurrentUndoSize(){return this.undoRedoService.getCurrentUndoStackSize()}getCurrentRedoSize(){return this.undoRedoService.getCurrentRedoStackSize()}assertChart(e,t){if(ne.__assertRegistered("@ag-grid-enterprise/charts","api."+e,this.context.getGridId()))return this.frameworkOverrides.wrapIncoming(()=>t())}getChartModels(){return this.assertChart("getChartModels",()=>this.chartService.getChartModels())}getChartRef(e){return this.assertChart("getChartRef",()=>this.chartService.getChartRef(e))}getChartImageDataURL(e){return this.assertChart("getChartImageDataURL",()=>this.chartService.getChartImageDataURL(e))}downloadChart(e){return this.assertChart("downloadChart",()=>this.chartService.downloadChart(e))}openChartToolPanel(e){return this.assertChart("openChartToolPanel",()=>this.chartService.openChartToolPanel(e))}closeChartToolPanel(e){return this.assertChart("closeChartToolPanel",()=>this.chartService.closeChartToolPanel(e.chartId))}createRangeChart(e){return this.assertChart("createRangeChart",()=>this.chartService.createRangeChart(e))}createPivotChart(e){return this.assertChart("createPivotChart",()=>this.chartService.createPivotChart(e))}createCrossFilterChart(e){return this.assertChart("createCrossFilterChart",()=>this.chartService.createCrossFilterChart(e))}updateChart(e){return this.assertChart("updateChart",()=>this.chartService.updateChart(e))}restoreChart(e,t){return this.assertChart("restoreChart",()=>this.chartService.restoreChart(e,t))}assertClipboard(e,t){ne.__assertRegistered("@ag-grid-enterprise/clipboard","api"+e,this.context.getGridId())&&t()}copyToClipboard(e){this.assertClipboard("copyToClipboard",()=>this.clipboardService.copyToClipboard(e))}cutToClipboard(e){this.assertClipboard("cutToClipboard",()=>this.clipboardService.cutToClipboard(e))}copySelectedRowsToClipboard(e){this.assertClipboard("copySelectedRowsToClipboard",()=>this.clipboardService.copySelectedRowsToClipboard(e))}copySelectedRangeToClipboard(e){this.assertClipboard("copySelectedRangeToClipboard",()=>this.clipboardService.copySelectedRangeToClipboard(e))}copySelectedRangeDown(){this.assertClipboard("copySelectedRangeDown",()=>this.clipboardService.copyRangeDown())}pasteFromClipboard(){this.assertClipboard("pasteFromClipboard",()=>this.clipboardService.pasteFromClipboard())}showColumnMenuAfterButtonClick(e,t){z("'showColumnMenuAfterButtonClick' is deprecated. Use 'IHeaderParams.showColumnMenu' within a header component, or 'api.showColumnMenu' elsewhere.");const i=this.columnModel.getGridColumn(e);this.menuService.showColumnMenu({column:i,buttonElement:t,positionBy:"button"})}showColumnMenuAfterMouseClick(e,t){z("'showColumnMenuAfterMouseClick' is deprecated. Use 'IHeaderParams.showColumnMenuAfterMouseClick' within a header component, or 'api.showColumnMenu' elsewhere.");let i=this.columnModel.getGridColumn(e);i||(i=this.columnModel.getPrimaryColumn(e)),i?this.menuService.showColumnMenu({column:i,mouseEvent:t,positionBy:"mouse"}):console.error(`AG Grid: column '${e}' not found`)}showContextMenu(e){const{rowNode:t,column:i,value:r,x:n,y:s}=e||{};let{x:o,y:a}=this.menuService.getContextMenuPosition(t,i);null!=n&&(o=n),null!=s&&(a=s),this.menuService.showContextMenu({mouseEvent:new MouseEvent("mousedown",{clientX:o,clientY:a}),rowNode:t,column:i,value:r})}showColumnChooser(e){this.menuService.showColumnChooser({chooserParams:e})}showColumnFilter(e){const t=this.columnModel.getGridColumn(e);t?this.menuService.showFilterMenu({column:t,containerType:"columnFilter",positionBy:"auto"}):console.error(`AG Grid: column '${e}' not found`)}showColumnMenu(e){const t=this.columnModel.getGridColumn(e);t?this.menuService.showColumnMenu({column:t,positionBy:"auto"}):console.error(`AG Grid: column '${e}' not found`)}hidePopupMenu(){this.menuService.hidePopupMenu()}hideColumnChooser(){this.menuService.hideColumnChooser()}tabToNextCell(e){return this.navigationService.tabToNextCell(!1,e)}tabToPreviousCell(e){return this.navigationService.tabToNextCell(!0,e)}getCellRendererInstances(e={}){return this.rowRenderer.getCellRendererInstances(e).map(Bo)}getCellEditorInstances(e={}){return this.rowRenderer.getCellEditorInstances(e).map(Bo)}getEditingCells(){return this.rowRenderer.getEditingCells()}stopEditing(e=!1){this.rowRenderer.stopEditing(e)}startEditingCell(e){const t=this.columnModel.getGridColumn(e.colKey);if(!t)return void console.warn(`AG Grid: no column found for ${e.colKey}`);const i={rowIndex:e.rowIndex,rowPinned:e.rowPinned||null,column:t};null==e.rowPinned&&this.ensureIndexVisible(e.rowIndex),this.ensureColumnVisible(e.colKey);const r=this.navigationService.getCellByPosition(i);r&&(this.focusService.isCellFocused(i)||this.focusService.setFocusedCell(i),r.startRowOrCellEdit(e.key))}addAggFunc(e,t){this.logDeprecation("v31.1","addAggFunc(key, func)","addAggFuncs({ key: func })"),this.aggFuncService&&this.aggFuncService.addAggFuncs({key:t})}addAggFuncs(e){this.aggFuncService&&this.aggFuncService.addAggFuncs(e)}clearAggFuncs(){this.aggFuncService&&this.aggFuncService.clear()}applyServerSideTransaction(e){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.applyTransaction(e);this.logMissingRowModel("applyServerSideTransaction","serverSide")}applyServerSideTransactionAsync(e,t){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.applyTransactionAsync(e,t);this.logMissingRowModel("applyServerSideTransactionAsync","serverSide")}applyServerSideRowData(e){var t,i;const r=null!=(t=e.startRow)?t:0,n=null!=(i=e.route)?i:[];r<0?console.warn(`AG Grid: invalid value ${e.startRow} for startRow, the value should be >= 0`):this.serverSideRowModel?this.serverSideRowModel.applyRowData(e.successParams,r,n):this.logMissingRowModel("setServerSideDatasource","serverSide")}retryServerSideLoads(){this.serverSideRowModel?this.serverSideRowModel.retryLoads():this.logMissingRowModel("retryServerSideLoads","serverSide")}flushServerSideAsyncTransactions(){if(this.serverSideTransactionManager)return this.serverSideTransactionManager.flushAsyncTransactions();this.logMissingRowModel("flushServerSideAsyncTransactions","serverSide")}applyTransaction(e){if(this.clientSideRowModel)return this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.updateRowData(e));this.logMissingRowModel("applyTransaction","clientSide")}applyTransactionAsync(e,t){this.clientSideRowModel?this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.batchUpdateRowData(e,t)):this.logMissingRowModel("applyTransactionAsync","clientSide")}flushAsyncTransactions(){this.clientSideRowModel?this.frameworkOverrides.wrapIncoming(()=>this.clientSideRowModel.flushAsyncTransactions()):this.logMissingRowModel("flushAsyncTransactions","clientSide")}refreshInfiniteCache(){this.infiniteRowModel?this.infiniteRowModel.refreshCache():this.logMissingRowModel("refreshInfiniteCache","infinite")}purgeInfiniteCache(){this.infiniteRowModel?this.infiniteRowModel.purgeCache():this.logMissingRowModel("purgeInfiniteCache","infinite")}refreshServerSide(e){this.serverSideRowModel?this.serverSideRowModel.refreshStore(e):this.logMissingRowModel("refreshServerSide","serverSide")}getServerSideGroupLevelState(){return this.serverSideRowModel?this.serverSideRowModel.getStoreState():(this.logMissingRowModel("getServerSideGroupLevelState","serverSide"),[])}getInfiniteRowCount(){if(this.infiniteRowModel)return this.infiniteRowModel.getRowCount();this.logMissingRowModel("getInfiniteRowCount","infinite")}isLastRowIndexKnown(){if(this.infiniteRowModel)return this.infiniteRowModel.isLastRowIndexKnown();this.logMissingRowModel("isLastRowIndexKnown","infinite")}getCacheBlockState(){return this.rowNodeBlockLoader.getBlockState()}getFirstDisplayedRow(){return this.logDeprecation("v31.1","getFirstDisplayedRow","getFirstDisplayedRowIndex"),this.getFirstDisplayedRowIndex()}getFirstDisplayedRowIndex(){return this.rowRenderer.getFirstVirtualRenderedRow()}getLastDisplayedRow(){return this.logDeprecation("v31.1","getLastDisplayedRow","getLastDisplayedRowIndex"),this.getLastDisplayedRowIndex()}getLastDisplayedRowIndex(){return this.rowRenderer.getLastVirtualRenderedRow()}getDisplayedRowAtIndex(e){return this.rowModel.getRow(e)}getDisplayedRowCount(){return this.rowModel.getRowCount()}paginationIsLastPageFound(){return this.paginationProxy.isLastPageFound()}paginationGetPageSize(){return this.paginationProxy.getPageSize()}paginationGetCurrentPage(){return this.paginationProxy.getCurrentPage()}paginationGetTotalPages(){return this.paginationProxy.getTotalPages()}paginationGetRowCount(){return this.paginationProxy.getMasterRowCount()}paginationGoToNextPage(){this.paginationProxy.goToNextPage()}paginationGoToPreviousPage(){this.paginationProxy.goToPreviousPage()}paginationGoToFirstPage(){this.paginationProxy.goToFirstPage()}paginationGoToLastPage(){this.paginationProxy.goToLastPage()}paginationGoToPage(e){this.paginationProxy.goToPage(e)}sizeColumnsToFit(e){"number"==typeof e?this.columnModel.sizeColumnsToFit(e,"api"):this.gridBodyCtrl.sizeColumnsToFit(e)}setColumnGroupOpened(e,t){this.columnModel.setColumnGroupOpened(e,t,"api")}getColumnGroup(e,t){return this.columnModel.getColumnGroup(e,t)}getProvidedColumnGroup(e){return this.columnModel.getProvidedColumnGroup(e)}getDisplayNameForColumn(e,t){return this.columnModel.getDisplayNameForColumn(e,t)||""}getDisplayNameForColumnGroup(e,t){return this.columnModel.getDisplayNameForColumnGroup(e,t)||""}getColumn(e){return this.columnModel.getPrimaryColumn(e)}getColumns(){return this.columnModel.getAllPrimaryColumns()}applyColumnState(e){return this.columnModel.applyColumnState(e,"api")}getColumnState(){return this.columnModel.getColumnState()}resetColumnState(){this.columnModel.resetColumnState("api")}getColumnGroupState(){return this.columnModel.getColumnGroupState()}setColumnGroupState(e){this.columnModel.setColumnGroupState(e,"api")}resetColumnGroupState(){this.columnModel.resetColumnGroupState("api")}isPinning(){return this.columnModel.isPinningLeft()||this.columnModel.isPinningRight()}isPinningLeft(){return this.columnModel.isPinningLeft()}isPinningRight(){return this.columnModel.isPinningRight()}getDisplayedColAfter(e){return this.columnModel.getDisplayedColAfter(e)}getDisplayedColBefore(e){return this.columnModel.getDisplayedColBefore(e)}setColumnVisible(e,t){this.logDeprecation("v31.1","setColumnVisible(key,visible)","setColumnsVisible([key],visible)"),this.columnModel.setColumnsVisible([e],t,"api")}setColumnsVisible(e,t){this.columnModel.setColumnsVisible(e,t,"api")}setColumnPinned(e,t){this.logDeprecation("v31.1","setColumnPinned(key,pinned)","setColumnsPinned([key],pinned)"),this.columnModel.setColumnsPinned([e],t,"api")}setColumnsPinned(e,t){this.columnModel.setColumnsPinned(e,t,"api")}getAllGridColumns(){return this.columnModel.getAllGridColumns()}getDisplayedLeftColumns(){return this.columnModel.getDisplayedLeftColumns()}getDisplayedCenterColumns(){return this.columnModel.getDisplayedCenterColumns()}getDisplayedRightColumns(){return this.columnModel.getDisplayedRightColumns()}getAllDisplayedColumns(){return this.columnModel.getAllDisplayedColumns()}getAllDisplayedVirtualColumns(){return this.columnModel.getViewportColumns()}moveColumn(e,t){this.logDeprecation("v31.1","moveColumn(key, toIndex)","moveColumns([key], toIndex)"),this.columnModel.moveColumns([e],t,"api")}moveColumnByIndex(e,t){this.columnModel.moveColumnByIndex(e,t,"api")}moveColumns(e,t){this.columnModel.moveColumns(e,t,"api")}moveRowGroupColumn(e,t){this.columnModel.moveRowGroupColumn(e,t,"api")}setColumnAggFunc(e,t){this.columnModel.setColumnAggFunc(e,t,"api")}setColumnWidth(e,t,i=!0,r="api"){this.logDeprecation("v31.1","setColumnWidth(col, width)","setColumnWidths([{key: col, newWidth: width}])"),this.columnModel.setColumnWidths([{key:e,newWidth:t}],!1,i,r)}setColumnWidths(e,t=!0,i="api"){this.columnModel.setColumnWidths(e,!1,t,i)}isPivotMode(){return this.columnModel.isPivotMode()}getPivotResultColumn(e,t){return this.columnModel.getSecondaryPivotColumn(e,t)}setValueColumns(e){this.columnModel.setValueColumns(e,"api")}getValueColumns(){return this.columnModel.getValueColumns()}removeValueColumn(e){this.logDeprecation("v31.1","removeValueColumn(colKey)","removeValueColumns([colKey])"),this.columnModel.removeValueColumns([e],"api")}removeValueColumns(e){this.columnModel.removeValueColumns(e,"api")}addValueColumn(e){this.logDeprecation("v31.1","addValueColumn(colKey)","addValueColumns([colKey])"),this.columnModel.addValueColumns([e],"api")}addValueColumns(e){this.columnModel.addValueColumns(e,"api")}setRowGroupColumns(e){this.columnModel.setRowGroupColumns(e,"api")}removeRowGroupColumn(e){this.logDeprecation("v31.1","removeRowGroupColumn(colKey)","removeRowGroupColumns([colKey])"),this.columnModel.removeRowGroupColumns([e],"api")}removeRowGroupColumns(e){this.columnModel.removeRowGroupColumns(e,"api")}addRowGroupColumn(e){this.logDeprecation("v31.1","addRowGroupColumn(colKey)","addRowGroupColumns([colKey])"),this.columnModel.addRowGroupColumns([e],"api")}addRowGroupColumns(e){this.columnModel.addRowGroupColumns(e,"api")}getRowGroupColumns(){return this.columnModel.getRowGroupColumns()}setPivotColumns(e){this.columnModel.setPivotColumns(e,"api")}removePivotColumn(e){this.logDeprecation("v31.1","removePivotColumn(colKey)","removePivotColumns([colKey])"),this.columnModel.removePivotColumns([e],"api")}removePivotColumns(e){this.columnModel.removePivotColumns(e,"api")}addPivotColumn(e){this.logDeprecation("v31.1","addPivotColumn(colKey)","addPivotColumns([colKey])"),this.columnModel.addPivotColumns([e],"api")}addPivotColumns(e){this.columnModel.addPivotColumns(e,"api")}getPivotColumns(){return this.columnModel.getPivotColumns()}getLeftDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeLeft()}getCenterDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeCentre()}getRightDisplayedColumnGroups(){return this.columnModel.getDisplayedTreeRight()}getAllDisplayedColumnGroups(){return this.columnModel.getAllDisplayedTrees()}autoSizeColumn(e,t){return this.logDeprecation("v31.1","autoSizeColumn(key, skipHeader)","autoSizeColumns([key], skipHeader)"),this.columnModel.autoSizeColumns({columns:[e],skipHeader:t,source:"api"})}autoSizeColumns(e,t){this.columnModel.autoSizeColumns({columns:e,skipHeader:t,source:"api"})}autoSizeAllColumns(e){this.columnModel.autoSizeAllColumns("api",e)}setPivotResultColumns(e){this.columnModel.setSecondaryColumns(e,"api")}getPivotResultColumns(){return this.columnModel.getSecondaryColumns()}getState(){return this.stateService.getState()}getGridOption(e){return this.gos.get(e)}setGridOption(e,t){this.updateGridOptions({[e]:t})}updateGridOptions(e){this.gos.updateGridOptions({options:e})}__internalUpdateGridOptions(e,t){this.gos.updateGridOptions({options:e,force:t,source:"gridOptionsUpdated"})}deprecatedUpdateGridOption(e,t){z(`set${e.charAt(0).toUpperCase()}${e.slice(1,e.length)} is deprecated. Please use 'api.setGridOption('${e}', newValue)' or 'api.updateGridOptions({ ${e}: newValue })' instead.`),this.setGridOption(e,t)}setPivotMode(e){this.deprecatedUpdateGridOption("pivotMode",e)}setPinnedTopRowData(e){this.deprecatedUpdateGridOption("pinnedTopRowData",e)}setPinnedBottomRowData(e){this.deprecatedUpdateGridOption("pinnedBottomRowData",e)}setPopupParent(e){this.deprecatedUpdateGridOption("popupParent",e)}setSuppressModelUpdateAfterUpdateTransaction(e){this.deprecatedUpdateGridOption("suppressModelUpdateAfterUpdateTransaction",e)}setDataTypeDefinitions(e){this.deprecatedUpdateGridOption("dataTypeDefinitions",e)}setPagination(e){this.deprecatedUpdateGridOption("pagination",e)}paginationSetPageSize(e){this.deprecatedUpdateGridOption("paginationPageSize",e)}setSideBar(e){this.deprecatedUpdateGridOption("sideBar",e)}setSuppressClipboardPaste(e){this.deprecatedUpdateGridOption("suppressClipboardPaste",e)}setGroupRemoveSingleChildren(e){this.deprecatedUpdateGridOption("groupRemoveSingleChildren",e)}setGroupRemoveLowestSingleChildren(e){this.deprecatedUpdateGridOption("groupRemoveLowestSingleChildren",e)}setGroupDisplayType(e){this.deprecatedUpdateGridOption("groupDisplayType",e)}setGroupIncludeFooter(e){this.deprecatedUpdateGridOption("groupIncludeFooter",e)}setGroupIncludeTotalFooter(e){this.deprecatedUpdateGridOption("groupIncludeTotalFooter",e)}setRowClass(e){this.deprecatedUpdateGridOption("rowClass",e)}setDeltaSort(e){this.deprecatedUpdateGridOption("deltaSort",e)}setSuppressRowDrag(e){this.deprecatedUpdateGridOption("suppressRowDrag",e)}setSuppressMoveWhenRowDragging(e){this.deprecatedUpdateGridOption("suppressMoveWhenRowDragging",e)}setSuppressRowClickSelection(e){this.deprecatedUpdateGridOption("suppressRowClickSelection",e)}setEnableAdvancedFilter(e){this.deprecatedUpdateGridOption("enableAdvancedFilter",e)}setIncludeHiddenColumnsInAdvancedFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInAdvancedFilter",e)}setAdvancedFilterParent(e){this.deprecatedUpdateGridOption("advancedFilterParent",e)}setAdvancedFilterBuilderParams(e){this.deprecatedUpdateGridOption("advancedFilterBuilderParams",e)}setQuickFilter(e){z("setQuickFilter is deprecated. Please use 'api.setGridOption('quickFilterText', newValue)' or 'api.updateGridOptions({ quickFilterText: newValue })' instead."),this.gos.updateGridOptions({options:{quickFilterText:e}})}setExcludeHiddenColumnsFromQuickFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInQuickFilter",!e)}setIncludeHiddenColumnsInQuickFilter(e){this.deprecatedUpdateGridOption("includeHiddenColumnsInQuickFilter",e)}setQuickFilterParser(e){this.deprecatedUpdateGridOption("quickFilterParser",e)}setQuickFilterMatcher(e){this.deprecatedUpdateGridOption("quickFilterMatcher",e)}setAlwaysShowHorizontalScroll(e){this.deprecatedUpdateGridOption("alwaysShowHorizontalScroll",e)}setAlwaysShowVerticalScroll(e){this.deprecatedUpdateGridOption("alwaysShowVerticalScroll",e)}setFunctionsReadOnly(e){this.deprecatedUpdateGridOption("functionsReadOnly",e)}setColumnDefs(e,t="api"){z("setColumnDefs is deprecated. Please use 'api.setGridOption('columnDefs', newValue)' or 'api.updateGridOptions({ columnDefs: newValue })' instead."),this.gos.updateGridOptions({options:{columnDefs:e},source:t})}setAutoGroupColumnDef(e,t="api"){z("setAutoGroupColumnDef is deprecated. Please use 'api.setGridOption('autoGroupColumnDef', newValue)' or 'api.updateGridOptions({ autoGroupColumnDef: newValue })' instead."),this.gos.updateGridOptions({options:{autoGroupColumnDef:e},source:t})}setDefaultColDef(e,t="api"){z("setDefaultColDef is deprecated. Please use 'api.setGridOption('defaultColDef', newValue)' or 'api.updateGridOptions({ defaultColDef: newValue })' instead."),this.gos.updateGridOptions({options:{defaultColDef:e},source:t})}setColumnTypes(e,t="api"){z("setColumnTypes is deprecated. Please use 'api.setGridOption('columnTypes', newValue)' or 'api.updateGridOptions({ columnTypes: newValue })' instead."),this.gos.updateGridOptions({options:{columnTypes:e},source:t})}setTreeData(e){this.deprecatedUpdateGridOption("treeData",e)}setServerSideDatasource(e){this.deprecatedUpdateGridOption("serverSideDatasource",e)}setCacheBlockSize(e){this.deprecatedUpdateGridOption("cacheBlockSize",e)}setDatasource(e){this.deprecatedUpdateGridOption("datasource",e)}setViewportDatasource(e){this.deprecatedUpdateGridOption("viewportDatasource",e)}setRowData(e){this.deprecatedUpdateGridOption("rowData",e)}setEnableCellTextSelection(e){this.deprecatedUpdateGridOption("enableCellTextSelection",e)}setHeaderHeight(e){this.deprecatedUpdateGridOption("headerHeight",e)}setDomLayout(e){this.deprecatedUpdateGridOption("domLayout",e)}setFillHandleDirection(e){this.deprecatedUpdateGridOption("fillHandleDirection",e)}setGroupHeaderHeight(e){this.deprecatedUpdateGridOption("groupHeaderHeight",e)}setFloatingFiltersHeight(e){this.deprecatedUpdateGridOption("floatingFiltersHeight",e)}setPivotHeaderHeight(e){this.deprecatedUpdateGridOption("pivotHeaderHeight",e)}setPivotGroupHeaderHeight(e){this.deprecatedUpdateGridOption("pivotGroupHeaderHeight",e)}setAnimateRows(e){this.deprecatedUpdateGridOption("animateRows",e)}setIsExternalFilterPresent(e){this.deprecatedUpdateGridOption("isExternalFilterPresent",e)}setDoesExternalFilterPass(e){this.deprecatedUpdateGridOption("doesExternalFilterPass",e)}setNavigateToNextCell(e){this.deprecatedUpdateGridOption("navigateToNextCell",e)}setTabToNextCell(e){this.deprecatedUpdateGridOption("tabToNextCell",e)}setTabToNextHeader(e){this.deprecatedUpdateGridOption("tabToNextHeader",e)}setNavigateToNextHeader(e){this.deprecatedUpdateGridOption("navigateToNextHeader",e)}setRowGroupPanelShow(e){this.deprecatedUpdateGridOption("rowGroupPanelShow",e)}setGetGroupRowAgg(e){this.deprecatedUpdateGridOption("getGroupRowAgg",e)}setGetBusinessKeyForNode(e){this.deprecatedUpdateGridOption("getBusinessKeyForNode",e)}setGetChildCount(e){this.deprecatedUpdateGridOption("getChildCount",e)}setProcessRowPostCreate(e){this.deprecatedUpdateGridOption("processRowPostCreate",e)}setGetRowId(e){z("getRowId is a static property and can no longer be updated.")}setGetRowClass(e){this.deprecatedUpdateGridOption("getRowClass",e)}setIsFullWidthRow(e){this.deprecatedUpdateGridOption("isFullWidthRow",e)}setIsRowSelectable(e){this.deprecatedUpdateGridOption("isRowSelectable",e)}setIsRowMaster(e){this.deprecatedUpdateGridOption("isRowMaster",e)}setPostSortRows(e){this.deprecatedUpdateGridOption("postSortRows",e)}setGetDocument(e){this.deprecatedUpdateGridOption("getDocument",e)}setGetContextMenuItems(e){this.deprecatedUpdateGridOption("getContextMenuItems",e)}setGetMainMenuItems(e){this.deprecatedUpdateGridOption("getMainMenuItems",e)}setProcessCellForClipboard(e){this.deprecatedUpdateGridOption("processCellForClipboard",e)}setSendToClipboard(e){this.deprecatedUpdateGridOption("sendToClipboard",e)}setProcessCellFromClipboard(e){this.deprecatedUpdateGridOption("processCellFromClipboard",e)}setProcessPivotResultColDef(e){this.deprecatedUpdateGridOption("processPivotResultColDef",e)}setProcessPivotResultColGroupDef(e){this.deprecatedUpdateGridOption("processPivotResultColGroupDef",e)}setPostProcessPopup(e){this.deprecatedUpdateGridOption("postProcessPopup",e)}setInitialGroupOrderComparator(e){this.deprecatedUpdateGridOption("initialGroupOrderComparator",e)}setGetChartToolbarItems(e){this.deprecatedUpdateGridOption("getChartToolbarItems",e)}setPaginationNumberFormatter(e){this.deprecatedUpdateGridOption("paginationNumberFormatter",e)}setGetServerSideGroupLevelParams(e){this.deprecatedUpdateGridOption("getServerSideGroupLevelParams",e)}setIsServerSideGroupOpenByDefault(e){this.deprecatedUpdateGridOption("isServerSideGroupOpenByDefault",e)}setIsApplyServerSideTransaction(e){this.deprecatedUpdateGridOption("isApplyServerSideTransaction",e)}setIsServerSideGroup(e){this.deprecatedUpdateGridOption("isServerSideGroup",e)}setGetServerSideGroupKey(e){this.deprecatedUpdateGridOption("getServerSideGroupKey",e)}setGetRowStyle(e){this.deprecatedUpdateGridOption("getRowStyle",e)}setGetRowHeight(e){this.deprecatedUpdateGridOption("getRowHeight",e)}};g([ue("rowRenderer")],zo.prototype,"rowRenderer",2),g([ue("navigationService")],zo.prototype,"navigationService",2),g([ue("filterManager")],zo.prototype,"filterManager",2),g([ue("columnModel")],zo.prototype,"columnModel",2),g([ue("selectionService")],zo.prototype,"selectionService",2),g([ue("gridOptionsService")],zo.prototype,"gos",2),g([ue("valueService")],zo.prototype,"valueService",2),g([ue("alignedGridsService")],zo.prototype,"alignedGridsService",2),g([ue("eventService")],zo.prototype,"eventService",2),g([ue("pinnedRowModel")],zo.prototype,"pinnedRowModel",2),g([ue("context")],zo.prototype,"context",2),g([ue("rowModel")],zo.prototype,"rowModel",2),g([ue("sortController")],zo.prototype,"sortController",2),g([ue("paginationProxy")],zo.prototype,"paginationProxy",2),g([ue("focusService")],zo.prototype,"focusService",2),g([ue("dragAndDropService")],zo.prototype,"dragAndDropService",2),g([ue("menuService")],zo.prototype,"menuService",2),g([ue("valueCache")],zo.prototype,"valueCache",2),g([ue("animationFrameService")],zo.prototype,"animationFrameService",2),g([ue("ctrlsService")],zo.prototype,"ctrlsService",2),g([ue("overlayService")],zo.prototype,"overlayService",2),g([ue("stateService")],zo.prototype,"stateService",2),g([ue("expansionService")],zo.prototype,"expansionService",2),g([ue("apiEventService")],zo.prototype,"apiEventService",2),g([ue("frameworkOverrides")],zo.prototype,"frameworkOverrides",2),g([ue("undoRedoService")],zo.prototype,"undoRedoService",2),g([ue("rowNodeBlockLoader")],zo.prototype,"rowNodeBlockLoader",2),g([he("csvCreator")],zo.prototype,"csvCreator",2),g([he("excelCreator")],zo.prototype,"excelCreator",2),g([he("rangeService")],zo.prototype,"rangeService",2),g([he("clipboardService")],zo.prototype,"clipboardService",2),g([he("aggFuncService")],zo.prototype,"aggFuncService",2),g([he("statusBarService")],zo.prototype,"statusBarService",2),g([he("chartService")],zo.prototype,"chartService",2),g([he("ssrmTransactionManager")],zo.prototype,"serverSideTransactionManager",2),g([he("sideBarService")],zo.prototype,"sideBarService",2),g([ae],zo.prototype,"init",1),zo=g([ce("gridApi")],zo);var Uo=class extends rt{constructor(){super(...arguments),this.quickFilter=null,this.quickFilterParts=null}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.resetQuickFilterCache()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VISIBLE,()=>{this.gos.get("includeHiddenColumnsInQuickFilter")||this.resetQuickFilterCache()}),this.addManagedPropertyListener("quickFilterText",e=>this.setQuickFilter(e.currentValue)),this.addManagedPropertyListeners(["includeHiddenColumnsInQuickFilter","applyQuickFilterBeforePivotOrAgg"],()=>this.onQuickFilterColumnConfigChanged()),this.quickFilter=this.parseQuickFilter(this.gos.get("quickFilterText")),this.parser=this.gos.get("quickFilterParser"),this.matcher=this.gos.get("quickFilterMatcher"),this.setQuickFilterParts(),this.addManagedPropertyListeners(["quickFilterMatcher","quickFilterParser"],()=>this.setQuickFilterParserAndMatcher())}isQuickFilterPresent(){return null!==this.quickFilter}doesRowPassQuickFilter(e){const t=this.gos.get("cacheQuickFilter");return this.matcher?this.doesRowPassQuickFilterMatcher(t,e):this.quickFilterParts.every(i=>t?this.doesRowPassQuickFilterCache(e,i):this.doesRowPassQuickFilterNoCache(e,i))}resetQuickFilterCache(){this.rowModel.forEachNode(e=>e.quickFilterAggregateText=null)}setQuickFilterParts(){const{quickFilter:e,parser:t}=this;this.quickFilterParts=e?t?t(e):e.split(" "):null}parseQuickFilter(e){return C(e)?this.gos.isRowModelType("clientSide")?e.toUpperCase():(console.warn("AG Grid - Quick filtering only works with the Client-Side Row Model"),null):null}setQuickFilter(e){if(null!=e&&"string"!=typeof e)return void console.warn("AG Grid - Grid option quickFilterText only supports string inputs, received: "+typeof e);const t=this.parseQuickFilter(e);this.quickFilter!==t&&(this.quickFilter=t,this.setQuickFilterParts(),this.dispatchEvent({type:Uo.EVENT_QUICK_FILTER_CHANGED}))}setQuickFilterParserAndMatcher(){const e=this.gos.get("quickFilterParser"),t=this.gos.get("quickFilterMatcher"),i=e!==this.parser||t!==this.matcher;this.parser=e,this.matcher=t,i&&(this.setQuickFilterParts(),this.dispatchEvent({type:Uo.EVENT_QUICK_FILTER_CHANGED}))}onQuickFilterColumnConfigChanged(){this.columnModel.refreshQuickFilterColumns(),this.resetQuickFilterCache(),this.isQuickFilterPresent()&&this.dispatchEvent({type:Uo.EVENT_QUICK_FILTER_CHANGED})}doesRowPassQuickFilterNoCache(e,t){return this.columnModel.getAllColumnsForQuickFilter().some(i=>{const r=this.getQuickFilterTextForColumn(i,e);return C(r)&&r.indexOf(t)>=0})}doesRowPassQuickFilterCache(e,t){return this.checkGenerateQuickFilterAggregateText(e),e.quickFilterAggregateText.indexOf(t)>=0}doesRowPassQuickFilterMatcher(e,t){let i;e?(this.checkGenerateQuickFilterAggregateText(t),i=t.quickFilterAggregateText):i=this.getQuickFilterAggregateText(t);const{quickFilterParts:r,matcher:n}=this;return n(r,i)}checkGenerateQuickFilterAggregateText(e){e.quickFilterAggregateText||(e.quickFilterAggregateText=this.getQuickFilterAggregateText(e))}getQuickFilterTextForColumn(e,t){let i=this.valueService.getValue(e,t,!0);const r=e.getColDef();if(r.getQuickFilterText){const n=this.gos.addGridCommonParams({value:i,node:t,data:t.data,column:e,colDef:r});i=r.getQuickFilterText(n)}return C(i)?i.toString().toUpperCase():null}getQuickFilterAggregateText(e){const t=[];return this.columnModel.getAllColumnsForQuickFilter().forEach(i=>{const r=this.getQuickFilterTextForColumn(i,e);C(r)&&t.push(r)}),t.join(Uo.QUICK_FILTER_SEPARATOR)}};Uo.EVENT_QUICK_FILTER_CHANGED="quickFilterChanged",Uo.QUICK_FILTER_SEPARATOR="\n",g([ue("valueService")],Uo.prototype,"valueService",2),g([ue("columnModel")],Uo.prototype,"columnModel",2),g([ue("rowModel")],Uo.prototype,"rowModel",2),g([ae],Uo.prototype,"postConstruct",1),Uo=g([ce("quickFilterService")],Uo);var Wo=class extends rt{constructor(){super(...arguments),this.allColumnFilters=new Map,this.allColumnListeners=new Map,this.activeAggregateFilters=[],this.activeColumnFilters=[],this.processingFilterChange=!1,this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue=[],this.advancedFilterModelUpdateQueue=[]}init(){var e,t,i;this.addManagedListener(this.eventService,lt.EVENT_GRID_COLUMNS_CHANGED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VALUE_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.refreshFiltersForAggregations()),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.updateAdvancedFilterColumns()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VISIBLE,()=>this.updateAdvancedFilterColumns()),this.addManagedListener(this.eventService,lt.EVENT_ROW_DATA_UPDATED,()=>this.onNewRowsLoaded("rowDataUpdated")),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.addManagedPropertyListeners(["isExternalFilterPresent","doesExternalFilterPass"],()=>{this.onFilterChanged({source:"api"})}),this.updateAggFiltering(),this.addManagedPropertyListener("groupAggFiltering",()=>{this.updateAggFiltering(),this.onFilterChanged()}),this.addManagedPropertyListener("advancedFilterModel",e=>this.setAdvancedFilterModel(e.currentValue)),this.addManagedListener(this.eventService,lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,({enabled:e})=>this.onAdvancedFilterEnabledChanged(e)),this.addManagedListener(this.eventService,lt.EVENT_DATA_TYPES_INFERRED,()=>this.processFilterModelUpdateQueue()),this.addManagedListener(this.quickFilterService,Uo.EVENT_QUICK_FILTER_CHANGED,()=>this.onFilterChanged({source:"quickFilter"})),this.initialFilterModel=h({},null!=(i=null==(t=null==(e=this.gos.get("initialState"))?void 0:e.filter)?void 0:t.filterModel)?i:{})}isExternalFilterPresentCallback(){const e=this.gos.getCallback("isExternalFilterPresent");return"function"==typeof e&&e({})}doesExternalFilterPass(e){const t=this.gos.get("doesExternalFilterPass");return"function"==typeof t&&t(e)}setFilterModel(e,t="api"){if(this.isAdvancedFilterEnabled())return void this.warnAdvancedFilters();if(this.dataTypeService.isPendingInference())return void this.filterModelUpdateQueue.push({model:e,source:t});const i=[],r=this.getFilterModel();if(e){const t=an(Object.keys(e));this.allColumnFilters.forEach((r,n)=>{const s=e[n];i.push(this.setModelOnFilterWrapper(r.filterPromise,s)),t.delete(n)}),t.forEach(t=>{const r=this.columnModel.getPrimaryColumn(t)||this.columnModel.getGridColumn(t);if(!r)return void console.warn("AG Grid: setFilterModel() - no column found for colId: "+t);if(!r.isFilterAllowed())return void console.warn("AG Grid: setFilterModel() - unable to fully apply model, filtering disabled for colId: "+t);const n=this.getOrCreateFilterWrapper(r,"NO_UI");n?i.push(this.setModelOnFilterWrapper(n.filterPromise,e[t])):console.warn("AG-Grid: setFilterModel() - unable to fully apply model, unable to create filter for colId: "+t)})}else this.allColumnFilters.forEach(e=>{i.push(this.setModelOnFilterWrapper(e.filterPromise,null))});hn.all(i).then(()=>{const e=this.getFilterModel(),i=[];this.allColumnFilters.forEach((t,n)=>{const s=r?r[n]:null,o=e?e[n]:null;ln.jsonEquals(s,o)||i.push(t.column)}),i.length>0&&this.onFilterChanged({columns:i,source:t})})}setModelOnFilterWrapper(e,t){return new hn(i=>{e.then(e=>{"function"!=typeof e.setModel&&(console.warn("AG Grid: filter missing setModel method, which is needed for setFilterModel"),i()),(e.setModel(t)||hn.resolve()).then(()=>i())})})}getFilterModel(){const e={};return this.allColumnFilters.forEach((t,i)=>{const r=this.getModelFromFilterWrapper(t);C(r)&&(e[i]=r)}),e}getModelFromFilterWrapper(e){var t;const i=e.filterPromise.resolveNow(null,e=>e);return null==i?null!=(t=this.initialFilterModel[e.column.getColId()])?t:null:"function"!=typeof i.getModel?(console.warn("AG Grid: filter API missing getModel method, which is needed for getFilterModel"),null):i.getModel()}isColumnFilterPresent(){return this.activeColumnFilters.length>0}isAggregateFilterPresent(){return!!this.activeAggregateFilters.length}isExternalFilterPresent(){return this.externalFilterPresent}isChildFilterPresent(){return this.isColumnFilterPresent()||this.isQuickFilterPresent()||this.isExternalFilterPresent()||this.isAdvancedFilterPresent()}isAdvancedFilterPresent(){return this.isAdvancedFilterEnabled()&&this.advancedFilterService.isFilterPresent()}onAdvancedFilterEnabledChanged(e){var t;e?this.allColumnFilters.size&&(this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"advancedFilterEnabled")),this.onFilterChanged({source:"advancedFilter"})):(null==(t=this.advancedFilterService)?void 0:t.isFilterPresent())&&(this.advancedFilterService.setModel(null),this.onFilterChanged({source:"advancedFilter"}))}isAdvancedFilterEnabled(){var e;return!!(null==(e=this.advancedFilterService)?void 0:e.isEnabled())}isAdvancedFilterHeaderActive(){return this.isAdvancedFilterEnabled()&&this.advancedFilterService.isHeaderActive()}doAggregateFiltersPass(e,t){return this.doColumnFiltersPass(e,t,!0)}updateActiveFilters(){this.activeColumnFilters.length=0,this.activeAggregateFilters.length=0;const e=e=>!!e&&(e.isFilterActive?e.isFilterActive():(console.warn("AG Grid: Filter is missing isFilterActive() method"),!1)),t=!!this.gos.getGroupAggFiltering(),i=e=>{if(!e.isPrimary())return!0;const i=!this.columnModel.isPivotActive();return!(!e.isValueActive()||!i)&&(!!this.columnModel.isPivotMode()||t)};this.allColumnFilters.forEach(t=>{if(t.filterPromise.resolveNow(!1,e)){const e=t.filterPromise.resolveNow(null,e=>e);i(t.column)?this.activeAggregateFilters.push(e):this.activeColumnFilters.push(e)}})}updateFilterFlagInColumns(e,t){this.allColumnFilters.forEach(i=>{const r=i.filterPromise.resolveNow(!1,e=>e.isFilterActive());i.column.setFilterActive(r,e,t)})}isAnyFilterPresent(){return this.isQuickFilterPresent()||this.isColumnFilterPresent()||this.isAggregateFilterPresent()||this.isExternalFilterPresent()||this.isAdvancedFilterPresent()}doColumnFiltersPass(e,t,i){const{data:r,aggData:n}=e,s=i?this.activeAggregateFilters:this.activeColumnFilters,o=i?n:r;for(let i=0;i<s.length;i++){const r=s[i];if(null!=r&&r!==t){if("function"!=typeof r.doesFilterPass)throw new Error("Filter is missing method doesFilterPass");if(!r.doesFilterPass({node:e,data:o}))return!1}}return!0}resetQuickFilterCache(){this.quickFilterService.resetQuickFilterCache()}refreshFiltersForAggregations(){this.gos.getGroupAggFiltering()&&this.onFilterChanged()}callOnFilterChangedOutsideRenderCycle(e){const t=()=>this.onFilterChanged(e);this.rowRenderer.isRefreshInProgress()?setTimeout(t,0):t()}onFilterChanged(e={}){const{source:t,filterInstance:i,additionalEventAttributes:r,columns:n}=e;this.updateDependantFilters(),this.updateActiveFilters(),this.updateFilterFlagInColumns("filterChanged",r),this.externalFilterPresent=this.isExternalFilterPresentCallback(),this.allColumnFilters.forEach(e=>{e.filterPromise&&e.filterPromise.then(e=>{e&&e!==i&&e.onAnyFilterChanged&&e.onAnyFilterChanged()})});const s={source:t,type:lt.EVENT_FILTER_CHANGED,columns:n||[]};r&&O(s,r),this.processingFilterChange=!0,this.eventService.dispatchEvent(s),this.processingFilterChange=!1}isSuppressFlashingCellsBecauseFiltering(){var e;return!(null!=(e=this.gos.get("allowShowChangeAfterFilter"))&&e)&&this.processingFilterChange}isQuickFilterPresent(){return this.quickFilterService.isQuickFilterPresent()}updateAggFiltering(){this.aggFiltering=!!this.gos.getGroupAggFiltering()}isAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&this.shouldApplyQuickFilterAfterAgg()}isNonAggregateQuickFilterPresent(){return this.isQuickFilterPresent()&&!this.shouldApplyQuickFilterAfterAgg()}shouldApplyQuickFilterAfterAgg(){return(this.aggFiltering||this.columnModel.isPivotMode())&&!this.gos.get("applyQuickFilterBeforePivotOrAgg")}doesRowPassOtherFilters(e,t){return this.doesRowPassFilter({rowNode:t,filterInstanceToSkip:e})}doesRowPassAggregateFilters(e){return!(this.isAggregateQuickFilterPresent()&&!this.quickFilterService.doesRowPassQuickFilter(e.rowNode)||this.isAggregateFilterPresent()&&!this.doAggregateFiltersPass(e.rowNode,e.filterInstanceToSkip))}doesRowPassFilter(e){return!(this.isNonAggregateQuickFilterPresent()&&!this.quickFilterService.doesRowPassQuickFilter(e.rowNode)||this.isExternalFilterPresent()&&!this.doesExternalFilterPass(e.rowNode)||this.isColumnFilterPresent()&&!this.doColumnFiltersPass(e.rowNode,e.filterInstanceToSkip)||this.isAdvancedFilterPresent()&&!this.advancedFilterService.doesFilterPass(e.rowNode))}onNewRowsLoaded(e){this.allColumnFilters.forEach(e=>{e.filterPromise.then(e=>{e.onNewRowsLoaded&&e.onNewRowsLoaded()})}),this.updateFilterFlagInColumns(e,{afterDataChange:!0}),this.updateActiveFilters()}createValueGetter(e){return({node:t})=>this.valueService.getValue(e,t,!0)}createGetValue(e){return(t,i)=>{const r=i?this.columnModel.getGridColumn(i):e;return r?this.valueService.getValue(r,t,!0):void 0}}getFilterComponent(e,t,i=!0){var r;if(i)return(null==(r=this.getOrCreateFilterWrapper(e,t))?void 0:r.filterPromise)||null;const n=this.cachedFilter(e);return n?n.filterPromise:null}isFilterActive(e){const t=this.cachedFilter(e);return!!t&&t.filterPromise.resolveNow(!1,e=>e.isFilterActive())}getOrCreateFilterWrapper(e,t){if(!e.isFilterAllowed())return null;let i=this.cachedFilter(e);return i||(i=this.createFilterWrapper(e,t),this.setColumnFilterWrapper(e,i)),i}cachedFilter(e){return this.allColumnFilters.get(e.getColId())}getDefaultFilter(e){let t;if(ne.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()))t="agSetColumnFilter";else{const i=this.dataTypeService.getBaseDataType(e);t="number"===i?"agNumberColumnFilter":"date"===i||"dateString"===i?"agDateColumnFilter":"agTextColumnFilter"}return t}getDefaultFloatingFilter(e){let t;if(ne.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()))t="agSetColumnFloatingFilter";else{const i=this.dataTypeService.getBaseDataType(e);t="number"===i?"agNumberColumnFloatingFilter":"date"===i||"dateString"===i?"agDateColumnFloatingFilter":"agTextColumnFloatingFilter"}return t}createFilterInstance(e){const t=this.getDefaultFilter(e),i=e.getColDef();let r;const n=d(h({},this.createFilterParams(e,i)),{filterModifiedCallback:()=>this.filterModifiedCallbackFactory(r,e)(),filterChangedCallback:t=>this.filterChangedCallbackFactory(r,e)(t),doesRowPassOtherFilter:e=>this.doesRowPassOtherFilters(r,e)}),s=this.userComponentFactory.getFilterDetails(i,n,t);return s?{filterPromise:()=>{const e=s.newAgStackInstance();return e&&e.then(e=>r=e),e},compDetails:s}:{filterPromise:null,compDetails:null}}createFilterParams(e,t){return this.gos.addGridCommonParams({column:e,colDef:I(t),rowModel:this.rowModel,filterChangedCallback:()=>{},filterModifiedCallback:()=>{},valueGetter:this.createValueGetter(e),getValue:this.createGetValue(e),doesRowPassOtherFilter:()=>!0})}createFilterWrapper(e,t){var i;const r={column:e,filterPromise:null,compiledElement:null,compDetails:null},{filterPromise:n,compDetails:s}=this.createFilterInstance(e);return r.filterPromise=null!=(i=null==n?void 0:n())?i:null,r.compDetails=s,r}onColumnsChanged(){const e=[];this.allColumnFilters.forEach((t,i)=>{let r;r=t.column.isPrimary()?this.columnModel.getPrimaryColumn(i):this.columnModel.getGridColumn(i),r&&r===t.column||(e.push(t.column),this.disposeFilterWrapper(t,"columnChanged"),this.disposeColumnListener(i))}),e.length>0?this.onFilterChanged({columns:e,source:"api"}):this.updateDependantFilters()}updateDependantFilters(){const e=this.columnModel.getGroupAutoColumns();null==e||e.forEach(e=>{"agGroupColumnFilter"===e.getColDef().filter&&this.getOrCreateFilterWrapper(e,"NO_UI")})}isFilterAllowed(e){var t,i;if(this.isAdvancedFilterEnabled())return!1;if(!e.isFilterAllowed())return!1;const r=this.allColumnFilters.get(e.getColId());return null==(i=null==(t=null==r?void 0:r.filterPromise)?void 0:t.resolveNow(!0,e=>"function"!=typeof(null==e?void 0:e.isFilterAllowed)||(null==e?void 0:e.isFilterAllowed())))||i}getFloatingFilterCompDetails(e,t){const i=t=>{const i=this.getFilterComponent(e,"NO_UI");null!=i&&i.then(e=>{t(Bo(e))})},r=e.getColDef(),n=d(h({},this.createFilterParams(e,r)),{filterChangedCallback:()=>i(t=>this.filterChangedCallbackFactory(t,e)())}),s=this.userComponentFactory.mergeParamsWithApplicationProvidedParams(r,Eo,n);let o=this.userComponentFactory.getDefaultFloatingFilterType(r,()=>this.getDefaultFloatingFilter(e));null==o&&(o="agReadOnlyFloatingFilter");const a={column:e,filterParams:s,currentParentModel:()=>this.getCurrentFloatingFilterParentModel(e),parentFilterInstance:i,showParentFilter:t,suppressFilterButton:!1};return this.userComponentFactory.getFloatingFilterCompDetails(r,a,o)}getCurrentFloatingFilterParentModel(e){const t=this.getFilterComponent(e,"NO_UI",!1);return t?t.resolveNow(null,e=>e&&e.getModel()):null}destroyFilter(e,t="api"){const i=e.getColId(),r=this.allColumnFilters.get(i);this.disposeColumnListener(i),delete this.initialFilterModel[i],r&&(this.disposeFilterWrapper(r,t),this.onFilterChanged({columns:[e],source:"api"}))}disposeColumnListener(e){const t=this.allColumnListeners.get(e);t&&(this.allColumnListeners.delete(e),t())}disposeFilterWrapper(e,t){e.filterPromise.then(i=>{this.getContext().destroyBean(i),e.column.setFilterActive(!1,"filterDestroyed"),this.allColumnFilters.delete(e.column.getColId());const r={type:lt.EVENT_FILTER_DESTROYED,source:t,column:e.column};this.eventService.dispatchEvent(r)})}filterModifiedCallbackFactory(e,t){return()=>{const i={type:lt.EVENT_FILTER_MODIFIED,column:t,filterInstance:e};this.eventService.dispatchEvent(i)}}filterChangedCallbackFactory(e,t){return i=>{var r;const n=null!=(r=null==i?void 0:i.source)?r:"api",s={filter:e,additionalEventAttributes:i,columns:[t],source:n};this.callOnFilterChangedOutsideRenderCycle(s)}}checkDestroyFilter(e){const t=this.allColumnFilters.get(e);if(!t)return;const i=t.column,{compDetails:r}=i.isFilterAllowed()?this.createFilterInstance(i):{compDetails:null};if(this.areFilterCompsDifferent(t.compDetails,r))return void this.destroyFilter(i,"paramsUpdated");const n=i.getColDef().filterParams;t.filterPromise?t.filterPromise.then(e=>{!1===(!(null==e?void 0:e.refresh)||e.refresh(h(d(h({},this.createFilterParams(i,i.getColDef())),{filterModifiedCallback:this.filterModifiedCallbackFactory(e,i),filterChangedCallback:this.filterChangedCallbackFactory(e,i),doesRowPassOtherFilter:t=>this.doesRowPassOtherFilters(e,t)}),n)))&&this.destroyFilter(i,"paramsUpdated")}):this.destroyFilter(i,"paramsUpdated")}setColumnFilterWrapper(e,t){const i=e.getColId();this.allColumnFilters.set(i,t),this.allColumnListeners.set(i,this.addManagedListener(e,Se.EVENT_COL_DEF_CHANGED,()=>this.checkDestroyFilter(i)))}areFilterCompsDifferent(e,t){if(!t||!e)return!0;const{componentClass:i}=e,{componentClass:r}=t;return!(i===r||(null==i?void 0:i.render)&&(null==r?void 0:r.render)&&i.render===r.render)}getAdvancedFilterModel(){return this.isAdvancedFilterEnabled()?this.advancedFilterService.getModel():null}setAdvancedFilterModel(e){this.isAdvancedFilterEnabled()&&(this.dataTypeService.isPendingInference()?this.advancedFilterModelUpdateQueue.push(e):(this.advancedFilterService.setModel(null!=e?e:null),this.onFilterChanged({source:"advancedFilter"})))}showAdvancedFilterBuilder(e){this.isAdvancedFilterEnabled()&&this.advancedFilterService.getCtrl().toggleFilterBuilder(e,!0)}updateAdvancedFilterColumns(){this.isAdvancedFilterEnabled()&&this.advancedFilterService.updateValidity()&&this.onFilterChanged({source:"advancedFilter"})}hasFloatingFilters(){return!this.isAdvancedFilterEnabled()&&this.columnModel.getAllGridColumns().some(e=>e.getColDef().floatingFilter)}getFilterInstance(e,t){if(this.isAdvancedFilterEnabled())return void this.warnAdvancedFilters();const i=this.getFilterInstanceImpl(e,e=>{if(!t)return;const i=Bo(e);t(i)});return Bo(i)}getColumnFilterInstance(e){return new Promise(t=>{this.getFilterInstance(e,e=>{t(e)})})}getFilterInstanceImpl(e,t){const i=this.columnModel.getPrimaryColumn(e);if(!i)return;const r=this.getFilterComponent(i,"NO_UI"),n=r&&r.resolveNow(null,e=>e);return n?setTimeout(t,0,n):r&&r.then(e=>{t(e)}),n}warnAdvancedFilters(){z("Column Filter API methods have been disabled as Advanced Filters are enabled.")}setupAdvancedFilterHeaderComp(e){var t;null==(t=this.advancedFilterService)||t.getCtrl().setupHeaderComp(e)}getHeaderRowCount(){return this.isAdvancedFilterHeaderActive()?1:0}getHeaderHeight(){return this.isAdvancedFilterHeaderActive()?this.advancedFilterService.getCtrl().getHeaderHeight():0}processFilterModelUpdateQueue(){this.filterModelUpdateQueue.forEach(({model:e,source:t})=>this.setFilterModel(e,t)),this.filterModelUpdateQueue=[],this.columnFilterModelUpdateQueue.forEach(({key:e,model:t,resolve:i})=>{this.setColumnFilterModel(e,t).then(()=>i())}),this.columnFilterModelUpdateQueue=[],this.advancedFilterModelUpdateQueue.forEach(e=>this.setAdvancedFilterModel(e)),this.advancedFilterModelUpdateQueue=[]}getColumnFilterModel(e){const t=this.getFilterWrapper(e);return t?this.getModelFromFilterWrapper(t):null}setColumnFilterModel(e,t){if(this.isAdvancedFilterEnabled())return this.warnAdvancedFilters(),Promise.resolve();if(this.dataTypeService.isPendingInference()){let i=()=>{};const r=new Promise(e=>{i=e});return this.columnFilterModelUpdateQueue.push({key:e,model:t,resolve:i}),r}const i=this.columnModel.getPrimaryColumn(e),r=i?this.getOrCreateFilterWrapper(i,"NO_UI"):null;return r?(n=this.setModelOnFilterWrapper(r.filterPromise,t),new Promise(e=>{n.then(t=>e(t))})):Promise.resolve();var n}getFilterWrapper(e){var t;const i=this.columnModel.getPrimaryColumn(e);return i&&null!=(t=this.cachedFilter(i))?t:null}destroy(){super.destroy(),this.allColumnFilters.forEach(e=>this.disposeFilterWrapper(e,"gridDestroyed")),this.allColumnListeners.clear()}};g([ue("valueService")],Wo.prototype,"valueService",2),g([ue("columnModel")],Wo.prototype,"columnModel",2),g([ue("rowModel")],Wo.prototype,"rowModel",2),g([ue("userComponentFactory")],Wo.prototype,"userComponentFactory",2),g([ue("rowRenderer")],Wo.prototype,"rowRenderer",2),g([ue("dataTypeService")],Wo.prototype,"dataTypeService",2),g([ue("quickFilterService")],Wo.prototype,"quickFilterService",2),g([he("advancedFilterService")],Wo.prototype,"advancedFilterService",2),g([ae],Wo.prototype,"init",1),Wo=g([ce("filterManager")],Wo);var jo=class extends yn{constructor(e,t){super('<div class="ag-filter"></div>'),this.column=e,this.source=t,this.filterWrapper=null}postConstruct(){this.createFilter(!0),this.addManagedListener(this.eventService,lt.EVENT_FILTER_DESTROYED,this.onFilterDestroyed.bind(this))}hasFilter(){return!!this.filterWrapper}getFilter(){var e,t;return null!=(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)?t:null}afterInit(){var e,t,i;return null!=(i=null==(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)?void 0:t.then(()=>{}))?i:hn.resolve()}afterGuiAttached(e){var t,i;null==(i=null==(t=this.filterWrapper)?void 0:t.filterPromise)||i.then(t=>{var i;null==(i=null==t?void 0:t.afterGuiAttached)||i.call(t,e)})}afterGuiDetached(){var e,t;null==(t=null==(e=this.filterWrapper)?void 0:e.filterPromise)||t.then(e=>{var t;null==(t=null==e?void 0:e.afterGuiDetached)||t.call(e)})}createFilter(e){var t;const{column:i,source:r}=this;this.filterWrapper=this.filterManager.getOrCreateFilterWrapper(i,r),(null==(t=this.filterWrapper)?void 0:t.filterPromise)&&this.filterWrapper.filterPromise.then(t=>{let n=t.getGui();if(C(n)||console.warn(`AG Grid: getGui method from filter returned ${n}, it should be a DOM element or an HTML template string.`),"string"==typeof n&&(n=br(n)),this.appendChild(n),e){const e={type:lt.EVENT_FILTER_OPENED,column:i,source:r,eGui:this.getGui()};this.eventService.dispatchEvent(e)}})}onFilterDestroyed(e){"api"!==e.source&&"paramsUpdated"!==e.source||e.column.getId()!==this.column.getId()||!this.columnModel.getPrimaryColumn(this.column)||(Cr(this.getGui()),this.createFilter())}destroy(){this.filterWrapper=null,super.destroy()}};g([ue("filterManager")],jo.prototype,"filterManager",2),g([ue("columnModel")],jo.prototype,"columnModel",2),g([ae],jo.prototype,"postConstruct",1);var Ko=class extends yn{constructor(e,t){super(e),this.ctrl=t}getCtrl(){return this.ctrl}},$o=class e extends Ko{constructor(t){super(e.TEMPLATE,t)}postConstruct(){const e=this.getGui(),t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),addOrRemoveBodyCssClass:(e,t)=>this.eFloatingFilterBody.classList.toggle(e,t),setButtonWrapperDisplayed:e=>sr(this.eButtonWrapper,e),setCompDetails:e=>this.setCompDetails(e),getFloatingFilterComp:()=>this.compPromise,setWidth:t=>e.style.width=t,setMenuIcon:e=>this.eButtonShowMainFilter.appendChild(e)};this.ctrl.setComp(t,e,this.eButtonShowMainFilter,this.eFloatingFilterBody)}setCompDetails(e){if(!e)return this.destroyFloatingFilterComp(),void(this.compPromise=null);this.compPromise=e.newAgStackInstance(),this.compPromise.then(e=>this.afterCompCreated(e))}destroyFloatingFilterComp(){this.floatingFilterComp&&(this.eFloatingFilterBody.removeChild(this.floatingFilterComp.getGui()),this.floatingFilterComp=this.destroyBean(this.floatingFilterComp))}afterCompCreated(e){e&&(this.isAlive()?(this.destroyFloatingFilterComp(),this.floatingFilterComp=e,this.eFloatingFilterBody.appendChild(e.getGui()),e.afterGuiAttached&&e.afterGuiAttached()):this.destroyBean(e))}};$o.TEMPLATE='<div class="ag-header-cell ag-floating-filter" role="gridcell">\n            <div ref="eFloatingFilterBody" role="presentation"></div>\n            <div class="ag-floating-filter-button ag-hidden" ref="eButtonWrapper" role="presentation">\n                <button type="button" class="ag-button ag-floating-filter-button-button" ref="eButtonShowMainFilter" tabindex="-1"></button>\n            </div>\n        </div>',g([Sn("eFloatingFilterBody")],$o.prototype,"eFloatingFilterBody",2),g([Sn("eButtonWrapper")],$o.prototype,"eButtonWrapper",2),g([Sn("eButtonShowMainFilter")],$o.prototype,"eButtonShowMainFilter",2),g([ae],$o.prototype,"postConstruct",1),g([le],$o.prototype,"destroyFloatingFilterComp",1);var qo=$o,Yo=(e=>(e.AUTO_HEIGHT="ag-layout-auto-height",e.NORMAL="ag-layout-normal",e.PRINT="ag-layout-print",e))(Yo||{}),Qo=class extends rt{constructor(e){super(),this.view=e}postConstruct(){this.addManagedPropertyListener("domLayout",this.updateLayoutClasses.bind(this)),this.updateLayoutClasses()}updateLayoutClasses(){const e=this.getDomLayout(),t={autoHeight:"autoHeight"===e,normal:"normal"===e,print:"print"===e},i=t.autoHeight?"ag-layout-auto-height":t.print?"ag-layout-print":"ag-layout-normal";this.view.updateLayoutClasses(i,t)}getDomLayout(){var e;const t=null!=(e=this.gos.get("domLayout"))?e:"normal";return-1===["normal","print","autoHeight"].indexOf(t)?(z(`${t} is not valid for DOM Layout, valid values are 'normal', 'autoHeight', 'print'.`),"normal"):t}};g([ae],Qo.prototype,"postConstruct",1);var Xo=class extends rt{constructor(e){super(),this.lastScrollSource=[null,null],this.scrollLeft=-1,this.nextScrollTop=-1,this.scrollTop=-1,this.lastOffsetHeight=-1,this.lastScrollTop=-1,this.eBodyViewport=e,this.resetLastHScrollDebounced=X(()=>this.lastScrollSource[1]=null,500),this.resetLastVScrollDebounced=X(()=>this.lastScrollSource[0]=null,500)}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onDisplayedColumnsWidthChanged.bind(this)),this.ctrlsService.whenReady(e=>{this.centerRowsCtrl=e.center,this.onDisplayedColumnsWidthChanged(),this.addScrollListener()})}addScrollListener(){const{fakeHScrollComp:e,fakeVScrollComp:t}=this.ctrlsService.getParams();this.addManagedListener(this.centerRowsCtrl.getViewportElement(),"scroll",this.onHScroll.bind(this)),e.onScrollCallback(this.onFakeHScroll.bind(this));const i=this.gos.get("debounceVerticalScrollbar"),r=i?X(this.onVScroll.bind(this),100):this.onVScroll.bind(this),n=i?X(this.onFakeVScroll.bind(this),100):this.onFakeVScroll.bind(this);this.addManagedListener(this.eBodyViewport,"scroll",r),t.onScrollCallback(n)}onDisplayedColumnsWidthChanged(){this.enableRtl&&this.horizontallyScrollHeaderCenterAndFloatingCenter()}horizontallyScrollHeaderCenterAndFloatingCenter(e){if(null==this.centerRowsCtrl)return;void 0===e&&(e=this.centerRowsCtrl.getCenterViewportScrollLeft());const t=this.enableRtl?e:-e,{topCenter:i,stickyTopCenter:r,stickyBottomCenter:n,centerHeader:s,bottomCenter:o,fakeHScrollComp:a}=this.ctrlsService.getParams();s.setHorizontalScroll(-t),o.setContainerTranslateX(t),i.setContainerTranslateX(t),r.setContainerTranslateX(t),n.setContainerTranslateX(t);const l=this.centerRowsCtrl.getViewportElement(),c=0===this.lastScrollSource[1];e=Math.abs(e),c?a.setScrollPosition(e):vr(l,e,this.enableRtl)}isControllingScroll(e,t){return null==this.lastScrollSource[t]?(this.lastScrollSource[t]=e,!0):this.lastScrollSource[t]===e}onFakeHScroll(){this.isControllingScroll(1,1)&&this.onHScrollCommon(1)}onHScroll(){this.isControllingScroll(0,1)&&this.onHScrollCommon(0)}onHScrollCommon(e){const t=this.centerRowsCtrl.getViewportElement(),{scrollLeft:i}=t;if(this.shouldBlockScrollUpdate(1,i,!0))return;let r;r=0===e?mr(t,this.enableRtl):this.ctrlsService.get("fakeHScrollComp").getScrollPosition(),this.doHorizontalScroll(Math.round(r)),this.resetLastHScrollDebounced()}onFakeVScroll(){this.isControllingScroll(1,0)&&this.onVScrollCommon(1)}onVScroll(){this.isControllingScroll(0,0)&&this.onVScrollCommon(0)}onVScrollCommon(e){let t;t=0===e?this.eBodyViewport.scrollTop:this.ctrlsService.get("fakeVScrollComp").getScrollPosition(),this.shouldBlockScrollUpdate(0,t,!0)||(this.animationFrameService.setScrollTop(t),this.nextScrollTop=t,0===e?this.ctrlsService.get("fakeVScrollComp").setScrollPosition(t):this.eBodyViewport.scrollTop=t,this.gos.get("suppressAnimationFrame")?this.scrollGridIfNeeded():this.animationFrameService.schedule(),this.resetLastVScrollDebounced())}doHorizontalScroll(e){const t=this.ctrlsService.get("fakeHScrollComp").getScrollPosition();this.scrollLeft===e&&e===t||(this.scrollLeft=e,this.fireScrollEvent(1),this.horizontallyScrollHeaderCenterAndFloatingCenter(e),this.centerRowsCtrl.onHorizontalViewportChanged(!0))}fireScrollEvent(e){const t={type:lt.EVENT_BODY_SCROLL,direction:1===e?"horizontal":"vertical",left:this.scrollLeft,top:this.scrollTop};this.eventService.dispatchEvent(t),window.clearTimeout(this.scrollTimer),this.scrollTimer=void 0,this.scrollTimer=window.setTimeout(()=>{const e=d(h({},t),{type:lt.EVENT_BODY_SCROLL_END});this.eventService.dispatchEvent(e)},100)}shouldBlockScrollUpdate(e,t,i=!1){return!(i&&!Di())&&(0===e?this.shouldBlockVerticalScroll(t):this.shouldBlockHorizontalScroll(t))}shouldBlockVerticalScroll(e){const t=ur(this.eBodyViewport),{scrollHeight:i}=this.eBodyViewport;return e<0||e+t>i}shouldBlockHorizontalScroll(e){const t=this.centerRowsCtrl.getCenterWidth(),{scrollWidth:i}=this.centerRowsCtrl.getViewportElement();if(this.enableRtl&&fr()){if(e>0)return!0}else if(e<0)return!0;return Math.abs(e)+t>i}redrawRowsAfterScroll(){this.fireScrollEvent(0)}checkScrollLeft(){this.scrollLeft!==this.centerRowsCtrl.getCenterViewportScrollLeft()&&this.onHScrollCommon(0)}scrollGridIfNeeded(){const e=this.scrollTop!=this.nextScrollTop;return e&&(this.scrollTop=this.nextScrollTop,this.redrawRowsAfterScroll()),e}setHorizontalScrollPosition(e,t=!1){const i=this.centerRowsCtrl.getViewportElement().scrollWidth-this.centerRowsCtrl.getCenterWidth();!t&&this.shouldBlockScrollUpdate(1,e)&&(e=this.enableRtl&&fr()?e>0?0:i:Math.min(Math.max(e,0),i)),vr(this.centerRowsCtrl.getViewportElement(),Math.abs(e),this.enableRtl),this.doHorizontalScroll(e)}setVerticalScrollPosition(e){this.eBodyViewport.scrollTop=e}getVScrollPosition(){return this.lastScrollTop=this.eBodyViewport.scrollTop,this.lastOffsetHeight=this.eBodyViewport.offsetHeight,{top:this.lastScrollTop,bottom:this.lastScrollTop+this.lastOffsetHeight}}getApproximateVScollPosition(){return this.lastScrollTop>=0&&this.lastOffsetHeight>=0?{top:this.scrollTop,bottom:this.scrollTop+this.lastOffsetHeight}:this.getVScrollPosition()}getHScrollPosition(){return this.centerRowsCtrl.getHScrollPosition()}isHorizontalScrollShowing(){return this.centerRowsCtrl.isHorizontalScrollShowing()}scrollHorizontally(e){const t=this.centerRowsCtrl.getViewportElement().scrollLeft;return this.setHorizontalScrollPosition(t+e),this.centerRowsCtrl.getViewportElement().scrollLeft-t}scrollToTop(){this.eBodyViewport.scrollTop=0}ensureNodeVisible(e,t=null){const i=this.rowModel.getRowCount();let r=-1;for(let t=0;t<i;t++){const i=this.rowModel.getRow(t);if("function"==typeof e){if(i&&e(i)){r=t;break}}else if(e===i||e===i.data){r=t;break}}r>=0&&this.ensureIndexVisible(r,t)}ensureIndexVisible(e,t){if(this.gos.isDomLayout("print"))return;const i=this.paginationProxy.getRowCount();if("number"!=typeof e||e<0||e>=i)return void console.warn("AG Grid: Invalid row index for ensureIndexVisible: "+e);const r=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel");this.getFrameworkOverrides().wrapIncoming(()=>{r||this.paginationProxy.goToPageWithIndex(e);const i=this.ctrlsService.getGridBodyCtrl(),n=i.getStickyTopHeight(),s=i.getStickyBottomHeight(),o=this.paginationProxy.getRow(e);let a;do{const e=o.rowTop,i=o.rowHeight,r=this.paginationProxy.getPixelOffset(),l=o.rowTop-r,c=l+o.rowHeight,u=this.getVScrollPosition(),h=this.heightScaler.getDivStretchOffset(),d=u.top+h,p=u.bottom+h,g=p-d,f=this.heightScaler.getScrollPositionForPixel(l),m=this.heightScaler.getScrollPositionForPixel(c-g),v=Math.min((f+m)/2,l);let C=null;"top"===t?C=f:"bottom"===t?C=m:"middle"===t?C=v:d+n>l?C=f-n:p-s<c&&(C=m+s),null!==C&&(this.setVerticalScrollPosition(C),this.rowRenderer.redraw({afterScroll:!0})),a=e!==o.rowTop||i!==o.rowHeight}while(a);this.animationFrameService.flushAllFrames()})}ensureColumnVisible(e,t="auto"){const i=this.columnModel.getGridColumn(e);if(!i)return;if(i.isPinned())return;if(!this.columnModel.isColumnDisplayed(i))return;const r=this.getPositionedHorizontalScroll(i,t);this.getFrameworkOverrides().wrapIncoming(()=>{null!==r&&this.centerRowsCtrl.setCenterViewportScrollLeft(r),this.centerRowsCtrl.onHorizontalViewportChanged(),this.animationFrameService.flushAllFrames()})}setScrollPosition(e,t){this.getFrameworkOverrides().wrapIncoming(()=>{this.centerRowsCtrl.setCenterViewportScrollLeft(t),this.setVerticalScrollPosition(e),this.rowRenderer.redraw({afterScroll:!0}),this.animationFrameService.flushAllFrames()})}getPositionedHorizontalScroll(e,t){const{columnBeforeStart:i,columnAfterEnd:r}=this.isColumnOutsideViewport(e),n=this.centerRowsCtrl.getCenterWidth()<e.getActualWidth(),s=this.centerRowsCtrl.getCenterWidth(),o=this.enableRtl;let a=(o?i:r)||n,l=o?r:i;"auto"!==t&&(a="start"===t,l="end"===t);const c="middle"===t;if(a||l||c){const{colLeft:t,colMiddle:i,colRight:r}=this.getColumnBounds(e);return c?i-s/2:a?o?r:t:o?t-s:r-s}return null}isColumnOutsideViewport(e){const{start:t,end:i}=this.getViewportBounds(),{colLeft:r,colRight:n}=this.getColumnBounds(e),s=this.enableRtl;return{columnBeforeStart:s?t>n:i<n,columnAfterEnd:s?i<r:t>r}}getColumnBounds(e){const t=this.enableRtl,i=this.columnModel.getBodyContainerWidth(),r=e.getActualWidth(),n=e.getLeft(),s=t?-1:1,o=t?i-n:n;return{colLeft:o,colMiddle:o+r/2*s,colRight:o+r*s}}getViewportBounds(){const e=this.centerRowsCtrl.getCenterWidth(),t=this.centerRowsCtrl.getCenterViewportScrollLeft();return{start:t,end:e+t,width:e}}};g([ue("ctrlsService")],Xo.prototype,"ctrlsService",2),g([ue("animationFrameService")],Xo.prototype,"animationFrameService",2),g([ue("paginationProxy")],Xo.prototype,"paginationProxy",2),g([ue("rowModel")],Xo.prototype,"rowModel",2),g([ue("rowContainerHeightService")],Xo.prototype,"heightScaler",2),g([ue("rowRenderer")],Xo.prototype,"rowRenderer",2),g([ue("columnModel")],Xo.prototype,"columnModel",2),g([ae],Xo.prototype,"postConstruct",1);var Zo=(e=>(e.ANIMATION_ON="ag-row-animation",e.ANIMATION_OFF="ag-row-no-animation",e))(Zo||{}),Jo="ag-force-vertical-scroll",ea=class extends rt{constructor(){super(...arguments),this.stickyTopHeight=0,this.stickyBottomHeight=0}getScrollFeature(){return this.bodyScrollFeature}getBodyViewportElement(){return this.eBodyViewport}setComp(e,t,i,r,n,s,o){this.comp=e,this.eGridBody=t,this.eBodyViewport=i,this.eTop=r,this.eBottom=n,this.eStickyTop=s,this.eStickyBottom=o,this.setCellTextSelection(this.gos.get("enableCellTextSelection")),this.addManagedPropertyListener("enableCellTextSelection",e=>this.setCellTextSelection(e.currentValue)),this.createManagedBean(new Qo(this.comp)),this.bodyScrollFeature=this.createManagedBean(new Xo(this.eBodyViewport)),this.addRowDragListener(),this.setupRowAnimationCssClass(),this.addEventListeners(),this.addFocusListeners([r,i,n,s,o]),this.onGridColumnsChanged(),this.addBodyViewportListener(),this.setFloatingHeights(),this.disableBrowserDragging(),this.addStopEditingWhenGridLosesFocus(),this.filterManager.setupAdvancedFilterHeaderComp(r),this.ctrlsService.register("gridBodyCtrl",this)}getComp(){return this.comp}addEventListeners(){this.addManagedListener(this.eventService,lt.EVENT_GRID_COLUMNS_CHANGED,this.onGridColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_SCROLL_VISIBILITY_CHANGED,this.onScrollVisibilityChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_HEADER_HEIGHT_CHANGED,this.onHeaderHeightChanged.bind(this))}addFocusListeners(e){e.forEach(e=>{this.addManagedListener(e,"focusin",t=>{const{target:i}=t,r=lr(i,"ag-root",e);e.classList.toggle("ag-has-focus",!r)}),this.addManagedListener(e,"focusout",t=>{const{target:i,relatedTarget:r}=t,n=e.contains(r),s=lr(r,"ag-root",e);lr(i,"ag-root",e)||n&&!s||e.classList.remove("ag-has-focus")})})}setColumnMovingCss(e){this.comp.setColumnMovingCss("ag-column-moving",e)}setCellTextSelection(e=!1){this.comp.setCellSelectableCss("ag-selectable",e)}onScrollVisibilityChanged(){const e=this.scrollVisibleService.isVerticalScrollShowing();this.setVerticalScrollPaddingVisible(e),this.setStickyWidth(e),this.setStickyBottomOffsetBottom();const t=`calc(100% + ${(e&&this.gos.getScrollbarWidth()||0)+(Vi()?16:0)}px)`;this.animationFrameService.requestAnimationFrame(()=>this.comp.setBodyViewportWidth(t))}onGridColumnsChanged(){const e=this.columnModel.getAllGridColumns();this.comp.setColumnCount(e.length)}disableBrowserDragging(){this.addManagedListener(this.eGridBody,"dragstart",e=>{if(e.target instanceof HTMLImageElement)return e.preventDefault(),!1})}addStopEditingWhenGridLosesFocus(){if(!this.gos.get("stopEditingWhenCellsLoseFocus"))return;const e=e=>{const i=e.relatedTarget;if(null===Li(i))return void this.rowRenderer.stopEditing();let r=t.some(e=>e.contains(i))&&this.mouseEventService.isElementInThisGrid(i);if(!r){const e=this.popupService;r=e.getActivePopups().some(e=>e.contains(i))||e.isElementWithinCustomPopup(i)}r||this.rowRenderer.stopEditing()},t=[this.eBodyViewport,this.eBottom,this.eTop,this.eStickyTop,this.eStickyBottom];t.forEach(t=>this.addManagedListener(t,"focusout",e))}updateRowCount(){const e=this.headerNavigationService.getHeaderRowCount()+this.filterManager.getHeaderRowCount(),t=this.rowModel.isLastRowIndexKnown()?this.rowModel.getRowCount():-1,i=-1===t?-1:e+t;this.comp.setRowCount(i)}registerBodyViewportResizeListener(e){this.comp.registerBodyViewportResizeListener(e)}setVerticalScrollPaddingVisible(e){const t=e?"scroll":"hidden";this.comp.setPinnedTopBottomOverflowY(t)}isVerticalScrollShowing(){const e=this.gos.get("alwaysShowVerticalScroll"),t=e?Jo:null,i=this.gos.isDomLayout("normal");return this.comp.setAlwaysVerticalScrollClass(t,e),e||i&&_r(this.eBodyViewport)}setupRowAnimationCssClass(){const e=()=>{const e=this.gos.isAnimateRows()&&!this.rowContainerHeightService.isStretching(),t=e?"ag-row-animation":"ag-row-no-animation";this.comp.setRowAnimationCssOnBodyViewport(t,e)};e(),this.addManagedListener(this.eventService,lt.EVENT_HEIGHT_SCALE_CHANGED,e),this.addManagedPropertyListener("animateRows",e)}getGridBodyElement(){return this.eGridBody}addBodyViewportListener(){const e=this.onBodyViewportContextMenu.bind(this);this.addManagedListener(this.eBodyViewport,"contextmenu",e),this.mockContextMenuForIPad(e),this.addManagedListener(this.eBodyViewport,"wheel",this.onBodyViewportWheel.bind(this)),this.addManagedListener(this.eStickyTop,"wheel",this.onStickyWheel.bind(this)),this.addManagedListener(this.eStickyBottom,"wheel",this.onStickyWheel.bind(this)),this.addFullWidthContainerWheelListener()}addFullWidthContainerWheelListener(){const e=this.eBodyViewport.querySelector(".ag-full-width-container"),t=this.eBodyViewport.querySelector(".ag-center-cols-viewport");e&&t&&this.addManagedListener(e,"wheel",e=>this.onFullWidthContainerWheel(e,t))}onFullWidthContainerWheel(e,t){!e.deltaX||Math.abs(e.deltaY)>Math.abs(e.deltaX)||!this.mouseEventService.isEventFromThisGrid(e)||(e.preventDefault(),t.scrollBy({left:e.deltaX}))}onBodyViewportContextMenu(e,t,i){if(!e&&!i)return;this.gos.get("preventDefaultOnContextMenu")&&(e||i).preventDefault();const{target:r}=e||t;r!==this.eBodyViewport&&r!==this.ctrlsService.get("center").getViewportElement()||this.menuService.showContextMenu({mouseEvent:e,touchEvent:i,value:null,anchorToElement:this.eGridBody})}mockContextMenuForIPad(e){if(!Di())return;const t=new ms(this.eBodyViewport);this.addManagedListener(t,ms.EVENT_LONG_TAP,t=>{e(void 0,t.touchStart,t.touchEvent)}),this.addDestroyFunc(()=>t.destroy())}onBodyViewportWheel(e){this.gos.get("suppressScrollWhenPopupsAreOpen")&&this.popupService.hasAnchoredPopup()&&e.preventDefault()}onStickyWheel(e){e.preventDefault(),e.offsetY&&this.scrollVertically(e.deltaY)}getGui(){return this.eGridBody}scrollVertically(e){const t=this.eBodyViewport.scrollTop;return this.bodyScrollFeature.setVerticalScrollPosition(t+e),this.eBodyViewport.scrollTop-t}addRowDragListener(){this.rowDragFeature=this.createManagedBean(new ko(this.eBodyViewport)),this.dragAndDropService.addDropTarget(this.rowDragFeature)}getRowDragFeature(){return this.rowDragFeature}onPinnedRowDataChanged(){this.setFloatingHeights()}setFloatingHeights(){const{pinnedRowModel:e}=this;let t=e.getPinnedTopTotalHeight(),i=e.getPinnedBottomTotalHeight();this.comp.setTopHeight(t),this.comp.setBottomHeight(i),this.comp.setTopDisplay(t?"inherit":"none"),this.comp.setBottomDisplay(i?"inherit":"none"),this.setStickyTopOffsetTop(),this.setStickyBottomOffsetBottom()}setStickyTopHeight(e=0){this.comp.setStickyTopHeight(`${e}px`),this.stickyTopHeight=e}getStickyTopHeight(){return this.stickyTopHeight}setStickyBottomHeight(e=0){this.comp.setStickyBottomHeight(`${e}px`),this.stickyBottomHeight=e}getStickyBottomHeight(){return this.stickyBottomHeight}setStickyWidth(e){if(e){const e=this.gos.getScrollbarWidth();this.comp.setStickyTopWidth(`calc(100% - ${e}px)`),this.comp.setStickyBottomWidth(`calc(100% - ${e}px)`)}else this.comp.setStickyTopWidth("100%"),this.comp.setStickyBottomWidth("100%")}onHeaderHeightChanged(){this.setStickyTopOffsetTop()}setStickyTopOffsetTop(){const e=this.ctrlsService.get("gridHeaderCtrl").getHeaderHeight()+this.filterManager.getHeaderHeight(),t=this.pinnedRowModel.getPinnedTopTotalHeight();let i=0;e>0&&(i+=e),t>0&&(i+=t),i>0&&(i+=1),this.comp.setStickyTopTop(`${i}px`)}setStickyBottomOffsetBottom(){const e=this.pinnedRowModel.getPinnedBottomTotalHeight()+(this.scrollVisibleService.isHorizontalScrollShowing()&&this.gos.getScrollbarWidth()||0);this.comp.setStickyBottomBottom(`${e}px`)}sizeColumnsToFit(e,t){const i=this.isVerticalScrollShowing()?this.gos.getScrollbarWidth():0,r=hr(this.eGridBody)-i;r>0?this.columnModel.sizeColumnsToFit(r,"sizeColumnsToFit",!1,e):void 0===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,100)},0):100===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,500)},100):500===t?window.setTimeout(()=>{this.sizeColumnsToFit(e,-1)},500):console.warn("AG Grid: tried to call sizeColumnsToFit() but the grid is coming back with zero width, maybe the grid is not visible yet on the screen?")}addScrollEventListener(e){this.eBodyViewport.addEventListener("scroll",e,{passive:!0})}removeScrollEventListener(e){this.eBodyViewport.removeEventListener("scroll",e)}};g([ue("animationFrameService")],ea.prototype,"animationFrameService",2),g([ue("rowContainerHeightService")],ea.prototype,"rowContainerHeightService",2),g([ue("ctrlsService")],ea.prototype,"ctrlsService",2),g([ue("columnModel")],ea.prototype,"columnModel",2),g([ue("scrollVisibleService")],ea.prototype,"scrollVisibleService",2),g([ue("menuService")],ea.prototype,"menuService",2),g([ue("headerNavigationService")],ea.prototype,"headerNavigationService",2),g([ue("dragAndDropService")],ea.prototype,"dragAndDropService",2),g([ue("pinnedRowModel")],ea.prototype,"pinnedRowModel",2),g([ue("rowRenderer")],ea.prototype,"rowRenderer",2),g([ue("popupService")],ea.prototype,"popupService",2),g([ue("mouseEventService")],ea.prototype,"mouseEventService",2),g([ue("rowModel")],ea.prototype,"rowModel",2),g([ue("filterManager")],ea.prototype,"filterManager",2);var ta=(e=>(e[e.FILL=0]="FILL",e[e.RANGE=1]="RANGE",e))(ta||{}),ia=(e=>(e[e.VALUE=0]="VALUE",e[e.DIMENSION=1]="DIMENSION",e))(ia||{}),ra="ag-cell-range-selected",na=class{constructor(e,t){this.beans=e,this.rangeService=e.rangeService,this.selectionHandleFactory=e.selectionHandleFactory,this.cellCtrl=t}setComp(e,t){this.cellComp=e,this.eGui=t,this.onRangeSelectionChanged()}onRangeSelectionChanged(){this.cellComp&&(this.rangeCount=this.rangeService.getCellRangeCount(this.cellCtrl.getCellPosition()),this.hasChartRange=this.getHasChartRange(),this.cellComp.addOrRemoveCssClass(ra,0!==this.rangeCount),this.cellComp.addOrRemoveCssClass(`${ra}-1`,1===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${ra}-2`,2===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${ra}-3`,3===this.rangeCount),this.cellComp.addOrRemoveCssClass(`${ra}-4`,this.rangeCount>=4),this.cellComp.addOrRemoveCssClass("ag-cell-range-chart",this.hasChartRange),pi(this.eGui,this.rangeCount>0||void 0),this.cellComp.addOrRemoveCssClass("ag-cell-range-single-cell",this.isSingleCell()),this.updateRangeBorders(),this.refreshHandle())}updateRangeBorders(){const e=this.getRangeBorders(),t=this.isSingleCell(),i=!t&&e.top,r=!t&&e.right,n=!t&&e.bottom,s=!t&&e.left;this.cellComp.addOrRemoveCssClass("ag-cell-range-top",i),this.cellComp.addOrRemoveCssClass("ag-cell-range-right",r),this.cellComp.addOrRemoveCssClass("ag-cell-range-bottom",n),this.cellComp.addOrRemoveCssClass("ag-cell-range-left",s)}isSingleCell(){const{rangeService:e}=this.beans;return 1===this.rangeCount&&!!e&&!e.isMoreThanOneCell()}getHasChartRange(){const{rangeService:e}=this.beans;if(!this.rangeCount||!e)return!1;const t=e.getCellRanges();return t.length>0&&t.every(e=>He([1,0],e.type))}updateRangeBordersIfRangeCount(){this.rangeCount>0&&(this.updateRangeBorders(),this.refreshHandle())}getRangeBorders(){const e=this.beans.gos.get("enableRtl");let t=!1,i=!1,r=!1,n=!1;const s=this.cellCtrl.getCellPosition().column,o=this.beans.columnModel;let a,l;e?(a=o.getDisplayedColAfter(s),l=o.getDisplayedColBefore(s)):(a=o.getDisplayedColBefore(s),l=o.getDisplayedColAfter(s));const c=this.rangeService.getCellRanges().filter(e=>this.rangeService.isCellInSpecificRange(this.cellCtrl.getCellPosition(),e));a||(n=!0),l||(i=!0);for(let e=0;e<c.length&&!(t&&i&&r&&n);e++){const s=c[e],o=this.rangeService.getRangeStartRow(s),u=this.rangeService.getRangeEndRow(s);!t&&this.beans.rowPositionUtils.sameRow(o,this.cellCtrl.getCellPosition())&&(t=!0),!r&&this.beans.rowPositionUtils.sameRow(u,this.cellCtrl.getCellPosition())&&(r=!0),!n&&a&&s.columns.indexOf(a)<0&&(n=!0),!i&&l&&s.columns.indexOf(l)<0&&(i=!0)}return{top:t,right:i,bottom:r,left:n}}refreshHandle(){if(this.beans.context.isDestroyed())return;const e=this.shouldHaveSelectionHandle();this.selectionHandle&&!e&&(this.selectionHandle=this.beans.context.destroyBean(this.selectionHandle)),e&&this.addSelectionHandle(),this.cellComp.addOrRemoveCssClass("ag-cell-range-handle",!!this.selectionHandle)}shouldHaveSelectionHandle(){const e=this.beans.gos,t=this.rangeService.getCellRanges(),i=t.length;if(this.rangeCount<1||i<1)return!1;const r=_e(t),n=this.cellCtrl.getCellPosition(),s=e.get("enableFillHandle")&&!this.cellCtrl.isSuppressFillHandle(),o=e.get("enableRangeHandle");let a=1===i&&!this.cellCtrl.isEditing()&&(s||o);if(this.hasChartRange){const e=1===t[0].type&&this.rangeService.isCellInSpecificRange(n,t[0]);this.cellComp.addOrRemoveCssClass("ag-cell-range-chart-category",e),a=0===r.type}return a&&null!=r.endRow&&this.rangeService.isContiguousRange(r)&&this.rangeService.isBottomRightCell(r,n)}addSelectionHandle(){const e=this.beans.gos,t=_e(this.rangeService.getCellRanges()).type,i=e.get("enableFillHandle")&&y(t)?0:1;this.selectionHandle&&this.selectionHandle.getType()!==i&&(this.selectionHandle=this.beans.context.destroyBean(this.selectionHandle)),this.selectionHandle||(this.selectionHandle=this.selectionHandleFactory.createSelectionHandle(i)),this.selectionHandle.refresh(this.cellCtrl)}destroy(){this.beans.context.destroyBean(this.selectionHandle)}},sa=class extends rt{constructor(e,t){super(),this.cellCtrl=e,this.beans=t,this.column=e.getColumn(),this.rowNode=e.getRowNode()}setupRowSpan(){this.rowSpan=this.column.getRowSpan(this.rowNode),this.addManagedListener(this.beans.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.onNewColumnsLoaded())}setComp(e){this.eGui=e,this.setupColSpan(),this.setupRowSpan(),this.onLeftChanged(),this.onWidthChanged(),this.applyRowSpan()}onNewColumnsLoaded(){const e=this.column.getRowSpan(this.rowNode);this.rowSpan!==e&&(this.rowSpan=e,this.applyRowSpan(!0))}onDisplayColumnsChanged(){const e=this.getColSpanningList();Pe(this.colsSpanning,e)||(this.colsSpanning=e,this.onWidthChanged(),this.onLeftChanged())}setupColSpan(){null!=this.column.getColDef().colSpan&&(this.colsSpanning=this.getColSpanningList(),this.addManagedListener(this.beans.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayColumnsChanged.bind(this)),this.addManagedListener(this.beans.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onWidthChanged.bind(this)))}onWidthChanged(){if(!this.eGui)return;const e=this.getCellWidth();this.eGui.style.width=`${e}px`}getCellWidth(){return this.colsSpanning?this.colsSpanning.reduce((e,t)=>e+t.getActualWidth(),0):this.column.getActualWidth()}getColSpanningList(){const e=this.column.getColSpan(this.rowNode),t=[];if(1===e)t.push(this.column);else{let i=this.column;const r=this.column.getPinned();for(let n=0;i&&n<e&&(t.push(i),i=this.beans.columnModel.getDisplayedColAfter(i),i&&!y(i))&&r===i.getPinned();n++);}return t}onLeftChanged(){if(!this.eGui)return;const e=this.modifyLeftForPrintLayout(this.getCellLeft());this.eGui.style.left=e+"px"}getCellLeft(){let e;return e=this.beans.gos.get("enableRtl")&&this.colsSpanning?_e(this.colsSpanning):this.column,e.getLeft()}modifyLeftForPrintLayout(e){if(!this.cellCtrl.isPrintLayout()||"left"===this.column.getPinned())return e;const t=this.beans.columnModel.getDisplayedColumnsLeftWidth();return"right"===this.column.getPinned()?t+this.beans.columnModel.getBodyContainerWidth()+(e||0):t+(e||0)}applyRowSpan(e){if(1===this.rowSpan&&!e)return;const t=this.beans.gos.getRowHeightAsNumber()*this.rowSpan;this.eGui.style.height=`${t}px`,this.eGui.style.zIndex="1"}destroy(){super.destroy()}},oa=class extends rt{constructor(e,t){super(),this.staticClasses=[],this.cellCtrl=e,this.beans=t,this.column=e.getColumn(),this.rowNode=e.getRowNode()}setComp(e){this.cellComp=e,this.applyUserStyles(),this.applyCellClassRules(),this.applyClassesFromColDef()}applyCellClassRules(){const e=this.column.getColDef(),{cellClassRules:t}=e,i=this.beans.gos.addGridCommonParams({value:this.cellCtrl.getValue(),data:this.rowNode.data,node:this.rowNode,colDef:e,column:this.column,rowIndex:this.rowNode.rowIndex});this.beans.stylingService.processClassRules(t===this.cellClassRules?void 0:this.cellClassRules,t,i,e=>this.cellComp.addOrRemoveCssClass(e,!0),e=>this.cellComp.addOrRemoveCssClass(e,!1)),this.cellClassRules=t}applyUserStyles(){const e=this.column.getColDef();if(!e.cellStyle)return;let t;if("function"==typeof e.cellStyle){const i=this.beans.gos.addGridCommonParams({column:this.column,value:this.cellCtrl.getValue(),colDef:e,data:this.rowNode.data,node:this.rowNode,rowIndex:this.rowNode.rowIndex});t=(0,e.cellStyle)(i)}else t=e.cellStyle;t&&this.cellComp.setUserStyles(t)}applyClassesFromColDef(){const e=this.column.getColDef(),t=this.beans.gos.addGridCommonParams({value:this.cellCtrl.getValue(),data:this.rowNode.data,node:this.rowNode,column:this.column,colDef:e,rowIndex:this.rowNode.rowIndex});this.staticClasses.length&&this.staticClasses.forEach(e=>this.cellComp.addOrRemoveCssClass(e,!1)),this.staticClasses=this.beans.stylingService.getStaticCellClasses(e,t),this.staticClasses.length&&this.staticClasses.forEach(e=>this.cellComp.addOrRemoveCssClass(e,!0))}destroy(){super.destroy()}},aa=class{postConstruct(){this.gos.isRowModelType("clientSide")&&(this.clientSideRowModel=this.rowModel),this.gos.isRowModelType("serverSide")&&(this.serverSideRowModel=this.rowModel)}};g([ue("resizeObserverService")],aa.prototype,"resizeObserverService",2),g([ue("paginationProxy")],aa.prototype,"paginationProxy",2),g([ue("context")],aa.prototype,"context",2),g([ue("gridOptionsService")],aa.prototype,"gos",2),g([ue("environment")],aa.prototype,"environment",2),g([ue("rowRenderer")],aa.prototype,"rowRenderer",2),g([ue("valueService")],aa.prototype,"valueService",2),g([ue("eventService")],aa.prototype,"eventService",2),g([ue("columnModel")],aa.prototype,"columnModel",2),g([ue("headerNavigationService")],aa.prototype,"headerNavigationService",2),g([ue("navigationService")],aa.prototype,"navigationService",2),g([ue("columnAnimationService")],aa.prototype,"columnAnimationService",2),g([ue("focusService")],aa.prototype,"focusService",2),g([ue("popupService")],aa.prototype,"popupService",2),g([ue("stylingService")],aa.prototype,"stylingService",2),g([ue("columnHoverService")],aa.prototype,"columnHoverService",2),g([ue("userComponentFactory")],aa.prototype,"userComponentFactory",2),g([ue("userComponentRegistry")],aa.prototype,"userComponentRegistry",2),g([ue("animationFrameService")],aa.prototype,"animationFrameService",2),g([ue("dragService")],aa.prototype,"dragService",2),g([ue("dragAndDropService")],aa.prototype,"dragAndDropService",2),g([ue("sortController")],aa.prototype,"sortController",2),g([ue("filterManager")],aa.prototype,"filterManager",2),g([ue("rowContainerHeightService")],aa.prototype,"rowContainerHeightService",2),g([ue("frameworkOverrides")],aa.prototype,"frameworkOverrides",2),g([ue("cellPositionUtils")],aa.prototype,"cellPositionUtils",2),g([ue("rowPositionUtils")],aa.prototype,"rowPositionUtils",2),g([ue("selectionService")],aa.prototype,"selectionService",2),g([ue("rowCssClassCalculator")],aa.prototype,"rowCssClassCalculator",2),g([ue("rowModel")],aa.prototype,"rowModel",2),g([ue("ctrlsService")],aa.prototype,"ctrlsService",2),g([ue("ctrlsFactory")],aa.prototype,"ctrlsFactory",2),g([ue("agStackComponentsRegistry")],aa.prototype,"agStackComponentsRegistry",2),g([ue("valueCache")],aa.prototype,"valueCache",2),g([ue("rowNodeEventThrottle")],aa.prototype,"rowNodeEventThrottle",2),g([ue("localeService")],aa.prototype,"localeService",2),g([ue("syncService")],aa.prototype,"syncService",2),g([ue("ariaAnnouncementService")],aa.prototype,"ariaAnnouncementService",2),g([he("rangeService")],aa.prototype,"rangeService",2),g([he("selectionHandleFactory")],aa.prototype,"selectionHandleFactory",2),g([ae],aa.prototype,"postConstruct",1),aa=g([ce("beans")],aa);var la=class extends aa{constructor(e,t,i){super(),this.cellCtrl=e,this.beans=t,this.column=i}onMouseEvent(e,t){if(!Ye(t))switch(e){case"click":this.onCellClicked(t);break;case"mousedown":case"touchstart":this.onMouseDown(t);break;case"dblclick":this.onCellDoubleClicked(t);break;case"mouseout":this.onMouseOut(t);break;case"mouseover":this.onMouseOver(t)}}onCellClicked(e){if(this.isDoubleClickOnIPad())return this.onCellDoubleClicked(e),void e.preventDefault();const{eventService:t,rangeService:i,gos:r}=this.beans,n=e.ctrlKey||e.metaKey;i&&n&&i.getCellRangeCount(this.cellCtrl.getCellPosition())>1&&i.intersectLastRange(!0);const s=this.cellCtrl.createEvent(e,lt.EVENT_CELL_CLICKED);t.dispatchEvent(s);const o=this.column.getColDef();o.onCellClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{o.onCellClicked(s)})},0),!r.get("singleClickEdit")&&!o.singleClickEdit||r.get("suppressClickEdit")||e.shiftKey&&0!=(null==i?void 0:i.getCellRanges().length)||this.cellCtrl.startRowOrCellEdit()}isDoubleClickOnIPad(){if(!Di()||Qe("dblclick"))return!1;const e=(new Date).getTime(),t=e-this.lastIPadMouseClickEvent<200;return this.lastIPadMouseClickEvent=e,t}onCellDoubleClicked(e){const t=this.column.getColDef(),i=this.cellCtrl.createEvent(e,lt.EVENT_CELL_DOUBLE_CLICKED);this.beans.eventService.dispatchEvent(i),"function"==typeof t.onCellDoubleClicked&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{t.onCellDoubleClicked(i)})},0),!this.beans.gos.get("singleClickEdit")&&!this.beans.gos.get("suppressClickEdit")&&this.cellCtrl.startRowOrCellEdit(null,e)}onMouseDown(e){const{ctrlKey:t,metaKey:i,shiftKey:r}=e,n=e.target,{cellCtrl:s,beans:o}=this,{eventService:a,rangeService:l,focusService:c}=o;if(this.isRightClickInExistingRange(e))return;const u=l&&0!=l.getCellRanges().length;if(!r||!u){const e=Mi()&&!s.isEditing()&&!nr(n);s.focusCell(e)}if(r&&u&&!c.isCellFocused(s.getCellPosition())){e.preventDefault();const t=c.getFocusedCell();if(t){const{column:e,rowIndex:i,rowPinned:r}=t,n=o.rowRenderer.getRowByPosition({rowIndex:i,rowPinned:r}),s=null==n?void 0:n.getCellCtrl(e);(null==s?void 0:s.isEditing())&&s.stopEditing(),c.setFocusedCell({column:e,rowIndex:i,rowPinned:r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}}if(!this.containsWidget(n)){if(l){const e=this.cellCtrl.getCellPosition();if(r)l.extendLatestRangeToCell(e);else{const r=t||i;l.setRangeToCell(e,r)}}a.dispatchEvent(this.cellCtrl.createEvent(e,lt.EVENT_CELL_MOUSE_DOWN))}}isRightClickInExistingRange(e){const{rangeService:t}=this.beans;if(t){const i=t.isCellInAnyRange(this.cellCtrl.getCellPosition()),r=2===e.button||e.ctrlKey&&this.beans.gos.get("allowContextMenuWithControlKey");if(i&&r)return!0}return!1}containsWidget(e){return lr(e,"ag-selection-checkbox",3)}onMouseOut(e){if(this.mouseStayingInsideCell(e))return;const t=this.cellCtrl.createEvent(e,lt.EVENT_CELL_MOUSE_OUT);this.beans.eventService.dispatchEvent(t),this.beans.columnHoverService.clearMouseOver()}onMouseOver(e){if(this.mouseStayingInsideCell(e))return;const t=this.cellCtrl.createEvent(e,lt.EVENT_CELL_MOUSE_OVER);this.beans.eventService.dispatchEvent(t),this.beans.columnHoverService.setMouseOver([this.column])}mouseStayingInsideCell(e){if(!e.target||!e.relatedTarget)return!1;const t=this.cellCtrl.getGui(),i=t.contains(e.target),r=t.contains(e.relatedTarget);return i&&r}destroy(){}},ca=class extends rt{constructor(e,t,i,r,n){super(),this.cellCtrl=e,this.beans=t,this.rowNode=r,this.rowCtrl=n}setComp(e){this.eGui=e}onKeyDown(e){const t=e.key;switch(t){case Yr.ENTER:this.onEnterKeyDown(e);break;case Yr.F2:this.onF2KeyDown(e);break;case Yr.ESCAPE:this.onEscapeKeyDown(e);break;case Yr.TAB:this.onTabKeyDown(e);break;case Yr.BACKSPACE:case Yr.DELETE:this.onBackspaceOrDeleteKeyDown(t,e);break;case Yr.DOWN:case Yr.UP:case Yr.RIGHT:case Yr.LEFT:this.onNavigationKeyDown(e,t)}}onNavigationKeyDown(e,t){this.cellCtrl.isEditing()||(e.shiftKey&&this.cellCtrl.isRangeSelectionEnabled()?this.onShiftRangeSelect(e):this.beans.navigationService.navigateToNextCell(e,t,this.cellCtrl.getCellPosition(),!0),e.preventDefault())}onShiftRangeSelect(e){if(!this.beans.rangeService)return;const t=this.beans.rangeService.extendLatestRangeInDirection(e);t&&this.beans.navigationService.ensureCellVisible(t)}onTabKeyDown(e){this.beans.navigationService.onTabKeyDown(this.cellCtrl,e)}onBackspaceOrDeleteKeyDown(e,t){var i;const{cellCtrl:r,beans:n,rowNode:s}=this,{gos:o,rangeService:a,eventService:l}=n;if(!r.isEditing()){if(l.dispatchEvent({type:lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_START}),en(e,o.get("enableCellEditingOnBackspace"))){if(a&&o.get("enableRangeSelection"))a.clearCellRangeCellValues({dispatchWrapperEvents:!0,wrapperEventSource:"deleteKey"});else if(r.isCellEditable()){const e=r.getColumn(),t=null!=(i=this.beans.valueService.parseValue(e,s,"",s.getValueFromValueService(e)))?i:null;s.setDataValue(e,t,"cellClear")}}else r.startRowOrCellEdit(e,t);l.dispatchEvent({type:lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_END})}}onEnterKeyDown(e){if(this.cellCtrl.isEditing()||this.rowCtrl.isEditing())this.cellCtrl.stopEditingAndFocus(!1,e.shiftKey);else if(this.beans.gos.get("enterNavigatesVertically")){const t=e.shiftKey?Yr.UP:Yr.DOWN;this.beans.navigationService.navigateToNextCell(null,t,this.cellCtrl.getCellPosition(),!1)}else this.cellCtrl.startRowOrCellEdit(Yr.ENTER,e),this.cellCtrl.isEditing()&&e.preventDefault()}onF2KeyDown(e){this.cellCtrl.isEditing()||this.cellCtrl.startRowOrCellEdit(Yr.F2,e)}onEscapeKeyDown(e){this.cellCtrl.isEditing()&&(this.cellCtrl.stopRowOrCellEdit(!0),this.cellCtrl.focusCell(!0))}processCharacter(e){if(e.target!==this.eGui||this.cellCtrl.isEditing())return;const t=e.key;" "===t?this.onSpaceKeyDown(e):(this.cellCtrl.startRowOrCellEdit(t,e),e.preventDefault())}onSpaceKeyDown(e){const{gos:t}=this.beans;if(!this.cellCtrl.isEditing()&&t.isRowSelection()){const i=this.rowNode.isSelected(),r=!i;if(r||!t.get("suppressRowDeselection")){const t=this.beans.gos.get("groupSelectsFiltered"),n=this.rowNode.setSelectedParams({newValue:r,rangeSelect:e.shiftKey,groupSelectsFiltered:t,event:e,source:"spaceKey"});void 0===i&&0===n&&this.rowNode.setSelectedParams({newValue:!1,rangeSelect:e.shiftKey,groupSelectsFiltered:t,event:e,source:"spaceKey"})}}e.preventDefault()}destroy(){super.destroy()}},ua=class extends yn{constructor(e,t,i){super('<div class="ag-drag-handle ag-row-drag" draggable="true"></div>'),this.rowNode=e,this.column=t,this.eCell=i}postConstruct(){this.getGui().appendChild($r("rowDrag",this.gos,null)),this.addGuiEventListener("mousedown",e=>{e.stopPropagation()}),this.addDragSource(),this.checkVisibility()}addDragSource(){this.addGuiEventListener("dragstart",this.onDragStart.bind(this))}onDragStart(e){const t=this.column.getColDef().dndSourceOnRowDrag;e.dataTransfer.setDragImage(this.eCell,0,0);t?t(this.gos.addGridCommonParams({rowNode:this.rowNode,dragEvent:e})):(()=>{try{const t=JSON.stringify(this.rowNode.data);e.dataTransfer.setData("application/json",t),e.dataTransfer.setData("text/plain",t)}catch(e){}})()}checkVisibility(){const e=this.column.isDndSource(this.rowNode);this.setDisplayed(e)}};g([ae],ua.prototype,"postConstruct",1);var ha=class{static getHeaderClassesFromColDef(e,t,i,r){return y(e)?[]:this.getColumnClassesFromCollDef(e.headerClass,e,t,i,r)}static getToolPanelClassesFromColDef(e,t,i,r){return y(e)?[]:this.getColumnClassesFromCollDef(e.toolPanelClass,e,t,i,r)}static refreshFirstAndLastStyles(e,t,i){e.addOrRemoveCssClass("ag-column-first",i.isColumnAtEdge(t,"first")),e.addOrRemoveCssClass("ag-column-last",i.isColumnAtEdge(t,"last"))}static getClassParams(e,t,i,r){return t.addGridCommonParams({colDef:e,column:i,columnGroup:r})}static getColumnClassesFromCollDef(e,t,i,r,n){if(y(e))return[];let s;return s="function"==typeof e?e(this.getClassParams(t,i,r,n)):e,"string"==typeof s?[s]:Array.isArray(s)?[...s]:[]}},da=0,pa=class e extends rt{constructor(e,t,i,r){super(),this.cellRangeFeature=null,this.cellPositionFeature=null,this.cellCustomStyleFeature=null,this.tooltipFeature=null,this.cellMouseListenerFeature=null,this.cellKeyboardListenerFeature=null,this.suppressRefreshCell=!1,this.onCellCompAttachedFuncs=[],this.column=e,this.rowNode=t,this.beans=i,this.rowCtrl=r,this.instanceId=e.getId()+"-"+da++,this.colIdSanitised=Ct(this.column.getId()),i.gos.get("suppressCellFocus")||(this.tabIndex=-1),this.createCellPosition(),this.addFeatures(),this.updateAndFormatValue(!1)}shouldRestoreFocus(){return this.beans.focusService.shouldRestoreFocus(this.cellPosition)}addFeatures(){this.cellPositionFeature=new sa(this,this.beans),this.addDestroyFunc(()=>{var e;null==(e=this.cellPositionFeature)||e.destroy(),this.cellPositionFeature=null}),this.cellCustomStyleFeature=new oa(this,this.beans),this.addDestroyFunc(()=>{var e;null==(e=this.cellCustomStyleFeature)||e.destroy(),this.cellCustomStyleFeature=null}),this.cellMouseListenerFeature=new la(this,this.beans,this.column),this.addDestroyFunc(()=>{var e;null==(e=this.cellMouseListenerFeature)||e.destroy(),this.cellMouseListenerFeature=null}),this.cellKeyboardListenerFeature=new ca(this,this.beans,this.column,this.rowNode,this.rowCtrl),this.addDestroyFunc(()=>{var e;null==(e=this.cellKeyboardListenerFeature)||e.destroy(),this.cellKeyboardListenerFeature=null}),this.column.isTooltipEnabled()&&(this.enableTooltipFeature(),this.addDestroyFunc(()=>{this.disableTooltipFeature()})),this.beans.rangeService&&this.beans.gos.get("enableRangeSelection")&&(this.cellRangeFeature=new na(this.beans,this),this.addDestroyFunc(()=>{var e;null==(e=this.cellRangeFeature)||e.destroy(),this.cellRangeFeature=null}))}enableTooltipFeature(e,t){const i="whenTruncated"===this.beans.gos.get("tooltipShowMode");t||!i||this.isCellRenderer()||(t=()=>{const e=this.getGui(),t=0===e.children.length?e:e.querySelector(".ag-cell-value");return!t||t.scrollWidth>t.clientWidth});const r={getColumn:()=>this.column,getColDef:()=>this.column.getColDef(),getRowIndex:()=>this.cellPosition.rowIndex,getRowNode:()=>this.rowNode,getGui:()=>this.getGui(),getLocation:()=>"cell",getTooltipValue:null!=e?()=>e:()=>{const e=this.column.getColDef(),t=this.rowNode.data;if(e.tooltipField&&C(t))return F(t,e.tooltipField,this.column.isTooltipFieldContainsDots());const i=e.tooltipValueGetter;return i?i(this.beans.gos.addGridCommonParams({location:"cell",colDef:this.column.getColDef(),column:this.column,rowIndex:this.cellPosition.rowIndex,node:this.rowNode,data:this.rowNode.data,value:this.value,valueFormatted:this.valueFormatted})):null},getValueFormatted:()=>this.valueFormatted,shouldDisplayTooltip:t};this.tooltipFeature=new mn(r,this.beans)}disableTooltipFeature(){this.tooltipFeature&&(this.tooltipFeature.destroy(),this.tooltipFeature=null)}setComp(e,t,i,r,n){var s,o,a,l;this.cellComp=e,this.eGui=t,this.printLayout=r,this.addDomData(),this.onCellFocused(this.focusEventToRestore),this.applyStaticCssClasses(),this.setWrapText(),this.onFirstRightPinnedChanged(),this.onLastLeftPinnedChanged(),this.onColumnHover(),this.setupControlComps(),this.setupAutoHeight(i),this.refreshFirstAndLastStyles(),this.refreshAriaColIndex(),null==(s=this.cellPositionFeature)||s.setComp(t),null==(o=this.cellCustomStyleFeature)||o.setComp(e),null==(a=this.tooltipFeature)||a.refreshToolTip(),null==(l=this.cellKeyboardListenerFeature)||l.setComp(this.eGui),this.cellRangeFeature&&this.cellRangeFeature.setComp(e,t),n&&this.isCellEditable()?this.startEditing():this.showValue(),this.onCellCompAttachedFuncs.length&&(this.onCellCompAttachedFuncs.forEach(e=>e()),this.onCellCompAttachedFuncs=[])}setupAutoHeight(e){if(this.isAutoHeight=this.column.isAutoHeight(),!this.isAutoHeight||!e)return;const t=e.parentElement,i=this.beans.gos.getRowHeightForNode(this.rowNode).height,r=n=>{if(this.editing)return;if(!this.isAlive())return;const{paddingTop:s,paddingBottom:o,borderBottomWidth:a,borderTopWidth:l}=cr(t),c=s+o+a+l,u=e.offsetHeight+c;if(n<5){const t=this.beans.gos.getDocument();if(!t||!t.contains(e)||0==u)return void window.setTimeout(()=>r(n+1),0)}const h=Math.max(u,i);this.rowNode.setRowAutoHeight(h,this.column)},n=()=>r(0);n();const s=this.beans.resizeObserverService.observeResize(e,n);this.addDestroyFunc(()=>{s(),this.rowNode.setRowAutoHeight(void 0,this.column)})}getCellAriaRole(){var e;return null!=(e=this.column.getColDef().cellAriaRole)?e:"gridcell"}getInstanceId(){return this.instanceId}getColumnIdSanitised(){return this.colIdSanitised}getTabIndex(){return this.tabIndex}isCellRenderer(){const e=this.column.getColDef();return null!=e.cellRenderer||null!=e.cellRendererSelector}getValueToDisplay(){var e;return null!=(e=this.valueFormatted)?e:this.value}showValue(e=!1){var t;const i=this.getValueToDisplay();let r;if(this.rowNode.stub){const e=this.createCellRendererParams();r=this.beans.userComponentFactory.getLoadingCellRendererDetails(this.column.getColDef(),e)}else if(this.isCellRenderer()){const e=this.createCellRendererParams();r=this.beans.userComponentFactory.getCellRendererDetails(this.column.getColDef(),e)}this.cellComp.setRenderDetails(r,i,e),null==(t=this.cellRangeFeature)||t.refreshHandle()}setupControlComps(){const e=this.column.getColDef();this.includeSelection=this.isIncludeControl(e.checkboxSelection),this.includeRowDrag=this.isIncludeControl(e.rowDrag),this.includeDndSource=this.isIncludeControl(e.dndSource),this.cellComp.setIncludeSelection(this.includeSelection),this.cellComp.setIncludeDndSource(this.includeDndSource),this.cellComp.setIncludeRowDrag(this.includeRowDrag)}isForceWrapper(){return this.beans.gos.get("enableCellTextSelection")||this.column.isAutoHeight()}isIncludeControl(e){return!(null!=this.rowNode.rowPinned||"function"!=typeof e&&!0!==e)}refreshShouldDestroy(){const e=this.column.getColDef(),t=this.includeSelection!=this.isIncludeControl(e.checkboxSelection),i=this.includeRowDrag!=this.isIncludeControl(e.rowDrag),r=this.includeDndSource!=this.isIncludeControl(e.dndSource),n=this.isAutoHeight!=this.column.isAutoHeight();return t||i||r||n}startEditing(e=null,t=!1,i=null){if(!this.isCellEditable()||this.editing)return;if(!this.cellComp)return void this.onCellCompAttachedFuncs.push(()=>{this.startEditing(e,t,i)});const r=this.createCellEditorParams(e,t),n=this.column.getColDef(),s=this.beans.userComponentFactory.getCellEditorDetails(n,r);this.editCompDetails=s;const o=null!=(null==s?void 0:s.popupFromSelector)?s.popupFromSelector:!!n.cellEditorPopup,a=null!=(null==s?void 0:s.popupPositionFromSelector)?s.popupPositionFromSelector:n.cellEditorPopupPosition;this.setEditing(!0),this.cellComp.setEditDetails(s,o,a,this.beans.gos.get("reactiveCustomComponents"));const l=this.createEvent(i,lt.EVENT_CELL_EDITING_STARTED);this.beans.eventService.dispatchEvent(l)}setEditing(e){var t;this.editing!==e&&(this.editing=e,null==(t=this.cellRangeFeature)||t.refreshHandle())}stopRowOrCellEdit(e=!1){"fullRow"===this.beans.gos.get("editType")?this.rowCtrl.stopEditing(e):this.stopEditing(e)}onPopupEditorClosed(){this.isEditing()&&this.stopEditingAndFocus()}takeValueFromCellEditor(e){const t={newValueExists:!1};if(e)return t;const i=this.cellComp.getCellEditor();return i?i.isCancelAfterEnd&&i.isCancelAfterEnd()?t:{newValue:i.getValue(),newValueExists:!0}:t}saveNewValue(e,t){if(t===e)return!1;this.suppressRefreshCell=!0;const i=this.rowNode.setDataValue(this.column,t,"edit");return this.suppressRefreshCell=!1,i}stopEditing(e=!1){if(!this.editing)return!1;const{newValue:t,newValueExists:i}=this.takeValueFromCellEditor(e),r=this.rowNode.getValueFromValueService(this.column);let n=!1;return i&&(n=this.saveNewValue(r,t)),this.setEditing(!1),this.cellComp.setEditDetails(),this.editCompDetails=void 0,this.updateAndFormatValue(!1),this.refreshCell({forceRefresh:!0,suppressFlash:!0}),this.dispatchEditingStoppedEvent(r,t,!e&&!!n),n}dispatchEditingStoppedEvent(e,t,i){const r=d(h({},this.createEvent(null,lt.EVENT_CELL_EDITING_STOPPED)),{oldValue:e,newValue:t,valueChanged:i});this.beans.eventService.dispatchEvent(r)}createCellEditorParams(e,t){return this.beans.gos.addGridCommonParams({value:this.rowNode.getValueFromValueService(this.column),eventKey:e,column:this.column,colDef:this.column.getColDef(),rowIndex:this.getCellPosition().rowIndex,node:this.rowNode,data:this.rowNode.data,cellStartedEdit:t,onKeyDown:this.onKeyDown.bind(this),stopEditing:this.stopEditingAndFocus.bind(this),eGridCell:this.getGui(),parseValue:this.parseValue.bind(this),formatValue:this.formatValue.bind(this)})}createCellRendererParams(){return this.beans.gos.addGridCommonParams({value:this.value,valueFormatted:this.valueFormatted,getValue:()=>this.rowNode.getValueFromValueService(this.column),setValue:e=>this.beans.valueService.setValue(this.rowNode,this.column,e),formatValue:this.formatValue.bind(this),data:this.rowNode.data,node:this.rowNode,pinned:this.column.getPinned(),colDef:this.column.getColDef(),column:this.column,rowIndex:this.getCellPosition().rowIndex,refreshCell:this.refreshCell.bind(this),eGridCell:this.getGui(),eParentOfValue:this.cellComp.getParentOfValue(),registerRowDragger:(e,t,i,r)=>this.registerRowDragger(e,t,r),setTooltip:(e,t)=>{var i;this.tooltipFeature&&this.disableTooltipFeature(),this.enableTooltipFeature(e,t),null==(i=this.tooltipFeature)||i.refreshToolTip()}})}parseValue(e){return this.beans.valueService.parseValue(this.column,this.rowNode,e,this.getValue())}setFocusOutOnEditor(){if(!this.editing)return;const e=this.cellComp.getCellEditor();e&&e.focusOut&&e.focusOut()}setFocusInOnEditor(){if(!this.editing)return;const e=this.cellComp.getCellEditor();e&&e.focusIn?e.focusIn():this.focusCell(!0)}onCellChanged(e){e.column===this.column&&this.refreshCell({})}refreshOrDestroyCell(e){var t;this.refreshShouldDestroy()?null==(t=this.rowCtrl)||t.recreateCell(this):this.refreshCell(e)}refreshCell(e){var t,i,r,n;if(this.suppressRefreshCell||this.editing)return;const s=this.column.getColDef(),o=null!=e&&!!e.newData,a=null!=e&&!!e.suppressFlash||!!s.suppressCellFlash,l=null==s.field&&null==s.valueGetter&&null==s.showRowGroup,c=e&&e.forceRefresh||l||o,u=!!this.cellComp,h=this.updateAndFormatValue(u);if(u){if(c||h){this.showValue(o);const e=this.beans.filterManager.isSuppressFlashingCellsBecauseFiltering();!a&&!e&&(this.beans.gos.get("enableCellChangeFlash")||s.enableCellChangeFlash)&&this.flashCell(),null==(t=this.cellCustomStyleFeature)||t.applyUserStyles(),null==(i=this.cellCustomStyleFeature)||i.applyClassesFromColDef()}null==(r=this.tooltipFeature)||r.refreshToolTip(),null==(n=this.cellCustomStyleFeature)||n.applyCellClassRules()}}stopEditingAndFocus(e=!1,t=!1){this.stopRowOrCellEdit(),this.focusCell(!0),e||this.navigateAfterEdit(t)}navigateAfterEdit(e){if(this.beans.gos.get("enterNavigatesVerticallyAfterEdit")){const t=e?Yr.UP:Yr.DOWN;this.beans.navigationService.navigateToNextCell(null,t,this.getCellPosition(),!1)}}flashCell(e){var t,i;const r=null!=(t=null==e?void 0:e.flashDuration)?t:null==e?void 0:e.flashDelay,n=null!=(i=null==e?void 0:e.fadeDuration)?i:null==e?void 0:e.fadeDelay;this.animateCell("data-changed",r,n)}animateCell(e,t,i){if(!this.cellComp)return;const r=`ag-cell-${e}`,n=`ag-cell-${e}-animation`,{gos:s}=this.beans;t||(t=s.get("cellFlashDuration")),C(i)||(i=s.get("cellFadeDuration")),this.cellComp.addOrRemoveCssClass(r,!0),this.cellComp.addOrRemoveCssClass(n,!1),this.beans.frameworkOverrides.wrapIncoming(()=>{window.setTimeout(()=>{this.isAlive()&&(this.cellComp.addOrRemoveCssClass(r,!1),this.cellComp.addOrRemoveCssClass(n,!0),this.eGui.style.transition=`background-color ${i}ms`,window.setTimeout(()=>{this.isAlive()&&(this.cellComp.addOrRemoveCssClass(n,!1),this.eGui.style.transition="")},i))},t)})}onFlashCells(e){if(!this.cellComp)return;const t=this.beans.cellPositionUtils.createId(this.getCellPosition());e.cells[t]&&this.animateCell("highlight")}isCellEditable(){return this.column.isCellEditable(this.rowNode)}isSuppressFillHandle(){return this.column.isSuppressFillHandle()}formatValue(e){var t;return null!=(t=this.callValueFormatter(e))?t:e}callValueFormatter(e){return this.beans.valueService.formatValue(this.column,this.rowNode,e)}updateAndFormatValue(e){const t=this.value,i=this.valueFormatted;return this.value=this.rowNode.getValueFromValueService(this.column),this.valueFormatted=this.callValueFormatter(this.value),!e||!this.valuesAreEqual(t,this.value)||this.valueFormatted!=i}valuesAreEqual(e,t){const i=this.column.getColDef();return i.equals?i.equals(e,t):e===t}getComp(){return this.cellComp}getValue(){return this.value}addDomData(){const t=this.getGui();this.beans.gos.setDomData(t,e.DOM_DATA_KEY_CELL_CTRL,this),this.addDestroyFunc(()=>this.beans.gos.setDomData(t,e.DOM_DATA_KEY_CELL_CTRL,null))}createEvent(e,t){return this.beans.gos.addGridCommonParams({type:t,node:this.rowNode,data:this.rowNode.data,value:this.value,column:this.column,colDef:this.column.getColDef(),rowPinned:this.rowNode.rowPinned,event:e,rowIndex:this.rowNode.rowIndex})}processCharacter(e){var t;null==(t=this.cellKeyboardListenerFeature)||t.processCharacter(e)}onKeyDown(e){var t;null==(t=this.cellKeyboardListenerFeature)||t.onKeyDown(e)}onMouseEvent(e,t){var i;null==(i=this.cellMouseListenerFeature)||i.onMouseEvent(e,t)}getGui(){return this.eGui}getColSpanningList(){return this.cellPositionFeature.getColSpanningList()}onLeftChanged(){var e;this.cellComp&&(null==(e=this.cellPositionFeature)||e.onLeftChanged())}onDisplayedColumnsChanged(){this.eGui&&(this.refreshAriaColIndex(),this.refreshFirstAndLastStyles())}refreshFirstAndLastStyles(){const{cellComp:e,column:t,beans:i}=this;ha.refreshFirstAndLastStyles(e,t,i.columnModel)}refreshAriaColIndex(){const e=this.beans.columnModel.getAriaColumnIndex(this.column);ci(this.getGui(),e)}isSuppressNavigable(){return this.column.isSuppressNavigable(this.rowNode)}onWidthChanged(){var e;return null==(e=this.cellPositionFeature)?void 0:e.onWidthChanged()}getColumn(){return this.column}getRowNode(){return this.rowNode}isPrintLayout(){return this.printLayout}getCellPosition(){return this.cellPosition}isEditing(){return this.editing}startRowOrCellEdit(e,t=null){this.cellComp?"fullRow"===this.beans.gos.get("editType")?this.rowCtrl.startRowEditing(e,this):this.startEditing(e,!0,t):this.onCellCompAttachedFuncs.push(()=>{this.startRowOrCellEdit(e,t)})}getRowCtrl(){return this.rowCtrl}getRowPosition(){return{rowIndex:this.cellPosition.rowIndex,rowPinned:this.cellPosition.rowPinned}}updateRangeBordersIfRangeCount(){this.cellComp&&this.cellRangeFeature&&this.cellRangeFeature.updateRangeBordersIfRangeCount()}onRangeSelectionChanged(){this.cellComp&&this.cellRangeFeature&&this.cellRangeFeature.onRangeSelectionChanged()}isRangeSelectionEnabled(){return null!=this.cellRangeFeature}focusCell(e=!1){this.beans.focusService.setFocusedCell({rowIndex:this.getCellPosition().rowIndex,column:this.column,rowPinned:this.rowNode.rowPinned,forceBrowserFocus:e})}onRowIndexChanged(){this.createCellPosition(),this.onCellFocused(),this.cellRangeFeature&&this.cellRangeFeature.onRangeSelectionChanged()}onFirstRightPinnedChanged(){if(!this.cellComp)return;const e=this.column.isFirstRightPinned();this.cellComp.addOrRemoveCssClass("ag-cell-first-right-pinned",e)}onLastLeftPinnedChanged(){if(!this.cellComp)return;const e=this.column.isLastLeftPinned();this.cellComp.addOrRemoveCssClass("ag-cell-last-left-pinned",e)}onCellFocused(e){if(this.beans.gos.get("suppressCellFocus"))return;const t=this.beans.focusService.isCellFocused(this.cellPosition);if(!this.cellComp)return void(t&&(null==e?void 0:e.forceBrowserFocus)&&(this.focusEventToRestore=e));this.focusEventToRestore=void 0,this.cellComp.addOrRemoveCssClass("ag-cell-focus",t),t&&e&&e.forceBrowserFocus&&this.cellComp.getFocusableElement().focus({preventScroll:!!e.preventScrollOnBrowserFocus});const i="fullRow"===this.beans.gos.get("editType");t||i||!this.editing||this.stopRowOrCellEdit(),t&&this.rowCtrl.announceDescription()}createCellPosition(){this.cellPosition={rowIndex:this.rowNode.rowIndex,rowPinned:v(this.rowNode.rowPinned),column:this.column}}applyStaticCssClasses(){this.cellComp.addOrRemoveCssClass("ag-cell",!0),this.cellComp.addOrRemoveCssClass("ag-cell-not-inline-editing",!0);const e=1==this.column.isAutoHeight();this.cellComp.addOrRemoveCssClass("ag-cell-auto-height",e),this.cellComp.addOrRemoveCssClass("ag-cell-normal-height",!e)}onColumnHover(){if(!this.cellComp)return;if(!this.beans.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.cellComp.addOrRemoveCssClass("ag-column-hover",e)}onColDefChanged(){if(this.cellComp)if(this.column.isTooltipEnabled()?(this.disableTooltipFeature(),this.enableTooltipFeature()):this.disableTooltipFeature(),this.setWrapText(),this.editing){const e=this.getCellEditor();if(null==e?void 0:e.refresh){const{eventKey:t,cellStartedEdit:i}=this.editCompDetails.params,r=this.createCellEditorParams(t,i),n=this.column.getColDef(),s=this.beans.userComponentFactory.getCellEditorDetails(n,r);e.refresh(s.params)}}else this.refreshOrDestroyCell({forceRefresh:!0,suppressFlash:!0})}setWrapText(){const e=1==this.column.getColDef().wrapText;this.cellComp.addOrRemoveCssClass("ag-cell-wrap-text",e)}dispatchCellContextMenuEvent(e){const t=this.column.getColDef(),i=this.createEvent(e,lt.EVENT_CELL_CONTEXT_MENU);this.beans.eventService.dispatchEvent(i),t.onCellContextMenu&&window.setTimeout(()=>{this.beans.frameworkOverrides.wrapOutgoing(()=>{t.onCellContextMenu(i)})},0)}getCellRenderer(){return this.cellComp?this.cellComp.getCellRenderer():null}getCellEditor(){return this.cellComp?this.cellComp.getCellEditor():null}destroy(){this.onCellCompAttachedFuncs=[],super.destroy()}createSelectionCheckbox(){const e=new Ns;return this.beans.context.createBean(e),e.init({rowNode:this.rowNode,column:this.column}),e}createDndSource(){const e=new ua(this.rowNode,this.column,this.eGui);return this.beans.context.createBean(e),e}registerRowDragger(e,t,i){if(this.customRowDragComp)return void this.customRowDragComp.setDragElement(e,t);const r=this.createRowDragComp(e,t,i);r&&(this.customRowDragComp=r,this.addDestroyFunc(()=>{this.beans.context.destroyBean(r),this.customRowDragComp=null}))}createRowDragComp(e,t,i){const r=this.beans.gos.get("pagination"),n=this.beans.gos.get("rowDragManaged"),s=this.beans.gos.isRowModelType("clientSide");if(n){if(!s)return void z("managed row dragging is only allowed in the Client Side Row Model");if(r)return void z("managed row dragging is not possible when doing pagination")}const o=new Vs(()=>this.value,this.rowNode,this.column,e,t,i);return this.beans.context.createBean(o),o}};pa.DOM_DATA_KEY_CELL_CTRL="cellCtrl";var ga=pa,fa=0,ma=class e extends rt{constructor(e,t,i,r,n){super(),this.allRowGuis=[],this.active=!0,this.centerCellCtrls={list:[],map:{}},this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}},this.slideInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.fadeInAnimation={left:!1,center:!1,right:!1,fullWidth:!1},this.rowDragComps=[],this.lastMouseDownOnDragger=!1,this.emptyStyle={},this.updateColumnListsPending=!1,this.rowId=null,this.businessKeySanitised=null,this.beans=t,this.gos=t.gos,this.rowNode=e,this.paginationPage=t.paginationProxy.getCurrentPage(),this.useAnimationFrameForCreate=r,this.printLayout=n,this.suppressRowTransform=this.gos.get("suppressRowTransform"),this.instanceId=e.id+"-"+fa++,this.rowId=Ct(e.id),this.initRowBusinessKey(),this.rowFocused=t.focusService.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned),this.rowLevel=t.rowCssClassCalculator.calculateRowLevel(this.rowNode),this.setRowType(),this.setAnimateFlags(i),this.rowStyles=this.processStylesFromGridOptions(),this.isFullWidth()&&!this.gos.get("suppressCellFocus")&&(this.tabIndex=-1),this.addListeners()}initRowBusinessKey(){this.businessKeyForNodeFunc=this.gos.get("getBusinessKeyForNode"),this.updateRowBusinessKey()}updateRowBusinessKey(){if("function"!=typeof this.businessKeyForNodeFunc)return;const e=this.businessKeyForNodeFunc(this.rowNode);this.businessKeySanitised=Ct(e)}getRowId(){return this.rowId}getRowStyles(){return this.rowStyles}getTabIndex(){return this.tabIndex}isSticky(){return this.rowNode.sticky}getInstanceId(){return this.instanceId}setComp(e,t,i){const r={rowComp:e,element:t,containerType:i};this.allRowGuis.push(r),"left"===i?this.leftGui=r:"right"===i?this.rightGui=r:"fullWidth"===i?this.fullWidthGui=r:this.centerGui=r,this.initialiseRowComp(r),"FullWidthLoading"===this.rowType||this.rowNode.rowPinned||this.beans.rowRenderer.dispatchFirstDataRenderedEvent()}unsetComp(e){switch(this.allRowGuis=this.allRowGuis.filter(t=>t.containerType!==e),e){case"left":this.leftGui=void 0;break;case"right":this.rightGui=void 0;break;case"fullWidth":this.fullWidthGui=void 0;break;case"center":this.centerGui=void 0}}isCacheable(){return"FullWidthDetail"===this.rowType&&this.gos.get("keepDetailRows")}setCached(e){const t=e?"none":"";this.allRowGuis.forEach(e=>e.element.style.display=t)}initialiseRowComp(t){const i=this.gos;this.listenOnDomOrder(t),this.beans.columnModel.wasAutoRowHeightEverActive()&&this.rowNode.checkAutoHeights(),this.onRowHeightChanged(t),this.updateRowIndexes(t),this.setFocusedClasses(t),this.setStylesFromGridOptions(!1,t),i.isRowSelection()&&this.rowNode.selectable&&this.onRowSelected(t),this.updateColumnLists(!this.useAnimationFrameForCreate);const r=t.rowComp;this.getInitialRowClasses(t.containerType).forEach(e=>r.addOrRemoveCssClass(e,!0)),this.executeSlideAndFadeAnimations(t),this.rowNode.group&&ti(t.element,1==this.rowNode.expanded),this.setRowCompRowId(r),this.setRowCompRowBusinessKey(r),i.setDomData(t.element,e.DOM_DATA_KEY_ROW_CTRL,this),this.addDestroyFunc(()=>i.setDomData(t.element,e.DOM_DATA_KEY_ROW_CTRL,null)),this.useAnimationFrameForCreate?this.beans.animationFrameService.createTask(this.addHoverFunctionality.bind(this,t.element),this.rowNode.rowIndex,"createTasksP2"):this.addHoverFunctionality(t.element),this.isFullWidth()&&this.setupFullWidth(t),i.get("rowDragEntireRow")&&this.addRowDraggerToRow(t),this.useAnimationFrameForCreate&&this.beans.animationFrameService.addDestroyTask(()=>{this.isAlive()&&t.rowComp.addOrRemoveCssClass("ag-after-created",!0)}),this.executeProcessRowPostCreateFunc()}setRowCompRowBusinessKey(e){null!=this.businessKeySanitised&&e.setRowBusinessKey(this.businessKeySanitised)}getBusinessKey(){return this.businessKeySanitised}setRowCompRowId(e){this.rowId=Ct(this.rowNode.id),null!=this.rowId&&e.setRowId(this.rowId)}executeSlideAndFadeAnimations(e){const{containerType:t}=e;this.slideInAnimation[t]&&(Y(()=>{this.onTopChanged()}),this.slideInAnimation[t]=!1),this.fadeInAnimation[t]&&(Y(()=>{e.rowComp.addOrRemoveCssClass("ag-opacity-zero",!1)}),this.fadeInAnimation[t]=!1)}addRowDraggerToRow(e){if(this.gos.get("enableRangeSelection"))return void z("Setting `rowDragEntireRow: true` in the gridOptions doesn't work with `enableRangeSelection: true`");const t=this.beans.localeService.getLocaleTextFunc(),i=new Vs(()=>`1 ${t("rowDragRow","row")}`,this.rowNode,void 0,e.element,void 0,!0),r=this.createBean(i,this.beans.context);this.rowDragComps.push(r)}setupFullWidth(e){const t=this.getPinnedForContainer(e.containerType);if("FullWidthDetail"==this.rowType&&!ne.__assertRegistered("@ag-grid-enterprise/master-detail","cell renderer 'agDetailCellRenderer' (for master detail)",this.beans.context.getGridId()))return;const i=this.createFullWidthCompDetails(e.element,t);e.rowComp.showFullWidth(i)}isPrintLayout(){return this.printLayout}getFullWidthCellRenderers(){var e,t;return this.gos.get("embedFullWidthRows")?this.allRowGuis.map(e=>{var t;return null==(t=null==e?void 0:e.rowComp)?void 0:t.getFullWidthCellRenderer()}):[null==(t=null==(e=this.fullWidthGui)?void 0:e.rowComp)?void 0:t.getFullWidthCellRenderer()]}getCellElement(e){const t=this.getCellCtrl(e);return t?t.getGui():null}executeProcessRowPostCreateFunc(){const e=this.gos.getCallback("processRowPostCreate");e&&this.areAllContainersReady()&&e({eRow:this.centerGui.element,ePinnedLeftRow:this.leftGui?this.leftGui.element:void 0,ePinnedRightRow:this.rightGui?this.rightGui.element:void 0,node:this.rowNode,rowIndex:this.rowNode.rowIndex,addRenderedRowListener:this.addEventListener.bind(this)})}areAllContainersReady(){const e=!!this.leftGui||!this.beans.columnModel.isPinningLeft(),t=!!this.centerGui,i=!!this.rightGui||!this.beans.columnModel.isPinningRight();return e&&t&&i}setRowType(){const e=this.rowNode.stub&&!this.gos.get("suppressServerSideFullWidthLoadingRow"),t=this.rowNode.isFullWidthCell(),i=this.gos.get("masterDetail")&&this.rowNode.detail,r=this.beans.columnModel.isPivotMode(),n=!!this.rowNode.group&&!this.rowNode.footer&&this.gos.isGroupUseEntireRow(r);this.rowType=e?"FullWidthLoading":i?"FullWidthDetail":t?"FullWidth":n?"FullWidthGroup":"Normal"}updateColumnLists(e=!1,t=!1){this.isFullWidth()||(e||this.gos.get("suppressAnimationFrame")||this.printLayout?this.updateColumnListsImpl(t):this.updateColumnListsPending||(this.beans.animationFrameService.createTask(()=>{this.active&&this.updateColumnListsImpl(!0)},this.rowNode.rowIndex,"createTasksP1"),this.updateColumnListsPending=!0))}createCellCtrls(e,t,i=null){const r={list:[],map:{}},n=(e,t)=>{r.list.push(t),r.map[e]=t};return t.forEach(t=>{const i=t.getInstanceId();let r=e.map[i];r||(r=new ga(t,this.rowNode,this.beans,this)),n(i,r)}),e.list.forEach(e=>{null==r.map[e.getColumn().getInstanceId()]&&(this.isCellEligibleToBeRemoved(e,i)?e.destroy():n(e.getColumn().getInstanceId(),e))}),r}updateColumnListsImpl(e){this.updateColumnListsPending=!1,this.createAllCellCtrls(),this.setCellCtrls(e)}setCellCtrls(e){this.allRowGuis.forEach(t=>{const i=this.getCellCtrlsForContainer(t.containerType);t.rowComp.setCellCtrls(i,e)})}getCellCtrlsForContainer(e){switch(e){case"left":return this.leftCellCtrls.list;case"right":return this.rightCellCtrls.list;case"fullWidth":return[];case"center":return this.centerCellCtrls.list;default:throw new Error(`Unhandled case: ${e}`)}}createAllCellCtrls(){const e=this.beans.columnModel;if(this.printLayout)this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,e.getAllDisplayedColumns()),this.leftCellCtrls={list:[],map:{}},this.rightCellCtrls={list:[],map:{}};else{const t=e.getViewportCenterColumnsForRow(this.rowNode);this.centerCellCtrls=this.createCellCtrls(this.centerCellCtrls,t);const i=e.getDisplayedLeftColumnsForRow(this.rowNode);this.leftCellCtrls=this.createCellCtrls(this.leftCellCtrls,i,"left");const r=e.getDisplayedRightColumnsForRow(this.rowNode);this.rightCellCtrls=this.createCellCtrls(this.rightCellCtrls,r,"right")}}isCellEligibleToBeRemoved(e,t){const i=!0;if(e.getColumn().getPinned()!=t)return i;const r=e.isEditing(),n=this.beans.focusService.isCellFocused(e.getCellPosition());if(r||n){const t=e.getColumn();return!(this.beans.columnModel.getAllDisplayedColumns().indexOf(t)>=0)&&i}return i}getDomOrder(){return this.gos.get("ensureDomOrder")||this.gos.isDomLayout("print")}listenOnDomOrder(e){const t=()=>{e.rowComp.setDomOrder(this.getDomOrder())};this.addManagedPropertyListener("domLayout",t),this.addManagedPropertyListener("ensureDomOrder",t)}setAnimateFlags(e){if(this.isSticky()||!e)return;const t=C(this.rowNode.oldRowTop),i=this.beans.columnModel.isPinningLeft(),r=this.beans.columnModel.isPinningRight();if(t){if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(this.slideInAnimation.fullWidth=!0);this.slideInAnimation.center=!0,this.slideInAnimation.left=i,this.slideInAnimation.right=r}else{if(this.isFullWidth()&&!this.gos.get("embedFullWidthRows"))return void(this.fadeInAnimation.fullWidth=!0);this.fadeInAnimation.center=!0,this.fadeInAnimation.left=i,this.fadeInAnimation.right=r}}isEditing(){return this.editingRow}isFullWidth(){return"Normal"!==this.rowType}refreshFullWidth(){const e=(e,t)=>!e||e.rowComp.refreshFullWidth(()=>this.createFullWidthCompDetails(e.element,t).params),t=e(this.fullWidthGui,null),i=e(this.centerGui,null),r=e(this.leftGui,"left"),n=e(this.rightGui,"right");return t&&i&&r&&n}addListeners(){this.addManagedListener(this.rowNode,Ls.EVENT_HEIGHT_CHANGED,()=>this.onRowHeightChanged()),this.addManagedListener(this.rowNode,Ls.EVENT_ROW_SELECTED,()=>this.onRowSelected()),this.addManagedListener(this.rowNode,Ls.EVENT_ROW_INDEX_CHANGED,this.onRowIndexChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_TOP_CHANGED,this.onTopChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_EXPANDED_CHANGED,this.updateExpandedCss.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_HAS_CHILDREN_CHANGED,this.updateExpandedCss.bind(this)),this.rowNode.detail&&this.addManagedListener(this.rowNode.parent,Ls.EVENT_DATA_CHANGED,this.onRowNodeDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_DATA_CHANGED,this.onRowNodeDataChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,this.postProcessCss.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_HIGHLIGHT_CHANGED,this.onRowNodeHighlightChanged.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_DRAGGING_CHANGED,this.postProcessRowDragging.bind(this)),this.addManagedListener(this.rowNode,Ls.EVENT_UI_LEVEL_CHANGED,this.onUiLevelChanged.bind(this));const e=this.beans.eventService;this.addManagedListener(e,lt.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED,this.onPaginationPixelOffsetChanged.bind(this)),this.addManagedListener(e,lt.EVENT_HEIGHT_SCALE_CHANGED,this.onTopChanged.bind(this)),this.addManagedListener(e,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(e,lt.EVENT_VIRTUAL_COLUMNS_CHANGED,this.onVirtualColumnsChanged.bind(this)),this.addManagedListener(e,lt.EVENT_CELL_FOCUSED,this.onCellFocusChanged.bind(this)),this.addManagedListener(e,lt.EVENT_CELL_FOCUS_CLEARED,this.onCellFocusChanged.bind(this)),this.addManagedListener(e,lt.EVENT_PAGINATION_CHANGED,this.onPaginationChanged.bind(this)),this.addManagedListener(e,lt.EVENT_MODEL_UPDATED,this.refreshFirstAndLastRowStyles.bind(this)),this.addManagedListener(e,lt.EVENT_COLUMN_MOVED,this.updateColumnLists.bind(this)),this.addDestroyFunc(()=>{this.destroyBeans(this.rowDragComps,this.beans.context),this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature,this.beans.context))}),this.addManagedPropertyListeners(["rowDragEntireRow"],()=>{this.gos.get("rowDragEntireRow")?this.allRowGuis.forEach(e=>{this.addRowDraggerToRow(e)}):(this.destroyBeans(this.rowDragComps,this.beans.context),this.rowDragComps=[])}),this.addListenersForCellComps()}addListenersForCellComps(){this.addManagedListener(this.rowNode,Ls.EVENT_ROW_INDEX_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onRowIndexChanged())}),this.addManagedListener(this.rowNode,Ls.EVENT_CELL_CHANGED,e=>{this.getAllCellCtrls().forEach(t=>t.onCellChanged(e))})}onRowNodeDataChanged(e){if(this.isFullWidth()!==!!this.rowNode.isFullWidthCell())this.beans.rowRenderer.redrawRow(this.rowNode);else{if(this.isFullWidth())return void(this.refreshFullWidth()||this.beans.rowRenderer.redrawRow(this.rowNode));this.getAllCellCtrls().forEach(t=>t.refreshCell({suppressFlash:!e.update,newData:!e.update})),this.allRowGuis.forEach(e=>{this.setRowCompRowId(e.rowComp),this.updateRowBusinessKey(),this.setRowCompRowBusinessKey(e.rowComp)}),this.onRowSelected(),this.postProcessCss()}}postProcessCss(){this.setStylesFromGridOptions(!0),this.postProcessClassesFromGridOptions(),this.postProcessRowClassRules(),this.postProcessRowDragging()}onRowNodeHighlightChanged(){const e=this.rowNode.highlighted;this.allRowGuis.forEach(t=>{const i=0===e,r=1===e;t.rowComp.addOrRemoveCssClass("ag-row-highlight-above",i),t.rowComp.addOrRemoveCssClass("ag-row-highlight-below",r)})}postProcessRowDragging(){const e=this.rowNode.dragging;this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-dragging",e))}updateExpandedCss(){const e=this.rowNode.isExpandable(),t=1==this.rowNode.expanded;this.allRowGuis.forEach(i=>{i.rowComp.addOrRemoveCssClass("ag-row-group",e),i.rowComp.addOrRemoveCssClass("ag-row-group-expanded",e&&t),i.rowComp.addOrRemoveCssClass("ag-row-group-contracted",e&&!t),ti(i.element,e&&t)})}onDisplayedColumnsChanged(){this.updateColumnLists(!0),this.beans.columnModel.wasAutoRowHeightEverActive()&&this.rowNode.checkAutoHeights()}onVirtualColumnsChanged(){this.updateColumnLists(!1,!0)}getRowPosition(){return{rowPinned:v(this.rowNode.rowPinned),rowIndex:this.rowNode.rowIndex}}onKeyboardNavigate(e){const t=this.allRowGuis.find(t=>t.element.contains(e.target));if((t?t.element:null)!==e.target)return;const i=this.rowNode,r=this.beans.focusService.getFocusedCell(),n={rowIndex:i.rowIndex,rowPinned:i.rowPinned,column:r&&r.column};this.beans.navigationService.navigateToNextCell(e,e.key,n,!0),e.preventDefault()}onTabKeyDown(e){if(e.defaultPrevented||Ye(e))return;const t=this.allRowGuis.find(t=>t.element.contains(e.target)),i=t?t.element:null,r=i===e.target;let n=null;r||(n=this.beans.focusService.findNextFocusableElement(i,!1,e.shiftKey)),(this.isFullWidth()&&r||!n)&&this.beans.navigationService.onTabKeyDown(this,e)}getFullWidthElement(){return this.fullWidthGui?this.fullWidthGui.element:null}getRowYPosition(){var e;const t=null==(e=this.allRowGuis.find(e=>Sr(e.element)))?void 0:e.element;return t?t.getBoundingClientRect().top:0}onFullWidthRowFocused(e){var t;const i=this.rowNode,r=!!e&&this.isFullWidth()&&e.rowIndex===i.rowIndex&&e.rowPinned==i.rowPinned,n=this.fullWidthGui?this.fullWidthGui.element:null==(t=this.centerGui)?void 0:t.element;n&&(n.classList.toggle("ag-full-width-focus",r),r&&n.focus({preventScroll:!0}))}recreateCell(e){this.centerCellCtrls=this.removeCellCtrl(this.centerCellCtrls,e),this.leftCellCtrls=this.removeCellCtrl(this.leftCellCtrls,e),this.rightCellCtrls=this.removeCellCtrl(this.rightCellCtrls,e),e.destroy(),this.updateColumnLists()}removeCellCtrl(e,t){const i={list:[],map:{}};return e.list.forEach(e=>{e!==t&&(i.list.push(e),i.map[e.getColumn().getInstanceId()]=e)}),i}onMouseEvent(e,t){switch(e){case"dblclick":this.onRowDblClick(t);break;case"click":this.onRowClick(t);break;case"touchstart":case"mousedown":this.onRowMouseDown(t)}}createRowEvent(e,t){return this.gos.addGridCommonParams({type:e,node:this.rowNode,data:this.rowNode.data,rowIndex:this.rowNode.rowIndex,rowPinned:this.rowNode.rowPinned,event:t})}createRowEventWithSource(e,t){const i=this.createRowEvent(e,t);return i.source=this,i}onRowDblClick(e){if(Ye(e))return;const t=this.createRowEventWithSource(lt.EVENT_ROW_DOUBLE_CLICKED,e);this.beans.eventService.dispatchEvent(t)}onRowMouseDown(e){if(this.lastMouseDownOnDragger=lr(e.target,"ag-row-drag",3),!this.isFullWidth())return;const t=this.rowNode,i=this.beans.columnModel;this.beans.rangeService&&this.beans.rangeService.removeAllCellRanges(),this.beans.focusService.setFocusedCell({rowIndex:t.rowIndex,column:i.getAllDisplayedColumns()[0],rowPinned:t.rowPinned,forceBrowserFocus:!0})}onRowClick(e){if(Ye(e)||this.lastMouseDownOnDragger)return;const t=this.createRowEventWithSource(lt.EVENT_ROW_CLICKED,e);this.beans.eventService.dispatchEvent(t);const i=e.ctrlKey||e.metaKey,r=e.shiftKey;if(this.gos.get("groupSelectsChildren")&&this.rowNode.group||this.isRowSelectionBlocked()||this.gos.get("suppressRowClickSelection"))return;const n=this.gos.get("rowMultiSelectWithClick"),s=!this.gos.get("suppressRowDeselection"),o="rowClicked";if(this.rowNode.isSelected())n?this.rowNode.setSelectedParams({newValue:!1,event:e,source:o}):i?s&&this.rowNode.setSelectedParams({newValue:!1,event:e,source:o}):this.rowNode.setSelectedParams({newValue:!0,clearSelection:!r,rangeSelect:r,event:e,source:o});else{const t=!n&&!i;this.rowNode.setSelectedParams({newValue:!0,clearSelection:t,rangeSelect:r,event:e,source:o})}}isRowSelectionBlocked(){return!this.rowNode.selectable||!!this.rowNode.rowPinned||!this.gos.isRowSelection()}setupDetailRowAutoHeight(e){if("FullWidthDetail"!==this.rowType)return;if(!this.gos.get("detailRowAutoHeight"))return;const t=()=>{const t=e.clientHeight;if(null!=t&&t>0){const e=()=>{this.rowNode.setRowHeight(t),this.beans.clientSideRowModel?this.beans.clientSideRowModel.onRowHeightChanged():this.beans.serverSideRowModel&&this.beans.serverSideRowModel.onRowHeightChanged()};window.setTimeout(e,0)}},i=this.beans.resizeObserverService.observeResize(e,t);this.addDestroyFunc(i),t()}createFullWidthCompDetails(e,t){const i=this.gos.addGridCommonParams({fullWidth:!0,data:this.rowNode.data,node:this.rowNode,value:this.rowNode.key,valueFormatted:this.rowNode.key,rowIndex:this.rowNode.rowIndex,eGridCell:e,eParentOfValue:e,pinned:t,addRenderedRowListener:this.addEventListener.bind(this),registerRowDragger:(e,t,i,r)=>this.addFullWidthRowDragging(e,t,i,r),setTooltip:(e,t)=>this.refreshRowTooltip(e,t)});switch(this.rowType){case"FullWidthDetail":return this.beans.userComponentFactory.getFullWidthDetailCellRendererDetails(i);case"FullWidthGroup":return this.beans.userComponentFactory.getFullWidthGroupCellRendererDetails(i);case"FullWidthLoading":return this.beans.userComponentFactory.getFullWidthLoadingCellRendererDetails(i);default:return this.beans.userComponentFactory.getFullWidthCellRendererDetails(i)}}refreshRowTooltip(e,t){if(!this.fullWidthGui)return;const i={getGui:()=>this.fullWidthGui.element,getTooltipValue:()=>e,getLocation:()=>"fullWidthRow",shouldDisplayTooltip:t};this.tooltipFeature&&this.destroyBean(this.tooltipFeature,this.beans.context),this.tooltipFeature=this.createBean(new mn(i,this.beans))}addFullWidthRowDragging(e,t,i="",r){if(!this.isFullWidth())return;const n=new Vs(()=>i,this.rowNode,void 0,e,t,r);this.createBean(n,this.beans.context),this.addDestroyFunc(()=>{this.destroyBean(n,this.beans.context)})}onUiLevelChanged(){const e=this.beans.rowCssClassCalculator.calculateRowLevel(this.rowNode);if(this.rowLevel!=e){const t="ag-row-level-"+e,i="ag-row-level-"+this.rowLevel;this.allRowGuis.forEach(e=>{e.rowComp.addOrRemoveCssClass(t,!0),e.rowComp.addOrRemoveCssClass(i,!1)})}this.rowLevel=e}isFirstRowOnPage(){return this.rowNode.rowIndex===this.beans.paginationProxy.getPageFirstRow()}isLastRowOnPage(){return this.rowNode.rowIndex===this.beans.paginationProxy.getPageLastRow()}refreshFirstAndLastRowStyles(){const e=this.isFirstRowOnPage(),t=this.isLastRowOnPage();this.firstRowOnPage!==e&&(this.firstRowOnPage=e,this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-first",e))),this.lastRowOnPage!==t&&(this.lastRowOnPage=t,this.allRowGuis.forEach(e=>e.rowComp.addOrRemoveCssClass("ag-row-last",t)))}stopEditing(e=!1){if(this.stoppingRowEdit)return;const t=this.getAllCellCtrls(),i=this.editingRow;this.stoppingRowEdit=!0;let r=!1;for(const n of t){const t=n.stopEditing(e);i&&!e&&!r&&t&&(r=!0)}if(r){const e=this.createRowEvent(lt.EVENT_ROW_VALUE_CHANGED);this.beans.eventService.dispatchEvent(e)}i&&this.setEditingRow(!1),this.stoppingRowEdit=!1}setInlineEditingCss(e){this.allRowGuis.forEach(t=>{t.rowComp.addOrRemoveCssClass("ag-row-inline-editing",e),t.rowComp.addOrRemoveCssClass("ag-row-not-inline-editing",!e)})}setEditingRow(e){this.editingRow=e,this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass("ag-row-editing",e));const t=e?this.createRowEvent(lt.EVENT_ROW_EDITING_STARTED):this.createRowEvent(lt.EVENT_ROW_EDITING_STOPPED);this.beans.eventService.dispatchEvent(t)}startRowEditing(e=null,t=null,i=null){this.editingRow||this.getAllCellCtrls().reduce((r,n)=>{const s=n===t;return s?n.startEditing(e,s,i):n.startEditing(null,s,i),!!r||n.isEditing()},!1)&&this.setEditingRow(!0)}getAllCellCtrls(){return 0===this.leftCellCtrls.list.length&&0===this.rightCellCtrls.list.length?this.centerCellCtrls.list:[...this.centerCellCtrls.list,...this.leftCellCtrls.list,...this.rightCellCtrls.list]}postProcessClassesFromGridOptions(){const e=this.beans.rowCssClassCalculator.processClassesFromGridOptions(this.rowNode);e&&e.length&&e.forEach(e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!0))})}postProcessRowClassRules(){this.beans.rowCssClassCalculator.processRowClassRules(this.rowNode,e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!0))},e=>{this.allRowGuis.forEach(t=>t.rowComp.addOrRemoveCssClass(e,!1))})}setStylesFromGridOptions(e,t){e&&(this.rowStyles=this.processStylesFromGridOptions()),this.forEachGui(t,e=>e.rowComp.setUserStyles(this.rowStyles))}getPinnedForContainer(e){return"left"===e?"left":"right"===e?"right":null}getInitialRowClasses(e){const t=this.getPinnedForContainer(e),i={rowNode:this.rowNode,rowFocused:this.rowFocused,fadeRowIn:this.fadeInAnimation[e],rowIsEven:this.rowNode.rowIndex%2==0,rowLevel:this.rowLevel,fullWidthRow:this.isFullWidth(),firstRowOnPage:this.isFirstRowOnPage(),lastRowOnPage:this.isLastRowOnPage(),printLayout:this.printLayout,expandable:this.rowNode.isExpandable(),pinned:t};return this.beans.rowCssClassCalculator.getInitialRowClasses(i)}processStylesFromGridOptions(){const e=this.gos.get("rowStyle");if(e&&"function"==typeof e)return void console.warn("AG Grid: rowStyle should be an object of key/value styles, not be a function, use getRowStyle() instead");const t=this.gos.getCallback("getRowStyle");let i;return t&&(i=t({data:this.rowNode.data,node:this.rowNode,rowIndex:this.rowNode.rowIndex})),i||e?Object.assign({},e,i):this.emptyStyle}onRowSelected(e){const t=!!this.rowNode.isSelected();this.forEachGui(e,e=>{e.rowComp.addOrRemoveCssClass("ag-row-selected",t),pi(e.element,t),!e.element.contains(this.beans.gos.getActiveDomElement())||e!==this.centerGui&&e!==this.fullWidthGui||this.announceDescription()})}announceDescription(){if(this.isRowSelectionBlocked())return;const e=this.rowNode.isSelected();if(e&&this.beans.gos.get("suppressRowDeselection"))return;const t=this.beans.localeService.getLocaleTextFunc()(e?"ariaRowDeselect":"ariaRowSelect",`Press SPACE to ${e?"deselect":"select"} this row.`);this.beans.ariaAnnouncementService.announceValue(t)}addHoverFunctionality(e){this.active&&(this.addManagedListener(e,"mouseenter",()=>this.rowNode.onMouseEnter()),this.addManagedListener(e,"mouseleave",()=>this.rowNode.onMouseLeave()),this.addManagedListener(this.rowNode,Ls.EVENT_MOUSE_ENTER,()=>{this.beans.dragService.isDragging()||this.gos.get("suppressRowHoverHighlight")||(e.classList.add("ag-row-hover"),this.rowNode.setHovered(!0))}),this.addManagedListener(this.rowNode,Ls.EVENT_MOUSE_LEAVE,()=>{e.classList.remove("ag-row-hover"),this.rowNode.setHovered(!1)}))}roundRowTopToBounds(e){const t=this.beans.ctrlsService.getGridBodyCtrl().getScrollFeature().getApproximateVScollPosition(),i=this.applyPaginationOffset(t.top,!0)-100,r=this.applyPaginationOffset(t.bottom,!0)+100;return Math.min(Math.max(i,e),r)}getFrameworkOverrides(){return this.beans.frameworkOverrides}forEachGui(e,t){e?t(e):this.allRowGuis.forEach(t)}onRowHeightChanged(e){if(null==this.rowNode.rowHeight)return;const t=this.rowNode.rowHeight,i=this.beans.environment.getDefaultRowHeight(),r=this.gos.isGetRowHeightFunction()?this.gos.getRowHeightForNode(this.rowNode).height:void 0,n=r?Math.min(i,r)-2+"px":void 0;this.forEachGui(e,e=>{e.element.style.height=`${t}px`,n&&e.element.style.setProperty("--ag-line-height",n)})}addEventListener(e,t){super.addEventListener(e,t)}removeEventListener(e,t){super.removeEventListener(e,t)}destroyFirstPass(e=!1){if(this.active=!1,!e&&this.gos.isAnimateRows()&&!this.isSticky())if(null!=this.rowNode.rowTop){const e=this.roundRowTopToBounds(this.rowNode.rowTop);this.setRowTop(e)}else this.allRowGuis.forEach(e=>e.rowComp.addOrRemoveCssClass("ag-opacity-zero",!0));this.rowNode.setHovered(!1);const t=this.createRowEvent(lt.EVENT_VIRTUAL_ROW_REMOVED);this.dispatchEvent(t),this.beans.eventService.dispatchEvent(t),super.destroy()}destroySecondPass(){this.allRowGuis.length=0,this.stopEditing();const e=e=>(e.list.forEach(e=>e.destroy()),{list:[],map:{}});this.centerCellCtrls=e(this.centerCellCtrls),this.leftCellCtrls=e(this.leftCellCtrls),this.rightCellCtrls=e(this.rightCellCtrls)}setFocusedClasses(e){this.forEachGui(e,e=>{e.rowComp.addOrRemoveCssClass("ag-row-focus",this.rowFocused),e.rowComp.addOrRemoveCssClass("ag-row-no-focus",!this.rowFocused)})}onCellFocusChanged(){const e=this.beans.focusService.isRowFocused(this.rowNode.rowIndex,this.rowNode.rowPinned);e!==this.rowFocused&&(this.rowFocused=e,this.setFocusedClasses()),!e&&this.editingRow&&this.stopEditing(!1)}onPaginationChanged(){const e=this.beans.paginationProxy.getCurrentPage();this.paginationPage!==e&&(this.paginationPage=e,this.onTopChanged()),this.refreshFirstAndLastRowStyles()}onTopChanged(){this.setRowTop(this.rowNode.rowTop)}onPaginationPixelOffsetChanged(){this.onTopChanged()}applyPaginationOffset(e,t=!1){return this.rowNode.isRowPinned()||this.rowNode.sticky?e:e+this.beans.paginationProxy.getPixelOffset()*(t?1:-1)}setRowTop(e){if(!this.printLayout&&C(e)){const t=this.applyPaginationOffset(e),i=`${this.rowNode.isRowPinned()||this.rowNode.sticky?t:this.beans.rowContainerHeightService.getRealPixelPosition(t)}px`;this.setRowTopStyle(i)}}getInitialRowTop(e){return this.suppressRowTransform?this.getInitialRowTopShared(e):void 0}getInitialTransform(e){return this.suppressRowTransform?void 0:`translateY(${this.getInitialRowTopShared(e)})`}getInitialRowTopShared(e){if(this.printLayout)return"";let t;if(this.isSticky())t=this.rowNode.stickyRowTop;else{const i=this.slideInAnimation[e]?this.roundRowTopToBounds(this.rowNode.oldRowTop):this.rowNode.rowTop,r=this.applyPaginationOffset(i);t=this.rowNode.isRowPinned()?r:this.beans.rowContainerHeightService.getRealPixelPosition(r)}return t+"px"}setRowTopStyle(e){this.allRowGuis.forEach(t=>this.suppressRowTransform?t.rowComp.setTop(e):t.rowComp.setTransform(`translateY(${e})`))}getRowNode(){return this.rowNode}getCellCtrl(e){let t=null;return this.getAllCellCtrls().forEach(i=>{i.getColumn()==e&&(t=i)}),null!=t||this.getAllCellCtrls().forEach(i=>{i.getColSpanningList().indexOf(e)>=0&&(t=i)}),t}onRowIndexChanged(){null!=this.rowNode.rowIndex&&(this.onCellFocusChanged(),this.updateRowIndexes(),this.postProcessCss())}getRowIndex(){return this.rowNode.getRowIndexString()}updateRowIndexes(e){const t=this.rowNode.getRowIndexString(),i=this.beans.headerNavigationService.getHeaderRowCount()+this.beans.filterManager.getHeaderRowCount(),r=this.rowNode.rowIndex%2==0,n=i+this.rowNode.rowIndex+1;this.forEachGui(e,e=>{e.rowComp.setRowIndex(t),e.rowComp.addOrRemoveCssClass("ag-row-even",r),e.rowComp.addOrRemoveCssClass("ag-row-odd",!r),ai(e.element,n)})}};ma.DOM_DATA_KEY_ROW_CTRL="renderedRow";var va=ma,Ca=class extends rt{constructor(e){super(),this.element=e}postConstruct(){this.addKeyboardListeners(),this.addMouseListeners(),this.mockContextMenuForIPad()}addKeyboardListeners(){const e="keydown",t=this.processKeyboardEvent.bind(this,e);this.addManagedListener(this.element,e,t)}addMouseListeners(){["dblclick","contextmenu","mouseover","mouseout","click",Qe("touchstart")?"touchstart":"mousedown"].forEach(e=>{const t=this.processMouseEvent.bind(this,e);this.addManagedListener(this.element,e,t)})}processMouseEvent(e,t){if(!this.mouseEventService.isEventFromThisGrid(t)||Ye(t))return;const i=this.getRowForEvent(t),r=this.mouseEventService.getRenderedCellForEvent(t);"contextmenu"===e?this.handleContextMenuMouseEvent(t,void 0,i,r):(r&&r.onMouseEvent(e,t),i&&i.onMouseEvent(e,t))}mockContextMenuForIPad(){if(!Di())return;const e=new ms(this.element);this.addManagedListener(e,ms.EVENT_LONG_TAP,e=>{const t=this.getRowForEvent(e.touchEvent),i=this.mouseEventService.getRenderedCellForEvent(e.touchEvent);this.handleContextMenuMouseEvent(void 0,e.touchEvent,t,i)}),this.addDestroyFunc(()=>e.destroy())}getRowForEvent(e){let t=e.target;for(;t;){const e=this.gos.getDomData(t,va.DOM_DATA_KEY_ROW_CTRL);if(e)return e;t=t.parentElement}return null}handleContextMenuMouseEvent(e,t,i,r){const n=i?i.getRowNode():null,s=r?r.getColumn():null;let o=null;if(s){const i=e||t;r.dispatchCellContextMenuEvent(null!=i?i:null),o=this.valueService.getValue(s,n)}const a=this.ctrlsService.getGridBodyCtrl(),l=r?r.getGui():a.getGridBodyElement();this.menuService.showContextMenu({mouseEvent:e,touchEvent:t,rowNode:n,column:s,value:o,anchorToElement:l})}getControlsForEventTarget(e){return{cellCtrl:Xe(this.gos,e,ga.DOM_DATA_KEY_CELL_CTRL),rowCtrl:Xe(this.gos,e,va.DOM_DATA_KEY_ROW_CTRL)}}processKeyboardEvent(e,t){const{cellCtrl:i,rowCtrl:r}=this.getControlsForEventTarget(t.target);t.defaultPrevented||(i?this.processCellKeyboardEvent(i,e,t):r&&r.isFullWidth()&&this.processFullWidthRowKeyboardEvent(r,e,t))}processCellKeyboardEvent(e,t,i){const r=e.getRowNode(),n=e.getColumn(),s=e.isEditing();if(Xr(this.gos,i,r,n,s)||"keydown"!==t||(!s&&this.navigationService.handlePageScrollingKey(i)||e.onKeyDown(i),this.doGridOperations(i,e.isEditing()),Qr(i)&&e.processCharacter(i)),"keydown"===t){const t=e.createEvent(i,lt.EVENT_CELL_KEY_DOWN);this.eventService.dispatchEvent(t)}}processFullWidthRowKeyboardEvent(e,t,i){const r=e.getRowNode(),n=this.focusService.getFocusedCell(),s=n&&n.column;if(!Xr(this.gos,i,r,s,!1)){const r=i.key;if("keydown"===t)switch(r){case Yr.PAGE_HOME:case Yr.PAGE_END:case Yr.PAGE_UP:case Yr.PAGE_DOWN:this.navigationService.handlePageScrollingKey(i,!0);break;case Yr.UP:case Yr.DOWN:e.onKeyboardNavigate(i);break;case Yr.TAB:e.onTabKeyDown(i)}}if("keydown"===t){const t=e.createRowEvent(lt.EVENT_CELL_KEY_DOWN,i);this.eventService.dispatchEvent(t)}}doGridOperations(e,t){if(!e.ctrlKey&&!e.metaKey)return;if(t)return;if(!this.mouseEventService.isEventFromThisGrid(e))return;const i=Jr(e);return i===Yr.A?this.onCtrlAndA(e):i===Yr.C?this.onCtrlAndC(e):i===Yr.D?this.onCtrlAndD(e):i===Yr.V?this.onCtrlAndV(e):i===Yr.X?this.onCtrlAndX(e):i===Yr.Y?this.onCtrlAndY():i===Yr.Z?this.onCtrlAndZ(e):void 0}onCtrlAndA(e){const{pinnedRowModel:t,paginationProxy:i,rangeService:r}=this;if(r&&i.isRowsToRender()){const[e,i]=[t.isEmpty("top"),t.isEmpty("bottom")],n=e?null:"top";let s,o;i?(s=null,o=this.paginationProxy.getRowCount()-1):(s="bottom",o=t.getPinnedBottomRowData().length-1);const a=this.columnModel.getAllDisplayedColumns();if(w(a))return;r.setCellRange({rowStartIndex:0,rowStartPinned:n,rowEndIndex:o,rowEndPinned:s,columnStart:a[0],columnEnd:_e(a)})}e.preventDefault()}onCtrlAndC(e){if(!this.clipboardService||this.gos.get("enableCellTextSelection"))return;const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||(e.preventDefault(),this.clipboardService.copyToClipboard())}onCtrlAndX(e){if(!this.clipboardService||this.gos.get("enableCellTextSelection")||this.gos.get("suppressCutToClipboard"))return;const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||(e.preventDefault(),this.clipboardService.cutToClipboard(void 0,"ui"))}onCtrlAndV(e){const{cellCtrl:t,rowCtrl:i}=this.getControlsForEventTarget(e.target);(null==t?void 0:t.isEditing())||(null==i?void 0:i.isEditing())||this.clipboardService&&!this.gos.get("suppressClipboardPaste")&&this.clipboardService.pasteFromClipboard()}onCtrlAndD(e){this.clipboardService&&!this.gos.get("suppressClipboardPaste")&&this.clipboardService.copyRangeDown(),e.preventDefault()}onCtrlAndZ(e){this.gos.get("undoRedoCellEditing")&&(e.preventDefault(),e.shiftKey?this.undoRedoService.redo("ui"):this.undoRedoService.undo("ui"))}onCtrlAndY(){this.undoRedoService.redo("ui")}};g([ue("mouseEventService")],Ca.prototype,"mouseEventService",2),g([ue("valueService")],Ca.prototype,"valueService",2),g([ue("menuService")],Ca.prototype,"menuService",2),g([ue("ctrlsService")],Ca.prototype,"ctrlsService",2),g([ue("navigationService")],Ca.prototype,"navigationService",2),g([ue("focusService")],Ca.prototype,"focusService",2),g([ue("undoRedoService")],Ca.prototype,"undoRedoService",2),g([ue("columnModel")],Ca.prototype,"columnModel",2),g([ue("paginationProxy")],Ca.prototype,"paginationProxy",2),g([ue("pinnedRowModel")],Ca.prototype,"pinnedRowModel",2),g([he("rangeService")],Ca.prototype,"rangeService",2),g([he("clipboardService")],Ca.prototype,"clipboardService",2),g([ae],Ca.prototype,"postConstruct",1);var ya=class extends rt{constructor(e){super(),this.centerContainerCtrl=e}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.listenForResize()}),this.addManagedListener(this.eventService,lt.EVENT_SCROLLBAR_WIDTH_CHANGED,this.onScrollbarWidthChanged.bind(this)),this.addManagedPropertyListeners(["alwaysShowHorizontalScroll","alwaysShowVerticalScroll"],()=>{this.checkViewportAndScrolls()})}listenForResize(){const e=()=>this.onCenterViewportResized();this.centerContainerCtrl.registerViewportResizeListener(e),this.gridBodyCtrl.registerBodyViewportResizeListener(e)}onScrollbarWidthChanged(){this.checkViewportAndScrolls()}onCenterViewportResized(){if(this.centerContainerCtrl.isViewportInTheDOMTree()){this.keepPinnedColumnsNarrowerThanViewport(),this.checkViewportAndScrolls();const e=this.centerContainerCtrl.getCenterWidth();e!==this.centerWidth&&(this.centerWidth=e,this.columnModel.refreshFlexedColumns({viewportWidth:this.centerWidth,updateBodyWidths:!0,fireResizedEvent:!0}))}else this.bodyHeight=0}keepPinnedColumnsNarrowerThanViewport(){const e=hr(this.gridBodyCtrl.getBodyViewportElement());if(e<=50)return;let t=this.getPinnedColumnsOverflowingViewport(e-50);const i=this.gos.getCallback("processUnpinnedColumns");t.length&&(i&&(t=i({columns:t,viewportWidth:e})),this.columnModel.setColumnsPinned(t,null,"viewportSizeFeature"))}getPinnedColumnsOverflowingViewport(e){const t=this.pinnedWidthService.getPinnedRightWidth()+this.pinnedWidthService.getPinnedLeftWidth();if(t<e)return[];const i=[...this.columnModel.getDisplayedLeftColumns()],r=[...this.columnModel.getDisplayedRightColumns()];let n=0,s=0;const o=[];let a=t-0-e;for(;(s<i.length||n<r.length)&&a>0;){if(n<r.length){const e=r[n++];a-=e.getActualWidth(),o.push(e)}if(s<i.length&&a>0){const e=i[s++];a-=e.getActualWidth(),o.push(e)}}return o}checkViewportAndScrolls(){this.updateScrollVisibleService(),this.checkBodyHeight(),this.onHorizontalViewportChanged(),this.gridBodyCtrl.getScrollFeature().checkScrollLeft()}getBodyHeight(){return this.bodyHeight}checkBodyHeight(){const e=ur(this.gridBodyCtrl.getBodyViewportElement());if(this.bodyHeight!==e){this.bodyHeight=e;const t={type:lt.EVENT_BODY_HEIGHT_CHANGED};this.eventService.dispatchEvent(t)}}updateScrollVisibleService(){this.updateScrollVisibleServiceImpl(),setTimeout(this.updateScrollVisibleServiceImpl.bind(this),500)}updateScrollVisibleServiceImpl(){const e={horizontalScrollShowing:this.isHorizontalScrollShowing(),verticalScrollShowing:this.gridBodyCtrl.isVerticalScrollShowing()};this.scrollVisibleService.setScrollsVisible(e)}isHorizontalScrollShowing(){return this.centerContainerCtrl.isHorizontalScrollShowing()}onHorizontalViewportChanged(){const e=this.centerContainerCtrl.getCenterWidth(),t=this.centerContainerCtrl.getViewportScrollLeft();this.columnModel.setViewportPosition(e,t)}};g([ue("ctrlsService")],ya.prototype,"ctrlsService",2),g([ue("pinnedWidthService")],ya.prototype,"pinnedWidthService",2),g([ue("columnModel")],ya.prototype,"columnModel",2),g([ue("scrollVisibleService")],ya.prototype,"scrollVisibleService",2),g([ae],ya.prototype,"postConstruct",1);var wa=class extends rt{constructor(e){super(),this.element=e}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_LEFT_PINNED_WIDTH_CHANGED,this.onPinnedLeftWidthChanged.bind(this))}onPinnedLeftWidthChanged(){const e=this.pinnedWidthService.getPinnedLeftWidth(),t=e>0;sr(this.element,t),xr(this.element,e)}getWidth(){return this.pinnedWidthService.getPinnedLeftWidth()}};g([ue("pinnedWidthService")],wa.prototype,"pinnedWidthService",2),g([ae],wa.prototype,"postConstruct",1);var Sa=class extends rt{constructor(e){super(),this.element=e}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED,this.onPinnedRightWidthChanged.bind(this))}onPinnedRightWidthChanged(){const e=this.pinnedWidthService.getPinnedRightWidth(),t=e>0;sr(this.element,t),xr(this.element,e)}getWidth(){return this.pinnedWidthService.getPinnedRightWidth()}};g([ue("pinnedWidthService")],Sa.prototype,"pinnedWidthService",2),g([ae],Sa.prototype,"postConstruct",1);var ba=class extends rt{constructor(e,t){super(),this.eContainer=e,this.eViewport=t}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,this.onHeightChanged.bind(this))}onHeightChanged(){const e=this.maxDivHeightScaler.getUiContainerHeight(),t=null!=e?`${e}px`:"";this.eContainer.style.height=t,this.eViewport&&(this.eViewport.style.height=t)}};g([ue("rowContainerHeightService")],ba.prototype,"maxDivHeightScaler",2),g([ae],ba.prototype,"postConstruct",1);var Ea=class extends rt{constructor(e){super(),this.eContainer=e}postConstruct(){this.rangeService&&(this.params={eElement:this.eContainer,onDragStart:this.rangeService.onDragStart.bind(this.rangeService),onDragStop:this.rangeService.onDragStop.bind(this.rangeService),onDragging:this.rangeService.onDragging.bind(this.rangeService)},this.addManagedPropertyListener("enableRangeSelection",e=>{e.currentValue?this.enableFeature():this.disableFeature()}),this.addDestroyFunc(()=>this.disableFeature()),this.gos.get("enableRangeSelection")&&this.enableFeature())}enableFeature(){this.dragService.addDragSource(this.params)}disableFeature(){this.dragService.removeDragSource(this.params)}};g([ue("dragService")],Ea.prototype,"dragService",2),g([he("rangeService")],Ea.prototype,"rangeService",2),g([ae],Ea.prototype,"postConstruct",1);var Aa=class extends rt{constructor(e,t=!1){super(),this.callback=e,this.addSpacer=t}postConstruct(){const e=this.setWidth.bind(this);this.addManagedPropertyListener("domLayout",e),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_CONTAINER_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_LEFT_PINNED_WIDTH_CHANGED,e),this.addSpacer&&(this.addManagedListener(this.eventService,lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_SCROLL_VISIBILITY_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_SCROLLBAR_WIDTH_CHANGED,e)),this.setWidth()}setWidth(){const{columnModel:e}=this,t=this.gos.isDomLayout("print"),i=e.getBodyContainerWidth(),r=e.getDisplayedColumnsLeftWidth(),n=e.getDisplayedColumnsRightWidth();let s;t?s=i+r+n:(s=i,this.addSpacer&&0===(this.gos.get("enableRtl")?r:n)&&this.scrollVisibleService.isVerticalScrollShowing()&&(s+=this.gos.getScrollbarWidth())),this.callback(s)}};g([ue("columnModel")],Aa.prototype,"columnModel",2),g([ue("scrollVisibleService")],Aa.prototype,"scrollVisibleService",2),g([ae],Aa.prototype,"postConstruct",1);var Ta=(e=>(e.LEFT="left",e.RIGHT="right",e.CENTER="center",e.FULL_WIDTH="fullWidth",e.TOP_LEFT="topLeft",e.TOP_RIGHT="topRight",e.TOP_CENTER="topCenter",e.TOP_FULL_WIDTH="topFullWidth",e.STICKY_TOP_LEFT="stickyTopLeft",e.STICKY_TOP_RIGHT="stickyTopRight",e.STICKY_TOP_CENTER="stickyTopCenter",e.STICKY_TOP_FULL_WIDTH="stickyTopFullWidth",e.STICKY_BOTTOM_LEFT="stickyBottomLeft",e.STICKY_BOTTOM_RIGHT="stickyBottomRight",e.STICKY_BOTTOM_CENTER="stickyBottomCenter",e.STICKY_BOTTOM_FULL_WIDTH="stickyBottomFullWidth",e.BOTTOM_LEFT="bottomLeft",e.BOTTOM_RIGHT="bottomRight",e.BOTTOM_CENTER="bottomCenter",e.BOTTOM_FULL_WIDTH="bottomFullWidth",e))(Ta||{}),Ma=(e=>(e.LEFT="left",e.RIGHT="right",e.CENTER="center",e.FULL_WIDTH="fullWidth",e))(Ma||{});function Ra(e){switch(e){case"center":case"topCenter":case"stickyTopCenter":case"bottomCenter":case"stickyBottomCenter":return"center";case"left":case"topLeft":case"stickyTopLeft":case"bottomLeft":case"stickyBottomLeft":return"left";case"right":case"topRight":case"stickyTopRight":case"bottomRight":case"stickyBottomRight":return"right";case"fullWidth":case"topFullWidth":case"stickyTopFullWidth":case"bottomFullWidth":case"stickyBottomFullWidth":return"fullWidth";default:throw Error("Invalid Row Container Type")}}var _a=bt([["center","ag-center-cols-container"],["left","ag-pinned-left-cols-container"],["right","ag-pinned-right-cols-container"],["fullWidth","ag-full-width-container"],["topCenter","ag-floating-top-container"],["topLeft","ag-pinned-left-floating-top"],["topRight","ag-pinned-right-floating-top"],["topFullWidth","ag-floating-top-full-width-container"],["stickyTopCenter","ag-sticky-top-container"],["stickyTopLeft","ag-pinned-left-sticky-top"],["stickyTopRight","ag-pinned-right-sticky-top"],["stickyTopFullWidth","ag-sticky-top-full-width-container"],["stickyBottomCenter","ag-sticky-bottom-container"],["stickyBottomLeft","ag-pinned-left-sticky-bottom"],["stickyBottomRight","ag-pinned-right-sticky-bottom"],["stickyBottomFullWidth","ag-sticky-bottom-full-width-container"],["bottomCenter","ag-floating-bottom-container"],["bottomLeft","ag-pinned-left-floating-bottom"],["bottomRight","ag-pinned-right-floating-bottom"],["bottomFullWidth","ag-floating-bottom-full-width-container"]]),Pa=bt([["center","ag-center-cols-viewport"],["topCenter","ag-floating-top-viewport"],["stickyTopCenter","ag-sticky-top-viewport"],["bottomCenter","ag-floating-bottom-viewport"],["stickyBottomCenter","ag-sticky-bottom-viewport"]]),xa=class e extends rt{constructor(e){super(),this.visible=!0,this.EMPTY_CTRLS=[],this.name=e,this.isFullWithContainer="topFullWidth"===this.name||"stickyTopFullWidth"===this.name||"stickyBottomFullWidth"===this.name||"bottomFullWidth"===this.name||"fullWidth"===this.name}static getRowContainerCssClasses(e){return{container:_a.get(e),viewport:Pa.get(e)}}static getPinned(e){switch(e){case"bottomLeft":case"topLeft":case"stickyTopLeft":case"stickyBottomLeft":case"left":return"left";case"bottomRight":case"topRight":case"stickyTopRight":case"stickyBottomRight":case"right":return"right";default:return null}}postConstruct(){this.enableRtl=this.gos.get("enableRtl"),this.forContainers(["center"],()=>this.viewportSizeFeature=this.createManagedBean(new ya(this)))}registerWithCtrlsService(){switch(this.name){case"fullWidth":case"topFullWidth":case"stickyTopFullWidth":case"bottomFullWidth":case"stickyBottomFullWidth":return;default:this.ctrlsService.register(this.name,this)}}forContainers(e,t){e.indexOf(this.name)>=0&&t()}getContainerElement(){return this.eContainer}getViewportSizeFeature(){return this.viewportSizeFeature}setComp(e,t,i){this.comp=e,this.eContainer=t,this.eViewport=i,this.createManagedBean(new Ca(this.eContainer)),this.addPreventScrollWhileDragging(),this.listenOnDomOrder(),this.stopHScrollOnPinnedRows();this.forContainers(["left","bottomLeft","topLeft","stickyTopLeft","stickyBottomLeft"],()=>{this.pinnedWidthFeature=this.createManagedBean(new wa(this.eContainer)),this.addManagedListener(this.eventService,lt.EVENT_LEFT_PINNED_WIDTH_CHANGED,()=>this.onPinnedWidthChanged())}),this.forContainers(["right","bottomRight","topRight","stickyTopRight","stickyBottomRight"],()=>{this.pinnedWidthFeature=this.createManagedBean(new Sa(this.eContainer)),this.addManagedListener(this.eventService,lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED,()=>this.onPinnedWidthChanged())}),this.forContainers(["center","left","right","fullWidth"],()=>this.createManagedBean(new ba(this.eContainer,"center"===this.name?i:void 0))),this.forContainers(["topCenter","topLeft","topRight","bottomCenter","bottomLeft","bottomRight","center","left","right","stickyTopCenter","stickyTopLeft","stickyTopRight","stickyBottomCenter","stickyBottomLeft","stickyBottomRight"],()=>this.createManagedBean(new Ea(this.eContainer))),this.forContainers(["center","topCenter","stickyTopCenter","bottomCenter","stickyBottomCenter"],()=>this.createManagedBean(new Aa(e=>this.comp.setContainerWidth(`${e}px`)))),this.addListeners(),this.registerWithCtrlsService()}addListeners(){this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,()=>this.onDisplayedColumnsChanged()),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,()=>this.onDisplayedColumnsWidthChanged()),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_ROWS_CHANGED,e=>this.onDisplayedRowsChanged(e.afterScroll)),this.onDisplayedColumnsChanged(),this.onDisplayedColumnsWidthChanged(),this.onDisplayedRowsChanged()}listenOnDomOrder(){if(["stickyTopCenter","stickyTopLeft","stickyTopRight","stickyTopFullWidth","stickyBottomCenter","stickyBottomLeft","stickyBottomRight","stickyBottomFullWidth"].indexOf(this.name)>=0)return void this.comp.setDomOrder(!0);const e=()=>{const e=this.gos.get("ensureDomOrder"),t=this.gos.isDomLayout("print");this.comp.setDomOrder(e||t)};this.addManagedPropertyListener("domLayout",e),e()}stopHScrollOnPinnedRows(){this.forContainers(["topCenter","stickyTopCenter","bottomCenter","stickyBottomCenter"],()=>{this.addManagedListener(this.eViewport,"scroll",()=>this.eViewport.scrollLeft=0)})}onDisplayedColumnsChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}onDisplayedColumnsWidthChanged(){this.forContainers(["center"],()=>this.onHorizontalViewportChanged())}addPreventScrollWhileDragging(){const e=e=>{this.dragService.isDragging()&&e.cancelable&&e.preventDefault()};this.eContainer.addEventListener("touchmove",e,{passive:!1}),this.addDestroyFunc(()=>this.eContainer.removeEventListener("touchmove",e))}onHorizontalViewportChanged(e=!1){const t=this.getCenterWidth(),i=this.getCenterViewportScrollLeft();this.columnModel.setViewportPosition(t,i,e)}getCenterWidth(){return hr(this.eViewport)}getCenterViewportScrollLeft(){return mr(this.eViewport,this.enableRtl)}registerViewportResizeListener(e){const t=this.resizeObserverService.observeResize(this.eViewport,e);this.addDestroyFunc(()=>t())}isViewportInTheDOMTree(){return wr(this.eViewport)}getViewportScrollLeft(){return mr(this.eViewport,this.enableRtl)}isHorizontalScrollShowing(){return this.gos.get("alwaysShowHorizontalScroll")||Rr(this.eViewport)}getViewportElement(){return this.eViewport}setContainerTranslateX(e){this.eContainer.style.transform=`translateX(${e}px)`}getHScrollPosition(){return{left:this.eViewport.scrollLeft,right:this.eViewport.scrollLeft+this.eViewport.offsetWidth}}setCenterViewportScrollLeft(e){vr(this.eViewport,e,this.enableRtl)}isContainerVisible(){return!e.getPinned(this.name)||!!this.pinnedWidthFeature&&this.pinnedWidthFeature.getWidth()>0}onPinnedWidthChanged(){const e=this.isContainerVisible();this.visible!=e&&(this.visible=e,this.onDisplayedRowsChanged())}onDisplayedRowsChanged(e=!1){const t=this.getRowCtrls();if(!this.visible||0===t.length)return void this.comp.setRowCtrls({rowCtrls:this.EMPTY_CTRLS});const i=this.gos.isDomLayout("print"),r=this.gos.get("embedFullWidthRows")||i,n=t.filter(e=>{const t=e.isFullWidth();return this.isFullWithContainer?!r&&t:r||!t});this.comp.setRowCtrls({rowCtrls:n,useFlushSync:e})}getRowCtrls(){switch(this.name){case"topCenter":case"topLeft":case"topRight":case"topFullWidth":return this.rowRenderer.getTopRowCtrls();case"stickyTopCenter":case"stickyTopLeft":case"stickyTopRight":case"stickyTopFullWidth":return this.rowRenderer.getStickyTopRowCtrls();case"stickyBottomCenter":case"stickyBottomLeft":case"stickyBottomRight":case"stickyBottomFullWidth":return this.rowRenderer.getStickyBottomRowCtrls();case"bottomCenter":case"bottomLeft":case"bottomRight":case"bottomFullWidth":return this.rowRenderer.getBottomRowCtrls();default:return this.rowRenderer.getCentreRowCtrls()}}};g([ue("dragService")],xa.prototype,"dragService",2),g([ue("ctrlsService")],xa.prototype,"ctrlsService",2),g([ue("columnModel")],xa.prototype,"columnModel",2),g([ue("resizeObserverService")],xa.prototype,"resizeObserverService",2),g([ue("rowRenderer")],xa.prototype,"rowRenderer",2),g([ae],xa.prototype,"postConstruct",1);var Da=xa,Ia=class extends yn{constructor(){super('<div class="ag-root ag-unselectable" role="treegrid">\n        <ag-header-root ref="gridHeader"></ag-header-root>\n        <div class="ag-floating-top" ref="eTop" role="presentation">\n            <ag-row-container ref="topLeftContainer" name="topLeft"></ag-row-container>\n            <ag-row-container ref="topCenterContainer" name="topCenter"></ag-row-container>\n            <ag-row-container ref="topRightContainer" name="topRight"></ag-row-container>\n            <ag-row-container ref="topFullWidthContainer" name="topFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-body" ref="eBody" role="presentation">\n            <div class="ag-body-viewport" ref="eBodyViewport" role="presentation">\n                <ag-row-container ref="leftContainer" name="left"></ag-row-container>\n                <ag-row-container ref="centerContainer" name="center"></ag-row-container>\n                <ag-row-container ref="rightContainer" name="right"></ag-row-container>\n                <ag-row-container ref="fullWidthContainer" name="fullWidth"></ag-row-container>\n            </div>\n            <ag-fake-vertical-scroll></ag-fake-vertical-scroll>\n        </div>\n        <div class="ag-sticky-top" ref="eStickyTop" role="presentation">\n            <ag-row-container ref="stickyTopLeftContainer" name="stickyTopLeft"></ag-row-container>\n            <ag-row-container ref="stickyTopCenterContainer" name="stickyTopCenter"></ag-row-container>\n            <ag-row-container ref="stickyTopRightContainer" name="stickyTopRight"></ag-row-container>\n            <ag-row-container ref="stickyTopFullWidthContainer" name="stickyTopFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-sticky-bottom" ref="eStickyBottom" role="presentation">\n            <ag-row-container ref="stickyBottomLeftContainer" name="stickyBottomLeft"></ag-row-container>\n            <ag-row-container ref="stickyBottomCenterContainer" name="stickyBottomCenter"></ag-row-container>\n            <ag-row-container ref="stickyBottomRightContainer" name="stickyBottomRight"></ag-row-container>\n            <ag-row-container ref="stickyBottomFullWidthContainer" name="stickyBottomFullWidth"></ag-row-container>\n        </div>\n        <div class="ag-floating-bottom" ref="eBottom" role="presentation">\n            <ag-row-container ref="bottomLeftContainer" name="bottomLeft"></ag-row-container>\n            <ag-row-container ref="bottomCenterContainer" name="bottomCenter"></ag-row-container>\n            <ag-row-container ref="bottomRightContainer" name="bottomRight"></ag-row-container>\n            <ag-row-container ref="bottomFullWidthContainer" name="bottomFullWidth"></ag-row-container>\n        </div>\n        <ag-fake-horizontal-scroll></ag-fake-horizontal-scroll>\n        <ag-overlay-wrapper></ag-overlay-wrapper>\n    </div>')}init(){const e=(e,t)=>{const i=`${e}px`;t.style.minHeight=i,t.style.height=i},t={setRowAnimationCssOnBodyViewport:(e,t)=>this.setRowAnimationCssOnBodyViewport(e,t),setColumnCount:e=>li(this.getGui(),e),setRowCount:e=>oi(this.getGui(),e),setTopHeight:t=>e(t,this.eTop),setBottomHeight:t=>e(t,this.eBottom),setTopDisplay:e=>this.eTop.style.display=e,setBottomDisplay:e=>this.eBottom.style.display=e,setStickyTopHeight:e=>this.eStickyTop.style.height=e,setStickyTopTop:e=>this.eStickyTop.style.top=e,setStickyTopWidth:e=>this.eStickyTop.style.width=e,setStickyBottomHeight:e=>this.eStickyBottom.style.height=e,setStickyBottomBottom:e=>this.eStickyBottom.style.bottom=e,setStickyBottomWidth:e=>this.eStickyBottom.style.width=e,setColumnMovingCss:(e,t)=>this.addOrRemoveCssClass(e,t),updateLayoutClasses:(e,t)=>{[this.eBodyViewport.classList,this.eBody.classList].forEach(e=>{e.toggle("ag-layout-auto-height",t.autoHeight),e.toggle("ag-layout-normal",t.normal),e.toggle("ag-layout-print",t.print)}),this.addOrRemoveCssClass("ag-layout-auto-height",t.autoHeight),this.addOrRemoveCssClass("ag-layout-normal",t.normal),this.addOrRemoveCssClass("ag-layout-print",t.print)},setAlwaysVerticalScrollClass:(e,t)=>this.eBodyViewport.classList.toggle(Jo,t),registerBodyViewportResizeListener:e=>{const t=this.resizeObserverService.observeResize(this.eBodyViewport,e);this.addDestroyFunc(()=>t())},setPinnedTopBottomOverflowY:e=>this.eTop.style.overflowY=this.eBottom.style.overflowY=e,setCellSelectableCss:(e,t)=>{[this.eTop,this.eBodyViewport,this.eBottom].forEach(i=>i.classList.toggle(e,t))},setBodyViewportWidth:e=>this.eBodyViewport.style.width=e};this.ctrl=this.createManagedBean(new ea),this.ctrl.setComp(t,this.getGui(),this.eBodyViewport,this.eTop,this.eBottom,this.eStickyTop,this.eStickyBottom),(this.rangeService&&this.gos.get("enableRangeSelection")||"multiple"===this.gos.get("rowSelection"))&&si(this.getGui(),!0)}setRowAnimationCssOnBodyViewport(e,t){const i=this.eBodyViewport.classList;i.toggle("ag-row-animation",t),i.toggle("ag-row-no-animation",!t)}getFloatingTopBottom(){return[this.eTop,this.eBottom]}};g([ue("resizeObserverService")],Ia.prototype,"resizeObserverService",2),g([he("rangeService")],Ia.prototype,"rangeService",2),g([Sn("eBodyViewport")],Ia.prototype,"eBodyViewport",2),g([Sn("eStickyTop")],Ia.prototype,"eStickyTop",2),g([Sn("eStickyBottom")],Ia.prototype,"eStickyBottom",2),g([Sn("eTop")],Ia.prototype,"eTop",2),g([Sn("eBottom")],Ia.prototype,"eBottom",2),g([Sn("gridHeader")],Ia.prototype,"headerRootComp",2),g([Sn("eBody")],Ia.prototype,"eBody",2),g([ae],Ia.prototype,"init",1);var La=class extends rt{postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onDisplayedColumnsWidthChanged.bind(this))}onDisplayedColumnsChanged(){this.update()}onDisplayedColumnsWidthChanged(){this.update()}update(){this.columnAnimationService.isActive()?this.columnAnimationService.executeLaterVMTurn(()=>{this.columnAnimationService.executeLaterVMTurn(()=>this.updateImpl())}):this.updateImpl()}updateImpl(){const e=this.ctrlsService.get("center");if(!e||this.columnAnimationService.isActive())return;const t={horizontalScrollShowing:e.isHorizontalScrollShowing(),verticalScrollShowing:this.isVerticalScrollShowing()};this.setScrollsVisible(t)}setScrollsVisible(e){if(this.horizontalScrollShowing!==e.horizontalScrollShowing||this.verticalScrollShowing!==e.verticalScrollShowing){this.horizontalScrollShowing=e.horizontalScrollShowing,this.verticalScrollShowing=e.verticalScrollShowing;const t={type:lt.EVENT_SCROLL_VISIBILITY_CHANGED};this.eventService.dispatchEvent(t)}}isHorizontalScrollShowing(){return this.horizontalScrollShowing}isVerticalScrollShowing(){return this.verticalScrollShowing}};g([ue("ctrlsService")],La.prototype,"ctrlsService",2),g([ue("columnAnimationService")],La.prototype,"columnAnimationService",2),g([ae],La.prototype,"postConstruct",1),La=g([ce("scrollVisibleService")],La);var Na=class extends rt{constructor(){super(...arguments),this.gridInstanceId=Na.gridInstanceSequence.next()}stampTopLevelGridCompWithGridInstance(e){e[Na.GRID_DOM_KEY]=this.gridInstanceId}getRenderedCellForEvent(e){return Xe(this.gos,e.target,ga.DOM_DATA_KEY_CELL_CTRL)}isEventFromThisGrid(e){return this.isElementInThisGrid(e.target)}isElementInThisGrid(e){let t=e;for(;t;){const e=t[Na.GRID_DOM_KEY];if(C(e))return e===this.gridInstanceId;t=t.parentElement}return!1}getCellPositionForEvent(e){const t=this.getRenderedCellForEvent(e);return t?t.getCellPosition():null}getNormalisedPosition(e){const t=this.gos.isDomLayout("normal"),i=e;let r,n;if(null!=i.clientX||null!=i.clientY?(r=i.clientX,n=i.clientY):(r=i.x,n=i.y),t){const e=this.ctrlsService.getGridBodyCtrl(),t=e.getScrollFeature().getVScrollPosition();r+=e.getScrollFeature().getHScrollPosition().left,n+=t.top}return{x:r,y:n}}};Na.gridInstanceSequence=new cn,Na.GRID_DOM_KEY="__ag_grid_instance",g([ue("ctrlsService")],Na.prototype,"ctrlsService",2),Na=g([ce("mouseEventService")],Na);var Oa=class extends rt{constructor(){super(),this.onPageDown=Z(this.onPageDown,100),this.onPageUp=Z(this.onPageUp,100)}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl})}handlePageScrollingKey(e,t=!1){const i=e.key,r=e.altKey,n=e.ctrlKey||e.metaKey,s=!!this.rangeService&&e.shiftKey,o=this.mouseEventService.getCellPositionForEvent(e);let a=!1;switch(i){case Yr.PAGE_HOME:case Yr.PAGE_END:n||r||(this.onHomeOrEndKey(i),a=!0);break;case Yr.LEFT:case Yr.RIGHT:case Yr.UP:case Yr.DOWN:if(!o)return!1;!n||r||s||(this.onCtrlUpDownLeftRight(i,o),a=!0);break;case Yr.PAGE_DOWN:case Yr.PAGE_UP:n||r||(a=this.handlePageUpDown(i,o,t))}return a&&e.preventDefault(),a}handlePageUpDown(e,t,i){return i&&(t=this.focusService.getFocusedCell()),!!t&&(e===Yr.PAGE_UP?this.onPageUp(t):this.onPageDown(t),!0)}navigateTo(e){var t;const{scrollIndex:i,scrollType:r,scrollColumn:n,focusIndex:s,focusColumn:o}=e;C(n)&&!n.isPinned()&&this.gridBodyCon.getScrollFeature().ensureColumnVisible(n),C(i)&&this.gridBodyCon.getScrollFeature().ensureIndexVisible(i,r),e.isAsync||this.gridBodyCon.getScrollFeature().ensureIndexVisible(s),this.focusService.setFocusedCell({rowIndex:s,column:o,rowPinned:null,forceBrowserFocus:!0}),null==(t=this.rangeService)||t.setRangeToCell({rowIndex:s,rowPinned:null,column:o})}onPageDown(e){const t=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition(),i=this.getViewportHeight(),r=this.paginationProxy.getPixelOffset(),n=t.top+i,s=this.paginationProxy.getRowIndexAtPixel(n+r);this.columnModel.isAutoRowHeightActive()?this.navigateToNextPageWithAutoHeight(e,s):this.navigateToNextPage(e,s)}onPageUp(e){const t=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition(),i=this.paginationProxy.getPixelOffset(),r=t.top,n=this.paginationProxy.getRowIndexAtPixel(r+i);this.columnModel.isAutoRowHeightActive()?this.navigateToNextPageWithAutoHeight(e,n,!0):this.navigateToNextPage(e,n,!0)}navigateToNextPage(e,t,i=!1){const r=this.getViewportHeight(),n=this.paginationProxy.getPageFirstRow(),s=this.paginationProxy.getPageLastRow(),o=this.paginationProxy.getPixelOffset(),a=this.paginationProxy.getRow(e.rowIndex),l=i?(null==a?void 0:a.rowHeight)-r-o:r-o,c=(null==a?void 0:a.rowTop)+l;let u,h=this.paginationProxy.getRowIndexAtPixel(c+o);if(h===e.rowIndex){const r=i?-1:1;t=h=e.rowIndex+r}i?(u="bottom",h<n&&(h=n),t<n&&(t=n)):(u="top",h>s&&(h=s),t>s&&(t=s)),this.isRowTallerThanView(h)&&(t=h,u="top"),this.navigateTo({scrollIndex:t,scrollType:u,scrollColumn:null,focusIndex:h,focusColumn:e.column})}navigateToNextPageWithAutoHeight(e,t,i=!1){this.navigateTo({scrollIndex:t,scrollType:i?"bottom":"top",scrollColumn:null,focusIndex:t,focusColumn:e.column}),setTimeout(()=>{const r=this.getNextFocusIndexForAutoHeight(e,i);this.navigateTo({scrollIndex:t,scrollType:i?"bottom":"top",scrollColumn:null,focusIndex:r,focusColumn:e.column,isAsync:!0})},50)}getNextFocusIndexForAutoHeight(e,t=!1){var i;const r=t?-1:1,n=this.getViewportHeight(),s=this.paginationProxy.getPageLastRow();let o=0,a=e.rowIndex;for(;a>=0&&a<=s;){const e=this.paginationProxy.getRow(a);if(e){const t=null!=(i=e.rowHeight)?i:0;if(o+t>n)break;o+=t}a+=r}return Math.max(0,Math.min(a,s))}getViewportHeight(){const{gridBodyCtrl:e,center:t}=this.ctrlsService.getParams(),i=e.getScrollFeature().getVScrollPosition(),r=this.gos.getScrollbarWidth();let n=i.bottom-i.top;return t.isHorizontalScrollShowing()&&(n-=r),n}isRowTallerThanView(e){const t=this.paginationProxy.getRow(e);if(!t)return!1;const i=t.rowHeight;return"number"==typeof i&&i>this.getViewportHeight()}onCtrlUpDownLeftRight(e,t){const i=this.cellNavigationService.getNextCellToFocus(e,t,!0),{rowIndex:r,column:n}=i;this.navigateTo({scrollIndex:r,scrollType:null,scrollColumn:n,focusIndex:r,focusColumn:n})}onHomeOrEndKey(e){const t=e===Yr.PAGE_HOME,i=this.columnModel.getAllDisplayedColumns(),r=t?i[0]:_e(i),n=t?this.paginationProxy.getPageFirstRow():this.paginationProxy.getPageLastRow();this.navigateTo({scrollIndex:n,scrollType:null,scrollColumn:r,focusIndex:n,focusColumn:r})}onTabKeyDown(e,t){const i=t.shiftKey,r=this.tabToNextCellCommon(e,i,t);if(!1===r)if(i){const{rowIndex:i,rowPinned:r}=e.getRowPosition();(r?0===i:i===this.paginationProxy.getPageFirstRow())&&(0===this.gos.get("headerHeight")||this.gos.get("suppressHeaderFocus")?this.focusService.focusNextGridCoreContainer(!0,!0):(t.preventDefault(),this.focusService.focusPreviousFromFirstCell(t)))}else e instanceof ga&&e.focusCell(!0),this.focusService.focusNextGridCoreContainer(i)&&t.preventDefault();else r&&t.preventDefault()}tabToNextCell(e,t){const i=this.focusService.getFocusedCell();if(!i)return!1;let r=this.getCellByPosition(i);return!!(r||(r=this.rowRenderer.getRowByPosition(i),r&&r.isFullWidth()))&&!!this.tabToNextCellCommon(r,e,t)}tabToNextCellCommon(e,t,i){let r,n=e.isEditing();if(!n&&e instanceof ga){const t=e.getRowCtrl();t&&(n=t.isEditing())}return r=n?"fullRow"===this.gos.get("editType")?this.moveToNextEditingRow(e,t,i):this.moveToNextEditingCell(e,t,i):this.moveToNextCellNotEditing(e,t),null===r?r:r||!!this.focusService.getFocusedHeader()}moveToNextEditingCell(e,t,i=null){const r=e.getCellPosition();e.getGui().focus(),e.stopEditing();const n=this.findNextCellToFocusOn(r,t,!0);return!1===n?null:null!=n&&(n.startEditing(null,!0,i),n.focusCell(!1),!0)}moveToNextEditingRow(e,t,i=null){const r=e.getCellPosition(),n=this.findNextCellToFocusOn(r,t,!0);if(!1===n)return null;if(null==n)return!1;const s=n.getCellPosition(),o=this.isCellEditable(r),a=this.isCellEditable(s),l=s&&r.rowIndex===s.rowIndex&&r.rowPinned===s.rowPinned;return o&&e.setFocusOutOnEditor(),l||(e.getRowCtrl().stopEditing(),n.getRowCtrl().startRowEditing(void 0,void 0,i)),a?(n.setFocusInOnEditor(),n.focusCell()):n.focusCell(!0),!0}moveToNextCellNotEditing(e,t){const i=this.columnModel.getAllDisplayedColumns();let r;r=e instanceof va?d(h({},e.getRowPosition()),{column:t?i[0]:_e(i)}):e.getCellPosition();const n=this.findNextCellToFocusOn(r,t,!1);if(!1===n)return null;if(n instanceof ga)n.focusCell(!0);else if(n)return this.tryToFocusFullWidthRow(n.getRowPosition(),t);return C(n)}findNextCellToFocusOn(e,t,i){var r;let n=e;for(;;){e!==n&&(e=n),t||(n=this.getLastCellOfColSpan(n)),n=this.cellNavigationService.getNextTabbedCell(n,t);const s=this.gos.getCallback("tabToNextCell");if(C(s)){const r=s({backwards:t,editing:i,previousCellPosition:e,nextCellPosition:n||null});if(!0===r||null===r)null===r&&z("Returning `null` from tabToNextCell is deprecated. Return `true` to stay on the current cell, or `false` to let the browser handle the tab behaviour."),n=e;else{if(!1===r)return!1;r.floating&&(z("tabToNextCellFunc return type should have attributes: rowIndex, rowPinned, column. However you had 'floating', maybe you meant 'rowPinned'?"),r.rowPinned=r.floating),n={rowIndex:r.rowIndex,column:r.column,rowPinned:r.rowPinned}}}if(!n)return null;if(n.rowIndex<0){const e=this.headerNavigationService.getHeaderRowCount();return this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:e+n.rowIndex,column:n.column},fromCell:!0}),null}const o="fullRow"===this.gos.get("editType");if(i&&!o&&!this.isCellEditable(n))continue;this.ensureCellVisible(n);const a=this.getCellByPosition(n);if(!a){const e=this.rowRenderer.getRowByPosition(n);if(!e||!e.isFullWidth()||i)continue;return e}if(!a.isSuppressNavigable())return null==(r=this.rangeService)||r.setRangeToCell(n),a}}isCellEditable(e){const t=this.lookupRowNodeForCell(e);return!!t&&e.column.isCellEditable(t)}getCellByPosition(e){const t=this.rowRenderer.getRowByPosition(e);return t?t.getCellCtrl(e.column):null}lookupRowNodeForCell(e){return"top"===e.rowPinned?this.pinnedRowModel.getPinnedTopRow(e.rowIndex):"bottom"===e.rowPinned?this.pinnedRowModel.getPinnedBottomRow(e.rowIndex):this.paginationProxy.getRow(e.rowIndex)}navigateToNextCell(e,t,i,r){let n=i,s=!1;for(;n&&(n===i||!this.isValidNavigateCell(n));)this.gos.get("enableRtl")?t===Yr.LEFT&&(n=this.getLastCellOfColSpan(n)):t===Yr.RIGHT&&(n=this.getLastCellOfColSpan(n)),n=this.cellNavigationService.getNextCellToFocus(t,n),s=y(n);if(s&&e&&e.key===Yr.UP&&(n={rowIndex:-1,rowPinned:null,column:i.column}),r){const r=this.gos.getCallback("navigateToNextCell");if(C(r)){const s=r({key:t,previousCellPosition:i,nextCellPosition:n||null,event:e});C(s)?(s.floating&&(z("tabToNextCellFunc return type should have attributes: rowIndex, rowPinned, column. However you had 'floating', maybe you meant 'rowPinned'?"),s.rowPinned=s.floating),n={rowPinned:s.rowPinned,rowIndex:s.rowIndex,column:s.column}):n=null}}if(!n)return;if(n.rowIndex<0){const t=this.headerNavigationService.getHeaderRowCount();return void this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:t+n.rowIndex,column:i.column},event:e||void 0,fromCell:!0})}const o=this.getNormalisedPosition(n);o?this.focusPosition(o):this.tryToFocusFullWidthRow(n)}getNormalisedPosition(e){this.ensureCellVisible(e);const t=this.getCellByPosition(e);return t?(e=t.getCellPosition(),this.ensureCellVisible(e),e):null}tryToFocusFullWidthRow(e,t=!1){const i=this.columnModel.getAllDisplayedColumns(),r=this.rowRenderer.getRowByPosition(e);if(!r||!r.isFullWidth())return!1;const n=this.focusService.getFocusedCell(),s={rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:e.column||(t?_e(i):i[0])};this.focusPosition(s);const o=null!=n&&this.rowPositionUtils.before(s,n),a={type:lt.EVENT_FULL_WIDTH_ROW_FOCUSED,rowIndex:s.rowIndex,rowPinned:s.rowPinned,column:s.column,isFullWidthCell:!0,floating:s.rowPinned,fromBelow:o};return this.eventService.dispatchEvent(a),!0}focusPosition(e){var t;this.focusService.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0}),null==(t=this.rangeService)||t.setRangeToCell(e)}isValidNavigateCell(e){return!!this.rowPositionUtils.getRowNode(e)}getLastCellOfColSpan(e){const t=this.getCellByPosition(e);if(!t)return e;const i=t.getColSpanningList();return 1===i.length?e:{rowIndex:e.rowIndex,column:_e(i),rowPinned:e.rowPinned}}ensureCellVisible(e){const t=this.gos.isGroupRowsSticky(),i=this.rowModel.getRow(e.rowIndex);!(t&&(null==i?void 0:i.sticky))&&y(e.rowPinned)&&this.gridBodyCon.getScrollFeature().ensureIndexVisible(e.rowIndex),e.column.isPinned()||this.gridBodyCon.getScrollFeature().ensureColumnVisible(e.column)}};g([ue("mouseEventService")],Oa.prototype,"mouseEventService",2),g([ue("paginationProxy")],Oa.prototype,"paginationProxy",2),g([ue("focusService")],Oa.prototype,"focusService",2),g([ue("columnModel")],Oa.prototype,"columnModel",2),g([ue("rowModel")],Oa.prototype,"rowModel",2),g([ue("ctrlsService")],Oa.prototype,"ctrlsService",2),g([ue("rowRenderer")],Oa.prototype,"rowRenderer",2),g([ue("headerNavigationService")],Oa.prototype,"headerNavigationService",2),g([ue("rowPositionUtils")],Oa.prototype,"rowPositionUtils",2),g([ue("cellNavigationService")],Oa.prototype,"cellNavigationService",2),g([ue("pinnedRowModel")],Oa.prototype,"pinnedRowModel",2),g([he("rangeService")],Oa.prototype,"rangeService",2),g([ae],Oa.prototype,"postConstruct",1),Oa=g([ce("navigationService")],Oa);var Fa=class e extends Es{constructor(e){super('<div class="ag-popup-editor" tabindex="-1"/>'),this.params=e}postConstruct(){this.gos.setDomData(this.getGui(),e.DOM_KEY_POPUP_EDITOR_WRAPPER,!0),this.addKeyDownListener()}addKeyDownListener(){const e=this.getGui(),t=this.params;this.addManagedListener(e,"keydown",e=>{Xr(this.gos,e,t.node,t.column,!0)||t.onKeyDown(e)})}};Fa.DOM_KEY_POPUP_EDITOR_WRAPPER="popupEditorWrapper",g([ae],Fa.prototype,"postConstruct",1);var ka=Fa,Ga=class extends yn{constructor(e,t,i,r,n){super(),this.rendererVersion=0,this.editorVersion=0,this.beans=e,this.column=t.getColumn(),this.rowNode=t.getRowNode(),this.rowCtrl=t.getRowCtrl(),this.eRow=r,this.cellCtrl=t;const s=document.createElement("div");s.setAttribute("comp-id",`${this.getCompId()}`),this.setTemplateFromElement(s);const o=this.getGui();this.forceWrapper=t.isForceWrapper(),this.refreshWrapper(!1);const a=(e,t)=>{null!=t&&""!=t?o.setAttribute(e,t):o.removeAttribute(e)};Ht(o,t.getCellAriaRole()),a("col-id",t.getColumnIdSanitised());const l=t.getTabIndex();void 0!==l&&a("tabindex",l.toString());const c={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setUserStyles:e=>Mr(o,e),getFocusableElement:()=>this.getFocusableElement(),setIncludeSelection:e=>this.includeSelection=e,setIncludeRowDrag:e=>this.includeRowDrag=e,setIncludeDndSource:e=>this.includeDndSource=e,setRenderDetails:(e,t,i)=>this.setRenderDetails(e,t,i),setEditDetails:(e,t,i)=>this.setEditDetails(e,t,i),getCellEditor:()=>this.cellEditor||null,getCellRenderer:()=>this.cellRenderer||null,getParentOfValue:()=>this.getParentOfValue()};t.setComp(c,this.getGui(),this.eCellWrapper,i,n)}getParentOfValue(){return this.eCellValue?this.eCellValue:this.eCellWrapper?this.eCellWrapper:this.getGui()}setRenderDetails(e,t,i){if(this.cellEditor&&!this.cellEditorPopupWrapper)return;this.firstRender=null==this.firstRender;const r=this.refreshWrapper(!1);this.refreshEditStyles(!1),e?!i&&!r&&this.refreshCellRenderer(e)||(this.destroyRenderer(),this.createCellRendererInstance(e)):(this.destroyRenderer(),this.insertValueWithoutCellRenderer(t))}setEditDetails(e,t,i){e?this.createCellEditorInstance(e,t,i):this.destroyEditor()}removeControls(){this.checkboxSelectionComp=this.beans.context.destroyBean(this.checkboxSelectionComp),this.dndSourceComp=this.beans.context.destroyBean(this.dndSourceComp),this.rowDraggingComp=this.beans.context.destroyBean(this.rowDraggingComp)}refreshWrapper(e){const t=this.includeRowDrag||this.includeDndSource||this.includeSelection,i=t||this.forceWrapper,r=i&&null==this.eCellWrapper;if(r){const e=document.createElement("div");e.setAttribute("role","presentation"),e.setAttribute("class","ag-cell-wrapper"),this.eCellWrapper=e,this.getGui().appendChild(this.eCellWrapper)}const n=!i&&null!=this.eCellWrapper;n&&(yr(this.eCellWrapper),this.eCellWrapper=void 0),this.addOrRemoveCssClass("ag-cell-value",!i);const s=!e&&i,o=s&&null==this.eCellValue;if(o){const e=document.createElement("span");e.setAttribute("role","presentation"),e.setAttribute("class","ag-cell-value"),this.eCellValue=e,this.eCellWrapper.appendChild(this.eCellValue)}const a=!s&&null!=this.eCellValue;a&&(yr(this.eCellValue),this.eCellValue=void 0);const l=r||n||o||a;return l&&this.removeControls(),e||t&&this.addControls(),l}addControls(){this.includeRowDrag&&null==this.rowDraggingComp&&(this.rowDraggingComp=this.cellCtrl.createRowDragComp(),this.rowDraggingComp&&this.eCellWrapper.insertBefore(this.rowDraggingComp.getGui(),this.eCellValue)),this.includeDndSource&&null==this.dndSourceComp&&(this.dndSourceComp=this.cellCtrl.createDndSource(),this.eCellWrapper.insertBefore(this.dndSourceComp.getGui(),this.eCellValue)),this.includeSelection&&null==this.checkboxSelectionComp&&(this.checkboxSelectionComp=this.cellCtrl.createSelectionCheckbox(),this.eCellWrapper.insertBefore(this.checkboxSelectionComp.getGui(),this.eCellValue))}createCellEditorInstance(e,t,i){const r=this.editorVersion,n=e.newAgStackInstance();if(!n)return;const{params:s}=e;n.then(e=>this.afterCellEditorCreated(r,e,s,t,i)),y(this.cellEditor)&&s.cellStartedEdit&&this.cellCtrl.focusCell(!0)}insertValueWithoutCellRenderer(e){const t=this.getParentOfValue();Cr(t);const i=null!=e?Ct(e,!0):null;null!=i&&(t.textContent=i)}destroyEditorAndRenderer(){this.destroyRenderer(),this.destroyEditor()}destroyRenderer(){const{context:e}=this.beans;this.cellRenderer=e.destroyBean(this.cellRenderer),yr(this.cellRendererGui),this.cellRendererGui=null,this.rendererVersion++}destroyEditor(){const{context:e}=this.beans;this.hideEditorPopup&&this.hideEditorPopup(),this.hideEditorPopup=void 0,this.cellEditor=e.destroyBean(this.cellEditor),this.cellEditorPopupWrapper=e.destroyBean(this.cellEditorPopupWrapper),yr(this.cellEditorGui),this.cellEditorGui=null,this.editorVersion++}refreshCellRenderer(e){if(null==this.cellRenderer||null==this.cellRenderer.refresh)return!1;if(this.cellRendererClass!==e.componentClass)return!1;const t=this.cellRenderer.refresh(e.params);return!0===t||void 0===t}createCellRendererInstance(e){const t=!this.beans.gos.get("suppressAnimationFrame"),i=this.rendererVersion,{componentClass:r}=e,n=()=>{if(this.rendererVersion!==i||!this.isAlive())return;const t=e.newAgStackInstance(),n=this.afterCellRendererCreated.bind(this,i,r);t&&t.then(n)};t&&this.firstRender?this.beans.animationFrameService.createTask(n,this.rowNode.rowIndex,"createTasksP2"):n()}getCtrl(){return this.cellCtrl}getRowCtrl(){return this.rowCtrl}getCellRenderer(){return this.cellRenderer}getCellEditor(){return this.cellEditor}afterCellRendererCreated(e,t,i){if(this.isAlive()&&e===this.rendererVersion){if(this.cellRenderer=i,this.cellRendererClass=t,this.cellRendererGui=this.cellRenderer.getGui(),null!=this.cellRendererGui){const e=this.getParentOfValue();Cr(e),e.appendChild(this.cellRendererGui)}}else this.beans.context.destroyBean(i)}afterCellEditorCreated(e,t,i,r,n){if(e!==this.editorVersion)return void this.beans.context.destroyBean(t);if(t.isCancelBeforeStart&&t.isCancelBeforeStart())return this.beans.context.destroyBean(t),void this.cellCtrl.stopEditing(!0);if(!t.getGui)return console.warn(`AG Grid: cellEditor for column ${this.column.getId()} is missing getGui() method`),void this.beans.context.destroyBean(t);this.cellEditor=t,this.cellEditorGui=t.getGui();const s=r||void 0!==t.isPopup&&t.isPopup();s?this.addPopupCellEditor(i,n):this.addInCellEditor(),this.refreshEditStyles(!0,s),t.afterGuiAttached&&t.afterGuiAttached()}refreshEditStyles(e,t){var i;this.addOrRemoveCssClass("ag-cell-inline-editing",e&&!t),this.addOrRemoveCssClass("ag-cell-popup-editing",e&&!!t),this.addOrRemoveCssClass("ag-cell-not-inline-editing",!e||!!t),null==(i=this.rowCtrl)||i.setInlineEditingCss(e)}addInCellEditor(){const e=this.getGui();e.contains(this.beans.gos.getActiveDomElement())&&e.focus(),this.destroyRenderer(),this.refreshWrapper(!0),this.clearParentOfValue(),this.cellEditorGui&&this.getParentOfValue().appendChild(this.cellEditorGui)}addPopupCellEditor(e,t){"fullRow"===this.beans.gos.get("editType")&&console.warn("AG Grid: popup cellEditor does not work with fullRowEdit - you cannot use them both - either turn off fullRowEdit, or stop using popup editors.");const i=this.cellEditor;this.cellEditorPopupWrapper=this.beans.context.createBean(new ka(e));const r=this.cellEditorPopupWrapper.getGui();this.cellEditorGui&&r.appendChild(this.cellEditorGui);const n=this.beans.popupService,s=this.beans.gos.get("stopEditingWhenCellsLoseFocus"),o=null!=t?t:i.getPopupPosition?i.getPopupPosition():"over",a=this.beans.gos.get("enableRtl"),l={ePopup:r,column:this.column,rowNode:this.rowNode,type:"popupCellEditor",eventSource:this.getGui(),position:o,alignSide:a?"right":"left",keepWithinBounds:!0},c=n.positionPopupByComponent.bind(n,l),u=this.beans.localeService.getLocaleTextFunc(),h=n.addPopup({modal:s,eChild:r,closeOnEsc:!0,closedCallback:()=>{this.cellCtrl.onPopupEditorClosed()},anchorToElement:this.getGui(),positionCallback:c,ariaLabel:u("ariaLabelCellEditor","Cell Editor")});h&&(this.hideEditorPopup=h.hideFunc)}detach(){this.eRow.removeChild(this.getGui())}destroy(){this.cellCtrl.stopEditing(),this.destroyEditorAndRenderer(),this.removeControls(),super.destroy()}clearParentOfValue(){const e=this.getGui();e.contains(this.beans.gos.getActiveDomElement())&&Ii()&&e.focus({preventScroll:!0}),Cr(this.getParentOfValue())}},Va=class extends yn{constructor(e,t,i){super(),this.cellComps={},this.beans=t,this.rowCtrl=e;const r=document.createElement("div");r.setAttribute("comp-id",`${this.getCompId()}`),r.setAttribute("style",this.getInitialStyle(i)),this.setTemplateFromElement(r);const n=this.getGui(),s=n.style;this.domOrder=this.rowCtrl.getDomOrder(),Ht(n,"row");const o=this.rowCtrl.getTabIndex();null!=o&&n.setAttribute("tabindex",o.toString());const a={setDomOrder:e=>this.domOrder=e,setCellCtrls:e=>this.setCellCtrls(e),showFullWidth:e=>this.showFullWidth(e),getFullWidthCellRenderer:()=>this.getFullWidthCellRenderer(),addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setUserStyles:e=>Mr(n,e),setTop:e=>s.top=e,setTransform:e=>s.transform=e,setRowIndex:e=>n.setAttribute("row-index",e),setRowId:e=>n.setAttribute("row-id",e),setRowBusinessKey:e=>n.setAttribute("row-business-key",e),refreshFullWidth:e=>this.refreshFullWidth(e)};e.setComp(a,this.getGui(),i),this.addDestroyFunc(()=>{e.unsetComp(i)})}getInitialStyle(e){const t=this.rowCtrl.getInitialTransform(e);return t?`transform: ${t}`:`top: ${this.rowCtrl.getInitialRowTop(e)}`}showFullWidth(e){const t=e.newAgStackInstance();t&&t.then(e=>{if(this.isAlive()){const t=e.getGui();this.getGui().appendChild(t),this.rowCtrl.setupDetailRowAutoHeight(t),this.setFullWidthRowComp(e)}else this.beans.context.destroyBean(e)})}setCellCtrls(e){const t=Object.assign({},this.cellComps);e.forEach(e=>{const i=e.getInstanceId();null==this.cellComps[i]?this.newCellComp(e):t[i]=null});const i=N(t).filter(e=>null!=e);this.destroyCells(i),this.ensureDomOrder(e)}ensureDomOrder(e){if(!this.domOrder)return;const t=[];e.forEach(e=>{const i=this.cellComps[e.getInstanceId()];i&&t.push(i.getGui())}),Ar(this.getGui(),t)}newCellComp(e){const t=new Ga(this.beans,e,this.rowCtrl.isPrintLayout(),this.getGui(),this.rowCtrl.isEditing());this.cellComps[e.getInstanceId()]=t,this.getGui().appendChild(t.getGui())}destroy(){super.destroy(),this.destroyAllCells()}destroyAllCells(){const e=N(this.cellComps).filter(e=>null!=e);this.destroyCells(e)}setFullWidthRowComp(e){this.fullWidthCellRenderer&&console.error("AG Grid - should not be setting fullWidthRowComponent twice"),this.fullWidthCellRenderer=e,this.addDestroyFunc(()=>{this.fullWidthCellRenderer=this.beans.context.destroyBean(this.fullWidthCellRenderer)})}getFullWidthCellRenderer(){return this.fullWidthCellRenderer}destroyCells(e){e.forEach(e=>{if(!e)return;const t=e.getCtrl().getInstanceId();this.cellComps[t]===e&&(e.detach(),e.destroy(),this.cellComps[t]=null)})}refreshFullWidth(e){const{fullWidthCellRenderer:t}=this;if(!t||!t.refresh)return!1;const i=e();return t.refresh(i)}},Ha=class extends yn{constructor(){super(function(){const e=yn.elementGettingCreated.getAttribute("name"),t=Da.getRowContainerCssClasses(e);let i;return i="center"===e||"topCenter"===e||"stickyTopCenter"===e||"bottomCenter"===e||"stickyBottomCenter"===e?`<div class="${t.viewport}" ref="eViewport" role="presentation">\n                <div class="${t.container}" ref="eContainer"></div>\n            </div>`:`<div class="${t.container}" ref="eContainer"></div>`,i}()),this.rowComps={},this.name=yn.elementGettingCreated.getAttribute("name"),this.type=Ra(this.name)}postConstruct(){const e={setViewportHeight:e=>this.eViewport.style.height=e,setRowCtrls:({rowCtrls:e})=>this.setRowCtrls(e),setDomOrder:e=>{this.domOrder=e},setContainerWidth:e=>this.eContainer.style.width=e};this.createManagedBean(new Da(this.name)).setComp(e,this.eContainer,this.eViewport)}preDestroy(){this.setRowCtrls([])}setRowCtrls(e){const t=h({},this.rowComps);this.rowComps={},this.lastPlacedElement=null,e.forEach(e=>{const i=e.getInstanceId(),r=t[i];if(r)this.rowComps[i]=r,delete t[i],this.ensureDomOrder(r.getGui());else{if(!e.getRowNode().displayed)return;const t=new Va(e,this.beans,this.type);this.rowComps[i]=t,this.appendRow(t.getGui())}}),N(t).forEach(e=>{this.eContainer.removeChild(e.getGui()),e.destroy()}),Ht(this.eContainer,"rowgroup")}appendRow(e){this.domOrder?Tr(this.eContainer,e,this.lastPlacedElement):this.eContainer.appendChild(e),this.lastPlacedElement=e}ensureDomOrder(e){this.domOrder&&(Er(this.eContainer,e,this.lastPlacedElement),this.lastPlacedElement=e)}};g([ue("beans")],Ha.prototype,"beans",2),g([Sn("eViewport")],Ha.prototype,"eViewport",2),g([Sn("eContainer")],Ha.prototype,"eContainer",2),g([ae],Ha.prototype,"postConstruct",1),g([le],Ha.prototype,"preDestroy",1);var Ba=class{constructor(e){this.columnsToAggregate=[],this.columnsToGroup=[],this.columnsToPivot=[],this.pinned=e}onDragEnter(e){if(this.clearColumnsList(),this.gos.get("functionsReadOnly"))return;const t=e.dragItem.columns;t&&t.forEach(e=>{e.isPrimary()&&(e.isAnyFunctionActive()||(e.isAllowValue()?this.columnsToAggregate.push(e):e.isAllowRowGroup()?this.columnsToGroup.push(e):e.isAllowPivot()&&this.columnsToPivot.push(e)))})}getIconName(){return this.columnsToAggregate.length+this.columnsToGroup.length+this.columnsToPivot.length>0?this.pinned?Gs.ICON_PINNED:Gs.ICON_MOVE:null}onDragLeave(e){this.clearColumnsList()}clearColumnsList(){this.columnsToAggregate.length=0,this.columnsToGroup.length=0,this.columnsToPivot.length=0}onDragging(e){}onDragStop(e){this.columnsToAggregate.length>0&&this.columnModel.addValueColumns(this.columnsToAggregate,"toolPanelDragAndDrop"),this.columnsToGroup.length>0&&this.columnModel.addRowGroupColumns(this.columnsToGroup,"toolPanelDragAndDrop"),this.columnsToPivot.length>0&&this.columnModel.addPivotColumns(this.columnsToPivot,"toolPanelDragAndDrop")}};g([ue("columnModel")],Ba.prototype,"columnModel",2),g([ue("gridOptionsService")],Ba.prototype,"gos",2);var za=class{static attemptMoveColumns(e){const{isFromHeader:t,hDirection:i,xPosition:r,fromEnter:n,fakeEvent:s,pinned:o,gos:a,columnModel:l}=e,c=0===i,u=1===i;let{allMovingColumns:h}=e;if(t){let e=[];h.forEach(t=>{var i;let r=null,n=t.getParent();for(;null!=n&&1===n.getDisplayedLeafColumns().length;)r=n,n=n.getParent();null!=r?((null==(i=r.getColGroupDef())?void 0:i.marryChildren)?r.getProvidedColumnGroup().getLeafColumns():r.getLeafColumns()).forEach(t=>{e.includes(t)||e.push(t)}):e.includes(t)||e.push(t)}),h=e}const d=h.slice();l.sortColumnsLikeGridColumns(d);const p=this.calculateValidMoves({movingCols:d,draggingRight:u,xPosition:r,pinned:o,gos:a,columnModel:l}),g=this.calculateOldIndex(d,l);if(0===p.length)return;const f=p[0];let m=null!==g&&!n;if(t&&(m=null!==g),m&&!s){if(c&&f>=g)return;if(u&&f<=g)return}const v=l.getAllDisplayedColumns();let C=[],y=null;for(let e=0;e<p.length;e++){const t=p[e],i=l.getProposedColumnOrder(d,t);if(!l.doesOrderPassRules(i))continue;const r=i.filter(e=>v.includes(e));if(null===y)y=r;else if(!Pe(r,y))break;const n=this.groupFragCount(i);C.push({move:t,fragCount:n})}return 0!==C.length?(C.sort((e,t)=>e.fragCount-t.fragCount),this.moveColumns(h,C[0].move,"uiColumnMoved",!1,l)):void 0}static moveColumns(e,t,i,r,n){return n.moveColumns(e,t,i,r),r?null:{columns:e,toIndex:t}}static calculateOldIndex(e,t){const i=t.getAllGridColumns(),r=De(e.map(e=>i.indexOf(e))),n=r[0];return _e(r)-n!==r.length-1?null:n}static groupFragCount(e){function t(e){let t=[],i=e.getOriginalParent();for(;null!=i;)t.push(i),i=i.getOriginalParent();return t}let i=0;for(let r=0;r<e.length-1;r++){let n=t(e[r]),s=t(e[r+1]);[n,s]=n.length>s.length?[n,s]:[s,n],n.forEach(e=>{-1===s.indexOf(e)&&i++})}return i}static getDisplayedColumns(e,t){switch(t){case"left":return e.getDisplayedLeftColumns();case"right":return e.getDisplayedRightColumns();default:return e.getDisplayedCenterColumns()}}static calculateValidMoves(e){const{movingCols:t,draggingRight:i,xPosition:r,pinned:n,gos:s,columnModel:o}=e;if(s.get("suppressMovableColumns")||t.some(e=>e.getColDef().suppressMovable))return[];const a=this.getDisplayedColumns(o,n),l=o.getAllGridColumns(),c=a.filter(e=>He(t,e)),u=a.filter(e=>!He(t,e)),h=l.filter(e=>!He(t,e));let d,p=0,g=r;if(i){let e=0;c.forEach(t=>e+=t.getActualWidth()),g-=e}if(g>0){for(let e=0;e<u.length&&(g-=u[e].getActualWidth(),!(g<0));e++)p++;i&&p++}if(p>0){const e=u[p-1];d=h.indexOf(e)+1}else d=h.indexOf(u[0]),-1===d&&(d=0);const f=[d],m=(e,t)=>e-t;if(i){let e=d+1;const t=l.length-1;for(;e<=t;)f.push(e),e++;f.sort(m)}else{let e=d;const t=l.length-1;let i=l[e];for(;e<=t&&a.indexOf(i)<0;)e++,f.push(e),i=l[e];e=d-1;const r=0;for(;e>=r;)f.push(e),e--;f.sort(m).reverse()}return f}static normaliseX(e,t,i,r,n){const s=n.getHeaderRowContainerCtrl(t).getViewport();return i&&(e-=s.getBoundingClientRect().left),r.get("enableRtl")&&(e=s.clientWidth-e),null==t&&(e+=n.get("center").getCenterViewportScrollLeft()),e}},Ua=class{constructor(e){this.needToMoveLeft=!1,this.needToMoveRight=!1,this.lastMovedInfo=null,this.pinned=e,this.isCenterContainer=!C(e)}init(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl})}getIconName(){return this.pinned?Gs.ICON_PINNED:Gs.ICON_MOVE}onDragEnter(e){const t=e.dragItem.columns;if(0===e.dragSource.type)this.setColumnsVisible(t,!0,"uiColumnDragged");else{const i=e.dragItem.visibleState,r=(t||[]).filter(e=>i[e.getId()]);this.setColumnsVisible(r,!0,"uiColumnDragged")}this.setColumnsPinned(t,this.pinned,"uiColumnDragged"),this.onDragging(e,!0,!0)}onDragLeave(){this.ensureIntervalCleared(),this.lastMovedInfo=null}setColumnsVisible(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockVisible);this.columnModel.setColumnsVisible(r,t,i)}}setColumnsPinned(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockPinned);this.columnModel.setColumnsPinned(r,t,i)}}onDragStop(){this.onDragging(this.lastDraggingEvent,!1,!0,!0),this.ensureIntervalCleared(),this.lastMovedInfo=null}checkCenterForScrolling(e){if(this.isCenterContainer){const t=this.ctrlsService.get("center"),i=t.getCenterViewportScrollLeft(),r=i+t.getCenterWidth();this.gos.get("enableRtl")?(this.needToMoveRight=e<i+50,this.needToMoveLeft=e>r-50):(this.needToMoveLeft=e<i+50,this.needToMoveRight=e>r-50),this.needToMoveLeft||this.needToMoveRight?this.ensureIntervalStarted():this.ensureIntervalCleared()}}onDragging(e=this.lastDraggingEvent,t=!1,i=!1,r=!1){var n;if(r){if(this.lastMovedInfo){const{columns:e,toIndex:t}=this.lastMovedInfo;za.moveColumns(e,t,"uiColumnMoved",!0,this.columnModel)}return}if(this.lastDraggingEvent=e,y(e.hDirection))return;const s=za.normaliseX(e.x,this.pinned,!1,this.gos,this.ctrlsService);t||this.checkCenterForScrolling(s);const o=this.normaliseDirection(e.hDirection),a=e.dragSource.type,l=(null==(n=e.dragSource.getDragItem().columns)?void 0:n.filter(e=>!e.getColDef().lockPinned||e.getPinned()==this.pinned))||[],c=za.attemptMoveColumns({allMovingColumns:l,isFromHeader:1===a,hDirection:o,xPosition:s,pinned:this.pinned,fromEnter:t,fakeEvent:i,gos:this.gos,columnModel:this.columnModel});c&&(this.lastMovedInfo=c)}normaliseDirection(e){if(!this.gos.get("enableRtl"))return e;switch(e){case 0:return 1;case 1:return 0;default:console.error(`AG Grid: Unknown direction ${e}`)}}ensureIntervalStarted(){this.movingIntervalId||(this.intervalCount=0,this.failedMoveAttempts=0,this.movingIntervalId=window.setInterval(this.moveInterval.bind(this),100),this.needToMoveLeft?this.dragAndDropService.setGhostIcon(Gs.ICON_LEFT,!0):this.dragAndDropService.setGhostIcon(Gs.ICON_RIGHT,!0))}ensureIntervalCleared(){this.movingIntervalId&&(window.clearInterval(this.movingIntervalId),this.movingIntervalId=null,this.dragAndDropService.setGhostIcon(Gs.ICON_MOVE))}moveInterval(){let e;this.intervalCount++,e=10+5*this.intervalCount,e>100&&(e=100);let t=null;const i=this.gridBodyCon.getScrollFeature();if(this.needToMoveLeft?t=i.scrollHorizontally(-e):this.needToMoveRight&&(t=i.scrollHorizontally(e)),0!==t)this.onDragging(this.lastDraggingEvent),this.failedMoveAttempts=0;else{this.failedMoveAttempts++;const e=this.lastDraggingEvent.dragItem.columns.filter(e=>!e.getColDef().lockPinned);if(e.length>0&&(this.dragAndDropService.setGhostIcon(Gs.ICON_PINNED),this.failedMoveAttempts>7)){const t=this.needToMoveLeft?"left":"right";this.setColumnsPinned(e,t,"uiColumnDragged"),this.dragAndDropService.nudge()}}}};g([ue("columnModel")],Ua.prototype,"columnModel",2),g([ue("dragAndDropService")],Ua.prototype,"dragAndDropService",2),g([ue("gridOptionsService")],Ua.prototype,"gos",2),g([ue("ctrlsService")],Ua.prototype,"ctrlsService",2),g([ae],Ua.prototype,"init",1);var Wa=class extends rt{constructor(e,t){super(),this.pinned=e,this.eContainer=t}postConstruct(){this.ctrlsService.whenReady(e=>{switch(this.pinned){case"left":this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.left.getContainerElement()],[e.bottomLeft.getContainerElement()],[e.topLeft.getContainerElement()]];break;case"right":this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.right.getContainerElement()],[e.bottomRight.getContainerElement()],[e.topRight.getContainerElement()]];break;default:this.eSecondaryContainers=[[e.gridBodyCtrl.getBodyViewportElement(),e.center.getViewportElement()],[e.bottomCenter.getViewportElement()],[e.topCenter.getViewportElement()]]}})}isInterestedIn(e){return 1===e||0===e&&this.gos.get("allowDragFromColumnsToolPanel")}getSecondaryContainers(){return this.eSecondaryContainers}getContainer(){return this.eContainer}init(){this.moveColumnFeature=this.createManagedBean(new Ua(this.pinned)),this.bodyDropPivotTarget=this.createManagedBean(new Ba(this.pinned)),this.dragAndDropService.addDropTarget(this)}getIconName(){return this.currentDropListener.getIconName()}isDropColumnInPivotMode(e){return this.columnModel.isPivotMode()&&0===e.dragSource.type}onDragEnter(e){this.currentDropListener=this.isDropColumnInPivotMode(e)?this.bodyDropPivotTarget:this.moveColumnFeature,this.currentDropListener.onDragEnter(e)}onDragLeave(e){this.currentDropListener.onDragLeave(e)}onDragging(e){this.currentDropListener.onDragging(e)}onDragStop(e){this.currentDropListener.onDragStop(e)}};g([ue("dragAndDropService")],Wa.prototype,"dragAndDropService",2),g([ue("columnModel")],Wa.prototype,"columnModel",2),g([ue("ctrlsService")],Wa.prototype,"ctrlsService",2),g([ae],Wa.prototype,"postConstruct",1),g([ae],Wa.prototype,"init",1);var ja=class e extends Ko{constructor(t){super(e.TEMPLATE,t),this.headerCompVersion=0,this.column=t.getColumnGroupChild(),this.pinned=t.getPinned()}postConstruct(){const e=this.getGui();var t,i;t="col-id",null!=(i=this.column.getColId())&&""!=i?e.setAttribute(t,i):e.removeAttribute(t);const r={setWidth:t=>e.style.width=t,addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setAriaSort:t=>t?hi(e,t):di(e),setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerComp};this.ctrl.setComp(r,this.getGui(),this.eResize,this.eHeaderCompWrapper);const n=this.ctrl.getSelectAllGui();this.eResize.insertAdjacentElement("afterend",n)}destroyHeaderComp(){this.headerComp&&(this.eHeaderCompWrapper.removeChild(this.headerCompGui),this.headerComp=this.destroyBean(this.headerComp),this.headerCompGui=void 0)}setUserCompDetails(e){this.headerCompVersion++;const t=this.headerCompVersion;e.newAgStackInstance().then(e=>this.afterCompCreated(t,e))}afterCompCreated(e,t){e==this.headerCompVersion&&this.isAlive()?(this.destroyHeaderComp(),this.headerComp=t,this.headerCompGui=t.getGui(),this.eHeaderCompWrapper.appendChild(this.headerCompGui),this.ctrl.setDragSource(this.getGui())):this.destroyBean(t)}};ja.TEMPLATE='<div class="ag-header-cell" role="columnheader">\n            <div ref="eResize" class="ag-header-cell-resize" role="presentation"></div>\n            <div ref="eHeaderCompWrapper" class="ag-header-cell-comp-wrapper" role="presentation"></div>\n        </div>',g([Sn("eResize")],ja.prototype,"eResize",2),g([Sn("eHeaderCompWrapper")],ja.prototype,"eHeaderCompWrapper",2),g([ae],ja.prototype,"postConstruct",1),g([le],ja.prototype,"destroyHeaderComp",1);var Ka=ja,$a=class e extends Ko{constructor(t){super(e.TEMPLATE,t)}postConstruct(){const e=this.getGui();e.setAttribute("col-id",this.ctrl.getColId());const t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setResizableDisplayed:e=>sr(this.eResize,e),setWidth:t=>e.style.width=t,setAriaExpanded:t=>{return i="aria-expanded",null!=(r=t)?e.setAttribute(i,r):e.removeAttribute(i);var i,r},setUserCompDetails:e=>this.setUserCompDetails(e),getUserCompInstance:()=>this.headerGroupComp};this.ctrl.setComp(t,e,this.eResize)}setUserCompDetails(e){e.newAgStackInstance().then(e=>this.afterHeaderCompCreated(e))}afterHeaderCompCreated(e){const t=()=>this.destroyBean(e);if(!this.isAlive())return void t();const i=this.getGui(),r=e.getGui();i.appendChild(r),this.addDestroyFunc(t),this.headerGroupComp=e,this.ctrl.setDragSource(i)}};$a.TEMPLATE='<div class="ag-header-group-cell" role="columnheader">\n            <div ref="eResize" class="ag-header-cell-resize" role="presentation"></div>\n        </div>',g([Sn("eResize")],$a.prototype,"eResize",2),g([ae],$a.prototype,"postConstruct",1);var qa=$a,Ya=(e=>(e.COLUMN_GROUP="group",e.COLUMN="column",e.FLOATING_FILTER="filter",e))(Ya||{}),Qa=class extends yn{constructor(e){super(),this.headerComps={},this.ctrl=e,this.setTemplate(`<div class="${this.ctrl.getHeaderRowClass()}" role="row"></div>`)}init(){ai(this.getGui(),this.ctrl.getAriaRowIndex());const e={setHeight:e=>this.getGui().style.height=e,setTop:e=>this.getGui().style.top=e,setHeaderCtrls:(e,t)=>this.setHeaderCtrls(e,t),setWidth:e=>this.getGui().style.width=e};this.ctrl.setComp(e)}destroyHeaderCtrls(){this.setHeaderCtrls([],!1)}setHeaderCtrls(e,t){if(!this.isAlive())return;const i=this.headerComps;if(this.headerComps={},e.forEach(e=>{const t=e.getInstanceId();let r=i[t];delete i[t],null==r&&(r=this.createHeaderComp(e),this.getGui().appendChild(r.getGui())),this.headerComps[t]=r}),D(i,(e,t)=>{this.getGui().removeChild(t.getGui()),this.destroyBean(t)}),t){const e=N(this.headerComps);e.sort((e,t)=>e.getCtrl().getColumnGroupChild().getLeft()-t.getCtrl().getColumnGroupChild().getLeft());const t=e.map(e=>e.getGui());Ar(this.getGui(),t)}}createHeaderComp(e){let t;switch(this.ctrl.getType()){case"group":t=new qa(e);break;case"filter":t=new qo(e);break;default:t=new Ka(e)}return this.createBean(t),t.setParentComponent(this),t}};g([ae],Qa.prototype,"init",1),g([le],Qa.prototype,"destroyHeaderCtrls",1);var Xa=0,Za=class e extends rt{constructor(e,t,i){super(),this.resizeToggleTimeout=0,this.resizeMultiplier=1,this.resizeFeature=null,this.lastFocusEvent=null,this.dragSource=null,this.columnGroupChild=e,this.parentRowCtrl=i,this.beans=t,this.instanceId=e.getUniqueId()+"-"+Xa++}postConstruct(){this.addManagedPropertyListeners(["suppressHeaderFocus"],()=>this.refreshTabIndex())}shouldStopEventPropagation(e){const{headerRowIndex:t,column:i}=this.focusService.getFocusedHeader();return Zr(this.gos,e,t,i)}getWrapperHasFocus(){return this.gos.getActiveDomElement()===this.eGui}setGui(e){this.eGui=e,this.addDomData(),this.addManagedListener(this.beans.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.onDisplayedColumnsChanged(),this.refreshTabIndex()}onDisplayedColumnsChanged(){this.comp&&this.column&&(this.refreshFirstAndLastStyles(),this.refreshAriaColIndex())}refreshFirstAndLastStyles(){const{comp:e,column:t,beans:i}=this;ha.refreshFirstAndLastStyles(e,t,i.columnModel)}refreshAriaColIndex(){const{beans:e,column:t}=this,i=e.columnModel.getAriaColumnIndex(t);ci(this.eGui,i)}addResizeAndMoveKeyboardListeners(){this.resizeFeature&&(this.addManagedListener(this.eGui,"keydown",this.onGuiKeyDown.bind(this)),this.addManagedListener(this.eGui,"keyup",this.onGuiKeyUp.bind(this)))}refreshTabIndex(){this.gos.get("suppressHeaderFocus")?this.eGui.removeAttribute("tabindex"):this.eGui.setAttribute("tabindex","-1")}onGuiKeyDown(e){var t;const i=this.gos.getActiveDomElement(),r=e.key===Yr.LEFT||e.key===Yr.RIGHT;if(this.isResizing&&(e.preventDefault(),e.stopImmediatePropagation()),i!==this.eGui||!e.shiftKey&&!e.altKey)return;if((this.isResizing||r)&&(e.preventDefault(),e.stopImmediatePropagation()),!r)return;const n=e.key===Yr.LEFT!==this.gos.get("enableRtl"),s=Fs[n?"Left":"Right"];if(e.altKey){this.isResizing=!0,this.resizeMultiplier+=1;const i=this.getViewportAdjustedResizeDiff(e);this.resizeHeader(i,e.shiftKey),null==(t=this.resizeFeature)||t.toggleColumnResizing(!0)}else this.moveHeader(s)}getViewportAdjustedResizeDiff(e){let t=this.getResizeDiff(e);if(this.column.getPinned()){const e=this.pinnedWidthService.getPinnedLeftWidth(),i=this.pinnedWidthService.getPinnedRightWidth(),r=hr(this.ctrlsService.getGridBodyCtrl().getBodyViewportElement())-50;if(e+i+t>r){if(!(r>e+i))return 0;t=r-e-i}}return t}getResizeDiff(e){let t=e.key===Yr.LEFT!==this.gos.get("enableRtl");const i=this.column.getPinned(),r=this.gos.get("enableRtl");return i&&r!==("right"===i)&&(t=!t),(t?-1:1)*this.resizeMultiplier}onGuiKeyUp(){this.isResizing&&(this.resizeToggleTimeout&&(window.clearTimeout(this.resizeToggleTimeout),this.resizeToggleTimeout=0),this.isResizing=!1,this.resizeMultiplier=1,this.resizeToggleTimeout=setTimeout(()=>{var e;null==(e=this.resizeFeature)||e.toggleColumnResizing(!1)},150))}handleKeyDown(e){const t=this.getWrapperHasFocus();switch(e.key){case Yr.PAGE_DOWN:case Yr.PAGE_UP:case Yr.PAGE_HOME:case Yr.PAGE_END:t&&e.preventDefault()}}addDomData(){const t=e.DOM_DATA_KEY_HEADER_CTRL;this.gos.setDomData(this.eGui,t,this),this.addDestroyFunc(()=>this.gos.setDomData(this.eGui,t,null))}getGui(){return this.eGui}focus(e){return!!this.eGui&&(this.lastFocusEvent=e||null,this.eGui.focus(),!0)}getRowIndex(){return this.parentRowCtrl.getRowIndex()}getParentRowCtrl(){return this.parentRowCtrl}getPinned(){return this.parentRowCtrl.getPinned()}getInstanceId(){return this.instanceId}getColumnGroupChild(){return this.columnGroupChild}removeDragSource(){this.dragSource&&(this.dragAndDropService.removeDragSource(this.dragSource),this.dragSource=null)}handleContextMenuMouseEvent(e,t,i){const r=null!=e?e:t;this.gos.get("preventDefaultOnContextMenu")&&r.preventDefault();const n=i instanceof Se?i:void 0;this.menuService.isHeaderContextMenuEnabled(n)&&this.menuService.showHeaderContextMenu(n,e,t),this.dispatchColumnMouseEvent(lt.EVENT_COLUMN_HEADER_CONTEXT_MENU,i)}dispatchColumnMouseEvent(e,t){const i={type:e,column:t};this.eventService.dispatchEvent(i)}destroy(){super.destroy(),this.removeDragSource(),this.comp=null,this.column=null,this.resizeFeature=null,this.lastFocusEvent=null,this.columnGroupChild=null,this.parentRowCtrl=null,this.eGui=null}};Za.DOM_DATA_KEY_HEADER_CTRL="headerCtrl",g([ue("pinnedWidthService")],Za.prototype,"pinnedWidthService",2),g([ue("focusService")],Za.prototype,"focusService",2),g([ue("userComponentFactory")],Za.prototype,"userComponentFactory",2),g([ue("ctrlsService")],Za.prototype,"ctrlsService",2),g([ue("dragAndDropService")],Za.prototype,"dragAndDropService",2),g([ue("menuService")],Za.prototype,"menuService",2),g([ae],Za.prototype,"postConstruct",1);var Ja=Za,el=class extends rt{constructor(e,t,i,r){super(),this.columnOrGroup=e,this.eCell=t,this.ariaEl=this.eCell.querySelector("[role=columnheader]")||this.eCell,this.colsSpanning=r,this.beans=i}setColsSpanning(e){this.colsSpanning=e,this.onLeftChanged()}getColumnOrGroup(){return this.beans.gos.get("enableRtl")&&this.colsSpanning?_e(this.colsSpanning):this.columnOrGroup}postConstruct(){this.addManagedListener(this.columnOrGroup,Se.EVENT_LEFT_CHANGED,this.onLeftChanged.bind(this)),this.setLeftFirstTime(),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,this.onLeftChanged.bind(this)),this.addManagedPropertyListener("domLayout",this.onLeftChanged.bind(this))}setLeftFirstTime(){const e=this.beans.gos.get("suppressColumnMoveAnimation"),t=C(this.columnOrGroup.getOldLeft());this.beans.columnAnimationService.isActive()&&t&&!e?this.animateInLeft():this.onLeftChanged()}animateInLeft(){const e=this.getColumnOrGroup(),t=e.getLeft(),i=e.getOldLeft(),r=this.modifyLeftForPrintLayout(e,i),n=this.modifyLeftForPrintLayout(e,t);this.setLeft(r),this.actualLeft=n,this.beans.columnAnimationService.executeNextVMTurn(()=>{this.actualLeft===n&&this.setLeft(n)})}onLeftChanged(){const e=this.getColumnOrGroup(),t=e.getLeft();this.actualLeft=this.modifyLeftForPrintLayout(e,t),this.setLeft(this.actualLeft)}modifyLeftForPrintLayout(e,t){if(!this.beans.gos.isDomLayout("print"))return t;if("left"===e.getPinned())return t;const i=this.beans.columnModel.getDisplayedColumnsLeftWidth();return"right"===e.getPinned()?i+this.beans.columnModel.getBodyContainerWidth()+t:i+t}setLeft(e){let t;if(C(e)&&(this.eCell.style.left=`${e}px`),this.columnOrGroup instanceof Se)t=this.columnOrGroup;else{const e=this.columnOrGroup.getLeafColumns();if(!e.length)return;e.length>1&&ui(this.ariaEl,e.length),t=e[0]}}};g([ae],el.prototype,"postConstruct",1);var tl=class extends rt{constructor(e,t){super(),this.columns=e,this.element=t}postConstruct(){this.gos.get("columnHoverHighlight")&&this.addMouseHoverListeners()}addMouseHoverListeners(){this.addManagedListener(this.element,"mouseout",this.onMouseOut.bind(this)),this.addManagedListener(this.element,"mouseover",this.onMouseOver.bind(this))}onMouseOut(){this.columnHoverService.clearMouseOver()}onMouseOver(){this.columnHoverService.setMouseOver(this.columns)}};g([ue("columnHoverService")],tl.prototype,"columnHoverService",2),g([ae],tl.prototype,"postConstruct",1);var il=class extends Ja{constructor(e,t,i){super(e,t,i),this.iconCreated=!1,this.column=e}setComp(e,t,i,r){this.comp=e,this.eButtonShowMainFilter=i,this.eFloatingFilterBody=r,this.setGui(t),this.setupActive(),this.setupWidth(),this.setupLeft(),this.setupHover(),this.setupFocus(),this.setupAria(),this.setupFilterButton(),this.setupUserComp(),this.setupSyncWithFilter(),this.setupUi(),this.addManagedListener(this.eButtonShowMainFilter,"click",this.showParentFilter.bind(this)),this.setupFilterChangedListener(),this.addManagedListener(this.column,Se.EVENT_COL_DEF_CHANGED,this.onColDefChanged.bind(this))}resizeHeader(){}moveHeader(){}setupActive(){const e=this.column.getColDef(),t=!!e.filter,i=!!e.floatingFilter;this.active=t&&i}setupUi(){if(this.comp.setButtonWrapperDisplayed(!this.suppressFilterButton&&this.active),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-full-body",this.suppressFilterButton),this.comp.addOrRemoveBodyCssClass("ag-floating-filter-body",!this.suppressFilterButton),!this.active||this.iconCreated)return;const e=$r("filter",this.gos,this.column);e&&(this.iconCreated=!0,this.eButtonShowMainFilter.appendChild(e))}setupFocus(){this.createManagedBean(new _n(this.eGui,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)}))}setupAria(){const e=this.localeService.getLocaleTextFunc();jt(this.eButtonShowMainFilter,e("ariaFilterMenuOpen","Open Filter Menu"))}onTabKeyDown(e){if(this.gos.getActiveDomElement()===this.eGui)return;const t=this.focusService.findNextFocusableElement(this.eGui,null,e.shiftKey);if(t)return this.beans.headerNavigationService.scrollToColumn(this.column),e.preventDefault(),void t.focus();const i=this.findNextColumnWithFloatingFilter(e.shiftKey);i&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:this.getParentRowCtrl().getRowIndex(),column:i},event:e})&&e.preventDefault()}findNextColumnWithFloatingFilter(e){const t=this.beans.columnModel;let i=this.column;do{if(i=e?t.getDisplayedColBefore(i):t.getDisplayedColAfter(i),!i)break}while(!i.getColDef().filter||!i.getColDef().floatingFilter);return i}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();switch(e.key){case Yr.UP:case Yr.DOWN:t||e.preventDefault();case Yr.LEFT:case Yr.RIGHT:if(t)return;e.stopPropagation();case Yr.ENTER:t&&this.focusService.focusInto(this.eGui)&&e.preventDefault();break;case Yr.ESCAPE:t||this.eGui.focus()}}onFocusIn(e){if(this.eGui.contains(e.relatedTarget))return;const t=!!e.relatedTarget&&!e.relatedTarget.classList.contains("ag-floating-filter"),i=!!e.relatedTarget&&lr(e.relatedTarget,"ag-floating-filter");if(t&&i&&e.target===this.eGui){const e=this.lastFocusEvent,t=!(!e||e.key!==Yr.TAB);if(e&&t){const t=e.shiftKey;this.focusService.focusInto(this.eGui,t)}}const r=this.getRowIndex();this.beans.focusService.setFocusedHeader(r,this.column)}setupHover(){this.createManagedBean(new tl([this.column],this.eGui));const e=()=>{if(!this.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.comp.addOrRemoveCssClass("ag-column-hover",e)};this.addManagedListener(this.eventService,lt.EVENT_COLUMN_HOVER_CHANGED,e),e()}setupLeft(){const e=new el(this.column,this.eGui,this.beans);this.createManagedBean(e)}setupFilterButton(){this.suppressFilterButton=!this.menuService.isFloatingFilterButtonEnabled(this.column),this.highlightFilterButtonWhenActive=!this.menuService.isLegacyMenuEnabled()}setupUserComp(){if(!this.active)return;const e=this.beans.filterManager.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter());e&&this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setCompDetails(e)}showParentFilter(){const e=this.suppressFilterButton?this.eFloatingFilterBody:this.eButtonShowMainFilter;this.menuService.showFilterMenu({column:this.column,buttonElement:e,containerType:"floatingFilter",positionBy:"button"})}setupSyncWithFilter(){if(!this.active)return;const{filterManager:e}=this.beans,t=t=>{if("filterDestroyed"===(null==t?void 0:t.source)&&this.context.isDestroyed())return;const i=this.comp.getFloatingFilterComp();i&&i.then(i=>{var r;if(i){const n=e.getCurrentFloatingFilterParentModel(this.column);i.onParentModelChanged(n,t?this.gos.addGridCommonParams({columns:null!=(r=t.columns)?r:[],type:lt.EVENT_FILTER_CHANGED,source:"api"===t.source?"api":"columnFilter"}):null)}})};this.destroySyncListener=this.addManagedListener(this.column,Se.EVENT_FILTER_CHANGED,t),e.isFilterActive(this.column)&&t(null)}setupWidth(){const e=()=>{const e=`${this.column.getActualWidth()}px`;this.comp.setWidth(e)};this.addManagedListener(this.column,Se.EVENT_WIDTH_CHANGED,e),e()}setupFilterChangedListener(){this.active&&(this.destroyFilterChangedListener=this.addManagedListener(this.column,Se.EVENT_FILTER_CHANGED,this.updateFilterButton.bind(this)),this.updateFilterButton())}updateFilterButton(){if(!this.suppressFilterButton&&this.comp){const e=this.beans.filterManager.isFilterAllowed(this.column);this.comp.setButtonWrapperDisplayed(e),this.highlightFilterButtonWhenActive&&e&&this.eButtonShowMainFilter.classList.toggle("ag-filter-active",this.column.isFilterActive())}}onColDefChanged(){var e,t;const i=this.active;this.setupActive();const r=!i&&this.active;i&&!this.active&&(null==(e=this.destroySyncListener)||e.call(this),null==(t=this.destroyFilterChangedListener)||t.call(this));const n=this.active?this.beans.filterManager.getFloatingFilterCompDetails(this.column,()=>this.showParentFilter()):null,s=this.comp.getFloatingFilterComp();s&&n?s.then(e=>{var t;!e||this.beans.filterManager.areFilterCompsDifferent(null!=(t=this.userCompDetails)?t:null,n)?this.updateCompDetails(n,r):this.updateFloatingFilterParams(n)}):this.updateCompDetails(n,r)}updateCompDetails(e,t){this.isAlive()&&(this.setCompDetails(e),this.setupFilterButton(),this.setupUi(),t&&(this.setupSyncWithFilter(),this.setupFilterChangedListener()))}updateFloatingFilterParams(e){var t;if(!e)return;const i=e.params;null==(t=this.comp.getFloatingFilterComp())||t.then(e=>{let t=!1;(null==e?void 0:e.refresh)&&"function"==typeof e.refresh&&null!==e.refresh(i)&&(t=!0),!t&&(null==e?void 0:e.onParamsUpdated)&&"function"==typeof e.onParamsUpdated&&null!==e.onParamsUpdated(i)&&z("Custom floating filter method 'onParamsUpdated' is deprecated. Use 'refresh' instead.")})}destroy(){super.destroy(),this.eButtonShowMainFilter=null,this.eFloatingFilterBody=null,this.userCompDetails=null,this.destroySyncListener=null,this.destroyFilterChangedListener=null}},rl=class extends rt{constructor(e,t,i,r,n){super(),this.pinned=e,this.column=t,this.eResize=i,this.comp=r,this.ctrl=n}postConstruct(){const e=[];let t,i;const r=()=>{if(sr(this.eResize,t),!t)return;const r=this.horizontalResizeService.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});if(e.push(r),i){const t=this.gos.get("skipHeaderOnAutoSize"),i=()=>{this.columnModel.autoSizeColumn(this.column,"uiColumnResized",t)};this.eResize.addEventListener("dblclick",i);const r=new ms(this.eResize);r.addEventListener(ms.EVENT_DOUBLE_TAP,i),e.push(()=>{this.eResize.removeEventListener("dblclick",i),r.removeEventListener(ms.EVENT_DOUBLE_TAP,i),r.destroy()})}},n=()=>{e.forEach(e=>e()),e.length=0},s=()=>{const e=this.column.isResizable(),s=!this.gos.get("suppressAutoSize")&&!this.column.getColDef().suppressAutoSize;(e!==t||s!==i)&&(t=e,i=s,n(),r())};s(),this.addDestroyFunc(n),this.ctrl.addRefreshFunction(s)}onResizing(e,t){const{column:i,lastResizeAmount:r,resizeStartWidth:n}=this,s=this.normaliseResizeAmount(t),o=[{key:i,newWidth:n+s}];this.column.getPinned()&&this.pinnedWidthService.getPinnedLeftWidth()+this.pinnedWidthService.getPinnedRightWidth()+(s-r)>hr(this.ctrlsService.getGridBodyCtrl().getBodyViewportElement())-50||(this.lastResizeAmount=s,this.columnModel.setColumnWidths(o,this.resizeWithShiftKey,e,"uiColumnResized"),e&&this.toggleColumnResizing(!1))}onResizeStart(e){this.resizeStartWidth=this.column.getActualWidth(),this.lastResizeAmount=0,this.resizeWithShiftKey=e,this.toggleColumnResizing(!0)}toggleColumnResizing(e){this.comp.addOrRemoveCssClass("ag-column-resizing",e)}normaliseResizeAmount(e){let t=e;const i="left"!==this.pinned,r="right"===this.pinned;return this.gos.get("enableRtl")?i&&(t*=-1):r&&(t*=-1),t}};g([ue("horizontalResizeService")],rl.prototype,"horizontalResizeService",2),g([ue("pinnedWidthService")],rl.prototype,"pinnedWidthService",2),g([ue("ctrlsService")],rl.prototype,"ctrlsService",2),g([ue("columnModel")],rl.prototype,"columnModel",2),g([ae],rl.prototype,"postConstruct",1);var nl=class extends rt{constructor(e){super(),this.cbSelectAllVisible=!1,this.processingEventFromCheckbox=!1,this.column=e}onSpaceKeyDown(e){const t=this.cbSelectAll;t.isDisplayed()&&!t.getGui().contains(this.gos.getActiveDomElement())&&(e.preventDefault(),t.setValue(!t.getValue()))}getCheckboxGui(){return this.cbSelectAll.getGui()}setComp(e){this.headerCellCtrl=e,this.cbSelectAll=this.createManagedBean(new zn),this.cbSelectAll.addCssClass("ag-header-select-all"),Ht(this.cbSelectAll.getGui(),"presentation"),this.showOrHideSelectAll(),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.onNewColumnsLoaded.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_SELECTION_CHANGED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_PAGINATION_CHANGED,this.onSelectionChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_MODEL_UPDATED,this.onModelChanged.bind(this)),this.addManagedListener(this.cbSelectAll,lt.EVENT_FIELD_VALUE_CHANGED,this.onCbSelectAll.bind(this)),Jt(this.cbSelectAll.getGui(),!0),this.cbSelectAll.getInputElement().setAttribute("tabindex","-1"),this.refreshSelectAllLabel()}onNewColumnsLoaded(){this.showOrHideSelectAll()}onDisplayedColumnsChanged(){this.isAlive()&&this.showOrHideSelectAll()}showOrHideSelectAll(){this.cbSelectAllVisible=this.isCheckboxSelection(),this.cbSelectAll.setDisplayed(this.cbSelectAllVisible,{skipAriaHidden:!0}),this.cbSelectAllVisible&&(this.checkRightRowModelType("selectAllCheckbox"),this.checkSelectionType("selectAllCheckbox"),this.updateStateOfCheckbox()),this.refreshSelectAllLabel()}onModelChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}onSelectionChanged(){this.cbSelectAllVisible&&this.updateStateOfCheckbox()}updateStateOfCheckbox(){if(this.processingEventFromCheckbox)return;this.processingEventFromCheckbox=!0;const e=this.selectionService.getSelectAllState(this.isFilteredOnly(),this.isCurrentPageOnly());this.cbSelectAll.setValue(e);const t=this.selectionService.hasNodesToSelect(this.isFilteredOnly(),this.isCurrentPageOnly());this.cbSelectAll.setDisabled(!t),this.refreshSelectAllLabel(),this.processingEventFromCheckbox=!1}refreshSelectAllLabel(){const e=this.localeService.getLocaleTextFunc(),t=this.cbSelectAll.getValue()?e("ariaChecked","checked"):e("ariaUnchecked","unchecked"),i=e("ariaRowSelectAll","Press Space to toggle all rows selection");this.cbSelectAllVisible?this.headerCellCtrl.setAriaDescriptionProperty("selectAll",`${i} (${t})`):this.headerCellCtrl.setAriaDescriptionProperty("selectAll",null),this.cbSelectAll.setInputAriaLabel(`${i} (${t})`),this.headerCellCtrl.announceAriaDescription()}checkSelectionType(e){return!("multiple"!==this.gos.get("rowSelection")&&(console.warn(`AG Grid: ${e} is only available if using 'multiple' rowSelection.`),1))}checkRightRowModelType(e){const t=this.rowModel.getType();return!("clientSide"!==t&&"serverSide"!==t&&(console.warn(`AG Grid: ${e} is only available if using 'clientSide' or 'serverSide' rowModelType, you are using ${t}.`),1))}onCbSelectAll(){if(this.processingEventFromCheckbox)return;if(!this.cbSelectAllVisible)return;const e=this.cbSelectAll.getValue(),t=this.isFilteredOnly(),i=this.isCurrentPageOnly();let r="uiSelectAll";i?r="uiSelectAllCurrentPage":t&&(r="uiSelectAllFiltered");const n={source:r,justFiltered:t,justCurrentPage:i};e?this.selectionService.selectAllRowNodes(n):this.selectionService.deselectAllRowNodes(n)}isCheckboxSelection(){let e=this.column.getColDef().headerCheckboxSelection;return"function"==typeof e&&(e=e(this.gos.addGridCommonParams({column:this.column,colDef:this.column.getColDef()}))),!!e&&this.checkRightRowModelType("headerCheckboxSelection")&&this.checkSelectionType("headerCheckboxSelection")}isFilteredOnly(){return!!this.column.getColDef().headerCheckboxSelectionFilteredOnly}isCurrentPageOnly(){return!!this.column.getColDef().headerCheckboxSelectionCurrentPageOnly}};g([ue("rowModel")],nl.prototype,"rowModel",2),g([ue("selectionService")],nl.prototype,"selectionService",2);var sl=class extends Ja{constructor(e,t,i){super(e,t,i),this.refreshFunctions=[],this.userHeaderClasses=new Set,this.ariaDescriptionProperties=new Map,this.column=e}setComp(e,t,i,r){this.comp=e,this.setGui(t),this.updateState(),this.setupWidth(),this.setupMovingCss(),this.setupMenuClass(),this.setupSortableClass(),this.setupWrapTextClass(),this.refreshSpanHeaderHeight(),this.setupAutoHeight(r),this.addColumnHoverListener(),this.setupFilterClass(),this.setupClassesFromColDef(),this.setupTooltip(),this.addActiveHeaderMouseListeners(),this.setupSelectAll(),this.setupUserComp(),this.refreshAria(),this.resizeFeature=this.createManagedBean(new rl(this.getPinned(),this.column,i,e,this)),this.createManagedBean(new tl([this.column],t)),this.createManagedBean(new el(this.column,t,this.beans)),this.createManagedBean(new _n(t,{shouldStopEventPropagation:e=>this.shouldStopEventPropagation(e),onTabKeyDown:()=>null,handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addResizeAndMoveKeyboardListeners(),this.addManagedPropertyListeners(["suppressMovableColumns","suppressMenuHide","suppressAggFuncInHeader"],this.refresh.bind(this)),this.addManagedListener(this.column,Se.EVENT_COL_DEF_CHANGED,this.refresh.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VALUE_CHANGED,this.onColumnValueChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,this.onColumnRowGroupChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_CHANGED,this.onColumnPivotChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_HEADER_HEIGHT_CHANGED,this.onHeaderHeightChanged.bind(this))}resizeHeader(e,t){var i,r;if(!this.column.isResizable())return;const n=this.column.getActualWidth(),s=null!=(i=this.column.getMinWidth())?i:0,o=null!=(r=this.column.getMaxWidth())?r:Number.MAX_SAFE_INTEGER,a=Math.min(Math.max(n+e,s),o);this.beans.columnModel.setColumnWidths([{key:this.column,newWidth:a}],t,!0,"uiColumnResized")}moveHeader(e){const{eGui:t,column:i,gos:r,ctrlsService:n}=this,s=this.getPinned(),o=t.getBoundingClientRect().left,a=i.getActualWidth(),l=0===e!==r.get("enableRtl"),c=za.normaliseX(l?o-20:o+a+20,s,!0,r,n);za.attemptMoveColumns({allMovingColumns:[i],isFromHeader:!0,hDirection:e,xPosition:c,pinned:s,fromEnter:!1,fakeEvent:!1,gos:r,columnModel:this.beans.columnModel}),n.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(i,"auto")}setupUserComp(){const e=this.lookupUserCompDetails();this.setCompDetails(e)}setCompDetails(e){this.userCompDetails=e,this.comp.setUserCompDetails(e)}lookupUserCompDetails(){const e=this.createParams(),t=this.column.getColDef();return this.userComponentFactory.getHeaderCompDetails(t,e)}createParams(){return this.gos.addGridCommonParams({column:this.column,displayName:this.displayName,enableSorting:this.column.isSortable(),enableMenu:this.menuEnabled,enableFilterButton:this.openFilterEnabled&&this.menuService.isHeaderFilterButtonEnabled(this.column),enableFilterIcon:!this.openFilterEnabled||this.menuService.isLegacyMenuEnabled(),showColumnMenu:e=>{this.menuService.showColumnMenu({column:this.column,buttonElement:e,positionBy:"button"})},showColumnMenuAfterMouseClick:e=>{this.menuService.showColumnMenu({column:this.column,mouseEvent:e,positionBy:"mouse"})},showFilter:e=>{this.menuService.showFilterMenu({column:this.column,buttonElement:e,containerType:"columnFilter",positionBy:"button"})},progressSort:e=>{this.beans.sortController.progressSort(this.column,!!e,"uiColumnSorted")},setSort:(e,t)=>{this.beans.sortController.setSortForColumn(this.column,e,!!t,"uiColumnSorted")},eGridHeader:this.getGui(),setTooltip:(e,t)=>{this.setupTooltip(e,t)}})}setupSelectAll(){this.selectAllFeature=this.createManagedBean(new nl(this.column)),this.selectAllFeature.setComp(this)}getSelectAllGui(){return this.selectAllFeature.getCheckboxGui()}handleKeyDown(e){super.handleKeyDown(e),e.key===Yr.SPACE&&this.selectAllFeature.onSpaceKeyDown(e),e.key===Yr.ENTER&&this.onEnterKeyDown(e),e.key===Yr.DOWN&&e.altKey&&this.showMenuOnKeyPress(e,!1)}onEnterKeyDown(e){if(e.ctrlKey||e.metaKey)this.showMenuOnKeyPress(e,!0);else if(this.sortable){const t=e.shiftKey;this.beans.sortController.progressSort(this.column,t,"uiColumnSorted")}}showMenuOnKeyPress(e,t){const i=this.comp.getUserCompInstance();i&&i instanceof ws&&i.onMenuKeyboardShortcut(t)&&e.preventDefault()}onFocusIn(e){if(!this.getGui().contains(e.relatedTarget)){const e=this.getRowIndex();this.focusService.setFocusedHeader(e,this.column),this.announceAriaDescription()}this.focusService.isKeyboardMode()&&this.setActiveHeader(!0)}onFocusOut(e){this.getGui().contains(e.relatedTarget)||this.setActiveHeader(!1)}setupTooltip(e,t){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const i="whenTruncated"===this.gos.get("tooltipShowMode"),r=this.eGui,n=this.column.getColDef();t||!i||n.headerComponent||(t=()=>{const e=r.querySelector(".ag-header-cell-text");return!e||e.scrollWidth>e.clientWidth});const s={getColumn:()=>this.column,getColDef:()=>this.column.getColDef(),getGui:()=>r,getLocation:()=>"header",getTooltipValue:()=>null!=e?e:this.column.getColDef().headerTooltip,shouldDisplayTooltip:t},o=this.createManagedBean(new mn(s));this.refreshFunctions.push(()=>o.refreshToolTip())}setupClassesFromColDef(){const e=()=>{const e=this.column.getColDef(),t=ha.getHeaderClassesFromColDef(e,this.gos,this.column,null),i=this.userHeaderClasses;this.userHeaderClasses=new Set(t),t.forEach(e=>{i.has(e)?i.delete(e):this.comp.addOrRemoveCssClass(e,!0)}),i.forEach(e=>this.comp.addOrRemoveCssClass(e,!1))};this.refreshFunctions.push(e),e()}setDragSource(e){if(this.dragSourceElement=e,this.removeDragSource(),!e||!this.draggable)return;const{column:t,beans:i,displayName:r,dragAndDropService:n,gos:s}=this,{columnModel:o}=i;let a=!this.gos.get("suppressDragLeaveHidesColumns");const l=this.dragSource={type:1,eElement:e,getDefaultIconName:()=>a?Gs.ICON_HIDE:Gs.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(t),dragItemName:r,onDragStarted:()=>{a=!s.get("suppressDragLeaveHidesColumns"),t.setMoving(!0,"uiColumnMoved")},onDragStopped:()=>t.setMoving(!1,"uiColumnMoved"),onGridEnter:e=>{var t;if(a){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!0,"uiColumnMoved")}},onGridExit:e=>{var t;if(a){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!1,"uiColumnMoved")}}};n.addDragSource(l,!0)}createDragItem(e){const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t}}updateState(){this.menuEnabled=this.menuService.isColumnMenuInHeaderEnabled(this.column),this.openFilterEnabled=this.menuService.isFilterMenuInHeaderEnabled(this.column),this.sortable=this.column.isSortable(),this.displayName=this.calculateDisplayName(),this.draggable=this.workOutDraggable()}addRefreshFunction(e){this.refreshFunctions.push(e)}refresh(){this.updateState(),this.refreshHeaderComp(),this.refreshAria(),this.refreshFunctions.forEach(e=>e())}refreshHeaderComp(){const e=this.lookupUserCompDetails();null!=this.comp.getUserCompInstance()&&this.userCompDetails.componentClass==e.componentClass&&this.attemptHeaderCompRefresh(e.params)?this.setDragSource(this.dragSourceElement):this.setCompDetails(e)}attemptHeaderCompRefresh(e){const t=this.comp.getUserCompInstance();return!!t&&(!!t.refresh&&t.refresh(e))}calculateDisplayName(){return this.beans.columnModel.getDisplayNameForColumn(this.column,"header",!0)}checkDisplayName(){this.displayName!==this.calculateDisplayName()&&this.refresh()}workOutDraggable(){const e=this.column.getColDef();return!(this.gos.get("suppressMovableColumns")||e.suppressMovable||e.lockPosition)||!!e.enableRowGroup||!!e.enablePivot}onColumnRowGroupChanged(){this.checkDisplayName()}onColumnPivotChanged(){this.checkDisplayName()}onColumnValueChanged(){this.checkDisplayName()}setupWidth(){const e=()=>{const e=this.column.getActualWidth();this.comp.setWidth(`${e}px`)};this.addManagedListener(this.column,Se.EVENT_WIDTH_CHANGED,e),e()}setupMovingCss(){const e=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-moving",this.column.isMoving())};this.addManagedListener(this.column,Se.EVENT_MOVING_CHANGED,e),e()}setupMenuClass(){const e=()=>{this.comp.addOrRemoveCssClass("ag-column-menu-visible",this.column.isMenuVisible())};this.addManagedListener(this.column,Se.EVENT_MENU_VISIBLE_CHANGED,e),e()}setupSortableClass(){const e=()=>{this.comp.addOrRemoveCssClass("ag-header-cell-sortable",!!this.sortable)};e(),this.addRefreshFunction(e),this.addManagedListener(this.eventService,Se.EVENT_SORT_CHANGED,this.refreshAriaSort.bind(this))}setupFilterClass(){const e=()=>{const e=this.column.isFilterActive();this.comp.addOrRemoveCssClass("ag-header-cell-filtered",e),this.refreshAria()};this.addManagedListener(this.column,Se.EVENT_FILTER_ACTIVE_CHANGED,e),e()}setupWrapTextClass(){const e=()=>{const e=!!this.column.getColDef().wrapHeaderText;this.comp.addOrRemoveCssClass("ag-header-cell-wrap-text",e)};e(),this.addRefreshFunction(e)}onDisplayedColumnsChanged(){super.onDisplayedColumnsChanged(),this.isAlive()&&this.onHeaderHeightChanged()}onHeaderHeightChanged(){this.refreshSpanHeaderHeight()}refreshSpanHeaderHeight(){const{eGui:e,column:t,comp:i,beans:r}=this;if(!t.isSpanHeaderHeight())return e.style.removeProperty("top"),e.style.removeProperty("height"),i.addOrRemoveCssClass("ag-header-span-height",!1),void i.addOrRemoveCssClass("ag-header-span-total",!1);const{numberOfParents:n,isSpanningTotal:s}=this.column.getColumnGroupPaddingInfo();i.addOrRemoveCssClass("ag-header-span-height",n>0);const{columnModel:o}=r,a=o.getColumnHeaderRowHeight();if(0===n)return i.addOrRemoveCssClass("ag-header-span-total",!1),e.style.setProperty("top","0px"),void e.style.setProperty("height",`${a}px`);i.addOrRemoveCssClass("ag-header-span-total",s);const l=n*(o.isPivotMode()?o.getPivotGroupHeaderHeight():o.getGroupHeaderHeight());e.style.setProperty("top",-l+"px"),e.style.setProperty("height",`${a+l}px`)}setupAutoHeight(e){const{columnModel:t,resizeObserverService:i}=this.beans,r=i=>{if(!this.isAlive())return;const{paddingTop:n,paddingBottom:s,borderBottomWidth:o,borderTopWidth:a}=cr(this.getGui()),l=n+s+o+a,c=e.offsetHeight+l;if(i<5){const t=this.beans.gos.getDocument();if(!t||!t.contains(e)||0==c)return void window.setTimeout(()=>r(i+1),0)}t.setColumnHeaderHeight(this.column,c)};let n,s=!1;const o=()=>{const e=this.column.isAutoHeaderHeight();e&&!s&&a(),!e&&s&&l()},a=()=>{s=!0,r(0),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!0),n=i.observeResize(e,()=>r(0))},l=()=>{s=!1,n&&n(),this.comp.addOrRemoveCssClass("ag-header-cell-auto-height",!1),n=void 0};o(),this.addDestroyFunc(()=>l()),this.addManagedListener(this.column,Se.EVENT_WIDTH_CHANGED,()=>s&&r(0)),this.addManagedListener(this.eventService,Se.EVENT_SORT_CHANGED,()=>{s&&window.setTimeout(()=>r(0))}),this.addRefreshFunction(o)}refreshAriaSort(){if(this.sortable){const e=this.localeService.getLocaleTextFunc(),t=this.beans.sortController.getDisplaySortForColumn(this.column)||null;this.comp.setAriaSort(Bt(t)),this.setAriaDescriptionProperty("sort",e("ariaSortableColumn","Press ENTER to sort"))}else this.comp.setAriaSort(),this.setAriaDescriptionProperty("sort",null)}refreshAriaMenu(){if(this.menuEnabled){const e=this.localeService.getLocaleTextFunc();this.setAriaDescriptionProperty("menu",e("ariaMenuColumn","Press ALT DOWN to open column menu"))}else this.setAriaDescriptionProperty("menu",null)}refreshAriaFilterButton(){if(this.openFilterEnabled&&!this.menuService.isLegacyMenuEnabled()){const e=this.localeService.getLocaleTextFunc();this.setAriaDescriptionProperty("filterButton",e("ariaFilterColumn","Press CTRL ENTER to open filter"))}else this.setAriaDescriptionProperty("filterButton",null)}refreshAriaFiltered(){const e=this.localeService.getLocaleTextFunc();this.column.isFilterActive()?this.setAriaDescriptionProperty("filter",e("ariaColumnFiltered","Column Filtered")):this.setAriaDescriptionProperty("filter",null)}setAriaDescriptionProperty(e,t){null!=t?this.ariaDescriptionProperties.set(e,t):this.ariaDescriptionProperties.delete(e)}announceAriaDescription(){if(!this.eGui.contains(this.beans.gos.getActiveDomElement()))return;const e=Array.from(this.ariaDescriptionProperties.keys()).sort((e,t)=>"filter"===e?-1:t.charCodeAt(0)-e.charCodeAt(0)).map(e=>this.ariaDescriptionProperties.get(e)).join(". ");this.beans.ariaAnnouncementService.announceValue(e)}refreshAria(){this.refreshAriaSort(),this.refreshAriaMenu(),this.refreshAriaFilterButton(),this.refreshAriaFiltered()}addColumnHoverListener(){const e=()=>{if(!this.gos.get("columnHoverHighlight"))return;const e=this.beans.columnHoverService.isHovered(this.column);this.comp.addOrRemoveCssClass("ag-column-hover",e)};this.addManagedListener(this.eventService,lt.EVENT_COLUMN_HOVER_CHANGED,e),e()}getColId(){return this.column.getColId()}addActiveHeaderMouseListeners(){const e=e=>this.handleMouseOverChange("mouseenter"===e.type);this.addManagedListener(this.getGui(),"mouseenter",e),this.addManagedListener(this.getGui(),"mouseleave",e),this.addManagedListener(this.getGui(),"click",()=>this.dispatchColumnMouseEvent(lt.EVENT_COLUMN_HEADER_CLICKED,this.column)),this.addManagedListener(this.getGui(),"contextmenu",e=>this.handleContextMenuMouseEvent(e,void 0,this.column))}handleMouseOverChange(e){this.setActiveHeader(e);const t={type:e?lt.EVENT_COLUMN_HEADER_MOUSE_OVER:lt.EVENT_COLUMN_HEADER_MOUSE_LEAVE,column:this.column};this.eventService.dispatchEvent(t)}setActiveHeader(e){this.comp.addOrRemoveCssClass("ag-header-active",e)}getAnchorElementForMenu(e){const t=this.comp.getUserCompInstance();return t instanceof ws?t.getAnchorElementForMenu(e):this.getGui()}destroy(){super.destroy(),this.refreshFunctions=null,this.selectAllFeature=null,this.dragSourceElement=null,this.userCompDetails=null,this.userHeaderClasses=null,this.ariaDescriptionProperties=null}},ol=class extends rt{constructor(e,t,i,r){super(),this.eResize=t,this.comp=e,this.pinned=i,this.columnGroup=r}postConstruct(){if(!this.columnGroup.isResizable())return void this.comp.setResizableDisplayed(!1);const e=this.horizontalResizeService.addResizeBar({eResizeBar:this.eResize,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this,!1),onResizeEnd:this.onResizing.bind(this,!0)});if(this.addDestroyFunc(e),!this.gos.get("suppressAutoSize")){const e=this.gos.get("skipHeaderOnAutoSize");this.eResize.addEventListener("dblclick",()=>{const t=[];this.columnGroup.getDisplayedLeafColumns().forEach(e=>{e.getColDef().suppressAutoSize||t.push(e.getColId())}),t.length>0&&this.columnModel.autoSizeColumns({columns:t,skipHeader:e,stopAtGroup:this.columnGroup,source:"uiColumnResized"}),this.resizeLeafColumnsToFit("uiColumnResized")})}}onResizeStart(e){const t=this.getInitialValues(e);this.storeLocalValues(t),this.toggleColumnResizing(!0)}onResizing(e,t,i="uiColumnResized"){const r=this.normaliseDragChange(t),n=this.resizeStartWidth+r;this.resizeColumnsFromLocalValues(n,i,e)}getInitialValues(e){const t=this.getColumnsToResize(),i=this.getInitialSizeOfColumns(t),r={columnsToResize:t,resizeStartWidth:i,resizeRatios:this.getSizeRatiosOfColumns(t,i)};let n=null;if(e&&(n=this.columnModel.getDisplayedGroupAtDirection(this.columnGroup,"After")),n){const e=n.getDisplayedLeafColumns(),t=r.groupAfterColumns=e.filter(e=>e.isResizable()),i=r.groupAfterStartWidth=this.getInitialSizeOfColumns(t);r.groupAfterRatios=this.getSizeRatiosOfColumns(t,i)}else r.groupAfterColumns=void 0,r.groupAfterStartWidth=void 0,r.groupAfterRatios=void 0;return r}storeLocalValues(e){const{columnsToResize:t,resizeStartWidth:i,resizeRatios:r,groupAfterColumns:n,groupAfterStartWidth:s,groupAfterRatios:o}=e;this.resizeCols=t,this.resizeStartWidth=i,this.resizeRatios=r,this.resizeTakeFromCols=n,this.resizeTakeFromStartWidth=s,this.resizeTakeFromRatios=o}clearLocalValues(){this.resizeCols=void 0,this.resizeRatios=void 0,this.resizeTakeFromCols=void 0,this.resizeTakeFromRatios=void 0}resizeLeafColumnsToFit(e){const t=this.autoWidthCalculator.getPreferredWidthForColumnGroup(this.columnGroup),i=this.getInitialValues();t>i.resizeStartWidth&&this.resizeColumns(i,t,e,!0)}resizeColumnsFromLocalValues(e,t,i=!0){var r,n,s;if(!this.resizeCols||!this.resizeRatios)return;const o={columnsToResize:this.resizeCols,resizeStartWidth:this.resizeStartWidth,resizeRatios:this.resizeRatios,groupAfterColumns:null!=(r=this.resizeTakeFromCols)?r:void 0,groupAfterStartWidth:null!=(n=this.resizeTakeFromStartWidth)?n:void 0,groupAfterRatios:null!=(s=this.resizeTakeFromRatios)?s:void 0};this.resizeColumns(o,e,t,i)}resizeColumns(e,t,i,r=!0){const{columnsToResize:n,resizeStartWidth:s,resizeRatios:o,groupAfterColumns:a,groupAfterStartWidth:l,groupAfterRatios:c}=e,u=[];if(u.push({columns:n,ratios:o,width:t}),a){const e=t-s;u.push({columns:a,ratios:c,width:l-e})}this.columnModel.resizeColumnSets({resizeSets:u,finished:r,source:i}),r&&this.toggleColumnResizing(!1)}toggleColumnResizing(e){this.comp.addOrRemoveCssClass("ag-column-resizing",e)}getColumnsToResize(){return this.columnGroup.getDisplayedLeafColumns().filter(e=>e.isResizable())}getInitialSizeOfColumns(e){return e.reduce((e,t)=>e+t.getActualWidth(),0)}getSizeRatiosOfColumns(e,t){return e.map(e=>e.getActualWidth()/t)}normaliseDragChange(e){let t=e;return this.gos.get("enableRtl")?"left"!==this.pinned&&(t*=-1):"right"===this.pinned&&(t*=-1),t}destroy(){super.destroy(),this.clearLocalValues()}};g([ue("horizontalResizeService")],ol.prototype,"horizontalResizeService",2),g([ue("autoWidthCalculator")],ol.prototype,"autoWidthCalculator",2),g([ue("columnModel")],ol.prototype,"columnModel",2),g([ae],ol.prototype,"postConstruct",1);var al=class extends rt{constructor(e,t){super(),this.removeChildListenersFuncs=[],this.columnGroup=t,this.comp=e}postConstruct(){this.addListenersToChildrenColumns(),this.addManagedListener(this.columnGroup,at.EVENT_DISPLAYED_CHILDREN_CHANGED,this.onDisplayedChildrenChanged.bind(this)),this.onWidthChanged(),this.addDestroyFunc(this.removeListenersOnChildrenColumns.bind(this))}addListenersToChildrenColumns(){this.removeListenersOnChildrenColumns();const e=this.onWidthChanged.bind(this);this.columnGroup.getLeafColumns().forEach(t=>{t.addEventListener("widthChanged",e),t.addEventListener("visibleChanged",e),this.removeChildListenersFuncs.push(()=>{t.removeEventListener("widthChanged",e),t.removeEventListener("visibleChanged",e)})})}removeListenersOnChildrenColumns(){this.removeChildListenersFuncs.forEach(e=>e()),this.removeChildListenersFuncs=[]}onDisplayedChildrenChanged(){this.addListenersToChildrenColumns(),this.onWidthChanged()}onWidthChanged(){const e=this.columnGroup.getActualWidth();this.comp.setWidth(`${e}px`),this.comp.addOrRemoveCssClass("ag-hidden",0===e)}};g([ae],al.prototype,"postConstruct",1);var ll=class extends Ja{constructor(e,t,i){super(e,t,i),this.onSuppressColMoveChange=()=>{if(!this.isAlive()||this.isSuppressMoving())this.removeDragSource();else if(!this.dragSource){const e=this.getGui();this.setDragSource(e)}},this.column=e}setComp(e,t,i){this.comp=e,this.setGui(t),this.displayName=this.beans.columnModel.getDisplayNameForColumnGroup(this.column,"header"),this.addClasses(),this.setupMovingCss(),this.setupExpandable(),this.setupTooltip(),this.addDestroyFunc(()=>{this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature))}),this.setupUserComp(),this.addHeaderMouseListeners();const r=this.getParentRowCtrl().getPinned(),n=this.column.getProvidedColumnGroup().getLeafColumns();this.createManagedBean(new tl(n,t)),this.createManagedBean(new el(this.column,t,this.beans)),this.createManagedBean(new al(e,this.column)),this.resizeFeature=this.createManagedBean(new ol(e,i,r,this.column)),this.createManagedBean(new _n(t,{shouldStopEventPropagation:this.shouldStopEventPropagation.bind(this),onTabKeyDown:()=>{},handleKeyDown:this.handleKeyDown.bind(this),onFocusIn:this.onFocusIn.bind(this)})),this.addManagedPropertyListener(lt.EVENT_SUPPRESS_COLUMN_MOVE_CHANGED,this.onSuppressColMoveChange),this.addResizeAndMoveKeyboardListeners()}resizeHeader(e,t){if(!this.resizeFeature)return;const i=this.resizeFeature.getInitialValues(t);this.resizeFeature.resizeColumns(i,i.resizeStartWidth+e,"uiColumnResized",!0)}moveHeader(e){const{beans:t,eGui:i,column:r,gos:n,ctrlsService:s}=this,o=n.get("enableRtl"),a=0===e,l=this.getPinned(),c=i.getBoundingClientRect(),u=c.left,h=c.width,d=za.normaliseX(a!==o?u-20:u+h+20,l,!0,n,s),p=r.getGroupId(),g=this.focusService.getFocusedHeader();za.attemptMoveColumns({allMovingColumns:this.column.getLeafColumns(),isFromHeader:!0,hDirection:e,xPosition:d,pinned:l,fromEnter:!1,fakeEvent:!1,gos:n,columnModel:t.columnModel});const f=r.getDisplayedLeafColumns(),m=a?f[0]:_e(f);this.ctrlsService.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(m,"auto"),!this.isAlive()&&g&&this.restoreFocus(p,r,g)}restoreFocus(e,t,i){const r=t.getLeafColumns();if(!r.length)return;const n=r[0].getParent();if(!n)return;const s=this.findGroupWidthId(n,e);s&&this.focusService.focusHeaderPosition({headerPosition:d(h({},i),{column:s})})}findGroupWidthId(e,t){for(;e;){if(e.getGroupId()===t)return e;e=e.getParent()}return null}resizeLeafColumnsToFit(e){this.resizeFeature&&this.resizeFeature.resizeLeafColumnsToFit(e)}setupUserComp(){const e=this.gos.addGridCommonParams({displayName:this.displayName,columnGroup:this.column,setExpanded:e=>{this.beans.columnModel.setColumnGroupOpened(this.column.getProvidedColumnGroup(),e,"gridInitializing")},setTooltip:(e,t)=>{this.setupTooltip(e,t)}}),t=this.userComponentFactory.getHeaderGroupCompDetails(e);this.comp.setUserCompDetails(t)}addHeaderMouseListeners(){const e=e=>this.handleMouseOverChange("mouseenter"===e.type);this.addManagedListener(this.getGui(),"mouseenter",e),this.addManagedListener(this.getGui(),"mouseleave",e),this.addManagedListener(this.getGui(),"click",()=>this.dispatchColumnMouseEvent(lt.EVENT_COLUMN_HEADER_CLICKED,this.column.getProvidedColumnGroup())),this.addManagedListener(this.getGui(),"contextmenu",e=>this.handleContextMenuMouseEvent(e,void 0,this.column.getProvidedColumnGroup()))}handleMouseOverChange(e){const t={type:e?lt.EVENT_COLUMN_HEADER_MOUSE_OVER:lt.EVENT_COLUMN_HEADER_MOUSE_LEAVE,column:this.column.getProvidedColumnGroup()};this.eventService.dispatchEvent(t)}setupTooltip(e,t){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature));const i=this.column.getColGroupDef(),r="whenTruncated"===this.gos.get("tooltipShowMode"),n=this.eGui;t||!r||(null==i?void 0:i.headerGroupComponent)||(t=()=>{const e=n.querySelector(".ag-header-group-text");return!e||e.scrollWidth>e.clientWidth});const s={getColumn:()=>this.column,getGui:()=>n,getLocation:()=>"headerGroup",getTooltipValue:()=>null!=e?e:i&&i.headerTooltip,shouldDisplayTooltip:t};i&&(s.getColDef=()=>i),this.createBean(new mn(s))}setupExpandable(){const e=this.column.getProvidedColumnGroup();this.refreshExpanded(),this.addManagedListener(e,Ee.EVENT_EXPANDABLE_CHANGED,this.refreshExpanded.bind(this)),this.addManagedListener(e,Ee.EVENT_EXPANDED_CHANGED,this.refreshExpanded.bind(this))}refreshExpanded(){const e=this.column;this.expandable=e.isExpandable();const t=e.isExpanded();this.expandable?this.comp.setAriaExpanded(t?"true":"false"):this.comp.setAriaExpanded(void 0)}getColId(){return this.column.getUniqueId()}addClasses(){const e=this.column.getColGroupDef(),t=ha.getHeaderClassesFromColDef(e,this.gos,null,this.column);this.column.isPadding()?(t.push("ag-header-group-cell-no-group"),this.column.getLeafColumns().every(e=>e.isSpanHeaderHeight())&&t.push("ag-header-span-height")):t.push("ag-header-group-cell-with-group"),t.forEach(e=>this.comp.addOrRemoveCssClass(e,!0))}setupMovingCss(){const e=this.column.getProvidedColumnGroup().getLeafColumns(),t=()=>this.comp.addOrRemoveCssClass("ag-header-cell-moving",this.column.isMoving());e.forEach(e=>{this.addManagedListener(e,Se.EVENT_MOVING_CHANGED,t)}),t()}onFocusIn(e){if(!this.eGui.contains(e.relatedTarget)){const e=this.getRowIndex();this.beans.focusService.setFocusedHeader(e,this.column)}}handleKeyDown(e){super.handleKeyDown(e);const t=this.getWrapperHasFocus();if(this.expandable&&t&&e.key===Yr.ENTER){const e=this.column,t=!e.isExpanded();this.beans.columnModel.setColumnGroupOpened(e.getProvidedColumnGroup(),t,"uiColumnExpanded")}}setDragSource(e){if(!this.isAlive()||this.isSuppressMoving())return;if(this.removeDragSource(),!e)return;const{beans:t,column:i,displayName:r,gos:n,dragAndDropService:s}=this,{columnModel:o}=t,a=i.getProvidedColumnGroup().getLeafColumns();let l=!n.get("suppressDragLeaveHidesColumns");const c=this.dragSource={type:1,eElement:e,getDefaultIconName:()=>l?Gs.ICON_HIDE:Gs.ICON_NOT_ALLOWED,dragItemName:r,getDragItem:()=>this.getDragItemForGroup(i),onDragStarted:()=>{l=!n.get("suppressDragLeaveHidesColumns"),a.forEach(e=>e.setMoving(!0,"uiColumnDragged"))},onDragStopped:()=>a.forEach(e=>e.setMoving(!1,"uiColumnDragged")),onGridEnter:e=>{var t;if(l){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!0,"uiColumnMoved")}},onGridExit:e=>{var t;if(l){const i=(null==(t=null==e?void 0:e.columns)?void 0:t.filter(e=>!e.getColDef().lockVisible))||[];o.setColumnsVisible(i,!1,"uiColumnMoved")}}};s.addDragSource(c,!0)}getDragItemForGroup(e){const t=e.getProvidedColumnGroup().getLeafColumns(),i={};t.forEach(e=>i[e.getId()]=e.isVisible());const r=[];return this.beans.columnModel.getAllDisplayedColumns().forEach(e=>{t.indexOf(e)>=0&&(r.push(e),Ne(t,e))}),t.forEach(e=>r.push(e)),{columns:r,visibleState:i}}isSuppressMoving(){let e=!1;return this.column.getLeafColumns().forEach(t=>{(t.getColDef().suppressMovable||t.getColDef().lockPosition)&&(e=!0)}),e||this.gos.get("suppressMovableColumns")}},cl=0,ul=class extends rt{constructor(e,t,i){super(),this.instanceId=cl++,this.rowIndex=e,this.pinned=t,this.type=i;const r="group"==i?"ag-header-row-column-group":"filter"==i?"ag-header-row-column-filter":"ag-header-row-column";this.headerRowClass=`ag-header-row ${r}`}postConstruct(){this.isPrintLayout=this.gos.isDomLayout("print"),this.isEnsureDomOrder=this.gos.get("ensureDomOrder")}getInstanceId(){return this.instanceId}setComp(e,t=!0){this.comp=e,t&&(this.onRowHeightChanged(),this.onVirtualColumnsChanged()),this.setWidth(),this.addEventListeners()}getHeaderRowClass(){return this.headerRowClass}getAriaRowIndex(){return this.rowIndex+1}addEventListeners(){this.addManagedListener(this.eventService,lt.EVENT_COLUMN_RESIZED,this.onColumnResized.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_VIRTUAL_COLUMNS_CHANGED,e=>this.onVirtualColumnsChanged(e.afterScroll)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_GRID_STYLES_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("domLayout",this.onDisplayedColumnsChanged.bind(this)),this.addManagedPropertyListener("ensureDomOrder",e=>this.isEnsureDomOrder=e.currentValue),this.addManagedPropertyListener("headerHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("pivotHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("groupHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("pivotGroupHeaderHeight",this.onRowHeightChanged.bind(this)),this.addManagedPropertyListener("floatingFiltersHeight",this.onRowHeightChanged.bind(this))}getHeaderCellCtrl(e){if(this.headerCellCtrls)return R(this.headerCellCtrls).find(t=>t.getColumnGroupChild()===e)}onDisplayedColumnsChanged(){this.isPrintLayout=this.gos.isDomLayout("print"),this.onVirtualColumnsChanged(),this.setWidth(),this.onRowHeightChanged()}getType(){return this.type}onColumnResized(){this.setWidth()}setWidth(){const e=this.getWidthForRow();this.comp.setWidth(`${e}px`)}getWidthForRow(){const{columnModel:e}=this.beans;return this.isPrintLayout?null!=this.pinned?0:e.getContainerWidth("right")+e.getContainerWidth("left")+e.getContainerWidth(null):e.getContainerWidth(this.pinned)}onRowHeightChanged(){var{topOffset:e,rowHeight:t}=this.getTopAndHeight();this.comp.setTop(e+"px"),this.comp.setHeight(t+"px")}getTopAndHeight(){const{columnModel:e,filterManager:t}=this.beans;let i=e.getHeaderRowCount();const r=[];let n=0;t.hasFloatingFilters()&&(i++,n=1);const s=e.getColumnGroupHeaderRowHeight(),o=e.getColumnHeaderRowHeight(),a=i-(1+n);for(let e=0;e<a;e++)r.push(s);r.push(o);for(let t=0;t<n;t++)r.push(e.getFloatingFiltersHeight());let l=0;for(let e=0;e<this.rowIndex;e++)l+=r[e];return{topOffset:l,rowHeight:r[this.rowIndex]}}getPinned(){return this.pinned}getRowIndex(){return this.rowIndex}onVirtualColumnsChanged(e=!1){const t=this.getHeaderCtrls(),i=this.isEnsureDomOrder||this.isPrintLayout;this.comp.setHeaderCtrls(t,i,e)}getHeaderCtrls(){const e=this.headerCellCtrls;this.headerCellCtrls=new Map;const t=this.getColumnsInViewport();for(const i of t)this.recycleAndCreateHeaderCtrls(i,e);const i=e=>{const{focusService:t,columnModel:i}=this.beans;return!!t.isHeaderWrapperFocused(e)&&i.isDisplayed(e.getColumnGroupChild())};if(e)for(const[t,r]of e)i(r)?this.headerCellCtrls.set(t,r):this.destroyBean(r);return Array.from(this.headerCellCtrls.values())}recycleAndCreateHeaderCtrls(e,t){if(!this.headerCellCtrls)return;if(e.isEmptyGroup())return;const i=e.getUniqueId();let r;if(t&&(r=t.get(i),t.delete(i)),r&&r.getColumnGroupChild()!=e&&(this.destroyBean(r),r=void 0),null==r)switch(this.type){case"filter":r=this.createBean(new il(e,this.beans,this));break;case"group":r=this.createBean(new ll(e,this.beans,this));break;default:r=this.createBean(new sl(e,this.beans,this))}this.headerCellCtrls.set(i,r)}getColumnsInViewport(){return this.isPrintLayout?this.getColumnsInViewportPrintLayout():this.getColumnsInViewportNormalLayout()}getColumnsInViewportPrintLayout(){if(null!=this.pinned)return[];let e=[];const t=this.getActualDepth(),{columnModel:i}=this.beans;return["left",null,"right"].forEach(r=>{const n=i.getVirtualHeaderGroupRow(r,t);e=e.concat(n)}),e}getActualDepth(){return"filter"==this.type?this.rowIndex-1:this.rowIndex}getColumnsInViewportNormalLayout(){return this.beans.columnModel.getVirtualHeaderGroupRow(this.pinned,this.getActualDepth())}focusHeader(e,t){if(!this.headerCellCtrls)return!1;const i=Array.from(this.headerCellCtrls.values()).find(t=>t.getColumnGroupChild()==e);return!!i&&i.focus(t)}destroy(){this.headerCellCtrls&&this.headerCellCtrls.forEach(e=>{this.destroyBean(e)}),this.headerCellCtrls=void 0,super.destroy()}};g([ue("beans")],ul.prototype,"beans",2),g([ae],ul.prototype,"postConstruct",1);var hl=class extends rt{constructor(e){super(),this.hidden=!1,this.includeFloatingFilter=!1,this.groupsRowCtrls=[],this.pinned=e}setComp(e,t){this.comp=e,this.eViewport=t,this.setupCenterWidth(),this.setupPinnedWidth(),this.setupDragAndDrop(this.eViewport),this.addManagedListener(this.eventService,lt.EVENT_GRID_COLUMNS_CHANGED,this.onGridColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.ctrlsService.registerHeaderContainer(this,this.pinned),this.columnModel.isReady()&&this.refresh()}setupDragAndDrop(e){const t=new Wa(this.pinned,e);this.createManagedBean(t)}refresh(e=!1){const t=new cn,i=this.focusService.getFocusHeaderToUseAfterRefresh();(()=>{const e=this.columnModel.getHeaderRowCount()-1;this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls);for(let i=0;i<e;i++){const e=this.createBean(new ul(t.next(),this.pinned,"group"));this.groupsRowCtrls.push(e)}})(),(()=>{const i=t.next(),r=!(this.hidden||null!=this.columnsRowCtrl&&e&&this.columnsRowCtrl.getRowIndex()===i);(r||this.hidden)&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),r&&(this.columnsRowCtrl=this.createBean(new ul(i,this.pinned,"column")))})(),(()=>{this.includeFloatingFilter=this.filterManager.hasFloatingFilters()&&!this.hidden;const i=()=>{this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)};if(!this.includeFloatingFilter)return void i();const r=t.next();if(this.filtersRowCtrl){const t=this.filtersRowCtrl.getRowIndex()!==r;e&&!t||i()}this.filtersRowCtrl||(this.filtersRowCtrl=this.createBean(new ul(r,this.pinned,"filter")))})();const r=this.getAllCtrls();this.comp.setCtrls(r),this.restoreFocusOnHeader(i)}restoreFocusOnHeader(e){null!=e&&e.column.getPinned()==this.pinned&&this.focusService.focusHeaderPosition({headerPosition:e})}getAllCtrls(){const e=[...this.groupsRowCtrls];return this.columnsRowCtrl&&e.push(this.columnsRowCtrl),this.filtersRowCtrl&&e.push(this.filtersRowCtrl),e}onGridColumnsChanged(){this.refresh(!0)}onDisplayedColumnsChanged(){const e=this.filterManager.hasFloatingFilters()&&!this.hidden;this.includeFloatingFilter!==e&&this.refresh(!0)}setupCenterWidth(){null==this.pinned&&this.createManagedBean(new Aa(e=>this.comp.setCenterWidth(`${e}px`),!0))}setHorizontalScroll(e){this.comp.setViewportScrollLeft(e)}setupPinnedWidth(){if(null==this.pinned)return;const e="left"===this.pinned,t="right"===this.pinned;this.hidden=!0;const i=()=>{const i=e?this.pinnedWidthService.getPinnedLeftWidth():this.pinnedWidthService.getPinnedRightWidth();if(null==i)return;const r=0==i,n=this.hidden!==r,s=this.gos.get("enableRtl"),o=this.gos.getScrollbarWidth(),a=this.scrollVisibleService.isVerticalScrollShowing()&&(s&&e||!s&&t)?i+o:i;this.comp.setPinnedContainerWidth(`${a}px`),this.comp.setDisplayed(!r),n&&(this.hidden=r,this.refresh())};this.addManagedListener(this.eventService,lt.EVENT_LEFT_PINNED_WIDTH_CHANGED,i),this.addManagedListener(this.eventService,lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED,i),this.addManagedListener(this.eventService,lt.EVENT_SCROLL_VISIBILITY_CHANGED,i),this.addManagedListener(this.eventService,lt.EVENT_SCROLLBAR_WIDTH_CHANGED,i)}getHeaderCtrlForColumn(e){if(e instanceof Se){if(!this.columnsRowCtrl)return;return this.columnsRowCtrl.getHeaderCellCtrl(e)}if(0!==this.groupsRowCtrls.length)for(let t=0;t<this.groupsRowCtrls.length;t++){const i=this.groupsRowCtrls[t].getHeaderCellCtrl(e);if(i)return i}}getHtmlElementForColumnHeader(e){const t=this.getHeaderCtrlForColumn(e);return t?t.getGui():null}getRowType(e){const t=this.getAllCtrls()[e];return t?t.getType():void 0}focusHeader(e,t,i){const r=this.getAllCtrls()[e];return!!r&&r.focusHeader(t,i)}getViewport(){return this.eViewport}getRowCount(){return this.groupsRowCtrls.length+(this.columnsRowCtrl?1:0)+(this.filtersRowCtrl?1:0)}destroy(){this.filtersRowCtrl&&(this.filtersRowCtrl=this.destroyBean(this.filtersRowCtrl)),this.columnsRowCtrl&&(this.columnsRowCtrl=this.destroyBean(this.columnsRowCtrl)),this.groupsRowCtrls&&this.groupsRowCtrls.length&&(this.groupsRowCtrls=this.destroyBeans(this.groupsRowCtrls)),super.destroy()}};g([ue("ctrlsService")],hl.prototype,"ctrlsService",2),g([ue("scrollVisibleService")],hl.prototype,"scrollVisibleService",2),g([ue("pinnedWidthService")],hl.prototype,"pinnedWidthService",2),g([ue("columnModel")],hl.prototype,"columnModel",2),g([ue("focusService")],hl.prototype,"focusService",2),g([ue("filterManager")],hl.prototype,"filterManager",2);var dl=class e extends yn{constructor(e){super(),this.headerRowComps={},this.rowCompsList=[],this.pinned=e}init(){this.selectAndSetTemplate();const e={setDisplayed:e=>this.setDisplayed(e),setCtrls:e=>this.setCtrls(e),setCenterWidth:e=>this.eCenterContainer.style.width=e,setViewportScrollLeft:e=>this.getGui().scrollLeft=e,setPinnedContainerWidth:e=>{const t=this.getGui();t.style.width=e,t.style.maxWidth=e,t.style.minWidth=e}};this.createManagedBean(new hl(this.pinned)).setComp(e,this.getGui())}selectAndSetTemplate(){const t="left"==this.pinned,i="right"==this.pinned,r=t?e.PINNED_LEFT_TEMPLATE:i?e.PINNED_RIGHT_TEMPLATE:e.CENTER_TEMPLATE;this.setTemplate(r),this.eRowContainer=this.eCenterContainer?this.eCenterContainer:this.getGui()}destroyRowComps(){this.setCtrls([])}destroyRowComp(e){this.destroyBean(e),this.eRowContainer.removeChild(e.getGui())}setCtrls(e){const t=this.headerRowComps;let i;this.headerRowComps={},this.rowCompsList=[];const r=e=>{const t=e.getGui();t.parentElement!=this.eRowContainer&&this.eRowContainer.appendChild(t),i&&Er(this.eRowContainer,t,i),i=t};e.forEach(e=>{const i=e.getInstanceId(),n=t[i];delete t[i];const s=n||this.createBean(new Qa(e));this.headerRowComps[i]=s,this.rowCompsList.push(s),r(s)}),N(t).forEach(e=>this.destroyRowComp(e))}};dl.PINNED_LEFT_TEMPLATE='<div class="ag-pinned-left-header" role="rowgroup"></div>',dl.PINNED_RIGHT_TEMPLATE='<div class="ag-pinned-right-header" role="rowgroup"></div>',dl.CENTER_TEMPLATE='<div class="ag-header-viewport" role="presentation">\n            <div class="ag-header-container" ref="eCenterContainer" role="rowgroup"></div>\n        </div>',g([Sn("eCenterContainer")],dl.prototype,"eCenterContainer",2),g([ae],dl.prototype,"init",1),g([le],dl.prototype,"destroyRowComps",1);var pl=dl,gl=(e=>(e[e.UP=0]="UP",e[e.DOWN=1]="DOWN",e[e.LEFT=2]="LEFT",e[e.RIGHT=3]="RIGHT",e))(gl||{}),fl=class extends rt{constructor(){super(...arguments),this.currentHeaderRowWithoutSpan=-1}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCon=e.gridBodyCtrl});const e=this.gos.getDocument();this.addManagedListener(e,"mousedown",()=>this.setCurrentHeaderRowWithoutSpan(-1))}getHeaderRowCount(){const e=this.ctrlsService.getHeaderRowContainerCtrl();return e?e.getRowCount():0}navigateVertically(e,t,i){if(t||(t=this.focusService.getFocusedHeader()),!t)return!1;const{headerRowIndex:r,column:n}=t,s=this.getHeaderRowCount(),o=0===e;let{headerRowIndex:a,column:l,headerRowIndexWithoutSpan:c}=o?this.headerPositionUtils.getColumnVisibleParent(n,r):this.headerPositionUtils.getColumnVisibleChild(n,r),u=!1;return a<0&&(a=0,l=n,u=!0),a>=s?(a=-1,this.setCurrentHeaderRowWithoutSpan(-1)):void 0!==c&&(this.currentHeaderRowWithoutSpan=c),!(!u&&!l)&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:a,column:l},allowUserOverride:!0,event:i})}setCurrentHeaderRowWithoutSpan(e){this.currentHeaderRowWithoutSpan=e}navigateHorizontally(e,t=!1,i){const r=this.focusService.getFocusedHeader(),n=2===e,s=this.gos.get("enableRtl");let o,a;if(-1!==this.currentHeaderRowWithoutSpan?r.headerRowIndex=this.currentHeaderRowWithoutSpan:this.currentHeaderRowWithoutSpan=r.headerRowIndex,n!==s?(a="Before",o=this.headerPositionUtils.findHeader(r,a)):(a="After",o=this.headerPositionUtils.findHeader(r,a)),o||!t)return this.focusService.focusHeaderPosition({headerPosition:o,direction:a,fromTab:t,allowUserOverride:!0,event:i});if(t){const e=this.gos.getCallback("tabToNextHeader");if(e)return this.focusService.focusHeaderPositionFromUserFunc({userFunc:e,headerPosition:o,direction:a})}return this.focusNextHeaderRow(r,a,i)}focusNextHeaderRow(e,t,i){const r=e.headerRowIndex;let n,s=null;if("Before"===t?r>0&&(n=r-1,this.currentHeaderRowWithoutSpan-=1,s=this.headerPositionUtils.findColAtEdgeForHeaderRow(n,"end")):(n=r+1,this.currentHeaderRowWithoutSpan<this.getHeaderRowCount()?this.currentHeaderRowWithoutSpan+=1:this.setCurrentHeaderRowWithoutSpan(-1),s=this.headerPositionUtils.findColAtEdgeForHeaderRow(n,"start")),!s)return!1;const{column:o,headerRowIndex:a}=this.headerPositionUtils.getHeaderIndexToFocus(s.column,null==s?void 0:s.headerRowIndex);return this.focusService.focusHeaderPosition({headerPosition:{column:o,headerRowIndex:a},direction:t,fromTab:!0,allowUserOverride:!0,event:i})}scrollToColumn(e,t="After"){if(e.getPinned())return;let i;if(e instanceof at){const r=e.getDisplayedLeafColumns();i="Before"===t?_e(r):r[0]}else i=e;this.gridBodyCon.getScrollFeature().ensureColumnVisible(i)}};g([ue("focusService")],fl.prototype,"focusService",2),g([ue("headerPositionUtils")],fl.prototype,"headerPositionUtils",2),g([ue("ctrlsService")],fl.prototype,"ctrlsService",2),g([ae],fl.prototype,"postConstruct",1),fl=g([ce("headerNavigationService")],fl);var ml=class extends rt{setComp(e,t,i){this.comp=e,this.eGui=t,this.createManagedBean(new _n(i,{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),onFocusOut:this.onFocusOut.bind(this)})),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onPivotModeChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.onPivotModeChanged(),this.setupHeaderHeight();const r=this.onHeaderContextMenu.bind(this);this.addManagedListener(this.eGui,"contextmenu",r),this.mockContextMenuForIPad(r),this.ctrlsService.register("gridHeaderCtrl",this)}setupHeaderHeight(){const e=this.setHeaderHeight.bind(this);e(),this.addManagedPropertyListener("headerHeight",e),this.addManagedPropertyListener("pivotHeaderHeight",e),this.addManagedPropertyListener("groupHeaderHeight",e),this.addManagedPropertyListener("pivotGroupHeaderHeight",e),this.addManagedPropertyListener("floatingFiltersHeight",e),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_HEADER_HEIGHT_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_GRID_STYLES_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,e)}getHeaderHeight(){return this.headerHeight}setHeaderHeight(){const{columnModel:e}=this;let t,i=0,r=e.getHeaderRowCount();this.filterManager.hasFloatingFilters()&&(r++,i=1);const n=this.columnModel.getColumnGroupHeaderRowHeight(),s=this.columnModel.getColumnHeaderRowHeight(),o=r-(1+i);if(t=i*e.getFloatingFiltersHeight(),t+=o*n,t+=s,this.headerHeight===t)return;this.headerHeight=t;const a=`${t+1}px`;this.comp.setHeightAndMinHeight(a),this.eventService.dispatchEvent({type:lt.EVENT_HEADER_HEIGHT_CHANGED})}onPivotModeChanged(){const e=this.columnModel.isPivotMode();this.comp.addOrRemoveCssClass("ag-pivot-on",e),this.comp.addOrRemoveCssClass("ag-pivot-off",!e)}onDisplayedColumnsChanged(){const e=this.columnModel.getAllDisplayedColumns().some(e=>e.isSpanHeaderHeight());this.comp.addOrRemoveCssClass("ag-header-allow-overflow",e)}onTabKeyDown(e){const t=this.gos.get("enableRtl"),i=e.shiftKey!==t?2:3;(this.headerNavigationService.navigateHorizontally(i,!0,e)||this.focusService.focusNextGridCoreContainer(e.shiftKey))&&e.preventDefault()}handleKeyDown(e){let t=null;switch(e.key){case Yr.LEFT:t=2;case Yr.RIGHT:C(t)||(t=3),this.headerNavigationService.navigateHorizontally(t,!1,e);break;case Yr.UP:t=0;case Yr.DOWN:C(t)||(t=1),this.headerNavigationService.navigateVertically(t,null,e)&&e.preventDefault();break;default:return}}onFocusOut(e){const{relatedTarget:t}=e;!t&&this.eGui.contains(this.gos.getActiveDomElement())||this.eGui.contains(t)||this.focusService.clearFocusedHeader()}onHeaderContextMenu(e,t,i){if(!e&&!i||!this.menuService.isHeaderContextMenuEnabled())return;const{target:r}=null!=e?e:t;r!==this.eGui&&r!==this.ctrlsService.getHeaderRowContainerCtrl().getViewport()||this.menuService.showHeaderContextMenu(void 0,e,i)}mockContextMenuForIPad(e){if(!Di())return;const t=new ms(this.eGui);this.addManagedListener(t,ms.EVENT_LONG_TAP,t=>{e(void 0,t.touchStart,t.touchEvent)}),this.addDestroyFunc(()=>t.destroy())}};g([ue("headerNavigationService")],ml.prototype,"headerNavigationService",2),g([ue("focusService")],ml.prototype,"focusService",2),g([ue("columnModel")],ml.prototype,"columnModel",2),g([ue("ctrlsService")],ml.prototype,"ctrlsService",2),g([ue("filterManager")],ml.prototype,"filterManager",2),g([ue("menuService")],ml.prototype,"menuService",2);var vl=class e extends yn{constructor(){super(e.TEMPLATE)}postConstruct(){const e={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),setHeightAndMinHeight:e=>{this.getGui().style.height=e,this.getGui().style.minHeight=e}};this.createManagedBean(new ml).setComp(e,this.getGui(),this.getFocusableElement());const t=e=>{this.createManagedBean(e),this.appendChild(e)};t(new pl("left")),t(new pl(null)),t(new pl("right"))}};vl.TEMPLATE='<div class="ag-header" role="presentation"/>',g([ae],vl.prototype,"postConstruct",1);var Cl=vl,yl=class extends rt{addResizeBar(e){const t={dragStartPixels:e.dragStartPixels||0,eElement:e.eResizeBar,onDragStart:this.onDragStart.bind(this,e),onDragStop:this.onDragStop.bind(this,e),onDragging:this.onDragging.bind(this,e),includeTouch:!0,stopPropagationForTouch:!0};return this.dragService.addDragSource(t),()=>this.dragService.removeDragSource(t)}onDragStart(e,t){this.dragStartX=t.clientX,this.setResizeIcons();const i=t instanceof MouseEvent&&!0===t.shiftKey;e.onResizeStart(i)}setResizeIcons(){const e=this.ctrlsService.get("gridCtrl");e.setResizeCursor(!0),e.disableUserSelect(!0)}onDragStop(e,t){e.onResizeEnd(this.resizeAmount),this.resetIcons()}resetIcons(){const e=this.ctrlsService.get("gridCtrl");e.setResizeCursor(!1),e.disableUserSelect(!1)}onDragging(e,t){this.resizeAmount=t.clientX-this.dragStartX,e.onResizing(this.resizeAmount)}};g([ue("dragService")],yl.prototype,"dragService",2),g([ue("ctrlsService")],yl.prototype,"ctrlsService",2),yl=g([ce("horizontalResizeService")],yl);var wl=class extends rt{hideActiveMenu(){this.hidePopup&&this.hidePopup()}showMenuAfterMouseEvent(e,t,i){this.showPopup(e,r=>{this.popupService.positionPopupUnderMouseEvent({column:e,type:i,mouseEvent:t,ePopup:r})},i,t.target,this.menuService.isLegacyMenuEnabled())}showMenuAfterButtonClick(e,t,i){let r=-1,n="left";const s=this.menuService.isLegacyMenuEnabled();!s&&this.gos.get("enableRtl")&&(r=1,n="right");let o=s?void 0:4*r,a=s?void 0:4;this.showPopup(e,r=>{this.popupService.positionPopupByComponent({type:i,eventSource:t,ePopup:r,nudgeX:o,nudgeY:a,alignSide:n,keepWithinBounds:!0,position:"under",column:e})},i,t,s)}showPopup(e,t,i,r,n){const s=e?this.createBean(new jo(e,"COLUMN_MENU")):void 0;if(this.activeMenu=s,!(null==s?void 0:s.hasFilter())||!e)throw new Error("AG Grid - unable to show popup filter, filter instantiation failed");const o=document.createElement("div");let a;Ht(o,"presentation"),o.classList.add("ag-menu"),n||o.classList.add("ag-filter-menu"),this.tabListener=this.addManagedListener(o,"keydown",e=>this.trapFocusWithin(e,o)),o.appendChild(null==s?void 0:s.getGui());const l=this.menuService.isColumnMenuAnchoringEnabled()?null!=r?r:this.ctrlsService.getGridBodyCtrl().getGui():void 0,c=this.localeService.getLocaleTextFunc(),u=n&&"columnFilter"!==i?c("ariaLabelColumnMenu","Column Menu"):c("ariaLabelColumnFilter","Column Filter"),h=this.popupService.addPopup({modal:!0,eChild:o,closeOnEsc:!0,closedCallback:t=>{e.setMenuVisible(!1,"contextMenu");const n=t instanceof KeyboardEvent;if(this.tabListener&&(this.tabListener=this.tabListener()),n&&r&&Sr(r)){const e=this.focusService.findTabbableParent(r);e&&e.focus()}null==s||s.afterGuiDetached(),this.destroyBean(this.activeMenu),this.dispatchVisibleChangedEvent(!1,i,e)},positionCallback:()=>t(o),anchorToElement:l,ariaLabel:u});h&&(this.hidePopup=a=h.hideFunc),s.afterInit().then(()=>{t(o),s.afterGuiAttached({container:i,hidePopup:a})}),e.setMenuVisible(!0,"contextMenu"),this.dispatchVisibleChangedEvent(!0,i,e)}trapFocusWithin(e,t){e.key!==Yr.TAB||e.defaultPrevented||this.focusService.findNextFocusableElement(t,!1,e.shiftKey)||(e.preventDefault(),this.focusService.focusInto(t,e.shiftKey))}dispatchVisibleChangedEvent(e,t,i){const r={type:lt.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:!1,key:t,column:null!=i?i:null};this.eventService.dispatchEvent(r)}isMenuEnabled(e){var t;return e.isFilterAllowed()&&(null!=(t=e.getColDef().menuTabs)?t:["filterMenuTab"]).includes("filterMenuTab")}showMenuAfterContextMenuEvent(){}destroy(){this.destroyBean(this.activeMenu),super.destroy()}};g([ue("filterManager")],wl.prototype,"filterManager",2),g([ue("popupService")],wl.prototype,"popupService",2),g([ue("focusService")],wl.prototype,"focusService",2),g([ue("ctrlsService")],wl.prototype,"ctrlsService",2),g([ue("menuService")],wl.prototype,"menuService",2),wl=g([ce("filterMenuFactory")],wl);var Sl=(e=>(e.TAB_GUARD="ag-tab-guard",e.TAB_GUARD_TOP="ag-tab-guard-top",e.TAB_GUARD_BOTTOM="ag-tab-guard-bottom",e))(Sl||{}),bl=class extends rt{constructor(e){super(),this.skipTabGuardFocus=!1,this.forcingFocusOut=!1;const{comp:t,eTopGuard:i,eBottomGuard:r,focusTrapActive:n,forceFocusOutWhenTabGuardsAreEmpty:s,focusInnerElement:o,onFocusIn:a,onFocusOut:l,shouldStopEventPropagation:c,onTabKeyDown:u,handleKeyDown:h,eFocusableElement:d}=e;this.comp=t,this.eTopGuard=i,this.eBottomGuard=r,this.providedFocusInnerElement=o,this.eFocusableElement=d,this.focusTrapActive=!!n,this.forceFocusOutWhenTabGuardsAreEmpty=!!s,this.providedFocusIn=a,this.providedFocusOut=l,this.providedShouldStopEventPropagation=c,this.providedOnTabKeyDown=u,this.providedHandleKeyDown=h}postConstruct(){this.createManagedBean(new _n(this.eFocusableElement,{shouldStopEventPropagation:()=>this.shouldStopEventPropagation(),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e)})),this.activateTabGuards(),[this.eTopGuard,this.eBottomGuard].forEach(e=>this.addManagedListener(e,"focus",this.onFocus.bind(this)))}handleKeyDown(e){this.providedHandleKeyDown&&this.providedHandleKeyDown(e)}tabGuardsAreActive(){return!!this.eTopGuard&&this.eTopGuard.hasAttribute("tabIndex")}shouldStopEventPropagation(){return!!this.providedShouldStopEventPropagation&&this.providedShouldStopEventPropagation()}activateTabGuards(){if(this.forcingFocusOut)return;const e=this.gos.get("tabIndex");this.comp.setTabIndex(e.toString())}deactivateTabGuards(){this.comp.setTabIndex()}onFocus(e){if(this.skipTabGuardFocus)return void(this.skipTabGuardFocus=!1);if(this.forceFocusOutWhenTabGuardsAreEmpty&&0===this.focusService.findFocusableElements(this.eFocusableElement,".ag-tab-guard").length)return void this.findNextElementOutsideAndFocus(e.target===this.eBottomGuard);const t=e.target===this.eBottomGuard;this.providedFocusInnerElement?this.providedFocusInnerElement(t):this.focusInnerElement(t)}findNextElementOutsideAndFocus(e){const t=this.gos.getDocument(),i=this.focusService.findFocusableElements(t.body,null,!0),r=i.indexOf(e?this.eTopGuard:this.eBottomGuard);if(-1===r)return;let n,s;e?(n=0,s=r):(n=r+1,s=i.length);const o=i.slice(n,s),a=this.gos.get("tabIndex");o.sort((e,t)=>{const i=parseInt(e.getAttribute("tabindex")||"0"),r=parseInt(t.getAttribute("tabindex")||"0");return r===a?1:i===a?-1:0===i?1:0===r?-1:i-r}),o[e?o.length-1:0].focus()}onFocusIn(e){this.focusTrapActive||(this.providedFocusIn&&this.providedFocusIn(e),this.deactivateTabGuards())}onFocusOut(e){this.focusTrapActive||(this.providedFocusOut&&this.providedFocusOut(e),this.eFocusableElement.contains(e.relatedTarget)||this.activateTabGuards())}onTabKeyDown(e){if(this.providedOnTabKeyDown)return void this.providedOnTabKeyDown(e);if(this.focusTrapActive)return;if(e.defaultPrevented)return;const t=this.tabGuardsAreActive();t&&this.deactivateTabGuards();const i=this.getNextFocusableElement(e.shiftKey);t&&setTimeout(()=>this.activateTabGuards(),0),i&&(i.focus(),e.preventDefault())}focusInnerElement(e=!1){const t=this.focusService.findFocusableElements(this.eFocusableElement);this.tabGuardsAreActive()&&(t.splice(0,1),t.splice(t.length-1,1)),t.length&&t[e?t.length-1:0].focus({preventScroll:!0})}getNextFocusableElement(e){return this.focusService.findNextFocusableElement(this.eFocusableElement,!1,e)}forceFocusOutOfContainer(e=!1){if(this.forcingFocusOut)return;const t=e?this.eTopGuard:this.eBottomGuard;this.activateTabGuards(),this.skipTabGuardFocus=!0,this.forcingFocusOut=!0,t.focus(),window.setTimeout(()=>{this.forcingFocusOut=!1,this.activateTabGuards()})}isTabGuard(e){return e===this.eTopGuard||e===this.eBottomGuard}};g([ue("focusService")],bl.prototype,"focusService",2),g([ae],bl.prototype,"postConstruct",1);var El=class extends yn{initialiseTabGuard(e){this.eTopGuard=this.createTabGuard("top"),this.eBottomGuard=this.createTabGuard("bottom"),this.eFocusableElement=this.getFocusableElement();const t=[this.eTopGuard,this.eBottomGuard],i={setTabIndex:e=>{t.forEach(t=>null!=e?t.setAttribute("tabindex",e):t.removeAttribute("tabindex"))}};this.addTabGuards(this.eTopGuard,this.eBottomGuard),this.tabGuardCtrl=this.createManagedBean(new bl({comp:i,focusTrapActive:!!e.focusTrapActive,eTopGuard:this.eTopGuard,eBottomGuard:this.eBottomGuard,eFocusableElement:this.eFocusableElement,onFocusIn:e.onFocusIn,onFocusOut:e.onFocusOut,focusInnerElement:e.focusInnerElement,handleKeyDown:e.handleKeyDown,onTabKeyDown:e.onTabKeyDown,shouldStopEventPropagation:e.shouldStopEventPropagation,forceFocusOutWhenTabGuardsAreEmpty:e.forceFocusOutWhenTabGuardsAreEmpty}))}createTabGuard(e){const t=document.createElement("div"),i="top"===e?"ag-tab-guard-top":"ag-tab-guard-bottom";return t.classList.add("ag-tab-guard",i),Ht(t,"presentation"),t}addTabGuards(e,t){this.eFocusableElement.insertAdjacentElement("afterbegin",e),this.eFocusableElement.insertAdjacentElement("beforeend",t)}removeAllChildrenExceptTabGuards(){const e=[this.eTopGuard,this.eBottomGuard];Cr(this.getFocusableElement()),this.addTabGuards(...e)}forceFocusOutOfContainer(e=!1){this.tabGuardCtrl.forceFocusOutOfContainer(e)}appendChild(e,t){Nr(e)||(e=e.getGui());const{eBottomGuard:i}=this;i?i.insertAdjacentElement("beforebegin",e):super.appendChild(e,t)}},Al=class e extends El{constructor(t){super(e.getTemplate(t.cssClass)),this.items=[],this.tabbedItemScrollMap=new Map,this.params=t}postConstruct(){this.setupHeader(),this.params.items&&this.params.items.forEach(e=>this.addItem(e)),this.initialiseTabGuard({onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this),focusInnerElement:this.focusInnerElement.bind(this),focusTrapActive:!0}),this.addDestroyFunc(()=>{var e,t,i;return null==(i=null==(t=null==(e=this.activeItem)?void 0:e.tabbedItem)?void 0:t.afterDetachedCallback)?void 0:i.call(t)})}static getTemplate(e){return`<div class="ag-tabs ${e}">\n            <div ref="eHeader"></div>\n            <div ref="eBody" role="presentation" class="ag-tabs-body ${e?`${e}-body`:""}"></div>\n        </div>`}setupHeader(){const{enableCloseButton:e,cssClass:t}=this.params,i=(e,i)=>{e.classList.add(`ag-tabs-${i}`),t&&e.classList.add(`${t}-${i}`)};e?(this.setupCloseButton(i),this.eTabHeader=this.gos.getDocument().createElement("div"),i(this.eHeader,"header-wrapper"),Ht(this.eHeader,"presentation"),this.eHeader.appendChild(this.eTabHeader)):this.eTabHeader=this.eHeader,Ht(this.eTabHeader,"tablist"),i(this.eTabHeader,"header")}setupCloseButton(e){const t=this.gos.getDocument(),i=t.createElement("button");e(i,"close-button");const r=$r("close",this.gos,void 0,!0);jt(i,this.params.closeButtonAriaLabel),i.appendChild(r),this.addManagedListener(i,"click",()=>{var e,t;return null==(t=(e=this.params).onCloseClicked)?void 0:t.call(e)});const n=t.createElement("div");e(n,"close-button-wrapper"),Ht(n,"presentation"),n.appendChild(i),this.eHeader.appendChild(n),this.eCloseButton=i}handleKeyDown(e){switch(e.key){case Yr.RIGHT:case Yr.LEFT:if(!this.eTabHeader.contains(this.gos.getActiveDomElement()))return;const t=e.key===Yr.RIGHT,i=this.gos.get("enableRtl"),r=this.items.indexOf(this.activeItem),n=t!==i?Math.min(r+1,this.items.length-1):Math.max(r-1,0);if(r===n)return;e.preventDefault();const s=this.items[n];this.showItemWrapper(s),s.eHeaderButton.focus();break;case Yr.UP:case Yr.DOWN:e.stopPropagation()}}onTabKeyDown(e){var t,i,r,n;if(e.defaultPrevented)return;const{focusService:s,eHeader:o,eBody:a,activeItem:l,params:c}=this,{suppressTrapFocus:u,enableCloseButton:h}=c,d=this.gos.getActiveDomElement(),p=e.target,g=e.shiftKey;if(o.contains(d))return e.preventDefault(),void(h&&g&&!(null==(t=this.eCloseButton)?void 0:t.contains(d))?null==(i=this.eCloseButton)||i.focus():u&&g?null==(r=this.focusService.findFocusableElementBeforeTabGuard(this.gos.getDocument().body,p))||r.focus():this.focusBody(e.shiftKey));let f=null;if(s.isTargetUnderManagedComponent(a,p)&&(g&&(f=this.focusService.findFocusableElementBeforeTabGuard(a,p)),f||u||(f=l.eHeaderButton)),!f&&a.contains(d)&&(f=s.findNextFocusableElement(a,!1,g),!f))return e.preventDefault(),void(u&&!g?this.forceFocusOutOfContainer(g):h&&!g?null==(n=this.eCloseButton)||n.focus():this.focusHeader());f&&(e.preventDefault(),f.focus())}focusInnerElement(e){e?this.focusHeader():this.focusBody(!0)}focusHeader(e){this.activeItem.eHeaderButton.focus({preventScroll:e})}focusBody(e){this.focusService.focusInto(this.eBody,e)}setAfterAttachedParams(e){this.afterAttachedParams=e}showFirstItem(){this.items.length>0&&this.showItemWrapper(this.items[0])}addItem(e){const t=document.createElement("span");Ht(t,"tab"),t.setAttribute("tabindex","-1"),t.appendChild(e.title),t.classList.add("ag-tab"),this.eTabHeader.appendChild(t),jt(t,e.titleLabel);const i={tabbedItem:e,eHeaderButton:t};this.items.push(i),t.addEventListener("click",this.showItemWrapper.bind(this,i))}showItem(e){const t=this.items.find(t=>t.tabbedItem===e);t&&this.showItemWrapper(t)}showItemWrapper(e){var t,i,r,n,s,o;const{tabbedItem:a,eHeaderButton:l}=e;null==(i=(t=this.params).onItemClicked)||i.call(t,{item:a}),this.activeItem!==e?(this.lastScrollListener&&(this.lastScrollListener=this.lastScrollListener()),Cr(this.eBody),a.bodyPromise.then(e=>{this.eBody.appendChild(e);const t=!this.focusService.isKeyboardMode();if(this.params.suppressFocusBodyOnOpen||this.focusService.focusInto(this.eBody,!1,t),a.afterAttachedCallback&&a.afterAttachedCallback(this.afterAttachedParams),this.params.keepScrollPosition){const t=a.getScrollableContainer&&a.getScrollableContainer()||e;this.lastScrollListener=this.addManagedListener(t,"scroll",()=>{this.tabbedItemScrollMap.set(a.name,t.scrollTop)});const i=this.tabbedItemScrollMap.get(a.name);void 0!==i&&setTimeout(()=>{t.scrollTop=i},0)}}),this.activeItem&&(this.activeItem.eHeaderButton.classList.remove("ag-tab-selected"),null==(o=(s=this.activeItem.tabbedItem).afterDetachedCallback)||o.call(s)),l.classList.add("ag-tab-selected"),this.activeItem=e):null==(n=(r=this.params).onActiveItemClicked)||n.call(r)}};g([ue("focusService")],Al.prototype,"focusService",2),g([Sn("eHeader")],Al.prototype,"eHeader",2),g([Sn("eBody")],Al.prototype,"eBody",2),g([ae],Al.prototype,"postConstruct",1);var Tl=Al,Ml=class extends rt{constructor(){super(...arguments),this.polyfillFunctions=[]}observeResize(e,t){const i=this.gos.getWindow(),r=()=>{var i,r;let n=null!=(i=null==e?void 0:e.clientWidth)?i:0,s=null!=(r=null==e?void 0:e.clientHeight)?r:0,o=!0;const a=()=>{var i,r;if(o){const o=null!=(i=null==e?void 0:e.clientWidth)?i:0,l=null!=(r=null==e?void 0:e.clientHeight)?r:0;(o!==n||l!==s)&&(n=o,s=l,t()),this.doNextPolyfillTurn(a)}};return a(),()=>o=!1},n=this.gos.get("suppressBrowserResizeObserver");return i.ResizeObserver&&!n?(()=>{const r=new i.ResizeObserver(t);return r.observe(e),()=>r.disconnect()})():this.getFrameworkOverrides().wrapIncoming(()=>r(),"resize-observer")}doNextPolyfillTurn(e){this.polyfillFunctions.push(e),this.schedulePolyfill()}schedulePolyfill(){this.polyfillScheduled||(this.polyfillScheduled=!0,window.setTimeout(()=>{const e=this.polyfillFunctions;this.polyfillScheduled=!1,this.polyfillFunctions=[],e.forEach(e=>e())},50))}};Ml=g([ce("resizeObserverService")],Ml);var Rl=class extends rt{constructor(){super(...arguments),this.createTasksP1={list:[],sorted:!1},this.createTasksP2={list:[],sorted:!1},this.destroyTasks=[],this.ticking=!1,this.scrollGoingDown=!0,this.lastPage=0,this.lastScrollTop=0,this.taskCount=0,this.cancelledTasks=new Set}setScrollTop(e){const t=this.gos.get("pagination");if(this.scrollGoingDown=e>=this.lastScrollTop,t&&0===e){const e=this.paginationProxy.getCurrentPage();e!==this.lastPage&&(this.lastPage=e,this.scrollGoingDown=!0)}this.lastScrollTop=e}init(){this.useAnimationFrame=!this.gos.get("suppressAnimationFrame")}isOn(){return this.useAnimationFrame}verifyAnimationFrameOn(e){!1===this.useAnimationFrame&&console.warn(`AG Grid: AnimationFrameService.${e} called but animation frames are off`)}createTask(e,t,i){this.verifyAnimationFrameOn(i);const r={task:e,index:t,createOrder:++this.taskCount};this.addTaskToList(this[i],r),this.schedule()}cancelTask(e){this.cancelledTasks.add(e)}addTaskToList(e,t){e.list.push(t),e.sorted=!1}sortTaskList(e){if(e.sorted)return;const t=this.scrollGoingDown?1:-1;e.list.sort((e,i)=>e.index!==i.index?t*(i.index-e.index):i.createOrder-e.createOrder),e.sorted=!0}addDestroyTask(e){this.verifyAnimationFrameOn("createTasksP3"),this.destroyTasks.push(e),this.schedule()}executeFrame(e){this.verifyAnimationFrameOn("executeFrame");const t=this.createTasksP1,i=t.list,r=this.createTasksP2,n=r.list,s=this.destroyTasks,o=(new Date).getTime();let a=(new Date).getTime()-o;const l=e<=0,c=this.ctrlsService.getGridBodyCtrl();for(;l||a<e;){if(!c.getScrollFeature().scrollGridIfNeeded()){let e;if(i.length)this.sortTaskList(t),e=i.pop().task;else if(n.length)this.sortTaskList(r),e=n.pop().task;else{if(!s.length){this.cancelledTasks.clear();break}e=s.pop()}this.cancelledTasks.has(e)||e()}a=(new Date).getTime()-o}i.length||n.length||s.length?this.requestFrame():this.stopTicking()}stopTicking(){this.ticking=!1}flushAllFrames(){this.useAnimationFrame&&this.executeFrame(-1)}schedule(){this.useAnimationFrame&&(this.ticking||(this.ticking=!0,this.requestFrame()))}requestFrame(){const e=this.executeFrame.bind(this,60);this.requestAnimationFrame(e)}requestAnimationFrame(e){const t=this.gos.getWindow();t.requestAnimationFrame?t.requestAnimationFrame(e):t.webkitRequestAnimationFrame?t.webkitRequestAnimationFrame(e):t.setTimeout(e,0)}isQueueEmpty(){return!this.ticking}debounce(e){let t=!1;return()=>{this.isOn()?t||(t=!0,this.addDestroyTask(()=>{t=!1,e()})):window.setTimeout(e,0)}}};g([ue("ctrlsService")],Rl.prototype,"ctrlsService",2),g([ue("paginationProxy")],Rl.prototype,"paginationProxy",2),g([ae],Rl.prototype,"init",1),Rl=g([ce("animationFrameService")],Rl);var _l=(e=>(e.EVERYTHING="group",e.FILTER="filter",e.SORT="sort",e.MAP="map",e.AGGREGATE="aggregate",e.FILTER_AGGREGATES="filter_aggregates",e.PIVOT="pivot",e.NOTHING="nothing",e))(_l||{}),Pl=class extends rt{postConstruct(){this.isClientSideRowModel="clientSide"===this.rowModel.getType()}expandRows(e){if(!this.isClientSideRowModel)return;const t=new Set(e);this.rowModel.forEachNode(e=>{e.id&&t.has(e.id)&&(e.expanded=!0)}),this.onGroupExpandedOrCollapsed()}getExpandedRows(){const e=[];return this.rowModel.forEachNode(({expanded:t,id:i})=>{t&&i&&e.push(i)}),e}expandAll(e){this.isClientSideRowModel&&this.rowModel.expandOrCollapseAll(e)}setRowNodeExpanded(e,t,i,r){e&&(i&&e.parent&&-1!==e.parent.level&&this.setRowNodeExpanded(e.parent,t,i,r),e.setExpanded(t,void 0,r))}onGroupExpandedOrCollapsed(){this.isClientSideRowModel&&this.rowModel.refreshModel({step:"map"})}};g([ue("rowModel")],Pl.prototype,"rowModel",2),g([ae],Pl.prototype,"postConstruct",1),Pl=g([ce("expansionService")],Pl);var xl=class extends rt{postConstruct(){var e;this.activeMenuFactory=null!=(e=this.enterpriseMenuFactory)?e:this.filterMenuFactory}showColumnMenu(e){this.showColumnMenuCommon(this.activeMenuFactory,e,"columnMenu")}showFilterMenu(e){const t=this.enterpriseMenuFactory&&this.isLegacyMenuEnabled()?this.enterpriseMenuFactory:this.filterMenuFactory;this.showColumnMenuCommon(t,e,e.containerType,!0)}showHeaderContextMenu(e,t,i){this.activeMenuFactory.showMenuAfterContextMenuEvent(e,t,i)}getContextMenuPosition(e,t){const i=this.getRowCtrl(e),r=this.getCellGui(i,t);if(!r)return i?{x:0,y:i.getRowYPosition()}:{x:0,y:0};const n=r.getBoundingClientRect();return{x:n.x+n.width/2,y:n.y+n.height/2}}showContextMenu(e){var t,i,r;const{column:n,rowNode:s}=e;let{anchorToElement:o,value:a}=e;s&&n&&null==a&&(a=s.getValueFromValueService(n)),null==o&&(o=this.getContextMenuAnchorElement(s,n)),null==(r=this.contextMenuFactory)||r.onContextMenu(null!=(t=e.mouseEvent)?t:null,null!=(i=e.touchEvent)?i:null,null!=s?s:null,null!=n?n:null,a,o)}showColumnChooser(e){var t;null==(t=this.columnChooserFactory)||t.showColumnChooser(e)}hidePopupMenu(){var e;null==(e=this.contextMenuFactory)||e.hideActiveMenu(),this.activeMenuFactory.hideActiveMenu()}hideColumnChooser(){var e;null==(e=this.columnChooserFactory)||e.hideActiveColumnChooser()}isColumnMenuInHeaderEnabled(e){const{suppressMenu:t,suppressHeaderMenuButton:i}=e.getColDef();return!(null!=i?i:t)&&this.activeMenuFactory.isMenuEnabled(e)&&(this.isLegacyMenuEnabled()||!!this.enterpriseMenuFactory)}isFilterMenuInHeaderEnabled(e){return!e.getColDef().suppressHeaderFilterButton&&this.filterManager.isFilterAllowed(e)}isHeaderContextMenuEnabled(e){return!(null==e?void 0:e.getColDef().suppressHeaderContextMenu)&&"new"===this.getColumnMenuType()}isHeaderMenuButtonAlwaysShowEnabled(){return this.isSuppressMenuHide()}isHeaderMenuButtonEnabled(){const e=!this.isSuppressMenuHide();return!(Di()&&e)}isHeaderFilterButtonEnabled(e){return this.isFilterMenuInHeaderEnabled(e)&&!this.isLegacyMenuEnabled()&&!this.isFloatingFilterButtonDisplayed(e)}isFilterMenuItemEnabled(e){return this.filterManager.isFilterAllowed(e)&&!this.isLegacyMenuEnabled()&&!this.isFilterMenuInHeaderEnabled(e)&&!this.isFloatingFilterButtonDisplayed(e)}isColumnMenuAnchoringEnabled(){return!this.isLegacyMenuEnabled()}areAdditionalColumnMenuItemsEnabled(){return"new"===this.getColumnMenuType()}isLegacyMenuEnabled(){return"legacy"===this.getColumnMenuType()}isFloatingFilterButtonEnabled(e){var t;const i=e.getColDef(),r=null==(t=i.floatingFilterComponentParams)?void 0:t.suppressFilterButton;return null!=r&&z("As of v31.1, 'colDef.floatingFilterComponentParams.suppressFilterButton' is deprecated. Use 'colDef.suppressFloatingFilterButton' instead."),null==i.suppressFloatingFilterButton?!r:!i.suppressFloatingFilterButton}getColumnMenuType(){var e;return null!=(e=this.gos.get("columnMenu"))?e:"legacy"}isFloatingFilterButtonDisplayed(e){return!!e.getColDef().floatingFilter&&this.isFloatingFilterButtonEnabled(e)}isSuppressMenuHide(){const e=this.gos.get("suppressMenuHide");return this.isLegacyMenuEnabled()?e:!this.gos.exists("suppressMenuHide")||e}showColumnMenuCommon(e,t,i,r){const{column:n,positionBy:s}=t;if("button"===s){const{buttonElement:s}=t;e.showMenuAfterButtonClick(n,s,i,r)}else if("mouse"===s){const{mouseEvent:s}=t;e.showMenuAfterMouseEvent(n,s,i,r)}else n&&(this.ctrlsService.getGridBodyCtrl().getScrollFeature().ensureColumnVisible(n,"auto"),this.animationFrameService.requestAnimationFrame(()=>{const t=this.ctrlsService.getHeaderRowContainerCtrl(n.getPinned()).getHeaderCtrlForColumn(n);e.showMenuAfterButtonClick(n,t.getAnchorElementForMenu(r),i,!0)}))}getRowCtrl(e){const{rowIndex:t,rowPinned:i}=e||{};if(null!=t)return this.rowRenderer.getRowByPosition({rowIndex:t,rowPinned:i})||void 0}getCellGui(e,t){if(!e||!t)return;const i=e.getCellCtrl(t);return(null==i?void 0:i.getGui())||void 0}getContextMenuAnchorElement(e,t){const i=this.ctrlsService.getGridBodyCtrl().getGridBodyElement(),r=this.getRowCtrl(e);if(!r)return i;return this.getCellGui(r,t)||(r.isFullWidth()?r.getFullWidthElement():i)}};g([ue("filterMenuFactory")],xl.prototype,"filterMenuFactory",2),g([ue("ctrlsService")],xl.prototype,"ctrlsService",2),g([ue("animationFrameService")],xl.prototype,"animationFrameService",2),g([ue("filterManager")],xl.prototype,"filterManager",2),g([ue("rowRenderer")],xl.prototype,"rowRenderer",2),g([he("columnChooserFactory")],xl.prototype,"columnChooserFactory",2),g([he("contextMenuFactory")],xl.prototype,"contextMenuFactory",2),g([he("enterpriseMenuFactory")],xl.prototype,"enterpriseMenuFactory",2),g([ae],xl.prototype,"postConstruct",1),xl=g([ce("menuService")],xl);var Dl=class extends rt{postConstruct(){this.ctrlsService.whenReady(e=>{this.centerRowContainerCtrl=e.center})}getPreferredWidthForColumn(e,t){const i=this.getHeaderCellForColumn(e);if(!i)return-1;const r=this.rowRenderer.getAllCellsForColumn(e);return t||r.push(i),this.addElementsToContainerAndGetWidth(r)}getPreferredWidthForColumnGroup(e){const t=this.getHeaderCellForColumn(e);return t?this.addElementsToContainerAndGetWidth([t]):-1}addElementsToContainerAndGetWidth(e){const t=document.createElement("form");t.style.position="fixed";const i=this.centerRowContainerCtrl.getContainerElement();e.forEach(e=>this.cloneItemIntoDummy(e,t)),i.appendChild(t);const r=t.offsetWidth;return i.removeChild(t),r+this.getAutoSizePadding()}getAutoSizePadding(){return this.gos.get("autoSizePadding")}getHeaderCellForColumn(e){let t=null;return this.ctrlsService.getHeaderRowContainerCtrls().forEach(i=>{const r=i.getHtmlElementForColumnHeader(e);null!=r&&(t=r)}),t}cloneItemIntoDummy(e,t){const i=e.cloneNode(!0);i.style.width="",i.style.position="static",i.style.left="";const r=document.createElement("div"),n=r.classList;["ag-header-cell","ag-header-group-cell"].some(e=>i.classList.contains(e))?(n.add("ag-header","ag-header-row"),r.style.position="static"):n.add("ag-row");let s=e.parentElement;for(;s;){if(["ag-header-row","ag-row"].some(e=>s.classList.contains(e))){for(let e=0;e<s.classList.length;e++){const t=s.classList[e];"ag-row-position-absolute"!=t&&n.add(t)}break}s=s.parentElement}r.appendChild(i),t.appendChild(r)}};g([ue("rowRenderer")],Dl.prototype,"rowRenderer",2),g([ue("ctrlsService")],Dl.prototype,"ctrlsService",2),g([ue("rowCssClassCalculator")],Dl.prototype,"rowCssClassCalculator",2),g([ae],Dl.prototype,"postConstruct",1),Dl=g([ce("autoWidthCalculator")],Dl);var Il=class extends rt{constructor(e,t){super(),this.createRowCon=e,this.destroyRowCtrls=t,this.stickyTopRowCtrls=[],this.stickyBottomRowCtrls=[],this.topContainerHeight=0,this.bottomContainerHeight=0}postConstruct(){this.isClientSide="clientSide"===this.rowModel.getType(),this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl})}getStickyTopRowCtrls(){return this.stickyTopRowCtrls}getStickyBottomRowCtrls(){return this.stickyBottomRowCtrls}getLastPixelOfGroup(e){return this.isClientSide?this.getClientSideLastPixelOfGroup(e):this.getServerSideLastPixelOfGroup(e)}getFirstPixelOfGroup(e){return e.footer?e.sibling.rowTop+e.sibling.rowHeight-1:e.hasChildren()?e.rowTop-1:0}getServerSideLastPixelOfGroup(e){var t,i,r,n;if(this.isClientSide)throw new Error("This func should only be called in server side row model.");if(e.isExpandable()||e.footer){if(e.master)return e.detailNode.rowTop+e.detailNode.rowHeight;if(!e.sibling||1===Math.abs(e.sibling.rowIndex-e.rowIndex)){let s=null==(t=e.childStore)?void 0:t.getStoreBounds();return e.footer&&(s=null==(i=e.sibling.childStore)?void 0:i.getStoreBounds()),(null!=(r=null==s?void 0:s.heightPx)?r:0)+(null!=(n=null==s?void 0:s.topPx)?n:0)}return e.footer?e.rowTop+e.rowHeight:e.sibling.rowTop+e.sibling.rowHeight}return Number.MAX_SAFE_INTEGER}getClientSideLastPixelOfGroup(e){if(!this.isClientSide)throw new Error("This func should only be called in client side row model.");if(e.isExpandable()||e.footer){const t=e.footer&&0===e.rowIndex,i=!e.sibling||1===Math.abs(e.sibling.rowIndex-e.rowIndex);if(t||i){let t=e.footer?e.sibling:e;for(;t.isExpandable()&&t.expanded;)if(t.master)t=t.detailNode;else if(t.childrenAfterSort){if(0===t.childrenAfterSort.length)break;t=_e(t.childrenAfterSort)}return t.rowTop+t.rowHeight}return e.footer?e.rowTop+e.rowHeight:e.sibling.rowTop+e.sibling.rowHeight}return Number.MAX_SAFE_INTEGER}updateStickyRows(e){const t="top"===e;let i=0;if(!this.canRowsBeSticky())return this.refreshNodesAndContainerHeight(e,new Set,i);const r=t?this.rowRenderer.getFirstVisibleVerticalPixel():this.rowRenderer.getLastVisibleVerticalPixel(),n=new Set,s=e=>{if(n.add(e),t){const t=this.getLastPixelOfGroup(e),n=r+i+e.rowHeight;e.stickyRowTop=t<n?i+(t-n):i}else{const t=this.getFirstPixelOfGroup(e),n=r-(i+e.rowHeight);e.stickyRowTop=t>n?i-(t-n):i}i=0,n.forEach(e=>{const t=e.stickyRowTop+e.rowHeight;i<t&&(i=t)})},o=this.areFooterRowsStickySuppressed(),a=this.gos.get("suppressGroupRowsSticky"),l=e=>!!e.displayed&&(e.footer?!0!==o&&(("grand"!==o||-1!==e.level)&&(!("group"===o&&e.level>-1)&&!n.has(e))):!!e.isExpandable()&&(!0!==a&&(!n.has(e)&&e.expanded)));for(let e=0;e<100;e++){let e=r+i;t||(e=r-i);const n=this.rowModel.getRowIndexAtPixel(e),o=this.rowModel.getRow(n);if(null==o)break;const a=this.getStickyAncestors(o).find(e=>(t?e.rowIndex<n:e.rowIndex>n)&&l(e));if(a)s(a);else{if(!(t?o.rowTop<e:o.rowTop+o.rowHeight>e)||!l(o))break;s(o)}}return t||n.forEach(e=>{e.stickyRowTop=i-(e.stickyRowTop+e.rowHeight)}),this.refreshNodesAndContainerHeight(e,n,i)}areFooterRowsStickySuppressed(){const e=this.gos.get("suppressStickyTotalRow");if(!0===e)return!0;const t=!!this.gos.get("groupIncludeFooter")||"group"===e,i=!!this.gos.get("groupIncludeTotalFooter")||"grand"===e;return!(!t||!i)||(i?"grand":!!t&&"group")}canRowsBeSticky(){const e=this.gos.isGroupRowsSticky(),t=this.areFooterRowsStickySuppressed(),i=this.gos.get("suppressGroupRowsSticky");return e&&(!t||!i)}getStickyAncestors(e){const t=[];let i=e.footer?e.sibling:e.parent;for(;i;)i.sibling&&t.push(i.sibling),t.push(i),i=i.parent;return t.reverse()}checkStickyRows(){const e=this.updateStickyRows("top"),t=this.updateStickyRows("bottom");return e||t}destroyStickyCtrls(){this.refreshNodesAndContainerHeight("top",new Set,0),this.refreshNodesAndContainerHeight("bottom",new Set,0)}refreshStickyNode(e){const t=new Set;if(this.stickyTopRowCtrls.some(t=>t.getRowNode()===e)){for(let i=0;i<this.stickyTopRowCtrls.length;i++){const r=this.stickyTopRowCtrls[i].getRowNode();r!==e&&t.add(r)}this.refreshNodesAndContainerHeight("top",t,this.topContainerHeight)&&this.checkStickyRows()}else{for(let i=0;i<this.stickyBottomRowCtrls.length;i++){const r=this.stickyBottomRowCtrls[i].getRowNode();r!==e&&t.add(r)}this.refreshNodesAndContainerHeight("bottom",t,this.bottomContainerHeight)&&this.checkStickyRows()}}refreshNodesAndContainerHeight(e,t,i){const r="top"===e,n=r?this.stickyTopRowCtrls:this.stickyBottomRowCtrls,s={},o=[];for(let e=0;e<n.length;e++){const i=n[e].getRowNode();t.has(i)?o.push(n[e]):(s[i.id]=n[e],i.sticky=!1)}const a=new Set;for(let e=0;e<o.length;e++)a.add(o[e].getRowNode());const l=[];t.forEach(e=>{a.has(e)||(e.sticky=!0,l.push(this.createRowCon(e,!1,!1)))});let c=!!l.length||o.length!==n.length;r?this.topContainerHeight!==i&&(this.topContainerHeight=i,this.gridBodyCtrl.setStickyTopHeight(i),c=!0):this.bottomContainerHeight!==i&&(this.bottomContainerHeight=i,this.gridBodyCtrl.setStickyBottomHeight(i),c=!0),this.destroyRowCtrls(s,!1);const u=[...o,...l];return u.sort((e,t)=>t.getRowNode().rowIndex-e.getRowNode().rowIndex),r||u.reverse(),u.forEach(e=>e.setRowTop(e.getRowNode().stickyRowTop)),!!c&&(r?this.stickyTopRowCtrls=u:this.stickyBottomRowCtrls=u,!0)}};g([ue("rowModel")],Il.prototype,"rowModel",2),g([ue("rowRenderer")],Il.prototype,"rowRenderer",2),g([ue("ctrlsService")],Il.prototype,"ctrlsService",2),g([ae],Il.prototype,"postConstruct",1);var Ll=class extends rt{constructor(){super(...arguments),this.destroyFuncsForColumnListeners=[],this.rowCtrlsByRowIndex={},this.zombieRowCtrls={},this.allRowCtrls=[],this.topRowCtrls=[],this.bottomRowCtrls=[],this.refreshInProgress=!1,this.dataFirstRenderedFired=!1,this.setupRangeSelectionListeners=()=>{const e=()=>{this.getAllCellCtrls().forEach(e=>e.onRangeSelectionChanged())},t=()=>{this.getAllCellCtrls().forEach(e=>e.updateRangeBordersIfRangeCount())},i=()=>{this.eventService.addEventListener(lt.EVENT_RANGE_SELECTION_CHANGED,e),this.eventService.addEventListener(lt.EVENT_COLUMN_MOVED,t),this.eventService.addEventListener(lt.EVENT_COLUMN_PINNED,t),this.eventService.addEventListener(lt.EVENT_COLUMN_VISIBLE,t)},r=()=>{this.eventService.removeEventListener(lt.EVENT_RANGE_SELECTION_CHANGED,e),this.eventService.removeEventListener(lt.EVENT_COLUMN_MOVED,t),this.eventService.removeEventListener(lt.EVENT_COLUMN_PINNED,t),this.eventService.removeEventListener(lt.EVENT_COLUMN_VISIBLE,t)};this.addDestroyFunc(()=>r()),this.addManagedPropertyListener("enableRangeSelection",e=>{e.currentValue?i():r()}),this.gos.get("enableRangeSelection")&&i()}}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl,this.initialise()})}initialise(){if(this.addManagedListener(this.eventService,lt.EVENT_PAGINATION_CHANGED,this.onPageLoaded.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,this.onDisplayedColumnsChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL,this.onBodyScroll.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_BODY_HEIGHT_CHANGED,this.redraw.bind(this)),this.addManagedPropertyListeners(["domLayout","embedFullWidthRows"],()=>this.onDomLayoutChanged()),this.addManagedPropertyListeners(["suppressMaxRenderedRowRestriction","rowBuffer"],()=>this.redraw()),this.addManagedPropertyListeners(["suppressCellFocus","getBusinessKeyForNode","fullWidthCellRenderer","fullWidthCellRendererParams","rowStyle","getRowStyle","rowClass","getRowClass","rowClassRules","suppressStickyTotalRow","groupRowRenderer","groupRowRendererParams","loadingCellRenderer","loadingCellRendererParams","detailCellRenderer","detailCellRendererParams","enableRangeSelection","enableCellTextSelection"],()=>this.redrawRows()),this.gos.isGroupRowsSticky()){const e=this.rowModel.getType();"clientSide"!==e&&"serverSide"!==e||(this.stickyRowFeature=this.createManagedBean(new Il(this.createRowCon.bind(this),this.destroyRowCtrls.bind(this))))}this.registerCellEventListeners(),this.initialiseCache(),this.printLayout=this.gos.isDomLayout("print"),this.embedFullWidthRows=this.printLayout||this.gos.get("embedFullWidthRows"),this.redrawAfterModelUpdate()}initialiseCache(){if(this.gos.get("keepDetailRows")){const e=this.getKeepDetailRowsCount(),t=null!=e?e:3;this.cachedRowCtrls=new Nl(t)}}getKeepDetailRowsCount(){return this.gos.get("keepDetailRowsCount")}getStickyTopRowCtrls(){return this.stickyRowFeature?this.stickyRowFeature.getStickyTopRowCtrls():[]}getStickyBottomRowCtrls(){return this.stickyRowFeature?this.stickyRowFeature.getStickyBottomRowCtrls():[]}updateAllRowCtrls(){const e=N(this.rowCtrlsByRowIndex),t=N(this.zombieRowCtrls),i=this.cachedRowCtrls?this.cachedRowCtrls.getEntries():[];t.length>0||i.length>0?this.allRowCtrls=[...e,...t,...i]:this.allRowCtrls=e}onCellFocusChanged(e){this.getAllCellCtrls().forEach(t=>t.onCellFocused(e)),this.getFullWidthRowCtrls().forEach(t=>t.onFullWidthRowFocused(e))}registerCellEventListeners(){this.addManagedListener(this.eventService,lt.EVENT_CELL_FOCUSED,e=>{this.onCellFocusChanged(e)}),this.addManagedListener(this.eventService,lt.EVENT_CELL_FOCUS_CLEARED,()=>{this.onCellFocusChanged()}),this.addManagedListener(this.eventService,lt.EVENT_FLASH_CELLS,e=>{this.getAllCellCtrls().forEach(t=>t.onFlashCells(e))}),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_HOVER_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onColumnHover())}),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,()=>{this.getAllCellCtrls().forEach(e=>e.onDisplayedColumnsChanged())}),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,()=>{this.printLayout&&this.getAllCellCtrls().forEach(e=>e.onLeftChanged())}),this.setupRangeSelectionListeners(),this.refreshListenersToColumnsForCellComps(),this.addManagedListener(this.eventService,lt.EVENT_GRID_COLUMNS_CHANGED,this.refreshListenersToColumnsForCellComps.bind(this)),this.addDestroyFunc(this.removeGridColumnListeners.bind(this))}removeGridColumnListeners(){this.destroyFuncsForColumnListeners.forEach(e=>e()),this.destroyFuncsForColumnListeners.length=0}refreshListenersToColumnsForCellComps(){this.removeGridColumnListeners(),this.columnModel.getAllGridColumns().forEach(e=>{const t=t=>{this.getAllCellCtrls().forEach(i=>{i.getColumn()===e&&t(i)})},i=()=>{t(e=>e.onLeftChanged())},r=()=>{t(e=>e.onWidthChanged())},n=()=>{t(e=>e.onFirstRightPinnedChanged())},s=()=>{t(e=>e.onLastLeftPinnedChanged())},o=()=>{t(e=>e.onColDefChanged())};e.addEventListener("leftChanged",i),e.addEventListener("widthChanged",r),e.addEventListener("firstRightPinnedChanged",n),e.addEventListener("lastLeftPinnedChanged",s),e.addEventListener("colDefChanged",o),this.destroyFuncsForColumnListeners.push(()=>{e.removeEventListener("leftChanged",i),e.removeEventListener("widthChanged",r),e.removeEventListener("firstRightPinnedChanged",n),e.removeEventListener("lastLeftPinnedChanged",s),e.removeEventListener("colDefChanged",o)})})}onDomLayoutChanged(){const e=this.gos.isDomLayout("print"),t=e||this.gos.get("embedFullWidthRows"),i=t!==this.embedFullWidthRows||this.printLayout!==e;this.printLayout=e,this.embedFullWidthRows=t,i&&this.redrawAfterModelUpdate({domLayoutChanged:!0})}datasourceChanged(){this.firstRenderedRow=0,this.lastRenderedRow=-1;const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e)}onPageLoaded(e){const t={recycleRows:e.keepRenderedRows,animate:e.animate,newData:e.newData,newPage:e.newPage,onlyBody:!0};this.redrawAfterModelUpdate(t)}getAllCellsForColumn(e){const t=[];return this.getAllRowCtrls().forEach(i=>{const r=i.getCellElement(e);r&&t.push(r)}),t}refreshFloatingRowComps(){this.refreshFloatingRows(this.topRowCtrls,this.pinnedRowModel.getPinnedTopRowData()),this.refreshFloatingRows(this.bottomRowCtrls,this.pinnedRowModel.getPinnedBottomRowData())}getTopRowCtrls(){return this.topRowCtrls}getCentreRowCtrls(){return this.allRowCtrls}getBottomRowCtrls(){return this.bottomRowCtrls}refreshFloatingRows(e,t){e.forEach(e=>{e.destroyFirstPass(),e.destroySecondPass()}),e.length=0,t&&t.forEach(t=>{const i=new va(t,this.beans,!1,!1,this.printLayout);e.push(i)})}onPinnedRowDataChanged(){this.redrawAfterModelUpdate({recycleRows:!0})}redrawRow(e,t=!1){var i;if(e.sticky)this.stickyRowFeature.refreshStickyNode(e);else{if(null==(i=this.cachedRowCtrls)?void 0:i.has(e))return void this.cachedRowCtrls.removeRow(e);{const t=t=>{const i=t[e.rowIndex];i&&i.getRowNode()===e&&(i.destroyFirstPass(),i.destroySecondPass(),t[e.rowIndex]=this.createRowCon(e,!1,!1))};switch(e.rowPinned){case"top":t(this.topRowCtrls);break;case"bottom":t(this.bottomRowCtrls);break;default:t(this.rowCtrlsByRowIndex),this.updateAllRowCtrls()}}}t||this.dispatchDisplayedRowsChanged(!1)}redrawRows(e){if(null!=e)return null==e||e.forEach(e=>this.redrawRow(e,!0)),void this.dispatchDisplayedRowsChanged(!1);this.redrawAfterModelUpdate()}getCellToRestoreFocusToAfterRefresh(e){const t=(null==e?void 0:e.suppressKeepFocus)?null:this.focusService.getFocusCellToUseAfterRefresh();if(null==t)return null;const i=this.gos.getActiveDomElement(),r=this.gos.getDomData(i,ga.DOM_DATA_KEY_CELL_CTRL),n=this.gos.getDomData(i,va.DOM_DATA_KEY_ROW_CTRL);return r||n?t:null}redrawAfterModelUpdate(e={}){this.getLockOnRefresh();const t=this.getCellToRestoreFocusToAfterRefresh(e);this.updateContainerHeights(),this.scrollToTopIfNewData(e);const i=!e.domLayoutChanged&&!!e.recycleRows,r=e.animate&&this.gos.isAnimateRows(),n=i?this.getRowsToRecycle():null;i||this.removeAllRowComps(),this.workOutFirstAndLastRowsToRender(),this.stickyRowFeature&&this.stickyRowFeature.checkStickyRows(),this.recycleRows(n,r),this.gridBodyCtrl.updateRowCount(),e.onlyBody||this.refreshFloatingRowComps(),this.dispatchDisplayedRowsChanged(),null!=t&&this.restoreFocusedCell(t),this.releaseLockOnRefresh()}scrollToTopIfNewData(e){const t=e.newData||e.newPage,i=this.gos.get("suppressScrollOnNewData");t&&!i&&this.gridBodyCtrl.getScrollFeature().scrollToTop()}updateContainerHeights(){if(this.printLayout)return void this.rowContainerHeightService.setModelHeight(null);let e=this.paginationProxy.getCurrentPageHeight();0===e&&(e=1),this.rowContainerHeightService.setModelHeight(e)}getLockOnRefresh(){if(this.refreshInProgress)throw new Error("AG Grid: cannot get grid to draw rows when it is in the middle of drawing rows. Your code probably called a grid API method while the grid was in the render stage. To overcome this, put the API call into a timeout, e.g. instead of api.redrawRows(), call setTimeout(function() { api.redrawRows(); }, 0). To see what part of your code that caused the refresh check this stacktrace.");this.refreshInProgress=!0}releaseLockOnRefresh(){this.refreshInProgress=!1}isRefreshInProgress(){return this.refreshInProgress}restoreFocusedCell(e){e&&(this.focusService.setRestoreFocusedCell(e),this.onCellFocusChanged(this.beans.gos.addGridCommonParams({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0,type:"mock"})))}stopEditing(e=!1){this.getAllRowCtrls().forEach(t=>{t.stopEditing(e)})}getAllCellCtrls(){const e=[],t=this.getAllRowCtrls(),i=t.length;for(let r=0;r<i;r++){const i=t[r].getAllCellCtrls(),n=i.length;for(let t=0;t<n;t++)e.push(i[t])}return e}getAllRowCtrls(){const e=this.stickyRowFeature&&this.stickyRowFeature.getStickyTopRowCtrls()||[],t=this.stickyRowFeature&&this.stickyRowFeature.getStickyBottomRowCtrls()||[],i=[...this.topRowCtrls,...this.bottomRowCtrls,...e,...t];for(const e in this.rowCtrlsByRowIndex)i.push(this.rowCtrlsByRowIndex[e]);return i}addRenderedRowListener(e,t,i){const r=this.rowCtrlsByRowIndex[t];r&&r.addEventListener(e,i)}flashCells(e={}){this.getCellCtrls(e.rowNodes,e.columns).forEach(t=>t.flashCell(e))}refreshCells(e={}){const t={forceRefresh:e.force,newData:!1,suppressFlash:e.suppressFlash};this.getCellCtrls(e.rowNodes,e.columns).forEach(e=>e.refreshOrDestroyCell(t)),e.rowNodes&&(this.getRowCtrls(e.rowNodes).forEach(e=>{e.isFullWidth()&&(e.refreshFullWidth()||this.redrawRow(e.getRowNode(),!0))}),this.dispatchDisplayedRowsChanged(!1))}getCellRendererInstances(e){var t;const i=this.getCellCtrls(e.rowNodes,e.columns).map(e=>e.getCellRenderer()).filter(e=>null!=e);if(null==(t=e.columns)?void 0:t.length)return i;const r=[],n=this.mapRowNodes(e.rowNodes);return this.getAllRowCtrls().forEach(e=>{if(n&&!this.isRowInMap(e.getRowNode(),n))return;if(!e.isFullWidth())return;const t=e.getFullWidthCellRenderers();for(let e=0;e<t.length;e++){const i=t[e];null!=i&&r.push(i)}}),[...r,...i]}getCellEditorInstances(e){const t=[];return this.getCellCtrls(e.rowNodes,e.columns).forEach(e=>{const i=e.getCellEditor();i&&t.push(i)}),t}getEditingCells(){const e=[];return this.getAllCellCtrls().forEach(t=>{if(t.isEditing()){const i=t.getCellPosition();e.push(i)}}),e}mapRowNodes(e){if(!e)return;const t={top:{},bottom:{},normal:{}};return e.forEach(e=>{const i=e.id;switch(e.rowPinned){case"top":t.top[i]=e;break;case"bottom":t.bottom[i]=e;break;default:t.normal[i]=e}}),t}isRowInMap(e,t){const i=e.id;switch(e.rowPinned){case"top":return null!=t.top[i];case"bottom":return null!=t.bottom[i];default:return null!=t.normal[i]}}getRowCtrls(e){const t=this.mapRowNodes(e),i=this.getAllRowCtrls();return e&&t?i.filter(e=>{const i=e.getRowNode();return this.isRowInMap(i,t)}):i}getCellCtrls(e,t){let i;C(t)&&(i={},t.forEach(e=>{const t=this.columnModel.getGridColumn(e);C(t)&&(i[t.getId()]=!0)}));const r=[];return this.getRowCtrls(e).forEach(e=>{e.getAllCellCtrls().forEach(e=>{const t=e.getColumn().getId();i&&!i[t]||r.push(e)})}),r}destroy(){this.removeAllRowComps(),super.destroy()}removeAllRowComps(){const e=Object.keys(this.rowCtrlsByRowIndex);this.removeRowCtrls(e),this.stickyRowFeature&&this.stickyRowFeature.destroyStickyCtrls()}getRowsToRecycle(){const e=[];D(this.rowCtrlsByRowIndex,(t,i)=>{null==i.getRowNode().id&&e.push(t)}),this.removeRowCtrls(e);const t={};return D(this.rowCtrlsByRowIndex,(e,i)=>{const r=i.getRowNode();t[r.id]=i}),this.rowCtrlsByRowIndex={},t}removeRowCtrls(e,t=!1){e.forEach(e=>{const i=this.rowCtrlsByRowIndex[e];i&&(i.destroyFirstPass(t),i.destroySecondPass()),delete this.rowCtrlsByRowIndex[e]})}onBodyScroll(e){"vertical"===e.direction&&this.redraw({afterScroll:!0})}redraw(e={}){const{afterScroll:t}=e;let i;this.stickyRowFeature&&Ii()&&(i=this.getCellToRestoreFocusToAfterRefresh()||void 0);const r=this.firstRenderedRow,n=this.lastRenderedRow;this.workOutFirstAndLastRowsToRender();let s=!1;this.stickyRowFeature&&(s=this.stickyRowFeature.checkStickyRows());const o=this.firstRenderedRow!==r||this.lastRenderedRow!==n;if((!t||s||o)&&(this.getLockOnRefresh(),this.recycleRows(null,!1,t),this.releaseLockOnRefresh(),this.dispatchDisplayedRowsChanged(t&&!s),null!=i)){const e=this.getCellToRestoreFocusToAfterRefresh();null!=i&&null==e&&(this.animationFrameService.flushAllFrames(),this.restoreFocusedCell(i))}}removeRowCompsNotToDraw(e,t){const i={};e.forEach(e=>i[e]=!0);const r=Object.keys(this.rowCtrlsByRowIndex).filter(e=>!i[e]);this.removeRowCtrls(r,t)}calculateIndexesToDraw(e){let t=Ui(this.firstRenderedRow,this.lastRenderedRow);const i=(e,i)=>{const r=i.getRowNode().rowIndex;null!=r&&(r<this.firstRenderedRow||r>this.lastRenderedRow)&&this.doNotUnVirtualiseRow(i)&&t.push(r)};D(this.rowCtrlsByRowIndex,i),D(e,i),t.sort((e,t)=>e-t);const r=[];for(let e=0;e<t.length;e++){const i=t[e],n=this.paginationProxy.getRow(i);n&&!n.sticky&&r.push(i)}return r}recycleRows(e,t=!1,i=!1){const r=this.calculateIndexesToDraw(e);(this.printLayout||i)&&(t=!1),this.removeRowCompsNotToDraw(r,!t);const n=[];r.forEach(r=>{const s=this.createOrUpdateRowCtrl(r,e,t,i);C(s)&&n.push(s)}),e&&(!i||this.gos.get("suppressAnimationFrame")||this.printLayout?this.destroyRowCtrls(e,t):this.beans.animationFrameService.addDestroyTask(()=>{this.destroyRowCtrls(e,t),this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()})),this.updateAllRowCtrls()}dispatchDisplayedRowsChanged(e=!1){const t={type:lt.EVENT_DISPLAYED_ROWS_CHANGED,afterScroll:e};this.eventService.dispatchEvent(t)}onDisplayedColumnsChanged(){const e=this.columnModel.isPinningLeft(),t=this.columnModel.isPinningRight();(this.pinningLeft!==e||t!==this.pinningRight)&&(this.pinningLeft=e,this.pinningRight=t,this.embedFullWidthRows&&this.redrawFullWidthEmbeddedRows())}redrawFullWidthEmbeddedRows(){const e=[];this.getFullWidthRowCtrls().forEach(t=>{const i=t.getRowNode().rowIndex;e.push(i.toString())}),this.refreshFloatingRowComps(),this.removeRowCtrls(e),this.redraw({afterScroll:!0})}getFullWidthRowCtrls(e){const t=this.mapRowNodes(e);return this.getAllRowCtrls().filter(e=>{if(!e.isFullWidth())return!1;const i=e.getRowNode();return!(null!=t&&!this.isRowInMap(i,t))})}createOrUpdateRowCtrl(e,t,i,r){let n,s=this.rowCtrlsByRowIndex[e];if(s||(n=this.paginationProxy.getRow(e),C(n)&&C(t)&&t[n.id]&&n.alreadyRendered&&(s=t[n.id],t[n.id]=null)),!s){if(n||(n=this.paginationProxy.getRow(e)),!C(n))return;s=this.createRowCon(n,i,r)}return n&&(n.alreadyRendered=!0),this.rowCtrlsByRowIndex[e]=s,s}destroyRowCtrls(e,t){const i=[];D(e,(e,r)=>{r&&(this.cachedRowCtrls&&r.isCacheable()?this.cachedRowCtrls.addRow(r):(r.destroyFirstPass(!t),t?(this.zombieRowCtrls[r.getInstanceId()]=r,i.push(()=>{r.destroySecondPass(),delete this.zombieRowCtrls[r.getInstanceId()]})):r.destroySecondPass()))}),t&&(i.push(()=>{this.updateAllRowCtrls(),this.dispatchDisplayedRowsChanged()}),K(i))}getRowBuffer(){return this.gos.get("rowBuffer")}getRowBufferInPixels(){return this.getRowBuffer()*this.gos.getRowHeightAsNumber()}workOutFirstAndLastRowsToRender(){let e,t;if(this.rowContainerHeightService.updateOffset(),this.paginationProxy.isRowsToRender())if(this.printLayout)this.environment.refreshRowHeightVariable(),e=this.paginationProxy.getPageFirstRow(),t=this.paginationProxy.getPageLastRow();else{const i=this.getRowBufferInPixels(),r=this.ctrlsService.getGridBodyCtrl(),n=this.gos.get("suppressRowVirtualisation");let s,o,a=!1;do{const e=this.paginationProxy.getPixelOffset(),{pageFirstPixel:t,pageLastPixel:l}=this.paginationProxy.getCurrentPagePixelRange(),c=this.rowContainerHeightService.getDivStretchOffset(),u=r.getScrollFeature().getVScrollPosition(),h=u.top,d=u.bottom;n?(s=t+c,o=l+c):(s=Math.max(h+e-i,t)+c,o=Math.min(d+e+i,l)+c),this.firstVisibleVPixel=Math.max(h+e,t)+c,this.lastVisibleVPixel=Math.min(d+e,l)+c,a=this.ensureAllRowsInRangeHaveHeightsCalculated(s,o)}while(a);let l=this.paginationProxy.getRowIndexAtPixel(s),c=this.paginationProxy.getRowIndexAtPixel(o);const u=this.paginationProxy.getPageFirstRow(),h=this.paginationProxy.getPageLastRow();l<u&&(l=u),c>h&&(c=h),e=l,t=c}else e=0,t=-1;const i=this.gos.isDomLayout("normal"),r=this.gos.get("suppressMaxRenderedRowRestriction"),n=Math.max(this.getRowBuffer(),500);i&&!r&&t-e>n&&(t=e+n);const s=e!==this.firstRenderedRow,o=t!==this.lastRenderedRow;if(s||o){this.firstRenderedRow=e,this.lastRenderedRow=t;const i={type:lt.EVENT_VIEWPORT_CHANGED,firstRow:e,lastRow:t};this.eventService.dispatchEvent(i)}}dispatchFirstDataRenderedEvent(){if(this.dataFirstRenderedFired)return;this.dataFirstRenderedFired=!0;const e={type:lt.EVENT_FIRST_DATA_RENDERED,firstRow:this.firstRenderedRow,lastRow:this.lastRenderedRow};window.requestAnimationFrame(()=>{this.beans.eventService.dispatchEvent(e)})}ensureAllRowsInRangeHaveHeightsCalculated(e,t){const i=this.paginationProxy.ensureRowHeightsValid(e,t,-1,-1);return i&&this.updateContainerHeights(),i}getFirstVisibleVerticalPixel(){return this.firstVisibleVPixel}getLastVisibleVerticalPixel(){return this.lastVisibleVPixel}getFirstVirtualRenderedRow(){return this.firstRenderedRow}getLastVirtualRenderedRow(){return this.lastRenderedRow}doNotUnVirtualiseRow(e){const t=!1,i=e.getRowNode(),r=this.focusService.isRowNodeFocused(i),n=e.isEditing(),s=i.detail;return(r||n||s)&&!!this.paginationProxy.isRowPresent(i)||t}createRowCon(e,t,i){const r=this.cachedRowCtrls?this.cachedRowCtrls.getRow(e):null;if(r)return r;const n=this.gos.get("suppressAnimationFrame"),s=i&&!n&&!this.printLayout;return new va(e,this.beans,t,s,this.printLayout)}getRenderedNodes(){const e=this.rowCtrlsByRowIndex;return Object.values(e).map(e=>e.getRowNode())}getRowByPosition(e){let t;const{rowIndex:i}=e;switch(e.rowPinned){case"top":t=this.topRowCtrls[i];break;case"bottom":t=this.bottomRowCtrls[i];break;default:t=this.rowCtrlsByRowIndex[i],t||(t=this.getStickyTopRowCtrls().find(e=>e.getRowNode().rowIndex===i)||null,t||(t=this.getStickyBottomRowCtrls().find(e=>e.getRowNode().rowIndex===i)||null))}return t}isRangeInRenderedViewport(e,t){if(null==e||null==t)return!1;const i=e>this.lastRenderedRow;return!(t<this.firstRenderedRow||i)}};g([ue("animationFrameService")],Ll.prototype,"animationFrameService",2),g([ue("paginationProxy")],Ll.prototype,"paginationProxy",2),g([ue("columnModel")],Ll.prototype,"columnModel",2),g([ue("pinnedRowModel")],Ll.prototype,"pinnedRowModel",2),g([ue("rowModel")],Ll.prototype,"rowModel",2),g([ue("focusService")],Ll.prototype,"focusService",2),g([ue("beans")],Ll.prototype,"beans",2),g([ue("rowContainerHeightService")],Ll.prototype,"rowContainerHeightService",2),g([ue("ctrlsService")],Ll.prototype,"ctrlsService",2),g([ae],Ll.prototype,"postConstruct",1),Ll=g([ce("rowRenderer")],Ll);var Nl=class{constructor(e){this.entriesMap={},this.entriesList=[],this.maxCount=e}addRow(e){if(this.entriesMap[e.getRowNode().id]=e,this.entriesList.push(e),e.setCached(!0),this.entriesList.length>this.maxCount){const e=this.entriesList[0];e.destroyFirstPass(),e.destroySecondPass(),this.removeFromCache(e)}}getRow(e){if(null==e||null==e.id)return null;const t=this.entriesMap[e.id];return t?(this.removeFromCache(t),t.setCached(!1),t.getRowNode()!=e?null:t):null}has(e){return null!=this.entriesMap[e.id]}removeRow(e){const t=e.id,i=this.entriesMap[t];delete this.entriesMap[t],Ne(this.entriesList,i)}removeFromCache(e){const t=e.getRowNode().id;delete this.entriesMap[t],Ne(this.entriesList,e)}getEntries(){return this.entriesList}},Ol=class extends rt{init(){this.setPinnedTopRowData(),this.setPinnedBottomRowData(),this.addManagedPropertyListener("pinnedTopRowData",()=>this.setPinnedTopRowData()),this.addManagedPropertyListener("pinnedBottomRowData",()=>this.setPinnedBottomRowData())}isEmpty(e){return w("top"===e?this.pinnedTopRows:this.pinnedBottomRows)}isRowsToRender(e){return!this.isEmpty(e)}getRowAtPixel(e,t){const i="top"===t?this.pinnedTopRows:this.pinnedBottomRows;if(w(i))return 0;for(let t=0;t<i.length;t++){const r=i[t];if(r.rowTop+r.rowHeight-1>=e)return t}return i.length-1}setPinnedTopRowData(){const e=this.gos.get("pinnedTopRowData");this.pinnedTopRows=this.createNodesFromData(e,!0);const t={type:lt.EVENT_PINNED_ROW_DATA_CHANGED};this.eventService.dispatchEvent(t)}setPinnedBottomRowData(){const e=this.gos.get("pinnedBottomRowData");this.pinnedBottomRows=this.createNodesFromData(e,!1);const t={type:lt.EVENT_PINNED_ROW_DATA_CHANGED};this.eventService.dispatchEvent(t)}createNodesFromData(e,t){const i=[];if(e){let r=0;e.forEach((e,n)=>{const s=new Ls(this.beans);s.data=e;const o=t?Ls.ID_PREFIX_TOP_PINNED:Ls.ID_PREFIX_BOTTOM_PINNED;s.id=o+n,s.rowPinned=t?"top":"bottom",s.setRowTop(r),s.setRowHeight(this.gos.getRowHeightForNode(s).height),s.setRowIndex(n),r+=s.rowHeight,i.push(s)})}return i}getPinnedTopRowData(){return this.pinnedTopRows}getPinnedBottomRowData(){return this.pinnedBottomRows}getPinnedTopTotalHeight(){return this.getTotalHeight(this.pinnedTopRows)}getPinnedTopRowCount(){return this.pinnedTopRows?this.pinnedTopRows.length:0}getPinnedBottomRowCount(){return this.pinnedBottomRows?this.pinnedBottomRows.length:0}getPinnedTopRow(e){return this.pinnedTopRows[e]}getPinnedBottomRow(e){return this.pinnedBottomRows[e]}forEachPinnedTopRow(e){w(this.pinnedTopRows)||this.pinnedTopRows.forEach(e)}forEachPinnedBottomRow(e){w(this.pinnedBottomRows)||this.pinnedBottomRows.forEach(e)}getPinnedBottomTotalHeight(){return this.getTotalHeight(this.pinnedBottomRows)}getTotalHeight(e){if(!e||0===e.length)return 0;const t=_e(e);return t.rowTop+t.rowHeight}};g([ue("beans")],Ol.prototype,"beans",2),g([ae],Ol.prototype,"init",1),Ol=g([ce("pinnedRowModel")],Ol);var Fl=(e=>(e.Applied="Applied",e.StoreNotFound="StoreNotFound",e.StoreLoading="StoreLoading",e.StoreWaitingToLoad="StoreWaitingToLoad",e.StoreLoadingFailed="StoreLoadingFailed",e.StoreWrongType="StoreWrongType",e.Cancelled="Cancelled",e.StoreNotStarted="StoreNotStarted",e))(Fl||{}),kl=class{constructor(e,t){this.active=!0,this.nodeIdsToColumns={},this.mapToItems={},this.keepingColumns=e,this.pathRoot={rowNode:t,children:null},this.mapToItems[t.id]=this.pathRoot}setInactive(){this.active=!1}isActive(){return this.active}depthFirstSearchChangedPath(e,t){if(e.children)for(let i=0;i<e.children.length;i++)this.depthFirstSearchChangedPath(e.children[i],t);t(e.rowNode)}depthFirstSearchEverything(e,t,i){if(e.childrenAfterGroup)for(let r=0;r<e.childrenAfterGroup.length;r++){const n=e.childrenAfterGroup[r];n.childrenAfterGroup?this.depthFirstSearchEverything(e.childrenAfterGroup[r],t,i):i&&t(n)}t(e)}forEachChangedNodeDepthFirst(e,t=!1,i=!1){this.active&&!i?this.depthFirstSearchChangedPath(this.pathRoot,e):this.depthFirstSearchEverything(this.pathRoot.rowNode,e,t)}executeFromRootNode(e){e(this.pathRoot.rowNode)}createPathItems(e){let t=e,i=0;for(;!this.mapToItems[t.id];){const e={rowNode:t,children:null};this.mapToItems[t.id]=e,i++,t=t.parent}return i}populateColumnsMap(e,t){if(!this.keepingColumns||!t)return;let i=e;for(;i;)this.nodeIdsToColumns[i.id]||(this.nodeIdsToColumns[i.id]={}),t.forEach(e=>this.nodeIdsToColumns[i.id][e.getId()]=!0),i=i.parent}linkPathItems(e,t){let i=e;for(let e=0;e<t;e++){const e=this.mapToItems[i.id],t=this.mapToItems[i.parent.id];t.children||(t.children=[]),t.children.push(e),i=i.parent}}addParentNode(e,t){if(!e||e.isRowPinned())return;const i=this.createPathItems(e);this.linkPathItems(e,i),this.populateColumnsMap(e,t)}canSkip(e){return this.active&&!this.mapToItems[e.id]}getValueColumnsForNode(e,t){if(!this.keepingColumns)return t;const i=this.nodeIdsToColumns[e.id];return t.filter(e=>i[e.getId()])}getNotValueColumnsForNode(e,t){if(!this.keepingColumns)return null;const i=this.nodeIdsToColumns[e.id];return t.filter(e=>!i[e.getId()])}},Gl=class e extends rt{constructor(t){super(),this.state=e.STATE_WAITING_TO_LOAD,this.version=0,this.id=t}getId(){return this.id}load(){this.state=e.STATE_LOADING,this.loadFromDatasource()}getVersion(){return this.version}setStateWaitingToLoad(){this.version++,this.state=e.STATE_WAITING_TO_LOAD}getState(){return this.state}pageLoadFailed(t){this.isRequestMostRecentAndLive(t)&&(this.state=e.STATE_FAILED,this.processServerFail()),this.dispatchLoadCompleted(!1)}success(e,t){this.successCommon(e,t)}pageLoaded(e,t,i){this.successCommon(e,{rowData:t,rowCount:i})}isRequestMostRecentAndLive(e){const t=e===this.version,i=this.isAlive();return t&&i}successCommon(t,i){this.dispatchLoadCompleted(),this.isRequestMostRecentAndLive(t)&&(this.state=e.STATE_LOADED,this.processServerResult(i))}dispatchLoadCompleted(t=!0){const i={type:e.EVENT_LOAD_COMPLETE,success:t,block:this};this.dispatchEvent(i)}};Gl.EVENT_LOAD_COMPLETE="loadComplete",Gl.STATE_WAITING_TO_LOAD="needsLoading",Gl.STATE_LOADING="loading",Gl.STATE_LOADED="loaded",Gl.STATE_FAILED="failed";var Vl=Gl,Hl=class extends rt{constructor(){super(...arguments),this.activeBlockLoadsCount=0,this.blocks=[],this.active=!0}postConstruct(){this.maxConcurrentRequests=this.getMaxConcurrentDatasourceRequests();const e=this.gos.get("blockLoadDebounceMillis");e&&e>0&&(this.checkBlockToLoadDebounce=ln.debounce(this.performCheckBlocksToLoad.bind(this),e))}setBeans(e){this.logger=e.create("RowNodeBlockLoader")}getMaxConcurrentDatasourceRequests(){const e=this.gos.get("maxConcurrentDatasourceRequests");return null==e?2:e<=0?void 0:e}addBlock(e){this.blocks.push(e),e.addEventListener(Vl.EVENT_LOAD_COMPLETE,this.loadComplete.bind(this)),this.checkBlockToLoad()}removeBlock(e){ln.removeFromArray(this.blocks,e)}destroy(){super.destroy(),this.active=!1}loadComplete(){this.activeBlockLoadsCount--,this.checkBlockToLoad(),this.dispatchEvent({type:Hl.BLOCK_LOADED_EVENT}),0==this.activeBlockLoadsCount&&this.dispatchEvent({type:Hl.BLOCK_LOADER_FINISHED_EVENT})}checkBlockToLoad(){this.checkBlockToLoadDebounce?this.checkBlockToLoadDebounce():this.performCheckBlocksToLoad()}performCheckBlocksToLoad(){if(!this.active)return;if(this.printCacheStatus(),null!=this.maxConcurrentRequests&&this.activeBlockLoadsCount>=this.maxConcurrentRequests)return void this.logger.log("checkBlockToLoad: max loads exceeded");const e=this.getAvailableLoadingCount(),t=this.blocks.filter(e=>e.getState()===Vl.STATE_WAITING_TO_LOAD).slice(0,e);this.registerLoads(t.length),t.forEach(e=>e.load()),this.printCacheStatus()}getBlockState(){if(this.gos.isRowModelType("serverSide"))return this.rowModel.getBlockStates();const e={};return this.blocks.forEach(t=>{const{id:i,state:r}=t.getBlockStateJson();e[i]=r}),e}printCacheStatus(){this.logger.isLogging()&&this.logger.log(`printCacheStatus: activePageLoadsCount = ${this.activeBlockLoadsCount}, blocks = ${JSON.stringify(this.getBlockState())}`)}isLoading(){return this.activeBlockLoadsCount>0}registerLoads(e){this.activeBlockLoadsCount+=e}getAvailableLoadingCount(){return void 0!==this.maxConcurrentRequests?this.maxConcurrentRequests-this.activeBlockLoadsCount:void 0}};Hl.BLOCK_LOADED_EVENT="blockLoaded",Hl.BLOCK_LOADER_FINISHED_EVENT="blockLoaderFinished",g([ue("rowModel")],Hl.prototype,"rowModel",2),g([ae],Hl.prototype,"postConstruct",1),g([f(0,pe("loggerFactory"))],Hl.prototype,"setBeans",1),Hl=g([ce("rowNodeBlockLoader")],Hl);var Bl=class extends rt{constructor(){super(...arguments),this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=0,this.pixelOffset=0,this.masterRowCount=0}postConstruct(){this.active=this.gos.get("pagination"),this.pageSizeFromGridOptions=this.gos.get("paginationPageSize"),this.paginateChildRows=this.isPaginateChildRows(),this.addManagedListener(this.eventService,lt.EVENT_MODEL_UPDATED,this.onModelUpdated.bind(this)),this.addManagedPropertyListener("pagination",this.onPaginationGridOptionChanged.bind(this)),this.addManagedPropertyListener("paginationPageSize",this.onPageSizeGridOptionChanged.bind(this)),this.onModelUpdated()}ensureRowHeightsValid(e,t,i,r){const n=this.rowModel.ensureRowHeightsValid(e,t,this.getPageFirstRow(),this.getPageLastRow());return n&&this.calculatePages(),n}isPaginateChildRows(){return!(!this.gos.get("groupRemoveSingleChildren")&&!this.gos.get("groupRemoveLowestSingleChildren"))||this.gos.get("paginateChildRows")}onModelUpdated(e){this.calculatePages();const t={type:lt.EVENT_PAGINATION_CHANGED,animate:!!e&&e.animate,newData:!!e&&e.newData,newPage:!!e&&e.newPage,newPageSize:!!e&&e.newPageSize,keepRenderedRows:!!e&&e.keepRenderedRows};this.eventService.dispatchEvent(t)}onPaginationGridOptionChanged(){this.active=this.gos.get("pagination"),this.calculatePages();const e={type:lt.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!1,keepRenderedRows:!0};this.eventService.dispatchEvent(e)}onPageSizeGridOptionChanged(){this.setPageSize(this.gos.get("paginationPageSize"),"gridOptions")}goToPage(e){if(!this.active||this.currentPage===e||"number"!=typeof this.currentPage)return;this.currentPage=e,this.calculatePages();const t={type:lt.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!0,newPageSize:!1,keepRenderedRows:!1};this.eventService.dispatchEvent(t)}getPixelOffset(){return this.pixelOffset}getRow(e){return this.rowModel.getRow(e)}getRowNode(e){return this.rowModel.getRowNode(e)}getRowIndexAtPixel(e){return this.rowModel.getRowIndexAtPixel(e)}getCurrentPageHeight(){return y(this.topRowBounds)||y(this.bottomRowBounds)?0:Math.max(this.bottomRowBounds.rowTop+this.bottomRowBounds.rowHeight-this.topRowBounds.rowTop,0)}getCurrentPagePixelRange(){return{pageFirstPixel:this.topRowBounds?this.topRowBounds.rowTop:0,pageLastPixel:this.bottomRowBounds?this.bottomRowBounds.rowTop+this.bottomRowBounds.rowHeight:0}}isRowPresent(e){return!!this.rowModel.isRowPresent(e)&&(e.rowIndex>=this.topDisplayedRowIndex&&e.rowIndex<=this.bottomDisplayedRowIndex)}isEmpty(){return this.rowModel.isEmpty()}isRowsToRender(){return this.rowModel.isRowsToRender()}forEachNode(e){return this.rowModel.forEachNode(e)}forEachNodeOnPage(e){const t=this.getPageFirstRow(),i=this.getPageLastRow();for(let r=t;r<=i;r++){const t=this.getRow(r);t&&e(t)}}getType(){return this.rowModel.getType()}getRowBounds(e){const t=this.rowModel.getRowBounds(e);return t.rowIndex=e,t}getPageFirstRow(){return this.topRowBounds?this.topRowBounds.rowIndex:-1}getPageLastRow(){return this.bottomRowBounds?this.bottomRowBounds.rowIndex:-1}getRowCount(){return this.rowModel.getRowCount()}getPageForIndex(e){return Math.floor(e/this.pageSize)}goToPageWithIndex(e){if(!this.active)return;const t=this.getPageForIndex(e);this.goToPage(t)}isRowInPage(e){return!this.active||this.getPageForIndex(e.rowIndex)===this.currentPage}isLastPageFound(){return this.rowModel.isLastRowIndexKnown()}getCurrentPage(){return this.currentPage}goToNextPage(){this.goToPage(this.currentPage+1)}goToPreviousPage(){this.goToPage(this.currentPage-1)}goToFirstPage(){this.goToPage(0)}goToLastPage(){const e=this.rowModel.getRowCount(),t=Math.floor(e/this.pageSize);this.goToPage(t)}getPageSize(){return this.pageSize}getTotalPages(){return this.totalPages}setPage(e){this.currentPage=e}get pageSize(){return C(this.pageSizeAutoCalculated)?this.pageSizeAutoCalculated:C(this.pageSizeFromPageSizeSelector)?this.pageSizeFromPageSizeSelector:C(this.pageSizeFromInitialState)?this.pageSizeFromInitialState:C(this.pageSizeFromGridOptions)?this.pageSizeFromGridOptions:this.defaultPageSize}unsetAutoCalculatedPageSize(){if(void 0===this.pageSizeAutoCalculated)return;const e=this.pageSizeAutoCalculated;if(this.pageSizeAutoCalculated=void 0,this.pageSize===e)return;this.calculatePages();const t={type:lt.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!0,keepRenderedRows:!1};this.eventService.dispatchEvent(t)}setPageSize(e,t){const i=this.pageSize;switch(t){case"autoCalculated":this.pageSizeAutoCalculated=e;break;case"pageSizeSelector":this.pageSizeFromPageSizeSelector=e,0!==this.currentPage&&this.goToFirstPage();break;case"initialState":this.pageSizeFromInitialState=e;break;case"gridOptions":this.pageSizeFromGridOptions=e,this.pageSizeFromInitialState=void 0,this.pageSizeFromPageSizeSelector=void 0,0!==this.currentPage&&this.goToFirstPage()}if(i!==this.pageSize){this.calculatePages();const e={type:lt.EVENT_PAGINATION_CHANGED,animate:!1,newData:!1,newPage:!1,newPageSize:!0,keepRenderedRows:!0};this.eventService.dispatchEvent(e)}}calculatePages(){this.active?this.paginateChildRows?this.calculatePagesAllRows():this.calculatePagesMasterRowsOnly():this.calculatedPagesNotActive(),this.topRowBounds=this.rowModel.getRowBounds(this.topDisplayedRowIndex),this.topRowBounds&&(this.topRowBounds.rowIndex=this.topDisplayedRowIndex),this.bottomRowBounds=this.rowModel.getRowBounds(this.bottomDisplayedRowIndex),this.bottomRowBounds&&(this.bottomRowBounds.rowIndex=this.bottomDisplayedRowIndex),this.setPixelOffset(C(this.topRowBounds)?this.topRowBounds.rowTop:0)}setPixelOffset(e){this.pixelOffset!==e&&(this.pixelOffset=e,this.eventService.dispatchEvent({type:lt.EVENT_PAGINATION_PIXEL_OFFSET_CHANGED}))}setZeroRows(){this.masterRowCount=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=-1,this.currentPage=0,this.totalPages=0}adjustCurrentPageIfInvalid(){this.currentPage>=this.totalPages&&(this.currentPage=this.totalPages-1),(!isFinite(this.currentPage)||isNaN(this.currentPage)||this.currentPage<0)&&(this.currentPage=0)}calculatePagesMasterRowsOnly(){if(this.masterRowCount=this.rowModel.getTopLevelRowCount(),this.masterRowCount<=0)return void this.setZeroRows();const e=this.masterRowCount-1;this.totalPages=Math.floor(e/this.pageSize)+1,this.adjustCurrentPageIfInvalid();const t=this.pageSize*this.currentPage;let i=this.pageSize*(this.currentPage+1)-1;if(i>e&&(i=e),this.topDisplayedRowIndex=this.rowModel.getTopLevelRowDisplayedIndex(t),i===e)this.bottomDisplayedRowIndex=this.rowModel.getRowCount()-1;else{const e=this.rowModel.getTopLevelRowDisplayedIndex(i+1);this.bottomDisplayedRowIndex=e-1}}getMasterRowCount(){return this.masterRowCount}calculatePagesAllRows(){if(this.masterRowCount=this.rowModel.getRowCount(),0===this.masterRowCount)return void this.setZeroRows();const e=this.masterRowCount-1;this.totalPages=Math.floor(e/this.pageSize)+1,this.adjustCurrentPageIfInvalid(),this.topDisplayedRowIndex=this.pageSize*this.currentPage,this.bottomDisplayedRowIndex=this.pageSize*(this.currentPage+1)-1,this.bottomDisplayedRowIndex>e&&(this.bottomDisplayedRowIndex=e)}calculatedPagesNotActive(){this.setPageSize(void 0,"autoCalculated"),this.totalPages=1,this.currentPage=0,this.topDisplayedRowIndex=0,this.bottomDisplayedRowIndex=this.rowModel.getRowCount()-1}};g([ue("rowModel")],Bl.prototype,"rowModel",2),g([ae],Bl.prototype,"postConstruct",1),Bl=g([ce("paginationProxy")],Bl);var zl=class extends rt{processAllCellClasses(e,t,i,r){this.processClassRules(void 0,e.cellClassRules,t,i,r),this.processStaticCellClasses(e,t,i)}processClassRules(e,t,i,r,n){if(null==t&&null==e)return;const s={},o={},a=(e,t)=>{e.split(" ").forEach(e=>{""!=e.trim()&&t(e)})};if(t){const e=Object.keys(t);for(let r=0;r<e.length;r++){const n=e[r],l=t[n];let c;"string"==typeof l?c=this.expressionService.evaluate(l,i):"function"==typeof l&&(c=l(i)),a(n,e=>{c?s[e]=!0:o[e]=!0})}}e&&n&&Object.keys(e).forEach(e=>a(e,e=>{s[e]||(o[e]=!0)})),n&&Object.keys(o).forEach(n),Object.keys(s).forEach(r)}getStaticCellClasses(e,t){const{cellClass:i}=e;if(!i)return[];let r;return r="function"==typeof i?i(t):i,"string"==typeof r&&(r=[r]),r||[]}processStaticCellClasses(e,t,i){this.getStaticCellClasses(e,t).forEach(e=>{i(e)})}};g([ue("expressionService")],zl.prototype,"expressionService",2),zl=g([ce("stylingService")],zl);var Ul=class extends zn{constructor(e){super(e,"ag-toggle-button")}setValue(e,t){return super.setValue(e,t),this.addOrRemoveCssClass("ag-selected",this.getValue()),this}},Wl=class extends Bn{constructor(e){super(e,"ag-text-area",null,"textarea")}setValue(e,t){const i=super.setValue(e,t);return this.eInput.value=e,i}setCols(e){return this.eInput.cols=e,this}setRows(e){return this.eInput.rows=e,this}},jl=class extends ts{constructor(e){super(e,"ag-date-field","date")}postConstruct(){super.postConstruct(),this.addManagedListener(this.eInput,"wheel",this.onWheel.bind(this));const e=Mi();this.addManagedListener(this.eInput,"mousedown",()=>{this.isDisabled()||e||this.eInput.focus()}),this.eInput.step="any"}onWheel(e){this.gos.getActiveDomElement()===this.eInput&&e.preventDefault()}setMin(e){var t;const i=e instanceof Date?null!=(t=Yi(null!=e?e:null,!1))?t:void 0:e;return this.min===i||(this.min=i,kr(this.eInput,"min",i)),this}setMax(e){var t;const i=e instanceof Date?null!=(t=Yi(null!=e?e:null,!1))?t:void 0:e;return this.max===i||(this.max=i,kr(this.eInput,"max",i)),this}setStep(e){return this.step===e||(this.step=e,kr(this.eInput,"step",e)),this}getDate(){var e;if(this.eInput.validity.valid)return null!=(e=Zi(this.getValue()))?e:void 0}setDate(e,t){this.setValue(Yi(null!=e?e:null,!1),t)}},Kl=class extends Bn{constructor(e){super(e,"ag-range-field","range")}postConstruct(){super.postConstruct();const{min:e,max:t,step:i}=this.config;null!=e&&this.setMinValue(e),null!=t&&this.setMaxValue(t),this.setStep(i||1)}addInputListeners(){this.addManagedListener(this.eInput,"input",e=>{const t=e.target.value;this.setValue(t)})}setMinValue(e){return this.min=e,this.eInput.setAttribute("min",e.toString()),this}setMaxValue(e){return this.max=e,this.eInput.setAttribute("max",e.toString()),this}setStep(e){return this.eInput.setAttribute("step",e.toString()),this}setValue(e,t){null!=this.min&&(e=Math.max(parseFloat(e),this.min).toString()),null!=this.max&&(e=Math.min(parseFloat(e),this.max).toString());const i=super.setValue(e,t);return this.eInput.value=e,i}},$l=class extends yn{constructor(e,t){super('<div class="ag-rich-select-row" role="presentation"></div>'),this.params=e,this.wrapperEl=t}postConstruct(){this.addManagedListener(this.getGui(),"click",this.onClick.bind(this))}setState(e){let t="";this.params.valueFormatter&&(t=this.params.valueFormatter(e)),this.populateWithRenderer(e,t)||this.populateWithoutRenderer(e,t),this.value=e}highlightString(e){const{parsedValue:t}=this;if(this.params.cellRenderer||!C(t))return;let i=C(e);if(i){const r=null==t?void 0:t.toLocaleLowerCase().indexOf(e.toLocaleLowerCase());if(r>=0){const i=r+e.length,n=Ct(t.slice(0,r),!0),s=Ct(t.slice(r,i),!0),o=Ct(t.slice(i));this.renderValueWithoutRenderer(`${n}<span class="ag-rich-select-row-text-highlight">${s}</span>${o}`)}else i=!1}i||this.renderValueWithoutRenderer(t)}updateHighlighted(e){var t;const i=this.getGui(),r=`ag-rich-select-row-${this.getCompId()}`;null==(t=i.parentElement)||t.setAttribute("id",r),e&&(ei(this.getParentComponent().getAriaElement(),r),this.wrapperEl.setAttribute("data-active-option",r)),pi(i.parentElement,e),this.addOrRemoveCssClass("ag-rich-select-row-selected",e)}populateWithoutRenderer(e,t){const i=this.gos.getDocument(),r=this.getGui(),n=i.createElement("span");n.style.overflow="hidden",n.style.textOverflow="ellipsis";const s=Ct(C(t)?t:e,!0);this.parsedValue=C(s)?s:null,r.appendChild(n),this.renderValueWithoutRenderer(s),this.setTooltip({newTooltipText:this.parsedValue,shouldDisplayTooltip:()=>n.scrollWidth>n.clientWidth})}renderValueWithoutRenderer(e){const t=this.getGui().querySelector("span");t&&(t.innerHTML=C(e)?e:"&nbsp;")}populateWithRenderer(e,t){let i,r;return this.params.cellRenderer&&(r=this.userComponentFactory.getCellRendererDetails(this.params,{value:e,valueFormatted:t,setTooltip:(e,t)=>{this.setTooltip({newTooltipText:e,shouldDisplayTooltip:t})}})),r&&(i=r.newAgStackInstance()),i&&Vr(i,this.getGui()),!!i&&(i.then(e=>{this.addDestroyFunc(()=>{this.getContext().destroyBean(e)})}),!0)}onClick(){const e=this.getParentComponent(),t={type:lt.EVENT_FIELD_PICKER_VALUE_SELECTED,fromEnterKey:!1,value:this.value};null==e||e.dispatchEvent(t)}};g([ue("userComponentFactory")],$l.prototype,"userComponentFactory",2),g([ae],$l.prototype,"postConstruct",1);var ql=class e extends El{constructor(t){super(e.getTemplate((null==t?void 0:t.cssIdentifier)||"default")),this.renderedRows=new Map,this.rowHeight=20,this.pageSize=-1,this.isScrolling=!1,this.isHeightFromTheme=!0;const{cssIdentifier:i="default",ariaRole:r="listbox",listName:n}=t||{};this.cssIdentifier=i,this.ariaRole=r,this.listName=n}postConstruct(){this.addScrollListener(),this.rowHeight=this.getItemHeight(),this.addResizeObserver(),this.initialiseTabGuard({onFocusIn:e=>this.onFocusIn(e),onFocusOut:e=>this.onFocusOut(e),focusInnerElement:e=>this.focusInnerElement(e),onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e)}),this.setAriaProperties(),this.addManagedListener(this.eventService,lt.EVENT_GRID_STYLES_CHANGED,this.onGridStylesChanged.bind(this))}onGridStylesChanged(){this.rowHeight=this.getItemHeight(),this.refresh()}setAriaProperties(){const e=this.localeService.getLocaleTextFunc()("ariaDefaultListName",this.listName||"List"),t=this.eContainer;Ht(t,this.ariaRole),jt(t,e)}addResizeObserver(){const e=this.resizeObserverService.observeResize(this.getGui(),()=>this.animationFrameService.requestAnimationFrame(()=>this.drawVirtualRows()));this.addDestroyFunc(e)}focusInnerElement(e){this.focusRow(e?this.model.getRowCount()-1:0)}onFocusIn(e){const t=e.target;t.classList.contains("ag-virtual-list-item")&&(this.lastFocusedRowIndex=Ut(t)-1)}onFocusOut(e){this.getFocusableElement().contains(e.relatedTarget)||(this.lastFocusedRowIndex=null)}handleKeyDown(e){switch(e.key){case Yr.UP:case Yr.DOWN:this.navigate(e.key===Yr.UP)&&e.preventDefault();break;case Yr.PAGE_HOME:case Yr.PAGE_END:case Yr.PAGE_UP:case Yr.PAGE_DOWN:null!==this.navigateToPage(e.key)&&e.preventDefault()}}onTabKeyDown(e){this.navigate(e.shiftKey)?e.preventDefault():(qe(e),this.forceFocusOutOfContainer(e.shiftKey))}navigate(e){if(null==this.lastFocusedRowIndex)return!1;const t=this.lastFocusedRowIndex+(e?-1:1);return!(t<0||t>=this.model.getRowCount()||(this.focusRow(t),0))}navigateToPage(e,t="focused"){let i=!1;"focused"===t&&(t=this.getLastFocusedRow(),i=!0);const r=this.model.getRowCount()-1;let n=-1;return e===Yr.PAGE_HOME?n=0:e===Yr.PAGE_END?n=r:e===Yr.PAGE_DOWN?n=Math.min(t+this.pageSize,r):e===Yr.PAGE_UP&&(n=Math.max(t-this.pageSize,0)),-1===n?null:(i?this.focusRow(n):this.ensureIndexVisible(n),n)}getLastFocusedRow(){return this.lastFocusedRowIndex}focusRow(e){this.isScrolling||(this.isScrolling=!0,this.ensureIndexVisible(e),this.animationFrameService.requestAnimationFrame(()=>{if(this.isScrolling=!1,!this.isAlive())return;const t=this.renderedRows.get(e);t&&t.eDiv.focus()}))}getComponentAt(e){const t=this.renderedRows.get(e);return t&&t.rowComponent}forEachRenderedRow(e){this.renderedRows.forEach((t,i)=>e(t.rowComponent,i))}static getTemplate(e){return`<div class="ag-virtual-list-viewport ag-${e}-virtual-list-viewport" role="presentation">\n                <div class="ag-virtual-list-container ag-${e}-virtual-list-container" ref="eContainer"></div>\n            </div>`}getItemHeight(){return this.isHeightFromTheme?this.environment.getListItemHeight():this.rowHeight}ensureIndexVisible(e,t=!0){const i=this.model.getRowCount();if("number"!=typeof e||e<0||e>=i)return console.warn("AG Grid: invalid row index for ensureIndexVisible: "+e),!1;const r=e*this.rowHeight,n=r+this.rowHeight,s=this.getGui(),o=s.scrollTop,a=s.offsetHeight,l=o+a,c=t?0:this.rowHeight,u=l<n-c;if(o>r+c)return s.scrollTop=r,!0;if(u){const e=n-a;return s.scrollTop=e,!0}return!1}setComponentCreator(e){this.componentCreator=e}setComponentUpdater(e){this.componentUpdater=e}getRowHeight(){return this.rowHeight}getScrollTop(){return this.getGui().scrollTop}setRowHeight(e){this.isHeightFromTheme=!1,this.rowHeight=e,this.refresh()}refresh(e){if(null==this.model||!this.isAlive())return;const t=this.model.getRowCount();this.eContainer.style.height=t*this.rowHeight+"px",J(()=>this.eContainer.clientHeight>=t*this.rowHeight,()=>{this.isAlive()&&(this.canSoftRefresh(e)?this.drawVirtualRows(!0):(this.clearVirtualRows(),this.drawVirtualRows()))})}canSoftRefresh(e){return!!(e&&this.renderedRows.size&&"function"==typeof this.model.areRowsEqual&&this.componentUpdater)}clearVirtualRows(){this.renderedRows.forEach((e,t)=>this.removeRow(t))}drawVirtualRows(e){if(!this.isAlive()||!this.model)return;const t=this.getGui(),i=t.scrollTop,r=i+t.offsetHeight,n=Math.floor(i/this.rowHeight),s=Math.floor(r/this.rowHeight);this.pageSize=Math.floor((r-i)/this.rowHeight),this.ensureRowsRendered(n,s,e)}ensureRowsRendered(e,t,i){this.renderedRows.forEach((i,r)=>{(r<e||r>t)&&r!==this.lastFocusedRowIndex&&this.removeRow(r)}),i&&this.refreshRows();for(let i=e;i<=t;i++)this.renderedRows.has(i)||i<this.model.getRowCount()&&this.insertRow(i)}insertRow(e){const t=this.model.getRow(e),i=document.createElement("div");i.classList.add("ag-virtual-list-item",`ag-${this.cssIdentifier}-virtual-list-item`),Ht(i,"tree"===this.ariaRole?"treeitem":"option"),ri(i,this.model.getRowCount()),ni(i,e+1),i.setAttribute("tabindex","-1"),i.style.height=`${this.rowHeight}px`,i.style.top=this.rowHeight*e+"px";const r=this.componentCreator(t,i);r.addGuiEventListener("focusin",()=>this.lastFocusedRowIndex=e),i.appendChild(r.getGui()),this.renderedRows.has(e-1)?this.renderedRows.get(e-1).eDiv.insertAdjacentElement("afterend",i):this.renderedRows.has(e+1)?this.renderedRows.get(e+1).eDiv.insertAdjacentElement("beforebegin",i):this.eContainer.appendChild(i),this.renderedRows.set(e,{rowComponent:r,eDiv:i,value:t})}removeRow(e){const t=this.renderedRows.get(e);this.eContainer.removeChild(t.eDiv),this.destroyBean(t.rowComponent),this.renderedRows.delete(e)}refreshRows(){const e=this.model.getRowCount();this.renderedRows.forEach((t,i)=>{var r,n;if(i>=e)this.removeRow(i);else{const e=this.model.getRow(i);(null==(n=(r=this.model).areRowsEqual)?void 0:n.call(r,t.value,e))?this.componentUpdater(e,t.rowComponent):this.removeRow(i)}})}addScrollListener(){this.addGuiEventListener("scroll",()=>this.drawVirtualRows(),{passive:!0})}setModel(e){this.model=e}getAriaElement(){return this.eContainer}destroy(){this.isAlive()&&(this.clearVirtualRows(),super.destroy())}};g([ue("resizeObserverService")],ql.prototype,"resizeObserverService",2),g([ue("animationFrameService")],ql.prototype,"animationFrameService",2),g([Sn("eContainer")],ql.prototype,"eContainer",2),g([ae],ql.prototype,"postConstruct",1);var Yl=ql,Ql=class extends Fn{constructor(e){var t,i;super(d(h({pickerAriaLabelKey:"ariaLabelRichSelectField",pickerAriaLabelValue:"Rich Select Field",pickerType:"ag-list",className:"ag-rich-select",pickerIcon:"smallDown",ariaRole:"combobox",template:null!=(t=null==e?void 0:e.template)?t:'\n    <div class="ag-picker-field" role="presentation">\n        <div ref="eLabel"></div>\n            <div ref="eWrapper" class="ag-wrapper ag-picker-field-wrapper ag-rich-select-value ag-picker-collapsed">\n            <div ref="eDisplayField" class="ag-picker-field-display"></div>\n            <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n            <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n        </div>\n    </div>',modalPicker:!1},e),{maxPickerHeight:null!=(i=null==e?void 0:e.maxPickerHeight)?i:"calc(var(--ag-row-height) * 6.5)"})),this.searchString="",this.highlightedItem=-1,this.lastRowHovered=-1,this.searchStringCreator=null;const{cellRowHeight:r,value:n,valueList:s,searchStringCreator:o}=e||{};null!=r&&(this.cellRowHeight=r),void 0!==n&&(this.value=n),null!=s&&(this.values=s),o&&(this.searchStringCreator=o)}postConstruct(){super.postConstruct(),this.createLoadingElement(),this.createListComponent();const{allowTyping:e,placeholder:t}=this.config;e?(this.eInput.setAutoComplete(!1).setInputPlaceholder(t),this.eDisplayField.classList.add("ag-hidden")):this.eInput.setDisplayed(!1),this.eWrapper.tabIndex=this.gos.get("tabIndex");const{searchDebounceDelay:i=300}=this.config;this.clearSearchString=X(this.clearSearchString,i),this.renderSelectedValue(),e&&(this.eInput.onValueChange(e=>this.searchTextFromString(e)),this.addManagedListener(this.eWrapper,"focus",this.onWrapperFocus.bind(this))),this.addManagedListener(this.eWrapper,"focusout",this.onWrapperFocusOut.bind(this))}createLoadingElement(){const e=this.gos.getDocument(),t=this.localeService.getLocaleTextFunc(),i=e.createElement("div");i.classList.add("ag-loading-text"),i.innerText=t("loadingOoo","Loading..."),this.eLoading=i}createListComponent(){this.listComponent=this.createBean(new Yl({cssIdentifier:"rich-select"})),this.listComponent.setComponentCreator(this.createRowComponent.bind(this)),this.listComponent.setComponentUpdater((e,t)=>{}),this.listComponent.setParentComponent(this),this.addManagedListener(this.listComponent,lt.EVENT_FIELD_PICKER_VALUE_SELECTED,e=>{this.onListValueSelected(e.value,e.fromEnterKey)});const{cellRowHeight:e}=this;e&&this.listComponent.setRowHeight(e);const t=this.listComponent.getGui(),i=this.listComponent.getAriaElement();this.addManagedListener(t,"mousemove",this.onPickerMouseMove.bind(this)),this.addManagedListener(t,"mousedown",e=>e.preventDefault()),t.classList.add("ag-rich-select-list");const r=`ag-rich-select-list-${this.listComponent.getCompId()}`;i.setAttribute("id",r),jt(i,this.localeService.getLocaleTextFunc()(this.config.pickerAriaLabelKey,this.config.pickerAriaLabelValue)),fi(this.eWrapper,i)}renderSelectedValue(){const{value:e,eDisplayField:t,config:i}=this,{allowTyping:r,initialInputValue:n}=this.config,s=this.config.valueFormatter?this.config.valueFormatter(e):e;if(r)return void this.eInput.setValue(null!=n?n:s);let o,a;if(i.cellRenderer&&(o=this.userComponentFactory.getCellRendererDetails(this.config,{value:e,valueFormatted:s})),o&&(a=o.newAgStackInstance()),a)Cr(t),Vr(a,t),a.then(e=>{this.addDestroyFunc(()=>this.getContext().destroyBean(e))});else{if(C(this.value))t.innerText=s,t.classList.remove("ag-display-as-placeholder");else{const{placeholder:e}=i;C(e)?(t.innerHTML=`${Ct(e)}`,t.classList.add("ag-display-as-placeholder")):Cr(t)}this.setTooltip({newTooltipText:null!=s?s:null,shouldDisplayTooltip:()=>this.eDisplayField.scrollWidth>this.eDisplayField.clientWidth})}}getCurrentValueIndex(){const{currentList:e,value:t}=this;if(null==t||!e)return-1;for(let i=0;i<e.length;i++)if(e[i]===t)return i;return-1}highlightFilterMatch(){var e;null==(e=this.listComponent)||e.forEachRenderedRow((e,t)=>{e.highlightString(this.searchString)})}highlightSelectedValue(e){var t;null==e&&(e=this.getCurrentValueIndex()),this.highlightedItem=e,null==(t=this.listComponent)||t.forEachRenderedRow((t,i)=>{const r=-1!==e&&this.highlightedItem===i;t.updateHighlighted(r)})}setRowHeight(e){e!==this.cellRowHeight&&(this.cellRowHeight=e),this.listComponent&&this.listComponent.setRowHeight(e)}createPickerComponent(){const{values:e}=this;return e&&this.setValueList({valueList:e}),this.listComponent}setSearchStringCreator(e){this.searchStringCreator=e}setValueList(e){const{valueList:t,refresh:i}=e;this.listComponent&&this.currentList!==t&&(this.currentList=t,this.listComponent.setModel({getRowCount:()=>t.length,getRow:e=>t[e],areRowsEqual:(e,t)=>e===t}),i&&(this.values?this.listComponent.refresh(!0):(this.values=t,this.isPickerDisplayed&&this.showCurrentValueInPicker())))}showPicker(){super.showPicker(),this.showCurrentValueInPicker(),this.displayOrHidePicker()}showCurrentValueInPicker(){var e,t;if(!this.listComponent)return;if(!this.currentList)return void(this.isPickerDisplayed&&this.eLoading&&this.listComponent.appendChild(this.eLoading));(null==(e=this.eLoading)?void 0:e.offsetParent)&&(null==(t=this.eLoading.parentElement)||t.removeChild(this.eLoading));const i=this.getCurrentValueIndex();-1!==i?(this.listComponent.refresh(),this.listComponent.ensureIndexVisible(i),this.listComponent.refresh(!0),this.highlightSelectedValue(i)):this.listComponent.refresh()}beforeHidePicker(){this.highlightedItem=-1,super.beforeHidePicker()}onWrapperFocus(){if(!this.eInput)return;const e=this.eInput.getFocusableElement();e.focus(),e.select()}onWrapperFocusOut(e){this.eWrapper.contains(e.relatedTarget)||this.hidePicker()}buildSearchStringFromKeyboardEvent(e){let{key:t}=e;if(t===Yr.BACKSPACE)this.searchString=this.searchString.slice(0,-1),t="";else if(!Qr(e))return;e.preventDefault(),this.searchTextFromCharacter(t)}searchTextFromCharacter(e){this.searchString+=e,this.runSearch(),this.clearSearchString()}searchTextFromString(e){null==e&&(e=""),this.searchString=e,this.runSearch()}buildSearchStrings(e){const{valueFormatter:t=e=>e}=this.config;let i;return"number"==typeof e[0]||"string"==typeof e[0]?i=e.map(e=>t(e)):"object"==typeof e[0]&&this.searchStringCreator&&(i=this.searchStringCreator(e)),i}getSuggestionsAndFilteredValues(e,t){let i=[],r=[];if(!e.length)return{suggestions:i,filteredValues:r};const{searchType:n="fuzzy",filterList:s}=this.config;if("fuzzy"===n){const e=zr(this.searchString,t,!0);i=e.values;const n=e.indices;if(s&&n.length)for(let e=0;e<n.length;e++)r.push(this.values[n[e]])}else i=t.filter((e,t)=>{const i=e.toLocaleLowerCase(),o=this.searchString.toLocaleLowerCase(),a="match"===n?i.startsWith(o):-1!==i.indexOf(o);return s&&a&&r.push(this.values[t]),a});return{suggestions:i,filteredValues:r}}filterListModel(e){const{filterList:t}=this.config;t&&(this.setValueList({valueList:e,refresh:!0}),this.alignPickerToComponent())}runSearch(){var e,t;const{values:i}=this,r=this.buildSearchStrings(i);if(!r)return void this.highlightSelectedValue(-1);const{suggestions:n,filteredValues:s}=this.getSuggestionsAndFilteredValues(this.searchString,r),{filterList:o,highlightMatch:a,searchType:l="fuzzy"}=this.config,c=s.length,u=!(!o||""===this.searchString);if(this.filterListModel(u?s:i),n.length){const e=u?0:r.indexOf(n[0]);this.selectListItem(e)}else if(this.highlightSelectedValue(-1),!u||c)null==(e=this.listComponent)||e.ensureIndexVisible(0);else if(u){this.getAriaElement().removeAttribute("data-active-option");const e=null==(t=this.listComponent)?void 0:t.getAriaElement();e&&ei(e,null)}a&&"fuzzy"!==l&&this.highlightFilterMatch(),this.displayOrHidePicker()}displayOrHidePicker(){var e;const t=null==(e=this.listComponent)?void 0:e.getGui(),i=!!this.currentList&&0===this.currentList.length;null==t||t.classList.toggle("ag-hidden",i)}clearSearchString(){this.searchString=""}selectListItem(e,t){!this.isPickerDisplayed||!this.currentList||!this.listComponent||e<0||e>=this.currentList.length||(this.listComponent.ensureIndexVisible(e,!t)&&!t&&this.listComponent.refresh(!0),this.highlightSelectedValue(e))}setValue(e,t,i){const r=this.currentList?this.currentList.indexOf(e):-1;return-1===r?this:(this.value=e,i||this.selectListItem(r),this.renderSelectedValue(),super.setValue(e,t))}createRowComponent(e){const t=new $l(this.config,this.eWrapper);t.setParentComponent(this.listComponent),this.getContext().createBean(t),t.setState(e);const{highlightMatch:i,searchType:r="fuzzy"}=this.config;return i&&"fuzzy"!==r&&t.highlightString(this.searchString),t}getRowForMouseEvent(e){const{listComponent:t}=this;if(!t)return-1;const i=(null==t?void 0:t.getGui()).getBoundingClientRect(),r=t.getScrollTop(),n=e.clientY-i.top+r;return Math.floor(n/t.getRowHeight())}onPickerMouseMove(e){if(!this.listComponent)return;const t=this.getRowForMouseEvent(e);-1!==t&&t!=this.lastRowHovered&&(this.lastRowHovered=t,this.selectListItem(t,!0))}onNavigationKeyDown(e,t){e.preventDefault();const i=t===Yr.DOWN;if(!this.isPickerDisplayed&&i)return void this.showPicker();const r=this.highlightedItem,n=-1===r?0:r+(i?1:-1);this.selectListItem(n)}onPageNavigation(e){var t;if(!this.isPickerDisplayed)return;const i=null==(t=this.listComponent)?void 0:t.navigateToPage(e,this.highlightedItem);null!=i&&this.animationFrameService.requestAnimationFrame(()=>{if(!this.isAlive())return null;this.highlightSelectedValue(i)})}onEnterKeyDown(e){this.isPickerDisplayed&&(e.preventDefault(),this.currentList&&this.onListValueSelected(this.currentList[this.highlightedItem],!0))}onTabKeyDown(){this.isPickerDisplayed&&this.currentList&&this.setValue(this.currentList[this.highlightedItem],!1,!0)}onListValueSelected(e,t){this.setValue(e,!1,!0),this.dispatchPickerEvent(e,t),this.hidePicker()}dispatchPickerEvent(e,t){const i={type:lt.EVENT_FIELD_PICKER_VALUE_SELECTED,fromEnterKey:t,value:e};this.dispatchEvent(i)}getFocusableElement(){const{allowTyping:e}=this.config;return e?this.eInput.getFocusableElement():super.getFocusableElement()}onKeyDown(e){const t=e.key,{allowTyping:i}=this.config;switch(t){case Yr.LEFT:case Yr.RIGHT:i||e.preventDefault();break;case Yr.PAGE_HOME:case Yr.PAGE_END:if(i){e.preventDefault();const i=this.eInput.getInputElement(),r=t===Yr.PAGE_HOME?0:i.value.length;i.setSelectionRange(r,r);break}case Yr.PAGE_UP:case Yr.PAGE_DOWN:e.preventDefault(),this.onPageNavigation(t);break;case Yr.DOWN:case Yr.UP:this.onNavigationKeyDown(e,t);break;case Yr.ESCAPE:this.isPickerDisplayed&&(Sr(this.listComponent.getGui())&&(e.preventDefault(),qe(e)),this.hidePicker());break;case Yr.ENTER:this.onEnterKeyDown(e);break;case Yr.TAB:this.onTabKeyDown();break;default:i||this.buildSearchStringFromKeyboardEvent(e)}}destroy(){this.listComponent&&(this.destroyBean(this.listComponent),this.listComponent=void 0),this.eLoading=void 0,super.destroy()}};g([ue("userComponentFactory")],Ql.prototype,"userComponentFactory",2),g([ue("animationFrameService")],Ql.prototype,"animationFrameService",2),g([Sn("eInput")],Ql.prototype,"eInput",2);var Xl=class e extends Nn{constructor(t){super(t,e.TEMPLATE),this.labelAlignment="top"}init(){this.eSlider.addCssClass("ag-slider-field");const{minValue:e,maxValue:t,textFieldWidth:i,step:r,value:n,onValueChange:s}=this.config;null!=e&&this.setMinValue(e),null!=t&&this.setMaxValue(t),null!=i&&this.setTextFieldWidth(i),null!=r&&this.setStep(r),null!=n&&this.setValue(n),null!=s&&this.onValueChange(s)}onValueChange(e){const t=lt.EVENT_FIELD_VALUE_CHANGED;return this.addManagedListener(this.eText,t,()=>{const t=parseFloat(this.eText.getValue());this.eSlider.setValue(t.toString(),!0),e(t||0)}),this.addManagedListener(this.eSlider,t,()=>{const t=this.eSlider.getValue();this.eText.setValue(t,!0),e(parseFloat(t))}),this}setSliderWidth(e){return this.eSlider.setWidth(e),this}setTextFieldWidth(e){return this.eText.setWidth(e),this}setMinValue(e){return this.eSlider.setMinValue(e),this.eText.setMin(e),this}setMaxValue(e){return this.eSlider.setMaxValue(e),this.eText.setMax(e),this}getValue(){return this.eText.getValue()}setValue(e,t){return this.getValue()===e||(this.eText.setValue(e,!0),this.eSlider.setValue(e,!0),t||this.dispatchEvent({type:lt.EVENT_FIELD_VALUE_CHANGED})),this}setStep(e){return this.eSlider.setStep(e),this.eText.setStep(e),this}};Xl.TEMPLATE='<div class="ag-slider">\n            <label ref="eLabel"></label>\n            <div class="ag-wrapper ag-slider-wrapper">\n                <ag-input-range ref="eSlider"></ag-input-range>\n                <ag-input-number-field ref="eText"></ag-input-number-field>\n            </div>\n        </div>',g([Sn("eLabel")],Xl.prototype,"eLabel",2),g([Sn("eSlider")],Xl.prototype,"eSlider",2),g([Sn("eText")],Xl.prototype,"eText",2),g([ae],Xl.prototype,"init",1);var Zl=Xl,Jl=class e extends yn{constructor(t={}){super(e.getTemplate(t)),this.params=t,this.suppressEnabledCheckbox=!0,this.suppressToggleExpandOnEnableChange=!1;const{enabled:i,items:r,suppressEnabledCheckbox:n,expanded:s,suppressToggleExpandOnEnableChange:o,useToggle:a}=t;this.cssIdentifier=t.cssIdentifier||"default",this.enabled=null==i||i,this.items=r||[],this.useToggle=null!=a&&a,this.alignItems=t.alignItems||"center",this.expanded=null==s||s,null!=n&&(this.suppressEnabledCheckbox=n),null!=o&&(this.suppressToggleExpandOnEnableChange=o)}static getTemplate(e){const t=e.cssIdentifier||"default";return`\n            <div class="ag-group ag-${t}-group" role="presentation">\n                <div ref="eToolbar" class="ag-group-toolbar ag-${t}-group-toolbar">\n                    <ag-checkbox ref="cbGroupEnabled"></ag-checkbox>\n                </div>\n                <div ref="eContainer" class="ag-group-container ag-group-container-${e.direction||"vertical"} ag-${t}-group-container"></div>\n            </div>\n        `}postConstruct(){if(this.setupTitleBar(),this.items.length){const e=this.items;this.items=[],this.addItems(e)}const e=this.localeService.getLocaleTextFunc();this.cbGroupEnabled.setLabel(e("enabled","Enabled")),this.enabled&&this.setEnabled(this.enabled,void 0,!0),this.setAlignItems(this.alignItems);const{onEnableChange:t,suppressOpenCloseIcons:i}=this.params;this.hideEnabledCheckbox(this.suppressEnabledCheckbox),this.hideOpenCloseIcons(null!=i&&i),this.refreshChildDisplay(),sr(this.eContainer,this.expanded),this.cbGroupEnabled.onValueChange(e=>{this.setEnabled(e,!0,this.suppressToggleExpandOnEnableChange),this.dispatchEnableChangeEvent(e)}),null!=t&&this.onEnableChange(t)}refreshChildDisplay(){var e;sr(this.eToolbar,this.expanded&&!this.suppressEnabledCheckbox),null==(e=this.eTitleBar)||e.refreshOnExpand(this.expanded)}isExpanded(){return this.expanded}setAlignItems(e){this.alignItems!==e&&this.removeCssClass(`ag-group-item-alignment-${this.alignItems}`),this.alignItems=e;const t=`ag-group-item-alignment-${this.alignItems}`;return this.addCssClass(t),this}toggleGroupExpand(t){var i;let r=!1;if((null==(i=this.eTitleBar)?void 0:i.isSuppressCollapse())&&!this.useToggle)t=!0,r=!0;else if(t=null!=t?t:!this.expanded,this.expanded===t)return this;return this.expanded=t,this.refreshChildDisplay(),sr(this.eContainer,t),r||this.dispatchEvent({type:t?e.EVENT_EXPANDED:e.EVENT_COLLAPSED}),this}addItems(e){e.forEach(e=>this.addItem(e))}prependItem(e){this.insertItem(e,!0)}addItem(e){this.insertItem(e,!1)}insertItem(e,t){const i=this.eContainer,r=e instanceof yn?e.getGui():e;r.classList.add("ag-group-item",`ag-${this.cssIdentifier}-group-item`),t?(i.insertAdjacentElement("afterbegin",r),this.items.unshift(r)):(i.appendChild(r),this.items.push(r))}hideItem(e,t){sr(this.items[t],!e)}getItemIndex(e){const t=e instanceof yn?e.getGui():e;return this.items.indexOf(t)}setTitle(e){var t;return null==(t=this.eTitleBar)||t.setTitle(e),this}addTitleBarWidget(e){var t;return null==(t=this.eTitleBar)||t.addWidget(e),this}addCssClassToTitleBar(e){var t;null==(t=this.eTitleBar)||t.addCssClass(e)}dispatchEnableChangeEvent(t){const i={type:e.EVENT_ENABLE_CHANGE,enabled:t};this.dispatchEvent(i)}setEnabled(e,t,i){var r;return this.enabled=e,this.refreshDisabledStyles(),i||this.toggleGroupExpand(e),t||(this.cbGroupEnabled.setValue(e),null==(r=this.eToggle)||r.setValue(e)),this}isEnabled(){return this.enabled}onEnableChange(t){return this.addManagedListener(this,e.EVENT_ENABLE_CHANGE,e=>t(e.enabled)),this}hideEnabledCheckbox(e){return this.suppressEnabledCheckbox=e,this.refreshChildDisplay(),this.refreshDisabledStyles(),this}hideOpenCloseIcons(e){var t;return null==(t=this.eTitleBar)||t.hideOpenCloseIcons(e),this}refreshDisabledStyles(){var e;const t=!this.enabled;this.eContainer.classList.toggle("ag-disabled",t),null==(e=this.eTitleBar)||e.refreshDisabledStyles(this.suppressEnabledCheckbox&&t),this.eContainer.classList.toggle("ag-disabled-group-container",t)}setupTitleBar(){const e=this.useToggle?this.createToggleTitleBar():this.createDefaultTitleBar();this.eToolbar.insertAdjacentElement("beforebegin",e.getGui())}createDefaultTitleBar(){const e=this.createManagedBean(new rc(this.params));return this.eTitleBar=e,e.refreshOnExpand(this.expanded),this.addManagedListener(e,rc.EVENT_EXPAND_CHANGED,e=>this.toggleGroupExpand(e.expanded)),e}createToggleTitleBar(){var e;const t=this.createManagedBean(new Ul({value:this.enabled,label:this.params.title,labelAlignment:"left",labelWidth:"flex",onValueChange:e=>{this.setEnabled(e,!0),this.dispatchEnableChangeEvent(e)}}));return t.addCssClass("ag-group-title-bar"),t.addCssClass(`ag-${null!=(e=this.params.cssIdentifier)?e:"default"}-group-title-bar ag-unselectable`),this.eToggle=t,this.toggleGroupExpand(this.enabled),t}};Jl.EVENT_EXPANDED="expanded",Jl.EVENT_COLLAPSED="collapsed",Jl.EVENT_ENABLE_CHANGE="enableChange",g([Sn("eToolbar")],Jl.prototype,"eToolbar",2),g([Sn("cbGroupEnabled")],Jl.prototype,"cbGroupEnabled",2),g([Sn("eContainer")],Jl.prototype,"eContainer",2),g([ae],Jl.prototype,"postConstruct",1);var ec=Jl,tc="ag-disabled-group-title-bar",ic=class e extends yn{constructor(t={}){super(e.getTemplate(t)),this.suppressOpenCloseIcons=!1;const{title:i,suppressOpenCloseIcons:r}=t;i&&i.length>0&&(this.title=i),null!=r&&(this.suppressOpenCloseIcons=r)}static getTemplate(e){var t;const i=null!=(t=e.cssIdentifier)?t:"default";return`\n            <div class="ag-group-title-bar ag-${i}-group-title-bar ag-unselectable" role="button">\n                <span class="ag-group-title-bar-icon ag-${i}-group-title-bar-icon" ref="eGroupOpenedIcon" role="presentation"></span>\n                <span class="ag-group-title-bar-icon ag-${i}-group-title-bar-icon" ref="eGroupClosedIcon" role="presentation"></span>\n                <span ref="eTitle" class="ag-group-title ag-${i}-group-title"></span>\n            </div>\n        `}postConstruct(){this.setTitle(this.title),this.hideOpenCloseIcons(this.suppressOpenCloseIcons),this.setupExpandContract()}setupExpandContract(){this.eGroupClosedIcon.appendChild(Kr("columnSelectClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild(Kr("columnSelectOpen",this.gos,null)),this.addManagedListener(this.getGui(),"click",()=>this.dispatchExpandChanged()),this.addManagedListener(this.getGui(),"keydown",e=>{switch(e.key){case Yr.ENTER:case Yr.SPACE:e.preventDefault(),this.dispatchExpandChanged();break;case Yr.RIGHT:case Yr.LEFT:e.preventDefault(),this.dispatchExpandChanged(e.key===Yr.RIGHT)}})}refreshOnExpand(e){this.refreshAriaStatus(e),this.refreshOpenCloseIcons(e)}refreshAriaStatus(e){this.suppressOpenCloseIcons||ti(this.getGui(),e)}refreshOpenCloseIcons(e){const t=!this.suppressOpenCloseIcons;sr(this.eGroupOpenedIcon,t&&e),sr(this.eGroupClosedIcon,t&&!e)}isSuppressCollapse(){return this.suppressOpenCloseIcons}dispatchExpandChanged(t){const i={type:e.EVENT_EXPAND_CHANGED,expanded:t};this.dispatchEvent(i)}setTitle(e){const t=this.getGui(),i=!!e&&e.length>0;e=i?e:void 0,this.eTitle.textContent=null!=e?e:"",sr(t,i),e!==this.title&&(this.title=e);const r=t.classList.contains(tc);return this.refreshDisabledStyles(r),this}addWidget(e){return this.getGui().appendChild(e),this}hideOpenCloseIcons(e){return this.suppressOpenCloseIcons=e,e&&this.dispatchExpandChanged(!0),this}refreshDisabledStyles(e){const t=this.getGui();e?(t.classList.add(tc),t.removeAttribute("tabindex")):(t.classList.remove(tc),"string"==typeof this.title?t.setAttribute("tabindex","0"):t.removeAttribute("tabindex"))}};ic.EVENT_EXPAND_CHANGED="expandedChanged",g([Sn("eGroupOpenedIcon")],ic.prototype,"eGroupOpenedIcon",2),g([Sn("eGroupClosedIcon")],ic.prototype,"eGroupClosedIcon",2),g([Sn("eTitle")],ic.prototype,"eTitle",2),g([ae],ic.prototype,"postConstruct",1);var rc=ic,nc=class extends El{constructor(e=0,t){super('<div class="ag-menu-list" role="tree"></div>'),this.level=e,this.menuItems=[],this.params=null!=t?t:{column:null,node:null,value:null}}postConstruct(){this.initialiseTabGuard({onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e),onFocusIn:e=>this.handleFocusIn(e),onFocusOut:e=>this.handleFocusOut(e)})}onTabKeyDown(e){const t=this.getParentComponent(),i=t&&t.getGui();i&&i.classList.contains("ag-focus-managed")||e.preventDefault(),e.shiftKey&&this.closeIfIsChild(e)}handleKeyDown(e){switch(e.key){case Yr.UP:case Yr.RIGHT:case Yr.DOWN:case Yr.LEFT:e.preventDefault(),this.handleNavKey(e.key);break;case Yr.ESCAPE:this.closeIfIsChild()&&qe(e)}}handleFocusIn(e){var t,i;const r=e.relatedTarget;(this.tabGuardCtrl.isTabGuard(r)||!this.getGui().contains(r)&&!(null==(i=null==(t=this.activeMenuItem)?void 0:t.getSubMenuGui())?void 0:i.contains(r)))&&(this.activeMenuItem?this.activeMenuItem.activate():this.activateFirstItem())}handleFocusOut(e){var t;const i=e.relatedTarget;!this.activeMenuItem||this.getGui().contains(i)||(null==(t=this.activeMenuItem.getSubMenuGui())?void 0:t.contains(i))||this.activeMenuItem.isSubMenuOpening()||this.activeMenuItem.deactivate()}clearActiveItem(){this.activeMenuItem&&(this.activeMenuItem.deactivate(),this.activeMenuItem=null)}addMenuItems(e){null!=e&&hn.all(e.map(e=>"separator"===e?hn.resolve({eGui:this.createSeparator()}):"string"==typeof e?(console.warn(`AG Grid: unrecognised menu item ${e}`),hn.resolve({eGui:null})):this.addItem(e))).then(e=>{e.forEach(e=>{(null==e?void 0:e.eGui)&&(this.appendChild(e.eGui),e.comp&&this.menuItems.push(e.comp))})})}addItem(e){const t=this.createManagedBean(new ac);return t.init({menuItemDef:e,isAnotherSubMenuOpen:()=>this.menuItems.some(e=>e.isSubMenuOpen()),level:this.level,contextParams:this.params}).then(()=>(t.setParentComponent(this),this.addManagedListener(t,ac.EVENT_CLOSE_MENU,e=>{this.dispatchEvent(e)}),this.addManagedListener(t,ac.EVENT_MENU_ITEM_ACTIVATED,e=>{this.activeMenuItem&&this.activeMenuItem!==e.menuItem&&this.activeMenuItem.deactivate(),this.activeMenuItem=e.menuItem}),{comp:t,eGui:t.getGui()}))}activateFirstItem(){const e=this.menuItems.filter(e=>!e.isDisabled())[0];e&&e.activate()}createSeparator(){return br('\n            <div class="ag-menu-separator" aria-hidden="true">\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n                <div class="ag-menu-separator-part"></div>\n            </div>')}handleNavKey(e){switch(e){case Yr.UP:case Yr.DOWN:const t=this.findNextItem(e===Yr.UP);return void(t&&t!==this.activeMenuItem&&t.activate())}e===(this.gos.get("enableRtl")?Yr.RIGHT:Yr.LEFT)?this.closeIfIsChild():this.openChild()}closeIfIsChild(e){const t=this.getParentComponent();return!!(t&&t instanceof ac)&&(e&&e.preventDefault(),t.closeSubMenu(),t.getGui().focus(),!0)}openChild(){this.activeMenuItem&&this.activeMenuItem.openSubMenu(!0)}findNextItem(e){const t=this.menuItems.filter(e=>!e.isDisabled());if(!t.length)return;if(!this.activeMenuItem)return e?_e(t):t[0];let i;e&&t.reverse();let r=!1;for(let e=0;e<t.length;e++){const n=t[e];if(r){i=n;break}n===this.activeMenuItem&&(r=!0)}return r&&!i?t[0]:i||this.activeMenuItem}destroy(){this.clearActiveItem(),super.destroy()}};g([ue("focusService")],nc.prototype,"focusService",2),g([ae],nc.prototype,"postConstruct",1);var sc=class extends El{constructor(e){super(),this.wrappedComponent=e,this.setTemplateFromElement(e.getGui())}postConstruct(){this.initialiseTabGuard({onTabKeyDown:e=>this.onTabKeyDown(e),handleKeyDown:e=>this.handleKeyDown(e)})}handleKeyDown(e){e.key===Yr.ESCAPE&&this.closePanel()}onTabKeyDown(e){e.defaultPrevented||(this.closePanel(),e.preventDefault())}closePanel(){const e=this.parentComponent;e.closeSubMenu(),setTimeout(()=>e.getGui().focus(),0)}};g([ae],sc.prototype,"postConstruct",1);var oc=class e extends rt{constructor(){super(...arguments),this.isActive=!1,this.subMenuIsOpen=!1,this.subMenuIsOpening=!1,this.suppressRootStyles=!0,this.suppressAria=!0,this.suppressFocus=!0}init(e){var t,i;const{menuItemDef:r,isAnotherSubMenuOpen:n,level:s,childComponent:o,contextParams:a}=e;return this.params=e.menuItemDef,this.level=s,this.isAnotherSubMenuOpen=n,this.childComponent=o,this.contextParams=a,this.cssClassPrefix=null!=(i=null==(t=this.params.menuItemParams)?void 0:t.cssClassPrefix)?i:"ag-menu-option",this.userComponentFactory.getMenuItemCompDetails(this.params,d(h({},r),{level:s,isAnotherSubMenuOpen:n,openSubMenu:e=>this.openSubMenu(e),closeSubMenu:()=>this.closeSubMenu(),closeMenu:e=>this.closeMenu(e),updateTooltip:(e,t)=>this.refreshTooltip(e,t),onItemActivated:()=>this.onItemActivated()})).newAgStackInstance().then(e=>{var t;this.menuItemComp=e;const i=null==(t=e.configureDefaults)?void 0:t.call(e);i&&this.configureDefaults(!0===i?void 0:i)})}addListeners(e,t){(null==t?void 0:t.suppressClick)||this.addManagedListener(e,"click",e=>this.onItemSelected(e)),(null==t?void 0:t.suppressKeyboardSelect)||this.addManagedListener(e,"keydown",e=>{e.key!==Yr.ENTER&&e.key!==Yr.SPACE||(e.preventDefault(),this.onItemSelected(e))}),(null==t?void 0:t.suppressMouseDown)||this.addManagedListener(e,"mousedown",e=>{e.stopPropagation(),e.preventDefault()}),(null==t?void 0:t.suppressMouseOver)||(this.addManagedListener(e,"mouseenter",()=>this.onMouseEnter()),this.addManagedListener(e,"mouseleave",()=>this.onMouseLeave()))}isDisabled(){return!!this.params.disabled}openSubMenu(t=!1){var i,r;if(this.closeSubMenu(),!this.params.subMenu)return;this.subMenuIsOpening=!0;const n=br('<div class="ag-menu" role="presentation"></div>');let s;this.eSubMenuGui=n;let o=()=>{this.subMenuIsOpening=!1};if(this.childComponent){const e=this.createBean(new sc(this.childComponent));e.setParentComponent(this);const t=e.getGui(),i="mouseenter",r=()=>this.cancelDeactivate();t.addEventListener(i,r),s=()=>t.removeEventListener(i,r),n.appendChild(t),this.childComponent.afterGuiAttached&&(o=()=>{this.childComponent.afterGuiAttached(),this.subMenuIsOpening=!1})}else if(this.params.subMenu){const i=this.createBean(new nc(this.level+1,this.contextParams));i.setParentComponent(this),i.addMenuItems(this.params.subMenu),n.appendChild(i.getGui()),this.addManagedListener(i,e.EVENT_CLOSE_MENU,e=>this.dispatchEvent(e)),i.addGuiEventListener("mouseenter",()=>this.cancelDeactivate()),s=()=>this.destroyBean(i),t&&(o=()=>{i.activateFirstItem(),this.subMenuIsOpening=!1})}const a=this.popupService.positionPopupForMenu.bind(this.popupService,{eventSource:this.eGui,ePopup:n}),l=this.localeService.getLocaleTextFunc(),c=this.popupService.addPopup({modal:!0,eChild:n,positionCallback:a,anchorToElement:this.eGui,ariaLabel:l("ariaLabelSubMenu","SubMenu"),afterGuiAttached:o});this.subMenuIsOpen=!0,this.setAriaExpanded(!0),this.hideSubMenu=()=>{var e,t;c&&c.hideFunc(),this.subMenuIsOpen=!1,this.setAriaExpanded(!1),s(),null==(t=(e=this.menuItemComp).setExpanded)||t.call(e,!1),this.eSubMenuGui=void 0},null==(r=(i=this.menuItemComp).setExpanded)||r.call(i,!0)}setAriaExpanded(e){this.suppressAria||ti(this.eGui,e)}closeSubMenu(){this.hideSubMenu&&(this.hideSubMenu(),this.hideSubMenu=null,this.setAriaExpanded(!1))}isSubMenuOpen(){return this.subMenuIsOpen}isSubMenuOpening(){return this.subMenuIsOpening}activate(e){var t,i;this.cancelActivate(),this.params.disabled||(this.isActive=!0,this.suppressRootStyles||this.eGui.classList.add(`${this.cssClassPrefix}-active`),null==(i=(t=this.menuItemComp).setActive)||i.call(t,!0),this.suppressFocus||this.eGui.focus({preventScroll:!0}),e&&this.params.subMenu&&window.setTimeout(()=>{this.isAlive()&&this.isActive&&this.openSubMenu()},300),this.onItemActivated())}deactivate(){var e,t;this.cancelDeactivate(),this.suppressRootStyles||this.eGui.classList.remove(`${this.cssClassPrefix}-active`),null==(t=(e=this.menuItemComp).setActive)||t.call(e,!1),this.isActive=!1,this.subMenuIsOpen&&this.hideSubMenu()}getGui(){return this.menuItemComp.getGui()}getParentComponent(){return this.parentComponent}setParentComponent(e){this.parentComponent=e}getSubMenuGui(){return this.eSubMenuGui}onItemSelected(e){var t,i;null==(i=(t=this.menuItemComp).select)||i.call(t),this.params.action?this.getFrameworkOverrides().wrapOutgoing(()=>this.params.action(this.gos.addGridCommonParams(h({},this.contextParams)))):this.openSubMenu(e&&"keydown"===e.type),this.params.subMenu&&!this.params.action||this.params.suppressCloseOnSelect||this.closeMenu(e)}closeMenu(t){const i={type:e.EVENT_CLOSE_MENU};t&&(t instanceof MouseEvent?i.mouseEvent=t:i.keyboardEvent=t),this.dispatchEvent(i)}onItemActivated(){const t={type:e.EVENT_MENU_ITEM_ACTIVATED,menuItem:this};this.dispatchEvent(t)}cancelActivate(){this.activateTimeoutId&&(window.clearTimeout(this.activateTimeoutId),this.activateTimeoutId=0)}cancelDeactivate(){this.deactivateTimeoutId&&(window.clearTimeout(this.deactivateTimeoutId),this.deactivateTimeoutId=0)}onMouseEnter(){this.cancelDeactivate(),this.isAnotherSubMenuOpen()?this.activateTimeoutId=window.setTimeout(()=>this.activate(!0),e.ACTIVATION_DELAY):this.activate(!0)}onMouseLeave(){this.cancelActivate(),this.isSubMenuOpen()?this.deactivateTimeoutId=window.setTimeout(()=>this.deactivate(),e.ACTIVATION_DELAY):this.deactivate()}configureDefaults(e){var t,i,r;if(!this.menuItemComp)return void setTimeout(()=>this.configureDefaults(e));let n=this.menuItemComp.getGui();const s=null==(i=(t=this.menuItemComp).getRootElement)?void 0:i.call(t);s&&((null==e?void 0:e.suppressRootStyles)||n.classList.add("ag-menu-option-custom"),n=s),this.eGui=n,this.suppressRootStyles=!!(null==e?void 0:e.suppressRootStyles),this.suppressRootStyles||(n.classList.add(this.cssClassPrefix),null==(r=this.params.cssClasses)||r.forEach(e=>n.classList.add(e)),this.params.disabled&&n.classList.add(`${this.cssClassPrefix}-disabled`)),(null==e?void 0:e.suppressTooltip)||this.refreshTooltip(this.params.tooltip),this.suppressAria=!!(null==e?void 0:e.suppressAria),this.suppressAria||(Ht(n,"treeitem"),Xt(n,this.level+1),this.params.disabled&&Zt(n,!0)),(null==e?void 0:e.suppressTabIndex)||n.setAttribute("tabindex","-1"),this.params.disabled||this.addListeners(n,e),this.suppressFocus=!!(null==e?void 0:e.suppressFocus)}refreshTooltip(e,t){this.tooltip=e,this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),e&&this.menuItemComp&&(this.tooltipFeature=this.createBean(new mn({getGui:()=>this.getGui(),getTooltipValue:()=>this.tooltip,getLocation:()=>"menu",shouldDisplayTooltip:t})))}destroy(){this.tooltipFeature&&(this.tooltipFeature=this.destroyBean(this.tooltipFeature)),super.destroy()}};oc.EVENT_CLOSE_MENU="closeMenu",oc.EVENT_MENU_ITEM_ACTIVATED="menuItemActivated",oc.ACTIVATION_DELAY=80,g([ue("popupService")],oc.prototype,"popupService",2),g([ue("userComponentFactory")],oc.prototype,"userComponentFactory",2);var ac=oc,lc=class e extends yn{constructor(t){super(e.getTemplate(t)),this.config=t,this.closable=!0}static getTemplate(e){const t=e.cssIdentifier||"default";return`<div class="ag-panel ag-${t}-panel" tabindex="-1">\n            <div ref="eTitleBar" class="ag-panel-title-bar ag-${t}-panel-title-bar ag-unselectable">\n                <span ref="eTitle" class="ag-panel-title-bar-title ag-${t}-panel-title-bar-title"></span>\n                <div ref="eTitleBarButtons" class="ag-panel-title-bar-buttons ag-${t}-panel-title-bar-buttons"></div>\n            </div>\n            <div ref="eContentWrapper" class="ag-panel-content-wrapper ag-${t}-panel-content-wrapper"></div>\n        </div>`}postConstruct(){const{component:e,closable:t,hideTitleBar:i,title:r,minWidth:n=250,width:s,minHeight:o=250,height:a,centered:l,popup:c,x:u,y:h}=this.config;this.positionableFeature=new Dn(this.getGui(),{minWidth:n,width:s,minHeight:o,height:a,centered:l,x:u,y:h,popup:c,calculateTopBuffer:()=>this.positionableFeature.getHeight()-this.getBodyHeight()}),this.createManagedBean(this.positionableFeature);const d=this.getGui();e&&this.setBodyComponent(e),i?sr(this.eTitleBar,!1):(r&&this.setTitle(r),this.setClosable(null!=t?t:this.closable)),this.addManagedListener(this.eTitleBar,"mousedown",e=>{if(d.contains(e.relatedTarget)||d.contains(this.gos.getActiveDomElement())||this.eTitleBarButtons.contains(e.target))return void e.preventDefault();const t=this.eContentWrapper.querySelector("button, [href], input, select, textarea, [tabindex]");t&&t.focus()}),c&&this.positionableFeature.isPositioned()||(this.renderComponent&&this.renderComponent(),this.positionableFeature.initialisePosition(),this.eContentWrapper.style.height="0")}renderComponent(){const e=this.getGui();e.focus(),this.close=()=>{e.parentElement.removeChild(e),this.destroy()}}getHeight(){return this.positionableFeature.getHeight()}setHeight(e){this.positionableFeature.setHeight(e)}getWidth(){return this.positionableFeature.getWidth()}setWidth(e){this.positionableFeature.setWidth(e)}setClosable(t){if(t!==this.closable&&(this.closable=t),t){const t=this.closeButtonComp=new yn(e.CLOSE_BTN_TEMPLATE);this.getContext().createBean(t);const i=t.getGui(),r=$r("close",this.gos);r.classList.add("ag-panel-title-bar-button-icon"),i.appendChild(r),this.addTitleBarButton(t),t.addManagedListener(i,"click",this.onBtClose.bind(this))}else if(this.closeButtonComp){const e=this.closeButtonComp.getGui();e.parentElement.removeChild(e),this.closeButtonComp=this.destroyBean(this.closeButtonComp)}}setBodyComponent(e){e.setParentComponent(this),this.eContentWrapper.appendChild(e.getGui())}addTitleBarButton(e,t){const i=this.eTitleBarButtons,r=i.children,n=r.length;null==t&&(t=n),t=Math.max(0,Math.min(t,n)),e.addCssClass("ag-panel-title-bar-button");const s=e.getGui();0===t?i.insertAdjacentElement("afterbegin",s):t===n?i.insertAdjacentElement("beforeend",s):r[t-1].insertAdjacentElement("afterend",s),e.setParentComponent(this)}getBodyHeight(){return ur(this.eContentWrapper)}getBodyWidth(){return hr(this.eContentWrapper)}setTitle(e){this.eTitle.innerText=e}onBtClose(){this.close()}destroy(){this.closeButtonComp&&(this.closeButtonComp=this.destroyBean(this.closeButtonComp));const e=this.getGui();e&&Sr(e)&&this.close(),super.destroy()}};lc.CLOSE_BTN_TEMPLATE='<div class="ag-button"></div>',g([Sn("eContentWrapper")],lc.prototype,"eContentWrapper",2),g([Sn("eTitleBar")],lc.prototype,"eTitleBar",2),g([Sn("eTitleBarButtons")],lc.prototype,"eTitleBarButtons",2),g([Sn("eTitle")],lc.prototype,"eTitle",2),g([ae],lc.prototype,"postConstruct",1);var cc=lc,uc=class extends cc{constructor(e){super(d(h({},e),{popup:!0})),this.isMaximizable=!1,this.isMaximized=!1,this.maximizeListeners=[],this.resizeListenerDestroy=null,this.lastPosition={x:0,y:0,width:0,height:0}}postConstruct(){const e=this.getGui(),{movable:t,resizable:i,maximizable:r}=this.config;this.addCssClass("ag-dialog"),super.postConstruct(),this.addManagedListener(e,"focusin",t=>{this.popupService.bringPopupToFront(e)}),t&&this.setMovable(t),r&&this.setMaximizable(r),i&&this.setResizable(i)}renderComponent(){const e=this.getGui(),{alwaysOnTop:t,modal:i,title:r,afterGuiAttached:n}=this.config,s=this.localeService.getLocaleTextFunc(),o=this.popupService.addPopup({modal:i,eChild:e,closeOnEsc:!0,closedCallback:this.onClosed.bind(this),alwaysOnTop:t,ariaLabel:r||s("ariaLabelDialog","Dialog"),afterGuiAttached:n});o&&(this.close=o.hideFunc)}onClosed(e){var t,i;this.destroy(),null==(i=(t=this.config).closedCallback)||i.call(t,e)}toggleMaximize(){const e=this.positionableFeature.getPosition();if(this.isMaximized){const{x:e,y:t,width:i,height:r}=this.lastPosition;this.setWidth(i),this.setHeight(r),this.positionableFeature.offsetElement(e,t)}else this.lastPosition.width=this.getWidth(),this.lastPosition.height=this.getHeight(),this.lastPosition.x=e.x,this.lastPosition.y=e.y,this.positionableFeature.offsetElement(0,0),this.setHeight("100%"),this.setWidth("100%");this.isMaximized=!this.isMaximized,this.refreshMaximizeIcon()}refreshMaximizeIcon(){sr(this.maximizeIcon,!this.isMaximized),sr(this.minimizeIcon,this.isMaximized)}clearMaximizebleListeners(){this.maximizeListeners.length&&(this.maximizeListeners.forEach(e=>e()),this.maximizeListeners.length=0),this.resizeListenerDestroy&&(this.resizeListenerDestroy(),this.resizeListenerDestroy=null)}destroy(){this.maximizeButtonComp=this.destroyBean(this.maximizeButtonComp),this.clearMaximizebleListeners(),super.destroy()}setResizable(e){this.positionableFeature.setResizable(e)}setMovable(e){this.positionableFeature.setMovable(e,this.eTitleBar)}setMaximizable(e){if(!e)return this.clearMaximizebleListeners(),void(this.maximizeButtonComp&&(this.destroyBean(this.maximizeButtonComp),this.maximizeButtonComp=this.maximizeIcon=this.minimizeIcon=void 0));const t=this.eTitleBar;if(!t||e===this.isMaximizable)return;const i=this.buildMaximizeAndMinimizeElements();this.refreshMaximizeIcon(),i.addManagedListener(i.getGui(),"click",this.toggleMaximize.bind(this)),this.addTitleBarButton(i,0),this.maximizeListeners.push(this.addManagedListener(t,"dblclick",this.toggleMaximize.bind(this))),this.resizeListenerDestroy=this.addManagedListener(this,"resize",()=>{this.isMaximized=!1,this.refreshMaximizeIcon()})}buildMaximizeAndMinimizeElements(){const e=this.maximizeButtonComp=this.createBean(new yn('<div class="ag-dialog-button"></span>')),t=e.getGui();return this.maximizeIcon=$r("maximize",this.gos),t.appendChild(this.maximizeIcon),this.maximizeIcon.classList.add("ag-panel-title-bar-button-icon"),this.minimizeIcon=$r("minimize",this.gos),t.appendChild(this.minimizeIcon),this.minimizeIcon.classList.add("ag-panel-title-bar-button-icon"),e}};g([ue("popupService")],uc.prototype,"popupService",2);var hc=0,dc=class extends rt{constructor(){super(...arguments),this.popupList=[]}postConstruct(){this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl}),this.addManagedListener(this.eventService,lt.EVENT_GRID_STYLES_CHANGED,this.handleThemeChange.bind(this))}getPopupParent(){return this.gos.get("popupParent")||this.gridCtrl.getGui()}positionPopupForMenu(e){const{eventSource:t,ePopup:i}=e,r=this.getPopupIndex(i);-1!==r&&(this.popupList[r].alignedToElement=t);const n=t.getBoundingClientRect(),s=this.getParentRect(),o=this.keepXYWithinBounds(i,n.top-s.top,0),a=i.clientWidth>0?i.clientWidth:200;i.style.minWidth=`${a}px`;const l=s.right-s.left-a;let c;function u(){return n.right-s.left-2}function h(){return n.left-s.left-a}this.gos.get("enableRtl")?(c=h(),c<0&&(c=u(),this.setAlignedStyles(i,"left")),c>l&&(c=0,this.setAlignedStyles(i,"right"))):(c=u(),c>l&&(c=h(),this.setAlignedStyles(i,"right")),c<0&&(c=0,this.setAlignedStyles(i,"left"))),i.style.left=`${c}px`,i.style.top=`${o}px`}positionPopupUnderMouseEvent(e){const{ePopup:t,nudgeX:i,nudgeY:r,skipObserver:n}=e;this.positionPopup({ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:!0,skipObserver:n,updatePosition:()=>this.calculatePointerAlign(e.mouseEvent),postProcessCallback:()=>this.callPostProcessPopup(e.type,e.ePopup,null,e.mouseEvent,e.column,e.rowNode)})}calculatePointerAlign(e){const t=this.getParentRect();return{x:e.clientX-t.left,y:e.clientY-t.top}}positionPopupByComponent(e){const{ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:n,eventSource:s,alignSide:o="left",position:a="over",column:l,rowNode:c,type:u}=e,h=s.getBoundingClientRect(),d=this.getParentRect(),p=this.getPopupIndex(t);-1!==p&&(this.popupList[p].alignedToElement=s),this.positionPopup({ePopup:t,nudgeX:i,nudgeY:r,keepWithinBounds:n,updatePosition:()=>{let i,n=h.left-d.left;return"right"===o&&(n-=t.offsetWidth-h.width),"over"===a?(i=h.top-d.top,this.setAlignedStyles(t,"over")):(this.setAlignedStyles(t,"under"),i="under"===this.shouldRenderUnderOrAbove(t,h,d,e.nudgeY||0)?h.top-d.top+h.height:h.top-t.offsetHeight-2*(r||0)-d.top),{x:n,y:i}},postProcessCallback:()=>this.callPostProcessPopup(u,t,s,null,l,c)})}shouldRenderUnderOrAbove(e,t,i,r){const n=i.bottom-t.bottom,s=t.top-i.top,o=e.offsetHeight+r;return n>o?"under":s>o||s>n?"above":"under"}setAlignedStyles(e,t){const i=this.getPopupIndex(e);if(-1===i)return;const r=this.popupList[i],{alignedToElement:n}=r;n&&(["right","left","over","above","under"].forEach(t=>{n.classList.remove(`ag-has-popup-positioned-${t}`),e.classList.remove(`ag-popup-positioned-${t}`)}),t&&(n.classList.add(`ag-has-popup-positioned-${t}`),e.classList.add(`ag-popup-positioned-${t}`)))}callPostProcessPopup(e,t,i,r,n,s){const o=this.gos.getCallback("postProcessPopup");o&&o({column:n,rowNode:s,ePopup:t,type:e,eventSource:i,mouseEvent:r})}positionPopup(e){const{ePopup:t,keepWithinBounds:i,nudgeX:r,nudgeY:n,skipObserver:s,updatePosition:o}=e,a={width:0,height:0},l=(s=!1)=>{let{x:l,y:c}=o();s&&t.clientWidth===a.width&&t.clientHeight===a.height||(a.width=t.clientWidth,a.height=t.clientHeight,r&&(l+=r),n&&(c+=n),i&&(l=this.keepXYWithinBounds(t,l,1),c=this.keepXYWithinBounds(t,c,0)),t.style.left=`${l}px`,t.style.top=`${c}px`,e.postProcessCallback&&e.postProcessCallback())};if(l(),!s){const e=this.resizeObserverService.observeResize(t,()=>l(!0));setTimeout(()=>e(),dc.WAIT_FOR_POPUP_CONTENT_RESIZE)}}getActivePopups(){return this.popupList.map(e=>e.element)}getPopupList(){return this.popupList}getParentRect(){const e=this.gos.getDocument();let t=this.getPopupParent();return t===e.body?t=e.documentElement:"static"===getComputedStyle(t).position&&(t=t.offsetParent),gr(t)}keepXYWithinBounds(e,t,i){const r=0===i,n=r?"clientHeight":"clientWidth",s=r?"top":"left",o=r?"offsetHeight":"offsetWidth",a=r?"scrollTop":"scrollLeft",l=this.gos.getDocument(),c=l.documentElement,u=this.getPopupParent(),h=u.getBoundingClientRect(),d=l.documentElement.getBoundingClientRect(),p=u===l.body,g=e[o];let f=p?(r?dr:pr)(c)+c[a]:u[n];p&&(f-=Math.abs(d[s]-h[s]));const m=f-g;return Math.min(Math.max(t,0),Math.abs(m))}addPopup(e){const t=this.gos.getDocument(),{eChild:i,ariaLabel:r,alwaysOnTop:n,positionCallback:s,anchorToElement:o}=e;if(!t)return console.warn("AG Grid: could not find the document, document is empty"),{hideFunc:()=>{}};const a=this.getPopupIndex(i);if(-1!==a)return{hideFunc:this.popupList[a].hideFunc};this.initialisePopupPosition(i);const l=this.createPopupWrapper(i,r,!!n),c=this.addEventListenersToPopup(d(h({},e),{wrapperEl:l}));return s&&s(),this.addPopupToPopupList(i,l,c,o),{hideFunc:c}}initialisePopupPosition(e){const t=this.getPopupParent().getBoundingClientRect();C(e.style.top)||(e.style.top=-1*t.top+"px"),C(e.style.left)||(e.style.left=-1*t.left+"px")}createPopupWrapper(e,t,i){const r=this.getPopupParent(),n=document.createElement("div"),{allThemes:s}=this.environment.getTheme();return s.length&&n.classList.add(...s),n.classList.add("ag-popup"),e.classList.add(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr","ag-popup-child"),e.hasAttribute("role")||Ht(e,"dialog"),jt(e,t),n.appendChild(e),r.appendChild(n),i?this.setAlwaysOnTop(e,!0):this.bringPopupToFront(e),n}handleThemeChange(){const{allThemes:e}=this.environment.getTheme();for(const t of this.popupList){for(const e of Array.from(t.wrapper.classList))e.startsWith("ag-theme-")&&t.wrapper.classList.remove(e);e.length&&t.wrapper.classList.add(...e)}}addEventListenersToPopup(e){const t=this.gos.getDocument(),i=this.getPopupParent(),{wrapperEl:r,eChild:n,closedCallback:s,afterGuiAttached:o,closeOnEsc:a,modal:l}=e;let c=!1;const u=e=>{r.contains(this.gos.getActiveDomElement())&&(e.key!==Yr.ESCAPE||Ye(e)||p({keyboardEvent:e}))},h=e=>p({mouseEvent:e}),d=e=>p({touchEvent:e}),p=(e={})=>{const{mouseEvent:o,touchEvent:a,keyboardEvent:l,forceHide:p}=e;(p||!this.isEventFromCurrentPopup({mouseEvent:o,touchEvent:a},n)&&!c)&&(c=!0,i.removeChild(r),t.removeEventListener("keydown",u),t.removeEventListener("mousedown",h),t.removeEventListener("touchstart",d),t.removeEventListener("contextmenu",h),this.eventService.removeEventListener(lt.EVENT_DRAG_STARTED,h),s&&s(o||a||l),this.removePopupFromPopupList(n))};return o&&o({hidePopup:p}),window.setTimeout(()=>{a&&t.addEventListener("keydown",u),l&&(t.addEventListener("mousedown",h),this.eventService.addEventListener(lt.EVENT_DRAG_STARTED,h),t.addEventListener("touchstart",d),t.addEventListener("contextmenu",h))},0),p}addPopupToPopupList(e,t,i,r){this.popupList.push({element:e,wrapper:t,hideFunc:i,instanceId:hc++,isAnchored:!!r}),r&&this.setPopupPositionRelatedToElement(e,r)}getPopupIndex(e){return this.popupList.findIndex(t=>t.element===e)}setPopupPositionRelatedToElement(e,t){const i=this.getPopupIndex(e);if(-1===i)return;const r=this.popupList[i];if(r.stopAnchoringPromise&&r.stopAnchoringPromise.then(e=>e&&e()),r.stopAnchoringPromise=void 0,r.isAnchored=!1,!t)return;const n=this.keepPopupPositionedRelativeTo({element:t,ePopup:e,hidePopup:r.hideFunc});return r.stopAnchoringPromise=n,r.isAnchored=!0,n}removePopupFromPopupList(e){this.setAlignedStyles(e,null),this.setPopupPositionRelatedToElement(e,null),this.popupList=this.popupList.filter(t=>t.element!==e)}keepPopupPositionedRelativeTo(e){const t=this.getPopupParent(),i=t.getBoundingClientRect(),{element:r,ePopup:n}=e,s=r.getBoundingClientRect(),o=i.top-s.top,a=i.left-s.left;let l=o,c=a;const u=n.style.top,h=parseInt(u.substring(0,u.length-1),10),d=n.style.left,p=parseInt(d.substring(0,d.length-1),10);return new hn(i=>{this.getFrameworkOverrides().setInterval(()=>{const i=t.getBoundingClientRect(),s=r.getBoundingClientRect();if(0==s.top&&0==s.left&&0==s.height&&0==s.width)return void e.hidePopup();const u=i.top-s.top;if(u!=l){const e=this.keepXYWithinBounds(n,h+o-u,0);n.style.top=`${e}px`}l=u;const d=i.left-s.left;if(d!=c){const e=this.keepXYWithinBounds(n,p+a-d,1);n.style.left=`${e}px`}c=d},200).then(e=>{i(()=>{null!=e&&window.clearInterval(e)})})})}hasAnchoredPopup(){return this.popupList.some(e=>e.isAnchored)}isEventFromCurrentPopup(e,t){const{mouseEvent:i,touchEvent:r}=e,n=i||r;if(!n)return!1;const s=this.getPopupIndex(t);if(-1===s)return!1;for(let e=s;e<this.popupList.length;e++)if(Ze(this.popupList[e].element,n))return!0;return this.isElementWithinCustomPopup(n.target)}isElementWithinCustomPopup(e){const t=this.gos.getDocument();for(;e&&e!==t.body;){if(e.classList.contains("ag-custom-component-popup")||null===e.parentElement)return!0;e=e.parentElement}return!1}getWrapper(e){for(;!e.classList.contains("ag-popup")&&e.parentElement;)e=e.parentElement;return e.classList.contains("ag-popup")?e:null}setAlwaysOnTop(e,t){const i=this.getWrapper(e);i&&(i.classList.toggle("ag-always-on-top",!!t),t&&this.bringPopupToFront(i))}bringPopupToFront(e){const t=this.getPopupParent(),i=Array.prototype.slice.call(t.querySelectorAll(".ag-popup")),r=i.length,n=Array.prototype.slice.call(t.querySelectorAll(".ag-popup.ag-always-on-top")),s=n.length,o=this.getWrapper(e);if(!o||r<=1||!t.contains(e))return;const a=i.indexOf(o),l=o.querySelectorAll("div"),c=[];for(l.forEach(e=>{0!==e.scrollTop&&c.push([e,e.scrollTop])}),s?o.classList.contains("ag-always-on-top")?a!==r-1&&_e(n).insertAdjacentElement("afterend",o):a!==r-s-1&&n[0].insertAdjacentElement("beforebegin",o):a!==r-1&&_e(i).insertAdjacentElement("afterend",o);c.length;){const e=c.pop();e[0].scrollTop=e[1]}}};dc.WAIT_FOR_POPUP_CONTENT_RESIZE=200,g([ue("focusService")],dc.prototype,"focusService",2),g([ue("ctrlsService")],dc.prototype,"ctrlsService",2),g([ue("resizeObserverService")],dc.prototype,"resizeObserverService",2),g([ae],dc.prototype,"postConstruct",1),dc=g([ce("popupService")],dc);var pc=class extends yn{constructor(){super('\n        <div class="ag-autocomplete-row" role="presentation">\n            <div class="ag-autocomplete-row-label"></div>\n        </div>'),this.hasHighlighting=!1}setState(e,t){this.value=e,this.render(),this.updateSelected(t)}updateSelected(e){this.addOrRemoveCssClass("ag-autocomplete-row-selected",e)}setSearchString(e){var t;let i=!1;if(C(e)){const r=null==(t=this.value)?void 0:t.toLocaleLowerCase().indexOf(e.toLocaleLowerCase());if(r>=0){i=!0,this.hasHighlighting=!0;const t=r+e.length,n=Ct(this.value.slice(0,r)),s=Ct(this.value.slice(r,t)),o=Ct(this.value.slice(t));this.getGui().lastElementChild.innerHTML=`${n}<b>${s}</b>${o}`}}!i&&this.hasHighlighting&&(this.hasHighlighting=!1,this.render())}render(){var e;this.getGui().lastElementChild.innerHTML=null!=(e=Ct(this.value))?e:"&nbsp;"}},gc=class e extends Es{constructor(t){super(e.TEMPLATE),this.params=t,this.searchString=""}destroy(){super.destroy()}init(){this.autocompleteEntries=this.params.autocompleteEntries,this.virtualList=this.createManagedBean(new Yl({cssIdentifier:"autocomplete"})),this.virtualList.setComponentCreator(this.createRowComponent.bind(this)),this.eList.appendChild(this.virtualList.getGui()),this.virtualList.setModel({getRowCount:()=>this.autocompleteEntries.length,getRow:e=>this.autocompleteEntries[e]});const e=this.virtualList.getGui();this.addManagedListener(e,"click",()=>this.params.onConfirmed()),this.addManagedListener(e,"mousemove",this.onMouseMove.bind(this)),this.addManagedListener(e,"mousedown",e=>e.preventDefault()),this.setSelectedValue(0)}onNavigationKeyDown(e,t){e.preventDefault();const i=this.autocompleteEntries.indexOf(this.selectedValue),r=t===Yr.UP?i-1:i+1;this.checkSetSelectedValue(r)}setSearch(e){this.searchString=e,C(e)?this.runSearch():(this.autocompleteEntries=this.params.autocompleteEntries,this.virtualList.refresh(),this.checkSetSelectedValue(0)),this.updateSearchInList()}runContainsSearch(e,t){let i,r=!1;const n=e.toLocaleLowerCase(),s=t.filter(e=>{const t=e.toLocaleLowerCase().indexOf(n),s=0===t,o=t>=0;return o&&(!i||!r&&s||r===s&&e.length<i.length)&&(i=e,r=s),o});return!i&&s.length&&(i=s[0]),{topMatch:i,allMatches:s}}runSearch(){var e,t;const{autocompleteEntries:i}=this.params,r=i.map(e=>{var t;return null!=(t=e.displayValue)?t:e.key});let n,s;if(this.params.useFuzzySearch)n=zr(this.searchString,r,!0).values,s=n.length?n[0]:void 0;else{const e=this.runContainsSearch(this.searchString,r);n=e.allMatches,s=e.topMatch}let o=i.filter(({key:e,displayValue:t})=>n.includes(null!=t?t:e));if(!o.length&&this.selectedValue&&(null==(t=null==(e=this.params)?void 0:e.forceLastSelection)?void 0:t.call(e,this.selectedValue,this.searchString))&&(o=[this.selectedValue]),this.autocompleteEntries=o,this.virtualList.refresh(),!s)return;const a=n.indexOf(s);this.checkSetSelectedValue(a)}updateSearchInList(){this.virtualList.forEachRenderedRow(e=>e.setSearchString(this.searchString))}checkSetSelectedValue(e){e>=0&&e<this.autocompleteEntries.length&&this.setSelectedValue(e)}setSelectedValue(e){const t=this.autocompleteEntries[e];this.selectedValue!==t&&(this.selectedValue=t,this.virtualList.ensureIndexVisible(e),this.virtualList.forEachRenderedRow((t,i)=>{t.updateSelected(e===i)}))}createRowComponent(e){var t;const i=new pc;return this.getContext().createBean(i),i.setState(null!=(t=e.displayValue)?t:e.key,e===this.selectedValue),i}onMouseMove(e){const t=this.virtualList.getGui().getBoundingClientRect(),i=this.virtualList.getScrollTop(),r=e.clientY-t.top+i,n=Math.floor(r/this.virtualList.getRowHeight());this.checkSetSelectedValue(n)}afterGuiAttached(){this.virtualList.refresh()}getSelectedValue(){var e;return this.autocompleteEntries.length&&null!=(e=this.selectedValue)?e:null}};gc.TEMPLATE='<div class="ag-autocomplete-list-popup">\n            <div ref="eList" class="ag-autocomplete-list"></div>\n        <div>',g([Sn("eList")],gc.prototype,"eList",2),g([ae],gc.prototype,"init",1);var fc=gc,mc=class e extends yn{constructor(){super('\n            <div class="ag-autocomplete" role="presentation">\n                <ag-input-text-field ref="eAutocompleteInput"></ag-input-text-field>\n            </div>'),this.isListOpen=!1,this.lastPosition=0,this.valid=!0}postConstruct(){this.eAutocompleteInput.onValueChange(e=>this.onValueChanged(e)),this.eAutocompleteInput.getInputElement().setAttribute("autocomplete","off"),this.addGuiEventListener("keydown",this.onKeyDown.bind(this)),this.addGuiEventListener("click",this.updatePositionAndList.bind(this)),this.addDestroyFunc(()=>{this.destroyBean(this.autocompleteList)}),this.addGuiEventListener("focusout",()=>this.onFocusOut())}onValueChanged(e){const t=v(e);this.updateValue(t),this.updateAutocompleteList(t)}updateValue(t){this.updateLastPosition(),this.dispatchEvent({type:e.EVENT_VALUE_CHANGED,value:t}),this.validate(t)}updateAutocompleteList(e){var t,i,r,n;const s=null!=(i=null==(t=this.listGenerator)?void 0:t.call(this,e,this.lastPosition))?i:{enabled:!1};if(s.type&&s.type===(null==(r=this.autocompleteListParams)?void 0:r.type)||this.isListOpen&&this.closeList(),this.autocompleteListParams=s,null==(n=this.autocompleteListParams)?void 0:n.enabled){this.isListOpen||this.openList();const{searchString:e}=this.autocompleteListParams;this.autocompleteList.setSearch(null!=e?e:"")}else this.isListOpen&&this.closeList()}onKeyDown(e){const t=e.key;switch(this.updateLastPosition(),t){case Yr.ENTER:this.onEnterKeyDown(e);break;case Yr.TAB:this.onTabKeyDown(e);break;case Yr.DOWN:case Yr.UP:this.onUpDownKeyDown(e,t);break;case Yr.LEFT:case Yr.RIGHT:case Yr.PAGE_HOME:case Yr.PAGE_END:setTimeout(()=>{this.updatePositionAndList()});break;case Yr.ESCAPE:this.onEscapeKeyDown(e);break;case Yr.SPACE:e.ctrlKey&&!this.isListOpen&&(e.preventDefault(),this.forceOpenList())}}confirmSelection(){var t;const i=null==(t=this.autocompleteList)?void 0:t.getSelectedValue();i&&(this.closeList(),this.dispatchEvent({type:e.EVENT_OPTION_SELECTED,value:this.getValue(),position:this.lastPosition,updateEntry:i,autocompleteType:this.autocompleteListParams.type}))}onTabKeyDown(e){this.isListOpen&&(e.preventDefault(),e.stopPropagation(),this.confirmSelection())}onEnterKeyDown(e){e.preventDefault(),this.isListOpen?this.confirmSelection():this.onCompleted()}onUpDownKeyDown(e,t){var i;e.preventDefault(),this.isListOpen?null==(i=this.autocompleteList)||i.onNavigationKeyDown(e,t):this.forceOpenList()}onEscapeKeyDown(e){this.isListOpen&&(e.preventDefault(),e.stopPropagation(),this.closeList(),this.setCaret(this.lastPosition,!0))}onFocusOut(){this.isListOpen&&this.closeList()}updatePositionAndList(){var e;this.updateLastPosition(),this.updateAutocompleteList(null!=(e=this.eAutocompleteInput.getValue())?e:null)}setCaret(e,t){const i=this.gos.getDocument(),r=this.gos.getActiveDomElement();!t||r&&r!==i.body||this.eAutocompleteInput.getFocusableElement().focus();const n=this.eAutocompleteInput.getInputElement();n.setSelectionRange(e,e),e===n.value.length&&(n.scrollLeft=n.scrollWidth)}forceOpenList(){this.onValueChanged(this.eAutocompleteInput.getValue())}updateLastPosition(){var e;this.lastPosition=null!=(e=this.eAutocompleteInput.getInputElement().selectionStart)?e:0}validate(t){var i;this.validator&&(this.validationMessage=this.validator(t),this.eAutocompleteInput.getInputElement().setCustomValidity(null!=(i=this.validationMessage)?i:""),this.valid=!this.validationMessage,this.dispatchEvent({type:e.EVENT_VALID_CHANGED,isValid:this.valid,validationMessage:this.validationMessage}))}openList(){this.isListOpen=!0,this.autocompleteList=this.createBean(new fc({autocompleteEntries:this.autocompleteListParams.entries,onConfirmed:()=>this.confirmSelection(),forceLastSelection:this.forceLastSelection}));const e=this.autocompleteList.getGui(),t={ePopup:e,type:"autocomplete",eventSource:this.getGui(),position:"under",alignSide:this.gos.get("enableRtl")?"right":"left",keepWithinBounds:!0},i=this.popupService.addPopup({eChild:e,anchorToElement:this.getGui(),positionCallback:()=>this.popupService.positionPopupByComponent(t),ariaLabel:this.listAriaLabel});this.hidePopup=i.hideFunc,this.autocompleteList.afterGuiAttached()}closeList(){this.isListOpen=!1,this.hidePopup(),this.destroyBean(this.autocompleteList),this.autocompleteList=null}onCompleted(){this.isListOpen&&this.closeList(),this.dispatchEvent({type:e.EVENT_VALUE_CONFIRMED,value:this.getValue(),isValid:this.isValid()})}getValue(){return v(this.eAutocompleteInput.getValue())}setInputPlaceholder(e){return this.eAutocompleteInput.setInputPlaceholder(e),this}setInputAriaLabel(e){return this.eAutocompleteInput.setInputAriaLabel(e),this}setListAriaLabel(e){return this.listAriaLabel=e,this}setListGenerator(e){return this.listGenerator=e,this}setValidator(e){return this.validator=e,this}isValid(){return this.valid}setValue(e){const{value:t,position:i,silent:r,updateListOnlyIfOpen:n,restoreFocus:s}=e;this.eAutocompleteInput.setValue(t,!0),this.setCaret(null!=i?i:this.lastPosition,s),r||this.updateValue(t),n&&!this.isListOpen||this.updateAutocompleteList(t)}setForceLastSelection(e){return this.forceLastSelection=e,this}setInputDisabled(e){return this.eAutocompleteInput.setDisabled(e),this}};mc.EVENT_VALUE_CHANGED="eventValueChanged",mc.EVENT_VALUE_CONFIRMED="eventValueConfirmed",mc.EVENT_OPTION_SELECTED="eventOptionSelected",mc.EVENT_VALID_CHANGED="eventValidChanged",g([ue("popupService")],mc.prototype,"popupService",2),g([Sn("eAutocompleteInput")],mc.prototype,"eAutocompleteInput",2),g([ae],mc.prototype,"postConstruct",1);var vc=mc,Cc=class e extends yn{constructor(e,t,i,r){super(),this.dragSourceDropTarget=e,this.ghost=t,this.horizontal=i,this.template=r}init(){var t;this.setTemplate(null!=(t=this.template)?t:e.TEMPLATE);const i=this.getGui();this.addElementClasses(i),this.addElementClasses(this.eDragHandle,"drag-handle"),this.addElementClasses(this.eText,"text"),this.addElementClasses(this.eButton,"button"),this.eDragHandle.appendChild($r("columnDrag",this.gos)),this.eButton.appendChild($r("cancel",this.gos)),this.setupComponents(),!this.ghost&&this.isDraggable()&&this.addDragSource(),this.setupAria(),this.setupTooltip(),this.activateTabIndex(),this.refreshDraggable()}isDraggable(){return!0}refreshDraggable(){this.eDragHandle.classList.toggle("ag-column-select-column-readonly",!this.isDraggable())}setupAria(){const e=this.localeService.getLocaleTextFunc(),t=[this.getAriaDisplayName()];this.addAdditionalAriaInstructions(t,e),jt(this.getGui(),t.join(". "))}addAdditionalAriaInstructions(e,t){if(this.isRemovable()){const i=t("ariaDropZoneColumnComponentDescription","Press DELETE to remove");e.push(i)}}setupTooltip(){const e=()=>{const e=this.getTooltip();this.setTooltip({newTooltipText:e})};e(),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,e)}getDragSourceId(){}getDefaultIconName(){return Gs.ICON_NOT_ALLOWED}addDragSource(){const{dragAndDropService:e,eDragHandle:t}=this,i=this.createGetDragItem(),r=this.getDefaultIconName(),n={type:this.getDragSourceType(),sourceId:this.getDragSourceId(),eElement:t,getDefaultIconName:()=>r,getDragItem:i,dragItemName:this.getDisplayName()};e.addDragSource(n,!0),this.addDestroyFunc(()=>e.removeDragSource(n))}setupComponents(){this.setTextValue(),this.setupRemove(),this.ghost&&this.addCssClass("ag-column-drop-cell-ghost")}isRemovable(){return!0}refreshRemove(){sr(this.eButton,this.isRemovable())}setupRemove(){this.refreshRemove();const t={type:e.EVENT_COLUMN_REMOVE};this.addGuiEventListener("keydown",e=>this.onKeyDown(e)),this.addManagedListener(this.eButton,"click",e=>{this.dispatchEvent(t),e.stopPropagation()});const i=new ms(this.eButton);this.addManagedListener(i,ms.EVENT_TAP,()=>{this.dispatchEvent(t)}),this.addDestroyFunc(i.destroy.bind(i))}onKeyDown(t){t.key===Yr.DELETE&&this.isRemovable()&&(t.preventDefault(),this.dispatchEvent({type:e.EVENT_COLUMN_REMOVE}))}getDisplayValue(){return this.getDisplayName()}setTextValue(){const e=Ct(this.getDisplayValue());this.eText.innerHTML=e}addElementClasses(e,t){t=t?`-${t}`:"";const i=this.horizontal?"horizontal":"vertical";e.classList.add(`ag-column-drop-cell${t}`,`ag-column-drop-${i}-cell${t}`)}destroy(){super.destroy(),this.dragSourceDropTarget=null}};Cc.EVENT_COLUMN_REMOVE="columnRemove",Cc.TEMPLATE='<span role="option">\n          <span ref="eDragHandle" class="ag-drag-handle ag-column-drop-cell-drag-handle" role="presentation"></span>\n          <span ref="eText" class="ag-column-drop-cell-text" aria-hidden="true"></span>\n          <span ref="eButton" class="ag-column-drop-cell-button" role="presentation"></span>\n        </span>',g([ue("dragAndDropService")],Cc.prototype,"dragAndDropService",2),g([Sn("eText")],Cc.prototype,"eText",2),g([Sn("eDragHandle")],Cc.prototype,"eDragHandle",2),g([Sn("eButton")],Cc.prototype,"eButton",2),g([ae],Cc.prototype,"init",1);var yc=Cc,wc=class e extends yn{constructor(t){super('<div class="ag-unselectable" role="presentation"></div>'),this.horizontal=t,this.state=e.STATE_NOT_DRAGGING,this.guiDestroyFunctions=[],this.childPillComponents=[],this.resizeEnabled=!1,this.addElementClasses(this.getGui()),this.ePillDropList=document.createElement("div"),this.addElementClasses(this.ePillDropList,"list"),Ht(this.ePillDropList,"listbox")}isHorizontal(){return this.horizontal}toggleResizable(e){this.positionableFeature.setResizable(!!e&&{bottom:!0}),this.resizeEnabled=e}isSourceEventFromTarget(e){const{dropZoneTarget:t,dragSource:i}=e;return t.contains(i.eElement)}destroy(){this.destroyGui(),super.destroy()}destroyGui(){this.guiDestroyFunctions.forEach(e=>e()),this.guiDestroyFunctions.length=0,this.childPillComponents.length=0,Cr(this.getGui()),Cr(this.ePillDropList)}init(e){this.params=null!=e?e:{},this.createManagedBean(new _n(this.getFocusableElement(),{handleKeyDown:this.handleKeyDown.bind(this)})),this.setupDropTarget(),this.positionableFeature=new Dn(this.getGui(),{minHeight:100}),this.createManagedBean(this.positionableFeature),this.refreshGui(),jt(this.ePillDropList,this.getAriaLabel())}handleKeyDown(e){const t=!this.horizontal;let i=e.key===Yr.DOWN,r=e.key===Yr.UP;if(!t){const t=this.gos.get("enableRtl");i=!t&&e.key===Yr.RIGHT||t&&e.key===Yr.LEFT,r=!t&&e.key===Yr.LEFT||t&&e.key===Yr.RIGHT}if(!i&&!r)return;const n=this.focusService.findNextFocusableElement(this.getFocusableElement(),!1,r);n&&(e.preventDefault(),n.focus())}addElementClasses(e,t){t=t?`-${t}`:"";const i=this.horizontal?"horizontal":"vertical";e.classList.add(`ag-column-drop${t}`,`ag-column-drop-${i}${t}`)}setupDropTarget(){this.dropTarget={getContainer:this.getGui.bind(this),getIconName:this.getIconName.bind(this),onDragging:this.onDragging.bind(this),onDragEnter:this.onDragEnter.bind(this),onDragLeave:this.onDragLeave.bind(this),onDragStop:this.onDragStop.bind(this),isInterestedIn:this.isInterestedIn.bind(this)},this.dragAndDropService.addDropTarget(this.dropTarget)}minimumAllowedNewInsertIndex(){return 0}checkInsertIndex(e){const t=this.getNewInsertIndex(e);if(t<0)return!1;const i=this.minimumAllowedNewInsertIndex(),r=Math.max(i,t),n=r!==this.insertIndex;return n&&(this.insertIndex=r),n}getNewInsertIndex(e){const t=e.event,i=this.horizontal?t.clientX:t.clientY,r=this.childPillComponents.map(e=>e.getGui().getBoundingClientRect()),n=r.findIndex(e=>this.horizontal?e.right>i&&e.left<i:e.top<i&&e.bottom>i);if(-1===n){const e=this.gos.get("enableRtl");return r.every(e=>i>(this.horizontal?e.right:e.bottom))?e&&this.horizontal?0:this.childPillComponents.length:r.every(e=>i<(this.horizontal?e.left:e.top))?e&&this.horizontal?this.childPillComponents.length:0:this.insertIndex}return this.insertIndex<=n?n+1:n}checkDragStartedBySelf(t){this.state===e.STATE_NOT_DRAGGING&&(this.state=e.STATE_REARRANGE_ITEMS,this.potentialDndItems=this.getItems(t.dragSource.getDragItem()),this.refreshGui(),this.checkInsertIndex(t),this.refreshGui())}onDragging(e){this.checkDragStartedBySelf(e),this.checkInsertIndex(e)&&this.refreshGui()}handleDragEnterEnd(e){}onDragEnter(t){const i=this.getItems(t.dragSource.getDragItem());this.state=e.STATE_NEW_ITEMS_IN;const r=i.filter(e=>this.isItemDroppable(e,t)),n=r.every(e=>-1!==this.childPillComponents.map(e=>e.getItem()).indexOf(e));0!==r.length&&(this.potentialDndItems=r,n?this.state=e.STATE_NOT_DRAGGING:(this.handleDragEnterEnd(t),this.checkInsertIndex(t),this.refreshGui()))}isPotentialDndItems(){return Re(this.potentialDndItems)}handleDragLeaveEnd(e){}onDragLeave(t){if(this.state===e.STATE_REARRANGE_ITEMS){const e=this.getItems(t.dragSource.getDragItem());this.removeItems(e)}this.isPotentialDndItems()&&(this.handleDragLeaveEnd(t),this.potentialDndItems=[],this.refreshGui()),this.state=e.STATE_NOT_DRAGGING}refreshOnDragStop(){return!0}onDragStop(){if(this.isPotentialDndItems()){let t=!1;this.state===e.STATE_NEW_ITEMS_IN?(this.addItems(this.potentialDndItems),t=!0):t=this.rearrangeItems(this.potentialDndItems),this.potentialDndItems=[],!this.refreshOnDragStop()&&t||this.refreshGui()}this.state=e.STATE_NOT_DRAGGING}removeItems(e){const t=this.getExistingItems().filter(t=>!He(e,t));this.updateItems(t)}addItems(e){if(!e)return;const t=this.getExistingItems().slice(),i=e.filter(e=>t.indexOf(e)<0);Ge(t,i,this.insertIndex),this.updateItems(t)}addItem(e){this.insertIndex=this.getExistingItems().length,this.addItems([e]),this.refreshGui()}rearrangeItems(e){const t=this.getNonGhostItems().slice();return Ge(t,e,this.insertIndex),!Pe(t,this.getExistingItems())&&(this.updateItems(t),!0)}refreshGui(){const e=this.ePillDropList.scrollTop,t=this.resizeEnabled,i=this.getFocusedItem();let r=this.focusService.findNextFocusableElement();r||(r=this.focusService.findNextFocusableElement(void 0,!1,!0)),this.toggleResizable(!1),this.destroyGui(),this.addIconAndTitleToGui(),this.addEmptyMessageToGui(),this.addItemsToGui(),this.isHorizontal()||(this.ePillDropList.scrollTop=e),t&&this.toggleResizable(t),this.focusService.isKeyboardMode()&&this.restoreFocus(i,r)}getFocusedItem(){const e=this.getGui(),t=this.gos.getActiveDomElement();return e.contains(t)?Array.from(e.querySelectorAll(".ag-column-drop-cell")).indexOf(t):-1}restoreFocus(e,t){const i=this.getGui(),r=Array.from(i.querySelectorAll(".ag-column-drop-cell"));if(-1===e)return;0===r.length&&t.focus();const n=r[Math.min(r.length-1,e)];n&&n.focus()}focusList(e){const t=e?this.childPillComponents.length-1:0;this.restoreFocus(t,this.getFocusableElement())}getNonGhostItems(){const e=this.getExistingItems();return this.isPotentialDndItems()?e.filter(e=>!He(this.potentialDndItems,e)):e}addItemsToGui(){const e=this.getNonGhostItems().map(e=>this.createItemComponent(e,!1));if(this.isPotentialDndItems()){const t=this.potentialDndItems.map(e=>this.createItemComponent(e,!0));this.insertIndex>=e.length?e.push(...t):e.splice(this.insertIndex,0,...t)}this.appendChild(this.ePillDropList),e.forEach((e,t)=>{t>0&&this.addArrow(this.ePillDropList),this.ePillDropList.appendChild(e.getGui())}),this.addAriaLabelsToComponents()}addAriaLabelsToComponents(){this.childPillComponents.forEach((e,t)=>{const i=e.getGui();ni(i,t+1),ri(i,this.childPillComponents.length)})}createItemComponent(e,t){const i=this.createPillComponent(e,this.dropTarget,t,this.horizontal);return i.addEventListener(yc.EVENT_COLUMN_REMOVE,this.removeItems.bind(this,[e])),this.context.createBean(i),this.guiDestroyFunctions.push(()=>this.destroyBean(i)),t||this.childPillComponents.push(i),i}addIconAndTitleToGui(){const{title:e,icon:t}=this.params;if(!e||!t)return;const i=document.createElement("div");if(Jt(i,!0),this.addElementClasses(i,"title-bar"),this.addElementClasses(t,"icon"),this.addOrRemoveCssClass("ag-column-drop-empty",this.isExistingItemsEmpty()),i.appendChild(t),!this.horizontal){const t=document.createElement("span");this.addElementClasses(t,"title"),t.innerHTML=e,i.appendChild(t)}this.appendChild(i)}isExistingItemsEmpty(){return 0===this.getExistingItems().length}addEmptyMessageToGui(){const{emptyMessage:e}=this.params;if(!e||!this.isExistingItemsEmpty()||this.isPotentialDndItems())return;const t=document.createElement("span");t.innerHTML=e,this.addElementClasses(t,"empty-message"),this.ePillDropList.appendChild(t)}addArrow(e){if(this.horizontal){const t=$r(this.gos.get("enableRtl")?"smallLeft":"smallRight",this.gos);this.addElementClasses(t,"cell-separator"),e.appendChild(t)}}};wc.STATE_NOT_DRAGGING="notDragging",wc.STATE_NEW_ITEMS_IN="newItemsIn",wc.STATE_REARRANGE_ITEMS="rearrangeItems",g([ue("focusService")],wc.prototype,"focusService",2),g([ue("dragAndDropService")],wc.prototype,"dragAndDropService",2);var Sc=wc,bc=["touchstart","touchend","touchmove","touchcancel"],Ec=class{constructor(e="javascript"){this.frameworkName=e,this.renderingEngine="vanilla",this.wrapIncoming=e=>e(),this.wrapOutgoing=e=>e()}setInterval(e,t){return new hn(i=>{i(window.setInterval(e,t))})}addEventListener(e,t,i,r){const n=He(bc,t);e.addEventListener(t,i,{capture:!!r,passive:n})}get shouldWrapOutgoing(){return!1}frameworkComponent(e){return null}isFrameworkComponent(e){return!1}getDocLink(e){return`https://www.ag-grid.com/${"solid"===this.frameworkName?"react":this.frameworkName}-data-grid${e?`/${e}`:""}`}},Ac=class extends rt{getNextCellToFocus(e,t,i=!1){return i?this.getNextCellToFocusWithCtrlPressed(e,t):this.getNextCellToFocusWithoutCtrlPressed(e,t)}getNextCellToFocusWithCtrlPressed(e,t){const i=e===Yr.UP,r=e===Yr.DOWN,n=e===Yr.LEFT;let s,o;if(i||r)o=i?this.paginationProxy.getPageFirstRow():this.paginationProxy.getPageLastRow(),s=t.column;else{const e=this.columnModel.getAllDisplayedColumns(),i=this.gos.get("enableRtl");o=t.rowIndex,s=n!==i?e[0]:_e(e)}return{rowIndex:o,rowPinned:null,column:s}}getNextCellToFocusWithoutCtrlPressed(e,t){let i=t,r=!1;for(;!r;){switch(e){case Yr.UP:i=this.getCellAbove(i);break;case Yr.DOWN:i=this.getCellBelow(i);break;case Yr.RIGHT:i=this.gos.get("enableRtl")?this.getCellToLeft(i):this.getCellToRight(i);break;case Yr.LEFT:i=this.gos.get("enableRtl")?this.getCellToRight(i):this.getCellToLeft(i);break;default:i=null,console.warn("AG Grid: unknown key for navigation "+e)}r=!i||this.isCellGoodToFocusOn(i)}return i}isCellGoodToFocusOn(e){const t=e.column;let i;switch(e.rowPinned){case"top":i=this.pinnedRowModel.getPinnedTopRow(e.rowIndex);break;case"bottom":i=this.pinnedRowModel.getPinnedBottomRow(e.rowIndex);break;default:i=this.rowModel.getRow(e.rowIndex)}return!!i&&!t.isSuppressNavigable(i)}getCellToLeft(e){if(!e)return null;const t=this.columnModel.getDisplayedColBefore(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getCellToRight(e){if(!e)return null;const t=this.columnModel.getDisplayedColAfter(e.column);return t?{rowIndex:e.rowIndex,column:t,rowPinned:e.rowPinned}:null}getRowBelow(e){const t=e.rowIndex,i=e.rowPinned;if(this.isLastRowInContainer(e))switch(i){case"bottom":return null;case"top":return this.rowModel.isRowsToRender()?{rowIndex:this.paginationProxy.getPageFirstRow(),rowPinned:null}:this.pinnedRowModel.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null;default:return this.pinnedRowModel.isRowsToRender("bottom")?{rowIndex:0,rowPinned:"bottom"}:null}const r=this.rowModel.getRow(e.rowIndex);return this.getNextStickyPosition(r)||{rowIndex:t+1,rowPinned:i}}getNextStickyPosition(e,t){if(!this.gos.isGroupRowsSticky()||!e||!e.sticky)return;let i=[];i=this.rowRenderer.getStickyTopRowCtrls().some(t=>t.getRowNode().rowIndex===e.rowIndex)?[...this.rowRenderer.getStickyTopRowCtrls()].sort((e,t)=>e.getRowNode().rowIndex-t.getRowNode().rowIndex):[...this.rowRenderer.getStickyBottomRowCtrls()].sort((e,t)=>t.getRowNode().rowIndex-e.getRowNode().rowIndex);const r=t?-1:1,n=i.findIndex(t=>t.getRowNode().rowIndex===e.rowIndex),s=i[n+r];return s?{rowIndex:s.getRowNode().rowIndex,rowPinned:null}:void 0}getCellBelow(e){if(!e)return null;const t=this.getRowBelow(e);return t?{rowIndex:t.rowIndex,column:e.column,rowPinned:t.rowPinned}:null}isLastRowInContainer(e){const t=e.rowPinned,i=e.rowIndex;return"top"===t?this.pinnedRowModel.getPinnedTopRowData().length-1<=i:"bottom"===t?this.pinnedRowModel.getPinnedBottomRowData().length-1<=i:this.paginationProxy.getPageLastRow()<=i}getRowAbove(e){const t=e.rowIndex,i=e.rowPinned;if(i?0===t:t===this.paginationProxy.getPageFirstRow())return"top"===i?null:i&&this.rowModel.isRowsToRender()?this.getLastBodyCell():this.pinnedRowModel.isRowsToRender("top")?this.getLastFloatingTopRow():null;const r=this.rowModel.getRow(e.rowIndex);return this.getNextStickyPosition(r,!0)||{rowIndex:t-1,rowPinned:i}}getCellAbove(e){if(!e)return null;const t=this.getRowAbove({rowIndex:e.rowIndex,rowPinned:e.rowPinned});return t?{rowIndex:t.rowIndex,column:e.column,rowPinned:t.rowPinned}:null}getLastBodyCell(){return{rowIndex:this.paginationProxy.getPageLastRow(),rowPinned:null}}getLastFloatingTopRow(){return{rowIndex:this.pinnedRowModel.getPinnedTopRowData().length-1,rowPinned:"top"}}getNextTabbedCell(e,t){return t?this.getNextTabbedCellBackwards(e):this.getNextTabbedCellForwards(e)}getNextTabbedCellForwards(e){const t=this.columnModel.getAllDisplayedColumns();let i=e.rowIndex,r=e.rowPinned,n=this.columnModel.getDisplayedColAfter(e.column);if(!n){n=t[0];const s=this.getRowBelow(e);if(y(s))return null;if(!s.rowPinned&&!this.paginationProxy.isRowInPage(s))return null;i=s?s.rowIndex:null,r=s?s.rowPinned:null}return{rowIndex:i,column:n,rowPinned:r}}getNextTabbedCellBackwards(e){const t=this.columnModel.getAllDisplayedColumns();let i=e.rowIndex,r=e.rowPinned,n=this.columnModel.getDisplayedColBefore(e.column);if(!n){n=_e(t);const s=this.getRowAbove({rowIndex:e.rowIndex,rowPinned:e.rowPinned});if(y(s))return null;if(!s.rowPinned&&!this.paginationProxy.isRowInPage(s))return null;i=s?s.rowIndex:null,r=s?s.rowPinned:null}return{rowIndex:i,column:n,rowPinned:r}}};g([ue("columnModel")],Ac.prototype,"columnModel",2),g([ue("rowModel")],Ac.prototype,"rowModel",2),g([ue("rowRenderer")],Ac.prototype,"rowRenderer",2),g([ue("pinnedRowModel")],Ac.prototype,"pinnedRowModel",2),g([ue("paginationProxy")],Ac.prototype,"paginationProxy",2),Ac=g([ce("cellNavigationService")],Ac);var Tc=class extends rt{constructor(){super(...arguments),this.consuming=!1}setBeans(e){this.logger=e.create("AlignedGridsService")}getAlignedGridApis(){var e;let t=null!=(e=this.gos.get("alignedGrids"))?e:[];const i="function"==typeof t;"function"==typeof t&&(t=t());const r=()=>`See ${this.getFrameworkOverrides().getDocLink("aligned-grids")}`;return t.map(e=>{var t;if(!e)return U("alignedGrids contains an undefined option."),i||U('You may want to configure via a callback to avoid setup race conditions:\n                     "alignedGrids: () => [linkedGrid]"'),void U(r());if(e instanceof zo)return e;const n=e;return"current"in n?null==(t=n.current)?void 0:t.api:(n.api||U(`alignedGrids - No api found on the linked grid. If you are passing gridOptions to alignedGrids since v31 this is no longer valid. ${r()}`),n.api)}).filter(e=>!!e&&!e.isDestroyed())}init(){this.addManagedListener(this.eventService,lt.EVENT_COLUMN_MOVED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VISIBLE,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PINNED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_GROUP_OPENED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_RESIZED,this.fireColumnEvent.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL,this.fireScrollEvent.bind(this))}fireEvent(e){this.consuming||this.getAlignedGridApis().forEach(t=>{if(t.isDestroyed())return;const i=t.__getAlignedGridService();e(i)})}onEvent(e){this.consuming=!0,e(),this.consuming=!1}fireColumnEvent(e){this.fireEvent(t=>{t.onColumnEvent(e)})}fireScrollEvent(e){"horizontal"===e.direction&&this.fireEvent(t=>{t.onScrollEvent(e)})}onScrollEvent(e){this.onEvent(()=>{this.ctrlsService.getGridBodyCtrl().getScrollFeature().setHorizontalScrollPosition(e.left,!0)})}getMasterColumns(e){const t=[];return e.columns?e.columns.forEach(e=>{t.push(e)}):e.column&&t.push(e.column),t}getColumnIds(e){const t=[];return e.columns?e.columns.forEach(e=>{t.push(e.getColId())}):e.column&&t.push(e.column.getColId()),t}onColumnEvent(e){this.onEvent(()=>{switch(e.type){case lt.EVENT_COLUMN_MOVED:case lt.EVENT_COLUMN_VISIBLE:case lt.EVENT_COLUMN_PINNED:case lt.EVENT_COLUMN_RESIZED:const t=e;this.processColumnEvent(t);break;case lt.EVENT_COLUMN_GROUP_OPENED:const i=e;this.processGroupOpenedEvent(i);break;case lt.EVENT_COLUMN_PIVOT_CHANGED:console.warn("AG Grid: pivoting is not supported with aligned grids. You can only use one of these features at a time in a grid.")}})}processGroupOpenedEvent(e){e.columnGroups.forEach(t=>{let i=null;if(t){const e=t.getGroupId();i=this.columnModel.getProvidedColumnGroup(e)}t&&!i||(this.logger.log("onColumnEvent-> processing "+e+" expanded = "+t.isExpanded()),this.columnModel.setColumnGroupOpened(i,t.isExpanded(),"alignedGridChanged"))})}processColumnEvent(e){var t;const i=e.column;let r=null;if(i&&(r=this.columnModel.getPrimaryColumn(i.getColId())),i&&!r)return;const n=this.getMasterColumns(e);switch(e.type){case lt.EVENT_COLUMN_MOVED:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId}));this.columnModel.applyColumnState({state:i,applyOrder:!0},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} toIndex = ${t.toIndex}`)}break;case lt.EVENT_COLUMN_VISIBLE:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId,hide:e.hide}));this.columnModel.applyColumnState({state:i},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} visible = ${t.visible}`)}break;case lt.EVENT_COLUMN_PINNED:{const t=e,i=e.api.getColumnState().map(e=>({colId:e.colId,pinned:e.pinned}));this.columnModel.applyColumnState({state:i},"alignedGridChanged"),this.logger.log(`onColumnEvent-> processing ${e.type} pinned = ${t.pinned}`)}break;case lt.EVENT_COLUMN_RESIZED:const i=e,r={};n.forEach(t=>{this.logger.log(`onColumnEvent-> processing ${e.type} actualWidth = ${t.getActualWidth()}`),r[t.getId()]={key:t.getColId(),newWidth:t.getActualWidth()}}),null==(t=i.flexColumns)||t.forEach(e=>{r[e.getId()]&&delete r[e.getId()]}),this.columnModel.setColumnWidths(Object.values(r),!1,i.finished,"alignedGridChanged")}const s=this.ctrlsService.getGridBodyCtrl().isVerticalScrollShowing();this.getAlignedGridApis().forEach(e=>{e.setGridOption("alwaysShowVerticalScroll",s)})}};g([ue("columnModel")],Tc.prototype,"columnModel",2),g([ue("ctrlsService")],Tc.prototype,"ctrlsService",2),g([f(0,pe("loggerFactory"))],Tc.prototype,"setBeans",1),g([ae],Tc.prototype,"init",1),Tc=g([ce("alignedGridsService")],Tc);var Mc=class extends rt{constructor(){super(...arguments),this.selectedNodes=new Map,this.lastRowNode=null}init(){this.rowSelection=this.gos.get("rowSelection"),this.groupSelectsChildren=this.gos.get("groupSelectsChildren"),this.addManagedPropertyListeners(["groupSelectsChildren","rowSelection"],()=>{this.groupSelectsChildren=this.gos.get("groupSelectsChildren"),this.rowSelection=this.gos.get("rowSelection"),this.deselectAllRowNodes({source:"api"})}),this.addManagedListener(this.eventService,lt.EVENT_ROW_SELECTED,this.onRowSelected.bind(this))}destroy(){super.destroy(),this.resetNodes(),this.lastRowNode=null}isMultiselect(){return"multiple"===this.rowSelection}setNodesSelected(e){var t;const{newValue:i,clearSelection:r,suppressFinishActions:n,rangeSelect:s,nodes:o,event:a,source:l="api"}=e;if(0===o.length)return 0;if(o.length>1&&!this.isMultiselect())return console.warn("AG Grid: cannot multi select while rowSelection='single'"),0;const c=this.groupSelectsChildren&&!0===e.groupSelectsFiltered,u=o.map(e=>e.footer?e.sibling:e);if(s){if(o.length>1)return console.warn("AG Grid: cannot range select while selecting multiple rows"),0;let e=null;if("checkboxSelected"===l&&!1===i&&this.lastRowNode&&(this.lastRowNode.id?e=this.lastRowNode:this.lastRowNode=null),null==e&&(e=this.getLastSelectedNode()),e){const t=u[0];if(t!==e&&this.isMultiselect())return this.selectRange(t,e,i,l)}}this.lastRowNode=i?null:u[0];let h=0;for(let e=0;e<u.length;e++){const r=u[e];c&&r.group||r.selectThisNode(i,a,l)&&h++,this.groupSelectsChildren&&(null==(t=r.childrenAfterGroup)?void 0:t.length)&&(h+=this.selectChildren(r,i,c,l))}if(!n&&(i&&(r||!this.isMultiselect())&&(h+=this.clearOtherNodes(u[0],l)),h>0)){this.updateGroupsFromChildrenSelections(l);const e={type:lt.EVENT_SELECTION_CHANGED,source:l};this.eventService.dispatchEvent(e)}return h}selectRange(e,t,i=!0,r){const n=this.rowModel.getNodesInRangeForSelection(e,t);let s=0;n.forEach(e=>{e.group&&this.groupSelectsChildren||e.selectThisNode(i,void 0,r)&&s++}),this.updateGroupsFromChildrenSelections(r);const o={type:lt.EVENT_SELECTION_CHANGED,source:r};return this.eventService.dispatchEvent(o),s}selectChildren(e,t,i,r){const n=i?e.childrenAfterAggFilter:e.childrenAfterGroup;return y(n)?0:this.setNodesSelected({newValue:t,clearSelection:!1,suppressFinishActions:!0,groupSelectsFiltered:i,source:r,nodes:n})}getLastSelectedNode(){const e=Array.from(this.selectedNodes.keys());if(0==e.length)return null;return this.selectedNodes.get(_e(e))||null}getSelectedNodes(){const e=[];return this.selectedNodes.forEach(t=>{t&&e.push(t)}),e}getSelectedRows(){const e=[];return this.selectedNodes.forEach(t=>{t&&t.data&&e.push(t.data)}),e}getSelectionCount(){return this.selectedNodes.size}filterFromSelection(e){const t=new Map;this.selectedNodes.forEach((i,r)=>{i&&e(i)&&t.set(r,i)}),this.selectedNodes=t}updateGroupsFromChildrenSelections(e,t){if(!this.groupSelectsChildren)return!1;if("clientSide"!==this.rowModel.getType())return!1;const i=this.rowModel.getRootNode();t||(t=new kl(!0,i)).setInactive();let r=!1;return t.forEachChangedNodeDepthFirst(t=>{if(t!==i){const i=t.calculateSelectedFromChildren();r=t.selectThisNode(null!==i&&i,void 0,e)||r}}),r}clearOtherNodes(e,t){const i=new Map;let r=0;return this.selectedNodes.forEach(n=>{if(n&&n.id!==e.id){const e=this.selectedNodes.get(n.id);r+=e.setSelectedParams({newValue:!1,clearSelection:!1,suppressFinishActions:!0,source:t}),this.groupSelectsChildren&&n.parent&&i.set(n.parent.id,n.parent)}}),i.forEach(e=>{const i=e.calculateSelectedFromChildren();e.selectThisNode(null!==i&&i,void 0,t)}),r}onRowSelected(e){const t=e.node;this.groupSelectsChildren&&t.group||(t.isSelected()?this.selectedNodes.set(t.id,t):this.selectedNodes.delete(t.id))}syncInRowNode(e,t){this.syncInOldRowNode(e,t),this.syncInNewRowNode(e)}syncInOldRowNode(e,t){if(C(t)&&e.id!==t.id&&t){const i=t.id;this.selectedNodes.get(i)==e&&this.selectedNodes.set(t.id,t)}}syncInNewRowNode(e){this.selectedNodes.has(e.id)?(e.setSelectedInitialValue(!0),this.selectedNodes.set(e.id,e)):e.setSelectedInitialValue(!1)}reset(e){const t=this.getSelectionCount();if(this.resetNodes(),t){const t={type:lt.EVENT_SELECTION_CHANGED,source:e};this.eventService.dispatchEvent(t)}}resetNodes(){var e;null==(e=this.selectedNodes)||e.clear()}getBestCostNodeSelection(){if("clientSide"!==this.rowModel.getType())return;const e=this.rowModel.getTopLevelNodes();if(null===e)return;const t=[];return function e(i){for(let r=0,n=i.length;r<n;r++){const n=i[r];if(n.isSelected())t.push(n);else{const t=n;t.group&&t.children&&e(t.children)}}}(e),t}isEmpty(){let e=0;return this.selectedNodes.forEach(t=>{t&&e++}),0===e}deselectAllRowNodes(e){const t=e=>e.selectThisNode(!1,void 0,r),i="clientSide"===this.rowModel.getType(),{source:r,justFiltered:n,justCurrentPage:s}=e;if(s||n){if(!i)return void console.error("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'");this.getNodesToSelect(n,s).forEach(t)}else this.selectedNodes.forEach(e=>{e&&t(e)}),this.reset(r);i&&this.groupSelectsChildren&&this.updateGroupsFromChildrenSelections(r);const o={type:lt.EVENT_SELECTION_CHANGED,source:r};this.eventService.dispatchEvent(o)}getSelectedCounts(e,t){let i=0,r=0;return this.getNodesToSelect(e,t).forEach(e=>{this.groupSelectsChildren&&e.group||(e.isSelected()?i++:e.selectable&&r++)}),{selectedCount:i,notSelectedCount:r}}getSelectAllState(e,t){const{selectedCount:i,notSelectedCount:r}=this.getSelectedCounts(e,t);return(0!==i||0!==r)&&(i>0&&r>0?null:i>0)}hasNodesToSelect(e=!1,t=!1){return this.getNodesToSelect(e,t).filter(e=>e.selectable).length>0}getNodesToSelect(e=!1,t=!1){if("clientSide"!==this.rowModel.getType())throw new Error(`selectAll only available when rowModelType='clientSide', ie not ${this.rowModel.getType()}`);const i=[];if(t)return this.paginationProxy.forEachNodeOnPage(e=>{if(e.group){if(!e.expanded){const t=e=>{var r;i.push(e),(null==(r=e.childrenAfterFilter)?void 0:r.length)&&e.childrenAfterFilter.forEach(t)};return void t(e)}this.groupSelectsChildren||i.push(e)}else i.push(e)}),i;const r=this.rowModel;return e?(r.forEachNodeAfterFilter(e=>{i.push(e)}),i):(r.forEachNode(e=>{i.push(e)}),i)}selectAllRowNodes(e){if("clientSide"!==this.rowModel.getType())throw new Error(`selectAll only available when rowModelType='clientSide', ie not ${this.rowModel.getType()}`);const{source:t,justFiltered:i,justCurrentPage:r}=e;this.getNodesToSelect(i,r).forEach(e=>e.selectThisNode(!0,void 0,t)),"clientSide"===this.rowModel.getType()&&this.groupSelectsChildren&&this.updateGroupsFromChildrenSelections(t);const n={type:lt.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(n)}getSelectionState(){const e=[];return this.selectedNodes.forEach(t=>{(null==t?void 0:t.id)&&e.push(t.id)}),e.length?e:null}setSelectionState(e,t){if(!Array.isArray(e))return;const i=new Set(e),r=[];this.rowModel.forEachNode(e=>{i.has(e.id)&&r.push(e)}),this.setNodesSelected({newValue:!0,nodes:r,source:t})}};g([ue("rowModel")],Mc.prototype,"rowModel",2),g([ue("paginationProxy")],Mc.prototype,"paginationProxy",2),g([ae],Mc.prototype,"init",1),Mc=g([ce("selectionService")],Mc);var Rc=class{constructor(e){this.viaApi=(e,...t)=>(z(`Since v31, 'columnApi.${e}' is deprecated and moved to 'api.${e}'.`),this.api[e](...t)),this.api=e}sizeColumnsToFit(e){this.viaApi("sizeColumnsToFit",e)}setColumnGroupOpened(e,t){this.viaApi("setColumnGroupOpened",e,t)}getColumnGroup(e,t){return this.viaApi("getColumnGroup",e,t)}getProvidedColumnGroup(e){return this.viaApi("getProvidedColumnGroup",e)}getDisplayNameForColumn(e,t){return this.viaApi("getDisplayNameForColumn",e,t)}getDisplayNameForColumnGroup(e,t){return this.viaApi("getDisplayNameForColumnGroup",e,t)}getColumn(e){return this.viaApi("getColumn",e)}getColumns(){return this.viaApi("getColumns")}applyColumnState(e){return this.viaApi("applyColumnState",e)}getColumnState(){return this.viaApi("getColumnState")}resetColumnState(){this.viaApi("resetColumnState")}getColumnGroupState(){return this.viaApi("getColumnGroupState")}setColumnGroupState(e){this.viaApi("setColumnGroupState",e)}resetColumnGroupState(){this.viaApi("resetColumnGroupState")}isPinning(){return this.viaApi("isPinning")}isPinningLeft(){return this.viaApi("isPinningLeft")}isPinningRight(){return this.viaApi("isPinningRight")}getDisplayedColAfter(e){return this.viaApi("getDisplayedColAfter",e)}getDisplayedColBefore(e){return this.viaApi("getDisplayedColBefore",e)}setColumnVisible(e,t){this.viaApi("setColumnVisible",e,t)}setColumnsVisible(e,t){this.viaApi("setColumnsVisible",e,t)}setColumnPinned(e,t){this.viaApi("setColumnPinned",e,t)}setColumnsPinned(e,t){this.viaApi("setColumnsPinned",e,t)}getAllGridColumns(){return this.viaApi("getAllGridColumns")}getDisplayedLeftColumns(){return this.viaApi("getDisplayedLeftColumns")}getDisplayedCenterColumns(){return this.viaApi("getDisplayedCenterColumns")}getDisplayedRightColumns(){return this.viaApi("getDisplayedRightColumns")}getAllDisplayedColumns(){return this.viaApi("getAllDisplayedColumns")}getAllDisplayedVirtualColumns(){return this.viaApi("getAllDisplayedVirtualColumns")}moveColumn(e,t){this.viaApi("moveColumn",e,t)}moveColumnByIndex(e,t){this.viaApi("moveColumnByIndex",e,t)}moveColumns(e,t){this.viaApi("moveColumns",e,t)}moveRowGroupColumn(e,t){this.viaApi("moveRowGroupColumn",e,t)}setColumnAggFunc(e,t){this.viaApi("setColumnAggFunc",e,t)}setColumnWidth(e,t,i=!0,r){this.viaApi("setColumnWidth",e,t,i,r)}setColumnWidths(e,t=!0,i){this.viaApi("setColumnWidths",e,t,i)}setPivotMode(e){this.viaApi("setPivotMode",e)}isPivotMode(){return this.viaApi("isPivotMode")}getPivotResultColumn(e,t){return this.viaApi("getPivotResultColumn",e,t)}setValueColumns(e){this.viaApi("setValueColumns",e)}getValueColumns(){return this.viaApi("getValueColumns")}removeValueColumn(e){this.viaApi("removeValueColumn",e)}removeValueColumns(e){this.viaApi("removeValueColumns",e)}addValueColumn(e){this.viaApi("addValueColumn",e)}addValueColumns(e){this.viaApi("addValueColumns",e)}setRowGroupColumns(e){this.viaApi("setRowGroupColumns",e)}removeRowGroupColumn(e){this.viaApi("removeRowGroupColumn",e)}removeRowGroupColumns(e){this.viaApi("removeRowGroupColumns",e)}addRowGroupColumn(e){this.viaApi("addRowGroupColumn",e)}addRowGroupColumns(e){this.viaApi("addRowGroupColumns",e)}getRowGroupColumns(){return this.viaApi("getRowGroupColumns")}setPivotColumns(e){this.viaApi("setPivotColumns",e)}removePivotColumn(e){this.viaApi("removePivotColumn",e)}removePivotColumns(e){this.viaApi("removePivotColumns",e)}addPivotColumn(e){this.viaApi("addPivotColumn",e)}addPivotColumns(e){this.viaApi("addPivotColumns",e)}getPivotColumns(){return this.viaApi("getPivotColumns")}getLeftDisplayedColumnGroups(){return this.viaApi("getLeftDisplayedColumnGroups")}getCenterDisplayedColumnGroups(){return this.viaApi("getCenterDisplayedColumnGroups")}getRightDisplayedColumnGroups(){return this.viaApi("getRightDisplayedColumnGroups")}getAllDisplayedColumnGroups(){return this.viaApi("getAllDisplayedColumnGroups")}autoSizeColumn(e,t){return this.viaApi("autoSizeColumn",e,t)}autoSizeColumns(e,t){this.viaApi("autoSizeColumns",e,t)}autoSizeAllColumns(e){this.viaApi("autoSizeAllColumns",e)}setPivotResultColumns(e){this.viaApi("setPivotResultColumns",e)}getPivotResultColumns(){return this.viaApi("getPivotResultColumns")}};g([ue("gridApi")],Rc.prototype,"api",2),Rc=g([ce("columnApi")],Rc);var _c=class extends rt{constructor(){super(...arguments),this.initialised=!1,this.isSsrm=!1}init(){this.isSsrm=this.gos.isRowModelType("serverSide"),this.cellExpressions=this.gos.get("enableCellExpressions"),this.isTreeData=this.gos.get("treeData"),this.initialised=!0;const e=e=>this.callColumnCellValueChangedHandler(e),t=this.gos.useAsyncEvents();this.eventService.addEventListener(lt.EVENT_CELL_VALUE_CHANGED,e,t),this.addDestroyFunc(()=>this.eventService.removeEventListener(lt.EVENT_CELL_VALUE_CHANGED,e,t)),this.addManagedPropertyListener("treeData",e=>this.isTreeData=e.currentValue)}getValue(e,t,i=!1,r=!1){if(this.initialised||this.init(),!t)return;const n=e.getColDef(),s=n.field,o=e.getColId(),a=t.data;let l;const c=t.groupData&&void 0!==t.groupData[o],u=!r&&t.aggData&&void 0!==t.aggData[o],h=this.isSsrm&&r&&!!e.getColDef().aggFunc,d=this.isSsrm&&t.footer&&t.field&&(!0===e.getColDef().showRowGroup||e.getColDef().showRowGroup===t.field);if(i&&n.filterValueGetter?l=this.executeFilterValueGetter(n.filterValueGetter,a,e,t):this.isTreeData&&u?l=t.aggData[o]:this.isTreeData&&n.valueGetter?l=this.executeValueGetter(n.valueGetter,a,e,t):this.isTreeData&&s&&a?l=F(a,s,e.isFieldContainsDots()):c?l=t.groupData[o]:u?l=t.aggData[o]:n.valueGetter?l=this.executeValueGetter(n.valueGetter,a,e,t):d?l=F(a,t.field,e.isFieldContainsDots()):s&&a&&!h&&(l=F(a,s,e.isFieldContainsDots())),this.cellExpressions&&"string"==typeof l&&0===l.indexOf("=")){const i=l.substring(1);l=this.executeValueGetter(i,a,e,t)}if(null==l){const i=this.getOpenedGroup(t,e);if(null!=i)return i}return l}parseValue(e,t,i,r){const n=e.getColDef(),s=this.gos.addGridCommonParams({node:t,data:null==t?void 0:t.data,oldValue:r,newValue:i,colDef:n,column:e}),o=n.valueParser;return C(o)?"function"==typeof o?o(s):this.expressionService.evaluate(o,s):i}formatValue(e,t,i,r,n=!0){let s,o=null;const a=e.getColDef();if(r?s=r:n&&(s=a.valueFormatter),s){const r=this.gos.addGridCommonParams({value:i,node:t,data:t?t.data:null,colDef:a,column:e});o="function"==typeof s?s(r):this.expressionService.evaluate(s,r)}else if(a.refData)return a.refData[i]||"";return null==o&&Array.isArray(i)&&(o=i.join(", ")),o}getOpenedGroup(e,t){if(!this.gos.get("showOpenedGroup"))return;if(!t.getColDef().showRowGroup)return;const i=t.getColDef().showRowGroup;let r=e.parent;for(;null!=r;){if(r.rowGroupColumn&&(!0===i||i===r.rowGroupColumn.getColId()))return r.key;r=r.parent}}setValue(e,t,i,r){const n=this.columnModel.getPrimaryColumn(t);if(!e||!n)return!1;y(e.data)&&(e.data={});const{field:s,valueSetter:o}=n.getColDef();if(y(s)&&y(o))return console.warn("AG Grid: you need either field or valueSetter set on colDef for editing to work"),!1;if(!this.dataTypeService.checkType(n,i))return console.warn("AG Grid: Data type of the new value does not match the cell data type of the column"),!1;const a=this.gos.addGridCommonParams({node:e,data:e.data,oldValue:this.getValue(n,e),newValue:i,colDef:n.getColDef(),column:n});let l;if(a.newValue=i,l=C(o)?"function"==typeof o?o(a):this.expressionService.evaluate(o,a):this.setValueUsingField(e.data,s,i,n.isFieldContainsDots()),void 0===l&&(l=!0),!l)return!1;e.resetQuickFilterAggregateText(),this.valueCache.onDataChanged(),a.newValue=this.getValue(n,e);const c={type:lt.EVENT_CELL_VALUE_CHANGED,event:null,rowIndex:e.rowIndex,rowPinned:e.rowPinned,column:a.column,api:a.api,columnApi:a.columnApi,colDef:a.colDef,context:a.context,data:e.data,node:e,oldValue:a.oldValue,newValue:a.newValue,value:a.newValue,source:r};return this.eventService.dispatchEvent(c),!0}callColumnCellValueChangedHandler(e){const t=e.colDef.onCellValueChanged;"function"==typeof t&&this.getFrameworkOverrides().wrapOutgoing(()=>{t({node:e.node,data:e.data,oldValue:e.oldValue,newValue:e.newValue,colDef:e.colDef,column:e.column,api:e.api,columnApi:e.columnApi,context:e.context})})}setValueUsingField(e,t,i,r){if(!t)return!1;let n=!1;if(r){const r=t.split(".");let s=e;for(;r.length>0&&s;){const e=r.shift();0===r.length?(n=s[e]===i,n||(s[e]=i)):s=s[e]}}else n=e[t]===i,n||(e[t]=i);return!n}executeFilterValueGetter(e,t,i,r){const n=this.gos.addGridCommonParams({data:t,node:r,column:i,colDef:i.getColDef(),getValue:this.getValueCallback.bind(this,r)});return"function"==typeof e?e(n):this.expressionService.evaluate(e,n)}executeValueGetter(e,t,i,r){const n=i.getColId(),s=this.valueCache.getValue(r,n);if(void 0!==s)return s;const o=this.gos.addGridCommonParams({data:t,node:r,column:i,colDef:i.getColDef(),getValue:this.getValueCallback.bind(this,r)});let a;return a="function"==typeof e?e(o):this.expressionService.evaluate(e,o),this.valueCache.setValue(r,n,a),a}getValueCallback(e,t){const i=this.columnModel.getPrimaryColumn(t);return i?this.getValue(i,e):null}getKeyForNode(e,t){const i=this.getValue(e,t),r=e.getColDef().keyCreator;let n=i;return r&&(n=r(this.gos.addGridCommonParams({value:i,colDef:e.getColDef(),column:e,node:t,data:t.data}))),"string"==typeof n||null==n||(n=String(n),"[object Object]"===n&&z("a column you are grouping or pivoting by has objects as values. If you want to group by complex objects then either a) use a colDef.keyCreator (se AG Grid docs) or b) to toString() on the object to return a key")),n}};g([ue("expressionService")],_c.prototype,"expressionService",2),g([ue("columnModel")],_c.prototype,"columnModel",2),g([ue("valueCache")],_c.prototype,"valueCache",2),g([ue("dataTypeService")],_c.prototype,"dataTypeService",2),g([ae],_c.prototype,"init",1),_c=g([ce("valueService")],_c);var Pc=class extends rt{constructor(){super(...arguments),this.expressionToFunctionCache={}}setBeans(e){this.logger=e.create("ExpressionService")}evaluate(e,t){if("string"==typeof e)return this.evaluateExpression(e,t);console.error("AG Grid: value should be either a string or a function",e)}evaluateExpression(e,t){try{return this.createExpressionFunction(e)(t.value,t.context,t.oldValue,t.newValue,t.value,t.node,t.data,t.colDef,t.rowIndex,t.api,t.columnApi,t.getValue,t.column,t.columnGroup)}catch(i){return console.log("Processing of the expression failed"),console.log("Expression = "+e),console.log("Params =",t),console.log("Exception = "+i),null}}createExpressionFunction(e){if(this.expressionToFunctionCache[e])return this.expressionToFunctionCache[e];const t=this.createFunctionBody(e),i=new Function("x, ctx, oldValue, newValue, value, node, data, colDef, rowIndex, api, columnApi, getValue, column, columnGroup",t);return this.expressionToFunctionCache[e]=i,i}createFunctionBody(e){return e.indexOf("return")>=0?e:"return "+e+";"}};g([f(0,pe("loggerFactory"))],Pc.prototype,"setBeans",1),Pc=g([ce("expressionService")],Pc);var xc=class extends rt{setBeans(e){this.logging=e.get("debug")}create(e){return new Dc(e,this.isLogging.bind(this))}isLogging(){return this.logging}};g([f(0,pe("gridOptionsService"))],xc.prototype,"setBeans",1),xc=g([ce("loggerFactory")],xc);var Dc=class{constructor(e,t){this.name=e,this.isLoggingFunc=t}isLogging(){return this.isLoggingFunc()}log(e){this.isLoggingFunc()&&console.log("AG Grid."+this.name+": "+e)}},Ic=class extends rt{setComp(e,t,i){this.view=e,this.eGridHostDiv=t,this.eGui=i,this.eGui.setAttribute("grid-id",this.context.getGridId()),this.dragAndDropService.addDropTarget({getContainer:()=>this.eGui,isInterestedIn:e=>1===e||0===e,getIconName:()=>Gs.ICON_NOT_ALLOWED}),this.mouseEventService.stampTopLevelGridCompWithGridInstance(t),this.createManagedBean(new Qo(this.view)),this.addRtlSupport();const r=this.resizeObserverService.observeResize(this.eGridHostDiv,this.onGridSizeChanged.bind(this));this.addDestroyFunc(()=>r()),this.ctrlsService.register("gridCtrl",this)}isDetailGrid(){var e;const t=this.focusService.findTabbableParent(this.getGui());return(null==(e=null==t?void 0:t.getAttribute("row-id"))?void 0:e.startsWith("detail"))||!1}showDropZones(){return ne.__isRegistered("@ag-grid-enterprise/row-grouping",this.context.getGridId())}showSideBar(){return ne.__isRegistered("@ag-grid-enterprise/side-bar",this.context.getGridId())}showStatusBar(){return ne.__isRegistered("@ag-grid-enterprise/status-bar",this.context.getGridId())}showWatermark(){return ne.__isRegistered("@ag-grid-enterprise/core",this.context.getGridId())}onGridSizeChanged(){const e={type:lt.EVENT_GRID_SIZE_CHANGED,clientWidth:this.eGridHostDiv.clientWidth,clientHeight:this.eGridHostDiv.clientHeight};this.eventService.dispatchEvent(e)}addRtlSupport(){const e=this.gos.get("enableRtl")?"ag-rtl":"ag-ltr";this.view.setRtlClass(e)}destroyGridUi(){this.view.destroyGridUi()}getGui(){return this.eGui}setResizeCursor(e){this.view.setCursor(e?"ew-resize":null)}disableUserSelect(e){this.view.setUserSelect(e?"none":null)}focusNextInnerContainer(e){const t=this.view.getFocusableContainers(),i=this.gos.getActiveDomElement(),r=t.findIndex(e=>e.contains(i))+(e?-1:1);return!(r<=0||r>=t.length)&&this.focusService.focusInto(t[r])}focusInnerElement(e){const t=this.view.getFocusableContainers(),i=this.columnModel.getAllDisplayedColumns();if(e){if(t.length>1)return this.focusService.focusInto(_e(t),!0);const e=_e(i);if(this.focusService.focusGridView(e,!0))return!0}if(0===this.gos.get("headerHeight")||this.gos.get("suppressHeaderFocus")){if(this.focusService.focusGridView(i[0]))return!0;for(let e=1;e<t.length;e++)if(this.focusService.focusInto(t[e]))return!0;return!1}return this.focusService.focusFirstHeader()}forceFocusOutOfContainer(e=!1){this.view.forceFocusOutOfContainer(e)}};g([ue("focusService")],Ic.prototype,"focusService",2),g([ue("resizeObserverService")],Ic.prototype,"resizeObserverService",2),g([ue("columnModel")],Ic.prototype,"columnModel",2),g([ue("ctrlsService")],Ic.prototype,"ctrlsService",2),g([ue("mouseEventService")],Ic.prototype,"mouseEventService",2),g([ue("dragAndDropService")],Ic.prototype,"dragAndDropService",2);var Lc=class extends El{constructor(e){super(),this.eGridDiv=e}postConstruct(){this.logger=this.loggerFactory.create("GridComp");const e={destroyGridUi:()=>this.destroyBean(this),setRtlClass:e=>this.addCssClass(e),forceFocusOutOfContainer:this.forceFocusOutOfContainer.bind(this),updateLayoutClasses:this.updateLayoutClasses.bind(this),getFocusableContainers:this.getFocusableContainers.bind(this),setUserSelect:e=>{this.getGui().style.userSelect=null!=e?e:"",this.getGui().style.webkitUserSelect=null!=e?e:""},setCursor:e=>{this.getGui().style.cursor=null!=e?e:""}};this.ctrl=this.createManagedBean(new Ic);const t=this.createTemplate();this.setTemplate(t),this.ctrl.setComp(e,this.eGridDiv,this.getGui()),this.insertGridIntoDom(),this.initialiseTabGuard({onTabKeyDown:()=>{},focusInnerElement:e=>this.ctrl.focusInnerElement(e),forceFocusOutWhenTabGuardsAreEmpty:!0})}insertGridIntoDom(){const e=this.getGui();this.eGridDiv.appendChild(e),this.addDestroyFunc(()=>{this.eGridDiv.removeChild(e),this.logger.log("Grid removed from DOM")})}updateLayoutClasses(e,t){const i=this.eRootWrapperBody.classList;i.toggle("ag-layout-auto-height",t.autoHeight),i.toggle("ag-layout-normal",t.normal),i.toggle("ag-layout-print",t.print),this.addOrRemoveCssClass("ag-layout-auto-height",t.autoHeight),this.addOrRemoveCssClass("ag-layout-normal",t.normal),this.addOrRemoveCssClass("ag-layout-print",t.print)}createTemplate(){return`<div class="ag-root-wrapper" role="presentation">\n                ${this.ctrl.showDropZones()?"<ag-grid-header-drop-zones></ag-grid-header-drop-zones>":""}\n                <div class="ag-root-wrapper-body" ref="rootWrapperBody" role="presentation">\n                    <ag-grid-body ref="gridBody"></ag-grid-body>\n                    ${this.ctrl.showSideBar()?'<ag-side-bar ref="sideBar"></ag-side-bar>':""}\n                </div>\n                ${this.ctrl.showStatusBar()?'<ag-status-bar ref="statusBar"></ag-status-bar>':""}\n                <ag-pagination></ag-pagination>\n                ${this.ctrl.showWatermark()?"<ag-watermark></ag-watermark>":""}\n            </div>`}getFocusableElement(){return this.eRootWrapperBody}getFocusableContainers(){const e=[this.gridBodyComp.getGui()];return this.sideBarComp&&e.push(this.sideBarComp.getGui()),e.filter(e=>Sr(e))}};g([ue("loggerFactory")],Lc.prototype,"loggerFactory",2),g([Sn("gridBody")],Lc.prototype,"gridBodyComp",2),g([Sn("sideBar")],Lc.prototype,"sideBarComp",2),g([Sn("rootWrapperBody")],Lc.prototype,"eRootWrapperBody",2),g([ae],Lc.prototype,"postConstruct",1);var Nc=class extends rt{progressSort(e,t,i){const r=this.getNextSortDirection(e);this.setSortForColumn(e,r,t,i)}setSortForColumn(e,t,i,r){"asc"!==t&&"desc"!==t&&(t=null);let n=[e];if(this.gos.isColumnsSortingCoupledToGroup()&&e.getColDef().showRowGroup){const t=this.columnModel.getSourceColumnsForGroupColumn(e),i=null==t?void 0:t.filter(e=>e.isSortable());i&&(n=[e,...i])}n.forEach(e=>e.setSort(t,r));const s=[];if(!i&&!this.gos.get("alwaysMultiSort")||this.gos.get("suppressMultiSort")){const e=this.clearSortBarTheseColumns(n,r);s.push(...e)}this.updateSortIndex(e),s.push(...n),this.dispatchSortChangedEvents(r,s)}updateSortIndex(e){const t=this.gos.isColumnsSortingCoupledToGroup(),i=this.columnModel.getGroupDisplayColumnForGroup(e.getId()),r=t&&i||e,n=this.getColumnsWithSortingOrdered();this.columnModel.getPrimaryAndSecondaryAndAutoColumns().forEach(e=>e.setSortIndex(null));const s=n.filter(e=>!(t&&e.getColDef().showRowGroup||e===r));(r.getSort()?[...s,r]:s).forEach((e,t)=>{e.setSortIndex(t)})}onSortChanged(e,t){this.dispatchSortChangedEvents(e,t)}isSortActive(){const e=this.columnModel.getPrimaryAndSecondaryAndAutoColumns().filter(e=>!!e.getSort());return e&&e.length>0}dispatchSortChangedEvents(e,t){const i={type:lt.EVENT_SORT_CHANGED,source:e};t&&(i.columns=t),this.eventService.dispatchEvent(i)}clearSortBarTheseColumns(e,t){const i=[];return this.columnModel.getPrimaryAndSecondaryAndAutoColumns().forEach(r=>{e.includes(r)||(r.getSort()&&i.push(r),r.setSort(void 0,t))}),i}getNextSortDirection(e){let t;if(t=e.getColDef().sortingOrder?e.getColDef().sortingOrder:this.gos.get("sortingOrder")?this.gos.get("sortingOrder"):Nc.DEFAULT_SORTING_ORDER,!Array.isArray(t)||t.length<=0)return console.warn(`AG Grid: sortingOrder must be an array with at least one element, currently it's ${t}`),null;const i=t.indexOf(e.getSort()),r=i<0,n=i==t.length-1;let s;return s=r||n?t[0]:t[i+1],Nc.DEFAULT_SORTING_ORDER.indexOf(s)<0?(console.warn("AG Grid: invalid sort type "+s),null):s}getIndexedSortMap(){let e=this.columnModel.getPrimaryAndSecondaryAndAutoColumns().filter(e=>!!e.getSort());if(this.columnModel.isPivotMode()){const t=this.gos.isColumnsSortingCoupledToGroup();e=e.filter(e=>{const i=!!e.getAggFunc(),r=!e.isPrimary(),n=t?this.columnModel.getGroupDisplayColumnForGroup(e.getId()):e.getColDef().showRowGroup;return i||r||n})}const t=this.columnModel.getRowGroupColumns().filter(e=>!!e.getSort()),i={};e.forEach((e,t)=>i[e.getId()]=t),e.sort((e,t)=>{const r=e.getSortIndex(),n=t.getSortIndex();return null!=r&&null!=n?r-n:null==r&&null==n?i[e.getId()]>i[t.getId()]?1:-1:null==n?-1:1});const r=this.gos.isColumnsSortingCoupledToGroup()&&!!t.length;r&&(e=[...new Set(e.map(e=>{var t;return null!=(t=this.columnModel.getGroupDisplayColumnForGroup(e.getId()))?t:e}))]);const n=new Map;return e.forEach((e,t)=>n.set(e,t)),r&&t.forEach(e=>{const t=this.columnModel.getGroupDisplayColumnForGroup(e.getId());n.set(e,n.get(t))}),n}getColumnsWithSortingOrdered(){return[...this.getIndexedSortMap().entries()].sort(([e,t],[i,r])=>t-r).map(([e])=>e)}getSortModel(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),colId:e.getId()}))}getSortOptions(){return this.getColumnsWithSortingOrdered().filter(e=>e.getSort()).map(e=>({sort:e.getSort(),column:e}))}canColumnDisplayMixedSort(e){const t=this.gos.isColumnsSortingCoupledToGroup(),i=!!e.getColDef().showRowGroup;return t&&i}getDisplaySortForColumn(e){const t=this.columnModel.getSourceColumnsForGroupColumn(e);if(!this.canColumnDisplayMixedSort(e)||!(null==t?void 0:t.length))return e.getSort();const i=null!=e.getColDef().field||e.getColDef().valueGetter?[e,...t]:t,r=i[0].getSort();return i.every(e=>e.getSort()==r)?r:"mixed"}getDisplaySortIndexForColumn(e){return this.getIndexedSortMap().get(e)}};Nc.DEFAULT_SORTING_ORDER=["asc","desc",null],g([ue("columnModel")],Nc.prototype,"columnModel",2),Nc=g([ce("sortController")],Nc);var Oc=class extends rt{static addKeyboardModeEvents(e){this.instanceCount>0||(e.addEventListener("keydown",Oc.toggleKeyboardMode),e.addEventListener("mousedown",Oc.toggleKeyboardMode))}static removeKeyboardModeEvents(e){this.instanceCount>0||(e.addEventListener("keydown",Oc.toggleKeyboardMode),e.addEventListener("mousedown",Oc.toggleKeyboardMode))}static toggleKeyboardMode(e){const t=Oc.keyboardModeActive,i="keydown"===e.type;i&&(e.ctrlKey||e.metaKey||e.altKey)||t!==i&&(Oc.keyboardModeActive=i)}static unregisterGridCompController(e){Oc.removeKeyboardModeEvents(e)}init(){const e=this.clearFocusedCell.bind(this);this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverythingChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_GROUP_OPENED,e),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.registerKeyboardFocusEvents(),this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl})}registerKeyboardFocusEvents(){const e=this.gos.getDocument();Oc.addKeyboardModeEvents(e),Oc.instanceCount++,this.addDestroyFunc(()=>{Oc.instanceCount--,Oc.unregisterGridCompController(e)})}onColumnEverythingChanged(){if(!this.focusedCellPosition)return;const e=this.focusedCellPosition.column,t=this.columnModel.getGridColumn(e.getId());e!==t&&this.clearFocusedCell()}isKeyboardMode(){return Oc.keyboardModeActive}getFocusCellToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedCellPosition||this.isDomDataMissingInHierarchy(this.gos.getActiveDomElement(),va.DOM_DATA_KEY_ROW_CTRL)?null:this.focusedCellPosition}getFocusHeaderToUseAfterRefresh(){return this.gos.get("suppressFocusAfterRefresh")||!this.focusedHeaderPosition||this.isDomDataMissingInHierarchy(this.gos.getActiveDomElement(),Ja.DOM_DATA_KEY_HEADER_CTRL)?null:this.focusedHeaderPosition}isDomDataMissingInHierarchy(e,t){let i=e;for(;i;){if(this.gos.getDomData(i,t))return!1;i=i.parentNode}return!0}getFocusedCell(){return this.focusedCellPosition}shouldRestoreFocus(e){return!!this.isCellRestoreFocused(e)&&(setTimeout(()=>{this.restoredFocusedCellPosition=null},0),!0)}isCellRestoreFocused(e){return null!=this.restoredFocusedCellPosition&&this.cellPositionUtils.equals(e,this.restoredFocusedCellPosition)}setRestoreFocusedCell(e){"react"===this.getFrameworkOverrides().renderingEngine&&(this.restoredFocusedCellPosition=e)}getFocusEventParams(){const{rowIndex:e,rowPinned:t,column:i}=this.focusedCellPosition,r={rowIndex:e,rowPinned:t,column:i,isFullWidthCell:!1},n=this.rowRenderer.getRowByPosition({rowIndex:e,rowPinned:t});return n&&(r.isFullWidthCell=n.isFullWidth()),r}clearFocusedCell(){if(this.restoredFocusedCellPosition=null,null==this.focusedCellPosition)return;const e=h({type:lt.EVENT_CELL_FOCUS_CLEARED},this.getFocusEventParams());this.focusedCellPosition=null,this.eventService.dispatchEvent(e)}setFocusedCell(e){const{column:t,rowIndex:i,rowPinned:r,forceBrowserFocus:n=!1,preventScrollOnBrowserFocus:s=!1}=e,o=this.columnModel.getGridColumn(t);if(!o)return void(this.focusedCellPosition=null);this.focusedCellPosition=o?{rowIndex:i,rowPinned:v(r),column:o}:null;const a=d(h({type:lt.EVENT_CELL_FOCUSED},this.getFocusEventParams()),{forceBrowserFocus:n,preventScrollOnBrowserFocus:s,floating:null});this.eventService.dispatchEvent(a)}isCellFocused(e){return null!=this.focusedCellPosition&&this.cellPositionUtils.equals(e,this.focusedCellPosition)}isRowNodeFocused(e){return this.isRowFocused(e.rowIndex,e.rowPinned)}isHeaderWrapperFocused(e){if(null==this.focusedHeaderPosition)return!1;const t=e.getColumnGroupChild(),i=e.getRowIndex(),r=e.getPinned(),{column:n,headerRowIndex:s}=this.focusedHeaderPosition;return t===n&&i===s&&r==n.getPinned()}clearFocusedHeader(){this.focusedHeaderPosition=null}getFocusedHeader(){return this.focusedHeaderPosition}setFocusedHeader(e,t){this.focusedHeaderPosition={headerRowIndex:e,column:t}}focusHeaderPosition(e){if(this.gos.get("suppressHeaderFocus"))return!1;const{direction:t,fromTab:i,allowUserOverride:r,event:n,fromCell:s,rowWithoutSpanValue:o}=e;let{headerPosition:a}=e;if(s&&this.filterManager.isAdvancedFilterHeaderActive())return this.focusAdvancedFilter(a);if(r){const e=this.getFocusedHeader(),r=this.headerNavigationService.getHeaderRowCount();if(i){const i=this.gos.getCallback("tabToNextHeader");i&&(a=this.getHeaderPositionFromUserFunc({userFunc:i,direction:t,currentPosition:e,headerPosition:a,headerRowCount:r}))}else{const t=this.gos.getCallback("navigateToNextHeader");t&&n&&(a=t({key:n.key,previousHeaderPosition:e,nextHeaderPosition:a,headerRowCount:r,event:n}))}}return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:t,event:n,fromCell:s,rowWithoutSpanValue:o})}focusHeaderPositionFromUserFunc(e){if(this.gos.get("suppressHeaderFocus"))return!1;const{userFunc:t,headerPosition:i,direction:r,event:n}=e,s=this.getFocusedHeader(),o=this.headerNavigationService.getHeaderRowCount(),a=this.getHeaderPositionFromUserFunc({userFunc:t,direction:r,currentPosition:s,headerPosition:i,headerRowCount:o});return!!a&&this.focusProvidedHeaderPosition({headerPosition:a,direction:r,event:n})}getHeaderPositionFromUserFunc(e){const{userFunc:t,direction:i,currentPosition:r,headerPosition:n,headerRowCount:s}=e,o=t({backwards:"Before"===i,previousHeaderPosition:r,nextHeaderPosition:n,headerRowCount:s});return!0===o||null===o?(null===o&&z("Returning `null` from tabToNextHeader is deprecated. Return `true` to stay on the current header, or `false` to let the browser handle the tab behaviour."),r):!1===o?null:o}focusProvidedHeaderPosition(e){const{headerPosition:t,direction:i,fromCell:r,rowWithoutSpanValue:n,event:s}=e;if(-1===t.headerRowIndex)return this.filterManager.isAdvancedFilterHeaderActive()?this.focusAdvancedFilter(t):this.focusGridView(t.column);this.headerNavigationService.scrollToColumn(t.column,i);const o=this.ctrlsService.getHeaderRowContainerCtrl(t.column.getPinned()).focusHeader(t.headerRowIndex,t.column,s);return o&&(null!=n||r)&&this.headerNavigationService.setCurrentHeaderRowWithoutSpan(null!=n?n:-1),o}focusFirstHeader(){let e=this.columnModel.getAllDisplayedColumns()[0];if(!e)return!1;e.getParent()&&(e=this.columnModel.getColumnGroupAtLevel(e,0));const t=this.headerPositionUtils.getHeaderIndexToFocus(e,0);return this.focusHeaderPosition({headerPosition:t,rowWithoutSpanValue:0})}focusLastHeader(e){const t=this.headerNavigationService.getHeaderRowCount()-1,i=_e(this.columnModel.getAllDisplayedColumns());return this.focusHeaderPosition({headerPosition:{headerRowIndex:t,column:i},rowWithoutSpanValue:-1,event:e})}focusPreviousFromFirstCell(e){return this.filterManager.isAdvancedFilterHeaderActive()?this.focusAdvancedFilter(null):this.focusLastHeader(e)}isAnyCellFocused(){return!!this.focusedCellPosition}isRowFocused(e,t){return null!=this.focusedCellPosition&&this.focusedCellPosition.rowIndex===e&&this.focusedCellPosition.rowPinned===v(t)}findFocusableElements(e,t,i=!1){const r=ir;let n=rr;t&&(n+=", "+t),i&&(n+=', [tabindex="-1"]');const s=Array.prototype.slice.apply(e.querySelectorAll(r)).filter(e=>Sr(e)),o=Array.prototype.slice.apply(e.querySelectorAll(n));return o.length?(a=o,s.filter(e=>-1===a.indexOf(e))):s;var a}focusInto(e,t=!1,i=!1){const r=this.findFocusableElements(e,null,i),n=t?_e(r):r[0];return!!n&&(n.focus({preventScroll:!0}),!0)}findFocusableElementBeforeTabGuard(e,t){if(!t)return null;const i=this.findFocusableElements(e),r=i.indexOf(t);if(-1===r)return null;let n=-1;for(let e=r-1;e>=0;e--)if(i[e].classList.contains("ag-tab-guard-top")){n=e;break}return n<=0?null:i[n-1]}findNextFocusableElement(e=this.eGridDiv,t,i){const r=this.findFocusableElements(e,t?':not([tabindex="-1"])':null),n=this.gos.getActiveDomElement();let s;s=t?r.findIndex(e=>e.contains(n)):r.indexOf(n);const o=s+(i?-1:1);return o<0||o>=r.length?null:r[o]}isTargetUnderManagedComponent(e,t){if(!t)return!1;const i=e.querySelectorAll(`.${_n.FOCUS_MANAGED_CLASS}`);if(!i.length)return!1;for(let e=0;e<i.length;e++)if(i[e].contains(t))return!0;return!1}findTabbableParent(e,t=5){let i=0;for(;e&&null===Li(e)&&++i<=t;)e=e.parentElement;return null===Li(e)?null:e}focusGridView(e,t){var i;if(this.gos.get("suppressCellFocus"))return t?this.gos.get("suppressHeaderFocus")?this.focusNextGridCoreContainer(!0,!0):this.focusLastHeader():this.focusNextGridCoreContainer(!1);const r=t?this.rowPositionUtils.getLastRow():this.rowPositionUtils.getFirstRow();if(!r)return!1;const{rowIndex:n,rowPinned:s}=r,o=this.getFocusedHeader();return!e&&o&&(e=o.column),!(null==n||!e||(this.navigationService.ensureCellVisible({rowIndex:n,column:e,rowPinned:s}),this.setFocusedCell({rowIndex:n,column:e,rowPinned:v(s),forceBrowserFocus:!0}),null==(i=this.rangeService)||i.setRangeToCell({rowIndex:n,rowPinned:s,column:e}),0))}focusNextGridCoreContainer(e,t=!1){return!(t||!this.gridCtrl.focusNextInnerContainer(e))||((t||!e&&!this.gridCtrl.isDetailGrid())&&this.gridCtrl.forceFocusOutOfContainer(e),!1)}focusAdvancedFilter(e){var t,i;return this.advancedFilterFocusColumn=null==e?void 0:e.column,null!=(i=null==(t=this.advancedFilterService)?void 0:t.getCtrl().focusHeaderComp())&&i}focusNextFromAdvancedFilter(e,t){var i,r;const n=null!=(r=t?void 0:this.advancedFilterFocusColumn)?r:null==(i=this.columnModel.getAllDisplayedColumns())?void 0:i[0];return e?this.focusHeaderPosition({headerPosition:{column:n,headerRowIndex:this.headerNavigationService.getHeaderRowCount()-1}}):this.focusGridView(n)}clearAdvancedFilterColumn(){this.advancedFilterFocusColumn=void 0}};Oc.keyboardModeActive=!1,Oc.instanceCount=0,g([ue("eGridDiv")],Oc.prototype,"eGridDiv",2),g([ue("columnModel")],Oc.prototype,"columnModel",2),g([ue("headerNavigationService")],Oc.prototype,"headerNavigationService",2),g([ue("headerPositionUtils")],Oc.prototype,"headerPositionUtils",2),g([ue("rowRenderer")],Oc.prototype,"rowRenderer",2),g([ue("rowPositionUtils")],Oc.prototype,"rowPositionUtils",2),g([ue("cellPositionUtils")],Oc.prototype,"cellPositionUtils",2),g([ue("navigationService")],Oc.prototype,"navigationService",2),g([ue("ctrlsService")],Oc.prototype,"ctrlsService",2),g([ue("filterManager")],Oc.prototype,"filterManager",2),g([he("rangeService")],Oc.prototype,"rangeService",2),g([he("advancedFilterService")],Oc.prototype,"advancedFilterService",2),g([ae],Oc.prototype,"init",1),Oc=g([ce("focusService")],Oc);var Fc=class extends rt{setMouseOver(e){this.selectedColumns=e;const t={type:lt.EVENT_COLUMN_HOVER_CHANGED};this.eventService.dispatchEvent(t)}clearMouseOver(){this.selectedColumns=null;const e={type:lt.EVENT_COLUMN_HOVER_CHANGED};this.eventService.dispatchEvent(e)}isHovered(e){return!!this.selectedColumns&&this.selectedColumns.indexOf(e)>=0}};Fc=g([ce("columnHoverService")],Fc);var kc=class extends rt{constructor(){super(...arguments),this.executeNextFuncs=[],this.executeLaterFuncs=[],this.active=!1,this.suppressAnimation=!1,this.animationThreadCount=0}postConstruct(){this.ctrlsService.whenReady(e=>this.gridBodyCtrl=e.gridBodyCtrl)}isActive(){return this.active&&!this.suppressAnimation}setSuppressAnimation(e){this.suppressAnimation=e}start(){this.active||this.gos.get("suppressColumnMoveAnimation")||this.gos.get("enableRtl")||(this.ensureAnimationCssClassPresent(),this.active=!0)}finish(){this.active&&this.flush(()=>{this.active=!1})}executeNextVMTurn(e){this.active?this.executeNextFuncs.push(e):e()}executeLaterVMTurn(e){this.active?this.executeLaterFuncs.push(e):e()}ensureAnimationCssClassPresent(){this.animationThreadCount++;const e=this.animationThreadCount;this.gridBodyCtrl.setColumnMovingCss(!0),this.executeLaterFuncs.push(()=>{this.animationThreadCount===e&&this.gridBodyCtrl.setColumnMovingCss(!1)})}flush(e){if(0===this.executeNextFuncs.length&&0===this.executeLaterFuncs.length)return void e();const t=e=>{for(;e.length;){const t=e.pop();t&&t()}};this.getFrameworkOverrides().wrapIncoming(()=>{window.setTimeout(()=>t(this.executeNextFuncs),0),window.setTimeout(()=>{e(),t(this.executeLaterFuncs)},200)})}};g([ue("ctrlsService")],kc.prototype,"ctrlsService",2),g([ae],kc.prototype,"postConstruct",1),kc=g([ce("columnAnimationService")],kc);var Gc=class extends rt{postConstruct(){this.ctrlsService.whenReady(e=>{this.centerRowsCtrl=e.center,this.addManagedListener(this.eventService,lt.EVENT_BODY_HEIGHT_CHANGED,this.checkPageSize.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_SCROLL_VISIBILITY_CHANGED,this.checkPageSize.bind(this)),this.addManagedPropertyListener("paginationAutoPageSize",this.onPaginationAutoSizeChanged.bind(this)),this.checkPageSize()})}notActive(){return!this.gos.get("paginationAutoPageSize")||null==this.centerRowsCtrl}onPaginationAutoSizeChanged(){this.notActive()?this.paginationProxy.unsetAutoCalculatedPageSize():this.checkPageSize()}checkPageSize(){if(this.notActive())return;const e=this.centerRowsCtrl.getViewportSizeFeature().getBodyHeight();if(e>0){const t=()=>{const t=this.gos.getRowHeightAsNumber(),i=Math.floor(e/t);this.paginationProxy.setPageSize(i,"autoCalculated")};this.isBodyRendered?X(()=>t(),50)():(t(),this.isBodyRendered=!0)}else this.isBodyRendered=!1}};g([ue("ctrlsService")],Gc.prototype,"ctrlsService",2),g([ue("paginationProxy")],Gc.prototype,"paginationProxy",2),g([ae],Gc.prototype,"postConstruct",1),Gc=g([ce("paginationAutoPageSizeService")],Gc);var Vc=class extends rt{constructor(){super(...arguments),this.cacheVersion=0}init(){this.active=this.gos.get("valueCache"),this.neverExpires=this.gos.get("valueCacheNeverExpires")}onDataChanged(){this.neverExpires||this.expire()}expire(){this.cacheVersion++}setValue(e,t,i){this.active&&(e.__cacheVersion!==this.cacheVersion&&(e.__cacheVersion=this.cacheVersion,e.__cacheData={}),e.__cacheData[t]=i)}getValue(e,t){if(this.active&&e.__cacheVersion===this.cacheVersion)return e.__cacheData[t]}};g([ae],Vc.prototype,"init",1),Vc=g([ce("valueCache")],Vc);var Hc=class extends rt{init(){"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel),this.addManagedListener(this.eventService,lt.EVENT_CELL_VALUE_CHANGED,this.onCellValueChanged.bind(this))}onCellValueChanged(e){"paste"!==e.source&&this.doChangeDetection(e.node,e.column)}doChangeDetection(e,t){if(this.gos.get("suppressChangeDetection"))return;const i=[e];if(this.clientSideRowModel&&!e.isRowPinned()){const r=this.gos.get("aggregateOnlyChangedColumns"),n=new kl(r,this.clientSideRowModel.getRootNode());n.addParentNode(e.parent,[t]),this.clientSideRowModel.doAggregate(n),n.forEachChangedNodeDepthFirst(e=>{i.push(e)})}this.rowRenderer.refreshCells({rowNodes:i})}};g([ue("rowModel")],Hc.prototype,"rowModel",2),g([ue("rowRenderer")],Hc.prototype,"rowRenderer",2),g([ae],Hc.prototype,"init",1),Hc=g([ce("changeDetectionService")],Hc);var Bc=class extends rt{adaptFunction(e,t){const i=this.componentMetadataProvider.retrieve(e);return i&&i.functionAdapter?i.functionAdapter(t):null}adaptCellRendererFunction(e){return class{refresh(e){return!1}getGui(){return this.eGui}init(t){const i=e(t),r=typeof i;this.eGui="string"!==r&&"number"!==r&&"boolean"!==r?null!=i?i:br("<span></span>"):br("<span>"+i+"</span>")}}}doesImplementIComponent(e){return!!e&&e.prototype&&"getGui"in e.prototype}};g([ue("componentMetadataProvider")],Bc.prototype,"componentMetadataProvider",2),Bc=g([ce("agComponentUtils")],Bc);var zc=class extends rt{postConstruct(){this.componentMetaData={dateComponent:{mandatoryMethodList:["getDate","setDate"],optionalMethodList:["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled","onParamsUpdated","refresh"]},detailCellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},headerComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},headerGroupComponent:{mandatoryMethodList:[],optionalMethodList:[]},loadingCellRenderer:{mandatoryMethodList:[],optionalMethodList:[],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},loadingOverlayComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},noRowsOverlayComponent:{mandatoryMethodList:[],optionalMethodList:["refresh"]},floatingFilterComponent:{mandatoryMethodList:["onParentModelChanged"],optionalMethodList:["afterGuiAttached","onParamsUpdated","refresh"]},cellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh","afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},cellEditor:{mandatoryMethodList:["getValue"],optionalMethodList:["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached","refresh"]},innerRenderer:{mandatoryMethodList:[],optionalMethodList:["afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},fullWidthCellRenderer:{mandatoryMethodList:[],optionalMethodList:["refresh","afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},groupRowRenderer:{mandatoryMethodList:[],optionalMethodList:["afterGuiAttached"],functionAdapter:this.agComponentUtils.adaptCellRendererFunction.bind(this.agComponentUtils)},filter:{mandatoryMethodList:["isFilterActive","doesFilterPass","getModel","setModel"],optionalMethodList:["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onFloatingFilterChanged","onAnyFilterChanged","refresh"]},statusPanel:{mandatoryMethodList:[],optionalMethodList:["refresh"]},toolPanel:{mandatoryMethodList:[],optionalMethodList:["refresh","getState"]},tooltipComponent:{mandatoryMethodList:[],optionalMethodList:[]},menuItem:{mandatoryMethodList:[],optionalMethodList:["setActive","select","setExpanded","configureDefaults"]}}}retrieve(e){return this.componentMetaData[e]}};g([ue("agComponentUtils")],zc.prototype,"agComponentUtils",2),g([ae],zc.prototype,"postConstruct",1),zc=g([ce("componentMetadataProvider")],zc);var Uc={"ag-theme-custom":{headerHeight:25,headerCellMinWidth:24,listItemHeight:20,rowHeight:25,chartMenuPanelWidth:220},"ag-theme-material":{headerHeight:56,headerCellMinWidth:48,listItemHeight:32,rowHeight:48,chartMenuPanelWidth:240},"ag-theme-balham":{headerHeight:32,headerCellMinWidth:24,listItemHeight:24,rowHeight:28,chartMenuPanelWidth:220},"ag-theme-alpine":{headerHeight:48,headerCellMinWidth:36,listItemHeight:24,rowHeight:42,chartMenuPanelWidth:240},"ag-theme-quartz":{headerHeight:48,headerCellMinWidth:36,listItemHeight:24,rowHeight:42,chartMenuPanelWidth:260}},Wc={headerHeight:["ag-header-row"],headerCellMinWidth:["ag-header-cell"],listItemHeight:["ag-virtual-list-item"],rowHeight:["ag-row"],chartMenuPanelWidth:["ag-chart-docked-container"]},jc=class extends rt{constructor(){super(...arguments),this.calculatedSizes={},this.calculatedTheme=null}postConstruct(){var e;const t=null!=(e=this.getTheme().el)?e:this.eGridDiv;this.addManagedPropertyListener("rowHeight",()=>this.refreshRowHeightVariable()),this.mutationObserver=new MutationObserver(()=>{this.calculatedSizes={},this.calculatedTheme=null,this.calculatedTheme=this.getTheme(),this.fireGridStylesChangedEvent()}),this.mutationObserver.observe(t||this.eGridDiv,{attributes:!0,attributeFilter:["class"]})}fireGridStylesChangedEvent(){const e={type:lt.EVENT_GRID_STYLES_CHANGED};this.eventService.dispatchEvent(e)}getSassVariable(e){const{themeFamily:t,el:i}=this.getTheme();if(!t||0!==t.indexOf("ag-theme"))return;this.calculatedSizes||(this.calculatedSizes={}),this.calculatedSizes[t]||(this.calculatedSizes[t]={});const r=this.calculatedSizes[t][e];return null!=r?r:(this.calculatedSizes[t][e]=this.calculateValueForSassProperty(e,t,i),this.calculatedSizes[t][e])}calculateValueForSassProperty(e,t,i){const r="ag-theme-"+(t.match("material")?"material":t.match("balham")?"balham":t.match("alpine")?"alpine":"custom"),n=Uc[r][e],s=this.gos.getDocument();if(i||(i=this.eGridDiv),!Wc[e])return n;const o=Wc[e],a=s.createElement("div"),l=Array.from(i.classList);a.classList.add(t,...l),a.style.position="absolute";const c=o.reduce((e,t)=>{const i=s.createElement("div");return i.style.position="static",i.classList.add(t),e.appendChild(i),i},a);let u=0;if(s.body){s.body.appendChild(a);const t=-1!==e.toLowerCase().indexOf("height")?"height":"width";u=parseInt(window.getComputedStyle(c)[t],10),s.body.removeChild(a)}return u||n}isThemeDark(){const{theme:e}=this.getTheme();return!!e&&e.indexOf("dark")>=0}chartMenuPanelWidth(){return this.getSassVariable("chartMenuPanelWidth")}getTheme(){if(this.calculatedTheme)return this.calculatedTheme;const e=/\bag-(material|(?:theme-([\w\-]*)))\b/g;let t=this.eGridDiv,i=null,r=[];for(;t;){if(i=e.exec(t.className),i){const i=t.className.match(e);i&&(r=i);break}t=t.parentElement||void 0}if(!i)return{allThemes:r};const n=i[0];return this.calculatedTheme={theme:n,el:t,themeFamily:n.replace(/-dark$/,""),allThemes:r},this.calculatedTheme}getFromTheme(e,t){var i;return null!=(i=this.getSassVariable(t))?i:e}getDefaultRowHeight(){return this.getFromTheme(25,"rowHeight")}getListItemHeight(){return this.getFromTheme(20,"listItemHeight")}refreshRowHeightVariable(){const e=this.eGridDiv.style.getPropertyValue("--ag-line-height").trim(),t=this.gos.get("rowHeight");if(null==t||isNaN(t)||!isFinite(t))return null!==e&&this.eGridDiv.style.setProperty("--ag-line-height",null),-1;const i=`${t}px`;return e!=i?(this.eGridDiv.style.setProperty("--ag-line-height",i),t):""!=e?parseFloat(e):-1}getMinColWidth(){const e=this.getFromTheme(null,"headerCellMinWidth");return C(e)?Math.max(e,10):10}destroy(){this.calculatedSizes=null,this.mutationObserver&&this.mutationObserver.disconnect(),super.destroy()}};g([ue("eGridDiv")],jc.prototype,"eGridDiv",2),g([ae],jc.prototype,"postConstruct",1),jc=g([ce("environment")],jc);var Kc=class extends rt{constructor(){super(...arguments),this.scrollY=0,this.uiBodyHeight=0}agWire(e){this.logger=e.create("RowContainerHeightService")}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_BODY_HEIGHT_CHANGED,this.updateOffset.bind(this)),this.maxDivHeight=Ni(),this.logger.log("maxDivHeight = "+this.maxDivHeight)}isStretching(){return this.stretching}getDivStretchOffset(){return this.divStretchOffset}updateOffset(){if(!this.stretching)return;const e=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition().top,t=this.getUiBodyHeight();(e!==this.scrollY||t!==this.uiBodyHeight)&&(this.scrollY=e,this.uiBodyHeight=t,this.calculateOffset())}calculateOffset(){this.setUiContainerHeight(this.maxDivHeight),this.pixelsToShave=this.modelHeight-this.uiContainerHeight,this.maxScrollY=this.uiContainerHeight-this.uiBodyHeight;const e=this.scrollY/this.maxScrollY,t=e*this.pixelsToShave;this.logger.log(`Div Stretch Offset = ${t} (${this.pixelsToShave} * ${e})`),this.setDivStretchOffset(t)}setUiContainerHeight(e){e!==this.uiContainerHeight&&(this.uiContainerHeight=e,this.eventService.dispatchEvent({type:lt.EVENT_ROW_CONTAINER_HEIGHT_CHANGED}))}clearOffset(){this.setUiContainerHeight(this.modelHeight),this.pixelsToShave=0,this.setDivStretchOffset(0)}setDivStretchOffset(e){const t="number"==typeof e?Math.floor(e):null;this.divStretchOffset!==t&&(this.divStretchOffset=t,this.eventService.dispatchEvent({type:lt.EVENT_HEIGHT_SCALE_CHANGED}))}setModelHeight(e){this.modelHeight=e,this.stretching=null!=e&&this.maxDivHeight>0&&e>this.maxDivHeight,this.stretching?this.calculateOffset():this.clearOffset()}getUiContainerHeight(){return this.uiContainerHeight}getRealPixelPosition(e){return e-this.divStretchOffset}getUiBodyHeight(){const e=this.ctrlsService.getGridBodyCtrl().getScrollFeature().getVScrollPosition();return e.bottom-e.top}getScrollPositionForPixel(e){if(this.pixelsToShave<=0)return e;const t=e/(this.modelHeight-this.getUiBodyHeight());return this.maxScrollY*t}};g([ue("ctrlsService")],Kc.prototype,"ctrlsService",2),g([f(0,pe("loggerFactory"))],Kc.prototype,"agWire",1),g([ae],Kc.prototype,"postConstruct",1),Kc=g([ce("rowContainerHeightService")],Kc);var $c=class extends rt{init(){this.addManagedPropertyListener("isRowSelectable",()=>this.updateSelectable())}updateSelectableAfterGrouping(){this.updateSelectable(!0)}updateSelectable(e=!1){const t=!!this.gos.get("rowSelection"),i=this.gos.get("isRowSelectable");if(!t||!i)return;const r=this.gos.get("groupSelectsChildren"),n="clientSide"===this.rowModel.getType()&&r,s=[],o=t=>{if(e&&!t.group)return;if(n&&t.group){const e=t.childrenAfterGroup.some(e=>!0===e.selectable);return void t.setRowSelectable(e,!0)}const r=!i||i(t);t.setRowSelectable(r,!0),!r&&t.isSelected()&&s.push(t)};if(n){const e=this.rowModel;new kl(!1,e.getRootNode()).forEachChangedNodeDepthFirst(o,!0,!0)}else this.rowModel.forEachNode(o);s.length&&this.selectionService.setNodesSelected({nodes:s,newValue:!1,source:"selectableChanged"}),n&&this.selectionService instanceof Mc&&this.selectionService.updateGroupsFromChildrenSelections("selectableChanged")}};g([ue("rowModel")],$c.prototype,"rowModel",2),g([ue("selectionService")],$c.prototype,"selectionService",2),g([ae],$c.prototype,"init",1),$c=g([ce("selectableService")],$c);var qc=class extends yn{constructor(){super(),this.previousAndFirstButtonsDisabled=!1,this.nextButtonDisabled=!1,this.lastButtonDisabled=!1,this.areListenersSetup=!1}postConstruct(){const e=this.gos.get("enableRtl");this.setTemplate(this.getTemplate());const{btFirst:t,btPrevious:i,btNext:r,btLast:n,pageSizeComp:s}=this;this.activateTabIndex([t,i,r,n]),t.insertAdjacentElement("afterbegin",$r(e?"last":"first",this.gos)),i.insertAdjacentElement("afterbegin",$r(e?"next":"previous",this.gos)),r.insertAdjacentElement("afterbegin",$r(e?"previous":"next",this.gos)),n.insertAdjacentElement("afterbegin",$r(e?"first":"last",this.gos)),this.addManagedPropertyListener("pagination",this.onPaginationChanged.bind(this)),this.addManagedPropertyListener("suppressPaginationPanel",this.onPaginationChanged.bind(this)),this.addManagedPropertyListeners(["paginationPageSizeSelector","paginationAutoPageSize","suppressPaginationPanel"],()=>this.onPageSizeRelatedOptionsChange()),this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector()),this.onPaginationChanged()}onPaginationChanged(){const e=this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel");this.setDisplayed(e),e&&(this.setupListeners(),this.enableOrDisableButtons(),this.updateRowLabels(),this.setCurrentPageLabel(),this.setTotalLabels(),this.onPageSizeRelatedOptionsChange())}onPageSizeRelatedOptionsChange(){this.pageSizeComp.toggleSelectDisplay(this.pageSizeComp.shouldShowPageSizeSelector())}setupListeners(){this.areListenersSetup||(this.addManagedListener(this.eventService,lt.EVENT_PAGINATION_CHANGED,this.onPaginationChanged.bind(this)),[{el:this.btFirst,fn:this.onBtFirst.bind(this)},{el:this.btPrevious,fn:this.onBtPrevious.bind(this)},{el:this.btNext,fn:this.onBtNext.bind(this)},{el:this.btLast,fn:this.onBtLast.bind(this)}].forEach(e=>{const{el:t,fn:i}=e;this.addManagedListener(t,"click",i),this.addManagedListener(t,"keydown",e=>{e.key!==Yr.ENTER&&e.key!==Yr.SPACE||(e.preventDefault(),i())})}),this.areListenersSetup=!0)}onBtFirst(){this.previousAndFirstButtonsDisabled||this.paginationProxy.goToFirstPage()}setCurrentPageLabel(){const e=this.paginationProxy.getTotalPages()>0,t=this.paginationProxy.getCurrentPage(),i=e?t+1:0;this.lbCurrent.textContent=this.formatNumber(i)}formatNumber(e){const t=this.gos.getCallback("paginationNumberFormatter");if(t)return t({value:e});const i=this.localeService.getLocaleTextFunc();return $i(e,i("thousandSeparator",","),i("decimalSeparator","."))}getTemplate(){const e=this.localeService.getLocaleTextFunc(),t=e("page","Page"),i=e("to","to"),r=e("of","of"),n=e("firstPage","First Page"),s=e("previousPage","Previous Page"),o=e("nextPage","Next Page"),a=e("lastPage","Last Page"),l=this.getCompId();return`<div class="ag-paging-panel ag-unselectable" id="ag-${l}">\n                <ag-page-size-selector ref="pageSizeComp"></ag-page-size-selector>\n                <span class="ag-paging-row-summary-panel" role="status">\n                    <span id="ag-${l}-first-row" ref="lbFirstRowOnPage" class="ag-paging-row-summary-panel-number"></span>\n                    <span id="ag-${l}-to">${i}</span>\n                    <span id="ag-${l}-last-row" ref="lbLastRowOnPage" class="ag-paging-row-summary-panel-number"></span>\n                    <span id="ag-${l}-of">${r}</span>\n                    <span id="ag-${l}-row-count" ref="lbRecordCount" class="ag-paging-row-summary-panel-number"></span>\n                </span>\n                <span class="ag-paging-page-summary-panel" role="presentation">\n                    <div ref="btFirst" class="ag-button ag-paging-button" role="button" aria-label="${n}"></div>\n                    <div ref="btPrevious" class="ag-button ag-paging-button" role="button" aria-label="${s}"></div>\n                    <span class="ag-paging-description" role="status">\n                        <span id="ag-${l}-start-page">${t}</span>\n                        <span id="ag-${l}-start-page-number" ref="lbCurrent" class="ag-paging-number"></span>\n                        <span id="ag-${l}-of-page">${r}</span>\n                        <span id="ag-${l}-of-page-number" ref="lbTotal" class="ag-paging-number"></span>\n                    </span>\n                    <div ref="btNext" class="ag-button ag-paging-button" role="button" aria-label="${o}"></div>\n                    <div ref="btLast" class="ag-button ag-paging-button" role="button" aria-label="${a}"></div>\n                </span>\n            </div>`}onBtNext(){this.nextButtonDisabled||this.paginationProxy.goToNextPage()}onBtPrevious(){this.previousAndFirstButtonsDisabled||this.paginationProxy.goToPreviousPage()}onBtLast(){this.lastButtonDisabled||this.paginationProxy.goToLastPage()}enableOrDisableButtons(){const e=this.paginationProxy.getCurrentPage(),t=this.paginationProxy.isLastPageFound(),i=this.paginationProxy.getTotalPages();this.previousAndFirstButtonsDisabled=0===e,this.toggleButtonDisabled(this.btFirst,this.previousAndFirstButtonsDisabled),this.toggleButtonDisabled(this.btPrevious,this.previousAndFirstButtonsDisabled);const r=this.isZeroPagesToDisplay(),n=e===i-1;this.nextButtonDisabled=n||r,this.lastButtonDisabled=!t||r||e===i-1,this.toggleButtonDisabled(this.btNext,this.nextButtonDisabled),this.toggleButtonDisabled(this.btLast,this.lastButtonDisabled)}toggleButtonDisabled(e,t){Zt(e,t),e.classList.toggle("ag-disabled",t)}updateRowLabels(){const e=this.paginationProxy.getCurrentPage(),t=this.paginationProxy.getPageSize(),i=this.paginationProxy.isLastPageFound(),r=this.paginationProxy.isLastPageFound()?this.paginationProxy.getMasterRowCount():null;let n,s;if(this.isZeroPagesToDisplay()?n=s=0:(n=t*e+1,s=n+t-1,i&&s>r&&(s=r)),this.lbFirstRowOnPage.textContent=this.formatNumber(n),this.rowNodeBlockLoader.isLoading()){const e=this.localeService.getLocaleTextFunc();this.lbLastRowOnPage.innerHTML=e("pageLastRowUnknown","?")}else this.lbLastRowOnPage.textContent=this.formatNumber(s)}isZeroPagesToDisplay(){const e=this.paginationProxy.isLastPageFound(),t=this.paginationProxy.getTotalPages();return e&&0===t}setTotalLabels(){const e=this.paginationProxy.isLastPageFound(),t=this.paginationProxy.getTotalPages(),i=e?this.paginationProxy.getMasterRowCount():null;if(1===i){const e=this.paginationProxy.getRow(0);if(e&&e.group&&!e.groupData&&!e.aggData)return void this.setTotalLabelsToZero()}if(e)this.lbTotal.textContent=this.formatNumber(t),this.lbRecordCount.textContent=this.formatNumber(i);else{const e=this.localeService.getLocaleTextFunc()("more","more");this.lbTotal.innerHTML=e,this.lbRecordCount.innerHTML=e}}setTotalLabelsToZero(){this.lbFirstRowOnPage.textContent=this.formatNumber(0),this.lbCurrent.textContent=this.formatNumber(0),this.lbLastRowOnPage.textContent=this.formatNumber(0),this.lbTotal.textContent=this.formatNumber(0),this.lbRecordCount.textContent=this.formatNumber(0)}};g([ue("paginationProxy")],qc.prototype,"paginationProxy",2),g([ue("rowNodeBlockLoader")],qc.prototype,"rowNodeBlockLoader",2),g([Sn("btFirst")],qc.prototype,"btFirst",2),g([Sn("btPrevious")],qc.prototype,"btPrevious",2),g([Sn("btNext")],qc.prototype,"btNext",2),g([Sn("btLast")],qc.prototype,"btLast",2),g([Sn("lbRecordCount")],qc.prototype,"lbRecordCount",2),g([Sn("lbFirstRowOnPage")],qc.prototype,"lbFirstRowOnPage",2),g([Sn("lbLastRowOnPage")],qc.prototype,"lbLastRowOnPage",2),g([Sn("lbCurrent")],qc.prototype,"lbCurrent",2),g([Sn("lbTotal")],qc.prototype,"lbTotal",2),g([Sn("pageSizeComp")],qc.prototype,"pageSizeComp",2),g([ae],qc.prototype,"postConstruct",1);var Yc=class e extends yn{constructor(){super(e.TEMPLATE),this.inProgress=!1,this.destroyRequested=!1}updateLayoutClasses(e,t){const i=this.eOverlayWrapper.classList;i.toggle("ag-layout-auto-height",t.autoHeight),i.toggle("ag-layout-normal",t.normal),i.toggle("ag-layout-print",t.print)}postConstruct(){this.createManagedBean(new Qo(this)),this.setDisplayed(!1,{skipAriaHidden:!0}),this.overlayService.registerOverlayWrapperComp(this)}setWrapperTypeClass(e){const t=this.eOverlayWrapper.classList;this.activeOverlayWrapperCssClass&&t.toggle(this.activeOverlayWrapperCssClass,!1),this.activeOverlayWrapperCssClass=e,t.toggle(e,!0)}showOverlay(e,t,i){this.inProgress||(this.setWrapperTypeClass(t),this.destroyActiveOverlay(),this.inProgress=!0,e&&e.then(e=>{this.inProgress=!1,this.eOverlayWrapper.appendChild(e.getGui()),this.activeOverlay=e,this.updateListenerDestroyFunc=i,this.destroyRequested&&(this.destroyRequested=!1,this.destroyActiveOverlay())}),this.setDisplayed(!0,{skipAriaHidden:!0}))}destroyActiveOverlay(){var e;this.inProgress?this.destroyRequested=!0:this.activeOverlay&&(this.activeOverlay=this.getContext().destroyBean(this.activeOverlay),null==(e=this.updateListenerDestroyFunc)||e.call(this),Cr(this.eOverlayWrapper))}hideOverlay(){this.destroyActiveOverlay(),this.setDisplayed(!1,{skipAriaHidden:!0})}destroy(){this.destroyActiveOverlay(),super.destroy()}};Yc.TEMPLATE='\n        <div class="ag-overlay" role="presentation">\n            <div class="ag-overlay-panel" role="presentation">\n                <div class="ag-overlay-wrapper" ref="eOverlayWrapper" role="presentation"></div>\n            </div>\n        </div>',g([ue("overlayService")],Yc.prototype,"overlayService",2),g([Sn("eOverlayWrapper")],Yc.prototype,"eOverlayWrapper",2),g([ae],Yc.prototype,"postConstruct",1);var Qc=Yc,Xc=class extends rt{getFirstRow(){let e,t=0;return this.pinnedRowModel.getPinnedTopRowCount()?e="top":this.rowModel.getRowCount()?(e=null,t=this.paginationProxy.getPageFirstRow()):this.pinnedRowModel.getPinnedBottomRowCount()&&(e="bottom"),void 0===e?null:{rowIndex:t,rowPinned:e}}getLastRow(){let e,t=null;const i=this.pinnedRowModel.getPinnedBottomRowCount(),r=this.pinnedRowModel.getPinnedTopRowCount();return i?(t="bottom",e=i-1):this.rowModel.getRowCount()?(t=null,e=this.paginationProxy.getPageLastRow()):r&&(t="top",e=r-1),void 0===e?null:{rowIndex:e,rowPinned:t}}getRowNode(e){switch(e.rowPinned){case"top":return this.pinnedRowModel.getPinnedTopRowData()[e.rowIndex];case"bottom":return this.pinnedRowModel.getPinnedBottomRowData()[e.rowIndex];default:return this.rowModel.getRow(e.rowIndex)}}sameRow(e,t){return!e&&!t||!(e&&!t||!e&&t)&&e.rowIndex===t.rowIndex&&e.rowPinned==t.rowPinned}before(e,t){switch(e.rowPinned){case"top":if("top"!==t.rowPinned)return!0;break;case"bottom":if("bottom"!==t.rowPinned)return!1;break;default:if(C(t.rowPinned))return"top"!==t.rowPinned}return e.rowIndex<t.rowIndex}};g([ue("rowModel")],Xc.prototype,"rowModel",2),g([ue("pinnedRowModel")],Xc.prototype,"pinnedRowModel",2),g([ue("paginationProxy")],Xc.prototype,"paginationProxy",2),Xc=g([ce("rowPositionUtils")],Xc);var Zc=class extends rt{createId(e){const{rowIndex:t,rowPinned:i,column:r}=e;return this.createIdFromValues({rowIndex:t,column:r,rowPinned:i})}createIdFromValues(e){const{rowIndex:t,rowPinned:i,column:r}=e;return`${t}.${null==i?"null":i}.${r.getId()}`}equals(e,t){const i=e.column===t.column,r=e.rowPinned===t.rowPinned,n=e.rowIndex===t.rowIndex;return i&&r&&n}};Zc=g([ce("cellPositionUtils")],Zc);var Jc=class{constructor(e){this.cellValueChanges=e}},eu=class extends Jc{constructor(e,t,i,r){super(e),this.initialRange=t,this.finalRange=i,this.ranges=r}},tu=class e{constructor(t){this.actionStack=[],this.maxStackSize=t||e.DEFAULT_STACK_SIZE,this.actionStack=new Array(this.maxStackSize)}pop(){return this.actionStack.pop()}push(e){e.cellValueChanges&&e.cellValueChanges.length>0&&(this.actionStack.length===this.maxStackSize&&this.actionStack.shift(),this.actionStack.push(e))}clear(){this.actionStack=[]}getCurrentStackSize(){return this.actionStack.length}};tu.DEFAULT_STACK_SIZE=10;var iu=tu,ru=class extends rt{constructor(){super(...arguments),this.cellValueChanges=[],this.activeCellEdit=null,this.activeRowEdit=null,this.isPasting=!1,this.isRangeInAction=!1,this.onCellValueChanged=e=>{const t={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned},i=null!==this.activeCellEdit&&this.cellPositionUtils.equals(this.activeCellEdit,t),r=null!==this.activeRowEdit&&this.rowPositionUtils.sameRow(this.activeRowEdit,t);if(!(i||r||this.isPasting||this.isRangeInAction))return;const{rowPinned:n,rowIndex:s,column:o,oldValue:a,value:l}=e,c={rowPinned:n,rowIndex:s,columnId:o.getColId(),newValue:l,oldValue:a};this.cellValueChanges.push(c)},this.clearStacks=()=>{this.undoStack.clear(),this.redoStack.clear()}}init(){if(!this.gos.get("undoRedoCellEditing"))return;const e=this.gos.get("undoRedoCellEditingLimit");e<=0||(this.undoStack=new iu(e),this.redoStack=new iu(e),this.addRowEditingListeners(),this.addCellEditingListeners(),this.addPasteListeners(),this.addFillListeners(),this.addCellKeyListeners(),this.addManagedListener(this.eventService,lt.EVENT_CELL_VALUE_CHANGED,this.onCellValueChanged),this.addManagedListener(this.eventService,lt.EVENT_MODEL_UPDATED,e=>{e.keepUndoRedoStack||this.clearStacks()}),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_GROUP_OPENED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_MOVED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PINNED,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VISIBLE,this.clearStacks),this.addManagedListener(this.eventService,lt.EVENT_ROW_DRAG_END,this.clearStacks),this.ctrlsService.whenReady(e=>{this.gridBodyCtrl=e.gridBodyCtrl}))}getCurrentUndoStackSize(){return this.undoStack?this.undoStack.getCurrentStackSize():0}getCurrentRedoStackSize(){return this.redoStack?this.redoStack.getCurrentStackSize():0}undo(e){const t={type:lt.EVENT_UNDO_STARTED,source:e};this.eventService.dispatchEvent(t);const i=this.undoRedo(this.undoStack,this.redoStack,"initialRange","oldValue","undo"),r={type:lt.EVENT_UNDO_ENDED,source:e,operationPerformed:i};this.eventService.dispatchEvent(r)}redo(e){const t={type:lt.EVENT_REDO_STARTED,source:e};this.eventService.dispatchEvent(t);const i=this.undoRedo(this.redoStack,this.undoStack,"finalRange","newValue","redo"),r={type:lt.EVENT_REDO_ENDED,source:e,operationPerformed:i};this.eventService.dispatchEvent(r)}undoRedo(e,t,i,r,n){if(!e)return!1;const s=e.pop();return!(!s||!s.cellValueChanges||(this.processAction(s,e=>e[r],n),s instanceof eu?this.processRange(this.rangeService,s.ranges||[s[i]]):this.processCell(s.cellValueChanges),t.push(s),0))}processAction(e,t,i){e.cellValueChanges.forEach(e=>{const{rowIndex:r,rowPinned:n,columnId:s}=e,o={rowIndex:r,rowPinned:n},a=this.rowPositionUtils.getRowNode(o);a.displayed&&a.setDataValue(s,t(e),i)})}processRange(e,t){let i;e.removeAllCellRanges(!0),t.forEach((r,n)=>{if(!r)return;const s=r.startRow,o=r.endRow;n===t.length-1&&(i={rowPinned:s.rowPinned,rowIndex:s.rowIndex,columnId:r.startColumn.getColId()},this.setLastFocusedCell(i));const a={rowStartIndex:s.rowIndex,rowStartPinned:s.rowPinned,rowEndIndex:o.rowIndex,rowEndPinned:o.rowPinned,columnStart:r.startColumn,columns:r.columns};e.addCellRange(a)})}processCell(e){const t=e[0],{rowIndex:i,rowPinned:r}=t,n={rowIndex:i,rowPinned:r},s=this.rowPositionUtils.getRowNode(n),o={rowPinned:t.rowPinned,rowIndex:s.rowIndex,columnId:t.columnId};this.setLastFocusedCell(o,this.rangeService)}setLastFocusedCell(e,t){const{rowIndex:i,columnId:r,rowPinned:n}=e,s=this.gridBodyCtrl.getScrollFeature(),o=this.columnModel.getGridColumn(r);if(!o)return;s.ensureIndexVisible(i),s.ensureColumnVisible(o);const a={rowIndex:i,column:o,rowPinned:n};this.focusService.setFocusedCell(d(h({},a),{forceBrowserFocus:!0})),null==t||t.setRangeToCell(a)}addRowEditingListeners(){this.addManagedListener(this.eventService,lt.EVENT_ROW_EDITING_STARTED,e=>{this.activeRowEdit={rowIndex:e.rowIndex,rowPinned:e.rowPinned}}),this.addManagedListener(this.eventService,lt.EVENT_ROW_EDITING_STOPPED,()=>{const e=new Jc(this.cellValueChanges);this.pushActionsToUndoStack(e),this.activeRowEdit=null})}addCellEditingListeners(){this.addManagedListener(this.eventService,lt.EVENT_CELL_EDITING_STARTED,e=>{this.activeCellEdit={column:e.column,rowIndex:e.rowIndex,rowPinned:e.rowPinned}}),this.addManagedListener(this.eventService,lt.EVENT_CELL_EDITING_STOPPED,e=>{if(this.activeCellEdit=null,e.valueChanged&&!this.activeRowEdit&&!this.isPasting&&!this.isRangeInAction){const e=new Jc(this.cellValueChanges);this.pushActionsToUndoStack(e)}})}addPasteListeners(){this.addManagedListener(this.eventService,lt.EVENT_PASTE_START,()=>{this.isPasting=!0}),this.addManagedListener(this.eventService,lt.EVENT_PASTE_END,()=>{const e=new Jc(this.cellValueChanges);this.pushActionsToUndoStack(e),this.isPasting=!1})}addFillListeners(){this.addManagedListener(this.eventService,lt.EVENT_FILL_START,()=>{this.isRangeInAction=!0}),this.addManagedListener(this.eventService,lt.EVENT_FILL_END,e=>{const t=new eu(this.cellValueChanges,e.initialRange,e.finalRange);this.pushActionsToUndoStack(t),this.isRangeInAction=!1})}addCellKeyListeners(){this.addManagedListener(this.eventService,lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_START,()=>{this.isRangeInAction=!0}),this.addManagedListener(this.eventService,lt.EVENT_KEY_SHORTCUT_CHANGED_CELL_END,()=>{let e;e=this.rangeService&&this.gos.get("enableRangeSelection")?new eu(this.cellValueChanges,void 0,void 0,[...this.rangeService.getCellRanges()]):new Jc(this.cellValueChanges),this.pushActionsToUndoStack(e),this.isRangeInAction=!1})}pushActionsToUndoStack(e){this.undoStack.push(e),this.cellValueChanges=[],this.redoStack.clear()}};g([ue("focusService")],ru.prototype,"focusService",2),g([ue("ctrlsService")],ru.prototype,"ctrlsService",2),g([ue("cellPositionUtils")],ru.prototype,"cellPositionUtils",2),g([ue("rowPositionUtils")],ru.prototype,"rowPositionUtils",2),g([ue("columnModel")],ru.prototype,"columnModel",2),g([he("rangeService")],ru.prototype,"rangeService",2),g([ae],ru.prototype,"init",1),ru=g([ce("undoRedoService")],ru);var nu=class extends rt{findHeader(e,t){let i,r;if(e.column instanceof at?i=this.columnModel.getDisplayedGroupAtDirection(e.column,t):(r=`getDisplayedCol${t}`,i=this.columnModel[r](e.column)),!i)return;let{headerRowIndex:n}=e;if("filter"!==this.getHeaderRowType(n)){const e=[i];for(;i.getParent();)i=i.getParent(),e.push(i);i=e[e.length-1-n]}const{column:s,headerRowIndex:o}=this.getHeaderIndexToFocus(i,n);return{column:s,headerRowIndex:o}}getHeaderIndexToFocus(e,t){let i;if(e instanceof at&&this.isAnyChildSpanningHeaderHeight(e)&&e.isPadding()){const r=e;i=r.getLeafColumns()[0];let n=i;for(;n!==r;)t++,n=n.getParent()}return{column:i||e,headerRowIndex:t}}isAnyChildSpanningHeaderHeight(e){return!!e&&e.getLeafColumns().some(e=>e.isSpanHeaderHeight())}getColumnVisibleParent(e,t){const i=this.getHeaderRowType(t),r="column"===i;let n="filter"===i?e:e.getParent(),s=t-1,o=s;if(r&&this.isAnyChildSpanningHeaderHeight(e.getParent())){for(;n&&n.isPadding();)n=n.getParent(),s--;o=s,s<0&&(n=e,s=t,o=void 0)}return{column:n,headerRowIndex:s,headerRowIndexWithoutSpan:o}}getColumnVisibleChild(e,t,i="After"){let r=e,n=t+1,s=n;if("group"===this.getHeaderRowType(t)){const t=e.getDisplayedLeafColumns(),s="After"===i?t[0]:_e(t),o=[];let a=s;for(;a.getParent()!==e;)a=a.getParent(),o.push(a);if(r=s,s.isSpanHeaderHeight())for(let e=o.length-1;e>=0;e--){const t=o[e];if(!t.isPadding()){r=t;break}n++}else r=_e(o),r||(r=s)}return{column:r,headerRowIndex:n,headerRowIndexWithoutSpan:s}}getHeaderRowType(e){const t=this.ctrlsService.getHeaderRowContainerCtrl();if(t)return t.getRowType(e)}findColAtEdgeForHeaderRow(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=i["start"===t?0:i.length-1];if(!r)return;const n=this.ctrlsService.getHeaderRowContainerCtrl(r.getPinned()).getRowType(e);return"group"==n?{headerRowIndex:e,column:this.columnModel.getColumnGroupAtLevel(r,e)}:{headerRowIndex:null==n?-1:e,column:r}}};g([ue("columnModel")],nu.prototype,"columnModel",2),g([ue("ctrlsService")],nu.prototype,"ctrlsService",2),nu=g([ce("headerPositionUtils")],nu);var su=class{buildColumnDefs(e,t,i){const r=[],n={};return e.forEach(e=>{let s=!0,o=this.createDefFromColumn(e,t,i),a=e.getOriginalParent(),l=null;for(;a;){let e=null;if(a.isPadding()){a=a.getOriginalParent();continue}const t=n[a.getGroupId()];if(t){t.children.push(o),s=!1;break}if(e=this.createDefFromGroup(a),e&&(e.children=[o],n[e.groupId]=e,o=e,a=a.getOriginalParent()),null!=a&&l===a){s=!1;break}l=a}s&&r.push(o)}),r}createDefFromGroup(e){const t=L(e.getColGroupDef(),["children"]);return t&&(t.groupId=e.getGroupId()),t}createDefFromColumn(e,t,i){const r=L(e.getColDef());return r.colId=e.getColId(),r.width=e.getActualWidth(),r.rowGroup=e.isRowGroupActive(),r.rowGroupIndex=e.isRowGroupActive()?t.indexOf(e):null,r.pivot=e.isPivotActive(),r.pivotIndex=e.isPivotActive()?i.indexOf(e):null,r.aggFunc=e.isValueActive()?e.getAggFunc():null,r.hide=!e.isVisible()||void 0,r.pinned=e.isPinned()?e.getPinned():null,r.sort=e.getSort()?e.getSort():null,r.sortIndex=null!=e.getSortIndex()?e.getSortIndex():null,r}};su=g([ce("columnDefFactory")],su);var ou=class{getInitialRowClasses(e){const t=[];return C(e.extraCssClass)&&t.push(e.extraCssClass),t.push("ag-row"),t.push(e.rowFocused?"ag-row-focus":"ag-row-no-focus"),e.fadeRowIn&&t.push("ag-opacity-zero"),t.push(e.rowIsEven?"ag-row-even":"ag-row-odd"),e.rowNode.isRowPinned()&&t.push("ag-row-pinned"),e.rowNode.isSelected()&&t.push("ag-row-selected"),e.rowNode.footer&&t.push("ag-row-footer"),t.push("ag-row-level-"+e.rowLevel),e.rowNode.stub&&t.push("ag-row-loading"),e.fullWidthRow&&t.push("ag-full-width-row"),e.expandable&&(t.push("ag-row-group"),t.push(e.rowNode.expanded?"ag-row-group-expanded":"ag-row-group-contracted")),e.rowNode.dragging&&t.push("ag-row-dragging"),ze(t,this.processClassesFromGridOptions(e.rowNode)),ze(t,this.preProcessRowClassRules(e.rowNode)),t.push(e.printLayout?"ag-row-position-relative":"ag-row-position-absolute"),e.firstRowOnPage&&t.push("ag-row-first"),e.lastRowOnPage&&t.push("ag-row-last"),e.fullWidthRow&&("left"===e.pinned&&t.push("ag-cell-last-left-pinned"),"right"===e.pinned&&t.push("ag-cell-first-right-pinned")),t}processClassesFromGridOptions(e){const t=[],i=e=>{"string"==typeof e?t.push(e):Array.isArray(e)&&e.forEach(e=>t.push(e))},r=this.gos.get("rowClass");if(r){if("function"==typeof r)return console.warn("AG Grid: rowClass should not be a function, please use getRowClass instead"),[];i(r)}const n=this.gos.getCallback("getRowClass");return n&&i(n({data:e.data,node:e,rowIndex:e.rowIndex})),t}preProcessRowClassRules(e){const t=[];return this.processRowClassRules(e,e=>{t.push(e)},e=>{}),t}processRowClassRules(e,t,i){const r=this.gos.addGridCommonParams({data:e.data,node:e,rowIndex:e.rowIndex});this.stylingService.processClassRules(void 0,this.gos.get("rowClassRules"),r,t,i)}calculateRowLevel(e){return e.group?e.level:e.parent?e.parent.level+1:0}};g([ue("stylingService")],ou.prototype,"stylingService",2),g([ue("gridOptionsService")],ou.prototype,"gos",2),ou=g([ce("rowCssClassCalculator")],ou);var au=class extends rt{init(){this.isAccentedSort=this.gos.get("accentedSort"),this.primaryColumnsSortGroups=this.gos.isColumnsSortingCoupledToGroup(),this.addManagedPropertyListener("accentedSort",e=>this.isAccentedSort=e.currentValue),this.addManagedPropertyListener("autoGroupColumnDef",()=>this.primaryColumnsSortGroups=this.gos.isColumnsSortingCoupledToGroup())}doFullSort(e,t){const i=e.map((e,t)=>({currentPos:t,rowNode:e}));return i.sort(this.compareRowNodes.bind(this,t)),i.map(e=>e.rowNode)}compareRowNodes(e,t,i){const r=t.rowNode,n=i.rowNode;for(let t=0,i=e.length;t<i;t++){const i=e[t],s="desc"===i.sort,o=this.getValue(r,i.column),a=this.getValue(n,i.column);let l;const c=this.getComparator(i,r);if(l=c?c(o,a,r,n,s):ln.defaultComparator(o,a,this.isAccentedSort),!isNaN(l)&&0!==l)return"asc"===i.sort?l:-1*l}return t.currentPos-i.currentPos}getComparator(e,t){const i=e.column,r=i.getColDef().comparator;if(null!=r)return r;if(!i.getColDef().showRowGroup)return;const n=!t.group&&i.getColDef().field;if(!n)return;const s=this.columnModel.getPrimaryColumn(n);return s?s.getColDef().comparator:void 0}getValue(e,t){var i,r;if(!this.primaryColumnsSortGroups)return this.valueService.getValue(t,e,!1,!1);if(e.rowGroupColumn===t){if(this.gos.isGroupUseEntireRow(this.columnModel.isPivotActive())){const r=null==(i=e.allLeafChildren)?void 0:i[0];return r?this.valueService.getValue(t,r,!1,!1):void 0}const n=this.columnModel.getGroupDisplayColumnForGroup(t.getId());if(!n)return;return null==(r=e.groupData)?void 0:r[n.getId()]}return e.group&&t.getColDef().showRowGroup?void 0:this.valueService.getValue(t,e,!1,!1)}};g([ue("valueService")],au.prototype,"valueService",2),g([ue("columnModel")],au.prototype,"columnModel",2),g([ae],au.prototype,"init",1),au=g([ce("rowNodeSorter")],au);var lu=class extends rt{constructor(){super(...arguments),this.params={},this.ready=!1,this.readyCallbacks=[]}checkReady(){const e=this.params;this.ready=null!=e.gridCtrl&&null!=e.gridBodyCtrl&&null!=e.center&&null!=e.left&&null!=e.right&&null!=e.bottomCenter&&null!=e.bottomLeft&&null!=e.bottomRight&&null!=e.topCenter&&null!=e.topLeft&&null!=e.topRight&&null!=e.stickyTopCenter&&null!=e.stickyTopLeft&&null!=e.stickyTopRight&&null!=e.stickyBottomCenter&&null!=e.stickyBottomLeft&&null!=e.stickyBottomRight&&null!=e.centerHeader&&null!=e.leftHeader&&null!=e.rightHeader&&null!=e.fakeHScrollComp&&null!=e.fakeVScrollComp&&null!=e.gridHeaderCtrl,this.ready&&(this.readyCallbacks.forEach(t=>t(e)),this.readyCallbacks.length=0)}whenReady(e){this.ready?e(this.params):this.readyCallbacks.push(e)}register(e,t){this.params[e]=t,this.checkReady()}registerHeaderContainer(e,t){switch(t){case"left":this.params.leftHeader=e;break;case"right":this.params.rightHeader=e;break;default:this.params.centerHeader=e}this.checkReady()}get(e){return this.params[e]}getParams(){return this.params}getGridBodyCtrl(){return this.params.gridBodyCtrl}getHeaderRowContainerCtrls(){return[this.params.leftHeader,this.params.rightHeader,this.params.centerHeader]}getHeaderRowContainerCtrl(e){switch(e){case"left":return this.params.leftHeader;case"right":return this.params.rightHeader;default:return this.params.centerHeader}}};lu.NAME="ctrlsService",lu=g([ce(lu.NAME)],lu);var cu=class extends rt{constructor(){super(...arguments),this.registry={}}register(e){this.registry[e.controllerName]=e.controllerClass}getInstance(e){const t=this.registry[e];if(null!=t)return new t}};cu=g([ce("ctrlsFactory")],cu);var uu=class extends yn{constructor(e,t){super(e),this.direction=t,this.hideTimeout=null}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_SCROLL_VISIBILITY_CHANGED,this.onScrollVisibilityChanged.bind(this)),this.onScrollVisibilityChanged(),this.addOrRemoveCssClass("ag-apple-scrollbar",xi()||Di())}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.invisibleScrollbar=Vi(),this.invisibleScrollbar&&(this.hideAndShowInvisibleScrollAsNeeded(),this.addActiveListenerToggles()))}addActiveListenerToggles(){const e=this.getGui();["mouseenter","mousedown","touchstart"].forEach(t=>this.addManagedListener(e,t,()=>this.addOrRemoveCssClass("ag-scrollbar-active",!0))),["mouseleave","touchend"].forEach(t=>this.addManagedListener(e,t,()=>this.addOrRemoveCssClass("ag-scrollbar-active",!1)))}onScrollVisibilityChanged(){void 0===this.invisibleScrollbar&&this.initialiseInvisibleScrollbar(),this.animationFrameService.requestAnimationFrame(()=>this.setScrollVisible())}hideAndShowInvisibleScrollAsNeeded(){this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL,e=>{e.direction===this.direction&&(null!==this.hideTimeout&&(window.clearTimeout(this.hideTimeout),this.hideTimeout=null),this.addOrRemoveCssClass("ag-scrollbar-scrolling",!0))}),this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL_END,()=>{this.hideTimeout=window.setTimeout(()=>{this.addOrRemoveCssClass("ag-scrollbar-scrolling",!1),this.hideTimeout=null},400)})}attemptSettingScrollPosition(e){const t=this.getViewport();J(()=>Sr(t),()=>this.setScrollPosition(e),100)}getViewport(){return this.eViewport}getContainer(){return this.eContainer}onScrollCallback(e){this.addManagedListener(this.getViewport(),"scroll",e)}};g([Sn("eViewport")],uu.prototype,"eViewport",2),g([Sn("eContainer")],uu.prototype,"eContainer",2),g([ue("scrollVisibleService")],uu.prototype,"scrollVisibleService",2),g([ue("ctrlsService")],uu.prototype,"ctrlsService",2),g([ue("animationFrameService")],uu.prototype,"animationFrameService",2);var hu=class e extends uu{constructor(){super(e.TEMPLATE,"horizontal")}postConstruct(){super.postConstruct();const e=this.setFakeHScrollSpacerWidths.bind(this);this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_PINNED_ROW_DATA_CHANGED,this.onPinnedRowDataChanged.bind(this)),this.addManagedPropertyListener("domLayout",e),this.ctrlsService.register("fakeHScrollComp",this),this.createManagedBean(new Aa(e=>this.eContainer.style.width=`${e}px`)),this.addManagedPropertyListeners(["suppressHorizontalScroll"],this.onScrollVisibilityChanged.bind(this))}initialiseInvisibleScrollbar(){void 0===this.invisibleScrollbar&&(this.enableRtl=this.gos.get("enableRtl"),super.initialiseInvisibleScrollbar(),this.invisibleScrollbar&&this.refreshCompBottom())}onPinnedRowDataChanged(){this.refreshCompBottom()}refreshCompBottom(){if(!this.invisibleScrollbar)return;const e=this.pinnedRowModel.getPinnedBottomTotalHeight();this.getGui().style.bottom=`${e}px`}onScrollVisibilityChanged(){super.onScrollVisibilityChanged(),this.setFakeHScrollSpacerWidths()}setFakeHScrollSpacerWidths(){const e=this.scrollVisibleService.isVerticalScrollShowing();let t=this.columnModel.getDisplayedColumnsRightWidth();const i=!this.enableRtl&&e,r=this.gos.getScrollbarWidth();i&&(t+=r),xr(this.eRightSpacer,t),this.eRightSpacer.classList.toggle("ag-scroller-corner",t<=r);let n=this.columnModel.getDisplayedColumnsLeftWidth();this.enableRtl&&e&&(n+=r),xr(this.eLeftSpacer,n),this.eLeftSpacer.classList.toggle("ag-scroller-corner",n<=r)}setScrollVisible(){const e=this.scrollVisibleService.isHorizontalScrollShowing(),t=this.invisibleScrollbar,i=this.gos.get("suppressHorizontalScroll"),r=e&&this.gos.getScrollbarWidth()||0,n=i?0:0===r&&t?16:r;this.addOrRemoveCssClass("ag-scrollbar-invisible",t),Ir(this.getGui(),n),Ir(this.eViewport,n),Ir(this.eContainer,n),this.setDisplayed(e,{skipAriaHidden:!0})}getScrollPosition(){return mr(this.getViewport(),this.enableRtl)}setScrollPosition(e){Sr(this.getViewport())||this.attemptSettingScrollPosition(e),vr(this.getViewport(),e,this.enableRtl)}};hu.TEMPLATE='<div class="ag-body-horizontal-scroll" aria-hidden="true">\n            <div class="ag-horizontal-left-spacer" ref="eLeftSpacer"></div>\n            <div class="ag-body-horizontal-scroll-viewport" ref="eViewport">\n                <div class="ag-body-horizontal-scroll-container" ref="eContainer"></div>\n            </div>\n            <div class="ag-horizontal-right-spacer" ref="eRightSpacer"></div>\n        </div>',g([Sn("eLeftSpacer")],hu.prototype,"eLeftSpacer",2),g([Sn("eRightSpacer")],hu.prototype,"eRightSpacer",2),g([ue("columnModel")],hu.prototype,"columnModel",2),g([ue("pinnedRowModel")],hu.prototype,"pinnedRowModel",2),g([ae],hu.prototype,"postConstruct",1);var du=hu,pu=class extends rt{postConstruct(){const e=this.checkContainerWidths.bind(this);this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_DISPLAYED_COLUMNS_WIDTH_CHANGED,e),this.addManagedPropertyListener("domLayout",e)}checkContainerWidths(){const e=this.gos.isDomLayout("print"),t=e?0:this.columnModel.getDisplayedColumnsLeftWidth(),i=e?0:this.columnModel.getDisplayedColumnsRightWidth();t!=this.leftWidth&&(this.leftWidth=t,this.eventService.dispatchEvent({type:lt.EVENT_LEFT_PINNED_WIDTH_CHANGED})),i!=this.rightWidth&&(this.rightWidth=i,this.eventService.dispatchEvent({type:lt.EVENT_RIGHT_PINNED_WIDTH_CHANGED}))}getPinnedRightWidth(){return this.rightWidth}getPinnedLeftWidth(){return this.leftWidth}};g([ue("columnModel")],pu.prototype,"columnModel",2),g([ae],pu.prototype,"postConstruct",1),pu=g([ce("pinnedWidthService")],pu);var gu=class extends rt{constructor(){super(...arguments),this.events=[]}postConstruct(){"clientSide"==this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel)}dispatchExpanded(e,t){if(null==this.clientSideRowModel)return void this.eventService.dispatchEvent(e);this.events.push(e);const i=()=>{this.clientSideRowModel&&this.clientSideRowModel.onRowGroupOpened(),this.events.forEach(e=>this.eventService.dispatchEvent(e)),this.events=[]};t?i():(null==this.dispatchExpandedDebounced&&(this.dispatchExpandedDebounced=this.animationFrameService.debounce(i)),this.dispatchExpandedDebounced())}};g([ue("animationFrameService")],gu.prototype,"animationFrameService",2),g([ue("rowModel")],gu.prototype,"rowModel",2),g([ae],gu.prototype,"postConstruct",1),gu=g([ce("rowNodeEventThrottle")],gu);var fu=(e,t)=>{var i;return"clientSide"===(null!=(i=t.rowModelType)?i:"clientSide")?{module:"@ag-grid-enterprise/row-grouping"}:null},mu={enableRowGroup:fu,rowGroup:fu,rowGroupIndex:fu,enablePivot:fu,enableValue:fu,pivot:fu,pivotIndex:fu,aggFunc:fu,cellEditor:e=>"agRichSelect"===e.cellEditor||"agRichSelectCellEditor"===e.cellEditor?{module:"@ag-grid-enterprise/rich-select"}:null,menuTabs:e=>{var t;const i=["columnsMenuTab","generalMenuTab"];return(null==(t=e.menuTabs)?void 0:t.some(e=>i.includes(e)))?{module:"@ag-grid-enterprise/menu"}:null},columnsMenuParams:{module:["@ag-grid-enterprise/menu","@ag-grid-enterprise/column-tool-panel"]},columnChooserParams:{module:["@ag-grid-enterprise/menu","@ag-grid-enterprise/column-tool-panel"]},headerCheckboxSelection:{supportedRowModels:["clientSide","serverSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelection is only supported with rowSelection=multiple"},headerCheckboxSelectionFilteredOnly:{supportedRowModels:["clientSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionFilteredOnly is only supported with rowSelection=multiple"},headerCheckboxSelectionCurrentPageOnly:{supportedRowModels:["clientSide"],dependencies:(e,{rowSelection:t})=>"multiple"===t?null:"headerCheckboxSelectionCurrentPageOnly is only supported with rowSelection=multiple"},children:()=>vu},vu={objectName:"colDef",allProperties:Object.keys({headerName:void 0,columnGroupShow:void 0,headerClass:void 0,toolPanelClass:void 0,headerValueGetter:void 0,pivotKeys:void 0,groupId:void 0,colId:void 0,sort:void 0,initialSort:void 0,field:void 0,type:void 0,cellDataType:void 0,tooltipComponent:void 0,tooltipField:void 0,headerTooltip:void 0,cellClass:void 0,showRowGroup:void 0,filter:void 0,initialAggFunc:void 0,defaultAggFunc:void 0,aggFunc:void 0,pinned:void 0,initialPinned:void 0,chartDataType:void 0,cellAriaRole:void 0,cellEditorPopupPosition:void 0,headerGroupComponent:void 0,headerGroupComponentParams:void 0,cellStyle:void 0,cellRenderer:void 0,cellRendererParams:void 0,cellEditor:void 0,cellEditorParams:void 0,filterParams:void 0,pivotValueColumn:void 0,headerComponent:void 0,headerComponentParams:void 0,floatingFilterComponent:void 0,floatingFilterComponentParams:void 0,tooltipComponentParams:void 0,refData:void 0,columnsMenuParams:void 0,columnChooserParams:void 0,children:void 0,sortingOrder:void 0,allowedAggFuncs:void 0,menuTabs:void 0,pivotTotalColumnIds:void 0,cellClassRules:void 0,icons:void 0,sortIndex:void 0,initialSortIndex:void 0,flex:void 0,initialFlex:void 0,width:void 0,initialWidth:void 0,minWidth:void 0,maxWidth:void 0,rowGroupIndex:void 0,initialRowGroupIndex:void 0,pivotIndex:void 0,initialPivotIndex:void 0,suppressCellFlash:void 0,suppressColumnsToolPanel:void 0,suppressFiltersToolPanel:void 0,openByDefault:void 0,marryChildren:void 0,suppressStickyLabel:void 0,hide:void 0,initialHide:void 0,rowGroup:void 0,initialRowGroup:void 0,pivot:void 0,initialPivot:void 0,checkboxSelection:void 0,showDisabledCheckboxes:void 0,headerCheckboxSelection:void 0,headerCheckboxSelectionFilteredOnly:void 0,headerCheckboxSelectionCurrentPageOnly:void 0,suppressMenu:void 0,suppressHeaderMenuButton:void 0,suppressMovable:void 0,lockPosition:void 0,lockVisible:void 0,lockPinned:void 0,unSortIcon:void 0,suppressSizeToFit:void 0,suppressAutoSize:void 0,enableRowGroup:void 0,enablePivot:void 0,enableValue:void 0,editable:void 0,suppressPaste:void 0,suppressNavigable:void 0,enableCellChangeFlash:void 0,rowDrag:void 0,dndSource:void 0,autoHeight:void 0,wrapText:void 0,sortable:void 0,resizable:void 0,singleClickEdit:void 0,floatingFilter:void 0,cellEditorPopup:void 0,suppressFillHandle:void 0,wrapHeaderText:void 0,autoHeaderHeight:void 0,dndSourceOnRowDrag:void 0,valueGetter:void 0,valueSetter:void 0,filterValueGetter:void 0,keyCreator:void 0,valueFormatter:void 0,valueParser:void 0,comparator:void 0,equals:void 0,pivotComparator:void 0,suppressKeyboardEvent:void 0,suppressHeaderKeyboardEvent:void 0,colSpan:void 0,rowSpan:void 0,getQuickFilterText:void 0,onCellValueChanged:void 0,onCellClicked:void 0,onCellDoubleClicked:void 0,onCellContextMenu:void 0,rowDragText:void 0,tooltipValueGetter:void 0,cellRendererSelector:void 0,cellEditorSelector:void 0,suppressSpanHeaderHeight:void 0,useValueFormatterForExport:void 0,useValueParserForImport:void 0,mainMenuItems:void 0,contextMenuItems:void 0,suppressFloatingFilterButton:void 0,suppressHeaderFilterButton:void 0,suppressHeaderContextMenu:void 0,loadingCellRenderer:void 0,loadingCellRendererParams:void 0,loadingCellRendererSelector:void 0}),docsUrl:"column-properties/",deprecations:{columnsMenuParams:{version:"31.1",message:"Use `columnChooserParams` instead."},suppressMenu:{version:"31.1",message:"Use `suppressHeaderMenuButton` instead."},suppressCellFlash:{version:"31.2",message:"Use `enableCellChangeFlash={false}` in the ColDef"},dndSource:{version:"31.2",message:"This feature has been replaced by `Row Dragging to an External DropZone`."},dndSourceOnRowDrag:{version:"31.2",message:"This feature has been replaced by `Row Dragging to an External DropZone`."}},validations:mu},Cu={suppressContextMenu:!1,preventDefaultOnContextMenu:!1,allowContextMenuWithControlKey:!1,suppressMenuHide:!1,enableBrowserTooltips:!1,tooltipTrigger:"hover",tooltipShowDelay:2e3,tooltipHideDelay:1e4,tooltipMouseTrack:!1,tooltipShowMode:"standard",tooltipInteraction:!1,copyHeadersToClipboard:!1,copyGroupHeadersToClipboard:!1,clipboardDelimiter:"\t",suppressCopyRowsToClipboard:!1,suppressCopySingleCellRanges:!1,suppressLastEmptyLineOnPaste:!1,suppressClipboardPaste:!1,suppressClipboardApi:!1,suppressCutToClipboard:!1,maintainColumnOrder:!1,suppressFieldDotNotation:!1,allowDragFromColumnsToolPanel:!1,suppressMovableColumns:!1,suppressColumnMoveAnimation:!1,suppressDragLeaveHidesColumns:!1,suppressRowGroupHidesColumns:!1,suppressAutoSize:!1,autoSizePadding:20,skipHeaderOnAutoSize:!1,singleClickEdit:!1,suppressClickEdit:!1,readOnlyEdit:!1,stopEditingWhenCellsLoseFocus:!1,enterNavigatesVertically:!1,enterNavigatesVerticallyAfterEdit:!1,enableCellEditingOnBackspace:!1,undoRedoCellEditing:!1,undoRedoCellEditingLimit:10,suppressCsvExport:!1,suppressExcelExport:!1,cacheQuickFilter:!1,includeHiddenColumnsInQuickFilter:!1,excludeChildrenWhenTreeDataFiltering:!1,enableAdvancedFilter:!1,includeHiddenColumnsInAdvancedFilter:!1,enableCharts:!1,suppressChartToolPanelsButton:!1,masterDetail:!1,keepDetailRows:!1,keepDetailRowsCount:10,detailRowAutoHeight:!1,tabIndex:0,rowBuffer:10,valueCache:!1,valueCacheNeverExpires:!1,enableCellExpressions:!1,suppressTouch:!1,suppressFocusAfterRefresh:!1,suppressAsyncEvents:!1,suppressBrowserResizeObserver:!1,suppressPropertyNamesCheck:!1,suppressChangeDetection:!1,debug:!1,suppressLoadingOverlay:!1,suppressNoRowsOverlay:!1,pagination:!1,paginationPageSize:100,paginationPageSizeSelector:!0,paginationAutoPageSize:!1,paginateChildRows:!1,suppressPaginationPanel:!1,pivotMode:!1,pivotPanelShow:"never",pivotDefaultExpanded:0,pivotSuppressAutoColumn:!1,suppressExpandablePivotGroups:!1,functionsReadOnly:!1,suppressAggFuncInHeader:!1,alwaysAggregateAtRootLevel:!1,aggregateOnlyChangedColumns:!1,suppressAggFilteredOnly:!1,removePivotHeaderRowWhenSingleValueColumn:!1,animateRows:!0,enableCellChangeFlash:!1,cellFlashDelay:500,cellFlashDuration:500,cellFadeDelay:1e3,cellFadeDuration:1e3,allowShowChangeAfterFilter:!1,domLayout:"normal",ensureDomOrder:!1,enableRtl:!1,suppressColumnVirtualisation:!1,suppressMaxRenderedRowRestriction:!1,suppressRowVirtualisation:!1,rowDragManaged:!1,suppressRowDrag:!1,suppressMoveWhenRowDragging:!1,rowDragEntireRow:!1,rowDragMultiRow:!1,embedFullWidthRows:!1,groupDisplayType:"singleColumn",groupDefaultExpanded:0,groupMaintainOrder:!1,groupSelectsChildren:!1,groupIncludeTotalFooter:!1,groupSuppressBlankHeader:!1,groupSelectsFiltered:!1,showOpenedGroup:!1,groupRemoveSingleChildren:!1,groupRemoveLowestSingleChildren:!1,groupHideOpenParents:!1,groupAllowUnbalanced:!1,rowGroupPanelShow:"never",suppressMakeColumnVisibleAfterUnGroup:!1,treeData:!1,rowGroupPanelSuppressSort:!1,suppressGroupRowsSticky:!1,rowModelType:"clientSide",asyncTransactionWaitMillis:50,suppressModelUpdateAfterUpdateTransaction:!1,cacheOverflowSize:1,infiniteInitialRowCount:1,serverSideInitialRowCount:1,suppressServerSideInfiniteScroll:!1,cacheBlockSize:100,maxBlocksInCache:-1,maxConcurrentDatasourceRequests:2,blockLoadDebounceMillis:0,purgeClosedRowNodes:!1,serverSideSortAllLevels:!1,serverSideOnlyRefreshFilteredGroups:!1,serverSideSortOnServer:!1,serverSideFilterOnServer:!1,serverSidePivotResultFieldSeparator:"_",viewportRowModelPageSize:5,viewportRowModelBufferSize:5,alwaysShowHorizontalScroll:!1,alwaysShowVerticalScroll:!1,debounceVerticalScrollbar:!1,suppressHorizontalScroll:!1,suppressScrollOnNewData:!1,suppressScrollWhenPopupsAreOpen:!1,suppressAnimationFrame:!1,suppressMiddleClickScrolls:!1,suppressPreventDefaultOnMouseWheel:!1,rowMultiSelectWithClick:!1,suppressRowDeselection:!1,suppressRowClickSelection:!1,suppressCellFocus:!1,suppressHeaderFocus:!1,suppressMultiRangeSelection:!1,enableCellTextSelection:!1,enableRangeSelection:!1,enableRangeHandle:!1,enableFillHandle:!1,fillHandleDirection:"xy",suppressClearOnFillReduction:!1,accentedSort:!1,unSortIcon:!1,suppressMultiSort:!1,alwaysMultiSort:!1,suppressMaintainUnsortedOrder:!1,suppressRowHoverHighlight:!1,suppressRowTransform:!1,columnHoverHighlight:!1,deltaSort:!1,enableGroupEdit:!1,suppressGroupMaintainValueType:!1,functionsPassive:!1,groupLockGroupColumns:0,serverSideEnableClientSideSort:!1,suppressServerSideFullWidthLoadingRow:!1,pivotMaxGeneratedColumns:-1},yu={sideBar:{module:"@ag-grid-enterprise/side-bar"},statusBar:{module:"@ag-grid-enterprise/status-bar"},enableCharts:{module:"@ag-grid-enterprise/charts"},getMainMenuItems:{module:"@ag-grid-enterprise/menu"},getContextMenuItems:{module:"@ag-grid-enterprise/menu"},allowContextMenuWithControlKey:{module:"@ag-grid-enterprise/menu"},enableAdvancedFilter:{module:"@ag-grid-enterprise/advanced-filter"},treeData:{supportedRowModels:["clientSide","serverSide"],module:"@ag-grid-enterprise/row-grouping",dependencies:e=>{var t;const i=null!=(t=e.rowModelType)?t:"clientSide";switch(i){case"clientSide":const t=`treeData requires 'getDataPath' in the ${i} row model.`;return e.getDataPath?null:t;case"serverSide":const r=`treeData requires 'isServerSideGroup' and 'getServerSideGroupKey' in the ${i} row model.`;return e.isServerSideGroup&&e.getServerSideGroupKey?null:r}return null}},masterDetail:{module:"@ag-grid-enterprise/master-detail"},enableRangeSelection:{module:"@ag-grid-enterprise/range-selection"},enableRangeHandle:{dependencies:{enableRangeSelection:[!0]}},enableFillHandle:{dependencies:{enableRangeSelection:[!0]}},groupDefaultExpanded:{supportedRowModels:["clientSide"]},groupIncludeFooter:{supportedRowModels:["clientSide","serverSide"],dependencies:e=>{var t;switch(null!=(t=e.rowModelType)?t:"clientSide"){case"clientSide":return null;case"serverSide":const t="groupIncludeFooter is not supported alongside suppressServerSideInfiniteScroll";return e.suppressServerSideInfiniteScroll?t:null}return null}},groupIncludeTotalFooter:{supportedRowModels:["clientSide"]},groupRemoveSingleChildren:{dependencies:{groupHideOpenParents:[void 0,!1],groupRemoveLowestSingleChildren:[void 0,!1]}},groupRemoveLowestSingleChildren:{dependencies:{groupHideOpenParents:[void 0,!1],groupRemoveSingleChildren:[void 0,!1]}},groupSelectsChildren:{dependencies:{rowSelection:["multiple"]}},suppressParentsInRowNodes:{dependencies:{groupSelectsChildren:[void 0,!1]}},viewportDatasource:{supportedRowModels:["viewport"],module:"@ag-grid-enterprise/viewport-row-model"},serverSideDatasource:{supportedRowModels:["serverSide"],module:"@ag-grid-enterprise/server-side-row-model"},cacheBlockSize:{supportedRowModels:["serverSide","infinite"]},datasource:{supportedRowModels:["infinite"],module:"@ag-grid-community/infinite-row-model"},rowData:{supportedRowModels:["clientSide"],module:"@ag-grid-community/client-side-row-model"},columnDefs:()=>vu,defaultColDef:()=>vu,defaultColGroupDef:()=>vu,autoGroupColumnDef:()=>vu},wu={objectName:"gridOptions",allProperties:[...Dt.ALL_PROPERTIES,...Lt.EVENT_CALLBACKS],propertyExceptions:["api","columnApi"],docsUrl:"grid-options/",deprecations:{enableChartToolPanelsButton:{version:"29"},functionsPassive:{version:"29.2"},onColumnRowGroupChangeRequest:{version:"29.2"},onColumnPivotChangeRequest:{version:"29.2"},onColumnValueChangeRequest:{version:"29.2"},onColumnAggFuncChangeRequest:{version:"29.2"},serverSideFilterAllLevels:{version:"30",message:"All server-side group levels are now filtered by default. This can be toggled using `serverSideOnlyRefreshFilteredGroups`."},suppressAggAtRootLevel:{version:"30",message:"The root level aggregation is now suppressed by default. This can be toggled using  `alwaysAggregateAtRootLevel`."},excludeHiddenColumnsFromQuickFilter:{version:"30",message:"Hidden columns are now excluded from the Quick Filter by default. This can be toggled using `includeHiddenColumnsInQuickFilter`."},enterMovesDown:{version:"30",renamed:"enterNavigatesVertically"},enterMovesDownAfterEdit:{version:"30",renamed:"enterNavigatesVerticallyAfterEdit"},suppressParentsInRowNodes:{version:"30.2",message:"Using suppressParentsInRowNodes is no longer recommended. To serialize nodes it is now recommended to instead remove the parent node reference before serialization."},advancedFilterModel:{version:"31",message:"Use `initialState.filter.advancedFilterModel` instead."},suppressAsyncEvents:{version:"31",message:"Events should be handled asynchronously."},cellFadeDelay:{version:"31.1",renamed:"cellFadeDuration"},cellFlashDelay:{version:"31.1",renamed:"cellFlashDuration"},suppressServerSideInfiniteScroll:{version:"31.1"},serverSideSortOnServer:{version:"31.1"},serverSideFilterOnServer:{version:"31.1"},enableCellChangeFlash:{version:"31.2",message:"Use `enableCellChangeFlash` in the `ColDef` or `defaultColDef` for all columns."},groupIncludeFooter:{version:"31.3",message:"Use `groupTotalRow` instead."},groupIncludeTotalFooter:{version:"31.3",message:"Use `grandTotalRow` instead."}},validations:yu},Su=class{constructor(){this.destroyed=!1,this.domDataKey="__AG_"+Math.random().toString(),this.propertyEventService=new fe,this.globalEventHandlerFactory=e=>(t,i)=>{if(this.destroyed)return;const r=ct.has(t);if(r&&!e||!r&&e)return;const n=Lt.getCallbackForEvent(t),s=this.gridOptions[n];"function"==typeof s&&this.frameworkOverrides.wrapOutgoing(()=>{s(i)})}}get context(){return this.gridOptions.context}init(){this.columnApi=new Rc(this.api);const e=!this.get("suppressAsyncEvents");this.eventService.addGlobalListener(this.globalEventHandlerFactory().bind(this),e),this.eventService.addGlobalListener(this.globalEventHandlerFactory(!0).bind(this),!1),this.propertyEventService.setFrameworkOverrides(this.frameworkOverrides),this.getScrollbarWidth()}destroy(){this.destroyed=!0,this.columnApi=void 0}get(e){var t;return null!=(t=this.gridOptions[e])?t:Cu[e]}getCallback(e){return this.mergeGridCommonParams(this.gridOptions[e])}exists(e){return C(this.gridOptions[e])}mergeGridCommonParams(e){return e?t=>{const i=t;return i.api=this.api,i.columnApi=this.columnApi,i.context=this.context,e(i)}:e}static toBoolean(e){return"boolean"==typeof e?e:"string"==typeof e&&("TRUE"===e.toUpperCase()||""==e)}static toNumber(e){if("number"==typeof e)return e;if("string"==typeof e){const t=parseInt(e);if(isNaN(t))return;return t}}static toConstrainedNum(e,t){return i=>{const r=Su.toNumber(i);if(!(null==r||r<e||r>t))return r}}static getCoercedValue(e,t){const i=Su.PROPERTY_COERCIONS.get(e);return i?i(t):t}static getCoercedGridOptions(e){const t={};return Object.entries(e).forEach(([e,i])=>{const r=Su.getCoercedValue(e,i);t[e]=r}),t}updateGridOptions({options:e,force:t,source:i="api"}){const r={id:Su.changeSetId++,properties:[]},n=[];Object.entries(e).forEach(([e,s])=>{"api"===i&&Pt[e]&&z(`${e} is an initial property and cannot be updated.`);const o=Su.getCoercedValue(e,s),a=t||"object"==typeof o&&"api"===i,l=this.gridOptions[e];if(a||l!==o){this.gridOptions[e]=o;const t={type:e,currentValue:o,previousValue:l,changeSet:r,source:i};n.push(t)}}),this.validationService.processGridOptions(this.gridOptions),r.properties=n.map(e=>e.type),n.forEach(e=>{this.gridOptions.debug&&console.log(`AG Grid: Updated property ${e.type} from `,e.previousValue," to  ",e.currentValue),this.propertyEventService.dispatchEvent(e)})}addEventListener(e,t){this.propertyEventService.addEventListener(e,t)}removeEventListener(e,t){this.propertyEventService.removeEventListener(e,t)}getScrollbarWidth(){if(null==this.scrollbarWidth){const e="number"==typeof this.gridOptions.scrollbarWidth&&this.gridOptions.scrollbarWidth>=0?this.gridOptions.scrollbarWidth:ki();null!=e&&(this.scrollbarWidth=e,this.eventService.dispatchEvent({type:lt.EVENT_SCROLLBAR_WIDTH_CHANGED}))}return this.scrollbarWidth}isRowModelType(e){return this.gridOptions.rowModelType===e||"clientSide"===e&&y(this.gridOptions.rowModelType)}isDomLayout(e){var t;return(null!=(t=this.gridOptions.domLayout)?t:"normal")===e}isRowSelection(){return"single"===this.gridOptions.rowSelection||"multiple"===this.gridOptions.rowSelection}useAsyncEvents(){return!this.get("suppressAsyncEvents")}isGetRowHeightFunction(){return"function"==typeof this.gridOptions.getRowHeight}getRowHeightForNode(e,t=!1,i){if(null==i&&(i=this.environment.getDefaultRowHeight()),this.isGetRowHeightFunction()){if(t)return{height:i,estimated:!0};const r={node:e,data:e.data},n=this.getCallback("getRowHeight")(r);if(this.isNumeric(n))return 0===n&&z("The return of `getRowHeight` cannot be zero. If the intention is to hide rows, use a filter instead."),{height:Math.max(1,n),estimated:!1}}return e.detail&&this.get("masterDetail")?this.getMasterDetailRowHeight():{height:this.gridOptions.rowHeight&&this.isNumeric(this.gridOptions.rowHeight)?this.gridOptions.rowHeight:i,estimated:!1}}getMasterDetailRowHeight(){return this.get("detailRowAutoHeight")?{height:1,estimated:!1}:this.isNumeric(this.gridOptions.detailRowHeight)?{height:this.gridOptions.detailRowHeight,estimated:!1}:{height:300,estimated:!1}}getRowHeightAsNumber(){if(!this.gridOptions.rowHeight||y(this.gridOptions.rowHeight))return this.environment.getDefaultRowHeight();const e=this.environment.refreshRowHeightVariable();return-1!==e?e:(console.warn("AG Grid row height must be a number if not using standard row model"),this.environment.getDefaultRowHeight())}isNumeric(e){return!isNaN(e)&&"number"==typeof e&&isFinite(e)}getDomDataKey(){return this.domDataKey}getDomData(e,t){const i=e[this.getDomDataKey()];return i?i[t]:void 0}setDomData(e,t,i){const r=this.getDomDataKey();let n=e[r];y(n)&&(n={},e[r]=n),n[t]=i}getDocument(){let e=null;return this.gridOptions.getDocument&&C(this.gridOptions.getDocument)?e=this.gridOptions.getDocument():this.eGridDiv&&(e=this.eGridDiv.ownerDocument),e&&C(e)?e:document}getWindow(){return this.getDocument().defaultView||window}getRootNode(){return this.eGridDiv.getRootNode()}getActiveDomElement(){return this.getRootNode().activeElement}getAsyncTransactionWaitMillis(){return C(this.gridOptions.asyncTransactionWaitMillis)?this.gridOptions.asyncTransactionWaitMillis:50}isAnimateRows(){return!this.get("ensureDomOrder")&&this.get("animateRows")}isGroupRowsSticky(){return!(this.get("paginateChildRows")||this.get("groupHideOpenParents")||this.isDomLayout("print"))}isColumnsSortingCoupledToGroup(){const e=this.gridOptions.autoGroupColumnDef;return!(null==e?void 0:e.comparator)&&!this.get("treeData")}getGroupAggFiltering(){const e=this.gridOptions.groupAggFiltering;return"function"==typeof e?this.getCallback("groupAggFiltering"):!0===e?()=>!0:void 0}getGrandTotalRow(){const e=this.gridOptions.grandTotalRow;return e||(this.gridOptions.groupIncludeTotalFooter?"bottom":void 0)}getGroupTotalRowCallback(){const e=this.get("groupTotalRow");if("function"==typeof e)return this.getCallback("groupTotalRow");if(e)return()=>e;const t=this.get("groupIncludeFooter");if("function"==typeof t){const e=this.getCallback("groupIncludeFooter");return t=>e(t)?"bottom":void 0}return()=>t?"bottom":void 0}isGroupMultiAutoColumn(){return this.gridOptions.groupDisplayType?"multipleColumns"===this.gridOptions.groupDisplayType:this.get("groupHideOpenParents")}isGroupUseEntireRow(e){return!e&&"groupRows"===this.gridOptions.groupDisplayType}getGridCommonParams(){return{api:this.api,columnApi:this.columnApi,context:this.context}}addGridCommonParams(e){const t=e;return t.api=this.api,t.columnApi=this.columnApi,t.context=this.context,t}};Su.PROPERTY_COERCIONS=new Map([...Dt.BOOLEAN_PROPERTIES.map(e=>[e,Su.toBoolean]),...Dt.NUMBER_PROPERTIES.map(e=>[e,Su.toNumber]),["groupAggFiltering",e=>"function"==typeof e?e:Su.toBoolean(e)],["pageSize",Su.toConstrainedNum(1,Number.MAX_VALUE)],["autoSizePadding",Su.toConstrainedNum(0,Number.MAX_VALUE)],["keepDetailRowsCount",Su.toConstrainedNum(1,Number.MAX_VALUE)],["rowBuffer",Su.toConstrainedNum(0,Number.MAX_VALUE)],["infiniteInitialRowCount",Su.toConstrainedNum(1,Number.MAX_VALUE)],["cacheOverflowSize",Su.toConstrainedNum(1,Number.MAX_VALUE)],["cacheBlockSize",Su.toConstrainedNum(1,Number.MAX_VALUE)],["serverSideInitialRowCount",Su.toConstrainedNum(1,Number.MAX_VALUE)],["viewportRowModelPageSize",Su.toConstrainedNum(1,Number.MAX_VALUE)],["viewportRowModelBufferSize",Su.toConstrainedNum(0,Number.MAX_VALUE)]]),Su.changeSetId=0,g([ue("gridOptions")],Su.prototype,"gridOptions",2),g([ue("eventService")],Su.prototype,"eventService",2),g([ue("environment")],Su.prototype,"environment",2),g([ue("frameworkOverrides")],Su.prototype,"frameworkOverrides",2),g([ue("eGridDiv")],Su.prototype,"eGridDiv",2),g([ue("validationService")],Su.prototype,"validationService",2),g([ue("gridApi")],Su.prototype,"api",2),g([ae],Su.prototype,"init",1),g([le],Su.prototype,"destroy",1),Su=g([ce("gridOptionsService")],Su);var bu=class extends rt{getLocaleTextFunc(){const e=this.gos.getCallback("getLocaleText");if(e)return(t,i,r)=>e({key:t,defaultValue:i,variableValues:r});const t=this.gos.get("localeText");return(e,i,r)=>{let n=t&&t[e];if(n&&r&&r.length){let e=0;for(;!(e>=r.length)&&-1!==n.indexOf("${variable}");)n=n.replace("${variable}",r[e++])}return null!=n?n:i}}};bu=g([ce("localeService")],bu);var Eu=class e extends uu{constructor(){super(e.TEMPLATE,"vertical")}postConstruct(){super.postConstruct(),this.createManagedBean(new ba(this.eContainer)),this.ctrlsService.register("fakeVScrollComp",this),this.addManagedListener(this.eventService,lt.EVENT_ROW_CONTAINER_HEIGHT_CHANGED,this.onRowContainerHeightChanged.bind(this))}setScrollVisible(){const e=this.scrollVisibleService.isVerticalScrollShowing(),t=this.invisibleScrollbar,i=e&&this.gos.getScrollbarWidth()||0,r=0===i&&t?16:i;this.addOrRemoveCssClass("ag-scrollbar-invisible",t),xr(this.getGui(),r),xr(this.eViewport,r),xr(this.eContainer,r),this.setDisplayed(e,{skipAriaHidden:!0})}onRowContainerHeightChanged(){const{ctrlsService:e}=this,t=e.getGridBodyCtrl().getBodyViewportElement(),i=this.getScrollPosition(),r=t.scrollTop;i!=r&&this.setScrollPosition(r,!0)}getScrollPosition(){return this.getViewport().scrollTop}setScrollPosition(e,t){t||Sr(this.getViewport())||this.attemptSettingScrollPosition(e),this.getViewport().scrollTop=e}};Eu.TEMPLATE='<div class="ag-body-vertical-scroll" aria-hidden="true">\n            <div class="ag-body-vertical-scroll-viewport" ref="eViewport">\n                <div class="ag-body-vertical-scroll-container" ref="eContainer"></div>\n            </div>\n        </div>',g([ae],Eu.prototype,"postConstruct",1);var Au=Eu,Tu={january:"January",february:"February",march:"March",april:"April",may:"May",june:"June",july:"July",august:"August",september:"September",october:"October",november:"November",december:"December"},Mu=["january","february","march","april","may","june","july","august","september","october","november","december"],Ru=class extends rt{constructor(){super(...arguments),this.dataTypeDefinitions={},this.isWaitingForRowData=!1,this.isColumnTypeOverrideInDataTypeDefinitions=!1,this.columnStateUpdatesPendingInference={},this.columnStateUpdateListenerDestroyFuncs=[]}init(){this.groupHideOpenParents=this.gos.get("groupHideOpenParents"),this.addManagedPropertyListener("groupHideOpenParents",()=>{this.groupHideOpenParents=this.gos.get("groupHideOpenParents")}),this.processDataTypeDefinitions(),this.addManagedPropertyListener("dataTypeDefinitions",e=>{this.processDataTypeDefinitions(),this.columnModel.recreateColumnDefs(Mt(e.source))})}processDataTypeDefinitions(){var e;const t=this.getDefaultDataTypes();this.dataTypeDefinitions={},Object.entries(t).forEach(([e,t])=>{this.dataTypeDefinitions[e]=d(h({},t),{groupSafeValueFormatter:this.createGroupSafeValueFormatter(t)})});const i=null!=(e=this.gos.get("dataTypeDefinitions"))?e:{};this.dataTypeMatchers={},Object.entries(i).forEach(([e,r])=>{const n=this.processDataTypeDefinition(r,i,[e],t);n&&(this.dataTypeDefinitions[e]=n,r.dataTypeMatcher&&(this.dataTypeMatchers[e]=r.dataTypeMatcher))}),this.checkObjectValueHandlers(t),["dateString","text","number","boolean","date"].forEach(e=>{const i=this.dataTypeMatchers[e];i&&delete this.dataTypeMatchers[e],this.dataTypeMatchers[e]=null!=i?i:t[e].dataTypeMatcher})}mergeDataTypeDefinitions(e,t){const i=h(h({},e),t);return e.columnTypes&&t.columnTypes&&t.appendColumnTypes&&(i.columnTypes=[...this.convertColumnTypes(e.columnTypes),...this.convertColumnTypes(t.columnTypes)]),i}processDataTypeDefinition(e,t,i,r){let n;const s=e.extendsDataType;if(e.columnTypes&&(this.isColumnTypeOverrideInDataTypeDefinitions=!0),e.extendsDataType===e.baseDataType){let i=r[s];const o=t[s];if(i&&o&&(i=o),!this.validateDataTypeDefinition(e,i,s))return;n=this.mergeDataTypeDefinitions(i,e)}else{if(i.includes(s))return void z('Data type definition hierarchies (via the "extendsDataType" property) cannot contain circular references.');const o=t[s];if(!this.validateDataTypeDefinition(e,o,s))return;const a=this.processDataTypeDefinition(o,t,[...i,s],r);if(!a)return;n=this.mergeDataTypeDefinitions(a,e)}return d(h({},n),{groupSafeValueFormatter:this.createGroupSafeValueFormatter(n)})}validateDataTypeDefinition(e,t,i){return t?t.baseDataType===e.baseDataType||(z('The "baseDataType" property of a data type definition must match that of its parent.'),!1):(z(`The data type definition ${i} does not exist.`),!1)}createGroupSafeValueFormatter(e){if(e.valueFormatter)return t=>{var i,r;if(null==(i=t.node)?void 0:i.group){const i=t.column.getAggFunc();if(i){if("first"===i||"last"===i)return e.valueFormatter(t);if("number"===e.baseDataType&&"count"!==i){if("number"==typeof t.value)return e.valueFormatter(t);if("object"==typeof t.value){if(!t.value)return;if("toNumber"in t.value)return e.valueFormatter(d(h({},t),{value:t.value.toNumber()}));if("value"in t.value)return e.valueFormatter(d(h({},t),{value:t.value.value}))}}}if(!this.gos.get("suppressGroupMaintainValueType"))return}else if(this.groupHideOpenParents&&t.column.isRowGroupActive()){if("string"!=typeof t.value||(null==(r=e.dataTypeMatcher)?void 0:r.call(e,t.value)))return e.valueFormatter(t);if(!this.gos.get("suppressGroupMaintainValueType"))return}return e.valueFormatter(t)}}updateColDefAndGetDataTypeDefinitionColumnType(e,t,i){let{cellDataType:r}=t;const{field:n}=t;if(void 0===r&&(r=e.cellDataType),null!=r&&!0!==r||(r=!!this.canInferCellDataType(e,t)&&this.inferCellDataType(n,i)),!r)return void(e.cellDataType=!1);const s=this.dataTypeDefinitions[r];if(s)return e.cellDataType=r,s.groupSafeValueFormatter&&(e.valueFormatter=s.groupSafeValueFormatter),s.valueParser&&(e.valueParser=s.valueParser),s.suppressDefaultProperties||this.setColDefPropertiesForBaseDataType(e,s,i),s.columnTypes;z(`Missing data type definition - "${r}"`)}updateColDefAndGetColumnType(e,t,i){var r,n;const s=this.updateColDefAndGetDataTypeDefinitionColumnType(e,t,i),o=null!=(n=null!=(r=t.type)?r:s)?n:e.type;return e.type=o,o?this.convertColumnTypes(o):void 0}addColumnListeners(e){if(!this.isWaitingForRowData)return;const t=this.columnStateUpdatesPendingInference[e.getColId()];if(!t)return;const i=e=>{t.add(e.key)};e.addEventListener(Se.EVENT_STATE_UPDATED,i),this.columnStateUpdateListenerDestroyFuncs.push(()=>e.removeEventListener(Se.EVENT_STATE_UPDATED,i))}canInferCellDataType(e,t){var i;if("clientSide"!==this.rowModel.getType())return!1;const r={cellRenderer:!0,valueGetter:!0,valueParser:!0,refData:!0};if(this.doColDefPropsPreventInference(t,r))return!1;const n=null===t.type?e.type:t.type;if(n){const e=null!=(i=this.gos.get("columnTypes"))?i:{};if(this.convertColumnTypes(n).some(t=>{const i=e[t.trim()];return i&&this.doColDefPropsPreventInference(i,r)}))return!1}return!this.doColDefPropsPreventInference(e,r)}doColDefPropsPreventInference(e,t){return[["cellRenderer","agSparklineCellRenderer"],["valueGetter",void 0],["valueParser",void 0],["refData",void 0]].some(([i,r])=>this.doesColDefPropPreventInference(e,t,i,r))}doesColDefPropPreventInference(e,t,i,r){if(!t[i])return!1;const n=e[i];return null===n?(t[i]=!1,!1):void 0===r?!!n:n===r}inferCellDataType(e,t){var i;if(!e)return;let r;const n=this.getInitialData();if(n){const t=e.indexOf(".")>=0&&!this.gos.get("suppressFieldDotNotation");r=F(n,e,t)}else this.initWaitForRowData(t);if(null==r)return;const[s]=null!=(i=Object.entries(this.dataTypeMatchers).find(([e,t])=>t(r)))?i:["object"];return s}getInitialData(){const e=this.gos.get("rowData");if(null==e?void 0:e.length)return e[0];if(this.initialData)return this.initialData;{const e=this.rowModel.getRootNode().allLeafChildren;if(null==e?void 0:e.length)return e[0].data}return null}initWaitForRowData(e){if(this.columnStateUpdatesPendingInference[e]=new Set,this.isWaitingForRowData)return;this.isWaitingForRowData=!0;const t=this.isColumnTypeOverrideInDataTypeDefinitions;t&&this.columnModel.queueResizeOperations();const i=this.addManagedListener(this.eventService,lt.EVENT_ROW_DATA_UPDATE_STARTED,e=>{const{firstRowData:r}=e;if(!r)return;null==i||i(),this.isWaitingForRowData=!1,this.processColumnsPendingInference(r,t),this.columnStateUpdatesPendingInference={},t&&this.columnModel.processResizeOperations();const n={type:lt.EVENT_DATA_TYPES_INFERRED};this.eventService.dispatchEvent(n)})}isPendingInference(){return this.isWaitingForRowData}processColumnsPendingInference(e,t){this.initialData=e;const i=[];this.columnStateUpdateListenerDestroyFuncs.forEach(e=>e()),this.columnStateUpdateListenerDestroyFuncs=[];const r={},n={};Object.entries(this.columnStateUpdatesPendingInference).forEach(([e,s])=>{const o=this.columnModel.getGridColumn(e);if(!o)return;const a=o.getColDef();if(!this.columnModel.resetColumnDefIntoColumn(o,"cellDataTypeInferred"))return;const l=o.getColDef();if(t&&l.type&&l.type!==a.type){const t=this.getUpdatedColumnState(o,s);t.rowGroup&&null==t.rowGroupIndex&&(r[e]=t),t.pivot&&null==t.pivotIndex&&(n[e]=t),i.push(t)}}),t&&i.push(...this.columnModel.generateColumnStateForRowGroupAndPivotIndexes(r,n)),i.length&&this.columnModel.applyColumnState({state:i},"cellDataTypeInferred"),this.initialData=null}getUpdatedColumnState(e,t){const i=this.columnModel.getColumnStateFromColDef(e);return t.forEach(e=>{delete i[e],"rowGroup"===e?delete i.rowGroupIndex:"pivot"===e&&delete i.pivotIndex}),i}checkObjectValueHandlers(e){const t=this.dataTypeDefinitions.object,i=e.object;this.hasObjectValueParser=t.valueParser!==i.valueParser,this.hasObjectValueFormatter=t.valueFormatter!==i.valueFormatter}convertColumnTypes(e){let t=[];return e instanceof Array?e.some(e=>"string"!=typeof e)?console.warn("if colDef.type is supplied an array it should be of type 'string[]'"):t=e:"string"==typeof e?t=e.split(","):console.warn("colDef.type should be of type 'string' | 'string[]'"),t}getDateStringTypeDefinition(e){var t;return e&&null!=(t=this.getDataTypeDefinition(e))?t:this.dataTypeDefinitions.dateString}getDateParserFunction(e){return this.getDateStringTypeDefinition(e).dateParser}getDateFormatterFunction(e){return this.getDateStringTypeDefinition(e).dateFormatter}getDataTypeDefinition(e){const t=e.getColDef();if(t.cellDataType)return this.dataTypeDefinitions[t.cellDataType]}getBaseDataType(e){var t;return null==(t=this.getDataTypeDefinition(e))?void 0:t.baseDataType}checkType(e,t){var i;if(null==t)return!0;const r=null==(i=this.getDataTypeDefinition(e))?void 0:i.dataTypeMatcher;return!r||r(t)}validateColDef(e){"object"===e.cellDataType&&(e.valueFormatter!==this.dataTypeDefinitions.object.groupSafeValueFormatter||this.hasObjectValueFormatter||z('Cell data type is "object" but no value formatter has been provided. Please either provide an object data type definition with a value formatter, or set "colDef.valueFormatter"'),e.editable&&e.valueParser===this.dataTypeDefinitions.object.valueParser&&!this.hasObjectValueParser&&z('Cell data type is "object" but no value parser has been provided. Please either provide an object data type definition with a value parser, or set "colDef.valueParser"'))}setColDefPropertiesForBaseDataType(e,t,i){const r=(e,i,r)=>{let n=e.getColDef().valueFormatter;return n===t.groupSafeValueFormatter&&(n=t.valueFormatter),this.valueService.formatValue(e,i,r,n)},n=ne.__isRegistered("@ag-grid-enterprise/set-filter",this.context.getGridId()),s=this.localeService.getLocaleTextFunc(),o=t=>{const{filterParams:i}=e;e.filterParams="object"==typeof i?h(h({},i),t):t};switch(t.baseDataType){case"number":e.cellEditor="agNumberCellEditor",n&&o({comparator:(e,t)=>{const i=null==e?0:parseInt(e),r=null==t?0:parseInt(t);return i===r?0:i>r?1:-1}});break;case"boolean":e.cellEditor="agCheckboxCellEditor",e.cellRenderer="agCheckboxCellRenderer",e.suppressKeyboardEvent=e=>!!e.colDef.editable&&e.event.key===Yr.SPACE,o(n?{valueFormatter:e=>C(e.value)?s(String(e.value),e.value?"True":"False"):s("blanks","(Blanks)")}:{maxNumConditions:1,debounceMs:0,filterOptions:["empty",{displayKey:"true",displayName:"True",predicate:(e,t)=>t,numberOfInputs:0},{displayKey:"false",displayName:"False",predicate:(e,t)=>!1===t,numberOfInputs:0}]});break;case"date":e.cellEditor="agDateCellEditor",e.keyCreator=e=>r(e.column,e.node,e.value),n&&o({valueFormatter:e=>{const t=r(e.column,e.node,e.value);return C(t)?t:s("blanks","(Blanks)")},treeList:!0,treeListFormatter:(e,t)=>{if(1===t&&null!=e){const t=Mu[Number(e)-1];return s(t,Tu[t])}return null!=e?e:s("blanks","(Blanks)")}});break;case"dateString":{e.cellEditor="agDateStringCellEditor",e.keyCreator=e=>r(e.column,e.node,e.value);const i=t.dateParser;o(n?{valueFormatter:e=>{const t=r(e.column,e.node,e.value);return C(t)?t:s("blanks","(Blanks)")},treeList:!0,treeListPathGetter:e=>{const t=i(null!=e?e:void 0);return t?[String(t.getFullYear()),String(t.getMonth()+1),String(t.getDate())]:null},treeListFormatter:(e,t)=>{if(1===t&&null!=e){const t=Mu[Number(e)-1];return s(t,Tu[t])}return null!=e?e:s("blanks","(Blanks)")}}:{comparator:(e,t)=>{const r=i(t);return null==t||r<e?-1:r>e?1:0}});break}case"object":e.cellEditorParams={useFormatter:!0},e.comparator=(e,t)=>{const n=this.columnModel.getPrimaryColumn(i),s=null==n?void 0:n.getColDef();if(!n||!s)return 0;const o=null==e?"":r(n,null,e),a=null==t?"":r(n,null,t);return o===a?0:o>a?1:-1},e.keyCreator=e=>r(e.column,e.node,e.value),n?o({valueFormatter:e=>{const t=r(e.column,e.node,e.value);return C(t)?t:s("blanks","(Blanks)")}}):e.filterValueGetter=e=>r(e.column,e.node,this.valueService.getValue(e.column,e.node))}}getDefaultDataTypes(){const e=e=>!!e.match("^\\d{4}-\\d{2}-\\d{2}$"),t=this.localeService.getLocaleTextFunc();return{number:{baseDataType:"number",valueParser:e=>{var t,i;return""===(null==(i=null==(t=e.newValue)?void 0:t.trim)?void 0:i.call(t))?null:Number(e.newValue)},valueFormatter:e=>null==e.value?"":"number"!=typeof e.value||isNaN(e.value)?t("invalidNumber","Invalid Number"):String(e.value),dataTypeMatcher:e=>"number"==typeof e},text:{baseDataType:"text",valueParser:e=>""===e.newValue?null:S(e.newValue),dataTypeMatcher:e=>"string"==typeof e},boolean:{baseDataType:"boolean",valueParser:e=>{var t,i;return null==e.newValue?e.newValue:""===(null==(i=null==(t=e.newValue)?void 0:t.trim)?void 0:i.call(t))?null:"true"===String(e.newValue).toLowerCase()},valueFormatter:e=>null==e.value?"":String(e.value),dataTypeMatcher:e=>"boolean"==typeof e},date:{baseDataType:"date",valueParser:e=>Zi(null==e.newValue?null:String(e.newValue)),valueFormatter:e=>{var i;return null==e.value?"":e.value instanceof Date&&!isNaN(e.value.getTime())?null!=(i=Yi(e.value,!1))?i:"":t("invalidDate","Invalid Date")},dataTypeMatcher:e=>e instanceof Date},dateString:{baseDataType:"dateString",dateParser:e=>{var t;return null!=(t=Zi(e))?t:void 0},dateFormatter:e=>{var t;return null!=(t=Yi(null!=e?e:null,!1))?t:void 0},valueParser:t=>e(String(t.newValue))?t.newValue:null,valueFormatter:t=>e(String(t.value))?t.value:"",dataTypeMatcher:t=>"string"==typeof t&&e(t)},object:{baseDataType:"object",valueParser:()=>null,valueFormatter:e=>{var t;return null!=(t=S(e.value))?t:""}}}}};g([ue("rowModel")],Ru.prototype,"rowModel",2),g([ue("columnModel")],Ru.prototype,"columnModel",2),g([ue("valueService")],Ru.prototype,"valueService",2),g([ae],Ru.prototype,"init",1),Ru=g([ce("dataTypeService")],Ru);var _u=class extends rt{constructor(){super(...arguments),this.waitingForColumns=!1}postConstruct(){this.addManagedPropertyListener("columnDefs",e=>this.setColumnDefs(e))}start(){this.ctrlsService.whenReady(()=>{const e=this.gos.get("columnDefs");e?this.setColumnsAndData(e):this.waitingForColumns=!0,this.gridReady()})}setColumnsAndData(e){this.columnModel.setColumnDefs(null!=e?e:[],"gridInitializing"),this.rowModel.start()}gridReady(){this.dispatchGridReadyEvent();const e=ne.__isRegistered("@ag-grid-enterprise/core",this.context.getGridId());new Dc("AG Grid",()=>this.gos.get("debug")).log(`initialised successfully, enterprise = ${e}`)}dispatchGridReadyEvent(){const e={type:lt.EVENT_GRID_READY};this.eventService.dispatchEvent(e)}setColumnDefs(e){const t=this.gos.get("columnDefs");if(t)return this.waitingForColumns?(this.waitingForColumns=!1,void this.setColumnsAndData(t)):void this.columnModel.setColumnDefs(t,Mt(e.source))}};g([ue("ctrlsService")],_u.prototype,"ctrlsService",2),g([ue("columnModel")],_u.prototype,"columnModel",2),g([ue("rowModel")],_u.prototype,"rowModel",2),g([ae],_u.prototype,"postConstruct",1),_u=g([ce("syncService")],_u);var Pu=class extends rt{constructor(){super(...arguments),this.manuallyDisplayed=!1}postConstruct(){this.addManagedListener(this.eventService,lt.EVENT_ROW_DATA_UPDATED,()=>this.onRowDataUpdated()),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.onNewColumnsLoaded())}registerOverlayWrapperComp(e){this.overlayWrapperComp=e,(!this.gos.get("columnDefs")||this.gos.isRowModelType("clientSide")&&!this.gos.get("rowData"))&&this.showLoadingOverlay()}showLoadingOverlay(){if(this.gos.get("suppressLoadingOverlay"))return;const e=this.userComponentFactory.getLoadingOverlayCompDetails({});this.showOverlay(e,"ag-overlay-loading-wrapper","loadingOverlayComponentParams")}showNoRowsOverlay(){if(this.gos.get("suppressNoRowsOverlay"))return;const e=this.userComponentFactory.getNoRowsOverlayCompDetails({});this.showOverlay(e,"ag-overlay-no-rows-wrapper","noRowsOverlayComponentParams")}showOverlay(e,t,i){const r=e.newAgStackInstance(),n=this.addManagedPropertyListener(i,({currentValue:e})=>{r.then(t=>{t.refresh&&t.refresh(this.gos.addGridCommonParams(h({},null!=e?e:{})))})});this.manuallyDisplayed=this.columnModel.isReady()&&!this.paginationProxy.isEmpty(),this.overlayWrapperComp.showOverlay(r,t,n)}hideOverlay(){this.manuallyDisplayed=!1,this.overlayWrapperComp.hideOverlay()}showOrHideOverlay(){const e=this.paginationProxy.isEmpty(),t=this.gos.get("suppressNoRowsOverlay");e&&!t?this.showNoRowsOverlay():this.hideOverlay()}onRowDataUpdated(){this.showOrHideOverlay()}onNewColumnsLoaded(){!this.columnModel.isReady()||this.paginationProxy.isEmpty()||this.manuallyDisplayed||this.hideOverlay()}};g([ue("userComponentFactory")],Pu.prototype,"userComponentFactory",2),g([ue("paginationProxy")],Pu.prototype,"paginationProxy",2),g([ue("columnModel")],Pu.prototype,"columnModel",2),g([ae],Pu.prototype,"postConstruct",1),Pu=g([ce("overlayService")],Pu);var xu=class extends rt{constructor(){super(...arguments),this.suppressEvents=!0,this.queuedUpdateSources=new Set,this.dispatchStateUpdateEventDebounced=X(()=>this.dispatchQueuedStateUpdateEvents(),0),this.onRowGroupOpenedDebounced=X(()=>this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState()),0),this.onRowSelectedDebounced=X(()=>{this.staleStateKeys.delete("rowSelection"),this.updateCachedState("rowSelection",this.getRowSelectionState())},0),this.staleStateKeys=new Set}postConstruct(){var e;this.isClientSideRowModel="clientSide"===this.rowModel.getType(),this.cachedState=null!=(e=this.gos.get("initialState"))?e:{},this.ctrlsService.whenReady(()=>this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnGridReady()));const t=this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,({source:e})=>{"gridInitializing"===e&&(null==t||t(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnColumnsInitialised()))}),i=this.addManagedListener(this.eventService,lt.EVENT_ROW_COUNT_READY,()=>{null==i||i(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnRowCountReady())}),r=this.addManagedListener(this.eventService,lt.EVENT_FIRST_DATA_RENDERED,()=>{null==r||r(),this.suppressEventsAndDispatchInitEvent(()=>this.setupStateOnFirstDataRendered())})}getState(){return this.staleStateKeys.size&&this.refreshStaleState(),this.cachedState}setupStateOnGridReady(){this.updateCachedState("sideBar",this.getSideBarState()),this.addManagedListener(this.eventService,lt.EVENT_TOOL_PANEL_VISIBLE_CHANGED,()=>this.updateCachedState("sideBar",this.getSideBarState())),this.addManagedListener(this.eventService,lt.EVENT_SIDE_BAR_UPDATED,()=>this.updateCachedState("sideBar",this.getSideBarState()))}setupStateOnColumnsInitialised(){var e;const t=null!=(e=this.gos.get("initialState"))?e:{};this.setColumnState(t),this.setColumnGroupState(t),this.updateColumnState(["aggregation","columnOrder","columnPinning","columnSizing","columnVisibility","pivot","pivot","rowGroup","sort"]),this.updateCachedState("columnGroup",this.getColumnGroupState()),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VALUE_CHANGED,()=>this.updateColumnState(["aggregation"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_MOVED,()=>this.updateColumnState(["columnOrder"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PINNED,()=>this.updateColumnState(["columnPinning"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_RESIZED,()=>this.updateColumnState(["columnSizing"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VISIBLE,()=>this.updateColumnState(["columnVisibility"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_CHANGED,()=>this.updateColumnState(["pivot"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.updateColumnState(["pivot"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.updateColumnState(["rowGroup"])),this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,()=>this.updateColumnState(["sort"])),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,()=>this.updateColumnState(["aggregation","columnOrder","columnPinning","columnSizing","columnVisibility","pivot","pivot","rowGroup","sort"])),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_GROUP_OPENED,()=>this.updateCachedState("columnGroup",this.getColumnGroupState()))}setupStateOnRowCountReady(){var e;const{filter:t,rowGroupExpansion:i,rowSelection:r,pagination:n}=null!=(e=this.gos.get("initialState"))?e:{},s=this.gos.get("advancedFilterModel");(t||s)&&this.setFilterState(t,s),i&&this.setRowGroupExpansionState(i),r&&this.setRowSelectionState(r),n&&this.setPaginationState(n),this.updateCachedState("filter",this.getFilterState()),this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState()),this.updateCachedState("rowSelection",this.getRowSelectionState()),this.updateCachedState("pagination",this.getPaginationState()),this.addManagedListener(this.eventService,lt.EVENT_FILTER_CHANGED,()=>this.updateCachedState("filter",this.getFilterState())),this.addManagedListener(this.eventService,lt.EVENT_ROW_GROUP_OPENED,()=>this.onRowGroupOpenedDebounced()),this.addManagedListener(this.eventService,lt.EVENT_EXPAND_COLLAPSE_ALL,()=>this.updateCachedState("rowGroupExpansion",this.getRowGroupExpansionState())),this.addManagedListener(this.eventService,lt.EVENT_SELECTION_CHANGED,()=>{this.staleStateKeys.add("rowSelection"),this.onRowSelectedDebounced()}),this.addManagedListener(this.eventService,lt.EVENT_PAGINATION_CHANGED,e=>{(e.newPage||e.newPageSize)&&this.updateCachedState("pagination",this.getPaginationState())})}setupStateOnFirstDataRendered(){var e;const{scroll:t,rangeSelection:i,focusedCell:r,columnOrder:n}=null!=(e=this.gos.get("initialState"))?e:{};r&&this.setFocusedCellState(r),i&&this.setRangeSelectionState(i),t&&this.setScrollState(t),this.setColumnPivotState(!!(null==n?void 0:n.orderedColIds)),this.updateCachedState("sideBar",this.getSideBarState()),this.updateCachedState("focusedCell",this.getFocusedCellState()),this.updateCachedState("rangeSelection",this.getRangeSelectionState()),this.updateCachedState("scroll",this.getScrollState()),this.addManagedListener(this.eventService,lt.EVENT_CELL_FOCUSED,()=>this.updateCachedState("focusedCell",this.getFocusedCellState())),this.addManagedListener(this.eventService,lt.EVENT_RANGE_SELECTION_CHANGED,e=>{e.finished&&this.updateCachedState("rangeSelection",this.getRangeSelectionState())}),this.addManagedListener(this.eventService,lt.EVENT_BODY_SCROLL_END,()=>this.updateCachedState("scroll",this.getScrollState()))}getColumnState(){const e=this.columnModel.isPivotMode(),t=[],i=[],r=[],n=[],s=[],o=[],a=[],l=[],c=[],u=this.columnModel.getColumnState();for(let e=0;e<u.length;e++){const{colId:h,sort:d,sortIndex:p,rowGroup:g,rowGroupIndex:f,aggFunc:m,pivot:v,pivotIndex:C,pinned:y,hide:w,width:S,flex:b}=u[e];c.push(h),d&&(t[null!=p?p:0]={colId:h,sort:d}),g&&(i[null!=f?f:0]=h),"string"==typeof m&&r.push({colId:h,aggFunc:m}),v&&(n[null!=C?C:0]=h),y&&("right"===y?o:s).push(h),w&&a.push(h),(b||S)&&l.push({colId:h,flex:null!=b?b:void 0,width:S})}return{sort:t.length?{sortModel:t}:void 0,rowGroup:i.length?{groupColIds:i}:void 0,aggregation:r.length?{aggregationModel:r}:void 0,pivot:n.length||e?{pivotMode:e,pivotColIds:n}:void 0,columnPinning:s.length||o.length?{leftColIds:s,rightColIds:o}:void 0,columnVisibility:a.length?{hiddenColIds:a}:void 0,columnSizing:l.length?{columnSizingModel:l}:void 0,columnOrder:c.length?{orderedColIds:c}:void 0}}setColumnState(e){const{sort:t,rowGroup:i,aggregation:r,pivot:n,columnPinning:s,columnVisibility:o,columnSizing:a,columnOrder:l}=e,c={},u=e=>{let t=c[e];return t||(t={colId:e},c[e]=t,t)};t&&t.sortModel.forEach(({colId:e,sort:t},i)=>{const r=u(e);r.sort=t,r.sortIndex=i}),i&&i.groupColIds.forEach((e,t)=>{const i=u(e);i.rowGroup=!0,i.rowGroupIndex=t}),r&&r.aggregationModel.forEach(({colId:e,aggFunc:t})=>{u(e).aggFunc=t}),n&&(n.pivotColIds.forEach((e,t)=>{const i=u(e);i.pivot=!0,i.pivotIndex=t}),this.gos.updateGridOptions({options:{pivotMode:n.pivotMode},source:"gridInitializing"})),s&&(s.leftColIds.forEach(e=>{u(e).pinned="left"}),s.rightColIds.forEach(e=>{u(e).pinned="right"})),o&&o.hiddenColIds.forEach(e=>{u(e).hide=!0}),a&&a.columnSizingModel.forEach(({colId:e,flex:t,width:i})=>{const r=u(e);r.flex=null!=t?t:null,r.width=i});const h=null==l?void 0:l.orderedColIds,d=!!(null==h?void 0:h.length),p=d?h.map(e=>u(e)):Object.values(c);if(p.length){this.columnStates=p;const e={sort:null,sortIndex:null,rowGroup:null,rowGroupIndex:null,aggFunc:null,pivot:null,pivotIndex:null,pinned:null,hide:null,flex:null};this.columnModel.applyColumnState({state:p,applyOrder:d,defaultState:e},"gridInitializing")}}setColumnPivotState(e){const t=this.columnStates;this.columnStates=void 0;const i=this.columnGroupStates;if(this.columnGroupStates=void 0,this.columnModel.isSecondaryColumnsPresent()){if(t){let i=[];for(const e of t)this.columnModel.getSecondaryColumn(e.colId)&&i.push(e);this.columnModel.applyColumnState({state:i,applyOrder:e},"gridInitializing")}i&&this.columnModel.setColumnGroupState(i,"gridInitializing")}}getColumnGroupState(){const e=this.columnModel.getColumnGroupState(),t=[];return e.forEach(({groupId:e,open:i})=>{i&&t.push(e)}),t.length?{openColumnGroupIds:t}:void 0}setColumnGroupState(e){var t;if(!e.hasOwnProperty("columnGroup"))return;const i=new Set(null==(t=e.columnGroup)?void 0:t.openColumnGroupIds),r=this.columnModel.getColumnGroupState().map(({groupId:e})=>{const t=i.has(e);return t&&i.delete(e),{groupId:e,open:t}});i.forEach(e=>{r.push({groupId:e,open:!0})}),r.length&&(this.columnGroupStates=r),this.columnModel.setColumnGroupState(r,"gridInitializing")}getFilterState(){var e;let t=this.filterManager.getFilterModel();t&&0===Object.keys(t).length&&(t=void 0);const i=null!=(e=this.filterManager.getAdvancedFilterModel())?e:void 0;return t||i?{filterModel:t,advancedFilterModel:i}:void 0}setFilterState(e,t){const{filterModel:i,advancedFilterModel:r}=null!=e?e:{advancedFilterModel:t};i&&this.filterManager.setFilterModel(i,"columnFilter"),r&&this.filterManager.setAdvancedFilterModel(r)}getRangeSelectionState(){var e;const t=null==(e=this.rangeService)?void 0:e.getCellRanges().map(e=>{const{id:t,type:i,startRow:r,endRow:n,columns:s,startColumn:o}=e;return{id:t,type:i,startRow:r,endRow:n,colIds:s.map(e=>e.getColId()),startColId:o.getColId()}});return(null==t?void 0:t.length)?{cellRanges:t}:void 0}setRangeSelectionState(e){if(!this.gos.get("enableRangeSelection")||!this.rangeService)return;const t=[];e.cellRanges.forEach(e=>{const i=[];if(e.colIds.forEach(e=>{const t=this.columnModel.getGridColumn(e);t&&i.push(t)}),!i.length)return;let r=this.columnModel.getGridColumn(e.startColId);if(!r){const e=this.columnModel.getAllDisplayedColumns(),t=new Set(i);r=e.find(e=>t.has(e))}t.push(d(h({},e),{columns:i,startColumn:r}))}),this.rangeService.setCellRanges(t)}getScrollState(){var e,t,i;if(!this.isClientSideRowModel)return;const r=null==(e=this.ctrlsService.getGridBodyCtrl())?void 0:e.getScrollFeature(),{left:n}=null!=(t=null==r?void 0:r.getHScrollPosition())?t:{left:0},{top:s}=null!=(i=null==r?void 0:r.getVScrollPosition())?i:{top:0};return s||n?{top:s,left:n}:void 0}setScrollState(e){var t;if(!this.isClientSideRowModel)return;const{top:i,left:r}=e;null==(t=this.ctrlsService.getGridBodyCtrl())||t.getScrollFeature().setScrollPosition(i,r)}getSideBarState(){var e,t;return null==(t=null==(e=this.sideBarService)?void 0:e.getSideBarComp())?void 0:t.getState()}getFocusedCellState(){if(!this.isClientSideRowModel)return;const e=this.focusService.getFocusedCell();if(e){const{column:t,rowIndex:i,rowPinned:r}=e;return{colId:t.getColId(),rowIndex:i,rowPinned:r}}}setFocusedCellState(e){if(!this.isClientSideRowModel)return;const{colId:t,rowIndex:i,rowPinned:r}=e;this.focusService.setFocusedCell({column:this.columnModel.getGridColumn(t),rowIndex:i,rowPinned:r,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}getPaginationState(){const e=this.paginationProxy.getCurrentPage(),t=this.gos.get("paginationAutoPageSize")?void 0:this.paginationProxy.getPageSize();if(e||t)return{page:e,pageSize:t}}setPaginationState(e){e.pageSize&&!this.gos.get("paginationAutoPageSize")&&this.paginationProxy.setPageSize(e.pageSize,"initialState"),"number"==typeof e.page&&this.paginationProxy.setPage(e.page)}getRowSelectionState(){var e;const t=this.selectionService.getSelectionState();return t&&(Array.isArray(t)||!1!==t.selectAll&&!1!==t.selectAllChildren||(null==(e=null==t?void 0:t.toggledNodes)?void 0:e.length))?t:void 0}setRowSelectionState(e){this.selectionService.setSelectionState(e,"gridInitializing")}getRowGroupExpansionState(){const e=this.expansionService.getExpandedRows();return e.length?{expandedRowGroupIds:e}:void 0}setRowGroupExpansionState(e){this.expansionService.expandRows(e.expandedRowGroupIds)}updateColumnState(e){const t=this.getColumnState();let i=!1;Object.entries(t).forEach(([e,t])=>{T(t,this.cachedState[e])||(i=!0)}),this.cachedState=h(h({},this.cachedState),t),i&&this.dispatchStateUpdateEvent(e)}updateCachedState(e,t){const i=this.cachedState[e];this.setCachedStateValue(e,t),T(t,i)||this.dispatchStateUpdateEvent([e])}setCachedStateValue(e,t){this.cachedState=d(h({},this.cachedState),{[e]:t})}refreshStaleState(){this.staleStateKeys.forEach(e=>{"rowSelection"===e&&this.setCachedStateValue(e,this.getRowSelectionState())}),this.staleStateKeys.clear()}dispatchStateUpdateEvent(e){this.suppressEvents||(e.forEach(e=>this.queuedUpdateSources.add(e)),this.dispatchStateUpdateEventDebounced())}dispatchQueuedStateUpdateEvents(){const e=Array.from(this.queuedUpdateSources);this.queuedUpdateSources.clear();const t={type:lt.EVENT_STATE_UPDATED,sources:e,state:this.cachedState};this.eventService.dispatchEvent(t)}suppressEventsAndDispatchInitEvent(e){this.suppressEvents=!0,this.columnAnimationService.setSuppressAnimation(!0),e(),setTimeout(()=>{this.suppressEvents=!1,this.queuedUpdateSources.clear(),this.isAlive()&&(this.columnAnimationService.setSuppressAnimation(!1),this.dispatchStateUpdateEvent(["gridInitializing"]))})}};g([ue("filterManager")],xu.prototype,"filterManager",2),g([ue("ctrlsService")],xu.prototype,"ctrlsService",2),g([ue("focusService")],xu.prototype,"focusService",2),g([ue("columnModel")],xu.prototype,"columnModel",2),g([ue("paginationProxy")],xu.prototype,"paginationProxy",2),g([ue("rowModel")],xu.prototype,"rowModel",2),g([ue("selectionService")],xu.prototype,"selectionService",2),g([ue("expansionService")],xu.prototype,"expansionService",2),g([ue("columnAnimationService")],xu.prototype,"columnAnimationService",2),g([he("sideBarService")],xu.prototype,"sideBarService",2),g([he("rangeService")],xu.prototype,"rangeService",2),g([ae],xu.prototype,"postConstruct",1),xu=g([ce("stateService")],xu);var Du=class extends rt{init(){this.processGridOptions(this.gridOptions)}processGridOptions(e){this.processOptions(e,wu)}processColumnDefs(e){this.processOptions(e,vu)}processOptions(e,t){const{validations:i,deprecations:r,allProperties:n,propertyExceptions:s,objectName:o,docsUrl:a}=t;n&&!0!==this.gridOptions.suppressPropertyNamesCheck&&this.checkProperties(e,[...null!=s?s:[],...Object.keys(r)],n,o,a);const l=new Set;Object.keys(e).forEach(t=>{var n;const s=r[t];if(s)if("renamed"in s){const{renamed:i,version:r}=s;l.add(`As of v${r}, ${String(t)} is deprecated. Please use ${String(i)} instead.`),e[i]=e[t]}else{const{message:e,version:i}=s;l.add(`As of v${i}, ${String(t)} is deprecated. ${null!=e?e:""}`)}const o=e[t];if(null==o||!1===o)return;const a=i[t];let c;if(!a)return;if("function"==typeof a){const i=a(e,this.gridOptions);if(!i)return;if("objectName"in i){const r=e[t];return Array.isArray(r)?void r.forEach(e=>{this.processOptions(e,i)}):void this.processOptions(e[t],i)}c=i}else c=a;const{module:u,dependencies:h,supportedRowModels:d}=c;if(d){const e=null!=(n=this.gridOptions.rowModelType)?n:"clientSide";if(!d.includes(e))return void l.add(`${String(t)} is not supported with the '${e}' row model.`)}if(u){const e=Array.isArray(u)?u:[u];let i=!0;if(e.forEach(e=>{ne.__assertRegistered(e,String(t),this.context.getGridId())||(i=!1,l.add(`${String(t)} is only available when ${e} is loaded.`))}),!i)return}if(h){const i=this.checkForWarning(t,h,e);if(i)return void l.add(i)}}),l.size>0&&l.forEach(e=>{z(e)})}checkForWarning(e,t,i){if("function"==typeof t)return t(i,this.gridOptions);const r=Object.entries(t).find(([e,t])=>{const r=i[e];return!t.includes(r)});if(!r)return null;const[n,s]=r;return s.length>1?`'${String(e)}' requires '${n}' to be one of [${s.join(", ")}].`:`'${String(e)}' requires '${n}' to be ${s[0]}.`}checkProperties(e,t,i,r,n){const s=Br(Object.getOwnPropertyNames(e),["__ob__","__v_skip","__metadata__",...t,...i],i);if(D(s,(e,t)=>{z(`invalid ${r} property '${e}' did you mean any of these: ${t.slice(0,8).join(", ")}`)}),Object.keys(s).length>0&&n){const e=this.getFrameworkOverrides().getDocLink(n);z(`to see all the valid ${r} properties please check: ${e}`)}}};g([ue("gridOptions")],Du.prototype,"gridOptions",2),g([ae],Du.prototype,"init",1),Du=g([ce("validationService")],Du);var Iu=class extends rt{constructor(){super(...arguments),this.syncEventListeners=new Map,this.asyncEventListeners=new Map,this.syncGlobalEventListeners=new Set,this.globalEventListenerPairs=new Map}postConstruct(){this.frameworkEventWrappingService=new me(this.getFrameworkOverrides())}addEventListener(e,t){const i=this.frameworkEventWrappingService.wrap(t),r=this.gos.useAsyncEvents()&&!ct.has(e),n=r?this.asyncEventListeners:this.syncEventListeners;n.has(e)||n.set(e,new Set),n.get(e).add(i),this.eventService.addEventListener(e,i,r)}removeEventListener(e,t){var i;const r=this.frameworkEventWrappingService.unwrap(t),n=this.asyncEventListeners.get(e),s=!!(null==n?void 0:n.delete(r));s||null==(i=this.syncEventListeners.get(e))||i.delete(r),this.eventService.removeEventListener(e,r,s)}addGlobalListener(e){const t=this.frameworkEventWrappingService.wrapGlobal(e);if(this.gos.useAsyncEvents()){const i=(e,i)=>{ct.has(e)&&t(e,i)},r=(e,i)=>{ct.has(e)||t(e,i)};this.globalEventListenerPairs.set(e,{syncListener:i,asyncListener:r}),this.eventService.addGlobalListener(i,!1),this.eventService.addGlobalListener(r,!0)}else this.syncGlobalEventListeners.add(t),this.eventService.addGlobalListener(t,!1)}removeGlobalListener(e){const t=this.frameworkEventWrappingService.unwrapGlobal(e);if(this.globalEventListenerPairs.has(t)){const{syncListener:i,asyncListener:r}=this.globalEventListenerPairs.get(t);this.eventService.removeGlobalListener(i,!1),this.eventService.removeGlobalListener(r,!0),this.globalEventListenerPairs.delete(e)}else this.syncGlobalEventListeners.delete(t),this.eventService.removeGlobalListener(t,!1)}destroyEventListeners(e,t){e.forEach((e,i)=>{e.forEach(e=>this.eventService.removeEventListener(i,e,t)),e.clear()}),e.clear()}destroyGlobalListeners(e,t){e.forEach(e=>this.eventService.removeGlobalListener(e,t)),e.clear()}destroy(){super.destroy(),this.destroyEventListeners(this.syncEventListeners,!1),this.destroyEventListeners(this.asyncEventListeners,!0),this.destroyGlobalListeners(this.syncGlobalEventListeners,!1),this.globalEventListenerPairs.forEach(({syncListener:e,asyncListener:t})=>{this.eventService.removeGlobalListener(e,!1),this.eventService.removeGlobalListener(t,!0)}),this.globalEventListenerPairs.clear()}};g([ae],Iu.prototype,"postConstruct",1),Iu=g([ce("apiEventService")],Iu);var Lu=class extends yn{constructor(){super('<span class="ag-paging-page-size"></span>'),this.hasEmptyOption=!1,this.handlePageSizeItemSelected=()=>{if(!this.selectPageSizeComp)return;const e=this.selectPageSizeComp.getValue();if(!e)return;const t=Number(e);isNaN(t)||t<1||t===this.paginationProxy.getPageSize()||(this.paginationProxy.setPageSize(t,"pageSizeSelector"),this.hasEmptyOption&&this.toggleSelectDisplay(!0),this.selectPageSizeComp.getFocusableElement().focus())}}init(){this.addManagedPropertyListener("paginationPageSizeSelector",()=>{this.onPageSizeSelectorValuesChange()}),this.addManagedListener(this.eventService,lt.EVENT_PAGINATION_CHANGED,e=>this.handlePaginationChanged(e))}handlePaginationChanged(e){if(!this.selectPageSizeComp||!(null==e?void 0:e.newPageSize))return;const t=this.paginationProxy.getPageSize();this.getPageSizeSelectorValues().includes(t)?this.selectPageSizeComp.setValue(t.toString()):this.hasEmptyOption?this.selectPageSizeComp.setValue(""):this.toggleSelectDisplay(!0)}toggleSelectDisplay(e){this.selectPageSizeComp&&this.reset(),e&&(this.reloadPageSizesSelector(),this.selectPageSizeComp&&this.appendChild(this.selectPageSizeComp))}reset(){Cr(this.getGui()),this.selectPageSizeComp&&(this.destroyBean(this.selectPageSizeComp),this.selectPageSizeComp=void 0)}onPageSizeSelectorValuesChange(){this.selectPageSizeComp&&this.shouldShowPageSizeSelector()&&this.reloadPageSizesSelector()}shouldShowPageSizeSelector(){return this.gos.get("pagination")&&!this.gos.get("suppressPaginationPanel")&&!this.gos.get("paginationAutoPageSize")&&!1!==this.gos.get("paginationPageSizeSelector")}reloadPageSizesSelector(){const e=this.getPageSizeSelectorValues(),t=this.paginationProxy.getPageSize(),i=!t||!e.includes(t);i&&(e.unshift(""),z("The paginationPageSize grid option is set to a value that is not in the list of page size options.\n                Please make sure that the paginationPageSize grid option is set to one of the values in the \n                paginationPageSizeSelector array, or set the paginationPageSizeSelector to false to hide the page size selector.")),this.selectPageSizeComp&&(this.destroyBean(this.selectPageSizeComp),this.selectPageSizeComp=void 0);const r=this.localeService.getLocaleTextFunc(),n=r("pageSizeSelectorLabel","Page Size:"),s=e.map(e=>({value:String(e),text:String(e)})),o=r("ariaPageSizeSelectorLabel","Page Size");this.selectPageSizeComp=this.createManagedBean(new Hn).addOptions(s).setValue(String(i?"":t)).setAriaLabel(o).setLabel(n).onValueChange(()=>this.handlePageSizeItemSelected()),this.hasEmptyOption=i}getPageSizeSelectorValues(){const e=this.gos.get("paginationPageSizeSelector");return Array.isArray(e)&&this.validateValues(e)?[...e].sort((e,t)=>e-t):[20,50,100]}validateValues(e){if(!e.length)return z("The paginationPageSizeSelector grid option is an empty array. This is most likely a mistake.\n                If you want to hide the page size selector, please set the paginationPageSizeSelector to false."),!1;for(let t=0;t<e.length;t++){const i=e[t],r=i>0;if("number"!=typeof i)return z("The paginationPageSizeSelector grid option contains a non-numeric value.\n                    Please make sure that all values in the paginationPageSizeSelector array are numbers."),!1;if(!r)return z("The paginationPageSizeSelector grid option contains a negative number or zero.\n                    Please make sure that all values in the paginationPageSizeSelector array are positive."),!1}return!0}destroy(){this.toggleSelectDisplay(!1),super.destroy()}};g([ue("paginationProxy")],Lu.prototype,"paginationProxy",2),g([ae],Lu.prototype,"init",1);var Nu=class extends rt{constructor(){super(),this.descriptionContainer=null,this.announceValue=X(this.announceValue.bind(this),200)}postConstruct(){const e=this.gos.getDocument(),t=this.descriptionContainer=e.createElement("div");t.classList.add("ag-aria-description-container"),qt(t,"polite"),Qt(t,"additions text"),Yt(t,!0),this.eGridDiv.appendChild(t)}announceValue(e){this.descriptionContainer&&(this.descriptionContainer.textContent="",setTimeout(()=>{this.isAlive()&&this.descriptionContainer&&(this.descriptionContainer.textContent=e)},50))}destroy(){super.destroy();const{descriptionContainer:e}=this;e&&(Cr(e),e.parentElement&&e.parentElement.removeChild(e)),this.descriptionContainer=null,this.eGridDiv=null}};g([ue("eGridDiv")],Nu.prototype,"eGridDiv",2),g([ae],Nu.prototype,"postConstruct",1),Nu=g([ce("ariaAnnouncementService")],Nu);var Ou=class{};function Fu(e){Ou.gridOptions=e}function ku(e,t,i){if(!t)return U("No gridOptions provided to createGrid"),{};const r=(new Hu).create(e,t,t=>{const i=new Lc(e);t.createBean(i)},void 0,i);if(!Object.isFrozen(t)&&!(null==i?void 0:i.frameworkOverrides)){const e="https://ag-grid.com/javascript-data-grid/grid-interface/#grid-api";Object.defineProperty(t,"api",{get:()=>{U(`gridOptions.api is no longer supported. See ${e}.`)},configurable:!0}),Object.defineProperty(t,"columnApi",{get:()=>{U(`gridOptions.columnApi is no longer supported and all methods moved to the grid api. See ${e}.`)},configurable:!0})}return r}Ou.gridOptions=void 0;var Gu=class{constructor(e,t,i){if(z("Since v31 new Grid(...) is deprecated. Use createGrid instead: `const gridApi = createGrid(...)`. The grid api is returned from createGrid and will not be available on gridOptions."),!t)return void U("No gridOptions provided to the grid");this.gridOptions=t;const r=(new Hu).create(e,t,t=>{const i=new Lc(e);t.createBean(i).addDestroyFunc(()=>{this.destroy()})},void 0,i);this.gridOptions.api=r,this.gridOptions.columnApi=new Rc(r)}destroy(){var e;this.gridOptions&&(null==(e=this.gridOptions.api)||e.destroy(),delete this.gridOptions.api,delete this.gridOptions.columnApi)}},Vu=1,Hu=class{create(e,t,i,r,n){var s;let o={};Ou.gridOptions?(O(o,Ou.gridOptions,!0,!0),o=h(h({},o),t)):o=t;const a=Su.getCoercedGridOptions(o),l=!!a.debug,c=null!=(s=a.gridId)?s:String(Vu++),u=this.getRegisteredModules(n,c),d=this.createBeansList(a.rowModelType,u,c),p=this.createProvidedBeans(e,a,n);if(!d)return void U("Failed to create grid.");const g={providedBeanInstances:p,beanClasses:d,debug:l,gridId:c},f=new Dc("Context",()=>g.debug),m=new se(g,f),v=m.getBean("beans");return this.registerModuleUserComponents(v,u),this.registerStackComponents(v,u),this.registerControllers(v,u),i(m),v.syncService.start(),r&&r(m),m.getBean("gridApi")}registerControllers(e,t){t.forEach(t=>{t.controllers&&t.controllers.forEach(t=>e.ctrlsFactory.register(t))})}registerStackComponents(e,t){const i=this.createAgStackComponentsList(t);e.agStackComponentsRegistry.setupComponents(i)}getRegisteredModules(e,t){const i=e?e.modules:null,r=ne.__getRegisteredModules(t),n=[],s={},o=(e,t,i)=>{var r;s[(r=t).moduleName]||(s[r.moduleName]=!0,n.push(r),ne.__register(r,e,i)),t.dependantModules&&t.dependantModules.forEach(t=>o(e,t,i))};return i&&i.forEach(e=>o(!0,e,t)),r&&r.forEach(e=>o(!ne.__isPackageBased(),e,void 0)),n}registerModuleUserComponents(e,t){this.extractModuleEntity(t,e=>e.userComponents?e.userComponents:[]).forEach(t=>{e.userComponentRegistry.registerDefaultComponent(t.componentName,t.componentClass)})}createProvidedBeans(e,t,i){let r=i?i.frameworkOverrides:null;y(r)&&(r=new Ec);const n={gridOptions:t,eGridDiv:e,globalEventListener:i?i.globalEventListener:null,globalSyncEventListener:i?i.globalSyncEventListener:null,frameworkOverrides:r};return i&&i.providedBeanInstances&&Object.assign(n,i.providedBeanInstances),n}createAgStackComponentsList(e){let t=[{componentName:"AgCheckbox",componentClass:zn},{componentName:"AgRadioButton",componentClass:Un},{componentName:"AgToggleButton",componentClass:Ul},{componentName:"AgInputTextField",componentClass:ts},{componentName:"AgInputTextArea",componentClass:Wl},{componentName:"AgInputNumberField",componentClass:is},{componentName:"AgInputDateField",componentClass:jl},{componentName:"AgInputRange",componentClass:Kl},{componentName:"AgRichSelect",componentClass:Ql},{componentName:"AgSelect",componentClass:Hn},{componentName:"AgSlider",componentClass:Zl},{componentName:"AgGridBody",componentClass:Ia},{componentName:"AgHeaderRoot",componentClass:Cl},{componentName:"AgSortIndicator",componentClass:Cs},{componentName:"AgPagination",componentClass:qc},{componentName:"AgPageSizeSelector",componentClass:Lu},{componentName:"AgOverlayWrapper",componentClass:Qc},{componentName:"AgGroupComponent",componentClass:ec},{componentName:"AgRowContainer",componentClass:Ha},{componentName:"AgFakeHorizontalScroll",componentClass:du},{componentName:"AgFakeVerticalScroll",componentClass:Au},{componentName:"AgAutocomplete",componentClass:vc}];const i=this.extractModuleEntity(e,e=>e.agStackComponents?e.agStackComponents:[]);return t=t.concat(i),t}createBeansList(e="clientSide",t,i){const r=t.filter(t=>!t.rowModel||t.rowModel===e),n={clientSide:"@ag-grid-community/client-side-row-model",infinite:"@ag-grid-community/infinite-row-model",serverSide:"@ag-grid-enterprise/server-side-row-model",viewport:"@ag-grid-enterprise/viewport-row-model"};if(!n[e])return void U("Could not find row model for rowModelType = "+e);if(!ne.__assertRegistered(n[e],`rowModelType = '${e}'`,i))return;const s=[aa,Xc,Zc,nu,Gc,zo,ho,Bc,zc,Ml,Lo,Kc,yl,bu,Du,Ol,Go,_t,fe,Su,dc,Mc,Wo,Tt,fl,Bl,Ll,Pc,nt,Tc,Oa,Vc,_c,xc,Dl,wl,Gs,Rc,Oc,Na,jc,Ac,zl,La,Nc,Fc,kc,$c,dt,Hc,Rl,ru,Nt,su,ou,Hl,au,lu,pu,gu,cu,Ru,Uo,_u,Pu,xu,Pl,Iu,Nu,xl],o=this.extractModuleEntity(r,e=>e.beans?e.beans:[]);s.push(...o);const a=[];return s.forEach(e=>{a.indexOf(e)<0&&a.push(e)}),a}extractModuleEntity(e,t){return[].concat(...e.map(t))}},Bu=class{wrap(e,t,i=[],r){const n=this.createWrapper(e,r);return t.forEach(e=>{this.createMethod(n,e,!0)}),i.forEach(e=>{this.createMethod(n,e,!1)}),n}unwrap(e){return e}createMethod(e,t,i){e.addMethod(t,this.createMethodProxy(e,t,i))}createMethodProxy(e,t,i){return function(){return e.hasMethod(t)?e.callMethod(t,arguments):(i&&console.warn("AG Grid: Framework component is missing the method "+t+"()"),null)}}},zu=class{};zu.CHART_TYPE_TO_SERIES_TYPE={column:"bar",groupedColumn:"bar",stackedColumn:"bar",normalizedColumn:"bar",bar:"bar",groupedBar:"bar",stackedBar:"bar",normalizedBar:"bar",line:"line",scatter:"scatter",bubble:"bubble",pie:"pie",donut:"donut",doughnut:"donut",area:"area",stackedArea:"area",normalizedArea:"area",histogram:"histogram",radarLine:"radar-line",radarArea:"radar-area",nightingale:"nightingale",radialColumn:"radial-column",radialBar:"radial-bar",sunburst:"sunburst",rangeBar:"range-bar",rangeArea:"range-area",boxPlot:"box-plot",treemap:"treemap",heatmap:"heatmap",waterfall:"waterfall"},zu.COMBO_CHART_TYPES=["columnLineCombo","areaColumnCombo","customCombo"],zu.SERIES_GROUP_TYPES=["grouped","stacked","normalized"];var Uu=(e=>(e.InsideBase="insideBase",e.InsideEnd="insideEnd",e.Center="center",e.OutsideEnd="outsideEnd",e))(Uu||{}),Wu="undefined"==typeof globalThis?{}:globalThis;Wu.HTMLElement="undefined"==typeof HTMLElement?{}:HTMLElement,Wu.HTMLButtonElement="undefined"==typeof HTMLButtonElement?{}:HTMLButtonElement,Wu.HTMLSelectElement="undefined"==typeof HTMLSelectElement?{}:HTMLSelectElement,Wu.HTMLInputElement="undefined"==typeof HTMLInputElement?{}:HTMLInputElement,Wu.Node="undefined"==typeof Node?{}:Node,Wu.MouseEvent="undefined"==typeof MouseEvent?{}:MouseEvent;var ju=class e{constructor(t,i,r,n,s,o){this.nextId=0,this.rowCountReady=!1,this.allNodesMap={},this.rootNode=t,this.gos=i,this.eventService=r,this.columnModel=n,this.beans=o,this.selectionService=s,this.rootNode.group=!0,this.rootNode.level=-1,this.rootNode.id=e.ROOT_NODE_ID,this.rootNode.allLeafChildren=[],this.rootNode.childrenAfterGroup=[],this.rootNode.childrenAfterSort=[],this.rootNode.childrenAfterAggFilter=[],this.rootNode.childrenAfterFilter=[]}getCopyOfNodesMap(){return ln.cloneObject(this.allNodesMap)}getRowNode(e){return this.allNodesMap[e]}setRowData(t){if("string"==typeof t)return void console.warn("AG Grid: rowData must be an array.");this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(t);const i=this.rootNode,r=this.rootNode.sibling;i.childrenAfterFilter=null,i.childrenAfterGroup=null,i.childrenAfterAggFilter=null,i.childrenAfterSort=null,i.childrenMapped=null,i.updateHasChildren(),this.nextId=0,this.allNodesMap={},t?i.allLeafChildren=t.map(t=>this.createNode(t,this.rootNode,e.TOP_LEVEL)):(i.allLeafChildren=[],i.childrenAfterGroup=[]),r&&(r.childrenAfterFilter=i.childrenAfterFilter,r.childrenAfterGroup=i.childrenAfterGroup,r.childrenAfterAggFilter=i.childrenAfterAggFilter,r.childrenAfterSort=i.childrenAfterSort,r.childrenMapped=i.childrenMapped,r.allLeafChildren=i.allLeafChildren)}updateRowData(e,t){this.rowCountReady=!0,this.dispatchRowDataUpdateStartedEvent(e.add);const i={remove:[],update:[],add:[]},r=[];return this.executeRemove(e,i,r),this.executeUpdate(e,i,r),this.executeAdd(e,i),this.updateSelection(r,"rowDataChanged"),t&&ln.sortRowNodesByOrder(this.rootNode.allLeafChildren,t),i}isRowCountReady(){return this.rowCountReady}dispatchRowDataUpdateStartedEvent(e){const t={type:lt.EVENT_ROW_DATA_UPDATE_STARTED,firstRowData:(null==e?void 0:e.length)?e[0]:null};this.eventService.dispatchEvent(t)}updateSelection(e,t){const i=e.length>0;if(i&&this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,source:t}),this.selectionService.updateGroupsFromChildrenSelections(t),i){const e={type:lt.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(e)}}executeAdd(t,i){var r;const{add:n,addIndex:s}=t;if(ln.missingOrEmpty(n))return;const o=n.map(t=>this.createNode(t,this.rootNode,e.TOP_LEVEL));if("number"==typeof s&&s>=0){const{allLeafChildren:e}=this.rootNode,t=e.length;let i=s;if(this.gos.get("treeData")&&s>0&&t>0)for(let n=0;n<t;n++)if((null==(r=e[n])?void 0:r.rowIndex)==s-1){i=n+1;break}const n=e.slice(0,i),a=e.slice(i,e.length);this.rootNode.allLeafChildren=[...n,...o,...a]}else this.rootNode.allLeafChildren=[...this.rootNode.allLeafChildren,...o];this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren),i.add=o}executeRemove(e,t,i){const{remove:r}=e;if(ln.missingOrEmpty(r))return;const n={};r.forEach(e=>{const r=this.lookupRowNode(e);r&&(r.isSelected()&&i.push(r),r.clearRowTopAndRowIndex(),n[r.id]=!0,delete this.allNodesMap[r.id],t.remove.push(r))}),this.rootNode.allLeafChildren=this.rootNode.allLeafChildren.filter(e=>!n[e.id]),this.rootNode.sibling&&(this.rootNode.sibling.allLeafChildren=this.rootNode.allLeafChildren)}executeUpdate(t,i,r){const{update:n}=t;ln.missingOrEmpty(n)||n.forEach(t=>{const n=this.lookupRowNode(t);n&&(n.updateData(t),!n.selectable&&n.isSelected()&&r.push(n),this.setMasterForRow(n,t,e.TOP_LEVEL,!1),i.update.push(n))})}lookupRowNode(e){const t=this.gos.getCallback("getRowId");let i;if(t){const r=t({data:e,level:0});if(i=this.allNodesMap[r],!i)return console.error(`AG Grid: could not find row id=${r}, data item was not found for this id`),null}else if(i=this.rootNode.allLeafChildren.find(t=>t.data===e),!i)return console.error("AG Grid: could not find data item as object was not found",e),console.error("Consider using getRowId to help the Grid find matching row data"),null;return i||null}createNode(e,t,i){const r=new Ls(this.beans);r.group=!1,this.setMasterForRow(r,e,i,!0);const n=this.gos.get("suppressParentsInRowNodes");return t&&!n&&(r.parent=t),r.level=i,r.setDataAndId(e,this.nextId.toString()),this.allNodesMap[r.id]&&console.warn(`AG Grid: duplicate node id '${r.id}' detected from getRowId callback, this could cause issues in your grid.`),this.allNodesMap[r.id]=r,this.nextId++,r}setMasterForRow(e,t,i,r){if(this.gos.get("treeData"))e.setMaster(!1),r&&(e.expanded=!1);else{if(this.gos.get("masterDetail")){const i=this.gos.get("isRowMaster");i?e.setMaster(i(t)):e.setMaster(!0)}else e.setMaster(!1);if(r){const t=this.columnModel.getRowGroupColumns(),r=i+(t?t.length:0);e.expanded=!!e.master&&this.isExpanded(r)}}}isExpanded(e){const t=this.gos.get("groupDefaultExpanded");return-1===t||e<t}};ju.TOP_LEVEL=0,ju.ROOT_NODE_ID="ROOT_NODE_ID";var Ku=ju,$u=class extends rt{constructor(){super(...arguments),this.onRowHeightChanged_debounced=ln.debounce(this.onRowHeightChanged.bind(this),100),this.rowsToDisplay=[],this.hasStarted=!1,this.shouldSkipSettingDataOnStart=!1,this.isRefreshingModel=!1,this.rowCountReady=!1}init(){const e=this.refreshModel.bind(this,{step:"group"}),t=!this.gos.get("suppressAnimationFrame"),i=this.refreshModel.bind(this,{step:"group",afterColumnsChanged:!0,keepRenderedRows:!0,animate:t});this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,i),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_VALUE_CHANGED,this.onValueChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_CHANGED,this.refreshModel.bind(this,{step:"pivot"})),this.addManagedListener(this.eventService,lt.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,this.onSortChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedListener(this.eventService,lt.EVENT_GRID_STYLES_CHANGED,this.onGridStylesChanges.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_GRID_READY,()=>this.onGridReady()),this.addPropertyListeners(),this.rootNode=new Ls(this.beans),this.nodeManager=new Ku(this.rootNode,this.gos,this.eventService,this.columnModel,this.selectionService,this.beans)}addPropertyListeners(){const e=new Set(["treeData","masterDetail"]),t=new Set(["suppressParentsInRowNodes","groupDefaultExpanded","groupAllowUnbalanced","initialGroupOrderComparator","groupHideOpenParents","groupDisplayType"]),i=new Set(["excludeChildrenWhenTreeDataFiltering"]),r=new Set(["removePivotHeaderRowWhenSingleValueColumn","pivotRowTotals","pivotColumnGroupTotals","suppressExpandablePivotGroups"]),n=new Set(["getGroupRowAgg","alwaysAggregateAtRootLevel","groupIncludeTotalFooter","suppressAggFilteredOnly","grandTotalRow"]),s=new Set(["postSortRows","groupDisplayType","accentedSort"]),o=new Set([]),a=new Set(["groupRemoveSingleChildren","groupRemoveLowestSingleChildren","groupIncludeFooter","groupTotalRow"]),l=[...e,...t,...i,...r,...r,...n,...s,...o,...a];this.addManagedPropertyListeners(l,l=>{var c;const u=null==(c=l.changeSet)?void 0:c.properties;if(!u)return;const h=e=>u.some(t=>e.has(t));h(e)?this.setRowData(this.rootNode.allLeafChildren.map(e=>e.data)):h(t)?this.refreshModel({step:"group"}):h(i)?this.refreshModel({step:"filter"}):h(r)?this.refreshModel({step:"pivot"}):h(n)?this.refreshModel({step:"aggregate"}):h(s)?this.refreshModel({step:"sort"}):h(o)?this.refreshModel({step:"filter_aggregates"}):h(a)&&this.refreshModel({step:"map"})}),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights())}start(){this.hasStarted=!0,this.shouldSkipSettingDataOnStart?this.dispatchUpdateEventsAndRefresh():this.setInitialData()}setInitialData(){const e=this.gos.get("rowData");e&&(this.shouldSkipSettingDataOnStart=!0,this.setRowData(e))}ensureRowHeightsValid(e,t,i,r){let n,s=!1;do{n=!1;const o=this.getRowIndexAtPixel(e),a=this.getRowIndexAtPixel(t),l=Math.max(o,i),c=Math.min(a,r);for(let e=l;e<=c;e++){const t=this.getRow(e);if(t.rowHeightEstimated){const e=this.gos.getRowHeightForNode(t);t.setRowHeight(e.height),n=!0,s=!0}}n&&this.setRowTopAndRowIndex()}while(n);return s}setRowTopAndRowIndex(){const e=this.environment.getDefaultRowHeight();let t=0;const i=new Set,r=this.gos.isDomLayout("normal");for(let n=0;n<this.rowsToDisplay.length;n++){const s=this.rowsToDisplay[n];if(null!=s.id&&i.add(s.id),null==s.rowHeight){const t=this.gos.getRowHeightForNode(s,r,e);s.setRowHeight(t.height,t.estimated)}s.setRowTop(t),s.setRowIndex(n),t+=s.rowHeight}return i}clearRowTopAndRowIndex(e,t){const i=e.isActive(),r=e=>{e&&null!=e.id&&!t.has(e.id)&&e.clearRowTopAndRowIndex()},n=e=>{if(r(e),r(e.detailNode),r(e.sibling),e.hasChildren()&&e.childrenAfterGroup){const t=-1==e.level;i&&!t&&!e.expanded||e.childrenAfterGroup.forEach(n)}};n(this.rootNode)}ensureRowsAtPixel(e,t,i=0){const r=this.getRowIndexAtPixel(t),n=this.getRow(r),s=!this.gos.get("suppressAnimationFrame");return n!==e[0]&&(e.forEach(e=>{ln.removeFromArray(this.rootNode.allLeafChildren,e)}),e.forEach((e,t)=>{ln.insertIntoArray(this.rootNode.allLeafChildren,e,Math.max(r+i,0)+t)}),this.refreshModel({step:"group",keepRenderedRows:!0,keepEditingRows:!0,animate:s}),!0)}highlightRowAtPixel(e,t){const i=null!=t?this.getRowIndexAtPixel(t):null,r=null!=i?this.getRow(i):null;if(!r||!e||r===e||null==t)return void(this.lastHighlightedRow&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null));const n=this.getHighlightPosition(t,r);this.lastHighlightedRow&&this.lastHighlightedRow!==r&&(this.lastHighlightedRow.setHighlighted(null),this.lastHighlightedRow=null),r.setHighlighted(n),this.lastHighlightedRow=r}getHighlightPosition(e,t){if(!t){const i=this.getRowIndexAtPixel(e);if(!(t=this.getRow(i||0)))return 1}const{rowTop:i,rowHeight:r}=t;return e-i<r/2?0:1}getLastHighlightedRowNode(){return this.lastHighlightedRow}isLastRowIndexKnown(){return!0}getRowCount(){return this.rowsToDisplay?this.rowsToDisplay.length:0}getTopLevelRowCount(){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return 1;const e=this.rootNode.childrenAfterAggFilter;return e?e.length:0}getTopLevelRowDisplayedIndex(e){if(this.rowsToDisplay&&this.rowsToDisplay[0]===this.rootNode)return e;let t=this.rootNode.childrenAfterSort[e];if(this.gos.get("groupHideOpenParents"))for(;t.expanded&&t.childrenAfterSort&&t.childrenAfterSort.length>0;)t=t.childrenAfterSort[0];return t.rowIndex}getRowBounds(e){if(ln.missing(this.rowsToDisplay))return null;const t=this.rowsToDisplay[e];return t?{rowTop:t.rowTop,rowHeight:t.rowHeight}:null}onRowGroupOpened(){const e=this.gos.isAnimateRows();this.refreshModel({step:"map",keepRenderedRows:!0,animate:e})}onFilterChanged(e){if(e.afterDataChange)return;const t=this.gos.isAnimateRows(),i=0===e.columns.length||e.columns.some(e=>e.isPrimary())?"filter":"filter_aggregates";this.refreshModel({step:i,keepRenderedRows:!0,animate:t})}onSortChanged(){const e=this.gos.isAnimateRows();this.refreshModel({step:"sort",keepRenderedRows:!0,animate:e,keepEditingRows:!0})}getType(){return"clientSide"}onValueChanged(){this.columnModel.isPivotActive()?this.refreshModel({step:"pivot"}):this.refreshModel({step:"aggregate"})}createChangePath(e){const t=ln.missingOrEmpty(e),i=new kl(!1,this.rootNode);return(t||this.gos.get("treeData"))&&i.setInactive(),i}isSuppressModelUpdateAfterUpdateTransaction(e){if(!this.gos.get("suppressModelUpdateAfterUpdateTransaction"))return!1;if(null==e.rowNodeTransactions)return!1;const t=e.rowNodeTransactions.filter(e=>null!=e.add&&e.add.length>0||null!=e.remove&&e.remove.length>0);return null==t||0==t.length}buildRefreshModelParams(e){let t="group";const i={everything:"group",group:"group",filter:"filter",map:"map",aggregate:"aggregate",sort:"sort",pivot:"pivot"};if(ln.exists(e)&&(t=i[e]),!ln.missing(t))return{step:t,keepRenderedRows:!0,keepEditingRows:!0,animate:!this.gos.get("suppressAnimationFrame")};console.error(`AG Grid: invalid step ${e}, available steps are ${Object.keys(i).join(", ")}`)}refreshModel(e){if(!this.hasStarted||this.isRefreshingModel||this.columnModel.shouldRowModelIgnoreRefresh())return;let t="object"==typeof e&&"step"in e?e:this.buildRefreshModelParams(e);if(!t)return;if(this.isSuppressModelUpdateAfterUpdateTransaction(t))return;const i=this.createChangePath(t.rowNodeTransactions);switch(this.isRefreshingModel=!0,t.step){case"group":this.doRowGrouping(t.rowNodeTransactions,t.rowNodeOrder,i,!!t.afterColumnsChanged);case"filter":this.doFilter(i);case"pivot":this.doPivot(i);case"aggregate":this.doAggregate(i);case"filter_aggregates":this.doFilterAggregates(i);case"sort":this.doSort(t.rowNodeTransactions,i);case"map":this.doRowsToDisplay()}const r=this.setRowTopAndRowIndex();this.clearRowTopAndRowIndex(i,r),this.isRefreshingModel=!1;const n={type:lt.EVENT_MODEL_UPDATED,animate:t.animate,keepRenderedRows:t.keepRenderedRows,newData:t.newData,newPage:!1,keepUndoRedoStack:t.keepUndoRedoStack};this.eventService.dispatchEvent(n)}isEmpty(){const e=ln.missing(this.rootNode.allLeafChildren)||0===this.rootNode.allLeafChildren.length;return ln.missing(this.rootNode)||e||!this.columnModel.isReady()}isRowsToRender(){return ln.exists(this.rowsToDisplay)&&this.rowsToDisplay.length>0}getNodesInRangeForSelection(e,t){let i=!t,r=!1;const n=[],s=this.gos.get("groupSelectsChildren");return this.forEachNodeAfterFilterAndSort(o=>{if(!r)if(i&&(o===t||o===e)&&(r=!0,o.group&&s))n.push(...o.allLeafChildren);else{if(!i){if(o!==t&&o!==e)return;i=!0}(!o.group||!s)&&n.push(o)}}),n}setDatasource(e){console.error("AG Grid: should never call setDatasource on clientSideRowController")}getTopLevelNodes(){return this.rootNode?this.rootNode.childrenAfterGroup:null}getRootNode(){return this.rootNode}getRow(e){return this.rowsToDisplay[e]}isRowPresent(e){return this.rowsToDisplay.indexOf(e)>=0}getRowIndexAtPixel(e){if(this.isEmpty()||0===this.rowsToDisplay.length)return-1;let t=0,i=this.rowsToDisplay.length-1;if(e<=0)return 0;if(ln.last(this.rowsToDisplay).rowTop<=e)return this.rowsToDisplay.length-1;let r=-1,n=-1;for(;;){const s=Math.floor((t+i)/2),o=this.rowsToDisplay[s];if(this.isRowInPixel(o,e))return s;if(o.rowTop<e?t=s+1:o.rowTop>e&&(i=s-1),r===t&&n===i)return s;r=t,n=i}}isRowInPixel(e,t){const i=e.rowTop,r=e.rowTop+e.rowHeight;return i<=t&&r>t}forEachLeafNode(e){this.rootNode.allLeafChildren&&this.rootNode.allLeafChildren.forEach((t,i)=>e(t,i))}forEachNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterGroup||[]],callback:e,recursionType:0,index:0,includeFooterNodes:t})}forEachNodeAfterFilter(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterAggFilter||[]],callback:e,recursionType:1,index:0,includeFooterNodes:t})}forEachNodeAfterFilterAndSort(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[...this.rootNode.childrenAfterSort||[]],callback:e,recursionType:2,index:0,includeFooterNodes:t})}forEachPivotNode(e,t=!1){this.recursivelyWalkNodesAndCallback({nodes:[this.rootNode],callback:e,recursionType:3,index:0,includeFooterNodes:t})}recursivelyWalkNodesAndCallback(e){const{nodes:t,callback:i,recursionType:r,includeFooterNodes:n}=e;let{index:s}=e;const o=e=>{var r;const o=null==(r=t[0])?void 0:r.parent;if(!o)return;const a=n&&this.gos.getGrandTotalRow(),l=this.gos.getGroupTotalRowCallback(),c=n&&l({node:o});o===this.rootNode?a===e&&(o.createFooter(),i(o.sibling,s++)):c===e&&(o.createFooter(),i(o.sibling,s++))};o("top");for(let e=0;e<t.length;e++){const o=t[e];if(i(o,s++),o.hasChildren()&&!o.footer){let e=null;switch(r){case 0:e=o.childrenAfterGroup;break;case 1:e=o.childrenAfterAggFilter;break;case 2:e=o.childrenAfterSort;break;case 3:e=o.leafGroup?null:o.childrenAfterSort}e&&(s=this.recursivelyWalkNodesAndCallback({nodes:[...e],callback:i,recursionType:r,index:s,includeFooterNodes:n}))}}return o("bottom"),s}doAggregate(e){var t;null==(t=this.aggregationStage)||t.execute({rowNode:this.rootNode,changedPath:e})}doFilterAggregates(e){this.filterAggregatesStage?this.filterAggregatesStage.execute({rowNode:this.rootNode,changedPath:e}):this.rootNode.childrenAfterAggFilter=this.rootNode.childrenAfterFilter}expandOrCollapseAll(e){const t=this.gos.get("treeData"),i=this.columnModel.isPivotActive(),r=n=>{n&&n.forEach(n=>{const s=()=>{n.expanded=e,r(n.childrenAfterGroup)};t?ln.exists(n.childrenAfterGroup)&&s():i?!n.leafGroup&&s():n.group&&s()})};this.rootNode&&r(this.rootNode.childrenAfterGroup),this.refreshModel({step:"map"});const n=e?"expandAll":"collapseAll",s={type:lt.EVENT_EXPAND_COLLAPSE_ALL,source:n};this.eventService.dispatchEvent(s)}doSort(e,t){this.sortStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,changedPath:t})}doRowGrouping(e,t,i,r){if(this.groupStage){if(e?this.groupStage.execute({rowNode:this.rootNode,rowNodeTransactions:e,rowNodeOrder:t,changedPath:i}):this.groupStage.execute({rowNode:this.rootNode,changedPath:i,afterColumnsChanged:r}),this.gos.get("groupSelectsChildren")&&this.selectionService.updateGroupsFromChildrenSelections("rowGroupChanged",i)){const e={type:lt.EVENT_SELECTION_CHANGED,source:"rowGroupChanged"};this.eventService.dispatchEvent(e)}}else this.rootNode.childrenAfterGroup=this.rootNode.allLeafChildren,this.rootNode.sibling&&(this.rootNode.sibling.childrenAfterGroup=this.rootNode.childrenAfterGroup),this.rootNode.updateHasChildren();this.nodeManager.isRowCountReady()&&(this.rowCountReady=!0,this.eventService.dispatchEventOnce({type:lt.EVENT_ROW_COUNT_READY}))}doFilter(e){this.filterStage.execute({rowNode:this.rootNode,changedPath:e})}doPivot(e){var t;null==(t=this.pivotStage)||t.execute({rowNode:this.rootNode,changedPath:e})}getCopyOfNodesMap(){return this.nodeManager.getCopyOfNodesMap()}getRowNode(e){if("string"==typeof e&&0==e.indexOf(Ls.ID_PREFIX_ROW_GROUP)){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}return this.nodeManager.getRowNode(e)}setRowData(e){this.selectionService.reset("rowDataChanged"),this.nodeManager.setRowData(e),this.hasStarted&&this.dispatchUpdateEventsAndRefresh()}dispatchUpdateEventsAndRefresh(){const e={type:lt.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(e),this.refreshModel({step:"group",newData:!0})}batchUpdateRowData(e,t){if(null==this.applyAsyncTransactionsTimeout){this.rowDataTransactionBatch=[];const e=this.gos.getAsyncTransactionWaitMillis();this.applyAsyncTransactionsTimeout=window.setTimeout(()=>{this.executeBatchUpdateRowData()},e)}this.rowDataTransactionBatch.push({rowDataTransaction:e,callback:t})}flushAsyncTransactions(){null!=this.applyAsyncTransactionsTimeout&&(clearTimeout(this.applyAsyncTransactionsTimeout),this.executeBatchUpdateRowData())}executeBatchUpdateRowData(){this.valueCache.onDataChanged();const e=[],t=[];let i=!1;if(this.rowDataTransactionBatch&&this.rowDataTransactionBatch.forEach(r=>{const n=this.nodeManager.updateRowData(r.rowDataTransaction,void 0);t.push(n),r.callback&&e.push(r.callback.bind(null,n)),"number"==typeof r.rowDataTransaction.addIndex&&(i=!0)}),this.commonUpdateRowData(t,void 0,i),e.length>0&&window.setTimeout(()=>{e.forEach(e=>e())},0),t.length>0){const e={type:lt.EVENT_ASYNC_TRANSACTIONS_FLUSHED,results:t};this.eventService.dispatchEvent(e)}this.rowDataTransactionBatch=null,this.applyAsyncTransactionsTimeout=void 0}updateRowData(e,t){this.valueCache.onDataChanged();const i=this.nodeManager.updateRowData(e,t),r="number"==typeof e.addIndex;return this.commonUpdateRowData([i],t,r),i}createRowNodeOrder(){if(this.gos.get("suppressMaintainUnsortedOrder"))return;const e={};if(this.rootNode&&this.rootNode.allLeafChildren)for(let t=0;t<this.rootNode.allLeafChildren.length;t++)e[this.rootNode.allLeafChildren[t].id]=t;return e}commonUpdateRowData(e,t,i){if(!this.hasStarted)return;const r=!this.gos.get("suppressAnimationFrame");i&&(t=this.createRowNodeOrder());const n={type:lt.EVENT_ROW_DATA_UPDATED};this.eventService.dispatchEvent(n),this.refreshModel({step:"group",rowNodeTransactions:e,rowNodeOrder:t,keepRenderedRows:!0,keepEditingRows:!0,animate:r})}doRowsToDisplay(){this.rowsToDisplay=this.flattenStage.execute({rowNode:this.rootNode})}onRowHeightChanged(){this.refreshModel({step:"map",keepRenderedRows:!0,keepEditingRows:!0,keepUndoRedoStack:!0})}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}resetRowHeights(){const e=this.resetRowHeightsForAllRowNodes();this.rootNode.setRowHeight(this.rootNode.rowHeight,!0),this.rootNode.sibling&&this.rootNode.sibling.setRowHeight(this.rootNode.sibling.rowHeight,!0),e&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{t.setRowHeight(t.rowHeight,!0);const i=t.detailNode;i&&i.setRowHeight(i.rowHeight,!0),t.sibling&&t.sibling.setRowHeight(t.sibling.rowHeight,!0),e=!0}),e}onGridStylesChanges(){this.columnModel.isAutoRowHeightActive()||this.resetRowHeights()}onGridReady(){this.hasStarted||this.setInitialData()}isRowDataLoaded(){return this.rowCountReady}};g([ue("columnModel")],$u.prototype,"columnModel",2),g([ue("selectionService")],$u.prototype,"selectionService",2),g([ue("valueCache")],$u.prototype,"valueCache",2),g([ue("beans")],$u.prototype,"beans",2),g([ue("filterStage")],$u.prototype,"filterStage",2),g([ue("sortStage")],$u.prototype,"sortStage",2),g([ue("flattenStage")],$u.prototype,"flattenStage",2),g([he("groupStage")],$u.prototype,"groupStage",2),g([he("aggregationStage")],$u.prototype,"aggregationStage",2),g([he("pivotStage")],$u.prototype,"pivotStage",2),g([he("filterAggregatesStage")],$u.prototype,"filterAggregatesStage",2),g([ae],$u.prototype,"init",1),$u=g([ce("rowModel")],$u);var qu=class extends rt{execute(e){const{changedPath:t}=e;this.filterService.filter(t)}};g([ue("filterService")],qu.prototype,"filterService",2),qu=g([ce("filterStage")],qu);var Yu=class extends rt{execute(e){const t=this.sortController.getSortOptions(),i=ln.exists(t)&&t.length>0,r=i&&ln.exists(e.rowNodeTransactions)&&this.gos.get("deltaSort"),n=t.some(e=>this.gos.isColumnsSortingCoupledToGroup()?e.column.isPrimary()&&e.column.isRowGroupActive():!!e.column.getColDef().showRowGroup);this.sortService.sort(t,i,r,e.rowNodeTransactions,e.changedPath,n)}};g([ue("sortService")],Yu.prototype,"sortService",2),g([ue("sortController")],Yu.prototype,"sortController",2),Yu=g([ce("sortStage")],Yu);var Qu=class extends rt{execute(e){const t=e.rowNode,i=[],r=this.beans.columnModel.isPivotMode(),n=r&&t.leafGroup,s=n?[t]:t.childrenAfterSort,o=this.getFlattenDetails();if(this.recursivelyAddToRowsToDisplay(o,s,i,r,0),!n&&i.length>0&&o.grandTotalRow){t.createFooter();const e="top"===o.grandTotalRow;this.addRowNodeToRowsToDisplay(o,t.sibling,i,0,e)}return i}getFlattenDetails(){const e=this.gos.get("groupRemoveSingleChildren");return{groupRemoveLowestSingleChildren:!e&&this.gos.get("groupRemoveLowestSingleChildren"),groupRemoveSingleChildren:e,isGroupMultiAutoColumn:this.gos.isGroupMultiAutoColumn(),hideOpenParents:this.gos.get("groupHideOpenParents"),grandTotalRow:this.gos.getGrandTotalRow(),groupTotalRow:this.gos.getGroupTotalRowCallback()}}recursivelyAddToRowsToDisplay(e,t,i,r,n){if(!ln.missingOrEmpty(t))for(let s=0;s<t.length;s++){const o=t[s],a=o.hasChildren(),l=r&&!a,c=e.groupRemoveSingleChildren&&a&&1===o.childrenAfterGroup.length,u=e.groupRemoveLowestSingleChildren&&a&&o.leafGroup&&1===o.childrenAfterGroup.length,h=r&&o.leafGroup,d=e.hideOpenParents&&o.expanded&&!o.master&&!h;if(!(l||d||c||u)&&this.addRowNodeToRowsToDisplay(e,o,i,n),!r||!o.leafGroup)if(a){const t=c||u;if(o.expanded||t){const s=e.groupTotalRow({node:o});s||o.destroyFooter();const a=t?n:n+1;"top"===s&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,a)),this.recursivelyAddToRowsToDisplay(e,o.childrenAfterSort,i,r,a),"bottom"===s&&(o.createFooter(),this.addRowNodeToRowsToDisplay(e,o.sibling,i,a))}}else if(o.master&&o.expanded){const t=this.createDetailNode(o);this.addRowNodeToRowsToDisplay(e,t,i,n)}}}addRowNodeToRowsToDisplay(e,t,i,r,n){n?i.unshift(t):i.push(t),t.setUiLevel(e.isGroupMultiAutoColumn?0:r)}createDetailNode(e){if(ln.exists(e.detailNode))return e.detailNode;const t=new Ls(this.beans);return t.detail=!0,t.selectable=!1,t.parent=e,ln.exists(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1,e.detailNode=t,t}};g([ue("beans")],Qu.prototype,"beans",2),Qu=g([ce("flattenStage")],Qu);var Xu=class extends rt{sort(e,t,i,r,n,s){const o=this.gos.get("groupMaintainOrder"),a=this.columnModel.getAllGridColumns().some(e=>e.isRowGroupActive());let l={};i&&r&&(l=this.calculateDirtyNodes(r));const c=this.columnModel.isPivotMode(),u=this.gos.getCallback("postSortRows");n&&n.forEachChangedNodeDepthFirst(r=>{var h;this.pullDownGroupDataForHideOpenParents(r.childrenAfterAggFilter,!0);const d=c&&r.leafGroup;if(o&&a&&!r.leafGroup&&!s){const e=null==(h=this.columnModel.getRowGroupColumns())?void 0:h[r.level+1],t=null===(null==e?void 0:e.getSort()),i=r.childrenAfterAggFilter.slice(0);if(r.childrenAfterSort&&!t){const e={};r.childrenAfterSort.forEach((t,i)=>{e[t.id]=i}),i.sort((t,i)=>{var r,n;return(null!=(r=e[t.id])?r:0)-(null!=(n=e[i.id])?n:0)})}r.childrenAfterSort=i}else r.childrenAfterSort=!t||d?r.childrenAfterAggFilter.slice(0):i?this.doDeltaSort(r,l,n,e):this.rowNodeSorter.doFullSort(r.childrenAfterAggFilter,e);if(r.sibling&&(r.sibling.childrenAfterSort=r.childrenAfterSort),this.updateChildIndexes(r),u){const e={nodes:r.childrenAfterSort};u(e)}}),this.updateGroupDataForHideOpenParents(n)}calculateDirtyNodes(e){const t={},i=e=>{e&&e.forEach(e=>t[e.id]=!0)};return e&&e.forEach(e=>{i(e.add),i(e.update),i(e.remove)}),t}doDeltaSort(e,t,i,r){const n=e.childrenAfterAggFilter,s=e.childrenAfterSort;if(!s)return this.rowNodeSorter.doFullSort(n,r);const o={},a=[];n.forEach(e=>{t[e.id]||!i.canSkip(e)?a.push(e):o[e.id]=!0});const l=s.filter(e=>o[e.id]),c=(e,t)=>({currentPos:t,rowNode:e}),u=a.map(c).sort((e,t)=>this.rowNodeSorter.compareRowNodes(r,e,t));return this.mergeSortedArrays(r,u,l.map(c)).map(({rowNode:e})=>e)}mergeSortedArrays(e,t,i){const r=[];let n=0,s=0;for(;n<t.length&&s<i.length;)this.rowNodeSorter.compareRowNodes(e,t[n],i[s])<0?r.push(t[n++]):r.push(i[s++]);for(;n<t.length;)r.push(t[n++]);for(;s<i.length;)r.push(i[s++]);return r}updateChildIndexes(e){if(ln.missing(e.childrenAfterSort))return;const t=e.childrenAfterSort;for(let i=0;i<t.length;i++){const r=t[i],n=0===i,s=i===e.childrenAfterSort.length-1;r.setFirstChild(n),r.setLastChild(s),r.setChildIndex(i)}}updateGroupDataForHideOpenParents(e){if(!this.gos.get("groupHideOpenParents"))return;if(this.gos.get("treeData"))return ln.warnOnce("The property hideOpenParents dose not work with Tree Data. This is because Tree Data has values at the group level, it doesn't make sense to hide them."),!1;const t=e=>{this.pullDownGroupDataForHideOpenParents(e.childrenAfterSort,!1),e.childrenAfterSort.forEach(e=>{e.hasChildren()&&t(e)})};e&&e.executeFromRootNode(e=>t(e))}pullDownGroupDataForHideOpenParents(e,t){this.gos.get("groupHideOpenParents")&&!ln.missing(e)&&e.forEach(e=>{this.columnModel.getGroupDisplayColumns().forEach(i=>{const r=i.getColDef().showRowGroup;if("string"!=typeof r)return void console.error("AG Grid: groupHideOpenParents only works when specifying specific columns for colDef.showRowGroup");const n=r,s=this.columnModel.getPrimaryColumn(n);if(s!==e.rowGroupColumn)if(t)e.setGroupValue(i.getId(),void 0);else{const t=e.getFirstChildOfFirstChild(s);t&&e.setGroupValue(i.getId(),t.key)}})})}};g([ue("columnModel")],Xu.prototype,"columnModel",2),g([ue("rowNodeSorter")],Xu.prototype,"rowNodeSorter",2),Xu=g([ce("sortService")],Xu);var Zu=class extends rt{filter(e){const t=this.filterManager.isChildFilterPresent();this.filterNodes(t,e)}filterNodes(e,t){const i=(t,i)=>{t.hasChildren()?t.childrenAfterFilter=e&&!i?t.childrenAfterGroup.filter(e=>{const t=e.childrenAfterFilter&&e.childrenAfterFilter.length>0,i=e.data&&this.filterManager.doesRowPassFilter({rowNode:e});return t||i}):t.childrenAfterGroup:t.childrenAfterFilter=t.childrenAfterGroup,t.sibling&&(t.sibling.childrenAfterFilter=t.childrenAfterFilter)};if(this.doingTreeDataFiltering()){const e=(t,r)=>{if(t.childrenAfterGroup)for(let n=0;n<t.childrenAfterGroup.length;n++){const s=t.childrenAfterGroup[n],o=r||this.filterManager.doesRowPassFilter({rowNode:s});s.childrenAfterGroup?e(t.childrenAfterGroup[n],o):i(s,o)}i(t,r)},r=t=>e(t,!1);t.executeFromRootNode(r)}else{const e=e=>i(e,!1);t.forEachChangedNodeDepthFirst(e,!0)}}doingTreeDataFiltering(){return this.gos.get("treeData")&&!this.gos.get("excludeChildrenWhenTreeDataFiltering")}};g([ue("filterManager")],Zu.prototype,"filterManager",2),Zu=g([ce("filterService")],Zu);var Ju=class extends rt{postConstruct(){"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel,this.addManagedPropertyListener("rowData",()=>this.onRowDataUpdated()))}isActive(){const e=this.gos.exists("getRowId");return!this.gos.get("resetRowDataOnUpdate")&&e}setRowData(e){const t=this.createTransactionForRowData(e);if(!t)return;const[i,r]=t;this.clientSideRowModel.updateRowData(i,r)}createTransactionForRowData(e){if(ln.missing(this.clientSideRowModel))return void console.error("AG Grid: ImmutableService only works with ClientSideRowModel");const t=this.gos.getCallback("getRowId");if(null==t)return void console.error("AG Grid: ImmutableService requires getRowId() callback to be implemented, your row data needs IDs!");const i={remove:[],update:[],add:[]},r=this.clientSideRowModel.getCopyOfNodesMap(),n=this.gos.get("suppressMaintainUnsortedOrder")?void 0:{};return ln.exists(e)&&e.forEach((e,s)=>{const o=t({data:e,level:0}),a=r[o];n&&(n[o]=s),a?(a.data!==e&&i.update.push(e),r[o]=void 0):i.add.push(e)}),ln.iterateObject(r,(e,t)=>{t&&i.remove.push(t.data)}),[i,n]}onRowDataUpdated(){const e=this.gos.get("rowData");e&&(this.isActive()?this.setRowData(e):(this.selectionService.reset("rowDataChanged"),this.clientSideRowModel.setRowData(e)))}};g([ue("rowModel")],Ju.prototype,"rowModel",2),g([ue("rowRenderer")],Ju.prototype,"rowRenderer",2),g([ue("selectionService")],Ju.prototype,"selectionService",2),g([ae],Ju.prototype,"postConstruct",1);var eh={version:"31.3.4",moduleName:"@ag-grid-community/client-side-row-model",rowModel:"clientSide",beans:[$u,qu,Yu,Qu,Xu,Zu,Ju=g([ce("immutableService")],Ju)]},th=Object.defineProperty,ih=Object.getOwnPropertyDescriptor,rh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?ih(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&th(t,i,s),s},nh=class extends Vl{constructor(e,t,i){super(e),this.parentCache=t,this.params=i,this.startRow=e*i.blockSize,this.endRow=this.startRow+i.blockSize}postConstruct(){this.createRowNodes()}getBlockStateJson(){return{id:""+this.getId(),state:{blockNumber:this.getId(),startRow:this.getStartRow(),endRow:this.getEndRow(),pageStatus:this.getState()}}}setDataAndId(e,t,i){ln.exists(t)?e.setDataAndId(t,i.toString()):e.setDataAndId(void 0,void 0)}loadFromDatasource(){const e=this.createLoadParams();ln.missing(this.params.datasource.getRows)?console.warn("AG Grid: datasource is missing getRows method"):window.setTimeout(()=>{this.params.datasource.getRows(e)},0)}processServerFail(){}createLoadParams(){return{startRow:this.getStartRow(),endRow:this.getEndRow(),successCallback:this.pageLoaded.bind(this,this.getVersion()),failCallback:this.pageLoadFailed.bind(this,this.getVersion()),sortModel:this.params.sortModel,filterModel:this.params.filterModel,context:this.gos.getGridCommonParams().context}}forEachNode(e,t,i){this.rowNodes.forEach((r,n)=>{this.startRow+n<i&&e(r,t.next())})}getLastAccessed(){return this.lastAccessed}getRow(e,t=!1){t||(this.lastAccessed=this.params.lastAccessedSequence.next());const i=e-this.startRow;return this.rowNodes[i]}getStartRow(){return this.startRow}getEndRow(){return this.endRow}createRowNodes(){this.rowNodes=[];for(let e=0;e<this.params.blockSize;e++){const t=this.startRow+e,i=new Ls(this.beans);i.setRowHeight(this.params.rowHeight),i.uiLevel=0,i.setRowIndex(t),i.setRowTop(this.params.rowHeight*t),this.rowNodes.push(i)}}processServerResult(e){this.rowNodes.forEach((t,i)=>{const r=e.rowData?e.rowData[i]:void 0;!t.id&&t.alreadyRendered&&r&&(this.rowNodes[i]=new Ls(this.beans),this.rowNodes[i].setRowIndex(t.rowIndex),this.rowNodes[i].setRowTop(t.rowTop),this.rowNodes[i].setRowHeight(t.rowHeight),t.clearRowTopAndRowIndex()),this.setDataAndId(this.rowNodes[i],r,this.startRow+i)});const t=null!=e.rowCount&&e.rowCount>=0?e.rowCount:void 0;this.parentCache.pageLoaded(this,t)}destroyRowNodes(){this.rowNodes.forEach(e=>{e.clearRowTopAndRowIndex()})}};rh([ue("beans")],nh.prototype,"beans",2),rh([ae],nh.prototype,"postConstruct",1),rh([le],nh.prototype,"destroyRowNodes",1);var sh,oh=class e extends rt{constructor(e){super(),this.lastRowIndexKnown=!1,this.blocks={},this.blockCount=0,this.rowCount=e.initialRowCount,this.params=e}setBeans(e){this.logger=e.create("InfiniteCache")}getRow(e,t=!1){const i=Math.floor(e/this.params.blockSize);let r=this.blocks[i];if(!r){if(t)return;r=this.createBlock(i)}return r.getRow(e)}createBlock(e){const t=this.createBean(new nh(e,this,this.params));return this.blocks[t.getId()]=t,this.blockCount++,this.purgeBlocksIfNeeded(t),this.params.rowNodeBlockLoader.addBlock(t),t}refreshCache(){0==this.blockCount?this.purgeCache():(this.getBlocksInOrder().forEach(e=>e.setStateWaitingToLoad()),this.params.rowNodeBlockLoader.checkBlockToLoad())}destroyAllBlocks(){this.getBlocksInOrder().forEach(e=>this.destroyBlock(e))}getRowCount(){return this.rowCount}isLastRowIndexKnown(){return this.lastRowIndexKnown}pageLoaded(e,t){this.isAlive()&&(this.logger.log(`onPageLoaded: page = ${e.getId()}, lastRow = ${t}`),this.checkRowCount(e,t),this.onCacheUpdated())}purgeBlocksIfNeeded(t){const i=this.getBlocksInOrder().filter(e=>e!=t);i.sort((e,t)=>t.getLastAccessed()-e.getLastAccessed());const r=this.params.maxBlocksInCache>0,n=r?this.params.maxBlocksInCache-1:null,s=e.MAX_EMPTY_BLOCKS_TO_KEEP-1;i.forEach((e,t)=>{if(e.getState()===nh.STATE_WAITING_TO_LOAD&&t>=s||r&&t>=n){if(this.isBlockCurrentlyDisplayed(e))return;if(this.isBlockFocused(e))return;this.removeBlockFromCache(e)}})}isBlockFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();if(!t)return!1;if(null!=t.rowPinned)return!1;const i=e.getStartRow(),r=e.getEndRow();return t.rowIndex>=i&&t.rowIndex<r}isBlockCurrentlyDisplayed(e){const t=e.getStartRow(),i=e.getEndRow()-1;return this.rowRenderer.isRangeInRenderedViewport(t,i)}removeBlockFromCache(e){e&&this.destroyBlock(e)}checkRowCount(e,t){if("number"==typeof t&&t>=0)this.rowCount=t,this.lastRowIndexKnown=!0;else if(!this.lastRowIndexKnown){const t=(e.getId()+1)*this.params.blockSize+this.params.overflowSize;this.rowCount<t&&(this.rowCount=t)}}setRowCount(e,t){this.rowCount=e,ln.exists(t)&&(this.lastRowIndexKnown=t),this.lastRowIndexKnown||this.rowCount%this.params.blockSize===0&&this.rowCount++,this.onCacheUpdated()}forEachNodeDeep(e){const t=new cn;this.getBlocksInOrder().forEach(i=>i.forEachNode(e,t,this.rowCount))}getBlocksInOrder(){return ln.getAllValuesInObject(this.blocks).sort((e,t)=>e.getId()-t.getId())}destroyBlock(e){delete this.blocks[e.getId()],this.destroyBean(e),this.blockCount--,this.params.rowNodeBlockLoader.removeBlock(e)}onCacheUpdated(){if(this.isAlive()){this.destroyAllBlocksPastVirtualRowCount();const e={type:lt.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}}destroyAllBlocksPastVirtualRowCount(){const e=[];this.getBlocksInOrder().forEach(t=>{t.getId()*this.params.blockSize>=this.rowCount&&e.push(t)}),e.length>0&&e.forEach(e=>this.destroyBlock(e))}purgeCache(){this.getBlocksInOrder().forEach(e=>this.removeBlockFromCache(e)),this.lastRowIndexKnown=!1,0===this.rowCount&&(this.rowCount=this.params.initialRowCount),this.onCacheUpdated()}getRowNodesInRange(e,t){const i=[];let r=-1,n=!1;const s=new cn;ln.missing(e)&&(n=!0);let o=!1;return this.getBlocksInOrder().forEach(a=>{o||(n&&r+1!==a.getId()?o=!0:(r=a.getId(),a.forEachNode(r=>{const s=r===e||r===t;(n||s)&&i.push(r),s&&(n=!n)},s,this.rowCount)))}),o||n?[]:i}};oh.MAX_EMPTY_BLOCKS_TO_KEEP=2,rh([ue("rowRenderer")],oh.prototype,"rowRenderer",2),rh([ue("focusService")],oh.prototype,"focusService",2),rh([(sh=pe("loggerFactory"),(e,t)=>sh(e,t,0))],oh.prototype,"setBeans",1),rh([le],oh.prototype,"destroyAllBlocks",1);var ah=oh,lh=class extends rt{getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}ensureRowHeightsValid(e,t,i,r){return!1}init(){this.gos.isRowModelType("infinite")&&(this.rowHeight=this.gos.getRowHeightAsNumber(),this.addEventListeners(),this.addDestroyFunc(()=>this.destroyCache()),this.verifyProps())}verifyProps(){this.gos.exists("initialGroupOrderComparator")&&ln.warnOnce("initialGroupOrderComparator cannot be used with Infinite Row Model as sorting is done on the server side")}start(){this.setDatasource(this.gos.get("datasource"))}destroyDatasource(){this.datasource&&(this.getContext().destroyBean(this.datasource),this.rowRenderer.datasourceChanged(),this.datasource=null)}addEventListeners(){this.addManagedListener(this.eventService,lt.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_SORT_CHANGED,this.onSortChanged.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverything.bind(this)),this.addManagedListener(this.eventService,lt.EVENT_STORE_UPDATED,this.onCacheUpdated.bind(this)),this.addManagedPropertyListener("datasource",()=>this.setDatasource(this.gos.get("datasource"))),this.addManagedPropertyListener("cacheBlockSize",()=>this.resetCache()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=this.gos.getRowHeightAsNumber(),this.cacheParams.rowHeight=this.rowHeight,this.updateRowHeights()})}onFilterChanged(){this.reset()}onSortChanged(){this.reset()}onColumnEverything(){let e;e=!this.cacheParams||this.isSortModelDifferent(),e&&this.reset()}isSortModelDifferent(){return!ln.jsonEquals(this.cacheParams.sortModel,this.sortController.getSortModel())}getType(){return"infinite"}setDatasource(e){this.destroyDatasource(),this.datasource=e,e&&this.reset()}isEmpty(){return!this.infiniteCache}isRowsToRender(){return!!this.infiniteCache}getNodesInRangeForSelection(e,t){return this.infiniteCache?this.infiniteCache.getRowNodesInRange(e,t):[]}reset(){this.datasource&&(null!=this.gos.getCallback("getRowId")||this.selectionService.reset("rowDataChanged"),this.resetCache())}createModelUpdatedEvent(){return{type:lt.EVENT_MODEL_UPDATED,newPage:!1,newPageSize:!1,newData:!1,keepRenderedRows:!0,animate:!1}}resetCache(){this.destroyCache(),this.cacheParams={datasource:this.datasource,filterModel:this.filterManager.getFilterModel(),sortModel:this.sortController.getSortModel(),rowNodeBlockLoader:this.rowNodeBlockLoader,initialRowCount:this.gos.get("infiniteInitialRowCount"),maxBlocksInCache:this.gos.get("maxBlocksInCache"),rowHeight:this.gos.getRowHeightAsNumber(),overflowSize:this.gos.get("cacheOverflowSize"),blockSize:this.gos.get("cacheBlockSize"),lastAccessedSequence:new cn},this.infiniteCache=this.createBean(new ah(this.cacheParams)),this.eventService.dispatchEventOnce({type:lt.EVENT_ROW_COUNT_READY});const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)});const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}destroyCache(){this.infiniteCache&&(this.infiniteCache=this.destroyBean(this.infiniteCache))}onCacheUpdated(){const e=this.createModelUpdatedEvent();this.eventService.dispatchEvent(e)}getRow(e){if(this.infiniteCache&&!(e>=this.infiniteCache.getRowCount()))return this.infiniteCache.getRow(e)}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}forEachNode(e){this.infiniteCache&&this.infiniteCache.forEachNodeDeep(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}getRowIndexAtPixel(e){if(0!==this.rowHeight){const t=Math.floor(e/this.rowHeight),i=this.getRowCount()-1;return t>i?i:t}return 0}getRowCount(){return this.infiniteCache?this.infiniteCache.getRowCount():0}isRowPresent(e){return!!this.getRowNode(e.id)}refreshCache(){this.infiniteCache&&this.infiniteCache.refreshCache()}purgeCache(){this.infiniteCache&&this.infiniteCache.purgeCache()}isLastRowIndexKnown(){return!!this.infiniteCache&&this.infiniteCache.isLastRowIndexKnown()}setRowCount(e,t){this.infiniteCache&&this.infiniteCache.setRowCount(e,t)}};rh([ue("filterManager")],lh.prototype,"filterManager",2),rh([ue("sortController")],lh.prototype,"sortController",2),rh([ue("selectionService")],lh.prototype,"selectionService",2),rh([ue("rowRenderer")],lh.prototype,"rowRenderer",2),rh([ue("rowNodeBlockLoader")],lh.prototype,"rowNodeBlockLoader",2),rh([ae],lh.prototype,"init",1),rh([le],lh.prototype,"destroyDatasource",1);var ch={version:"31.3.4",moduleName:"@ag-grid-community/infinite-row-model",rowModel:"infinite",beans:[lh=rh([ce("rowModel")],lh)]},uh=Object.defineProperty,hh=Object.defineProperties,dh=Object.getOwnPropertyDescriptor,ph=Object.getOwnPropertyDescriptors,gh=Object.getOwnPropertySymbols,fh=Object.prototype.hasOwnProperty,mh=Object.prototype.propertyIsEnumerable,vh=(e,t,i)=>t in e?uh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Ch=(e,t)=>{for(var i in t||(t={}))fh.call(t,i)&&vh(e,i,t[i]);if(gh)for(var i of gh(t))mh.call(t,i)&&vh(e,i,t[i]);return e},yh=(e,t)=>hh(e,ph(t)),wh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?dh(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&uh(t,i,s),s},Sh=(e,t,i)=>new Promise((r,n)=>{var s=e=>{try{a(i.next(e))}catch(e){n(e)}},o=e=>{try{a(i.throw(e))}catch(e){n(e)}},a=e=>e.done?r(e.value):Promise.resolve(e.value).then(s,o);a((i=i.apply(e,t)).next())}),bh=class{setBeans(e){this.beans=e}getFileName(e){const t=this.getDefaultFileExtension();return null!=e&&e.length||(e=this.getDefaultFileName()),-1===e.indexOf(".")?`${e}.${t}`:e}getData(e){const t=this.createSerializingSession(e);return this.beans.gridSerializer.serialize(t,e)}getDefaultFileName(){return`export.${this.getDefaultFileExtension()}`}},Eh=class{constructor(e){this.groupColumns=[];const{columnModel:t,valueService:i,gos:r,processCellCallback:n,processHeaderCallback:s,processGroupHeaderCallback:o,processRowGroupCallback:a}=e;this.columnModel=t,this.valueService=i,this.gos=r,this.processCellCallback=n,this.processHeaderCallback=s,this.processGroupHeaderCallback=o,this.processRowGroupCallback=a}prepare(e){this.groupColumns=e.filter(e=>!!e.getColDef().showRowGroup)}extractHeaderValue(e){const t=this.getHeaderName(this.processHeaderCallback,e);return null!=t?t:""}extractRowCellValue(e,t,i,r,n){const s=this.gos.get("groupHideOpenParents")&&!n.footer||!this.shouldRenderGroupSummaryCell(n,e,t)?this.valueService.getValue(e,n):this.createValueForGroupNode(e,n);return this.processCell({accumulatedRowIndex:i,rowNode:n,column:e,value:s,processCellCallback:this.processCellCallback,type:r})}shouldRenderGroupSummaryCell(e,t,i){var r;if(!e||!e.group)return!1;if(-1!==this.groupColumns.indexOf(t)){if(null!=(null==(r=e.groupData)?void 0:r[t.getId()]))return!0;if(this.gos.isRowModelType("serverSide")&&e.group)return!0;if(e.footer&&-1===e.level){const e=t.getColDef();return null==e||!0===e.showRowGroup||e.showRowGroup===this.columnModel.getRowGroupColumns()[0].getId()}}const n=this.gos.isGroupUseEntireRow(this.columnModel.isPivotMode());return 0===i&&n}getHeaderName(e,t){return e?e(this.gos.addGridCommonParams({column:t})):this.columnModel.getDisplayNameForColumn(t,"csv",!0)}createValueForGroupNode(e,t){if(this.processRowGroupCallback)return this.processRowGroupCallback(this.gos.addGridCommonParams({column:e,node:t}));const i=this.gos.get("treeData"),r=this.gos.get("suppressGroupMaintainValueType"),n=t=>{var n,s;if(i||r)return t.key;const o=null==(n=t.groupData)?void 0:n[e.getId()];return o&&t.rowGroupColumn&&!1!==t.rowGroupColumn.getColDef().useValueFormatterForExport&&null!=(s=this.valueService.formatValue(t.rowGroupColumn,t,o))?s:o},s=t.footer,o=[n(t)];if(!this.gos.isGroupMultiAutoColumn())for(;t.parent;)t=t.parent,o.push(n(t));const a=o.reverse().join(" -> ");return s?`Total ${a}`:a}processCell(e){var t;const{accumulatedRowIndex:i,rowNode:r,column:n,value:s,processCellCallback:o,type:a}=e;return o?{value:null!=(t=o(this.gos.addGridCommonParams({accumulatedRowIndex:i,column:n,node:r,value:s,type:a,parseValue:e=>this.valueService.parseValue(n,r,e,this.valueService.getValue(n,r)),formatValue:e=>{var t;return null!=(t=this.valueService.formatValue(n,r,e))?t:e}})))?t:""}:!1!==n.getColDef().useValueFormatterForExport?{value:null!=s?s:"",valueFormatted:this.valueService.formatValue(n,r,s)}:{value:null!=s?s:""}}},Ah=class{static download(e,t){const i=document.defaultView||window;if(!i)return void console.warn("AG Grid: There is no `window` associated with the current `document`");const r=document.createElement("a"),n=i.URL.createObjectURL(t);r.setAttribute("href",n),r.setAttribute("download",e),r.style.display="none",document.body.appendChild(r),r.dispatchEvent(new MouseEvent("click",{bubbles:!1,cancelable:!0,view:i})),document.body.removeChild(r),i.setTimeout(()=>{i.URL.revokeObjectURL(n)},0)}},Th=class extends Eh{constructor(e){super(e),this.isFirstLine=!0,this.result="";const{suppressQuotes:t,columnSeparator:i}=e;this.suppressQuotes=t,this.columnSeparator=i}addCustomContent(e){e&&("string"==typeof e?(/^\s*\n/.test(e)||this.beginNewLine(),e=e.replace(/\r?\n/g,"\r\n"),this.result+=e):e.forEach(e=>{this.beginNewLine(),e.forEach((e,t)=>{0!==t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(e.data.value||""),e.mergeAcross&&this.appendEmptyCells(e.mergeAcross)})}))}onNewHeaderGroupingRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderGroupingRowColumn.bind(this)}}onNewHeaderGroupingRowColumn(e,t,i,r){0!=i&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(t),this.appendEmptyCells(r)}appendEmptyCells(e){for(let t=1;t<=e;t++)this.result+=this.columnSeparator+this.putInQuotes("")}onNewHeaderRow(){return this.beginNewLine(),{onColumn:this.onNewHeaderRowColumn.bind(this)}}onNewHeaderRowColumn(e,t){0!=t&&(this.result+=this.columnSeparator),this.result+=this.putInQuotes(this.extractHeaderValue(e))}onNewBodyRow(){return this.beginNewLine(),{onColumn:this.onNewBodyRowColumn.bind(this)}}onNewBodyRowColumn(e,t,i){var r;0!=t&&(this.result+=this.columnSeparator);const n=this.extractRowCellValue(e,t,t,"csv",i);this.result+=this.putInQuotes(null!=(r=n.valueFormatted)?r:n.value)}putInQuotes(e){if(this.suppressQuotes)return e;if(null==e)return'""';let t;return"string"==typeof e?t=e:"function"==typeof e.toString?t=e.toString():(console.warn("AG Grid: unknown value type during csv conversion"),t=""),'"'+t.replace(/"/g,'""')+'"'}parse(){return this.result}beginNewLine(){this.isFirstLine||(this.result+="\r\n"),this.isFirstLine=!1}},Mh=class extends bh{postConstruct(){this.setBeans({gridSerializer:this.gridSerializer,gos:this.gos})}getMergedParams(e){const t=this.gos.get("defaultCsvExportParams");return Object.assign({},t,e)}export(e){if(this.isExportSuppressed())return void console.warn("AG Grid: Export cancelled. Export is not allowed as per your configuration.");const t=this.getMergedParams(e),i=this.getData(t),r=new Blob(["\ufeff",i],{type:"text/plain"}),n="function"==typeof t.fileName?t.fileName(this.gos.getGridCommonParams()):t.fileName;Ah.download(this.getFileName(n),r)}exportDataAsCsv(e){this.export(e)}getDataAsCsv(e,t=!1){const i=t?Object.assign({},e):this.getMergedParams(e);return this.getData(i)}getDefaultFileExtension(){return"csv"}createSerializingSession(e){const{columnModel:t,valueService:i,gos:r}=this,{processCellCallback:n,processHeaderCallback:s,processGroupHeaderCallback:o,processRowGroupCallback:a,suppressQuotes:l,columnSeparator:c}=e;return new Th({columnModel:t,valueService:i,gos:r,processCellCallback:n||void 0,processHeaderCallback:s||void 0,processGroupHeaderCallback:o||void 0,processRowGroupCallback:a||void 0,suppressQuotes:l||!1,columnSeparator:c||","})}isExportSuppressed(){return this.gos.get("suppressCsvExport")}};wh([ue("columnModel")],Mh.prototype,"columnModel",2),wh([ue("valueService")],Mh.prototype,"valueService",2),wh([ue("gridSerializer")],Mh.prototype,"gridSerializer",2),wh([ue("gridOptionsService")],Mh.prototype,"gos",2),wh([ae],Mh.prototype,"postConstruct",1),Mh=wh([ce("csvCreator")],Mh);var Rh=(e=>(e[e.HEADER_GROUPING=0]="HEADER_GROUPING",e[e.HEADER=1]="HEADER",e[e.BODY=2]="BODY",e))(Rh||{}),_h=class extends rt{serialize(e,t={}){const{allColumns:i,columnKeys:r,skipRowGroups:n}=t,s=this.getColumnsToExport(i,n,r);return ln.compose(this.prepareSession(s),this.prependContent(t),this.exportColumnGroups(t,s),this.exportHeaders(t,s),this.processPinnedTopRows(t,s),this.processRows(t,s),this.processPinnedBottomRows(t,s),this.appendContent(t))(e).parse()}processRow(e,t,i,r){const n=t.shouldRowBeSkipped||(()=>!1),s=this.gos.get("groupRemoveSingleChildren"),o=this.gos.get("groupRemoveLowestSingleChildren"),a=null!=t.rowPositions||!!t.onlySelected,l=this.gos.get("groupHideOpenParents")&&!a,c=this.columnModel.isPivotMode()?r.leafGroup:!r.group,u=!!r.footer,h=(t.skipRowGroups,o&&r.leafGroup),d=1===r.allChildrenCount&&(s||h);if(!c&&!u&&(t.skipRowGroups||d||l)||t.onlySelected&&!r.isSelected()||t.skipPinnedTop&&"top"===r.rowPinned||t.skipPinnedBottom&&"bottom"===r.rowPinned)return;if(-1===r.level&&!c&&!u)return;if(n(this.gos.addGridCommonParams({node:r})))return;const p=e.onNewBodyRow(r);if(i.forEach((e,t)=>{p.onColumn(e,t,r)}),t.getCustomContentBelowRow){const i=t.getCustomContentBelowRow(this.gos.addGridCommonParams({node:r}));i&&e.addCustomContent(i)}}appendContent(e){return t=>{const i=e.appendContent;return i&&t.addCustomContent(i),t}}prependContent(e){return t=>{const i=e.prependContent;return i&&t.addCustomContent(i),t}}prepareSession(e){return t=>(t.prepare(e),t)}exportColumnGroups(e,t){return i=>{if(!e.skipColumnGroupHeaders){const r=new ut,n=this.displayedGroupCreator.createDisplayedGroups(t,r,null);this.recursivelyAddHeaderGroups(n,i,e.processGroupHeaderCallback)}return i}}exportHeaders(e,t){return i=>{if(!e.skipColumnHeaders){const e=i.onNewHeaderRow();t.forEach((t,i)=>{e.onColumn(t,i,void 0)})}return i}}processPinnedTopRows(e,t){return i=>{const r=this.processRow.bind(this,i,e,t);return e.rowPositions?e.rowPositions.filter(e=>"top"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel.getPinnedTopRow(e.rowIndex)).forEach(r):this.pinnedRowModel.forEachPinnedTopRow(r),i}}processRows(e,t){return i=>{const r=this.rowModel,n=r.getType(),s="clientSide"===n,o="serverSide"===n,a=!s&&e.onlySelected,l=this.processRow.bind(this,i,e,t),{exportedRows:c="filteredAndSorted"}=e;if(e.rowPositions)e.rowPositions.filter(e=>null==e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>r.getRow(e.rowIndex)).forEach(l);else if(this.columnModel.isPivotMode())s?r.forEachPivotNode(l,!0):o?r.forEachNodeAfterFilterAndSort(l,!0):r.forEachNode(l);else if(e.onlySelectedAllPages||a){const e=this.selectionService.getSelectedNodes();this.replicateSortedOrder(e),e.forEach(l)}else"all"===c?r.forEachNode(l):s||o?r.forEachNodeAfterFilterAndSort(l,!0):r.forEachNode(l);return i}}replicateSortedOrder(e){const t=this.sortController.getSortOptions(),i=(e,r)=>{var n,s,o,a;return null!=e.rowIndex&&null!=r.rowIndex?e.rowIndex-r.rowIndex:e.level===r.level?(null==(n=e.parent)?void 0:n.id)===(null==(s=r.parent)?void 0:s.id)?this.rowNodeSorter.compareRowNodes(t,{rowNode:e,currentPos:null!=(o=e.rowIndex)?o:-1},{rowNode:r,currentPos:null!=(a=r.rowIndex)?a:-1}):i(e.parent,r.parent):e.level>r.level?i(e.parent,r):i(e,r.parent)};e.sort(i)}processPinnedBottomRows(e,t){return i=>{const r=this.processRow.bind(this,i,e,t);return e.rowPositions?e.rowPositions.filter(e=>"bottom"===e.rowPinned).sort((e,t)=>e.rowIndex-t.rowIndex).map(e=>this.pinnedRowModel.getPinnedBottomRow(e.rowIndex)).forEach(r):this.pinnedRowModel.forEachPinnedBottomRow(r),i}}getColumnsToExport(e=!1,t=!1,i){const r=this.columnModel.isPivotMode();if(i&&i.length)return this.columnModel.getGridColumns(i);const n=this.gos.get("treeData");let s=[];return s=e&&!r?this.columnModel.getAllGridColumns():this.columnModel.getAllDisplayedColumns(),t&&!n&&(s=s.filter(e=>e.getColId()!==ht)),s}recursivelyAddHeaderGroups(e,t,i){const r=[];e.forEach(e=>{const t=e;t.getChildren&&t.getChildren().forEach(e=>r.push(e))}),e.length>0&&e[0]instanceof at&&this.doAddHeaderHeader(t,e,i),r&&r.length>0&&this.recursivelyAddHeaderGroups(r,t,i)}doAddHeaderHeader(e,t,i){const r=e.onNewHeaderGroupingRow();let n=0;t.forEach(e=>{const t=e;let s;s=i?i(this.gos.addGridCommonParams({columnGroup:t})):this.columnModel.getDisplayNameForColumnGroup(t,"header");const o=t.getLeafColumns().reduce((e,t,i,r)=>{let n=ln.last(e);return"open"===t.getColumnGroupShow()?n&&null==n[1]||(n=[i],e.push(n)):n&&null==n[1]&&(n[1]=i-1),i===r.length-1&&n&&null==n[1]&&(n[1]=i),e},[]);r.onColumn(t,s||"",n++,t.getLeafColumns().length-1,o)})}};wh([ue("displayedGroupCreator")],_h.prototype,"displayedGroupCreator",2),wh([ue("columnModel")],_h.prototype,"columnModel",2),wh([ue("rowModel")],_h.prototype,"rowModel",2),wh([ue("pinnedRowModel")],_h.prototype,"pinnedRowModel",2),wh([ue("selectionService")],_h.prototype,"selectionService",2),wh([ue("rowNodeSorter")],_h.prototype,"rowNodeSorter",2),wh([ue("sortController")],_h.prototype,"sortController",2),_h=wh([ce("gridSerializer")],_h);var Ph={version:"31.3.4",moduleName:"@ag-grid-community/csv-export",beans:[Mh,_h]},xh="\r\n",Dh=class{static createHeader(e={}){const t=["version"];return e.version||(e.version="1.0"),e.encoding&&t.push("encoding"),e.standalone&&t.push("standalone"),`<?xml ${t.map(t=>`${t}="${e[t]}"`).join(" ")} ?>`}static createXml(e,t){let i="";e.properties&&(e.properties.prefixedAttributes&&e.properties.prefixedAttributes.forEach(e=>{Object.keys(e.map).forEach(r=>{i+=this.returnAttributeIfPopulated(e.prefix+r,e.map[r],t)})}),e.properties.rawMap&&Object.keys(e.properties.rawMap).forEach(r=>{i+=this.returnAttributeIfPopulated(r,e.properties.rawMap[r],t)}));let r="<"+e.name+i;return e.children||null!=e.textNode?null!=e.textNode?r+">"+e.textNode+"</"+e.name+">"+xh:(r+=">\r\n",e.children&&e.children.forEach(e=>{r+=this.createXml(e,t)}),r+"</"+e.name+">"+xh):r+"/>"+xh}static returnAttributeIfPopulated(e,t,i){if(!t&&""!==t&&0!==t)return"";let r=t;return"boolean"==typeof t&&i&&(r=i(t)),` ${e}="${r}"`}};function Ih(e,t){let i="";for(let r=0;r<t;r++)i+=String.fromCharCode(255&e),e>>>=8;return i}var Lh=e=>e.length?(e=>{if(!e.length)return 0;let t=-1,i=0,r=0,n=0;for(let s=0;s<e.length;s++)i=e[s],r=255&(t^i),n=Nh[r],t=t>>>8^n;return-1^t})("string"==typeof e?(new TextEncoder).encode(e):e):0,Nh=new Uint32Array([0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918e3,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117]),{utf8_encode:Oh}=ln,Fh=(e,t)=>Sh(void 0,null,function*(){const{content:i}=e,{size:r,content:n}=i?Vh(i):{size:0,content:Uint8Array.from([])};let s,o,a=!1;if("file"===e.type&&n&&r>0){const e=yield(e=>Sh(void 0,null,function*(){const t=new Blob([e]),{size:i,content:r}=yield(n=t,Sh(void 0,null,function*(){let e=0;const t=[],i=new WritableStream({write:i=>{t.push(i),e+=i.length}}),r=new ReadableStream({start:e=>{const t=new FileReader;t.onload=t=>{var i;(null==(i=t.target)?void 0:i.result)&&e.enqueue(t.target.result),e.close()},t.readAsArrayBuffer(n)}}),s=new window.CompressionStream("deflate-raw");return yield r.pipeThrough(s).pipeTo(i),{size:e,content:new Blob(t)}}));var n;return{size:i,content:new Uint8Array(yield r.arrayBuffer())}}))(n);s=e.content,o=e.size,a=!0}const l=Gh(e,a,t,r,n,o);return yh(Ch({},l),{content:s||n,isCompressed:a})}),kh=(e,t)=>{const{content:i}=e,{content:r}=i?Vh(i):{content:Uint8Array.from([])},n=Gh(e,!1,t,r.length,r,void 0);return yh(Ch({},n),{content:r,isCompressed:!1})},Gh=(e,t,i,r,n,s)=>{const{content:o,path:a,created:l}=e,c=(e=>{let t=e.getHours();return t<<=6,t|=e.getMinutes(),t<<=5,t|=e.getSeconds()/2,t})(l),u=(e=>{let t=e.getFullYear()-1980;return t<<=4,t|=e.getMonth()+1,t<<=5,t|=e.getDate(),t})(l),h=Lh(n),d=void 0!==s?s:r,p=Oh(a),g=p!==a;let f="";if(g){const e=Ih(1,1)+Ih(Lh(p),4)+p;f="up"+Ih(e.length,2)+e}const m="\0"+(g?"\0\b":"\0\0")+Ih(t?8:0,2)+Ih(c,2)+Ih(u,2)+Ih(d?h:0,4)+Ih(null!=s?s:r,4)+Ih(r,4)+Ih(p.length,2)+Ih(f.length,2),v="PK"+m+p+f,C="PK\0"+m+"\0\0\0\0\0\0"+(o?"\0\0\0\0":"\0\0\0")+Ih(i,4)+p+f;return{localFileHeader:Uint8Array.from(v,e=>e.charCodeAt(0)),centralDirectoryHeader:Uint8Array.from(C,e=>e.charCodeAt(0))}},Vh=e=>{let t;return t="string"==typeof e?(e=>{const t=new Uint8Array(e.length);for(let i=0;i<e.length;i++)t[i]=e.charCodeAt(i);return t})(atob(e.split(";base64,")[1])):e,{size:t.length,content:t}},Hh=class{static addFolders(e){e.forEach(this.addFolder.bind(this))}static addFolder(e){this.folders.push({path:e,created:new Date,isBase64:!1,type:"folder"})}static addFile(e,t,i=!1){this.files.push({path:e,created:new Date,content:i?t:(new TextEncoder).encode(t),isBase64:i,type:"file"})}static getZipFile(e="application/zip"){return Sh(this,null,function*(){const t=yield this.buildCompressedFileStream();return this.clearStream(),new Blob([t],{type:e})})}static getUncompressedZipFile(e="application/zip"){const t=this.buildFileStream();return this.clearStream(),new Blob([t],{type:e})}static clearStream(){this.folders=[],this.files=[]}static packageFiles(e){let t=new Uint8Array(0),i=new Uint8Array(0),r=0,n=0;for(const s of e){const{localFileHeader:e,centralDirectoryHeader:o,content:a}=s,l=new Uint8Array(t.length+e.length);l.set(t),l.set(e,t.length),t=l;const c=new Uint8Array(t.length+a.length);c.set(t),c.set(a,t.length),t=c;const u=new Uint8Array(i.length+o.length);u.set(i),u.set(o,i.length),i=u,r+=e.length+a.length,n+=o.length}const s=((e,t,i)=>{const r="PK\0\0\0\0"+Ih(e,2)+Ih(e,2)+Ih(t,4)+Ih(i,4)+"\0\0";return Uint8Array.from(r,e=>e.charCodeAt(0))})(e.length,n,r),o=new Uint8Array(t.length+i.length+s.length);return o.set(t),o.set(i,t.length),o.set(s,t.length+i.length),o}static buildCompressedFileStream(){return Sh(this,null,function*(){const e=[...this.folders,...this.files],t=[];let i=0;for(const r of e){const e=yield Fh(r,i),{localFileHeader:n,content:s}=e;t.push(e),i+=n.length+s.length}return this.packageFiles(t)})}static buildFileStream(){const e=[...this.folders,...this.files],t=[];let i=0;for(const r of e){const e=kh(r,i),{localFileHeader:n,content:s}=e;t.push(e),i+=n.length+s.length}return this.packageFiles(t)}};Hh.folders=[],Hh.files=[],ne.__registerModules([eh,ch,Ph],!1,void 0)},13581(e,t,i){"use strict";i.d(t,{hFV:()=>y});var r=i(54989),n=i(40682),s=Object.defineProperty,o=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,l=Object.prototype.hasOwnProperty,c=(e,t)=>{for(var i in t)s(e,i,{get:t[i],enumerable:!0})},u=(e,t,i,r)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let n of a(t))l.call(e,n)||n===i||s(e,n,{get:()=>t[n],enumerable:!(r=o(t,n))||r.enumerable});return e},h=(e,t,i)=>(u(e,t,"default"),i&&u(i,t,"default")),d=(e,t,i,r)=>{for(var n,a=r>1?void 0:r?o(t,i):t,l=e.length-1;l>=0;l--)(n=e[l])&&(a=(r?n(t,i,a):n(a))||a);return r&&a&&s(t,i,a),a},p={};c(p,{ALWAYS_SYNC_GLOBAL_EVENTS:()=>r.Yx9,AbstractHeaderCellCtrl:()=>r.$Y_,AdvancedFilterModule:()=>fe,AgAbstractField:()=>r.JWk,AgAbstractLabel:()=>r.DKR,AgAutocomplete:()=>r.bB5,AgCheckbox:()=>r.Unm,AgDialog:()=>r.fNJ,AgGroupComponent:()=>r.Pk_,AgInputDateField:()=>r.RYS,AgInputNumberField:()=>r.SpC,AgInputRange:()=>r.ycK,AgInputTextArea:()=>r.vXh,AgInputTextField:()=>r.stt,AgMenuItemComponent:()=>r.yuY,AgMenuItemRenderer:()=>r.Y0b,AgMenuList:()=>r.i9O,AgMenuPanel:()=>r.qkt,AgPanel:()=>r.LT8,AgPickerField:()=>r.HHt,AgPromise:()=>r.oY$,AgPromiseStatus:()=>r.SEh,AgRadioButton:()=>r.OQA,AgRichSelect:()=>r.pNP,AgSelect:()=>r.Ju4,AgSlider:()=>r.YD7,AgStackComponentsRegistry:()=>r.yOL,AgToggleButton:()=>r.bLJ,AlignedGridsService:()=>r.TYQ,AnimateShowChangeCellRenderer:()=>r.YEH,AnimateSlideCellRenderer:()=>r.kOq,AnimationFrameService:()=>r.hK9,AutoScrollService:()=>r.MSA,AutoWidthCalculator:()=>r.Qgm,Autowired:()=>r.dsm,BarColumnLabelPlacement:()=>r.fnn,BaseComponentWrapper:()=>r.Cf3,Bean:()=>r.dR4,BeanStub:()=>r.XQb,Beans:()=>r.MDK,BodyDropPivotTarget:()=>r.R4L,BodyDropTarget:()=>r.LFT,CellComp:()=>r.ehA,CellCtrl:()=>r.wX9,CellNavigationService:()=>r.aBp,CellPositionUtils:()=>r.HM$,CellRangeType:()=>r.OnL,ChangedPath:()=>r.k$d,ChartMappings:()=>r.E1g,CheckboxCellEditor:()=>r.j19,CheckboxCellRenderer:()=>r.tj3,CheckboxSelectionComponent:()=>r.TJD,ClientSideRowModelSteps:()=>r.zOQ,ClipboardModule:()=>Us,Column:()=>r.VPZ,ColumnApi:()=>r.jf3,ColumnFactory:()=>r.tbO,ColumnGroup:()=>r.ock,ColumnKeyCreator:()=>r.a1W,ColumnModel:()=>r.K02,ColumnsToolPanelModule:()=>Da,Component:()=>r.uAl,ComponentUtil:()=>r.kNx,Context:()=>r.obS,CssClassApplier:()=>r.PC7,CssClassManager:()=>r.hv8,CtrlsService:()=>r.GsR,DataTypeService:()=>r.gvq,DateCellEditor:()=>r.ofN,DateFilter:()=>r.ZvW,DateStringCellEditor:()=>r.tyx,DisplayedGroupCreator:()=>r.HDb,DragAndDropService:()=>r.WO_,DragService:()=>r.atK,DragSourceType:()=>r.qRA,EnterpriseCoreModule:()=>S,Environment:()=>r.OH$,EventService:()=>r.USV,Events:()=>r.sVA,ExcelExportModule:()=>_c,ExcelFactoryMode:()=>r.FiP,ExpansionService:()=>r.pkb,ExpressionService:()=>r.k4Y,FilterManager:()=>r.qh$,FilterWrapperComp:()=>r.jfj,FiltersToolPanelModule:()=>Kc,FloatingFilterMapper:()=>r.aq,FocusService:()=>r.c4$,GROUP_AUTO_COLUMN_ID:()=>r.JPk,Grid:()=>r.xA9,GridApi:()=>r.fAn,GridBodyComp:()=>r.IqQ,GridBodyCtrl:()=>r.m20,GridChartsModule:()=>Is,GridComp:()=>r.qdQ,GridCoreCreator:()=>r.Ug$,GridCtrl:()=>r.s1r,GridHeaderComp:()=>r.zCV,GridHeaderCtrl:()=>r.vBt,GridOptionsService:()=>r.E3M,GroupCellRenderer:()=>r.H_$,GroupCellRendererCtrl:()=>r.ihO,GroupInstanceIdCreator:()=>r.uf_,HeaderCellCtrl:()=>r.Lhl,HeaderFilterCellComp:()=>r.rdE,HeaderFilterCellCtrl:()=>r.HiW,HeaderGroupCellCtrl:()=>r.Kb3,HeaderNavigationDirection:()=>r.BFs,HeaderNavigationService:()=>r.Ry8,HeaderPositionUtils:()=>r.CS5,HeaderRowComp:()=>r.Hyp,HeaderRowContainerComp:()=>r.U3q,HeaderRowContainerCtrl:()=>r.OPU,HeaderRowCtrl:()=>r.fRK,HeaderRowType:()=>r.YtK,HorizontalDirection:()=>r.Iu8,HorizontalResizeService:()=>r.QBm,KeyCode:()=>r.DDm,LargeTextCellEditor:()=>r.GPp,LayoutCssClasses:()=>r.gay,LicenseManager:()=>y,LocaleService:()=>r.iH9,Logger:()=>r.VyI,LoggerFactory:()=>r.PLc,ManagedFocusFeature:()=>r.G21,MasterDetailModule:()=>ru,MenuModule:()=>Pu,MenuService:()=>r.$1h,ModuleNames:()=>r.zsj,ModuleRegistry:()=>r.syG,MouseEventService:()=>r.Rdv,MoveColumnFeature:()=>r.auO,MultiFilter:()=>zu,MultiFilterModule:()=>Wu,NavigationService:()=>r.o_p,NumberCellEditor:()=>r.dcM,NumberFilter:()=>r.yLQ,NumberSequence:()=>r.RI_,Optional:()=>r.Xx1,PaginationProxy:()=>r.TOO,PillDragComp:()=>r.v26,PillDropZonePanel:()=>r.fNO,PinnedRowModel:()=>r.aP4,PivotDropZonePanel:()=>Co,PopupComponent:()=>r.yGC,PopupEditorWrapper:()=>r.zmE,PopupService:()=>r.OQU,PositionableFeature:()=>r.qyQ,PostConstruct:()=>r.o7C,PreConstruct:()=>r.fK3,PreDestroy:()=>r.yah,PrimaryColsPanel:()=>Ca,PropertyKeys:()=>r.K42,ProvidedColumnGroup:()=>r.D45,ProvidedFilter:()=>r.Q5x,Qualifier:()=>r.Vf_,QuerySelector:()=>r.yLT,RangeSelectionModule:()=>Fe,RefSelector:()=>r.PIB,ResizeObserverService:()=>r.kem,RichSelectModule:()=>Ku,RowAnimationCssClasses:()=>r.IGk,RowContainerComp:()=>r.B_v,RowContainerCtrl:()=>r.Rlq,RowContainerName:()=>r.lon,RowContainerType:()=>r.uvO,RowCtrl:()=>r.CJG,RowGroupDropZonePanel:()=>vo,RowGroupingModule:()=>Ao,RowHighlightPosition:()=>r.m5s,RowNode:()=>r.TUE,RowNodeBlock:()=>r.iEP,RowNodeBlockLoader:()=>r.RRV,RowNodeSorter:()=>r.mE1,RowPositionUtils:()=>r.HLc,RowRenderer:()=>r.k7d,ScalarFilter:()=>r.TaT,ScrollVisibleService:()=>r.fVA,SelectCellEditor:()=>r.eAL,SelectableService:()=>r.K4S,SelectionHandleType:()=>r.LIk,ServerSideRowModelModule:()=>Eh,ServerSideTransactionResultStatus:()=>r.a8A,SetFilter:()=>Vh,SetFilterModule:()=>Wh,SetLeftFeature:()=>r.uij,SideBarModule:()=>qo,SimpleFilter:()=>r.PJL,SortController:()=>r.xSC,SortIndicatorComp:()=>r.pE7,SparklinesModule:()=>Xd,StandardMenuFactory:()=>r.Pmj,StatusBarModule:()=>cp,StylingService:()=>r.EJF,TabGuardClassNames:()=>r.pA9,TabGuardComp:()=>r.aJZ,TabGuardCtrl:()=>r.Udn,TabbedLayout:()=>r.LfH,TextCellEditor:()=>r.zIT,TextFilter:()=>r.U$F,TextFloatingFilter:()=>r.U_L,Timer:()=>r.M4G,ToolPanelColDefService:()=>Ko,TooltipFeature:()=>r.CvR,TooltipStateManager:()=>r.mSN,TouchListener:()=>r.MVO,UserComponentFactory:()=>r.xMA,UserComponentRegistry:()=>r.utH,ValueCache:()=>r.YHi,ValueService:()=>r.bBw,ValuesDropZonePanel:()=>To,VanillaFrameworkOverrides:()=>r.pow,VerticalDirection:()=>r.mqe,ViewportRowModelModule:()=>gp,VirtualList:()=>r.wjn,VirtualListDragFeature:()=>r.ia$,_:()=>r._,__FORCE_MODULE_DETECTION_AG_GRID_CORE_EXT:()=>Ls,agCharts:()=>Ns,createGrid:()=>r.Dvw,exportMultipleSheetsAsExcel:()=>Mc,getMultipleSheetsAsExcel:()=>Tc,getRowContainerTypeForName:()=>r.CSq,provideGlobalGridOptions:()=>r.Nat});var g=class{constructor(){this.ieCompatibility=!1}init(){this.ieCompatibility="5d41402abc4b2a76b9719d911017c592"!=this.md5("hello")}md5cycle(e,t){let i=e[0],r=e[1],n=e[2],s=e[3];i=this.ff(i,r,n,s,t[0],7,-680876936),s=this.ff(s,i,r,n,t[1],12,-389564586),n=this.ff(n,s,i,r,t[2],17,606105819),r=this.ff(r,n,s,i,t[3],22,-1044525330),i=this.ff(i,r,n,s,t[4],7,-176418897),s=this.ff(s,i,r,n,t[5],12,1200080426),n=this.ff(n,s,i,r,t[6],17,-1473231341),r=this.ff(r,n,s,i,t[7],22,-45705983),i=this.ff(i,r,n,s,t[8],7,1770035416),s=this.ff(s,i,r,n,t[9],12,-1958414417),n=this.ff(n,s,i,r,t[10],17,-42063),r=this.ff(r,n,s,i,t[11],22,-1990404162),i=this.ff(i,r,n,s,t[12],7,1804603682),s=this.ff(s,i,r,n,t[13],12,-40341101),n=this.ff(n,s,i,r,t[14],17,-1502002290),r=this.ff(r,n,s,i,t[15],22,1236535329),i=this.gg(i,r,n,s,t[1],5,-165796510),s=this.gg(s,i,r,n,t[6],9,-1069501632),n=this.gg(n,s,i,r,t[11],14,643717713),r=this.gg(r,n,s,i,t[0],20,-373897302),i=this.gg(i,r,n,s,t[5],5,-701558691),s=this.gg(s,i,r,n,t[10],9,38016083),n=this.gg(n,s,i,r,t[15],14,-660478335),r=this.gg(r,n,s,i,t[4],20,-405537848),i=this.gg(i,r,n,s,t[9],5,568446438),s=this.gg(s,i,r,n,t[14],9,-1019803690),n=this.gg(n,s,i,r,t[3],14,-187363961),r=this.gg(r,n,s,i,t[8],20,1163531501),i=this.gg(i,r,n,s,t[13],5,-1444681467),s=this.gg(s,i,r,n,t[2],9,-51403784),n=this.gg(n,s,i,r,t[7],14,1735328473),r=this.gg(r,n,s,i,t[12],20,-1926607734),i=this.hh(i,r,n,s,t[5],4,-378558),s=this.hh(s,i,r,n,t[8],11,-2022574463),n=this.hh(n,s,i,r,t[11],16,1839030562),r=this.hh(r,n,s,i,t[14],23,-35309556),i=this.hh(i,r,n,s,t[1],4,-1530992060),s=this.hh(s,i,r,n,t[4],11,1272893353),n=this.hh(n,s,i,r,t[7],16,-155497632),r=this.hh(r,n,s,i,t[10],23,-1094730640),i=this.hh(i,r,n,s,t[13],4,681279174),s=this.hh(s,i,r,n,t[0],11,-358537222),n=this.hh(n,s,i,r,t[3],16,-722521979),r=this.hh(r,n,s,i,t[6],23,76029189),i=this.hh(i,r,n,s,t[9],4,-640364487),s=this.hh(s,i,r,n,t[12],11,-421815835),n=this.hh(n,s,i,r,t[15],16,530742520),r=this.hh(r,n,s,i,t[2],23,-995338651),i=this.ii(i,r,n,s,t[0],6,-198630844),s=this.ii(s,i,r,n,t[7],10,1126891415),n=this.ii(n,s,i,r,t[14],15,-1416354905),r=this.ii(r,n,s,i,t[5],21,-57434055),i=this.ii(i,r,n,s,t[12],6,1700485571),s=this.ii(s,i,r,n,t[3],10,-1894986606),n=this.ii(n,s,i,r,t[10],15,-1051523),r=this.ii(r,n,s,i,t[1],21,-2054922799),i=this.ii(i,r,n,s,t[8],6,1873313359),s=this.ii(s,i,r,n,t[15],10,-30611744),n=this.ii(n,s,i,r,t[6],15,-1560198380),r=this.ii(r,n,s,i,t[13],21,1309151649),i=this.ii(i,r,n,s,t[4],6,-145523070),s=this.ii(s,i,r,n,t[11],10,-1120210379),n=this.ii(n,s,i,r,t[2],15,718787259),r=this.ii(r,n,s,i,t[9],21,-343485551),e[0]=this.add32(i,e[0]),e[1]=this.add32(r,e[1]),e[2]=this.add32(n,e[2]),e[3]=this.add32(s,e[3])}cmn(e,t,i,r,n,s){return t=this.add32(this.add32(t,e),this.add32(r,s)),this.add32(t<<n|t>>>32-n,i)}ff(e,t,i,r,n,s,o){return this.cmn(t&i|~t&r,e,t,n,s,o)}gg(e,t,i,r,n,s,o){return this.cmn(t&r|i&~r,e,t,n,s,o)}hh(e,t,i,r,n,s,o){return this.cmn(t^i^r,e,t,n,s,o)}ii(e,t,i,r,n,s,o){return this.cmn(i^(t|~r),e,t,n,s,o)}md51(e){const t=e.length,i=[1732584193,-271733879,-1732584194,271733878];let r;for(r=64;r<=e.length;r+=64)this.md5cycle(i,this.md5blk(e.substring(r-64,r)));e=e.substring(r-64);const n=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(r=0;r<e.length;r++)n[r>>2]|=e.charCodeAt(r)<<(r%4<<3);if(n[r>>2]|=128<<(r%4<<3),r>55)for(this.md5cycle(i,n),r=0;r<16;r++)n[r]=0;return n[14]=8*t,this.md5cycle(i,n),i}md5blk(e){const t=[];for(let i=0;i<64;i+=4)t[i>>2]=e.charCodeAt(i)+(e.charCodeAt(i+1)<<8)+(e.charCodeAt(i+2)<<16)+(e.charCodeAt(i+3)<<24);return t}rhex(e){const t="0123456789abcdef".split("");let i="",r=0;for(;r<4;r++)i+=t[e>>8*r+4&15]+t[e>>8*r&15];return i}hex(e){for(let t=0;t<e.length;t++)e[t]=this.rhex(e[t]);return e.join("")}md5(e){return this.hex(this.md51(e))}add32(e,t){return this.ieCompatibility?this.add32Compat(e,t):this.add32Std(e,t)}add32Std(e,t){return e+t&4294967295}add32Compat(e,t){const i=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(i>>16)<<16|65535&i}};function f(e){return null==e||0===e.length}var m={"01":"GRID","02":"CHARTS","0102":"BOTH"},v=class e{constructor(e){this.watermarkMessage=void 0,this.totalMessageLength=124,this.document=e,this.md5=new g,this.md5.init()}validateLicense(){const t=this.getLicenseDetails(e.licenseKey),i=`AG Grid ${"BOTH"===t.currentLicenseType?"and AG Charts ":""}Enterprise`,r=void 0===t.suppliedLicenseType?"":`AG ${"BOTH"===t.suppliedLicenseType?"Grid and AG Charts":"GRID"===t.suppliedLicenseType?"Grid":"Charts"} Enterprise`;if(t.missing)this.isWebsiteUrl()&&!this.isForceWatermark()||this.outputMissingLicenseKey(i);else if(t.expired){const n=e.getGridReleaseDate(),s=e.formatDate(n);this.outputExpiredKey(t.expiry,s,i,r)}else t.valid?t.isTrial&&t.trialExpired&&this.outputExpiredTrialKey(t.expiry,i,r):this.outputInvalidLicenseKey(!!t.incorrectLicenseType,i,r)}static extractExpiry(t){const i=t.substring(t.lastIndexOf("_")+1,t.length);return new Date(parseInt(e.decode(i),10))}static extractLicenseComponents(t){let i=t.replace(/[\u200B-\u200D\uFEFF]/g,"");if(i=i.replace(/\r?\n|\r/g,""),t.length<=32)return{md5:null,license:t,version:null,isTrial:null};const r=i.length-32,n=i.substring(r),s=i.substring(0,r),[o,a,l]=e.extractBracketedInformation(i);return{md5:n,license:s,version:o,isTrial:a,type:l}}getLicenseDetails(t){const i=e.chartsLicenseManager?"BOTH":"GRID";if(f(t))return{licenseKey:t,valid:!1,missing:!0,currentLicenseType:i};const r=e.getGridReleaseDate(),{md5:n,license:s,version:o,isTrial:a,type:l}=e.extractLicenseComponents(t);let c,u,h,d=n===this.md5.md5(s)&&-1===t.indexOf("For_Trialing_ag-Grid_Only"),p=null,g=!1;function v(){c=p<new Date,u=void 0}if(d&&(p=e.extractExpiry(s),d=!isNaN(p.getTime()),d))switch(u=r>p,o){case"legacy":case"2":a&&v();break;case"3":f(l)?d=!1:(h=l,l!==m["01"]&&l!==m["0102"]||"BOTH"===i&&"BOTH"!==h?(d=!1,g=!0):a&&v())}return d?{licenseKey:t,valid:d,expiry:e.formatDate(p),expired:u,version:o,isTrial:a,trialExpired:c,incorrectLicenseType:g,currentLicenseType:i,suppliedLicenseType:h}:{licenseKey:t,valid:d,incorrectLicenseType:g,currentLicenseType:i,suppliedLicenseType:h}}isDisplayWatermark(){return this.isForceWatermark()||!this.isLocalhost()&&!this.isWebsiteUrl()&&!f(this.watermarkMessage)}getWatermarkMessage(){return this.watermarkMessage||""}getHostname(){const e=(this.document.defaultView||window).location,{hostname:t=""}=e;return t}isForceWatermark(){const e=(this.document.defaultView||window).location,{pathname:t}=e;return!!t&&-1!==t.indexOf("forceWatermark")}isWebsiteUrl(){return null!==this.getHostname().match(/^((?:[\w-]+\.)?ag-grid\.com)$/)}isLocalhost(){return null!==this.getHostname().match(/^(?:127\.0\.0\.1|localhost)$/)}static formatDate(e){const t=e.getDate(),i=e.getMonth(),r=e.getFullYear();return t+" "+["January","February","March","April","May","June","July","August","September","October","November","December"][i]+" "+r}static getGridReleaseDate(){return new Date(parseInt(e.decode(e.RELEASE_INFORMATION),10))}static decode(t){const i="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let r,n,s,o,a,l,c,u="",h=0;const d=t.replace(/[^A-Za-z0-9+/=]/g,"");for(;h<d.length;)o=i.indexOf(d.charAt(h++)),a=i.indexOf(d.charAt(h++)),l=i.indexOf(d.charAt(h++)),c=i.indexOf(d.charAt(h++)),r=o<<2|a>>4,n=(15&a)<<4|l>>2,s=(3&l)<<6|c,u+=String.fromCharCode(r),64!=l&&(u+=String.fromCharCode(n)),64!=c&&(u+=String.fromCharCode(s));return u=e.utf8_decode(u),u}static utf8_decode(e){e=e.replace(/rn/g,"n");let t="";for(let i=0;i<e.length;i++){const r=e.charCodeAt(i);r<128?t+=String.fromCharCode(r):r>127&&r<2048?(t+=String.fromCharCode(r>>6|192),t+=String.fromCharCode(63&r|128)):(t+=String.fromCharCode(r>>12|224),t+=String.fromCharCode(r>>6&63|128),t+=String.fromCharCode(63&r|128))}return t}static setChartsLicenseManager(e){this.chartsLicenseManager=e}static setLicenseKey(e){this.licenseKey=e,this.chartsLicenseManager&&this.chartsLicenseManager.setLicenseKey(e,!0)}static extractBracketedInformation(e){if(!e.includes("["))return["legacy",!1,void 0];const t=e.match(/\[(.*?)\]/g).map(e=>e.replace("[","").replace("]",""));if(!t||0===t.length)return["legacy",!1,void 0];const i=1===t.filter(e=>"TRIAL"===e).length,r=t.filter(e=>0===e.indexOf("v"))[0];return[r?r.replace("v",""):"legacy",i,m[t.filter(e=>m[e])[0]]]}centerPadAndOutput(e){const t=this.totalMessageLength-e.length;console.error(e.padStart(t/2+e.length,"*").padEnd(this.totalMessageLength,"*"))}padAndOutput(e,t="*",i=""){console.error(e.padEnd(this.totalMessageLength-i.length,t)+i)}outputInvalidLicenseKey(e,t,i){e?(this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Incompatible License Key "),this.padAndOutput(`* Your license key is for ${i} only and does not cover you for ${t}.`," ","*"),this.padAndOutput("* Please contact info@ag-grid.com to obtain a combined license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput("")):(this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Invalid License Key "),this.padAndOutput("* Your license key is not valid - please contact info@ag-grid.com to obtain a valid license."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput("")),this.watermarkMessage="Invalid License"}outputExpiredTrialKey(e,t,i){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${t} License `),this.centerPadAndOutput(" Trial Period Expired. "),this.padAndOutput(`* Your trial only license for ${i} expired on ${e}.`," ","*"),this.padAndOutput("* Please email info@ag-grid.com to purchase a license."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="Trial Period Expired"}outputMissingLicenseKey(e){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${e} License `),this.centerPadAndOutput(" License Key Not Found "),this.padAndOutput(`* All ${e} features are unlocked for trial.`," ","*"),this.padAndOutput("* If you want to hide the watermark please email info@ag-grid.com for a trial license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="For Trial Use Only"}outputExpiredKey(e,t,i,r){this.centerPadAndOutput(""),this.centerPadAndOutput(` ${i} License `),this.centerPadAndOutput(" Incompatible Software Version "),this.padAndOutput(`* Your license key works with versions of ${r} released before ${e}.`," ","*"),this.padAndOutput(`* The version you are trying to use was released on ${t}.`," ","*"),this.padAndOutput("* Please contact info@ag-grid.com to renew your license key."," ","*"),this.centerPadAndOutput(""),this.centerPadAndOutput(""),this.watermarkMessage="License Expired"}};v.RELEASE_INFORMATION="MTcxNTc3NTcyODYxNg==";var C=v,y=class extends r.XQb{validateLicense(){this.licenseManager=new C(this.gos.getDocument()),this.licenseManager.validateLicense()}static getLicenseDetails(e){return new C(null).getLicenseDetails(e)}isDisplayWatermark(){return this.licenseManager.isDisplayWatermark()}getWatermarkMessage(){return this.licenseManager.getWatermarkMessage()}static setLicenseKey(e){C.setLicenseKey(e)}static setChartsLicenseManager(e){C.setChartsLicenseManager(e)}};d([r.fK3],y.prototype,"validateLicense",1),y=d([(0,r.dR4)("licenseManager")],y);var w=class extends r.uAl{constructor(){super('<div class="ag-watermark">\n                <div ref="eLicenseTextRef" class="ag-watermark-text"></div>\n            </div>')}postConstruct(){const e=this.shouldDisplayWatermark();this.setDisplayed(e),e&&(this.eLicenseTextRef.innerText=this.licenseManager.getWatermarkMessage(),window.setTimeout(()=>this.addCssClass("ag-opacity-zero"),0),window.setTimeout(()=>this.setDisplayed(!1),5e3))}shouldDisplayWatermark(){return this.licenseManager.isDisplayWatermark()}};d([(0,r.dsm)("licenseManager")],w.prototype,"licenseManager",2),d([(0,r.PIB)("eLicenseTextRef")],w.prototype,"eLicenseTextRef",2),d([r.o7C],w.prototype,"postConstruct",1);var S={version:"31.3.4",moduleName:r.zsj.EnterpriseCoreModule,beans:[y],agStackComponents:[{componentName:"AgWatermark",componentClass:w}]},b=Object.defineProperty,E=Object.defineProperties,A=Object.getOwnPropertyDescriptor,T=Object.getOwnPropertyDescriptors,M=Object.getOwnPropertySymbols,R=Object.prototype.hasOwnProperty,_=Object.prototype.propertyIsEnumerable,P=(e,t,i)=>t in e?b(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,x=(e,t)=>{for(var i in t||(t={}))R.call(t,i)&&P(e,i,t[i]);if(M)for(var i of M(t))_.call(t,i)&&P(e,i,t[i]);return e},D=(e,t)=>E(e,T(t)),I=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?A(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&b(t,i,s),s},L=class extends r.uAl{constructor(e){super('\n            <div class="ag-advanced-filter-header" role="row">\n            </div>'),this.enabled=e}postConstruct(){this.setupAdvancedFilter(this.enabled),this.addDestroyFunc(()=>this.destroyBean(this.eAdvancedFilter)),this.addManagedListener(this.eventService,r.sVA.EVENT_GRID_COLUMNS_CHANGED,()=>this.onGridColumnsChanged()),this.addGuiEventListener("keydown",e=>this.onKeyDown(e)),this.addGuiEventListener("focusout",e=>{this.getFocusableElement().contains(e.relatedTarget)||this.focusService.clearAdvancedFilterColumn()})}getFocusableElement(){var e,t;return null!=(t=null==(e=this.eAdvancedFilter)?void 0:e.getGui())?t:this.getGui()}setEnabled(e){e!==this.enabled&&this.setupAdvancedFilter(e)}refresh(){var e;null==(e=this.eAdvancedFilter)||e.refresh()}getHeight(){return this.height}setInputDisabled(e){var t;null==(t=this.eAdvancedFilter)||t.setInputDisabled(e)}setupAdvancedFilter(e){const t=this.getGui();if(e){this.eAdvancedFilter=this.createBean(new Y);const e=this.eAdvancedFilter.getGui();this.eAdvancedFilter.addCssClass("ag-advanced-filter-header-cell"),this.height=this.columnModel.getFloatingFiltersHeight();const i=`${this.height}px`;t.style.height=i,t.style.minHeight=i,this.setAriaRowIndex(),r._.setAriaRole(e,"gridcell"),r._.setAriaColIndex(e,1),this.setAriaColumnCount(e),t.appendChild(e)}else r._.clearElement(t),this.destroyBean(this.eAdvancedFilter),this.height=0;r._.setDisplayed(t,e),this.enabled=e}setAriaColumnCount(e){r._.setAriaColSpan(e,this.columnModel.getAllGridColumns().length)}setAriaRowIndex(){r._.setAriaRowIndex(this.getGui(),this.headerNavigationService.getHeaderRowCount())}onGridColumnsChanged(){this.eAdvancedFilter&&(this.setAriaColumnCount(this.eAdvancedFilter.getGui()),this.setAriaRowIndex())}onKeyDown(e){switch(e.key){case r.DDm.ENTER:this.hasFocus()&&this.focusService.focusInto(this.getFocusableElement())&&e.preventDefault();break;case r.DDm.ESCAPE:this.hasFocus()||this.getFocusableElement().focus();break;case r.DDm.UP:this.navigateUpDown(!0,e);break;case r.DDm.DOWN:this.navigateUpDown(!1,e);break;case r.DDm.TAB:if(this.hasFocus())this.navigateLeftRight(e);else{const t=this.focusService.findNextFocusableElement(this.getFocusableElement(),null,e.shiftKey);t?(e.preventDefault(),t.focus()):this.navigateLeftRight(e)}}}navigateUpDown(e,t){this.hasFocus()&&this.focusService.focusNextFromAdvancedFilter(e)&&t.preventDefault()}navigateLeftRight(e){(e.shiftKey?this.focusService.focusLastHeader():this.focusService.focusNextFromAdvancedFilter(!1,!0))&&e.preventDefault()}hasFocus(){return this.gos.getActiveDomElement()===this.getFocusableElement()}};I([(0,r.dsm)("columnModel")],L.prototype,"columnModel",2),I([(0,r.dsm)("focusService")],L.prototype,"focusService",2),I([(0,r.dsm)("headerNavigationService")],L.prototype,"headerNavigationService",2),I([r.o7C],L.prototype,"postConstruct",1);var N=class extends r.pNP{constructor(e){super(D(x({},e),{template:'\n                <div class="ag-picker-field" role="presentation">\n                    <div ref="eLabel"></div>\n                    <div ref="eWrapper" class="ag-wrapper ag-picker-collapsed">\n                        <div ref="eDisplayField" class="ag-picker-field-display"></div>\n                        <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n                        <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n                    </div>\n                </div>'})),this.params=e}showPicker(){setTimeout(()=>super.showPicker())}hidePicker(){setTimeout(()=>super.hidePicker())}postConstruct(){super.postConstruct();const{wrapperClassName:e,ariaLabel:t}=this.params;r._.setDisplayed(this.eDisplayField,!1),e&&this.eWrapper.classList.add(e),r._.setAriaLabelledBy(this.eWrapper,""),r._.setAriaLabel(this.eWrapper,t)}onEnterKeyDown(e){r._.stopPropagationForAgGrid(e),this.isPickerDisplayed?super.onEnterKeyDown(e):(e.preventDefault(),this.showPicker())}},O=class e extends r.XQb{constructor(e,t){super(),this.comp=e,this.virtualList=t}postConstruct(){this.createManagedBean(new r.ia$(this.comp,this.virtualList,{dragSourceType:r.qRA.AdvancedFilterBuilder,listItemDragStartEvent:e.EVENT_DRAG_STARTED,listItemDragEndEvent:e.EVENT_DRAG_ENDED,eventSource:this,getCurrentDragValue:e=>this.getCurrentDragValue(e),isMoveBlocked:()=>!1,getNumRows:e=>e.getNumItems(),moveItem:(e,t)=>this.moveItem(e,t)}))}getCurrentDragValue(e){return e.item}moveItem(e,t){this.comp.moveItem(e,t)}};O.EVENT_DRAG_STARTED="advancedFilterBuilderDragStarted",O.EVENT_DRAG_ENDED="advancedFilterBuilderDragEnded",I([r.o7C],O.prototype,"postConstruct",1);var F=O,k=class extends r.XQb{constructor(e,t,i){super(),this.eGui=e,this.focusWrapper=t,this.eFocusableComp=i}postConstruct(){this.addManagedListener(this.eGui,"keydown",e=>{switch(e.key){case r.DDm.TAB:e.defaultPrevented||r._.stopPropagationForAgGrid(e);break;case r.DDm.UP:case r.DDm.DOWN:r._.stopPropagationForAgGrid(e);break;case r.DDm.ESCAPE:if(r._.isStopPropagationForAgGrid(e))return;this.eGui.contains(this.gos.getActiveDomElement())&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.focusWrapper.focus())}}),this.addManagedListener(this.focusWrapper,"keydown",e=>{if(e.key===r.DDm.ENTER){if(r._.isStopPropagationForAgGrid(e))return;this.gos.getActiveDomElement()===this.focusWrapper&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.eFocusableComp.getFocusableElement().focus())}}),this.addManagedListener(this.focusWrapper,"focusin",()=>{this.focusWrapper.classList.add("ag-advanced-filter-builder-virtual-list-item-highlight")}),this.addManagedListener(this.focusWrapper,"focusout",e=>{this.focusWrapper.contains(e.relatedTarget)||this.focusWrapper.classList.remove("ag-advanced-filter-builder-virtual-list-item-highlight")})}};function G(e,t){return{pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderAddField",pickerAriaLabelValue:"Advanced Filter Builder Add Field",pickerType:"ag-list",valueList:[{key:"condition",displayValue:e("advancedFilterBuilderAddCondition")},{key:"join",displayValue:e("advancedFilterBuilderAddJoin")}],valueFormatter:e=>{var t;return null==e?null:null!=(t=e.displayValue)?t:e.key},pickerIcon:"advancedFilterBuilderAdd",maxPickerWidth:`${null!=t?t:120}px`,wrapperClassName:"ag-advanced-filter-builder-item-button",ariaLabel:e("advancedFilterBuilderAddButtonTooltip")}}I([r.o7C],k.prototype,"postConstruct",1);var V=class{};V.EVENT_ADDED="advancedFilterBuilderAdded",V.EVENT_MOVED="advancedFilterBuilderMoved",V.EVENT_REMOVED="advancedFilterBuilderRemoved",V.EVENT_VALUE_CHANGED="advancedFilterBuilderValueChanged",V.EVENT_VALID_CHANGED="advancedFilterBuilderValidChanged";var H=class extends r.uAl{constructor(){super('\n            <div class="ag-advanced-filter-builder-item-condition" role="presentation"></div>\n        '),this.validationMessage=null}init(e){const{item:t,createPill:i}=e;this.item=t,this.createPill=i,this.filterModel=t.filterModel,this.setupColumnCondition(this.filterModel),this.validate(),this.addDestroyFunc(()=>this.destroyBeans([this.eColumnPill,this.eOperatorPill,this.eOperandPill]))}getDragName(){return this.filterModel.colId?this.advancedFilterExpressionService.parseColumnFilterModel(this.filterModel):this.getDefaultColumnDisplayValue()}getAriaLabel(){return`${this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderFilterItem")} ${this.getDragName()}`}getValidationMessage(){return this.validationMessage}getFocusableElement(){return this.eColumnPill.getFocusableElement()}setupColumnCondition(e){var t;const i=this.advancedFilterExpressionService.getColumnDetails(e.colId);this.baseCellDataType=i.baseCellDataType,this.column=i.column,this.numOperands=this.getNumOperands(this.getOperatorKey()),this.eColumnPill=this.createPill({key:this.getColumnKey(),displayValue:null!=(t=this.getColumnDisplayValue())?t:this.getDefaultColumnDisplayValue(),cssClass:"ag-advanced-filter-builder-column-pill",isSelect:!0,getEditorParams:()=>({values:this.advancedFilterExpressionService.getColumnAutocompleteEntries()}),update:e=>this.setColumnKey(e),pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderColumnSelectField",pickerAriaLabelValue:"Advanced Filter Builder Column Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderColumn")}),this.getGui().appendChild(this.eColumnPill.getGui()),r._.exists(this.getColumnKey())&&(this.createOperatorPill(),this.hasOperand()&&this.createOperandPill())}createOperatorPill(){var e;this.eOperatorPill=this.createPill({key:this.getOperatorKey(),displayValue:null!=(e=this.getOperatorDisplayValue())?e:this.getDefaultOptionSelectValue(),cssClass:"ag-advanced-filter-builder-option-pill",isSelect:!0,getEditorParams:()=>({values:this.getOperatorAutocompleteEntries()}),update:e=>this.setOperatorKey(e),pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderOptionSelectField",pickerAriaLabelValue:"Advanced Filter Builder Option Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderOption")}),this.eColumnPill.getGui().insertAdjacentElement("afterend",this.eOperatorPill.getGui())}createOperandPill(){var e;const t=null!=(e=this.getOperandDisplayValue())?e:"";this.eOperandPill=this.createPill({key:t,displayValue:t,baseCellDataType:this.baseCellDataType,cssClass:"ag-advanced-filter-builder-value-pill",isSelect:!1,update:e=>this.setOperand(e),ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderValue")}),this.getGui().appendChild(this.eOperandPill.getGui())}getColumnKey(){return this.filterModel.colId}getColumnDisplayValue(){return this.advancedFilterExpressionService.getColumnDisplayValue(this.filterModel)}getOperatorKey(){return this.filterModel.type}getOperatorDisplayValue(){return this.advancedFilterExpressionService.getOperatorDisplayValue(this.filterModel)}getOperandDisplayValue(){return this.advancedFilterExpressionService.getOperandDisplayValue(this.filterModel,!0)}hasOperand(){return this.numOperands>0}getOperatorAutocompleteEntries(){return this.column?this.advancedFilterExpressionService.getOperatorAutocompleteEntries(this.column,this.baseCellDataType):[]}setColumnKey(e){this.eOperatorPill||this.createOperatorPill();const t=this.advancedFilterExpressionService.getColumnDetails(e);this.column=t.column;const i=t.baseCellDataType;this.baseCellDataType!==i&&(this.baseCellDataType=i,this.setOperatorKey(void 0),this.eOperatorPill&&(r._.removeFromParent(this.eOperatorPill.getGui()),this.destroyBean(this.eOperatorPill),this.createOperatorPill()),this.validate()),this.filterModel.colId=e,this.filterModel.filterType=this.baseCellDataType}setOperatorKey(e){const t=this.getNumOperands(e);t!==this.numOperands&&(this.numOperands=t,0===t?this.destroyOperandPill():(this.createOperandPill(),"number"!==this.baseCellDataType&&this.setOperand(""))),this.filterModel.type=e,this.validate()}setOperand(e){var t;let i=e;this.column&&(i=null!=(t=this.advancedFilterExpressionService.getOperandModelValue(e,this.baseCellDataType,this.column))?t:""),this.filterModel.filter=i,this.validate()}getNumOperands(e){var t,i;return null!=(i=null==(t=this.advancedFilterExpressionService.getExpressionOperator(this.baseCellDataType,e))?void 0:t.numOperands)?i:0}destroyOperandPill(){delete this.filterModel.filter,this.getGui().removeChild(this.eOperandPill.getGui()),this.destroyBean(this.eOperandPill),this.eOperandPill=void 0}validate(){let e=null;r._.exists(this.getColumnKey())?r._.exists(this.getOperatorKey())?this.numOperands>0&&!r._.exists(this.getOperandDisplayValue())&&(e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationEnterValue")):e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationSelectOption"):e=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationSelectColumn"),this.item.valid=!e,e!==this.validationMessage&&(this.validationMessage=e,this.dispatchEvent({type:V.EVENT_VALID_CHANGED}))}getDefaultColumnDisplayValue(){return this.advancedFilterExpressionService.translate("advancedFilterBuilderSelectColumn")}getDefaultOptionSelectValue(){return this.advancedFilterExpressionService.translate("advancedFilterBuilderSelectOption")}};I([(0,r.dsm)("advancedFilterExpressionService")],H.prototype,"advancedFilterExpressionService",2),I([(0,r.dsm)("valueService")],H.prototype,"valueService",2);var B=class extends r.uAl{constructor(e){super('\n            <div class="ag-advanced-filter-builder-pill-wrapper" role="presentation">\n                <div ref="ePill" class="ag-advanced-filter-builder-pill" role="button">\n                    <span ref="eLabel" class="ag-advanced-filter-builder-pill-display"></span>\n                </div>\n            </div>\n        '),this.params=e,this.value=e.value}postConstruct(){const{cssClass:e,ariaLabel:t}=this.params;this.ePill.classList.add(e),this.activateTabIndex([this.ePill]),this.eLabel.id=`${this.getCompId()}`,r._.setAriaDescribedBy(this.ePill,this.eLabel.id),r._.setAriaLabel(this.ePill,t),this.renderValue(),this.addManagedListener(this.ePill,"click",e=>{e.preventDefault(),this.showEditor()}),this.addManagedListener(this.ePill,"keydown",e=>{e.key===r.DDm.ENTER&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.showEditor())}),this.addDestroyFunc(()=>this.destroyBean(this.eEditor))}getFocusableElement(){return this.ePill}showEditor(){if(this.eEditor)return;r._.setDisplayed(this.ePill,!1),this.eEditor=this.createEditorComp(this.params.type),this.eEditor.setValue(this.value);const e=this.eEditor.getGui();this.eEditor.addManagedListener(e,"keydown",e=>{switch(e.key){case r.DDm.ENTER:e.preventDefault(),r._.stopPropagationForAgGrid(e),this.updateValue(!0);break;case r.DDm.ESCAPE:e.preventDefault(),r._.stopPropagationForAgGrid(e),this.hideEditor(!0)}}),this.eEditor.addManagedListener(e,"focusout",()=>{this.updateValue(!1)}),this.getGui().appendChild(e),this.eEditor.getFocusableElement().focus()}createEditorComp(e){let t;switch(e){case"text":t=new r.stt;break;case"number":t=new r.SpC;break;case"date":t=new r.RYS}return this.createBean(t)}hideEditor(e){const{eEditor:t}=this;t&&(this.eEditor=void 0,this.getGui().removeChild(t.getGui()),this.destroyBean(t),r._.setDisplayed(this.ePill,!0),e&&this.ePill.focus())}renderValue(){let e;this.eLabel.classList.remove("ag-advanced-filter-builder-value-empty","ag-advanced-filter-builder-value-number","ag-advanced-filter-builder-value-text"),r._.exists(this.value)?"number"===this.params.type?(e=this.value,this.eLabel.classList.add("ag-advanced-filter-builder-value-number")):(e=`"${this.value}"`,this.eLabel.classList.add("ag-advanced-filter-builder-value-text")):(e=this.advancedFilterExpressionService.translate("advancedFilterBuilderEnterValue"),this.eLabel.classList.add("ag-advanced-filter-builder-value-empty")),this.eLabel.innerText=e}updateValue(e){var t;if(!this.eEditor)return;const i=null!=(t=this.eEditor.getValue())?t:"";this.dispatchEvent({type:r.sVA.EVENT_FIELD_VALUE_CHANGED,value:i}),this.value=i,this.renderValue(),this.hideEditor(e)}};I([(0,r.PIB)("ePill")],B.prototype,"ePill",2),I([(0,r.PIB)("eLabel")],B.prototype,"eLabel",2),I([(0,r.dsm)("advancedFilterExpressionService")],B.prototype,"advancedFilterExpressionService",2),I([r.o7C],B.prototype,"postConstruct",1);var z=class extends r.uAl{constructor(){super('\n            <div class="ag-advanced-filter-builder-item-condition" role="presentation"></div>\n        ')}init(e){const{item:t,createPill:i}=e,r=t.filterModel;this.filterModel=r,this.ePill=i({key:r.type,displayValue:this.advancedFilterExpressionService.parseJoinOperator(r),cssClass:"ag-advanced-filter-builder-join-pill",isSelect:!0,getEditorParams:()=>({values:this.advancedFilterExpressionService.getJoinOperatorAutocompleteEntries()}),update:e=>r.type=e,pickerAriaLabelKey:"ariaLabelAdvancedFilterBuilderJoinSelectField",pickerAriaLabelValue:"Advanced Filter Builder Join Operator Select Field",ariaLabel:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderJoinOperator")}),this.getGui().appendChild(this.ePill.getGui()),this.addDestroyFunc(()=>this.destroyBean(this.ePill))}getDragName(){return this.advancedFilterExpressionService.parseJoinOperator(this.filterModel)}getAriaLabel(){return`${this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderGroupItem")} ${this.getDragName()}`}getValidationMessage(){return null}getFocusableElement(){return this.ePill.getFocusableElement()}};I([(0,r.dsm)("advancedFilterExpressionService")],z.prototype,"advancedFilterExpressionService",2);var U=class extends r.pNP{constructor(e){super(D(x({},e),{template:'\n                <div class="ag-picker-field ag-advanced-filter-builder-pill-wrapper" role="presentation">\n                    <div ref="eLabel"></div>\n                    <div ref="eWrapper" class="ag-wrapper ag-advanced-filter-builder-pill ag-picker-collapsed">\n                        <div ref="eDisplayField" class="ag-picker-field-display ag-advanced-filter-builder-pill-display"></div>\n                        <ag-input-text-field ref="eInput" class="ag-rich-select-field-input"></ag-input-text-field>\n                        <div ref="eIcon" class="ag-picker-field-icon" aria-hidden="true"></div>\n                    </div>\n                </div>'})),this.params=e}getFocusableElement(){return this.eWrapper}showPicker(){setTimeout(()=>super.showPicker())}hidePicker(){setTimeout(()=>super.hidePicker())}postConstruct(){super.postConstruct();const{wrapperClassName:e,ariaLabel:t}=this.params;this.eWrapper.classList.add(e),r._.setAriaLabelledBy(this.eWrapper,""),r._.setAriaLabel(this.eWrapper,t)}createPickerComponent(){var e;if(!this.values){const{values:t}=this.params.getEditorParams();this.values=t;const i=this.value.key,r=null!=(e=t.find(e=>e.key===i))?e:{key:i,displayValue:this.value.displayValue};this.value=r}return super.createPickerComponent()}onEnterKeyDown(e){r._.stopPropagationForAgGrid(e),this.isPickerDisplayed?super.onEnterKeyDown(e):(e.preventDefault(),this.showPicker())}},W=class extends r.aJZ{constructor(e,t,i){super('\n            <div class="ag-advanced-filter-builder-item-wrapper" role="presentation">\n                <div ref="eItem" class="ag-advanced-filter-builder-item" role="presentation">\n                    <div ref="eTreeLines" class="ag-advanced-filter-builder-item-tree-lines" aria-hidden="true"></div>\n                    <span ref="eDragHandle" class="ag-drag-handle" aria-hidden="true"></span>\n                    <span ref="eValidation" class="ag-advanced-filter-builder-item-button ag-advanced-filter-builder-invalid" aria-hidden="true"></span>\n                </div>\n                <div ref="eButtons" class="ag-advanced-filter-builder-item-buttons">\n                    <span ref="eMoveUpButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                    <span ref="eMoveDownButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                    <div ref="eAddButton" role="presentation"></div>\n                    <span ref="eRemoveButton" class="ag-advanced-filter-builder-item-button" role="button"></span>\n                </div>\n            </div>\n        '),this.item=e,this.dragFeature=t,this.focusWrapper=i,this.moveUpDisabled=!1,this.moveDownDisabled=!1}postConstruct(){const{filterModel:e,level:t,showMove:i}=this.item,n="join"===e.filterType;if(this.ePillWrapper=this.createManagedBean(n?new z:new H),this.ePillWrapper.init({item:this.item,createPill:e=>this.createPill(e)}),this.eDragHandle.insertAdjacentElement("afterend",this.ePillWrapper.getGui()),0===t){const e=document.createElement("div");e.classList.add("ag-advanced-filter-builder-item-tree-line-vertical-bottom"),e.classList.add("ag-advanced-filter-builder-item-tree-line-root"),this.eTreeLines.appendChild(e),r._.setDisplayed(this.eDragHandle,!1),r._.setDisplayed(this.eButtons,!1),r._.setAriaExpanded(this.focusWrapper,!0)}else this.setupTreeLines(t),this.eDragHandle.appendChild(r._.createIconNoSpan("advancedFilterBuilderDrag",this.gos)),this.setupValidation(),this.setupMoveButtons(i),this.setupAddButton(),this.setupRemoveButton(),this.setupDragging(),this.updateAriaExpanded();r._.setAriaLevel(this.focusWrapper,t+1),this.initialiseTabGuard({}),this.createManagedBean(new k(this.getGui(),this.focusWrapper,this.ePillWrapper)),this.updateAriaLabel(),this.addManagedListener(this.ePillWrapper,V.EVENT_VALUE_CHANGED,()=>this.dispatchEvent({type:V.EVENT_VALUE_CHANGED})),this.addManagedListener(this.ePillWrapper,V.EVENT_VALID_CHANGED,()=>this.updateValidity())}setState(e){const{level:t}=this.item;if(0===t)return;const{showMove:i}=this.item,{disableMoveUp:n,disableMoveDown:s,treeLines:o,showStartTreeLine:a}=e;this.updateTreeLines(o,a),this.updateAriaExpanded(),i&&(this.moveUpDisabled=!!n,this.moveDownDisabled=!!s,this.eMoveUpButton.classList.toggle("ag-advanced-filter-builder-item-button-disabled",n),this.eMoveDownButton.classList.toggle("ag-advanced-filter-builder-item-button-disabled",s),r._.setAriaDisabled(this.eMoveUpButton,!!n),r._.setAriaDisabled(this.eMoveDownButton,!!s),this.moveUpTooltipFeature.refreshToolTip(),this.moveDownTooltipFeature.refreshToolTip())}focusMoveButton(e){(e?this.eMoveUpButton:this.eMoveDownButton).focus()}afterAdd(){this.ePillWrapper.getFocusableElement().focus()}setupTreeLines(e){for(let t=0;t<e;t++){const e=document.createElement("div");this.eTreeLines.appendChild(e)}}updateTreeLines(e,t){const i=e.length-1,{children:r}=this.eTreeLines;for(let t=0;t<i;t++){const i=r.item(t);i&&i.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical",!e[t])}const n=r.item(i);if(n){n.classList.add("ag-advanced-filter-builder-item-tree-line-horizontal");const t=e[i];n.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical-top",t),n.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical",!t)}this.eDragHandle.classList.toggle("ag-advanced-filter-builder-item-tree-line-vertical-bottom",t)}setupValidation(){this.eValidation.appendChild(r._.createIconNoSpan("advancedFilterBuilderInvalid",this.gos)),this.validationTooltipFeature=this.createManagedBean(new r.CvR({getGui:()=>this.eValidation,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.ePillWrapper.getValidationMessage(),getTooltipShowDelayOverride:()=>1e3})),this.updateValidity()}setupAddButton(){var e;const t=G(e=>this.advancedFilterExpressionService.translate(e),null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.addSelectWidth),i=this.createManagedBean(new N(t));this.addManagedListener(i,r.sVA.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>this.dispatchEvent({type:V.EVENT_ADDED,item:this.item,isJoin:"join"===e.key})),this.eAddButton.appendChild(i.getGui()),this.createManagedBean(new r.CvR({getGui:()=>this.eAddButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip")}))}setupRemoveButton(){this.eRemoveButton.appendChild(r._.createIconNoSpan("advancedFilterBuilderRemove",this.gos)),this.addManagedListener(this.eRemoveButton,"click",()=>this.removeItem()),this.addManagedListener(this.eRemoveButton,"keydown",e=>{e.key===r.DDm.ENTER&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.removeItem())}),this.createManagedBean(new r.CvR({getGui:()=>this.eRemoveButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderRemoveButtonTooltip")})),r._.setAriaLabel(this.eRemoveButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderRemoveButtonTooltip")),this.activateTabIndex([this.eRemoveButton])}setupMoveButtons(e){e?(this.eMoveUpButton.appendChild(r._.createIconNoSpan("advancedFilterBuilderMoveUp",this.gos)),this.addManagedListener(this.eMoveUpButton,"click",()=>this.moveItem(!0)),this.addManagedListener(this.eMoveUpButton,"keydown",e=>{e.key===r.DDm.ENTER&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.moveItem(!0))}),this.moveUpTooltipFeature=this.createManagedBean(new r.CvR({getGui:()=>this.eMoveUpButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.moveUpDisabled?null:this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveUpButtonTooltip")})),r._.setAriaLabel(this.eMoveUpButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveUpButtonTooltip")),this.eMoveDownButton.appendChild(r._.createIconNoSpan("advancedFilterBuilderMoveDown",this.gos)),this.addManagedListener(this.eMoveDownButton,"click",()=>this.moveItem(!1)),this.addManagedListener(this.eMoveDownButton,"keydown",e=>{e.key===r.DDm.ENTER&&(e.preventDefault(),r._.stopPropagationForAgGrid(e),this.moveItem(!1))}),this.moveDownTooltipFeature=this.createManagedBean(new r.CvR({getGui:()=>this.eMoveDownButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.moveDownDisabled?null:this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveDownButtonTooltip")})),r._.setAriaLabel(this.eMoveDownButton,this.advancedFilterExpressionService.translate("advancedFilterBuilderMoveDownButtonTooltip")),this.activateTabIndex([this.eMoveUpButton,this.eMoveDownButton])):(r._.setDisplayed(this.eMoveUpButton,!1),r._.setDisplayed(this.eMoveDownButton,!1))}updateValidity(){r._.setVisible(this.eValidation,!this.item.valid),this.validationTooltipFeature.refreshToolTip(),this.updateAriaLabel()}createPill(e){var t,i;const{key:n,displayValue:s,cssClass:o,update:a,ariaLabel:l}=e,c=e=>{null!=e&&(a(e),this.dispatchEvent({type:V.EVENT_VALUE_CHANGED}))};if(e.isSelect){const{getEditorParams:a,pickerAriaLabelKey:u,pickerAriaLabelValue:h}=e,d=this.gos.get("advancedFilterBuilderParams"),p=`${null!=(t=null==d?void 0:d.pillSelectMinWidth)?t:140}px`,g=`${null!=(i=null==d?void 0:d.pillSelectMaxWidth)?i:200}px`,f=this.createBean(new U({pickerAriaLabelKey:u,pickerAriaLabelValue:h,pickerType:"ag-list",value:{key:n,displayValue:s},valueFormatter:e=>{var t;return null==e?null:null!=(t=e.displayValue)?t:e.key},variableWidth:!0,minPickerWidth:p,maxPickerWidth:g,getEditorParams:a,wrapperClassName:o,ariaLabel:l}));return this.addManagedListener(f,r.sVA.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>c(null==e?void 0:e.key)),f}{const t=this.createBean(new B({value:s,cssClass:o,type:this.getInputType(e.baseCellDataType),ariaLabel:l}));return this.addManagedListener(t,r.sVA.EVENT_FIELD_VALUE_CHANGED,({value:e})=>c(e)),t}}getInputType(e){switch(e){case"text":case"object":case"boolean":return"text";case"number":return"number";case"date":case"dateString":return"date"}}setupDragging(){const e={type:r.qRA.AdvancedFilterBuilder,eElement:this.eDragHandle,dragItemName:()=>this.ePillWrapper.getDragName(),getDefaultIconName:()=>r.WO_.ICON_NOT_ALLOWED,getDragItem:()=>({}),onDragStarted:()=>this.dragFeature.dispatchEvent({type:F.EVENT_DRAG_STARTED,item:this.item}),onDragStopped:()=>this.dragFeature.dispatchEvent({type:F.EVENT_DRAG_ENDED})};this.dragAndDropService.addDragSource(e,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(e))}updateAriaLabel(){const e=this.ePillWrapper.getAriaLabel(),t=`${this.item.level+1}`,i=this.ePillWrapper.getValidationMessage();let n;n=i?this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItemValidation",[e,t,i]):this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItem",[e,t]),r._.setAriaLabel(this.focusWrapper,n)}updateAriaExpanded(){r._.removeAriaExpanded(this.focusWrapper);const{filterModel:e}=this.item;"join"===(null==e?void 0:e.filterType)&&e.conditions.length&&r._.setAriaExpanded(this.focusWrapper,!0)}removeItem(){this.dispatchEvent({type:V.EVENT_REMOVED,item:this.item})}moveItem(e){this.dispatchEvent({type:V.EVENT_MOVED,item:this.item,backwards:e})}};I([(0,r.PIB)("eTreeLines")],W.prototype,"eTreeLines",2),I([(0,r.PIB)("eDragHandle")],W.prototype,"eDragHandle",2),I([(0,r.PIB)("eItem")],W.prototype,"eItem",2),I([(0,r.PIB)("eButtons")],W.prototype,"eButtons",2),I([(0,r.PIB)("eValidation")],W.prototype,"eValidation",2),I([(0,r.PIB)("eMoveUpButton")],W.prototype,"eMoveUpButton",2),I([(0,r.PIB)("eMoveDownButton")],W.prototype,"eMoveDownButton",2),I([(0,r.PIB)("eAddButton")],W.prototype,"eAddButton",2),I([(0,r.PIB)("eRemoveButton")],W.prototype,"eRemoveButton",2),I([(0,r.dsm)("beans")],W.prototype,"beans",2),I([(0,r.dsm)("dragAndDropService")],W.prototype,"dragAndDropService",2),I([(0,r.dsm)("advancedFilterExpressionService")],W.prototype,"advancedFilterExpressionService",2),I([r.o7C],W.prototype,"postConstruct",1);var j=class extends r.uAl{constructor(e,t){super('\n            <div class="ag-advanced-filter-builder-item-wrapper" role="presentation">\n                <div ref="eItem" class="ag-advanced-filter-builder-item" role="presentation">\n                    <div class="ag-advanced-filter-builder-item-tree-lines" aria-hidden="true">\n                        <div class="ag-advanced-filter-builder-item-tree-line-vertical-top ag-advanced-filter-builder-item-tree-line-horizontal"></div>\n                    </div>\n                </div>\n            </div>\n        '),this.item=e,this.focusWrapper=t}postConstruct(){var e;r._.setAriaLevel(this.focusWrapper,2);const t=G(e=>this.advancedFilterExpressionService.translate(e),null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.addSelectWidth),i=this.createManagedBean(new N(t));this.addManagedListener(i,r.sVA.EVENT_FIELD_PICKER_VALUE_SELECTED,({value:e})=>{this.dispatchEvent({type:V.EVENT_ADDED,item:this.item,isJoin:"join"===e.key})}),this.eItem.appendChild(i.getGui()),this.createManagedBean(new r.CvR({getGui:()=>i.getGui(),getLocation:()=>"advancedFilter",getTooltipValue:()=>this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip")})),this.createManagedBean(new k(this.getGui(),this.focusWrapper,i)),r._.setAriaLabel(this.focusWrapper,this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderItem",[this.advancedFilterExpressionService.translate("advancedFilterBuilderAddButtonTooltip"),`${this.item.level+1}`]))}afterAdd(){}};I([(0,r.dsm)("beans")],j.prototype,"beans",2),I([(0,r.dsm)("advancedFilterExpressionService")],j.prototype,"advancedFilterExpressionService",2),I([(0,r.PIB)("eItem")],j.prototype,"eItem",2),I([r.o7C],j.prototype,"postConstruct",1);var K=class extends r.uAl{constructor(){super('\n            <div role="presentation" class="ag-advanced-filter-builder" tabindex="-1">\n                <div role="presentation" class="ag-advanced-filter-builder-list" ref="eList"></div>\n                <div role="presentation" class="ag-advanced-filter-builder-button-panel">\n                    <button class="ag-button ag-standard-button ag-advanced-filter-builder-apply-button" ref="eApplyFilterButton"></button>\n                    <button class="ag-button ag-standard-button ag-advanced-filter-builder-cancel-button" ref="eCancelFilterButton"></button>\n                </div>\n            </div>'),this.validationMessage=null}postConstruct(){var e;const{showMoveButtons:t}=null!=(e=this.gos.get("advancedFilterBuilderParams"))?e:{};this.showMove=!!t,this.addManagedPropertyListener("advancedFilterBuilderParams",({currentValue:e})=>{this.showMove=!!(null==e?void 0:e.showMoveButtons),this.refreshList(!1)}),this.filterModel=this.setupFilterModel(),this.setupVirtualList(),this.dragFeature=this.createManagedBean(new F(this,this.virtualList)),this.setupButtons()}refresh(){let e=this.virtualList.getLastFocusedRow();this.setupFilterModel(),this.validateItems(),this.refreshList(!1),null!=e&&(this.virtualList.getComponentAt(e)||(e=0),this.virtualList.focusRow(e))}getNumItems(){return this.items.length}moveItem(e,t){t&&e&&this.moveItemToIndex(e,t.rowIndex,t.position)}afterGuiAttached(){this.virtualList.focusRow(0)}setupVirtualList(){this.virtualList=this.createManagedBean(new r.wjn({cssIdentifier:"advanced-filter-builder",ariaRole:"tree",listName:this.advancedFilterExpressionService.translate("ariaAdvancedFilterBuilderList")})),this.virtualList.setComponentCreator(this.createItemComponent.bind(this)),this.virtualList.setComponentUpdater(this.updateItemComponent.bind(this)),this.virtualList.setRowHeight(40),this.eList.appendChild(this.virtualList.getGui()),this.virtualList.setModel({getRowCount:()=>this.items.length,getRow:e=>this.items[e],areRowsEqual:(e,t)=>e===t}),this.buildList(),this.virtualList.refresh()}setupButtons(){this.eApplyFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilderApply"),this.activateTabIndex([this.eApplyFilterButton]),this.addManagedListener(this.eApplyFilterButton,"click",()=>{this.advancedFilterService.setModel(this.filterModel),this.filterManager.onFilterChanged({source:"advancedFilter"}),this.close()}),this.validationTooltipFeature=this.createManagedBean(new r.CvR({getGui:()=>this.eApplyFilterButton,getLocation:()=>"advancedFilter",getTooltipValue:()=>this.validationMessage,getTooltipShowDelayOverride:()=>1e3})),this.validate(),this.addManagedListener(this.eApplyFilterButton,"mouseenter",()=>this.addOrRemoveCssClass("ag-advanced-filter-builder-validation",!0)),this.addManagedListener(this.eApplyFilterButton,"mouseleave",()=>this.addOrRemoveCssClass("ag-advanced-filter-builder-validation",!1)),this.eCancelFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilderCancel"),this.activateTabIndex([this.eCancelFilterButton]),this.addManagedListener(this.eCancelFilterButton,"click",()=>this.close())}removeItemFromParent(e){const t=e.parent.conditions.indexOf(e.filterModel);return e.parent.conditions.splice(t,1),t}moveItemToIndex(e,t,i){var r;const n=this.items[t],s="join"===(null==(r=n.filterModel)?void 0:r.filterType)&&"bottom"===i,o=s?n.filterModel:n.parent;if(!o)return;if(this.isChildOrSelf(o,e.filterModel)||n===e)return;let a;this.removeItemFromParent(e),s?a=0:(a=o.conditions.indexOf(n.filterModel),-1===a?a=o.conditions.length:"bottom"===i&&(a+=1)),o.conditions.splice(a,0,e.filterModel),this.refreshList(!1)}isChildOrSelf(e,t){return e===t||"join"===t.filterType&&t.conditions.some(t=>this.isChildOrSelf(e,t))}setupFilterModel(){const e=this.formatFilterModel(this.advancedFilterService.getModel());return this.stringifiedModel=JSON.stringify(e),e}formatFilterModel(e){return"join"!==(e=null!=e?e:{filterType:"join",type:"AND",conditions:[]}).filterType&&(e={filterType:"join",type:"AND",conditions:[e]}),e}buildList(){const e=(t,i,r,n)=>{i.push({filterModel:t,level:r,parent:n,valid:!0,showMove:this.showMove}),"join"===t.filterType&&(t.conditions.forEach(n=>e(n,i,r+1,t)),0===r&&i.push({filterModel:null,level:r+1,parent:t,valid:!0}))};this.items=[],e(this.filterModel,this.items,0)}refreshList(e){if(!e){const e=[];this.items.forEach(t=>{t.valid||e.push(t.filterModel)}),this.buildList(),e.length&&this.items.forEach(t=>{t.filterModel&&e.includes(t.filterModel)&&(t.valid=!1)})}this.virtualList.refresh(e),this.validate()}updateItemComponent(e,t){const i=this.items.indexOf(e),r=(e,t)=>{const i=this.items.find(t=>t.filterModel===e),n=null==i?void 0:i.parent;if(n){const{conditions:i}=n;r(n,t),t.push(i[i.length-1]===e)}},n=[],{filterModel:s}=e;s&&(r(s,n),n[0]=!1);const o="join"===(null==s?void 0:s.filterType)&&!!s.conditions.length;t.setState({disableMoveUp:1===i,disableMoveDown:!this.canMoveDown(e,i),treeLines:n,showStartTreeLine:o})}createItemComponent(e,t){const i=this.createBean(e.filterModel?new W(e,this.dragFeature,t):new j(e,t));return i.addManagedListener(i,V.EVENT_REMOVED,({item:e})=>this.removeItem(e)),i.addManagedListener(i,V.EVENT_VALUE_CHANGED,()=>this.validate()),i.addManagedListener(i,V.EVENT_ADDED,({item:e,isJoin:t})=>this.addItem(e,t)),i.addManagedListener(i,V.EVENT_MOVED,({item:e,backwards:t})=>this.moveItemUpDown(e,t)),i instanceof W&&this.updateItemComponent(e,i),i}addItem(e,t){var i;const{parent:r,level:n,filterModel:s}=e,o="join"===(null==s?void 0:s.filterType),a=t?{filterType:"join",type:"AND",conditions:[]}:{},l=o?s:r;let c=o?0:l.conditions.indexOf(s);c>=0?(o||(c+=1),l.conditions.splice(c,0,a)):l.conditions.push(a);let u=this.items.indexOf(e);const h=u>=0;if(h){e.filterModel&&u++;const i=[{filterModel:a,level:o?n+1:n,parent:l,valid:t,showMove:this.showMove}];this.items.splice(u,0,...i)}this.refreshList(h),h&&(null==(i=this.virtualList.getComponentAt(u))||i.afterAdd())}removeItem(e){var t;const i=e.parent,{filterModel:r}=e,n=i.conditions.indexOf(r);i.conditions.splice(n,1);const s="join"===(null==(t=e.filterModel)?void 0:t.filterType),o=this.items.indexOf(e),a=!s&&o>=0;a&&this.items.splice(o,1),this.refreshList(a),o>=0&&this.virtualList.focusRow(o)}moveItemUpDown(e,t){const i=this.items.indexOf(e),r=t?i-1:i+1;if(0===r||!t&&!this.canMoveDown(e,i))return;const n=this.items[r],s=this.removeItemFromParent(e),{level:o,filterModel:a,parent:l}=e,{level:c,filterModel:u,parent:h}=n;if(t)if(c===o&&"join"===u.filterType)u.conditions.push(a);else if(c<=o){const e=h.conditions.indexOf(u);h.conditions.splice(e,0,a)}else l.conditions[s-1].conditions.push(a);else if(c===o)if("join"===u.filterType)u.conditions.splice(0,0,a);else{const e=h.conditions.indexOf(u);h.conditions.splice(e+1,0,a)}else if(s<l.conditions.length)l.conditions.splice(s+1,0,a);else{const e=this.items.find(e=>e.filterModel===l),t=e.parent.conditions.indexOf(e.filterModel)+1;e.parent.conditions.splice(t,0,a)}this.refreshList(!1);const d=this.items.findIndex(({filterModel:e})=>e===a);if(d>=0){const e=this.virtualList.getComponentAt(d);e instanceof W&&e.focusMoveButton(t)}}canMoveDown(e,t){return!(1===e.level&&t===this.items.length-2||1===e.level&&e.parent.conditions[e.parent.conditions.length-1]===e.filterModel)}close(){this.advancedFilterService.getCtrl().toggleFilterBuilder("ui")}validate(){let e=!this.items.every(({valid:e})=>e);e?this.validationMessage=this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationIncomplete"):(e=JSON.stringify(this.filterModel)===this.stringifiedModel,this.validationMessage=e?this.advancedFilterExpressionService.translate("advancedFilterBuilderValidationAlreadyApplied"):null),r._.setDisabled(this.eApplyFilterButton,e),this.validationTooltipFeature.refreshToolTip()}validateItems(){const e=e=>{e.type=void 0},t=e=>{delete e.filter};this.items.forEach(i=>{if(!i.valid||!i.filterModel||"join"===i.filterModel.filterType)return;const{filterModel:n}=i,{colId:s}=n,o=this.advancedFilterExpressionService.getColumnAutocompleteEntries().find(({key:e})=>e===s),a=this.advancedFilterExpressionService.getColumnDetails(n.colId);if(!o||!a.column)return i.valid=!1,n.colId=void 0,e(n),void t(n);const l=this.advancedFilterExpressionService.getDataTypeExpressionOperator(a.baseCellDataType).operators[n.type];if(!l)return i.valid=!1,e(n),void t(n);l.numOperands>0&&!r._.exists(n.filter)&&(i.valid=!1)})}};I([(0,r.PIB)("eList")],K.prototype,"eList",2),I([(0,r.PIB)("eApplyFilterButton")],K.prototype,"eApplyFilterButton",2),I([(0,r.PIB)("eCancelFilterButton")],K.prototype,"eCancelFilterButton",2),I([(0,r.dsm)("filterManager")],K.prototype,"filterManager",2),I([(0,r.dsm)("advancedFilterService")],K.prototype,"advancedFilterService",2),I([(0,r.dsm)("advancedFilterExpressionService")],K.prototype,"advancedFilterExpressionService",2),I([(0,r.dsm)("beans")],K.prototype,"beans",2),I([r.o7C],K.prototype,"postConstruct",1);var $=class e extends r.XQb{constructor(e){super(),this.enabled=e}postConstruct(){this.hasAdvancedFilterParent=!!this.gos.get("advancedFilterParent"),this.ctrlsService.whenReady(()=>this.setAdvancedFilterComp()),this.addManagedListener(this.eventService,r.sVA.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,({enabled:e})=>this.onEnabledChanged(e)),this.addManagedPropertyListener("advancedFilterParent",()=>this.updateComps()),this.addDestroyFunc(()=>{this.destroyAdvancedFilterComp(),this.destroyBean(this.eBuilderComp),this.eBuilderDialog&&this.eBuilderDialog.isAlive()&&this.destroyBean(this.eBuilderDialog)})}setupHeaderComp(e){this.eHeaderComp=this.createManagedBean(new L(this.enabled&&!this.hasAdvancedFilterParent)),e.insertAdjacentElement("beforebegin",this.eHeaderComp.getGui())}focusHeaderComp(){return!!this.eHeaderComp&&(this.eHeaderComp.getFocusableElement().focus(),!0)}refreshComp(){var e,t;null==(e=this.eFilterComp)||e.refresh(),null==(t=this.eHeaderComp)||t.refresh()}refreshBuilderComp(){var e;null==(e=this.eBuilderComp)||e.refresh()}getHeaderHeight(){var e,t;return null!=(t=null==(e=this.eHeaderComp)?void 0:e.getHeight())?t:0}setInputDisabled(e){var t,i;null==(t=this.eFilterComp)||t.setInputDisabled(e),null==(i=this.eHeaderComp)||i.setInputDisabled(e)}toggleFilterBuilder(t,i){if(i&&this.eBuilderDialog||!1===i&&!this.eBuilderDialog)return;if(this.eBuilderDialog)return this.builderDestroySource=t,void this.destroyBean(this.eBuilderDialog);this.setInputDisabled(!0);const{width:n,height:s,minWidth:o}=this.getBuilderDialogSize();this.eBuilderComp=this.createBean(new K),this.eBuilderDialog=this.createBean(new r.fNJ({title:this.advancedFilterExpressionService.translate("advancedFilterBuilderTitle"),component:this.eBuilderComp,width:n,height:s,resizable:!0,movable:!0,maximizable:!0,centered:!0,closable:!0,minWidth:o,afterGuiAttached:()=>{var e;return null==(e=this.eBuilderComp)?void 0:e.afterGuiAttached()}})),this.dispatchFilterBuilderVisibleChangedEvent(t,!0),this.eBuilderDialog.addEventListener(r.fNJ.EVENT_DESTROYED,()=>{var t;this.destroyBean(this.eBuilderComp),this.eBuilderComp=void 0,this.eBuilderDialog=void 0,this.setInputDisabled(!1),this.dispatchEvent({type:e.EVENT_BUILDER_CLOSED}),this.dispatchFilterBuilderVisibleChangedEvent(null!=(t=this.builderDestroySource)?t:"ui",!1),this.builderDestroySource=void 0})}dispatchFilterBuilderVisibleChangedEvent(e,t){const i={type:r.sVA.EVENT_ADVANCED_FILTER_BUILDER_VISIBLE_CHANGED,source:e,visible:t};this.eventService.dispatchEvent(i)}getBuilderDialogSize(){var e,t;const i=null!=(t=null==(e=this.gos.get("advancedFilterBuilderParams"))?void 0:e.minWidth)?t:500,n=this.popupService.getPopupParent(),s=Math.round(r._.getAbsoluteWidth(n))-2,o=Math.round(.75*r._.getAbsoluteHeight(n))-2;return{width:Math.min(Math.max(600,i),s),height:Math.min(600,o),minWidth:i}}onEnabledChanged(e){this.enabled=e,this.updateComps()}updateComps(){this.setAdvancedFilterComp(),this.setHeaderCompEnabled(),this.eventService.dispatchEvent({type:r.sVA.EVENT_HEADER_HEIGHT_CHANGED})}setAdvancedFilterComp(){if(this.destroyAdvancedFilterComp(),!this.enabled)return;const e=this.gos.get("advancedFilterParent");if(this.hasAdvancedFilterParent=!!e,e){const t=this.createBean(new Y),i=t.getGui(),{allThemes:r}=this.environment.getTheme();r.length&&i.classList.add(...r),i.classList.add(this.gos.get("enableRtl")?"ag-rtl":"ag-ltr"),e.appendChild(i),this.eFilterComp=t}}setHeaderCompEnabled(){var e;null==(e=this.eHeaderComp)||e.setEnabled(this.enabled&&!this.hasAdvancedFilterParent)}destroyAdvancedFilterComp(){this.eFilterComp&&(r._.removeFromParent(this.eFilterComp.getGui()),this.destroyBean(this.eFilterComp))}};$.EVENT_BUILDER_CLOSED="advancedFilterBuilderClosed",I([(0,r.dsm)("focusService")],$.prototype,"focusService",2),I([(0,r.dsm)("ctrlsService")],$.prototype,"ctrlsService",2),I([(0,r.dsm)("popupService")],$.prototype,"popupService",2),I([(0,r.dsm)("advancedFilterExpressionService")],$.prototype,"advancedFilterExpressionService",2),I([r.o7C],$.prototype,"postConstruct",1);var q=$,Y=class extends r.uAl{constructor(){super('\n            <div class="ag-advanced-filter" role="presentation" tabindex="-1">\n                <ag-autocomplete ref="eAutocomplete"></ag-autocomplete>\n                <button class="ag-button ag-standard-button ag-advanced-filter-apply-button" ref="eApplyFilterButton"></button>\n                <button class="ag-advanced-filter-builder-button" ref="eBuilderFilterButton">\n                    <span ref="eBuilderFilterButtonIcon" aria-hidden="true"></span>\n                    <span class="ag-advanced-filter-builder-button-label" ref="eBuilderFilterButtonLabel"></span>\n                </button>\n            </div>'),this.expressionParser=null,this.isApplyDisabled=!0,this.builderOpen=!1}postConstruct(){this.eAutocomplete.setListGenerator((e,t)=>this.generateAutocompleteListParams(t)).setValidator(()=>this.validateValue()).setForceLastSelection((e,t)=>this.forceLastSelection(e,t)).setInputAriaLabel(this.advancedFilterExpressionService.translate("ariaAdvancedFilterInput")).setListAriaLabel(this.advancedFilterExpressionService.translate("ariaLabelAdvancedFilterAutocomplete")),this.refresh(),this.addManagedListener(this.eAutocomplete,r.bB5.EVENT_VALUE_CHANGED,({value:e})=>this.onValueChanged(e)),this.addManagedListener(this.eAutocomplete,r.bB5.EVENT_VALUE_CONFIRMED,({isValid:e})=>this.onValueConfirmed(e)),this.addManagedListener(this.eAutocomplete,r.bB5.EVENT_OPTION_SELECTED,({position:e,updateEntry:t,autocompleteType:i})=>this.onOptionSelected(e,t,i)),this.addManagedListener(this.eAutocomplete,r.bB5.EVENT_VALID_CHANGED,({isValid:e,validationMessage:t})=>this.onValidChanged(e,t)),this.setupApplyButton(),this.setupBuilderButton()}refresh(){const e=this.advancedFilterService.getExpressionDisplayValue();this.eAutocomplete.setValue({value:null!=e?e:"",position:null==e?void 0:e.length,updateListOnlyIfOpen:!0})}setInputDisabled(e){this.eAutocomplete.setInputDisabled(e),r._.setDisabled(this.eApplyFilterButton,e||this.isApplyDisabled)}getTooltipParams(){const e=super.getTooltipParams();return e.location="advancedFilter",e}setupApplyButton(){this.eApplyFilterButton.innerText=this.advancedFilterExpressionService.translate("advancedFilterApply"),this.activateTabIndex([this.eApplyFilterButton]),this.addManagedListener(this.eApplyFilterButton,"click",()=>this.onValueConfirmed(this.eAutocomplete.isValid())),r._.setDisabled(this.eApplyFilterButton,this.isApplyDisabled)}setupBuilderButton(){this.eBuilderFilterButtonIcon.appendChild(r._.createIconNoSpan("advancedFilterBuilder",this.gos)),this.eBuilderFilterButtonLabel.innerText=this.advancedFilterExpressionService.translate("advancedFilterBuilder"),this.activateTabIndex([this.eBuilderFilterButton]),this.addManagedListener(this.eBuilderFilterButton,"click",()=>this.openBuilder()),this.addManagedListener(this.advancedFilterService.getCtrl(),q.EVENT_BUILDER_CLOSED,()=>this.closeBuilder())}onValueChanged(e){var t;e=r._.makeNull(e),this.advancedFilterService.setExpressionDisplayValue(e),this.expressionParser=this.advancedFilterService.createExpressionParser(e);const i=null==(t=this.expressionParser)?void 0:t.parseExpression();i&&i!==e&&this.eAutocomplete.setValue({value:i,silent:!0,restoreFocus:!0})}onValueConfirmed(e){e&&!this.isApplyDisabled&&(r._.setDisabled(this.eApplyFilterButton,!0),this.advancedFilterService.applyExpression(),this.filterManager.onFilterChanged({source:"advancedFilter"}))}onOptionSelected(e,t,i){const{updatedValue:r,updatedPosition:n,hideAutocomplete:s}=this.updateExpression(e,t,i);this.eAutocomplete.setValue({value:r,position:n,updateListOnlyIfOpen:s,restoreFocus:!0})}validateValue(){var e,t,i;return(null==(e=this.expressionParser)?void 0:e.isValid())?null:null!=(i=null==(t=this.expressionParser)?void 0:t.getValidationMessage())?i:null}onValidChanged(e,t){this.isApplyDisabled=!e||this.advancedFilterService.isCurrentExpressionApplied(),r._.setDisabled(this.eApplyFilterButton,this.isApplyDisabled),this.setTooltip({newTooltipText:t,showDelayOverride:1e3})}generateAutocompleteListParams(e){return this.expressionParser?this.expressionParser.getAutocompleteListParams(e):this.advancedFilterExpressionService.getDefaultAutocompleteListParams("")}updateExpression(e,t,i){var r,n;return this.advancedFilterExpressionService.updateAutocompleteCache(t,i),null!=(n=null==(r=this.expressionParser)?void 0:r.updateExpression(e,t,i))?n:this.advancedFilterService.getDefaultExpression(t)}forceLastSelection({key:e,displayValue:t},i){return!!i.toLocaleLowerCase().match(`^${(null!=t?t:e).toLocaleLowerCase()}\\s*$`)}openBuilder(){this.builderOpen||(this.builderOpen=!0,r._.setDisabled(this.eBuilderFilterButton,!0),this.advancedFilterService.getCtrl().toggleFilterBuilder("ui"))}closeBuilder(){this.builderOpen&&(this.builderOpen=!1,r._.setDisabled(this.eBuilderFilterButton,!1),this.eBuilderFilterButton.focus())}};I([(0,r.PIB)("eAutocomplete")],Y.prototype,"eAutocomplete",2),I([(0,r.PIB)("eApplyFilterButton")],Y.prototype,"eApplyFilterButton",2),I([(0,r.PIB)("eBuilderFilterButton")],Y.prototype,"eBuilderFilterButton",2),I([(0,r.PIB)("eBuilderFilterButtonIcon")],Y.prototype,"eBuilderFilterButtonIcon",2),I([(0,r.PIB)("eBuilderFilterButtonLabel")],Y.prototype,"eBuilderFilterButtonLabel",2),I([(0,r.dsm)("advancedFilterService")],Y.prototype,"advancedFilterService",2),I([(0,r.dsm)("advancedFilterExpressionService")],Y.prototype,"advancedFilterExpressionService",2),I([(0,r.dsm)("filterManager")],Y.prototype,"filterManager",2),I([r.o7C],Y.prototype,"postConstruct",1);var Q={ariaAdvancedFilterBuilderItem:e=>`${e[0]}. Level ${e[1]}. Press ENTER to edit.`,ariaAdvancedFilterBuilderItemValidation:e=>`${e[0]}. Level ${e[1]}. ${e[2]} Press ENTER to edit.`,ariaAdvancedFilterBuilderList:"Advanced Filter Builder List",ariaAdvancedFilterBuilderFilterItem:"Filter Condition",ariaAdvancedFilterBuilderGroupItem:"Filter Group",ariaAdvancedFilterBuilderColumn:"Column",ariaAdvancedFilterBuilderOption:"Option",ariaAdvancedFilterBuilderValue:"Value",ariaAdvancedFilterBuilderJoinOperator:"Join Operator",ariaAdvancedFilterInput:"Advanced Filter Input",ariaLabelAdvancedFilterAutocomplete:"Advanced Filter Autocomplete",advancedFilterContains:"contains",advancedFilterNotContains:"does not contain",advancedFilterTextEquals:"equals",advancedFilterTextNotEqual:"does not equal",advancedFilterStartsWith:"begins with",advancedFilterEndsWith:"ends with",advancedFilterBlank:"is blank",advancedFilterNotBlank:"is not blank",advancedFilterEquals:"=",advancedFilterNotEqual:"!=",advancedFilterGreaterThan:">",advancedFilterGreaterThanOrEqual:">=",advancedFilterLessThan:"<",advancedFilterLessThanOrEqual:"<=",advancedFilterTrue:"is true",advancedFilterFalse:"is false",advancedFilterAnd:"AND",advancedFilterOr:"OR",advancedFilterApply:"Apply",advancedFilterBuilder:"Builder",advancedFilterValidationMissingColumn:"Column is missing",advancedFilterValidationMissingOption:"Option is missing",advancedFilterValidationMissingValue:"Value is missing",advancedFilterValidationInvalidColumn:"Column not found",advancedFilterValidationInvalidOption:"Option not found",advancedFilterValidationMissingQuote:"Value is missing an end quote",advancedFilterValidationNotANumber:"Value is not a number",advancedFilterValidationInvalidDate:"Value is not a valid date",advancedFilterValidationMissingCondition:"Condition is missing",advancedFilterValidationJoinOperatorMismatch:"Join operators within a condition must be the same",advancedFilterValidationInvalidJoinOperator:"Join operator not found",advancedFilterValidationMissingEndBracket:"Missing end bracket",advancedFilterValidationExtraEndBracket:"Too many end brackets",advancedFilterValidationMessage:e=>`Expression has an error. ${e[0]} - ${e[1]}.`,advancedFilterValidationMessageAtEnd:e=>`Expression has an error. ${e[0]} at end of expression.`,advancedFilterBuilderTitle:"Advanced Filter",advancedFilterBuilderApply:"Apply",advancedFilterBuilderCancel:"Cancel",advancedFilterBuilderAddButtonTooltip:"Add Filter or Group",advancedFilterBuilderRemoveButtonTooltip:"Remove",advancedFilterBuilderMoveUpButtonTooltip:"Move Up",advancedFilterBuilderMoveDownButtonTooltip:"Move Down",advancedFilterBuilderAddJoin:"Add Group",advancedFilterBuilderAddCondition:"Add Filter",advancedFilterBuilderSelectColumn:"Select a column",advancedFilterBuilderSelectOption:"Select an option",advancedFilterBuilderEnterValue:"Enter a value...",advancedFilterBuilderValidationAlreadyApplied:"Current filter already applied.",advancedFilterBuilderValidationIncomplete:"Not all conditions are complete.",advancedFilterBuilderValidationSelectColumn:"Must select a column.",advancedFilterBuilderValidationSelectOption:"Must select an option.",advancedFilterBuilderValidationEnterValue:"Must enter a value."};function X(e,t,i){if(!e)return"";const r=i-t;return r?e.slice(0,e.length-r):e}function Z(e,t,i,r,n,s,o){const a=i+(!e.length||o?0:1);let l=0;return n&&(" "===e[a]?l=1:(r+=" ",s&&(r+='"'))),{updatedValue:e.slice(0,t)+r+e.slice(a),updatedPosition:t+r.length+l}}function J(e,t,i,r){let n=t,s=!1;for(;n<e.length;){const t=e[n];if("("===t){r&&" "===e[n-1]?s=!0:n-=1;break}if(" "===t||i&&")"===t){n-=1;break}n++}return{endPosition:n,isEmpty:s}}function ee(e,t,i,r){i!==t&&(e.expression=Z(e.expression,r-t.length+1,r,i).updatedValue)}var te=class{constructor(e,t){this.params=e,this.startPosition=t,this.type="column",this.valid=!0,this.hasStartChar=!1,this.hasEndChar=!1,this.colName=""}parse(e,t){if(e!==ne.COL_START_CHAR||this.colName)if(e===ne.COL_END_CHAR&&this.hasStartChar){if(this.parseColumn(!1,t))return this.hasEndChar=!0,!1;this.colName+=e}else this.colName+=e;else this.hasStartChar=!0}getDisplayValue(){return(this.hasStartChar?ne.COL_START_CHAR:"")+this.colName+(this.hasEndChar?ne.COL_END_CHAR:"")}getColId(){return this.colId}complete(e){this.parseColumn(!0,e)}getValidationError(){var e;return this.valid?null:{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidColumn"),startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}}parseColumn(e,t){var i;this.endPosition=t;const r=this.params.advancedFilterExpressionService.getColId(this.colName);return r&&this.hasStartChar&&(this.colId=r.colId,ee(this.params,this.colName,r.columnName,t-1),this.colName=r.columnName,this.column=this.params.columnModel.getPrimaryColumn(this.colId),this.column)?(this.baseCellDataType=null!=(i=this.params.dataTypeService.getBaseDataType(this.column))?i:"text",!0):(e&&(this.valid=!1),this.baseCellDataType="text",!1)}},ie=class{constructor(e,t,i){this.params=e,this.startPosition=t,this.baseCellDataType=i,this.type="operator",this.valid=!0,this.expectedNumOperands=0,this.operator=""}parse(e,t){if(" "===e||")"===e){if(this.parseOperator(!1,t-1))return!0;this.operator+=e}else this.operator+=e}complete(e){this.parseOperator(!0,e)}getValidationError(){var e;return this.valid?null:{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidOption"),startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}}getDisplayValue(){return this.operator}getOperatorKey(){return this.parsedOperator}parseOperator(e,t){const i=this.params.advancedFilterExpressionService.getDataTypeExpressionOperator(this.baseCellDataType),r=i.findOperator(this.operator);if(this.endPosition=t,r){this.parsedOperator=r;const e=i.operators[r];this.expectedNumOperands=e.numOperands;const n=e.displayValue;return ee(this.params,this.operator,n,t),this.operator=n,!0}return!e&&null===r||(this.valid=!1),!1}},re=class{constructor(e,t,i,r){this.params=e,this.startPosition=t,this.baseCellDataType=i,this.column=r,this.type="operand",this.valid=!0,this.operand="",this.validationMessage=null}parse(e,t){if(" "===e){if(!this.quotes)return this.parseOperand(!1,t),!0;this.operand+=e}else if(")"===e){if("number"===this.baseCellDataType||!this.quotes)return this.parseOperand(!1,t-1),!0;this.operand+=e}else if(this.operand||this.quotes||"'"!==e&&'"'!==e){if(this.quotes&&e===this.quotes)return this.parseOperand(!1,t),!1;this.operand+=e}else this.quotes=e}complete(e){this.parseOperand(!0,e)}getValidationError(){var e;return this.validationMessage?{message:this.validationMessage,startPosition:this.startPosition,endPosition:null!=(e=this.endPosition)?e:this.params.expression.length-1}:null}getRawValue(){return this.operand}getModelValue(){return this.modelValue}parseOperand(e,t){const{advancedFilterExpressionService:i}=this.params;if(this.endPosition=t,this.modelValue=this.operand,e&&this.quotes)this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationMissingQuote");else if(""===this.modelValue)this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationMissingValue");else{const e=i.getOperandModelValue(this.operand,this.baseCellDataType,this.column);switch(null!=e&&(this.modelValue=e),this.baseCellDataType){case"number":(this.quotes||isNaN(this.modelValue))&&(this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationNotANumber"));break;case"date":case"dateString":null==e&&(this.valid=!1,this.validationMessage=i.translate("advancedFilterValidationInvalidDate"))}}}},ne=class{constructor(e,t){this.params=e,this.startPosition=t,this.isAwaiting=!0}parseExpression(){var e,t;let i=this.startPosition;const{expression:r}=this.params;for(;i<r.length;){const e=r[i];if(" "===e&&this.isAwaiting);else{if(this.isAwaiting=!1,!this.parser){let e;this.columnParser?this.operatorParser?(this.operandParser=new re(this.params,i,this.columnParser.baseCellDataType,this.columnParser.column),e=this.operandParser):(this.operatorParser=new ie(this.params,i,this.columnParser.baseCellDataType),e=this.operatorParser):(this.columnParser=new te(this.params,i),e=this.columnParser),this.parser=e}const t=this.parser.parse(e,i);if(null!=t){if(this.isComplete())return this.returnEndPosition(t?i-1:i,!0);this.parser=void 0,this.isAwaiting=!0}}i++}return null==(t=null==(e=this.parser)?void 0:e.complete)||t.call(e,i-1),this.returnEndPosition(i)}isValid(){return this.isComplete()&&this.columnParser.valid&&this.operatorParser.valid&&(!this.operandParser||this.operandParser.valid)}getValidationError(){var e,t,i,r,n;const s=null!=(n=null!=(i=null==(e=this.columnParser)?void 0:e.getValidationError())?i:null==(t=this.operatorParser)?void 0:t.getValidationError())?n:null==(r=this.operandParser)?void 0:r.getValidationError();if(s)return s;const o=this.params.expression.length;let a;return this.columnParser?this.operatorParser?this.operatorParser.expectedNumOperands&&!this.operandParser&&(a="advancedFilterValidationMissingValue"):a="advancedFilterValidationMissingOption":a="advancedFilterValidationMissingColumn",a?{message:this.params.advancedFilterExpressionService.translate(a),startPosition:o,endPosition:o}:null}getFunctionString(e){return this.getFunctionCommon(e,(e,t,i,r)=>`params.operators[${t}].evaluator(expressionProxy.getValue('${i.replace(/(['"])/,"\\$1")}', node), node, params.evaluatorParams[${r}]${null==e?"":`, params.operands[${e}]`})`)}getFunctionParsed(e){return this.getFunctionCommon(e,(e,t,i,r)=>(n,s,o)=>o.operators[t].evaluator(n.getValue(i,s),s,o.evaluatorParams[r],null==e?void 0:o.operands[e]))}getAutocompleteListParams(e){return this.isColumnPosition(e)?this.getColumnAutocompleteListParams(e):this.isOperatorPosition(e)?this.getOperatorAutocompleteListParams(e):this.isBeyondEndPosition(e)?void 0:{enabled:!1}}updateExpression(e,t,i){var r,n,s,o,a;const{expression:l}=this.params;if(this.isColumnPosition(e))return Z(this.params.expression,this.startPosition,(null==(r=this.columnParser)?void 0:r.getColId())?this.columnParser.endPosition:J(l,e).endPosition,this.params.advancedFilterExpressionService.getColumnValue(t),!0);if(this.isOperatorPosition(e)){const r=this.getBaseCellDataTypeFromOperatorAutocompleteType(i),c=this.hasOperand(r,t.key),u=c&&this.doesOperandNeedQuotes(r);let h;if(null!=(null==(n=this.operatorParser)?void 0:n.startPosition)&&e<this.operatorParser.startPosition)h=Z(l,e,e,null!=(s=t.displayValue)?s:t.key,c,u);else{let i,r=!1;if(null==(o=this.operatorParser)?void 0:o.getOperatorKey())i=this.operatorParser.endPosition;else{const{endPosition:t,isEmpty:n}=J(l,e,!0,!0);i=t,r=n}h=Z(l,function(e,t,i){let r=t;for(;r<i&&" "===e[r];)r++;return r}(l,this.columnParser.endPosition+1,i),i,null!=(a=t.displayValue)?a:t.key,c,u,r)}return D(x({},h),{hideAutocomplete:!c})}return null}getModel(){const e=this.columnParser.getColId(),t={filterType:this.columnParser.baseCellDataType,colId:e,type:this.operatorParser.getOperatorKey()};return this.operatorParser.expectedNumOperands&&(t.filter=this.operandParser.getModelValue()),t}getFunctionCommon(e,t){var i,r;const n=this.columnParser.getColId(),s=null==(i=this.operatorParser)?void 0:i.getOperatorKey(),{operators:o,evaluatorParams:a,operands:l}=e,c=this.params.advancedFilterExpressionService.getExpressionOperator(this.columnParser.baseCellDataType,s),u=this.addToListAndGetIndex(o,c),h=this.params.advancedFilterExpressionService.getExpressionEvaluatorParams(n),d=this.addToListAndGetIndex(a,h);return t(0===(null==(r=this.operatorParser)?void 0:r.expectedNumOperands)?void 0:this.addToListAndGetIndex(l,this.getOperandValue()),u,n,d)}getOperandValue(){let e=this.operandParser.getRawValue();const{baseCellDataType:t,column:i}=this.columnParser;switch(t){case"number":e=Number(e);break;case"date":case"dateString":e=this.params.valueService.parseValue(i,null,e,void 0)}return"dateString"===t?this.params.dataTypeService.getDateParserFunction(i)(e):e}isComplete(){return!(!this.operatorParser||!(!this.operatorParser.expectedNumOperands||this.operatorParser.expectedNumOperands&&this.operandParser))}isColumnPosition(e){return!this.columnParser||null==this.columnParser.endPosition||e<=this.columnParser.endPosition+1}isOperatorPosition(e){return!this.operatorParser||null==this.operatorParser.endPosition||e<=this.operatorParser.endPosition+1}isBeyondEndPosition(e){return this.isComplete()&&null!=this.endPosition&&e>this.endPosition+1&&this.endPosition+1<this.params.expression.length}returnEndPosition(e,t){return this.endPosition=t?e:e-1,e}getColumnAutocompleteListParams(e){return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getColumnAutocompleteEntries(),"column",this.getColumnSearchString(e))}getColumnSearchString(e){var t,i,r,n,s;const o=null!=(i=null==(t=this.columnParser)?void 0:t.getDisplayValue())?i:"",a=X(o,e,null==(null==(r=this.columnParser)?void 0:r.endPosition)?this.params.expression.length:this.columnParser.endPosition+1),l=(null==(n=this.columnParser)?void 0:n.hasStartChar)&&a.length>0,c=(null==(s=this.columnParser)?void 0:s.hasEndChar)&&a.length===o.length+2;return l?a.slice(1,c?-1:void 0):a}getOperatorAutocompleteListParams(e){var t,i,r,n,s;const o=null==(t=this.columnParser)?void 0:t.column;if(!o)return{enabled:!1};const a=this.columnParser.baseCellDataType,l=null!=(null==(i=this.operatorParser)?void 0:i.startPosition)&&e<this.operatorParser.startPosition?"":X(null!=(n=null==(r=this.operatorParser)?void 0:r.getDisplayValue())?n:"",e,null==(null==(s=this.operatorParser)?void 0:s.endPosition)?this.params.expression.length:this.operatorParser.endPosition+1);return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getOperatorAutocompleteEntries(o,a),`operator-${a}`,l)}getBaseCellDataTypeFromOperatorAutocompleteType(e){return null==e?void 0:e.replace("operator-","")}hasOperand(e,t){var i,r;return!e||!t||(null!=(r=null==(i=this.params.advancedFilterExpressionService.getExpressionOperator(e,t))?void 0:i.numOperands)?r:0)>0}doesOperandNeedQuotes(e){return"number"!==e}addToListAndGetIndex(e,t){const i=e.length;return e.push(t),i}};function se(e,t,i){let r=!1;const n=e.toLocaleLowerCase(),s=n+" ",o=Object.entries(t).find(([e,t])=>{const o=i(t).toLocaleLowerCase();return o.startsWith(s)&&(r=!0),o===n});return o?o[0]:r?null:void 0}function oe(e,t){return(null!=t?t:Object.keys(e)).map(t=>({key:t,displayValue:e[t].displayValue}))}ne.COL_START_CHAR="[",ne.COL_END_CHAR="]";var ae=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return oe(this.operators,e)}findOperator(e){return se(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e}=this.params;this.operators={contains:{displayValue:e("advancedFilterContains"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.includes(t)),numOperands:1},notContains:{displayValue:e("advancedFilterNotContains"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!0,(e,t)=>!e.includes(t)),numOperands:1},equals:{displayValue:e("advancedFilterTextEquals"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e===t),numOperands:1},notEqual:{displayValue:e("advancedFilterTextNotEqual"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!0,(e,t)=>e!=t),numOperands:1},startsWith:{displayValue:e("advancedFilterStartsWith"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.startsWith(t)),numOperands:1},endsWith:{displayValue:e("advancedFilterEndsWith"),evaluator:(e,t,i,r)=>this.evaluateExpression(e,t,i,r,!1,(e,t)=>e.endsWith(t)),numOperands:1},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e||"string"==typeof e&&0===e.trim().length,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e&&("string"!=typeof e||e.trim().length>0),numOperands:0}}}evaluateExpression(e,t,i,r,n,s){return null==e?n:i.caseSensitive?s(i.valueConverter(e,t),r):s(i.valueConverter(e,t).toLocaleLowerCase(),r.toLocaleLowerCase())}},le=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return oe(this.operators,e)}findOperator(e){return se(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e,equals:t}=this.params;this.operators={equals:{displayValue:e("advancedFilterEquals"),evaluator:(e,i,r,n)=>this.evaluateSingleOperandExpression(e,i,r,n,!!r.includeBlanksInEquals,t),numOperands:1},notEqual:{displayValue:e("advancedFilterNotEqual"),evaluator:(e,i,r,n)=>this.evaluateSingleOperandExpression(e,i,r,n,!!r.includeBlanksInEquals,(e,i)=>!t(e,i)),numOperands:1},greaterThan:{displayValue:e("advancedFilterGreaterThan"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInGreaterThan,(e,t)=>e>t),numOperands:1},greaterThanOrEqual:{displayValue:e("advancedFilterGreaterThanOrEqual"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInGreaterThan,(e,t)=>e>=t),numOperands:1},lessThan:{displayValue:e("advancedFilterLessThan"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInLessThan,(e,t)=>e<t),numOperands:1},lessThanOrEqual:{displayValue:e("advancedFilterLessThanOrEqual"),evaluator:(e,t,i,r)=>this.evaluateSingleOperandExpression(e,t,i,r,!!i.includeBlanksInLessThan,(e,t)=>e<=t),numOperands:1},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e,numOperands:0}}}evaluateSingleOperandExpression(e,t,i,r,n,s){return null==e?n:s(i.valueConverter(e,t),r)}},ce=class{constructor(e){this.params=e,this.initOperators()}getEntries(e){return oe(this.operators,e)}findOperator(e){return se(e,this.operators,({displayValue:e})=>e)}initOperators(){const{translate:e}=this.params;this.operators={true:{displayValue:e("advancedFilterTrue"),evaluator:e=>!!e,numOperands:0},false:{displayValue:e("advancedFilterFalse"),evaluator:e=>!1===e,numOperands:0},blank:{displayValue:e("advancedFilterBlank"),evaluator:e=>null==e,numOperands:0},notBlank:{displayValue:e("advancedFilterNotBlank"),evaluator:e=>null!=e,numOperands:0}}}},ue=class extends r.XQb{constructor(){super(...arguments),this.columnNameToIdMap={},this.columnAutocompleteEntries=null,this.expressionEvaluatorParams={}}postConstruct(){this.expressionJoinOperators=this.generateExpressionJoinOperators(),this.expressionOperators=this.generateExpressionOperators()}parseJoinOperator(e){var t;const{type:i}=e;return null!=(t=this.expressionJoinOperators[i])?t:i}getColumnDisplayValue(e){const{colId:t}=e,i=this.getColumnAutocompleteEntries().find(({key:e})=>e===t);let r;return i?(r=i.displayValue,this.columnNameToIdMap[r.toLocaleUpperCase()]={colId:t,columnName:r}):r=t,r}getOperatorDisplayValue(e){var t,i;return null!=(i=null==(t=this.getExpressionOperator(e.filterType,e.type))?void 0:t.displayValue)?i:e.type}getOperandModelValue(e,t,i){var n;switch(t){case"number":return r._.exists(e)?Number(e):null;case"date":return r._.serialiseDate(this.valueService.parseValue(i,null,e,void 0),!1);case"dateString":const t=this.valueService.parseValue(i,null,e,void 0);return r._.serialiseDate(null!=(n=this.dataTypeService.getDateParserFunction(i)(t))?n:null,!1)}return e}getOperandDisplayValue(e,t){var i,n;const{colId:s,filter:o}=e,a=this.columnModel.getPrimaryColumn(s);let l="";if(null!=o){let s;switch(e.filterType){case"number":s=null!=(i=r._.toStringOrNull(o))?i:"";break;case"date":const e=r._.parseDateTimeFromString(o);s=a?this.valueService.formatValue(a,null,e):null;break;case"dateString":const t=r._.parseDateTimeFromString(o),n=a?this.dataTypeService.getDateFormatterFunction(a)(null!=t?t:void 0):null;s=a?this.valueService.formatValue(a,null,n):null}"number"!==e.filterType&&(s=null!=(n=null!=s?s:r._.toStringOrNull(o))?n:"",t||(s=`"${s}"`)),l=t?s:` ${s}`}return l}parseColumnFilterModel(e){var t,i;return`[${null!=(t=this.getColumnDisplayValue(e))?t:""}] ${null!=(i=this.getOperatorDisplayValue(e))?i:""}${this.getOperandDisplayValue(e)}`}updateAutocompleteCache(e,t){if("column"===t){const{key:t,displayValue:i}=e;this.columnNameToIdMap[e.displayValue.toLocaleUpperCase()]={colId:t,columnName:i}}}translate(e,t){let i=Q[e];return"function"==typeof i&&(i=i(t)),this.localeService.getLocaleTextFunc()(e,i,t)}generateAutocompleteListParams(e,t,i){return{enabled:!0,type:t,searchString:i,entries:e}}getColumnAutocompleteEntries(){var e;if(this.columnAutocompleteEntries)return this.columnAutocompleteEntries;const t=null!=(e=this.columnModel.getAllPrimaryColumns())?e:[],i=[],r=this.gos.get("includeHiddenColumnsInAdvancedFilter");return t.forEach(e=>{e.getColDef().filter&&(r||e.isVisible()||e.isRowGroupActive())&&i.push({key:e.getColId(),displayValue:this.columnModel.getDisplayNameForColumn(e,"advancedFilter")})}),i.sort((e,t)=>{var i,r;const n=null!=(i=e.displayValue)?i:"",s=null!=(r=t.displayValue)?r:"";return n<s?-1:s>n?1:0}),i}getOperatorAutocompleteEntries(e,t){const i=this.getActiveOperators(e);return this.getDataTypeExpressionOperator(t).getEntries(i)}getJoinOperatorAutocompleteEntries(){return Object.entries(this.expressionJoinOperators).map(([e,t])=>({key:e,displayValue:t}))}getDefaultAutocompleteListParams(e){return this.generateAutocompleteListParams(this.getColumnAutocompleteEntries(),"column",e)}getDataTypeExpressionOperator(e){return this.expressionOperators[e]}getExpressionOperator(e,t){var i,r;return null==(r=null==(i=this.getDataTypeExpressionOperator(e))?void 0:i.operators)?void 0:r[t]}getExpressionJoinOperators(){return this.expressionJoinOperators}getColId(e){const t=e.toLocaleUpperCase(),i=this.columnNameToIdMap[t];if(i)return i;const r=this.getColumnAutocompleteEntries().find(({displayValue:e})=>e.toLocaleUpperCase()===t);if(r){const{key:e,displayValue:i}=r,n={colId:e,columnName:i};return this.columnNameToIdMap[t]=n,n}return null}getExpressionEvaluatorParams(e){let t=this.expressionEvaluatorParams[e];if(t)return t;const i=this.columnModel.getPrimaryColumn(e);if(!i)return{valueConverter:e=>e};switch(this.dataTypeService.getBaseDataType(i)){case"dateString":t={valueConverter:this.dataTypeService.getDateParserFunction(i)};break;case"object":t=i.getColDef().filterValueGetter?{valueConverter:e=>e}:{valueConverter:(e,t)=>{var r;return null!=(r=this.valueService.formatValue(i,t,e))?r:"function"==typeof e.toString?e.toString():""}};break;case"text":case void 0:t={valueConverter:e=>r._.toStringOrNull(e)};break;default:t={valueConverter:e=>e}}const{filterParams:n}=i.getColDef();return n&&["caseSensitive","includeBlanksInEquals","includeBlanksInLessThan","includeBlanksInGreaterThan"].forEach(e=>{const i=n[e];i&&(t[e]=i)}),this.expressionEvaluatorParams[e]=t,t}getColumnDetails(e){var t,i;const r=null!=(t=this.columnModel.getPrimaryColumn(e))?t:void 0;return{column:r,baseCellDataType:null!=(i=r?this.dataTypeService.getBaseDataType(r):void 0)?i:"text"}}generateExpressionOperators(){const e=(e,t)=>this.translate(e,t);return{text:new ae({translate:e}),boolean:new ce({translate:e}),object:new ae({translate:e}),number:new le({translate:e,equals:(e,t)=>e===t}),date:new le({translate:e,equals:(e,t)=>e.getTime()===t.getTime()}),dateString:new le({translate:e,equals:(e,t)=>e.getTime()===t.getTime()})}}getColumnValue({displayValue:e}){return`${ne.COL_START_CHAR}${e}${ne.COL_END_CHAR}`}generateExpressionJoinOperators(){return{AND:this.translate("advancedFilterAnd"),OR:this.translate("advancedFilterOr")}}getActiveOperators(e){var t;const i=null==(t=e.getColDef().filterParams)?void 0:t.filterOptions;if(i)return i.every(e=>"string"==typeof e)?i:void 0}resetColumnCaches(){this.columnAutocompleteEntries=null,this.columnNameToIdMap={},this.expressionEvaluatorParams={}}};I([(0,r.dsm)("valueService")],ue.prototype,"valueService",2),I([(0,r.dsm)("columnModel")],ue.prototype,"columnModel",2),I([(0,r.dsm)("dataTypeService")],ue.prototype,"dataTypeService",2),I([r.o7C],ue.prototype,"postConstruct",1),ue=I([(0,r.dR4)("advancedFilterExpressionService")],ue);var he=class{constructor(e){this.params=e,this.operators=[],this.operatorStartPositions=[],this.operatorEndPositions=[],this.activeOperator=0,this.validationError=null}parseExpression(e){this.operators.push(""),this.operatorStartPositions.push(e),this.operatorEndPositions.push(void 0);const{expression:t}=this.params;for(;e<t.length;){const i=t[e];if(" "===i){if(this.parseOperator(e-1))return this.activeOperator++,e-1;this.operators[this.activeOperator]+=i}else this.operators[this.activeOperator]+=i;e++}return this.parseOperator(e-1),e}isValid(){return!(this.validationError||this.operators.length&&!this.parsedOperator)}getValidationError(){return this.validationError}getFunction(){return"OR"===this.parsedOperator?"||":"&&"}getModel(){return"OR"===this.parsedOperator?"OR":"AND"}getAutocompleteListParams(e,t){let i;if(null==t)i="";else{const r=this.operators[t],n=this.operatorEndPositions[t];i=X(r,e,null==n?this.params.expression.length:n+1)}let r=this.params.advancedFilterExpressionService.getJoinOperatorAutocompleteEntries();return(t||null==t&&this.activeOperator)&&(r=r.filter(({key:e})=>e===this.parsedOperator)),this.params.advancedFilterExpressionService.generateAutocompleteListParams(r,"join",i)}updateExpression(e,t,i){var r,n;let{expression:s}=this.params;const o=null!=(r=t.displayValue)?r:t.key;if(0===i)for(let e=this.operatorEndPositions.length-1;e>0;e--){const t=this.operatorEndPositions[e];null!=t&&(s=Z(s,this.operatorStartPositions[e],t,o).updatedValue)}return Z(s,this.operatorStartPositions.length>i?this.operatorStartPositions[i]:e,null!=(n=this.operatorEndPositions.length>i?this.operatorEndPositions[i]:void 0)?n:J(s,e,!0).endPosition,o,!0)}getNumOperators(){return this.operators.length}getLastOperatorEndPosition(){return this.operatorEndPositions[this.operatorEndPositions.length-1]}parseOperator(e){const t=this.operators.length>this.activeOperator?this.operators[this.activeOperator]:"",i=this.params.advancedFilterExpressionService.getExpressionJoinOperators(),r=se(t,i,e=>e);if(r){this.operatorEndPositions[this.activeOperator]=e;const n=i[r];if(this.activeOperator){if(r!==this.parsedOperator)return this.validationError||(this.validationError={message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationJoinOperatorMismatch"),startPosition:e-t.length+1,endPosition:e}),!1}else this.parsedOperator=r;return t!==n&&(ee(this.params,t,n,e),this.operators[this.activeOperator]=n),!0}return null!==r&&(this.validationError||(this.validationError={message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationInvalidJoinOperator"),startPosition:e-t.length+1,endPosition:e}),!0)}},de=class e{constructor(e,t){this.params=e,this.startPosition=t,this.expectingExpression=!0,this.expectingOperator=!1,this.expressionParsers=[],this.operatorParser=new he(this.params),this.missingEndBracket=!1,this.extraEndBracket=!1}parseExpression(){let t=this.startPosition;const{expression:i}=this.params;for(;t<i.length;){const r=i[t];if("("!==r||this.expectingOperator){if(")"===r)return this.endPosition=t-1,0===this.startPosition&&(this.extraEndBracket=!0),t;if(" "===r);else if(this.expectingExpression){const e=new ne(this.params,t);t=e.parseExpression(),this.expressionParsers.push(e),this.expectingExpression=!1,this.expectingOperator=!0}else this.expectingOperator&&(t=this.operatorParser.parseExpression(t),this.expectingOperator=!1,this.expectingExpression=!0)}else{const i=new e(this.params,t+1);t=i.parseExpression(),this.expressionParsers.push(i),this.expectingExpression=!1,this.expectingOperator=!0}t++}return this.startPosition>0&&(this.missingEndBracket=!0),t}isValid(){return!this.missingEndBracket&&!this.extraEndBracket&&this.expressionParsers.length===this.operatorParser.getNumOperators()+1&&this.operatorParser.isValid()&&this.expressionParsers.every(e=>e.isValid())}getValidationError(){const e=this.operatorParser.getValidationError();for(let t=0;t<this.expressionParsers.length;t++){const i=this.expressionParsers[t].getValidationError();if(i)return e&&e.startPosition<i.startPosition?e:i}if(e)return e;if(this.extraEndBracket)return{message:this.params.advancedFilterExpressionService.translate("advancedFilterValidationExtraEndBracket"),startPosition:this.endPosition+1,endPosition:this.endPosition+1};let t;return this.expressionParsers.length===this.operatorParser.getNumOperators()?t="advancedFilterValidationMissingCondition":this.missingEndBracket&&(t="advancedFilterValidationMissingEndBracket"),t?{message:this.params.advancedFilterExpressionService.translate(t),startPosition:this.params.expression.length,endPosition:this.params.expression.length}:null}getFunctionString(e){const t=this.expressionParsers.length>1,i=this.expressionParsers.map(t=>t.getFunctionString(e)).join(` ${this.operatorParser.getFunction()} `);return t?`(${i})`:i}getFunctionParsed(e){const t=this.operatorParser.getFunction(),i=this.expressionParsers.map(t=>t.getFunctionParsed(e)),r="&&"===t?"every":"some";return(e,t,n)=>i[r](i=>i(e,t,n))}getAutocompleteListParams(e){if(null!=this.endPosition&&e>this.endPosition+1)return;if(!this.expressionParsers.length)return this.getColumnAutocompleteListParams();const t=this.getExpressionParserIndex(e);if(null==t)return"("===this.params.expression[e]?{enabled:!1}:this.getColumnAutocompleteListParams();const i=this.expressionParsers[t].getAutocompleteListParams(e);if(!i){if(t<this.expressionParsers.length-1)return this.operatorParser.getAutocompleteListParams(e,t);if(this.expressionParsers.length===this.operatorParser.getNumOperators()){const t=this.operatorParser.getLastOperatorEndPosition();return null==t||e<=t+1?this.operatorParser.getAutocompleteListParams(e,this.operatorParser.getNumOperators()-1):this.getColumnAutocompleteListParams()}return")"===this.params.expression[e-1]?{enabled:!1}:this.operatorParser.getAutocompleteListParams(e)}return i}updateExpression(e,t,i){var r;const n=this.params.expression,s=this.getExpressionParserIndex(e);if(null==s){const e="column"===i?this.params.advancedFilterExpressionService.getColumnValue(t):null!=(r=t.displayValue)?r:t.key;return Z(n,this.startPosition,this.startPosition,e,!0)}const o=this.expressionParsers[s].updateExpression(e,t,i);return null==o?"column"===i?Z(n,e,n.length-1,this.params.advancedFilterExpressionService.getColumnValue(t),!0):null!=this.endPosition&&e>this.endPosition+1?null:this.operatorParser.updateExpression(e,t,s):o}getModel(){return this.expressionParsers.length>1?{filterType:"join",type:this.operatorParser.getModel(),conditions:this.expressionParsers.map(e=>e.getModel())}:this.expressionParsers[0].getModel()}getColumnAutocompleteListParams(){return this.params.advancedFilterExpressionService.generateAutocompleteListParams(this.params.advancedFilterExpressionService.getColumnAutocompleteEntries(),"column","")}getExpressionParserIndex(e){let t;for(let i=0;i<this.expressionParsers.length&&!(this.expressionParsers[i].startPosition>e);i++)t=i;return t}},pe=class{constructor(e){this.params=e,this.valid=!1}parseExpression(){this.joinExpressionParser=new de(this.params,0);const e=this.joinExpressionParser.parseExpression();return this.valid=e>=this.params.expression.length-1&&this.joinExpressionParser.isValid(),this.params.expression}isValid(){return this.valid}getValidationMessage(){const e=this.joinExpressionParser.getValidationError();if(!e)return null;const{message:t,startPosition:i,endPosition:r}=e;return i<this.params.expression.length?this.params.advancedFilterExpressionService.translate("advancedFilterValidationMessage",[t,this.params.expression.slice(i,r+1).trim()]):this.params.advancedFilterExpressionService.translate("advancedFilterValidationMessageAtEnd",[t])}getFunctionString(){const e=this.createFunctionParams();return{functionString:`return ${this.joinExpressionParser.getFunctionString(e)};`,params:e}}getFunctionParsed(){const e=this.createFunctionParams();return{expressionFunction:this.joinExpressionParser.getFunctionParsed(e),params:e}}getAutocompleteListParams(e){var t;return null!=(t=this.joinExpressionParser.getAutocompleteListParams(e))?t:{enabled:!1}}updateExpression(e,t,i){return this.joinExpressionParser.updateExpression(e,t,i)}getModel(){return this.isValid()?this.joinExpressionParser.getModel():null}createFunctionParams(){return{operands:[],operators:[],evaluatorParams:[]}}},ge=class extends r.XQb{constructor(){super(...arguments),this.appliedExpression=null,this.expression=null,this.isValid=!0}postConstruct(){this.setEnabled(this.gos.get("enableAdvancedFilter"),!0),this.ctrl=this.createManagedBean(new q(this.enabled)),this.expressionProxy={getValue:(e,t)=>{const i=this.columnModel.getPrimaryColumn(e);return i?this.valueService.getValue(i,t,!0):void 0}},this.addManagedPropertyListener("enableAdvancedFilter",e=>this.setEnabled(!!e.currentValue)),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,e=>this.onNewColumnsLoaded(e)),this.addManagedPropertyListener("includeHiddenColumnsInAdvancedFilter",()=>this.updateValidity())}isEnabled(){return this.enabled}isFilterPresent(){return!!this.expressionFunction}doesFilterPass(e){return this.expressionFunction(this.expressionProxy,e,this.expressionParams)}getModel(){var e;const t=this.createExpressionParser(this.appliedExpression);return null==t||t.parseExpression(),null!=(e=null==t?void 0:t.getModel())?e:null}setModel(e){const t=(e,i)=>{if("join"===e.filterType){const n=this.advancedFilterExpressionService.parseJoinOperator(e),s=e.conditions.map(e=>t(e)).filter(e=>r._.exists(e)).join(` ${n} `);return i||e.conditions.length<=1?s:`(${s})`}return this.advancedFilterExpressionService.parseColumnFilterModel(e)},i=e?t(e,!0):null;this.setExpressionDisplayValue(i),this.applyExpression(),this.ctrl.refreshComp(),this.ctrl.refreshBuilderComp()}getExpressionDisplayValue(){return this.expression}setExpressionDisplayValue(e){this.expression=e}isCurrentExpressionApplied(){return this.appliedExpression===this.expression}createExpressionParser(e){return e?new pe({expression:e,columnModel:this.columnModel,dataTypeService:this.dataTypeService,valueService:this.valueService,advancedFilterExpressionService:this.advancedFilterExpressionService}):null}getDefaultExpression(e){const t=this.advancedFilterExpressionService.getColumnValue(e)+" ";return{updatedValue:t,updatedPosition:t.length}}isHeaderActive(){return!this.gos.get("advancedFilterParent")}getCtrl(){return this.ctrl}setEnabled(e,t){const i=this.enabled,n=this.rowModel.getType(),s="clientSide"===n||"serverSide"===n;if(e&&!n&&r._.warnOnce("Advanced Filter is only supported with the Client-Side Row Model or Server-Side Row Model."),this.enabled=e&&s,!t&&this.enabled!==i){const e={type:r.sVA.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,enabled:this.enabled};this.eventService.dispatchEvent(e)}}applyExpression(){const e=this.createExpressionParser(this.expression);null==e||e.parseExpression(),this.applyExpressionFromParser(e)}applyExpressionFromParser(e){if(this.isValid=!e||e.isValid(),!e||!this.isValid)return this.expressionFunction=null,this.expressionParams=null,void(this.appliedExpression=null);const{expressionFunction:t,params:i}=this.getFunction(e);this.expressionFunction=t,this.expressionParams=i,this.appliedExpression=this.expression}getFunction(e){if(this.gos.get("suppressAdvancedFilterEval"))return e.getFunctionParsed();{const{functionString:t,params:i}=e.getFunctionString();return{expressionFunction:new Function("expressionProxy","node","params",t),params:i}}}updateValidity(){this.advancedFilterExpressionService.resetColumnCaches();const e=this.createExpressionParser(this.expression);null==e||e.parseExpression();const t=(!e||e.isValid())!==this.isValid;return this.applyExpressionFromParser(e),this.ctrl.refreshComp(),this.ctrl.refreshBuilderComp(),t}onNewColumnsLoaded(e){if("gridInitializing"!==e.source||!this.dataTypeService.isPendingInference())return;this.ctrl.setInputDisabled(!0);const t=this.addManagedListener(this.eventService,r.sVA.EVENT_DATA_TYPES_INFERRED,()=>{null==t||t(),this.ctrl.setInputDisabled(!1)})}};I([(0,r.dsm)("valueService")],ge.prototype,"valueService",2),I([(0,r.dsm)("columnModel")],ge.prototype,"columnModel",2),I([(0,r.dsm)("dataTypeService")],ge.prototype,"dataTypeService",2),I([(0,r.dsm)("rowModel")],ge.prototype,"rowModel",2),I([(0,r.dsm)("advancedFilterExpressionService")],ge.prototype,"advancedFilterExpressionService",2),I([r.o7C],ge.prototype,"postConstruct",1),ge=I([(0,r.dR4)("advancedFilterService")],ge);var fe={version:"31.3.4",moduleName:r.zsj.AdvancedFilterModule,beans:[ge,ue],agStackComponents:[{componentName:"agAdvancedFilter",componentClass:Y}],dependantModules:[S]},me={};c(me,{GridChartsModule:()=>Is,__FORCE_MODULE_DETECTION_AG_GRID_CORE_EXT:()=>Ls,agCharts:()=>Ns});var ve=Object.defineProperty,Ce=Object.defineProperties,ye=Object.getOwnPropertyDescriptor,we=Object.getOwnPropertyDescriptors,Se=Object.getOwnPropertySymbols,be=Object.prototype.hasOwnProperty,Ee=Object.prototype.propertyIsEnumerable,Ae=(e,t,i)=>t in e?ve(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Te=(e,t)=>{for(var i in t||(t={}))be.call(t,i)&&Ae(e,i,t[i]);if(Se)for(var i of Se(t))Ee.call(t,i)&&Ae(e,i,t[i]);return e},Me=(e,t)=>Ce(e,we(t)),Re=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?ye(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&ve(t,i,s),s},_e=class extends r.XQb{constructor(){super(...arguments),this.cellRanges=[],this.bodyScrollListener=this.onBodyScroll.bind(this),this.dragging=!1,this.intersectionRange=!1}init(){this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_VISIBLE,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_VALUE_CHANGED,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_CHANGED,()=>this.removeAllCellRanges()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_GROUP_OPENED,this.refreshLastRangeStart.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_MOVED,this.refreshLastRangeStart.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PINNED,this.refreshLastRangeStart.bind(this)),this.ctrlsService.whenReady(e=>{const t=e.gridBodyCtrl;this.autoScrollService=new r.MSA({scrollContainer:t.getBodyViewportElement(),scrollAxis:"xy",getVerticalPosition:()=>t.getScrollFeature().getVScrollPosition().top,setVerticalPosition:e=>t.getScrollFeature().setVerticalScrollPosition(e),getHorizontalPosition:()=>t.getScrollFeature().getHScrollPosition().left,setHorizontalPosition:e=>t.getScrollFeature().setHorizontalScrollPosition(e),shouldSkipVerticalScroll:()=>!this.gos.isDomLayout("normal"),shouldSkipHorizontalScroll:()=>!t.getScrollFeature().isHorizontalScrollShowing()})})}onColumnsChanged(){this.refreshLastRangeStart();const e=this.columnModel.getAllDisplayedColumns();this.cellRanges.forEach(t=>{const i=t.columns;t.columns=t.columns.filter(t=>t.isVisible()&&-1!==e.indexOf(t)),!r._.areEqual(i,t.columns)&&this.dispatchChangedEvent(!1,!0,t.id)});const t=this.cellRanges.length;this.cellRanges=this.cellRanges.filter(e=>e.columns.length>0),t>this.cellRanges.length&&this.dispatchChangedEvent(!1,!0)}refreshLastRangeStart(){const e=r._.last(this.cellRanges);e&&this.refreshRangeStart(e)}isContiguousRange(e){const t=e.columns;if(!t.length)return!1;const i=this.columnModel.getAllDisplayedColumns(),n=t.map(e=>i.indexOf(e)).sort((e,t)=>e-t);return r._.last(n)-n[0]+1===t.length}getRangeStartRow(e){return e.startRow&&e.endRow?this.rowPositionUtils.before(e.startRow,e.endRow)?e.startRow:e.endRow:{rowIndex:0,rowPinned:this.pinnedRowModel.getPinnedTopRowCount()>0?"top":null}}getRangeEndRow(e){if(e.startRow&&e.endRow)return this.rowPositionUtils.before(e.startRow,e.endRow)?e.endRow:e.startRow;const t=this.pinnedRowModel.getPinnedBottomRowCount();return t>0?{rowIndex:t-1,rowPinned:"bottom"}:{rowIndex:this.rowModel.getRowCount()-1,rowPinned:null}}setRangeToCell(e,t=!1){if(!this.gos.get("enableRangeSelection"))return;const i=this.calculateColumnsBetween(e.column,e.column);if(!i)return;(this.gos.get("suppressMultiRangeSelection")||!t||r._.missing(this.cellRanges))&&this.removeAllCellRanges(!0);const n={rowIndex:e.rowIndex,rowPinned:e.rowPinned},s={startRow:n,endRow:n,columns:i,startColumn:e.column};this.cellRanges.push(s),this.setNewestRangeStartCell(e),this.onDragStop(),this.dispatchChangedEvent(!0,!0)}extendLatestRangeToCell(e){if(this.isEmpty()||!this.newestRangeStartCell)return;const t=r._.last(this.cellRanges);this.updateRangeEnd(t,e)}updateRangeEnd(e,t,i=!1){const r=t.column,n=this.calculateColumnsBetween(e.startColumn,r);n&&!this.isLastCellOfRange(e,t)&&(e.columns=n,e.endRow={rowIndex:t.rowIndex,rowPinned:t.rowPinned},i||this.dispatchChangedEvent(!0,!0,e.id))}refreshRangeStart(e){const{startColumn:t,columns:i}=e,n=(t,i)=>{const r=e.columns.filter(e=>e!==t);t?(e.startColumn=t,e.columns=i?[t,...r]:[...r,t]):e.columns=r},{left:s,right:o}=this.getRangeEdgeColumns(e);t!==i[0]||t===s?t===r._.last(i)&&t===o&&n(o,!1):n(s,!0)}getRangeEdgeColumns(e){const t=this.columnModel.getAllDisplayedColumns(),i=e.columns.map(e=>t.indexOf(e)).filter(e=>e>-1).sort((e,t)=>e-t);return{left:t[i[0]],right:t[r._.last(i)]}}extendLatestRangeInDirection(e){if(this.isEmpty()||!this.newestRangeStartCell)return;const t=e.key,i=e.ctrlKey||e.metaKey,n=r._.last(this.cellRanges),s=this.newestRangeStartCell,o=n.columns[0],a=r._.last(n.columns),l=n.endRow.rowIndex,c=n.endRow.rowPinned,u={column:s.column===o?a:o,rowIndex:l,rowPinned:c},h=this.cellNavigationService.getNextCellToFocus(t,u,i);return h?(this.setCellRange({rowStartIndex:s.rowIndex,rowStartPinned:s.rowPinned,rowEndIndex:h.rowIndex,rowEndPinned:h.rowPinned,columnStart:s.column,columnEnd:h.column}),h):void 0}setCellRange(e){this.gos.get("enableRangeSelection")&&(this.removeAllCellRanges(!0),this.addCellRange(e))}setCellRanges(e){r._.shallowCompare(this.cellRanges,e)||(this.removeAllCellRanges(!0),e.forEach(e=>{e.columns&&e.startRow&&this.setNewestRangeStartCell({rowIndex:e.startRow.rowIndex,rowPinned:e.startRow.rowPinned,column:e.columns[0]}),this.cellRanges.push(e)}),this.dispatchChangedEvent(!1,!0))}setNewestRangeStartCell(e){this.newestRangeStartCell=e}clearCellRangeCellValues(e){let{cellRanges:t}=e;const{cellEventSource:i="rangeService",dispatchWrapperEvents:n,wrapperEventSource:s="deleteKey"}=e;if(n){const e={type:r.sVA.EVENT_RANGE_DELETE_START,source:s};this.eventService.dispatchEvent(e)}if(t||(t=this.cellRanges),t.forEach(e=>{this.forEachRowInRange(e,t=>{var r;const n=this.rowPositionUtils.getRowNode(t);if(n)for(let t=0;t<e.columns.length;t++){const s=this.columnModel.getGridColumn(e.columns[t]);if(!s||!s.isCellEditable(n))continue;const o=null!=(r=this.valueService.parseValue(s,n,"",n.getValueFromValueService(s)))?r:null;n.setDataValue(s,o,i)}})}),n){const e={type:r.sVA.EVENT_RANGE_DELETE_END,source:s};this.eventService.dispatchEvent(e)}}createCellRangeFromCellRangeParams(e){return this.createPartialCellRangeFromRangeParams(e,!1)}createPartialCellRangeFromRangeParams(e,t){let i,n=!1;if(e.columns)i=e.columns.map(e=>this.columnModel.getColumnWithValidation(e)).filter(e=>e);else{const t=this.columnModel.getColumnWithValidation(e.columnStart),r=this.columnModel.getColumnWithValidation(e.columnEnd);if(!t||!r)return;i=this.calculateColumnsBetween(t,r),i&&i.length&&(n=i[0]!==t)}if(i&&(t||0!==i.length))return{startRow:null!=e.rowStartIndex?{rowIndex:e.rowStartIndex,rowPinned:e.rowStartPinned||null}:void 0,endRow:null!=e.rowEndIndex?{rowIndex:e.rowEndIndex,rowPinned:e.rowEndPinned||null}:void 0,columns:i,startColumn:n?r._.last(i):i[0]}}addCellRange(e){if(!this.gos.get("enableRangeSelection"))return;const t=this.createCellRangeFromCellRangeParams(e);t&&(t.startRow&&this.setNewestRangeStartCell({rowIndex:t.startRow.rowIndex,rowPinned:t.startRow.rowPinned,column:t.startColumn}),this.cellRanges.push(t),this.dispatchChangedEvent(!1,!0,t.id))}getCellRanges(){return this.cellRanges}isEmpty(){return 0===this.cellRanges.length}isMoreThanOneCell(){const e=this.cellRanges.length;if(0===e)return!1;if(e>1)return!0;const t=this.cellRanges[0],i=this.getRangeStartRow(t),r=this.getRangeEndRow(t);return i.rowPinned!==r.rowPinned||i.rowIndex!==r.rowIndex||1!==t.columns.length}areAllRangesAbleToMerge(){const e=new Map;if(this.cellRanges.length<=1)return!0;let t;this.cellRanges.forEach(t=>{this.forEachRowInRange(t,i=>{const r=`${i.rowPinned||"normal"}_${i.rowIndex}`,n=e.get(r),s=t.columns.map(e=>e.getId());if(n){const e=s.filter(e=>-1===n.indexOf(e));n.push(...e)}else e.set(r,s)})});for(const i of e.values()){const e=i.sort().join();if(void 0!==t){if(t!==e)return!1}else t=e}return!0}forEachRowInRange(e,t){const i=this.getRangeStartRow(e),r=this.getRangeEndRow(e);let n=i;for(;n&&(t(n),!this.rowPositionUtils.sameRow(n,r));)n=this.cellNavigationService.getRowBelow(n)}removeAllCellRanges(e){this.isEmpty()||(this.onDragStop(),this.cellRanges.length=0,e||this.dispatchChangedEvent(!1,!0))}onBodyScroll(){this.dragging&&this.lastMouseEvent&&this.onDragging(this.lastMouseEvent)}isCellInAnyRange(e){return this.getCellRangeCount(e)>0}isCellInSpecificRange(e,t){const i=null!==t.columns&&r._.includes(t.columns,e.column),n=this.isRowInRange(e.rowIndex,e.rowPinned,t);return i&&n}isLastCellOfRange(e,t){const{startRow:i,endRow:n}=e,s=this.rowPositionUtils.before(i,n)?n:i,o=t.rowIndex===s.rowIndex&&t.rowPinned===s.rowPinned,a=e.columns[0],l=r._.last(e.columns),c=e.startColumn===a?l:a;return t.column===c&&o}isBottomRightCell(e,t){const i=this.columnModel.getAllDisplayedColumns(),n=e.columns.map(e=>i.indexOf(e)).sort((e,t)=>e-t),{startRow:s,endRow:o}=e,a=this.rowPositionUtils.before(s,o)?o:s,l=i.indexOf(t.column)===r._.last(n),c=t.rowIndex===a.rowIndex&&r._.makeNull(t.rowPinned)===r._.makeNull(a.rowPinned);return l&&c}getCellRangeCount(e){return this.isEmpty()?0:this.cellRanges.filter(t=>this.isCellInSpecificRange(e,t)).length}isRowInRange(e,t,i){const r=this.getRangeStartRow(i),n=this.getRangeEndRow(i),s={rowIndex:e,rowPinned:t||null},o=s.rowIndex===r.rowIndex&&s.rowPinned==r.rowPinned,a=s.rowIndex===n.rowIndex&&s.rowPinned==n.rowPinned;if(o||a)return!0;const l=!this.rowPositionUtils.before(s,r),c=this.rowPositionUtils.before(s,n);return l&&c}getDraggingRange(){return this.draggingRange}onDragStart(e){if(!this.gos.get("enableRangeSelection"))return;const{ctrlKey:t,metaKey:i,shiftKey:n}=e,s=t||i,o=!this.gos.get("suppressMultiRangeSelection")&&s,a=n&&r._.existsAndNotEmpty(this.cellRanges);o||a&&!r._.exists(r._.last(this.cellRanges).type)||this.removeAllCellRanges(!0);const l=this.dragService.getStartTarget();if(l&&this.updateValuesOnMove(l),this.lastCellHovered){if(this.dragging=!0,this.lastMouseEvent=e,this.intersectionRange=o&&this.getCellRangeCount(this.lastCellHovered)>1,a||this.setNewestRangeStartCell(this.lastCellHovered),this.cellRanges.length>0)this.draggingRange=r._.last(this.cellRanges);else{const e={rowIndex:this.lastCellHovered.rowIndex,rowPinned:this.lastCellHovered.rowPinned};this.draggingRange={startRow:e,endRow:e,columns:[this.lastCellHovered.column],startColumn:this.newestRangeStartCell.column},this.cellRanges.push(this.draggingRange)}this.ctrlsService.getGridBodyCtrl().addScrollEventListener(this.bodyScrollListener),this.dispatchChangedEvent(!0,!1,this.draggingRange.id)}}intersectLastRange(e){if(e&&this.dragging)return;if(this.gos.get("suppressMultiRangeSelection"))return;if(this.isEmpty())return;const t=this.rowPositionUtils,i=r._.last(this.cellRanges),n=this.getRangeStartRow(i),s=this.getRangeEndRow(i),o=[];this.cellRanges.slice(0,-1).forEach(e=>{const a=this.getRangeStartRow(e),l=this.getRangeEndRow(e),c=e.columns,u=c.filter(e=>-1===i.columns.indexOf(e));if(u.length===c.length)return void o.push(e);if(t.before(s,a)||t.before(l,n))return void o.push(e);const h=o.length;if(t.before(a,n)){const e={columns:[...c],startColumn:i.startColumn,startRow:Te({},a),endRow:this.cellNavigationService.getRowAbove(n)};o.push(e)}if(u.length>0){const e={columns:u,startColumn:r._.includes(u,i.startColumn)?i.startColumn:u[0],startRow:this.rowMax([Te({},n),Te({},a)]),endRow:this.rowMin([Te({},s),Te({},l)])};o.push(e)}t.before(s,l)&&o.push({columns:[...c],startColumn:i.startColumn,startRow:this.cellNavigationService.getRowBelow(s),endRow:Te({},l)}),o.length-h===1&&(o[o.length-1].id=e.id)}),this.cellRanges=o,e&&this.dispatchChangedEvent(!1,!0)}rowMax(e){let t;return e.forEach(e=>{(void 0===t||this.rowPositionUtils.before(t,e))&&(t=e)}),t}rowMin(e){let t;return e.forEach(e=>{(void 0===t||this.rowPositionUtils.before(e,t))&&(t=e)}),t}updateValuesOnMove(e){const t=r._.getCtrlForEventTarget(this.gos,e,r.wX9.DOM_DATA_KEY_CELL_CTRL),i=null==t?void 0:t.getCellPosition();this.cellHasChanged=!1,!i||this.lastCellHovered&&this.cellPositionUtils.equals(i,this.lastCellHovered)||(this.lastCellHovered&&(this.cellHasChanged=!0),this.lastCellHovered=i)}onDragging(e){if(!this.dragging||!e)return;this.updateValuesOnMove(e.target),this.lastMouseEvent=e;const t=this.lastCellHovered,i=e=>t&&t.rowPinned===e&&this.newestRangeStartCell.rowPinned===e,r=i("top")||i("bottom");if(this.autoScrollService.check(e,r),!this.cellHasChanged)return;const n=this.calculateColumnsBetween(this.newestRangeStartCell.column,t.column);n&&(this.draggingRange.endRow={rowIndex:t.rowIndex,rowPinned:t.rowPinned},this.draggingRange.columns=n,this.dispatchChangedEvent(!1,!1,this.draggingRange.id))}onDragStop(){if(!this.dragging)return;const{id:e}=this.draggingRange;this.autoScrollService.ensureCleared(),this.ctrlsService.getGridBodyCtrl().removeScrollEventListener(this.bodyScrollListener),this.lastMouseEvent=null,this.dragging=!1,this.draggingRange=void 0,this.lastCellHovered=void 0,this.intersectionRange&&(this.intersectionRange=!1,this.intersectLastRange()),this.dispatchChangedEvent(!1,!0,e)}dispatchChangedEvent(e,t,i){const n={type:r.sVA.EVENT_RANGE_SELECTION_CHANGED,started:e,finished:t,id:i};this.eventService.dispatchEvent(n)}calculateColumnsBetween(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=e===t,n=i.indexOf(e);if(n<0)return void console.warn(`AG Grid: column ${e.getId()} is not visible`);const s=r?n:i.indexOf(t);if(s<0)return void console.warn(`AG Grid: column ${t.getId()} is not visible`);if(r)return[e];const o=Math.min(n,s),a=o===n?s:n,l=[];for(let e=o;e<=a;e++)l.push(i[e]);return l}};Re([(0,r.dsm)("rowModel")],_e.prototype,"rowModel",2),Re([(0,r.dsm)("dragService")],_e.prototype,"dragService",2),Re([(0,r.dsm)("columnModel")],_e.prototype,"columnModel",2),Re([(0,r.dsm)("cellNavigationService")],_e.prototype,"cellNavigationService",2),Re([(0,r.dsm)("pinnedRowModel")],_e.prototype,"pinnedRowModel",2),Re([(0,r.dsm)("rowPositionUtils")],_e.prototype,"rowPositionUtils",2),Re([(0,r.dsm)("cellPositionUtils")],_e.prototype,"cellPositionUtils",2),Re([(0,r.dsm)("ctrlsService")],_e.prototype,"ctrlsService",2),Re([(0,r.dsm)("valueService")],_e.prototype,"valueService",2),Re([r.o7C],_e.prototype,"init",1),_e=Re([(0,r.dR4)("rangeService")],_e);var Pe=class extends r.uAl{constructor(){super(...arguments),this.changedCalculatedValues=!1,this.dragging=!1,this.shouldDestroyOnEndDragging=!1}init(){this.dragService.addDragSource({dragStartPixels:0,eElement:this.getGui(),onDragStart:this.onDragStart.bind(this),onDragging:e=>{this.dragging=!0,this.rangeService.autoScrollService.check(e),this.changedCalculatedValues&&(this.onDrag(e),this.changedCalculatedValues=!1)},onDragStop:e=>{this.dragging=!1,this.onDragEnd(e),this.clearValues(),this.rangeService.autoScrollService.ensureCleared(),document.body.classList.remove(this.getDraggingCssClass()),this.shouldDestroyOnEndDragging&&this.destroy()}}),this.addManagedListener(this.getGui(),"mousedown",this.preventRangeExtension.bind(this))}isDragging(){return this.dragging}getCellCtrl(){return this.cellCtrl}setCellCtrl(e){this.cellCtrl=e}getCellRange(){return this.cellRange}setCellRange(e){this.cellRange=e}getRangeStartRow(){return this.rangeStartRow}setRangeStartRow(e){this.rangeStartRow=e}getRangeEndRow(){return this.rangeEndRow}setRangeEndRow(e){this.rangeEndRow=e}getLastCellHovered(){return this.lastCellHovered}preventRangeExtension(e){e.stopPropagation()}onDragStart(e){this.cellHoverListener=this.addManagedListener(this.ctrlsService.get("gridCtrl").getGui(),"mousemove",this.updateValuesOnMove.bind(this)),document.body.classList.add(this.getDraggingCssClass())}getDraggingCssClass(){return`ag-dragging-${this.type===r.LIk.FILL?"fill":"range"}-handle`}updateValuesOnMove(e){const t=this.mouseEventService.getCellPositionForEvent(e);!t||this.lastCellHovered&&this.cellPositionUtils.equals(t,this.lastCellHovered)||(this.lastCellHovered=t,this.changedCalculatedValues=!0)}getType(){return this.type}refresh(e){const t=this.getCellCtrl(),i=this.getGui(),n=r._.last(this.rangeService.getCellRanges()),s=n.startRow,o=n.endRow;if(s&&o&&(this.rowPositionUtils.before(o,s)?(this.setRangeStartRow(o),this.setRangeEndRow(s)):(this.setRangeStartRow(s),this.setRangeEndRow(o))),t!==e||!r._.isVisible(i)){this.setCellCtrl(e);const t=e.getComp().getParentOfValue();t&&t.appendChild(i)}this.setCellRange(n)}clearValues(){this.lastCellHovered=void 0,this.removeListeners()}removeListeners(){this.cellHoverListener&&(this.cellHoverListener(),this.cellHoverListener=void 0)}destroy(){if(!this.shouldDestroyOnEndDragging&&this.isDragging())return r._.setDisplayed(this.getGui(),!1),void(this.shouldDestroyOnEndDragging=!0);this.shouldDestroyOnEndDragging=!1,super.destroy(),this.removeListeners();const e=this.getGui();e.parentElement&&e.parentElement.removeChild(e)}};function xe(e){const t=e.length;let i=0;if(t<=1)return e;for(let t=0;t<e.length;t++){const r=e[t],n=r.toString().split("e-");n.length>1?i=Math.max(i,parseInt(n[1],10)):Math.floor(r)!==r&&(i=Math.max(i,r.toString().split(".")[1].length))}let r=0,n=0,s=0,o=0,a=0;for(let i=0;i<t;i++)a=e[i],r+=i,n+=a,o+=i*i,s+=i*a;const l=(t*s-r*n)/(t*o-r*r),c=n/t-l*r/t,u=[];for(let e=0;e<=t;e++)u.push(parseFloat((e*l+c).toFixed(i)));return u}Re([(0,r.dsm)("rowRenderer")],Pe.prototype,"rowRenderer",2),Re([(0,r.dsm)("dragService")],Pe.prototype,"dragService",2),Re([(0,r.dsm)("rangeService")],Pe.prototype,"rangeService",2),Re([(0,r.dsm)("mouseEventService")],Pe.prototype,"mouseEventService",2),Re([(0,r.dsm)("columnModel")],Pe.prototype,"columnModel",2),Re([(0,r.dsm)("cellNavigationService")],Pe.prototype,"cellNavigationService",2),Re([(0,r.dsm)("navigationService")],Pe.prototype,"navigationService",2),Re([(0,r.dsm)("rowPositionUtils")],Pe.prototype,"rowPositionUtils",2),Re([(0,r.dsm)("cellPositionUtils")],Pe.prototype,"cellPositionUtils",2),Re([(0,r.dsm)("ctrlsService")],Pe.prototype,"ctrlsService",2),Re([r.o7C],Pe.prototype,"init",1);var De=class e extends Pe{constructor(){super(e.TEMPLATE),this.markedCells=[],this.cellValues=[],this.isUp=!1,this.isLeft=!1,this.isReduce=!1,this.type=r.LIk.FILL}updateValuesOnMove(e){super.updateValuesOnMove(e),this.initialXY||(this.initialXY=this.mouseEventService.getNormalisedPosition(e));const{x:t,y:i}=this.initialXY,{x:r,y:n}=this.mouseEventService.getNormalisedPosition(e),s=Math.abs(t-r),o=Math.abs(i-n),a=this.getFillHandleDirection();let l;l="xy"===a?s>o?"x":"y":a,l!==this.dragAxis&&(this.dragAxis=l,this.changedCalculatedValues=!0)}onDrag(e){if(!this.initialPosition){const e=this.getCellCtrl();if(!e)return;this.initialPosition=e.getCellPosition()}const t=this.getLastCellHovered();t&&this.markPathFrom(this.initialPosition,t)}onDragEnd(e){if(this.initialXY=null,!this.markedCells.length)return;const t="x"===this.dragAxis,i=this.getCellRange(),r=i.columns.length,n=this.getRangeStartRow(),s=this.getRangeEndRow();let o;if(this.isUp||this.isLeft){const e=t?n:this.lastCellMarked;o=this.rangeService.createCellRangeFromCellRangeParams({rowStartIndex:e.rowIndex,rowStartPinned:e.rowPinned,columnStart:t?this.lastCellMarked.column:i.columns[0],rowEndIndex:s.rowIndex,rowEndPinned:s.rowPinned,columnEnd:i.columns[r-1]})}else o=this.rangeService.createCellRangeFromCellRangeParams({rowStartIndex:n.rowIndex,rowStartPinned:n.rowPinned,columnStart:i.columns[0],rowEndIndex:t?s.rowIndex:this.lastCellMarked.rowIndex,rowEndPinned:t?s.rowPinned:this.lastCellMarked.rowPinned,columnEnd:t?this.lastCellMarked.column:i.columns[r-1]});o&&(this.raiseFillStartEvent(),this.handleValueChanged(i,o,e),this.rangeService.setCellRanges([o]),this.raiseFillEndEvent(i,o))}getFillHandleDirection(){const e=this.gos.get("fillHandleDirection");return e?"x"!==e&&"y"!==e&&"xy"!==e?(r._.warnOnce("valid values for fillHandleDirection are 'x', 'y' and 'xy'. Default to 'xy'."),"xy"):e:"xy"}raiseFillStartEvent(){const e={type:r.sVA.EVENT_FILL_START};this.eventService.dispatchEvent(e)}raiseFillEndEvent(e,t){const i={type:r.sVA.EVENT_FILL_END,initialRange:e,finalRange:t};this.eventService.dispatchEvent(i)}handleValueChanged(e,t,i){const n=this.rangeService.getRangeEndRow(e),s=this.rangeService.getRangeStartRow(e),o=this.rangeService.getRangeEndRow(t),a=this.rangeService.getRangeStartRow(t),l="y"===this.dragAxis;if(this.isReduce&&!this.gos.get("suppressClearOnFillReduction")){const i=l?e.columns:e.columns.filter(e=>t.columns.indexOf(e)<0),r=l?this.cellNavigationService.getRowBelow(o):a;return void(r&&this.clearCellsInRange(r,n,i))}const c=[],u=[],h=[],d=[];let p=!0,g=0;const f=()=>{c.length=0,u.length=0,h.length=0,d.length=0,g=0},m=(t,i)=>{let u=this.isUp?n:s,h=!1;for(l&&(p=!0,f());!h&&u;){const d=this.rowPositionUtils.getRowNode(u);if(!d)break;l&&t?v(c,t,d,()=>!this.rowPositionUtils.sameRow(u,this.isUp?s:n)):i&&(p=!0,f(),i.forEach(t=>v(c,t,d,()=>t!==(this.isLeft?e.columns[0]:r._.last(e.columns))))),h=this.rowPositionUtils.sameRow(u,this.isUp?a:o),u=this.isUp?this.cellNavigationService.getRowAbove(u):this.cellNavigationService.getRowBelow(u)}},v=(e,t,n,s)=>{var o,a;let l,c=!1;if(p)l=this.valueService.getValue(t,n),u.push(l),h.push(this.valueService.getValue(t,n,void 0,!0)),d.push(this.valueService.formatValue(t,n,l)),p=s();else{const{value:s,fromUserFunction:p,sourceCol:f,sourceRowNode:m}=this.processValues({event:i,values:e,initialValues:u,initialNonAggregatedValues:h,initialFormattedValues:d,col:t,rowNode:n,idx:g++});if(l=s,t.isCellEditable(n)){const e=this.valueService.getValue(t,n);p||(f&&!1!==(null==(o=f.getColDef())?void 0:o.useValueFormatterForExport)&&(l=null!=(a=this.valueService.formatValue(f,m,l))?a:l),!1!==t.getColDef().useValueParserForImport&&(l=this.valueService.parseValue(t,n,f?l:r._.toStringOrNull(l),e))),p&&e===l?c=!0:n.setDataValue(t,l,"rangeService")}}c||e.push({value:l,column:t,rowNode:n})};if(l)e.columns.forEach(e=>{m(e)});else{const e=this.isLeft?[...t.columns].reverse():t.columns;m(void 0,e)}}clearCellsInRange(e,t,i){const r={startRow:e,endRow:t,columns:i,startColumn:i[0]};this.rangeService.clearCellRangeCellValues({cellRanges:[r]})}processValues(e){const{event:t,values:i,initialValues:n,initialNonAggregatedValues:s,initialFormattedValues:o,col:a,rowNode:l,idx:c}=e,u=this.gos.getCallback("fillOperation");let h;if(h="y"===this.dragAxis?this.isUp?"up":"down":this.isLeft?"left":"right",u){const e=u({event:t,values:i.map(({value:e})=>e),initialValues:n,initialNonAggregatedValues:s,initialFormattedValues:o,currentIndex:c,currentCellValue:this.valueService.getValue(a,l),direction:h,column:a,rowNode:l});if(!1!==e)return{value:e,fromUserFunction:!0}}const d=!i.some(({value:e})=>{const t=parseFloat(e);return isNaN(t)||t.toString()!==e.toString()});if(t.altKey||!d){if(d&&1===n.length){const e=this.isUp||this.isLeft?-1:1;return{value:parseFloat(r._.last(i).value)+1*e,fromUserFunction:!1}}const{value:e,column:t,rowNode:s}=i[c%i.length];return{value:e,fromUserFunction:!1,sourceCol:t,sourceRowNode:s}}return{value:r._.last(xe(i.map(({value:e})=>Number(e)))),fromUserFunction:!1}}clearValues(){this.clearMarkedPath(),this.clearCellValues(),this.lastCellMarked=void 0,super.clearValues()}clearMarkedPath(){this.markedCells.forEach(e=>{if(!e.isAlive())return;const t=e.getComp();t.addOrRemoveCssClass("ag-selection-fill-top",!1),t.addOrRemoveCssClass("ag-selection-fill-right",!1),t.addOrRemoveCssClass("ag-selection-fill-bottom",!1),t.addOrRemoveCssClass("ag-selection-fill-left",!1)}),this.markedCells.length=0,this.isUp=!1,this.isLeft=!1,this.isReduce=!1}clearCellValues(){this.cellValues.length=0}markPathFrom(e,t){if(this.clearMarkedPath(),this.clearCellValues(),"y"===this.dragAxis){if(this.rowPositionUtils.sameRow(t,e))return;const i=this.rowPositionUtils.before(t,e),r=this.getRangeStartRow(),n=this.getRangeEndRow();i&&(t.rowPinned==r.rowPinned&&t.rowIndex>=r.rowIndex||r.rowPinned!=n.rowPinned&&t.rowPinned==n.rowPinned&&t.rowIndex<=n.rowIndex)?(this.reduceVertical(e,t),this.isReduce=!0):(this.extendVertical(e,t,i),this.isReduce=!1)}else{const i=e.column,r=t.column;if(i===r)return;const n=this.columnModel.getAllDisplayedColumns(),s=n.indexOf(i),o=n.indexOf(r);o<=s&&o>=n.indexOf(this.getCellRange().columns[0])?(this.reduceHorizontal(e,t),this.isReduce=!0):(this.extendHorizontal(e,t,o<s),this.isReduce=!1)}this.lastCellMarked=t}extendVertical(e,t,i){const{navigationService:r,rangeService:n}=this;let s=e;do{const o=this.getCellRange(),a=o.columns.length;for(let l=0;l<a;l++){const c=o.columns[l],u={rowIndex:s.rowIndex,rowPinned:s.rowPinned},h=Me(Te({},u),{column:c}),d=n.isCellInSpecificRange(h,o),p=this.rowPositionUtils.sameRow(s,e);if(i&&(this.isUp=!0),!p){const e=r.getCellByPosition(h);if(e){this.markedCells.push(e);const r=e.getComp();d||(r.addOrRemoveCssClass("ag-selection-fill-left",0===l),r.addOrRemoveCssClass("ag-selection-fill-right",l===a-1)),r.addOrRemoveCssClass(i?"ag-selection-fill-top":"ag-selection-fill-bottom",this.rowPositionUtils.sameRow(s,t))}}}if(this.rowPositionUtils.sameRow(s,t))break}while(s=i?this.cellNavigationService.getRowAbove(s):this.cellNavigationService.getRowBelow(s))}reduceVertical(e,t){let i=e;do{const e=this.getCellRange(),r=e.columns.length,n=this.rowPositionUtils.sameRow(i,t);for(let n=0;n<r;n++){const r={rowIndex:i.rowIndex,rowPinned:i.rowPinned},s=Me(Te({},r),{column:e.columns[n]}),o=this.navigationService.getCellByPosition(s);o&&(this.markedCells.push(o),o.getComp().addOrRemoveCssClass("ag-selection-fill-bottom",this.rowPositionUtils.sameRow(i,t)))}if(n)break}while(i=this.cellNavigationService.getRowAbove(i))}extendHorizontal(e,t,i){const n=this.columnModel.getAllDisplayedColumns(),s=n.indexOf(i?t.column:e.column),o=n.indexOf(i?this.getCellRange().columns[0]:t.column),a=i?0:1,l=n.slice(s+a,o+a),c=this.getRangeStartRow(),u=this.getRangeEndRow();l.forEach(e=>{let t=c,n=!1;do{n=this.rowPositionUtils.sameRow(t,u);const s=this.navigationService.getCellByPosition({rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:e});if(s){this.markedCells.push(s);const n=s.getComp();n.addOrRemoveCssClass("ag-selection-fill-top",this.rowPositionUtils.sameRow(t,c)),n.addOrRemoveCssClass("ag-selection-fill-bottom",this.rowPositionUtils.sameRow(t,u)),i?(this.isLeft=!0,n.addOrRemoveCssClass("ag-selection-fill-left",e===l[0])):n.addOrRemoveCssClass("ag-selection-fill-right",e===r._.last(l))}t=this.cellNavigationService.getRowBelow(t)}while(!n)})}reduceHorizontal(e,t){const i=this.columnModel.getAllDisplayedColumns(),r=i.indexOf(t.column),n=i.indexOf(e.column),s=i.slice(r,n),o=this.getRangeStartRow(),a=this.getRangeEndRow();s.forEach(e=>{let t=o,i=!1;do{i=this.rowPositionUtils.sameRow(t,a);const r=this.navigationService.getCellByPosition({rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:e});r&&(this.markedCells.push(r),r.getComp().addOrRemoveCssClass("ag-selection-fill-right",e===s[0])),t=this.cellNavigationService.getRowBelow(t)}while(!i)})}refresh(e){const t=this.rangeService.getCellRanges()[0];t.startRow&&t.endRow?super.refresh(e):this.destroy()}};De.TEMPLATE='<div class="ag-fill-handle"></div>',Re([(0,r.dsm)("valueService")],De.prototype,"valueService",2);var Ie=De,Le=class e extends Pe{constructor(){super(e.TEMPLATE),this.type=r.LIk.RANGE,this.rangeFixed=!1}onDrag(e){const t=this.getLastCellHovered();if(!t)return;const i=this.rangeService.getCellRanges(),n=r._.last(i);this.rangeFixed||(this.fixRangeStartEnd(n),this.rangeFixed=!0),this.endPosition={rowIndex:t.rowIndex,rowPinned:t.rowPinned,column:t.column},2===i.length&&i[0].type===r.OnL.DIMENSION&&n.type===r.OnL.VALUE&&!this.rowPositionUtils.sameRow(this.endPosition,this.rangeService.getRangeEndRow(n))&&this.rangeService.updateRangeEnd(i[0],Me(Te({},this.endPosition),{column:i[0].columns[0]}),!0),this.rangeService.extendLatestRangeToCell(this.endPosition)}onDragEnd(e){const t=r._.last(this.rangeService.getCellRanges());this.fixRangeStartEnd(t),this.rangeFixed=!1}fixRangeStartEnd(e){const t=this.rangeService.getRangeStartRow(e),i=this.rangeService.getRangeEndRow(e),r=e.columns[0];e.startRow=t,e.endRow=i,e.startColumn=r}};Le.TEMPLATE='<div class="ag-range-handle"></div>';var Ne=Le,Oe=class extends r.XQb{createSelectionHandle(e){return this.createBean(e===r.LIk.RANGE?new Ne:new Ie)}};Oe=Re([(0,r.dR4)("selectionHandleFactory")],Oe);var Fe={version:"31.3.4",moduleName:r.zsj.RangeSelectionModule,beans:[_e,Oe],agStackComponents:[{componentName:"AgFillHandle",componentClass:Ie},{componentName:"AgRangeHandle",componentClass:Ne}],dependantModules:[S]};h(me,n);var ke=Object.defineProperty,Ge=Object.defineProperties,Ve=Object.getOwnPropertyDescriptor,He=Object.getOwnPropertyDescriptors,Be=Object.getOwnPropertySymbols,ze=Object.prototype.hasOwnProperty,Ue=Object.prototype.propertyIsEnumerable,We=(e,t,i)=>t in e?ke(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,je=(e,t)=>{for(var i in t||(t={}))ze.call(t,i)&&We(e,i,t[i]);if(Be)for(var i of Be(t))Ue.call(t,i)&&We(e,i,t[i]);return e},Ke=(e,t)=>Ge(e,He(t)),$e=(e,t)=>{var i={};for(var r in e)ze.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&Be)for(var r of Be(e))t.indexOf(r)<0&&Ue.call(e,r)&&(i[r]=e[r]);return i},qe=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Ve(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&ke(t,i,s),s},Ye=class e extends r.XQb{getData(e){if(e.crossFiltering){if(e.grouping)return console.warn("AG Grid: crossing filtering with row grouping is not supported."),{chartData:[],columnNames:{}};if(!this.gos.isRowModelType("clientSide"))return console.warn("AG Grid: crossing filtering is only supported in the client side row model."),{chartData:[],columnNames:{}}}this.gos.isRowModelType("serverSide")&&e.pivoting&&this.updatePivotKeysForSSRM();const t=this.extractRowsFromGridRowModel(e);return t.chartData=this.aggregateRowsByDimension(e,t.chartData),t}extractRowsFromGridRowModel(t){const{crossFiltering:i,startRow:n,endRow:s,valueCols:o,dimensionCols:a,grouping:l}=t;let c=[];const u={},h={},d={};let p,g={},f=[];if(i)g=this.getFilteredRowNodes(),f=this.getAllRowNodes(),p=f.length;else{const e=this.gridRowModel.getRowCount()-1;p=n===s&&0===n&&0===a.length&&0===o.length?0:(s>=0?Math.min(s,e):e)-n+1}p>0&&o.forEach(e=>{let t=[];const i=e.getColDef().pivotKeys;i&&(t=i.slice());const r=e.getColDef().headerName;r&&t.push(r),t.length>0&&(u[e.getId()]=t)});let m,v=0;for(let r=0;r<p;r++){const s=i?f[r]:this.gridRowModel.getRow(r+n);if(s.footer){v++;continue}const u={};a.forEach(t=>{const i=t.colId,n=this.columnModel.getGridColumn(i);if(n){const t=this.valueService.getValue(n,s);if(l){const n=t&&t.toString?String(t.toString()):"",o=e.getGroupLabels(s,n);u[i]={labels:o,toString:function(){return this.labels.filter(e=>!!e).reverse().join(" - ")}},s.group&&(h[o.toString()]=r-v);const a=o.slice(1,o.length).toString();a&&(d[a]=h[a])}else u[i]=t}else u[ft.DEFAULT_CATEGORY]=r+1}),o.forEach(e=>{const r=e.getColId();if(i){const i=r+"-filtered-out",n=this.valueService.getValue(e,s),o=null!=n&&"function"==typeof n.toNumber?n.toNumber():n;g[s.id]?(u[r]=o,u[i]=t.aggFunc||t.isScatter?void 0:0):(u[r]=t.aggFunc||t.isScatter?void 0:0,u[i]=o)}else{let t=this.valueService.getValue(e,s);t&&t.hasOwnProperty("toString")&&(t=parseFloat(t.toString())),u[r]=null!=t&&"function"==typeof t.toNumber?t.toNumber():t}}),c.push(u)}if(l){const e=r._.values(d),t=c;c=[],m=[];for(let i=0;i<t.length;i++)(r._.includes(e,i)?m:c).push(t[i])}return{chartData:c,columnNames:u,groupChartData:m}}aggregateRowsByDimension(e,t){const i=e.dimensionCols;if(!e.aggFunc||0===i.length)return t;const n=r._.last(i),s=n&&n.colId,o={},a=[];if(t.forEach(e=>{let t=o;i.forEach(r=>{const n=r.colId,o=e[n];if(n===s){let r=t[o];r||(r={__children:[]},i.forEach(t=>{const i=t.colId;r[i]=e[i]}),t[o]=r,a.push(r)),r.__children.push(e)}else t[o]||(t[o]={}),t=t[o]})}),r.syG.__assertRegistered(r.zsj.RowGroupingModule,"Charting Aggregation",this.context.getGridId())){const t=this.aggregationStage;a.forEach(i=>e.valueCols.forEach(r=>{if(e.crossFiltering)e.valueCols.forEach(r=>{const n=r.getColId(),s=i.__children.filter(e=>void 0!==e[n]).map(e=>e[n]);let o=t.aggregateValues(s,e.aggFunc);i[r.getId()]=o&&void 0!==o.value?o.value:o;const a=`${n}-filtered-out`,l=i.__children.filter(e=>void 0!==e[a]).map(e=>e[a]);let c=t.aggregateValues(l,e.aggFunc);i[a]=c&&void 0!==c.value?c.value:c});else{const n=i.__children.map(e=>e[r.getId()]);let s=t.aggregateValues(n,e.aggFunc);i[r.getId()]=s&&void 0!==s.value?s.value:s}}))}return a}updatePivotKeysForSSRM(){const e=this.columnModel.getSecondaryColumns();if(!e)return;const t=this.extractPivotKeySeparator(e);e.forEach(e=>{if(""===t)e.getColDef().pivotKeys=[];else{const i=e.getColId().split(t);e.getColDef().pivotKeys=i.slice(0,i.length-1)}})}extractPivotKeySeparator(e){if(0===e.length)return"";const t=(e,i)=>{const r=e.getGroupId();return e.getParent()?t(e.getParent(),r):i.split(r)[1][0]},i=e[0];return null==i.getParent()?"":t(i.getParent(),i.getColId())}static getGroupLabels(e,t){const i=[t];for(;e&&0!==e.level;)(e=e.parent)&&i.push(e.key);return i}getFilteredRowNodes(){const e={};return this.gridRowModel.forEachNodeAfterFilterAndSort(t=>{e[t.id]=t}),e}getAllRowNodes(){let e=[];return this.gridRowModel.forEachNode(t=>{e.push(t)}),this.sortRowNodes(e)}sortRowNodes(e){const t=this.sortController.getSortOptions();return t&&0!=t.length?this.rowNodeSorter.doFullSort(e,t):e}};qe([(0,r.dsm)("rowModel")],Ye.prototype,"gridRowModel",2),qe([(0,r.dsm)("valueService")],Ye.prototype,"valueService",2),qe([(0,r.dsm)("columnModel")],Ye.prototype,"columnModel",2),qe([(0,r.dsm)("rowNodeSorter")],Ye.prototype,"rowNodeSorter",2),qe([(0,r.dsm)("sortController")],Ye.prototype,"sortController",2),qe([(0,r.Xx1)("aggregationStage")],Ye.prototype,"aggregationStage",2);var Qe=Ye,Xe=class extends r.XQb{constructor(){super(...arguments),this.valueColsWithoutSeriesType=new Set}postConstruct(){const e=()=>this.valueColsWithoutSeriesType.clear();this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,e),this.addManagedListener(this.eventService,r.sVA.EVENT_ROW_DATA_UPDATED,e)}getColumn(e){return this.columnModel.getPrimaryColumn(e)}getAllDisplayedColumns(){return this.columnModel.getAllDisplayedColumns()}getColDisplayName(e){return this.columnModel.getDisplayNameForColumn(e,"chart")}getRowGroupColumns(){return this.columnModel.getRowGroupColumns()}getGroupDisplayColumns(){return this.columnModel.getGroupDisplayColumns()}isPivotMode(){return this.columnModel.isPivotMode()}isPivotActive(){return this.columnModel.isPivotActive()}getChartColumns(){const e=this.columnModel.getAllGridColumns(),t=new Set,i=new Set;return e.forEach(e=>{const r=e.getColDef(),n=r.chartDataType;if(n)switch(n){case"category":case"time":return void t.add(e);case"series":return void i.add(e);case"excluded":return;default:console.warn(`AG Grid: unexpected chartDataType value '${n}' supplied, instead use 'category', 'series' or 'excluded'`)}"ag-Grid-AutoColumn"!==r.colId?e.isPrimary()?(this.isInferredValueCol(e)?i:t).add(e):i.add(e):t.add(e)}),{dimensionCols:t,valueCols:i}}isInferredValueCol(e){const t=e.getColId();if("ag-Grid-AutoColumn"===t)return!1;const i=this.rowPositionUtils.getRowNode({rowIndex:0,rowPinned:null});if(!i)return this.valueColsWithoutSeriesType.has(t);let r=this.valueService.getValue(e,i);null==r&&(r=this.extractLeafData(i,e)),null!=r&&"function"==typeof r.toNumber&&(r=r.toNumber());const n="number"==typeof r;return n&&this.valueColsWithoutSeriesType.add(t),n}extractLeafData(e,t){if(!e.allLeafChildren)return null;for(let i=0;i<e.allLeafChildren.length;i++){const r=e.allLeafChildren[i],n=this.valueService.getValue(t,r);if(null!=n)return n}return null}destroy(){this.valueColsWithoutSeriesType.clear(),super.destroy()}};qe([(0,r.dsm)("columnModel")],Xe.prototype,"columnModel",2),qe([(0,r.dsm)("valueService")],Xe.prototype,"valueService",2),qe([(0,r.dsm)("rowPositionUtils")],Xe.prototype,"rowPositionUtils",2),qe([r.o7C],Xe.prototype,"postConstruct",1),Xe=qe([(0,r.dR4)("chartColumnService")],Xe);var Ze=class e extends r.XQb{constructor(e){var t;super(),this.suppressComboChartWarnings=!1,this.chartDataModel=e,this.seriesChartTypes=null!=(t=e.params.seriesChartTypes)?t:[]}init(){this.initComboCharts()}update(e){this.seriesChartTypes=null!=e?e:this.seriesChartTypes,this.initComboCharts(),this.updateSeriesChartTypes()}initComboCharts(){const e=this.seriesChartTypes&&this.seriesChartTypes.length>0;("customCombo"===this.chartDataModel.chartType||e)&&(this.chartDataModel.chartType="customCombo",this.savedCustomSeriesChartTypes=this.seriesChartTypes||[])}updateSeriesChartTypes(){this.chartDataModel.isComboChart()&&(this.seriesChartTypes=this.seriesChartTypes.map(e=>{const t=["groupedColumn","stackedColumn","stackedArea"].includes(e.chartType);return e.secondaryAxis=!t&&e.secondaryAxis,e}),"customCombo"!==this.chartDataModel.chartType?this.updateChartSeriesTypesForBuiltInCombos():this.updateSeriesChartTypesForCustomCombo())}updateSeriesChartTypesForCustomCombo(){this.seriesChartTypes&&this.seriesChartTypes.length>0||this.suppressComboChartWarnings||console.warn("AG Grid: 'seriesChartTypes' are required when the 'customCombo' chart type is specified."),this.seriesChartTypes=this.seriesChartTypes.map(t=>(e.SUPPORTED_COMBO_CHART_TYPES.includes(t.chartType)||(console.warn(`AG Grid: invalid chartType '${t.chartType}' supplied in 'seriesChartTypes', converting to 'line' instead.`),t.chartType="line"),t));const t=this.chartDataModel.valueColState.map(e=>{this.savedCustomSeriesChartTypes&&0!==this.savedCustomSeriesChartTypes.length||(this.savedCustomSeriesChartTypes=this.seriesChartTypes);return this.savedCustomSeriesChartTypes.find(t=>t.colId===e.colId)||(e.selected&&!this.suppressComboChartWarnings&&console.warn(`AG Grid: no 'seriesChartType' found for colId = '${e.colId}', defaulting to 'line'.`),{colId:e.colId,chartType:"line",secondaryAxis:!1})});this.seriesChartTypes=t,this.savedCustomSeriesChartTypes=t,this.suppressComboChartWarnings=!0}updateChartSeriesTypesForBuiltInCombos(){const{chartType:e,valueColState:t}=this.chartDataModel;let i="columnLineCombo"===e?"groupedColumn":"stackedArea",r="columnLineCombo"===e?"line":"groupedColumn";const n=t.filter(e=>e.selected),s=Math.ceil(n.length/2);this.seriesChartTypes=n.map((e,t)=>{const n=t>=s?r:i;return{colId:e.colId,chartType:n,secondaryAxis:!1}})}};Ze.SUPPORTED_COMBO_CHART_TYPES=["line","groupedColumn","stackedColumn","area","stackedArea"],qe([r.o7C],Ze.prototype,"init",1);var Je=Ze,et={area:{isCartesian:!0,canInvert:!0},bar:{isCartesian:!0,canInvert:!0},histogram:{isCartesian:!0},line:{isCartesian:!0,canInvert:!0},pie:{isPie:!0},donut:{isPie:!0,canInvert:!0},scatter:{isCartesian:!0},bubble:{isCartesian:!0},"radial-column":{isPolar:!0,isEnterprise:!0,isRadial:!0,canInvert:!0},"radial-bar":{isPolar:!0,isEnterprise:!0,isRadial:!0,canInvert:!0},"radar-line":{isPolar:!0,isEnterprise:!0,canInvert:!0},"radar-area":{isPolar:!0,isEnterprise:!0,canInvert:!0},nightingale:{isPolar:!0,isEnterprise:!0,canInvert:!0},"range-bar":{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0},"range-area":{isCartesian:!0,isEnterprise:!0},"box-plot":{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0},treemap:{isEnterprise:!0,isHierarchical:!0},sunburst:{isEnterprise:!0,isHierarchical:!0},heatmap:{isCartesian:!0,isEnterprise:!0},waterfall:{isCartesian:!0,isEnterprise:!0,canSwitchDirection:!0}};function tt(e){return r.E1g.COMBO_CHART_TYPES.includes(e)}function it(e,t){var i;return!!(null==(i=et[e])?void 0:i[t])}var rt=new Set(["stackedColumn","normalizedColumn","stackedBar","normalizedBar"]);function nt(e){return it(e,"isCartesian")}function st(e){return it(e,"isPolar")}function ot(e){return it(e,"isHierarchical")}function at(e){return"doughnut"===e?"donut":e}function lt(e){return r.E1g.CHART_TYPE_TO_SERIES_TYPE[e]}function ct(e){var t;return null!=(t=lt(e))?t:"line"}function ut(e){return it(e,"isPie")}function ht(e){return ot(ct(e))?void 0:1}function dt(e){return ot(ct(e))?2:function(e){return"pie"===e||"waterfall"===e||"histogram"===e}(e)?1:void 0}function pt(e){return it(ct(e),"canInvert")}var gt=class e extends r.XQb{constructor(e){super(),this.unlinked=!1,this.chartData=[],this.valueColState=[],this.dimensionColState=[],this.columnNames={},this.crossFiltering=!1,this.grouping=!1,this.params=e,this.chartId=e.chartId,this.setParams(e)}setParams(e){const{chartType:t,pivotChart:i,chartThemeName:r,switchCategorySeries:n,aggFunc:s,cellRange:o,suppressChartRanges:a,unlinkChart:l,crossFiltering:c,seriesGroupType:u}=e;this.chartType=t,this.pivotChart=null!=i&&i,this.chartThemeName=r,this.switchCategorySeries=!!n,this.aggFunc=s,this.referenceCellRange=o,this.suppliedCellRange=o,this.suppressChartRanges=null!=a&&a,this.unlinked=!!l,this.crossFiltering=!!c,this.seriesGroupType=u}init(){this.datasource=this.createManagedBean(new Qe),this.chartColumnService=this.createManagedBean(new Xe),this.comboChartModel=this.createManagedBean(new Je(this)),this.updateCellRanges({setColsFromRange:!0}),this.updateData()}updateModel(e){const{cellRange:t,seriesChartTypes:i}=e;t!==this.suppliedCellRange&&(this.dimensionCellRange=void 0,this.valueCellRange=void 0),this.setParams(e),this.updateSelectedDimensions(null==t?void 0:t.columns),this.updateCellRanges({setColsFromRange:!0}),(this.isComboChart()||i)&&this.comboChartModel.update(i),this.unlinked||this.updateData()}updateCellRanges(e){const{updatedColState:t,resetOrder:i,maintainColState:r,setColsFromRange:n}=null!=e?e:{};this.valueCellRange&&(this.referenceCellRange=this.valueCellRange);const{dimensionCols:s,valueCols:o}=this.chartColumnService.getChartColumns(),a=this.getAllColumnsFromRanges();t&&this.updateColumnState(t,i),this.setDimensionCellRange(s,a,t),this.setValueCellRange(o,a,n),t||r||(this.resetColumnState(),this.syncDimensionCellRange()),this.comboChartModel.updateSeriesChartTypes()}updateData(){const{startRow:e,endRow:t}=this.getRowIndexes();this.pivotChart&&this.resetColumnState(),this.grouping=this.isGrouping();const i={aggFunc:this.aggFunc,dimensionCols:this.getSelectedDimensions(),grouping:this.grouping,pivoting:this.isPivotActive(),crossFiltering:this.crossFiltering,valueCols:this.getSelectedValueCols(),startRow:e,endRow:t,isScatter:r._.includes(["scatter","bubble"],this.chartType)},{chartData:n,columnNames:s,groupChartData:o}=this.datasource.getData(i);this.chartData=n,this.groupChartData=o,this.columnNames=s,this.categoryAxisType=void 0}isGrouping(){const e=this.gos.get("treeData"),t=e?null:this.chartColumnService.getRowGroupColumns(),i=e||t&&t.length>0,r=this.getSelectedDimensions().map(({colId:e})=>e),n=this.chartColumnService.getGroupDisplayColumns().map(e=>e.getColId()).some(e=>r.includes(e));return!!i&&n}getSelectedValueCols(){return this.valueColState.filter(e=>e.selected).map(e=>e.column)}getSelectedDimensions(){return this.dimensionColState.filter(e=>e.selected)}getColDisplayName(e){return this.chartColumnService.getColDisplayName(e)}isPivotMode(){return this.chartColumnService.isPivotMode()}getChartDataType(e){const t=this.chartColumnService.getColumn(e);return t?t.getColDef().chartDataType:void 0}isPivotActive(){return this.chartColumnService.isPivotActive()}createCellRange(e,...t){return{id:this.chartId,startRow:this.referenceCellRange.startRow,endRow:this.referenceCellRange.endRow,columns:t,startColumn:e===r.OnL.DIMENSION||null==this.referenceCellRange.startColumn?t[0]:this.referenceCellRange.startColumn,type:e}}getAllColumnsFromRanges(){if(this.pivotChart)return r._.convertToSet(this.chartColumnService.getAllDisplayedColumns());const e=this.dimensionCellRange||this.valueCellRange?[]:this.referenceCellRange.columns;return this.dimensionCellRange&&e.push(...this.dimensionCellRange.columns),this.valueCellRange&&e.push(...this.valueCellRange.columns),r._.convertToSet(e)}getRowIndexes(){let e=0,t=0;const{rangeService:i,valueCellRange:r,dimensionCellRange:n}=this,s=r||n;if(i&&s){e=i.getRangeStartRow(s).rowIndex;const r=i.getRangeEndRow(s);t="bottom"===r.rowPinned?-1:r.rowIndex}return{startRow:e,endRow:t}}resetColumnState(){const{dimensionCols:t,valueCols:i}=this.chartColumnService.getChartColumns(),n=this.getAllColumnsFromRanges(),s=this.valueColState.length<1;this.dimensionColState=[],this.valueColState=[];const o=ot(ct(this.chartType));let a=!1,l=1;const c=this.suppliedCellRange.columns[0];t.forEach(e=>{const t="ag-Grid-AutoColumn"===e.getColId();let i=!1;this.crossFiltering&&this.aggFunc?c.getColId()===e.getColId()&&(i=!0):i=!!t||(!a||o)&&n.has(e),this.dimensionColState.push({column:e,colId:e.getColId(),displayName:this.getColDisplayName(e),selected:i,order:l++}),i&&(a=!0)});const u={colId:e.DEFAULT_CATEGORY,displayName:this.chartTranslationService.translate("defaultCategory"),selected:!a,order:0};this.dimensionColState.unshift(u);const h=this.referenceCellRange.columns.filter(e=>i.has(e));i.forEach(e=>{s&&r._.includes(this.referenceCellRange.columns,e)&&(e=h.shift()),this.valueColState.push({column:e,colId:e.getColId(),displayName:this.getColDisplayName(e),selected:n.has(e),order:l++})})}updateColumnState(e,t){const i=t=>t.colId===e.colId,{dimensionColState:r,valueColState:n}=this,s=r.find(i),o=n.find(i);if(s)if(ot(ct(this.chartType)))s.selected=e.selected;else{const t=e.selected?s:r.filter(e=>e!==s).find(({selected:e})=>e);r.forEach(e=>e.selected=e===t)}else o&&(o.selected=e.selected);const a=[...r,...n],l=[];t||(a.forEach((t,i)=>{i===e.order&&l.push(e.colId),t.colId!==e.colId&&l.push(t.colId)}),a.forEach(e=>{const t=l.indexOf(e.colId);e.order=t>=0?l.indexOf(e.colId):a.length-1})),this.reorderColState()}reorderColState(){const e=(e,t)=>e.order-t.order;this.dimensionColState.sort(e),this.valueColState.sort(e)}setDimensionCellRange(t,i,n){this.dimensionCellRange=void 0;const s=ot(ct(this.chartType));if(!n&&!this.dimensionColState.length){const e=new Array;return t.forEach(t=>{e.length>0&&!s||!i.has(t)||e.push(t)}),void(e.length>0&&(this.dimensionCellRange=this.createCellRange(r.OnL.DIMENSION,...e)))}let o=n?[n]:[];if(this.crossFiltering&&this.aggFunc){const e=this.suppliedCellRange.columns[0];o=this.dimensionColState.filter(t=>t.colId===e.getColId())}else(s||0===o.length||o.some(({column:e})=>!e||!t.has(e)))&&(o=this.dimensionColState.filter(e=>e.selected));const a=1===o.length&&o[0].colId===e.DEFAULT_CATEGORY,l=o.map(({column:e})=>e).filter(e=>null!=e);l.length>0&&!a&&(this.dimensionCellRange=this.createCellRange(r.OnL.DIMENSION,...l))}setValueCellRange(e,t,i){this.valueCellRange=void 0;const n=[],s=dt(this.chartType);let o=0;if(e.forEach(e=>{i?(null==s||o<s)&&t.has(e)&&(n.push(e),o++):this.valueColState.some(t=>t.selected&&t.colId===e.getColId())&&n.push(e)}),n.length>0){let e=[];this.valueColState.length>0?e=this.valueColState.map(e=>e.colId):t.forEach(t=>e.push(t.getColId())),n.sort((t,i)=>e.indexOf(t.getColId())-e.indexOf(i.getColId())),this.valueCellRange=this.createCellRange(r.OnL.VALUE,...n)}}resetCellRanges(e,t){if(!e&&!t)return;const{dimensionCols:i,valueCols:r}=this.chartColumnService.getChartColumns(),n=this.getAllColumnsFromRanges();e&&this.setDimensionCellRange(i,n),t&&this.setValueCellRange(r,n)}updateSelectedDimensions(e){const t=new Set(e.map(e=>e.getColId()));if(ot(ct(this.chartType))){const e=this.dimensionColState.filter(e=>t.has(e.colId)),i=new Set(e.map(e=>e.colId));this.dimensionColState=this.dimensionColState.map(e=>Ke(je({},e),{selected:i.has(e.colId)}))}else{const e=(this.dimensionColState.find(e=>t.has(e.colId))||this.dimensionColState[0]).colId;this.dimensionColState=this.dimensionColState.map(t=>Ke(je({},t),{selected:t.colId===e}))}}syncDimensionCellRange(){const e=this.getSelectedDimensions();if(0===e.length)return;const t=e.map(({column:e})=>e).filter(e=>null!=e);t.length>0&&(this.dimensionCellRange=this.createCellRange(r.OnL.DIMENSION,...t))}isComboChart(e){return tt(null!=e?e:this.chartType)}};gt.DEFAULT_CATEGORY="AG-GRID-DEFAULT-CATEGORY",qe([(0,r.dsm)("rangeService")],gt.prototype,"rangeService",2),qe([(0,r.dsm)("chartTranslationService")],gt.prototype,"chartTranslationService",2),qe([r.o7C],gt.prototype,"init",1);var ft=gt,mt=["number","category","grouped-category","log","time"];function vt(e,t){return!1!==t.clone&&t.isMergeableObject(e)?bt(function(e){return Array.isArray(e)?[]:{}}(e),e,t):e}function Ct(e,t,i){return e.concat(t).map(function(e){return vt(e,i)})}function yt(e){return Object.keys(e).concat(function(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return e.propertyIsEnumerable(t)}):[]}(e))}function wt(e,t){try{return t in e}catch(e){return!1}}function St(e){return function(e){return!!e&&"object"==typeof e}(e)&&!function(e){const t=Object.prototype.toString.call(e);return"[object RegExp]"===t||"[object Date]"===t}(e)}function bt(e,t,i){(i=i||{}).arrayMerge=i.arrayMerge||Ct,i.isMergeableObject=i.isMergeableObject||St,i.cloneUnlessOtherwiseSpecified=vt;const r=Array.isArray(t);return r===Array.isArray(e)?r?i.arrayMerge(e,t,i):function(e={},t={},i){const r={};return i.isMergeableObject(e)&&yt(e).forEach(function(t){r[t]=vt(e[t],i)}),yt(t).forEach(function(n){(function(e,t){return wt(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))})(e,n)||(wt(e,n)&&i.isMergeableObject(t[n])?r[n]=function(e,t){if(!t.customMerge)return bt;const i=t.customMerge(e);return"function"==typeof i?i:bt}(n,i)(e[n],t[n],i):r[n]=vt(t[n],i))}),r}(e,t,i):vt(t,i)}function Et(e,t,i){if(null==e)return i;const r=t.split(".");let n=e;for(;r.length>1;)if(n=n[r.shift()],null==n)return i;const s=n[r[0]];return null!=s?s:i}function At(e){return r._.includes(Object.keys(n._Theme.themes),e)}var Tt=mt.reduce((e,t)=>Ke(je({},e),{[t]:{title:{_enabledFromTheme:!0}}}),{});function Mt(e,t,i){const r=e.getExtraPaddingDirections();return{common:Ke(je({},t?{animation:{duration:500}}:void 0),{axes:Tt,padding:{top:!i&&r.includes("top")?40:20,right:r.includes("right")?30:20,bottom:r.includes("bottom")?40:20,left:r.includes("left")?30:20}}),pie:{series:{title:{_enabledFromTheme:!0},calloutLabel:{_enabledFromTheme:!0},sectorLabel:{enabled:!1,_enabledFromTheme:!0}}},donut:{series:{title:{_enabledFromTheme:!0},calloutLabel:{_enabledFromTheme:!0},sectorLabel:{enabled:!1,_enabledFromTheme:!0}}}}}function Rt(e,t){const{customChartThemes:i}=e,r=i&&i[t];return r||console.warn(`AG Grid: no stock theme exists with the name '${t}' and no custom chart theme with that name was supplied to 'customChartThemes'`),r}var _t=e=>t=>null==t||e(t),Pt=e=>"string"==typeof e,xt=e=>"boolean"==typeof e,Dt=e=>"object"==typeof e,It=(e,t)=>i=>`AG Grid - unable to update chart as invalid params supplied:  \`${e}: ${i}\`, expected ${t}.`,Lt=e=>`${e} is not supported in AG Charts Community (either 'ag-grid-charts-enterprise' or '@ag-grid-enterprise/charts-enterprise' hasn't been loaded). See https://www.ag-grid.com/javascript-data-grid/integrated-charts-installation/ for more details.`,Nt=class e{static isEnterprise(){return n._ModuleSupport.enterpriseModule.isEnterprise}static isValidChartType(e){return!!lt(e)||tt(e)}static isLegacyChartType(t){return e.legacyChartTypes.includes(t)}static validateUpdateParams(t){switch(t.type){case"rangeChartUpdate":return e.validateUpdateRangeChartParams(t);case"pivotChartUpdate":return e.validateUpdatePivotChartParams(t);case"crossFilterChartUpdate":return e.validateUpdateCrossFilterChartParams(t);default:return console.warn(`AG Grid - Invalid value supplied for 'type': ${t.type}. It must be either 'rangeChartUpdate', 'pivotChartUpdate', or 'crossFilterChartUpdate'.`),!1}}static validateCreateParams(t){return e.validateProperties(t,[e.enterpriseChartTypeValidation,e.switchCategorySeriesValidation])}static validateUpdateRangeChartParams(t){const i=[...e.commonUpdateValidations,e.enterpriseChartTypeValidation,...e.cellRangeValidations,{property:"seriesChartTypes",validationFn:e=>void 0===e||Array.isArray(e)&&e.every(Dt),warnMessage:It("seriesChartTypes","Array of SeriesChartType")}];return e.validateProperties(t,i,[...e.baseUpdateChartParams,"cellRange","suppressChartRanges","switchCategorySeries","aggFunc","seriesChartTypes","seriesGroupType"],"UpdateRangeChartParams")}static validateUpdatePivotChartParams(t){const i=[...e.commonUpdateValidations];return e.validateProperties(t,i,[...e.baseUpdateChartParams],"UpdatePivotChartParams")}static validateUpdateCrossFilterChartParams(t){const i=[...e.commonUpdateValidations,...e.cellRangeValidations];return e.validateProperties(t,i,[...e.baseUpdateChartParams,"cellRange","suppressChartRanges","aggFunc"],"UpdateCrossFilterChartParams")}static validateProperties(e,t,i,r){let n;for(const i of t){const{property:t,validationFn:r,warnMessage:s,warnIfFixed:o}=i;if(t in e){const i=e[t],a=r(i);if(!0===a)continue;if(!1===a)return console.warn(s(i)),!1;n=n||je({},e),n[t]=a,o&&console.warn(s(i))}}if(i)for(const t in e)if(!i.includes(t))return console.warn(`AG Grid - Unexpected property supplied. ${r} does not contain: \`${t}\`.`),!1;return n||!0}};Nt.legacyChartTypes=["doughnut"],Nt.baseUpdateChartParams=["type","chartId","chartType","chartThemeName","chartThemeOverrides","unlinkChart"],Nt.validateChartType=_t(e=>{if(Nt.isValidChartType(e))return!0;if(Nt.isLegacyChartType(e)){const t=at(e);return r._.warnOnce(`The chart type '${e}' has been deprecated. Please use '${t}' instead.`),t}return!1}),Nt.validateAgChartThemeOverrides=_t(e=>"object"==typeof e),Nt.validateChartParamsCellRange=_t(e=>"object"==typeof e),Nt.validateAggFunc=_t(e=>"string"==typeof e||"function"==typeof e),Nt.enterpriseChartTypeValidation={property:"chartType",validationFn:_t(e=>Nt.isEnterprise()||!e||!function(e){return it(ct(e),"isEnterprise")}(e)),warnMessage:e=>Lt(`The '${e}' chart type`)},Nt.switchCategorySeriesValidation={property:"switchCategorySeries",validationFn:_t(e=>{if(!e||Nt.isEnterprise())return!0}),warnMessage:()=>Lt("'switchCategorySeries' has been ignored as it"),warnIfFixed:!0},Nt.commonUpdateValidations=[{property:"chartId",validationFn:Pt,warnMessage:It("chartId","string")},{property:"chartType",validationFn:Nt.validateChartType,warnMessage:It("chartType","ChartType")},{property:"chartThemeName",validationFn:Pt,warnMessage:It("chartThemeName","string")},{property:"chartThemeOverrides",validationFn:Nt.validateAgChartThemeOverrides,warnMessage:It("chartThemeOverrides","AgChartThemeOverrides")},{property:"unlinkChart",validationFn:xt,warnMessage:It("unlinkChart","boolean")}],Nt.cellRangeValidations=[{property:"cellRange",validationFn:Nt.validateChartParamsCellRange,warnMessage:It("cellRange","ChartParamsCellRange")},{property:"suppressChartRanges",validationFn:xt,warnMessage:It("suppressChartRanges","boolean")},{property:"aggFunc",validationFn:Nt.validateAggFunc,warnMessage:It("aggFunc","string or IAggFunc")},Nt.switchCategorySeriesValidation];var Ot=Nt,Ft=["ag-default","ag-material","ag-sheets","ag-polychroma","ag-vivid"],kt=class e extends r.XQb{constructor(e){super(),this.model=e,this.isEnterprise=()=>n._ModuleSupport.enterpriseModule.isEnterprise}init(){this.setChartRange(),this.addManagedListener(this.eventService,r.sVA.EVENT_RANGE_SELECTION_CHANGED,e=>{e.id&&e.id===this.model.chartId&&this.updateForRangeChange()}),this.model.unlinked&&this.rangeService&&this.rangeService.setCellRanges([]),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_MOVED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PINNED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_VISIBLE,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,this.updateForGridChange.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_CELL_VALUE_CHANGED,this.updateForDataChange.bind(this))}update(e){if(!this.validUpdateType(e))return!1;const t=Ot.validateUpdateParams(e);if(!t)return!1;const i=!0===t?e:t;return this.applyValidatedChartParams(i),!0}applyValidatedChartParams(e){var t,i,r,n,s,o,a,l,c;const{chartId:u,chartType:h,chartThemeName:d,unlinkChart:p}=e,g={chartId:u,pivotChart:this.model.pivotChart,chartType:null!=h?h:this.model.chartType,chartThemeName:null!=d?d:this.model.chartThemeName,unlinkChart:null!=p?p:this.model.unlinked,cellRange:this.model.suppliedCellRange,switchCategorySeries:this.model.switchCategorySeries,aggFunc:this.model.aggFunc,seriesChartTypes:void 0,suppressChartRanges:!1,crossFiltering:!1};let f=je({},g);switch(e.type){case"rangeChartUpdate":f.cellRange=null!=(t=this.createCellRange(e))?t:this.model.suppliedCellRange,f.switchCategorySeries=null!=(i=e.switchCategorySeries)?i:this.model.switchCategorySeries,f.aggFunc=null!=(r=e.aggFunc)?r:this.model.aggFunc,f.seriesChartTypes=e.seriesChartTypes,f.suppressChartRanges=null!=(n=e.suppressChartRanges)?n:this.model.suppressChartRanges,f.seriesGroupType=null!=(s=e.seriesGroupType)?s:this.model.seriesGroupType;break;case"crossFilterChartUpdate":f.cellRange=null!=(o=this.createCellRange(e))?o:this.model.suppliedCellRange,f.switchCategorySeries=!1,f.aggFunc=null!=(a=e.aggFunc)?a:this.model.aggFunc,f.crossFiltering=!0,f.suppressChartRanges=null!=(l=e.suppressChartRanges)?l:this.model.suppressChartRanges;break;case"pivotChartUpdate":f.switchCategorySeries=!1}this.model.updateModel(f),f.unlinkChart||f.suppressChartRanges?null==(c=this.rangeService)||c.setCellRanges([]):this.setChartRange()}updateForGridChange(e){if(this.model.unlinked)return;const{maintainColState:t,setColsFromRange:i}=null!=e?e:{};this.model.updateCellRanges({maintainColState:t,setColsFromRange:i}),this.model.updateData(),this.setChartRange()}updateForDataChange(){this.model.unlinked||(this.model.updateData(),this.raiseChartModelUpdateEvent())}updateForRangeChange(){this.updateForGridChange({setColsFromRange:!0}),this.raiseChartRangeSelectionChangedEvent()}updateForPanelChange(e){this.model.updateCellRanges(e),this.model.updateData(),e.skipAnimation&&this.getChartProxy().getChartRef().skipAnimations(),this.setChartRange(),this.raiseChartRangeSelectionChangedEvent()}updateThemeOverrides(e){this.chartProxy.updateThemeOverrides(e)}getChartUpdateParams(e){const t=this.getSelectedValueColState().map(e=>({colId:e.colId,displayName:e.displayName})),i=this.getChartData(),r=this.getSelectedDimensions(),n={data:i,groupData:this.model.groupChartData,grouping:this.isGrouping(),categories:r.map(e=>{var t;return{id:e.colId,name:e.displayName,chartDataType:null!=(t=this.model.categoryAxisType)?t:this.model.getChartDataType(e.colId)}}),fields:t,chartId:this.getChartId(),getCrossFilteringContext:()=>({lastSelectedChartId:"xxx"}),seriesChartTypes:this.getSeriesChartTypes(),updatedOverrides:e,seriesGroupType:this.model.seriesGroupType};return this.isCategorySeriesSwitched()?this.invertCategorySeriesParams(n):n}invertCategorySeriesParams(e){const[t]=e.categories,i=[{id:ft.DEFAULT_CATEGORY,name:""}],r=e.data.map((e,i)=>{const r=`${t.id}:${i}`,n=e[t.id];return{colId:r,displayName:null==n?"":String(n)}}),n=e.fields.map(i=>{const r={[ft.DEFAULT_CATEGORY]:i.displayName};for(const[n,s]of e.data.entries()){const e=`${t.id}:${n}`,o=s[i.colId];r[e]=o}return r});return Ke(je({},e),{categories:i,fields:r,data:n})}getChartModel(){const e=this.model.pivotChart?"pivot":"range",t=this.isComboChart()?this.model.comboChartModel.seriesChartTypes:void 0;return{modelType:e,chartId:this.model.chartId,chartType:this.model.chartType,chartThemeName:this.getChartThemeName(),chartOptions:this.chartProxy.getChartThemeOverrides(),chartPalette:this.chartProxy.getChartPalette(),cellRange:this.getCellRangeParams(),switchCategorySeries:this.model.switchCategorySeries,suppressChartRanges:this.model.suppressChartRanges,aggFunc:this.model.aggFunc,unlinkChart:this.model.unlinked,seriesChartTypes:t,seriesGroupType:this.model.seriesGroupType}}getChartId(){return this.model.chartId}getChartData(){return this.model.chartData}getChartType(){return this.model.chartType}setChartType(e){this.updateMultiSeriesAndCategory(this.model.chartType,e),this.model.chartType=e,this.model.comboChartModel.updateSeriesChartTypes(),this.model.switchCategorySeries=!1,this.model.categoryAxisType=void 0,this.model.seriesGroupType=void 0,this.raiseChartModelUpdateEvent(),this.raiseChartOptionsChangedEvent()}isCategorySeriesSwitched(){return this.model.switchCategorySeries&&!this.model.isGrouping()}switchCategorySeries(e){pt(this.getChartType())&&(this.model.switchCategorySeries=e,this.raiseChartModelUpdateEvent())}getAggFunc(){return this.model.aggFunc}setAggFunc(e,t){this.model.aggFunc!==e&&(this.model.aggFunc=e,t||(this.model.updateData(),this.raiseChartModelUpdateEvent()))}updateMultiSeriesAndCategory(e,t){var i,r;const n=(e,t)=>{let i=0;for(const r of e)r.selected&&(i>=t?r.selected=!1:i++);0===i&&(e[0].selected=!0)},s=ht(t),o=dt(t),a=null!=s&&(null!=(i=ht(e))?i:100)>(null!=s?s:100),l=null!=o&&(null!=(r=dt(e))?r:100)>(null!=o?o:100);a&&n(this.model.dimensionColState,s),l&&n(this.model.valueColState,o),(a||l)&&(this.model.resetCellRanges(a,l),this.setChartRange(!0))}setChartThemeName(e,t){this.model.chartThemeName=e,t||(this.raiseChartModelUpdateEvent(),this.raiseChartOptionsChangedEvent())}getChartThemeName(){return this.model.chartThemeName}isPivotChart(){return this.model.pivotChart}isPivotMode(){return this.model.isPivotMode()}isGrouping(){return this.model.isGrouping()}isCrossFilterChart(){return this.model.crossFiltering}getThemeNames(){return this.gos.get("chartThemes")||Ft}getThemes(){return this.getThemeNames().map(e=>{const t=At(e)?e:this.chartProxy.lookupCustomChartTheme(e);return n._Theme.getChartTheme(t)})}getPalettes(){return this.getThemes().map(e=>e.palette)}getThemeTemplateParameters(){return this.getThemes().map(e=>e.getTemplateParameters())}getValueColState(){return this.model.valueColState.map(this.displayNameMapper.bind(this))}getSelectedValueColState(){return this.getValueColState().filter(e=>e.selected)}getSelectedDimensions(){return this.model.getSelectedDimensions()}displayNameMapper(e){const t=this.model.columnNames[e.colId];return e.displayName=t?t.join(" - "):this.model.getColDisplayName(e.column),e}getColStateForMenu(){return{dimensionCols:this.model.dimensionColState,valueCols:this.getValueColState()}}setChartRange(e=!1){!this.rangeService||this.model.suppressChartRanges||this.model.unlinked||this.rangeService.setCellRanges(this.getCellRanges()),e||this.raiseChartModelUpdateEvent()}detachChartRange(){this.model.unlinked=!this.model.unlinked,this.model.unlinked?this.rangeService&&this.rangeService.setCellRanges([]):this.updateForGridChange(),this.dispatchEvent({type:e.EVENT_CHART_LINKED_CHANGED})}setChartProxy(e){this.chartProxy=e}getChartProxy(){return this.chartProxy}isActiveXYChart(){return r._.includes(["scatter","bubble"],this.getChartType())}isChartLinked(){return!this.model.unlinked}customComboExists(){const e=this.model.comboChartModel.savedCustomSeriesChartTypes;return e&&e.length>0}getSeriesChartTypes(){return this.model.comboChartModel.seriesChartTypes}isComboChart(e){return this.model.isComboChart(e)}updateSeriesChartType(t,i,r){const n=this.model.comboChartModel.seriesChartTypes.find(e=>e.colId===t);if(n){const t="customCombo"!==this.model.chartType;t&&(this.model.chartType="customCombo");const s=n.chartType;null!=i&&(n.chartType=i),null!=r&&(n.secondaryAxis=r),this.model.comboChartModel.savedCustomSeriesChartTypes=this.model.comboChartModel.seriesChartTypes,this.model.comboChartModel.updateSeriesChartTypes(),this.updateForDataChange(),t&&this.dispatchEvent({type:e.EVENT_CHART_TYPE_CHANGED}),s!==i&&this.dispatchEvent({type:e.EVENT_CHART_SERIES_CHART_TYPE_CHANGED}),this.raiseChartOptionsChangedEvent()}}getActiveSeriesChartTypes(){const e=this.getSelectedValueColState().map(e=>e.colId);return this.getSeriesChartTypes().filter(t=>e.includes(t.colId))}getChartSeriesTypes(e){const t=null!=e?e:this.getChartType();return this.isComboChart(t)?["line","bar","area"]:[ct(t)]}getChartSeriesType(){const e=this.getSeriesChartTypes();if(0===e.length)return"bar";const t=e[0].chartType;return"columnLineCombo"===t?"bar":"areaColumnCombo"===t?"area":ct(t)}getCellRanges(){return[this.model.dimensionCellRange,this.model.valueCellRange].filter(e=>e)}createCellRange(e){var t;return e.cellRange&&(null==(t=this.rangeService)?void 0:t.createPartialCellRangeFromRangeParams(e.cellRange,!0))}validUpdateType(e){var t;if(!e.type)return console.warn("AG Grid - Unable to update chart as the 'type' is missing. It must be either 'rangeChartUpdate', 'pivotChartUpdate', or 'crossFilterChartUpdate'."),!1;const i={"Range Chart":()=>!this.isPivotChart()&&!this.isCrossFilterChart(),"Pivot Chart":()=>this.isPivotChart(),"Cross Filter Chart":()=>this.isCrossFilterChart()},r=null!=(t=Object.keys(i).find(e=>i[e]()))?t:"Range Chart",n=e.type===`${r[0].toLowerCase()}${r.slice(1).replace(/ /g,"")}Update`;return n||console.warn(`AG Grid - Unable to update chart as a '${e.type}' update type is not permitted on a ${r}.`),n}getCellRangeParams(){const e=this.getCellRanges(),t=e[0],i=t&&t.startRow||null,r=t&&t.endRow||null;return{rowStartIndex:i&&i.rowIndex,rowStartPinned:i&&i.rowPinned,rowEndIndex:r&&r.rowIndex,rowEndPinned:r&&r.rowPinned,columns:e.reduce((e,t)=>e.concat(t.columns.map(e=>e.getId())),[])}}setCategoryAxisType(e){this.model.categoryAxisType=e,this.raiseChartModelUpdateEvent()}getSeriesGroupType(){var e;return null!=(e=this.model.seriesGroupType)?e:this.chartProxy.getSeriesGroupType()}setSeriesGroupType(e){this.model.seriesGroupType=e,this.raiseChartModelUpdateEvent()}raiseChartModelUpdateEvent(){const t={type:e.EVENT_CHART_MODEL_UPDATE};this.dispatchEvent(t)}raiseChartUpdatedEvent(){const t={type:e.EVENT_CHART_UPDATED};this.dispatchEvent(t)}raiseChartApiUpdateEvent(){const t={type:e.EVENT_CHART_API_UPDATE};this.dispatchEvent(t)}raiseChartOptionsChangedEvent(){const{chartId:e,chartType:t}=this.getChartModel(),i={type:r.sVA.EVENT_CHART_OPTIONS_CHANGED,chartId:e,chartType:t,chartThemeName:this.getChartThemeName(),chartOptions:this.chartProxy.getChartThemeOverrides()};this.eventService.dispatchEvent(i)}raiseChartRangeSelectionChangedEvent(){const e={type:r.sVA.EVENT_CHART_RANGE_SELECTION_CHANGED,id:this.model.chartId,chartId:this.model.chartId,cellRange:this.getCellRangeParams()};this.eventService.dispatchEvent(e)}destroy(){super.destroy(),this.rangeService&&this.rangeService.setCellRanges([])}};kt.EVENT_CHART_UPDATED="chartUpdated",kt.EVENT_CHART_API_UPDATE="chartApiUpdate",kt.EVENT_CHART_MODEL_UPDATE="chartModelUpdate",kt.EVENT_CHART_TYPE_CHANGED="chartTypeChanged",kt.EVENT_CHART_SERIES_CHART_TYPE_CHANGED="chartSeriesChartTypeChanged",kt.EVENT_CHART_LINKED_CHANGED="chartLinkedChanged",qe([(0,r.dsm)("rangeService")],kt.prototype,"rangeService",2),qe([r.o7C],kt.prototype,"init",1);var Gt=kt,Vt=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.config=null!=t?t:{};const{selectedValueList:i,valueFormatter:n,valueList:s}=this.config;this.selectedValues=null!=i?i:[],this.valueList=null!=s?s:[],this.valueFormatter=null!=n?n:e=>r._.escapeString(e)}init(){const{ariaLabel:e,onValuesChange:t,dragSourceId:i}=this.config;this.dropZonePanel=this.createManagedBean(new zt({getValues:()=>this.selectedValues,setValues:e=>this.updateValues(e),isDraggable:()=>this.selectedValues.length>1},e=>this.valueFormatter(e),e,i)),this.getGui().appendChild(this.dropZonePanel.getGui()),this.initSelect(),null!=t&&(this.onValuesChange=t)}setValues(e,t){const{added:i,removed:r,updated:n}=this.getChanges(this.valueList,e);let s=!1;return(i.length||r.length||n.length)&&(s=!0),this.valueList=e,this.updateValues(t,s,!0),this}setValueFormatter(e){return this.valueFormatter=e,this}initSelect(){const e=this.createSelectOptions();if(!e.length)return!1;const{selectPlaceholder:t}=this.config;return this.eSelect=this.createBean(new r.Ju4({options:e,placeholder:t,onValueChange:e=>this.addValue(e),pickerIcon:"chartsMenuAdd"})),this.getGui().appendChild(this.eSelect.getGui()),!0}createSelectOptions(){let e=[];const{maxSelection:t}=this.config;return t&&this.selectedValues.length>=t||this.valueList.forEach(t=>{this.selectedValues.includes(t)||e.push({value:t,text:this.valueFormatter(t)})}),e}addValue(e){this.dropZonePanel.addItem(e)}updateValues(e,t,i){var r,n,s,o,a;const l=this.selectedValues;this.selectedValues=e;const c=this.getChanges(l,e),u=t||c.added.length||c.removed.length,h=this.gos.getActiveDomElement(),d=null==(r=this.eSelect)?void 0:r.getGui().contains(h),p=null==(n=this.dropZonePanel)?void 0:n.getGui().contains(h);i||null==(s=this.onValuesChange)||s.call(this,c);const g=!!u&&!this.refreshSelect();this.dropZonePanel.refreshGui(),u&&d&&(g?this.dropZonePanel.focusList(!0):null==(o=this.eSelect)||o.getFocusableElement().focus()),p&&!e.length&&(null==(a=this.eSelect)||a.getFocusableElement().focus())}getChanges(e,t){return{added:t.filter(t=>!e.includes(t)),removed:e.filter(e=>!t.includes(e)),updated:t.filter((t,i)=>e[i]!==t),selected:t}}refreshSelect(){if(!this.eSelect)return this.initSelect();const e=this.createSelectOptions();return e.length?(this.eSelect.clearOptions().addOptions(e).setValue(void 0,!0),!0):(r._.removeFromParent(this.eSelect.getGui()),this.eSelect=this.destroyBean(this.eSelect),!1)}destroy(){this.destroyBean(this.eSelect),super.destroy()}};Vt.TEMPLATE='<div class="ag-pill-select" role="presentation"></div>',qe([r.o7C],Vt.prototype,"init",1);var Ht=Vt,Bt=class extends r.v26{constructor(e,t,i,r,n,s){super(t,i,!1),this.value=e,this.valueFormatter=r,this.draggable=n,this.sourceId=s}getItem(){return this.value}getDisplayName(){return this.valueFormatter(this.value)}getAriaDisplayName(){return this.getDisplayName()}getTooltip(){}createGetDragItem(){return()=>({value:this.value})}getDragSourceType(){return r.qRA.ChartPanel}getDragSourceId(){return this.sourceId}isDraggable(){return this.draggable}},zt=class extends r.fNO{constructor(e,t,i,r){super(!1),this.model=e,this.valueFormatter=t,this.ariaLabel=i,this.sourceId=r}postConstruct(){super.init()}isItemDroppable(e,t){return this.isSourceEventFromTarget(t)||null!=this.sourceId&&this.sourceId===t.dragSource.sourceId}updateItems(e){this.model.setValues(e)}getExistingItems(){return this.model.getValues()}getIconName(){return this.isPotentialDndItems()?r.WO_.ICON_MOVE:r.WO_.ICON_NOT_ALLOWED}getAriaLabel(){return this.ariaLabel}createPillComponent(e,t,i){return new Bt(e,t,i,this.valueFormatter,this.model.isDraggable(),this.sourceId)}getItems(e){return[e.value]}isInterestedIn(e){return e===r.qRA.ChartPanel}};qe([r.o7C],zt.prototype,"postConstruct",1);var Ut=class extends r.uAl{constructor(e,t,i,r,n){super(n),this.chartController=e,this.autoScrollService=t,this.allowMultipleSelection=i,this.maxSelection=r,this.columnComps=new Map}refreshColumnComps(e){return!!r._.areEqual(r._.keys(this.columnComps),e.map(({colId:e})=>e))&&(e.forEach(e=>{this.columnComps.get(e.colId).setValue(e.selected,!0)}),!0)}createGroup(e,t,i,n,s){if(this.allowMultipleSelection){const r=e.filter(e=>e.selected);this.valuePillSelect=this.groupComp.createManagedBean(new Ht({valueList:e,selectedValueList:r,valueFormatter:t,selectPlaceholder:this.chartTranslationService.translate(i),dragSourceId:n,onValuesChange:e=>this.onValueChange(e),maxSelection:this.maxSelection})),this.groupComp.addItem(this.valuePillSelect)}else{const t=this.createValueSelectParams(e);t.onValueChange=t=>{e.forEach(e=>{e.selected=!1}),t.selected=!0,t.colId===ft.DEFAULT_CATEGORY&&this.chartController.setAggFunc(void 0,!0),this.chartController.updateForPanelChange({updatedColState:t,skipAnimation:null==s?void 0:s()})},this.valueSelect=this.groupComp.createManagedBean(new r.Ju4(t)),this.groupComp.addItem(this.valueSelect)}}refreshValueSelect(e){if(!this.valueSelect)return;const{options:t,value:i}=this.createValueSelectParams(e);this.valueSelect.clearOptions().addOptions(t).setValue(i,!0)}createValueSelectParams(e){let t;return{options:e.map(e=>{var i;const r=null!=(i=e.displayName)?i:"";return e.selected&&(t=e),{value:e,text:r}}),value:t}}onDragging(e){const t=this.checkHoveredItem(e);if(!t)return;this.lastDraggedColumn=e.dragItem.columns[0];const{comp:i,position:r}=t,{comp:n,position:s}=this.lastHoveredItem||{};i===n&&r===s||(this.autoScrollService.check(e.event),this.clearHoveredItems(),this.lastHoveredItem={comp:i,position:r},i.getGui().classList.add("ag-list-item-hovered",`ag-item-highlight-${r}`))}checkHoveredItem(e){if(r._.missing(e.vDirection))return null;const t=e.event;for(const e of this.columnComps.values()){const i=e.getGui();if(!i.querySelector(".ag-chart-data-column-drag-handle"))continue;const r=i.getBoundingClientRect();if(t.clientY>=r.top&&t.clientY<=r.bottom){const n=i.clientHeight;return{comp:e,position:t.clientY>r.top+n/2?"bottom":"top"}}}return null}onDragLeave(){this.clearHoveredItems()}onDragStop(){if(this.lastHoveredItem){const{dimensionCols:e,valueCols:t}=this.chartController.getColStateForMenu(),i=[...e,...t].find(e=>e.column===this.lastDraggedColumn);if(i){let e=Array.from(this.columnComps.values()).indexOf(this.lastHoveredItem.comp);"bottom"===this.lastHoveredItem.position&&e++,i.order=e,this.chartController.updateForPanelChange({updatedColState:i})}}this.clearHoveredItems(),this.lastDraggedColumn=void 0,this.autoScrollService.ensureCleared()}clearHoveredItems(){this.columnComps.forEach(e=>{e.getGui().classList.remove("ag-list-item-hovered","ag-item-highlight-top","ag-item-highlight-bottom")}),this.lastHoveredItem=void 0}addDragHandle(e,t){const i=r._.createIconNoSpan("columnDrag",this.gos);i.classList.add("ag-drag-handle","ag-chart-data-column-drag-handle"),e.getGui().insertAdjacentElement("beforeend",i);const n={type:r.qRA.ChartPanel,eElement:i,dragItemName:t.displayName,getDragItem:()=>({columns:[t.column]}),onDragStopped:()=>this.onDragStop()};this.dragAndDropService.addDragSource(n,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(n))}addChangeListener(e,t){this.addManagedListener(e,r.sVA.EVENT_FIELD_VALUE_CHANGED,()=>{t.selected=e.getValue(),this.chartController.updateForPanelChange({updatedColState:t})})}isInterestedIn(e){return e===r.qRA.ChartPanel}onValueChange({added:e,updated:t,removed:i,selected:r}){let n,s;const o=()=>{r.forEach((e,t)=>{e.order=t}),s=!0};e.length?(n=e[0],n.selected=!0,o()):i.length?(n=i[0],n.selected=!1):t.length&&(o(),n=t[0]),n&&this.chartController.updateForPanelChange({updatedColState:n,resetOrder:s})}destroy(){this.valuePillSelect=void 0,this.valueSelect=void 0,super.destroy()}};qe([(0,r.dsm)("dragAndDropService")],Ut.prototype,"dragAndDropService",2),qe([(0,r.dsm)("chartTranslationService")],Ut.prototype,"chartTranslationService",2);var Wt=class e extends Ut{constructor(t,i,r,n,s,o){super(t,i,n,void 0,e.TEMPLATE),this.title=r,this.dimensionCols=s,this.isOpen=o}init(){this.groupComp=this.createBean(new r.Pk_({title:this.title,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen})),this.chartMenuService.isLegacyFormat()?(this.createLegacyCategoriesGroup(this.dimensionCols),this.clearAggFuncControls()):(this.createCategoriesGroup(this.dimensionCols),this.createAggFuncControls(this.dimensionCols)),this.getGui().appendChild(this.groupComp.getGui())}refresh(e){var t;this.chartMenuService.isLegacyFormat()?this.refreshColumnComps(e)||this.recreate(e):(null==(t=this.valuePillSelect)||t.setValues(e,e.filter(e=>e.selected)),this.refreshValueSelect(e),this.refreshAggFuncControls(e,this.chartController.getAggFunc()))}recreate(e){this.isOpen=this.groupComp.isExpanded(),r._.clearElement(this.getGui()),this.destroyBean(this.groupComp),this.dimensionCols=e,this.init()}createCategoriesGroup(e){this.createGroup(e,e=>{var t;return null!=(t=e.displayName)?t:""},"categoryAdd","categorySelect",()=>!this.chartController.getAggFunc())}createLegacyCategoriesGroup(e){const t=`chartDimension${this.groupComp.getCompId()}`,i=this.allowMultipleSelection;if(e.forEach(e=>{var n;const s={label:null!=(n=e.displayName)?n:"",value:e.selected,inputName:t},o=this.groupComp.createManagedBean(i?(()=>{const e=new r.Unm(s);return e.addCssClass("ag-data-select-checkbox"),e})():new r.OQA(s));this.addChangeListener(o,e),this.groupComp.addItem(o),this.columnComps.set(e.colId,o),i&&this.addDragHandle(o,e)}),i){const e=this.groupComp.getGui(),t={getIconName:()=>r.WO_.ICON_MOVE,getContainer:()=>e,onDragging:e=>this.onDragging(e),onDragLeave:()=>this.onDragLeave(),isInterestedIn:this.isInterestedIn.bind(this),targetContainsSource:!0};this.dragAndDropService.addDropTarget(t),this.addDestroyFunc(()=>this.dragAndDropService.removeDropTarget(t))}}createAggFuncControls(e){const t=this.chartController.getAggFunc();this.groupComp.addItem(this.aggFuncToggle=this.createBean(new r.bLJ({label:this.chartTranslationService.translate("aggregate"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:null!=t,onValueChange:e=>{var t,i;const r=e?"sum":void 0;this.chartController.setAggFunc(r),null==(t=this.aggFuncSelect)||t.setValue(r,!0),null==(i=this.aggFuncSelect)||i.setDisplayed(null!=r)}}))),this.groupComp.addItem(this.aggFuncSelect=this.createBean(new r.Ju4({options:[{value:"sum",text:this.chartTranslationService.translate("sum")},{value:"first",text:this.chartTranslationService.translate("first")},{value:"last",text:this.chartTranslationService.translate("last")},{value:"min",text:this.chartTranslationService.translate("min")},{value:"max",text:this.chartTranslationService.translate("max")},{value:"count",text:this.chartTranslationService.translate("count")},{value:"avg",text:this.chartTranslationService.translate("avg")}],value:"string"==typeof t?t:void 0,onValueChange:e=>{this.chartController.setAggFunc(e)}}))),this.refreshAggFuncControls(e,t)}refreshAggFuncControls(e,t){var i,r,n,s;const o=e.filter(e=>e.selected).some(e=>e.colId!==ft.DEFAULT_CATEGORY);null==(i=this.aggFuncToggle)||i.setValue(null!=t),null==(r=this.aggFuncSelect)||r.setValue("string"==typeof t?t:void 0,!0),null==(n=this.aggFuncToggle)||n.setDisplayed(o),null==(s=this.aggFuncSelect)||s.setDisplayed(o&&null!=t)}clearAggFuncControls(){this.aggFuncToggle=this.aggFuncToggle&&this.destroyBean(this.aggFuncToggle),this.aggFuncSelect=this.aggFuncSelect&&this.destroyBean(this.aggFuncSelect)}destroy(){this.clearAggFuncControls(),this.groupComp=this.destroyBean(this.groupComp),super.destroy()}};Wt.TEMPLATE='<div id="categoriesGroup"></div>',qe([(0,r.dsm)("chartMenuService")],Wt.prototype,"chartMenuService",2),qe([r.o7C],Wt.prototype,"init",1);var jt=Wt,Kt=class e extends Ut{constructor(t,i,r,n,s,o,a,l){super(t,i,s,o,e.TEMPLATE),this.chartOptionsService=r,this.title=n,this.valueCols=a,this.isOpen=l}init(){if(this.groupComp=this.createBean(new r.Pk_({title:this.title,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen})),this.chartController.isActiveXYChart()){const e=this.groupComp.createManagedBean(new r.bLJ({label:this.chartTranslationService.translate("paired"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:this.chartOptionsService.getPairedMode(),onValueChange:e=>{this.chartOptionsService.setPairedMode(!!e),this.chartController.updateForGridChange({maintainColState:!0})}}));this.groupComp.addItem(e)}this.chartMenuService.isLegacyFormat()?this.createLegacySeriesGroup(this.valueCols):this.createSeriesGroup(this.valueCols),this.getGui().appendChild(this.groupComp.getGui())}refresh(e){var t,i;if(this.chartMenuService.isLegacyFormat())if(this.refreshColumnComps(e)){if(this.chartController.isActiveXYChart()){const t=this.generateGetSeriesLabel(e);e.forEach(e=>{this.columnComps.get(e.colId).setLabel(t(e))})}}else this.recreate(e);else null==(t=this.valuePillSelect)||t.setValueFormatter(this.generateGetSeriesLabel(e)),null==(i=this.valuePillSelect)||i.setValues(e,e.filter(e=>e.selected)),this.refreshValueSelect(e)}recreate(e){this.isOpen=this.groupComp.isExpanded(),r._.clearElement(this.getGui()),this.destroyBean(this.groupComp),this.valueCols=e,this.init()}createSeriesGroup(e){this.createGroup(e,this.generateGetSeriesLabel(e),"seriesAdd","seriesSelect")}createLegacySeriesGroup(e){const t=this.generateGetSeriesLabel(e);e.forEach(e=>{const i=t(e),n=this.groupComp.createManagedBean(new r.Unm({label:i,value:e.selected}));n.addCssClass("ag-data-select-checkbox"),this.addChangeListener(n,e),this.groupComp.addItem(n),this.columnComps.set(e.colId,n),this.addDragHandle(n,e)});const i=this.groupComp.getGui(),n={getIconName:()=>r.WO_.ICON_MOVE,getContainer:()=>i,onDragging:e=>this.onDragging(e),onDragLeave:()=>this.onDragLeave(),isInterestedIn:this.isInterestedIn.bind(this),targetContainsSource:!0};this.dragAndDropService.addDropTarget(n),this.addDestroyFunc(()=>this.dragAndDropService.removeDropTarget(n))}generateGetSeriesLabel(e){if(!this.chartController.isActiveXYChart())return e=>{var t;return null!=(t=e.displayName)?t:""};const t=e.filter(e=>e.selected),i="bubble"===this.chartController.getChartType(),r=this.chartOptionsService.getPairedMode(),n=new Map;return n.set(0,"X"),n.set(1,"Y"),n.set(2,"size"),e=>{var s;const o=null!=(s=e.displayName)?s:"";if(!e.selected)return o;const a=t.indexOf(e);if(-1===a)return o;let l;return l=r?n.get(a%(i?3:2)):0===a?"X":i&&a%2==0?"size":"Y",`${o} (${l})`}}destroy(){this.groupComp=this.destroyBean(this.groupComp),super.destroy()}};Kt.TEMPLATE='<div id="seriesGroup"></div>',qe([(0,r.dsm)("chartMenuService")],Kt.prototype,"chartMenuService",2),qe([r.o7C],Kt.prototype,"init",1);var $t=Kt,qt=class e extends r.uAl{constructor(t,i,r){super(e.TEMPLATE),this.chartController=t,this.columns=i,this.isOpen=r,this.selectedColIds=[],this.chartTypeComps=new Map,this.secondaryAxisComps=new Map}init(){this.createSeriesChartTypeGroup(this.columns)}refresh(e){r._.areEqual(this.getValidColIds(e),this.selectedColIds)?this.refreshComps():this.recreate(e)}recreate(e){this.isOpen=this.seriesChartTypeGroupComp.isExpanded(),r._.clearElement(this.getGui()),this.destroyBean(this.seriesChartTypeGroupComp),this.columns=e,this.selectedColIds=[],this.clearComps(),this.init()}getValidColIds(e){const t=this.chartController.getSeriesChartTypes();return e.filter(e=>e.selected&&!!t.filter(t=>t.colId===e.colId)[0]).map(({colId:e})=>e)}createSeriesChartTypeGroup(e){this.seriesChartTypeGroupComp=this.createBean(new r.Pk_({title:this.chartTranslationService.translate("seriesChartType"),enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!1,cssIdentifier:"charts-data",expanded:this.isOpen}));const t=this.chartController.getSeriesChartTypes();e.forEach(e=>{if(!e.selected)return;const i=t.filter(t=>t.colId===e.colId)[0];if(!i)return;this.selectedColIds.push(e.colId);const n=this.seriesChartTypeGroupComp.createManagedBean(new r.Pk_({title:e.displayName,enabled:!0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-format-sub-level"})),s=this.seriesChartTypeGroupComp.createManagedBean(new r.Unm({label:this.chartTranslationService.translate("secondaryAxis"),labelWidth:"flex",disabled:(o=i.chartType,["groupedColumn","stackedColumn","stackedArea"].includes(o)),value:!!i.secondaryAxis,onValueChange:t=>this.chartController.updateSeriesChartType(e.colId,void 0,t)}));var o;n.addItem(s);const a=e=>this.chartTranslationService.translate(e),l=[{value:"line",text:a("line")},{value:"area",text:a("area")},{value:"stackedArea",text:a("stackedArea")},{value:"groupedColumn",text:a("groupedColumn")},{value:"stackedColumn",text:a("stackedColumn")}],c=n.createManagedBean(new r.Ju4({labelAlignment:"left",labelWidth:"flex",options:l,value:i.chartType,onValueChange:t=>this.chartController.updateSeriesChartType(e.colId,t)}));n.addItem(c),this.seriesChartTypeGroupComp.addItem(n),this.chartTypeComps.set(e.colId,c),this.secondaryAxisComps.set(e.colId,s)}),this.getGui().appendChild(this.seriesChartTypeGroupComp.getGui())}refreshComps(){const e=this.chartController.getSeriesChartTypes();this.selectedColIds.forEach(t=>{const i=e.find(e=>e.colId===t);if(!i)return;const r=this.chartTypeComps.get(t),n=this.secondaryAxisComps.get(t);null==r||r.setValue(i.chartType),null==n||n.setValue(!!i.secondaryAxis),null==n||n.setDisabled(this.isSecondaryAxisDisabled(i.chartType))})}clearComps(){this.chartTypeComps.clear(),this.secondaryAxisComps.clear()}isSecondaryAxisDisabled(e){return["groupedColumn","stackedColumn","stackedArea"].includes(e)}destroy(){this.clearComps(),this.seriesChartTypeGroupComp=this.destroyBean(this.seriesChartTypeGroupComp),super.destroy()}};qt.TEMPLATE='<div id="seriesChartTypeGroup"></div>',qe([(0,r.dsm)("chartTranslationService")],qt.prototype,"chartTranslationService",2),qe([r.o7C],qt.prototype,"init",1);var Yt=qt,Qt=class e extends r.uAl{constructor(e,t){super(),this.getValue=e,this.setValue=t}init(){this.switchCategorySeriesToggleButton=this.createManagedBean(new r.bLJ({label:this.chartTranslationService.translate("switchCategorySeries"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",value:this.getValue(),onValueChange:e=>{this.setValue(e)}}));const t={title:void 0,suppressEnabledCheckbox:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-data",expanded:!0,items:[this.switchCategorySeriesToggleButton]};this.setTemplate(e.TEMPLATE,{switchCategorySeriesGroup:t})}refresh(){var e;null==(e=this.switchCategorySeriesToggleButton)||e.setValue(this.getValue(),!0)}};Qt.TEMPLATE='<div>\n        <ag-group-component ref="switchCategorySeriesGroup"></ag-group-component>\n    </div>',qe([(0,r.dsm)("chartTranslationService")],Qt.prototype,"chartTranslationService",2),qe([r.o7C],Qt.prototype,"init",1);var Xt=Qt,Zt={groups:[{type:"categories",isOpen:!0},{type:"series",isOpen:!0},{type:"seriesChartType",isOpen:!0}]},Jt=class e extends r.uAl{constructor(t,i){super(e.TEMPLATE),this.chartController=t,this.chartOptionsService=i,this.isSwitchCategorySeriesToggled=!1}init(){this.switchCategorySeriesPanel=this.addComponent(this.createManagedBean(new Xt(()=>this.chartController.isCategorySeriesSwitched(),e=>this.chartController.switchCategorySeries(e)))),this.isSwitchCategorySeriesToggled=this.chartController.isCategorySeriesSwitched(),this.createAutoScrollService(),this.updatePanels(),this.addManagedListener(this.chartController,Gt.EVENT_CHART_MODEL_UPDATE,this.updatePanels.bind(this)),this.addManagedListener(this.chartController,Gt.EVENT_CHART_API_UPDATE,this.updatePanels.bind(this))}destroy(){this.clearPanelComponents(),super.destroy()}updatePanels(){var e,t,i,r,n;const s=this.chartType,o=this.isSwitchCategorySeriesToggled,{dimensionCols:a,valueCols:l}=this.chartController.getColStateForMenu();this.chartType=this.chartController.getChartType(),this.isSwitchCategorySeriesToggled=this.chartController.isCategorySeriesSwitched();const c=this.isSwitchCategorySeriesToggled!==o;this.canRefresh(s,this.chartType)&&!c?(null==(e=this.categoriesDataPanel)||e.refresh(a),null==(t=this.seriesDataPanel)||t.refresh(l),null==(i=this.seriesChartTypePanel)||i.refresh(l)):this.recreatePanels(a,l),null==(r=this.switchCategorySeriesPanel)||r.setDisplayed(pt(this.chartType)&&!this.chartMenuService.isLegacyFormat()&&!this.chartController.isGrouping()),c&&(null==(n=this.switchCategorySeriesPanel)||n.refresh())}canRefresh(e,t){if(void 0===e)return!1;if(e===t)return!0;const i=e=>["columnLineCombo","areaColumnCombo","customCombo"].includes(e);return!(!i(e)||!i(t))}recreatePanels(e,t){var i;this.clearPanelComponents();const{chartType:n}=this;if(!n)return;const s=this.chartController.isCategorySeriesSwitched(),o=null==(i=this.getDataPanelDef().groups)?void 0:i.map(({type:i,isOpen:o})=>i===(s?"series":"categories")?this.categoriesDataPanel=this.createBean(new jt(this.chartController,this.autoScrollService,this.getCategoryGroupTitle(s),this.getCategoryGroupMultipleSelect(n,s),e,o)):i===(s?"categories":"series")?this.seriesDataPanel=this.createBean(new $t(this.chartController,this.autoScrollService,this.chartOptionsService,this.getSeriesGroupTitle(s),this.getSeriesGroupMultipleSelect(n,s),this.getSeriesGroupMaxSelection(n,s),t,o)):"seriesChartType"===i?this.chartController.isComboChart()?this.seriesChartTypePanel=this.createBean(new Yt(this.chartController,t,o)):null:(r._.warnOnce(`Invalid charts data panel group name supplied: '${i}'`),null)).filter(e=>null!=e);o&&this.addPanelComponents(o)}addPanelComponents(e){var t;const i=document.createDocumentFragment();for(const t of e)this.registerComponent(t),i.appendChild(t.getGui());const r=null==(t=this.switchCategorySeriesPanel)?void 0:t.getGui();return this.getGui().insertBefore(i,null!=r?r:null),e}clearPanelComponents(){const e=this.getGui();this.categoriesDataPanel&&e.removeChild(this.categoriesDataPanel.getGui()),this.seriesDataPanel&&e.removeChild(this.seriesDataPanel.getGui()),this.seriesChartTypePanel&&e.removeChild(this.seriesChartTypePanel.getGui()),this.categoriesDataPanel=this.destroyBean(this.categoriesDataPanel),this.seriesDataPanel=this.destroyBean(this.seriesDataPanel),this.seriesChartTypePanel=this.destroyBean(this.seriesChartTypePanel)}createAutoScrollService(){const e=this.getGui();this.autoScrollService=new r.MSA({scrollContainer:e,scrollAxis:"y",getVerticalPosition:()=>e.scrollTop,setVerticalPosition:t=>e.scrollTop=t})}addComponent(e){return this.registerComponent(e),this.getGui().appendChild(e.getGui()),e}registerComponent(e){e.addCssClass("ag-chart-data-section")}getDataPanelDef(){var e,t;return null!=(t=null==(e=this.gos.get("chartToolPanelsDef"))?void 0:e.dataPanel)?t:Zt}getCategoryGroupTitle(e){return e?this.chartTranslationService.translate("seriesLabels"):this.chartTranslationService.translate(this.chartController.isActiveXYChart()?"labels":"categories")}getCategoryGroupMultipleSelect(e,t){return!t&&1!==ht(e)}getSeriesGroupTitle(e){return e?this.chartTranslationService.translate("categoryValues"):this.chartTranslationService.translate(this.chartController.isActiveXYChart()?"xyValues":"series")}getSeriesGroupMultipleSelect(e,t){return 1!==this.getSeriesGroupMaxSelection(e,t)}getSeriesGroupMaxSelection(e,t){if(!t)return dt(e)}};Jt.TEMPLATE='<div class="ag-chart-data-wrapper ag-scrollable-container"></div>',qe([(0,r.dsm)("chartTranslationService")],Jt.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],Jt.prototype,"chartMenuService",2),qe([r.o7C],Jt.prototype,"init",1);var ei=Jt,ti=class e extends r.uAl{constructor(e){super(),this.activeComps=[],this.params=e,this.chartOptions=e.chartMenuUtils.getChartOptions()}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.params.name||this.chartTranslationService.translate("font"),enabled:this.params.enabled,suppressEnabledCheckbox:!!this.params.suppressEnabledCheckbox,onEnableChange:e=>{this.params.onEnableChange&&this.params.onEnableChange(e)}};this.setTemplate(e.TEMPLATE,{fontGroup:t,familySelect:this.getFamilySelectParams(),weightStyleSelect:this.getWeightStyleSelectParams(),sizeSelect:this.getSizeSelectParams(),colorPicker:this.params.chartMenuUtils.getDefaultColorPickerParams(this.params.keyMapper("color"))})}addCompToPanel(e){this.fontGroup.addItem(e),this.activeComps.push(e)}setEnabled(e){this.fontGroup.setEnabled(e)}getFamilySelectParams(){const e=["Arial, sans-serif","Aria Black, sans-serif","Book Antiqua,  serif","Charcoal, sans-serif","Comic Sans MS, cursive","Courier, monospace","Courier New, monospace","Gadget, sans-serif","Geneva, sans-serif","Helvetica, sans-serif","Impact, sans-serif","Lucida Console, monospace","Lucida Grande, sans-serif","Lucida Sans Unicode,  sans-serif","Monaco, monospace","Palatino Linotype, serif","Palatino, serif","Times New Roman, serif","Times, serif","Verdana, sans-serif"],t=this.getInitialFontValue("fontFamily");let i=e[0];if(t){const n=e.map(e=>e.toLowerCase()).indexOf(t.toLowerCase());if(n>=0)i=e[n];else{const n=r._.capitalise(t);e.push(n),i=n}}return{options:e.sort().map(e=>({value:e,text:e})),inputWidth:"flex",value:`${i}`,onValueChange:e=>this.setFont({fontFamily:e})}}getSizeSelectParams(){const e=[8,10,12,14,16,18,20,22,24,26,28,30,32,34,36],t=this.getInitialFontValue("fontSize");return r._.includes(e,t)||e.push(t),{options:e.sort((e,t)=>e-t).map(e=>({value:`${e}`,text:`${e}`})),inputWidth:"flex",value:`${t}`,onValueChange:e=>this.setFont({fontSize:parseInt(e,10)}),label:this.chartTranslationService.translate("size")}}getWeightStyleSelectParams(){var e,t;const i=null!=(e=this.getInitialFontValue("fontWeight"))?e:"normal",r=null!=(t=this.getInitialFontValue("fontStyle"))?t:"normal",n=[{name:"normal",weight:"normal",style:"normal"},{name:"bold",weight:"bold",style:"normal"},{name:"italic",weight:"normal",style:"italic"},{name:"boldItalic",weight:"bold",style:"italic"}];let s=n.find(e=>e.weight===i&&e.style===r);return s||(s={name:"predefined",weight:i,style:r},n.unshift(s)),{options:n.map(e=>({value:e.name,text:this.chartTranslationService.translate(e.name)})),inputWidth:"flex",value:s.name,onValueChange:e=>{const t=n.find(t=>t.name===e);this.setFont({fontWeight:t.weight,fontStyle:t.style})}}}addItemToPanel(e){this.fontGroup.addItem(e),this.activeComps.push(e)}destroyActiveComps(){this.activeComps.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActiveComps(),super.destroy()}setFont(e){const{keyMapper:t}=this.params;Object.entries(e).forEach(([e,i])=>{i&&this.chartOptions.setValue(t(e),i)})}getInitialFontValue(e){const{keyMapper:t}=this.params;return this.chartOptions.getValue(t(e))}};ti.TEMPLATE='<div class="ag-font-panel">\n            <ag-group-component ref="fontGroup">\n                <ag-select ref="familySelect"></ag-select>\n                <ag-select ref="weightStyleSelect"></ag-select>\n                <div class="ag-charts-font-size-color">\n                    <ag-select ref="sizeSelect"></ag-select>\n                    <ag-color-picker ref="colorPicker"></ag-color-picker>\n                </div>\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("fontGroup")],ti.prototype,"fontGroup",2),qe([(0,r.dsm)("chartTranslationService")],ti.prototype,"chartTranslationService",2),qe([r.o7C],ti.prototype,"init",1);var ii=ti,ri=class e extends r.uAl{constructor({chartMenuParamsFactory:e,isExpandedOnInit:t=!1}){super(),this.chartMenuUtils=e,this.isExpandedOnInit=t}init(){const t=this.chartMenuUtils.addEnableParams("legend.enabled",{cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("legend"),suppressEnabledCheckbox:!1,suppressToggleExpandOnEnableChange:!0,expanded:this.isExpandedOnInit,items:[this.createLabelPanel()]});this.setTemplate(e.TEMPLATE,{legendGroup:t,legendPositionSelect:this.chartMenuUtils.getDefaultLegendParams("legend.position"),legendPaddingSlider:this.getSliderParams("spacing","spacing",200),markerSizeSlider:this.getSliderParams("item.marker.size","markerSize",40),markerStrokeSlider:this.getSliderParams("item.marker.strokeWidth","markerStroke",10),markerPaddingSlider:this.getSliderParams("item.marker.padding","itemSpacing",20),itemPaddingXSlider:this.getSliderParams("item.paddingX","layoutHorizontalSpacing",50),itemPaddingYSlider:this.getSliderParams("item.paddingY","layoutVerticalSpacing",50)})}getSliderParams(e,t,i){return this.chartMenuUtils.getDefaultSliderParams(`legend.${e}`,t,i)}createLabelPanel(){const e={enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`legend.item.label.${e}`};return this.createManagedBean(new ii(e))}};ri.TEMPLATE='<div>\n            <ag-group-component ref="legendGroup">\n                <ag-select ref="legendPositionSelect"></ag-select>\n                <ag-slider ref="legendPaddingSlider"></ag-slider>\n                <ag-slider ref="markerSizeSlider"></ag-slider>\n                <ag-slider ref="markerStrokeSlider"></ag-slider>\n                <ag-slider ref="markerPaddingSlider"></ag-slider>\n                <ag-slider ref="itemPaddingXSlider"></ag-slider>\n                <ag-slider ref="itemPaddingYSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],ri.prototype,"chartTranslationService",2),qe([r.o7C],ri.prototype,"init",1);var ni=ri,si=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t=this.chartMenuUtils.addEnableParams("tick.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("ticks"),suppressEnabledCheckbox:!1}),i=this.chartMenuUtils.getDefaultColorPickerParams("tick.color"),r=this.chartMenuUtils.getDefaultSliderParams("tick.width","width",10),n=this.chartMenuUtils.getDefaultSliderParams("tick.size","length",30);this.setTemplate(e.TEMPLATE,{axisTicksGroup:t,axisTicksColorPicker:i,axisTicksWidthSlider:r,axisTicksSizeSlider:n})}};si.TEMPLATE='<div>\n            <ag-group-component ref="axisTicksGroup">\n                <ag-color-picker ref="axisTicksColorPicker"></ag-color-picker>\n                <ag-slider ref="axisTicksWidthSlider"></ag-slider>\n                <ag-slider ref="axisTicksSizeSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],si.prototype,"chartTranslationService",2),qe([r.o7C],si.prototype,"init",1);var oi=si,ai=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e,this.chartOptions=e.getChartOptions()}init(){const t=this.chartMenuUtils.addEnableParams("gridLine.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("gridLines"),suppressEnabledCheckbox:!1}),i=this.getGridLineColorPickerParams("color"),r=this.getGridLineWidthSliderParams("thickness"),n=this.getGridLineDashSliderParams("lineDash");this.setTemplate(e.TEMPLATE,{gridLineGroup:t,gridLineColorPicker:i,gridLineWidthSlider:r,gridLineLineDashSlider:n})}getGridLineColorPickerParams(e){return this.chartMenuUtils.getDefaultColorPickerParams("gridLine.style",e,{formatInputValue:e=>{var t;return null==(t=null==e?void 0:e[0])?void 0:t.stroke},parseInputValue:e=>{var t;const i=null!=(t=this.chartOptions.getValue("gridLine.style"))?t:[];return 0===i.length?[{stroke:e,lineDash:[]}]:[Ke(je({},i[0]),{stroke:e})]}})}getGridLineWidthSliderParams(e){return this.chartMenuUtils.getDefaultSliderParams("gridLine.width",e,10)}getGridLineDashSliderParams(e){var t,i;const r=this.chartOptions.getValue("gridLine.style"),n=null==(i=null==(t=null==r?void 0:r[0])?void 0:t.lineDash)?void 0:i[0],s=this.chartMenuUtils.getDefaultSliderParamsWithoutValueParams(null!=n?n:0,e,30);return s.onValueChange=e=>{const t=this.chartOptions.getValue("gridLine.style.0.stroke");this.chartOptions.setValue("gridLine.style",[{lineDash:[e],stroke:t}])},s}};ai.TEMPLATE='<div>\n            <ag-group-component ref="gridLineGroup">\n                <ag-color-picker ref="gridLineColorPicker"></ag-color-picker>\n                <ag-slider ref="gridLineWidthSlider"></ag-slider>\n                <ag-slider ref="gridLineLineDashSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],ai.prototype,"chartTranslationService",2),qe([r.o7C],ai.prototype,"init",1);var li=ai,ci=class e extends r.DKR{constructor(t){super(t,e.TEMPLATE),this.radius=0,this.offsetX=0,this.offsetY=0}postConstruct(){super.postConstruct();const{value:e,onValueChange:t}=this.config;null!=e&&this.setValue(e,void 0,!0),null!=t&&this.onValueChange(t),this.dragListener={eElement:this.eParentCircle,dragStartPixels:0,onDragStart:e=>{this.parentCircleRect=this.eParentCircle.getBoundingClientRect()},onDragging:e=>this.calculateAngleDrag(e),onDragStop:()=>{}},this.dragService.addDragSource(this.dragListener),this.eAngleValue.setLabel("").setLabelWidth(5).setInputWidth(45).setMin(0).setMax(360).setValue(`${this.degrees}`).onValueChange(e=>{null!=e&&""!==e||(e="0"),e=this.eAngleValue.normalizeValue(e);let t=parseFloat(e);t>180&&(t-=360),this.setValue(t)}),this.updateNumberInput(),r._.exists(this.getValue())&&this.eAngleValue.setValue(this.normalizeNegativeValue(this.getValue()).toString()),this.addManagedListener(this,r.sVA.EVENT_FIELD_VALUE_CHANGED,()=>{this.eAngleValue.getInputElement().contains(this.gos.getActiveDomElement())||this.updateNumberInput()})}updateNumberInput(){const e=this.normalizeNegativeValue(this.getValue());this.eAngleValue.setValue(e.toString())}positionChildCircle(e){const t=this.parentCircleRect||{width:24,height:24},i=this.eChildCircle,r=t.width/2,n=t.height/2;i.style.left=`${r+8*Math.cos(e)}px`,i.style.top=`${n+8*Math.sin(e)}px`}calculatePolar(){const e=this.offsetX,t=this.offsetY,i=Math.atan2(t,e);this.degrees=this.toDegrees(i),this.radius=Math.sqrt(e*e+t*t),this.positionChildCircle(i)}calculateCartesian(){const e=this.toRadians(this.getValue()),t=this.getRadius();this.setOffsetX(Math.cos(e)*t).setOffsetY(Math.sin(e)*t)}setOffsetX(e){return this.offsetX!==e&&(this.offsetX=e,this.calculatePolar()),this}setOffsetY(e){return this.offsetY!==e&&(this.offsetY=e,this.calculatePolar()),this}calculateAngleDrag(e){const t=this.parentCircleRect,i=t.width/2,r=t.height/2,n=e.clientX-t.left-i,s=e.clientY-t.top-r,o=Math.atan2(s,n);this.setValue(o,!0)}toDegrees(e){return e/Math.PI*180}toRadians(e){return e/180*Math.PI}normalizeNegativeValue(e){return e<0?360+e:e}normalizeAngle180(e){return(e%=2*Math.PI)<-Math.PI?e+=2*Math.PI:e>=Math.PI&&(e-=2*Math.PI),e}getRadius(){return this.radius}setRadius(e){return this.radius===e||(this.radius=e,this.calculateCartesian()),this}onValueChange(e){return this.addManagedListener(this,r.sVA.EVENT_FIELD_VALUE_CHANGED,()=>{e(this.degrees)}),this}getValue(e){return e?this.toRadians(this.degrees):this.degrees}setValue(e,t,i){let n;return n=t?e:this.normalizeAngle180(this.toRadians(e)),e=this.toDegrees(n),this.degrees!==e&&(this.degrees=Math.floor(e),this.calculateCartesian(),this.positionChildCircle(n),i||this.dispatchEvent({type:r.sVA.EVENT_FIELD_VALUE_CHANGED})),this}setWidth(e){return r._.setFixedWidth(this.getGui(),e),this}setDisabled(e){return super.setDisabled(e),this.eAngleValue.setDisabled(e),this}destroy(){this.dragService.removeDragSource(this.dragListener),super.destroy()}};ci.TEMPLATE='<div class="ag-angle-select">\n            <div ref="eLabel"></div>\n            <div class="ag-wrapper ag-angle-select-wrapper">\n                <div ref="eAngleSelectField" class="ag-angle-select-field">\n                    <div ref="eParentCircle" class="ag-angle-select-parent-circle">\n                        <div ref="eChildCircle" class="ag-angle-select-child-circle"></div>\n                    </div>\n                </div>\n                <ag-input-number-field ref="eAngleValue"></ag-input-number-field>\n            </div>\n        </div>',qe([(0,r.PIB)("eLabel")],ci.prototype,"eLabel",2),qe([(0,r.PIB)("eParentCircle")],ci.prototype,"eParentCircle",2),qe([(0,r.PIB)("eChildCircle")],ci.prototype,"eChildCircle",2),qe([(0,r.PIB)("eAngleValue")],ci.prototype,"eAngleValue",2),qe([(0,r.dsm)("dragService")],ci.prototype,"dragService",2);var ui=ci,hi=class extends r.XQb{constructor(e){super(),this.chartOptionsProxy=e}getDefaultColorPickerParams(e,t,i){return this.addValueParams(e,{label:this.chartTranslationService.translate(null!=t?t:"color"),labelWidth:"flex",inputWidth:"flex"},i)}getDefaultNumberInputParams(e,t,i){return this.addValueParams(e,{label:this.chartTranslationService.translate(t),labelWidth:"flex",inputWidth:"flex",precision:null==i?void 0:i.precision,step:null==i?void 0:i.step,min:null==i?void 0:i.min,max:null==i?void 0:i.max},{parseInputValue:e=>{const t=Number(e);return isNaN(t)?void 0:t},formatInputValue:e=>null==e?"":`${e}`})}getDefaultSliderParams(e,t,i,r){var n;let s=null!=(n=this.chartOptionsProxy.getValue(e))?n:0;r&&Array.isArray(s)&&(s=s[0]);const o=this.getDefaultSliderParamsWithoutValueParams(s,t,i);return o.onValueChange=t=>this.chartOptionsProxy.setValue(e,r?[t]:t),o}getDefaultSliderParamsWithoutValueParams(e,t,i){return{label:this.chartTranslationService.translate(t),minValue:0,maxValue:Math.max(e,i),textFieldWidth:45,value:`${e}`}}getDefaultCheckboxParams(e,t,i){const r=this.chartOptionsProxy.getValue(e),n={label:this.chartTranslationService.translate(t),value:r,readOnly:null==i?void 0:i.readOnly,passive:null==i?void 0:i.passive};return n.onValueChange=t=>{this.chartOptionsProxy.setValue(e,"boolean"==typeof t?t:void 0)},n}getDefaultSelectParams(e,t,i,r){const n=this.chartOptionsProxy.getValue(e),s={label:this.chartTranslationService.translate(t),value:n,options:i,pickerType:null==r?void 0:r.pickerType,pickerAriaLabelKey:null==r?void 0:r.pickerAriaLabelKey,pickerAriaLabelValue:null==r?void 0:r.pickerAriaLabelValue};return s.onValueChange=t=>{this.chartOptionsProxy.setValue(e,t)},s}getDefaultLegendParams(e){return this.addValueParams(e,{label:this.chartTranslationService.translate("position"),labelWidth:"flex",inputWidth:"flex",options:["top","right","bottom","left"].map(e=>({value:e,text:this.chartTranslationService.translate(e)}))})}getDefaultFontPanelParams(e,t){const i=t=>`${e}.${t}`;return this.addEnableParams(i("enabled"),{name:this.chartTranslationService.translate(t),suppressEnabledCheckbox:!1,chartMenuUtils:this,keyMapper:i})}addValueParams(e,t,i){const r=this.chartOptionsProxy.getValue(e);return t.value=(null==i?void 0:i.formatInputValue)?i.formatInputValue(r):r,t.onValueChange=t=>{const r=(null==i?void 0:i.parseInputValue)?i.parseInputValue(t):t;this.chartOptionsProxy.setValue(e,r)},t}addEnableParams(e,t){var i;return t.enabled=null!=(i=this.chartOptionsProxy.getValue(e))&&i,t.onEnableChange=t=>this.chartOptionsProxy.setValue(e,t),t}getChartOptions(){return this.chartOptionsProxy}};qe([(0,r.dsm)("chartTranslationService")],hi.prototype,"chartTranslationService",2);var di=class e extends r.uAl{constructor(e,{chartController:t,chartOptionsService:i,isExpandedOnInit:r=!1,seriesType:n}){super(),this.activePanels=[],this.axisLabelUpdateFuncs=[],this.axisType=e,this.chartController=t,this.chartAxisOptionsProxy=i.getCartesianAxisOptionsProxy(e),this.chartAxisThemeOverridesProxy=i.getCartesianAxisThemeOverridesProxy(e),this.chartAxisAppliedThemeOverridesProxy=i.getCartesianAxisAppliedThemeOverridesProxy(e),this.chartOptionsSeriesProxy=i.getSeriesOptionsProxy(()=>null!=n?n:this.chartController.getChartSeriesType()),this.chartOptionsService=i,this.isExpandedOnInit=r}init(){var t;const i=this.axisType,n={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate(i),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0},s=this.createManagedBean(new hi(this.chartAxisOptionsProxy)),o=this.createManagedBean(new hi(this.chartAxisThemeOverridesProxy)),a=this.getAxisTypeSelectParams(s,this.chartAxisAppliedThemeOverridesProxy),l=this.getAxisPositionSelectParams(s),c=this.getAxisTimeFormatSelectParams(s),u=this.getAxisColorInputParams(o),h=this.getAxisLineWidthSliderParams(o);this.setTemplate(e.TEMPLATE,{axisGroup:n,axisTypeSelect:null!=a?a:void 0,axisPositionSelect:null!=l?l:void 0,axisTimeFormatSelect:null!=c?c:void 0,axisColorInput:u,axisLineWidthSlider:h}),this.axisTypeSelect.setDisplayed(!!(null==(t=a.options)?void 0:t.length)),l||this.removeTemplateComponent(this.axisPositionSelect);const d=()=>{const e="time"===this.chartAxisOptionsProxy.getValue("type");r._.setDisplayed(this.axisTimeFormatSelect.getGui(),e)};c?(d(),this.addManagedListener(this.eventService,r.sVA.EVENT_CHART_OPTIONS_CHANGED,e=>{d()})):this.removeTemplateComponent(this.axisTimeFormatSelect),this.initGridLines(o),this.initAxisTicks(o),this.initAxisLabels(o),this.addManagedListener(this.chartController,Gt.EVENT_CHART_UPDATED,()=>this.axisLabelUpdateFuncs.forEach(e=>e())),this.addManagedListener(this.chartController,Gt.EVENT_CHART_MODEL_UPDATE,()=>setTimeout(()=>{this.refreshAxisTypeSelect(s),d()}))}getAxisTypeSelectParams(e,t){const i=e.getChartOptions(),r=this.getAxisTypeSelectOptions(),n=e.getDefaultSelectParams("type","axisType",r);return n.onValueChange=e=>{var r;const n=i.getValue("type");if(e===n)return;const s=t.getValue("*"),o="time"===e,a="time"===n!==o?o?"%d %B %Y":void 0:null;if(this.chartOptionsService.setCartesianCategoryAxisType(this.axisType,e),null!==a){const e=null!=(r=i.getValue("label"))?r:{};i.setValue("label",Ke(je({},e),{format:a}))}t.setValue("*",s)},n}refreshAxisTypeSelect(e){const t=this.getAxisTypeSelectOptions(),i=!!t.length;this.axisTypeSelect.setDisplayed(i),i&&this.axisTypeSelect.clearOptions().addOptions(t).setValue(e.getChartOptions().getValue("type"))}getAxisTypeSelectOptions(){const e=this.chartController.getChartType();return["heatmap","histogram","boxPlot","rangeBar","scatter","bubble"].includes(e)||this.chartController.isGrouping()||!this.isCategoryAxis()||this.chartController.isCategorySeriesSwitched()||!(()=>{const e=this.chartController.getChartData()[0];return!!e&&this.chartController.getSelectedDimensions().every(t=>!isNaN(parseFloat(e[t.colId])))})()?[]:["category","number","time"].map(e=>({value:e,text:this.translate(e)}))}isCategoryAxis(){const e="horizontal"===this.chartOptionsSeriesProxy.getValue("direction");return e&&"yAxis"===this.axisType||!e&&"xAxis"===this.axisType}getAxisPositionSelectParams(e){const t=((e,t)=>{if("heatmap"===e)return null;switch(t){case"xAxis":return[{value:"top",text:this.translate("top")},{value:"bottom",text:this.translate("bottom")}];case"yAxis":return[{value:"left",text:this.translate("left")},{value:"right",text:this.translate("right")}]}})(this.chartController.getChartType(),this.axisType);return t?e.getDefaultSelectParams("position","position",t):null}getAxisTimeFormatSelectParams(e){if(!this.isCategoryAxis())return null;const t=[{value:"%d/%m/%Y",text:this.translate("timeFormatSlashesDDMMYYYY")},{value:"%m/%d/%Y",text:this.translate("timeFormatSlashesMMDDYYYY")},{value:"%d/%m/%y",text:this.translate("timeFormatSlashesDDMMYY")},{value:"%m/%d/%y",text:this.translate("timeFormatSlashesMMDDYY")},{value:"%d.%e.%y",text:this.translate("timeFormatDotsDDMYY")},{value:"%e.%d.%y",text:this.translate("timeFormatDotsMDDYY")},{value:"%Y-%m-%d",text:this.translate("timeFormatDashesYYYYMMDD")},{value:"%d %B %Y",text:this.translate("timeFormatSpacesDDMMMMYYYY")},{value:"%H:%M:%S",text:this.translate("timeFormatHHMMSS")},{value:"%I:%M:%S %p",text:this.translate("timeFormatHHMMSSAmPm")}];return e.getDefaultSelectParams("label.format","timeFormat",t)}getAxisColorInputParams(e){return e.getDefaultColorPickerParams("line.color")}getAxisLineWidthSliderParams(e){var t;const i=e.getChartOptions(),r=e.getDefaultSliderParamsWithoutValueParams(null!=(t=i.getValue("line.enabled")?i.getValue("line.width"):null)?t:0,"thickness",10);return r.onValueChange=e=>{var t;t=0===e?null:e,i.setValues([{expression:"line.enabled",value:null!=t},{expression:"line.width",value:null!=t?t:0}])},r}initGridLines(e){if("heatmap"!==this.chartController.getChartType()){const t=this.createBean(new li(e));this.axisGroup.addItem(t),this.activePanels.push(t)}}initAxisTicks(e){if(!this.hasConfigurableAxisTicks())return;const t=this.createBean(new oi(e));this.axisGroup.addItem(t),this.activePanels.push(t)}hasConfigurableAxisTicks(){switch(this.chartController.getChartType()){case"radarLine":case"radarArea":case"rangeBar":case"boxPlot":case"waterfall":return!1;default:return!0}}initAxisLabels(e){const t={name:this.translate("labels"),enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:e,keyMapper:e=>`label.${e}`},i=this.createBean(new ii(t));this.axisGroup.addItem(i),this.activePanels.push(i),this.addAdditionalLabelComps(i,e)}addAdditionalLabelComps(e,t){this.addLabelPadding(e,t);const i=this.createRotationWidget("labelRotation",t),r=this.initLabelRotation(i,t);e.addCompToPanel(r),e.addCompToPanel(i)}initLabelRotation(e,t){const i=t.getChartOptions(),n=()=>i.getValue("label.rotation"),s="number"!=typeof n()&&i.getValue("label.autoRotate"),o=this.createBean(new r.Unm({label:this.translate("autoRotate"),value:s,onValueChange:t=>{t&&(this.prevRotation=n()),i.setValues([{expression:"label.autoRotate",value:t},{expression:"label.rotation",value:t?void 0:this.prevRotation}]),e.setDisabled(t)}}));return e.setDisabled(s),o}createRotationWidget(e,t){var i;const r=t.getChartOptions(),n=()=>r.getValue("label.rotation"),s=String.fromCharCode(176),o=`${this.chartTranslationService.translate(e)} ${s}`,a=new ui({label:o,labelWidth:"flex",value:null!=(i=n())?i:0,onValueChange:e=>r.setValue("label.rotation",e)});return this.axisLabelUpdateFuncs.push(()=>{var e;a.setValue(null!=(e=n())?e:0)}),this.createBean(a)}addLabelPadding(e,t){const i=this.createBean(new r.YD7(t.getDefaultSliderParams("label.padding","padding",30)));e.addCompToPanel(i)}translate(e){return this.chartTranslationService.translate(e)}removeTemplateComponent(e){r._.removeFromParent(e.getGui()),this.destroyBean(e)}destroyActivePanels(){this.activePanels.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};di.TEMPLATE='<div>\n            <ag-group-component ref="axisGroup">\n                <ag-select ref="axisTypeSelect"></ag-select>\n                <ag-select ref="axisTimeFormatSelect"></ag-select>\n                <ag-select ref="axisPositionSelect"></ag-select>\n                <ag-color-picker ref="axisColorInput"></ag-color-picker>\n                <ag-slider ref="axisLineWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("axisGroup")],di.prototype,"axisGroup",2),qe([(0,r.PIB)("axisTypeSelect")],di.prototype,"axisTypeSelect",2),qe([(0,r.PIB)("axisPositionSelect")],di.prototype,"axisPositionSelect",2),qe([(0,r.PIB)("axisTimeFormatSelect")],di.prototype,"axisTimeFormatSelect",2),qe([(0,r.dsm)("chartTranslationService")],di.prototype,"chartTranslationService",2),qe([r.o7C],di.prototype,"init",1);var pi=di,gi=class e extends r.uAl{constructor({chartController:e,chartAxisMenuParamsFactory:t,isExpandedOnInit:i=!1}){super(),this.chartController=e,this.chartMenuUtils=t,this.isExpandedOnInit=i}init(){const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate("polarAxis"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0},i=this.chartMenuUtils.getDefaultColorPickerParams("line.color"),r=this.chartMenuUtils.getDefaultSliderParams("line.width","thickness",10);this.setTemplate(e.TEMPLATE,{axisGroup:t,axisColorInput:i,axisLineWidthSlider:r}),this.initAxis(),this.initAxisLabels(),this.initRadiusAxis()}initAxis(){const e=this.chartController.getChartType();if(["radarLine","radarArea"].includes(e)){const e=[{value:"circle",text:this.translate("circle")},{value:"polygon",text:this.translate("polygon")}];this.axisGroup.addItem(this.createSelect({labelKey:"shape",options:e,property:"shape"}))}"pie"!==e&&this.axisGroup.addItem(this.createSlider({labelKey:"innerRadius",defaultMaxValue:1,property:"innerRadiusRatio"}))}initAxisLabels(){const e={name:this.translate("labels"),enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`label.${e}`},t=this.createManagedBean(new ii(e)),i=this.createOrientationWidget();t.addItemToPanel(i),this.axisGroup.addItem(t)}createOrientationWidget(){const e=[{value:"fixed",text:this.translate("fixed")},{value:"parallel",text:this.translate("parallel")},{value:"perpendicular",text:this.translate("perpendicular")}];return this.createSelect({labelKey:"orientation",options:e,property:"label.orientation"})}initRadiusAxis(){if(!it(ct(this.chartController.getChartType()),"isRadial"))return;const e=[this.createSlider({labelKey:"groupPadding",defaultMaxValue:1,property:"paddingInner"}),this.createSlider({labelKey:"seriesPadding",defaultMaxValue:1,property:"groupPaddingInner"})],t=this.createManagedBean(new r.Pk_({cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,enabled:!0,suppressEnabledCheckbox:!0,title:this.translate("padding"),items:e})).hideEnabledCheckbox(!0).hideOpenCloseIcons(!0);this.axisGroup.addItem(t)}createSlider(e){const{labelKey:t,defaultMaxValue:i,step:n=.05,property:s}=e,o=this.chartMenuUtils.getDefaultSliderParams(s,t,i);return o.step=n,this.createManagedBean(new r.YD7(o))}createSelect(e){const{labelKey:t,options:i,property:n}=e;return this.createManagedBean(new r.Ju4(this.chartMenuUtils.addValueParams(n,{label:this.chartTranslationService.translate(t),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:i})))}translate(e){return this.chartTranslationService.translate(e)}};gi.TEMPLATE='<div>\n            <ag-group-component ref="axisGroup">\n                <ag-color-picker ref="axisColorInput"></ag-color-picker>\n                <ag-slider ref="axisLineWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("axisGroup")],gi.prototype,"axisGroup",2),qe([(0,r.dsm)("chartTranslationService")],gi.prototype,"chartTranslationService",2),qe([r.o7C],gi.prototype,"init",1);var fi=gi,mi=class e extends r.uAl{constructor(e,t){super(),this.chartMenuUtils=e,this.chartController=t}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("padding"),suppressEnabledCheckbox:!0},i=e=>this.chartMenuUtils.getDefaultSliderParams("padding."+e,e,200);this.setTemplate(e.TEMPLATE,{chartPaddingGroup:t,paddingTopSlider:i("top"),paddingRightSlider:i("right"),paddingBottomSlider:i("bottom"),paddingLeftSlider:i("left")}),this.addManagedListener(this.eventService,r.sVA.EVENT_CHART_OPTIONS_CHANGED,e=>{this.updateTopPadding(e.chartOptions)})}updateTopPadding(e){const t=[...this.chartController.getChartSeriesTypes(),"common"].map(t=>{var i,r;return null==(r=null==(i=e[t])?void 0:i.padding)?void 0:r.top}).find(e=>null!=e);null!=t&&this.paddingTopSlider.setValue(`${t}`)}};mi.TEMPLATE='<div>\n            <ag-group-component ref="chartPaddingGroup">\n                <ag-slider ref="paddingTopSlider"></ag-slider>\n                <ag-slider ref="paddingRightSlider"></ag-slider>\n                <ag-slider ref="paddingBottomSlider"></ag-slider>\n                <ag-slider ref="paddingLeftSlider"></ag-slider>\n            </ag-group-component>\n        <div>',qe([(0,r.PIB)("paddingTopSlider")],mi.prototype,"paddingTopSlider",2),qe([(0,r.dsm)("chartTranslationService")],mi.prototype,"chartTranslationService",2),qe([r.o7C],mi.prototype,"init",1);var vi=mi,Ci=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t=this.chartMenuUtils.addEnableParams("background.visible",{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("background"),suppressEnabledCheckbox:!1}),i=this.chartMenuUtils.getDefaultColorPickerParams("background.fill");this.setTemplate(e.TEMPLATE,{chartBackgroundGroup:t,colorPicker:i})}};Ci.TEMPLATE='<div>\n            <ag-group-component ref="chartBackgroundGroup">\n                <ag-color-picker ref="colorPicker"></ag-color-picker>\n            </ag-group-component>\n        <div>',qe([(0,r.dsm)("chartTranslationService")],Ci.prototype,"chartTranslationService",2),qe([r.o7C],Ci.prototype,"init",1);var yi=Ci,wi=class e extends r.uAl{constructor(t,i){super(e.TEMPLATE),this.chartMenuUtils=t,this.chartController=i,this.activePanels=[],this.chartOptions=t.getChartOptions()}init(){this.initFontPanel(),this.titlePlaceholder=this.chartTranslationService.translate("titlePlaceholder")}hasTitle(){const e=this.chartOptions.getValue("title");return e&&e.enabled&&e.text&&e.text.length>0}initFontPanel(){const e=this.hasTitle(),t={name:this.chartTranslationService.translate("title"),enabled:e,suppressEnabledCheckbox:!1,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`title.${e}`,onEnableChange:e=>{if(this.chartMenuService.doesChartToolbarExist(this.chartController)){const t=this.chartOptions.getValue("padding.top");this.chartOptions.setValue("padding.top",e?t-20:t+20)}this.chartOptions.setValue("title.enabled",e);const t=this.chartOptions.getValue("title.text"),i="Title"===t||0===(null==t?void 0:t.trim().length);e&&i&&this.chartOptions.setValue("title.text",this.titlePlaceholder)}},i=this.createBean(new ii(t));i.addItemToPanel(this.createSpacingSlicer()),this.getGui().appendChild(i.getGui()),this.activePanels.push(i),this.addManagedListener(this.eventService,"chartTitleEdit",()=>{i.setEnabled(this.hasTitle())})}createSpacingSlicer(){const e=this.chartMenuUtils.getDefaultSliderParams("title.spacing","spacing",100);return e.value="10",this.createBean(new r.YD7(e))}destroyActivePanels(){this.activePanels.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};wi.TEMPLATE="<div></div>",qe([(0,r.dsm)("chartTranslationService")],wi.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],wi.prototype,"chartMenuService",2),qe([r.o7C],wi.prototype,"init",1);var Si=wi,bi=class e extends r.uAl{constructor({chartController:e,chartMenuParamsFactory:t,isExpandedOnInit:i=!1,chartOptionsService:r,seriesType:n}){super(),this.chartController=e,this.chartMenuParamsFactory=t,this.chartOptionsSeriesProxy=r.getSeriesOptionsProxy(()=>null!=n?n:this.chartController.getChartSeriesType()),this.isExpandedOnInit=i}init(){this.chartSeriesMenuParamsFactory=this.createManagedBean(new hi(this.chartOptionsSeriesProxy));const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("chart"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0,items:[this.createManagedBean(new Si(this.chartMenuParamsFactory,this.chartController)),this.createManagedBean(new vi(this.chartMenuParamsFactory,this.chartController)),this.createManagedBean(new yi(this.chartMenuParamsFactory)),...this.createDirectionSelect()]};this.setTemplate(e.TEMPLATE,{chartGroup:t}),this.addManagedListener(this.eventService,r.sVA.EVENT_CHART_OPTIONS_CHANGED,()=>this.refresh())}refresh(){this.updateDirectionSelect()}createDirectionSelect(){if(this.chartMenuService.isLegacyFormat())return[];const e=["horizontal","vertical"].map(e=>({value:e,text:this.chartTranslationService.translate(e)})),t=this.chartSeriesMenuParamsFactory.getDefaultSelectParams("direction","direction",e);t.labelWidth="flex",t.inputWidth="flex";const i=t.onValueChange;return t.onValueChange=e=>{i(e),this.chartController.raiseChartModelUpdateEvent()},this.directionSelect=this.createManagedBean(new r.Ju4(t)),this.updateDirectionSelect(),[this.directionSelect]}updateDirectionSelect(){var e;null==(e=this.directionSelect)||e.setDisplayed(it(ct(this.chartController.getChartType()),"canSwitchDirection"))}};bi.TEMPLATE='<div>\n            <ag-group-component ref="chartGroup"></ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],bi.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],bi.prototype,"chartMenuService",2),qe([r.o7C],bi.prototype,"init",1);var Ei=bi,Ai=class e extends r.uAl{constructor(e,t="shadow"){super(),this.chartMenuUtils=e,this.propertyKey=t}init(){const t=this.propertyKey,i=this.chartMenuUtils.addEnableParams(`${t}.enabled`,{cssIdentifier:"charts-format-sub-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("shadow"),suppressEnabledCheckbox:!1}),r=this.chartMenuUtils.getDefaultColorPickerParams(`${t}.color`);this.setTemplate(e.TEMPLATE,{shadowGroup:i,shadowColorPicker:r,shadowBlurSlider:this.getSliderParams("blur",0,20),shadowXOffsetSlider:this.getSliderParams("xOffset",-10,10),shadowYOffsetSlider:this.getSliderParams("yOffset",-10,10)})}getSliderParams(e,t,i){const r=`${this.propertyKey}.${e}`,n=this.chartMenuUtils.getDefaultSliderParams(r,e,i);return n.minValue=t,n}};Ai.TEMPLATE='<div>\n            <ag-group-component ref="shadowGroup">\n                <ag-color-picker ref="shadowColorPicker"></ag-color-picker>\n                <ag-slider ref="shadowBlurSlider"></ag-slider>\n                <ag-slider ref="shadowXOffsetSlider"></ag-slider>\n                <ag-slider ref="shadowYOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Ai.prototype,"chartTranslationService",2),qe([r.o7C],Ai.prototype,"init",1);var Ti=Ai,Mi=class e extends r.uAl{constructor(e,t){super(),this.chartOptionsService=e,this.chartMenuUtils=t}init(){const t=this.chartOptionsService.getChartType(),i=r._.includes(["scatter","bubble"],t),n=this.chartMenuUtils.addEnableParams("marker.enabled",{cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("markers"),suppressEnabledCheckbox:i,suppressOpenCloseIcons:!0}),s="bubble"===t;let o,a;s?(o=this.getSliderParams("marker.maxSize","maxSize",60),a=this.getSliderParams("marker.size","minSize",60)):(o={},a=this.getSliderParams("marker.size","size",60)),this.setTemplate(e.TEMPLATE,{seriesMarkersGroup:n,seriesMarkerShapeSelect:this.getMarkerShapeSelectParams(),seriesMarkerMinSizeSlider:o,seriesMarkerSizeSlider:a,seriesMarkerStrokeWidthSlider:this.getSliderParams("marker.strokeWidth","strokeWidth",10)}),s||this.seriesMarkerMinSizeSlider.setDisplayed(!1)}getMarkerShapeSelectParams(){return this.chartMenuUtils.addValueParams("marker.shape",{options:[{value:"square",text:"Square"},{value:"circle",text:"Circle"},{value:"cross",text:"Cross"},{value:"diamond",text:"Diamond"},{value:"plus",text:"Plus"},{value:"triangle",text:"Triangle"},{value:"heart",text:"Heart"}],label:this.chartTranslationService.translate("shape")})}getSliderParams(e,t,i){return this.chartMenuUtils.getDefaultSliderParams(e,t,i)}};Mi.TEMPLATE='<div>\n            <ag-group-component ref="seriesMarkersGroup">\n                <ag-select ref="seriesMarkerShapeSelect"></ag-select>\n                <ag-slider ref="seriesMarkerMinSizeSlider"></ag-slider>\n                <ag-slider ref="seriesMarkerSizeSlider"></ag-slider>\n                <ag-slider ref="seriesMarkerStrokeWidthSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("seriesMarkerMinSizeSlider")],Mi.prototype,"seriesMarkerMinSizeSlider",2),qe([(0,r.dsm)("chartTranslationService")],Mi.prototype,"chartTranslationService",2),qe([r.o7C],Mi.prototype,"init",1);var Ri=Mi,_i=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.H=1,this.S=1,this.B=1,this.A=1,this.isSpectrumDragging=!1,this.isSpectrumHueDragging=!1,this.isSpectrumAlphaDragging=!1,this.colorChanged=!1,this.picker=t.picker}postConstruct(){this.initTabIndex(),this.initRecentColors(),this.addGuiEventListener("focus",()=>this.spectrumColor.focus()),this.addGuiEventListener("keydown",e=>{e.key!==r.DDm.ENTER||e.defaultPrevented||this.destroy()}),this.addManagedListener(this.spectrumColor,"keydown",e=>this.moveDragger(e)),this.addManagedListener(this.spectrumAlphaSlider,"keydown",e=>this.moveAlphaSlider(e)),this.addManagedListener(this.spectrumHueSlider,"keydown",e=>this.moveHueSlider(e)),this.addManagedListener(this.spectrumVal,"mousedown",this.onSpectrumDraggerDown.bind(this)),this.addManagedListener(this.spectrumHue,"mousedown",this.onSpectrumHueDown.bind(this)),this.addManagedListener(this.spectrumAlpha,"mousedown",this.onSpectrumAlphaDown.bind(this)),this.addGuiEventListener("mousemove",e=>{this.onSpectrumDraggerMove(e),this.onSpectrumHueMove(e),this.onSpectrumAlphaMove(e)}),this.addManagedListener(document,"mouseup",this.onMouseUp.bind(this)),this.addManagedListener(this.recentColors,"click",this.onRecentColorClick.bind(this)),this.addManagedListener(this.recentColors,"keydown",e=>{e.key!==r.DDm.ENTER&&e.key!==r.DDm.SPACE||(e.preventDefault(),this.onRecentColorClick(e))})}initTabIndex(){const e=this.tabIndex=this.gos.get("tabIndex").toString();this.spectrumColor.setAttribute("tabindex",e),this.spectrumHueSlider.setAttribute("tabindex",e),this.spectrumAlphaSlider.setAttribute("tabindex",e)}refreshSpectrumRect(){return this.spectrumValRect=this.spectrumVal.getBoundingClientRect()}refreshHueRect(){return this.spectrumHueRect=this.spectrumHue.getBoundingClientRect()}refreshAlphaRect(){return this.spectrumAlphaRect=this.spectrumAlpha.getBoundingClientRect()}onSpectrumDraggerDown(e){this.refreshSpectrumRect(),this.isSpectrumDragging=!0,this.moveDragger(e)}onSpectrumDraggerMove(e){this.isSpectrumDragging&&this.moveDragger(e)}onSpectrumHueDown(e){this.refreshHueRect(),this.isSpectrumHueDragging=!0,this.moveHueSlider(e)}onSpectrumHueMove(e){this.isSpectrumHueDragging&&this.moveHueSlider(e)}onSpectrumAlphaDown(e){this.refreshAlphaRect(),this.isSpectrumAlphaDragging=!0,this.moveAlphaSlider(e)}onSpectrumAlphaMove(e){this.isSpectrumAlphaDragging&&this.moveAlphaSlider(e)}onMouseUp(){this.isSpectrumDragging=!1,this.isSpectrumHueDragging=!1,this.isSpectrumAlphaDragging=!1}moveDragger(e){const t=this.spectrumValRect;if(!t)return;let i,n;if(e instanceof MouseEvent)i=e.clientX-t.left,n=e.clientY-t.top;else{const t=e.key===r.DDm.LEFT,s=e.key===r.DDm.RIGHT,o=e.key===r.DDm.UP,a=e.key===r.DDm.DOWN,l=o||a,c=t||s;if(!l&&!c)return;e.preventDefault();const{x:u,y:h}=this.getSpectrumValue();i=u+(c?t?-5:5:0),n=h+(l?o?-5:5:0)}i=Math.max(i,0),i=Math.min(i,t.width),n=Math.max(n,0),n=Math.min(n,t.height),this.setSpectrumValue(i/t.width,1-n/t.height)}moveHueSlider(e){const t=this.spectrumHueRect;if(!t)return;const i=this.moveSlider(this.spectrumHueSlider,e);null!=i&&(this.H=1-i/t.width,this.update())}moveAlphaSlider(e){const t=this.spectrumAlphaRect;if(!t)return;const i=this.moveSlider(this.spectrumAlphaSlider,e);null!=i&&(this.A=i/t.width,this.update())}moveSlider(e,t){var i;const n=e.getBoundingClientRect(),s=null==(i=e.parentElement)?void 0:i.getBoundingClientRect();if(!e||!s)return null;let o;if(t instanceof MouseEvent)o=t.clientX-s.left;else{const i=t.key===r.DDm.LEFT,s=t.key===r.DDm.RIGHT;if(!i&&!s)return null;t.preventDefault();const a=i?-5:5;o=parseFloat(e.style.left)-n.width/2+a}return o=Math.max(o,0),o=Math.min(o,s.width),e.style.left=o+n.width/2+"px",o}update(){const e=n._Util.Color.fromHSB(360*this.H,this.S,this.B,this.A),t=n._Util.Color.fromHSB(360*this.H,1,1),i=e.toRgbaString(),r=this.picker;n._Util.Color.fromString(r.getValue()).toRgbaString()!==i&&(this.colorChanged=!0),r.setValue(i),this.spectrumColor.style.backgroundColor=t.toRgbaString(),this.spectrumDragger.style.backgroundColor=i}setSpectrumValue(e,t){const i=this.spectrumValRect||this.refreshSpectrumRect();if(null==i)return;const r=this.spectrumDragger,n=r.getBoundingClientRect();e=Math.max(0,e),e=Math.min(1,e),t=Math.max(0,t),t=Math.min(1,t),this.S=e,this.B=t,r.style.left=e*i.width-n.width/2+"px",r.style.top=(1-t)*i.height-n.height/2+"px",this.update()}getSpectrumValue(){const e=this.spectrumDragger,t=e.getBoundingClientRect();return{x:parseFloat(e.style.left)+t.width/2,y:parseFloat(e.style.top)+t.height/2}}initRecentColors(){const t=e.recentColors.map((e,t)=>`<div class="ag-recent-color" id=${t} style="background-color: ${e}; width: 15px; height: 15px;" recent-color="${e}" tabIndex="${this.tabIndex}"></div>`);this.recentColors.innerHTML=t.join("")}setValue(e){const t=n._Util.Color.fromString(e),[i,r,s]=t.toHSB();this.H=(isNaN(i)?0:i)/360,this.A=t.a;const o=this.spectrumHueRect||this.refreshHueRect(),a=this.spectrumAlphaRect||this.refreshAlphaRect();this.spectrumHueSlider.style.left=(this.H-1)*-o.width+"px",this.spectrumAlphaSlider.style.left=this.A*a.width+"px",this.setSpectrumValue(r,s)}onRecentColorClick(t){const i=t.target;if(!r._.exists(i.id))return;const n=parseInt(i.id,10);this.setValue(e.recentColors[n]),this.destroy()}addRecentColor(){const t=n._Util.Color.fromHSB(360*this.H,this.S,this.B,this.A).toRgbaString();let i=e.recentColors;this.colorChanged&&i[0]!==t&&(i=i.filter(e=>e!=t),i=[t].concat(i),i.length>e.maxRecentColors&&(i=i.slice(0,e.maxRecentColors)),e.recentColors=i)}destroy(){this.addRecentColor(),super.destroy()}};_i.maxRecentColors=8,_i.recentColors=[],_i.TEMPLATE='<div class="ag-color-panel" tabindex="-1">\n            <div ref="spectrumColor" class="ag-spectrum-color">\n                <div class="ag-spectrum-sat ag-spectrum-fill">\n                    <div ref="spectrumVal" class="ag-spectrum-val ag-spectrum-fill">\n                        <div ref="spectrumDragger" class="ag-spectrum-dragger"></div>\n                    </div>\n                </div>\n            </div>\n            <div class="ag-spectrum-tools">\n                <div ref="spectrumHue" class="ag-spectrum-hue ag-spectrum-tool">\n                    <div class="ag-spectrum-hue-background"></div>\n                    <div ref="spectrumHueSlider" class="ag-spectrum-slider"></div>\n                </div>\n                <div ref="spectrumAlpha" class="ag-spectrum-alpha ag-spectrum-tool">\n                    <div class="ag-spectrum-alpha-background"></div>\n                    <div ref="spectrumAlphaSlider" class="ag-spectrum-slider"></div>\n                </div>\n                <div ref="recentColors" class="ag-recent-colors"></div>\n            </div>\n        </div>',qe([(0,r.PIB)("spectrumColor")],_i.prototype,"spectrumColor",2),qe([(0,r.PIB)("spectrumVal")],_i.prototype,"spectrumVal",2),qe([(0,r.PIB)("spectrumDragger")],_i.prototype,"spectrumDragger",2),qe([(0,r.PIB)("spectrumHue")],_i.prototype,"spectrumHue",2),qe([(0,r.PIB)("spectrumHueSlider")],_i.prototype,"spectrumHueSlider",2),qe([(0,r.PIB)("spectrumAlpha")],_i.prototype,"spectrumAlpha",2),qe([(0,r.PIB)("spectrumAlphaSlider")],_i.prototype,"spectrumAlphaSlider",2),qe([(0,r.PIB)("recentColors")],_i.prototype,"recentColors",2),qe([r.o7C],_i.prototype,"postConstruct",1);var Pi=_i,xi=class extends r.HHt{constructor(e){super(je({pickerAriaLabelKey:"ariaLabelColorPicker",pickerAriaLabelValue:"Color Picker",pickerType:"ag-list",className:"ag-color-picker",pickerIcon:"colorPicker"},e))}postConstruct(){super.postConstruct(),this.value&&this.setValue(this.value)}createPickerComponent(){const e=this.getGui().getBoundingClientRect();return this.createBean(new r.fNJ({closable:!1,modal:!0,hideTitleBar:!0,minWidth:190,width:190,height:250,x:e.right-190,y:e.top-250}))}renderAndPositionPicker(){const e=this.pickerComponent,t=this.createBean(new Pi({picker:this}));return e.addCssClass("ag-color-dialog"),t.addDestroyFunc(()=>{e.isAlive()&&this.destroyBean(e)}),e.setParentComponent(this),e.setBodyComponent(t),t.setValue(this.getValue()),t.getGui().focus(),e.addDestroyFunc(()=>{this.isDestroyingPicker?this.isDestroyingPicker=!1:(this.beforeHidePicker(),this.isDestroyingPicker=!0,t.isAlive()&&this.destroyBean(t),this.isAlive()&&this.getFocusableElement().focus())}),()=>{var e;return null==(e=this.pickerComponent)?void 0:e.close()}}setValue(e){return this.value===e?this:(this.eDisplayField.style.backgroundColor=e,super.setValue(e))}getValue(){return this.value}},Di=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("callout"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{calloutGroup:t,calloutLengthSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLine.length","length",40),calloutStrokeWidthSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLine.strokeWidth","strokeWidth",10),labelOffsetSlider:this.chartMenuUtils.getDefaultSliderParams("calloutLabel.offset","offset",30)})}};Di.TEMPLATE='<div>\n            <ag-group-component ref="calloutGroup">\n                <ag-slider ref="calloutLengthSlider"></ag-slider>\n                <ag-slider ref="calloutStrokeWidthSlider"></ag-slider>\n                <ag-slider ref="labelOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Di.prototype,"chartTranslationService",2),qe([r.o7C],Di.prototype,"init",1);var Ii=Di,Li=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("cap"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0},i=this.chartMenuUtils.getDefaultSliderParams("cap.lengthRatio","capLengthRatio",1);i.step=.05,this.setTemplate(e.TEMPLATE,{capsGroup:t,capLengthRatioSlider:i})}};Li.TEMPLATE='<div>\n            <ag-group-component ref="capsGroup">\n                <ag-slider ref="capLengthRatioSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Li.prototype,"chartTranslationService",2),qe([r.o7C],Li.prototype,"init",1);var Ni=Li,Oi=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("connectorLine"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{lineGroup:t,lineColorPicker:this.chartMenuUtils.getDefaultColorPickerParams("line.stroke"),lineStrokeWidthSlider:this.getSliderParams("strokeWidth",10,"line.strokeWidth"),lineDashSlider:this.getSliderParams("lineDash",30,"line.lineDash",1,!0),lineOpacitySlider:this.getSliderParams("strokeOpacity",1,"line.strokeOpacity",.05)})}getSliderParams(e,t,i,r=1,n=!1){const s=this.chartMenuUtils.getDefaultSliderParams(i,e,t,n);return s.step=r,s}};Oi.TEMPLATE='<div>\n            <ag-group-component ref="lineGroup">\n                <ag-color-picker ref="lineColorPicker"></ag-color-picker>\n                <ag-slider ref="lineStrokeWidthSlider"></ag-slider>\n                <ag-slider ref="lineOpacitySlider"></ag-slider>\n                <ag-slider ref="lineDashSlider"></ag-slider>                \n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Oi.prototype,"chartTranslationService",2),qe([r.o7C],Oi.prototype,"init",1);var Fi=Oi,ki=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("whisker"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{whiskersGroup:t,whiskerColorPicker:this.chartMenuUtils.getDefaultColorPickerParams("whisker.stroke"),whiskerThicknessSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.strokeWidth","strokeWidth",10),whiskerOpacitySlider:this.chartMenuUtils.getDefaultSliderParams("whisker.strokeOpacity","strokeOpacity",1),whiskerLineDashSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.lineDash","lineDash",30,!0),whiskerLineDashOffsetSlider:this.chartMenuUtils.getDefaultSliderParams("whisker.lineDashOffset","lineDashOffset",30)})}};ki.TEMPLATE='<div>\n            <ag-group-component ref="whiskersGroup">\n                <ag-color-picker ref="whiskerColorPicker"></ag-color-picker>\n                <ag-slider ref="whiskerThicknessSlider"></ag-slider>\n                <ag-slider ref="whiskerOpacitySlider"></ag-slider>\n                <ag-slider ref="whiskerLineDashSlider"></ag-slider>\n                <ag-slider ref="whiskerLineDashOffsetSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],ki.prototype,"chartTranslationService",2),qe([r.o7C],ki.prototype,"init",1);var Gi=ki,Vi=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e,this.activePanels=[]}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",title:this.chartTranslationService.translate("seriesItems"),enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{seriesItemsGroup:t,seriesItemSelect:this.getSeriesItemsParams()}),this.initSeriesControls()}getSeriesItemsParams(){const e=[{value:"positive",text:this.chartTranslationService.translate("seriesItemPositive")},{value:"negative",text:this.chartTranslationService.translate("seriesItemNegative")}];return{label:this.chartTranslationService.translate("seriesItemType"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:e,value:"positive",onValueChange:e=>{this.destroyActivePanels(),this.initSeriesControls(e)}}}initSeriesControls(e="positive"){this.initSlider("strokeWidth",10,`item.${e}.strokeWidth`),this.initSlider("lineDash",30,`item.${e}.lineDash`,1,!0),this.initSlider("strokeOpacity",1,`item.${e}.strokeOpacity`,.05,!1),this.initSlider("fillOpacity",1,`item.${e}.fillOpacity`,.05,!1),this.initItemLabels(e)}initSlider(e,t,i,n=1,s=!1){const o=this.chartMenuUtils.getDefaultSliderParams(i,e,t,s);o.step=n;const a=this.seriesItemsGroup.createManagedBean(new r.YD7(o));this.seriesItemsGroup.addItem(a),this.activePanels.push(a)}initItemLabels(e){const t=this.chartMenuUtils.getDefaultFontPanelParams(`item.${e}.label`,"seriesItemLabels"),i=this.createBean(new ii(t));this.seriesItemsGroup.addItem(i),this.activePanels.push(i)}destroyActivePanels(){this.activePanels.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};Vi.TEMPLATE='<div>\n            <ag-group-component ref="seriesItemsGroup">\n                <ag-select ref="seriesItemSelect"></ag-select>\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("seriesItemsGroup")],Vi.prototype,"seriesItemsGroup",2),qe([(0,r.dsm)("chartTranslationService")],Vi.prototype,"chartTranslationService",2),qe([r.o7C],Vi.prototype,"init",1);var Hi=Vi,Bi=class e extends r.uAl{constructor(e){super(),this.chartMenuUtils=e}init(){const t={cssIdentifier:"charts-format-sub-level",direction:"vertical",enabled:!0,suppressOpenCloseIcons:!0,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{groupSpacing:Ke(je({},t),{title:this.chartTranslationService.translate("group")}),tileSpacing:Ke(je({},t),{title:this.chartTranslationService.translate("tile")}),groupPaddingSlider:this.getSliderParams("padding","group.padding"),groupSpacingSlider:this.getSliderParams("spacing","group.gap"),tilePaddingSlider:this.getSliderParams("padding","tile.padding"),tileSpacingSlider:this.getSliderParams("spacing","tile.gap")})}getSliderParams(e,t){return this.chartMenuUtils.getDefaultSliderParams(t,e,10)}};Bi.TEMPLATE='<div>\n            <ag-group-component ref="groupSpacing">\n                <ag-slider ref="groupPaddingSlider"></ag-slider>\n                <ag-slider ref="groupSpacingSlider"></ag-slider>\n            </ag-group-component>\n            <ag-group-component ref="tileSpacing">\n                <ag-slider ref="tilePaddingSlider"></ag-slider>\n                <ag-slider ref="tileSpacingSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Bi.prototype,"chartTranslationService",2),qe([r.o7C],Bi.prototype,"init",1);var zi=Bi,Ui=class e extends r.uAl{constructor({chartController:e,chartOptionsService:t,seriesType:i,isExpandedOnInit:r=!1}){super(),this.activePanels=[],this.widgetFuncs={lineWidth:()=>this.initStrokeWidth("lineWidth"),strokeWidth:()=>this.initStrokeWidth("strokeWidth"),lineColor:()=>this.initLineColor(),lineDash:()=>this.initLineDash(),lineOpacity:()=>this.initLineOpacity(),fillOpacity:()=>this.initFillOpacity(),markers:()=>this.initMarkers(),labels:()=>this.initLabels(),shadow:()=>this.initShadow(),tooltips:()=>this.initTooltips(),bins:()=>this.initBins(),whiskers:()=>this.initWhiskers(),caps:()=>this.initCaps(),connectorLine:()=>this.initConnectorLine(),seriesItems:()=>this.initSeriesItemsPanel(),tileSpacing:()=>this.initTileSpacingPanel(),groupType:()=>this.initGroupType()},this.seriesWidgetMappings={bar:["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","shadow"],pie:["tooltips","strokeWidth","lineOpacity","fillOpacity","labels","shadow"],donut:["tooltips","strokeWidth","lineOpacity","fillOpacity","labels","shadow"],line:["tooltips","lineWidth","lineDash","lineOpacity","markers","labels"],scatter:["tooltips","markers","labels"],bubble:["tooltips","markers","labels"],area:["tooltips","lineWidth","lineDash","lineOpacity","fillOpacity","markers","labels","shadow"],histogram:["tooltips","bins","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","shadow"],"radial-column":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"radial-bar":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"radar-line":["tooltips","strokeWidth","lineDash","lineOpacity","markers","labels"],"radar-area":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","markers","labels"],nightingale:["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels","groupType"],"box-plot":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","whiskers","caps"],"range-bar":["tooltips","strokeWidth","lineDash","lineOpacity","fillOpacity","labels"],"range-area":["tooltips","lineWidth","lineDash","lineOpacity","fillOpacity","markers","labels","shadow"],treemap:["tooltips","tileSpacing"],sunburst:["tooltips"],heatmap:["tooltips","labels","lineColor","lineWidth","lineOpacity"],waterfall:["tooltips","connectorLine","seriesItems"]},this.chartController=e,this.chartOptionsService=t,this.seriesType=i||this.chartController.getChartSeriesType(),this.isExpandedOnInit=r}init(){const t={cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.translate("series"),expanded:this.isExpandedOnInit,suppressEnabledCheckbox:!0};this.setTemplate(e.TEMPLATE,{seriesGroup:t}),this.chartMenuUtils=this.createManagedBean(new hi(this.chartOptionsService.getSeriesOptionsProxy(()=>this.seriesType))),this.chartOptions=this.chartMenuUtils.getChartOptions(),this.addManagedListener(this.chartController,Gt.EVENT_CHART_SERIES_CHART_TYPE_CHANGED,this.refreshWidgets.bind(this)),this.refreshWidgets()}refreshWidgets(){this.destroyActivePanels(),this.chartController.getChartProxy().getChart().waitForUpdate().then(()=>{var e;!this.isAlive()||(this.chartController.isComboChart()&&(this.updateSeriesType(),this.initSeriesSelect()),(null!=(e=this.seriesWidgetMappings[this.seriesType])?e:[]).forEach(e=>this.widgetFuncs[e]()))}).catch(e=>console.error("AG Grid - chart rendering failed",e))}initSeriesSelect(){const e=this.seriesGroup.createManagedBean(new r.Ju4({label:this.translate("seriesType"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:this.getSeriesSelectOptions(),value:`${this.seriesType}`,onValueChange:e=>{this.seriesType=e,this.refreshWidgets()}}));this.seriesGroup.addItem(e),this.activePanels.push(e)}initTooltips(){const e=this.createBean(new r.bLJ(this.chartMenuUtils.addValueParams("tooltip.enabled",{label:this.translate("tooltips"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex"})));this.addWidget(e)}initLineColor(){const e=this.createBean(new xi(this.chartMenuUtils.getDefaultColorPickerParams("stroke","strokeColor")));this.addWidget(e)}initStrokeWidth(e){const t=this.createBean(new r.YD7(this.chartMenuUtils.getDefaultSliderParams("strokeWidth",e,10)));this.addWidget(t)}initLineDash(){const e=this.createBean(new r.YD7(this.chartMenuUtils.getDefaultSliderParams("lineDash","lineDash",30,!0)));this.addWidget(e)}initLineOpacity(){const e=this.chartMenuUtils.getDefaultSliderParams("strokeOpacity","strokeOpacity",1);e.step=.05;const t=this.createBean(new r.YD7(e));this.addWidget(t)}initFillOpacity(){const e=this.chartMenuUtils.getDefaultSliderParams("fillOpacity","fillOpacity",1);e.step=.05;const t=this.createBean(new r.YD7(e));this.addWidget(t)}initLabels(){const e=ut(this.seriesType),t=e?"calloutLabel":"label",i=e?"calloutLabels":"labels",n=this.chartMenuUtils.getDefaultFontPanelParams(t,i),s=this.createBean(new ii(n));if(e){const e=this.createBean(new Ii(this.chartMenuUtils));s.addCompToPanel(e),this.activePanels.push(e)}if(this.addWidget(s),e){const e=this.chartMenuUtils.getDefaultFontPanelParams("sectorLabel","sectorLabels"),t=this.createBean(new ii(e)),i=this.getSectorLabelPositionRatio();t.addCompToPanel(i),this.addWidget(t)}if("range-bar"===this.seriesType){const e=[{value:"inside",text:this.translate("inside")},{value:"outside",text:this.translate("outside")}],t=s.createManagedBean(new r.Ju4(this.chartMenuUtils.addValueParams("label.placement",{label:this.translate("labelPlacement"),labelAlignment:"left",labelWidth:"flex",inputWidth:"flex",options:e})));s.addCompToPanel(t),this.activePanels.push(t);const i=s.createManagedBean(new r.YD7(this.chartMenuUtils.getDefaultSliderParams("label.padding","padding",200)));s.addCompToPanel(i),this.activePanels.push(i)}}getSectorLabelPositionRatio(){const e=this.chartMenuUtils.getDefaultSliderParams("sectorLabel.positionRatio","positionRatio",1);return e.step=.05,this.createBean(new r.YD7(e))}initShadow(){const e=this.createBean(new Ti(this.chartMenuUtils));this.addWidget(e)}initMarkers(){const e=this.createBean(new Ri(this.chartOptionsService,this.chartMenuUtils));this.addWidget(e)}initBins(){var e;const t=this.chartMenuUtils.getDefaultSliderParams("binCount","histogramBinCount",20),i=(null!=(e=this.chartOptions.getValue("bins"))?e:this.chartOptions.getValue("calculatedBins",!0)).length;t.value=`${i}`,t.maxValue=Math.max(i,20);const n=this.createBean(new r.YD7(t));this.addWidget(n)}initWhiskers(){const e=this.createBean(new Gi(this.chartMenuUtils));this.addWidget(e)}initCaps(){const e=this.createBean(new Ni(this.chartMenuUtils));this.addWidget(e)}initConnectorLine(){const e=this.createBean(new Fi(this.chartMenuUtils));this.addWidget(e)}initSeriesItemsPanel(){const e=this.createBean(new Hi(this.chartMenuUtils));this.addWidget(e)}initTileSpacingPanel(){const e=this.createBean(new zi(this.chartMenuUtils));this.addWidget(e)}initGroupType(){const e=this.createBean(new r.Ju4({label:this.chartTranslationService.translate("seriesGroupType"),options:r.E1g.SERIES_GROUP_TYPES.map(e=>({value:e,text:this.chartTranslationService.translate(`${e}SeriesGroupType`)})),value:this.chartController.getSeriesGroupType(),onValueChange:e=>this.chartController.setSeriesGroupType(e)}));this.addWidget(e)}addWidget(e){this.seriesGroup.addItem(e),this.activePanels.push(e)}getSeriesSelectOptions(){const e=this.getActiveSeriesTypes();return["area","bar","line"].filter(t=>e.includes(t)).map(e=>({value:e,text:this.translate(e)}))}updateSeriesType(){const e=this.getActiveSeriesTypes();!e.includes(this.seriesType)&&e.length>0&&(this.seriesType=e[0])}getActiveSeriesTypes(){return this.chartController.getActiveSeriesChartTypes().map(e=>ct(e.chartType))}translate(e){return this.chartTranslationService.translate(e)}destroyActivePanels(){this.activePanels.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)})}destroy(){this.destroyActivePanels(),super.destroy()}};Ui.TEMPLATE='<div>\n            <ag-group-component ref="seriesGroup">\n            </ag-group-component>\n        </div>',qe([(0,r.PIB)("seriesGroup")],Ui.prototype,"seriesGroup",2),qe([(0,r.dsm)("chartTranslationService")],Ui.prototype,"chartTranslationService",2),qe([r.o7C],Ui.prototype,"init",1);var Wi=Ui,ji=class e extends r.uAl{constructor({chartMenuParamsFactory:e,isExpandedOnInit:t=!1}){super(),this.chartMenuUtils=e,this.isExpandedOnInit=t}init(){const t=this.chartMenuUtils.addEnableParams("gradientLegend.enabled",{cssIdentifier:"charts-format-top-level",direction:"vertical",title:this.chartTranslationService.translate("legend"),suppressEnabledCheckbox:!1,suppressToggleExpandOnEnableChange:!0,expanded:this.isExpandedOnInit,items:[this.createLabelPanel()]});this.setTemplate(e.TEMPLATE,{legendGroup:t,legendPositionSelect:this.chartMenuUtils.getDefaultLegendParams("gradientLegend.position"),gradientReverseCheckbox:this.getGradientReverseCheckboxParams(),gradientThicknessSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.gradient.thickness","thickness",40),gradientPreferredLengthSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.gradient.preferredLength","preferredLength",300),legendSpacingSlider:this.chartMenuUtils.getDefaultSliderParams("gradientLegend.spacing","spacing",200)})}getGradientReverseCheckboxParams(){return this.chartMenuUtils.addValueParams("gradientLegend.reverseOrder",{label:this.chartTranslationService.translate("reverseDirection"),labelWidth:"flex"})}createLabelPanel(){const e={enabled:!0,suppressEnabledCheckbox:!0,chartMenuUtils:this.chartMenuUtils,keyMapper:e=>`gradientLegend.scale.label.${e}`};return this.createManagedBean(new ii(e))}};ji.TEMPLATE='<div>\n            <ag-group-component ref="legendGroup">\n                <ag-select ref="legendPositionSelect"></ag-select>\n                <ag-checkbox ref="gradientReverseCheckbox"></ag-checkbox>\n                <ag-slider ref="gradientThicknessSlider"></ag-slider>\n                <ag-slider ref="gradientPreferredLengthSlider"></ag-slider>\n                <ag-slider ref="legendSpacingSlider"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],ji.prototype,"chartTranslationService",2),qe([r.o7C],ji.prototype,"init",1);var Ki=ji,$i=class extends r.XQb{constructor(e,t,i,r){super(),this.chartController=e,this.eGui=t,this.cssClass=i,this.createPanels=r,this.panels=[]}postConstruct(){this.addManagedListener(this.chartController,Gt.EVENT_CHART_UPDATED,()=>this.refreshPanels(!0)),this.addManagedListener(this.chartController,Gt.EVENT_CHART_API_UPDATE,()=>this.refreshPanels(!1))}addComponent(e){this.createBean(e),this.panels.push(e),e.addCssClass(this.cssClass),this.eGui.appendChild(e.getGui())}refreshPanels(e){const t=this.chartController.getChartType(),i=this.chartController.isGrouping(),r=ct(t);e&&t===this.chartType&&i===this.isGrouping||(this.destroyPanels(),this.createPanels(t,r),this.chartType=t,this.isGrouping=i)}destroyPanels(){this.panels.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)}),this.panels=[]}destroy(){this.destroyPanels(),super.destroy()}};qe([r.o7C],$i.prototype,"postConstruct",1);var qi={groups:[{type:"chart"},{type:"legend"},{type:"series"},{type:"axis"}]},Yi=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}init(){this.chartPanelFeature=this.createManagedBean(new $i(this.chartMenuContext.chartController,this.getGui(),"ag-chart-format-section",(e,t)=>this.createPanels(e,t))),this.chartPanelFeature.refreshPanels()}createPanels(e,t){var i;null==(i=this.getFormatPanelDef().groups)||i.forEach(i=>{const n=i.type;if(!this.isGroupPanelShownInSeries(n,t))return;const s=Ke(je({},this.chartMenuContext),{isExpandedOnInit:i.isOpen,seriesType:t});switch(n){case"chart":this.chartPanelFeature.addComponent(new Ei(s));break;case"legend":const n=["treemap","sunburst","heatmap"].includes(e)?new Ki(s):new ni(s);this.chartPanelFeature.addComponent(n);break;case"axis":st(t)?this.chartPanelFeature.addComponent(new fi(s)):nt(t)&&(this.chartPanelFeature.addComponent(new pi("xAxis",s)),this.chartPanelFeature.addComponent(new pi("yAxis",s)));break;case"horizontalAxis":this.chartPanelFeature.addComponent(new pi("xAxis",s));break;case"verticalAxis":this.chartPanelFeature.addComponent(new pi("yAxis",s));break;case"series":this.chartPanelFeature.addComponent(new Wi(s));break;case"navigator":r._.warnOnce("'navigator' is now displayed in the charts advanced settings instead of the format panel, and this setting will be ignored.");default:r._.warnOnce(`Invalid charts format panel group name supplied: '${i.type}'`)}})}getFormatPanelDef(){var e;return(null==(e=this.gos.get("chartToolPanelsDef"))?void 0:e.formatPanel)||qi}isGroupPanelShownInSeries(e,t){return["chart","legend","series"].includes(e)||nt(t)&&["axis","horizontalAxis","verticalAxis"].includes(e)||st(t)&&"axis"===e}};Yi.TEMPLATE='<div class="ag-chart-format-wrapper"></div>',qe([r.o7C],Yi.prototype,"init",1);var Qi=Yi,Xi=class extends r.uAl{constructor(e,t){super(),this.tooltipName=t,this.size=58,this.padding=5,this.root=new n._Scene.Group;const i=new n._Scene.Scene({width:this.size,height:this.size});i.canvas.element.classList.add("ag-chart-mini-thumbnail-canvas"),i.setRoot(this.root),i.setContainer(e),this.scene=i}init(){this.scene.canvas.element.title=this.chartTranslationService.translate(this.tooltipName),this.scene.render().catch(e=>{console.error("AG Grid - chart update failed",e)})}};qe([(0,r.dsm)("chartTranslationService")],Xi.prototype,"chartTranslationService",2),qe([r.o7C],Xi.prototype,"init",1);var Zi=class extends Xi{constructor(e,t){super(e,t),this.stroke="gray",this.axisOvershoot=3}addAxes(){const e=this.size,t=this.padding,i=new n._Scene.Line;i.x1=t,i.y1=t,i.x2=t,i.y2=e-t+this.axisOvershoot,i.stroke=this.stroke;const r=new n._Scene.Line;r.x1=t-this.axisOvershoot+1,r.y1=e-t,r.x2=e-t+1,r.y2=e-t,r.stroke=this.stroke;const s=this.root;s.append(i),s.append(r)}};function Ji(e){const{stacked:t,size:i,padding:r,xScalePadding:s,xScaleDomain:o,yScaleDomain:a}=e,l=new n._Scene.BandScale;l.domain=o,l.range=[r,i-r],l.paddingInner=s,l.paddingOuter=s;const c=new n._Scene.LinearScale;c.domain=a,c.range=[i-r,r];const u=(e,t,i)=>e.map((e,r)=>{const s=i.convert(e),o=new n._Scene.Rect;return o.x=t.convert(r),o.y=s,o.width=t.bandwidth,o.height=i.convert(0)-s,o.strokeWidth=0,o.crisp=!0,o});return t?e.data.map(e=>u(e,l,c)):u(e.data,l,c)}function er(e,t,i,r){const s=new n._Scene.LinearScale;s.domain=[0,4],s.range=[r,i-r];const o=new n._Scene.LinearScale;o.domain=[0,10],o.range=[i-r,r];const a=t.map(e=>{const t=new n._Scene.Path;return t.strokeWidth=3,t.lineCap="round",t.fill=void 0,e.forEach((e,i)=>{t.path[i>0?"lineTo":"moveTo"](s.convert(i),o.convert(e))}),t}),l=new n._Scene.Group;return l.setClipRectInGroupCoordinateSpace(new n._Scene.BBox(r,r,i-2*r,i-2*r)),l.append(a),e.append(l),a}function tr(e,t,i,r,s,o=0){const a=new n._Scene.LinearScale;a.domain=[0,7],a.range=[-Math.PI,Math.PI].map(e=>e+Math.PI/2);const l=new n._Scene.LinearScale;l.domain=[0,10],l.range=[r,s];const c=[],u=t.map(e=>{const t=new n._Scene.Path;return t.strokeWidth=1,t.strokeOpacity=.5,t.lineCap="round",t.fill=void 0,t.fillOpacity=.8,e.forEach((e,i)=>{const u=a.convert(i),h=r+s-l.convert(e),d=h*Math.cos(u),p=h*Math.sin(u);if(t.path[i>0?"lineTo":"moveTo"](d,p),o>0){const e=new n._Scene.Circle;e.x=d,e.y=p,e.size=o,c.push(e)}}),t.path.closePath(),t}),h=new n._Scene.Group,d=i/2;return h.translationX=d,h.translationY=d,h.append([...u,...c]),e.append(h),{paths:u,markers:c}}function ir(e){let[t,i]=[1/0,-1/0];return{processedData:e.reduce((e,r,n)=>{const s=n>0?e[n-1]:void 0;null!=e[n]||(e[n]=[]);const o=e[n];return r.forEach((e,r)=>{s&&(e+=s[r]),o[r]=e,o[r]<t&&(t=o[r]),o[r]>i&&(i=o[r])}),e},[]),min:t,max:i}}qe([r.o7C],Zi.prototype,"addAxes",1);var rr=class extends Zi{constructor(e,t,i){super(e,"groupedColumnTooltip"),this.columnData=[2,3,4];const{root:r,columnData:n,size:s,padding:o}=this;this.columns=Ji({stacked:!1,root:r,data:n,size:s,padding:o,xScaleDomain:[0,1,2],yScaleDomain:[0,4],xScalePadding:.3}),r.append(this.columns),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};rr.chartType="groupedColumn";var nr=class e extends Zi{constructor(t,i,r,n,s,o=e.data,a=[0,16],l="stackedColumnTooltip"){super(t,l);const{root:c,size:u,padding:h}=this;this.stackedColumns=Ji({stacked:!0,root:c,data:o,size:u,padding:h,xScaleDomain:[0,1,2],yScaleDomain:a,xScalePadding:.3}),c.append([].concat.apply([],this.stackedColumns)),this.updateColors(i,r)}updateColors(e,t){this.stackedColumns.forEach((i,r)=>i.forEach(i=>{i.fill=e[r],i.stroke=t[r]}))}};nr.chartType="stackedColumn",nr.data=[[8,12,16],[6,9,12],[2,3,4]];var sr=nr,or=class e extends sr{constructor(t,i,r,n,s){super(t,i,r,n,s,e.data,[0,10],"normalizedColumnTooltip")}};or.chartType="normalizedColumn",or.data=[[10,10,10],[6,7,8],[2,4,6]];var ar=or,lr=class extends Zi{constructor(e,t,i){super(e,"groupedBarTooltip");const r=this.padding,s=this.size,o=new n._Scene.BandScale;o.domain=[0,1,2],o.range=[r,s-r],o.paddingInner=.3,o.paddingOuter=.3;const a=new n._Scene.LinearScale;a.domain=[0,4],a.range=[s-r,r];const l=a.convert(0),c=o.bandwidth;this.bars=[2,3,4].map((e,t)=>{const i=new n._Scene.Rect;return i.x=r,i.y=o.convert(t),i.width=l-a.convert(e),i.height=c,i.strokeWidth=0,i.crisp=!0,i}),this.updateColors(t,i),this.root.append(this.bars)}updateColors(e,t){this.bars.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};lr.chartType="groupedBar";var cr=class e extends Zi{constructor(t,i,r,s,o,a=e.data,l=[0,16],c="stackedBarTooltip"){super(t,c);const u=this.size,h=this.padding,d=new n._Scene.BandScale;d.domain=[0,1,2],d.range=[h,u-h],d.paddingInner=.3,d.paddingOuter=.3;const p=new n._Scene.LinearScale;p.domain=l,p.range=[u-h,h];const g=p.convert(0),f=d.bandwidth;this.bars=a.map(e=>e.map((e,t)=>{const i=new n._Scene.Rect;return i.x=h,i.y=d.convert(t),i.width=g-p.convert(e),i.height=f,i.strokeWidth=0,i.crisp=!0,i})),this.updateColors(i,r),this.root.append([].concat.apply([],this.bars))}updateColors(e,t){this.bars.forEach((i,r)=>i.forEach(i=>{i.fill=e[r],i.stroke=t[r]}))}};cr.chartType="stackedBar",cr.data=[[8,12,16],[6,9,12],[2,3,4]];var ur=cr,hr=class e extends ur{constructor(t,i,r,n,s){super(t,i,r,n,s,e.data,[0,10],"normalizedBarTooltip")}};hr.chartType="normalizedBar",hr.data=[[10,10,10],[6,7,8],[2,4,6]];var dr=hr,pr=n._Scene.toRadians,gr=class extends Xi{constructor(e,t,i,r,s,o=.6,a="donutTooltip"){super(e,a);const l=(this.size-2*this.padding)/2,c=l+this.padding,u=[[pr(-90),pr(30)],[pr(30),pr(120)],[pr(120),pr(180)],[pr(180),pr(210)],[pr(210),pr(240)],[pr(240),pr(270)]];this.sectors=u.map(([e,t])=>{const i=new n._Scene.Sector;return i.centerX=c,i.centerY=c,i.innerRadius=l*o,i.outerRadius=l,i.startAngle=e,i.endAngle=t,i.stroke=void 0,i.strokeWidth=0,i.inset=.75,i}),this.updateColors(t,i),this.root.append(this.sectors)}updateColors(e,t){this.sectors.forEach((i,r)=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})}};gr.chartType="donut";var fr=class extends gr{constructor(e,t,i,r,n){super(e,t,i,r,n,0,"pieTooltip")}};fr.chartType="pie";var mr=class extends Zi{constructor(e,t,i){super(e,"lineTooltip"),this.data=[[9,7,8,5,6],[5,6,3,4,1],[1,3,4,8,7]],this.lines=er(this.root,this.data,this.size,this.padding),this.updateColors(t,i)}updateColors(e,t){this.lines.forEach((t,i)=>{t.stroke=e[i]})}};mr.chartType="line";var vr=class extends Zi{constructor(e,t,i){super(e,"scatterTooltip");const r=this.size,s=this.padding,o=new n._Scene.LinearScale;o.domain=[-.5,4],o.range=[2*s,r-s];const a=new n._Scene.LinearScale;a.domain=[-.5,3.5],a.range=[r-s,s];const l=[];[[[.3,3],[1.1,.9],[2,.4],[3.4,2.4]],[[0,.3],[1,2],[2.4,1.4],[3,0]]].forEach(e=>{e.forEach(([e,t])=>{const i=new n._Scene.Arc;i.strokeWidth=0,i.centerX=o.convert(e),i.centerY=a.convert(t),i.radius=2.5,l.push(i)})}),this.points=l,this.updateColors(t,i);const c=new n._Scene.Group;c.setClipRectInGroupCoordinateSpace(new n._Scene.BBox(s,s,r-2*s,r-2*s)),c.append(this.points),this.root.append(c)}updateColors(e,t){this.points.forEach((i,r)=>{i.stroke=t[r%t.length],i.fill=e[r%e.length]})}};vr.chartType="scatter";var Cr=class extends Zi{constructor(e,t,i){super(e,"bubbleTooltip");const r=this.size,s=this.padding,o=new n._Scene.LinearScale;o.domain=[0,1],o.range=[2*s,r-s];const a=new n._Scene.LinearScale;a.domain=[0,1],a.range=[r-s,s];const l=[];[[[.1,.3,5],[.5,.4,7],[.2,.8,7]],[[.8,.7,5],[.7,.3,9]]].forEach(e=>{e.forEach(([e,t,i])=>{const r=new n._Scene.Arc;r.strokeWidth=0,r.centerX=o.convert(e),r.centerY=a.convert(t),r.radius=i,r.fillOpacity=.7,l.push(r)})}),this.points=l,this.updateColors(t,i);const c=new n._Scene.Group;c.setClipRectInGroupCoordinateSpace(new n._Scene.BBox(s,s,r-2*s,r-2*s)),c.append(this.points),this.root.append(c)}updateColors(e,t){this.points.forEach((i,r)=>{i.stroke=t[r%t.length],i.fill=e[r%e.length]})}};Cr.chartType="bubble";var yr=class e extends Zi{constructor(t,i,r,s,o,a=e.data){super(t,"groupedAreaTooltip");const l=this.size,c=this.padding,u=new n._Scene.BandScale;u.domain=[0,1,2],u.paddingInner=1,u.paddingOuter=0,u.range=[c+.5,l-c-.5];const h=new n._Scene.LinearScale;h.domain=[0,6],h.range=[l-c+.5,c];const d=2*a.length-1,p=[],g=h.convert(0);a.forEach((e,t)=>{const i=u.convert(t);e.forEach((e,r)=>{const n=h.convert(e),s=p[r]||(p[r]=[]);s[t]={x:i,y:n},s[d-t]={x:i,y:g}})}),this.areas=p.reverse().map(e=>{const t=new n._Scene.Path;t.strokeWidth=1,t.strokeOpacity=.75,t.fillOpacity=.7;const i=t.path;return i.clear(),e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),i.closePath(),t}),this.updateColors(i,r),this.root.append(this.areas)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};yr.chartType="area",yr.data=[[1,3,5],[2,6,4],[5,3,1]];var wr=yr,Sr=class e extends Zi{constructor(t,i,r,s,o,a=e.data,l="stackedAreaTooltip"){super(t,l);const c=this.size,u=this.padding,h=new n._Scene.BandScale;h.domain=[0,1,2],h.paddingInner=1,h.paddingOuter=0,h.range=[u+.5,c-u-.5];const d=new n._Scene.LinearScale;d.domain=[0,16],d.range=[c-u+.5,u+.5];const p=2*a.length-1,g=[];a.forEach((e,t)=>{const i=h.convert(t);let r=0;e.forEach((e,n)=>{const s=d.convert(r+e),o=g[n]||(g[n]=[]);o[t]={x:i,y:s},o[p-t]={x:i,y:d.convert(r)},r+=e})}),this.areas=g.map(e=>{const t=new n._Scene.Path;t.strokeWidth=0;const i=t.path;return i.clear(),e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),i.closePath(),t}),this.updateColors(i,r),this.root.append(this.areas)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};Sr.chartType="stackedArea",Sr.data=[[2,3,2],[3,6,5],[6,2,2]];var br=Sr,Er=class e extends br{constructor(t,i,r,n,s,o=e.data){super(t,i,r,n,s,o,"normalizedAreaTooltip")}};Er.chartType="normalizedArea",Er.data=br.data.map(e=>{const t=e.reduce((e,t)=>e+t,0);return e.map(e=>e/t*16)});var Ar=Er,Tr=class extends Zi{constructor(e,t,i){super(e,"histogramTooltip");const r=this.padding,s=this.size,o=[2,5,11,13,10,6,1],a=new n._Scene.LinearScale;a.domain=[0,o.length],a.range=[r,s-r];const l=new n._Scene.LinearScale;l.domain=[0,o.reduce((e,t)=>Math.max(e,t),0)],l.range=[s-r,r];const c=l.convert(0);this.bars=o.map((e,t)=>{const i=l.convert(e),r=a.convert(t),s=a.convert(t+1),o=new n._Scene.Rect;return o.x=r,o.y=i,o.width=s-r,o.height=c-i,o.strokeWidth=1,o.strokeOpacity=.75,o.crisp=!0,o}),this.updateColors(t,i),this.root.append(this.bars)}updateColors([e],[t]){this.bars.forEach(i=>{i.fill=e,i.stroke=t})}};Tr.chartType="histogram";var Mr=class extends Xi{constructor(e,t){super(e,t),this.stroke="gray",this.showRadiusAxisLine=!0,this.showAngleAxisLines=!0}addAxes(){const e=this.size,t=this.padding,i=(e-2*t)/2,r=this.showAngleAxisLines?[i,.8*i,.6*i,.4*i]:[],s=new n._Scene.Line;s.x1=e/2,s.y1=t,s.x2=e/2,s.y2=e-t-i-r[r.length-1],s.stroke=this.stroke,s.strokeOpacity=.5,s.fill=void 0,s.visible=this.showRadiusAxisLine;const o=t+i;this.gridLines=r.map((e,t)=>{const i=new n._Scene.Path;return i.path.arc(o,o,e,0,2*Math.PI),i.strokeWidth=1,i.stroke=this.stroke,i.strokeOpacity=0===t?.5:.2,i.fill=void 0,i});const a=this.root;a.append(s),this.gridLines.length>0&&a.append(this.gridLines)}};qe([r.o7C],Mr.prototype,"addAxes",1);var Rr=class extends Mr{constructor(e,t,i){super(e,"radialColumnTooltip"),this.data=[[6,8,10,2,6,5],[4,4,3,6,4,4],[5,4,2,9,8,9]],this.showRadiusAxisLine=!1;const{padding:r,size:s,data:o}=this,a=(s-2*r)/2,l=.4*a,c=new n._Scene.BandScale;c.domain=o[0].map((e,t)=>t),c.range=[0,2*Math.PI],c.paddingInner=0,c.paddingOuter=0;const u=.7*c.bandwidth,{processedData:h,max:d}=ir(o),p=new n._Scene.LinearScale;p.domain=[0,d],p.range=[l,a];const g=this.size/2;this.series=h.map((e,t)=>{const i=0===t?void 0:h[t-1],r=new n._Scene.Group({zIndex:1e6}),s=e.map((e,t)=>{const r=null==i?void 0:i[t],s=p.convert(e),o=p.convert(null!=r?r:0),h=c.convert(t),d=h+u,f=n._Scene.getRadialColumnWidth(h,d,a,.5,.5),m=new n._Scene.RadialColumnShape;return m.scalingCenterX=g,m.scalingCenterY=g,m.columnWidth=f,m.innerRadius=o,m.outerRadius=s,m.startAngle=h,m.endAngle=d,m.isBeveled=!0,m.axisInnerRadius=l,m.axisOuterRadius=a,m.stroke=void 0,m.strokeWidth=0,m});return r.append(s),r.translationX=g,r.translationY=g,r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};Rr.chartType="radialColumn";var _r=class extends Mr{constructor(e,t,i){super(e,"radialBarTooltip"),this.data=[[6,8,10],[4,4,3],[5,4,2]],this.showRadiusAxisLine=!1;const r=(this.size-this.padding)/2,s=.4*r,o=r+s,a=new n._Scene.BandScale;a.domain=this.data[0].map((e,t)=>t),a.range=[r,s],a.paddingInner=.5,a.paddingOuter=0;const l=a.bandwidth,{processedData:c,max:u}=ir(this.data),h=new n._Scene.LinearScale;h.domain=[0,Math.ceil(1.5*u)];const d=1.5*Math.PI,p=d+2*Math.PI;h.range=[d,p];const g=this.size/2;this.series=c.map((e,t)=>{const i=t<0?void 0:c[t-1],r=new n._Scene.Group({zIndex:1e6}),s=e.map((e,t)=>{var r;const s=null!=(r=null==i?void 0:i[t])?r:0,c=o-a.convert(t),u=c+l,d=h.convert(s),p=h.convert(e),f=new n._Scene.Sector;return f.centerX=g,f.centerY=g,f.innerRadius=c,f.outerRadius=u,f.startAngle=d,f.endAngle=p,f.stroke=void 0,f.strokeWidth=0,f});return r.append(s),r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};_r.chartType="radialBar";var Pr=class extends Mr{constructor(e,t,i){super(e,"radarLineTooltip"),this.markerSize=4,this.data=[[8,7,8,7,8,8,7,8],[6,8,5,10,6,7,4,6],[0,3,3,5,4,4,2,0]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,{paths:n,markers:s}=tr(this.root,this.data,this.size,r,0,this.markerSize);this.lines=n,this.markers=s,this.updateColors(t,i)}updateColors(e,t){this.lines.forEach((i,r)=>{const n=this.data[r].length;i.stroke=e[r];const s=r*n,o=s+n;this.markers.slice(s,o).forEach(i=>{i.stroke=t[r],i.fill=e[r]})})}};Pr.chartType="radarLine";var xr=class extends Mr{constructor(e,t,i){super(e,"radarAreaTooltip"),this.data=[[8,10,5,7,4,1,5,8],[1,1,2,7,7,8,10,1],[4,5,9,9,4,2,3,4]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,n=r-.3*this.size;this.areas=tr(this.root,this.data,this.size,r,n).paths,this.updateColors(t,i)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}};xr.chartType="radarArea";var Dr=class extends Mr{constructor(e,t,i){super(e,"nightingaleTooltip"),this.data=[[6,10,9,8,7,8],[4,6,5,4,5,5],[3,5,4,3,4,7]],this.showRadiusAxisLine=!1;const r=(this.size-2*this.padding)/2,s=new n._Scene.BandScale;s.domain=this.data[0].map((e,t)=>t),s.range=[-Math.PI,Math.PI],s.paddingInner=0,s.paddingOuter=0;const o=.7*s.bandwidth,{processedData:a,max:l}=ir(this.data),c=new n._Scene.LinearScale;c.domain=[0,l],c.range=[0,r];const u=this.size/2;this.series=a.map((e,t)=>{const i=t<0?void 0:a[t-1],r=new n._Scene.Group({zIndex:1e6}),l=e.map((e,t)=>{const r=null==i?void 0:i[t],a=c.convert(e),l=c.convert(null!=r?r:0),h=s.convert(t),d=h+o,p=new n._Scene.Sector;return p.centerX=u,p.centerY=u,p.innerRadius=l,p.outerRadius=a,p.startAngle=h,p.endAngle=d,p.stroke=void 0,p.strokeWidth=0,p});return r.append(l),r}),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};Dr.chartType="nightingale";var Ir=class extends Zi{constructor(e,t,i){super(e,"rangeBarTooltip"),this.bars=this.createRangeBar(this.root,[3,3.5,3],this.size,this.padding,"vertical"),this.updateColors(t,i)}updateColors(e,t){this.bars.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]})}createRangeBar(e,t,i,r,s){const o="horizontal"===s,a=2*r,l=new n._Scene.BandScale;l.domain=t.map((e,t)=>t),l.range=[r,i-r],l.paddingInner=.3,l.paddingOuter=.3;const c=new n._Scene.LinearScale;c.domain=[.7*t.reduce((e,t)=>Math.min(e,t),1/0),1.3*t.reduce((e,t)=>Math.max(e,t),0)],c.range=[a,i-a];const u=l.bandwidth,h=t.map((e,t)=>{const[i,r]=[.7*e,1.3*e],s=l.convert(t),a=c.convert(i),h=c.convert(r)-a,d=new n._Scene.Rect;return d.x=o?a:s,d.y=o?s:a,d.width=o?h:u,d.height=o?u:h,d.strokeWidth=0,d.crisp=!0,d});return e.append(h),h}};Ir.chartType="rangeBar";var Lr=class extends Zi{constructor(e,t,i){super(e,"rangeAreaTooltip");const r=[Nr({offset:1.5,length:4,pattern:{low:3,high:5,period:4}}),Nr({offset:1.5,length:4,pattern:{low:2.25,high:4.25,period:4}}),Nr({offset:3,length:4,pattern:{low:2.5,high:4.5,period:4}})].map(e=>e.map(([e,t])=>({x:e,low:t-.875,high:t+.875}))),{lines:n,areas:s}=this.createRangeArea(this.root,r,this.size,this.padding);this.lines=n,this.areas=s,this.updateColors(t,i)}updateColors(e,t){e=Fr(e,1,2),t=Fr(t,1,2),this.lines.forEach(([e,i],r)=>{e.fill=void 0,e.stroke=t[r],i.fill=void 0,i.stroke=t[r]}),this.areas.forEach((t,i)=>{t.fill=e[i]})}createRangeArea(e,t,i,r){const s=t.reduce((e,t)=>t.reduce((e,{x:t})=>Math.min(e,t),e),1/0),o=t.reduce((e,t)=>t.reduce((e,{x:t})=>Math.max(e,t),e),-1/0),a=t.reduce((e,t)=>t.reduce((e,{low:t})=>Math.min(e,t),e),1/0),l=t.reduce((e,t)=>t.reduce((e,{high:t})=>Math.max(e,t),e),-1/0),c=new n._Scene.LinearScale;c.domain=[s,o],c.range=[r,i-r];const u=2*r,h=new n._Scene.LinearScale;h.domain=[a,l],h.range=[i-u,u];const d=[],p=[];return t.map(e=>{const t=new n._Scene.Path,i=new n._Scene.Path,r=new n._Scene.Path;return d.push([t,i]),p.push(r),t.strokeWidth=0,i.strokeWidth=0,r.strokeWidth=0,r.fillOpacity=.8,t.path.clear(),i.path.clear(),r.path.clear(),e.map((e,n)=>{const{x:s,low:o,high:a}=e,l=c.convert(s),u=h.convert(o),d=h.convert(a),p=n>0?"lineTo":"moveTo";return t.path[p](l,d),i.path[p](l,u),r.path[p](l,d),[l,u]})}).forEach((e,t)=>{const i=e.length-1,r=p[t];for(let t=i;t>=0;t--){const[i,n]=e[t];r.path.lineTo(i,n)}}),e.append(p.concat(...d)),{lines:d,areas:p}}};function Nr(e){const{offset:t,length:i,pattern:r}=e,n=function(e,t,i){const{period:r}=i,n=e/r,s=[0,.5].map(e=>e-n).map(Or).sort((e,t)=>e-t);return Array.from({length:Math.floor(s.length*(r/t))},(e,t)=>s[t%s.length]+Math.floor(t/s.length)).map(e=>e*r).map(t=>o(t,e,i))}(t,i,r),s=i;return 0!==n.length&&0===n[0][0]||n.unshift(o(0,t,r)),n[n.length-1][0]!==s&&n.push(o(s,t,r)),n;function o(e,t,i){return[e,a(t+e,i)]}function a(e,t){const{low:i,high:r,period:n}=t,s=Or(e/n);return i+(r-i)*(s>.5?1-2*(s-.5):2*s)}}function Or(e){const t=e%1;return t<0?t+1:t}function Fr(e,t,i){const r=[...e],n=r[t];return r[t]=r[i],r[i]=n,r}Lr.chartType="rangeArea";var kr=class extends Zi{constructor(e,t,i,r,s){super(e,"boxPlotTooltip");const o=this.padding,a=this.size,l=[11,11.5,10.5],c=new n._Scene.LinearScale;c.domain=[.8*l.reduce((e,t)=>Math.min(e,t),1/0),1.2*l.reduce((e,t)=>Math.max(e,t),0)],c.range=[a-1.5*o,o];const u=new n._Scene.BandScale;u.domain=l.map((e,t)=>t),u.range=[o,a-o],u.paddingInner=.4,u.paddingOuter=.2;const h=Math.round(u.bandwidth),d=Math.round(u.bandwidth/2);this.boxPlotGroups=l.map((e,t)=>{let[i,r,s,o]=[.8*e,.9*e,1.1*e,1.2*e];const a=Math.round(c.convert(s)),l=Math.round(u.convert(t)),p=Math.round(l+h),g=Math.round(c.convert(r)),f=Math.round(c.convert(i)),m=Math.round(c.convert(e)),v=Math.round(c.convert(o)),C=l+d,y=new n._Scene.Group,w=new n._Scene.Rect,S=new n._Scene.Line,b=new n._Scene.Line,E=new n._Scene.Line,A=new n._Scene.Line,T=new n._Scene.Line;return w.x=l,w.y=a,w.width=h,w.height=g-a,w.strokeWidth=1,w.strokeOpacity=.75,w.crisp=!0,this.setLineProperties(S,l,p,m,m),this.setLineProperties(b,C,C,v,a),this.setLineProperties(E,C,C,f,g),this.setLineProperties(A,l,p,v,v),this.setLineProperties(T,l,p,f,f),y.append([w,S,b,E,A,T]),y}),this.updateColors(t,i,r,s),this.root.append(this.boxPlotGroups)}updateColors(e,t,i,r){var s;const o=null==i?void 0:i.properties.get(n._Theme.DEFAULT_BACKGROUND_COLOUR),a=null!=(s=Array.isArray(o)?o[0]:o)?s:"white";this.boxPlotGroups.forEach((i,s)=>{var o;null==(o=i.children)||o.forEach(i=>{const o=e[s%e.length];i.fill=r?o:n._Util.Color.interpolate(o,a)(.7),i.stroke=t[s%t.length]})})}setLineProperties(e,t,i,r,n){e.x1=t,e.x2=i,e.y1=r,e.y2=n,e.strokeOpacity=.75}};kr.chartType="boxPlot";var Gr=class extends Xi{constructor(e,t,i,r,s){super(e,"treemapTooltip");const{size:o,padding:a}=this,l=[[1,1],[3,2,1]],c=l.length%2==0?.3:.2,u=[a,o-a],h=l.length,d=h*(h+1)/2,p=c/(h-1),g=u[1]-u[0],f=g-c;let m=u[0];this.rects=l.reduce((e,t,i)=>{null!=e||(e=[]);const r=f*((h-i)/d),s=t.length,o=t.reduce((e,t)=>e+t,0),a=c/(s-1||1),l=s>1?g-c:g;let v=u[0];const C=t.map(e=>{const t=new n._Scene.Rect,i=l*e/o;return t.x=m,t.y=v,t.width=r,t.height=i,t.strokeWidth=.75,t.crisp=!0,v+=i+a,t});return m+=r+p,e.push(...C),e},[]),this.updateColors(t,i,r,s);const v=new n._Scene.Group;v.setClipRectInGroupCoordinateSpace(new n._Scene.BBox(a,a,o-a,o-a)),v.append(this.rects),this.root.append(v)}updateColors(e,t,i,r){var s;const{properties:o}=null!=i?i:{},a=null==o?void 0:o.get(n._Theme.DEFAULT_BACKGROUND_COLOUR),l=null!=(s=Array.isArray(a)?a[0]:a)?s:"white";this.rects.forEach((i,n)=>{i.fill=e[n%t.length],i.stroke=r?t[n%t.length]:l})}};Gr.chartType="treemap";var Vr=class extends Mr{constructor(e,t,i){super(e,"sunburstTooltip"),this.data=[[[],[]],[[],[]],[[],[]]],this.angleOffset=-Math.PI/2,this.innerRadiusRatio=0,this.showRadiusAxisLine=!1,this.showAngleAxisLines=!1;const{data:r,size:s,padding:o,angleOffset:a,innerRadiusRatio:l}=this,c=(s-2*o)/2,u=[a+0,a+2*Math.PI],h=Math.abs(u[1]-u[0]),d=[c*l,c],p=Math.abs(d[1]-d[0]);let g=0;const f=(e,t)=>{e.forEach(e=>{const i=t+1;g=Math.max(g,i),f(e,i)})};f(r,0);const m=p/g,v=this.size/2,C=u[0];this.series=[];const y=(e,t,i,r,s)=>{if(!Array.isArray(e))return;const o=t+1;let a=i;e.forEach((e,i,l)=>{let c=s;c||(c=new n._Scene.Group,this.series.push(c));const u=d[0]+t*m,h=d[0]+o*m,p=1/l.length,g=a,f=g+r*p,C=new n._Scene.Sector;C.centerX=v,C.centerY=v,C.innerRadius=u,C.outerRadius=h,C.startAngle=g,C.endAngle=f,C.stroke=void 0,C.strokeWidth=0,C.inset=.75,a=f,c.append(C),y(e,o,g,Math.abs(f-g),c)})};y(r,0,C,h),this.root.append(this.series),this.updateColors(t,i)}updateColors(e,t){this.series.forEach((i,r)=>{var n;null==(n=i.children)||n.forEach(i=>{i.fill=e[r%e.length],i.stroke=t[r%t.length]})})}};Vr.chartType="sunburst";var Hr=class extends Xi{constructor(e,t,i,r,s){var o,a;super(e,"heatmapTooltip");const{size:l,padding:c}=this,u=Array.from({length:3},(e,t)=>Array.from({length:3},(e,t)=>t)),h=u.map((e,t)=>t),d=new n._Scene.BandScale;d.domain=h,d.range=[c,l-c],d.paddingInner=.01,d.paddingOuter=.1;const p=new n._Scene.BandScale;p.domain=h,p.range=[c,l-c],p.paddingInner=.01,p.paddingOuter=.1;const g=null!=(o=d.bandwidth)?o:0,f=null!=(a=p.bandwidth)?a:0;this.rects=u.reduce((e,t,i)=>{null!=e||(e=[]);const r=t.map((e,t)=>{const r=new n._Scene.Rect;return r.x=d.convert(i),r.y=p.convert(t),r.width=g,r.height=f,r.strokeWidth=0,r.crisp=!0,r});return e.push(...r),e},[]),this.updateColors(t,i,r,s);const m=new n._Scene.Group;m.setClipRectInGroupCoordinateSpace(new n._Scene.BBox(c,c,l-c,l-c)),m.append(this.rects),this.root.append(m)}updateColors(e,t,i,r){var s;const{properties:o}=null!=i?i:{},a=null==o?void 0:o.get(n._Theme.DEFAULT_DIVERGING_SERIES_COLOUR_RANGE),l=null==o?void 0:o.get(n._Theme.DEFAULT_BACKGROUND_COLOUR),c=null!=(s=Array.isArray(l)?l[0]:l)?s:"white",u=r?[e[0],e[1]]:a,h=r?t[0]:c;this.rects.forEach((e,t)=>{e.fill=n._Util.Color.interpolate(u[0],u[1])(.2*t),e.stroke=h})}};Hr.chartType="heatmap";var Br=class extends Zi{constructor(e,t,i,r,n){super(e,"waterfallTooltip"),this.data=[4,3,-3,6,-3],this.bars=this.createWaterfall(this.root,this.data,this.size,this.padding,"vertical").bars,this.updateColors(t,i,r,n)}updateColors(e,t,i,r){var s,o;const{data:a}=this,{properties:l}=null!=i?i:{},c={fill:e[0],stroke:t[0]},u={fill:e[1],stroke:t[1]},h=r?c:null!=(s=null==l?void 0:l.get(n._Theme.DEFAULT_WATERFALL_SERIES_POSITIVE_COLOURS))?s:c,d=r?u:null!=(o=null==l?void 0:l.get(n._Theme.DEFAULT_WATERFALL_SERIES_NEGATIVE_COLOURS))?o:u;this.bars.forEach((e,t)=>{const i=a[t]>=0;e.fill=i?h.fill:d.fill,e.stroke=i?h.stroke:d.stroke})}createWaterfall(e,t,i,r,s){const o=2*r,{processedData:a,min:l,max:c}=ir(t.map(e=>[e])),u=a.reduce((e,t)=>e.concat(t),[]),h=new n._Scene.LinearScale;h.domain=[Math.min(l,0),c],h.range=[i-o,o];const d=new n._Scene.BandScale;d.domain=t.map((e,t)=>t),d.range=[r,i-r],d.paddingInner=.2,d.paddingOuter=.3;const p=d.bandwidth,g=new n._Scene.Path;g.stroke="#575757",g.strokeWidth=0;const f=Math.floor(g.strokeWidth)%2/2,m=g.path;m.clear();const v="horizontal"===s,C=u.map((e,i)=>{const r=i>0?u[i-1]:0,s=t[i]>0,o=Math.round(h.convert(e)),a=Math.round(h.convert(r)),l=(s?o:a)-f,c=(s?a:o)+f,g=Math.abs(c-l),C=d.convert(i),y=new n._Scene.Rect;y.x=v?l:C,y.y=v?C:l,y.width=v?g:p,y.height=v?p:g,y.strokeWidth=0,y.crisp=!0;const w=o+f,S=a+f;if(i>0){const e=v?S:y.x,t=v?y.y:S;m.lineTo(e,t)}const b=v?w:y.x,E=v?y.y:w;return m.moveTo(b,E),y});return e.append([g,...C]),{bars:C}}};Br.chartType="waterfall";var zr=class extends Zi{constructor(e,t,i){super(e,"columnLineComboTooltip"),this.columnData=[3,4],this.lineData=[[5,4,6,5,4]];const{root:r,columnData:n,lineData:s,size:o,padding:a}=this;this.columns=Ji({stacked:!1,root:r,data:n,size:o,padding:a,xScaleDomain:[0,1],yScaleDomain:[0,4],xScalePadding:.5}),r.append(this.columns),this.lines=er(r,s,o,a),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.lines.forEach((t,i)=>{t.stroke=e[i+2]})}};zr.chartType="columnLineCombo";var Ur=class extends Zi{constructor(e,t,i){super(e,"areaColumnComboTooltip"),this.columnData=[3,4.5],this.areaData=[[5,4,6,5,4]];const{root:r,columnData:s,areaData:o,size:a,padding:l}=this;this.columns=Ji({stacked:!1,root:r,data:s,size:a,padding:l,xScaleDomain:[0,1],yScaleDomain:[0,6],xScalePadding:.5});const c=new n._Scene.BandScale;c.range=[l,a-l],c.domain=[0,1,2,3,4],c.paddingInner=1,c.paddingOuter=0;const u=new n._Scene.LinearScale;u.range=[a-l,l],u.domain=[0,6];const h=[],d=u.convert(0),p=c.convert(0);o.forEach((e,t)=>{const i=h[t]||(h[t]=[]);e.forEach((e,t)=>{const r=e,n=t,s=c.convert(n),o=u.convert(r);i[t]={x:s,y:o}});const r=c.convert(e.length-1);h[t].push({x:r,y:d},{x:p,y:d})}),this.areas=h.map(e=>{const t=new n._Scene.Path;t.strokeWidth=0,t.fillOpacity=.8;const i=t.path;return e.forEach((e,t)=>i[t>0?"lineTo":"moveTo"](e.x,e.y)),t}),r.append(this.areas),r.append([].concat.apply([],this.columns)),this.updateColors(t,i)}updateColors(e,t){this.areas.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.columns.forEach((i,r)=>{i.fill=e[r+1],i.stroke=t[r+1]})}};Ur.chartType="areaColumnCombo";var Wr=class extends Xi{constructor(e,t,i){super(e,"customComboTooltip"),this.columnData=[3,4],this.lineData=[[5,4,6,5,4]];const{root:r,columnData:s,lineData:o,size:a,padding:l}=this;this.columns=Ji({stacked:!1,root:r,data:s,size:a,padding:l,xScaleDomain:[0,1],yScaleDomain:[0,4],xScalePadding:.5}),r.append(this.columns),this.lines=er(r,o,a,l);const c="grey",u=new n._Scene.Line;u.x1=l,u.y1=l,u.x2=l,u.y2=a-l+3,u.stroke=c;const h=new n._Scene.Line;h.x1=l-3+1,h.y1=a-l,h.x2=a-l+1,h.y2=a-l,h.stroke=c;const d=new n._Scene.Path;this.buildPenIconPath(d),d.fill="whitesmoke",d.stroke="darkslategrey",d.strokeWidth=1,r.append([h,u,d]),this.updateColors(t,i)}updateColors(e,t){this.columns.forEach((i,r)=>{i.fill=e[r],i.stroke=t[r]}),this.lines.forEach((t,i)=>{t.stroke=e[i+2]})}buildPenIconPath(e){const{path:t}=e;t.moveTo(25.76,43.46),t.lineTo(31.27,48.53),t.moveTo(49.86,22),t.lineTo(49.86,22),t.cubicCurveTo(49.01994659053345,21.317514933510974,47.89593834348529,21.09645997825817,46.86,21.41),t.lineTo(46.86,21.41),t.cubicCurveTo(45.55460035985361,21.77260167850787,44.38777081121966,22.517979360321792,43.51,23.55),t.lineTo(25.51,43.8),t.lineTo(25.43,43.89),t.lineTo(23.01,51.89),t.lineTo(22.83,52.46),t.lineTo(31.02,48.86),t.lineTo(49.02,28.52),t.lineTo(49.02,28.52),t.cubicCurveTo(49.940716461596224,27.521914221246085,50.54302631059587,26.2720342455763,50.75,24.93),t.lineTo(50.75,24.93),t.cubicCurveTo(50.95363374988308,23.866379846512814,50.62080640232334,22.77066734274871,49.86,22),t.closePath(),t.moveTo(41.76,25.5),t.lineTo(47.34,30.5),t.moveTo(40.74,26.65),t.lineTo(46.25,31.71)}};Wr.chartType="customCombo";var jr={columnGroup:{column:{range:!0,pivot:!0,enterprise:!1,icon:rr},stackedColumn:{range:!0,pivot:!0,enterprise:!1,icon:sr},normalizedColumn:{range:!0,pivot:!0,enterprise:!1,icon:ar}},barGroup:{bar:{range:!0,pivot:!0,enterprise:!1,icon:lr},stackedBar:{range:!0,pivot:!0,enterprise:!1,icon:ur},normalizedBar:{range:!0,pivot:!0,enterprise:!1,icon:dr}},pieGroup:{pie:{range:!0,pivot:!0,enterprise:!1,icon:fr},donut:{range:!0,pivot:!0,enterprise:!1,icon:gr},doughnut:{range:!0,pivot:!0,enterprise:!1,icon:gr}},lineGroup:{line:{range:!0,pivot:!0,enterprise:!1,icon:mr}},scatterGroup:{scatter:{range:!0,pivot:!0,enterprise:!1,icon:vr},bubble:{range:!0,pivot:!0,enterprise:!1,icon:Cr}},areaGroup:{area:{range:!0,pivot:!0,enterprise:!1,icon:wr},stackedArea:{range:!0,pivot:!0,enterprise:!1,icon:br},normalizedArea:{range:!0,pivot:!0,enterprise:!1,icon:Ar}},polarGroup:{radarLine:{range:!0,pivot:!1,enterprise:!0,icon:Pr},radarArea:{range:!0,pivot:!1,enterprise:!0,icon:xr},nightingale:{range:!0,pivot:!1,enterprise:!0,icon:Dr},radialColumn:{range:!0,pivot:!1,enterprise:!0,icon:Rr},radialBar:{range:!0,pivot:!1,enterprise:!0,icon:_r}},statisticalGroup:{boxPlot:{range:!0,pivot:!1,enterprise:!0,icon:kr},histogram:{range:!0,pivot:!1,enterprise:!1,icon:Tr},rangeBar:{range:!0,pivot:!1,enterprise:!0,icon:Ir},rangeArea:{range:!0,pivot:!1,enterprise:!0,icon:Lr}},hierarchicalGroup:{treemap:{range:!0,pivot:!0,enterprise:!0,icon:Gr},sunburst:{range:!0,pivot:!0,enterprise:!0,icon:Vr}},specializedGroup:{heatmap:{range:!0,pivot:!1,enterprise:!0,icon:Hr},waterfall:{range:!0,pivot:!1,enterprise:!0,icon:Br}},combinationGroup:{columnLineCombo:{range:!0,pivot:!0,enterprise:!1,icon:zr},areaColumnCombo:{range:!0,pivot:!0,enterprise:!1,icon:Ur},customCombo:{range:!0,pivot:!0,enterprise:!1,icon:Wr}}},Kr={columnGroup:["column","stackedColumn","normalizedColumn"],barGroup:["bar","stackedBar","normalizedBar"],pieGroup:["pie","donut"],lineGroup:["line"],scatterGroup:["scatter","bubble"],areaGroup:["area","stackedArea","normalizedArea"],polarGroup:["radarLine","radarArea","nightingale","radialColumn","radialBar"],statisticalGroup:["boxPlot","histogram","rangeBar","rangeArea"],hierarchicalGroup:["treemap","sunburst"],specializedGroup:["heatmap","waterfall"],combinationGroup:["columnLineCombo","areaColumnCombo","customCombo"]},$r=class e extends r.uAl{constructor(t,i,r,n,s,o=Kr){super(e.TEMPLATE),this.wrappers={},this.chartController=t,this.fills=i,this.strokes=r,this.themeTemplateParameters=n,this.isCustomTheme=s,this.chartGroups=je({},o)}init(){!this.chartController.customComboExists()&&this.chartGroups.combinationGroup&&(this.chartGroups.combinationGroup=this.chartGroups.combinationGroup.filter(e=>"customCombo"!==e));const e=this.getGui(),t=this.chartController.isEnterprise(),i=this.chartController.isPivotChart(),n=!i,s=Object.keys(this.chartGroups).map(e=>{var s;const o=e in jr?jr[e]:void 0;if(!o)return r._.warnOnce(`invalid chartGroupsDef config '${e}'`),null;const a=(null!=(s=this.chartGroups[e])?s:[]).map(s=>{const a=s in o?o[s]:void 0;return a?!t&&a.enterprise?null:n&&a.range||i&&a.pivot?a:null:(r._.warnOnce(`invalid chartGroupsDef config '${e}.${s}'`),null)}).filter(e=>null!=e);return 0===a.length?null:{label:this.chartTranslationService.translate(e),items:a}}).filter(e=>null!=e);for(const{label:t,items:i}of s){const n=this.createBean(new r.Pk_({title:t,suppressEnabledCheckbox:!0,enabled:!0,suppressOpenCloseIcons:!0,cssIdentifier:"charts-settings",direction:"horizontal"}));for(const e of i){const t=e.icon,i=document.createElement("div");i.classList.add("ag-chart-mini-thumbnail");const r=t.chartType;this.addManagedListener(i,"click",()=>{this.chartController.setChartType(r),this.updateSelectedMiniChart()}),this.wrappers[r]=i,this.createBean(new t(i,this.fills,this.strokes,this.themeTemplateParameters,this.isCustomTheme)),n.addItem(i)}e.appendChild(n.getGui())}this.updateSelectedMiniChart()}updateSelectedMiniChart(){const e=this.chartController.getChartType();for(const t in this.wrappers){const i=t===e;this.wrappers[t].classList.toggle("ag-selected",i)}}};$r.TEMPLATE='<div class="ag-chart-settings-mini-wrapper"></div>',qe([(0,r.dsm)("chartTranslationService")],$r.prototype,"chartTranslationService",2),qe([r.o7C],$r.prototype,"init",1);var qr=$r,Yr=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.chartController=t,this.miniChartsContainers=[],this.cardItems=[],this.activePaletteIndex=0,this.palettes=[],this.themes=[]}postConstruct(){this.resetPalettes(),this.ePrevBtn.insertAdjacentElement("afterbegin",r._.createIconNoSpan("previous",this.gos)),this.eNextBtn.insertAdjacentElement("afterbegin",r._.createIconNoSpan("next",this.gos)),this.addManagedListener(this.ePrevBtn,"click",()=>this.setActivePalette(this.getPrev(),"left")),this.addManagedListener(this.eNextBtn,"click",()=>this.setActivePalette(this.getNext(),"right")),this.addManagedListener(this.chartController,Gt.EVENT_CHART_TYPE_CHANGED,()=>this.resetPalettes(!0)),this.addManagedListener(this.chartController,Gt.EVENT_CHART_API_UPDATE,()=>this.resetPalettes(!0)),this.scrollSelectedIntoView()}scrollSelectedIntoView(){setTimeout(()=>{const e=this.miniChartsContainers.find(e=>!e.getGui().classList.contains("ag-hidden")).getGui().querySelector(".ag-selected");if(e){const t=e.offsetParent;t&&this.eMiniChartsContainer.scrollTo(0,t.offsetTop)}},250)}resetPalettes(e){var t,i;const n=this.chartController.getPalettes(),s=this.chartController.getThemeTemplateParameters(),o=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.settingsPanel)?void 0:i.chartGroupsDef;if(r._.shallowCompare(n,this.palettes)&&!e||this.isAnimating)return;this.palettes=n,this.themes=this.chartController.getThemeNames(),this.activePaletteIndex=this.themes.findIndex(e=>e===this.chartController.getChartThemeName()),this.cardItems=[],r._.clearElement(this.eCardSelector),this.destroyMiniCharts();const{themes:a}=this;this.palettes.forEach((e,t)=>{const i=this.activePaletteIndex===t,{fills:r,strokes:n}=e,l=!At(a[t]),c=this.createBean(new qr(this.chartController,r,n,s[t],l,o));this.miniChartsContainers.push(c),this.eMiniChartsContainer.appendChild(c.getGui()),this.addCardLink(t),i?c.updateSelectedMiniChart():c.setDisplayed(!1)}),r._.setDisplayed(this.eNavBar,this.palettes.length>1),r._.radioCssClass(this.cardItems[this.activePaletteIndex],"ag-selected","ag-not-selected")}addCardLink(e){const t=document.createElement("div");t.classList.add("ag-chart-settings-card-item"),this.addManagedListener(t,"click",()=>{this.setActivePalette(e,e<this.activePaletteIndex?"left":"right")}),this.eCardSelector.appendChild(t),this.cardItems.push(t)}getPrev(){let e=this.activePaletteIndex-1;return e<0&&(e=this.palettes.length-1),e}getNext(){let e=this.activePaletteIndex+1;return e>=this.palettes.length&&(e=0),e}setActivePalette(e,t){if(this.isAnimating||this.activePaletteIndex===e)return;r._.radioCssClass(this.cardItems[e],"ag-selected","ag-not-selected");const i=this.miniChartsContainers[this.activePaletteIndex],n=i.getGui(),s=this.miniChartsContainers[e],o=s.getGui();i.updateSelectedMiniChart(),s.updateSelectedMiniChart();const a="left"===t?-1:1,l=o.style.left=r._.getAbsoluteWidth(this.getGui())*a+"px";this.activePaletteIndex=e,this.isAnimating=!0;const c="ag-animating";s.setDisplayed(!0),i.addCssClass(c),s.addCssClass(c),this.chartController.setChartThemeName(this.themes[e]),window.setTimeout(()=>{n.style.left=-parseFloat(l)+"px",o.style.left="0px"},0),window.setTimeout(()=>{this.isAnimating=!1,i.removeCssClass(c),s.removeCssClass(c),i.setDisplayed(!1)},300)}destroyMiniCharts(){r._.clearElement(this.eMiniChartsContainer),this.miniChartsContainers=this.destroyBeans(this.miniChartsContainers)}destroy(){this.destroyMiniCharts(),super.destroy()}};Yr.TEMPLATE='<div class="ag-chart-settings-wrapper">\n            <div ref="eMiniChartsContainer" class="ag-chart-settings-mini-charts-container ag-scrollable-container"></div>\n            <div ref="eNavBar" class="ag-chart-settings-nav-bar">\n                <div ref="ePrevBtn" class="ag-chart-settings-prev">\n                    <button type="button" class="ag-button ag-chart-settings-prev-button"></button>\n                </div>\n                <div ref="eCardSelector" class="ag-chart-settings-card-selector"></div>\n                <div ref="eNextBtn" class="ag-chart-settings-next">\n                    <button type="button" class="ag-button ag-chart-settings-next-button"></button>\n                </div>\n            </div>\n        </div>',qe([(0,r.PIB)("eMiniChartsContainer")],Yr.prototype,"eMiniChartsContainer",2),qe([(0,r.PIB)("eNavBar")],Yr.prototype,"eNavBar",2),qe([(0,r.PIB)("eCardSelector")],Yr.prototype,"eCardSelector",2),qe([(0,r.PIB)("ePrevBtn")],Yr.prototype,"ePrevBtn",2),qe([(0,r.PIB)("eNextBtn")],Yr.prototype,"eNextBtn",2),qe([r.o7C],Yr.prototype,"postConstruct",1);var Qr=Yr,Xr=class e extends r.uAl{constructor(e,t){super(),this.panels=e,this.chartMenuContext=t,this.tabs=[]}init(){this.panels.forEach(e=>{const t=e.replace("chart","").toLowerCase(),i=this.createPanel(t),r=this.createTab(e,t,i);this.tabs.push(r),this.addDestroyFunc(()=>this.destroyBean(i))}),this.tabbedLayout=new r.LfH({items:this.tabs,cssClass:"ag-chart-tabbed-menu",keepScrollPosition:!0,suppressFocusBodyOnOpen:!0,suppressTrapFocus:!0,enableCloseButton:!this.chartMenuService.isLegacyFormat(),closeButtonAriaLabel:this.chartTranslationService.translate("ariaChartMenuClose"),onCloseClicked:()=>{var t;null==(t=this.eventSource)||t.focus({preventScroll:!0}),this.dispatchEvent({type:e.EVENT_CLOSED})}}),this.getContext().createBean(this.tabbedLayout)}createTab(e,t,i){const n=document.createElement("div");n.classList.add("ag-chart-tab",`ag-chart-${t}`),this.getContext().createBean(i),n.appendChild(i.getGui());const s=document.createElement("div"),o=this.chartTranslationService.translate(t);return s.innerText=o,{title:s,titleLabel:o,bodyPromise:r.oY$.resolve(n),getScrollableContainer:()=>n.querySelector(".ag-scrollable-container")||n,name:e}}showTab(e){const t=this.tabs[e];this.tabbedLayout.showItem(t)}getGui(){return this.tabbedLayout&&this.tabbedLayout.getGui()}showMenu(e,t){var i;this.eventSource=e,t||null==(i=this.tabbedLayout)||i.focusHeader(!0)}destroy(){this.parentComponent&&this.parentComponent.isAlive()&&this.destroyBean(this.parentComponent),super.destroy()}createPanel(t){const{chartController:i,chartOptionsService:r}=this.chartMenuContext;switch(t){case e.TAB_DATA:return new ei(i,r);case e.TAB_FORMAT:return new Qi(this.chartMenuContext);default:return new Qr(i)}}};Xr.EVENT_CLOSED="closed",Xr.TAB_DATA="data",Xr.TAB_FORMAT="format",qe([(0,r.dsm)("chartTranslationService")],Xr.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],Xr.prototype,"chartMenuService",2),qe([r.o7C],Xr.prototype,"init",1);var Zr=Xr,Jr=class extends r.uAl{constructor(){super('<div class="ag-chart-menu" ref="eMenu"></div>'),this.buttonListenersDestroyFuncs=[]}updateParams(e){const{buttons:t}=e;this.createButtons(t)}createButtons(e){this.buttonListenersDestroyFuncs.forEach(e=>null==e?void 0:e()),this.buttonListenersDestroyFuncs=[];const t=this.eMenu;r._.clearElement(t),e.forEach(e=>{const{buttonName:i,iconName:r,callback:n}=e,s=this.createButton(r),o=this.chartTranslationService.translate(i+"ToolbarTooltip");o&&s instanceof HTMLElement&&(s.title=o),this.buttonListenersDestroyFuncs.push(this.addManagedListener(s,"click",e=>n(e.target))),t.appendChild(s)})}createButton(e){let t=r._.createIconNoSpan(e,this.gos,void 0,!0);return t.classList.add("ag-chart-menu-icon"),this.chartMenuService.isLegacyFormat()||(t=this.wrapButton(t)),t}wrapButton(e){const t=this.gos.getDocument().createElement("button");return t.appendChild(e),t.classList.add("ag-chart-menu-toolbar-button"),t}destroy(){this.buttonListenersDestroyFuncs=[],super.destroy()}};qe([(0,r.dsm)("chartTranslationService")],Jr.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],Jr.prototype,"chartMenuService",2),qe([(0,r.PIB)("eMenu")],Jr.prototype,"eMenu",2);var en=class e extends r.uAl{constructor(t,i,r){super(e.TEMPLATE),this.eChartContainer=t,this.eMenuPanelContainer=i,this.chartMenuContext=r,this.buttons={chartSettings:{iconName:"menu",callback:()=>this.showMenu({panel:this.defaultPanel})},chartData:{iconName:"menu",callback:()=>this.showMenu({panel:"chartData"})},chartFormat:{iconName:"menu",callback:()=>this.showMenu({panel:"chartFormat"})},chartLink:{iconName:"linked",callback:()=>this.chartMenuService.toggleLinked(this.chartMenuContext)},chartUnlink:{iconName:"unlinked",callback:()=>this.chartMenuService.toggleLinked(this.chartMenuContext)},chartDownload:{iconName:"save",callback:()=>this.chartMenuService.downloadChart(this.chartMenuContext)},chartMenu:{iconName:"menuAlt",callback:e=>this.showMenuList(e)}},this.panels=[],this.menuVisible=!1,this.chartController=r.chartController}postConstruct(){this.legacyFormat=this.chartMenuService.isLegacyFormat(),this.chartToolbar=this.createManagedBean(new Jr),this.getGui().appendChild(this.chartToolbar.getGui()),this.legacyFormat&&this.createLegacyToggleButton(),this.refreshToolbarAndPanels(),this.addManagedListener(this.eventService,r.sVA.EVENT_CHART_CREATED,e=>{var t;e.chartId===this.chartController.getChartId()&&Boolean(null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.defaultToolPanel)&&this.showMenu({panel:this.defaultPanel,animate:!1,suppressFocus:!0})}),this.addManagedListener(this.chartController,Gt.EVENT_CHART_LINKED_CHANGED,this.refreshToolbarAndPanels.bind(this)),this.refreshMenuClasses(),this.legacyFormat&&!this.gos.get("suppressChartToolPanelsButton")&&this.panels.length>0&&(this.getGui().classList.add("ag-chart-tool-panel-button-enable"),this.eHideButton&&this.addManagedListener(this.eHideButton,"click",this.toggleMenu.bind(this))),this.legacyFormat||this.getGui().classList.add("ag-chart-menu-wrapper"),this.addManagedListener(this.chartController,Gt.EVENT_CHART_API_UPDATE,this.refreshToolbarAndPanels.bind(this))}isVisible(){return this.menuVisible}getExtraPaddingDirections(){const e=[];return["chartMenu","chartLink","chartUnlink","chartDownload"].some(e=>this.chartToolbarOptions.includes(e))&&e.push("top"),["chartSettings","chartData","chartFormat"].some(e=>this.chartToolbarOptions.includes(e))&&e.push(this.gos.get("enableRtl")?"left":"right"),e}createLegacyToggleButton(){const e=this.gos.getDocument();this.eHideButton=e.createElement("button"),this.eHideButton.classList.add("ag-button","ag-chart-menu-close"),this.eHideButtonIcon=e.createElement("span"),this.eHideButtonIcon.classList.add("ag-icon","ag-icon-contracted"),this.eHideButton.appendChild(this.eHideButtonIcon),this.getGui().appendChild(this.eHideButton)}refreshToolbarAndPanels(){this.initToolbarOptionsAndPanels(),this.updateToolbar()}initToolbarOptionsAndPanels(){const{panels:e,defaultPanel:t,chartToolbarOptions:i}=this.chartMenuService.getToolbarOptionsAndPanels(this.chartController);this.panels=e,this.defaultPanel=t,this.chartToolbarOptions=i}updateToolbar(){const e=this.chartToolbarOptions.map(e=>{const{iconName:t,callback:i}=this.buttons[e];return{buttonName:e,iconName:t,callback:i}});this.chartToolbar.updateParams({buttons:e})}createMenuPanel(e){const t=this.environment.chartMenuPanelWidth(),i=this.menuPanel=this.createBean(new r.LT8({minWidth:t,width:t,height:"100%",closable:!0,hideTitleBar:!0,cssIdentifier:"chart-menu"}));return i.setParentComponent(this),this.eMenuPanelContainer.appendChild(i.getGui()),this.tabbedMenu=this.createBean(new Zr(this.panels,this.chartMenuContext)),this.addManagedListener(this.tabbedMenu,Zr.EVENT_CLOSED,()=>{this.hideMenu(!1)}),this.addManagedListener(i,r.uAl.EVENT_DESTROYED,()=>this.destroyBean(this.tabbedMenu)),new r.oY$(t=>{window.setTimeout(()=>{i.setBodyComponent(this.tabbedMenu),this.tabbedMenu.showTab(e),t(i),this.legacyFormat&&this.addManagedListener(this.eChartContainer,"click",e=>{this.getGui().contains(e.target)||this.menuVisible&&this.hideMenu()})},100)})}showContainer(e,t){this.menuPanel&&(this.menuVisible=!0,this.showParent(this.menuPanel.getWidth()),this.refreshMenuClasses(),this.tabbedMenu.showMenu(e,t))}toggleMenu(){this.menuVisible?this.hideMenu(this.legacyFormat):this.showMenu({animate:this.legacyFormat})}showMenu(e){const{panel:t,animate:i=!0,eventSource:r,suppressFocus:n}=e;if(i||this.eMenuPanelContainer.classList.add("ag-no-transition"),this.menuPanel&&!t)this.showContainer(r,n);else{const e=t||this.defaultPanel;let i=this.panels.indexOf(e);i<0&&(console.warn(`AG Grid: '${t}' is not a valid Chart Tool Panel name`),i=this.panels.indexOf(this.defaultPanel)),this.menuPanel?(this.tabbedMenu.showTab(i),this.showContainer(r,n)):this.createMenuPanel(i).then(()=>this.showContainer(r,n))}i||setTimeout(()=>{this.isAlive()&&this.eMenuPanelContainer.classList.remove("ag-no-transition")},500)}hideMenu(e=!0){e||this.eMenuPanelContainer.classList.add("ag-no-transition"),this.hideParent(),window.setTimeout(()=>{this.menuVisible=!1,this.refreshMenuClasses(),e||this.eMenuPanelContainer.classList.remove("ag-no-transition")},500)}refreshMenuClasses(){this.eChartContainer.classList.toggle("ag-chart-menu-visible",this.menuVisible),this.eChartContainer.classList.toggle("ag-chart-menu-hidden",!this.menuVisible),this.legacyFormat&&!this.gos.get("suppressChartToolPanelsButton")&&(this.eHideButtonIcon.classList.toggle("ag-icon-contracted",this.menuVisible),this.eHideButtonIcon.classList.toggle("ag-icon-expanded",!this.menuVisible))}showParent(e){this.eMenuPanelContainer.style.minWidth=`${e}px`}hideParent(){this.eMenuPanelContainer.style.minWidth="0"}showMenuList(e){this.chartMenuListFactory.showMenuList({eventSource:e,showMenu:()=>this.showMenu({animate:!1,eventSource:e}),chartMenuContext:this.chartMenuContext})}destroy(){super.destroy(),this.menuPanel&&this.menuPanel.isAlive()&&this.destroyBean(this.menuPanel),this.tabbedMenu&&this.tabbedMenu.isAlive()&&this.destroyBean(this.tabbedMenu)}};en.TEMPLATE="<div></div>",qe([(0,r.dsm)("chartMenuService")],en.prototype,"chartMenuService",2),qe([(0,r.dsm)("chartMenuListFactory")],en.prototype,"chartMenuListFactory",2),qe([r.o7C],en.prototype,"postConstruct",1);var tn=en,rn=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.chartMenu=t,this.destroyableChartListeners=[],this.editing=!1}init(){this.addManagedListener(this.getGui(),"keydown",e=>{this.editing&&"Enter"===e.key&&!e.shiftKey&&(this.handleEndEditing(),e.preventDefault())}),this.addManagedListener(this.getGui(),"input",()=>{this.editing&&this.updateHeight()}),this.addManagedListener(this.getGui(),"blur",()=>this.endEditing())}refreshTitle(e){this.chartController=e.chartController,this.chartOptionsService=e.chartOptionsService,this.chartMenuUtils=e.chartMenuParamsFactory.getChartOptions();for(const e of this.destroyableChartListeners)e();this.destroyableChartListeners=[];const t=this.chartController.getChartProxy().getChart(),i=t.canvasElement,r=this.addManagedListener(i,"dblclick",e=>{const{title:r}=t;if(r&&r.node.containsPoint(e.offsetX,e.offsetY)){const e=r.node.computeBBox(),t=r.node.inverseTransformPoint(e.x,e.y);this.startEditing(je(je({},e),t),i.width)}});let n=!1;const s=this.addManagedListener(i,"mousemove",e=>{const{title:r}=t,s=!!(r&&r.enabled&&r.node.containsPoint(e.offsetX,e.offsetY));n!==s&&(i.style.cursor=s?"pointer":""),n=s});this.destroyableChartListeners=[r,s]}startEditing(e,t){if(this.chartMenuService.isLegacyFormat()&&this.chartMenu&&this.chartMenu.isVisible())return;if(this.editing)return;this.editing=!0;const i=Math.max(Math.min(e.width+20,t),300),r=this.getGui();r.classList.add("currently-editing");const n=r.style;n.fontFamily=this.chartMenuUtils.getValue("title.fontFamily"),n.fontWeight=this.chartMenuUtils.getValue("title.fontWeight"),n.fontStyle=this.chartMenuUtils.getValue("title.fontStyle"),n.fontSize=this.chartMenuUtils.getValue("title.fontSize")+"px",n.color=this.chartMenuUtils.getValue("title.color");const s=this.chartMenuUtils.getValue("title.text"),o=s===this.chartTranslationService.translate("titlePlaceholder");r.value=o?"":s;const a=s.split(/\r?\n/g).length;n.left=Math.round(e.x+e.width/2-i/2-1)+"px",n.top=Math.round(e.y+e.height/2-a*this.getLineHeight()/2-2)+"px",n.width=Math.round(i)+"px",n.lineHeight=this.getLineHeight()+"px",this.updateHeight(),r.focus()}updateHeight(){const e=this.getGui(),t=this.chartMenuUtils.getValue("title.text").split(/\r?\n/g).length,i=e.value.split(/\r?\n/g).length;e.style.height=Math.round(Math.max(t,i)*this.getLineHeight())+4+"px"}getLineHeight(){const e=this.chartMenuUtils.getValue("title.lineHeight");return e?parseInt(e):Math.round(1.2*parseInt(this.chartMenuUtils.getValue("title.fontSize")))}handleEndEditing(){const e=this.chartMenuUtils.getValue("title.color");this.chartMenuUtils.setValue("title.color","rgba(0, 0, 0, 0)"),this.chartOptionsService.awaitChartOptionUpdate(()=>this.endEditing()),this.chartOptionsService.awaitChartOptionUpdate(()=>{this.chartMenuUtils.setValue("title.color",e)})}endEditing(){if(!this.editing)return;this.editing=!1;const e=this.getGui().value;e&&""!==e.trim()?(this.chartMenuUtils.setValue("title.text",e),this.chartMenuUtils.setValue("title.enabled",!0)):(this.chartMenuUtils.setValue("title.text",""),this.chartMenuUtils.setValue("title.enabled",!1)),this.getGui().classList.remove("currently-editing"),this.chartOptionsService.awaitChartOptionUpdate(()=>{this.eventService.dispatchEvent({type:"chartTitleEdit"})})}};rn.TEMPLATE='<textarea\n             class="ag-chart-title-edit"\n             style="padding:0; border:none; border-radius: 0; min-height: 0; text-align: center; resize: none;" />\n        ',qe([(0,r.dsm)("chartTranslationService")],rn.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],rn.prototype,"chartMenuService",2),qe([r.o7C],rn.prototype,"init",1);var nn=rn;function sn(e){return null!=e.chart?e.chart:e}var on=class{constructor(e){this.chartProxyParams=e,this.clearThemeOverrides=!1,this.isEnterpriseCharts=n._ModuleSupport.enterpriseModule.isEnterprise,this.chart=e.chartInstance,this.chartType=e.chartType,this.crossFiltering=e.crossFiltering,this.crossFilterCallback=e.crossFilterCallback,this.standaloneChartType=ct(this.chartType),null==this.chart?this.chart=n.AgCharts.create(this.getCommonChartOptions()):this.clearThemeOverrides=!0}crossFilteringReset(){}update(e){n.AgCharts.update(this.getChartRef(),this.getUpdateOptions(e,this.getCommonChartOptions(e.updatedOverrides)))}updateThemeOverrides(e){n.AgCharts.updateDelta(this.getChartRef(),{theme:{overrides:e}})}getChart(){return sn(this.chart)}getChartRef(){return this.chart}downloadChart(e,t,i){const{chart:r}=this,s=sn(r),o=t||(s.title?s.title.text:"chart"),{width:a,height:l}=e||{};n.AgCharts.download(r,{width:a,height:l,fileName:o,fileFormat:i})}getChartImageDataURL(e){return this.getChart().getCanvasDataURL(e)}getChartOptions(){return this.chart.getOptions()}getChartThemeOverrides(){var e;return null!=(e=this.getChartOptions().theme.overrides)?e:{}}getChartPalette(){return n._Theme.getChartTheme(this.getChartOptions().theme).palette}setPaired(e){const t=ct(this.chartProxyParams.chartType);n.AgCharts.updateDelta(this.chart,{theme:{overrides:{[t]:{paired:e}}}})}isPaired(){const e=ct(this.chartProxyParams.chartType);return Et(this.getChartThemeOverrides(),`${e}.paired`,!0)}lookupCustomChartTheme(e){return Rt(this.chartProxyParams,e)}getSeriesGroupType(){}transformCategoryData(e,t){return e.map((e,i)=>{const r=e[t],n=r&&r.toString?r.toString():"",s=je({},e);return s[t]={id:i,value:r,toString:()=>n},s})}getCommonChartOptions(e){var t,i;const s=this.clearThemeOverrides?{}:null!=(i=null==(t=this.chart)?void 0:t.getOptions())?i:{},o=null!=this.chart?this.getActiveFormattingPanelOverrides():void 0;this.clearThemeOverrides=!1;const a=function(e,t,i,s,o){var a;const{chartOptionsToRestore:l,chartPaletteToRestore:c,chartThemeToRestore:u}=e,h=function(e){let t=e.getChartThemeName();const i=e.getChartThemes();return r._.includes(i,t)||(t=i[0]),t}(e),d=At(h),p=d?{baseTheme:h}:null!=(a=Rt(e,h))?a:{},g=e.getGridOptionsChartThemeOverrides(),f=e.apiChartThemeOverrides,m=ct(e.chartType),v=e.crossFiltering?function(e,t,i){const r={listeners:{legendItemClick:t=>{e.getChart().series.forEach(e=>{e.toggleSeriesItem(t.itemId,t.enabled),e.toggleSeriesItem(`${t.itemId}-filtered-out`,t.enabled)})}}};return{[i]:{tooltip:{delay:500},legend:r,listeners:{click:e=>t.crossFilterCallback(e,!0)}}}}(t,e,m):void 0,C=[d?Mt(e,i,(()=>{const e=e=>!!e&&Object.keys(e).some(t=>Et(e[t],"title.enabled",!1));return e(g)||e(f)})()):void 0,s,v,g,f,je({},null!=l?l:{}),o].filter(e=>!!e).reduce((e,t)=>({baseTheme:e,overrides:t}),p);return c&&h===u&&(function(e,t){const i=(e,t)=>e.length===t.length&&e.every((e,i)=>e===t[i]);return i(e.fills,t.fills)&&i(e.strokes,t.strokes)}(c,n._Theme.getChartTheme(p).palette)||(C.palette=c)),C}(this.chartProxyParams,this,this.isEnterpriseCharts,this.getChartThemeDefaults(),null!=e?e:o),l=Ke(je({},s),{mode:"integrated"});return l.theme=a,l.container=this.chartProxyParams.parentElement,l}getChartThemeDefaults(){const e=this.getSeriesChartThemeDefaults(),t=e?{[this.standaloneChartType]:e}:{},i={enabled:!0,snap:!0,label:{enabled:!1}};return je({common:{navigator:{enabled:!1},zoom:{enabled:!0},animation:{enabled:!0,duration:500},axes:{number:{crosshair:i},category:{crosshair:i},log:{crosshair:i},time:{crosshair:i}}}},t)}getSeriesChartThemeDefaults(){}getActiveFormattingPanelOverrides(){var e,t;if(this.clearThemeOverrides)return{};const i=null==(e=this.chart)?void 0:e.getOptions().theme;return null!=(t=null==i?void 0:i.overrides)?t:{}}destroy({keepChartInstance:e=!1}={}){if(e)return this.chart.resetAnimations(),this.chart;this.destroyChart()}destroyChart(){this.chart&&(this.chart.destroy(),this.chart=void 0)}},an=class extends on{constructor(e){super(e),this.crossFilteringAllPoints=new Set,this.crossFilteringSelectedPoints=[]}getUpdateOptions(e,t){const i=this.getAxes(e,t);return Ke(je({},t),{data:this.getData(e,i),axes:i,series:this.getSeries(e)})}getData(e,t){const i=["area","line"].includes(this.standaloneChartType);return this.crossFiltering&&i?this.getCrossFilterData(e):this.getDataTransformedData(e,t)}getDataTransformedData(e,t){const i=t[0].type,{categories:r,data:n}=e,[s]=r;switch(i){case"category":return this.transformCategoryData(n,s.id);case"time":return this.transformTimeData(n,s.id);default:return n}}getXAxisType(e){return e.grouping?"grouped-category":this.isXAxisOfType(e,"time",e=>e instanceof Date)?"time":this.isXAxisOfType(e,"number")?"number":"category"}isXAxisOfType(e,t,i){const[r]=e.categories;if(null==r?void 0:r.chartDataType)return r.chartDataType===t;if(!i)return!1;const n=e.data[0];return!!n&&i(n[r.id])}transformTimeData(e,t){var i;return(null==(i=e[0])?void 0:i[t])instanceof Date?e:e.map(e=>{const i=e[t];return"string"==typeof i?Ke(je({},e),{[t]:new Date(i)}):e})}crossFilteringReset(){this.crossFilteringSelectedPoints=[],this.crossFilteringAllPoints.clear()}crossFilteringPointSelected(e){return 0==this.crossFilteringSelectedPoints.length||this.crossFilteringSelectedPoints.includes(e)}crossFilteringDeselectedPoints(){return this.crossFilteringSelectedPoints.length>0&&this.crossFilteringAllPoints.size!==this.crossFilteringSelectedPoints.length}extractLineAreaCrossFilterSeries(e,t){const[i]=t.categories,r=e=>"area"===this.standaloneChartType?t.getCrossFilteringContext().lastSelectedChartId===t.chartId?e+"-total":e:e+"-total";return e.map(e=>(e.yKey=r(e.yKey),e.listeners={nodeClick:t=>{const i=t.datum[e.xKey],r=t.event.metaKey||t.event.ctrlKey;this.crossFilteringAddSelectedPoint(r,i),this.crossFilterCallback(t)}},e.marker={formatter:e=>{const t=e.datum[i.id];return{fill:e.highlighted?"yellow":e.fill,size:e.highlighted?14:this.crossFilteringPointSelected(t)?8:0}}},"area"===this.standaloneChartType&&(e.fillOpacity=this.crossFilteringDeselectedPoints()?.3:1),"line"===this.standaloneChartType&&(e.strokeOpacity=this.crossFilteringDeselectedPoints()?.3:1),e))}getCrossFilterData(e){this.crossFilteringAllPoints.clear();const[t]=e.categories,i=e.fields[0].colId,r=`${i}-filtered-out`,n=e.getCrossFilteringContext().lastSelectedChartId;return e.data.map(s=>{const o=s[t.id];this.crossFilteringAllPoints.add(o);const a=this.crossFilteringPointSelected(o);return"area"===this.standaloneChartType&&n===e.chartId&&(s[`${i}-total`]=a?s[i]:s[i]+s[r]),"line"===this.standaloneChartType&&(s[`${i}-total`]=a?s[i]:s[i]+s[r]),s})}crossFilteringAddSelectedPoint(e,t){e?this.crossFilteringSelectedPoints.push(t):this.crossFilteringSelectedPoints=[t]}isHorizontal(e){const t=this.standaloneChartType;if("waterfall"!==t&&"box-plot"!==t&&"range-bar"!==t)return!1;const i=e.theme,r=e=>{var i,n,s;const o=null==(s=null==(n=null==(i=null==e?void 0:e.overrides)?void 0:i[t])?void 0:n.series)?void 0:s.direction;return null!=o?"horizontal"===o:"object"==typeof(null==e?void 0:e.baseTheme)&&r(e.baseTheme)};return r(i)}};function ln(e,t){const i=parseInt(e.slice(1,3),16),r=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16);return t?`rgba(${i}, ${r}, ${n}, ${t})`:`rgba(${i}, ${r}, ${n})`}function cn(e,t){return e.map(e=>{const i=n._Util.Color.fromString(e);return new n._Util.Color(i.r,i.g,i.b,t).toHexString()})}var un=new Set(["bar","groupedBar","stackedBar","normalizedBar"]),hn=class extends an{constructor(e){super(e)}getAxes(e){const t=[{type:this.getXAxisType(e),position:this.isHorizontal()?"left":"bottom"},{type:"number",position:this.isHorizontal()?"bottom":"left"}];if(this.isNormalised()){const e=t[1];e.label=Ke(je({},e.label),{formatter:e=>Math.round(e.value)+"%"})}return t}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>{return{type:this.standaloneChartType,direction:this.isHorizontal()?"horizontal":"vertical",stacked:this.crossFiltering||(i=this.chartType,rt.has(i)),normalizedTo:this.isNormalised()?100:void 0,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName};var i});return this.crossFiltering?this.extractCrossFilterSeries(i):i}extractCrossFilterSeries(e){const t=this.getChartPalette(),i=(e,i)=>Ke(je({},e),{highlightStyle:{item:{fill:void 0}},fill:null==t?void 0:t.fills[i],stroke:null==t?void 0:t.strokes[i],listeners:{nodeClick:this.crossFilterCallback}}),r=e=>{const t=e.yKey+"-filtered-out";return Ke(je({},bt({},e)),{yKey:t,fill:ln(e.fill,"0.3"),stroke:ln(e.stroke,"0.3"),showInLegend:!1})},n=[];for(let t=0;t<e.length;t++){const s=i(e[t],t);n.push(s),n.push(r(s))}return n}isNormalised(){return!this.crossFiltering&&r._.includes(["normalizedColumn","normalizedBar"],this.chartType)}isHorizontal(){return un.has(this.chartType)}},dn=class extends an{constructor(e){super(e)}getAxes(e){const t=[{type:this.getXAxisType(e),position:"bottom"},{type:"number",position:"left"}];if(this.isNormalised()){const e=t[1];e.label=Ke(je({},e.label),{formatter:e=>Math.round(e.value)+"%"})}return t}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>({type:this.standaloneChartType,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName,normalizedTo:"normalizedArea"===this.chartType?100:void 0,stacked:["normalizedArea","stackedArea"].includes(this.chartType)}));return this.crossFiltering?this.extractLineAreaCrossFilterSeries(i,e):i}isNormalised(){return!this.crossFiltering&&"normalizedArea"===this.chartType}},pn=class extends an{constructor(e){super(e)}getAxes(e){return[{type:this.getXAxisType(e),position:"bottom"},{type:"number",position:"left"}]}getSeries(e){const[t]=e.categories,i=e.fields.map(e=>({type:this.standaloneChartType,xKey:t.id,xName:t.name,yKey:e.colId,yName:e.displayName}));return this.crossFiltering?this.extractLineAreaCrossFilterSeries(i,e):i}},gn=class extends on{constructor(e){super(e)}getAxes(e){const t="radial-bar"===this.standaloneChartType;return[{type:t?"angle-number":"angle-category"},{type:t?"radius-category":"radius-number"}]}getSeries(e){const{fields:t,categories:i,seriesGroupType:r}=e,[n]=i,s="radial-bar"===this.standaloneChartType,o=this.getSeriesGroupTypeOptions(r);return t.map(e=>{var t,i;return je({type:this.standaloneChartType,angleKey:s?e.colId:n.id,angleName:s?null!=(t=e.displayName)?t:void 0:n.name,radiusKey:s?n.id:e.colId,radiusName:s?n.name:null!=(i=e.displayName)?i:void 0},o)})}getSeriesGroupType(){var e,t;const i=this.standaloneChartType;if(!["nightingale","radial-bar","radial-column"].includes(i))return;const r=null==(t=null==(e=this.getChart().series)?void 0:e[0])?void 0:t.properties.toJson(),n=()=>r.normalizedTo?"normalized":"stacked";return"nightingale"===i?r.grouped?"grouped":n():r.stacked?n():"grouped"}getUpdateOptions(e,t){const i=this.getAxes(e);return Ke(je({},t),{data:this.getData(e,i),axes:i,series:this.getSeries(e)})}getData(e,t){if(t.some(e=>"angle-category"===e.type||"radius-category"===e.type)){const[t]=e.categories;return this.transformCategoryData(e.data,t.id)}return e.data}getSeriesGroupTypeOptions(e){return e?{grouped:"grouped"===e||void 0,stacked:"grouped"!==e||void 0,normalizedTo:"normalized"===e?100:void 0}:{}}},fn=class e extends on{constructor(e){super(e)}getUpdateOptions(e,t){return Ke(je({},t),{data:this.crossFiltering?this.getCrossFilterData(e):e.data,series:this.getSeries(e)})}getSeries(t){const[i]=t.categories,r=t.fields.length,n={currentOffset:0,offsetAmount:r>1?20:40},s=this.getFields(t).map(t=>{var s;const o={type:this.standaloneChartType,angleKey:t.colId,angleName:t.displayName,sectorLabelKey:t.colId,calloutLabelName:i.name,calloutLabelKey:i.id};if("donut"===this.chartType||"doughnut"===this.chartType){const{outerRadiusOffset:i,innerRadiusOffset:a}=e.calculateOffsets(n),l=t.displayName?{title:{text:t.displayName,showInLegend:r>1}}:void 0;return Ke(je(Ke(je({},o),{type:"donut",outerRadiusOffset:i,innerRadiusOffset:a}),l),{calloutLine:{colors:null==(s=this.getChartPalette())?void 0:s.strokes}})}return o});return this.crossFiltering?this.extractCrossFilterSeries(s):s}getCrossFilterData(e){const t=e.fields[0].colId,i=`${t}-filtered-out`;return e.data.map(e=>{const r=e[t]+e[i];return e[`${t}-total`]=r,e[i]=1,e[t]=e[t]/r,e})}extractCrossFilterSeries(e){const t=this.getChartPalette(),i=e[0],r=i.angleKey,n=(e=>Ke(je({},e),{legendItemKey:e.calloutLabelKey,calloutLabel:{enabled:!1},highlightStyle:{item:{fill:void 0}},radiusKey:e.angleKey,angleKey:e.angleKey+"-total",radiusMin:0,radiusMax:1,listeners:{nodeClick:this.crossFilterCallback}}))(i);return[(s=i,o=r,Ke(je({},bt({},n)),{radiusKey:o+"-filtered-out",fills:cn(null!=(a=s.fills)?a:t.fills,.3),strokes:cn(null!=(l=s.strokes)?l:t.strokes,.3),showInLegend:!1})),n];var s,o,a,l}static calculateOffsets(e){const t=e.currentOffset;e.currentOffset-=e.offsetAmount;const i=e.currentOffset;return e.currentOffset-=e.offsetAmount,{outerRadiusOffset:t,innerRadiusOffset:i}}getFields(e){return"pie"===this.chartType?e.fields.slice(0,1):e.fields}},mn=class extends an{constructor(e){super(e)}getAxes(e){return[{type:"number",position:"bottom"},{type:"number",position:"left"}]}getSeries(e){const[t]=e.categories,i=this.isPaired(),r=this.getSeriesDefinitions(e.fields,i),n=t.id===ft.DEFAULT_CATEGORY?void 0:t,s=r.map(e=>{var t,i,r,s,o;return(null==e?void 0:e.sizeField)?{type:"bubble",xKey:e.xField.colId,xName:null!=(t=e.xField.displayName)?t:void 0,yKey:e.yField.colId,yName:null!=(i=e.yField.displayName)?i:void 0,title:`${e.yField.displayName} vs ${e.xField.displayName}`,sizeKey:e.sizeField.colId,sizeName:null!=(r=e.sizeField.displayName)?r:"",labelKey:n?n.id:e.yField.colId,labelName:n?n.name:void 0}:{type:"scatter",xKey:e.xField.colId,xName:null!=(s=e.xField.displayName)?s:void 0,yKey:e.yField.colId,yName:null!=(o=e.yField.displayName)?o:void 0,title:`${e.yField.displayName} vs ${e.xField.displayName}`,labelKey:n?n.id:e.yField.colId,labelName:n?n.name:void 0}});return this.crossFiltering?this.extractCrossFilterSeries(s,e):s}extractCrossFilterSeries(e,t){const{data:i}=t,r=this.getChartPalette(),n=e=>`${e}-filtered-out`,s=e.map((e,t)=>{const s=null==r?void 0:r.fills[t],o=null==r?void 0:r.strokes[t];let a;if("bubble"===e.type){const{sizeKey:t}=e;a=((e,t)=>{var i;const r=[1/0,-1/0];if(null!=t)for(const s of e){const e=null!=(i=s[t])?i:s[n(t)];e<r[0]&&(r[0]=e),e>r[1]&&(r[1]=e)}if(r[0]<=r[1])return r})(i,t)}const l=Ke(je({},e.marker),{fill:s,stroke:o,domain:a});return Ke(je({},e),{marker:l,highlightStyle:{item:{fill:"yellow"}},listeners:Ke(je({},e.listeners),{nodeClick:this.crossFilterCallback})})});return[...s,...s.map(e=>{let{yKey:t,xKey:i}=e,r={};return"bubble"===e.type&&(r={sizeKey:n(e.sizeKey)}),Ke(je(je({},e),r),{yKey:n(t),xKey:n(i),marker:Ke(je({},e.marker),{fillOpacity:.3,strokeOpacity:.3}),showInLegend:!1,listeners:Ke(je({},e.listeners),{nodeClick:e=>{const t=e.datum[n(i)],r=Ke(je({},e),{xKey:i,datum:Ke(je({},e.datum),{[i]:t})});this.crossFilterCallback(r)}})})})]}getSeriesDefinitions(e,t){if(e.length<2)return[];const i="bubble"===this.chartType;if(t)return i?e.map((t,i)=>i%3==0?{xField:t,yField:e[i+1],sizeField:e[i+2]}:null).filter(e=>e&&e.yField&&e.sizeField):e.map((t,i)=>i%2==0?{xField:t,yField:e[i+1]}:null).filter(e=>e&&e.yField);const r=e[0];return i?e.map((t,i)=>i%2==1?{xField:r,yField:t,sizeField:e[i+1]}:null).filter(e=>e&&e.sizeField):e.filter((e,t)=>t>0).map(e=>({xField:r,yField:e}))}},vn=class extends an{constructor(e){super(e)}getAxes(e,t){return[{type:this.getXAxisType(e),position:this.isHorizontal(t)?"left":"bottom"},{type:"number",position:this.isHorizontal(t)?"bottom":"left"}]}computeSeriesStatistics(e,t){const{data:i,fields:r}=e,[n]=e.categories,s=n.id||ft.DEFAULT_CATEGORY,o=this.groupDataByCategory(s,i);return Array.from(o).map(([e,i])=>{const s={[n.id]:e};return r.forEach((e,r)=>{const n=i.map(t=>t[e.colId]).filter(e=>"number"==typeof e&&!isNaN(e));Object.entries(t(n)).forEach(([e,t])=>{s[`${e}:${r}`]=n.length>0?t:null})}),s})}groupDataByCategory(e,t){return t.reduce((t,i)=>{let r=(t=>{if(e===ft.DEFAULT_CATEGORY)return 1;const i=t[e];return null==i?"":i instanceof Date?i.getTime():i})(i);const n=t.get(r);return n?n.push(i):t.set(r,[i]),t},new Map)}},Cn=class extends vn{constructor(e){super(e)}getSeries(e){const[t]=e.categories;return e.fields.map((e,i)=>{var r;return{type:this.standaloneChartType,xKey:t.id,xName:t.name,yName:null!=(r=e.displayName)?r:void 0,yLowName:"Min",yHighName:"Max",yLowKey:`min:${i}`,yHighKey:`max:${i}`}})}getData(e){return this.computeSeriesStatistics(e,e=>({min:Math.min(...e),max:Math.max(...e)}))}},yn=class extends an{constructor(e){super(e)}getSeries(e){const t=e.fields[0];return[{type:this.standaloneChartType,xKey:t.colId,xName:t.displayName,yName:this.chartProxyParams.translate("histogramFrequency"),areaPlot:!1}]}getAxes(e){return[{type:"number",position:"bottom"},{type:"number",position:"left"}]}},wn=class extends vn{constructor(e){super(e)}getSeries(e){const[t]=e.categories;return e.fields.map((e,i)=>{var r;return{type:this.standaloneChartType,xKey:t.id,xName:t.name,yName:null!=(r=e.displayName)?r:void 0,minName:"Min",q1Name:"Q1",medianName:"Median",q3Name:"Q3",maxName:"Max",minKey:`min:${i}`,q1Key:`q1:${i}`,medianKey:`median:${i}`,q3Key:`q3:${i}`,maxKey:`max:${i}`}})}getData(e){return this.computeSeriesStatistics(e,e=>{const t=e.sort((e,t)=>e-t);return{min:t[0],q1:this.quantile(t,.25),median:this.quantile(t,.5),q3:this.quantile(t,.75),max:t[t.length-1]}})}quantile(e,t){const i=(e.length-1)*t,r=Math.floor(i),n=i-r;return void 0!==e[r+1]?e[r]+n*(e[r+1]-e[r]):e[r]}},Sn=class extends on{constructor(e){super(e)}getUpdateOptions(e,t){const i="AG-GRID-DEFAULT-HEATMAP-SERIES-KEY",r="AG-GRID-DEFAULT-HEATMAP-VALUE-KEY",n="AG-GRID-DEFAULT-HEATMAP-CATEGORY-KEY";return Ke(je({},t),{series:this.getSeries(e,i,r,n),data:this.getData(e,i,r,n)})}getSeries(e,t,i,r){const[n]=e.categories;return[{type:this.standaloneChartType,yKey:r,xKey:t,colorKey:i,yName:n.name,xName:void 0,colorName:void 0}]}getData(e,t,i,r){const[n]=e.categories;return s=e.data,o=(s,o)=>{const a=s[n.id],l=null==a?"":String(a),c={id:o,value:a,toString:()=>l};return e.fields.map(({colId:e,displayName:n})=>Ke(je({},s),{[t]:n,[i]:s[e],[r]:c}))},s.reduce((e,t,i,r)=>e.concat(o(t,i)),new Array);var s,o}getSeriesChartThemeDefaults(){return{gradientLegend:{gradient:{preferredLength:200}},series:{tooltip:{renderer:bn}}}}};function bn(e){const{xKey:t,yKey:i,colorKey:r,yName:n,datum:s}=e;return{title:"",content:[{label:n,value:s[i]},{label:s[t],value:r&&s[r]}].map(({label:e,value:t})=>`<b>${En(String(e))}:</b> ${En(String(t))}`).join("<br>")}}function En(e){const t={"&":"&amp;","<":"&lt;",">":"&gt;"},i=`[${Object.keys(t).join("")}]`,r=new RegExp(i,"g");return e.replace(r,e=>t[e])}var An=class extends an{constructor(e){super(e)}getAxes(e,t){return[{type:this.getXAxisType(e),position:this.isHorizontal(t)?"left":"bottom"},{type:"number",position:this.isHorizontal(t)?"bottom":"left"}]}getSeries(e){var t;const[i]=e.categories,[r]=e.fields;return[{type:this.standaloneChartType,xKey:i.id,xName:i.name,yKey:r.colId,yName:null!=(t=r.displayName)?t:void 0}]}},Tn=["number","category","time","grouped-category"],Mn=[...Tn,"angle-category","angle-number","radius-category","radius-number"],Rn=class e extends r.XQb{constructor(e){super(),this.chartController=e}getChartThemeOverridesProxy(){return{getValue:e=>this.getChartOption(e),setValue:(e,t)=>this.setChartThemeOverrides([{expression:e,value:t}]),setValues:e=>this.setChartThemeOverrides(e)}}getAxisThemeOverridesProxy(){return{getValue:e=>this.getAxisProperty(e),setValue:(e,t)=>this.setAxisThemeOverrides([{expression:e,value:t}]),setValues:e=>this.setAxisThemeOverrides(e)}}getCartesianAxisOptionsProxy(e){return{getValue:t=>this.getCartesianAxisProperty(e,t),setValue:(t,i)=>this.setCartesianAxisOptions(e,[{expression:t,value:i}]),setValues:t=>this.setCartesianAxisOptions(e,t)}}getCartesianAxisThemeOverridesProxy(e){return{getValue:t=>this.getCartesianAxisProperty(e,t),setValue:(t,i)=>this.setCartesianAxisThemeOverrides(e,[{expression:t,value:i}]),setValues:t=>this.setCartesianAxisThemeOverrides(e,t)}}getCartesianAxisAppliedThemeOverridesProxy(e){return{getValue:t=>this.getCartesianAxisThemeOverride(e,"*"===t?null:t),setValue:(t,i)=>this.setCartesianAxisThemeOverrides(e,[{expression:"*"===t?null:t,value:i}]),setValues:t=>this.setCartesianAxisThemeOverrides(e,t)}}getSeriesOptionsProxy(e){return{getValue:(t,i)=>this.getSeriesOption(e(),t,i),setValue:(t,i)=>this.setSeriesOptions(e(),[{expression:t,value:i}]),setValues:t=>this.setSeriesOptions(e(),t)}}getPersistedChartThemeOverrides(e,t,i,r){const n=this.getRetainedChartThemeOverrideKeys(i,r),s=this.getRetainedChartAxisThemeOverrideKeys(null,i,r),o=this.createChartOptions();for(const t of n){const n=this.retrieveChartOptionsThemeOverride(e,i,t);void 0!==n&&this.assignChartOptionsThemeOverride(o,r,t,n)}return t&&this.assignPersistedAxisOverrides({existingAxes:t,retainedChartAxisThemeOverrideKeys:s,existingChartOptions:e,targetChartOptions:o,existingChartType:i,targetChartType:r}),o.theme.overrides}assignPersistedAxisOverrides(e){const{existingAxes:t,retainedChartAxisThemeOverrideKeys:i,existingChartOptions:r,targetChartOptions:n,existingChartType:s,targetChartType:o}=e;for(const{expression:e,targetAxisTypes:a}of i)for(const i of t.map(e=>e.type)){const t=this.retrieveChartOptionsThemeOverride(r,s,["axes",i,e].join("."));if(void 0!==t)for(const i of a)this.assignChartOptionsThemeOverride(n,o,["axes",i,e].join("."),t)}}getRetainedChartThemeOverrideKeys(e,t){const i=["zoom","navigator"];return["animation",...((e,t)=>{const r=new Array;return nt(ct(e))&&nt(ct(t))&&r.push(...i),r})(e,t)]}getRetainedChartAxisThemeOverrideKeys(e,t,i){return nt(ct(t))&&nt(ct(i))?this.getRetainedCartesianAxisThemeOverrideKeys(e).map(e=>({expression:e,targetAxisTypes:Tn})):[]}getRetainedCartesianAxisThemeOverrideKeys(e){const t="xAxis"===e?["",".top",".bottom"]:"yAxis"===e?["",".left",".right"]:["",".left",".right",".top",".bottom"],i=["crosshair"],r=new Array;for(const e of i)for(const i of t)r.push(`${e}${i}`);return r}getChartOption(e){return Et(this.getChart(),e,void 0)}setChartThemeOverrides(e){const t=this.getChartType(),i=this.createChartOptions();for(const{expression:r,value:n}of e)this.assignChartOptionsThemeOverride(i,t,r,n);this.applyChartOptions(i)}applyChartOptions(e,t){0!==Object.keys(e).length&&(this.updateChart(e),!(null==t?void 0:t.silent)&&this.raiseChartOptionsChangedEvent())}awaitChartOptionUpdate(e){this.chartController.getChartProxy().getChart().waitForUpdate().then(()=>e()).catch(e=>console.error("AG Grid - chart update failed",e))}getAxisProperty(e){var t;return Et(null==(t=this.getChart().axes)?void 0:t[0],e,void 0)}setAxisThemeOverrides(e){var t;const i=this.getChart(),r=this.getChartType();let n=this.createChartOptions();for(const{expression:s,value:o}of e){const e=null==(t=i.axes)?void 0:t.filter(e=>{const t=s.split(".");let i=e;for(const e of t){if(!(e in i))return!1;i=i[e]}return!0});if(e)for(const t of e)this.isValidAxisType(t)&&this.assignChartAxisThemeOverride(n,r,t.type,null,s,o)}this.applyChartOptions(n)}getCartesianAxisProperty(e,t){const i=this.getChartAxes();return Et(this.getCartesianAxis(i,e),t,void 0)}getCartesianAxisThemeOverride(e,t){const i=this.getChartAxes(),r=this.getCartesianAxis(i,e);if(!r||!this.isValidAxisType(r))return;const n=this.getChartType(),s=this.getChart().getOptions();return this.retrieveChartAxisThemeOverride(s,n,r.type,"yAxis"===e?["left","right"]:["bottom","top"],t)}setCartesianAxisThemeOverrides(e,t){const i=this.getChartAxes(),r=this.getCartesianAxis(i,e);if(!r||!this.isValidAxisType(r))return;const n=this.getChartType();let s=this.createChartOptions();for(const{expression:i,value:o}of t)this.assignChartAxisThemeOverride(s,n,r.type,"yAxis"===e?["left","right"]:["bottom","top"],i,o);this.applyChartOptions(s)}setCartesianAxisOptions(e,t){this.updateCartesianAxisOptions(e,(e,i,r)=>{const n=i.indexOf(r);for(const{expression:i,value:r}of t)this.assignChartOption(e,`axes.${n}.${i}`,r)})}updateCartesianAxisOptions(e,t){const i=this.getChart().getOptions(),r="axes"in i?i.axes:void 0;if(!i||!r)return;const n=this.getChartAxes(),s=this.getCartesianAxis(n,e);if(!s)return;let o=this.createChartOptions();o.axes=r,t(o,n,s,i),this.applyChartOptions(o)}setCartesianCategoryAxisType(e,t){this.updateCartesianAxisOptions(e,(i,r,n,s)=>{const o=this.getChartType();this.assignPersistedAxisOverrides({existingAxes:[n],retainedChartAxisThemeOverrideKeys:this.getRetainedChartAxisThemeOverrideKeys(e,o,o),existingChartOptions:s,targetChartOptions:i,existingChartType:o,targetChartType:o}),this.assignChartOption(i,"axes.0.type",t),this.chartController.setCategoryAxisType(t)})}getCartesianAxis(e,t){if(!(e.length<2))switch(t){case"xAxis":return"x"===e[0].direction?e[0]:e[1];case"yAxis":return"y"===e[1].direction?e[1]:e[0]}}getSeriesOption(t,i,r){const n=this.getChart().series.find(i=>e.isMatchingSeries(t,i));return Et(r?n:null==n?void 0:n.properties.toJson(),i,void 0)}setSeriesOptions(e,t){let i=this.createChartOptions();for(const{expression:r,value:n}of t)this.assignChartOptionsSeriesThemeOverride(i,e,`series.${r}`,n);this.applyChartOptions(i)}getPairedMode(){return this.chartController.getChartProxy().isPaired()}setPairedMode(e){this.chartController.getChartProxy().setPaired(e)}getChartAxes(){var e;return null!=(e=this.getChart().axes)?e:[]}retrieveChartAxisThemeOverride(e,t,i,r,n){if(!r)return this.retrieveChartOptionsThemeOverride(e,t,["axes",i,...n?[n]:[]].join("."));for(const s of r){const r=this.retrieveChartOptionsThemeOverride(e,t,["axes",i,s,...n?[n]:[]].join("."));if(void 0!==r)return r}}assignChartAxisThemeOverride(e,t,i,r,n,s){if(r)for(const o of r)this.assignChartOptionsThemeOverride(e,t,["axes",i,o,...n?[n]:[]].join("."),s);else this.assignChartOptionsThemeOverride(e,t,["axes",i,...n?[n]:[]].join("."),s)}isValidAxisType(e){return Mn.includes(e.type)}getChartType(){return this.chartController.getChartType()}getChart(){return this.chartController.getChartProxy().getChart()}updateChart(e){const t=this.chartController.getChartProxy().getChartRef();t.skipAnimations(),n.AgCharts.updateDelta(t,e)}createChartOptions(){return{theme:{overrides:{}}}}retrieveChartOptionsThemeOverride(e,t,i){const r=this.getChartThemeOverridesSeriesTypeKeys(t);for(const t of r){const r=this.retrieveChartOptionsSeriesThemeOverride(e,t,i);if(void 0!==r)return r}}assignChartOptionsThemeOverride(e,t,i,r){const n=this.getChartThemeOverridesSeriesTypeKeys(t);for(const t of n)this.assignChartOptionsSeriesThemeOverride(e,t,i,r)}retrieveChartOptionsSeriesThemeOverride(e,t,i){return this.retrieveChartOption(e,["theme","overrides",t,...i?[i]:[]].join("."))}assignChartOptionsSeriesThemeOverride(e,t,i,r){this.assignChartOption(e,["theme","overrides",t,...i?[i]:[]].join("."),r)}getChartThemeOverridesSeriesTypeKeys(e){const t=this.chartController.getChartSeriesTypes(e);return this.chartController.isComboChart()&&t.push("common"),t}retrieveChartOption(e,t){return Et(e,t,void 0)}assignChartOption(e,t,i){!function(e,t,i){if(null==e)return;const r=t.split(".");let n=e;r.forEach((e,t)=>{n[e]||(n[e]={}),t<r.length-1&&(n=n[e])}),n[r[r.length-1]]=i}(e,t,i)}raiseChartOptionsChangedEvent(){const e=this.chartController.getChartModel(),t={type:r.sVA.EVENT_CHART_OPTIONS_CHANGED,chartId:e.chartId,chartType:e.chartType,chartThemeName:this.chartController.getChartThemeName(),chartOptions:e.chartOptions};this.eventService.dispatchEvent(t)}static isMatchingSeries(e,t){return function(e){return!!et[e]}(e)&&t.type===e}destroy(){super.destroy()}},_n=class extends an{constructor(e){super(e)}getAxes(e){const t=e?e.fields:[],i=new Map(t.map(e=>[e.colId,e])),{primaryYKeys:r,secondaryYKeys:n}=this.getYKeys(t,e.seriesChartTypes),s=[{type:this.getXAxisType(e),position:"bottom"}];return r.length>0&&s.push({type:"number",keys:r,position:"left"}),n.length>0&&n.forEach(e=>{const t=i.get(e);if(!t||t.colId!==e)return;const r={type:"number",keys:[e],position:"right"};s.push(r)}),s}getSeries(e){const{fields:t,seriesChartTypes:i}=e,[r]=e.categories;return t.map(e=>{const t=i.find(t=>t.colId===e.colId);if(t){const i=t.chartType,n=["groupedColumn","groupedBar"].includes(i)?{grouped:!0}:{};return je({type:ct(i),xKey:r.id,yKey:e.colId,yName:e.displayName,stacked:["stackedArea","stackedColumn"].includes(i)},n)}})}getYKeys(e,t){const i=[],r=[];return e.forEach(e=>{const n=e.colId,s=t.find(e=>e.colId===n);s&&(s.secondaryAxis?r.push(n):i.push(n))}),{primaryYKeys:i,secondaryYKeys:r}}},Pn=["chartSettings","chartData","chartFormat"],xn=["chartUnlink","chartLink","chartDownload"],Dn={settings:"chartSettings",data:"chartData",format:"chartFormat"},In=class extends r.XQb{isLegacyFormat(){return!this.chartService.isEnterprise()}downloadChart(e,t,i,r){e.chartController.getChartProxy().downloadChart(t,i,r)}toggleLinked(e){e.chartController.detachChartRange()}openAdvancedSettings(e,t){this.advancedSettingsMenuFactory.showMenu(e,t)}hideAdvancedSettings(){this.advancedSettingsMenuFactory.hideMenu()}getToolbarOptionsAndPanels(e){var t,i,n;const s=this.isLegacyFormat();let o,a,l;if(Boolean(this.gos.get("chartToolPanelsDef"))||!s){const c=s?[e.isChartLinked()?"chartLink":"chartUnlink","chartDownload"]:["chartMenu"],u=this.gos.getCallback("getChartToolbarItems");l=u?u({defaultItems:c}).filter(e=>{if(!(s?xn:[...xn,"chartMenu"]).includes(e)){let t;return t=Pn.includes(e)?`'${e}' is a Chart Tool Panel option and will be ignored since 'chartToolPanelsDef' is used. Please use 'chartToolPanelsDef.panels' grid option instead`:"chartMenu"===e?"'chartMenu' is only allowed as a Chart Toolbar Option when using AG Charts Enterprise":`'${e}' is not a valid Chart Toolbar Option`,r._.warnOnce(t),!1}return!0}):c;const h=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.panels)?void 0:i.map(e=>{const t=Dn[e];return t||r._.warnOnce(`Invalid panel in chartToolPanelsDef.panels: '${e}'`),t}).filter(e=>Boolean(e));o=h||Object.values(Dn),e.isPivotChart()&&(o=o.filter(e=>"chartData"!==e));const d=null==(n=this.gos.get("chartToolPanelsDef"))?void 0:n.defaultToolPanel;a=d&&Dn[d]||o[0],s&&(l=o.length>0?[o[0],...l]:l)}else{let t=["chartSettings","chartData","chartFormat",e.isChartLinked()?"chartLink":"chartUnlink","chartDownload"];const i=this.gos.getCallback("getChartToolbarItems");if(i){const e=this.gos.get("suppressChartToolPanelsButton");t=i({defaultItems:e?t:xn}).filter(t=>{if(!Pn.includes(t)&&!xn.includes(t))return r._.warnOnce(`'${t}' is not a valid Chart Toolbar Option`),!1;if(!e&&Pn.includes(t)){const e=`'${t}' is a Chart Tool Panel option and will be ignored. Please use 'chartToolPanelsDef.panels' grid option instead`;return r._.warnOnce(e),!1}return!0}),e||(t=t.concat(Pn))}e.isPivotChart()&&(t=t.filter(e=>"chartData"!==e));const n=["chartUnlink","chartLink","chartDownload"];o=t.filter(e=>-1===n.indexOf(e)),a=o[0],l=t.filter(e=>-1!==n.indexOf(e)||o.length&&e===o[0])}return{panels:o,defaultPanel:a,chartToolbarOptions:l}}doesChartToolbarExist(e){const{chartToolbarOptions:t}=this.getToolbarOptionsAndPanels(e);return["chartMenu",...xn].some(e=>t.includes(e))}doChartToolPanelsExist(e){const{panels:t}=this.getToolbarOptionsAndPanels(e);return t.length>0}};qe([(0,r.dsm)("chartService")],In.prototype,"chartService",2),qe([(0,r.dsm)("advancedSettingsMenuFactory")],In.prototype,"advancedSettingsMenuFactory",2),In=qe([(0,r.dR4)("chartMenuService")],In);var Ln="AG-GRID-DEFAULT-LABEL-KEY";function Nn(e,t=null,i){const{depth:r,rootValues:n,value:s,children:o}=e;if(n)return n.map(e=>je({[Ln]:t},e));if(0===r)return[je({[Ln]:t},s)];const a=[];for(const[e,t]of o.entries())a.push(...Nn(t,e,!0));return i?[je({[Ln]:t,children:a},null!=s?s:{})]:a}function On(e,t,i){const r={depth:0,children:new Map};return e.forEach(e=>{n(e,t(e),i,0,r)}),r;function n(e,t,i,r,s){if(r===t)return 0===r?(s.rootValues||(s.rootValues=[]),s.rootValues.push(e)):s.value=e,s;{const o=i(e,r),a=n(e,t,i,r+1,s.children.get(o)||{depth:0,children:new Map});return s.children.set(o,a),s.depth=Math.max(1+a.depth,s.depth),s}}}var Fn=class extends on{constructor(e){super(e)}getUpdateOptions(e,t){const{fields:i}=e,[r,n]=i;return Ke(je({},t),{series:this.getSeries(r,n),data:this.getData(e,r,n)})}getSeriesChartThemeDefaults(){return{gradientLegend:{gradient:{preferredLength:200}}}}getSeries(e,t){var i,r;return[{type:this.standaloneChartType,labelKey:Ln,sizeKey:null==e?void 0:e.colId,sizeName:null!=(i=null==e?void 0:e.displayName)?i:void 0,colorKey:null==t?void 0:t.colId,colorName:null!=(r=null==t?void 0:t.displayName)?r:void 0}]}getData(e,t,i){var n;const{categories:s,data:o,groupData:a,grouping:l}=e;return l?function(e,t){return Nn(On(e,function(e){var i,r;return null!=(r=null==(i=t(e))?void 0:i.length)?r:0},function(e,i){const r=t(e);return r?r[r.length-1-i]:null}))}(i?o.concat(null!=(n=null==a?void 0:a.map(e=>{const i=je({},e);return delete i[t.colId],i}))?n:[]):o,e=>{var t,i;return null!=(i=null==(t=e[r.JPk])?void 0:t.labels)?i:null}):function(e,t){return Nn(On(e,function(e){return t.length},function(e,i){return null==(r=e[t[i]])?null:String(r);var r}))}(o,s.map(({id:e})=>e))}},kn=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.params=t}init(){const e=Ke(je({},this.params),{chartType:at(this.params.chartType),chartThemeName:this.getThemeName()}),t=this.gos.get("enableRtl");this.addCssClass(t?"ag-rtl":"ag-ltr");const i=this.createBean(new ft(e));this.chartController=this.createManagedBean(new Gt(i)),this.chartOptionsService=this.createManagedBean(new Rn(this.chartController)),this.validateCustomThemes(),this.createChart(),this.params.insideDialog&&this.addDialog(),this.addMenu(),this.addTitleEditComp(),this.addManagedListener(this.getGui(),"focusin",this.setActiveChartCellRange.bind(this)),this.addManagedListener(this.chartController,Gt.EVENT_CHART_MODEL_UPDATE,this.update.bind(this)),this.addManagedPropertyListeners(["chartThemeOverrides","chartThemes"],this.reactivePropertyUpdate.bind(this)),this.update(),this.raiseChartCreatedEvent()}createChart(){var t;let i;this.chartProxy&&(i=this.chartProxy.destroy({keepChartInstance:!0}));const r=this.chartController.getChartType(),n={chartType:r,chartInstance:i,getChartThemeName:this.getChartThemeName.bind(this),getChartThemes:this.getChartThemes.bind(this),customChartThemes:this.gos.get("customChartThemes"),getGridOptionsChartThemeOverrides:()=>this.getGridOptionsChartThemeOverrides(),getExtraPaddingDirections:()=>{var e,t;return null!=(t=null==(e=this.chartMenu)?void 0:e.getExtraPaddingDirections())?t:[]},apiChartThemeOverrides:this.params.chartThemeOverrides,crossFiltering:null!=(t=this.params.crossFiltering)&&t,crossFilterCallback:(e,t)=>{this.params.crossFilteringContext.lastSelectedChartId=t?"":this.chartController.getChartId(),t&&this.params.crossFilteringResetCallback(),this.crossFilterService.filter(e,t)},parentElement:this.eChart,grouping:this.chartController.isGrouping(),chartThemeToRestore:this.params.chartThemeName,chartOptionsToRestore:this.params.chartOptionsToRestore,chartPaletteToRestore:this.params.chartPaletteToRestore,seriesChartTypes:this.chartController.getSeriesChartTypes(),translate:e=>this.chartTranslationService.translate(e)};if(this.params.chartOptionsToRestore=void 0,this.chartType=r,this.chartProxy=e.createChartProxy(n),!this.chartProxy)return void console.warn("AG Grid: invalid chart type supplied: ",n.chartType);const s=this.eChart.querySelector("canvas");s&&s.classList.add("ag-charts-canvas"),this.chartController.setChartProxy(this.chartProxy),this.createMenuContext(),this.titleEdit&&this.titleEdit.refreshTitle(this.chartMenuContext)}createMenuContext(){if(this.chartMenuContext)return;const e=this.createManagedBean(new hi(this.chartOptionsService.getChartThemeOverridesProxy())),t=this.createManagedBean(new hi(this.chartOptionsService.getAxisThemeOverridesProxy()));this.chartMenuContext={chartController:this.chartController,chartOptionsService:this.chartOptionsService,chartMenuParamsFactory:e,chartAxisMenuParamsFactory:t}}getChartThemeName(){return this.chartController.getChartThemeName()}getChartThemes(){return this.chartController.getThemeNames()}getGridOptionsChartThemeOverrides(){return this.gos.get("chartThemeOverrides")}static createChartProxy(e){switch(e.chartType){case"column":case"bar":case"groupedColumn":case"stackedColumn":case"normalizedColumn":case"groupedBar":case"stackedBar":case"normalizedBar":return new hn(e);case"pie":case"donut":case"doughnut":return new fn(e);case"area":case"stackedArea":case"normalizedArea":return new dn(e);case"line":return new pn(e);case"scatter":case"bubble":return new mn(e);case"histogram":return new yn(e);case"radarLine":case"radarArea":case"nightingale":case"radialColumn":case"radialBar":return new gn(e);case"rangeBar":case"rangeArea":return new Cn(e);case"boxPlot":return new wn(e);case"treemap":case"sunburst":return new Fn(e);case"heatmap":return new Sn(e);case"waterfall":return new An(e);case"columnLineCombo":case"areaColumnCombo":case"customCombo":return new _n(e);default:throw`AG Grid: Unable to create chart as an invalid chartType = '${e.chartType}' was supplied.`}}addDialog(){const e=this.chartTranslationService.translate(this.params.pivotChart?"pivotChartTitle":"rangeChartTitle"),{width:t,height:i}=this.getBestDialogSize();this.chartDialog=new r.fNJ({resizable:!0,movable:!0,maximizable:!0,title:e,width:t,height:i,component:this,centered:!0,closable:!0}),this.getContext().createBean(this.chartDialog),this.chartDialog.addEventListener(r.fNJ.EVENT_DESTROYED,()=>{this.destroy(),this.chartMenuService.hideAdvancedSettings()})}getBestDialogSize(){const e=this.popupService.getPopupParent(),t=.75*r._.getAbsoluteWidth(e),i=.75*r._.getAbsoluteHeight(e),n=this.chartProxy.getChart();let s=this.params.insideDialog?850:n.width,o=this.params.insideDialog?470:n.height;return(s>t||o>i)&&(s=Math.min(s,t),o=Math.round(.553*s),o>i&&(o=i,s=Math.min(s,Math.round(o/.553)))),{width:s,height:o}}addMenu(){this.params.crossFiltering||(this.chartMenu=this.createBean(new tn(this.eChartContainer,this.eMenuContainer,this.chartMenuContext)),this.eChartContainer.appendChild(this.chartMenu.getGui()))}addTitleEditComp(){this.titleEdit=this.createBean(new nn(this.chartMenu)),this.eTitleEditContainer.appendChild(this.titleEdit.getGui()),this.chartProxy&&this.titleEdit.refreshTitle(this.chartMenuContext)}update(e){if((null==e?void 0:e.chartId)&&!this.chartController.update(e))return;const t=this.chartTypeChanged(e),i=t||this.chartEmpty?(e=>{const t=this.chartType,i=e,r=this.chartProxy.getChart(),n=null==r?void 0:r.getOptions(),s=null==r?void 0:r.axes;return this.chartOptionsService.getPersistedChartThemeOverrides(n,s,t,null!=i?i:t)})(t):void 0;t&&this.createChart();const r=i&&(null==e?void 0:e.chartThemeOverrides)?bt(i,e.chartThemeOverrides):i||(null==e?void 0:e.chartThemeOverrides);this.updateChart(r),(null==e?void 0:e.chartId)&&this.chartProxy.getChart().waitForUpdate().then(()=>{this.chartController.raiseChartApiUpdateEvent()})}updateChart(e){const{chartProxy:t}=this,i=this.chartController.getSelectedValueColState(),r=this.chartController.getChartData(),n=this.handleEmptyChart(r,i.length);if(this.chartEmpty=n,n)return void(e&&this.chartController.updateThemeOverrides(e));let s=this.chartController.getChartUpdateParams(e);t.update(s),this.chartProxy.getChart().waitForUpdate().then(()=>{this.chartController.raiseChartUpdatedEvent()}),this.titleEdit.refreshTitle(this.chartMenuContext)}chartTypeChanged(e){const[t,i]=[this.chartController.getChartType(),null==e?void 0:e.chartType],r=i?at(i):void 0;return this.chartType!==t?null!=r?r:t:r&&t!==r?r:null}getChartModel(){return this.chartController.getChartModel()}getChartImageDataURL(e){return this.chartProxy.getChartImageDataURL(e)}handleEmptyChart(e,t){const i=this.chartController.isPivotChart()&&!this.chartController.isPivotMode(),n=this.chartController.getChartType();let s=1;this.chartController.isActiveXYChart()?s="bubble"===n?3:2:ot(ct(n))&&(s=0);const o=t<s||0===e.length;if(this.eChart){const e=i||o;r._.setDisplayed(this.eChart,!e),r._.setDisplayed(this.eEmpty,e)}return i?(this.eEmpty.innerText=this.chartTranslationService.translate("pivotChartRequiresPivotMode"),!0):!!o&&(this.eEmpty.innerText=this.chartTranslationService.translate("noDataToChart"),!0)}downloadChart(e,t,i){this.chartProxy.downloadChart(e,t,i)}openChartToolPanel(e){const t=e?Dn[e]:e;this.chartMenu.showMenu({panel:t})}closeChartToolPanel(){this.chartMenu.hideMenu()}getChartId(){return this.chartController.getChartId()}getUnderlyingChart(){return this.chartProxy.getChartRef()}crossFilteringReset(){this.chartProxy.crossFilteringReset()}setActiveChartCellRange(e){this.getGui().contains(e.relatedTarget)||(this.chartController.setChartRange(!0),this.focusService.clearFocusedCell())}getThemeName(){const e=this.gos.get("chartThemes")||Ft;if(0===e.length)throw new Error("Cannot create chart: no chart themes available.");const{chartThemeName:t}=this.params;return r._.includes(e,t)?t:e[0]}getAllKeysInObjects(e){const t={};return e.filter(e=>null!=e).forEach(e=>{Object.keys(e).forEach(e=>t[e]=null)}),Object.keys(t)}validateCustomThemes(){const e=this.getChartThemes(),t=this.gos.get("customChartThemes");t&&this.getAllKeysInObjects([t]).forEach(t=>{r._.includes(e,t)||console.warn("AG Grid: a custom chart theme with the name '"+t+"' has been supplied but not added to the 'chartThemes' list")})}reactivePropertyUpdate(){this.chartController.setChartThemeName(this.getThemeName(),!0);const e=this.getChartId(),t=this.chartController.isCrossFilterChart()?"crossFilter":this.getChartModel().modelType,i=this.gos.get("chartThemeOverrides")||{};this.update({type:`${t}ChartUpdate`,chartId:e,chartThemeOverrides:i})}raiseChartCreatedEvent(){const e={type:r.sVA.EVENT_CHART_CREATED,chartId:this.chartController.getChartId()};this.chartProxy.getChart().waitForUpdate().then(()=>{this.eventService.dispatchEvent(e)})}raiseChartDestroyedEvent(){const e={type:r.sVA.EVENT_CHART_DESTROYED,chartId:this.chartController.getChartId()};this.eventService.dispatchEvent(e)}destroy(){var e;super.destroy(),this.chartProxy&&this.chartProxy.destroy(),this.destroyBean(this.chartMenu),this.destroyBean(this.titleEdit),this.chartDialog&&this.chartDialog.isAlive()&&this.destroyBean(this.chartDialog),null==(e=this.onDestroyColorSchemeChangeListener)||e.call(this);const t=this.getGui();r._.clearElement(t),r._.removeFromParent(t),this.raiseChartDestroyedEvent()}};kn.TEMPLATE='<div class="ag-chart" tabindex="-1">\n            <div ref="eChartContainer" tabindex="-1" class="ag-chart-components-wrapper">\n                <div ref="eChart" class="ag-chart-canvas-wrapper"></div>\n                <div ref="eEmpty" class="ag-chart-empty-text ag-unselectable"></div>\n            </div>\n            <div ref="eTitleEditContainer"></div>\n            <div ref="eMenuContainer" class="ag-chart-docked-container" style="min-width: 0px;"></div>\n        </div>',qe([(0,r.PIB)("eChart")],kn.prototype,"eChart",2),qe([(0,r.PIB)("eChartContainer")],kn.prototype,"eChartContainer",2),qe([(0,r.PIB)("eMenuContainer")],kn.prototype,"eMenuContainer",2),qe([(0,r.PIB)("eEmpty")],kn.prototype,"eEmpty",2),qe([(0,r.PIB)("eTitleEditContainer")],kn.prototype,"eTitleEditContainer",2),qe([(0,r.dsm)("chartCrossFilterService")],kn.prototype,"crossFilterService",2),qe([(0,r.dsm)("chartTranslationService")],kn.prototype,"chartTranslationService",2),qe([(0,r.dsm)("chartMenuService")],kn.prototype,"chartMenuService",2),qe([(0,r.dsm)("focusService")],kn.prototype,"focusService",2),qe([(0,r.dsm)("popupService")],kn.prototype,"popupService",2),qe([r.o7C],kn.prototype,"init",1);var Gn=kn,Vn="31.3.4";function Hn(e){return e=os("chartOptions.legend.item.marker.type","shape",e),e=os("chartOptions.seriesDefaults.marker.type","shape",e),os("chartOptions.legend.padding","spacing",e)}function Bn(e){var t;const i=e=as("chartOptions.seriesDefaults.marker.minSize",e),{chartType:r,chartPalette:n,chartOptions:s}=i,o=s,{xAxis:a,yAxis:l}=o,c=$e(o,["xAxis","yAxis"]),u=$e(i,["chartType","chartPalette","chartOptions"]),h=function(e){switch(e){case"bar":case"stackedBar":case"normalizedBar":return["number","category"];case"groupedBar":return["number","grouped-category"];case"column":case"stackedColumn":case"normalizedColumn":case"line":case"area":case"stackedArea":case"normalizedArea":case"histogram":return["category","number"];case"groupedColumn":return["grouped-category","number"];case"scatter":case"bubble":return["number","number"];default:return}}(r),d=null==h?void 0:h.map((e,t)=>je({type:e},0===t?a:l));return je({chartType:r,chartThemeName:null!=(t={borneo:"ag-default",material:"ag-material",bright:"ag-vivid"}[n])?t:"ag-default",chartOptions:Ke(je({},c),{axes:d,xAxis:a,yAxis:l})},u)}function zn(e){return os("chartOptions.seriesDefaults.label.minRequiredAngle","minAngle",e)}function Un(e){return e=as("chart",e=cs("chartOptions.seriesDefaults.highlightStyle",e,e=>{var t=e,{dimOpacity:i}=t,r=$e(t,["dimOpacity"]);return je(je({},r),null!=i?{series:{dimOpacity:i}}:{})})),e=as("chartOptions.seriesDefaults.tooltipClass",e),e=ts("chartOptions.axes[].label.rotation",0,e=as("chartOptions.seriesDefaults.tooltipTracking",e)),ts("chartOptions.axes[].label.rotation",335,e)}function Wn(e){const t=e=>{var t=e,{item:i,series:r}=t,n=$e(t,["item","series"]);return je({item:je(je({},n),i)},r?{series:r}:{})};return e=cs("chartOptions.seriesDefaults.highlightStyle",e,t),cs("chartOptions.series[].highlightStyle",e,t)}function jn(e){e=ns("chartOptions.seriesDefaults.fill.opacity","chartOptions.seriesDefaults.fillOpacity",e),e=ns("chartOptions.seriesDefaults.stroke.opacity","chartOptions.seriesDefaults.strokeOpacity",e),e=as("chartOptions.seriesDefaults.fill",e=ns("chartOptions.seriesDefaults.stroke.width","chartOptions.seriesDefaults.strokeWidth",e)),e=as("chartOptions.seriesDefaults.stroke",e),e=as("chartOptions.seriesDefaults.callout.colors",e),e=as("chartOptions.xAxis",e);const t=e=as("chartOptions.yAxis",e),{chartType:i,chartOptions:r}=t,n=r,{axes:s,series:o,seriesDefaults:a}=n,l=$e(n,["axes","series","seriesDefaults"]),c=$e(t,["chartType","chartOptions"]),u=at(i),h=ct(u),d=[h],p={};if(!ut(h)){const e={top:{},bottom:{},left:{},right:{}},t=s.map(t=>{var i=t,{type:r}=i,n=$e(i,["type"]);return{[r]:je(je({},e),n)}}).reduce(us,{});mt.filter(e=>null==t[e]).forEach(i=>{t[i]=je({},e)}),p.axes=t}const g=d.map(e=>({[e]:je(Ke(je({},p),{series:a}),l)})).reduce(us,{});return Ke(je({},c),{chartType:u,chartOptions:g})}function Kn(e){return e=as("chartOptions.*.title.padding",e),e=as("chartOptions.*.subtitle.padding",e),is("chartOptions.*.axes.*.title.enabled",!1,e=as("chartOptions.*.axes.*.title.padding",e))}function $n(e){return e=os("chartOptions.pie.series.callout","calloutLine",e),e=os("chartOptions.pie.series.label","calloutLabel",e),e=os("chartOptions.pie.series.labelKey","sectorLabelKey",e),e=os("chartOptions.pie.series.labelName","sectorLabelName",e),e=os("chartOptions.donut.series.callout","calloutLine",e),e=os("chartOptions.donut.series.label","calloutLabel",e),e=os("chartOptions.donut.series.labelKey","sectorLabelKey",e),os("chartOptions.donut.series.labelName","sectorLabelName",e)}function qn(e){return e=ss("chartOptions.scatter.series.fill","chartOptions.scatter.series.marker.fill",e),e=ss("chartOptions.scatter.series.fillOpacity","chartOptions.scatter.series.marker.fillOpacity",e),e=ss("chartOptions.scatter.series.stroke","chartOptions.scatter.series.marker.stroke",e),e=ss("chartOptions.scatter.series.strokeOpacity","chartOptions.scatter.series.marker.strokeOpacity",e),ns("chartOptions.scatter.series.paired","chartOptions.scatter.paired",e=ss("chartOptions.scatter.series.strokeWidth","chartOptions.scatter.series.marker.strokeWidth",e))}function Yn(e){return as("chartOptions.axes[].tick.count",e)}function Qn(e){return cs("chartOptions.*.tooltip",e,e=>{var t=e,{tracking:i}=t,r=$e(t,["tracking"]);const n=je({},r);return!1===i?(null!=n.position||(n.position={type:"pointer"}),null!=n.range||(n.range="nearest")):!0===i&&(null!=n.position||(n.position={type:"node"}),null!=n.range||(n.range="nearest")),n})}function Xn(e){return e=os("chartOptions.pie.series.labelKey","sectorLabelKey",e),is("chartOptions.common.legend.position","right",e=rs("chartOptions.common.legend.enabled",!0,e=as("chartOptions.*.series.flipXY",e=Qn(e=Yn(e=os("chartOptions.pie.series.labelName","sectorLabelName",e))))))}function Zn(e){const t=os("chartOptions.column","bar",e),i={"ag-pastel":"ag-sheets","ag-solar":"ag-polychroma"}[t.chartThemeName]||t.chartThemeName;return Ke(je({},t),{chartThemeName:i})}function Jn(e,t,i){if(es(e)>es(t.version)){const r=i(t);return r.version=e,r}return t}function es(e){const{major:t,minor:i,patch:r}=function(e){const t="string"==typeof e?e.split(".").map(e=>Number(e)):[];if(3!==t.length||t.some(e=>isNaN(e)))throw new Error("AG Grid - Illegal version string: "+e);return{major:t[0],minor:t[1],patch:t[2]}}(e);return 1e4*t+100*i+r}function ts(e,t,i){return ls(e,!0,i,(e,i)=>{e[i]===t&&delete e[i]})}function is(e,t,i){return ls(e,!1,i,(e,i)=>{null==e[i]&&(e[i]=t)})}function rs(e,t,i){var r;"string"==typeof e&&(e=e.split("."));const n=e[0];return e.length>1&&(i[n]=rs(e.slice(1),t,null!=(r=i[n])?r:{})),Object.keys(i).includes(n)||(i[n]=t),i}function ns(e,t,i){let r,n=!1;return i=ls(e,!0,i,(e,t)=>{n=!0,r=e[t],delete e[t]}),n?ls(t,!1,i,(e,t)=>{e[t]=r}):i}function ss(e,t,i){let r,n=!1;return i=ls(e,!0,i,(e,t)=>{n=!0,r=e[t],delete e[t]}),n?ls(t,!1,i,(e,t)=>{void 0===e[t]&&(e[t]=r)}):i}function os(e,t,i){return ls(e,!0,i,(e,i)=>{e[t]=e[i],delete e[i]})}function as(e,t){return ls(e,!0,t,(e,t)=>delete e[t])}function ls(e,t,i,r){const n=e instanceof Array?e:e.split("."),s=n.slice(0,n.length-1),o=n[n.length-1];return cs(s,i,e=>{const i=Object.keys(e).includes(o);if(t&&!i)return e;const n=je({},e);return r(n,o),n})}function cs(e,t,i){const r=e instanceof Array?e:e.split(".");if(t=je({},t),0===r.length)return i(t);if(r[0].startsWith("{")){const e=r[0].substring(1,r[0].lastIndexOf("}")).split(",");for(const n of e)null!=t[n]&&(t[n]=cs(r.slice(1),t[n],i))}else if(r[0].endsWith("[]")){const n=r[0].substring(0,e[0].indexOf("["));t[n]instanceof Array&&(t[n]=t[n].map(e=>cs(r.slice(1),e,i)))}else if("*"===r[0])for(const e in t)t[e]=cs(r.slice(1),t[e],i);else null!=t[r[0]]&&(t[r[0]]=cs(r.slice(1),t[r[0]],i));return t}var us=(e,t)=>je(je({},e),t),hs=class extends r.XQb{constructor(){super(...arguments),this.activeCharts=new Set,this.activeChartComps=new Set,this.crossFilteringContext={lastSelectedChartId:""},this.isEnterprise=()=>n._ModuleSupport.enterpriseModule.isEnterprise}updateChart(e){if(0===this.activeChartComps.size)return void console.warn("AG Grid - No active charts to update.");const t=[...this.activeChartComps].find(t=>t.getChartId()===e.chartId);t?t.update(e):console.warn(`AG Grid - Unable to update chart. No active chart found with ID: ${e.chartId}.`)}getChartModels(){const e=[];return this.activeChartComps.forEach(t=>e.push((e=>Ke(je({},e),{version:Vn}))(t.getChartModel()))),e}getChartRef(e){let t;return this.activeCharts.forEach(i=>{i.chartId===e&&(t=i)}),t}getChartComp(e){let t;return this.activeChartComps.forEach(i=>{i.getChartId()===e&&(t=i)}),t}getChartImageDataURL(e){let t;return this.activeChartComps.forEach(i=>{i.getChartId()===e.chartId&&(t=i.getChartImageDataURL(e.fileFormat))}),t}downloadChart(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e.chartId);null==t||t.downloadChart(e.dimensions,e.fileName,e.fileFormat)}openChartToolPanel(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e.chartId);null==t||t.openChartToolPanel(e.panel)}closeChartToolPanel(e){const t=Array.from(this.activeChartComps).find(t=>t.getChartId()===e);null==t||t.closeChartToolPanel()}createChartFromCurrentRange(e="groupedColumn"){const t=this.getSelectedRange();return this.createChart({cellRange:t,chartType:e})}restoreChart(e,t){if(!e)return void console.warn("AG Grid - unable to restore chart as no chart model is provided");let i,r,n,s;return e.version!==Vn&&(e=function(e){return e.version,null==e.version&&(e.version=function(e){var t,i;const r=e;if(null!=e.version)return e.version;const n=(e,...t)=>Object.keys(e||{}).some(e=>t.includes(e)),s=r.chartOptions,o=n(s,"seriesDefaults")?null==s?void 0:s.seriesDefaults:null==s?void 0:s[Object.keys(s)[0]],a={"27.0.0":n(r,"seriesChartTypes"),"26.2.0":!n(s,"seriesDefaults"),"26.1.0":n(null==o?void 0:o.highlightStyle,"item"),"26.0.0":n(null==o?void 0:o.highlightStyle,"series"),"25.1.0":n(null==o?void 0:o.label,"minAngle"),"25.0.0":n(r,"modelType","aggFunc","unlinkChart","suppressChartRanges")||n(o,"lineDash","lineDashOffset"),"24.0.0":n(r,"chartThemeName","chart")||n(s,"series"),"23.2.0":n(s,"navigator"),"23.0.0":n(null==(i=null==(t=null==s?void 0:s.legend)?void 0:t.item)?void 0:i.marker,"shape"),"22.1.0":n(r,"chartPalette","chartType")},l="27.1.0",c=Object.entries(a).filter(([e,t])=>t),[u=l]=c[0];return u}(e)),e=Jn("23.0.0",e,Hn),e=Jn("24.0.0",e,Bn),e=Jn("25.1.0",e,zn),e=Jn("26.0.0",e,Un),e=Jn("26.1.0",e,Wn),e=Jn("26.2.0",e,jn),e=Jn("28.0.0",e,Kn),e=Jn("28.2.0",e,$n),e=Jn("29.0.0",e,qn),e=Jn("29.1.0",e,Yn),e=Jn("29.2.0",e,Qn),e=Jn("30.0.0",e,Xn),e=function(e){return e=as("chartOptions.*.width",e),is("chartOptions.*.axes.category.label.autoRotate",!0,e=as("chartOptions.*.height",e))}(e=Jn("31.0.0",e,Zn)),Jn(Vn,e,e=>e)}(e)),"pivot"===e.modelType?(this.gos.updateGridOptions({options:{pivotMode:!0},source:"pivotChart"}),i=this.createCellRange(void 0,!0),r=!0,n=!0):(i=this.createCellRange(e.cellRange),s=e.chartPalette),i?this.createChart(Ke(je({},e),{cellRange:i,pivotChart:r,suppressChartRanges:n,chartContainer:t,chartOptionsToRestore:e.chartOptions,chartPaletteToRestore:s})):void 0}createRangeChart(e){const t=this.createCellRange(e.cellRange);if(t)return this.createChart(Ke(je({},e),{cellRange:t}))}createPivotChart(e){this.gos.updateGridOptions({options:{pivotMode:!0},source:"pivotChart"});const t=this.createCellRange(void 0,!0);if(t)return this.createChart(Ke(je({},e),{cellRange:t,pivotChart:!0,suppressChartRanges:!0}))}createCrossFilterChart(e){const t=this.createCellRange(e.cellRange);if(!t)return;const i=!(void 0!==e.suppressChartRanges&&null!==e.suppressChartRanges)||e.suppressChartRanges;return this.createChart(Ke(je({},e),{cellRange:t,suppressChartRanges:i,crossFiltering:!0}))}createChart(e){const t=Ot.validateCreateParams(e);if(!t)return;e=!0===t?e:t;const{chartType:i,chartContainer:r}=e,n=this.gos.getCallback("createChartContainer"),s=Ke(je({},e),{chartId:this.generateId(),chartType:at(i),insideDialog:!(r||n),crossFilteringContext:this.crossFilteringContext,crossFilteringResetCallback:()=>this.activeChartComps.forEach(e=>e.crossFilteringReset())}),o=new Gn(s);this.context.createBean(o);const a=this.createChartRef(o);if(r){r.appendChild(o.getGui());const e=this.environment.getTheme();e.el&&!e.el.contains(r)&&r.classList.add(e.theme)}else n?n(a):o.addEventListener(Gn.EVENT_DESTROYED,()=>{this.activeChartComps.delete(o),this.activeCharts.delete(a)});return a}createChartRef(e){const t={destroyChart:()=>{this.activeCharts.has(t)&&(this.context.destroyBean(e),this.activeChartComps.delete(e),this.activeCharts.delete(t))},chartElement:e.getGui(),chart:e.getUnderlyingChart(),chartId:e.getChartModel().chartId};return this.activeCharts.add(t),this.activeChartComps.add(e),t}getSelectedRange(){var e,t;const i=null!=(t=null==(e=this.rangeService)?void 0:e.getCellRanges())?t:[];return i.length>0?i[0]:{columns:[]}}generateId(){return`id-${Math.random().toString(36).substring(2,18)}`}createCellRange(e,t){var i;const r=t?{rowStartIndex:null,rowStartPinned:void 0,rowEndIndex:null,rowEndPinned:void 0,columns:this.columnModel.getAllDisplayedColumns().map(e=>e.getColId())}:e,n=r&&(null==(i=this.rangeService)?void 0:i.createPartialCellRangeFromRangeParams(r,!0));return n||console.warn(`AG Grid - unable to create chart as ${t?"there are no columns in the grid":"no range is selected"}.`),n}destroyAllActiveCharts(){this.activeCharts.forEach(e=>e.destroyChart())}};hs.CHARTS_VERSION=n.VERSION,qe([(0,r.dsm)("columnModel")],hs.prototype,"columnModel",2),qe([(0,r.Xx1)("rangeService")],hs.prototype,"rangeService",2),qe([r.yah],hs.prototype,"destroyAllActiveCharts",1),hs=qe([(0,r.dR4)("chartService")],hs);var ds=class extends r.XQb{translate(e){return this.localeService.getLocaleTextFunc()(e,ds.DEFAULT_TRANSLATIONS[e])}};ds.DEFAULT_TRANSLATIONS={pivotChartTitle:"Pivot Chart",rangeChartTitle:"Range Chart",settings:"Chart",data:"Data",format:"Format",categories:"Categories",defaultCategory:"(None)",series:"Series",switchCategorySeries:"Switch Category / Series",categoryValues:"Category Values",seriesLabels:"Series Labels",aggregate:"Aggregate",xyValues:"X Y Values",paired:"Paired Mode",axis:"Axis",xAxis:"Horizontal Axis",yAxis:"Vertical Axis",polarAxis:"Polar Axis",radiusAxis:"Radius Axis",navigator:"Navigator",zoom:"Zoom",animation:"Animation",crosshair:"Crosshair",color:"Color",thickness:"Thickness",preferredLength:"Preferred Length",xType:"X Type",axisType:"Axis Type",automatic:"Automatic",category:"Category",number:"Number",time:"Time",timeFormat:"Time Format",autoRotate:"Auto Rotate",labelRotation:"Rotation",circle:"Circle",orientation:"Orientation",polygon:"Polygon",fixed:"Fixed",parallel:"Parallel",perpendicular:"Perpendicular",radiusAxisPosition:"Position",ticks:"Ticks",gridLines:"Grid Lines",width:"Width",height:"Height",length:"Length",padding:"Padding",spacing:"Spacing",chart:"Chart",title:"Title",titlePlaceholder:"Chart title - double click to edit",background:"Background",font:"Font",top:"Top",right:"Right",bottom:"Bottom",left:"Left",labels:"Labels",calloutLabels:"Callout Labels",sectorLabels:"Sector Labels",positionRatio:"Position Ratio",size:"Size",shape:"Shape",minSize:"Minimum Size",maxSize:"Maximum Size",legend:"Legend",position:"Position",markerSize:"Marker Size",markerStroke:"Marker Stroke",markerPadding:"Marker Padding",itemSpacing:"Item Spacing",itemPaddingX:"Item Padding X",itemPaddingY:"Item Padding Y",layoutHorizontalSpacing:"Horizontal Spacing",layoutVerticalSpacing:"Vertical Spacing",strokeWidth:"Stroke Width",offset:"Offset",offsets:"Offsets",tooltips:"Tooltips",callout:"Callout",markers:"Markers",shadow:"Shadow",blur:"Blur",xOffset:"X Offset",yOffset:"Y Offset",lineWidth:"Line Width",lineDash:"Line Dash",lineDashOffset:"Dash Offset",scrollingZoom:"Scrolling",scrollingStep:"Scrolling Step",selectingZoom:"Selecting",durationMillis:"Duration (ms)",crosshairLabel:"Label",crosshairSnap:"Snap to Node",normal:"Normal",bold:"Bold",italic:"Italic",boldItalic:"Bold Italic",predefined:"Predefined",fillOpacity:"Fill Opacity",strokeColor:"Line Color",strokeOpacity:"Line Opacity",miniChart:"Mini-Chart",histogramBinCount:"Bin count",connectorLine:"Connector Line",seriesItems:"Series Items",seriesItemType:"Item Type",seriesItemPositive:"Positive",seriesItemNegative:"Negative",seriesItemLabels:"Item Labels",columnGroup:"Column",barGroup:"Bar",pieGroup:"Pie",lineGroup:"Line",scatterGroup:"X Y (Scatter)",areaGroup:"Area",polarGroup:"Polar",statisticalGroup:"Statistical",hierarchicalGroup:"Hierarchical",specializedGroup:"Specialized",combinationGroup:"Combination",groupedColumnTooltip:"Grouped",stackedColumnTooltip:"Stacked",normalizedColumnTooltip:"100% Stacked",groupedBarTooltip:"Grouped",stackedBarTooltip:"Stacked",normalizedBarTooltip:"100% Stacked",pieTooltip:"Pie",donutTooltip:"Donut",lineTooltip:"Line",groupedAreaTooltip:"Area",stackedAreaTooltip:"Stacked",normalizedAreaTooltip:"100% Stacked",scatterTooltip:"Scatter",bubbleTooltip:"Bubble",histogramTooltip:"Histogram",radialColumnTooltip:"Radial Column",radialBarTooltip:"Radial Bar",radarLineTooltip:"Radar Line",radarAreaTooltip:"Radar Area",nightingaleTooltip:"Nightingale",rangeBarTooltip:"Range Bar",rangeAreaTooltip:"Range Area",boxPlotTooltip:"Box Plot",treemapTooltip:"Treemap",sunburstTooltip:"Sunburst",heatmapTooltip:"Heatmap",waterfallTooltip:"Waterfall",columnLineComboTooltip:"Column & Line",areaColumnComboTooltip:"Area & Column",customComboTooltip:"Custom Combination",innerRadius:"Inner Radius",startAngle:"Start Angle",endAngle:"End Angle",reverseDirection:"Reverse Direction",groupPadding:"Group Padding",seriesPadding:"Series Padding",group:"Group",tile:"Tile",whisker:"Whisker",cap:"Cap",capLengthRatio:"Length Ratio",labelPlacement:"Placement",inside:"Inside",outside:"Outside",noDataToChart:"No data available to be charted.",pivotChartRequiresPivotMode:"Pivot Chart requires Pivot Mode enabled.",chartSettingsToolbarTooltip:"Menu",chartLinkToolbarTooltip:"Linked to Grid",chartUnlinkToolbarTooltip:"Unlinked from Grid",chartDownloadToolbarTooltip:"Download Chart",chartMenuToolbarTooltip:"Menu",chartEdit:"Edit Chart",chartAdvancedSettings:"Advanced Settings",chartLink:"Link to Grid",chartUnlink:"Unlink from Grid",chartDownload:"Download Chart",histogramFrequency:"Frequency",seriesChartType:"Series Chart Type",seriesType:"Series Type",secondaryAxis:"Secondary Axis",seriesAdd:"Add a series",categoryAdd:"Add a category",area:"Area",bar:"Bar",column:"Column",line:"Line",scatter:"Scatter",histogram:"Histogram",radialColumn:"Radial Column",radialBar:"Radial Bar",radarLine:"Radar Line",radarArea:"Radar Area",nightingale:"Nightingale",rangeBar:"Range Bar",rangeArea:"Range Area",treemap:"Treemap",sunburst:"Sunburst",waterfall:"Waterfall",boxPlot:"Box Plot",pie:"Pie",donut:"Donut",stackedArea:"StackedArea",groupedColumn:"Grouped Column",stackedColumn:"Stacked Column",advancedSettings:"Advanced Settings",ariaChartMenuClose:"Close Chart Edit Menu",timeFormatSlashesDDMMYYYY:"DD/MM/YYYY",timeFormatSlashesMMDDYYYY:"MM/DD/YYYY",timeFormatSlashesDDMMYY:"DD/MM/YY",timeFormatSlashesMMDDYY:"MM/DD/YY",timeFormatDotsDDMYY:"DD.M.YY",timeFormatDotsMDDYY:"M.DD.YY",timeFormatDashesYYYYMMDD:"YYYY-MM-DD",timeFormatSpacesDDMMMMYYYY:"DD MMMM YYYY",timeFormatHHMMSS:"HH:MM:SS",timeFormatHHMMSSAmPm:"HH:MM:SS AM/PM",sum:"Sum",first:"First",last:"Last",min:"Min",max:"Max",count:"Count",avg:"Average",direction:"Direction",horizontal:"Horizontal",vertical:"Vertical",seriesGroupType:"Group Type",groupedSeriesGroupType:"Grouped",stackedSeriesGroupType:"Stacked",normalizedSeriesGroupType:"100% Stacked"},ds=qe([(0,r.dR4)("chartTranslationService")],ds);var ps=class extends r.XQb{filter(e,t=!1){const i=this.gridApi.getFilterModel();if(t)return void this.resetFilters(i);let r=ps.extractFilterColId(e);this.isValidColumnFilter(r)?this.updateFilters(i,e,r):console.warn("AG Grid: cross filtering requires a 'agSetColumnFilter' or 'agMultiColumnFilter' to be defined on the column with id: '"+r+"'")}resetFilters(e){Object.keys(e).length>0&&(this.gridApi.setFilterModel(null),this.gridApi.onFilterChanged())}updateFilters(e,t,i){let n=ps.extractFilterColId(t),s=t.datum[n];if(void 0===s)return;let o=s.toString();if(t.event.metaKey||t.event.ctrlKey){const t=this.getCurrentGridValuesForCategory(i);let n;r._.includes(t,o)?n=t.filter(e=>e!==o):(n=t,n.push(o)),e[i]=this.getUpdatedFilterModel(i,n)}else{const t=[o];e={[i]:this.getUpdatedFilterModel(i,t)}}this.gridApi.setFilterModel(e)}getUpdatedFilterModel(e,t){return"agMultiColumnFilter"===this.getColumnFilterType(e)?{filterType:"multi",filterModels:[null,{filterType:"set",values:t}]}:{filterType:"set",values:t}}getCurrentGridValuesForCategory(e){let t=[];const i=this.getColumnById(e);return this.gridApi.forEachNodeAfterFilter(e=>{if(i&&!e.group){const r=this.valueService.getValue(i,e)+"";t.includes(r)||t.push(r)}}),t}static extractFilterColId(e){return e.xKey||e.calloutLabelKey}isValidColumnFilter(e){e.indexOf("-filtered-out")&&(e=e.replace("-filtered-out",""));let t=this.getColumnFilterType(e);return"boolean"==typeof t?t:r._.includes(["agSetColumnFilter","agMultiColumnFilter"],t)}getColumnFilterType(e){let t=this.getColumnById(e);if(t)return t.getColDef().filter}getColumnById(e){return this.columnModel.getGridColumn(e)}};function gs(e){return e&&e.match(/\d+\.\d+\.\d+/)}function fs({type:e,gridVersion:t,chartsVersion:i}){const r="AG Grid: AG Grid version is incompatible. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.";if(!t)return r;const n=function(e){if(!e||!gs(e))return;const[t,i]=e.split(".")||[],r=`${t}.${i}.x`,n=parseInt(t,10)-28+6;return n<0?void 0:{gridMajorMinor:r,chartsMajorMinor:`${n}.${i}.x`}}(t);if(!n)return r;const{gridMajorMinor:s,chartsMajorMinor:o}=n;return"incompatible"===e?`AG Grid version ${t} and AG Charts version ${i} is not supported. AG Grid version ${s} should be used with AG Chart ${o}. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.`:"invalidCharts"===e?`AG Grid version ${s} should be used with AG Chart ${o}. Please see https://www.ag-grid.com/javascript-data-grid/modules/ for more information.`:r}qe([(0,r.dsm)("gridApi")],ps.prototype,"gridApi",2),qe([(0,r.dsm)("columnModel")],ps.prototype,"columnModel",2),qe([(0,r.dsm)("valueService")],ps.prototype,"valueService",2),ps=qe([(0,r.dR4)("chartCrossFilterService")],ps);var ms=class extends r.XQb{showMenuList(e){const{eventSource:t,showMenu:i,chartMenuContext:r}=e,n=this.chartMenuService.doChartToolPanelsExist(r.chartController),s=this.mapWithStockItems(this.getMenuItems(r.chartController,n),r,i,t,n);if(!s.length)return;const o=this.createBean(new vs(s));this.activeChartMenuList=o;let a=-1,l="left";this.gos.get("enableRtl")&&(a=1,l="right");const c=o.getGui();this.popupService.addPopup({modal:!0,eChild:c,closeOnEsc:!0,closedCallback:()=>{this.destroyBean(o),this.activeChartMenuList=void 0;const e=this.gos.getDocument(),i=this.gos.getActiveDomElement();i&&i!==e.body||t.focus({preventScroll:!0})},afterGuiAttached:e=>o.afterGuiAttached(e),positionCallback:()=>{this.popupService.positionPopupByComponent({type:"chartMenu",eventSource:t,ePopup:c,alignSide:l,nudgeX:4*a,nudgeY:4,position:"under",keepWithinBounds:!0})},ariaLabel:"Chart Menu"})}getMenuItems(e,t){const i=[...t?["chartEdit"]:[],...e.isEnterprise()?["chartAdvancedSettings"]:[],e.isChartLinked()?"chartUnlink":"chartLink","chartDownload"],r=this.gos.get("chartMenuItems");return r?Array.isArray(r)?r:r(this.gos.addGridCommonParams({defaultItems:i})):i}mapWithStockItems(e,t,i,r,n){if(!e)return[];const s=[];return e.forEach(e=>{let o;if(o="string"==typeof e?this.getStockMenuItem(e,t,i,r,n):je({},e),!o)return;const{subMenu:a}=o;Array.isArray(a)&&(o.subMenu=this.mapWithStockItems(a,t,i,r,n)),s.push(o)}),s}getStockMenuItem(e,t,i,r,n){switch(e){case"chartEdit":return n?this.createMenuItem(this.chartTranslationService.translate("chartEdit"),"chartsMenuEdit",i):null;case"chartAdvancedSettings":return this.createMenuItem(this.chartTranslationService.translate("chartAdvancedSettings"),"chartsMenuAdvancedSettings",()=>this.chartMenuService.openAdvancedSettings(t,r));case"chartUnlink":return t.chartController.isChartLinked()?this.createMenuItem(this.chartTranslationService.translate("chartUnlink"),"unlinked",()=>this.chartMenuService.toggleLinked(t)):null;case"chartLink":return t.chartController.isChartLinked()?null:this.createMenuItem(this.chartTranslationService.translate("chartLink"),"linked",()=>this.chartMenuService.toggleLinked(t));case"chartDownload":return this.createMenuItem(this.chartTranslationService.translate("chartDownload"),"save",()=>this.chartMenuService.downloadChart(t))}return null}createMenuItem(e,t,i){return{name:e,icon:r._.createIconNoSpan(t,this.gos,null),action:i}}destroy(){this.destroyBean(this.activeChartMenuList),super.destroy()}};qe([(0,r.dsm)("popupService")],ms.prototype,"popupService",2),qe([(0,r.dsm)("chartMenuService")],ms.prototype,"chartMenuService",2),qe([(0,r.dsm)("chartTranslationService")],ms.prototype,"chartTranslationService",2),ms=qe([(0,r.dR4)("chartMenuListFactory")],ms);var vs=class extends r.uAl{constructor(e){super('\n            <div ref="eChartsMenu" role="presentation" class="ag-menu ag-chart-menu-popup"></div>\n        '),this.menuItems=e}init(){this.mainMenuList=this.createManagedBean(new r.i9O(0)),this.mainMenuList.addMenuItems(this.menuItems),this.mainMenuList.addEventListener(r.yuY.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.eChartsMenu.appendChild(this.mainMenuList.getGui())}onHidePopup(){var e;null==(e=this.hidePopupFunc)||e.call(this)}afterGuiAttached({hidePopup:e}){e&&(this.hidePopupFunc=e,this.addDestroyFunc(e)),this.focusService.focusInto(this.mainMenuList.getGui())}};qe([(0,r.dsm)("focusService")],vs.prototype,"focusService",2),qe([(0,r.PIB)("eChartsMenu")],vs.prototype,"eChartsMenu",2),qe([r.o7C],vs.prototype,"init",1);var Cs=class e extends r.uAl{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("animation.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("animation"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultNumberInputParams("animation.duration","durationMillis",{min:0});this.setTemplate(e.TEMPLATE,{animationGroup:t,animationHeightInput:i})}};Cs.TEMPLATE='<div>\n            <ag-group-component ref="animationGroup">\n                <ag-input-number-field ref="animationHeightInput"></ag-input>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],Cs.prototype,"chartTranslationService",2),qe([r.o7C],Cs.prototype,"init",1);var ys=Cs,ws=class e extends r.uAl{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("crosshair.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("crosshair"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultCheckboxParams("crosshair.label.enabled","crosshairLabel"),r=this.chartMenuParamsFactory.getDefaultCheckboxParams("crosshair.snap","crosshairSnap"),n=this.chartMenuParamsFactory.getDefaultColorPickerParams("crosshair.stroke","color");this.setTemplate(e.TEMPLATE,{crosshairGroup:t,crosshairLabelCheckbox:i,crosshairSnapCheckbox:r,crosshairStrokeColorPicker:n})}};ws.TEMPLATE='<div>\n            <ag-group-component ref="crosshairGroup">\n                <ag-checkbox ref="crosshairLabelCheckbox"></ag-checkbox>\n                <ag-checkbox ref="crosshairSnapCheckbox"></ag-checkbox>\n                <ag-color-picker ref="crosshairStrokeColorPicker"></ag-color-picker>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],ws.prototype,"chartTranslationService",2),qe([r.o7C],ws.prototype,"init",1);var Ss=ws,bs=class e extends r.uAl{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("navigator.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("navigator"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultSliderParams("navigator.height","height",60);i.minValue=10;const r=this.chartMenuParamsFactory.getDefaultCheckboxParams("navigator.miniChart.enabled","miniChart");this.setTemplate(e.TEMPLATE,{navigatorGroup:t,navigatorHeightSlider:i,navigatorMiniChartCheckbox:r})}};bs.TEMPLATE='<div>\n            <ag-group-component ref="navigatorGroup">\n                <ag-slider ref="navigatorHeightSlider"></ag-slider>\n                <ag-checkbox ref="navigatorMiniChartCheckbox"></ag-checkbox>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],bs.prototype,"chartTranslationService",2),qe([r.o7C],bs.prototype,"init",1);var Es=bs,As=class e extends r.uAl{constructor(e){super(),this.chartMenuParamsFactory=e}init(){const t=this.chartMenuParamsFactory.addEnableParams("zoom.enabled",{cssIdentifier:"charts-advanced-settings-top-level",direction:"vertical",suppressOpenCloseIcons:!0,title:this.chartTranslationService.translate("zoom"),suppressEnabledCheckbox:!0,useToggle:!0}),i=this.chartMenuParamsFactory.getDefaultCheckboxParams("zoom.enableScrolling","scrollingZoom"),r=this.chartMenuParamsFactory.getDefaultSliderParams("zoom.scrollingStep","scrollingStep",1);r.step=.01,r.minValue=r.step;const n=this.chartMenuParamsFactory.getDefaultCheckboxParams("zoom.enableSelecting","selectingZoom");i.onValueChange=(e=>t=>{e&&(e(t),this.zoomScrollingStepInput.setDisabled(!t))})(i.onValueChange),this.setTemplate(e.TEMPLATE,{zoomGroup:t,zoomScrollingCheckbox:i,zoomScrollingStepInput:r,zoomSelectingCheckbox:n}),this.zoomScrollingStepInput.setDisabled(!i.value)}};As.TEMPLATE='<div>\n            <ag-group-component ref="zoomGroup">\n                <ag-checkbox ref="zoomSelectingCheckbox"></ag-checkbox>\n                <ag-checkbox ref="zoomScrollingCheckbox"></ag-checkbox>\n                <ag-slider ref="zoomScrollingStepInput"></ag-slider>\n            </ag-group-component>\n        </div>',qe([(0,r.dsm)("chartTranslationService")],As.prototype,"chartTranslationService",2),qe([(0,r.PIB)("zoomScrollingStepInput")],As.prototype,"zoomScrollingStepInput",2),qe([r.o7C],As.prototype,"init",1);var Ts=As,Ms=["navigator","zoom","animation","crosshair"],Rs=class e extends r.uAl{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}postConstruct(){this.chartPanelFeature=this.createManagedBean(new $i(this.chartMenuContext.chartController,this.getGui(),"ag-chart-advanced-settings-section",(e,t)=>this.createPanels(e,t))),this.chartPanelFeature.refreshPanels()}createPanels(e,t){Ms.forEach(e=>{if(!this.isGroupPanelShownForSeries(e,t))return;const i=this.createPanel(e);this.chartPanelFeature.addComponent(i)})}isGroupPanelShownForSeries(e,t){return"animation"===e||nt(t)}createPanel(e){const{chartMenuParamsFactory:t,chartAxisMenuParamsFactory:i}=this.chartMenuContext;switch(e){case"navigator":return new Es(t);case"zoom":return new Ts(t);case"animation":return new ys(t);case"crosshair":return new Ss(i)}}};Rs.TEMPLATE='<div class="ag-chart-advanced-settings-wrapper"></div>',qe([r.o7C],Rs.prototype,"postConstruct",1);var _s=Rs,Ps=class extends r.XQb{showMenu(e,t){this.hideMenu();const i=this.createBean(new Ds(e));this.activeDialog=this.createBean(new r.fNJ({title:this.chartTranslationService.translate("advancedSettings"),component:i,width:300,height:400,resizable:!0,movable:!0,centered:!0,closable:!0,afterGuiAttached:()=>{var e;null==(e=this.focusService.findFocusableElements(i.getGui())[0])||e.focus()},closedCallback:()=>{this.activeMenu=this.destroyBean(this.activeMenu),this.activeDialog=void 0,null==t||t.focus({preventScroll:!0})}})),this.activeMenu=i}hideMenu(){this.activeDialog&&this.destroyBean(this.activeDialog)}destroy(){this.activeMenu=this.destroyBean(this.activeMenu),this.activeDialog=this.destroyBean(this.activeDialog),super.destroy()}};qe([(0,r.dsm)("focusService")],Ps.prototype,"focusService",2),qe([(0,r.dsm)("chartTranslationService")],Ps.prototype,"chartTranslationService",2),Ps=qe([(0,r.dR4)("advancedSettingsMenuFactory")],Ps);var xs=class e extends r.aJZ{constructor(t){super(e.TEMPLATE),this.chartMenuContext=t}postConstruct(){this.advancedSettingsPanel=this.createManagedBean(new _s(this.chartMenuContext)),this.getGui().appendChild(this.advancedSettingsPanel.getGui()),this.initialiseTabGuard({onTabKeyDown:this.onTabKeyDown.bind(this),focusTrapActive:!0})}onTabKeyDown(e){if(e.defaultPrevented)return;e.preventDefault();const t=e.shiftKey,i=this.advancedSettingsPanel.getGui(),r=this.focusService.findNextFocusableElement(i,!1,t);if(r)r.focus();else{const e=this.focusService.findFocusableElements(i);e.length&&e[t?e.length-1:0].focus()}}};xs.TEMPLATE='<div class="ag-chart-advanced-settings"></div>',qe([(0,r.dsm)("focusService")],xs.prototype,"focusService",2),qe([r.o7C],xs.prototype,"postConstruct",1);var Ds=xs,Is={version:Vn,validate:()=>function({gridVersion:e,chartsVersion:t}){if(!gs(t))return{isValid:!1,message:fs({type:"invalidCharts",gridVersion:e,chartsVersion:t})};if(!gs(e))return{isValid:!1,message:fs({type:"invalidGrid",gridVersion:e,chartsVersion:t})};const[i,r]=e.split(".")||[],[n,s,o]=t.split(".")||[],a=function({gridMajorVersion:e,chartsMajorVersion:t}){const i=parseInt(e,10)-28;return i===parseInt(t,10)-6&&i>=0}({gridMajorVersion:i,chartsMajorVersion:n});return a&&r===s||o.includes("beta")?{isValid:!0}:a&&r===s?{isValid:!1,message:fs({type:"invalid",gridVersion:e,chartsVersion:t})}:{isValid:!1,message:fs({type:"incompatible",gridVersion:e,chartsVersion:t})}}({gridVersion:Vn,chartsVersion:hs.CHARTS_VERSION}),moduleName:r.zsj.GridChartsModule,beans:[hs,ds,ps,ms,In,Ps],agStackComponents:[{componentName:"AgColorPicker",componentClass:xi},{componentName:"AgAngleSelect",componentClass:ui},{componentName:"AgPillSelect",componentClass:Ht}],dependantModules:[Fe,S]},Ls=0,Ns={time:n.time,AgChart:n.AgChart},Os=Object.defineProperty,Fs=Object.getOwnPropertyDescriptor,ks=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Fs(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Os(t,i,s),s},Gs="paste",Vs="dragCopy",Hs="clipboard",Bs=e=>`AG Grid: Unable to use the Clipboard API (navigator.clipboard.${e}()). The reason why it could not be used has been logged in the previous line. For this reason the grid has defaulted to using a workaround which doesn't perform as well. Either fix why Clipboard API is blocked, OR stop this message from appearing by setting grid property suppressClipboardApi=true (which will default the grid to using the workaround rather than the API.`,zs=class extends r.XQb{constructor(){super(...arguments),this.lastPasteOperationTime=0,this.navigatorApiFailed=!1}init(){this.logger=this.loggerFactory.create("ClipboardService"),"clientSide"===this.rowModel.getType()&&(this.clientSideRowModel=this.rowModel),this.ctrlsService.whenReady(e=>{this.gridCtrl=e.gridCtrl})}pasteFromClipboard(){this.logger.log("pasteFromClipboard"),!this.gos.get("suppressClipboardApi")&&!this.navigatorApiFailed&&navigator.clipboard&&navigator.clipboard.readText?navigator.clipboard.readText().then(this.processClipboardData.bind(this)).catch(e=>{r._.doOnce(()=>{console.warn(e),console.warn(Bs("readText"))},"clipboardApiError"),this.navigatorApiFailed=!0,this.pasteFromClipboardLegacy()}):this.pasteFromClipboardLegacy()}pasteFromClipboardLegacy(){let e=!1;const t=t=>{const i=(new Date).getTime();i-this.lastPasteOperationTime<50&&(e=!0,t.preventDefault()),this.lastPasteOperationTime=i};this.executeOnTempElement(e=>{e.addEventListener("paste",t),e.focus({preventScroll:!0})},i=>{const r=i.value;e?this.refocusLastFocusedCell():this.processClipboardData(r),i.removeEventListener("paste",t)})}refocusLastFocusedCell(){const e=this.focusService.getFocusedCell();e&&this.focusService.setFocusedCell({rowIndex:e.rowIndex,column:e.column,rowPinned:e.rowPinned,forceBrowserFocus:!0})}getClipboardDelimiter(){const e=this.gos.get("clipboardDelimiter");return r._.exists(e)?e:"\t"}processClipboardData(e){if(null==e)return;let t=zs.stringToArray(e,this.getClipboardDelimiter());const i=this.gos.getCallback("processDataFromClipboard");i&&(t=i({data:t})),null!=t&&(this.gos.get("suppressLastEmptyLineOnPaste")&&this.removeLastLineIfBlank(t),this.doPasteOperation((e,i,r,n)=>{var s;(null==(s=this.rangeService)?void 0:s.isMoreThanOneCell())&&!this.hasOnlyOneValueToPaste(t)?this.pasteIntoActiveRange(this.rangeService,t,e,i,n):this.pasteStartingFromFocusedCell(t,e,i,r,n)}))}static stringToArray(e,t=","){const i=[],r=e=>"\r"===e||"\n"===e;let n=!1;if(""===e)return[[""]];for(let s=0,o=0,a=0;a<e.length;a++){const l=e[a-1],c=e[a],u=e[a+1],h=()=>{i[s]||(i[s]=[]),i[s][o]||(i[s][o]="")};if(h(),'"'===c&&(n?'"'===u?(i[s][o]+='"',a++):n=!1:(void 0===l||l===t||r(l))&&(n=!0)),!n&&'"'!==c){if(c===t){o++,h();continue}if(r(c)){o=0,s++,h(),"\r"===c&&"\n"===u&&a++;continue}}i[s][o]+=c}return i}doPasteOperation(e){const t="clipboard";let i;if(this.eventService.dispatchEvent({type:r.sVA.EVENT_PASTE_START,source:t}),this.clientSideRowModel){const e=this.gos.get("aggregateOnlyChangedColumns");i=new r.k$d(e,this.clientSideRowModel.getRootNode())}const n={},s=[];e(n,s,this.focusService.getFocusedCell(),i);const o=[...s];i&&(this.clientSideRowModel.doAggregate(i),i.forEachChangedNodeDepthFirst(e=>{o.push(e)})),this.rowRenderer.refreshCells({rowNodes:o}),this.dispatchFlashCells(n),this.fireRowChanged(s),this.refocusLastFocusedCell();const a={type:r.sVA.EVENT_PASTE_END,source:t};this.eventService.dispatchEvent(a)}pasteIntoActiveRange(e,t,i,r,n){const s=this.getRangeSize(e)%t.length!=0;let o=0,a=0;this.iterateActiveRanges(!1,(e,l,c,u)=>{if(u-o>=t.length){if(s)return;o+=a,a=0}const h=t[u-o];r.push(l);const d=this.gos.getCallback("processCellFromClipboard");c.forEach((t,r)=>{if(!t.isCellEditable(l)||t.isSuppressPaste(l))return;r>=h.length&&(r%=h.length);const s=this.processCell(l,t,h[r],Vs,d,!0);l.setDataValue(t,s,Gs),n&&n.addParentNode(l.parent,[t]);const{rowIndex:o,rowPinned:a}=e,c=this.cellPositionUtils.createIdFromValues({rowIndex:o,column:t,rowPinned:a});i[c]=!0}),a++})}getDisplayedColumnsStartingAt(e){let t=e;const i=[];for(;null!=t;)i.push(t),t=this.columnModel.getDisplayedColAfter(t);return i}pasteStartingFromFocusedCell(e,t,i,r,n){if(!r)return;const s={rowIndex:r.rowIndex,rowPinned:r.rowPinned},o=this.getDisplayedColumnsStartingAt(r.column);this.isPasteSingleValueIntoRange(e)?this.pasteSingleValueIntoRange(e,i,t,n):this.pasteMultipleValues(e,s,i,o,t,Hs,n)}isPasteSingleValueIntoRange(e){return this.hasOnlyOneValueToPaste(e)&&null!=this.rangeService&&!this.rangeService.isEmpty()}pasteSingleValueIntoRange(e,t,i,r){const n=e[0][0];this.iterateActiveRanges(!1,(e,s,o)=>{t.push(s),o.forEach(e=>this.updateCellValue(s,e,n,i,Hs,r))})}hasOnlyOneValueToPaste(e){return 1===e.length&&1===e[0].length}copyRangeDown(){if(!this.rangeService||this.rangeService.isEmpty())return;const e=[];this.doPasteOperation((t,i,r,n)=>{const s=this.gos.getCallback("processCellForClipboard"),o=this.gos.getCallback("processCellFromClipboard");this.iterateActiveRanges(!0,(r,a,l)=>{e.length?(i.push(a),l.forEach((i,s)=>{if(!i.isCellEditable(a)||i.isSuppressPaste(a))return;const l=this.processCell(a,i,e[s],Vs,o,!0);a.setDataValue(i,l,Gs),n&&n.addParentNode(a.parent,[i]);const{rowIndex:c,rowPinned:u}=r,h=this.cellPositionUtils.createIdFromValues({rowIndex:c,column:i,rowPinned:u});t[h]=!0})):l.forEach(t=>{const i=this.processCell(a,t,this.valueService.getValue(t,a),Vs,s,!1,!0);e.push(i)})})})}removeLastLineIfBlank(e){const t=r._.last(e);if(t&&1===t.length&&""===t[0]){if(1===e.length)return;r._.removeFromArray(e,t)}}fireRowChanged(e){"fullRow"===this.gos.get("editType")&&e.forEach(e=>{const t={type:r.sVA.EVENT_ROW_VALUE_CHANGED,node:e,data:e.data,rowIndex:e.rowIndex,rowPinned:e.rowPinned};this.eventService.dispatchEvent(t)})}pasteMultipleValues(e,t,i,r,n,s,o){let a=t;const l=null!=this.clientSideRowModel&&!this.gos.get("enableGroupEdit")&&!this.gos.get("treeData"),c=()=>{for(;;){if(!a)return null;const e=this.rowPositionUtils.getRowNode(a);if(a=this.cellNavigationService.getRowBelow({rowPinned:a.rowPinned,rowIndex:a.rowIndex}),null==e)return null;if(!(e.detail||e.footer||l&&e.group))return e}};e.forEach(e=>{const t=c();t&&(e.forEach((e,i)=>this.updateCellValue(t,r[i],e,n,s,o)),i.push(t))})}updateCellValue(e,t,i,r,n,s){if(!e||!t||!t.isCellEditable(e)||t.isSuppressPaste(e))return;if(e.group&&t.isValueActive())return;const o=this.processCell(e,t,i,n,this.gos.getCallback("processCellFromClipboard"),!0);e.setDataValue(t,o,Gs);const{rowIndex:a,rowPinned:l}=e;r[this.cellPositionUtils.createIdFromValues({rowIndex:a,column:t,rowPinned:l})]=!0,s&&s.addParentNode(e.parent,[t])}copyToClipboard(e={}){this.copyOrCutToClipboard(e)}cutToClipboard(e={},t="api"){if(this.gos.get("suppressCutToClipboard"))return;const i={type:r.sVA.EVENT_CUT_START,source:t};this.eventService.dispatchEvent(i),this.copyOrCutToClipboard(e,!0);const n={type:r.sVA.EVENT_CUT_END,source:t};this.eventService.dispatchEvent(n)}copyOrCutToClipboard(e,t){let{includeHeaders:i,includeGroupHeaders:r}=e;this.logger.log(`copyToClipboard: includeHeaders = ${i}`),null==i&&(i=this.gos.get("copyHeadersToClipboard")),null==r&&(r=this.gos.get("copyGroupHeadersToClipboard"));const n={includeHeaders:i,includeGroupHeaders:r},s=!this.gos.get("suppressCopyRowsToClipboard");let o=null;!this.rangeService||this.rangeService.isEmpty()||this.shouldSkipSingleCellRange(this.rangeService)?s&&!this.selectionService.isEmpty()?(this.copySelectedRowsToClipboard(n),o=1):this.focusService.isAnyCellFocused()&&(this.copyFocusedCellToClipboard(n),o=2):(this.copySelectedRangeToClipboard(n),o=0),t&&null!==o&&this.clearCellsAfterCopy(o)}clearCellsAfterCopy(e){if(this.eventService.dispatchEvent({type:r.sVA.EVENT_KEY_SHORTCUT_CHANGED_CELL_START}),0===e)this.rangeService.clearCellRangeCellValues({cellEventSource:"clipboardService"});else if(1===e)this.clearSelectedRows();else{const e=this.focusService.getFocusedCell();if(null==e)return;const t=this.rowPositionUtils.getRowNode(e);t&&this.clearCellValue(t,e.column)}this.eventService.dispatchEvent({type:r.sVA.EVENT_KEY_SHORTCUT_CHANGED_CELL_END})}clearSelectedRows(){const e=this.selectionService.getSelectedNodes(),t=this.columnModel.getAllDisplayedColumns();for(const i of e)for(const e of t)this.clearCellValue(i,e)}clearCellValue(e,t){var i;if(!t.isCellEditable(e))return;const r=null!=(i=this.valueService.parseValue(t,e,"",e.getValueFromValueService(t)))?i:null;e.setDataValue(t,r,"clipboardService")}shouldSkipSingleCellRange(e){return this.gos.get("suppressCopySingleCellRanges")&&!e.isMoreThanOneCell()}iterateActiveRanges(e,t,i){if(!this.rangeService||this.rangeService.isEmpty())return;const r=this.rangeService.getCellRanges();e?this.iterateActiveRange(r[0],t,i,!0):r.forEach((e,n)=>this.iterateActiveRange(e,t,i,n===r.length-1))}iterateActiveRange(e,t,i,r){if(!this.rangeService)return;let n=this.rangeService.getRangeStartRow(e);const s=this.rangeService.getRangeEndRow(e);i&&e.columns&&i(e.columns);let o=0,a=!1;for(;!a&&null!=n;){const i=this.rowPositionUtils.getRowNode(n);a=this.rowPositionUtils.sameRow(n,s),t(n,i,e.columns,o++,a&&r),n=this.cellNavigationService.getRowBelow(n)}}copySelectedRangeToClipboard(e={}){if(!this.rangeService||this.rangeService.isEmpty())return;const t=this.rangeService.areAllRangesAbleToMerge(),{data:i,cellsToFlash:r}=t?this.buildDataFromMergedRanges(this.rangeService,e):this.buildDataFromRanges(this.rangeService,e);this.copyDataToClipboard(i),this.dispatchFlashCells(r)}buildDataFromMergedRanges(e,t){const i=new Set,r=e.getCellRanges(),n=new Map,s=[],o={};r.forEach(t=>{t.columns.forEach(e=>i.add(e));const{rowPositions:r,cellsToFlash:a}=this.getRangeRowPositionsAndCellsToFlash(e,t);r.forEach(e=>{const t=`${e.rowIndex}-${e.rowPinned||"null"}`;n.get(t)||(n.set(t,!0),s.push(e))}),Object.assign(o,a)});const a=this.columnModel.getAllDisplayedColumns(),l=Array.from(i);return l.sort((e,t)=>a.indexOf(e)-a.indexOf(t)),{data:this.buildExportParams({columns:l,rowPositions:s,includeHeaders:t.includeHeaders,includeGroupHeaders:t.includeGroupHeaders}),cellsToFlash:o}}buildDataFromRanges(e,t){const i=e.getCellRanges(),r=[],n={};return i.forEach(i=>{const{rowPositions:s,cellsToFlash:o}=this.getRangeRowPositionsAndCellsToFlash(e,i);Object.assign(n,o),r.push(this.buildExportParams({columns:i.columns,rowPositions:s,includeHeaders:t.includeHeaders,includeGroupHeaders:t.includeGroupHeaders}))}),{data:r.join("\n"),cellsToFlash:n}}getRangeRowPositionsAndCellsToFlash(e,t){const i=[],r={},n=e.getRangeStartRow(t),s=e.getRangeEndRow(t);let o=n;for(;o&&(i.push(o),t.columns.forEach(e=>{const{rowIndex:t,rowPinned:i}=o,n=this.cellPositionUtils.createIdFromValues({rowIndex:t,column:e,rowPinned:i});r[n]=!0}),!this.rowPositionUtils.sameRow(o,s));)o=this.cellNavigationService.getRowBelow(o);return{rowPositions:i,cellsToFlash:r}}getCellsToFlashFromRowNodes(e){const t=this.columnModel.getAllDisplayedColumns(),i={};for(let r=0;r<e.length;r++){const{rowIndex:n,rowPinned:s}=e[r];if(null!=n)for(let e=0;e<t.length;e++){const r=t[e];i[this.cellPositionUtils.createIdFromValues({rowIndex:n,column:r,rowPinned:s})]=!0}}return i}copyFocusedCellToClipboard(e={}){const t=this.focusService.getFocusedCell();if(null==t)return;const i=this.cellPositionUtils.createId(t),r={rowPinned:t.rowPinned,rowIndex:t.rowIndex},n=t.column,s=this.buildExportParams({columns:[n],rowPositions:[r],includeHeaders:e.includeHeaders,includeGroupHeaders:e.includeGroupHeaders});this.copyDataToClipboard(s),this.dispatchFlashCells({[i]:!0})}copySelectedRowsToClipboard(e={}){const{columnKeys:t,includeHeaders:i,includeGroupHeaders:r}=e,n=this.buildExportParams({columns:t,includeHeaders:i,includeGroupHeaders:r});this.copyDataToClipboard(n);const s=this.selectionService.getSelectedNodes()||[];this.dispatchFlashCells(this.getCellsToFlashFromRowNodes(s))}buildExportParams(e){const{columns:t,rowPositions:i,includeHeaders:r=!1,includeGroupHeaders:n=!1}=e,s={columnKeys:t,rowPositions:i,skipColumnHeaders:!r,skipColumnGroupHeaders:!n,suppressQuotes:!0,columnSeparator:this.getClipboardDelimiter(),onlySelected:!i,processCellCallback:this.gos.getCallback("processCellForClipboard"),processRowGroupCallback:e=>this.processRowGroupCallback(e),processHeaderCallback:this.gos.getCallback("processHeaderForClipboard"),processGroupHeaderCallback:this.gos.getCallback("processGroupHeaderForClipboard")};return this.csvCreator.getDataAsCsv(s,!0)}processRowGroupCallback(e){const{node:t,column:i}=e,r=this.gos.get("treeData"),n=this.gos.get("suppressGroupMaintainValueType");let s=(()=>{var e,s;if(r||n||!i)return t.key;const o=null==(e=t.groupData)?void 0:e[i.getId()];return o&&t.rowGroupColumn&&!1!==t.rowGroupColumn.getColDef().useValueFormatterForExport&&null!=(s=this.valueService.formatValue(t.rowGroupColumn,t,o))?s:o})();if(e.node.footer){let e="";s&&s.length&&(e=` ${s}`),s=`Total${e}`}const o=this.gos.getCallback("processCellForClipboard");if(o){let e=t.rowGroupColumn;return!e&&t.footer&&-1===t.level&&(e=this.columnModel.getRowGroupColumns()[0]),o({value:s,node:t,column:e,type:"clipboard",formatValue:i=>{var r;return null!=(r=this.valueService.formatValue(e,t,i))?r:i},parseValue:i=>this.valueService.parseValue(e,t,i,this.valueService.getValue(e,t))})}return s}dispatchFlashCells(e){window.setTimeout(()=>{const t={type:r.sVA.EVENT_FLASH_CELLS,cells:e};this.eventService.dispatchEvent(t)},0)}processCell(e,t,i,r,n,s,o){var a;return n?n({column:t,node:e,value:i,type:r,formatValue:i=>{var r;return null!=(r=this.valueService.formatValue(t,null!=e?e:null,i))?r:i},parseValue:i=>this.valueService.parseValue(t,null!=e?e:null,i,this.valueService.getValue(t,e))}):s&&!1!==t.getColDef().useValueParserForImport?this.valueService.parseValue(t,null!=e?e:null,i,this.valueService.getValue(t,e)):o&&!1!==t.getColDef().useValueFormatterForExport&&null!=(a=this.valueService.formatValue(t,null!=e?e:null,i))?a:i}copyDataToClipboard(e){const t=this.gos.getCallback("sendToClipboard");t?t({data:e}):!this.gos.get("suppressClipboardApi")&&navigator.clipboard?navigator.clipboard.writeText(e).catch(t=>{r._.doOnce(()=>{console.warn(t),console.warn(Bs("writeText"))},"clipboardApiError"),this.copyDataToClipboardLegacy(e)}):this.copyDataToClipboardLegacy(e)}copyDataToClipboardLegacy(e){this.executeOnTempElement(t=>{const i=this.gos.getDocument(),r=this.gos.getActiveDomElement();t.value=e||" ",t.select(),t.focus({preventScroll:!0}),i.execCommand("copy")||console.warn("AG Grid: Browser did not allow document.execCommand('copy'). Ensure api.copySelectedRowsToClipboard() is invoked via a user event, i.e. button click, otherwise the browser will prevent it for security reasons."),null!=r&&null!=r.focus&&r.focus({preventScroll:!0})})}executeOnTempElement(e,t){const i=this.gos.getDocument(),r=i.createElement("textarea");r.style.width="1px",r.style.height="1px",r.style.top=i.documentElement.scrollTop+"px",r.style.left=i.documentElement.scrollLeft+"px",r.style.position="absolute",r.style.opacity="0";const n=this.gridCtrl.getGui();n.appendChild(r);try{e(r)}catch(e){console.warn("AG Grid: Browser does not support document.execCommand('copy') for clipboard operations")}t?window.setTimeout(()=>{t(r),n.removeChild(r)},100):n.removeChild(r)}getRangeSize(e){const t=e.getCellRanges();let i=0,r=0;return t.length>0&&(i=e.getRangeStartRow(t[0]).rowIndex,r=e.getRangeEndRow(t[0]).rowIndex),i-r+1}};ks([(0,r.dsm)("csvCreator")],zs.prototype,"csvCreator",2),ks([(0,r.dsm)("loggerFactory")],zs.prototype,"loggerFactory",2),ks([(0,r.dsm)("selectionService")],zs.prototype,"selectionService",2),ks([(0,r.dsm)("rowModel")],zs.prototype,"rowModel",2),ks([(0,r.dsm)("ctrlsService")],zs.prototype,"ctrlsService",2),ks([(0,r.dsm)("valueService")],zs.prototype,"valueService",2),ks([(0,r.dsm)("focusService")],zs.prototype,"focusService",2),ks([(0,r.dsm)("rowRenderer")],zs.prototype,"rowRenderer",2),ks([(0,r.dsm)("columnModel")],zs.prototype,"columnModel",2),ks([(0,r.dsm)("cellNavigationService")],zs.prototype,"cellNavigationService",2),ks([(0,r.dsm)("cellPositionUtils")],zs.prototype,"cellPositionUtils",2),ks([(0,r.dsm)("rowPositionUtils")],zs.prototype,"rowPositionUtils",2),ks([(0,r.Xx1)("rangeService")],zs.prototype,"rangeService",2),ks([r.o7C],zs.prototype,"init",1),zs=ks([(0,r.dR4)("clipboardService")],zs);var Us={version:"31.3.4",moduleName:r.zsj.ClipboardModule,beans:[zs],dependantModules:[S,r.n76]},Ws=Object.defineProperty,js=Object.defineProperties,Ks=Object.getOwnPropertyDescriptor,$s=Object.getOwnPropertyDescriptors,qs=Object.getOwnPropertySymbols,Ys=Object.prototype.hasOwnProperty,Qs=Object.prototype.propertyIsEnumerable,Xs=(e,t,i)=>t in e?Ws(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Zs=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Ks(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Ws(t,i,s),s},Js=class extends r.XQb{execute(e){const t=r._.missingOrEmpty(this.columnModel.getValueColumns()),i=!this.gos.getCallback("getGroupRowAgg"),n=e.changedPath&&e.changedPath.isActive();if(t&&i&&n)return;const s=this.createAggDetails(e);this.recursivelyCreateAggData(s)}createAggDetails(e){const t=this.columnModel.isPivotActive(),i=this.columnModel.getValueColumns(),r=t?this.columnModel.getPivotColumns():[];return{alwaysAggregateAtRootLevel:this.gos.get("alwaysAggregateAtRootLevel"),groupIncludeTotalFooter:!!this.gos.getGrandTotalRow(),changedPath:e.changedPath,valueColumns:i,pivotColumns:r,filteredOnly:!this.isSuppressAggFilteredOnly(),userAggFunc:this.gos.getCallback("getGroupRowAgg")}}isSuppressAggFilteredOnly(){return void 0!==this.gos.getGroupAggFiltering()||this.gos.get("suppressAggFilteredOnly")}recursivelyCreateAggData(e){e.changedPath.forEachChangedNodeDepthFirst(t=>{if(t.hasChildren()){if(-1===t.level&&!e.groupIncludeTotalFooter){const i=!this.columnModel.isPivotMode();if(!e.alwaysAggregateAtRootLevel&&i)return void t.setAggData(null)}this.aggregateRowNode(t,e)}else t.aggData&&t.setAggData(null)},!0)}aggregateRowNode(e,t){const i=0===t.valueColumns.length,r=0===t.pivotColumns.length;let n;n=t.userAggFunc?t.userAggFunc({nodes:e.childrenAfterFilter}):i?null:r?this.aggregateRowNodeUsingValuesOnly(e,t):this.aggregateRowNodeUsingValuesAndPivot(e),e.setAggData(n),e.sibling&&e.sibling.setAggData(n)}aggregateRowNodeUsingValuesAndPivot(e){var t,i;const r={},n=null!=(t=this.columnModel.getSecondaryColumns())?t:[];let s=!0;for(let t=0;t<n.length;t++){const o=n[t],a=o.getColDef();if(null!=a.pivotTotalColumnIds){s=!1;continue}const l=null!=(i=a.pivotKeys)?i:[];let c;c=e.leafGroup?this.getValuesFromMappedSet(e.childrenMapped,l,a.pivotValueColumn):this.getValuesPivotNonLeaf(e,a.colId),r[a.colId]=this.aggregateValues(c,a.pivotValueColumn.getAggFunc(),a.pivotValueColumn,e,o)}if(!s)for(let t=0;t<n.length;t++){const i=n[t],s=i.getColDef();if(null==s.pivotTotalColumnIds||!s.pivotTotalColumnIds.length)continue;const o=s.pivotTotalColumnIds.map(e=>r[e]);r[s.colId]=this.aggregateValues(o,s.pivotValueColumn.getAggFunc(),s.pivotValueColumn,e,i)}return r}aggregateRowNodeUsingValuesOnly(e,t){const i={},r=t.changedPath.isActive()?t.changedPath.getValueColumnsForNode(e,t.valueColumns):t.valueColumns,n=t.changedPath.isActive()?t.changedPath.getNotValueColumnsForNode(e,t.valueColumns):null,s=this.getValuesNormal(e,r,t.filteredOnly),o=e.aggData;return r.forEach((t,r)=>{i[t.getId()]=this.aggregateValues(s[r],t.getAggFunc(),t,e)}),n&&o&&n.forEach(e=>{i[e.getId()]=o[e.getId()]}),i}getValuesPivotNonLeaf(e,t){return e.childrenAfterFilter.map(e=>e.aggData[t])}getValuesFromMappedSet(e,t,i){let r=e;for(let e=0;e<t.length;e++){const i=t[e];r=r?r[i]:null}return r?r.map(e=>this.valueService.getValue(i,e)):[]}getValuesNormal(e,t,i){const r=[];t.forEach(()=>r.push([]));const n=t.length,s=i?e.childrenAfterFilter:e.childrenAfterGroup,o=s.length;for(let e=0;e<o;e++){const i=s[e];for(let e=0;e<n;e++){const n=t[e],s=this.valueService.getValue(n,i);r[e].push(s)}}return r}aggregateValues(e,t,i,r,n){const s="string"==typeof t?this.aggFuncService.getAggFunc(t):t;return"function"!=typeof s?(console.error(`AG Grid: unrecognised aggregation function ${t}`),null):s(this.gos.addGridCommonParams({values:e,column:i,colDef:i?i.getColDef():void 0,pivotResultColumn:n,rowNode:r,data:r?r.data:void 0}))}};Zs([(0,r.dsm)("columnModel")],Js.prototype,"columnModel",2),Zs([(0,r.dsm)("valueService")],Js.prototype,"valueService",2),Zs([(0,r.dsm)("aggFuncService")],Js.prototype,"aggFuncService",2),Js=Zs([(0,r.dR4)("aggregationStage")],Js);var eo=class{constructor(){this.allSets={},this.allParents=[]}removeFromChildrenAfterGroup(e,t){this.getSet(e).removeFromChildrenAfterGroup[t.id]=!0}isRemoveFromAllLeafChildren(e,t){return!!this.getSet(e).removeFromAllLeafChildren[t.id]}preventRemoveFromAllLeafChildren(e,t){delete this.getSet(e).removeFromAllLeafChildren[t.id]}removeFromAllLeafChildren(e,t){this.getSet(e).removeFromAllLeafChildren[t.id]=!0}getSet(e){return this.allSets[e.id]||(this.allSets[e.id]={removeFromAllLeafChildren:{},removeFromChildrenAfterGroup:{}},this.allParents.push(e)),this.allSets[e.id]}getAllParents(){return this.allParents}flush(){this.allParents.forEach(e=>{const t=this.allSets[e.id];e.childrenAfterGroup=e.childrenAfterGroup.filter(e=>!t.removeFromChildrenAfterGroup[e.id]),e.allLeafChildren=e.allLeafChildren.filter(e=>!t.removeFromAllLeafChildren[e.id]),e.updateHasChildren(),e.sibling&&(e.sibling.childrenAfterGroup=e.childrenAfterGroup,e.sibling.allLeafChildren=e.allLeafChildren)}),this.allSets={},this.allParents.length=0}},to=class extends r.XQb{execute(e){const t=this.createGroupingDetails(e);if(t.transactions)this.handleTransaction(t);else{const i=!0===e.afterColumnsChanged;this.shotgunResetEverything(t,i)}t.usingTreeData||(this.positionLeafsAndGroups(e.changedPath),this.orderGroups(t)),this.selectableService.updateSelectableAfterGrouping()}positionLeafsAndGroups(e){e.forEachChangedNodeDepthFirst(e=>{if(e.childrenAfterGroup){const t=[],i=[];let r;e.childrenAfterGroup.forEach(e=>{var n;(null==(n=e.childrenAfterGroup)?void 0:n.length)?""!==e.key||r?i.push(e):r=e:t.push(e)}),r&&i.push(r),e.childrenAfterGroup=[...t,...i]}},!1)}createGroupingDetails(e){var t;const{rowNode:i,changedPath:r,rowNodeTransactions:n,rowNodeOrder:s}=e,o=this.gos.get("treeData"),a=o?null:this.columnModel.getRowGroupColumns();return{includeParents:!this.gos.get("suppressParentsInRowNodes"),expandByDefault:this.gos.get("groupDefaultExpanded"),groupedCols:a,rootNode:i,pivotMode:this.columnModel.isPivotMode(),groupedColCount:o||!a?0:a.length,rowNodeOrder:s,transactions:n,changedPath:r,groupAllowUnbalanced:this.gos.get("groupAllowUnbalanced"),isGroupOpenByDefault:this.gos.getCallback("isGroupOpenByDefault"),initialGroupOrderComparator:this.gos.getCallback("initialGroupOrderComparator"),usingTreeData:o,suppressGroupMaintainValueType:this.gos.get("suppressGroupMaintainValueType"),getDataPath:o?this.gos.get("getDataPath"):void 0,keyCreators:null!=(t=null==a?void 0:a.map(e=>e.getColDef().keyCreator))?t:[]}}handleTransaction(e){e.transactions.forEach(t=>{const i=e.usingTreeData?void 0:new eo;if(r._.existsAndNotEmpty(t.remove)&&this.removeNodes(t.remove,e,i),r._.existsAndNotEmpty(t.update)&&this.moveNodesInWrongPath(t.update,e,i),r._.existsAndNotEmpty(t.add)&&this.insertNodes(t.add,e,!1),i){const t=i.getAllParents().slice();i.flush(),this.removeEmptyGroups(t,e)}}),e.rowNodeOrder&&this.sortChildren(e)}sortChildren(e){e.changedPath.forEachChangedNodeDepthFirst(t=>{t.childrenAfterGroup&&r._.sortRowNodesByOrder(t.childrenAfterGroup,e.rowNodeOrder)&&e.changedPath.addParentNode(t)},!1,!0)}orderGroups(e){const t=e.initialGroupOrderComparator;r._.exists(t)&&function e(i){r._.exists(i.childrenAfterGroup)&&!i.leafGroup&&(i.childrenAfterGroup.sort((e,i)=>t({nodeA:e,nodeB:i})),i.childrenAfterGroup.forEach(t=>e(t)))}(e.rootNode)}getExistingPathForNode(e,t){const i=[];let r=t.usingTreeData?e:e.parent;for(;r&&r!==t.rootNode;)i.push({key:r.key,rowGroupColumn:r.rowGroupColumn,field:r.field}),r=r.parent;return i.reverse(),i}moveNodesInWrongPath(e,t,i){e.forEach(e=>{t.changedPath.isActive()&&t.changedPath.addParentNode(e.parent);const n=e=>e.key,s=this.getExistingPathForNode(e,t).map(n),o=this.getGroupInfo(e,t).map(n);r._.areEqual(s,o)||this.moveNode(e,t,i)})}moveNode(e,t,i){if(this.removeNodesInStages([e],t,i),this.insertOneNode(e,t,!0,i),e.setData(e.data),t.changedPath.isActive()){const i=e.parent;t.changedPath.addParentNode(i)}}removeNodes(e,t,i){this.removeNodesInStages(e,t,i),t.changedPath.isActive()&&e.forEach(e=>t.changedPath.addParentNode(e.parent))}removeNodesInStages(e,t,i){if(this.removeNodesFromParents(e,t,i),t.usingTreeData){this.postRemoveCreateFillerNodes(e,t);const i=e.map(e=>e.parent);this.removeEmptyGroups(i,t)}}forEachParentGroup(e,t,i){let r=t;for(;r&&r!==e.rootNode;)i(r),r=r.parent}removeNodesFromParents(e,t,i){const r=null==i,n=i||new eo;e.forEach(e=>{this.removeFromParent(e,n),this.forEachParentGroup(t,e.parent,t=>{n.removeFromAllLeafChildren(t,e)})}),r&&n.flush()}postRemoveCreateFillerNodes(e,t){e.forEach(e=>{if(e.hasChildren()){const i=this.getExistingPathForNode(e,t),r=this.findParentForNode(e,i,t);r.expanded=e.expanded,r.allLeafChildren=e.allLeafChildren,r.childrenAfterGroup=e.childrenAfterGroup,r.childrenMapped=e.childrenMapped,r.updateHasChildren(),r.childrenAfterGroup.forEach(e=>e.parent=r)}})}removeEmptyGroups(e,t){let i=!0;const r=e=>{const t=this.getChildrenMappedKey(e.key,e.rowGroupColumn),i=e.parent;return!!(i&&i.childrenMapped&&i.childrenMapped[t]&&e.isEmptyRowGroupNode())};for(;i;){i=!1;const n=new eo;e.forEach(e=>{this.forEachParentGroup(t,e,e=>{r(e)&&(i=!0,this.removeFromParent(e,n),e.setSelectedParams({newValue:!1,source:"rowGroupChanged"}))})}),n.flush()}}removeFromParent(e,t){e.parent&&(t?t.removeFromChildrenAfterGroup(e.parent,e):(r._.removeFromArray(e.parent.childrenAfterGroup,e),e.parent.updateHasChildren()));const i=this.getChildrenMappedKey(e.key,e.rowGroupColumn);e.parent&&e.parent.childrenMapped&&(e.parent.childrenMapped[i]=void 0),e.setRowTop(null),e.setRowIndex(null)}addToParent(e,t){const i=this.getChildrenMappedKey(e.key,e.rowGroupColumn);t&&(null!=t.childrenMapped&&(t.childrenMapped[i]=e),t.childrenAfterGroup.push(e),t.updateHasChildren())}areGroupColsEqual(e,t){return null!=e&&null!=t&&e.pivotMode===t.pivotMode&&r._.areEqual(e.groupedCols,t.groupedCols)&&r._.areEqual(e.keyCreators,t.keyCreators)}checkAllGroupDataAfterColsChanged(e){const t=i=>{i&&i.forEach(i=>{if(!e.usingTreeData&&!i.group)return;const r={field:i.field,key:i.key,rowGroupColumn:i.rowGroupColumn,leafNode:i.allLeafChildren[0]};this.setGroupData(i,r,e),t(i.childrenAfterGroup)})};t(e.rootNode.childrenAfterGroup)}shotgunResetEverything(e,t){if(this.noChangeInGroupingColumns(e,t))return;this.selectionService.filterFromSelection(e=>e&&!e.group);const{rootNode:i,groupedCols:r}=e;i.leafGroup=!e.usingTreeData&&0===r.length,i.childrenAfterGroup=[],i.childrenMapped={},i.updateHasChildren();const n=i.sibling;n&&(n.childrenAfterGroup=i.childrenAfterGroup,n.childrenMapped=i.childrenMapped),this.insertNodes(i.allLeafChildren,e,!1)}noChangeInGroupingColumns(e,t){let i=!1;const r=this.columnModel.getGroupDisplayColumns(),n=r?r.map(e=>e.getId()).join("-"):"";return t&&(i=e.usingTreeData||this.areGroupColsEqual(e,this.oldGroupingDetails),this.oldGroupDisplayColIds!==n&&this.checkAllGroupDataAfterColsChanged(e)),this.oldGroupingDetails=e,this.oldGroupDisplayColIds=n,i}insertNodes(e,t,i){e.forEach(e=>{this.insertOneNode(e,t,i),t.changedPath.isActive()&&t.changedPath.addParentNode(e.parent)})}insertOneNode(e,t,i,r){const n=this.getGroupInfo(e,t),s=this.findParentForNode(e,n,t,r);s.group||console.warn("AG Grid: duplicate group keys for row data, keys should be unique",[s.data,e.data]),t.usingTreeData?this.swapGroupWithUserNode(s,e,i):(e.parent=s,e.level=n.length,s.childrenAfterGroup.push(e),s.updateHasChildren())}findParentForNode(e,t,i,r){let n=i.rootNode;return t.forEach((t,s)=>{n=this.getOrCreateNextNode(n,t,s,i),(null==r?void 0:r.isRemoveFromAllLeafChildren(n,e))?null==r||r.preventRemoveFromAllLeafChildren(n,e):n.allLeafChildren.push(e)}),n}swapGroupWithUserNode(e,t,i){t.parent=e.parent,t.key=e.key,t.field=e.field,t.groupData=e.groupData,t.level=e.level,i||(t.expanded=e.expanded),t.leafGroup=e.leafGroup,t.rowGroupIndex=e.rowGroupIndex,t.allLeafChildren=e.allLeafChildren,t.childrenAfterGroup=e.childrenAfterGroup,t.childrenMapped=e.childrenMapped,t.sibling=e.sibling,t.updateHasChildren(),this.removeFromParent(e),t.childrenAfterGroup.forEach(e=>e.parent=t),this.addToParent(t,e.parent)}getOrCreateNextNode(e,t,i,r){const n=this.getChildrenMappedKey(t.key,t.rowGroupColumn);let s=e.childrenMapped?e.childrenMapped[n]:void 0;return s||(s=this.createGroup(t,e,i,r),this.addToParent(s,e)),s}createGroup(e,t,i,n){const s=new r.TUE(this.beans);return s.group=!0,s.field=e.field,s.rowGroupColumn=e.rowGroupColumn,this.setGroupData(s,e,n),s.key=e.key,s.id=this.createGroupId(s,t,n.usingTreeData,i),s.level=i,s.leafGroup=!n.usingTreeData&&i===n.groupedColCount-1,s.allLeafChildren=[],s.setAllChildrenCount(0),s.rowGroupIndex=n.usingTreeData?null:i,s.childrenAfterGroup=[],s.childrenMapped={},s.updateHasChildren(),s.parent=n.includeParents?t:null,this.setExpandedInitialValue(n,s),s}createGroupId(e,t,i,n){let s;return s=i?(e,t,i)=>{if(i<0)return null;const r=t?s(t,t.parent,i-1):null;return`${null==r?"":r+"-"}${i}-${e.key}`}:(e,t)=>{if(!e.rowGroupColumn)return null;const i=t?s(t,t.parent,0):null;return`${null==i?"":i+"-"}${e.rowGroupColumn.getColId()}-${e.key}`},r.TUE.ID_PREFIX_ROW_GROUP+s(e,t,n)}setGroupData(e,t,i){e.groupData={},this.columnModel.getGroupDisplayColumns().forEach(r=>{if(i.usingTreeData)return void(e.groupData[r.getColId()]=t.key);const n=e.rowGroupColumn;null!==n&&r.isRowGroupDisplayed(n.getId())&&(i.suppressGroupMaintainValueType?e.groupData[r.getColId()]=t.key:e.groupData[r.getColId()]=this.valueService.getValue(n,t.leafNode))})}getChildrenMappedKey(e,t){return t?t.getId()+"-"+e:e}setExpandedInitialValue(e,t){if(e.pivotMode&&t.leafGroup)return void(t.expanded=!1);const i=e.isGroupOpenByDefault;if(i){const e={rowNode:t,field:t.field,key:t.key,level:t.level,rowGroupColumn:t.rowGroupColumn};return void(t.expanded=1==i(e))}const{expandByDefault:r}=e;-1!==e.expandByDefault?t.expanded=t.level<r:t.expanded=!0}getGroupInfo(e,t){return t.usingTreeData?this.getGroupInfoFromCallback(e,t):this.getGroupInfoFromGroupColumns(e,t)}getGroupInfoFromCallback(e,t){const i=t.getDataPath?t.getDataPath(e.data):null;return null!=i&&0!==i.length||r._.warnOnce(`getDataPath() should not return an empty path for data ${e.data}`),i?i.map(e=>({key:e,field:null,rowGroupColumn:null})):[]}getGroupInfoFromGroupColumns(e,t){const i=[];return t.groupedCols.forEach(r=>{let n=this.valueService.getKeyForNode(r,e),s=null!=n&&""!==n;if((t.pivotMode||!t.groupAllowUnbalanced)&&!s&&(n="",s=!0),s){const t={key:n,field:r.getColDef().field,rowGroupColumn:r,leafNode:e};i.push(t)}}),i}};Zs([(0,r.dsm)("columnModel")],to.prototype,"columnModel",2),Zs([(0,r.dsm)("selectableService")],to.prototype,"selectableService",2),Zs([(0,r.dsm)("valueService")],to.prototype,"valueService",2),Zs([(0,r.dsm)("beans")],to.prototype,"beans",2),Zs([(0,r.dsm)("selectionService")],to.prototype,"selectionService",2),to=Zs([(0,r.dR4)("groupStage")],to);var io=class extends r.XQb{init(){const e=()=>{var e;return null!=(e=this.gos.get("serverSidePivotResultFieldSeparator"))?e:"_"};this.fieldSeparator=e(),this.addManagedPropertyListener("serverSidePivotResultFieldSeparator",()=>{this.fieldSeparator=e()});const t=()=>this.gos.get("pivotDefaultExpanded");this.pivotDefaultExpanded=t(),this.addManagedPropertyListener("pivotDefaultExpanded",()=>{this.pivotDefaultExpanded=t()})}createPivotColumnDefs(e){const t=this.createPivotColumnsFromUniqueValues(e),i=function e(t,i=[]){return t.forEach(t=>{void 0!==t.children?e(t.children,i):i.push(t)}),i}(t);return this.addRowGroupTotals(t,i),this.addExpandablePivotGroups(t,i),this.addPivotTotalsToGroups(t,i),{pivotColumnGroupDefs:t,pivotColumnDefs:i.map(e=>r._.cloneObject(e))}}createPivotColumnsFromUniqueValues(e){const t=this.columnModel.getPivotColumns(),i=t.length;return this.recursivelyBuildGroup(0,e,[],i,t)}recursivelyBuildGroup(e,t,i,n,s){const o=this.columnModel.getValueColumns();if(e>=n)return this.buildMeasureCols(i);const a=s[e].getColDef(),l=this.headerNameComparator.bind(this,a.pivotComparator);if(1===o.length&&this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&e===n-1){const e=[];return r._.iterateObject(t,t=>{const r=[...i,t],n=this.createColDef(o[0],t,r);n.columnGroupShow="open",e.push(n)}),e.sort(l),e}const c=[];return r._.iterateObject(t,(t,r)=>{const o=-1===this.pivotDefaultExpanded||e<this.pivotDefaultExpanded,a=[...i,t];c.push({children:this.recursivelyBuildGroup(e+1,r,a,n,s),headerName:t,pivotKeys:a,columnGroupShow:"open",openByDefault:o,groupId:this.generateColumnGroupId(a)})}),c.sort(l),c}buildMeasureCols(e){const t=this.columnModel.getValueColumns();return 0===t.length?[this.createColDef(null,"-",e)]:t.map(t=>{const i=this.columnModel.getDisplayNameForColumn(t,"header");return r=((e,t)=>{for(var i in t||(t={}))Ys.call(t,i)&&Xs(e,i,t[i]);if(qs)for(var i of qs(t))Qs.call(t,i)&&Xs(e,i,t[i]);return e})({},this.createColDef(t,i,e)),js(r,$s({columnGroupShow:"open"}));var r})}addExpandablePivotGroups(e,t){if(this.gos.get("suppressExpandablePivotGroups")||this.gos.get("pivotColumnGroupTotals"))return;const i=(e,t,r)=>{const n=e;if(n.children){const s=new Map;n.children.forEach(e=>{i(e,t,s)});const o=!n.children.some(e=>e.children);this.columnModel.getValueColumns().forEach(i=>{const r=this.columnModel.getDisplayNameForColumn(i,"header"),n=this.createColDef(i,r,e.pivotKeys);n.pivotTotalColumnIds=s.get(i.getColId()),n.columnGroupShow="closed",n.aggFunc=i.getAggFunc(),o||(e.children.push(n),t.push(n))}),this.merge(r,s)}else{const t=e;if(!t.pivotValueColumn)return;const i=t.pivotValueColumn.getColId(),n=r.has(i)?r.get(i):[];n.push(t.colId),r.set(i,n)}};e.forEach(e=>{i(e,t,new Map)})}addPivotTotalsToGroups(e,t){if(!this.gos.get("pivotColumnGroupTotals"))return;const i="after"===this.gos.get("pivotColumnGroupTotals"),r=this.columnModel.getValueColumns(),n=r.map(e=>e.getAggFunc());if(!n||n.length<1||!this.sameAggFuncs(n))return;const s=r[0];e.forEach(e=>{this.recursivelyAddPivotTotal(e,t,s,i)})}recursivelyAddPivotTotal(e,t,i,r){const n=e;if(!n.children){const t=e;return t.colId?[t.colId]:null}let s=[];if(n.children.forEach(e=>{const n=this.recursivelyAddPivotTotal(e,t,i,r);n&&(s=s.concat(n))}),n.children.length>1){const n=this.localeService.getLocaleTextFunc()("pivotColumnGroupTotals","Total"),o=this.createColDef(i,n,e.pivotKeys,!0);o.pivotTotalColumnIds=s,o.aggFunc=i.getAggFunc();const a=e.children;r?a.push(o):a.unshift(o),t.push(o)}return s}addRowGroupTotals(e,t){if(!this.gos.get("pivotRowTotals"))return;const i="after"===this.gos.get("pivotRowTotals"),r=this.columnModel.getValueColumns(),n=i?r.slice():r.slice().reverse();for(let r=0;r<n.length;r++){const s=n[r];let o=[];e.forEach(e=>{o=o.concat(this.extractColIdsForValueColumn(e,s))});const a=n.length>1||!this.gos.get("removePivotHeaderRowWhenSingleValueColumn");this.createRowGroupTotal(e,t,s,o,i,a)}}extractColIdsForValueColumn(e,t){const i=e;if(!i.children){const e=i;return e.pivotValueColumn===t&&e.colId?[e.colId]:[]}let r=[];return i.children.forEach(e=>{this.extractColIdsForValueColumn(e,t);const i=this.extractColIdsForValueColumn(e,t);r=r.concat(i)}),r}createRowGroupTotal(e,t,i,r,n,s){let o;if(0===this.columnModel.getValueColumns().length)o=this.createColDef(null,"-",[]);else{const e=this.columnModel.getDisplayNameForColumn(i,"header");o=this.createColDef(i,e,[]),o.pivotTotalColumnIds=r}o.colId=io.PIVOT_ROW_TOTAL_PREFIX+o.colId,t.push(o);const a=s?{children:[o],pivotKeys:[],groupId:`${io.PIVOT_ROW_TOTAL_PREFIX}_pivotGroup_${i.getColId()}`}:o;n?e.push(a):e.unshift(a)}createColDef(e,t,i,r=!1){const n={};if(e){const t=e.getColDef();Object.assign(n,t),n.hide=!1}return n.headerName=t,n.colId=this.generateColumnId(i||[],e&&!r?e.getColId():""),n.field=n.colId,n.valueGetter=e=>{var t;return null==(t=e.data)?void 0:t[e.colDef.field]},n.pivotKeys=i,n.pivotValueColumn=e,!0===n.filter&&(n.filter="agNumberColumnFilter"),n}sameAggFuncs(e){if(1==e.length)return!0;for(let t=1;t<e.length;t++)if(e[t]!==e[0])return!1;return!0}headerNameComparator(e,t,i){return e?e(t.headerName,i.headerName):t.headerName&&!i.headerName?1:!t.headerName&&i.headerName?-1:t.headerName&&i.headerName?t.headerName<i.headerName?-1:t.headerName>i.headerName?1:0:0}merge(e,t){t.forEach((t,i,r)=>{const n=[...e.has(i)?e.get(i):[],...t];e.set(i,n)})}generateColumnGroupId(e){return`pivotGroup_${this.columnModel.getPivotColumns().map(e=>e.getColId()).join("-")}_${e.join("-")}`}generateColumnId(e,t){return`pivot_${this.columnModel.getPivotColumns().map(e=>e.getColId()).join("-")}_${e.join("-")}_${t}`}createColDefsFromFields(e){const t={};for(let i=0;i<e.length;i++){const r=e[i].split(this.fieldSeparator);let n=t;for(let e=0;e<r.length;e++){const t=r[e];null==n[t]&&(n[t]={}),n=n[t]}}const i=(e,t,r,n)=>{var s;const o=[];for(let t in r){const s=r[t],a=i(`${e}${this.fieldSeparator}${t}`,t,s,n+1);o.push(a)}if(0===o.length){const i=this.columnModel.getPrimaryColumn(t);if(i){const r=null!=(s=this.columnModel.getDisplayNameForColumn(i,"header"))?s:t,n=this.createColDef(i,r,void 0,!1);return n.colId=e,n.aggFunc=i.getAggFunc(),n.valueGetter=t=>{var i;return null==(i=t.data)?void 0:i[e]},n}return{colId:e,headerName:t,valueGetter:t=>{var i;return null==(i=t.data)?void 0:i[e]}}}return this.gos.get("removePivotHeaderRowWhenSingleValueColumn")&&1===o.length&&"colId"in o[0]?(o[0].headerName=t,o[0]):{openByDefault:-1===this.pivotDefaultExpanded||n<this.pivotDefaultExpanded,groupId:e,headerName:t,children:o}},r=[];for(let e in t){const n=i(e,e,t[e],0);r.push(n)}return r}};io.PIVOT_ROW_TOTAL_PREFIX="PivotRowTotal_",Zs([(0,r.dsm)("columnModel")],io.prototype,"columnModel",2),Zs([r.o7C],io.prototype,"init",1),io=Zs([(0,r.dR4)("pivotColDefService")],io);var ro=class extends r.XQb{constructor(){super(...arguments),this.uniqueValues={},this.lastTimeFailed=!1,this.maxUniqueValues=-1,this.currentUniqueCount=0}execute(e){const t=e.changedPath;this.columnModel.isPivotActive()?this.executePivotOn(t):this.executePivotOff(t)}executePivotOff(e){this.aggregationColumnsHashLastTime=null,this.uniqueValues={},this.columnModel.isSecondaryColumnsPresent()&&(this.columnModel.setSecondaryColumns(null,"rowModelUpdated"),e&&e.setInactive())}executePivotOn(e){var t;const i=null!=(t=this.columnModel.getValueColumns().length)?t:1,n=this.gos.get("pivotMaxGeneratedColumns");let s;this.maxUniqueValues=-1===n?-1:n/i;try{s=this.bucketUpRowNodes(e)}catch(e){if(e.message===ro.EXCEEDED_MAX_UNIQUE_VALUES){this.columnModel.setSecondaryColumns([],"rowModelUpdated");const t={type:r.sVA.EVENT_PIVOT_MAX_COLUMNS_EXCEEDED,message:e.message};return this.eventService.dispatchEvent(t),void(this.lastTimeFailed=!0)}throw e}const o=this.setUniqueValues(s),a=this.columnModel.getValueColumns(),l=a.map(e=>`${e.getId()}-${e.getColDef().headerName}`).join("#"),c=a.map(e=>e.getAggFunc().toString()).join("#"),u=this.aggregationColumnsHashLastTime!==l,h=this.aggregationFuncsHashLastTime!==c;this.aggregationColumnsHashLastTime=l,this.aggregationFuncsHashLastTime=c;const d=this.columnModel.getRowGroupColumns().map(e=>e.getId()).join("#"),p=d!==this.groupColumnsHashLastTime;this.groupColumnsHashLastTime=d;const g=this.gos.get("pivotRowTotals"),f=this.gos.get("pivotColumnGroupTotals"),m=this.gos.get("suppressExpandablePivotGroups"),v=this.gos.get("removePivotHeaderRowWhenSingleValueColumn"),C=g!==this.pivotRowTotalsLastTime||f!==this.pivotColumnGroupTotalsLastTime||m!==this.suppressExpandablePivotGroupsLastTime||v!==this.removePivotHeaderRowWhenSingleValueColumnLastTime;if(this.pivotRowTotalsLastTime=g,this.pivotColumnGroupTotalsLastTime=f,this.suppressExpandablePivotGroupsLastTime=m,this.removePivotHeaderRowWhenSingleValueColumnLastTime=v,this.lastTimeFailed||o||u||p||h||C){const{pivotColumnGroupDefs:t,pivotColumnDefs:i}=this.pivotColDefService.createPivotColumnDefs(this.uniqueValues);this.pivotColumnDefs=i,this.columnModel.setSecondaryColumns(t,"rowModelUpdated"),e&&e.setInactive()}this.lastTimeFailed=!1}setUniqueValues(e){return!(JSON.stringify(e)===JSON.stringify(this.uniqueValues)||(this.uniqueValues=e,0))}bucketUpRowNodes(e){this.currentUniqueCount=0;const t={};e.forEachChangedNodeDepthFirst(e=>{e.leafGroup&&(e.childrenMapped=null)});const i=e=>{var r;e.leafGroup?this.bucketRowNode(e,t):null==(r=e.childrenAfterFilter)||r.forEach(i)};return e.executeFromRootNode(i),t}bucketRowNode(e,t){const i=this.columnModel.getPivotColumns();0===i.length?e.childrenMapped=null:e.childrenMapped=this.bucketChildren(e.childrenAfterFilter,i,0,t),e.sibling&&(e.sibling.childrenMapped=e.childrenMapped)}bucketChildren(e,t,i,n){const s={},o=t[i];if(e.forEach(e=>{let t=this.valueService.getKeyForNode(o,e);if(r._.missing(t)&&(t=""),!n[t]){this.currentUniqueCount+=1,n[t]={};const e=-1!==this.maxUniqueValues,i=this.currentUniqueCount>this.maxUniqueValues;if(e&&i)throw Error(ro.EXCEEDED_MAX_UNIQUE_VALUES)}s[t]||(s[t]=[]),s[t].push(e)}),i===t.length-1)return s;{const e={};return r._.iterateObject(s,(r,s)=>{e[r]=this.bucketChildren(s,t,i+1,n[r])}),e}}getPivotColumnDefs(){return this.pivotColumnDefs}};ro.EXCEEDED_MAX_UNIQUE_VALUES="Exceeded maximum allowed pivot column count.",Zs([(0,r.dsm)("valueService")],ro.prototype,"valueService",2),Zs([(0,r.dsm)("columnModel")],ro.prototype,"columnModel",2),Zs([(0,r.dsm)("pivotColDefService")],ro.prototype,"pivotColDefService",2),ro=Zs([(0,r.dR4)("pivotStage")],ro);var no={sum:"Sum",first:"First",last:"Last",min:"Min",max:"Max",count:"Count",avg:"Average"},so=class extends r.XQb{constructor(){super(...arguments),this.aggFuncsMap={},this.initialised=!1}init(){this.initialised||(this.initialiseWithDefaultAggregations(),this.addAggFuncs(this.gos.get("aggFuncs")))}initialiseWithDefaultAggregations(){this.aggFuncsMap[so.AGG_SUM]=oo,this.aggFuncsMap[so.AGG_FIRST]=ao,this.aggFuncsMap[so.AGG_LAST]=lo,this.aggFuncsMap[so.AGG_MIN]=co,this.aggFuncsMap[so.AGG_MAX]=uo,this.aggFuncsMap[so.AGG_COUNT]=ho,this.aggFuncsMap[so.AGG_AVG]=po,this.initialised=!0}isAggFuncPossible(e,t){const i=this.getFuncNames(e),n=r._.includes(i,t),s=r._.exists(this.aggFuncsMap[t]);return n&&s}getDefaultFuncLabel(e){var t;return null!=(t=no[e])?t:e}getDefaultAggFunc(e){const t=e.getColDef().defaultAggFunc;if(r._.exists(t)&&this.isAggFuncPossible(e,t))return t;if(this.isAggFuncPossible(e,so.AGG_SUM))return so.AGG_SUM;const i=this.getFuncNames(e);return r._.existsAndNotEmpty(i)?i[0]:null}addAggFuncs(e){this.init(),r._.iterateObject(e,(e,t)=>{this.aggFuncsMap[e]=t})}getAggFunc(e){return this.init(),this.aggFuncsMap[e]}getFuncNames(e){const t=e.getColDef().allowedAggFuncs;return null==t?Object.keys(this.aggFuncsMap).sort():t}clear(){this.aggFuncsMap={}}};function oo(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"==typeof r?null===i?i=r:i+="number"==typeof i?r:BigInt(r):"bigint"==typeof r&&(i=null===i?r:("bigint"==typeof i?i:BigInt(i))+r)}return i}function ao(e){return e.values.length>0?e.values[0]:null}function lo(e){return e.values.length>0?r._.last(e.values):null}function co(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"!=typeof r&&"bigint"!=typeof r||!(null===i||i>r)||(i=r)}return i}function uo(e){const{values:t}=e;let i=null;for(let e=0;e<t.length;e++){const r=t[e];"number"!=typeof r&&"bigint"!=typeof r||!(null===i||i<r)||(i=r)}return i}function ho(e){var t,i;const{values:r}=e;let n=0;for(let e=0;e<r.length;e++){const t=r[e];n+=null!=t&&"number"==typeof t.value?t.value:1}const s=null==(i=null==(t=e.rowNode)?void 0:t.aggData)?void 0:i[e.column.getColId()];return s&&s.value===n?s:{value:n,toString:function(){return this.value.toString()},toNumber:function(){return this.value}}}function po(e){var t,i,r;const{values:n}=e;let s=0,o=0;for(let e=0;e<n.length;e++){const t=n[e];let i=null;"number"==typeof t||"bigint"==typeof t?(i=t,o++):null==t||"number"!=typeof t.value&&"bigint"!=typeof t.value||"number"!=typeof t.count||(i=t.value*("number"==typeof t.value?t.count:BigInt(t.count)),o+=t.count),"number"==typeof i?s+="number"==typeof s?i:BigInt(i):"bigint"==typeof i&&(s=("bigint"==typeof s?s:BigInt(s))+i)}let a=null;o>0&&(a=s/("number"==typeof s?o:BigInt(o)));const l=null==(r=null==(t=e.rowNode)?void 0:t.aggData)?void 0:r[null==(i=e.column)?void 0:i.getColId()];return l&&l.count===o&&l.value===a?l:{count:o,value:a,toString:function(){return"number"==typeof this.value||"bigint"==typeof this.value?this.value.toString():""},toNumber:function(){return this.value}}}so.AGG_SUM="sum",so.AGG_FIRST="first",so.AGG_LAST="last",so.AGG_MIN="min",so.AGG_MAX="max",so.AGG_COUNT="count",so.AGG_AVG="avg",Zs([r.o7C],so.prototype,"init",1),so=Zs([(0,r.dR4)("aggFuncService")],so);var go=class extends r.v26{constructor(e,t,i,r,n){super(t,i,n,'\n                <span role="option">\n                    <span ref="eDragHandle" class="ag-drag-handle ag-column-drop-cell-drag-handle" role="presentation"></span>\n                    <span ref="eText" class="ag-column-drop-cell-text" aria-hidden="true"></span>\n                    <ag-sort-indicator ref="eSortIndicator"></ag-sort-indicator>\n                    <span ref="eButton" class="ag-column-drop-cell-button" role="presentation"></span>\n                </span>\n            '),this.column=e,this.dropZonePurpose=r,this.popupShowing=!1}init(){this.displayName=this.columnModel.getDisplayNameForColumn(this.column,"columnDrop"),super.init(),this.setupSort(),this.addManagedListener(this.eventService,r.VPZ.EVENT_SORT_CHANGED,()=>{this.setupAria()}),this.isGroupingZone()&&this.addManagedPropertyListener("groupLockGroupColumns",()=>{this.refreshRemove(),this.refreshDraggable(),this.setupAria()})}getItem(){return this.column}getDisplayName(){return this.displayName}getTooltip(){return this.column.getColDef().headerTooltip}addAdditionalAriaInstructions(e,t){const i=this.gos.get("rowGroupPanelSuppressSort"),r=this.gos.get("functionsReadOnly");if(this.isAggregationZone()&&!r){const i=t("ariaDropZoneColumnValueItemDescription","Press ENTER to change the aggregation type");e.push(i)}if(this.isGroupingZone()&&this.column.isSortable()&&!i){const i=t("ariaDropZoneColumnGroupItemDescription","Press ENTER to sort");e.push(i)}super.addAdditionalAriaInstructions(e,t)}isDraggable(){return this.isReadOnly()}isRemovable(){return this.isReadOnly()}isReadOnly(){return!this.isGroupingAndLocked()&&!this.gos.get("functionsReadOnly")}getAriaDisplayName(){const e=this.localeService.getLocaleTextFunc(),{name:t,aggFuncName:i}=this.getColumnAndAggFuncName(),r=e("ariaDropZoneColumnComponentAggFuncSeparator"," of "),n={asc:e("ariaDropZoneColumnComponentSortAscending","ascending"),desc:e("ariaDropZoneColumnComponentSortDescending","descending")},s=this.column.getSort(),o=this.gos.get("rowGroupPanelSuppressSort");return[i&&`${i}${r}`,t,this.isGroupingZone()&&!o&&s&&`, ${n[s]}`].filter(e=>!!e).join("")}getColumnAndAggFuncName(){const e=this.displayName;let t="";if(this.isAggregationZone()){const e=this.column.getAggFunc(),i="string"==typeof e?e:"agg";t=this.localeService.getLocaleTextFunc()(i,i)}return{name:e,aggFuncName:t}}setupSort(){const e=this.column.isSortable(),t=this.isGroupingZone();if(e&&t&&!this.gos.get("rowGroupPanelSuppressSort")){this.eSortIndicator.setupSort(this.column,!0);const e=e=>{e.preventDefault();const t="ctrl"===this.gos.get("multiSortKey")?e.ctrlKey||e.metaKey:e.shiftKey;this.sortController.progressSort(this.column,t,"uiColumnSorted")};this.addGuiEventListener("click",e),this.addGuiEventListener("keydown",t=>{t.key===r.DDm.ENTER&&this.isGroupingZone()&&e(t)})}}getDefaultIconName(){return r.WO_.ICON_HIDE}createGetDragItem(){const{column:e}=this;return()=>{const t={};return t[e.getId()]=e.isVisible(),{columns:[e],visibleState:t}}}setupComponents(){super.setupComponents(),this.isAggregationZone()&&!this.gos.get("functionsReadOnly")&&this.addGuiEventListener("click",this.onShowAggFuncSelection.bind(this))}onKeyDown(e){super.onKeyDown(e),e.key===r.DDm.ENTER&&this.isAggregationZone()&&!this.gos.get("functionsReadOnly")&&(e.preventDefault(),this.onShowAggFuncSelection())}getDisplayValue(){const{name:e,aggFuncName:t}=this.getColumnAndAggFuncName();return this.isAggregationZone()?`${t}(${e})`:e}onShowAggFuncSelection(){if(this.popupShowing)return;this.popupShowing=!0;const e=new r.wjn({cssIdentifier:"select-agg-func"}),t=this.aggFuncService.getFuncNames(this.column),i=this.getGui(),n=e.getGui();e.setModel({getRow:function(e){return t[e]},getRowCount:function(){return t.length}}),this.getContext().createBean(e);const s=r._.loadTemplate('<div class="ag-select-agg-func-popup"></div>');s.style.top="0px",s.style.left="0px",s.appendChild(n),s.style.width=`${i.clientWidth}px`;const o=this.addManagedListener(s,"focusout",e=>{!s.contains(e.relatedTarget)&&l&&l.hideFunc()}),a=this.localeService.getLocaleTextFunc(),l=this.popupService.addPopup({modal:!0,eChild:s,closeOnEsc:!0,closedCallback:t=>{this.destroyBean(e),this.popupShowing=!1,"Escape"===(null==t?void 0:t.key)&&i.focus(),o&&o()},ariaLabel:a("ariaLabelAggregationFunction","Aggregation Function")});l&&e.setComponentCreator(this.createAggSelect.bind(this,l.hideFunc)),e.addGuiEventListener("keydown",t=>{if(t.key===r.DDm.ENTER||t.key===r.DDm.SPACE){const t=e.getLastFocusedRow();if(null==t)return;const i=e.getComponentAt(t);i&&i.selectItem()}}),this.popupService.positionPopupByComponent({type:"aggFuncSelect",eventSource:i,ePopup:s,keepWithinBounds:!0,column:this.column,position:"under"}),e.refresh();let c=t.findIndex(e=>e===this.column.getAggFunc());-1===c&&(c=0),e.focusRow(c)}createAggSelect(e,t){const i=this.localeService.getLocaleTextFunc(),n=t.toString(),s=i(n,n);return new fo(()=>{if(e(),this.gos.get("functionsPassive")){const e={type:r.sVA.EVENT_COLUMN_AGG_FUNC_CHANGE_REQUEST,columns:[this.column],aggFunc:t};this.eventService.dispatchEvent(e)}else this.columnModel.setColumnAggFunc(this.column,t,"toolPanelDragAndDrop")},s)}isGroupingAndLocked(){return this.isGroupingZone()&&this.columnModel.isColumnGroupingLocked(this.column)}isAggregationZone(){return"aggregation"===this.dropZonePurpose}isGroupingZone(){return"rowGroup"===this.dropZonePurpose}getDragSourceType(){return r.qRA.ToolPanel}destroy(){super.destroy(),this.column=null}};Zs([(0,r.dsm)("popupService")],go.prototype,"popupService",2),Zs([(0,r.dsm)("sortController")],go.prototype,"sortController",2),Zs([(0,r.dsm)("columnModel")],go.prototype,"columnModel",2),Zs([(0,r.Xx1)("aggFuncService")],go.prototype,"aggFuncService",2),Zs([(0,r.PIB)("eSortIndicator")],go.prototype,"eSortIndicator",2);var fo=class extends r.uAl{constructor(e,t){super('<div class="ag-select-agg-func-item"/>'),this.selectItem=e,this.getGui().innerText=t,this.addGuiEventListener("click",this.selectItem)}},mo=class extends r.fNO{constructor(e,t){super(e),this.dropZonePurpose=t}init(e){super.init(e),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.refreshGui.bind(this)),this.addManagedPropertyListeners(["functionsReadOnly","rowGroupPanelSuppressSort","groupLockGroupColumns"],this.refreshGui.bind(this))}getItems(e){var t;return null!=(t=e.columns)?t:[]}isInterestedIn(e){return e===r.qRA.HeaderCell||e===r.qRA.ToolPanel}minimumAllowedNewInsertIndex(){const e=this.gos.get("groupLockGroupColumns"),t=this.columnModel.getRowGroupColumns().length;return-1===e?t:Math.min(e,t)}showOrHideColumnOnExit(e){return this.isRowGroupPanel()&&!this.gos.get("suppressRowGroupHidesColumns")&&!e.fromNudge}handleDragEnterEnd(e){if(this.showOrHideColumnOnExit(e)){const t=e.dragSource.getDragItem().columns;this.setColumnsVisible(t,!1,"uiColumnDragged")}}handleDragLeaveEnd(e){if(this.showOrHideColumnOnExit(e)){const t=e.dragSource.getDragItem();this.setColumnsVisible(t.columns,!0,"uiColumnDragged")}}setColumnsVisible(e,t,i){if(e){const r=e.filter(e=>!e.getColDef().lockVisible);this.columnModel.setColumnsVisible(r,t,i)}}isRowGroupPanel(){return"rowGroup"===this.dropZonePurpose}refreshOnDragStop(){return!this.gos.get("functionsPassive")}createPillComponent(e,t,i,r){return new go(e,t,i,this.dropZonePurpose,r)}};Zs([(0,r.dsm)("columnModel")],mo.prototype,"columnModel",2);var vo=class extends mo{constructor(e){super(e,"rowGroup")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("rowGroupColumnsEmptyMessage","Drag here to set row groups"),i=e("groups","Row Groups");super.init({icon:r._.createIconNoSpan("rowGroupPanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,this.refreshGui.bind(this))}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaRowGroupDropZonePanelLabel","Row Groups")}getTooltipParams(){const e=super.getTooltipParams();return e.location="rowGroupColumnsList",e}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowRowGroup()&&(!e.isRowGroupActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setRowGroupColumns(e,"toolPanelUi")}getIconName(){return this.isPotentialDndItems()?r.WO_.ICON_GROUP:r.WO_.ICON_NOT_ALLOWED}getExistingItems(){return this.columnModel.getRowGroupColumns()}};Zs([r.o7C],vo.prototype,"passBeansUp",1);var Co=class extends mo{constructor(e){super(e,"pivot")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("pivotColumnsEmptyMessage","Drag here to set column labels"),i=e("pivots","Column Labels");super.init({icon:r._.createIconNoSpan("pivotPanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.refresh.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_CHANGED,this.refresh.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.checkVisibility.bind(this)),this.refresh()}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaPivotDropZonePanelLabel","Column Labels")}getTooltipParams(){const e=super.getTooltipParams();return e.location="pivotColumnsList",e}refresh(){this.checkVisibility(),this.refreshGui()}checkVisibility(){const e=this.columnModel.isPivotMode();if(this.isHorizontal())switch(this.gos.get("pivotPanelShow")){case"always":this.setDisplayed(e);break;case"onlyWhenPivoting":const t=this.columnModel.isPivotActive();this.setDisplayed(e&&t);break;default:this.setDisplayed(!1)}else this.setDisplayed(e)}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowPivot()&&(!e.isPivotActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:r.sVA.EVENT_COLUMN_PIVOT_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setPivotColumns(e,"toolPanelUi")}getIconName(){return this.isPotentialDndItems()?r.WO_.ICON_PIVOT:r.WO_.ICON_NOT_ALLOWED}getExistingItems(){return this.columnModel.getPivotColumns()}};Zs([r.o7C],Co.prototype,"passBeansUp",1);var yo=class extends r.uAl{constructor(){super()}postConstruct(){this.setGui(this.createNorthPanel()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onRowGroupChanged()),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,()=>this.onRowGroupChanged()),this.addManagedPropertyListener("rowGroupPanelShow",()=>this.onRowGroupChanged()),this.addManagedPropertyListener("pivotPanelShow",()=>this.onPivotPanelShow()),this.onRowGroupChanged()}createNorthPanel(){const e=document.createElement("div");return e.classList.add("ag-column-drop-wrapper"),r._.setAriaRole(e,"presentation"),this.rowGroupComp=new vo(!0),this.createManagedBean(this.rowGroupComp),this.pivotComp=new Co(!0),this.createManagedBean(this.pivotComp),e.appendChild(this.rowGroupComp.getGui()),e.appendChild(this.pivotComp.getGui()),this.addManagedListener(this.rowGroupComp,r.uAl.EVENT_DISPLAYED_CHANGED,()=>this.onDropPanelVisible()),this.addManagedListener(this.pivotComp,r.uAl.EVENT_DISPLAYED_CHANGED,()=>this.onDropPanelVisible()),this.onDropPanelVisible(),e}onDropPanelVisible(){const e=this.rowGroupComp.isDisplayed()&&this.pivotComp.isDisplayed();this.rowGroupComp.addOrRemoveCssClass("ag-column-drop-horizontal-half-width",e),this.pivotComp.addOrRemoveCssClass("ag-column-drop-horizontal-half-width",e)}onRowGroupChanged(){if(!this.rowGroupComp)return;const e=this.gos.get("rowGroupPanelShow");if("always"===e)this.rowGroupComp.setDisplayed(!0);else if("onlyWhenGrouping"===e){const e=!this.columnModel.isRowGroupEmpty();this.rowGroupComp.setDisplayed(e)}else this.rowGroupComp.setDisplayed(!1)}onPivotPanelShow(){if(!this.pivotComp)return;const e=this.gos.get("pivotPanelShow");if("always"===e)this.pivotComp.setDisplayed(!0);else if("onlyWhenPivoting"===e){const e=this.columnModel.isPivotActive();this.pivotComp.setDisplayed(e)}else this.pivotComp.setDisplayed(!1)}};Zs([(0,r.dsm)("columnModel")],yo.prototype,"columnModel",2),Zs([r.o7C],yo.prototype,"postConstruct",1);var wo=class extends r.XQb{execute(e){const t=this.columnModel.isPivotMode(),i=this.filterManager.isAggregateFilterPresent()||this.filterManager.isAggregateQuickFilterPresent(),r=this.gos.getGroupAggFiltering()||(t?e=>e.node.leafGroup:e=>!e.node.group),{changedPath:n}=e,s=(e,t=!1)=>{e.childrenAfterFilter&&(e.childrenAfterAggFilter=e.childrenAfterFilter,t&&e.childrenAfterAggFilter.forEach(e=>s(e,t)),this.setAllChildrenCount(e)),e.sibling&&(e.sibling.childrenAfterAggFilter=e.childrenAfterAggFilter)};n.forEachChangedNodeDepthFirst(i?e=>{var t;e.childrenAfterAggFilter=(null==(t=e.childrenAfterFilter)?void 0:t.filter(e=>{var t;return r({node:e})&&this.filterManager.doesRowPassAggregateFilters({rowNode:e})?(s(e,!0),!0):null==(t=e.childrenAfterAggFilter)?void 0:t.length}))||null,this.setAllChildrenCount(e),e.sibling&&(e.sibling.childrenAfterAggFilter=e.childrenAfterAggFilter)}:s,!0)}setAllChildrenCountTreeData(e){let t=0;e.childrenAfterAggFilter.forEach(e=>{t++,t+=e.allChildrenCount}),e.setAllChildrenCount(t)}setAllChildrenCountGridGrouping(e){let t=0;e.childrenAfterAggFilter.forEach(e=>{e.group?t+=e.allChildrenCount:t++}),e.setAllChildrenCount(t)}setAllChildrenCount(e){e.hasChildren()?this.gos.get("treeData")?this.setAllChildrenCountTreeData(e):this.setAllChildrenCountGridGrouping(e):e.setAllChildrenCount(null)}};Zs([(0,r.dsm)("filterManager")],wo.prototype,"filterManager",2),Zs([(0,r.dsm)("columnModel")],wo.prototype,"columnModel",2),wo=Zs([(0,r.dR4)("filterAggregatesStage")],wo);var So=class e extends r.aJZ{constructor(){super('\n            <div class="ag-group-filter">\n                <div ref="eGroupField"></div>\n                <div ref="eUnderlyingFilter"></div>\n            </div>\n        ')}postConstruct(){this.initialiseTabGuard({})}init(e){return this.params=e,this.validateParams(),this.updateGroups().then(()=>{this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onColumnRowGroupChanged())})}validateParams(){const{colDef:e}=this.params;e.field&&r._.warnOnce('Group Column Filter does not work with the colDef property "field". This property will be ignored.'),e.filterValueGetter&&r._.warnOnce('Group Column Filter does not work with the colDef property "filterValueGetter". This property will be ignored.'),e.filterParams&&r._.warnOnce('Group Column Filter does not work with the colDef property "filterParams". This property will be ignored.')}updateGroups(){const e=this.updateGroupField();return this.getUnderlyingFilters(e)}getSourceColumns(){if(this.groupColumn=this.params.column,this.gos.get("treeData"))return r._.warnOnce("Group Column Filter does not work with Tree Data enabled. Please disable Tree Data, or use a different filter."),[];return this.columnModel.getSourceColumnsForGroupColumn(this.groupColumn)||(r._.warnOnce("Group Column Filter only works on group columns. Please use a different filter."),[])}updateGroupField(){r._.clearElement(this.eGroupField),this.eGroupFieldSelect&&this.destroyBean(this.eGroupFieldSelect);const e=this.getSourceColumns(),t=e.filter(e=>e.isFilterAllowed());return t.length?(1===e.length?(this.selectedColumn=t[0],r._.setDisplayed(this.eGroupField,!1)):(this.selectedColumn&&t.some(e=>e.getId()===this.selectedColumn.getId())||(this.selectedColumn=t[0]),this.createGroupFieldSelectElement(t),this.eGroupField.appendChild(this.eGroupFieldSelect.getGui()),this.eGroupField.appendChild(r._.loadTemplate('<div class="ag-filter-separator"></div>')),r._.setDisplayed(this.eGroupField,!0)),t):(this.selectedColumn=void 0,r._.setDisplayed(this.eGroupField,!1),null)}createGroupFieldSelectElement(e){this.eGroupFieldSelect=this.createManagedBean(new r.Ju4);const t=this.localeService.getLocaleTextFunc();this.eGroupFieldSelect.setLabel(t("groupFilterSelect","Select field:")),this.eGroupFieldSelect.setLabelAlignment("top"),this.eGroupFieldSelect.addOptions(e.map(e=>{var t;return{value:e.getId(),text:null!=(t=this.columnModel.getDisplayNameForColumn(e,"groupFilter",!1))?t:void 0}})),this.eGroupFieldSelect.setValue(this.selectedColumn.getId()),this.eGroupFieldSelect.onValueChange(e=>this.updateSelectedColumn(e)),this.eGroupFieldSelect.addCssClass("ag-group-filter-field-select-wrapper"),1===e.length&&this.eGroupFieldSelect.setDisabled(!0)}getUnderlyingFilters(e){if(!e)return this.filterColumnPairs=void 0,this.selectedFilter=void 0,this.groupColumn.setFilterActive(!1,"columnRowGroupChanged"),r.oY$.resolve();const t=[],i=[];return e.forEach(e=>{const r=this.filterManager.getOrCreateFilterWrapper(e,"COLUMN_MENU");(null==r?void 0:r.filterPromise)&&t.push(r.filterPromise.then(t=>(t&&i.push({filter:t,column:e}),e.getId()===this.selectedColumn.getId()&&(this.selectedFilter=null!=t?t:void 0),t)))}),r.oY$.all(t).then(()=>{this.filterColumnPairs=i,this.groupColumn.setFilterActive(this.isFilterActive(),"columnRowGroupChanged")})}addUnderlyingFilterElement(){var e,t;if(r._.clearElement(this.eUnderlyingFilter),!this.selectedColumn)return r.oY$.resolve();const i=this.createManagedBean(new r.jfj(this.selectedColumn,"COLUMN_MENU"));return this.filterWrapperComp=i,i.hasFilter()?(this.eUnderlyingFilter.appendChild(i.getGui()),null!=(t=null==(e=i.getFilter())?void 0:e.then(()=>{var e,t;null==(e=i.afterGuiAttached)||e.call(i,this.afterGuiAttachedParams),(null==(t=this.afterGuiAttachedParams)?void 0:t.suppressFocus)||!this.eGroupFieldSelect||this.eGroupFieldSelect.isDisabled()||this.eGroupFieldSelect.getFocusableElement().focus()}))?t:r.oY$.resolve()):r.oY$.resolve()}updateSelectedColumn(t){var i;if(!t)return;null==(i=this.filterWrapperComp)||i.afterGuiDetached(),this.destroyBean(this.filterWrapperComp);const r=this.getFilterColumnPair(t);this.selectedColumn=null==r?void 0:r.column,this.selectedFilter=null==r?void 0:r.filter,this.dispatchEvent({type:e.EVENT_SELECTED_COLUMN_CHANGED}),this.addUnderlyingFilterElement()}isFilterActive(){var e;return!!(null==(e=this.filterColumnPairs)?void 0:e.some(({filter:e})=>e.isFilterActive()))}doesFilterPass(){return!0}getModel(){return null}setModel(){return r.oY$.resolve()}afterGuiAttached(e){this.afterGuiAttachedParams=e,this.addUnderlyingFilterElement()}afterGuiDetached(){var e,t;r._.clearElement(this.eUnderlyingFilter),null==(t=null==(e=this.selectedFilter)?void 0:e.afterGuiDetached)||t.call(e)}onColumnRowGroupChanged(){this.updateGroups().then(()=>{this.dispatchEvent({type:e.EVENT_COLUMN_ROW_GROUP_CHANGED}),this.eventService.dispatchEvent({type:"filterAllowedUpdated"})})}getFilterColumnPair(e){var t;if(e)return null==(t=this.filterColumnPairs)?void 0:t.find(({column:t})=>t.getId()===e)}getSelectedFilter(){return this.selectedFilter}getSelectedColumn(){return this.selectedColumn}isFilterAllowed(){return!!this.selectedColumn}destroy(){super.destroy()}};So.EVENT_COLUMN_ROW_GROUP_CHANGED="columnRowGroupChanged",So.EVENT_SELECTED_COLUMN_CHANGED="selectedColumnChanged",Zs([(0,r.dsm)("filterManager")],So.prototype,"filterManager",2),Zs([(0,r.dsm)("columnModel")],So.prototype,"columnModel",2),Zs([(0,r.PIB)("eGroupField")],So.prototype,"eGroupField",2),Zs([(0,r.PIB)("eUnderlyingFilter")],So.prototype,"eUnderlyingFilter",2),Zs([r.o7C],So.prototype,"postConstruct",1);var bo=So,Eo=class extends r.uAl{constructor(){super('\n            <div ref="eFloatingFilter" class="ag-group-floating-filter ag-floating-filter-input" role="presentation"></div>\n        '),this.haveAddedColumnListeners=!1}init(e){this.params=e;const t="multipleColumns"===this.gos.get("groupDisplayType");return new r.oY$(e=>{this.params.parentFilterInstance(i=>{this.parentFilterInstance=i,t?this.setupUnderlyingFloatingFilterElement().then(()=>e()):(this.setupReadOnlyFloatingFilterElement(),e())})}).then(()=>{this.addManagedListener(this.parentFilterInstance,bo.EVENT_SELECTED_COLUMN_CHANGED,()=>this.onSelectedColumnChanged()),this.addManagedListener(this.parentFilterInstance,bo.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.onColumnRowGroupChanged())})}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams()}setParams(){var e;const t=this.columnModel.getDisplayNameForColumn(this.params.column,"header",!0),i=this.localeService.getLocaleTextFunc();null==(e=this.eFloatingFilterText)||e.setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}setupReadOnlyFloatingFilterElement(){this.eFloatingFilterText||(this.eFloatingFilterText=this.createManagedBean(new r.stt),this.eFloatingFilterText.setDisabled(!0).addGuiEventListener("click",()=>this.params.showParentFilter()),this.setParams()),this.updateDisplayedValue(),this.eFloatingFilter.appendChild(this.eFloatingFilterText.getGui())}setupUnderlyingFloatingFilterElement(){this.showingUnderlyingFloatingFilter=!1,this.underlyingFloatingFilter=void 0,r._.clearElement(this.eFloatingFilter);const e=this.parentFilterInstance.getSelectedColumn();if(e&&!e.isVisible()){const t=this.filterManager.getFloatingFilterCompDetails(e,this.params.showParentFilter);if(t)return this.compDetails=t,this.haveAddedColumnListeners||(this.haveAddedColumnListeners=!0,this.addManagedListener(e,r.VPZ.EVENT_VISIBLE_CHANGED,this.onColumnVisibleChanged.bind(this)),this.addManagedListener(e,r.VPZ.EVENT_COL_DEF_CHANGED,this.onColDefChanged.bind(this))),t.newAgStackInstance().then(e=>{var t,i;this.underlyingFloatingFilter=e,null==(i=this.underlyingFloatingFilter)||i.onParentModelChanged(null==(t=this.parentFilterInstance.getSelectedFilter())?void 0:t.getModel()),this.appendChild(e.getGui()),this.showingUnderlyingFloatingFilter=!0})}return this.setupReadOnlyFloatingFilterElement(),r.oY$.resolve()}onColumnVisibleChanged(){this.setupUnderlyingFloatingFilterElement()}onColDefChanged(e){var t,i,r;if(!e.column)return;const n=this.filterManager.getFloatingFilterCompDetails(e.column,this.params.showParentFilter);n&&((null==(t=this.underlyingFloatingFilter)?void 0:t.refresh)?this.underlyingFloatingFilter.refresh(n.params):null==(r=null==(i=this.underlyingFloatingFilter)?void 0:i.onParamsUpdated)||r.call(i,n.params))}onParentModelChanged(e,t){var i,r;this.showingUnderlyingFloatingFilter?null==(r=this.underlyingFloatingFilter)||r.onParentModelChanged(null==(i=this.parentFilterInstance.getSelectedFilter())?void 0:i.getModel(),t):this.updateDisplayedValue()}updateDisplayedValue(){if(!this.parentFilterInstance||!this.eFloatingFilterText)return;const e=this.parentFilterInstance.getSelectedFilter();if(!e)return this.eFloatingFilterText.setValue(""),void this.eFloatingFilterText.setDisplayed(!1);if(this.eFloatingFilterText.setDisplayed(!0),e.getModelAsString){const t=e.getModel();this.eFloatingFilterText.setValue(null==t?"":e.getModelAsString(t))}else this.eFloatingFilterText.setValue("")}onSelectedColumnChanged(){this.showingUnderlyingFloatingFilter||this.updateDisplayedValue()}onColumnRowGroupChanged(){this.showingUnderlyingFloatingFilter||this.updateDisplayedValue()}destroy(){super.destroy()}};Zs([(0,r.dsm)("columnModel")],Eo.prototype,"columnModel",2),Zs([(0,r.dsm)("filterManager")],Eo.prototype,"filterManager",2),Zs([(0,r.PIB)("eFloatingFilter")],Eo.prototype,"eFloatingFilter",2);var Ao={version:"31.3.4",moduleName:r.zsj.RowGroupingModule,beans:[Js,wo,to,io,ro,so],agStackComponents:[{componentName:"AgGridHeaderDropZones",componentClass:yo}],userComponents:[{componentName:"agGroupColumnFilter",componentClass:bo},{componentName:"agGroupColumnFloatingFilter",componentClass:Eo}],dependantModules:[S]},To=class extends mo{constructor(e){super(e,"aggregation")}passBeansUp(){const e=this.localeService.getLocaleTextFunc(),t=e("valueColumnsEmptyMessage","Drag here to aggregate"),i=e("values","Values");super.init({icon:r._.createIconNoSpan("valuePanel",this.gos,null),emptyMessage:t,title:i}),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_VALUE_CHANGED,this.refreshGui.bind(this))}getAriaLabel(){return this.localeService.getLocaleTextFunc()("ariaValuesDropZonePanelLabel","Values")}getTooltipParams(){const e=super.getTooltipParams();return e.location="valueColumnsList",e}getIconName(){return this.isPotentialDndItems()?r.WO_.ICON_AGGREGATE:r.WO_.ICON_NOT_ALLOWED}isItemDroppable(e,t){return!(this.gos.get("functionsReadOnly")||!e.isPrimary())&&e.isAllowValue()&&(!e.isValueActive()||this.isSourceEventFromTarget(t))}updateItems(e){if(this.gos.get("functionsPassive")){const t={type:r.sVA.EVENT_COLUMN_VALUE_CHANGE_REQUEST,columns:e};this.eventService.dispatchEvent(t)}else this.columnModel.setValueColumns(e,"toolPanelUi")}getExistingItems(){return this.columnModel.getValueColumns()}};Zs([r.o7C],To.prototype,"passBeansUp",1);var Mo=Object.defineProperty,Ro=Object.defineProperties,_o=Object.getOwnPropertyDescriptor,Po=Object.getOwnPropertyDescriptors,xo=Object.getOwnPropertySymbols,Do=Object.prototype.hasOwnProperty,Io=Object.prototype.propertyIsEnumerable,Lo=(e,t,i)=>t in e?Mo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,No=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?_o(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Mo(t,i,s),s},Oo=class extends r.uAl{constructor(){super('<div class="ag-tool-panel-horizontal-resize"></div>'),this.minWidth=100,this.maxWidth=null}setElementToResize(e){this.elementToResize=e}postConstruct(){const e=this.horizontalResizeService.addResizeBar({eResizeBar:this.getGui(),dragStartPixels:1,onResizeStart:this.onResizeStart.bind(this),onResizing:this.onResizing.bind(this),onResizeEnd:this.onResizeEnd.bind(this)});this.addDestroyFunc(e),this.setInverted(this.gos.get("enableRtl"))}dispatchResizeEvent(e,t,i){const n={type:r.sVA.EVENT_TOOL_PANEL_SIZE_CHANGED,width:i,started:e,ended:t};this.eventService.dispatchEvent(n)}onResizeStart(){this.startingWidth=this.elementToResize.offsetWidth,this.dispatchResizeEvent(!0,!1,this.startingWidth)}onResizeEnd(e){return this.onResizing(e,!0)}onResizing(e,t=!1){const i=this.inverted?-1:1;let r=Math.max(this.minWidth,Math.floor(this.startingWidth-e*i));null!=this.maxWidth&&(r=Math.min(this.maxWidth,r)),this.elementToResize.style.width=`${r}px`,this.dispatchResizeEvent(!1,t,r)}setInverted(e){this.inverted=e}setMaxWidth(e){this.maxWidth=e}setMinWidth(e){this.minWidth=null!=e?e:100}};No([(0,r.dsm)("horizontalResizeService")],Oo.prototype,"horizontalResizeService",2),No([r.o7C],Oo.prototype,"postConstruct",1);var Fo=class e extends r.uAl{constructor(e){super(),this.toolPanelDef=e}getToolPanelId(){return this.toolPanelDef.id}postConstruct(){const e=this.createTemplate();this.setTemplate(e),this.setLabel(),this.setIcon(),this.addManagedListener(this.eToggleButton,"click",this.onButtonPressed.bind(this)),this.eToggleButton.setAttribute("id",`ag-${this.getCompId()}-button`)}createTemplate(){return'<div class="ag-side-button" role="presentation">\n                <button type="button" ref="eToggleButton" tabindex="-1" role="tab" aria-expanded="false" class="ag-button ag-side-button-button">\n                    <div ref="eIconWrapper" class="ag-side-button-icon-wrapper" aria-hidden="true"></div>\n                    <span ref ="eLabel" class="ag-side-button-label"></span>\n                </button>\n            </div>'}setLabel(){const e=this.localeService.getLocaleTextFunc(),t=this.toolPanelDef,i=e(t.labelKey,t.labelDefault);this.eLabel.innerText=i}setIcon(){this.eIconWrapper.insertAdjacentElement("afterbegin",r._.createIconNoSpan(this.toolPanelDef.iconKey,this.gos))}onButtonPressed(){this.dispatchEvent({type:e.EVENT_TOGGLE_BUTTON_CLICKED})}setSelected(e){this.addOrRemoveCssClass("ag-selected",e),r._.setAriaExpanded(this.eToggleButton,e)}getButtonElement(){return this.eToggleButton}};Fo.EVENT_TOGGLE_BUTTON_CLICKED="toggleButtonClicked",No([(0,r.PIB)("eToggleButton")],Fo.prototype,"eToggleButton",2),No([(0,r.PIB)("eIconWrapper")],Fo.prototype,"eIconWrapper",2),No([(0,r.PIB)("eLabel")],Fo.prototype,"eLabel",2),No([r.o7C],Fo.prototype,"postConstruct",1);var ko=Fo,Go=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.buttonComps=[]}postConstruct(){this.addManagedListener(this.getFocusableElement(),"keydown",this.handleKeyDown.bind(this))}handleKeyDown(e){if(e.key!==r.DDm.TAB||!e.shiftKey)return;const t=r._.last(this.columnModel.getAllDisplayedColumns());this.focusService.focusGridView(t,!0)&&e.preventDefault()}setActiveButton(e){this.buttonComps.forEach(t=>{t.setSelected(e===t.getToolPanelId())})}addButtonComp(t){const i=this.createBean(new ko(t));return this.buttonComps.push(i),this.appendChild(i),i.addEventListener(ko.EVENT_TOGGLE_BUTTON_CLICKED,()=>{this.dispatchEvent({type:e.EVENT_SIDE_BAR_BUTTON_CLICKED,toolPanelId:t.id})}),i}clearButtons(){this.buttonComps=this.destroyBeans(this.buttonComps),r._.clearElement(this.getGui())}};Go.EVENT_SIDE_BAR_BUTTON_CLICKED="sideBarButtonClicked",Go.TEMPLATE='<div class="ag-side-buttons" role="tablist"></div>',No([(0,r.dsm)("focusService")],Go.prototype,"focusService",2),No([(0,r.dsm)("columnModel")],Go.prototype,"columnModel",2),No([r.o7C],Go.prototype,"postConstruct",1),No([r.yah],Go.prototype,"clearButtons",1);var Vo=Go,Ho=class e{static parse(t){if(t){if(!0===t)return{toolPanels:[e.DEFAULT_COLUMN_COMP,e.DEFAULT_FILTER_COMP],defaultToolPanel:"columns"};if("string"==typeof t)return e.parse([t]);if(Array.isArray(t)){const i=[];if(t.forEach(t=>{const r=e.DEFAULT_BY_KEY[t];r?i.push(r):console.warn(`AG Grid: the key ${t} is not a valid key for specifying a tool panel, valid keys are: ${Object.keys(e.DEFAULT_BY_KEY).join(",")}`)}),0===i.length)return;return{toolPanels:i,defaultToolPanel:i[0].id}}return{toolPanels:e.parseComponents(t.toolPanels),defaultToolPanel:t.defaultToolPanel,hiddenByDefault:t.hiddenByDefault,position:t.position}}}static parseComponents(t){const i=[];return t?(t.forEach(t=>{let r=null;if("string"==typeof t){const i=e.DEFAULT_BY_KEY[t];if(!i)return void console.warn(`AG Grid: the key ${t} is not a valid key for specifying a tool panel, valid keys are: ${Object.keys(e.DEFAULT_BY_KEY).join(",")}`);r=i}else r=t;i.push(r)}),i):i}};Ho.DEFAULT_COLUMN_COMP={id:"columns",labelDefault:"Columns",labelKey:"columns",iconKey:"columns",toolPanel:"agColumnsToolPanel"},Ho.DEFAULT_FILTER_COMP={id:"filters",labelDefault:"Filters",labelKey:"filters",iconKey:"filter",toolPanel:"agFiltersToolPanel"},Ho.DEFAULT_BY_KEY={columns:Ho.DEFAULT_COLUMN_COMP,filters:Ho.DEFAULT_FILTER_COMP};var Bo=Ho,zo=class e extends r.uAl{constructor(){super(e.TEMPLATE)}setupResize(){const e=this.getGui(),t=this.resizeBar=this.createManagedBean(new Oo);e.setAttribute("id",`ag-${this.getCompId()}`),t.setElementToResize(e),this.appendChild(t)}getToolPanelId(){return this.toolPanelId}setToolPanelDef(e,t){const{id:i,minWidth:r,maxWidth:n,width:s}=e;this.toolPanelId=i,this.width=s;const o=this.userComponentFactory.getToolPanelCompDetails(e,t),a=o.newAgStackInstance();this.params=o.params,null!=a?(a.then(this.setToolPanelComponent.bind(this)),null!=r&&this.resizeBar.setMinWidth(r),null!=n&&this.resizeBar.setMaxWidth(n)):console.warn(`AG Grid: error processing tool panel component ${i}. You need to specify 'toolPanel'`)}setToolPanelComponent(e){this.toolPanelCompInstance=e,this.appendChild(e.getGui()),this.addDestroyFunc(()=>{this.destroyBean(e)}),this.width&&(this.getGui().style.width=`${this.width}px`)}getToolPanelInstance(){return this.toolPanelCompInstance}setResizerSizerSide(e){const t="left"===e,i=this.gos.get("enableRtl")?t:!t;this.resizeBar.setInverted(i)}refresh(){this.toolPanelCompInstance.refresh(this.params)}};zo.TEMPLATE='<div class="ag-tool-panel-wrapper" role="tabpanel"/>',No([(0,r.dsm)("userComponentFactory")],zo.prototype,"userComponentFactory",2),No([r.o7C],zo.prototype,"setupResize",1);var Uo=zo,Wo=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.toolPanelWrappers=[]}postConstruct(){var e;this.sideBarButtonsComp.addEventListener(Vo.EVENT_SIDE_BAR_BUTTON_CLICKED,this.onToolPanelButtonClicked.bind(this));const{sideBar:t}=null!=(e=this.gos.get("initialState"))?e:{};this.setSideBarDef({sideBarDef:Bo.parse(this.gos.get("sideBar")),sideBarState:t}),this.addManagedPropertyListener("sideBar",this.onSideBarUpdated.bind(this)),this.sideBarService.registerSideBarComp(this),this.createManagedBean(new r.G21(this.getFocusableElement(),{onTabKeyDown:this.onTabKeyDown.bind(this),handleKeyDown:this.handleKeyDown.bind(this)}))}onTabKeyDown(e){if(e.defaultPrevented)return;const{focusService:t,sideBarButtonsComp:i}=this,r=this.getGui(),n=i.getGui(),s=this.gos.getActiveDomElement(),o=r.querySelector(".ag-tool-panel-wrapper:not(.ag-hidden)"),a=e.target;if(!o)return;if(n.contains(s))return void(t.focusInto(o,e.shiftKey)&&e.preventDefault());if(!e.shiftKey)return;let l=null;o.contains(s)?l=this.focusService.findNextFocusableElement(o,void 0,!0):t.isTargetUnderManagedComponent(o,a)&&e.shiftKey&&(l=this.focusService.findFocusableElementBeforeTabGuard(o,a)),l||(l=n.querySelector(".ag-selected button")),l&&l!==e.target&&(e.preventDefault(),l.focus())}handleKeyDown(e){const t=this.gos.getActiveDomElement();if(!this.sideBarButtonsComp.getGui().contains(t))return;const i=this.sideBarButtonsComp.getGui(),n=Array.prototype.slice.call(i.querySelectorAll(".ag-side-button")),s=n.findIndex(e=>e.contains(t));let o=null;switch(e.key){case r.DDm.LEFT:case r.DDm.UP:o=Math.max(0,s-1);break;case r.DDm.RIGHT:case r.DDm.DOWN:o=Math.min(s+1,n.length-1)}if(null===o)return;const a=n[o].querySelector("button");a&&(a.focus(),e.preventDefault())}onToolPanelButtonClicked(e){const t=e.toolPanelId;this.openedItem()===t?this.openToolPanel(void 0,"sideBarButtonClicked"):this.openToolPanel(t,"sideBarButtonClicked")}clearDownUi(){this.sideBarButtonsComp.clearButtons(),this.destroyToolPanelWrappers()}setSideBarDef({sideBarDef:e,sideBarState:t,existingToolPanelWrappers:i}){if(this.setDisplayed(!1),this.sideBar=e,this.sideBar&&this.sideBar.toolPanels){const e=this.sideBar.toolPanels;if(this.createToolPanelsAndSideButtons(e,t,i),!this.toolPanelWrappers.length)return;const r=t?t.visible:!this.sideBar.hiddenByDefault;if(this.setDisplayed(r),this.setSideBarPosition(t?t.position:this.sideBar.position),r)if(t){const{openToolPanel:e}=t;e&&this.openToolPanel(e,"sideBarInitializing")}else this.openToolPanel(this.sideBar.defaultToolPanel,"sideBarInitializing")}}getDef(){return this.sideBar}setSideBarPosition(e){e||(e="right"),this.position=e;const t="left"===e,i=t?"right":"left";return this.addOrRemoveCssClass("ag-side-bar-left",t),this.addOrRemoveCssClass("ag-side-bar-right",!t),this.toolPanelWrappers.forEach(e=>{e.setResizerSizerSide(i)}),this.eventService.dispatchEvent({type:r.sVA.EVENT_SIDE_BAR_UPDATED}),this}setDisplayed(e,t){super.setDisplayed(e,t),this.eventService.dispatchEvent({type:r.sVA.EVENT_SIDE_BAR_UPDATED})}getState(){const e={};return this.toolPanelWrappers.forEach(t=>{var i,r;e[t.getToolPanelId()]=null==(r=null==(i=t.getToolPanelInstance())?void 0:i.getState)?void 0:r.call(i)}),{visible:this.isDisplayed(),position:this.position,openToolPanel:this.openedItem(),toolPanels:e}}createToolPanelsAndSideButtons(e,t,i){var r;for(const n of e)this.createToolPanelAndSideButton(n,null==(r=null==t?void 0:t.toolPanels)?void 0:r[n.id],null==i?void 0:i[n.id])}validateDef(e){if(null==e.id)return console.warn("AG Grid: please review all your toolPanel components, it seems like at least one of them doesn't have an id"),!1;if("agColumnsToolPanel"===e.toolPanel&&!r.syG.__assertRegistered(r.zsj.ColumnsToolPanelModule,"Column Tool Panel",this.context.getGridId()))return!1;if("agFiltersToolPanel"===e.toolPanel){if(!r.syG.__assertRegistered(r.zsj.FiltersToolPanelModule,"Filters Tool Panel",this.context.getGridId()))return!1;if(this.filterManager.isAdvancedFilterEnabled())return r._.warnOnce("Advanced Filter does not work with Filters Tool Panel. Filters Tool Panel has been disabled."),!1}return!0}createToolPanelAndSideButton(e,t,i){if(!this.validateDef(e))return;const n=this.sideBarButtonsComp.addButtonComp(e);let s;i?s=i:(s=this.getContext().createBean(new Uo),s.setToolPanelDef(e,{initialState:t,onStateUpdated:()=>this.eventService.dispatchEvent({type:r.sVA.EVENT_SIDE_BAR_UPDATED})})),s.setDisplayed(!1);const o=s.getGui();this.appendChild(o),this.toolPanelWrappers.push(s),r._.setAriaControls(n.getButtonElement(),o)}refresh(){this.toolPanelWrappers.forEach(e=>e.refresh())}openToolPanel(e,t="api"){const i=this.openedItem();i!==e&&(this.toolPanelWrappers.forEach(t=>{const i=e===t.getToolPanelId();t.setDisplayed(i)}),i!==this.openedItem()&&(this.sideBarButtonsComp.setActiveButton(e),this.raiseToolPanelVisibleEvent(e,null!=i?i:void 0,t)))}getToolPanelInstance(e){const t=this.toolPanelWrappers.filter(t=>t.getToolPanelId()===e)[0];if(t)return t.getToolPanelInstance();console.warn(`AG Grid: unable to lookup Tool Panel as invalid key supplied: ${e}`)}raiseToolPanelVisibleEvent(e,t,i){const n=!!e&&!!t;if(t){const e={type:r.sVA.EVENT_TOOL_PANEL_VISIBLE_CHANGED,source:i,key:t,visible:!1,switchingToolPanel:n};this.eventService.dispatchEvent(e)}if(e){const t={type:r.sVA.EVENT_TOOL_PANEL_VISIBLE_CHANGED,source:i,key:e,visible:!0,switchingToolPanel:n};this.eventService.dispatchEvent(t)}}close(e="api"){this.openToolPanel(void 0,e)}isToolPanelShowing(){return!!this.openedItem()}openedItem(){let e=null;return this.toolPanelWrappers.forEach(t=>{t.isDisplayed()&&(e=t.getToolPanelId())}),e}onSideBarUpdated(){var e;const t=Bo.parse(this.gos.get("sideBar"));let i={};t&&this.sideBar&&(null==(e=t.toolPanels)||e.forEach(e=>{var t,n;const{id:s}=e;if(!s)return;const o=null==(t=this.sideBar.toolPanels)?void 0:t.find(e=>e.id===s);if(!o||e.toolPanel!==o.toolPanel)return;const a=this.toolPanelWrappers.find(e=>e.getToolPanelId()===s);if(!a)return;const l=this.gos.addGridCommonParams((c=((e,t)=>{for(var i in t||(t={}))Do.call(t,i)&&Lo(e,i,t[i]);if(xo)for(var i of xo(t))Io.call(t,i)&&Lo(e,i,t[i]);return e})({},null!=(n=e.toolPanelParams)?n:{}),Ro(c,Po({onStateUpdated:()=>this.eventService.dispatchEvent({type:r.sVA.EVENT_SIDE_BAR_UPDATED})}))));var c;!0===a.getToolPanelInstance().refresh(l)&&(this.toolPanelWrappers=this.toolPanelWrappers.filter(e=>e!==a),r._.removeFromParent(a.getGui()),i[s]=a)})),this.clearDownUi(),this.setSideBarDef({sideBarDef:t,existingToolPanelWrappers:i})}destroyToolPanelWrappers(){this.toolPanelWrappers.forEach(e=>{r._.removeFromParent(e.getGui()),this.destroyBean(e)}),this.toolPanelWrappers.length=0}destroy(){this.destroyToolPanelWrappers(),super.destroy()}};Wo.TEMPLATE='<div class="ag-side-bar ag-unselectable">\n            <ag-side-bar-buttons ref="sideBarButtons"></ag-side-bar-buttons>\n        </div>',No([(0,r.dsm)("focusService")],Wo.prototype,"focusService",2),No([(0,r.dsm)("filterManager")],Wo.prototype,"filterManager",2),No([(0,r.dsm)("sideBarService")],Wo.prototype,"sideBarService",2),No([(0,r.PIB)("sideBarButtons")],Wo.prototype,"sideBarButtonsComp",2),No([r.o7C],Wo.prototype,"postConstruct",1);var jo=Wo,Ko=class extends r.XQb{constructor(){super(...arguments),this.isColGroupDef=e=>e&&void 0!==e.children,this.getId=e=>this.isColGroupDef(e)?e.groupId:e.colId}createColumnTree(e){const t=[],i=(e,n)=>{if(this.isColGroupDef(e)){const t=e,s=void 0!==t.groupId?t.groupId:t.headerName,o=new r.D45(t,s,!1,n),a=[];return t.children.forEach(e=>{const t=i(e,n+1);t&&a.push(t)}),o.setChildren(a),o}{const i=e,r=i.colId?i.colId:i.field,n=this.columnModel.getPrimaryColumn(r);return n||t.push(i),n}},n=[];return e.forEach(e=>{const t=i(e,0);t&&n.push(t)}),t.length>0&&console.warn("AG Grid: unable to find grid columns for the supplied colDef(s):",t),n}syncLayoutWithGrid(e){const t=this.getLeafPathTrees();e(this.mergeLeafPathTrees(t))}getLeafPathTrees(){const e=(t,i)=>{let n;if(t instanceof r.D45)if(t.isPadding())n=i;else{const e=Object.assign({},t.getColGroupDef());e.groupId=t.getGroupId(),e.children=[i],n=e}else{const e=Object.assign({},t.getColDef());e.colId=t.getColId(),n=e}const s=t.getOriginalParent();return s?e(s,n):n};return this.columnModel.getAllGridColumns().filter(e=>{const t=e.getColDef();return e.isPrimary()&&!t.showRowGroup}).map(t=>e(t,t.getColDef()))}mergeLeafPathTrees(e){const t=(e,t)=>this.isColGroupDef(e)&&this.isColGroupDef(t)&&this.getId(e)===this.getId(t),i=(e,t)=>{if(!this.isColGroupDef(t))return e;const r=e,n=t;return n.children&&n.groupId&&this.addChildrenToGroup(r,n.groupId,n.children[0])||n.children.forEach(e=>i(r,e)),r},r=[];for(let n=1;n<=e.length;n++){const s=e[n-1],o=e[n];t(s,o)?e[n]=i(s,o):r.push(s)}return r}addChildrenToGroup(e,t,i){if(!this.isColGroupDef(e))return!0;const n=e,s=i;if(((e,t)=>{const i=e.children.map(this.getId),n=r._.includes(i,this.getId(t)),s=r._.last(e.children),o=s&&this.getId(s)!==this.getId(t);return n&&o})(n,s))return n.children.push(s),!0;if(n.groupId===t){const e=n.children.map(this.getId);if(!r._.includes(e,this.getId(s)))return n.children.push(s),!0}return n.children.forEach(e=>this.addChildrenToGroup(e,t,i)),!1}};No([(0,r.dsm)("columnModel")],Ko.prototype,"columnModel",2),Ko=No([(0,r.dR4)("toolPanelColDefService")],Ko);var $o=class extends r.XQb{registerSideBarComp(e){this.sideBarComp=e}getSideBarComp(){return this.sideBarComp}};$o=No([(0,r.dR4)("sideBarService")],$o);var qo={version:"31.3.4",moduleName:r.zsj.SideBarModule,beans:[Ko,$o],agStackComponents:[{componentName:"AgHorizontalResize",componentClass:Oo},{componentName:"AgSideBar",componentClass:jo},{componentName:"AgSideBarButtons",componentClass:Vo}],dependantModules:[S]},Yo=Object.defineProperty,Qo=Object.getOwnPropertyDescriptor,Xo=Object.getOwnPropertySymbols,Zo=Object.prototype.hasOwnProperty,Jo=Object.prototype.propertyIsEnumerable,ea=(e,t,i)=>t in e?Yo(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,ta=(e,t)=>{for(var i in t||(t={}))Zo.call(t,i)&&ea(e,i,t[i]);if(Xo)for(var i of Xo(t))Jo.call(t,i)&&ea(e,i,t[i]);return e},ia=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Qo(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Yo(t,i,s),s},ra=class e extends r.uAl{constructor(){super(e.TEMPLATE)}postConstruct(){this.createExpandIcons(),this.addManagedListener(this.eExpand,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eExpand,"keydown",e=>{e.key===r.DDm.SPACE&&(e.preventDefault(),this.onExpandClicked())}),this.addManagedListener(this.eSelect.getInputElement(),"click",this.onSelectClicked.bind(this)),this.addManagedPropertyListener("functionsReadOnly",()=>this.onFunctionsReadOnlyPropChanged()),this.eFilterTextField.setAutoComplete(!1).onValueChange(()=>this.onFilterTextChanged()),this.addManagedListener(this.eFilterTextField.getInputElement(),"keydown",this.onMiniFilterKeyDown.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.showOrHideOptions.bind(this));const e=this.localeService.getLocaleTextFunc();this.eSelect.setInputAriaLabel(e("ariaColumnSelectAll","Toggle Select All Columns")),this.eFilterTextField.setInputAriaLabel(e("ariaFilterColumnsInput","Filter Columns Input")),this.activateTabIndex([this.eExpand])}onFunctionsReadOnlyPropChanged(){const e=this.gos.get("functionsReadOnly");this.eSelect.setReadOnly(e),this.eSelect.addOrRemoveCssClass("ag-column-select-column-readonly",e)}init(e){this.params=e;const t=this.gos.get("functionsReadOnly");this.eSelect.setReadOnly(t),this.eSelect.addOrRemoveCssClass("ag-column-select-column-readonly",t),this.columnModel.isReady()&&this.showOrHideOptions()}createExpandIcons(){this.eExpand.appendChild(this.eExpandChecked=r._.createIconNoSpan("columnSelectOpen",this.gos)),this.eExpand.appendChild(this.eExpandUnchecked=r._.createIconNoSpan("columnSelectClosed",this.gos)),this.eExpand.appendChild(this.eExpandIndeterminate=r._.createIconNoSpan("columnSelectIndeterminate",this.gos)),this.setExpandState(0)}showOrHideOptions(){const e=!this.params.suppressColumnFilter,t=!this.params.suppressColumnSelectAll,i=!this.params.suppressColumnExpandAll,n=this.columnModel.isPrimaryColumnGroupsPresent(),s=this.localeService.getLocaleTextFunc();this.eFilterTextField.setInputPlaceholder(s("searchOoo","Search...")),r._.setDisplayed(this.eFilterTextField.getGui(),e),r._.setDisplayed(this.eSelect.getGui(),t),r._.setDisplayed(this.eExpand,i&&n)}onFilterTextChanged(){this.onFilterTextChangedDebounced||(this.onFilterTextChangedDebounced=r._.debounce(()=>{const e=this.eFilterTextField.getValue();this.dispatchEvent({type:"filterChanged",filterText:e})},e.DEBOUNCE_DELAY)),this.onFilterTextChangedDebounced()}onMiniFilterKeyDown(t){t.key===r.DDm.ENTER&&setTimeout(()=>this.onSelectClicked(),e.DEBOUNCE_DELAY)}onSelectClicked(){this.dispatchEvent({type:this.selectState?"unselectAll":"selectAll"})}onExpandClicked(){this.dispatchEvent({type:0===this.expandState?"collapseAll":"expandAll"})}setExpandState(e){this.expandState=e,r._.setDisplayed(this.eExpandChecked,0===this.expandState),r._.setDisplayed(this.eExpandUnchecked,1===this.expandState),r._.setDisplayed(this.eExpandIndeterminate,2===this.expandState)}setSelectionState(e){this.selectState=e,this.eSelect.setValue(this.selectState)}};ra.DEBOUNCE_DELAY=300,ra.TEMPLATE='<div class="ag-column-select-header" role="presentation">\n            <div ref="eExpand" class="ag-column-select-header-icon"></div>\n            <ag-checkbox ref="eSelect" class="ag-column-select-header-checkbox"></ag-checkbox>\n            <ag-input-text-field class="ag-column-select-header-filter-wrapper" ref="eFilterTextField"></ag-input-text-field>\n        </div>',ia([(0,r.dsm)("columnModel")],ra.prototype,"columnModel",2),ia([(0,r.PIB)("eExpand")],ra.prototype,"eExpand",2),ia([(0,r.PIB)("eSelect")],ra.prototype,"eSelect",2),ia([(0,r.PIB)("eFilterTextField")],ra.prototype,"eFilterTextField",2),ia([r.o7C],ra.prototype,"postConstruct",1);var na=ra,sa=class e{constructor(e,t,i,n=!1,s){this.eventService=new r.USV,this.displayName=e,this.dept=i,this.group=n,n?(this.columnGroup=t,this.expanded=s,this.children=[]):this.column=t}isGroup(){return this.group}getDisplayName(){return this.displayName}getColumnGroup(){return this.columnGroup}getColumn(){return this.column}getDept(){return this.dept}isExpanded(){return!!this.expanded}getChildren(){return this.children}isPassesFilter(){return this.passesFilter}setExpanded(t){t!==this.expanded&&(this.expanded=t,this.eventService.dispatchEvent({type:e.EVENT_EXPANDED_CHANGED}))}setPassesFilter(e){this.passesFilter=e}addEventListener(e,t){this.eventService.addEventListener(e,t)}removeEventListener(e,t){this.eventService.removeEventListener(e,t)}};sa.EVENT_EXPANDED_CHANGED="expandedChanged";var oa=sa,aa=class extends r.uAl{constructor(e,t,i){super('<div class="ag-menu"></div>'),this.column=e,this.mouseEvent=t,this.parentEl=i,this.displayName=null}postConstruct(){if(this.initializeProperties(this.column),this.buildMenuItemMap(),this.column instanceof r.VPZ?this.displayName=this.columnModel.getDisplayNameForColumn(this.column,"columnToolPanel"):this.displayName=this.columnModel.getDisplayNameForProvidedColumnGroup(null,this.column,"columnToolPanel"),this.isActive()){this.mouseEvent.preventDefault();const e=this.getMappedMenuItems();if(0===e.length)return;this.displayContextMenu(e)}}initializeProperties(e){e instanceof r.D45?this.columns=e.getLeafColumns():this.columns=[e],this.allowGrouping=this.columns.some(e=>e.isPrimary()&&e.isAllowRowGroup()),this.allowValues=this.columns.some(e=>e.isPrimary()&&e.isAllowValue()),this.allowPivoting=this.columnModel.isPivotMode()&&this.columns.some(e=>e.isPrimary()&&e.isAllowPivot())}buildMenuItemMap(){const e=this.localeService.getLocaleTextFunc();this.menuItemMap=new Map,this.menuItemMap.set("rowGroup",{allowedFunction:e=>e.isPrimary()&&e.isAllowRowGroup()&&!this.columnModel.isColumnGroupingLocked(e),activeFunction:e=>e.isRowGroupActive(),activateLabel:()=>`${e("groupBy","Group by")} ${this.displayName}`,deactivateLabel:()=>`${e("ungroupBy","Un-Group by")} ${this.displayName}`,activateFunction:()=>{const e=this.columnModel.getRowGroupColumns();this.columnModel.setRowGroupColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getRowGroupColumns();this.columnModel.setRowGroupColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"menuAddRowGroup",removeIcon:"menuRemoveRowGroup"}),this.menuItemMap.set("value",{allowedFunction:e=>e.isPrimary()&&e.isAllowValue(),activeFunction:e=>e.isValueActive(),activateLabel:()=>e("addToValues",`Add ${this.displayName} to values`,[this.displayName]),deactivateLabel:()=>e("removeFromValues",`Remove ${this.displayName} from values`,[this.displayName]),activateFunction:()=>{const e=this.columnModel.getValueColumns();this.columnModel.setValueColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getValueColumns();this.columnModel.setValueColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"valuePanel",removeIcon:"valuePanel"}),this.menuItemMap.set("pivot",{allowedFunction:e=>this.columnModel.isPivotMode()&&e.isPrimary()&&e.isAllowPivot(),activeFunction:e=>e.isPivotActive(),activateLabel:()=>e("addToLabels",`Add ${this.displayName} to labels`,[this.displayName]),deactivateLabel:()=>e("removeFromLabels",`Remove ${this.displayName} from labels`,[this.displayName]),activateFunction:()=>{const e=this.columnModel.getPivotColumns();this.columnModel.setPivotColumns(this.addColumnsToList(e),"toolPanelUi")},deActivateFunction:()=>{const e=this.columnModel.getPivotColumns();this.columnModel.setPivotColumns(this.removeColumnsFromList(e),"toolPanelUi")},addIcon:"pivotPanel",removeIcon:"pivotPanel"})}addColumnsToList(e){return[...e].concat(this.columns.filter(t=>-1===e.indexOf(t)))}removeColumnsFromList(e){return e.filter(e=>-1===this.columns.indexOf(e))}displayContextMenu(e){const t=this.getGui(),i=this.createBean(new r.i9O),n=this.localeService.getLocaleTextFunc();let s=()=>{};t.appendChild(i.getGui()),i.addMenuItems(e),i.addManagedListener(i,r.yuY.EVENT_CLOSE_MENU,()=>{this.parentEl.focus(),s()});const o=this.popupService.addPopup({modal:!0,eChild:t,closeOnEsc:!0,afterGuiAttached:()=>this.focusService.focusInto(i.getGui()),ariaLabel:n("ariaLabelContextMenu","Context Menu"),closedCallback:e=>{e instanceof KeyboardEvent&&this.parentEl.focus(),this.destroyBean(i)}});o&&(s=o.hideFunc),this.popupService.positionPopupUnderMouseEvent({type:"columnContextMenu",mouseEvent:this.mouseEvent,ePopup:t})}isActive(){return this.allowGrouping||this.allowValues||this.allowPivoting}getMappedMenuItems(){const e=[];for(const t of this.menuItemMap.values()){const i=this.columns.some(e=>t.allowedFunction(e)&&!t.activeFunction(e)),n=this.columns.some(e=>t.allowedFunction(e)&&t.activeFunction(e));i&&e.push({name:t.activateLabel(this.displayName),icon:r._.createIconNoSpan(t.addIcon,this.gos,null),action:()=>t.activateFunction()}),n&&e.push({name:t.deactivateLabel(this.displayName),icon:r._.createIconNoSpan(t.removeIcon,this.gos,null),action:()=>t.deActivateFunction()})}return e}};ia([(0,r.dsm)("columnModel")],aa.prototype,"columnModel",2),ia([(0,r.dsm)("popupService")],aa.prototype,"popupService",2),ia([(0,r.dsm)("focusService")],aa.prototype,"focusService",2),ia([r.o7C],aa.prototype,"postConstruct",1);var la=class e extends r.uAl{constructor(e,t,i,r){super(),this.modelItem=e,this.allowDragging=t,this.eventType=i,this.focusWrapper=r,this.processingColumnStateChange=!1,this.modelItem=e,this.columnGroup=e.getColumnGroup(),this.columnDept=e.getDept(),this.displayName=e.getDisplayName(),this.allowDragging=t}init(){this.setTemplate(e.TEMPLATE),this.eDragHandle=r._.createIconNoSpan("columnDrag",this.gos),this.eDragHandle.classList.add("ag-drag-handle","ag-column-select-column-group-drag-handle");const t=this.cbSelect.getGui(),i=this.cbSelect.getInputElement();t.insertAdjacentElement("afterend",this.eDragHandle),i.setAttribute("tabindex","-1"),this.eLabel.innerHTML=this.displayName?this.displayName:"",this.setupExpandContract(),this.addCssClass("ag-column-select-indent-"+this.columnDept),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.eLabel,"click",this.onLabelClicked.bind(this)),this.addManagedListener(this.cbSelect,r.sVA.EVENT_FIELD_VALUE_CHANGED,this.onCheckboxChanged.bind(this)),this.addManagedListener(this.modelItem,oa.EVENT_EXPANDED_CHANGED,this.onExpandChanged.bind(this)),this.addManagedListener(this.focusWrapper,"keydown",this.handleKeyDown.bind(this)),this.addManagedListener(this.focusWrapper,"contextmenu",this.onContextMenu.bind(this)),this.setOpenClosedIcons(),this.setupDragging(),this.onColumnStateChanged(),this.addVisibilityListenersToAllChildren(),this.refreshAriaExpanded(),this.refreshAriaLabel(),this.setupTooltip(),r.PC7.getToolPanelClassesFromColDef(this.columnGroup.getColGroupDef(),this.gos,null,this.columnGroup).forEach(e=>this.addOrRemoveCssClass(e,!0))}getColumns(){return this.columnGroup.getLeafColumns()}setupTooltip(){const e=this.columnGroup.getColGroupDef();if(!e)return;let t;"whenTruncated"===this.gos.get("tooltipShowMode")&&(t=()=>this.eLabel.scrollWidth>this.eLabel.clientWidth);const i=()=>{const i=e.headerTooltip;this.setTooltip({newTooltipText:i,location:"columnToolPanelColumnGroup",shouldDisplayTooltip:t})};i(),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,i)}getTooltipParams(){const e=super.getTooltipParams();return e.location="columnToolPanelColumnGroup",e}handleKeyDown(e){switch(e.key){case r.DDm.LEFT:e.preventDefault(),this.modelItem.setExpanded(!1);break;case r.DDm.RIGHT:e.preventDefault(),this.modelItem.setExpanded(!0);break;case r.DDm.SPACE:e.preventDefault(),this.isSelectable()&&this.onSelectAllChanged(!this.isSelected())}}onContextMenu(e){const{columnGroup:t,gos:i}=this;if(i.get("functionsReadOnly"))return;const r=this.createBean(new aa(t,e,this.focusWrapper));this.addDestroyFunc(()=>{r.isAlive()&&this.destroyBean(r)})}addVisibilityListenersToAllChildren(){this.columnGroup.getLeafColumns().forEach(e=>{this.addManagedListener(e,r.VPZ.EVENT_VISIBLE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,r.VPZ.EVENT_VALUE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,r.VPZ.EVENT_PIVOT_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(e,r.VPZ.EVENT_ROW_GROUP_CHANGED,this.onColumnStateChanged.bind(this))})}setupDragging(){if(!this.allowDragging)return void r._.setDisplayed(this.eDragHandle,!1);let e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:r.qRA.ToolPanel,eElement:this.eDragHandle,dragItemName:this.displayName,getDefaultIconName:()=>e?r.WO_.ICON_HIDE:r.WO_.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(),onDragStarted:()=>{e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_START,column:this.columnGroup};this.eventService.dispatchEvent(t)},onDragStopped:()=>{const e={type:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_END};this.eventService.dispatchEvent(e)},onGridEnter:t=>{e&&this.modelItemUtils.updateColumns({columns:this.columnGroup.getLeafColumns(),visibleState:null==t?void 0:t.visibleState,pivotState:null==t?void 0:t.pivotState,eventType:this.eventType})},onGridExit:()=>{e&&this.onChangeCommon(!1)}};this.dragAndDropService.addDragSource(t,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(t))}createDragItem(){const e=this.columnGroup.getLeafColumns(),t={},i={};return e.forEach(e=>{const r=e.getId();t[r]=e.isVisible(),i[r]=this.modelItemUtils.createPivotState(e)}),{columns:e,visibleState:t,pivotState:i}}setupExpandContract(){this.eGroupClosedIcon.appendChild(r._.createIcon("columnSelectClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild(r._.createIcon("columnSelectOpen",this.gos,null)),this.addManagedListener(this.eGroupClosedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.addManagedListener(this.eGroupOpenedIcon,"click",this.onExpandOrContractClicked.bind(this));const e=new r.MVO(this.eColumnGroupIcons,!0);this.addManagedListener(e,r.MVO.EVENT_TAP,this.onExpandOrContractClicked.bind(this)),this.addDestroyFunc(e.destroy.bind(e))}onLabelClicked(){const e=!this.cbSelect.getValue();this.onChangeCommon(e)}onCheckboxChanged(e){this.onChangeCommon(e.selected)}getVisibleLeafColumns(){const e=[],t=i=>{i.forEach(i=>{i.isPassesFilter()&&(i.isGroup()?t(i.getChildren()):e.push(i.getColumn()))})};return t(this.modelItem.getChildren()),e}onChangeCommon(e){this.refreshAriaLabel(),this.processingColumnStateChange||this.modelItemUtils.selectAllChildren(this.modelItem.getChildren(),e,this.eventType)}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumnGroup","Column Group"),i=this.cbSelect.getValue(),n=void 0===i?e("ariaIndeterminate","indeterminate"):i?e("ariaVisible","visible"):e("ariaHidden","hidden"),s=e("ariaToggleVisibility","Press SPACE to toggle visibility");r._.setAriaLabel(this.focusWrapper,`${this.displayName} ${t}`),this.cbSelect.setInputAriaLabel(`${s} (${n})`),r._.setAriaDescribedBy(this.focusWrapper,this.cbSelect.getInputElement().id)}onColumnStateChanged(){const e=this.workOutSelectedValue(),t=this.workOutReadOnlyValue();this.processingColumnStateChange=!0,this.cbSelect.setValue(e),this.cbSelect.setReadOnly(t),this.addOrRemoveCssClass("ag-column-select-column-group-readonly",t),this.processingColumnStateChange=!1}workOutSelectedValue(){const e=this.columnModel.isPivotMode(),t=this.getVisibleLeafColumns();let i=0,r=0;if(t.forEach(t=>{!e&&t.getColDef().lockVisible||(this.isColumnChecked(t,e)?i++:r++)}),!(i>0&&r>0))return i>0}workOutReadOnlyValue(){const e=this.columnModel.isPivotMode();let t=0;return this.columnGroup.getLeafColumns().forEach(i=>{e?i.isAnyFunctionAllowed()&&t++:i.getColDef().lockVisible||t++}),0===t}isColumnChecked(e,t){if(t){const t=e.isPivotActive(),i=e.isRowGroupActive(),r=e.isValueActive();return t||i||r}return e.isVisible()}onExpandOrContractClicked(){const e=this.modelItem.isExpanded();this.modelItem.setExpanded(!e)}onExpandChanged(){this.setOpenClosedIcons(),this.refreshAriaExpanded()}setOpenClosedIcons(){const e=this.modelItem.isExpanded();r._.setDisplayed(this.eGroupClosedIcon,!e),r._.setDisplayed(this.eGroupOpenedIcon,e)}refreshAriaExpanded(){r._.setAriaExpanded(this.focusWrapper,this.modelItem.isExpanded())}getDisplayName(){return this.displayName}onSelectAllChanged(e){const t=this.cbSelect.getValue();!this.cbSelect.isReadOnly()&&(e&&!t||!e&&t)&&this.cbSelect.toggle()}isSelected(){return this.cbSelect.getValue()}isSelectable(){return!this.cbSelect.isReadOnly()}setSelected(e){this.cbSelect.setValue(e,!0)}};la.TEMPLATE='<div class="ag-column-select-column-group" aria-hidden="true">\n            <span class="ag-column-group-icons" ref="eColumnGroupIcons" >\n                <span class="ag-column-group-closed-icon" ref="eGroupClosedIcon"></span>\n                <span class="ag-column-group-opened-icon" ref="eGroupOpenedIcon"></span>\n            </span>\n            <ag-checkbox ref="cbSelect" class="ag-column-select-checkbox"></ag-checkbox>\n            <span class="ag-column-select-column-label" ref="eLabel"></span>\n        </div>',ia([(0,r.dsm)("columnModel")],la.prototype,"columnModel",2),ia([(0,r.dsm)("dragAndDropService")],la.prototype,"dragAndDropService",2),ia([(0,r.dsm)("modelItemUtils")],la.prototype,"modelItemUtils",2),ia([(0,r.PIB)("cbSelect")],la.prototype,"cbSelect",2),ia([(0,r.PIB)("eLabel")],la.prototype,"eLabel",2),ia([(0,r.PIB)("eGroupOpenedIcon")],la.prototype,"eGroupOpenedIcon",2),ia([(0,r.PIB)("eGroupClosedIcon")],la.prototype,"eGroupClosedIcon",2),ia([(0,r.PIB)("eColumnGroupIcons")],la.prototype,"eColumnGroupIcons",2),ia([r.o7C],la.prototype,"init",1);var ca=la,ua=class extends r.XQb{constructor(e,t){super(),this.comp=e,this.virtualList=t}postConstruct(){this.createManagedBean(new r.ia$(this.comp,this.virtualList,{dragSourceType:r.qRA.ToolPanel,listItemDragStartEvent:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_START,listItemDragEndEvent:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_END,eventSource:this.eventService,getCurrentDragValue:e=>this.getCurrentDragValue(e),isMoveBlocked:e=>this.isMoveBlocked(e),getNumRows:e=>e.getDisplayedColsList().length,moveItem:(e,t)=>this.moveItem(e,t)}))}getCurrentDragValue(e){return e.column}isMoveBlocked(e){return!!this.gos.get("suppressMovableColumns")||!!this.getCurrentColumns(e).find(e=>{const t=e.getColDef();return!!t.suppressMovable||!!t.lockPosition})}moveItem(e,t){const i=this.getTargetIndex(e,t),r=this.getCurrentColumns(e);null!=i&&this.columnModel.moveColumns(r,i,"toolPanelUi")}getMoveDiff(e,t){const i=this.columnModel.getAllGridColumns(),r=this.getCurrentColumns(e),n=r[0],s=r.length;return i.indexOf(n)<t?s:0}getCurrentColumns(e){return e instanceof r.D45?e.getLeafColumns():[e]}getTargetIndex(e,t){if(!t)return null;const i=t.component;let r,n="top"===t.position;if(i instanceof ca?(r=i.getColumns()[0],n=!0):r=i.getColumn(),-1!==this.getCurrentColumns(e).indexOf(r))return null;const s=this.columnModel.getAllGridColumns().indexOf(r),o=n?s:s+1;return o-this.getMoveDiff(e,o)}};ia([(0,r.dsm)("columnModel")],ua.prototype,"columnModel",2),ia([r.o7C],ua.prototype,"postConstruct",1);var ha=class e extends r.uAl{constructor(e,t,i,r){super(),this.allowDragging=t,this.groupsExist=i,this.focusWrapper=r,this.processingColumnStateChange=!1,this.column=e.getColumn(),this.columnDept=e.getDept(),this.displayName=e.getDisplayName()}init(){this.setTemplate(e.TEMPLATE),this.eDragHandle=r._.createIconNoSpan("columnDrag",this.gos),this.eDragHandle.classList.add("ag-drag-handle","ag-column-select-column-drag-handle");const t=this.cbSelect.getGui(),i=this.cbSelect.getInputElement();t.insertAdjacentElement("afterend",this.eDragHandle),i.setAttribute("tabindex","-1");const n=r._.escapeString(this.displayName);this.eLabel.innerHTML=n;const s=this.columnDept;this.groupsExist&&this.addCssClass("ag-column-select-add-group-indent"),this.addCssClass(`ag-column-select-indent-${s}`),this.setupDragging(),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,r.VPZ.EVENT_VALUE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,r.VPZ.EVENT_PIVOT_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,r.VPZ.EVENT_ROW_GROUP_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.column,r.VPZ.EVENT_VISIBLE_CHANGED,this.onColumnStateChanged.bind(this)),this.addManagedListener(this.focusWrapper,"keydown",this.handleKeyDown.bind(this)),this.addManagedListener(this.focusWrapper,"contextmenu",this.onContextMenu.bind(this)),this.addManagedPropertyListener("functionsReadOnly",this.onColumnStateChanged.bind(this)),this.addManagedListener(this.cbSelect,r.sVA.EVENT_FIELD_VALUE_CHANGED,this.onCheckboxChanged.bind(this)),this.addManagedListener(this.eLabel,"click",this.onLabelClicked.bind(this)),this.onColumnStateChanged(),this.refreshAriaLabel(),this.setupTooltip(),r.PC7.getToolPanelClassesFromColDef(this.column.getColDef(),this.gos,this.column,null).forEach(e=>this.addOrRemoveCssClass(e,!0))}getColumn(){return this.column}setupTooltip(){let e;"whenTruncated"===this.gos.get("tooltipShowMode")&&(e=()=>this.eLabel.scrollWidth>this.eLabel.clientWidth);const t=()=>{const t=this.column.getColDef().headerTooltip;this.setTooltip({newTooltipText:t,location:"columnToolPanelColumn",shouldDisplayTooltip:e})};t(),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,t)}getTooltipParams(){const e=super.getTooltipParams();return e.location="columnToolPanelColumn",e.colDef=this.column.getColDef(),e}onContextMenu(e){const{column:t,gos:i}=this;if(i.get("functionsReadOnly"))return;const r=this.createBean(new aa(t,e,this.focusWrapper));this.addDestroyFunc(()=>{r.isAlive()&&this.destroyBean(r)})}handleKeyDown(e){e.key===r.DDm.SPACE&&(e.preventDefault(),this.isSelectable()&&this.onSelectAllChanged(!this.isSelected()))}onLabelClicked(){if(this.gos.get("functionsReadOnly"))return;const e=!this.cbSelect.getValue();this.onChangeCommon(e)}onCheckboxChanged(e){this.onChangeCommon(e.selected)}onChangeCommon(e){this.cbSelect.isReadOnly()||(this.refreshAriaLabel(),this.processingColumnStateChange||this.modelItemUtils.setColumn(this.column,e,"toolPanelUi"))}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumn","Column"),i=this.cbSelect.getValue()?e("ariaVisible","visible"):e("ariaHidden","hidden"),n=e("ariaToggleVisibility","Press SPACE to toggle visibility");r._.setAriaLabel(this.focusWrapper,`${this.displayName} ${t}`),this.cbSelect.setInputAriaLabel(`${n} (${i})`),r._.setAriaDescribedBy(this.focusWrapper,this.cbSelect.getInputElement().id)}setupDragging(){if(!this.allowDragging)return void r._.setDisplayed(this.eDragHandle,!1);let e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:r.qRA.ToolPanel,eElement:this.eDragHandle,dragItemName:this.displayName,getDefaultIconName:()=>e?r.WO_.ICON_HIDE:r.WO_.ICON_NOT_ALLOWED,getDragItem:()=>this.createDragItem(),onDragStarted:()=>{e=!this.gos.get("suppressDragLeaveHidesColumns");const t={type:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_START,column:this.column};this.eventService.dispatchEvent(t)},onDragStopped:()=>{const e={type:r.sVA.EVENT_COLUMN_PANEL_ITEM_DRAG_END};this.eventService.dispatchEvent(e)},onGridEnter:t=>{e&&this.modelItemUtils.updateColumns({columns:[this.column],visibleState:null==t?void 0:t.visibleState,pivotState:null==t?void 0:t.pivotState,eventType:"toolPanelUi"})},onGridExit:()=>{e&&this.onChangeCommon(!1)}};this.dragAndDropService.addDragSource(t,!0),this.addDestroyFunc(()=>this.dragAndDropService.removeDragSource(t))}createDragItem(){const e=this.column.getColId(),t={[e]:this.column.isVisible()},i={[e]:this.modelItemUtils.createPivotState(this.column)};return{columns:[this.column],visibleState:t,pivotState:i}}onColumnStateChanged(){this.processingColumnStateChange=!0;const e=this.columnModel.isPivotMode();if(e){const e=this.column.isAnyFunctionActive();this.cbSelect.setValue(e)}else this.cbSelect.setValue(this.column.isVisible());let t=!0,i=!0;if(e){const e=this.gos.get("functionsReadOnly"),r=!this.column.isAnyFunctionAllowed();t=!e&&!r,i=t}else{const{enableRowGroup:e,enableValue:r,lockPosition:n,suppressMovable:s,lockVisible:o}=this.column.getColDef();t=!o,i=!!e||!!r||!(n||s)}this.cbSelect.setReadOnly(!t),this.eDragHandle.classList.toggle("ag-column-select-column-readonly",!i),this.addOrRemoveCssClass("ag-column-select-column-readonly",!i&&!t);const r=e&&this.gos.get("functionsPassive");this.cbSelect.setPassive(r),this.processingColumnStateChange=!1}getDisplayName(){return this.displayName}onSelectAllChanged(e){e!==this.cbSelect.getValue()&&(this.cbSelect.isReadOnly()||this.cbSelect.toggle())}isSelected(){return this.cbSelect.getValue()}isSelectable(){return!this.cbSelect.isReadOnly()}isExpandable(){return!1}setExpanded(e){console.warn("AG Grid: can not expand a column item that does not represent a column group header")}};ha.TEMPLATE='<div class="ag-column-select-column" aria-hidden="true">\n            <ag-checkbox ref="cbSelect" class="ag-column-select-checkbox"></ag-checkbox>\n            <span class="ag-column-select-column-label" ref="eLabel"></span>\n        </div>',ia([(0,r.dsm)("columnModel")],ha.prototype,"columnModel",2),ia([(0,r.dsm)("dragAndDropService")],ha.prototype,"dragAndDropService",2),ia([(0,r.dsm)("modelItemUtils")],ha.prototype,"modelItemUtils",2),ia([(0,r.PIB)("eLabel")],ha.prototype,"eLabel",2),ia([(0,r.PIB)("cbSelect")],ha.prototype,"cbSelect",2),ia([r.o7C],ha.prototype,"init",1);var da=ha,pa=class{constructor(e){this.items=e}getRowCount(){return this.items.length}getRow(e){return this.items[e]}},ga=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.destroyColumnItemFuncs=[],this.hasLoadedInitialState=!1,this.isInitialState=!1}destroyColumnTree(){this.allColsTree=[],this.destroyColumnItemFuncs.forEach(e=>e()),this.destroyColumnItemFuncs=[]}init(e,t,i){this.params=e,this.allowDragging=t,this.eventType=i,this.params.suppressSyncLayoutWithGrid||this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_MOVED,this.onColumnsChanged.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.onColumnsChanged.bind(this)),[r.sVA.EVENT_COLUMN_PIVOT_CHANGED,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,r.sVA.EVENT_COLUMN_VALUE_CHANGED,r.sVA.EVENT_COLUMN_VISIBLE,r.sVA.EVENT_NEW_COLUMNS_LOADED].forEach(e=>{this.addManagedListener(this.eventService,e,this.fireSelectionChangedEvent.bind(this))}),this.expandGroupsByDefault=!this.params.contractColumnSelection,this.virtualList=this.createManagedBean(new r.wjn({cssIdentifier:"column-select",ariaRole:"tree"})),this.appendChild(this.virtualList.getGui()),this.virtualList.setComponentCreator((e,t)=>(r._.setAriaLevel(t,e.getDept()+1),this.createComponentFromItem(e,t))),this.columnModel.isReady()&&this.onColumnsChanged(),this.params.suppressColumnMove||this.createManagedBean(new ua(this,this.virtualList))}createComponentFromItem(e,t){if(e.isGroup()){const i=new ca(e,this.allowDragging,this.eventType,t);return this.getContext().createBean(i),i}const i=new da(e,this.allowDragging,this.groupsExist,t);return this.getContext().createBean(i),i}onColumnsChanged(){this.hasLoadedInitialState||(this.hasLoadedInitialState=!0,this.isInitialState=!!this.params.initialState);const e=this.getExpandedStates(),t=this.columnModel.isPivotMode();this.params.suppressSyncLayoutWithGrid||t?this.buildTreeFromProvidedColumnDefs():this.buildTreeFromWhatGridIsDisplaying(),this.setExpandedStates(e),this.markFilteredColumns(),this.flattenAndFilterModel(),this.isInitialState=!1}getDisplayedColsList(){return this.displayedColsList}getExpandedStates(){const e={};if(this.isInitialState){const{expandedGroupIds:t}=this.params.initialState;return t.forEach(t=>{e[t]=!0}),e}return this.allColsTree?(this.forEachItem(t=>{if(!t.isGroup())return;const i=t.getColumnGroup();i&&(e[i.getId()]=t.isExpanded())}),e):{}}setExpandedStates(e){if(!this.allColsTree)return;const{isInitialState:t}=this;this.forEachItem(i=>{if(!i.isGroup())return;const r=i.getColumnGroup();if(r){const n=e[r.getId()];(null!=n||t)&&i.setExpanded(!!n)}})}buildTreeFromWhatGridIsDisplaying(){this.colDefService.syncLayoutWithGrid(this.setColumnLayout.bind(this))}setColumnLayout(e){const t=this.colDefService.createColumnTree(e);this.buildListModel(t),this.groupsExist=e.some(e=>e&&void 0!==e.children),this.markFilteredColumns(),this.flattenAndFilterModel()}buildTreeFromProvidedColumnDefs(){this.buildListModel(this.columnModel.getPrimaryColumnTree()),this.groupsExist=this.columnModel.isPrimaryColumnGroupsPresent()}buildListModel(e){const t=this.onColumnExpanded.bind(this),i=e=>{e.addEventListener(oa.EVENT_EXPANDED_CHANGED,t);const i=e.removeEventListener.bind(e,oa.EVENT_EXPANDED_CHANGED,t);this.destroyColumnItemFuncs.push(i)},n=(e,t,i)=>{e.forEach(e=>{e instanceof r.D45?s(e,t,i):o(e,t,i)})},s=(e,t,r)=>{const s=e.getColGroupDef();if(s&&s.suppressColumnsToolPanel)return;if(e.isPadding())return void n(e.getChildren(),t,r);const o=this.columnModel.getDisplayNameForProvidedColumnGroup(null,e,"columnToolPanel"),a=new oa(o,e,t,!0,this.expandGroupsByDefault);r.push(a),i(a),n(e.getChildren(),t+1,a.getChildren())},o=(e,t,i)=>{if(e.getColDef()&&e.getColDef().suppressColumnsToolPanel)return;const r=this.columnModel.getDisplayNameForColumn(e,"columnToolPanel");i.push(new oa(r,e,t))};this.destroyColumnTree(),n(e,0,this.allColsTree)}onColumnExpanded(){this.flattenAndFilterModel()}flattenAndFilterModel(){this.displayedColsList=[];const e=t=>{t.isPassesFilter()&&(this.displayedColsList.push(t),t.isGroup()&&t.isExpanded()&&t.getChildren().forEach(e))};this.allColsTree.forEach(e),this.virtualList.setModel(new pa(this.displayedColsList));const t=this.virtualList.getLastFocusedRow();this.virtualList.refresh(),null!=t&&this.focusRowIfAlive(t),this.notifyListeners(),this.refreshAriaLabel()}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaColumnPanelList","Column List"),i=e("columns","Columns"),n=this.displayedColsList.length;r._.setAriaLabel(this.virtualList.getAriaElement(),`${t} ${n} ${i}`)}focusRowIfAlive(e){window.setTimeout(()=>{this.isAlive()&&this.virtualList.focusRow(e)},0)}forEachItem(e){const t=i=>{i.forEach(i=>{e(i),i.isGroup()&&t(i.getChildren())})};this.allColsTree&&t(this.allColsTree)}doSetExpandedAll(e){this.forEachItem(t=>{t.isGroup()&&t.setExpanded(e)})}setGroupsExpanded(e,t){if(!t)return void this.doSetExpandedAll(e);const i=[];this.forEachItem(r=>{if(!r.isGroup())return;const n=r.getColumnGroup().getId();t.indexOf(n)>=0&&(r.setExpanded(e),i.push(n))});const n=t.filter(e=>!r._.includes(i,e));n.length>0&&console.warn("AG Grid: unable to find group(s) for supplied groupIds:",n)}getExpandState(){let e=0,t=0;return this.forEachItem(i=>{i.isGroup()&&(i.isExpanded()?e++:t++)}),e>0&&t>0?2:t>0?1:0}doSetSelectedAll(e){this.modelItemUtils.selectAllChildren(this.allColsTree,e,this.eventType)}getSelectionState(){let e=0,t=0;const i=this.columnModel.isPivotMode();if(this.forEachItem(r=>{if(r.isGroup())return;if(!r.isPassesFilter())return;const n=r.getColumn(),s=n.getColDef();let o;if(i){if(!n.isAllowPivot()&&!n.isAllowRowGroup()&&!n.isAllowValue())return;o=n.isValueActive()||n.isPivotActive()||n.isRowGroupActive()}else{if(s.lockVisible)return;o=n.isVisible()}o?e++:t++}),!(e>0&&t>0))return!(0===e||t>0)}setFilterText(e){this.filterText=r._.exists(e)?e.toLowerCase():null,this.markFilteredColumns(),this.flattenAndFilterModel()}markFilteredColumns(){const e=e=>{if(!r._.exists(this.filterText))return!0;const t=e.getDisplayName();return null==t||-1!==t.toLowerCase().indexOf(this.filterText)},t=(i,r)=>{let n=!1;if(i.isGroup()){const s=e(i);i.getChildren().forEach(e=>{const i=t(e,s||r);i&&(n=i)})}const s=!(!r&&!n)||e(i);return i.setPassesFilter(s),s};this.allColsTree.forEach(e=>t(e,!1))}notifyListeners(){this.fireGroupExpandedEvent(),this.fireSelectionChangedEvent()}fireGroupExpandedEvent(){const e=this.getExpandState();this.dispatchEvent({type:"groupExpanded",state:e})}fireSelectionChangedEvent(){if(!this.allColsTree)return;const e=this.getSelectionState();this.dispatchEvent({type:"selectionChanged",state:e})}getExpandedGroups(){const e=[];return this.allColsTree?(this.forEachItem(t=>{t.isGroup()&&t.isExpanded()&&e.push(t.getColumnGroup().getId())}),e):e}};ga.TEMPLATE='<div class="ag-column-select-list" role="presentation"></div>',ia([(0,r.dsm)("columnModel")],ga.prototype,"columnModel",2),ia([(0,r.dsm)("toolPanelColDefService")],ga.prototype,"colDefService",2),ia([(0,r.dsm)("modelItemUtils")],ga.prototype,"modelItemUtils",2),ia([r.yah],ga.prototype,"destroyColumnTree",1);var fa=ga,ma=class extends r.uAl{createTemplate(){return'<div class="ag-pivot-mode-panel">\n                <ag-toggle-button ref="cbPivotMode" class="ag-pivot-mode-select"></ag-toggle-button>\n            </div>'}init(){this.setTemplate(this.createTemplate()),this.cbPivotMode.setValue(this.columnModel.isPivotMode());const e=this.localeService.getLocaleTextFunc();this.cbPivotMode.setLabel(e("pivotMode","Pivot Mode")),this.addManagedListener(this.cbPivotMode,r.sVA.EVENT_FIELD_VALUE_CHANGED,this.onBtPivotMode.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.onPivotModeChanged.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,this.onPivotModeChanged.bind(this))}onBtPivotMode(){const e=!!this.cbPivotMode.getValue();if(e!==this.columnModel.isPivotMode()){this.gos.updateGridOptions({options:{pivotMode:e},source:"toolPanelUi"});const{api:t}=this;t&&t.refreshHeader()}}onPivotModeChanged(){const e=this.columnModel.isPivotMode();this.cbPivotMode.setValue(e)}};ia([(0,r.dsm)("columnModel")],ma.prototype,"columnModel",2),ia([(0,r.dsm)("gridApi")],ma.prototype,"api",2),ia([(0,r.PIB)("cbPivotMode")],ma.prototype,"cbPivotMode",2),ia([r.fK3],ma.prototype,"init",1);var va=class e extends r.uAl{constructor(){super(e.TEMPLATE)}init(e,t,i){this.allowDragging=e,this.params=t,this.eventType=i,this.primaryColsHeaderPanel.init(this.params);const n=this.params.suppressColumnFilter,s=this.params.suppressColumnSelectAll;this.params.suppressColumnExpandAll&&n&&s&&this.primaryColsHeaderPanel.setDisplayed(!1),this.addManagedListener(this.primaryColsListPanel,"groupExpanded",this.onGroupExpanded.bind(this)),this.addManagedListener(this.primaryColsListPanel,"selectionChanged",this.onSelectionChange.bind(this)),this.primaryColsListPanel.init(this.params,this.allowDragging,this.eventType),this.addManagedListener(this.primaryColsHeaderPanel,"expandAll",this.onExpandAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"collapseAll",this.onCollapseAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"selectAll",this.onSelectAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"unselectAll",this.onUnselectAll.bind(this)),this.addManagedListener(this.primaryColsHeaderPanel,"filterChanged",this.onFilterChanged.bind(this)),this.positionableFeature=new r.qyQ(this.getGui(),{minHeight:100}),this.createManagedBean(this.positionableFeature)}toggleResizable(e){this.positionableFeature.setResizable(!!e&&{bottom:!0})}onExpandAll(){this.primaryColsListPanel.doSetExpandedAll(!0)}onCollapseAll(){this.primaryColsListPanel.doSetExpandedAll(!1)}expandGroups(e){this.primaryColsListPanel.setGroupsExpanded(!0,e)}collapseGroups(e){this.primaryColsListPanel.setGroupsExpanded(!1,e)}setColumnLayout(e){this.primaryColsListPanel.setColumnLayout(e)}onFilterChanged(e){this.primaryColsListPanel.setFilterText(e.filterText)}syncLayoutWithGrid(){this.primaryColsListPanel.onColumnsChanged()}onSelectAll(){this.primaryColsListPanel.doSetSelectedAll(!0)}onUnselectAll(){this.primaryColsListPanel.doSetSelectedAll(!1)}onGroupExpanded(e){this.primaryColsHeaderPanel.setExpandState(e.state),this.params.onStateUpdated()}onSelectionChange(e){this.primaryColsHeaderPanel.setSelectionState(e.state)}getExpandedGroups(){return this.primaryColsListPanel.getExpandedGroups()}};va.TEMPLATE='<div class="ag-column-select">\n            <ag-primary-cols-header ref="primaryColsHeaderPanel"></ag-primary-cols-header>\n            <ag-primary-cols-list ref="primaryColsListPanel"></ag-primary-cols-list>\n        </div>',ia([(0,r.PIB)("primaryColsHeaderPanel")],va.prototype,"primaryColsHeaderPanel",2),ia([(0,r.PIB)("primaryColsListPanel")],va.prototype,"primaryColsListPanel",2);var Ca=va,ya=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.initialised=!1,this.childDestroyFuncs=[]}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}init(e){const t=this.gos.addGridCommonParams({suppressColumnMove:!1,suppressColumnSelectAll:!1,suppressColumnFilter:!1,suppressColumnExpandAll:!1,contractColumnSelection:!1,suppressPivotMode:!1,suppressRowGroups:!1,suppressValues:!1,suppressPivots:!1,suppressSyncLayoutWithGrid:!1});if(this.params=ta(ta({},t),e),this.isRowGroupingModuleLoaded()&&!this.params.suppressPivotMode&&(this.pivotModePanel=this.createBean(new ma),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotModePanel)),this.appendChild(this.pivotModePanel)),this.primaryColsPanel=this.createBean(new Ca),this.childDestroyFuncs.push(()=>this.destroyBean(this.primaryColsPanel)),this.primaryColsPanel.init(!0,this.params,"toolPanelUi"),this.primaryColsPanel.addCssClass("ag-column-panel-column-select"),this.appendChild(this.primaryColsPanel),this.isRowGroupingModuleLoaded()){this.params.suppressRowGroups||(this.rowGroupDropZonePanel=this.createBean(new vo(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.rowGroupDropZonePanel)),this.appendChild(this.rowGroupDropZonePanel)),this.params.suppressValues||(this.valuesDropZonePanel=this.createBean(new To(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.valuesDropZonePanel)),this.appendChild(this.valuesDropZonePanel)),this.params.suppressPivots||(this.pivotDropZonePanel=this.createBean(new Co(!1)),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotDropZonePanel)),this.appendChild(this.pivotDropZonePanel)),this.setLastVisible();const e=this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,()=>{this.resetChildrenHeight(),this.setLastVisible()});this.childDestroyFuncs.push(()=>e())}this.initialised=!0}setPivotModeSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.pivotModePanel?this.pivotModePanel.setDisplayed(e):e&&(this.pivotModePanel=this.createBean(new ma),this.getGui().insertBefore(this.pivotModePanel.getGui(),this.getGui().firstChild),this.childDestroyFuncs.push(()=>this.destroyBean(this.pivotModePanel))),this.setLastVisible())}setRowGroupsSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.rowGroupDropZonePanel?this.rowGroupDropZonePanel.setDisplayed(e):e&&(this.rowGroupDropZonePanel=this.createManagedBean(new vo(!1)),this.appendChild(this.rowGroupDropZonePanel)),this.setLastVisible())}setValuesSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.valuesDropZonePanel?this.valuesDropZonePanel.setDisplayed(e):e&&(this.valuesDropZonePanel=this.createManagedBean(new To(!1)),this.appendChild(this.valuesDropZonePanel)),this.setLastVisible())}setPivotSectionVisible(e){this.isRowGroupingModuleLoaded()&&(this.pivotDropZonePanel?this.pivotDropZonePanel.setDisplayed(e):e&&(this.pivotDropZonePanel=this.createManagedBean(new Co(!1)),this.appendChild(this.pivotDropZonePanel),this.pivotDropZonePanel.setDisplayed(e)),this.setLastVisible())}setResizers(){[this.primaryColsPanel,this.rowGroupDropZonePanel,this.valuesDropZonePanel,this.pivotDropZonePanel].forEach(e=>{if(!e)return;const t=e.getGui();e.toggleResizable(!t.classList.contains("ag-last-column-drop")&&!t.classList.contains("ag-hidden"))})}setLastVisible(){const e=this.getGui();Array.prototype.slice.call(e.querySelectorAll(".ag-column-drop")).forEach(e=>e.classList.remove("ag-last-column-drop"));const t=e.querySelectorAll(".ag-column-drop:not(.ag-hidden)"),i=r._.last(t);i&&i.classList.add("ag-last-column-drop"),this.setResizers()}resetChildrenHeight(){const e=this.getGui().children;for(let t=0;t<e.length;t++){const i=e[t];i.style.removeProperty("height"),i.style.removeProperty("flex")}}isRowGroupingModuleLoaded(){return r.syG.__assertRegistered(r.zsj.RowGroupingModule,"Row Grouping",this.context.getGridId())}expandColumnGroups(e){this.primaryColsPanel.expandGroups(e)}collapseColumnGroups(e){this.primaryColsPanel.collapseGroups(e)}setColumnLayout(e){this.primaryColsPanel.setColumnLayout(e)}syncLayoutWithGrid(){this.primaryColsPanel.syncLayoutWithGrid()}destroyChildren(){this.childDestroyFuncs.forEach(e=>e()),this.childDestroyFuncs.length=0,r._.clearElement(this.getGui())}refresh(e){return this.destroyChildren(),this.init(e),!0}getState(){return{expandedGroupIds:this.primaryColsPanel.getExpandedGroups()}}destroy(){this.destroyChildren(),super.destroy()}};ya.TEMPLATE='<div class="ag-column-panel"></div>';var wa=ya,Sa=class{selectAllChildren(e,t,i){const r=this.extractAllLeafColumns(e);this.setAllColumns(r,t,i)}setColumn(e,t,i){this.setAllColumns([e],t,i)}setAllColumns(e,t,i){this.columnModel.isPivotMode()?this.setAllPivot(e,t,i):this.setAllVisible(e,t,i)}extractAllLeafColumns(e){const t=[],i=e=>{e.forEach(e=>{e.isPassesFilter()&&(e.isGroup()?i(e.getChildren()):t.push(e.getColumn()))})};return i(e),t}setAllVisible(e,t,i){const r=[];e.forEach(e=>{e.getColDef().lockVisible||e.isVisible()!=t&&r.push({colId:e.getId(),hide:!t})}),r.length>0&&this.columnModel.applyColumnState({state:r},i)}setAllPivot(e,t,i){this.gos.get("functionsPassive")?this.setAllPivotPassive(e,t):this.setAllPivotActive(e,t,i)}setAllPivotPassive(e,t){const i=this.columnModel.getPivotColumns().slice(),n=this.columnModel.getValueColumns().slice(),s=this.columnModel.getRowGroupColumns().slice();let o=!1,a=!1,l=!1;const c=t?e=>{e.isAnyFunctionActive()||(e.isAllowValue()?(n.push(e),a=!0):e.isAllowRowGroup()?(s.push(e),o=!0):e.isAllowPivot()&&(i.push(e),l=!0))}:e=>{e.isAnyFunctionActive()&&(i.indexOf(e)>=0&&(r._.removeFromArray(i,e),o=!0),n.indexOf(e)>=0&&(r._.removeFromArray(n,e),a=!0),s.indexOf(e)>=0&&(r._.removeFromArray(s,e),l=!0))};if(e.forEach(c),o){const e={type:r.sVA.EVENT_COLUMN_PIVOT_CHANGE_REQUEST,columns:i};this.eventService.dispatchEvent(e)}if(l){const e={type:r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGE_REQUEST,columns:s};this.eventService.dispatchEvent(e)}if(a){const e={type:r.sVA.EVENT_COLUMN_VALUE_CHANGE_REQUEST,columns:s};this.eventService.dispatchEvent(e)}}setAllPivotActive(e,t,i){const r=[],n=t?e=>{if(!e.isAnyFunctionActive())if(e.isAllowValue()){const t="string"==typeof e.getAggFunc()?e.getAggFunc():this.aggFuncService.getDefaultAggFunc(e);r.push({colId:e.getId(),aggFunc:t})}else e.isAllowRowGroup()?r.push({colId:e.getId(),rowGroup:!0}):e.isAllowPivot()&&r.push({colId:e.getId(),pivot:!0})}:e=>{(e.isPivotActive()||e.isRowGroupActive()||e.isValueActive())&&r.push({colId:e.getId(),pivot:!1,rowGroup:!1,aggFunc:null})};e.forEach(n),r.length>0&&this.columnModel.applyColumnState({state:r},i)}updateColumns(e){const{columns:t,visibleState:i,pivotState:r,eventType:n}=e,s=t.map(e=>{const t=e.getColId();if(this.columnModel.isPivotMode()){const e=null==r?void 0:r[t];return{colId:t,pivot:null==e?void 0:e.pivot,rowGroup:null==e?void 0:e.rowGroup,aggFunc:null==e?void 0:e.aggFunc}}return{colId:t,hide:!(null==i?void 0:i[t])}});this.columnModel.applyColumnState({state:s},n)}createPivotState(e){return{pivot:e.isPivotActive(),rowGroup:e.isRowGroupActive(),aggFunc:e.isValueActive()?e.getAggFunc():void 0}}};ia([(0,r.dsm)("aggFuncService")],Sa.prototype,"aggFuncService",2),ia([(0,r.dsm)("columnModel")],Sa.prototype,"columnModel",2),ia([(0,r.dsm)("gridOptionsService")],Sa.prototype,"gos",2),ia([(0,r.dsm)("eventService")],Sa.prototype,"eventService",2),Sa=ia([(0,r.dR4)("modelItemUtils")],Sa);var ba,Ea,Aa,Ta,Ma,Ra,_a,Pa,xa,Da={version:"31.3.4",moduleName:r.zsj.ColumnsToolPanelModule,beans:[Sa],agStackComponents:[{componentName:"AgPrimaryColsHeader",componentClass:na},{componentName:"AgPrimaryColsList",componentClass:fa},{componentName:"AgPrimaryCols",componentClass:Ca}],userComponents:[{componentName:"agColumnsToolPanel",componentClass:wa}],dependantModules:[S,Ao,qo]},Ia=Object.defineProperty,La=Object.defineProperties,Na=Object.getOwnPropertyDescriptor,Oa=Object.getOwnPropertyDescriptors,Fa=Object.getOwnPropertySymbols,ka=Object.prototype.hasOwnProperty,Ga=Object.prototype.propertyIsEnumerable,Va=(e,t,i)=>t in e?Ia(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Ha=(e,t)=>{for(var i in t||(t={}))ka.call(t,i)&&Va(e,i,t[i]);if(Fa)for(var i of Fa(t))Ga.call(t,i)&&Va(e,i,t[i]);return e},Ba=(e,t)=>La(e,Oa(t)),za=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Na(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Ia(t,i,s),s},Ua={getTemplate(e){const t=(new Date).toJSON();return{name:"cp:coreProperties",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{cp:"http://schemas.openxmlformats.org/package/2006/metadata/core-properties",dc:"http://purl.org/dc/elements/1.1/",dcterms:"http://purl.org/dc/terms/",dcmitype:"http://purl.org/dc/dcmitype/",xsi:"http://www.w3.org/2001/XMLSchema-instance"}}]},children:[{name:"dc:creator",textNode:e},{name:"dc:title",textNode:"Workbook"},{name:"dcterms:created",properties:{rawMap:{"xsi:type":"dcterms:W3CDTF"}},textNode:t},{name:"dcterms:modified",properties:{rawMap:{"xsi:type":"dcterms:W3CDTF"}},textNode:t}]}}},Wa={getTemplate(e){const{name:t,ContentType:i,Extension:r,PartName:n}=e;return{name:t,properties:{rawMap:{Extension:r,PartName:n,ContentType:i}}}}},ja={getTemplate(e){const t=new Array(e).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml",PartName:`/xl/worksheets/sheet${t+1}.xml`})),i=yc.worksheetImages.size,r=yc.worksheetHeaderFooterImages.size,n=yc.worksheetDataTables.size,s={};yc.workbookImageIds.forEach(e=>{const t="jpg"===e.type?"jpeg":e.type;s[t]=!0});const o=new Array(i).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.drawing+xml",PartName:`/xl/drawings/drawing${t+1}.xml`})),a=new Array(n).fill(void 0).map((e,t)=>({name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml",PartName:`/xl/tables/${yc.getTableNameFromIndex(t)}.xml`})),l=Object.keys(s).map(e=>({name:"Default",ContentType:`image/${e}`,Extension:e}));return r&&l.push({name:"Default",Extension:"vml",ContentType:"application/vnd.openxmlformats-officedocument.vmlDrawing"}),{name:"Types",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/package/2006/content-types"}},children:[...l,{name:"Default",Extension:"rels",ContentType:"application/vnd.openxmlformats-package.relationships+xml"},{name:"Default",ContentType:"application/xml",Extension:"xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml",PartName:"/xl/workbook.xml"},...t,{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.theme+xml",PartName:"/xl/theme/theme1.xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml",PartName:"/xl/styles.xml"},{name:"Override",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml",PartName:"/xl/sharedStrings.xml"},...o,...a,{name:"Override",ContentType:"application/vnd.openxmlformats-package.core-properties+xml",PartName:"/docProps/core.xml"}].map(e=>Wa.getTemplate(e))}}},Ka={0:1,"0.00":2,"#,##0":3,"#,##0.00":4,"0%":9,"0.00%":10,"0.00E+00":11,"# ?/?":12,"# ??/??":13,"mm-dd-yy":14,"d-mmm-yy":15,"d-mmm":16,"mmm-yy":17,"h:mm AM/PM":18,"h:mm:ss AM/PM":19,"h:mm":20,"h:mm:ss":21,"m/d/yy h:mm":22,"#,##0 ;(#,##0)":37,"#,##0 ;[Red](#,##0)":38,"#,##0.00;(#,##0.00)":39,"#,##0.00;[Red](#,##0.00)":40,"mm:ss":45,"[h]:mm:ss":46,"mmss.0":47,"##0.0E+0":48,"@":49},$a=e=>Math.round(96*e/72),qa=e=>Math.ceil(9525*e),Ya=(e,t)=>{if(!t)return;let i;return i="number"==typeof t?t:t({rowIndex:e}),r=i,Math.round(72*r/96);var r},Qa=(e,t)=>{const i=r.aS7.createHeader({encoding:"UTF-8",standalone:"yes"}),n=r.aS7.createXml(e);return t?n:`${i}${n}`},Xa=e=>{const t=String.fromCharCode,i=Math.floor(e/26),r=e%26;return i&&26!==e?r?i<26?t(65+i-1)+t(65+r-1):Xa(i)+t(65+r-1):Xa(i-1)+"Z":t(65+e-1)},Za=(e,t)=>({name:`xdr:${e}`,children:[{name:"xdr:col",textNode:t.col.toString()},{name:"xdr:colOff",textNode:t.offsetX.toString()},{name:"xdr:row",textNode:t.row.toString()},{name:"xdr:rowOff",textNode:t.offsetY.toString()}]}),Ja=e=>{const t=[{name:"a:ext",properties:{rawMap:{uri:"{FF2B5EF4-FFF2-40B4-BE49-F238E27FC236}"}},children:[{name:"a16:creationId",properties:{rawMap:{id:"{822E6D20-D7BC-2841-A643-D49A6EF008A2}","xmlns:a16":"http://schemas.microsoft.com/office/drawing/2014/main"}}}]}];switch(e.recolor&&e.recolor.toLowerCase()){case"grayscale":case"sepia":case"washout":t.push({name:"a:ext",properties:{rawMap:{uri:"{C183D7F6-B498-43B3-948B-1728B52AA6E4}"}},children:[{name:"adec:decorative",properties:{rawMap:{val:"0","xmlns:adec":"http://schemas.microsoft.com/office/drawing/2017/decorative"}}}]})}return{name:"a:extLst",children:t}},el=(e,t)=>({name:"xdr:nvPicPr",children:[{name:"xdr:cNvPr",properties:{rawMap:{id:t,name:e.id,descr:null!=e.altText?e.altText:void 0}},children:[Ja(e)]},{name:"xdr:cNvPicPr",properties:{rawMap:{preferRelativeResize:"0"}},children:[{name:"a:picLocks"}]}]}),tl=e=>{if(!e.saturation&&!e.tint)return;const t=[];return e.saturation&&t.push({name:"a:satMod",properties:{rawMap:{val:1e3*e.saturation}}}),e.tint&&t.push({name:"a:tint",properties:{rawMap:{val:1e3*e.tint}}}),t},il=(e,t)=>{let i;if(e.transparency){const t=Math.min(Math.max(e.transparency,0),100);i=[{name:"a:alphaModFix",properties:{rawMap:{amt:1e5-Math.round(1e3*t)}}}]}if(e.recolor)switch(i||(i=[]),e.recolor.toLocaleLowerCase()){case"grayscale":i.push({name:"a:grayscl"});break;case"sepia":i.push((n={color:"D9C3A5",tint:50,saturation:180},{name:"a:duotone",children:[{name:"a:prstClr",properties:{rawMap:{val:(r={color:"black"}).color}},children:tl(r)},{name:"a:srgbClr",properties:{rawMap:{val:n.color}},children:tl(n)}]}));break;case"washout":i.push({name:"a:lum",properties:{rawMap:{bright:"70000",contrast:"-70000"}}})}var r,n;return{name:"xdr:blipFill",children:[{name:"a:blip",properties:{rawMap:{cstate:"print","r:embed":`rId${t}`,"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}},children:i},{name:"a:stretch",children:[{name:"a:fillRect"}]}]}},rl=(e,t)=>{const i={name:"a:xfrm",children:[{name:"a:off",properties:{rawMap:{x:0,y:0}}},{name:"a:ext",properties:{rawMap:{cx:t.width,cy:t.height}}}]};if(e.rotation){const t=e.rotation;i.properties={rawMap:{rot:6e4*Math.min(Math.max(t,0),360)}}}return{name:"xdr:spPr",children:[i,{name:"a:prstGeom",properties:{rawMap:{prst:"rect"}},children:[{name:"a:avLst"}]}]}},nl=(e,t,i,r)=>({name:"xdr:pic",children:[el(e,t+1),il(e,i+1),rl(e,r)]}),sl={getTemplate(e){const{sheetIndex:t}=e,i=yc.worksheetImages.get(t),r=yc.worksheetImageIds.get(t);return{name:"xdr:wsDr",properties:{rawMap:{"xmlns:a":"http://schemas.openxmlformats.org/drawingml/2006/main","xmlns:xdr":"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing"}},children:i.map((e,t)=>{const i=(e=>{e.fitCell=!!e.fitCell||!e.width||!e.height;const{position:t={},fitCell:i,width:r=0,height:n=0,totalHeight:s,totalWidth:o}=e,{offsetX:a=0,offsetY:l=0,row:c=1,rowSpan:u=1,column:h=1,colSpan:d=1}=t;return{from:{row:c-1,col:h-1,offsetX:qa(a),offsetY:qa(l)},to:{row:c-1+(i?1:u-1),col:h-1+(i?1:d-1),offsetX:qa(r+a),offsetY:qa(n+l)},height:qa(s||n),width:qa(o||r)}})(e);return{name:"xdr:twoCellAnchor",properties:{rawMap:{editAs:"absolute"}},children:[Za("from",i.from),Za("to",i.to),nl(e,t,r.get(e.id).index,i),{name:"xdr:clientData"}]}})}}},ol={getTemplate(e,t){const{name:i,columns:r,rowCount:n,displayName:s,headerRowIndex:o,showRowStripes:a,showColumnStripes:l,showFilterButtons:c,highlightFirstColumn:u,highlightLastColumn:h}=e||{};if(!(e&&i&&Array.isArray(r)&&r.length&&n))return{name:"table"};const d=r.map((e,t)=>({name:"filterColumn",properties:{rawMap:{colId:t.toString(),hiddenButton:c[t]?0:1}}})),p=o+1,g=(t+1).toString(),f=`A${p}:${String.fromCharCode(64+r.length)}${p+n}`;return{name:"table",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"xr xr3","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision","xmlns:xr3":"http://schemas.microsoft.com/office/spreadsheetml/2016/revision3",name:i,displayName:t?`${s}_${t+1}`:s,ref:f,totalsRowShown:0,id:g}},children:[{name:"autoFilter",properties:{rawMap:{ref:f}},children:d},{name:"tableColumns",properties:{rawMap:{count:r.length}},children:r.map((e,t)=>({name:"tableColumn",properties:{rawMap:{id:(t+1).toString(),name:e,dataCellStyle:"Normal"}}}))},{name:"tableStyleInfo",properties:{rawMap:{name:"TableStyleLight1",showFirstColumn:u?1:0,showLastColumn:h?1:0,showRowStripes:a?1:0,showColumnStripes:l?1:0}}}]}}},al=e=>{const[t,i,r,n]=e;return{name:`a:${t}`,children:[{name:`a:${i}`,properties:{rawMap:{val:r,lastClr:n}}}]}},ll=()=>({name:"a:clrScheme",properties:{rawMap:{name:"Office"}},children:[al(["dk1","sysClr","windowText","000000"]),al(["lt1","sysClr","window","FFFFFF"]),al(["dk2","srgbClr","44546A"]),al(["lt2","srgbClr","E7E6E6"]),al(["accent1","srgbClr","4472C4"]),al(["accent2","srgbClr","ED7D31"]),al(["accent3","srgbClr","A5A5A5"]),al(["accent4","srgbClr","FFC000"]),al(["accent5","srgbClr","5B9BD5"]),al(["accent6","srgbClr","70AD47"]),al(["hlink","srgbClr","0563C1"]),al(["folHlink","srgbClr","954F72"])]}),cl=e=>{const[t,i,r,n]=e;return{name:`a:${t}`,properties:{rawMap:{script:r,typeface:i,panose:n}}}},ul=()=>({name:"a:fontScheme",properties:{rawMap:{name:"Office"}},children:[{name:"a:majorFont",children:[cl(["latin","Calibri Light",void 0,"020F0302020204030204"]),cl(["ea",""]),cl(["cs",""]),cl(["font","游ゴシック Light","Jpan"]),cl(["font","맑은 고딕","Hang"]),cl(["font","等线 Light","Hans"]),cl(["font","新細明體","Hant"]),cl(["font","Times New Roman","Arab"]),cl(["font","Times New Roman","Hebr"]),cl(["font","Tahoma","Thai"]),cl(["font","Nyala","Ethi"]),cl(["font","Vrinda","Beng"]),cl(["font","Shruti","Gujr"]),cl(["font","MoolBoran","Khmr"]),cl(["font","Tunga","Knda"]),cl(["font","Raavi","Guru"]),cl(["font","Euphemia","Cans"]),cl(["font","Plantagenet Cherokee","Cher"]),cl(["font","Microsoft Yi Baiti","Yiii"]),cl(["font","Microsoft Himalaya","Tibt"]),cl(["font","MV Boli","Thaa"]),cl(["font","Mangal","Deva"]),cl(["font","Gautami","Telu"]),cl(["font","Latha","Taml"]),cl(["font","Estrangelo Edessa","Syrc"]),cl(["font","Kalinga","Orya"]),cl(["font","Kartika","Mlym"]),cl(["font","DokChampa","Laoo"]),cl(["font","Iskoola Pota","Sinh"]),cl(["font","Mongolian Baiti","Mong"]),cl(["font","Times New Roman","Viet"]),cl(["font","Microsoft Uighur","Uigh"]),cl(["font","Sylfaen","Geor"]),cl(["font","Arial","Armn"]),cl(["font","Leelawadee UI","Bugi"]),cl(["font","Microsoft JhengHei","Bopo"]),cl(["font","Javanese Text","Java"]),cl(["font","Segoe UI","Lisu"]),cl(["font","Myanmar Text","Mymr"]),cl(["font","Ebrima","Nkoo"]),cl(["font","Nirmala UI","Olck"]),cl(["font","Ebrima","Osma"]),cl(["font","Phagspa","Phag"]),cl(["font","Estrangelo Edessa","Syrn"]),cl(["font","Estrangelo Edessa","Syrj"]),cl(["font","Estrangelo Edessa","Syre"]),cl(["font","Nirmala UI","Sora"]),cl(["font","Microsoft Tai Le","Tale"]),cl(["font","Microsoft New Tai Lue","Talu"]),cl(["font","Ebrima","Tfng"])]},{name:"a:minorFont",children:[cl(["latin","Calibri",void 0,"020F0502020204030204"]),cl(["ea",""]),cl(["cs",""]),cl(["font","游ゴシック","Jpan"]),cl(["font","맑은 고딕","Hang"]),cl(["font","等线","Hans"]),cl(["font","新細明體","Hant"]),cl(["font","Arial","Arab"]),cl(["font","Arial","Hebr"]),cl(["font","Tahoma","Thai"]),cl(["font","Nyala","Ethi"]),cl(["font","Vrinda","Beng"]),cl(["font","Shruti","Gujr"]),cl(["font","DaunPenh","Khmr"]),cl(["font","Tunga","Knda"]),cl(["font","Raavi","Guru"]),cl(["font","Euphemia","Cans"]),cl(["font","Plantagenet Cherokee","Cher"]),cl(["font","Microsoft Yi Baiti","Yiii"]),cl(["font","Microsoft Himalaya","Tibt"]),cl(["font","MV Boli","Thaa"]),cl(["font","Mangal","Deva"]),cl(["font","Gautami","Telu"]),cl(["font","Latha","Taml"]),cl(["font","Estrangelo Edessa","Syrc"]),cl(["font","Kalinga","Orya"]),cl(["font","Kartika","Mlym"]),cl(["font","DokChampa","Laoo"]),cl(["font","Iskoola Pota","Sinh"]),cl(["font","Mongolian Baiti","Mong"]),cl(["font","Arial","Viet"]),cl(["font","Microsoft Uighur","Uigh"]),cl(["font","Sylfaen","Geor"]),cl(["font","Arial","Armn"]),cl(["font","Leelawadee UI","Bugi"]),cl(["font","Microsoft JhengHei","Bopo"]),cl(["font","Javanese Text","Java"]),cl(["font","Segoe UI","Lisu"]),cl(["font","Myanmar Text","Mymr"]),cl(["font","Ebrima","Nkoo"]),cl(["font","Nirmala UI","Olck"]),cl(["font","Ebrima","Osma"]),cl(["font","Phagspa","Phag"]),cl(["font","Estrangelo Edessa","Syrn"]),cl(["font","Estrangelo Edessa","Syrj"]),cl(["font","Estrangelo Edessa","Syre"]),cl(["font","Nirmala UI","Sora"]),cl(["font","Microsoft Tai Le","Tale"]),cl(["font","Microsoft New Tai Lue","Talu"]),cl(["font","Ebrima","Tfng"])]}]}),hl=(e,t,i)=>({name:`a:${e}`,properties:{rawMap:{val:t}},children:i}),dl=e=>{const[t,i,r,n,s,o]=e,a=[];return a.push(hl("satMod",r)),n&&a.push(hl("lumMod",n)),s&&a.push(hl("tint",s)),o&&a.push(hl("shade",o)),{name:"a:gs",properties:{rawMap:{pos:t}},children:[{name:"a:schemeClr",properties:{rawMap:{val:i}},children:a}]}},pl=(e,t)=>({name:"a:solidFill",children:[hl("schemeClr",e,t)]}),gl=e=>{const[t,i,r,n,s]=e,[o,a]=s;return{name:"a:gradFill",properties:{rawMap:{rotWithShape:t}},children:[{name:"a:gsLst",children:[dl(i),dl(r),dl(n)]},{name:"a:lin",properties:{rawMap:{ang:o,scaled:a}}}]}},fl=e=>{const[t,i,r,n]=e;return{name:"a:ln",properties:{rawMap:{w:t,cap:i,cmpd:r,algn:n}},children:[pl("phClr"),hl("prstDash","solid"),{name:"a:miter",properties:{rawMap:{lim:"800000"}}}]}},ml=e=>{const t=[];if(e){const[i,r,n,s,o]=e;t.push({name:"a:outerShdw",properties:{rawMap:{blurRad:i,dist:r,dir:n,algn:s,rotWithShape:o}},children:[hl("srgbClr","000000",[hl("alpha","63000")])]})}return{name:"a:effectStyle",children:[Object.assign({},{name:"a:effectLst"},t.length?{children:t}:{})]}},vl=()=>({name:"a:fmtScheme",properties:{rawMap:{name:"Office"}},children:[{name:"a:fillStyleLst",children:[pl("phClr"),gl(["1",["0","phClr","105000","110000","67000"],["50000","phClr","103000","105000","73000"],["100000","phClr","109000","105000","81000"],["5400000","0"]]),gl(["1",["0","phClr","103000","102000","94000"],["50000","phClr","110000","100000",void 0,"100000"],["100000","phClr","120000","99000",void 0,"78000"],["5400000","0"]])]},{name:"a:lnStyleLst",children:[fl(["6350","flat","sng","ctr"]),fl(["12700","flat","sng","ctr"]),fl(["19050","flat","sng","ctr"])]},{name:"a:effectStyleLst",children:[ml(),ml(),ml(["57150","19050","5400000","ctr","0"])]},{name:"a:bgFillStyleLst",children:[pl("phClr"),pl("phClr",[hl("tint","95000"),hl("satMod","170000")]),gl(["1",["0","phClr","150000","102000","93000","98000"],["50000","phClr","130000","103000","98000","90000"],["100000","phClr","120000",void 0,void 0,"63000"],["5400000","0"]])]}]}),Cl=()=>({name:"a:themeElements",children:[ll(),ul(),vl()]}),yl=()=>({name:"a:theme",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{a:"http://schemas.openxmlformats.org/drawingml/2006/main"}}],rawMap:{name:"Office Theme"}},children:[Cl(),{name:"a:objectDefaults"},{name:"a:extraClrSchemeLst"}]}),wl=e=>{const t=[];for(const i of e.keys()){const e=i.toString(),n={name:"t",textNode:r._.escapeString(e)};e.trim().length!==e.length&&(n.properties={rawMap:{"xml:space":"preserve"}}),t.push({name:"si",children:[n]})}return t},Sl=e=>({name:"sst",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main",count:e.size,uniqueCount:e.size}},children:wl(e)}),bl={getTemplate(e){let{formatCode:t,numFmtId:i}=e;return t.length&&(t=function(e){const t=e.split(/(\[[^\]]*\])/);for(let e=0;e<t.length;e++){let i=t[e];i.length&&(i.startsWith("[")||(i=i.replace(/\$/g,'"$"')),t[e]=r._.escapeString(i))}return t.join("")}(t)),{name:"numFmt",properties:{rawMap:{formatCode:t,numFmtId:i}}}}},El=e=>({name:"numFmts",properties:{rawMap:{count:e.length}},children:e.map(e=>bl.getTemplate(e))}),Al={getTemplate(e){const{size:t,colorTheme:i,color:r="FF000000",fontName:n="Calibri",family:s,scheme:o,italic:a,bold:l,strikeThrough:c,outline:u,shadow:h,underline:d,verticalAlign:p}=e,g=[{name:"sz",properties:{rawMap:{val:t}}},{name:"color",properties:{rawMap:{theme:i,rgb:r}}},{name:"name",properties:{rawMap:{val:n}}}];return s&&g.push({name:"family",properties:{rawMap:{val:s}}}),o&&g.push({name:"scheme",properties:{rawMap:{val:o}}}),a&&g.push({name:"i"}),l&&g.push({name:"b"}),c&&g.push({name:"strike"}),u&&g.push({name:"outline"}),h&&g.push({name:"shadow"}),d&&g.push({name:"u",properties:{rawMap:{val:d}}}),p&&g.push({name:"vertAlign",properties:{rawMap:{val:p}}}),{name:"font",children:g}}},Tl=e=>({name:"fonts",properties:{rawMap:{count:e.length}},children:e.map(e=>Al.getTemplate(e))}),Ml={getTemplate(e){const{patternType:t,fgTheme:i,fgTint:r,fgRgb:n,bgRgb:s,bgIndexed:o}=e,a={name:"patternFill",properties:{rawMap:{patternType:t}}};return(i||r||n)&&(a.children=[{name:"fgColor",properties:{rawMap:{theme:i,tint:r,rgb:n}}}]),(o||s)&&(a.children||(a.children=[]),a.children.push({name:"bgColor",properties:{rawMap:{indexed:o,rgb:s}}})),{name:"fill",children:[a]}}},Rl=e=>({name:"fills",properties:{rawMap:{count:e.length}},children:e.map(e=>Ml.getTemplate(e))}),_l={None:"None",Dot:"Dotted",Dash:"Dashed",Double:"Double",DashDot:"DashDot",DashDotDot:"DashDotDot",SlantDashDot:"SlantDashDot"},Pl=["Dashed","DashDot","DashDotDot"],xl={None:"none",Solid:"solid",Gray50:"mediumGray",Gray75:"darkGray",Gray25:"lightGray",HorzStripe:"darkHorizontal",VertStripe:"darkVertical",ReverseDiagStripe:"darkDown",DiagStripe:"darkUp",DiagCross:"darkGrid",ThickDiagCross:"darkTrellis",ThinHorzStripe:"lightHorizontal",ThinVertStripe:"lightVertical",ThinReverseDiagStripe:"lightDown",ThinDiagStripe:"lightUp",ThinHorzCross:"lightGrid",ThinDiagCross:"lightTrellis",Gray125:"gray125",Gray0625:"gray0625"},Dl={Automatic:"general",Left:"left",Center:"center",Right:"right",Fill:"fill",Justify:"justify",CenterAcrossSelection:"centerContinuous",Distributed:"distributed",JustifyDistributed:"justify"},Il={Automatic:void 0,Top:"top",Bottom:"bottom",Center:"center",Justify:"justify",Distributed:"distributed",JustifyDistributed:"justify"},Ll=e=>null==e?e:("#"===e.charAt(0)&&(e=e.substring(1)),6===e.length?"FF"+e:e),Nl=(e,t)=>{if(!e)return"thin";const i=(e=>{switch(e){case 1:return"thin";case 2:return"medium";case 3:return"thick";default:return"hair"}})(t),r=_l[e];return"Continuous"===e?i:"medium"===i&&-1!==Pl.indexOf(r)?`medium${r}`:r.charAt(0).toLowerCase()+r.substring(1)},Ol=e=>Dl[e]||"general",Fl=e=>Il[e]||void 0,kl=e=>({name:"color",properties:{rawMap:{rgb:Ll(e||"#000000")}}}),Gl={getTemplate(e){const{left:t,right:i,top:r,bottom:n,diagonal:s}=e,o=t?[kl(t.color)]:void 0,a=i?[kl(i.color)]:void 0,l=r?[kl(r.color)]:void 0,c=n?[kl(n.color)]:void 0,u=s?[kl(s.color)]:void 0;return{name:"border",children:[{name:"left",properties:{rawMap:{style:t&&t.style}},children:o},{name:"right",properties:{rawMap:{style:i&&i.style}},children:a},{name:"top",properties:{rawMap:{style:r&&r.style}},children:l},{name:"bottom",properties:{rawMap:{style:n&&n.style}},children:c},{name:"diagonal",properties:{rawMap:{style:s&&s.style}},children:u}]}}},Vl=e=>({name:"borders",properties:{rawMap:{count:e.length}},children:e.map(e=>Gl.getTemplate(e))}),Hl=e=>{const t=["Context","LeftToRight","RightToLeft"].indexOf(e);return Math.max(t,0)},Bl={getTemplate(e){const{horizontal:t,indent:i,readingOrder:r,rotate:n,shrinkToFit:s,vertical:o,wrapText:a}=e;return{name:"alignment",properties:{rawMap:{horizontal:t&&Ol(t),indent:i,readingOrder:r&&Hl(r),textRotation:n,shrinkToFit:s,vertical:o&&Fl(o),wrapText:a}}}}},zl={getTemplate(e){const t=!1===e.protected?0:1;return{name:"protection",properties:{rawMap:{hidden:!0===e.hideFormula?1:0,locked:t}}}}},Ul={getTemplate(e){const{alignment:t,borderId:i,fillId:r,fontId:n,numFmtId:s,protection:o,quotePrefix:a,xfId:l}=e,c=[];return t&&c.push(Bl.getTemplate(t)),o&&c.push(zl.getTemplate(o)),{name:"xf",properties:{rawMap:{applyAlignment:t?1:void 0,applyProtection:o?1:void 0,applyBorder:i?1:void 0,applyFill:r?1:void 0,borderId:i,fillId:r,applyFont:n?1:void 0,fontId:n,applyNumberFormat:s?1:void 0,numFmtId:s,quotePrefix:a?1:void 0,xfId:l}},children:c.length?c:void 0}}},Wl=e=>({name:"cellStyleXfs",properties:{rawMap:{count:e.length}},children:e.map(e=>Ul.getTemplate(e))}),jl=e=>({name:"cellXfs",properties:{rawMap:{count:e.length}},children:e.map(e=>Ul.getTemplate(e))}),Kl={getTemplate(e){const{builtinId:t,name:i,xfId:r}=e;return{name:"cellStyle",properties:{rawMap:{builtinId:t,name:i,xfId:r}}}}},$l=e=>({name:"cellStyles",properties:{rawMap:{count:e.length}},children:e.map(e=>Kl.getTemplate(e))}),ql=(e,t)=>(-1!==e.indexOf("mixedStyle")&&t>1&&(e+=`_${t}`),e),Yl=()=>{ba={base:0},Ea=[],Aa=[{fontName:"Calibri",colorTheme:"1",family:"2",scheme:"minor"}],Ta=[{patternType:"none"},{patternType:"gray125"}],Ma=[{left:void 0,right:void 0,top:void 0,bottom:void 0,diagonal:void 0}],Ra=[{borderId:0,fillId:0,fontId:0,numFmtId:0}],_a=[{borderId:0,fillId:0,fontId:0,numFmtId:0,xfId:0}],Pa=[{builtinId:0,name:"Normal",xfId:0}]},Ql=e=>{const{alignment:t,borders:i,font:r,interior:n,numberFormat:s,protection:o,quotePrefix:a}=e;let{id:l}=e,c=0,u=0,h=0,d=0;l&&(l=ql(l,xa),null==ba[l]&&(n&&(c=(e=>{const t=(i=e.pattern)?xl[i]||i:"none";var i;const r=Ll(e.color),n=Ll(e.patternColor);let s=Ta.findIndex(e=>{const{patternType:i,fgRgb:s,bgRgb:o}=e;return i==t&&s==r&&o==n});return-1===s&&(s=Ta.length,Ta.push({patternType:t,fgRgb:r,bgRgb:n})),s})(n)),i&&(u=(e=>{const{borderBottom:t,borderTop:i,borderLeft:r,borderRight:n}=e;let s,o,a,l,c,u,h,d;r&&(a=Nl(r.lineStyle,r.weight),h=Ll(r.color)),n&&(l=Nl(n.lineStyle,n.weight),d=Ll(n.color)),t&&(s=Nl(t.lineStyle,t.weight),c=Ll(t.color)),i&&(o=Nl(i.lineStyle,i.weight),u=Ll(i.color));let p=Ma.findIndex(e=>{const{left:t,right:i,top:r,bottom:n}=e;if(!t&&(a||h))return!1;if(!i&&(l||d))return!1;if(!r&&(o||u))return!1;if(!n&&(s||c))return!1;const{style:p,color:g}=t||{},{style:f,color:m}=i||{},{style:v,color:C}=r||{},{style:y,color:w}=n||{};return p==a&&g==h&&f==l&&m==d&&v==o&&C==u&&y==s&&w==c});return-1===p&&(p=Ma.length,Ma.push({left:{style:a,color:h},right:{style:l,color:d},top:{style:o,color:u},bottom:{style:s,color:c},diagonal:{style:void 0,color:void 0}})),p})(i)),r&&(h=(e=>{const{fontName:t="Calibri",color:i,size:r,bold:n,italic:s,outline:o,shadow:a,strikeThrough:l,underline:c,family:u,verticalAlign:h}=e,d=Ll(i),p=(e=>{if(void 0===e)return;const t=["Automatic","Roman","Swiss","Modern","Script","Decorative"].indexOf(e||"Automatic");return Math.max(t,0)})(u),g=c?c.toLocaleLowerCase():void 0,f=h?h.toLocaleLowerCase():void 0;let m=Aa.findIndex(e=>e.fontName==t&&e.color==d&&e.size==r&&e.bold==n&&e.italic==s&&e.outline==o&&e.shadow==a&&e.strikeThrough==l&&e.underline==g&&e.verticalAlign==f&&e.family==p);return-1===m&&(m=Aa.length,Aa.push({fontName:t,color:d,size:r,bold:n,italic:s,outline:o,shadow:a,strikeThrough:l,underline:g,verticalAlign:f,family:null!=p?p.toString():void 0})),m})(r)),s&&(d=(e=>{if(Ka[e])return Ka[e];let t=Ea.findIndex(t=>t.formatCode===e);return-1===t?(t=Ea.length+164,Ea.push({formatCode:e,numFmtId:t})):t=Ea[t].numFmtId,t})(s.format)),ba[l]=_a.length,_a.push({alignment:t,borderId:u||0,fillId:c||0,fontId:h||0,numFmtId:d||0,protection:o,quotePrefix:a,xfId:0})))},Xl=(e,t)=>ba[ql(e,t)]||0,Zl={getTemplate(e){const t=El(Ea),i=Tl(Aa.map(t=>Ba(Ha({},t),{size:null!=t.size?t.size:e}))),r=Rl(Ta),n=Vl(Ma),s=Wl(Ra),o=jl(_a),a=$l(Pa);return Yl(),{name:"styleSheet",properties:{rawMap:{"mc:Ignorable":"x14ac x16r2 xr",xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac","xmlns:x16r2":"http://schemas.microsoft.com/office/spreadsheetml/2015/02/main","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision"}},children:[t,i,r,n,s,o,a,{name:"tableStyles",properties:{rawMap:{count:0,defaultPivotStyle:"PivotStyleLight16",defaultTableStyle:"TableStyleMedium2"}}}]}}},Jl={getTemplate(e,t){const i=(t+1).toString();return{name:"sheet",properties:{rawMap:{name:e,sheetId:i,"r:id":`rId${i}`}}}}},ec=e=>({name:"sheets",children:e.map((e,t)=>Jl.getTemplate(e,t))}),tc=e=>({name:"workbook",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}}],rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},children:[ec(e)]}),ic={getTemplate(e){const{min:t,max:i,outlineLevel:r,s:n,width:s,hidden:o,bestFit:a}=e;let l=1,c="0";return s>1&&(l=(e=>Math.ceil((e-12)/7+1))(s),c="1"),{name:"col",properties:{rawMap:{min:t,max:i,outlineLevel:null!=r?r:void 0,width:l,style:n,hidden:o?"1":"0",bestFit:a?"1":"0",customWidth:c}}}}},rc={getTemplate(e,t,i){const{ref:n,data:s,styleId:o}=e,{type:a,value:l}=s||{type:"empty",value:null};let c=a;"f"===a?c="str":a.charAt(0)===a.charAt(0).toUpperCase()&&(c=(e=>{const t=e.charAt(0).toLowerCase();return"s"===t?"inlineStr":t})(a));const u={name:"c",properties:{rawMap:{r:n,t:"empty"===c?void 0:c,s:o?Xl(o,i):void 0}}};if("empty"===c)return u;let h;return h="str"===c&&"f"===a?[{name:"f",textNode:r._.escapeString(l)}]:"inlineStr"===c?[{name:"is",children:[{name:"t",textNode:r._.escapeString(l)}]}]:[{name:"v",textNode:l}],Object.assign({},u,{children:h})}},nc=e=>{var t;return""!==(null==(t=e.data)?void 0:t.value)||void 0!==e.styleId},sc={getTemplate(e,t,i){const{collapsed:r,hidden:n,height:s,outlineLevel:o,cells:a=[]}=e;return((e,t)=>{const i=[];let r=0;for(let t=0;t<e.length;t++){const n=e[t];n.mergeAcross&&(i.push({pos:t,excelPos:r}),r+=n.mergeAcross),r++}if(i.length)for(let r=i.length-1;r>=0;r--){const n=[],s=e[i[r].pos];for(let e=1;e<=s.mergeAcross;e++)n.push({ref:`${Xa(i[r].excelPos+1+e)}${t+1}`,styleId:s.styleId,data:{type:"empty",value:null}});n.length&&e.splice(i[r].pos+1,0,...n)}})(a,t),{name:"row",properties:{rawMap:{r:t+1,collapsed:r?"1":"0",hidden:n?"1":"0",ht:s,customHeight:null!=s?"1":"0",spans:"1:1",outlineLevel:o||void 0}},children:a.filter(nc).map((e,t)=>rc.getTemplate(e,t,i))}}},oc=e=>({name:"mergeCell",properties:{rawMap:{ref:e}}}),ac=e=>{if(null==e)return 1;const t=["Letter","Letter Small","Tabloid","Ledger","Legal","Statement","Executive","A3","A4","A4 Small","A5","A6","B4","B5","Folio","Envelope","Envelope DL","Envelope C5","Envelope B5","Envelope C3","Envelope C4","Envelope C6","Envelope Monarch","Japanese Postcard","Japanese Double Postcard"].indexOf(e);return-1===t?1:t+1},lc=(e,t,i)=>e.reduce((e,n,s)=>{const o="Center"===(a=n.position)?"C":"Right"===a?"R":"L";var a;const l=(c=`${e}&amp;${o}`,(u=n.font)?(c+="&amp;&quot;",c+=u.fontName||"Calibri",u.bold!==u.italic?c+=u.bold?",Bold":",Italic":u.bold?c+=",Bold Italic":c+=",Regular",c+="&quot;",u.size&&(c+=`&amp;${u.size}`),u.strikeThrough&&(c+="&amp;S"),u.underline&&(c+="&amp;"+("Double"===u.underline?"E":"U")),u.color&&(c+=`&amp;K${u.color.replace("#","").toUpperCase()}`),c):c);var c,u;n.position||(n.position=["Left","Center","Right"][s]);const{image:h}=n;if("&[Picture]"===n.value&&h){const e=`${o}${t}${i}`;yc.addHeaderFooterImageToMap(h,e)}return`${l}${r._.escapeString((d=n.value,r._.iterateObject({"&[Page]":"&P","&[Pages]":"&N","&[Date]":"&D","&[Time]":"&T","&[Tab]":"&A","&[Path]":"&Z","&[File]":"&F","&[Picture]":"&G"},(e,t)=>{d=d.replace(e,t)}),d))}`;var d},""),cc=e=>{const t=[];return["all","first","even"].forEach(i=>{const r=e[i],n="all"===i?"odd":i;if(r)for(const[e,s]of Object.entries(r)){const r=`${e.charAt(0).toUpperCase()}${e.slice(1)}`,o=e[0].toUpperCase();if(s){const e="all"===i?"":i.toUpperCase();t.push({name:`${n}${r}`,properties:{rawMap:{"xml:space":"preserve"}},textNode:lc(s,o,e)})}}}),t},uc={getTemplate(e){const{worksheet:t,currentSheet:i,config:n}=e,{margins:s={},pageSetup:o,headerFooterConfig:a,suppressColumnOutline:l}=n,{table:c}=t,{rows:u,columns:h}=c,d=h&&h.length?((e,t,i)=>{const r=[],n=[];e.forEach((e,i)=>{const s=e.cells;let o,a=0;s.forEach((e,s)=>{const l=s+a+1,c=Xa(l),u=i+1;if(e.mergeAcross){a+=e.mergeAcross;const t=Xa(s+a+1);r.push(`${c}${u}:${t}${u}`)}t[l-1]||(t[l-1]={});const{collapsibleRanges:h}=e;h&&h.forEach(e=>{n.push([l+e[0],l+e[1]])}),o=t[l-1],o.min=l,o.max=l,e.ref=`${c}${u}`})}),n.sort((e,t)=>e[0]!==t[0]?e[0]-t[0]:t[1]-e[1]);const s=new Map,o=new Map;return n.filter(e=>{const t=e.toString();return!s.get(t)&&(s.set(t,!0),!0)}).forEach(e=>{const r=t.find(t=>t.min==e[0]&&t.max==e[1]),n=o.get(e[0]);t.push({min:e[0],max:e[1],outlineLevel:i?void 0:n||1,width:(r||{width:100}).width}),o.set(e[0],(n||0)+1)}),r})(u,h,!!l):[],{worksheetDataTables:p}=yc,g=p.get(i),f=r._.compose(e=>(e.children.push({name:"sheetPr",children:[{name:"outlinePr",properties:{rawMap:{summaryBelow:0}}}]}),e),(e=>t=>{const i=e.reduce((e,t)=>t.outlineLevel&&t.outlineLevel>e?t.outlineLevel:e,0);return t.children.push({name:"sheetFormatPr",properties:{rawMap:{baseColWidth:10,defaultRowHeight:16,outlineLevelRow:i||void 0}}}),t})(u),(e=>t=>(e.length&&t.children.push({name:"cols",children:e.map(e=>ic.getTemplate(e))}),t))(h),((e,t)=>i=>(e.length&&i.children.push({name:"sheetData",children:e.map((e,i)=>sc.getTemplate(e,i,t))}),i))(u,i+1),(v=d,e=>(v.length&&e.children.push({name:"mergeCells",properties:{rawMap:{count:v.length}},children:v.map(e=>oc(e))}),e)),(e=>t=>{const{top:i=.75,right:r=.7,bottom:n=.75,left:s=.7,header:o=.3,footer:a=.3}=e;return t.children.push({name:"pageMargins",properties:{rawMap:{bottom:n,footer:a,header:o,left:s,right:r,top:i}}}),t})(s),(e=>t=>{var i;return e&&t.children.push({name:"pageSetup",properties:{rawMap:{horizontalDpi:0,verticalDpi:0,orientation:(i=e.orientation,!i||"Portrait"!==i&&"Landscape"!==i?"portrait":i.toLocaleLowerCase()),paperSize:ac(e.pageSize)}}}),t})(o),(e=>t=>{if(!e)return t;const i=null!=e.first?1:0,r=null!=e.even?1:0;return t.children.push({name:"headerFooter",properties:{rawMap:{differentFirst:i,differentOddEven:r}},children:cc(e)}),t})(a),(e=>t=>{const i=yc.worksheetImages.get(e);return(null==i?void 0:i.length)&&t.children.push({name:"drawing",properties:{rawMap:{"r:id":"rId"+ ++t.rIdCounter}}}),t})(i),(e=>t=>(yc.worksheetHeaderFooterImages.get(e)&&t.children.push({name:"legacyDrawingHF",properties:{rawMap:{"r:id":"rId"+ ++t.rIdCounter}}}),t))(i),(m=g,e=>(m&&e.children.push({name:"tableParts",properties:{rawMap:{count:"1"}},children:[{name:"tablePart",properties:{rawMap:{"r:id":"rId"+ ++e.rIdCounter}}}]}),e)));var m,v;const{children:C}=f({children:[],rIdCounter:0});return{name:"worksheet",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships"}}],rawMap:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},children:C}}},hc={getTemplate(e){const{Id:t,Type:i,Target:r}=e;return{name:"Relationship",properties:{rawMap:{Id:t,Type:i,Target:r}}}}},dc=e=>({name:"Relationships",properties:{rawMap:{xmlns:"http://schemas.openxmlformats.org/package/2006/relationships"}},children:e.map(e=>hc.getTemplate(e))}),pc=e=>{const{aspectratio:t,rotation:i}=e||{},r={};return t&&(r.aspectratio="t"),i&&(r.rotation="t"),{name:"o:lock",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}],rawMap:r}}},gc={0:"0",5:"6554f",10:"13107f",15:"19661f",20:"26214f",25:".5",30:"39322f",35:"45875f",40:"52429f",45:"58982f",50:"1",55:"72818f",60:"1.25",65:"93623f",70:"109227f",75:"2",80:"2.5",85:"3.4",90:"5",95:"10",96:"12.5",97:"1092267f",98:"25",99:"50",100:"2147483647f"},fc=(e,t)=>{var i;let r;const{recolor:n,brightness:s,contrast:o,id:a}=e;var l;return n&&(r={},"Washout"!==n&&"Grayscale"!==n||(r.gain="19661f",r.blacklevel="22938f"),"Black & White"!==n&&"Grayscale"!==n||(r.grayscale="t","Black & White"===n&&(r.bilevel="t"))),n&&"Grayscale"!==n||(r||(r={}),null!=o&&50!==o&&(r.gain=null!=(i=gc[o])?i:"1"),null!=s&&50!==s&&(r.blacklevel=(l=s,(l-0)/100*1-.5).toString())),{name:"v:imagedata",properties:{prefixedAttributes:[{prefix:"o:",map:{relid:`rId${t}`,title:a}}],rawMap:r}}},mc=e=>Math.floor(.74999943307122*(null!=e?e:0)),vc={getTemplate(e){const t=yc.worksheetHeaderFooterImages.get(e.sheetIndex)||[];var i;return{name:"xml",properties:{prefixedAttributes:[{prefix:"xmlns:",map:{v:"urn:schemas-microsoft-com:vml",o:"urn:schemas-microsoft-com:office:office",x:"urn:schemas-microsoft-com:office:excel"}}]},children:[{name:"o:shapelayout",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}]},children:[{name:"o:idmap",properties:{prefixedAttributes:[{prefix:"v:",map:{ext:"edit"}}],rawMap:{data:"1"}}}]},{name:"v:shapetype",properties:{prefixedAttributes:[{prefix:"o:",map:{spt:"75",preferrelative:"t"}}],rawMap:{coordsize:"21600,21600",filled:"f",id:"_x0000_t75",path:"m@4@5l@4@11@9@11@9@5xe",stroked:"f"}},children:[{name:"v:stroke",properties:{rawMap:{joinstyle:"miter"}}},(i=["if lineDrawn pixelLineWidth 0","sum @0 1 0","sum 0 0 @1","prod @2 1 2","prod @3 21600 pixelWidth","prod @3 21600 pixelHeight","sum @0 0 1","prod @6 1 2","prod @7 21600 pixelWidth","sum @8 21600 0","prod @7 21600 pixelHeight","sum @10 21600 0"],{name:"v:formulas",children:i.map(e=>({name:"v:f",properties:{rawMap:{eqn:e}}}))}),{name:"v:path",properties:{prefixedAttributes:[{prefix:"o:",map:{connecttype:"rect",extrusionok:"f"}}],rawMap:{gradientshapeok:"t"}}},pc({aspectratio:!0})]},...t.map((e,t)=>((e,t)=>{const{width:i=0,height:r=0,altText:n}=e,s=mc(i),o=mc(r);return{name:"v:shape",properties:{rawMap:{id:e.headerFooterPosition,"o:spid":"_x0000_s1025",style:`position: absolute; margin-left: 0; margin-top: 10in; margin-bottom: 0; margin-right: 0; width: ${s}pt; height: ${o}pt; z-index: ${t+1}`,type:"#_x0000_t75",alt:n}},children:[fc(e,t+1),pc({rotation:!0})]}})(e,t))]}}},Cc=class e{static createExcel(e,t,i){this.addSheetName(t),((e,t)=>{1===(xa=t)&&Yl(),e.forEach(Ql)})(e,this.sheetNames.length);let r=Object.assign({},i);return i.exportAsExcelTable&&(i.columnModel.isPivotActive()&&(this.showExcelTableNonCompatibleFeaturesWarning("pivot mode"),r.exportAsExcelTable=!1),i.gos.get("masterDetail")&&(this.showExcelTableNonCompatibleFeaturesWarning("master/detail"),r.exportAsExcelTable=!1)),this.processTableConfig(t,r),this.createWorksheet(t,r)}static showExcelTableNonCompatibleFeaturesWarning(e){console.warn(`AG Grid: Excel table export does not work with ${e}. The exported Excel file will not contain any Excel tables.\nPlease turn off ${e} to enable Excel table exports.`)}static getTableNameFromIndex(e){return`table${e+1}`}static getSanitizedTableName(e){return e.replace(/^[^a-zA-Z_]+/,"_").replace(/\s/g,"_").replace(/[^a-zA-Z0-9_]/g,"_")}static addTableToSheet(e,t){this.worksheetDataTables.has(e)?console.warn("Unable to add data table to Excel sheet: A table already exists."):this.worksheetDataTables.set(e,t)}static processTableConfig(t,i){var r;if(!i.exportAsExcelTable)return;const n="boolean"==typeof i.exportAsExcelTable?{}:i.exportAsExcelTable,{name:s,showColumnStripes:o,showRowStripes:a,showFilterButton:l,highlightFirstColumn:c,highlightLastColumn:u}=n,h=this.getSanitizedTableName(s||e.defaultTableDisplayName),d=this.sheetNames.length-1,{table:p}=t,{rows:g,columns:f}=p,m=i.columnModel.getHeaderRowCount(),v=m-1,C=g.length,y=f.length,w=[],S=[];for(let e=0;e<y;e++){const t=f[e];w.push(t.displayName||""),S.push("match"===l||void 0===l?null!=(r=t.filterAllowed)&&r:l)}w&&w.length&&C&&h?this.addTableToSheet(d,{name:this.getTableNameFromIndex(d),displayName:h,columns:w,showFilterButtons:S,headerRowIndex:v,rowCount:C-m,showRowStripes:null==a||a,showColumnStripes:null!=o&&o,highlightFirstColumn:null!=c&&c,highlightLastColumn:null!=u&&u}):console.warn("Unable to add data table to Excel sheet: Missing required parameters.")}static addHeaderFooterImageToMap(e,t){const i=this.sheetNames.length-1,r=e;r.headerFooterPosition=t,this.buildImageMap({imageToAdd:r,idx:i});let n=this.worksheetHeaderFooterImages.get(i);n||(n=[],this.worksheetHeaderFooterImages.set(i,n)),n.find(t=>t.id===e.id)||n.push(e)}static addBodyImageToMap(e,t,i,r,n){let s=this.sheetNames.length;const{row:o,column:a}=e.position||{},l=e;r&&(null==t||null==i||o&&a||(e.position||(e.position={}),e.position=Object.assign({},e.position,{row:t,column:r.indexOf(i)+1})),((e,t)=>{const{colSpan:i,column:r}=e.position;if(e.width)if(i){const n=t.slice(r-1,r+i-1);let s=0;for(let t=0;t<n.length;t++){const i=n[t].getActualWidth();if(e.width<s+i){e.position.colSpan=t+1,e.totalWidth=e.width,e.width=e.totalWidth-s;break}s+=i}}else e.totalWidth=e.width})(l,r),((e,t)=>{const{rowSpan:i,row:r}=e.position;if(e.height)if(i){let n=0,s=0;for(let o=r;o<r+i;o++){const i=$a(Ya(o,t)||20);if(e.height<n+i){e.position.rowSpan=s+1,e.totalHeight=e.height,e.height=e.totalHeight-n;break}n+=i,s++}}else e.totalHeight=e.height})(l,n)),this.buildImageMap({imageToAdd:l,idx:s});let c=this.worksheetImageIds.get(s);c||(c=new Map,this.worksheetImageIds.set(s,c));const u=this.worksheetImages.get(s);u?u.push(l):this.worksheetImages.set(s,[l]),c.get(e.id)||c.set(e.id,{index:c.size,type:e.imageType})}static buildImageMap(e){const{imageToAdd:t,idx:i}=e,r=this.images.get(t.id);if(r){const e=r.find(e=>e.sheetId===i);e?e.image.push(t):r.push({sheetId:i,image:[t]})}else this.images.set(t.id,[{sheetId:i,image:[t]}]),this.workbookImageIds.set(t.id,{type:t.imageType,index:this.workbookImageIds.size})}static addSheetName(e){const t=r._.escapeString(e.name)||"";let i="";for(;-1!==this.sheetNames.indexOf(`${t}${i}`);)if(""===i)i="_1";else{const e=parseInt(i.slice(1),10);i=`_${e+1}`}e.name=`${t}${i}`,this.sheetNames.push(e.name)}static getStringPosition(e){return this.sharedStrings.has(e)?this.sharedStrings.get(e):(this.sharedStrings.set(e,this.sharedStrings.size),this.sharedStrings.size-1)}static resetFactory(){this.sharedStrings=new Map,this.images=new Map,this.worksheetImages=new Map,this.worksheetHeaderFooterImages=new Map,this.workbookImageIds=new Map,this.worksheetImageIds=new Map,this.worksheetDataTables=new Map,this.sheetNames=[],this.factoryMode=r.FiP.SINGLE_SHEET}static createWorkbook(){return Qa(tc(this.sheetNames))}static createStylesheet(e){return Qa(Zl.getTemplate(e))}static createSharedStrings(){return Qa(Sl(this.sharedStrings))}static createCore(e){return Qa(Ua.getTemplate(e))}static createContentTypes(e){return Qa(ja.getTemplate(e))}static createRels(){const e=dc([{Id:"rId1",Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",Target:"xl/workbook.xml"},{Id:"rId2",Type:"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",Target:"docProps/core.xml"}]);return Qa(e)}static createTheme(){return Qa(yl())}static createTable(e,t){return Qa(ol.getTemplate(e,t))}static createWorkbookRels(e){const t=new Array(e).fill(void 0).map((e,t)=>({Id:`rId${t+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",Target:`worksheets/sheet${t+1}.xml`})),i=dc([...t,{Id:`rId${e+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",Target:"theme/theme1.xml"},{Id:`rId${e+2}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",Target:"styles.xml"},{Id:`rId${e+3}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",Target:"sharedStrings.xml"}]);return Qa(i)}static createDrawing(e){return Qa(sl.getTemplate({sheetIndex:e}))}static createDrawingRel(e){const t=this.worksheetImageIds.get(e)||[],i=[];for(const[e,r]of t)i.push({Id:`rId${r.index+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/image${this.workbookImageIds.get(e).index+1}.${r.type}`});return Qa(dc(i))}static createVmlDrawing(e){return Qa(vc.getTemplate({sheetIndex:e}),!0)}static createVmlDrawingRel(e){const t=this.worksheetHeaderFooterImages.get(e)||[],i=[];for(let e=0;e<t.length;e++){const r=t[e],n=this.workbookImageIds.get(r.id);if(!n)continue;const{index:s,type:o}=n,a="jpg"===o?"jpeg":o;i.push({Id:`rId${e+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/image${s+1}.${a}`})}return Qa(dc(i))}static createRelationships({drawingIndex:e,vmlDrawingIndex:t,tableIndex:i}={}){if(void 0===e&&void 0===t&&void 0===i)return"";const r=[];null!=e&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",Target:`../drawings/drawing${e+1}.xml`}),null!=t&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",Target:`../drawings/vmlDrawing${t+1}.vml`}),null!=i&&r.push({Id:`rId${r.length+1}`,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table",Target:`../tables/${this.getTableNameFromIndex(i)}.xml`});const n=dc(r);return Qa(n)}static createWorksheet(e,t){return Qa(uc.getTemplate({worksheet:e,currentSheet:this.sheetNames.length-1,config:t}))}};Cc.sharedStrings=new Map,Cc.sheetNames=[],Cc.images=new Map,Cc.worksheetImages=new Map,Cc.worksheetHeaderFooterImages=new Map,Cc.workbookImageIds=new Map,Cc.worksheetImageIds=new Map,Cc.worksheetDataTables=new Map,Cc.defaultTableDisplayName="AG-GRID-TABLE",Cc.factoryMode=r.FiP.SINGLE_SHEET;var yc=Cc,wc=class extends r.NF5{constructor(e){super(e),this.mixedStyles={},this.mixedStyleCounter=0,this.rows=[],this.config=Object.assign({},e),this.stylesByIds={},this.config.baseExcelStyles.forEach(e=>{this.stylesByIds[e.id]=e}),this.excelStyles=[...this.config.baseExcelStyles,{id:"_quotePrefix",quotePrefix:1}]}addCustomContent(e){e.forEach(e=>{const t=this.rows.length+1;let i;this.config.suppressRowOutline||null==e.outlineLevel||(i=e.outlineLevel);const r={height:Ya(t,e.height||this.config.rowHeight),cells:(e.cells||[]).map((e,i)=>{var r,n,s;const o=this.addImage(t,this.columnsToExport[i],null==(r=e.data)?void 0:r.value);let a=null;e.styleId&&(a="string"==typeof e.styleId?[e.styleId]:e.styleId);const l=this.getStyleId(a);if(o)return this.createCell(l,this.getDataTypeForValue(o.value),null==o.value?"":o.value);const c=null!=(s=null==(n=e.data)?void 0:n.value)?s:"",u=this.getDataTypeForValue(c);return e.mergeAcross?this.createMergedCell(l,u,c,e.mergeAcross):this.createCell(l,u,c)}),outlineLevel:i};null!=e.collapsed&&(r.collapsed=e.collapsed),null!=e.hidden&&(r.hidden=e.hidden),this.rows.push(r)})}onNewHeaderGroupingRow(){const e=[];return this.rows.push({cells:e,height:Ya(this.rows.length+1,this.config.headerRowHeight)}),{onColumn:(t,i,n,s,o)=>{const a=this.config.styleLinker({rowType:r.T6X.HEADER_GROUPING,rowIndex:1,value:`grouping-${i}`,columnGroup:t});e.push(Ba(Ha({},this.createMergedCell(this.getStyleId(a),this.getDataTypeForValue("string"),i,s)),{collapsibleRanges:o}))}}}onNewHeaderRow(){return this.onNewRow(this.onNewHeaderColumn,this.config.headerRowHeight)}onNewBodyRow(e){const t=this.onNewRow(this.onNewBodyColumn,this.config.rowHeight);return e&&this.addRowOutlineIfNecessary(e),t}prepare(e){super.prepare(e),this.columnsToExport=[...e],this.cols=e.map((e,t)=>this.convertColumnToExcel(e,t))}parse(){const e=this.rows.reduce((e,t)=>Math.max(e,t.cells.length),0);for(;this.cols.length<e;)this.cols.push(this.convertColumnToExcel(null,this.cols.length+1));const t={name:this.config.sheetName,table:{columns:this.cols,rows:this.rows}};return this.createExcel(t)}addRowOutlineIfNecessary(e){const{gos:t,suppressRowOutline:i,rowGroupExpandState:n="expanded"}=this.config;if(t.get("groupHideOpenParents")||i||null==e.level)return;const s=e.footer?1:0,o=r._.last(this.rows);if(o.outlineLevel=e.level+s,"expanded"===n)return;const a="collapsed"===n;if(e.isExpandable()){const t=!a&&e.expanded;o.collapsed=!t}o.hidden=!!e.parent&&-1!==e.parent.level&&(a||this.isAnyParentCollapsed(e.parent))}isAnyParentCollapsed(e){for(;e&&-1!==e.level;){if(!e.expanded)return!0;e=e.parent}return!1}convertColumnToExcel(e,t){const i=this.config.columnWidth,r=e?this.extractHeaderValue(e):void 0,n=null!=r?r:"",s=!!e&&e.isFilterAllowed();if(i)return"number"==typeof i?{width:i,displayName:n,filterAllowed:s}:{width:i({column:e,index:t}),displayName:n,filterAllowed:s};if(e){const t=75;return{width:Math.max(e.getActualWidth(),t),displayName:n,filterAllowed:s}}return{displayName:n,filterAllowed:s}}onNewHeaderColumn(e,t){return i=>{const n=this.extractHeaderValue(i),s=this.config.styleLinker({rowType:r.T6X.HEADER,rowIndex:e,value:n,column:i});t.push(this.createCell(this.getStyleId(s),this.getDataTypeForValue("string"),n))}}onNewBodyColumn(e,t){let i=0;return(n,s,o)=>{if(i>0)return void(i-=1);const{value:a,valueFormatted:l}=this.extractRowCellValue(n,s,e,"excel",o),c=this.config.styleLinker({rowType:r.T6X.BODY,rowIndex:e,value:a,column:n,node:o}),u=this.getStyleId(c),h=n.getColSpan(o),d=this.addImage(e,n,a);d?t.push(this.createCell(u,this.getDataTypeForValue(d.value),null==d.value?"":d.value)):h>1?(i=h-1,t.push(this.createMergedCell(u,this.getDataTypeForValue(a),a,h-1))):t.push(this.createCell(u,this.getDataTypeForValue(a),a,l))}}onNewRow(e,t){const i=[];return this.rows.push({cells:i,height:Ya(this.rows.length+1,t)}),{onColumn:e.bind(this,this.rows.length,i)()}}createExcel(e){const{excelStyles:t,config:i}=this;return yc.createExcel(t,e,i)}getDataTypeForValue(e){return void 0===e?"empty":this.isNumerical(e)?"n":"s"}getTypeFromStyle(e,t){if(this.isFormula(t))return"f";if(e&&e.dataType)switch(e.dataType.toLocaleLowerCase()){case"formula":return"f";case"string":return"s";case"number":return"n";case"datetime":return"d";case"error":return"e";case"boolean":return"b";default:console.warn(`AG Grid: Unrecognized data type for excel export [${e.id}.dataType=${e.dataType}]`)}return null}addImage(e,t,i){if(!this.config.addImageToCell)return;const r=this.config.addImageToCell(e,t,i);return r?(yc.addBodyImageToMap(r.image,e,t,this.columnsToExport,this.config.rowHeight),r):void 0}createCell(e,t,i,r){const n=this.getStyleById(e);!(null==n?void 0:n.dataType)&&"s"===t&&r&&(i=r);const s=this.getTypeFromStyle(n,i)||t,{value:o,escaped:a}=this.getCellValue(s,i),l=[];return n&&l.push(e),a&&l.push("_quotePrefix"),{styleId:e=this.getStyleId(l)||void 0,data:{type:s,value:o}}}createMergedCell(e,t,i,r){const n=null==i?"":i;return{styleId:this.getStyleById(e)?e:void 0,data:{type:t,value:"s"===t?yc.getStringPosition(n).toString():i},mergeAcross:r}}getCellValue(e,t){let i=!1;if(null==t&&(e="s",t=""),"s"===e)t&&"'"===t[0]&&(i=!0,t=t.slice(1)),t=yc.getStringPosition(t).toString();else if("f"===e)t=t.slice(1);else if("n"===e){const e=Number(t);isNaN(e)?t="":""!==t&&(t=e.toString())}return{value:t,escaped:i}}getStyleId(e){if(!e||!e.length)return null;if(1===e.length)return e[0];const t=e.join("-");return this.mixedStyles[t]||this.addNewMixedStyle(e),this.mixedStyles[t].excelID}deepCloneObject(e){return JSON.parse(JSON.stringify(e))}addNewMixedStyle(e){this.mixedStyleCounter+=1;const t=`mixedStyle${this.mixedStyleCounter}`,i={};for(const t of e)for(const e of this.excelStyles)e.id===t&&r._.mergeDeep(i,this.deepCloneObject(e));i.id=t,i.name=t;const n=e.join("-");this.mixedStyles[n]={excelID:t,key:n,result:i},this.excelStyles.push(i),this.stylesByIds[t]=i}isFormula(e){return null!=e&&this.config.autoConvertFormulas&&e.toString().startsWith("=")}isNumerical(e){return"bigint"==typeof e||isFinite(e)&&""!==e&&!isNaN(parseFloat(e))}getStyleById(e){return null==e?null:this.stylesByIds[e]||null}},Sc=(e,t)=>{const i="xl/drawings",n=`${i}/drawing${t+1}.xml`,s=`${i}/_rels/drawing${t+1}.xml.rels`;r.J1w.addFile(s,yc.createDrawingRel(e)),r.J1w.addFile(n,yc.createDrawing(e))},bc=(e,t)=>{const i="xl/drawings",n=`${i}/vmlDrawing${t+1}.vml`,s=`${i}/_rels/vmlDrawing${t+1}.vml.rels`;r.J1w.addFile(n,yc.createVmlDrawing(e)),r.J1w.addFile(s,yc.createVmlDrawingRel(e))},Ec=(e,t={})=>{if(!e||0===e.length)return console.warn("AG Grid: Invalid params supplied to createExcelFileForExcel() - `ExcelExportParams.data` is empty."),yc.resetFactory(),!1;const{fontSize:i=11,author:n="AG Grid"}=t;return(()=>{r.J1w.addFolders(["_rels/","docProps/","xl/","xl/theme/","xl/_rels/","xl/worksheets/"]);const{images:e}=yc;if(!e.size)return;r.J1w.addFolders(["xl/worksheets/_rels","xl/drawings/","xl/drawings/_rels","xl/media/"]);let t=0;e.forEach(e=>{const i=e[0].image[0],{base64:n,imageType:s}=i,o="jpg"===s?"jpeg":s;r.J1w.addFile(`xl/media/image${++t}.${o}`,n,!0)})})(),(()=>{const{worksheetDataTables:e}=yc,t=e,i=Array.from(t.keys());for(let e=0;e<i.length;e++){const n=i[e],s=t.get(n);s&&r.J1w.addFile(`xl/tables/${s.name}.xml`,yc.createTable(s,e))}})(),(e=>{let t=0,i=0,n=0;const{images:s,worksheetDataTables:o,worksheetImages:a,worksheetHeaderFooterImages:l}=yc;for(let c=0;c<e.length;c++){const u=e[c];r.J1w.addFile(`xl/worksheets/sheet${c+1}.xml`,u,!1);const h=s.size>0&&a.has(c),d=o.size>0&&o.has(c),p=s.size&&l.has(c);if(!h&&!d&&!p)continue;let g,f,m;h&&(Sc(c,t),f=t,t++),p&&(bc(c,i),m=i,i++),d&&(g=n++);const v=`xl/worksheets/_rels/sheet${c+1}.xml.rels`;r.J1w.addFile(v,yc.createRelationships({tableIndex:g,drawingIndex:f,vmlDrawingIndex:m}))}})(e),((e,t,i)=>{r.J1w.addFile("xl/workbook.xml",yc.createWorkbook()),r.J1w.addFile("xl/styles.xml",yc.createStylesheet(e)),r.J1w.addFile("xl/sharedStrings.xml",yc.createSharedStrings()),r.J1w.addFile("xl/theme/theme1.xml",yc.createTheme()),r.J1w.addFile("xl/_rels/workbook.xml.rels",yc.createWorkbookRels(i)),r.J1w.addFile("docProps/core.xml",yc.createCore(t)),r.J1w.addFile("[Content_Types].xml",yc.createContentTypes(i)),r.J1w.addFile("_rels/.rels",yc.createRels())})(i,n,e.length),yc.resetFactory(),!0},Ac=e=>{const{data:t,fontSize:i,author:n}=e,s=e.mimeType||"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";return Ec(t,{author:n,fontSize:i})?r.J1w.getZipFile(s):Promise.resolve(void 0)},Tc=e=>{const{data:t,fontSize:i,author:n}=e,s=e.mimeType||"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";if(Ec(t,{author:n,fontSize:i}))return r.J1w.getUncompressedZipFile(s)},Mc=e=>{const{fileName:t="export.xlsx"}=e;Ac(e).then(e=>{if(e){const i="function"==typeof t?t():t;r._7R.download(i,e)}})},Rc=class extends r.YzF{postConstruct(){this.setBeans({gridSerializer:this.gridSerializer,gos:this.gos})}getMergedParams(e){const t=this.gos.get("defaultExcelExportParams");return Object.assign({},t,e)}export(e){if(this.isExportSuppressed())return void console.warn("AG Grid: Export cancelled. Export is not allowed as per your configuration.");const t=this.getMergedParams(e),i={data:[this.getData(t)],fontSize:t.fontSize,author:t.author,mimeType:t.mimeType};this.packageCompressedFile(i).then(e=>{if(e){const{fileName:i}=t,n="function"==typeof i?i(this.gos.getGridCommonParams()):i;r._7R.download(this.getFileName(n),e)}})}exportDataAsExcel(e){this.export(e)}getDataAsExcel(e){const t=this.getMergedParams(e),i={data:[this.getData(t)],fontSize:t.fontSize,author:t.author,mimeType:t.mimeType};return this.packageFile(i)}setFactoryMode(e){yc.factoryMode=e}getFactoryMode(){return yc.factoryMode}getSheetDataForExcel(e){const t=this.getMergedParams(e);return this.getData(t)}getMultipleSheetsAsExcel(e){return Tc(e)}exportMultipleSheetsAsExcel(e){Mc(e)}getDefaultFileExtension(){return"xlsx"}createSerializingSession(e){const{columnModel:t,valueService:i,gos:r}=this;let n;if(null!=e.sheetName){const{sheetName:t}=e,i="function"==typeof t?t(this.gos.getGridCommonParams()):t;n=String(i).substring(0,31)}else n="ag-grid";const s=Ba(Ha({},e),{sheetName:n,columnModel:t,valueService:i,gos:r,suppressRowOutline:e.suppressRowOutline||e.skipRowGroups,headerRowHeight:e.headerRowHeight||e.rowHeight,baseExcelStyles:this.gos.get("excelStyles")||[],styleLinker:this.styleLinker.bind(this)});return new wc(s)}styleLinker(e){const{rowType:t,rowIndex:i,value:n,column:s,columnGroup:o,node:a}=e,l=t===r.T6X.HEADER,c=t===r.T6X.HEADER_GROUPING,u=l?s:o;let h=[];if(l||c)return h.push("header"),c&&h.push("headerGroup"),u&&(h=h.concat(r.PC7.getHeaderClassesFromColDef(u.getDefinition(),this.gos,s||null,o||null))),h;const d=this.gos.get("excelStyles"),p=["cell"];if(!d||!d.length)return p;const g=d.map(e=>e.id);return this.stylingService.processAllCellClasses(s.getDefinition(),this.gos.addGridCommonParams({value:n,data:a.data,node:a,colDef:s.getDefinition(),column:s,rowIndex:i}),e=>{g.indexOf(e)>-1&&p.push(e)}),p.sort((e,t)=>g.indexOf(e)<g.indexOf(t)?-1:1)}isExportSuppressed(){return this.gos.get("suppressExcelExport")}packageCompressedFile(e){return Ac(e)}packageFile(e){return Tc(e)}};za([(0,r.dsm)("columnModel")],Rc.prototype,"columnModel",2),za([(0,r.dsm)("valueService")],Rc.prototype,"valueService",2),za([(0,r.dsm)("stylingService")],Rc.prototype,"stylingService",2),za([(0,r.dsm)("gridSerializer")],Rc.prototype,"gridSerializer",2),za([(0,r.dsm)("gridOptionsService")],Rc.prototype,"gos",2),za([r.o7C],Rc.prototype,"postConstruct",1),Rc=za([(0,r.dR4)("excelCreator")],Rc);var _c={version:"31.3.4",moduleName:r.zsj.ExcelExportModule,beans:[Rc,r.pK6,r.HvL],dependantModules:[r.n76,S]},Pc=Object.defineProperty,xc=Object.getOwnPropertyDescriptor,Dc=Object.getOwnPropertySymbols,Ic=Object.prototype.hasOwnProperty,Lc=Object.prototype.propertyIsEnumerable,Nc=(e,t,i)=>t in e?Pc(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Oc=(e,t)=>{for(var i in t||(t={}))Ic.call(t,i)&&Nc(e,i,t[i]);if(Dc)for(var i of Dc(t))Lc.call(t,i)&&Nc(e,i,t[i]);return e},Fc=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?xc(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Pc(t,i,s),s},kc=class extends r.uAl{preConstruct(){this.setTemplate('<div class="ag-filter-toolpanel-search" role="presentation">\n                <div ref="eExpand" class="ag-filter-toolpanel-expand"></div>\n                <ag-input-text-field ref="eFilterTextField" class="ag-filter-toolpanel-search-input"></ag-input-text-field>\n            </div>')}postConstruct(){const e=this.localeService.getLocaleTextFunc();this.eFilterTextField.setAutoComplete(!1).setInputAriaLabel(e("ariaFilterColumnsInput","Filter Columns Input")).onValueChange(this.onSearchTextChanged.bind(this)),this.createExpandIcons(),this.setExpandState(0),this.addManagedListener(this.eExpand,"click",this.onExpandClicked.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.showOrHideOptions.bind(this))}init(e){this.params=e,this.columnModel.isReady()&&this.showOrHideOptions()}createExpandIcons(){this.eExpand.appendChild(this.eExpandChecked=r._.createIconNoSpan("columnSelectOpen",this.gos)),this.eExpand.appendChild(this.eExpandUnchecked=r._.createIconNoSpan("columnSelectClosed",this.gos)),this.eExpand.appendChild(this.eExpandIndeterminate=r._.createIconNoSpan("columnSelectIndeterminate",this.gos))}showOrHideOptions(){const e=!this.params.suppressFilterSearch,t=!this.params.suppressExpandAll,i=this.localeService.getLocaleTextFunc();this.eFilterTextField.setInputPlaceholder(i("searchOoo","Search..."));const n=this.columnModel.getAllGridColumns().some(e=>e.getOriginalParent()&&e.isFilterAllowed());r._.setDisplayed(this.eFilterTextField.getGui(),e),r._.setDisplayed(this.eExpand,t&&n)}onSearchTextChanged(){this.onSearchTextChangedDebounced||(this.onSearchTextChangedDebounced=r._.debounce(()=>{this.dispatchEvent({type:"searchChanged",searchText:this.eFilterTextField.getValue()})},300)),this.onSearchTextChangedDebounced()}onExpandClicked(){const e=0===this.currentExpandState?{type:"collapseAll"}:{type:"expandAll"};this.dispatchEvent(e)}setExpandState(e){this.currentExpandState=e,r._.setDisplayed(this.eExpandChecked,0===this.currentExpandState),r._.setDisplayed(this.eExpandUnchecked,1===this.currentExpandState),r._.setDisplayed(this.eExpandIndeterminate,2===this.currentExpandState)}};Fc([(0,r.dsm)("columnModel")],kc.prototype,"columnModel",2),Fc([(0,r.PIB)("eExpand")],kc.prototype,"eExpand",2),Fc([(0,r.PIB)("eFilterTextField")],kc.prototype,"eFilterTextField",2),Fc([r.fK3],kc.prototype,"preConstruct",1),Fc([r.o7C],kc.prototype,"postConstruct",1);var Gc=class e extends r.uAl{constructor(t,i){super(e.TEMPLATE),this.expandedCallback=i,this.expanded=!1,this.hideHeader=t}postConstruct(){this.eExpandChecked=r._.createIconNoSpan("columnSelectOpen",this.gos),this.eExpandUnchecked=r._.createIconNoSpan("columnSelectClosed",this.gos),this.eExpand.appendChild(this.eExpandChecked),this.eExpand.appendChild(this.eExpandUnchecked)}setColumn(e){this.column=e,this.eFilterName.innerText=this.columnModel.getDisplayNameForColumn(this.column,"filterToolPanel",!1)||"",this.addManagedListener(this.eFilterToolPanelHeader,"click",this.toggleExpanded.bind(this)),this.addManagedListener(this.eFilterToolPanelHeader,"keydown",this.onKeyDown.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_FILTER_OPENED,this.onFilterOpened.bind(this)),this.addInIcon("filter",this.eFilterIcon,this.column),r._.setDisplayed(this.eFilterIcon,this.isFilterActive(),{skipAriaHidden:!0}),r._.setDisplayed(this.eExpandChecked,!1),this.hideHeader?(r._.setDisplayed(this.eFilterToolPanelHeader,!1),this.eFilterToolPanelHeader.removeAttribute("tabindex")):this.eFilterToolPanelHeader.setAttribute("tabindex","0"),this.addManagedListener(this.column,r.VPZ.EVENT_FILTER_CHANGED,this.onFilterChanged.bind(this))}onKeyDown(e){const{key:t}=e,{ENTER:i,SPACE:n,LEFT:s,RIGHT:o}=r.DDm;t!==i&&t!==n&&t!==s&&t!==o||(e.preventDefault(),t===i||t===n?this.toggleExpanded():t===r.DDm.LEFT?this.collapse():this.expand())}getColumn(){return this.column}getColumnFilterName(){return this.columnModel.getDisplayNameForColumn(this.column,"filterToolPanel",!1)}addCssClassToTitleBar(e){this.eFilterToolPanelHeader.classList.add(e)}addInIcon(e,t,i){if(null==t)return;const n=r._.createIconNoSpan(e,this.gos,i);t.appendChild(n)}isFilterActive(){return this.filterManager.isFilterActive(this.column)}onFilterChanged(){r._.setDisplayed(this.eFilterIcon,this.isFilterActive(),{skipAriaHidden:!0}),this.dispatchEvent({type:r.VPZ.EVENT_FILTER_CHANGED})}toggleExpanded(){this.expanded?this.collapse():this.expand()}expand(){this.expanded||(this.expanded=!0,r._.setAriaExpanded(this.eFilterToolPanelHeader,!0),r._.setDisplayed(this.eExpandChecked,!0),r._.setDisplayed(this.eExpandUnchecked,!1),this.addFilterElement(),this.expandedCallback())}addFilterElement(e){var t;const i=r._.loadTemplate('<div class="ag-filter-toolpanel-instance-filter"></div>'),n=this.createManagedBean(new r.jfj(this.column,"TOOLBAR"));this.filterWrapperComp=n,n.hasFilter()&&(null==(t=n.getFilter())||t.then(t=>{this.underlyingFilter=t,t&&(i.appendChild(n.getGui()),this.agFilterToolPanelBody.appendChild(i),n.afterGuiAttached({container:"toolPanel",suppressFocus:e}))}))}collapse(){var e;this.expanded&&(this.expanded=!1,r._.setAriaExpanded(this.eFilterToolPanelHeader,!1),this.removeFilterElement(),r._.setDisplayed(this.eExpandChecked,!1),r._.setDisplayed(this.eExpandUnchecked,!0),null==(e=this.filterWrapperComp)||e.afterGuiDetached(),this.destroyBean(this.filterWrapperComp),this.expandedCallback())}removeFilterElement(){r._.clearElement(this.agFilterToolPanelBody)}isExpanded(){return this.expanded}refreshFilter(e){var t;if(!this.expanded)return;const i=this.underlyingFilter;i&&(e?"function"==typeof i.refreshVirtualList&&i.refreshVirtualList():null==(t=i.afterGuiDetached)||t.call(i))}onFilterOpened(e){"COLUMN_MENU"===e.source&&e.column===this.column&&this.expanded&&this.collapse()}};Gc.TEMPLATE='\n        <div class="ag-filter-toolpanel-instance">\n            <div class="ag-filter-toolpanel-header ag-filter-toolpanel-instance-header" ref="eFilterToolPanelHeader" role="button" aria-expanded="false">\n                <div ref="eExpand" class="ag-filter-toolpanel-expand"></div>\n                <span ref="eFilterName" class="ag-header-cell-text"></span>\n                <span ref="eFilterIcon" class="ag-header-icon ag-filter-icon ag-filter-toolpanel-instance-header-icon" aria-hidden="true"></span>\n            </div>\n            <div class="ag-filter-toolpanel-instance-body ag-filter" ref="agFilterToolPanelBody"></div>\n        </div>',Fc([(0,r.PIB)("eFilterToolPanelHeader")],Gc.prototype,"eFilterToolPanelHeader",2),Fc([(0,r.PIB)("eFilterName")],Gc.prototype,"eFilterName",2),Fc([(0,r.PIB)("agFilterToolPanelBody")],Gc.prototype,"agFilterToolPanelBody",2),Fc([(0,r.PIB)("eFilterIcon")],Gc.prototype,"eFilterIcon",2),Fc([(0,r.PIB)("eExpand")],Gc.prototype,"eExpand",2),Fc([(0,r.dsm)("filterManager")],Gc.prototype,"filterManager",2),Fc([(0,r.dsm)("columnModel")],Gc.prototype,"columnModel",2),Fc([r.o7C],Gc.prototype,"postConstruct",1);var Vc=Gc,Hc=class e extends r.uAl{constructor(e,t,i,r,n){super(),this.columnGroup=e,this.childFilterComps=t,this.depth=r,this.expandedCallback=i,this.showingColumn=n}preConstruct(){this.setTemplate(e.TEMPLATE,{filterGroupComp:{cssIdentifier:"filter-toolpanel",direction:"vertical"}})}init(){this.setGroupTitle(),this.filterGroupComp.setAlignItems("stretch"),this.filterGroupComp.addCssClass(`ag-filter-toolpanel-group-level-${this.depth}`),this.filterGroupComp.addCssClassToTitleBar(`ag-filter-toolpanel-group-level-${this.depth}-header`),this.childFilterComps.forEach(e=>{this.filterGroupComp.addItem(e),e.addCssClassToTitleBar(`ag-filter-toolpanel-group-level-${this.depth+1}-header`)}),this.refreshFilterClass(),this.addExpandCollapseListeners(),this.addFilterChangedListeners(),this.setupTooltip(),this.addInIcon("filter")}setupTooltip(){if(!this.showingColumn)return;let e;"whenTruncated"===this.gos.get("tooltipShowMode")&&(e=()=>{const e=this.filterGroupComp.getGui().querySelector(".ag-group-title");return!e||e.scrollWidth>e.clientWidth});const t=()=>{const t=this.columnGroup.getColDef().headerTooltip;this.setTooltip({newTooltipText:t,location:"filterToolPanelColumnGroup",shouldDisplayTooltip:e})};t(),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,t)}getTooltipParams(){const e=super.getTooltipParams();return e.location="filterToolPanelColumnGroup",e}addCssClassToTitleBar(e){this.filterGroupComp.addCssClassToTitleBar(e)}refreshFilters(t){this.childFilterComps.forEach(i=>{i instanceof e?i.refreshFilters(t):i.refreshFilter(t)})}isColumnGroup(){return this.columnGroup instanceof r.D45}isExpanded(){return this.filterGroupComp.isExpanded()}getChildren(){return this.childFilterComps}getFilterGroupName(){return this.filterGroupName?this.filterGroupName:""}getFilterGroupId(){return this.columnGroup.getId()}hideGroupItem(e,t){this.filterGroupComp.hideItem(e,t)}hideGroup(e){this.setDisplayed(!e)}addInIcon(e){const t=r._.createIconNoSpan(e,this.gos);t&&t.classList.add("ag-filter-toolpanel-group-instance-header-icon"),this.filterGroupComp.addTitleBarWidget(t)}forEachToolPanelFilterChild(e){this.childFilterComps.forEach(t=>{t instanceof Vc&&e(t)})}addExpandCollapseListeners(){const e=this.isColumnGroup()?()=>this.expandedCallback():()=>this.forEachToolPanelFilterChild(e=>e.expand()),t=this.isColumnGroup()?()=>this.expandedCallback():()=>this.forEachToolPanelFilterChild(e=>e.collapse());this.addManagedListener(this.filterGroupComp,r.Pk_.EVENT_EXPANDED,e),this.addManagedListener(this.filterGroupComp,r.Pk_.EVENT_COLLAPSED,t)}getColumns(){return this.columnGroup instanceof r.D45?this.columnGroup.getLeafColumns():[this.columnGroup]}addFilterChangedListeners(){this.getColumns().forEach(e=>{this.addManagedListener(e,r.VPZ.EVENT_FILTER_CHANGED,()=>this.refreshFilterClass())}),this.columnGroup instanceof r.D45||this.addManagedListener(this.eventService,r.sVA.EVENT_FILTER_OPENED,this.onFilterOpened.bind(this))}refreshFilterClass(){const e=this.getColumns();this.filterGroupComp.addOrRemoveCssClass("ag-has-filter",e.some(e=>e.isFilterActive()))}onFilterOpened(e){"COLUMN_MENU"===e.source&&e.column===this.columnGroup&&this.isExpanded()&&this.collapse()}expand(){this.filterGroupComp.toggleGroupExpand(!0)}collapse(){this.filterGroupComp.toggleGroupExpand(!1)}setGroupTitle(){this.filterGroupName=this.columnGroup instanceof r.D45?this.getColumnGroupName(this.columnGroup):this.getColumnName(this.columnGroup),this.filterGroupComp.setTitle(this.filterGroupName||"")}getColumnGroupName(e){return this.columnModel.getDisplayNameForProvidedColumnGroup(null,e,"filterToolPanel")}getColumnName(e){return this.columnModel.getDisplayNameForColumn(e,"filterToolPanel",!1)}destroyFilters(){this.childFilterComps=this.destroyBeans(this.childFilterComps),r._.clearElement(this.getGui())}destroy(){this.destroyFilters(),super.destroy()}};Hc.TEMPLATE='<div class="ag-filter-toolpanel-group-wrapper">\n            <ag-group-component ref="filterGroupComp"></ag-group-component>\n        </div>',Fc([(0,r.PIB)("filterGroupComp")],Hc.prototype,"filterGroupComp",2),Fc([(0,r.dsm)("columnModel")],Hc.prototype,"columnModel",2),Fc([r.fK3],Hc.prototype,"preConstruct",1),Fc([r.o7C],Hc.prototype,"init",1);var Bc=Hc,zc=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.initialised=!1,this.hasLoadedInitialState=!1,this.isInitialState=!1,this.filterGroupComps=[],this.suppressOnColumnsChanged=!1,this.onColumnsChangedPending=!1}init(e){this.initialised=!0;const t=this.gos.addGridCommonParams({suppressExpandAll:!1,suppressFilterSearch:!1,suppressSyncLayoutWithGrid:!1});r._.mergeDeep(t,e),this.params=t,this.params.suppressSyncLayoutWithGrid||this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_MOVED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,()=>this.onColumnsChanged()),this.addManagedListener(this.eventService,r.sVA.EVENT_TOOL_PANEL_VISIBLE_CHANGED,e=>{"filters"===e.key&&this.refreshFilters(e.visible)}),this.addManagedListener(this.eventService,r.sVA.EVENT_DRAG_STARTED,()=>{this.suppressOnColumnsChanged=!0}),this.addManagedListener(this.eventService,r.sVA.EVENT_DRAG_STOPPED,()=>{this.suppressOnColumnsChanged=!1,this.onColumnsChangedPending&&(this.onColumnsChangedPending=!1,this.onColumnsChanged())}),this.columnModel.isReady()&&this.onColumnsChanged()}onColumnsChanged(){if(this.suppressOnColumnsChanged)return void(this.onColumnsChangedPending=!0);const e=this.columnModel.isPivotMode();this.params.suppressSyncLayoutWithGrid||e?this.buildTreeFromProvidedColumnDefs():this.syncFilterLayout(),this.refreshAriaLabel()}syncFilterLayout(){this.toolPanelColDefService.syncLayoutWithGrid(this.setFiltersLayout.bind(this)),this.refreshAriaLabel()}buildTreeFromProvidedColumnDefs(){const e=this.columnModel.getPrimaryColumnTree();this.recreateFilters(e)}setFiltersLayout(e){const t=this.toolPanelColDefService.createColumnTree(e);this.recreateFilters(t)}recreateFilters(e){const t=this.gos.getActiveDomElement();this.hasLoadedInitialState||(this.hasLoadedInitialState=!0,this.isInitialState=!!this.params.initialState);const i=this.getExpansionState();this.destroyFilters(),this.filterGroupComps=this.recursivelyAddComps(e,0,i);const n=this.filterGroupComps.length;n&&(this.filterGroupComps.forEach(e=>this.appendChild(e)),this.setFirstAndLastVisible(0,n-1)),r._.exists(this.searchFilterText)&&this.searchFilters(this.searchFilterText),this.fireExpandedEvent(),this.getGui().contains(t)&&t.focus(),this.isInitialState=!1,this.refreshAriaLabel()}recursivelyAddComps(e,t,i){return r._.flatten(e.map(e=>{if(e instanceof r.D45)return r._.flatten(this.recursivelyAddFilterGroupComps(e,t,i));const n=e;if(!this.shouldDisplayFilter(n))return[];const s=new Vc(0===t,()=>this.onFilterExpanded());if(this.createBean(s),s.setColumn(n),i.get(n.getId())&&s.expand(),t>0)return s;const o=this.createBean(new Bc(n,[s],this.onGroupExpanded.bind(this),t,!0));return o.addCssClassToTitleBar("ag-filter-toolpanel-header"),i.get(o.getFilterGroupId())||o.collapse(),o}))}refreshAriaLabel(){const e=this.localeService.getLocaleTextFunc(),t=e("ariaFilterPanelList","Filter List"),i=e("filters","Filters"),n=this.getGui().querySelectorAll(".ag-filter-toolpanel-group-item:not(.ag-filter-toolpanel-group-wrapper, .ag-hidden)").length;r._.setAriaLabel(this.getAriaElement(),`${t} ${n} ${i}`)}recursivelyAddFilterGroupComps(e,t,i){if(!this.filtersExistInChildren(e.getChildren()))return;const n=e.getColGroupDef();if(n&&n.suppressFiltersToolPanel)return[];const s=e.isPadding()?t:t+1,o=r._.flatten(this.recursivelyAddComps(e.getChildren(),s,i));if(e.isPadding())return o;const a=new Bc(e,o,this.onGroupExpanded.bind(this),t,!1);this.createBean(a),a.addCssClassToTitleBar("ag-filter-toolpanel-header");const l=i.get(a.getFilterGroupId());return(this.isInitialState&&!l||!1===l)&&a.collapse(),[a]}filtersExistInChildren(e){return e.some(e=>e instanceof r.D45?this.filtersExistInChildren(e.getChildren()):this.shouldDisplayFilter(e))}shouldDisplayFilter(e){const t=e.getColDef()&&e.getColDef().suppressFiltersToolPanel;return e.isFilterAllowed()&&!t}getExpansionState(){const e=new Map;if(this.isInitialState){const{expandedColIds:t,expandedGroupIds:i}=this.params.initialState;return t.forEach(t=>e.set(t,!0)),i.forEach(t=>e.set(t,!0)),e}const t=i=>{e.set(i.getFilterGroupId(),i.isExpanded()),i.getChildren().forEach(i=>{i instanceof Bc?t(i):e.set(i.getColumn().getId(),i.isExpanded())})};return this.filterGroupComps.forEach(t),e}refresh(){}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}expandFilterGroups(e,t){const i=[],n=s=>{const o=s.getFilterGroupId();(!t||r._.includes(t,o))&&(e&&s.isColumnGroup()?s.expand():s.collapse(),i.push(o)),s.getChildren().forEach(e=>{e instanceof Bc&&n(e)})};if(this.filterGroupComps.forEach(n),this.onGroupExpanded(),t){const e=t.filter(e=>i.indexOf(e)<0);e.length>0&&console.warn("AG Grid: unable to find groups for these supplied groupIds:",e)}}expandFilters(e,t){const i=[],n=s=>{if(s instanceof Bc){let t=!1;return s.getChildren().forEach(i=>{n(i)&&(e?(s.expand(),t=!0):s.isColumnGroup()||s.collapse())}),t}const o=s.getColumn().getColId(),a=!t||r._.includes(t,o);return a&&(e?s.expand():s.collapse(),i.push(o)),a};if(this.filterGroupComps.forEach(n),this.onGroupExpanded(),t){const e=t.filter(e=>i.indexOf(e)<0);e.length>0&&console.warn("AG Grid: unable to find columns for these supplied colIds:",e)}}onGroupExpanded(){this.fireExpandedEvent()}onFilterExpanded(){this.dispatchEvent({type:"filterExpanded"})}fireExpandedEvent(){let e=0,t=0;const i=r=>{r.isColumnGroup()&&(r.isExpanded()?e++:t++,r.getChildren().forEach(e=>{e instanceof Bc&&i(e)}))};let r;this.filterGroupComps.forEach(i),r=e>0&&t>0?2:t>0?1:0,this.dispatchEvent({type:"groupExpanded",state:r})}performFilterSearch(e){this.searchFilterText=r._.exists(e)?e.toLowerCase():null,this.searchFilters(this.searchFilterText)}searchFilters(e){const t=t=>!r._.exists(e)||-1!==t.toLowerCase().indexOf(e),i=(e,r)=>{if(!(e instanceof Bc))return t(e.getColumnFilterName()||"");const n=e.getChildren(),s=t(e.getFilterGroupName()),o=r||s;if(o){e.hideGroup(!1);for(let t=0;t<n.length;t++)i(n[t],o),e.hideGroupItem(!1,t);return!0}let a=!1;return n.forEach((t,n)=>{const s=i(t,r);e.hideGroupItem(!s,n),s&&(a=!0)}),e.hideGroup(!a),a};let n,s;this.filterGroupComps.forEach((e,t)=>{i(e,!1),void 0===n?e.containsCssClass("ag-hidden")||(n=t,s=t):e.containsCssClass("ag-hidden")||s===t||(s=t)}),this.setFirstAndLastVisible(n,s),this.refreshAriaLabel()}setFirstAndLastVisible(e,t){this.filterGroupComps.forEach((i,r)=>{i.removeCssClass("ag-first-group-visible"),i.removeCssClass("ag-last-group-visible"),r===e&&i.addCssClass("ag-first-group-visible"),r===t&&i.addCssClass("ag-last-group-visible")})}refreshFilters(e){this.filterGroupComps.forEach(t=>t.refreshFilters(e))}getExpandedFiltersAndGroups(){const e=[],t=new Set,i=r=>{if(r instanceof Bc){r.getChildren().forEach(e=>i(e));const n=r.getFilterGroupId();r.isExpanded()&&!t.has(n)&&e.push(n)}else r.isExpanded()&&t.add(r.getColumn().getColId())};return this.filterGroupComps.forEach(i),{expandedGroupIds:e,expandedColIds:Array.from(t)}}destroyFilters(){this.filterGroupComps=this.destroyBeans(this.filterGroupComps),r._.clearElement(this.getGui())}destroy(){this.destroyFilters(),super.destroy()}};zc.TEMPLATE='<div class="ag-filter-list-panel"></div>',Fc([(0,r.dsm)("toolPanelColDefService")],zc.prototype,"toolPanelColDefService",2),Fc([(0,r.dsm)("columnModel")],zc.prototype,"columnModel",2);var Uc=zc,Wc=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.initialised=!1,this.listenerDestroyFuncs=[]}init(e){this.initialised&&(this.listenerDestroyFuncs.forEach(e=>e()),this.listenerDestroyFuncs=[]),this.initialised=!0;const t=this.gos.addGridCommonParams({suppressExpandAll:!1,suppressFilterSearch:!1,suppressSyncLayoutWithGrid:!1});this.params=Oc(Oc({},t),e),this.filtersToolPanelHeaderPanel.init(this.params),this.filtersToolPanelListPanel.init(this.params);const i=this.params.suppressExpandAll,r=this.params.suppressFilterSearch;i&&r&&this.filtersToolPanelHeaderPanel.setDisplayed(!1),this.listenerDestroyFuncs.push(this.addManagedListener(this.filtersToolPanelHeaderPanel,"expandAll",this.onExpandAll.bind(this)),this.addManagedListener(this.filtersToolPanelHeaderPanel,"collapseAll",this.onCollapseAll.bind(this)),this.addManagedListener(this.filtersToolPanelHeaderPanel,"searchChanged",this.onSearchChanged.bind(this)),this.addManagedListener(this.filtersToolPanelListPanel,"filterExpanded",this.onFilterExpanded.bind(this)),this.addManagedListener(this.filtersToolPanelListPanel,"groupExpanded",this.onGroupExpanded.bind(this)))}setVisible(e){super.setDisplayed(e),e&&!this.initialised&&this.init(this.params)}onExpandAll(){this.filtersToolPanelListPanel.expandFilterGroups(!0)}onCollapseAll(){this.filtersToolPanelListPanel.expandFilterGroups(!1)}onSearchChanged(e){this.filtersToolPanelListPanel.performFilterSearch(e.searchText)}setFilterLayout(e){this.filtersToolPanelListPanel.setFiltersLayout(e)}onFilterExpanded(){this.params.onStateUpdated()}onGroupExpanded(e){this.filtersToolPanelHeaderPanel.setExpandState(e.state),this.params.onStateUpdated()}expandFilterGroups(e){this.filtersToolPanelListPanel.expandFilterGroups(!0,e)}collapseFilterGroups(e){this.filtersToolPanelListPanel.expandFilterGroups(!1,e)}expandFilters(e){this.filtersToolPanelListPanel.expandFilters(!0,e)}collapseFilters(e){this.filtersToolPanelListPanel.expandFilters(!1,e)}syncLayoutWithGrid(){this.filtersToolPanelListPanel.syncFilterLayout()}refresh(e){return this.init(e),!0}getState(){return this.filtersToolPanelListPanel.getExpandedFiltersAndGroups()}destroy(){super.destroy()}};Wc.TEMPLATE='<div class="ag-filter-toolpanel">\n            <ag-filters-tool-panel-header ref="filtersToolPanelHeaderPanel"></ag-filters-tool-panel-header>\n            <ag-filters-tool-panel-list ref="filtersToolPanelListPanel"></ag-filters-tool-panel-list>\n         </div>',Fc([(0,r.PIB)("filtersToolPanelHeaderPanel")],Wc.prototype,"filtersToolPanelHeaderPanel",2),Fc([(0,r.PIB)("filtersToolPanelListPanel")],Wc.prototype,"filtersToolPanelListPanel",2);var jc=Wc,Kc={version:"31.3.4",moduleName:r.zsj.FiltersToolPanelModule,beans:[],agStackComponents:[{componentName:"AgFiltersToolPanelHeader",componentClass:kc},{componentName:"AgFiltersToolPanelList",componentClass:Uc}],userComponents:[{componentName:"agFiltersToolPanel",componentClass:jc}],dependantModules:[qo,S]},$c=Object.defineProperty,qc=Object.getOwnPropertyDescriptor,Yc=Object.getOwnPropertySymbols,Qc=Object.prototype.hasOwnProperty,Xc=Object.prototype.propertyIsEnumerable,Zc=(e,t,i)=>t in e?$c(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Jc=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?qc(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&$c(t,i,s),s},eu=class extends r.XQb{constructor(){super(...arguments),this.loadRowDataVersion=0}init(e,t){this.params=t,this.comp=e,null!=t.pinned||(this.setAutoHeightClasses(),this.setupRefreshStrategy(),this.addThemeToDetailGrid(),this.createDetailGrid(),this.loadRowData(),this.addManagedListener(this.eventService,r.sVA.EVENT_FULL_WIDTH_ROW_FOCUSED,this.onFullWidthRowFocused.bind(this)))}onFullWidthRowFocused(e){const t=this.params,i={rowIndex:t.node.rowIndex,rowPinned:t.node.rowPinned},r={rowIndex:e.rowIndex,rowPinned:e.rowPinned};this.rowPositionUtils.sameRow(i,r)&&this.focusService.focusInto(this.comp.getGui(),e.fromBelow)}setAutoHeightClasses(){const e=this.gos.get("detailRowAutoHeight"),t=e?"ag-details-row-auto-height":"ag-details-row-fixed-height",i=e?"ag-details-grid-auto-height":"ag-details-grid-fixed-height";this.comp.addOrRemoveCssClass(t,!0),this.comp.addOrRemoveDetailGridCssClass(i,!0)}setupRefreshStrategy(){const e=this.params.refreshStrategy;"everything"==e||"nothing"==e||"rows"==e?this.refreshStrategy=e:(null!=e&&console.warn("AG Grid: invalid cellRendererParams.refreshStrategy = '"+e+"' supplied, defaulting to refreshStrategy = 'rows'."),this.refreshStrategy="rows")}addThemeToDetailGrid(){const{theme:e}=this.environment.getTheme();e&&this.comp.addOrRemoveDetailGridCssClass(e,!0)}createDetailGrid(){if(r._.missing(this.params.detailGridOptions))return void console.warn("AG Grid: could not find detail grid options for master detail, please set gridOptions.detailCellRendererParams.detailGridOptions");const e=this.gos.get("detailRowAutoHeight"),t=((e,t)=>{for(var i in t||(t={}))Qc.call(t,i)&&Zc(e,i,t[i]);if(Yc)for(var i of Yc(t))Xc.call(t,i)&&Zc(e,i,t[i]);return e})({},this.params.detailGridOptions);e&&(t.domLayout="autoHeight"),this.comp.setDetailGrid(t)}registerDetailWithMaster(e,t){const i=this.params.node.id,r=this.params.api,n={id:i,api:e,columnApi:t},s=this.params.node;r.isDestroyed()||(r.addDetailGridInfo(i,n),s.detailGridInfo=n,this.addDestroyFunc(()=>{s.detailGridInfo===n&&(r.isDestroyed()||r.removeDetailGridInfo(i),s.detailGridInfo=null)}))}loadRowData(){var e,t,i;this.loadRowDataVersion++;const r=this.loadRowDataVersion;if("serverSide"===(null==(e=this.params.detailGridOptions)?void 0:e.rowModelType))return void(null==(i=null==(t=this.params.node.detailGridInfo)?void 0:t.api)||i.refreshServerSide({purge:!0}));const n=this.params.getDetailRowData;n?n({node:this.params.node,data:this.params.node.data,successCallback:e=>{this.loadRowDataVersion===r&&this.comp.setRowData(e)},context:this.gos.getGridCommonParams().context}):console.warn("AG Grid: could not find getDetailRowData for master / detail, please set gridOptions.detailCellRendererParams.getDetailRowData")}refresh(){const e=!0;switch(this.refreshStrategy){case"nothing":return e;case"everything":return!1}return this.loadRowData(),e}};Jc([(0,r.dsm)("rowPositionUtils")],eu.prototype,"rowPositionUtils",2),Jc([(0,r.dsm)("focusService")],eu.prototype,"focusService",2);var tu=class e extends r.uAl{init(e){this.params=e,this.selectAndSetTemplate();const t={addOrRemoveCssClass:(e,t)=>this.addOrRemoveCssClass(e,t),addOrRemoveDetailGridCssClass:(e,t)=>this.eDetailGrid.classList.toggle(e,t),setDetailGrid:e=>this.setDetailGrid(e),setRowData:e=>this.setRowData(e),getGui:()=>this.eDetailGrid};this.ctrl=this.createManagedBean(new eu),this.ctrl.init(t,e)}refresh(){return this.ctrl&&this.ctrl.refresh()}destroy(){super.destroy()}selectAndSetTemplate(){if(this.params.pinned)return void this.setTemplate('<div class="ag-details-row"></div>');const t=()=>{this.setTemplate(e.TEMPLATE)};if(r._.missing(this.params.template))t();else if("string"==typeof this.params.template)this.setTemplate(this.params.template);else if("function"==typeof this.params.template){const e=(0,this.params.template)(this.params);this.setTemplate(e)}else console.warn("AG Grid: detailCellRendererParams.template should be function or string"),t();null==this.eDetailGrid&&console.warn('AG Grid: reference to eDetailGrid was missing from the details template. Please add ref="eDetailGrid" to the template.')}setDetailGrid(e){if(!this.eDetailGrid)return;const t=this.context.getBean("agGridReact"),i=t?r._.cloneObject(t):void 0,n=this.context.getBean("frameworkComponentWrapper"),s=this.getFrameworkOverrides(),o=(0,r.Dvw)(this.eDetailGrid,e,{frameworkOverrides:s,providedBeanInstances:{agGridReact:i,frameworkComponentWrapper:n},modules:r.syG.__getGridRegisteredModules(this.params.api.getGridId())});this.detailApi=o,this.ctrl.registerDetailWithMaster(o,new r.jf3(o)),this.addDestroyFunc(()=>{null==o||o.destroy()})}setRowData(e){this.detailApi&&this.detailApi.setGridOption("rowData",e)}};tu.TEMPLATE='<div class="ag-details-row" role="gridcell">\n            <div ref="eDetailGrid" class="ag-details-grid" role="presentation"></div>\n        </div>',Jc([(0,r.PIB)("eDetailGrid")],tu.prototype,"eDetailGrid",2);var iu=tu,ru={version:"31.3.4",moduleName:r.zsj.MasterDetailModule,beans:[],userComponents:[{componentName:"agDetailCellRenderer",componentClass:iu}],controllers:[{controllerName:"detailCellRenderer",controllerClass:eu}],dependantModules:[S]},nu=Object.defineProperty,su=Object.defineProperties,ou=Object.getOwnPropertyDescriptor,au=Object.getOwnPropertyDescriptors,lu=Object.getOwnPropertySymbols,cu=Object.prototype.hasOwnProperty,uu=Object.prototype.propertyIsEnumerable,hu=(e,t,i)=>t in e?nu(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,du=(e,t)=>{for(var i in t||(t={}))cu.call(t,i)&&hu(e,i,t[i]);if(lu)for(var i of lu(t))uu.call(t,i)&&hu(e,i,t[i]);return e},pu=(e,t)=>su(e,au(t)),gu=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?ou(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&nu(t,i,s),s},fu=class extends r.XQb{hideActiveMenu(){this.destroyBean(this.activeMenu)}showMenuAfterMouseEvent(e,t,i,r){const n=r?"filterMenuTab":void 0;this.showMenu(e,r=>{var s;const o=r.getGui();this.popupService.positionPopupUnderMouseEvent({type:i,column:e,mouseEvent:t,ePopup:o}),n&&(null==(s=r.showTab)||s.call(r,n)),this.dispatchVisibleChangedEvent(!0,!1,e,n)},i,n,void 0,t.target)}showMenuAfterButtonClick(e,t,i,r){let n=-1,s="left";this.gos.get("enableRtl")&&(n=1,s="right");const o=r?"filterMenuTab":void 0,a=o?[o]:void 0,l=this.menuService.isLegacyMenuEnabled();let c=(l?9:4)*n,u=l?-23:4;this.showMenu(e,r=>{var n;const a=r.getGui();this.popupService.positionPopupByComponent({type:i,column:e,eventSource:t,ePopup:a,alignSide:s,nudgeX:c,nudgeY:u,position:"under",keepWithinBounds:!0}),o&&(null==(n=r.showTab)||n.call(r,o)),this.dispatchVisibleChangedEvent(!0,!1,e,o)},i,o,a,t)}showMenu(e,t,i,n,s,o){var a;const{menu:l,eMenuGui:c,anchorToElement:u,restoreFocusParams:h}=this.getMenuParams(e,s,o),d=[];d.push(t=>{const i=l.getGui();this.destroyBean(l),e&&(e.setMenuVisible(!1,"contextMenu"),this.menuUtils.restoreFocusOnClose(h,i,t))});const p=this.localeService.getLocaleTextFunc();if(this.popupService.addPopup({modal:!0,eChild:c,closeOnEsc:!0,closedCallback:t=>{d.forEach(e=>e(t)),this.dispatchVisibleChangedEvent(!1,!1,e,n)},afterGuiAttached:e=>l.afterGuiAttached(Object.assign({},{container:i},e)),positionCallback:n?()=>t(l):void 0,ariaLabel:p("ariaLabelColumnMenu","Column Menu")}),n||(null==(a=l.showTabBasedOnPreviousSelection)||a.call(l),t(l)),this.menuService.isColumnMenuAnchoringEnabled()){const t=this.popupService.setPopupPositionRelatedToElement(c,u);t&&e&&this.addStopAnchoring(t,e,d)}l.addEventListener(vu.EVENT_TAB_SELECTED,t=>{this.dispatchVisibleChangedEvent(!1,!0,e),this.lastSelectedTab=t.key,this.dispatchVisibleChangedEvent(!0,!0,e)}),null==e||e.setMenuVisible(!0,"contextMenu"),this.activeMenu=l,l.addEventListener(r.XQb.EVENT_DESTROYED,()=>{this.activeMenu===l&&(this.activeMenu=null)})}addStopAnchoring(e,t,i){e.then(e=>{t.addEventListener("leftChanged",e),t.addEventListener("visibleChanged",e),i.push(()=>{t.removeEventListener("leftChanged",e),t.removeEventListener("visibleChanged",e)})})}getMenuParams(e,t,i){const r={column:e,headerPosition:this.focusService.getFocusedHeader(),columnIndex:this.columnModel.getAllDisplayedColumns().indexOf(e),eventSource:i},n=this.createMenu(e,r,t,i);return{menu:n,eMenuGui:n.getGui(),anchorToElement:i||this.ctrlsService.getGridBodyCtrl().getGui(),restoreFocusParams:r}}createMenu(e,t,i,r){return this.menuService.isLegacyMenuEnabled()?this.createBean(new vu(e,t,this.lastSelectedTab,i,r)):this.createBean(new Cu(e,t,r))}dispatchVisibleChangedEvent(e,t,i,n){var s,o;const a={type:r.sVA.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:t,key:null!=(o=null!=(s=this.lastSelectedTab)?s:n)?o:this.menuService.isLegacyMenuEnabled()?vu.TAB_GENERAL:"columnMenu",column:null!=i?i:null};this.eventService.dispatchEvent(a)}isMenuEnabled(e){var t;if(!this.menuService.isLegacyMenuEnabled())return!0;const i=!this.filterManager.isFilterAllowed(e),r=null!=(t=e.getColDef().menuTabs)?t:vu.TABS_DEFAULT;return(i&&r.includes(vu.TAB_FILTER)?r.length-1:r.length)>0}showMenuAfterContextMenuEvent(e,t,i){this.menuUtils.onContextMenu(t,i,t=>(this.showMenuAfterMouseEvent(e,t,"columnMenu"),!0))}};gu([(0,r.dsm)("popupService")],fu.prototype,"popupService",2),gu([(0,r.dsm)("focusService")],fu.prototype,"focusService",2),gu([(0,r.dsm)("ctrlsService")],fu.prototype,"ctrlsService",2),gu([(0,r.dsm)("columnModel")],fu.prototype,"columnModel",2),gu([(0,r.dsm)("filterManager")],fu.prototype,"filterManager",2),gu([(0,r.dsm)("menuUtils")],fu.prototype,"menuUtils",2),gu([(0,r.dsm)("menuService")],fu.prototype,"menuService",2),fu=gu([(0,r.dR4)("enterpriseMenuFactory")],fu);var mu=class e extends r.XQb{constructor(t,i,r,n,s){super(),this.column=t,this.restoreFocusParams=i,this.initialSelection=r,this.restrictTo=n,this.sourceElement=s,this.tabFactories={},this.includeChecks={},this.tabFactories[e.TAB_GENERAL]=this.createMainPanel.bind(this),this.tabFactories[e.TAB_FILTER]=this.createFilterPanel.bind(this),this.tabFactories[e.TAB_COLUMNS]=this.createColumnsPanel.bind(this),this.includeChecks[e.TAB_GENERAL]=()=>!0,this.includeChecks[e.TAB_FILTER]=()=>!!t&&this.filterManager.isFilterAllowed(t),this.includeChecks[e.TAB_COLUMNS]=()=>!0}init(){const e=this.getTabsToCreate().map(e=>this.createTab(e));this.tabbedLayout=new r.LfH({items:e,cssClass:"ag-menu",onActiveItemClicked:this.onHidePopup.bind(this),onItemClicked:this.onTabItemClicked.bind(this)}),this.createBean(this.tabbedLayout),this.mainMenuList&&this.mainMenuList.setParentComponent(this.tabbedLayout),this.addDestroyFunc(()=>this.destroyBean(this.tabbedLayout))}getTabsToCreate(){var t,i;return this.restrictTo?this.restrictTo:(null!=(i=null==(t=this.column)?void 0:t.getColDef().menuTabs)?i:e.TABS_DEFAULT).filter(e=>this.isValidMenuTabItem(e)).filter(e=>this.isNotSuppressed(e)).filter(e=>this.isModuleLoaded(e))}isModuleLoaded(t){return t!==e.TAB_COLUMNS||r.syG.__isRegistered(r.zsj.ColumnsToolPanelModule,this.context.getGridId())}isValidMenuTabItem(t){let i=!0,r=e.TABS_DEFAULT;return null!=this.restrictTo&&(i=this.restrictTo.indexOf(t)>-1,r=this.restrictTo),i=i&&e.TABS_DEFAULT.indexOf(t)>-1,i||console.warn(`AG Grid: Trying to render an invalid menu item '${t}'. Check that your 'menuTabs' contains one of [${r}]`),i}isNotSuppressed(e){return this.includeChecks[e]()}createTab(e){return this.tabFactories[e]()}showTabBasedOnPreviousSelection(){this.showTab(this.initialSelection)}showTab(t){this.tabItemColumns&&t===e.TAB_COLUMNS?this.tabbedLayout.showItem(this.tabItemColumns):this.tabItemFilter&&t===e.TAB_FILTER?this.tabbedLayout.showItem(this.tabItemFilter):this.tabItemGeneral&&t===e.TAB_GENERAL?this.tabbedLayout.showItem(this.tabItemGeneral):this.tabbedLayout.showFirstItem()}onTabItemClicked(t){let i=null;switch(t.item){case this.tabItemColumns:i=e.TAB_COLUMNS;break;case this.tabItemFilter:i=e.TAB_FILTER;break;case this.tabItemGeneral:i=e.TAB_GENERAL}i&&this.activateTab(i)}activateTab(t){const i={type:e.EVENT_TAB_SELECTED,key:t};this.dispatchEvent(i)}createMainPanel(){return this.mainMenuList=this.columnMenuFactory.createMenu(this,this.column,()=>{var e;return null!=(e=this.sourceElement)?e:this.getGui()}),this.mainMenuList.addEventListener(r.yuY.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.tabItemGeneral={title:r._.createIconNoSpan("menu",this.gos,this.column),titleLabel:e.TAB_GENERAL.replace("MenuTab",""),bodyPromise:r.oY$.resolve(this.mainMenuList.getGui()),name:e.TAB_GENERAL},this.tabItemGeneral}onHidePopup(e){this.menuUtils.closePopupAndRestoreFocusOnSelect(this.hidePopupFunc,this.restoreFocusParams,e)}createFilterPanel(){const t=this.column?this.createManagedBean(new r.jfj(this.column,"COLUMN_MENU")):null;if(!(null==t?void 0:t.hasFilter()))throw new Error("AG Grid - Unable to instantiate filter");return this.tabItemFilter={title:r._.createIconNoSpan("filter",this.gos,this.column),titleLabel:e.TAB_FILTER.replace("MenuTab",""),bodyPromise:r.oY$.resolve(null==t?void 0:t.getGui()),afterAttachedCallback:e=>t.afterGuiAttached(e),afterDetachedCallback:()=>t.afterGuiDetached(),name:e.TAB_FILTER},this.tabItemFilter}createColumnsPanel(){const t=document.createElement("div");t.classList.add("ag-menu-column-select-wrapper");const i=this.columnChooserFactory.createColumnSelectPanel(this,this.column).getGui();return i.classList.add("ag-menu-column-select"),t.appendChild(i),this.tabItemColumns={title:r._.createIconNoSpan("columns",this.gos,this.column),titleLabel:e.TAB_COLUMNS.replace("MenuTab",""),bodyPromise:r.oY$.resolve(t),name:e.TAB_COLUMNS},this.tabItemColumns}afterGuiAttached(e){const{container:t,hidePopup:i}=e;this.tabbedLayout.setAfterAttachedParams({container:t,hidePopup:i}),i&&(this.hidePopupFunc=i,this.addDestroyFunc(i))}getGui(){return this.tabbedLayout.getGui()}};mu.EVENT_TAB_SELECTED="tabSelected",mu.TAB_FILTER="filterMenuTab",mu.TAB_GENERAL="generalMenuTab",mu.TAB_COLUMNS="columnsMenuTab",mu.TABS_DEFAULT=[mu.TAB_GENERAL,mu.TAB_FILTER,mu.TAB_COLUMNS],gu([(0,r.dsm)("filterManager")],mu.prototype,"filterManager",2),gu([(0,r.dsm)("columnChooserFactory")],mu.prototype,"columnChooserFactory",2),gu([(0,r.dsm)("columnMenuFactory")],mu.prototype,"columnMenuFactory",2),gu([(0,r.dsm)("menuUtils")],mu.prototype,"menuUtils",2),gu([r.o7C],mu.prototype,"init",1);var vu=mu,Cu=class extends r.uAl{constructor(e,t,i){super('\n            <div ref="eColumnMenu" role="presentation" class="ag-menu ag-column-menu"></div>\n        '),this.column=e,this.restoreFocusParams=t,this.sourceElement=i}init(){this.mainMenuList=this.columnMenuFactory.createMenu(this,this.column,()=>{var e;return null!=(e=this.sourceElement)?e:this.getGui()}),this.mainMenuList.addEventListener(r.yuY.EVENT_CLOSE_MENU,this.onHidePopup.bind(this)),this.eColumnMenu.appendChild(this.mainMenuList.getGui())}onHidePopup(e){this.menuUtils.closePopupAndRestoreFocusOnSelect(this.hidePopupFunc,this.restoreFocusParams,e)}afterGuiAttached({hidePopup:e}){e&&(this.hidePopupFunc=e,this.addDestroyFunc(e)),this.focusService.focusInto(this.mainMenuList.getGui())}};gu([(0,r.dsm)("columnMenuFactory")],Cu.prototype,"columnMenuFactory",2),gu([(0,r.dsm)("menuUtils")],Cu.prototype,"menuUtils",2),gu([(0,r.dsm)("focusService")],Cu.prototype,"focusService",2),gu([(0,r.PIB)("eColumnMenu")],Cu.prototype,"eColumnMenu",2),gu([r.o7C],Cu.prototype,"init",1);var yu="ag-context-menu-open",wu=class extends r.XQb{hideActiveMenu(){this.destroyBean(this.activeMenu)}getMenuItems(e,t,i){const n=[];if(r._.exists(e)&&r.syG.__isRegistered(r.zsj.ClipboardModule,this.context.getGridId())&&t&&(this.gos.get("suppressCutToClipboard")||n.push("cut"),n.push("copy","copyWithHeaders","copyWithGroupHeaders","paste","separator")),this.gos.get("enableCharts")&&r.syG.__isRegistered(r.zsj.GridChartsModule,this.context.getGridId())&&(this.columnModel.isPivotMode()&&n.push("pivotChart"),this.rangeService&&!this.rangeService.isEmpty()&&n.push("chartRange")),r._.exists(e)){const e=!r.syG.__isRegistered(r.zsj.CsvExportModule,this.context.getGridId()),t=!r.syG.__isRegistered(r.zsj.ExcelExportModule,this.context.getGridId()),i=this.gos.get("suppressExcelExport")||t,s=this.gos.get("suppressCsvExport")||e;!(r._.isIOSUserAgent()||i&&s)&&n.push("export")}const s=n.length?n:void 0,o=null==t?void 0:t.getColDef().contextMenuItems;if(Array.isArray(o))return o;if("function"==typeof o)return o(this.gos.addGridCommonParams({column:t,node:e,value:i,defaultItems:s}));const a=this.gos.getCallback("getContextMenuItems");return a?a({column:t,node:e,value:i,defaultItems:s}):n}onContextMenu(e,t,i,r,n,s){this.menuUtils.onContextMenu(e,t,e=>this.showMenu(i,r,n,e,s))}showMenu(e,t,i,n,s){const o=this.getMenuItems(e,t,i),a=this.ctrlsService.getGridBodyCtrl().getGui();if(void 0===o||r._.missingOrEmpty(o))return!1;const l=new Su(o,t,e,i);this.createBean(l);const c=l.getGui(),u={column:t,rowNode:e,type:"contextMenu",mouseEvent:n,ePopup:c,nudgeY:1},h=this.localeService.getLocaleTextFunc(),d=this.popupService.addPopup({modal:!0,eChild:c,closeOnEsc:!0,closedCallback:e=>{a.classList.remove(yu),this.destroyBean(l),this.dispatchVisibleChangedEvent(!1,void 0===e?"api":"ui")},click:n,positionCallback:()=>{const e=this.gos.get("enableRtl");this.popupService.positionPopupUnderMouseEvent(pu(du({},u),{nudgeX:e?-1*(c.offsetWidth+1):1}))},anchorToElement:s,ariaLabel:h("ariaLabelContextMenu","Context Menu")});d&&(a.classList.add(yu),l.afterGuiAttached({container:"contextMenu",hidePopup:d.hideFunc})),this.activeMenu&&this.hideActiveMenu(),this.activeMenu=l,l.addEventListener(r.XQb.EVENT_DESTROYED,()=>{this.activeMenu===l&&(this.activeMenu=null)}),d&&l.addEventListener(r.yuY.EVENT_CLOSE_MENU,e=>{var t,i;return d.hideFunc({mouseEvent:null!=(t=e.mouseEvent)?t:void 0,keyboardEvent:null!=(i=e.keyboardEvent)?i:void 0,forceHide:!0})});const p=n&&n instanceof MouseEvent&&"mousedown"===n.type;return this.dispatchVisibleChangedEvent(!0,p?"api":"ui"),!0}dispatchVisibleChangedEvent(e,t="ui"){const i={type:r.sVA.EVENT_CONTEXT_MENU_VISIBLE_CHANGED,visible:e,source:t};this.eventService.dispatchEvent(i)}};gu([(0,r.dsm)("popupService")],wu.prototype,"popupService",2),gu([(0,r.dsm)("ctrlsService")],wu.prototype,"ctrlsService",2),gu([(0,r.dsm)("columnModel")],wu.prototype,"columnModel",2),gu([(0,r.dsm)("menuUtils")],wu.prototype,"menuUtils",2),gu([(0,r.Xx1)("rangeService")],wu.prototype,"rangeService",2),wu=gu([(0,r.dR4)("contextMenuFactory")],wu);var Su=class extends r.uAl{constructor(e,t,i,r){super('<div class="ag-menu" role="presentation"></div>'),this.menuItems=e,this.column=t,this.node=i,this.value=r,this.menuList=null,this.focusedCell=null}addMenuItems(){const e=this.createManagedBean(new r.i9O(0,{column:this.column,node:this.node,value:this.value})),t=this.menuItemMapper.mapWithStockItems(this.menuItems,null,()=>this.getGui());e.addMenuItems(t),this.appendChild(e),this.menuList=e,e.addEventListener(r.yuY.EVENT_CLOSE_MENU,e=>this.dispatchEvent(e))}afterGuiAttached(e){e.hidePopup&&this.addDestroyFunc(e.hidePopup),this.focusedCell=this.focusService.getFocusedCell(),this.menuList&&this.focusService.focusInto(this.menuList.getGui())}restoreFocusedCell(){const e=this.focusService.getFocusedCell();if(e&&this.focusedCell&&this.cellPositionUtils.equals(e,this.focusedCell)){const{rowIndex:e,rowPinned:t,column:i}=this.focusedCell,r=this.gos.getDocument(),n=this.gos.getActiveDomElement();n&&n!==r.body||this.focusService.setFocusedCell({rowIndex:e,column:i,rowPinned:t,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!this.focusService.isKeyboardMode()})}}destroy(){this.restoreFocusedCell(),super.destroy()}};gu([(0,r.dsm)("menuItemMapper")],Su.prototype,"menuItemMapper",2),gu([(0,r.dsm)("focusService")],Su.prototype,"focusService",2),gu([(0,r.dsm)("cellPositionUtils")],Su.prototype,"cellPositionUtils",2),gu([r.o7C],Su.prototype,"addMenuItems",1);var bu=class extends r.XQb{mapWithStockItems(e,t,i){if(!e)return[];const r=[];return e.forEach(e=>{let n;if(n="string"==typeof e?this.getStockMenuItem(e,t,i):du({},e),!n)return;const s=n,{subMenu:o}=s;o&&o instanceof Array&&(s.subMenu=this.mapWithStockItems(o,t,i)),null!=n&&r.push(n)}),r}getStockMenuItem(e,t,i){var n;const s=this.localeService.getLocaleTextFunc(),o=this.gos.get("skipHeaderOnAutoSize");switch(e){case"pinSubMenu":return{name:s("pinColumn","Pin Column"),icon:r._.createIconNoSpan("menuPin",this.gos,null),subMenu:["clearPinned","pinLeft","pinRight"]};case"pinLeft":return{name:s("pinLeft","Pin Left"),action:()=>this.columnModel.setColumnsPinned([t],"left","contextMenu"),checked:!!t&&t.isPinnedLeft()};case"pinRight":return{name:s("pinRight","Pin Right"),action:()=>this.columnModel.setColumnsPinned([t],"right","contextMenu"),checked:!!t&&t.isPinnedRight()};case"clearPinned":return{name:s("noPin","No Pin"),action:()=>this.columnModel.setColumnsPinned([t],null,"contextMenu"),checked:!!t&&!t.isPinned()};case"valueAggSubMenu":return r.syG.__assertRegistered(r.zsj.RowGroupingModule,"Aggregation from Menu",this.context.getGridId())&&((null==t?void 0:t.isPrimary())||(null==t?void 0:t.getColDef().pivotValueColumn))?{name:s("valueAggregation","Value Aggregation"),icon:r._.createIconNoSpan("menuValue",this.gos,null),subMenu:this.createAggregationSubMenu(t,this.aggFuncService)}:null;case"autoSizeThis":return{name:s("autosizeThiscolumn","Autosize This Column"),action:()=>this.columnModel.autoSizeColumn(t,"contextMenu",o)};case"autoSizeAll":return{name:s("autosizeAllColumns","Autosize All Columns"),action:()=>this.columnModel.autoSizeAllColumns("contextMenu",o)};case"rowGroup":return{name:s("groupBy","Group by")+" "+r._.escapeString(this.columnModel.getDisplayNameForColumn(t,"header")),disabled:(null==t?void 0:t.isRowGroupActive())||!(null==t?void 0:t.getColDef().enableRowGroup),action:()=>this.columnModel.addRowGroupColumns([t],"contextMenu"),icon:r._.createIconNoSpan("menuAddRowGroup",this.gos,null)};case"rowUnGroup":const a=r._.createIconNoSpan("menuRemoveRowGroup",this.gos,null),l=null==t?void 0:t.getColDef().showRowGroup,c=this.gos.get("groupLockGroupColumns");if(!0===l)return{name:s("ungroupAll","Un-Group All"),disabled:-1===c||c>=this.columnModel.getRowGroupColumns().length,action:()=>this.columnModel.setRowGroupColumns(this.columnModel.getRowGroupColumns().slice(0,c),"contextMenu"),icon:a};if("string"==typeof l){const e=this.columnModel.getPrimaryColumn(l),t=null!=e?r._.escapeString(this.columnModel.getDisplayNameForColumn(e,"header")):l;return{name:s("ungroupBy","Un-Group by")+" "+t,disabled:null!=e&&this.columnModel.isColumnGroupingLocked(e),action:()=>this.columnModel.removeRowGroupColumns([l],"contextMenu"),icon:a}}return{name:s("ungroupBy","Un-Group by")+" "+r._.escapeString(this.columnModel.getDisplayNameForColumn(t,"header")),disabled:!(null==t?void 0:t.isRowGroupActive())||!(null==t?void 0:t.getColDef().enableRowGroup)||this.columnModel.isColumnGroupingLocked(t),action:()=>this.columnModel.removeRowGroupColumns([t],"contextMenu"),icon:a};case"resetColumns":return{name:s("resetColumns","Reset Columns"),action:()=>this.columnModel.resetColumnState("contextMenu")};case"expandAll":return{name:s("expandAll","Expand All Row Groups"),action:()=>this.gridApi.expandAll()};case"contractAll":return{name:s("collapseAll","Collapse All Row Groups"),action:()=>this.gridApi.collapseAll()};case"copy":return r.syG.__assertRegistered(r.zsj.ClipboardModule,"Copy from Menu",this.context.getGridId())?{name:s("copy","Copy"),shortcut:s("ctrlC","Ctrl+C"),icon:r._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard()}:null;case"copyWithHeaders":return r.syG.__assertRegistered(r.zsj.ClipboardModule,"Copy with Headers from Menu",this.context.getGridId())?{name:s("copyWithHeaders","Copy with Headers"),icon:r._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard({includeHeaders:!0})}:null;case"copyWithGroupHeaders":return r.syG.__assertRegistered(r.zsj.ClipboardModule,"Copy with Group Headers from Menu",this.context.getGridId())?{name:s("copyWithGroupHeaders","Copy with Group Headers"),icon:r._.createIconNoSpan("clipboardCopy",this.gos,null),action:()=>this.clipboardService.copyToClipboard({includeHeaders:!0,includeGroupHeaders:!0})}:null;case"cut":if(r.syG.__assertRegistered(r.zsj.ClipboardModule,"Cut from Menu",this.context.getGridId())){const e=this.focusService.getFocusedCell(),t=e?this.rowPositionUtils.getRowNode(e):null,i=!!t&&(null==e?void 0:e.column.isCellEditable(t));return{name:s("cut","Cut"),shortcut:s("ctrlX","Ctrl+X"),icon:r._.createIconNoSpan("clipboardCut",this.gos,null),disabled:!i||this.gos.get("suppressCutToClipboard"),action:()=>this.clipboardService.cutToClipboard(void 0,"contextMenu")}}return null;case"paste":return r.syG.__assertRegistered(r.zsj.ClipboardModule,"Paste from Clipboard",this.context.getGridId())?{name:s("paste","Paste"),shortcut:s("ctrlV","Ctrl+V"),disabled:!0,icon:r._.createIconNoSpan("clipboardPaste",this.gos,null),action:()=>this.clipboardService.pasteFromClipboard()}:null;case"export":const u=[],h=r.syG.__isRegistered(r.zsj.CsvExportModule,this.context.getGridId()),d=r.syG.__isRegistered(r.zsj.ExcelExportModule,this.context.getGridId());return!this.gos.get("suppressCsvExport")&&h&&u.push("csvExport"),!this.gos.get("suppressExcelExport")&&d&&u.push("excelExport"),{name:s("export","Export"),subMenu:u,icon:r._.createIconNoSpan("save",this.gos,null)};case"csvExport":return{name:s("csvExport","CSV Export"),icon:r._.createIconNoSpan("csvExport",this.gos,null),action:()=>this.gridApi.exportDataAsCsv({})};case"excelExport":return{name:s("excelExport","Excel Export"),icon:r._.createIconNoSpan("excelExport",this.gos,null),action:()=>this.gridApi.exportDataAsExcel()};case"separator":return"separator";case"pivotChart":case"chartRange":return null!=(n=this.chartMenuItemMapper.getChartItems(e))?n:null;case"columnFilter":return t?{name:s("columnFilter","Column Filter"),icon:r._.createIconNoSpan("filter",this.gos,null),action:()=>this.menuService.showFilterMenu({column:t,buttonElement:i(),containerType:"columnFilter",positionBy:"button"})}:null;case"columnChooser":return r.syG.__isRegistered(r.zsj.ColumnsToolPanelModule,this.context.getGridId())?{name:s("columnChooser","Choose Columns"),icon:r._.createIconNoSpan("columns",this.gos,null),action:()=>this.menuService.showColumnChooser({column:t,eventSource:i()})}:null;case"sortAscending":return{name:s("sortAscending","Sort Ascending"),icon:r._.createIconNoSpan("sortAscending",this.gos,null),action:()=>this.sortController.setSortForColumn(t,"asc",!1,"columnMenu")};case"sortDescending":return{name:s("sortDescending","Sort Descending"),icon:r._.createIconNoSpan("sortDescending",this.gos,null),action:()=>this.sortController.setSortForColumn(t,"desc",!1,"columnMenu")};case"sortUnSort":return{name:s("sortUnSort","Clear Sort"),icon:r._.createIconNoSpan("sortUnSort",this.gos,null),action:()=>this.sortController.setSortForColumn(t,null,!1,"columnMenu")};default:return console.warn(`AG Grid: unknown menu item type ${e}`),null}}createAggregationSubMenu(e,t){const i=this.localeService.getLocaleTextFunc();let n;if(e.isPrimary())n=e;else{const t=e.getColDef().pivotValueColumn;n=r._.exists(t)?t:void 0}const s=[];if(n){const e=n.isValueActive(),r=t.getFuncNames(n);s.push({name:i("noAggregation","None"),action:()=>{this.columnModel.removeValueColumns([n],"contextMenu"),this.columnModel.setColumnAggFunc(n,void 0,"contextMenu")},checked:!e}),r.forEach(r=>{s.push({name:i(r,t.getDefaultFuncLabel(r)),action:()=>{this.columnModel.setColumnAggFunc(n,r,"contextMenu"),this.columnModel.addValueColumns([n],"contextMenu")},checked:e&&n.getAggFunc()===r})})}return s}};gu([(0,r.dsm)("columnModel")],bu.prototype,"columnModel",2),gu([(0,r.dsm)("gridApi")],bu.prototype,"gridApi",2),gu([(0,r.dsm)("focusService")],bu.prototype,"focusService",2),gu([(0,r.dsm)("rowPositionUtils")],bu.prototype,"rowPositionUtils",2),gu([(0,r.dsm)("chartMenuItemMapper")],bu.prototype,"chartMenuItemMapper",2),gu([(0,r.dsm)("menuService")],bu.prototype,"menuService",2),gu([(0,r.dsm)("sortController")],bu.prototype,"sortController",2),gu([(0,r.Xx1)("clipboardService")],bu.prototype,"clipboardService",2),gu([(0,r.Xx1)("aggFuncService")],bu.prototype,"aggFuncService",2),bu=gu([(0,r.dR4)("menuItemMapper")],bu);var Eu=class extends r.XQb{getChartItems(e){var t,i;if(!this.chartService)return void r.syG.__assertRegistered(r.zsj.GridChartsModule,`the Context Menu key "${e}"`,this.context.getGridId());const n="pivotChart"===e?new Au(this.gos,this.chartService,this.localeService):new Tu(this.gos,this.chartService,this.localeService),s=this.chartService.isEnterprise();let o=n.getMenuItem();if(o&&o.subMenu&&!s){const e=t=>{var i;return pu(du({},t),{subMenu:null==(i=t.subMenu)?void 0:i.filter(e=>!e._enterprise).map(t=>e(t))})};o=e(o)}const a=null==(i=null==(t=this.gos.get("chartToolPanelsDef"))?void 0:t.settingsPanel)?void 0:i.chartGroupsDef;return a&&(o=Eu.filterAndOrderChartMenu(o,a,n.getConfigLookup())),this.cleanInternals(o)}cleanInternals(e){if(!e)return e;const t=e=>{var i;return null==e||delete e._key,null==e||delete e._enterprise,null==(i=null==e?void 0:e.subMenu)||i.forEach(e=>t(e)),e};return t(e)}static buildLookup(e){let t={};const i=e=>{t[e._key]=e,e.subMenu&&e.subMenu.forEach(e=>i(e))};return i(e),t}static filterAndOrderChartMenu(e,t,i){var n;const s=this.buildLookup(e);let o=pu(du({},e),{subMenu:[]});if(Object.entries(t).forEach(([e,t])=>{var n,a;const l=i[e];if(null===l)return;if(null==l)return void r._.warnOnce(`invalid chartGroupsDef config '${e}'`);const c=s[l._key];if(c)if(c.subMenu){const i=t.map(t=>{const i=l[t];if(null!=i)return s[i];r._.warnOnce(`invalid chartGroupsDef config '${e}.${t}'`)}).filter(e=>void 0!==e);i.length>0&&(c.subMenu=i,null==(n=o.subMenu)||n.push(c))}else null==(a=o.subMenu)||a.push(c)}),0!=(null==(n=o.subMenu)?void 0:n.length))return o}};gu([(0,r.Xx1)("chartService")],Eu.prototype,"chartService",2),Eu=gu([(0,r.dR4)("chartMenuItemMapper")],Eu);var Au=class{constructor(e,t,i){this.gos=e,this.chartService=t,this.localeService=i}getMenuItem(){const e=this.localeService.getLocaleTextFunc(),t=(t,i,r,n,s=!1)=>({name:e(t,i),action:()=>this.chartService.createPivotChart({chartType:r}),_key:n,_enterprise:s});return{name:e("pivotChart","Pivot Chart"),_key:"pivotChart",subMenu:[{_key:"pivotColumnChart",name:e("columnChart","Column"),subMenu:[t("groupedColumn","Grouped&lrm;","groupedColumn","pivotGroupedColumn"),t("stackedColumn","Stacked&lrm;","stackedColumn","pivotStackedColumn"),t("normalizedColumn","100% Stacked&lrm;","normalizedColumn","pivotNormalizedColumn")]},{_key:"pivotBarChart",name:e("barChart","Bar"),subMenu:[t("groupedBar","Grouped&lrm;","groupedBar","pivotGroupedBar"),t("stackedBar","Stacked&lrm;","stackedBar","pivotStackedBar"),t("normalizedBar","100% Stacked&lrm;","normalizedBar","pivotNormalizedBar")]},{_key:"pivotPieChart",name:e("pieChart","Pie"),subMenu:[t("pie","Pie&lrm;","pie","pivotPie"),t("donut","Donut&lrm;","donut","pivotDonut")]},t("line","Line&lrm;","line","pivotLineChart"),{_key:"pivotXYChart",name:e("xyChart","X Y (Scatter)"),subMenu:[t("scatter","Scatter&lrm;","scatter","pivotScatter"),t("bubble","Bubble&lrm;","bubble","pivotBubble")]},{_key:"pivotAreaChart",name:e("areaChart","Area"),subMenu:[t("area","Area&lrm;","area","pivotArea"),t("stackedArea","Stacked&lrm;","stackedArea","pivotStackedArea"),t("normalizedArea","100% Stacked&lrm;","normalizedArea","pivotNormalizedArea")]},{_key:"pivotStatisticalChart",_enterprise:!1,name:e("statisticalChart","Statistical"),subMenu:[t("histogramChart","Histogram&lrm;","histogram","pivotHistogram",!1)]},{_key:"pivotHierarchicalChart",_enterprise:!0,name:e("hierarchicalChart","Hierarchical"),subMenu:[t("treemapChart","Treemap&lrm;","treemap","pivotTreemap",!0),t("sunburstChart","Sunburst&lrm;","sunburst","pivotSunburst",!0)]},{_key:"pivotCombinationChart",name:e("combinationChart","Combination"),subMenu:[t("columnLineCombo","Column & Line&lrm;","columnLineCombo","pivotColumnLineCombo"),t("AreaColumnCombo","Area & Column&lrm;","areaColumnCombo","pivotAreaColumnCombo")]}],icon:r._.createIconNoSpan("chart",this.gos,void 0)}}getConfigLookup(){return{columnGroup:{_key:"pivotColumnChart",column:"pivotGroupedColumn",stackedColumn:"pivotStackedColumn",normalizedColumn:"pivotNormalizedColumn"},barGroup:{_key:"pivotBarChart",bar:"pivotGroupedBar",stackedBar:"pivotStackedBar",normalizedBar:"pivotNormalizedBar"},pieGroup:{_key:"pivotPieChart",pie:"pivotPie",donut:"pivotDonut",doughnut:"pivotDonut"},lineGroup:{_key:"pivotLineChart",line:"pivotLineChart"},scatterGroup:{_key:"pivotXYChart",bubble:"pivotBubble",scatter:"pivotScatter"},areaGroup:{_key:"pivotAreaChart",area:"pivotArea",stackedArea:"pivotStackedArea",normalizedArea:"pivotNormalizedArea"},combinationGroup:{_key:"pivotCombinationChart",columnLineCombo:"pivotColumnLineCombo",areaColumnCombo:"pivotAreaColumnCombo",customCombo:null},hierarchicalGroup:{_key:"pivotHierarchicalChart",treemap:"pivotTreemap",sunburst:"pivotSunburst"},statisticalGroup:{_key:"pivotStatisticalChart",histogram:"pivotHistogram",rangeBar:null,rangeArea:null,boxPlot:null},polarGroup:null,specializedGroup:null}}},Tu=class{constructor(e,t,i){this.gos=e,this.chartService=t,this.localeService=i}getMenuItem(){const e=this.localeService.getLocaleTextFunc(),t=(t,i,r,n,s=!1)=>({name:e(t,i),action:()=>this.chartService.createChartFromCurrentRange(r),_key:n,_enterprise:s});return{name:e("chartRange","Chart Range"),_key:"chartRange",subMenu:[{name:e("columnChart","Column"),subMenu:[t("groupedColumn","Grouped&lrm;","groupedColumn","rangeGroupedColumn"),t("stackedColumn","Stacked&lrm;","stackedColumn","rangeStackedColumn"),t("normalizedColumn","100% Stacked&lrm;","normalizedColumn","rangeNormalizedColumn")],_key:"rangeColumnChart"},{name:e("barChart","Bar"),subMenu:[t("groupedBar","Grouped&lrm;","groupedBar","rangeGroupedBar"),t("stackedBar","Stacked&lrm;","stackedBar","rangeStackedBar"),t("normalizedBar","100% Stacked&lrm;","normalizedBar","rangeNormalizedBar")],_key:"rangeBarChart"},{name:e("pieChart","Pie"),subMenu:[t("pie","Pie&lrm;","pie","rangePie"),t("donut","Donut&lrm;","donut","rangeDonut")],_key:"rangePieChart"},t("line","Line&lrm;","line","rangeLineChart"),{name:e("xyChart","X Y (Scatter)"),subMenu:[t("scatter","Scatter&lrm;","scatter","rangeScatter"),t("bubble","Bubble&lrm;","bubble","rangeBubble")],_key:"rangeXYChart"},{name:e("areaChart","Area"),subMenu:[t("area","Area&lrm;","area","rangeArea"),t("stackedArea","Stacked&lrm;","stackedArea","rangeStackedArea"),t("normalizedArea","100% Stacked&lrm;","normalizedArea","rangeNormalizedArea")],_key:"rangeAreaChart"},{name:e("polarChart","Polar"),subMenu:[t("radarLine","Radar Line&lrm;","radarLine","rangeRadarLine"),t("radarArea","Radar Area&lrm;","radarArea","rangeRadarArea"),t("nightingale","Nightingale&lrm;","nightingale","rangeNightingale"),t("radialColumn","Radial Column&lrm;","radialColumn","rangeRadialColumn"),t("radialBar","Radial Bar&lrm;","radialBar","rangeRadialBar")],_key:"rangePolarChart",_enterprise:!0},{name:e("statisticalChart","Statistical"),subMenu:[t("boxPlot","Box Plot&lrm;","boxPlot","rangeBoxPlot",!0),t("histogramChart","Histogram&lrm;","histogram","rangeHistogram",!1),t("rangeBar","Range Bar&lrm;","rangeBar","rangeRangeBar",!0),t("rangeArea","Range Area&lrm;","rangeArea","rangeRangeArea",!0)],_key:"rangeStatisticalChart",_enterprise:!1},{name:e("hierarchicalChart","Hierarchical"),subMenu:[t("treemap","Treemap&lrm;","treemap","rangeTreemap"),t("sunburst","Sunburst&lrm;","sunburst","rangeSunburst")],_key:"rangeHierarchicalChart",_enterprise:!0},{name:e("specializedChart","Specialized"),subMenu:[t("heatmap","Heatmap&lrm;","heatmap","rangeHeatmap"),t("waterfall","Waterfall&lrm;","waterfall","rangeWaterfall")],_key:"rangeSpecializedChart",_enterprise:!0},{name:e("combinationChart","Combination"),subMenu:[t("columnLineCombo","Column & Line&lrm;","columnLineCombo","rangeColumnLineCombo"),t("AreaColumnCombo","Area & Column&lrm;","areaColumnCombo","rangeAreaColumnCombo")],_key:"rangeCombinationChart"}],icon:r._.createIconNoSpan("chart",this.gos,void 0)}}getConfigLookup(){return{columnGroup:{_key:"rangeColumnChart",column:"rangeGroupedColumn",stackedColumn:"rangeStackedColumn",normalizedColumn:"rangeNormalizedColumn"},barGroup:{_key:"rangeBarChart",bar:"rangeGroupedBar",stackedBar:"rangeStackedBar",normalizedBar:"rangeNormalizedBar"},pieGroup:{_key:"rangePieChart",pie:"rangePie",donut:"rangeDonut",doughnut:"rangeDonut"},lineGroup:{_key:"rangeLineChart",line:"rangeLineChart"},scatterGroup:{_key:"rangeXYChart",bubble:"rangeBubble",scatter:"rangeScatter"},areaGroup:{_key:"rangeAreaChart",area:"rangeArea",stackedArea:"rangeStackedArea",normalizedArea:"rangeNormalizedArea"},polarGroup:{_key:"rangePolarChart",radarLine:"rangeRadarLine",radarArea:"rangeRadarArea",nightingale:"rangeNightingale",radialColumn:"rangeRadialColumn",radialBar:"rangeRadialBar"},statisticalGroup:{_key:"rangeStatisticalChart",boxPlot:"rangeBoxPlot",histogram:"rangeHistogram",rangeBar:"rangeRangeBar",rangeArea:"rangeRangeArea"},hierarchicalGroup:{_key:"rangeHierarchicalChart",treemap:"rangeTreemap",sunburst:"rangeSunburst"},specializedGroup:{_key:"rangeSpecializedChart",heatmap:"rangeHeatmap",waterfall:"rangeWaterfall"},combinationGroup:{_key:"rangeCombinationChart",columnLineCombo:"rangeColumnLineCombo",areaColumnCombo:"rangeAreaColumnCombo",customCombo:null}}}},Mu=class extends r.XQb{createColumnSelectPanel(e,t,i,r){var n,s;const o=e.createManagedBean(new Ca),a=null!=(s=null!=(n=null!=r?r:null==t?void 0:t.getColDef().columnChooserParams)?n:null==t?void 0:t.getColDef().columnsMenuParams)?s:{},{contractColumnSelection:l,suppressColumnExpandAll:c,suppressColumnFilter:u,suppressColumnSelectAll:h,suppressSyncLayoutWithGrid:d,columnLayout:p}=a;return o.init(!!i,this.gos.addGridCommonParams({suppressColumnMove:!1,suppressValues:!1,suppressPivots:!1,suppressRowGroups:!1,suppressPivotMode:!1,contractColumnSelection:!!l,suppressColumnExpandAll:!!c,suppressColumnFilter:!!u,suppressColumnSelectAll:!!h,suppressSyncLayoutWithGrid:!!p||!!d,onStateUpdated:()=>{}}),"columnMenu"),p&&o.setColumnLayout(p),o}showColumnChooser({column:e,chooserParams:t,eventSource:i}){this.hideActiveColumnChooser();const n=this.createColumnSelectPanel(this,e,!0,t),s=this.localeService.getLocaleTextFunc(),o=this.columnModel.getAllDisplayedColumns().indexOf(e),a=e?this.focusService.getFocusedHeader():null;this.activeColumnChooserDialog=this.createBean(new r.fNJ({title:s("chooseColumns","Choose Columns"),component:n,width:300,height:300,resizable:!0,movable:!0,centered:!0,closable:!0,afterGuiAttached:()=>{var t;null==(t=this.focusService.findNextFocusableElement(n.getGui()))||t.focus(),this.dispatchVisibleChangedEvent(!0,e)},closedCallback:t=>{const r=this.activeColumnChooser.getGui();this.destroyBean(this.activeColumnChooser),this.activeColumnChooser=void 0,this.activeColumnChooserDialog=void 0,this.dispatchVisibleChangedEvent(!1,e),e&&this.menuUtils.restoreFocusOnClose({column:e,headerPosition:a,columnIndex:o,eventSource:i},r,t,!0)}})),this.activeColumnChooser=n}hideActiveColumnChooser(){this.activeColumnChooserDialog&&this.destroyBean(this.activeColumnChooserDialog)}dispatchVisibleChangedEvent(e,t){const i={type:r.sVA.EVENT_COLUMN_MENU_VISIBLE_CHANGED,visible:e,switchingTab:!1,key:"columnChooser",column:null!=t?t:null};this.eventService.dispatchEvent(i)}};gu([(0,r.dsm)("focusService")],Mu.prototype,"focusService",2),gu([(0,r.dsm)("menuUtils")],Mu.prototype,"menuUtils",2),gu([(0,r.dsm)("columnModel")],Mu.prototype,"columnModel",2),Mu=gu([(0,r.dR4)("columnChooserFactory")],Mu);var Ru=class extends r.XQb{createMenu(e,t,i){const n=e.createManagedBean(new r.i9O(0,{column:null!=t?t:null,node:null,value:null})),s=this.getMenuItems(t),o=this.menuItemMapper.mapWithStockItems(s,null!=t?t:null,i);return n.addMenuItems(o),n}getMenuItems(e){const t=this.getDefaultMenuOptions(e);let i;const n=null==e?void 0:e.getColDef().mainMenuItems;if(Array.isArray(n))i=n;else if("function"==typeof n)i=n(this.gos.addGridCommonParams({column:e,defaultItems:t}));else{const r=this.gos.getCallback("getMainMenuItems");i=r&&e?r({column:e,defaultItems:t}):t}return r._.removeRepeatsFromArray(i,Ru.MENU_ITEM_SEPARATOR),i}getDefaultMenuOptions(e){const t=[],i=this.menuService.isLegacyMenuEnabled();if(!e)return i||t.push("columnChooser"),t.push("resetColumns"),t;const r=!e.getColDef().lockPinned,n=this.columnModel.getRowGroupColumns().length,s=n>0,o=e.isAllowValue(),a=e.isAllowRowGroup(),l=e.isPrimary(),c=this.columnModel.isPivotMode(),u="clientSide"===this.rowModel.getType(),h=this.gos.get("treeData"),d=l&&s&&o||!l;if(!i&&e.isSortable()){const i=e.getSort();"asc"!==i&&t.push("sortAscending"),"desc"!==i&&t.push("sortDescending"),i&&t.push("sortUnSort"),t.push(Ru.MENU_ITEM_SEPARATOR)}return this.menuService.isFilterMenuItemEnabled(e)&&(t.push("columnFilter"),t.push(Ru.MENU_ITEM_SEPARATOR)),r&&t.push("pinSubMenu"),d&&t.push("valueAggSubMenu"),(r||d)&&t.push(Ru.MENU_ITEM_SEPARATOR),t.push("autoSizeThis"),t.push("autoSizeAll"),t.push(Ru.MENU_ITEM_SEPARATOR),e.getColDef().showRowGroup?t.push("rowUnGroup"):a&&e.isPrimary()&&(e.isRowGroupActive()?this.columnModel.isColumnGroupingLocked(e)||t.push("rowUnGroup"):t.push("rowGroup")),t.push(Ru.MENU_ITEM_SEPARATOR),i||t.push("columnChooser"),t.push("resetColumns"),u&&(h||n>(c?1:0))&&(t.push("expandAll"),t.push("contractAll")),t}};Ru.MENU_ITEM_SEPARATOR="separator",gu([(0,r.dsm)("menuItemMapper")],Ru.prototype,"menuItemMapper",2),gu([(0,r.dsm)("columnModel")],Ru.prototype,"columnModel",2),gu([(0,r.dsm)("rowModel")],Ru.prototype,"rowModel",2),gu([(0,r.dsm)("filterManager")],Ru.prototype,"filterManager",2),gu([(0,r.dsm)("menuService")],Ru.prototype,"menuService",2),Ru=gu([(0,r.dR4)("columnMenuFactory")],Ru);var _u=class extends r.XQb{restoreFocusOnClose(e,t,i,r){const{eventSource:n}=e,s=i instanceof KeyboardEvent;if(!r&&!s||!n)return;const o=this.gos.getDocument(),a=this.gos.getActiveDomElement();(t.contains(a)||a===o.body)&&this.focusHeaderCell(e)}closePopupAndRestoreFocusOnSelect(e,t,i){let r;i&&i.keyboardEvent&&(r=i.keyboardEvent),e(r&&{keyboardEvent:r});const n=this.focusService.getFocusedCell(),s=this.gos.getDocument(),o=this.gos.getActiveDomElement();if(!o||o===s.body)if(n){const{rowIndex:e,rowPinned:t,column:i}=n;this.focusService.setFocusedCell({rowIndex:e,column:i,rowPinned:t,forceBrowserFocus:!0,preventScrollOnBrowserFocus:!0})}else this.focusHeaderCell(t)}onContextMenu(e,t,i){if((this.gos.get("allowContextMenuWithControlKey")||!e||!e.ctrlKey&&!e.metaKey)&&(e&&this.blockMiddleClickScrollsIfNeeded(e),!this.gos.get("suppressContextMenu")&&i(null!=e?e:t.touches[0]))){const i=null!=e?e:t;i&&i.cancelable&&i.preventDefault()}}focusHeaderCell(e){const{column:t,columnIndex:i,headerPosition:n,eventSource:s}=e;if(this.columnModel.getAllDisplayedColumns().some(e=>e===t)&&s&&r._.isVisible(s)){const e=this.focusService.findTabbableParent(s);e&&(t&&this.headerNavigationService.scrollToColumn(t),e.focus())}else if(n&&-1!==i){const e=this.columnModel.getAllDisplayedColumns(),t=e[i]||r._.last(e);t&&this.focusService.focusHeaderPosition({headerPosition:{headerRowIndex:n.headerRowIndex,column:t}})}}blockMiddleClickScrollsIfNeeded(e){this.gos.get("suppressMiddleClickScrolls")&&2===e.which&&e.preventDefault()}};gu([(0,r.dsm)("focusService")],_u.prototype,"focusService",2),gu([(0,r.dsm)("headerNavigationService")],_u.prototype,"headerNavigationService",2),gu([(0,r.dsm)("columnModel")],_u.prototype,"columnModel",2),_u=gu([(0,r.dR4)("menuUtils")],_u);var Pu={version:"31.3.4",moduleName:r.zsj.MenuModule,beans:[fu,wu,bu,Eu,Mu,Ru,_u],dependantModules:[S]},xu=Object.defineProperty,Du=Object.defineProperties,Iu=Object.getOwnPropertyDescriptor,Lu=Object.getOwnPropertyDescriptors,Nu=Object.getOwnPropertySymbols,Ou=Object.prototype.hasOwnProperty,Fu=Object.prototype.propertyIsEnumerable,ku=(e,t,i)=>t in e?xu(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Gu=(e,t)=>{for(var i in t||(t={}))Ou.call(t,i)&&ku(e,i,t[i]);if(Nu)for(var i of Nu(t))Fu.call(t,i)&&ku(e,i,t[i]);return e},Vu=(e,t)=>Du(e,Lu(t)),Hu=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Iu(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&xu(t,i,s),s},Bu=class e extends r.aJZ{constructor(){super('<div class="ag-multi-filter ag-menu-list-compact"></div>'),this.filterDefs=[],this.filters=[],this.guiDestroyFuncs=[],this.filterGuis=[],this.activeFilterIndices=[],this.lastActivatedMenuItem=null,this.afterFiltersReadyFuncs=[]}postConstruct(){this.initialiseTabGuard({onFocusIn:e=>this.onFocusIn(e)})}static getFilterDefs(e){const{filters:t}=e;return t&&t.length>0?t:[{filter:"agTextColumnFilter"},{filter:"agSetColumnFilter"}]}init(t){this.params=t,this.filterDefs=e.getFilterDefs(t);const{column:i,filterChangedCallback:n}=t;this.column=i,this.filterChangedCallback=n;const s=[];return this.filterDefs.forEach((e,t)=>{const i=this.createFilter(e,t);null!=i&&s.push(i)}),new r.oY$(e=>{r.oY$.all(s).then(t=>{this.filters=t,this.refreshGui("columnMenu").then(()=>{e()})})}).then(()=>{this.afterFiltersReadyFuncs.forEach(e=>e()),this.afterFiltersReadyFuncs.length=0})}refreshGui(e){return e===this.lastOpenedInContainer?r.oY$.resolve():(this.removeAllChildrenExceptTabGuards(),this.destroyChildren(),r.oY$.all(this.filters.map((t,i)=>{const n=this.filterDefs[i],s=this.getFilterTitle(t,n);let o;if("subMenu"===n.display&&"toolPanel"!==e)o=this.insertFilterMenu(t,s).then(e=>e.getGui());else if("subMenu"===n.display||"accordion"===n.display){const e=this.insertFilterGroup(t,s);o=r.oY$.resolve(e.getGui())}else o=r.oY$.resolve(t.getGui());return o})).then(t=>{t.forEach((e,t)=>{t>0&&this.appendChild(r._.loadTemplate('<div class="ag-filter-separator"></div>')),this.appendChild(e)}),this.filterGuis=t,this.lastOpenedInContainer=e}))}getFilterTitle(e,t){return null!=t.title?t.title:e instanceof r.Q5x?e.getFilterTitle():"Filter"}destroyChildren(){this.guiDestroyFuncs.forEach(e=>e()),this.guiDestroyFuncs.length=0,this.filterGuis.length=0}insertFilterMenu(e,t){const i=this.createBean(new r.yuY);return i.init({menuItemDef:{name:t,subMenu:[],cssClasses:["ag-multi-filter-menu-item"],menuItem:r.Y0b,menuItemParams:{cssClassPrefix:"ag-compact-menu-option",isCompact:!0}},level:0,isAnotherSubMenuOpen:()=>!1,childComponent:e,contextParams:{column:null,node:null,value:null}}).then(()=>{i.setParentComponent(this),this.guiDestroyFuncs.push(()=>this.destroyBean(i)),this.addManagedListener(i,r.yuY.EVENT_MENU_ITEM_ACTIVATED,e=>{this.lastActivatedMenuItem&&this.lastActivatedMenuItem!==e.menuItem&&this.lastActivatedMenuItem.deactivate(),this.lastActivatedMenuItem=e.menuItem});const e=i.getGui();return i.addManagedListener(e,"keydown",e=>{const{key:t}=e;switch(t){case r.DDm.UP:case r.DDm.RIGHT:case r.DDm.DOWN:case r.DDm.LEFT:e.preventDefault(),t===r.DDm.RIGHT&&i.openSubMenu(!0)}}),i.addManagedListener(e,"focusin",()=>i.activate()),i.addManagedListener(e,"focusout",()=>{i.isSubMenuOpen()||i.isSubMenuOpening()||i.deactivate()}),i})}insertFilterGroup(e,t){const i=this.createBean(new r.Pk_({title:t,cssIdentifier:"multi-filter"}));return this.guiDestroyFuncs.push(()=>this.destroyBean(i)),i.addItem(e.getGui()),i.toggleGroupExpand(!1),e.afterGuiAttached&&i.addManagedListener(i,r.Pk_.EVENT_EXPANDED,()=>e.afterGuiAttached({container:this.lastOpenedInContainer,suppressFocus:!0,hidePopup:this.hidePopup})),i}isFilterActive(){return this.filters.some(e=>e.isFilterActive())}getLastActiveFilterIndex(){return this.activeFilterIndices.length>0?this.activeFilterIndices[this.activeFilterIndices.length-1]:null}doesFilterPass(e,t){let i=!0;return this.filters.forEach(r=>{i&&r!==t&&r.isFilterActive()&&(i=r.doesFilterPass(e))}),i}getFilterType(){return"multi"}getModelFromUi(){return{filterType:this.getFilterType(),filterModels:this.filters.map(e=>{const t=e;return"function"==typeof t.getModelFromUi?t.getModelFromUi():null})}}getModel(){return this.isFilterActive()?{filterType:this.getFilterType(),filterModels:this.filters.map(e=>e.isFilterActive()?e.getModel():null)}:null}setModel(e){const t=(e,t)=>new r.oY$(i=>{const r=e.setModel(t);r?r.then(()=>i()):i()});let i=[];return null==e?i=this.filters.map((e,i)=>t(e,null).then(()=>{this.updateActiveList(i)})):this.filters.forEach((r,n)=>{const s=e.filterModels.length>n?e.filterModels[n]:null,o=t(r,s).then(()=>{this.updateActiveList(n)});i.push(o)}),r.oY$.all(i).then(()=>{})}applyModel(e="api"){let t=!1;return this.filters.forEach(i=>{i instanceof r.Q5x&&(t=i.applyModel(e)||t)}),t}getChildFilterInstance(e){return this.filters[e]}afterGuiAttached(e){let t;e?(this.hidePopup=e.hidePopup,t=this.refreshGui(e.container)):(this.hidePopup=void 0,t=r.oY$.resolve()),t.then(()=>{const{filterDefs:t}=this;let i=!1;t&&r._.forEachReverse(t,(t,r)=>{var n;const s=0===r,o=!s||"inline"!==t.display,a=Vu(Gu({},null!=e?e:{}),{suppressFocus:o}),l=null==(n=this.filters)?void 0:n[r];if(l&&(this.executeFunctionIfExistsOnFilter(l,"afterGuiAttached",a),s&&(i=!0)),s&&o){const e=this.filterGuis[r];e&&(e.focus(),i=!0)}});const n=this.gos.getDocument(),s=this.gos.getActiveDomElement();i||s&&s!==n.body&&!this.getGui().contains(s)||this.forceFocusOutOfContainer(!0)})}afterGuiDetached(){this.executeFunctionIfExists("afterGuiDetached")}onAnyFilterChanged(){this.executeFunctionIfExists("onAnyFilterChanged")}onNewRowsLoaded(){this.executeFunctionIfExists("onNewRowsLoaded")}destroy(){this.filters.forEach(e=>this.destroyBean(e)),this.filters.length=0,this.destroyChildren(),this.hidePopup=void 0,super.destroy()}executeFunctionIfExists(e,...t){r._.forEachReverse(this.filters,i=>{this.executeFunctionIfExistsOnFilter(i,e,t)})}executeFunctionIfExistsOnFilter(e,t,...i){const r=e[t];"function"==typeof r&&r.apply(e,i)}createFilter(e,t){const{filterModifiedCallback:i,doesRowPassOtherFilter:r}=this.params;let n;const s=Vu(Gu({},this.filterManager.createFilterParams(this.column,this.column.getColDef())),{filterModifiedCallback:i,filterChangedCallback:e=>{this.executeWhenAllFiltersReady(()=>this.filterChanged(t,e))},doesRowPassOtherFilter:e=>r(e)&&this.doesFilterPass({node:e,data:e.data},n)}),o=this.userComponentFactory.getFilterDetails(e,s,"agTextColumnFilter");if(!o)return null;const a=o.newAgStackInstance();return a&&a.then(e=>n=e),a}executeWhenAllFiltersReady(e){this.filters&&this.filters.length>0?e():this.afterFiltersReadyFuncs.push(e)}updateActiveList(e){const t=this.filters[e];r._.removeFromArray(this.activeFilterIndices,e),t.isFilterActive()&&this.activeFilterIndices.push(e)}filterChanged(e,t){this.updateActiveList(e),this.filterChangedCallback(t);const i=this.filters[e];this.filters.forEach(e=>{e!==i&&"function"==typeof e.onAnyFilterChanged&&e.onAnyFilterChanged()})}onFocusIn(e){null==this.lastActivatedMenuItem||this.lastActivatedMenuItem.getGui().contains(e.target)||(this.lastActivatedMenuItem.deactivate(),this.lastActivatedMenuItem=null)}getModelAsString(e){var t,i,r,n;if(!this.filters||!(null==(t=null==e?void 0:e.filterModels)?void 0:t.length))return"";const s=null!=(i=this.getLastActiveFilterIndex())?i:0,o=this.filters[s];return null!=(n=null==(r=o.getModelAsString)?void 0:r.call(o,e.filterModels[s]))?n:""}};Hu([(0,r.dsm)("filterManager")],Bu.prototype,"filterManager",2),Hu([(0,r.dsm)("userComponentFactory")],Bu.prototype,"userComponentFactory",2),Hu([r.o7C],Bu.prototype,"postConstruct",1);var zu=Bu,Uu=class extends r.uAl{constructor(){super('<div class="ag-multi-floating-filter ag-floating-filter-input"></div>'),this.floatingFilters=[],this.compDetailsList=[]}init(e){this.params=e;const{compDetailsList:t}=this.getCompDetailsList(e);return this.setParams(t)}setParams(e){const t=[];return e.forEach(e=>{const i=null==e?void 0:e.newAgStackInstance();null!=i&&(this.compDetailsList.push(e),t.push(i))}),r.oY$.all(t).then(e=>{e.forEach((e,t)=>{this.floatingFilters.push(e);const i=e.getGui();this.appendChild(i),t>0&&r._.setDisplayed(i,!1)})})}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e;const{compDetailsList:t,floatingFilterParamsList:i}=this.getCompDetailsList(e);t.length===this.compDetailsList.length&&t.every((e,t)=>!this.filterManager.areFilterCompsDifferent(this.compDetailsList[t],e))?i.forEach((e,t)=>{var i;const r=this.floatingFilters[t];let n=!1;r.refresh&&null!==r.refresh(e)&&(n=!0),n||null==(i=r.onParamsUpdated)||i.call(r,e)}):(r._.clearElement(this.getGui()),this.destroyBeans(this.floatingFilters),this.floatingFilters=[],this.compDetailsList=[],this.setParams(t))}getCompDetailsList(e){const t=[],i=[],n=e.filterParams;return zu.getFilterDefs(n).forEach((n,s)=>{const o=Vu(Gu({},e),{parentFilterInstance:e=>{this.parentMultiFilterInstance(t=>{const i=t.getChildFilterInstance(s);null!=i&&e(i)})}});r._.mergeDeep(o.filterParams,n.filterParams);const a=this.getCompDetails(n,o);a&&(t.push(a),i.push(o))}),{compDetailsList:t,floatingFilterParamsList:i}}onParentModelChanged(e,t){t&&t.afterFloatingFilter||this.parentMultiFilterInstance(i=>{if(null==e)this.floatingFilters.forEach((e,i)=>{e.onParentModelChanged(null,t),r._.setDisplayed(e.getGui(),0===i)});else{const n=i.getLastActiveFilterIndex();this.floatingFilters.forEach((i,s)=>{const o=e.filterModels.length>s?e.filterModels[s]:null;i.onParentModelChanged(o,t);const a=null==n?0===s:s===n;r._.setDisplayed(i.getGui(),a)})}})}destroy(){this.destroyBeans(this.floatingFilters),this.floatingFilters.length=0,super.destroy()}getCompDetails(e,t){var i;let r=null!=(i=this.userComponentFactory.getDefaultFloatingFilterType(e,()=>this.filterManager.getDefaultFloatingFilter(this.params.column)))?i:"agReadOnlyFloatingFilter";return this.userComponentFactory.getFloatingFilterCompDetails(e,t,r)}parentMultiFilterInstance(e){this.params.parentFilterInstance(t=>{if(!(t instanceof zu))throw new Error("AG Grid - MultiFloatingFilterComp expects MultiFilter as its parent");e(t)})}};Hu([(0,r.dsm)("userComponentFactory")],Uu.prototype,"userComponentFactory",2),Hu([(0,r.dsm)("filterManager")],Uu.prototype,"filterManager",2);var Wu={version:"31.3.4",moduleName:r.zsj.MultiFilterModule,beans:[],userComponents:[{componentName:"agMultiColumnFilter",componentClass:zu},{componentName:"agMultiColumnFloatingFilter",componentClass:Uu}],dependantModules:[S]},ju=class extends r.yGC{constructor(){super('<div class="ag-cell-edit-wrapper"></div>')}init(e){this.params=e;const{cellStartedEdit:t,cellHeight:i,values:n}=e;r._.missing(n)&&console.warn("AG Grid: agRichSelectCellEditor requires cellEditorParams.values to be set");const{params:s,valuesPromise:o}=this.buildRichSelectParams();this.richSelect=this.createManagedBean(new r.pNP(s)),this.richSelect.addCssClass("ag-cell-editor"),this.appendChild(this.richSelect),o&&o.then(e=>{this.richSelect.setValueList({valueList:e,refresh:!0});const t=this.getSearchStringCallback(e);t&&this.richSelect.setSearchStringCreator(t)}),this.addManagedListener(this.richSelect,r.sVA.EVENT_FIELD_PICKER_VALUE_SELECTED,this.onEditorPickerValueSelected.bind(this)),this.addManagedListener(this.richSelect.getGui(),"focusout",this.onEditorFocusOut.bind(this)),this.focusAfterAttached=t,r._.exists(i)&&this.richSelect.setRowHeight(i)}onEditorPickerValueSelected(e){this.params.stopEditing(!e.fromEnterKey)}onEditorFocusOut(e){this.richSelect.getGui().contains(e.relatedTarget)||this.params.stopEditing(!0)}buildRichSelectParams(){const{cellRenderer:e,value:t,values:i,formatValue:r,searchDebounceDelay:n,valueListGap:s,valueListMaxHeight:o,valueListMaxWidth:a,allowTyping:l,filterList:c,searchType:u,highlightMatch:h,valuePlaceholder:d,eventKey:p}=this.params,g={value:t,cellRenderer:e,searchDebounceDelay:n,valueFormatter:r,pickerAriaLabelKey:"ariaLabelRichSelectField",pickerAriaLabelValue:"Rich Select Field",pickerType:"virtual-list",pickerGap:s,allowTyping:l,filterList:c,searchType:u,highlightMatch:h,maxPickerHeight:o,maxPickerWidth:a,placeholder:d,initialInputValue:1===(null==p?void 0:p.length)?p:void 0};let f,m;return f="function"==typeof i?i(this.params):null!=i?i:[],Array.isArray(f)?(g.valueList=f,g.searchStringCreator=this.getSearchStringCallback(f)):m=f,{params:g,valuesPromise:m}}getSearchStringCallback(e){const{colDef:t}=this.params;if("object"==typeof e[0]&&t.keyCreator)return e=>e.map(e=>{const i=this.gos.addGridCommonParams({value:e,colDef:this.params.colDef,column:this.params.column,node:this.params.node,data:this.params.data});return t.keyCreator(i)})}afterGuiAttached(){const{focusAfterAttached:e,params:t}=this;setTimeout(()=>{if(!this.isAlive())return;if(e){const e=this.richSelect.getFocusableElement();e.focus();const{allowTyping:t,eventKey:i}=this.params;!t||i&&1===i.length||e.select()}this.richSelect.showPicker();const{eventKey:i}=t;i&&1===(null==i?void 0:i.length)&&this.richSelect.searchTextFromString(i)})}getValue(){return this.richSelect.getValue()}isPopup(){return!1}},Ku={version:"31.3.4",moduleName:r.zsj.RichSelectModule,beans:[],userComponents:[{componentName:"agRichSelect",componentClass:ju},{componentName:"agRichSelectCellEditor",componentClass:ju}],dependantModules:[S]},$u=Object.defineProperty,qu=Object.defineProperties,Yu=Object.getOwnPropertyDescriptor,Qu=Object.getOwnPropertyDescriptors,Xu=Object.getOwnPropertySymbols,Zu=Object.prototype.hasOwnProperty,Ju=Object.prototype.propertyIsEnumerable,eh=(e,t,i)=>t in e?$u(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,th=(e,t)=>{for(var i in t||(t={}))Zu.call(t,i)&&eh(e,i,t[i]);if(Xu)for(var i of Xu(t))Ju.call(t,i)&&eh(e,i,t[i]);return e},ih=(e,t)=>{var i={};for(var r in e)Zu.call(e,r)&&t.indexOf(r)<0&&(i[r]=e[r]);if(null!=e&&Xu)for(var r of Xu(e))t.indexOf(r)<0&&Ju.call(e,r)&&(i[r]=e[r]);return i},rh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Yu(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&$u(t,i,s),s},nh=class extends r.iEP{constructor(e,t,i){super(0),this.nodeIdSequence=new r.RI_,this.info={},this.ssrmParams=e,this.parentRowNode=i,this.level=i.level+1,this.groupLevel=e.rowGroupCols?this.level<e.rowGroupCols.length:void 0,this.leafGroup=!!e.rowGroupCols&&this.level===e.rowGroupCols.length-1}postConstruct(){if(this.usingTreeData=this.gos.get("treeData"),this.nodeIdPrefix=this.blockUtils.createNodeIdPrefix(this.parentRowNode),!this.usingTreeData&&this.groupLevel){const e=this.ssrmParams.rowGroupCols[this.level];this.groupField=e.field,this.rowGroupColumn=this.columnModel.getRowGroupColumns()[this.level]}let e=1;const t=-1===this.parentRowNode.level,i=this.storeUtils.getServerSideInitialRowCount();t&&null!=i&&(e=i),this.initialiseRowNodes(e),this.rowNodeBlockLoader.addBlock(this),this.addDestroyFunc(()=>this.rowNodeBlockLoader.removeBlock(this)),this.postSortFunc=this.gos.getCallback("postSortRows"),null!=i&&this.eventService.dispatchEventOnce({type:r.sVA.EVENT_ROW_COUNT_READY})}destroyRowNodes(){this.blockUtils.destroyRowNodes(this.allRowNodes),this.allRowNodes=[],this.nodesAfterSort=[],this.nodesAfterFilter=[],this.allNodesMap={}}initialiseRowNodes(e,t=!1){this.destroyRowNodes();for(let i=0;i<e;i++){const e=this.blockUtils.createRowNode({field:this.groupField,group:this.groupLevel,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn});t&&(e.failedLoad=!0),this.allRowNodes.push(e),this.nodesAfterFilter.push(e),this.nodesAfterSort.push(e)}}getBlockStateJson(){return{id:this.nodeIdPrefix?this.nodeIdPrefix:"",state:this.getState()}}loadFromDatasource(){this.storeUtils.loadFromDatasource({startRow:void 0,endRow:void 0,parentBlock:this,parentNode:this.parentRowNode,storeParams:this.ssrmParams,success:this.success.bind(this,this.getVersion()),fail:this.pageLoadFailed.bind(this,this.getVersion())})}getStartRow(){return 0}getEndRow(){return this.nodesAfterSort.length}createDataNode(e,t){const i=this.blockUtils.createRowNode({field:this.groupField,group:this.groupLevel,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn});null!=t?r._.insertIntoArray(this.allRowNodes,i,t):this.allRowNodes.push(i);const n=this.prefixId(this.nodeIdSequence.next());return this.blockUtils.setDataIntoRowNode(i,e,n,void 0),this.nodeManager.addRowNode(i),this.blockUtils.checkOpenByDefault(i),this.allNodesMap[i.id]=i,i}prefixId(e){return this.nodeIdPrefix?this.nodeIdPrefix+"-"+e:e.toString()}processServerFail(){this.initialiseRowNodes(1,!0),this.fireStoreUpdatedEvent(),this.flushAsyncTransactions()}processServerResult(e){if(!this.isAlive())return;const t=e.groupLevelInfo;t&&Object.assign(this.info,t),e.pivotResultFields&&this.serverSideRowModel.generateSecondaryColumns(e.pivotResultFields);const i=this.allRowNodes.length>0?this.allNodesMap:void 0;this.allRowNodes=[],this.nodesAfterSort=[],this.nodesAfterFilter=[],this.allNodesMap={},e.rowData||r._.warnOnce('"params.data" is missing from Server-Side Row Model success() callback. Please use the "data" attribute. If no data is returned, set an empty list.'),this.createOrRecycleNodes(i,e.rowData),i&&this.blockUtils.destroyRowNodes(r._.getAllValuesInObject(i)),0===this.level&&this.eventService.dispatchEventOnce({type:r.sVA.EVENT_ROW_COUNT_READY}),this.filterAndSortNodes(),this.fireStoreUpdatedEvent(),this.flushAsyncTransactions()}createOrRecycleNodes(e,t){if(!t)return;const i=t=>{if(!e)return;const i=this.gos.getCallback("getRowId");if(!i)return;const r=this.parentRowNode.getGroupKeys(),n=this.level,s=i({data:t,parentKeys:r.length>0?r:void 0,level:n}),o=e[s];return o?(delete e[s],o):void 0},r=(e,t)=>{this.allNodesMap[e.id]=e,this.blockUtils.updateDataIntoRowNode(e,t),this.allRowNodes.push(e)};t.forEach(e=>{const t=i(e);t?r(t,e):this.createDataNode(e)})}flushAsyncTransactions(){window.setTimeout(()=>this.transactionManager.flushAsyncTransactions(),0)}filterAndSortNodes(){this.filterRowNodes(),this.sortRowNodes()}sortRowNodes(){const e=this.storeUtils.isServerSideSortAllLevels()||this.storeUtils.isServerSideSortOnServer(),t=this.sortController.getSortOptions(),i=!t||0==t.length;if(e||i)this.nodesAfterSort=this.nodesAfterFilter;else if(this.nodesAfterSort=this.rowNodeSorter.doFullSort(this.nodesAfterFilter,t),this.postSortFunc){const e={nodes:this.nodesAfterSort};this.postSortFunc(e)}}filterRowNodes(){const e=!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||this.storeUtils.isServerSideFilterOnServer(),t=this.groupLevel;this.nodesAfterFilter=e||t?this.allRowNodes:this.allRowNodes.filter(e=>this.filterManager.doesRowPassFilter({rowNode:e}))}clearDisplayIndexes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.allRowNodes.forEach(e=>this.blockUtils.clearDisplayIndex(e))}getDisplayIndexEnd(){return this.displayIndexEnd}isDisplayIndexInStore(e){return 0!==this.getRowCount()&&e>=this.displayIndexStart&&e<this.displayIndexEnd}setDisplayIndexes(e,t){this.displayIndexStart=e.peek(),this.topPx=t.value;const i={};this.nodesAfterSort.forEach(r=>{this.blockUtils.setDisplayIndex(r,e,t),i[r.id]=!0}),this.allRowNodes.forEach(e=>{i[e.id]||this.blockUtils.clearDisplayIndex(e)}),this.displayIndexEnd=e.peek(),this.heightPx=t.value-this.topPx}forEachStoreDeep(e,t=new r.RI_){e(this,t.next()),this.allRowNodes.forEach(i=>{const r=i.childStore;r&&r.forEachStoreDeep(e,t)})}forEachNodeDeep(e,t=new r.RI_){this.allRowNodes.forEach(i=>{e(i,t.next());const r=i.childStore;r&&r.forEachNodeDeep(e,t)})}forEachNodeDeepAfterFilterAndSort(e,t=new r.RI_,i=!1){this.nodesAfterSort.forEach(r=>{e(r,t.next());const n=r.childStore;n&&n.forEachNodeDeepAfterFilterAndSort(e,t,i)}),i&&this.parentRowNode.sibling&&e(this.parentRowNode.sibling,t.next())}getRowUsingDisplayIndex(e){if(this.isDisplayIndexInStore(e))return this.blockUtils.binarySearchForDisplayIndex(e,this.nodesAfterSort)}getRowBounds(e){for(let t=0;t<this.nodesAfterSort.length;t++){const i=this.nodesAfterSort[t],r=this.blockUtils.extractRowBounds(i,e);if(r)return r}return null}isPixelInRange(e){return e>=this.topPx&&e<this.topPx+this.heightPx}getRowIndexAtPixel(e){if(e<=this.topPx)return this.nodesAfterSort[0].rowIndex;if(e>=this.topPx+this.heightPx){const t=this.nodesAfterSort[this.nodesAfterSort.length-1],i=t.rowTop+t.rowHeight;if(e>=i&&t.expanded){if(t.childStore&&t.childStore.getRowCount()>0)return t.childStore.getRowIndexAtPixel(e);if(t.detailNode)return t.detailNode.rowIndex}return t.rowIndex}let t=null;return this.nodesAfterSort.forEach(i=>{const r=this.blockUtils.getIndexAtPixel(i,e);null!=r&&(t=r)}),null==t?this.displayIndexEnd-1:t}getChildStore(e){return this.storeUtils.getChildStore(e,this,e=>this.allRowNodes.find(t=>t.key==e))}forEachChildStoreShallow(e){this.allRowNodes.forEach(t=>{const i=t.childStore;i&&e(i)})}refreshAfterFilter(e){const t=this.storeUtils.isServerSideFilterOnServer(),i=this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e);if(!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||t&&i)return this.refreshStore(!0),void this.sortRowNodes();this.filterRowNodes(),this.sortRowNodes(),this.forEachChildStoreShallow(t=>t.refreshAfterFilter(e))}refreshAfterSort(e){const t=this.storeUtils.isServerSideSortOnServer(),i=this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e);if(this.storeUtils.isServerSideSortAllLevels()||t&&i)return this.refreshStore(!0),void this.filterRowNodes();this.filterRowNodes(),this.sortRowNodes(),this.forEachChildStoreShallow(t=>t.refreshAfterSort(e))}applyTransaction(e){switch(this.getState()){case r.iEP.STATE_FAILED:return{status:r.a8A.StoreLoadingFailed};case r.iEP.STATE_LOADING:return{status:r.a8A.StoreLoading};case r.iEP.STATE_WAITING_TO_LOAD:return{status:r.a8A.StoreWaitingToLoad}}const t=this.gos.getCallback("isApplyServerSideTransaction");if(t&&!t({transaction:e,parentNode:this.parentRowNode,groupLevelInfo:this.info}))return{status:r.a8A.Cancelled};const i={status:r.a8A.Applied,remove:[],update:[],add:[]},n=[];return this.executeAdd(e,i),this.executeRemove(e,i,n),this.executeUpdate(e,i,n),this.filterAndSortNodes(),this.updateSelection(n),i}updateSelection(e){if(e.length>0){this.selectionService.setNodesSelected({newValue:!1,nodes:e,suppressFinishActions:!0,clearSelection:!1,source:"rowDataChanged"});const t={type:r.sVA.EVENT_SELECTION_CHANGED,source:"rowDataChanged"};this.eventService.dispatchEvent(t)}}executeAdd(e,t){const{add:i,addIndex:n}=e;r._.missingOrEmpty(i)||("number"==typeof n&&n>=0?i.reverse().forEach(e=>{const i=this.createDataNode(e,n);t.add.push(i)}):i.forEach(e=>{const i=this.createDataNode(e);t.add.push(i)}))}executeRemove(e,t,i){const{remove:r}=e;if(null==r)return;const n={};r.forEach(e=>{const r=this.lookupRowNode(e);r&&(r.isSelected()&&i.push(r),r.clearRowTopAndRowIndex(),n[r.id]=!0,delete this.allNodesMap[r.id],t.remove.push(r),this.nodeManager.removeNode(r))}),this.allRowNodes=this.allRowNodes.filter(e=>!n[e.id])}executeUpdate(e,t,i){const{update:r}=e;null!=r&&r.forEach(e=>{const r=this.lookupRowNode(e);r&&(this.blockUtils.updateDataIntoRowNode(r,e),!r.selectable&&r.isSelected()&&i.push(r),t.update.push(r))})}lookupRowNode(e){const t=this.gos.getCallback("getRowId");let i;if(null!=t){const r=this.level,n=this.parentRowNode.getGroupKeys(),s=t({data:e,parentKeys:n.length>0?n:void 0,level:r});if(i=this.allNodesMap[s],!i)return console.error(`AG Grid: could not find row id=${s}, data item was not found for this id`),null}else if(i=this.allRowNodes.find(t=>t.data===e),!i)return console.error("AG Grid: could not find data item as object was not found",e),null;return i}addStoreStates(e){e.push({suppressInfiniteScroll:!0,route:this.parentRowNode.getGroupKeys(),rowCount:this.allRowNodes.length,info:this.info}),this.forEachChildStoreShallow(t=>t.addStoreStates(e))}refreshStore(e){if(e){const e=this.nodesAfterSort?this.nodesAfterSort.length:1;this.initialiseRowNodes(e)}this.scheduleLoad(),this.fireStoreUpdatedEvent()}retryLoads(){this.getState()===r.iEP.STATE_FAILED&&(this.initialiseRowNodes(1),this.scheduleLoad()),this.forEachChildStoreShallow(e=>e.retryLoads())}scheduleLoad(){this.setStateWaitingToLoad(),this.rowNodeBlockLoader.checkBlockToLoad()}fireStoreUpdatedEvent(){const e={type:r.sVA.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}getRowCount(){return this.nodesAfterSort.length}getTopLevelRowDisplayedIndex(e){return this.nodesAfterSort[e].rowIndex}isLastRowIndexKnown(){return this.getState()==r.iEP.STATE_LOADED}getRowNodesInRange(e,t){const i=[];let n=!1;return r._.missing(e)&&(n=!0),this.nodesAfterSort.forEach(r=>{const s=r===e||r===t;(n||s)&&i.push(r),s&&(n=!n)}),n?[]:i}getStoreBounds(){return{topPx:this.topPx,heightPx:this.heightPx}}};rh([(0,r.dsm)("ssrmStoreUtils")],nh.prototype,"storeUtils",2),rh([(0,r.dsm)("ssrmBlockUtils")],nh.prototype,"blockUtils",2),rh([(0,r.dsm)("columnModel")],nh.prototype,"columnModel",2),rh([(0,r.dsm)("rowNodeBlockLoader")],nh.prototype,"rowNodeBlockLoader",2),rh([(0,r.dsm)("rowNodeSorter")],nh.prototype,"rowNodeSorter",2),rh([(0,r.dsm)("sortController")],nh.prototype,"sortController",2),rh([(0,r.dsm)("selectionService")],nh.prototype,"selectionService",2),rh([(0,r.dsm)("ssrmNodeManager")],nh.prototype,"nodeManager",2),rh([(0,r.dsm)("filterManager")],nh.prototype,"filterManager",2),rh([(0,r.dsm)("ssrmTransactionManager")],nh.prototype,"transactionManager",2),rh([(0,r.dsm)("rowModel")],nh.prototype,"serverSideRowModel",2),rh([r.o7C],nh.prototype,"postConstruct",1),rh([r.yah],nh.prototype,"destroyRowNodes",1);var sh=class{constructor(...e){if(e.length<1)throw new Error("AG Grid: At least one index must be provided.");this.indexes=e,this.maps=new Map(this.indexes.map(e=>[e,new Map]))}getSize(){return this.maps.get(this.indexes[0]).size}getBy(e,t){const i=this.maps.get(e);if(!i)throw new Error(`AG Grid: ${String(e)} not found`);return i.get(t)}set(e){this.indexes.forEach(t=>{const i=this.maps.get(t);if(!i)throw new Error(`AG Grid: ${String(t)} not found`);i.set(e[t],e)})}delete(e){this.indexes.forEach(t=>{const i=this.maps.get(t);if(!i)throw new Error(`AG Grid: ${String(t)} not found`);i.delete(e[t])})}clear(){this.maps.forEach(e=>e.clear())}getIterator(e){const t=this.maps.get(e);if(!t)throw new Error(`AG Grid: ${String(e)} not found`);return t.values()}forEach(e){const t=this.getIterator(this.indexes[0]);let i;for(;(i=t.next())&&!i.done;)e(i.value)}find(e){const t=this.getIterator(this.indexes[0]);let i;for(;(i=t.next())&&!i.done;)if(e(i.value))return i.value}filter(e){const t=this.getIterator(this.indexes[0]);let i;const r=[];for(;(i=t.next())&&!i.done;)e(i.value)&&r.push(i.value);return r}},oh=class extends r.XQb{constructor(){super(...arguments),this.cacheLoadingNodesMap=new Map,this.isCheckQueued=!1,this.nextBlockToLoad=void 0}init(){this.addManagedListener(this.rowNodeBlockLoader,r.RRV.BLOCK_LOADED_EVENT,()=>this.queueLoadCheck())}subscribe(e){this.cacheLoadingNodesMap.set(e,new Set)}unsubscribe(e){this.cacheLoadingNodesMap.delete(e)}queueLoadCheck(){this.isCheckQueued||(this.isCheckQueued=!0,window.queueMicrotask(()=>{this.queueLoadAction(),this.isCheckQueued=!1}))}queueLoadAction(){const e=this.getBlockToLoad();if(!e)return;const t=this.nextBlockToLoad&&this.nextBlockToLoad.cache===e.cache&&this.nextBlockToLoad.index===e.index;if(!(t||this.nextBlockToLoad&&t)){this.nextBlockToLoad=e,window.clearTimeout(this.loaderTimeout);const t=Number(this.nextBlockToLoad.index),i=this.nextBlockToLoad.cache,r=e.index+e.cache.getBlockSize();this.loaderTimeout=window.setTimeout(()=>{i.isAlive()&&(this.loaderTimeout=void 0,this.attemptLoad(i,t,r),this.nextBlockToLoad=void 0)},this.gos.get("blockLoadDebounceMillis"))}}attemptLoad(e,t,i){const r=this.rowNodeBlockLoader.getAvailableLoadingCount();null!=r&&0===r||(this.rowNodeBlockLoader.registerLoads(1),this.executeLoad(e,t,i),this.queueLoadCheck())}executeLoad(e,t,i){var r;const n=e.getSsrmParams(),s={startRow:t,endRow:i,rowGroupCols:n.rowGroupCols,valueCols:n.valueCols,pivotCols:n.pivotCols,pivotMode:n.pivotMode,groupKeys:e.store.getParentNode().getGroupKeys(),filterModel:n.filterModel,sortModel:n.sortModel},o=this.cacheLoadingNodesMap.get(e),a=()=>{for(let e=0;e<i-t;e++)o.delete(t+e)},l=this.gos.addGridCommonParams({request:s,success:r=>{this.rowNodeBlockLoader.loadComplete(),e.onLoadSuccess(t,i-t,r),a()},fail:()=>{this.rowNodeBlockLoader.loadComplete(),e.onLoadFailed(t,i-t),a()},parentNode:e.store.getParentNode()});(()=>{for(let e=0;e<i-t;e++)o.add(t+e)})(),null==(r=e.getSsrmParams().datasource)||r.getRows(l)}getBlockToLoad(){var e;const t=this.rowRenderer.getFirstVirtualRenderedRow(),i=this.rowRenderer.getLastVirtualRenderedRow();for(let e=t;e<=i;e++){const t=this.rowModel.getRow(e);if(!t)continue;const i=t.parent&&t.parent.childStore;if(!(i&&i instanceof lh))continue;const r=i.getCache(),n=r.getNodes().getBy("node",t);if(!n)continue;const s=this.cacheLoadingNodesMap.get(r);if(!(null==s?void 0:s.has(n.index))&&(t.__needsRefreshWhenVisible||t.stub&&!t.failedLoad))return{cache:r,index:r.getBlockStartIndex(n.index)}}let r=null,n=null,s=Number.MAX_SAFE_INTEGER;for(const e of this.cacheLoadingNodesMap.keys())e.getNodesToRefresh().forEach(o=>{if(null==o.rowIndex)return n=o,void(r=e);const a=e.getNodes().getBy("node",o);if(!a)return;const l=this.cacheLoadingNodesMap.get(e);if(null==l?void 0:l.has(a.index))return;const c=Math.abs(t-o.rowIndex),u=Math.abs(o.rowIndex-i);c<s&&(n=o,s=c,r=e),u<s&&(n=o,s=u,r=e)});if(!r)return;const o=r,a=null==(e=o.getNodes().getBy("node",n))?void 0:e.index;return null==a?void 0:{cache:o,index:o.getBlockStartIndex(a)}}isRowLoading(e,t){var i,r;return null!=(r=null==(i=this.cacheLoadingNodesMap.get(e))?void 0:i.has(t))&&r}};oh.DEFAULT_BLOCK_SIZE=100,rh([(0,r.dsm)("rowNodeBlockLoader")],oh.prototype,"rowNodeBlockLoader",2),rh([(0,r.dsm)("rowRenderer")],oh.prototype,"rowRenderer",2),rh([(0,r.dsm)("rowModel")],oh.prototype,"rowModel",2),rh([r.o7C],oh.prototype,"init",1),oh=rh([(0,r.dR4)("lazyBlockLoadingService")],oh);var ah=class extends r.XQb{constructor(e,t,i){super(),this.live=!0,this.removedNodeCache=new Map,this.store=e,this.numberOfRows=t,this.isLastRowKnown=!1,this.storeParams=i}init(){this.lazyBlockLoadingService.subscribe(this),this.nodeMap=new sh("index","id","node"),this.nodeDisplayIndexMap=new Map,this.nodesToRefresh=new Set,this.defaultNodeIdPrefix=this.blockUtils.createNodeIdPrefix(this.store.getParentNode()),this.getRowIdFunc=this.gos.getCallback("getRowId"),this.isMasterDetail=this.gos.get("masterDetail")}destroyRowNodes(){this.lazyBlockLoadingService.unsubscribe(this),this.numberOfRows=0,this.nodeMap.forEach(e=>this.blockUtils.destroyRowNode(e.node)),this.nodeMap.clear(),this.nodeDisplayIndexMap.clear(),this.nodesToRefresh.clear(),this.live=!1}getRowByDisplayIndex(e){var t,i,r,n;if(!this.store.isDisplayIndexInStore(e))return;const s=this.nodeDisplayIndexMap.get(e);if(s)return(s.stub||s.__needsRefreshWhenVisible)&&this.lazyBlockLoadingService.queueLoadCheck(),s;if(e===this.store.getDisplayIndexStart())return this.createStubNode(0,e);const o=this.nodeDisplayIndexMap.get(e-1);if(o){if(this.isMasterDetail&&o.master&&o.expanded)return o.detailNode;if(o.expanded&&(null==(t=o.childStore)?void 0:t.isDisplayIndexInStore(e)))return null==(i=o.childStore)?void 0:i.getRowUsingDisplayIndex(e);const r=this.nodeMap.getBy("node",o);return this.createStubNode(r.index+1,e)}const a=this.getSurroundingNodesByDisplayIndex(e);if(null==a){const t=this.store.getRowCount()-(this.store.getDisplayIndexEnd()-e);return this.createStubNode(t,e)}const{previousNode:l,nextNode:c}=a;if(l&&l.node.expanded&&(null==(r=l.node.childStore)?void 0:r.isDisplayIndexInStore(e)))return null==(n=l.node.childStore)?void 0:n.getRowUsingDisplayIndex(e);if(c){const t=c.node.rowIndex-e,i=c.index-t;return this.createStubNode(i,e)}const u=this.store.getRowCount()-(this.store.getDisplayIndexEnd()-e);return this.createStubNode(u,e)}createStubNode(e,t){const i=this.store.getRowBounds(t),r=this.createRowAtIndex(e,null,e=>{e.setRowIndex(t),e.setRowTop(i.rowTop),this.nodeDisplayIndexMap.set(t,e)});return this.lazyBlockLoadingService.queueLoadCheck(),r}getRowByStoreIndex(e){var t;return null==(t=this.nodeMap.getBy("index",e))?void 0:t.node}skipDisplayIndexes(e,t,i){if(0===e)return;const r=this.gos.getRowHeightAsNumber();t.skip(e),i.value+=e*r}setDisplayIndexes(e,t){this.nodeDisplayIndexMap.clear();const i={};this.nodeMap.forEach(e=>{i[e.index]=e.node});let r=-1;for(const n in i){const s=i[n],o=Number(n),a=o-1-r;this.skipDisplayIndexes(a,e,t),this.blockUtils.setDisplayIndex(s,e,t),this.nodeDisplayIndexMap.set(s.rowIndex,s),r=o}const n=this.numberOfRows-1-r;this.skipDisplayIndexes(n,e,t),this.purgeExcessRows()}getRowCount(){return this.numberOfRows}setRowCount(e,t){if(e<0)throw new Error("AG Grid: setRowCount can only accept a positive row count.");this.numberOfRows=e,null!=t&&(this.isLastRowKnown=t,!1===t&&(this.numberOfRows+=1)),this.fireStoreUpdatedEvent()}getNodes(){return this.nodeMap}getNodeCachedByDisplayIndex(e){var t;return null!=(t=this.nodeDisplayIndexMap.get(e))?t:null}getNodesToRefresh(){return this.nodesToRefresh}getSurroundingNodesByDisplayIndex(e){let t,i;return this.nodeMap.forEach(r=>{e>r.node.rowIndex?(null==i||i.node.rowIndex<r.node.rowIndex)&&(i=r):(null==t||t.node.rowIndex>r.node.rowIndex)&&(t=r)}),i||t?{previousNode:i,nextNode:t}:null}getDisplayIndexFromStoreIndex(e){var t,i;const r=this.nodeMap.getBy("index",e);if(r)return r.node.rowIndex;let n,s;if(this.nodeMap.forEach(t=>{e>t.index?(null==s||s.index<t.index)&&(s=t):(null==n||n.index>t.index)&&(n=t)}),!n)return this.store.getDisplayIndexEnd()-(this.numberOfRows-e);if(!s)return this.store.getDisplayIndexStart()+e;const o=e-s.index;return(null!=(i=null==(t=s.node.childStore)?void 0:t.getDisplayIndexEnd())?i:s.node.rowIndex)+o}createRowAtIndex(e,t,i){var r,n;const s=this.nodeMap.getBy("index",e);if(s){const{node:i}=s;if(i.__needsRefreshWhenVisible=!1,this.doesNodeMatch(t,i))return this.blockUtils.updateDataIntoRowNode(i,t),this.nodesToRefresh.delete(i),i;if(null==this.getRowIdFunc&&i.hasChildren()&&i.expanded)return this.nodesToRefresh.delete(i),i;this.destroyRowAtIndex(e)}if(t&&null!=this.getRowIdFunc){const i=this.getRowId(t),s=i&&(null==(r=this.removedNodeCache)?void 0:r.get(i));if(s)return null==(n=this.removedNodeCache)||n.delete(i),this.blockUtils.updateDataIntoRowNode(s,t),this.nodeMap.set({id:s.id,node:s,index:e}),s;const o=this.nodeMap.getBy("id",i);if(o){this.nodeMap.delete(o);const{node:i,index:r}=o;return this.blockUtils.updateDataIntoRowNode(i,t),this.nodeMap.set({id:i.id,node:i,index:e}),this.nodesToRefresh.delete(i),this.getBlockStartIndex(r)===this.getBlockStartIndex(e)||this.markBlockForVerify(r),i}}const o=this.blockUtils.createRowNode(this.store.getRowDetails());if(null!=t){const e=this.getPrefixedId(this.store.getIdSequence().next());this.blockUtils.setDataIntoRowNode(o,t,e,void 0),this.serverSideRowModel.setPaused(!0),this.blockUtils.checkOpenByDefault(o),this.serverSideRowModel.setPaused(!1),this.nodeManager.addRowNode(o)}return this.nodeMap.set({id:o.id,node:o,index:e}),i&&i(o),o}getBlockStates(){const e={},t={};this.nodeMap.forEach(({node:i,index:r})=>{var n;const s=this.getBlockStartIndex(r);i.stub||i.failedLoad||(e[s]=(null!=(n=e[s])?n:0)+1);let o="loaded";i.failedLoad?o="failed":this.lazyBlockLoadingService.isRowLoading(this,s)?o="loading":(this.nodesToRefresh.has(i)||i.stub)&&(o="needsLoading"),t[s]||(t[s]=new Set),t[s].add(o)});const i={loading:4,failed:3,needsLoading:2,loaded:1},r=this.blockUtils.createNodeIdPrefix(this.store.getParentNode()),n={};return Object.entries(t).forEach(([t,s])=>{var o;const a=[...s].sort((e,t)=>{var r,n;return(null!=(r=i[e])?r:0)-(null!=(n=i[t])?n:0)})[0],l=Number(t)/this.getBlockSize(),c=r?`${r}-${l}`:String(l);n[c]={blockNumber:l,startRow:Number(t),endRow:Number(t)+this.getBlockSize(),pageStatus:a,loadedRowCount:null!=(o=e[t])?o:0}}),n}destroyRowAtIndex(e){const t=this.nodeMap.getBy("index",e);t&&(this.nodeMap.delete(t),this.nodeDisplayIndexMap.delete(t.node.rowIndex),this.nodesToRefresh.size>0?this.removedNodeCache.set(t.node.id,t.node):this.blockUtils.destroyRowNode(t.node),this.nodesToRefresh.delete(t.node))}getSsrmParams(){return this.store.getSsrmParams()}getPrefixedId(e){return this.defaultNodeIdPrefix?this.defaultNodeIdPrefix+"-"+e:e.toString()}markBlockForVerify(e){const[t,i]=this.getBlockBounds(e);this.nodeMap.filter(e=>e.index>=t&&e.index<i).forEach(({node:e})=>{e.__needsRefreshWhenVisible=!0})}doesNodeMatch(e,t){if(t.stub)return!1;if(null!=this.getRowIdFunc){const i=this.getRowId(e);return t.id===i}return t.data===e}purgeStubsOutsideOfViewport(){const e=this.api.getFirstDisplayedRowIndex(),t=this.api.getLastDisplayedRowIndex(),i=this.getBlockStartIndex(e),[r,n]=this.getBlockBounds(t);this.nodeMap.forEach(e=>{this.lazyBlockLoadingService.isRowLoading(this,e.index)||e.node.failedLoad||e.node.stub&&(e.index<i||e.index>n)&&this.destroyRowAtIndex(e.index)})}getBlocksDistanceFromRow(e,t){const i={};return e.forEach(({node:e,index:r})=>{const[n,s]=this.getBlockBounds(r);if(n in i)return;const o=Math.abs(e.rowIndex-t);let a;const l=this.nodeMap.getBy("index",[s-1]);l&&(a=Math.abs(l.node.rowIndex-t));const c=null==a||o<a?o:a;i[n]=c}),Object.entries(i)}purgeExcessRows(){var e;if(this.purgeStubsOutsideOfViewport(),null==this.store.getDisplayIndexEnd()||null==this.storeParams.maxBlocksInCache)return;const t=this.api.getFirstDisplayedRowIndex(),i=this.api.getLastDisplayedRowIndex(),r=new Set,n=new Set;this.nodeMap.forEach(({index:e,node:s})=>{const o=this.getBlockStartIndex(e);r.add(o),s.rowIndex>=t&&s.rowIndex<=i&&n.add(o)});const s=Math.max(n.size,null!=(e=this.storeParams.maxBlocksInCache)?e:0),o=r.size-s;if(o<=0)return;let a=Number.MAX_SAFE_INTEGER,l=Number.MIN_SAFE_INTEGER;n.forEach(e=>{a>e&&(a=e),l<e&&(l=e)});const c=this.nodeMap.filter(({node:e,index:t})=>{const i=this.getBlockStartIndex(t);return!(i>=a&&i<=l||this.isNodeCached(e))});if(0===c.length)return;const u=t+(i-t)/2,h=this.getBlocksDistanceFromRow(c,u),d=this.getBlockSize();h.sort((e,t)=>Math.sign(t[1]-e[1]));for(let e=0;e<Math.min(o,h.length);e++){const t=Number(h[e][0]);for(let e=t;e<t+d;e++){const t=this.nodeMap.getBy("index",e);t&&!this.isNodeCached(t.node)&&this.destroyRowAtIndex(e)}}}isNodeFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();return!!t&&(null==t.rowPinned&&t.rowIndex===e.rowIndex)}isNodeCached(e){return e.isExpandable()&&e.expanded||this.isNodeFocused(e)}extractDuplicateIds(e){if(null==this.getRowIdFunc)return[];const t=new Set,i=new Set;return e.forEach(e=>{const r=this.getRowId(e);t.has(r)?i.add(r):t.add(r)}),[...i]}onLoadSuccess(e,t,i){if(!this.live)return;const r=i.groupLevelInfo;if(this.store.setStoreInfo(r),null!=this.getRowIdFunc){const r=this.extractDuplicateIds(i.rowData);if(r.length>0){const i=r.join(", ");return console.warn(`AG Grid: Unable to display rows as duplicate row ids (${i}) were returned by the getRowId callback. Please modify the getRowId callback to provide unique ids.`),void this.onLoadFailed(e,t)}}i.pivotResultFields&&this.serverSideRowModel.generateSecondaryColumns(i.pivotResultFields);const n=this.nodesToRefresh.size>0;if(i.rowData.forEach((t,i)=>{var r;const n=e+i,s=this.nodeMap.getBy("index",n);if(!(null==(r=null==s?void 0:s.node)?void 0:r.stub))return s&&this.doesNodeMatch(t,s.node)?(this.blockUtils.updateDataIntoRowNode(s.node,t),this.nodesToRefresh.delete(s.node),void(s.node.__needsRefreshWhenVisible=!1)):void this.createRowAtIndex(n,t);this.createRowAtIndex(n,t)}),null!=i.rowCount&&-1!==i.rowCount)this.numberOfRows=i.rowCount,this.isLastRowKnown=!0;else if(t>i.rowData.length)this.numberOfRows=e+i.rowData.length,this.isLastRowKnown=!0;else if(!this.isLastRowKnown){const t=e+i.rowData.length+1;t>this.numberOfRows&&(this.numberOfRows=t)}this.isLastRowKnown&&this.nodeMap.filter(e=>e.index>=this.numberOfRows).forEach(e=>this.destroyRowAtIndex(e.index)),this.fireStoreUpdatedEvent();const s=0===this.nodesToRefresh.size;n&&s&&this.fireRefreshFinishedEvent()}fireRefreshFinishedEvent(){0===this.nodesToRefresh.size&&(this.removedNodeCache.forEach(e=>{this.blockUtils.destroyRowNode(e)}),this.removedNodeCache=new Map,this.store.fireRefreshFinishedEvent())}isStoreFullyLoaded(){const e=this.isLastRowKnown,t=this.nodeMap.getSize()===this.numberOfRows;if(!e||!t)return;if(this.nodesToRefresh.size>0)return;let i=-1;return null==this.nodeMap.find(e=>(i+=1,e.index!==i||!!e.node.__needsRefreshWhenVisible||!!e.node.stub))}isLastRowIndexKnown(){return this.isLastRowKnown}onLoadFailed(e,t){var i;if(!this.live)return;const r=this.nodesToRefresh.size>0;for(let r=e;r<e+t&&r<this.getRowCount();r++){let{node:e}=null!=(i=this.nodeMap.getBy("index",r))?i:{};e&&this.nodesToRefresh.delete(e),e&&e.stub||(e&&!e.stub&&this.destroyRowAtIndex(r),e=this.createRowAtIndex(r)),e.__needsRefreshWhenVisible=!1,e.failedLoad=!0}const n=0===this.nodesToRefresh.size;r&&n&&this.fireRefreshFinishedEvent(),this.fireStoreUpdatedEvent()}markNodesForRefresh(){this.nodeMap.forEach(e=>{e.node.stub&&!e.node.failedLoad||this.nodesToRefresh.add(e.node)}),this.lazyBlockLoadingService.queueLoadCheck(),this.isLastRowKnown&&0===this.numberOfRows&&(this.numberOfRows=1,this.isLastRowKnown=!1,this.fireStoreUpdatedEvent())}isNodeInCache(e){return!!this.nodeMap.getBy("id",e)}fireStoreUpdatedEvent(){this.live&&this.store.fireStoreUpdatedEvent()}getRowId(e){if(null==this.getRowIdFunc)return null;const{level:t}=this.store.getRowDetails(),i=this.store.getParentNode().getGroupKeys(),r=this.getRowIdFunc({data:e,parentKeys:i.length>0?i:void 0,level:t});return String(r)}getOrderedNodeMap(){const e={};return this.nodeMap.forEach(t=>e[t.index]=t),e}clearDisplayIndexes(){this.nodeDisplayIndexMap.clear()}clientSideSortRows(){const e=this.sortController.getSortOptions();if(!e.some(e=>null!=e.sort))return;const t=new Array(this.nodeMap.getSize());this.nodeMap.forEach(e=>t[e.index]=e.node),this.nodeMap.clear(),this.rowNodeSorter.doFullSort(t,e).forEach((e,t)=>{this.nodeMap.set({id:e.id,node:e,index:t})})}updateRowNodes(e){if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const t=[];return e.forEach(e=>{const i=this.getRowId(e),r=this.nodeMap.getBy("id",i);r&&(this.blockUtils.updateDataIntoRowNode(r.node,e),t.push(r.node))}),t}insertRowNodes(e,t){const i=this.store.getRowCount()-(this.store.getParentNode().sibling?1:0),r=null==t&&this.isLastRowKnown?i:t;if(null==r||i<r)return[];if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const n={};e.forEach(e=>{const t=this.getRowId(e);t&&this.isNodeInCache(t)||(n[t]=e)});const s=Object.values(n);let o=s.length;if(0===o)return[];const a=this.nodeMap.filter(e=>e.index>=r);return a.forEach(e=>this.nodeMap.delete(e)),a.forEach(e=>{this.nodeMap.set({node:e.node,index:e.index+o,id:e.id})}),this.numberOfRows+=o,s.map((e,t)=>this.createRowAtIndex(r+t,e))}removeRowNodes(e){if(null==this.getRowIdFunc)throw new Error("AG Grid: Transactions can only be applied when row ids are supplied.");const t=[],i=[];let r=0;const n=[...e],s=this.getOrderedNodeMap();let o=-1;for(let e in s){o+=1;const a=s[e],l=n.findIndex(e=>e===a.id);if(-1!==l){n.splice(l,1),this.destroyRowAtIndex(Number(e)),t.push(a.node),r+=1;continue}if(0===r)continue;const c=Number(e);o!==c&&i.push(a.node),this.nodeMap.delete(s[e]),this.nodeMap.set({id:a.id,node:a.node,index:c-r})}return this.numberOfRows-=this.isLastRowIndexKnown()?e.length:r,n.length>0&&i.length>0&&(i.forEach(e=>e.__needsRefreshWhenVisible=!0),this.lazyBlockLoadingService.queueLoadCheck()),t}getBlockSize(){return this.storeParams.cacheBlockSize||oh.DEFAULT_BLOCK_SIZE}getBlockStartIndex(e){return e-e%this.getBlockSize()}getBlockBounds(e){const t=this.getBlockStartIndex(e);return[t,t+this.getBlockSize()]}};rh([(0,r.dsm)("gridApi")],ah.prototype,"api",2),rh([(0,r.dsm)("ssrmBlockUtils")],ah.prototype,"blockUtils",2),rh([(0,r.dsm)("focusService")],ah.prototype,"focusService",2),rh([(0,r.dsm)("ssrmNodeManager")],ah.prototype,"nodeManager",2),rh([(0,r.dsm)("rowModel")],ah.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("rowNodeSorter")],ah.prototype,"rowNodeSorter",2),rh([(0,r.dsm)("sortController")],ah.prototype,"sortController",2),rh([(0,r.dsm)("lazyBlockLoadingService")],ah.prototype,"lazyBlockLoadingService",2),rh([r.o7C],ah.prototype,"init",1),rh([r.yah],ah.prototype,"destroyRowNodes",1);var lh=class extends r.XQb{constructor(e,t,i){super(),this.idSequence=new r.RI_,this.ssrmParams=e,this.parentRowNode=i,this.storeParams=t,this.level=i.level+1,this.group=!!e.rowGroupCols&&this.level<e.rowGroupCols.length,this.leafGroup=!!e.rowGroupCols&&this.level===e.rowGroupCols.length-1,this.info={}}init(){var e;let t=1;if(0===this.level&&(t=null!=(e=this.storeUtils.getServerSideInitialRowCount())?e:1,this.eventService.dispatchEventOnce({type:r.sVA.EVENT_ROW_COUNT_READY})),this.cache=this.createManagedBean(new ah(this,t,this.storeParams)),!this.gos.get("treeData")&&this.group){const e=this.ssrmParams.rowGroupCols[this.level];this.groupField=e.field,this.rowGroupColumn=this.columnModel.getRowGroupColumns()[this.level]}}destroyRowNodes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.destroyBean(this.cache)}applyRowData(e,t,i){this.cache.onLoadSuccess(t,i,e)}applyTransaction(e){var t,i,n;const s=this.gos.getCallback("getRowId");if(!s)return console.warn("AG Grid: getRowId callback must be implemented for transactions to work. Transaction was ignored."),{status:r.a8A.Cancelled};const o=this.gos.getCallback("isApplyServerSideTransaction");if(o&&!o({transaction:e,parentNode:this.parentRowNode,groupLevelInfo:this.info}))return{status:r.a8A.Cancelled};const a=this.cache.isStoreFullyLoaded();let l,c,u;if((null==(t=e.update)?void 0:t.length)&&(l=this.cache.updateRowNodes(e.update)),null==(i=e.add)?void 0:i.length){let t=e.addIndex;null!=t&&t<0&&(t=void 0),c=this.cache.insertRowNodes(e.add,t)}if(null==(n=e.remove)?void 0:n.length){const t=e.remove.map(e=>s({level:this.level,parentKeys:this.parentRowNode.getGroupKeys(),data:e})),i=[...new Set(t)];u=this.cache.removeRowNodes(i)}const h=this.gos.get("serverSideEnableClientSideSort"),d=(null==l?void 0:l.length)||(null==c?void 0:c.length);return a&&h&&d&&this.cache.clientSideSortRows(),this.updateSelectionAfterTransaction(l,u),{status:r.a8A.Applied,update:l,add:c,remove:u}}updateSelectionAfterTransaction(e,t){const i=[];null==e||e.forEach(e=>{e.isSelected()&&!e.selectable&&i.push(e)}),null==t||t.forEach(e=>{e.isSelected()&&i.push(e)}),i.length&&this.selectionService.setNodesSelected({newValue:!1,clearSelection:!1,nodes:i,source:"rowDataChanged"})}clearDisplayIndexes(){this.displayIndexStart=void 0,this.displayIndexEnd=void 0,this.cache.getNodes().forEach(e=>this.blockUtils.clearDisplayIndex(e.node)),this.parentRowNode.sibling&&this.blockUtils.clearDisplayIndex(this.parentRowNode.sibling),this.cache.clearDisplayIndexes()}getDisplayIndexStart(){return this.displayIndexStart}getDisplayIndexEnd(){return this.displayIndexEnd}getRowCount(){return this.parentRowNode.sibling?this.cache.getRowCount()+1:this.cache.getRowCount()}setRowCount(e,t){this.cache.setRowCount(e,t)}isDisplayIndexInStore(e){return 0!==this.cache.getRowCount()&&this.displayIndexStart<=e&&e<this.getDisplayIndexEnd()}setDisplayIndexes(e,t){this.displayIndexStart=e.peek(),this.topPx=t.value;const i=this.parentRowNode.level>-1&&this.gos.getGroupTotalRowCallback()({node:this.parentRowNode});i||this.parentRowNode.destroyFooter(),"top"===i&&(this.parentRowNode.createFooter(),this.blockUtils.setDisplayIndex(this.parentRowNode.sibling,e,t)),this.cache.setDisplayIndexes(e,t),"bottom"===i&&(this.parentRowNode.createFooter(),this.blockUtils.setDisplayIndex(this.parentRowNode.sibling,e,t)),this.displayIndexEnd=e.peek(),this.heightPx=t.value-this.topPx}forEachStoreDeep(e,t=new r.RI_){e(this,t.next()),this.cache.getNodes().forEach(i=>{const r=i.node.childStore;r&&r.forEachStoreDeep(e,t)})}forEachNodeDeep(e,t=new r.RI_){this.cache.getNodes().forEach(i=>{e(i.node,t.next());const r=i.node.childStore;r&&r.forEachNodeDeep(e,t)})}forEachNodeDeepAfterFilterAndSort(e,t=new r.RI_,i=!1){const n=this.parentRowNode.level>-1&&this.gos.getGroupTotalRowCallback()({node:this.parentRowNode});"top"===n&&e(this.parentRowNode.sibling,t.next());const s=this.cache.getOrderedNodeMap();for(let r in s){const n=s[r];e(n.node,t.next());const o=n.node.childStore;o&&o.forEachNodeDeepAfterFilterAndSort(e,t,i)}"bottom"===n&&e(this.parentRowNode.sibling,t.next())}retryLoads(){this.cache.getNodes().forEach(({node:e})=>{e.failedLoad&&(e.failedLoad=!1,e.__needsRefreshWhenVisible=!0,e.stub=!0)}),this.forEachChildStoreShallow(e=>e.retryLoads()),this.fireStoreUpdatedEvent()}getRowUsingDisplayIndex(e){return this.parentRowNode.sibling&&e===this.parentRowNode.sibling.rowIndex?this.parentRowNode.sibling:this.cache.getRowByDisplayIndex(e)}getRowBounds(e){var t;if(!this.isDisplayIndexInStore(e))return null;const i=this.cache.getNodeCachedByDisplayIndex(e);if(i){const t=this.blockUtils.extractRowBounds(i,e);if(t)return t}const{previousNode:r,nextNode:n}=null!=(t=this.cache.getSurroundingNodesByDisplayIndex(e))?t:{};if(r){const t=this.blockUtils.extractRowBounds(r.node,e);if(null!=t)return t}const s=this.gos.getRowHeightAsNumber();if(n){const t=(n.node.rowIndex-e)*s;return{rowTop:n.node.rowTop-t,rowHeight:s}}return{rowTop:this.topPx+this.heightPx-(this.getDisplayIndexEnd()-e)*s,rowHeight:s}}isPixelInRange(e){return e>=this.topPx&&e<this.topPx+this.heightPx}getRowIndexAtPixel(e){if(e<this.topPx)return this.getDisplayIndexStart();if(e>=this.topPx+this.heightPx)return this.getDisplayIndexEnd()-1;if(this.parentRowNode.sibling&&e>this.parentRowNode.sibling.rowTop&&e<this.parentRowNode.sibling.rowTop+this.parentRowNode.sibling.rowHeight)return this.parentRowNode.sibling.rowIndex;let t=Number.MAX_SAFE_INTEGER,i=null,r=Number.MAX_SAFE_INTEGER,n=null;if(this.cache.getNodes().forEach(({node:s})=>{const o=Math.abs(e-s.rowTop);s.rowTop<e?o<t&&(t=o,i=s):o<r&&(r=o,n=s)}),i){const t=this.blockUtils.getIndexAtPixel(i,e);if(null!=t)return t}const s=this.gos.getRowHeightAsNumber();if(n){const t=n.rowTop,i=Math.ceil((t-e)/s);return n.rowIndex-i}const o=this.topPx+this.heightPx,a=Math.floor((o-e)/s);return this.getDisplayIndexEnd()-a}getChildStore(e){return this.storeUtils.getChildStore(e,this,e=>{const t=this.cache.getNodes().find(t=>t.node.key==e);return t?t.node:null})}forEachChildStoreShallow(e){this.cache.getNodes().forEach(({node:t})=>{t.childStore&&e(t.childStore)})}refreshAfterSort(e){if(this.storeUtils.isServerSideSortAllLevels()||this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e)){const e=this.cache.isStoreFullyLoaded(),t=this.gos.get("serverSideEnableClientSideSort");if(!e||!t){const e=this.cache.getRowCount();return this.destroyBean(this.cache),void(this.cache=this.createManagedBean(new ah(this,e,this.storeParams)))}this.cache.clientSideSortRows()}this.forEachChildStoreShallow(t=>t.refreshAfterSort(e))}refreshAfterFilter(e){!this.storeUtils.isServerSideOnlyRefreshFilteredGroups()||this.storeUtils.isServerRefreshNeeded(this.parentRowNode,this.ssrmParams.rowGroupCols,e)?this.refreshStore(!0):this.forEachChildStoreShallow(t=>t.refreshAfterFilter(e))}refreshStore(e){if(e)return this.destroyBean(this.cache),this.cache=this.createManagedBean(new ah(this,1,this.storeParams)),void this.fireStoreUpdatedEvent();this.cache.markNodesForRefresh()}getTopLevelRowDisplayedIndex(e){const t=this.cache.getDisplayIndexFromStoreIndex(e);return null!=t?t:e}isLastRowIndexKnown(){return this.cache.isLastRowIndexKnown()}getRowNodesInRange(e,t){let i=!1;return r._.missing(e)&&!0,this.cache.getNodes().filter(({node:i})=>i.rowIndex>=e.rowIndex&&i.rowIndex<=t.rowIndex).map(({node:e})=>e)}addStoreStates(e){e.push({suppressInfiniteScroll:!1,route:this.parentRowNode.getGroupKeys(),rowCount:this.getRowCount(),lastRowIndexKnown:this.isLastRowIndexKnown(),info:this.info,maxBlocksInCache:this.storeParams.maxBlocksInCache,cacheBlockSize:this.storeParams.cacheBlockSize}),this.forEachChildStoreShallow(t=>t.addStoreStates(e))}getIdSequence(){return this.idSequence}getParentNode(){return this.parentRowNode}getRowDetails(){return{field:this.groupField,group:this.group,leafGroup:this.leafGroup,level:this.level,parent:this.parentRowNode,rowGroupColumn:this.rowGroupColumn}}getSsrmParams(){return this.ssrmParams}setStoreInfo(e){e&&Object.assign(this.info,e)}fireStoreUpdatedEvent(){const e={type:r.sVA.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(e)}fireRefreshFinishedEvent(){const e={type:r.sVA.EVENT_STORE_REFRESHED,route:this.parentRowNode.getRoute()};this.eventService.dispatchEvent(e)}getBlockStates(){return this.cache.getBlockStates()}getStoreBounds(){return{topPx:this.topPx,heightPx:this.heightPx}}getCache(){return this.cache}};rh([(0,r.dsm)("ssrmBlockUtils")],lh.prototype,"blockUtils",2),rh([(0,r.dsm)("ssrmStoreUtils")],lh.prototype,"storeUtils",2),rh([(0,r.dsm)("columnModel")],lh.prototype,"columnModel",2),rh([(0,r.dsm)("selectionService")],lh.prototype,"selectionService",2),rh([r.o7C],lh.prototype,"init",1),rh([r.yah],lh.prototype,"destroyRowNodes",1);var ch=class extends r.XQb{constructor(){super(...arguments),this.onRowHeightChanged_debounced=r._.debounce(this.onRowHeightChanged.bind(this),100),this.pauseStoreUpdateListening=!1,this.started=!1,this.managingPivotResultColumns=!1}ensureRowHeightsValid(){return!1}start(){this.started=!0,this.updateDatasource()}destroyDatasource(){this.datasource&&(this.datasource.destroy&&this.datasource.destroy(),this.rowRenderer.datasourceChanged(),this.datasource=void 0)}addEventListeners(){this.addManagedListener(this.eventService,r.sVA.EVENT_NEW_COLUMNS_LOADED,this.onColumnEverything.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_STORE_UPDATED,this.onStoreUpdated.bind(this));const e=this.resetRootStore.bind(this);this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_VALUE_CHANGED,e),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_CHANGED,e),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,e),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_PIVOT_MODE_CHANGED,e),this.addManagedPropertyListeners(["masterDetail","treeData","removePivotHeaderRowWhenSingleValueColumn","suppressServerSideInfiniteScroll","cacheBlockSize"],e),this.addManagedPropertyListener("rowHeight",()=>this.resetRowHeights()),this.verifyProps(),this.addManagedPropertyListener("serverSideDatasource",()=>this.updateDatasource())}updateDatasource(){const e=this.gos.get("serverSideDatasource");e&&this.setDatasource(e)}verifyProps(){this.gos.exists("initialGroupOrderComparator")&&r._.warnOnce("initialGroupOrderComparator cannot be used with Server Side Row Model."),this.gos.isRowSelection()&&!this.gos.exists("getRowId")&&r._.warnOnce("getRowId callback must be provided for Server Side Row Model selection to work correctly.")}setDatasource(e){this.started&&(this.destroyDatasource(),this.datasource=e,this.resetRootStore())}applyRowData(e,t,i){const r=this.getRootStore();if(!r)return;const n=r.getChildStore(i);n&&(n instanceof lh?n.applyRowData(e,t,e.rowData.length):n instanceof nh&&n.processServerResult(e))}isLastRowIndexKnown(){const e=this.getRootStore();return!!e&&e.isLastRowIndexKnown()}onColumnEverything(){if(!this.storeParams)return void this.resetRootStore();const e=this.columnsToValueObjects(this.columnModel.getRowGroupColumns()),t=this.columnsToValueObjects(this.columnModel.getValueColumns()),i=this.columnsToValueObjects(this.columnModel.getPivotColumns()),n=e=>{const t={};e.oldCols.forEach(e=>t[e.id]=e);const i=e.newCols.every(e=>{const i=t[e.id];return i&&delete t[e.id],i&&i.field===e.field&&i.aggFunc===e.aggFunc}),r=!e.allowRemovedColumns&&!!Object.values(t).length;return i&&!r},s=!r._.jsonEquals(this.storeParams.sortModel,this.sortController.getSortModel()),o=!n({oldCols:this.storeParams.rowGroupCols,newCols:e}),a=!n({oldCols:this.storeParams.pivotCols,newCols:i}),l=!!(null==e?void 0:e.length)&&!n({oldCols:this.storeParams.valueCols,newCols:t,allowRemovedColumns:!0});if(s||o||a||l)this.resetRootStore();else{const e=this.createStoreParams();this.storeParams.rowGroupCols=e.rowGroupCols,this.storeParams.pivotCols=e.pivotCols,this.storeParams.valueCols=e.valueCols}}destroyRootStore(){this.rootNode&&this.rootNode.childStore&&(this.rootNode.childStore=this.destroyBean(this.rootNode.childStore),this.nodeManager.clear())}refreshAfterSort(e,t){this.storeParams&&(this.storeParams.sortModel=e);const i=this.getRootStore();i&&(i.refreshAfterSort(t),this.onStoreUpdated())}generateSecondaryColumns(e){if(!this.pivotColDefService)return void r.syG.__assertRegistered(r.zsj.RowGroupingModule,"pivotResultFields",this.context.getGridId());const t=this.pivotColDefService.createColDefsFromFields(e);this.managingPivotResultColumns=!0,this.columnModel.setSecondaryColumns(t,"rowModelUpdated")}resetRowHeights(){const e=this.resetRowHeightsForAllRowNodes(),t=this.gos.getRowHeightForNode(this.rootNode);if(this.rootNode.setRowHeight(t.height,t.estimated),this.rootNode.sibling){const e=this.gos.getRowHeightForNode(this.rootNode.sibling);this.rootNode.sibling.setRowHeight(e.height,e.estimated)}e&&this.onRowHeightChanged()}resetRowHeightsForAllRowNodes(){let e=!1;return this.forEachNode(t=>{const i=this.gos.getRowHeightForNode(t);t.setRowHeight(i.height,i.estimated);const r=t.detailNode;if(r){const e=this.gos.getRowHeightForNode(r);r.setRowHeight(e.height,e.estimated)}if(t.sibling){const e=this.gos.getRowHeightForNode(t.sibling);r.setRowHeight(e.height,e.estimated)}e=!0}),e}resetRootStore(){this.destroyRootStore(),this.rootNode=new r.TUE(this.beans),this.rootNode.group=!0,this.rootNode.level=-1,this.datasource&&(this.storeParams=this.createStoreParams(),this.rootNode.childStore=this.createBean(this.storeFactory.createStore(this.storeParams,this.rootNode)),this.updateRowIndexesAndBounds()),this.managingPivotResultColumns&&(this.columnModel.setSecondaryColumns(null,"api"),this.managingPivotResultColumns=!1),this.dispatchModelUpdated(!0)}columnsToValueObjects(e){return e.map(e=>({id:e.getId(),aggFunc:e.getAggFunc(),displayName:this.columnModel.getDisplayNameForColumn(e,"model"),field:e.getColDef().field}))}createStoreParams(){const e=this.columnsToValueObjects(this.columnModel.getRowGroupColumns()),t=this.columnsToValueObjects(this.columnModel.getValueColumns()),i=this.columnsToValueObjects(this.columnModel.getPivotColumns()),n=this.gos.isGetRowHeightFunction();return{valueCols:t,rowGroupCols:e,pivotCols:i,pivotMode:this.columnModel.isPivotMode(),filterModel:this.filterManager.isAdvancedFilterEnabled()?this.filterManager.getAdvancedFilterModel():this.filterManager.getFilterModel(),sortModel:this.sortController.getSortModel(),datasource:this.datasource,lastAccessedSequence:new r.RI_,dynamicRowHeight:n}}getParams(){return this.storeParams}dispatchModelUpdated(e=!1){const t={type:r.sVA.EVENT_MODEL_UPDATED,animate:!e,keepRenderedRows:!e,newPage:!1,newData:!1};this.eventService.dispatchEvent(t)}onStoreUpdated(){this.pauseStoreUpdateListening||(this.updateRowIndexesAndBounds(),this.dispatchModelUpdated())}onRowHeightChangedDebounced(){this.onRowHeightChanged_debounced()}onRowHeightChanged(){this.updateRowIndexesAndBounds(),this.dispatchModelUpdated()}updateRowIndexesAndBounds(){const e=this.getRootStore();e&&e.setDisplayIndexes(new r.RI_,{value:0})}retryLoads(){const e=this.getRootStore();e&&(e.retryLoads(),this.onStoreUpdated())}getRow(e){const t=this.getRootStore();if(t)return t.getRowUsingDisplayIndex(e)}setPaused(e){this.pauseStoreUpdateListening=e}expandAll(e){this.pauseStoreUpdateListening=!0,this.forEachNode(t=>{t.stub||t.hasChildren()&&t.setExpanded(e)}),this.pauseStoreUpdateListening=!1,this.onStoreUpdated()}refreshAfterFilter(e,t){this.storeParams&&(this.storeParams.filterModel=e);const i=this.getRootStore();i&&(i.refreshAfterFilter(t),this.onStoreUpdated())}getRootStore(){if(this.rootNode&&this.rootNode.childStore)return this.rootNode.childStore}getRowCount(){const e=this.getRootStore();return e?e.getDisplayIndexEnd():0}getTopLevelRowCount(){const e=this.getRootStore();return e?e.getRowCount():1}getTopLevelRowDisplayedIndex(e){const t=this.getRootStore();return t?t.getTopLevelRowDisplayedIndex(e):e}getRowBounds(e){const t=this.getRootStore();return t?t.getRowBounds(e):{rowTop:0,rowHeight:this.gos.getRowHeightAsNumber()}}getBlockStates(){const e=this.getRootStore();if(!e)return;const t={};return e.forEachStoreDeep(e=>{if(e instanceof nh){const{id:i,state:r}=e.getBlockStateJson();t[i]=r}else{if(!(e instanceof lh))throw new Error("AG Grid: Unsupported store type");Object.entries(e.getBlockStates()).forEach(([e,i])=>{t[e]=i})}}),t}getRowIndexAtPixel(e){const t=this.getRootStore();return e<=0||!t?0:t.getRowIndexAtPixel(e)}isEmpty(){return!1}isRowsToRender(){return null!=this.getRootStore()&&this.getRowCount()>0}getType(){return"serverSide"}forEachNode(e){const t=this.getRootStore();t&&t.forEachNodeDeep(e)}forEachNodeAfterFilterAndSort(e,t=!1){const i=this.getRootStore();i&&i.forEachNodeDeepAfterFilterAndSort(e,void 0,t)}executeOnStore(e,t){if(!this.started)return!1;const i=this.getRootStore();if(!i)return!0;const r=i.getChildStore(e);return r&&t(r),!0}refreshStore(e={}){const t=e.route?e.route:[];this.executeOnStore(t,t=>t.refreshStore(1==e.purge))}getStoreState(){const e=[],t=this.getRootStore();return t&&t.addStoreStates(e),e}getNodesInRangeForSelection(e,t){if(!r._.exists(e))return[];if(!t)return[e];const i=e.rowIndex,n=t.rowIndex;if(null===i||null===n)return[e];const s=[],[o,a]=[i,n].sort((e,t)=>e-t);return this.forEachNode(e=>{const t=e.rowIndex;null==t||e.stub||t>=o&&t<=a&&s.push(e)}),s.length!==a-o+1?[e]:s}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i),i.detailNode&&i.detailNode.id===e&&(t=i.detailNode)}),t}isRowPresent(e){return!!this.getRowNode(e.id)}setRowCount(e,t){const i=this.getRootStore();if(i){if(i instanceof lh)return void i.setRowCount(e,t);console.error("AG Grid: Infinite scrolling must be enabled in order to set the row count.")}}};rh([(0,r.dsm)("columnModel")],ch.prototype,"columnModel",2),rh([(0,r.dsm)("filterManager")],ch.prototype,"filterManager",2),rh([(0,r.dsm)("sortController")],ch.prototype,"sortController",2),rh([(0,r.dsm)("rowRenderer")],ch.prototype,"rowRenderer",2),rh([(0,r.dsm)("ssrmNodeManager")],ch.prototype,"nodeManager",2),rh([(0,r.dsm)("ssrmStoreFactory")],ch.prototype,"storeFactory",2),rh([(0,r.dsm)("beans")],ch.prototype,"beans",2),rh([(0,r.Xx1)("pivotColDefService")],ch.prototype,"pivotColDefService",2),rh([r.yah],ch.prototype,"destroyDatasource",1),rh([r.o7C],ch.prototype,"addEventListeners",1),rh([r.yah],ch.prototype,"destroyRootStore",1),ch=rh([(0,r.dR4)("rowModel")],ch);var uh=class extends r.XQb{loadFromDatasource(e){const{storeParams:t,parentBlock:i,parentNode:r}=e,n=r.getGroupKeys();if(!t.datasource)return;const s={startRow:e.startRow,endRow:e.endRow,rowGroupCols:t.rowGroupCols,valueCols:t.valueCols,pivotCols:t.pivotCols,pivotMode:t.pivotMode,groupKeys:n,filterModel:t.filterModel,sortModel:t.sortModel},o=this.gos.addGridCommonParams({success:e.success,fail:e.fail,request:s,parentNode:e.parentNode});window.setTimeout(()=>{t.datasource&&i.isAlive()?t.datasource.getRows(o):e.fail()},0)}getChildStore(e,t,i){if(r._.missingOrEmpty(e))return t;const n=i(e[0]);if(n){if(1===e.length&&!n.childStore){const e=this.serverSideRowModel.getParams();n.childStore=this.createBean(this.storeFactory.createStore(e,n))}const t=e.slice(1,e.length),i=n.childStore;return i?i.getChildStore(t):null}return null}isServerRefreshNeeded(e,t,i){if(i.valueColChanged||i.secondaryColChanged)return!0;const r=e.level+1;if(!(r<t.length))return!0;const n=t[r].id;return i.changedColumns.indexOf(n)>-1||this.columnModel.getAllGridColumns().filter(e=>e.getColDef().showRowGroup&&i.changedColumns.includes(e.getId())).map(e=>e.getColDef().showRowGroup).some(e=>!0===e||e===n)}getServerSideInitialRowCount(){return this.gos.get("serverSideInitialRowCount")}assertRowModelIsServerSide(e){return!!this.gos.isRowModelType("serverSide")||(r._.warnOnce(`The '${e}' property can only be used with the Server Side Row Model.`),!1)}assertNotTreeData(e){return!this.gos.get("treeData")||(r._.warnOnce(`The '${e}' property cannot be used while using tree data.`),!1)}isServerSideSortAllLevels(){return this.gos.get("serverSideSortAllLevels")&&this.assertRowModelIsServerSide("serverSideSortAllLevels")}isServerSideOnlyRefreshFilteredGroups(){return this.gos.get("serverSideOnlyRefreshFilteredGroups")&&this.assertRowModelIsServerSide("serverSideOnlyRefreshFilteredGroups")}isServerSideSortOnServer(){return this.gos.get("serverSideSortOnServer")&&this.assertRowModelIsServerSide("serverSideSortOnServer")&&this.assertNotTreeData("serverSideSortOnServer")}isServerSideFilterOnServer(){return this.gos.get("serverSideFilterOnServer")&&this.assertRowModelIsServerSide("serverSideFilterOnServer")&&this.assertNotTreeData("serverSideFilterOnServer")}};rh([(0,r.dsm)("columnModel")],uh.prototype,"columnModel",2),rh([(0,r.dsm)("rowModel")],uh.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("ssrmStoreFactory")],uh.prototype,"storeFactory",2),uh=rh([(0,r.dR4)("ssrmStoreUtils")],uh);var hh=class extends r.XQb{createRowNode(e){const t=new r.TUE(this.beans),i=null!=e.rowHeight?e.rowHeight:this.gos.getRowHeightAsNumber();return t.setRowHeight(i),t.group=e.group,t.leafGroup=e.leafGroup,t.level=e.level,t.uiLevel=e.level,t.parent=e.parent,t.stub=!0,t.__needsRefreshWhenVisible=!1,t.group&&(t.expanded=!1,t.field=e.field,t.rowGroupColumn=e.rowGroupColumn),t}destroyRowNodes(e){e&&e.forEach(e=>this.destroyRowNode(e))}destroyRowNode(e,t=!1){e.childStore&&!t&&(this.destroyBean(e.childStore),e.childStore=null),e.sibling&&!e.footer&&this.destroyRowNode(e.sibling,!1),e.clearRowTopAndRowIndex(),null!=e.id&&this.nodeManager.removeNode(e)}setTreeGroupInfo(e){e.updateHasChildren();const t=this.gos.get("getServerSideGroupKey");e.hasChildren()&&null!=t&&(e.key=t(e.data)),e.hasChildren()||null==e.childStore||(this.destroyBean(e.childStore),e.childStore=null,e.expanded=!1)}setRowGroupInfo(e){e.key=this.valueService.getValue(e.rowGroupColumn,e),null!==e.key&&void 0!==e.key||r._.doOnce(()=>{console.warn("AG Grid: null and undefined values are not allowed for server side row model keys"),e.rowGroupColumn&&console.warn(`column = ${e.rowGroupColumn.getId()}`),console.warn("data is ",e.data)},"ServerSideBlock-CannotHaveNullOrUndefinedForKey"),this.beans.gos.getGroupTotalRowCallback()({node:e})&&(e.createFooter(),e.sibling&&(e.sibling.uiLevel=e.uiLevel+1))}setMasterDetailInfo(e){const t=this.gos.get("isRowMaster");e.master=null==t||t(e.data)}updateDataIntoRowNode(e,t){e.updateData(t),this.gos.get("treeData")?(this.setTreeGroupInfo(e),this.setChildCountIntoRowNode(e)):e.group?(this.setChildCountIntoRowNode(e),e.footer||(this.beans.gos.getGroupTotalRowCallback()({node:e})?e.sibling?e.sibling.updateData(t):e.createFooter():e.sibling&&e.destroyFooter())):this.gos.get("masterDetail")}setDataIntoRowNode(e,t,i,n){var s;e.stub=!1;const o=this.gos.get("treeData");r._.exists(t)?(e.setDataAndId(t,i),o?this.setTreeGroupInfo(e):e.group?this.setRowGroupInfo(e):this.gos.get("masterDetail")&&this.setMasterDetailInfo(e)):(e.setDataAndId(void 0,void 0),e.key=null),(o||e.group)&&(this.setGroupDataIntoRowNode(e),this.setChildCountIntoRowNode(e)),r._.exists(t)&&(e.setRowHeight(this.gos.getRowHeightForNode(e,!1,n).height),null==(s=e.sibling)||s.setRowHeight(this.gos.getRowHeightForNode(e.sibling,!1,n).height))}setChildCountIntoRowNode(e){const t=this.gos.get("getChildCount");t&&e.setAllChildrenCount(t(e.data))}setGroupDataIntoRowNode(e){const t=this.columnModel.getGroupDisplayColumns(),i=this.gos.get("treeData");t.forEach(t=>{if(null==e.groupData&&(e.groupData={}),i)e.groupData[t.getColId()]=e.key;else if(t.isRowGroupDisplayed(e.rowGroupColumn.getId())){const i=this.valueService.getValue(e.rowGroupColumn,e);e.groupData[t.getColId()]=i}})}clearDisplayIndex(e){e.clearRowTopAndRowIndex(),e.hasChildren()&&r._.exists(e.childStore)&&e.childStore.clearDisplayIndexes(),e.master&&e.detailNode&&e.detailNode.clearRowTopAndRowIndex()}setDisplayIndex(e,t,i){if(e.setRowIndex(t.next()),e.setRowTop(i.value),i.value+=e.rowHeight,!e.footer&&(e.master&&(e.expanded&&e.detailNode?(e.detailNode.setRowIndex(t.next()),e.detailNode.setRowTop(i.value),i.value+=e.detailNode.rowHeight):e.detailNode&&e.detailNode.clearRowTopAndRowIndex()),e.hasChildren()&&r._.exists(e.childStore))){const r=e.childStore;e.expanded?r.setDisplayIndexes(t,i):r.clearDisplayIndexes()}}binarySearchForDisplayIndex(e,t){let i=0,n=t.length-1;if(r._.missing(n)||r._.missing(i))console.warn(`AG Grid: error: topPointer = ${n}, bottomPointer = ${i}`);else for(;;){const r=Math.floor((i+n)/2),s=t[r];if(s.rowIndex===e)return s;const o=s.master&&s.expanded,a=s.detailNode;if(o&&a&&a.rowIndex===e)return s.detailNode;const l=s.childStore;if(s.expanded&&l&&l.isDisplayIndexInStore(e))return l.getRowUsingDisplayIndex(e);if(s.rowIndex<e)i=r+1;else{if(!(s.rowIndex>e))return void console.warn(`AG Grid: error: unable to locate rowIndex = ${e} in cache`);n=r-1}}}extractRowBounds(e,t){const i=e=>({rowHeight:e.rowHeight,rowTop:e.rowTop});if(e.rowIndex===t)return i(e);if(e.hasChildren()&&e.expanded&&r._.exists(e.childStore)){const i=e.childStore;if(i.isDisplayIndexInStore(t))return i.getRowBounds(t)}else if(e.master&&e.expanded&&r._.exists(e.detailNode)&&e.detailNode.rowIndex===t)return i(e.detailNode)}getIndexAtPixel(e,t){if(e.isPixelInRange(t))return e.rowIndex;const i=e.master&&e.expanded,n=e.detailNode;if(i&&n&&n.isPixelInRange(t))return e.detailNode.rowIndex;if(e.hasChildren()&&e.expanded&&r._.exists(e.childStore)){const i=e.childStore;if(i.isPixelInRange(t))return i.getRowIndexAtPixel(t)}return null}createNodeIdPrefix(e){const t=[];let i=e;for(;i&&i.level>=0;)""===i.key?t.push("ag-Grid-MissingKey"):t.push(i.key),i=i.parent;if(t.length>0)return t.reverse().join("-")}checkOpenByDefault(e){return this.expansionService.checkOpenByDefault(e)}};rh([(0,r.dsm)("valueService")],hh.prototype,"valueService",2),rh([(0,r.dsm)("columnModel")],hh.prototype,"columnModel",2),rh([(0,r.dsm)("ssrmNodeManager")],hh.prototype,"nodeManager",2),rh([(0,r.dsm)("beans")],hh.prototype,"beans",2),rh([(0,r.dsm)("expansionService")],hh.prototype,"expansionService",2),hh=rh([(0,r.dR4)("ssrmBlockUtils")],hh);var dh=class{constructor(){this.rowNodes={}}addRowNode(e){const t=e.id;this.rowNodes[t]&&(console.warn(`AG Grid: Duplicate node id ${e.id}. Row ID's are provided via the getRowId() callback. Please modify the getRowId() callback code to provide unique row id values.`),console.warn("first instance",this.rowNodes[t].data),console.warn("second instance",e.data)),this.rowNodes[t]=e}removeNode(e){const t=e.id;this.rowNodes[t]&&(this.rowNodes[t]=void 0)}clear(){this.rowNodes={}}};rh([r.yah],dh.prototype,"clear",1),dh=rh([(0,r.dR4)("ssrmNodeManager")],dh);var ph=class extends r.XQb{constructor(){super(...arguments),this.asyncTransactions=[]}postConstruct(){this.gos.isRowModelType("serverSide")}applyTransactionAsync(e,t){null==this.asyncTransactionsTimeout&&this.scheduleExecuteAsync(),this.asyncTransactions.push({transaction:e,callback:t})}scheduleExecuteAsync(){const e=this.gos.getAsyncTransactionWaitMillis();this.asyncTransactionsTimeout=window.setTimeout(()=>{this.executeAsyncTransactions()},e)}executeAsyncTransactions(){if(!this.asyncTransactions)return;const e=[],t=[],i=[];let n=!1;if(this.asyncTransactions.forEach(s=>{let o;this.serverSideRowModel.executeOnStore(s.transaction.route,e=>{o=e.applyTransaction(s.transaction)})?null==o&&(o={status:r.a8A.StoreNotFound}):o={status:r.a8A.StoreNotStarted},t.push(o),o.status==r.a8A.StoreLoading?i.push(s):(s.callback&&e.push(()=>s.callback(o)),o.status===r.a8A.Applied&&(n=!0))}),e.length>0&&window.setTimeout(()=>{e.forEach(e=>e())},0),this.asyncTransactionsTimeout=void 0,this.asyncTransactions=i,n&&(this.valueCache.onDataChanged(),this.eventService.dispatchEvent({type:r.sVA.EVENT_STORE_UPDATED})),t.length>0){const e={type:r.sVA.EVENT_ASYNC_TRANSACTIONS_FLUSHED,results:t};this.eventService.dispatchEvent(e)}}flushAsyncTransactions(){null!=this.asyncTransactionsTimeout&&clearTimeout(this.asyncTransactionsTimeout),this.executeAsyncTransactions()}applyTransaction(e){let t;if(this.serverSideRowModel.executeOnStore(e.route,i=>{t=i.applyTransaction(e)})){if(t){if(this.valueCache.onDataChanged(),t.remove){const i=t.remove.map(e=>e.id);this.selectionService.deleteSelectionStateFromParent(e.route||[],i)}return this.eventService.dispatchEvent({type:r.sVA.EVENT_STORE_UPDATED}),t}return{status:r.a8A.StoreNotFound}}return{status:r.a8A.StoreNotStarted}}};rh([(0,r.dsm)("rowNodeBlockLoader")],ph.prototype,"rowNodeBlockLoader",2),rh([(0,r.dsm)("valueCache")],ph.prototype,"valueCache",2),rh([(0,r.dsm)("rowModel")],ph.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("rowRenderer")],ph.prototype,"rowRenderer",2),rh([(0,r.dsm)("selectionService")],ph.prototype,"selectionService",2),rh([r.o7C],ph.prototype,"postConstruct",1),ph=rh([(0,r.dR4)("ssrmTransactionManager")],ph);var gh=class extends r.XQb{postConstruct(){this.gos.isRowModelType("serverSide")&&this.addManagedListener(this.eventService,r.sVA.EVENT_ROW_GROUP_OPENED,this.onRowGroupOpened.bind(this))}onRowGroupOpened(e){const t=e.node;if(t.expanded){if(t.master)this.createDetailNode(t);else if(r._.missing(t.childStore)){const e=this.serverSideRowModel.getParams();t.childStore=this.createBean(this.storeFactory.createStore(e,t))}}else this.gos.get("purgeClosedRowNodes")&&r._.exists(t.childStore)&&(t.childStore=this.destroyBean(t.childStore));const i={type:r.sVA.EVENT_STORE_UPDATED};this.eventService.dispatchEvent(i)}createDetailNode(e){if(r._.exists(e.detailNode))return e.detailNode;const t=new r.TUE(this.beans);t.detail=!0,t.selectable=!1,t.parent=e,r._.exists(e.id)&&(t.id="detail_"+e.id),t.data=e.data,t.level=e.level+1;const i=this.gos.getRowHeightForNode(t).height;return t.rowHeight=i||200,e.detailNode=t,t}};rh([(0,r.dsm)("rowModel")],gh.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("ssrmStoreFactory")],gh.prototype,"storeFactory",2),rh([(0,r.dsm)("beans")],gh.prototype,"beans",2),rh([r.o7C],gh.prototype,"postConstruct",1),gh=rh([(0,r.dR4)("ssrmExpandListener")],gh);var fh=class extends r.XQb{postConstruct(){this.gos.isRowModelType("serverSide")&&this.addManagedListener(this.eventService,r.sVA.EVENT_SORT_CHANGED,this.onSortChanged.bind(this))}onSortChanged(){const e=this.serverSideRowModel.getParams();if(!e)return;const t=this.sortController.getSortModel(),i=e.sortModel,r=this.findChangedColumnsInSort(t,i),n={valueColChanged:this.listenerUtils.isSortingWithValueColumn(r),secondaryColChanged:this.listenerUtils.isSortingWithSecondaryColumn(r),changedColumns:r};this.serverSideRowModel.refreshAfterSort(t,n)}findChangedColumnsInSort(e,t){let i=[];return[e,t].forEach(e=>{if(e){const t=e.map(e=>e.colId);i=i.concat(t)}}),i.filter(i=>{const r=t.find(e=>e.colId===i),n=e.find(e=>e.colId===i);return((e,t)=>(e?e.sort:null)!==(t?t.sort:null))(r,n)||((i,r)=>(i?t.indexOf(i):-1)!==(r?e.indexOf(r):-1))(r,n)})}};rh([(0,r.dsm)("sortController")],fh.prototype,"sortController",2),rh([(0,r.dsm)("rowModel")],fh.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("ssrmListenerUtils")],fh.prototype,"listenerUtils",2),rh([r.o7C],fh.prototype,"postConstruct",1),fh=rh([(0,r.dR4)("ssrmSortService")],fh);var mh=class extends r.XQb{postConstruct(){this.gos.isRowModelType("serverSide")&&(this.addManagedListener(this.eventService,r.sVA.EVENT_ADVANCED_FILTER_ENABLED_CHANGED,()=>this.onFilterChanged(!0)),this.addManagedListener(this.eventService,r.sVA.EVENT_FILTER_CHANGED,()=>this.onFilterChanged()))}onFilterChanged(e){const t=this.serverSideRowModel.getParams();if(!t)return;const i=t.filterModel;let r,n;if(this.filterManager.isAdvancedFilterEnabled()){r=this.filterManager.getAdvancedFilterModel();const t=e?Object.keys(null!=i?i:{}):this.getAdvancedFilterColumns(i),s=this.getAdvancedFilterColumns(r);t.forEach(e=>s.add(e)),n=Array.from(s)}else if(r=this.filterManager.getFilterModel(),e){const e=this.getAdvancedFilterColumns(i);Object.keys(r).forEach(t=>e.add(t)),n=Array.from(e)}else n=this.findChangedColumns(i,r);const s={valueColChanged:this.listenerUtils.isSortingWithValueColumn(n),secondaryColChanged:this.listenerUtils.isSortingWithSecondaryColumn(n),changedColumns:n};this.serverSideRowModel.refreshAfterFilter(r,s)}findChangedColumns(e,t){const i={};Object.keys(e).forEach(e=>i[e]=!0),Object.keys(t).forEach(e=>i[e]=!0);const r=[];return Object.keys(i).forEach(i=>{JSON.stringify(e[i])!=JSON.stringify(t[i])&&r.push(i)}),r}getAdvancedFilterColumns(e){const t=new Set;if(!e)return t;const i=e=>{"join"===e.filterType?e.conditions.forEach(e=>i(e)):t.add(e.colId)};return i(e),t}};rh([(0,r.dsm)("rowModel")],mh.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("filterManager")],mh.prototype,"filterManager",2),rh([(0,r.dsm)("ssrmListenerUtils")],mh.prototype,"listenerUtils",2),rh([r.o7C],mh.prototype,"postConstruct",1),mh=rh([(0,r.dR4)("ssrmFilterListener")],mh);var vh=class{createStore(e,t){const i=this.getStoreParams(e,t);return new(i.suppressInfiniteScroll?nh:lh)(e,i,t)}getStoreParams(e,t){const i=this.getLevelSpecificParams(t),r=this.isInfiniteScroll(i);return{suppressInfiniteScroll:!r,cacheBlockSize:this.getBlockSize(r,i),maxBlocksInCache:this.getMaxBlocksInCache(r,e,i)}}getMaxBlocksInCache(e,t,i){if(!e)return;const n=i&&null!=i.maxBlocksInCache?i.maxBlocksInCache:this.gos.get("maxBlocksInCache");if(null!=n&&n>=0){if(t.dynamicRowHeight){const e="Server Side Row Model does not support Dynamic Row Height and Cache Purging. Either a) remove getRowHeight() callback or b) remove maxBlocksInCache property. Purging has been disabled.";return void r._.warnOnce(e)}if(this.columnModel.isAutoRowHeightActive()){const e="Server Side Row Model does not support Auto Row Height and Cache Purging. Either a) remove colDef.autoHeight or b) remove maxBlocksInCache property. Purging has been disabled.";return void r._.warnOnce(e)}return n}}getBlockSize(e,t){if(!e)return;const i=t&&null!=t.cacheBlockSize?t.cacheBlockSize:this.gos.get("cacheBlockSize");return null!=i&&i>0?i:100}getLevelSpecificParams(e){const t=this.gos.getCallback("getServerSideGroupLevelParams");if(t)return t({level:e.level+1,parentRowNode:e.level>=0?e:void 0,rowGroupColumns:this.columnModel.getRowGroupColumns(),pivotColumns:this.columnModel.getPivotColumns(),pivotMode:this.columnModel.isPivotMode()})}isInfiniteScroll(e){return!(e&&null!=e.suppressInfiniteScroll?e.suppressInfiniteScroll:this.isSuppressServerSideInfiniteScroll())}isSuppressServerSideInfiniteScroll(){return this.gos.get("suppressServerSideInfiniteScroll")}};rh([(0,r.dsm)("gridOptionsService")],vh.prototype,"gos",2),rh([(0,r.dsm)("columnModel")],vh.prototype,"columnModel",2),vh=rh([(0,r.dR4)("ssrmStoreFactory")],vh);var Ch=class{isSortingWithValueColumn(e){const t=this.columnModel.getValueColumns().map(e=>e.getColId());for(let i=0;i<e.length;i++)if(t.indexOf(e[i])>-1)return!0;return!1}isSortingWithSecondaryColumn(e){if(!this.columnModel.getSecondaryColumns())return!1;const t=this.columnModel.getSecondaryColumns().map(e=>e.getColId());for(let i=0;i<e.length;i++)if(t.indexOf(e[i])>-1)return!0;return!1}};rh([(0,r.dsm)("columnModel")],Ch.prototype,"columnModel",2),Ch=rh([(0,r.dR4)("ssrmListenerUtils")],Ch);var yh=class extends r.XQb{constructor(){super(...arguments),this.selectedState={selectAll:!1,toggledNodes:new Set},this.lastSelected=null,this.selectAllUsed=!1,this.selectedNodes={}}init(){this.rowSelection=this.gos.get("rowSelection"),this.addManagedPropertyListener("rowSelection",e=>{this.rowSelection=e.currentValue})}getSelectedState(){return{selectAll:this.selectedState.selectAll,toggledNodes:[...this.selectedState.toggledNodes]}}setSelectedState(e){const t={selectAll:!1,toggledNodes:new Set};"object"==typeof e?"selectAll"in e&&"boolean"==typeof e.selectAll?(t.selectAll=e.selectAll,"toggledNodes"in e&&Array.isArray(e.toggledNodes)?(e.toggledNodes.forEach(e=>{"string"==typeof e?t.toggledNodes.add(e):console.warn(`AG Grid: Provided ids must be of string type. Invalid id provided: ${e}`)}),this.selectedState=t):console.error("AG Grid: `toggledNodes` must be an array of string ids.")):console.error("AG Grid: Select all status should be of boolean type."):console.error("AG Grid: The provided selection state should be an object.")}deleteSelectionStateFromParent(e,t){if(0===this.selectedState.toggledNodes.size)return!1;let i=!1;return t.forEach(e=>{this.selectedState.toggledNodes.delete(e)&&(i=!0)}),i}setNodesSelected(e){if(0===e.nodes.length)return 0;const t=e.clearSelection&&e.newValue&&!e.rangeSelect;if("multiple"!==this.rowSelection||t){if(e.nodes.length>1)throw new Error("AG Grid: cannot select multiple rows when rowSelection is set to 'single'");const t=e.nodes[0];return e.newValue?(this.selectedNodes={[t.id]:t},this.selectedState={selectAll:!1,toggledNodes:new Set([t.id])}):(this.selectedNodes={},this.selectedState={selectAll:!1,toggledNodes:new Set}),this.lastSelected=t.id,1}const i=t=>{e.newValue?this.selectedNodes[t.id]=t:delete this.selectedNodes[t.id];const i=t.selectable;e.newValue!==this.selectedState.selectAll&&i?this.selectedState.toggledNodes.add(t.id):this.selectedState.toggledNodes.delete(t.id)};if(e.rangeSelect&&this.lastSelected){if(e.nodes.length>1)throw new Error("AG Grid: cannot select multiple rows when using rangeSelect");const t=e.nodes[0],r=this.rowModel.getRowNode(this.lastSelected);return this.rowModel.getNodesInRangeForSelection(t,null!=r?r:null).forEach(i),this.lastSelected=t.id,1}return e.nodes.forEach(i),this.lastSelected=e.nodes[e.nodes.length-1].id,1}processNewRow(e){this.selectedNodes[e.id]&&(this.selectedNodes[e.id]=e)}isNodeSelected(e){const t=this.selectedState.toggledNodes.has(e.id);return this.selectedState.selectAll?!t:t}getSelectedNodes(){return this.selectAllUsed&&console.warn("AG Grid: getSelectedNodes and getSelectedRows functions cannot be used with select all functionality with the server-side row model.\n                Use `api.getServerSideSelectionState()` instead."),Object.values(this.selectedNodes)}getSelectedRows(){return this.getSelectedNodes().map(e=>e.data)}getSelectionCount(){return this.selectedState.selectAll?-1:this.selectedState.toggledNodes.size}clearOtherNodes(e,t){const i=this.selectedState.selectAll?1:this.selectedState.toggledNodes.size-1;this.selectedState={selectAll:!1,toggledNodes:new Set([e.id])},this.rowModel.forEachNode(i=>{i!==e&&i.selectThisNode(!1,void 0,t)});const n={type:r.sVA.EVENT_SELECTION_CHANGED,source:t};return this.eventService.dispatchEvent(n),i}isEmpty(){var e;return!this.selectedState.selectAll&&!(null==(e=this.selectedState.toggledNodes)?void 0:e.size)}selectAllRowNodes(e){this.selectedState={selectAll:!0,toggledNodes:new Set},this.selectedNodes={},this.selectAllUsed=!0}deselectAllRowNodes(e){this.selectedState={selectAll:!1,toggledNodes:new Set},this.selectedNodes={}}getSelectAllState(e,t){return this.selectedState.selectAll?!(this.selectedState.toggledNodes.size>0)||null:this.selectedState.toggledNodes.size>0&&null}};rh([(0,r.dsm)("rowModel")],yh.prototype,"rowModel",2),rh([r.o7C],yh.prototype,"init",1);var wh=class extends r.XQb{constructor(){super(...arguments),this.selectedState={selectAllChildren:!1,toggledNodes:new Map},this.lastSelected=null}init(){this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,()=>this.removeRedundantState()),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>this.selectionService.reset("rowGroupChanged"))}getSelectedState(){const e=this.gos.get("treeData"),t=(i,r,n)=>{const s={nodeId:n};if((e||r<=this.columnModel.getRowGroupColumns().length)&&(s.selectAllChildren=i.selectAllChildren),i.toggledNodes.size){const e=[];i.toggledNodes.forEach((i,n)=>{const s=t(i,r+1,n);e.push(s)}),s.toggledNodes=e}return s};return t(this.selectedState,0)}setSelectedState(e){const t=(e,i)=>{var r,n;if("object"!=typeof e)throw new Error("AG Grid: Each provided state object must be an object.");if("selectAllChildren"in e&&"boolean"!=typeof e.selectAllChildren)throw new Error("AG Grid: `selectAllChildren` must be a boolean value or undefined.");if("toggledNodes"in e){if(!Array.isArray(e.toggledNodes))throw new Error("AG Grid: `toggledNodes` must be an array.");if(!e.toggledNodes.every(e=>"object"==typeof e&&"nodeId"in e&&"string"==typeof e.nodeId))throw new Error("AG Grid: Every `toggledNode` requires an associated string id.")}const s=null!=(r=e.selectAllChildren)?r:!i,o=null==(n=e.toggledNodes)?void 0:n.map(e=>[e.nodeId,t(e,s)]);if(null==o?void 0:o.some(([e,t])=>s===t.selectAllChildren&&0===t.toggledNodes.size))throw new Error("\n                    AG Grid: AG Grid: Row selection state could not be parsed due to invalid data. Ensure all child state has toggledNodes or does not conform with the parent rule.\n                    Please rebuild the selection state and reapply it.\n                ");return{selectAllChildren:s,toggledNodes:new Map(o)}};try{this.selectedState=t(e,!!e.selectAllChildren)}catch(e){console.error(e.message)}}deleteSelectionStateFromParent(e,t){let i=this.selectedState;const r=[...e];for(;i&&r.length;)i=i.toggledNodes.get(r.pop());if(!i)return!1;let n=!1;return t.forEach(e=>{(null==i?void 0:i.toggledNodes.delete(e))&&(n=!0)}),n&&this.removeRedundantState(),n}setNodesSelected(e){const t=e,{nodes:i}=t,r=ih(t,["nodes"]);if(0===i.length)return 0;if(e.rangeSelect){if(i.length>1)throw new Error("AG Grid: cannot select multiple rows when using rangeSelect");const e=i[0],t=this.rowModel.getNodesInRangeForSelection(e,this.lastSelected).map(this.getRouteToNode).sort((e,t)=>t.length-e.length),n=new Set;return t.forEach(t=>{n.has(t[t.length-1])||(t.forEach(e=>n.add(e)),this.recursivelySelectNode(t,this.selectedState,th({node:e},r)))}),this.removeRedundantState(),this.lastSelected=e,1}return e.nodes.forEach(e=>{const t=this.getRouteToNode(e);var i;this.recursivelySelectNode(t,this.selectedState,(i=th({},r),qu(i,Qu({node:e}))))}),this.removeRedundantState(),this.lastSelected=e.nodes[e.nodes.length-1],1}isNodeSelected(e){const t=this.getRouteToNode(e);return this.isNodePathSelected(t,this.selectedState)}isNodePathSelected([e,...t],i){if(0===t.length){const t=i.toggledNodes.has(e.id);if(e.hasChildren()){const t=i.toggledNodes.get(e.id);if(t&&t.toggledNodes.size)return}return i.selectAllChildren?!t:t}if(i.toggledNodes.has(e.id)){const r=i.toggledNodes.get(e.id);if(r)return this.isNodePathSelected(t,r)}return!!i.selectAllChildren}getRouteToNode(e){const t=[];let i=e;for(;i.parent;)t.push(i),i=i.parent;return t.reverse()}removeRedundantState(){if(this.filterManager.isAnyFilterPresent())return;const e=(t=this.selectedState,i,r)=>{if(t.toggledNodes.forEach((i,r)=>{e(i,r,t)}),i){const e=this.rowModel.getRowNode(i),r=null==e?void 0:e.childStore;if((null==r?void 0:r.isLastRowIndexKnown())&&t.toggledNodes.size>=r.getRowCount()){for(const e of t.toggledNodes.entries()){const[t,i]=e;if(i.toggledNodes.size>0)return;if(!this.rowModel.getRowNode(t))return}t.selectAllChildren=!t.selectAllChildren,t.toggledNodes.clear()}}const n=0===t.toggledNodes.size,s=(null==r?void 0:r.selectAllChildren)===t.selectAllChildren;n&&s&&(null==r||r.toggledNodes.delete(i))};e()}recursivelySelectNode([e,...t],i,r){if(!e)return;if(!t.length){const t=e.selectable;if(i.selectAllChildren===r.newValue||!t)return void i.toggledNodes.delete(e.id);const n={selectAllChildren:r.newValue,toggledNodes:new Map};return void i.toggledNodes.set(e.id,n)}const n=i.toggledNodes.has(e.id),s=n?i.toggledNodes.get(e.id):{selectAllChildren:i.selectAllChildren,toggledNodes:new Map};n||i.toggledNodes.set(e.id,s),this.recursivelySelectNode(t,s,r),i.selectAllChildren===s.selectAllChildren&&0===s.toggledNodes.size&&i.toggledNodes.delete(e.id)}getSelectedNodes(){console.warn("AG Grid: `getSelectedNodes` and `getSelectedRows` functions cannot be used with `groupSelectsChildren` and the server-side row model.\n            Use `api.getServerSideSelectionState()` instead.");const e=[];return this.rowModel.forEachNode(t=>{t.isSelected()&&e.push(t)}),e}processNewRow(e){}getSelectedRows(){return this.getSelectedNodes().map(e=>e.data)}getSelectionCount(){return-1}isEmpty(){var e;return!this.selectedState.selectAllChildren&&!(null==(e=this.selectedState.toggledNodes)?void 0:e.size)}selectAllRowNodes(e){this.selectedState={selectAllChildren:!0,toggledNodes:new Map}}deselectAllRowNodes(e){this.selectedState={selectAllChildren:!1,toggledNodes:new Map}}getSelectAllState(e,t){return this.selectedState.selectAllChildren?!(this.selectedState.toggledNodes.size>0)||null:this.selectedState.toggledNodes.size>0&&null}};rh([(0,r.dsm)("rowModel")],wh.prototype,"rowModel",2),rh([(0,r.dsm)("columnModel")],wh.prototype,"columnModel",2),rh([(0,r.dsm)("filterManager")],wh.prototype,"filterManager",2),rh([(0,r.dsm)("rowModel")],wh.prototype,"serverSideRowModel",2),rh([(0,r.dsm)("selectionService")],wh.prototype,"selectionService",2),rh([r.o7C],wh.prototype,"init",1);var Sh=class extends r.XQb{init(){const e=this.gos.get("groupSelectsChildren");this.addManagedPropertyListener("groupSelectsChildren",e=>{this.destroyBean(this.selectionStrategy);const t=e.currentValue?wh:yh;this.selectionStrategy=this.createManagedBean(new t),this.shotgunResetNodeSelectionState();const i={type:r.sVA.EVENT_SELECTION_CHANGED,source:"api"};this.eventService.dispatchEvent(i)}),this.addManagedPropertyListener("rowSelection",()=>this.deselectAllRowNodes({source:"api"}));const t=e?wh:yh;this.selectionStrategy=this.createManagedBean(new t)}getSelectionState(){return this.selectionStrategy.getSelectedState()}setSelectionState(e,t){if(Array.isArray(e))return;this.selectionStrategy.setSelectedState(e),this.shotgunResetNodeSelectionState();const i={type:r.sVA.EVENT_SELECTION_CHANGED,source:t};this.eventService.dispatchEvent(i)}setNodesSelected(e){const t=e,{nodes:i}=t,n=ih(t,["nodes"]),s=this.gos.get("rowSelection");if(i.length>1&&"multiple"!==s)return console.warn("AG Grid: cannot multi select while rowSelection='single'"),0;if(i.length>1&&e.rangeSelect)return console.warn("AG Grid: cannot use range selection when multi selecting rows"),0;const o=th({nodes:i.filter(e=>e.selectable)},n);if(!o.nodes.length)return 0;const a=this.selectionStrategy.setNodesSelected(o);this.shotgunResetNodeSelectionState(o.source);const l={type:r.sVA.EVENT_SELECTION_CHANGED,source:o.source};return this.eventService.dispatchEvent(l),a}deleteSelectionStateFromParent(e,t){if(!this.selectionStrategy.deleteSelectionStateFromParent(e,t))return;this.shotgunResetNodeSelectionState();const i={type:r.sVA.EVENT_SELECTION_CHANGED,source:"api"};this.eventService.dispatchEvent(i)}shotgunResetNodeSelectionState(e){this.rowModel.forEachNode(t=>{if(t.stub)return;const i=this.selectionStrategy.isNodeSelected(t);i!==t.isSelected()&&t.selectThisNode(i,void 0,e)})}getSelectedNodes(){return this.selectionStrategy.getSelectedNodes()}getSelectedRows(){return this.selectionStrategy.getSelectedRows()}getSelectionCount(){return this.selectionStrategy.getSelectionCount()}syncInRowNode(e,t){this.selectionStrategy.processNewRow(e);const i=this.selectionStrategy.isNodeSelected(e);if(0!=i&&!e.selectable){this.selectionStrategy.setNodesSelected({nodes:[e],newValue:!1,source:"api"}),this.shotgunResetNodeSelectionState();const t={type:r.sVA.EVENT_SELECTION_CHANGED,source:"api"};return void this.eventService.dispatchEvent(t)}e.setSelectedInitialValue(i)}reset(){this.selectionStrategy.deselectAllRowNodes({source:"api"})}isEmpty(){return this.selectionStrategy.isEmpty()}hasNodesToSelect(e=!1,t=!1){return!0}selectAllRowNodes(e){(e.justCurrentPage||e.justFiltered)&&console.warn("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'"),this.selectionStrategy.selectAllRowNodes(e),this.rowModel.forEachNode(t=>{t.stub||t.selectThisNode(!0,void 0,e.source)});const t={type:r.sVA.EVENT_SELECTION_CHANGED,source:e.source};this.eventService.dispatchEvent(t)}deselectAllRowNodes(e){(e.justCurrentPage||e.justFiltered)&&console.warn("AG Grid: selecting just filtered only works when gridOptions.rowModelType='clientSide'"),this.selectionStrategy.deselectAllRowNodes(e),this.rowModel.forEachNode(t=>{t.stub||t.selectThisNode(!1,void 0,e.source)});const t={type:r.sVA.EVENT_SELECTION_CHANGED,source:e.source};this.eventService.dispatchEvent(t)}getSelectAllState(e,t){return this.selectionStrategy.getSelectAllState(e,t)}updateGroupsFromChildrenSelections(e,t){return!1}getBestCostNodeSelection(){console.warn("AG Grid: calling gridApi.getBestCostNodeSelection() is only possible when using rowModelType=`clientSide`.")}filterFromSelection(){}};rh([(0,r.dsm)("rowModel")],Sh.prototype,"rowModel",2),rh([r.o7C],Sh.prototype,"init",1),Sh=rh([(0,r.dR4)("selectionService")],Sh);var bh=class extends r.pkb{constructor(){super(...arguments),this.queuedRowIds=new Set}postConstruct(){super.postConstruct(),this.addManagedListener(this.eventService,r.sVA.EVENT_COLUMN_ROW_GROUP_CHANGED,()=>{this.queuedRowIds.clear()})}checkOpenByDefault(e){if(!e.isExpandable())return;if(this.queuedRowIds.has(e.id))return this.queuedRowIds.delete(e.id),void e.setExpanded(!0);const t=this.gos.getCallback("isServerSideGroupOpenByDefault");t&&t({data:e.data,rowNode:e})&&e.setExpanded(!0)}expandRows(e){e.forEach(e=>{const t=this.serverSideRowModel.getRowNode(e);t?t.setExpanded(!0):this.queuedRowIds.add(e)})}expandAll(e){this.serverSideRowModel.expandAll(e)}onGroupExpandedOrCollapsed(){}};rh([(0,r.dsm)("rowModel")],bh.prototype,"serverSideRowModel",2),bh=rh([(0,r.dR4)("expansionService")],bh);var Eh={version:"31.3.4",moduleName:r.zsj.ServerSideRowModelModule,rowModel:"serverSide",beans:[ch,gh,fh,uh,hh,dh,ph,mh,vh,Ch,Sh,bh,oh],dependantModules:[S]},Ah=Object.defineProperty,Th=Object.getOwnPropertyDescriptor,Mh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Th(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&Ah(t,i,s),s},Rh=class{constructor(e,t,i,r,n,s,o,a,l,c,u){this.rowModel=e,this.filterParams=t,this.createKey=i,this.caseFormat=r,this.columnModel=n,this.valueService=s,this.treeDataOrGrouping=o,this.treeData=a,this.getDataPath=l,this.groupAllowUnbalanced=c,this.addManagedListener=u}extractUniqueValuesAsync(e,t){return new r.oY$(i=>{if(this.rowModel.isRowDataLoaded())i(this.extractUniqueValues(e,t));else{const n=this.addManagedListener(r.sVA.EVENT_ROW_COUNT_READY,()=>{null==n||n(),i(this.extractUniqueValues(e,t))})}})}extractUniqueValues(e,t){const i=new Map,n=this.extractExistingFormattedKeys(t),s=new Set,o=this.treeData&&!!this.getDataPath,a=this.columnModel.getRowGroupColumns(),l=(e,o)=>{const a=this.caseFormat(e);if(!s.has(a)){s.add(a);let l=e,c=r._.makeNull(o);const u=null==n?void 0:n.get(a);null!=u&&(l=u,c=t.get(u)),i.set(l,c)}};return this.rowModel.forEachLeafNode(t=>{if(!t.data||!e(t))return;if(this.treeDataOrGrouping)return void this.addValueForTreeDataOrGrouping(t,o,a,l);let i=this.getValue(t);this.filterParams.convertValuesToStrings?this.addValueForConvertValuesToString(t,i,l):null!=i&&Array.isArray(i)?(i.forEach(e=>{l(this.createKey(e,t),e)}),0===i.length&&l(null,null)):l(this.createKey(i,t),i)}),i}addValueForConvertValuesToString(e,t,i){const n=this.createKey(t,e);null!=n&&Array.isArray(n)?(n.forEach(e=>{const t=r._.toStringOrNull(r._.makeNull(e));i(t,t)}),0===n.length&&i(null,null)):i(n,n)}addValueForTreeDataOrGrouping(e,t,i,n){var s;let o;if(t){if(null==(s=e.childrenAfterGroup)?void 0:s.length)return;o=this.getDataPath(e.data)}else o=i.map(t=>this.valueService.getKeyForNode(t,e)),o.push(this.getValue(e));o&&(o=o.map(e=>r._.toStringOrNull(r._.makeNull(e)))),!t&&this.groupAllowUnbalanced&&(null==o?void 0:o.some(e=>null==e))&&(o=o.filter(e=>null!=e)),n(this.createKey(o),o)}getValue(e){return this.filterParams.getValue(e)}extractExistingFormattedKeys(e){if(!e)return null;const t=new Map;return e.forEach((e,i)=>{t.set(this.caseFormat(i),i)}),t}},_h=class{};_h.SELECT_ALL="__AG_SELECT_ALL__",_h.ADD_SELECTION_TO_FILTER="__AG_ADD_SELECTION_TO_FILTER__";var Ph=class{constructor(e,t,i,r){this.valueService=e,this.valueFormatter=t,this.formatter=i,this.column=r,this.displayedKeys=[]}updateDisplayedValuesToAllAvailable(e,t,i){this.displayedKeys=Array.from(i)}updateDisplayedValuesToMatchMiniFilter(e,t,i,r,n){this.displayedKeys=[];for(let t of i)if(null==t)n&&this.displayedKeys.push(t);else{const i=e(t),n=this.valueService.formatValue(this.column,null,i,this.valueFormatter,!1);r(this.formatter(n))&&this.displayedKeys.push(t)}}getDisplayedValueCount(){return this.displayedKeys.length}getDisplayedItem(e){return this.displayedKeys[e]}getSelectAllItem(){return _h.SELECT_ALL}getAddSelectionToFilterItem(){return _h.ADD_SELECTION_TO_FILTER}getDisplayedKeys(){return this.displayedKeys}forEachDisplayedKey(e){this.displayedKeys.forEach(e)}someDisplayedKey(e){return this.displayedKeys.some(e)}hasGroups(){return!1}refresh(){}},xh=class e{constructor(e,t,i,r){this.formatter=e,this.treeListPathGetter=t,this.treeListFormatter=i,this.treeDataOrGrouping=r,this.allDisplayedItemsTree=[],this.activeDisplayedItemsFlat=[],this.selectAllItem={depth:0,filterPasses:!0,available:!0,treeKey:_h.SELECT_ALL,children:this.allDisplayedItemsTree,expanded:!0,key:_h.SELECT_ALL,parentTreeKeys:[]},this.addSelectionToFilterItem={depth:0,filterPasses:!0,available:!0,treeKey:_h.ADD_SELECTION_TO_FILTER,expanded:!0,key:_h.ADD_SELECTION_TO_FILTER,parentTreeKeys:[]}}updateDisplayedValuesToAllAvailable(e,t,i,r){"reload"===r?this.generateItemTree(e,t,i):"otherFilter"===r?(this.updateAvailable(i),this.updateExpandAll()):"miniFilter"===r&&(this.resetFilter(),this.updateExpandAll()),this.flattenItems()}updateDisplayedValuesToMatchMiniFilter(e,t,i,r,n,s){"reload"===s?this.generateItemTree(e,t,i):"otherFilter"===s&&this.updateAvailable(i),this.updateFilter(r,n),this.updateExpandAll(),this.flattenItems()}generateItemTree(e,t,i){var r;this.allDisplayedItemsTree=[],this.groupsExist=!1;const n=this.getTreeListPathGetter(e,i);for(let s of t){const t=null!=(r=n(e(s)))?r:[null];t.length>1&&(this.groupsExist=!0);const o=i.has(s);let a,l=this.allDisplayedItemsTree,c=[];t.forEach((e,i)=>{l||(l=[],a.children=l),a=l.find(t=>{var i;return(null==(i=t.treeKey)?void 0:i.toUpperCase())===(null==e?void 0:e.toUpperCase())}),a||(a={treeKey:e,depth:i,filterPasses:!0,expanded:!1,available:o,parentTreeKeys:c},i===t.length-1&&(a.key=s),l.push(a)),l=a.children,c=[...c,e]})}this.updateAvailable(i),this.selectAllItem.children=this.allDisplayedItemsTree,this.selectAllItem.expanded=!1}getTreeListPathGetter(t,i){if(this.treeListPathGetter)return this.treeListPathGetter;if(this.treeDataOrGrouping)return e=>e;let n=!1;for(const e of i){const i=t(e);if(i instanceof Date){n=!0;break}if(null!=i)break}return n?e.DATE_TREE_LIST_PATH_GETTER:(r._.warnOnce("property treeList=true for Set Filter params, but you did not provide a treeListPathGetter or values of type Date."),e=>[String(e)])}flattenItems(){this.activeDisplayedItemsFlat=[];const e=t=>{t.forEach(t=>{t.filterPasses&&t.available&&(this.activeDisplayedItemsFlat.push(t),t.children&&t.expanded&&e(t.children))})};e(this.allDisplayedItemsTree)}resetFilter(){const e=t=>{t.children&&t.children.forEach(t=>{e(t)}),t.filterPasses=!0};this.allDisplayedItemsTree.forEach(t=>e(t))}updateFilter(e,t){const i=i=>!!i.available&&(null==i.treeKey?t:e(this.formatter(this.treeListFormatter?this.treeListFormatter(i.treeKey,i.depth,i.parentTreeKeys):i.treeKey)));this.allDisplayedItemsTree.forEach(e=>this.recursiveItemCheck(e,!1,i,"filterPasses"))}getDisplayedValueCount(){return this.activeDisplayedItemsFlat.length}getDisplayedItem(e){return this.activeDisplayedItemsFlat[e]}getSelectAllItem(){return this.selectAllItem}getAddSelectionToFilterItem(){return this.addSelectionToFilterItem}getDisplayedKeys(){const e=[];return this.forEachDisplayedKey(t=>e.push(t)),e}forEachDisplayedKey(e){const t=(i,r)=>{i.children?i.expanded&&r||i.children.forEach(e=>{e.filterPasses&&t(e,!1)}):e(i.key)};this.activeDisplayedItemsFlat.forEach(e=>t(e,!0))}someDisplayedKey(e){const t=(i,r)=>i.children?(!i.expanded||!r)&&i.children.some(e=>!!e.filterPasses&&t(e,!1)):e(i.key);return this.activeDisplayedItemsFlat.some(e=>t(e,!0))}hasGroups(){return this.groupsExist}refresh(){this.updateExpandAll(),this.flattenItems()}updateExpandAll(){const e=(t,i,r)=>{for(const n of t){if(!n.filterPasses||!n.available||!n.children)continue;if(i=i||!!n.expanded,r=r||!n.expanded,i&&r)return;const t=e(n.children,i,r);if(void 0===t)return;t?i=!0:r=!0}return i&&r?void 0:i},t=this.getSelectAllItem();t.expanded=e(t.children,!1,!1)}recursiveItemCheck(e,t,i,r){let n=!1;e.children&&e.children.forEach(s=>{const o=this.recursiveItemCheck(s,t||i(e),i,r);n=n||o});const s=t||n||i(e);return e[r]=s,s}updateAvailable(e){const t=t=>e.has(t.key);this.allDisplayedItemsTree.forEach(e=>this.recursiveItemCheck(e,!1,t,"available"))}};xh.DATE_TREE_LIST_PATH_GETTER=e=>e?[String(e.getFullYear()),String(e.getMonth()+1),String(e.getDate())]:null;var Dh=xh,Ih=class{constructor({caseFormat:e}){this.filteringKeys=null,this.filteringKeysCaseFormatted=null,this.hasNoAppliedFilteringKeys=!1,this.caseFormat=e}allFilteringKeys(){return this.filteringKeys}allFilteringKeysCaseFormatted(){return this.filteringKeysCaseFormatted}noAppliedFilteringKeys(){return this.hasNoAppliedFilteringKeys}setFilteringKeys(e){this.filteringKeys=new Set(e),this.hasNoAppliedFilteringKeys=!this.filteringKeys||0===this.filteringKeys.size,this.filteringKeysCaseFormatted=new Set,this.filteringKeys.forEach(e=>this.filteringKeysCaseFormatted.add(this.caseFormat(e)))}addFilteringKey(e){null==this.filteringKeys&&(this.filteringKeys=new Set,this.filteringKeysCaseFormatted=new Set),this.filteringKeys.add(e),this.filteringKeysCaseFormatted.add(this.caseFormat(e)),this.hasNoAppliedFilteringKeys&&(this.hasNoAppliedFilteringKeys=!1)}hasCaseFormattedFilteringKey(e){return this.filteringKeysCaseFormatted.has(this.caseFormat(e))}hasFilteringKey(e){return this.filteringKeys.has(e)}reset(){this.filteringKeys=null,this.filteringKeysCaseFormatted=null,this.hasNoAppliedFilteringKeys=!1}},Lh=class e{constructor(e){this.localEventService=new r.USV,this.miniFilterText=null,this.addCurrentSelectionToFilter=!1,this.providedValues=null,this.allValues=new Map,this.availableKeys=new Set,this.selectedKeys=new Set,this.initialised=!1;const{usingComplexObjects:t,columnModel:i,valueService:n,treeDataTreeList:s,groupingTreeList:o,filterParams:a,gos:l,valueFormatter:c,addManagedListener:u}=e,{column:h,colDef:d,textFormatter:p,doesRowPassOtherFilter:g,suppressSorting:f,comparator:m,rowModel:v,values:C,caseSensitive:y,convertValuesToStrings:w,treeList:S,treeListPathGetter:b,treeListFormatter:E}=a;this.filterParams=a,this.gos=l,this.setIsLoading=e.setIsLoading,this.translate=e.translate,this.caseFormat=e.caseFormat,this.createKey=e.createKey,this.usingComplexObjects=!!e.usingComplexObjects,this.formatter=p||r.U$F.DEFAULT_FORMATTER,this.doesRowPassOtherFilters=g,this.suppressSorting=f||!1,this.convertValuesToStrings=!!w,this.filteringKeys=new Ih({caseFormat:this.caseFormat});const A=null!=m?m:d.comparator,T=!!s||!!o;this.compareByValue=!!(t&&A||T||S&&!b),this.entryComparator=T&&!A?this.createTreeDataOrGroupingComparator():!S||b||A?([e,t],[i,r])=>A(t,r):([e,t],[i,n])=>r._.defaultComparator(t,n),this.keyComparator=null!=A?A:r._.defaultComparator,this.caseSensitive=!!y;const M=l.get("getDataPath"),R=l.get("groupAllowUnbalanced");"clientSide"===v.getType()&&(this.clientSideValuesExtractor=new Rh(v,this.filterParams,this.createKey,this.caseFormat,i,n,T,!!s,M,R,u)),null==C?this.valuesType=2:(this.valuesType=Array.isArray(C)?0:1,this.providedValues=C),this.displayValueModel=S?new Dh(this.formatter,b,E,s||o):new Ph(n,c,this.formatter,h),this.updateAllValues().then(e=>this.resetSelectionState(e||[]))}addEventListener(e,t,i){this.localEventService.addEventListener(e,t,i)}removeEventListener(e,t,i){this.localEventService.removeEventListener(e,t,i)}updateOnParamsChange(e){return new r.oY$(t=>{const{values:i,textFormatter:n,suppressSorting:s}=e,o=this.providedValues,a=this.suppressSorting;if(this.filterParams=e,this.formatter=n||r.U$F.DEFAULT_FORMATTER,this.suppressSorting=s||!1,this.providedValues=null!=i?i:null,this.providedValues!==o||this.suppressSorting!==a){i&&0!==i.length?this.valuesType=Array.isArray(i)?0:1:(this.valuesType=2,this.providedValues=null);const e=this.getModel();this.updateAllValues().then(i=>{this.setModel(e).then(()=>t())})}else t()})}refreshValues(){return new r.oY$(e=>{this.allValuesPromise.then(()=>{const t=this.getModel();this.updateAllValues(),this.setModel(t).then(()=>e())})})}overrideValues(e){return new r.oY$(t=>{this.allValuesPromise.then(()=>{this.valuesType=0,this.providedValues=e,this.refreshValues().then(()=>t())})})}refreshAfterAnyFilterChanged(){return this.showAvailableOnly()?this.allValuesPromise.then(e=>(this.updateAvailableKeys(null!=e?e:[],"otherFilter"),!0)):r.oY$.resolve(!1)}isInitialised(){return this.initialised}updateAllValues(){return this.allValuesPromise=new r.oY$(e=>{switch(this.valuesType){case 2:this.getValuesFromRowsAsync(!1).then(t=>e(this.processAllValues(t)));break;case 0:e(this.processAllValues(this.uniqueValues(this.validateProvidedValues(this.providedValues))));break;case 1:{this.setIsLoading(!0);const t=this.providedValues,{column:i,colDef:r}=this.filterParams,n=this.gos.addGridCommonParams({success:t=>{this.setIsLoading(!1),e(this.processAllValues(this.uniqueValues(this.validateProvidedValues(t))))},colDef:r,column:i});window.setTimeout(()=>t(n),0);break}default:throw new Error("Unrecognised valuesType")}}),this.allValuesPromise.then(e=>this.updateAvailableKeys(e||[],"reload")).then(()=>this.initialised=!0),this.allValuesPromise}processAllValues(e){const t=this.sortKeys(e);return this.allValues=null!=e?e:new Map,t}validateProvidedValues(e){if(this.usingComplexObjects&&(null==e?void 0:e.length)){const t=e[0];t&&"object"!=typeof t&&"function"!=typeof t&&(null==this.createKey(t)?r._.warnOnce("Set Filter Key Creator is returning null for provided values and provided values are primitives. Please provide complex objects or set convertValuesToStrings=true in the filterParams. See https://www.ag-grid.com/javascript-data-grid/filter-set-filter-list/#filter-value-types"):r._.warnOnce("Set Filter has a Key Creator, but provided values are primitives. Did you mean to provide complex objects or enable convertValuesToStrings?"))}return e}setValuesType(e){this.valuesType=e}getValuesType(){return this.valuesType}isKeyAvailable(e){return this.availableKeys.has(e)}showAvailableOnly(){return 2===this.valuesType}updateAvailableKeys(t,i){const r=this.showAvailableOnly()?this.sortKeys(this.getValuesFromRows(!0)):t;this.availableKeys=new Set(r),this.localEventService.dispatchEvent({type:e.EVENT_AVAILABLE_VALUES_CHANGED}),this.updateDisplayedValues(i,t)}sortKeys(e){const t=null!=e?e:new Map;if(this.suppressSorting)return Array.from(t.keys());let i;return i=this.compareByValue?Array.from(t.entries()).sort(this.entryComparator).map(([e])=>e):Array.from(t.keys()).sort(this.keyComparator),this.filterParams.excelMode&&t.has(null)&&(i=i.filter(e=>null!=e),i.push(null)),i}getParamsForValuesFromRows(e=!1){return this.clientSideValuesExtractor?{predicate:t=>!e||this.doesRowPassOtherFilters(t),existingValues:e&&!this.caseSensitive?this.allValues:void 0}:(r._.doOnce(()=>{console.error("AG Grid: Set Filter cannot initialise because you are using a row model that does not contain all rows in the browser. Either use a different filter type, or configure Set Filter such that you provide it with values")},"setFilterValueNotCSRM"),null)}getValuesFromRows(e=!1){const t=this.getParamsForValuesFromRows(e);return t?this.clientSideValuesExtractor.extractUniqueValues(t.predicate,t.existingValues):null}getValuesFromRowsAsync(e=!1){const t=this.getParamsForValuesFromRows(e);return t?this.clientSideValuesExtractor.extractUniqueValuesAsync(t.predicate,t.existingValues):r.oY$.resolve(null)}setMiniFilter(e){return e=r._.makeNull(e),this.miniFilterText!==e&&(null===e&&this.setAddCurrentSelectionToFilter(!1),this.miniFilterText=e,this.updateDisplayedValues("miniFilter"),!0)}getMiniFilter(){return this.miniFilterText}updateDisplayedValues(e,t){if("expansion"===e)return void this.displayValueModel.refresh();if(null==this.miniFilterText)return void this.displayValueModel.updateDisplayedValuesToAllAvailable(e=>this.getValue(e),t,this.availableKeys,e);const i=this.caseFormat(this.formatter(this.miniFilterText)||""),r=e=>null!=e&&this.caseFormat(e).indexOf(i)>=0,n=!!this.filterParams.excelMode&&r(this.translate("blanks"));this.displayValueModel.updateDisplayedValuesToMatchMiniFilter(e=>this.getValue(e),t,this.availableKeys,r,n,e)}getDisplayedValueCount(){return this.displayValueModel.getDisplayedValueCount()}getDisplayedItem(e){return this.displayValueModel.getDisplayedItem(e)}getSelectAllItem(){return this.displayValueModel.getSelectAllItem()}getAddSelectionToFilterItem(){return this.displayValueModel.getAddSelectionToFilterItem()}hasSelections(){return this.filterParams.defaultToNothingSelected?this.selectedKeys.size>0:this.allValues.size!==this.selectedKeys.size}getKeys(){return Array.from(this.allValues.keys())}getValues(){return Array.from(this.allValues.values())}getValue(e){return this.allValues.get(e)}setAddCurrentSelectionToFilter(e){this.addCurrentSelectionToFilter=e}isInWindowsExcelMode(){return"windows"===this.filterParams.excelMode}isAddCurrentSelectionToFilterChecked(){return this.isInWindowsExcelMode()&&this.addCurrentSelectionToFilter}showAddCurrentSelectionToFilter(){return this.isInWindowsExcelMode()&&r._.exists(this.miniFilterText)&&this.miniFilterText.length>0}selectAllMatchingMiniFilter(e=!1){null==this.miniFilterText?this.selectedKeys=new Set(this.allValues.keys()):(e&&this.selectedKeys.clear(),this.displayValueModel.forEachDisplayedKey(e=>this.selectedKeys.add(e)))}deselectAllMatchingMiniFilter(){null==this.miniFilterText?this.selectedKeys.clear():this.displayValueModel.forEachDisplayedKey(e=>this.selectedKeys.delete(e))}selectKey(e){this.selectedKeys.add(e)}deselectKey(e){this.filterParams.excelMode&&this.isEverythingVisibleSelected()&&this.resetSelectionState(this.displayValueModel.getDisplayedKeys()),this.selectedKeys.delete(e)}isKeySelected(e){return this.selectedKeys.has(e)}isEverythingVisibleSelected(){return!this.displayValueModel.someDisplayedKey(e=>!this.isKeySelected(e))}isNothingVisibleSelected(){return!this.displayValueModel.someDisplayedKey(e=>this.isKeySelected(e))}getModel(){if(!this.hasSelections())return null;const e=this.isAddCurrentSelectionToFilterChecked()?this.filteringKeys.allFilteringKeys():null;if(e&&e.size>0){if(this.selectedKeys){const t=new Set([...Array.from(e),...Array.from(this.selectedKeys).filter(t=>!e.has(t))]);return Array.from(t)}return Array.from(e)}return Array.from(this.selectedKeys)}setModel(e){return this.allValuesPromise.then(t=>{if(null==e)this.resetSelectionState(null!=t?t:[]);else{this.selectedKeys.clear();const t=new Map;this.allValues.forEach((e,i)=>{t.set(this.caseFormat(i),i)}),e.forEach(e=>{const i=this.caseFormat(r._.makeNull(e)),n=t.get(i);void 0!==n&&this.selectKey(n)})}})}uniqueValues(e){const t=new Map,i=new Set;return(null!=e?e:[]).forEach(e=>{const n=r._.makeNull(e),s=this.convertAndGetKey(n),o=this.caseFormat(s);i.has(o)||(i.add(o),t.set(s,n))}),t}convertAndGetKey(e){return this.convertValuesToStrings?e:this.createKey(e)}resetSelectionState(e){this.filterParams.defaultToNothingSelected?this.selectedKeys.clear():this.selectedKeys=new Set(e)}hasGroups(){return this.displayValueModel.hasGroups()}createTreeDataOrGroupingComparator(){return([e,t],[i,n])=>{if(null==t)return null==n?0:-1;if(null==n)return 1;for(let e=0;e<t.length;e++){if(e>=n.length)return 1;const i=r._.defaultComparator(t[e],n[e]);if(0!==i)return i}return 0}}setAppliedModelKeys(e){this.filteringKeys.setFilteringKeys(e)}addToAppliedModelKeys(e){this.filteringKeys.addFilteringKey(e)}getAppliedModelKeys(){return this.filteringKeys.allFilteringKeys()}getCaseFormattedAppliedModelKeys(){return this.filteringKeys.allFilteringKeysCaseFormatted()}hasAppliedModelKey(e){return this.filteringKeys.hasCaseFormattedFilteringKey(e)}hasAnyAppliedModelKey(){return!this.filteringKeys.noAppliedFilteringKeys()}};Lh.EVENT_AVAILABLE_VALUES_CHANGED="availableValuesChanged";var Nh=Lh,Oh=class e extends r.uAl{constructor(t){var i;super(t.isGroup?e.GROUP_TEMPLATE:e.TEMPLATE),this.focusWrapper=t.focusWrapper,this.value=t.value,this.params=t.params,this.translate=t.translate,this.valueFormatter=t.valueFormatter,this.item=t.item,this.isSelected=t.isSelected,this.isTree=t.isTree,this.depth=null!=(i=t.depth)?i:0,this.isGroup=t.isGroup,this.groupsExist=t.groupsExist,this.isExpanded=t.isExpanded,this.hasIndeterminateExpandState=t.hasIndeterminateExpandState}init(){this.addDestroyFunc(()=>{var e;return null==(e=this.destroyCellRendererComponent)?void 0:e.call(this)}),this.render(),this.eCheckbox.setLabelEllipsis(!0).setValue(this.isSelected,!0).setDisabled(!!this.params.readOnly).getInputElement().setAttribute("tabindex","-1"),this.refreshVariableAriaLabels(),this.isTree&&(this.depth>0&&this.addCssClass("ag-set-filter-indent-"+this.depth),this.isGroup?this.setupExpansion():this.groupsExist&&this.addCssClass("ag-set-filter-add-group-indent"),r._.setAriaLevel(this.getAriaElement(),this.depth+1)),this.refreshAriaChecked(),this.params.readOnly||this.eCheckbox.onValueChange(e=>this.onCheckboxChanged(!!e))}getFocusableElement(){return this.focusWrapper}setupExpansion(){this.eGroupClosedIcon.appendChild(r._.createIcon("setFilterGroupClosed",this.gos,null)),this.eGroupOpenedIcon.appendChild(r._.createIcon("setFilterGroupOpen",this.gos,null)),this.addManagedListener(this.eGroupClosedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.addManagedListener(this.eGroupOpenedIcon,"click",this.onExpandOrContractClicked.bind(this)),this.hasIndeterminateExpandState&&(this.eGroupIndeterminateIcon.appendChild(r._.createIcon("setFilterGroupIndeterminate",this.gos,null)),this.addManagedListener(this.eGroupIndeterminateIcon,"click",this.onExpandOrContractClicked.bind(this))),this.setExpandedIcons(),this.refreshAriaExpanded()}onExpandOrContractClicked(){this.setExpanded(!this.isExpanded)}setExpanded(t,i){if(this.isGroup&&t!==this.isExpanded){this.isExpanded=t;const r={type:e.EVENT_EXPANDED_CHANGED,isExpanded:!!t,item:this.item};i||this.dispatchEvent(r),this.setExpandedIcons(),this.refreshAriaExpanded()}}setExpandedIcons(){r._.setDisplayed(this.eGroupClosedIcon,this.hasIndeterminateExpandState?!1===this.isExpanded:!this.isExpanded),r._.setDisplayed(this.eGroupOpenedIcon,!0===this.isExpanded),this.hasIndeterminateExpandState&&r._.setDisplayed(this.eGroupIndeterminateIcon,void 0===this.isExpanded)}onCheckboxChanged(t){this.isSelected=t;const i={type:e.EVENT_SELECTION_CHANGED,isSelected:t,item:this.item};this.dispatchEvent(i),this.refreshVariableAriaLabels(),this.refreshAriaChecked()}toggleSelected(){this.params.readOnly||this.setSelected(!this.isSelected)}setSelected(e,t){this.isSelected=e,this.eCheckbox.setValue(e,t),this.refreshAriaChecked()}refreshVariableAriaLabels(){if(!this.isTree)return;const e=this.localeService.getLocaleTextFunc(),t=this.eCheckbox.getValue(),i=void 0===t?e("ariaIndeterminate","indeterminate"):t?e("ariaVisible","visible"):e("ariaHidden","hidden"),n=e("ariaToggleVisibility","Press SPACE to toggle visibility");r._.setAriaLabelledBy(this.eCheckbox.getInputElement(),void 0),this.eCheckbox.setInputAriaLabel(`${n} (${i})`)}setupFixedAriaLabels(e){if(!this.isTree)return;const t=this.localeService.getLocaleTextFunc()("ariaFilterValue","Filter Value"),i=this.getAriaElement();r._.setAriaLabel(i,`${e} ${t}`),r._.setAriaDescribedBy(i,this.eCheckbox.getInputElement().id)}refreshAriaChecked(){const e=this.getAriaElement();r._.setAriaChecked(e,this.eCheckbox.getValue())}refreshAriaExpanded(){r._.setAriaExpanded(this.getAriaElement(),!!this.isExpanded)}refresh(e,t,i){var r,n;if(this.item=e,t!==this.isSelected&&this.setSelected(t,!0),this.setExpanded(i,!0),this.valueFunction){const e=this.valueFunction();this.setTooltipAndCellRendererParams(e,e),this.cellRendererComponent||this.renderCellWithoutCellRenderer()}if(this.cellRendererComponent&&!(null==(n=(r=this.cellRendererComponent).refresh)?void 0:n.call(r,this.cellRendererParams))){const e=this.cellRendererComponent;this.renderCell(),this.destroyBean(e)}}render(){const{params:{column:e}}=this;let{value:t}=this,i=null;"function"==typeof t?(this.valueFunction=t,i=this.valueFunction(),t=i):i=this.isTree?r._.toStringOrNull(t):this.getFormattedValue(e,t),this.setTooltipAndCellRendererParams(t,i),this.renderCell()}setTooltipAndCellRendererParams(e,t){const i="whenTruncated"===this.gos.get("tooltipShowMode");if(this.params.showTooltips&&(!i||!this.params.cellRenderer)){const n=null!=t?t:r._.toStringOrNull(e);let s;i&&(s=()=>{const e=this.eCheckbox.getGui().querySelector(".ag-label");return!e||e.scrollWidth>e.clientWidth}),this.setTooltip({newTooltipText:n,location:"setFilterValue",getColDef:()=>this.params.colDef,getColumn:()=>this.params.column,shouldDisplayTooltip:s})}this.cellRendererParams=this.gos.addGridCommonParams({value:e,valueFormatted:t,colDef:this.params.colDef,column:this.params.column,setTooltip:(e,t)=>{this.setTooltip({newTooltipText:e,getColDef:()=>this.params.colDef,getColumn:()=>this.params.column,location:"setFilterValue",shouldDisplayTooltip:t})}})}getTooltipParams(){const e=super.getTooltipParams();return e.location="setFilterValue",e.colDef=this.getComponentHolder(),this.isTree&&(e.level=this.depth),e}getFormattedValue(e,t){return this.valueService.formatValue(e,null,t,this.valueFormatter,!1)}renderCell(){const e=this.userComponentFactory.getSetFilterCellRendererDetails(this.params,this.cellRendererParams),t=e?e.newAgStackInstance():void 0;null!=t?t.then(e=>{e&&(this.cellRendererComponent=e,this.eCheckbox.setLabel(e.getGui()),this.destroyCellRendererComponent=()=>this.destroyBean(e))}):this.renderCellWithoutCellRenderer()}renderCellWithoutCellRenderer(){var e;let t=null!=(e=null==this.cellRendererParams.valueFormatted?this.cellRendererParams.value:this.cellRendererParams.valueFormatted)?e:this.translate("blanks");"string"!=typeof t&&(r._.warnOnce(`Set Filter Value Formatter must return string values. Please ensure the Set Filter Value Formatter returns string values for complex objects, or set convertValuesToStrings=true in the filterParams. See ${this.getFrameworkOverrides().getDocLink("filter-set-filter-list/#filter-value-types")}`),t=""),this.eCheckbox.setLabel(t),this.setupFixedAriaLabels(t)}getComponentHolder(){return this.params.column.getColDef()}};Oh.EVENT_SELECTION_CHANGED="selectionChanged",Oh.EVENT_EXPANDED_CHANGED="expandedChanged",Oh.GROUP_TEMPLATE='\n        <div class="ag-set-filter-item" aria-hidden="true">\n            <span class="ag-set-filter-group-icons">\n                <span class="ag-set-filter-group-closed-icon" ref="eGroupClosedIcon"></span>\n                <span class="ag-set-filter-group-opened-icon" ref="eGroupOpenedIcon"></span>\n                <span class="ag-set-filter-group-indeterminate-icon" ref="eGroupIndeterminateIcon"></span>\n            </span>\n            <ag-checkbox ref="eCheckbox" class="ag-set-filter-item-checkbox"></ag-checkbox>\n        </div>',Oh.TEMPLATE='\n        <div class="ag-set-filter-item">\n            <ag-checkbox ref="eCheckbox" class="ag-set-filter-item-checkbox"></ag-checkbox>\n        </div>',Mh([(0,r.dsm)("valueService")],Oh.prototype,"valueService",2),Mh([(0,r.dsm)("userComponentFactory")],Oh.prototype,"userComponentFactory",2),Mh([(0,r.PIB)("eCheckbox")],Oh.prototype,"eCheckbox",2),Mh([(0,r.PIB)("eGroupOpenedIcon")],Oh.prototype,"eGroupOpenedIcon",2),Mh([(0,r.PIB)("eGroupClosedIcon")],Oh.prototype,"eGroupClosedIcon",2),Mh([(0,r.PIB)("eGroupIndeterminateIcon")],Oh.prototype,"eGroupIndeterminateIcon",2),Mh([r.o7C],Oh.prototype,"init",1);var Fh=Oh,kh={loadingOoo:"Loading...",blanks:"(Blanks)",searchOoo:"Search...",selectAll:"(Select All)",selectAllSearchResults:"(Select All Search Results)",addCurrentSelectionToFilter:"Add current selection to filter",noMatches:"No matches."},Gh=class{getModelAsString(e,t){const{values:i}=e||t.getModel()||{},r=t.getValueModel();if(null==i||null==r)return"";const n=i.filter(e=>r.isKeyAvailable(e)),s=n.length;return`(${s}) ${n.slice(0,10).map(e=>t.getFormattedValue(e)).join(",")}${s>10?",...":""}`}},Vh=class extends r.Q5x{constructor(){super("setFilter"),this.valueModel=null,this.setFilterParams=null,this.virtualList=null,this.caseSensitive=!1,this.convertValuesToStrings=!1,this.treeDataTreeList=!1,this.groupingTreeList=!1,this.hardRefreshVirtualList=!1,this.noValueFormatterSupplied=!1,this.filterModelFormatter=new Gh,this.updateSetFilterOnParamsChange=e=>{var t;this.setFilterParams=e,this.convertValuesToStrings=!!e.convertValuesToStrings,this.caseSensitive=!!e.caseSensitive;const i=null!=(t=e.keyCreator)?t:e.colDef.keyCreator;this.setValueFormatter(e.valueFormatter,i,this.convertValuesToStrings,!!e.treeList,!!e.colDef.refData);const n=e.column.getId().startsWith(r.JPk);this.treeDataTreeList=this.gos.get("treeData")&&!!e.treeList&&n,this.getDataPath=this.gos.get("getDataPath"),this.groupingTreeList=!!this.columnModel.getRowGroupColumns().length&&!!e.treeList&&n,this.createKey=this.generateCreateKey(i,this.convertValuesToStrings,this.treeDataTreeList||this.groupingTreeList)}}postConstruct(){super.postConstruct()}updateUiVisibility(){}createBodyTemplate(){return`\n            <div class="ag-set-filter">\n                <div ref="eFilterLoading" class="ag-filter-loading ag-hidden">${this.translateForSetFilter("loadingOoo")}</div>\n                <ag-input-text-field class="ag-mini-filter" ref="eMiniFilter"></ag-input-text-field>\n                <div ref="eFilterNoMatches" class="ag-filter-no-matches ag-hidden">${this.translateForSetFilter("noMatches")}</div>\n                <div ref="eSetFilterList" class="ag-set-filter-list" role="presentation"></div>\n            </div>`}handleKeyDown(e){if(super.handleKeyDown(e),!e.defaultPrevented)switch(e.key){case r.DDm.SPACE:this.handleKeySpace(e);break;case r.DDm.ENTER:this.handleKeyEnter(e);break;case r.DDm.LEFT:this.handleKeyLeft(e);break;case r.DDm.RIGHT:this.handleKeyRight(e)}}handleKeySpace(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.toggleSelected()}handleKeyEnter(e){if(!this.setFilterParams)return;const{excelMode:t,readOnly:i}=this.setFilterParams||{};t&&!i&&(e.preventDefault(),this.onBtApply(!1,!1,e),"mac"===this.setFilterParams.excelMode&&this.eMiniFilter.getInputElement().select())}handleKeyLeft(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.setExpanded(!1)}handleKeyRight(e){var t;null==(t=this.getComponentForKeyEvent(e))||t.setExpanded(!0)}getComponentForKeyEvent(e){var t;if(!this.eSetFilterList.contains(this.gos.getActiveDomElement())||!this.virtualList)return;const i=this.virtualList.getLastFocusedRow();if(null==i)return;const r=this.virtualList.getComponentAt(i);if(null==r)return;e.preventDefault();const{readOnly:n}=null!=(t=this.setFilterParams)?t:{};return n?void 0:r}getCssIdentifier(){return"set-filter"}setModel(e){var t;return null==e&&null==(null==(t=this.valueModel)?void 0:t.getModel())?(this.setMiniFilter(null),r.oY$.resolve()):super.setModel(e)}refresh(e){var t,i,r;return!!super.refresh(e)&&(!["treeList","treeListFormatter","treeListPathGetter","keyCreator","convertValuesToStrings","caseSensitive","comparator","suppressSelectAll","excelMode"].some(t=>{var i;return e[t]!==(null==(i=this.setFilterParams)?void 0:i[t])})&&!this.haveColDefParamsChanged(e.colDef)&&(super.updateParams(e),this.updateSetFilterOnParamsChange(e),this.updateMiniFilter(),e.cellRenderer===(null==(t=this.setFilterParams)?void 0:t.cellRenderer)&&e.valueFormatter===(null==(i=this.setFilterParams)?void 0:i.valueFormatter)||this.checkAndRefreshVirtualList(),null==(r=this.valueModel)||r.updateOnParamsChange(e).then(()=>{var e;(null==(e=this.valueModel)?void 0:e.hasSelections())&&this.refreshFilterValues()}),!0))}haveColDefParamsChanged(e){var t;const i=null==(t=this.setFilterParams)?void 0:t.colDef;return["keyCreator","filterValueGetter"].some(t=>e[t]!==(null==i?void 0:i[t]))}setModelAndRefresh(e){return this.valueModel?this.valueModel.setModel(e).then(()=>this.checkAndRefreshVirtualList()):r.oY$.resolve()}resetUiToDefaults(){return this.setMiniFilter(null),this.setModelAndRefresh(null)}setModelIntoUi(e){this.setMiniFilter(null);const t=null==e?null:e.values;return this.setModelAndRefresh(t)}getModelFromUi(){if(!this.valueModel)throw new Error("Value model has not been created.");const e=this.valueModel.getModel();return e?{values:e,filterType:this.getFilterType()}:null}getFilterType(){return"set"}getValueModel(){return this.valueModel}areModelsEqual(e,t){return null==e&&null==t||null!=e&&null!=t&&r._.areEqual(e.values,t.values)}setParams(e){var t;this.applyExcelModeOptions(e),super.setParams(e),this.updateSetFilterOnParamsChange(e);const i=null!=(t=e.keyCreator)?t:e.colDef.keyCreator;this.valueModel=new Nh({filterParams:e,setIsLoading:e=>this.setIsLoading(e),translate:e=>this.translateForSetFilter(e),caseFormat:e=>this.caseFormat(e),createKey:this.createKey,valueFormatter:this.valueFormatter,usingComplexObjects:!!i,gos:this.gos,columnModel:this.columnModel,valueService:this.valueService,treeDataTreeList:this.treeDataTreeList,groupingTreeList:this.groupingTreeList,addManagedListener:(e,t)=>this.addManagedListener(this.eventService,e,t)}),this.initialiseFilterBodyUi(),this.addEventListenersForDataChanges()}onAddCurrentSelectionToFilterChange(e){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.setAddCurrentSelectionToFilter(e)}setValueFormatter(e,t,i,n,s){let o=e;if(!o){if(t&&!i&&!n)throw new Error("AG Grid: Must supply a Value Formatter in Set Filter params when using a Key Creator unless convertValuesToStrings is enabled");this.noValueFormatterSupplied=!0,s||(o=e=>r._.toStringOrNull(e.value))}this.valueFormatter=o}generateCreateKey(e,t,i){if(i&&!e)throw new Error("AG Grid: Must supply a Key Creator in Set Filter params when `treeList = true` on a group column, and Tree Data or Row Grouping is enabled.");return e?(t,i=null)=>{const n=this.getKeyCreatorParams(t,i);return r._.makeNull(e(n))}:t?e=>Array.isArray(e)?e:r._.makeNull(r._.toStringOrNull(e)):e=>r._.makeNull(r._.toStringOrNull(e))}getFormattedValue(e){var t;let i=this.valueModel.getValue(e);this.noValueFormatterSupplied&&(this.treeDataTreeList||this.groupingTreeList)&&Array.isArray(i)&&(i=r._.last(i));const n=this.valueService.formatValue(this.setFilterParams.column,null,i,this.valueFormatter,!1);return null!=(t=null==n?r._.toStringOrNull(i):n)?t:this.translateForSetFilter("blanks")}applyExcelModeOptions(e){"windows"===e.excelMode?(e.buttons||(e.buttons=["apply","cancel"]),null==e.closeOnApply&&(e.closeOnApply=!0)):"mac"===e.excelMode&&(e.buttons||(e.buttons=["reset"]),null==e.applyMiniFilterWhileTyping&&(e.applyMiniFilterWhileTyping=!0),null==e.debounceMs&&(e.debounceMs=500)),e.excelMode&&e.defaultToNothingSelected&&(e.defaultToNothingSelected=!1,r._.warnOnce('The Set Filter Parameter "defaultToNothingSelected" value was ignored because it does not work when "excelMode" is used.'))}addEventListenersForDataChanges(){this.isValuesTakenFromGrid()&&(this.addManagedListener(this.eventService,r.sVA.EVENT_CELL_VALUE_CHANGED,e=>{this.setFilterParams&&e.column===this.setFilterParams.column&&this.syncAfterDataChange()}),this.addManagedPropertyListeners(["treeData","getDataPath","groupAllowUnbalanced"],()=>{this.syncAfterDataChange()}))}syncAfterDataChange(){if(!this.valueModel)throw new Error("Value model has not been created.");return this.valueModel.refreshValues().then(()=>{this.checkAndRefreshVirtualList(),this.onBtApply(!1,!0)})}setIsLoading(e){r._.setDisplayed(this.eFilterLoading,e),e||(this.hardRefreshVirtualList=!0)}initialiseFilterBodyUi(){this.initVirtualList(),this.initMiniFilter()}initVirtualList(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const e=this.localeService.getLocaleTextFunc()("ariaFilterList","Filter List"),t=!!this.setFilterParams.treeList,i=this.virtualList=this.createBean(new r.wjn({cssIdentifier:"filter",ariaRole:t?"tree":"listbox",listName:e})),n=this.getRefElement("eSetFilterList");t&&n.classList.add("ag-set-filter-tree-list"),n&&n.appendChild(i.getGui());const{cellHeight:s}=this.setFilterParams;let o;null!=s&&i.setRowHeight(s),i.setComponentCreator((e,i)=>this.createSetListItem(e,t,i)),i.setComponentUpdater((e,t)=>this.updateSetListItem(e,t)),o=this.setFilterParams.suppressSelectAll?new Hh(this.valueModel):new Bh(this.valueModel,()=>this.isSelectAllSelected()),t&&(o=new zh(o)),i.setModel(o)}getSelectAllLabel(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const e=null!=this.valueModel.getMiniFilter()&&this.setFilterParams.excelMode?"selectAllSearchResults":"selectAll";return this.translateForSetFilter(e)}getAddSelectionToFilterLabel(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");return this.translateForSetFilter("addCurrentSelectionToFilter")}createSetListItem(e,t,i){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const r=this.valueModel.hasGroups(),{isSelected:n,isExpanded:s}=this.isSelectedExpanded(e),{value:o,depth:a,isGroup:l,hasIndeterminateExpandState:c,selectedListener:u,expandedListener:h}=this.newSetListItemAttributes(e,t),d={focusWrapper:i,value:o,params:this.setFilterParams,translate:e=>this.translateForSetFilter(e),valueFormatter:this.valueFormatter,item:e,isSelected:n,isTree:t,depth:a,groupsExist:r,isGroup:l,isExpanded:s,hasIndeterminateExpandState:c},p=this.createBean(new Fh(d));return p.addEventListener(Fh.EVENT_SELECTION_CHANGED,u),h&&p.addEventListener(Fh.EVENT_EXPANDED_CHANGED,h),p}newSetTreeItemAttributes(e,t){var i,r,n,s,o,a;if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const l=this.valueModel.hasGroups();return e.key===_h.SELECT_ALL?{value:()=>this.getSelectAllLabel(),isGroup:l,depth:e.depth,hasIndeterminateExpandState:!0,selectedListener:e=>this.onSelectAll(e.isSelected),expandedListener:e=>this.onExpandAll(e.item,e.isExpanded)}:e.key===_h.ADD_SELECTION_TO_FILTER?{value:()=>this.getAddSelectionToFilterLabel(),depth:e.depth,isGroup:!1,hasIndeterminateExpandState:!1,selectedListener:e=>{this.onAddCurrentSelectionToFilterChange(e.isSelected)}}:e.children?{value:null!=(n=null==(r=(i=this.setFilterParams).treeListFormatter)?void 0:r.call(i,e.treeKey,e.depth,e.parentTreeKeys))?n:e.treeKey,depth:e.depth,isGroup:!0,selectedListener:e=>this.onGroupItemSelected(e.item,e.isSelected),expandedListener:e=>this.onExpandedChanged(e.item,e.isExpanded)}:{value:null!=(a=null==(o=(s=this.setFilterParams).treeListFormatter)?void 0:o.call(s,e.treeKey,e.depth,e.parentTreeKeys))?a:e.treeKey,depth:e.depth,selectedListener:e=>this.onItemSelected(e.item.key,e.isSelected)}}newSetListItemAttributes(e,t){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");return this.isSetFilterModelTreeItem(e)?this.newSetTreeItemAttributes(e,t):e===_h.SELECT_ALL?{value:()=>this.getSelectAllLabel(),selectedListener:e=>this.onSelectAll(e.isSelected)}:e===_h.ADD_SELECTION_TO_FILTER?{value:()=>this.getAddSelectionToFilterLabel(),selectedListener:e=>{this.onAddCurrentSelectionToFilterChange(e.isSelected)}}:{value:this.valueModel.getValue(e),selectedListener:e=>this.onItemSelected(e.item,e.isSelected)}}updateSetListItem(e,t){const{isSelected:i,isExpanded:r}=this.isSelectedExpanded(e);t.refresh(e,i,r)}isSelectedExpanded(e){let t,i;return this.isSetFilterModelTreeItem(e)?(i=e.expanded,t=e.key===_h.SELECT_ALL?this.isSelectAllSelected():e.key===_h.ADD_SELECTION_TO_FILTER?this.valueModel.isAddCurrentSelectionToFilterChecked():e.children?this.areAllChildrenSelected(e):this.valueModel.isKeySelected(e.key)):t=e===_h.SELECT_ALL?this.isSelectAllSelected():e===_h.ADD_SELECTION_TO_FILTER?this.valueModel.isAddCurrentSelectionToFilterChecked():this.valueModel.isKeySelected(e),{isSelected:t,isExpanded:i}}isSetFilterModelTreeItem(e){return void 0!==(null==e?void 0:e.treeKey)}initMiniFilter(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{eMiniFilter:e,localeService:t}=this,i=t.getLocaleTextFunc();e.setDisplayed(!this.setFilterParams.suppressMiniFilter),e.setValue(this.valueModel.getMiniFilter()),e.onValueChange(()=>this.onMiniFilterInput()),e.setInputAriaLabel(i("ariaSearchFilterValues","Search filter values")),this.addManagedListener(e.getInputElement(),"keydown",e=>this.onMiniFilterKeyDown(e))}updateMiniFilter(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{eMiniFilter:e}=this;e.isDisplayed()!==!this.setFilterParams.suppressMiniFilter&&e.setDisplayed(!this.setFilterParams.suppressMiniFilter);const t=this.valueModel.getMiniFilter();e.getValue()!==t&&e.setValue(t)}afterGuiAttached(e){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");super.afterGuiAttached(e),this.resetExpansion(),this.refreshVirtualList();const{eMiniFilter:t}=this;t.setInputPlaceholder(this.translateForSetFilter("searchOoo")),e&&e.suppressFocus||t.getFocusableElement().focus()}afterGuiDetached(){var e,t;super.afterGuiDetached(),(null==(e=this.setFilterParams)?void 0:e.excelMode)&&this.resetMiniFilter();const i=this.getModel();!(null==(t=this.setFilterParams)?void 0:t.excelMode)&&this.areModelsEqual(i,this.getModelFromUi())||(this.resetUiToActiveModel(i),this.showOrHideResults())}applyModel(e="api"){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");this.setFilterParams.excelMode&&"rowDataUpdated"!==e&&this.valueModel.isEverythingVisibleSelected()&&this.valueModel.selectAllMatchingMiniFilter();const t=this.valueModel.showAddCurrentSelectionToFilter()&&this.valueModel.isAddCurrentSelectionToFilterChecked();if(t&&!this.getModel())return!1;const i=super.applyModel(e),r=this.getModel();return r?(t||this.valueModel.setAppliedModelKeys(new Set),r.values.forEach(e=>{this.valueModel.addToAppliedModelKeys(e)})):t||this.valueModel.setAppliedModelKeys(null),i}isModelValid(e){return!this.setFilterParams||!this.setFilterParams.excelMode||null==e||e.values.length>0}doesFilterPass(e){if(!this.setFilterParams||!this.valueModel||!this.valueModel.getCaseFormattedAppliedModelKeys())return!0;if(!this.valueModel.hasAnyAppliedModelKey())return!1;const{node:t,data:i}=e;if(this.treeDataTreeList)return this.doesFilterPassForTreeData(t,i);if(this.groupingTreeList)return this.doesFilterPassForGrouping(t);let r=this.getValueFromNode(t);return this.convertValuesToStrings?this.doesFilterPassForConvertValuesToString(t,r):null!=r&&Array.isArray(r)?0===r.length?this.valueModel.hasAppliedModelKey(null):r.some(e=>this.isInAppliedModel(this.createKey(e,t))):this.isInAppliedModel(this.createKey(r,t))}doesFilterPassForConvertValuesToString(e,t){const i=this.createKey(t,e);return null!=i&&Array.isArray(i)?0===i.length?this.valueModel.hasAppliedModelKey(null):i.some(e=>this.isInAppliedModel(e)):this.isInAppliedModel(i)}doesFilterPassForTreeData(e,t){var i;return!(null==(i=e.childrenAfterGroup)?void 0:i.length)&&this.isInAppliedModel(this.createKey(this.checkMakeNullDataPath(this.getDataPath(t))))}doesFilterPassForGrouping(e){const t=this.columnModel.getRowGroupColumns().map(t=>this.valueService.getKeyForNode(t,e));return t.push(this.getValueFromNode(e)),this.isInAppliedModel(this.createKey(this.checkMakeNullDataPath(t)))}checkMakeNullDataPath(e){return e&&(e=e.map(e=>r._.toStringOrNull(r._.makeNull(e)))),(null==e?void 0:e.some(e=>null==e))?null:e}isInAppliedModel(e){return this.valueModel.hasAppliedModelKey(e)}getValueFromNode(e){return this.setFilterParams.getValue(e)}getKeyCreatorParams(e,t=null){return{value:e,colDef:this.setFilterParams.colDef,column:this.setFilterParams.column,node:t,data:null==t?void 0:t.data,api:this.setFilterParams.api,columnApi:this.setFilterParams.columnApi,context:this.setFilterParams.context}}onNewRowsLoaded(){this.isValuesTakenFromGrid()&&this.syncAfterDataChange()}isValuesTakenFromGrid(){return!!this.valueModel&&2===this.valueModel.getValuesType()}setFilterValues(e){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.overrideValues(e).then(()=>{this.checkAndRefreshVirtualList(),this.onUiChanged()})}resetFilterValues(){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.setValuesType(2),this.syncAfterDataChange()}refreshFilterValues(){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.isInitialised()&&this.valueModel.refreshValues().then(()=>{this.checkAndRefreshVirtualList(),this.onUiChanged()})}onAnyFilterChanged(){setTimeout(()=>{if(this.isAlive()){if(!this.valueModel)throw new Error("Value model has not been created.");this.valueModel.refreshAfterAnyFilterChanged().then(e=>{e&&(this.checkAndRefreshVirtualList(),this.showOrHideResults())})}},0)}onMiniFilterInput(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.valueModel.setMiniFilter(this.eMiniFilter.getValue()))return;const{applyMiniFilterWhileTyping:e,readOnly:t}=this.setFilterParams||{};!t&&e?this.filterOnAllVisibleValues(!1):this.updateUiAfterMiniFilterChange()}updateUiAfterMiniFilterChange(){if(!this.setFilterParams)throw new Error("Set filter params have not been provided.");if(!this.valueModel)throw new Error("Value model has not been created.");const{excelMode:e,readOnly:t}=this.setFilterParams||{};null==e||t?this.checkAndRefreshVirtualList():null==this.valueModel.getMiniFilter()?this.resetUiToActiveModel(this.getModel()):(this.valueModel.selectAllMatchingMiniFilter(!0),this.checkAndRefreshVirtualList(),this.onUiChanged()),this.showOrHideResults()}showOrHideResults(){if(!this.valueModel)throw new Error("Value model has not been created.");const e=null!=this.valueModel.getMiniFilter()&&this.valueModel.getDisplayedValueCount()<1;r._.setDisplayed(this.eNoMatches,e),r._.setDisplayed(this.eSetFilterList,!e)}resetMiniFilter(){var e;this.eMiniFilter.setValue(null,!0),null==(e=this.valueModel)||e.setMiniFilter(null)}resetUiToActiveModel(e,t){this.setModelAndRefresh(null==e?null:e.values).then(()=>{this.onUiChanged(!1,"prevent"),null==t||t()})}handleCancelEnd(e){this.setMiniFilter(null),super.handleCancelEnd(e)}onMiniFilterKeyDown(e){const{excelMode:t,readOnly:i}=this.setFilterParams||{};e.key!==r.DDm.ENTER||t||i||this.filterOnAllVisibleValues()}filterOnAllVisibleValues(e=!0){const{readOnly:t}=this.setFilterParams||{};if(!this.valueModel)throw new Error("Value model has not been created.");if(t)throw new Error("Unable to filter in readOnly mode.");this.valueModel.selectAllMatchingMiniFilter(!0),this.checkAndRefreshVirtualList(),this.onUiChanged(!1,e?"immediately":"debounce"),this.showOrHideResults()}focusRowIfAlive(e){null!=e&&window.setTimeout(()=>{if(!this.virtualList)throw new Error("Virtual list has not been created.");this.isAlive()&&this.virtualList.focusRow(e)},0)}onSelectAll(e){if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.virtualList)throw new Error("Virtual list has not been created.");e?this.valueModel.selectAllMatchingMiniFilter():this.valueModel.deselectAllMatchingMiniFilter(),this.refreshAfterSelection()}onGroupItemSelected(e,t){const i=e=>{e.children?e.children.forEach(e=>i(e)):this.selectItem(e.key,t)};i(e),this.refreshAfterSelection()}onItemSelected(e,t){if(!this.valueModel)throw new Error("Value model has not been created.");if(!this.virtualList)throw new Error("Virtual list has not been created.");this.selectItem(e,t),this.refreshAfterSelection()}selectItem(e,t){t?this.valueModel.selectKey(e):this.valueModel.deselectKey(e)}onExpandAll(e,t){const i=e=>{e.filterPasses&&e.available&&e.children&&(e.children.forEach(e=>i(e)),e.expanded=t)};i(e),this.refreshAfterExpansion()}onExpandedChanged(e,t){e.expanded=t,this.refreshAfterExpansion()}refreshAfterExpansion(){const e=this.virtualList.getLastFocusedRow();this.valueModel.updateDisplayedValues("expansion"),this.checkAndRefreshVirtualList(),this.focusRowIfAlive(e)}refreshAfterSelection(){const e=this.virtualList.getLastFocusedRow();this.checkAndRefreshVirtualList(),this.onUiChanged(),this.focusRowIfAlive(e)}setMiniFilter(e){this.eMiniFilter.setValue(e),this.onMiniFilterInput()}getMiniFilter(){return this.valueModel?this.valueModel.getMiniFilter():null}checkAndRefreshVirtualList(){if(!this.virtualList)throw new Error("Virtual list has not been created.");this.virtualList.refresh(!this.hardRefreshVirtualList),this.hardRefreshVirtualList&&(this.hardRefreshVirtualList=!1)}getFilterKeys(){return this.valueModel?this.valueModel.getKeys():[]}getFilterValues(){return this.valueModel?this.valueModel.getValues():[]}getValues(){return this.getFilterKeys()}refreshVirtualList(){this.setFilterParams&&this.setFilterParams.refreshValuesOnOpen?this.refreshFilterValues():this.checkAndRefreshVirtualList()}translateForSetFilter(e){return this.localeService.getLocaleTextFunc()(e,kh[e])}isSelectAllSelected(){if(!this.setFilterParams||!this.valueModel)return!1;if(this.setFilterParams.defaultToNothingSelected){if(this.valueModel.hasSelections()&&this.valueModel.isEverythingVisibleSelected())return!0;if(this.valueModel.isNothingVisibleSelected())return!1}else{if(this.valueModel.hasSelections()&&this.valueModel.isNothingVisibleSelected())return!1;if(this.valueModel.isEverythingVisibleSelected())return!0}}areAllChildrenSelected(e){const t=e=>{if(e.children){let i=!1,r=!1;return e.children.some(e=>{if(!e.filterPasses||!e.available)return!1;const n=t(e);return void 0===n||(n?i=!0:r=!0,i&&r)})?void 0:i}return this.valueModel.isKeySelected(e.key)};return this.setFilterParams.defaultToNothingSelected?this.valueModel.hasSelections()&&t(e):t(e)}destroy(){null!=this.virtualList&&(this.virtualList.destroy(),this.virtualList=null),super.destroy()}caseFormat(e){return null==e||"string"!=typeof e||this.caseSensitive?e:e.toUpperCase()}resetExpansion(){var e,t;if(!(null==(e=this.setFilterParams)?void 0:e.treeList))return;const i=null==(t=this.valueModel)?void 0:t.getSelectAllItem();if(this.isSetFilterModelTreeItem(i)){const e=t=>{t.children&&(t.children.forEach(t=>e(t)),t.expanded=!1)};e(i),this.valueModel.updateDisplayedValues("expansion")}}getModelAsString(e){return this.filterModelFormatter.getModelAsString(e,this)}getPositionableElement(){return this.eSetFilterList}};Mh([(0,r.PIB)("eMiniFilter")],Vh.prototype,"eMiniFilter",2),Mh([(0,r.PIB)("eFilterLoading")],Vh.prototype,"eFilterLoading",2),Mh([(0,r.PIB)("eSetFilterList")],Vh.prototype,"eSetFilterList",2),Mh([(0,r.PIB)("eFilterNoMatches")],Vh.prototype,"eNoMatches",2),Mh([(0,r.dsm)("columnModel")],Vh.prototype,"columnModel",2),Mh([(0,r.dsm)("valueService")],Vh.prototype,"valueService",2);var Hh=class{constructor(e){this.model=e}getRowCount(){return this.model.getDisplayedValueCount()}getRow(e){return this.model.getDisplayedItem(e)}areRowsEqual(e,t){return e===t}},Bh=class{constructor(e,t){this.model=e,this.isSelectAllSelected=t}getRowCount(){const e=this.model.showAddCurrentSelectionToFilter()?2:1;return this.model.getDisplayedValueCount()+e}getRow(e){if(0===e)return this.model.getSelectAllItem();const t=this.model.showAddCurrentSelectionToFilter(),i=t?2:1;return 1===e&&t?this.model.getAddSelectionToFilterItem():this.model.getDisplayedItem(e-i)}areRowsEqual(e,t){return e===t}},zh=class{constructor(e){this.model=e}getRowCount(){return this.model.getRowCount()}getRow(e){return this.model.getRow(e)}areRowsEqual(e,t){return null==e&&null==t||null!=e&&null!=t&&e.treeKey===t.treeKey&&e.depth===t.depth}},Uh=class extends r.uAl{constructor(){super('\n            <div class="ag-floating-filter-input ag-set-floating-filter-input" role="presentation">\n                <ag-input-text-field ref="eFloatingFilterText"></ag-input-text-field>\n            </div>'),this.availableValuesListenerAdded=!1,this.filterModelFormatter=new Gh}destroy(){super.destroy()}init(e){this.params=e,this.eFloatingFilterText.setDisabled(!0).addGuiEventListener("click",()=>this.params.showParentFilter()),this.setParams(e)}setParams(e){const t=this.columnModel.getDisplayNameForColumn(e.column,"header",!0),i=this.localeService.getLocaleTextFunc();this.eFloatingFilterText.setInputAriaLabel(`${t} ${i("ariaFilterInput","Filter Input")}`)}onParamsUpdated(e){this.refresh(e)}refresh(e){this.params=e,this.setParams(e)}onParentModelChanged(e){this.updateFloatingFilterText(e)}parentSetFilterInstance(e){this.params.parentFilterInstance(t=>{if(!(t instanceof Vh))throw new Error("AG Grid - SetFloatingFilter expects SetFilter as its parent");e(t)})}addAvailableValuesListener(){this.parentSetFilterInstance(e=>{const t=e.getValueModel();t&&this.addManagedListener(t,Nh.EVENT_AVAILABLE_VALUES_CHANGED,()=>this.updateFloatingFilterText())}),this.availableValuesListenerAdded=!0}updateFloatingFilterText(e){this.availableValuesListenerAdded||this.addAvailableValuesListener(),this.parentSetFilterInstance(t=>{this.eFloatingFilterText.setValue(this.filterModelFormatter.getModelAsString(e,t))})}};Mh([(0,r.PIB)("eFloatingFilterText")],Uh.prototype,"eFloatingFilterText",2),Mh([(0,r.dsm)("columnModel")],Uh.prototype,"columnModel",2);var Wh={version:"31.3.4",moduleName:r.zsj.SetFilterModule,beans:[],userComponents:[{componentName:"agSetColumnFilter",componentClass:Vh},{componentName:"agSetColumnFloatingFilter",componentClass:Uh}],dependantModules:[S]},jh=Object.defineProperty,Kh=Object.getOwnPropertyDescriptor,$h=Object.getOwnPropertySymbols,qh=Object.prototype.hasOwnProperty,Yh=Object.prototype.propertyIsEnumerable,Qh=(e,t,i)=>t in e?jh(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,Xh=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?Kh(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&jh(t,i,s),s},{extent:Zh,isNumber:Jh,isString:ed,isStringObject:td,isDate:id,createId:rd,Padding:nd}=n._Util,{LinearScale:sd,BandScale:od,TimeScale:ad}=n._Scale,ld=class{constructor(){this.type="category",this.stroke="rgb(204, 214, 235)",this.strokeWidth=1}},cd=class e{constructor(){this.id=rd(this),this.seriesRect={x:0,y:0,width:0,height:0},this._context=void 0,this._container=void 0,this._data=void 0,this.padding=new nd(3),this.xKey="x",this.yKey="y",this.dataType=void 0,this.xData=[],this.yData=[],this.min=void 0,this.max=void 0,this.yScale=new sd,this.axis=new ld,this.highlightStyle={size:6,fill:"yellow",stroke:"silver",strokeWidth:1},this._width=100,this._height=100,this.smallestInterval=void 0,this.layoutId=0,this.defaultDateFormatter=new Intl.DateTimeFormat("en-US",{year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1}),this._onMouseMove=this.onMouseMove.bind(this),this._onMouseOut=this.onMouseOut.bind(this);const t=new n._Scene.Group;this.rootGroup=t;const i=document.createElement("div");i.setAttribute("class","ag-sparkline-wrapper");const r=new n._Scene.Scene({});this.scene=r,this.canvasElement=r.canvas.element,r.setRoot(t),r.setContainer(i),this.resizeAndSetDimensions(this.width,this.height),e.tooltipDocuments.includes(document)||this.initialiseTooltipStyles(),this.setupDomEventListeners(this.canvasElement)}set context(e){this._context!==e&&(this._context=e)}get context(){return this._context}set container(e){if(this._container!==e){const{parentNode:t}=this.canvasElement;null!=t&&t.removeChild(this.canvasElement),e&&e.appendChild(this.canvasElement),this._container=e}}get container(){return this._container}set data(e){this._data!==e&&(this._data=e,this.processData(),this.mouseMoveEvent&&this.highlightedDatum&&this.updateHitPoint(this.mouseMoveEvent))}get data(){return this._data}resizeAndSetDimensions(e,t){this.scene.resize(e,t),this.seriesRect.width=e,this.seriesRect.height=t}initialiseTooltipStyles(){const t=document.createElement("style");t.innerHTML="\n.ag-sparkline-tooltip-wrapper {\n    position: absolute;\n    user-select: none;\n    pointer-events: none;\n}\n\n.ag-sparkline-tooltip {\n    position: relative;\n    font: 12px arial,sans-serif;\n    border-radius: 2px;\n    box-shadow: 0 1px 3px rgb(0 0 0 / 20%), 0 1px 1px rgb(0 0 0 / 14%);\n    line-height: 1.7em;\n    overflow: hidden;\n    white-space: nowrap;\n    z-index: 99999;\n    background-color: rgb(255, 255, 255);\n    color: rgba(0,0,0, 0.67);\n}\n\n.ag-sparkline-tooltip-content {\n    padding: 0 7px;\n    opacity: 1;\n}\n\n.ag-sparkline-tooltip-title {\n    padding-left: 7px;\n    opacity: 1;\n}\n\n.ag-sparkline-tooltip-wrapper-hidden {\n    top: -10000px !important;\n}\n\n.ag-sparkline-wrapper {\n    box-sizing: border-box;\n    overflow: hidden;\n}\n",document.head.insertBefore(t,document.head.querySelector("style")),e.tooltipDocuments.push(document)}set width(e){this._width!==e&&(this._width=e,this.scene.resize(e,this.height),this.scheduleLayout())}get width(){return this._width}set height(e){this._height!==e&&(this._height=e,this.scene.resize(this.width,e),this.scheduleLayout())}get height(){return this._height}update(){}updateYScale(){this.updateYScaleRange(),this.updateYScaleDomain()}updateYScaleDomain(){}updateYScaleRange(){const{yScale:e,seriesRect:t}=this;e.range=[t.height,0]}updateXScale(){const{type:e}=this.axis;this.xScale=this.getXScale(e),this.updateXScaleRange(),this.updateXScaleDomain()}updateXScaleRange(){this.xScale.range=[0,this.seriesRect.width]}updateXScaleDomain(){const{xData:e,xScale:t}=this;let i;(t instanceof sd||t instanceof ad)&&(i=Zh(e)),this.xScale.domain=i?i.slice():e}getXScale(e="category"){switch(e){case"number":return new sd;case"time":return new ad;default:return new od}}updateAxisLine(){}updateAxes(){this.updateYScale(),this.updateXScale(),this.updateAxisLine()}updateCrosshairs(){this.updateXCrosshairLine(),this.updateYCrosshairLine()}generateNodeData(){return[]}getNodeData(){return[]}updateNodes(){}updateXCrosshairLine(){}updateYCrosshairLine(){}highlightDatum(e){this.updateNodes()}dehighlightDatum(){this.highlightedDatum=void 0,this.updateNodes(),this.updateCrosshairs()}onMouseMove(e){this.mouseMoveEvent=e,this.updateHitPoint(e)}updateHitPoint(e){var t,i,r;const n=this.pickClosestSeriesNodeDatum(e.offsetX,e.offsetY);if(!n)return;const s=this.highlightedDatum;this.highlightedDatum=n,(this.highlightedDatum&&!s||this.highlightedDatum&&s&&this.highlightedDatum!==s)&&(this.highlightDatum(n),this.updateCrosshairs(),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e))),(null==(r=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.enabled)||r)&&this.handleTooltip(e,n)}onMouseOut(e){this.dehighlightDatum(),this.tooltip.toggle(!1),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e))}processData(){const{data:e,yData:t,xData:i}=this;if(!e||this.invalidData(this.data))return;t.length=0,i.length=0;const r=e.length,n=this.getDataType(e);this.dataType=n;const{type:s}=this.axis,o="number"!==s&&"time"!==s?"category":s,a="number"===o||"time"===o,l=(e,t)=>{null==this.smallestInterval&&(this.smallestInterval={x:1/0,y:1/0});const{x:i}=this.smallestInterval,r=Math.abs(e-t);r>0&&r<i&&(this.smallestInterval.x=r)};let c;if("number"===n)for(let n=0;n<r;n++){const r=n,s=e[n],u=this.getDatum(r,o),h=this.getDatum(s,"number");a&&l(u,c),i.push(u),t.push(h),c=u}else if("array"===n)for(let n=0;n<r;n++){const r=e[n];if(Array.isArray(r)){const e=r[0],n=r[1],s=this.getDatum(e,o),u=this.getDatum(n,"number");if(null==s)continue;a&&l(s,c),i.push(s),t.push(u),c=s}}else if("object"===n){const{yKey:n,xKey:s}=this;for(let u=0;u<r;u++){const r=e[u];if("object"==typeof r&&!Array.isArray(r)){const e=r[s],u=r[n],h=this.getDatum(e,o),d=this.getDatum(u,"number");if(null==h)continue;a&&l(h,c),i.push(h),t.push(d),c=h}}}this.updateAxes(),this.immediateLayout()}getDataType(e){for(const t of e)if(null!=t){if(Jh(t))return"number";if(Array.isArray(t))return"array";if("object"==typeof t)return"object"}}getDatum(e,t){if("number"===t&&Jh(e)||"time"===t&&(Jh(e)||id(e)))return e;if("category"===t){if(ed(e)||id(e)||Jh(e))return{toString:()=>String(e)};if(td(e))return e}}get layoutScheduled(){return!!this.layoutId}scheduleLayout(){this.layoutId&&cancelAnimationFrame(this.layoutId),this.layoutId=requestAnimationFrame(()=>{this.immediateLayout(),this.layoutId=0})}immediateLayout(){this.setSparklineDimensions(),this.invalidData(this.data)||(this.updateXScaleRange(),this.updateYScaleRange(),this.updateAxisLine(),this.update(),this.scene.render().catch(e=>console.error("AG Grid - chart rendering failed",e)))}setSparklineDimensions(){const{width:e,height:t,padding:i,seriesRect:r,rootGroup:n}=this,s=e-i.left-i.right,o=t-i.top-i.bottom;r.width=s,r.height=o,r.x=i.left,r.y=i.top,n.translationX=r.x,n.translationY=r.y}pickClosestSeriesNodeDatum(e,t){let i,r=1/0;const n=this.rootGroup.transformPoint(e,t),s=this.getNodeData();for(let e=0;e<s.length;e++){const t=s[e];if(!t.point)return;const o=this.getDistance(n,t.point);o<=r&&(r=o,i=t)}return i}getDistance(e,t){return Math.abs(e.x-t.x)}handleTooltip(e,t){var i,r;const{seriesDatum:n}=t,{canvasElement:s}=this,{clientX:o,clientY:a}=e,l=null==(i=this.processedOptions)?void 0:i.tooltip,c={pageX:o,pageY:a,position:{xOffset:null==l?void 0:l.xOffset,yOffset:null==l?void 0:l.yOffset},container:null==l?void 0:l.container};null==c.container&&(c.container=s);const u=n.y,h=n.x;let d=null==(r=null==l?void 0:l.enabled)||r;const p=null==l?void 0:l.renderer;if(p){const e=p({context:this.context,datum:n,yValue:u,xValue:h});d="string"!=typeof e&&void 0!==e.enabled?e.enabled:d}const g=d&&void 0!==n.y&&this.getTooltipHtml(t);g&&this.tooltip.show(c,g)}formatNumericDatum(e){return String(Math.round(10*e)/10)}formatDatum(e){const t=this.axis.type||"category";return"number"===t&&"number"==typeof e?this.formatNumericDatum(e):"time"===t&&(e instanceof Date||Jh(e))?this.defaultDateFormatter.format(e):String(e)}setupDomEventListeners(e){e.addEventListener("mousemove",this._onMouseMove),e.addEventListener("mouseout",this._onMouseOut)}cleanupDomEventListeners(e){e.removeEventListener("mousemove",this._onMouseMove),e.removeEventListener("mouseout",this._onMouseOut)}invalidData(e){return!e||!Array.isArray(e)}destroy(){this.cleanupDomEventListeners(this.canvasElement),this.scene.destroy(),this.container=void 0}};cd.tooltipDocuments=[];var ud=cd;function hd(e,t){var i,r,n;if("string"==typeof e)return e;t=null!=t?t:{};const{content:s=(null!=(i=t.content)?i:""),title:o=(null!=(r=t.title)?r:void 0),color:a=t.color,backgroundColor:l=t.backgroundColor,opacity:c=(null!=(n=t.opacity)?n:1)}=e;let u,h;a?(u=o?`<span class="${pd.class}-title"; style="color: ${a}">${o}</span>`:"",h=`<span class="${pd.class}-content" style="color: ${a}">${s}</span>`):(u=o?`<span class="${pd.class}-title">${o}</span>`:"",h=`<span class="${pd.class}-content">${s}</span>`);let d=`opacity: ${c}`;return l&&(d+=`; background-color: ${l.toLowerCase()}`),`<div class="${pd.class}" style="${d}">\n                ${u}\n                ${h}\n            </div>`}var dd=class e{constructor(){this.element=document.createElement("div"),document.body.appendChild(this.element)}isVisible(){const{element:t}=this;if(t.classList)return!t.classList.contains(`${e.class}-wrapper-hidden`);const i=t.getAttribute("class");return!!i&&i.split(" ").indexOf(`${e.class}-wrapper-hidden`)<0}updateClass(t){const i=[`${e.class}-wrapper`];!0!==t&&i.push(`${e.class}-wrapper-hidden`),this.element.setAttribute("class",i.join(" "))}show(e,t){var i,r,n,s;this.toggle(!1);const{element:o}=this;if(void 0!==t)o.innerHTML=t;else if(!o.innerHTML)return;const a=null!=(r=null==(i=e.position)?void 0:i.xOffset)?r:10,l=null!=(s=null==(n=e.position)?void 0:n.yOffset)?s:0;let c=e.pageX+a,u=e.pageY+l;const h=o.getBoundingClientRect();let d=window.innerWidth-h.width;if(e.container){const t=e.container.getBoundingClientRect();d=t.left+(t.width-h.width)}c>d&&(c=e.pageX-o.clientWidth-a),"undefined"!=typeof scrollX&&(c+=scrollX),"undefined"!=typeof scrollY&&(u+=scrollY),o.style.left=`${Math.round(c)}px`,o.style.top=`${Math.round(u)}px`,this.toggle(!0)}toggle(e){this.updateClass(e)}destroy(){const{parentNode:e}=this.element;e&&e.removeChild(this.element)}};dd.class="ag-sparkline-tooltip";var pd=dd;function gd(e){switch(e){case"circle":default:return n._Scene.Circle;case"square":return n._Scene.Square;case"diamond":return n._Scene.Diamond}}function fd(e,t="solid"){const i={solid:[],dash:[4,3],dot:[1,3],dashDot:[4,3,1,3],dashDotDot:[4,3,1,3,1,3],shortDot:[1,1],shortDash:[3,1],shortDashDot:[3,1,1,1],shortDashDotDot:[3,1,1,1,1,1],longDash:[8,3],longDashDot:[8,3,1,3],longDashDotDot:[8,3,1,3,1,3]},r={solid:[],dash:[3,3],dot:[0,3],dashDot:[3,3,0,3],dashDotDot:[3,3,0,3,0,3],shortDot:[0,2],shortDash:[2,2],shortDashDot:[2,2,0,2],shortDashDotDot:[2,2,0,2,0,2],longDash:[7,3],longDashDot:[7,3,0,3],longDashDotDot:[7,3,0,3,0,3]};return"round"===e||"square"===e?null==r[t]?(console.warn(`'${t}' is not a valid 'lineDash' option.`),r.solid):r[t]:null==i[t]?(console.warn(`'${t}' is not a valid 'lineDash' option.`),i.solid):i[t]}var{extent:md}=n._Util,{BandScale:vd}=n._Scale,Cd=class{constructor(){this.enabled=!0,this.shape="circle",this.size=0,this.fill="rgb(124, 181, 236)",this.stroke="rgb(124, 181, 236)",this.strokeWidth=1,this.formatter=void 0}},yd=class{constructor(){this.stroke="rgb(124, 181, 236)",this.strokeWidth=1}},wd=class{constructor(){this.xLine={enabled:!0,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0},this.yLine={enabled:!1,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0}}},Sd=class extends ud{constructor(){super(),this.fill="rgba(124, 181, 236, 0.25)",this.strokePath=new n._Scene.Path,this.fillPath=new n._Scene.Path,this.xCrosshairLine=new n._Scene.Line,this.yCrosshairLine=new n._Scene.Line,this.areaSparklineGroup=new n._Scene.Group,this.xAxisLine=new n._Scene.Line,this.markers=new n._Scene.Group,this.markerSelection=n._Scene.Selection.select(this.markers,()=>this.markerFactory()),this.markerSelectionData=[],this.marker=new Cd,this.line=new yd,this.crosshairs=new wd,this.rootGroup.append(this.areaSparklineGroup),this.xAxisLine.zIndex=500,this.fillPath.zIndex=50,this.strokePath.zIndex=1e3,this.xCrosshairLine.zIndex=2e3,this.yCrosshairLine.zIndex=2e3,this.markers.zIndex=2500,this.areaSparklineGroup.append([this.fillPath,this.xAxisLine,this.strokePath,this.xCrosshairLine,this.yCrosshairLine,this.markers])}markerFactory(){const{shape:e}=this.marker;return new(gd(e))}getNodeData(){return this.markerSelectionData}update(){const e=this.generateNodeData();if(!e)return;const{nodeData:t,fillData:i,strokeData:r}=e;this.markerSelectionData=t,this.updateSelection(t),this.updateNodes(),this.updateStroke(r),this.updateFill(i)}updateYScaleDomain(){const{yData:e,yScale:t}=this,i=md(e);let r=0,n=1;void 0!==i&&(r=this.min=i[0],n=this.max=i[1]),r=r<0?r:0,n=n<0?0:n,t.domain=[r,n]}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n}=this;if(!e)return;const s=!(r instanceof vd),o=s?0:r.bandwidth/2,a=t.length,l=[],c=[],u=[];let h,d,p,g;const f=n.convert(0);for(let e=0;e<a;e++){const m=t[e],v=i[e],C=r.convert(s?r.toDomain(v):v)+o,y=void 0===m?NaN:n.convert(m);e+1<a&&(g=r.convert(s?r.toDomain(i[e+1]):i[e+1])+o),u.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),void 0===m&&void 0!==p?(c.push({seriesDatum:void 0,point:{x:p,y:f}}),void 0!==g&&c.push({seriesDatum:void 0,point:{x:g,y:f}})):void 0!==m&&(c.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),l.push({seriesDatum:{x:v,y:m},point:{x:C,y}}),h=void 0!==h?h:C,d=C),p=C}return c.push({seriesDatum:void 0,point:{x:d,y:f}},{seriesDatum:void 0,point:{x:h,y:f}}),{nodeData:l,fillData:c,strokeData:u}}updateAxisLine(){const{xScale:e,yScale:t,axis:i,xAxisLine:r}=this;r.x1=e.range[0],r.x2=e.range[1],r.y1=r.y2=0,r.stroke=i.stroke,r.strokeWidth=i.strokeWidth;const n=t.convert(0);r.translationY=n}updateSelection(e){this.markerSelection.update(e)}updateNodes(){const{highlightedDatum:e,highlightStyle:t,marker:i}=this,{size:r,fill:n,stroke:s,strokeWidth:o}=t,a=i.formatter;this.markerSelection.each((t,l,c)=>{const{point:u,seriesDatum:h}=l;if(!u)return;const d=l===e,p=d&&void 0!==n?n:i.fill,g=d&&void 0!==s?s:i.stroke,f=d&&void 0!==o?o:i.strokeWidth,m=d&&void 0!==r?r:i.size;let v;if(a){const e=0===c,t=c===this.markerSelectionData.length-1,i=h.y===this.min,r=h.y===this.max;v=a({datum:l,xValue:h.x,yValue:h.y,min:i,max:r,first:e,last:t,fill:p,stroke:g,strokeWidth:f,size:m,highlighted:d})}t.size=v&&null!=v.size?v.size:m,t.fill=v&&null!=v.fill?v.fill:p,t.stroke=v&&null!=v.stroke?v.stroke:g,t.strokeWidth=v&&null!=v.strokeWidth?v.strokeWidth:f,t.translationX=u.x,t.translationY=u.y,t.visible=v&&null!=v.enabled?v.enabled:i.enabled&&t.size>0})}updateStroke(e){const{strokePath:t,yData:i,line:r}=this,n=t.path;if(n.clear(),i.length<2)return;const s=e.length;let o=!0;for(let t=0;t<s;t++){const{point:i,seriesDatum:r}=e[t],s=i.x,a=i.y;null==r.y?o=!0:o?(n.moveTo(s,a),o=!1):n.lineTo(s,a)}t.lineJoin=t.lineCap="round",t.fill=void 0,t.stroke=r.stroke,t.strokeWidth=r.strokeWidth}updateFill(e){const{fillPath:t,yData:i,fill:r}=this,n=t.path,s=e.length;if(n.clear(),!(i.length<2)){for(let t=0;t<s;t++){const{point:i}=e[t],r=i.x,s=i.y;t>0?n.lineTo(r,s):n.moveTo(r,s)}n.closePath(),t.lineJoin="round",t.stroke=void 0,t.fill=r}}updateXCrosshairLine(){var e;const{yScale:t,xCrosshairLine:i,highlightedDatum:r,crosshairs:{xLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.y1=t.range[0],i.y2=t.range[1],i.x1=i.x2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:fd(i.lineCap,n.lineDash),i.translationX=r.point.x}updateYCrosshairLine(){var e;const{xScale:t,yCrosshairLine:i,highlightedDatum:r,crosshairs:{yLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.x1=t.range[0],i.x2=t.range[1],i.y1=i.y2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:fd(i.lineCap,n.lineDash),i.translationY=r.point.y}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?hd(l({context:this.context,datum:n,yValue:s,xValue:o}),a):hd(a)}};Sd.className="AreaSparkline";var{extent:bd}=n._Util,{BandScale:Ed}=n._Scale,Ad=class{constructor(){this.enabled=!0,this.shape="circle",this.size=0,this.fill="rgb(124, 181, 236)",this.stroke="rgb(124, 181, 236)",this.strokeWidth=1,this.formatter=void 0}},Td=class{constructor(){this.stroke="rgb(124, 181, 236)",this.strokeWidth=1}},Md=class{constructor(){this.xLine={enabled:!0,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0},this.yLine={enabled:!1,stroke:"rgba(0,0,0, 0.54)",strokeWidth:1,lineDash:"solid",lineCap:void 0}}},Rd=class extends ud{constructor(){super(),this.linePath=new n._Scene.Path,this.xCrosshairLine=new n._Scene.Line,this.yCrosshairLine=new n._Scene.Line,this.lineSparklineGroup=new n._Scene.Group,this.markers=new n._Scene.Group,this.markerSelection=n._Scene.Selection.select(this.markers,()=>this.markerFactory()),this.markerSelectionData=[],this.marker=new Ad,this.line=new Td,this.crosshairs=new Md,this.rootGroup.append(this.lineSparklineGroup),this.linePath.zIndex=1e3,this.xCrosshairLine.zIndex=2e3,this.yCrosshairLine.zIndex=2e3,this.markers.zIndex=2500,this.lineSparklineGroup.append([this.linePath,this.xCrosshairLine,this.yCrosshairLine,this.markers])}getNodeData(){return this.markerSelectionData}markerFactory(){const{shape:e}=this.marker;return new(gd(e))}onMarkerShapeChange(){this.markerSelection=this.markerSelection.clear(),this.scheduleLayout()}update(){const e=this.generateNodeData();e&&(this.markerSelectionData=e,this.updateSelection(e),this.updateNodes(),this.updateLine())}updateYScaleDomain(){const{yData:e,yScale:t}=this,i=bd(e);let r=0,n=1;if(void 0!==i&&(r=this.min=i[0],n=this.max=i[1]),r===n){const e=Math.abs(.01*r);r-=e,n+=e}t.domain=[r,n]}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:n}=this;if(!e)return;const s=!(r instanceof Ed),o=s?0:r.bandwidth/2,a=[];for(let e=0;e<t.length;e++){const l=t[e],c=i[e];if(null==l)continue;const u=r.convert(s?r.toDomain(c):c)+o,h=void 0===l?NaN:n.convert(l);a.push({seriesDatum:{x:c,y:l},point:{x:u,y:h}})}return a}updateSelection(e){this.markerSelection.update(e)}updateNodes(){const{highlightedDatum:e,highlightStyle:t,marker:i}=this,{size:r,fill:n,stroke:s,strokeWidth:o}=t,a=i.formatter;this.markerSelection.each((t,l,c)=>{const u=l===e,h=u&&void 0!==n?n:i.fill,d=u&&void 0!==s?s:i.stroke,p=u&&void 0!==o?o:i.strokeWidth,g=u&&void 0!==r?r:i.size;let f;const{seriesDatum:m,point:v}=l;if(a){const e=0===c,t=c===this.markerSelectionData.length-1,i=m.y===this.min,r=m.y===this.max;f=a({datum:l,xValue:m.x,yValue:m.y,min:i,max:r,first:e,last:t,fill:h,stroke:d,strokeWidth:p,size:g,highlighted:u})}t.size=f&&null!=f.size?f.size:g,t.fill=f&&null!=f.fill?f.fill:h,t.stroke=f&&null!=f.stroke?f.stroke:d,t.strokeWidth=f&&null!=f.strokeWidth?f.strokeWidth:p,t.translationX=v.x,t.translationY=v.y,t.visible=f&&null!=f.enabled?f.enabled:i.enabled&&t.size>0})}updateLine(){const{linePath:e,yData:t,xData:i,xScale:r,yScale:n,line:s}=this,o=e.path;if(o.clear(),t.length<2)return;const a=!(r instanceof Ed),l=t.length,c=a?0:r.bandwidth/2;let u=!0;for(let e=0;e<l;e++){const s=i[e],l=t[e],h=r.convert(a?r.toDomain(s):s)+c,d=void 0===l?NaN:n.convert(l);null==l?u=!0:u?(o.moveTo(h,d),u=!1):o.lineTo(h,d)}e.fill=void 0,e.stroke=s.stroke,e.strokeWidth=s.strokeWidth}updateXCrosshairLine(){var e;const{yScale:t,xCrosshairLine:i,highlightedDatum:r,crosshairs:{xLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.y1=t.range[0],i.y2=t.range[1],i.x1=i.x2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:fd(i.lineCap,n.lineDash),i.translationX=r.point.x}updateYCrosshairLine(){var e;const{xScale:t,yCrosshairLine:i,highlightedDatum:r,crosshairs:{yLine:n}}=this;if(!n.enabled||null==r)return void(i.strokeWidth=0);i.x1=t.range[0],i.x2=t.range[1],i.y1=i.y2=0,i.stroke=n.stroke,i.strokeWidth=null!=(e=n.strokeWidth)?e:1,i.lineCap="round"===n.lineCap||"square"===n.lineCap?n.lineCap:void 0;const{lineDash:s}=n;i.lineDash=Array.isArray(s)?s:fd(i.lineCap,n.lineDash),i.translationY=r.point.y}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?hd(l({context:this.context,datum:n,yValue:s,xValue:o}),a):hd(a)}};Rd.className="LineSparkline";var _d=class{constructor(){this.enabled=!0,this.fontSize=8,this.fontFamily="Verdana, sans-serif",this.fontStyle=void 0,this.fontWeight=void 0,this.color="rgba(70, 70, 70, 1)"}},{extent:Pd}=n._Util,xd=class extends _d{constructor(){super(...arguments),this.formatter=void 0,this.placement="insideEnd"}},Dd=class extends ud{constructor(){super(),this.fill="rgb(124, 181, 236)",this.stroke="silver",this.strokeWidth=0,this.paddingInner=.1,this.paddingOuter=.2,this.valueAxisDomain=void 0,this.formatter=void 0,this.axisLine=new n._Scene.Line,this.bandWidth=0,this.sparklineGroup=new n._Scene.Group,this.rectGroup=new n._Scene.Group,this.labelGroup=new n._Scene.Group,this.rectSelection=n._Scene.Selection.select(this.rectGroup,n._Scene.Rect),this.labelSelection=n._Scene.Selection.select(this.labelGroup,n._Scene.Text),this.nodeSelectionData=[],this.label=new xd,this.rootGroup.append(this.sparklineGroup),this.rectGroup.zIndex=50,this.axisLine.zIndex=500,this.labelGroup.zIndex=1500,this.sparklineGroup.append([this.rectGroup,this.axisLine,this.labelGroup]),this.axisLine.lineCap="round",this.label.enabled=!1}getNodeData(){return this.nodeSelectionData}update(){this.updateSelections(),this.updateNodes()}updateSelections(){const e=this.generateNodeData();e&&(this.nodeSelectionData=e,this.updateRectSelection(e),this.updateLabelSelection(e))}updateNodes(){this.updateRectNodes(),this.updateLabelNodes()}calculateStep(e){var t;const{xScale:i,paddingInner:r,paddingOuter:n,smallestInterval:s}=this;let o=(i.domain[1]-i.domain[0])/(null!=(t=null==s?void 0:s.x)?t:1)+1;const a=Math.min(o,50),l=a-1;return e/Math.max(1,2*n+l*r+a)}updateYScaleDomain(){const{yScale:e,yData:t,valueAxisDomain:i}=this,r=Pd(t);let n=0,s=1;void 0!==r&&(n=this.min=r[0],s=this.max=r[1]),n=n<0?n:0,s=s<0?0:s,i&&(i[1]<s&&(i[1]=s),i[0]>n&&(i[0]=n)),e.domain=i||[n,s]}updateRectSelection(e){this.rectSelection.update(e)}updateRectNodes(){const{highlightedDatum:e,formatter:t,fill:i,stroke:r,strokeWidth:n}=this,{fill:s,stroke:o,strokeWidth:a}=this.highlightStyle;this.rectSelection.each((l,c,u)=>{const h=c===e,d=h&&void 0!==s?s:i,p=h&&void 0!==o?o:r,g=h&&void 0!==a?a:n;let f;const{x:m,y:v,width:C,height:y,seriesDatum:w}=c;if(t){const e=0===u,i=u===this.nodeSelectionData.length-1,r=w.y===this.min,n=w.y===this.max;f=t({datum:c,xValue:w.x,yValue:w.y,width:C,height:y,min:r,max:n,first:e,last:i,fill:d,stroke:p,strokeWidth:g,highlighted:h})}l.fill=f&&f.fill||d,l.stroke=f&&f.stroke||p,l.strokeWidth=f&&f.strokeWidth||g,l.x=l.y=0,l.width=C,l.height=y,l.visible=l.height>0,l.translationX=m,l.translationY=v})}updateLabelSelection(e){this.labelSelection.update(e,e=>{e.tag=1,e.pointerEvents=n._Scene.PointerEvents.None})}updateLabelNodes(){const{label:{enabled:e,fontStyle:t,fontWeight:i,fontSize:r,fontFamily:n,color:s}}=this;this.labelSelection.each((o,a)=>{const l=a.label;l&&e?(o.fontStyle=t,o.fontWeight=i,o.fontSize=r,o.fontFamily=n,o.textAlign=l.textAlign,o.textBaseline=l.textBaseline,o.text=l.text,o.x=l.x,o.y=l.y,o.fill=s,o.visible=!0):o.visible=!1})}getTooltipHtml(e){var t,i;const{dataType:r}=this,{seriesDatum:n}=e,s=n.y,o=n.x,a={content:this.formatNumericDatum(s),title:"array"===r||"object"===r?this.formatDatum(o):void 0},l=null==(i=null==(t=this.processedOptions)?void 0:t.tooltip)?void 0:i.renderer;return l?hd(l({context:this.context,datum:n,yValue:s,xValue:o}),a):hd(a)}formatLabelValue(e){return e%1!=0?e.toFixed(1):e.toFixed(0)}},{isNumber:Id}=n._Util,{BandScale:Ld}=n._Scale,Nd=class extends Dd{updateYScaleRange(){const{seriesRect:e,yScale:t}=this;t.range=[0,e.width]}updateXScaleRange(){const{xScale:e,seriesRect:t,paddingOuter:i,paddingInner:r}=this;if(e instanceof Ld)e.range=[0,t.height],e.paddingInner=r,e.paddingOuter=i;else{const n=this.calculateStep(t.height),s=n*i;this.bandWidth=n*(1-r),e.range=[s,t.height-s-this.bandWidth]}}updateAxisLine(){const{yScale:e,axis:t,axisLine:i,seriesRect:r}=this,{strokeWidth:n}=t;i.x1=0,i.x2=0,i.y1=0,i.y2=r.height,i.stroke=t.stroke,i.strokeWidth=n+(n%2==1?1:0);const s=e.convert(0);i.translationX=s}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:s,fill:o,stroke:a,strokeWidth:l,label:c}=this;if(!e)return;const{fontStyle:u,fontWeight:h,fontSize:d,fontFamily:p,color:g,formatter:f,placement:m}=c,v=[],C=s.convert(0),y=!(r instanceof Ld);for(let e=0,c=t.length;e<c;e++){let c=t[e];const w=i[e],S=void 0===c;S&&(c=0);const b=r.convert(y?r.toDomain(w):w),E=Math.min(void 0===c?NaN:s.convert(c),C),A=Math.max(void 0===c?NaN:s.convert(c),C),T=y?this.bandWidth:r.bandwidth,M=A-E,R={x:C,y:b};let _;_=f?f({value:c}):void 0!==c&&Id(c)?this.formatLabelValue(c):"";const P=b+T/2;let x;const D="middle";let I;const L=void 0!==c&&c>=0,N=4;if("center"===m)x=E+M/2,I="center";else if("outsideEnd"===m)x=E+(L?M+N:-N),I=L?"start":"end";else if("insideEnd"===m){x=E+(L?M-N:N),I=L?"end":"start";const e=n._Scene.Text.getTextSize(_,p).width||20;(L&&x<C+e||!L&&x>C-e)&&(x=C+N*(L?1:-1),I=L?"start":"end")}else x=C+N*(L?1:-1),I=L?"start":"end";v.push({x:E,y:b,width:M,height:T,fill:o,stroke:a,strokeWidth:l,seriesDatum:{x:w,y:S?void 0:c},point:R,label:{x,y:P,text:_,fontStyle:u,fontWeight:h,fontSize:d,fontFamily:p,textAlign:I,textBaseline:D,fill:g}})}return v}getDistance(e,t){return Math.abs(e.y-t.y)}};Nd.className="BarSparkline";var{isNumber:Od}=n._Util,{BandScale:Fd}=n._Scale,kd=class extends Dd{updateYScaleRange(){const{seriesRect:e,yScale:t}=this;t.range=[e.height,0]}updateXScaleRange(){const{xScale:e,seriesRect:t,paddingOuter:i,paddingInner:r}=this;if(e instanceof Fd)e.range=[0,t.width],e.paddingInner=r,e.paddingOuter=i;else{const n=this.calculateStep(t.width),s=n*i;this.bandWidth=n*(1-r),e.range=[s,t.width-s-this.bandWidth]}}updateAxisLine(){const{yScale:e,axis:t,axisLine:i,seriesRect:r}=this,{strokeWidth:n}=t;i.x1=0,i.x2=r.width,i.y1=0,i.y2=0,i.stroke=t.stroke,i.strokeWidth=n+(n%2==1?1:0);const s=e.convert(0);i.translationY=s}generateNodeData(){const{data:e,yData:t,xData:i,xScale:r,yScale:s,fill:o,stroke:a,strokeWidth:l,label:c}=this;if(!e)return;const{fontStyle:u,fontWeight:h,fontSize:d,fontFamily:p,color:g,formatter:f,placement:m}=c,v=[],C=s.convert(0),y=!(r instanceof Fd);for(let e=0,c=t.length;e<c;e++){let c=t[e];const w=i[e],S=void 0===c;S&&(c=0);const b=Math.min(void 0===c?NaN:s.convert(c),C),E=r.convert(y?r.toDomain(w):w),A=Math.max(void 0===c?NaN:s.convert(c),C),T=y?this.bandWidth:r.bandwidth,M=A-b,R={x:E+T/2,y:C};let _;_=f?f({value:c}):void 0!==c&&Od(c)?this.formatLabelValue(c):"";const P=E+T/2;let x;const D="center";let I;const L=void 0!==c&&c>=0,N=2;if("center"===m)x=b+M/2,I="middle";else if("outsideEnd"===m)x=b+(L?-N:M+N),I=L?"bottom":"top";else if("insideEnd"===m){x=b+(L?N:M-N),I=L?"top":"bottom";const e=n._Scene.Text.getTextSize(_,p).height||10;(L&&x>C-e||!L&&x<C+e)&&(x=C+N*(L?-1:1),I=L?"bottom":"top")}else x=C+N*(L?-1:1),I=L?"bottom":"top";v.push({x:E,y:b,width:T,height:M,fill:o,stroke:a,strokeWidth:l,seriesDatum:{x:w,y:S?void 0:c},point:R,label:{x:P,y:x,text:_,fontStyle:u,fontWeight:h,fontSize:d,fontFamily:p,textAlign:D,textBaseline:I,fill:g}})}return v}};kd.className="ColumnSparkline";var{isNumber:Gd}=n._Util,Vd=class{static create(e,t){const i=function(e="line"){switch(e){case"column":return new kd;case"bar":return new Nd;case"area":return new Sd;default:return new Rd}}((e=n._Util.deepClone(e)).type);return t&&(i.tooltip=t),function(e,t){$d(e,"context",t.context,t),$d(e,"width",t.width,t),$d(e,"height",t.height,t),$d(e,"container",t.container,t),$d(e,"xKey",t.xKey,t),$d(e,"yKey",t.yKey,t),t.padding&&function(e,t){$d(e,"top",t.top,t),$d(e,"right",t.right,t),$d(e,"bottom",t.bottom,t),$d(e,"left",t.left,t)}(e.padding,t.padding),t.axis&&function(e,t){$d(e,"type",t.type,t),$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t)}(e.axis,t.axis),t.highlightStyle&&function(e,t){$d(e,"fill",t.fill,t),$d(e,"size",t.size,t),$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t)}(e.highlightStyle,t.highlightStyle)}(i,e),function(e,t){switch(t.type){case"bar":case"column":!function(e,t){$d(e,"valueAxisDomain",t.valueAxisDomain,t),$d(e,"fill",t.fill,t),$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t),$d(e,"paddingInner",t.paddingInner,t),$d(e,"paddingOuter",t.paddingOuter,t),$d(e,"formatter",t.formatter,t),t.label&&function(e,t){$d(e,"enabled",t.enabled,t),$d(e,"fontStyle",t.fontStyle,t),$d(e,"fontWeight",t.fontWeight,t),$d(e,"fontSize",t.fontSize,t),$d(e,"fontFamily",t.fontFamily,t),$d(e,"textAlign",t.textAlign,t),$d(e,"textBaseline",t.textBaseline,t),$d(e,"color",t.color,t),$d(e,"formatter",t.formatter,t),$d(e,"placement",t.placement,t)}(e.label,t.label)}(e,t);break;case"area":!function(e,t){$d(e,"fill",t.fill,t),t.marker&&Hd(e.marker,t.marker),t.line&&Bd(e.line,t.line),t.crosshairs&&zd(e.crosshairs,t.crosshairs)}(e,t);break;default:!function(e,t){t.marker&&Hd(e.marker,t.marker),t.line&&Bd(e.line,t.line),t.crosshairs&&zd(e.crosshairs,t.crosshairs)}(e,t)}}(i,e),e.data&&(i.data=e.data),i.processedOptions=e,i}};function Hd(e,t){$d(e,"enabled",t.enabled,t),$d(e,"size",t.size,t),$d(e,"shape",t.shape,t),$d(e,"fill",t.fill,t),$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t),$d(e,"formatter",t.formatter,t)}function Bd(e,t){$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t)}function zd(e,t){e.xLine&&t.xLine&&Ud(e.xLine,t.xLine),e.yLine&&t.yLine&&Ud(e.yLine,t.yLine)}function Ud(e,t){$d(e,"enabled",t.enabled,t),$d(e,"stroke",t.stroke,t),$d(e,"strokeWidth",t.strokeWidth,t),$d(e,"lineDash",t.lineDash,t),$d(e,"lineCap",t.lineCap,t)}var Wd={},jd=(e,t,i)=>{if(Gd(t))return!0;const r=`AG Charts: ${e} must be a number, the value you provided is not a valid number. Using the default of ${i}px.`;var n,s;return n=()=>console.warn(r),Wd[s=`${e} not a number`]||(n(),Wd[s]=!0),!1},Kd={xOffset:jd,yOffset:jd};function $d(e,t,i,r){if(t in r)if(t in e){const r=Kd[t];(!r||r(t,i,e[t]))&&e[t]!==i&&(e[t]=i)}else console.warn(`Property ${t} does not exist on the target object.`)}var qd=class e extends r.uAl{constructor(){super(e.TEMPLATE)}init(e){let t=!0;const i=this.resizeObserverService.observeResize(this.getGui(),()=>{const{clientWidth:i,clientHeight:r}=this.getGui();if(0!==i&&0!==r)if(t){const n=((e,t)=>{for(var i in t||(t={}))qh.call(t,i)&&Qh(e,i,t[i]);if($h)for(var i of $h(t))Yh.call(t,i)&&Qh(e,i,t[i]);return e})({data:e.value,width:i,height:r,context:{data:e.data}},e.sparklineOptions);this.sparkline=Vd.create(n,this.sparklineTooltipSingleton.getSparklineTooltip()),this.eSparkline.appendChild(this.sparkline.canvasElement),t=!1}else this.sparkline.width=i,this.sparkline.height=r});this.addDestroyFunc(()=>i())}refresh(e){return!!this.sparkline&&(this.sparkline.data=e.value,!0)}destroy(){this.sparkline&&this.sparkline.destroy(),super.destroy()}};qd.TEMPLATE='<div class="ag-sparkline-wrapper">\n            <span ref="eSparkline"></span>\n        </div>',Xh([(0,r.PIB)("eSparkline")],qd.prototype,"eSparkline",2),Xh([(0,r.dsm)("resizeObserverService")],qd.prototype,"resizeObserverService",2),Xh([(0,r.dsm)("sparklineTooltipSingleton")],qd.prototype,"sparklineTooltipSingleton",2);var Yd=qd,Qd=class extends r.XQb{postConstruct(){this.tooltip=new pd}getSparklineTooltip(){return this.tooltip}destroyTooltip(){this.tooltip&&this.tooltip.destroy()}};Xh([r.o7C],Qd.prototype,"postConstruct",1),Xh([r.yah],Qd.prototype,"destroyTooltip",1),Qd=Xh([(0,r.dR4)("sparklineTooltipSingleton")],Qd);var Xd={version:"31.3.4",moduleName:r.zsj.SparklinesModule,beans:[Qd],userComponents:[{componentName:"agSparklineCellRenderer",componentClass:Yd}],dependantModules:[S]},Zd=class extends r.XQb{constructor(){super(),this.allComponents=new Map}registerStatusPanel(e,t){this.allComponents.set(e,t)}unregisterStatusPanel(e){this.allComponents.delete(e)}unregisterAllComponents(){this.allComponents.clear()}getStatusPanel(e){return this.allComponents.get(e)}destroy(){this.unregisterAllComponents(),super.destroy()}};Zd=d([(0,r.dR4)("statusBarService")],Zd);var Jd=class e extends r.uAl{constructor(){super(e.TEMPLATE),this.compDestroyFunctions={}}postConstruct(){this.processStatusPanels(new Map),this.addManagedPropertyListeners(["statusBar"],this.handleStatusBarChanged.bind(this))}processStatusPanels(e){var t;const i=null==(t=this.gos.get("statusBar"))?void 0:t.statusPanels;if(i){const t=i.filter(e=>"left"===e.align);this.createAndRenderComponents(t,this.eStatusBarLeft,e);const r=i.filter(e=>"center"===e.align);this.createAndRenderComponents(r,this.eStatusBarCenter,e);const n=i.filter(e=>!e.align||"right"===e.align);this.createAndRenderComponents(n,this.eStatusBarRight,e)}else this.setDisplayed(!1)}handleStatusBarChanged(){var e;const t=null==(e=this.gos.get("statusBar"))?void 0:e.statusPanels,i=Array.isArray(t)&&t.length>0;this.setDisplayed(i);const n=new Map;i&&t.forEach(e=>{var t,i;const s=null!=(t=e.key)?t:e.statusPanel,o=this.statusBarService.getStatusPanel(s);if(null==o?void 0:o.refresh){const t=this.gos.addGridCommonParams(null!=(i=e.statusPanelParams)?i:{});o.refresh(t)&&(n.set(s,o),delete this.compDestroyFunctions[s],r._.removeFromParent(o.getGui()))}}),this.resetStatusBar(),i&&this.processStatusPanels(n)}resetStatusBar(){this.eStatusBarLeft.innerHTML="",this.eStatusBarCenter.innerHTML="",this.eStatusBarRight.innerHTML="",this.destroyComponents(),this.statusBarService.unregisterAllComponents()}destroyComponents(){Object.values(this.compDestroyFunctions).forEach(e=>e()),this.compDestroyFunctions={}}createAndRenderComponents(e,t,i){const n=[];e.forEach(e=>{const t=e.key||e.statusPanel,s=i.get(t);let o;if(s)o=r.oY$.resolve(s);else{const t={};if(o=this.userComponentFactory.getStatusPanelCompDetails(e,t).newAgStackInstance(),!o)return}n.push({key:t,promise:o})}),r.oY$.all(n.map(e=>e.promise)).then(()=>{n.forEach(e=>{e.promise.then(i=>{const r=()=>{this.getContext().destroyBean(i)};this.isAlive()?(this.statusBarService.registerStatusPanel(e.key,i),t.appendChild(i.getGui()),this.compDestroyFunctions[e.key]=r):r()})})})}};Jd.TEMPLATE='<div class="ag-status-bar">\n            <div ref="eStatusBarLeft" class="ag-status-bar-left" role="status"></div>\n            <div ref="eStatusBarCenter" class="ag-status-bar-center" role="status"></div>\n            <div ref="eStatusBarRight" class="ag-status-bar-right" role="status"></div>\n        </div>',d([(0,r.dsm)("userComponentFactory")],Jd.prototype,"userComponentFactory",2),d([(0,r.dsm)("statusBarService")],Jd.prototype,"statusBarService",2),d([(0,r.PIB)("eStatusBarLeft")],Jd.prototype,"eStatusBarLeft",2),d([(0,r.PIB)("eStatusBarCenter")],Jd.prototype,"eStatusBarCenter",2),d([(0,r.PIB)("eStatusBarRight")],Jd.prototype,"eStatusBarRight",2),d([r.o7C],Jd.prototype,"postConstruct",1),d([r.yah],Jd.prototype,"destroyComponents",1);var ep=Jd,tp=class e extends r.uAl{constructor(){super(e.TEMPLATE)}setLabel(e,t){this.setDisplayed(!1);const i=this.localeService.getLocaleTextFunc();this.eLabel.innerHTML=i(e,t)}setValue(e){this.eValue.innerHTML=e}};tp.TEMPLATE='<div class="ag-status-name-value">\n            <span ref="eLabel"></span>:&nbsp;\n            <span ref="eValue" class="ag-status-name-value-value"></span>\n        </div>',d([(0,r.PIB)("eLabel")],tp.prototype,"eLabel",2),d([(0,r.PIB)("eValue")],tp.prototype,"eValue",2);var ip=tp,rp=class extends ip{postConstruct(){"clientSide"===this.rowModel.getType()?(this.setLabel("totalAndFilteredRows","Rows"),this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-total-and-filtered-row-count"),this.setDisplayed(!0),this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,this.onDataChanged.bind(this)),this.onDataChanged()):r._.warnOnce("agTotalAndFilteredRowCountComponent should only be used with the client side row model.")}onDataChanged(){const e=this.localeService.getLocaleTextFunc(),t=e("thousandSeparator",","),i=e("decimalSeparator","."),n=r._.formatNumberCommas(this.getFilteredRowCountValue(),t,i),s=r._.formatNumberCommas(this.getTotalRowCount(),t,i);if(n===s)this.setValue(n);else{const e=this.localeService.getLocaleTextFunc();this.setValue(`${n} ${e("of","of")} ${s}`)}}getFilteredRowCountValue(){let e=0;return this.rowModel.forEachNodeAfterFilter(t=>{t.group||e++}),e}getTotalRowCount(){let e=0;return this.rowModel.forEachNode(t=>{t.group||e++}),e}init(){}refresh(){return!0}destroy(){super.destroy()}};d([(0,r.dsm)("rowModel")],rp.prototype,"rowModel",2),d([r.o7C],rp.prototype,"postConstruct",1);var np=class extends ip{postConstruct(){if(this.setLabel("filteredRows","Filtered"),"clientSide"!==this.rowModel.getType())return void r._.warnOnce("agFilteredRowCountComponent should only be used with the client side row model.");this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-filtered-row-count"),this.setDisplayed(!0);const e=this.onDataChanged.bind(this);this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,e),e()}onDataChanged(){const e=this.getTotalRowCountValue(),t=this.getFilteredRowCountValue(),i=this.localeService.getLocaleTextFunc(),n=i("thousandSeparator",","),s=i("decimalSeparator",".");this.setValue(r._.formatNumberCommas(t,n,s)),this.setDisplayed(e!==t)}getTotalRowCountValue(){let e=0;return this.rowModel.forEachNode(t=>e+=1),e}getFilteredRowCountValue(){let e=0;return this.rowModel.forEachNodeAfterFilter(t=>{t.group||(e+=1)}),e}init(){}refresh(){return!0}destroy(){super.destroy()}};d([(0,r.dsm)("rowModel")],np.prototype,"rowModel",2),d([r.o7C],np.prototype,"postConstruct",1);var sp=class extends ip{postConstruct(){this.setLabel("totalRows","Total Rows"),"clientSide"===this.rowModel.getType()?(this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-total-row-count"),this.setDisplayed(!0),this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,this.onDataChanged.bind(this)),this.onDataChanged()):r._.warnOnce("agTotalRowCountComponent should only be used with the client side row model.")}onDataChanged(){const e=this.localeService.getLocaleTextFunc(),t=e("thousandSeparator",","),i=e("decimalSeparator",".");this.setValue(r._.formatNumberCommas(this.getRowCountValue(),t,i))}getRowCountValue(){let e=0;return this.rowModel.forEachLeafNode(t=>e+=1),e}init(){}refresh(){return!0}destroy(){super.destroy()}};d([(0,r.dsm)("rowModel")],sp.prototype,"rowModel",2),d([r.o7C],sp.prototype,"postConstruct",1);var op=class extends ip{postConstruct(){if(!this.isValidRowModel())return void console.warn("AG Grid: agSelectedRowCountComponent should only be used with the client and server side row model.");this.setLabel("selectedRows","Selected"),this.addCssClass("ag-status-panel"),this.addCssClass("ag-status-panel-selected-row-count"),this.onRowSelectionChanged();const e=this.onRowSelectionChanged.bind(this);this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,e),this.addManagedListener(this.eventService,r.sVA.EVENT_SELECTION_CHANGED,e)}isValidRowModel(){const e=this.rowModel.getType();return"clientSide"===e||"serverSide"===e}onRowSelectionChanged(){const e=this.selectionService.getSelectionCount();if(e<0)return this.setValue("?"),void this.setDisplayed(!0);const t=this.localeService.getLocaleTextFunc(),i=t("thousandSeparator",","),n=t("decimalSeparator",".");this.setValue(r._.formatNumberCommas(e,i,n)),this.setDisplayed(e>0)}init(){}refresh(){return!0}destroy(){super.destroy()}};d([(0,r.dsm)("rowModel")],op.prototype,"rowModel",2),d([(0,r.dsm)("selectionService")],op.prototype,"selectionService",2),d([r.o7C],op.prototype,"postConstruct",1);var ap=class e extends r.uAl{constructor(){super(e.TEMPLATE)}destroy(){super.destroy()}postConstruct(){this.isValidRowModel()?(this.avgAggregationComp.setLabel("avg","Average"),this.countAggregationComp.setLabel("count","Count"),this.minAggregationComp.setLabel("min","Min"),this.maxAggregationComp.setLabel("max","Max"),this.sumAggregationComp.setLabel("sum","Sum"),this.addManagedListener(this.eventService,r.sVA.EVENT_RANGE_SELECTION_CHANGED,this.onRangeSelectionChanged.bind(this)),this.addManagedListener(this.eventService,r.sVA.EVENT_MODEL_UPDATED,this.onRangeSelectionChanged.bind(this))):console.warn("AG Grid: agAggregationComponent should only be used with the client and server side row model.")}isValidRowModel(){const e=this.rowModel.getType();return"clientSide"===e||"serverSide"===e}init(e){this.params=e}refresh(e){return this.params=e,this.onRangeSelectionChanged(),!0}setAggregationComponentValue(e,t,i){var n;const s=this.getAllowedAggregationValueComponent(e);if(r._.exists(s)&&s){const e=this.localeService.getLocaleTextFunc(),n=e("thousandSeparator",","),o=e("decimalSeparator",".");s.setValue(r._.formatNumberTwoDecimalPlacesAndCommas(t,n,o)),s.setDisplayed(i)}else null==(n=this.getAggregationValueComponent(e))||n.setDisplayed(!1)}getAllowedAggregationValueComponent(e){const{aggFuncs:t}=this.params;return!t||t.includes(e)?this.getAggregationValueComponent(e):null}getAggregationValueComponent(e){return this[`${e}AggregationComp`]}onRangeSelectionChanged(){var e;const t=null==(e=this.rangeService)?void 0:e.getCellRanges();let i=0,n=0,s=0,o=null,a=null;const l={};if(t&&!r._.missingOrEmpty(t)&&this.rangeService)for(let e=0;e<t.length;e++){const c=t[e];let u=this.rangeService.getRangeStartRow(c);const h=this.rangeService.getRangeEndRow(c);for(;!r._.missing(u)&&u&&!this.rowPositionUtils.before(h,u)&&u&&c.columns;)c.columns.forEach(e=>{if(null===u)return;const t=this.cellPositionUtils.createId({rowPinned:u.rowPinned,column:e,rowIndex:u.rowIndex});if(l[t])return;l[t]=!0;const c=this.rowPositionUtils.getRowNode(u);if(r._.missing(c))return;let h=this.valueService.getValue(e,c);r._.missing(h)||""===h||(n++,"object"==typeof h&&"value"in h&&(h=h.value,""===h)||("string"==typeof h&&(h=Number(h)),"number"!=typeof h||isNaN(h)||(i+=h,(null===a||h>a)&&(a=h),(null===o||h<o)&&(o=h),s++)))}),u=this.cellNavigationService.getRowBelow(u)}const c=n>1,u=s>1;this.setAggregationComponentValue("count",n,c),this.setAggregationComponentValue("sum",i,u),this.setAggregationComponentValue("min",o,u),this.setAggregationComponentValue("max",a,u),this.setAggregationComponentValue("avg",i/s,u)}};ap.TEMPLATE='<div class="ag-status-panel ag-status-panel-aggregations">\n            <ag-name-value ref="avgAggregationComp"></ag-name-value>\n            <ag-name-value ref="countAggregationComp"></ag-name-value>\n            <ag-name-value ref="minAggregationComp"></ag-name-value>\n            <ag-name-value ref="maxAggregationComp"></ag-name-value>\n            <ag-name-value ref="sumAggregationComp"></ag-name-value>\n        </div>',d([(0,r.Xx1)("rangeService")],ap.prototype,"rangeService",2),d([(0,r.dsm)("valueService")],ap.prototype,"valueService",2),d([(0,r.dsm)("cellNavigationService")],ap.prototype,"cellNavigationService",2),d([(0,r.dsm)("rowModel")],ap.prototype,"rowModel",2),d([(0,r.dsm)("cellPositionUtils")],ap.prototype,"cellPositionUtils",2),d([(0,r.dsm)("rowPositionUtils")],ap.prototype,"rowPositionUtils",2),d([(0,r.PIB)("sumAggregationComp")],ap.prototype,"sumAggregationComp",2),d([(0,r.PIB)("countAggregationComp")],ap.prototype,"countAggregationComp",2),d([(0,r.PIB)("minAggregationComp")],ap.prototype,"minAggregationComp",2),d([(0,r.PIB)("maxAggregationComp")],ap.prototype,"maxAggregationComp",2),d([(0,r.PIB)("avgAggregationComp")],ap.prototype,"avgAggregationComp",2),d([r.o7C],ap.prototype,"postConstruct",1);var lp=ap,cp={version:"31.3.4",moduleName:r.zsj.StatusBarModule,beans:[Zd],agStackComponents:[{componentName:"AgStatusBar",componentClass:ep},{componentName:"AgNameValue",componentClass:ip}],userComponents:[{componentName:"agAggregationComponent",componentClass:lp},{componentName:"agSelectedRowCountComponent",componentClass:op},{componentName:"agTotalRowCountComponent",componentClass:sp},{componentName:"agFilteredRowCountComponent",componentClass:np},{componentName:"agTotalAndFilteredRowCountComponent",componentClass:rp}],dependantModules:[S]},up=Object.defineProperty,hp=Object.getOwnPropertyDescriptor,dp=(e,t,i,r)=>{for(var n,s=r>1?void 0:r?hp(t,i):t,o=e.length-1;o>=0;o--)(n=e[o])&&(s=(r?n(t,i,s):n(s))||s);return r&&s&&up(t,i,s),s},pp=class extends r.XQb{constructor(){super(...arguments),this.firstRow=-1,this.lastRow=-1,this.rowCount=-1,this.rowNodesByIndex={}}ensureRowHeightsValid(e,t,i,r){return!1}init(){this.rowHeight=this.gos.getRowHeightAsNumber(),this.addManagedListener(this.eventService,r.sVA.EVENT_VIEWPORT_CHANGED,this.onViewportChanged.bind(this)),this.addManagedPropertyListener("viewportDatasource",()=>this.updateDatasource()),this.addManagedPropertyListener("rowHeight",()=>{this.rowHeight=this.gos.getRowHeightAsNumber(),this.updateRowHeights()})}start(){this.updateDatasource()}isLastRowIndexKnown(){return!0}destroyDatasource(){this.viewportDatasource&&(this.viewportDatasource.destroy&&this.viewportDatasource.destroy(),this.rowRenderer.datasourceChanged(),this.firstRow=-1,this.lastRow=-1)}updateDatasource(){const e=this.gos.get("viewportDatasource");e&&this.setViewportDatasource(e)}getViewportRowModelPageSize(){return this.gos.get("viewportRowModelPageSize")}getViewportRowModelBufferSize(){return this.gos.get("viewportRowModelBufferSize")}calculateFirstRow(e){const t=this.getViewportRowModelBufferSize(),i=this.getViewportRowModelPageSize(),r=e-t;return r<0?0:Math.floor(r/i)*i}calculateLastRow(e){if(-1===e)return e;const t=this.getViewportRowModelBufferSize(),i=this.getViewportRowModelPageSize(),r=e+t,n=Math.ceil(r/i)*i,s=this.rowCount-1;return Math.min(n,s)}onViewportChanged(e){const t=this.calculateFirstRow(e.firstRow),i=this.calculateLastRow(e.lastRow);this.firstRow===t&&this.lastRow===i||(this.firstRow=t,this.lastRow=i,this.purgeRowsNotInViewport(),this.viewportDatasource&&this.viewportDatasource.setViewportRange(this.firstRow,this.lastRow))}purgeRowsNotInViewport(){Object.keys(this.rowNodesByIndex).forEach(e=>{const t=parseInt(e,10);if(t<this.firstRow||t>this.lastRow){if(this.isRowFocused(t))return;delete this.rowNodesByIndex[t]}})}isRowFocused(e){const t=this.focusService.getFocusCellToUseAfterRefresh();return!!t&&(null==t.rowPinned&&t.rowIndex===e)}setViewportDatasource(e){this.destroyDatasource(),this.viewportDatasource=e,this.rowCount=-1,e.init?e.init({setRowCount:this.setRowCount.bind(this),setRowData:this.setRowData.bind(this),getRow:this.getRow.bind(this)}):console.warn("AG Grid: viewport is missing init method.")}getType(){return"viewport"}getRow(e){return this.rowNodesByIndex[e]||(this.rowNodesByIndex[e]=this.createBlankRowNode(e)),this.rowNodesByIndex[e]}getRowNode(e){let t;return this.forEachNode(i=>{i.id===e&&(t=i)}),t}getRowCount(){return-1===this.rowCount?0:this.rowCount}getRowIndexAtPixel(e){return 0!==this.rowHeight?Math.floor(e/this.rowHeight):0}getRowBounds(e){return{rowHeight:this.rowHeight,rowTop:this.rowHeight*e}}updateRowHeights(){this.forEachNode(e=>{e.setRowHeight(this.rowHeight),e.setRowTop(this.rowHeight*e.rowIndex)});const e={type:r.sVA.EVENT_MODEL_UPDATED,newData:!1,newPage:!1,keepRenderedRows:!0,animate:!1};this.eventService.dispatchEvent(e)}getTopLevelRowCount(){return this.getRowCount()}getTopLevelRowDisplayedIndex(e){return e}isEmpty(){return this.rowCount>0}isRowsToRender(){return this.rowCount>0}getNodesInRangeForSelection(e,t){const i=r._.missing(e)?0:e.rowIndex,n=t.rowIndex,s=i<this.firstRow||i>this.lastRow,o=n<this.firstRow||n>this.lastRow;if(s||o)return[];const a=[],l=i<=n?n:i;for(let e=i<=n?i:n;e<=l;e++)a.push(this.rowNodesByIndex[e]);return a}forEachNode(e){let t=0;Object.keys(this.rowNodesByIndex).forEach(i=>{const r=parseInt(i,10),n=this.rowNodesByIndex[r];e(n,t),t++})}setRowData(e){r._.iterateObject(e,(e,t)=>{const i=parseInt(e,10);if(i>=this.firstRow&&i<=this.lastRow){let e=this.rowNodesByIndex[i];r._.missing(e)&&(e=this.createBlankRowNode(i),this.rowNodesByIndex[i]=e),e.setDataAndId(t,i.toString())}})}createBlankRowNode(e){const t=new r.TUE(this.beans);return t.setRowHeight(this.rowHeight),t.setRowTop(this.rowHeight*e),t.setRowIndex(e),t}setRowCount(e,t=!1){if(e===this.rowCount)return;this.rowCount=e,this.eventService.dispatchEventOnce({type:r.sVA.EVENT_ROW_COUNT_READY});const i={type:r.sVA.EVENT_MODEL_UPDATED,newData:!1,newPage:!1,keepRenderedRows:t,animate:!1};this.eventService.dispatchEvent(i)}isRowPresent(e){return!!this.getRowNode(e.id)}};dp([(0,r.dsm)("rowRenderer")],pp.prototype,"rowRenderer",2),dp([(0,r.dsm)("focusService")],pp.prototype,"focusService",2),dp([(0,r.dsm)("beans")],pp.prototype,"beans",2),dp([r.o7C],pp.prototype,"init",1),dp([r.yah],pp.prototype,"destroyDatasource",1),pp=dp([(0,r.dR4)("rowModel")],pp);var gp={version:"31.3.4",moduleName:r.zsj.ViewportRowModelModule,rowModel:"viewport",beans:[pp],dependantModules:[S]};h(p,me),r.syG.__registerModules([r.Q90,r.Sko,r.n76,fe,Is,Us,Da,_c,Kc,ru,Pu,Wu,Fe,Ku,Ao,Eh,Wh,qo,Xd,cp,gp],!1,void 0)},56137(e,t,i){"use strict";i.d(t,{W6:()=>fe});var r=i(22155),n=i(54989),s=i(70316),o=i(32431),a=Object.defineProperty,l=Object.defineProperties,c=Object.getOwnPropertyDescriptors,u=Object.getOwnPropertySymbols,h=Object.prototype.hasOwnProperty,d=Object.prototype.propertyIsEnumerable,p=(e,t,i)=>t in e?a(e,t,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[t]=i,g=(e,t)=>{for(var i in t||(t={}))h.call(t,i)&&p(e,i,t[i]);if(u)for(var i of u(t))d.call(t,i)&&p(e,i,t[i]);return e},f=(e,t)=>l(e,c(t)),m=(0,r.createContext)({setMethods:()=>{}}),v=(0,r.memo)(e=>{const{initialProps:t,addUpdateCallback:i,CustomComponentClass:n,setMethods:s}=e,[o,a]=(0,r.useState)(t);return(0,r.useEffect)(()=>{i(e=>a(e))},[]),r.createElement(m.Provider,{value:{setMethods:s}},r.createElement(n,g({},o)))}),C=0;function y(){return"agPortalKey_"+ ++C}var w=class{constructor(e,t,i,r){this.portal=null,this.oldPortal=null,this.reactComponent=e,this.portalManager=t,this.componentType=i,this.suppressFallbackMethods=!!r,this.statelessComponent=this.isStateless(this.reactComponent),this.key=y(),this.portalKey=y(),this.instanceCreated=this.isStatelessComponent()?n.oY$.resolve(!1):new n.oY$(e=>{this.resolveInstanceCreated=e})}getGui(){return this.eParentElement}getRootElement(){return this.eParentElement.firstChild}destroy(){return this.componentInstance&&"function"==typeof this.componentInstance.destroy&&this.componentInstance.destroy(),this.portalManager.destroyPortal(this.portal)}createParentElement(e){const t=this.portalManager.getComponentWrappingElement(),i=document.createElement(t||"div");return i.classList.add("ag-react-container"),e.reactContainer=i,i}addParentContainerStyleAndClasses(){this.componentInstance&&(this.componentInstance.getReactContainerStyle&&this.componentInstance.getReactContainerStyle()&&(n._.warnOnce('Since v31.1 "getReactContainerStyle" is deprecated. Apply styling directly to ".ag-react-container" if needed.'),Object.assign(this.eParentElement.style,this.componentInstance.getReactContainerStyle())),this.componentInstance.getReactContainerClasses&&this.componentInstance.getReactContainerClasses())&&(n._.warnOnce('Since v31.1 "getReactContainerClasses" is deprecated. Apply styling directly to ".ag-react-container" if needed.'),this.componentInstance.getReactContainerClasses().forEach(e=>this.eParentElement.classList.add(e)))}statelessComponentRendered(){return this.eParentElement.childElementCount>0||this.eParentElement.childNodes.length>0}getFrameworkComponentInstance(){return this.componentInstance}isStatelessComponent(){return this.statelessComponent}getReactComponentName(){return this.reactComponent.name}getMemoType(){return this.hasSymbol()?Symbol.for("react.memo"):60115}hasSymbol(){return"function"==typeof Symbol&&Symbol.for}isStateless(e){return"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===this.getMemoType()}hasMethod(e){const t=this.getFrameworkComponentInstance();return!!t&&null!=t[e]||this.fallbackMethodAvailable(e)}callMethod(e,t){const i=this.getFrameworkComponentInstance();if(this.isStatelessComponent())return this.fallbackMethod(e,t&&t[0]?t[0]:{});if(!i)return void setTimeout(()=>this.callMethod(e,t));const r=i[e];return r?r.apply(i,t):this.fallbackMethodAvailable(e)?this.fallbackMethod(e,t&&t[0]?t[0]:{}):void 0}addMethod(e,t){this[e]=t}init(e){return this.eParentElement=this.createParentElement(e),this.params=e,this.createOrUpdatePortal(e),new n.oY$(e=>this.createReactComponent(e))}createOrUpdatePortal(e){this.isStatelessComponent()||(this.ref=e=>{var t;this.componentInstance=e,this.addParentContainerStyleAndClasses(),null==(t=this.resolveInstanceCreated)||t.call(this,!0),this.resolveInstanceCreated=void 0},e.ref=this.ref),this.reactElement=this.createElement(this.reactComponent,f(g({},e),{key:this.key})),this.portal=(0,s.createPortal)(this.reactElement,this.eParentElement,this.portalKey)}createElement(e,t){return(0,r.createElement)(e,t)}createReactComponent(e){this.portalManager.mountReactPortal(this.portal,this,t=>{e(t)})}isNullValue(){return this.valueRenderedIsNull(this.params)}rendered(){return this.isStatelessComponent()&&this.statelessComponentRendered()||!(this.isStatelessComponent()||!this.getFrameworkComponentInstance())}valueRenderedIsNull(e){if(!this.componentType.cellRenderer)return!1;const t=console.error;try{return console.error=()=>{},""===(0,o.renderToStaticMarkup)((0,r.createElement)(this.reactComponent,e))}catch(e){}finally{console.error=t}return!1}refreshComponent(e){this.oldPortal=this.portal,this.createOrUpdatePortal(e),this.portalManager.updateReactPortal(this.oldPortal,this.portal)}fallbackMethod(e,t){const i=this[`${e}Component`];if(!this.suppressFallbackMethods&&i)return i.bind(this)(t)}fallbackMethodAvailable(e){return!this.suppressFallbackMethods&&!!this[`${e}Component`]}};function S(e,t,i){e.forEach(e=>{const r=t[e];r&&(i[e]=r)})}var b=class extends w{constructor(){super(...arguments),this.awaitUpdateCallback=new n.oY$(e=>{this.resolveUpdateCallback=e}),this.wrapperComponent=v}init(e){return this.sourceParams=e,super.init(this.getProps())}addMethod(){}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}getFrameworkComponentInstance(){return this}createElement(e,t){return super.createElement(this.wrapperComponent,{initialProps:t,CustomComponentClass:e,setMethods:e=>this.setMethods(e),addUpdateCallback:e=>{this.updateCallback=()=>(e(this.getProps()),new n.oY$(e=>{setTimeout(()=>{e()})})),this.resolveUpdateCallback()}})}setMethods(e){this.providedMethods=e,S(this.getOptionalMethods(),this.providedMethods,this)}getOptionalMethods(){return[]}getProps(){return f(g({},this.sourceParams),{key:this.key,ref:this.ref})}refreshProps(){return this.updateCallback?this.updateCallback():new n.oY$(e=>this.awaitUpdateCallback.then(()=>{this.updateCallback().then(()=>e())}))}},E=class extends b{constructor(){super(...arguments),this.date=null,this.onDateChange=e=>this.updateDate(e)}getDate(){return this.date}setDate(e){this.date=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached","setInputPlaceholder","setInputAriaLabel","setDisabled"]}updateDate(e){this.setDate(e),this.sourceParams.onDateChanged()}getProps(){const e=super.getProps();return e.date=this.date,e.onDateChange=this.onDateChange,delete e.onDateChanged,e}},A=class extends b{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e),this.onUiChange=()=>this.sourceParams.filterChangedCallback()}isFilterActive(){return null!=this.model}doesFilterPass(e){return this.providedMethods.doesFilterPass(e)}getModel(){return this.model}setModel(e){return this.model=e,this.refreshProps()}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getOptionalMethods(){return["afterGuiAttached","afterGuiDetached","onNewRowsLoaded","getModelAsString","onAnyFilterChanged"]}updateModel(e){this.setModel(e).then(()=>this.sourceParams.filterChangedCallback())}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e.onUiChange=this.onUiChange,delete e.filterChangedCallback,delete e.filterModifiedCallback,delete e.valueGetter,e}};function T(e,t){e.parentFilterInstance(i=>{(i.setModel(t)||n.oY$.resolve()).then(()=>{e.filterParams.filterChangedCallback()})})}var M=class{constructor(e,t){this.floatingFilterParams=e,this.refreshProps=t,this.model=null,this.onModelChange=e=>this.updateModel(e)}getProps(){return f(g({},this.floatingFilterParams),{model:this.model,onModelChange:this.onModelChange})}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.floatingFilterParams=e,this.refreshProps()}setMethods(e){S(this.getOptionalMethods(),e,this)}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),T(this.floatingFilterParams,e)}},R=class extends b{constructor(){super(...arguments),this.model=null,this.onModelChange=e=>this.updateModel(e)}onParentModelChanged(e){this.model=e,this.refreshProps()}refresh(e){this.sourceParams=e,this.refreshProps()}getOptionalMethods(){return["afterGuiAttached"]}updateModel(e){this.model=e,this.refreshProps(),T(this.sourceParams,e)}getProps(){const e=super.getProps();return e.model=this.model,e.onModelChange=this.onModelChange,e}},_=class extends b{refresh(e){this.sourceParams=e,this.refreshProps()}},P=class extends b{constructor(){super(...arguments),this.active=!1,this.expanded=!1,this.onActiveChange=e=>this.updateActive(e)}setActive(e){this.awaitSetActive(e)}setExpanded(e){this.expanded=e,this.refreshProps()}getOptionalMethods(){return["select","configureDefaults"]}awaitSetActive(e){return this.active=e,this.refreshProps()}updateActive(e){const t=this.awaitSetActive(e);e&&t.then(()=>this.sourceParams.onItemActivated())}getProps(){const e=super.getProps();return e.active=this.active,e.expanded=this.expanded,e.onActiveChange=this.onActiveChange,delete e.onItemActivated,e}},x=class extends b{refresh(e){this.sourceParams=e,this.refreshProps()}},D=class extends b{refresh(e){return this.sourceParams=e,this.refreshProps(),!0}},I=class extends b{constructor(){super(...arguments),this.onStateChange=e=>this.updateState(e)}refresh(e){return this.sourceParams=e,this.refreshProps(),!0}getState(){return this.state}updateState(e){this.state=e,this.refreshProps(),this.sourceParams.onStateUpdated()}getProps(){const e=super.getProps();return e.state=this.state,e.onStateChange=this.onStateChange,e}},L=class e{constructor(t,i,r){this.destroyed=!1,this.portals=[],this.hasPendingPortalUpdate=!1,this.wrappingElement=i||"div",this.refresher=t,this.maxComponentCreationTimeMs=r||e.MAX_COMPONENT_CREATION_TIME_IN_MS}getPortals(){return this.portals}destroy(){this.destroyed=!0}destroyPortal(e){this.portals=this.portals.filter(t=>t!==e),this.batchUpdate()}getComponentWrappingElement(){return this.wrappingElement}mountReactPortal(e,t,i){this.portals=[...this.portals,e],this.waitForInstance(t,i),this.batchUpdate()}updateReactPortal(e,t){this.portals[this.portals.indexOf(e)]=t,this.batchUpdate()}batchUpdate(){this.hasPendingPortalUpdate||(setTimeout(()=>{this.destroyed||(this.refresher(),this.hasPendingPortalUpdate=!1)}),this.hasPendingPortalUpdate=!0)}waitForInstance(e,t,i=Date.now()){if(this.destroyed)t(null);else if(e.rendered())t(e);else{if(Date.now()-i>=this.maxComponentCreationTimeMs&&!this.hasPendingPortalUpdate)return e.isNullValue()?void t(e):(console.error(`AG Grid: React Component '${e.getReactComponentName()}' not created within ${this.maxComponentCreationTimeMs}ms.`),void console.error("    If the component is using `forwardRef` but not `useImperativeHandle`, add the following: `useImperativeHandle(ref, () => ({}));`"));window.setTimeout(()=>{this.waitForInstance(e,t,i)})}}};L.MAX_COMPONENT_CREATION_TIME_IN_MS=1e3;var N=L,O=r.createContext({}),F=(...e)=>e.filter(e=>null!=e&&""!==e).join(" "),k=class e{constructor(...e){this.classesMap={},e.forEach(e=>{this.classesMap[e]=!0})}setClass(t,i){if(!!this.classesMap[t]==i)return this;const r=new e;return r.classesMap=g({},this.classesMap),r.classesMap[t]=i,r}toString(){return Object.keys(this.classesMap).filter(e=>this.classesMap[e]).join(" ")}},G=e=>"function"==typeof e&&!(e.prototype&&e.prototype.isReactComponent)||"object"==typeof e&&e.$$typeof===("function"==typeof Symbol&&Symbol.for?Symbol.for("react.memo"):60115),V=null!=s.createRoot&&null!=s.flushSync,H=!1,B=(e,t)=>{V&&e&&!H?s.flushSync(t):t()};function z(e,t,i){if(null==t||null==e)return t;if(e===t||0===t.length&&0===e.length)return e;if(i||0===e.length&&t.length>0||e.length>0&&0===t.length)return t;const r=[],n=[],s=new Map,o=new Map;for(let e=0;e<t.length;e++){const i=t[e];o.set(i.getInstanceId(),i)}for(let t=0;t<e.length;t++){const i=e[t];s.set(i.getInstanceId(),i),o.has(i.getInstanceId())&&r.push(i)}for(let e=0;e<t.length;e++){const i=t[e],r=i.getInstanceId();s.has(r)||n.push(i)}return r.length===e.length&&0===n.length?e:0===r.length&&n.length===t.length?t:0===r.length?n:0===n.length?r:[...r,...n]}var U=(e,t,i,r)=>{if(!e||e.componentFromFramework||t.isDestroyed())return;const n=e.newAgStackInstance();if(!n)return;let s,o,a=!1;return n.then(e=>{a?t.destroyBean(e):(s=e,o=s.getGui(),i.appendChild(o),W(r,s))}),()=>{a=!0,s&&(o&&o.parentElement&&o.parentElement.removeChild(o),t.destroyBean(s),r&&W(r,void 0))}},W=(e,t)=>{e&&(e instanceof Function?e(t):e.current=t)},j=(0,r.forwardRef)((e,t)=>{var i;const s=(0,r.useContext)(O).context,o=(0,r.useRef)(null),a=(0,r.useRef)(null),l=(0,r.useRef)(null),c=(0,r.useRef)(null),u=(0,r.useRef)(null),h=(0,r.useRef)(),[d,p]=(0,r.useState)(),[f,m]=(0,r.useState)(),[v,C]=(0,r.useState)(),[y,w]=(0,r.useState)(()=>new k),[S,b]=(0,r.useState)(()=>new k("ag-hidden")),[E,A]=(0,r.useState)(()=>new k("ag-hidden")),[T,M]=(0,r.useState)(()=>new k("ag-invisible"));(0,r.useImperativeHandle)(t,()=>({refresh:()=>!1})),(0,r.useLayoutEffect)(()=>U(d,s,a.current),[d]);const R=(0,r.useCallback)(t=>{if(o.current=t,!o.current)return s.destroyBean(h.current),void(h.current=null);const i={setInnerRenderer:(e,t)=>{p(e),C(t)},setChildCount:e=>m(e),addOrRemoveCssClass:(e,t)=>w(i=>i.setClass(e,t)),setContractedDisplayed:e=>A(t=>t.setClass("ag-hidden",!e)),setExpandedDisplayed:e=>b(t=>t.setClass("ag-hidden",!e)),setCheckboxVisible:e=>M(t=>t.setClass("ag-invisible",!e))};h.current=s.createBean(new n.ihO),h.current.init(i,o.current,l.current,c.current,u.current,j,e)},[]),_=(0,r.useMemo)(()=>`ag-cell-wrapper ${y.toString()}`,[y]),P=(0,r.useMemo)(()=>`ag-group-expanded ${S.toString()}`,[S]),x=(0,r.useMemo)(()=>`ag-group-contracted ${E.toString()}`,[E]),D=(0,r.useMemo)(()=>`ag-group-checkbox ${T.toString()}`,[T]),I=d&&d.componentFromFramework,L=I?d.componentClass:void 0,N=null==d&&null!=v,F=n._.escapeString(v,!0);return r.createElement("span",g({className:_,ref:R},e.colDef?{}:{role:null==(i=h.current)?void 0:i.getCellAriaRole()}),r.createElement("span",{className:P,ref:c}),r.createElement("span",{className:x,ref:u}),r.createElement("span",{className:D,ref:l}),r.createElement("span",{className:"ag-group-value",ref:a},N&&r.createElement(r.Fragment,null,F),I&&r.createElement(L,g({},d.params))),r.createElement("span",{className:"ag-group-child-count"},f))}),K=j,$=(0,r.memo)(e=>{const{ctrl:t}=e,i=t.isAlive(),{context:s}=(0,r.useContext)(O),o=i?t.getColId():void 0,[a,l]=(0,r.useState)(),c=(0,r.useRef)(null),u=(0,r.useRef)(null),h=(0,r.useRef)(null),d=(0,r.useRef)();let p=(0,r.useRef)();i&&!p.current&&(p.current=new n.hv8(()=>c.current));const m=(0,r.useCallback)(e=>{var r;if(c.current=e,!c.current||!i)return;const s={setWidth:e=>{c.current&&(c.current.style.width=e)},addOrRemoveCssClass:(e,t)=>p.current.addOrRemoveCssClass(e,t),setAriaSort:e=>{c.current&&(e?n._.setAriaSort(c.current,e):n._.removeAriaSort(c.current))},setUserCompDetails:e=>l(e),getUserCompInstance:()=>d.current||void 0};t.setComp(s,c.current,u.current,h.current);const o=t.getSelectAllGui();null==(r=u.current)||r.insertAdjacentElement("afterend",o)},[]);(0,r.useLayoutEffect)(()=>U(a,s,h.current,d),[a]),(0,r.useEffect)(()=>{t.setDragSource(c.current)},[a]);const v=(0,r.useMemo)(()=>!(!(null==a?void 0:a.componentFromFramework)||!G(a.componentClass)),[a]),C=a&&a.componentFromFramework,y=a&&a.componentClass;return r.createElement("div",{ref:m,className:"ag-header-cell","col-id":o,role:"columnheader"},r.createElement("div",{ref:u,className:"ag-header-cell-resize",role:"presentation"}),r.createElement("div",{ref:h,className:"ag-header-cell-comp-wrapper",role:"presentation"},C&&v&&r.createElement(y,g({},a.params)),C&&!v&&r.createElement(y,f(g({},a.params),{ref:d}))))}),q=(0,r.memo)(e=>{const{context:t}=(0,r.useContext)(O),{ctrl:i}=e,[n,s]=(0,r.useState)(()=>new k),[o,a]=(0,r.useState)(()=>new k),[l,c]=(0,r.useState)("false"),[u,h]=(0,r.useState)(),[d,p]=(0,r.useState)(),m=(0,r.useMemo)(()=>i.getColId(),[]),v=(0,r.useRef)(null),C=(0,r.useRef)(null),y=(0,r.useRef)(),w=(0,r.useCallback)(e=>{if(v.current=e,!v.current)return;const t={setWidth:e=>{v.current&&(v.current.style.width=e)},addOrRemoveCssClass:(e,t)=>s(i=>i.setClass(e,t)),setUserCompDetails:e=>p(e),setResizableDisplayed:e=>{a(t=>t.setClass("ag-hidden",!e)),c(e?"false":"true")},setAriaExpanded:e=>h(e),getUserCompInstance:()=>y.current||void 0};i.setComp(t,v.current,C.current)},[]);(0,r.useLayoutEffect)(()=>U(d,t,v.current),[d]),(0,r.useEffect)(()=>{v.current&&i.setDragSource(v.current)},[d]);const S=(0,r.useMemo)(()=>!(!(null==d?void 0:d.componentFromFramework)||!G(d.componentClass)),[d]),b=(0,r.useMemo)(()=>"ag-header-group-cell "+n.toString(),[n]),E=(0,r.useMemo)(()=>"ag-header-cell-resize "+o.toString(),[o]),A=d&&d.componentFromFramework,T=d&&d.componentClass;return r.createElement("div",{ref:w,className:b,"col-id":m,role:"columnheader","aria-expanded":u},A&&S&&r.createElement(T,g({},d.params)),A&&!S&&r.createElement(T,f(g({},d.params),{ref:y})),r.createElement("div",{ref:C,"aria-hidden":l,className:E}))});function Y(){n._.warnOnce("Using custom components without `reactiveCustomComponents = true` is deprecated.")}var Q=(0,r.memo)(e=>{const{context:t,gos:i}=(0,r.useContext)(O),[s,o]=(0,r.useState)(()=>new k("ag-header-cell","ag-floating-filter")),[a,l]=(0,r.useState)(()=>new k),[c,u]=(0,r.useState)(()=>new k("ag-floating-filter-button","ag-hidden")),[h,d]=(0,r.useState)("false"),[p,v]=(0,r.useState)(),[C,y]=(0,r.useState)(1),w=(0,r.useRef)(null),S=(0,r.useRef)(null),b=(0,r.useRef)(null),E=(0,r.useRef)(null),A=(0,r.useRef)(),T=(0,r.useRef)(),R=e=>{null!=e&&A.current&&A.current(e)},{ctrl:_}=e,P=(0,r.useCallback)(e=>{if(w.current=e,!w.current)return;T.current=new n.oY$(e=>{A.current=e});const t={addOrRemoveCssClass:(e,t)=>o(i=>i.setClass(e,t)),addOrRemoveBodyCssClass:(e,t)=>l(i=>i.setClass(e,t)),setButtonWrapperDisplayed:e=>{u(t=>t.setClass("ag-hidden",!e)),d(e?"false":"true")},setWidth:e=>{w.current&&(w.current.style.width=e)},setCompDetails:e=>v(e),getFloatingFilterComp:()=>T.current?T.current:null,setMenuIcon:e=>{var t;return null==(t=E.current)?void 0:t.appendChild(e)}};_.setComp(t,w.current,E.current,S.current)},[]);(0,r.useLayoutEffect)(()=>U(p,t,S.current,R),[p]);const x=(0,r.useMemo)(()=>s.toString(),[s]),D=(0,r.useMemo)(()=>a.toString(),[a]),I=(0,r.useMemo)(()=>c.toString(),[c]),L=(0,r.useMemo)(()=>!!(p&&p.componentFromFramework&&G(p.componentClass)),[p]),N=(0,r.useMemo)(()=>i.get("reactiveCustomComponents"),[]),F=(0,r.useMemo)(()=>{if(p){if(N){const e=new M(p.params,()=>y(e=>e+1));return R(e),e}p.componentFromFramework&&Y()}},[p]),V=null==F?void 0:F.getProps(),H=p&&p.componentFromFramework,B=p&&p.componentClass;return r.createElement("div",{ref:P,className:x,role:"gridcell"},r.createElement("div",{ref:S,className:D,role:"presentation"},H&&!N&&r.createElement(B,f(g({},p.params),{ref:L?()=>{}:R})),H&&N&&r.createElement(m.Provider,{value:{setMethods:e=>F.setMethods(e)}},r.createElement(B,g({},V)))),r.createElement("div",{ref:b,"aria-hidden":h,className:I,role:"presentation"},r.createElement("button",{ref:E,type:"button",className:"ag-button ag-floating-filter-button-button",tabIndex:-1})))}),X=(0,r.memo)(e=>{const{ctrl:t}=e,{topOffset:i,rowHeight:s}=(0,r.useMemo)(()=>t.getTopAndHeight(),[]),o=t.getAriaRowIndex(),a=t.getHeaderRowClass(),[l,c]=(0,r.useState)(()=>s+"px"),[u,h]=(0,r.useState)(()=>i+"px"),d=(0,r.useRef)(null),p=(0,r.useRef)(null),[g,f]=(0,r.useState)(()=>t.getHeaderCtrls()),m=(0,r.useRef)(null),v=(0,r.useCallback)(e=>{if(m.current=e,!e)return;const i={setHeight:e=>c(e),setTop:e=>h(e),setHeaderCtrls:(e,t,i)=>{p.current=d.current,d.current=e;const r=z(p.current,e,t);r!==p.current&&B(i,()=>f(r))},setWidth:e=>{m.current&&(m.current.style.width=e)}};t.setComp(i,!1)},[]),C=(0,r.useMemo)(()=>({height:l,top:u}),[l,u]),y=(0,r.useCallback)(e=>{switch(t.getType()){case n.YtK.COLUMN_GROUP:return r.createElement(q,{ctrl:e,key:e.getInstanceId()});case n.YtK.FLOATING_FILTER:return r.createElement(Q,{ctrl:e,key:e.getInstanceId()});default:return r.createElement($,{ctrl:e,key:e.getInstanceId()})}},[]);return r.createElement("div",{ref:v,className:a,role:"row",style:C,"aria-rowindex":o},g.map(y))}),Z=(0,r.memo)(e=>{const[t,i]=(0,r.useState)(!0),[s,o]=(0,r.useState)([]),{context:a}=(0,r.useContext)(O),l=(0,r.useRef)(null),c=(0,r.useRef)(null),u=(0,r.useRef)(null),h="left"===e.pinned,d="right"===e.pinned,p=!h&&!d,g=(0,r.useCallback)(t=>{if(l.current=t,!l.current)return a.destroyBean(u.current),void(u.current=null);const r={setDisplayed:i,setCtrls:e=>o(e),setCenterWidth:e=>{c.current&&(c.current.style.width=e)},setViewportScrollLeft:e=>{l.current&&(l.current.scrollLeft=e)},setPinnedContainerWidth:e=>{l.current&&(l.current.style.width=e,l.current.style.minWidth=e,l.current.style.maxWidth=e)}};u.current=a.createBean(new n.OPU(e.pinned)),u.current.setComp(r,l.current)},[]),f=t?"":"ag-hidden",m=()=>s.map(e=>r.createElement(X,{ctrl:e,key:e.getInstanceId()}));return r.createElement(r.Fragment,null,h&&r.createElement("div",{ref:g,className:"ag-pinned-left-header "+f,"aria-hidden":!t,role:"rowgroup"},m()),d&&r.createElement("div",{ref:g,className:"ag-pinned-right-header "+f,"aria-hidden":!t,role:"rowgroup"},m()),p&&r.createElement("div",{ref:g,className:"ag-header-viewport "+f,role:"presentation"},r.createElement("div",{ref:c,className:"ag-header-container",role:"rowgroup"},m())))}),J=(0,r.memo)(()=>{const[e,t]=(0,r.useState)(()=>new k),[i,s]=(0,r.useState)(),{context:o}=(0,r.useContext)(O),a=(0,r.useRef)(null),l=(0,r.useRef)(null),c=(0,r.useCallback)(e=>{if(a.current=e,!e)return o.destroyBean(l.current),void(l.current=null);const i={addOrRemoveCssClass:(e,i)=>t(t=>t.setClass(e,i)),setHeightAndMinHeight:e=>s(e)};l.current=o.createBean(new n.vBt),l.current.setComp(i,a.current,a.current)},[]),u=(0,r.useMemo)(()=>"ag-header "+e.toString(),[e]),h=(0,r.useMemo)(()=>({height:i,minHeight:i}),[i]);return r.createElement("div",{ref:c,className:u,style:h,role:"presentation"},r.createElement(Z,{pinned:"left"}),r.createElement(Z,{pinned:null}),r.createElement(Z,{pinned:"right"}))}),ee=(e,t)=>{(0,r.useEffect)(()=>{const i=t.current;if(i){const t=i.parentElement;if(t){const r=document.createComment(e);return t.insertBefore(r,i),()=>{t.removeChild(r)}}}},[e])},te=(0,r.memo)(e=>{const[t,i]=(0,r.useState)(),{context:o,popupService:a,localeService:l,gos:c}=(0,r.useContext)(O);return(()=>{const t=(0,r.useRef)(()=>{const{editDetails:t,cellCtrl:r,eParentCell:s}=e,{compDetails:u}=t,h=c.get("stopEditingWhenCellsLoseFocus"),d=o.createBean(new n.zmE(u.params)),p=d.getGui();if(e.jsChildComp){const t=e.jsChildComp.getGui();t&&p.appendChild(t)}const g={column:r.getColumn(),rowNode:r.getRowNode(),type:"popupCellEditor",eventSource:s,ePopup:p,position:t.popupPosition,keepWithinBounds:!0},f=a.positionPopupByComponent.bind(a,g),m=l.getLocaleTextFunc(),v=a.addPopup({modal:h,eChild:p,closeOnEsc:!0,closedCallback:()=>{r.onPopupEditorClosed()},anchorToElement:s,positionCallback:f,ariaLabel:m("ariaLabelCellEditor","Cell Editor")}),C=v?v.hideFunc:void 0;return i(d),e.jsChildComp&&e.jsChildComp.afterGuiAttached&&e.jsChildComp.afterGuiAttached(),()=>{null!=C&&C(),o.destroyBean(d)}}),s=(0,r.useRef)(),u=(0,r.useRef)(!1),h=(0,r.useRef)(!1),[,d]=(0,r.useState)(0);u.current&&(h.current=!0),(0,r.useEffect)(()=>(u.current||(s.current=t.current(),u.current=!0),d(e=>e+1),()=>{h.current&&s.current&&s.current()}),[])})(),r.createElement(r.Fragment,null,t&&e.wrappedContent&&(0,s.createPortal)(e.wrappedContent,t.getGui()))}),ie=class{constructor(e,t){this.cellEditorParams=e,this.refreshProps=t,this.instanceCreated=new n.oY$(e=>{this.resolveInstanceCreated=e}),this.onValueChange=e=>this.updateValue(e),this.value=e.value}getProps(){return f(g({},this.cellEditorParams),{initialValue:this.cellEditorParams.value,value:this.value,onValueChange:this.onValueChange})}getValue(){return this.value}refresh(e){this.cellEditorParams=e,this.refreshProps()}setMethods(e){S(this.getOptionalMethods(),e,this)}getInstance(){return this.instanceCreated.then(()=>this.componentInstance)}setRef(e){var t;this.componentInstance=e,null==(t=this.resolveInstanceCreated)||t.call(this),this.resolveInstanceCreated=void 0}getOptionalMethods(){return["isPopup","isCancelBeforeStart","isCancelAfterEnd","getPopupPosition","focusIn","focusOut","afterGuiAttached"]}updateValue(e){this.value=e,this.refreshProps()}},re=(e,t,i)=>{const n=e.compProxy;return r.createElement(r.Fragment,null,!n&&r.createElement(t,f(g({},e.compDetails.params),{ref:i})),n&&((e,t,i)=>{const{compProxy:n}=e;i(n);const s=n.getProps(),o=G(t);return r.createElement(m.Provider,{value:{setMethods:e=>n.setMethods(e)}},o&&r.createElement(t,g({},s)),!o&&r.createElement(t,f(g({},s),{ref:e=>n.setRef(e)})))})(e,t,i))},ne=(0,r.memo)(e=>{const{context:t}=(0,r.useContext)(O),{cellCtrl:i,printLayout:s,editingRow:o}=e,a=i.getTabIndex(),l=i.getColumnIdSanitised(),c=i.getInstanceId(),[u,h]=(0,r.useState)(()=>i.isCellRenderer()?void 0:{compDetails:void 0,value:i.getValueToDisplay(),force:!1}),[d,p]=(0,r.useState)(),[m,v]=(0,r.useState)(1),[C,y]=(0,r.useState)(),[w,S]=(0,r.useState)(!1),[b,E]=(0,r.useState)(!1),[A,T]=(0,r.useState)(!1),[M,R]=(0,r.useState)(),_=(0,r.useMemo)(()=>i.isForceWrapper(),[i]),P=(0,r.useMemo)(()=>i.getCellAriaRole(),[i]),x=(0,r.useRef)(null),D=(0,r.useRef)(null),I=(0,r.useRef)(),L=(0,r.useRef)(),N=(0,r.useRef)(),F=(0,r.useRef)([]),k=(0,r.useRef)(),[V,H]=(0,r.useState)(0),B=(0,r.useCallback)(e=>{k.current=e,H(e=>e+1)},[]),z=_||null!=u&&(w||A||b),U=(0,r.useCallback)((e,t)=>{L.current=t,t&&(((e,t,i)=>{const r=i.getColumn();if(!e&&t.isPopup&&t.isPopup()){const e=`AG Grid: Found an issue in column ${r.getColId()}. If using React, specify an editor is a popup using colDef.cellEditorPopup=true. AG Grid React cannot depend on the editor component specifying if it's in a popup (via the isPopup() method on the editor), as React needs to know this information BEFORE the component is created.`;n._.doOnce(()=>console.warn(e),"jsEditorComp-isPopup-"+i.getColumn().getColId())}if(e&&t.getPopupPosition&&null!=t.getPopupPosition()){const e=`AG Grid: Found an issue in column ${r.getColId()}. If using React, specify an editor popup position using colDef.cellEditorPopupPosition=true. AG Grid React cannot depend on the editor component specifying it's position (via the getPopupPosition() method on the editor), as React needs to know this information BEFORE the component is created.`;n._.doOnce(()=>console.warn(e),"jsEditorComp-getPopupPosition-"+i.getColumn().getColId())}})(e,t,i),t.isCancelBeforeStart&&t.isCancelBeforeStart()&&setTimeout(()=>{i.stopEditing(!0),i.focusCell(!0)}))},[i]),W=(0,r.useCallback)(e=>U(!0,e),[U]),j=(0,r.useCallback)(e=>U(!1,e),[U]);let K=(0,r.useRef)();K.current||(K.current=new n.hv8(()=>x.current)),((e,t,i,n,s,o)=>{const{context:a}=(0,r.useContext)(O),l=(0,r.useCallback)(()=>{const e=s.current;if(!e)return;const t=e.getGui();t&&t.parentElement&&t.parentElement.removeChild(t),a.destroyBean(e),s.current=void 0},[]);(0,r.useEffect)(()=>{const r=null!=e,n=e&&e.compDetails&&!e.compDetails.componentFromFramework;if(!r||!n||t&&null==i)return void l();const a=e.compDetails;if(s.current){const t=s.current,i=!(null==t.refresh||0!=e.force)&&t.refresh(a.params);if(!0===i||void 0===i)return;l()}const c=a.newAgStackInstance();if(!c)return;const u=c.resolveNow(null,e=>e);if(!u)return;const h=u.getGui();h&&((t?i:o.current).appendChild(h),s.current=u)},[e,t,n]),(0,r.useEffect)(()=>l,[])})(u,z,k.current,V,I,x);const $=(0,r.useRef)();(0,r.useLayoutEffect)(()=>{const e=$.current,t=u;if($.current=u,null==e||null==e.compDetails||null==t||null==t.compDetails)return;const i=e.compDetails,r=t.compDetails;i.componentClass==r.componentClass&&null!=D.current&&null!=D.current.refresh&&1!=D.current.refresh(r.params)&&v(e=>e+1)},[u]),(0,r.useLayoutEffect)(()=>{if(!d||d.compDetails.componentFromFramework)return;const e=d.compDetails,i=!0===d.popup,r=(e=>{const t=e.newAgStackInstance();if(t)return t.resolveNow(null,e=>e)})(e);if(!r)return;const n=r.getGui();if(U(i,r),!i){const e=(_?N:x).current;null==e||e.appendChild(n),r.afterGuiAttached&&r.afterGuiAttached()}return R(r),()=>{t.destroyBean(r),U(i,void 0),R(void 0),n&&n.parentElement&&n.parentElement.removeChild(n)}},[d]);const q=(0,r.useCallback)(e=>{if(N.current=e,!N.current)return F.current.forEach(e=>e()),void(F.current=[]);const r=e=>{var i;if(e){const r=e.getGui();null==(i=N.current)||i.insertAdjacentElement("afterbegin",r),F.current.push(()=>{t.destroyBean(e),n._.removeFromParent(r)})}return e};w&&r(i.createSelectionCheckbox()),A&&r(i.createDndSource()),b&&r(i.createRowDragComp())},[i,t,A,b,w]),Q=(0,r.useCallback)(e=>{if(x.current=e,!x.current)return;if(!i)return;const t={addOrRemoveCssClass:(e,t)=>K.current.addOrRemoveCssClass(e,t),setUserStyles:e=>y(e),getFocusableElement:()=>x.current,setIncludeSelection:e=>S(e),setIncludeRowDrag:e=>E(e),setIncludeDndSource:e=>T(e),getCellEditor:()=>L.current||null,getCellRenderer:()=>D.current?D.current:I.current,getParentOfValue:()=>k.current?k.current:N.current?N.current:x.current,setRenderDetails:(e,t,i)=>{h(r=>(null==r?void 0:r.compDetails)!==e||(null==r?void 0:r.value)!==t||(null==r?void 0:r.force)!==i?{value:t,compDetails:e,force:i}:r)},setEditDetails:(e,t,i,r)=>{if(e){let n;r?n=new ie(e.params,()=>v(e=>e+1)):e.componentFromFramework&&Y(),p({compDetails:e,popup:t,popupPosition:i,compProxy:n}),t||h(void 0)}else p(e=>{(null==e?void 0:e.compProxy)&&(L.current=void 0)})}},r=N.current||void 0;i.setComp(t,x.current,r,s,o)},[]),X=(0,r.useMemo)(()=>!!(u&&u.compDetails&&u.compDetails.componentFromFramework&&G(u.compDetails.componentClass)),[u]);(0,r.useLayoutEffect)(()=>{var e;x.current&&(K.current.addOrRemoveCssClass("ag-cell-value",!z),K.current.addOrRemoveCssClass("ag-cell-inline-editing",!!d&&!d.popup),K.current.addOrRemoveCssClass("ag-cell-popup-editing",!!d&&!!d.popup),K.current.addOrRemoveCssClass("ag-cell-not-inline-editing",!d||!!d.popup),null==(e=i.getRowCtrl())||e.setInlineEditingCss(!!d),i.shouldRestoreFocus()&&!i.isEditing()&&x.current.focus({preventScroll:!0}))});const Z=()=>r.createElement(r.Fragment,null,null!=u&&((e,t,i,n,s,o,a)=>{const{compDetails:l,value:c}=e,u=!l,h=l&&l.componentFromFramework,d=l&&l.componentClass,p=(null==c?void 0:c.toString)?c.toString():c,m=()=>r.createElement(r.Fragment,null,u&&r.createElement(r.Fragment,null,p),h&&!o&&r.createElement(d,f(g({},l.params),{key:t,ref:n})),h&&o&&r.createElement(d,f(g({},l.params),{key:t})));return r.createElement(r.Fragment,null,s?r.createElement("span",{role:"presentation",id:`cell-${i}`,className:"ag-cell-value",ref:a},m()):m())})(u,m,c,D,z,X,B),null!=d&&((e,t,i,n,s,o)=>{const a=e.compDetails,l=a.componentClass,c=a.componentFromFramework&&!e.popup,u=a.componentFromFramework&&e.popup,h=!a.componentFromFramework&&e.popup;return r.createElement(r.Fragment,null,c&&re(e,l,t),u&&r.createElement(te,{editDetails:e,cellCtrl:s,eParentCell:n,wrappedContent:re(e,l,i)}),h&&o&&r.createElement(te,{editDetails:e,cellCtrl:s,eParentCell:n,jsChildComp:o}))})(d,j,W,x.current,i,M));return r.createElement("div",{ref:Q,style:C,tabIndex:a,role:P,"col-id":l},z?r.createElement("div",{className:"ag-cell-wrapper",role:"presentation",ref:q},Z()):Z())}),se=(0,r.memo)(e=>{const{context:t,gos:i}=(0,r.useContext)(O),{rowCtrl:s,containerType:o}=e,a=s.getTabIndex(),l=(0,r.useRef)(s.getDomOrder()),c=s.isFullWidth(),u=s.getRowNode().displayed,[h,d]=(0,r.useState)(()=>u?s.getRowIndex():null),[p,m]=(0,r.useState)(()=>s.getRowId()),[v,C]=(0,r.useState)(()=>s.getBusinessKey()),[y,w]=(0,r.useState)(()=>s.getRowStyles()),S=(0,r.useRef)(null),b=(0,r.useRef)(null),[E,A]=(0,r.useState)(()=>null),[T,M]=(0,r.useState)(),[R,_]=(0,r.useState)(()=>u?s.getInitialRowTop(o):void 0),[P,x]=(0,r.useState)(()=>u?s.getInitialTransform(o):void 0),D=(0,r.useRef)(null),I=(0,r.useRef)(),L=(0,r.useRef)(!1),[N,F]=(0,r.useState)(0);(0,r.useEffect)(()=>{var e;if(L.current)return;if(!T)return;if(N>10)return;const t=null==(e=D.current)?void 0:e.firstChild;t?(s.setupDetailRowAutoHeight(t),L.current=!0):F(e=>e+1)},[T,N]);let k=(0,r.useRef)();k.current||(k.current=new n.hv8(()=>D.current));const V=(0,r.useCallback)(e=>{if(D.current=e,!D.current)return void s.unsetComp(o);if(!s.isAlive())return;const t={setTop:_,setTransform:x,addOrRemoveCssClass:(e,t)=>k.current.addOrRemoveCssClass(e,t),setDomOrder:e=>l.current=e,setRowIndex:d,setRowId:m,setRowBusinessKey:C,setUserStyles:w,setCellCtrls:(e,t)=>{b.current=S.current,S.current=e;const i=z(b.current,e,l.current);i!==b.current&&B(t,()=>A(i))},showFullWidth:e=>M(e),getFullWidthCellRenderer:()=>I.current,refreshFullWidth:e=>$.current?(M(t=>f(g({},t),{params:e()})),!0):!(!I.current||!I.current.refresh)&&I.current.refresh(e())};s.setComp(t,D.current,o)},[]);(0,r.useLayoutEffect)(()=>U(T,t,D.current,I),[T]);const H=(0,r.useMemo)(()=>{const e={top:R,transform:P};return Object.assign(e,y),e},[R,P,y]),W=c&&T&&T.componentFromFramework,j=!c&&null!=E,K=(0,r.useMemo)(()=>!(!(null==T?void 0:T.componentFromFramework)||!G(T.componentClass)),[T]),$=(0,r.useRef)(!1);return(0,r.useEffect)(()=>{$.current=K&&!!T&&!!i.get("reactiveCustomComponents")},[K,T]),r.createElement("div",{ref:V,role:"row",style:H,"row-index":h,"row-id":p,"row-business-key":v,tabIndex:a},j&&(null==E?void 0:E.map(e=>r.createElement(ne,{cellCtrl:e,editingRow:s.isEditing(),printLayout:s.isPrintLayout(),key:e.getInstanceId()}))),W&&(()=>{const e=T.componentClass;return r.createElement(r.Fragment,null,K&&r.createElement(e,g({},T.params)),!K&&r.createElement(e,f(g({},T.params),{ref:I})))})())}),oe=(0,r.memo)(e=>{const{context:t}=(0,r.useContext)(O),{name:i}=e,s=(0,r.useMemo)(()=>(0,n.CSq)(i),[i]),o=(0,r.useRef)(null),a=(0,r.useRef)(null),l=(0,r.useRef)([]),c=(0,r.useRef)([]),[u,h]=(0,r.useState)(()=>[]),d=(0,r.useRef)(!1),p=(0,r.useRef)(),g=(0,r.useMemo)(()=>n.Rlq.getRowContainerCssClasses(i),[i]),f=(0,r.useMemo)(()=>F(g.viewport),[g]),m=(0,r.useMemo)(()=>F(g.container),[g]),v=i===n.lon.CENTER||i===n.lon.TOP_CENTER||i===n.lon.BOTTOM_CENTER||i===n.lon.STICKY_TOP_CENTER||i===n.lon.STICKY_BOTTOM_CENTER;ee(" AG Row Container "+i+" ",v?o:a);const C=(0,r.useCallback)(()=>v?null!=o.current&&null!=a.current:null!=a.current,[]),y=(0,r.useCallback)(()=>v?null==o.current&&null==a.current:null==a.current,[]),w=(0,r.useCallback)(()=>{if(y()&&(t.destroyBean(p.current),p.current=null),C()){const e=e=>{const t=z(c.current,l.current,d.current);t!==c.current&&(c.current=t,B(e,()=>h(t)))},r={setViewportHeight:e=>{o.current&&(o.current.style.height=e)},setRowCtrls:({rowCtrls:t,useFlushSync:i})=>{const r=!!i&&l.current.length>0&&t.length>0;l.current=t,e(r)},setDomOrder:t=>{d.current!=t&&(d.current=t,e(!1))},setContainerWidth:e=>{a.current&&(a.current.style.width=e)}};p.current=t.createBean(new n.Rlq(i)),p.current.setComp(r,a.current,o.current)}},[C,y]),S=(0,r.useCallback)(e=>{a.current=e,w()},[w]),b=(0,r.useCallback)(e=>{o.current=e,w()},[w]),E=()=>r.createElement("div",{className:m,ref:S,role:"rowgroup"},u.map(e=>r.createElement(se,{rowCtrl:e,containerType:s,key:e.getInstanceId()})));return r.createElement(r.Fragment,null,v?r.createElement("div",{className:f,ref:b,role:"presentation"},E()):E())}),ae=(0,r.memo)(()=>{const{context:e,agStackComponentsRegistry:t,resizeObserverService:i}=(0,r.useContext)(O),[s,o]=(0,r.useState)(""),[a,l]=(0,r.useState)(0),[c,u]=(0,r.useState)(0),[h,d]=(0,r.useState)("0px"),[p,g]=(0,r.useState)("0px"),[f,m]=(0,r.useState)("100%"),[v,C]=(0,r.useState)("0px"),[y,w]=(0,r.useState)("0px"),[S,b]=(0,r.useState)("100%"),[E,A]=(0,r.useState)(""),[T,M]=(0,r.useState)(""),[R,_]=(0,r.useState)(null),[P,x]=(0,r.useState)(""),[D,I]=(0,r.useState)(null),[L,N]=(0,r.useState)("ag-layout-normal");let k=(0,r.useRef)();k.current||(k.current=new n.hv8(()=>G.current));const G=(0,r.useRef)(null),V=(0,r.useRef)(null),H=(0,r.useRef)(null),B=(0,r.useRef)(null),z=(0,r.useRef)(null),U=(0,r.useRef)(null),W=(0,r.useRef)(null),j=(0,r.useRef)([]),K=(0,r.useRef)([]);ee(" AG Grid Body ",G),ee(" AG Pinned Top ",V),ee(" AG Sticky Top ",H),ee(" AG Middle ",U),ee(" AG Pinned Bottom ",W);const $=(0,r.useCallback)(r=>{if(G.current=r,!G.current)return e.destroyBeans(j.current),K.current.forEach(e=>e()),j.current=[],void(K.current=[]);if(!e)return;const s=i=>{const r=t.getComponentClass(i),n=e.createBean(new r);return j.current.push(n),n},a=(e,t)=>{e.appendChild(t),K.current.push(()=>e.removeChild(t))};a(G.current,document.createComment(" AG Fake Horizontal Scroll ")),a(G.current,s("AG-FAKE-HORIZONTAL-SCROLL").getGui()),a(G.current,document.createComment(" AG Overlay Wrapper ")),a(G.current,s("AG-OVERLAY-WRAPPER").getGui()),z.current&&(a(z.current,document.createComment(" AG Fake Vertical Scroll ")),a(z.current,s("AG-FAKE-VERTICAL-SCROLL").getGui()));const c={setRowAnimationCssOnBodyViewport:o,setColumnCount:e=>{G.current&&n._.setAriaColCount(G.current,e)},setRowCount:e=>{G.current&&n._.setAriaRowCount(G.current,e)},setTopHeight:l,setBottomHeight:u,setStickyTopHeight:d,setStickyTopTop:g,setStickyTopWidth:m,setTopDisplay:A,setBottomDisplay:M,setColumnMovingCss:(e,t)=>k.current.addOrRemoveCssClass(e,t),updateLayoutClasses:N,setAlwaysVerticalScrollClass:_,setPinnedTopBottomOverflowY:x,setCellSelectableCss:(e,t)=>I(t?e:null),setBodyViewportWidth:e=>{U.current&&(U.current.style.width=e)},registerBodyViewportResizeListener:e=>{if(U.current){const t=i.observeResize(U.current,e);K.current.push(()=>t())}},setStickyBottomHeight:C,setStickyBottomBottom:w,setStickyBottomWidth:b},h=e.createBean(new n.m20);j.current.push(h),h.setComp(c,G.current,U.current,V.current,W.current,H.current,B.current)},[]),q=(0,r.useMemo)(()=>F("ag-root","ag-unselectable",L),[L]),Y=(0,r.useMemo)(()=>F("ag-body-viewport",s,L,R,D),[s,L,R,D]),Q=(0,r.useMemo)(()=>F("ag-body",L),[L]),X=(0,r.useMemo)(()=>F("ag-floating-top",D),[D]),Z=(0,r.useMemo)(()=>F("ag-sticky-top",D),[D]),te=(0,r.useMemo)(()=>F("ag-sticky-bottom",D),[D]),ie=(0,r.useMemo)(()=>F("ag-floating-bottom",D),[D]),re=(0,r.useMemo)(()=>({height:a,minHeight:a,display:E,overflowY:P}),[a,E,P]),ne=(0,r.useMemo)(()=>({height:h,top:p,width:f}),[h,p,f]),se=(0,r.useMemo)(()=>({height:v,bottom:y,width:S}),[v,y,S]),ae=(0,r.useMemo)(()=>({height:c,minHeight:c,display:T,overflowY:P}),[c,T,P]),le=e=>r.createElement(oe,{name:e,key:`${e}-container`}),ce=({section:e,children:t,className:i,style:n})=>r.createElement("div",{ref:e,className:i,role:"presentation",style:n},t.map(le));return r.createElement("div",{ref:$,className:q,role:"treegrid"},r.createElement(J,null),ce({section:V,className:X,style:re,children:[n.lon.TOP_LEFT,n.lon.TOP_CENTER,n.lon.TOP_RIGHT,n.lon.TOP_FULL_WIDTH]}),r.createElement("div",{className:Q,ref:z,role:"presentation"},ce({section:U,className:Y,children:[n.lon.LEFT,n.lon.CENTER,n.lon.RIGHT,n.lon.FULL_WIDTH]})),ce({section:H,className:Z,style:ne,children:[n.lon.STICKY_TOP_LEFT,n.lon.STICKY_TOP_CENTER,n.lon.STICKY_TOP_RIGHT,n.lon.STICKY_TOP_FULL_WIDTH]}),ce({section:B,className:te,style:se,children:[n.lon.STICKY_BOTTOM_LEFT,n.lon.STICKY_BOTTOM_CENTER,n.lon.STICKY_BOTTOM_RIGHT,n.lon.STICKY_BOTTOM_FULL_WIDTH]}),ce({section:W,className:ie,style:ae,children:[n.lon.BOTTOM_LEFT,n.lon.BOTTOM_CENTER,n.lon.BOTTOM_RIGHT,n.lon.BOTTOM_FULL_WIDTH]}))}),le=(0,r.forwardRef)((e,t)=>{const{children:i,eFocusableElement:s,onTabKeyDown:o,gridCtrl:a,forceFocusOutWhenTabGuardsAreEmpty:l}=e,{context:c}=(0,r.useContext)(O),u=(0,r.useRef)(null),h=(0,r.useRef)(null),d=(0,r.useRef)(),p=e=>{const t=null==e?void 0:parseInt(e,10).toString();[u,h].forEach(e=>{var i,r;void 0===t?null==(i=e.current)||i.removeAttribute("tabindex"):null==(r=e.current)||r.setAttribute("tabindex",t)})};(0,r.useImperativeHandle)(t,()=>({forceFocusOutOfContainer(e){var t;null==(t=d.current)||t.forceFocusOutOfContainer(e)}}));const g=(0,r.useCallback)(()=>{if(!u.current&&!h.current)return c.destroyBean(d.current),void(d.current=null);if(u.current&&h.current){const e={setTabIndex:p};d.current=c.createBean(new n.Udn({comp:e,eTopGuard:u.current,eBottomGuard:h.current,eFocusableElement:s,onTabKeyDown:o,forceFocusOutWhenTabGuardsAreEmpty:l,focusInnerElement:e=>a.focusInnerElement(e)}))}},[]),f=(0,r.useCallback)(e=>{u.current=e,g()},[g]),m=(0,r.useCallback)(e=>{h.current=e,g()},[g]),v=e=>{const t="top"===e?n.pA9.TAB_GUARD_TOP:n.pA9.TAB_GUARD_BOTTOM;return r.createElement("div",{className:`${n.pA9.TAB_GUARD} ${t}`,role:"presentation",ref:"top"===e?f:m})};return r.createElement(r.Fragment,null,v("top"),i,v("bottom"))}),ce=(0,r.memo)(le),ue=(0,r.memo)(({context:e})=>{const[t,i]=(0,r.useState)(""),[s,o]=(0,r.useState)(""),[a,l]=(0,r.useState)(""),[c,u]=(0,r.useState)(null),[h,d]=(0,r.useState)(null),[p,g]=(0,r.useState)(!1),[f,m]=(0,r.useState)(),v=(0,r.useRef)(null),C=(0,r.useRef)(null),y=(0,r.useRef)(),[w,S]=(0,r.useState)(null),b=(0,r.useRef)(()=>{}),E=(0,r.useCallback)(()=>{},[]),A=(0,r.useMemo)(()=>e.isDestroyed()?null:e.getBean("beans"),[e]);ee(" AG Grid ",C);const T=(0,r.useCallback)(t=>{if(C.current=t,!C.current)return e.destroyBean(v.current),void(v.current=null);if(e.isDestroyed())return;v.current=e.createBean(new n.s1r);const r=v.current;b.current=r.focusInnerElement.bind(r);const s={destroyGridUi:()=>{},setRtlClass:i,forceFocusOutOfContainer:e=>{var t;null==(t=y.current)||t.forceFocusOutOfContainer(e)},updateLayoutClasses:l,getFocusableContainers:()=>{var e,t;const i=[],r=null==(e=C.current)?void 0:e.querySelector(".ag-root"),n=null==(t=C.current)?void 0:t.querySelector(".ag-side-bar:not(.ag-hidden)");return r&&i.push(r),n&&i.push(n),i},setCursor:u,setUserSelect:d};r.setComp(s,C.current,C.current),g(!0)},[]);(0,r.useEffect)(()=>{if(!(f&&A&&v.current&&w&&C.current))return;const t=v.current,i=[],{agStackComponentsRegistry:r}=A,n=r.getComponentClass("AG-GRID-HEADER-DROP-ZONES"),s=r.getComponentClass("AG-SIDE-BAR"),o=r.getComponentClass("AG-STATUS-BAR"),a=r.getComponentClass("AG-WATERMARK"),l=r.getComponentClass("AG-PAGINATION"),c=[],u=C.current;if(t.showDropZones()&&n){const t=e.createBean(new n),r=t.getGui();u.insertAdjacentElement("afterbegin",r),c.push(r),i.push(t)}if(t.showSideBar()&&s){const t=e.createBean(new s),r=t.getGui(),n=w.querySelector(".ag-tab-guard-bottom");n&&(n.insertAdjacentElement("beforebegin",r),c.push(r)),i.push(t)}if(t.showStatusBar()&&o){const t=e.createBean(new o),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}if(l){const t=e.createBean(new l),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}if(t.showWatermark()&&a){const t=e.createBean(new a),r=t.getGui();u.insertAdjacentElement("beforeend",r),c.push(r),i.push(t)}return()=>{e.destroyBeans(i),c.forEach(e=>{e.parentElement&&e.parentElement.removeChild(e)})}},[f,w,A]);const M=(0,r.useMemo)(()=>F("ag-root-wrapper",t,s,a),[t,s,a]),R=(0,r.useMemo)(()=>F("ag-root-wrapper-body","ag-focus-managed",a),[a]),_=(0,r.useMemo)(()=>({userSelect:null!=h?h:"",WebkitUserSelect:null!=h?h:"",cursor:null!=c?c:""}),[h,c]),P=(0,r.useCallback)(e=>{y.current=e,m(null!==e)},[]);return r.createElement("div",{ref:T,className:M,style:_,role:"presentation"},r.createElement("div",{className:R,ref:S,role:"presentation"},p&&w&&A&&r.createElement(O.Provider,{value:A},r.createElement(ce,{ref:P,eFocusableElement:w,onTabKeyDown:E,gridCtrl:v.current,forceFocusOutWhenTabGuardsAreEmpty:!0},r.createElement(ae,null)))))}),he=e=>{var t,i;const s=(0,r.useRef)(),o=(0,r.useRef)(null),a=(0,r.useRef)(null),l=(0,r.useRef)([]),c=(0,r.useRef)([]),u=(0,r.useRef)(e),h=(0,r.useRef)(!1),[d,p]=(0,r.useState)(void 0),[,f]=(0,r.useState)(0),m=(0,r.useCallback)(t=>{if(o.current=t,!o.current)return l.current.forEach(e=>e()),void(l.current.length=0);const i=e.modules||[];a.current||(a.current=new N(()=>f(e=>e+1),e.componentWrappingElement,e.maxComponentCreationTimeMs),l.current.push(()=>{var e;null==(e=a.current)||e.destroy(),a.current=null}));const r=n.kNx.combineAttributesAndGridOptions(e.gridOptions,e),u={providedBeanInstances:{frameworkComponentWrapper:new de(a.current,!!r.reactiveCustomComponents)},modules:i,frameworkOverrides:new ge},d=new n.Ug$;s.current=d.create(o.current,r,t=>{p(t),l.current.push(()=>{t.destroy()}),t.getBean(n.GsR.NAME).whenReady(()=>{if(t.isDestroyed())return;const i=s.current;i&&e.setGridApi&&e.setGridApi(i,new n.jf3(i))})},e=>{e.getBean(n.GsR.NAME).whenReady(()=>{c.current.forEach(e=>e()),c.current.length=0,h.current=!0})},u)},[]),v=(0,r.useMemo)(()=>g({height:"100%"},e.containerStyle||{}),[e.containerStyle]),C=(0,r.useCallback)(e=>{h.current?e():c.current.push(e)},[]);return(0,r.useEffect)(()=>{const t=function(e,t){const i={};return Object.keys(t).forEach(r=>{const n=t[r];e[r]!==n&&(i[r]=n)}),i}(u.current,e);u.current=e,C(()=>{s.current&&n.kNx.processOnChange(t,s.current)})},[e]),r.createElement("div",{style:v,className:e.className,ref:m},d&&!d.isDestroyed()?r.createElement(ue,{context:d}):null,null!=(i=null==(t=a.current)?void 0:t.getPortals())?i:null)},de=class extends n.Cf3{constructor(e,t){super(),this.parent=e,this.reactiveCustomComponents=t}createWrapper(e,t){if(this.reactiveCustomComponents){const i=(e=>{switch(e){case"filter":return A;case"floatingFilterComponent":return R;case"dateComponent":return E;case"loadingOverlayComponent":return _;case"noRowsOverlayComponent":return x;case"statusPanel":return D;case"toolPanel":return I;case"menuItem":return P}})(t.propertyName);if(i)return new i(e,this.parent,t)}else switch(t.propertyName){case"filter":case"floatingFilterComponent":case"dateComponent":case"loadingOverlayComponent":case"noRowsOverlayComponent":case"statusPanel":case"toolPanel":case"menuItem":Y()}const i=!t.cellRenderer&&"toolPanel"!==t.propertyName;return new w(e,this.parent,t,i)}},pe=(0,r.forwardRef)((e,t)=>{const{ctrlsFactory:i,context:s,gos:o,resizeObserverService:a,clientSideRowModel:l,serverSideRowModel:c}=(0,r.useContext)(O),[u,h]=(0,r.useState)(()=>new k),[d,p]=(0,r.useState)(()=>new k),[m,v]=(0,r.useState)(),[C,y]=(0,r.useState)(),w=(0,r.useRef)(),S=(0,r.useRef)(null),b=(0,r.useRef)(),E=(0,r.useMemo)(()=>n.syG.__getGridRegisteredModules(e.api.getGridId()),[e]),A=(0,r.useMemo)(()=>u.toString()+" ag-details-row",[u]),T=(0,r.useMemo)(()=>d.toString()+" ag-details-grid",[d]);t&&(0,r.useImperativeHandle)(t,()=>({refresh(){var e,t;return null!=(t=null==(e=w.current)?void 0:e.refresh())&&t}})),e.template&&n._.warnOnce("detailCellRendererParams.template is not supported by AG Grid React. To change the template, provide a Custom Detail Cell Renderer. See https://ag-grid.com/react-data-grid/master-detail-custom-detail/");const M=(0,r.useCallback)(t=>{if(S.current=t,!S.current)return s.destroyBean(w.current),void(b.current&&b.current());const r={addOrRemoveCssClass:(e,t)=>h(i=>i.setClass(e,t)),addOrRemoveDetailGridCssClass:(e,t)=>p(i=>i.setClass(e,t)),setDetailGrid:e=>v(e),setRowData:e=>y(e),getGui:()=>S.current},n=i.getInstance("detailCellRenderer");if(n&&(s.createBean(n),n.init(r,e),w.current=n,o.get("detailRowAutoHeight"))){const t=()=>{if(null==S.current)return;const t=S.current.clientHeight;null!=t&&t>0&&setTimeout(()=>{e.node.setRowHeight(t),l?l.onRowHeightChanged():c&&c.onRowHeightChanged()},0)};b.current=a.observeResize(S.current,t),t()}},[]),R=(0,r.useCallback)((e,t)=>{var i;null==(i=w.current)||i.registerDetailWithMaster(e,t)},[]);return r.createElement("div",{className:A,ref:M},m&&r.createElement(he,f(g({className:T},m),{modules:E,rowData:C,setGridApi:R})))}),ge=class extends n.pow{constructor(){super("react"),this.frameworkComponents={agGroupCellRenderer:K,agGroupRowRenderer:K,agDetailCellRenderer:pe},this.wrapIncoming=(e,t)=>{return"ensureVisible"===t?(i=e,H||setTimeout(()=>H=!1,0),H=!0,i()):e();var i},this.renderingEngine="react"}frameworkComponent(e){return this.frameworkComponents[e]}isFrameworkComponent(e){if(!e)return!1;const t=e.prototype;return!(t&&"getGui"in t)}},fe=class extends r.Component{constructor(){super(...arguments),this.apiListeners=[],this.setGridApi=(e,t)=>{this.api=e,this.columnApi=t,this.apiListeners.forEach(t=>t(e))}}registerApiListener(e){this.apiListeners.push(e)}componentWillUnmount(){this.apiListeners.length=0}render(){return r.createElement(he,f(g({},this.props),{setGridApi:this.setGridApi}))}}},80183(e,t,i){"use strict";i.d(t,{A:()=>bt});var r={};function n(e,t){return function(){return e.apply(t,arguments)}}i.r(r),i.d(r,{hasBrowserEnv:()=>Te,hasStandardBrowserEnv:()=>Re,hasStandardBrowserWebWorkerEnv:()=>_e,navigator:()=>Me,origin:()=>Pe});var s=i(85409);const{toString:o}=Object.prototype,{getPrototypeOf:a}=Object,{iterator:l,toStringTag:c}=Symbol,u=(h=Object.create(null),e=>{const t=o.call(e);return h[t]||(h[t]=t.slice(8,-1).toLowerCase())});var h;const d=e=>(e=e.toLowerCase(),t=>u(t)===e),p=e=>t=>typeof t===e,{isArray:g}=Array,f=p("undefined");function m(e){return null!==e&&!f(e)&&null!==e.constructor&&!f(e.constructor)&&y(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const v=d("ArrayBuffer"),C=p("string"),y=p("function"),w=p("number"),S=e=>null!==e&&"object"==typeof e,b=e=>{if("object"!==u(e))return!1;const t=a(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||c in e||l in e)},E=d("Date"),A=d("File"),T=d("Blob"),M=d("FileList"),R="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:{},_=void 0!==R.FormData?R.FormData:void 0,P=d("URLSearchParams"),[x,D,I,L]=["ReadableStream","Request","Response","Headers"].map(d);function N(e,t,{allOwnKeys:i=!1}={}){if(null==e)return;let r,n;if("object"!=typeof e&&(e=[e]),g(e))for(r=0,n=e.length;r<n;r++)t.call(null,e[r],r,e);else{if(m(e))return;const n=i?Object.getOwnPropertyNames(e):Object.keys(e),s=n.length;let o;for(r=0;r<s;r++)o=n[r],t.call(null,e[o],o,e)}}function O(e,t){if(m(e))return null;t=t.toLowerCase();const i=Object.keys(e);let r,n=i.length;for(;n-- >0;)if(r=i[n],t===r.toLowerCase())return r;return null}const F="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:globalThis,k=e=>!f(e)&&e!==F,G=(V="undefined"!=typeof Uint8Array&&a(Uint8Array),e=>V&&e instanceof V);var V;const H=d("HTMLFormElement"),B=(({hasOwnProperty:e})=>(t,i)=>e.call(t,i))(Object.prototype),z=d("RegExp"),U=(e,t)=>{const i=Object.getOwnPropertyDescriptors(e),r={};N(i,(i,n)=>{let s;!1!==(s=t(i,n,e))&&(r[n]=s||i)}),Object.defineProperties(e,r)},W=d("AsyncFunction"),j=(K="function"==typeof setImmediate,$=y(F.postMessage),K?setImmediate:$?(q=`axios@${Math.random()}`,Y=[],F.addEventListener("message",({source:e,data:t})=>{e===F&&t===q&&Y.length&&Y.shift()()},!1),e=>{Y.push(e),F.postMessage(q,"*")}):e=>setTimeout(e));var K,$,q,Y;const Q="undefined"!=typeof queueMicrotask?queueMicrotask.bind(F):void 0!==s&&s.nextTick||j,X={isArray:g,isArrayBuffer:v,isBuffer:m,isFormData:e=>{if(!e)return!1;if(_&&e instanceof _)return!0;const t=a(e);if(!t||t===Object.prototype)return!1;if(!y(e.append))return!1;const i=u(e);return"formdata"===i||"object"===i&&y(e.toString)&&"[object FormData]"===e.toString()},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&v(e.buffer),t},isString:C,isNumber:w,isBoolean:e=>!0===e||!1===e,isObject:S,isPlainObject:b,isEmptyObject:e=>{if(!S(e)||m(e))return!1;try{return 0===Object.keys(e).length&&Object.getPrototypeOf(e)===Object.prototype}catch(e){return!1}},isReadableStream:x,isRequest:D,isResponse:I,isHeaders:L,isUndefined:f,isDate:E,isFile:A,isReactNativeBlob:e=>!(!e||void 0===e.uri),isReactNative:e=>e&&void 0!==e.getParts,isBlob:T,isRegExp:z,isFunction:y,isStream:e=>S(e)&&y(e.pipe),isURLSearchParams:P,isTypedArray:G,isFileList:M,forEach:N,merge:function e(...t){const{caseless:i,skipUndefined:r}=k(this)&&this||{},n={},s=(t,s)=>{if("__proto__"===s||"constructor"===s||"prototype"===s)return;const o=i&&O(n,s)||s,a=B(n,o)?n[o]:void 0;b(a)&&b(t)?n[o]=e(a,t):b(t)?n[o]=e({},t):g(t)?n[o]=t.slice():r&&f(t)||(n[o]=t)};for(let e=0,i=t.length;e<i;e++)t[e]&&N(t[e],s);return n},extend:(e,t,i,{allOwnKeys:r}={})=>(N(t,(t,r)=>{i&&y(t)?Object.defineProperty(e,r,{__proto__:null,value:n(t,i),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,r,{__proto__:null,value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,i,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{__proto__:null,value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{__proto__:null,value:t.prototype}),i&&Object.assign(e.prototype,i)},toFlatObject:(e,t,i,r)=>{let n,s,o;const l={};if(t=t||{},null==e)return t;do{for(n=Object.getOwnPropertyNames(e),s=n.length;s-- >0;)o=n[s],r&&!r(o,e,t)||l[o]||(t[o]=e[o],l[o]=!0);e=!1!==i&&a(e)}while(e&&(!i||i(e,t))&&e!==Object.prototype);return t},kindOf:u,kindOfTest:d,endsWith:(e,t,i)=>{e=String(e),(void 0===i||i>e.length)&&(i=e.length),i-=t.length;const r=e.indexOf(t,i);return-1!==r&&r===i},toArray:e=>{if(!e)return null;if(g(e))return e;let t=e.length;if(!w(t))return null;const i=new Array(t);for(;t-- >0;)i[t]=e[t];return i},forEachEntry:(e,t)=>{const i=(e&&e[l]).call(e);let r;for(;(r=i.next())&&!r.done;){const i=r.value;t.call(e,i[0],i[1])}},matchAll:(e,t)=>{let i;const r=[];for(;null!==(i=e.exec(t));)r.push(i);return r},isHTMLForm:H,hasOwnProperty:B,hasOwnProp:B,reduceDescriptors:U,freezeMethods:e=>{U(e,(t,i)=>{if(y(e)&&["arguments","caller","callee"].includes(i))return!1;const r=e[i];y(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+i+"'")}))})},toObjectSet:(e,t)=>{const i={},r=e=>{e.forEach(e=>{i[e]=!0})};return g(e)?r(e):r(String(e).split(t)),i},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,i){return t.toUpperCase()+i}),noop:()=>{},toFiniteNumber:(e,t)=>null!=e&&Number.isFinite(e=+e)?e:t,findKey:O,global:F,isContextDefined:k,isSpecCompliantForm:function(e){return!!(e&&y(e.append)&&"FormData"===e[c]&&e[l])},toJSONObject:e=>{const t=new WeakSet,i=e=>{if(S(e)){if(t.has(e))return;if(m(e))return e;if(!("toJSON"in e)){t.add(e);const r=g(e)?[]:{};return N(e,(e,t)=>{const n=i(e);!f(n)&&(r[t]=n)}),t.delete(e),r}}return e};return i(e)},isAsyncFn:W,isThenable:e=>e&&(S(e)||y(e))&&y(e.then)&&y(e.catch),setImmediate:j,asap:Q,isIterable:e=>null!=e&&y(e[l])},Z=X.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),J=new RegExp("[\\u0000-\\u0008\\u000a-\\u001f\\u007f]+","g"),ee=new RegExp("[^\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+","g");function te(e,t){return X.isArray(e)?e.map(e=>te(e,t)):function(e){let t=0,i=e.length;for(;t<i;){const i=e.charCodeAt(t);if(9!==i&&32!==i)break;t+=1}for(;i>t;){const t=e.charCodeAt(i-1);if(9!==t&&32!==t)break;i-=1}return 0===t&&i===e.length?e:e.slice(t,i)}(String(e).replace(t,""))}function ie(e){const t=Object.create(null);return X.forEach(e.toJSON(),(e,i)=>{t[i]=(e=>te(e,ee))(e)}),t}const re=Symbol("internals");function ne(e){return e&&String(e).trim().toLowerCase()}function se(e){return!1===e||null==e?e:X.isArray(e)?e.map(se):(e=>te(e,J))(String(e))}function oe(e,t,i,r,n){return X.isFunction(r)?r.call(this,t,i):(n&&(t=i),X.isString(t)?X.isString(r)?-1!==t.indexOf(r):X.isRegExp(r)?r.test(t):void 0:void 0)}class ae{constructor(e){e&&this.set(e)}set(e,t,i){const r=this;function n(e,t,i){const n=ne(t);if(!n)throw new Error("header name must be a non-empty string");const s=X.findKey(r,n);(!s||void 0===r[s]||!0===i||void 0===i&&!1!==r[s])&&(r[s||t]=se(e))}const s=(e,t)=>X.forEach(e,(e,i)=>n(e,i,t));if(X.isPlainObject(e)||e instanceof this.constructor)s(e,t);else if(X.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim()))s((e=>{const t={};let i,r,n;return e&&e.split("\n").forEach(function(e){n=e.indexOf(":"),i=e.substring(0,n).trim().toLowerCase(),r=e.substring(n+1).trim(),!i||t[i]&&Z[i]||("set-cookie"===i?t[i]?t[i].push(r):t[i]=[r]:t[i]=t[i]?t[i]+", "+r:r)}),t})(e),t);else if(X.isObject(e)&&X.isIterable(e)){let i,r,n={};for(const t of e){if(!X.isArray(t))throw TypeError("Object iterator must return a key-value pair");n[r=t[0]]=(i=n[r])?X.isArray(i)?[...i,t[1]]:[i,t[1]]:t[1]}s(n,t)}else null!=e&&n(t,e,i);return this}get(e,t){if(e=ne(e)){const i=X.findKey(this,e);if(i){const e=this[i];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),i=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=i.exec(e);)t[r[1]]=r[2];return t}(e);if(X.isFunction(t))return t.call(this,e,i);if(X.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=ne(e)){const i=X.findKey(this,e);return!(!i||void 0===this[i]||t&&!oe(0,this[i],i,t))}return!1}delete(e,t){const i=this;let r=!1;function n(e){if(e=ne(e)){const n=X.findKey(i,e);!n||t&&!oe(0,i[n],n,t)||(delete i[n],r=!0)}}return X.isArray(e)?e.forEach(n):n(e),r}clear(e){const t=Object.keys(this);let i=t.length,r=!1;for(;i--;){const n=t[i];e&&!oe(0,this[n],n,e,!0)||(delete this[n],r=!0)}return r}normalize(e){const t=this,i={};return X.forEach(this,(r,n)=>{const s=X.findKey(i,n);if(s)return t[s]=se(r),void delete t[n];const o=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,i)=>t.toUpperCase()+i)}(n):String(n).trim();o!==n&&delete t[n],t[o]=se(r),i[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return X.forEach(this,(i,r)=>{null!=i&&!1!==i&&(t[r]=e&&X.isArray(i)?i.join(", "):i)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+": "+t).join("\n")}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const i=new this(e);return t.forEach(e=>i.set(e)),i}static accessor(e){const t=(this[re]=this[re]={accessors:{}}).accessors,i=this.prototype;function r(e){const r=ne(e);t[r]||(function(e,t){const i=X.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+i,{__proto__:null,value:function(e,i,n){return this[r].call(this,t,e,i,n)},configurable:!0})})}(i,e),t[r]=!0)}return X.isArray(e)?e.forEach(r):r(e),this}}ae.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),X.reduceDescriptors(ae.prototype,({value:e},t)=>{let i=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[i]=e}}}),X.freezeMethods(ae);const le=ae;class ce extends Error{static from(e,t,i,r,n,s){const o=new ce(e.message,t||e.code,i,r,n);return o.cause=e,o.name=e.name,null!=e.status&&null==o.status&&(o.status=e.status),s&&Object.assign(o,s),o}constructor(e,t,i,r,n){super(e),Object.defineProperty(this,"message",{__proto__:null,value:e,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,t&&(this.code=t),i&&(this.config=i),r&&(this.request=r),n&&(this.response=n,this.status=n.status)}toJSON(){const e=this.config,t=e&&X.hasOwnProp(e,"redact")?e.redact:void 0,i=X.isArray(t)&&t.length>0?function(e,t){const i=new Set(t.map(e=>String(e).toLowerCase())),r=[],n=e=>{if(null===e||"object"!=typeof e)return e;if(X.isBuffer(e))return e;if(-1!==r.indexOf(e))return;let t;if(e instanceof le&&(e=e.toJSON()),r.push(e),X.isArray(e))t=[],e.forEach((e,i)=>{const r=n(e);X.isUndefined(r)||(t[i]=r)});else{if(!X.isPlainObject(e)&&function(e){if(X.hasOwnProp(e,"toJSON"))return!0;let t=Object.getPrototypeOf(e);for(;t&&t!==Object.prototype;){if(X.hasOwnProp(t,"toJSON"))return!0;t=Object.getPrototypeOf(t)}return!1}(e))return r.pop(),e;t=Object.create(null);for(const[r,s]of Object.entries(e)){const e=i.has(r.toLowerCase())?"[REDACTED ****]":n(s);X.isUndefined(e)||(t[r]=e)}}return r.pop(),t};return n(e)}(e,t):X.toJSONObject(e);return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:i,code:this.code,status:this.status}}}ce.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE",ce.ERR_BAD_OPTION="ERR_BAD_OPTION",ce.ECONNABORTED="ECONNABORTED",ce.ETIMEDOUT="ETIMEDOUT",ce.ECONNREFUSED="ECONNREFUSED",ce.ERR_NETWORK="ERR_NETWORK",ce.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS",ce.ERR_DEPRECATED="ERR_DEPRECATED",ce.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE",ce.ERR_BAD_REQUEST="ERR_BAD_REQUEST",ce.ERR_CANCELED="ERR_CANCELED",ce.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT",ce.ERR_INVALID_URL="ERR_INVALID_URL",ce.ERR_FORM_DATA_DEPTH_EXCEEDED="ERR_FORM_DATA_DEPTH_EXCEEDED";const ue=ce;function he(e){return X.isPlainObject(e)||X.isArray(e)}function de(e){return X.endsWith(e,"[]")?e.slice(0,-2):e}function pe(e,t,i){return e?e.concat(t).map(function(e,t){return e=de(e),!i&&t?"["+e+"]":e}).join(i?".":""):t}const ge=X.toFlatObject(X,{},null,function(e){return/^is[A-Z]/.test(e)}),fe=function(e,t,i){if(!X.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(i=X.toFlatObject(i,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!X.isUndefined(t[e])})).metaTokens,n=i.visitor||h,s=i.dots,o=i.indexes,a=i.Blob||"undefined"!=typeof Blob&&Blob,l=void 0===i.maxDepth?100:i.maxDepth,c=a&&X.isSpecCompliantForm(t);if(!X.isFunction(n))throw new TypeError("visitor must be a function");function u(e){if(null===e)return"";if(X.isDate(e))return e.toISOString();if(X.isBoolean(e))return e.toString();if(!c&&X.isBlob(e))throw new ue("Blob is not supported. Use a Buffer instead.");return X.isArrayBuffer(e)||X.isTypedArray(e)?c&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function h(e,i,n){let a=e;if(X.isReactNative(t)&&X.isReactNativeBlob(e))return t.append(pe(n,i,s),u(e)),!1;if(e&&!n&&"object"==typeof e)if(X.endsWith(i,"{}"))i=r?i:i.slice(0,-2),e=JSON.stringify(e);else if(X.isArray(e)&&function(e){return X.isArray(e)&&!e.some(he)}(e)||(X.isFileList(e)||X.endsWith(i,"[]"))&&(a=X.toArray(e)))return i=de(i),a.forEach(function(e,r){!X.isUndefined(e)&&null!==e&&t.append(!0===o?pe([i],r,s):null===o?i:i+"[]",u(e))}),!1;return!!he(e)||(t.append(pe(n,i,s),u(e)),!1)}const d=[],p=Object.assign(ge,{defaultVisitor:h,convertValue:u,isVisitable:he});if(!X.isObject(e))throw new TypeError("data must be an object");return function e(i,r,s=0){if(!X.isUndefined(i)){if(s>l)throw new ue("Object is too deeply nested ("+s+" levels). Max depth: "+l,ue.ERR_FORM_DATA_DEPTH_EXCEEDED);if(-1!==d.indexOf(i))throw Error("Circular reference detected in "+r.join("."));d.push(i),X.forEach(i,function(i,o){!0===(!(X.isUndefined(i)||null===i)&&n.call(t,i,X.isString(o)?o.trim():o,r,p))&&e(i,r?r.concat(o):[o],s+1)}),d.pop()}}(e),t};function me(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+"};return encodeURIComponent(e).replace(/[!'()~]|%20/g,function(e){return t[e]})}function ve(e,t){this._pairs=[],e&&fe(e,this,t)}const Ce=ve.prototype;Ce.append=function(e,t){this._pairs.push([e,t])},Ce.toString=function(e){const t=e?function(t){return e.call(this,t,me)}:me;return this._pairs.map(function(e){return t(e[0])+"="+t(e[1])},"").join("&")};const ye=ve;function we(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Se(e,t,i){if(!t)return e;const r=i&&i.encode||we,n=X.isFunction(i)?{serialize:i}:i,s=n&&n.serialize;let o;if(o=s?s(t,n):X.isURLSearchParams(t)?t.toString():new ye(t,n).toString(r),o){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+o}return e}const be=class{constructor(){this.handlers=[]}use(e,t,i){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!i&&i.synchronous,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){X.forEach(this.handlers,function(t){null!==t&&e(t)})}},Ee={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},Ae={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:ye,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},protocols:["http","https","file","blob","url","data"]},Te="undefined"!=typeof window&&"undefined"!=typeof document,Me="object"==typeof navigator&&navigator||void 0,Re=Te&&(!Me||["ReactNative","NativeScript","NS"].indexOf(Me.product)<0),_e="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,Pe=Te&&window.location.href||"http://localhost",xe={...r,...Ae},De=function(e){function t(e,i,r,n){let s=e[n++];if("__proto__"===s)return!0;const o=Number.isFinite(+s),a=n>=e.length;return s=!s&&X.isArray(r)?r.length:s,a?(X.hasOwnProp(r,s)?r[s]=X.isArray(r[s])?r[s].concat(i):[r[s],i]:r[s]=i,!o):(X.hasOwnProp(r,s)&&X.isObject(r[s])||(r[s]=[]),t(e,i,r[s],n)&&X.isArray(r[s])&&(r[s]=function(e){const t={},i=Object.keys(e);let r;const n=i.length;let s;for(r=0;r<n;r++)s=i[r],t[s]=e[s];return t}(r[s])),!o)}if(X.isFormData(e)&&X.isFunction(e.entries)){const i={};return X.forEachEntry(e,(e,r)=>{t(function(e){return X.matchAll(/\w+|\[(\w*)]/g,e).map(e=>"[]"===e[0]?"":e[1]||e[0])}(e),r,i,0)}),i}return null},Ie=(e,t)=>null!=e&&X.hasOwnProp(e,t)?e[t]:void 0,Le={transitional:Ee,adapter:["xhr","http","fetch"],transformRequest:[function(e,t){const i=t.getContentType()||"",r=i.indexOf("application/json")>-1,n=X.isObject(e);if(n&&X.isHTMLForm(e)&&(e=new FormData(e)),X.isFormData(e))return r?JSON.stringify(De(e)):e;if(X.isArrayBuffer(e)||X.isBuffer(e)||X.isStream(e)||X.isFile(e)||X.isBlob(e)||X.isReadableStream(e))return e;if(X.isArrayBufferView(e))return e.buffer;if(X.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let s;if(n){const t=Ie(this,"formSerializer");if(i.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return fe(e,new xe.classes.URLSearchParams,{visitor:function(e,t,i,r){return xe.isNode&&X.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)},...t})}(e,t).toString();if((s=X.isFileList(e))||i.indexOf("multipart/form-data")>-1){const i=Ie(this,"env"),r=i&&i.FormData;return fe(s?{"files[]":e}:e,r&&new r,t)}}return n||r?(t.setContentType("application/json",!1),function(e){if(X.isString(e))try{return(0,JSON.parse)(e),X.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=Ie(this,"transitional")||Le.transitional,i=t&&t.forcedJSONParsing,r=Ie(this,"responseType"),n="json"===r;if(X.isResponse(e)||X.isReadableStream(e))return e;if(e&&X.isString(e)&&(i&&!r||n)){const i=!(t&&t.silentJSONParsing)&&n;try{return JSON.parse(e,Ie(this,"parseReviver"))}catch(e){if(i){if("SyntaxError"===e.name)throw ue.from(e,ue.ERR_BAD_RESPONSE,this,null,Ie(this,"response"));throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:xe.classes.FormData,Blob:xe.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};X.forEach(["delete","get","head","post","put","patch","query"],e=>{Le.headers[e]={}});const Ne=Le;function Oe(e,t){const i=this||Ne,r=t||i,n=le.from(r.headers);let s=r.data;return X.forEach(e,function(e){s=e.call(i,s,n.normalize(),t?t.status:void 0)}),n.normalize(),s}function Fe(e){return!(!e||!e.__CANCEL__)}const ke=class extends ue{constructor(e,t,i){super(null==e?"canceled":e,ue.ERR_CANCELED,t,i),this.name="CanceledError",this.__CANCEL__=!0}};function Ge(e,t,i){const r=i.config.validateStatus;i.status&&r&&!r(i.status)?t(new ue("Request failed with status code "+i.status,i.status>=400&&i.status<500?ue.ERR_BAD_REQUEST:ue.ERR_BAD_RESPONSE,i.config,i.request,i)):e(i)}const Ve=(e,t,i=3)=>{let r=0;const n=function(e,t){e=e||10;const i=new Array(e),r=new Array(e);let n,s=0,o=0;return t=void 0!==t?t:1e3,function(a){const l=Date.now(),c=r[o];n||(n=l),i[s]=a,r[s]=l;let u=o,h=0;for(;u!==s;)h+=i[u++],u%=e;if(s=(s+1)%e,s===o&&(o=(o+1)%e),l-n<t)return;const d=c&&l-c;return d?Math.round(1e3*h/d):void 0}}(50,250);return function(e,t){let i,r,n=0,s=1e3/t;const o=(t,s=Date.now())=>{n=s,i=null,r&&(clearTimeout(r),r=null),e(...t)};return[(...e)=>{const t=Date.now(),a=t-n;a>=s?o(e,t):(i=e,r||(r=setTimeout(()=>{r=null,o(i)},s-a)))},()=>i&&o(i)]}(i=>{if(!i||"number"!=typeof i.loaded)return;const s=i.loaded,o=i.lengthComputable?i.total:void 0,a=null!=o?Math.min(s,o):s,l=Math.max(0,a-r),c=n(l);r=Math.max(r,a),e({loaded:a,total:o,progress:o?a/o:void 0,bytes:l,rate:c||void 0,estimated:c&&o?(o-a)/c:void 0,event:i,lengthComputable:null!=o,[t?"download":"upload"]:!0})},i)},He=(e,t)=>{const i=null!=e;return[r=>t[0]({lengthComputable:i,total:e,loaded:r}),t[1]]},Be=e=>(...t)=>X.asap(()=>e(...t)),ze=xe.hasStandardBrowserEnv?((e,t)=>i=>(i=new URL(i,xe.origin),e.protocol===i.protocol&&e.host===i.host&&(t||e.port===i.port)))(new URL(xe.origin),xe.navigator&&/(msie|trident)/i.test(xe.navigator.userAgent)):()=>!0,Ue=xe.hasStandardBrowserEnv?{write(e,t,i,r,n,s,o){if("undefined"==typeof document)return;const a=[`${e}=${encodeURIComponent(t)}`];X.isNumber(i)&&a.push(`expires=${new Date(i).toUTCString()}`),X.isString(r)&&a.push(`path=${r}`),X.isString(n)&&a.push(`domain=${n}`),!0===s&&a.push("secure"),X.isString(o)&&a.push(`SameSite=${o}`),document.cookie=a.join("; ")},read(e){if("undefined"==typeof document)return null;const t=document.cookie.split(";");for(let i=0;i<t.length;i++){const r=t[i].replace(/^\s+/,""),n=r.indexOf("=");if(-1!==n&&r.slice(0,n)===e)return decodeURIComponent(r.slice(n+1))}return null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read:()=>null,remove(){}};function We(e,t,i){let r=!("string"==typeof(n=t)&&/^([a-z][a-z\d+\-.]*:)?\/\//i.test(n));var n;return e&&(r||!1===i)?function(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}const je=e=>e instanceof le?{...e}:e;function Ke(e,t){t=t||{};const i=Object.create(null);function r(e,t,i,r){return X.isPlainObject(e)&&X.isPlainObject(t)?X.merge.call({caseless:r},e,t):X.isPlainObject(t)?X.merge({},t):X.isArray(t)?t.slice():t}function n(e,t,i,n){return X.isUndefined(t)?X.isUndefined(e)?void 0:r(void 0,e,0,n):r(e,t,0,n)}function s(e,t){if(!X.isUndefined(t))return r(void 0,t)}function o(e,t){return X.isUndefined(t)?X.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function a(i,n,s){return X.hasOwnProp(t,s)?r(i,n):X.hasOwnProp(e,s)?r(void 0,i):void 0}Object.defineProperty(i,"hasOwnProperty",{__proto__:null,value:Object.prototype.hasOwnProperty,enumerable:!1,writable:!0,configurable:!0});const l={url:s,method:s,data:s,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,allowedSocketPaths:o,responseEncoding:o,validateStatus:a,headers:(e,t,i)=>n(je(e),je(t),0,!0)};return X.forEach(Object.keys({...e,...t}),function(r){if("__proto__"===r||"constructor"===r||"prototype"===r)return;const s=X.hasOwnProp(l,r)?l[r]:n,o=s(X.hasOwnProp(e,r)?e[r]:void 0,X.hasOwnProp(t,r)?t[r]:void 0,r);X.isUndefined(o)&&s!==a||(i[r]=o)}),i}const $e=["content-type","content-length"],qe=e=>{const t=Ke({},e),i=e=>X.hasOwnProp(t,e)?t[e]:void 0,r=i("data");let n=i("withXSRFToken");const s=i("xsrfHeaderName"),o=i("xsrfCookieName");let a=i("headers");const l=i("auth"),c=i("baseURL"),u=i("allowAbsoluteUrls"),h=i("url");var d;if(t.headers=a=le.from(a),t.url=Se(We(c,h,u),e.params,e.paramsSerializer),l&&a.set("Authorization","Basic "+btoa((l.username||"")+":"+(l.password?(d=l.password,encodeURIComponent(d).replace(/%([0-9A-F]{2})/gi,(e,t)=>String.fromCharCode(parseInt(t,16)))):""))),X.isFormData(r)&&(xe.hasStandardBrowserEnv||xe.hasStandardBrowserWebWorkerEnv?a.setContentType(void 0):X.isFunction(r.getHeaders)&&function(e,t,i){"content-only"===i?Object.entries(t).forEach(([t,i])=>{$e.includes(t.toLowerCase())&&e.set(t,i)}):e.set(t)}(a,r.getHeaders(),i("formDataHeaderPolicy"))),xe.hasStandardBrowserEnv&&(X.isFunction(n)&&(n=n(t)),!0===n||null==n&&ze(t.url))){const e=s&&o&&Ue.read(o);e&&a.set(s,e)}return t},Ye="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise(function(t,i){const r=qe(e);let n=r.data;const s=le.from(r.headers).normalize();let o,a,l,c,u,{responseType:h,onUploadProgress:d,onDownloadProgress:p}=r;function g(){c&&c(),u&&u(),r.cancelToken&&r.cancelToken.unsubscribe(o),r.signal&&r.signal.removeEventListener("abort",o)}let f=new XMLHttpRequest;function m(){if(!f)return;const r=le.from("getAllResponseHeaders"in f&&f.getAllResponseHeaders());Ge(function(e){t(e),g()},function(e){i(e),g()},{data:h&&"text"!==h&&"json"!==h?f.response:f.responseText,status:f.status,statusText:f.statusText,headers:r,config:e,request:f}),f=null}f.open(r.method.toUpperCase(),r.url,!0),f.timeout=r.timeout,"onloadend"in f?f.onloadend=m:f.onreadystatechange=function(){f&&4===f.readyState&&(0!==f.status||f.responseURL&&f.responseURL.startsWith("file:"))&&setTimeout(m)},f.onabort=function(){f&&(i(new ue("Request aborted",ue.ECONNABORTED,e,f)),g(),f=null)},f.onerror=function(t){const r=t&&t.message?t.message:"Network Error",n=new ue(r,ue.ERR_NETWORK,e,f);n.event=t||null,i(n),g(),f=null},f.ontimeout=function(){let t=r.timeout?"timeout of "+r.timeout+"ms exceeded":"timeout exceeded";const n=r.transitional||Ee;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),i(new ue(t,n.clarifyTimeoutError?ue.ETIMEDOUT:ue.ECONNABORTED,e,f)),g(),f=null},void 0===n&&s.setContentType(null),"setRequestHeader"in f&&X.forEach(ie(s),function(e,t){f.setRequestHeader(t,e)}),X.isUndefined(r.withCredentials)||(f.withCredentials=!!r.withCredentials),h&&"json"!==h&&(f.responseType=r.responseType),p&&([l,u]=Ve(p,!0),f.addEventListener("progress",l)),d&&f.upload&&([a,c]=Ve(d),f.upload.addEventListener("progress",a),f.upload.addEventListener("loadend",c)),(r.cancelToken||r.signal)&&(o=t=>{f&&(i(!t||t.type?new ke(null,e,f):t),f.abort(),g(),f=null)},r.cancelToken&&r.cancelToken.subscribe(o),r.signal&&(r.signal.aborted?o():r.signal.addEventListener("abort",o)));const v=function(e){const t=/^([-+\w]{1,25}):(?:\/\/)?/.exec(e);return t&&t[1]||""}(r.url);!v||xe.protocols.includes(v)?f.send(n||null):i(new ue("Unsupported protocol "+v+":",ue.ERR_BAD_REQUEST,e))})},Qe=(e,t)=>{if(e=e?e.filter(Boolean):[],!t&&!e.length)return;const i=new AbortController;let r=!1;const n=function(e){if(!r){r=!0,o();const t=e instanceof Error?e:this.reason;i.abort(t instanceof ue?t:new ke(t instanceof Error?t.message:t))}};let s=t&&setTimeout(()=>{s=null,n(new ue(`timeout of ${t}ms exceeded`,ue.ETIMEDOUT))},t);const o=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(n):e.removeEventListener("abort",n)}),e=null)};e.forEach(e=>e.addEventListener("abort",n));const{signal:a}=i;return a.unsubscribe=()=>X.asap(o),a},Xe=function*(e,t){let i=e.byteLength;if(!t||i<t)return void(yield e);let r,n=0;for(;n<i;)r=n+t,yield e.slice(n,r),n=r},Ze=(e,t,i,r)=>{const n=async function*(e,t){for await(const i of async function*(e){if(e[Symbol.asyncIterator])return void(yield*e);const t=e.getReader();try{for(;;){const{done:e,value:i}=await t.read();if(e)break;yield i}}finally{await t.cancel()}}(e))yield*Xe(i,t)}(e,t);let s,o=0,a=e=>{s||(s=!0,r&&r(e))};return new ReadableStream({async pull(e){try{const{done:t,value:r}=await n.next();if(t)return a(),void e.close();let s=r.byteLength;if(i){let e=o+=s;i(e)}e.enqueue(new Uint8Array(r))}catch(e){throw a(e),e}},cancel:e=>(a(e),n.return())},{highWaterMark:2})},Je="1.16.1",{isFunction:et}=X,tt=(e,...t)=>{try{return!!e(...t)}catch(e){return!1}},it=e=>{const t=void 0!==X.global&&null!==X.global?X.global:globalThis,{ReadableStream:i,TextEncoder:r}=t;e=X.merge.call({skipUndefined:!0},{Request:t.Request,Response:t.Response},e);const{fetch:n,Request:s,Response:o}=e,a=n?et(n):"function"==typeof fetch,l=et(s),c=et(o);if(!a)return!1;const u=a&&et(i),h=a&&("function"==typeof r?(d=new r,e=>d.encode(e)):async e=>new Uint8Array(await new s(e).arrayBuffer()));var d;const p=l&&u&&tt(()=>{let e=!1;const t=new s(xe.origin,{body:new i,method:"POST",get duplex(){return e=!0,"half"}}),r=t.headers.has("Content-Type");return null!=t.body&&t.body.cancel(),e&&!r}),g=c&&u&&tt(()=>X.isReadableStream(new o("").body)),f={stream:g&&(e=>e.body)};a&&["text","arrayBuffer","blob","formData","stream"].forEach(e=>{!f[e]&&(f[e]=(t,i)=>{let r=t&&t[e];if(r)return r.call(t);throw new ue(`Response type '${e}' is not supported`,ue.ERR_NOT_SUPPORT,i)})});const m=async(e,t)=>{const i=X.toFiniteNumber(e.getContentLength());return null==i?(async e=>{if(null==e)return 0;if(X.isBlob(e))return e.size;if(X.isSpecCompliantForm(e)){const t=new s(xe.origin,{method:"POST",body:e});return(await t.arrayBuffer()).byteLength}return X.isArrayBufferView(e)||X.isArrayBuffer(e)?e.byteLength:(X.isURLSearchParams(e)&&(e+=""),X.isString(e)?(await h(e)).byteLength:void 0)})(t):i};return async e=>{let{url:t,method:i,data:a,signal:c,cancelToken:u,timeout:h,onDownloadProgress:d,onUploadProgress:v,responseType:C,headers:y,withCredentials:w="same-origin",fetchOptions:S,maxContentLength:b,maxBodyLength:E}=qe(e);const A=X.isNumber(b)&&b>-1,T=X.isNumber(E)&&E>-1;let M=n||fetch;C=C?(C+"").toLowerCase():"text";let R=Qe([c,u&&u.toAbortSignal()],h),_=null;const P=R&&R.unsubscribe&&(()=>{R.unsubscribe()});let x;try{if(A&&"string"==typeof t&&t.startsWith("data:")){const i=function(e){if(!e||"string"!=typeof e)return 0;if(!e.startsWith("data:"))return 0;const t=e.indexOf(",");if(t<0)return 0;const i=e.slice(5,t),r=e.slice(t+1);if(/;base64/i.test(i)){let e=r.length;const t=r.length;for(let i=0;i<t;i++)if(37===r.charCodeAt(i)&&i+2<t){const t=r.charCodeAt(i+1),n=r.charCodeAt(i+2);(t>=48&&t<=57||t>=65&&t<=70||t>=97&&t<=102)&&(n>=48&&n<=57||n>=65&&n<=70||n>=97&&n<=102)&&(e-=2,i+=2)}let i=0,n=t-1;const s=e=>e>=2&&37===r.charCodeAt(e-2)&&51===r.charCodeAt(e-1)&&(68===r.charCodeAt(e)||100===r.charCodeAt(e));n>=0&&(61===r.charCodeAt(n)?(i++,n--):s(n)&&(i++,n-=3)),1===i&&n>=0&&(61===r.charCodeAt(n)||s(n))&&i++;const o=3*Math.floor(e/4)-(i||0);return o>0?o:0}if("undefined"!=typeof Buffer&&"function"==typeof Buffer.byteLength)return Buffer.byteLength(r,"utf8");let n=0;for(let e=0,t=r.length;e<t;e++){const i=r.charCodeAt(e);if(i<128)n+=1;else if(i<2048)n+=2;else if(i>=55296&&i<=56319&&e+1<t){const t=r.charCodeAt(e+1);t>=56320&&t<=57343?(n+=4,e++):n+=3}else n+=3}return n}(t);if(i>b)throw new ue("maxContentLength size of "+b+" exceeded",ue.ERR_BAD_RESPONSE,e,_)}if(T&&"get"!==i&&"head"!==i){const t=await m(y,a);if("number"==typeof t&&isFinite(t)&&t>E)throw new ue("Request body larger than maxBodyLength limit",ue.ERR_BAD_REQUEST,e,_)}if(v&&p&&"get"!==i&&"head"!==i&&0!==(x=await m(y,a))){let e,i=new s(t,{method:"POST",body:a,duplex:"half"});if(X.isFormData(a)&&(e=i.headers.get("content-type"))&&y.setContentType(e),i.body){const[e,t]=He(x,Ve(Be(v)));a=Ze(i.body,65536,e,t)}}X.isString(w)||(w=w?"include":"omit");const n=l&&"credentials"in s.prototype;if(X.isFormData(a)){const e=y.getContentType();e&&/^multipart\/form-data/i.test(e)&&!/boundary=/i.test(e)&&y.delete("content-type")}y.set("User-Agent","axios/"+Je,!1);const c={...S,signal:R,method:i.toUpperCase(),headers:ie(y.normalize()),body:a,duplex:"half",credentials:n?w:void 0};_=l&&new s(t,c);let u=await(l?M(_,S):M(t,c));if(A){const t=X.toFiniteNumber(u.headers.get("content-length"));if(null!=t&&t>b)throw new ue("maxContentLength size of "+b+" exceeded",ue.ERR_BAD_RESPONSE,e,_)}const h=g&&("stream"===C||"response"===C);if(g&&u.body&&(d||A||h&&P)){const t={};["status","statusText","headers"].forEach(e=>{t[e]=u[e]});const i=X.toFiniteNumber(u.headers.get("content-length")),[r,n]=d&&He(i,Ve(Be(d),!0))||[];let s=0;const a=t=>{if(A&&(s=t,s>b))throw new ue("maxContentLength size of "+b+" exceeded",ue.ERR_BAD_RESPONSE,e,_);r&&r(t)};u=new o(Ze(u.body,65536,a,()=>{n&&n(),P&&P()}),t)}C=C||"text";let D=await f[X.findKey(f,C)||"text"](u,e);if(A&&!g&&!h){let t;if(null!=D&&("number"==typeof D.byteLength?t=D.byteLength:"number"==typeof D.size?t=D.size:"string"==typeof D&&(t="function"==typeof r?(new r).encode(D).byteLength:D.length)),"number"==typeof t&&t>b)throw new ue("maxContentLength size of "+b+" exceeded",ue.ERR_BAD_RESPONSE,e,_)}return!h&&P&&P(),await new Promise((t,i)=>{Ge(t,i,{data:D,headers:le.from(u.headers),status:u.status,statusText:u.statusText,config:e,request:_})})}catch(t){if(P&&P(),R&&R.aborted&&R.reason instanceof ue){const i=R.reason;throw i.config=e,_&&(i.request=_),t!==i&&(i.cause=t),i}if(t&&"TypeError"===t.name&&/Load failed|fetch/i.test(t.message))throw Object.assign(new ue("Network Error",ue.ERR_NETWORK,e,_,t&&t.response),{cause:t.cause||t});throw ue.from(t,t&&t.code,e,_,t&&t.response)}}},rt=new Map,nt=e=>{let t=e&&e.env||{};const{fetch:i,Request:r,Response:n}=t,s=[r,n,i];let o,a,l=s.length,c=rt;for(;l--;)o=s[l],a=c.get(o),void 0===a&&c.set(o,a=l?new Map:it(t)),c=a;return a},st=(nt(),{http:null,xhr:Ye,fetch:{get:nt}});X.forEach(st,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{__proto__:null,value:t})}catch(e){}Object.defineProperty(e,"adapterName",{__proto__:null,value:t})}});const ot=e=>`- ${e}`,at=e=>X.isFunction(e)||null===e||!1===e,lt=function(e,t){e=X.isArray(e)?e:[e];const{length:i}=e;let r,n;const s={};for(let o=0;o<i;o++){let i;if(r=e[o],n=r,!at(r)&&(n=st[(i=String(r)).toLowerCase()],void 0===n))throw new ue(`Unknown adapter '${i}'`);if(n&&(X.isFunction(n)||(n=n.get(t))))break;s[i||"#"+o]=n}if(!n){const e=Object.entries(s).map(([e,t])=>`adapter ${e} `+(!1===t?"is not supported by the environment":"is not available in the build"));let t=i?e.length>1?"since :\n"+e.map(ot).join("\n"):" "+ot(e[0]):"as no adapter specified";throw new ue("There is no suitable adapter to dispatch the request "+t,"ERR_NOT_SUPPORT")}return n};function ct(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new ke(null,e)}function ut(e){return ct(e),e.headers=le.from(e.headers),e.data=Oe.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),lt(e.adapter||Ne.adapter,e)(e).then(function(t){ct(e),e.response=t;try{t.data=Oe.call(e,e.transformResponse,t)}finally{delete e.response}return t.headers=le.from(t.headers),t},function(t){if(!Fe(t)&&(ct(e),t&&t.response)){e.response=t.response;try{t.response.data=Oe.call(e,e.transformResponse,t.response)}finally{delete e.response}t.response.headers=le.from(t.response.headers)}return Promise.reject(t)})}const ht={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{ht[e]=function(i){return typeof i===e||"a"+(t<1?"n ":" ")+e}});const dt={};ht.transitional=function(e,t,i){function r(e,t){return"[Axios v"+Je+"] Transitional option '"+e+"'"+t+(i?". "+i:"")}return(i,n,s)=>{if(!1===e)throw new ue(r(n," has been removed"+(t?" in "+t:"")),ue.ERR_DEPRECATED);return t&&!dt[n]&&(dt[n]=!0,console.warn(r(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(i,n,s)}},ht.spelling=function(e){return(t,i)=>(console.warn(`${i} is likely a misspelling of ${e}`),!0)};const pt={assertOptions:function(e,t,i){if("object"!=typeof e)throw new ue("options must be an object",ue.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let n=r.length;for(;n-- >0;){const s=r[n],o=Object.prototype.hasOwnProperty.call(t,s)?t[s]:void 0;if(o){const t=e[s],i=void 0===t||o(t,s,e);if(!0!==i)throw new ue("option "+s+" must be "+i,ue.ERR_BAD_OPTION_VALUE);continue}if(!0!==i)throw new ue("Unknown option "+s,ue.ERR_BAD_OPTION)}},validators:ht},gt=pt.validators;class ft{constructor(e){this.defaults=e||{},this.interceptors={request:new be,response:new be}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=new Error;const i=(()=>{if(!t.stack)return"";const e=t.stack.indexOf("\n");return-1===e?"":t.stack.slice(e+1)})();try{if(e.stack){if(i){const t=i.indexOf("\n"),r=-1===t?-1:i.indexOf("\n",t+1),n=-1===r?"":i.slice(r+1);String(e.stack).endsWith(n)||(e.stack+="\n"+i)}}else e.stack=i}catch(e){}}throw e}}_request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Ke(this.defaults,t);const{transitional:i,paramsSerializer:r,headers:n}=t;void 0!==i&&pt.assertOptions(i,{silentJSONParsing:gt.transitional(gt.boolean),forcedJSONParsing:gt.transitional(gt.boolean),clarifyTimeoutError:gt.transitional(gt.boolean),legacyInterceptorReqResOrdering:gt.transitional(gt.boolean)},!1),null!=r&&(X.isFunction(r)?t.paramsSerializer={serialize:r}:pt.assertOptions(r,{encode:gt.function,serialize:gt.function},!0)),void 0!==t.allowAbsoluteUrls||(void 0!==this.defaults.allowAbsoluteUrls?t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:t.allowAbsoluteUrls=!0),pt.assertOptions(t,{baseUrl:gt.spelling("baseURL"),withXsrfToken:gt.spelling("withXSRFToken")},!0),t.method=(t.method||this.defaults.method||"get").toLowerCase();let s=n&&X.merge(n.common,n[t.method]);n&&X.forEach(["delete","get","head","post","put","patch","query","common"],e=>{delete n[e]}),t.headers=le.concat(s,n);const o=[];let a=!0;this.interceptors.request.forEach(function(e){if("function"==typeof e.runWhen&&!1===e.runWhen(t))return;a=a&&e.synchronous;const i=t.transitional||Ee;i&&i.legacyInterceptorReqResOrdering?o.unshift(e.fulfilled,e.rejected):o.push(e.fulfilled,e.rejected)});const l=[];let c;this.interceptors.response.forEach(function(e){l.push(e.fulfilled,e.rejected)});let u,h=0;if(!a){const e=[ut.bind(this),void 0];for(e.unshift(...o),e.push(...l),u=e.length,c=Promise.resolve(t);h<u;)c=c.then(e[h++],e[h++]);return c}u=o.length;let d=t;for(;h<u;){const e=o[h++],t=o[h++];try{d=e(d)}catch(e){t.call(this,e);break}}try{c=ut.call(this,d)}catch(e){return Promise.reject(e)}for(h=0,u=l.length;h<u;)c=c.then(l[h++],l[h++]);return c}getUri(e){return Se(We((e=Ke(this.defaults,e)).baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}}X.forEach(["delete","get","head","options"],function(e){ft.prototype[e]=function(t,i){return this.request(Ke(i||{},{method:e,url:t,data:(i||{}).data}))}}),X.forEach(["post","put","patch","query"],function(e){function t(t){return function(i,r,n){return this.request(Ke(n||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:i,data:r}))}}ft.prototype[e]=t(),"query"!==e&&(ft.prototype[e+"Form"]=t(!0))});const mt=ft;class vt{constructor(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");let t;this.promise=new Promise(function(e){t=e});const i=this;this.promise.then(e=>{if(!i._listeners)return;let t=i._listeners.length;for(;t-- >0;)i._listeners[t](e);i._listeners=null}),this.promise.then=e=>{let t;const r=new Promise(e=>{i.subscribe(e),t=e}).then(e);return r.cancel=function(){i.unsubscribe(t)},r},e(function(e,r,n){i.reason||(i.reason=new ke(e,r,n),t(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}toAbortSignal(){const e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let e;return{token:new vt(function(t){e=t}),cancel:e}}}const Ct=vt,yt={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(yt).forEach(([e,t])=>{yt[t]=e});const wt=yt,St=function e(t){const i=new mt(t),r=n(mt.prototype.request,i);return X.extend(r,mt.prototype,i,{allOwnKeys:!0}),X.extend(r,i,null,{allOwnKeys:!0}),r.create=function(i){return e(Ke(t,i))},r}(Ne);St.Axios=mt,St.CanceledError=ke,St.CancelToken=Ct,St.isCancel=Fe,St.VERSION=Je,St.toFormData=fe,St.AxiosError=ue,St.Cancel=St.CanceledError,St.all=function(e){return Promise.all(e)},St.spread=function(e){return function(t){return e.apply(null,t)}},St.isAxiosError=function(e){return X.isObject(e)&&!0===e.isAxiosError},St.mergeConfig=Ke,St.AxiosHeaders=le,St.formToJSON=e=>De(X.isHTMLForm(e)?new FormData(e):e),St.getAdapter=lt,St.HttpStatusCode=wt,St.default=St;const bt=St},67723(e,t,i){"use strict";function r(e){if(e)throw e}i.d(t,{V:()=>r})},29942(e,t,i){"use strict";function r(e,t){const i=String(e);if("string"!=typeof t)throw new TypeError("Expected character");let r=0,n=i.indexOf(t);for(;-1!==n;)r++,n=i.indexOf(t,n+t.length);return r}i.d(t,{D:()=>r})},5779(e,t,i){"use strict";function r(e){if("string"==typeof e||"number"==typeof e)return""+e;let t="";if(Array.isArray(e))for(let i,n=0;n<e.length;n++)""!==(i=r(e[n]))&&(t+=(t&&" ")+i);else for(let i in e)e[i]&&(t+=(t&&" ")+i);return t}i.d(t,{A:()=>r})},70851(e,t,i){"use strict";function r(e){var t,i,n="";if("string"==typeof e||"number"==typeof e)n+=e;else if("object"==typeof e)if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(i=r(e[t]))&&(n&&(n+=" "),n+=i)}else for(i in e)e[i]&&(n&&(n+=" "),n+=i);return n}i.d(t,{A:()=>n});const n=function(){for(var e,t,i=0,n="",s=arguments.length;i<s;i++)(e=arguments[i])&&(t=r(e))&&(n&&(n+=" "),n+=t);return n}},12172(e,t,i){"use strict";function r(e,t){const i=t||{};return(""===e[e.length-1]?[...e,""]:e).join((i.padRight?" ":"")+","+(!1===i.padLeft?"":" ")).trim()}i.d(t,{A:()=>r})},18600(e,t,i){"use strict";var r;function n(){}function s(){s.init.call(this)}function o(e){return void 0===e._maxListeners?s.defaultMaxListeners:e._maxListeners}function a(e,t,i,r){var s,a,l,c;if("function"!=typeof i)throw new TypeError('"listener" argument must be a function');if((a=e._events)?(a.newListener&&(e.emit("newListener",t,i.listener?i.listener:i),a=e._events),l=a[t]):(a=e._events=new n,e._eventsCount=0),l){if("function"==typeof l?l=a[t]=r?[i,l]:[l,i]:r?l.unshift(i):l.push(i),!l.warned&&(s=o(e))&&s>0&&l.length>s){l.warned=!0;var u=new Error("Possible EventEmitter memory leak detected. "+l.length+" "+t+" listeners added. Use emitter.setMaxListeners() to increase limit");u.name="MaxListenersExceededWarning",u.emitter=e,u.type=t,u.count=l.length,c=u,"function"==typeof console.warn?console.warn(c):console.log(c)}}else l=a[t]=i,++e._eventsCount;return e}function l(e,t,i){var r=!1;function n(){e.removeListener(t,n),r||(r=!0,i.apply(e,arguments))}return n.listener=i,n}function c(e){var t=this._events;if(t){var i=t[e];if("function"==typeof i)return 1;if(i)return i.length}return 0}function u(e,t){for(var i=new Array(t);t--;)i[t]=e[t];return i}i.d(t,{As:()=>ti}),n.prototype=Object.create(null),s.EventEmitter=s,s.usingDomains=!1,s.prototype.domain=void 0,s.prototype._events=void 0,s.prototype._maxListeners=void 0,s.defaultMaxListeners=10,s.init=function(){this.domain=null,s.usingDomains&&(!r.active||this instanceof r.Domain||(this.domain=r.active)),this._events&&this._events!==Object.getPrototypeOf(this)._events||(this._events=new n,this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},s.prototype.setMaxListeners=function(e){if("number"!=typeof e||e<0||isNaN(e))throw new TypeError('"n" argument must be a positive number');return this._maxListeners=e,this},s.prototype.getMaxListeners=function(){return o(this)},s.prototype.emit=function(e){var t,i,r,n,s,o,a,l="error"===e;if(o=this._events)l=l&&null==o.error;else if(!l)return!1;if(a=this.domain,l){if(t=arguments[1],!a){if(t instanceof Error)throw t;var c=new Error('Uncaught, unspecified "error" event. ('+t+")");throw c.context=t,c}return t||(t=new Error('Uncaught, unspecified "error" event')),t.domainEmitter=this,t.domain=a,t.domainThrown=!1,a.emit("error",t),!1}if(!(i=o[e]))return!1;var h="function"==typeof i;switch(r=arguments.length){case 1:!function(e,t,i){if(t)e.call(i);else for(var r=e.length,n=u(e,r),s=0;s<r;++s)n[s].call(i)}(i,h,this);break;case 2:!function(e,t,i,r){if(t)e.call(i,r);else for(var n=e.length,s=u(e,n),o=0;o<n;++o)s[o].call(i,r)}(i,h,this,arguments[1]);break;case 3:!function(e,t,i,r,n){if(t)e.call(i,r,n);else for(var s=e.length,o=u(e,s),a=0;a<s;++a)o[a].call(i,r,n)}(i,h,this,arguments[1],arguments[2]);break;case 4:!function(e,t,i,r,n,s){if(t)e.call(i,r,n,s);else for(var o=e.length,a=u(e,o),l=0;l<o;++l)a[l].call(i,r,n,s)}(i,h,this,arguments[1],arguments[2],arguments[3]);break;default:for(n=new Array(r-1),s=1;s<r;s++)n[s-1]=arguments[s];!function(e,t,i,r){if(t)e.apply(i,r);else for(var n=e.length,s=u(e,n),o=0;o<n;++o)s[o].apply(i,r)}(i,h,this,n)}return!0},s.prototype.addListener=function(e,t){return a(this,e,t,!1)},s.prototype.on=s.prototype.addListener,s.prototype.prependListener=function(e,t){return a(this,e,t,!0)},s.prototype.once=function(e,t){if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');return this.on(e,l(this,e,t)),this},s.prototype.prependOnceListener=function(e,t){if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');return this.prependListener(e,l(this,e,t)),this},s.prototype.removeListener=function(e,t){var i,r,s,o,a;if("function"!=typeof t)throw new TypeError('"listener" argument must be a function');if(!(r=this._events))return this;if(!(i=r[e]))return this;if(i===t||i.listener&&i.listener===t)0===--this._eventsCount?this._events=new n:(delete r[e],r.removeListener&&this.emit("removeListener",e,i.listener||t));else if("function"!=typeof i){for(s=-1,o=i.length;o-- >0;)if(i[o]===t||i[o].listener&&i[o].listener===t){a=i[o].listener,s=o;break}if(s<0)return this;if(1===i.length){if(i[0]=void 0,0===--this._eventsCount)return this._events=new n,this;delete r[e]}else!function(e,t){for(var i=t,r=i+1,n=e.length;r<n;i+=1,r+=1)e[i]=e[r];e.pop()}(i,s);r.removeListener&&this.emit("removeListener",e,a||t)}return this},s.prototype.removeAllListeners=function(e){var t,i;if(!(i=this._events))return this;if(!i.removeListener)return 0===arguments.length?(this._events=new n,this._eventsCount=0):i[e]&&(0===--this._eventsCount?this._events=new n:delete i[e]),this;if(0===arguments.length){for(var r,s=Object.keys(i),o=0;o<s.length;++o)"removeListener"!==(r=s[o])&&this.removeAllListeners(r);return this.removeAllListeners("removeListener"),this._events=new n,this._eventsCount=0,this}if("function"==typeof(t=i[e]))this.removeListener(e,t);else if(t)do{this.removeListener(e,t[t.length-1])}while(t[0]);return this},s.prototype.listeners=function(e){var t,i=this._events;return i&&(t=i[e])?"function"==typeof t?[t.listener||t]:function(e){for(var t=new Array(e.length),i=0;i<t.length;++i)t[i]=e[i].listener||e[i];return t}(t):[]},s.listenerCount=function(e,t){return"function"==typeof e.listenerCount?e.listenerCount(t):c.call(e,t)},s.prototype.listenerCount=c,s.prototype.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};var h="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},d=[],p=[],g="undefined"!=typeof Uint8Array?Uint8Array:Array,f=!1;function m(){f=!0;for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0;t<64;++t)d[t]=e[t],p[e.charCodeAt(t)]=t;p["-".charCodeAt(0)]=62,p["_".charCodeAt(0)]=63}function v(e){return d[e>>18&63]+d[e>>12&63]+d[e>>6&63]+d[63&e]}function C(e,t,i){for(var r,n=[],s=t;s<i;s+=3)r=(e[s]<<16)+(e[s+1]<<8)+e[s+2],n.push(v(r));return n.join("")}function y(e){var t;f||m();for(var i=e.length,r=i%3,n="",s=[],o=16383,a=0,l=i-r;a<l;a+=o)s.push(C(e,a,a+o>l?l:a+o));return 1===r?(t=e[i-1],n+=d[t>>2],n+=d[t<<4&63],n+="=="):2===r&&(t=(e[i-2]<<8)+e[i-1],n+=d[t>>10],n+=d[t>>4&63],n+=d[t<<2&63],n+="="),s.push(n),s.join("")}function w(e,t,i,r,n){var s,o,a=8*n-r-1,l=(1<<a)-1,c=l>>1,u=-7,h=i?n-1:0,d=i?-1:1,p=e[t+h];for(h+=d,s=p&(1<<-u)-1,p>>=-u,u+=a;u>0;s=256*s+e[t+h],h+=d,u-=8);for(o=s&(1<<-u)-1,s>>=-u,u+=r;u>0;o=256*o+e[t+h],h+=d,u-=8);if(0===s)s=1-c;else{if(s===l)return o?NaN:1/0*(p?-1:1);o+=Math.pow(2,r),s-=c}return(p?-1:1)*o*Math.pow(2,s-r)}function S(e,t,i,r,n,s){var o,a,l,c=8*s-n-1,u=(1<<c)-1,h=u>>1,d=23===n?Math.pow(2,-24)-Math.pow(2,-77):0,p=r?0:s-1,g=r?1:-1,f=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,o=u):(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1&&(o--,l*=2),(t+=o+h>=1?d/l:d*Math.pow(2,1-h))*l>=2&&(o++,l/=2),o+h>=u?(a=0,o=u):o+h>=1?(a=(t*l-1)*Math.pow(2,n),o+=h):(a=t*Math.pow(2,h-1)*Math.pow(2,n),o=0));n>=8;e[i+p]=255&a,p+=g,a/=256,n-=8);for(o=o<<n|a,c+=n;c>0;e[i+p]=255&o,p+=g,o/=256,c-=8);e[i+p-g]|=128*f}var b={}.toString,E=Array.isArray||function(e){return"[object Array]"==b.call(e)};function A(){return M.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function T(e,t){if(A()<t)throw new RangeError("Invalid typed array length");return M.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=M.prototype:(null===e&&(e=new M(t)),e.length=t),e}function M(e,t,i){if(!(M.TYPED_ARRAY_SUPPORT||this instanceof M))return new M(e,t,i);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return P(this,e)}return R(this,e,t,i)}function R(e,t,i,r){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,i,r){if(t.byteLength,i<0||t.byteLength<i)throw new RangeError("'offset' is out of bounds");if(t.byteLength<i+(r||0))throw new RangeError("'length' is out of bounds");return t=void 0===i&&void 0===r?new Uint8Array(t):void 0===r?new Uint8Array(t,i):new Uint8Array(t,i,r),M.TYPED_ARRAY_SUPPORT?(e=t).__proto__=M.prototype:e=x(e,t),e}(e,t,i,r):"string"==typeof t?function(e,t,i){if("string"==typeof i&&""!==i||(i="utf8"),!M.isEncoding(i))throw new TypeError('"encoding" must be a valid string encoding');var r=0|L(t,i),n=(e=T(e,r)).write(t,i);return n!==r&&(e=e.slice(0,n)),e}(e,t,i):function(e,t){if(I(t)){var i=0|D(t.length);return 0===(e=T(e,i)).length||t.copy(e,0,0,i),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(r=t.length)!=r?T(e,0):x(e,t);if("Buffer"===t.type&&E(t.data))return x(e,t.data)}var r;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function _(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function P(e,t){if(_(t),e=T(e,t<0?0:0|D(t)),!M.TYPED_ARRAY_SUPPORT)for(var i=0;i<t;++i)e[i]=0;return e}function x(e,t){var i=t.length<0?0:0|D(t.length);e=T(e,i);for(var r=0;r<i;r+=1)e[r]=255&t[r];return e}function D(e){if(e>=A())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+A().toString(16)+" bytes");return 0|e}function I(e){return!(null==e||!e._isBuffer)}function L(e,t){if(I(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var i=e.length;if(0===i)return 0;for(var r=!1;;)switch(t){case"ascii":case"latin1":case"binary":return i;case"utf8":case"utf-8":case void 0:return oe(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*i;case"hex":return i>>>1;case"base64":return ae(e).length;default:if(r)return oe(e).length;t=(""+t).toLowerCase(),r=!0}}function N(e,t,i){var r=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===i||i>this.length)&&(i=this.length),i<=0)return"";if((i>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return Y(this,t,i);case"utf8":case"utf-8":return j(this,t,i);case"ascii":return $(this,t,i);case"latin1":case"binary":return q(this,t,i);case"base64":return W(this,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Q(this,t,i);default:if(r)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),r=!0}}function O(e,t,i){var r=e[t];e[t]=e[i],e[i]=r}function F(e,t,i,r,n){if(0===e.length)return-1;if("string"==typeof i?(r=i,i=0):i>2147483647?i=2147483647:i<-2147483648&&(i=-2147483648),i=+i,isNaN(i)&&(i=n?0:e.length-1),i<0&&(i=e.length+i),i>=e.length){if(n)return-1;i=e.length-1}else if(i<0){if(!n)return-1;i=0}if("string"==typeof t&&(t=M.from(t,r)),I(t))return 0===t.length?-1:k(e,t,i,r,n);if("number"==typeof t)return t&=255,M.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,i):Uint8Array.prototype.lastIndexOf.call(e,t,i):k(e,[t],i,r,n);throw new TypeError("val must be string, number or Buffer")}function k(e,t,i,r,n){var s,o=1,a=e.length,l=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return-1;o=2,a/=2,l/=2,i/=2}function c(e,t){return 1===o?e[t]:e.readUInt16BE(t*o)}if(n){var u=-1;for(s=i;s<a;s++)if(c(e,s)===c(t,-1===u?0:s-u)){if(-1===u&&(u=s),s-u+1===l)return u*o}else-1!==u&&(s-=s-u),u=-1}else for(i+l>a&&(i=a-l),s=i;s>=0;s--){for(var h=!0,d=0;d<l;d++)if(c(e,s+d)!==c(t,d)){h=!1;break}if(h)return s}return-1}function G(e,t,i,r){i=Number(i)||0;var n=e.length-i;r?(r=Number(r))>n&&(r=n):r=n;var s=t.length;if(s%2!=0)throw new TypeError("Invalid hex string");r>s/2&&(r=s/2);for(var o=0;o<r;++o){var a=parseInt(t.substr(2*o,2),16);if(isNaN(a))return o;e[i+o]=a}return o}function V(e,t,i,r){return le(oe(t,e.length-i),e,i,r)}function H(e,t,i,r){return le(function(e){for(var t=[],i=0;i<e.length;++i)t.push(255&e.charCodeAt(i));return t}(t),e,i,r)}function B(e,t,i,r){return H(e,t,i,r)}function z(e,t,i,r){return le(ae(t),e,i,r)}function U(e,t,i,r){return le(function(e,t){for(var i,r,n,s=[],o=0;o<e.length&&!((t-=2)<0);++o)r=(i=e.charCodeAt(o))>>8,n=i%256,s.push(n),s.push(r);return s}(t,e.length-i),e,i,r)}function W(e,t,i){return 0===t&&i===e.length?y(e):y(e.slice(t,i))}function j(e,t,i){i=Math.min(e.length,i);for(var r=[],n=t;n<i;){var s,o,a,l,c=e[n],u=null,h=c>239?4:c>223?3:c>191?2:1;if(n+h<=i)switch(h){case 1:c<128&&(u=c);break;case 2:128==(192&(s=e[n+1]))&&(l=(31&c)<<6|63&s)>127&&(u=l);break;case 3:s=e[n+1],o=e[n+2],128==(192&s)&&128==(192&o)&&(l=(15&c)<<12|(63&s)<<6|63&o)>2047&&(l<55296||l>57343)&&(u=l);break;case 4:s=e[n+1],o=e[n+2],a=e[n+3],128==(192&s)&&128==(192&o)&&128==(192&a)&&(l=(15&c)<<18|(63&s)<<12|(63&o)<<6|63&a)>65535&&l<1114112&&(u=l)}null===u?(u=65533,h=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),n+=h}return function(e){var t=e.length;if(t<=K)return String.fromCharCode.apply(String,e);for(var i="",r=0;r<t;)i+=String.fromCharCode.apply(String,e.slice(r,r+=K));return i}(r)}M.TYPED_ARRAY_SUPPORT=void 0===h.TYPED_ARRAY_SUPPORT||h.TYPED_ARRAY_SUPPORT,A(),M.poolSize=8192,M._augment=function(e){return e.__proto__=M.prototype,e},M.from=function(e,t,i){return R(null,e,t,i)},M.TYPED_ARRAY_SUPPORT&&(M.prototype.__proto__=Uint8Array.prototype,M.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&M[Symbol.species]),M.alloc=function(e,t,i){return function(e,t,i,r){return _(t),t<=0?T(e,t):void 0!==i?"string"==typeof r?T(e,t).fill(i,r):T(e,t).fill(i):T(e,t)}(null,e,t,i)},M.allocUnsafe=function(e){return P(null,e)},M.allocUnsafeSlow=function(e){return P(null,e)},M.isBuffer=ce,M.compare=function(e,t){if(!I(e)||!I(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var i=e.length,r=t.length,n=0,s=Math.min(i,r);n<s;++n)if(e[n]!==t[n]){i=e[n],r=t[n];break}return i<r?-1:r<i?1:0},M.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},M.concat=function(e,t){if(!E(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return M.alloc(0);var i;if(void 0===t)for(t=0,i=0;i<e.length;++i)t+=e[i].length;var r=M.allocUnsafe(t),n=0;for(i=0;i<e.length;++i){var s=e[i];if(!I(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(r,n),n+=s.length}return r},M.byteLength=L,M.prototype._isBuffer=!0,M.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)O(this,t,t+1);return this},M.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)O(this,t,t+3),O(this,t+1,t+2);return this},M.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)O(this,t,t+7),O(this,t+1,t+6),O(this,t+2,t+5),O(this,t+3,t+4);return this},M.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?j(this,0,e):N.apply(this,arguments)},M.prototype.equals=function(e){if(!I(e))throw new TypeError("Argument must be a Buffer");return this===e||0===M.compare(this,e)},M.prototype.inspect=function(){var e="";return this.length>0&&(e=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(e+=" ... ")),"<Buffer "+e+">"},M.prototype.compare=function(e,t,i,r,n){if(!I(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===i&&(i=e?e.length:0),void 0===r&&(r=0),void 0===n&&(n=this.length),t<0||i>e.length||r<0||n>this.length)throw new RangeError("out of range index");if(r>=n&&t>=i)return 0;if(r>=n)return-1;if(t>=i)return 1;if(this===e)return 0;for(var s=(n>>>=0)-(r>>>=0),o=(i>>>=0)-(t>>>=0),a=Math.min(s,o),l=this.slice(r,n),c=e.slice(t,i),u=0;u<a;++u)if(l[u]!==c[u]){s=l[u],o=c[u];break}return s<o?-1:o<s?1:0},M.prototype.includes=function(e,t,i){return-1!==this.indexOf(e,t,i)},M.prototype.indexOf=function(e,t,i){return F(this,e,t,i,!0)},M.prototype.lastIndexOf=function(e,t,i){return F(this,e,t,i,!1)},M.prototype.write=function(e,t,i,r){if(void 0===t)r="utf8",i=this.length,t=0;else if(void 0===i&&"string"==typeof t)r=t,i=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(i)?(i|=0,void 0===r&&(r="utf8")):(r=i,i=void 0)}var n=this.length-t;if((void 0===i||i>n)&&(i=n),e.length>0&&(i<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var s=!1;;)switch(r){case"hex":return G(this,e,t,i);case"utf8":case"utf-8":return V(this,e,t,i);case"ascii":return H(this,e,t,i);case"latin1":case"binary":return B(this,e,t,i);case"base64":return z(this,e,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return U(this,e,t,i);default:if(s)throw new TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),s=!0}},M.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var K=4096;function $(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(127&e[n]);return r}function q(e,t,i){var r="";i=Math.min(e.length,i);for(var n=t;n<i;++n)r+=String.fromCharCode(e[n]);return r}function Y(e,t,i){var r=e.length;(!t||t<0)&&(t=0),(!i||i<0||i>r)&&(i=r);for(var n="",s=t;s<i;++s)n+=se(e[s]);return n}function Q(e,t,i){for(var r=e.slice(t,i),n="",s=0;s<r.length;s+=2)n+=String.fromCharCode(r[s]+256*r[s+1]);return n}function X(e,t,i){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>i)throw new RangeError("Trying to access beyond buffer length")}function Z(e,t,i,r,n,s){if(!I(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<s)throw new RangeError('"value" argument is out of bounds');if(i+r>e.length)throw new RangeError("Index out of range")}function J(e,t,i,r){t<0&&(t=65535+t+1);for(var n=0,s=Math.min(e.length-i,2);n<s;++n)e[i+n]=(t&255<<8*(r?n:1-n))>>>8*(r?n:1-n)}function ee(e,t,i,r){t<0&&(t=4294967295+t+1);for(var n=0,s=Math.min(e.length-i,4);n<s;++n)e[i+n]=t>>>8*(r?n:3-n)&255}function te(e,t,i,r,n,s){if(i+r>e.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("Index out of range")}function ie(e,t,i,r,n){return n||te(e,0,i,4),S(e,t,i,r,23,4),i+4}function re(e,t,i,r,n){return n||te(e,0,i,8),S(e,t,i,r,52,8),i+8}M.prototype.slice=function(e,t){var i,r=this.length;if((e=~~e)<0?(e+=r)<0&&(e=0):e>r&&(e=r),(t=void 0===t?r:~~t)<0?(t+=r)<0&&(t=0):t>r&&(t=r),t<e&&(t=e),M.TYPED_ARRAY_SUPPORT)(i=this.subarray(e,t)).__proto__=M.prototype;else{var n=t-e;i=new M(n,void 0);for(var s=0;s<n;++s)i[s]=this[s+e]}return i},M.prototype.readUIntLE=function(e,t,i){e|=0,t|=0,i||X(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r},M.prototype.readUIntBE=function(e,t,i){e|=0,t|=0,i||X(e,t,this.length);for(var r=this[e+--t],n=1;t>0&&(n*=256);)r+=this[e+--t]*n;return r},M.prototype.readUInt8=function(e,t){return t||X(e,1,this.length),this[e]},M.prototype.readUInt16LE=function(e,t){return t||X(e,2,this.length),this[e]|this[e+1]<<8},M.prototype.readUInt16BE=function(e,t){return t||X(e,2,this.length),this[e]<<8|this[e+1]},M.prototype.readUInt32LE=function(e,t){return t||X(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},M.prototype.readUInt32BE=function(e,t){return t||X(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},M.prototype.readIntLE=function(e,t,i){e|=0,t|=0,i||X(e,t,this.length);for(var r=this[e],n=1,s=0;++s<t&&(n*=256);)r+=this[e+s]*n;return r>=(n*=128)&&(r-=Math.pow(2,8*t)),r},M.prototype.readIntBE=function(e,t,i){e|=0,t|=0,i||X(e,t,this.length);for(var r=t,n=1,s=this[e+--r];r>0&&(n*=256);)s+=this[e+--r]*n;return s>=(n*=128)&&(s-=Math.pow(2,8*t)),s},M.prototype.readInt8=function(e,t){return t||X(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},M.prototype.readInt16LE=function(e,t){t||X(e,2,this.length);var i=this[e]|this[e+1]<<8;return 32768&i?4294901760|i:i},M.prototype.readInt16BE=function(e,t){t||X(e,2,this.length);var i=this[e+1]|this[e]<<8;return 32768&i?4294901760|i:i},M.prototype.readInt32LE=function(e,t){return t||X(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},M.prototype.readInt32BE=function(e,t){return t||X(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},M.prototype.readFloatLE=function(e,t){return t||X(e,4,this.length),w(this,e,!0,23,4)},M.prototype.readFloatBE=function(e,t){return t||X(e,4,this.length),w(this,e,!1,23,4)},M.prototype.readDoubleLE=function(e,t){return t||X(e,8,this.length),w(this,e,!0,52,8)},M.prototype.readDoubleBE=function(e,t){return t||X(e,8,this.length),w(this,e,!1,52,8)},M.prototype.writeUIntLE=function(e,t,i,r){e=+e,t|=0,i|=0,r||Z(this,e,t,i,Math.pow(2,8*i)-1,0);var n=1,s=0;for(this[t]=255&e;++s<i&&(n*=256);)this[t+s]=e/n&255;return t+i},M.prototype.writeUIntBE=function(e,t,i,r){e=+e,t|=0,i|=0,r||Z(this,e,t,i,Math.pow(2,8*i)-1,0);var n=i-1,s=1;for(this[t+n]=255&e;--n>=0&&(s*=256);)this[t+n]=e/s&255;return t+i},M.prototype.writeUInt8=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,1,255,0),M.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},M.prototype.writeUInt16LE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,2,65535,0),M.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):J(this,e,t,!0),t+2},M.prototype.writeUInt16BE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,2,65535,0),M.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):J(this,e,t,!1),t+2},M.prototype.writeUInt32LE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,4,4294967295,0),M.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):ee(this,e,t,!0),t+4},M.prototype.writeUInt32BE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,4,4294967295,0),M.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):ee(this,e,t,!1),t+4},M.prototype.writeIntLE=function(e,t,i,r){if(e=+e,t|=0,!r){var n=Math.pow(2,8*i-1);Z(this,e,t,i,n-1,-n)}var s=0,o=1,a=0;for(this[t]=255&e;++s<i&&(o*=256);)e<0&&0===a&&0!==this[t+s-1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},M.prototype.writeIntBE=function(e,t,i,r){if(e=+e,t|=0,!r){var n=Math.pow(2,8*i-1);Z(this,e,t,i,n-1,-n)}var s=i-1,o=1,a=0;for(this[t+s]=255&e;--s>=0&&(o*=256);)e<0&&0===a&&0!==this[t+s+1]&&(a=1),this[t+s]=(e/o|0)-a&255;return t+i},M.prototype.writeInt8=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,1,127,-128),M.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},M.prototype.writeInt16LE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,2,32767,-32768),M.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):J(this,e,t,!0),t+2},M.prototype.writeInt16BE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,2,32767,-32768),M.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):J(this,e,t,!1),t+2},M.prototype.writeInt32LE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,4,2147483647,-2147483648),M.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):ee(this,e,t,!0),t+4},M.prototype.writeInt32BE=function(e,t,i){return e=+e,t|=0,i||Z(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),M.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):ee(this,e,t,!1),t+4},M.prototype.writeFloatLE=function(e,t,i){return ie(this,e,t,!0,i)},M.prototype.writeFloatBE=function(e,t,i){return ie(this,e,t,!1,i)},M.prototype.writeDoubleLE=function(e,t,i){return re(this,e,t,!0,i)},M.prototype.writeDoubleBE=function(e,t,i){return re(this,e,t,!1,i)},M.prototype.copy=function(e,t,i,r){if(i||(i=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r<i&&(r=i),r===i)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(i<0||i>=this.length)throw new RangeError("sourceStart out of bounds");if(r<0)throw new RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t<r-i&&(r=e.length-t+i);var n,s=r-i;if(this===e&&i<t&&t<r)for(n=s-1;n>=0;--n)e[n+t]=this[n+i];else if(s<1e3||!M.TYPED_ARRAY_SUPPORT)for(n=0;n<s;++n)e[n+t]=this[n+i];else Uint8Array.prototype.set.call(e,this.subarray(i,i+s),t);return s},M.prototype.fill=function(e,t,i,r){if("string"==typeof e){if("string"==typeof t?(r=t,t=0,i=this.length):"string"==typeof i&&(r=i,i=this.length),1===e.length){var n=e.charCodeAt(0);n<256&&(e=n)}if(void 0!==r&&"string"!=typeof r)throw new TypeError("encoding must be a string");if("string"==typeof r&&!M.isEncoding(r))throw new TypeError("Unknown encoding: "+r)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<i)throw new RangeError("Out of range index");if(i<=t)return this;var s;if(t>>>=0,i=void 0===i?this.length:i>>>0,e||(e=0),"number"==typeof e)for(s=t;s<i;++s)this[s]=e;else{var o=I(e)?e:oe(new M(e,r).toString()),a=o.length;for(s=0;s<i-t;++s)this[s+t]=o[s%a]}return this};var ne=/[^+\/0-9A-Za-z-_]/g;function se(e){return e<16?"0"+e.toString(16):e.toString(16)}function oe(e,t){var i;t=t||1/0;for(var r=e.length,n=null,s=[],o=0;o<r;++o){if((i=e.charCodeAt(o))>55295&&i<57344){if(!n){if(i>56319){(t-=3)>-1&&s.push(239,191,189);continue}if(o+1===r){(t-=3)>-1&&s.push(239,191,189);continue}n=i;continue}if(i<56320){(t-=3)>-1&&s.push(239,191,189),n=i;continue}i=65536+(n-55296<<10|i-56320)}else n&&(t-=3)>-1&&s.push(239,191,189);if(n=null,i<128){if((t-=1)<0)break;s.push(i)}else if(i<2048){if((t-=2)<0)break;s.push(i>>6|192,63&i|128)}else if(i<65536){if((t-=3)<0)break;s.push(i>>12|224,i>>6&63|128,63&i|128)}else{if(!(i<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;s.push(i>>18|240,i>>12&63|128,i>>6&63|128,63&i|128)}}return s}function ae(e){return function(e){var t,i,r,n,s,o;f||m();var a=e.length;if(a%4>0)throw new Error("Invalid string. Length must be a multiple of 4");s="="===e[a-2]?2:"="===e[a-1]?1:0,o=new g(3*a/4-s),r=s>0?a-4:a;var l=0;for(t=0,i=0;t<r;t+=4,i+=3)n=p[e.charCodeAt(t)]<<18|p[e.charCodeAt(t+1)]<<12|p[e.charCodeAt(t+2)]<<6|p[e.charCodeAt(t+3)],o[l++]=n>>16&255,o[l++]=n>>8&255,o[l++]=255&n;return 2===s?(n=p[e.charCodeAt(t)]<<2|p[e.charCodeAt(t+1)]>>4,o[l++]=255&n):1===s&&(n=p[e.charCodeAt(t)]<<10|p[e.charCodeAt(t+1)]<<4|p[e.charCodeAt(t+2)]>>2,o[l++]=n>>8&255,o[l++]=255&n),o}(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(ne,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function le(e,t,i,r){for(var n=0;n<r&&!(n+i>=t.length||n>=e.length);++n)t[n+i]=e[n];return n}function ce(e){return null!=e&&(!!e._isBuffer||ue(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&ue(e.slice(0,0))}(e))}function ue(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function he(){throw new Error("setTimeout has not been defined")}function de(){throw new Error("clearTimeout has not been defined")}var pe=he,ge=de;function fe(e){if(pe===setTimeout)return setTimeout(e,0);if((pe===he||!pe)&&setTimeout)return pe=setTimeout,setTimeout(e,0);try{return pe(e,0)}catch(t){try{return pe.call(null,e,0)}catch(t){return pe.call(this,e,0)}}}"function"==typeof h.setTimeout&&(pe=setTimeout),"function"==typeof h.clearTimeout&&(ge=clearTimeout);var me,ve=[],Ce=!1,ye=-1;function we(){Ce&&me&&(Ce=!1,me.length?ve=me.concat(ve):ye=-1,ve.length&&Se())}function Se(){if(!Ce){var e=fe(we);Ce=!0;for(var t=ve.length;t;){for(me=ve,ve=[];++ye<t;)me&&me[ye].run();ye=-1,t=ve.length}me=null,Ce=!1,function(e){if(ge===clearTimeout)return clearTimeout(e);if((ge===de||!ge)&&clearTimeout)return ge=clearTimeout,clearTimeout(e);try{return ge(e)}catch(t){try{return ge.call(null,e)}catch(t){return ge.call(this,e)}}}(e)}}function be(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var i=1;i<arguments.length;i++)t[i-1]=arguments[i];ve.push(new Ee(e,t)),1!==ve.length||Ce||fe(Se)}function Ee(e,t){this.fun=e,this.array=t}Ee.prototype.run=function(){this.fun.apply(null,this.array)};var Ae=h.performance||{};Ae.now||Ae.mozNow||Ae.msNow||Ae.oNow||Ae.webkitNow;var Te={env:{}},Me="function"==typeof Object.create?function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:function(e,t){e.super_=t;var i=function(){};i.prototype=t.prototype,e.prototype=new i,e.prototype.constructor=e},Re=/%[sdj%]/g;function _e(e){if(!He(e)){for(var t=[],i=0;i<arguments.length;i++)t.push(Ie(arguments[i]));return t.join(" ")}i=1;for(var r=arguments,n=r.length,s=String(e).replace(Re,function(e){if("%%"===e)return"%";if(i>=n)return e;switch(e){case"%s":return String(r[i++]);case"%d":return Number(r[i++]);case"%j":try{return JSON.stringify(r[i++])}catch(e){return"[Circular]"}default:return e}}),o=r[i];i<n;o=r[++i])Ve(o)||!Ue(o)?s+=" "+o:s+=" "+Ie(o);return s}function Pe(e,t){if(Be(h.process))return function(){return Pe(e,t).apply(this,arguments)};if(!0===Te.noDeprecation)return e;var i=!1;return function(){if(!i){if(Te.throwDeprecation)throw new Error(t);Te.traceDeprecation?console.trace(t):console.error(t),i=!0}return e.apply(this,arguments)}}var xe,De={};function Ie(e,t){var i={seen:[],stylize:Ne};return arguments.length>=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),Ge(t)?i.showHidden=t:t&&function(e,t){if(!t||!Ue(t))return e;for(var i=Object.keys(t),r=i.length;r--;)e[i[r]]=t[i[r]]}(i,t),Be(i.showHidden)&&(i.showHidden=!1),Be(i.depth)&&(i.depth=2),Be(i.colors)&&(i.colors=!1),Be(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=Le),Oe(i,e,i.depth)}function Le(e,t){var i=Ie.styles[t];return i?"["+Ie.colors[i][0]+"m"+e+"["+Ie.colors[i][1]+"m":e}function Ne(e,t){return e}function Oe(e,t,i){if(e.customInspect&&t&&Ke(t.inspect)&&t.inspect!==Ie&&(!t.constructor||t.constructor.prototype!==t)){var r=t.inspect(i,e);return He(r)||(r=Oe(e,r,i)),r}var n=function(e,t){if(Be(t))return e.stylize("undefined","undefined");if(He(t)){var i="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(i,"string")}return"number"==typeof t?e.stylize(""+t,"number"):Ge(t)?e.stylize(""+t,"boolean"):Ve(t)?e.stylize("null","null"):void 0}(e,t);if(n)return n;var s=Object.keys(t),o=function(e){var t={};return e.forEach(function(e,i){t[e]=!0}),t}(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(t)),je(t)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return Fe(t);if(0===s.length){if(Ke(t)){var a=t.name?": "+t.name:"";return e.stylize("[Function"+a+"]","special")}if(ze(t))return e.stylize(RegExp.prototype.toString.call(t),"regexp");if(We(t))return e.stylize(Date.prototype.toString.call(t),"date");if(je(t))return Fe(t)}var l,c,u="",h=!1,d=["{","}"];return l=t,Array.isArray(l)&&(h=!0,d=["[","]"]),Ke(t)&&(u=" [Function"+(t.name?": "+t.name:"")+"]"),ze(t)&&(u=" "+RegExp.prototype.toString.call(t)),We(t)&&(u=" "+Date.prototype.toUTCString.call(t)),je(t)&&(u=" "+Fe(t)),0!==s.length||h&&0!=t.length?i<0?ze(t)?e.stylize(RegExp.prototype.toString.call(t),"regexp"):e.stylize("[Object]","special"):(e.seen.push(t),c=h?function(e,t,i,r,n){for(var s=[],o=0,a=t.length;o<a;++o)qe(t,String(o))?s.push(ke(e,t,i,r,String(o),!0)):s.push("");return n.forEach(function(n){n.match(/^\d+$/)||s.push(ke(e,t,i,r,n,!0))}),s}(e,t,i,o,s):s.map(function(r){return ke(e,t,i,o,r,h)}),e.seen.pop(),function(e,t,i){return e.reduce(function(e,t){return t.indexOf("\n"),e+t.replace(/\u001b\[\d\d?m/g,"").length+1},0)>60?i[0]+(""===t?"":t+"\n ")+" "+e.join(",\n  ")+" "+i[1]:i[0]+t+" "+e.join(", ")+" "+i[1]}(c,u,d)):d[0]+u+d[1]}function Fe(e){return"["+Error.prototype.toString.call(e)+"]"}function ke(e,t,i,r,n,s){var o,a,l;if((l=Object.getOwnPropertyDescriptor(t,n)||{value:t[n]}).get?a=l.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):l.set&&(a=e.stylize("[Setter]","special")),qe(r,n)||(o="["+n+"]"),a||(e.seen.indexOf(l.value)<0?(a=Ve(i)?Oe(e,l.value,null):Oe(e,l.value,i-1)).indexOf("\n")>-1&&(a=s?a.split("\n").map(function(e){return"  "+e}).join("\n").substr(2):"\n"+a.split("\n").map(function(e){return"   "+e}).join("\n")):a=e.stylize("[Circular]","special")),Be(o)){if(s&&n.match(/^\d+$/))return a;(o=JSON.stringify(""+n)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(o=o.substr(1,o.length-2),o=e.stylize(o,"name")):(o=o.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),o=e.stylize(o,"string"))}return o+": "+a}function Ge(e){return"boolean"==typeof e}function Ve(e){return null===e}function He(e){return"string"==typeof e}function Be(e){return void 0===e}function ze(e){return Ue(e)&&"[object RegExp]"===$e(e)}function Ue(e){return"object"==typeof e&&null!==e}function We(e){return Ue(e)&&"[object Date]"===$e(e)}function je(e){return Ue(e)&&("[object Error]"===$e(e)||e instanceof Error)}function Ke(e){return"function"==typeof e}function $e(e){return Object.prototype.toString.call(e)}function qe(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Ye(){this.head=null,this.tail=null,this.length=0}Ie.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},Ie.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},Ye.prototype.push=function(e){var t={data:e,next:null};this.length>0?this.tail.next=t:this.head=t,this.tail=t,++this.length},Ye.prototype.unshift=function(e){var t={data:e,next:this.head};0===this.length&&(this.tail=t),this.head=t,++this.length},Ye.prototype.shift=function(){if(0!==this.length){var e=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,e}},Ye.prototype.clear=function(){this.head=this.tail=null,this.length=0},Ye.prototype.join=function(e){if(0===this.length)return"";for(var t=this.head,i=""+t.data;t=t.next;)i+=e+t.data;return i},Ye.prototype.concat=function(e){if(0===this.length)return M.alloc(0);if(1===this.length)return this.head.data;for(var t=M.allocUnsafe(e>>>0),i=this.head,r=0;i;)i.data.copy(t,r),r+=i.data.length,i=i.next;return t};var Qe=M.isEncoding||function(e){switch(e&&e.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function Xe(e){switch(this.encoding=(e||"utf8").toLowerCase().replace(/[-_]/,""),function(e){if(e&&!Qe(e))throw new Error("Unknown encoding: "+e)}(e),this.encoding){case"utf8":this.surrogateSize=3;break;case"ucs2":case"utf16le":this.surrogateSize=2,this.detectIncompleteChar=Je;break;case"base64":this.surrogateSize=3,this.detectIncompleteChar=et;break;default:return void(this.write=Ze)}this.charBuffer=new M(6),this.charReceived=0,this.charLength=0}function Ze(e){return e.toString(this.encoding)}function Je(e){this.charReceived=e.length%2,this.charLength=this.charReceived?2:0}function et(e){this.charReceived=e.length%3,this.charLength=this.charReceived?3:0}Xe.prototype.write=function(e){for(var t="";this.charLength;){var i=e.length>=this.charLength-this.charReceived?this.charLength-this.charReceived:e.length;if(e.copy(this.charBuffer,this.charReceived,0,i),this.charReceived+=i,this.charReceived<this.charLength)return"";if(e=e.slice(i,e.length),!((r=(t=this.charBuffer.slice(0,this.charLength).toString(this.encoding)).charCodeAt(t.length-1))>=55296&&r<=56319)){if(this.charReceived=this.charLength=0,0===e.length)return t;break}this.charLength+=this.surrogateSize,t=""}this.detectIncompleteChar(e);var r,n=e.length;if(this.charLength&&(e.copy(this.charBuffer,0,e.length-this.charReceived,n),n-=this.charReceived),n=(t+=e.toString(this.encoding,0,n)).length-1,(r=t.charCodeAt(n))>=55296&&r<=56319){var s=this.surrogateSize;return this.charLength+=s,this.charReceived+=s,this.charBuffer.copy(this.charBuffer,s,0,s),e.copy(this.charBuffer,0,0,s),t.substring(0,n)}return t},Xe.prototype.detectIncompleteChar=function(e){for(var t=e.length>=3?3:e.length;t>0;t--){var i=e[e.length-t];if(1==t&&i>>5==6){this.charLength=2;break}if(t<=2&&i>>4==14){this.charLength=3;break}if(t<=3&&i>>3==30){this.charLength=4;break}}this.charReceived=t},Xe.prototype.end=function(e){var t="";if(e&&e.length&&(t=this.write(e)),this.charReceived){var i=this.charReceived,r=this.charBuffer,n=this.encoding;t+=r.slice(0,i).toString(n)}return t},nt.ReadableState=rt;var tt,it=(tt="stream",Be(xe)&&(xe=Te.env.NODE_DEBUG||""),tt=tt.toUpperCase(),De[tt]||(new RegExp("\\b"+tt+"\\b","i").test(xe)?De[tt]=function(){var e=_e.apply(null,arguments);console.error("%s %d: %s",tt,0,e)}:De[tt]=function(){}),De[tt]);function rt(e,t){e=e||{},this.objectMode=!!e.objectMode,t instanceof It&&(this.objectMode=this.objectMode||!!e.readableObjectMode);var i=e.highWaterMark,r=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r,this.highWaterMark=~~this.highWaterMark,this.buffer=new Ye,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.defaultEncoding=e.defaultEncoding||"utf8",this.ranOut=!1,this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,e.encoding&&(this.decoder=new Xe(e.encoding),this.encoding=e.encoding)}function nt(e){if(!(this instanceof nt))return new nt(e);this._readableState=new rt(e,this),this.readable=!0,e&&"function"==typeof e.read&&(this._read=e.read),s.call(this)}function st(e,t,i,r,n){var s=function(e,t){var i=null;return ce(t)||"string"==typeof t||null==t||e.objectMode||(i=new TypeError("Invalid non-string/buffer chunk")),i}(t,i);if(s)e.emit("error",s);else if(null===i)t.reading=!1,function(e,t){if(!t.ended){if(t.decoder){var i=t.decoder.end();i&&i.length&&(t.buffer.push(i),t.length+=t.objectMode?1:i.length)}t.ended=!0,lt(e)}}(e,t);else if(t.objectMode||i&&i.length>0)if(t.ended&&!n){var o=new Error("stream.push() after EOF");e.emit("error",o)}else if(t.endEmitted&&n){var a=new Error("stream.unshift() after end event");e.emit("error",a)}else{var l;!t.decoder||n||r||(i=t.decoder.write(i),l=!t.objectMode&&0===i.length),n||(t.reading=!1),l||(t.flowing&&0===t.length&&!t.sync?(e.emit("data",i),e.read(0)):(t.length+=t.objectMode?1:i.length,n?t.buffer.unshift(i):t.buffer.push(i),t.needReadable&&lt(e))),function(e,t){t.readingMore||(t.readingMore=!0,be(ut,e,t))}(e,t)}else n||(t.reading=!1);return function(e){return!e.ended&&(e.needReadable||e.length<e.highWaterMark||0===e.length)}(t)}Me(nt,s),nt.prototype.push=function(e,t){var i=this._readableState;return i.objectMode||"string"!=typeof e||(t=t||i.defaultEncoding)!==i.encoding&&(e=M.from(e,t),t=""),st(this,i,e,t,!1)},nt.prototype.unshift=function(e){return st(this,this._readableState,e,"",!0)},nt.prototype.isPaused=function(){return!1===this._readableState.flowing},nt.prototype.setEncoding=function(e){return this._readableState.decoder=new Xe(e),this._readableState.encoding=e,this};var ot=8388608;function at(e,t){return e<=0||0===t.length&&t.ended?0:t.objectMode?1:e!=e?t.flowing&&t.length?t.buffer.head.data.length:t.length:(e>t.highWaterMark&&(t.highWaterMark=function(e){return e>=ot?e=ot:(e--,e|=e>>>1,e|=e>>>2,e|=e>>>4,e|=e>>>8,e|=e>>>16,e++),e}(e)),e<=t.length?e:t.ended?t.length:(t.needReadable=!0,0))}function lt(e){var t=e._readableState;t.needReadable=!1,t.emittedReadable||(it("emitReadable",t.flowing),t.emittedReadable=!0,t.sync?be(ct,e):ct(e))}function ct(e){it("emit readable"),e.emit("readable"),pt(e)}function ut(e,t){for(var i=t.length;!t.reading&&!t.flowing&&!t.ended&&t.length<t.highWaterMark&&(it("maybeReadMore read 0"),e.read(0),i!==t.length);)i=t.length;t.readingMore=!1}function ht(e){it("readable nexttick read 0"),e.read(0)}function dt(e,t){t.reading||(it("resume read 0"),e.read(0)),t.resumeScheduled=!1,t.awaitDrain=0,e.emit("resume"),pt(e),t.flowing&&!t.reading&&e.read(0)}function pt(e){var t=e._readableState;for(it("flow",t.flowing);t.flowing&&null!==e.read(););}function gt(e,t){return 0===t.length?null:(t.objectMode?i=t.buffer.shift():!e||e>=t.length?(i=t.decoder?t.buffer.join(""):1===t.buffer.length?t.buffer.head.data:t.buffer.concat(t.length),t.buffer.clear()):i=function(e,t,i){var r;return e<t.head.data.length?(r=t.head.data.slice(0,e),t.head.data=t.head.data.slice(e)):r=e===t.head.data.length?t.shift():i?function(e,t){var i=t.head,r=1,n=i.data;for(e-=n.length;i=i.next;){var s=i.data,o=e>s.length?s.length:e;if(o===s.length?n+=s:n+=s.slice(0,e),0===(e-=o)){o===s.length?(++r,i.next?t.head=i.next:t.head=t.tail=null):(t.head=i,i.data=s.slice(o));break}++r}return t.length-=r,n}(e,t):function(e,t){var i=M.allocUnsafe(e),r=t.head,n=1;for(r.data.copy(i),e-=r.data.length;r=r.next;){var s=r.data,o=e>s.length?s.length:e;if(s.copy(i,i.length-e,0,o),0===(e-=o)){o===s.length?(++n,r.next?t.head=r.next:t.head=t.tail=null):(t.head=r,r.data=s.slice(o));break}++n}return t.length-=n,i}(e,t),r}(e,t.buffer,t.decoder),i);var i}function ft(e){var t=e._readableState;if(t.length>0)throw new Error('"endReadable()" called on non-empty stream');t.endEmitted||(t.ended=!0,be(mt,t,e))}function mt(e,t){e.endEmitted||0!==e.length||(e.endEmitted=!0,t.readable=!1,t.emit("end"))}function vt(e,t){for(var i=0,r=e.length;i<r;i++)if(e[i]===t)return i;return-1}function Ct(){}function yt(e,t,i){this.chunk=e,this.encoding=t,this.callback=i,this.next=null}function wt(e,t){Object.defineProperty(this,"buffer",{get:Pe(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.")}),e=e||{},this.objectMode=!!e.objectMode,t instanceof It&&(this.objectMode=this.objectMode||!!e.writableObjectMode);var i=e.highWaterMark,r=this.objectMode?16:16384;this.highWaterMark=i||0===i?i:r,this.highWaterMark=~~this.highWaterMark,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1;var n=!1===e.decodeStrings;this.decodeStrings=!n,this.defaultEncoding=e.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(e){!function(e,t){var i=e._writableState,r=i.sync,n=i.writecb;if(function(e){e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0}(i),t)!function(e,t,i,r,n){--t.pendingcb,i?be(n,r):n(r),e._writableState.errorEmitted=!0,e.emit("error",r)}(e,i,r,t,n);else{var s=Tt(i);s||i.corked||i.bufferProcessing||!i.bufferedRequest||At(e,i),r?be(Et,e,i,s,n):Et(e,i,s,n)}}(t,e)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.bufferedRequestCount=0,this.corkedRequestsFree=new _t(this)}function St(e){if(!(this instanceof St||this instanceof It))return new St(e);this._writableState=new wt(e,this),this.writable=!0,e&&("function"==typeof e.write&&(this._write=e.write),"function"==typeof e.writev&&(this._writev=e.writev)),s.call(this)}function bt(e,t,i,r,n,s,o){t.writelen=r,t.writecb=o,t.writing=!0,t.sync=!0,i?e._writev(n,t.onwrite):e._write(n,s,t.onwrite),t.sync=!1}function Et(e,t,i,r){i||function(e,t){0===t.length&&t.needDrain&&(t.needDrain=!1,e.emit("drain"))}(e,t),t.pendingcb--,r(),Rt(e,t)}function At(e,t){t.bufferProcessing=!0;var i=t.bufferedRequest;if(e._writev&&i&&i.next){var r=t.bufferedRequestCount,n=new Array(r),s=t.corkedRequestsFree;s.entry=i;for(var o=0;i;)n[o]=i,i=i.next,o+=1;bt(e,t,!0,t.length,n,"",s.finish),t.pendingcb++,t.lastBufferedRequest=null,s.next?(t.corkedRequestsFree=s.next,s.next=null):t.corkedRequestsFree=new _t(t)}else{for(;i;){var a=i.chunk,l=i.encoding,c=i.callback;if(bt(e,t,!1,t.objectMode?1:a.length,a,l,c),i=i.next,t.writing)break}null===i&&(t.lastBufferedRequest=null)}t.bufferedRequestCount=0,t.bufferedRequest=i,t.bufferProcessing=!1}function Tt(e){return e.ending&&0===e.length&&null===e.bufferedRequest&&!e.finished&&!e.writing}function Mt(e,t){t.prefinished||(t.prefinished=!0,e.emit("prefinish"))}function Rt(e,t){var i=Tt(t);return i&&(0===t.pendingcb?(Mt(e,t),t.finished=!0,e.emit("finish")):Mt(e,t)),i}function _t(e){var t=this;this.next=null,this.entry=null,this.finish=function(i){var r=t.entry;for(t.entry=null;r;){var n=r.callback;e.pendingcb--,n(i),r=r.next}e.corkedRequestsFree?e.corkedRequestsFree.next=t:e.corkedRequestsFree=t}}nt.prototype.read=function(e){it("read",e),e=parseInt(e,10);var t=this._readableState,i=e;if(0!==e&&(t.emittedReadable=!1),0===e&&t.needReadable&&(t.length>=t.highWaterMark||t.ended))return it("read: emitReadable",t.length,t.ended),0===t.length&&t.ended?ft(this):lt(this),null;if(0===(e=at(e,t))&&t.ended)return 0===t.length&&ft(this),null;var r,n=t.needReadable;return it("need readable",n),(0===t.length||t.length-e<t.highWaterMark)&&it("length less than watermark",n=!0),t.ended||t.reading?it("reading or ended",n=!1):n&&(it("do read"),t.reading=!0,t.sync=!0,0===t.length&&(t.needReadable=!0),this._read(t.highWaterMark),t.sync=!1,t.reading||(e=at(i,t))),null===(r=e>0?gt(e,t):null)?(t.needReadable=!0,e=0):t.length-=e,0===t.length&&(t.ended||(t.needReadable=!0),i!==e&&t.ended&&ft(this)),null!==r&&this.emit("data",r),r},nt.prototype._read=function(e){this.emit("error",new Error("not implemented"))},nt.prototype.pipe=function(e,t){var i=this,r=this._readableState;switch(r.pipesCount){case 0:r.pipes=e;break;case 1:r.pipes=[r.pipes,e];break;default:r.pipes.push(e)}r.pipesCount+=1,it("pipe count=%d opts=%j",r.pipesCount,t);var n=t&&!1===t.end?c:o;function s(e){it("onunpipe"),e===i&&c()}function o(){it("onend"),e.end()}r.endEmitted?be(n):i.once("end",n),e.on("unpipe",s);var a=function(e){return function(){var t=e._readableState;it("pipeOnDrain",t.awaitDrain),t.awaitDrain&&t.awaitDrain--,0===t.awaitDrain&&e.listeners("data").length&&(t.flowing=!0,pt(e))}}(i);e.on("drain",a);var l=!1;function c(){it("cleanup"),e.removeListener("close",p),e.removeListener("finish",g),e.removeListener("drain",a),e.removeListener("error",d),e.removeListener("unpipe",s),i.removeListener("end",o),i.removeListener("end",c),i.removeListener("data",h),l=!0,!r.awaitDrain||e._writableState&&!e._writableState.needDrain||a()}var u=!1;function h(t){it("ondata"),u=!1,!1!==e.write(t)||u||((1===r.pipesCount&&r.pipes===e||r.pipesCount>1&&-1!==vt(r.pipes,e))&&!l&&(it("false write response, pause",i._readableState.awaitDrain),i._readableState.awaitDrain++,u=!0),i.pause())}function d(t){it("onerror",t),f(),e.removeListener("error",d),0===e.listeners("error").length&&e.emit("error",t)}function p(){e.removeListener("finish",g),f()}function g(){it("onfinish"),e.removeListener("close",p),f()}function f(){it("unpipe"),i.unpipe(e)}return i.on("data",h),function(e,t,i){if("function"==typeof e.prependListener)return e.prependListener(t,i);e._events&&e._events[t]?Array.isArray(e._events[t])?e._events[t].unshift(i):e._events[t]=[i,e._events[t]]:e.on(t,i)}(e,"error",d),e.once("close",p),e.once("finish",g),e.emit("pipe",i),r.flowing||(it("pipe resume"),i.resume()),e},nt.prototype.unpipe=function(e){var t=this._readableState;if(0===t.pipesCount)return this;if(1===t.pipesCount)return e&&e!==t.pipes||(e||(e=t.pipes),t.pipes=null,t.pipesCount=0,t.flowing=!1,e&&e.emit("unpipe",this)),this;if(!e){var i=t.pipes,r=t.pipesCount;t.pipes=null,t.pipesCount=0,t.flowing=!1;for(var n=0;n<r;n++)i[n].emit("unpipe",this);return this}var s=vt(t.pipes,e);return-1===s||(t.pipes.splice(s,1),t.pipesCount-=1,1===t.pipesCount&&(t.pipes=t.pipes[0]),e.emit("unpipe",this)),this},nt.prototype.on=function(e,t){var i=s.prototype.on.call(this,e,t);if("data"===e)!1!==this._readableState.flowing&&this.resume();else if("readable"===e){var r=this._readableState;r.endEmitted||r.readableListening||(r.readableListening=r.needReadable=!0,r.emittedReadable=!1,r.reading?r.length&&lt(this):be(ht,this))}return i},nt.prototype.addListener=nt.prototype.on,nt.prototype.resume=function(){var e=this._readableState;return e.flowing||(it("resume"),e.flowing=!0,function(e,t){t.resumeScheduled||(t.resumeScheduled=!0,be(dt,e,t))}(this,e)),this},nt.prototype.pause=function(){return it("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(it("pause"),this._readableState.flowing=!1,this.emit("pause")),this},nt.prototype.wrap=function(e){var t=this._readableState,i=!1,r=this;for(var n in e.on("end",function(){if(it("wrapped end"),t.decoder&&!t.ended){var e=t.decoder.end();e&&e.length&&r.push(e)}r.push(null)}),e.on("data",function(n){it("wrapped data"),t.decoder&&(n=t.decoder.write(n)),t.objectMode&&null==n||(t.objectMode||n&&n.length)&&(r.push(n)||(i=!0,e.pause()))}),e)void 0===this[n]&&"function"==typeof e[n]&&(this[n]=function(t){return function(){return e[t].apply(e,arguments)}}(n));return function(e,t){for(var i=0,r=e.length;i<r;i++)t(e[i])}(["error","close","destroy","pause","resume"],function(t){e.on(t,r.emit.bind(r,t))}),r._read=function(t){it("wrapped _read",t),i&&(i=!1,e.resume())},r},nt._fromList=gt,St.WritableState=wt,Me(St,s),wt.prototype.getBuffer=function(){for(var e=this.bufferedRequest,t=[];e;)t.push(e),e=e.next;return t},St.prototype.pipe=function(){this.emit("error",new Error("Cannot pipe, not readable"))},St.prototype.write=function(e,t,i){var r=this._writableState,n=!1;return"function"==typeof t&&(i=t,t=null),M.isBuffer(e)?t="buffer":t||(t=r.defaultEncoding),"function"!=typeof i&&(i=Ct),r.ended?function(e,t){var i=new Error("write after end");e.emit("error",i),be(t,i)}(this,i):function(e,t,i,r){var n=!0,s=!1;return null===i?s=new TypeError("May not write null values to stream"):M.isBuffer(i)||"string"==typeof i||void 0===i||t.objectMode||(s=new TypeError("Invalid non-string/buffer chunk")),s&&(e.emit("error",s),be(r,s),n=!1),n}(this,r,e,i)&&(r.pendingcb++,n=function(e,t,i,r,n){i=function(e,t,i){return e.objectMode||!1===e.decodeStrings||"string"!=typeof t||(t=M.from(t,i)),t}(t,i,r),M.isBuffer(i)&&(r="buffer");var s=t.objectMode?1:i.length;t.length+=s;var o=t.length<t.highWaterMark;if(o||(t.needDrain=!0),t.writing||t.corked){var a=t.lastBufferedRequest;t.lastBufferedRequest=new yt(i,r,n),a?a.next=t.lastBufferedRequest:t.bufferedRequest=t.lastBufferedRequest,t.bufferedRequestCount+=1}else bt(e,t,!1,s,i,r,n);return o}(this,r,e,t,i)),n},St.prototype.cork=function(){this._writableState.corked++},St.prototype.uncork=function(){var e=this._writableState;e.corked&&(e.corked--,e.writing||e.corked||e.finished||e.bufferProcessing||!e.bufferedRequest||At(this,e))},St.prototype.setDefaultEncoding=function(e){if("string"==typeof e&&(e=e.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((e+"").toLowerCase())>-1))throw new TypeError("Unknown encoding: "+e);return this._writableState.defaultEncoding=e,this},St.prototype._write=function(e,t,i){i(new Error("not implemented"))},St.prototype._writev=null,St.prototype.end=function(e,t,i){var r=this._writableState;"function"==typeof e?(i=e,e=null,t=null):"function"==typeof t&&(i=t,t=null),null!=e&&this.write(e,t),r.corked&&(r.corked=1,this.uncork()),r.ending||r.finished||function(e,t,i){t.ending=!0,Rt(e,t),i&&(t.finished?be(i):e.once("finish",i)),t.ended=!0,e.writable=!1}(this,r,i)},Me(It,nt);for(var Pt=Object.keys(St.prototype),xt=0;xt<Pt.length;xt++){var Dt=Pt[xt];It.prototype[Dt]||(It.prototype[Dt]=St.prototype[Dt])}function It(e){if(!(this instanceof It))return new It(e);nt.call(this,e),St.call(this,e),e&&!1===e.readable&&(this.readable=!1),e&&!1===e.writable&&(this.writable=!1),this.allowHalfOpen=!0,e&&!1===e.allowHalfOpen&&(this.allowHalfOpen=!1),this.once("end",Lt)}function Lt(){this.allowHalfOpen||this._writableState.ended||be(Nt,this)}function Nt(e){e.end()}function Ot(e){this.afterTransform=function(t,i){return function(e,t,i){var r=e._transformState;r.transforming=!1;var n=r.writecb;if(!n)return e.emit("error",new Error("no writecb in Transform class"));r.writechunk=null,r.writecb=null,null!=i&&e.push(i),n(t);var s=e._readableState;s.reading=!1,(s.needReadable||s.length<s.highWaterMark)&&e._read(s.highWaterMark)}(e,t,i)},this.needTransform=!1,this.transforming=!1,this.writecb=null,this.writechunk=null,this.writeencoding=null}function Ft(e){if(!(this instanceof Ft))return new Ft(e);It.call(this,e),this._transformState=new Ot(this);var t=this;this._readableState.needReadable=!0,this._readableState.sync=!1,e&&("function"==typeof e.transform&&(this._transform=e.transform),"function"==typeof e.flush&&(this._flush=e.flush)),this.once("prefinish",function(){"function"==typeof this._flush?this._flush(function(e){kt(t,e)}):kt(t)})}function kt(e,t){if(t)return e.emit("error",t);var i=e._writableState,r=e._transformState;if(i.length)throw new Error("Calling transform done when ws.length != 0");if(r.transforming)throw new Error("Calling transform done when still transforming");return e.push(null)}function Gt(e){if(!(this instanceof Gt))return new Gt(e);Ft.call(this,e)}function Vt(){s.call(this)}Me(Ft,It),Ft.prototype.push=function(e,t){return this._transformState.needTransform=!1,It.prototype.push.call(this,e,t)},Ft.prototype._transform=function(e,t,i){throw new Error("Not implemented")},Ft.prototype._write=function(e,t,i){var r=this._transformState;if(r.writecb=i,r.writechunk=e,r.writeencoding=t,!r.transforming){var n=this._readableState;(r.needTransform||n.needReadable||n.length<n.highWaterMark)&&this._read(n.highWaterMark)}},Ft.prototype._read=function(e){var t=this._transformState;null!==t.writechunk&&t.writecb&&!t.transforming?(t.transforming=!0,this._transform(t.writechunk,t.writeencoding,t.afterTransform)):t.needTransform=!0},Me(Gt,Ft),Gt.prototype._transform=function(e,t,i){i(null,e)},Me(Vt,s),Vt.Readable=nt,Vt.Writable=St,Vt.Duplex=It,Vt.Transform=Ft,Vt.PassThrough=Gt,Vt.Stream=Vt,Vt.prototype.pipe=function(e,t){var i=this;function r(t){e.writable&&!1===e.write(t)&&i.pause&&i.pause()}function n(){i.readable&&i.resume&&i.resume()}i.on("data",r),e.on("drain",n),e._isStdio||t&&!1===t.end||(i.on("end",a),i.on("close",l));var o=!1;function a(){o||(o=!0,e.end())}function l(){o||(o=!0,"function"==typeof e.destroy&&e.destroy())}function c(e){if(u(),0===s.listenerCount(this,"error"))throw e}function u(){i.removeListener("data",r),e.removeListener("drain",n),i.removeListener("end",a),i.removeListener("close",l),i.removeListener("error",c),e.removeListener("error",c),i.removeListener("end",u),i.removeListener("close",u),e.removeListener("close",u)}return i.on("error",c),e.on("error",c),i.on("end",u),i.on("close",u),e.on("close",u),e.emit("pipe",i),e};class Ht extends Error{constructor(e,t,...i){Array.isArray(t)&&(t=t.join(" ")),super(t),void 0!==Error.captureStackTrace&&Error.captureStackTrace(this,Ht),this.code=e;for(const e of i)for(const t in e){const i=e[t];this[t]=ce(i)?i.toString():null==i?i:JSON.parse(JSON.stringify(i))}}}const Bt=function(e){return"object"==typeof e&&null!==e&&!Array.isArray(e)},zt=".".charCodeAt(0),Ut=/\\(\\)?/g,Wt=RegExp("[^.[\\]]+|\\[(?:([^\"'][^[]*)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))","g"),jt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Kt=/^\w*$/,$t=function(e){const t=typeof e;return"symbol"===t||"object"===t&&e&&"[object Symbol]"===function(e){return Object.prototype.toString.call(e)}(e)},qt=function(e){if("string"==typeof e||$t(e))return e;const t=`${e}`;return"0"==t&&1/e==-INFINITY?"-0":t},Yt=function(e,t){let i=0;const r=(t=function(e,t){return Array.isArray(e)?e:function(e,t){if(Array.isArray(e))return!1;const i=typeof e;return!("number"!==i&&"symbol"!==i&&"boolean"!==i&&e&&!$t(e))||Kt.test(e)||!jt.test(e)||null!=t&&e in Object(t)}(e,t)?[e]:function(e){const t=[];return e.charCodeAt(0)===zt&&t.push(""),e.replace(Wt,function(e,i,r,n){let s=e;r?s=n.replace(Ut,"$1"):i&&(s=i.trim()),t.push(s)}),t}(e)}(t,e)).length;for(;null!=e&&i<r;)e=e[qt(t[i++])];return i&&i===r?e:void 0},Qt=function(e){if(null==e)return[void 0,void 0];if("object"!=typeof e)return[Error('Invalid option "columns": expect an array or an object')];if(Array.isArray(e)){const t=[];for(const i of e)if("string"==typeof i)t.push({key:i,header:i});else{if("object"!=typeof i||null===i||Array.isArray(i))return[Error("Invalid column definition: expect a string or an object")];if(!i.key)return[Error('Invalid column definition: property "key" is required')];void 0===i.header&&(i.header=i.key),t.push(i)}e=t}else{const t=[];for(const i in e)t.push({key:i,header:e[i]});e=t}return[void 0,e]},Xt=function(e){return e.replace(/([A-Z])/g,function(e,t){return"_"+t.toLowerCase()})},Zt=function(e){const t={};for(const i in e)t[Xt(i)]=e[i];if(void 0===t.bom||null===t.bom||!1===t.bom)t.bom=!1;else if(!0!==t.bom)return[new Ht("CSV_OPTION_BOOLEAN_INVALID_TYPE",["option `bom` is optional and must be a boolean value,",`got ${JSON.stringify(t.bom)}`])];if(void 0===t.delimiter||null===t.delimiter)t.delimiter=",";else if(ce(t.delimiter))t.delimiter=t.delimiter.toString();else if("string"!=typeof t.delimiter)return[new Ht("CSV_OPTION_DELIMITER_INVALID_TYPE",["option `delimiter` must be a buffer or a string,",`got ${JSON.stringify(t.delimiter)}`])];if(void 0===t.quote||null===t.quote)t.quote='"';else if(!0===t.quote)t.quote='"';else if(!1===t.quote)t.quote="";else if(ce(t.quote))t.quote=t.quote.toString();else if("string"!=typeof t.quote)return[new Ht("CSV_OPTION_QUOTE_INVALID_TYPE",["option `quote` must be a boolean, a buffer or a string,",`got ${JSON.stringify(t.quote)}`])];if(void 0!==t.quoted&&null!==t.quoted||(t.quoted=!1),void 0===t.escape_formulas||null===t.escape_formulas)t.escape_formulas=!1;else if("boolean"!=typeof t.escape_formulas)return[new Ht("CSV_OPTION_ESCAPE_FORMULAS_INVALID_TYPE",["option `escape_formulas` must be a boolean,",`got ${JSON.stringify(t.escape_formulas)}`])];if(void 0!==t.quoted_empty&&null!==t.quoted_empty||(t.quoted_empty=void 0),void 0===t.quoted_match||null===t.quoted_match||!1===t.quoted_match?t.quoted_match=null:Array.isArray(t.quoted_match)||(t.quoted_match=[t.quoted_match]),t.quoted_match)for(const e of t.quoted_match){const t=e instanceof RegExp;if("string"!=typeof e&&!t)return[Error(`Invalid Option: quoted_match must be a string or a regex, got ${JSON.stringify(e)}`)]}if(void 0!==t.quoted_string&&null!==t.quoted_string||(t.quoted_string=!1),void 0!==t.eof&&null!==t.eof||(t.eof=!0),void 0===t.escape||null===t.escape)t.escape='"';else if(ce(t.escape))t.escape=t.escape.toString();else if("string"!=typeof t.escape)return[Error(`Invalid Option: escape must be a buffer or a string, got ${JSON.stringify(t.escape)}`)];if(t.escape.length>1)return[Error(`Invalid Option: escape must be one character, got ${t.escape.length} characters`)];void 0!==t.header&&null!==t.header||(t.header=!1);const[i,r]=Qt(t.columns);if(void 0!==i)return[i];if(t.columns=r,void 0!==t.quoted&&null!==t.quoted||(t.quoted=!1),void 0!==t.cast&&null!==t.cast||(t.cast={}),void 0!==t.cast.bigint&&null!==t.cast.bigint||(t.cast.bigint=e=>""+e),void 0!==t.cast.boolean&&null!==t.cast.boolean||(t.cast.boolean=e=>e?"1":""),void 0!==t.cast.date&&null!==t.cast.date||(t.cast.date=e=>""+e.getTime()),void 0!==t.cast.number&&null!==t.cast.number||(t.cast.number=e=>""+e),void 0!==t.cast.object&&null!==t.cast.object||(t.cast.object=e=>JSON.stringify(e)),void 0!==t.cast.string&&null!==t.cast.string||(t.cast.string=function(e){return e}),void 0!==t.on_record&&"function"!=typeof t.on_record)return[Error('Invalid Option: "on_record" must be a function.')];if(void 0===t.record_delimiter||null===t.record_delimiter)t.record_delimiter="\n";else if(ce(t.record_delimiter))t.record_delimiter=t.record_delimiter.toString();else if("string"!=typeof t.record_delimiter)return[Error(`Invalid Option: record_delimiter must be a buffer or a string, got ${JSON.stringify(t.record_delimiter)}`)];switch(t.record_delimiter){case"unix":t.record_delimiter="\n";break;case"mac":t.record_delimiter="\r";break;case"windows":t.record_delimiter="\r\n";break;case"ascii":t.record_delimiter="";break;case"unicode":t.record_delimiter="\u2028"}return[void 0,t]},Jt=M.from([239,187,191]);class ei extends Ft{constructor(e={}){super({writableObjectMode:!0,...e});const[t,i]=Zt(e);if(void 0!==t)throw t;this.options=i,this.state={stop:!1},this.info={records:0},this.api=function(e,t,i){return{options:e,state:t,info:i,__transform:function(e,t){if(!Array.isArray(e)&&"object"!=typeof e)return Error(`Invalid Record: expect an array or an object, got ${JSON.stringify(e)}`);if(0===this.info.records)if(Array.isArray(e)){if(!0===this.options.header&&void 0===this.options.columns)return Error("Undiscoverable Columns: header option requires column option or object records")}else if(void 0===this.options.columns){const[t,i]=Qt(Object.keys(e));if(t)return;this.options.columns=i}if(0===this.info.records){this.bom(t);const e=this.headers(t);if(e)return e}try{this.options.on_record&&this.options.on_record(e,this.info.records)}catch(i){return i}let i,r;if(this.options.eof){if([i,r]=this.stringify(e),i)return i;if(void 0===r)return;r+=this.options.record_delimiter}else{if([i,r]=this.stringify(e),i)return i;if(void 0===r)return;(this.options.header||this.info.records)&&(r=this.options.record_delimiter+r)}this.info.records++,t(r)},stringify:function(e,t=!1){if("object"!=typeof e)return[void 0,e];const{columns:i}=this.options,r=[];if(Array.isArray(e)){i&&e.splice(i.length);for(let i=0;i<e.length;i++){const n=e[i],[s,o]=this.__cast(n,{index:i,column:i,records:this.info.records,header:t});if(s)return[s];r[i]=[o,n]}}else for(let n=0;n<i.length;n++){const s=Yt(e,i[n].key),[o,a]=this.__cast(s,{index:n,column:i[n].key,records:this.info.records,header:t});if(o)return[o];r[n]=[a,s]}let n="";for(let e=0;e<r.length;e++){let t,i,[s,o]=r[e];if("string"==typeof s)t=this.options;else if(Bt(s)){if(t=s,s=t.value,delete t.value,"string"!=typeof s&&null!=s&&i)return[Error(`Invalid Casting Value: returned value must return a string, null or undefined, got ${JSON.stringify(s)}`)];if(t={...this.options,...t},[i,t]=Zt(t),void 0!==i)return[i]}else{if(null!=s)return[Error(`Invalid Casting Value: returned value must return a string, an object, null or undefined, got ${JSON.stringify(s)}`)];t=this.options}const{delimiter:a,escape:l,quote:c,quoted:u,quoted_empty:h,quoted_string:d,quoted_match:p,record_delimiter:g,escape_formulas:f}=t;if(""===s&&""===o){let e=p&&p.filter(e=>"string"==typeof e?-1!==s.indexOf(e):e.test(s));e=e&&e.length>0,!0===(e||!0===h||!0===d&&!1!==h)&&(s=c+s+c),n+=s}else if(s){if("string"!=typeof s)return[Error(`Formatter must return a string, null or undefined, got ${JSON.stringify(s)}`)];const e=a.length&&s.indexOf(a)>=0,t=""!==c&&s.indexOf(c)>=0,i=s.indexOf(l)>=0&&l!==c,r=s.indexOf(g)>=0,h=d&&"string"==typeof o;let m=p&&p.filter(e=>"string"==typeof e?-1!==s.indexOf(e):e.test(s));if(m=m&&m.length>0,f)switch(s[0]){case"=":case"+":case"-":case"@":case"\t":case"\r":case"＝":case"＋":case"－":case"＠":s=`'${s}`}const v=!0===t||e||r||u||h||m;if(!0===v&&!0===i){const e="\\"===l?new RegExp(l+l,"g"):new RegExp(l,"g");s=s.replace(e,l+l)}if(!0===t){const e=new RegExp(c,"g");s=s.replace(e,l+c)}!0===v&&(s=c+s+c),n+=s}else(!0===h||""===o&&!0===d&&!1!==h)&&(n+=c+c);e!==r.length-1&&(n+=a)}return[void 0,n]},bom:function(e){!0===this.options.bom&&e(Jt)},headers:function(e){if(!1===this.options.header)return;if(void 0===this.options.columns)return;let t,i=this.options.columns.map(e=>e.header);if(this.options.eof?([t,i]=this.stringify(i,!0),i+=this.options.record_delimiter):[t,i]=this.stringify(i),t)return t;e(i)},__cast:function(e,t){const i=typeof e;try{return"string"===i?[void 0,this.options.cast.string(e,t)]:"bigint"===i?[void 0,this.options.cast.bigint(e,t)]:"number"===i?[void 0,this.options.cast.number(e,t)]:"boolean"===i?[void 0,this.options.cast.boolean(e,t)]:e instanceof Date?[void 0,this.options.cast.date(e,t)]:"object"===i&&null!==e?[void 0,this.options.cast.object(e,t)]:[void 0,e,e]}catch(e){return[e]}}}}(this.options,this.state,this.info),this.api.options.on_record=(...e)=>{this.emit("record",...e)}}_transform(e,t,i){if(!0===this.state.stop)return;const r=this.api.__transform(e,this.push.bind(this));void 0!==r&&(this.state.stop=!0),i(r)}_flush(e){if(!0!==this.state.stop){if(0===this.info.records){this.api.bom(this.push.bind(this));const t=this.api.headers(this.push.bind(this));t&&e(t)}e()}}}const ti=function(){let e,t,i;for(const r in arguments){const n=arguments[r],s=typeof n;if(void 0===e&&Array.isArray(n))e=n;else if(void 0===t&&Bt(n))t=n;else{if(void 0!==i||"function"!==s)throw new Ht("CSV_INVALID_ARGUMENT",["Invalid argument:",`got ${JSON.stringify(n)} at index ${r}`]);i=n}}const r=new ei(t);if(i){const e=[];r.on("readable",function(){let t;for(;null!==(t=this.read());)e.push(t)}),r.on("error",function(e){i(e)}),r.on("end",function(){try{i(void 0,e.join(""))}catch(e){return void i(e)}})}if(void 0!==e){const t=function(){for(const t of e)r.write(t);r.end()};"function"==typeof setImmediate?setImmediate(t):setTimeout(t,0)}return r}},52413(e,t,i){"use strict";function r(e,t,i){e.prototype=t.prototype=i,i.constructor=e}function n(e,t){var i=Object.create(e.prototype);for(var r in t)i[r]=t[r];return i}function s(){}i.d(t,{Ay:()=>S,Qh:()=>A});var o=.7,a=1/o,l="\\s*([+-]?\\d+)\\s*",c="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",u="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",h=/^#([0-9a-f]{3,8})$/,d=new RegExp(`^rgb\\(${l},${l},${l}\\)$`),p=new RegExp(`^rgb\\(${u},${u},${u}\\)$`),g=new RegExp(`^rgba\\(${l},${l},${l},${c}\\)$`),f=new RegExp(`^rgba\\(${u},${u},${u},${c}\\)$`),m=new RegExp(`^hsl\\(${c},${u},${u}\\)$`),v=new RegExp(`^hsla\\(${c},${u},${u},${c}\\)$`),C={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};function y(){return this.rgb().formatHex()}function w(){return this.rgb().formatRgb()}function S(e){var t,i;return e=(e+"").trim().toLowerCase(),(t=h.exec(e))?(i=t[1].length,t=parseInt(t[1],16),6===i?b(t):3===i?new T(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===i?E(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===i?E(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=d.exec(e))?new T(t[1],t[2],t[3],1):(t=p.exec(e))?new T(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=g.exec(e))?E(t[1],t[2],t[3],t[4]):(t=f.exec(e))?E(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=m.exec(e))?D(t[1],t[2]/100,t[3]/100,1):(t=v.exec(e))?D(t[1],t[2]/100,t[3]/100,t[4]):C.hasOwnProperty(e)?b(C[e]):"transparent"===e?new T(NaN,NaN,NaN,0):null}function b(e){return new T(e>>16&255,e>>8&255,255&e,1)}function E(e,t,i,r){return r<=0&&(e=t=i=NaN),new T(e,t,i,r)}function A(e,t,i,r){return 1===arguments.length?((n=e)instanceof s||(n=S(n)),n?new T((n=n.rgb()).r,n.g,n.b,n.opacity):new T):new T(e,t,i,null==r?1:r);var n}function T(e,t,i,r){this.r=+e,this.g=+t,this.b=+i,this.opacity=+r}function M(){return`#${x(this.r)}${x(this.g)}${x(this.b)}`}function R(){const e=_(this.opacity);return`${1===e?"rgb(":"rgba("}${P(this.r)}, ${P(this.g)}, ${P(this.b)}${1===e?")":`, ${e})`}`}function _(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function P(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function x(e){return((e=P(e))<16?"0":"")+e.toString(16)}function D(e,t,i,r){return r<=0?e=t=i=NaN:i<=0||i>=1?e=t=NaN:t<=0&&(e=NaN),new L(e,t,i,r)}function I(e){if(e instanceof L)return new L(e.h,e.s,e.l,e.opacity);if(e instanceof s||(e=S(e)),!e)return new L;if(e instanceof L)return e;var t=(e=e.rgb()).r/255,i=e.g/255,r=e.b/255,n=Math.min(t,i,r),o=Math.max(t,i,r),a=NaN,l=o-n,c=(o+n)/2;return l?(a=t===o?(i-r)/l+6*(i<r):i===o?(r-t)/l+2:(t-i)/l+4,l/=c<.5?o+n:2-o-n,a*=60):l=c>0&&c<1?0:a,new L(a,l,c,e.opacity)}function L(e,t,i,r){this.h=+e,this.s=+t,this.l=+i,this.opacity=+r}function N(e){return(e=(e||0)%360)<0?e+360:e}function O(e){return Math.max(0,Math.min(1,e||0))}function F(e,t,i){return 255*(e<60?t+(i-t)*e/60:e<180?i:e<240?t+(i-t)*(240-e)/60:t)}r(s,S,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:y,formatHex:y,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return I(this).formatHsl()},formatRgb:w,toString:w}),r(T,A,n(s,{brighter(e){return e=null==e?a:Math.pow(a,e),new T(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?o:Math.pow(o,e),new T(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new T(P(this.r),P(this.g),P(this.b),_(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:M,formatHex:M,formatHex8:function(){return`#${x(this.r)}${x(this.g)}${x(this.b)}${x(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:R,toString:R})),r(L,function(e,t,i,r){return 1===arguments.length?I(e):new L(e,t,i,null==r?1:r)},n(s,{brighter(e){return e=null==e?a:Math.pow(a,e),new L(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?o:Math.pow(o,e),new L(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,i=this.l,r=i+(i<.5?i:1-i)*t,n=2*i-r;return new T(F(e>=240?e-240:e+120,n,r),F(e,n,r),F(e<120?e+240:e-120,n,r),this.opacity)},clamp(){return new L(N(this.h),O(this.s),O(this.l),_(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=_(this.opacity);return`${1===e?"hsl(":"hsla("}${N(this.h)}, ${100*O(this.s)}%, ${100*O(this.l)}%${1===e?")":`, ${e})`}`}}))},54560(e,t,i){"use strict";i.d(t,{A:()=>l});var r={value:()=>{}};function n(){for(var e,t=0,i=arguments.length,r={};t<i;++t){if(!(e=arguments[t]+"")||e in r||/[\s.]/.test(e))throw new Error("illegal type: "+e);r[e]=[]}return new s(r)}function s(e){this._=e}function o(e,t){for(var i,r=0,n=e.length;r<n;++r)if((i=e[r]).name===t)return i.value}function a(e,t,i){for(var n=0,s=e.length;n<s;++n)if(e[n].name===t){e[n]=r,e=e.slice(0,n).concat(e.slice(n+1));break}return null!=i&&e.push({name:t,value:i}),e}s.prototype=n.prototype={constructor:s,on:function(e,t){var i,r,n=this._,s=(r=n,(e+"").trim().split(/^|\s+/).map(function(e){var t="",i=e.indexOf(".");if(i>=0&&(t=e.slice(i+1),e=e.slice(0,i)),e&&!r.hasOwnProperty(e))throw new Error("unknown type: "+e);return{type:e,name:t}})),l=-1,c=s.length;if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t);for(;++l<c;)if(i=(e=s[l]).type)n[i]=a(n[i],e.name,t);else if(null==t)for(i in n)n[i]=a(n[i],e.name,null);return this}for(;++l<c;)if((i=(e=s[l]).type)&&(i=o(n[i],e.name)))return i},copy:function(){var e={},t=this._;for(var i in t)e[i]=t[i].slice();return new s(e)},call:function(e,t){if((i=arguments.length-2)>0)for(var i,r,n=new Array(i),s=0;s<i;++s)n[s]=arguments[s+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=0,i=(r=this._[e]).length;s<i;++s)r[s].value.apply(t,n)},apply:function(e,t,i){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],n=0,s=r.length;n<s;++n)r[n].value.apply(t,i)}};const l=n},83971(e,t,i){"use strict";i.d(t,{A:()=>g});var r=i(54560),n=i(6063),s=i(60616),o=i(37572),a=i(7240);const l=e=>()=>e;function c(e,{sourceEvent:t,subject:i,target:r,identifier:n,active:s,x:o,y:a,dx:l,dy:c,dispatch:u}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:i,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:n,enumerable:!0,configurable:!0},active:{value:s,enumerable:!0,configurable:!0},x:{value:o,enumerable:!0,configurable:!0},y:{value:a,enumerable:!0,configurable:!0},dx:{value:l,enumerable:!0,configurable:!0},dy:{value:c,enumerable:!0,configurable:!0},_:{value:u}})}function u(e){return!e.ctrlKey&&!e.button}function h(){return this.parentNode}function d(e,t){return null==t?{x:e.x,y:e.y}:t}function p(){return navigator.maxTouchPoints||"ontouchstart"in this}function g(){var e,t,i,g,f=u,m=h,v=d,C=p,y={},w=(0,r.A)("start","drag","end"),S=0,b=0;function E(e){e.on("mousedown.drag",A).filter(C).on("touchstart.drag",R).on("touchmove.drag",_,a.vr).on("touchend.drag touchcancel.drag",P).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function A(r,s){if(!g&&f.call(this,r,s)){var l=x(this,m.call(this,r,s),r,s,"mouse");l&&((0,n.A)(r.view).on("mousemove.drag",T,a.Rw).on("mouseup.drag",M,a.Rw),(0,o.A)(r.view),(0,a.GK)(r),i=!1,e=r.clientX,t=r.clientY,l("start",r))}}function T(r){if((0,a.Ay)(r),!i){var n=r.clientX-e,s=r.clientY-t;i=n*n+s*s>b}y.mouse("drag",r)}function M(e){(0,n.A)(e.view).on("mousemove.drag mouseup.drag",null),(0,o.y)(e.view,i),(0,a.Ay)(e),y.mouse("end",e)}function R(e,t){if(f.call(this,e,t)){var i,r,n=e.changedTouches,s=m.call(this,e,t),o=n.length;for(i=0;i<o;++i)(r=x(this,s,e,t,n[i].identifier,n[i]))&&((0,a.GK)(e),r("start",e,n[i]))}}function _(e){var t,i,r=e.changedTouches,n=r.length;for(t=0;t<n;++t)(i=y[r[t].identifier])&&((0,a.Ay)(e),i("drag",e,r[t]))}function P(e){var t,i,r=e.changedTouches,n=r.length;for(g&&clearTimeout(g),g=setTimeout(function(){g=null},500),t=0;t<n;++t)(i=y[r[t].identifier])&&((0,a.GK)(e),i("end",e,r[t]))}function x(e,t,i,r,n,o){var a,l,u,h=w.copy(),d=(0,s.A)(o||i,t);if(null!=(u=v.call(e,new c("beforestart",{sourceEvent:i,target:E,identifier:n,active:S,x:d[0],y:d[1],dx:0,dy:0,dispatch:h}),r)))return a=u.x-d[0]||0,l=u.y-d[1]||0,function i(o,p,g){var f,m=d;switch(o){case"start":y[n]=i,f=S++;break;case"end":delete y[n],--S;case"drag":d=(0,s.A)(g||p,t),f=S}h.call(o,e,new c(o,{sourceEvent:p,subject:u,target:E,identifier:n,active:f,x:d[0]+a,y:d[1]+l,dx:d[0]-m[0],dy:d[1]-m[1],dispatch:h}),r)}}return E.filter=function(e){return arguments.length?(f="function"==typeof e?e:l(!!e),E):f},E.container=function(e){return arguments.length?(m="function"==typeof e?e:l(e),E):m},E.subject=function(e){return arguments.length?(v="function"==typeof e?e:l(e),E):v},E.touchable=function(e){return arguments.length?(C="function"==typeof e?e:l(!!e),E):C},E.on=function(){var e=w.on.apply(w,arguments);return e===w?E:e},E.clickDistance=function(e){return arguments.length?(b=(e=+e)*e,E):Math.sqrt(b)},E}c.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e}},37572(e,t,i){"use strict";i.d(t,{A:()=>s,y:()=>o});var r=i(6063),n=i(7240);function s(e){var t=e.document.documentElement,i=(0,r.A)(e).on("dragstart.drag",n.Ay,n.Rw);"onselectstart"in t?i.on("selectstart.drag",n.Ay,n.Rw):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function o(e,t){var i=e.document.documentElement,s=(0,r.A)(e).on("dragstart.drag",null);t&&(s.on("click.drag",n.Ay,n.Rw),setTimeout(function(){s.on("click.drag",null)},0)),"onselectstart"in i?s.on("selectstart.drag",null):(i.style.MozUserSelect=i.__noselect,delete i.__noselect)}},7240(e,t,i){"use strict";i.d(t,{Ay:()=>o,GK:()=>s,Rw:()=>n,vr:()=>r});const r={passive:!1},n={capture:!0,passive:!1};function s(e){e.stopImmediatePropagation()}function o(e){e.preventDefault(),e.stopImmediatePropagation()}},59394(e,t,i){"use strict";i.d(t,{A:()=>r});const r=e=>()=>e},77419(e,t,i){"use strict";function r(e,t){return e=+e,t=+t,function(i){return e*(1-i)+t*i}}i.d(t,{A:()=>r})},92795(e,t,i){"use strict";i.d(t,{Ay:()=>a});var r=i(52413);function n(e,t,i,r,n){var s=e*e,o=s*e;return((1-3*e+3*s-o)*t+(4-6*s+3*o)*i+(1+3*e+3*s-3*o)*r+o*n)/6}var s=i(59394);function o(e,t){var i=t-e;return i?function(e,t){return function(i){return e+i*t}}(e,i):(0,s.A)(isNaN(e)?t:e)}const a=function e(t){var i=function(e){return 1===(e=+e)?o:function(t,i){return i-t?function(e,t,i){return e=Math.pow(e,i),t=Math.pow(t,i)-e,i=1/i,function(r){return Math.pow(e+r*t,i)}}(t,i,e):(0,s.A)(isNaN(t)?i:t)}}(t);function n(e,t){var n=i((e=(0,r.Qh)(e)).r,(t=(0,r.Qh)(t)).r),s=i(e.g,t.g),a=i(e.b,t.b),l=o(e.opacity,t.opacity);return function(t){return e.r=n(t),e.g=s(t),e.b=a(t),e.opacity=l(t),e+""}}return n.gamma=e,n}(1);function l(e){return function(t){var i,n,s=t.length,o=new Array(s),a=new Array(s),l=new Array(s);for(i=0;i<s;++i)n=(0,r.Qh)(t[i]),o[i]=n.r||0,a[i]=n.g||0,l[i]=n.b||0;return o=e(o),a=e(a),l=e(l),n.opacity=1,function(e){return n.r=o(e),n.g=a(e),n.b=l(e),n+""}}}l(function(e){var t=e.length-1;return function(i){var r=i<=0?i=0:i>=1?(i=1,t-1):Math.floor(i*t),s=e[r],o=e[r+1],a=r>0?e[r-1]:2*s-o,l=r<t-1?e[r+2]:2*o-s;return n((i-r/t)*t,a,s,o,l)}}),l(function(e){var t=e.length;return function(i){var r=Math.floor(((i%=1)<0?++i:i)*t),s=e[(r+t-1)%t],o=e[r%t],a=e[(r+1)%t],l=e[(r+2)%t];return n((i-r/t)*t,s,o,a,l)}})},20835(e,t,i){"use strict";i.d(t,{A:()=>o});var r=i(77419),n=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,s=new RegExp(n.source,"g");function o(e,t){var i,o,a,l=n.lastIndex=s.lastIndex=0,c=-1,u=[],h=[];for(e+="",t+="";(i=n.exec(e))&&(o=s.exec(t));)(a=o.index)>l&&(a=t.slice(l,a),u[c]?u[c]+=a:u[++c]=a),(i=i[0])===(o=o[0])?u[c]?u[c]+=o:u[++c]=o:(u[++c]=null,h.push({i:c,x:(0,r.A)(i,o)})),l=s.lastIndex;return l<t.length&&(a=t.slice(l),u[c]?u[c]+=a:u[++c]=a),u.length<2?h[0]?function(e){return function(t){return e(t)+""}}(h[0].x):function(e){return function(){return e}}(t):(t=h.length,function(e){for(var i,r=0;r<t;++r)u[(i=h[r]).i]=i.x(e);return u.join("")})}},32262(e,t,i){"use strict";i.d(t,{A:()=>d});var r=i(52413),n=i(92795);function s(e,t){var i,r=t?t.length:0,n=e?Math.min(r,e.length):0,s=new Array(n),o=new Array(r);for(i=0;i<n;++i)s[i]=d(e[i],t[i]);for(;i<r;++i)o[i]=t[i];return function(e){for(i=0;i<n;++i)o[i]=s[i](e);return o}}function o(e,t){var i=new Date;return e=+e,t=+t,function(r){return i.setTime(e*(1-r)+t*r),i}}var a=i(77419);function l(e,t){var i,r={},n={};for(i in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)i in e?r[i]=d(e[i],t[i]):n[i]=t[i];return function(e){for(i in r)n[i]=r[i](e);return n}}var c=i(20835),u=i(59394);function h(e,t){t||(t=[]);var i,r=e?Math.min(t.length,e.length):0,n=t.slice();return function(s){for(i=0;i<r;++i)n[i]=e[i]*(1-s)+t[i]*s;return n}}function d(e,t){var i,d,p=typeof t;return null==t||"boolean"===p?(0,u.A)(t):("number"===p?a.A:"string"===p?(i=(0,r.Ay)(t))?(t=i,n.Ay):c.A:t instanceof r.Ay?n.Ay:t instanceof Date?o:(d=t,!ArrayBuffer.isView(d)||d instanceof DataView?Array.isArray(t)?s:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?l:a.A:h))(e,t)}},96785(e,t,i){"use strict";function r(e){return((e=Math.exp(e))+1/e)/2}i.d(t,{A:()=>n});const n=function e(t,i,n){function s(e,s){var o,a,l=e[0],c=e[1],u=e[2],h=s[0],d=s[1],p=s[2],g=h-l,f=d-c,m=g*g+f*f;if(m<1e-12)a=Math.log(p/u)/t,o=function(e){return[l+e*g,c+e*f,u*Math.exp(t*e*a)]};else{var v=Math.sqrt(m),C=(p*p-u*u+n*m)/(2*u*i*v),y=(p*p-u*u-n*m)/(2*p*i*v),w=Math.log(Math.sqrt(C*C+1)-C),S=Math.log(Math.sqrt(y*y+1)-y);a=(S-w)/t,o=function(e){var n,s=e*a,o=r(w),h=u/(i*v)*(o*(n=t*s+w,((n=Math.exp(2*n))-1)/(n+1))-function(e){return((e=Math.exp(e))-1/e)/2}(w));return[l+h*g,c+h*f,u*o/r(t*s+w)]}}return o.duration=1e3*a*t/Math.SQRT2,o}return s.rho=function(t){var i=Math.max(.001,+t),r=i*i;return e(i,r,r*r)},s}(Math.SQRT2,2,4)},99269(e,t,i){"use strict";function r(e){return function(){return this.matches(e)}}function n(e){return function(t){return t.matches(e)}}i.d(t,{A:()=>r,j:()=>n})},39276(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(27683);function n(e){var t=e+="",i=t.indexOf(":");return i>=0&&"xmlns"!==(t=e.slice(0,i))&&(e=e.slice(i+1)),r.A.hasOwnProperty(t)?{space:r.A[t],local:e}:e}},27683(e,t,i){"use strict";i.d(t,{A:()=>n,g:()=>r});var r="http://www.w3.org/1999/xhtml";const n={svg:"http://www.w3.org/2000/svg",xhtml:r,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"}},60616(e,t,i){"use strict";function r(e,t){if(e=function(e){let t;for(;t=e.sourceEvent;)e=t;return e}(e),void 0===t&&(t=e.currentTarget),t){var i=t.ownerSVGElement||t;if(i.createSVGPoint){var r=i.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,[(r=r.matrixTransform(t.getScreenCTM().inverse())).x,r.y]}if(t.getBoundingClientRect){var n=t.getBoundingClientRect();return[e.clientX-n.left-t.clientLeft,e.clientY-n.top-t.clientTop]}}return[e.pageX,e.pageY]}i.d(t,{A:()=>r})},6063(e,t,i){"use strict";i.d(t,{A:()=>n});var r=i(64155);function n(e){return"string"==typeof e?new r.LN([[document.querySelector(e)]],[document.documentElement]):new r.LN([[e]],r.zr)}},64155(e,t,i){"use strict";i.d(t,{LN:()=>se,Ay:()=>ae,zr:()=>ne});var r=i(68166),n=i(54355);var s=i(99269),o=Array.prototype.find;function a(){return this.firstElementChild}var l=Array.prototype.filter;function c(){return Array.from(this.children)}function u(e){return new Array(e.length)}function h(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}function d(e,t,i,r,n,s){for(var o,a=0,l=t.length,c=s.length;a<c;++a)(o=t[a])?(o.__data__=s[a],r[a]=o):i[a]=new h(e,s[a]);for(;a<l;++a)(o=t[a])&&(n[a]=o)}function p(e,t,i,r,n,s,o){var a,l,c,u=new Map,d=t.length,p=s.length,g=new Array(d);for(a=0;a<d;++a)(l=t[a])&&(g[a]=c=o.call(l,l.__data__,a,t)+"",u.has(c)?n[a]=l:u.set(c,l));for(a=0;a<p;++a)c=o.call(e,s[a],a,s)+"",(l=u.get(c))?(r[a]=l,l.__data__=s[a],u.delete(c)):i[a]=new h(e,s[a]);for(a=0;a<d;++a)(l=t[a])&&u.get(g[a])===l&&(n[a]=l)}function g(e){return e.__data__}function f(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function m(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}h.prototype={constructor:h,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};var v=i(39276);function C(e){return function(){this.removeAttribute(e)}}function y(e){return function(){this.removeAttributeNS(e.space,e.local)}}function w(e,t){return function(){this.setAttribute(e,t)}}function S(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function b(e,t){return function(){var i=t.apply(this,arguments);null==i?this.removeAttribute(e):this.setAttribute(e,i)}}function E(e,t){return function(){var i=t.apply(this,arguments);null==i?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,i)}}var A=i(37915);function T(e){return function(){delete this[e]}}function M(e,t){return function(){this[e]=t}}function R(e,t){return function(){var i=t.apply(this,arguments);null==i?delete this[e]:this[e]=i}}function _(e){return e.trim().split(/^|\s+/)}function P(e){return e.classList||new x(e)}function x(e){this._node=e,this._names=_(e.getAttribute("class")||"")}function D(e,t){for(var i=P(e),r=-1,n=t.length;++r<n;)i.add(t[r])}function I(e,t){for(var i=P(e),r=-1,n=t.length;++r<n;)i.remove(t[r])}function L(e){return function(){D(this,e)}}function N(e){return function(){I(this,e)}}function O(e,t){return function(){(t.apply(this,arguments)?D:I)(this,e)}}function F(){this.textContent=""}function k(e){return function(){this.textContent=e}}function G(e){return function(){var t=e.apply(this,arguments);this.textContent=null==t?"":t}}function V(){this.innerHTML=""}function H(e){return function(){this.innerHTML=e}}function B(e){return function(){var t=e.apply(this,arguments);this.innerHTML=null==t?"":t}}function z(){this.nextSibling&&this.parentNode.appendChild(this)}function U(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}x.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};var W=i(27683);function j(e){return function(){var t=this.ownerDocument,i=this.namespaceURI;return i===W.g&&t.documentElement.namespaceURI===W.g?t.createElement(e):t.createElementNS(i,e)}}function K(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function $(e){var t=(0,v.A)(e);return(t.local?K:j)(t)}function q(){return null}function Y(){var e=this.parentNode;e&&e.removeChild(this)}function Q(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function X(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function Z(e){return function(){var t=this.__on;if(t){for(var i,r=0,n=-1,s=t.length;r<s;++r)i=t[r],e.type&&i.type!==e.type||i.name!==e.name?t[++n]=i:this.removeEventListener(i.type,i.listener,i.options);++n?t.length=n:delete this.__on}}}function J(e,t,i){return function(){var r,n=this.__on,s=function(e){return function(t){e.call(this,t,this.__data__)}}(t);if(n)for(var o=0,a=n.length;o<a;++o)if((r=n[o]).type===e.type&&r.name===e.name)return this.removeEventListener(r.type,r.listener,r.options),this.addEventListener(r.type,r.listener=s,r.options=i),void(r.value=t);this.addEventListener(e.type,s,i),r={type:e.type,name:e.name,value:t,listener:s,options:i},n?n.push(r):this.__on=[r]}}var ee=i(46515);function te(e,t,i){var r=(0,ee.A)(e),n=r.CustomEvent;"function"==typeof n?n=new n(t,i):(n=r.document.createEvent("Event"),i?(n.initEvent(t,i.bubbles,i.cancelable),n.detail=i.detail):n.initEvent(t,!1,!1)),e.dispatchEvent(n)}function ie(e,t){return function(){return te(this,e,t)}}function re(e,t){return function(){return te(this,e,t.apply(this,arguments))}}var ne=[null];function se(e,t){this._groups=e,this._parents=t}function oe(){return new se([[document.documentElement]],ne)}se.prototype=oe.prototype={constructor:se,select:function(e){"function"!=typeof e&&(e=(0,r.A)(e));for(var t=this._groups,i=t.length,n=new Array(i),s=0;s<i;++s)for(var o,a,l=t[s],c=l.length,u=n[s]=new Array(c),h=0;h<c;++h)(o=l[h])&&(a=e.call(o,o.__data__,h,l))&&("__data__"in o&&(a.__data__=o.__data__),u[h]=a);return new se(n,this._parents)},selectAll:function(e){e="function"==typeof e?function(e){return function(){return null==(t=e.apply(this,arguments))?[]:Array.isArray(t)?t:Array.from(t);var t}}(e):(0,n.A)(e);for(var t=this._groups,i=t.length,r=[],s=[],o=0;o<i;++o)for(var a,l=t[o],c=l.length,u=0;u<c;++u)(a=l[u])&&(r.push(e.call(a,a.__data__,u,l)),s.push(a));return new se(r,s)},selectChild:function(e){return this.select(null==e?a:function(e){return function(){return o.call(this.children,e)}}("function"==typeof e?e:(0,s.j)(e)))},selectChildren:function(e){return this.selectAll(null==e?c:function(e){return function(){return l.call(this.children,e)}}("function"==typeof e?e:(0,s.j)(e)))},filter:function(e){"function"!=typeof e&&(e=(0,s.A)(e));for(var t=this._groups,i=t.length,r=new Array(i),n=0;n<i;++n)for(var o,a=t[n],l=a.length,c=r[n]=[],u=0;u<l;++u)(o=a[u])&&e.call(o,o.__data__,u,a)&&c.push(o);return new se(r,this._parents)},data:function(e,t){if(!arguments.length)return Array.from(this,g);var i,r=t?p:d,n=this._parents,s=this._groups;"function"!=typeof e&&(i=e,e=function(){return i});for(var o=s.length,a=new Array(o),l=new Array(o),c=new Array(o),u=0;u<o;++u){var h=n[u],m=s[u],v=m.length,C=f(e.call(h,h&&h.__data__,u,n)),y=C.length,w=l[u]=new Array(y),S=a[u]=new Array(y);r(h,m,w,S,c[u]=new Array(v),C,t);for(var b,E,A=0,T=0;A<y;++A)if(b=w[A]){for(A>=T&&(T=A+1);!(E=S[T])&&++T<y;);b._next=E||null}}return(a=new se(a,n))._enter=l,a._exit=c,a},enter:function(){return new se(this._enter||this._groups.map(u),this._parents)},exit:function(){return new se(this._exit||this._groups.map(u),this._parents)},join:function(e,t,i){var r=this.enter(),n=this,s=this.exit();return"function"==typeof e?(r=e(r))&&(r=r.selection()):r=r.append(e+""),null!=t&&(n=t(n))&&(n=n.selection()),null==i?s.remove():i(s),r&&n?r.merge(n).order():n},merge:function(e){for(var t=e.selection?e.selection():e,i=this._groups,r=t._groups,n=i.length,s=r.length,o=Math.min(n,s),a=new Array(n),l=0;l<o;++l)for(var c,u=i[l],h=r[l],d=u.length,p=a[l]=new Array(d),g=0;g<d;++g)(c=u[g]||h[g])&&(p[g]=c);for(;l<n;++l)a[l]=i[l];return new se(a,this._parents)},selection:function(){return this},order:function(){for(var e=this._groups,t=-1,i=e.length;++t<i;)for(var r,n=e[t],s=n.length-1,o=n[s];--s>=0;)(r=n[s])&&(o&&4^r.compareDocumentPosition(o)&&o.parentNode.insertBefore(r,o),o=r);return this},sort:function(e){function t(t,i){return t&&i?e(t.__data__,i.__data__):!t-!i}e||(e=m);for(var i=this._groups,r=i.length,n=new Array(r),s=0;s<r;++s){for(var o,a=i[s],l=a.length,c=n[s]=new Array(l),u=0;u<l;++u)(o=a[u])&&(c[u]=o);c.sort(t)}return new se(n,this._parents).order()},call:function(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var e=this._groups,t=0,i=e.length;t<i;++t)for(var r=e[t],n=0,s=r.length;n<s;++n){var o=r[n];if(o)return o}return null},size:function(){let e=0;for(const t of this)++e;return e},empty:function(){return!this.node()},each:function(e){for(var t=this._groups,i=0,r=t.length;i<r;++i)for(var n,s=t[i],o=0,a=s.length;o<a;++o)(n=s[o])&&e.call(n,n.__data__,o,s);return this},attr:function(e,t){var i=(0,v.A)(e);if(arguments.length<2){var r=this.node();return i.local?r.getAttributeNS(i.space,i.local):r.getAttribute(i)}return this.each((null==t?i.local?y:C:"function"==typeof t?i.local?E:b:i.local?S:w)(i,t))},style:A.A,property:function(e,t){return arguments.length>1?this.each((null==t?T:"function"==typeof t?R:M)(e,t)):this.node()[e]},classed:function(e,t){var i=_(e+"");if(arguments.length<2){for(var r=P(this.node()),n=-1,s=i.length;++n<s;)if(!r.contains(i[n]))return!1;return!0}return this.each(("function"==typeof t?O:t?L:N)(i,t))},text:function(e){return arguments.length?this.each(null==e?F:("function"==typeof e?G:k)(e)):this.node().textContent},html:function(e){return arguments.length?this.each(null==e?V:("function"==typeof e?B:H)(e)):this.node().innerHTML},raise:function(){return this.each(z)},lower:function(){return this.each(U)},append:function(e){var t="function"==typeof e?e:$(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})},insert:function(e,t){var i="function"==typeof e?e:$(e),n=null==t?q:"function"==typeof t?t:(0,r.A)(t);return this.select(function(){return this.insertBefore(i.apply(this,arguments),n.apply(this,arguments)||null)})},remove:function(){return this.each(Y)},clone:function(e){return this.select(e?X:Q)},datum:function(e){return arguments.length?this.property("__data__",e):this.node().__data__},on:function(e,t,i){var r,n,s=function(e){return e.trim().split(/^|\s+/).map(function(e){var t="",i=e.indexOf(".");return i>=0&&(t=e.slice(i+1),e=e.slice(0,i)),{type:e,name:t}})}(e+""),o=s.length;if(!(arguments.length<2)){for(a=t?J:Z,r=0;r<o;++r)this.each(a(s[r],t,i));return this}var a=this.node().__on;if(a)for(var l,c=0,u=a.length;c<u;++c)for(r=0,l=a[c];r<o;++r)if((n=s[r]).type===l.type&&n.name===l.name)return l.value},dispatch:function(e,t){return this.each(("function"==typeof t?re:ie)(e,t))},[Symbol.iterator]:function*(){for(var e=this._groups,t=0,i=e.length;t<i;++t)for(var r,n=e[t],s=0,o=n.length;s<o;++s)(r=n[s])&&(yield r)}};const ae=oe},37915(e,t,i){"use strict";i.d(t,{A:()=>a,j:()=>l});var r=i(46515);function n(e){return function(){this.style.removeProperty(e)}}function s(e,t,i){return function(){this.style.setProperty(e,t,i)}}function o(e,t,i){return function(){var r=t.apply(this,arguments);null==r?this.style.removeProperty(e):this.style.setProperty(e,r,i)}}function a(e,t,i){return arguments.length>1?this.each((null==t?n:"function"==typeof t?o:s)(e,t,null==i?"":i)):l(this.node(),e)}function l(e,t){return e.style.getPropertyValue(t)||(0,r.A)(e).getComputedStyle(e,null).getPropertyValue(t)}},68166(e,t,i){"use strict";function r(){}function n(e){return null==e?r:function(){return this.querySelector(e)}}i.d(t,{A:()=>n})},54355(e,t,i){"use strict";function r(){return[]}function n(e){return null==e?r:function(){return this.querySelectorAll(e)}}i.d(t,{A:()=>n})},46515(e,t,i){"use strict";function r(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}i.d(t,{A:()=>r})},17076(e,t,i){"use strict";i.d(t,{s_:()=>Le,GS:()=>Ee,_V:()=>Ae});var r,n,s=i(54560),o=i(37572),a=i(96785),l=i(6063),c=i(60616),u=i(64155),h=0,d=0,p=0,g=0,f=0,m=0,v="object"==typeof performance&&performance.now?performance:Date,C="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function y(){return f||(C(w),f=v.now()+m)}function w(){f=0}function S(){this._call=this._time=this._next=null}function b(e,t,i){var r=new S;return r.restart(e,t,i),r}function E(){f=(g=v.now())+m,h=d=0;try{!function(){y(),++h;for(var e,t=r;t;)(e=f-t._time)>=0&&t._call.call(void 0,e),t=t._next;--h}()}finally{h=0,function(){for(var e,t,i=r,s=1/0;i;)i._call?(s>i._time&&(s=i._time),e=i,i=i._next):(t=i._next,i._next=null,i=e?e._next=t:r=t);n=e,T(s)}(),f=0}}function A(){var e=v.now(),t=e-g;t>1e3&&(m-=t,g=e)}function T(e){h||(d&&(d=clearTimeout(d)),e-f>24?(e<1/0&&(d=setTimeout(E,e-v.now()-m)),p&&(p=clearInterval(p))):(p||(g=v.now(),p=setInterval(A,1e3)),h=1,C(E)))}function M(e,t,i){var r=new S;return t=null==t?0:+t,r.restart(i=>{r.stop(),e(i+t)},t,i),r}S.prototype=b.prototype={constructor:S,restart:function(e,t,i){if("function"!=typeof e)throw new TypeError("callback is not a function");i=(null==i?y():+i)+(null==t?0:+t),this._next||n===this||(n?n._next=this:r=this,n=this),this._call=e,this._time=i,T()},stop:function(){this._call&&(this._call=null,this._time=1/0,T())}};var R=(0,s.A)("start","end","cancel","interrupt"),_=[];function P(e,t,i,r,n,s){var o=e.__transition;if(o){if(i in o)return}else e.__transition={};!function(e,t,i){var r,n=e.__transition;function s(l){var c,u,h,d;if(1!==i.state)return a();for(c in n)if((d=n[c]).name===i.name){if(3===d.state)return M(s);4===d.state?(d.state=6,d.timer.stop(),d.on.call("interrupt",e,e.__data__,d.index,d.group),delete n[c]):+c<t&&(d.state=6,d.timer.stop(),d.on.call("cancel",e,e.__data__,d.index,d.group),delete n[c])}if(M(function(){3===i.state&&(i.state=4,i.timer.restart(o,i.delay,i.time),o(l))}),i.state=2,i.on.call("start",e,e.__data__,i.index,i.group),2===i.state){for(i.state=3,r=new Array(h=i.tween.length),c=0,u=-1;c<h;++c)(d=i.tween[c].value.call(e,e.__data__,i.index,i.group))&&(r[++u]=d);r.length=u+1}}function o(t){for(var n=t<i.duration?i.ease.call(null,t/i.duration):(i.timer.restart(a),i.state=5,1),s=-1,o=r.length;++s<o;)r[s].call(e,n);5===i.state&&(i.on.call("end",e,e.__data__,i.index,i.group),a())}function a(){for(var r in i.state=6,i.timer.stop(),delete n[t],n)return;delete e.__transition}n[t]=i,i.timer=b(function(e){i.state=1,i.timer.restart(s,i.delay,i.time),i.delay<=e&&s(e-i.delay)},0,i.time)}(e,i,{name:t,index:r,group:n,on:R,tween:_,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:0})}function x(e,t){var i=I(e,t);if(i.state>0)throw new Error("too late; already scheduled");return i}function D(e,t){var i=I(e,t);if(i.state>3)throw new Error("too late; already running");return i}function I(e,t){var i=e.__transition;if(!i||!(i=i[t]))throw new Error("transition not found");return i}function L(e,t){var i,r,n,s=e.__transition,o=!0;if(s){for(n in t=null==t?null:t+"",s)(i=s[n]).name===t?(r=i.state>2&&i.state<5,i.state=6,i.timer.stop(),i.on.call(r?"interrupt":"cancel",e,e.__data__,i.index,i.group),delete s[n]):o=!1;o&&delete e.__transition}}var N,O=i(77419),F=180/Math.PI,k={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function G(e,t,i,r,n,s){var o,a,l;return(o=Math.sqrt(e*e+t*t))&&(e/=o,t/=o),(l=e*i+t*r)&&(i-=e*l,r-=t*l),(a=Math.sqrt(i*i+r*r))&&(i/=a,r/=a,l/=a),e*r<t*i&&(e=-e,t=-t,l=-l,o=-o),{translateX:n,translateY:s,rotate:Math.atan2(t,e)*F,skewX:Math.atan(l)*F,scaleX:o,scaleY:a}}function V(e,t,i,r){function n(e){return e.length?e.pop()+" ":""}return function(s,o){var a=[],l=[];return s=e(s),o=e(o),function(e,r,n,s,o,a){if(e!==n||r!==s){var l=o.push("translate(",null,t,null,i);a.push({i:l-4,x:(0,O.A)(e,n)},{i:l-2,x:(0,O.A)(r,s)})}else(n||s)&&o.push("translate("+n+t+s+i)}(s.translateX,s.translateY,o.translateX,o.translateY,a,l),function(e,t,i,s){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),s.push({i:i.push(n(i)+"rotate(",null,r)-2,x:(0,O.A)(e,t)})):t&&i.push(n(i)+"rotate("+t+r)}(s.rotate,o.rotate,a,l),function(e,t,i,s){e!==t?s.push({i:i.push(n(i)+"skewX(",null,r)-2,x:(0,O.A)(e,t)}):t&&i.push(n(i)+"skewX("+t+r)}(s.skewX,o.skewX,a,l),function(e,t,i,r,s,o){if(e!==i||t!==r){var a=s.push(n(s)+"scale(",null,",",null,")");o.push({i:a-4,x:(0,O.A)(e,i)},{i:a-2,x:(0,O.A)(t,r)})}else 1===i&&1===r||s.push(n(s)+"scale("+i+","+r+")")}(s.scaleX,s.scaleY,o.scaleX,o.scaleY,a,l),s=o=null,function(e){for(var t,i=-1,r=l.length;++i<r;)a[(t=l[i]).i]=t.x(e);return a.join("")}}}var H=V(function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?k:G(t.a,t.b,t.c,t.d,t.e,t.f)},"px, ","px)","deg)"),B=V(function(e){return null==e?k:(N||(N=document.createElementNS("http://www.w3.org/2000/svg","g")),N.setAttribute("transform",e),(e=N.transform.baseVal.consolidate())?G((e=e.matrix).a,e.b,e.c,e.d,e.e,e.f):k)},", ",")",")"),z=i(39276);function U(e,t){var i,r;return function(){var n=D(this,e),s=n.tween;if(s!==i)for(var o=0,a=(r=i=s).length;o<a;++o)if(r[o].name===t){(r=r.slice()).splice(o,1);break}n.tween=r}}function W(e,t,i){var r,n;if("function"!=typeof i)throw new Error;return function(){var s=D(this,e),o=s.tween;if(o!==r){n=(r=o).slice();for(var a={name:t,value:i},l=0,c=n.length;l<c;++l)if(n[l].name===t){n[l]=a;break}l===c&&n.push(a)}s.tween=n}}function j(e,t,i){var r=e._id;return e.each(function(){var e=D(this,r);(e.value||(e.value={}))[t]=i.apply(this,arguments)}),function(e){return I(e,r).value[t]}}var K=i(52413),$=i(92795),q=i(20835);function Y(e,t){var i;return("number"==typeof t?O.A:t instanceof K.Ay?$.Ay:(i=(0,K.Ay)(t))?(t=i,$.Ay):q.A)(e,t)}function Q(e){return function(){this.removeAttribute(e)}}function X(e){return function(){this.removeAttributeNS(e.space,e.local)}}function Z(e,t,i){var r,n,s=i+"";return function(){var o=this.getAttribute(e);return o===s?null:o===r?n:n=t(r=o,i)}}function J(e,t,i){var r,n,s=i+"";return function(){var o=this.getAttributeNS(e.space,e.local);return o===s?null:o===r?n:n=t(r=o,i)}}function ee(e,t,i){var r,n,s;return function(){var o,a,l=i(this);if(null!=l)return(o=this.getAttribute(e))===(a=l+"")?null:o===r&&a===n?s:(n=a,s=t(r=o,l));this.removeAttribute(e)}}function te(e,t,i){var r,n,s;return function(){var o,a,l=i(this);if(null!=l)return(o=this.getAttributeNS(e.space,e.local))===(a=l+"")?null:o===r&&a===n?s:(n=a,s=t(r=o,l));this.removeAttributeNS(e.space,e.local)}}function ie(e,t){var i,r;function n(){var n=t.apply(this,arguments);return n!==r&&(i=(r=n)&&function(e,t){return function(i){this.setAttributeNS(e.space,e.local,t.call(this,i))}}(e,n)),i}return n._value=t,n}function re(e,t){var i,r;function n(){var n=t.apply(this,arguments);return n!==r&&(i=(r=n)&&function(e,t){return function(i){this.setAttribute(e,t.call(this,i))}}(e,n)),i}return n._value=t,n}function ne(e,t){return function(){x(this,e).delay=+t.apply(this,arguments)}}function se(e,t){return t=+t,function(){x(this,e).delay=t}}function oe(e,t){return function(){D(this,e).duration=+t.apply(this,arguments)}}function ae(e,t){return t=+t,function(){D(this,e).duration=t}}var le=i(99269),ce=i(68166),ue=i(54355),he=u.Ay.prototype.constructor,de=i(37915);function pe(e){return function(){this.style.removeProperty(e)}}var ge=0;function fe(e,t,i,r){this._groups=e,this._parents=t,this._name=i,this._id=r}function me(){return++ge}var ve=u.Ay.prototype;fe.prototype=function(e){return(0,u.Ay)().transition(e)}.prototype={constructor:fe,select:function(e){var t=this._name,i=this._id;"function"!=typeof e&&(e=(0,ce.A)(e));for(var r=this._groups,n=r.length,s=new Array(n),o=0;o<n;++o)for(var a,l,c=r[o],u=c.length,h=s[o]=new Array(u),d=0;d<u;++d)(a=c[d])&&(l=e.call(a,a.__data__,d,c))&&("__data__"in a&&(l.__data__=a.__data__),h[d]=l,P(h[d],t,i,d,h,I(a,i)));return new fe(s,this._parents,t,i)},selectAll:function(e){var t=this._name,i=this._id;"function"!=typeof e&&(e=(0,ue.A)(e));for(var r=this._groups,n=r.length,s=[],o=[],a=0;a<n;++a)for(var l,c=r[a],u=c.length,h=0;h<u;++h)if(l=c[h]){for(var d,p=e.call(l,l.__data__,h,c),g=I(l,i),f=0,m=p.length;f<m;++f)(d=p[f])&&P(d,t,i,f,p,g);s.push(p),o.push(l)}return new fe(s,o,t,i)},selectChild:ve.selectChild,selectChildren:ve.selectChildren,filter:function(e){"function"!=typeof e&&(e=(0,le.A)(e));for(var t=this._groups,i=t.length,r=new Array(i),n=0;n<i;++n)for(var s,o=t[n],a=o.length,l=r[n]=[],c=0;c<a;++c)(s=o[c])&&e.call(s,s.__data__,c,o)&&l.push(s);return new fe(r,this._parents,this._name,this._id)},merge:function(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,i=e._groups,r=t.length,n=i.length,s=Math.min(r,n),o=new Array(r),a=0;a<s;++a)for(var l,c=t[a],u=i[a],h=c.length,d=o[a]=new Array(h),p=0;p<h;++p)(l=c[p]||u[p])&&(d[p]=l);for(;a<r;++a)o[a]=t[a];return new fe(o,this._parents,this._name,this._id)},selection:function(){return new he(this._groups,this._parents)},transition:function(){for(var e=this._name,t=this._id,i=me(),r=this._groups,n=r.length,s=0;s<n;++s)for(var o,a=r[s],l=a.length,c=0;c<l;++c)if(o=a[c]){var u=I(o,t);P(o,e,i,c,a,{time:u.time+u.delay+u.duration,delay:0,duration:u.duration,ease:u.ease})}return new fe(r,this._parents,e,i)},call:ve.call,nodes:ve.nodes,node:ve.node,size:ve.size,empty:ve.empty,each:ve.each,on:function(e,t){var i=this._id;return arguments.length<2?I(this.node(),i).on.on(e):this.each(function(e,t,i){var r,n,s=function(e){return(e+"").trim().split(/^|\s+/).every(function(e){var t=e.indexOf(".");return t>=0&&(e=e.slice(0,t)),!e||"start"===e})}(t)?x:D;return function(){var o=s(this,e),a=o.on;a!==r&&(n=(r=a).copy()).on(t,i),o.on=n}}(i,e,t))},attr:function(e,t){var i=(0,z.A)(e),r="transform"===i?B:Y;return this.attrTween(e,"function"==typeof t?(i.local?te:ee)(i,r,j(this,"attr."+e,t)):null==t?(i.local?X:Q)(i):(i.local?J:Z)(i,r,t))},attrTween:function(e,t){var i="attr."+e;if(arguments.length<2)return(i=this.tween(i))&&i._value;if(null==t)return this.tween(i,null);if("function"!=typeof t)throw new Error;var r=(0,z.A)(e);return this.tween(i,(r.local?ie:re)(r,t))},style:function(e,t,i){var r="transform"==(e+="")?H:Y;return null==t?this.styleTween(e,function(e,t){var i,r,n;return function(){var s=(0,de.j)(this,e),o=(this.style.removeProperty(e),(0,de.j)(this,e));return s===o?null:s===i&&o===r?n:n=t(i=s,r=o)}}(e,r)).on("end.style."+e,pe(e)):"function"==typeof t?this.styleTween(e,function(e,t,i){var r,n,s;return function(){var o=(0,de.j)(this,e),a=i(this),l=a+"";return null==a&&(this.style.removeProperty(e),l=a=(0,de.j)(this,e)),o===l?null:o===r&&l===n?s:(n=l,s=t(r=o,a))}}(e,r,j(this,"style."+e,t))).each(function(e,t){var i,r,n,s,o="style."+t,a="end."+o;return function(){var l=D(this,e),c=l.on,u=null==l.value[o]?s||(s=pe(t)):void 0;c===i&&n===u||(r=(i=c).copy()).on(a,n=u),l.on=r}}(this._id,e)):this.styleTween(e,function(e,t,i){var r,n,s=i+"";return function(){var o=(0,de.j)(this,e);return o===s?null:o===r?n:n=t(r=o,i)}}(e,r,t),i).on("end.style."+e,null)},styleTween:function(e,t,i){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(null==t)return this.tween(r,null);if("function"!=typeof t)throw new Error;return this.tween(r,function(e,t,i){var r,n;function s(){var s=t.apply(this,arguments);return s!==n&&(r=(n=s)&&function(e,t,i){return function(r){this.style.setProperty(e,t.call(this,r),i)}}(e,s,i)),r}return s._value=t,s}(e,t,null==i?"":i))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this);this.textContent=null==t?"":t}}(j(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(null==e)return this.tween(t,null);if("function"!=typeof e)throw new Error;return this.tween(t,function(e){var t,i;function r(){var r=e.apply(this,arguments);return r!==i&&(t=(i=r)&&function(e){return function(t){this.textContent=e.call(this,t)}}(r)),t}return r._value=e,r}(e))},remove:function(){return this.on("end.remove",function(e){return function(){var t=this.parentNode;for(var i in this.__transition)if(+i!==e)return;t&&t.removeChild(this)}}(this._id))},tween:function(e,t){var i=this._id;if(e+="",arguments.length<2){for(var r,n=I(this.node(),i).tween,s=0,o=n.length;s<o;++s)if((r=n[s]).name===e)return r.value;return null}return this.each((null==t?U:W)(i,e,t))},delay:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?ne:se)(t,e)):I(this.node(),t).delay},duration:function(e){var t=this._id;return arguments.length?this.each(("function"==typeof e?oe:ae)(t,e)):I(this.node(),t).duration},ease:function(e){var t=this._id;return arguments.length?this.each(function(e,t){if("function"!=typeof t)throw new Error;return function(){D(this,e).ease=t}}(t,e)):I(this.node(),t).ease},easeVarying:function(e){if("function"!=typeof e)throw new Error;return this.each(function(e,t){return function(){var i=t.apply(this,arguments);if("function"!=typeof i)throw new Error;D(this,e).ease=i}}(this._id,e))},end:function(){var e,t,i=this,r=i._id,n=i.size();return new Promise(function(s,o){var a={value:o},l={value:function(){0===--n&&s()}};i.each(function(){var i=D(this,r),n=i.on;n!==e&&((t=(e=n).copy())._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),i.on=t}),0===n&&s()})},[Symbol.iterator]:ve[Symbol.iterator]};var Ce={time:null,delay:0,duration:250,ease:function(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}};function ye(e,t){for(var i;!(i=e.__transition)||!(i=i[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return i}u.Ay.prototype.interrupt=function(e){return this.each(function(){L(this,e)})},u.Ay.prototype.transition=function(e){var t,i;e instanceof fe?(t=e._id,e=e._name):(t=me(),(i=Ce).time=y(),e=null==e?null:e+"");for(var r=this._groups,n=r.length,s=0;s<n;++s)for(var o,a=r[s],l=a.length,c=0;c<l;++c)(o=a[c])&&P(o,e,t,c,a,i||ye(o,t));return new fe(r,this._parents,e,t)};const we=e=>()=>e;function Se(e,{sourceEvent:t,target:i,transform:r,dispatch:n}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:i,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:n}})}function be(e,t,i){this.k=e,this.x=t,this.y=i}be.prototype={constructor:be,scale:function(e){return 1===e?this:new be(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new be(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Ee=new be(1,0,0);function Ae(e){for(;!e.__zoom;)if(!(e=e.parentNode))return Ee;return e.__zoom}function Te(e){e.stopImmediatePropagation()}function Me(e){e.preventDefault(),e.stopImmediatePropagation()}function Re(e){return!(e.ctrlKey&&"wheel"!==e.type||e.button)}function _e(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e).hasAttribute("viewBox")?[[(e=e.viewBox.baseVal).x,e.y],[e.x+e.width,e.y+e.height]]:[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]:[[0,0],[e.clientWidth,e.clientHeight]]}function Pe(){return this.__zoom||Ee}function xe(e){return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function De(){return navigator.maxTouchPoints||"ontouchstart"in this}function Ie(e,t,i){var r=e.invertX(t[0][0])-i[0][0],n=e.invertX(t[1][0])-i[1][0],s=e.invertY(t[0][1])-i[0][1],o=e.invertY(t[1][1])-i[1][1];return e.translate(n>r?(r+n)/2:Math.min(0,r)||Math.max(0,n),o>s?(s+o)/2:Math.min(0,s)||Math.max(0,o))}function Le(){var e,t,i,r=Re,n=_e,u=Ie,h=xe,d=De,p=[0,1/0],g=[[-1/0,-1/0],[1/0,1/0]],f=250,m=a.A,v=(0,s.A)("start","zoom","end"),C=0,y=10;function w(e){e.property("__zoom",Pe).on("wheel.zoom",R,{passive:!1}).on("mousedown.zoom",_).on("dblclick.zoom",P).filter(d).on("touchstart.zoom",x).on("touchmove.zoom",D).on("touchend.zoom touchcancel.zoom",I).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function S(e,t){return(t=Math.max(p[0],Math.min(p[1],t)))===e.k?e:new be(t,e.x,e.y)}function b(e,t,i){var r=t[0]-i[0]*e.k,n=t[1]-i[1]*e.k;return r===e.x&&n===e.y?e:new be(e.k,r,n)}function E(e){return[(+e[0][0]+ +e[1][0])/2,(+e[0][1]+ +e[1][1])/2]}function A(e,t,i,r){e.on("start.zoom",function(){T(this,arguments).event(r).start()}).on("interrupt.zoom end.zoom",function(){T(this,arguments).event(r).end()}).tween("zoom",function(){var e=this,s=arguments,o=T(e,s).event(r),a=n.apply(e,s),l=null==i?E(a):"function"==typeof i?i.apply(e,s):i,c=Math.max(a[1][0]-a[0][0],a[1][1]-a[0][1]),u=e.__zoom,h="function"==typeof t?t.apply(e,s):t,d=m(u.invert(l).concat(c/u.k),h.invert(l).concat(c/h.k));return function(e){if(1===e)e=h;else{var t=d(e),i=c/t[2];e=new be(i,l[0]-t[0]*i,l[1]-t[1]*i)}o.zoom(null,e)}})}function T(e,t,i){return!i&&e.__zooming||new M(e,t)}function M(e,t){this.that=e,this.args=t,this.active=0,this.sourceEvent=null,this.extent=n.apply(e,t),this.taps=0}function R(e,...t){if(r.apply(this,arguments)){var i=T(this,t).event(e),n=this.__zoom,s=Math.max(p[0],Math.min(p[1],n.k*Math.pow(2,h.apply(this,arguments)))),o=(0,c.A)(e);if(i.wheel)i.mouse[0][0]===o[0]&&i.mouse[0][1]===o[1]||(i.mouse[1]=n.invert(i.mouse[0]=o)),clearTimeout(i.wheel);else{if(n.k===s)return;i.mouse=[o,n.invert(o)],L(this),i.start()}Me(e),i.wheel=setTimeout(function(){i.wheel=null,i.end()},150),i.zoom("mouse",u(b(S(n,s),i.mouse[0],i.mouse[1]),i.extent,g))}}function _(e,...t){if(!i&&r.apply(this,arguments)){var n=e.currentTarget,s=T(this,t,!0).event(e),a=(0,l.A)(e.view).on("mousemove.zoom",function(e){if(Me(e),!s.moved){var t=e.clientX-d,i=e.clientY-p;s.moved=t*t+i*i>C}s.event(e).zoom("mouse",u(b(s.that.__zoom,s.mouse[0]=(0,c.A)(e,n),s.mouse[1]),s.extent,g))},!0).on("mouseup.zoom",function(e){a.on("mousemove.zoom mouseup.zoom",null),(0,o.y)(e.view,s.moved),Me(e),s.event(e).end()},!0),h=(0,c.A)(e,n),d=e.clientX,p=e.clientY;(0,o.A)(e.view),Te(e),s.mouse=[h,this.__zoom.invert(h)],L(this),s.start()}}function P(e,...t){if(r.apply(this,arguments)){var i=this.__zoom,s=(0,c.A)(e.changedTouches?e.changedTouches[0]:e,this),o=i.invert(s),a=i.k*(e.shiftKey?.5:2),h=u(b(S(i,a),s,o),n.apply(this,t),g);Me(e),f>0?(0,l.A)(this).transition().duration(f).call(A,h,s,e):(0,l.A)(this).call(w.transform,h,s,e)}}function x(i,...n){if(r.apply(this,arguments)){var s,o,a,l,u=i.touches,h=u.length,d=T(this,n,i.changedTouches.length===h).event(i);for(Te(i),o=0;o<h;++o)a=u[o],l=[l=(0,c.A)(a,this),this.__zoom.invert(l),a.identifier],d.touch0?d.touch1||d.touch0[2]===l[2]||(d.touch1=l,d.taps=0):(d.touch0=l,s=!0,d.taps=1+!!e);e&&(e=clearTimeout(e)),s&&(d.taps<2&&(t=l[0],e=setTimeout(function(){e=null},500)),L(this),d.start())}}function D(e,...t){if(this.__zooming){var i,r,n,s,o=T(this,t).event(e),a=e.changedTouches,l=a.length;for(Me(e),i=0;i<l;++i)r=a[i],n=(0,c.A)(r,this),o.touch0&&o.touch0[2]===r.identifier?o.touch0[0]=n:o.touch1&&o.touch1[2]===r.identifier&&(o.touch1[0]=n);if(r=o.that.__zoom,o.touch1){var h=o.touch0[0],d=o.touch0[1],p=o.touch1[0],f=o.touch1[1],m=(m=p[0]-h[0])*m+(m=p[1]-h[1])*m,v=(v=f[0]-d[0])*v+(v=f[1]-d[1])*v;r=S(r,Math.sqrt(m/v)),n=[(h[0]+p[0])/2,(h[1]+p[1])/2],s=[(d[0]+f[0])/2,(d[1]+f[1])/2]}else{if(!o.touch0)return;n=o.touch0[0],s=o.touch0[1]}o.zoom("touch",u(b(r,n,s),o.extent,g))}}function I(e,...r){if(this.__zooming){var n,s,o=T(this,r).event(e),a=e.changedTouches,u=a.length;for(Te(e),i&&clearTimeout(i),i=setTimeout(function(){i=null},500),n=0;n<u;++n)s=a[n],o.touch0&&o.touch0[2]===s.identifier?delete o.touch0:o.touch1&&o.touch1[2]===s.identifier&&delete o.touch1;if(o.touch1&&!o.touch0&&(o.touch0=o.touch1,delete o.touch1),o.touch0)o.touch0[1]=this.__zoom.invert(o.touch0[0]);else if(o.end(),2===o.taps&&(s=(0,c.A)(s,this),Math.hypot(t[0]-s[0],t[1]-s[1])<y)){var h=(0,l.A)(this).on("dblclick.zoom");h&&h.apply(this,arguments)}}}return w.transform=function(e,t,i,r){var n=e.selection?e.selection():e;n.property("__zoom",Pe),e!==n?A(e,t,i,r):n.interrupt().each(function(){T(this,arguments).event(r).start().zoom(null,"function"==typeof t?t.apply(this,arguments):t).end()})},w.scaleBy=function(e,t,i,r){w.scaleTo(e,function(){return this.__zoom.k*("function"==typeof t?t.apply(this,arguments):t)},i,r)},w.scaleTo=function(e,t,i,r){w.transform(e,function(){var e=n.apply(this,arguments),r=this.__zoom,s=null==i?E(e):"function"==typeof i?i.apply(this,arguments):i,o=r.invert(s),a="function"==typeof t?t.apply(this,arguments):t;return u(b(S(r,a),s,o),e,g)},i,r)},w.translateBy=function(e,t,i,r){w.transform(e,function(){return u(this.__zoom.translate("function"==typeof t?t.apply(this,arguments):t,"function"==typeof i?i.apply(this,arguments):i),n.apply(this,arguments),g)},null,r)},w.translateTo=function(e,t,i,r,s){w.transform(e,function(){var e=n.apply(this,arguments),s=this.__zoom,o=null==r?E(e):"function"==typeof r?r.apply(this,arguments):r;return u(Ee.translate(o[0],o[1]).scale(s.k).translate("function"==typeof t?-t.apply(this,arguments):-t,"function"==typeof i?-i.apply(this,arguments):-i),e,g)},r,s)},M.prototype={event:function(e){return e&&(this.sourceEvent=e),this},start:function(){return 1===++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(e,t){return this.mouse&&"mouse"!==e&&(this.mouse[1]=t.invert(this.mouse[0])),this.touch0&&"touch"!==e&&(this.touch0[1]=t.invert(this.touch0[0])),this.touch1&&"touch"!==e&&(this.touch1[1]=t.invert(this.touch1[0])),this.that.__zoom=t,this.emit("zoom"),this},end:function(){return 0===--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(e){var t=(0,l.A)(this.that).datum();v.call(e,this.that,new Se(e,{sourceEvent:this.sourceEvent,target:w,type:e,transform:this.that.__zoom,dispatch:v}),t)}},w.wheelDelta=function(e){return arguments.length?(h="function"==typeof e?e:we(+e),w):h},w.filter=function(e){return arguments.length?(r="function"==typeof e?e:we(!!e),w):r},w.touchable=function(e){return arguments.length?(d="function"==typeof e?e:we(!!e),w):d},w.extent=function(e){return arguments.length?(n="function"==typeof e?e:we([[+e[0][0],+e[0][1]],[+e[1][0],+e[1][1]]]),w):n},w.scaleExtent=function(e){return arguments.length?(p[0]=+e[0],p[1]=+e[1],w):[p[0],p[1]]},w.translateExtent=function(e){return arguments.length?(g[0][0]=+e[0][0],g[1][0]=+e[1][0],g[0][1]=+e[0][1],g[1][1]=+e[1][1],w):[[g[0][0],g[0][1]],[g[1][0],g[1][1]]]},w.constrain=function(e){return arguments.length?(u=e,w):u},w.duration=function(e){return arguments.length?(f=+e,w):f},w.interpolate=function(e){return arguments.length?(m=e,w):m},w.on=function(){var e=v.on.apply(v,arguments);return e===v?w:e},w.clickDistance=function(e){return arguments.length?(C=(e=+e)*e,w):Math.sqrt(C)},w.tapDistance=function(e){return arguments.length?(y=+e,w):y},w}Ae.prototype=be.prototype},67543(e,t,i){"use strict";i.d(t,{s:()=>n});const r=document.createElement("i");function n(e){const t="&"+e+";";r.innerHTML=t;const i=r.textContent;return(59!==i.charCodeAt(i.length-1)||"semi"===e)&&i!==t&&i}},40562(e,t,i){"use strict";function r(){}function n(){}i.d(t,{HB:()=>n,ok:()=>r})},36464(e,t,i){"use strict";function r(e){if("string"!=typeof e)throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}i.d(t,{A:()=>r})},10150(e,t,i){"use strict";i.d(t,{UU:()=>o});const r=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,n=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,s={};function o(e,t){return((t||s).jsx?n:r).test(e)}},94531(e,t,i){"use strict";i.d(t,{AH:()=>d});let r={data:""},n=e=>{if("object"==typeof window){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||r},s=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,o=/\/\*[^]*?\*\/|  +/g,a=/\n+/g,l=(e,t)=>{let i="",r="",n="";for(let s in e){let o=e[s];"@"==s[0]?"i"==s[1]?i=s+" "+o+";":r+="f"==s[1]?l(o,s):s+"{"+l(o,"k"==s[1]?"":t)+"}":"object"==typeof o?r+=l(o,t?t.replace(/([^,])+/g,e=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):s):null!=o&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),n+=l.p?l.p(s,o):s+":"+o+";")}return i+(t&&n?t+"{"+n+"}":n)+r},c={},u=e=>{if("object"==typeof e){let t="";for(let i in e)t+=i+u(e[i]);return t}return e},h=(e,t,i,r,n)=>{let h=u(e),d=c[h]||(c[h]=(e=>{let t=0,i=11;for(;t<e.length;)i=101*i+e.charCodeAt(t++)>>>0;return"go"+i})(h));if(!c[d]){let t=h!==e?e:(e=>{let t,i,r=[{}];for(;t=s.exec(e.replace(o,""));)t[4]?r.shift():t[3]?(i=t[3].replace(a," ").trim(),r.unshift(r[0][i]=r[0][i]||{})):r[0][t[1]]=t[2].replace(a," ").trim();return r[0]})(e);c[d]=l(n?{["@keyframes "+d]:t}:t,i?"":"."+d)}let p=i&&c.g?c.g:null;return i&&(c.g=c[d]),((e,t,i,r)=>{r?t.data=t.data.replace(r,e):-1===t.data.indexOf(e)&&(t.data=i?e+t.data:t.data+e)})(c[d],t,r,p),d};function d(e){let t=this||{},i=e.call?e(t.p):e;return h(i.unshift?i.raw?((e,t,i)=>e.reduce((e,r,n)=>{let s=t[n];if(s&&s.call){let e=s(i),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;s=t?"."+t:e&&"object"==typeof e?e.props?"":l(e,""):!1===e?"":e}return e+r+(null==s?"":s)},""))(i,[].slice.call(arguments,1),t.p):i.reduce((e,i)=>Object.assign(e,i&&i.call?i(t.p):i),{}):i,n(t.target),t.g,t.o,t.k)}d.bind({g:1}),d.bind({k:1})},10114(e){"use strict";e.exports=JSON.parse('{"$id":"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#","description":"Meta-schema for $data reference (JSON AnySchema extension proposal)","type":"object","required":["$data"],"properties":{"$data":{"type":"string","anyOf":[{"format":"relative-json-pointer"},{"format":"json-pointer"}]}},"additionalProperties":false}')},7456(e){"use strict";e.exports=JSON.parse('{"$schema":"http://json-schema.org/draft-07/schema#","$id":"http://json-schema.org/draft-07/schema#","title":"Core schema meta-schema","definitions":{"schemaArray":{"type":"array","minItems":1,"items":{"$ref":"#"}},"nonNegativeInteger":{"type":"integer","minimum":0},"nonNegativeIntegerDefault0":{"allOf":[{"$ref":"#/definitions/nonNegativeInteger"},{"default":0}]},"simpleTypes":{"enum":["array","boolean","integer","null","number","object","string"]},"stringArray":{"type":"array","items":{"type":"string"},"uniqueItems":true,"default":[]}},"type":["object","boolean"],"properties":{"$id":{"type":"string","format":"uri-reference"},"$schema":{"type":"string","format":"uri"},"$ref":{"type":"string","format":"uri-reference"},"$comment":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"default":true,"readOnly":{"type":"boolean","default":false},"examples":{"type":"array","items":true},"multipleOf":{"type":"number","exclusiveMinimum":0},"maximum":{"type":"number"},"exclusiveMaximum":{"type":"number"},"minimum":{"type":"number"},"exclusiveMinimum":{"type":"number"},"maxLength":{"$ref":"#/definitions/nonNegativeInteger"},"minLength":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"pattern":{"type":"string","format":"regex"},"additionalItems":{"$ref":"#"},"items":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/schemaArray"}],"default":true},"maxItems":{"$ref":"#/definitions/nonNegativeInteger"},"minItems":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"uniqueItems":{"type":"boolean","default":false},"contains":{"$ref":"#"},"maxProperties":{"$ref":"#/definitions/nonNegativeInteger"},"minProperties":{"$ref":"#/definitions/nonNegativeIntegerDefault0"},"required":{"$ref":"#/definitions/stringArray"},"additionalProperties":{"$ref":"#"},"definitions":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"properties":{"type":"object","additionalProperties":{"$ref":"#"},"default":{}},"patternProperties":{"type":"object","additionalProperties":{"$ref":"#"},"propertyNames":{"format":"regex"},"default":{}},"dependencies":{"type":"object","additionalProperties":{"anyOf":[{"$ref":"#"},{"$ref":"#/definitions/stringArray"}]}},"propertyNames":{"$ref":"#"},"const":true,"enum":{"type":"array","items":true,"minItems":1,"uniqueItems":true},"type":{"anyOf":[{"$ref":"#/definitions/simpleTypes"},{"type":"array","items":{"$ref":"#/definitions/simpleTypes"},"minItems":1,"uniqueItems":true}]},"format":{"type":"string"},"contentMediaType":{"type":"string"},"contentEncoding":{"type":"string"},"if":{"$ref":"#"},"then":{"$ref":"#"},"else":{"$ref":"#"},"allOf":{"$ref":"#/definitions/schemaArray"},"anyOf":{"$ref":"#/definitions/schemaArray"},"oneOf":{"$ref":"#/definitions/schemaArray"},"not":{"$ref":"#"}},"default":true}')},40501(e){"use strict";e.exports=JSON.parse('{"name":"aws-appsync-auth-link","version":"3.0.7","main":"lib/index.js","license":"Apache-2.0","description":"AWS Mobile AppSync Auth Link for JavaScript","author":{"name":"Amazon Web Services","url":"https://aws.amazon.com/"},"homepage":"https://github.com/awslabs/aws-mobile-appsync-sdk-js.git","repository":{"type":"git","url":"https://github.com/awslabs/aws-mobile-appsync-sdk-js.git"},"scripts":{"prepare":"tsc","test":"jest --coverage --coverageReporters=text --passWithNoTests","test-watch":"jest --watch"},"dependencies":{"@aws-crypto/sha256-js":"^1.2.0","@aws-sdk/types":"^3.25.0","@aws-sdk/util-hex-encoding":"^3.29.0","debug":"2.6.9"},"devDependencies":{"@apollo/client":"^3.2.0"},"peerDependencies":{"@apollo/client":"3.x"}}')},3349(e){"use strict";e.exports=JSON.parse('{"aes-128-ecb":{"cipher":"AES","key":128,"iv":0,"mode":"ECB","type":"block"},"aes-192-ecb":{"cipher":"AES","key":192,"iv":0,"mode":"ECB","type":"block"},"aes-256-ecb":{"cipher":"AES","key":256,"iv":0,"mode":"ECB","type":"block"},"aes-128-cbc":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes-192-cbc":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes-256-cbc":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes128":{"cipher":"AES","key":128,"iv":16,"mode":"CBC","type":"block"},"aes192":{"cipher":"AES","key":192,"iv":16,"mode":"CBC","type":"block"},"aes256":{"cipher":"AES","key":256,"iv":16,"mode":"CBC","type":"block"},"aes-128-cfb":{"cipher":"AES","key":128,"iv":16,"mode":"CFB","type":"stream"},"aes-192-cfb":{"cipher":"AES","key":192,"iv":16,"mode":"CFB","type":"stream"},"aes-256-cfb":{"cipher":"AES","key":256,"iv":16,"mode":"CFB","type":"stream"},"aes-128-cfb8":{"cipher":"AES","key":128,"iv":16,"mode":"CFB8","type":"stream"},"aes-192-cfb8":{"cipher":"AES","key":192,"iv":16,"mode":"CFB8","type":"stream"},"aes-256-cfb8":{"cipher":"AES","key":256,"iv":16,"mode":"CFB8","type":"stream"},"aes-128-cfb1":{"cipher":"AES","key":128,"iv":16,"mode":"CFB1","type":"stream"},"aes-192-cfb1":{"cipher":"AES","key":192,"iv":16,"mode":"CFB1","type":"stream"},"aes-256-cfb1":{"cipher":"AES","key":256,"iv":16,"mode":"CFB1","type":"stream"},"aes-128-ofb":{"cipher":"AES","key":128,"iv":16,"mode":"OFB","type":"stream"},"aes-192-ofb":{"cipher":"AES","key":192,"iv":16,"mode":"OFB","type":"stream"},"aes-256-ofb":{"cipher":"AES","key":256,"iv":16,"mode":"OFB","type":"stream"},"aes-128-ctr":{"cipher":"AES","key":128,"iv":16,"mode":"CTR","type":"stream"},"aes-192-ctr":{"cipher":"AES","key":192,"iv":16,"mode":"CTR","type":"stream"},"aes-256-ctr":{"cipher":"AES","key":256,"iv":16,"mode":"CTR","type":"stream"},"aes-128-gcm":{"cipher":"AES","key":128,"iv":12,"mode":"GCM","type":"auth"},"aes-192-gcm":{"cipher":"AES","key":192,"iv":12,"mode":"GCM","type":"auth"},"aes-256-gcm":{"cipher":"AES","key":256,"iv":12,"mode":"GCM","type":"auth"}}')},8049(e){"use strict";e.exports=JSON.parse('{"sha224WithRSAEncryption":{"sign":"rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"RSA-SHA224":{"sign":"ecdsa/rsa","hash":"sha224","id":"302d300d06096086480165030402040500041c"},"sha256WithRSAEncryption":{"sign":"rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"RSA-SHA256":{"sign":"ecdsa/rsa","hash":"sha256","id":"3031300d060960864801650304020105000420"},"sha384WithRSAEncryption":{"sign":"rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"RSA-SHA384":{"sign":"ecdsa/rsa","hash":"sha384","id":"3041300d060960864801650304020205000430"},"sha512WithRSAEncryption":{"sign":"rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA512":{"sign":"ecdsa/rsa","hash":"sha512","id":"3051300d060960864801650304020305000440"},"RSA-SHA1":{"sign":"rsa","hash":"sha1","id":"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{"sign":"ecdsa","hash":"sha1","id":""},"sha256":{"sign":"ecdsa","hash":"sha256","id":""},"sha224":{"sign":"ecdsa","hash":"sha224","id":""},"sha384":{"sign":"ecdsa","hash":"sha384","id":""},"sha512":{"sign":"ecdsa","hash":"sha512","id":""},"DSA-SHA":{"sign":"dsa","hash":"sha1","id":""},"DSA-SHA1":{"sign":"dsa","hash":"sha1","id":""},"DSA":{"sign":"dsa","hash":"sha1","id":""},"DSA-WITH-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-SHA224":{"sign":"dsa","hash":"sha224","id":""},"DSA-WITH-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-SHA256":{"sign":"dsa","hash":"sha256","id":""},"DSA-WITH-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-SHA384":{"sign":"dsa","hash":"sha384","id":""},"DSA-WITH-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-SHA512":{"sign":"dsa","hash":"sha512","id":""},"DSA-RIPEMD160":{"sign":"dsa","hash":"rmd160","id":""},"ripemd160WithRSA":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"RSA-RIPEMD160":{"sign":"rsa","hash":"rmd160","id":"3021300906052b2403020105000414"},"md5WithRSAEncryption":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"},"RSA-MD5":{"sign":"rsa","hash":"md5","id":"3020300c06082a864886f70d020505000410"}}')},32279(e){"use strict";e.exports=JSON.parse('{"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}')},14923(e){"use strict";e.exports=JSON.parse('{"AElig":"Æ","AMP":"&","Aacute":"Á","Acirc":"Â","Agrave":"À","Aring":"Å","Atilde":"Ã","Auml":"Ä","COPY":"©","Ccedil":"Ç","ETH":"Ð","Eacute":"É","Ecirc":"Ê","Egrave":"È","Euml":"Ë","GT":">","Iacute":"Í","Icirc":"Î","Igrave":"Ì","Iuml":"Ï","LT":"<","Ntilde":"Ñ","Oacute":"Ó","Ocirc":"Ô","Ograve":"Ò","Oslash":"Ø","Otilde":"Õ","Ouml":"Ö","QUOT":"\\"","REG":"®","THORN":"Þ","Uacute":"Ú","Ucirc":"Û","Ugrave":"Ù","Uuml":"Ü","Yacute":"Ý","aacute":"á","acirc":"â","acute":"´","aelig":"æ","agrave":"à","amp":"&","aring":"å","atilde":"ã","auml":"ä","brvbar":"¦","ccedil":"ç","cedil":"¸","cent":"¢","copy":"©","curren":"¤","deg":"°","divide":"÷","eacute":"é","ecirc":"ê","egrave":"è","eth":"ð","euml":"ë","frac12":"½","frac14":"¼","frac34":"¾","gt":">","iacute":"í","icirc":"î","iexcl":"¡","igrave":"ì","iquest":"¿","iuml":"ï","laquo":"«","lt":"<","macr":"¯","micro":"µ","middot":"·","nbsp":" ","not":"¬","ntilde":"ñ","oacute":"ó","ocirc":"ô","ograve":"ò","ordf":"ª","ordm":"º","oslash":"ø","otilde":"õ","ouml":"ö","para":"¶","plusmn":"±","pound":"£","quot":"\\"","raquo":"»","reg":"®","sect":"§","shy":"­","sup1":"¹","sup2":"²","sup3":"³","szlig":"ß","thorn":"þ","times":"×","uacute":"ú","ucirc":"û","ugrave":"ù","uml":"¨","uuml":"ü","yacute":"ý","yen":"¥","yuml":"ÿ"}')},61711(e){"use strict";e.exports=JSON.parse('{"0":"�","128":"€","130":"‚","131":"ƒ","132":"„","133":"…","134":"†","135":"‡","136":"ˆ","137":"‰","138":"Š","139":"‹","140":"Œ","142":"Ž","145":"‘","146":"’","147":"“","148":"”","149":"•","150":"–","151":"—","152":"˜","153":"™","154":"š","155":"›","156":"œ","158":"ž","159":"Ÿ"}')},37821(e){"use strict";e.exports=JSON.parse('{"modp1":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},"modp2":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},"modp5":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},"modp14":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},"modp15":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},"modp16":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},"modp17":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},"modp18":{"gen":"02","prime":"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}')},23718(e){"use strict";e.exports={rE:"6.6.1"}}}]);
//# sourceMappingURL=509.f368fd51c1b00cd60323.js.map